hugo-theme-anubis2/layouts/_default/list.html
vringar fe94f1b2ff Use .Pages instead of site.RegularPages in list.html
This results in Section Pages only showing the
pages of their respective Sections instead
of showing all available articles.
2021-06-28 14:44:57 +02:00

19 lines
705 B
HTML

{{ define "main" }}
<div class="index-content">
{{ .Content }}
</div>
<div class="articles h-feed">
<h1 class="post-title">{{ i18n .Title }}</h1>
{{ $pages := where .Pages "Type" "in" site.Params.mainSections }}
{{ range $pages }}
<div class="post-short-list h-entry">
<header class="post-header">
<h2 class="p-name post-title{{ if .Params.favorite }} favorite{{end}}{{ if .Params.draft }} draft{{end}}"><a class="u-url" href="{{ .RelPermalink }}">{{ trim .Title " " }}</a></h2>
</header>
{{ partial "postInfo.html" . }}
</div>
{{ end }}
</div>
{{ end }}