Replies: 1 comment 1 reply
|
Your navigation structure is fine. Two separate things are stopping the styles from landing, and the first one is why it looks like the component "loses track" of the parent. 1.
|
|
Your navigation structure is fine. Two separate things are stopping the styles from landing, and the first one is why it looks like the component "loses track" of the parent. 1.
|
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi everyone!
I tried my best for about a day and couldnt figure out how to get the solution I wanted. I saw the perfect example how I want to make it work in the Nuxt UI Templates. The dashboard-template Sidebar when collapsed shows the parent as active, even when popover is active. When I activate popover on my UNavigationMenu, it looses to keep track of the active parent and shows different CSS Styles.
I'm using UNavigationMenu inside a sidebar (UDashboardSidebar) with custom styling provided via the :ui prop.
I have nested items with children (e.g. Settings -> Staff, Billing, etc.). When a child menu item is selected/active, the child correctly receives active state styling (data-active), but the parent menu trigger item retains its default inactive styles.
Here is an snippet of my navigation structure and setup:
And my NavigationMenu
Go easy on me, please. I am no CSS neither a Nuxt UI crack, gave my best but maybe the ui stylings are a bit messy.
Hope someone can help me out with that.
Thanks in advance everbody!
Best!
All reactions