Component
Popover
Non-modal content anchored to a trigger.
import { Popover } from '@loidolt/theme-svelte';
Example
Notes
- The default trigger wears the quiet button;
triggerVariant/triggerSizechange that, and an explicittriggerClasswins wholesale.
Props
Generated from the component source, so it cannot drift from the implementation.
| Prop | Type | Default | Notes |
|---|---|---|---|
children required | Snippet | — | |
align | Alignment | 'start' | |
class | string | — | class lands on the portaled Content element. |
onOpenChange | (open: boolean) => void | — | |
open bindable | boolean | false | |
ref bindable | HTMLElement | null | null | |
side | Placement | 'bottom' | |
sideOffset | number | 6 | |
trigger | Snippet | — | |
triggerChild | Snippet<[TriggerChildProps]> | — | Full control of the trigger element — receives the props Bits needs on it. |
triggerClass | string | — | |
triggerSize | ControlSize | — | |
triggerVariant | ActionVariant | — | Button variant for the default trigger (quiet unless set). An explicit triggerClass wins wholesale. |
Plus the attributes of Omit<PopoverContentProps, 'children' | 'class' | 'child'>, forwarded to the root element.