@progress/kendo-react-grid 9.4.0-develop.2 → 9.4.0-develop.20

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 (184) hide show
  1. package/Grid.js +1 -1
  2. package/Grid.mjs +4 -5
  3. package/GridClientContextReader.js +2 -1
  4. package/GridClientContextReader.mjs +15 -14
  5. package/GridClientWrapper.js +2 -1
  6. package/GridClientWrapper.mjs +436 -381
  7. package/GridColumn.js +1 -1
  8. package/GridColumn.mjs +4 -5
  9. package/GridComponent.js +1 -1
  10. package/GridComponent.mjs +342 -306
  11. package/GridSearchBox.js +8 -0
  12. package/GridSearchBox.mjs +35 -0
  13. package/GridState.js +2 -1
  14. package/GridState.mjs +79 -67
  15. package/GridToolbar.js +1 -1
  16. package/GridToolbar.mjs +5 -6
  17. package/GridWatermarkOverlay.js +2 -1
  18. package/GridWatermarkOverlay.mjs +2 -2
  19. package/NOTICE.txt +40 -51
  20. package/StatusBar.js +1 -1
  21. package/StatusBar.mjs +0 -1
  22. package/VirtualScroll.js +1 -1
  23. package/VirtualScroll.mjs +0 -1
  24. package/VirtualScrollFixed.js +1 -1
  25. package/VirtualScrollFixed.mjs +9 -10
  26. package/cells/GridCell.js +1 -1
  27. package/cells/GridCell.mjs +25 -23
  28. package/cells/GridDetailCell.js +1 -1
  29. package/cells/GridDetailCell.mjs +5 -6
  30. package/cells/GridDetailHierarchyCell.js +1 -1
  31. package/cells/GridDetailHierarchyCell.mjs +4 -5
  32. package/cells/GridEditCell.js +1 -1
  33. package/cells/GridEditCell.mjs +6 -7
  34. package/cells/GridFilterCell.js +2 -1
  35. package/cells/GridGroupCell.js +1 -1
  36. package/cells/GridGroupCell.mjs +11 -12
  37. package/cells/GridHierarchyCell.js +1 -1
  38. package/cells/GridHierarchyCell.mjs +7 -8
  39. package/cells/GridRowReorderCell.js +1 -1
  40. package/cells/GridRowReorderCell.mjs +3 -4
  41. package/cells/GridSelectionCell.js +1 -1
  42. package/cells/GridSelectionCell.mjs +12 -13
  43. package/cells/client/DetailCellContainer.js +2 -1
  44. package/cells/client/DetailCellContainer.mjs +2 -2
  45. package/cells/client/GridCellContainer.js +2 -1
  46. package/cells/client/GridEditCellContainer.js +2 -1
  47. package/cells/client/GridEditCellEditor.js +2 -1
  48. package/cells/client/GridEditCellEditor.mjs +14 -14
  49. package/cells/client/GridGroupCellContainer.js +2 -1
  50. package/cells/client/GridGroupCellContainer.mjs +39 -39
  51. package/cells/client/GridGroupCellToggle.js +2 -1
  52. package/cells/client/GridGroupCellToggle.mjs +3 -3
  53. package/cells/client/GridHierarchyCellContainer.js +2 -1
  54. package/cells/client/GridHierarchyCellToggle.js +2 -1
  55. package/cells/client/GridHierarchyCellToggle.mjs +15 -15
  56. package/cells/client/GridRowReorderContainer.js +2 -1
  57. package/cells/client/GridRowReorderContainer.mjs +3 -3
  58. package/cells/client/GridSelectionCellContainer.js +2 -1
  59. package/cells/client/GridSelectionCellInput.js +2 -1
  60. package/cells/client/GridSelectionCellInput.mjs +3 -3
  61. package/columnMenu/GridColumnMenuCheckboxFilter.js +2 -1
  62. package/columnMenu/GridColumnMenuCheckboxFilter.mjs +56 -55
  63. package/columnMenu/GridColumnMenuColumnsChooser.js +9 -0
  64. package/columnMenu/GridColumnMenuColumnsChooser.mjs +82 -0
  65. package/columnMenu/GridColumnMenuColumnsList.js +2 -1
  66. package/columnMenu/GridColumnMenuColumnsList.mjs +16 -16
  67. package/columnMenu/GridColumnMenuFilter.js +2 -1
  68. package/columnMenu/GridColumnMenuFilterCell.js +2 -1
  69. package/columnMenu/GridColumnMenuFilterCell.mjs +3 -3
  70. package/columnMenu/GridColumnMenuFilterUI.js +2 -1
  71. package/columnMenu/GridColumnMenuGroup.js +2 -1
  72. package/columnMenu/GridColumnMenuGroup.mjs +5 -5
  73. package/columnMenu/GridColumnMenuItem.js +2 -1
  74. package/columnMenu/GridColumnMenuItem.mjs +2 -2
  75. package/columnMenu/GridColumnMenuItemContent.js +2 -1
  76. package/columnMenu/GridColumnMenuItemContent.mjs +4 -4
  77. package/columnMenu/GridColumnMenuItemGroup.js +2 -1
  78. package/columnMenu/GridColumnMenuItemGroup.mjs +4 -4
  79. package/columnMenu/GridColumnMenuSort.js +2 -1
  80. package/columnMenu/GridColumnMenuSort.mjs +8 -8
  81. package/columnMenu/GridColumnMenuWrapper.js +2 -1
  82. package/components/GridContainerElementContainer.js +2 -1
  83. package/components/GridCustomCellClientContainer.js +2 -1
  84. package/components/GridCustomCellClientContainer.mjs +2 -2
  85. package/components/GridDragClue.js +2 -1
  86. package/components/GridDragClue.mjs +5 -5
  87. package/components/GridDraggableRowsContainer.js +2 -1
  88. package/components/GridDropClue.js +2 -1
  89. package/components/GridDropClue.mjs +5 -5
  90. package/components/GridElementContainer.js +2 -1
  91. package/components/GridElementContainer.mjs +6 -6
  92. package/components/GridLoader.js +9 -0
  93. package/components/GridLoader.mjs +22 -0
  94. package/components/PagerContainer.js +2 -1
  95. package/components/PagerContainer.mjs +4 -4
  96. package/components/VirtualScrollHeightContainer.js +2 -1
  97. package/components/VirtualScrollHeightContainer.mjs +2 -2
  98. package/components/colGroup/GridColGroup.js +2 -1
  99. package/components/colGroup/GridColGroup.mjs +5 -5
  100. package/components/icons/reorder-row-svg.js +2 -1
  101. package/components/icons/reorder-row-svg.mjs +2 -2
  102. package/components/noRecords/GridNoRecords.js +2 -1
  103. package/components/noRecords/GridNoRecords.mjs +5 -5
  104. package/components/noRecords/GridNoRecordsContainer.js +2 -1
  105. package/components/noRecords/GridNoRecordsContainer.mjs +4 -4
  106. package/components/table/GridTable.js +2 -1
  107. package/components/table/GridTable.mjs +4 -4
  108. package/components/table/GridTableBody.js +2 -1
  109. package/components/table/GridTableBody.mjs +2 -2
  110. package/components/table/GridTableScrollable.js +2 -1
  111. package/components/table/GridTableScrollable.mjs +6 -6
  112. package/components/utils.js +1 -1
  113. package/components/utils.mjs +0 -1
  114. package/constants/index.js +1 -1
  115. package/constants/index.mjs +0 -1
  116. package/contextMenu/GridContextMenu.js +2 -1
  117. package/contextMenu/GridContextMenu.mjs +3 -3
  118. package/contextMenu/enums.js +1 -1
  119. package/contextMenu/enums.mjs +0 -1
  120. package/dist/cdn/js/kendo-react-grid.js +8 -1
  121. package/drag/ColumnDraggable.js +2 -1
  122. package/drag/ColumnDraggable.mjs +7 -7
  123. package/drag/ColumnResize.js +1 -1
  124. package/drag/ColumnResize.mjs +0 -1
  125. package/drag/CommonDragLogic.js +1 -1
  126. package/drag/CommonDragLogic.mjs +0 -1
  127. package/drag/GroupingIndicator.js +2 -1
  128. package/drag/GroupingIndicator.mjs +11 -11
  129. package/filterCommon.js +1 -1
  130. package/filterCommon.mjs +4 -5
  131. package/footer/Footer.js +2 -1
  132. package/footer/FooterCell.js +1 -1
  133. package/footer/FooterCell.mjs +3 -4
  134. package/footer/FooterRow.js +1 -1
  135. package/footer/FooterRow.mjs +6 -7
  136. package/footer/client/FooterCellContainer.js +2 -1
  137. package/footer/client/FooterCellContainer.mjs +5 -5
  138. package/header/FilterRow.js +1 -1
  139. package/header/FilterRow.mjs +41 -43
  140. package/header/GridHeaderCell.js +2 -1
  141. package/header/GridHeaderCell.mjs +4 -4
  142. package/header/GridHeaderSelectionCell.js +2 -1
  143. package/header/GroupPanel.js +2 -1
  144. package/header/Header.js +2 -1
  145. package/header/HeaderRow.js +1 -1
  146. package/header/HeaderRow.mjs +33 -35
  147. package/header/client/GridFilterCellContainer.js +2 -1
  148. package/header/client/GridFilterCellContainer.mjs +7 -7
  149. package/header/client/GridFilterCellElementContainer.js +2 -1
  150. package/header/client/GridHeaderCellContainer.js +2 -1
  151. package/header/client/GridHeaderCellContainer.mjs +20 -18
  152. package/header/client/GridHeaderCellElementContainer.js +2 -1
  153. package/header/client/GridHeaderCellElementContainer.mjs +10 -10
  154. package/header/client/GridHeaderRowContainer.js +2 -1
  155. package/header/client/GridHeaderRowReorderCell.js +2 -1
  156. package/header/client/GridHeaderRowReorderCell.mjs +2 -2
  157. package/header/client/HeaderCellResizer.js +2 -1
  158. package/header/client/HeaderRowDraggable.js +2 -1
  159. package/index.d.mts +211 -5
  160. package/index.d.ts +211 -5
  161. package/index.js +1 -1
  162. package/index.mjs +71 -68
  163. package/messages/index.js +1 -1
  164. package/messages/index.mjs +38 -37
  165. package/messages/messagesMap.js +1 -1
  166. package/messages/messagesMap.mjs +2 -3
  167. package/package-metadata.js +1 -1
  168. package/package-metadata.mjs +2 -3
  169. package/package.json +13 -12
  170. package/paging/GridPagerSettings.js +1 -1
  171. package/paging/GridPagerSettings.mjs +6 -7
  172. package/rows/GridDetailRow.js +1 -1
  173. package/rows/GridDetailRow.mjs +2 -3
  174. package/rows/GridRow.js +2 -1
  175. package/rows/GridRow.mjs +45 -45
  176. package/sortCommon.js +8 -0
  177. package/{interfaces/GridSortSettings.mjs → sortCommon.mjs} +0 -1
  178. package/utils/_clientModule.js +2 -1
  179. package/utils/_clientModule.mjs +2 -2
  180. package/utils/_serverModule.js +1 -1
  181. package/utils/_serverModule.mjs +0 -1
  182. package/utils/index.js +1 -1
  183. package/utils/index.mjs +104 -99
  184. package/interfaces/GridSortSettings.js +0 -8
