diff options
author | Christian Mutti <christian@chrs.dev> | 2024-06-21 16:21:25 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-21 16:21:25 -0300 |
commit | e7b875a1fabbd6f5ca13b76cca994b606b1da593 (patch) | |
tree | fbdb9f6e002f1b1582a1b6111d46d3e561ee2f7a /layouts | |
parent | 729a354f4cf3f44e7920cf56cfbba77037fa00b6 (diff) | |
download | hugo-bearcub-e7b875a1fabbd6f5ca13b76cca994b606b1da593.tar.gz hugo-bearcub-e7b875a1fabbd6f5ca13b76cca994b606b1da593.tar.bz2 |
Add `hideReply` functionality to pages (#18)
Set the `hideReply` param on front matter to completely remove the "reply
to" link present in the bottom of the pages. This is
backwards-compatible given that any page that does not have the
`hideReply` param will continue to work as before.
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/_default/single.html | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 4ff8d75..2baecc4 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -16,6 +16,7 @@ <a class="blog-tags" href="{{ .RelPermalink }}">#{{ lower .LinkTitle }}</a> {{ end }} </p> +{{ if not .Params.hideReply }} {{ with .Site.Params.author.email }} <p> <a href='mailto:{{ . }}?subject={{ i18n "email-subject" }}"{{ default $.Site.Title $.Page.Title }}"'> @@ -24,3 +25,4 @@ </p> {{ end }} {{ end }} +{{ end }} |