Rename pages to page_list

master
Will Faught 2 years ago
parent 2c4f4324ff
commit 52eb483ed7

@ -277,7 +277,7 @@ paige:
title: title:
class: "display-5 fw-bold text-center" # Default is "display-5 fw-bold text-center" class: "display-5 fw-bold text-center" # Default is "display-5 fw-bold text-center"
hide: false # Default is false hide: false # Default is false
pages: # Page lists in list and term default layouts page_list:
authors: authors:
class: "text-center text-secondary" # Default is "text-center text-secondary" class: "text-center text-secondary" # Default is "text-center text-secondary"
show: false # Default is false show: false # Default is false

@ -18,24 +18,24 @@
{{ $p := .Paginate (.Pages.ByDate.Reverse.GroupByDate "January 2006") }} {{ $p := .Paginate (.Pages.ByDate.Reverse.GroupByDate "January 2006") }}
<section> <section>
{{ range $p.PageGroups }} {{ range $p.PageGroups }}
{{ if $.Param "paige.pages.header.hide" | not }} {{ if $.Param "paige.page_list.header.hide" | not }}
<h2 class="{{ $.Param `paige.pages.header.class` | default `h5 text-center` }}">{{ .Key }}</h2> <h2 class="{{ $.Param `paige.page_list.header.class` | default `h5 text-center` }}">{{ .Key }}</h2>
{{ end }} {{ end }}
{{ range .Pages }} {{ range .Pages }}
{{ $class := "text-center" }} {{ $class := "text-center" }}
{{ $authors := cond ($.Param "paige.pages.authors.show" | not) "" (partial "paige/func-authors.html" .) }} {{ $authors := cond ($.Param "paige.page_list.authors.show" | not) "" (partial "paige/func-authors.html" .) }}
{{ $authorsclass := $.Param "paige.pages.authors.class" | default (print $class " text-secondary") }} {{ $authorsclass := $.Param "paige.page_list.authors.class" | default (print $class " text-secondary") }}
{{ $date := cond ($.Param "paige.pages.date.show" | not) "" .PublishDate }} {{ $date := cond ($.Param "paige.page_list.date.show" | not) "" .PublishDate }}
{{ $dateclass := $.Param "paige.pages.date.class" | default (print $class " text-secondary") }} {{ $dateclass := $.Param "paige.page_list.date.class" | default (print $class " text-secondary") }}
{{ $description := cond ($.Param "paige.pages.description.hide" | not) (.Description | markdownify) "" }} {{ $description := cond ($.Param "paige.page_list.description.hide" | not) (.Description | markdownify) "" }}
{{ $descriptionclass := $.Param "paige.pages.description.class" | default $class }} {{ $descriptionclass := $.Param "paige.page_list.description.class" | default $class }}
{{ $flags := slice }} {{ $flags := slice }}
{{ $gap := "mb-0" }} {{ $gap := "mb-0" }}
{{ $summary := cond ($.Param "paige.pages.summary.show" | not) "" (.Summary | strings.TrimPrefix "<p>" | strings.TrimSuffix "</p>") }} {{ $summary := cond ($.Param "paige.page_list.summary.show" | not) "" (.Summary | strings.TrimPrefix "<p>" | strings.TrimSuffix "</p>") }}
{{ $summaryclass := $.Param "paige.pages.summary.class" | default $class }} {{ $summaryclass := $.Param "paige.page_list.summary.class" | default $class }}
{{ $title := cond ($.Param "paige.pages.title.hide" | not) (.Title | markdownify) "" }} {{ $title := cond ($.Param "paige.page_list.title.hide" | not) (.Title | markdownify) "" }}
{{ $titleclass := $.Param "paige.pages.title_class" | default $class }} {{ $titleclass := $.Param "paige.page_list.title_class" | default $class }}
{{ if .Draft }} {{ if .Draft }}
{{ $flags = $flags | append "paige-draft" "paige-unpublished" }} {{ $flags = $flags | append "paige-draft" "paige-unpublished" }}

Loading…
Cancel
Save