Welcome to mirror list, hosted at ThFree Co, Russian Federation.

recent-pages.html « partials « layouts - github.com/marketempower/axiom.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 11b3c6867dbaa2cef077f297958e89b5965c21ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{{- $limit := .limit | default 7 -}}
{{- $sections := "" -}}
{{- with .sections }}
{{- $sections = split . "," -}}
{{- end }}
{{- $sections = $sections | default $.Site.Params.mainSections | default (slice "post" "posts") -}}
{{- $class := .class | default "mt-8" -}}
{{- $style := .style -}}

{{- $pages := first $limit (where $.Site.RegularPages "Type" "in" $sections) -}}
{{- range $pages }}
<div class="{{ $class }}"{{ with $style }} style="{{ . | safeCSS }}"{{ end }}>
  {{ .Render "summary" }}
</div>
{{- end }}