Hide empty subnavigations and their buttons in mobile view
This commit is contained in:
@@ -124,27 +124,31 @@
|
|||||||
title="{subitem.title}">
|
title="{subitem.title}">
|
||||||
{subitem.title}
|
{subitem.title}
|
||||||
</a>
|
</a>
|
||||||
<button type="button"
|
<f:if condition="{subitem.children}">
|
||||||
class="focus:outline-none"
|
<button type="button"
|
||||||
data-action="collapse#toggle">
|
class="focus:outline-none"
|
||||||
<svg class="h-6 w-6 transform text-white" data-collapse-target="icon">
|
data-action="collapse#toggle">
|
||||||
<use href="#icon-chevron-down"></use>
|
<svg class="h-6 w-6 transform text-white" data-collapse-target="icon">
|
||||||
</svg>
|
<use href="#icon-chevron-down"></use>
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
<div class="transform pt-2"
|
|
||||||
data-collapse-target="container">
|
|
||||||
<f:for each="{subitem.children}" as="subsubitem">
|
|
||||||
<a href="{subsubitem.link}"{f:if(condition: '{subsubitem.data.doktype} == 3', then: ' _target="blank"')}
|
|
||||||
class="flex items-center space-x-2 text-lg leading-loose text-white hover:text-white focus:text-white"
|
|
||||||
title="{subsubitem.title}">
|
|
||||||
<svg class="w-4 h-4 text-white">
|
|
||||||
<use href="#icon-chevron-right"></use>
|
|
||||||
</svg>
|
</svg>
|
||||||
<span>{subsubitem.title}</span>
|
</button>
|
||||||
</a>
|
</f:if>
|
||||||
</f:for>
|
|
||||||
</div>
|
</div>
|
||||||
|
<f:if condition="{subitem.children}">
|
||||||
|
<div class="transform pt-2"
|
||||||
|
data-collapse-target="container">
|
||||||
|
<f:for each="{subitem.children}" as="subsubitem">
|
||||||
|
<a href="{subsubitem.link}"{f:if(condition: '{subsubitem.data.doktype} == 3', then: ' _target="blank"')}
|
||||||
|
class="flex items-center space-x-2 text-lg leading-loose text-white hover:text-white focus:text-white"
|
||||||
|
title="{subsubitem.title}">
|
||||||
|
<svg class="w-4 h-4 text-white">
|
||||||
|
<use href="#icon-chevron-right"></use>
|
||||||
|
</svg>
|
||||||
|
<span>{subsubitem.title}</span>
|
||||||
|
</a>
|
||||||
|
</f:for>
|
||||||
|
</div>
|
||||||
|
</f:if>
|
||||||
</li>
|
</li>
|
||||||
</f:for>
|
</f:for>
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
Reference in New Issue
Block a user