theKashey / react-focus-on

🎯 Solution for WAI ARIA compatible modal dialogs or full-screen tasks, you were looking for
MIT License
336 stars 14 forks source link

Switch from click to mousedown (and touchend to touchstart) for click outside behaviour #21

Closed benoitgrelard closed 4 years ago

benoitgrelard commented 4 years ago

Closes #20

theKashey commented 4 years ago

Makes sense from a consistency point of view. However, I haven't found any "system" Modal I could close by clicking outside - usually they ignore it. However, "clicking" on a foreground window bring it to top on mouse down, not click.

benoitgrelard commented 4 years ago

Yeah exactly, it's less common in system dialogs to use click outside. Good point on foreground window being on mouse down rather than click too though, seems to be consistent with the rest as I found.

theKashey commented 4 years ago

Then let's move forward!

benoitgrelard commented 4 years ago

Awesome, let me know when you're able to release a new version with this change.

theKashey commented 4 years ago

Give me some time to check, as long as there is another unpublished, and yet untested change - #19

benoitgrelard commented 4 years ago

No worries!