mirror of
https://github.com/davegallant/davegallant.github.io.git
synced 2025-08-05 16:23:39 +00:00
28 lines
953 B
HTML
28 lines
953 B
HTML
<div class="post-meta">
|
|
{{- with .page.Date -}}
|
|
<span>{{ .Format "2006-01-02" }}</span>
|
|
{{- end -}}
|
|
{{- with .page.Params.Author -}}
|
|
<span> by </span><span class="post-meta__author">{{ . }}</span>
|
|
{{- end -}}
|
|
{{ with .page.Params.tags }}
|
|
<div class="post-tags">
|
|
{{ range . -}}
|
|
<a class="post-tag" href="{{ urlize (printf "tags/%s" . ) | absURL }}">
|
|
{{- /* Replace hyphen with non-breaking hyphen */ -}}
|
|
{{- replace (urlize .) "-" "‑" | safeHTML -}}
|
|
</a>
|
|
{{- end }}
|
|
</div>
|
|
{{ end }}
|
|
|
|
{{ if .page.Params.cover }}
|
|
<!--
|
|
Only lazy-load images below-the-fold. For post lists, start loading
|
|
covers from the third post and onwards.
|
|
-->
|
|
{{ $lazy := ge .pageIndex 2 }}
|
|
{{ partial "image.html" (dict "src" .page.Params.cover.src "alt" .page.Params.cover.alt "caption" .page.Params.cover.caption "page" .page "lazy" $lazy) }}
|
|
{{ end }}
|
|
</div>
|