GoBlog/templates/photosummary.gohtml

18 lines
673 B
Plaintext

{{ define "photosummary" }}
<article class="h-entry border-bottom">
{{ if gt .Data.Priority 0 }}<p>📌 {{ string .Blog.Lang "pinned" }}</p>{{ end }}
{{ if .Data.Title }}
<h2 class="p-name">
<a class="u-url" href="{{ .Data.Path }}">
{{ mdtext .Data.Title }}
</a>
</h2>
{{ end }}
{{ include "summarymeta" . }}
{{ range $i, $photo := (photolinks .Data) }}
{{ md ( printf "![](%s)" $photo ) }}
{{ end }}
<p class="p-summary">{{ summary .Data }}</p>
<p>{{ if (photolinks .Data) }}🖼️ {{ end }}<a class="u-url" href="{{ .Data.Path }}">{{ string .Blog.Lang "view" }}</a></p>
</article>
{{ end }}