Skip to content
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

List block: when removing an empty list item, should not merge two list items #12398

Closed
v18 opened this issue Nov 28, 2018 · 5 comments
Closed
Assignees
Labels
[Block] List Affects the List Block [Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Type] Bug An existing feature does not function as intended

Comments

@v18
Copy link

v18 commented Nov 28, 2018

Describe the bug
When I press the 'delete' key on an empty list item, the item below the empty one gets merged with the one above.

A gif demo:

remove-empty-list-item

To Reproduce
Steps to reproduce the behavior:

  1. Make a new list gutenberg block
  2. Add some items
  3. Make one of the items empty (no text, but still with a number / bullet)
  4. Put cursor at the empty list item
  5. Press 'delete' on your keyboard
  6. See the two items around the empty list item merged

Expected behavior

Starting from this list:

list-before-delete

1. Apples
2. Oranges
3. 
4. Limes
5. Lemons

I expected to see this after pressing 'delete' on item 3:

list-after-delete

1. Apples
2. Oranges
4. Limes
5. Lemons
@designsimply designsimply added the Needs Testing Needs further testing to be confirmed. label Nov 28, 2018
@designsimply
Copy link
Member

Tested and confirmed that deleting an empty list item merges the list items before and after it using WordPress 4.9.8 and Gutenberg 4.5.1 master @ e4fd51cb5 using Firefox 63.0.3 on macOS 10.13.6.

@designsimply designsimply added [Type] Bug An existing feature does not function as intended [Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Block] List Affects the List Block and removed Needs Testing Needs further testing to be confirmed. labels Nov 28, 2018
@ellatrix
Copy link
Member

Thanks for the report!

@ellatrix ellatrix self-assigned this Nov 29, 2018
@ZebulanStanphill
Copy link
Member

I can confirm this is still happening in Gutenberg 4.6.1.

@youknowriad
Copy link
Contributor

I can't reproduce, I suppose it was fixed by #13697

@ellatrix
Copy link
Member

Thanks for testing. Yes, I think it was TinyMCE and RichText both acting at the same time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] List Affects the List Block [Feature] Writing Flow Block selection, navigation, splitting, merging, deletion... [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

5 participants