{{ if .Pages }} {{ if .Params.paige.show_full_pages }} {{ $p := .Paginate .Pages }}
{{ range $p.Pages }} {{ .Scratch.Set "paige_show_full_pages" true }} {{ partial "paige/article.html" . }} {{ end }}
{{ if or $p.HasPrev $p.HasNext }}
{{ partial "paige/pagination.html" . }}
{{ end }} {{ else }} {{ $p := .Paginate (.Pages.ByDate.Reverse.GroupByDate "January 2006") }}
{{ range $p.PageGroups }}

{{ .Key }}

{{ range .Pages }} {{ $class := "text-center" }} {{ $authors := cond ($.Param "paige.pages.show_authors" | not | not) (partial "paige/func-authors.html" .) "" }} {{ $authorsclass := $.Param "paige.pages.authors_class" | default (print $class " text-secondary") }} {{ $date := cond ($.Param "paige.pages.show_date" | not | not) .PublishDate "" }} {{ $dateclass := $.Param "paige.pages.date_class" | default (print $class " text-secondary") }} {{ $description := cond ($.Param "paige.pages.hide_description" | not) (.Description | markdownify) "" }} {{ $descriptionclass := $.Param "paige.pages.description_class" | default $class }} {{ $flags := slice }} {{ $gap := "mb-0" }} {{ $summary := cond ($.Param "paige.pages.show_summary" | not | not) (.Summary | strings.TrimPrefix "

" | strings.TrimSuffix "

") "" }} {{ $summaryclass := $.Param "paige.pages.summary_class" | default $class }} {{ $title := .Title | markdownify }} {{ $titleclass := $.Param "paige.pages.title_class" | default $class }} {{ if .Draft }} {{ $flags = $flags | append "paige-draft" "paige-unpublished" }} {{ end }} {{ if and .ExpiryDate (lt .ExpiryDate now) }} {{ $flags = $flags | append "paige-expired" "paige-unpublished" }} {{ end }} {{ if and .PublishDate (gt .PublishDate now) }} {{ $flags = $flags | append "paige-future" "paige-unpublished" }} {{ end }} {{ if and .PublishDate .Lastmod (lt .PublishDate .Lastmod) }} {{ $flags = $flags | append "paige-modified" }} {{ end }} {{ $flags = delimit ($flags | sort | uniq) " " }}

{{ $title | markdownify }}

{{ with $description }}

{{ . }}

{{ end }} {{ with $authors }}

{{ . }}

{{ end }} {{ with $date }}

{{ end }} {{ if $summary }}

{{ $summary }}

{{ end }} {{ end }} {{ end }}
{{ if or $p.HasPrev $p.HasNext }}
{{ partial "paige/pagination.html" . }}
{{ end }} {{ end }} {{ end }}