@progress/kendo-react-data-tools 5.4.0-dev.202205250548 → 5.4.0-dev.202206081230

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.
Files changed (180) hide show
  1. package/dist/cdn/js/kendo-react-data-tools.js +1 -1
  2. package/dist/es/columnmenu/ColumnMenu.js +17 -6
  3. package/dist/es/columnmenu/ColumnMenuFilterForm.d.ts +1 -0
  4. package/dist/es/columnmenu/ColumnMenuFilterLogic.js +1 -1
  5. package/dist/es/columnmenu/ColumnMenuFilters.js +4 -4
  6. package/dist/es/columnmenu/ColumnMenuItem.js +1 -1
  7. package/dist/es/columnmenu/ColumnMenuOperators.d.ts +4 -4
  8. package/dist/es/columnmenu/ColumnMenuOperators.js +17 -8
  9. package/dist/es/drag/ColumnDraggable.d.ts +1 -0
  10. package/dist/es/drag/ColumnDraggable.js +4 -1
  11. package/dist/es/drag/ColumnResize.d.ts +5 -4
  12. package/dist/es/drag/ColumnResize.js +3 -0
  13. package/dist/es/drag/ColumnResizer.js +4 -1
  14. package/dist/es/drag/CommonDragLogic.d.ts +9 -8
  15. package/dist/es/drag/CommonDragLogic.js +1 -0
  16. package/dist/es/drag/DragClue.d.ts +2 -2
  17. package/dist/es/drag/DragClue.js +4 -2
  18. package/dist/es/drag/DropClue.d.ts +1 -1
  19. package/dist/es/drag/DropClue.js +3 -1
  20. package/dist/es/filter/Expression.js +11 -7
  21. package/dist/es/filter/FieldSettings.js +1 -0
  22. package/dist/es/filter/Filter.d.ts +1 -1
  23. package/dist/es/filter/Filter.js +8 -6
  24. package/dist/es/filter/Group.js +51 -24
  25. package/dist/es/filter/filters/BooleanFilter.d.ts +2 -2
  26. package/dist/es/filter/filters/BooleanFilter.js +3 -1
  27. package/dist/es/filter/filters/DateFilter.js +4 -2
  28. package/dist/es/filter/filters/EnumFilter.d.ts +2 -2
  29. package/dist/es/filter/filters/EnumFilter.js +5 -3
  30. package/dist/es/filter/filters/NumericFilter.js +4 -2
  31. package/dist/es/filter/filters/TextFilter.d.ts +1 -2
  32. package/dist/es/filter/filters/TextFilter.js +4 -2
  33. package/dist/es/filter/index.js +1 -0
  34. package/dist/es/filter/operators.d.ts +4 -4
  35. package/dist/es/filter/operators.js +17 -8
  36. package/dist/es/filteringCells/BooleanFilter.js +13 -2
  37. package/dist/es/filteringCells/DateFilter.js +3 -1
  38. package/dist/es/filteringCells/FilterCellProps.js +1 -0
  39. package/dist/es/filteringCells/FilterComponent.js +15 -4
  40. package/dist/es/filteringCells/FilterComponentProps.js +1 -0
  41. package/dist/es/filteringCells/FilterOperator.js +1 -0
  42. package/dist/es/filteringCells/NumericFilter.js +3 -1
  43. package/dist/es/filteringCells/TextFilter.js +3 -1
  44. package/dist/es/filteringCells/index.js +3 -0
  45. package/dist/es/header/CellProps.js +1 -0
  46. package/dist/es/header/ColumnProps.d.ts +8 -8
  47. package/dist/es/header/FilterRow.js +1 -1
  48. package/dist/es/header/Header.js +3 -1
  49. package/dist/es/header/HeaderCell.d.ts +1 -1
  50. package/dist/es/header/HeaderCell.js +2 -2
  51. package/dist/es/header/HeaderRow.d.ts +9 -7
  52. package/dist/es/header/HeaderRow.js +3 -1
  53. package/dist/es/header/HeaderSelectionCell.d.ts +2 -1
  54. package/dist/es/header/HeaderSelectionCell.js +2 -2
  55. package/dist/es/header/HeaderThElement.d.ts +10 -10
  56. package/dist/es/header/SortSettings.d.ts +1 -38
  57. package/dist/es/header/SortSettings.js +10 -1
  58. package/dist/es/header/index.js +1 -0
  59. package/dist/es/header/utils/index.d.ts +5 -2
  60. package/dist/es/header/utils/index.js +1 -1
  61. package/dist/es/main.js +4 -0
  62. package/dist/es/messages/index.d.ts +62 -62
  63. package/dist/es/navigation/TableKeyboardNavigation.d.ts +8 -8
  64. package/dist/es/navigation/TableKeyboardNavigation.js +10 -1
  65. package/dist/es/navigation/TableKeyboardNavigationContext.d.ts +1 -1
  66. package/dist/es/navigation/TableKeyboardNavigationContextType.js +1 -0
  67. package/dist/es/navigation/TableKeyboardNavigationStateType.js +1 -0
  68. package/dist/es/navigation/constants.d.ts +3 -3
  69. package/dist/es/navigation/constants.js +11 -2
  70. package/dist/es/navigation/hooks.d.ts +2 -3
  71. package/dist/es/navigation/utils.d.ts +26 -26
  72. package/dist/es/navigation/utils.js +10 -10
  73. package/dist/es/package-metadata.js +1 -1
  74. package/dist/es/pager/Pager.d.ts +4 -3
  75. package/dist/es/pager/Pager.js +23 -4
  76. package/dist/es/pager/PagerInput.js +5 -3
  77. package/dist/es/pager/PagerNumericButtons.d.ts +2 -2
  78. package/dist/es/pager/PagerNumericButtons.js +5 -3
  79. package/dist/es/pager/PagerPageSizes.d.ts +1 -1
  80. package/dist/es/pager/PagerPageSizes.js +3 -1
  81. package/dist/es/selection/TableSelectableSettings.js +1 -0
  82. package/dist/es/selection/TableSelection.js +1 -1
  83. package/dist/es/selection/events.js +1 -0
  84. package/dist/es/selection/utils.d.ts +5 -5
  85. package/dist/es/selection/utils.js +21 -5
  86. package/dist/es/utils/data-operations.js +13 -4
  87. package/dist/es/utils/group-operations.d.ts +1 -1
  88. package/dist/es/utils/group-operations.js +1 -1
  89. package/dist/es/virtualization/columns.js +10 -1
  90. package/dist/npm/columnmenu/ColumnMenu.js +29 -13
  91. package/dist/npm/columnmenu/ColumnMenuFilterForm.d.ts +1 -0
  92. package/dist/npm/columnmenu/ColumnMenuFilterForm.js +6 -3
  93. package/dist/npm/columnmenu/ColumnMenuFilterLogic.js +5 -3
  94. package/dist/npm/columnmenu/ColumnMenuFilters.js +15 -10
  95. package/dist/npm/columnmenu/ColumnMenuItem.js +5 -3
  96. package/dist/npm/columnmenu/ColumnMenuOperators.d.ts +4 -4
  97. package/dist/npm/columnmenu/ColumnMenuOperators.js +18 -8
  98. package/dist/npm/columnmenu/index.js +20 -9
  99. package/dist/npm/drag/ColumnDraggable.d.ts +1 -0
  100. package/dist/npm/drag/ColumnDraggable.js +5 -1
  101. package/dist/npm/drag/ColumnResize.d.ts +5 -4
  102. package/dist/npm/drag/ColumnResize.js +4 -0
  103. package/dist/npm/drag/ColumnResizer.js +5 -1
  104. package/dist/npm/drag/CommonDragLogic.d.ts +9 -8
  105. package/dist/npm/drag/CommonDragLogic.js +4 -2
  106. package/dist/npm/drag/DragClue.d.ts +2 -2
  107. package/dist/npm/drag/DragClue.js +6 -3
  108. package/dist/npm/drag/DropClue.d.ts +1 -1
  109. package/dist/npm/drag/DropClue.js +5 -2
  110. package/dist/npm/filter/Expression.js +18 -13
  111. package/dist/npm/filter/Filter.d.ts +1 -1
  112. package/dist/npm/filter/Filter.js +10 -7
  113. package/dist/npm/filter/Group.js +56 -28
  114. package/dist/npm/filter/filters/BooleanFilter.d.ts +2 -2
  115. package/dist/npm/filter/filters/BooleanFilter.js +4 -1
  116. package/dist/npm/filter/filters/DateFilter.js +5 -2
  117. package/dist/npm/filter/filters/EnumFilter.d.ts +2 -2
  118. package/dist/npm/filter/filters/EnumFilter.js +8 -5
  119. package/dist/npm/filter/filters/NumericFilter.js +5 -2
  120. package/dist/npm/filter/filters/TextFilter.d.ts +1 -2
  121. package/dist/npm/filter/filters/TextFilter.js +5 -2
  122. package/dist/npm/filter/filters/index.js +19 -8
  123. package/dist/npm/filter/index.js +20 -8
  124. package/dist/npm/filter/operators.d.ts +4 -4
  125. package/dist/npm/filter/operators.js +22 -10
  126. package/dist/npm/filteringCells/BooleanFilter.js +15 -3
  127. package/dist/npm/filteringCells/DateFilter.js +5 -2
  128. package/dist/npm/filteringCells/FilterComponent.js +19 -6
  129. package/dist/npm/filteringCells/NumericFilter.js +5 -2
  130. package/dist/npm/filteringCells/TextFilter.js +5 -2
  131. package/dist/npm/filteringCells/index.js +22 -8
  132. package/dist/npm/header/ColumnProps.d.ts +8 -8
  133. package/dist/npm/header/ColumnProps.js +1 -0
  134. package/dist/npm/header/FilterRow.js +6 -4
  135. package/dist/npm/header/Header.js +5 -2
  136. package/dist/npm/header/HeaderCell.d.ts +1 -1
  137. package/dist/npm/header/HeaderCell.js +3 -2
  138. package/dist/npm/header/HeaderRow.d.ts +9 -7
  139. package/dist/npm/header/HeaderRow.js +8 -5
  140. package/dist/npm/header/HeaderSelectionCell.d.ts +2 -1
  141. package/dist/npm/header/HeaderSelectionCell.js +3 -2
  142. package/dist/npm/header/HeaderThElement.d.ts +10 -10
  143. package/dist/npm/header/HeaderThElement.js +4 -2
  144. package/dist/npm/header/SortSettings.d.ts +1 -38
  145. package/dist/npm/header/SortSettings.js +13 -2
  146. package/dist/npm/header/index.js +24 -12
  147. package/dist/npm/header/utils/index.d.ts +5 -2
  148. package/dist/npm/header/utils/index.js +2 -1
  149. package/dist/npm/main.js +40 -24
  150. package/dist/npm/messages/index.d.ts +62 -62
  151. package/dist/npm/messages/index.js +3 -1
  152. package/dist/npm/navigation/TableKeyboardNavigation.d.ts +8 -8
  153. package/dist/npm/navigation/TableKeyboardNavigation.js +19 -9
  154. package/dist/npm/navigation/TableKeyboardNavigationContext.d.ts +1 -1
  155. package/dist/npm/navigation/TableKeyboardNavigationContext.js +1 -0
  156. package/dist/npm/navigation/constants.d.ts +3 -3
  157. package/dist/npm/navigation/constants.js +13 -3
  158. package/dist/npm/navigation/hooks.d.ts +2 -3
  159. package/dist/npm/navigation/hooks.js +3 -1
  160. package/dist/npm/navigation/utils.d.ts +26 -26
  161. package/dist/npm/navigation/utils.js +54 -33
  162. package/dist/npm/package-metadata.js +2 -1
  163. package/dist/npm/pager/Pager.d.ts +4 -3
  164. package/dist/npm/pager/Pager.js +30 -10
  165. package/dist/npm/pager/PagerInput.js +9 -6
  166. package/dist/npm/pager/PagerNumericButtons.d.ts +2 -2
  167. package/dist/npm/pager/PagerNumericButtons.js +8 -5
  168. package/dist/npm/pager/PagerPageSizes.d.ts +1 -1
  169. package/dist/npm/pager/PagerPageSizes.js +6 -3
  170. package/dist/npm/selection/TableSelection.js +19 -17
  171. package/dist/npm/selection/constants.js +1 -0
  172. package/dist/npm/selection/utils.d.ts +5 -5
  173. package/dist/npm/selection/utils.js +50 -24
  174. package/dist/npm/utils/data-operations.js +17 -7
  175. package/dist/npm/utils/group-operations.d.ts +1 -1
  176. package/dist/npm/utils/group-operations.js +11 -7
  177. package/dist/npm/virtualization/columns.js +11 -1
  178. package/dist/npm/virtualization/index.js +15 -4
  179. package/dist/systemjs/kendo-react-data-tools.js +1 -1
  180. package/package.json +10 -10
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -22,6 +24,15 @@ var __assign = (this && this.__assign) || function () {
22
24
  };
