File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2727 < div class ="collapse navbar-collapse " id ="navbarSupportedContent ">
2828 < ul class ="menu-main navbar-nav me-auto mb-2 mb-lg-0 ">
2929 {{- $current := . -}}
30- {{- $section := $current.Section -}}
30+ {{- $currentPath := strings.TrimSuffix "/" $current.RelPermalink -}}
3131 {{ range .Site.Menus.main -}}
3232 {{- $active := or ($current.IsMenuCurrent "main" .) ($current.HasMenuCurrent "main" .) -}}
33- {{- $active = or $active (eq .Name $current.LinkTitle) -}}
34- {{- $active = or $active (and (eq .Name ($section | humanize)) (eq $current.Section $section)) -}}
35- {{- $active = or $active (and (eq .Identifier ($section | humanize)) (eq $current.Section $section)) -}}
36- {{- $active = or $active (and (eq .Name "Blog") (eq $current.Section "blog" "contributors")) -}}
33+ {{- $menuPath := strings.TrimSuffix "/" (.URL | relLangURL) -}}
34+ {{- $active = or $active (eq $menuPath $currentPath) -}}
3735 {{ if .HasChildren }}
3836 < li class ="nav-item dropdown ">
3937 < a class ="nav-link dropdown-toggle " id ="navbarDropdown " role ="button " data-bs-toggle ="dropdown " aria-expanded ="false ">
You can’t perform that action at this time.
0 commit comments