summaryrefslogtreecommitdiff
path: root/templates/shortcodes
diff options
context:
space:
mode:
authorVanja Cosic <1070957+vanjacosic@users.noreply.github.com>2023-04-03 14:31:13 +0200
committerVanja Cosic <1070957+vanjacosic@users.noreply.github.com>2023-04-03 14:31:13 +0200
commite0615a7638c6f86b3f059f1d900376d315fbfeea (patch)
tree290e24a5eb237371326b43b98f58d1c6c811e45b /templates/shortcodes
downloadcph-rust-website-e0615a7638c6f86b3f059f1d900376d315fbfeea.zip
Initial commit (the draft version from February)
Diffstat (limited to 'templates/shortcodes')
-rw-r--r--templates/shortcodes/list_events.md15
1 files changed, 15 insertions, 0 deletions
diff --git a/templates/shortcodes/list_events.md b/templates/shortcodes/list_events.md
new file mode 100644
index 0000000..1b887c7
--- /dev/null
+++ b/templates/shortcodes/list_events.md
@@ -0,0 +1,15 @@
+{% set meetups = load_data(path="events.toml") %}
+
+{% if meetups[group] %}
+## {{ group | capitalize }}
+
+{% for item in meetups[group] %}
+### {{ item.title }}
+
+{% if item.url %}**Link:** [Meetup.com]({{ item.url }}){% endif %}
+**Date:** {% if item.date %}<time datetime="{{ item.date }}">{{ item.date | date(format="%A, %e %B %Y", timezone="Europe/Berlin") }}</time> {% else %}(No date found) {% endif %}
+**Venue:** {% if item.venue %}{{ item.venue }} – {% endif %}{% if item.address %}{{ item.address }} {% else %}(No venue) {% endif %}
+{% if item.content -%}**Description:**<blockquote>{{ item.content | safe }}</blockquote>{% endif %}
+
+{% endfor %}
+{% endif %}