Include all existing events in both languages and add homepage-only logo credits. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
29 lines
1.3 KiB
HTML
29 lines
1.3 KiB
HTML
<section class="event-list" aria-labelledby="event-list-title">
|
|
<h1 id="event-list-title">{{ .Page.Params.eventsTitle }}</h1>
|
|
<div class="event-cards">
|
|
{{ range .Page.Params.events }}
|
|
<article class="event-card{{ with .status }} event-card--upcoming{{ end }}">
|
|
<header class="event-card__header">
|
|
<h2>{{ .code }}</h2>
|
|
{{ $logo := resources.GetMatch (printf "img/events/%s.*" (lower .code)) }}
|
|
{{ $original := .logoOriginal }}
|
|
{{ with $logo }}
|
|
{{ if $original }}
|
|
<img class="event-card__image" src="{{ .RelPermalink }}" alt="">
|
|
{{ else }}
|
|
<span class="event-card__logo" style="--event-logo: url('{{ .RelPermalink }}')" aria-hidden="true"></span>
|
|
{{ end }}
|
|
{{ else }}
|
|
{{ errorf "Missing event logo for %s" .code }}
|
|
{{ end }}
|
|
</header>
|
|
<div class="event-card__body">
|
|
<h3>{{ if .status }}{{ .title }}{{ else }}<a href="{{ .url }}">{{ .title }}</a>{{ end }}</h3>
|
|
<p>{{ .event }}</p>
|
|
<p class="event-card__date">{{ .date }}, {{ .location }}</p>
|
|
{{ with .status }}<p class="event-card__status">{{ . }}</p>{{ end }}
|
|
</div>
|
|
</article>
|
|
{{ end }}
|
|
</div>
|
|
</section>
|