@den4ik92/ng2-smart-table 19.5.51 → 19.6.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.
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
1
2
|
import { DataSource } from '../../lib/data-source/data-source';
|
|
2
3
|
import * as i0 from "@angular/core";
|
|
3
4
|
export declare class PagerComponent {
|
|
4
5
|
readonly source: import("@angular/core").InputSignal<DataSource<any>>;
|
|
6
|
+
readonly content: import("@angular/core").InputSignal<TemplateRef<any> | undefined>;
|
|
5
7
|
protected readonly pagingConf: import("@angular/core").Signal<import("@den4ik92/ng2-smart-table").SmartTablePagerSettings>;
|
|
6
8
|
protected readonly currentPerPage: import("@angular/core").Signal<number>;
|
|
7
9
|
protected readonly currentPage: import("@angular/core").Signal<number>;
|
|
@@ -18,5 +20,5 @@ export declare class PagerComponent {
|
|
|
18
20
|
getPages(current: number, last: number, total: number): (string | number)[];
|
|
19
21
|
onChangePerPage(target: HTMLSelectElement): void;
|
|
20
22
|
static ɵfac: i0.ɵɵFactoryDeclaration<PagerComponent, never>;
|
|
21
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<PagerComponent, "ng2-smart-table-pager", never, { "source": { "alias": "source"; "required": true; "isSignal": true; }; }, {}, never,
|
|
23
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PagerComponent, "ng2-smart-table-pager", never, { "source": { "alias": "source"; "required": true; "isSignal": true; }; "content": { "alias": "content"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
|
|
22
24
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AfterViewInit, ElementRef, NgZone, OnChanges, OnDestroy, SimpleChange } from '@angular/core';
|
|
1
|
+
import { AfterViewInit, ElementRef, Injector, NgZone, OnChanges, OnDestroy, SimpleChange, TemplateRef, ViewContainerRef } from '@angular/core';
|
|
2
2
|
import { Row } from './lib/data-set/row';
|
|
3
3
|
import { DataSource } from './lib/data-source/data-source';
|
|
4
4
|
import { Grid } from './lib/grid';
|
|
@@ -7,8 +7,40 @@ import * as i0 from "@angular/core";
|
|
|
7
7
|
export declare class Ng2SmartTableComponent<T extends BaseDataType = any> implements OnChanges, OnDestroy, AfterViewInit {
|
|
8
8
|
private elementRef;
|
|
9
9
|
private ngZone;
|
|
10
|
+
private injector;
|
|
10
11
|
readonly source: import("@angular/core").InputSignal<DataSource<T>>;
|
|
11
12
|
readonly settings: import("@angular/core").InputSignal<SmartTableSettings<T>>;
|
|
13
|
+
/**
|
|
14
|
+
* @description If you want to display pagination in your custom container, you can pass it to "paginationSlot".
|
|
15
|
+
* @example
|
|
16
|
+
* <ng2-smart-table
|
|
17
|
+
* [paginationSlot]="paginationSlot">
|
|
18
|
+
* </ng2-smart-table>
|
|
19
|
+
* <div #paginationSlot>
|
|
20
|
+
* </div>
|
|
21
|
+
*/
|
|
22
|
+
readonly paginationSlot: import("@angular/core").InputSignal<ViewContainerRef | undefined>;
|
|
23
|
+
/**
|
|
24
|
+
* @description if you want to render custom data inside a container with pagination you can pass a TemplateRef
|
|
25
|
+
* @example
|
|
26
|
+
* <ng2-smart-table
|
|
27
|
+
* [paginationTemplateData]="paginationData"
|
|
28
|
+
* >
|
|
29
|
+
* </ng2-smart-table>
|
|
30
|
+
* <ng-template #paginationData
|
|
31
|
+
* >
|
|
32
|
+
* any data
|
|
33
|
+
* </ng-template>
|
|
34
|
+
* ----- or another option, will work only if you do not use paginationSlot
|
|
35
|
+
* <ng2-smart-table
|
|
36
|
+
* [paginationTemplateData]="paginationData"
|
|
37
|
+
* >
|
|
38
|
+
* <ng-container pager-content>
|
|
39
|
+
* some content will be rendered in the pager
|
|
40
|
+
* </ng-container>
|
|
41
|
+
* </ng2-smart-table>
|
|
42
|
+
*/
|
|
43
|
+
readonly paginationTemplateData: import("@angular/core").InputSignal<TemplateRef<unknown> | undefined>;
|
|
12
44
|
readonly multiRowSelect: import("@angular/core").OutputEmitterRef<SmartTableRowSelectEvent<T>>;
|
|
13
45
|
readonly rowClicked: import("@angular/core").OutputEmitterRef<SmartTableRowClickedEvent<T>>;
|
|
14
46
|
readonly columnsSorted: import("@angular/core").OutputEmitterRef<ColumnPositionState[]>;
|
|
@@ -30,7 +62,8 @@ export declare class Ng2SmartTableComponent<T extends BaseDataType = any> implem
|
|
|
30
62
|
private readonly isExternalMode;
|
|
31
63
|
private resizeObserver;
|
|
32
64
|
private resizeDebounceTimer;
|
|
33
|
-
|
|
65
|
+
private paginationComponentRef;
|
|
66
|
+
constructor(elementRef: ElementRef, ngZone: NgZone, injector: Injector);
|
|
34
67
|
ngOnChanges({ settings }: Record<string, SimpleChange>): void;
|
|
35
68
|
ngAfterViewInit(): void;
|
|
36
69
|
ngOnDestroy(): void;
|
|
@@ -50,5 +83,5 @@ export declare class Ng2SmartTableComponent<T extends BaseDataType = any> implem
|
|
|
50
83
|
private setupResizeObserver;
|
|
51
84
|
private destroyResizeObserver;
|
|
52
85
|
static ɵfac: i0.ɵɵFactoryDeclaration<Ng2SmartTableComponent<any>, never>;
|
|
53
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<Ng2SmartTableComponent<any>, "ng2-smart-table", never, { "source": { "alias": "source"; "required": true; "isSignal": true; }; "settings": { "alias": "settings"; "required": true; "isSignal": true; }; }, { "multiRowSelect": "multiRowSelect"; "rowClicked": "rowClicked"; "columnsSorted": "columnsSorted"; "deleteEmitter": "deleteEmitter"; "deleteConfirm": "deleteConfirm"; "edit": "edit"; "editConfirm": "editConfirm"; "editCancel": "editCancel"; "create": "create"; "createConfirm": "createConfirm"; "custom": "custom"; }, never,
|
|
86
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<Ng2SmartTableComponent<any>, "ng2-smart-table", never, { "source": { "alias": "source"; "required": true; "isSignal": true; }; "settings": { "alias": "settings"; "required": true; "isSignal": true; }; "paginationSlot": { "alias": "paginationSlot"; "required": false; "isSignal": true; }; "paginationTemplateData": { "alias": "paginationTemplateData"; "required": false; "isSignal": true; }; }, { "multiRowSelect": "multiRowSelect"; "rowClicked": "rowClicked"; "columnsSorted": "columnsSorted"; "deleteEmitter": "deleteEmitter"; "deleteConfirm": "deleteConfirm"; "edit": "edit"; "editConfirm": "editConfirm"; "editCancel": "editCancel"; "create": "create"; "createConfirm": "createConfirm"; "custom": "custom"; }, never, ["[pager-content]"], true, never>;
|
|
54
87
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@den4ik92/ng2-smart-table",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.6.0",
|
|
4
4
|
"description": "Angular Smart Table",
|
|
5
5
|
"author": "Den4ik92",
|
|
6
6
|
"license": "MIT",
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
"tslib": "^2.6.1"
|
|
9
9
|
},
|
|
10
10
|
"peerDependencies": {
|
|
11
|
-
"@angular/common": "^19.
|
|
12
|
-
"@angular/core": "^19.
|
|
13
|
-
"@angular/forms": "^19.
|
|
14
|
-
"@angular/cdk": "^19.
|
|
11
|
+
"@angular/common": "^19.2.14",
|
|
12
|
+
"@angular/core": "^19.2.14",
|
|
13
|
+
"@angular/forms": "^19.2.14",
|
|
14
|
+
"@angular/cdk": "^19.2.14"
|
|
15
15
|
},
|
|
16
16
|
"module": "fesm2022/den4ik92-ng2-smart-table.mjs",
|
|
17
17
|
"typings": "index.d.ts",
|