mirror of
https://github.com/Wonderfall/hugo-WonderMod.git
synced 2024-11-24 11:31:37 +01:00
Add post-content
only if it exists
This commit is contained in:
parent
162d80071f
commit
b4393b3d6e
@ -16,11 +16,13 @@
|
||||
</header>
|
||||
{{- end }}
|
||||
|
||||
{{- if .Content }}
|
||||
<div class="post-content">
|
||||
{{- if not (.Param "disableAnchoredHeadings") }}
|
||||
{{- partial "anchored_headings.html" .Content -}}
|
||||
{{- else }}{{ .Content }}{{ end }}
|
||||
</div>
|
||||
{{- end }}
|
||||
|
||||
{{- $pages := union .RegularPages .Sections }}
|
||||
|
||||
|
@ -25,11 +25,15 @@
|
||||
{{- if (.Param "ShowToc") }}
|
||||
{{- partial "toc.html" . }}
|
||||
{{- end }}
|
||||
|
||||
{{- if .Content }}
|
||||
<div class="post-content">
|
||||
{{- if not (.Param "disableAnchoredHeadings") }}
|
||||
{{- partial "anchored_headings.html" .Content -}}
|
||||
{{- else }}{{ .Content }}{{ end }}
|
||||
</div>
|
||||
{{- end }}
|
||||
|
||||
<footer class="post-footer">
|
||||
{{- if .Params.tags }}
|
||||
<ul class="post-tags">
|
||||
|
Loading…
Reference in New Issue
Block a user