feat: add a Mein Account group to the main menu and lock the page while the drawer is open
This commit is contained in:
1 parent
4530d2434b
commit
8a02b28d00
6 files changed
+164
-24
No files matched your search
@@ -1,6 +1,7 @@
|
||||
{#
|
||||
The account menu behind the user's picture: own profile, the other areas (MenuBuilder::createUserMenu)
|
||||
and logout. Opens on click, closes on a click elsewhere and on Escape.
|
||||
The account menu behind the user's picture: own profile, the other areas and logout
|
||||
(MenuBuilder::createUserMenu). Opens on click, closes on a click elsewhere and on Escape. Only from lg
|
||||
up; below that the same items are reached through the main menu in the drawer.
|
||||
#}
|
||||
{% set user_menu = knp_menu_get('default_user') %}
|
||||
<div class="relative"
|
||||
@@ -22,11 +23,6 @@
|
||||
<div class="hidden absolute right-0 top-full mt-2 z-40 min-w-56 border border-line bg-white py-1 text-sm shadow-lg"
|
||||
role="menu"
|
||||
{{ stimulus_target('toggle', 'toggle') }}>
|
||||
{% if app.user.teamer %}
|
||||
<a href="{{ path('app_teamer_profile_index') }}" class="menu-item flex items-center gap-x-3" role="menuitem">{{ icon('user', 'w-5 h-5 text-muted') }}Mein Profil</a>
|
||||
{% elseif is_granted('ROLE_ADMINISTRATIVE') %}
|
||||
<a href="{{ path('app_administrative_profile_index') }}" class="menu-item flex items-center gap-x-3" role="menuitem">{{ icon('user', 'w-5 h-5 text-muted') }}Mein Profil</a>
|
||||
{% endif %}
|
||||
{% for item in user_menu.children %}
|
||||
{% if loop.last %}<hr class="my-1 border-line">{% endif %}
|
||||
<a href="{{ item.uri }}" class="menu-item flex items-center gap-x-3" role="menuitem">{{ icon(item.extras.icon, 'w-5 h-5 text-muted') }}{{ item.label }}</a>
|
||||
|
||||
Reference in new issue
Block a user