@acorex/components 22.2.0 → 22.2.1

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.
package/lookup/README.md CHANGED
@@ -62,7 +62,7 @@ Value binding uses the signal `value` model (`FormValueControl`) — prefer `[(n
62
62
  - `valueField` / `textField` / `disabledField`: field mappings. For tree modes these map to the tree `idField` / `titleField`.
63
63
  - `columns`: column definitions (`{ field, title, width?, expandHandler? }`) for `multi-column` and `multi-column-tree` (mapped to `ax-text-column`).
64
64
  - `treeParentField` / `hasChildrenField`: hierarchy fields for `multi-column-tree` (defaults `parentId` / `hasChild`).
65
- - `searchable`: when `true` (default), the trigger accepts typing and filters the list or tree in every mode. Nested array trees keep matching branches and expand ancestors of hits; lazy callback trees filter each loaded level (unloaded descendants are not searched). When `false`, the trigger is select-only.
65
+ - `searchable`: when `true` (default), the trigger accepts typing and filters the list or tree in every mode. Nested array trees keep matching branches and expand ancestors of hits; lazy callback trees are hydrated once per popup open and searched in full (subsequent keystrokes filter the cached snapshot in memory). When `false`, the trigger is select-only.
66
66
  - `adaptivityEnabled`: when `true` (default), the list opens as a bottom actionsheet on small screens instead of a dropdown; set `false` to always use the anchored dropdown.
67
67
  - `caption`: title shown in the actionsheet header (falls back to `placeholder`).
68
68
  - `alternate`: when `true`, list rows use alternating background colors for easier scanning (all modes, including tree).
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@acorex/components",
3
- "version": "22.2.0",
3
+ "version": "22.2.1",
4
4
  "peerDependencies": {
5
- "@acorex/core": "22.2.0",
6
- "@acorex/cdk": "22.2.0",
5
+ "@acorex/core": "22.2.1",
6
+ "@acorex/cdk": "22.2.1",
7
7
  "@angular/aria": ">=22.1.0",
8
8
  "polytype": ">=0.17.0",
9
9
  "hammerjs": ">=2.0.8",
@@ -4858,6 +4858,7 @@ declare class AXConversationAudioPickerComponent implements OnDestroy, AXConvers
4858
4858
  private catalogFileTypeDef?;
4859
4859
  caption: string;
4860
4860
  groupItems: boolean;
4861
+ sendAsDocuments: boolean;
4861
4862
  readonly allowMultiple: _angular_core.Signal<boolean>;
4862
4863
  constructor();
4863
4864
  activate(): Promise<void>;
@@ -4871,6 +4872,7 @@ declare class AXConversationAudioPickerComponent implements OnDestroy, AXConvers
4871
4872
  renameAudio(index: number): Promise<void>;
4872
4873
  replaceAttachment(index: number): Promise<void>;
4873
4874
  sendAudio(): Promise<void>;
4875
+ private sendAudioAsDocuments;
4874
4876
  canSend(): boolean;
4875
4877
  getUploadingLabel(progress: number): string;
4876
4878
  getCancelUploadLabel(): string;
@@ -869,9 +869,10 @@ declare class AXDataTableComponent extends AXBaseDataTable implements OnInit, Af
869
869
  protected resizeColumnProp: {
870
870
  startX: number;
871
871
  startWidth: number;
872
- columnIndex: number;
873
- newColumnWidth: number;
874
- thElement: any;
872
+ column: AXDataTableColumnComponent | null;
873
+ thElement: HTMLElement | null;
874
+ /** True when the resize handle sits on the column's trailing edge in screen coordinates. */
875
+ resizeFromTrailingEdge: boolean;
875
876
  };
876
877
  /**
877
878
  * Columns that used `width="auto"` and received header-only sizing before rows were available.
@@ -1087,10 +1088,20 @@ declare class AXDataTableComponent extends AXBaseDataTable implements OnInit, Af
1087
1088
  protected toggleExpanded(rows: any[], expandedItem: any, children: any[]): any[];
1088
1089
  protected refreshExpandedItem(id: string | number): Promise<void>;
1089
1090
  private updateChildren;
1091
+ /**
1092
+ * CDK sort-predicate indices follow physical left-to-right order; map them to `columnsList` order.
1093
+ * @ignore
1094
+ */
1095
+ private cdkSortIndexToColumnIndex;
1096
+ /**
1097
+ * Restricts column reordering to non-fixed columns only.
1098
+ * @ignore
1099
+ */
1100
+ protected columnReorderSortPredicate: (index: number) => boolean;
1090
1101
  /**
1091
1102
  * @ignore
1092
1103
  */
1093
- protected drop(event: CdkDragDrop<any, any, any>): void;
1104
+ protected drop(event: CdkDragDrop<AXDataTableColumnComponent>): void;
1094
1105
  /**
1095
1106
  * @ignore
1096
1107
  */
@@ -1154,11 +1165,11 @@ declare class AXDataTableComponent extends AXBaseDataTable implements OnInit, Af
1154
1165
  * @param columnIndex - The index of the column to auto-fit
1155
1166
  * @ignore
1156
1167
  */
1157
- protected onResizeHandlerDoubleClick(event: MouseEvent, columnIndex: number): void;
1168
+ protected onResizeHandlerDoubleClick(event: MouseEvent, column: AXDataTableColumnComponent): void;
1158
1169
  /**
1159
1170
  * @ignore
1160
1171
  */
1161
- protected onResizeColumnStart(event: MouseEvent, columnIndex: number): void;
1172
+ protected onResizeColumnStart(event: MouseEvent, column: AXDataTableColumnComponent): void;
1162
1173
  /**
1163
1174
  * @ignore
1164
1175
  */
@@ -3,7 +3,7 @@ import { TemplateRef, ElementRef } from '@angular/core';
3
3
  import { AXEvent, AXDataSource, AXListDataSource, AXHtmlEvent, NXValueComponent, AXStyleLookType, AXValueChangedEvent, AXFocusEvent, AXItemClickEvent, AXItemSelectedEvent } from '@acorex/cdk/common';
4
4
  import { AXPopoverComponent } from '@acorex/components/popover';
5
5
  import { AXSearchBoxComponent } from '@acorex/components/search-box';
6
- import { AXTreeViewDataSource, AXTreeViewItemTemplateContext, AXTreeViewSelectionChangeEvent, AXTreeViewSelectionBehavior, AXTreeViewNode } from '@acorex/components/tree-view';
6
+ import { AXTreeViewNode, AXTreeViewDataSource, AXTreeViewSelectionBehavior, AXTreeViewItemTemplateContext, AXTreeViewSelectionChangeEvent } from '@acorex/components/tree-view';
7
7
  import { FormValueControl } from '@angular/forms/signals';
8
8
  import { AXListNavigationDirective, AXListNavigationItemDirective } from '@acorex/cdk/list-navigation';
9
9
  import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
@@ -57,72 +57,6 @@ interface AXLookupSelectionChangedEvent<TItem = any> extends AXEvent {
57
57
  value: unknown | unknown[] | null;
58
58
  }
59
59
 
60
- /**
61
- * Internal mini component for the `drop-down-tree` lookup mode:
62
- * a predefined list rendered in a tree-like structure for single item selection.
63
- *
64
- * @category Components
65
- */
66
- declare class AXLookupDropDownTreeComponent {
67
- #private;
68
- constructor();
69
- /**
70
- * The tree datasource: an array of nodes or a lazy children callback.
71
- */
72
- dataSource: _angular_core.InputSignal<AXTreeViewDataSource>;
73
- /**
74
- * The node property used as the selection value (tree `idField`).
75
- */
76
- valueField: _angular_core.InputSignal<string>;
77
- /**
78
- * The node property used as the display text (tree `titleField`).
79
- */
80
- textField: _angular_core.InputSignal<string>;
81
- /**
82
- * The node property marking a node as disabled.
83
- */
84
- disabledField: _angular_core.InputSignal<string>;
85
- /**
86
- * Currently selected values (at most one for single selection).
87
- */
88
- selectedValues: _angular_core.InputSignal<unknown[]>;
89
- /**
90
- * Custom template rendered for each tree node.
91
- */
92
- nodeTemplate: _angular_core.InputSignal<TemplateRef<AXTreeViewItemTemplateContext>>;
93
- /**
94
- * Custom template rendered when the filtered tree has no nodes.
95
- */
96
- emptyTemplate: _angular_core.InputSignal<TemplateRef<unknown>>;
97
- /**
98
- * When `true`, visible tree nodes use alternating background colors.
99
- */
100
- alternate: _angular_core.InputSignal<boolean>;
101
- /**
102
- * Unique id that changes on every search apply so a new tree instance is created.
103
- */
104
- filterKey: _angular_core.InputSignal<string>;
105
- /**
106
- * When set, matching characters in the default node label are highlighted.
107
- */
108
- highlightText: _angular_core.InputSignal<string>;
109
- /**
110
- * Emitted when the user selects a node.
111
- */
112
- itemClick: _angular_core.OutputEmitterRef<AXLookupItemClickEvent>;
113
- protected selectedIds: _angular_core.Signal<string[]>;
114
- protected isEmpty: _angular_core.Signal<boolean>;
115
- protected treeInstances: _angular_core.Signal<{
116
- id: string;
117
- source: AXTreeViewDataSource;
118
- }[]>;
119
- /** Whether the filtered tree currently has no nodes. */
120
- hasNoMatches(): boolean;
121
- protected handleSelectionChange(e: AXTreeViewSelectionChangeEvent): void;
122
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXLookupDropDownTreeComponent, never>;
123
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXLookupDropDownTreeComponent, "ax-lookup-drop-down-tree", never, { "dataSource": { "alias": "dataSource"; "required": true; "isSignal": true; }; "valueField": { "alias": "valueField"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "disabledField": { "alias": "disabledField"; "required": false; "isSignal": true; }; "selectedValues": { "alias": "selectedValues"; "required": false; "isSignal": true; }; "nodeTemplate": { "alias": "nodeTemplate"; "required": false; "isSignal": true; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; "isSignal": true; }; "alternate": { "alias": "alternate"; "required": false; "isSignal": true; }; "filterKey": { "alias": "filterKey"; "required": false; "isSignal": true; }; "highlightText": { "alias": "highlightText"; "required": false; "isSignal": true; }; }, { "itemClick": "itemClick"; }, never, never, true, never>;
124
- }
125
-
126
60
  /**
127
61
  * Shared `AXDataSource` + CDK virtual scroll plumbing for the list-based lookup views
128
62
  * (`ax-lookup-drop-down-list`, `ax-lookup-multi-select`).
@@ -271,6 +205,14 @@ declare class AXLookupMultiSelectTreeComponent {
271
205
  * Custom template rendered when the filtered tree has no nodes.
272
206
  */
273
207
  emptyTemplate: _angular_core.InputSignal<TemplateRef<unknown>>;
208
+ /**
209
+ * Custom template rendered while the tree is hydrating for search.
210
+ */
211
+ loadingTemplate: _angular_core.InputSignal<TemplateRef<unknown>>;
212
+ /**
213
+ * When `true`, a loading placeholder is shown while lazy tree data is hydrated for search.
214
+ */
215
+ loading: _angular_core.InputSignal<boolean>;
274
216
  /**
275
217
  * When `true`, visible tree nodes use alternating background colors.
276
218
  */
@@ -297,7 +239,7 @@ declare class AXLookupMultiSelectTreeComponent {
297
239
  hasNoMatches(): boolean;
298
240
  protected handleSelectionChange(e: AXTreeViewSelectionChangeEvent): void;
299
241
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXLookupMultiSelectTreeComponent, never>;
300
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXLookupMultiSelectTreeComponent, "ax-lookup-multi-select-tree", never, { "dataSource": { "alias": "dataSource"; "required": true; "isSignal": true; }; "valueField": { "alias": "valueField"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "disabledField": { "alias": "disabledField"; "required": false; "isSignal": true; }; "selectedValues": { "alias": "selectedValues"; "required": false; "isSignal": true; }; "selectionBehavior": { "alias": "selectionBehavior"; "required": false; "isSignal": true; }; "nodeTemplate": { "alias": "nodeTemplate"; "required": false; "isSignal": true; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; "isSignal": true; }; "alternate": { "alias": "alternate"; "required": false; "isSignal": true; }; "filterKey": { "alias": "filterKey"; "required": false; "isSignal": true; }; "highlightText": { "alias": "highlightText"; "required": false; "isSignal": true; }; }, { "selectionChange": "selectionChange"; }, never, never, true, never>;
242
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXLookupMultiSelectTreeComponent, "ax-lookup-multi-select-tree", never, { "dataSource": { "alias": "dataSource"; "required": true; "isSignal": true; }; "valueField": { "alias": "valueField"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "disabledField": { "alias": "disabledField"; "required": false; "isSignal": true; }; "selectedValues": { "alias": "selectedValues"; "required": false; "isSignal": true; }; "selectionBehavior": { "alias": "selectionBehavior"; "required": false; "isSignal": true; }; "nodeTemplate": { "alias": "nodeTemplate"; "required": false; "isSignal": true; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; "isSignal": true; }; "loadingTemplate": { "alias": "loadingTemplate"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "alternate": { "alias": "alternate"; "required": false; "isSignal": true; }; "filterKey": { "alias": "filterKey"; "required": false; "isSignal": true; }; "highlightText": { "alias": "highlightText"; "required": false; "isSignal": true; }; }, { "selectionChange": "selectionChange"; }, never, never, true, never>;
301
243
  }
302
244
 
303
245
  /**
@@ -378,6 +320,7 @@ declare class AXLookupComponent<T = AXLookupItem> extends NXValueComponent imple
378
320
  * Whether the trigger accepts typing and filters the datasource (`true`),
379
321
  * or is select-only with no writable input (`false`).
380
322
  * Applies to all modes, including `drop-down-tree` and `multi-select-tree`.
323
+ * Lazy callback trees are hydrated once per popup open and searched in full.
381
324
  * On small screens with `adaptivityEnabled`, search is typed in the actionsheet instead of the trigger.
382
325
  */
383
326
  searchable: _angular_core.InputSignal<boolean>;
@@ -521,6 +464,7 @@ declare class AXLookupComponent<T = AXLookupItem> extends NXValueComponent imple
521
464
  protected isSheetSearchEnabled: _angular_core.Signal<boolean>;
522
465
  /** Query typed in the actionsheet search field (independent of the trigger display text). */
523
466
  protected sheetSearchText: _angular_core.WritableSignal<string>;
467
+ protected treeSearchLoading: _angular_core.WritableSignal<boolean>;
524
468
  /** Increments on every tree filter apply so the tree view remounts with a new instance. */
525
469
  protected treeFilterKey: _angular_core.Signal<string>;
526
470
  /** Query passed to result-item highlighting (empty when disabled). */
@@ -558,8 +502,6 @@ declare class AXLookupComponent<T = AXLookupItem> extends NXValueComponent imple
558
502
  protected popupRef: _angular_core.Signal<ElementRef<HTMLElement>>;
559
503
  protected triggerSearchInput: _angular_core.Signal<ElementRef<HTMLInputElement>>;
560
504
  protected listView: _angular_core.Signal<AXLookupListViewBase>;
561
- protected dropDownTreeView: _angular_core.Signal<AXLookupDropDownTreeComponent>;
562
- protected multiSelectTreeView: _angular_core.Signal<AXLookupMultiSelectTreeComponent>;
563
505
  protected sheetSearchRef: _angular_core.Signal<AXSearchBoxComponent>;
564
506
  constructor();
565
507
  /** Returns the display text of an item using the `textField` mapping. */
@@ -673,6 +615,80 @@ declare class AXLookupMultiSelectComponent extends AXLookupListViewBase {
673
615
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXLookupMultiSelectComponent, "ax-lookup-multi-select", never, {}, {}, never, never, true, never>;
674
616
  }
675
617
 
618
+ /**
619
+ * Internal mini component for the `drop-down-tree` lookup mode:
620
+ * a predefined list rendered in a tree-like structure for single item selection.
621
+ *
622
+ * @category Components
623
+ */
624
+ declare class AXLookupDropDownTreeComponent {
625
+ #private;
626
+ constructor();
627
+ /**
628
+ * The tree datasource: an array of nodes or a lazy children callback.
629
+ */
630
+ dataSource: _angular_core.InputSignal<AXTreeViewDataSource>;
631
+ /**
632
+ * The node property used as the selection value (tree `idField`).
633
+ */
634
+ valueField: _angular_core.InputSignal<string>;
635
+ /**
636
+ * The node property used as the display text (tree `titleField`).
637
+ */
638
+ textField: _angular_core.InputSignal<string>;
639
+ /**
640
+ * The node property marking a node as disabled.
641
+ */
642
+ disabledField: _angular_core.InputSignal<string>;
643
+ /**
644
+ * Currently selected values (at most one for single selection).
645
+ */
646
+ selectedValues: _angular_core.InputSignal<unknown[]>;
647
+ /**
648
+ * Custom template rendered for each tree node.
649
+ */
650
+ nodeTemplate: _angular_core.InputSignal<TemplateRef<AXTreeViewItemTemplateContext>>;
651
+ /**
652
+ * Custom template rendered when the filtered tree has no nodes.
653
+ */
654
+ emptyTemplate: _angular_core.InputSignal<TemplateRef<unknown>>;
655
+ /**
656
+ * Custom template rendered while the tree is hydrating for search.
657
+ */
658
+ loadingTemplate: _angular_core.InputSignal<TemplateRef<unknown>>;
659
+ /**
660
+ * When `true`, a loading placeholder is shown while lazy tree data is hydrated for search.
661
+ */
662
+ loading: _angular_core.InputSignal<boolean>;
663
+ /**
664
+ * When `true`, visible tree nodes use alternating background colors.
665
+ */
666
+ alternate: _angular_core.InputSignal<boolean>;
667
+ /**
668
+ * Unique id that changes on every search apply so a new tree instance is created.
669
+ */
670
+ filterKey: _angular_core.InputSignal<string>;
671
+ /**
672
+ * When set, matching characters in the default node label are highlighted.
673
+ */
674
+ highlightText: _angular_core.InputSignal<string>;
675
+ /**
676
+ * Emitted when the user selects a node.
677
+ */
678
+ itemClick: _angular_core.OutputEmitterRef<AXLookupItemClickEvent>;
679
+ protected selectedIds: _angular_core.Signal<string[]>;
680
+ protected isEmpty: _angular_core.Signal<boolean>;
681
+ protected treeInstances: _angular_core.Signal<{
682
+ id: string;
683
+ source: AXTreeViewDataSource;
684
+ }[]>;
685
+ /** Whether the filtered tree currently has no nodes. */
686
+ hasNoMatches(): boolean;
687
+ protected handleSelectionChange(e: AXTreeViewSelectionChangeEvent): void;
688
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXLookupDropDownTreeComponent, never>;
689
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXLookupDropDownTreeComponent, "ax-lookup-drop-down-tree", never, { "dataSource": { "alias": "dataSource"; "required": true; "isSignal": true; }; "valueField": { "alias": "valueField"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "disabledField": { "alias": "disabledField"; "required": false; "isSignal": true; }; "selectedValues": { "alias": "selectedValues"; "required": false; "isSignal": true; }; "nodeTemplate": { "alias": "nodeTemplate"; "required": false; "isSignal": true; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; "isSignal": true; }; "loadingTemplate": { "alias": "loadingTemplate"; "required": false; "isSignal": true; }; "loading": { "alias": "loading"; "required": false; "isSignal": true; }; "alternate": { "alias": "alternate"; "required": false; "isSignal": true; }; "filterKey": { "alias": "filterKey"; "required": false; "isSignal": true; }; "highlightText": { "alias": "highlightText"; "required": false; "isSignal": true; }; }, { "itemClick": "itemClick"; }, never, never, true, never>;
690
+ }
691
+
676
692
  /**
677
693
  * Internal mini component for the `multi-column` lookup mode:
678
694
  * renders selectable rows in an `ax-data-table` grid and loads further