creates article list partial

This commit is contained in:
Drew
2025-03-11 15:23:36 -06:00
parent 2ad602faf1
commit 257a5a7dfc
4 changed files with 43 additions and 35 deletions

View File

@ -1,25 +1,7 @@
{{ define "main" }}
<main class="flex gap-4 lg:gap-16 justify-around mt-8">
<ul class="flex flex-col gap-4 w-full">
{{ range where .Site.RegularPages "Section" "oral-histories" }}
<li class="flex gap-4 items-center">
<a class="flex-grow" href="{{ .RelPermalink }}">{{ partial "article-wompum.html" . }}</a>
<time class="text-gray-800 font-iosevka" datetime="{{ .Date.Format "2006-01-02" }}">
<p>{{ .Date.Format "Jan" }}</p>
<p>{{ .Date.Format "02" }}</p>
<p>{{ .Date.Format "2006" }}</p>
</time>
<div class="flex-shrink-0 max-w-max">
<a class="text-2xl font-bold hover:text-green-900 underline" href="{{ .RelPermalink }}">{{ .Title }}</a>
<p class="max-w-prose">{{ .Params.summary }}</p>
{{ partial "tags.html" .}}
</div>
</li>
{{ end }}
{{ partial "article-list.html" (dict "Pages" (where .Site.RegularPages "Section" "oral-histories")) }}
</ul>
<aside class="max-w-prose w-1/4 flex flex-col gap-8 mb-8">
@ -31,7 +13,7 @@
<section>
<h2 class="text-4xl mb-4 font-iosevka">Narrators</h2>
<div class="tag-cloud font-iosevka">
<div class="tag-cloud font-iosevka text-gray-600">
{{ $narrators := slice }}
{{ range .Site.RegularPages }}
{{ with .Params.narrator }}
@ -51,7 +33,7 @@
<section>
<h2 class="text-4xl mb-4 font-iosevka">Facilitators</h2>
<div class="tag-cloud font-iosevka">
<div class="tag-cloud font-iosevka text-gray-600">
{{ $facilitators := slice }}
{{ range .Site.RegularPages }}
{{ with .Params.facilitator }}
@ -71,7 +53,7 @@
<section>
<h2 class="text-4xl mb-4 font-iosevka">Tags</h2>
<div class="tag-cloud font-iosevka">
<div class="tag-cloud font-iosevka text-gray-600">
{{ $tags := .Site.Taxonomies.tags }}
{{ range $tag, $pages := $tags }}
<a href="{{ "/tags/" | relLangURL }}{{ $tag | urlize }}" style="font-size: {{ add 1 (div (len $pages) 2) }}em;"