-
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
Inserter: Fix unresponsive Browse All Button on Quick Inserter for Mobile Screens. #67339
base: trunk
Are you sure you want to change the base?
Inserter: Fix unresponsive Browse All Button on Quick Inserter for Mobile Screens. #67339
Conversation
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If 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. |
What if you adjust the z-index so that the in-between inserter's popover is under the "all blocks" modal? |
Thank you for the review, @ellatrix! It seems that the approach with |
Maybe we should always close Quick Inserter via the "Browse All" button when Global (Inserter) is engaged. If I remember correctly, the focus also moves to the latter; not sure what's the point of keeping another popup open. Cc @jeryj, this might overlap with one of the bugs you're working on. |
packages/block-editor/src/components/inserter/quick-inserter.js
Outdated
Show resolved
Hide resolved
@yogeshbhutkar, let's see what others think about the suggestion above - #67339 (comment). |
Fixes: #67338
What?
This PR resolves a bug that causes the
Browse All
button in theQuick Inserter
to become unresponsive when clicked on mobile devices. The issue occurs because theQuick Inserter
opens in a full-screen dialog on mobile, obscuring thesidebar Inserter
. With this fix, clickingBrowse All
on mobile will close theQuick Inserter
and seamlessly open thesidebar Inserter
.How?
A new prop has now been added to the
<QuickInserter />
component calledcloseQuickInserter
which is used to close theDialog/Dropdown
exclusively on mobile devices when clicked. It precedes the old logic to open theInserter
via click event onBrowse All
.Testing Instructions
Screenshots or screencast
Screen.Recording.2024-11-27.at.2.49.16.PM.mov