ten1seven / what-input

A global utility for tracking the current input method (mouse/pointer, keyboard or touch).
https://ten1seven.github.io/what-input
MIT License
1.35k stars 89 forks source link

Mouse intent when long-tapping in Firefox for Android #94

Open lorenzos opened 5 years ago

lorenzos commented 5 years ago

A somewhat minor issue, but on Firefox for Android [data-whatintent="mouse"] is set for a very short time when long-tapping anything (like, for text selection or to fire the browser's contextual menu). It may be that Firefox for Android fires a mouse-related event on long-taps to "emulate" right clicks?

I noticed it on an element that has a :hover tooltip that I wanted to remove on mobile: I hide the tooltip in CSS and I use [data-whatintent="mouse"] to re-display it. It worked, and the tooltip is gone on normal taps; but I noticed it came back for a moment when long-tapping.

I don't know if it can be fixed or if it's worth it, but thanks anyway.

ten1seven commented 5 years ago

Hi @lorenzos, thanks for reporting this. I'll give it a look.