mirror of
https://github.com/Vimux/Binario.git
synced 2024-11-21 21:58:28 +00:00
Use .Param for TOC and comments
Enable/disable "TOC" and "comments" partials for all site or specific posts. See: https://gohugo.io/functions/param/
This commit is contained in:
parent
0f53632b07
commit
b099c5e941
2 changed files with 2 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
{{ if and .Site.DisqusShortname (not (or .Site.Params.comments .Params.comments)) }}
|
||||
{{ if and (.Site.DisqusShortname) (.Param "comments") }}
|
||||
<section class="comments block">
|
||||
{{ template "_internal/disqus.html" . }}
|
||||
</section>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{ if .Params.toc }}
|
||||
{{ if .Param "toc" }}
|
||||
<details class="post__toc toc" {{ if .Params.tocOpen }}open{{ end }}>
|
||||
<summary class="toc__title">{{- T "post_toc" -}}</summary>
|
||||
{{ .TableOfContents }}
|
||||
|
|
Loading…
Reference in a new issue