fix mobile menu links without sub-items (#1043)

This commit is contained in:
trean
2024-07-22 16:51:45 +02:00
committed by GitHub
parent 973e14f847
commit 692885b637
@@ -8,7 +8,14 @@
{{ range .Params.menuItems }}
<li class="menu-mobile__item" data-path="{{ .id }}">
<div class="menu-mobile__item-content">
{{ .name }}
{{ if and (not .subMenuItems) .url }}
<a href="{{ .url }}">
{{ .name }}
</a>
{{ else }}
{{ .name }}
{{ end }}
{{ if .subMenuItems }}
<button type="button" class="menu-mobile__expand">{{ partial "svg" "arrow-sm-down.svg" }}</button>
{{ end }}