@firestitch/list 9.9.7 → 9.9.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/app/classes/actions-controller.d.ts +20 -20
- package/app/classes/columns-controller.d.ts +65 -65
- package/app/classes/data-controller.d.ts +89 -89
- package/app/classes/external-params-controller.d.ts +31 -31
- package/app/classes/index.d.ts +2 -2
- package/app/classes/list-controller.d.ts +166 -166
- package/app/classes/pagination-controller.d.ts +185 -185
- package/app/classes/persistance-controller.d.ts +7 -7
- package/app/classes/reorder-controller.d.ts +56 -56
- package/app/classes/selection-controller.d.ts +141 -141
- package/app/classes/sorting-controller.d.ts +64 -63
- package/app/components/body/body.component.d.ts +29 -29
- package/app/components/body/row/actions/actions.component.d.ts +32 -32
- package/app/components/body/row/cell/cell.component.d.ts +20 -20
- package/app/components/body/row/inline-action/inline-action.component.d.ts +10 -10
- package/app/components/body/row/row.component.d.ts +66 -66
- package/app/components/customize-cols/customize-cols.component.d.ts +14 -14
- package/app/components/footer/footer-row/footer-cell/footer-cell.component.d.ts +4 -4
- package/app/components/footer/footer-row/footer-row.component.d.ts +8 -8
- package/app/components/footer/footer.component.d.ts +8 -8
- package/app/components/head/head-cell/head-cell.component.d.ts +11 -11
- package/app/components/head/head.component.d.ts +40 -40
- package/app/components/list/list.component.d.ts +108 -108
- package/app/components/loader/loader.component.d.ts +11 -11
- package/app/components/manage-saved-filters/manage-saved-filters.component.d.ts +10 -10
- package/app/components/pagination/pagination.component.d.ts +11 -11
- package/app/components/saved-filters/saved-filters.component.d.ts +12 -12
- package/app/components/status/status.component.d.ts +18 -18
- package/app/directives/cell/cell.directive.d.ts +5 -5
- package/app/directives/column/column.directive.d.ts +24 -23
- package/app/directives/draggable-list/draggable-list.directive.d.ts +77 -77
- package/app/directives/draggable-row/draggable-row.directive.d.ts +18 -18
- package/app/directives/empty-state/empty-state.directive.d.ts +2 -2
- package/app/directives/footer/footer.directive.d.ts +5 -5
- package/app/directives/group-cell/group-cell.directive.d.ts +3 -3
- package/app/directives/group-expand-trigger/group-expand-trigger.directive.d.ts +7 -7
- package/app/directives/header/header.directive.d.ts +5 -5
- package/app/enums/button-type.enum.d.ts +7 -7
- package/app/enums/page-change-type.enum.d.ts +4 -4
- package/app/enums/pagination-strategy.enum.d.ts +5 -5
- package/app/enums/row-type.enum.d.ts +5 -5
- package/app/enums/state.enum.d.ts +9 -9
- package/app/fs-list.module.d.ts +6 -6
- package/app/fs-list.providers.d.ts +3 -3
- package/app/interfaces/cellconfig.interface.d.ts +5 -5
- package/app/interfaces/draggable-list.interface.d.ts +7 -7
- package/app/interfaces/external-params.interface.d.ts +13 -13
- package/app/interfaces/index.d.ts +3 -3
- package/app/interfaces/listconfig.interface.d.ts +220 -220
- package/app/interfaces/pagination.interface.d.ts +13 -13
- package/app/models/column.model.d.ts +48 -46
- package/app/models/row/base-row.d.ts +13 -13
- package/app/models/row/child-row.d.ts +12 -12
- package/app/models/row/group-row.d.ts +14 -14
- package/app/models/row/simple-row.d.ts +5 -5
- package/app/models/row-action.model.d.ts +29 -29
- package/app/models/row.d.ts +28 -28
- package/app/models/styleConfig.model.d.ts +31 -31
- package/app/services/group-expand-notifier.service.d.ts +8 -8
- package/bundles/firestitch-list.umd.js +5814 -5784
- package/bundles/firestitch-list.umd.js.map +1 -1
- package/bundles/firestitch-list.umd.min.js +1 -1
- package/bundles/firestitch-list.umd.min.js.map +1 -1
- package/esm2015/app/classes/actions-controller.js +55 -55
- package/esm2015/app/classes/columns-controller.js +185 -185
- package/esm2015/app/classes/data-controller.js +317 -311
- package/esm2015/app/classes/external-params-controller.js +155 -155
- package/esm2015/app/classes/index.js +3 -3
- package/esm2015/app/classes/list-controller.js +730 -730
- package/esm2015/app/classes/pagination-controller.js +461 -461
- package/esm2015/app/classes/persistance-controller.js +22 -22
- package/esm2015/app/classes/reorder-controller.js +161 -161
- package/esm2015/app/classes/selection-controller.js +444 -444
- package/esm2015/app/classes/sorting-controller.js +181 -172
- package/esm2015/app/components/body/body.component.js +103 -103
- package/esm2015/app/components/body/row/actions/actions.component.js +110 -110
- package/esm2015/app/components/body/row/cell/cell.component.js +93 -93
- package/esm2015/app/components/body/row/inline-action/inline-action.component.js +34 -34
- package/esm2015/app/components/body/row/row.component.js +267 -267
- package/esm2015/app/components/customize-cols/customize-cols.component.js +67 -67
- package/esm2015/app/components/footer/footer-row/footer-cell/footer-cell.component.js +18 -18
- package/esm2015/app/components/footer/footer-row/footer-row.component.js +35 -35
- package/esm2015/app/components/footer/footer.component.js +30 -30
- package/esm2015/app/components/head/head-cell/head-cell.component.js +35 -35
- package/esm2015/app/components/head/head.component.js +99 -99
- package/esm2015/app/components/list/list.component.js +357 -357
- package/esm2015/app/components/loader/loader.component.js +46 -46
- package/esm2015/app/components/manage-saved-filters/manage-saved-filters.component.js +75 -75
- package/esm2015/app/components/pagination/pagination.component.js +44 -44
- package/esm2015/app/components/saved-filters/saved-filters.component.js +36 -36
- package/esm2015/app/components/status/status.component.js +77 -77
- package/esm2015/app/directives/cell/cell.directive.js +21 -21
- package/esm2015/app/directives/column/column.directive.js +97 -93
- package/esm2015/app/directives/draggable-list/draggable-list.directive.js +264 -264
- package/esm2015/app/directives/draggable-row/draggable-row.directive.js +81 -81
- package/esm2015/app/directives/empty-state/empty-state.directive.js +11 -11
- package/esm2015/app/directives/footer/footer.directive.js +21 -21
- package/esm2015/app/directives/group-cell/group-cell.directive.js +12 -12
- package/esm2015/app/directives/group-expand-trigger/group-expand-trigger.directive.js +32 -32
- package/esm2015/app/directives/header/header.directive.js +21 -21
- package/esm2015/app/enums/button-type.enum.js +9 -9
- package/esm2015/app/enums/page-change-type.enum.js +6 -6
- package/esm2015/app/enums/pagination-strategy.enum.js +7 -7
- package/esm2015/app/enums/row-type.enum.js +7 -7
- package/esm2015/app/enums/state.enum.js +11 -11
- package/esm2015/app/fs-list.module.js +140 -140
- package/esm2015/app/fs-list.providers.js +4 -4
- package/esm2015/app/interfaces/cellconfig.interface.js +1 -1
- package/esm2015/app/interfaces/draggable-list.interface.js +1 -1
- package/esm2015/app/interfaces/external-params.interface.js +1 -1
- package/esm2015/app/interfaces/index.js +1 -1
- package/esm2015/app/interfaces/listconfig.interface.js +1 -1
- package/esm2015/app/interfaces/pagination.interface.js +1 -1
- package/esm2015/app/models/column.model.js +185 -175
- package/esm2015/app/models/row/base-row.js +23 -23
- package/esm2015/app/models/row/child-row.js +28 -28
- package/esm2015/app/models/row/group-row.js +41 -41
- package/esm2015/app/models/row/simple-row.js +10 -10
- package/esm2015/app/models/row-action.model.js +115 -115
- package/esm2015/app/models/row.js +77 -77
- package/esm2015/app/models/styleConfig.model.js +86 -86
- package/esm2015/app/services/group-expand-notifier.service.js +25 -25
- package/esm2015/firestitch-list.js +17 -17
- package/esm2015/public_api.js +40 -40
- package/esm5/app/classes/actions-controller.js +71 -71
- package/esm5/app/classes/columns-controller.js +236 -236
- package/esm5/app/classes/data-controller.js +373 -365
- package/esm5/app/classes/external-params-controller.js +185 -185
- package/esm5/app/classes/index.js +3 -3
- package/esm5/app/classes/list-controller.js +749 -749
- package/esm5/app/classes/pagination-controller.js +568 -568
- package/esm5/app/classes/persistance-controller.js +25 -25
- package/esm5/app/classes/reorder-controller.js +195 -195
- package/esm5/app/classes/selection-controller.js +465 -465
- package/esm5/app/classes/sorting-controller.js +204 -195
- package/esm5/app/components/body/body.component.js +104 -104
- package/esm5/app/components/body/row/actions/actions.component.js +113 -113
- package/esm5/app/components/body/row/cell/cell.component.js +95 -95
- package/esm5/app/components/body/row/inline-action/inline-action.component.js +35 -35
- package/esm5/app/components/body/row/row.component.js +295 -295
- package/esm5/app/components/customize-cols/customize-cols.component.js +69 -69
- package/esm5/app/components/footer/footer-row/footer-cell/footer-cell.component.js +20 -20
- package/esm5/app/components/footer/footer-row/footer-row.component.js +38 -38
- package/esm5/app/components/footer/footer.component.js +31 -31
- package/esm5/app/components/head/head-cell/head-cell.component.js +38 -38
- package/esm5/app/components/head/head.component.js +106 -106
- package/esm5/app/components/list/list.component.js +391 -391
- package/esm5/app/components/loader/loader.component.js +47 -47
- package/esm5/app/components/manage-saved-filters/manage-saved-filters.component.js +81 -81
- package/esm5/app/components/pagination/pagination.component.js +46 -46
- package/esm5/app/components/saved-filters/saved-filters.component.js +41 -41
- package/esm5/app/components/status/status.component.js +79 -79
- package/esm5/app/directives/cell/cell.directive.js +24 -24
- package/esm5/app/directives/column/column.directive.js +98 -94
- package/esm5/app/directives/draggable-list/draggable-list.directive.js +281 -281
- package/esm5/app/directives/draggable-row/draggable-row.directive.js +83 -83
- package/esm5/app/directives/empty-state/empty-state.directive.js +14 -14
- package/esm5/app/directives/footer/footer.directive.js +24 -24
- package/esm5/app/directives/group-cell/group-cell.directive.js +17 -17
- package/esm5/app/directives/group-expand-trigger/group-expand-trigger.directive.js +33 -33
- package/esm5/app/directives/header/header.directive.js +24 -24
- package/esm5/app/enums/button-type.enum.js +9 -9
- package/esm5/app/enums/page-change-type.enum.js +6 -6
- package/esm5/app/enums/pagination-strategy.enum.js +7 -7
- package/esm5/app/enums/row-type.enum.js +7 -7
- package/esm5/app/enums/state.enum.js +11 -11
- package/esm5/app/fs-list.module.js +145 -145
- package/esm5/app/fs-list.providers.js +4 -4
- package/esm5/app/interfaces/cellconfig.interface.js +1 -1
- package/esm5/app/interfaces/draggable-list.interface.js +1 -1
- package/esm5/app/interfaces/external-params.interface.js +1 -1
- package/esm5/app/interfaces/index.js +1 -1
- package/esm5/app/interfaces/listconfig.interface.js +1 -1
- package/esm5/app/interfaces/pagination.interface.js +1 -1
- package/esm5/app/models/column.model.js +204 -194
- package/esm5/app/models/row/base-row.js +35 -35
- package/esm5/app/models/row/child-row.js +43 -43
- package/esm5/app/models/row/group-row.js +61 -61
- package/esm5/app/models/row/simple-row.js +15 -15
- package/esm5/app/models/row-action.model.js +126 -126
- package/esm5/app/models/row.js +126 -126
- package/esm5/app/models/styleConfig.model.js +91 -91
- package/esm5/app/services/group-expand-notifier.service.js +30 -30
- package/esm5/firestitch-list.js +17 -17
- package/esm5/public_api.js +40 -40
- package/fesm2015/firestitch-list.js +5174 -5146
- package/fesm2015/firestitch-list.js.map +1 -1
- package/fesm5/firestitch-list.js +5799 -5769
- package/fesm5/firestitch-list.js.map +1 -1
- package/firestitch-list.d.ts +18 -18
- package/firestitch-list.metadata.json +1 -1
- package/package.json +1 -1
- package/public_api.d.ts +33 -33
|
@@ -1,220 +1,220 @@
|
|
|
1
|
-
import { Observable } from 'rxjs';
|
|
2
|
-
import { FsSelectionActionSelected, FsSelectionDialogConfigAction, SelectionRef } from '@firestitch/selection';
|
|
3
|
-
import { IFilterConfigItem, IFilterConfigDateItem, FsFilterPersistance, IFilterSavedFiltersConfig, FsFilterAction, ChangeFn } from '@firestitch/filter';
|
|
4
|
-
import { ActionType } from '../enums/button-type.enum';
|
|
5
|
-
import { ReorderPosition, ReorderStrategy } from '../classes/reorder-controller';
|
|
6
|
-
import { PaginationStrategy } from '../enums/pagination-strategy.enum';
|
|
7
|
-
import { RowType } from '../enums/row-type.enum';
|
|
8
|
-
import { FsListState } from '../enums/state.enum';
|
|
9
|
-
export interface FsPaging {
|
|
10
|
-
limits?: number[];
|
|
11
|
-
limit?: number;
|
|
12
|
-
page?: number;
|
|
13
|
-
pages?: number;
|
|
14
|
-
records?: number;
|
|
15
|
-
strategy?: PaginationStrategy;
|
|
16
|
-
}
|
|
17
|
-
export interface FsListConfig {
|
|
18
|
-
heading?: string;
|
|
19
|
-
trackBy?: string;
|
|
20
|
-
subheading?: string;
|
|
21
|
-
status?: boolean;
|
|
22
|
-
chips?: boolean;
|
|
23
|
-
column?: FsListColumnConfig;
|
|
24
|
-
filterInput?: boolean;
|
|
25
|
-
queryParam?: boolean;
|
|
26
|
-
paging?: FsPaging | false;
|
|
27
|
-
loadMore?: FsListLoadMoreConfig | boolean;
|
|
28
|
-
columnDefaults?: Object;
|
|
29
|
-
filters?: (IFilterConfigItem | IFilterConfigDateItem)[];
|
|
30
|
-
savedFilters?: IFilterSavedFiltersConfig;
|
|
31
|
-
persist?: FsListPersitance;
|
|
32
|
-
rowActions?: (FsListRowActionGroup | FsListRowAction)[];
|
|
33
|
-
rowClass?: (row: any) => string;
|
|
34
|
-
actions?: FsListAction[];
|
|
35
|
-
fetch?: FsListFetchFn;
|
|
36
|
-
scrollable?: FsListScrollableConfig | boolean;
|
|
37
|
-
selection?: FsListSelectionConfig;
|
|
38
|
-
initialFetch?: boolean;
|
|
39
|
-
rowEvents?: {
|
|
40
|
-
[name: string]: (event: any) => void;
|
|
41
|
-
};
|
|
42
|
-
header?: FsListHeaderConfig;
|
|
43
|
-
cell?: FsListCellConfig;
|
|
44
|
-
footer?: FsListFooterConfig;
|
|
45
|
-
reorder?: FsListReorderConfig;
|
|
46
|
-
sorts?: FsListSortsConfig[];
|
|
47
|
-
group?: FsListGroupConfig;
|
|
48
|
-
sort?: FsListSortConfig;
|
|
49
|
-
restore?: FsListRestoreConfig;
|
|
50
|
-
noResults?: FsListNoResultsConfig;
|
|
51
|
-
emptyState?: FsListEmptyStateConfig;
|
|
52
|
-
filterInit?: ChangeFn;
|
|
53
|
-
filterChange?: ChangeFn;
|
|
54
|
-
}
|
|
55
|
-
export interface FsListGroupConfig {
|
|
56
|
-
enabled?: boolean;
|
|
57
|
-
initialExpand?: boolean;
|
|
58
|
-
groupBy?: (row: any) => any;
|
|
59
|
-
compareBy?: (row: any) => any;
|
|
60
|
-
actions?: (FsListRowActionGroup | FsListRowAction)[];
|
|
61
|
-
}
|
|
62
|
-
export interface FsListLoadMoreConfig {
|
|
63
|
-
label?: string;
|
|
64
|
-
}
|
|
65
|
-
export interface FsListReorderConfig {
|
|
66
|
-
start?: () => void;
|
|
67
|
-
moved?: FsListReorderMovedCallback;
|
|
68
|
-
done?: FsListReorderDoneCallback;
|
|
69
|
-
moveDrop?: FsListReorderMoveInGroupCallback;
|
|
70
|
-
position?: ReorderPosition;
|
|
71
|
-
strategy?: ReorderStrategy;
|
|
72
|
-
label?: string;
|
|
73
|
-
menu?: boolean;
|
|
74
|
-
}
|
|
75
|
-
export declare type FsListReorderMovedCallback = (rows: FsListReorderData[]) => void;
|
|
76
|
-
export declare type FsListReorderDoneCallback = (rows: FsListReorderData[]) => void | Observable<any>;
|
|
77
|
-
export interface FsListReorderData {
|
|
78
|
-
type: RowType;
|
|
79
|
-
data: any;
|
|
80
|
-
parent: FsListReorderData;
|
|
81
|
-
}
|
|
82
|
-
export declare type FsListReorderMoveInGroupCallback = (data: {
|
|
83
|
-
row1: any;
|
|
84
|
-
row2: any;
|
|
85
|
-
group1: any;
|
|
86
|
-
group2: any;
|
|
87
|
-
}) => boolean;
|
|
88
|
-
export interface FsListHeaderConfig {
|
|
89
|
-
className?: string;
|
|
90
|
-
align?: string;
|
|
91
|
-
}
|
|
92
|
-
export interface FsListCellConfig {
|
|
93
|
-
className?: string;
|
|
94
|
-
align?: string;
|
|
95
|
-
}
|
|
96
|
-
export interface FsListFooterConfig {
|
|
97
|
-
className?: string;
|
|
98
|
-
align?: string;
|
|
99
|
-
}
|
|
100
|
-
export interface FsListSortsConfig {
|
|
101
|
-
name: string;
|
|
102
|
-
value: string;
|
|
103
|
-
direction?: 'asc' | 'desc';
|
|
104
|
-
}
|
|
105
|
-
export interface FsListSortConfig {
|
|
106
|
-
value: string;
|
|
107
|
-
direction?: 'asc' | 'desc';
|
|
108
|
-
}
|
|
109
|
-
export interface FsListScrollableConfig {
|
|
110
|
-
name: string;
|
|
111
|
-
activationDown?: number;
|
|
112
|
-
loaderDiametr?: number;
|
|
113
|
-
status?: boolean;
|
|
114
|
-
}
|
|
115
|
-
export interface FsListRestoreConfig {
|
|
116
|
-
query?: any;
|
|
117
|
-
filter?: boolean | string;
|
|
118
|
-
filterLabel?: string;
|
|
119
|
-
menuLabel?: string;
|
|
120
|
-
click?: (row: FsListAbstractRow, event?: any) => void | Observable<any>;
|
|
121
|
-
reload?: boolean;
|
|
122
|
-
}
|
|
123
|
-
export interface FsListNoResultsConfig {
|
|
124
|
-
message?: string;
|
|
125
|
-
}
|
|
126
|
-
export interface FsListSelectionConfig {
|
|
127
|
-
actions?: FsSelectionDialogConfigAction[];
|
|
128
|
-
actionSelected?: (action: FsListActionSelected) => Observable<boolean>;
|
|
129
|
-
allSelected?: () => void;
|
|
130
|
-
cancelled?: () => void;
|
|
131
|
-
selectAll?: boolean;
|
|
132
|
-
selectionChanged?: (data: any, selectedAll: boolean, selectionRef: SelectionRef) => FsSelectionDialogConfigAction[] | Observable<FsSelectionDialogConfigAction[] | void> | void;
|
|
133
|
-
}
|
|
134
|
-
export interface FsListFetchSubscription {
|
|
135
|
-
loadOffset?: boolean;
|
|
136
|
-
}
|
|
137
|
-
export declare type FsListAction = {
|
|
138
|
-
customize?: boolean;
|
|
139
|
-
} & FsFilterAction;
|
|
140
|
-
export interface FsListRowActionGroup {
|
|
141
|
-
label?: string;
|
|
142
|
-
rowActions: FsListRowAction[];
|
|
143
|
-
}
|
|
144
|
-
export interface FsListRowAction {
|
|
145
|
-
label?: string;
|
|
146
|
-
type?: ActionType;
|
|
147
|
-
className?: string;
|
|
148
|
-
icon?: string;
|
|
149
|
-
menu?: boolean;
|
|
150
|
-
click?: (row: any, event: any, index: any) => void;
|
|
151
|
-
link?: FsListRowActionLinkFn;
|
|
152
|
-
show?: (row: any, index: number) => boolean;
|
|
153
|
-
remove?: {
|
|
154
|
-
title?: string;
|
|
155
|
-
template?: string;
|
|
156
|
-
} | boolean;
|
|
157
|
-
restore?: boolean;
|
|
158
|
-
}
|
|
159
|
-
export interface FsListRowActionLinkFn {
|
|
160
|
-
(row: FsListAbstractRow): FsListRowActionLink;
|
|
161
|
-
}
|
|
162
|
-
export interface FsListRowActionLink {
|
|
163
|
-
link: any[] | string;
|
|
164
|
-
queryParams?: Record<string, any>;
|
|
165
|
-
target?: string;
|
|
166
|
-
}
|
|
167
|
-
export interface FsListAbstractRow {
|
|
168
|
-
[name: string]: any;
|
|
169
|
-
}
|
|
170
|
-
export interface FsListTrackByFn {
|
|
171
|
-
(row: FsListAbstractRow, index?: number): boolean;
|
|
172
|
-
}
|
|
173
|
-
export interface FsListTrackByTargetRowFn {
|
|
174
|
-
(listRow: FsListAbstractRow, targetRow?: FsListAbstractRow): boolean;
|
|
175
|
-
}
|
|
176
|
-
export interface FsListColumnLoadFn {
|
|
177
|
-
(): Observable<FsListColumn[]>;
|
|
178
|
-
}
|
|
179
|
-
export interface FsListColumnChangeFn {
|
|
180
|
-
(listColumns: FsListColumn[]): void;
|
|
181
|
-
}
|
|
182
|
-
export interface FsListColumnTitleFn {
|
|
183
|
-
(name: string, defaultTitle: string): string;
|
|
184
|
-
}
|
|
185
|
-
export interface FsListColumnTooltipFn {
|
|
186
|
-
(name: string, show: boolean, disabled: boolean): string;
|
|
187
|
-
}
|
|
188
|
-
export interface FsListColumnDisabledFn {
|
|
189
|
-
(name: string): boolean;
|
|
190
|
-
}
|
|
191
|
-
export interface FsListColumnSelectedFn {
|
|
192
|
-
(name: string, show: boolean): boolean;
|
|
193
|
-
}
|
|
194
|
-
export interface FsListColumnConfig {
|
|
195
|
-
load?: FsListColumnLoadFn;
|
|
196
|
-
change?: FsListColumnChangeFn;
|
|
197
|
-
title?: FsListColumnTitleFn;
|
|
198
|
-
tooltip?: FsListColumnTooltipFn;
|
|
199
|
-
disabled?: FsListColumnDisabledFn;
|
|
200
|
-
selected?: FsListColumnSelectedFn;
|
|
201
|
-
}
|
|
202
|
-
export interface FsListColumn {
|
|
203
|
-
name: string;
|
|
204
|
-
show: boolean;
|
|
205
|
-
}
|
|
206
|
-
export interface FsListActionSelected extends FsSelectionActionSelected {
|
|
207
|
-
selected: any[];
|
|
208
|
-
}
|
|
209
|
-
export interface FsListEmptyStateConfig {
|
|
210
|
-
validate: FsListStateValidationFn;
|
|
211
|
-
}
|
|
212
|
-
export interface FsListFetchOptions {
|
|
213
|
-
state: FsListState;
|
|
214
|
-
}
|
|
215
|
-
export declare type FsListPersitance = FsFilterPersistance;
|
|
216
|
-
export declare type FsListStateValidationFn = (filters: any, rows: FsListAbstractRow[]) => boolean;
|
|
217
|
-
export declare type FsListFetchFn = (query: Record<string, any>, options: FsListFetchOptions) => Observable<{
|
|
218
|
-
data: unknown[];
|
|
219
|
-
paging?: FsPaging;
|
|
220
|
-
}>;
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { FsSelectionActionSelected, FsSelectionDialogConfigAction, SelectionRef } from '@firestitch/selection';
|
|
3
|
+
import { IFilterConfigItem, IFilterConfigDateItem, FsFilterPersistance, IFilterSavedFiltersConfig, FsFilterAction, ChangeFn } from '@firestitch/filter';
|
|
4
|
+
import { ActionType } from '../enums/button-type.enum';
|
|
5
|
+
import { ReorderPosition, ReorderStrategy } from '../classes/reorder-controller';
|
|
6
|
+
import { PaginationStrategy } from '../enums/pagination-strategy.enum';
|
|
7
|
+
import { RowType } from '../enums/row-type.enum';
|
|
8
|
+
import { FsListState } from '../enums/state.enum';
|
|
9
|
+
export interface FsPaging {
|
|
10
|
+
limits?: number[];
|
|
11
|
+
limit?: number;
|
|
12
|
+
page?: number;
|
|
13
|
+
pages?: number;
|
|
14
|
+
records?: number;
|
|
15
|
+
strategy?: PaginationStrategy;
|
|
16
|
+
}
|
|
17
|
+
export interface FsListConfig {
|
|
18
|
+
heading?: string;
|
|
19
|
+
trackBy?: string;
|
|
20
|
+
subheading?: string;
|
|
21
|
+
status?: boolean;
|
|
22
|
+
chips?: boolean;
|
|
23
|
+
column?: FsListColumnConfig;
|
|
24
|
+
filterInput?: boolean;
|
|
25
|
+
queryParam?: boolean;
|
|
26
|
+
paging?: FsPaging | false;
|
|
27
|
+
loadMore?: FsListLoadMoreConfig | boolean;
|
|
28
|
+
columnDefaults?: Object;
|
|
29
|
+
filters?: (IFilterConfigItem | IFilterConfigDateItem)[];
|
|
30
|
+
savedFilters?: IFilterSavedFiltersConfig;
|
|
31
|
+
persist?: FsListPersitance;
|
|
32
|
+
rowActions?: (FsListRowActionGroup | FsListRowAction)[];
|
|
33
|
+
rowClass?: (row: any) => string;
|
|
34
|
+
actions?: FsListAction[];
|
|
35
|
+
fetch?: FsListFetchFn;
|
|
36
|
+
scrollable?: FsListScrollableConfig | boolean;
|
|
37
|
+
selection?: FsListSelectionConfig;
|
|
38
|
+
initialFetch?: boolean;
|
|
39
|
+
rowEvents?: {
|
|
40
|
+
[name: string]: (event: any) => void;
|
|
41
|
+
};
|
|
42
|
+
header?: FsListHeaderConfig;
|
|
43
|
+
cell?: FsListCellConfig;
|
|
44
|
+
footer?: FsListFooterConfig;
|
|
45
|
+
reorder?: FsListReorderConfig;
|
|
46
|
+
sorts?: FsListSortsConfig[];
|
|
47
|
+
group?: FsListGroupConfig;
|
|
48
|
+
sort?: FsListSortConfig;
|
|
49
|
+
restore?: FsListRestoreConfig;
|
|
50
|
+
noResults?: FsListNoResultsConfig;
|
|
51
|
+
emptyState?: FsListEmptyStateConfig;
|
|
52
|
+
filterInit?: ChangeFn;
|
|
53
|
+
filterChange?: ChangeFn;
|
|
54
|
+
}
|
|
55
|
+
export interface FsListGroupConfig {
|
|
56
|
+
enabled?: boolean;
|
|
57
|
+
initialExpand?: boolean;
|
|
58
|
+
groupBy?: (row: any) => any;
|
|
59
|
+
compareBy?: (row: any) => any;
|
|
60
|
+
actions?: (FsListRowActionGroup | FsListRowAction)[];
|
|
61
|
+
}
|
|
62
|
+
export interface FsListLoadMoreConfig {
|
|
63
|
+
label?: string;
|
|
64
|
+
}
|
|
65
|
+
export interface FsListReorderConfig {
|
|
66
|
+
start?: () => void;
|
|
67
|
+
moved?: FsListReorderMovedCallback;
|
|
68
|
+
done?: FsListReorderDoneCallback;
|
|
69
|
+
moveDrop?: FsListReorderMoveInGroupCallback;
|
|
70
|
+
position?: ReorderPosition;
|
|
71
|
+
strategy?: ReorderStrategy;
|
|
72
|
+
label?: string;
|
|
73
|
+
menu?: boolean;
|
|
74
|
+
}
|
|
75
|
+
export declare type FsListReorderMovedCallback = (rows: FsListReorderData[]) => void;
|
|
76
|
+
export declare type FsListReorderDoneCallback = (rows: FsListReorderData[]) => void | Observable<any>;
|
|
77
|
+
export interface FsListReorderData {
|
|
78
|
+
type: RowType;
|
|
79
|
+
data: any;
|
|
80
|
+
parent: FsListReorderData;
|
|
81
|
+
}
|
|
82
|
+
export declare type FsListReorderMoveInGroupCallback = (data: {
|
|
83
|
+
row1: any;
|
|
84
|
+
row2: any;
|
|
85
|
+
group1: any;
|
|
86
|
+
group2: any;
|
|
87
|
+
}) => boolean;
|
|
88
|
+
export interface FsListHeaderConfig {
|
|
89
|
+
className?: string;
|
|
90
|
+
align?: string;
|
|
91
|
+
}
|
|
92
|
+
export interface FsListCellConfig {
|
|
93
|
+
className?: string;
|
|
94
|
+
align?: string;
|
|
95
|
+
}
|
|
96
|
+
export interface FsListFooterConfig {
|
|
97
|
+
className?: string;
|
|
98
|
+
align?: string;
|
|
99
|
+
}
|
|
100
|
+
export interface FsListSortsConfig {
|
|
101
|
+
name: string;
|
|
102
|
+
value: string;
|
|
103
|
+
direction?: 'asc' | 'desc';
|
|
104
|
+
}
|
|
105
|
+
export interface FsListSortConfig {
|
|
106
|
+
value: string;
|
|
107
|
+
direction?: 'asc' | 'desc';
|
|
108
|
+
}
|
|
109
|
+
export interface FsListScrollableConfig {
|
|
110
|
+
name: string;
|
|
111
|
+
activationDown?: number;
|
|
112
|
+
loaderDiametr?: number;
|
|
113
|
+
status?: boolean;
|
|
114
|
+
}
|
|
115
|
+
export interface FsListRestoreConfig {
|
|
116
|
+
query?: any;
|
|
117
|
+
filter?: boolean | string;
|
|
118
|
+
filterLabel?: string;
|
|
119
|
+
menuLabel?: string;
|
|
120
|
+
click?: (row: FsListAbstractRow, event?: any) => void | Observable<any>;
|
|
121
|
+
reload?: boolean;
|
|
122
|
+
}
|
|
123
|
+
export interface FsListNoResultsConfig {
|
|
124
|
+
message?: string;
|
|
125
|
+
}
|
|
126
|
+
export interface FsListSelectionConfig {
|
|
127
|
+
actions?: FsSelectionDialogConfigAction[];
|
|
128
|
+
actionSelected?: (action: FsListActionSelected) => Observable<boolean>;
|
|
129
|
+
allSelected?: () => void;
|
|
130
|
+
cancelled?: () => void;
|
|
131
|
+
selectAll?: boolean;
|
|
132
|
+
selectionChanged?: (data: any, selectedAll: boolean, selectionRef: SelectionRef) => FsSelectionDialogConfigAction[] | Observable<FsSelectionDialogConfigAction[] | void> | void;
|
|
133
|
+
}
|
|
134
|
+
export interface FsListFetchSubscription {
|
|
135
|
+
loadOffset?: boolean;
|
|
136
|
+
}
|
|
137
|
+
export declare type FsListAction = {
|
|
138
|
+
customize?: boolean;
|
|
139
|
+
} & FsFilterAction;
|
|
140
|
+
export interface FsListRowActionGroup {
|
|
141
|
+
label?: string;
|
|
142
|
+
rowActions: FsListRowAction[];
|
|
143
|
+
}
|
|
144
|
+
export interface FsListRowAction {
|
|
145
|
+
label?: string;
|
|
146
|
+
type?: ActionType;
|
|
147
|
+
className?: string;
|
|
148
|
+
icon?: string;
|
|
149
|
+
menu?: boolean;
|
|
150
|
+
click?: (row: any, event: any, index: any) => void;
|
|
151
|
+
link?: FsListRowActionLinkFn;
|
|
152
|
+
show?: (row: any, index: number) => boolean;
|
|
153
|
+
remove?: {
|
|
154
|
+
title?: string;
|
|
155
|
+
template?: string;
|
|
156
|
+
} | boolean;
|
|
157
|
+
restore?: boolean;
|
|
158
|
+
}
|
|
159
|
+
export interface FsListRowActionLinkFn {
|
|
160
|
+
(row: FsListAbstractRow): FsListRowActionLink;
|
|
161
|
+
}
|
|
162
|
+
export interface FsListRowActionLink {
|
|
163
|
+
link: any[] | string;
|
|
164
|
+
queryParams?: Record<string, any>;
|
|
165
|
+
target?: string;
|
|
166
|
+
}
|
|
167
|
+
export interface FsListAbstractRow {
|
|
168
|
+
[name: string]: any;
|
|
169
|
+
}
|
|
170
|
+
export interface FsListTrackByFn {
|
|
171
|
+
(row: FsListAbstractRow, index?: number): boolean;
|
|
172
|
+
}
|
|
173
|
+
export interface FsListTrackByTargetRowFn {
|
|
174
|
+
(listRow: FsListAbstractRow, targetRow?: FsListAbstractRow): boolean;
|
|
175
|
+
}
|
|
176
|
+
export interface FsListColumnLoadFn {
|
|
177
|
+
(): Observable<FsListColumn[]>;
|
|
178
|
+
}
|
|
179
|
+
export interface FsListColumnChangeFn {
|
|
180
|
+
(listColumns: FsListColumn[]): void;
|
|
181
|
+
}
|
|
182
|
+
export interface FsListColumnTitleFn {
|
|
183
|
+
(name: string, defaultTitle: string): string;
|
|
184
|
+
}
|
|
185
|
+
export interface FsListColumnTooltipFn {
|
|
186
|
+
(name: string, show: boolean, disabled: boolean): string;
|
|
187
|
+
}
|
|
188
|
+
export interface FsListColumnDisabledFn {
|
|
189
|
+
(name: string): boolean;
|
|
190
|
+
}
|
|
191
|
+
export interface FsListColumnSelectedFn {
|
|
192
|
+
(name: string, show: boolean): boolean;
|
|
193
|
+
}
|
|
194
|
+
export interface FsListColumnConfig {
|
|
195
|
+
load?: FsListColumnLoadFn;
|
|
196
|
+
change?: FsListColumnChangeFn;
|
|
197
|
+
title?: FsListColumnTitleFn;
|
|
198
|
+
tooltip?: FsListColumnTooltipFn;
|
|
199
|
+
disabled?: FsListColumnDisabledFn;
|
|
200
|
+
selected?: FsListColumnSelectedFn;
|
|
201
|
+
}
|
|
202
|
+
export interface FsListColumn {
|
|
203
|
+
name: string;
|
|
204
|
+
show: boolean;
|
|
205
|
+
}
|
|
206
|
+
export interface FsListActionSelected extends FsSelectionActionSelected {
|
|
207
|
+
selected: any[];
|
|
208
|
+
}
|
|
209
|
+
export interface FsListEmptyStateConfig {
|
|
210
|
+
validate: FsListStateValidationFn;
|
|
211
|
+
}
|
|
212
|
+
export interface FsListFetchOptions {
|
|
213
|
+
state: FsListState;
|
|
214
|
+
}
|
|
215
|
+
export declare type FsListPersitance = FsFilterPersistance;
|
|
216
|
+
export declare type FsListStateValidationFn = (filters: any, rows: FsListAbstractRow[]) => boolean;
|
|
217
|
+
export declare type FsListFetchFn = (query: Record<string, any>, options: FsListFetchOptions) => Observable<{
|
|
218
|
+
data: unknown[];
|
|
219
|
+
paging?: FsPaging;
|
|
220
|
+
}>;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { PageChangeType } from '../enums/page-change-type.enum';
|
|
2
|
-
export interface QueryPageStrategy {
|
|
3
|
-
page?: number;
|
|
4
|
-
limit?: number;
|
|
5
|
-
}
|
|
6
|
-
export interface QueryOffsetStrategy {
|
|
7
|
-
offset?: number;
|
|
8
|
-
limit?: number;
|
|
9
|
-
}
|
|
10
|
-
export interface PageChange {
|
|
11
|
-
type: PageChangeType;
|
|
12
|
-
payload: any;
|
|
13
|
-
}
|
|
1
|
+
import { PageChangeType } from '../enums/page-change-type.enum';
|
|
2
|
+
export interface QueryPageStrategy {
|
|
3
|
+
page?: number;
|
|
4
|
+
limit?: number;
|
|
5
|
+
}
|
|
6
|
+
export interface QueryOffsetStrategy {
|
|
7
|
+
offset?: number;
|
|
8
|
+
limit?: number;
|
|
9
|
+
}
|
|
10
|
+
export interface PageChange {
|
|
11
|
+
type: PageChangeType;
|
|
12
|
+
payload: any;
|
|
13
|
+
}
|
|
@@ -1,46 +1,48 @@
|
|
|
1
|
-
import { TemplateRef } from '@angular/core';
|
|
2
|
-
import { Model } from 'tsmodels';
|
|
3
|
-
import { StyleConfig } from './styleConfig.model';
|
|
4
|
-
export declare enum SortingDirection {
|
|
5
|
-
asc = "asc",
|
|
6
|
-
desc = "desc"
|
|
7
|
-
}
|
|
8
|
-
export declare class Column extends Model {
|
|
9
|
-
title: string;
|
|
10
|
-
name: string;
|
|
11
|
-
show: boolean;
|
|
12
|
-
customize: boolean;
|
|
13
|
-
width: string;
|
|
14
|
-
sortable: boolean;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
get
|
|
35
|
-
get
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
2
|
+
import { Model } from 'tsmodels';
|
|
3
|
+
import { StyleConfig } from './styleConfig.model';
|
|
4
|
+
export declare enum SortingDirection {
|
|
5
|
+
asc = "asc",
|
|
6
|
+
desc = "desc"
|
|
7
|
+
}
|
|
8
|
+
export declare class Column extends Model {
|
|
9
|
+
title: string;
|
|
10
|
+
name: string;
|
|
11
|
+
show: boolean;
|
|
12
|
+
customize: boolean;
|
|
13
|
+
width: string;
|
|
14
|
+
sortable: boolean;
|
|
15
|
+
sortableDefault: boolean;
|
|
16
|
+
headerTemplate: TemplateRef<any>;
|
|
17
|
+
groupCellTemplate: TemplateRef<any>;
|
|
18
|
+
cellTemplate: TemplateRef<any>;
|
|
19
|
+
footerTemplate: TemplateRef<any>;
|
|
20
|
+
expandTrigger: TemplateRef<any>;
|
|
21
|
+
superTriger: TemplateRef<any>;
|
|
22
|
+
headerConfigs: StyleConfig;
|
|
23
|
+
groupCellConfigs: StyleConfig;
|
|
24
|
+
cellConfigs: StyleConfig;
|
|
25
|
+
footerConfigs: StyleConfig;
|
|
26
|
+
colStyles: StyleConfig;
|
|
27
|
+
sortingDirection: SortingDirection;
|
|
28
|
+
headerColspanned: boolean;
|
|
29
|
+
groupCellColspanned: boolean;
|
|
30
|
+
cellColspanned: boolean;
|
|
31
|
+
footerColspanned: boolean;
|
|
32
|
+
private _ordered;
|
|
33
|
+
constructor(colConfig?: any, colDefaults?: any);
|
|
34
|
+
get direction(): "desc" | "asc";
|
|
35
|
+
get fullNameDirection(): "Ascending" | "Descending";
|
|
36
|
+
get ordered(): boolean;
|
|
37
|
+
set ordered(value: boolean);
|
|
38
|
+
_fromJSON(value: any): void;
|
|
39
|
+
/**
|
|
40
|
+
* Merge with defaults with existing config
|
|
41
|
+
* @param defaults
|
|
42
|
+
*/
|
|
43
|
+
mergeWithColumnDefaults(defaults: any): void;
|
|
44
|
+
/**
|
|
45
|
+
* Change sorting direction
|
|
46
|
+
*/
|
|
47
|
+
changeDirection(): void;
|
|
48
|
+
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { RowType } from '../../enums/row-type.enum';
|
|
2
|
-
import { FsListReorderData } from '../../interfaces';
|
|
3
|
-
export declare abstract class BaseRow {
|
|
4
|
-
index: number;
|
|
5
|
-
readyToSwap: boolean;
|
|
6
|
-
protected readonly _rowType: RowType;
|
|
7
|
-
private readonly _data;
|
|
8
|
-
constructor(data?: any, rowType?: RowType);
|
|
9
|
-
get data(): any;
|
|
10
|
-
get type(): RowType;
|
|
11
|
-
getReorderData(): FsListReorderData;
|
|
12
|
-
abstract destroy(): any;
|
|
13
|
-
}
|
|
1
|
+
import { RowType } from '../../enums/row-type.enum';
|
|
2
|
+
import { FsListReorderData } from '../../interfaces';
|
|
3
|
+
export declare abstract class BaseRow {
|
|
4
|
+
index: number;
|
|
5
|
+
readyToSwap: boolean;
|
|
6
|
+
protected readonly _rowType: RowType;
|
|
7
|
+
private readonly _data;
|
|
8
|
+
constructor(data?: any, rowType?: RowType);
|
|
9
|
+
get data(): any;
|
|
10
|
+
get type(): RowType;
|
|
11
|
+
getReorderData(): FsListReorderData;
|
|
12
|
+
abstract destroy(): any;
|
|
13
|
+
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { BaseRow } from './base-row';
|
|
2
|
-
import { GroupRow } from './group-row';
|
|
3
|
-
import { FsListReorderData } from '../../interfaces';
|
|
4
|
-
export declare class ChildRow extends BaseRow {
|
|
5
|
-
visible: boolean;
|
|
6
|
-
private readonly _parent;
|
|
7
|
-
constructor(data?: any, parent?: GroupRow);
|
|
8
|
-
get parent(): GroupRow;
|
|
9
|
-
get isChild(): boolean;
|
|
10
|
-
getReorderData(): FsListReorderData;
|
|
11
|
-
destroy(): void;
|
|
12
|
-
}
|
|
1
|
+
import { BaseRow } from './base-row';
|
|
2
|
+
import { GroupRow } from './group-row';
|
|
3
|
+
import { FsListReorderData } from '../../interfaces';
|
|
4
|
+
export declare class ChildRow extends BaseRow {
|
|
5
|
+
visible: boolean;
|
|
6
|
+
private readonly _parent;
|
|
7
|
+
constructor(data?: any, parent?: GroupRow);
|
|
8
|
+
get parent(): GroupRow;
|
|
9
|
+
get isChild(): boolean;
|
|
10
|
+
getReorderData(): FsListReorderData;
|
|
11
|
+
destroy(): void;
|
|
12
|
+
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { BaseRow } from './base-row';
|
|
2
|
-
import { ChildRow } from './child-row';
|
|
3
|
-
export declare class GroupRow extends BaseRow {
|
|
4
|
-
children: ChildRow[];
|
|
5
|
-
private readonly _expanded;
|
|
6
|
-
constructor(data?: any, initialExpand?: boolean);
|
|
7
|
-
get isGroup(): boolean;
|
|
8
|
-
get expanded(): boolean;
|
|
9
|
-
get expanded$(): import("rxjs").Observable<boolean>;
|
|
10
|
-
updateChildrenIndexes(): void;
|
|
11
|
-
updateChildrenVisibility(): void;
|
|
12
|
-
toggleRowExpandStatus(): void;
|
|
13
|
-
destroy(): void;
|
|
14
|
-
}
|
|
1
|
+
import { BaseRow } from './base-row';
|
|
2
|
+
import { ChildRow } from './child-row';
|
|
3
|
+
export declare class GroupRow extends BaseRow {
|
|
4
|
+
children: ChildRow[];
|
|
5
|
+
private readonly _expanded;
|
|
6
|
+
constructor(data?: any, initialExpand?: boolean);
|
|
7
|
+
get isGroup(): boolean;
|
|
8
|
+
get expanded(): boolean;
|
|
9
|
+
get expanded$(): import("rxjs").Observable<boolean>;
|
|
10
|
+
updateChildrenIndexes(): void;
|
|
11
|
+
updateChildrenVisibility(): void;
|
|
12
|
+
toggleRowExpandStatus(): void;
|
|
13
|
+
destroy(): void;
|
|
14
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BaseRow } from './base-row';
|
|
2
|
-
export declare class SimpleRow extends BaseRow {
|
|
3
|
-
constructor(data?: any);
|
|
4
|
-
destroy(): void;
|
|
5
|
-
}
|
|
1
|
+
import { BaseRow } from './base-row';
|
|
2
|
+
export declare class SimpleRow extends BaseRow {
|
|
3
|
+
constructor(data?: any);
|
|
4
|
+
destroy(): void;
|
|
5
|
+
}
|