@acorex/components 21.0.0-next.51 → 21.0.0-next.52
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/accordion/index.d.ts +1 -0
- package/button-group/index.d.ts +4 -6
- package/chips/index.d.ts +8 -3
- package/collapse/index.d.ts +6 -4
- package/data-list/index.d.ts +1 -1
- package/data-table/index.d.ts +253 -4
- package/dialog/index.d.ts +1 -1
- package/fesm2022/acorex-components-accordion.mjs +21 -16
- package/fesm2022/acorex-components-accordion.mjs.map +1 -1
- package/fesm2022/acorex-components-action-sheet.mjs +12 -12
- package/fesm2022/acorex-components-action-sheet.mjs.map +1 -1
- package/fesm2022/acorex-components-alert.mjs +13 -13
- package/fesm2022/acorex-components-alert.mjs.map +1 -1
- package/fesm2022/acorex-components-aspect-ratio.mjs +3 -3
- package/fesm2022/acorex-components-aspect-ratio.mjs.map +1 -1
- package/fesm2022/acorex-components-audio-wave.mjs +10 -11
- package/fesm2022/acorex-components-audio-wave.mjs.map +1 -1
- package/fesm2022/acorex-components-autocomplete.mjs +7 -7
- package/fesm2022/acorex-components-autocomplete.mjs.map +1 -1
- package/fesm2022/acorex-components-avatar.mjs +12 -12
- package/fesm2022/acorex-components-avatar.mjs.map +1 -1
- package/fesm2022/acorex-components-badge.mjs +9 -9
- package/fesm2022/acorex-components-badge.mjs.map +1 -1
- package/fesm2022/acorex-components-bottom-navigation.mjs +11 -11
- package/fesm2022/acorex-components-bottom-navigation.mjs.map +1 -1
- package/fesm2022/acorex-components-breadcrumbs.mjs +11 -11
- package/fesm2022/acorex-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/acorex-components-button-group.mjs +19 -23
- package/fesm2022/acorex-components-button-group.mjs.map +1 -1
- package/fesm2022/acorex-components-button.mjs +18 -18
- package/fesm2022/acorex-components-button.mjs.map +1 -1
- package/fesm2022/acorex-components-calendar.mjs +17 -17
- package/fesm2022/acorex-components-calendar.mjs.map +1 -1
- package/fesm2022/acorex-components-check-box.mjs +10 -10
- package/fesm2022/acorex-components-check-box.mjs.map +1 -1
- package/fesm2022/acorex-components-chips.mjs +14 -12
- package/fesm2022/acorex-components-chips.mjs.map +1 -1
- package/fesm2022/acorex-components-circular-progress.mjs +10 -12
- package/fesm2022/acorex-components-circular-progress.mjs.map +1 -1
- package/fesm2022/acorex-components-code-editor.mjs +10 -10
- package/fesm2022/acorex-components-code-editor.mjs.map +1 -1
- package/fesm2022/acorex-components-collapse.mjs +19 -22
- package/fesm2022/acorex-components-collapse.mjs.map +1 -1
- package/fesm2022/acorex-components-color-box.mjs +9 -9
- package/fesm2022/acorex-components-color-box.mjs.map +1 -1
- package/fesm2022/acorex-components-color-palette.mjs +30 -30
- package/fesm2022/acorex-components-color-palette.mjs.map +1 -1
- package/fesm2022/acorex-components-command.mjs +9 -9
- package/fesm2022/acorex-components-command.mjs.map +1 -1
- package/fesm2022/acorex-components-comment.mjs +32 -32
- package/fesm2022/acorex-components-comment.mjs.map +1 -1
- package/fesm2022/acorex-components-conversation.mjs +51 -51
- package/fesm2022/acorex-components-conversation.mjs.map +1 -1
- package/fesm2022/acorex-components-conversation2.mjs +184 -184
- package/fesm2022/acorex-components-conversation2.mjs.map +1 -1
- package/fesm2022/acorex-components-cron-job.mjs +46 -46
- package/fesm2022/acorex-components-cron-job.mjs.map +1 -1
- package/fesm2022/acorex-components-data-list.mjs +14 -25
- package/fesm2022/acorex-components-data-list.mjs.map +1 -1
- package/fesm2022/acorex-components-data-pager.mjs +33 -34
- package/fesm2022/acorex-components-data-pager.mjs.map +1 -1
- package/fesm2022/acorex-components-data-table.mjs +487 -51
- package/fesm2022/acorex-components-data-table.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-box.mjs +9 -9
- package/fesm2022/acorex-components-datetime-box.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-input.mjs +9 -9
- package/fesm2022/acorex-components-datetime-input.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-picker.mjs +9 -9
- package/fesm2022/acorex-components-datetime-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-decorators.mjs +36 -43
- package/fesm2022/acorex-components-decorators.mjs.map +1 -1
- package/fesm2022/acorex-components-dialog.mjs +14 -15
- package/fesm2022/acorex-components-dialog.mjs.map +1 -1
- package/fesm2022/acorex-components-drawer-legacy.mjs +13 -13
- package/fesm2022/acorex-components-drawer-legacy.mjs.map +1 -1
- package/fesm2022/acorex-components-drawer.mjs +16 -15
- package/fesm2022/acorex-components-drawer.mjs.map +1 -1
- package/fesm2022/acorex-components-dropdown-button.mjs +9 -9
- package/fesm2022/acorex-components-dropdown-button.mjs.map +1 -1
- package/fesm2022/acorex-components-dropdown.mjs +16 -18
- package/fesm2022/acorex-components-dropdown.mjs.map +1 -1
- package/fesm2022/acorex-components-editor.mjs +11 -11
- package/fesm2022/acorex-components-editor.mjs.map +1 -1
- package/fesm2022/acorex-components-file-explorer.mjs +25 -25
- package/fesm2022/acorex-components-file-explorer.mjs.map +1 -1
- package/fesm2022/acorex-components-flow-chart.mjs +16 -16
- package/fesm2022/acorex-components-flow-chart.mjs.map +1 -1
- package/fesm2022/acorex-components-form.mjs +24 -32
- package/fesm2022/acorex-components-form.mjs.map +1 -1
- package/fesm2022/acorex-components-grid-layout-builder.mjs +13 -12
- package/fesm2022/acorex-components-grid-layout-builder.mjs.map +1 -1
- package/fesm2022/acorex-components-image-editor.mjs +44 -44
- package/fesm2022/acorex-components-image-editor.mjs.map +1 -1
- package/fesm2022/acorex-components-image.mjs +9 -9
- package/fesm2022/acorex-components-image.mjs.map +1 -1
- package/fesm2022/acorex-components-json-viewer.mjs +8 -8
- package/fesm2022/acorex-components-json-viewer.mjs.map +1 -1
- package/fesm2022/acorex-components-kanban.mjs +6 -8
- package/fesm2022/acorex-components-kanban.mjs.map +1 -1
- package/fesm2022/acorex-components-kbd.mjs +11 -29
- package/fesm2022/acorex-components-kbd.mjs.map +1 -1
- package/fesm2022/acorex-components-label.mjs +9 -9
- package/fesm2022/acorex-components-label.mjs.map +1 -1
- package/fesm2022/acorex-components-list.mjs +9 -9
- package/fesm2022/acorex-components-list.mjs.map +1 -1
- package/fesm2022/acorex-components-loading-dialog.mjs +12 -12
- package/fesm2022/acorex-components-loading-dialog.mjs.map +1 -1
- package/fesm2022/acorex-components-loading.mjs +23 -23
- package/fesm2022/acorex-components-loading.mjs.map +1 -1
- package/fesm2022/acorex-components-map.mjs +14 -14
- package/fesm2022/acorex-components-map.mjs.map +1 -1
- package/fesm2022/acorex-components-media-viewer.mjs +39 -39
- package/fesm2022/acorex-components-media-viewer.mjs.map +1 -1
- package/fesm2022/acorex-components-menu.mjs +21 -21
- package/fesm2022/acorex-components-menu.mjs.map +1 -1
- package/fesm2022/{acorex-components-modal-acorex-components-modal-BnUdtPke.mjs → acorex-components-modal-acorex-components-modal-iYSPzoLn.mjs} +22 -22
- package/fesm2022/acorex-components-modal-acorex-components-modal-iYSPzoLn.mjs.map +1 -0
- package/fesm2022/acorex-components-modal-modal-content.component-sZWKhYM-.mjs +212 -0
- package/fesm2022/acorex-components-modal-modal-content.component-sZWKhYM-.mjs.map +1 -0
- package/fesm2022/acorex-components-modal.mjs +1 -1
- package/fesm2022/acorex-components-navbar.mjs +9 -9
- package/fesm2022/acorex-components-navbar.mjs.map +1 -1
- package/fesm2022/acorex-components-notification.mjs +23 -16
- package/fesm2022/acorex-components-notification.mjs.map +1 -1
- package/fesm2022/acorex-components-number-box-legacy.mjs +9 -9
- package/fesm2022/acorex-components-number-box-legacy.mjs.map +1 -1
- package/fesm2022/acorex-components-number-box.mjs +9 -9
- package/fesm2022/acorex-components-number-box.mjs.map +1 -1
- package/fesm2022/acorex-components-otp.mjs +9 -9
- package/fesm2022/acorex-components-otp.mjs.map +1 -1
- package/fesm2022/acorex-components-page.mjs +10 -10
- package/fesm2022/acorex-components-page.mjs.map +1 -1
- package/fesm2022/acorex-components-paint.mjs +39 -34
- package/fesm2022/acorex-components-paint.mjs.map +1 -1
- package/fesm2022/acorex-components-password-box.mjs +13 -13
- package/fesm2022/acorex-components-password-box.mjs.map +1 -1
- package/fesm2022/acorex-components-pdf-reader.mjs +8 -8
- package/fesm2022/acorex-components-pdf-reader.mjs.map +1 -1
- package/fesm2022/acorex-components-phone-box.mjs +9 -9
- package/fesm2022/acorex-components-phone-box.mjs.map +1 -1
- package/fesm2022/acorex-components-picker.mjs +17 -17
- package/fesm2022/acorex-components-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-popover.mjs +11 -11
- package/fesm2022/acorex-components-popover.mjs.map +1 -1
- package/fesm2022/acorex-components-popup.mjs +13 -13
- package/fesm2022/acorex-components-popup.mjs.map +1 -1
- package/fesm2022/acorex-components-progress-bar.mjs +9 -11
- package/fesm2022/acorex-components-progress-bar.mjs.map +1 -1
- package/fesm2022/acorex-components-qrcode.mjs +9 -9
- package/fesm2022/acorex-components-qrcode.mjs.map +1 -1
- package/fesm2022/acorex-components-query-builder.mjs +8 -8
- package/fesm2022/acorex-components-query-builder.mjs.map +1 -1
- package/fesm2022/acorex-components-radio.mjs +9 -9
- package/fesm2022/acorex-components-radio.mjs.map +1 -1
- package/fesm2022/acorex-components-rail-navigation.mjs +36 -38
- package/fesm2022/acorex-components-rail-navigation.mjs.map +1 -1
- package/fesm2022/acorex-components-range-slider.mjs +10 -10
- package/fesm2022/acorex-components-range-slider.mjs.map +1 -1
- package/fesm2022/acorex-components-rate-picker.mjs +35 -20
- package/fesm2022/acorex-components-rate-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-rest-api-generator.mjs +22 -22
- package/fesm2022/acorex-components-rest-api-generator.mjs.map +1 -1
- package/fesm2022/acorex-components-result.mjs +8 -8
- package/fesm2022/acorex-components-result.mjs.map +1 -1
- package/fesm2022/acorex-components-routing-progress.mjs +8 -8
- package/fesm2022/acorex-components-routing-progress.mjs.map +1 -1
- package/fesm2022/acorex-components-rrule.mjs +9 -9
- package/fesm2022/acorex-components-rrule.mjs.map +1 -1
- package/fesm2022/acorex-components-scheduler-picker.mjs +56 -56
- package/fesm2022/acorex-components-scheduler-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-scheduler.mjs +43 -43
- package/fesm2022/acorex-components-scheduler.mjs.map +1 -1
- package/fesm2022/acorex-components-scss.mjs +4 -4
- package/fesm2022/acorex-components-scss.mjs.map +1 -1
- package/fesm2022/acorex-components-search-box.mjs +10 -16
- package/fesm2022/acorex-components-search-box.mjs.map +1 -1
- package/fesm2022/acorex-components-select-box.mjs +9 -11
- package/fesm2022/acorex-components-select-box.mjs.map +1 -1
- package/fesm2022/acorex-components-selection-list-2.mjs +11 -11
- package/fesm2022/acorex-components-selection-list-2.mjs.map +1 -1
- package/fesm2022/acorex-components-selection-list.mjs +9 -9
- package/fesm2022/acorex-components-selection-list.mjs.map +1 -1
- package/fesm2022/acorex-components-side-menu.mjs +14 -14
- package/fesm2022/acorex-components-side-menu.mjs.map +1 -1
- package/fesm2022/acorex-components-skeleton.mjs +8 -8
- package/fesm2022/acorex-components-skeleton.mjs.map +1 -1
- package/fesm2022/acorex-components-slider.mjs +12 -12
- package/fesm2022/acorex-components-slider.mjs.map +1 -1
- package/fesm2022/acorex-components-sliding-item.mjs +14 -14
- package/fesm2022/acorex-components-sliding-item.mjs.map +1 -1
- package/fesm2022/acorex-components-step-wizard.mjs +14 -14
- package/fesm2022/acorex-components-step-wizard.mjs.map +1 -1
- package/fesm2022/acorex-components-switch.mjs +14 -14
- package/fesm2022/acorex-components-switch.mjs.map +1 -1
- package/fesm2022/acorex-components-tabs.mjs +15 -15
- package/fesm2022/acorex-components-tabs.mjs.map +1 -1
- package/fesm2022/acorex-components-tag-box.mjs +9 -9
- package/fesm2022/acorex-components-tag-box.mjs.map +1 -1
- package/fesm2022/acorex-components-tag.mjs +9 -9
- package/fesm2022/acorex-components-tag.mjs.map +1 -1
- package/fesm2022/acorex-components-text-area.mjs +9 -9
- package/fesm2022/acorex-components-text-area.mjs.map +1 -1
- package/fesm2022/acorex-components-text-box.mjs +12 -12
- package/fesm2022/acorex-components-text-box.mjs.map +1 -1
- package/fesm2022/acorex-components-time-duration.mjs +7 -7
- package/fesm2022/acorex-components-time-duration.mjs.map +1 -1
- package/fesm2022/acorex-components-time-line.mjs +12 -12
- package/fesm2022/acorex-components-time-line.mjs.map +1 -1
- package/fesm2022/acorex-components-toast.mjs +14 -14
- package/fesm2022/acorex-components-toast.mjs.map +1 -1
- package/fesm2022/acorex-components-toolbar.mjs +8 -8
- package/fesm2022/acorex-components-toolbar.mjs.map +1 -1
- package/fesm2022/acorex-components-tooltip.mjs +19 -14
- package/fesm2022/acorex-components-tooltip.mjs.map +1 -1
- package/fesm2022/acorex-components-tree-view-legacy.mjs +10 -10
- package/fesm2022/acorex-components-tree-view-legacy.mjs.map +1 -1
- package/fesm2022/acorex-components-tree-view.mjs +70 -16
- package/fesm2022/acorex-components-tree-view.mjs.map +1 -1
- package/fesm2022/acorex-components-uploader.mjs +16 -16
- package/fesm2022/acorex-components-uploader.mjs.map +1 -1
- package/fesm2022/acorex-components-video-player.mjs +8 -8
- package/fesm2022/acorex-components-video-player.mjs.map +1 -1
- package/fesm2022/acorex-components-wysiwyg.mjs +42 -42
- package/fesm2022/acorex-components-wysiwyg.mjs.map +1 -1
- package/fesm2022/acorex-components.mjs.map +1 -1
- package/grid-layout-builder/index.d.ts +2 -1
- package/kbd/index.d.ts +7 -13
- package/loading/index.d.ts +1 -1
- package/notification/index.d.ts +2 -0
- package/package.json +7 -7
- package/paint/index.d.ts +6 -1
- package/rate-picker/index.d.ts +15 -5
- package/slider/index.d.ts +2 -2
- package/tooltip/index.d.ts +1 -0
- package/tree-view/index.d.ts +22 -4
- package/fesm2022/acorex-components-modal-acorex-components-modal-BnUdtPke.mjs.map +0 -1
- package/fesm2022/acorex-components-modal-modal-content.component-Cgq-wx_m.mjs +0 -214
- package/fesm2022/acorex-components-modal-modal-content.component-Cgq-wx_m.mjs.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { MXValueComponent, AXListDataSource } from '@acorex/cdk/common';
|
|
2
|
+
import { AXCheckBoxComponent } from '@acorex/components/check-box';
|
|
3
|
+
import { AXTooltipDirective } from '@acorex/components/tooltip';
|
|
4
|
+
import * as i2 from '@angular/cdk/scrolling';
|
|
5
|
+
import { ScrollingModule, CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
|
|
3
6
|
import * as i1 from '@angular/common';
|
|
4
7
|
import { CommonModule } from '@angular/common';
|
|
8
|
+
import * as i0 from '@angular/core';
|
|
9
|
+
import { input, EventEmitter, signal, computed, model, effect, ViewChild, Output, ViewEncapsulation, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
5
10
|
import { FormsModule } from '@angular/forms';
|
|
6
|
-
import * as i2 from '@angular/cdk/scrolling';
|
|
7
|
-
import { ScrollingModule, CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
|
|
8
|
-
import { MXValueComponent, AXListDataSource } from '@acorex/cdk/common';
|
|
9
|
-
import { AXTooltipDirective } from '@acorex/components/tooltip';
|
|
10
|
-
import { AXCheckBoxComponent } from '@acorex/components/check-box';
|
|
11
11
|
|
|
12
12
|
class AXDataListComponent extends MXValueComponent {
|
|
13
13
|
constructor() {
|
|
@@ -96,12 +96,10 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
96
96
|
effect(() => {
|
|
97
97
|
const dataSource = this.dataSource();
|
|
98
98
|
if (dataSource) {
|
|
99
|
-
console.log('Data source changed, creating AXListDataSource...');
|
|
100
99
|
this.listDataSource = new AXListDataSource({
|
|
101
100
|
source: dataSource,
|
|
102
101
|
debounceTime: 100, // Add debounce to prevent too many page requests
|
|
103
102
|
});
|
|
104
|
-
console.log('Created AXListDataSource:', this.listDataSource);
|
|
105
103
|
// Set up subscriptions
|
|
106
104
|
this.setupDataSourceSubscription();
|
|
107
105
|
}
|
|
@@ -114,16 +112,13 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
114
112
|
setupDataSourceSubscription() {
|
|
115
113
|
if (!this.dataSource() || !this.listDataSource)
|
|
116
114
|
return;
|
|
117
|
-
console.log('Setting up data source subscription for:', this.dataSource());
|
|
118
115
|
// Subscribe to data source changes
|
|
119
116
|
this.dataSource().onChanged.subscribe((data) => {
|
|
120
|
-
console.log('Data source changed:', data);
|
|
121
117
|
if (data && data.cachedItems) {
|
|
122
118
|
this.totalItems.set(data.totalCount || data.cachedItems.length);
|
|
123
119
|
}
|
|
124
120
|
});
|
|
125
121
|
this.dataSource().onLoadingChanged.subscribe((loading) => {
|
|
126
|
-
console.log('Loading changed:', loading);
|
|
127
122
|
this.loading.set(loading);
|
|
128
123
|
});
|
|
129
124
|
// Load initial data - just trigger the first page load
|
|
@@ -148,7 +143,7 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
148
143
|
const currentKeys = this.selectedKeys();
|
|
149
144
|
const itemKey = this.getItemKey(item);
|
|
150
145
|
if (currentKeys.includes(itemKey)) {
|
|
151
|
-
this.selectedKeys.set(currentKeys.filter(key => key !== itemKey));
|
|
146
|
+
this.selectedKeys.set(currentKeys.filter((key) => key !== itemKey));
|
|
152
147
|
}
|
|
153
148
|
else {
|
|
154
149
|
this.selectedKeys.set([...currentKeys, itemKey]);
|
|
@@ -163,7 +158,7 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
163
158
|
deselectItem(item) {
|
|
164
159
|
const currentKeys = this.selectedKeys();
|
|
165
160
|
const itemKey = this.getItemKey(item);
|
|
166
|
-
const newKeys = currentKeys.filter(key => key !== itemKey);
|
|
161
|
+
const newKeys = currentKeys.filter((key) => key !== itemKey);
|
|
167
162
|
this.selectedKeys.set(newKeys);
|
|
168
163
|
this.updateSelectedItems();
|
|
169
164
|
}
|
|
@@ -172,7 +167,7 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
172
167
|
const dataSource = this.listDataSource?.source;
|
|
173
168
|
if (!dataSource)
|
|
174
169
|
return;
|
|
175
|
-
const selected = dataSource.cachedItems.filter(item => keys.includes(this.getItemKey(item)));
|
|
170
|
+
const selected = dataSource.cachedItems.filter((item) => keys.includes(this.getItemKey(item)));
|
|
176
171
|
this.selectedItems.set(selected);
|
|
177
172
|
// Update selection model
|
|
178
173
|
if (this.isMultipleSelection()) {
|
|
@@ -351,18 +346,12 @@ class AXDataListComponent extends MXValueComponent {
|
|
|
351
346
|
shouldShowTooltip(item) {
|
|
352
347
|
return this.showItemTooltip() && !!this.getItemTooltip(item);
|
|
353
348
|
}
|
|
354
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
355
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.15", type: AXDataListComponent, isStandalone: true, selector: "ax-data-list", inputs: { dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: true, isRequired: true, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, showCheckbox: { classPropertyName: "showCheckbox", publicName: "showCheckbox", isSignal: true, isRequired: false, transformFunction: null }, itemHeight: { classPropertyName: "itemHeight", publicName: "itemHeight", isSignal: true, isRequired: false, transformFunction: null }, isItemTruncated: { classPropertyName: "isItemTruncated", publicName: "isItemTruncated", isSignal: true, isRequired: false, transformFunction: null }, showItemTooltip: { classPropertyName: "showItemTooltip", publicName: "showItemTooltip", isSignal: true, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: true, isRequired: false, transformFunction: null }, tooltipField: { classPropertyName: "tooltipField", publicName: "tooltipField", isSignal: true, isRequired: false, transformFunction: null }, textField: { classPropertyName: "textField", publicName: "textField", isSignal: true, isRequired: false, transformFunction: null }, descriptionField: { classPropertyName: "descriptionField", publicName: "descriptionField", isSignal: true, isRequired: false, transformFunction: null }, levelField: { classPropertyName: "levelField", publicName: "levelField", isSignal: true, isRequired: false, transformFunction: null }, childrenField: { classPropertyName: "childrenField", publicName: "childrenField", isSignal: true, isRequired: false, transformFunction: null }, expandedField: { classPropertyName: "expandedField", publicName: "expandedField", isSignal: true, isRequired: false, transformFunction: null }, itemTemplate: { classPropertyName: "itemTemplate", publicName: "itemTemplate", isSignal: true, isRequired: false, transformFunction: null }, emptyTemplate: { classPropertyName: "emptyTemplate", publicName: "emptyTemplate", isSignal: true, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: true, isRequired: false, transformFunction: null }, selectionModel: { classPropertyName: "selectionModel", publicName: "selectionModel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectionChange: "selectionChange", itemClick: "itemClick", itemDoubleClick: "itemDoubleClick", expandChange: "expandChange", selectionModel: "selectionModelChange" }, viewQueries: [{ propertyName: "viewport", first: true, predicate: CdkVirtualScrollViewport, descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-data-list\" [class.ax-data-list--loading]=\"loading()\">\n <!-- Loading State -->\n @if (loading()) {\n <div class=\"ax-data-list__loading\">\n <ng-container *ngTemplateOutlet=\"loadingTemplate() || defaultLoadingTemplate\"></ng-container>\n </div>\n }\n\n <!-- Empty State -->\n @if (isEmpty()) {\n <div class=\"ax-data-list__empty\">\n <ng-container *ngTemplateOutlet=\"emptyTemplate() || defaultEmptyTemplate\"></ng-container>\n </div>\n }\n\n <!-- List Content -->\n @if (hasItems() && listDataSource !== null) {\n <div class=\"ax-data-list__content\">\n <cdk-virtual-scroll-viewport\n [itemSize]=\"itemHeight()\"\n class=\"ax-data-list__viewport\"\n [class.ax-data-list__viewport--truncated]=\"isItemTruncated()\"\n >\n <ng-container *cdkVirtualFor=\"let item of listDataSource; let i = index; trackBy: trackByFn\">\n @if (item) {\n <div\n class=\"ax-data-list__item\"\n [class.ax-data-list__item--selected]=\"isItemSelected(item)\"\n [class.ax-data-list__item--disabled]=\"isItemDisabled(item)\"\n [class.ax-data-list__item--focused]=\"focusedIndex() === i\"\n [class]=\"'ax-data-list__item--level-' + getItemLevel(item)\"\n [style.height.px]=\"itemHeight()\"\n (click)=\"onItemClick(item, $event)\"\n (dblclick)=\"onItemDoubleClick(item)\"\n (keydown)=\"onKeyDown($event, item, i)\"\n tabindex=\"0\"\n role=\"listitem\"\n [attr.aria-selected]=\"isItemSelected(item)\"\n [attr.aria-disabled]=\"isItemDisabled(item)\"\n [attr.aria-level]=\"getItemLevel(item) + 1\"\n >\n <!-- Checkbox -->\n @if (showCheckboxes()) {\n <div class=\"ax-data-list__checkbox\" (click)=\"onCheckboxClick($event)\">\n <ax-check-box\n [value]=\"isItemSelected(item)\"\n [disabled]=\"isItemDisabled(item)\"\n (valueChange)=\"onCheckboxChange(item, $event)\"\n >\n </ax-check-box>\n </div>\n }\n\n <!-- Expand/Collapse Button for Tree Items -->\n @if (hasChildren(item)) {\n <div\n class=\"ax-data-list__expand-button\"\n [class.ax-data-list__expand-button--expanded]=\"isExpanded(item)\"\n (click)=\"toggleExpanded(item, $event)\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-expanded]=\"isExpanded(item)\"\n >\n <svg class=\"ax-data-list__expand-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path d=\"M7 10l5 5 5-5z\" />\n </svg>\n </div>\n }\n\n <!-- Item Content -->\n <div class=\"ax-data-list__content-wrapper\">\n <!-- Custom Item Template -->\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate();\n context: {\n $implicit: item,\n index: i,\n selected: isItemSelected(item),\n disabled: isItemDisabled(item),\n }\n \"\n ></ng-container>\n } @else {\n <ng-container *ngTemplateOutlet=\"defaultItemTemplate\"></ng-container>\n }\n\n <!-- Default Item Template -->\n <ng-template #defaultItemTemplate>\n <div\n class=\"ax-data-list__text\"\n [class.ax-data-list__text--truncated]=\"isItemTruncated()\"\n [axTooltip]=\"shouldShowTooltip(item) ? getItemTooltip(item) : null\"\n [axTooltipDisabled]=\"!shouldShowTooltip(item)\"\n >\n {{ getItemText(item) }}\n </div>\n\n @if (getItemDescription(item)) {\n <div\n class=\"ax-data-list__description\"\n [class.ax-data-list__description--truncated]=\"isItemTruncated()\"\n >\n {{ getItemDescription(item) }}\n </div>\n }\n </ng-template>\n </div>\n </div>\n } @else {\n <!-- Loading skeleton for null items -->\n <div class=\"ax-data-list__item ax-data-list__item--loading\" [style.height.px]=\"itemHeight()\">\n <div class=\"ax-data-list__loading-skeleton\">\n <div class=\"ax-data-list__skeleton-checkbox\"></div>\n <div class=\"ax-data-list__skeleton-content\">\n <div class=\"ax-data-list__skeleton-text\"></div>\n <div class=\"ax-data-list__skeleton-description\"></div>\n </div>\n </div>\n </div>\n }\n </ng-container>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n</div>\n\n<!-- Default Loading Template -->\n<ng-template #defaultLoadingTemplate>\n <div class=\"ax-data-list__loading-default\">\n <div class=\"ax-data-list__loading-spinner\"></div>\n <span>Loading...</span>\n </div>\n</ng-template>\n\n<!-- Default Empty Template -->\n<ng-template #defaultEmptyTemplate>\n <div class=\"ax-data-list__empty-default\">\n <svg class=\"ax-data-list__empty-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path\n d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z\"\n />\n </svg>\n <span>No items to display</span>\n </div>\n</ng-template>\n", styles: [".ax-data-list{display:flex;flex-direction:column;width:100%;height:100%;background:var(--ax-color-background, #ffffff);border:1px solid var(--ax-color-border, #e5e7eb);border-radius:var(--ax-border-radius, .375rem);overflow:hidden}.ax-data-list--loading .ax-data-list__content{opacity:.6;pointer-events:none}.ax-data-list__loading{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__loading-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__loading-spinner{width:2rem;height:2rem;border:2px solid var(--ax-color-border, #e5e7eb);border-top:2px solid var(--ax-color-primary, #3b82f6);border-radius:50%;animation:spin 1s linear infinite}.ax-data-list__empty{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__empty-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280);text-align:center}.ax-data-list__empty-icon{width:3rem;height:3rem;opacity:.5}.ax-data-list__content{flex:1;overflow:hidden}.ax-data-list__viewport{height:100%;width:100%}.ax-data-list__viewport--truncated .ax-data-list__text,.ax-data-list__viewport--truncated .ax-data-list__description{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__item{display:flex;align-items:center;padding:.5rem 1rem;cursor:pointer;transition:all .15s ease-in-out;border-bottom:1px solid var(--ax-color-border-light, #f3f4f6);position:relative}.ax-data-list__item:hover:not(.ax-data-list__item--disabled){background-color:var(--ax-color-hover, #f9fafb)}.ax-data-list__item:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--selected{background-color:var(--ax-color-primary-light, #dbeafe);color:var(--ax-color-primary, #3b82f6);border-color:var(--ax-color-primary, #3b82f6)}.ax-data-list__item--selected:hover{background-color:var(--ax-color-primary-light-hover, #bfdbfe)}.ax-data-list__item--disabled{cursor:not-allowed;opacity:.6;background-color:var(--ax-color-disabled, #f9fafb);color:var(--ax-color-text-disabled, #9ca3af)}.ax-data-list__item--disabled:hover{background-color:var(--ax-color-disabled, #f9fafb)}.ax-data-list__item--focused{background-color:var(--ax-color-focus, #eff6ff);outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--loading{cursor:default;pointer-events:none;background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--loading:hover{background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--level-0{padding-left:1rem}.ax-data-list__item--level-1{padding-left:2.5rem}.ax-data-list__item--level-2{padding-left:4rem}.ax-data-list__item--level-3{padding-left:5.5rem}.ax-data-list__item--level-4{padding-left:7rem}.ax-data-list__item--level-5{padding-left:8.5rem}.ax-data-list__checkbox{margin-right:.75rem;flex-shrink:0}.ax-data-list__expand-button{display:flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;margin-right:.5rem;cursor:pointer;border-radius:.25rem;transition:all .15s ease-in-out;flex-shrink:0}.ax-data-list__expand-button:hover{background-color:var(--ax-color-hover, #f3f4f6)}.ax-data-list__expand-button:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:2px}.ax-data-list__expand-button--expanded .ax-data-list__expand-icon{transform:rotate(90deg)}.ax-data-list__expand-icon{width:1rem;height:1rem;transition:transform .15s ease-in-out;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__content-wrapper{flex:1;min-width:0;display:flex;flex-direction:column;gap:.25rem}.ax-data-list__text{font-weight:500;color:var(--ax-color-text, #111827);line-height:1.25}.ax-data-list__text--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__description{font-size:.875rem;color:var(--ax-color-text-secondary, #6b7280);line-height:1.25}.ax-data-list__description--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@media (max-width: 768px){.ax-data-list__item{padding:.75rem 1rem}.ax-data-list__item--level-1{padding-left:2rem}.ax-data-list__item--level-2{padding-left:3rem}.ax-data-list__item--level-3{padding-left:4rem}.ax-data-list__item--level-4{padding-left:5rem}.ax-data-list__item--level-5{padding-left:6rem}.ax-data-list__checkbox{margin-right:.5rem}.ax-data-list__expand-button{margin-right:.25rem}}@media (prefers-contrast: high){.ax-data-list{border-width:2px}.ax-data-list__item{border-bottom-width:2px}.ax-data-list__item:focus{outline-width:3px}.ax-data-list__item--selected{border-width:2px}.ax-data-list__expand-button:focus{outline-width:3px}}@media (prefers-reduced-motion: reduce){.ax-data-list__item,.ax-data-list__expand-icon{transition:none}.ax-data-list__loading-spinner{animation:none}}.ax-data-list__loading-skeleton{display:flex;align-items:center;width:100%;gap:.75rem}.ax-data-list__skeleton-checkbox{width:1rem;height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;flex-shrink:0}.ax-data-list__skeleton-content{flex:1;display:flex;flex-direction:column;gap:.5rem}.ax-data-list__skeleton-text{height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:80%}.ax-data-list__skeleton-description{height:.75rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:60%}@keyframes shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i2.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "directive", type: i2.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { kind: "component", type: i2.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "directive", type: AXTooltipDirective, selector: "[axTooltip]", inputs: ["axTooltipDisabled", "axTooltip", "axTooltipContext", "axTooltipPlacement", "axTooltipOffsetX", "axTooltipOffsetY", "axTooltipOpenAfter", "axTooltipCloseAfter"] }, { kind: "component", type: AXCheckBoxComponent, selector: "ax-check-box", inputs: ["disabled", "tabIndex", "readonly", "color", "value", "name", "id", "isLoading", "indeterminate"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
349
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.9", ngImport: i0, type: AXDataListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
350
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.9", type: AXDataListComponent, isStandalone: true, selector: "ax-data-list", inputs: { dataSource: { classPropertyName: "dataSource", publicName: "dataSource", isSignal: true, isRequired: true, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, showCheckbox: { classPropertyName: "showCheckbox", publicName: "showCheckbox", isSignal: true, isRequired: false, transformFunction: null }, itemHeight: { classPropertyName: "itemHeight", publicName: "itemHeight", isSignal: true, isRequired: false, transformFunction: null }, isItemTruncated: { classPropertyName: "isItemTruncated", publicName: "isItemTruncated", isSignal: true, isRequired: false, transformFunction: null }, showItemTooltip: { classPropertyName: "showItemTooltip", publicName: "showItemTooltip", isSignal: true, isRequired: false, transformFunction: null }, disabledField: { classPropertyName: "disabledField", publicName: "disabledField", isSignal: true, isRequired: false, transformFunction: null }, tooltipField: { classPropertyName: "tooltipField", publicName: "tooltipField", isSignal: true, isRequired: false, transformFunction: null }, textField: { classPropertyName: "textField", publicName: "textField", isSignal: true, isRequired: false, transformFunction: null }, descriptionField: { classPropertyName: "descriptionField", publicName: "descriptionField", isSignal: true, isRequired: false, transformFunction: null }, levelField: { classPropertyName: "levelField", publicName: "levelField", isSignal: true, isRequired: false, transformFunction: null }, childrenField: { classPropertyName: "childrenField", publicName: "childrenField", isSignal: true, isRequired: false, transformFunction: null }, expandedField: { classPropertyName: "expandedField", publicName: "expandedField", isSignal: true, isRequired: false, transformFunction: null }, itemTemplate: { classPropertyName: "itemTemplate", publicName: "itemTemplate", isSignal: true, isRequired: false, transformFunction: null }, emptyTemplate: { classPropertyName: "emptyTemplate", publicName: "emptyTemplate", isSignal: true, isRequired: false, transformFunction: null }, loadingTemplate: { classPropertyName: "loadingTemplate", publicName: "loadingTemplate", isSignal: true, isRequired: false, transformFunction: null }, selectionModel: { classPropertyName: "selectionModel", publicName: "selectionModel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectionChange: "selectionChange", itemClick: "itemClick", itemDoubleClick: "itemDoubleClick", expandChange: "expandChange", selectionModel: "selectionModelChange" }, viewQueries: [{ propertyName: "viewport", first: true, predicate: CdkVirtualScrollViewport, descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-data-list\" [class.ax-data-list--loading]=\"loading()\">\n <!-- Loading State -->\n @if (loading()) {\n <div class=\"ax-data-list__loading\">\n <ng-container *ngTemplateOutlet=\"loadingTemplate() || defaultLoadingTemplate\"></ng-container>\n </div>\n }\n\n <!-- Empty State -->\n @if (isEmpty()) {\n <div class=\"ax-data-list__empty\">\n <ng-container *ngTemplateOutlet=\"emptyTemplate() || defaultEmptyTemplate\"></ng-container>\n </div>\n }\n\n <!-- List Content -->\n @if (hasItems() && listDataSource !== null) {\n <div class=\"ax-data-list__content\">\n <cdk-virtual-scroll-viewport\n [itemSize]=\"itemHeight()\"\n class=\"ax-data-list__viewport\"\n [class.ax-data-list__viewport--truncated]=\"isItemTruncated()\"\n >\n <ng-container *cdkVirtualFor=\"let item of listDataSource; let i = index; trackBy: trackByFn\">\n @if (item) {\n <div\n class=\"ax-data-list__item\"\n [class.ax-data-list__item--selected]=\"isItemSelected(item)\"\n [class.ax-data-list__item--disabled]=\"isItemDisabled(item)\"\n [class.ax-data-list__item--focused]=\"focusedIndex() === i\"\n [class]=\"'ax-data-list__item--level-' + getItemLevel(item)\"\n [style.height.px]=\"itemHeight()\"\n (click)=\"onItemClick(item, $event)\"\n (dblclick)=\"onItemDoubleClick(item)\"\n (keydown)=\"onKeyDown($event, item, i)\"\n tabindex=\"0\"\n role=\"listitem\"\n [attr.aria-selected]=\"isItemSelected(item)\"\n [attr.aria-disabled]=\"isItemDisabled(item)\"\n [attr.aria-level]=\"getItemLevel(item) + 1\"\n >\n <!-- Checkbox -->\n @if (showCheckboxes()) {\n <div class=\"ax-data-list__checkbox\" (click)=\"onCheckboxClick($event)\">\n <ax-check-box\n [value]=\"isItemSelected(item)\"\n [disabled]=\"isItemDisabled(item)\"\n (valueChange)=\"onCheckboxChange(item, $event)\"\n >\n </ax-check-box>\n </div>\n }\n\n <!-- Expand/Collapse Button for Tree Items -->\n @if (hasChildren(item)) {\n <div\n class=\"ax-data-list__expand-button\"\n [class.ax-data-list__expand-button--expanded]=\"isExpanded(item)\"\n (click)=\"toggleExpanded(item, $event)\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-expanded]=\"isExpanded(item)\"\n >\n <svg class=\"ax-data-list__expand-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path d=\"M7 10l5 5 5-5z\" />\n </svg>\n </div>\n }\n\n <!-- Item Content -->\n <div class=\"ax-data-list__content-wrapper\">\n <!-- Custom Item Template -->\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate();\n context: {\n $implicit: item,\n index: i,\n selected: isItemSelected(item),\n disabled: isItemDisabled(item),\n }\n \"\n ></ng-container>\n } @else {\n <ng-container *ngTemplateOutlet=\"defaultItemTemplate\"></ng-container>\n }\n\n <!-- Default Item Template -->\n <ng-template #defaultItemTemplate>\n <div\n class=\"ax-data-list__text\"\n [class.ax-data-list__text--truncated]=\"isItemTruncated()\"\n [axTooltip]=\"shouldShowTooltip(item) ? getItemTooltip(item) : null\"\n [axTooltipDisabled]=\"!shouldShowTooltip(item)\"\n >\n {{ getItemText(item) }}\n </div>\n\n @if (getItemDescription(item)) {\n <div\n class=\"ax-data-list__description\"\n [class.ax-data-list__description--truncated]=\"isItemTruncated()\"\n >\n {{ getItemDescription(item) }}\n </div>\n }\n </ng-template>\n </div>\n </div>\n } @else {\n <!-- Loading skeleton for null items -->\n <div class=\"ax-data-list__item ax-data-list__item--loading\" [style.height.px]=\"itemHeight()\">\n <div class=\"ax-data-list__loading-skeleton\">\n <div class=\"ax-data-list__skeleton-checkbox\"></div>\n <div class=\"ax-data-list__skeleton-content\">\n <div class=\"ax-data-list__skeleton-text\"></div>\n <div class=\"ax-data-list__skeleton-description\"></div>\n </div>\n </div>\n </div>\n }\n </ng-container>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n</div>\n\n<!-- Default Loading Template -->\n<ng-template #defaultLoadingTemplate>\n <div class=\"ax-data-list__loading-default\">\n <div class=\"ax-data-list__loading-spinner\"></div>\n <span>Loading...</span>\n </div>\n</ng-template>\n\n<!-- Default Empty Template -->\n<ng-template #defaultEmptyTemplate>\n <div class=\"ax-data-list__empty-default\">\n <svg class=\"ax-data-list__empty-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path\n d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z\"\n />\n </svg>\n <span>No items to display</span>\n </div>\n</ng-template>\n", styles: [".ax-data-list{display:flex;flex-direction:column;width:100%;height:100%;background:var(--ax-color-background, #ffffff);border:1px solid var(--ax-color-border, #e5e7eb);border-radius:var(--ax-border-radius, .375rem);overflow:hidden}.ax-data-list--loading .ax-data-list__content{opacity:.6;pointer-events:none}.ax-data-list__loading{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__loading-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__loading-spinner{width:2rem;height:2rem;border:2px solid var(--ax-color-border, #e5e7eb);border-top:2px solid var(--ax-color-primary, #3b82f6);border-radius:50%;animation:spin 1s linear infinite}.ax-data-list__empty{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__empty-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280);text-align:center}.ax-data-list__empty-icon{width:3rem;height:3rem;opacity:.5}.ax-data-list__content{flex:1;overflow:hidden}.ax-data-list__viewport{height:100%;width:100%}.ax-data-list__viewport--truncated .ax-data-list__text,.ax-data-list__viewport--truncated .ax-data-list__description{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__item{display:flex;align-items:center;padding:.5rem 1rem;cursor:pointer;transition:all .15s ease-in-out;border-bottom:1px solid var(--ax-color-border-light, #f3f4f6);position:relative}.ax-data-list__item:hover:not(.ax-data-list__item--disabled){background-color:var(--ax-color-hover, #f9fafb)}.ax-data-list__item:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--selected{background-color:var(--ax-color-primary-light, #dbeafe);color:var(--ax-color-primary, #3b82f6);border-color:var(--ax-color-primary, #3b82f6)}.ax-data-list__item--selected:hover{background-color:var(--ax-color-primary-light-hover, #bfdbfe)}.ax-data-list__item--disabled{cursor:not-allowed;opacity:.6;background-color:var(--ax-color-disabled, #f9fafb);color:var(--ax-color-text-disabled, #9ca3af)}.ax-data-list__item--disabled:hover{background-color:var(--ax-color-disabled, #f9fafb)}.ax-data-list__item--focused{background-color:var(--ax-color-focus, #eff6ff);outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--loading{cursor:default;pointer-events:none;background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--loading:hover{background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--level-0{padding-left:1rem}.ax-data-list__item--level-1{padding-left:2.5rem}.ax-data-list__item--level-2{padding-left:4rem}.ax-data-list__item--level-3{padding-left:5.5rem}.ax-data-list__item--level-4{padding-left:7rem}.ax-data-list__item--level-5{padding-left:8.5rem}.ax-data-list__checkbox{margin-right:.75rem;flex-shrink:0}.ax-data-list__expand-button{display:flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;margin-right:.5rem;cursor:pointer;border-radius:.25rem;transition:all .15s ease-in-out;flex-shrink:0}.ax-data-list__expand-button:hover{background-color:var(--ax-color-hover, #f3f4f6)}.ax-data-list__expand-button:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:2px}.ax-data-list__expand-button--expanded .ax-data-list__expand-icon{transform:rotate(90deg)}.ax-data-list__expand-icon{width:1rem;height:1rem;transition:transform .15s ease-in-out;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__content-wrapper{flex:1;min-width:0;display:flex;flex-direction:column;gap:.25rem}.ax-data-list__text{font-weight:500;color:var(--ax-color-text, #111827);line-height:1.25}.ax-data-list__text--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__description{font-size:.875rem;color:var(--ax-color-text-secondary, #6b7280);line-height:1.25}.ax-data-list__description--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@media (max-width: 768px){.ax-data-list__item{padding:.75rem 1rem}.ax-data-list__item--level-1{padding-left:2rem}.ax-data-list__item--level-2{padding-left:3rem}.ax-data-list__item--level-3{padding-left:4rem}.ax-data-list__item--level-4{padding-left:5rem}.ax-data-list__item--level-5{padding-left:6rem}.ax-data-list__checkbox{margin-right:.5rem}.ax-data-list__expand-button{margin-right:.25rem}}@media (prefers-contrast: high){.ax-data-list{border-width:2px}.ax-data-list__item{border-bottom-width:2px}.ax-data-list__item:focus{outline-width:3px}.ax-data-list__item--selected{border-width:2px}.ax-data-list__expand-button:focus{outline-width:3px}}@media (prefers-reduced-motion: reduce){.ax-data-list__item,.ax-data-list__expand-icon{transition:none}.ax-data-list__loading-spinner{animation:none}}.ax-data-list__loading-skeleton{display:flex;align-items:center;width:100%;gap:.75rem}.ax-data-list__skeleton-checkbox{width:1rem;height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;flex-shrink:0}.ax-data-list__skeleton-content{flex:1;display:flex;flex-direction:column;gap:.5rem}.ax-data-list__skeleton-text{height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:80%}.ax-data-list__skeleton-description{height:.75rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:60%}@keyframes shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i2.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "directive", type: i2.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { kind: "component", type: i2.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { kind: "directive", type: AXTooltipDirective, selector: "[axTooltip]", inputs: ["axTooltipDisabled", "axTooltip", "axTooltipContext", "axTooltipPlacement", "axTooltipOffsetX", "axTooltipOffsetY", "axTooltipOpenAfter", "axTooltipCloseAfter"] }, { kind: "component", type: AXCheckBoxComponent, selector: "ax-check-box", inputs: ["disabled", "tabIndex", "readonly", "color", "value", "name", "id", "isLoading", "indeterminate"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
356
351
|
}
|
|
357
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
352
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.9", ngImport: i0, type: AXDataListComponent, decorators: [{
|
|
358
353
|
type: Component,
|
|
359
|
-
args: [{ selector: 'ax-data-list', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: true, imports: [
|
|
360
|
-
CommonModule,
|
|
361
|
-
FormsModule,
|
|
362
|
-
ScrollingModule,
|
|
363
|
-
AXTooltipDirective,
|
|
364
|
-
AXCheckBoxComponent,
|
|
365
|
-
], template: "<div class=\"ax-data-list\" [class.ax-data-list--loading]=\"loading()\">\n <!-- Loading State -->\n @if (loading()) {\n <div class=\"ax-data-list__loading\">\n <ng-container *ngTemplateOutlet=\"loadingTemplate() || defaultLoadingTemplate\"></ng-container>\n </div>\n }\n\n <!-- Empty State -->\n @if (isEmpty()) {\n <div class=\"ax-data-list__empty\">\n <ng-container *ngTemplateOutlet=\"emptyTemplate() || defaultEmptyTemplate\"></ng-container>\n </div>\n }\n\n <!-- List Content -->\n @if (hasItems() && listDataSource !== null) {\n <div class=\"ax-data-list__content\">\n <cdk-virtual-scroll-viewport\n [itemSize]=\"itemHeight()\"\n class=\"ax-data-list__viewport\"\n [class.ax-data-list__viewport--truncated]=\"isItemTruncated()\"\n >\n <ng-container *cdkVirtualFor=\"let item of listDataSource; let i = index; trackBy: trackByFn\">\n @if (item) {\n <div\n class=\"ax-data-list__item\"\n [class.ax-data-list__item--selected]=\"isItemSelected(item)\"\n [class.ax-data-list__item--disabled]=\"isItemDisabled(item)\"\n [class.ax-data-list__item--focused]=\"focusedIndex() === i\"\n [class]=\"'ax-data-list__item--level-' + getItemLevel(item)\"\n [style.height.px]=\"itemHeight()\"\n (click)=\"onItemClick(item, $event)\"\n (dblclick)=\"onItemDoubleClick(item)\"\n (keydown)=\"onKeyDown($event, item, i)\"\n tabindex=\"0\"\n role=\"listitem\"\n [attr.aria-selected]=\"isItemSelected(item)\"\n [attr.aria-disabled]=\"isItemDisabled(item)\"\n [attr.aria-level]=\"getItemLevel(item) + 1\"\n >\n <!-- Checkbox -->\n @if (showCheckboxes()) {\n <div class=\"ax-data-list__checkbox\" (click)=\"onCheckboxClick($event)\">\n <ax-check-box\n [value]=\"isItemSelected(item)\"\n [disabled]=\"isItemDisabled(item)\"\n (valueChange)=\"onCheckboxChange(item, $event)\"\n >\n </ax-check-box>\n </div>\n }\n\n <!-- Expand/Collapse Button for Tree Items -->\n @if (hasChildren(item)) {\n <div\n class=\"ax-data-list__expand-button\"\n [class.ax-data-list__expand-button--expanded]=\"isExpanded(item)\"\n (click)=\"toggleExpanded(item, $event)\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-expanded]=\"isExpanded(item)\"\n >\n <svg class=\"ax-data-list__expand-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path d=\"M7 10l5 5 5-5z\" />\n </svg>\n </div>\n }\n\n <!-- Item Content -->\n <div class=\"ax-data-list__content-wrapper\">\n <!-- Custom Item Template -->\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate();\n context: {\n $implicit: item,\n index: i,\n selected: isItemSelected(item),\n disabled: isItemDisabled(item),\n }\n \"\n ></ng-container>\n } @else {\n <ng-container *ngTemplateOutlet=\"defaultItemTemplate\"></ng-container>\n }\n\n <!-- Default Item Template -->\n <ng-template #defaultItemTemplate>\n <div\n class=\"ax-data-list__text\"\n [class.ax-data-list__text--truncated]=\"isItemTruncated()\"\n [axTooltip]=\"shouldShowTooltip(item) ? getItemTooltip(item) : null\"\n [axTooltipDisabled]=\"!shouldShowTooltip(item)\"\n >\n {{ getItemText(item) }}\n </div>\n\n @if (getItemDescription(item)) {\n <div\n class=\"ax-data-list__description\"\n [class.ax-data-list__description--truncated]=\"isItemTruncated()\"\n >\n {{ getItemDescription(item) }}\n </div>\n }\n </ng-template>\n </div>\n </div>\n } @else {\n <!-- Loading skeleton for null items -->\n <div class=\"ax-data-list__item ax-data-list__item--loading\" [style.height.px]=\"itemHeight()\">\n <div class=\"ax-data-list__loading-skeleton\">\n <div class=\"ax-data-list__skeleton-checkbox\"></div>\n <div class=\"ax-data-list__skeleton-content\">\n <div class=\"ax-data-list__skeleton-text\"></div>\n <div class=\"ax-data-list__skeleton-description\"></div>\n </div>\n </div>\n </div>\n }\n </ng-container>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n</div>\n\n<!-- Default Loading Template -->\n<ng-template #defaultLoadingTemplate>\n <div class=\"ax-data-list__loading-default\">\n <div class=\"ax-data-list__loading-spinner\"></div>\n <span>Loading...</span>\n </div>\n</ng-template>\n\n<!-- Default Empty Template -->\n<ng-template #defaultEmptyTemplate>\n <div class=\"ax-data-list__empty-default\">\n <svg class=\"ax-data-list__empty-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path\n d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z\"\n />\n </svg>\n <span>No items to display</span>\n </div>\n</ng-template>\n", styles: [".ax-data-list{display:flex;flex-direction:column;width:100%;height:100%;background:var(--ax-color-background, #ffffff);border:1px solid var(--ax-color-border, #e5e7eb);border-radius:var(--ax-border-radius, .375rem);overflow:hidden}.ax-data-list--loading .ax-data-list__content{opacity:.6;pointer-events:none}.ax-data-list__loading{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__loading-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__loading-spinner{width:2rem;height:2rem;border:2px solid var(--ax-color-border, #e5e7eb);border-top:2px solid var(--ax-color-primary, #3b82f6);border-radius:50%;animation:spin 1s linear infinite}.ax-data-list__empty{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__empty-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280);text-align:center}.ax-data-list__empty-icon{width:3rem;height:3rem;opacity:.5}.ax-data-list__content{flex:1;overflow:hidden}.ax-data-list__viewport{height:100%;width:100%}.ax-data-list__viewport--truncated .ax-data-list__text,.ax-data-list__viewport--truncated .ax-data-list__description{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__item{display:flex;align-items:center;padding:.5rem 1rem;cursor:pointer;transition:all .15s ease-in-out;border-bottom:1px solid var(--ax-color-border-light, #f3f4f6);position:relative}.ax-data-list__item:hover:not(.ax-data-list__item--disabled){background-color:var(--ax-color-hover, #f9fafb)}.ax-data-list__item:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--selected{background-color:var(--ax-color-primary-light, #dbeafe);color:var(--ax-color-primary, #3b82f6);border-color:var(--ax-color-primary, #3b82f6)}.ax-data-list__item--selected:hover{background-color:var(--ax-color-primary-light-hover, #bfdbfe)}.ax-data-list__item--disabled{cursor:not-allowed;opacity:.6;background-color:var(--ax-color-disabled, #f9fafb);color:var(--ax-color-text-disabled, #9ca3af)}.ax-data-list__item--disabled:hover{background-color:var(--ax-color-disabled, #f9fafb)}.ax-data-list__item--focused{background-color:var(--ax-color-focus, #eff6ff);outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--loading{cursor:default;pointer-events:none;background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--loading:hover{background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--level-0{padding-left:1rem}.ax-data-list__item--level-1{padding-left:2.5rem}.ax-data-list__item--level-2{padding-left:4rem}.ax-data-list__item--level-3{padding-left:5.5rem}.ax-data-list__item--level-4{padding-left:7rem}.ax-data-list__item--level-5{padding-left:8.5rem}.ax-data-list__checkbox{margin-right:.75rem;flex-shrink:0}.ax-data-list__expand-button{display:flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;margin-right:.5rem;cursor:pointer;border-radius:.25rem;transition:all .15s ease-in-out;flex-shrink:0}.ax-data-list__expand-button:hover{background-color:var(--ax-color-hover, #f3f4f6)}.ax-data-list__expand-button:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:2px}.ax-data-list__expand-button--expanded .ax-data-list__expand-icon{transform:rotate(90deg)}.ax-data-list__expand-icon{width:1rem;height:1rem;transition:transform .15s ease-in-out;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__content-wrapper{flex:1;min-width:0;display:flex;flex-direction:column;gap:.25rem}.ax-data-list__text{font-weight:500;color:var(--ax-color-text, #111827);line-height:1.25}.ax-data-list__text--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__description{font-size:.875rem;color:var(--ax-color-text-secondary, #6b7280);line-height:1.25}.ax-data-list__description--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@media (max-width: 768px){.ax-data-list__item{padding:.75rem 1rem}.ax-data-list__item--level-1{padding-left:2rem}.ax-data-list__item--level-2{padding-left:3rem}.ax-data-list__item--level-3{padding-left:4rem}.ax-data-list__item--level-4{padding-left:5rem}.ax-data-list__item--level-5{padding-left:6rem}.ax-data-list__checkbox{margin-right:.5rem}.ax-data-list__expand-button{margin-right:.25rem}}@media (prefers-contrast: high){.ax-data-list{border-width:2px}.ax-data-list__item{border-bottom-width:2px}.ax-data-list__item:focus{outline-width:3px}.ax-data-list__item--selected{border-width:2px}.ax-data-list__expand-button:focus{outline-width:3px}}@media (prefers-reduced-motion: reduce){.ax-data-list__item,.ax-data-list__expand-icon{transition:none}.ax-data-list__loading-spinner{animation:none}}.ax-data-list__loading-skeleton{display:flex;align-items:center;width:100%;gap:.75rem}.ax-data-list__skeleton-checkbox{width:1rem;height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;flex-shrink:0}.ax-data-list__skeleton-content{flex:1;display:flex;flex-direction:column;gap:.5rem}.ax-data-list__skeleton-text{height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:80%}.ax-data-list__skeleton-description{height:.75rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:60%}@keyframes shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}\n"] }]
|
|
354
|
+
args: [{ selector: 'ax-data-list', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, standalone: true, imports: [CommonModule, FormsModule, ScrollingModule, AXTooltipDirective, AXCheckBoxComponent], template: "<div class=\"ax-data-list\" [class.ax-data-list--loading]=\"loading()\">\n <!-- Loading State -->\n @if (loading()) {\n <div class=\"ax-data-list__loading\">\n <ng-container *ngTemplateOutlet=\"loadingTemplate() || defaultLoadingTemplate\"></ng-container>\n </div>\n }\n\n <!-- Empty State -->\n @if (isEmpty()) {\n <div class=\"ax-data-list__empty\">\n <ng-container *ngTemplateOutlet=\"emptyTemplate() || defaultEmptyTemplate\"></ng-container>\n </div>\n }\n\n <!-- List Content -->\n @if (hasItems() && listDataSource !== null) {\n <div class=\"ax-data-list__content\">\n <cdk-virtual-scroll-viewport\n [itemSize]=\"itemHeight()\"\n class=\"ax-data-list__viewport\"\n [class.ax-data-list__viewport--truncated]=\"isItemTruncated()\"\n >\n <ng-container *cdkVirtualFor=\"let item of listDataSource; let i = index; trackBy: trackByFn\">\n @if (item) {\n <div\n class=\"ax-data-list__item\"\n [class.ax-data-list__item--selected]=\"isItemSelected(item)\"\n [class.ax-data-list__item--disabled]=\"isItemDisabled(item)\"\n [class.ax-data-list__item--focused]=\"focusedIndex() === i\"\n [class]=\"'ax-data-list__item--level-' + getItemLevel(item)\"\n [style.height.px]=\"itemHeight()\"\n (click)=\"onItemClick(item, $event)\"\n (dblclick)=\"onItemDoubleClick(item)\"\n (keydown)=\"onKeyDown($event, item, i)\"\n tabindex=\"0\"\n role=\"listitem\"\n [attr.aria-selected]=\"isItemSelected(item)\"\n [attr.aria-disabled]=\"isItemDisabled(item)\"\n [attr.aria-level]=\"getItemLevel(item) + 1\"\n >\n <!-- Checkbox -->\n @if (showCheckboxes()) {\n <div class=\"ax-data-list__checkbox\" (click)=\"onCheckboxClick($event)\">\n <ax-check-box\n [value]=\"isItemSelected(item)\"\n [disabled]=\"isItemDisabled(item)\"\n (valueChange)=\"onCheckboxChange(item, $event)\"\n >\n </ax-check-box>\n </div>\n }\n\n <!-- Expand/Collapse Button for Tree Items -->\n @if (hasChildren(item)) {\n <div\n class=\"ax-data-list__expand-button\"\n [class.ax-data-list__expand-button--expanded]=\"isExpanded(item)\"\n (click)=\"toggleExpanded(item, $event)\"\n role=\"button\"\n tabindex=\"0\"\n [attr.aria-expanded]=\"isExpanded(item)\"\n >\n <svg class=\"ax-data-list__expand-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path d=\"M7 10l5 5 5-5z\" />\n </svg>\n </div>\n }\n\n <!-- Item Content -->\n <div class=\"ax-data-list__content-wrapper\">\n <!-- Custom Item Template -->\n @if (itemTemplate()) {\n <ng-container\n *ngTemplateOutlet=\"\n itemTemplate();\n context: {\n $implicit: item,\n index: i,\n selected: isItemSelected(item),\n disabled: isItemDisabled(item),\n }\n \"\n ></ng-container>\n } @else {\n <ng-container *ngTemplateOutlet=\"defaultItemTemplate\"></ng-container>\n }\n\n <!-- Default Item Template -->\n <ng-template #defaultItemTemplate>\n <div\n class=\"ax-data-list__text\"\n [class.ax-data-list__text--truncated]=\"isItemTruncated()\"\n [axTooltip]=\"shouldShowTooltip(item) ? getItemTooltip(item) : null\"\n [axTooltipDisabled]=\"!shouldShowTooltip(item)\"\n >\n {{ getItemText(item) }}\n </div>\n\n @if (getItemDescription(item)) {\n <div\n class=\"ax-data-list__description\"\n [class.ax-data-list__description--truncated]=\"isItemTruncated()\"\n >\n {{ getItemDescription(item) }}\n </div>\n }\n </ng-template>\n </div>\n </div>\n } @else {\n <!-- Loading skeleton for null items -->\n <div class=\"ax-data-list__item ax-data-list__item--loading\" [style.height.px]=\"itemHeight()\">\n <div class=\"ax-data-list__loading-skeleton\">\n <div class=\"ax-data-list__skeleton-checkbox\"></div>\n <div class=\"ax-data-list__skeleton-content\">\n <div class=\"ax-data-list__skeleton-text\"></div>\n <div class=\"ax-data-list__skeleton-description\"></div>\n </div>\n </div>\n </div>\n }\n </ng-container>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n</div>\n\n<!-- Default Loading Template -->\n<ng-template #defaultLoadingTemplate>\n <div class=\"ax-data-list__loading-default\">\n <div class=\"ax-data-list__loading-spinner\"></div>\n <span>Loading...</span>\n </div>\n</ng-template>\n\n<!-- Default Empty Template -->\n<ng-template #defaultEmptyTemplate>\n <div class=\"ax-data-list__empty-default\">\n <svg class=\"ax-data-list__empty-icon\" viewBox=\"0 0 24 24\" fill=\"currentColor\">\n <path\n d=\"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-5 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z\"\n />\n </svg>\n <span>No items to display</span>\n </div>\n</ng-template>\n", styles: [".ax-data-list{display:flex;flex-direction:column;width:100%;height:100%;background:var(--ax-color-background, #ffffff);border:1px solid var(--ax-color-border, #e5e7eb);border-radius:var(--ax-border-radius, .375rem);overflow:hidden}.ax-data-list--loading .ax-data-list__content{opacity:.6;pointer-events:none}.ax-data-list__loading{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__loading-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__loading-spinner{width:2rem;height:2rem;border:2px solid var(--ax-color-border, #e5e7eb);border-top:2px solid var(--ax-color-primary, #3b82f6);border-radius:50%;animation:spin 1s linear infinite}.ax-data-list__empty{display:flex;align-items:center;justify-content:center;padding:2rem;min-height:200px}.ax-data-list__empty-default{display:flex;flex-direction:column;align-items:center;gap:1rem;color:var(--ax-color-text-secondary, #6b7280);text-align:center}.ax-data-list__empty-icon{width:3rem;height:3rem;opacity:.5}.ax-data-list__content{flex:1;overflow:hidden}.ax-data-list__viewport{height:100%;width:100%}.ax-data-list__viewport--truncated .ax-data-list__text,.ax-data-list__viewport--truncated .ax-data-list__description{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__item{display:flex;align-items:center;padding:.5rem 1rem;cursor:pointer;transition:all .15s ease-in-out;border-bottom:1px solid var(--ax-color-border-light, #f3f4f6);position:relative}.ax-data-list__item:hover:not(.ax-data-list__item--disabled){background-color:var(--ax-color-hover, #f9fafb)}.ax-data-list__item:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--selected{background-color:var(--ax-color-primary-light, #dbeafe);color:var(--ax-color-primary, #3b82f6);border-color:var(--ax-color-primary, #3b82f6)}.ax-data-list__item--selected:hover{background-color:var(--ax-color-primary-light-hover, #bfdbfe)}.ax-data-list__item--disabled{cursor:not-allowed;opacity:.6;background-color:var(--ax-color-disabled, #f9fafb);color:var(--ax-color-text-disabled, #9ca3af)}.ax-data-list__item--disabled:hover{background-color:var(--ax-color-disabled, #f9fafb)}.ax-data-list__item--focused{background-color:var(--ax-color-focus, #eff6ff);outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:-2px}.ax-data-list__item--loading{cursor:default;pointer-events:none;background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--loading:hover{background-color:var(--ax-color-background, #ffffff)}.ax-data-list__item--level-0{padding-left:1rem}.ax-data-list__item--level-1{padding-left:2.5rem}.ax-data-list__item--level-2{padding-left:4rem}.ax-data-list__item--level-3{padding-left:5.5rem}.ax-data-list__item--level-4{padding-left:7rem}.ax-data-list__item--level-5{padding-left:8.5rem}.ax-data-list__checkbox{margin-right:.75rem;flex-shrink:0}.ax-data-list__expand-button{display:flex;align-items:center;justify-content:center;width:1.5rem;height:1.5rem;margin-right:.5rem;cursor:pointer;border-radius:.25rem;transition:all .15s ease-in-out;flex-shrink:0}.ax-data-list__expand-button:hover{background-color:var(--ax-color-hover, #f3f4f6)}.ax-data-list__expand-button:focus{outline:2px solid var(--ax-color-primary, #3b82f6);outline-offset:2px}.ax-data-list__expand-button--expanded .ax-data-list__expand-icon{transform:rotate(90deg)}.ax-data-list__expand-icon{width:1rem;height:1rem;transition:transform .15s ease-in-out;color:var(--ax-color-text-secondary, #6b7280)}.ax-data-list__content-wrapper{flex:1;min-width:0;display:flex;flex-direction:column;gap:.25rem}.ax-data-list__text{font-weight:500;color:var(--ax-color-text, #111827);line-height:1.25}.ax-data-list__text--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.ax-data-list__description{font-size:.875rem;color:var(--ax-color-text-secondary, #6b7280);line-height:1.25}.ax-data-list__description--truncated{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@media (max-width: 768px){.ax-data-list__item{padding:.75rem 1rem}.ax-data-list__item--level-1{padding-left:2rem}.ax-data-list__item--level-2{padding-left:3rem}.ax-data-list__item--level-3{padding-left:4rem}.ax-data-list__item--level-4{padding-left:5rem}.ax-data-list__item--level-5{padding-left:6rem}.ax-data-list__checkbox{margin-right:.5rem}.ax-data-list__expand-button{margin-right:.25rem}}@media (prefers-contrast: high){.ax-data-list{border-width:2px}.ax-data-list__item{border-bottom-width:2px}.ax-data-list__item:focus{outline-width:3px}.ax-data-list__item--selected{border-width:2px}.ax-data-list__expand-button:focus{outline-width:3px}}@media (prefers-reduced-motion: reduce){.ax-data-list__item,.ax-data-list__expand-icon{transition:none}.ax-data-list__loading-spinner{animation:none}}.ax-data-list__loading-skeleton{display:flex;align-items:center;width:100%;gap:.75rem}.ax-data-list__skeleton-checkbox{width:1rem;height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;flex-shrink:0}.ax-data-list__skeleton-content{flex:1;display:flex;flex-direction:column;gap:.5rem}.ax-data-list__skeleton-text{height:1rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:80%}.ax-data-list__skeleton-description{height:.75rem;background:linear-gradient(90deg,#f3f4f6 25%,#e5e7eb,#f3f4f6 75%);background-size:200% 100%;border-radius:.25rem;animation:shimmer 1.5s infinite;width:60%}@keyframes shimmer{0%{background-position:-200% 0}to{background-position:200% 0}}\n"] }]
|
|
366
355
|
}], ctorParameters: () => [], propDecorators: { dataSource: [{ type: i0.Input, args: [{ isSignal: true, alias: "dataSource", required: true }] }], config: [{ type: i0.Input, args: [{ isSignal: true, alias: "config", required: false }] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], showCheckbox: [{ type: i0.Input, args: [{ isSignal: true, alias: "showCheckbox", required: false }] }], itemHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "itemHeight", required: false }] }], isItemTruncated: [{ type: i0.Input, args: [{ isSignal: true, alias: "isItemTruncated", required: false }] }], showItemTooltip: [{ type: i0.Input, args: [{ isSignal: true, alias: "showItemTooltip", required: false }] }], disabledField: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabledField", required: false }] }], tooltipField: [{ type: i0.Input, args: [{ isSignal: true, alias: "tooltipField", required: false }] }], textField: [{ type: i0.Input, args: [{ isSignal: true, alias: "textField", required: false }] }], descriptionField: [{ type: i0.Input, args: [{ isSignal: true, alias: "descriptionField", required: false }] }], levelField: [{ type: i0.Input, args: [{ isSignal: true, alias: "levelField", required: false }] }], childrenField: [{ type: i0.Input, args: [{ isSignal: true, alias: "childrenField", required: false }] }], expandedField: [{ type: i0.Input, args: [{ isSignal: true, alias: "expandedField", required: false }] }], itemTemplate: [{ type: i0.Input, args: [{ isSignal: true, alias: "itemTemplate", required: false }] }], emptyTemplate: [{ type: i0.Input, args: [{ isSignal: true, alias: "emptyTemplate", required: false }] }], loadingTemplate: [{ type: i0.Input, args: [{ isSignal: true, alias: "loadingTemplate", required: false }] }], selectionChange: [{
|
|
367
356
|
type: Output
|
|
368
357
|
}], itemClick: [{
|