-
Notifications
You must be signed in to change notification settings - Fork 56
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
Trash icon should remove the whole block, not just delete the contents #449
Comments
I've been investigating this a bit further. This is the behavior on Gutenberg Web: What happens when the last block is removed, is that an instance of the paragraph block remains there, in the same way that happens in the mobile version. The difference is that the paragraph block on web has a placeholder that has the same text than the initial
@iamthomasbishop what do you think about the first option? Is your expectation based on the web behavior or are you actually thinking on a custom mobile behavior? |
I think I'd expect the keyboard to dismiss |
I think there are some issues with the web behaviour, which I only noticed from your GIF 😁 When you delete the last block, you get the paragraph with a placeholder, but the placeholder isn't visible if the block is focused. This block can't normally be deleted because the empty paragraph doesn't show the toolbar until you start typing. However, if you enable the top toolbar the block/formatting controls are still there, so yo can repeatedly remove that block and it looks like nothing happened (even the menu stays open). I think adding the placeholder is still valuable, but as I mentioned to Thomas last week, we also don't want to copy this 😁 |
I think we should move towards adding the full default block appender instead of the empty paragraph. Deleting the (single/only) block should dismiss the keyboard, plus add the default block appender. |
Tested again and this is now solved. |
Reported by @iamthomasbishop
The issue happens when there is just one block in the canvas. When it is deleted with the trash icon, it will be replaced with an empty default (Paragraph) block block.
Expected behavior:
When:
Expect:
The text was updated successfully, but these errors were encountered: