Improve list pages + support "series"

- Use a <ul>: better accessibility
- Background for individual pages in the list, giving a better feeling
  of separation
- Support "series" taxonomy (displayed oldest to newest)
This commit is contained in:
2021-11-12 20:25:47 -06:00
parent 57be090b6a
commit b03fc6c7b1
5 changed files with 62 additions and 17 deletions

View File

@ -10,8 +10,9 @@
</span>
</h1>
{{ with .Sections }}
<div class="sections">
{{ range .Sections }}
{{ range . }}
<a class="section-anchor" href="{{ .Permalink }}">
<div class="section">
@ -34,13 +35,18 @@
{{ end }}
</div>
{{ end }}
<div class="posts">
{{ range .Paginator.Pages }}
{{ .Render "summary" }}
{{ else }}
{{ i18n "no_posts" }}
{{ end }}
<div class="page-list">
<ul>
{{ range .Paginator.Pages }}
<li>{{ .Render "summary" }}</li>
{{ else }}
<div>
{{ i18n "no_posts" }}
</div>
{{ end }}
</ul>
</div>
{{ if gt .Paginator.TotalPages 1 }}