23
25
  return __assign.apply(this, arguments);
24
26
  };
27
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
28
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
29
+ if (ar || !(i in from)) {
30
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
31
+ ar[i] = from[i];
32
+ }
33
+ }
34
+ return to.concat(ar || Array.prototype.slice.call(from));
35
+ };
25
36
  import * as React from 'react';
26
37
  import * as PropTypes from 'prop-types';
27
38
  import { isCompositeFilterDescriptor } from '@progress/kendo-data-query';
@@ -37,43 +48,59 @@ var Group = /** @class */ (function (_super) {
37
48
  __extends(Group, _super);
38
49
  function Group() {
39
50
  var _this = _super !== null && _super.apply(this, arguments) || this;
40
- _this.onGroupRemove = function () {
41
- _this.props.onRemove.call(undefined, {
42
- filter: _this.props.filter
43
- });
51
+ _this.onGroupRemove = function (event) {
52
+ var ev = {
53
+ filter: _this.props.filter,
54
+ target: _this,
55
+ syntheticEvent: event,
56
+ nativeEvent: event.nativeEvent
57
+ };
58
+ _this.props.onRemove.call(undefined, ev);
44
59
  };
45
- _this.onAddExpression = function () {
60
+ _this.onAddExpression = function (event) {
46
61
  var prevFilter = _this.props.filter;
47
62
  var firstField = _this.props.fields[0];
48
63
  var newExpression = { field: firstField.name, operator: firstField.operators[0].operator };
49
64
  newExpression.value = stringOperator(newExpression.operator) ? '' : null;
50
- _this.props.onChange.call(undefined, {
51
- nextFilter: __assign({}, prevFilter, { filters: prevFilter.filters.concat([newExpression]) }),
52
- prevFilter: prevFilter
53
- });
65
+ var ev = {
66
+ nextFilter: __assign(__assign({}, prevFilter), { filters: __spreadArray(__spreadArray([], prevFilter.filters, true), [newExpression], false) }),
67
+ prevFilter: prevFilter,
68
+ target: _this,
69
+ syntheticEvent: event,
70
+ nativeEvent: event.nativeEvent
71
+ };
72
+ _this.props.onChange.call(undefined, ev);
54
73
  };
55
- _this.onAddGroup = function () {
74
+ _this.onAddGroup = function (event) {
56
75
  var prevFilter = _this.props.filter;
57
- _this.props.onChange.call(undefined, {
58
- nextFilter: __assign({}, prevFilter, { filters: prevFilter.filters.concat([__assign({}, _this.props.defaultGroupFilter)]) }),
59
- prevFilter: prevFilter
60
- });
76
+ var ev = {
77
+ nextFilter: __assign(__assign({}, prevFilter), { filters: __spreadArray(__spreadArray([], prevFilter.filters, true), [__assign({}, _this.props.defaultGroupFilter)], false) }),
78
+ prevFilter: prevFilter,
79
+ target: _this,
80
+ syntheticEvent: event,
81
+ nativeEvent: event.nativeEvent
82
+ };
83
+ _this.props.onChange.call(undefined, ev);
61
84
  };
62
- _this.onLogicAnd = function () { return _this.changeLogic('and'); };
63
- _this.onLogicOr = function () { return _this.changeLogic('or'); };
64
- _this.changeLogic = function (logic) {
85
+ _this.onLogicAnd = function (event) { return _this.changeLogic('and', event); };
86
+ _this.onLogicOr = function (event) { return _this.changeLogic('or', event); };
87
+ _this.changeLogic = function (logic, event) {
65
88
  var prevFilter = _this.props.filter;
66
89
  if (prevFilter.logic !== logic) {
67
- _this.props.onChange.call(undefined, {
68
- nextFilter: __assign({}, prevFilter, { logic: logic }),
69
- prevFilter: prevFilter
70
- });
90
+ var ev = {
91
+ nextFilter: __assign(__assign({}, prevFilter), { logic: logic }),
92
+ prevFilter: prevFilter,
93
+ target: _this,
94
+ syntheticEvent: event,
95
+ nativeEvent: event.nativeEvent
96
+ };
97
+ _this.props.onChange.call(undefined, ev);
71
98
  }
72
99
  };
73
100
  _this.replaceFilter = function (prevFilter, nextFilter) {
74
101
  var filter = _this.props.filter;
75
102
  var filters = filter.filters.map(function (f) { return f === prevFilter ? nextFilter : f; });
76
- return __assign({}, filter, { filters: filters });
103
+ return __assign(__assign({}, filter), { filters: filters });
77
104
  };
78
105
  _this.onChange = function (event) {
79
106
  var nextFilter = _this.replaceFilter(event.prevFilter, event.nextFilter);
@@ -90,7 +117,7 @@ var Group = /** @class */ (function (_super) {
90
117
  var prevFilter = _this.props.filter;
91
118
  var filters = prevFilter.filters.filter(function (f) { return f !== event.filter; });
92
119
  var changeEvent = {
93
- nextFilter: __assign({}, prevFilter, { filters: filters }),
120
+ nextFilter: __assign(__assign({}, prevFilter), { filters: filters }),
94
121
  prevFilter: prevFilter,
95
122
  syntheticEvent: event.syntheticEvent,
96
123
  nativeEvent: event.nativeEvent,
@@ -28,10 +28,10 @@ export declare class BooleanFilter extends React.Component<BooleanFilterProps> {
28
28
  static propTypes: {
29
29
  filter: PropTypes.Validator<object>;
30
30
  onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
31
- data: PropTypes.Requireable<PropTypes.InferProps<{
31
+ data: PropTypes.Requireable<(PropTypes.InferProps<{
32
32
  text: PropTypes.Requireable<string>;
33
33
  value: PropTypes.Requireable<any>;
34
- }>[]>;
34
+ }> | null | undefined)[]>;
35
35
  defaultItem: PropTypes.Requireable<any>;
36
36
  };
37
37
  private data;
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -34,7 +36,7 @@ var DateFilter = /** @class */ (function (_super) {
34
36
  var _this = _super !== null && _super.apply(this, arguments) || this;
35
37
  _this.onChange = function (event) {
36
38
  _this.props.onFilterChange.call(undefined, {
37
- nextFilter: __assign({}, _this.props.filter, { value: event.value })
39
+ nextFilter: __assign(__assign({}, _this.props.filter), { value: event.value })
38
40
  });
39
41
  };
40
42
  return _this;
@@ -28,10 +28,10 @@ export declare class EnumFilter extends React.Component<EnumFilterProps> {
28
28
  static propTypes: {
29
29
  filter: PropTypes.Validator<object>;
30
30
  onFilterChange: PropTypes.Validator<(...args: any[]) => any>;
31
- data: PropTypes.Requireable<PropTypes.InferProps<{
31
+ data: PropTypes.Requireable<(PropTypes.InferProps<{
32
32
  text: PropTypes.Requireable<string>;
33
33
  value: PropTypes.Requireable<any>;
34
- }>[]>;
34
+ }> | null | undefined)[]>;
35
35
  defaultItem: PropTypes.Requireable<any>;
36
36
  };
37
37
  /**
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -37,7 +39,7 @@ var EnumFilter = /** @class */ (function (_super) {
37
39
  var _this = _super !== null && _super.apply(this, arguments) || this;
38
40
  _this.onChange = function (event) {
39
41
  _this.props.onFilterChange.call(undefined, {
40
- nextFilter: __assign({}, _this.props.filter, { value: event.value.value })
42
+ nextFilter: __assign(__assign({}, _this.props.filter), { value: event.value.value })
41
43
  });
42
44
  };
43
45
  return _this;
@@ -48,7 +50,7 @@ var EnumFilter = /** @class */ (function (_super) {
48
50
  EnumFilter.prototype.render = function () {
49
51
  var locService = provideLocalizationService(this);
50
52
  var _a = this.props, filter = _a.filter, _b = _a.data, data = _b === void 0 ? [] : _b, defaultItem = _a.defaultItem;
51
- var locData = data.map(function (item) { return (__assign({}, item, { text: locService.toLanguageString(item.text, messages[item.text] || item.text) })); });
53
+ var locData = data.map(function (item) { return (__assign(__assign({}, item), { text: locService.toLanguageString(item.text, messages[item.text] || item.text) })); });
52
54
  return (React.createElement(DropDownList, { value: locData.find(function (i) { return i.value === filter.value; }) || null, onChange: this.onChange, defaultItem: defaultItem, data: locData, textField: "text" }));
53
55
  };
54
56
  /**
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -34,7 +36,7 @@ var NumericFilter = /** @class */ (function (_super) {
34
36
  var _this = _super !== null && _super.apply(this, arguments) || this;
35
37
  _this.onChange = function (event) {
36
38
  _this.props.onFilterChange.call(undefined, {
37
- nextFilter: __assign({}, _this.props.filter, { value: event.value })
39
+ nextFilter: __assign(__assign({}, _this.props.filter), { value: event.value })
38
40
  });
39
41
  };
40
42
  return _this;
@@ -1,6 +1,5 @@
1
1
  import * as React from 'react';
2
2
  import * as PropTypes from 'prop-types';
3
- import { FilterOperator } from '../../filteringCells';
4
3
  import { FilterDescriptor } from '@progress/kendo-data-query';
5
4
  /**
6
5
  * The props of the TextFilter component.
@@ -14,7 +13,7 @@ export interface TextFilterProps {
14
13
  * The FilterChange event, triggered while editing the FilterOperator.
15
14
  */
16
15
  onFilterChange: (event: {
17
- nextFilter: FilterOperator;
16
+ nextFilter: FilterDescriptor;
18
17
  }) => void;
19
18
  }
20
19
  /**
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -34,7 +36,7 @@ var TextFilter = /** @class */ (function (_super) {
34
36
  var _this = _super !== null && _super.apply(this, arguments) || this;
35
37
  _this.onChange = function (event) {
36
38
  _this.props.onFilterChange.call(undefined, {
37
- nextFilter: __assign({}, _this.props.filter, { value: event.value })
39
+ nextFilter: __assign(__assign({}, _this.props.filter), { value: event.value })
38
40
  });
39
41
  };
40
42
  return _this;
@@ -1,5 +1,6 @@
1
1
  export * from './filters';
2
2
  export * from './Expression';
3
+ export * from './FieldSettings';
3
4
  export * from './Filter';
4
5
  export * from './Group';
5
6
  export * from './operators';
@@ -22,7 +22,7 @@ export declare class Operators {
22
22
  * - { text: 'filter.isEmptyOperator', operator: 'isempty' }
23
23
  * - { text: 'filter.isNotEmptyOperator', operator: 'isnotempty' }
24
24
  */
25
- static readonly text: FilterOperator[];
25
+ static get text(): FilterOperator[];
26
26
  /**
27
27
  * An array containing the operators for the NumericFilter component.
28
28
  *
@@ -37,7 +37,7 @@ export declare class Operators {
37
37
  * - { text: 'filter.isNullOperator', operator: 'isnull' }
38
38
  * - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
39
39
  */
40
- static readonly numeric: FilterOperator[];
40
+ static get numeric(): FilterOperator[];
41
41
  /**
42
42
  * An array containing the operators for the DateFilter component.
43
43
  *
@@ -52,7 +52,7 @@ export declare class Operators {
52
52
  * - { text: 'filter.isNullOperator', operator: 'isnull' }
53
53
  * - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
54
54
  */
55
- static readonly date: FilterOperator[];
55
+ static get date(): FilterOperator[];
56
56
  /**
57
57
  * An array containing the operators for the BooleanFilter component.
58
58
  *
@@ -61,7 +61,7 @@ export declare class Operators {
61
61
  * - { text: 'filter.eqOperator', operator: 'eq' }
62
62
  * - { text: 'filter.notEqOperator', operator: 'neq' }
63
63
  */
64
- static readonly boolean: FilterOperator[];
64
+ static get boolean(): FilterOperator[];
65
65
  }
66
66
  /**
67
67
  * @hidden
@@ -1,3 +1,12 @@
1
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
2
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
3
+ if (ar || !(i in from)) {
4
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
5
+ ar[i] = from[i];
6
+ }
7
+ }
8
+ return to.concat(ar || Array.prototype.slice.call(from));
9
+ };
1
10
  import { filterEqOperator, filterNotEqOperator, filterIsNullOperator, filterIsNotNullOperator, filterIsEmptyOperator, filterIsNotEmptyOperator, filterStartsWithOperator, filterContainsOperator, filterNotContainsOperator, filterEndsWithOperator, filterGteOperator, filterGtOperator, filterLteOperator, filterLtOperator, filterAfterOrEqualOperator, filterAfterOperator, filterBeforeOperator, filterBeforeOrEqualOperator } from './../messages';
2
11
  var textOperators = [
3
12
  { text: filterContainsOperator, operator: 'contains' },
@@ -62,9 +71,9 @@ var Operators = /** @class */ (function () {
62
71
  * - { text: 'filter.isNotEmptyOperator', operator: 'isnotempty' }
63
72
  */
64
73
  get: function () {
65
- return textOperators.slice();
74
+ return __spreadArray([], textOperators, true);
66
75
  },
67
- enumerable: true,
76
+ enumerable: false,
68
77
  configurable: true
69
78
  });
70
79
  Object.defineProperty(Operators, "numeric", {
@@ -83,9 +92,9 @@ var Operators = /** @class */ (function () {
83
92
  * - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
84
93
  */
85
94
  get: function () {
86
- return numericOperators.slice();
95
+ return __spreadArray([], numericOperators, true);
87
96
  },
88
- enumerable: true,
97
+ enumerable: false,
89
98
  configurable: true
90
99
  });
91
100
  Object.defineProperty(Operators, "date", {
@@ -104,9 +113,9 @@ var Operators = /** @class */ (function () {
104
113
  * - { text: 'filter.isNotNullOperator', operator: 'isnotnull' }
105
114
  */
106
115
  get: function () {
107
- return dateOperators.slice();
116
+ return __spreadArray([], dateOperators, true);
108
117
  },
109
- enumerable: true,
118
+ enumerable: false,
110
119
  configurable: true
111
120
  });
112
121
  Object.defineProperty(Operators, "boolean", {
@@ -119,9 +128,9 @@ var Operators = /** @class */ (function () {
119
128
  * - { text: 'filter.notEqOperator', operator: 'neq' }
120
129
  */
121
130
  get: function () {
122
- return booleanOperators.slice();
131
+ return __spreadArray([], booleanOperators, true);
123
132
  },
124
- enumerable: true,
133
+ enumerable: false,
125
134
  configurable: true
126
135
  });
127
136
  return Operators;
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -22,6 +24,15 @@ var __assign = (this && this.__assign) || function () {
22
24
  };
23
25
  return __assign.apply(this, arguments);
24
26
  };
27
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
28
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
29
+ if (ar || !(i in from)) {
30
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
31
+ ar[i] = from[i];
32
+ }
33
+ }
34
+ return to.concat(ar || Array.prototype.slice.call(from));
35
+ };
25
36
  import * as React from 'react';
26
37
  import { createFilterComponent } from './FilterComponent';
27
38
  import { DropDownList } from '@progress/kendo-react-dropdowns';
@@ -48,7 +59,7 @@ var settings = {
48
59
  return;
49
60
  }
50
61
  var filterResult = current ?
51
- filter.map(function (f) { return f.field === field ? __assign({}, current, { value: value }) : f; }) : filter.concat([{ value: value, field: field, operator: booleanOperator }]);
62
+ filter.map(function (f) { return f.field === field ? __assign(__assign({}, current), { value: value }) : f; }) : __spreadArray(__spreadArray([], filter, true), [{ value: value, field: field, operator: booleanOperator }], false);
52
63
  cellProps.onFilterChange.call(undefined, {
53
64
  filter: filterResult,
54
65
  field: field,
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -0,0 +1 @@
1
+ export {};
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -22,6 +24,15 @@ var __assign = (this && this.__assign) || function () {
22
24
  };
23
25
  return __assign.apply(this, arguments);
24
26
  };
27
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
28
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
29
+ if (ar || !(i in from)) {
30
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
31
+ ar[i] = from[i];
32
+ }
33
+ }
34
+ return to.concat(ar || Array.prototype.slice.call(from));
35
+ };
25
36
  import * as React from 'react';
26
37
  import { Button } from '@progress/kendo-react-buttons';
27
38
  import { classNames } from '@progress/kendo-react-common';
@@ -43,7 +54,7 @@ export var createFilterComponent = function (settings) {
43
54
  var _a = _this.props, _b = _a.filter, filter = _b === void 0 ? [] : _b, _c = _a.field, field = _c === void 0 ? '' : _c;
44
55
  var existing = _this.findCellFilter();
45
56
  var filterResult = existing ?
46
- filter.map(function (f) { return f.field === field ? __assign({}, existing, { value: value }) : f; }) : filter.concat([__assign({}, settings.emptyFilter, { value: value, field: field })]);
57
+ filter.map(function (f) { return f.field === field ? __assign(__assign({}, existing), { value: value }) : f; }) : __spreadArray(__spreadArray([], filter, true), [__assign(__assign({}, settings.emptyFilter), { value: value, field: field })], false);
47
58
  _this.filterChange({
48
59
  filter: filterResult,
49
60
  field: field,
@@ -55,7 +66,7 @@ export var createFilterComponent = function (settings) {
55
66
  var _a = _this.props, _b = _a.filter, filter = _b === void 0 ? [] : _b, _c = _a.field, field = _c === void 0 ? '' : _c;
56
67
  var existing = _this.findCellFilter();
57
68
  var filterResult = existing ?
58
- filter.map(function (f) { return f.field === field ? __assign({}, existing, { operator: operator }) : f; }) : filter.concat([__assign({}, settings.emptyFilter, { field: field, operator: operator })]);
69
+ filter.map(function (f) { return f.field === field ? __assign(__assign({}, existing), { operator: operator }) : f; }) : __spreadArray(__spreadArray([], filter, true), [__assign(__assign({}, settings.emptyFilter), { field: field, operator: operator })], false);
59
70
  _this.filterChange({
60
71
  filter: filterResult,
61
72
  field: field,
@@ -79,7 +90,7 @@ export var createFilterComponent = function (settings) {
79
90
  FilterComponent.prototype.render = function () {
80
91
  var _a;
81
92
  var _b = this.props, _c = _b.clearButtonTitle, clearButtonTitle = _c === void 0 ? '' : _c, _d = _b.operators, operators = _d === void 0 ? [] : _d;
82
- var filter = this.findCellFilter() || __assign({}, settings.emptyFilter, { operator: '' });
93
+ var filter = this.findCellFilter() || __assign(__assign({}, settings.emptyFilter), { operator: '' });
83
94
  var operator = filter.operator, value = filter.value;
84
95
  var operatorComponentProps = {
85
96
  value: operators.find(function (item) { return item.operator === operator; }) || null,
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -1,4 +1,7 @@
1
1
  export * from './FilterComponent';
2
+ export * from './FilterComponentProps';
3
+ export * from './FilterCellProps';
4
+ export * from './FilterOperator';
2
5
  export * from './BooleanFilter';
3
6
  export * from './DateFilter';
4
7
  export * from './NumericFilter';
@@ -0,0 +1 @@
1
+ export {};
@@ -1,13 +1,13 @@
1
1
  import { ComponentType } from 'react';
2
- import { HeaderCellProps } from './HeaderCell';
3
- import { CellProps } from './CellProps';
4
- import { FilterCellProps } from '../filteringCells/FilterCellProps';
2
+ import { HeaderCellProps as HeaderCellPropsDefault } from './HeaderCell';
3
+ import { CellProps as CellPropsDefault } from './CellProps';
4
+ import { FilterCellProps as FilterCellPropsDefault } from '../filteringCells/FilterCellProps';
5
5
  import { ColumnSortSettings } from './SortSettings';
6
6
  import { ColumnMenuProps } from '../columnmenu';
7
7
  /**
8
8
  * @hidden
9
9
  */
10
- export interface ColumnBaseProps {
10
+ export interface ColumnBaseProps<CellProps = CellPropsDefault> {
11
11
  /**
12
12
  * The field to which the column is bound.
13
13
  */
@@ -86,11 +86,11 @@ export interface ColumnBaseProps {
86
86
  /**
87
87
  * @hidden
88
88
  */
89
- export interface TreeColumnBaseProps extends ColumnBaseProps {
89
+ export interface TreeColumnBaseProps<CellProps = CellPropsDefault, HeaderCellProps = HeaderCellPropsDefault, FilterCellProps = FilterCellPropsDefault> extends ColumnBaseProps<CellProps> {
90
90
  /**
91
91
  * A collection of child columns.
92
92
  */
93
- children?: TreeColumnBaseProps[];
93
+ children?: TreeColumnBaseProps<CellProps, HeaderCellProps, FilterCellProps>[];
94
94
  /**
95
95
  * The column menu component. Pass the [ColumnMenuTextColumn]({% slug api_data-tools_columnmenutextcolumn %}),
96
96
  * [ColumnMenuNumericColumn]({% slug api_data-tools_columnmenunumericcolumn %}),
@@ -124,7 +124,7 @@ export interface TreeColumnBaseProps extends ColumnBaseProps {
124
124
  /**
125
125
  * @hidden
126
126
  */
127
- export interface ExtendedColumnProps extends TreeColumnBaseProps {
127
+ export interface ExtendedColumnProps<CellProps = CellPropsDefault, HeaderCellProps = HeaderCellPropsDefault, FilterCellProps = FilterCellPropsDefault> extends TreeColumnBaseProps<CellProps, HeaderCellProps, FilterCellProps> {
128
128
  declarationIndex: number;
129
129
  parentIndex: number;
130
130
  colSpan: number;
@@ -132,7 +132,7 @@ export interface ExtendedColumnProps extends TreeColumnBaseProps {
132
132
  depth: number;
133
133
  kFirst?: boolean;
134
134
  index: number;
135
- children: ExtendedColumnProps[];
135
+ children: ExtendedColumnProps<CellProps, HeaderCellProps, FilterCellProps>[];
136
136
  left: number;
137
137
  right: number;
138
138
  rightBorder: boolean;
@@ -8,7 +8,7 @@ import { filterAriaLabel, messages } from '../messages';
8
8
  */
9
9
  export var FILTER_ROW_CLASS = 'k-filter-row';
10
10
  var headerCellClassName = function (sort, field, locked) {
11
- var result = "" + (locked ? 'k-grid-header-sticky' : '');
11
+ var result = "".concat(locked ? 'k-grid-header-sticky' : '');
12
12
  if (sort.some(function (descriptor) { return descriptor.field === field; })) {
13
13
  result += ' k-sorted';
14
14
  }
@@ -2,10 +2,12 @@ var __extends = (this && this.__extends) || (function () {
2
2
  var extendStatics = function (d, b) {
3
3
  extendStatics = Object.setPrototypeOf ||
4
4
  ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
5
+ function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
6
  return extendStatics(d, b);
7
7
  };
8
8
  return function (d, b) {
9
+ if (typeof b !== "function" && b !== null)
10
+ throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
9
11
  extendStatics(d, b);
10
12
  function __() { this.constructor = d; }
11
13
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
@@ -44,4 +44,4 @@ export interface HeaderCellProps extends HeaderCellBaseProps {
44
44
  /**
45
45
  * @hidden
46
46
  */
47
- export declare function HeaderCell(props: HeaderCellProps): any;
47
+ export declare function HeaderCell(props: HeaderCellProps): JSX.Element;