Popover | PopoverAnchor
PopoverAnchor#
Description#
- Component that defines the element the popover is positioned against. Useful when the anchor is not the trigger: for example, when the popover opens from a context menu but must hang from another element. Without an anchor, the popover positions against the trigger.
Props#
asChild(boolean) — Iftrue, does not wrap in adivand applies attributes to the only child. Default:false.
Usage#
| |
Notes#
- On unmount, the anchor is automatically cleared from the context.
- The anchor takes precedence over the trigger when calculating the popover position.