-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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 browse all shows non-allowed blocks in InnerBlocks #64998
Comments
It's definitely buggy, but I can't reproduce the exact same thing as what was reported. For me, as soon as I click 'Browse All' it seems to lose track of where the block should be inserted and instead shows blocks that can be inserted after the container instead of within the container block. It also inserts them after instead of within. Then when I try to select an inner block with the inserter open, the inserter itself glitches. The differences I'm seeing might be because I'm testing Here's a screencap showing that (I changed the buttons block so that it also allows a paragraph and removed Kapture.2024-09-03.at.11.56.13.mp4 |
Hmm now that I try again it actually doesn't insert non-allowed blocks, but they still show up in the inserter. Must've been some change I made while testing that allowed that. Using the test-block from the repo I linked, it won't actually insert non-allowed blocks at all, but I see the highlight appear after the block as opposed to inside it (which is what happens when I select an allowed block). |
Yes, there was a change in 6.6 around that, I should've mentioned it. |
Inserter change was introduced in #62169. |
@Mamaduka Does that mean this will be fixed with that PR or is this a consequence of that PR? Because I see no "list of blocks that can be inserted" as the PR says. Edit: Oh I see, it's stuff above the thin grey border that's insertable at selection. That is not clear at all. I had to look at the class names in the inspector to figure that out. Is it possible to add a headline or something to make this clearer? |
@WordPress/gutenberg-design I know we had considered an "Allowed blocks" heading or putting the title of the block in there, like "List Block" instead of repeating the design section. What do you think? |
I think this is a regression caused by #64048. The A group block for reproduction
<!-- wp:group {"allowedBlocks":["core/paragraph","core/image"],"layout":{"type":"flex","orientation":"vertical"}} -->
<div class="wp-block-group"></div>
<!-- /wp:group --> Screencast with 64048 reverted.CleanShot.2024-09-05.at.09.36.01.mp4 |
There are options, always, but at the moment I'd not add any changes to the UI until we've more solidly fixed the bugs at play. There seems to be something off with trunk at the moment, to echo George above. |
Description
What works:
What doesn't work correctly:
Selecting one block here inserts it into inner blocks area even though it's not allowed.Hover over one block here displays the highlight outside the parent block.Expected:
Step-by-step reproduction instructions
Screenshots, screen recording, code snippet
Repo with example plugin: https://github.com/traed/inner-blocks-bug
Environment info
Please confirm that you have searched existing issues in the repo.
Please confirm that you have tested with all plugins deactivated except Gutenberg.
The text was updated successfully, but these errors were encountered: