Overlays
v1.0.0Added in 1.0.0
A rich preview of a person, listing or link that floats in on hover or focus, and opens as a bottom sheet with a tap on touch screens.
Rest the pointer on a link or a name and after half a second the preview grows out of it on a quick spring. Move onto the card and it stays open, so its buttons and links work; leave both and it fades out 200ms later. Tab to the trigger and it opens the same way; Escape or moving focus on closes it. The card is a supplement: its content is skipped by Tab and every action in it is reachable elsewhere. On phones and tablets there is no hover, so the first tap opens the preview as a bottom sheet instead of following the link: drag it down, tap the dim page or press Escape to close it, and the sheet's own link leads on. With reduced motion it only fades.
npx wingo-ui@latest add hover-cardPro item: the CLI needs a Pro account. See plans
Daniel Reed2 h ago
@emma.carter is the bike still available? I could come by tomorrow afternoon to see it.
Emma CarterSeller1 h ago
Yes, it is. I am around after 5 PM, in the Pearl District.
Sophia Lee20 min ago
I bought a table from @emma.carter last month. Everything was exactly as pictured.
Hover @emma.carter or a name, then move onto the card: it stays open. Tab to a link and it opens too.
openDelay 500ms · closeDelay 200ms · sheet on touch · sheetTitle "Preview"