From b07d4ff0dfe2267013e3be729b58fb2a83c2deb8 Mon Sep 17 00:00:00 2001 From: Martin Kagamino Lehoux Date: Sun, 14 Jun 2026 16:44:29 +0200 Subject: feat: Table of content --- layouts/_default/single.html | 2 +- layouts/partials/single/default.html | 2 +- layouts/partials/single/table-of-contents.html | 17 +++++++++++------ 3 files changed, 13 insertions(+), 8 deletions(-) (limited to 'layouts') diff --git a/layouts/_default/single.html b/layouts/_default/single.html index d20343b..d8ae6b6 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -1,6 +1,6 @@ {{ define "main" }} -
+

{{ .Title }}

diff --git a/layouts/partials/single/default.html b/layouts/partials/single/default.html index 25cda09..9b9b9c3 100644 --- a/layouts/partials/single/default.html +++ b/layouts/partials/single/default.html @@ -1,4 +1,4 @@ -
+
{{ partial "single/components/title/large" . }}
diff --git a/layouts/partials/single/table-of-contents.html b/layouts/partials/single/table-of-contents.html index b8489bc..05689a1 100644 --- a/layouts/partials/single/table-of-contents.html +++ b/layouts/partials/single/table-of-contents.html @@ -1,6 +1,11 @@ -{{ if and .TableOfContents .Params.tableOfContents }} - -{{ end }} \ No newline at end of file +{{ if and .TableOfContents (ne .Params.tableOfContents false) }} +
+ + On this page + + + + + {{ .TableOfContents }} +
+{{ end }} -- cgit v1.3