Clean up the terms template a bit

This commit is contained in:
Eryn Wells 2024-01-08 13:16:53 -08:00
parent 8b7e70dc81
commit ee9382b7a9

View file

@ -6,35 +6,18 @@
<header class="page"> <header class="page">
<h1>{{ .Title }}</h1> <h1>{{ .Title }}</h1>
</header> </header>
<article>
{{ .Content }}
{{- range .Data.Terms.Alphabetical -}} {{ .Content }}
<h2>{{ .Name | title }}</h2>
{{- range .WeightedPages -}} {{- range .Data.Terms.Alphabetical -}}
<article class="post"> <h2>{{ .Name | title }}</h2>
<header>
<time class="nobreak" datetime="{{ .Date | time.Format "2006-01-02" }}">{{ .Date | time.Format "Jan 2, 2006" }}</time>
<h1 class="title"><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
</header>
{{ if .Description }} {{- range .WeightedPages -}}
<p>{{ .Description }}</p> {{ if or (not .Draft) (not hugo.IsProduction) }}
{{ else if lt .WordCount 110 }} {{ .Render "li_grid_with_date" }}
{{ .Content }} {{ end }}
{{ else }}
{{ warnf "Post \"%s\" doesn't have a description or content suitable for the blog list" .Title }}
<p>{{ .WordCount }} words</p>
{{ end }}
{{ partial "footer_tags.html" . }}
{{ partial "development/draft_tag.html" . }}
</article>
{{- end -}}
{{- end -}} {{- end -}}
</article> {{- end -}}
{{ end }} {{ end }}
{{ define "footer" }} {{ define "footer" }}