diff options
author | Ngô Ngọc Đức Huy <huyngo@disroot.org> | 2023-08-04 15:19:35 +0700 |
---|---|---|
committer | Ngô Ngọc Đức Huy <huyngo@disroot.org> | 2023-08-04 15:19:35 +0700 |
commit | 743ec02a6980c4ee0fbd9f2cb5f23b568dc6d706 (patch) | |
tree | 3d9efae1a8b3c3724844cece5d4e4c13c2ca9331 /layouts/partials/toc.html | |
parent | b472b8a7485a560740000f945f6e2fef3829fbb5 (diff) | |
download | victor-743ec02a6980c4ee0fbd9f2cb5f23b568dc6d706.tar.gz |
Check site params only books
Diffstat (limited to 'layouts/partials/toc.html')
-rw-r--r-- | layouts/partials/toc.html | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/layouts/partials/toc.html b/layouts/partials/toc.html index 3b5a822..607e7f0 100644 --- a/layouts/partials/toc.html +++ b/layouts/partials/toc.html @@ -1,5 +1,4 @@ -{{ $chapters := .content.Page.Pages }} -{{ $currentLink := .currentLink}} +{{ $chapters := .Page.Pages }} {{ range .Page.Translations }} {{ $chapters = $chapters | lang.Merge .Pages }} {{ end}} @@ -10,14 +9,10 @@ {{ with .Params.chapterName }} {{ $fullTitle = printf "%s – %s" $fullTitle . }} {{ end }} - {{ if eq $currentLink .RelPermalink }} - <a aria-current="page">{{ trim $fullTitle " " }}</a> ({{ i18n "current"}}) - {{ else }} - <a href="{{ .RelPermalink }}">{{ trim $fullTitle " " }}</a> - {{ end }} + <a href="{{ .RelPermalink }}">{{ trim $fullTitle " " }}</a> {{ partial "post-info.html" . }} {{ if .IsSection}} - {{ partial "toc.html" (dict "content" . "currentLink" $currentLink) }} + {{ partial "toc.html" . }} {{ end }} </li> {{ end }} |