import type { CSSResultGroup } from 'lit'; import DSAIcon from '../icon/icon'; import DSAVisuallyHidden from '../visually-hidden/visually-hidden'; import { ShoelaceElement } from '../../internal/shoelace-element'; /** * @summary Options define the selectable items within various form controls such as [select](/components/select). * @documentation https://dsa.service-public-autonomie.fr/latest/librairie-webcomponents/liste-deroulante/option/web-NYvlY5jN * * @dependency dsa-icon * @dependency dsa-visually-hidden * * @slot - The option's label. * @slot prefix - Used to prepend an icon or similar element to the menu item. * @slot suffix - Used to append an icon or similar element to the menu item. */ export default class DSAOption extends ShoelaceElement { static styles: CSSResultGroup; static dependencies: { 'dsa-icon': typeof DSAIcon; 'dsa-visually-hidden': typeof DSAVisuallyHidden; }; private cachedTextLabel; private readonly localize; defaultSlot: HTMLSlotElement; current: boolean; selected: boolean; hasHover: boolean; /** * The option's value. When selected, the containing form control will receive this value. The value must be unique * from other options in the same group. Values may not contain spaces, as spaces are used as delimiters when listing * multiple values. */ value: string; /** Draws the option in a disabled state, preventing selection. */ disabled: boolean; /** The option's size. */ size: 'small' | 'medium' | 'large'; /** Indicates whether the input should be in error state */ error: boolean; /** Display an amount information for the option */ amount: number; /** Role of the option for better accessibility */ role: 'option' | 'checkbox' | 'radio'; /** Indicates whether the multiple options selection is possible */ multiple: boolean; private syncSelectionAriaAttribute; connectedCallback(): void; private handleDefaultSlotChange; private handleMouseEnter; private handleMouseLeave; handleDisabledChange(): void; handleSelectedChange(): void; handleRoleChange(): void; handleErrorChange(): void; handleValueChange(): void; /** Returns a plain text label based on the option's content. */ getTextLabel(): string; render(): import("lit").TemplateResult<1>; } declare global { interface HTMLElementTagNameMap { 'dsa-option': DSAOption; } }