import { FASTElement } from "@microsoft/fast-element"; import type { AccordionMenuExpandMode } from "./accordion-menu.options.js"; /** * AccordionMenu * @summary An AccordionMenu component that provides an interactive accordion interface, allowing for expandable and collapsible sections. Implements ARIA Accordion. * * @example * ```html * * * * * * * * * * * * * * ``` * * @attr {AccordionMenuExpandMode} expand-mode - Controls the expand mode of the Accordion, either allowing single or multiple item expansion. * * @prop {ElementInternals} elementInternals - Internal element state used to manage the component. * @prop {HTMLElement[]} slottedElements - The slotted accordion menu items. * @prop {AccordionMenuExpandMode} expandmode - Controls the expand mode of the Accordion, either allowing single or multiple item expansion. * * @slot - The default slot for the accordion items. * * @csspart accordion-menu - Represents the accordion menu container. * * @method expandmodeChanged - Handles changes to the `expandmode` attribute. * @method handleChange - Handles changes to observed properties. * @method clearSelections - Clears the selections of menu items. * @method findExpandedItem - Finds the first expanded item in the accordion. * @method setItems - Sets up the accordion items. * @method isSingleExpandMode - Checks if the accordion is in single expand mode. * @method setSingleExpandMode - Controls the behavior of the accordion in single expand mode. * * @fires change - Fires a custom 'change' event when the active item changes. * * @extends FASTElement * @tagname fabric-accordion-menu * @public */ export declare class AccordionMenu extends FASTElement { /** Internal element state used to manage the component. */ elementInternals: ElementInternals; /** Constructor for the AccordionMenu component. */ constructor(); /** Lifecycle method called when the component is connected to the DOM. */ connectedCallback(): void; /** Lifecycle method called when the component is disconnected from the DOM. */ disconnectedCallback(): void; /** * Controls the expand mode of the Accordion, either allowing * single or multiple item expansion. * HTML attribute: expand-mode * @public */ expandmode: AccordionMenuExpandMode; /** * Handles changes to the `expandmode` attribute. * @param prev - The previous value. * @param next - The next value. */ expandmodeChanged(prev: AccordionMenuExpandMode, next: AccordionMenuExpandMode): void; /** * The slotted accordion menu items. * @public */ slottedElements: HTMLElement[]; /** * Handles changes to observed properties. * @param source - The source element. * @param propertyName - The name of the property that changed. */ handleChange(source: HTMLElement, propertyName: string): void; /** * Clears the selections of menu items. */ clearSelections(): void; /** * Finds the first expanded item in the accordion. */ private findExpandedItem; /** * Sets up the accordion items. */ private setItems; private static elementIndent; /** * check if the item is a menu item */ protected isMenuItemElement: (el: Element) => el is HTMLElement; /** * Checks if the accordion is in single expand mode. */ private isSingleExpandMode; /** * Controls the behavior of the accordion in single expand mode. */ private setSingleExpandMode; /** * Removes event listeners from items. */ private removeItemListeners; } //# sourceMappingURL=accordion-menu.d.ts.map