import { LitElement, PropertyValues } from 'lit'; import { Directive, DirectiveParameters } from 'lit/directive.js'; import { ElementPart, type RenderOptions } from 'lit'; export declare class SimplePopper extends LitElement { static lazy(target: Element, callback: (target: SimplePopper) => void): void; static styles: import("lit").CSSResult; showing: boolean; manualOpening: boolean; maxWidthAsTarget: boolean; placement: 'top' | 'right' | 'bottom' | 'left' | 'top-start' | 'top-end' | 'right-start' | 'right-end' | 'bottom-start' | 'bottom-end' | 'left-start' | 'left-end'; offset: number; minWidth: string; minHeight: string; onClose: () => void; private arrowElement; constructor(); firstUpdated(): void; protected updated(_changedProperties: PropertyValues): void; connectedCallback(): void; _target: Element | null; get target(): Element | null; set target(target: Element | null); private cleanupAutoUpdate; show: () => void; hide: () => void; hideOnOutsideClick: (event: Event) => void; hideOnSlotClick: (event: Event) => void; finishHide: () => void; render(): import("lit-html").TemplateResult<1>; } declare class PopperDirective extends Directive { didSetupLazy: boolean; popperContent?: unknown; part?: ElementPart; popper?: SimplePopper; render(popperContent?: unknown): void; update(part: ElementPart, [popperContent]: DirectiveParameters): void; setupLazy(): void; renderTooltipContent(): void; } export declare const popper: (popperContent?: unknown) => import("lit-html/directive").DirectiveResult; export interface SharedPopperOptions { /** Anchor element the popper is positioned against. */ target: Element; /** Lit template (or any renderable) shown inside the popper. */ content: unknown; placement?: SimplePopper['placement']; offset?: number; maxWidthAsTarget?: boolean; minWidth?: string; /** Called whenever the popper hides (outside click, item pick, repoint). */ onClose?: () => void; /** Pass `{ host: }` so events/directives in `content` bind correctly. */ renderOptions?: RenderOptions; } /** Open (or re-point) the shared popper for `target` with `content`. */ export declare function openSharedPopper(options: SharedPopperOptions): SimplePopper; /** Re-render content into the shared popper only if `target` currently owns it. */ export declare function renderSharedPopperContent(target: Element, content: unknown, renderOptions?: RenderOptions): void; /** Close the shared popper. If `target` is given, only close when it owns it. */ export declare function closeSharedPopper(target?: Element): void; /** Whether the shared popper is currently open and anchored to `target`. */ export declare function isSharedPopperOpenFor(target: Element): boolean; declare global { interface HTMLElementTagNameMap { 'simple-popper': SimplePopper; } } export {};