@acorex/components 20.2.0-next.19 → 20.2.0-next.20

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.
Files changed (37) hide show
  1. package/autocomplete/index.d.ts +6 -2
  2. package/data-list/README.md +356 -0
  3. package/data-list/index.d.ts +102 -0
  4. package/fesm2022/acorex-components-autocomplete.mjs +19 -3
  5. package/fesm2022/acorex-components-autocomplete.mjs.map +1 -1
  6. package/fesm2022/acorex-components-color-palette.mjs +1 -1
  7. package/fesm2022/acorex-components-color-palette.mjs.map +1 -1
  8. package/fesm2022/acorex-components-cron-job.mjs +6 -6
  9. package/fesm2022/acorex-components-cron-job.mjs.map +1 -1
  10. package/fesm2022/acorex-components-data-list.mjs +386 -0
  11. package/fesm2022/acorex-components-data-list.mjs.map +1 -0
  12. package/fesm2022/acorex-components-list.mjs +6 -14
  13. package/fesm2022/acorex-components-list.mjs.map +1 -1
  14. package/fesm2022/acorex-components-phone-box.mjs +1 -1
  15. package/fesm2022/acorex-components-phone-box.mjs.map +1 -1
  16. package/fesm2022/acorex-components-query-builder.mjs +1 -1
  17. package/fesm2022/acorex-components-query-builder.mjs.map +1 -1
  18. package/fesm2022/acorex-components-rest-api-generator.mjs +1 -1
  19. package/fesm2022/acorex-components-rest-api-generator.mjs.map +1 -1
  20. package/fesm2022/acorex-components-rrule.mjs +1 -1
  21. package/fesm2022/acorex-components-rrule.mjs.map +1 -1
  22. package/fesm2022/acorex-components-scheduler.mjs +1 -1
  23. package/fesm2022/acorex-components-scheduler.mjs.map +1 -1
  24. package/fesm2022/acorex-components-select-box.mjs +62 -19
  25. package/fesm2022/acorex-components-select-box.mjs.map +1 -1
  26. package/fesm2022/acorex-components-selection-list-2.mjs +5 -2
  27. package/fesm2022/acorex-components-selection-list-2.mjs.map +1 -1
  28. package/fesm2022/acorex-components-selection-list.mjs +7 -4
  29. package/fesm2022/acorex-components-selection-list.mjs.map +1 -1
  30. package/fesm2022/acorex-components-tag-box.mjs +24 -12
  31. package/fesm2022/acorex-components-tag-box.mjs.map +1 -1
  32. package/fesm2022/acorex-components-wysiwyg.mjs +1 -1
  33. package/fesm2022/acorex-components-wysiwyg.mjs.map +1 -1
  34. package/list/index.d.ts +3 -9
  35. package/package.json +13 -9
  36. package/select-box/index.d.ts +11 -2
  37. package/tag-box/index.d.ts +2 -2
@@ -1,7 +1,7 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { AfterViewInit, OnDestroy, TemplateRef } from '@angular/core';
3
3
  import * as polytype from 'polytype';
4
- import { MXSelectionValueComponent, MXLookComponent, AXDataSource, MXSelectionBridgeService, AXAutocompleteParentComponent, MXInputBaseValueComponent, AXEvent, AXValueChangedEvent } from '@acorex/cdk/common';
4
+ import { MXSelectionValueComponent, MXLookComponent, AXDataSource, MXSelectionBridgeService, AXAutocompleteParentComponent, MXInputBaseValueComponent, AXEvent, AXValueChangedEvent, AXItemClickEvent, AXItemSelectedEvent } from '@acorex/cdk/common';
5
5
  import { MXDropdownBoxBaseComponent, AXDropdownBoxComponent } from '@acorex/components/dropdown';
6
6
  import { AXListComponent } from '@acorex/components/list';
7
7
 
@@ -100,6 +100,10 @@ declare class AXAutocompleteComponent extends AXAutocompleteComponent_base imple
100
100
  /** @ignore */
101
101
  protected _handleValueChanged(e: AXValueChangedEvent): void;
102
102
  /** @ignore */
103
+ protected _handleItemClick(e: AXItemClickEvent): void;
104
+ /** @ignore */
105
+ protected _handleItemSelected(e: AXItemSelectedEvent): void;
106
+ /** @ignore */
103
107
  private setDropdownSize;
