Module popup

Source
Expand description

Provider-neutral popup registry, ownership, and dismissal intents. Provider-neutral popup ownership and lifecycle.

PopupPortal is the runtime authority for popup identity, ordering, and dismissal. It intentionally does not choose an overlay or native-window backend: hosts consume PopupIntent values and obtain popup content from the portal. This keeps widget APIs independent from a particular windowing provider.

Structs§

ElementTreeId
Stable identity of one retained element tree.
PopupBackendCapabilities
Popup presentation capabilities reported by a host adapter.
PopupBackendResolution
Observable backend selection, including a native-to-overlay fallback.
PopupContent
Retained factory used to remount popup content in either an overlay tree or a native presentation.
PopupId
Stable identity of one popup registration.
PopupOwner
Complete identity of the element that owns a popup.
PopupPlacementInput
Complete provider-neutral input to popup placement resolution.
PopupPlacementSpec
Provider-neutral placement requested before a host viewport is known.
PopupPortal
UI-local popup registry and z-order authority.
PopupPortalOutcome
Result of routing one popup lifecycle or input operation.
PopupRequest
Registration contract for one popup.
PopupSemantics
Provider-neutral interaction and accessibility contract for a popup.
ResolvedPopupPlacement
Deterministic result of backend and popup geometry resolution.

Enums§

PopupAlignment
Cross-axis alignment of a popup relative to its anchor.
PopupBackend
Presentation backend requested or selected for a popup.
PopupDismissReason
Reason recorded when the portal asks a backend to hide a popup.
PopupFocusPolicy
Focus behavior requested when the popup becomes visible.
PopupIntent
Host-independent side effect emitted by PopupPortal.
PopupMountPolicy
Rendering ownership selected for one popup registration.
PopupPlacement
Preferred vertical side of an anchored popup.
PopupPlacementError
Invalid geometry supplied to popup placement resolution.
PopupPortalError
Invalid popup registry operation.
PopupRole
Semantic role exposed by a popup independently from its presentation.

Constants§

HEADLESS_POPUP_WINDOW_ID
Logical presentation used by direct/headless event routing.

Functions§

clamp_popup_to_viewport
Clamps popup bounds to a viewport without tracking a requested side.
position_popup
Positions a popup relative to an anchor without viewport flip or clamp.
resolve_popup_placement
Resolves popup side, alignment, flip, viewport clamp, and backend fallback.