@ngbase/adk 0.1.9 → 0.1.11
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/collections/SelectionModel.d.ts +8 -3
- package/datepicker/datepicker-trigger.d.ts +1 -1
- package/datepicker/datepicker.d.ts +2 -2
- package/fesm2022/ngbase-adk-chip.mjs +2 -2
- package/fesm2022/ngbase-adk-chip.mjs.map +1 -1
- package/fesm2022/ngbase-adk-collections.mjs +8 -1
- package/fesm2022/ngbase-adk-collections.mjs.map +1 -1
- package/fesm2022/ngbase-adk-table.mjs +195 -81
- package/fesm2022/ngbase-adk-table.mjs.map +1 -1
- package/package.json +22 -22
- package/schematics/components/files/chip/chip-llm.md.template +1 -1
- package/schematics/components/files/form-field/input-style.directive.ts.template +5 -2
- package/schematics/components/files/list/list.ts.template +1 -1
- package/schematics/components/files/select/select.ts.template +13 -4
- package/schematics/components/files/table/table-llm.md.template +41 -1
- package/schematics/components/files/table/table.ts.template +105 -12
- package/table/body-row.d.ts +7 -3
- package/table/head-row.d.ts +10 -7
- package/table/public-api.d.ts +5 -5
- package/table/sort.d.ts +40 -0
- package/table/table.d.ts +9 -3
package/table/sort.d.ts
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { NgbColumn } from './column';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export type SortDirection = 'asc' | 'desc' | '';
|
|
4
|
+
export interface Sort {
|
|
5
|
+
active: string;
|
|
6
|
+
direction: SortDirection;
|
|
7
|
+
}
|
|
8
|
+
export type SortFn<T> = (data: T[], column: string, direction: SortDirection) => T[];
|
|
9
|
+
export declare class NgbSort<T> {
|
|
10
|
+
private readonly table;
|
|
11
|
+
readonly sortFn: import("@angular/core").InputSignal<SortFn<T> | undefined>;
|
|
12
|
+
readonly disableClear: import("@angular/core").InputSignal<boolean>;
|
|
13
|
+
readonly sortColumn: import("@angular/core").ModelSignal<string>;
|
|
14
|
+
readonly sortDirection: import("@angular/core").ModelSignal<SortDirection>;
|
|
15
|
+
readonly sortMode: import("@angular/core").InputSignal<"client" | "server">;
|
|
16
|
+
readonly sortChange: import("@angular/core").OutputEmitterRef<Sort>;
|
|
17
|
+
constructor();
|
|
18
|
+
private defaultSortFn;
|
|
19
|
+
sort(column: string, direction?: SortDirection): void;
|
|
20
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgbSort<any>, never>;
|
|
21
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NgbSort<any>, "[ngbSort]", ["ngbSort"], { "sortFn": { "alias": "sortFn"; "required": false; "isSignal": true; }; "disableClear": { "alias": "disableClear"; "required": false; "isSignal": true; }; "sortColumn": { "alias": "sortColumn"; "required": false; "isSignal": true; }; "sortDirection": { "alias": "sortDirection"; "required": false; "isSignal": true; }; "sortMode": { "alias": "sortMode"; "required": false; "isSignal": true; }; }, { "sortColumn": "sortColumnChange"; "sortDirection": "sortDirectionChange"; "sortChange": "sortChange"; }, never, never, true, never>;
|
|
22
|
+
}
|
|
23
|
+
export declare class NgbSortHeader<T extends NgbSort<U>, U = any> {
|
|
24
|
+
readonly sort: T;
|
|
25
|
+
readonly column: NgbColumn;
|
|
26
|
+
readonly disableClear: import("@angular/core").InputSignal<boolean>;
|
|
27
|
+
readonly sortDirection: import("@angular/core").Signal<SortDirection | undefined>;
|
|
28
|
+
setDirections(direction: SortDirection): void;
|
|
29
|
+
toggle(): void;
|
|
30
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NgbSortHeader<any, any>, never>;
|
|
31
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<NgbSortHeader<any, any>, "[ngbSortHeader]", never, { "disableClear": { "alias": "disableClear"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
32
|
+
}
|
|
33
|
+
export declare function aliasSort(directive: typeof NgbSort): {
|
|
34
|
+
provide: typeof NgbSort;
|
|
35
|
+
useExisting: typeof NgbSort;
|
|
36
|
+
};
|
|
37
|
+
export declare function aliasSortHeader(directive: typeof NgbSortHeader<any, any>): {
|
|
38
|
+
provide: typeof NgbSortHeader;
|
|
39
|
+
useExisting: typeof NgbSortHeader<any, any>;
|
|
40
|
+
};
|
package/table/table.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { InjectionToken } from '@angular/core';
|
|
1
|
+
import { InjectionToken, WritableSignal } from '@angular/core';
|
|
2
2
|
import { NgbColumn } from './column';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
|
-
export declare const
|
|
4
|
+
export declare const TABLE_ROW_DATA: InjectionToken<WritableSignal<any>>;
|
|
5
5
|
export declare class NgbTable<T> {
|
|
6
6
|
private readonly injector;
|
|
7
7
|
private readonly differs;
|
|
@@ -10,17 +10,23 @@ export declare class NgbTable<T> {
|
|
|
10
10
|
private readonly bodyRowDef;
|
|
11
11
|
private readonly headRowDef;
|
|
12
12
|
readonly columns: import("@angular/core").Signal<readonly NgbColumn[]>;
|
|
13
|
+
readonly plugins: WritableSignal<Set<(data: T[]) => T[]>>;
|
|
13
14
|
readonly data: import("@angular/core").InputSignal<T[]>;
|
|
14
15
|
readonly trackBy: import("@angular/core").InputSignal<(index: number, item: T) => any>;
|
|
16
|
+
protected readonly pluggedData: import("@angular/core").Signal<T[]>;
|
|
15
17
|
private _dataDiffers?;
|
|
16
18
|
private readonly _values;
|
|
17
|
-
private readonly valuesTracker;
|
|
18
19
|
constructor();
|
|
19
20
|
private _updateItemIndexContext;
|
|
20
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<NgbTable<any>, never>;
|
|
21
22
|
static ɵdir: i0.ɵɵDirectiveDeclaration<NgbTable<any>, "table[ngbTable]", never, { "data": { "alias": "data"; "required": true; "isSignal": true; }; "trackBy": { "alias": "trackBy"; "required": false; "isSignal": true; }; }, {}, ["bodyRowDef", "headRowDef", "columns"], never, true, never>;
|
|
22
23
|
}
|
|
24
|
+
export declare function aliasTable(table: typeof NgbTable): {
|
|
25
|
+
provide: typeof NgbTable;
|
|
26
|
+
useExisting: typeof NgbTable;
|
|
27
|
+
};
|
|
23
28
|
export declare class TableOutletContext<T> {
|
|
29
|
+
_data: WritableSignal<T>;
|
|
24
30
|
$implicit: T;
|
|
25
31
|
index?: number;
|
|
26
32
|
count?: number;
|