Omnibar: add pressed state for the Help and Notifications buttons - #113305
Omnibar: add pressed state for the Help and Notifications buttons#113305fushar wants to merge 1 commit into
Conversation
Introduce an `isActive` flag on `OmnibarNode` and render leaf nodes with `is-active` plus `aria-pressed`, then wire the help center and notifications plugins to it. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
WordPress.com
Automattic for Agencies
|
|
Do we need pressed state? I checked WP Admin, and it didn't have it 🤔 |
|
Yes, but I think it's the hover state rather than the pressed state, since it looks the same when you hover over it. |
|
Interesting.... then how do you think we should move forward? I'm not sure if I can trigger hover state on the menu when we're inside the panel, without hacks 🥹 |
|
Opened #113332. What do you think? There is an edge case where hovering over a dropdown at the top of the panel (e.g., the Notifications shortcut) does not work. But I guess it's acceptable. |
Thanks, I checked that. It seems it just makes thing more complicated 🤔 the logic already knows that the panel is open (via |
|
It's just aligned with the existing logic on wp-admin 😂 |

Proposed Changes
Support pressed state in omnibar menu, and then apply it to notification and help center nodes.
Why are these changes being made?
We want to match React omnibar with PHP admin bar behavior.
Testing Instructions
Test with
dashboard/omnibar-radicalflag turned on.Click notification / help center; verify they are still in pressed state when the panels are still open.