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 }}
|
2022-04-30 11:36:39 +00:00
|
|
|
<svg class="gblog-icon gblog_tag"><use xlink:href="#gblog_tag"></use></svg>
|
2022-01-29 13:38:08 +00:00
|
|
|
<span class="gblog-post__tag">
|
|
|
|
{{ $pageCount }}
|
|
|
|
post{{ if ne $pageCount 1 }}s{{ end }}
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
|
|
|
|
|
<span class="flex align-center no-wrap">
|
2022-04-30 11:36:39 +00:00
|
|
|
<svg class="gblog-icon gblog_star"><use xlink:href="#gblog_star"></use></svg>
|
2022-01-29 13:38:08 +00:00
|
|
|
<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 }}
|