zioth / dokuwiki-autotooltip

DokuWiki plugin to add styled tooltip functionality, and to automatically generate link tooltips based on page abstracts.
MIT License
5 stars 4 forks source link

Can’t close tooltip on mobile / touchscreen #8

Closed gudnimg closed 4 years ago

gudnimg commented 5 years ago

Probably not an issue but is it possible to add an event or function to detect if the user clicks/touches somewhere else on the screen in order to close the tooltip?

Right now if you trigger the tooltip the only way to get rid of it is to refresh the page.

zioth commented 4 years ago

Sorry for the year-long delay! I just tried this on mobile (Android/Chrome), and the tooltip closes when I touch somewhere outside of it. Do you remember what browser/device you were using?

gudnimg commented 4 years ago

No problem, better late than never! :)

Huh I just tried it again on my phone. I used Safari on iOS last year, and it seems to work now like you described. Guess I can now use this everywhere on my wiki :D

I tried Chrome as well on iOS, that works too!

zioth commented 4 years ago

Great! I like closing issues without having to do anything! :)

zioth commented 4 years ago

Of course, tooltips on mobile are an issue mobile apps have been dealing with since the beginning. There's really no intuitive way to show a tooltip, and since space is so limited, you're often left with a row of obscure icons with no explanation. My favorite example is in WhatsApp: There's a a curved-left arrow next to a curved-right arrow. One quotes, while the other shares. Completely different behavior for nearly identical icons, with no explanation.

One solution is to add question mark icons next to tooltip-aware context, and you tap the question mark to get a tooltip, instead of the context item itself. However, that doesn't work for a wiki. You don't want your page filled up with question marks.