UNPKG

@funidata/ngx-fudis

Version:

Funidata Design System.

89 lines (88 loc) 3.79 kB
import { EventEmitter, OnChanges, ElementRef } from '@angular/core'; import { FudisComponentChanges } from '../../../../../types/miscellaneous'; import * as i0 from "@angular/core"; export declare class SelectAutocompleteBaseDirective { protected _elementRef: ElementRef<HTMLInputElement>; constructor(_elementRef: ElementRef<HTMLInputElement>); /** * To enable autocomplete */ enableAutocomplete: boolean; /** * Determine how many characters must be typed for autocomplete to open available options */ typeThreshold: 0 | 3; /** * Id of binded Select element */ id: string; /** * To clear input field when Clear Button is clicked */ clearButtonClick: boolean | null; /** * Output event for updating parent's filter text signal */ handleFilterTextUpdate: EventEmitter<string>; /** * Output event for opening parent dropdown */ handleDropdownOpen: EventEmitter<void>; /** * Output event for closing parent dropdown */ handleDropdownClose: EventEmitter<void>; /** * Output event for closing parent dropdown */ handleClearButtonReset: EventEmitter<void>; /** * Output event for input focus */ handleFocus: EventEmitter<{ event: FocusEvent; focusFromClearButton: boolean; }>; /** * Output event for input blur */ handleBlur: EventEmitter<FocusEvent>; /** * Keyboard button pressed */ private _keyDown; /** * If Focus came from related clear button */ private _focusFromClearButton; /** * Currently typed input text */ private _inputText; /** * If input is focused or not */ protected _focused: boolean; private _handleFocus; private _handleBlur; private _handleKeyDown; private _handleKeyUp; static ɵfac: i0.ɵɵFactoryDeclaration<SelectAutocompleteBaseDirective, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<SelectAutocompleteBaseDirective, "[fudisSelectAutocompleteBase]", never, { "enableAutocomplete": { "alias": "enableAutocomplete"; "required": false; }; "typeThreshold": { "alias": "typeThreshold"; "required": true; }; "id": { "alias": "id"; "required": false; }; "clearButtonClick": { "alias": "clearButtonClick"; "required": false; }; }, { "handleFilterTextUpdate": "handleFilterTextUpdate"; "handleDropdownOpen": "handleDropdownOpen"; "handleDropdownClose": "handleDropdownClose"; "handleClearButtonReset": "handleClearButtonReset"; "handleFocus": "handleFocus"; "handleBlur": "handleBlur"; }, never, never, false, never>; } export declare class SelectAutocompleteDirective extends SelectAutocompleteBaseDirective implements OnChanges { constructor(_elementRef: ElementRef<HTMLInputElement>); /** * Currently selected visible label */ selectedLabel: string | null; ngOnChanges(changes: FudisComponentChanges<SelectAutocompleteDirective>): void; static ɵfac: i0.ɵɵFactoryDeclaration<SelectAutocompleteDirective, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<SelectAutocompleteDirective, "[fudisSelectAutocomplete]", never, { "selectedLabel": { "alias": "selectedLabel"; "required": false; }; }, {}, never, never, false, never>; } export declare class MultiselectAutocompleteDirective extends SelectAutocompleteBaseDirective implements OnChanges { constructor(_elementRef: ElementRef<HTMLInputElement>); ngOnChanges(changes: FudisComponentChanges<SelectAutocompleteDirective>): void; static ɵfac: i0.ɵɵFactoryDeclaration<MultiselectAutocompleteDirective, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<MultiselectAutocompleteDirective, "[fudisMultiselectAutocomplete]", never, {}, {}, never, never, false, never>; }