- {% include "partials/settings_dropdown.html" %}
-
+
+ {% include "partials/settings_dropdown.html" %}
diff --git a/assets/views/partials/profile_menu.html b/assets/views/partials/profile_menu.html
index bdf2833..a419895 100644
--- a/assets/views/partials/profile_menu.html
+++ b/assets/views/partials/profile_menu.html
@@ -1,17 +1,16 @@
{# Customer profile dropdown in the storefront navbar.
- Penguin UI markup (navbar/with-user-profile.html dropdown + avatar rendered as
- avatar-with-initials.html, primary variant, since we have no photo), but with
- the same minimal core-Alpine toggle as settings_dropdown.html — plain
- open / @click.outside, NOT Penguin's x-trap / $focus keyboard nav (that needs
- the Alpine Focus plugin we don't rely on). Self-contained Alpine state.
+ Proper Penguin UI dropdown: behaviour is the vendored
+ dropdowns/dropdown-with-icons.html verbatim (isOpen / openedWithKeyboard,
+ x-trap + $focus keyboard nav, x-cloak x-show, @click.outside). Trigger is the
+ round initials avatar (avatar-with-initials.html, primary variant). Menu items
+ are our account links.
- IMPORTANT: the dropdown
needs an inline style="display: none" in addition
- to x-cloak. Because it has id="userMenu", htmx hx-boost "settles" it by id
- across boosted navigations, and that interferes with Alpine re-applying x-show,
- leaving the menu visible (open=false) after navigating. The inline display:none
- keeps it hidden until x-show explicitly opens it. (settings_dropdown has no id,
- so it is not settled and does not need this.) #}
+ Needs the Alpine Focus plugin (loaded before Alpine core in base.html) for
+ x-trap / $focus. Self-contained Alpine state; the host only needs to place it
+ in the navbar flex row. The panel has NO id on purpose — an id would make htmx
+ hx-boost "settle" it across boosted navigations and reappear; id-less Penguin
+ dropdowns are unaffected. #}
{# initials from the full name, e.g. "Filip Priec" -> "FP" #}
{% set _name = customer_name | default(value='') | trim %}
@@ -22,34 +21,53 @@
{% set _person_icon = '' %}
-