From: Kai Moritz Date: Sun, 30 Nov 2025 08:11:06 +0000 (+0100) Subject: Partial `terms.html` überarbeitet X-Git-Tag: frontend--hugo--rebase--2025-12-21--19-20~20 X-Git-Url: https://juplo.de/gitweb/?a=commitdiff_plain;h=2b6bc792645e8594ed03d41563e1ed4cd382e3ed;p=website Partial `terms.html` überarbeitet --- diff --git a/layouts/_partials/terms.html b/layouts/_partials/terms.html index 8a6ebec2..a10e59ec 100644 --- a/layouts/_partials/terms.html +++ b/layouts/_partials/terms.html @@ -1,23 +1,17 @@ -{{- /* -For a given taxonomy, renders a list of terms assigned to the page. - -@context {page} page The current page. -@context {string} taxonomy The taxonomy. - -@example: {{ partial "terms.html" (dict "taxonomy" "tags" "page" .) }} -*/}} - -{{- $page := .page }} -{{- $taxonomy := .taxonomy }} - -{{- with $page.GetTerms $taxonomy }} - {{- $label := (index . 0).Parent.LinkTitle }} -
-
{{ $label }}:
- -
+ diff --git a/layouts/page.html b/layouts/page.html index 30fcf482..e6b6060b 100644 --- a/layouts/page.html +++ b/layouts/page.html @@ -4,5 +4,7 @@ {{ .Content }} - {{ partial "terms.html" (dict "taxonomy" "tags" "page" .) }} +{{ end }} +{{ define "marginalcontent" }} + {{ partial "terms.html" . }} {{ end }}