import type { Snippet } from "svelte"; import type { EscapeLayerImplProps, EscapeLayerProps } from "../escape-layer/types.js"; import type { DismissibleLayerImplProps, DismissibleLayerProps } from "../dismissible-layer/types.js"; import type { FloatingLayerContentImplProps, FloatingLayerContentProps } from "../floating-layer/types.js"; import type { TextSelectionLayerImplProps, TextSelectionLayerProps } from "../text-selection-layer/types.js"; import type { PresenceLayerImplProps, PresenceLayerProps } from "../presence-layer/types.js"; import type { FocusScopeImplProps, FocusScopeProps } from "../focus-scope/types.js"; import type { ScrollLockProps } from "../scroll-lock/index.js"; import type { Direction } from "../../../shared/index.js"; export type PopperLayerProps = EscapeLayerProps & Omit & FloatingLayerContentProps & PresenceLayerProps & TextSelectionLayerProps & FocusScopeProps & Omit; export type PopperLayerStaticProps = EscapeLayerProps & Omit & PresenceLayerProps & TextSelectionLayerProps & FocusScopeProps & Omit & { content?: Snippet<[{ props: Record; }]>; dir?: Direction; }; export type PopperLayerImplProps = Omit & TextSelectionLayerImplProps & FocusScopeImplProps & { popper: Snippet<[ { props: Record; wrapperProps: Record; } ]>; isStatic?: boolean; /** * Tooltips are special in that they are commonly composed * with other floating components, where the same trigger is * used for both the tooltip and the popover. * * For situations like this, we need to use a different context * symbol so that conflicts don't occur. */ tooltip?: boolean; /** * Whether the popper layer should be rendered. */ shouldRender: boolean; /** * Override for the content's pointer-events style. * @default "auto" */ contentPointerEvents?: "auto" | "none"; }, "enabled">;