mirror of
https://github.com/adityatelange/hugo-PaperMod.git
synced 2025-10-26 22:22:31 +01:00
cover: granular controls for hiding cover image #156
in site config =>
params:
cover:
hidden: true # hide everywhere but not in structured data
hiddenInList: true # hide on list pages and home
hiddenInSingle: true # hide on single page
per-page in front-matter =>
hidden: true # only hide on current single page
This commit is contained in:
@@ -31,7 +31,8 @@
|
||||
{{- $class = "post-entry tag-entry" }}
|
||||
{{- end }}
|
||||
<article class="{{ $class }}">
|
||||
{{- partial "cover.html" (dict "cxt" . "IsHome" true) }}
|
||||
{{- $isHidden := (.Site.Params.cover.hidden | default .Site.Params.cover.hiddenInList)}}
|
||||
{{- partial "cover.html" (dict "cxt" . "IsHome" true "isHidden" $isHidden) }}
|
||||
<header class="entry-header">
|
||||
<h2>
|
||||
{{ .Title }}
|
||||
|
||||
Reference in New Issue
Block a user