🐛 Fixed the menu entries to be displayed correctly in secondary menu.

This commit is contained in:
elkan1788
2025-01-30 17:55:50 +08:00
parent 7a307a72a0
commit a6991680b8
2 changed files with 30 additions and 28 deletions

View File

@@ -15,9 +15,9 @@
{{ if .HasChildren }}
<ul class="menu-children">
{{ range .Children }}
{{ $active = or ($curP.IsMenuCurrent .Menu .) ($curP.HasMenuCurrent .Menu .) }}
{{ $active = $curP.IsMenuCurrent .Menu . }}
<li class="menu-child-item">
<a href="{{ .PageRef | relLangURL }}" class="hvr-icon-pulse {{if $active }}menu-item-active{{ end }}" rel="section">
<a href="{{ .URL | relLangURL }}" class="hvr-icon-pulse {{if $active }}menu-item-active{{ end }}" rel="section">
<i class="fa hvr-icon"></i>{{ .Name }}
</a>
</li>