import { FASTElement } from "@microsoft/fast-element"; import type { DropdownOption } from "../option/index.js"; /** * OptionGroup * @summary An OptionGroup Custom HTML Element that groups related options within a listbox or dropdown. * Implements semantics similar to the native {@link https://developer.mozilla.org/docs/Web/HTML/Element/optgroup | HTMLOptGroupElement}. * * @example * ```html * * * Apple * Banana * * * Carrot * Broccoli * * * ``` * * @attr {string} label - The label for the option group, displayed as a non-selectable header. * @attr {boolean} disabled - When true, disables all options within this group. * * @prop {DropdownOption[]} options - The collection of child option elements. * * @slot - Default slot for fabric-option elements. * * @csspart label - The label element for the group header. * * @extends FASTElement * @tagname fabric-option-group * @public */ export declare class OptionGroup extends FASTElement { /** * The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | ElementInternals} instance for the component. * * @internal */ elementInternals: ElementInternals; /** * The label for the option group. Displayed as a non-selectable header. * * @public * @remarks * HTML Attribute: label */ label: string; /** * The disabled state of the option group. * When true, all child options are also disabled. * * @public * @remarks * HTML Attribute: disabled */ disabled?: boolean; /** * The collection of slotted option elements. * * @internal */ slottedOptions: Element[]; /** * Gets the collection of child option elements. * * @public */ get options(): DropdownOption[]; /** * Handles changes to the disabled attribute. * Updates the aria-disabled state on the element internals. * * @param prev - The previous disabled state. * @param next - The new disabled state. * @internal */ disabledChanged(prev: boolean | undefined, next: boolean | undefined): void; connectedCallback(): void; /** * Handles changes to the label attribute. * Updates the aria-label for accessibility. * * @param _prev - The previous label. * @param next - The new label. * @internal */ labelChanged(_prev: string | undefined, next: string | undefined): void; } //# sourceMappingURL=option-group.d.ts.map