@nova-design-system/nova-angular-18 3.20.0 → 3.21.1-beta.0
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/dist/nova-components/esm2022/lib/components/nv-datatable.component.mjs +143 -39
- package/dist/nova-components/esm2022/lib/nova-components.module.mjs +3 -3
- package/dist/nova-components/esm2022/lib/providers/notification.service.mjs +33 -1
- package/dist/nova-components/esm2022/lib/stencil-generated/component-value-accessors.mjs +37 -1
- package/dist/nova-components/esm2022/lib/stencil-generated/components.mjs +287 -7
- package/dist/nova-components/esm2022/lib/stencil-generated/index.mjs +12 -1
- package/dist/nova-components/fesm2022/nova-components.mjs +499 -47
- package/dist/nova-components/fesm2022/nova-components.mjs.map +1 -1
- package/dist/nova-components/lib/components/nv-datatable.component.d.ts +51 -2
- package/dist/nova-components/lib/nova-components.module.d.ts +2 -2
- package/dist/nova-components/lib/providers/notification.service.d.ts +7 -0
- package/dist/nova-components/lib/stencil-generated/component-value-accessors.d.ts +7 -0
- package/dist/nova-components/lib/stencil-generated/components.d.ts +110 -2
- package/dist/nova-components/lib/stencil-generated/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -5,7 +5,7 @@ import { __decorate } from 'tslib';
|
|
|
5
5
|
import { fromEvent, BehaviorSubject } from 'rxjs';
|
|
6
6
|
import * as i2 from '@angular/common';
|
|
7
7
|
import { CommonModule } from '@angular/common';
|
|
8
|
-
import { memo, createTable, getCoreRowModel, getPaginationRowModel } from '@tanstack/table-core';
|
|
8
|
+
import { memo, createTable, getSortedRowModel, getCoreRowModel, getPaginationRowModel } from '@tanstack/table-core';
|
|
9
9
|
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
10
10
|
export * from '@nova-design-system/nova-webcomponents/constants';
|
|
11
11
|
|
|
@@ -253,11 +253,11 @@ let NvButton = class NvButton {
|
|
|
253
253
|
this.el = r.nativeElement;
|
|
254
254
|
}
|
|
255
255
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvButton, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
256
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvButton, selector: "nv-button", inputs: { active: "active", danger: "danger", disabled: "disabled", emphasis: "emphasis", fluid: "fluid", form: "form", loading: "loading", size: "size", type: "type" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
256
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvButton, selector: "nv-button", inputs: { active: "active", danger: "danger", disableTabindex: "disableTabindex", disabled: "disabled", emphasis: "emphasis", fluid: "fluid", form: "form", loading: "loading", size: "size", type: "type" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
257
257
|
};
|
|
258
258
|
NvButton = __decorate([
|
|
259
259
|
ProxyCmp({
|
|
260
|
-
inputs: ['active', 'danger', 'disabled', 'emphasis', 'fluid', 'form', 'loading', 'size', 'type']
|
|
260
|
+
inputs: ['active', 'danger', 'disableTabindex', 'disabled', 'emphasis', 'fluid', 'form', 'loading', 'size', 'type']
|
|
261
261
|
})
|
|
262
262
|
], NvButton);
|
|
263
263
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvButton, decorators: [{
|
|
@@ -267,7 +267,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
267
267
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
268
268
|
template: '<ng-content></ng-content>',
|
|
269
269
|
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
270
|
-
inputs: ['active', 'danger', 'disabled', 'emphasis', 'fluid', 'form', 'loading', 'size', 'type'],
|
|
270
|
+
inputs: ['active', 'danger', 'disableTabindex', 'disabled', 'emphasis', 'fluid', 'form', 'loading', 'size', 'type'],
|
|
271
271
|
standalone: false
|
|
272
272
|
}]
|
|
273
273
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
@@ -903,11 +903,11 @@ let NvIconbutton = class NvIconbutton {
|
|
|
903
903
|
this.el = r.nativeElement;
|
|
904
904
|
}
|
|
905
905
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvIconbutton, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
906
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvIconbutton, selector: "nv-iconbutton", inputs: { active: "active", disabled: "disabled", emphasis: "emphasis", loading: "loading", name: "name", shape: "shape", size: "size", type: "type" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
906
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvIconbutton, selector: "nv-iconbutton", inputs: { active: "active", disableTabindex: "disableTabindex", disabled: "disabled", emphasis: "emphasis", loading: "loading", name: "name", shape: "shape", size: "size", type: "type" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
907
907
|
};
|
|
908
908
|
NvIconbutton = __decorate([
|
|
909
909
|
ProxyCmp({
|
|
910
|
-
inputs: ['active', 'disabled', 'emphasis', 'loading', 'name', 'shape', 'size', 'type']
|
|
910
|
+
inputs: ['active', 'disableTabindex', 'disabled', 'emphasis', 'loading', 'name', 'shape', 'size', 'type']
|
|
911
911
|
})
|
|
912
912
|
], NvIconbutton);
|
|
913
913
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvIconbutton, decorators: [{
|
|
@@ -917,7 +917,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
917
917
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
918
918
|
template: '<ng-content></ng-content>',
|
|
919
919
|
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
920
|
-
inputs: ['active', 'disabled', 'emphasis', 'loading', 'name', 'shape', 'size', 'type'],
|
|
920
|
+
inputs: ['active', 'disableTabindex', 'disabled', 'emphasis', 'loading', 'name', 'shape', 'size', 'type'],
|
|
921
921
|
standalone: false
|
|
922
922
|
}]
|
|
923
923
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
@@ -1026,6 +1026,31 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
1026
1026
|
standalone: false
|
|
1027
1027
|
}]
|
|
1028
1028
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1029
|
+
let NvNotificationBullet = class NvNotificationBullet {
|
|
1030
|
+
constructor(c, r, z) {
|
|
1031
|
+
this.z = z;
|
|
1032
|
+
c.detach();
|
|
1033
|
+
this.el = r.nativeElement;
|
|
1034
|
+
}
|
|
1035
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvNotificationBullet, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1036
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvNotificationBullet, selector: "nv-notification-bullet", inputs: { contrastingBorder: "contrastingBorder", count: "count", emphasis: "emphasis", intention: "intention", size: "size" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1037
|
+
};
|
|
1038
|
+
NvNotificationBullet = __decorate([
|
|
1039
|
+
ProxyCmp({
|
|
1040
|
+
inputs: ['contrastingBorder', 'count', 'emphasis', 'intention', 'size']
|
|
1041
|
+
})
|
|
1042
|
+
], NvNotificationBullet);
|
|
1043
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvNotificationBullet, decorators: [{
|
|
1044
|
+
type: Component,
|
|
1045
|
+
args: [{
|
|
1046
|
+
selector: 'nv-notification-bullet',
|
|
1047
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1048
|
+
template: '<ng-content></ng-content>',
|
|
1049
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1050
|
+
inputs: ['contrastingBorder', 'count', 'emphasis', 'intention', 'size'],
|
|
1051
|
+
standalone: false
|
|
1052
|
+
}]
|
|
1053
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1029
1054
|
let NvNotificationcontainer = class NvNotificationcontainer {
|
|
1030
1055
|
constructor(c, r, z) {
|
|
1031
1056
|
this.z = z;
|
|
@@ -1101,6 +1126,224 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
1101
1126
|
standalone: false
|
|
1102
1127
|
}]
|
|
1103
1128
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1129
|
+
let NvSidebar = class NvSidebar {
|
|
1130
|
+
constructor(c, r, z) {
|
|
1131
|
+
this.z = z;
|
|
1132
|
+
c.detach();
|
|
1133
|
+
this.el = r.nativeElement;
|
|
1134
|
+
proxyOutputs(this, this.el, ['openChanged']);
|
|
1135
|
+
}
|
|
1136
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebar, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1137
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebar, selector: "nv-sidebar", inputs: { activePath: "activePath", notificationEmphasis: "notificationEmphasis", notificationIntention: "notificationIntention", open: "open", type: "type" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1138
|
+
};
|
|
1139
|
+
NvSidebar = __decorate([
|
|
1140
|
+
ProxyCmp({
|
|
1141
|
+
inputs: ['activePath', 'notificationEmphasis', 'notificationIntention', 'open', 'type']
|
|
1142
|
+
})
|
|
1143
|
+
], NvSidebar);
|
|
1144
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebar, decorators: [{
|
|
1145
|
+
type: Component,
|
|
1146
|
+
args: [{
|
|
1147
|
+
selector: 'nv-sidebar',
|
|
1148
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1149
|
+
template: '<ng-content></ng-content>',
|
|
1150
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1151
|
+
inputs: ['activePath', 'notificationEmphasis', 'notificationIntention', 'open', 'type'],
|
|
1152
|
+
standalone: false
|
|
1153
|
+
}]
|
|
1154
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1155
|
+
let NvSidebarcontent = class NvSidebarcontent {
|
|
1156
|
+
constructor(c, r, z) {
|
|
1157
|
+
this.z = z;
|
|
1158
|
+
c.detach();
|
|
1159
|
+
this.el = r.nativeElement;
|
|
1160
|
+
}
|
|
1161
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarcontent, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1162
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarcontent, selector: "nv-sidebarcontent", ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1163
|
+
};
|
|
1164
|
+
NvSidebarcontent = __decorate([
|
|
1165
|
+
ProxyCmp({})
|
|
1166
|
+
], NvSidebarcontent);
|
|
1167
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarcontent, decorators: [{
|
|
1168
|
+
type: Component,
|
|
1169
|
+
args: [{
|
|
1170
|
+
selector: 'nv-sidebarcontent',
|
|
1171
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1172
|
+
template: '<ng-content></ng-content>',
|
|
1173
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1174
|
+
inputs: [],
|
|
1175
|
+
standalone: false
|
|
1176
|
+
}]
|
|
1177
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1178
|
+
let NvSidebardivider = class NvSidebardivider {
|
|
1179
|
+
constructor(c, r, z) {
|
|
1180
|
+
this.z = z;
|
|
1181
|
+
c.detach();
|
|
1182
|
+
this.el = r.nativeElement;
|
|
1183
|
+
}
|
|
1184
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebardivider, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1185
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebardivider, selector: "nv-sidebardivider", ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1186
|
+
};
|
|
1187
|
+
NvSidebardivider = __decorate([
|
|
1188
|
+
ProxyCmp({})
|
|
1189
|
+
], NvSidebardivider);
|
|
1190
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebardivider, decorators: [{
|
|
1191
|
+
type: Component,
|
|
1192
|
+
args: [{
|
|
1193
|
+
selector: 'nv-sidebardivider',
|
|
1194
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1195
|
+
template: '<ng-content></ng-content>',
|
|
1196
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1197
|
+
inputs: [],
|
|
1198
|
+
standalone: false
|
|
1199
|
+
}]
|
|
1200
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1201
|
+
let NvSidebarfooter = class NvSidebarfooter {
|
|
1202
|
+
constructor(c, r, z) {
|
|
1203
|
+
this.z = z;
|
|
1204
|
+
c.detach();
|
|
1205
|
+
this.el = r.nativeElement;
|
|
1206
|
+
}
|
|
1207
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarfooter, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1208
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarfooter, selector: "nv-sidebarfooter", ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1209
|
+
};
|
|
1210
|
+
NvSidebarfooter = __decorate([
|
|
1211
|
+
ProxyCmp({})
|
|
1212
|
+
], NvSidebarfooter);
|
|
1213
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarfooter, decorators: [{
|
|
1214
|
+
type: Component,
|
|
1215
|
+
args: [{
|
|
1216
|
+
selector: 'nv-sidebarfooter',
|
|
1217
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1218
|
+
template: '<ng-content></ng-content>',
|
|
1219
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1220
|
+
inputs: [],
|
|
1221
|
+
standalone: false
|
|
1222
|
+
}]
|
|
1223
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1224
|
+
let NvSidebargroup = class NvSidebargroup {
|
|
1225
|
+
constructor(c, r, z) {
|
|
1226
|
+
this.z = z;
|
|
1227
|
+
c.detach();
|
|
1228
|
+
this.el = r.nativeElement;
|
|
1229
|
+
}
|
|
1230
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebargroup, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1231
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebargroup, selector: "nv-sidebargroup", inputs: { label: "label" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1232
|
+
};
|
|
1233
|
+
NvSidebargroup = __decorate([
|
|
1234
|
+
ProxyCmp({
|
|
1235
|
+
inputs: ['label']
|
|
1236
|
+
})
|
|
1237
|
+
], NvSidebargroup);
|
|
1238
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebargroup, decorators: [{
|
|
1239
|
+
type: Component,
|
|
1240
|
+
args: [{
|
|
1241
|
+
selector: 'nv-sidebargroup',
|
|
1242
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1243
|
+
template: '<ng-content></ng-content>',
|
|
1244
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1245
|
+
inputs: ['label'],
|
|
1246
|
+
standalone: false
|
|
1247
|
+
}]
|
|
1248
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1249
|
+
let NvSidebarheader = class NvSidebarheader {
|
|
1250
|
+
constructor(c, r, z) {
|
|
1251
|
+
this.z = z;
|
|
1252
|
+
c.detach();
|
|
1253
|
+
this.el = r.nativeElement;
|
|
1254
|
+
}
|
|
1255
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarheader, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1256
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarheader, selector: "nv-sidebarheader", ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1257
|
+
};
|
|
1258
|
+
NvSidebarheader = __decorate([
|
|
1259
|
+
ProxyCmp({})
|
|
1260
|
+
], NvSidebarheader);
|
|
1261
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarheader, decorators: [{
|
|
1262
|
+
type: Component,
|
|
1263
|
+
args: [{
|
|
1264
|
+
selector: 'nv-sidebarheader',
|
|
1265
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1266
|
+
template: '<ng-content></ng-content>',
|
|
1267
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1268
|
+
inputs: [],
|
|
1269
|
+
standalone: false
|
|
1270
|
+
}]
|
|
1271
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1272
|
+
let NvSidebarlogo = class NvSidebarlogo {
|
|
1273
|
+
constructor(c, r, z) {
|
|
1274
|
+
this.z = z;
|
|
1275
|
+
c.detach();
|
|
1276
|
+
this.el = r.nativeElement;
|
|
1277
|
+
}
|
|
1278
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarlogo, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1279
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarlogo, selector: "nv-sidebarlogo", inputs: { collapsedLogo: "collapsedLogo", label: "label", logo: "logo" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1280
|
+
};
|
|
1281
|
+
NvSidebarlogo = __decorate([
|
|
1282
|
+
ProxyCmp({
|
|
1283
|
+
inputs: ['collapsedLogo', 'label', 'logo']
|
|
1284
|
+
})
|
|
1285
|
+
], NvSidebarlogo);
|
|
1286
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarlogo, decorators: [{
|
|
1287
|
+
type: Component,
|
|
1288
|
+
args: [{
|
|
1289
|
+
selector: 'nv-sidebarlogo',
|
|
1290
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1291
|
+
template: '<ng-content></ng-content>',
|
|
1292
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1293
|
+
inputs: ['collapsedLogo', 'label', 'logo'],
|
|
1294
|
+
standalone: false
|
|
1295
|
+
}]
|
|
1296
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1297
|
+
let NvSidebarnavitem = class NvSidebarnavitem {
|
|
1298
|
+
constructor(c, r, z) {
|
|
1299
|
+
this.z = z;
|
|
1300
|
+
c.detach();
|
|
1301
|
+
this.el = r.nativeElement;
|
|
1302
|
+
}
|
|
1303
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarnavitem, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1304
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarnavitem, selector: "nv-sidebarnavitem", inputs: { active: "active", collapsible: "collapsible", icon: "icon", notificationCount: "notificationCount", open: "open" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1305
|
+
};
|
|
1306
|
+
NvSidebarnavitem = __decorate([
|
|
1307
|
+
ProxyCmp({
|
|
1308
|
+
inputs: ['active', 'collapsible', 'icon', 'notificationCount', 'open']
|
|
1309
|
+
})
|
|
1310
|
+
], NvSidebarnavitem);
|
|
1311
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarnavitem, decorators: [{
|
|
1312
|
+
type: Component,
|
|
1313
|
+
args: [{
|
|
1314
|
+
selector: 'nv-sidebarnavitem',
|
|
1315
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1316
|
+
template: '<ng-content></ng-content>',
|
|
1317
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1318
|
+
inputs: ['active', 'collapsible', 'icon', 'notificationCount', 'open'],
|
|
1319
|
+
standalone: false
|
|
1320
|
+
}]
|
|
1321
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1322
|
+
let NvSidebarnavsubitem = class NvSidebarnavsubitem {
|
|
1323
|
+
constructor(c, r, z) {
|
|
1324
|
+
this.z = z;
|
|
1325
|
+
c.detach();
|
|
1326
|
+
this.el = r.nativeElement;
|
|
1327
|
+
}
|
|
1328
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarnavsubitem, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1329
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarnavsubitem, selector: "nv-sidebarnavsubitem", inputs: { active: "active" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1330
|
+
};
|
|
1331
|
+
NvSidebarnavsubitem = __decorate([
|
|
1332
|
+
ProxyCmp({
|
|
1333
|
+
inputs: ['active']
|
|
1334
|
+
})
|
|
1335
|
+
], NvSidebarnavsubitem);
|
|
1336
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarnavsubitem, decorators: [{
|
|
1337
|
+
type: Component,
|
|
1338
|
+
args: [{
|
|
1339
|
+
selector: 'nv-sidebarnavsubitem',
|
|
1340
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1341
|
+
template: '<ng-content></ng-content>',
|
|
1342
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1343
|
+
inputs: ['active'],
|
|
1344
|
+
standalone: false
|
|
1345
|
+
}]
|
|
1346
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1104
1347
|
let NvSplit = class NvSplit {
|
|
1105
1348
|
constructor(c, r, z) {
|
|
1106
1349
|
this.z = z;
|
|
@@ -1176,6 +1419,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
1176
1419
|
standalone: false
|
|
1177
1420
|
}]
|
|
1178
1421
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1422
|
+
let NvTableheader = class NvTableheader {
|
|
1423
|
+
constructor(c, r, z) {
|
|
1424
|
+
this.z = z;
|
|
1425
|
+
c.detach();
|
|
1426
|
+
this.el = r.nativeElement;
|
|
1427
|
+
proxyOutputs(this, this.el, ['sortDirectionChanged']);
|
|
1428
|
+
}
|
|
1429
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvTableheader, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1430
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.13", type: NvTableheader, selector: "nv-tableheader", inputs: { sortDirection: "sortDirection", sortable: "sortable" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1431
|
+
};
|
|
1432
|
+
NvTableheader = __decorate([
|
|
1433
|
+
ProxyCmp({
|
|
1434
|
+
inputs: ['sortDirection', 'sortable']
|
|
1435
|
+
})
|
|
1436
|
+
], NvTableheader);
|
|
1437
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvTableheader, decorators: [{
|
|
1438
|
+
type: Component,
|
|
1439
|
+
args: [{
|
|
1440
|
+
selector: 'nv-tableheader',
|
|
1441
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1442
|
+
template: '<ng-content></ng-content>',
|
|
1443
|
+
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
|
|
1444
|
+
inputs: ['sortDirection', 'sortable'],
|
|
1445
|
+
standalone: false
|
|
1446
|
+
}]
|
|
1447
|
+
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i0.ElementRef }, { type: i0.NgZone }] });
|
|
1179
1448
|
let NvToggle = class NvToggle {
|
|
1180
1449
|
constructor(c, r, z) {
|
|
1181
1450
|
this.z = z;
|
|
@@ -1319,12 +1588,23 @@ const DIRECTIVES = [
|
|
|
1319
1588
|
NvMenu,
|
|
1320
1589
|
NvMenuitem,
|
|
1321
1590
|
NvNotification,
|
|
1591
|
+
NvNotificationBullet,
|
|
1322
1592
|
NvNotificationcontainer,
|
|
1323
1593
|
NvPopover,
|
|
1324
1594
|
NvRow,
|
|
1595
|
+
NvSidebar,
|
|
1596
|
+
NvSidebarcontent,
|
|
1597
|
+
NvSidebardivider,
|
|
1598
|
+
NvSidebarfooter,
|
|
1599
|
+
NvSidebargroup,
|
|
1600
|
+
NvSidebarheader,
|
|
1601
|
+
NvSidebarlogo,
|
|
1602
|
+
NvSidebarnavitem,
|
|
1603
|
+
NvSidebarnavsubitem,
|
|
1325
1604
|
NvSplit,
|
|
1326
1605
|
NvStack,
|
|
1327
1606
|
NvTable,
|
|
1607
|
+
NvTableheader,
|
|
1328
1608
|
NvToggle,
|
|
1329
1609
|
NvTogglebutton,
|
|
1330
1610
|
NvTogglebuttongroup,
|
|
@@ -2093,6 +2373,7 @@ function createAngularTable(options) {
|
|
|
2093
2373
|
|
|
2094
2374
|
/* eslint-disable jsdoc/require-jsdoc */
|
|
2095
2375
|
/* eslint-disable jsdoc/require-returns */
|
|
2376
|
+
/* eslint-disable jsdoc/require-param */
|
|
2096
2377
|
/**
|
|
2097
2378
|
* A powerful, flexible datatable component built on TanStack Table.
|
|
2098
2379
|
* Supports custom cell rendering, column configuration, pagination, and full TypeScript typing.
|
|
@@ -2102,6 +2383,37 @@ class NvDatatable {
|
|
|
2102
2383
|
table() {
|
|
2103
2384
|
return this.tableInstance();
|
|
2104
2385
|
}
|
|
2386
|
+
/**
|
|
2387
|
+
* Handle sort direction change from table header
|
|
2388
|
+
* @param {Event} event The sort direction change event or direction string
|
|
2389
|
+
* @param {object} header The table header object
|
|
2390
|
+
*/
|
|
2391
|
+
handleSortDirectionChanged(event, header) {
|
|
2392
|
+
// Extract direction from event or use directly if string
|
|
2393
|
+
let direction;
|
|
2394
|
+
if (typeof event === 'string') {
|
|
2395
|
+
direction = event;
|
|
2396
|
+
}
|
|
2397
|
+
else if ('detail' in event && typeof event.detail === 'string') {
|
|
2398
|
+
direction = event.detail;
|
|
2399
|
+
}
|
|
2400
|
+
else {
|
|
2401
|
+
// Fallback - shouldn't happen but handle gracefully
|
|
2402
|
+
console.warn('Unexpected event type in handleSortDirectionChanged:', event);
|
|
2403
|
+
return;
|
|
2404
|
+
}
|
|
2405
|
+
const sortingConfig = this.sorting();
|
|
2406
|
+
// Check if multi-sort is enabled
|
|
2407
|
+
const isMultiSort = sortingConfig?.enableMultiSort ?? false;
|
|
2408
|
+
if (direction === 'none') {
|
|
2409
|
+
// Clear this column's sort
|
|
2410
|
+
header.column.clearSorting();
|
|
2411
|
+
}
|
|
2412
|
+
else {
|
|
2413
|
+
// Toggle sort - TanStack will handle the logic internally
|
|
2414
|
+
header.column.toggleSorting(direction === 'desc', isMultiSort);
|
|
2415
|
+
}
|
|
2416
|
+
}
|
|
2105
2417
|
constructor() {
|
|
2106
2418
|
/** Column definitions */
|
|
2107
2419
|
this.columns = input([]);
|
|
@@ -2109,6 +2421,8 @@ class NvDatatable {
|
|
|
2109
2421
|
this.rows = input([]);
|
|
2110
2422
|
/** Optional pagination configuration */
|
|
2111
2423
|
this.pagination = input(undefined);
|
|
2424
|
+
/** Optional sorting configuration */
|
|
2425
|
+
this.sorting = input(undefined);
|
|
2112
2426
|
/** Should the header stick to the top of the table when scrolling? */
|
|
2113
2427
|
this.stickyHeader = input(false);
|
|
2114
2428
|
/** Signal to track cell templates array */
|
|
@@ -2126,6 +2440,8 @@ class NvDatatable {
|
|
|
2126
2440
|
pageIndex: 0,
|
|
2127
2441
|
pageSize: this.pagination()?.initialPageSize || 10,
|
|
2128
2442
|
});
|
|
2443
|
+
/** Sorting state for controlled sorting (server mode) */
|
|
2444
|
+
this.sortingState = signal(this.sorting()?.sortState || []);
|
|
2129
2445
|
/** Reference to table rows for infinite scroll observer */
|
|
2130
2446
|
this.tableRows = viewChild('tableRow');
|
|
2131
2447
|
/** Intersection observer for infinite scroll */
|
|
@@ -2154,7 +2470,7 @@ class NvDatatable {
|
|
|
2154
2470
|
// Default: just return the value (formatted if valueFormatter was used)
|
|
2155
2471
|
return context.getValue();
|
|
2156
2472
|
};
|
|
2157
|
-
|
|
2473
|
+
const columnDef = {
|
|
2158
2474
|
accessorKey: col.field,
|
|
2159
2475
|
accessorFn: col.valueFormatter
|
|
2160
2476
|
? (row) => {
|
|
@@ -2169,27 +2485,82 @@ class NvDatatable {
|
|
|
2169
2485
|
header: col.headerName || String(col.field),
|
|
2170
2486
|
size: col.width,
|
|
2171
2487
|
enableResizing: col.resizable ?? true,
|
|
2488
|
+
// Sorting configuration
|
|
2489
|
+
enableSorting: this.sorting() ? col.sortable ?? true : false,
|
|
2172
2490
|
cell: cellRenderer,
|
|
2173
2491
|
};
|
|
2492
|
+
// Add optional sorting properties only if defined
|
|
2493
|
+
if (col.sortingFn !== undefined) {
|
|
2494
|
+
// @ts-expect-error - TanStack typing is strict but this works at runtime
|
|
2495
|
+
columnDef.sortingFn = col.sortingFn;
|
|
2496
|
+
}
|
|
2497
|
+
if (col.sortDescFirst !== undefined) {
|
|
2498
|
+
columnDef.sortDescFirst = col.sortDescFirst;
|
|
2499
|
+
}
|
|
2500
|
+
if (col.invertSorting !== undefined) {
|
|
2501
|
+
columnDef.invertSorting = col.invertSorting;
|
|
2502
|
+
}
|
|
2503
|
+
if (col.sortUndefined !== undefined) {
|
|
2504
|
+
columnDef.sortUndefined = col.sortUndefined;
|
|
2505
|
+
}
|
|
2506
|
+
return columnDef;
|
|
2174
2507
|
});
|
|
2175
2508
|
});
|
|
2176
2509
|
/** TanStack table instance with Signals */
|
|
2177
2510
|
this.tableInstance = createAngularTable(() => {
|
|
2178
2511
|
const paginationConfig = this.pagination();
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2512
|
+
const sortingConfig = this.sorting();
|
|
2513
|
+
// Determine base table configuration with sorting
|
|
2514
|
+
const getBaseTableConfig = () => {
|
|
2515
|
+
const baseConfig = {
|
|
2182
2516
|
data: this.rows(),
|
|
2183
2517
|
columns: this.tableColumns(),
|
|
2184
2518
|
getCoreRowModel: getCoreRowModel(),
|
|
2519
|
+
// Sorting configuration
|
|
2520
|
+
...(sortingConfig && {
|
|
2521
|
+
state: {
|
|
2522
|
+
sorting: sortingConfig.mode === 'server' && sortingConfig.sortState
|
|
2523
|
+
? sortingConfig.sortState
|
|
2524
|
+
: this.sortingState(),
|
|
2525
|
+
},
|
|
2526
|
+
onSortingChange: (updaterOrValue) => {
|
|
2527
|
+
const currentSort = sortingConfig.mode === 'server' && sortingConfig.sortState
|
|
2528
|
+
? sortingConfig.sortState
|
|
2529
|
+
: this.sortingState();
|
|
2530
|
+
const newSort = typeof updaterOrValue === 'function'
|
|
2531
|
+
? updaterOrValue(currentSort)
|
|
2532
|
+
: updaterOrValue;
|
|
2533
|
+
// Always update internal state for reactivity
|
|
2534
|
+
this.sortingState.set(newSort);
|
|
2535
|
+
// For server-side sorting, also call the callback
|
|
2536
|
+
if (sortingConfig?.mode === 'server' &&
|
|
2537
|
+
sortingConfig.onSortingChange) {
|
|
2538
|
+
sortingConfig.onSortingChange(newSort);
|
|
2539
|
+
}
|
|
2540
|
+
},
|
|
2541
|
+
manualSorting: sortingConfig.mode === 'server',
|
|
2542
|
+
enableSorting: true,
|
|
2543
|
+
enableMultiSort: sortingConfig.enableMultiSort ?? false,
|
|
2544
|
+
enableSortingRemoval: sortingConfig.enableSortingRemoval ?? true,
|
|
2545
|
+
maxMultiSortColCount: sortingConfig.maxMultiSortColCount,
|
|
2546
|
+
sortDescFirst: sortingConfig.sortDescFirst ?? false,
|
|
2547
|
+
// When multi-sort is enabled, treat all clicks as multi-sort events
|
|
2548
|
+
isMultiSortEvent: sortingConfig.enableMultiSort
|
|
2549
|
+
? () => true
|
|
2550
|
+
: undefined,
|
|
2551
|
+
getSortedRowModel: sortingConfig.mode === 'client' ? getSortedRowModel() : undefined,
|
|
2552
|
+
}),
|
|
2185
2553
|
};
|
|
2554
|
+
return baseConfig;
|
|
2555
|
+
};
|
|
2556
|
+
if (!paginationConfig || paginationConfig.mode === 'infinite') {
|
|
2557
|
+
// No pagination or infinite scroll - simple config
|
|
2558
|
+
return getBaseTableConfig();
|
|
2186
2559
|
}
|
|
2187
2560
|
else if (paginationConfig.mode === 'client') {
|
|
2188
2561
|
// Client-side pagination
|
|
2189
2562
|
return {
|
|
2190
|
-
|
|
2191
|
-
columns: this.tableColumns(),
|
|
2192
|
-
getCoreRowModel: getCoreRowModel(),
|
|
2563
|
+
...getBaseTableConfig(),
|
|
2193
2564
|
getPaginationRowModel: getPaginationRowModel(),
|
|
2194
2565
|
initialState: {
|
|
2195
2566
|
pagination: {
|
|
@@ -2200,12 +2571,11 @@ class NvDatatable {
|
|
|
2200
2571
|
};
|
|
2201
2572
|
}
|
|
2202
2573
|
else {
|
|
2203
|
-
// Server-side pagination
|
|
2574
|
+
// Server-side pagination - manual pagination with reactive state
|
|
2575
|
+
const baseConfig = getBaseTableConfig();
|
|
2204
2576
|
const pageSize = this.paginationState().pageSize;
|
|
2205
2577
|
return {
|
|
2206
|
-
|
|
2207
|
-
columns: this.tableColumns(),
|
|
2208
|
-
getCoreRowModel: getCoreRowModel(),
|
|
2578
|
+
...baseConfig,
|
|
2209
2579
|
manualPagination: true,
|
|
2210
2580
|
pageCount: paginationConfig.totalPageCount !== undefined
|
|
2211
2581
|
? paginationConfig.totalPageCount
|
|
@@ -2214,13 +2584,19 @@ class NvDatatable {
|
|
|
2214
2584
|
: -1,
|
|
2215
2585
|
state: {
|
|
2216
2586
|
pagination: this.paginationState(),
|
|
2587
|
+
...(baseConfig.state && { sorting: baseConfig.state.sorting }),
|
|
2217
2588
|
},
|
|
2218
2589
|
onPaginationChange: (updaterOrValue) => {
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2590
|
+
const newState = typeof updaterOrValue === 'function'
|
|
2591
|
+
? updaterOrValue(this.paginationState())
|
|
2592
|
+
: updaterOrValue;
|
|
2593
|
+
this.paginationState.set(newState);
|
|
2594
|
+
// Call user's callback for server-side pagination
|
|
2595
|
+
if (paginationConfig.onPaginationChange) {
|
|
2596
|
+
paginationConfig.onPaginationChange({
|
|
2597
|
+
pageIndex: newState.pageIndex,
|
|
2598
|
+
pageSize: newState.pageSize,
|
|
2599
|
+
});
|
|
2224
2600
|
}
|
|
2225
2601
|
},
|
|
2226
2602
|
};
|
|
@@ -2259,18 +2635,6 @@ class NvDatatable {
|
|
|
2259
2635
|
: undefined,
|
|
2260
2636
|
};
|
|
2261
2637
|
});
|
|
2262
|
-
// Watch pagination state changes for server mode
|
|
2263
|
-
effect(() => {
|
|
2264
|
-
const paginationConfig = this.pagination();
|
|
2265
|
-
const state = this.paginationState();
|
|
2266
|
-
if (paginationConfig?.mode === 'server' &&
|
|
2267
|
-
paginationConfig.onPaginationChange) {
|
|
2268
|
-
paginationConfig.onPaginationChange({
|
|
2269
|
-
pageIndex: state.pageIndex,
|
|
2270
|
-
pageSize: state.pageSize,
|
|
2271
|
-
});
|
|
2272
|
-
}
|
|
2273
|
-
}, { allowSignalWrites: true });
|
|
2274
2638
|
// Set up intersection observer for infinite scroll
|
|
2275
2639
|
effect(() => {
|
|
2276
2640
|
const paginationConfig = this.pagination();
|
|
@@ -2329,7 +2693,7 @@ class NvDatatable {
|
|
|
2329
2693
|
}
|
|
2330
2694
|
}
|
|
2331
2695
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvDatatable, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2332
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: NvDatatable, isStandalone: true, selector: "nv-datatable", inputs: { columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, pagination: { classPropertyName: "pagination", publicName: "pagination", isSignal: true, isRequired: false, transformFunction: null }, stickyHeader: { classPropertyName: "stickyHeader", publicName: "stickyHeader", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "paginationTemplate", first: true, predicate: ["paginationTemplate"], descendants: true, read: TemplateRef }, { propertyName: "cellTemplates", predicate: NvDatatableCellDirective }], viewQueries: [{ propertyName: "tableRows", first: true, predicate: ["tableRow"], descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
2696
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.13", type: NvDatatable, isStandalone: true, selector: "nv-datatable", inputs: { columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, pagination: { classPropertyName: "pagination", publicName: "pagination", isSignal: true, isRequired: false, transformFunction: null }, sorting: { classPropertyName: "sorting", publicName: "sorting", isSignal: true, isRequired: false, transformFunction: null }, stickyHeader: { classPropertyName: "stickyHeader", publicName: "stickyHeader", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "paginationTemplate", first: true, predicate: ["paginationTemplate"], descendants: true, read: TemplateRef }, { propertyName: "cellTemplates", predicate: NvDatatableCellDirective }], viewQueries: [{ propertyName: "tableRows", first: true, predicate: ["tableRow"], descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
2333
2697
|
<nv-table>
|
|
2334
2698
|
<table>
|
|
2335
2699
|
<thead [attr.data-sticky-top]="stickyHeader() ? 'true' : null">
|
|
@@ -2348,9 +2712,19 @@ class NvDatatable {
|
|
|
2348
2712
|
!header.column.columnDef.enableResizing ? 'true' : null
|
|
2349
2713
|
"
|
|
2350
2714
|
>
|
|
2351
|
-
@if (!header.isPlaceholder) {
|
|
2715
|
+
@if (!header.isPlaceholder) { @if (header.column.getCanSort()) {
|
|
2716
|
+
<nv-tableheader
|
|
2717
|
+
[sortable]="true"
|
|
2718
|
+
[sortDirection]="header.column.getIsSorted() || 'none'"
|
|
2719
|
+
(sortDirectionChanged)="
|
|
2720
|
+
handleSortDirectionChanged($event, header)
|
|
2721
|
+
"
|
|
2722
|
+
>
|
|
2723
|
+
{{ header.column.columnDef.header }}
|
|
2724
|
+
</nv-tableheader>
|
|
2725
|
+
} @else {
|
|
2352
2726
|
{{ header.column.columnDef.header }}
|
|
2353
|
-
}
|
|
2727
|
+
} }
|
|
2354
2728
|
</th>
|
|
2355
2729
|
}
|
|
2356
2730
|
</tr>
|
|
@@ -2361,7 +2735,7 @@ class NvDatatable {
|
|
|
2361
2735
|
@for (row of table().getRowModel().rows; track row.id; let i = $index)
|
|
2362
2736
|
{
|
|
2363
2737
|
<tr
|
|
2364
|
-
[attr.data-testid]="'datatable-row-' +
|
|
2738
|
+
[attr.data-testid]="'datatable-row-' + i"
|
|
2365
2739
|
#tableRow
|
|
2366
2740
|
[attr.data-is-last]="
|
|
2367
2741
|
isInfiniteScroll() && i === table().getRowModel().rows.length - 1
|
|
@@ -2370,7 +2744,7 @@ class NvDatatable {
|
|
|
2370
2744
|
"
|
|
2371
2745
|
>
|
|
2372
2746
|
@for (cell of row.getVisibleCells(); track cell.id) {
|
|
2373
|
-
<td [attr.data-testid]="'datatable-cell-' + cell.id">
|
|
2747
|
+
<td [attr.data-testid]="'datatable-cell-' + cell.column.id">
|
|
2374
2748
|
<ng-container
|
|
2375
2749
|
*flexRender="
|
|
2376
2750
|
cell.column.columnDef.cell;
|
|
@@ -2425,9 +2799,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
2425
2799
|
!header.column.columnDef.enableResizing ? 'true' : null
|
|
2426
2800
|
"
|
|
2427
2801
|
>
|
|
2428
|
-
@if (!header.isPlaceholder) {
|
|
2802
|
+
@if (!header.isPlaceholder) { @if (header.column.getCanSort()) {
|
|
2803
|
+
<nv-tableheader
|
|
2804
|
+
[sortable]="true"
|
|
2805
|
+
[sortDirection]="header.column.getIsSorted() || 'none'"
|
|
2806
|
+
(sortDirectionChanged)="
|
|
2807
|
+
handleSortDirectionChanged($event, header)
|
|
2808
|
+
"
|
|
2809
|
+
>
|
|
2810
|
+
{{ header.column.columnDef.header }}
|
|
2811
|
+
</nv-tableheader>
|
|
2812
|
+
} @else {
|
|
2429
2813
|
{{ header.column.columnDef.header }}
|
|
2430
|
-
}
|
|
2814
|
+
} }
|
|
2431
2815
|
</th>
|
|
2432
2816
|
}
|
|
2433
2817
|
</tr>
|
|
@@ -2438,7 +2822,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
2438
2822
|
@for (row of table().getRowModel().rows; track row.id; let i = $index)
|
|
2439
2823
|
{
|
|
2440
2824
|
<tr
|
|
2441
|
-
[attr.data-testid]="'datatable-row-' +
|
|
2825
|
+
[attr.data-testid]="'datatable-row-' + i"
|
|
2442
2826
|
#tableRow
|
|
2443
2827
|
[attr.data-is-last]="
|
|
2444
2828
|
isInfiniteScroll() && i === table().getRowModel().rows.length - 1
|
|
@@ -2447,7 +2831,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
2447
2831
|
"
|
|
2448
2832
|
>
|
|
2449
2833
|
@for (cell of row.getVisibleCells(); track cell.id) {
|
|
2450
|
-
<td [attr.data-testid]="'datatable-cell-' + cell.id">
|
|
2834
|
+
<td [attr.data-testid]="'datatable-cell-' + cell.column.id">
|
|
2451
2835
|
<ng-container
|
|
2452
2836
|
*flexRender="
|
|
2453
2837
|
cell.column.columnDef.cell;
|
|
@@ -3248,6 +3632,41 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
3248
3632
|
type: HostListener,
|
|
3249
3633
|
args: ['openChanged', ['$event']]
|
|
3250
3634
|
}] } });
|
|
3635
|
+
class NvSidebarValueAccessor extends ValueAccessor {
|
|
3636
|
+
constructor(el) {
|
|
3637
|
+
super(el);
|
|
3638
|
+
}
|
|
3639
|
+
handleOpenChanged(event) {
|
|
3640
|
+
this.handleChangeEvent(event.target.open);
|
|
3641
|
+
}
|
|
3642
|
+
writeValue(value) {
|
|
3643
|
+
this.el.nativeElement.open = this.lastValue = value;
|
|
3644
|
+
}
|
|
3645
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarValueAccessor, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
3646
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.13", type: NvSidebarValueAccessor, selector: "nv-sidebar", host: { listeners: { "openChanged": "handleOpenChanged($event)" } }, providers: [
|
|
3647
|
+
{
|
|
3648
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3649
|
+
useExisting: NvSidebarValueAccessor,
|
|
3650
|
+
multi: true,
|
|
3651
|
+
},
|
|
3652
|
+
], usesInheritance: true, ngImport: i0 }); }
|
|
3653
|
+
}
|
|
3654
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NvSidebarValueAccessor, decorators: [{
|
|
3655
|
+
type: Directive,
|
|
3656
|
+
args: [{
|
|
3657
|
+
selector: 'nv-sidebar',
|
|
3658
|
+
providers: [
|
|
3659
|
+
{
|
|
3660
|
+
provide: NG_VALUE_ACCESSOR,
|
|
3661
|
+
useExisting: NvSidebarValueAccessor,
|
|
3662
|
+
multi: true,
|
|
3663
|
+
},
|
|
3664
|
+
],
|
|
3665
|
+
}]
|
|
3666
|
+
}], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { handleOpenChanged: [{
|
|
3667
|
+
type: HostListener,
|
|
3668
|
+
args: ['openChanged', ['$event']]
|
|
3669
|
+
}] } });
|
|
3251
3670
|
class NvSplitValueAccessor extends ValueAccessor {
|
|
3252
3671
|
constructor(el) {
|
|
3253
3672
|
super(el);
|
|
@@ -3374,6 +3793,7 @@ const VALUE_ACCESSORS = [
|
|
|
3374
3793
|
NvFieldtimeValueAccessor,
|
|
3375
3794
|
NvNotificationValueAccessor,
|
|
3376
3795
|
NvPopoverValueAccessor,
|
|
3796
|
+
NvSidebarValueAccessor,
|
|
3377
3797
|
NvSplitValueAccessor,
|
|
3378
3798
|
NvToggleValueAccessor,
|
|
3379
3799
|
NvTogglebuttongroupValueAccessor,
|
|
@@ -3393,7 +3813,7 @@ function provideNovaComponents() {
|
|
|
3393
3813
|
}
|
|
3394
3814
|
class NovaComponentsModule {
|
|
3395
3815
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
3396
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsModule, declarations: [NvAccordion, NvAccordionItem, NvAlert, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCol, NvDatagrid, NvDatagridcolumn, NvDialog, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFielddate, NvFielddaterange, NvFielddropdown, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldnumber, NvFieldpassword, NvFieldradio, NvFieldselect, NvFieldslider, NvFieldtext, NvFieldtextarea, NvFieldtime, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationcontainer, NvPopover, NvRow, NvSplit, NvStack, NvTable, NvToggle, NvTogglebutton, NvTogglebuttongroup, NvTooltip], imports: [NvDatatable], exports: [NvAccordion, NvAccordionItem, NvAlert, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCol, NvDatagrid, NvDatagridcolumn, NvDialog, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFielddate, NvFielddaterange, NvFielddropdown, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldnumber, NvFieldpassword, NvFieldradio, NvFieldselect, NvFieldslider, NvFieldtext, NvFieldtextarea, NvFieldtime, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationcontainer, NvPopover, NvRow, NvSplit, NvStack, NvTable, NvToggle, NvTogglebutton, NvTogglebuttongroup, NvTooltip, NvDatatable] }); }
|
|
3816
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsModule, declarations: [NvAccordion, NvAccordionItem, NvAlert, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCol, NvDatagrid, NvDatagridcolumn, NvDialog, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFielddate, NvFielddaterange, NvFielddropdown, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldnumber, NvFieldpassword, NvFieldradio, NvFieldselect, NvFieldslider, NvFieldtext, NvFieldtextarea, NvFieldtime, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationBullet, NvNotificationcontainer, NvPopover, NvRow, NvSidebar, NvSidebarcontent, NvSidebardivider, NvSidebarfooter, NvSidebargroup, NvSidebarheader, NvSidebarlogo, NvSidebarnavitem, NvSidebarnavsubitem, NvSplit, NvStack, NvTable, NvTableheader, NvToggle, NvTogglebutton, NvTogglebuttongroup, NvTooltip], imports: [NvDatatable], exports: [NvAccordion, NvAccordionItem, NvAlert, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCol, NvDatagrid, NvDatagridcolumn, NvDialog, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFielddate, NvFielddaterange, NvFielddropdown, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldnumber, NvFieldpassword, NvFieldradio, NvFieldselect, NvFieldslider, NvFieldtext, NvFieldtextarea, NvFieldtime, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationBullet, NvNotificationcontainer, NvPopover, NvRow, NvSidebar, NvSidebarcontent, NvSidebardivider, NvSidebarfooter, NvSidebargroup, NvSidebarheader, NvSidebarlogo, NvSidebarnavitem, NvSidebarnavsubitem, NvSplit, NvStack, NvTable, NvTableheader, NvToggle, NvTogglebutton, NvTogglebuttongroup, NvTooltip, NvDatatable] }); }
|
|
3397
3817
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsModule, providers: [provideNovaComponents()], imports: [NvDatatable] }); }
|
|
3398
3818
|
}
|
|
3399
3819
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsModule, decorators: [{
|
|
@@ -3407,7 +3827,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
3407
3827
|
}] });
|
|
3408
3828
|
class NovaComponentsValueAccessorModule {
|
|
3409
3829
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsValueAccessorModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
3410
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsValueAccessorModule, declarations: [NvAccordionValueAccessor, NvAlertValueAccessor, NvCalendarValueAccessor, NvDatagridValueAccessor, NvDialogValueAccessor, NvFieldcheckboxValueAccessor, NvFielddateValueAccessor, NvFielddaterangeValueAccessor, NvFielddropdownValueAccessor, NvFieldmultiselectValueAccessor, NvFieldnumberValueAccessor, NvFieldpasswordValueAccessor, NvFieldradioValueAccessor, NvFieldselectValueAccessor, NvFieldsliderValueAccessor, NvFieldtextValueAccessor, NvFieldtextareaValueAccessor, NvFieldtimeValueAccessor, NvNotificationValueAccessor, NvPopoverValueAccessor, NvSplitValueAccessor, NvToggleValueAccessor, NvTogglebuttongroupValueAccessor], exports: [NvAccordionValueAccessor, NvAlertValueAccessor, NvCalendarValueAccessor, NvDatagridValueAccessor, NvDialogValueAccessor, NvFieldcheckboxValueAccessor, NvFielddateValueAccessor, NvFielddaterangeValueAccessor, NvFielddropdownValueAccessor, NvFieldmultiselectValueAccessor, NvFieldnumberValueAccessor, NvFieldpasswordValueAccessor, NvFieldradioValueAccessor, NvFieldselectValueAccessor, NvFieldsliderValueAccessor, NvFieldtextValueAccessor, NvFieldtextareaValueAccessor, NvFieldtimeValueAccessor, NvNotificationValueAccessor, NvPopoverValueAccessor, NvSplitValueAccessor, NvToggleValueAccessor, NvTogglebuttongroupValueAccessor] }); }
|
|
3830
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsValueAccessorModule, declarations: [NvAccordionValueAccessor, NvAlertValueAccessor, NvCalendarValueAccessor, NvDatagridValueAccessor, NvDialogValueAccessor, NvFieldcheckboxValueAccessor, NvFielddateValueAccessor, NvFielddaterangeValueAccessor, NvFielddropdownValueAccessor, NvFieldmultiselectValueAccessor, NvFieldnumberValueAccessor, NvFieldpasswordValueAccessor, NvFieldradioValueAccessor, NvFieldselectValueAccessor, NvFieldsliderValueAccessor, NvFieldtextValueAccessor, NvFieldtextareaValueAccessor, NvFieldtimeValueAccessor, NvNotificationValueAccessor, NvPopoverValueAccessor, NvSidebarValueAccessor, NvSplitValueAccessor, NvToggleValueAccessor, NvTogglebuttongroupValueAccessor], exports: [NvAccordionValueAccessor, NvAlertValueAccessor, NvCalendarValueAccessor, NvDatagridValueAccessor, NvDialogValueAccessor, NvFieldcheckboxValueAccessor, NvFielddateValueAccessor, NvFielddaterangeValueAccessor, NvFielddropdownValueAccessor, NvFieldmultiselectValueAccessor, NvFieldnumberValueAccessor, NvFieldpasswordValueAccessor, NvFieldradioValueAccessor, NvFieldselectValueAccessor, NvFieldsliderValueAccessor, NvFieldtextValueAccessor, NvFieldtextareaValueAccessor, NvFieldtimeValueAccessor, NvNotificationValueAccessor, NvPopoverValueAccessor, NvSidebarValueAccessor, NvSplitValueAccessor, NvToggleValueAccessor, NvTogglebuttongroupValueAccessor] }); }
|
|
3411
3831
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsValueAccessorModule }); }
|
|
3412
3832
|
}
|
|
3413
3833
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NovaComponentsValueAccessorModule, decorators: [{
|
|
@@ -3442,6 +3862,7 @@ class NotificationService {
|
|
|
3442
3862
|
}
|
|
3443
3863
|
constructor() {
|
|
3444
3864
|
this._notifications = new BehaviorSubject([]);
|
|
3865
|
+
this.timers = new Map();
|
|
3445
3866
|
/**
|
|
3446
3867
|
* Observable stream of active notifications.
|
|
3447
3868
|
*/
|
|
@@ -3479,6 +3900,14 @@ class NotificationService {
|
|
|
3479
3900
|
clearRefs() {
|
|
3480
3901
|
this.elRefs.clear();
|
|
3481
3902
|
}
|
|
3903
|
+
/**
|
|
3904
|
+
* Clean up all timers and references.
|
|
3905
|
+
*/
|
|
3906
|
+
ngOnDestroy() {
|
|
3907
|
+
this.timers.forEach((timer) => clearTimeout(timer));
|
|
3908
|
+
this.timers.clear();
|
|
3909
|
+
this.clearRefs();
|
|
3910
|
+
}
|
|
3482
3911
|
/**
|
|
3483
3912
|
* Show a new notification.
|
|
3484
3913
|
*
|
|
@@ -3497,6 +3926,7 @@ class NotificationService {
|
|
|
3497
3926
|
icon: options.icon,
|
|
3498
3927
|
actions: options.actions ?? [],
|
|
3499
3928
|
actionSlot: options.actionSlot,
|
|
3929
|
+
duration: options.duration ?? 0,
|
|
3500
3930
|
createdAt: Date.now(),
|
|
3501
3931
|
};
|
|
3502
3932
|
const currentNotifications = this._notifications.value;
|
|
@@ -3511,6 +3941,13 @@ class NotificationService {
|
|
|
3511
3941
|
setTimeout(() => {
|
|
3512
3942
|
const ref = this.elRefs.get(id);
|
|
3513
3943
|
ref?.show();
|
|
3944
|
+
// Set up auto-dismiss timer if duration > 0
|
|
3945
|
+
if (notification.duration && notification.duration > 0) {
|
|
3946
|
+
const timer = setTimeout(() => {
|
|
3947
|
+
this.dismiss(id);
|
|
3948
|
+
}, notification.duration);
|
|
3949
|
+
this.timers.set(id, timer);
|
|
3950
|
+
}
|
|
3514
3951
|
}, 0);
|
|
3515
3952
|
return id;
|
|
3516
3953
|
}
|
|
@@ -3521,6 +3958,12 @@ class NotificationService {
|
|
|
3521
3958
|
* @param {string} id The notification ID to dismiss
|
|
3522
3959
|
*/
|
|
3523
3960
|
dismiss(id) {
|
|
3961
|
+
// Clear timer if exists
|
|
3962
|
+
const timer = this.timers.get(id);
|
|
3963
|
+
if (timer) {
|
|
3964
|
+
clearTimeout(timer);
|
|
3965
|
+
this.timers.delete(id);
|
|
3966
|
+
}
|
|
3524
3967
|
this.elRefs.get(id)?.dismiss?.();
|
|
3525
3968
|
}
|
|
3526
3969
|
/**
|
|
@@ -3529,6 +3972,12 @@ class NotificationService {
|
|
|
3529
3972
|
* @param {string} id The notification ID to dismiss
|
|
3530
3973
|
*/
|
|
3531
3974
|
remove(id) {
|
|
3975
|
+
// Clear timer if exists
|
|
3976
|
+
const timer = this.timers.get(id);
|
|
3977
|
+
if (timer) {
|
|
3978
|
+
clearTimeout(timer);
|
|
3979
|
+
this.timers.delete(id);
|
|
3980
|
+
}
|
|
3532
3981
|
const currentNotifications = this._notifications.value;
|
|
3533
3982
|
const filteredNotifications = currentNotifications.filter((notification) => notification.id !== id);
|
|
3534
3983
|
this._notifications.next(filteredNotifications);
|
|
@@ -3537,6 +3986,9 @@ class NotificationService {
|
|
|
3537
3986
|
* Immediately remove all active notifications.
|
|
3538
3987
|
*/
|
|
3539
3988
|
removeAll() {
|
|
3989
|
+
// Clear all timers
|
|
3990
|
+
this.timers.forEach((timer) => clearTimeout(timer));
|
|
3991
|
+
this.timers.clear();
|
|
3540
3992
|
this._notifications.next([]);
|
|
3541
3993
|
}
|
|
3542
3994
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NotificationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
@@ -3735,5 +4187,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
3735
4187
|
* Generated bundle index. Do not edit.
|
|
3736
4188
|
*/
|
|
3737
4189
|
|
|
3738
|
-
export { NotificationService, NotificationServiceComponent, NovaComponentsModule, NovaComponentsValueAccessorModule, NvAccordion, NvAccordionItem, NvAccordionValueAccessor, NvAlert, NvAlertValueAccessor, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCalendarValueAccessor, NvCol, NvDatagrid, NvDatagridValueAccessor, NvDatagridcolumn, NvDatatable, NvDatatableCellDirective, NvDialog, NvDialogValueAccessor, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFieldcheckboxValueAccessor, NvFielddate, NvFielddateValueAccessor, NvFielddaterange, NvFielddaterangeValueAccessor, NvFielddropdown, NvFielddropdownValueAccessor, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldmultiselectValueAccessor, NvFieldnumber, NvFieldnumberValueAccessor, NvFieldpassword, NvFieldpasswordValueAccessor, NvFieldradio, NvFieldradioValueAccessor, NvFieldselect, NvFieldselectValueAccessor, NvFieldslider, NvFieldsliderValueAccessor, NvFieldtext, NvFieldtextValueAccessor, NvFieldtextarea, NvFieldtextareaValueAccessor, NvFieldtime, NvFieldtimeValueAccessor, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationValueAccessor, NvNotificationcontainer, NvPopover, NvPopoverValueAccessor, NvRow, NvSplit, NvSplitValueAccessor, NvStack, NvTable, NvToggle, NvToggleValueAccessor, NvTogglebutton, NvTogglebuttongroup, NvTogglebuttongroupValueAccessor, NvTooltip, VALUE_ACCESSORS, makeColumn, flexRenderComponent as nvDatatableRenderComponent, provideNovaComponents };
|
|
4190
|
+
export { NotificationService, NotificationServiceComponent, NovaComponentsModule, NovaComponentsValueAccessorModule, NvAccordion, NvAccordionItem, NvAccordionValueAccessor, NvAlert, NvAlertValueAccessor, NvAvatar, NvBadge, NvBreadcrumb, NvBreadcrumbs, NvButton, NvButtongroup, NvCalendar, NvCalendarValueAccessor, NvCol, NvDatagrid, NvDatagridValueAccessor, NvDatagridcolumn, NvDatatable, NvDatatableCellDirective, NvDialog, NvDialogValueAccessor, NvDialogfooter, NvDialogheader, NvFieldcheckbox, NvFieldcheckboxValueAccessor, NvFielddate, NvFielddateValueAccessor, NvFielddaterange, NvFielddaterangeValueAccessor, NvFielddropdown, NvFielddropdownValueAccessor, NvFielddropdownitem, NvFielddropdownitemcheck, NvFieldmultiselect, NvFieldmultiselectValueAccessor, NvFieldnumber, NvFieldnumberValueAccessor, NvFieldpassword, NvFieldpasswordValueAccessor, NvFieldradio, NvFieldradioValueAccessor, NvFieldselect, NvFieldselectValueAccessor, NvFieldslider, NvFieldsliderValueAccessor, NvFieldtext, NvFieldtextValueAccessor, NvFieldtextarea, NvFieldtextareaValueAccessor, NvFieldtime, NvFieldtimeValueAccessor, NvIcon, NvIconbutton, NvLoader, NvMenu, NvMenuitem, NvNotification, NvNotificationBullet, NvNotificationValueAccessor, NvNotificationcontainer, NvPopover, NvPopoverValueAccessor, NvRow, NvSidebar, NvSidebarValueAccessor, NvSidebarcontent, NvSidebardivider, NvSidebarfooter, NvSidebargroup, NvSidebarheader, NvSidebarlogo, NvSidebarnavitem, NvSidebarnavsubitem, NvSplit, NvSplitValueAccessor, NvStack, NvTable, NvTableheader, NvToggle, NvToggleValueAccessor, NvTogglebutton, NvTogglebuttongroup, NvTogglebuttongroupValueAccessor, NvTooltip, VALUE_ACCESSORS, makeColumn, flexRenderComponent as nvDatatableRenderComponent, provideNovaComponents };
|
|
3739
4191
|
//# sourceMappingURL=nova-components.mjs.map
|