2020-09-21 16:03:05 +00:00
|
|
|
{{ define "title" }}
|
2020-10-12 16:47:23 +00:00
|
|
|
{{ if .Blog.Photos.Title }}
|
|
|
|
<title>{{ .Blog.Photos.Title }} - {{ .Blog.Title }}</title>
|
2020-09-21 16:03:05 +00:00
|
|
|
{{ else }}
|
2020-10-12 16:47:23 +00:00
|
|
|
<title>{{ .Blog.Title }}</title>
|
2020-09-21 16:03:05 +00:00
|
|
|
{{ end }}
|
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ define "main" }}
|
|
|
|
<main>
|
2020-10-12 16:47:23 +00:00
|
|
|
{{ with .Blog.Photos.Title }}<h1>{{ . }}</h1>{{ end }}
|
|
|
|
{{ with .Blog.Photos.Description }}{{ md . }}{{ end }}
|
|
|
|
{{ if (or .Blog.Photos.Title .Blog.Photos.Description) }}
|
2020-09-21 16:03:05 +00:00
|
|
|
<hr>
|
|
|
|
{{ end }}
|
2020-10-12 16:47:23 +00:00
|
|
|
{{ $blog := .Blog }}
|
|
|
|
{{ range $i, $post := .Data.Posts }}
|
|
|
|
{{ include "photosummary" $blog $post }}
|
2020-09-21 16:03:05 +00:00
|
|
|
{{ end }}
|
2020-10-12 16:47:23 +00:00
|
|
|
{{ if .Data.HasPrev }}
|
2020-10-12 17:12:43 +00:00
|
|
|
<p><a href="{{ .Data.Prev }}">{{ string .Blog.Lang "prev" }}</a></p>
|
2020-09-21 16:03:05 +00:00
|
|
|
{{ end }}
|
2020-10-12 16:47:23 +00:00
|
|
|
{{ if .Data.HasNext }}
|
2020-10-12 17:12:43 +00:00
|
|
|
<p><a href="{{ .Data.Next }}">{{ string .Blog.Lang "next" }}</a></p>
|
2020-09-21 16:03:05 +00:00
|
|
|
{{ end }}
|
|
|
|
</main>
|
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ define "photos" }}
|
|
|
|
{{ template "base" . }}
|
|
|
|
{{ end }}
|