binario/layouts/partials/post_toc.html
vimux b099c5e941
Use .Param for TOC and comments
Enable/disable "TOC" and "comments" partials for all site or specific posts.
See: https://gohugo.io/functions/param/
2018-05-27 00:02:06 +03:00

6 lines
No EOL
196 B
HTML

{{ if .Param "toc" }}
<details class="post__toc toc" {{ if .Params.tocOpen }}open{{ end }}>
<summary class="toc__title">{{- T "post_toc" -}}</summary>
{{ .TableOfContents }}
</details>
{{ end }}