melt-ui: Tooltip doesn't work on iPhone
Describe the bug
@TGlide, hi!
It seems like the tooltip doesn’t work on iPhone even on the melt-ui website.
Reproduction
It’s reproducible even on the melt-ui website — https://melt-ui.com/docs/builders/tooltip.
https://github.com/melt-ui/melt-ui/assets/55146773/e6744ec6-b1e6-4f47-bfba-dc148956d33a
Logs
No response
System Info
System:
OS: macOS 14.2.1
CPU: (8) arm64 Apple M1 Pro
Memory: 950.44 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.3.0 - ~/.nvm/versions/node/v20.3.0/bin/node
Yarn: 1.22.19 - ~/.nvm/versions/node/v20.3.0/bin/yarn
npm: 9.6.7 - ~/.nvm/versions/node/v20.3.0/bin/npm
bun: 1.0.7 - ~/.bun/bin/bun
Browsers:
Chrome: 120.0.6099.234
Safari: 17.2.1
npmPackages:
@melt-ui/svelte: ^0.70.0 => 0.70.0
@sveltejs/kit: ^1.20.4 => 1.30.3
svelte: ^4.0.5 => 4.2.8
Severity
annoyance
About this issue
- Original URL
- State: open
- Created 5 months ago
- Comments: 22 (11 by maintainers)
Nothing super laid out. You’ll find most of our plans here in issues, discussions, and sometimes in the Discord. RN the focus is getting 1.0 up and running. That means a focus on stability, fixes, testing, docs, etc.
Tooltip is not intended for this.
Sorry, but that’s not relevant. Melt’s documentation is the important bit here.
Of course it’s not because of the name. They have different behaviours, accessibility concerns, etc. E.g. a popover can have interactible content inside it, a tooltip cannot.
No such thing, it’s just more suitable in certain situations.
Obvious to whom? Will screen readers say that you should long press it? Is there a consensus to have tooltips on any button? You need to hover a button before clicking it, so a tooltip naturally appearing is a nice bonus. And tooltips generally work this way.
Long pressing does not necessarily bring tooltips in other places. It’s not a standard in any shape or form.
Being a UI library, the choices we make greatly impact the web, specially as it grows. We can’t be careless and assume, things need to be done with a lot of thought, evidence, and study.
I tried using
Popover
on mobile andTooltip
on desktop. It 100% works but adds so much complexity to the code, affecting DX.I’m not that into accessibility and don’t know a lot of nuances, but from the info you provided, it’s clear that tooltips should work on touch devices.
I don’t see any contradictions between the above statement and a functional tooltip on mobile. The content is non-essential anyway. It doesn’t matter whether you’re on a touch device or a desktop/laptop.
But maybe it’s only my naive opinion.