@progress/kendo-react-data-tools 7.2.4-develop.2 → 7.2.4-develop.4
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/clipboard/clipboard.service.js +8 -0
- package/clipboard/clipboard.service.mjs +27 -0
- package/clipboard/common.js +13 -0
- package/clipboard/common.mjs +64 -0
- package/columnmenu/ColumnMenu.js +8 -0
- package/columnmenu/ColumnMenu.mjs +256 -0
- package/columnmenu/ColumnMenuFilterForm.js +8 -0
- package/columnmenu/ColumnMenuFilterForm.mjs +47 -0
- package/columnmenu/ColumnMenuFilterLogic.js +8 -0
- package/columnmenu/ColumnMenuFilterLogic.mjs +29 -0
- package/columnmenu/ColumnMenuFilters.js +8 -0
- package/columnmenu/ColumnMenuFilters.mjs +98 -0
- package/columnmenu/ColumnMenuItem.js +8 -0
- package/columnmenu/ColumnMenuItem.mjs +26 -0
- package/columnmenu/ColumnMenuOperators.js +8 -0
- package/columnmenu/ColumnMenuOperators.mjs +109 -0
- package/dist/cdn/js/kendo-react-datatools.js +8 -10
- package/drag/ColumnDraggable.js +8 -0
- package/drag/ColumnDraggable.mjs +40 -0
- package/drag/ColumnResize.js +8 -0
- package/drag/ColumnResize.mjs +58 -0
- package/drag/ColumnResizer.js +8 -0
- package/drag/ColumnResizer.mjs +56 -0
- package/drag/CommonDragLogic.js +8 -0
- package/drag/CommonDragLogic.mjs +89 -0
- package/drag/DragClue.js +8 -0
- package/drag/DragClue.mjs +52 -0
- package/drag/DropClue.js +8 -0
- package/drag/DropClue.mjs +43 -0
- package/filter/Expression.js +8 -0
- package/filter/Expression.mjs +113 -0
- package/filter/Filter.js +8 -0
- package/filter/Filter.mjs +84 -0
- package/filter/Group.js +8 -0
- package/filter/Group.mjs +163 -0
- package/filter/filters/BooleanFilter.js +8 -0
- package/filter/filters/BooleanFilter.mjs +43 -0
- package/filter/filters/DateFilter.js +8 -0
- package/filter/filters/DateFilter.mjs +43 -0
- package/filter/filters/EnumFilter.js +8 -0
- package/filter/filters/EnumFilter.mjs +59 -0
- package/filter/filters/NumericFilter.js +8 -0
- package/filter/filters/NumericFilter.mjs +54 -0
- package/filter/filters/TextFilter.js +8 -0
- package/filter/filters/TextFilter.mjs +46 -0
- package/filter/operators.js +8 -0
- package/filter/operators.mjs +114 -0
- package/filteringCells/BooleanFilter.js +8 -0
- package/filteringCells/BooleanFilter.mjs +49 -0
- package/filteringCells/DateFilter.js +8 -0
- package/filteringCells/DateFilter.mjs +22 -0
- package/filteringCells/FilterComponent.js +8 -0
- package/filteringCells/FilterComponent.mjs +81 -0
- package/filteringCells/NumericFilter.js +8 -0
- package/filteringCells/NumericFilter.mjs +22 -0
- package/filteringCells/TextFilter.js +8 -0
- package/filteringCells/TextFilter.mjs +22 -0
- package/header/ColumnProps.js +8 -0
- package/header/ColumnProps.mjs +19 -0
- package/header/FilterRow.js +8 -0
- package/header/FilterRow.mjs +54 -0
- package/header/Header.js +8 -0
- package/header/Header.mjs +36 -0
- package/header/HeaderCell.js +8 -0
- package/header/HeaderCell.mjs +18 -0
- package/header/HeaderRow.js +8 -0
- package/header/HeaderRow.mjs +132 -0
- package/header/HeaderSelectionCell.js +8 -0
- package/header/HeaderSelectionCell.mjs +32 -0
- package/header/HeaderThElement.js +8 -0
- package/header/HeaderThElement.mjs +47 -0
- package/header/SortSettings.js +8 -0
- package/header/SortSettings.mjs +12 -0
- package/header/utils/index.js +8 -0
- package/header/utils/index.mjs +130 -0
- package/index.d.mts +2398 -5
- package/index.d.ts +2398 -32
- package/index.js +8 -10
- package/index.mjs +152 -2987
- package/messages/index.js +8 -0
- package/messages/index.mjs +167 -0
- package/navigation/TableKeyboardNavigation.js +8 -0
- package/navigation/TableKeyboardNavigation.mjs +142 -0
- package/navigation/TableKeyboardNavigationContext.js +8 -0
- package/navigation/TableKeyboardNavigationContext.mjs +14 -0
- package/navigation/constants.js +8 -0
- package/navigation/constants.mjs +43 -0
- package/navigation/hooks.js +8 -0
- package/navigation/hooks.mjs +22 -0
- package/navigation/utils.js +8 -0
- package/navigation/utils.mjs +107 -0
- package/package-metadata.js +8 -0
- package/package-metadata.mjs +19 -0
- package/package.json +9 -9
- package/pager/Pager.js +8 -0
- package/pager/Pager.mjs +234 -0
- package/pager/PagerInput.js +8 -0
- package/pager/PagerInput.mjs +38 -0
- package/pager/PagerNumericButtons.js +8 -0
- package/pager/PagerNumericButtons.mjs +103 -0
- package/pager/PagerPageSizes.js +8 -0
- package/pager/PagerPageSizes.mjs +38 -0
- package/selection/TableSelection.js +8 -0
- package/selection/TableSelection.mjs +123 -0
- package/selection/constants.js +8 -0
- package/selection/constants.mjs +14 -0
- package/selection/utils.js +8 -0
- package/selection/utils.mjs +155 -0
- package/utils/data-operations.js +8 -0
- package/utils/data-operations.mjs +127 -0
- package/utils/group-operations.js +8 -0
- package/utils/group-operations.mjs +32 -0
- package/virtualization/columns.js +8 -0
- package/virtualization/columns.mjs +43 -0
- package/clipboard/clipboard.service.d.ts +0 -17
- package/clipboard/common.d.ts +0 -129
- package/columnmenu/ColumnMenu.d.ts +0 -83
- package/columnmenu/ColumnMenuFilterForm.d.ts +0 -17
- package/columnmenu/ColumnMenuFilterLogic.d.ts +0 -7
- package/columnmenu/ColumnMenuFilters.d.ts +0 -23
- package/columnmenu/ColumnMenuItem.d.ts +0 -15
- package/columnmenu/ColumnMenuOperators.d.ts +0 -69
- package/columnmenu/index.d.ts +0 -10
- package/drag/ColumnDraggable.d.ts +0 -34
- package/drag/ColumnResize.d.ts +0 -36
- package/drag/ColumnResizer.d.ts +0 -32
- package/drag/CommonDragLogic.d.ts +0 -42
- package/drag/DragClue.d.ts +0 -26
- package/drag/DropClue.d.ts +0 -23
- package/filter/Expression.d.ts +0 -50
- package/filter/FieldSettings.d.ts +0 -34
- package/filter/Filter.d.ts +0 -83
- package/filter/Group.d.ts +0 -58
- package/filter/filters/BooleanFilter.d.ts +0 -47
- package/filter/filters/DateFilter.d.ts +0 -30
- package/filter/filters/EnumFilter.d.ts +0 -47
- package/filter/filters/NumericFilter.d.ts +0 -37
- package/filter/filters/TextFilter.d.ts +0 -44
- package/filter/filters/index.d.ts +0 -9
- package/filter/index.d.ts +0 -10
- package/filter/operators.d.ts +0 -77
- package/filteringCells/BooleanFilter.d.ts +0 -12
- package/filteringCells/DateFilter.d.ts +0 -12
- package/filteringCells/FilterCellProps.d.ts +0 -39
- package/filteringCells/FilterComponent.d.ts +0 -21
- package/filteringCells/FilterComponentProps.d.ts +0 -27
- package/filteringCells/FilterOperator.d.ts +0 -17
- package/filteringCells/NumericFilter.d.ts +0 -12
- package/filteringCells/TextFilter.d.ts +0 -12
- package/filteringCells/index.d.ts +0 -12
- package/header/CellProps.d.ts +0 -72
- package/header/ColumnProps.d.ts +0 -157
- package/header/FilterRow.d.ts +0 -29
- package/header/Header.d.ts +0 -22
- package/header/HeaderCell.d.ts +0 -51
- package/header/HeaderRow.d.ts +0 -41
- package/header/HeaderSelectionCell.d.ts +0 -15
- package/header/HeaderThElement.d.ts +0 -26
- package/header/SortSettings.d.ts +0 -30
- package/header/index.d.ts +0 -14
- package/header/utils/index.d.ts +0 -87
- package/messages/index.d.ts +0 -394
- package/navigation/TableKeyboardNavigation.d.ts +0 -72
- package/navigation/TableKeyboardNavigationContext.d.ts +0 -10
- package/navigation/TableKeyboardNavigationContextType.d.ts +0 -11
- package/navigation/TableKeyboardNavigationStateType.d.ts +0 -14
- package/navigation/constants.d.ts +0 -58
- package/navigation/hooks.d.ts +0 -16
- package/navigation/utils.d.ts +0 -149
- package/package-metadata.d.ts +0 -9
- package/pager/Pager.d.ts +0 -208
- package/pager/PagerInput.d.ts +0 -29
- package/pager/PagerNumericButtons.d.ts +0 -32
- package/pager/PagerPageSizes.d.ts +0 -30
- package/selection/TableSelectableSettings.d.ts +0 -35
- package/selection/TableSelection.d.ts +0 -15
- package/selection/constants.d.ts +0 -10
- package/selection/events.d.ts +0 -98
- package/selection/utils.d.ts +0 -70
- package/utils/DataItemWrapper.d.ts +0 -14
- package/utils/data-operations.d.ts +0 -98
- package/utils/group-operations.d.ts +0 -33
- package/virtualization/columns.d.ts +0 -19
- package/virtualization/index.d.ts +0 -5
package/index.d.ts
CHANGED
|
@@ -1,32 +1,2398 @@
|
|
|
1
|
-
|
|
2
|
-
*
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
export
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
import { BaseEvent } from '@progress/kendo-react-common';
|
|
9
|
+
import { ComponentType } from 'react';
|
|
10
|
+
import { CompositeFilterDescriptor } from '@progress/kendo-data-query';
|
|
11
|
+
import { DropDownListProps } from '@progress/kendo-react-dropdowns';
|
|
12
|
+
import { FilterDescriptor } from '@progress/kendo-data-query';
|
|
13
|
+
import { GroupDescriptor } from '@progress/kendo-data-query';
|
|
14
|
+
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
|
15
|
+
import PropTypes from 'prop-types';
|
|
16
|
+
import * as React_2 from 'react';
|
|
17
|
+
import { SortDescriptor } from '@progress/kendo-data-query';
|
|
18
|
+
import { SVGIcon } from '@progress/kendo-react-common';
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Represents the base object of the `onPageChange` event. It is usually used
|
|
22
|
+
* in custom pager scenarios in cases when we don't need any of the events or the target.
|
|
23
|
+
*/
|
|
24
|
+
export declare interface BasePageChangeEvent {
|
|
25
|
+
/**
|
|
26
|
+
* The number of records that will be skipped.
|
|
27
|
+
*/
|
|
28
|
+
skip: number;
|
|
29
|
+
/**
|
|
30
|
+
* The number of records that will be taken.
|
|
31
|
+
*/
|
|
32
|
+
take: number;
|
|
33
|
+
/**
|
|
34
|
+
* A React Synthetic Event.
|
|
35
|
+
*/
|
|
36
|
+
syntheticEvent?: React_2.SyntheticEvent<any>;
|
|
37
|
+
/**
|
|
38
|
+
* A native DOM event.
|
|
39
|
+
*/
|
|
40
|
+
nativeEvent?: any;
|
|
41
|
+
/**
|
|
42
|
+
* A target change event.
|
|
43
|
+
*/
|
|
44
|
+
targetEvent?: PagerTargetEvent;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* The BooleanFilter component used for editing boolean value of FilterDescriptor object.
|
|
49
|
+
*/
|
|
50
|
+
export declare class BooleanFilter extends React_2.Component<BooleanFilterProps> {
|
|
51
|
+
/**
|
|
52
|
+
* @hidden
|
|
53
|
+
*/
|
|
54
|
+
static propTypes: {
|
|
55
|
+
filter: PropTypes.Validator<object>;
|
|
56
|
+
onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
57
|
+
data: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
58
|
+
text: PropTypes.Requireable<string>;
|
|
59
|
+
value: PropTypes.Requireable<any>;
|
|
60
|
+
}> | null | undefined)[]>;
|
|
61
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
62
|
+
defaultItem: PropTypes.Requireable<any>;
|
|
63
|
+
};
|
|
64
|
+
private data;
|
|
65
|
+
/**
|
|
66
|
+
* @hidden
|
|
67
|
+
*/
|
|
68
|
+
render(): JSX_2.Element;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* @hidden
|
|
73
|
+
*/
|
|
74
|
+
export declare class BooleanFilterCell extends BooleanFilterCell_base {
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
declare const BooleanFilterCell_base: React_2.ComponentClass<FilterComponentProps, any>;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* The props of the BooleanFilter component.
|
|
81
|
+
*/
|
|
82
|
+
export declare interface BooleanFilterProps extends TextFilterProps {
|
|
83
|
+
/**
|
|
84
|
+
* A collection of text-value pairs passed to the BooleanFilter DropDownList.
|
|
85
|
+
* Defaults to [ { text: 'True', value: true }, { text: 'False', value: false } ]
|
|
86
|
+
*/
|
|
87
|
+
data?: Array<{
|
|
88
|
+
text: string;
|
|
89
|
+
value: any;
|
|
90
|
+
}>;
|
|
91
|
+
/**
|
|
92
|
+
* The defaultItem passed to the BooleanFilter DropDownList.
|
|
93
|
+
*/
|
|
94
|
+
defaultItem?: any;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* @hidden
|
|
99
|
+
*/
|
|
100
|
+
export declare interface CellProps {
|
|
101
|
+
/**
|
|
102
|
+
* @hidden
|
|
103
|
+
*/
|
|
104
|
+
id: string;
|
|
105
|
+
/**
|
|
106
|
+
* The index to be applied to the `aria-colindex` attribute.
|
|
107
|
+
*/
|
|
108
|
+
ariaColumnIndex: number;
|
|
109
|
+
/**
|
|
110
|
+
* Indicates if the cell is selected.
|
|
111
|
+
*/
|
|
112
|
+
isSelected: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* The expanded value of the cell.
|
|
115
|
+
*/
|
|
116
|
+
expanded?: boolean;
|
|
117
|
+
/**
|
|
118
|
+
* The custom CSS classes of the cells.
|
|
119
|
+
*/
|
|
120
|
+
className?: string;
|
|
121
|
+
/**
|
|
122
|
+
* The styles for the cell.
|
|
123
|
+
*/
|
|
124
|
+
style?: React_2.CSSProperties;
|
|
125
|
+
/**
|
|
126
|
+
* The field to which the cell is bound.
|
|
127
|
+
*/
|
|
128
|
+
field?: string;
|
|
129
|
+
/**
|
|
130
|
+
* The data item which corresponds to the current row.
|
|
131
|
+
*/
|
|
132
|
+
dataItem: any;
|
|
133
|
+
/**
|
|
134
|
+
* The format that is applied to the value before the value is displayed.
|
|
135
|
+
* Takes the `{0:format}` form where `format` is a standard number format, a custom number format,
|
|
136
|
+
* a standard date format, or a custom date format. For more information on the supported date and number formats,
|
|
137
|
+
* refer to the [kendo-intl](https://github.com/telerik/kendo-intl/blob/develop/docs/index.md) documentation.
|
|
138
|
+
*/
|
|
139
|
+
format?: string;
|
|
140
|
+
/**
|
|
141
|
+
* The column span of the cell.
|
|
142
|
+
*/
|
|
143
|
+
colSpan?: number;
|
|
144
|
+
/**
|
|
145
|
+
* The event that is fired when the cell is selected.
|
|
146
|
+
*/
|
|
147
|
+
selectionChange?: (event: {
|
|
148
|
+
syntheticEvent: React_2.SyntheticEvent<any>;
|
|
149
|
+
}) => void;
|
|
150
|
+
/**
|
|
151
|
+
* The event that is fired when the cell value is changed.
|
|
152
|
+
*/
|
|
153
|
+
onChange?: (event: {
|
|
154
|
+
dataItem: any;
|
|
155
|
+
syntheticEvent: React_2.SyntheticEvent<any>;
|
|
156
|
+
field?: string;
|
|
157
|
+
value?: any;
|
|
158
|
+
}) => void;
|
|
159
|
+
/**
|
|
160
|
+
* A function for overriding the default rendering of the cell.
|
|
161
|
+
*/
|
|
162
|
+
render?: (defaultRendering: React_2.ReactElement<HTMLTableCellElement> | null, props: CellProps) => React_2.ReactElement<HTMLTableCellElement> | null;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* The possible values of the `type` property.
|
|
167
|
+
*/
|
|
168
|
+
export declare enum ClipboardActionType {
|
|
169
|
+
copy = "copy",
|
|
170
|
+
cut = "cut",
|
|
171
|
+
paste = "paste"
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* Represents the object that is returned form the `populateClipboardData` function.
|
|
176
|
+
*/
|
|
177
|
+
export declare interface ClipboardData {
|
|
178
|
+
/**
|
|
179
|
+
* A collection of the ClipboardItem that are selected.
|
|
180
|
+
*/
|
|
181
|
+
copiedItems: ClipboardItem_2[];
|
|
182
|
+
/**
|
|
183
|
+
* A collection of the ClipboardItem that are pasted.
|
|
184
|
+
*/
|
|
185
|
+
pastedItems: ClipboardItem_2[];
|
|
186
|
+
/**
|
|
187
|
+
* When the action is `copy` or `cut` - the Grid data, copied to the clipboard, in Excel-compatible format.
|
|
188
|
+
* When the action is `paste` - the current clipboard data, available in the original DOM event.
|
|
189
|
+
*/
|
|
190
|
+
clipboardData: string;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/**
|
|
194
|
+
* Represents the object of the `onClipboardData` event.
|
|
195
|
+
*/
|
|
196
|
+
export declare interface ClipboardDataEvent {
|
|
197
|
+
/**
|
|
198
|
+
* Represents the type of the clipboard action.
|
|
199
|
+
*/
|
|
200
|
+
type: ClipboardActionType;
|
|
201
|
+
/**
|
|
202
|
+
* Represents the native clipboard event.
|
|
203
|
+
*/
|
|
204
|
+
nativeEvent?: ClipboardEvent;
|
|
205
|
+
/**
|
|
206
|
+
* All the Grid columns.
|
|
207
|
+
*/
|
|
208
|
+
columns: ColumnBaseProps[];
|
|
209
|
+
/**
|
|
210
|
+
* Passes the clipboard prop copyHeaders value in the clipboard action.
|
|
211
|
+
*/
|
|
212
|
+
copyHeaders?: boolean;
|
|
213
|
+
/**
|
|
214
|
+
* Sets the cell delimiter used when manipulating the clipboard data Defaults to `\t`.
|
|
215
|
+
*/
|
|
216
|
+
cellDelimiter?: string;
|
|
217
|
+
/**
|
|
218
|
+
* Sets the row delimiter used when manipulating the clipboard data Defaults to `\r\n`.
|
|
219
|
+
*/
|
|
220
|
+
newLineDelimiter?: string;
|
|
221
|
+
/**
|
|
222
|
+
* Passes the dataItemKey prop in the clipboard action.
|
|
223
|
+
*/
|
|
224
|
+
dataItemKey: string;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
/**
|
|
228
|
+
* Represents the aria that is copied - the dataItem and the fields.
|
|
229
|
+
*/
|
|
230
|
+
declare interface ClipboardItem_2 {
|
|
231
|
+
/**
|
|
232
|
+
* Represents the dataItem used in the clipboard action.
|
|
233
|
+
*/
|
|
234
|
+
dataItem: any;
|
|
235
|
+
/**
|
|
236
|
+
* Represents the fields used in the clipboard action.
|
|
237
|
+
*/
|
|
238
|
+
fields: string[];
|
|
239
|
+
}
|
|
240
|
+
export { ClipboardItem_2 as ClipboardItem }
|
|
241
|
+
|
|
242
|
+
/**
|
|
243
|
+
* @hidden
|
|
244
|
+
*/
|
|
245
|
+
export declare class ClipboardService {
|
|
246
|
+
private clipboardEvent;
|
|
247
|
+
constructor(ClipboardEventHandler: (clipboardType: ClipboardActionType, event: ClipboardEvent) => void);
|
|
248
|
+
private copyHandler;
|
|
249
|
+
private cutHandler;
|
|
250
|
+
private pasteHandler;
|
|
251
|
+
addEventListeners: (document: Document | undefined) => void;
|
|
252
|
+
removeEventListeners: (document: Document | undefined) => void;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
/**
|
|
256
|
+
* Represents settings that can be added to the clipboard behavior.
|
|
257
|
+
*/
|
|
258
|
+
export declare interface ClipboardSettings {
|
|
259
|
+
/**
|
|
260
|
+
* Determines whether column titles or field names will be included in the generated data
|
|
261
|
+
* during the `copy` and `cut` actions.
|
|
262
|
+
* Defaults to `false`.
|
|
263
|
+
*/
|
|
264
|
+
copyHeaders: boolean;
|
|
265
|
+
/**
|
|
266
|
+
* Determines what is the delimiter used to separate the cells.
|
|
267
|
+
* Defaults to `\t`.
|
|
268
|
+
*/
|
|
269
|
+
cellDelimiter?: string;
|
|
270
|
+
/**
|
|
271
|
+
* Determines what is the delimiter used to separate the rows.
|
|
272
|
+
* Defaults to `'\r\n'`.
|
|
273
|
+
*/
|
|
274
|
+
newLineDelimiter?: string;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
/** @hidden */
|
|
278
|
+
export declare const closestTagName: (target: HTMLElement | null, tagName: 'TD' | 'TR' | 'TABLE') => HTMLElement | null;
|
|
279
|
+
|
|
280
|
+
/**
|
|
281
|
+
* @hidden
|
|
282
|
+
*/
|
|
283
|
+
export declare interface ColumnBaseProps<CellProps = CellProps> {
|
|
284
|
+
/**
|
|
285
|
+
* The field to which the column is bound.
|
|
286
|
+
*/
|
|
287
|
+
field?: string;
|
|
288
|
+
/**
|
|
289
|
+
* The title of the column.
|
|
290
|
+
*/
|
|
291
|
+
title?: string;
|
|
292
|
+
/**
|
|
293
|
+
* Allows the column headers to be clicked and the `sortChange` event emitted.
|
|
294
|
+
* You have to handle the `sortChange` event yourself and sort the data.
|
|
295
|
+
* Defaults to `true`.
|
|
296
|
+
*/
|
|
297
|
+
sortable?: boolean | ColumnSortSettings;
|
|
298
|
+
/**
|
|
299
|
+
* The width of the column (in pixels).
|
|
300
|
+
*/
|
|
301
|
+
width?: string | number;
|
|
302
|
+
/**
|
|
303
|
+
* Defines if the header selection checkbox is checked.
|
|
304
|
+
*/
|
|
305
|
+
headerSelectionValue?: boolean;
|
|
306
|
+
/**
|
|
307
|
+
* The format that is applied to the value before it is displayed.
|
|
308
|
+
* Takes the `{0:format}` form where `format` is a standard number format, a custom number format,
|
|
309
|
+
* a standard date format, or a custom date format. For more information on the supported date and number formats,
|
|
310
|
+
* refer to the [kendo-intl](https://github.com/telerik/kendo-intl/blob/develop/docs/index.md) documentation.
|
|
311
|
+
*/
|
|
312
|
+
format?: string;
|
|
313
|
+
/**
|
|
314
|
+
* Sets the custom CSS classes to the column header cell.
|
|
315
|
+
*/
|
|
316
|
+
headerClassName?: string;
|
|
317
|
+
/**
|
|
318
|
+
* Sets the custom CSS classes to the column cells.
|
|
319
|
+
*/
|
|
320
|
+
className?: string;
|
|
321
|
+
/**
|
|
322
|
+
* Indicates whether the column is resizable.
|
|
323
|
+
*/
|
|
324
|
+
resizable?: boolean;
|
|
325
|
+
/**
|
|
326
|
+
* Indicates whether the column is reorderable.
|
|
327
|
+
*/
|
|
328
|
+
reorderable?: boolean;
|
|
329
|
+
/**
|
|
330
|
+
* The width of the column (in pixels) below which the user is not able to resize the column through the UI. Defaults to `10`.
|
|
331
|
+
*/
|
|
332
|
+
minResizableWidth?: number;
|
|
333
|
+
/**
|
|
334
|
+
* Determinates the position of the column.
|
|
335
|
+
* Columns with smaller `orderIndex` will appear before columns with bigger `orderIndex`.
|
|
336
|
+
* Defaults to `0`.
|
|
337
|
+
*/
|
|
338
|
+
orderIndex?: number;
|
|
339
|
+
/**
|
|
340
|
+
* The column identifier used to distinguish columns for example in multi column header scenarios with resize and keyboard navigation.
|
|
341
|
+
* Also used for unique key for rendering the component cells.
|
|
342
|
+
* If not set, the component will generate unique `id` automatically.
|
|
343
|
+
*/
|
|
344
|
+
id?: string;
|
|
345
|
+
/**
|
|
346
|
+
* Defines the component that will be rendered as a cell.
|
|
347
|
+
* If not set, a `Cell` will be rendered by default.
|
|
348
|
+
*/
|
|
349
|
+
cell?: ComponentType<CellProps>;
|
|
350
|
+
/**
|
|
351
|
+
* @hidden
|
|
352
|
+
*/
|
|
353
|
+
navigatable?: boolean;
|
|
354
|
+
/**
|
|
355
|
+
* @hidden
|
|
356
|
+
*/
|
|
357
|
+
locked?: boolean;
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
/**
|
|
361
|
+
* @hidden
|
|
362
|
+
*/
|
|
363
|
+
export declare const ColumnDefaultProps: {
|
|
364
|
+
filterable: boolean;
|
|
365
|
+
editable: boolean;
|
|
366
|
+
sortable: boolean;
|
|
367
|
+
resizable: boolean;
|
|
368
|
+
reorderable: boolean;
|
|
369
|
+
groupable: boolean;
|
|
370
|
+
};
|
|
371
|
+
|
|
372
|
+
/**
|
|
373
|
+
* @hidden
|
|
374
|
+
*/
|
|
375
|
+
declare interface ColumnDraggableProps {
|
|
376
|
+
pressHandler?: (draggableEvent: any, element: HTMLTableRowElement | HTMLDivElement) => void;
|
|
377
|
+
dragHandler?: (draggableEvent: any, element: HTMLTableRowElement | HTMLDivElement) => void;
|
|
378
|
+
releaseHandler?: (draggableEvent: any) => void;
|
|
379
|
+
ariaRowIndex?: number;
|
|
380
|
+
children?: React_2.ReactNode;
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
/**
|
|
384
|
+
* The `ColumnMenuBooleanColumn` component. Use it for `boolean` type columns.
|
|
385
|
+
*/
|
|
386
|
+
export declare const ColumnMenuBooleanColumn: React_2.FunctionComponent<ColumnMenuProps>;
|
|
387
|
+
|
|
388
|
+
export declare const ColumnMenuBooleanFilter: React_2.FunctionComponent<ColumnMenuFilterProps>;
|
|
389
|
+
|
|
390
|
+
/**
|
|
391
|
+
* The `ColumnMenuDateColumn` component. Use it for `Date` type columns.
|
|
392
|
+
*/
|
|
393
|
+
export declare const ColumnMenuDateColumn: React_2.FunctionComponent<ColumnMenuProps>;
|
|
394
|
+
|
|
395
|
+
export declare const ColumnMenuDateFilter: React_2.FunctionComponent<ColumnMenuFilterProps>;
|
|
396
|
+
|
|
397
|
+
/**
|
|
398
|
+
* @hidden
|
|
399
|
+
*/
|
|
400
|
+
export declare const ColumnMenuFilterForm: React_2.FunctionComponent<ColumnMenuFormProps>;
|
|
401
|
+
|
|
402
|
+
export declare const ColumnMenuFilterLogic: React_2.FunctionComponent<DropDownListProps>;
|
|
403
|
+
|
|
404
|
+
export declare interface ColumnMenuFilterProps {
|
|
405
|
+
filter: FilterDescriptor;
|
|
406
|
+
onFilterChange: (event: React_2.SyntheticEvent<any>, nextFilter: FilterDescriptor, prevFilter: FilterDescriptor) => void;
|
|
407
|
+
operators?: {
|
|
408
|
+
text: string;
|
|
409
|
+
operator: string;
|
|
410
|
+
}[];
|
|
411
|
+
initialFilter?: FilterDescriptor;
|
|
412
|
+
input?: React_2.ComponentType<{
|
|
413
|
+
value: any;
|
|
414
|
+
onChange: any;
|
|
415
|
+
}>;
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
export declare const ColumnMenuForm: React_2.FunctionComponent<ColumnMenuFormProps>;
|
|
419
|
+
|
|
420
|
+
export declare interface ColumnMenuFormProps {
|
|
421
|
+
show?: boolean;
|
|
422
|
+
onSubmit?: React_2.FormEventHandler<HTMLFormElement>;
|
|
423
|
+
onReset?: React_2.FormEventHandler<HTMLFormElement>;
|
|
424
|
+
actions?: React_2.ReactNode;
|
|
425
|
+
children?: React_2.ReactNode;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
export declare const ColumnMenuItem: React_2.FunctionComponent<ColumnMenuItemProps>;
|
|
429
|
+
|
|
430
|
+
export declare interface ColumnMenuItemProps {
|
|
431
|
+
onClick?: (event: React_2.MouseEvent<HTMLDivElement>) => void;
|
|
432
|
+
selected?: boolean;
|
|
433
|
+
disabled?: boolean;
|
|
434
|
+
iconClass?: string;
|
|
435
|
+
svgIcon?: SVGIcon;
|
|
436
|
+
title: string;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
/**
|
|
440
|
+
* The `ColumnMenuNumericColumn` component. Use it for `number` type columns.
|
|
441
|
+
*/
|
|
442
|
+
export declare const ColumnMenuNumericColumn: React_2.FunctionComponent<ColumnMenuProps>;
|
|
443
|
+
|
|
444
|
+
export declare const ColumnMenuNumericFilter: React_2.FunctionComponent<ColumnMenuFilterProps>;
|
|
445
|
+
|
|
446
|
+
/**
|
|
447
|
+
* Represents the operators for the ColumnMenuTextFilter, ColumnMenuNumericFilter,
|
|
448
|
+
* ColumnMenuDateFilter and ColumnMenuBooleanFilter components.
|
|
449
|
+
*
|
|
450
|
+
* The text field of each operator object will be resolved according to the
|
|
451
|
+
* [localization messages]({% slug globalization_datatools %}#toc-messages).
|
|
452
|
+
*/
|
|
453
|
+
export declare class ColumnMenuOperators {
|
|
454
|
+
/**
|
|
455
|
+
* An array containing the operators for the ColumnMenuTextFilter component.
|
|
456
|
+
*
|
|
457
|
+
* The operators are:
|
|
458
|
+
*
|
|
459
|
+
* - { text: 'columnMenu.filterContainsOperator', operator: 'contains' }
|
|
460
|
+
* - { text: 'columnMenu.filterNotContainsOperator', operator: 'doesnotcontain' }
|
|
461
|
+
* - { text: 'columnMenu.filterEqOperator', operator: 'eq' }
|
|
462
|
+
* - { text: 'columnMenu.filterNotEqOperator', operator: 'neq' }
|
|
463
|
+
* - { text: 'columnMenu.filterStartsWithOperator', operator: 'startswith' }
|
|
464
|
+
* - { text: 'columnMenu.filterEndsWithOperator', operator: 'endswith' }
|
|
465
|
+
* - { text: 'columnMenu.filterIsNullOperator', operator: 'isnull' }
|
|
466
|
+
* - { text: 'columnMenu.filterIsNotNullOperator', operator: 'isnotnull' }
|
|
467
|
+
* - { text: 'columnMenu.filterIsEmptyOperator', operator: 'isempty' }
|
|
468
|
+
* - { text: 'columnMenu.filterIsNotEmptyOperator', operator: 'isnotempty' }
|
|
469
|
+
*/
|
|
470
|
+
static get text(): FilterOperator[];
|
|
471
|
+
/**
|
|
472
|
+
* An array containing the operators for the ColumnMenuNumericFilter component.
|
|
473
|
+
*
|
|
474
|
+
* The operators are:
|
|
475
|
+
*
|
|
476
|
+
* - { text: 'columnMenu.filterEqOperator', operator: 'eq' }
|
|
477
|
+
* - { text: 'columnMenu.filterNotEqOperator', operator: 'neq' }
|
|
478
|
+
* - { text: 'columnMenu.filterGteOperator', operator: 'gte' }
|
|
479
|
+
* - { text: 'columnMenu.filterGtOperator', operator: 'gt' }
|
|
480
|
+
* - { text: 'columnMenu.filterLteOperator', operator: 'lte' }
|
|
481
|
+
* - { text: 'columnMenu.filterLtOperator', operator: 'lt' }
|
|
482
|
+
* - { text: 'columnMenu.filterIsNullOperator', operator: 'isnull' }
|
|
483
|
+
* - { text: 'columnMenu.filterIsNotNullOperator', operator: 'isnotnull' }
|
|
484
|
+
*/
|
|
485
|
+
static get numeric(): FilterOperator[];
|
|
486
|
+
/**
|
|
487
|
+
* An array containing the operators for the ColumnMenuDateFilter component.
|
|
488
|
+
*
|
|
489
|
+
* The operators are:
|
|
490
|
+
*
|
|
491
|
+
* - { text: 'columnMenu.filterEqOperator', operator: 'eq' }
|
|
492
|
+
* - { text: 'columnMenu.filterNotEqOperator', operator: 'neq' }
|
|
493
|
+
* - { text: 'columnMenu.filterAfterOrEqualOperator', operator: 'gte' }
|
|
494
|
+
* - { text: 'columnMenu.filterAfterOperator', operator: 'gt' }
|
|
495
|
+
* - { text: 'columnMenu.filterBeforeOperator', operator: 'lt' }
|
|
496
|
+
* - { text: 'columnMenu.filterBeforeOrEqualOperator', operator: 'lte' }
|
|
497
|
+
* - { text: 'columnMenu.filterIsNullOperator', operator: 'isnull' }
|
|
498
|
+
* - { text: 'columnMenu.filterIsNotNullOperator', operator: 'isnotnull' }
|
|
499
|
+
*/
|
|
500
|
+
static get date(): FilterOperator[];
|
|
501
|
+
/**
|
|
502
|
+
* An array containing the operators for the ColumnMenuBooleanFilter component.
|
|
503
|
+
*
|
|
504
|
+
* The operators are:
|
|
505
|
+
*
|
|
506
|
+
* - { text: 'columnMenu.filterIsTrue', operator: '' }
|
|
507
|
+
*/
|
|
508
|
+
static get boolean(): FilterOperator[];
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
/**
|
|
512
|
+
* The props of the ColumnMenu component.
|
|
513
|
+
*/
|
|
514
|
+
export declare interface ColumnMenuProps {
|
|
515
|
+
/**
|
|
516
|
+
* The descriptors by which the data is sorted.
|
|
517
|
+
*/
|
|
518
|
+
sort?: SortDescriptor[];
|
|
519
|
+
/**
|
|
520
|
+
* Fires when the sorting of the ColumnMenu is changed.
|
|
521
|
+
*/
|
|
522
|
+
onSortChange?: (event: React_2.SyntheticEvent<any>, sort: SortDescriptor[], field: string) => void;
|
|
523
|
+
/**
|
|
524
|
+
* The descriptors by which the data is filtered.
|
|
525
|
+
*/
|
|
526
|
+
filter?: CompositeFilterDescriptor[];
|
|
527
|
+
/**
|
|
528
|
+
* Fires when the ColumnMenu filter is changed.
|
|
529
|
+
*/
|
|
530
|
+
onFilterChange?: (event: React_2.SyntheticEvent<any>, filter: CompositeFilterDescriptor[], field: string) => void;
|
|
531
|
+
/**
|
|
532
|
+
* The field to which the ColumnMenu is bound.
|
|
533
|
+
*/
|
|
534
|
+
field?: string;
|
|
535
|
+
/**
|
|
536
|
+
* If set to `true`, a button for sorting in `asc` direction will be rendered.
|
|
537
|
+
*/
|
|
538
|
+
sortAsc?: boolean;
|
|
539
|
+
/**
|
|
540
|
+
* If set to `true`, a button for sorting in `desc` direction will be rendered.
|
|
541
|
+
*/
|
|
542
|
+
sortDesc?: boolean;
|
|
543
|
+
/**
|
|
544
|
+
* Defines the filtering UI and accepts an array with components.
|
|
545
|
+
*/
|
|
546
|
+
filterContent?: any[];
|
|
547
|
+
/**
|
|
548
|
+
* Defines the initial expand state of the filters.
|
|
549
|
+
* Defaults to `false`.
|
|
550
|
+
*/
|
|
551
|
+
expandFilters?: boolean;
|
|
552
|
+
/**
|
|
553
|
+
* A function that returns the initial filter descriptor base on the ColumnMenu field.
|
|
554
|
+
* Use it to customize the initial values of the filtering components.
|
|
555
|
+
*/
|
|
556
|
+
initialFilter?: (field: string) => CompositeFilterDescriptor;
|
|
557
|
+
/**
|
|
558
|
+
* Fires when the ColumnMenu items are about to be rendered. Use it to add or remove menu items.
|
|
559
|
+
* The `defaultRendering` is an array with the sorting and filtering components.
|
|
560
|
+
* `props` contains the column's field and the closeMenu function which closes the ColumnMenu.
|
|
561
|
+
*/
|
|
562
|
+
itemsRender?: (defaultRendering: (React_2.ReactElement<HTMLDivElement> | null)[], props: {
|
|
563
|
+
field?: string;
|
|
564
|
+
closeMenu: () => void;
|
|
565
|
+
}) => React_2.ReactNode;
|
|
566
|
+
/**
|
|
567
|
+
* Fires when the ColumnMenu is about to be rendered. Use it to override the default rendering of the ColumnMenu.
|
|
568
|
+
* The defaultRendering is an array with the button `React.ReactElement<HTMLSpanElement>` and popup `React.ReactElement<PopupProps>` components.
|
|
569
|
+
*/
|
|
570
|
+
render?: (defaultRendering: React_2.ReactElement<any>[]) => React_2.ReactNode;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
/**
|
|
574
|
+
* The `ColumnMenuTextColumn` component. Use it for `string` type columns.
|
|
575
|
+
*/
|
|
576
|
+
export declare const ColumnMenuTextColumn: React_2.FunctionComponent<ColumnMenuProps>;
|
|
577
|
+
|
|
578
|
+
export declare const ColumnMenuTextFilter: React_2.FunctionComponent<ColumnMenuFilterProps>;
|
|
579
|
+
|
|
580
|
+
/**
|
|
581
|
+
* @hidden
|
|
582
|
+
*/
|
|
583
|
+
export declare class ColumnResize<C = CellProps, H = HeaderCellProps, F = FilterCellProps> {
|
|
584
|
+
/**
|
|
585
|
+
* The main `colgroup` of the Grid.
|
|
586
|
+
*/
|
|
587
|
+
colGroupMain: any | null;
|
|
588
|
+
/**
|
|
589
|
+
* The header `colgroup` of the Grid (if any).
|
|
590
|
+
*/
|
|
591
|
+
colGroupHeader: any | null;
|
|
592
|
+
/**
|
|
593
|
+
* The footer `colgroup` of the Grid (if any).
|
|
594
|
+
*/
|
|
595
|
+
colGroupFooter: any | null;
|
|
596
|
+
columns: ExtendedColumnProps<C, H, F>[];
|
|
597
|
+
/**
|
|
598
|
+
* The settings for resizing the Grid.
|
|
599
|
+
*/
|
|
600
|
+
resizable: boolean;
|
|
601
|
+
onResize: (index: number, newWidth: number, oldWidth: number, originalEvent: any, end: boolean) => void;
|
|
602
|
+
private isRtl;
|
|
603
|
+
constructor(triggerResize: (index: number, newWidth: number, oldWidth: number, originalEvent: any, end: boolean) => void);
|
|
604
|
+
setIsRtl: (isRtl: boolean) => void;
|
|
605
|
+
dragHandler(event: any, column: ExtendedColumnProps<C, H, F>, dragCue: HTMLSpanElement, end: boolean): void;
|
|
606
|
+
private setWidths;
|
|
607
|
+
private updateColElements;
|
|
608
|
+
private setColWidth;
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
/**
|
|
612
|
+
* @hidden
|
|
613
|
+
*/
|
|
614
|
+
export declare class ColumnResizer extends React_2.Component<ColumnResizerResizerProps, {}> {
|
|
615
|
+
private draggable;
|
|
616
|
+
private isDragged;
|
|
617
|
+
/**
|
|
618
|
+
* @hidden
|
|
619
|
+
*/
|
|
620
|
+
onDrag: (data: any) => void;
|
|
621
|
+
/**
|
|
622
|
+
* @hidden
|
|
623
|
+
*/
|
|
624
|
+
onRelease: (data: any) => void;
|
|
625
|
+
/**
|
|
626
|
+
* @hidden
|
|
627
|
+
*/
|
|
628
|
+
onDoubleClick: (event: React_2.MouseEvent<HTMLSpanElement, MouseEvent>) => void;
|
|
629
|
+
render(): JSX_2.Element;
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
/**
|
|
633
|
+
* @hidden
|
|
634
|
+
*/
|
|
635
|
+
declare interface ColumnResizerResizerProps {
|
|
636
|
+
resize: (event: any, dragCue: HTMLSpanElement, end: boolean) => void;
|
|
637
|
+
autofit?: (event: React_2.MouseEvent<HTMLSpanElement, MouseEvent>, dragCue: HTMLSpanElement) => void;
|
|
638
|
+
}
|
|
639
|
+
|
|
640
|
+
/**
|
|
641
|
+
* The settings for sorting the columns of the component.
|
|
642
|
+
*/
|
|
643
|
+
export declare type ColumnSortSettings = boolean | {
|
|
644
|
+
/**
|
|
645
|
+
* Enables the removal of the column sorting functionality.
|
|
646
|
+
*/
|
|
647
|
+
allowUnsort?: boolean;
|
|
648
|
+
};
|
|
649
|
+
|
|
650
|
+
/**
|
|
651
|
+
* @hidden
|
|
652
|
+
*/
|
|
653
|
+
export declare class CommonDragLogic<C = CellProps, H = HeaderCellProps, F = FilterCellProps> {
|
|
654
|
+
columns: ExtendedColumnProps<C, H, F>[];
|
|
655
|
+
reorderable: boolean;
|
|
656
|
+
groupable: boolean;
|
|
657
|
+
private startColumn;
|
|
658
|
+
private startGroup;
|
|
659
|
+
private currentColumn;
|
|
660
|
+
private currentGroup;
|
|
661
|
+
private columnReorder;
|
|
662
|
+
private groupReorder;
|
|
663
|
+
private columnToGroup;
|
|
664
|
+
private dropElementClue;
|
|
665
|
+
private dragElementClue;
|
|
666
|
+
private groupPanelDivElement;
|
|
667
|
+
constructor(columnReorder: handler, groupReorder: handler, columnToGroup: handler);
|
|
668
|
+
refGroupPanelDiv: (e: HTMLDivElement | null) => void;
|
|
669
|
+
refDropElementClue: (e: DropClue | null) => void;
|
|
670
|
+
refDragElementClue: (e: DragClue | null) => void;
|
|
671
|
+
pressHandler: (event: any, element: HTMLTableRowElement | HTMLDivElement) => void;
|
|
672
|
+
dragHandler: (event: any, element: HTMLTableRowElement | HTMLDivElement) => void;
|
|
673
|
+
releaseHandler: (event: any) => void;
|
|
674
|
+
private getColumnIndex;
|
|
675
|
+
private getGroupIndex;
|
|
676
|
+
private isValid;
|
|
677
|
+
private updateDragElementClue;
|
|
678
|
+
private updateDropElementClue;
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
/**
|
|
682
|
+
* Creates a tree from the passed dataset.
|
|
683
|
+
*
|
|
684
|
+
* @param {object[]} dataset - The source dataset of data items.
|
|
685
|
+
* @param {(item: object) => any} getId - A function which will return the id of the data item.
|
|
686
|
+
* @param {(item: object) => any} getParentId - A function which will return the data item id of its parent data item.
|
|
687
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
688
|
+
* @returns {object[]} - A collection of the generated data items that are structured in a tree.
|
|
689
|
+
*/
|
|
690
|
+
export declare const createDataTree: (dataset: any[], getId: (item: any) => any, getParentId: (item: any) => any, subItemsField: string) => any[];
|
|
691
|
+
|
|
692
|
+
/**
|
|
693
|
+
* @hidden
|
|
694
|
+
*/
|
|
695
|
+
export declare const createFilterComponent: (settings: FilterComponentSettings) => React_2.ComponentClass<FilterComponentProps, any>;
|
|
696
|
+
|
|
697
|
+
/**
|
|
698
|
+
* @hidden
|
|
699
|
+
*/
|
|
700
|
+
declare interface DataItemWrapper {
|
|
701
|
+
dataItem: any;
|
|
702
|
+
level: number[];
|
|
703
|
+
height: number;
|
|
704
|
+
offsetTop: number;
|
|
705
|
+
levelCount: number;
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
/**
|
|
709
|
+
* The DateFilter component used for editing date value of FilterDescriptor object.
|
|
710
|
+
*/
|
|
711
|
+
export declare class DateFilter extends React_2.Component<DateFilterProps> {
|
|
712
|
+
/**
|
|
713
|
+
* @hidden
|
|
714
|
+
*/
|
|
715
|
+
static propTypes: {
|
|
716
|
+
filter: PropTypes.Validator<object>;
|
|
717
|
+
onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
718
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
719
|
+
};
|
|
720
|
+
/**
|
|
721
|
+
* @hidden
|
|
722
|
+
*/
|
|
723
|
+
render(): JSX_2.Element;
|
|
724
|
+
private onChange;
|
|
725
|
+
}
|
|
726
|
+
|
|
727
|
+
/**
|
|
728
|
+
* @hidden
|
|
729
|
+
*/
|
|
730
|
+
export declare class DateFilterCell extends DateFilterCell_base {
|
|
731
|
+
}
|
|
732
|
+
|
|
733
|
+
declare const DateFilterCell_base: React_2.ComponentClass<FilterComponentProps, any>;
|
|
734
|
+
|
|
735
|
+
/**
|
|
736
|
+
* The props of the DateFilter component.
|
|
737
|
+
*/
|
|
738
|
+
export declare interface DateFilterProps extends TextFilterProps {
|
|
739
|
+
}
|
|
740
|
+
|
|
741
|
+
/**
|
|
742
|
+
* @hidden
|
|
743
|
+
*/
|
|
744
|
+
export declare class DragClue extends React_2.PureComponent<any, DragClueState> {
|
|
745
|
+
private elementRef;
|
|
746
|
+
readonly state: DragClueState;
|
|
747
|
+
hiddenElementRef: React_2.RefObject<HTMLDivElement>;
|
|
748
|
+
get element(): HTMLDivElement | null;
|
|
749
|
+
constructor(props: any);
|
|
750
|
+
render(): JSX_2.Element;
|
|
751
|
+
}
|
|
752
|
+
|
|
753
|
+
/**
|
|
754
|
+
* @hidden
|
|
755
|
+
*/
|
|
756
|
+
declare interface DragClueState {
|
|
757
|
+
visible: boolean;
|
|
758
|
+
top: number;
|
|
759
|
+
left: number;
|
|
760
|
+
innerText: string;
|
|
761
|
+
status: 'k-i-cancel' | 'k-i-plus';
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
/**
|
|
765
|
+
* @hidden
|
|
766
|
+
*/
|
|
767
|
+
export declare class DropClue extends React_2.PureComponent<any, DropClueState> {
|
|
768
|
+
readonly state: DropClueState;
|
|
769
|
+
hiddenElementRef: React_2.RefObject<HTMLDivElement>;
|
|
770
|
+
constructor(props: any);
|
|
771
|
+
render(): JSX_2.Element;
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
/**
|
|
775
|
+
* @hidden
|
|
776
|
+
*/
|
|
777
|
+
declare interface DropClueState {
|
|
778
|
+
visible: boolean;
|
|
779
|
+
top: number;
|
|
780
|
+
left: number;
|
|
781
|
+
height: number;
|
|
782
|
+
}
|
|
783
|
+
|
|
784
|
+
/**
|
|
785
|
+
* The EnumFilter component used for editing the value of FilterDescriptor object.
|
|
786
|
+
* It renders a DropDownList and allows you to choose a value from the predefined list.
|
|
787
|
+
*/
|
|
788
|
+
export declare class EnumFilter extends React_2.Component<EnumFilterProps> {
|
|
789
|
+
/**
|
|
790
|
+
* @hidden
|
|
791
|
+
*/
|
|
792
|
+
static propTypes: {
|
|
793
|
+
filter: PropTypes.Validator<object>;
|
|
794
|
+
onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
795
|
+
data: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
796
|
+
text: PropTypes.Requireable<string>;
|
|
797
|
+
value: PropTypes.Requireable<any>;
|
|
798
|
+
}> | null | undefined)[]>;
|
|
799
|
+
defaultItem: PropTypes.Requireable<any>;
|
|
800
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
801
|
+
};
|
|
802
|
+
/**
|
|
803
|
+
* @hidden
|
|
804
|
+
*/
|
|
805
|
+
render(): JSX_2.Element;
|
|
806
|
+
private onChange;
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
/**
|
|
810
|
+
* The props of the EnumFilter component.
|
|
811
|
+
*/
|
|
812
|
+
export declare interface EnumFilterProps extends TextFilterProps {
|
|
813
|
+
/**
|
|
814
|
+
* A collection of text-value pairs passed to the EnumFilter DropDownList.
|
|
815
|
+
*/
|
|
816
|
+
data?: Array<{
|
|
817
|
+
text: string;
|
|
818
|
+
value: any;
|
|
819
|
+
}>;
|
|
820
|
+
/**
|
|
821
|
+
* The defaultItem passed to the EnumFilter DropDownList.
|
|
822
|
+
*/
|
|
823
|
+
defaultItem?: any;
|
|
824
|
+
}
|
|
825
|
+
|
|
826
|
+
/**
|
|
827
|
+
* @hidden
|
|
828
|
+
*/
|
|
829
|
+
export declare class Expression extends React_2.Component<ExpressionProps> {
|
|
830
|
+
static propTypes: {
|
|
831
|
+
filter: PropTypes.Validator<object>;
|
|
832
|
+
fields: PropTypes.Validator<any[]>;
|
|
833
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
834
|
+
onChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
835
|
+
onRemove: PropTypes.Validator<(...args: any[]) => any>;
|
|
836
|
+
};
|
|
837
|
+
render(): JSX_2.Element;
|
|
838
|
+
private onFieldChange;
|
|
839
|
+
private onOperatorChange;
|
|
840
|
+
private onInputChange;
|
|
841
|
+
private triggerOnFilterChange;
|
|
842
|
+
private onFilterRemove;
|
|
843
|
+
}
|
|
844
|
+
|
|
845
|
+
/**
|
|
846
|
+
* @hidden
|
|
847
|
+
*/
|
|
848
|
+
export declare interface ExpressionChangeEvent extends BaseEvent<Expression> {
|
|
849
|
+
prevFilter: FilterDescriptor;
|
|
850
|
+
nextFilter: FilterDescriptor;
|
|
851
|
+
}
|
|
852
|
+
|
|
853
|
+
/**
|
|
854
|
+
* @hidden
|
|
855
|
+
*/
|
|
856
|
+
export declare interface ExpressionProps {
|
|
857
|
+
filter: FilterDescriptor;
|
|
858
|
+
fields: Array<FieldSettings>;
|
|
859
|
+
ariaLabel?: string;
|
|
860
|
+
onChange: (event: ExpressionChangeEvent) => void;
|
|
861
|
+
onRemove: (event: ExpressionRemoveEvent) => void;
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
/**
|
|
865
|
+
* @hidden
|
|
866
|
+
*/
|
|
867
|
+
export declare interface ExpressionRemoveEvent extends BaseEvent<Expression> {
|
|
868
|
+
filter: FilterDescriptor;
|
|
869
|
+
}
|
|
870
|
+
|
|
871
|
+
/**
|
|
872
|
+
* Similar to the `Object.assign` function. Additionally, creates a new array for the subitems.
|
|
873
|
+
*
|
|
874
|
+
* @param {object} item - The source data item.
|
|
875
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
876
|
+
* @param {object} propsToExtend - The props with which the source data item will be extended.
|
|
877
|
+
* @returns {object} - The target data item.
|
|
878
|
+
*/
|
|
879
|
+
export declare const extendDataItem: (item: any, subItemsField: string, propsToExtend?: any) => any;
|
|
880
|
+
|
|
881
|
+
/**
|
|
882
|
+
* @hidden
|
|
883
|
+
*/
|
|
884
|
+
export declare interface ExtendedColumnProps<CellProps = CellProps, HeaderCellProps = HeaderCellProps, FilterCellProps = FilterCellProps> extends TreeColumnBaseProps<CellProps, HeaderCellProps, FilterCellProps> {
|
|
885
|
+
declarationIndex: number;
|
|
886
|
+
parentIndex: number;
|
|
887
|
+
colSpan: number;
|
|
888
|
+
rowSpan: number;
|
|
889
|
+
depth: number;
|
|
890
|
+
kFirst?: boolean;
|
|
891
|
+
index: number;
|
|
892
|
+
children: ExtendedColumnProps<CellProps, HeaderCellProps, FilterCellProps>[];
|
|
893
|
+
left: number;
|
|
894
|
+
right: number;
|
|
895
|
+
rightBorder: boolean;
|
|
896
|
+
groupable: boolean;
|
|
897
|
+
ariaColumnIndex: number;
|
|
898
|
+
isAccessible: boolean;
|
|
899
|
+
}
|
|
900
|
+
|
|
901
|
+
/**
|
|
902
|
+
* The FieldSettings object.
|
|
903
|
+
*/
|
|
904
|
+
export declare interface FieldSettings {
|
|
905
|
+
/**
|
|
906
|
+
* The field name.
|
|
907
|
+
*/
|
|
908
|
+
name: string;
|
|
909
|
+
/**
|
|
910
|
+
* The field label, which will be shown in the fields DropDownList.
|
|
911
|
+
*/
|
|
912
|
+
label: string;
|
|
913
|
+
/**
|
|
914
|
+
* The filter editor component. Could be any of the built-in TextFilter, NumericFilter, DateFilter, BooleanFilter or a custom component.
|
|
915
|
+
*/
|
|
916
|
+
filter: any;
|
|
917
|
+
/**
|
|
918
|
+
* The collection of operators which will be passed to the operators DropDownList.
|
|
919
|
+
*/
|
|
920
|
+
operators: Array<FilterOperator>;
|
|
921
|
+
/**
|
|
922
|
+
* Specifies the smallest value that can be entered.
|
|
923
|
+
*/
|
|
924
|
+
min?: number;
|
|
925
|
+
/**
|
|
926
|
+
* Specifies the greatest value that can be entered.
|
|
927
|
+
*/
|
|
928
|
+
max?: number;
|
|
929
|
+
}
|
|
930
|
+
|
|
931
|
+
/**
|
|
932
|
+
* Represents the [KendoReact Filter component]({% slug overview_filter %}).
|
|
933
|
+
*/
|
|
934
|
+
export declare class Filter extends React_2.Component<FilterProps> {
|
|
935
|
+
/**
|
|
936
|
+
* @hidden
|
|
937
|
+
*/
|
|
938
|
+
static propTypes: {
|
|
939
|
+
className: PropTypes.Requireable<string>;
|
|
940
|
+
style: PropTypes.Requireable<object>;
|
|
941
|
+
fields: (props: FilterProps, propName: string) => Error | null;
|
|
942
|
+
ariaLabelGroup: PropTypes.Requireable<string>;
|
|
943
|
+
ariaLabelExpression: PropTypes.Requireable<string>;
|
|
944
|
+
value: PropTypes.Validator<object>;
|
|
945
|
+
onChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
946
|
+
};
|
|
947
|
+
constructor(props: FilterProps);
|
|
948
|
+
/**
|
|
949
|
+
* @hidden
|
|
950
|
+
*/
|
|
951
|
+
render(): JSX_2.Element;
|
|
952
|
+
private onFilterChange;
|
|
953
|
+
private onGroupRemove;
|
|
954
|
+
}
|
|
955
|
+
|
|
956
|
+
/**
|
|
957
|
+
* @hidden
|
|
958
|
+
*/
|
|
959
|
+
export declare const FILTER_ROW_CLASS = "k-table-row k-filter-row";
|
|
960
|
+
|
|
961
|
+
/**
|
|
962
|
+
* Filters the provided data tree according to the specified `Array<FilterDescriptor|CompositeFilterDescriptor>`.
|
|
963
|
+
*
|
|
964
|
+
* @param {T[]} data - The data that will be filtered.
|
|
965
|
+
* @param {FilterDescriptor[]|CompositeFilterDescriptor[]} descriptors - The filter criteria that will be applied.
|
|
966
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
967
|
+
* @returns {T[]} - The filtered data.
|
|
968
|
+
*/
|
|
969
|
+
export declare function filterBy(data: any[], descriptors: FilterDescriptor[] | CompositeFilterDescriptor[], subItemsField: string): any[];
|
|
970
|
+
|
|
971
|
+
/**
|
|
972
|
+
* @hidden
|
|
973
|
+
*/
|
|
974
|
+
export declare interface FilterCellProps {
|
|
975
|
+
/**
|
|
976
|
+
* The column field in which the cell is located.
|
|
977
|
+
*/
|
|
978
|
+
field?: string;
|
|
979
|
+
/**
|
|
980
|
+
* The function that will be called if the cell needs to notify its parent TreeList about a change.
|
|
981
|
+
*/
|
|
982
|
+
onFilterChange?: (event: {
|
|
983
|
+
filter: Array<FilterDescriptor>;
|
|
984
|
+
field: string;
|
|
985
|
+
syntheticEvent: React.SyntheticEvent<any>;
|
|
986
|
+
}) => void;
|
|
987
|
+
/**
|
|
988
|
+
* The collection of `FilterDescriptor` objects that is passed by the TreeList component.
|
|
989
|
+
*/
|
|
990
|
+
filter?: FilterDescriptor[];
|
|
991
|
+
/**
|
|
992
|
+
* @hidden
|
|
993
|
+
*/
|
|
994
|
+
components?: {
|
|
995
|
+
DatePicker?: any;
|
|
996
|
+
DropDownList?: any;
|
|
997
|
+
Input?: any;
|
|
998
|
+
NumericTextBox?: any;
|
|
999
|
+
};
|
|
1000
|
+
/**
|
|
1001
|
+
* @hidden
|
|
1002
|
+
*/
|
|
1003
|
+
clearButtonTitle?: string;
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
/**
|
|
1007
|
+
* The FilterChangeEvent object.
|
|
1008
|
+
*/
|
|
1009
|
+
export declare interface FilterChangeEvent extends BaseEvent<Filter> {
|
|
1010
|
+
/**
|
|
1011
|
+
* The changed composite filter descriptor.
|
|
1012
|
+
*/
|
|
1013
|
+
filter: CompositeFilterDescriptor;
|
|
1014
|
+
}
|
|
1015
|
+
|
|
1016
|
+
/**
|
|
1017
|
+
* @hidden
|
|
1018
|
+
*/
|
|
1019
|
+
export declare interface FilterComponentProps extends FilterCellProps {
|
|
1020
|
+
/**
|
|
1021
|
+
* The list of the operators.
|
|
1022
|
+
*/
|
|
1023
|
+
operators?: FilterOperator[];
|
|
1024
|
+
/**
|
|
1025
|
+
* The accessible label of the component.
|
|
1026
|
+
*/
|
|
1027
|
+
ariaLabel?: string;
|
|
1028
|
+
/**
|
|
1029
|
+
* @hidden
|
|
1030
|
+
*/
|
|
1031
|
+
min?: number;
|
|
1032
|
+
/**
|
|
1033
|
+
* @hidden
|
|
1034
|
+
*/
|
|
1035
|
+
max?: number;
|
|
1036
|
+
}
|
|
1037
|
+
|
|
1038
|
+
/**
|
|
1039
|
+
* @hidden
|
|
1040
|
+
*/
|
|
1041
|
+
export declare interface FilterComponentSettings {
|
|
1042
|
+
inputComponent: (props: any) => React_2.ReactNode;
|
|
1043
|
+
operatorComponent: (props: any, cellProps: FilterComponentProps) => React_2.ReactNode;
|
|
1044
|
+
emptyFilter: FilterDescriptor;
|
|
1045
|
+
operators?: FilterOperator[];
|
|
1046
|
+
}
|
|
1047
|
+
|
|
1048
|
+
/**
|
|
1049
|
+
* A filter operator object.
|
|
1050
|
+
*/
|
|
1051
|
+
export declare interface FilterOperator {
|
|
1052
|
+
/**
|
|
1053
|
+
* The label of the operator.
|
|
1054
|
+
*/
|
|
1055
|
+
text: string;
|
|
1056
|
+
/**
|
|
1057
|
+
* The operator value.
|
|
1058
|
+
*/
|
|
1059
|
+
operator: any;
|
|
1060
|
+
}
|
|
1061
|
+
|
|
1062
|
+
/**
|
|
1063
|
+
* The props of the Filter component.
|
|
1064
|
+
*/
|
|
1065
|
+
export declare interface FilterProps {
|
|
1066
|
+
/**
|
|
1067
|
+
* Sets additional classes to the Filter.
|
|
1068
|
+
*/
|
|
1069
|
+
className?: string;
|
|
1070
|
+
/**
|
|
1071
|
+
* The styles that are applied to the Filter.
|
|
1072
|
+
*/
|
|
1073
|
+
style?: React_2.CSSProperties;
|
|
1074
|
+
/**
|
|
1075
|
+
* The fields settings of the Filter.
|
|
1076
|
+
*/
|
|
1077
|
+
fields: Array<FieldSettings>;
|
|
1078
|
+
/**
|
|
1079
|
+
* The composite filter descriptor value.
|
|
1080
|
+
*/
|
|
1081
|
+
value: CompositeFilterDescriptor;
|
|
1082
|
+
/**
|
|
1083
|
+
* Represents the aria-label prop of the Filter's container component.
|
|
1084
|
+
*/
|
|
1085
|
+
ariaLabel?: string;
|
|
1086
|
+
/**
|
|
1087
|
+
* Represents the aria-label prop of the Filter's underlying Group component.
|
|
1088
|
+
*/
|
|
1089
|
+
ariaLabelGroup?: string;
|
|
1090
|
+
/**
|
|
1091
|
+
* Represents the aria-label prop of the Filter's underlying Expression component.
|
|
1092
|
+
*/
|
|
1093
|
+
ariaLabelExpression?: string;
|
|
1094
|
+
/**
|
|
1095
|
+
* The Filter onChange event.
|
|
1096
|
+
*/
|
|
1097
|
+
onChange: (event: FilterChangeEvent) => void;
|
|
1098
|
+
/**
|
|
1099
|
+
* The initial composite filter descriptor which will be used when a new group is created.
|
|
1100
|
+
*/
|
|
1101
|
+
defaultGroupFilter?: CompositeFilterDescriptor;
|
|
1102
|
+
}
|
|
1103
|
+
|
|
1104
|
+
/**
|
|
1105
|
+
* @hidden
|
|
1106
|
+
*/
|
|
1107
|
+
export declare const FilterRow: (props: FilterRowProps) => JSX_2.Element;
|
|
1108
|
+
|
|
1109
|
+
/**
|
|
1110
|
+
* @hidden
|
|
1111
|
+
*/
|
|
1112
|
+
export declare interface FilterRowProps {
|
|
1113
|
+
columns: ExtendedColumnProps[];
|
|
1114
|
+
filter?: FilterDescriptor[];
|
|
1115
|
+
filterChange: (event: {
|
|
1116
|
+
filter: FilterDescriptor[];
|
|
1117
|
+
field: string;
|
|
1118
|
+
syntheticEvent: React_2.SyntheticEvent<any>;
|
|
1119
|
+
}) => void;
|
|
1120
|
+
sort?: SortDescriptor[];
|
|
1121
|
+
ariaRowIndex?: number;
|
|
1122
|
+
}
|
|
1123
|
+
|
|
1124
|
+
/**
|
|
1125
|
+
* @hidden
|
|
1126
|
+
*/
|
|
1127
|
+
export declare function flatData(data: any[], getChildren: (dataItem: any) => any[], itemMap: (item: any) => any): DataItemWrapper[];
|
|
1128
|
+
|
|
1129
|
+
/**
|
|
1130
|
+
* @hidden
|
|
1131
|
+
*/
|
|
1132
|
+
export declare const FOCUSABLE_ELEMENTS: string[];
|
|
1133
|
+
|
|
1134
|
+
/** @hidden */
|
|
1135
|
+
export declare const getColumnIndex: (element: HTMLTableCellElement) => number | undefined;
|
|
1136
|
+
|
|
1137
|
+
/**
|
|
1138
|
+
* Get all group ids from the data.
|
|
1139
|
+
*
|
|
1140
|
+
* @param {{data: any[]}} options - The options to be processed.
|
|
1141
|
+
* @returns {string[]} - Collection of all group ids from the data.
|
|
1142
|
+
*/
|
|
1143
|
+
export declare const getGroupIds: (options: {
|
|
1144
|
+
data: any;
|
|
1145
|
+
}) => string[];
|
|
1146
|
+
|
|
1147
|
+
/**
|
|
1148
|
+
* @hidden
|
|
1149
|
+
*/
|
|
1150
|
+
export declare function getIndex(event: any, parent: HTMLTableRowElement | HTMLDivElement | null): number;
|
|
1151
|
+
|
|
1152
|
+
/**
|
|
1153
|
+
* Returns the data item path in the tree based on the level parameter.
|
|
1154
|
+
*
|
|
1155
|
+
* @param {any[]} tree - The data tree.
|
|
1156
|
+
* @param {number[]} level - The level of the target tree item.
|
|
1157
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
1158
|
+
* @returns {any[]} - The path of the data item.
|
|
1159
|
+
*/
|
|
1160
|
+
export declare const getItemPath: (tree: any[], level: number[], subItemsField?: string) => any[];
|
|
1161
|
+
|
|
1162
|
+
/** @hidden */
|
|
1163
|
+
export declare const getOffset: (offsetParent: any) => any;
|
|
1164
|
+
|
|
1165
|
+
/** @hidden */
|
|
1166
|
+
export declare const getRowIndex: (element: HTMLTableRowElement) => number | undefined;
|
|
1167
|
+
|
|
1168
|
+
/**
|
|
1169
|
+
* Get selected state from the component selection event.
|
|
1170
|
+
*
|
|
1171
|
+
* @param {{event: TableSelectionChangeEvent, selectedState: {[id: string]: boolean | number[]}, dataItemKey: string}} options
|
|
1172
|
+
* @returns {{[id: string]: boolean | number[]}} - The new selected state.
|
|
1173
|
+
*/
|
|
1174
|
+
export declare const getSelectedState: (options: {
|
|
1175
|
+
event: TableSelectionChangeEvent<any>;
|
|
1176
|
+
selectedState: {
|
|
1177
|
+
[id: string]: boolean | number[];
|
|
1178
|
+
};
|
|
1179
|
+
dataItemKey: string;
|
|
1180
|
+
}) => {
|
|
1181
|
+
[id: string]: boolean | number[];
|
|
1182
|
+
};
|
|
1183
|
+
|
|
1184
|
+
/**
|
|
1185
|
+
* Get selected state from the component KeyDown event.
|
|
1186
|
+
*
|
|
1187
|
+
* @param {{event: TableKeyDownEvent, selectedState: {[id: string]: boolean | number[]}, dataItemKey: string}} options
|
|
1188
|
+
* @returns {{[id: string]: boolean | number[]}} - The new selected state.
|
|
1189
|
+
*/
|
|
1190
|
+
export declare const getSelectedStateFromKeyDown: (options: {
|
|
1191
|
+
event: TableKeyDownEvent<any>;
|
|
1192
|
+
selectedState: {
|
|
1193
|
+
[id: string]: boolean | number[];
|
|
1194
|
+
};
|
|
1195
|
+
dataItemKey: string;
|
|
1196
|
+
}) => {
|
|
1197
|
+
[id: string]: boolean | number[];
|
|
1198
|
+
};
|
|
1199
|
+
|
|
1200
|
+
/** @hidden */
|
|
1201
|
+
export declare const getSelectionOptions: (selectable?: TableSelectableSettings) => {
|
|
1202
|
+
enabled: boolean;
|
|
1203
|
+
drag: boolean;
|
|
1204
|
+
mode: TableSelectableMode;
|
|
1205
|
+
cell: boolean;
|
|
1206
|
+
};
|
|
1207
|
+
|
|
1208
|
+
/**
|
|
1209
|
+
* @hidden
|
|
1210
|
+
*/
|
|
1211
|
+
export declare class Group extends React_2.Component<GroupProps> {
|
|
1212
|
+
static propTypes: {
|
|
1213
|
+
filter: PropTypes.Validator<object>;
|
|
1214
|
+
fields: PropTypes.Validator<any[]>;
|
|
1215
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
1216
|
+
ariaLabelExpression: PropTypes.Requireable<string>;
|
|
1217
|
+
onChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
1218
|
+
onRemove: PropTypes.Validator<(...args: any[]) => any>;
|
|
1219
|
+
defaultGroupFilter: PropTypes.Validator<object>;
|
|
1220
|
+
};
|
|
1221
|
+
render(): JSX_2.Element;
|
|
1222
|
+
private onGroupRemove;
|
|
1223
|
+
private onAddExpression;
|
|
1224
|
+
private onAddGroup;
|
|
1225
|
+
private onLogicAnd;
|
|
1226
|
+
private onLogicOr;
|
|
1227
|
+
private changeLogic;
|
|
1228
|
+
private replaceFilter;
|
|
1229
|
+
private onChange;
|
|
1230
|
+
private onRemove;
|
|
1231
|
+
}
|
|
1232
|
+
|
|
1233
|
+
/**
|
|
1234
|
+
* @hidden
|
|
1235
|
+
*/
|
|
1236
|
+
export declare interface GroupChangeEvent extends BaseEvent<Group> {
|
|
1237
|
+
prevFilter: CompositeFilterDescriptor;
|
|
1238
|
+
nextFilter: CompositeFilterDescriptor;
|
|
1239
|
+
}
|
|
1240
|
+
|
|
1241
|
+
/**
|
|
1242
|
+
* @hidden
|
|
1243
|
+
*/
|
|
1244
|
+
export declare interface GroupProps {
|
|
1245
|
+
filter: CompositeFilterDescriptor;
|
|
1246
|
+
fields: Array<FieldSettings>;
|
|
1247
|
+
ariaLabel?: string;
|
|
1248
|
+
ariaLabelExpression?: string;
|
|
1249
|
+
onChange: (event: GroupChangeEvent) => void;
|
|
1250
|
+
onRemove: (event: GroupRemoveEvent) => void;
|
|
1251
|
+
defaultGroupFilter: CompositeFilterDescriptor;
|
|
1252
|
+
}
|
|
1253
|
+
|
|
1254
|
+
/**
|
|
1255
|
+
* @hidden
|
|
1256
|
+
*/
|
|
1257
|
+
export declare interface GroupRemoveEvent extends BaseEvent<Group> {
|
|
1258
|
+
filter: CompositeFilterDescriptor;
|
|
1259
|
+
}
|
|
1260
|
+
|
|
1261
|
+
/**
|
|
1262
|
+
* @hidden
|
|
1263
|
+
*/
|
|
1264
|
+
declare type handler = (prevIndex: number, nextIndex: number, nativeEvent: any) => void;
|
|
1265
|
+
|
|
1266
|
+
/**
|
|
1267
|
+
* @hidden
|
|
1268
|
+
*/
|
|
1269
|
+
export declare class Header extends React_2.Component<HeaderProps> {
|
|
1270
|
+
private element;
|
|
1271
|
+
componentDidMount(): void;
|
|
1272
|
+
render(): JSX_2.Element;
|
|
1273
|
+
}
|
|
1274
|
+
|
|
1275
|
+
/**
|
|
1276
|
+
* @hidden
|
|
1277
|
+
*/
|
|
1278
|
+
export declare function HeaderCell(props: HeaderCellProps): JSX_2.Element;
|
|
1279
|
+
|
|
1280
|
+
/**
|
|
1281
|
+
* @hidden
|
|
1282
|
+
*/
|
|
1283
|
+
export declare interface HeaderCellBaseProps {
|
|
1284
|
+
/**
|
|
1285
|
+
* The column field in which the cell is located.
|
|
1286
|
+
*/
|
|
1287
|
+
field?: string;
|
|
1288
|
+
/**
|
|
1289
|
+
* The title of the column in which the cell is located.
|
|
1290
|
+
*/
|
|
1291
|
+
title?: string;
|
|
1292
|
+
/**
|
|
1293
|
+
* The `click` event handler of the cell.
|
|
1294
|
+
*/
|
|
1295
|
+
onClick?: any;
|
|
1296
|
+
/**
|
|
1297
|
+
* The `selectionChange` event handler of the cell.
|
|
1298
|
+
*/
|
|
1299
|
+
selectionChange: any;
|
|
1300
|
+
/**
|
|
1301
|
+
* The `selectionValue` event handler of the column in which the cell is located.
|
|
1302
|
+
*/
|
|
1303
|
+
selectionValue: any;
|
|
1304
|
+
/**
|
|
1305
|
+
* A function for overriding the default rendering of the header cell.
|
|
1306
|
+
*/
|
|
1307
|
+
render?: (defaultRendering: React_2.ReactNode | null, props: HeaderCellBaseProps) => React_2.ReactNode;
|
|
1308
|
+
/**
|
|
1309
|
+
* The current sort icons.
|
|
1310
|
+
*/
|
|
1311
|
+
children: React_2.ReactNode;
|
|
1312
|
+
}
|
|
1313
|
+
|
|
1314
|
+
/**
|
|
1315
|
+
* @hidden
|
|
1316
|
+
*/
|
|
1317
|
+
export declare interface HeaderCellProps extends HeaderCellBaseProps {
|
|
1318
|
+
/**
|
|
1319
|
+
* A function for overriding the default rendering of the header cell.
|
|
1320
|
+
*/
|
|
1321
|
+
render?: (defaultRendering: React_2.ReactNode | null, props: HeaderCellProps) => React_2.ReactNode;
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
/**
|
|
1325
|
+
* @hidden
|
|
1326
|
+
*/
|
|
1327
|
+
export declare interface HeaderProps {
|
|
1328
|
+
headerRow: React_2.ReactElement<any>;
|
|
1329
|
+
filterRow?: React_2.ReactElement<any>;
|
|
1330
|
+
columnResize?: ColumnResize;
|
|
1331
|
+
}
|
|
1332
|
+
|
|
1333
|
+
/**
|
|
1334
|
+
* @hidden
|
|
1335
|
+
*/
|
|
1336
|
+
export declare class HeaderRow<C = CellProps, H = HeaderCellProps, F = FilterCellProps> extends React_2.Component<HeaderRowProps<C, H, F>, {}> {
|
|
1337
|
+
cellClick: (e: React_2.MouseEvent<HTMLSpanElement> | React_2.KeyboardEvent<HTMLElement>, column: TreeColumnBaseProps<C, H, F>) => void;
|
|
1338
|
+
cellKeyDown: (event: React_2.KeyboardEvent<HTMLElement>, column: TreeColumnBaseProps<C, H, F>) => void;
|
|
1339
|
+
sortIcon(sortIndex: number): (false | JSX_2.Element)[] | null;
|
|
1340
|
+
render(): JSX_2.Element[];
|
|
1341
|
+
private cells;
|
|
1342
|
+
}
|
|
1343
|
+
|
|
1344
|
+
/**
|
|
1345
|
+
* @hidden
|
|
1346
|
+
*/
|
|
1347
|
+
export declare interface HeaderRowProps<C = CellProps, H = HeaderCellProps, F = FilterCellProps> extends ColumnDraggableProps {
|
|
1348
|
+
sortable?: SortSettings;
|
|
1349
|
+
sortChange?: (e: React_2.SyntheticEvent<any>, descriptors: SortDescriptor[], field?: string) => void;
|
|
1350
|
+
filterChange?: (e: React_2.SyntheticEvent<any>, descriptors: FilterDescriptor[], field?: string) => void;
|
|
1351
|
+
sort?: SortDescriptor[];
|
|
1352
|
+
columns: ExtendedColumnProps<C, H, F>[];
|
|
1353
|
+
columnsMap: number[][];
|
|
1354
|
+
selectionChange: (e: any) => void;
|
|
1355
|
+
cellRender?: (defaultRendering: React_2.ReactNode | null, props: HeaderCellProps) => React_2.ReactNode;
|
|
1356
|
+
columnResize?: ColumnResize<C, H, F>;
|
|
1357
|
+
columnMenu?: React_2.ComponentType<ColumnMenuProps>;
|
|
1358
|
+
columnMenuFilter?: CompositeFilterDescriptor[];
|
|
1359
|
+
columnMenuFilterChange?: (e: React_2.SyntheticEvent<any>, filter: CompositeFilterDescriptor[], field?: string) => void;
|
|
1360
|
+
}
|
|
1361
|
+
|
|
1362
|
+
/**
|
|
1363
|
+
* @hidden
|
|
1364
|
+
*/
|
|
1365
|
+
export declare function HeaderSelectionCell(props: HeaderSelectionCellProps): JSX_2.Element;
|
|
1366
|
+
|
|
1367
|
+
/**
|
|
1368
|
+
* @hidden
|
|
1369
|
+
*/
|
|
1370
|
+
export declare interface HeaderSelectionCellProps extends HeaderCellProps {
|
|
1371
|
+
inputId: string;
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
/**
|
|
1375
|
+
* @hidden
|
|
1376
|
+
*/
|
|
1377
|
+
export declare const HeaderThElement: {
|
|
1378
|
+
(props: {
|
|
1379
|
+
ariaSort?: 'none' | 'ascending' | 'descending';
|
|
1380
|
+
ariaLabel?: string;
|
|
1381
|
+
ariaColumnIndex?: number;
|
|
1382
|
+
ariaSelected?: boolean;
|
|
1383
|
+
ariaDescription?: string;
|
|
1384
|
+
colSpan?: number;
|
|
1385
|
+
rowSpan?: number;
|
|
1386
|
+
role?: string;
|
|
1387
|
+
columnId: string;
|
|
1388
|
+
className?: string;
|
|
1389
|
+
style?: any;
|
|
1390
|
+
children: any;
|
|
1391
|
+
onKeyDown?: any;
|
|
1392
|
+
navigatable?: boolean;
|
|
1393
|
+
}): JSX_2.Element;
|
|
1394
|
+
displayName: string;
|
|
1395
|
+
};
|
|
1396
|
+
|
|
1397
|
+
/**
|
|
1398
|
+
* @hidden
|
|
1399
|
+
*/
|
|
1400
|
+
export declare function isRtl(element: HTMLElement | null): boolean;
|
|
1401
|
+
|
|
1402
|
+
/**
|
|
1403
|
+
* @hidden
|
|
1404
|
+
*/
|
|
1405
|
+
export declare const KEYBOARD_NAV_DATA_BODY = "data-keyboardnavbody";
|
|
1406
|
+
|
|
1407
|
+
/**
|
|
1408
|
+
* @hidden
|
|
1409
|
+
*/
|
|
1410
|
+
export declare const KEYBOARD_NAV_DATA_HEADER = "data-keyboardnavheader";
|
|
1411
|
+
|
|
1412
|
+
/**
|
|
1413
|
+
* @hidden
|
|
1414
|
+
*/
|
|
1415
|
+
export declare const KEYBOARD_NAV_DATA_ID = "data-keyboardnavid";
|
|
1416
|
+
|
|
1417
|
+
/**
|
|
1418
|
+
* @hidden
|
|
1419
|
+
*/
|
|
1420
|
+
export declare const KEYBOARD_NAV_DATA_LEVEL = "data-keyboardnavlevel";
|
|
1421
|
+
|
|
1422
|
+
/**
|
|
1423
|
+
* @hidden
|
|
1424
|
+
*/
|
|
1425
|
+
export declare const KEYBOARD_NAV_DATA_SCOPE = "data-keyboardnavscope";
|
|
1426
|
+
|
|
1427
|
+
/**
|
|
1428
|
+
* @hidden
|
|
1429
|
+
*/
|
|
1430
|
+
export declare const KEYBOARD_NAV_DATA_ZONE = "data-keyboardnavzone";
|
|
1431
|
+
|
|
1432
|
+
/**
|
|
1433
|
+
* @hidden
|
|
1434
|
+
*/
|
|
1435
|
+
export declare const KEYBOARD_NAV_FILTER_COL_SUFFIX = "_filter";
|
|
1436
|
+
|
|
1437
|
+
/**
|
|
1438
|
+
* @hidden
|
|
1439
|
+
*/
|
|
1440
|
+
export declare function mapColumns(columns: Array<{
|
|
1441
|
+
parentIndex: number;
|
|
1442
|
+
colSpan: number;
|
|
1443
|
+
rowSpan: number;
|
|
1444
|
+
depth: number;
|
|
1445
|
+
kFirst?: boolean;
|
|
1446
|
+
children: any[];
|
|
1447
|
+
width?: string | number;
|
|
1448
|
+
locked?: boolean;
|
|
1449
|
+
index: number;
|
|
1450
|
+
left: number;
|
|
1451
|
+
right: number;
|
|
1452
|
+
rightBorder: boolean;
|
|
1453
|
+
ariaColumnIndex: number;
|
|
1454
|
+
}>): number[][];
|
|
1455
|
+
|
|
1456
|
+
/**
|
|
1457
|
+
* Changes the `subItems` collection of each data item which matches the passed `condition`.
|
|
1458
|
+
*
|
|
1459
|
+
* @param {any[]} data - The data tree.
|
|
1460
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
1461
|
+
* @param {(item: object) => Boolean} condition - A function that will be executed for each data item and
|
|
1462
|
+
* will return `true` for items that have to change the subitems collection.
|
|
1463
|
+
* @param {(subItems: object[]) => object[]} change - A function which
|
|
1464
|
+
* has as a parameter the subitems collection of the matched items and which will return the new subitems collection.
|
|
1465
|
+
* @returns {any[]} - The new data tree.
|
|
1466
|
+
*/
|
|
1467
|
+
export declare const modifySubItems: (data: any[], subItemsField: string, condition: (item: any) => boolean, change: (subItems: any[]) => any[]) => any[];
|
|
1468
|
+
|
|
1469
|
+
/**
|
|
1470
|
+
* Moves the targeted item in the tree to another position.
|
|
1471
|
+
*
|
|
1472
|
+
* @param {any[]} data - The data tree.
|
|
1473
|
+
* @param {number[]} target - The level of the target tree item which will be moved.
|
|
1474
|
+
* @param {number[] | null} destination - The level of the destination tree item where the target item will be moved in.
|
|
1475
|
+
* If it is null, the target item will be added at the root level.
|
|
1476
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
1477
|
+
* @returns {any[]} - The new data tree.
|
|
1478
|
+
*/
|
|
1479
|
+
export declare const moveTreeItem: (data: any[], target: number[], destination: number[] | null, subItemsField: string) => any[];
|
|
1480
|
+
|
|
1481
|
+
/**
|
|
1482
|
+
* @hidden
|
|
1483
|
+
*/
|
|
1484
|
+
export declare function nextColumn(columns: {
|
|
1485
|
+
depth: number;
|
|
1486
|
+
locked?: boolean;
|
|
1487
|
+
}[], current: number): {
|
|
1488
|
+
depth: number;
|
|
1489
|
+
locked?: boolean | undefined;
|
|
1490
|
+
} | null;
|
|
1491
|
+
|
|
1492
|
+
/**
|
|
1493
|
+
* @hidden
|
|
1494
|
+
*/
|
|
1495
|
+
export declare const normalize: (...settings: (SortSettings | ColumnSortSettings)[]) => any;
|
|
1496
|
+
|
|
1497
|
+
/**
|
|
1498
|
+
* The NumericFilter component used for editing numeric value of FilterDescriptor object.
|
|
1499
|
+
*/
|
|
1500
|
+
export declare class NumericFilter extends React_2.Component<NumericFilterProps> {
|
|
1501
|
+
/**
|
|
1502
|
+
* @hidden
|
|
1503
|
+
*/
|
|
1504
|
+
static propTypes: {
|
|
1505
|
+
filter: PropTypes.Validator<object>;
|
|
1506
|
+
onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
1507
|
+
};
|
|
1508
|
+
/**
|
|
1509
|
+
* @hidden
|
|
1510
|
+
*/
|
|
1511
|
+
render(): JSX_2.Element;
|
|
1512
|
+
private onChange;
|
|
1513
|
+
}
|
|
1514
|
+
|
|
1515
|
+
/**
|
|
1516
|
+
* @hidden
|
|
1517
|
+
*/
|
|
1518
|
+
export declare class NumericFilterCell extends NumericFilterCell_base {
|
|
1519
|
+
}
|
|
1520
|
+
|
|
1521
|
+
declare const NumericFilterCell_base: React_2.ComponentClass<FilterComponentProps, any>;
|
|
1522
|
+
|
|
1523
|
+
/**
|
|
1524
|
+
* The props of the NumericFilter component.
|
|
1525
|
+
*/
|
|
1526
|
+
export declare interface NumericFilterProps extends TextFilterProps {
|
|
1527
|
+
/**
|
|
1528
|
+
* Specifies the smallest value that can be entered.
|
|
1529
|
+
*/
|
|
1530
|
+
min?: number;
|
|
1531
|
+
/**
|
|
1532
|
+
* Specifies the greatest value that can be entered.
|
|
1533
|
+
*/
|
|
1534
|
+
max?: number;
|
|
1535
|
+
}
|
|
1536
|
+
|
|
1537
|
+
/**
|
|
1538
|
+
* Represents the operators for the TextFilter, NumericFilter, DateFilter and BooleanFilter components.
|
|
1539
|
+
*
|
|
1540
|
+
* The text field of each operator object will be resolved according to the
|
|
1541
|
+
* [localization messages]({% slug globalization_datatools %}#toc-messages).
|
|
1542
|
+
*/
|
|
1543
|
+
export declare class Operators {
|
|
1544
|
+
/**
|
|
1545
|
+
* An array containing the operators for the TextFilter component.
|
|
1546
|
+
*
|
|
1547
|
+
* The operators are:
|
|
1548
|
+
*
|
|
1549
|
+
* - { text: 'filter.containsOperator', operator: 'contains' }
|
|
1550
|
+
* - { text: 'filter.notContainsOperator', operator: 'doesnotcontain' }
|
|
1551
|
+
* - { text: 'filter.eqOperator', operator: 'eq' }
|
|
1552
|
+
* - { text: 'filter.notEqOperator', operator: 'neq' }
|
|
1553
|
+
* - { text: 'filter.startsWithOperator', operator: 'startswith' }
|
|
1554
|
+
* - { text: 'filter.endsWithOperator', operator: 'endswith' }
|
|
1555
|
+
* - { text: 'filter.isNullOperator', operator: 'isnull' }
|
|
1556
|
+
* - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
|
|
1557
|
+
* - { text: 'filter.isEmptyOperator', operator: 'isempty' }
|
|
1558
|
+
* - { text: 'filter.isNotEmptyOperator', operator: 'isnotempty' }
|
|
1559
|
+
*/
|
|
1560
|
+
static get text(): FilterOperator[];
|
|
1561
|
+
/**
|
|
1562
|
+
* An array containing the operators for the NumericFilter component.
|
|
1563
|
+
*
|
|
1564
|
+
* The operators are:
|
|
1565
|
+
*
|
|
1566
|
+
* - { text: 'filter.eqOperator', operator: 'eq' }
|
|
1567
|
+
* - { text: 'filter.notEqOperator', operator: 'neq' }
|
|
1568
|
+
* - { text: 'filter.gteOperator', operator: 'gte' }
|
|
1569
|
+
* - { text: 'filter.gtOperator', operator: 'gt' }
|
|
1570
|
+
* - { text: 'filter.lteOperator', operator: 'lte' }
|
|
1571
|
+
* - { text: 'filter.ltOperator', operator: 'lt' }
|
|
1572
|
+
* - { text: 'filter.isNullOperator', operator: 'isnull' }
|
|
1573
|
+
* - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
|
|
1574
|
+
*/
|
|
1575
|
+
static get numeric(): FilterOperator[];
|
|
1576
|
+
/**
|
|
1577
|
+
* An array containing the operators for the DateFilter component.
|
|
1578
|
+
*
|
|
1579
|
+
* The operators are:
|
|
1580
|
+
*
|
|
1581
|
+
* - { text: 'filter.eqOperator', operator: 'eq' }
|
|
1582
|
+
* - { text: 'filter.notEqOperator', operator: 'neq' }
|
|
1583
|
+
* - { text: 'filter.afterOrEqualOperator', operator: 'gte' }
|
|
1584
|
+
* - { text: 'filter.afterOperator', operator: 'gt' }
|
|
1585
|
+
* - { text: 'filter.beforeOperator', operator: 'lt' }
|
|
1586
|
+
* - { text: 'filter.beforeOrEqualOperator', operator: 'lte' }
|
|
1587
|
+
* - { text: 'filter.isNullOperator', operator: 'isnull' }
|
|
1588
|
+
* - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
|
|
1589
|
+
*/
|
|
1590
|
+
static get date(): FilterOperator[];
|
|
1591
|
+
/**
|
|
1592
|
+
* An array containing the operators for the BooleanFilter component.
|
|
1593
|
+
*
|
|
1594
|
+
* The operators are:
|
|
1595
|
+
*
|
|
1596
|
+
* - { text: 'filter.eqOperator', operator: 'eq' }
|
|
1597
|
+
* - { text: 'filter.notEqOperator', operator: 'neq' }
|
|
1598
|
+
*/
|
|
1599
|
+
static get boolean(): FilterOperator[];
|
|
1600
|
+
}
|
|
1601
|
+
|
|
1602
|
+
/**
|
|
1603
|
+
* Orders the specified tree according to the provided sort descriptors.
|
|
1604
|
+
*
|
|
1605
|
+
* @param {T[]} data - The data that will be sorted.
|
|
1606
|
+
* @param {SortDescriptor[]} descriptors - The descriptors by which the data will be sorted.
|
|
1607
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
1608
|
+
* @returns {T[]} - The sorted data.
|
|
1609
|
+
*/
|
|
1610
|
+
export declare function orderBy(data: any[], descriptors: SortDescriptor[], subItemsField: string): any[];
|
|
1611
|
+
|
|
1612
|
+
/**
|
|
1613
|
+
* Represents the object of the `onPageChange` event.
|
|
1614
|
+
*/
|
|
1615
|
+
export declare interface PageChangeEvent extends BasePageChangeEvent {
|
|
1616
|
+
/**
|
|
1617
|
+
* An event target.
|
|
1618
|
+
*/
|
|
1619
|
+
target: Pager;
|
|
1620
|
+
/**
|
|
1621
|
+
* A React Synthetic Event.
|
|
1622
|
+
*/
|
|
1623
|
+
syntheticEvent: React_2.SyntheticEvent<any>;
|
|
1624
|
+
/**
|
|
1625
|
+
* A native DOM event.
|
|
1626
|
+
*/
|
|
1627
|
+
nativeEvent: any;
|
|
1628
|
+
/**
|
|
1629
|
+
* A target change event.
|
|
1630
|
+
*/
|
|
1631
|
+
targetEvent: PagerTargetEvent;
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1634
|
+
export declare class Pager extends React_2.Component<PagerProps, PagerState> {
|
|
1635
|
+
/**
|
|
1636
|
+
* @hidden
|
|
1637
|
+
*/
|
|
1638
|
+
static propTypes: {
|
|
1639
|
+
className: PropTypes.Requireable<string>;
|
|
1640
|
+
style: PropTypes.Requireable<object>;
|
|
1641
|
+
total: PropTypes.Validator<number>;
|
|
1642
|
+
skip: PropTypes.Validator<number>;
|
|
1643
|
+
take: PropTypes.Validator<number>;
|
|
1644
|
+
buttonCount: PropTypes.Requireable<number>;
|
|
1645
|
+
info: PropTypes.Requireable<boolean>;
|
|
1646
|
+
type: PropTypes.Requireable<string>;
|
|
1647
|
+
pageSizes: PropTypes.Requireable<(NonNullable<string | number | null | undefined> | null | undefined)[]>;
|
|
1648
|
+
previousNext: PropTypes.Requireable<boolean>;
|
|
1649
|
+
onPageChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
1650
|
+
messagesMap: PropTypes.Requireable<(...args: any[]) => any>;
|
|
1651
|
+
size: PropTypes.Requireable<string | null>;
|
|
1652
|
+
dir: PropTypes.Requireable<string>;
|
|
1653
|
+
};
|
|
1654
|
+
/**
|
|
1655
|
+
* @hidden
|
|
1656
|
+
*/
|
|
1657
|
+
static defaultProps: {
|
|
1658
|
+
buttonCount: number;
|
|
1659
|
+
info: boolean;
|
|
1660
|
+
type: string;
|
|
1661
|
+
size: string;
|
|
1662
|
+
};
|
|
1663
|
+
private _element;
|
|
1664
|
+
private get isRtl();
|
|
1665
|
+
/**
|
|
1666
|
+
* Returns the HTML element of the Pager component.
|
|
1667
|
+
*/
|
|
1668
|
+
get element(): HTMLDivElement | null;
|
|
1669
|
+
constructor(props: PagerProps);
|
|
1670
|
+
/**
|
|
1671
|
+
* @hidden
|
|
1672
|
+
*/
|
|
1673
|
+
componentDidMount(): void;
|
|
1674
|
+
/**
|
|
1675
|
+
* @hidden
|
|
1676
|
+
*/
|
|
1677
|
+
componentWillUnmount(): void;
|
|
1678
|
+
/**
|
|
1679
|
+
* @hidden
|
|
1680
|
+
*/
|
|
1681
|
+
render(): JSX_2.Element;
|
|
1682
|
+
private onPageChange;
|
|
1683
|
+
private renderButton;
|
|
1684
|
+
private get totalPages();
|
|
1685
|
+
private changePage;
|
|
1686
|
+
private onWindowResize;
|
|
1687
|
+
}
|
|
1688
|
+
|
|
1689
|
+
export declare interface PagerProps {
|
|
1690
|
+
/**
|
|
1691
|
+
* The total number of records.
|
|
1692
|
+
*/
|
|
1693
|
+
total: number;
|
|
1694
|
+
/**
|
|
1695
|
+
* The number of records that will be skipped.
|
|
1696
|
+
*/
|
|
1697
|
+
skip: number;
|
|
1698
|
+
/**
|
|
1699
|
+
* The number of records that will be taken.
|
|
1700
|
+
*/
|
|
1701
|
+
take: number;
|
|
1702
|
+
/**
|
|
1703
|
+
* Sets additional classes to the Pager.
|
|
1704
|
+
*/
|
|
1705
|
+
className?: string;
|
|
1706
|
+
/**
|
|
1707
|
+
* The styles that are applied to the Pager.
|
|
1708
|
+
*/
|
|
1709
|
+
style?: React_2.CSSProperties;
|
|
1710
|
+
/**
|
|
1711
|
+
* Sets the maximum numeric buttons count before the buttons are collapsed.
|
|
1712
|
+
*/
|
|
1713
|
+
buttonCount?: number;
|
|
1714
|
+
/**
|
|
1715
|
+
* Toggles the information about the current page and the total number of records.
|
|
1716
|
+
*/
|
|
1717
|
+
info?: boolean;
|
|
1718
|
+
/**
|
|
1719
|
+
* Defines the type of the pager.
|
|
1720
|
+
* * (Default) `numeric` — Renders buttons with numbers.
|
|
1721
|
+
* * `input` — Renders an input field for typing the page number.
|
|
1722
|
+
*/
|
|
1723
|
+
type?: 'numeric' | 'input';
|
|
1724
|
+
/**
|
|
1725
|
+
* Displays a menu for selecting the page size.
|
|
1726
|
+
*/
|
|
1727
|
+
pageSizes?: Array<number> | Array<number | string>;
|
|
1728
|
+
/**
|
|
1729
|
+
* Sets the selected value of the page size Dropdownlist.
|
|
1730
|
+
* It is useful when the selected value could also be a string not only a number.
|
|
1731
|
+
*/
|
|
1732
|
+
pageSizeValue?: string | number;
|
|
1733
|
+
/**
|
|
1734
|
+
* Toggles the **Previous** and **Next** buttons.
|
|
1735
|
+
*/
|
|
1736
|
+
previousNext?: boolean;
|
|
1737
|
+
/**
|
|
1738
|
+
* Defines if the pager will be responsive. Defaults to `true`.
|
|
1739
|
+
*/
|
|
1740
|
+
responsive?: boolean;
|
|
1741
|
+
/**
|
|
1742
|
+
* Configures the `size` of the Pager.
|
|
1743
|
+
*
|
|
1744
|
+
* The available options are:
|
|
1745
|
+
* - small
|
|
1746
|
+
* - medium
|
|
1747
|
+
* - large
|
|
1748
|
+
* - null—Does not set a size `className`.
|
|
1749
|
+
*
|
|
1750
|
+
* @default `medium`
|
|
1751
|
+
*/
|
|
1752
|
+
size?: null | 'small' | 'medium' | 'large';
|
|
1753
|
+
/**
|
|
1754
|
+
* Fires when the page of the Pager is changed. You have to handle the event yourself and page the data.
|
|
1755
|
+
*/
|
|
1756
|
+
onPageChange?: ((event: PageChangeEvent) => void) | ((event: BasePageChangeEvent) => void);
|
|
1757
|
+
/**
|
|
1758
|
+
* Useful for modifying the Pager messages.
|
|
1759
|
+
*/
|
|
1760
|
+
messagesMap?: (messageKey: string) => ({
|
|
1761
|
+
messageKey: string;
|
|
1762
|
+
defaultMessage: string;
|
|
1763
|
+
});
|
|
1764
|
+
/**
|
|
1765
|
+
* Sets the direction of the component.
|
|
1766
|
+
*/
|
|
1767
|
+
dir?: string;
|
|
1768
|
+
}
|
|
1769
|
+
|
|
1770
|
+
/**
|
|
1771
|
+
* @hidden
|
|
1772
|
+
*/
|
|
1773
|
+
declare interface PagerState {
|
|
1774
|
+
showPagerSizes?: boolean;
|
|
1775
|
+
showPagerInfo?: boolean;
|
|
1776
|
+
}
|
|
1777
|
+
|
|
1778
|
+
/**
|
|
1779
|
+
* A Pager target event.
|
|
1780
|
+
*/
|
|
1781
|
+
export declare interface PagerTargetEvent {
|
|
1782
|
+
[key: string]: any;
|
|
1783
|
+
/**
|
|
1784
|
+
* An event target.
|
|
1785
|
+
*/
|
|
1786
|
+
target?: any;
|
|
1787
|
+
/**
|
|
1788
|
+
* An event value.
|
|
1789
|
+
*/
|
|
1790
|
+
value?: any;
|
|
1791
|
+
}
|
|
1792
|
+
|
|
1793
|
+
/**
|
|
1794
|
+
* Represents the `PopulateClipboardArgs` event argument.
|
|
1795
|
+
*/
|
|
1796
|
+
export declare interface PopulateClipboardArgs {
|
|
1797
|
+
/**
|
|
1798
|
+
* Represents the object of the `onClipboardData` event.
|
|
1799
|
+
*/
|
|
1800
|
+
event: ClipboardDataEvent;
|
|
1801
|
+
/**
|
|
1802
|
+
* Represents the current selected state of the data.
|
|
1803
|
+
*/
|
|
1804
|
+
selectedState: {
|
|
1805
|
+
[key: string | number]: boolean | number[];
|
|
1806
|
+
};
|
|
1807
|
+
/**
|
|
1808
|
+
* Passes the data currently displayed.
|
|
1809
|
+
*/
|
|
1810
|
+
data: any[];
|
|
1811
|
+
/**
|
|
1812
|
+
* Passes dataItemKey name of the field that could be used to make difference between dataItems.
|
|
1813
|
+
*/
|
|
1814
|
+
dataItemKey?: string;
|
|
1815
|
+
/**
|
|
1816
|
+
* Passes subItemsField that will be used in grouping cases.
|
|
1817
|
+
*/
|
|
1818
|
+
subItemsField?: string;
|
|
1819
|
+
}
|
|
1820
|
+
|
|
1821
|
+
/**
|
|
1822
|
+
* A function used to populate the Clipboard data.
|
|
1823
|
+
*/
|
|
1824
|
+
export declare const populateClipboardData: (args: PopulateClipboardArgs) => ClipboardData;
|
|
1825
|
+
|
|
1826
|
+
/**
|
|
1827
|
+
* @hidden
|
|
1828
|
+
*/
|
|
1829
|
+
export declare function readColumns<C = CellProps, H = HeaderCellProps, F = FilterCellProps>(elements: TreeColumnBaseProps<C, H, F>[], idInfo: {
|
|
1830
|
+
prevId: number;
|
|
1831
|
+
idPrefix: string;
|
|
1832
|
+
}, depth?: number): ExtendedColumnProps<C, H, F>[];
|
|
1833
|
+
|
|
1834
|
+
/** @hidden */
|
|
1835
|
+
export declare const relativeContextElement: (element: any) => any;
|
|
1836
|
+
|
|
1837
|
+
/**
|
|
1838
|
+
* Removes the items from the passed `data` which match the passed `condition`.
|
|
1839
|
+
*
|
|
1840
|
+
* @param {any[]} data - The data tree.
|
|
1841
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
1842
|
+
* @param {(item: object) => Boolean} condition - A function that will be executed for each data item
|
|
1843
|
+
* in the tree data and the items for which returns true will be removed.
|
|
1844
|
+
* @returns {any[]} - The new data tree.
|
|
1845
|
+
*/
|
|
1846
|
+
export declare const removeItems: (data: any[], subItemsField: string, condition: (item: any) => boolean) => any[];
|
|
1847
|
+
|
|
1848
|
+
/**
|
|
1849
|
+
* Apply the `expanded` prop to the group items in data based on the provided collection of group ids.
|
|
1850
|
+
*
|
|
1851
|
+
* @param {{data: any[], collapsedIds: string[]}} options - The options to be processed.
|
|
1852
|
+
* @returns {string[]} - Collection of all group ids from the data.
|
|
1853
|
+
*/
|
|
1854
|
+
export declare const setExpandedState: (options: {
|
|
1855
|
+
data: any;
|
|
1856
|
+
collapsedIds: string[];
|
|
1857
|
+
}) => any[];
|
|
1858
|
+
|
|
1859
|
+
/**
|
|
1860
|
+
* Add unique ids to the group items inside data.
|
|
1861
|
+
*
|
|
1862
|
+
* @param {{data: any[], group: GroupDescriptor[]}} options - The options to be processed.
|
|
1863
|
+
*/
|
|
1864
|
+
export declare const setGroupIds: (options: {
|
|
1865
|
+
data: any;
|
|
1866
|
+
group?: Array<GroupDescriptor>;
|
|
1867
|
+
}) => void;
|
|
1868
|
+
|
|
1869
|
+
/**
|
|
1870
|
+
* @hidden
|
|
1871
|
+
*
|
|
1872
|
+
* Apply the selected field to the data items based on the selected state.
|
|
1873
|
+
*
|
|
1874
|
+
* @param {{data: any, selectedState: {[id: string]: boolean | number[]}, dataItemKey: string; selectedField: string; subItemsField?: string; }} options
|
|
1875
|
+
* @returns {any[]}
|
|
1876
|
+
*/
|
|
1877
|
+
export declare const setSelectedState: (options: {
|
|
1878
|
+
data: any;
|
|
1879
|
+
selectedState: {
|
|
1880
|
+
[id: string]: boolean | number[];
|
|
1881
|
+
};
|
|
1882
|
+
dataItemKey: string;
|
|
1883
|
+
selectedField: string;
|
|
1884
|
+
subItemsField?: string | undefined;
|
|
1885
|
+
}) => any[];
|
|
1886
|
+
|
|
1887
|
+
/**
|
|
1888
|
+
* The settings for sorting the component data.
|
|
1889
|
+
*/
|
|
1890
|
+
export declare type SortSettings = boolean | ColumnSortSettings & {
|
|
1891
|
+
/**
|
|
1892
|
+
* The sort mode of the component.
|
|
1893
|
+
*
|
|
1894
|
+
* The available modes are:
|
|
1895
|
+
* - `single`
|
|
1896
|
+
* - `multiple`
|
|
1897
|
+
*/
|
|
1898
|
+
mode?: 'single' | 'multiple';
|
|
1899
|
+
};
|
|
1900
|
+
|
|
1901
|
+
/**
|
|
1902
|
+
* @hidden
|
|
1903
|
+
*/
|
|
1904
|
+
export declare const stringOperator: (operator: any) => boolean;
|
|
1905
|
+
|
|
1906
|
+
/**
|
|
1907
|
+
* @hidden
|
|
1908
|
+
*/
|
|
1909
|
+
export declare const TABBABLE_ELEMENTS: string[];
|
|
1910
|
+
|
|
1911
|
+
/** @hidden */
|
|
1912
|
+
export declare const TABLE_COL_INDEX_ATTRIBUTE = "data-grid-col-index";
|
|
1913
|
+
|
|
1914
|
+
/** @hidden */
|
|
1915
|
+
export declare const TABLE_PREVENT_SELECTION_ELEMENT = "data-prevent-selection";
|
|
1916
|
+
|
|
1917
|
+
/** @hidden */
|
|
1918
|
+
export declare const TABLE_ROW_INDEX_ATTRIBUTE = "data-grid-row-index";
|
|
1919
|
+
|
|
1920
|
+
/**
|
|
1921
|
+
* @hidden
|
|
1922
|
+
*/
|
|
1923
|
+
export declare function tableColumnsVirtualization(args: {
|
|
1924
|
+
enabled?: boolean;
|
|
1925
|
+
columns: {
|
|
1926
|
+
width?: string | number;
|
|
1927
|
+
locked?: boolean;
|
|
1928
|
+
}[];
|
|
1929
|
+
tableViewPortWidth: number;
|
|
1930
|
+
scrollLeft: number;
|
|
1931
|
+
}): {
|
|
1932
|
+
colSpans: number[];
|
|
1933
|
+
hiddenColumns: boolean[];
|
|
1934
|
+
};
|
|
1935
|
+
|
|
1936
|
+
/** @hidden */
|
|
1937
|
+
export declare interface TableDragSelectionReleaseEvent {
|
|
1938
|
+
/**
|
|
1939
|
+
* Selection start row index.
|
|
1940
|
+
*/
|
|
1941
|
+
startRowIndex: number;
|
|
1942
|
+
/**
|
|
1943
|
+
* Selection start column index.
|
|
1944
|
+
*/
|
|
1945
|
+
startColIndex: number;
|
|
1946
|
+
/**
|
|
1947
|
+
* Selection end row index.
|
|
1948
|
+
*/
|
|
1949
|
+
endRowIndex: number;
|
|
1950
|
+
/**
|
|
1951
|
+
* Selection end column index.
|
|
1952
|
+
*/
|
|
1953
|
+
endColIndex: number;
|
|
1954
|
+
/**
|
|
1955
|
+
* A native DOM event.
|
|
1956
|
+
*/
|
|
1957
|
+
nativeEvent: any;
|
|
1958
|
+
/**
|
|
1959
|
+
* Is ctrl key modifier pressed.
|
|
1960
|
+
*/
|
|
1961
|
+
ctrlKey: boolean;
|
|
1962
|
+
/**
|
|
1963
|
+
* Is alt key modifier pressed.
|
|
1964
|
+
*/
|
|
1965
|
+
altKey: boolean;
|
|
1966
|
+
/**
|
|
1967
|
+
* Is meta key modifier pressed.
|
|
1968
|
+
*/
|
|
1969
|
+
metaKey: boolean;
|
|
1970
|
+
/**
|
|
1971
|
+
* Is shift key modifier pressed.
|
|
1972
|
+
*/
|
|
1973
|
+
shiftKey: boolean;
|
|
1974
|
+
/**
|
|
1975
|
+
* Selection mode.
|
|
1976
|
+
*/
|
|
1977
|
+
mode: 'single' | 'multiple';
|
|
1978
|
+
/**
|
|
1979
|
+
* Indicates if cell selection mode is enabled.
|
|
1980
|
+
*/
|
|
1981
|
+
cell: boolean;
|
|
1982
|
+
/**
|
|
1983
|
+
* Indicates if current event is created from drag.
|
|
1984
|
+
*/
|
|
1985
|
+
isDrag: boolean;
|
|
1986
|
+
}
|
|
1987
|
+
|
|
1988
|
+
/**
|
|
1989
|
+
* @hidden
|
|
1990
|
+
*/
|
|
1991
|
+
export declare const tableKeyboardNavigation: {
|
|
1992
|
+
onConstructor: (options: {
|
|
1993
|
+
navigatable: boolean | undefined;
|
|
1994
|
+
contextStateRef: {
|
|
1995
|
+
current?: TableKeyboardNavigationContextType;
|
|
1996
|
+
};
|
|
1997
|
+
navigationStateRef: {
|
|
1998
|
+
current?: TableKeyboardNavigationStateType;
|
|
1999
|
+
};
|
|
2000
|
+
idPrefix?: string;
|
|
2001
|
+
}) => void;
|
|
2002
|
+
onComponentDidMount: (options: {
|
|
2003
|
+
scope?: HTMLElement;
|
|
2004
|
+
contextStateRef: {
|
|
2005
|
+
current?: TableKeyboardNavigationContextType;
|
|
2006
|
+
};
|
|
2007
|
+
navigationStateRef: {
|
|
2008
|
+
current?: TableKeyboardNavigationStateType;
|
|
2009
|
+
};
|
|
2010
|
+
}) => void;
|
|
2011
|
+
onGetSnapshotBeforeUpdate: (options: {
|
|
2012
|
+
document?: Document;
|
|
2013
|
+
contextStateRef: {
|
|
2014
|
+
current?: TableKeyboardNavigationContextType;
|
|
2015
|
+
};
|
|
2016
|
+
navigationStateRef: {
|
|
2017
|
+
current?: TableKeyboardNavigationStateType;
|
|
2018
|
+
};
|
|
2019
|
+
}) => void;
|
|
2020
|
+
onComponentDidUpdate: (options: {
|
|
2021
|
+
scope?: HTMLElement;
|
|
2022
|
+
contextStateRef: {
|
|
2023
|
+
current?: TableKeyboardNavigationContextType;
|
|
2024
|
+
};
|
|
2025
|
+
navigationStateRef: {
|
|
2026
|
+
current?: TableKeyboardNavigationStateType;
|
|
2027
|
+
};
|
|
2028
|
+
}) => void;
|
|
2029
|
+
onFocus: (event: React_2.FocusEvent<HTMLDivElement>, options: {
|
|
2030
|
+
contextStateRef: {
|
|
2031
|
+
current?: TableKeyboardNavigationContextType;
|
|
2032
|
+
};
|
|
2033
|
+
}) => void;
|
|
2034
|
+
onKeyDown: (event: React_2.KeyboardEvent<HTMLElement>, options: {
|
|
2035
|
+
contextStateRef: {
|
|
2036
|
+
current?: TableKeyboardNavigationContextType;
|
|
2037
|
+
};
|
|
2038
|
+
navigationStateRef: {
|
|
2039
|
+
current?: TableKeyboardNavigationStateType;
|
|
2040
|
+
};
|
|
2041
|
+
onNavigationAction?: ((options: {
|
|
2042
|
+
event: React_2.KeyboardEvent<HTMLElement>;
|
|
2043
|
+
focusElement: any;
|
|
2044
|
+
}) => void) | undefined;
|
|
2045
|
+
}) => void;
|
|
2046
|
+
generateMatrix: (options: {
|
|
2047
|
+
scope?: HTMLElement;
|
|
2048
|
+
navigationStateRef: {
|
|
2049
|
+
current?: TableKeyboardNavigationStateType;
|
|
2050
|
+
};
|
|
2051
|
+
}) => void;
|
|
2052
|
+
};
|
|
2053
|
+
|
|
2054
|
+
/**
|
|
2055
|
+
* @hidden
|
|
2056
|
+
*/
|
|
2057
|
+
export declare const tableKeyboardNavigationBodyAttributes: {
|
|
2058
|
+
"data-keyboardnavbody": boolean;
|
|
2059
|
+
};
|
|
2060
|
+
|
|
2061
|
+
/**
|
|
2062
|
+
* @hidden
|
|
2063
|
+
*/
|
|
2064
|
+
export declare const TableKeyboardNavigationContext: React_2.Context<TableKeyboardNavigationContextType | undefined>;
|
|
2065
|
+
|
|
2066
|
+
/**
|
|
2067
|
+
* @hidden
|
|
2068
|
+
*/
|
|
2069
|
+
export declare interface TableKeyboardNavigationContextType {
|
|
2070
|
+
activeId: string | undefined;
|
|
2071
|
+
level: number;
|
|
2072
|
+
}
|
|
2073
|
+
|
|
2074
|
+
/**
|
|
2075
|
+
* @hidden
|
|
2076
|
+
*/
|
|
2077
|
+
export declare const tableKeyboardNavigationHeaderAttributes: {
|
|
2078
|
+
"data-keyboardnavheader": boolean;
|
|
2079
|
+
};
|
|
2080
|
+
|
|
2081
|
+
/**
|
|
2082
|
+
* @hidden
|
|
2083
|
+
*/
|
|
2084
|
+
export declare const tableKeyboardNavigationScopeAttributes: {
|
|
2085
|
+
"data-keyboardnavscope": boolean;
|
|
2086
|
+
};
|
|
2087
|
+
|
|
2088
|
+
/**
|
|
2089
|
+
* @hidden
|
|
2090
|
+
*/
|
|
2091
|
+
export declare interface TableKeyboardNavigationStateType {
|
|
2092
|
+
activeElementIsFocused: boolean;
|
|
2093
|
+
prevNavigationIndexes?: [number, number];
|
|
2094
|
+
idPrefix: string;
|
|
2095
|
+
navigationMatrix: string[][];
|
|
2096
|
+
lastHeaderIndex: number;
|
|
2097
|
+
}
|
|
2098
|
+
|
|
2099
|
+
/**
|
|
2100
|
+
* @hidden
|
|
2101
|
+
*/
|
|
2102
|
+
export declare const tableKeyboardNavigationTools: {
|
|
2103
|
+
generateNavigatableId: (navigationId: string, idPrefix: string, type?: 'column' | 'cell') => string;
|
|
2104
|
+
getNavigatableId: (element: Element | null) => string | undefined;
|
|
2105
|
+
getNavigatableLevel: (element: Element | null) => number | undefined;
|
|
2106
|
+
getNavigatableElement: (scope: HTMLElement, options?: {
|
|
2107
|
+
level: number;
|
|
2108
|
+
}) => HTMLElement;
|
|
2109
|
+
getClosestNavigatableElement: (target: HTMLElement) => Element | null;
|
|
2110
|
+
getActiveElement: (scope: HTMLElement, activeId?: string) => HTMLElement;
|
|
2111
|
+
getClosestScope: (target: HTMLElement) => Element | null;
|
|
2112
|
+
getHeaderElement: (scope: HTMLElement) => Element | null;
|
|
2113
|
+
getBodyElement: (scope: HTMLElement) => Element | null;
|
|
2114
|
+
getFocusableElements: (scope: HTMLElement, options?: {
|
|
2115
|
+
focusable: boolean;
|
|
2116
|
+
}) => Element[];
|
|
2117
|
+
getNavigatableElements: (scope: HTMLElement | null, options?: {
|
|
2118
|
+
level: number;
|
|
2119
|
+
}) => any[];
|
|
2120
|
+
filterNavigatableElements: (options?: {
|
|
2121
|
+
level: number;
|
|
2122
|
+
}) => (element: HTMLElement) => boolean;
|
|
2123
|
+
focusElement: (options: {
|
|
2124
|
+
elementForFocus: HTMLElement;
|
|
2125
|
+
prevElement?: HTMLElement;
|
|
2126
|
+
contextStateRef: {
|
|
2127
|
+
current?: TableKeyboardNavigationContextType;
|
|
2128
|
+
};
|
|
2129
|
+
event: any;
|
|
2130
|
+
}) => void;
|
|
2131
|
+
getIdPrefix: (navigationStateRef: {
|
|
2132
|
+
current?: TableKeyboardNavigationStateType;
|
|
2133
|
+
}) => string;
|
|
2134
|
+
isNavigatable: (element: Element | null) => boolean;
|
|
2135
|
+
findNextIdByRowIndex: (initialRowIndex: number, cellIndex: number, elementId: string | undefined, matrix: string[][], isReverse: boolean) => [
|
|
2136
|
+
string,
|
|
2137
|
+
[
|
|
2138
|
+
number,
|
|
2139
|
+
number
|
|
2140
|
+
]
|
|
2141
|
+
] | [
|
|
2142
|
+
];
|
|
2143
|
+
findNextIdByCellIndex: (rowIndex: number, initialCellIndex: number, elementId: string | undefined, matrix: string[][], isReverse: boolean) => [
|
|
2144
|
+
string,
|
|
2145
|
+
[
|
|
2146
|
+
number,
|
|
2147
|
+
number
|
|
2148
|
+
]
|
|
2149
|
+
] | [
|
|
2150
|
+
];
|
|
2151
|
+
findId: (navigationMatrix: string[][], cellId?: string) => number[] | undefined;
|
|
2152
|
+
getNextNavigationIndex: (navigationStateRef: {
|
|
2153
|
+
current?: TableKeyboardNavigationStateType;
|
|
2154
|
+
}) => number;
|
|
2155
|
+
getFilterColumnId: (columnId: string) => string;
|
|
2156
|
+
};
|
|
2157
|
+
|
|
2158
|
+
/** @hidden */
|
|
2159
|
+
export declare interface TableKeyDownEvent<T> extends BaseEvent<T> {
|
|
2160
|
+
/**
|
|
2161
|
+
* The current leaf data items.
|
|
2162
|
+
*/
|
|
2163
|
+
dataItems: any[];
|
|
2164
|
+
/**
|
|
2165
|
+
* Selection mode.
|
|
2166
|
+
*/
|
|
2167
|
+
mode: 'single' | 'multiple';
|
|
2168
|
+
/**
|
|
2169
|
+
* Indicates if cell selection mode is enabled.
|
|
2170
|
+
*/
|
|
2171
|
+
cell: boolean;
|
|
2172
|
+
/**
|
|
2173
|
+
* The `selectedField` prop of the component.
|
|
2174
|
+
*/
|
|
2175
|
+
selectedField: string;
|
|
2176
|
+
/**
|
|
2177
|
+
* The component unique identifier.
|
|
2178
|
+
*/
|
|
2179
|
+
componentId: string;
|
|
2180
|
+
}
|
|
2181
|
+
|
|
2182
|
+
/** @hidden */
|
|
2183
|
+
export declare type TableSelectableMode = 'single' | 'multiple';
|
|
2184
|
+
|
|
2185
|
+
/** @hidden */
|
|
2186
|
+
export declare interface TableSelectableSettings {
|
|
2187
|
+
/**
|
|
2188
|
+
* Determines if selection is allowed.
|
|
2189
|
+
*
|
|
2190
|
+
* @default true
|
|
2191
|
+
*/
|
|
2192
|
+
enabled?: boolean;
|
|
2193
|
+
/**
|
|
2194
|
+
* The available values are:
|
|
2195
|
+
* * `single`
|
|
2196
|
+
* * `multiple`
|
|
2197
|
+
*
|
|
2198
|
+
* @default "multiple"
|
|
2199
|
+
*/
|
|
2200
|
+
mode?: TableSelectableMode;
|
|
2201
|
+
/**
|
|
2202
|
+
* Determines if cell selection is allowed.
|
|
2203
|
+
*
|
|
2204
|
+
* @default false
|
|
2205
|
+
*/
|
|
2206
|
+
cell?: boolean;
|
|
2207
|
+
/**
|
|
2208
|
+
* Determines if drag selection is allowed.
|
|
2209
|
+
*
|
|
2210
|
+
* @default false
|
|
2211
|
+
*/
|
|
2212
|
+
drag?: boolean;
|
|
2213
|
+
}
|
|
2214
|
+
|
|
2215
|
+
/** @hidden */
|
|
2216
|
+
export declare const TableSelection: (props: TableSelectionProps) => JSX_2.Element;
|
|
2217
|
+
|
|
2218
|
+
/** @hidden */
|
|
2219
|
+
export declare interface TableSelectionChangeEvent<T> extends BaseEvent<T>, TableDragSelectionReleaseEvent {
|
|
2220
|
+
/**
|
|
2221
|
+
* The data item which was selected or deselected when the checkbox selection column is used. It will be `null` when the row or cell selection is used.
|
|
2222
|
+
*/
|
|
2223
|
+
dataItem: any;
|
|
2224
|
+
/**
|
|
2225
|
+
* The `selectedField` prop of the component.
|
|
2226
|
+
*/
|
|
2227
|
+
selectedField: string;
|
|
2228
|
+
/**
|
|
2229
|
+
* The component unique identifier.
|
|
2230
|
+
*/
|
|
2231
|
+
componentId: string;
|
|
2232
|
+
/**
|
|
2233
|
+
* The current component leaf data items.
|
|
2234
|
+
*/
|
|
2235
|
+
dataItems: any[];
|
|
2236
|
+
}
|
|
2237
|
+
|
|
2238
|
+
/** @hidden */
|
|
2239
|
+
export declare interface TableSelectionProps {
|
|
2240
|
+
children: any;
|
|
2241
|
+
selectable?: TableSelectableSettings;
|
|
2242
|
+
onRelease: (options: TableDragSelectionReleaseEvent) => void;
|
|
2243
|
+
childRef?: (childElement: HTMLElement) => void;
|
|
2244
|
+
}
|
|
2245
|
+
|
|
2246
|
+
/**
|
|
2247
|
+
* The TextFilter component used for editing text value of FilterDescriptor object.
|
|
2248
|
+
*/
|
|
2249
|
+
export declare class TextFilter extends React_2.Component<TextFilterProps> {
|
|
2250
|
+
/**
|
|
2251
|
+
* @hidden
|
|
2252
|
+
*/
|
|
2253
|
+
static propTypes: {
|
|
2254
|
+
filter: PropTypes.Validator<object>;
|
|
2255
|
+
onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
2256
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
2257
|
+
};
|
|
2258
|
+
/**
|
|
2259
|
+
* @hidden
|
|
2260
|
+
*/
|
|
2261
|
+
render(): JSX_2.Element;
|
|
2262
|
+
private onChange;
|
|
2263
|
+
}
|
|
2264
|
+
|
|
2265
|
+
/**
|
|
2266
|
+
* @hidden
|
|
2267
|
+
*/
|
|
2268
|
+
export declare class TextFilterCell extends TextFilterCell_base {
|
|
2269
|
+
}
|
|
2270
|
+
|
|
2271
|
+
declare const TextFilterCell_base: React_2.ComponentClass<FilterComponentProps, any>;
|
|
2272
|
+
|
|
2273
|
+
/**
|
|
2274
|
+
* The props of the TextFilter component.
|
|
2275
|
+
*/
|
|
2276
|
+
export declare interface TextFilterProps {
|
|
2277
|
+
/**
|
|
2278
|
+
* The FilterDescriptor object which will be edited.
|
|
2279
|
+
*/
|
|
2280
|
+
filter: FilterDescriptor;
|
|
2281
|
+
/**
|
|
2282
|
+
* The FilterChange event, triggered while editing the FilterOperator.
|
|
2283
|
+
*/
|
|
2284
|
+
onFilterChange: (event: {
|
|
2285
|
+
nextFilter: FilterDescriptor;
|
|
2286
|
+
}) => void;
|
|
2287
|
+
/**
|
|
2288
|
+
* The accessible label of the component.
|
|
2289
|
+
*/
|
|
2290
|
+
ariaLabel?: string;
|
|
2291
|
+
}
|
|
2292
|
+
|
|
2293
|
+
/**
|
|
2294
|
+
* @hidden
|
|
2295
|
+
*/
|
|
2296
|
+
export declare interface TreeColumnBaseProps<CellProps = CellProps, HeaderCellProps = HeaderCellProps, FilterCellProps = FilterCellProps> extends ColumnBaseProps<CellProps> {
|
|
2297
|
+
/**
|
|
2298
|
+
* A collection of child columns.
|
|
2299
|
+
*/
|
|
2300
|
+
children?: TreeColumnBaseProps<CellProps, HeaderCellProps, FilterCellProps>[];
|
|
2301
|
+
/**
|
|
2302
|
+
* The column menu component. Pass the [ColumnMenuTextColumn]({% slug api_data-tools_columnmenutextcolumn %}),
|
|
2303
|
+
* [ColumnMenuNumericColumn]({% slug api_data-tools_columnmenunumericcolumn %}),
|
|
2304
|
+
* [ColumnMenuDateColumn]({% slug api_data-tools_columnmenudatecolumn %}),
|
|
2305
|
+
* [ColumnMenuBooleanColumn]({% slug api_data-tools_columnmenubooleancolumn %})
|
|
2306
|
+
* or a custom component base on the type of the column data.
|
|
2307
|
+
*/
|
|
2308
|
+
columnMenu?: React.ComponentType<ColumnMenuProps>;
|
|
2309
|
+
/**
|
|
2310
|
+
* If set to `true`, the column will render the icons that are used for expanding and collapsing child rows.
|
|
2311
|
+
*/
|
|
2312
|
+
expandable?: boolean;
|
|
2313
|
+
/**
|
|
2314
|
+
* Defines the component that will be rendered as an edit cell.
|
|
2315
|
+
*/
|
|
2316
|
+
editCell?: ComponentType<CellProps>;
|
|
2317
|
+
/**
|
|
2318
|
+
* Defines the component that will be rendered as a header cell.
|
|
2319
|
+
* If not set, a `HeaderCell` will be rendered by default.
|
|
2320
|
+
*/
|
|
2321
|
+
headerCell?: ComponentType<HeaderCellProps>;
|
|
2322
|
+
/**
|
|
2323
|
+
* **Deprecated**. Use `filterCell` prop instead.
|
|
2324
|
+
*/
|
|
2325
|
+
filter?: ComponentType<FilterCellProps>;
|
|
2326
|
+
/**
|
|
2327
|
+
* Defines the component that will be rendered as a filter cell.
|
|
2328
|
+
*/
|
|
2329
|
+
filterCell?: ComponentType<FilterCellProps>;
|
|
2330
|
+
}
|
|
2331
|
+
|
|
2332
|
+
/**
|
|
2333
|
+
* Creates a flat data array from the passed tree dataset.
|
|
2334
|
+
*
|
|
2335
|
+
* @param {object[]} dataset - The source dataset of data items.
|
|
2336
|
+
* @param {string} expandField - The field which points to the expanded value of each data item.
|
|
2337
|
+
* @param {string} subItemsField - The field which points to the subitems collection of each data item.
|
|
2338
|
+
* @returns {object[]} - A collection of the generated data items that are in a flat structure.
|
|
2339
|
+
*/
|
|
2340
|
+
export declare const treeToFlat: (data: any[], expandField: string, subItemsField: string) => any[];
|
|
2341
|
+
|
|
2342
|
+
/**
|
|
2343
|
+
* @hidden
|
|
2344
|
+
*/
|
|
2345
|
+
export declare const unaryOperator: (operator: any) => boolean;
|
|
2346
|
+
|
|
2347
|
+
/**
|
|
2348
|
+
* @hidden
|
|
2349
|
+
*/
|
|
2350
|
+
export declare function updateLeft(columnsMap: number[][], columns: Array<{
|
|
2351
|
+
parentIndex: number;
|
|
2352
|
+
colSpan: number;
|
|
2353
|
+
rowSpan: number;
|
|
2354
|
+
depth: number;
|
|
2355
|
+
kFirst?: boolean;
|
|
2356
|
+
children: any[];
|
|
2357
|
+
width?: string | number;
|
|
2358
|
+
locked?: boolean;
|
|
2359
|
+
index: number;
|
|
2360
|
+
left: number;
|
|
2361
|
+
right: number;
|
|
2362
|
+
rightBorder: boolean;
|
|
2363
|
+
ariaColumnIndex: number;
|
|
2364
|
+
}>, generateLeft?: boolean): void;
|
|
2365
|
+
|
|
2366
|
+
/**
|
|
2367
|
+
* @hidden
|
|
2368
|
+
*/
|
|
2369
|
+
export declare function updateRight(columnsMap: number[][], columns: Array<{
|
|
2370
|
+
parentIndex: number;
|
|
2371
|
+
colSpan: number;
|
|
2372
|
+
rowSpan: number;
|
|
2373
|
+
depth: number;
|
|
2374
|
+
kFirst?: boolean;
|
|
2375
|
+
children: any[];
|
|
2376
|
+
width?: string | number;
|
|
2377
|
+
locked?: boolean;
|
|
2378
|
+
index: number;
|
|
2379
|
+
left: number;
|
|
2380
|
+
right: number;
|
|
2381
|
+
rightBorder: boolean;
|
|
2382
|
+
ariaColumnIndex: number;
|
|
2383
|
+
}>, generateRight?: boolean): void;
|
|
2384
|
+
|
|
2385
|
+
/**
|
|
2386
|
+
* @hidden
|
|
2387
|
+
*/
|
|
2388
|
+
export declare const useTableKeyboardNavigation: (elementId: string, navigatable?: boolean) => {
|
|
2389
|
+
tabIndex?: undefined;
|
|
2390
|
+
"data-keyboardnavlevel"?: undefined;
|
|
2391
|
+
"data-keyboardnavid"?: undefined;
|
|
2392
|
+
} | {
|
|
2393
|
+
tabIndex: number;
|
|
2394
|
+
"data-keyboardnavlevel": number;
|
|
2395
|
+
"data-keyboardnavid": string;
|
|
2396
|
+
};
|
|
2397
|
+
|
|
2398
|
+
export { }
|