Repository navigation
[WP 7.2] UI: Show keyboard focus on disabled menu items - #85765
Conversation
* Menu: Show focus on disabled UI items * Fix UI disabled menu focus changelog reference * Menu: Use highlighted state for disabled item focus rings --- Co-authored-by: ciampo <mciampini@git.wordpress.org> Co-authored-by: mirka <0mirka00@git.wordpress.org>
🤖 PR meta 🤖🎉 PropsIf you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. Updated as activity occurs, without notifying anyone named here. Add the 📦 Bundle sizeSize Change: -18 B (0%) Total Size: 9.04 MB 📦 View Changed
⚡ PerformanceShow the resultsClient side metrics exclude the server response time. front-end-block-theme
front-end-classic-theme
media-processing
media-upload
post-editor
site-editor
🏁 Flaky testsSome tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information. As a user I expect my navigation to use the colors I selected for it in
|
|
Whoever reviews this PR, feel free to merge it too if approved. I may not be super available over the next few days. |
Manual backport of #85488 to
wp/7.2.What?
Show a focus ring on disabled Menu items reached with the keyboard.
Why?
The automatic cherry-pick failed because the release branch's changelog differs from trunk.
How?
Apply the CSS from
21d4f363fded2df864ec520449b7c65e3fcbc21funchanged. Resolve only the changelog conflict by adding the Menu entry underUnreleased→Bug Fixes, without bringing over unrelated trunk entries.Testing Instructions
Testing Instructions for Keyboard
All steps above use the keyboard. Arrow keys should move focus between items, and Escape should return focus to the trigger.
Local verification
The production build, all 60 existing Menu tests, CSS lint, and changelog validation passed. Storybook checks confirmed the focus ring, blocked disabled activation, and focus return in Default, plus the ring in Rich Items with the dark theme and WordPress global CSS. The CSS additions exactly match the original commit.
Screenshots or screencast
See the before/after previews in #85488.
Use of AI Tools
Codex applied the cherry-pick, resolved the changelog conflict, ran verification, and drafted this description.