Allow to enable/disable the "contact me" section in the footer.

Just set `footer.contactMe.enable` in the config. Default is true, for
backwards compatibility.
This commit is contained in:
Jøhannes Lippmann 2021-04-28 09:46:51 +02:00
parent 674156343d
commit ecb6835e44

View file

@ -1,4 +1,5 @@
{{ $footerEnabled := site.Params.footer.enable | default true }} {{ $footerEnabled := site.Params.footer.enable | default true }}
{{ $contactMeEnabled := site.Params.footer.contactMe.enable | default true }}
{{ if $footerEnabled }} {{ if $footerEnabled }}
{{ $author:= site.Data.author }} {{ $author:= site.Data.author }}
@ -58,7 +59,7 @@
{{ end }} {{ end }}
</div> </div>
{{ if $author }} {{ if (and $contactMeEnabled $author) }}
<div class="col-md-4 col-sm-12"> <div class="col-md-4 col-sm-12">
<h5>{{ i18n "contact_me" }}</h5> <h5>{{ i18n "contact_me" }}</h5>
<ul> <ul>