Skip to content

Conversation

scuml
Copy link
Contributor

@scuml scuml commented Nov 2, 2022

Move the creation on the mouseup event handler to inside the mousedown and add {once: true} so that is is removed after each use. This prevents multiple mouseup events from getting attached to document (which breaks mouseup behavior) when using libraries that update page content without reloading the page like Hotwire Turbo, htmx, and Unpoly.

@tim-schilling tim-schilling merged commit 8e3335a into django-commons:main Nov 2, 2022
@tim-schilling
Copy link
Member

Thanks for the PR and cleaning up my mess!

@scuml
Copy link
Contributor Author

scuml commented Nov 2, 2022

Thanks for the fast review @tim-schilling !

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