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

fix: Unable to delete a list item #95

Closed
wants to merge 1 commit into from

Conversation

alex-reinfoce
Copy link

#90

@donnfelker
Copy link

This only deletes ordered list items unfortunately, it does not work when you change the list type to unordered.

donnfelker added a commit to donnfelker/list that referenced this pull request Apr 14, 2024
The backspace update from editor-js#95 worked, but the event listeners
are lost when the toggleTune is invoked. This
PR adds the listeners back after the tune is invoked.

The listeners are lost because replaceWith does not
propogate the existing listeners to the new element.
@donnfelker
Copy link

I just added a PR that includes your fix as well as the re-attachment of listeners.

@donnfelker
Copy link

I've added an example of how to patch it in #90

@alex-reinfoce
Copy link
Author

I've added an example of how to patch it in #90

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants