Simplify "active menu" logic for section menus

Fixes #8776
This commit is contained in:
Bjørn Erik Pedersen
2021-07-20 12:10:22 +02:00
parent 634481ba8c
commit d831d2fce8
7 changed files with 151 additions and 34 deletions

View File

@@ -24,4 +24,6 @@ aliases: []
returns `true` if the PAGE is the same object as the `.Page` in one of the
**children menu entries** under MENUENTRY in a given MENU.
{{< new-in "0.86.0" >}} If MENUENTRY's `.Page` is a [section](/content-management/sections/) then, from Hugo `0.86.0`, this method also returns true for any descendant of that section..
You can find its example use in [menu templates](/templates/menu-templates/).