Tooltips on actionable controls - problems with links and in general touch devices
See original GitHub issueCurrently, tooltips have a series of issues:
- if added to a link, it seems that the tooltip swallows any further attempt to actually trigger the link (even when using a mouse or keyboard)
- using a touchscreen, conceptually the tooltip is triggered when the trigger element receives focus; however, if on an interactive element like a button (and link, but that’s currently broken in all cases as per the above point), tapping the trigger will already trigger whatever action is associated with it (taking the buttons with tooltips as example, tapping a button will trigger whatever the click behavior associated with it is, and only then show the tooltip)
Ideally, the way tooltips on interactive controls should work:
- for mouse/keyboard, show the tooltips on focus/hover but then do not prevent the default action (not dug into the code, but likely a
preventDefault
somewhere is the culprit) - for touchscreen/stylus interactions, keep track of whether or not the tooltip is visible; if not, on first tap/focus show tooltip then
preventDefault
. if tooltip IS visible, don’tpreventDefault
and allow the control to just carry out its normal function (and possibly close the tooltip). this way interactive controls with tooltip get a “two-step” process: first tap to show tooltip, second tap to actually trigger their functionality
Issue Analytics
- State:
- Created 6 years ago
- Reactions:6
- Comments:7 (4 by maintainers)
Top Results From Across the Web
Tooltips in the era of touch - Stack Overflow
Show activity on this post. Tooltips are an incredibly useful interface paradigm to know an application. They are the mapping between the visual...
Read more >Tooltips in the time of WCAG 2.1 | Sarah Higley
Unfortunately, one of the major drawbacks to tooltips is that they are inaccessible to touch devices when attached to buttons or links. This...
Read more >The problem with tooltips and what to do instead - Adam Silver
Tooltips are not only hard to use, but they're normally totally unnecessary. Learn why that is and what you could do instead.
Read more >Alternatives to tooltips in tablets? - UX Stack Exchange
Besides the mouse-over problem, your design has other potential problems on touch, like controls that will be too small to use.
Read more >Tooltip Guidelines - Nielsen Norman Group
Because tooltips are initiated by a hover gesture, they can be used only on devices with a mouse or keyboard. They are not...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
ah, thanks for checking. you’re right, some changes to the code since i filed this must have addressed this. good catch.
I’ve created this codepen, and I seem to be able to click the link and it navigates. Is there something I’m missing in this example?
https://codepen.io/tyricec/pen/VrpBGx