1
0
Fork 0
forked from goffee/core

check child items to active nav

This commit is contained in:
Zeni Kim 2025-04-28 00:12:43 -05:00
parent 30746a0602
commit c9cb539d18

View file

@ -11,7 +11,7 @@
{{end}}
<li class="nav-item dropdown">
<a href="{{$item.Link}}" {{if eq .IsDisabled true}}disabled{{end}} data-bs-toggle="dropdown"
class="nav-link dropdown-toggle {{if eq .IsActive true or $hasActiveChild}}active{{end}} {{if eq .IsDisabled true}}disabled{{end}}">{{$item.Text}}</a>
class="nav-link dropdown-toggle {{if or $item.IsActive $hasActiveChild}}active{{end}} {{if eq .IsDisabled true}}disabled{{end}}">{{$item.Text}}</a>
<ul class="dropdown-menu">
{{ range $item.ChildItems}}
{{template "content_dropdown_item" .}}