104
108
  /**
105
109
  * Filters the data source based on the provided search term.
@@ -112,7 +116,7 @@ declare class AXAutocompleteComponent extends AXAutocompleteComponent_base imple
112
116
  refresh(): void;
113
117
  private get __hostName();
114
118
  static ɵfac: i0.ɵɵFactoryDeclaration<AXAutocompleteComponent, never>;
115
- static ɵcmp: i0.ɵɵComponentDeclaration<AXAutocompleteComponent, "ax-autocomplete", never, { "disabled": { "alias": "disabled"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "tabIndex": { "alias": "tabIndex"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "minValue": { "alias": "minValue"; "required": false; }; "maxValue": { "alias": "maxValue"; "required": false; }; "value": { "alias": "value"; "required": false; }; "state": { "alias": "state"; "required": false; }; "name": { "alias": "name"; "required": false; }; "id": { "alias": "id"; "required": false; }; "type": { "alias": "type"; "required": false; }; "look": { "alias": "look"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "valueField": { "alias": "valueField"; "required": false; }; "textField": { "alias": "textField"; "required": false; }; "disabledField": { "alias": "disabledField"; "required": false; }; "textTemplate": { "alias": "textTemplate"; "required": false; }; "selectedItems": { "alias": "selectedItems"; "required": false; }; "delayTime": { "alias": "delayTime"; "required": false; "isSignal": true; }; "dataSource": { "alias": "dataSource"; "required": false; }; "caption": { "alias": "caption"; "required": false; }; "itemTemplate": { "alias": "itemTemplate"; "required": false; }; "selectedTemplate": { "alias": "selectedTemplate"; "required": false; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; }; "loadingTemplate": { "alias": "loadingTemplate"; "required": false; }; "dropdownWidth": { "alias": "dropdownWidth"; "required": false; }; }, { "valueChange": "valueChange"; "stateChange": "stateChange"; "onValueChanged": "onValueChanged"; "onBlur": "onBlur"; "onFocus": "onFocus"; "readonlyChange": "readonlyChange"; "disabledChange": "disabledChange"; "onOpened": "onOpened"; "onClosed": "onClosed"; }, never, ["ax-footer"], true, never>;
119
+ static ɵcmp: i0.ɵɵComponentDeclaration<AXAutocompleteComponent, "ax-autocomplete", never, { "disabled": { "alias": "disabled"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "tabIndex": { "alias": "tabIndex"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "minValue": { "alias": "minValue"; "required": false; }; "maxValue": { "alias": "maxValue"; "required": false; }; "value": { "alias": "value"; "required": false; }; "state": { "alias": "state"; "required": false; }; "name": { "alias": "name"; "required": false; }; "id": { "alias": "id"; "required": false; }; "type": { "alias": "type"; "required": false; }; "look": { "alias": "look"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "valueField": { "alias": "valueField"; "required": false; }; "textField": { "alias": "textField"; "required": false; }; "disabledField": { "alias": "disabledField"; "required": false; }; "textTemplate": { "alias": "textTemplate"; "required": false; }; "selectedItems": { "alias": "selectedItems"; "required": false; }; "delayTime": { "alias": "delayTime"; "required": false; "isSignal": true; }; "dataSource": { "alias": "dataSource"; "required": false; }; "caption": { "alias": "caption"; "required": false; }; "itemTemplate": { "alias": "itemTemplate"; "required": false; }; "selectedTemplate": { "alias": "selectedTemplate"; "required": false; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; }; "loadingTemplate": { "alias": "loadingTemplate"; "required": false; }; "dropdownWidth": { "alias": "dropdownWidth"; "required": false; }; }, { "valueChange": "valueChange"; "stateChange": "stateChange"; "onValueChanged": "onValueChanged"; "onBlur": "onBlur"; "onFocus": "onFocus"; "readonlyChange": "readonlyChange"; "disabledChange": "disabledChange"; "onOpened": "onOpened"; "onClosed": "onClosed"; "onItemClick": "onItemClick"; "onItemSelected": "onItemSelected"; }, never, ["ax-footer"], true, never>;
116
120
  }
117
121
 
118
122
  declare class AXAutocompleteModule {
@@ -0,0 +1,356 @@
1
+ # @acorex/components/data-list
2
+
3
+ Secondary entry point of `@acorex/components`. It can be used by importing from `@acorex/components/data-list`.
4
+
5
+ ## Overview
6
+
7
+ `AXDataList` is a modern, signal-based Angular data list component that provides virtual scrolling, selection management, and tree grouping capabilities. It's designed to replace the existing `AXListComponent` with improved performance and modern Angular patterns.
8
+
9
+ ## Key Features
10
+
11
+ ### Core Functionality
12
+
13
+ - ✅ **Virtual Scrolling** - CDK-based virtual scrolling for large datasets
14
+ - ✅ **Selection Management** - Single and multiple selection modes
15
+ - ✅ **Tree Grouping** - Hierarchical item organization with expand/collapse
16
+ - ✅ **Template System** - Custom templates for items, loading, and empty states
17
+ - ✅ **Keyboard Navigation** - Full keyboard accessibility
18
+ - ✅ **Modern Angular** - Signal-based architecture for optimal performance
19
+
20
+ ### Advanced Features
21
+
22
+ - ✅ **Disabled Items** - Field-based item disabling with visual and behavioral support
23
+ - ✅ **Tooltip Support** - Custom tooltip content via field mapping
24
+ - ✅ **Checkbox Control** - Configurable checkbox display and behavior
25
+ - ✅ **Search API** - External search integration (not built-in)
26
+
27
+ ## Component Architecture
28
+
29
+ ### Base Class
30
+
31
+ - **Inherits from**: `MXValueComponent` (instead of `MXSelectionValueComponent`)
32
+ - **Change Detection**: `OnPush` strategy
33
+ - **Encapsulation**: `ViewEncapsulation.None`
34
+
35
+ ### Dependencies
36
+
37
+ - `@angular/cdk/scrolling` - Virtual scrolling
38
+ - `@angular/forms` - Form integration
39
+ - `@acorex/cdk/common` - Base components and utilities
40
+
41
+ ## Input Properties
42
+
43
+ ### Basic Properties
44
+
45
+ | Property | Type | Default | Description |
46
+ | ---------- | --------- | ------- | ---------------------------- |
47
+ | `id` | `string` | - | Component identifier |
48
+ | `name` | `string` | - | Component name for forms |
49
+ | `disabled` | `boolean` | `false` | Disable the entire component |
50
+ | `readonly` | `boolean` | `false` | Make component read-only |
51
+ | `tabIndex` | `number` | `0` | Tab order |
52
+
53
+ ### Data & Selection
54
+
55
+ | Property | Type | Default | Description |
56
+ | --------------- | ----------------------- | -------- | -------------------------------- |
57
+ | `dataSource` | `AXDataSource<unknown>` | `[]` | Data source for the list |
58
+ | `value` | `unknown \| unknown[]` | - | Current selected value(s) |
59
+ | `valueField` | `string` | `'id'` | Field name for item value |
60
+ | `textField` | `string` | `'text'` | Field name for item display text |
61
+ | `multiple` | `boolean` | `false` | Enable multiple selection |
62
+ | `selectionMode` | `string` | `'item'` | Selection behavior |
63
+
64
+ ### Display & Behavior
65
+
66
+ | Property | Type | Default | Description |
67
+ | ----------------- | ------------------ | ------- | --------------------------------- |
68
+ | `itemHeight` | `number \| 'auto'` | `40` | Height of each list item |
69
+ | `isItemTruncated` | `boolean` | `true` | Enable text truncation |
70
+ | `showItemTooltip` | `boolean` | `false` | Show tooltips for truncated items |
71
+ | `showCheckbox` | `boolean` | `true` | Show checkboxes for selection |
72
+
73
+ ### Field Mappings
74
+
75
+ | Property | Type | Default | Description |
76
+ | --------------- | -------- | ------- | ------------------------------------------- |
77
+ | `disabledField` | `string` | - | Field name to determine if item is disabled |
78
+ | `tooltipField` | `string` | - | Field name for custom tooltip content |
79
+
80
+ ### Tree Grouping
81
+
82
+ | Property | Type | Default | Description |
83
+ | -------------------- | ------------- | ------------ | --------------------------------- |
84
+ | `childrenField` | `string` | `'children'` | Field name containing child items |
85
+ | `expandedField` | `string` | `'expanded'` | Field name for expanded state |
86
+ | `levelField` | `string` | `'level'` | Field name for nesting level |
87
+ | `groupTemplate` | `TemplateRef` | - | Template for group headers |
88
+ | `expandIconTemplate` | `TemplateRef` | - | Custom expand/collapse icons |
89
+
90
+ ### Templates
91
+
92
+ | Property | Type | Default | Description |
93
+ | ----------------- | ------------- | ------- | ------------------------------ |
94
+ | `itemTemplate` | `TemplateRef` | - | Custom template for list items |
95
+ | `emptyTemplate` | `TemplateRef` | - | Template for empty state |
96
+ | `loadingTemplate` | `TemplateRef` | - | Template for loading state |
97
+ | `textTemplate` | `TemplateRef` | - | Custom text display template |
98
+
99
+ ## Output Events
100
+
101
+ ### Value & Selection Events
102
+
103
+ | Event | Type | Description |
104
+ | -------------------- | ------------------------- | ----------------------- |
105
+ | `onValueChanged` | `AXValueChangedEvent` | Value selection changed |
106
+ | `onItemClick` | `AXItemClickEvent` | Item clicked |
107
+ | `onItemSelected` | `AXItemSelectedEvent` | Item selection changed |
108
+ | `onSelectionChanged` | `AXSelectionChangedEvent` | Selection state changed |
109
+
110
+ ### Focus & Interaction Events
111
+
112
+ | Event | Type | Description |
113
+ | ----------- | ---------------- | ---------------------- |
114
+ | `onBlur` | `AXBlurEvent` | Component lost focus |
115
+ | `onFocus` | `AXFocusEvent` | Component gained focus |
116
+ | `onKeyDown` | `AXKeyDownEvent` | Key pressed |
117
+
118
+ ### Data & State Events
119
+
120
+ | Event | Type | Description |
121
+ | ------------------------ | -------------------------- | ----------------------- |
122
+ | `onScrolledIndexChanged` | `AXListScrollIndexChanged` | Scroll position changed |
123
+ | `onLoadingChanged` | `AXLoadingChangedEvent` | Loading state changed |
124
+ | `onDataChanged` | `AXDataChangedEvent` | Data source changed |
125
+
126
+ ### Tree Grouping Events
127
+
128
+ | Event | Type | Description |
129
+ | ----------------- | ---------------------- | ----------------------------- |
130
+ | `onItemExpanded` | `AXItemExpandedEvent` | Item expanded |
131
+ | `onItemCollapsed` | `AXItemCollapsedEvent` | Item collapsed |
132
+ | `onGroupToggle` | `AXGroupToggleEvent` | Group expand/collapse toggled |
133
+
134
+ ## Public API Methods
135
+
136
+ ### Selection Management
137
+
138
+ | Method | Parameters | Return | Description |
139
+ | ---------------------- | --------------- | ----------- | ----------------------------- |
140
+ | `selectItem(item)` | `item: unknown` | `void` | Select specific item |
141
+ | `deselectItem(item)` | `item: unknown` | `void` | Deselect specific item |
142
+ | `clearSelection()` | - | `void` | Clear all selections |
143
+ | `getSelectedItems()` | - | `unknown[]` | Get currently selected items |
144
+ | `isItemSelected(item)` | `item: unknown` | `boolean` | Check if item is selected |
145
+ | `isItemDisabled(item)` | `item: unknown` | `boolean` | Check if item is disabled |
146
+ | `canSelectItem(item)` | `item: unknown` | `boolean` | Check if item can be selected |
147
+
148
+ ### Navigation & Focus
149
+
150
+ | Method | Parameters | Return | Description |
151
+ | ---------------------- | --------------- | ------ | ---------------------------- |
152
+ | `focus()` | - | `void` | Focus the component |
153
+ | `focusItem(index)` | `index: number` | `void` | Focus specific item by index |
154
+ | `focusNextItem()` | - | `void` | Focus next item |
155
+ | `focusPreviousItem()` | - | `void` | Focus previous item |
156
+ | `scrollToIndex(index)` | `index: number` | `void` | Scroll to specific index |
157
+
158
+ ### Data & State
159
+
160
+ | Method | Parameters | Return | Description |
161
+ | ----------------------- | --------------- | ----------- | --------------------------- |
162
+ | `refresh()` | - | `void` | Refresh data source |
163
+ | `getItemByKey(key)` | `key: unknown` | `unknown` | Get item by key |
164
+ | `getItemByIndex(index)` | `index: number` | `unknown` | Get item by index |
165
+ | `getVisibleItems()` | - | `unknown[]` | Get items currently visible |
166
+
167
+ ### Tree Grouping
168
+
169
+ | Method | Parameters | Return | Description |
170
+ | ---------------------- | --------------- | ----------- | ------------------------- |
171
+ | `expandItem(item)` | `item: unknown` | `void` | Expand group |
172
+ | `collapseItem(item)` | `item: unknown` | `void` | Collapse group |
173
+ | `toggleExpanded(item)` | `item: unknown` | `void` | Toggle expand/collapse |
174
+ | `expandAll()` | - | `void` | Expand all groups |
175
+ | `collapseAll()` | - | `void` | Collapse all groups |
176
+ | `isExpanded(item)` | `item: unknown` | `boolean` | Check if item is expanded |
177
+ | `getItemLevel(item)` | `item: unknown` | `number` | Get nesting level |
178
+ | `getParentItem(item)` | `item: unknown` | `unknown` | Get parent item |
179
+ | `getChildItems(item)` | `item: unknown` | `unknown[]` | Get child items |
180
+
181
+ ### Viewport Management
182
+
183
+ | Method | Parameters | Return | Description |
184
+ | --------------------- | ---------- | ------ | -------------------------- |
185
+ | `render()` | - | `void` | Re-render the component |
186
+ | `checkViewportSize()` | - | `void` | Update viewport dimensions |
187
+ | `scrollToTop()` | - | `void` | Scroll to top |
188
+ | `scrollToBottom()` | - | `void` | Scroll to bottom |
189
+
190
+ ## Template Context Variables
191
+
192
+ ### Standard Item Context
193
+
194
+ | Variable | Type | Description |
195
+ | ----------- | --------- | --------------- |
196
+ | `$implicit` | `unknown` | The item data |
197
+ | `index` | `number` | Item index |
198
+ | `selected` | `boolean` | Selection state |
199
+ | `disabled` | `boolean` | Disabled state |
200
+ | `first` | `boolean` | First item flag |
201
+ | `last` | `boolean` | Last item flag |
202
+ | `even` | `boolean` | Even index flag |
203
+ | `odd` | `boolean` | Odd index flag |
204
+
205
+ ### Tree Grouping Context
206
+
207
+ | Variable | Type | Description |
208
+ | ------------- | ----------- | ------------------------------ |
209
+ | `level` | `number` | Nesting level (0, 1, 2, etc.) |
210
+ | `isGroup` | `boolean` | Whether item is a group/parent |
211
+ | `isExpanded` | `boolean` | Whether group is expanded |
212
+ | `hasChildren` | `boolean` | Whether item has children |
213
+ | `parent` | `unknown` | Reference to parent item |
214
+ | `children` | `unknown[]` | Child items array |
215
+
216
+ ## Behavior Specifications
217
+
218
+ ### Disabled Items
219
+
220
+ - **Visual**: Grayed out appearance with reduced opacity
221
+ - **Focus**: Disabled items are focusable but not selectable
222
+ - **Navigation**: Skipped in keyboard navigation (Arrow keys)
223
+ - **Selection**: Cannot be selected or deselected
224
+ - **Checkbox**: Disabled checkboxes for disabled items
225
+
226
+ ### Tooltip Behavior
227
+
228
+ - **Custom Tooltip**: `tooltipField` provides custom tooltip content
229
+ - **Default Tooltip**: Shows on hover regardless of truncation
230
+ - **Priority**: Custom tooltip overrides default text tooltip
231
+
232
+ ### Checkbox Behavior
233
+
234
+ - **Display**: Controlled by `showCheckbox` input
235
+ - **State**: Disabled items show disabled checkboxes
236
+ - **Group Headers**: Can show checkboxes for "select all children" behavior
237
+ - **Behavior Options**: Configurable checkbox interaction patterns
238
+
239
+ ### Tree Grouping Behavior
240
+
241
+ - **Expand/Collapse**: Click on group header or expand icon
242
+ - **Selection**: Group selection can affect child selection
243
+ - **Navigation**: Keyboard navigation respects expanded/collapsed state
244
+ - **Performance**: Virtual scrolling optimized for tree structures
245
+
246
+ ## CSS Classes & Styling
247
+
248
+ ### Container Classes
249
+
250
+ - `.ax-list-container` - Main container
251
+ - `.ax-list-container.ax-height-auto` - Auto height mode
252
+ - `.ax-list-container.ax-tree-mode` - Tree grouping mode
253
+
254
+ ### Item Classes
255
+
256
+ - `.ax-list-item` - Individual items
257
+ - `.ax-list-item.ax-state-selected` - Selected state
258
+ - `.ax-list-item.ax-state-disabled` - Disabled state
259
+ - `.ax-list-item.ax-state-focused` - Focused state
260
+ - `.ax-list-item.ax-state-loading` - Loading state
261
+ - `.ax-list-item.ax-state-empty` - Empty state
262
+
263
+ ### Tree Grouping Classes
264
+
265
+ - `.ax-list-item.ax-group-header` - Group header items
266
+ - `.ax-list-item.ax-group-expanded` - Expanded group
267
+ - `.ax-list-item.ax-group-collapsed` - Collapsed group
268
+ - `.ax-list-item.ax-group-child` - Child items
269
+ - `.ax-list-item.ax-level-{n}` - Nesting level styling
270
+
271
+ ### State Classes
272
+
273
+ - `.ax-list-item.ax-level-0` - Root level items
274
+ - `.ax-list-item.ax-level-1` - First level nested items
275
+ - `.ax-list-item.ax-level-2` - Second level nested items
276
+ - `.ax-list-item.ax-has-children` - Items with children
277
+ - `.ax-list-item.ax-no-children` - Items without children
278
+
279
+ ## Performance Considerations
280
+
281
+ ### Virtual Scrolling
282
+
283
+ - **Item Size**: Fixed item height for optimal performance
284
+ - **Viewport Management**: Efficient viewport size calculations
285
+ - **Memory Usage**: Minimal DOM elements for large datasets
286
+
287
+ ### Signal Optimization
288
+
289
+ - **Change Detection**: Signal-based updates for minimal re-renders
290
+ - **Computed Values**: Efficient computed signals for derived state
291
+ - **Memory Management**: Proper signal cleanup and disposal
292
+
293
+ ### Tree Grouping Performance
294
+
295
+ - **Lazy Loading**: Children loaded on demand
296
+ - **Virtual Scrolling**: Optimized for hierarchical structures
297
+ - **Selection Caching**: Efficient selection state management
298
+
299
+ ## Migration Guide
300
+
301
+ ### From AXListComponent
302
+
303
+ - **Component Name**: Change from `ax-list` to `ax-data-list`
304
+ - **Base Class**: Change from `MXSelectionValueComponent` to `MXValueComponent`
305
+ - **Inputs**: Update input property names (e.g., `checkbox` → `showCheckbox`)
306
+ - **Events**: Update event handler names
307
+ - **Templates**: Ensure template context compatibility
308
+
309
+ ### Breaking Changes
310
+
311
+ - **Selection API**: Simplified selection management
312
+ - **Event Names**: Updated event naming conventions
313
+ - **Template Context**: Enhanced context variables for tree grouping
314
+
315
+ ## Future Enhancements
316
+
317
+ ### Planned Features
318
+
319
+ - **Drag & Drop**: Item reordering and tree restructuring
320
+ - **Filtering**: Client-side filtering capabilities
321
+ - **Sorting**: Multi-column sorting support
322
+ - **Pagination**: Built-in pagination controls
323
+ - **Export**: Data export functionality
324
+
325
+ ### Performance Improvements
326
+
327
+ - **Web Workers**: Background data processing
328
+ - **Service Workers**: Offline data caching
329
+ - **IndexedDB**: Local data persistence
330
+ - **WebAssembly**: High-performance data operations
331
+
332
+ ## Implementation Notes
333
+
334
+ ### Development Phases
335
+
336
+ 1. **Phase 1**: Core functionality with virtual scrolling
337
+ 2. **Phase 2**: Selection management and templates
338
+ 3. **Phase 3**: Tree grouping implementation
339
+ 4. **Phase 4**: Advanced features and optimizations
340
+
341
+ ### Testing Strategy
342
+
343
+ - **Unit Tests**: Component logic and API methods
344
+ - **Integration Tests**: Template system and data binding
345
+ - **Performance Tests**: Virtual scrolling and large datasets
346
+ - **Accessibility Tests**: Keyboard navigation and screen readers
347
+
348
+ ### Browser Support
349
+
350
+ - **Modern Browsers**: Chrome 90+, Firefox 88+, Safari 14+
351
+ - **Mobile**: iOS Safari 14+, Chrome Mobile 90+
352
+ - **Fallbacks**: Graceful degradation for older browsers
353
+
354
+ ---
355
+
356
+ _This README serves as the complete specification for AXListComponent2 development and implementation._
@@ -0,0 +1,102 @@
1
+ import * as _angular_core from '@angular/core';
2
+ import { OnInit, TemplateRef, EventEmitter } from '@angular/core';
3
+ import { CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
4
+ import { MXValueComponent, AXDataSource, AXListDataSource } from '@acorex/cdk/common';
5
+
6
+ interface AXDataListItem {
7
+ id: string;
8
+ text: string;
9
+ description?: string;
10
+ disabled?: boolean;
11
+ tooltip?: string;
12
+ level?: number;
13
+ children?: AXDataListItem[];
14
+ expanded?: boolean;
15
+ [key: string]: any;
16
+ }
17
+ interface AXDataListConfig {
18
+ disabledField?: string;
19
+ tooltipField?: string;
20
+ textField?: string;
21
+ descriptionField?: string;
22
+ levelField?: string;
23
+ childrenField?: string;
24
+ expandedField?: string;
25
+ }
26
+ interface AXDataListSelectionChange {
27
+ selectedItems: AXDataListItem[];
28
+ selectedKeys: string[];
29
+ isMultiple: boolean;
30
+ }
31
+ declare class AXDataListComponent extends MXValueComponent implements OnInit {
32
+ dataSource: _angular_core.InputSignal<AXDataSource<AXDataListItem>>;
33
+ config: _angular_core.InputSignal<AXDataListConfig>;
34
+ multiple: _angular_core.InputSignal<boolean>;
35
+ showCheckbox: _angular_core.InputSignal<boolean>;
36
+ itemHeight: _angular_core.InputSignal<number>;
37
+ isItemTruncated: _angular_core.InputSignal<boolean>;
38
+ showItemTooltip: _angular_core.InputSignal<boolean>;
39
+ disabledField: _angular_core.InputSignal<string>;
40
+ tooltipField: _angular_core.InputSignal<string>;
41
+ textField: _angular_core.InputSignal<string>;
42
+ descriptionField: _angular_core.InputSignal<string>;
43
+ levelField: _angular_core.InputSignal<string>;
44
+ childrenField: _angular_core.InputSignal<string>;
45
+ expandedField: _angular_core.InputSignal<string>;
46
+ itemTemplate: _angular_core.InputSignal<TemplateRef<any>>;
47
+ emptyTemplate: _angular_core.InputSignal<TemplateRef<any>>;
48
+ loadingTemplate: _angular_core.InputSignal<TemplateRef<any>>;
49
+ selectionChange: EventEmitter<AXDataListSelectionChange>;
50
+ itemClick: EventEmitter<AXDataListItem>;
51
+ itemDoubleClick: EventEmitter<AXDataListItem>;
52
+ expandChange: EventEmitter<{
53
+ item: AXDataListItem;
54
+ expanded: boolean;
55
+ }>;
56
+ viewport: CdkVirtualScrollViewport;
57
+ protected loading: _angular_core.WritableSignal<boolean>;
58
+ protected totalItems: _angular_core.WritableSignal<number>;
59
+ protected selectedItems: _angular_core.WritableSignal<AXDataListItem[]>;
60
+ protected selectedKeys: _angular_core.WritableSignal<string[]>;
61
+ protected focusedIndex: _angular_core.WritableSignal<number>;
62
+ protected expandedItems: _angular_core.WritableSignal<Set<string>>;
63
+ protected listDataSource: AXListDataSource<AXDataListItem> | null;
64
+ protected hasItems: _angular_core.Signal<boolean>;
65
+ protected isEmpty: _angular_core.Signal<boolean>;
66
+ protected isMultipleSelection: _angular_core.Signal<boolean>;
67
+ protected showCheckboxes: _angular_core.Signal<boolean>;
68
+ selectionModel: _angular_core.ModelSignal<string | string[]>;
69
+ constructor();
70
+ ngOnInit(): void;
71
+ private setupDataSourceSubscription;
72
+ protected selectItem(item: AXDataListItem, event?: Event): void;
73
+ protected toggleMultipleSelection(item: AXDataListItem): void;
74
+ protected setSingleSelection(item: AXDataListItem): void;
75
+ protected deselectItem(item: AXDataListItem): void;
76
+ protected updateSelectedItems(): void;
77
+ protected isItemSelected(item: AXDataListItem): boolean;
78
+ protected isItemDisabled(item: AXDataListItem): boolean;
79
+ protected getItemKey(item: AXDataListItem): string;
80
+ protected toggleExpanded(item: AXDataListItem, event: Event): void;
81
+ protected hasChildren(item: AXDataListItem): boolean;
82
+ protected isExpanded(item: AXDataListItem): boolean;
83
+ protected getItemLevel(item: AXDataListItem): number;
84
+ protected onKeyDown(event: KeyboardEvent, item: AXDataListItem, index: number): void;
85
+ protected focusNextItem(currentIndex: number): void;
86
+ protected focusPreviousItem(currentIndex: number): void;
87
+ protected scrollToIndex(index: number): void;
88
+ protected onItemClick(item: AXDataListItem, event: Event): void;
89
+ protected onCheckboxChange(item: AXDataListItem, checked: boolean): void;
90
+ protected onCheckboxClick(event: Event): void;
91
+ protected onItemDoubleClick(item: AXDataListItem): void;
92
+ protected getItemText(item: AXDataListItem): string;
93
+ protected getItemDescription(item: AXDataListItem): string;
94
+ protected getItemTooltip(item: AXDataListItem): string;
95
+ protected shouldShowTooltip(item: AXDataListItem): boolean;
96
+ protected trackByFn: (index: number, item: AXDataListItem) => string;
97
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXDataListComponent, never>;
98
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXDataListComponent, "ax-data-list", never, { "dataSource": { "alias": "dataSource"; "required": true; "isSignal": true; }; "config": { "alias": "config"; "required": false; "isSignal": true; }; "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; "showCheckbox": { "alias": "showCheckbox"; "required": false; "isSignal": true; }; "itemHeight": { "alias": "itemHeight"; "required": false; "isSignal": true; }; "isItemTruncated": { "alias": "isItemTruncated"; "required": false; "isSignal": true; }; "showItemTooltip": { "alias": "showItemTooltip"; "required": false; "isSignal": true; }; "disabledField": { "alias": "disabledField"; "required": false; "isSignal": true; }; "tooltipField": { "alias": "tooltipField"; "required": false; "isSignal": true; }; "textField": { "alias": "textField"; "required": false; "isSignal": true; }; "descriptionField": { "alias": "descriptionField"; "required": false; "isSignal": true; }; "levelField": { "alias": "levelField"; "required": false; "isSignal": true; }; "childrenField": { "alias": "childrenField"; "required": false; "isSignal": true; }; "expandedField": { "alias": "expandedField"; "required": false; "isSignal": true; }; "itemTemplate": { "alias": "itemTemplate"; "required": false; "isSignal": true; }; "emptyTemplate": { "alias": "emptyTemplate"; "required": false; "isSignal": true; }; "loadingTemplate": { "alias": "loadingTemplate"; "required": false; "isSignal": true; }; "selectionModel": { "alias": "selectionModel"; "required": false; "isSignal": true; }; }, { "selectionChange": "selectionChange"; "itemClick": "itemClick"; "itemDoubleClick": "itemDoubleClick"; "expandChange": "expandChange"; "selectionModel": "selectionModelChange"; }, never, never, true, never>;
99
+ }
100
+
101
+ export { AXDataListComponent };
102
+ export type { AXDataListConfig, AXDataListItem, AXDataListSelectionChange };
@@ -161,6 +161,20 @@ class AXAutocompleteComponent extends classes(MXDropdownBoxBaseComponent, MXSele
161
161
  }
162
162
  }
163
163
  /** @ignore */
