ueberdosis / tiptap

The headless rich text editor framework for web artisans.
https://tiptap.dev
MIT License
27.13k stars 2.26k forks source link

[Bug]: Deleting at end of bullet list causes a new bullet point to spawn #5137

Open EricHasegawa opened 5 months ago

EricHasegawa commented 5 months ago

Affected Packages

StarterKit, BulletList, ListItem

Version(s)

latest

Bug Description

Create a bullet list as normal, enter the first bullet point. Press enter -> new empty listItem spawns below. Press enter, second listItem is deleted, cursor goes to start of line, press delete -> second bullet point comes back,

Reproduction can be seen here

Browser Used

Chrome

Code Example URL

https://tiptap.dev/docs/editor/examples/default

Expected Behavior

I would expect pressing delete returns my cursor to the first listItem, rather than creating a new listItem; intuitively, its quite odd that pressing delete actually creates the new bullet point

Additional Context (Optional)

Video of a reproduction with context is here

Dependency Updates

levonbrunson commented 5 months ago

I resolved this by adding ListKeymap to the extensions, not sure why it fixes the issue.

Edit: Someone found a solution in the PR at the end of the thread in this issue -> https://github.com/ueberdosis/tiptap/issues/4395

Nantris commented 5 months ago

To the TipTap team: The "default editor" should probably include the ListKeymap extension, no? More broadly, this seems like a recurring point of confusion which, if clarified, could reduce the issue count and load on the maintainers.

Nantris commented 3 months ago

I think this is close-able, but the docs should be updated somehow.