@nova-design-system/nova-angular-19 3.19.0 → 3.21.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/fesm2022/nova-components.mjs +259 -56
- package/dist/nova-components/fesm2022/nova-components.mjs.map +1 -1
- package/dist/nova-components/lib/components/nv-datatable-cell.directive.d.ts +7 -7
- package/dist/nova-components/lib/components/nv-datatable.component.d.ts +153 -56
- package/dist/nova-components/lib/nova-components.module.d.ts +1 -1
- package/dist/nova-components/lib/providers/notification.service.d.ts +7 -0
- package/dist/nova-components/lib/stencil-generated/components.d.ts +17 -3
- package/dist/nova-components/lib/stencil-generated/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -4,9 +4,9 @@ import * as i0 from "@angular/core";
|
|
|
4
4
|
/**
|
|
5
5
|
* Context type for cell templates - uses TanStack Table's CellContext directly
|
|
6
6
|
*/
|
|
7
|
-
export type NvDatatableCellContext<T> = {
|
|
7
|
+
export type NvDatatableCellContext<T, V> = {
|
|
8
8
|
/** The cell's actual value */
|
|
9
|
-
$implicit: CellContext<T,
|
|
9
|
+
$implicit: CellContext<T, V>;
|
|
10
10
|
};
|
|
11
11
|
/**
|
|
12
12
|
* Directive to mark ng-templates as cell templates for specific fields.
|
|
@@ -24,14 +24,14 @@ export type NvDatatableCellContext<T> = {
|
|
|
24
24
|
* </nv-datatable>
|
|
25
25
|
* ```
|
|
26
26
|
*/
|
|
27
|
-
export declare class NvDatatableCellDirective<T
|
|
28
|
-
template: TemplateRef<NvDatatableCellContext<T>>;
|
|
27
|
+
export declare class NvDatatableCellDirective<T, V> {
|
|
28
|
+
template: TemplateRef<NvDatatableCellContext<T, V>>;
|
|
29
29
|
/**
|
|
30
30
|
* The field name this template should render.
|
|
31
31
|
* Should match a field in your column definitions.
|
|
32
32
|
*/
|
|
33
33
|
nvDatatableCell: string;
|
|
34
|
-
constructor(template: TemplateRef<NvDatatableCellContext<T>>);
|
|
35
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<NvDatatableCellDirective<any>, never>;
|
|
36
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<NvDatatableCellDirective<any>, "ng-template[nvDatatableCell]", never, { "nvDatatableCell": { "alias": "nvDatatableCell"; "required": true; }; }, {}, never, never, true, never>;
|
|
34
|
+
constructor(template: TemplateRef<NvDatatableCellContext<T, V>>);
|
|
35
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NvDatatableCellDirective<any, any>, never>;
|
|
36
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NvDatatableCellDirective<any, any>, "ng-template[nvDatatableCell]", never, { "nvDatatableCell": { "alias": "nvDatatableCell"; "required": true; }; }, {}, never, never, true, never>;
|
|
37
37
|
}
|
|
@@ -1,32 +1,149 @@
|
|
|
1
1
|
import { TemplateRef, QueryList, AfterViewInit, OnDestroy } from '@angular/core';
|
|
2
2
|
import { NvDatatableCellDirective } from './nv-datatable-cell.directive';
|
|
3
|
-
import { type FlexRenderComponent, type ColumnDef, type CellContext } from './datatable.utils';
|
|
3
|
+
import { type FlexRenderComponent, type ColumnDef, type CellContext, type SortingState, type NoInfer } from './datatable.utils';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
5
|
+
/**
|
|
6
|
+
* A powerful, flexible datatable component built on TanStack Table.
|
|
7
|
+
* Supports custom cell rendering, column configuration, pagination, and full TypeScript typing.
|
|
8
|
+
*/
|
|
9
|
+
export declare class NvDatatable<T> implements AfterViewInit, OnDestroy {
|
|
10
|
+
/** Column definitions */
|
|
11
|
+
columns: import("@angular/core").InputSignal<NvDatatableColumn<T, keyof T, T[keyof T]>[]>;
|
|
12
|
+
/** Row data */
|
|
13
|
+
rows: import("@angular/core").InputSignal<T[]>;
|
|
14
|
+
/** Optional pagination configuration */
|
|
15
|
+
pagination: import("@angular/core").InputSignal<NvDatatablePaginationConfig | undefined>;
|
|
16
|
+
/** Optional sorting configuration */
|
|
17
|
+
sorting: import("@angular/core").InputSignal<NvDatatableSortingConfig | undefined>;
|
|
18
|
+
/** Should the header stick to the top of the table when scrolling? */
|
|
19
|
+
stickyHeader: import("@angular/core").InputSignal<boolean>;
|
|
20
|
+
/** Template for custom pagination UI */
|
|
21
|
+
paginationTemplate?: TemplateRef<{
|
|
22
|
+
$implicit: NvDatatableRenderPaginationAPI;
|
|
23
|
+
}>;
|
|
24
|
+
/** Cell templates provided via nvDatatableCell directive */
|
|
25
|
+
cellTemplates?: QueryList<NvDatatableCellDirective<T, T[keyof T]>>;
|
|
26
|
+
/** Signal to track cell templates array */
|
|
27
|
+
private cellTemplatesSignal;
|
|
28
|
+
/** Map of field names to cell templates */
|
|
29
|
+
private cellTemplateMap;
|
|
30
|
+
/** Pagination state for server mode */
|
|
31
|
+
private paginationState;
|
|
32
|
+
/** Sorting state for controlled sorting (server mode) */
|
|
33
|
+
private sortingState;
|
|
34
|
+
/** Reference to table rows for infinite scroll observer */
|
|
35
|
+
private tableRows;
|
|
36
|
+
/** Intersection observer for infinite scroll */
|
|
37
|
+
private observer;
|
|
38
|
+
/** Helper to check if using infinite scroll */
|
|
39
|
+
isInfiniteScroll: import("@angular/core").Signal<boolean>;
|
|
40
|
+
/** Computed table columns with proper typing and filtering. */
|
|
41
|
+
tableColumns: import("@angular/core").Signal<ColumnDef<T, T[keyof T]>[]>;
|
|
42
|
+
/** TanStack table instance with Signals */
|
|
43
|
+
private tableInstance;
|
|
44
|
+
/** Public getter for table instance. */
|
|
45
|
+
table(): import("@tanstack/table-core").Table<T>;
|
|
46
|
+
/**
|
|
47
|
+
* Handle sort direction change from table header
|
|
48
|
+
* @param {Event} event The sort direction change event or direction string
|
|
49
|
+
* @param {object} header The table header object
|
|
50
|
+
*/
|
|
51
|
+
handleSortDirectionChanged(event: Event | CustomEvent<string> | string, header: {
|
|
52
|
+
column: {
|
|
53
|
+
clearSorting: () => void;
|
|
54
|
+
toggleSorting: (desc?: boolean, multi?: boolean) => void;
|
|
55
|
+
};
|
|
56
|
+
}): void;
|
|
57
|
+
/** Build pagination API for template */
|
|
58
|
+
paginationAPI: import("@angular/core").Signal<NvDatatableRenderPaginationAPI | null>;
|
|
59
|
+
constructor();
|
|
60
|
+
ngAfterViewInit(): void;
|
|
61
|
+
ngOnDestroy(): void;
|
|
62
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NvDatatable<any>, never>;
|
|
63
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NvDatatable<any>, "nv-datatable", never, { "columns": { "alias": "columns"; "required": false; "isSignal": true; }; "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "pagination": { "alias": "pagination"; "required": false; "isSignal": true; }; "sorting": { "alias": "sorting"; "required": false; "isSignal": true; }; "stickyHeader": { "alias": "stickyHeader"; "required": false; "isSignal": true; }; }, {}, ["paginationTemplate", "cellTemplates"], never, true, never>;
|
|
15
64
|
}
|
|
65
|
+
/********************************* UTILS **************************************/
|
|
66
|
+
/**
|
|
67
|
+
* Creates a strongly-typed column factory for a given row type.
|
|
68
|
+
*
|
|
69
|
+
* @template Row The row data type (e.g., `Product`)
|
|
70
|
+
*
|
|
71
|
+
* @returns {function} A function that accepts a column definition and infers:
|
|
72
|
+
* - `K` as the field key (`keyof Row`)
|
|
73
|
+
* - `F` as the return type of `valueFormatter` (defaults to `Row[K]`)
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* ```ts
|
|
77
|
+
* // Define your row type
|
|
78
|
+
* interface Product {
|
|
79
|
+
* name: string;
|
|
80
|
+
* price: number;
|
|
81
|
+
* }
|
|
82
|
+
*
|
|
83
|
+
* const col = makeColumn<Product>();
|
|
84
|
+
*/
|
|
85
|
+
export declare function makeColumn<Row>(): <K extends keyof Row, F = Row[K]>(col: NvDatatableColumn<Row, K, F>) => NvDatatableColumn<Row>;
|
|
86
|
+
export { flexRenderComponent as nvDatatableRenderComponent } from './datatable.utils';
|
|
87
|
+
/********************************* TYPES **************************************/
|
|
88
|
+
export type { CellContext as NvDatatableCellContext };
|
|
16
89
|
/** Column definition for NvDatatable. */
|
|
17
|
-
export interface NvDatatableColumn<
|
|
18
|
-
|
|
90
|
+
export interface NvDatatableColumn<Row, K extends keyof Row = keyof Row, F = Row[K]> {
|
|
91
|
+
/** Field name from row data */
|
|
92
|
+
field: K;
|
|
93
|
+
/** Display name for column header */
|
|
19
94
|
headerName?: string;
|
|
95
|
+
/** Column width in pixels */
|
|
20
96
|
width?: number;
|
|
97
|
+
/** Whether column is resizable */
|
|
21
98
|
resizable?: boolean;
|
|
99
|
+
/** Whether column is hidden */
|
|
22
100
|
hidden?: boolean;
|
|
101
|
+
/**
|
|
102
|
+
* Transform the raw value before rendering. Receives the cell value and full row object.
|
|
103
|
+
* This is useful for formatting dates, converting arrays to strings, accessing nested objects, etc.
|
|
104
|
+
* The transformed value is then passed to renderCell or templates.
|
|
105
|
+
*/
|
|
106
|
+
valueFormatter?: (params: NvTableValueFormatterParams<Row, Row[K], K>) => F;
|
|
23
107
|
/**
|
|
24
108
|
* Custom cell renderer function that can return either a string or Angular TemplateRef.
|
|
25
109
|
* Use `$implicit` in your template to receive the CellContext.
|
|
110
|
+
* Note: If valueFormatter is provided, renderCell receives the formatted value.
|
|
26
111
|
*/
|
|
27
|
-
renderCell?: (context: CellContext<
|
|
28
|
-
$implicit: CellContext<
|
|
112
|
+
renderCell?: (context: CellContext<Row, F>) => string | FlexRenderComponent | TemplateRef<{
|
|
113
|
+
$implicit: CellContext<Row, F>;
|
|
29
114
|
}>;
|
|
115
|
+
/** Enable/disable sorting for this column */
|
|
116
|
+
sortable?: boolean;
|
|
117
|
+
/** Custom sorting function or built-in function name */
|
|
118
|
+
sortingFn?: ((rowA: any, rowB: any, columnId: string) => number) | string;
|
|
119
|
+
/** Start with descending sort for this column */
|
|
120
|
+
sortDescFirst?: boolean;
|
|
121
|
+
/** Invert the sort order (useful for rankings) */
|
|
122
|
+
invertSorting?: boolean;
|
|
123
|
+
/** Where to place undefined values in sort */
|
|
124
|
+
sortUndefined?: 'first' | 'last' | false | -1 | 1;
|
|
125
|
+
}
|
|
126
|
+
/** Parameters for custom cell rendering function. */
|
|
127
|
+
export interface NvTableRenderCellParams<Row, Value, Field> {
|
|
128
|
+
/** Cell value */
|
|
129
|
+
value: Value | NoInfer<Value>;
|
|
130
|
+
/** Row data */
|
|
131
|
+
row: Row;
|
|
132
|
+
/** Field name */
|
|
133
|
+
field: Field;
|
|
134
|
+
/** Row index */
|
|
135
|
+
rowIndex: number;
|
|
136
|
+
}
|
|
137
|
+
/**
|
|
138
|
+
* Parameters for valueFormatter function.
|
|
139
|
+
*/
|
|
140
|
+
export interface NvTableValueFormatterParams<Row, Value, Field> {
|
|
141
|
+
/** Cell original value */
|
|
142
|
+
value: Value;
|
|
143
|
+
/** Row data */
|
|
144
|
+
row: Row;
|
|
145
|
+
/** Field name */
|
|
146
|
+
field: Field;
|
|
30
147
|
}
|
|
31
148
|
/**
|
|
32
149
|
* Pagination configuration for NvDatatable.
|
|
@@ -93,46 +210,26 @@ export interface NvDatatableRenderPaginationAPI {
|
|
|
93
210
|
hasMore?: boolean;
|
|
94
211
|
}
|
|
95
212
|
/**
|
|
96
|
-
*
|
|
213
|
+
* Sorting configuration for NvDatatable.
|
|
214
|
+
* Supports both client-side and server-side sorting.
|
|
97
215
|
*/
|
|
98
|
-
export
|
|
99
|
-
/**
|
|
100
|
-
|
|
101
|
-
/**
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
|
|
105
|
-
/**
|
|
106
|
-
|
|
107
|
-
/**
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
/**
|
|
112
|
-
|
|
113
|
-
/** Signal to track cell templates array */
|
|
114
|
-
private cellTemplatesSignal;
|
|
115
|
-
/** Map of field names to cell templates */
|
|
116
|
-
private cellTemplateMap;
|
|
117
|
-
/** Pagination state for server mode */
|
|
118
|
-
private paginationState;
|
|
119
|
-
/** Reference to table rows for infinite scroll observer */
|
|
120
|
-
private tableRows;
|
|
121
|
-
/** Intersection observer for infinite scroll */
|
|
122
|
-
private observer;
|
|
123
|
-
/** Helper to check if using infinite scroll */
|
|
124
|
-
isInfiniteScroll: import("@angular/core").Signal<boolean>;
|
|
125
|
-
/** Computed table columns with proper typing and filtering. */
|
|
126
|
-
tableColumns: import("@angular/core").Signal<ColumnDef<T>[]>;
|
|
127
|
-
/** TanStack table instance with Signals */
|
|
128
|
-
private tableInstance;
|
|
129
|
-
/** Public getter for table instance. */
|
|
130
|
-
table(): import("@tanstack/table-core").Table<T>;
|
|
131
|
-
/** Build pagination API for template */
|
|
132
|
-
paginationAPI: import("@angular/core").Signal<NvDatatableRenderPaginationAPI | null>;
|
|
133
|
-
constructor();
|
|
134
|
-
ngAfterViewInit(): void;
|
|
135
|
-
ngOnDestroy(): void;
|
|
136
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<NvDatatable<any>, never>;
|
|
137
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<NvDatatable<any>, "nv-datatable", never, { "columns": { "alias": "columns"; "required": false; "isSignal": true; }; "rows": { "alias": "rows"; "required": false; "isSignal": true; }; "pagination": { "alias": "pagination"; "required": false; "isSignal": true; }; "stickyHeader": { "alias": "stickyHeader"; "required": false; "isSignal": true; }; }, {}, ["paginationTemplate", "cellTemplates"], never, true, never>;
|
|
216
|
+
export interface NvDatatableSortingConfig {
|
|
217
|
+
/** Sorting mode */
|
|
218
|
+
mode: 'client' | 'server';
|
|
219
|
+
/** Enable multi-column sorting with Shift+Click */
|
|
220
|
+
enableMultiSort?: boolean;
|
|
221
|
+
/** Allow cycling through to "no sort" state */
|
|
222
|
+
enableSortingRemoval?: boolean;
|
|
223
|
+
/** Maximum number of columns for multi-sort */
|
|
224
|
+
maxMultiSortColCount?: number;
|
|
225
|
+
/** Start with descending sort as first toggle state */
|
|
226
|
+
sortDescFirst?: boolean;
|
|
227
|
+
/** Controlled sort state (for server-side sorting) */
|
|
228
|
+
sortState?: SortingState;
|
|
229
|
+
/** Callback when sorting changes (for server-side sorting) */
|
|
230
|
+
onSortingChange?: (sorting: SortingState) => void;
|
|
138
231
|
}
|
|
232
|
+
/**
|
|
233
|
+
* Sorting state type - array of sort descriptors
|
|
234
|
+
*/
|
|
235
|
+
export type NvDataTableSortingState = SortingState;
|
|
@@ -4,7 +4,7 @@ import * as i2 from "./components/nv-datatable.component";
|
|
|
4
4
|
import * as i3 from "./stencil-generated/component-value-accessors";
|
|
5
5
|
export declare class NovaComponentsModule {
|
|
6
6
|
static ɵfac: i0.ɵɵFactoryDeclaration<NovaComponentsModule, never>;
|
|
7
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<NovaComponentsModule, [typeof i1.NvAccordion, typeof i1.NvAccordionItem, typeof i1.NvAlert, typeof i1.NvAvatar, typeof i1.NvBadge, typeof i1.NvBreadcrumb, typeof i1.NvBreadcrumbs, typeof i1.NvButton, typeof i1.NvButtongroup, typeof i1.NvCalendar, typeof i1.NvCol, typeof i1.NvDatagrid, typeof i1.NvDatagridcolumn, typeof i1.NvDialog, typeof i1.NvDialogfooter, typeof i1.NvDialogheader, typeof i1.NvFieldcheckbox, typeof i1.NvFielddate, typeof i1.NvFielddaterange, typeof i1.NvFielddropdown, typeof i1.NvFielddropdownitem, typeof i1.NvFielddropdownitemcheck, typeof i1.NvFieldmultiselect, typeof i1.NvFieldnumber, typeof i1.NvFieldpassword, typeof i1.NvFieldradio, typeof i1.NvFieldselect, typeof i1.NvFieldslider, typeof i1.NvFieldtext, typeof i1.NvFieldtextarea, typeof i1.NvFieldtime, typeof i1.NvIcon, typeof i1.NvIconbutton, typeof i1.NvLoader, typeof i1.NvMenu, typeof i1.NvMenuitem, typeof i1.NvNotification, typeof i1.NvNotificationcontainer, typeof i1.NvPopover, typeof i1.NvRow, typeof i1.NvSplit, typeof i1.NvStack, typeof i1.NvTable, typeof i1.NvToggle, typeof i1.NvTogglebutton, typeof i1.NvTogglebuttongroup, typeof i1.NvTooltip], [typeof i2.NvDatatable], [typeof i1.NvAccordion, typeof i1.NvAccordionItem, typeof i1.NvAlert, typeof i1.NvAvatar, typeof i1.NvBadge, typeof i1.NvBreadcrumb, typeof i1.NvBreadcrumbs, typeof i1.NvButton, typeof i1.NvButtongroup, typeof i1.NvCalendar, typeof i1.NvCol, typeof i1.NvDatagrid, typeof i1.NvDatagridcolumn, typeof i1.NvDialog, typeof i1.NvDialogfooter, typeof i1.NvDialogheader, typeof i1.NvFieldcheckbox, typeof i1.NvFielddate, typeof i1.NvFielddaterange, typeof i1.NvFielddropdown, typeof i1.NvFielddropdownitem, typeof i1.NvFielddropdownitemcheck, typeof i1.NvFieldmultiselect, typeof i1.NvFieldnumber, typeof i1.NvFieldpassword, typeof i1.NvFieldradio, typeof i1.NvFieldselect, typeof i1.NvFieldslider, typeof i1.NvFieldtext, typeof i1.NvFieldtextarea, typeof i1.NvFieldtime, typeof i1.NvIcon, typeof i1.NvIconbutton, typeof i1.NvLoader, typeof i1.NvMenu, typeof i1.NvMenuitem, typeof i1.NvNotification, typeof i1.NvNotificationcontainer, typeof i1.NvPopover, typeof i1.NvRow, typeof i1.NvSplit, typeof i1.NvStack, typeof i1.NvTable, typeof i1.NvToggle, typeof i1.NvTogglebutton, typeof i1.NvTogglebuttongroup, typeof i1.NvTooltip, typeof i2.NvDatatable]>;
|
|
7
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<NovaComponentsModule, [typeof i1.NvAccordion, typeof i1.NvAccordionItem, typeof i1.NvAlert, typeof i1.NvAvatar, typeof i1.NvBadge, typeof i1.NvBreadcrumb, typeof i1.NvBreadcrumbs, typeof i1.NvButton, typeof i1.NvButtongroup, typeof i1.NvCalendar, typeof i1.NvCol, typeof i1.NvDatagrid, typeof i1.NvDatagridcolumn, typeof i1.NvDialog, typeof i1.NvDialogfooter, typeof i1.NvDialogheader, typeof i1.NvFieldcheckbox, typeof i1.NvFielddate, typeof i1.NvFielddaterange, typeof i1.NvFielddropdown, typeof i1.NvFielddropdownitem, typeof i1.NvFielddropdownitemcheck, typeof i1.NvFieldmultiselect, typeof i1.NvFieldnumber, typeof i1.NvFieldpassword, typeof i1.NvFieldradio, typeof i1.NvFieldselect, typeof i1.NvFieldslider, typeof i1.NvFieldtext, typeof i1.NvFieldtextarea, typeof i1.NvFieldtime, typeof i1.NvIcon, typeof i1.NvIconbutton, typeof i1.NvLoader, typeof i1.NvMenu, typeof i1.NvMenuitem, typeof i1.NvNotification, typeof i1.NvNotificationcontainer, typeof i1.NvPopover, typeof i1.NvRow, typeof i1.NvSplit, typeof i1.NvStack, typeof i1.NvTable, typeof i1.NvTableheader, typeof i1.NvToggle, typeof i1.NvTogglebutton, typeof i1.NvTogglebuttongroup, typeof i1.NvTooltip], [typeof i2.NvDatatable], [typeof i1.NvAccordion, typeof i1.NvAccordionItem, typeof i1.NvAlert, typeof i1.NvAvatar, typeof i1.NvBadge, typeof i1.NvBreadcrumb, typeof i1.NvBreadcrumbs, typeof i1.NvButton, typeof i1.NvButtongroup, typeof i1.NvCalendar, typeof i1.NvCol, typeof i1.NvDatagrid, typeof i1.NvDatagridcolumn, typeof i1.NvDialog, typeof i1.NvDialogfooter, typeof i1.NvDialogheader, typeof i1.NvFieldcheckbox, typeof i1.NvFielddate, typeof i1.NvFielddaterange, typeof i1.NvFielddropdown, typeof i1.NvFielddropdownitem, typeof i1.NvFielddropdownitemcheck, typeof i1.NvFieldmultiselect, typeof i1.NvFieldnumber, typeof i1.NvFieldpassword, typeof i1.NvFieldradio, typeof i1.NvFieldselect, typeof i1.NvFieldslider, typeof i1.NvFieldtext, typeof i1.NvFieldtextarea, typeof i1.NvFieldtime, typeof i1.NvIcon, typeof i1.NvIconbutton, typeof i1.NvLoader, typeof i1.NvMenu, typeof i1.NvMenuitem, typeof i1.NvNotification, typeof i1.NvNotificationcontainer, typeof i1.NvPopover, typeof i1.NvRow, typeof i1.NvSplit, typeof i1.NvStack, typeof i1.NvTable, typeof i1.NvTableheader, typeof i1.NvToggle, typeof i1.NvTogglebutton, typeof i1.NvTogglebuttongroup, typeof i1.NvTooltip, typeof i2.NvDatatable]>;
|
|
8
8
|
static ɵinj: i0.ɵɵInjectorDeclaration<NovaComponentsModule>;
|
|
9
9
|
}
|
|
10
10
|
export declare class NovaComponentsValueAccessorModule {
|
|
@@ -35,6 +35,8 @@ export interface NotificationOptions {
|
|
|
35
35
|
actions?: NotificationAction[];
|
|
36
36
|
/** Custom components for the notification actions. */
|
|
37
37
|
actionSlot?: Type<unknown>;
|
|
38
|
+
/** Duration in milliseconds before auto-dismissing. 0 = sticky (no auto-dismiss). Default: 0 */
|
|
39
|
+
duration?: number;
|
|
38
40
|
}
|
|
39
41
|
/**
|
|
40
42
|
* A notification with all required fields populated.
|
|
@@ -60,6 +62,7 @@ export interface NotificationServiceConfig {
|
|
|
60
62
|
export declare class NotificationService {
|
|
61
63
|
private readonly _notifications;
|
|
62
64
|
private readonly _config;
|
|
65
|
+
private readonly timers;
|
|
63
66
|
/**
|
|
64
67
|
* Observable stream of active notifications.
|
|
65
68
|
*/
|
|
@@ -87,6 +90,10 @@ export declare class NotificationService {
|
|
|
87
90
|
registerRef(id: string, el: HTMLNvNotificationElement): void;
|
|
88
91
|
unregisterRef(id: string): void;
|
|
89
92
|
clearRefs(): void;
|
|
93
|
+
/**
|
|
94
|
+
* Clean up all timers and references.
|
|
95
|
+
*/
|
|
96
|
+
ngOnDestroy(): void;
|
|
90
97
|
/**
|
|
91
98
|
* Show a new notification.
|
|
92
99
|
*
|
|
@@ -103,7 +103,7 @@ export declare class NvButton {
|
|
|
103
103
|
protected el: HTMLNvButtonElement;
|
|
104
104
|
constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone);
|
|
105
105
|
static ɵfac: i0.ɵɵFactoryDeclaration<NvButton, never>;
|
|
106
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<NvButton, "nv-button", never, { "active": { "alias": "active"; "required": false; }; "danger": { "alias": "danger"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "emphasis": { "alias": "emphasis"; "required": false; }; "fluid": { "alias": "fluid"; "required": false; }; "form": { "alias": "form"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
106
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NvButton, "nv-button", never, { "active": { "alias": "active"; "required": false; }; "danger": { "alias": "danger"; "required": false; }; "disableTabindex": { "alias": "disableTabindex"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "emphasis": { "alias": "emphasis"; "required": false; }; "fluid": { "alias": "fluid"; "required": false; }; "form": { "alias": "form"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
107
107
|
}
|
|
108
108
|
export declare interface NvButton extends Components.NvButton {
|
|
109
109
|
}
|
|
@@ -360,7 +360,7 @@ export declare interface NvFieldnumber extends Components.NvFieldnumber {
|
|
|
360
360
|
/**
|
|
361
361
|
* Emitted when the input value changes. @bind value
|
|
362
362
|
*/
|
|
363
|
-
valueChanged: EventEmitter<CustomEvent<number>>;
|
|
363
|
+
valueChanged: EventEmitter<CustomEvent<number | null>>;
|
|
364
364
|
}
|
|
365
365
|
export declare class NvFieldpassword {
|
|
366
366
|
protected z: NgZone;
|
|
@@ -468,7 +468,7 @@ export declare class NvIconbutton {
|
|
|
468
468
|
protected el: HTMLNvIconbuttonElement;
|
|
469
469
|
constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone);
|
|
470
470
|
static ɵfac: i0.ɵɵFactoryDeclaration<NvIconbutton, never>;
|
|
471
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<NvIconbutton, "nv-iconbutton", never, { "active": { "alias": "active"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "emphasis": { "alias": "emphasis"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "name": { "alias": "name"; "required": false; }; "shape": { "alias": "shape"; "required": false; }; "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
471
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NvIconbutton, "nv-iconbutton", never, { "active": { "alias": "active"; "required": false; }; "disableTabindex": { "alias": "disableTabindex"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "emphasis": { "alias": "emphasis"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "name": { "alias": "name"; "required": false; }; "shape": { "alias": "shape"; "required": false; }; "size": { "alias": "size"; "required": false; }; "type": { "alias": "type"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
472
472
|
}
|
|
473
473
|
export declare interface NvIconbutton extends Components.NvIconbutton {
|
|
474
474
|
}
|
|
@@ -590,6 +590,20 @@ export declare class NvTable {
|
|
|
590
590
|
}
|
|
591
591
|
export declare interface NvTable extends Components.NvTable {
|
|
592
592
|
}
|
|
593
|
+
export declare class NvTableheader {
|
|
594
|
+
protected z: NgZone;
|
|
595
|
+
protected el: HTMLNvTableheaderElement;
|
|
596
|
+
constructor(c: ChangeDetectorRef, r: ElementRef, z: NgZone);
|
|
597
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NvTableheader, never>;
|
|
598
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NvTableheader, "nv-tableheader", never, { "sortDirection": { "alias": "sortDirection"; "required": false; }; "sortable": { "alias": "sortable"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
599
|
+
}
|
|
600
|
+
export declare interface NvTableheader extends Components.NvTableheader {
|
|
601
|
+
/**
|
|
602
|
+
* Event emitted when the sort direction changes. Payload is the new sort
|
|
603
|
+
direction.
|
|
604
|
+
*/
|
|
605
|
+
sortDirectionChanged: EventEmitter<CustomEvent<string>>;
|
|
606
|
+
}
|
|
593
607
|
export declare class NvToggle {
|
|
594
608
|
protected z: NgZone;
|
|
595
609
|
protected el: HTMLNvToggleElement;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import * as d from './components';
|
|
2
|
-
export declare const DIRECTIVES: (typeof d.NvAccordion | typeof d.NvAccordionItem | typeof d.NvAlert | typeof d.NvAvatar | typeof d.NvBadge | typeof d.NvBreadcrumb | typeof d.NvBreadcrumbs | typeof d.NvButton | typeof d.NvButtongroup | typeof d.NvCalendar | typeof d.NvCol | typeof d.NvDatagrid | typeof d.NvDatagridcolumn | typeof d.NvDialog | typeof d.NvDialogfooter | typeof d.NvDialogheader | typeof d.NvFieldcheckbox | typeof d.NvFielddate | typeof d.NvFielddaterange | typeof d.NvFielddropdown | typeof d.NvFielddropdownitem | typeof d.NvFielddropdownitemcheck | typeof d.NvFieldmultiselect | typeof d.NvFieldnumber | typeof d.NvFieldpassword | typeof d.NvFieldradio | typeof d.NvFieldselect | typeof d.NvFieldslider | typeof d.NvFieldtext | typeof d.NvFieldtextarea | typeof d.NvFieldtime | typeof d.NvIcon | typeof d.NvIconbutton | typeof d.NvLoader | typeof d.NvMenu | typeof d.NvMenuitem | typeof d.NvNotification | typeof d.NvNotificationcontainer | typeof d.NvPopover | typeof d.NvRow | typeof d.NvSplit | typeof d.NvStack | typeof d.NvTable | typeof d.NvToggle | typeof d.NvTogglebutton | typeof d.NvTogglebuttongroup | typeof d.NvTooltip)[];
|
|
2
|
+
export declare const DIRECTIVES: (typeof d.NvAccordion | typeof d.NvAccordionItem | typeof d.NvAlert | typeof d.NvAvatar | typeof d.NvBadge | typeof d.NvBreadcrumb | typeof d.NvBreadcrumbs | typeof d.NvButton | typeof d.NvButtongroup | typeof d.NvCalendar | typeof d.NvCol | typeof d.NvDatagrid | typeof d.NvDatagridcolumn | typeof d.NvDialog | typeof d.NvDialogfooter | typeof d.NvDialogheader | typeof d.NvFieldcheckbox | typeof d.NvFielddate | typeof d.NvFielddaterange | typeof d.NvFielddropdown | typeof d.NvFielddropdownitem | typeof d.NvFielddropdownitemcheck | typeof d.NvFieldmultiselect | typeof d.NvFieldnumber | typeof d.NvFieldpassword | typeof d.NvFieldradio | typeof d.NvFieldselect | typeof d.NvFieldslider | typeof d.NvFieldtext | typeof d.NvFieldtextarea | typeof d.NvFieldtime | typeof d.NvIcon | typeof d.NvIconbutton | typeof d.NvLoader | typeof d.NvMenu | typeof d.NvMenuitem | typeof d.NvNotification | typeof d.NvNotificationcontainer | typeof d.NvPopover | typeof d.NvRow | typeof d.NvSplit | typeof d.NvStack | typeof d.NvTable | typeof d.NvTableheader | typeof d.NvToggle | typeof d.NvTogglebutton | typeof d.NvTogglebuttongroup | typeof d.NvTooltip)[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nova-design-system/nova-angular-19",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.21.0",
|
|
4
4
|
"description": "Nova is a design system created by Elia Group to empower creators to efficiently build solutions that people love to use.",
|
|
5
5
|
"author": "Elia Group",
|
|
6
6
|
"homepage": "https://nova.eliagroup.io",
|