164
+ _handleItemClick(e) {
165
+ this.onItemClick.emit(e);
166
+ if (!this.multiple) {
167
+ this.close();
168
+ }
169
+ }
170
+ /** @ignore */
171
+ _handleItemSelected(e) {
172
+ this.onItemSelected.emit(e);
173
+ if (!this.multiple) {
174
+ this.close();
175
+ }
176
+ }
177
+ /** @ignore */
164
178
  setDropdownSize(count = 0) {
165
179
  if (this.dropdown.isActionsheetStyle) {
166
180
  this.dropdownSizes = {
@@ -211,7 +225,7 @@ class AXAutocompleteComponent extends classes(MXDropdownBoxBaseComponent, MXSele
211
225
  return this.name;
212
226
  }
213
227
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.8", ngImport: i0, type: AXAutocompleteComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
214
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.8", type: AXAutocompleteComponent, isStandalone: true, selector: "ax-autocomplete", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: false, isRequired: false, transformFunction: null }, tabIndex: { classPropertyName: "tabIndex", publicName: "tabIndex", isSignal: false, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: false, isRequired: false, transformFunction: null }, minValue: { classPropertyName: "minValue", publicName: "minValue", isSignal: false, isRequired: false, transformFunction: null }, maxValue: { classPropertyName: "maxValue", publicName: "maxValue", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: false, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: false, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: false, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: false, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: false, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: false, isRequired: false, transformFunction: null }, valueField: { classPropertyName: "valueField", publicName: "valueField", isSignal: false, isRequired: false, transformFunction: null }, textField: { classPropertyName: "textField", publicName: "textField", isSignal: false, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: false, isRequired: false, transformFunction: null }, textTemplate: { classPropertyName: "textTemplate", publicName: "textTemplate", isSignal: false, isRequired: false, transformFunction: null }, selectedItems: { classPropertyName: "selectedItems", publicName: "selectedItems", isSignal: false, isRequired: false, transformFunction: null }, delayTime: { classPropertyName: "delayTime", publicName: "delayTime", isSignal: true, isRequired: false, transformFunction: null }, dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: false, isRequired: false, transformFunction: null }, caption: { classPropertyName: "caption", publicName: "caption", isSignal: false, isRequired: false, transformFunction: null }, itemTemplate: { classPropertyName: "itemTemplate", publicName: "itemTemplate", isSignal: false, isRequired: false, transformFunction: null }, selectedTemplate: { classPropertyName: "selectedTemplate", publicName: "selectedTemplate", isSignal: false, isRequired: false, transformFunction: null }, emptyTemplate: { classPropertyName: "emptyTemplate", publicName: "emptyTemplate", isSignal: false, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: false, isRequired: false, transformFunction: null }, dropdownWidth: { classPropertyName: "dropdownWidth", publicName: "dropdownWidth", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", onBlur: "onBlur", onFocus: "onFocus", readonlyChange: "readonlyChange", disabledChange: "disabledChange", onOpened: "onOpened", onClosed: "onClosed" }, host: { attributes: { "ngSkipHydration": "true" }, properties: { "attr.name": "this.__hostName" } }, providers: [
228
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.1.8", type: AXAutocompleteComponent, isStandalone: true, selector: "ax-autocomplete", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: false, isRequired: false, transformFunction: null }, tabIndex: { classPropertyName: "tabIndex", publicName: "tabIndex", isSignal: false, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: false, isRequired: false, transformFunction: null }, minValue: { classPropertyName: "minValue", publicName: "minValue", isSignal: false, isRequired: false, transformFunction: null }, maxValue: { classPropertyName: "maxValue", publicName: "maxValue", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: false, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: false, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: false, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: false, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: false, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: false, isRequired: false, transformFunction: null }, valueField: { classPropertyName: "valueField", publicName: "valueField", isSignal: false, isRequired: false, transformFunction: null }, textField: { classPropertyName: "textField", publicName: "textField", isSignal: false, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: false, isRequired: false, transformFunction: null }, textTemplate: { classPropertyName: "textTemplate", publicName: "textTemplate", isSignal: false, isRequired: false, transformFunction: null }, selectedItems: { classPropertyName: "selectedItems", publicName: "selectedItems", isSignal: false, isRequired: false, transformFunction: null }, delayTime: { classPropertyName: "delayTime", publicName: "delayTime", isSignal: true, isRequired: false, transformFunction: null }, dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: false, isRequired: false, transformFunction: null }, caption: { classPropertyName: "caption", publicName: "caption", isSignal: false, isRequired: false, transformFunction: null }, itemTemplate: { classPropertyName: "itemTemplate", publicName: "itemTemplate", isSignal: false, isRequired: false, transformFunction: null }, selectedTemplate: { classPropertyName: "selectedTemplate", publicName: "selectedTemplate", isSignal: false, isRequired: false, transformFunction: null }, emptyTemplate: { classPropertyName: "emptyTemplate", publicName: "emptyTemplate", isSignal: false, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: false, isRequired: false, transformFunction: null }, dropdownWidth: { classPropertyName: "dropdownWidth", publicName: "dropdownWidth", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", onBlur: "onBlur", onFocus: "onFocus", readonlyChange: "readonlyChange", disabledChange: "disabledChange", onOpened: "onOpened", onClosed: "onClosed", onItemClick: "onItemClick", onItemSelected: "onItemSelected" }, host: { attributes: { "ngSkipHydration": "true" }, properties: { "attr.name": "this.__hostName" } }, providers: [
215
229
  { provide: AXComponent, useExisting: AXAutocompleteComponent },
216
230
  { provide: AXFocusableComponent, useExisting: AXAutocompleteComponent },
217
231
  { provide: AXValuableComponent, useExisting: AXAutocompleteComponent },
@@ -228,7 +242,7 @@ class AXAutocompleteComponent extends classes(MXDropdownBoxBaseComponent, MXSele
228
242
  useClass: MXSelectionBridgeService,
229
243
  },
230
244
  AXUnsubscriber,
231
- ], viewQueries: [{ propertyName: "list", first: true, predicate: AXListComponent, descendants: true }, { propertyName: "dropdown", first: true, predicate: AXDropdownBoxComponent, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ax-dropdown-box\n [look]=\"look\"\n [hasInput]=\"false\"\n [disabled]=\"disabled\"\n (blur)=\"emitOnBlurEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n [class.ax-state-multiple]=\"multiple\"\n (onOpened)=\"_handleOnOpenedEvent($event)\"\n (onClosed)=\"_handleOnClosedEvent($event)\"\n>\n <ng-container panel>\n <div #panel class=\"ax-autocomplete-panel\" [style.min-width]=\"dropdownSizes.width\">\n @if (dropdown.isActionsheetStyle) {\n <ax-header class=\"ax-solid\">\n <ax-title>{{ caption || placeholder | translate | async }}</ax-title>\n <ax-close-button [icon]=\"multiple ? 'ax-icon ax-icon-check' : 'ax-icon ax-icon-close'\"></ax-close-button>\n </ax-header>\n }\n @if (renderList) {\n <ax-list\n [ngModel]=\"value\"\n [readonly]=\"readonly\"\n [multiple]=\"multiple\"\n [textField]=\"textField\"\n [selectionMode]=\"'item'\"\n [valueField]=\"valueField\"\n [textTemplate]=\"textTemplate\"\n [itemTemplate]=\"itemTemplate\"\n [dataSource]=\"_listDataSource\"\n [loadingTemplate]=\"loadingTemplate\"\n [style.height]=\"dropdownSizes.height\"\n [emptyTemplate]=\"emptyTemplate ?? empty\"\n (onValueChanged)=\"_handleValueChanged($event)\"\n >\n <ng-template #empty> {{ '@acorex:common.general.no-result-found' | translate | async }} </ng-template>\n </ax-list>\n }\n\n @if (isLoading()) {\n @if (loadingTemplate) {\n <ng-template [ngTemplateOutlet]=\"loadingTemplate\"></ng-template>\n } @else {\n <div class=\"ax-autocomplete-loading-container\">\n <ax-loading></ax-loading>\n </div>\n }\n }\n\n <ng-content select=\"ax-footer\"> </ng-content>\n </div>\n </ng-container>\n</ax-dropdown-box>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: AXListComponent, selector: "ax-list", inputs: ["id", "name", "disabled", "readonly", "valueField", "textField", "textTemplate", "disabledField", "multiple", "selectionMode", "isItemTruncated", "showItemTooltip", "dataSource", "itemHeight", "itemTemplate", "emptyTemplate", "loadingTemplate", "checkbox"], outputs: ["onValueChanged", "disabledChange", "readonlyChange", "onBlur", "onFocus", "onItemClick", "onScrolledIndexChanged"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "component", type: AXDropdownBoxComponent, selector: "ax-dropdown-box", inputs: ["disabled", "look", "hasInput", "popoverWidth"], outputs: ["disabledChange", "onBlur", "onFocus", "onClick", "onOpened", "onClosed"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "component", type: AXDecoratorCloseButtonComponent, selector: "ax-close-button", inputs: ["closeAll", "icon"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
245
+ ], viewQueries: [{ propertyName: "list", first: true, predicate: AXListComponent, descendants: true }, { propertyName: "dropdown", first: true, predicate: AXDropdownBoxComponent, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ax-dropdown-box\n [look]=\"look\"\n [hasInput]=\"false\"\n [disabled]=\"disabled\"\n (blur)=\"emitOnBlurEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n [class.ax-state-multiple]=\"multiple\"\n (onOpened)=\"_handleOnOpenedEvent($event)\"\n (onClosed)=\"_handleOnClosedEvent($event)\"\n>\n <ng-container panel>\n <div #panel class=\"ax-autocomplete-panel\" [style.min-width]=\"dropdownSizes.width\">\n @if (dropdown.isActionsheetStyle) {\n <ax-header class=\"ax-solid\">\n <ax-title>{{ caption || placeholder | translate | async }}</ax-title>\n <ax-close-button [icon]=\"multiple ? 'ax-icon ax-icon-check' : 'ax-icon ax-icon-close'\"></ax-close-button>\n </ax-header>\n }\n @if (renderList) {\n <ax-list\n [ngModel]=\"value\"\n [readonly]=\"readonly\"\n [multiple]=\"multiple\"\n [textField]=\"textField\"\n [selectionMode]=\"'item'\"\n [valueField]=\"valueField\"\n [textTemplate]=\"textTemplate\"\n [itemTemplate]=\"itemTemplate\"\n [dataSource]=\"_listDataSource\"\n [loadingTemplate]=\"loadingTemplate\"\n [style.height]=\"dropdownSizes.height\"\n [emptyTemplate]=\"emptyTemplate ?? empty\"\n (onValueChanged)=\"_handleValueChanged($event)\"\n (onItemClick)=\"_handleItemClick($event)\"\n (onItemSelected)=\"_handleItemSelected($event)\"\n >\n <ng-template #empty> {{ '@acorex:common.general.no-result-found' | translate | async }} </ng-template>\n </ax-list>\n }\n\n @if (isLoading()) {\n @if (loadingTemplate) {\n <ng-template [ngTemplateOutlet]=\"loadingTemplate\"></ng-template>\n } @else {\n <div class=\"ax-autocomplete-loading-container\">\n <ax-loading></ax-loading>\n </div>\n }\n }\n\n <ng-content select=\"ax-footer\"> </ng-content>\n </div>\n </ng-container>\n</ax-dropdown-box>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: AXListComponent, selector: "ax-list", inputs: ["id", "name", "disabled", "readonly", "valueField", "textField", "textTemplate", "disabledField", "multiple", "selectionMode", "isItemTruncated", "showItemTooltip", "dataSource", "itemHeight", "itemTemplate", "emptyTemplate", "loadingTemplate", "checkbox"], outputs: ["onValueChanged", "disabledChange", "readonlyChange", "onBlur", "onFocus", "onItemClick", "onItemSelected", "onScrolledIndexChanged"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: AXLoadingComponent, selector: "ax-loading", inputs: ["visible", "type", "context"], outputs: ["visibleChange"] }, { kind: "component", type: AXDropdownBoxComponent, selector: "ax-dropdown-box", inputs: ["disabled", "look", "hasInput", "popoverWidth"], outputs: ["disabledChange", "onBlur", "onFocus", "onClick", "onOpened", "onClosed"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "component", type: AXDecoratorCloseButtonComponent, selector: "ax-close-button", inputs: ["closeAll", "icon"] }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
232
246
  }
233
247
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.8", ngImport: i0, type: AXAutocompleteComponent, decorators: [{
234
248
  type: Component,
@@ -261,6 +275,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.8", ngImpor
261
275
  'disabledChange',
262
276
  'onOpened',
263
277
  'onClosed',
278
+ 'onItemClick',
279
+ 'onItemSelected',
264
280
  ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [
265
281
  { provide: AXComponent, useExisting: AXAutocompleteComponent },
266
282
  { provide: AXFocusableComponent, useExisting: AXAutocompleteComponent },
@@ -288,7 +304,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.8", ngImpor
288
304
  AXDropdownBoxComponent,
289
305
  AXDecoratorGenericComponent,
290
306
  AXDecoratorCloseButtonComponent,
291
- ], template: "<ax-dropdown-box\n [look]=\"look\"\n [hasInput]=\"false\"\n [disabled]=\"disabled\"\n (blur)=\"emitOnBlurEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n [class.ax-state-multiple]=\"multiple\"\n (onOpened)=\"_handleOnOpenedEvent($event)\"\n (onClosed)=\"_handleOnClosedEvent($event)\"\n>\n <ng-container panel>\n <div #panel class=\"ax-autocomplete-panel\" [style.min-width]=\"dropdownSizes.width\">\n @if (dropdown.isActionsheetStyle) {\n <ax-header class=\"ax-solid\">\n <ax-title>{{ caption || placeholder | translate | async }}</ax-title>\n <ax-close-button [icon]=\"multiple ? 'ax-icon ax-icon-check' : 'ax-icon ax-icon-close'\"></ax-close-button>\n </ax-header>\n }\n @if (renderList) {\n <ax-list\n [ngModel]=\"value\"\n [readonly]=\"readonly\"\n [multiple]=\"multiple\"\n [textField]=\"textField\"\n [selectionMode]=\"'item'\"\n [valueField]=\"valueField\"\n [textTemplate]=\"textTemplate\"\n [itemTemplate]=\"itemTemplate\"\n [dataSource]=\"_listDataSource\"\n [loadingTemplate]=\"loadingTemplate\"\n [style.height]=\"dropdownSizes.height\"\n [emptyTemplate]=\"emptyTemplate ?? empty\"\n (onValueChanged)=\"_handleValueChanged($event)\"\n >\n <ng-template #empty> {{ '@acorex:common.general.no-result-found' | translate | async }} </ng-template>\n </ax-list>\n }\n\n @if (isLoading()) {\n @if (loadingTemplate) {\n <ng-template [ngTemplateOutlet]=\"loadingTemplate\"></ng-template>\n } @else {\n <div class=\"ax-autocomplete-loading-container\">\n <ax-loading></ax-loading>\n </div>\n }\n }\n\n <ng-content select=\"ax-footer\"> </ng-content>\n </div>\n </ng-container>\n</ax-dropdown-box>\n" }]
307
+ ], template: "<ax-dropdown-box\n [look]=\"look\"\n [hasInput]=\"false\"\n [disabled]=\"disabled\"\n (blur)=\"emitOnBlurEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n [class.ax-state-multiple]=\"multiple\"\n (onOpened)=\"_handleOnOpenedEvent($event)\"\n (onClosed)=\"_handleOnClosedEvent($event)\"\n>\n <ng-container panel>\n <div #panel class=\"ax-autocomplete-panel\" [style.min-width]=\"dropdownSizes.width\">\n @if (dropdown.isActionsheetStyle) {\n <ax-header class=\"ax-solid\">\n <ax-title>{{ caption || placeholder | translate | async }}</ax-title>\n <ax-close-button [icon]=\"multiple ? 'ax-icon ax-icon-check' : 'ax-icon ax-icon-close'\"></ax-close-button>\n </ax-header>\n }\n @if (renderList) {\n <ax-list\n [ngModel]=\"value\"\n [readonly]=\"readonly\"\n [multiple]=\"multiple\"\n [textField]=\"textField\"\n [selectionMode]=\"'item'\"\n [valueField]=\"valueField\"\n [textTemplate]=\"textTemplate\"\n [itemTemplate]=\"itemTemplate\"\n [dataSource]=\"_listDataSource\"\n [loadingTemplate]=\"loadingTemplate\"\n [style.height]=\"dropdownSizes.height\"\n [emptyTemplate]=\"emptyTemplate ?? empty\"\n (onValueChanged)=\"_handleValueChanged($event)\"\n (onItemClick)=\"_handleItemClick($event)\"\n (onItemSelected)=\"_handleItemSelected($event)\"\n >\n <ng-template #empty> {{ '@acorex:common.general.no-result-found' | translate | async }} </ng-template>\n </ax-list>\n }\n\n @if (isLoading()) {\n @if (loadingTemplate) {\n <ng-template [ngTemplateOutlet]=\"loadingTemplate\"></ng-template>\n } @else {\n <div class=\"ax-autocomplete-loading-container\">\n <ax-loading></ax-loading>\n </div>\n }\n }\n\n <ng-content select=\"ax-footer\"> </ng-content>\n </div>\n </ng-container>\n</ax-dropdown-box>\n" }]
292
308
  }], propDecorators: { dataSource: [{
293
309
  type: Input
294
310
  }], placeholder: [{