Popover
Presents a native SwiftUI popover from a composed SwiftUI trigger.
#Import
Import Popover from @quickgui/solid/swift-ui.
import { Host, Popover } from "@quickgui/solid/swift-ui";#Usage
<Popover
isPresented={open()}
onIsPresentedChange={setOpen}
attachmentAnchor="bottom"
arrowEdge="top"
>
<Popover.Trigger render={<Button label="Open" />} />
<Popover.Content>
<QuickGUIHostView width={280} height={120}>
<SettingsPanel />
</QuickGUIHostView>
</Popover.Content>
</Popover>#Anatomy
Popover.TriggerPopover.Content
<Popover isPresented={open()} onIsPresentedChange={setOpen}>
<Popover.Trigger render={<Button label="Open" />} />
<Popover.Content>{/* SwiftUI-hosted content */}</Popover.Content>
</Popover>#API reference
Expand an entry for its description and complete signature. A dash means no declaration default is documented.
Popover
View sourcePopover(props: PopoverProps): NativeNodetestIDstring—
modifiersViewModifier[]—
childrenunknown—
Declares children (optional). Reactive JSX expressions update this property in place.
unknownView sourceisPresentedboolean—
onIsPresentedChange(isPresented: boolean) => void—
Declares onIsPresentedChange (optional). Reactive JSX expressions update this property in place.
(isPresented: boolean) => voidView sourceattachmentAnchorPopoverAttachmentAnchor—
Declares attachmentAnchor (optional). Reactive JSX expressions update this property in place.
PopoverAttachmentAnchorView sourcearrowEdgePopoverArrowEdge—
Declares arrowEdge (optional). Reactive JSX expressions update this property in place.
PopoverArrowEdgeView sourceref((node: NativeNode) => void) | NativeNode—
Declares ref (optional). Reactive JSX expressions update this property in place.
((node: NativeNode) => void) | NativeNodeView sourcePopover.Trigger
View sourcePopover.Trigger(props: PopoverTriggerProps): NativeNoderenderJSX.Element—
Native SwiftUI component used as the trigger. This follows Base UI's composition shape: Trigger supplies behavior and `render` replaces its default element. The rendered component's own press handler runs before Trigger's behavior.
JSX.ElementView sourceonPress(event: QuickGuiEvent) => void—
Called after the rendered component's own press handler and before the popover opens.
(event: QuickGuiEvent) => voidView sourceref(node: NativeNode) => void—
Receives the rendered trigger component rather than the internal structural slot.
(node: NativeNode) => voidView sourcePopover.Content
View sourcePopover.Content(props: PopoverContentProps): NativeNodechildrenunknown—
Declares children (optional). Reactive JSX expressions update this property in place.
unknownView sourceref((node: NativeNode) => void) | NativeNode—
Declares ref (optional). Reactive JSX expressions update this property in place.
((node: NativeNode) => void) | NativeNodeView source