Some layout tweaks for the term template
Allow removing the pages list if the "pages" page variable is set false.
This commit is contained in:
parent
f21ac49b08
commit
66d50f773b
1 changed files with 10 additions and 10 deletions
|
@ -12,20 +12,20 @@
|
|||
{{- $hasContent := false -}}
|
||||
{{ with .Content }}
|
||||
{{- $hasContent = true -}}
|
||||
<section>
|
||||
{{ . }}
|
||||
</section>
|
||||
{{ end }}
|
||||
|
||||
{{ if $hasContent }}
|
||||
<h2>Posts</h2>
|
||||
{{ end }}
|
||||
{{ if .Params.posts | default true }}
|
||||
{{ if and $hasContent }}
|
||||
<h2>Posts</h2>
|
||||
{{ end }}
|
||||
|
||||
<ul>
|
||||
{{- range .Pages -}}
|
||||
<li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
|
||||
{{- end -}}
|
||||
</ul>
|
||||
<ul>
|
||||
{{- range .Pages -}}
|
||||
<li><a href="{{ .RelPermalink }}">{{ .Title }}</a></li>
|
||||
{{- end -}}
|
||||
</ul>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ define "footer" }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue