mirror of
https://github.com/opnsense/core.git
synced 2026-10-12 02:20:36 +00:00
ui: sync expanded state for selected submenus
Noticed while reviewing https://github.com/opnsense/core/pull/10942 This will prevent two submenus being open at the same time regardless of depth, which seemed to happen particularly on second-level submenus. This will cause more shifting around, but this consistency is already applied on the first-level submenu. The alternative is to allow multiple second-level submenus open at the same time and only close when switching top-level sections.
This commit is contained in:
@@ -13,7 +13,8 @@
|
||||
{% if subMenuItem.Url == '' %}
|
||||
{# next level items, submenu is a container #}
|
||||
<a href="#{{ topMenuItem.Id }}_{{ subMenuItem.Id }}" class="{{ subMenuItem.LinkClass }}"
|
||||
data-toggle="collapse" data-parent="#{{ topMenuItem.Id }}">
|
||||
data-toggle="collapse" data-parent="#{{ topMenuItem.Id }}"
|
||||
aria-expanded="{% if subMenuItem.Selected %}true{% else %}false{% endif %}">
|
||||
<div style="display: table;width: 100%;">
|
||||
<div style="display: table-row">
|
||||
<div style="display: table-cell">{{ subMenuItem.VisibleName }}</div>
|
||||
|
||||
Reference in New Issue
Block a user