hugo-internet-weblog/layouts/partials/preview_list.html
2019-08-17 18:54:19 -04:00

25 lines
585 B
HTML

{{ $pages := .Pages }}
{{ if .IsHome }}
{{ $pages = .Site.RegularPages }}
{{ end }}
{{ $paginator := .Paginate $pages }}
{{ range .Paginator.Pages }}
{{ $url := replace .Permalink .Site.BaseURL "" }}
{{ if or (eq .Type "microposts") (eq .Type "micropost") }}
{{ partial "preview_micropost.html" . }}
{{ end }}
{{ if or (eq .Type "photos") (eq .Type "photo") }}
{{ partial "preview_photo_post.html" . }}
{{ end }}
{{ if or (eq .Type "posts") (eq .Type "post") }}
{{ partial "preview_post.html" . }}
{{ end }}
{{ end }}
{{ partial "pagination.html" . }}