Add upcoming section

This commit is contained in:
dolphinau 2025-09-06 19:43:00 +02:00
parent bcd86c1ebe
commit af606d3188
10 changed files with 172 additions and 105 deletions

View file

@ -0,0 +1,17 @@
<div class="upcoming">
{{ $sites := where site.RegularPages "Section" "upcoming" }}
{{ range sort $sites ".Params.ConcertDate" }}
<div class="upcoming-entry">
<p class="concert-date">
{{ $t := time.AsTime .Params.ConcertDate }}
{{ $format1 := "Monday 2 Jan 2006" }}
{{ $format2 := "Jan 2006" }}
<!-- TODO: Try format1 -->
{{ time.Format $format2 $t | humanize }}
</p>
<h2>{{ .LinkTitle }}</h2>
</div>
{{ end }}
</div>