diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 198f9a91d7..a1c86e35f0 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -60,14 +60,14 @@ {{ end }} {{ define "rightsidebar_content" }} - {{/* in-this-section.html depends on these being reneredc first. */}} - {{ $related := partial "layouts/related.html" . }} - {{ $toc := partial "layouts/toc.html" . }} - {{ if not .Params.hide_in_this_section }} - {{ partial "layouts/in-this-section.html" . }} - {{ end }} - {{ $related }} - {{ if $.Store.Get "hasToc" }} - {{ $toc }} - {{ end }} +
+ {{ $toc := partial "layouts/toc.html" . }} + {{ if $.Store.Get "hasToc" }} + {{ $toc }} + {{ end }} + {{ if not .Params.hide_in_this_section }} + {{ partial "layouts/in-this-section.html" . }} + {{ end }} + {{ partial "layouts/related.html" . }} +
{{ end }} diff --git a/layouts/partials/layouts/in-this-section.html b/layouts/partials/layouts/in-this-section.html index 28e5ed7ebf..48d6510c13 100644 --- a/layouts/partials/layouts/in-this-section.html +++ b/layouts/partials/layouts/in-this-section.html @@ -1,11 +1,6 @@ {{- with .CurrentSection.RegularPages }} - {{ $hasTocOrRelated := or ($.Store.Get "hasToc") ($.Store.Get "hasRelated") }}

diff --git a/layouts/partials/layouts/related.html b/layouts/partials/layouts/related.html index dc0de68701..54d38212cb 100644 --- a/layouts/partials/layouts/related.html +++ b/layouts/partials/layouts/related.html @@ -18,9 +18,8 @@ {{/* Avoid repeating pages that's listed in In this section. */}} {{- $related = $related | complement .CurrentSection.RegularPages | first 7 }} {{- with $related }} - {{ $.Store.Set "hasRelated" true }}

+ class="text-base font-semibold tracking-tight text-gray-600 dark:text-gray-400 mt-8"> {{ $heading }}