2022-01-29 13:38:08 +00:00
|
|
|
{{ define "main" }}
|
|
|
|
{{ $paginator := .Paginate .Paginator.Pages }}
|
|
|
|
{{ range $paginator.Pages.ByTitle }}
|
|
|
|
<article class="gblog-post">
|
|
|
|
<header class="gblog-post__header">
|
|
|
|
<h1 class="gblog-post__title">
|
2022-02-05 19:02:17 +00:00
|
|
|
<a href="{{ .RelPermalink }}">{{ partial "utils/title" . }}</a>
|
2022-01-29 13:38:08 +00:00
|
|
|
</h1>
|
|
|
|
</header>
|
|
|
|
|
|
|
|
<footer class="gblog-post__meta flex align-center">
|
|
|
|
<span class="flex align-center no-wrap">
|
|
|
|
{{ $pageCount := len .Pages }}
|
|
|
|
<svg class="icon gblog_tag"><use xlink:href="#gblog_tag"></use></svg>
|
|
|
|
<span class="gblog-post__tag">
|
|
|
|
{{ $pageCount }}
|
|
|
|
post{{ if ne $pageCount 1 }}s{{ end }}
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
|
|
|
|
<span class="flex align-center no-wrap">
|
|
|
|
<svg class="icon gblog_star"><use xlink:href="#gblog_star"></use></svg>
|
|
|
|
<span>
|
|
|
|
{{ $latet := index .Pages.ByDate 0 }}
|
|
|
|
{{ with $latet }}
|
2022-02-05 19:02:17 +00:00
|
|
|
<a href="{{ .RelPermalink }}">{{ partial "utils/title" . }}</a>
|
2022-01-29 13:38:08 +00:00
|
|
|
{{ end }}
|
|
|
|
<i>by</i>
|
|
|
|
{{ $ac := 0 }}
|
|
|
|
{{ with $latet.Params.authors }}
|
|
|
|
{{ range sort . }}
|
|
|
|
{{ $author := index $.Site.Data.authors . }}
|
|
|
|
{{ with $.Site.GetPage (printf "/authors/%s" . | urlize) }}
|
|
|
|
{{ if eq $ac 0 }}
|
|
|
|
{{ template "post-author" dict "name" $author.name "page" . }}
|
|
|
|
{{ else }}
|
|
|
|
{{ template "post-author" dict "name" $author.name "page" . }}
|
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
{{ $ac = (add $ac 1) }}
|
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
</footer>
|
|
|
|
</article>
|
|
|
|
{{ end }}
|
|
|
|
{{ partial "pagination.html" . }}
|
|
|
|
{{ end }}
|