import { ReactiveController, ReactiveElement } from 'lit'; /** * A reactive controller that observes whether slotted content matching * given CSS selectors is present in the host's light DOM. * * Replaces the `ObserveSlotPresence` mixin with a composition-based approach. * * @example * ```typescript * class MyComponent extends SpectrumElement { * private slotPresence = new SlotPresenceController(this, '[slot="icon"]'); * * get hasIcon(): boolean { * return this.slotPresence.isPresent; * } * } * ``` * * @example * ```typescript * // Observing multiple selectors * class MyComponent extends SpectrumElement { * private slotPresence = new SlotPresenceController(this, [ * '[slot="icon"]', * '[slot="description"]', * ]); * * get hasIcon(): boolean { * return this.slotPresence.getPresence('[slot="icon"]'); * } * * get hasDescription(): boolean { * return this.slotPresence.getPresence('[slot="description"]'); * } * } * ``` */ export declare class SlotPresenceController implements ReactiveController { private host; private selectors; private presenceMap; private observer; constructor(host: ReactiveElement, selectors: string | string[]); /** * Whether slotted content is present. Use this when observing a single * selector. Throws if multiple selectors were provided — use * `getPresence(selector)` instead. */ get isPresent(): boolean; /** * Returns whether content matching the given selector is present. */ getPresence(selector: string): boolean; private checkPresence; hostConnected(): void; hostDisconnected(): void; }