tagify icon indicating copy to clipboard operation
tagify copied to clipboard

Change 'click' event into 'mousedown'

Open Massi-X opened this issue 1 year ago • 4 comments

This prevents the dropdown from closing when the user starts a selection (mousedown) within the input and ends it (mouseup) outside of the input

Massi-X avatar Nov 18 '24 23:11 Massi-X

selection of what? what are the steps to reproduce? a video would be nice :)

yairEO avatar Nov 23 '24 12:11 yairEO

Hi @yairEO I can't trigger the bug with unpatched 4.32.1 version, so this could be related to some of my commits in #1410. You could wait to review that but in any case I found this fixes another incorrect behavior (at least to me) that is the border focus style being lost when the selection ends outside the input, see video (for clarity I click the mouse inside the input, drag to select and release it outside of the input borders)

https://github.com/user-attachments/assets/345c086f-22c3-4c69-96e4-23bcfa78fb17

Massi-X avatar Nov 24 '24 11:11 Massi-X

Also need to test how this affects mobile users where the click event was translated into a touch event

yairEO avatar Nov 25 '24 05:11 yairEO

Yep

PS. It should be fine https://caniuse.com/?search=mousedown

Massi-X avatar Nov 25 '24 07:11 Massi-X