blog: clean up tags page

This commit is contained in:
Benjamin A. Petersen 2023-08-15 14:18:48 -04:00
parent c54933bf33
commit 2891da25f5
No known key found for this signature in database
GPG Key ID: EF6EF83523A4BE46
5 changed files with 53 additions and 11 deletions

File diff suppressed because one or more lines are too long

View File

@ -587,3 +587,11 @@ pre code {
}
}
}
.terms {
ul {
li {
display: block
}
}
}

View File

@ -1,14 +1,20 @@
{{ define "main" }}
<main>
{{ if or .Title .Content }}
<div>
{{ with .Title }}<h1>{{ . }}</h1>{{ end }}
{{ with .Content }}<div>{{ . }}</div>{{ end }}
<div class="hero subpage">
<div class="wrapper">
{{ if or .Title .Content }}
<div>
{{ with .Title }}<h1>{{ . }}</h1>{{ end }}
{{ with .Content }}<div>{{ . }}</div>{{ end }}
</div>
{{ end }}
</div>
</div>
{{ end }}
{{ range .Paginator.Pages }}
{{ .Render "summary" }}
{{ end }}
<div class="wrapper landing">
{{ range .Paginator.Pages }}
{{ .Render "summary" }}
{{ end }}
</div>
</main>
{{ end }}

View File

@ -2,7 +2,7 @@
<main>
<div class="hero blog">
<div class="wrapper">
<h2>Pinniped Blog Posts by {{ .Title }}</h2>
<h2>Pinniped Blog Posts For {{ .Title }}</h2>
</div>
</div>
<div class="wrapper blog landing">
@ -14,4 +14,4 @@
</div>
</main>
{{ partial "getting-started" . }}
{{ end }}
{{ end }}

View File

@ -0,0 +1,28 @@
{{ define "main" }}
<main>
<div class="hero subpage">
<div class="wrapper">
{{ if or .Title .Content }}
<div>
{{ with .Title }}<h1>{{ . }}</h1>{{ end }}
{{ with .Content }}<div>{{ . }}</div>{{ end }}
</div>
{{ end }}
</div>
</div>
<div class="wrapper terms">
<p>Blog posts have been tagged with the following set of tags (including authors):</p>
<ul>
{{range $name, $taxonomy := .Site.Taxonomies.tags}} {{ $cnt := .Count }}
{{ with $.Site.GetPage (printf "/tags/%s" $name) }}
<li>
<a href={{ .RelPermalink }} title="All pages with tag <i>{{$name}}</i>">{{ .Title }}</a>
<sup>{{$cnt}}</sup>
</li>
{{end}}
{{end}}
</ul>
</div>
</main>
{{ end }}