Skip to Content
glob.ui home
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 actionBehaviour
Enter, Space on the triggerOpens the popover and moves focus to its first focusable element.
Click the trigger againCloses it. It does not reopen.
EscapeCloses it and returns focus to the trigger.
Click outsideCloses 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.

On this page