1
Fork 0

Replace zero date with hr

This commit is contained in:
Jake Howard 2018-02-22 20:34:01 +00:00
parent 7daff47eaf
commit 8056c37d92
Signed by: jake
GPG key ID: 57AFB45680EDD477

View file

@ -5,9 +5,13 @@
<h1 class="display-4">{{ .Title }}</h1>
{{ range $paginator.PageGroups }}
{{ $month := (print .Key "-01") }}
<h3 class="mt-5">
<time datetime="{{ $month }}" title='{{ dateFormat "January 2006" $month }}'>{{ dateFormat "2006-01" $month }}</time>
</h3>
{{ if (index .Pages 0).Date.IsZero }}
<hr class="my-5" />
{{ else }}
<h3 class="mt-5">
<time datetime="{{ $month }}" title='{{ dateFormat "January 2006" $month }}'>{{ dateFormat "2006-01" $month }}</time>
</h3>
{{ end }}
{{ range (sort .Pages "Date" "desc") }}
{{ partial "list_item.html" . }}
{{ end }}