add nerd101

This commit is contained in:
Lyn Fugmann 2024-10-04 13:54:40 +02:00
parent 9ff8a13190
commit 1340f4a772
9 changed files with 247 additions and 8 deletions

View file

@ -1,10 +1,6 @@
---js
{
layout: "page.njk",
getLocalized: function(item) {
if (typeof item === "string") return item;
return item[this.ctx.lang];
},
toDate: function(dateStr) {
return new Date(dateStr);
}
@ -23,7 +19,7 @@
<div class="timeslot-container">
<h3 id="{{date}}_{{loop.index}}">
{% if event.livestream %}{% icon "solid:video", title="Livestream" %}{% endif %}
{{ getLocalized(event.title) }}
{{ event.title | localized }}
</h3>
<div class="timeslot-time">
@ -34,19 +30,19 @@
<span class="full">{{ event.start }}{{ " " + event.end if event.end }}</span>
</div>
<p>{{ getLocalized(event.description) | mdInline | safe }}</p>
<p>{{ event.description | localized | mdInline | safe }}</p>
{% if event.annotation %}
<p class="annotation">
{% icon "solid:exclamation", title=("Notice" if lang == "en" else "Hinweis") %}
{{ getLocalized(event.annotation) | mdInline | safe }}
{{ event.annotation | localized | mdInline | safe }}
</p>
{% endif %}
{% if event.location %}
<p class="location">
{% icon "solid:location-dot", title=("Location" if lang == "en" else "Veranstaltungsort") %}
{{ getLocalized(event.location) | mdInline | safe }}
{{ event.location | localized | mdInline | safe }}
</p>
{% endif %}