Components
Popover
Floating content next to a trigger, for example a small form. Non-modal: focus moves in, but nothing is trapped.
Client componentUses state or handlers, so it starts with "use client".
import { Popover, PopoverTrigger, PopoverContent } from "@glob-ui/popover"Preview
API
Props are generated from the TypeScript types in the package source.
Popover
Prop
Type
PopoverTrigger
Prop
Type
PopoverContent
Prop
Type
Accessibility
| Key or action | Behaviour |
|---|---|
| Enter, Space on the trigger | Opens the popover and moves focus to its first focusable element. |
| Click the trigger again | Closes it. It does not reopen. |
| Escape | Closes it and returns focus to the trigger. |
| Click outside | Closes it (light dismiss). |
ARIA. The trigger has aria-haspopup="dialog" and aria-expanded. The content is role="dialog", named by its trigger unless you pass aria-label or aria-labelledby.
Dialog
A modal dialog on the native `<dialog>` element. Focus moves in, Escape closes it, and focus returns to the trigger. Build your own modal on the same behaviour with `DialogContentBase`.
Tooltip
A short description that appears on hover or keyboard focus. It stays open while the pointer is over it.