@@ -6,22 +6,23 @@
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
8
  "use client";
9
- import * as a from "react";
10
- import { useDir as St, setScrollbarWidth as we, canUseDOM as q, getter as ue, getActiveElement as kt, getScrollbarWidth as Dt, RowHeightService as ye } from "@progress/kendo-react-common";
11
- import { getSelectionOptions as G, getEditableOptions as Kt, tableKeyboardNavigation as K, ClipboardService as Mt, TableKeyboardNavigationContext as Tt, getSelectedStateFromKeyDown as At, closestTagName as xe, getColumnIndex as Ht, getRowIndex as Gt, editReducer as Ft, EDIT_ACTION as Lt, getDetailExpandableOptions as zt, detailExpandReducer as Se, getGroupExpandableOptions as Nt, groupExpandReducer as Ot, DETAIL_EXPAND_ACTION as Ut, getSelectedState as ke, updateLeft as Vt, updateRight as Wt } from "@progress/kendo-react-data-tools";
12
- import { ColumnResize as Bt } from "./drag/ColumnResize.mjs";
13
- import { CommonDragLogic as _t } from "./drag/CommonDragLogic.mjs";
14
- import { SAFARI_REGEX as jt } from "./constants/index.mjs";
15
- import { getDefaultHeadContextMenuItems as qt, getDefaultBodyContextMenuItems as Xt, sanitizeColumns as $t, firefox as De, firefoxMaxHeight as Ke } from "./utils/index.mjs";
16
- import { VirtualScrollFixed as Me } from "./VirtualScrollFixed.mjs";
17
- import { VirtualScroll as Jt } from "./VirtualScroll.mjs";
18
- import { GridContextMenu as Yt } from "./contextMenu/GridContextMenu.mjs";
19
- import { GridContextMenuAnchorPart as Te } from "./contextMenu/enums.mjs";
20
- import { normalize as Qt, firstLevelSortSeqMap as Zt } from "./interfaces/GridSortSettings.mjs";
21
- const pt = a.createContext(void 0), ur = (t) => {
22
- const R = t.gridProps.isClient, [b, ge] = a.useState({}), Ae = (e) => {
23
- e.event.preventDefault(), ge({
24
- ...b,
9
+ import * as i from "react";
10
+ import { useDir as Kt, setScrollbarWidth as ke, canUseDOM as q, getter as X, getActiveElement as Mt, getScrollbarWidth as Tt, RowHeightService as De } from "@progress/kendo-react-common";
11
+ import { getSelectionOptions as $, getEditableOptions as At, tableKeyboardNavigation as M, ClipboardService as Ht, TableKeyboardNavigationContext as Ft, getSelectedStateFromKeyDown as Gt, closestTagName as Ke, getColumnIndex as zt, getRowIndex as Lt, editReducer as Nt, EDIT_ACTION as Ot, getDetailExpandableOptions as Bt, detailExpandReducer as Me, getGroupExpandableOptions as Ut, groupExpandReducer as Vt, DETAIL_EXPAND_ACTION as Wt, getSelectedState as Te, updateLeft as _t, updateRight as jt } from "@progress/kendo-react-data-tools";
12
+ import { ColumnResize as qt } from "./drag/ColumnResize.mjs";
13
+ import { CommonDragLogic as Xt } from "./drag/CommonDragLogic.mjs";
14
+ import { SAFARI_REGEX as $t } from "./constants/index.mjs";
15
+ import { getDefaultHeadContextMenuItems as Jt, getDefaultBodyContextMenuItems as Yt, sanitizeColumns as Qt, firefox as Ae, firefoxMaxHeight as He } from "./utils/index.mjs";
16
+ import { VirtualScrollFixed as Fe } from "./VirtualScrollFixed.mjs";
17
+ import { VirtualScroll as Zt } from "./VirtualScroll.mjs";
18
+ import { GridContextMenu as pt } from "./contextMenu/GridContextMenu.mjs";
19
+ import { GridContextMenuAnchorPart as Ge } from "./contextMenu/enums.mjs";
20
+ import { normalize as er, firstLevelSortSeqMap as tr } from "./sortCommon.mjs";
21
+ const rr = i.createContext(void 0), mr = (t) => {
22
+ var xe, Se;
23
+ const C = t.gridProps.isClient, [h, fe] = i.useState({}), ze = (e) => {
24
+ e.event.preventDefault(), fe({
25
+ ...h,
25
26
  show: !0,
26
27
  offset: {
27
28
  left: e.event.pageX,
@@ -30,39 +31,39 @@ const pt = a.createContext(void 0), ur = (t) => {
30
31
  dataItem: e.dataItem,
31
32
  field: e.field
32
33
  });
33
- }, fe = () => {
34
- ge({});
35
- }, f = a.useMemo(() => t.columnsRef.current.find((e) => e.field === b.field), [t.columnsRef, b]), me = a.useMemo(() => {
36
- const e = t.gridProps.sortable && (f == null ? void 0 : f.sortable);
37
- return qt({
34
+ }, me = () => {
35
+ fe({});
36
+ }, m = i.useMemo(() => t.columnsRef.current.find((e) => e.field === h.field), [t.columnsRef, h]), Pe = i.useMemo(() => {
37
+ const e = t.gridProps.sortable && (m == null ? void 0 : m.sortable);
38
+ return Jt({
38
39
  sortable: !!e,
39
- selectable: G(t.gridProps.selectable).enabled,
40
+ selectable: $(t.gridProps.selectable).enabled,
40
41
  clipboard: !!t.gridProps.clipboard
41
42
  });
42
- }, [f, t.gridProps.sortable, t.gridProps.selectable, t.gridProps.clipboard]), Pe = a.useMemo(() => {
43
- const e = t.gridProps.sortable && (f == null ? void 0 : f.sortable);
44
- return Xt({
43
+ }, [m, t.gridProps.sortable, t.gridProps.selectable, t.gridProps.clipboard]), he = i.useMemo(() => {
44
+ const e = t.gridProps.sortable && (m == null ? void 0 : m.sortable);
45
+ return Yt({
45
46
  sortable: !!e,
46
- selectable: G(t.gridProps.selectable).enabled,
47
+ selectable: $(t.gridProps.selectable).enabled,
47
48
  clipboard: !!t.gridProps.clipboard
48
49
  });
49
- }, [f, t.gridProps.sortable, t.gridProps.selectable, t.gridProps.clipboard]), He = a.useMemo(() => {
50
- const e = (f == null ? void 0 : f.contextMenu) || t.gridProps.contextMenu, r = typeof e == "function" ? e(b) : e;
51
- if (r && b.offset) {
52
- const n = b.dataItem ? Te.body : Te.head, o = r[n];
53
- return o === !1 ? void 0 : o === !0 || o === void 0 ? b.dataItem ? Pe : me : o;
50
+ }, [m, t.gridProps.sortable, t.gridProps.selectable, t.gridProps.clipboard]), Le = i.useMemo(() => {
51
+ const e = (m == null ? void 0 : m.contextMenu) || t.gridProps.contextMenu, r = typeof e == "function" ? e(h) : e;
52
+ if (r && h.offset) {
53
+ const n = h.dataItem ? Ge.body : Ge.head, o = r[n], a = h.dataItem ? he : Pe;
54
+ return o === !1 ? void 0 : o === !0 || o === void 0 ? a : o;
54
55
  }
55
- }, [t.gridProps.contextMenu, b, Pe, me, f]), Ge = (e) => {
56
- var c;
56
+ }, [t.gridProps.contextMenu, h, he, Pe, m]), Ne = (e) => {
57
+ var d;
57
58
  const r = e.event.item, n = {
58
- target: I.current,
59
+ target: R.current,
59
60
  syntheticEvent: e.event.syntheticEvent,
60
61
  nativeEvent: e.event.nativeEvent,
61
62
  menuItem: r,
62
63
  ...e
63
64
  };
64
65
  t.gridProps.onContextMenuItemClick && s(t.gridProps.onContextMenuItemClick, n);
65
- const o = Y(), i = {
66
+ const o = Z(), a = {
66
67
  selectedField: t.gridProps.selectedField || "",
67
68
  componentId: t.id,
68
69
  dataItems: o,
@@ -76,34 +77,34 @@ const pt = a.createContext(void 0), ur = (t) => {
76
77
  metaKey: !1,
77
78
  shiftKey: !1,
78
79
  isDrag: !1,
79
- ...G(t.gridProps.selectable),
80
+ ...$(t.gridProps.selectable),
80
81
  ...n
81
82
  };
82
- switch ((c = r.data) == null ? void 0 : c.action) {
83
+ switch ((d = r.data) == null ? void 0 : d.action) {
83
84
  case "SortCommand":
84
- if (f) {
85
+ if (m) {
85
86
  const l = r.name ? r.name.toLowerCase().includes("asc") ? "asc" : r.name.toLowerCase().includes("desc") ? "desc" : void 0 : void 0;
86
- he(e.event.syntheticEvent, f, l);
87
+ be(e.event.syntheticEvent, m, l);
87
88
  }
88
89
  break;
89
90
  case "SelectRowCommand":
90
- Ye(i);
91
+ et(a);
91
92
  break;
92
93
  case "SelectAllRowsCommand":
93
- Je(i);
94
+ pe(a);
94
95
  break;
95
96
  case "ClearSelectionCommand":
96
- Qe(i);
97
+ tt(a);
97
98
  break;
98
99
  }
99
- fe();
100
- }, F = () => {
100
+ me();
101
+ }, z = () => {
101
102
  const e = u.current.filter((r) => r.declarationIndex >= 0 && r.parentIndex === -1);
102
- return $t(e);
103
- }, Fe = (e, r, n) => {
104
- if (t.gridProps.onContextMenu && R) {
103
+ return Qt(e);
104
+ }, Oe = (e, r, n) => {
105
+ if (t.gridProps.onContextMenu && C) {
105
106
  const o = {
106
- target: I.current,
107
+ target: R.current,
107
108
  syntheticEvent: e,
108
109
  nativeEvent: e.nativeEvent,
109
110
  dataItem: r,
@@ -111,61 +112,63 @@ const pt = a.createContext(void 0), ur = (t) => {
111
112
  };
112
113
  s(t.gridProps.onContextMenu, o);
113
114
  }
114
- t.gridProps.contextMenu && Ae({
115
+ t.gridProps.contextMenu && ze({
115
116
  event: e,
116
117
  dataItem: r,
117
118
  field: n
118
119
  });
119
- }, Le = (e) => {
120
+ }, Be = (e) => {
120
121
  if (e.target !== e.currentTarget)
121
122
  return;
122
- clearTimeout(de.current), d.current && (d.current.table = w.current);
123
+ clearTimeout(le.current), c.current && (c.current.table = w.current);
123
124
  const r = e.currentTarget.scrollLeft, n = e.currentTarget.scrollTop, o = t.gridProps.scrollable === "virtual";
124
- t.gridProps.columnVirtualization && (!o || n === ie.current) && (de.current = window.setTimeout(() => {
125
- p();
126
- }, 0)), t.gridProps.scrollLeftRef && (t.gridProps.scrollLeftRef.current = r), A.current && A.current.setScrollLeft(r), T.current && T.current.setScrollLeft(r), d.current && n !== ie.current && d.current.scrollHandler(e), t.gridProps.onScroll && R && s(t.gridProps.onScroll, {
127
- ...m(e)
128
- }), ie.current = n;
129
- }, ze = (e) => {
130
- var c, l, P, h;
131
- K.onKeyDown(e, {
125
+ t.gridProps.columnVirtualization && (!o || n === ce.current) && (le.current = window.setTimeout(() => {
126
+ te();
127
+ }, 0)), t.gridProps.scrollLeftRef && (t.gridProps.scrollLeftRef.current = r), F.current && F.current.setScrollLeft(r), H.current && H.current.setScrollLeft(r), c.current && n !== ce.current && c.current.scrollHandler(e), t.gridProps.onScroll && C && s(t.gridProps.onScroll, {
128
+ ...P(e)
129
+ }), ce.current = n;
130
+ }, Ue = (e) => {
131
+ var n, o, a, d;
132
+ M.onKeyDown(e, {
132
133
  navigatable: t.gridProps.navigatable || !1,
133
- contextStateRef: v,
134
- navigationStateRef: x,
135
- onNavigationAction: Oe,
136
- columns: F()
137
- }), K.onGetSnapshotBeforeUpdate({
134
+ contextStateRef: y,
135
+ navigationStateRef: k,
136
+ onNavigationAction: We,
137
+ columns: z()
138
+ }), M.onGetSnapshotBeforeUpdate({
138
139
  document: E(),
139
- contextStateRef: v,
140
- navigationStateRef: x
140
+ contextStateRef: y,
141
+ navigationStateRef: k
141
142
  });
142
- const { mode: r, cell: n, enabled: o } = G(t.gridProps.selectable), i = {
143
+ const r = {
143
144
  dataItems: O(),
144
- mode: r,
145
- cell: n,
145
+ mode: b.mode,
146
+ cell: b.cell,
146
147
  componentId: t.id,
147
148
  selectedField: t.gridProps.selectedField,
148
- ...m(e)
149
+ ...P(e)
149
150
  };
150
- if (t.gridProps.onKeyDown && R && s(t.gridProps.onKeyDown, i), !t.gridProps.selectedField && o && t.gridProps.dataItemKey) {
151
- const g = At({
152
- event: i,
153
- selectedState: (c = t.gridProps.select) != null ? c : {},
151
+ if (t.gridProps.onKeyDown && C && s(t.gridProps.onKeyDown, r), !t.gridProps.selectedField && b.enabled && t.gridProps.dataItemKey) {
152
+ const l = Gt({
153
+ event: r,
154
+ selectedState: (n = t.gridProps.select) != null ? n : {},
154
155
  dataItemKey: t.gridProps.dataItemKey
155
156
  });
156
- if (g === t.gridProps.select)
157
+ if (l === t.gridProps.select)
157
158
  return;
158
- const D = e.target, wt = xe(D, "TD"), yt = xe(D, "TR"), se = Ht(wt), H = Gt(yt);
159
- if (se !== void 0 && H !== void 0) {
160
- const xt = Array.isArray(t.gridProps.data) ? (l = t.gridProps.data) == null ? void 0 : l[H] : (h = (P = t.gridProps.data) == null ? void 0 : P.data) == null ? void 0 : h[H];
159
+ const f = e.target, I = Ke(f, "TD"), g = Ke(f, "TR"), x = zt(I), G = Lt(g);
160
+ if (x !== void 0 && G !== void 0) {
161
+ const ge = Array.isArray(t.gridProps.data) ? (o = t.gridProps.data) == null ? void 0 : o[G] : (d = (a = t.gridProps.data) == null ? void 0 : a.data) == null ? void 0 : d[G];
161
162
  t.gridProps.onSelectionChange && s(t.gridProps.onSelectionChange, {
162
- ...i,
163
- select: g,
164
- dataItem: xt,
165
- startRowIndex: H,
166
- startColIndex: se,
167
- endRowIndex: H,
168
- endColIndex: se,
163
+ ...r,
164
+ select: l,
165
+ dataItem: ge,
166
+ startRowIndex: G,
167
+ startColIndex: x,
168
+ startDataItem: ge,
169
+ endDataItem: ge,
170
+ endRowIndex: G,
171
+ endColIndex: x,
169
172
  ctrlKey: e.ctrlKey,
170
173
  altKey: e.altKey,
171
174
  metaKey: e.metaKey,
@@ -174,83 +177,83 @@ const pt = a.createContext(void 0), ur = (t) => {
174
177
  });
175
178
  }
176
179
  }
177
- }, Ne = (e) => {
178
- K.onFocus(e, {
180
+ }, Ve = (e) => {
181
+ M.onFocus(e, {
179
182
  navigatable: !!t.gridProps.navigatable,
180
- contextStateRef: v
183
+ contextStateRef: y
181
184
  });
182
- }, Oe = (e) => {
183
- if (e.action === "moveToNextPage" && pe(e.event), e.action === "moveToPrevPage" && et(e.event), e.focusElement && e.action === "reorderToRight") {
185
+ }, We = (e) => {
186
+ if (e.action === "moveToNextPage" && nt(e.event), e.action === "moveToPrevPage" && ot(e.event), e.focusElement && e.action === "reorderToRight") {
184
187
  const r = parseInt(e.focusElement.ariaColIndex, 10) - 1;
185
- r < u.current.length - 1 && $(r, r + 1, e.event);
188
+ r < u.current.length - 1 && Y(r, r + 1, e.event);
186
189
  }
187
190
  if (e.focusElement && e.action === "reorderToLeft") {
188
191
  const r = parseInt(e.focusElement.ariaColIndex, 10) - 1;
189
- r > 0 && $(r, r - 1, e.event);
192
+ r > 0 && Y(r, r - 1, e.event);
190
193
  }
191
- if (t.gridProps.onNavigationAction && R) {
194
+ if (t.gridProps.onNavigationAction && C) {
192
195
  const r = {
193
196
  focusElement: e.focusElement,
194
- ...m(e.event)
197
+ ...P(e.event)
195
198
  };
196
199
  s(t.gridProps.onNavigationAction, r);
197
200
  }
198
- }, Ue = (e, r) => {
201
+ }, _e = (e, r) => {
199
202
  t.gridProps.onRowClick && e.target.nodeName === "TD" && s(t.gridProps.onRowClick, {
200
203
  dataItem: r,
201
- ...m(e)
204
+ ...P(e)
202
205
  });
203
- }, Ve = (e, r) => {
206
+ }, je = (e, r) => {
204
207
  t.gridProps.onRowDoubleClick && e.target.nodeName === "TD" && s(t.gridProps.onRowDoubleClick, {
205
208
  dataItem: r,
206
- ...m(e)
209
+ ...P(e)
207
210
  });
208
- }, We = (e, r, n) => {
209
- if (Ct && vt === "incell" && t.gridProps.dataItemKey) {
210
- const o = Ft(t.gridProps.edit, {
211
- type: Lt.ENTER_FIELD_EDIT,
211
+ }, qe = (e, r, n) => {
212
+ if (ye.enabled && ye.mode === "incell" && t.gridProps.dataItemKey) {
213
+ const o = Nt(t.gridProps.edit, {
214
+ type: Ot.ENTER_FIELD_EDIT,
212
215
  payload: { id: r[t.gridProps.dataItemKey], field: n }
213
216
  });
214
217
  t.gridProps.onEditChange && s(t.gridProps.onEditChange, {
215
218
  edit: o,
216
- ...m(e)
219
+ ...P(e)
217
220
  });
218
221
  }
219
- }, Be = (e, r) => {
222
+ }, Xe = (e, r) => {
220
223
  var o;
221
- if (zt(t.detailExpandable).enabled) {
222
- const i = Se((o = t.gridProps.detailExpand) != null ? o : {}, e);
224
+ if (Bt(t.detailExpandable).enabled) {
225
+ const a = Me((o = t.gridProps.detailExpand) != null ? o : {}, e);
223
226
  t.gridProps.onDetailExpandChange && s(t.gridProps.onDetailExpandChange, {
224
- ...m(r),
225
- detailExpand: i
227
+ ...P(r),
228
+ detailExpand: a
226
229
  });
227
230
  }
228
- }, _e = (e, r) => {
231
+ }, $e = (e, r) => {
229
232
  var o;
230
- const n = Nt(
231
- typeof t.gridProps.groupable == "object" && t.gridProps.groupable.enabled !== !1 ? t.gridProps.groupable.expandable : t.gridProps.groupable
233
+ const n = Ut(
234
+ typeof t.gridProps.groupable == "object" ? t.gridProps.groupable.expandable !== !1 : t.gridProps.groupable
232
235
  );
233
236
  if (n.enabled) {
234
- const i = Ot((o = t.gridProps.groupExpand) != null ? o : [], e, n);
237
+ const a = Vt((o = t.gridProps.groupExpand) != null ? o : [], e, n);
235
238
  t.gridProps.onGroupExpandChange && s(t.gridProps.onGroupExpandChange, {
236
- ...m(r),
237
- groupExpand: i
239
+ ...P(r),
240
+ groupExpand: a
238
241
  });
239
242
  }
240
- }, he = (e, r, n) => {
241
- const { allowUnsort: o, mode: i } = Qt(t.gridProps.sortable || !1, r.sortable || !1), c = (t.gridProps.sort || []).filter((h) => h.field === r.field)[0], l = n || Zt[o][c && c.dir || ""], P = i === "single" ? [] : (t.gridProps.sort || []).filter((h) => h.field !== r.field);
242
- l !== "" && r.field && P.push({ field: r.field, dir: l }), be(P, e);
243
- }, je = (e) => {
243
+ }, be = (e, r, n) => {
244
+ const { allowUnsort: o, mode: a } = er(t.gridProps.sortable || !1, r.sortable || !1), d = (t.gridProps.sort || []).filter((I) => I.field === r.field)[0], l = n || tr[o][d && d.dir || ""], f = a === "single" ? [] : (t.gridProps.sort || []).filter((I) => I.field !== r.field);
245
+ l !== "" && r.field && f.push({ field: r.field, dir: l }), Ie(f, e);
246
+ }, Je = (e) => {
244
247
  var r;
245
248
  if (e.field === t.gridProps.expandField || e._expand || t.gridProps.group && e.field === void 0) {
246
249
  if (t.gridProps.onExpandChange) {
247
- const n = t.gridProps.dataItemKey ? Se((r = t.gridProps.detailExpand) != null ? r : {}, {
248
- type: Ut.SET,
250
+ const n = t.gridProps.dataItemKey ? Me((r = t.gridProps.detailExpand) != null ? r : {}, {
251
+ type: Wt.SET,
249
252
  id: e.dataItem[t.gridProps.dataItemKey],
250
253
  payload: e.value
251
254
  }) : t.gridProps.detailExpand;
252
255
  s(t.gridProps.onExpandChange, {
253
- ...m(e.syntheticEvent),
256
+ ...P(e.syntheticEvent),
254
257
  expand: n,
255
258
  dataItem: e.dataItem,
256
259
  dataIndex: e.dataIndex,
@@ -260,64 +263,67 @@ const pt = a.createContext(void 0), ur = (t) => {
260
263
  return;
261
264
  }
262
265
  t.gridProps.onItemChange && s(t.gridProps.onItemChange, {
263
- ...m(e.syntheticEvent),
266
+ ...P(e.syntheticEvent),
264
267
  dataItem: e.dataItem,
265
268
  dataIndex: e.dataIndex,
266
269
  field: e.field,
267
270
  value: e.value
268
271
  });
269
- }, qe = (e) => {
272
+ }, Ye = (e) => {
270
273
  var r;
271
- if (t.gridProps.onSelectionChange) {
272
- const { event: n, dataItem: o, dataIndex: i, columnIndex: c } = e, { mode: l, cell: P } = G(t.gridProps.selectable), h = {
273
- ...m(n.syntheticEvent),
274
+ if (t.gridProps.onSelectionChange && b.enabled) {
275
+ const { event: n, dataItem: o, dataIndex: a, columnIndex: d } = e, l = {
276
+ ...P(n.syntheticEvent),
274
277
  dataItem: o,
275
- startColIndex: c,
276
- endColIndex: c,
277
- startRowIndex: i,
278
- endRowIndex: i,
278
+ startColIndex: d,
279
+ endColIndex: d,
280
+ startRowIndex: a,
281
+ endRowIndex: a,
279
282
  dataItems: O(),
280
283
  altKey: !1,
281
284
  ctrlKey: !1,
282
285
  shiftKey: !1,
283
286
  metaKey: !1,
284
- mode: l,
285
- cell: P,
287
+ mode: b.mode,
288
+ cell: b.cell,
286
289
  isDrag: !1,
287
290
  componentId: t.id,
288
291
  selectedField: t.gridProps.selectedField || ""
289
292
  };
290
293
  s(t.gridProps.onSelectionChange, {
291
- ...h,
292
- select: t.gridProps.dataItemKey ? ke({
293
- event: h,
294
+ ...l,
295
+ select: t.gridProps.dataItemKey ? Te({
296
+ event: l,
294
297
  selectedState: (r = t.gridProps.select) != null ? r : {},
295
298
  dataItemKey: t.gridProps.dataItemKey
296
299
  }) : {}
297
300
  });
298
301
  }
299
- }, Xe = (e) => {
300
- var r, n, o;
301
- t.gridProps.onHeaderSelectionChange && s(t.gridProps.onHeaderSelectionChange, {
302
- select: e.syntheticEvent.target.checked ? (Array.isArray(t.gridProps.data) ? t.gridProps.data : (n = (r = t.gridProps.data) == null ? void 0 : r.data) != null ? n : []).reduce((i, c) => (t.gridProps.dataItemKey && (i[ue(t.gridProps.dataItemKey)(c)] = !0), i), {}) : {},
303
- field: e.field,
304
- nativeEvent: e.syntheticEvent && e.syntheticEvent.nativeEvent,
305
- syntheticEvent: e.syntheticEvent,
306
- target: I.current,
307
- dataItems: O(),
308
- selectedField: (o = t.gridProps.selectedField) != null ? o : ""
309
- });
302
+ }, Qe = (e) => {
303
+ var r;
304
+ if (t.gridProps.onHeaderSelectionChange && b.enabled) {
305
+ const n = O();
306
+ s(t.gridProps.onHeaderSelectionChange, {
307
+ select: e.syntheticEvent.target.checked ? n.reduce((o, a) => (t.gridProps.dataItemKey && X(t.gridProps.dataItemKey)(a) !== void 0 && (o[X(t.gridProps.dataItemKey)(a)] = !0), o), {}) : {},
308
+ field: e.field,
309
+ nativeEvent: e.syntheticEvent && e.syntheticEvent.nativeEvent,
310
+ syntheticEvent: e.syntheticEvent,
311
+ target: R.current,
312
+ dataItems: n,
313
+ selectedField: (r = t.gridProps.selectedField) != null ? r : ""
314
+ });
315
+ }
310
316
  }, L = (e, r) => {
311
- t.gridProps.onSelectionChange && R && s(t.gridProps.onSelectionChange, {
317
+ t.gridProps.onSelectionChange && C && b.enabled && s(t.gridProps.onSelectionChange, {
312
318
  ...e,
313
319
  select: r
314
320
  });
315
- }, $e = (e) => {
321
+ }, Ze = (e) => {
316
322
  var r;
317
- if (t.gridProps.onSelectionChange) {
318
- const n = Y()[e.startRowIndex], o = Y()[e.endRowIndex], i = {
323
+ if (t.gridProps.onSelectionChange && b.enabled) {
324
+ const n = Z()[e.startRowIndex], o = Z()[e.endRowIndex], a = {
319
325
  syntheticEvent: void 0,
320
- target: I.current,
326
+ target: R.current,
321
327
  selectedField: t.gridProps.selectedField || "",
322
328
  componentId: t.id,
323
329
  dataItems: O(),
@@ -325,18 +331,18 @@ const pt = a.createContext(void 0), ur = (t) => {
325
331
  startDataItem: n,
326
332
  endDataItem: o,
327
333
  ...e
328
- }, c = ke({
329
- event: i,
334
+ }, d = Te({
335
+ event: a,
330
336
  selectedState: (r = t.gridProps.select) != null ? r : {},
331
337
  // Thats kinda strange, even through the `dataItemKey` is required by the `getSelectedState`
332
338
  // it does work correctly even without it
333
339
  dataItemKey: t.gridProps.dataItemKey
334
340
  });
335
- L(i, c);
341
+ L(a, d);
336
342
  }
337
- }, Je = (e) => {
338
- if (t.gridProps.onSelectionChange) {
339
- const r = e.dataItems[0], n = e.dataItems[e.dataItems.length - 1], o = {}, i = {
343
+ }, pe = (e) => {
344
+ if (t.gridProps.onSelectionChange && b.enabled) {
345
+ const r = e.dataItems[0], n = e.dataItems[e.dataItems.length - 1], o = {}, a = {
340
346
  ...e,
341
347
  startDataItem: r,
342
348
  endDataItem: n,
@@ -345,145 +351,176 @@ const pt = a.createContext(void 0), ur = (t) => {
345
351
  startColIndex: 0,
346
352
  endColIndex: u.current.length - 1
347
353
  };
348
- e.dataItems.forEach((c) => {
349
- const P = ue(t.gridProps.dataItemKey)(c);
350
- o[P] = e.cell ? [...Array(u.current.length).keys()] : !0;
351
- }), L(i, o);
354
+ e.dataItems.forEach((d) => {
355
+ const f = X(t.gridProps.dataItemKey)(d);
356
+ o[f] = e.cell ? [...Array(u.current.length).keys()] : !0;
357
+ }), L(a, o);
352
358
  }
353
- }, Ye = (e) => {
354
- if (t.gridProps.onSelectionChange) {
355
- const n = ue(t.gridProps.dataItemKey)(e.dataItem), o = 0, i = u.current.length - 1, c = e.dataItems.findIndex(
356
- (D) => D[t.gridProps.dataItemKey] === e.dataItem[t.gridProps.dataItemKey]
357
- ), h = {
359
+ }, et = (e) => {
360
+ if (t.gridProps.onSelectionChange && b.enabled) {
361
+ const n = X(t.gridProps.dataItemKey)(e.dataItem), o = 0, a = u.current.length - 1, d = e.dataItems.findIndex(
362
+ (x) => x[t.gridProps.dataItemKey] === e.dataItem[t.gridProps.dataItemKey]
363
+ ), I = {
358
364
  ...e,
359
- startDataItem: c,
360
- endDataItem: c,
361
- startRowIndex: c,
362
- endRowIndex: c,
365
+ startDataItem: d,
366
+ endDataItem: d,
367
+ startRowIndex: d,
368
+ endRowIndex: d,
363
369
  startColIndex: o,
364
- endColIndex: i
370
+ endColIndex: a
365
371
  }, g = e.mode === "multiple" ? t.gridProps.select || {} : {};
366
- g[n] === !0 || Array.isArray(g[n]) && g[n].length === u.current.length ? delete g[n] : g[n] = e.cell ? [...Array(u.current.length).keys()] : !0, L(h, g);
372
+ g[n] === !0 || Array.isArray(g[n]) && g[n].length === u.current.length ? delete g[n] : g[n] = e.cell ? [...Array(u.current.length).keys()] : !0, L(I, g);
367
373
  }
368
- }, Qe = (e) => {
369
- t.gridProps.onSelectionChange && L(e);
370
- }, z = (e, r, n, o, i) => {
371
- const c = t.gridProps.onDataStateChange;
374
+ }, tt = (e) => {
375
+ t.gridProps.onSelectionChange && b.enabled && L(e, {});
376
+ }, T = (e, r, n, o, a) => {
377
+ const d = t.gridProps.onDataStateChange;
372
378
  if (e) {
373
- const l = { ...m(o), ...r, targetEvent: i };
379
+ const l = { ...P(o), ...r, targetEvent: a };
374
380
  s(e, l);
375
381
  } else
376
- c && s(c, {
377
- ...m(o),
378
- targetEvent: i || {},
382
+ d && s(d, {
383
+ ...P(o),
384
+ targetEvent: a || {},
379
385
  dataState: {
380
- ...lt(),
386
+ ...Pt(),
381
387
  ...n
382
388
  }
383
389
  });
384
390
  }, N = (e, r, n) => {
385
- z(
391
+ T(
386
392
  t.gridProps.onPageChange,
387
393
  { page: e },
388
394
  { skip: e.skip, take: e.take },
389
395
  r,
390
396
  n
391
397
  );
392
- }, Ze = () => {
398
+ }, rt = () => {
393
399
  let e = t.gridProps.total || 0;
394
400
  return Array.isArray(t.gridProps.data) ? e = e || t.gridProps.data.length : t.gridProps.data && (e = e || t.gridProps.data.total), e;
395
- }, pe = (e) => {
396
- const r = t.gridProps.take || 0, n = (t.gridProps.skip || 0) + r, o = Ze();
401
+ }, nt = (e) => {
402
+ var a, d;
403
+ const r = (d = (a = t.gridProps.take) != null ? a : t.gridProps.pageSize) != null ? d : 0, n = (t.gridProps.skip || 0) + r, o = rt();
397
404
  n < o && N({ skip: n, take: r }, e);
398
- }, et = (e) => {
399
- const r = t.gridProps.take || 0, n = (t.gridProps.skip || 0) - r;
405
+ }, ot = (e) => {
406
+ var o, a;
407
+ const r = (a = (o = t.gridProps.take) != null ? o : t.gridProps.pageSize) != null ? a : 0, n = (t.gridProps.skip || 0) - r;
400
408
  n >= 0 && N({ skip: n, take: r }, e);
401
- }, tt = (e) => {
409
+ }, at = (e) => {
402
410
  N({ skip: e.skip, take: e.take }, e.syntheticEvent, e.targetEvent);
403
- }, be = (e, r) => {
404
- z(
411
+ }, Ie = (e, r) => {
412
+ T(
405
413
  t.gridProps.onSortChange,
406
414
  { sort: e },
407
415
  { sort: e, ...t.gridProps.scrollable === "virtual" ? { skip: 0 } : {} },
408
416
  r
409
417
  );
410
- }, rt = (e, r) => {
411
- z(
418
+ }, it = (e, r) => {
419
+ T(
412
420
  t.gridProps.onFilterChange,
413
421
  { filter: e },
414
422
  { filter: e || void 0, skip: 0 },
415
423
  r
416
424
  );
417
- }, X = (e, r) => {
425
+ }, dt = (e) => {
426
+ const r = t.gridProps.searchFields || u.current.map((a) => a.field) || [], n = e.nativeEvent.target.value, o = {
427
+ logic: "or",
428
+ filters: r.filter((a) => a !== void 0).map((a) => {
429
+ var d;
430
+ return typeof a == "string" ? { field: a, value: n, operator: "contains" } : {
431
+ value: n,
432
+ operator: (d = a.operator) != null ? d : "contains",
433
+ field: a.field,
434
+ ignoreCase: a.ignoreCase
435
+ };
436
+ })
437
+ };
438
+ T(
439
+ t.gridProps.onSearchChange,
440
+ {
441
+ search: o
442
+ },
443
+ {},
444
+ e.syntheticEvent
445
+ );
446
+ }, J = (e, r) => {
418
447
  const n = r.nativeEvent ? r : { nativeEvent: r.nativeEvent || r.originalEvent };
419
- e.length === 0 && t.gridProps.navigatable && (ne.current = !0), z(
448
+ e.length === 0 && t.gridProps.navigatable && (ae.current = !0), T(
420
449
  t.gridProps.onGroupChange,
421
450
  { group: e },
422
451
  { group: e, skip: 0 },
423
452
  n
424
453
  );
425
- }, $ = (e, r, n) => {
426
- const o = u.current[e], i = o.depth, c = (g) => {
454
+ }, ct = (e) => {
455
+ if (t.gridProps.onColumnsStateChange) {
456
+ const r = {
457
+ target: R.current,
458
+ columnsState: e
459
+ };
460
+ s(t.gridProps.onColumnsStateChange, r);
461
+ }
462
+ }, Y = (e, r, n) => {
463
+ const o = u.current[e], a = o.depth, d = (g) => {
427
464
  do
428
465
  g++;
429
- while (g < u.current.length && u.current[g].depth > i);
466
+ while (g < u.current.length && u.current[g].depth > a);
430
467
  return g;
431
- }, l = u.current.splice(e, c(e) - e);
432
- u.current.splice(e < r ? c(r - l.length) : r, 0, ...l), u.current.filter((g) => g.declarationIndex >= 0).forEach((g, D) => g.orderIndex = D);
433
- const P = u.current[e].locked && u.current[r].locked;
434
- Vt(t.columnsMapRef, u.current, P || _.current), Wt(t.columnsMapRef, u.current, P || _.current), re.current && (_.current = !1, re.current = !1);
435
- const h = F();
436
- if (p(), t.gridProps.onColumnReorder) {
468
+ }, l = u.current.splice(e, d(e) - e);
469
+ u.current.splice(e < r ? d(r - l.length) : r, 0, ...l), u.current.filter((g) => g.declarationIndex >= 0).forEach((g, x) => g.orderIndex = x);
470
+ const f = u.current[e].locked && u.current[r].locked;
471
+ _t(t.columnsMapRef, u.current, f || _.current), jt(t.columnsMapRef, u.current, f || _.current), oe.current && (_.current = !1, oe.current = !1);
472
+ const I = z();
473
+ if (te(), t.gridProps.onColumnReorder) {
437
474
  const g = {
438
- target: I.current,
439
- columns: h,
475
+ target: R.current,
476
+ columns: I,
440
477
  columnId: o.id,
441
478
  nativeEvent: n
442
479
  };
443
480
  s(t.gridProps.onColumnReorder, g);
444
481
  }
445
- }, nt = (e, r, n) => {
482
+ }, lt = (e, r, n) => {
446
483
  const o = typeof t.gridProps.rowReorderable == "object" ? t.gridProps.rowReorderable.enabled : t.gridProps.rowReorderable;
447
484
  if (n === "forbidden" || !o || !j.current)
448
485
  return;
449
- const { slicedData: i, dataRef: c } = t, l = (i || c)[r];
486
+ const { slicedData: a, dataRef: d } = t, l = (a || d)[r];
450
487
  t.gridProps.onRowReorder && s(t.gridProps.onRowReorder, {
451
488
  draggedDataItems: [j.current],
452
489
  droppedDataItem: l == null ? void 0 : l.dataItem,
453
490
  dropPosition: n,
454
491
  nativeEvent: e.originalEvent,
455
492
  dragEvent: e,
456
- target: I.current
493
+ target: R.current
457
494
  }), j.current = null;
458
- }, ot = (e, r, n) => {
495
+ }, st = (e, r, n) => {
459
496
  if (t.gridProps.group === void 0)
460
497
  return;
461
498
  const o = t.gridProps.group.slice();
462
- o.splice(r, 0, ...o.splice(e, 1)), X(o, n);
463
- }, Ie = (e, r, n) => {
499
+ o.splice(r, 0, ...o.splice(e, 1)), J(o, n);
500
+ }, Re = (e, r, n) => {
464
501
  const o = u.current[e].field;
465
502
  if (!o)
466
503
  return;
467
- const i = (t.gridProps.group || []).slice();
468
- i.splice(r, 0, { field: o }), X(i, n);
469
- }, at = (e, r) => {
470
- const n = y.current.getCurrentGroupsLength;
471
- Ie(e, n, r);
472
- }, J = () => {
504
+ const a = (t.gridProps.group || []).slice();
505
+ a.splice(r, 0, { field: o }), J(a, n);
506
+ }, ut = (e, r) => {
507
+ const n = S.current.getCurrentGroupsLength;
508
+ Re(e, n, r);
509
+ }, Q = () => {
473
510
  let e = 0;
474
- if (!C.current.colGroupMain)
511
+ if (!v.current.colGroupMain)
475
512
  return;
476
- const r = C.current.colGroupMain.children;
513
+ const r = v.current.colGroupMain.children;
477
514
  for (let n = 0; n < r.length; n++) {
478
515
  const o = r[n].width;
479
516
  if (!o)
480
517
  return;
481
518
  e += parseFloat(o.toString());
482
519
  }
483
- e = Math.round(e), A.current && A.current.setWidth(e), T.current && T.current.setWidth(e), w.current && (w.current.style.width = e + "px");
484
- }, it = (e, r) => {
485
- if (t.gridProps.onClipboard && R) {
486
- if (!dt() || !e)
520
+ e = Math.round(e), F.current && F.current.setWidth(e), H.current && H.current.setWidth(e), w.current && (w.current.style.width = e + "px");
521
+ }, gt = (e, r) => {
522
+ if (t.gridProps.onClipboard && C) {
523
+ if (!ft() || !e)
487
524
  return;
488
525
  s(t.gridProps.onClipboard, {
489
526
  type: e,
@@ -493,34 +530,37 @@ const pt = a.createContext(void 0), ur = (t) => {
493
530
  ...typeof t.gridProps.clipboard != "boolean" ? t.gridProps.clipboard : {}
494
531
  });
495
532
  }
496
- }, dt = () => {
497
- var i, c, l;
533
+ }, ft = () => {
534
+ var a, d, l;
498
535
  if (!q)
499
536
  return !1;
500
- const e = kt(E()), r = e ? e.matches(".k-table-td") ? e : (i = E()) == null ? void 0 : i.body : (c = E()) == null ? void 0 : c.body, n = r.closest(".k-grid-container"), o = r && ((l = k.current) == null ? void 0 : l.contains(r));
537
+ const e = Mt(E()), r = e ? e.matches(".k-table-td") ? e : (a = E()) == null ? void 0 : a.body : (d = E()) == null ? void 0 : d.body, n = r.closest(".k-grid-container"), o = r && ((l = K.current) == null ? void 0 : l.contains(r));
501
538
  return !!(r && o && n);
502
- }, ct = (e, r, n, o, i, c) => {
503
- J(), _.current = !0, re.current = !0, t.gridProps.onColumnResize && R && s(t.gridProps.onColumnResize, {
504
- columns: F(),
539
+ }, mt = (e, r, n, o, a, d) => {
540
+ Q(), _.current = !0, oe.current = !0, t.gridProps.onColumnResize && C && s(t.gridProps.onColumnResize, {
541
+ columns: z(),
505
542
  nativeEvent: o,
506
- targetColumnId: c,
543
+ targetColumnId: d,
507
544
  index: e,
508
545
  newWidth: r,
509
546
  oldWidth: n,
510
- end: i,
511
- target: I.current
547
+ end: a,
548
+ target: R.current
512
549
  });
513
- }, lt = () => ({
514
- filter: t.gridProps.filter,
515
- sort: t.gridProps.sort,
516
- skip: t.gridProps.skip,
517
- take: t.gridProps.take !== void 0 ? t.gridProps.take : t.gridProps.pageSize,
518
- group: t.gridProps.group
519
- }), m = (e) => ({
550
+ }, Pt = () => {
551
+ var e;
552
+ return {
553
+ filter: t.gridProps.filter,
554
+ sort: t.gridProps.sort,
555
+ skip: t.gridProps.skip,
556
+ take: (e = t.gridProps.take) != null ? e : t.gridProps.pageSize,
557
+ group: t.gridProps.group
558
+ };
559
+ }, P = (e) => ({
520
560
  nativeEvent: e && e.nativeEvent,
521
561
  syntheticEvent: e,
522
- target: I.current
523
- }), st = (e) => ({
562
+ target: R.current
563
+ }), ht = (e) => ({
524
564
  ...e,
525
565
  nativeEvent: void 0,
526
566
  syntheticEvent: void 0,
@@ -529,89 +569,99 @@ const pt = a.createContext(void 0), ur = (t) => {
529
569
  focusElement: void 0
530
570
  }), s = (e, r) => {
531
571
  if (e.name === "proxy") {
532
- e.call(void 0, st(r));
572
+ e.call(void 0, ht(r));
533
573
  return;
534
574
  }
535
575
  e.call(void 0, r);
536
- }, ut = () => {
576
+ }, bt = () => {
537
577
  var e, r, n;
538
- if (M.current && ((e = M.current) == null ? void 0 : e.getElementsByClassName("k-grid-edit-row").length) > 0) {
539
- ae.current = !1, (r = document.activeElement) != null && r.closest(".k-grid-edit-row") ? oe.current = document.activeElement : oe.current = void 0;
540
- const o = Array.from((n = M.current) == null ? void 0 : n.getElementsByClassName("k-grid-edit-row"));
541
- o.length > le.current.length ? B.current = o.filter(
542
- (i) => !le.current.includes(i)
543
- )[0] : o.length === 1 && (B.current = o[0], ae.current = !0), le.current = o;
578
+ if (A.current && ((e = A.current) == null ? void 0 : e.getElementsByClassName("k-grid-edit-row").length) > 0) {
579
+ de.current = !1, (r = document.activeElement) != null && r.closest(".k-grid-edit-row") ? ie.current = document.activeElement : ie.current = void 0;
580
+ const o = Array.from((n = A.current) == null ? void 0 : n.getElementsByClassName("k-grid-edit-row"));
581
+ o.length > ue.current.length ? W.current = o.filter(
582
+ (a) => !ue.current.includes(a)
583
+ )[0] : o.length === 1 && (W.current = o[0], de.current = !0), ue.current = o;
544
584
  }
545
- }, O = () => t.dataRef.filter((e) => e.rowType === "data").map((e) => e.dataItem), Y = () => (t.slicedData || t.dataRef).filter((e) => e.rowType === "data").map((e) => e.dataItem), Q = () => (te.current || (te.current = Dt() || void 0), te.current), E = () => {
585
+ }, O = () => t.dataRef.filter((e) => e.rowType === "data").map((e) => e.dataItem), Z = () => (t.slicedData || t.dataRef).filter((e) => e.rowType === "data").map((e) => e.dataItem), p = () => (ne.current || (ne.current = Tt() || void 0), ne.current), E = () => {
546
586
  var e;
547
587
  if (q)
548
- return ((e = U()) == null ? void 0 : e.ownerDocument) || document;
549
- }, U = () => k.current, Z = a.useCallback(
588
+ return ((e = B()) == null ? void 0 : e.ownerDocument) || document;
589
+ }, B = () => K.current, ee = i.useCallback(
550
590
  (e) => {
551
591
  var o;
552
- if (!d.current || !((o = d.current) != null && o.container) || t.gridProps.scrollable === "none")
592
+ if (!c.current || !((o = c.current) != null && o.container) || t.gridProps.scrollable === "none")
553
593
  return;
554
- S.current && S.current.disconnect();
555
- const { rowIndex: r } = e, n = U();
594
+ D.current && D.current.disconnect();
595
+ const { rowIndex: r } = e, n = B();
556
596
  if (t.gridProps.scrollable === "virtual")
557
- d.current.askedSkip = r, d.current.container.scroll(
597
+ c.current.askedSkip = r, c.current.container.scroll(
558
598
  0,
559
- Math.round(d.current.askedSkip / d.current.total * d.current.container.scrollHeight)
599
+ Math.round(c.current.askedSkip / c.current.total * c.current.container.scrollHeight)
560
600
  );
561
601
  else if (n) {
562
- const i = r < 1 ? n.querySelector("tbody > tr:nth-child(1)") : n.querySelector(`tbody > tr:nth-child(${r + 1})`);
563
- i && W.current && (W.current.scrollTop = i.offsetTop);
602
+ const a = r < 1 ? n.querySelector("tbody > tr:nth-child(1)") : n.querySelector(`tbody > tr:nth-child(${r + 1})`);
603
+ a && V.current && (V.current.scrollTop = a.offsetTop);
564
604
  }
565
605
  },
566
606
  [t.gridProps.scrollable]
567
- ), Re = (e) => JSON.stringify(e.map((r) => ({ id: r.id, field: r.field, title: r.title, children: r.children }))), gt = () => Re(Et) === Re(u.current), ft = () => {
568
- gt() || p();
569
- }, mt = () => {
607
+ ), Ce = (e) => JSON.stringify(e.map((r) => ({ id: r.id, field: r.field, title: r.title, children: r.children }))), It = () => Ce(kt) === Ce(u.current), Rt = () => {
608
+ It() || te();
609
+ }, Ct = () => {
570
610
  const { data: e, total: r } = t.gridProps;
571
611
  return Array.isArray(e) ? e.length === r : e ? r === e.total : !1;
572
- }, Pt = (e, r) => {
573
- if (d.current) {
574
- if (d.current.fixedScroll = t.gridProps.fixedScroll || !1, d.current.PageChange = N, d.current.realSkip = t.gridProps.skip || 0, d.current.pageSize = (t.gridProps.take !== void 0 ? t.gridProps.take : t.gridProps.pageSize) || 0, d.current.scrollableVirtual = t.gridProps.scrollable === "virtual", d.current.total = e, d.current.propsSkip = (t.gridProps.skip || 0) + (t.gridProps.scrollable === "virtual" ? d.current.topCacheCount + (d.current.attendedSkip - (t.gridProps.skip || 0)) : 0), t.gridProps.rowHeight !== void 0 && t.gridProps.rowHeight > 0 && !r) {
575
- const n = t.gridProps.rowHeight * e;
576
- d.current.containerHeight = De ? Math.min(Ke, n) : n;
612
+ }, Et = (e, r) => {
613
+ var n, o;
614
+ if (c.current) {
615
+ if (c.current.fixedScroll = t.gridProps.fixedScroll || !1, c.current.PageChange = N, c.current.realSkip = t.gridProps.skip || 0, c.current.pageSize = (o = (n = t.gridProps.take) != null ? n : t.gridProps.pageSize) != null ? o : 0, c.current.scrollableVirtual = t.gridProps.scrollable === "virtual", c.current.total = e, c.current.propsSkip = (t.gridProps.skip || 0) + (t.gridProps.scrollable === "virtual" ? c.current.topCacheCount + (c.current.attendedSkip - (t.gridProps.skip || 0)) : 0), t.gridProps.rowHeight !== void 0 && t.gridProps.rowHeight > 0 && !r) {
616
+ const a = t.gridProps.rowHeight * e;
617
+ c.current.containerHeight = Ae ? Math.min(He, a) : a;
577
618
  } else
578
- d.current.containerHeight = 1533915;
579
- if (d.current.containerRef = W, d.current.tableBodyRef = M, d.current.table = w.current, d.current instanceof Me) {
580
- const { rowHeight: n = 0, detail: o, expandField: i } = t.gridProps;
581
- let { detailRowHeight: c = 0 } = t.gridProps;
582
- c = o && i ? c : n, mt() ? (d.current.total = t.dataRef.length, d.current.rowHeightService = new ye(
619
+ c.current.containerHeight = 1533915;
620
+ if (c.current.containerRef = V, c.current.tableBodyRef = A, c.current.table = w.current, c.current instanceof Fe) {
621
+ const { rowHeight: a = 0, detail: d, expandField: l } = t.gridProps;
622
+ let { detailRowHeight: f = 0 } = t.gridProps;
623
+ f = d && l ? f : a, Ct() ? (c.current.total = t.dataRef.length, c.current.rowHeightService = new De(
583
624
  t.dataRef.length,
584
- n,
585
- c,
625
+ a,
626
+ f,
586
627
  t.dataRef
587
- )) : d.current.rowHeightService = new ye(e, n, c);
588
- const l = d.current.rowHeightService.totalHeight();
589
- d.current.containerHeight = De ? Math.min(Ke, l) : l;
628
+ )) : c.current.rowHeightService = new De(e, a, f);
629
+ const I = c.current.rowHeightService.totalHeight();
630
+ c.current.containerHeight = Ae ? Math.min(He, I) : I;
590
631
  }
591
632
  }
592
- }, Ee = a.useCallback(
633
+ }, vt = () => {
634
+ const e = (n) => n.map((o) => ({
635
+ id: o.id,
636
+ field: o.field,
637
+ title: o.title,
638
+ hidden: !1,
639
+ children: o.children ? e(o.children) : null
640
+ })), r = t.columnsRef.current.filter((n) => n.depth === 0);
641
+ return e(r);
642
+ }, Ee = i.useCallback(
593
643
  (e) => {
594
- const r = { rowIndex: ce.current };
644
+ const r = { rowIndex: se.current };
595
645
  e.forEach((n) => {
596
- n.isIntersecting || Z(r);
646
+ n.isIntersecting || ee(r);
597
647
  });
598
648
  },
599
- [Z]
600
- ), p = () => {
649
+ [ee]
650
+ ), te = () => {
601
651
  t.gridProps.forceUpdate && t.gridProps.forceUpdate();
602
- }, ht = (e) => e.left !== void 0 ? Ce !== "rtl" ? { left: e.left, right: e.right } : { left: e.right, right: e.left } : {}, I = a.useRef(null), u = t.columnsRef, d = a.useRef(), C = a.useRef(), y = a.useRef(), v = a.useRef(), x = a.useRef(), V = a.useRef(), S = a.useRef(null), M = a.useRef(null), bt = a.useRef(null), W = a.useRef(null), w = a.useRef(null), ee = a.useRef(null), k = a.useRef(null), T = a.useRef(null), A = a.useRef(null), te = a.useRef(), re = a.useRef(!1), ne = a.useRef(!1), B = a.useRef(), oe = a.useRef(), ae = a.useRef(!1), _ = a.useRef(!0), ie = a.useRef(0), de = a.useRef(), ce = a.useRef(), le = a.useRef([]), j = a.useRef(null), It = a.useRef(null), Rt = a.useRef(null), Ce = St(k), Et = a.useMemo(() => a.Children.toArray(t.gridProps.children), [t.gridProps.children]), { enabled: Ct, mode: vt } = Kt(t.gridProps.editable);
603
- a.useMemo(() => {
604
- K.onConstructor({
652
+ }, yt = (e) => e.left !== void 0 ? ve !== "rtl" ? { left: e.left, right: e.right } : { left: e.right, right: e.left } : {}, R = i.useRef(null), u = t.columnsRef, c = i.useRef(), v = i.useRef(), S = i.useRef(), y = i.useRef(), k = i.useRef(), U = i.useRef(), D = i.useRef(null), A = i.useRef(null), wt = i.useRef(null), V = i.useRef(null), w = i.useRef(null), re = i.useRef(null), K = i.useRef(null), H = i.useRef(null), F = i.useRef(null), ne = i.useRef(), oe = i.useRef(!1), ae = i.useRef(!1), W = i.useRef(), ie = i.useRef(), de = i.useRef(!1), _ = i.useRef(!0), ce = i.useRef(0), le = i.useRef(), se = i.useRef(), ue = i.useRef([]), j = i.useRef(null), xt = i.useRef(null), St = i.useRef(null), ve = Kt(K), kt = i.useMemo(() => i.Children.toArray(t.gridProps.children), [t.gridProps.children]), b = $((xe = t.gridProps.selectable) != null ? xe : !!t.gridProps.selectedField), ye = At((Se = t.gridProps.editable) != null ? Se : !!t.gridProps.editField);
653
+ i.useMemo(() => {
654
+ M.onConstructor({
605
655
  navigatable: !!t.gridProps.navigatable,
606
- contextStateRef: v,
607
- navigationStateRef: x,
656
+ contextStateRef: y,
657
+ navigationStateRef: k,
608
658
  idPrefix: t.id
609
659
  });
610
- }, []), a.useMemo(() => {
660
+ }, []), i.useMemo(() => {
611
661
  var n;
612
- (n = d.current) == null || n.reset();
613
- const e = t.gridProps.groupable === !0 || typeof t.gridProps.groupable == "object" && t.gridProps.groupable.enabled !== !1, r = t.isFixedVirtualScroll ? Me : Jt;
614
- d.current = new r(e || t.gridProps.rowHeight === void 0 || t.gridProps.rowHeight === 0);
662
+ (n = c.current) == null || n.reset();
663
+ const e = t.gridProps.groupable === !0 || typeof t.gridProps.groupable == "object" && t.gridProps.groupable.enabled !== !1, r = t.isFixedVirtualScroll ? Fe : Zt;
664
+ c.current = new r(e || t.gridProps.rowHeight === void 0 || t.gridProps.rowHeight === 0);
615
665
  }, [
616
666
  t.gridProps.scrollable,
617
667
  t.gridProps.total,
@@ -620,140 +670,145 @@ const pt = a.createContext(void 0), ur = (t) => {
620
670
  t.gridProps.groupable,
621
671
  t.gridProps.sort,
622
672
  t.gridProps.rowHeight
623
- ]), a.useEffect(() => (t.gridProps.clipboard && (V.current = new Mt(it), V.current.addEventListeners(E())), () => {
624
- V.current && V.current.removeEventListeners(E());
625
- }), [t.gridProps.onClipboard, t.gridProps.clipboard]), a.useEffect(() => (t.gridProps.columnVirtualization && !window.navigator.userAgent.match(jt) && (ee.current && (ee.current.style.display = "block"), w.current && (w.current.style.display = "block")), J(), we(Q()), K.onComponentDidMount({
626
- scope: k.current || void 0,
627
- contextStateRef: v,
628
- navigationStateRef: x
673
+ ]), i.useEffect(() => (t.gridProps.clipboard && (U.current = new Ht(gt), U.current.addEventListeners(E())), () => {
674
+ U.current && U.current.removeEventListeners(E());
675
+ }), [t.gridProps.onClipboard, t.gridProps.clipboard]), i.useEffect(() => (t.gridProps.columnVirtualization && !window.navigator.userAgent.match($t) && (re.current && (re.current.style.display = "block"), w.current && (w.current.style.display = "block")), Q(), ke(p()), M.onComponentDidMount({
676
+ scope: K.current || void 0,
677
+ contextStateRef: y,
678
+ navigationStateRef: k
629
679
  }), () => {
630
- clearTimeout(de.current);
631
- }), []), a.useEffect(() => {
680
+ clearTimeout(le.current);
681
+ }), []), i.useEffect(() => {
632
682
  var e;
633
- J(), we(Q()), (e = d.current) != null && e.tableTransform && d.current.table && (d.current.table.style.transform = d.current.tableTransform, d.current.tableTransform = ""), ut(), K.onComponentDidUpdate({
634
- scope: k.current || void 0,
635
- contextStateRef: v,
636
- navigationStateRef: x,
637
- focusFirst: ne.current,
638
- newEditableRow: B.current,
639
- singleEditRow: ae.current,
640
- lastActiveElement: oe.current,
683
+ Q(), ke(p()), (e = c.current) != null && e.tableTransform && c.current.table && (c.current.table.style.transform = c.current.tableTransform, c.current.tableTransform = ""), bt(), M.onComponentDidUpdate({
684
+ scope: K.current || void 0,
685
+ contextStateRef: y,
686
+ navigationStateRef: k,
687
+ focusFirst: ae.current,
688
+ newEditableRow: W.current,
689
+ singleEditRow: de.current,
690
+ lastActiveElement: ie.current,
641
691
  navigatable: t.gridProps.navigatable
642
- }), ne.current = !1, B.current = void 0;
643
- }), a.useEffect(() => {
692
+ }), ae.current = !1, W.current = void 0;
693
+ }), i.useEffect(() => {
644
694
  if (q) {
645
695
  const e = {
646
696
  rootMargin: "0px",
647
697
  threshold: 0.9
648
698
  };
649
- S.current = window.IntersectionObserver && new window.IntersectionObserver(Ee, e) || null;
699
+ D.current = window.IntersectionObserver && new window.IntersectionObserver(Ee, e) || null;
650
700
  }
651
- }, [Ee]), a.useEffect(() => {
701
+ }, [Ee]), i.useEffect(() => {
652
702
  var r;
653
703
  let e;
654
- return q && window.ResizeObserver && (e = new window.ResizeObserver(ft), e.observe((r = E()) == null ? void 0 : r.body)), () => {
704
+ return q && window.ResizeObserver && (e = new window.ResizeObserver(Rt), e.observe((r = E()) == null ? void 0 : r.body)), () => {
655
705
  e == null || e.disconnect();
656
706
  };
657
- }, []), a.useImperativeHandle(
658
- I,
707
+ }, []), i.useImperativeHandle(
708
+ R,
659
709
  () => ({
660
710
  get element() {
661
- return U();
711
+ return B();
662
712
  },
663
713
  props: t.gridProps,
664
714
  get columns() {
665
- return F();
715
+ return z();
666
716
  },
667
717
  scrollIntoView: (e) => {
668
718
  var o;
669
- if (!((o = d.current) != null && o.container) || t.gridProps.scrollable === "none")
719
+ if (!((o = c.current) != null && o.container) || t.gridProps.scrollable === "none")
670
720
  return;
671
721
  const { rowIndex: r } = e;
672
- ce.current = r;
673
- const n = U();
674
- if (S.current && n) {
675
- S.current.disconnect();
676
- const i = n.querySelector(`[absolute-row-index="${ce.current}"]`);
677
- i ? S.current.observe(i) : Z(e);
722
+ se.current = r;
723
+ const n = B();
724
+ if (D.current && n) {
725
+ D.current.disconnect();
726
+ const a = n.querySelector(`[absolute-row-index="${se.current}"]`);
727
+ a ? D.current.observe(a) : ee(e);
678
728
  }
679
729
  },
680
730
  fitColumns: (e) => {
681
- C.current.dblClickHandler(null, e);
731
+ v.current.dblClickHandler(null, e);
682
732
  }
683
733
  })
684
- ), a.useImperativeHandle(t.gridRef, () => I.current), a.useMemo(() => {
685
- C.current = new Bt(ct);
686
- }, [t.gridProps.onColumnResize]), a.useMemo(() => {
687
- y.current = new _t($, ot, Ie);
734
+ ), i.useImperativeHandle(t.gridRef, () => R.current), i.useMemo(() => {
735
+ v.current = new qt(mt);
736
+ }, [t.gridProps.onColumnResize]), i.useMemo(() => {
737
+ S.current = new Xt(Y, st, Re);
688
738
  }, [
689
739
  t.gridProps.onColumnReorder,
690
740
  t.gridProps.onGroupChange,
691
741
  t.gridProps.group,
692
742
  t.gridProps.groupable
693
- ]), C.current.resizable = t.gridProps.resizable || !1, C.current.columns = u.current;
694
- const ve = t.gridProps.groupable === !0 || typeof t.gridProps.groupable == "object" && t.gridProps.groupable.enabled !== !1;
695
- return y.current.reorderable = t.gridProps.reorderable || !1, y.current.groupable = ve, y.current.columns = u.current, Pt(t.total, ve), /* @__PURE__ */ a.createElement(
696
- pt.Provider,
743
+ ]), v.current.resizable = t.gridProps.resizable || !1, v.current.columns = u.current;
744
+ const we = t.gridProps.groupable === !0 || typeof t.gridProps.groupable == "object" && t.gridProps.groupable.enabled !== !1;
745
+ S.current.reorderable = t.gridProps.reorderable || !1, S.current.groupable = we, S.current.columns = u.current, Et(t.total, we);
746
+ const Dt = t.gridProps.columnsState || vt();
747
+ return /* @__PURE__ */ i.createElement(
748
+ rr.Provider,
697
749
  {
698
750
  value: {
699
- isClient: R,
700
- rowReorder: nt,
751
+ isClient: C,
752
+ rowReorder: lt,
701
753
  activeDragRowDataItemRef: j,
702
- reorderRowDragTargetRef: It,
703
- reorderRowDropTargetRef: Rt,
704
- dir: Ce,
705
- getCellPositionStyle: ht,
754
+ reorderRowDragTargetRef: xt,
755
+ reorderRowDropTargetRef: St,
756
+ dir: ve,
757
+ getCellPositionStyle: yt,
706
758
  dataItemKey: t.gridProps.dataItemKey,
707
- groupChange: X,
708
- selectionRelease: $e,
709
- pagerPageChange: tt,
710
- onContextMenu: Fe,
711
- rowClick: Ue,
712
- rowDblClick: Ve,
713
- cellClick: We,
714
- headerCellClick: he,
715
- itemChange: je,
716
- sortChange: be,
717
- filterChange: rt,
718
- onHeaderSelectionChange: Xe,
719
- columnGroupChange: at,
720
- onKeyDown: ze,
721
- onFocus: Ne,
722
- scrollHandler: Le,
723
- selectionChange: qe,
724
- dispatchDetailExpand: Be,
725
- dispatchGroupExpand: _e,
726
- columnResizeRef: C,
727
- dragLogicRef: y,
728
- navigationStateRef: x,
759
+ columnsState: Dt,
760
+ onColumnsStateChange: ct,
761
+ groupChange: J,
762
+ selectionRelease: Ze,
763
+ pagerPageChange: at,
764
+ onContextMenu: Oe,
765
+ rowClick: _e,
766
+ rowDblClick: je,
767
+ cellClick: qe,
768
+ headerCellClick: be,
769
+ itemChange: Je,
770
+ sortChange: Ie,
771
+ filterChange: it,
772
+ searchChange: dt,
773
+ onHeaderSelectionChange: Qe,
774
+ columnGroupChange: ut,
775
+ onKeyDown: Ue,
776
+ onFocus: Ve,
777
+ scrollHandler: Be,
778
+ selectionChange: Ye,
779
+ dispatchDetailExpand: Xe,
780
+ dispatchGroupExpand: $e,
781
+ columnResizeRef: v,
782
+ dragLogicRef: S,
783
+ navigationStateRef: k,
729
784
  tableElementRef: w,
730
- tableBodyElementRef: M,
731
- headerElementRef: bt,
732
- containerElementRef: W,
733
- headTableElementRef: ee,
734
- elementRef: k,
735
- footerRef: T,
736
- headerRef: A,
737
- getCachedScrollbarWidth: Q,
738
- vsRef: d
785
+ tableBodyElementRef: A,
786
+ headerElementRef: wt,
787
+ containerElementRef: V,
788
+ headTableElementRef: re,
789
+ elementRef: K,
790
+ footerRef: H,
791
+ headerRef: F,
792
+ getCachedScrollbarWidth: p,
793
+ vsRef: c
739
794
  }
740
795
  },
741
- /* @__PURE__ */ a.createElement(Tt.Provider, { value: v.current }, t.children),
742
- /* @__PURE__ */ a.createElement(
743
- Yt,
796
+ /* @__PURE__ */ i.createElement(Ft.Provider, { value: y.current }, t.children),
797
+ /* @__PURE__ */ i.createElement(
798
+ pt,
744
799
  {
745
- show: b.show,
746
- dataItem: b.dataItem,
747
- field: b.field,
748
- items: He,
749
- offset: b.offset,
750
- onClose: fe,
751
- onSelect: Ge
800
+ show: h.show,
801
+ dataItem: h.dataItem,
802
+ field: h.field,
803
+ items: Le,
804
+ offset: h.offset,
805
+ onClose: me,
806
+ onSelect: Ne
752
807
  }
753
808
  )
754
809
  );
755
810
  };
756
811
  export {
757
- ur as GridClientWrapper,
758
- pt as GridContext
812
+ mr as GridClientWrapper,
813
+ rr as GridContext
759
814
  };