mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-08-24 23:38:56 +00:00
6123eaac2c
The `_default` folder is removed.
26 lines
1.0 KiB
HTML
26 lines
1.0 KiB
HTML
{{- define "title" -}}
|
|
{{- .Params.Title | default (T .Data.Plural) | default .Data.Plural | dict "Some" | T "allSome" -}}
|
|
{{- if .Site.Params.withSiteTitle }} {{ .Site.Params.titleDelimiter }} {{ .Site.Title }}{{- end -}}
|
|
{{- end -}}
|
|
|
|
{{- define "content" -}}
|
|
{{- $taxonomies := .Data.Plural -}}
|
|
{{- $iconMap := dict
|
|
"categories" "fa-solid fa-folder-tree"
|
|
"collections" "fa-solid fa-layer-group"
|
|
"tags" "fa-solid fa-tags"
|
|
-}}
|
|
{{- $icon := index $iconMap $taxonomies | default $iconMap.categories -}}
|
|
|
|
<div class="page archive">
|
|
{{- /* Title */ -}}
|
|
<h1 class="single-title animate__animated animate__pulse animate__faster">
|
|
{{- dict "Class" (add $icon " fa-fw me-1") | partial "plugin/icon.html" -}}
|
|
{{- .Params.Title | default (T $taxonomies) | default $taxonomies | dict "Some" | T "allSome" }} <sup>{{ len .Data.Terms.ByCount }}</sup>
|
|
</h1>
|
|
{{- /* Render different taxonomies */ -}}
|
|
{{- $template := cond ( eq $taxonomies "tags") "tags" "taxonomies" -}}
|
|
{{- .Render $template -}}
|
|
</div>
|
|
{{- end -}}
|