quang 19.3.15-3 → 19.3.15-5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,7 +9,7 @@ import * as i0 from "@angular/core";
9
9
  *
10
10
  * `searchTextDebounce` is by default set to 300ms.
11
11
  */
12
- export declare class QuangAutocompleteComponent extends QuangBaseComponent<string | number | string[] | number[]> {
12
+ export declare class QuangAutocompleteComponent extends QuangBaseComponent<string | number | string[] | number[] | null> {
13
13
  /**
14
14
  * The list of options to display in the autocomplete dropdown.
15
15
  */
@@ -80,6 +80,13 @@ export declare class QuangAutocompleteComponent extends QuangBaseComponent<strin
80
80
  * @default 'vertical'
81
81
  */
82
82
  multiSelectDisplayMode: import("@angular/core").InputSignal<"vertical" | "horizontal">;
83
+ /**
84
+ * Position of chips relative to the input in multiple selection mode.
85
+ * - 'top': Chips are displayed above the input (default)
86
+ * - 'bottom': Chips are displayed below the input
87
+ * @default 'top'
88
+ */
89
+ chipsPosition: import("@angular/core").InputSignal<"top" | "bottom">;
83
90
  /**
84
91
  * Debounce time in milliseconds for search text changes.
85
92
  * @default 300
@@ -166,8 +173,8 @@ export declare class QuangAutocompleteComponent extends QuangBaseComponent<strin
166
173
  private readonly showOptionsChangeSubscription;
167
174
  constructor();
168
175
  setupFormControl(): void;
169
- writeValue(val: string | number | string[] | number[]): void;
170
- onChangedHandler(value: string | number | string[] | number[]): void;
176
+ writeValue(val: string | number | string[] | number[] | null): void;
177
+ onChangedHandler(value: string | number | string[] | number[] | null): void;
171
178
  onBlurHandler(): void;
172
179
  /**
173
180
  * Shows the option list dropdown.
@@ -187,7 +194,28 @@ export declare class QuangAutocompleteComponent extends QuangBaseComponent<strin
187
194
  * @param value The selected option's value
188
195
  * @param hideOptions Whether to hide the dropdown after selection
189
196
  */
190
- onValueChange(value: string | number, hideOptions?: boolean): void;
197
+ onValueChange(value: string | number | null, hideOptions?: boolean): void;
198
+ /**
199
+ * Handles keydown events on the input element for accessibility.
200
+ * @param event The keyboard event
201
+ */
202
+ onInputKeydown(event: KeyboardEvent): void;
203
+ /**
204
+ * Handles Escape key press from option list.
205
+ * Closes dropdown and returns focus to input.
206
+ */
207
+ onEscapePressed(): void;
208
+ /**
209
+ * Handles Tab key press from option list.
210
+ * Closes dropdown and allows natural tab navigation.
211
+ */
212
+ onTabPressed(_event: {
213
+ shiftKey: boolean;
214
+ }): void;
215
+ /**
216
+ * Sets focus to the input element.
217
+ */
218
+ focusInput(): void;
191
219
  /**
192
220
  * Handles input blur event.
193
221
  * @param event The focus event
@@ -249,7 +277,7 @@ export declare class QuangAutocompleteComponent extends QuangBaseComponent<strin
249
277
  /**
250
278
  * Emits search text change after debounce.
251
279
  * When `updateValueOnType` is true, also updates the form value using the same
252
- * matching logic as checkInputValue (auto-select matching options, or use free text).
280
+ * matching logic as processTextToFormValue (auto-select matching options, or use free text).
253
281
  */
254
282
  private emitDebouncedSearchText;
255
283
  /**
@@ -259,5 +287,5 @@ export declare class QuangAutocompleteComponent extends QuangBaseComponent<strin
259
287
  */
260
288
  private updateValueWithoutExitingSearchMode;
261
289
  static ɵfac: i0.ɵɵFactoryDeclaration<QuangAutocompleteComponent, never>;
262
- static ɵcmp: i0.ɵɵComponentDeclaration<QuangAutocompleteComponent, "quang-autocomplete", never, { "selectOptions": { "alias": "selectOptions"; "required": true; "isSignal": true; }; "allowFreeText": { "alias": "allowFreeText"; "required": false; "isSignal": true; }; "autoSelectOnExactMatch": { "alias": "autoSelectOnExactMatch"; "required": false; "isSignal": true; }; "updateValueOnType": { "alias": "updateValueOnType"; "required": false; "isSignal": true; }; "syncFormWithText": { "alias": "syncFormWithText"; "required": false; "isSignal": true; }; "optionListMaxHeight": { "alias": "optionListMaxHeight"; "required": false; "isSignal": true; }; "translateValue": { "alias": "translateValue"; "required": false; "isSignal": true; }; "scrollBehaviorOnOpen": { "alias": "scrollBehaviorOnOpen"; "required": false; "isSignal": true; }; "emitOnly": { "alias": "emitOnly"; "required": false; "isSignal": true; }; "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; "chipMaxLength": { "alias": "chipMaxLength"; "required": false; "isSignal": true; }; "multiSelectDisplayMode": { "alias": "multiSelectDisplayMode"; "required": false; "isSignal": true; }; "searchTextDebounce": { "alias": "searchTextDebounce"; "required": false; "isSignal": true; }; "internalFilterOptions": { "alias": "internalFilterOptions"; "required": false; "isSignal": true; }; }, { "selectedOption": "selectedOption"; "searchTextChange": "searchTextChange"; }, never, never, true, never>;
290
+ static ɵcmp: i0.ɵɵComponentDeclaration<QuangAutocompleteComponent, "quang-autocomplete", never, { "selectOptions": { "alias": "selectOptions"; "required": true; "isSignal": true; }; "allowFreeText": { "alias": "allowFreeText"; "required": false; "isSignal": true; }; "autoSelectOnExactMatch": { "alias": "autoSelectOnExactMatch"; "required": false; "isSignal": true; }; "updateValueOnType": { "alias": "updateValueOnType"; "required": false; "isSignal": true; }; "syncFormWithText": { "alias": "syncFormWithText"; "required": false; "isSignal": true; }; "optionListMaxHeight": { "alias": "optionListMaxHeight"; "required": false; "isSignal": true; }; "translateValue": { "alias": "translateValue"; "required": false; "isSignal": true; }; "scrollBehaviorOnOpen": { "alias": "scrollBehaviorOnOpen"; "required": false; "isSignal": true; }; "emitOnly": { "alias": "emitOnly"; "required": false; "isSignal": true; }; "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; "chipMaxLength": { "alias": "chipMaxLength"; "required": false; "isSignal": true; }; "multiSelectDisplayMode": { "alias": "multiSelectDisplayMode"; "required": false; "isSignal": true; }; "chipsPosition": { "alias": "chipsPosition"; "required": false; "isSignal": true; }; "searchTextDebounce": { "alias": "searchTextDebounce"; "required": false; "isSignal": true; }; "internalFilterOptions": { "alias": "internalFilterOptions"; "required": false; "isSignal": true; }; }, { "selectedOption": "selectedOption"; "searchTextChange": "searchTextChange"; }, never, never, true, never>;
263
291
  }
@@ -12,20 +12,41 @@ export declare class QuangSelectComponent extends QuangBaseComponent<string | nu
12
12
  selectOptions: import("@angular/core").InputSignal<SelectOption[]>;
13
13
  scrollBehaviorOnOpen: import("@angular/core").InputSignal<ScrollBehavior>;
14
14
  selectButton: import("@angular/core").Signal<ElementRef<HTMLButtonElement> | undefined>;
15
+ /** Whether the option list is currently visible */
15
16
  _showOptions: import("@angular/core").WritableSignal<boolean>;
16
- _optionHideTimeout: import("@angular/core").WritableSignal<any>;
17
17
  _selectedItems: import("@angular/core").Signal<SelectOption[] | null>;
18
18
  translateValue: import("@angular/core").InputSignal<boolean>;
19
19
  nullOption: import("@angular/core").InputSignal<boolean>;
20
20
  autoSelectSingleOption: import("@angular/core").InputSignal<boolean>;
21
21
  readonly ParentType = OptionListParentType.SELECT;
22
22
  constructor();
23
- changeOptionsVisibility(skipTimeout?: boolean): void;
23
+ changeOptionsVisibility(): void;
24
24
  showOptionVisibility(): void;
25
- hideOptionVisibility(skipTimeout?: boolean): void;
25
+ hideOptionVisibility(): void;
26
26
  onBlurHandler(): void;
27
27
  onChangedHandler(value: string | number | string[] | number[] | null): void;
28
28
  onMouseLeaveCallback(): void;
29
+ /**
30
+ * Handles keydown events on the select button for accessibility.
31
+ * @param event The keyboard event
32
+ */
33
+ onButtonKeydown(event: KeyboardEvent): void;
34
+ /**
35
+ * Handles Escape key press from option list.
36
+ * Closes dropdown and returns focus to button.
37
+ */
38
+ onEscapePressed(): void;
39
+ /**
40
+ * Handles Tab key press from option list.
41
+ * Closes dropdown and allows natural tab navigation.
42
+ */
43
+ onTabPressed(_event: {
44
+ shiftKey: boolean;
45
+ }): void;
46
+ /**
47
+ * Sets focus to the select button element.
48
+ */
49
+ focusButton(): void;
29
50
  static ɵfac: i0.ɵɵFactoryDeclaration<QuangSelectComponent, never>;
30
51
  static ɵcmp: i0.ɵɵComponentDeclaration<QuangSelectComponent, "quang-select", never, { "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "optionListMaxHeight": { "alias": "optionListMaxHeight"; "required": false; "isSignal": true; }; "selectOptions": { "alias": "selectOptions"; "required": true; "isSignal": true; }; "scrollBehaviorOnOpen": { "alias": "scrollBehaviorOnOpen"; "required": false; "isSignal": true; }; "translateValue": { "alias": "translateValue"; "required": false; "isSignal": true; }; "nullOption": { "alias": "nullOption"; "required": false; "isSignal": true; }; "autoSelectSingleOption": { "alias": "autoSelectSingleOption"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
31
52
  }
@@ -14,7 +14,7 @@ export declare class QuangOptionListComponent {
14
14
  selectionMode: import("@angular/core").InputSignal<"single" | "multiple">;
15
15
  optionListMaxHeight: import("@angular/core").InputSignal<string>;
16
16
  selectOptions: import("@angular/core").InputSignal<SelectOption[]>;
17
- selectButtonRef: import("@angular/core").InputSignal<HTMLInputElement | HTMLButtonElement | HTMLDivElement>;
17
+ selectButtonRef: import("@angular/core").InputSignal<HTMLButtonElement | HTMLInputElement | HTMLDivElement>;
18
18
  _value: import("@angular/core").InputSignal<any>;
19
19
  _isDisabled: import("@angular/core").InputSignal<boolean | undefined>;
20
20
  componentClass: import("@angular/core").InputSignal<string | string[]>;
@@ -28,6 +28,12 @@ export declare class QuangOptionListComponent {
28
28
  scrollBehaviorOnOpen: import("@angular/core").InputSignal<ScrollBehavior>;
29
29
  changedHandler: import("@angular/core").OutputEmitterRef<any>;
30
30
  blurHandler: import("@angular/core").OutputEmitterRef<any>;
31
+ /** Emitted when user presses Escape - parent should close dropdown and return focus to trigger */
32
+ escapePressed: import("@angular/core").OutputEmitterRef<void>;
33
+ /** Emitted when user presses Tab - parent should handle focus transition */
34
+ tabPressed: import("@angular/core").OutputEmitterRef<{
35
+ shiftKey: boolean;
36
+ }>;
31
37
  optionListContainer: import("@angular/core").Signal<ElementRef<HTMLDivElement> | undefined>;
32
38
  destroyRef: DestroyRef;
33
39
  parentType: import("@angular/core").InputSignal<OptionListParentType>;
@@ -38,6 +44,12 @@ export declare class QuangOptionListComponent {
38
44
  selectOptionsList: import("@angular/core").Signal<SelectOption[]>;
39
45
  onKeyDown: Subscription | null;
40
46
  selectedElementIndex: import("@angular/core").Signal<number>;
47
+ /** Signal to track currently focused item index for aria-activedescendant */
48
+ focusedItemIndex: import("@angular/core").WritableSignal<number>;
49
+ /**
50
+ * Returns the ID of the currently focused item for aria-activedescendant
51
+ */
52
+ getActiveDescendantId(): string | null;
41
53
  optionList$: import("@angular/core").EffectRef;
42
54
  handleSearch(key: string, listItems: HTMLLIElement[], currentIndex: number): number;
43
55
  changePosition(): void;
@@ -49,5 +61,5 @@ export declare class QuangOptionListComponent {
49
61
  getOptionListWidth(): void;
50
62
  getOptionListTop(): void;
51
63
  static ɵfac: i0.ɵɵFactoryDeclaration<QuangOptionListComponent, never>;
52
- static ɵcmp: i0.ɵɵComponentDeclaration<QuangOptionListComponent, "quang-option-list", never, { "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "optionListMaxHeight": { "alias": "optionListMaxHeight"; "required": false; "isSignal": true; }; "selectOptions": { "alias": "selectOptions"; "required": false; "isSignal": true; }; "selectButtonRef": { "alias": "selectButtonRef"; "required": true; "isSignal": true; }; "_value": { "alias": "_value"; "required": false; "isSignal": true; }; "_isDisabled": { "alias": "_isDisabled"; "required": false; "isSignal": true; }; "componentClass": { "alias": "componentClass"; "required": false; "isSignal": true; }; "componentLabel": { "alias": "componentLabel"; "required": false; "isSignal": true; }; "componentTabIndex": { "alias": "componentTabIndex"; "required": false; "isSignal": true; }; "translateValue": { "alias": "translateValue"; "required": false; "isSignal": true; }; "nullOption": { "alias": "nullOption"; "required": false; "isSignal": true; }; "scrollBehaviorOnOpen": { "alias": "scrollBehaviorOnOpen"; "required": false; "isSignal": true; }; "parentType": { "alias": "parentType"; "required": true; "isSignal": true; }; "parentID": { "alias": "parentID"; "required": false; "isSignal": true; }; }, { "changedHandler": "changedHandler"; "blurHandler": "blurHandler"; }, never, never, true, never>;
64
+ static ɵcmp: i0.ɵɵComponentDeclaration<QuangOptionListComponent, "quang-option-list", never, { "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "optionListMaxHeight": { "alias": "optionListMaxHeight"; "required": false; "isSignal": true; }; "selectOptions": { "alias": "selectOptions"; "required": false; "isSignal": true; }; "selectButtonRef": { "alias": "selectButtonRef"; "required": true; "isSignal": true; }; "_value": { "alias": "_value"; "required": false; "isSignal": true; }; "_isDisabled": { "alias": "_isDisabled"; "required": false; "isSignal": true; }; "componentClass": { "alias": "componentClass"; "required": false; "isSignal": true; }; "componentLabel": { "alias": "componentLabel"; "required": false; "isSignal": true; }; "componentTabIndex": { "alias": "componentTabIndex"; "required": false; "isSignal": true; }; "translateValue": { "alias": "translateValue"; "required": false; "isSignal": true; }; "nullOption": { "alias": "nullOption"; "required": false; "isSignal": true; }; "scrollBehaviorOnOpen": { "alias": "scrollBehaviorOnOpen"; "required": false; "isSignal": true; }; "parentType": { "alias": "parentType"; "required": true; "isSignal": true; }; "parentID": { "alias": "parentID"; "required": false; "isSignal": true; }; }, { "changedHandler": "changedHandler"; "blurHandler": "blurHandler"; "escapePressed": "escapePressed"; "tabPressed": "tabPressed"; }, never, never, true, never>;
53
65
  }