@zeedhi/teknisa-components-common 1.117.1 → 3.0.1
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/.package.json +43 -0
- package/dist/teknisa-components-common.js +3802 -0
- package/dist/teknisa-components-common.min.js +3802 -0
- package/dist/types/components/index.d.ts +7 -0
- package/{types → dist/types}/components/tek-breadcrumb-header/breadcrumb-header.d.ts +12 -12
- package/{types → dist/types}/components/tek-breadcrumb-header/interfaces.d.ts +6 -6
- package/dist/types/components/tek-datasource/index.d.ts +3 -0
- package/{types → dist/types}/components/tek-datasource/interfaces.d.ts +16 -16
- package/{types/components/tek-datasource/memory-datasource.d.ts → dist/types/components/tek-datasource/tek-memory-datasource.d.ts} +93 -100
- package/{types/components/tek-datasource/rest-datasource.d.ts → dist/types/components/tek-datasource/tek-rest-datasource.d.ts} +95 -103
- package/dist/types/components/tek-grid/columns-searcher.d.ts +5 -0
- package/dist/types/components/tek-grid/dynamic-filter-datasource-factory.d.ts +6 -0
- package/{types → dist/types}/components/tek-grid/filter-helper.d.ts +7 -7
- package/{types → dist/types}/components/tek-grid/grid-filter-button.d.ts +29 -31
- package/dist/types/components/tek-grid/grouped-data-manager.d.ts +82 -0
- package/dist/types/components/tek-grid/grouped-data-selector.d.ts +7 -0
- package/dist/types/components/tek-grid/grouped-view-navigator.d.ts +14 -0
- package/dist/types/components/tek-grid/index.d.ts +18 -0
- package/dist/types/components/tek-grid/interfaces.d.ts +259 -0
- package/dist/types/components/tek-grid/keymap-grouped.d.ts +6 -0
- package/{types → dist/types}/components/tek-grid/layout-options.d.ts +39 -31
- package/{types/components/tek-grid/grid-column.d.ts → dist/types/components/tek-grid/tek-grid-column.d.ts} +42 -45
- package/{types/components/tek-grid/grid-columns-button-controller.d.ts → dist/types/components/tek-grid/tek-grid-columns-button/tek-grid-columns-button-controller.d.ts} +8 -8
- package/{types/components/tek-grid/grid-columns-button.d.ts → dist/types/components/tek-grid/tek-grid-columns-button/tek-grid-columns-button.d.ts} +13 -12
- package/dist/types/components/tek-grid/tek-grid-controller.d.ts +31 -0
- package/dist/types/components/tek-grid/tek-grid-events.d.ts +31 -0
- package/{types/utils/grid-base → dist/types/components/tek-grid/tek-grid-toolbar-provider}/export-options/button-option.d.ts +17 -16
- package/{types/utils/grid-base → dist/types/components/tek-grid/tek-grid-toolbar-provider}/export-options/index.d.ts +3 -3
- package/dist/types/components/tek-grid/tek-grid-toolbar-provider/export-options/interfaces.d.ts +5 -0
- package/{types/utils/grid-base → dist/types/components/tek-grid/tek-grid-toolbar-provider}/export-options/multi-option.d.ts +12 -12
- package/dist/types/components/tek-grid/tek-grid-toolbar-provider/index.d.ts +2 -0
- package/dist/types/components/tek-grid/tek-grid-toolbar-provider/tek-grid-toolbar-provider.d.ts +22 -0
- package/dist/types/components/tek-grid/tek-grid.d.ts +216 -0
- package/{types → dist/types}/components/tek-user-info/TekUserInfoController.d.ts +22 -21
- package/{types → dist/types}/components/tek-user-info/interfaces.d.ts +27 -28
- package/{types → dist/types}/components/tek-user-info/tek-user-info-list.d.ts +32 -31
- package/{types → dist/types}/components/tek-user-info/tek-user-info.d.ts +37 -38
- package/{types → dist/types}/error/delete-rows-error.d.ts +6 -6
- package/dist/types/error/tek-grid-delete-rows-error.d.ts +7 -0
- package/dist/types/error/teknisa-common-error.d.ts +6 -0
- package/dist/types/index.d.ts +2 -0
- package/{types → dist/types}/utils/config/config.d.ts +7 -7
- package/dist/types/utils/index.d.ts +3 -0
- package/dist/types/utils/is-filled-object/is-filled-object.d.ts +2 -0
- package/dist/types/utils/is-nil.d.ts +1 -0
- package/environments.json +14 -0
- package/package.json +26 -18
- package/src/components/index.ts +101 -0
- package/src/components/tek-breadcrumb-header/breadcrumb-header.ts +29 -0
- package/src/components/tek-breadcrumb-header/interfaces.ts +7 -0
- package/src/components/tek-datasource/index.ts +3 -0
- package/src/components/tek-datasource/interfaces.ts +36 -0
- package/src/components/tek-datasource/tek-memory-datasource.ts +314 -0
- package/src/components/tek-datasource/tek-rest-datasource.ts +224 -0
- package/src/components/tek-grid/columns-searcher.ts +22 -0
- package/src/components/tek-grid/dynamic-filter-datasource-factory.ts +20 -0
- package/src/components/tek-grid/filter-helper.ts +20 -0
- package/src/components/tek-grid/grid-filter-button.ts +419 -0
- package/src/components/tek-grid/grouped-data-manager.ts +448 -0
- package/src/components/tek-grid/grouped-data-selector.ts +40 -0
- package/src/components/tek-grid/grouped-view-navigator.ts +84 -0
- package/src/components/tek-grid/index.ts +18 -0
- package/src/components/tek-grid/interfaces.ts +329 -0
- package/src/components/tek-grid/keymap-grouped.ts +20 -0
- package/src/components/tek-grid/layout-options.ts +248 -0
- package/src/components/tek-grid/tek-grid-column.ts +193 -0
- package/src/components/tek-grid/tek-grid-columns-button/tek-grid-columns-button-controller.ts +28 -0
- package/src/components/tek-grid/tek-grid-columns-button/tek-grid-columns-button.ts +38 -0
- package/src/components/tek-grid/tek-grid-controller.ts +140 -0
- package/src/components/tek-grid/tek-grid-events.ts +105 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/export-options/button-option.ts +26 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/export-options/index.ts +3 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/export-options/interfaces.ts +6 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/export-options/multi-option.ts +85 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/index.ts +2 -0
- package/src/components/tek-grid/tek-grid-toolbar-provider/tek-grid-toolbar-provider.ts +365 -0
- package/src/components/tek-grid/tek-grid.ts +1118 -0
- package/src/components/tek-user-info/TekUserInfoController.ts +87 -0
- package/src/components/tek-user-info/interfaces.ts +21 -0
- package/src/components/tek-user-info/tek-user-info-list.ts +64 -0
- package/src/components/tek-user-info/tek-user-info.ts +337 -0
- package/src/error/tek-grid-delete-rows-error.ts +15 -0
- package/src/error/teknisa-common-error.ts +8 -0
- package/src/index.ts +2 -0
- package/src/utils/config/config.ts +8 -0
- package/src/utils/index.ts +3 -0
- package/src/utils/is-filled-object/is-filled-object.ts +5 -0
- package/src/utils/is-nil.ts +3 -0
- package/tests/__helpers__/component-event-helper.ts +1 -1
- package/tests/__helpers__/get-child-helper.ts +1 -1
- package/tests/__helpers__/mock-created-helper.ts +1 -1
- package/tests/unit/components/crud/crud-button.spec.ts +1 -1
- package/tests/unit/components/tek-datasource/memory-datasource.spec.ts +1 -11
- package/tests/unit/components/tek-datasource/rest-datasource.spec.ts +5 -7
- package/tests/unit/components/tek-drag-grid/tek-drag-grid.spec.ts +1 -1
- package/tests/unit/components/tek-grid/button-option.spec.ts +49 -0
- package/tests/unit/components/tek-grid/columns-searcher.spec.ts +112 -0
- package/tests/unit/components/tek-grid/dynamic-filter-datasource-factory.spec.ts +90 -0
- package/tests/unit/components/tek-grid/filter-helper.spec.ts +34 -130
- package/tests/unit/components/tek-grid/grid-filter-button.spec.ts +114 -239
- package/tests/unit/components/tek-grid/grouped-data-manager.spec.ts +593 -0
- package/tests/unit/components/tek-grid/grouped-data-selector.spec.ts +136 -0
- package/tests/unit/components/tek-grid/grouped-view-navigator.spec.ts +244 -0
- package/tests/unit/components/tek-grid/keymap-grouped.spec.ts +20 -0
- package/tests/unit/components/tek-grid/{layout_options.spec.ts → layout-options.spec.ts} +70 -30
- package/tests/unit/components/tek-grid/multi-option.spec.ts +139 -0
- package/tests/unit/components/tek-grid/{grid-column.spec.ts → tek-grid-column.spec.ts} +44 -2
- package/tests/unit/components/tek-grid/{grid-columns-button.spec.ts → tek-grid-columns-button.spec.ts} +42 -9
- package/tests/unit/components/tek-grid/tek-grid-controller.spec.ts +253 -0
- package/tests/unit/components/tek-grid/tek-grid-events.spec.ts +186 -0
- package/tests/unit/components/tek-grid/tek-grid-toolbar-provider.spec.ts +34 -0
- package/tests/unit/components/tek-grid/tek-grid.spec.ts +895 -0
- package/tests/unit/components/tek-grid/tek-memory-datasource.spec.ts +482 -0
- package/tests/unit/components/tek-grid/tek-rest-datasource.spec.ts +422 -0
- package/tests/unit/components/tek-user-info/tek-user-info-list.spec.ts +1 -1
- package/tests/unit/components/tek-user-info/tek-user-info.spec.ts +10 -14
- package/tests/unit/components/tree-grid/tree-grid.spec.ts +4 -28
- package/tests/unit/utils/grid-base/export-options/multi-option.spec.ts +2 -2
- package/tests/unit/utils/grid-base/grid-controller.spec.ts +17 -152
- package/tsconfig.build.json +7 -0
- package/coverage/clover.xml +0 -2007
- package/coverage/coverage-final.json +0 -48
- package/coverage/lcov-report/base.css +0 -224
- package/coverage/lcov-report/block-navigation.js +0 -87
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +0 -431
- package/coverage/lcov-report/prettify.css +0 -1
- package/coverage/lcov-report/prettify.js +0 -2
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +0 -210
- package/coverage/lcov-report/tests/__helpers__/component-event-helper.ts.html +0 -100
- package/coverage/lcov-report/tests/__helpers__/flush-promises-helper.ts.html +0 -94
- package/coverage/lcov-report/tests/__helpers__/get-child-helper.ts.html +0 -166
- package/coverage/lcov-report/tests/__helpers__/index.html +0 -176
- package/coverage/lcov-report/tests/__helpers__/index.ts.html +0 -94
- package/coverage/lcov-report/tests/__helpers__/mock-created-helper.ts.html +0 -121
- package/coverage/lcov.info +0 -3885
- package/dist/tek-components-common.esm.js +0 -4833
- package/dist/tek-components-common.umd.js +0 -4870
- package/tests/unit/components/tek-grid/grid.spec.ts +0 -3377
- package/tests/unit/utils/grid-base/delete-rows-error.spec.ts +0 -24
- package/types/components/crud/crud-add-button.d.ts +0 -38
- package/types/components/crud/crud-button.d.ts +0 -27
- package/types/components/crud/crud-cancel-button.d.ts +0 -28
- package/types/components/crud/crud-delete-button.d.ts +0 -42
- package/types/components/crud/crud-form.d.ts +0 -46
- package/types/components/crud/crud-save-button.d.ts +0 -24
- package/types/components/crud/interfaces.d.ts +0 -15
- package/types/components/index.d.ts +0 -41
- package/types/components/tek-card-title/card-title.d.ts +0 -14
- package/types/components/tek-card-title/interfaces.d.ts +0 -9
- package/types/components/tek-drag-grid/interfaces.d.ts +0 -7
- package/types/components/tek-drag-grid/tek-drag-grid.d.ts +0 -36
- package/types/components/tek-grid/grid.d.ts +0 -267
- package/types/components/tek-grid/interfaces.d.ts +0 -203
- package/types/components/tek-image/image.d.ts +0 -55
- package/types/components/tek-image/interfaces.d.ts +0 -12
- package/types/components/tek-iterable-carousel/interfaces.d.ts +0 -5
- package/types/components/tek-iterable-carousel/iterable-carousel.d.ts +0 -13
- package/types/components/tek-iterable-component-render/interfaces.d.ts +0 -3
- package/types/components/tek-iterable-component-render/iterable-component-render.d.ts +0 -10
- package/types/components/tek-loading/interfaces.d.ts +0 -6
- package/types/components/tek-loading/loading.d.ts +0 -24
- package/types/components/tek-notifications/interfaces.d.ts +0 -22
- package/types/components/tek-notifications/notifications.d.ts +0 -35
- package/types/components/tek-product-card/interfaces.d.ts +0 -19
- package/types/components/tek-product-card/product-card.d.ts +0 -66
- package/types/components/tek-tree-grid/interfaces.d.ts +0 -30
- package/types/components/tek-tree-grid/tree-grid.d.ts +0 -102
- package/types/error/incomplete-groups-error.d.ts +0 -8
- package/types/index.d.ts +0 -2
- package/types/utils/extract-properties.d.ts +0 -7
- package/types/utils/grid-base/export-options/interfaces.d.ts +0 -5
- package/types/utils/grid-base/grid-base.d.ts +0 -59
- package/types/utils/grid-base/grid-controller.d.ts +0 -27
- package/types/utils/index.d.ts +0 -6
- package/types/utils/report-filter/report-filter.d.ts +0 -12
|
@@ -1,203 +0,0 @@
|
|
|
1
|
-
import { IBeforeReportEvent, IComponent, IComponentEvents, IComponentRender, IGridColumnEditable, IGridEditable, IIterableColumnsButton, EventDef, IModal, IButton, LabelFormatter } from '@zeedhi/common';
|
|
2
|
-
import { IDictionary, IEvent, IEventParam, IDateHelperValue, IDateHelperValues } from '@zeedhi/core';
|
|
3
|
-
import { IDynamicFilterItem, TekGrid, TekGridLayoutOptions, TekTreeGrid } from '..';
|
|
4
|
-
export interface ITekGridLayoutEventParams extends IEventParam<ITekGrid> {
|
|
5
|
-
layouts: ITekGridLayoutInfo;
|
|
6
|
-
}
|
|
7
|
-
export interface ITekGridCalcSummaryEventParams extends IEventParam<ITekGrid> {
|
|
8
|
-
summary: ITekGridSummary;
|
|
9
|
-
columnName: string;
|
|
10
|
-
rowValue: IDictionary<any>;
|
|
11
|
-
}
|
|
12
|
-
export declare type ITekGridEvent<T> = (event: T) => Promise<any>;
|
|
13
|
-
export interface ITekGridEvents<T = IEventParam<any> | ITekGridLayoutEventParams | ITekGridCalcSummaryEventParams> extends IComponentEvents<T> {
|
|
14
|
-
addClick?: EventDef<T>;
|
|
15
|
-
afterCancel?: EventDef<T>;
|
|
16
|
-
afterDelete?: EventDef<T>;
|
|
17
|
-
afterSave?: EventDef<T>;
|
|
18
|
-
beforeApplyFilter?: EventDef<T>;
|
|
19
|
-
beforeCancel?: EventDef<T>;
|
|
20
|
-
beforeDelete?: EventDef<T>;
|
|
21
|
-
beforeSave?: EventDef<T>;
|
|
22
|
-
calcSummary?: EventDef<T>;
|
|
23
|
-
filterClick?: EventDef<T>;
|
|
24
|
-
loadLayouts?: EventDef<T, ITekGridEvent<T>>;
|
|
25
|
-
saveLayouts?: EventDef<T>;
|
|
26
|
-
groupRowClick?: EventDef<T>;
|
|
27
|
-
groupSelect?: EventDef<T>;
|
|
28
|
-
groupUnselect?: EventDef<T>;
|
|
29
|
-
beforeOpenReport?: EventDef<T, IBeforeReportEvent>;
|
|
30
|
-
beforeReload?: EventDef<T>;
|
|
31
|
-
[key: string]: any;
|
|
32
|
-
}
|
|
33
|
-
export declare type ITekGridLayoutOptionsEvent<T> = (event: T) => Promise<any>;
|
|
34
|
-
export interface ITekGridLayoutOptionsEvents<T = IEventParam<any> | ITekGridLayoutEventParams> extends IComponentEvents<T> {
|
|
35
|
-
loadLayouts?: ITekGridEvent<T>;
|
|
36
|
-
saveLayouts?: IEvent<T>;
|
|
37
|
-
[key: string]: any;
|
|
38
|
-
}
|
|
39
|
-
export interface ITekGrid extends IGridEditable {
|
|
40
|
-
actions?: IComponentRender[];
|
|
41
|
-
addButton?: boolean;
|
|
42
|
-
columnFilterButton?: boolean;
|
|
43
|
-
columns?: ITekGridColumn[];
|
|
44
|
-
columnsButton?: boolean;
|
|
45
|
-
columnsButtonIgnore?: string[];
|
|
46
|
-
deleteButton?: 'none' | 'currentRow' | 'selection';
|
|
47
|
-
events?: ITekGridEvents;
|
|
48
|
-
showEditButtons?: boolean;
|
|
49
|
-
filterButton?: boolean;
|
|
50
|
-
modalFilterProps?: IModalFilterProps;
|
|
51
|
-
showSearch?: boolean;
|
|
52
|
-
showHideButton?: boolean;
|
|
53
|
-
showLayoutOptions?: boolean;
|
|
54
|
-
title?: string;
|
|
55
|
-
showExport?: boolean;
|
|
56
|
-
showReload?: boolean;
|
|
57
|
-
exportConfig?: ITekGridExportConfig[];
|
|
58
|
-
exportActions?: IComponentRender[];
|
|
59
|
-
groupsOpened?: boolean;
|
|
60
|
-
showSummaryTotal?: boolean;
|
|
61
|
-
layoutOptions?: TekGridLayoutOptions;
|
|
62
|
-
mainGrid?: boolean;
|
|
63
|
-
showCheckboxAllFilter?: boolean;
|
|
64
|
-
defaultFilter?: IDictionary;
|
|
65
|
-
xlsDefaultType?: string;
|
|
66
|
-
toolbarOpened?: boolean;
|
|
67
|
-
reportTitle?: string;
|
|
68
|
-
reportLabelFormatter?: LabelFormatter;
|
|
69
|
-
}
|
|
70
|
-
export declare type MultiOptionParams = {
|
|
71
|
-
iconName: string;
|
|
72
|
-
label: string;
|
|
73
|
-
cssClass?: string;
|
|
74
|
-
reportParams?: {
|
|
75
|
-
portrait?: boolean;
|
|
76
|
-
rowObj?: any;
|
|
77
|
-
};
|
|
78
|
-
};
|
|
79
|
-
export interface ITekGridExportConfig {
|
|
80
|
-
type: string;
|
|
81
|
-
portrait?: boolean;
|
|
82
|
-
label?: string;
|
|
83
|
-
iconName?: string;
|
|
84
|
-
multiOption?: MultiOptionParams[];
|
|
85
|
-
}
|
|
86
|
-
export interface ITekGridLayoutInfo {
|
|
87
|
-
currentLayoutName?: string;
|
|
88
|
-
layouts?: IDictionary<ITekGridLayout>;
|
|
89
|
-
}
|
|
90
|
-
export interface ITekGridLayout {
|
|
91
|
-
name: string;
|
|
92
|
-
gridWidth?: string;
|
|
93
|
-
columns?: ITekGridLayoutColumn[];
|
|
94
|
-
order?: string[];
|
|
95
|
-
dynamicFilter?: IDictionary<IDynamicFilterItem[]>;
|
|
96
|
-
filter?: IDictionary<any>;
|
|
97
|
-
}
|
|
98
|
-
export declare const columnAggregationValues: ["SUM", "MIN", "MAX", "AVG", "COUNT", undefined];
|
|
99
|
-
export declare type ITekGridColumnAggregation = (typeof columnAggregationValues)[number];
|
|
100
|
-
export interface ITekGridLayoutColumn {
|
|
101
|
-
name: string;
|
|
102
|
-
width?: string;
|
|
103
|
-
minWidth?: string;
|
|
104
|
-
maxWidth?: string;
|
|
105
|
-
isVisible?: boolean;
|
|
106
|
-
fixed?: boolean;
|
|
107
|
-
grouped?: boolean;
|
|
108
|
-
aggregation?: ITekGridColumnAggregation;
|
|
109
|
-
label?: string;
|
|
110
|
-
align?: 'left' | 'right' | 'center';
|
|
111
|
-
groupOpened?: boolean;
|
|
112
|
-
filterHelperValue?: string | IDictionary<any>;
|
|
113
|
-
}
|
|
114
|
-
export interface ITekGridLayoutOptions extends IComponentRender {
|
|
115
|
-
events?: ITekGridLayoutOptionsEvents;
|
|
116
|
-
}
|
|
117
|
-
export declare type IFilterRelation = 'AND' | 'OR';
|
|
118
|
-
export declare type IFilterOperation = 'CONTAINS' | 'NOT_CONTAINS' | 'EQUALS' | 'NOT_EQUALS' | 'GREATER_THAN' | 'LESS_THAN' | 'GREATER_THAN_EQUALS' | 'LESS_THAN_EQUALS' | 'IN' | 'NOT_IN' | 'BETWEEN';
|
|
119
|
-
export interface IFilterPropsComponent extends IComponent {
|
|
120
|
-
relation?: IFilterRelation;
|
|
121
|
-
operation?: IFilterOperation;
|
|
122
|
-
helperOptions?: string[];
|
|
123
|
-
helperValue?: string;
|
|
124
|
-
}
|
|
125
|
-
export interface ITekGridColumn extends IGridColumnEditable {
|
|
126
|
-
filterProps?: IFilterPropsComponent | IFilterPropsComponent[];
|
|
127
|
-
filterable?: boolean;
|
|
128
|
-
filterIndex?: number;
|
|
129
|
-
skipLookupSearch?: boolean;
|
|
130
|
-
grouped?: boolean;
|
|
131
|
-
aggregation?: ITekGridColumnAggregation;
|
|
132
|
-
groupOpened?: boolean;
|
|
133
|
-
groupLabelForEmptyValue?: string;
|
|
134
|
-
storeData?: boolean;
|
|
135
|
-
}
|
|
136
|
-
export interface ITekGridColumnsButton extends IIterableColumnsButton {
|
|
137
|
-
hideGroups?: boolean;
|
|
138
|
-
}
|
|
139
|
-
export interface ITekGridFilterButton extends IButton {
|
|
140
|
-
gridName?: string;
|
|
141
|
-
grid?: TekGrid | TekTreeGrid;
|
|
142
|
-
showCheckboxAll?: boolean;
|
|
143
|
-
}
|
|
144
|
-
export interface ITekGridGroup {
|
|
145
|
-
column: ITekGridColumn;
|
|
146
|
-
name: string;
|
|
147
|
-
label: string;
|
|
148
|
-
lastValue: any;
|
|
149
|
-
footer: ITekGridFooter;
|
|
150
|
-
initialized: boolean;
|
|
151
|
-
lastGroupHeaderRow?: ITekGridGroupHeader;
|
|
152
|
-
}
|
|
153
|
-
export interface ITekGridGroupHeader {
|
|
154
|
-
group: boolean;
|
|
155
|
-
groupRow: IDictionary;
|
|
156
|
-
groupColumnName: string;
|
|
157
|
-
groupHeader: boolean;
|
|
158
|
-
groupIndex: number;
|
|
159
|
-
groupLabel: string;
|
|
160
|
-
groupValue: any;
|
|
161
|
-
groupOpened: boolean;
|
|
162
|
-
groupHeaders: ITekGridGroupHeader[];
|
|
163
|
-
children: IDictionary<any>[];
|
|
164
|
-
}
|
|
165
|
-
export interface ITekGridFooter {
|
|
166
|
-
[key: string]: ITekGridSummary;
|
|
167
|
-
}
|
|
168
|
-
export interface ITekGridSummary {
|
|
169
|
-
sum: any;
|
|
170
|
-
avg: any;
|
|
171
|
-
count: number;
|
|
172
|
-
min: any;
|
|
173
|
-
max: any;
|
|
174
|
-
}
|
|
175
|
-
export interface ITekFilterHelperValue extends IDateHelperValue {
|
|
176
|
-
}
|
|
177
|
-
export interface ITekFilterHelperValues extends IDateHelperValues {
|
|
178
|
-
}
|
|
179
|
-
export interface IModalFilterProps extends IModal {
|
|
180
|
-
height?: string;
|
|
181
|
-
maxHeight?: string;
|
|
182
|
-
}
|
|
183
|
-
export interface ITekGridGroupFooter {
|
|
184
|
-
groupFooter: boolean;
|
|
185
|
-
groupIndex: number;
|
|
186
|
-
groupHeaders: ITekGridGroupHeader[];
|
|
187
|
-
groupLabel: string;
|
|
188
|
-
groupValue: any;
|
|
189
|
-
[key: string]: any;
|
|
190
|
-
}
|
|
191
|
-
export declare type ITekGridSummaryTotal = ITekGridGroupFooter & {
|
|
192
|
-
[key: string]: any;
|
|
193
|
-
};
|
|
194
|
-
export declare type IGroupedData = (ITekGridGroupHeader & {
|
|
195
|
-
[key: string]: any;
|
|
196
|
-
}) | {
|
|
197
|
-
[key: string]: any;
|
|
198
|
-
groupFooter: boolean;
|
|
199
|
-
groupSummary: boolean;
|
|
200
|
-
} | ITekGridSummaryTotal | {
|
|
201
|
-
[key: string]: any;
|
|
202
|
-
groupHeaders: ITekGridGroupHeader[];
|
|
203
|
-
};
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { ComponentRender } from '@zeedhi/common';
|
|
2
|
-
import { IImage } from './interfaces';
|
|
3
|
-
/**
|
|
4
|
-
* Teknisa component
|
|
5
|
-
*/
|
|
6
|
-
export declare class Image extends ComponentRender implements IImage {
|
|
7
|
-
/**
|
|
8
|
-
* Route path
|
|
9
|
-
*/
|
|
10
|
-
to: string;
|
|
11
|
-
/**
|
|
12
|
-
* Image source.
|
|
13
|
-
*/
|
|
14
|
-
src: string;
|
|
15
|
-
/**
|
|
16
|
-
* Defines the component height. Possible values for this property can be
|
|
17
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
18
|
-
*/
|
|
19
|
-
height: string | number;
|
|
20
|
-
/**
|
|
21
|
-
* Defines the component min height. Possible values for this property can be
|
|
22
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
23
|
-
*/
|
|
24
|
-
minHeight: string | number;
|
|
25
|
-
/**
|
|
26
|
-
* Defines the component max height. Possible values for this property can be
|
|
27
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
28
|
-
*/
|
|
29
|
-
maxHeight: string | number;
|
|
30
|
-
/**
|
|
31
|
-
* Set component height to fill all space available
|
|
32
|
-
*/
|
|
33
|
-
fillHeight: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* Defines the component width. Possible values for this property can be
|
|
36
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
37
|
-
*/
|
|
38
|
-
width: string | number;
|
|
39
|
-
/**
|
|
40
|
-
* Defines the component min width. Possible values for this property can be
|
|
41
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
42
|
-
*/
|
|
43
|
-
minWidth: string | number;
|
|
44
|
-
/**
|
|
45
|
-
* Defines the component max height. Possible values for this property can be
|
|
46
|
-
* <samp>'auto', '100%', '400px' or 400</samp>
|
|
47
|
-
*/
|
|
48
|
-
maxWidth: string | number;
|
|
49
|
-
/**
|
|
50
|
-
* Creates a new instance of ImgLink
|
|
51
|
-
* @param props Image Link props
|
|
52
|
-
*/
|
|
53
|
-
constructor(props: IImage);
|
|
54
|
-
load(event?: Event, element?: HTMLElement): void;
|
|
55
|
-
}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { IComponentRender } from '@zeedhi/common';
|
|
2
|
-
export interface IImage extends IComponentRender {
|
|
3
|
-
to?: string;
|
|
4
|
-
src?: string;
|
|
5
|
-
height?: number | string;
|
|
6
|
-
maxHeight?: number | string;
|
|
7
|
-
minHeight?: number | string;
|
|
8
|
-
fillHeight?: boolean;
|
|
9
|
-
width?: number | string;
|
|
10
|
-
maxWidth?: number | string;
|
|
11
|
-
minWidth?: number | string;
|
|
12
|
-
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { ICarousel, IIterableComponentRender } from '@zeedhi/common';
|
|
2
|
-
export declare type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
|
|
3
|
-
export interface IIterableCarousel extends ICarousel {
|
|
4
|
-
iterable?: Omit<IIterableComponentRender, 'name' | 'component'>;
|
|
5
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Carousel, IComponentRender, IterableComponentRender } from '@zeedhi/common';
|
|
2
|
-
import { IIterableCarousel } from './interfaces';
|
|
3
|
-
/**
|
|
4
|
-
* Base class for IterableCarousel component.
|
|
5
|
-
* This component uses every row returned by IterableComponentRender.datasource to render
|
|
6
|
-
* slides defined by componentMetadata property, inside a carousel component.
|
|
7
|
-
*/
|
|
8
|
-
export declare class IterableCarousel extends Carousel implements IIterableCarousel {
|
|
9
|
-
iterable: IterableComponentRender;
|
|
10
|
-
constructor(props: IIterableCarousel);
|
|
11
|
-
get children(): IComponentRender[];
|
|
12
|
-
set children(value: IComponentRender[]);
|
|
13
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { Iterable, IIterableComponentRender } from '@zeedhi/common';
|
|
2
|
-
/**
|
|
3
|
-
* Base class for IterableComponentRender component.
|
|
4
|
-
* This component uses every row returned by Iterable.datasource to render
|
|
5
|
-
* components defined by componentMetadata property.
|
|
6
|
-
* If the data inside the datasource is changed you should perform
|
|
7
|
-
* a datasource.get() to force updating the rendered components.
|
|
8
|
-
*/
|
|
9
|
-
export declare class IterableComponentRender extends Iterable implements IIterableComponentRender {
|
|
10
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Loading as ZdLoading } from '@zeedhi/common';
|
|
2
|
-
import { ILoading } from './interfaces';
|
|
3
|
-
/**
|
|
4
|
-
* Teknisa component
|
|
5
|
-
*/
|
|
6
|
-
export declare class Loading extends ZdLoading implements ILoading {
|
|
7
|
-
/**
|
|
8
|
-
* text to show in Loader Overlay
|
|
9
|
-
*/
|
|
10
|
-
text: string;
|
|
11
|
-
/**
|
|
12
|
-
* zIndex value.
|
|
13
|
-
*/
|
|
14
|
-
zIndex: number | string;
|
|
15
|
-
/**
|
|
16
|
-
* loading path.
|
|
17
|
-
*/
|
|
18
|
-
image: string;
|
|
19
|
-
/**
|
|
20
|
-
* Creates a new instance of TekLoading
|
|
21
|
-
* @param props Image Link props
|
|
22
|
-
*/
|
|
23
|
-
constructor(props: ILoading);
|
|
24
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { IIterable, IComponentEvents, EventDef } from '@zeedhi/common';
|
|
2
|
-
import { IEventParam } from '@zeedhi/core';
|
|
3
|
-
import { Notifications } from './notifications';
|
|
4
|
-
export interface INotification {
|
|
5
|
-
id: string;
|
|
6
|
-
date: string;
|
|
7
|
-
subject: string;
|
|
8
|
-
body: string;
|
|
9
|
-
read: boolean;
|
|
10
|
-
}
|
|
11
|
-
export interface INotificationsEvent extends IEventParam<Notifications> {
|
|
12
|
-
notification: INotification;
|
|
13
|
-
}
|
|
14
|
-
export interface INotificationsEvents<T = INotificationsEvent | IEventParam<any>> extends IComponentEvents<T> {
|
|
15
|
-
showAllClick?: EventDef<T>;
|
|
16
|
-
notificationClick?: EventDef<T>;
|
|
17
|
-
markAllAsReadClick?: EventDef<T>;
|
|
18
|
-
}
|
|
19
|
-
export interface INotifications extends IIterable {
|
|
20
|
-
allNotificationsPath?: string;
|
|
21
|
-
events?: INotificationsEvents;
|
|
22
|
-
}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { Iterable } from '@zeedhi/common';
|
|
2
|
-
import { INotifications, INotificationsEvents } from './interfaces';
|
|
3
|
-
/**
|
|
4
|
-
* Notifications component is used to show notifications
|
|
5
|
-
*/
|
|
6
|
-
export declare class Notifications extends Iterable implements INotifications {
|
|
7
|
-
allNotificationsPath: string;
|
|
8
|
-
/**
|
|
9
|
-
* Defines grid events.
|
|
10
|
-
*/
|
|
11
|
-
events: INotificationsEvents;
|
|
12
|
-
cardTitle: {
|
|
13
|
-
name: string;
|
|
14
|
-
component: string;
|
|
15
|
-
title: string;
|
|
16
|
-
rightSlot: {
|
|
17
|
-
name: string;
|
|
18
|
-
component: string;
|
|
19
|
-
tag: string;
|
|
20
|
-
events: {
|
|
21
|
-
click: ({ event, element }: any) => void;
|
|
22
|
-
};
|
|
23
|
-
children: {
|
|
24
|
-
name: string;
|
|
25
|
-
cssClass: string;
|
|
26
|
-
component: string;
|
|
27
|
-
text: string;
|
|
28
|
-
}[];
|
|
29
|
-
}[];
|
|
30
|
-
};
|
|
31
|
-
constructor(props: INotifications);
|
|
32
|
-
markAsRead({ event, element }: any): void;
|
|
33
|
-
showAll(event: Event, element: HTMLElement): void;
|
|
34
|
-
notificationClick(event: Event, notification: any, element: HTMLElement): void;
|
|
35
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { IComponentRender } from '@zeedhi/common';
|
|
2
|
-
import { IEventParam } from '@zeedhi/core';
|
|
3
|
-
import { ProductCard } from './product-card';
|
|
4
|
-
export declare type IProductCardEvent = IEventParam<ProductCard>;
|
|
5
|
-
export interface IProductCard extends IComponentRender {
|
|
6
|
-
id?: string;
|
|
7
|
-
to?: string;
|
|
8
|
-
src?: string;
|
|
9
|
-
errorImagePath?: string;
|
|
10
|
-
errorImageText?: string;
|
|
11
|
-
productPrice?: number | string;
|
|
12
|
-
productName?: string;
|
|
13
|
-
productSupplier?: string;
|
|
14
|
-
productBrand?: string;
|
|
15
|
-
width?: string;
|
|
16
|
-
height?: number | string;
|
|
17
|
-
maxHeight?: number | string;
|
|
18
|
-
minHeight?: number | string;
|
|
19
|
-
}
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
import { ComponentRender } from '@zeedhi/common';
|
|
2
|
-
import { IProductCard } from './interfaces';
|
|
3
|
-
/**
|
|
4
|
-
* Teknisa product card component
|
|
5
|
-
*/
|
|
6
|
-
export declare class ProductCard extends ComponentRender implements IProductCard {
|
|
7
|
-
/**
|
|
8
|
-
* Route path.
|
|
9
|
-
*/
|
|
10
|
-
to: string;
|
|
11
|
-
/**
|
|
12
|
-
* Product Id.
|
|
13
|
-
*/
|
|
14
|
-
id: string;
|
|
15
|
-
/**
|
|
16
|
-
* Image source Product.
|
|
17
|
-
*/
|
|
18
|
-
src: string;
|
|
19
|
-
/**
|
|
20
|
-
* Product name.
|
|
21
|
-
*/
|
|
22
|
-
productName: string;
|
|
23
|
-
/**
|
|
24
|
-
* Product supplier
|
|
25
|
-
*/
|
|
26
|
-
productSupplier?: string;
|
|
27
|
-
/**
|
|
28
|
-
* Product brand
|
|
29
|
-
*/
|
|
30
|
-
productBrand?: string;
|
|
31
|
-
/**
|
|
32
|
-
* Product price
|
|
33
|
-
*/
|
|
34
|
-
productPrice?: number | string;
|
|
35
|
-
/**
|
|
36
|
-
* Path to image to be shown when error
|
|
37
|
-
*/
|
|
38
|
-
errorImagePath: string;
|
|
39
|
-
/**
|
|
40
|
-
* Text to be shown when error
|
|
41
|
-
*/
|
|
42
|
-
errorImageText: string;
|
|
43
|
-
/**
|
|
44
|
-
* Card width
|
|
45
|
-
*/
|
|
46
|
-
width: string;
|
|
47
|
-
/**
|
|
48
|
-
* Sets the height for the component.
|
|
49
|
-
*/
|
|
50
|
-
height: number | string;
|
|
51
|
-
/**
|
|
52
|
-
* Sets the maximum height for the component.
|
|
53
|
-
*/
|
|
54
|
-
maxHeight: number | string;
|
|
55
|
-
/**
|
|
56
|
-
* Sets the minimum height for the component.
|
|
57
|
-
*/
|
|
58
|
-
minHeight: number | string;
|
|
59
|
-
protected currencyFormatterFn: Function;
|
|
60
|
-
/**
|
|
61
|
-
* Creates a new instance of ProductCard
|
|
62
|
-
* @param props Product Card props
|
|
63
|
-
*/
|
|
64
|
-
constructor(props: IProductCard);
|
|
65
|
-
get productPriceFormat(): any;
|
|
66
|
-
}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { IComponentRender, ITreeGridEditable } from '@zeedhi/common';
|
|
2
|
-
import { IDictionary } from '@zeedhi/core';
|
|
3
|
-
import { ITekGridColumn, ITekGridEvents, ITekGridExportConfig, TekGridLayoutOptions, IModalFilterProps } from '..';
|
|
4
|
-
export interface ITekTreeGrid extends ITreeGridEditable {
|
|
5
|
-
actions?: IComponentRender[];
|
|
6
|
-
addButton?: boolean;
|
|
7
|
-
columnFilterButton?: boolean;
|
|
8
|
-
columns?: ITekGridColumn[];
|
|
9
|
-
columnsButton?: boolean;
|
|
10
|
-
columnsButtonIgnore?: string[];
|
|
11
|
-
deleteButton?: 'none' | 'currentRow' | 'selection';
|
|
12
|
-
events?: ITekGridEvents;
|
|
13
|
-
filterButton?: boolean;
|
|
14
|
-
mainGrid?: boolean;
|
|
15
|
-
modalFilterProps?: IModalFilterProps;
|
|
16
|
-
showSearch?: boolean;
|
|
17
|
-
showHideButton?: boolean;
|
|
18
|
-
showLayoutOptions?: boolean;
|
|
19
|
-
title?: string;
|
|
20
|
-
showExport?: boolean;
|
|
21
|
-
showEditButtons?: boolean;
|
|
22
|
-
showReload?: boolean;
|
|
23
|
-
exportConfig?: ITekGridExportConfig[];
|
|
24
|
-
exportActions?: IComponentRender[];
|
|
25
|
-
layoutOptions?: TekGridLayoutOptions;
|
|
26
|
-
showCheckboxAllFilter?: boolean;
|
|
27
|
-
defaultFilter?: IDictionary;
|
|
28
|
-
toolbarOpened?: boolean;
|
|
29
|
-
reportTitle?: string;
|
|
30
|
-
}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import { IComponentRender, TreeGridEditable } from '@zeedhi/common';
|
|
2
|
-
import { Datasource, IDictionary } from '@zeedhi/core';
|
|
3
|
-
import { ITekGridAtoms } from '../../utils';
|
|
4
|
-
import { TekGridColumn } from '../tek-grid/grid-column';
|
|
5
|
-
import { IModalFilterProps, ITekGridColumn, ITekGridEvents, ITekGridExportConfig } from '../tek-grid/interfaces';
|
|
6
|
-
import { ITekTreeGrid } from './interfaces';
|
|
7
|
-
import { TekGridLayoutOptions } from '..';
|
|
8
|
-
export declare class TekTreeGrid extends TreeGridEditable implements ITekTreeGrid {
|
|
9
|
-
title: string;
|
|
10
|
-
addButton: boolean;
|
|
11
|
-
/**
|
|
12
|
-
* Components that will be rendered on toolbar slot
|
|
13
|
-
*/
|
|
14
|
-
toolbarConfig: (IComponentRender | string)[];
|
|
15
|
-
showEditButtons: boolean;
|
|
16
|
-
deleteButton: 'none' | 'currentRow' | 'selection';
|
|
17
|
-
actions: IComponentRender[];
|
|
18
|
-
filterButton: boolean;
|
|
19
|
-
modalFilterProps: IModalFilterProps;
|
|
20
|
-
showSearch?: boolean;
|
|
21
|
-
showHideButton: boolean;
|
|
22
|
-
columnFilterButton: boolean;
|
|
23
|
-
columnsButton: boolean;
|
|
24
|
-
columnsButtonIgnore: string[];
|
|
25
|
-
events: ITekGridEvents;
|
|
26
|
-
/**
|
|
27
|
-
* Enables column dragging
|
|
28
|
-
* @public
|
|
29
|
-
*/
|
|
30
|
-
dragColumns: boolean;
|
|
31
|
-
/**
|
|
32
|
-
* Defines if the grid is the unique grid on screen
|
|
33
|
-
*/
|
|
34
|
-
mainGrid: boolean;
|
|
35
|
-
/**
|
|
36
|
-
* Enables column resizing
|
|
37
|
-
* @public
|
|
38
|
-
*/
|
|
39
|
-
resizeColumns: boolean;
|
|
40
|
-
/**
|
|
41
|
-
* Enables layout saving
|
|
42
|
-
* @public
|
|
43
|
-
*/
|
|
44
|
-
showLayoutOptions: boolean;
|
|
45
|
-
/**
|
|
46
|
-
* Editable columns
|
|
47
|
-
*/
|
|
48
|
-
columns: TekGridColumn[];
|
|
49
|
-
/**
|
|
50
|
-
* Show export button
|
|
51
|
-
*/
|
|
52
|
-
showExport: boolean;
|
|
53
|
-
/**
|
|
54
|
-
* Show refresh button
|
|
55
|
-
*/
|
|
56
|
-
showReload: boolean;
|
|
57
|
-
toolbarOpened: boolean;
|
|
58
|
-
protected keyShortcutKeyMapping: any;
|
|
59
|
-
/**
|
|
60
|
-
* Export config
|
|
61
|
-
*/
|
|
62
|
-
exportConfig: ITekGridExportConfig[];
|
|
63
|
-
private toolbarSlotProps;
|
|
64
|
-
/**
|
|
65
|
-
* Actions to overwrite the default export config
|
|
66
|
-
*/
|
|
67
|
-
exportActions?: IComponentRender[];
|
|
68
|
-
private gridBase;
|
|
69
|
-
filterRelationsDatasource: Datasource;
|
|
70
|
-
filterOperationsDatasource: Datasource;
|
|
71
|
-
showCheckboxAllFilter: boolean;
|
|
72
|
-
defaultFilter: IDictionary;
|
|
73
|
-
reportTitle: string;
|
|
74
|
-
/**
|
|
75
|
-
* TekTreeGrid class constructor
|
|
76
|
-
* @param props TekTreeGrid properties
|
|
77
|
-
*/
|
|
78
|
-
constructor(props: ITekTreeGrid);
|
|
79
|
-
onMounted(element: HTMLElement): void;
|
|
80
|
-
onBeforeDestroy(): void;
|
|
81
|
-
onCreated(): void;
|
|
82
|
-
protected focusSearchInput(): void;
|
|
83
|
-
get layoutOptions(): TekGridLayoutOptions | undefined;
|
|
84
|
-
/**
|
|
85
|
-
* Get Grid columns objects
|
|
86
|
-
* @param columns Grid columns parameter
|
|
87
|
-
*/
|
|
88
|
-
protected getColumns(columns: ITekGridColumn[]): TekGridColumn[];
|
|
89
|
-
columnHasFilterData(column: TekGridColumn): any;
|
|
90
|
-
getReport(type: string, portrait?: boolean, rowObj?: any): Promise<Window | null>;
|
|
91
|
-
setSearch(search: string): Promise<any>;
|
|
92
|
-
/**
|
|
93
|
-
* Dispatches row click event
|
|
94
|
-
* @param row Grid row
|
|
95
|
-
* @param event DOM event
|
|
96
|
-
* @param element DOM Element
|
|
97
|
-
*/
|
|
98
|
-
rowClick(row: IDictionary<any>, event: Event, element: HTMLElement): void;
|
|
99
|
-
getAtomInstance<T>(key: keyof ITekGridAtoms): T;
|
|
100
|
-
getFilterInputs(columnName?: string): import("@zeedhi/common").Input[];
|
|
101
|
-
getColumn(name: string): TekGridColumn;
|
|
102
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { IDictionary } from '@zeedhi/core';
|
|
2
|
-
/**
|
|
3
|
-
* Thrown when a row has incomplete group information.
|
|
4
|
-
* Provides details about the missing groups and the problematic row.
|
|
5
|
-
*/
|
|
6
|
-
export declare class IncompleteGroupsError extends Error {
|
|
7
|
-
constructor(row: IDictionary, missingGroups: string[]);
|
|
8
|
-
}
|
package/types/index.d.ts
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Extracts properties from an object based on a list of properties
|
|
3
|
-
* @param obj object whose properties will be extracted
|
|
4
|
-
* @param props array of strings with the properties to be extracted
|
|
5
|
-
* @returns object containing the extracted properties
|
|
6
|
-
*/
|
|
7
|
-
export declare const extractProperties: (obj: any, props: string[]) => any;
|