import { type TypeaheadPredicate } from '@aracna/core'; import { type CSSResultGroup, type PropertyDeclarations } from 'lit'; import { AriaComboBoxButtonController, AriaComboBoxClearController, AriaComboBoxController, AriaComboBoxInputController, AriaComboBoxListController, AriaComboBoxOptionController, AriaComboBoxOptionRemoveController } from '../../controllers/aria-combo-box-controller.js'; import { ElementSlug } from '../../definitions/enums.js'; import type { AriaComboBoxButtonElementEventMap, AriaComboBoxClearElementEventMap, AriaComboBoxElementEventMap, AriaComboBoxGroupElementEventMap, AriaComboBoxInputElementEventMap, AriaComboBoxListElementEventMap, AriaComboBoxOptionElementEventMap, AriaComboBoxOptionRemoveElementEventMap } from '../../definitions/events.js'; import type { QueryDeclarations } from '../../definitions/interfaces.js'; import type { AriaComboBoxElementAutoComplete, AriaComboBoxElementFilterOptionsPredicate } from '../../definitions/types.js'; import { AracnaBaseElement as BaseElement } from '../core/base-element.js'; import { AracnaFloatingElement as FloatingElement } from '../core/floating-element.js'; import { AracnaFormControlElement as FormControlElement } from '../core/form-control-element.js'; declare global { interface HTMLElementTagNameMap { 'aracna-aria-combobox': AriaComboBoxElement; 'aracna-aria-combobox-button': AriaComboBoxButtonElement; 'aracna-aria-combobox-clear': AriaComboBoxClearElement; 'aracna-aria-combobox-group': AriaComboBoxGroupElement; 'aracna-aria-combobox-input': AriaComboBoxInputElement; 'aracna-aria-combobox-list': AriaComboBoxListElement; 'aracna-aria-combobox-option': AriaComboBoxOptionElement; 'aracna-aria-combobox-option-remove': AriaComboBoxOptionRemoveElement; } } declare class AriaComboBoxElement extends FormControlElement { protected aria: AriaComboBoxController; /** * Properties */ /** */ autocomplete?: AriaComboBoxElementAutoComplete; expanded?: boolean; multiple?: boolean; scrollIntoViewBehaviour?: ScrollBehavior; scrollIntoViewBlock?: ScrollLogicalPosition; scrollIntoViewInline?: ScrollLogicalPosition; typeaheadDebounceTime?: number; typeaheadPredicate?: TypeaheadPredicate; /** * Queries */ /** */ buttonElement?: AriaComboBoxButtonElement; groupElement?: AriaComboBoxGroupElement; inputElement?: AriaComboBoxInputElement; listElement?: AriaComboBoxListElement; focusedOptionElement?: AriaComboBoxOptionElement; optionElements: AriaComboBoxOptionElement[]; selectElement?: HTMLSelectElement; selectedOptionElement?: AriaComboBoxOptionElement; selectedOptionElements: AriaComboBoxOptionElement[]; connectedCallback(): void; disconnectedCallback(): void; attributeChangedCallback(name: string, _old: string | null, value: string | null): void; onKeyDown: (event: KeyboardEvent) => void; onTypeaheadMatch: (element: AriaComboBoxOptionElement) => void; collapse(): void; expand(): void; removeOption(value: any): void; clear(): void; findOptionElementByValue(value: any): AriaComboBoxOptionElement | undefined; findOptionElementLabelByValue(value: any): string | undefined; filterOptions(options: T[], predicate?: AriaComboBoxElementFilterOptionsPredicate): T[]; isOptionElementFocused(element: AriaComboBoxOptionElement): boolean; get collapsed(): boolean; get editable(): boolean; get focusedOptionElementIndex(): number; get slug(): ElementSlug; get scrollIntoViewOptions(): ScrollIntoViewOptions; get selectedOptionElementIndex(): number; get single(): boolean; get value(): any; set value(value: any); static properties: PropertyDeclarations; static queries: QueryDeclarations; static styles: CSSResultGroup; } declare class AriaComboBoxGroupElement extends BaseElement { get slug(): ElementSlug; } declare class AriaComboBoxButtonElement extends BaseElement { protected aria: AriaComboBoxButtonController; /** * Queries */ /** */ rootElement?: AriaComboBoxElement; connectedCallback(): void; disconnectedCallback(): void; onBlur: () => void; onClick: () => void; get slug(): ElementSlug; static queries: QueryDeclarations; static styles: CSSResultGroup; } declare class AriaComboBoxInputElement extends BaseElement { protected aria: AriaComboBoxInputController; /** * Queries */ /** */ inputElement?: HTMLInputElement; rootElement?: AriaComboBoxElement; connectedCallback(): void; disconnectedCallback(): void; onBlur: () => void; onClick: () => void; onInput: () => void; focus(): void; clear(): void; get slug(): ElementSlug; get value(): string | undefined; set value(value: string | undefined); static properties: PropertyDeclarations; static queries: QueryDeclarations; } declare class AriaComboBoxListElement extends FloatingElement { protected aria: AriaComboBoxListController; /** * Queries */ /** */ rootElement?: AriaComboBoxElement; get slug(): ElementSlug; get referenceElement(): AriaComboBoxGroupElement | undefined; static queries: QueryDeclarations; static styles: CSSResultGroup; } declare class AriaComboBoxOptionElement extends BaseElement { protected aria: AriaComboBoxOptionController; /** * Properties */ /** */ focused?: boolean; selected?: boolean; value?: any; /** * Queries */ /** */ listElement?: AriaComboBoxListElement; rootElement?: AriaComboBoxElement; /** * Internals */ /** */ _label?: string; connectedCallback(): void; disconnectedCallback(): void; attributeChangedCallback(name: string, _old: string | null, value: string | null): void; blur(): void; focus(options?: FocusOptions | undefined): void; select(): void; unselect(clear?: boolean): void; onClick(): void; onPointerDown: (event: PointerEvent) => void; get label(): string | undefined; set label(label: string | undefined); get slug(): ElementSlug; get unselected(): boolean; static properties: PropertyDeclarations; static queries: QueryDeclarations; static styles: CSSResultGroup; } declare class AriaComboBoxOptionRemoveElement extends BaseElement { protected aria: AriaComboBoxOptionRemoveController; /** * Propertis */ /** */ value?: any; /** * Queries */ /** */ rootElement?: AriaComboBoxElement; connectedCallback(): void; disconnectedCallback(): void; onClick: () => void; get slug(): ElementSlug; static properties: PropertyDeclarations; static queries: QueryDeclarations; static styles: CSSResultGroup; } declare class AriaComboBoxClearElement extends BaseElement { protected aria: AriaComboBoxClearController; /** * Queries */ /** */ rootElement?: AriaComboBoxElement; connectedCallback(): void; disconnectedCallback(): void; onClick: () => void; get slug(): ElementSlug; static queries: QueryDeclarations; static styles: CSSResultGroup; } export { AriaComboBoxButtonElement as AracnaAriaComboBoxButtonElement, AriaComboBoxClearElement as AracnaAriaComboBoxClearElement, AriaComboBoxElement as AracnaAriaComboBoxElement, AriaComboBoxGroupElement as AracnaAriaComboBoxGroupElement, AriaComboBoxInputElement as AracnaAriaComboBoxInputElement, AriaComboBoxListElement as AracnaAriaComboBoxListElement, AriaComboBoxOptionElement as AracnaAriaComboBoxOptionElement, AriaComboBoxOptionRemoveElement as AracnaAriaComboBoxOptionRemoveElement };