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

github.com/pfadfinder-konstanz/hugo-dpsg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormax.mehl <max.mehl@fsfe.org>2021-08-29 19:31:19 +0300
committermax.mehl <max.mehl@fsfe.org>2021-08-29 19:31:19 +0300
commitea40eff1b97f5253a46f16147b551520f1625d74 (patch)
tree640588a5aca5f2c41bc2af43565e74a2bfbcf32e
parentb1a3b436679ad8ec464071a9154256dfdc260cbf (diff)
introduce extra partial below page's h1
-rw-r--r--README.md3
-rw-r--r--layouts/_default/list.html1
-rw-r--r--layouts/_default/single.html1
-rw-r--r--layouts/index.html1
4 files changed, 5 insertions, 1 deletions
diff --git a/README.md b/README.md
index 8446c93..1daede8 100644
--- a/README.md
+++ b/README.md
@@ -93,7 +93,8 @@ theme = "hugo-dpsg"
dateformat = "02.01.2006" # Change the format of dates
customCSS = ["css/custom.css"] # Include custom CSS files, can also be used per-page as front matter attribute
customJS = ["js/custom.js"] # Include custom JS files
- customPartial = "piwik.html" # Include custom partials, e.g. tracking codes
+ customPartial = "piwik.html" # Include custom partials at the end of the page, e.g. tracking codes
+ belowTitlePartial = "alert.html" # Include custom partial below the pages title
[Params.style.vars]
highlightColor = "#003056" # Override main theme color
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 2ab1b8b..55040f1 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -5,6 +5,7 @@
<h1 class="main__title">{{ . }}</h1>
</header>
{{- end }}
+ {{- with .Site.Params.belowTitlePartial }}{{ partial . }}{{ end }}
{{- with .Content }}
<div class="content main__content clearfix">
{{ . }}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index b5ba965..143f4e2 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -10,6 +10,7 @@
<div class="post__meta meta">{{ . }}</div>
{{- end }}
</header>
+ {{- with .Site.Params.belowTitlePartial }}{{ partial . }}{{ end }}
{{- if and (.Params.thumbnail) (not .Params.thumbnail_hide_post) }}
<figure class="post__thumbnail">
<img src="{{ .Params.thumbnail | relURL }}" alt="{{ .Title }}">
diff --git a/layouts/index.html b/layouts/index.html
index 911e1a5..cca40a4 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -5,6 +5,7 @@
<h1 class="main__title">{{ . }}</h1>
</header>
{{- end }}
+ {{- with .Site.Params.belowTitlePartial }}{{ partial . }}{{ end }}
{{- with .Content }}
<div class="content main__content clearfix">
{{ . }}