-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add select-parent button to block toolbar "More options" menu. #40105
Add select-parent button to block toolbar "More options" menu. #40105
Conversation
Size Change: +242 B (0%) Total Size: 1.22 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ZebulanStanphill This is working well for me. One small label change that would make this perfect. Context is everything for screen reader users.
packages/block-editor/src/components/block-settings-menu/block-settings-dropdown.js
Outdated
Show resolved
Hide resolved
…-settings-dropdown.js Co-authored-by: Alex Stine <alex.stine@yourtechadvisors.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
What?
Split out and updated from the obsolete #23800, this PR adds a "Select parent" button to the block toolbar's ellipsis menu.
Why?
In a brief discussion at the end of #23800, it was suggested that a select-parent option in the block toolbar ellipsis menu might still be useful, even after the improvements to the one on the left of the block toolbar.
Specifically, the thin-viewport/mobile version of the UI does not show the standard select-parent button, so this ellipsis menu option can serve as a substitute in that context.
How?
This PR just adds a button to the block toolbar ellipsis menu that behaves pretty much identically to the one visible on the left of the standard desktop viewport block toolbar.
Testing Instructions
Notes
I've noticed that merely focusing the ellipsis menu option does not make the parent block outline show, which is different from the behavior of the icon-button on the left of the block toolbar. I can't find a reason for this, thought I suspect it has something to do with a quirk of how
useShowMoversGestures
works. (Speaking of which, that hook really needs a refactor, since even its name no longer makes sense after all the changes that have been made to the block toolbar since the hook's creation. I'll probably do that as a separate PR at some point.)Screenshot