import { LitElement, TemplateResult, CSSResult } from 'lit'; import { OverlayPlacement, OverlayOffset } from '../overlay/overlay.js'; declare global { interface HTMLElementTagNameMap { 'forge-ai-popover': ForgeAiPopoverComponent; } interface HTMLElementEventMap { 'forge-ai-popover-toggle': CustomEvent; } } export interface PopoverToggleEventData { open: boolean; newState: string; oldState: string; } export type PopoverPlacement = OverlayPlacement; export type PopoverOffset = OverlayOffset; /** * @summary A popover component that provides styled overlay functionality. * * @description * This component wraps the base overlay component with popover-specific styling * including animations, shadows, and rounded corners. * * @slot - The default slot for popover content. * * @cssproperty --ai-overlay-available-width - Set on the popover when `autoSize` is enabled; the width available in the chosen placement direction. * @cssproperty --ai-overlay-available-height - Set on the popover when `autoSize` is enabled; the height available in the chosen placement direction. */ export declare class ForgeAiPopoverComponent extends LitElement { static styles: CSSResult; /** * The anchor element to position the popover relative to. */ anchor: Element | null; /** * The placement of the popover relative to the anchor. */ placement: PopoverPlacement; /** * Whether the popover should flip to the opposite side when there's no space. */ flip: boolean; /** * Whether the popover should shift to stay in view. */ shift: boolean; /** * Whether the popover should constrain its own size to the space available in the chosen * placement direction, exposed as the `--ai-overlay-available-width`/`--ai-overlay-available-height` * CSS custom properties so slotted content can shrink (and scroll internally) instead of being * clipped by the viewport. */ autoSize: boolean; /** * Whether the popover is open. */ open: boolean; /** * Whether to show an arrow pointing to the anchor element. */ arrow: boolean; /** * The offset of the popover from the anchor element. * Can be a number (main axis offset) or an object with mainAxis, crossAxis, and alignmentAxis properties. */ offset: PopoverOffset | undefined; /** * The dismiss mode for the popover. * - 'auto': Automatically closes on outside clicks and Escape key * - 'manual': Requires manual control to close */ dismissMode: 'auto' | 'manual'; private _arrowElement?; private _onOverlayToggle; render(): TemplateResult; }