@box-kite/react 2.2.7 → 2.2.9

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 (96) hide show
  1. package/BOX_AI_CONTEXT.md +76 -0
  2. package/BOX_KITE_AI_CONTEXT.md +76 -0
  3. package/analytics.cjs +1 -0
  4. package/analytics.d.ts +10 -0
  5. package/analytics.mjs +121 -0
  6. package/behavior.cjs +1 -1
  7. package/behavior.mjs +42 -38
  8. package/box.cjs +1 -1
  9. package/box.d.ts +9 -0
  10. package/box.mjs +17 -16
  11. package/catalog.cjs +1 -1
  12. package/catalog.mjs +8 -0
  13. package/client.cjs +1 -1
  14. package/client.mjs +120 -120
  15. package/components/accordion.cjs +1 -1
  16. package/components/accordion.mjs +19 -10
  17. package/components/agent.cjs +1 -1
  18. package/components/agent.mjs +21 -8
  19. package/components/calendar.cjs +1 -1
  20. package/components/calendar.d.ts +3 -1
  21. package/components/calendar.mjs +154 -142
  22. package/components/combobox.cjs +1 -1
  23. package/components/combobox.mjs +184 -174
  24. package/components/dashboard.cjs +1 -1
  25. package/components/dashboard.mjs +183 -170
  26. package/components/dataGrid/models/columnModel.d.ts +1 -0
  27. package/components/dataGrid/models/gridModel.d.ts +18 -0
  28. package/components/dataGrid/models/rangeModel.d.ts +3 -0
  29. package/components/dataGrid.cjs +3 -3
  30. package/components/dataGrid.mjs +987 -896
  31. package/components/dateField.cjs +1 -1
  32. package/components/dateField.mjs +160 -149
  33. package/components/datePicker.cjs +1 -1
  34. package/components/datePicker.mjs +226 -206
  35. package/components/dialog.cjs +1 -1
  36. package/components/dialog.mjs +38 -33
  37. package/components/dropdown.cjs +1 -1
  38. package/components/dropdown.mjs +107 -93
  39. package/components/form.cjs +1 -1
  40. package/components/form.mjs +22 -18
  41. package/components/menu.cjs +1 -1
  42. package/components/menu.d.ts +2 -0
  43. package/components/menu.mjs +196 -175
  44. package/components/overlay.cjs +1 -1
  45. package/components/overlay.mjs +7 -7
  46. package/components/popover.cjs +1 -1
  47. package/components/popover.mjs +4 -0
  48. package/components/radioGroup.cjs +1 -1
  49. package/components/radioGroup.mjs +10 -5
  50. package/components/slider.cjs +1 -1
  51. package/components/slider.mjs +84 -83
  52. package/components/sortableList.cjs +1 -1
  53. package/components/sortableList.mjs +158 -150
  54. package/components/swipeItem.cjs +1 -1
  55. package/components/swipeItem.mjs +92 -84
  56. package/components/tabs.cjs +1 -1
  57. package/components/tabs.mjs +10 -5
  58. package/components/timeZoneSelect.cjs +1 -1
  59. package/components/timeZoneSelect.mjs +40 -35
  60. package/components/toaster.cjs +1 -1
  61. package/components/toaster.mjs +151 -113
  62. package/dataGridDateParts.cjs +1 -1
  63. package/dataGridDateParts.mjs +56 -55
  64. package/dataGridList.cjs +1 -1
  65. package/dataGridList.mjs +430 -429
  66. package/effects.cjs +1 -1
  67. package/effects.mjs +1 -1
  68. package/interactionListening.cjs +1 -0
  69. package/interactionListening.mjs +117 -0
  70. package/interactions.cjs +1 -0
  71. package/interactions.mjs +25 -0
  72. package/layer.cjs +1 -1
  73. package/layer.mjs +68 -66
  74. package/package.json +132 -68
  75. package/placement.cjs +1 -1
  76. package/placement.mjs +10 -10
  77. package/platform.cjs +1 -1
  78. package/platform.mjs +44 -25
  79. package/react/interactions/interactions.d.ts +30 -0
  80. package/react/popover/usePopoverLayer.d.ts +3 -0
  81. package/react/useStyles.d.ts +8 -1
  82. package/react-shared.cjs +1 -1
  83. package/react-shared.mjs +49 -48
  84. package/reporting.cjs +1 -0
  85. package/reporting.mjs +51 -0
  86. package/scrolling.cjs +1 -1
  87. package/scrolling.mjs +1 -1
  88. package/supabase/functions/collect/index.d.ts +30 -0
  89. package/supabase/functions/collect/index.test.d.ts +1 -0
  90. package/utils/analytics/analytics.d.ts +72 -0
  91. package/utils/analytics/analyticsIdentity.d.ts +13 -0
  92. package/utils/interactions/componentAttribute.d.ts +6 -0
  93. package/utils/interactions/interactionChannel.d.ts +35 -0
  94. package/utils/interactions/interactionJson.d.ts +6 -0
  95. package/utils/interactions/interactionListening.d.ts +6 -0
  96. package/utils/interactions/interactionTypes.d.ts +224 -0
@@ -1,37 +1,39 @@
1
1
  "use client";
2
- import { d as e, i as t, s as n } from "../platform.mjs";
2
+ import { l as e, o as t, p as n } from "../platform.mjs";
3
3
  import { n as r } from "../effects.mjs";
4
- import i from "../box.mjs";
5
- import { a, n as o, o as s, r as c, t as l } from "../behavior.mjs";
6
- import { t as u } from "../identity.mjs";
7
- import { Path as d, Svg as f } from "./svg.mjs";
8
- import p from "./button.mjs";
9
- import m from "./visuallyHidden.mjs";
10
- import h from "./flex.mjs";
11
- import g from "./checkbox.mjs";
12
- import _ from "./overlay.mjs";
13
- import v from "./presence.mjs";
14
- import y from "./textbox.mjs";
15
- import { n as b } from "../scrolling.mjs";
16
- import x from "./grid.mjs";
17
- import S from "./dropdown.mjs";
18
- import { Span as C } from "./semantics.mjs";
19
- import w from "./popover.mjs";
20
- import T from "./switch.mjs";
21
- import ee, { Fragment as te, createContext as ne, forwardRef as E, memo as D, useCallback as O, useContext as k, useEffect as A, useImperativeHandle as j, useLayoutEffect as re, useMemo as M, useRef as N, useState as P, useSyncExternalStore as ie } from "react";
22
- import { Fragment as F, jsx as I, jsxs as L } from "react/jsx-runtime";
23
- import { useSyncExternalStore as ae } from "use-sync-external-store/shim";
4
+ import { t as i } from "../interactions.mjs";
5
+ import a from "../box.mjs";
6
+ import { a as o, n as s, o as c, r as l, t as u } from "../behavior.mjs";
7
+ import { t as d } from "../identity.mjs";
8
+ import { t as f } from "../reporting.mjs";
9
+ import { Path as p, Svg as m } from "./svg.mjs";
10
+ import h from "./button.mjs";
11
+ import g from "./visuallyHidden.mjs";
12
+ import _ from "./flex.mjs";
13
+ import v from "./checkbox.mjs";
14
+ import y from "./overlay.mjs";
15
+ import b from "./presence.mjs";
16
+ import x from "./textbox.mjs";
17
+ import { n as S } from "../scrolling.mjs";
18
+ import C from "./grid.mjs";
19
+ import w from "./dropdown.mjs";
20
+ import { Span as T } from "./semantics.mjs";
21
+ import E from "./popover.mjs";
22
+ import ee from "./switch.mjs";
23
+ import D, { Fragment as te, createContext as O, forwardRef as k, memo as A, useCallback as j, useContext as M, useEffect as N, useImperativeHandle as ne, useLayoutEffect as re, useMemo as ie, useRef as P, useState as F, useSyncExternalStore as ae } from "react";
24
+ import { Fragment as I, jsx as L, jsxs as R } from "react/jsx-runtime";
25
+ import { useSyncExternalStore as oe } from "use-sync-external-store/shim";
24
26
  //#region src/components/dataGrid/components/dataGridBottomBarSelection.tsx
25
- function oe(e) {
27
+ function se(e) {
26
28
  let { grid: t } = e, n = t.selectedRows.size, r = t.isSelectionView;
27
- return /* @__PURE__ */ L(h, {
29
+ return /* @__PURE__ */ R(_, {
28
30
  component: `${t.componentName}.bottomBar.selection`,
29
31
  children: [
30
- /* @__PURE__ */ I(i, {
32
+ /* @__PURE__ */ L(a, {
31
33
  component: `${t.componentName}.bottomBar.info`,
32
34
  children: t.localeText.selectedCount(n, t.hiddenSelectedCount)
33
35
  }),
34
- t.canShowSelection && (n > 0 || r) && /* @__PURE__ */ I(p, {
36
+ t.canShowSelection && (n > 0 || r) && /* @__PURE__ */ L(h, {
35
37
  type: "button",
36
38
  component: `${t.componentName}.bottomBar.action`,
37
39
  variant: { pressed: r },
@@ -39,11 +41,11 @@ function oe(e) {
39
41
  onClick: t.toggleSelectionView,
40
42
  children: t.localeText.showSelected
41
43
  }),
42
- n > 0 && /* @__PURE__ */ L(p, {
44
+ n > 0 && /* @__PURE__ */ R(h, {
43
45
  type: "button",
44
46
  component: `${t.componentName}.bottomBar.action`,
45
47
  onClick: t.clearSelection,
46
- children: [/* @__PURE__ */ I(i, {
48
+ children: [/* @__PURE__ */ L(a, {
47
49
  tag: "span",
48
50
  props: { "aria-hidden": !0 },
49
51
  children: "✕"
@@ -54,74 +56,74 @@ function oe(e) {
54
56
  }
55
57
  //#endregion
56
58
  //#region src/components/dataGrid/components/dataGridPagination.tsx
57
- function se(e) {
58
- let { grid: t } = e, { pagination: n } = t, r = n.state, a = O(() => n.firstPage(), [n]), o = O(() => n.prevPage(), [n]), s = O(() => n.nextPage(), [n]), c = O(() => n.lastPage(), [n]);
59
+ function ce(e) {
60
+ let { grid: t } = e, { pagination: n } = t, r = n.state, i = j(() => n.firstPage(), [n]), o = j(() => n.prevPage(), [n]), s = j(() => n.nextPage(), [n]), c = j(() => n.lastPage(), [n]);
59
61
  if (!r) return null;
60
62
  let { canGoPrev: l, canGoNext: u, totalPages: d } = n;
61
- return /* @__PURE__ */ L(h, {
63
+ return /* @__PURE__ */ R(_, {
62
64
  component: `${t.componentName}.bottomBar.pagination`,
63
65
  gap: .5,
64
66
  ai: "center",
65
67
  children: [
66
- /* @__PURE__ */ I(ce, {
68
+ /* @__PURE__ */ L(le, {
67
69
  grid: t,
68
70
  pageSize: r.pageSize
69
71
  }),
70
- /* @__PURE__ */ I(R, {
72
+ /* @__PURE__ */ L(de, {
71
73
  componentName: t.componentName,
72
74
  label: t.localeText.firstPage,
73
- onClick: a,
75
+ onClick: i,
74
76
  disabled: !l,
75
- children: /* @__PURE__ */ I(pe, {})
77
+ children: /* @__PURE__ */ L(he, {})
76
78
  }),
77
- /* @__PURE__ */ I(R, {
79
+ /* @__PURE__ */ L(de, {
78
80
  componentName: t.componentName,
79
81
  label: t.localeText.previousPage,
80
82
  onClick: o,
81
83
  disabled: !l,
82
- children: /* @__PURE__ */ I(de, {})
84
+ children: /* @__PURE__ */ L(pe, {})
83
85
  }),
84
- /* @__PURE__ */ L(h, {
86
+ /* @__PURE__ */ R(_, {
85
87
  ai: "center",
86
88
  gap: 1.5,
87
89
  px: 2,
88
90
  userSelect: "none",
89
- children: [/* @__PURE__ */ I(le, {
91
+ children: [/* @__PURE__ */ L(ue, {
90
92
  grid: t,
91
93
  page: r.page,
92
94
  totalPages: d
93
- }), /* @__PURE__ */ I(i, {
95
+ }), /* @__PURE__ */ L(a, {
94
96
  component: `${t.componentName}.bottomBar.pagination.info`,
95
97
  fontSize: 12,
96
98
  opacity: .7,
97
99
  children: t.localeText.pageCount(d)
98
100
  })]
99
101
  }),
100
- /* @__PURE__ */ I(R, {
102
+ /* @__PURE__ */ L(de, {
101
103
  componentName: t.componentName,
102
104
  label: t.localeText.nextPage,
103
105
  onClick: s,
104
106
  disabled: !u,
105
- children: /* @__PURE__ */ I(fe, {})
107
+ children: /* @__PURE__ */ L(me, {})
106
108
  }),
107
- /* @__PURE__ */ I(R, {
109
+ /* @__PURE__ */ L(de, {
108
110
  componentName: t.componentName,
109
111
  label: t.localeText.lastPage,
110
112
  onClick: c,
111
113
  disabled: !u,
112
- children: /* @__PURE__ */ I(me, {})
114
+ children: /* @__PURE__ */ L(ge, {})
113
115
  })
114
116
  ]
115
117
  });
116
118
  }
117
- se.displayName = "DataGridPagination";
118
- function ce({ grid: e, pageSize: t }) {
119
+ ce.displayName = "DataGridPagination";
120
+ function le({ grid: e, pageSize: t }) {
119
121
  let n = e.pagination.pageSizeOptions;
120
- return !n || n.length === 0 ? null : /* @__PURE__ */ I(h, {
122
+ return !n || n.length === 0 ? null : /* @__PURE__ */ L(_, {
121
123
  ai: "center",
122
124
  gap: 1,
123
125
  me: 1,
124
- children: /* @__PURE__ */ I(i, {
126
+ children: /* @__PURE__ */ L(a, {
125
127
  component: `${e.componentName}.bottomBar.pagination.pageSize`,
126
128
  tag: "select",
127
129
  fontSize: 12,
@@ -132,22 +134,22 @@ function ce({ grid: e, pageSize: t }) {
132
134
  value: t,
133
135
  onChange: (t) => e.pagination.changePageSize(Number(t.target.value))
134
136
  },
135
- children: n.map((t) => /* @__PURE__ */ I("option", {
137
+ children: n.map((t) => /* @__PURE__ */ L("option", {
136
138
  value: t,
137
139
  children: e.localeText.pageSizeOption(t)
138
140
  }, t))
139
141
  })
140
142
  });
141
143
  }
142
- function le({ grid: e, page: t, totalPages: n }) {
143
- let [r, i] = P(String(t)), [a, o] = P(t);
144
+ function ue({ grid: e, page: t, totalPages: n }) {
145
+ let [r, i] = F(String(t)), [a, o] = F(t);
144
146
  t !== a && (o(t), i(String(t)));
145
- let s = O(() => {
147
+ let s = j(() => {
146
148
  e.pagination.jumpToPage(r), i(String(e.pagination.page));
147
- }, [e, r]), c = O((e) => {
149
+ }, [e, r]), c = j((e) => {
148
150
  e.key === "Enter" ? s() : e.key === "Escape" && i(String(t));
149
151
  }, [s, t]);
150
- return /* @__PURE__ */ I(y, {
152
+ return /* @__PURE__ */ L(x, {
151
153
  type: "number",
152
154
  variant: "compact",
153
155
  value: r,
@@ -163,9 +165,9 @@ function le({ grid: e, page: t, totalPages: n }) {
163
165
  }
164
166
  });
165
167
  }
166
- function R(e) {
168
+ function de(e) {
167
169
  let { componentName: t, label: n, onClick: r, disabled: i, children: a } = e;
168
- return /* @__PURE__ */ I(p, {
170
+ return /* @__PURE__ */ L(h, {
169
171
  component: `${t}.bottomBar.pagination.button`,
170
172
  props: {
171
173
  "aria-label": n,
@@ -185,8 +187,8 @@ function R(e) {
185
187
  children: a
186
188
  });
187
189
  }
188
- function ue(e) {
189
- return /* @__PURE__ */ I(f, {
190
+ function fe(e) {
191
+ return /* @__PURE__ */ L(m, {
190
192
  viewBox: "0 0 24 24",
191
193
  width: "14",
192
194
  height: "14",
@@ -195,70 +197,70 @@ function ue(e) {
195
197
  strokeWidth: 2,
196
198
  strokeLinecap: "round",
197
199
  strokeLinejoin: "round",
198
- children: /* @__PURE__ */ I(d, { d: e.d })
200
+ children: /* @__PURE__ */ L(p, { d: e.d })
199
201
  });
200
202
  }
201
- function de() {
202
- return /* @__PURE__ */ I(ue, { d: "M15 18l-6-6 6-6" });
203
- }
204
- function fe() {
205
- return /* @__PURE__ */ I(ue, { d: "M9 18l6-6-6-6" });
206
- }
207
203
  function pe() {
208
- return /* @__PURE__ */ I(ue, { d: "M18 18l-6-6 6-6M11 18l-6-6 6-6" });
204
+ return /* @__PURE__ */ L(fe, { d: "M15 18l-6-6 6-6" });
209
205
  }
210
206
  function me() {
211
- return /* @__PURE__ */ I(ue, { d: "M6 18l6-6-6-6M13 18l6-6-6-6" });
207
+ return /* @__PURE__ */ L(fe, { d: "M9 18l6-6-6-6" });
208
+ }
209
+ function he() {
210
+ return /* @__PURE__ */ L(fe, { d: "M18 18l-6-6 6-6M11 18l-6-6 6-6" });
211
+ }
212
+ function ge() {
213
+ return /* @__PURE__ */ L(fe, { d: "M6 18l6-6-6-6M13 18l6-6-6-6" });
212
214
  }
213
215
  //#endregion
214
216
  //#region src/components/dataGrid/components/dataGridBottomBar.tsx
215
- function he(e) {
217
+ function _e(e) {
216
218
  let { grid: t } = e, { pagination: n, filter: r } = t;
217
219
  if (n.state) {
218
- let { totalItems: e, startItem: r, endItem: a } = n;
219
- return /* @__PURE__ */ L(h, {
220
+ let { totalItems: e, startItem: r, endItem: i } = n;
221
+ return /* @__PURE__ */ R(_, {
220
222
  component: `${t.componentName}.bottomBar`,
221
223
  children: [
222
- /* @__PURE__ */ I(i, {
224
+ /* @__PURE__ */ L(a, {
223
225
  component: `${t.componentName}.bottomBar.info`,
224
- children: t.localeText.pageRowRange(r, a, e)
226
+ children: t.localeText.pageRowRange(r, i, e)
225
227
  }),
226
- t.props.def.rowSelection && /* @__PURE__ */ I(oe, { grid: t }),
227
- /* @__PURE__ */ I(se, { grid: t })
228
+ t.props.def.rowSelection && /* @__PURE__ */ L(se, { grid: t }),
229
+ /* @__PURE__ */ L(ce, { grid: t })
228
230
  ]
229
231
  });
230
232
  }
231
- let { filtered: a, total: o } = r.filterStats;
232
- return /* @__PURE__ */ L(h, {
233
+ let { filtered: i, total: o } = r.filterStats;
234
+ return /* @__PURE__ */ R(_, {
233
235
  component: `${t.componentName}.bottomBar`,
234
236
  children: [
235
- /* @__PURE__ */ I(i, {
237
+ /* @__PURE__ */ L(a, {
236
238
  component: `${t.componentName}.bottomBar.info`,
237
- children: t.localeText.rowCount(a, o)
239
+ children: t.localeText.rowCount(i, o)
238
240
  }),
239
- r.hasActiveFilters && /* @__PURE__ */ L(p, {
241
+ r.hasActiveFilters && /* @__PURE__ */ R(h, {
240
242
  type: "button",
241
243
  component: `${t.componentName}.bottomBar.clearFilters`,
242
244
  onClick: r.clearAllFilters,
243
- children: [/* @__PURE__ */ I(i, {
245
+ children: [/* @__PURE__ */ L(a, {
244
246
  tag: "span",
245
247
  props: { "aria-hidden": !0 },
246
248
  children: "✕"
247
249
  }), t.localeText.clearFilters]
248
250
  }),
249
- t.props.def.rowSelection && /* @__PURE__ */ I(oe, { grid: t })
251
+ t.props.def.rowSelection && /* @__PURE__ */ L(se, { grid: t })
250
252
  ]
251
253
  });
252
254
  }
253
255
  //#endregion
254
256
  //#region src/components/dataGrid/gridNavigationContext.ts
255
- var ge = ne(null);
257
+ var ve = O(null);
256
258
  function z() {
257
- return k(ge);
259
+ return M(ve);
258
260
  }
259
- var _e = () => () => {};
260
- function ve(e, t, n) {
261
- let r = ie(e?.activeCell.subscribe ?? _e, () => !!e?.activeCell.isActive(t, n), () => !!e?.activeCell.isActive(t, n));
261
+ var ye = () => () => {};
262
+ function be(e, t, n) {
263
+ let r = ae(e?.activeCell.subscribe ?? ye, () => !!e?.activeCell.isActive(t, n), () => !!e?.activeCell.isActive(t, n));
262
264
  return e ? {
263
265
  ...e.cellProps(t, n),
264
266
  tabIndex: r ? 0 : -1
@@ -266,7 +268,7 @@ function ve(e, t, n) {
266
268
  }
267
269
  //#endregion
268
270
  //#region src/components/dataGrid/models/viewportModel.ts
269
- var ye = class e {
271
+ var xe = class e {
270
272
  grid;
271
273
  static DEFAULT_VISIBLE_ROWS_COUNT = 10;
272
274
  static ROWS_AHEAD = 12;
@@ -319,7 +321,7 @@ var ye = class e {
319
321
  totalHeight: this.totalHeight,
320
322
  viewHeight: void 0
321
323
  };
322
- let { rowHeight: i } = this.grid, { ROWS_AHEAD: a, ROWS_BEHIND: o, PARTIAL_ROWS: s } = e, c = n === "down" ? o : a, { offsets: l } = this.grid.rowOffsets.value, u = this.hasDetailRows ? b(l, t) : Math.floor(t / i), d = Math.max(0, u - c), f = this.hasDetailRows ? l[d] ?? 0 : d * i;
324
+ let { rowHeight: i } = this.grid, { ROWS_AHEAD: a, ROWS_BEHIND: o, PARTIAL_ROWS: s } = e, c = n === "down" ? o : a, { offsets: l } = this.grid.rowOffsets.value, u = this.hasDetailRows ? S(l, t) : Math.floor(t / i), d = Math.max(0, u - c), f = this.hasDetailRows ? l[d] ?? 0 : d * i;
323
325
  return {
324
326
  startIndex: d,
325
327
  take: this.visibleRowsCount + s + o + a,
@@ -328,7 +330,7 @@ var ye = class e {
328
330
  viewHeight: this.viewHeight
329
331
  };
330
332
  }
331
- }, be = class {
333
+ }, Se = class {
332
334
  row;
333
335
  column;
334
336
  listeners = /* @__PURE__ */ new Set();
@@ -342,23 +344,23 @@ var ye = class e {
342
344
  set(e, t) {
343
345
  (e !== this.row || t !== this.column) && (this.row = e, this.column = t, this.listeners.forEach((e) => e()));
344
346
  }
345
- }, xe, Se;
346
- function Ce() {
347
- return Se ??= import("../dataGridDateParts.mjs").then((e) => xe = e.default), Se;
347
+ }, Ce, we;
348
+ function Te() {
349
+ return we ??= import("../dataGridDateParts.mjs").then((e) => Ce = e.default), we;
348
350
  }
349
- function we() {
350
- return xe;
351
+ function Ee() {
352
+ return Ce;
351
353
  }
352
- function Te(e) {
353
- let [t, n] = P(void 0);
354
+ function De(e) {
355
+ let [t, n] = F(void 0);
354
356
  return r(() => {
355
357
  if (!e || t) return;
356
- if (xe) {
357
- n(() => xe);
358
+ if (Ce) {
359
+ n(() => Ce);
358
360
  return;
359
361
  }
360
362
  let r = !0;
361
- return Ce().then((e) => r && n(() => e)), () => {
363
+ return Te().then((e) => r && n(() => e)), () => {
362
364
  r = !1;
363
365
  };
364
366
  }, [e, t]), t;
@@ -368,35 +370,39 @@ function Te(e) {
368
370
  function B(e, t) {
369
371
  return JSON.stringify([e, t]);
370
372
  }
371
- var Ee = 1e3;
372
- function De(e) {
373
- return typeof e == "number" ? "number" : typeof e == "boolean" ? "checkbox" : e instanceof Date ? "datetime" : typeof e == "string" ? ke.test(e) ? "date" : Ae.test(e) ? "time" : je.test(e) ? "datetime" : "text" : "text";
373
+ var Oe = 1e3;
374
+ function ke(e) {
375
+ return typeof e == "number" ? "number" : typeof e == "boolean" ? "checkbox" : e instanceof Date ? "datetime" : typeof e == "string" ? je.test(e) ? "date" : Me.test(e) ? "time" : Ne.test(e) ? "datetime" : "text" : "text";
374
376
  }
375
- var Oe = /* @__PURE__ */ new Set([
377
+ var Ae = /* @__PURE__ */ new Set([
376
378
  "date",
377
379
  "time",
378
380
  "datetime"
379
- ]), ke = /^\d{4}-\d{2}-\d{2}$/, Ae = /^\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/, je = /^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}/;
380
- function Me(e) {
381
- return Oe.has(e);
381
+ ]), je = /^\d{4}-\d{2}-\d{2}$/, Me = /^\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/, Ne = /^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}/;
382
+ function Pe(e) {
383
+ return Ae.has(e);
382
384
  }
383
- function Ne(e, t) {
385
+ function Fe(e, t) {
384
386
  if (e === "text") return t;
385
387
  if (e !== "number" || t.trim() === "") return;
386
388
  let n = Number(t);
387
389
  return Number.isFinite(n) ? n : void 0;
388
390
  }
389
- var Pe = /* @__PURE__ */ new Set([
391
+ var Ie = [
392
+ "value",
393
+ "oldValue",
394
+ "error"
395
+ ], Le = /* @__PURE__ */ new Set([
390
396
  "true",
391
397
  "1",
392
398
  "yes"
393
- ]), Fe = /* @__PURE__ */ new Set([
399
+ ]), Re = /* @__PURE__ */ new Set([
394
400
  "false",
395
401
  "0",
396
402
  "no",
397
403
  ""
398
404
  ]);
399
- function Ie(e, t, n) {
405
+ function ze(e, t, n) {
400
406
  if (e.type === "number") {
401
407
  if (n.trim() === "") return { value: null };
402
408
  let e = Number(n);
@@ -404,17 +410,17 @@ function Ie(e, t, n) {
404
410
  }
405
411
  if (e.type === "checkbox") {
406
412
  let e = n.trim().toLowerCase();
407
- return Pe.has(e) ? { value: !0 } : Fe.has(e) ? { value: !1 } : void 0;
413
+ return Le.has(e) ? { value: !0 } : Re.has(e) ? { value: !1 } : void 0;
408
414
  }
409
- if (Me(e.type)) {
415
+ if (Pe(e.type)) {
410
416
  if (n.trim() === "") return { value: null };
411
- let t = we();
417
+ let t = Ee();
412
418
  if (t) {
413
419
  let r = t.parsePasted(e, n);
414
420
  return r ? { value: r } : void 0;
415
421
  }
416
422
  let r = n.trim();
417
- return (e.type === "date" ? ke : e.type === "time" ? Ae : je).test(r) ? { value: r } : void 0;
423
+ return (e.type === "date" ? je : e.type === "time" ? Me : Ne).test(r) ? { value: r } : void 0;
418
424
  }
419
425
  if (e.type === "select") {
420
426
  let e = t.find((e) => String(e.value) === n);
@@ -422,10 +428,10 @@ function Ie(e, t, n) {
422
428
  }
423
429
  return { value: n };
424
430
  }
425
- function Le(e) {
431
+ function Be(e) {
426
432
  return e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey;
427
433
  }
428
- var Re = class {
434
+ var Ve = class {
429
435
  grid;
430
436
  constructor(e) {
431
437
  this.grid = e;
@@ -450,7 +456,7 @@ var Re = class {
450
456
  }
451
457
  editorFor(e, t) {
452
458
  let { editor: n } = e.def;
453
- return typeof n == "object" ? n : n ? { type: n } : { type: De(t) };
459
+ return typeof n == "object" ? n : n ? { type: n } : { type: ke(t) };
454
460
  }
455
461
  isEditing(e, t) {
456
462
  return this._active?.rowKey === e && this._active.columnKey === t;
@@ -475,7 +481,7 @@ var Re = class {
475
481
  return !!this._active?.pending;
476
482
  }
477
483
  begin(e, t, n, r) {
478
- let i = r === void 0 ? void 0 : Ne(this.editorFor(t, n).type, r);
484
+ let i = r === void 0 ? void 0 : Fe(this.editorFor(t, n).type, r);
479
485
  this.rejected.delete(B(e.key, t.key)), this._active = {
480
486
  row: e,
481
487
  rowKey: e.key,
@@ -484,7 +490,10 @@ var Re = class {
484
490
  token: ++this._token,
485
491
  drafts: 0,
486
492
  pending: !1
487
- }, this.grid.notify();
493
+ }, this.grid.notify(), this.grid.reportInteraction("cellEditStart", n, r === void 0 ? "open" : "typing", {
494
+ rowKey: e.key,
495
+ columnKey: t.key
496
+ }, ["value"]);
488
497
  }
489
498
  beginAt(e, t, n) {
490
499
  let r = this.grid.flatRows.value[e], i = this.grid.columns.value.visibleLeafs[t];
@@ -534,10 +543,19 @@ var Re = class {
534
543
  ...this._active,
535
544
  pending: !1,
536
545
  error: typeof n == "string" ? n : this.invalidValue
537
- }, this.grid.notify();
546
+ }, this.grid.notify(), this.grid.reportInteraction("cellEditReject", t.value, "invalid", {
547
+ rowKey: t.rowKey,
548
+ columnKey: t.columnKey,
549
+ oldValue: t.oldValue,
550
+ error: this._active.error
551
+ }, Ie);
538
552
  return;
539
553
  }
540
- this.values.set(B(t.rowKey, t.columnKey), t.value), this._edits = [...this._edits, t], this._active = void 0, this.grid.notify(), this.grid.props.onCellEditsChange?.(this._edits, { reason: "edit" });
554
+ this.values.set(B(t.rowKey, t.columnKey), t.value), this._edits = [...this._edits, t], this._active = void 0, this.grid.notify(), this.grid.props.onCellEditsChange?.(this._edits, { reason: "edit" }), this.grid.reportInteraction("cellEdit", t.value, "edit", {
555
+ rowKey: t.rowKey,
556
+ columnKey: t.columnKey,
557
+ oldValue: t.oldValue
558
+ }, Ie);
541
559
  }
542
560
  }
543
561
  valueOf(e, t, n) {
@@ -561,7 +579,7 @@ var Re = class {
561
579
  c++;
562
580
  continue;
563
581
  }
564
- let f = this.valueOf(l.key, u.key, l.data[u.key]), p = Ie(this.editorFor(u, f), this.optionsFor(u, l), d), m = {
582
+ let f = this.valueOf(l.key, u.key, l.data[u.key]), p = ze(this.editorFor(u, f), this.optionsFor(u, l), d), m = {
565
583
  rowKey: l.key,
566
584
  columnKey: u.key,
567
585
  row: l.data,
@@ -594,16 +612,34 @@ var Re = class {
594
612
  return;
595
613
  }
596
614
  Object.is(e.value, e.oldValue) || (this.values.set(B(e.rowKey, e.columnKey), e.value), a.push(e));
597
- }), a.length > 0 && (this._edits = [...this._edits, ...a]), this.grid.notify(), a.length > 0 && this.grid.props.onCellEditsChange?.(this._edits, { reason: "paste" }), this.grid.props.onPaste?.({
598
- range: this.grid.range.rangeOf(t),
615
+ }), a.length > 0 && (this._edits = [...this._edits, ...a]), this.grid.notify(), a.length > 0 && this.grid.props.onCellEditsChange?.(this._edits, { reason: "paste" });
616
+ let s = this.grid.range.rangeOf(t);
617
+ this.grid.props.onPaste?.({
618
+ range: s,
599
619
  applied: a,
600
620
  rejected: o,
601
621
  skipped: i
602
622
  });
623
+ let c = a.map(({ rowKey: e, columnKey: t, value: n, oldValue: r }) => ({
624
+ rowKey: e,
625
+ columnKey: t,
626
+ value: n,
627
+ oldValue: r
628
+ })), { startRow: l, endRow: u, columns: d } = s;
629
+ this.grid.reportInteraction("paste", a.length, "paste", {
630
+ range: {
631
+ startRow: l,
632
+ endRow: u,
633
+ columns: d
634
+ },
635
+ rejected: o.length,
636
+ skipped: i,
637
+ cells: c
638
+ }, ["cells"]);
603
639
  }
604
640
  nextEditable(e, t, n = !1) {
605
- let r = this.grid.flatRows.value, i = this.grid.columns.value.visibleLeafs, a = n ? -1 : 1, o = e * i.length + t + a, s = Math.min(r.length * i.length - 1, o + Ee);
606
- for (let e = o; e >= Math.max(0, o - Ee) && e <= s; e += a) {
641
+ let r = this.grid.flatRows.value, i = this.grid.columns.value.visibleLeafs, a = n ? -1 : 1, o = e * i.length + t + a, s = Math.min(r.length * i.length - 1, o + Oe);
642
+ for (let e = o; e >= Math.max(0, o - Oe) && e <= s; e += a) {
607
643
  let t = Math.floor(e / i.length), n = e % i.length, a = r[t], o = i[n];
608
644
  if (!(!o || a?.kind !== "row" || !this.isEditable(a, o))) return {
609
645
  row: t,
@@ -676,7 +712,12 @@ var Re = class {
676
712
  this.grid.edits.commit();
677
713
  };
678
714
  cancelEdit = () => {
679
- this.grid.edits.cancel();
715
+ if (!this.grid.edits.isOpen) return;
716
+ let { draft: e } = this.grid.edits;
717
+ this.grid.edits.cancel(), this.grid.reportInteraction("cellEditCancel", e, "cancel", {
718
+ rowKey: this.row.key,
719
+ columnKey: this.column.key
720
+ }, ["value"]);
680
721
  };
681
722
  }, H = class e {
682
723
  grid;
@@ -777,42 +818,42 @@ function W(e) {
777
818
  }
778
819
  //#endregion
779
820
  //#region src/components/dataGrid/useGridNavigation.ts
780
- var ze = "[role=\"gridcell\"],[role=\"columnheader\"]", Be = "a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]", Ve = 2, He = [];
781
- function Ue(e) {
782
- let { grid: t, scrollerRef: n, scroll: i, onScrollTo: a } = e, o = t.headerRows.value, c = t.filter.hasFilterableColumns, u = o.length + +!!c, d = t.viewport.isEmpty ? He : t.flatRows.value, f = t.columns.value.visibleLeafs.length, p = t.aggregation.hasFooter && !t.viewport.isEmpty ? 1 : 0, m = u + d.length + p, h = O((e) => {
821
+ var He = "[role=\"gridcell\"],[role=\"columnheader\"]", Ue = "a[href],button:not([disabled]),input:not([disabled]),select:not([disabled]),textarea:not([disabled]),[tabindex]", We = 2, Ge = [];
822
+ function Ke(e) {
823
+ let { grid: t, scrollerRef: n, scroll: i, onScrollTo: a } = e, o = t.headerRows.value, s = t.filter.hasFilterableColumns, l = o.length + +!!s, d = t.viewport.isEmpty ? Ge : t.flatRows.value, f = t.columns.value.visibleLeafs.length, p = t.aggregation.hasFooter && !t.viewport.isEmpty ? 1 : 0, m = l + d.length + p, h = j((e) => {
783
824
  if (e < o.length) return o[e]?.length ?? 0;
784
- if (e < u || e >= u + d.length) return f;
785
- let t = d[e - u];
825
+ if (e < l || e >= l + d.length) return f;
826
+ let t = d[e - l];
786
827
  return t ? t.cellCount : 0;
787
828
  }, [
788
829
  d,
789
830
  f,
790
- u,
831
+ l,
791
832
  o
792
- ]), g = O((e, t) => e < o.length ? (o[e]?.[t]?.headerCell.columnIndex ?? t + 1) - 1 : e < u ? t : d[e - u]?.columnOf(t) ?? t, [
833
+ ]), g = j((e, t) => e < o.length ? (o[e]?.[t]?.headerCell.columnIndex ?? t + 1) - 1 : e < l ? t : d[e - l]?.columnOf(t) ?? t, [
793
834
  d,
794
- u,
835
+ l,
795
836
  o
796
- ]), _ = N(!1), v = O((e, r) => {
797
- let { viewport: o } = t, s = e - u, c = n.current;
837
+ ]), _ = P(!1), v = j((e, r) => {
838
+ let { viewport: o } = t, s = e - l, c = n.current;
798
839
  if (o.showAll || !c || s >= d.length) return;
799
840
  if (s < 0) {
800
- r >= u && (c.scrollTop = 0, a(0));
841
+ r >= l && (c.scrollTop = 0, a(0));
801
842
  return;
802
843
  }
803
- let { startIndex: l, take: f } = o.window(i.top, i.direction);
804
- if (s >= l + Ve && s < l + f - Ve) return;
844
+ let { startIndex: u, take: f } = o.window(i.top, i.direction);
845
+ if (s >= u + We && s < u + f - We) return;
805
846
  let p = o.rowTop(s);
806
847
  c.scrollTop = p, a(p);
807
848
  }, [
808
849
  d.length,
809
850
  t,
810
- u,
851
+ l,
811
852
  a,
812
853
  i,
813
854
  n
814
- ]), y = N(0), b = O((e, n, r) => {
815
- let i = e - u;
855
+ ]), y = P(0), b = j((e, n, r) => {
856
+ let i = e - l;
816
857
  if (i < 0 || i >= d.length) {
817
858
  t.range.clear();
818
859
  return;
@@ -826,8 +867,8 @@ function Ue(e) {
826
867
  d.length,
827
868
  g,
828
869
  t,
829
- u
830
- ]), x = l({
870
+ l
871
+ ]), x = u({
831
872
  count: m,
832
873
  columns: h,
833
874
  columnIndexOf: g,
@@ -840,23 +881,23 @@ function Ue(e) {
840
881
  r(() => {
841
882
  _.current && (_.current = !1, S()?.focus());
842
883
  });
843
- let C = O((e, n, r) => {
884
+ let C = j((e, n, r) => {
844
885
  if (!t.tree.enabled || e.key !== "ArrowRight" && e.key !== "ArrowLeft") return !1;
845
- let i = d[n - u];
886
+ let i = d[n - l];
846
887
  if (!W(i) || t.columns.value.visibleLeafs[r]?.key !== t.tree.columnKey) return !1;
847
888
  if (e.key === (t.isRtl ? "ArrowLeft" : "ArrowRight")) return !i.hasChildren || i.treeExpanded ? !1 : (i.toggleTree(), !0);
848
889
  if (i.hasChildren && i.treeExpanded) return i.toggleTree(), !0;
849
- for (let e = n - 1; e >= u; e--) {
850
- let t = d[e - u];
890
+ for (let e = n - 1; e >= l; e--) {
891
+ let t = d[e - l];
851
892
  if (!(!W(t) || t.level >= i.level)) return x.setActiveCell(e, r, { reason: "keyboard" }), !0;
852
893
  }
853
894
  return !1;
854
895
  }, [
855
896
  d,
856
897
  t,
857
- u,
898
+ l,
858
899
  x
859
- ]), w = O((e) => {
900
+ ]), w = j((e) => {
860
901
  let { activeIndex: t, activeColumn: n } = x, r = e ? -1 : 1, i = n + r;
861
902
  if (i >= 0 && i < h(t)) return x.setActiveCell(t, i, { reason: "keyboard" }), !0;
862
903
  let a = t + r;
@@ -865,29 +906,29 @@ function Ue(e) {
865
906
  h,
866
907
  x,
867
908
  m
868
- ]), T = O((e, n) => {
909
+ ]), T = j((e, n) => {
869
910
  if (!t.props.def.rowSelection) return !1;
870
- if (e < u) return e >= o.length || !t.columns.value.visibleLeafs[n]?.isRowSelection ? !1 : (t.toggleSelectAllRows(), !0);
871
- let r = t.flatRows.value[e - u];
911
+ if (e < l) return e >= o.length || !t.columns.value.visibleLeafs[n]?.isRowSelection ? !1 : (t.toggleSelectAllRows(), !0);
912
+ let r = t.flatRows.value[e - l];
872
913
  return r instanceof U && (r.toggleSelection(), !0);
873
914
  }, [
874
915
  t,
875
- u,
916
+ l,
876
917
  o.length
877
- ]), ee = O((e, t, n) => {
878
- let r = Array.from(e.querySelectorAll(Be));
918
+ ]), E = j((e, t, n) => {
919
+ let r = Array.from(e.querySelectorAll(Ue));
879
920
  if (r.length < 2) return !1;
880
921
  let i = r.indexOf(t);
881
922
  return i !== -1 && (r[(i + (n ? -1 : 1) + r.length) % r.length].focus(), !0);
882
- }, []), te = x.onKeyDown, ne = O((e) => {
883
- let n = e.target, r = n.closest?.(ze);
923
+ }, []), ee = x.onKeyDown, D = j((e) => {
924
+ let n = e.target, r = n.closest?.(He);
884
925
  if (r) {
885
926
  if (n !== r) {
886
927
  if (e.key === "Escape" && !r.querySelector("[aria-expanded=\"true\"]")) {
887
928
  e.preventDefault(), r.focus();
888
929
  return;
889
930
  }
890
- e.key === "Tab" && ee(r, n, e.shiftKey) && e.preventDefault();
931
+ e.key === "Tab" && E(r, n, e.shiftKey) && e.preventDefault();
891
932
  return;
892
933
  }
893
934
  if (e.key === "Tab" && t.props.def.tabNavigation === "cells") {
@@ -904,17 +945,17 @@ function Ue(e) {
904
945
  e.preventDefault(), n.sortColumn();
905
946
  return;
906
947
  }
907
- if (t.edits.beginAt(x.activeIndex - u, x.activeColumn)) {
948
+ if (t.edits.beginAt(x.activeIndex - l, x.activeColumn)) {
908
949
  e.preventDefault();
909
950
  return;
910
951
  }
911
- let i = r.querySelector(Be);
952
+ let i = r.querySelector(Ue);
912
953
  if (i) {
913
954
  e.preventDefault(), i.focus();
914
955
  return;
915
956
  }
916
957
  }
917
- if (t.edits.enabled && Le(e) && t.edits.beginAt(x.activeIndex - u, x.activeColumn, e.key)) {
958
+ if (t.edits.enabled && Be(e) && t.edits.beginAt(x.activeIndex - l, x.activeColumn, e.key)) {
918
959
  e.preventDefault();
919
960
  return;
920
961
  }
@@ -922,26 +963,26 @@ function Ue(e) {
922
963
  e.preventDefault();
923
964
  return;
924
965
  }
925
- te(e);
966
+ ee(e);
926
967
  }
927
968
  }, [
928
969
  t,
929
- u,
970
+ l,
930
971
  o,
931
972
  x.activeColumn,
932
973
  x.activeIndex,
933
- te,
934
- w,
935
974
  ee,
975
+ w,
976
+ E,
936
977
  T,
937
978
  C
938
- ]), { setActiveCell: E, activeIndex: D, activeColumn: k } = x, A = s(x.cellProps), [j] = P(() => new be(D, k));
939
- r(() => j.set(D, k), [
940
- j,
979
+ ]), { setActiveCell: te, activeIndex: O, activeColumn: k } = x, A = c(x.cellProps), [M] = F(() => new Se(O, k));
980
+ r(() => M.set(O, k), [
981
+ M,
941
982
  k,
942
- D
983
+ O
943
984
  ]);
944
- let re = O((e, t) => {
985
+ let N = j((e, t) => {
945
986
  let { ref: n, onFocus: r } = A.current(e, t);
946
987
  return {
947
988
  ref: n,
@@ -949,27 +990,27 @@ function Ue(e) {
949
990
  };
950
991
  }, [A]);
951
992
  return {
952
- navigation: M(() => ({
993
+ navigation: ie(() => ({
953
994
  rowCount: m,
954
995
  columnCount: f,
955
- headerRowCount: u,
956
- cellProps: re,
957
- activeCell: j,
958
- setActiveCell: E
996
+ headerRowCount: l,
997
+ cellProps: N,
998
+ activeCell: M,
999
+ setActiveCell: te
959
1000
  }), [
960
- j,
961
- re,
1001
+ M,
1002
+ N,
962
1003
  f,
963
- u,
1004
+ l,
964
1005
  m,
965
- E
1006
+ te
966
1007
  ]),
967
- onKeyDown: ne
1008
+ onKeyDown: D
968
1009
  };
969
1010
  }
970
1011
  //#endregion
971
1012
  //#region src/utils/array/arrayUtils.ts
972
- var We;
1013
+ var qe;
973
1014
  (function(e) {
974
1015
  function t(e, t, n = 0) {
975
1016
  return e.slice(n, n + t);
@@ -1016,11 +1057,11 @@ var We;
1016
1057
  }));
1017
1058
  }
1018
1059
  e.groupBy = s;
1019
- })(We ||= {});
1020
- var G = We, Ge = "row-number-cell", Ke = "row-selection-cell", K = "grouping-cell", qe = "row-detail-cell", Je = Symbol("memo.unset"), Ye = class {
1060
+ })(qe ||= {});
1061
+ var G = qe, Je = "row-number-cell", Ye = "row-selection-cell", K = "grouping-cell", Xe = "row-detail-cell", Ze = Symbol("memo.unset"), Qe = class {
1021
1062
  action;
1022
1063
  deps;
1023
- cache = Je;
1064
+ cache = Ze;
1024
1065
  dependents = /* @__PURE__ */ new Set();
1025
1066
  wired = !1;
1026
1067
  constructor(e, t) {
@@ -1033,46 +1074,46 @@ var G = We, Ge = "row-number-cell", Ke = "row-selection-cell", K = "grouping-cel
1033
1074
  }
1034
1075
  }
1035
1076
  get value() {
1036
- return this.wire(), this.cache === Je && (this.cache = this.action()), this.cache;
1077
+ return this.wire(), this.cache === Ze && (this.cache = this.action()), this.cache;
1037
1078
  }
1038
1079
  clear() {
1039
- if (this.wire(), this.cache !== Je) {
1040
- this.cache = Je;
1080
+ if (this.wire(), this.cache !== Ze) {
1081
+ this.cache = Ze;
1041
1082
  for (let e of this.dependents) e.clear();
1042
1083
  }
1043
1084
  }
1044
1085
  };
1045
1086
  function q(e, t = () => []) {
1046
- return new Ye(e, t);
1087
+ return new Qe(e, t);
1047
1088
  }
1048
1089
  //#endregion
1049
1090
  //#region src/components/dataGrid/models/aggregationModel.ts
1050
- function Xe(e) {
1091
+ function $e(e) {
1051
1092
  return e.filter((e) => typeof e == "number" && !Number.isNaN(e));
1052
1093
  }
1053
- var Ze = (e) => e.reduce((e, t) => e + t, 0), Qe = (e, t) => e.reduce((e, n) => (t ? n < e : n > e) ? n : e), $e = {
1094
+ var et = (e) => e.reduce((e, t) => e + t, 0), tt = (e, t) => e.reduce((e, n) => (t ? n < e : n > e) ? n : e), nt = {
1054
1095
  sum: (e) => {
1055
- let t = Xe(e);
1056
- return t.length ? Ze(t) : null;
1096
+ let t = $e(e);
1097
+ return t.length ? et(t) : null;
1057
1098
  },
1058
1099
  avg: (e) => {
1059
- let t = Xe(e);
1060
- return t.length ? Math.round(Ze(t) / t.length * 100) / 100 : null;
1100
+ let t = $e(e);
1101
+ return t.length ? Math.round(et(t) / t.length * 100) / 100 : null;
1061
1102
  },
1062
1103
  min: (e) => {
1063
- let t = Xe(e);
1064
- return t.length ? Qe(t, !0) : null;
1104
+ let t = $e(e);
1105
+ return t.length ? tt(t, !0) : null;
1065
1106
  },
1066
1107
  max: (e) => {
1067
- let t = Xe(e);
1068
- return t.length ? Qe(t, !1) : null;
1108
+ let t = $e(e);
1109
+ return t.length ? tt(t, !1) : null;
1069
1110
  },
1070
1111
  count: (e, t) => t.length
1071
1112
  };
1072
- function et(e, t, n) {
1073
- return typeof e == "function" ? e(t, n) : $e[e]?.(t, n) ?? null;
1113
+ function rt(e, t, n) {
1114
+ return typeof e == "function" ? e(t, n) : nt[e]?.(t, n) ?? null;
1074
1115
  }
1075
- var tt = class {
1116
+ var it = class {
1076
1117
  grid;
1077
1118
  constructor(e) {
1078
1119
  this.grid = e;
@@ -1093,8 +1134,8 @@ var tt = class {
1093
1134
  get footerLabelColumn() {
1094
1135
  return this.grid.columns.value.visibleLeafs.find((e) => (e.isData || e.isGrouping) && !e.aggregate);
1095
1136
  }
1096
- footerCells = q(() => this.grid.columns.value.visibleLeafs.map((e) => new nt(this.grid, e, this.grid.filteredData, "footer")), () => [this.grid.rows]);
1097
- }, nt = class {
1137
+ footerCells = q(() => this.grid.columns.value.visibleLeafs.map((e) => new at(this.grid, e, this.grid.filteredData, "footer")), () => [this.grid.rows]);
1138
+ }, at = class {
1098
1139
  grid;
1099
1140
  column;
1100
1141
  rows;
@@ -1109,7 +1150,7 @@ var tt = class {
1109
1150
  }
1110
1151
  _value = q(() => {
1111
1152
  let e = this.column.aggregate;
1112
- return e ? et(e, this.values, this.rows) : null;
1153
+ return e ? rt(e, this.values, this.rows) : null;
1113
1154
  });
1114
1155
  get value() {
1115
1156
  let e = this.given?.();
@@ -1124,7 +1165,7 @@ var tt = class {
1124
1165
  get isLast() {
1125
1166
  return !1;
1126
1167
  }
1127
- }, rt = class {
1168
+ }, ot = class {
1128
1169
  grid;
1129
1170
  row;
1130
1171
  column;
@@ -1146,7 +1187,7 @@ var tt = class {
1146
1187
  get cellKind() {
1147
1188
  return this.column.isGrouping ? "grouping" : this.column.isRowSelection ? this.row.selectable ? "selection" : "spacer" : this.row.spans(this.column) ? "hidden" : this.column.aggregate ? "aggregate" : "spacer";
1148
1189
  }
1149
- _aggregate = q(() => this.column.aggregate ? new nt(this.grid, this.column, this.row.allRows.map((e) => e.data), "group", () => this.row.aggregateValue(this.column)) : null);
1190
+ _aggregate = q(() => this.column.aggregate ? new at(this.grid, this.column, this.row.allRows.map((e) => e.data), "group", () => this.row.aggregateValue(this.column)) : null);
1150
1191
  get aggregate() {
1151
1192
  return this._aggregate.value;
1152
1193
  }
@@ -1165,7 +1206,7 @@ var tt = class {
1165
1206
  get hasGroupingBorder() {
1166
1207
  return this.row.groupingColumn.pin === "START";
1167
1208
  }
1168
- }, it = class {
1209
+ }, st = class {
1169
1210
  grid;
1170
1211
  groupColumn;
1171
1212
  rows;
@@ -1199,7 +1240,7 @@ var tt = class {
1199
1240
  let e = this.grid.columns.value.visibleLeafs;
1200
1241
  return this._cells?.leafs !== e && (this._cells = {
1201
1242
  leafs: e,
1202
- cells: e.map((e) => new rt(this.grid, this, e))
1243
+ cells: e.map((e) => new ot(this.grid, this, e))
1203
1244
  }), this._cells;
1204
1245
  }
1205
1246
  get renderedCells() {
@@ -1257,13 +1298,13 @@ var tt = class {
1257
1298
  };
1258
1299
  //#endregion
1259
1300
  //#region src/components/dataGrid/components/dataGridDetailRow.tsx
1260
- function at(e) {
1261
- let { row: t, index: n } = e, { grid: a, parentRow: o } = t, s = a.props.def.rowDetail, c = z(), l = (c?.headerRowCount ?? 0) + n, { ref: u, tabIndex: d, onFocus: f } = ve(c, l, 0), p = t.isAutoHeight, m = N(null);
1301
+ function ct(e) {
1302
+ let { row: t, index: n } = e, { grid: i, parentRow: o } = t, s = i.props.def.rowDetail, c = z(), l = (c?.headerRowCount ?? 0) + n, { ref: u, tabIndex: d, onFocus: f } = be(c, l, 0), p = t.isAutoHeight, m = P(null);
1262
1303
  return r(() => {
1263
- a.takeDetailReveal(o.key) && m.current?.scrollIntoView?.({ block: "nearest" });
1264
- }), /* @__PURE__ */ I(h, {
1304
+ i.takeDetailReveal(o.key) && m.current?.scrollIntoView?.({ block: "nearest" });
1305
+ }), /* @__PURE__ */ L(_, {
1265
1306
  ref: m,
1266
- component: `${a.componentName}.body.detailRow`,
1307
+ component: `${i.componentName}.body.detailRow`,
1267
1308
  transition: "none",
1268
1309
  props: {
1269
1310
  role: "row",
@@ -1273,9 +1314,9 @@ function at(e) {
1273
1314
  gridColumn: "1 / -1",
1274
1315
  height: p ? "auto" : `${t.height}px`
1275
1316
  },
1276
- children: /* @__PURE__ */ I(i, {
1317
+ children: /* @__PURE__ */ L(a, {
1277
1318
  ref: u,
1278
- component: `${a.componentName}.body.detailRow.content`,
1319
+ component: `${i.componentName}.body.detailRow.content`,
1279
1320
  position: "sticky",
1280
1321
  insetStart: 0,
1281
1322
  overflowX: "auto",
@@ -1288,20 +1329,20 @@ function at(e) {
1288
1329
  tabIndex: d,
1289
1330
  onFocus: f
1290
1331
  },
1291
- style: { width: `var(${a.viewportWidthVarName})` },
1332
+ style: { width: `var(${i.viewportWidthVarName})` },
1292
1333
  children: s.content(o.data)
1293
1334
  })
1294
1335
  });
1295
1336
  }
1296
- at.displayName = "DataGridDetailRow";
1297
- var ot = D(at);
1337
+ ct.displayName = "DataGridDetailRow";
1338
+ var lt = A(ct);
1298
1339
  //#endregion
1299
1340
  //#region src/components/dataGrid/components/dataGridAggregateValue.tsx
1300
- function st(e) {
1341
+ function ut(e) {
1301
1342
  let { cell: t } = e, { column: n } = t;
1302
- if (n.AggregateCell) return /* @__PURE__ */ I(n.AggregateCell, { cell: t });
1343
+ if (n.AggregateCell) return /* @__PURE__ */ L(n.AggregateCell, { cell: t });
1303
1344
  let r = t.scope === "footer" ? "footer.cell" : "body.groupRow.aggregate";
1304
- return /* @__PURE__ */ I(i, {
1345
+ return /* @__PURE__ */ L(a, {
1305
1346
  component: `${n.grid.componentName}.${r}`,
1306
1347
  px: 3,
1307
1348
  textOverflow: "ellipsis",
@@ -1310,12 +1351,12 @@ function st(e) {
1310
1351
  children: t.value
1311
1352
  });
1312
1353
  }
1313
- st.displayName = "DataGridAggregateValue";
1354
+ ut.displayName = "DataGridAggregateValue";
1314
1355
  //#endregion
1315
1356
  //#region src/components/dataGrid/components/dataGridCell.tsx
1316
- var ct = "button,a[href],input,select,textarea";
1317
- function J(e) {
1318
- let { children: t, cell: r, row: i, columnIndex: a, ariaColIndex: o, ariaColSpan: s, style: c, ...l } = e, { column: u } = r, d = z(), { ref: f, tabIndex: p, onFocus: m } = ve(d, i, a), { range: g } = u.grid, _ = r instanceof V ? i - (d?.headerRowCount ?? 0) : -1, v = _ >= 0 && g.isCurrent(_, a), y = _ >= 0 && g.isSelected(_, a);
1357
+ var dt = "button,a[href],input,select,textarea";
1358
+ function J(t) {
1359
+ let { children: n, cell: r, row: i, columnIndex: a, ariaColIndex: o, ariaColSpan: s, style: c, ...l } = t, { column: u } = r, d = z(), { ref: f, tabIndex: p, onFocus: m } = be(d, i, a), { range: h } = u.grid, g = r instanceof V ? i - (d?.headerRowCount ?? 0) : -1, v = g >= 0 && h.isCurrent(g, a), y = g >= 0 && h.isSelected(g, a);
1319
1360
  u.hasAlign && (l.jc = u.align);
1320
1361
  let b = r.isExpanded ? {
1321
1362
  ...u.cellVariant.value,
@@ -1337,14 +1378,14 @@ function J(e) {
1337
1378
  ...b,
1338
1379
  isInvalid: !0
1339
1380
  });
1340
- let S = r instanceof V ? (e) => {
1341
- e.target.closest(ct) || (n(e.currentTarget), r.beginEdit());
1342
- } : void 0, C = g.enabled && _ >= 0, w = C ? (e) => {
1343
- e.button === 0 && e.pointerType !== "touch" && (e.target.closest(ct) || g.press(_, a, e.shiftKey));
1344
- } : void 0, T = C && g.isDragging ? (e) => {
1345
- g.dragTo(_, a), e.currentTarget.focus();
1381
+ let S = r instanceof V ? (t) => {
1382
+ t.target.closest(dt) || (e(t.currentTarget), r.beginEdit());
1383
+ } : void 0, C = h.enabled && g >= 0, w = C ? (e) => {
1384
+ e.button === 0 && e.pointerType !== "touch" && (e.target.closest(dt) || h.press(g, a, e.shiftKey));
1385
+ } : void 0, T = C && h.isDragging ? (e) => {
1386
+ h.dragTo(g, a), e.currentTarget.focus();
1346
1387
  } : void 0;
1347
- return /* @__PURE__ */ I(h, {
1388
+ return /* @__PURE__ */ L(_, {
1348
1389
  ref: f,
1349
1390
  component: `${u.grid.componentName}.body.cell`,
1350
1391
  props: {
@@ -1365,31 +1406,31 @@ function J(e) {
1365
1406
  ...c
1366
1407
  },
1367
1408
  ...l,
1368
- children: t
1409
+ children: n
1369
1410
  });
1370
1411
  }
1371
1412
  J.displayName = "DataGridCell";
1372
1413
  //#endregion
1373
1414
  //#region src/components/dataGrid/components/dataGridFooter.tsx
1374
- function lt(e) {
1415
+ function ft(e) {
1375
1416
  let { grid: t } = e, { aggregation: n } = t, r = z();
1376
1417
  if (!n.hasFooter) return null;
1377
- let a = (r?.rowCount ?? 1) - 1, { footerLabelColumn: o, footerLabel: s } = n;
1378
- return /* @__PURE__ */ I(x, {
1418
+ let i = (r?.rowCount ?? 1) - 1, { footerLabelColumn: o, footerLabel: s } = n;
1419
+ return /* @__PURE__ */ L(C, {
1379
1420
  component: `${t.componentName}.footer`,
1380
1421
  props: { role: "rowgroup" },
1381
1422
  style: { gridTemplateColumns: t.gridTemplateColumns.value },
1382
- children: /* @__PURE__ */ I(i, {
1423
+ children: /* @__PURE__ */ L(a, {
1383
1424
  display: "contents",
1384
1425
  props: {
1385
1426
  role: "row",
1386
- "aria-rowindex": a + 1
1427
+ "aria-rowindex": i + 1
1387
1428
  },
1388
- children: n.footerCells.value.map((e, n) => /* @__PURE__ */ I(J, {
1429
+ children: n.footerCells.value.map((e, n) => /* @__PURE__ */ L(J, {
1389
1430
  cell: e,
1390
- row: a,
1431
+ row: i,
1391
1432
  columnIndex: n,
1392
- children: e.column.aggregate ? /* @__PURE__ */ I(st, { cell: e }) : e.column === o ? /* @__PURE__ */ I(i, {
1433
+ children: e.column.aggregate ? /* @__PURE__ */ L(ut, { cell: e }) : e.column === o ? /* @__PURE__ */ L(a, {
1393
1434
  component: `${t.componentName}.footer.label`,
1394
1435
  px: 3,
1395
1436
  textWrap: "nowrap",
@@ -1399,16 +1440,16 @@ function lt(e) {
1399
1440
  })
1400
1441
  });
1401
1442
  }
1402
- lt.displayName = "DataGridFooter";
1443
+ ft.displayName = "DataGridFooter";
1403
1444
  //#endregion
1404
1445
  //#region src/icons/expandIcon.tsx
1405
1446
  function Y(e) {
1406
- return /* @__PURE__ */ I(f, {
1447
+ return /* @__PURE__ */ L(m, {
1407
1448
  viewBox: "4 2 16 18",
1408
1449
  width: "1rem",
1409
1450
  fill: "currentColor",
1410
1451
  ...e,
1411
- children: /* @__PURE__ */ I(d, {
1452
+ children: /* @__PURE__ */ L(p, {
1412
1453
  fillRule: "evenodd",
1413
1454
  d: "M12.707 14.707a1 1 0 0 1-1.414 0l-5-5a1 1 0 0 1 1.414-1.414L12 12.586l4.293-4.293a1 1 0 1 1 1.414 1.414l-5 5Z",
1414
1455
  props: { clipRule: "evenodd" }
@@ -1417,32 +1458,32 @@ function Y(e) {
1417
1458
  }
1418
1459
  //#endregion
1419
1460
  //#region src/components/dataGrid/components/dataGridCellPlaceholder.tsx
1420
- var ut = [
1461
+ var pt = [
1421
1462
  "3/5",
1422
1463
  "2/5",
1423
1464
  "4/5",
1424
1465
  "1/2",
1425
1466
  "7/12"
1426
1467
  ];
1427
- function dt(e) {
1428
- let { cell: t, columnIndex: n } = e, r = ut[(t.row.rowIndex + n) % ut.length];
1429
- return /* @__PURE__ */ I(h, {
1468
+ function mt(e) {
1469
+ let { cell: t, columnIndex: n } = e, r = pt[(t.row.rowIndex + n) % pt.length];
1470
+ return /* @__PURE__ */ L(_, {
1430
1471
  component: `${t.grid.componentName}.body.cell.placeholder`,
1431
1472
  ai: "center",
1432
1473
  px: 3,
1433
1474
  props: { "aria-hidden": !0 },
1434
- children: /* @__PURE__ */ I(i, {
1475
+ children: /* @__PURE__ */ L(a, {
1435
1476
  component: `${t.grid.componentName}.body.cell.placeholder.bar`,
1436
1477
  width: r
1437
1478
  })
1438
1479
  });
1439
1480
  }
1440
- dt.displayName = "DataGridCellPlaceholder";
1481
+ mt.displayName = "DataGridCellPlaceholder";
1441
1482
  //#endregion
1442
1483
  //#region src/components/dataGrid/components/dataGridGroupRow.tsx
1443
- function ft(e) {
1444
- let { row: t, index: n } = e, { selected: r, indeterminate: a, expanded: o, placeholder: s } = t, c = (z()?.headerRowCount ?? 0) + n, l = O(() => t.toggleSelectAll(), [t]);
1445
- return /* @__PURE__ */ I(h, {
1484
+ function ht(e) {
1485
+ let { row: t, index: n } = e, { selected: r, indeterminate: i, expanded: o, placeholder: s } = t, c = (z()?.headerRowCount ?? 0) + n, l = j(() => t.toggleSelectAll(), [t]);
1486
+ return /* @__PURE__ */ L(_, {
1446
1487
  component: `${t.grid.componentName}.body.groupRow`,
1447
1488
  className: "grid-row",
1448
1489
  selected: t.grid.props.def.rowSelection ? r : void 0,
@@ -1455,7 +1496,7 @@ function ft(e) {
1455
1496
  },
1456
1497
  children: t.renderedCells.map(({ cell: e, columnIndex: n }, u) => {
1457
1498
  switch (e.cellKind) {
1458
- case "grouping": return /* @__PURE__ */ I(J, {
1499
+ case "grouping": return /* @__PURE__ */ L(J, {
1459
1500
  cell: e,
1460
1501
  row: c,
1461
1502
  columnIndex: u,
@@ -1469,13 +1510,13 @@ function ft(e) {
1469
1510
  gridColumn: e.gridColumnSpan,
1470
1511
  ps: e.depthPadding,
1471
1512
  overflow: "auto",
1472
- children: s ? /* @__PURE__ */ I(dt, {
1513
+ children: s ? /* @__PURE__ */ L(mt, {
1473
1514
  cell: e,
1474
1515
  columnIndex: u
1475
- }) : /* @__PURE__ */ I(i, {
1516
+ }) : /* @__PURE__ */ L(a, {
1476
1517
  textWrap: "nowrap",
1477
1518
  px: 3,
1478
- children: /* @__PURE__ */ L(p, {
1519
+ children: /* @__PURE__ */ R(h, {
1479
1520
  component: `${t.grid.componentName}.body.groupRow.expandButton`,
1480
1521
  onClick: () => t.toggleRow(),
1481
1522
  cursor: "pointer",
@@ -1486,7 +1527,7 @@ function ft(e) {
1486
1527
  tabIndex: -1,
1487
1528
  "aria-expanded": o
1488
1529
  },
1489
- children: [/* @__PURE__ */ I(Y, {
1530
+ children: [/* @__PURE__ */ L(Y, {
1490
1531
  fill: "currentColor",
1491
1532
  width: "14px",
1492
1533
  height: "14px",
@@ -1495,16 +1536,16 @@ function ft(e) {
1495
1536
  })
1496
1537
  })
1497
1538
  }, e.column.key);
1498
- case "selection": return /* @__PURE__ */ I(J, {
1539
+ case "selection": return /* @__PURE__ */ L(J, {
1499
1540
  cell: e,
1500
1541
  row: c,
1501
1542
  columnIndex: u,
1502
1543
  ariaColIndex: n + 1,
1503
- children: /* @__PURE__ */ I(g, {
1544
+ children: /* @__PURE__ */ L(v, {
1504
1545
  variant: "datagrid",
1505
1546
  m: 1,
1506
1547
  checked: r,
1507
- indeterminate: a,
1548
+ indeterminate: i,
1508
1549
  onChange: l,
1509
1550
  props: {
1510
1551
  tabIndex: -1,
@@ -1512,14 +1553,14 @@ function ft(e) {
1512
1553
  }
1513
1554
  })
1514
1555
  }, e.column.key);
1515
- case "aggregate": return /* @__PURE__ */ I(J, {
1556
+ case "aggregate": return /* @__PURE__ */ L(J, {
1516
1557
  cell: e,
1517
1558
  row: c,
1518
1559
  columnIndex: u,
1519
1560
  ariaColIndex: n + 1,
1520
- children: e.aggregate && /* @__PURE__ */ I(st, { cell: e.aggregate })
1561
+ children: e.aggregate && /* @__PURE__ */ L(ut, { cell: e.aggregate })
1521
1562
  }, e.column.key);
1522
- case "spacer": return /* @__PURE__ */ I(J, {
1563
+ case "spacer": return /* @__PURE__ */ L(J, {
1523
1564
  cell: e,
1524
1565
  row: c,
1525
1566
  columnIndex: u,
@@ -1532,21 +1573,21 @@ function ft(e) {
1532
1573
  })
1533
1574
  });
1534
1575
  }
1535
- ft.displayName = "DataGridGroupRow";
1536
- var pt = D(ft), mt = "input:not([type=\"hidden\"]),select,textarea,button,[role=\"spinbutton\"]";
1537
- function ht(e) {
1576
+ ht.displayName = "DataGridGroupRow";
1577
+ var gt = A(ht), _t = "input:not([type=\"hidden\"]),select,textarea,button,[role=\"spinbutton\"]";
1578
+ function vt(e) {
1538
1579
  let { options: t } = e.editor;
1539
1580
  return typeof t == "function" ? t(e.row.data) : t ?? [];
1540
1581
  }
1541
- function gt(e) {
1542
- let { cell: t, row: n, columnIndex: i } = e, { grid: a } = t, o = z(), s = N(null), c = u("datagrid-cell-error"), { error: l, pending: d } = t;
1582
+ function yt(e) {
1583
+ let { cell: t, row: n, columnIndex: i } = e, { grid: a } = t, o = z(), s = P(null), c = d("datagrid-cell-error"), { error: l, pending: u } = t;
1543
1584
  r(() => {
1544
- let e = s.current?.querySelector(mt);
1585
+ let e = s.current?.querySelector(_t);
1545
1586
  e?.focus(), e instanceof HTMLInputElement && e.type !== "checkbox" && e.select();
1546
1587
  }, []);
1547
- let f = O(() => {
1588
+ let f = j(() => {
1548
1589
  s.current?.closest("[role=\"gridcell\"]")?.focus();
1549
- }, []), p = O((e) => {
1590
+ }, []), p = j((e) => {
1550
1591
  if (!o) return;
1551
1592
  let t = a.edits.nextEditable(n - o.headerRowCount, i, e.shiftKey);
1552
1593
  t && (e.preventDefault(), o.setActiveCell(t.row + o.headerRowCount, t.column, { reason: "programmatic" }), a.edits.beginAt(t.row, t.column));
@@ -1555,7 +1596,7 @@ function gt(e) {
1555
1596
  a,
1556
1597
  o,
1557
1598
  n
1558
- ]), m = O((e) => {
1599
+ ]), m = j((e) => {
1559
1600
  if (e.key === "Escape") {
1560
1601
  if (s.current?.querySelector("[aria-expanded=\"true\"]")) return;
1561
1602
  e.preventDefault(), e.stopPropagation(), t.cancelEdit(), f();
@@ -1576,23 +1617,23 @@ function gt(e) {
1576
1617
  t,
1577
1618
  f,
1578
1619
  p
1579
- ]), g = O(() => {
1620
+ ]), h = j(() => {
1580
1621
  !t.editing || t.pending || t.commitEdit();
1581
1622
  }, [t]);
1582
- return /* @__PURE__ */ L(h, {
1623
+ return /* @__PURE__ */ R(_, {
1583
1624
  ref: s,
1584
1625
  component: `${a.componentName}.body.cell.editor`,
1585
- variant: { isPending: d },
1626
+ variant: { isPending: u },
1586
1627
  props: { onKeyDown: m },
1587
1628
  width: "fit",
1588
1629
  height: "fit",
1589
1630
  ai: "center",
1590
- children: [/* @__PURE__ */ I(_t, {
1631
+ children: [/* @__PURE__ */ L(bt, {
1591
1632
  cell: t,
1592
1633
  errorId: l ? c : void 0,
1593
- onBlur: g,
1634
+ onBlur: h,
1594
1635
  onCommitted: f
1595
- }), l && /* @__PURE__ */ I(_, {
1636
+ }), l && /* @__PURE__ */ L(y, {
1596
1637
  anchor: s,
1597
1638
  side: "bottom",
1598
1639
  align: "start",
@@ -1605,24 +1646,24 @@ function gt(e) {
1605
1646
  })]
1606
1647
  });
1607
1648
  }
1608
- function _t(e) {
1609
- let { cell: t, errorId: n, onBlur: r, onCommitted: i } = e, { EditCell: a } = t.column.def, { type: o, placeholder: s, step: c, min: l, max: u } = t.editor, d = t.column.header ?? t.column.key, f = {
1649
+ function bt(e) {
1650
+ let { cell: t, errorId: n, onBlur: r, onCommitted: i } = e, { EditCell: a } = t.column.def, { type: o, placeholder: s, step: c, min: l, max: u } = t.editor, d = t.column.header ?? t.column.key, p = {
1610
1651
  "aria-label": t.grid.localeText.editCell(String(d)),
1611
1652
  "aria-invalid": n ? !0 : void 0,
1612
1653
  "aria-describedby": n
1613
- }, p = Te(Me(o));
1614
- if (a) return /* @__PURE__ */ I(a, { cell: t });
1615
- if (o === "checkbox") return /* @__PURE__ */ I(g, {
1654
+ }, m = De(Pe(o));
1655
+ if (a) return /* @__PURE__ */ L(a, { cell: t });
1656
+ if (o === "checkbox") return /* @__PURE__ */ L(v, {
1616
1657
  checked: !!t.draft,
1617
1658
  onChange: (e) => {
1618
1659
  t.setDraft(e.target.checked), t.commitEdit(), i();
1619
1660
  },
1620
1661
  props: {
1621
- ...f,
1662
+ ...p,
1622
1663
  onBlur: r
1623
1664
  }
1624
1665
  });
1625
- if (o === "select") return /* @__PURE__ */ I(S, {
1666
+ if (o === "select") return /* @__PURE__ */ L(f, { children: /* @__PURE__ */ L(w, {
1626
1667
  value: t.draft,
1627
1668
  defaultOpen: !0,
1628
1669
  width: "fit",
@@ -1633,21 +1674,21 @@ function _t(e) {
1633
1674
  onValueChange: (e) => {
1634
1675
  t.setDraft(e ?? null), t.commitEdit(), i();
1635
1676
  },
1636
- props: f,
1637
- children: ht(t).map((e) => /* @__PURE__ */ I(S.Item, {
1677
+ props: p,
1678
+ children: vt(t).map((e) => /* @__PURE__ */ L(w.Item, {
1638
1679
  value: e.value,
1639
1680
  children: e.label ?? String(e.value)
1640
1681
  }, String(e.value)))
1641
- });
1642
- if (Me(o)) return p ? /* @__PURE__ */ I(p.DateEditor, {
1682
+ }) });
1683
+ if (Pe(o)) return m ? /* @__PURE__ */ L(m.DateEditor, {
1643
1684
  cell: t,
1644
- label: f["aria-label"],
1685
+ label: p["aria-label"],
1645
1686
  errorId: n,
1646
1687
  onBlur: r
1647
1688
  }) : null;
1648
- let m = o === "number";
1649
- return /* @__PURE__ */ I(y, {
1650
- type: m ? "number" : "text",
1689
+ let h = o === "number";
1690
+ return /* @__PURE__ */ L(x, {
1691
+ type: h ? "number" : "text",
1651
1692
  value: t.draft === null || t.draft === void 0 ? "" : String(t.draft),
1652
1693
  placeholder: s,
1653
1694
  step: c,
@@ -1658,94 +1699,94 @@ function _t(e) {
1658
1699
  focus: { outline: 0 },
1659
1700
  onChange: (e) => {
1660
1701
  let n = e.target.value;
1661
- t.setDraft(m ? n === "" ? null : Number(n) : n);
1702
+ t.setDraft(h ? n === "" ? null : Number(n) : n);
1662
1703
  },
1663
1704
  props: {
1664
- ...f,
1705
+ ...p,
1665
1706
  min: l,
1666
1707
  max: u,
1667
1708
  onBlur: r
1668
1709
  }
1669
1710
  });
1670
1711
  }
1671
- gt.displayName = "DataGridCellEditor";
1712
+ yt.displayName = "DataGridCellEditor";
1672
1713
  //#endregion
1673
1714
  //#region src/components/dataGrid/components/dataGridBooleanValue.tsx
1674
- function vt(e) {
1715
+ function xt(e) {
1675
1716
  let { value: t, text: n } = e;
1676
- return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ I(f, {
1717
+ return /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(m, {
1677
1718
  viewBox: "0 0 16 16",
1678
1719
  width: "1rem",
1679
1720
  height: "1rem",
1680
1721
  css: { verticalAlign: "middle" },
1681
1722
  color: t ? void 0 : "base-400",
1682
1723
  props: { fill: "none" },
1683
- children: /* @__PURE__ */ I(d, {
1724
+ children: /* @__PURE__ */ L(p, {
1684
1725
  d: t ? "m3.5 8.5 3 3 6-7" : "m5 5 6 6m0-6-6 6",
1685
1726
  stroke: "currentColor",
1686
1727
  strokeWidth: 1.75,
1687
1728
  strokeLinecap: "round",
1688
1729
  strokeLinejoin: "round"
1689
1730
  })
1690
- }), /* @__PURE__ */ I(m, {
1731
+ }), /* @__PURE__ */ L(g, {
1691
1732
  tag: "span",
1692
1733
  children: t ? n.booleanTrue : n.booleanFalse
1693
1734
  })] });
1694
1735
  }
1695
- vt.displayName = "DataGridBooleanValue";
1736
+ xt.displayName = "DataGridBooleanValue";
1696
1737
  //#endregion
1697
1738
  //#region src/components/dataGrid/components/dataGridDateValue.tsx
1698
- function yt(e, t) {
1739
+ function St(e, t) {
1699
1740
  if (e.def.dateFormat) return e.def.dateFormat;
1700
1741
  let { editor: n } = e.def, r = typeof n == "object" ? n.type : n;
1701
- return r && Me(r) ? r : t instanceof Date ? "datetime" : null;
1742
+ return r && Pe(r) ? r : t instanceof Date ? "datetime" : null;
1702
1743
  }
1703
- function bt(e) {
1704
- let { value: t, format: n } = e, r = Te(!0);
1705
- return r ? /* @__PURE__ */ I(r.DateValue, {
1744
+ function Ct(e) {
1745
+ let { value: t, format: n } = e, r = De(!0);
1746
+ return r ? /* @__PURE__ */ L(r.DateValue, {
1706
1747
  value: t,
1707
1748
  format: n
1708
- }) : /* @__PURE__ */ I(F, { children: t instanceof Date ? t.toISOString() : t == null ? "" : String(t) });
1749
+ }) : /* @__PURE__ */ L(I, { children: t instanceof Date ? t.toISOString() : t == null ? "" : String(t) });
1709
1750
  }
1710
- bt.displayName = "DataGridDateValue";
1751
+ Ct.displayName = "DataGridDateValue";
1711
1752
  //#endregion
1712
1753
  //#region src/components/dataGrid/components/dataGridCellText.tsx
1713
- function xt(e) {
1714
- let { cell: t } = e, { value: n } = t, r = yt(t.column, n);
1715
- return /* @__PURE__ */ I(h, {
1754
+ function wt(e) {
1755
+ let { cell: t } = e, { value: n } = t, r = St(t.column, n);
1756
+ return /* @__PURE__ */ L(_, {
1716
1757
  component: `${t.grid.componentName}.body.cell.text`,
1717
1758
  height: "fit",
1718
1759
  width: "fit",
1719
1760
  overflow: "auto",
1720
1761
  ai: "center",
1721
1762
  jc: t.column.align,
1722
- children: /* @__PURE__ */ I(i, {
1763
+ children: /* @__PURE__ */ L(a, {
1723
1764
  px: 3,
1724
1765
  textOverflow: "ellipsis",
1725
1766
  overflow: "hidden",
1726
1767
  textWrap: "nowrap",
1727
- children: typeof n == "boolean" ? /* @__PURE__ */ I(vt, {
1768
+ children: typeof n == "boolean" ? /* @__PURE__ */ L(xt, {
1728
1769
  value: n,
1729
1770
  text: t.grid.localeText
1730
- }) : r ? /* @__PURE__ */ I(bt, {
1771
+ }) : r ? /* @__PURE__ */ L(Ct, {
1731
1772
  value: n,
1732
1773
  format: r
1733
1774
  }) : n
1734
1775
  })
1735
1776
  });
1736
1777
  }
1737
- xt.displayName = "DataGridCellText";
1778
+ wt.displayName = "DataGridCellText";
1738
1779
  //#endregion
1739
1780
  //#region src/components/dataGrid/components/dataGridCellTree.tsx
1740
- function St(e) {
1741
- let { cell: t, row: n, children: r } = e, { hasChildren: a, treeExpanded: o, level: s } = n, c = n.grid.componentName, l = O((e) => {
1781
+ function Tt(e) {
1782
+ let { cell: t, row: n, children: r } = e, { hasChildren: i, treeExpanded: o, level: s } = n, c = n.grid.componentName, l = j((e) => {
1742
1783
  e.stopPropagation(), n.toggleTree();
1743
1784
  }, [n]), u = t.value == null || t.value === "" ? t.grid.localeText.unnamedRow(n.rowIndex + 1) : String(t.value);
1744
- return /* @__PURE__ */ L(h, {
1785
+ return /* @__PURE__ */ R(_, {
1745
1786
  component: `${c}.body.cell.tree`,
1746
1787
  ai: "center",
1747
1788
  ps: s * n.grid.tree.indent,
1748
- children: [a ? /* @__PURE__ */ I(p, {
1789
+ children: [i ? /* @__PURE__ */ L(h, {
1749
1790
  component: `${c}.body.cell.tree.toggle`,
1750
1791
  variant: { isExpanded: o },
1751
1792
  type: "button",
@@ -1758,13 +1799,13 @@ function St(e) {
1758
1799
  tabIndex: -1,
1759
1800
  "aria-label": (o ? t.grid.localeText.collapseTreeRow : t.grid.localeText.expandTreeRow)(u)
1760
1801
  },
1761
- children: /* @__PURE__ */ I(Y, {
1802
+ children: /* @__PURE__ */ L(Y, {
1762
1803
  fill: "currentColor",
1763
1804
  width: "14px",
1764
1805
  height: "14px",
1765
1806
  rotate: o ? 0 : -90
1766
1807
  })
1767
- }) : /* @__PURE__ */ I(i, { component: `${c}.body.cell.tree.spacer` }), /* @__PURE__ */ I(i, {
1808
+ }) : /* @__PURE__ */ L(a, { component: `${c}.body.cell.tree.spacer` }), /* @__PURE__ */ L(a, {
1768
1809
  textOverflow: "ellipsis",
1769
1810
  overflow: "hidden",
1770
1811
  textWrap: "nowrap",
@@ -1773,29 +1814,29 @@ function St(e) {
1773
1814
  })]
1774
1815
  });
1775
1816
  }
1776
- St.displayName = "DataGridCellTree";
1817
+ Tt.displayName = "DataGridCellTree";
1777
1818
  //#endregion
1778
1819
  //#region src/components/dataGrid/components/dataGridRow.tsx
1779
- function Ct(e) {
1780
- let { row: t, index: n } = e, { selected: r, expandOnRowClick: i } = t, a = (z()?.headerRowCount ?? 0) + n, o = W(t) ? t : void 0, s = o && t.grid.tree.columnKey, c = O(() => {
1820
+ function Et(e) {
1821
+ let { row: t, index: n } = e, { selected: r, expandOnRowClick: i } = t, a = (z()?.headerRowCount ?? 0) + n, o = W(t) ? t : void 0, s = o && t.grid.tree.columnKey, c = j(() => {
1781
1822
  t.toggleDetail();
1782
1823
  }, [t]), l = (e, n) => {
1783
- if (e.editing) return /* @__PURE__ */ I(gt, {
1824
+ if (e.editing) return /* @__PURE__ */ L(yt, {
1784
1825
  cell: e,
1785
1826
  row: a,
1786
1827
  columnIndex: n
1787
1828
  });
1788
- let r = t.placeholder && !e.column.isRowNumber ? /* @__PURE__ */ I(dt, {
1829
+ let r = t.placeholder && !e.column.isRowNumber ? /* @__PURE__ */ L(mt, {
1789
1830
  cell: e,
1790
1831
  columnIndex: n
1791
- }) : e.column.Cell ? /* @__PURE__ */ I(e.column.Cell, { cell: e }) : /* @__PURE__ */ I(xt, { cell: e });
1792
- return !o || e.column.key !== s ? r : /* @__PURE__ */ I(St, {
1832
+ }) : e.column.Cell ? /* @__PURE__ */ L(e.column.Cell, { cell: e }) : /* @__PURE__ */ L(wt, { cell: e });
1833
+ return !o || e.column.key !== s ? r : /* @__PURE__ */ L(Tt, {
1793
1834
  cell: e,
1794
1835
  row: o,
1795
1836
  children: r
1796
1837
  });
1797
1838
  };
1798
- return /* @__PURE__ */ I(h, {
1839
+ return /* @__PURE__ */ L(_, {
1799
1840
  component: `${t.grid.componentName}.body.row`,
1800
1841
  className: "grid-row",
1801
1842
  selected: t.grid.props.def.rowSelection ? r : void 0,
@@ -1811,7 +1852,7 @@ function Ct(e) {
1811
1852
  onClick: i ? c : void 0
1812
1853
  },
1813
1854
  cursor: i ? "pointer" : void 0,
1814
- children: t.cells.map((e, t) => /* @__PURE__ */ I(J, {
1855
+ children: t.cells.map((e, t) => /* @__PURE__ */ L(J, {
1815
1856
  cell: e,
1816
1857
  row: a,
1817
1858
  columnIndex: t,
@@ -1819,37 +1860,37 @@ function Ct(e) {
1819
1860
  }, e.column.key))
1820
1861
  });
1821
1862
  }
1822
- Ct.displayName = "DataGridRow";
1823
- var wt = D(Ct);
1863
+ Et.displayName = "DataGridRow";
1864
+ var Dt = A(Et);
1824
1865
  //#endregion
1825
1866
  //#region src/components/dataGrid/components/dataGridBody.tsx
1826
- function Tt(e, t, n) {
1827
- return e instanceof H ? /* @__PURE__ */ I(ot, {
1867
+ function Ot(e, t, n) {
1868
+ return e instanceof H ? /* @__PURE__ */ L(lt, {
1828
1869
  row: e,
1829
1870
  index: t,
1830
1871
  version: n
1831
- }, e.key) : e instanceof it ? /* @__PURE__ */ I(pt, {
1872
+ }, e.key) : e instanceof st ? /* @__PURE__ */ L(gt, {
1832
1873
  row: e,
1833
1874
  index: t,
1834
1875
  version: n
1835
- }, e.key) : /* @__PURE__ */ I(wt, {
1876
+ }, e.key) : /* @__PURE__ */ L(Dt, {
1836
1877
  row: e,
1837
1878
  index: t,
1838
1879
  version: n
1839
1880
  }, e.key);
1840
1881
  }
1841
- function Et(e) {
1842
- let { grid: t, scroll: n } = e, { viewport: r } = t, { startIndex: a, take: o, translateY: s, totalHeight: c, viewHeight: l } = r.window(n.top, n.direction), u = r.showAll, d = r.isEmpty, f = t.flatRows.value, p = t.getSnapshot(), m = M(() => d ? null : G.take(f, o, a).map((e, n) => Tt(e, a + n, t.rowVersion(e, a + n))), [
1882
+ function kt(e) {
1883
+ let { grid: t, scroll: n } = e, { viewport: r } = t, { startIndex: i, take: o, translateY: s, totalHeight: c, viewHeight: l } = r.window(n.top, n.direction), u = r.showAll, d = r.isEmpty, f = t.flatRows.value, p = t.getSnapshot(), m = ie(() => d ? null : G.take(f, o, i).map((e, n) => Ot(e, i + n, t.rowVersion(e, i + n))), [
1843
1884
  f,
1844
1885
  t,
1845
1886
  d,
1846
1887
  o,
1847
- a,
1888
+ i,
1848
1889
  p
1849
1890
  ]);
1850
1891
  if (d) {
1851
1892
  let { noDataComponent: e } = t.props.def, n = t.props.loading ? t.localeText.loadingRows : t.localeText.noRows;
1852
- return /* @__PURE__ */ I(h, {
1893
+ return /* @__PURE__ */ L(_, {
1853
1894
  component: `${t.componentName}.body.empty`,
1854
1895
  jc: "center",
1855
1896
  ai: "center",
@@ -1858,14 +1899,14 @@ function Et(e) {
1858
1899
  insetStart: 0,
1859
1900
  props: { role: "row" },
1860
1901
  style: { height: r.emptyHeight },
1861
- children: /* @__PURE__ */ I(i, {
1902
+ children: /* @__PURE__ */ L(a, {
1862
1903
  display: "contents",
1863
1904
  props: { role: "gridcell" },
1864
1905
  children: e ?? n
1865
1906
  })
1866
1907
  });
1867
1908
  }
1868
- return u ? /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ I(x, {
1909
+ return u ? /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(C, {
1869
1910
  component: `${t.componentName}.body`,
1870
1911
  width: "max-content",
1871
1912
  minWidth: "fit",
@@ -1874,13 +1915,13 @@ function Et(e) {
1874
1915
  props: { role: "rowgroup" },
1875
1916
  style: { gridTemplateColumns: t.gridTemplateColumns.value },
1876
1917
  children: m
1877
- }), /* @__PURE__ */ I(lt, { grid: t })] }) : /* @__PURE__ */ L(i, {
1918
+ }), /* @__PURE__ */ L(ft, { grid: t })] }) : /* @__PURE__ */ R(a, {
1878
1919
  props: { role: "presentation" },
1879
1920
  style: { height: l },
1880
- children: [/* @__PURE__ */ I(i, {
1921
+ children: [/* @__PURE__ */ L(a, {
1881
1922
  props: { role: "presentation" },
1882
1923
  style: { height: `${c}px` },
1883
- children: /* @__PURE__ */ I(x, {
1924
+ children: /* @__PURE__ */ L(C, {
1884
1925
  component: `${t.componentName}.body`,
1885
1926
  width: "max-content",
1886
1927
  minWidth: "fit",
@@ -1894,15 +1935,15 @@ function Et(e) {
1894
1935
  },
1895
1936
  children: m
1896
1937
  })
1897
- }), /* @__PURE__ */ I(lt, { grid: t })]
1938
+ }), /* @__PURE__ */ L(ft, { grid: t })]
1898
1939
  });
1899
1940
  }
1900
- Et.displayName = "DataGridBody";
1941
+ kt.displayName = "DataGridBody";
1901
1942
  //#endregion
1902
1943
  //#region src/components/dataGrid/components/dataGridEmptyColumns.tsx
1903
- function Dt(e) {
1944
+ function At(e) {
1904
1945
  let { grid: t } = e;
1905
- return /* @__PURE__ */ I(h, {
1946
+ return /* @__PURE__ */ L(_, {
1906
1947
  component: `${t.componentName}.emptyColumns`,
1907
1948
  d: "column",
1908
1949
  ai: "center",
@@ -1913,11 +1954,11 @@ function Dt(e) {
1913
1954
  bgColor: "base-50",
1914
1955
  borderRadius: 4,
1915
1956
  theme: { dark: { bgColor: "base-900" } },
1916
- children: /* @__PURE__ */ L(h, {
1957
+ children: /* @__PURE__ */ R(_, {
1917
1958
  d: "column",
1918
1959
  ai: "center",
1919
1960
  gap: 3,
1920
- children: [/* @__PURE__ */ I(i, {
1961
+ children: [/* @__PURE__ */ L(a, {
1921
1962
  width: 16,
1922
1963
  height: 16,
1923
1964
  borderRadius: 999,
@@ -1926,29 +1967,29 @@ function Dt(e) {
1926
1967
  display: "flex",
1927
1968
  ai: "center",
1928
1969
  jc: "center",
1929
- children: /* @__PURE__ */ I(f, {
1970
+ children: /* @__PURE__ */ L(m, {
1930
1971
  viewBox: "0 0 24 24",
1931
1972
  width: "40",
1932
1973
  fill: "currentColor",
1933
1974
  color: "base-400",
1934
1975
  theme: { dark: { color: "base-500" } },
1935
- children: /* @__PURE__ */ I(d, {
1976
+ children: /* @__PURE__ */ L(p, {
1936
1977
  fillRule: "evenodd",
1937
1978
  props: { clipRule: "evenodd" },
1938
1979
  d: "M3 6a3 3 0 013-3h12a3 3 0 013 3v12a3 3 0 01-3 3H6a3 3 0 01-3-3V6zm3-1a1 1 0 00-1 1v12a1 1 0 001 1h12a1 1 0 001-1V6a1 1 0 00-1-1H6zm2 3a1 1 0 011-1h6a1 1 0 110 2H9a1 1 0 01-1-1zm0 4a1 1 0 011-1h6a1 1 0 110 2H9a1 1 0 01-1-1zm0 4a1 1 0 011-1h4a1 1 0 110 2H9a1 1 0 01-1-1z"
1939
1980
  })
1940
1981
  })
1941
- }), /* @__PURE__ */ L(h, {
1982
+ }), /* @__PURE__ */ R(_, {
1942
1983
  d: "column",
1943
1984
  ai: "center",
1944
1985
  gap: 1,
1945
- children: [/* @__PURE__ */ I(i, {
1986
+ children: [/* @__PURE__ */ L(a, {
1946
1987
  fontSize: 18,
1947
1988
  fontWeight: 600,
1948
1989
  color: "base-900",
1949
1990
  theme: { dark: { color: "base-50" } },
1950
1991
  children: t.localeText.noColumnsTitle
1951
- }), /* @__PURE__ */ I(i, {
1992
+ }), /* @__PURE__ */ L(a, {
1952
1993
  fontSize: 14,
1953
1994
  color: "base-500",
1954
1995
  textAlign: "center",
@@ -1961,7 +2002,7 @@ function Dt(e) {
1961
2002
  }
1962
2003
  //#endregion
1963
2004
  //#region src/utils/dataGrid/headerCellUtils.ts
1964
- var Ot;
2005
+ var jt;
1965
2006
  (function(e) {
1966
2007
  let t = e.CELL_SELECTOR = "[role=\"columnheader\"][aria-sort]", n = ".resizer", r = `button, input, a, [role="menu"], [role="separator"], ${n}`;
1967
2008
  function i(e, t) {
@@ -2036,8 +2077,8 @@ var Ot;
2036
2077
  } : e;
2037
2078
  }
2038
2079
  e.pause = u;
2039
- })(Ot ||= {});
2040
- var X = Ot, kt;
2080
+ })(jt ||= {});
2081
+ var X = jt, Mt;
2041
2082
  (function(e) {
2042
2083
  function t(e, t) {
2043
2084
  return (t?.type === "text" ? t.value : "") === (e.trim() ? e : "");
@@ -2064,31 +2105,31 @@ var X = Ot, kt;
2064
2105
  return t.valueTo === void 0 ? isNaN(r) : t.valueTo === r;
2065
2106
  }
2066
2107
  e.numberMatches = r;
2067
- })(kt ||= {});
2068
- var Z = kt, At = 300;
2069
- function jt(e, t, n) {
2070
- let i = N(/* @__PURE__ */ new Map()), o = O(() => {
2108
+ })(Mt ||= {});
2109
+ var Z = Mt, Nt = 300;
2110
+ function Pt(e, t, n) {
2111
+ let i = P(/* @__PURE__ */ new Map()), a = j(() => {
2071
2112
  for (let e of i.current.values()) clearTimeout(e);
2072
2113
  i.current.clear();
2073
- }, []), s = O((e, t) => {
2114
+ }, []), s = j((e, t) => {
2074
2115
  clearTimeout(i.current.get(e)), i.current.set(e, setTimeout(() => {
2075
2116
  i.current.delete(e), t();
2076
- }, At));
2117
+ }, Nt));
2077
2118
  }, []);
2078
- A(() => o, [o]);
2079
- let c = a(() => {
2080
- t(e) || (o(), n(e));
2119
+ N(() => a, [a]);
2120
+ let c = o(() => {
2121
+ t(e) || (a(), n(e));
2081
2122
  });
2082
2123
  return r(c, [e, c]), {
2083
2124
  debounce: s,
2084
- cancel: o
2125
+ cancel: a
2085
2126
  };
2086
2127
  }
2087
2128
  //#endregion
2088
2129
  //#region src/components/dataGrid/components/dataGridColumnFilter.tsx
2089
- function Mt(e) {
2130
+ function Ft(e) {
2090
2131
  let { label: t, onClear: n } = e;
2091
- return /* @__PURE__ */ I(p, {
2132
+ return /* @__PURE__ */ L(h, {
2092
2133
  clean: !0,
2093
2134
  type: "button",
2094
2135
  position: "absolute",
@@ -2103,7 +2144,7 @@ function Mt(e) {
2103
2144
  tabIndex: -1,
2104
2145
  "aria-label": t
2105
2146
  },
2106
- children: /* @__PURE__ */ I(i, {
2147
+ children: /* @__PURE__ */ L(a, {
2107
2148
  fontSize: 10,
2108
2149
  color: "base-400",
2109
2150
  hover: { color: "base-600" },
@@ -2111,16 +2152,16 @@ function Mt(e) {
2111
2152
  })
2112
2153
  });
2113
2154
  }
2114
- function Nt({ column: e }) {
2115
- let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), i = e.grid.localeText, [a, o] = P(t?.type === "text" ? t.value : ""), { debounce: s, cancel: c } = jt(t, (e) => Z.textMatches(a, e), (e) => o(e?.type === "text" ? e.value : "")), l = O((t) => {
2155
+ function It({ column: e }) {
2156
+ let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), i = e.grid.localeText, [a, o] = F(t?.type === "text" ? t.value : ""), { debounce: s, cancel: c } = Pt(t, (e) => Z.textMatches(a, e), (e) => o(e?.type === "text" ? e.value : "")), l = j((t) => {
2116
2157
  let n = t.target.value;
2117
2158
  o(n), s("value", () => e.setTextFilter(n));
2118
- }, [e, s]), u = O(() => {
2159
+ }, [e, s]), u = j(() => {
2119
2160
  c(), o(""), e.clearFilter();
2120
2161
  }, [e, c]);
2121
- return /* @__PURE__ */ L(h, {
2162
+ return /* @__PURE__ */ R(_, {
2122
2163
  component: `${n}.filter.cell.input`,
2123
- children: [/* @__PURE__ */ I(y, {
2164
+ children: [/* @__PURE__ */ L(x, {
2124
2165
  width: "fit",
2125
2166
  variant: "compact",
2126
2167
  placeholder: e.filterConfig?.placeholder ?? i.filterPlaceholder,
@@ -2133,19 +2174,19 @@ function Nt({ column: e }) {
2133
2174
  tabIndex: -1,
2134
2175
  "aria-label": i.filterColumn(r)
2135
2176
  }
2136
- }), a && /* @__PURE__ */ I(Mt, {
2177
+ }), a && /* @__PURE__ */ L(Ft, {
2137
2178
  label: i.clearFilter(r),
2138
2179
  onClear: u
2139
2180
  })]
2140
2181
  });
2141
2182
  }
2142
- function Pt({ column: e }) {
2143
- let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), i = e.grid.localeText, [a, o] = P(() => Z.numberDraft(t)), s = N(a), c = O((e) => {
2183
+ function Lt({ column: e }) {
2184
+ let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), i = e.grid.localeText, [a, o] = F(() => Z.numberDraft(t)), s = P(a), c = j((e) => {
2144
2185
  s.current = e, o(e);
2145
- }, []), { debounce: l, cancel: u } = jt(t, (e) => Z.numberMatches(a, e), (e) => c(Z.numberDraft(e))), { operator: d, value: f, valueTo: p } = a, m = e.filterConfig, g = O(() => {
2186
+ }, []), { debounce: l, cancel: u } = Pt(t, (e) => Z.numberMatches(a, e), (e) => c(Z.numberDraft(e))), { operator: d, value: p, valueTo: m } = a, h = e.filterConfig, g = j(() => {
2146
2187
  let { operator: t, value: n, valueTo: r } = s.current;
2147
2188
  e.setNumberFilter(t, n, r);
2148
- }, [e]), _ = O((e, t) => {
2189
+ }, [e]), v = j((e, t) => {
2149
2190
  c({
2150
2191
  ...s.current,
2151
2192
  ...e
@@ -2155,21 +2196,21 @@ function Pt({ column: e }) {
2155
2196
  g,
2156
2197
  l,
2157
2198
  u
2158
- ]), v = O((e) => _({ value: e.target.value }, !0), [_]), b = O((e) => _({ valueTo: e.target.value }, !0), [_]), x = O((e) => _({ operator: e }, !1), [_]), C = O(() => {
2199
+ ]), y = j((e) => v({ value: e.target.value }, !0), [v]), b = j((e) => v({ valueTo: e.target.value }, !0), [v]), S = j((e) => v({ operator: e }, !1), [v]), C = j(() => {
2159
2200
  u(), c(Z.numberDraft(void 0)), e.clearFilter();
2160
2201
  }, [
2161
2202
  e,
2162
2203
  u,
2163
2204
  c
2164
2205
  ]);
2165
- return /* @__PURE__ */ L(h, {
2206
+ return /* @__PURE__ */ R(_, {
2166
2207
  component: `${n}.filter.cell.input`,
2167
2208
  ai: d === "between" ? "start" : "center",
2168
2209
  gap: 1,
2169
- children: [/* @__PURE__ */ L(S, {
2210
+ children: [/* @__PURE__ */ L(f, { children: /* @__PURE__ */ R(w, {
2170
2211
  value: d,
2171
2212
  variant: "compact",
2172
- onChange: (e) => e && x(e),
2213
+ onChange: (e) => e && S(e),
2173
2214
  minWidth: 6,
2174
2215
  hideIcon: !0,
2175
2216
  b: 0,
@@ -2180,51 +2221,51 @@ function Pt({ column: e }) {
2180
2221
  "aria-label": i.filterComparison(r)
2181
2222
  },
2182
2223
  children: [
2183
- /* @__PURE__ */ I(S.Item, {
2224
+ /* @__PURE__ */ L(w.Item, {
2184
2225
  value: "eq",
2185
2226
  children: "="
2186
2227
  }),
2187
- /* @__PURE__ */ I(S.Item, {
2228
+ /* @__PURE__ */ L(w.Item, {
2188
2229
  value: "ne",
2189
2230
  children: "≠"
2190
2231
  }),
2191
- /* @__PURE__ */ I(S.Item, {
2232
+ /* @__PURE__ */ L(w.Item, {
2192
2233
  value: "gt",
2193
2234
  children: ">"
2194
2235
  }),
2195
- /* @__PURE__ */ I(S.Item, {
2236
+ /* @__PURE__ */ L(w.Item, {
2196
2237
  value: "gte",
2197
2238
  children: "≥"
2198
2239
  }),
2199
- /* @__PURE__ */ I(S.Item, {
2240
+ /* @__PURE__ */ L(w.Item, {
2200
2241
  value: "lt",
2201
2242
  children: "<"
2202
2243
  }),
2203
- /* @__PURE__ */ I(S.Item, {
2244
+ /* @__PURE__ */ L(w.Item, {
2204
2245
  value: "lte",
2205
2246
  children: "≤"
2206
2247
  }),
2207
- /* @__PURE__ */ I(S.Item, {
2248
+ /* @__PURE__ */ L(w.Item, {
2208
2249
  value: "between",
2209
2250
  children: "↔"
2210
2251
  })
2211
2252
  ]
2212
- }), d === "between" ? /* @__PURE__ */ L(h, {
2253
+ }) }), d === "between" ? /* @__PURE__ */ R(_, {
2213
2254
  d: "column",
2214
2255
  gap: 1,
2215
2256
  flex1: !0,
2216
- children: [/* @__PURE__ */ L(h, {
2257
+ children: [/* @__PURE__ */ R(_, {
2217
2258
  ai: "center",
2218
2259
  position: "relative",
2219
2260
  flex1: !0,
2220
- children: [/* @__PURE__ */ I(y, {
2261
+ children: [/* @__PURE__ */ L(x, {
2221
2262
  type: "number",
2222
2263
  variant: "compact",
2223
- placeholder: m?.placeholder ?? i.filterFromPlaceholder,
2224
- value: f,
2225
- onChange: v,
2264
+ placeholder: h?.placeholder ?? i.filterFromPlaceholder,
2265
+ value: p,
2266
+ onChange: y,
2226
2267
  width: "fit",
2227
- step: m?.step,
2268
+ step: h?.step,
2228
2269
  b: 0,
2229
2270
  bgColor: "transparent",
2230
2271
  focus: { outline: 0 },
@@ -2232,21 +2273,21 @@ function Pt({ column: e }) {
2232
2273
  tabIndex: -1,
2233
2274
  "aria-label": i.filterFrom(r)
2234
2275
  }
2235
- }), (f !== "" || p !== "") && /* @__PURE__ */ I(Mt, {
2276
+ }), (p !== "" || m !== "") && /* @__PURE__ */ L(Ft, {
2236
2277
  label: i.clearFilter(r),
2237
2278
  onClear: C
2238
2279
  })]
2239
- }), /* @__PURE__ */ I(h, {
2280
+ }), /* @__PURE__ */ L(_, {
2240
2281
  ai: "center",
2241
2282
  flex1: !0,
2242
- children: /* @__PURE__ */ I(y, {
2283
+ children: /* @__PURE__ */ L(x, {
2243
2284
  type: "number",
2244
2285
  variant: "compact",
2245
2286
  placeholder: i.filterToPlaceholder,
2246
- value: p,
2287
+ value: m,
2247
2288
  onChange: b,
2248
2289
  width: "fit",
2249
- step: m?.step,
2290
+ step: h?.step,
2250
2291
  b: 0,
2251
2292
  bgColor: "transparent",
2252
2293
  focus: { outline: 0 },
@@ -2256,18 +2297,18 @@ function Pt({ column: e }) {
2256
2297
  }
2257
2298
  })
2258
2299
  })]
2259
- }) : /* @__PURE__ */ L(h, {
2300
+ }) : /* @__PURE__ */ R(_, {
2260
2301
  ai: "center",
2261
2302
  position: "relative",
2262
2303
  flex1: !0,
2263
- children: [/* @__PURE__ */ I(y, {
2304
+ children: [/* @__PURE__ */ L(x, {
2264
2305
  type: "number",
2265
2306
  variant: "compact",
2266
- placeholder: m?.placeholder ?? i.filterValuePlaceholder,
2267
- value: f,
2268
- onChange: v,
2307
+ placeholder: h?.placeholder ?? i.filterValuePlaceholder,
2308
+ value: p,
2309
+ onChange: y,
2269
2310
  width: "fit",
2270
- step: m?.step,
2311
+ step: h?.step,
2271
2312
  b: 0,
2272
2313
  bgColor: "transparent",
2273
2314
  focus: { outline: 0 },
@@ -2275,28 +2316,28 @@ function Pt({ column: e }) {
2275
2316
  tabIndex: -1,
2276
2317
  "aria-label": i.filterColumn(r)
2277
2318
  }
2278
- }), f !== "" && /* @__PURE__ */ I(Mt, {
2319
+ }), p !== "" && /* @__PURE__ */ L(Ft, {
2279
2320
  label: i.clearFilter(r),
2280
2321
  onClear: C
2281
2322
  })]
2282
2323
  })]
2283
2324
  });
2284
2325
  }
2285
- function Ft({ column: e }) {
2286
- let t = Te(!0);
2287
- return t ? /* @__PURE__ */ I(t.DateFilter, { column: e }) : null;
2326
+ function Rt({ column: e }) {
2327
+ let t = De(!0);
2328
+ return t ? /* @__PURE__ */ L(t.DateFilter, { column: e }) : null;
2288
2329
  }
2289
- function It({ column: e }) {
2290
- let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), a = e.grid.localeText, o = t?.type === "multiselect" ? t.values : [], s = e.filterOptions, c = O((t, n) => {
2330
+ function zt({ column: e }) {
2331
+ let { currentFilter: t } = e, { componentName: n } = e.grid, r = String(e.header ?? e.key), i = e.grid.localeText, o = t?.type === "multiselect" ? t.values : [], s = e.filterOptions, c = j((t, n) => {
2291
2332
  e.setMultiselectFilter(n);
2292
2333
  }, [e]);
2293
- return /* @__PURE__ */ I(h, {
2334
+ return /* @__PURE__ */ L(_, {
2294
2335
  component: `${n}.filter.cell.input`,
2295
- children: /* @__PURE__ */ L(S, {
2336
+ children: /* @__PURE__ */ L(f, { children: /* @__PURE__ */ R(w, {
2296
2337
  multiple: !0,
2297
2338
  showCheckbox: !0,
2298
2339
  isSearchable: !0,
2299
- searchPlaceholder: a.filterSelectSearchPlaceholder,
2340
+ searchPlaceholder: i.filterSelectSearchPlaceholder,
2300
2341
  value: o,
2301
2342
  width: "fit",
2302
2343
  minWidth: 0,
@@ -2307,43 +2348,43 @@ function It({ column: e }) {
2307
2348
  focus: { outline: 0 },
2308
2349
  props: {
2309
2350
  tabIndex: -1,
2310
- "aria-label": a.filterColumn(r)
2351
+ "aria-label": i.filterColumn(r)
2311
2352
  },
2312
2353
  children: [
2313
- /* @__PURE__ */ I(S.Display, { children: (t) => t.length === 0 ? /* @__PURE__ */ I(i, {
2354
+ /* @__PURE__ */ L(w.Display, { children: (t) => t.length === 0 ? /* @__PURE__ */ L(a, {
2314
2355
  tag: "span",
2315
2356
  color: "base-400",
2316
- children: e.filterConfig?.placeholder ?? a.filterSelectPlaceholder
2357
+ children: e.filterConfig?.placeholder ?? i.filterSelectPlaceholder
2317
2358
  }) : t.length === 1 ? s.find((e) => e.value === t[0])?.label ?? String(t[0]) : `${t.length} selected` }),
2318
- /* @__PURE__ */ I(S.Unselect, { children: a.filterSelectClear }),
2319
- /* @__PURE__ */ I(S.SelectAll, { children: a.filterSelectAll }),
2320
- s.map((e) => /* @__PURE__ */ I(S.Item, {
2359
+ /* @__PURE__ */ L(w.Unselect, { children: i.filterSelectClear }),
2360
+ /* @__PURE__ */ L(w.SelectAll, { children: i.filterSelectAll }),
2361
+ s.map((e) => /* @__PURE__ */ L(w.Item, {
2321
2362
  value: e.value,
2322
2363
  ai: "center",
2323
2364
  gap: 2,
2324
2365
  children: e.label
2325
2366
  }, String(e.value)))
2326
2367
  ]
2327
- })
2368
+ }) })
2328
2369
  });
2329
2370
  }
2330
- function Lt(e) {
2371
+ function Bt(e) {
2331
2372
  let { column: t } = e, n = t.filterConfig;
2332
2373
  if (!n) return null;
2333
2374
  switch (n.type) {
2334
- case "number": return /* @__PURE__ */ I(Pt, { column: t });
2335
- case "multiselect": return /* @__PURE__ */ I(It, { column: t });
2336
- case "date": return /* @__PURE__ */ I(Ft, { column: t });
2337
- default: return /* @__PURE__ */ I(Nt, { column: t });
2375
+ case "number": return /* @__PURE__ */ L(Lt, { column: t });
2376
+ case "multiselect": return /* @__PURE__ */ L(zt, { column: t });
2377
+ case "date": return /* @__PURE__ */ L(Rt, { column: t });
2378
+ default: return /* @__PURE__ */ L(It, { column: t });
2338
2379
  }
2339
2380
  }
2340
- Lt.displayName = "DataGridColumnFilter";
2381
+ Bt.displayName = "DataGridColumnFilter";
2341
2382
  //#endregion
2342
2383
  //#region src/components/dataGrid/components/dataGridFilterCell.tsx
2343
- function Rt(e) {
2344
- let { column: t, grid: n, row: r, columnIndex: i } = e, { widthVarName: a, inlineStartVarName: o, inlineEndVarName: s, filterable: c } = t, { isStartPinned: l, isEndPinned: u, isPinned: d, isFirstStartPinned: f, isLastStartPinned: p, isFirstEndPinned: m, isLastEndPinned: g } = t.pinFlags.value, { ref: _, tabIndex: v, onFocus: y } = ve(z(), r, i), b = t.isGrouping || t.isRowNumber || t.isRowSelection;
2345
- return /* @__PURE__ */ I(h, {
2346
- ref: _,
2384
+ function Vt(e) {
2385
+ let { column: t, grid: n, row: r, columnIndex: i } = e, { widthVarName: a, inlineStartVarName: o, inlineEndVarName: s, filterable: c } = t, { isStartPinned: l, isEndPinned: u, isPinned: d, isFirstStartPinned: f, isLastStartPinned: p, isFirstEndPinned: m, isLastEndPinned: h } = t.pinFlags.value, { ref: g, tabIndex: v, onFocus: y } = be(z(), r, i), b = t.isGrouping || t.isRowNumber || t.isRowSelection;
2386
+ return /* @__PURE__ */ L(_, {
2387
+ ref: g,
2347
2388
  component: `${n.componentName}.filter.cell`,
2348
2389
  props: {
2349
2390
  role: "gridcell",
@@ -2356,7 +2397,7 @@ function Rt(e) {
2356
2397
  isFirstStartPinned: f,
2357
2398
  isLastStartPinned: p,
2358
2399
  isFirstEndPinned: m,
2359
- isLastEndPinned: g
2400
+ isLastEndPinned: h
2360
2401
  },
2361
2402
  px: 2,
2362
2403
  style: {
@@ -2364,23 +2405,23 @@ function Rt(e) {
2364
2405
  insetInlineStart: l ? `var(${o})` : void 0,
2365
2406
  insetInlineEnd: u ? `var(${s})` : void 0
2366
2407
  },
2367
- children: !b && c && /* @__PURE__ */ I(Lt, { column: t })
2408
+ children: !b && c && /* @__PURE__ */ L(Bt, { column: t })
2368
2409
  });
2369
2410
  }
2370
- Rt.displayName = "DataGridFilterCell";
2411
+ Vt.displayName = "DataGridFilterCell";
2371
2412
  //#endregion
2372
2413
  //#region src/components/dataGrid/components/dataGridFilterRow.tsx
2373
- function zt(e) {
2414
+ function Ht(e) {
2374
2415
  let { grid: t } = e;
2375
2416
  if (!t.filter.hasFilterableColumns) return null;
2376
2417
  let n = t.headerRows.value.length;
2377
- return /* @__PURE__ */ I(i, {
2418
+ return /* @__PURE__ */ L(a, {
2378
2419
  display: "contents",
2379
2420
  props: {
2380
2421
  role: "row",
2381
2422
  "aria-rowindex": n + 1
2382
2423
  },
2383
- children: t.columns.value.visibleLeafs.map((e, r) => /* @__PURE__ */ I(Rt, {
2424
+ children: t.columns.value.visibleLeafs.map((e, r) => /* @__PURE__ */ L(Vt, {
2384
2425
  column: e,
2385
2426
  grid: t,
2386
2427
  row: n,
@@ -2388,25 +2429,25 @@ function zt(e) {
2388
2429
  }, e.uniqueKey))
2389
2430
  });
2390
2431
  }
2391
- zt.displayName = "DataGridFilterRow";
2432
+ Ht.displayName = "DataGridFilterRow";
2392
2433
  //#endregion
2393
2434
  //#region src/icons/sortIcon.tsx
2394
- function Bt(e) {
2395
- return /* @__PURE__ */ I(f, {
2435
+ function Ut(e) {
2436
+ return /* @__PURE__ */ L(m, {
2396
2437
  viewBox: "0 0 24 24",
2397
2438
  width: "1.5rem",
2398
2439
  ...e,
2399
- children: /* @__PURE__ */ I(d, { d: "M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z" })
2440
+ children: /* @__PURE__ */ L(p, { d: "M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z" })
2400
2441
  });
2401
2442
  }
2402
2443
  //#endregion
2403
2444
  //#region src/icons/dotsIcon.tsx
2404
- function Vt(e) {
2405
- return /* @__PURE__ */ I(f, {
2445
+ function Wt(e) {
2446
+ return /* @__PURE__ */ L(m, {
2406
2447
  viewBox: "0 0 16 16",
2407
2448
  width: "18",
2408
2449
  ...e,
2409
- children: /* @__PURE__ */ I(d, {
2450
+ children: /* @__PURE__ */ L(p, {
2410
2451
  strokeWidth: 4,
2411
2452
  d: "M7.936 12.128a.936.936 0 1 1 0 1.872.936.936 0 0 1 0-1.872ZM7.936 7.052a.936.936 0 1 1 0 1.873.936.936 0 0 1 0-1.873ZM7.936 1.977a.936.936 0 1 1 0 1.872.936.936 0 0 1 0-1.872Z"
2412
2453
  })
@@ -2414,126 +2455,126 @@ function Vt(e) {
2414
2455
  }
2415
2456
  //#endregion
2416
2457
  //#region src/icons/groupingIcon.tsx
2417
- function Ht(e) {
2418
- return /* @__PURE__ */ I(f, {
2458
+ function Gt(e) {
2459
+ return /* @__PURE__ */ L(m, {
2419
2460
  viewBox: "0 0 24 24",
2420
2461
  width: "1.5rem",
2421
2462
  ...e,
2422
- children: /* @__PURE__ */ I(d, { d: "M3 5h8v2H3V5zm0 6h8v2H3v-2zm0 6h8v2H3v-2zm12-12h6v6h-6V5zm1 1v4h4V6h-4zm-1 7h6v6h-6v-6zm1 1v4h4v-4h-4z" })
2463
+ children: /* @__PURE__ */ L(p, { d: "M3 5h8v2H3V5zm0 6h8v2H3v-2zm0 6h8v2H3v-2zm12-12h6v6h-6V5zm1 1v4h4V6h-4zm-1 7h6v6h-6v-6zm1 1v4h4v-4h-4z" })
2423
2464
  });
2424
2465
  }
2425
2466
  //#endregion
2426
2467
  //#region src/icons/pinIcon.tsx
2427
- function Ut(e) {
2428
- return /* @__PURE__ */ I(f, {
2468
+ function Kt(e) {
2469
+ return /* @__PURE__ */ L(m, {
2429
2470
  viewBox: "0 0 1024 1024",
2430
2471
  width: "1.5rem",
2431
2472
  ...e,
2432
- children: /* @__PURE__ */ I(d, { d: "M31.997 1023.957a31.699 31.699 0 0 1-22.611-9.386C3.328 1008.556 0 1000.493 0 991.96s3.328-16.596 9.386-22.611L328.25 650.484l-152.52-152.52a95.907 95.907 0 0 1-25.087-92.152 95.31 95.31 0 0 1 44.327-58.62l.896-.512a353.464 353.464 0 0 1 176.156-47.398c20.137 0 40.36 1.749 60.283 5.205L597.71 44.54A95.224 95.224 0 0 1 678.685.085c25.64 0 49.745 9.983 67.877 28.073l249.195 249.195a95.224 95.224 0 0 1 25.897 88.74 95.139 95.139 0 0 1-42.152 60.154L719.513 591.695a352.227 352.227 0 0 1-42.663 237.292A95.395 95.395 0 0 1 594 876.514a95.523 95.523 0 0 1-67.963-28.2L373.43 695.706 54.61 1014.614a31.912 31.912 0 0 1-22.612 9.343zm340.025-660.68c-50.64 0-100.685 13.566-144.798 39.207a31.57 31.57 0 0 0-14.676 19.497 31.699 31.699 0 0 0 8.362 30.675L571.344 803.09c6.059 6.059 14.122 9.386 22.697 9.386a31.699 31.699 0 0 0 27.56-15.785 287.421 287.421 0 0 0 31.06-212.676 31.997 31.997 0 0 1 13.907-34.471l278.59-177.266a31.57 31.57 0 0 0 14.037-20.051 31.699 31.699 0 0 0-8.618-29.566l-249.28-249.28a31.912 31.912 0 0 0-49.618 5.418l-177.308 278.59a31.827 31.827 0 0 1-34.472 13.908 293.778 293.778 0 0 0-67.877-8.02z" })
2473
+ children: /* @__PURE__ */ L(p, { d: "M31.997 1023.957a31.699 31.699 0 0 1-22.611-9.386C3.328 1008.556 0 1000.493 0 991.96s3.328-16.596 9.386-22.611L328.25 650.484l-152.52-152.52a95.907 95.907 0 0 1-25.087-92.152 95.31 95.31 0 0 1 44.327-58.62l.896-.512a353.464 353.464 0 0 1 176.156-47.398c20.137 0 40.36 1.749 60.283 5.205L597.71 44.54A95.224 95.224 0 0 1 678.685.085c25.64 0 49.745 9.983 67.877 28.073l249.195 249.195a95.224 95.224 0 0 1 25.897 88.74 95.139 95.139 0 0 1-42.152 60.154L719.513 591.695a352.227 352.227 0 0 1-42.663 237.292A95.395 95.395 0 0 1 594 876.514a95.523 95.523 0 0 1-67.963-28.2L373.43 695.706 54.61 1014.614a31.912 31.912 0 0 1-22.612 9.343zm340.025-660.68c-50.64 0-100.685 13.566-144.798 39.207a31.57 31.57 0 0 0-14.676 19.497 31.699 31.699 0 0 0 8.362 30.675L571.344 803.09c6.059 6.059 14.122 9.386 22.697 9.386a31.699 31.699 0 0 0 27.56-15.785 287.421 287.421 0 0 0 31.06-212.676 31.997 31.997 0 0 1 13.907-34.471l278.59-177.266a31.57 31.57 0 0 0 14.037-20.051 31.699 31.699 0 0 0-8.618-29.566l-249.28-249.28a31.912 31.912 0 0 0-49.618 5.418l-177.308 278.59a31.827 31.827 0 0 1-34.472 13.908 293.778 293.778 0 0 0-67.877-8.02z" })
2433
2474
  });
2434
2475
  }
2435
2476
  //#endregion
2436
2477
  //#region src/components/dataGrid/components/dataGridHeaderCellContextMenu.tsx
2437
- function Wt(e) {
2478
+ function qt(e) {
2438
2479
  let { side: t, left: n, right: r } = e;
2439
- return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ I(C, {
2480
+ return /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(T, {
2440
2481
  rtl: { display: "none" },
2441
2482
  children: t === "start" ? n : r
2442
- }), /* @__PURE__ */ I(C, {
2483
+ }), /* @__PURE__ */ L(T, {
2443
2484
  ltr: { display: "none" },
2444
2485
  children: t === "start" ? r : n
2445
2486
  })] });
2446
2487
  }
2447
- function Gt(e) {
2448
- let { column: t } = e, { grid: n, isEndAligned: a, header: s, key: d } = t, f = t.headerCell, m = String(s ?? d), g = n.localeText, y = u("datagrid-column-menu"), [b, x] = P(!1), S = N(null), w = N(null), T = N(!1), ee = a ? 3 : void 0, ne = a ? void 0 : 3, E = M(() => {
2449
- let e = (e) => /* @__PURE__ */ I(C, {
2488
+ function Jt(e) {
2489
+ let { column: t } = e, { grid: n, isEndAligned: i, header: o, key: c } = t, f = t.headerCell, p = String(o ?? c), m = n.localeText, g = d("datagrid-column-menu"), [v, x] = F(!1), S = P(null), C = P(null), w = P(!1), E = i ? 3 : void 0, ee = i ? void 0 : 3, D = ie(() => {
2490
+ let e = (e) => /* @__PURE__ */ L(T, {
2450
2491
  component: `${n.componentName}.header.cell.contextMenu.tooltip.item.icon`,
2451
2492
  children: e
2452
- }), r = (t) => e(/* @__PURE__ */ I(Bt, {
2493
+ }), r = (t) => e(/* @__PURE__ */ L(Ut, {
2453
2494
  width: "100%",
2454
2495
  fill: "currentColor",
2455
2496
  rotate: t
2456
- })), a = (t, n) => e(/* @__PURE__ */ I(Ut, {
2497
+ })), i = (t, n) => e(/* @__PURE__ */ L(Kt, {
2457
2498
  width: "100%",
2458
2499
  fill: "currentColor",
2459
2500
  rotate: t,
2460
2501
  rtl: { rotate: n }
2461
- })), o = e(/* @__PURE__ */ I(Ht, {
2502
+ })), o = e(/* @__PURE__ */ L(Gt, {
2462
2503
  width: "100%",
2463
2504
  fill: "currentColor"
2464
- })), s = /* @__PURE__ */ I(i, { width: 4 });
2505
+ })), s = /* @__PURE__ */ L(a, { width: 4 });
2465
2506
  return [
2466
2507
  [
2467
2508
  f.canSortAsc && {
2468
2509
  key: "sort-asc",
2469
2510
  icon: r(),
2470
- label: g.sortAscending,
2471
- text: g.sortAscending,
2511
+ label: m.sortAscending,
2512
+ text: m.sortAscending,
2472
2513
  run: () => t.sortColumn("ASC")
2473
2514
  },
2474
2515
  f.canSortDesc && {
2475
2516
  key: "sort-desc",
2476
2517
  icon: r(180),
2477
- label: g.sortDescending,
2478
- text: g.sortDescending,
2518
+ label: m.sortDescending,
2519
+ text: m.sortDescending,
2479
2520
  run: () => t.sortColumn("DESC")
2480
2521
  },
2481
2522
  f.canClearSort && {
2482
2523
  key: "sort-clear",
2483
2524
  icon: s,
2484
- label: g.clearSort,
2485
- text: g.clearSort,
2525
+ label: m.clearSort,
2526
+ text: m.clearSort,
2486
2527
  run: () => t.sortColumn(void 0)
2487
2528
  }
2488
2529
  ],
2489
2530
  [
2490
2531
  f.canPinStart && {
2491
2532
  key: "pin-start",
2492
- icon: a(0, -90),
2493
- label: /* @__PURE__ */ I(Wt, {
2533
+ icon: i(0, -90),
2534
+ label: /* @__PURE__ */ L(qt, {
2494
2535
  side: "start",
2495
- left: g.pinLeft,
2496
- right: g.pinRight
2536
+ left: m.pinLeft,
2537
+ right: m.pinRight
2497
2538
  }),
2498
- text: g.pinLeft,
2539
+ text: m.pinLeft,
2499
2540
  run: () => t.pinColumn("START")
2500
2541
  },
2501
2542
  f.canPinEnd && {
2502
2543
  key: "pin-end",
2503
- icon: a(-90, 0),
2504
- label: /* @__PURE__ */ I(Wt, {
2544
+ icon: i(-90, 0),
2545
+ label: /* @__PURE__ */ L(qt, {
2505
2546
  side: "end",
2506
- left: g.pinLeft,
2507
- right: g.pinRight
2547
+ left: m.pinLeft,
2548
+ right: m.pinRight
2508
2549
  }),
2509
- text: g.pinRight,
2550
+ text: m.pinRight,
2510
2551
  run: () => t.pinColumn("END")
2511
2552
  },
2512
2553
  f.canUnpin && {
2513
2554
  key: "unpin",
2514
2555
  icon: s,
2515
- label: g.unpin,
2516
- text: g.unpin,
2556
+ label: m.unpin,
2557
+ text: m.unpin,
2517
2558
  run: () => t.pinColumn()
2518
2559
  }
2519
2560
  ],
2520
2561
  [f.canGroupBy && {
2521
2562
  key: "group",
2522
2563
  icon: o,
2523
- label: /* @__PURE__ */ I(i, {
2564
+ label: /* @__PURE__ */ L(a, {
2524
2565
  textWrap: "nowrap",
2525
- children: g.groupBy(m)
2566
+ children: m.groupBy(p)
2526
2567
  }),
2527
- text: g.groupBy(m),
2568
+ text: m.groupBy(p),
2528
2569
  run: t.toggleGrouping
2529
2570
  }, f.canUnGroupAll && {
2530
2571
  key: "ungroup",
2531
2572
  icon: o,
2532
- label: /* @__PURE__ */ I(i, {
2573
+ label: /* @__PURE__ */ L(a, {
2533
2574
  textWrap: "nowrap",
2534
- children: g.ungroupAll
2575
+ children: m.ungroupAll
2535
2576
  }),
2536
- text: g.ungroupAll,
2577
+ text: m.ungroupAll,
2537
2578
  run: n.unGroupAll
2538
2579
  }]
2539
2580
  ].map((e) => e.filter((e) => e !== !1)).filter((e) => e.length > 0).flatMap((e, t) => e.map((e, n) => ({
@@ -2542,93 +2583,93 @@ function Gt(e) {
2542
2583
  })));
2543
2584
  }, [
2544
2585
  t,
2545
- m,
2586
+ p,
2546
2587
  n,
2547
2588
  f,
2548
- g
2549
- ]), D = O((e = !0) => {
2550
- T.current = !1, x(!1), e && S.current?.focus();
2551
- }, []), k = l({
2552
- count: E.length,
2553
- textOf: (e) => E[e]?.text ?? "",
2589
+ m
2590
+ ]), O = j((e = !0) => {
2591
+ w.current = !1, x(!1), e && S.current?.focus();
2592
+ }, []), k = u({
2593
+ count: D.length,
2594
+ textOf: (e) => D[e]?.text ?? "",
2554
2595
  onSelect: (e) => {
2555
- E[e]?.run(), D();
2596
+ D[e]?.run(), O();
2556
2597
  }
2557
2598
  });
2558
- c({
2559
- enabled: b,
2560
- inside: [S, w],
2561
- onDismiss: () => D()
2562
- }), o({
2563
- enabled: b,
2599
+ l({
2600
+ enabled: v,
2601
+ inside: [S, C],
2602
+ onDismiss: () => O()
2603
+ }), s({
2604
+ enabled: v,
2564
2605
  returnTo: S
2565
2606
  });
2566
- let A = k.setActiveIndex, j = k.activeItem, re = O(() => {
2567
- A(0, { reason: "programmatic" }), T.current = !0, x(!0);
2607
+ let A = k.setActiveIndex, M = k.activeItem, N = j(() => {
2608
+ A(0, { reason: "programmatic" }), w.current = !0, x(!0);
2568
2609
  }, [A]);
2569
2610
  return r(() => {
2570
- if (!T.current) return;
2571
- let e = j();
2572
- e && (T.current = !1, e.focus());
2573
- }), /* @__PURE__ */ L(h, {
2611
+ if (!w.current) return;
2612
+ let e = M();
2613
+ e && (w.current = !1, e.focus());
2614
+ }), /* @__PURE__ */ R(_, {
2574
2615
  position: "absolute",
2575
- insetStart: ee,
2576
- insetEnd: ne,
2616
+ insetStart: E,
2617
+ insetEnd: ee,
2577
2618
  top: "1/2",
2578
2619
  translateY: -3,
2579
2620
  ai: "center",
2580
- children: [/* @__PURE__ */ I(p, {
2621
+ children: [/* @__PURE__ */ L(h, {
2581
2622
  ref: S,
2582
2623
  component: `${n.componentName}.header.cell.contextMenu`,
2583
- onClick: () => b ? D(!1) : re(),
2624
+ onClick: () => v ? O(!1) : N(),
2584
2625
  variant: f.contextMenuButtonVariant,
2585
2626
  type: "button",
2586
2627
  props: {
2587
2628
  tabIndex: -1,
2588
- "aria-label": g.columnOptions(m),
2629
+ "aria-label": m.columnOptions(p),
2589
2630
  "aria-haspopup": "menu",
2590
- "aria-expanded": b,
2591
- "aria-controls": b ? y : void 0
2631
+ "aria-expanded": v,
2632
+ "aria-controls": v ? g : void 0
2592
2633
  },
2593
- children: /* @__PURE__ */ I(C, {
2634
+ children: /* @__PURE__ */ L(T, {
2594
2635
  component: `${n.componentName}.header.cell.contextMenu.icon`,
2595
- children: /* @__PURE__ */ I(Vt, { fill: "currentColor" })
2636
+ children: /* @__PURE__ */ L(Wt, { fill: "currentColor" })
2596
2637
  })
2597
- }), /* @__PURE__ */ I(v, {
2598
- present: b,
2599
- children: (e) => /* @__PURE__ */ I(_, {
2638
+ }), /* @__PURE__ */ L(b, {
2639
+ present: v,
2640
+ children: (e) => /* @__PURE__ */ L(y, {
2600
2641
  component: `${n.componentName}.header.cell.contextMenu.tooltip`,
2601
2642
  variant: { closed: !e.present },
2602
- ref: w,
2643
+ ref: C,
2603
2644
  contentRef: e.ref,
2604
2645
  anchor: S,
2605
2646
  side: "bottom",
2606
2647
  align: "end",
2607
2648
  matchWidth: !1,
2608
- id: y,
2649
+ id: g,
2609
2650
  props: {
2610
2651
  role: "menu",
2611
- "aria-label": g.columnOptions(m),
2652
+ "aria-label": m.columnOptions(p),
2612
2653
  onKeyDown: k.onKeyDown,
2613
2654
  ...e.props
2614
2655
  },
2615
- children: E.map((e, t) => {
2616
- let { ref: r, tabIndex: a, onFocus: o } = k.itemProps(t);
2617
- return /* @__PURE__ */ L(te, { children: [e.startsSection && /* @__PURE__ */ I(i, {
2656
+ children: D.map((e, t) => {
2657
+ let { ref: r, tabIndex: i, onFocus: o } = k.itemProps(t);
2658
+ return /* @__PURE__ */ R(te, { children: [e.startsSection && /* @__PURE__ */ L(a, {
2618
2659
  bb: 1,
2619
2660
  my: 2,
2620
2661
  borderColor: "base-300",
2621
2662
  component: `${n.componentName}.header.cell.contextMenu.tooltip.item.separator`
2622
- }), /* @__PURE__ */ L(p, {
2663
+ }), /* @__PURE__ */ R(h, {
2623
2664
  component: `${n.componentName}.header.cell.contextMenu.tooltip.item`,
2624
2665
  ref: r,
2625
2666
  type: "button",
2626
2667
  onClick: (t) => {
2627
- t.stopPropagation(), e.run(), D();
2668
+ t.stopPropagation(), e.run(), O();
2628
2669
  },
2629
2670
  props: {
2630
2671
  role: "menuitem",
2631
- tabIndex: a,
2672
+ tabIndex: i,
2632
2673
  onFocus: o
2633
2674
  },
2634
2675
  children: [e.icon, e.label]
@@ -2638,27 +2679,27 @@ function Gt(e) {
2638
2679
  })]
2639
2680
  });
2640
2681
  }
2641
- Gt.displayName = "DataGridHeaderCellContextMenu";
2682
+ Jt.displayName = "DataGridHeaderCellContextMenu";
2642
2683
  //#endregion
2643
2684
  //#region src/components/dataGrid/components/dataGridHeaderCellResizer.tsx
2644
- var Kt = (e) => "touches" in e ? e.touches[0]?.pageX ?? 0 : e.pageX, qt = 16, Jt = 150;
2645
- function Yt(e) {
2646
- let { column: t, controls: n } = e, r = t.grid.resizerStyle, a = t.headerCell, o = O((e) => {
2685
+ var Yt = (e) => "touches" in e ? e.touches[0]?.pageX ?? 0 : e.pageX, Xt = 16, Zt = 150;
2686
+ function Qt(e) {
2687
+ let { column: t, controls: n } = e, r = t.grid.resizerStyle, i = t.headerCell, o = j((e) => {
2647
2688
  let { grid: n } = t;
2648
- e.type === "mousedown" && e.preventDefault(), t.beginResize(Kt(e.nativeEvent));
2649
- let r = new AbortController(), { signal: i } = r, a = 0, o = Kt(e.nativeEvent), s = () => {
2689
+ e.type === "mousedown" && e.preventDefault(), t.beginResize(Yt(e.nativeEvent));
2690
+ let r = new AbortController(), { signal: i } = r, a = 0, o = Yt(e.nativeEvent), s = () => {
2650
2691
  t.applyResize(o), n.paintSizes();
2651
2692
  }, c = n.resizeMode === "instant" ? (e) => {
2652
- o = Kt(e), s();
2693
+ o = Yt(e), s();
2653
2694
  } : (e) => {
2654
- o = Kt(e), a ||= requestAnimationFrame(() => {
2695
+ o = Yt(e), a ||= requestAnimationFrame(() => {
2655
2696
  a = 0, s();
2656
2697
  });
2657
2698
  }, l = () => {
2658
2699
  r.abort(), a && cancelAnimationFrame(a), s(), t.endResize();
2659
2700
  };
2660
2701
  window.addEventListener("mousemove", c, { signal: i }), window.addEventListener("touchmove", c, { signal: i }), window.addEventListener("mouseup", l, { signal: i }), window.addEventListener("touchend", l, { signal: i });
2661
- }, [t]), s = N(void 0), c = N(0), l = O(() => {
2702
+ }, [t]), s = P(void 0), c = P(0), l = j(() => {
2662
2703
  let { grid: e } = t;
2663
2704
  if (e.resizeMode === "instant") {
2664
2705
  e.paintSizes();
@@ -2667,36 +2708,36 @@ function Yt(e) {
2667
2708
  c.current ||= requestAnimationFrame(() => {
2668
2709
  c.current = 0, e.paintSizes();
2669
2710
  });
2670
- }, [t]), u = O(() => {
2711
+ }, [t]), u = j(() => {
2671
2712
  s.current !== void 0 && (clearTimeout(s.current), s.current = void 0, c.current &&= (cancelAnimationFrame(c.current), 0), t.endResize());
2672
2713
  }, [t]);
2673
- A(() => () => {
2714
+ N(() => () => {
2674
2715
  clearTimeout(s.current), c.current && cancelAnimationFrame(c.current);
2675
2716
  }, []);
2676
- let d = O((e) => {
2717
+ let d = j((e) => {
2677
2718
  switch (e.key) {
2678
2719
  case "ArrowRight":
2679
- t.moveResizer(qt);
2720
+ t.moveResizer(Xt);
2680
2721
  break;
2681
2722
  case "ArrowLeft":
2682
2723
  t.moveResizer(-16);
2683
2724
  break;
2684
2725
  case "Home":
2685
- t.resizeWidthTo(a.minWidth);
2726
+ t.resizeWidthTo(i.minWidth);
2686
2727
  break;
2687
2728
  case "End":
2688
- t.resizeWidthTo(a.maxWidth);
2729
+ t.resizeWidthTo(i.maxWidth);
2689
2730
  break;
2690
2731
  default: return;
2691
2732
  }
2692
- e.preventDefault(), l(), clearTimeout(s.current), s.current = setTimeout(u, Jt);
2733
+ e.preventDefault(), l(), clearTimeout(s.current), s.current = setTimeout(u, Zt);
2693
2734
  }, [
2694
2735
  t,
2695
2736
  u,
2696
- a,
2737
+ i,
2697
2738
  l
2698
- ]), { isAtGridEnd: f } = a;
2699
- return /* @__PURE__ */ I(h, {
2739
+ ]), { isAtGridEnd: f } = i;
2740
+ return /* @__PURE__ */ L(_, {
2700
2741
  height: "fit",
2701
2742
  ai: "center",
2702
2743
  position: "absolute",
@@ -2704,7 +2745,7 @@ function Yt(e) {
2704
2745
  insetStart: t.pin === "END" ? -.75 : void 0,
2705
2746
  zIndex: 1,
2706
2747
  py: 3,
2707
- children: /* @__PURE__ */ I(i, {
2748
+ children: /* @__PURE__ */ L(a, {
2708
2749
  cursor: "col-resize",
2709
2750
  px: f ? void 0 : .75,
2710
2751
  ps: f ? 1.5 : void 0,
@@ -2715,19 +2756,19 @@ function Yt(e) {
2715
2756
  onMouseDown: o,
2716
2757
  onTouchStart: o
2717
2758
  },
2718
- children: /* @__PURE__ */ I(i, {
2759
+ children: /* @__PURE__ */ L(a, {
2719
2760
  component: `${t.grid.componentName}.header.cell.resizer`,
2720
2761
  opacity: r === "visible" ? void 0 : 0,
2721
2762
  group: r === "hover" ? { "header-cell/hover": { opacity: 1 } } : void 0,
2722
2763
  props: {
2723
2764
  role: "separator",
2724
- "aria-label": a.resizerLabel,
2765
+ "aria-label": i.resizerLabel,
2725
2766
  "aria-controls": n,
2726
2767
  "aria-orientation": "vertical",
2727
- "aria-valuenow": a.width,
2728
- "aria-valuemin": a.minWidth,
2729
- "aria-valuemax": a.maxWidth,
2730
- "aria-valuetext": t.grid.localeText.columnWidth(a.width),
2768
+ "aria-valuenow": i.width,
2769
+ "aria-valuemin": i.minWidth,
2770
+ "aria-valuemax": i.maxWidth,
2771
+ "aria-valuetext": t.grid.localeText.columnWidth(i.width),
2731
2772
  tabIndex: -1,
2732
2773
  onKeyDown: d,
2733
2774
  onKeyUp: u
@@ -2736,28 +2777,28 @@ function Yt(e) {
2736
2777
  })
2737
2778
  });
2738
2779
  }
2739
- Yt.displayName = "DataGridHeaderCellResizer";
2780
+ Qt.displayName = "DataGridHeaderCellResizer";
2740
2781
  //#endregion
2741
2782
  //#region src/components/dataGrid/components/dataGridHeaderCell.tsx
2742
- function Xt(e) {
2743
- let { column: t, row: n, columnIndex: r } = e, { grid: a } = t, { isStartPinned: o, isEndPinned: s } = t.pinFlags.value, c = t.headerCell, { isSortable: l, showResizer: d, showContextMenu: f, paddingStart: p, paddingEnd: _ } = c, { ref: v, tabIndex: y, onFocus: b } = ve(z(), n, r), x = u("datagrid-columnheader"), S = N(null), C = O(() => {
2744
- a.toggleSelectAllRows();
2745
- }, [a]), w = t.isRowSelection ? /* @__PURE__ */ I(g, {
2783
+ function $t(e) {
2784
+ let { column: t, row: n, columnIndex: r } = e, { grid: i } = t, { isStartPinned: o, isEndPinned: s } = t.pinFlags.value, c = t.headerCell, { isSortable: l, showResizer: u, showContextMenu: f, paddingStart: p, paddingEnd: m } = c, { ref: h, tabIndex: y, onFocus: b } = be(z(), n, r), x = d("datagrid-columnheader"), S = P(null), C = j(() => {
2785
+ i.toggleSelectAllRows();
2786
+ }, [i]), w = t.isRowSelection ? /* @__PURE__ */ L(v, {
2746
2787
  variant: "datagrid",
2747
2788
  m: 1,
2748
- indeterminate: a.someRowsSelected && !a.allRowsSelected,
2749
- checked: a.allRowsSelected,
2789
+ indeterminate: i.someRowsSelected && !i.allRowsSelected,
2790
+ checked: i.allRowsSelected,
2750
2791
  onChange: C,
2751
2792
  props: {
2752
2793
  tabIndex: -1,
2753
- "aria-label": a.localeText.selectAllRows
2794
+ "aria-label": i.localeText.selectAllRows
2754
2795
  }
2755
- }) : c.hiddenLabel ? /* @__PURE__ */ I(m, {
2796
+ }) : c.hiddenLabel ? /* @__PURE__ */ L(g, {
2756
2797
  tag: "span",
2757
2798
  children: c.hiddenLabel
2758
2799
  }) : c.label;
2759
- return /* @__PURE__ */ I(h, {
2760
- ref: v,
2800
+ return /* @__PURE__ */ L(_, {
2801
+ ref: h,
2761
2802
  id: x,
2762
2803
  props: {
2763
2804
  role: "columnheader",
@@ -2773,7 +2814,7 @@ function Xt(e) {
2773
2814
  } : void 0
2774
2815
  },
2775
2816
  className: "header-cell",
2776
- component: `${a.componentName}.header.cell`,
2817
+ component: `${i.componentName}.header.cell`,
2777
2818
  variant: c.variant,
2778
2819
  gridRow: t.gridRows,
2779
2820
  gridColumn: c.gridColumn,
@@ -2782,29 +2823,29 @@ function Xt(e) {
2782
2823
  insetInlineStart: o ? `var(${t.inlineStartVarName})` : void 0,
2783
2824
  insetInlineEnd: s ? `var(${t.inlineEndVarName})` : void 0
2784
2825
  },
2785
- children: /* @__PURE__ */ L(F, { children: [
2786
- /* @__PURE__ */ I(h, {
2826
+ children: /* @__PURE__ */ R(I, { children: [
2827
+ /* @__PURE__ */ L(_, {
2787
2828
  width: "fit",
2788
2829
  height: "fit",
2789
2830
  jc: t.align,
2790
- children: /* @__PURE__ */ L(h, {
2831
+ children: /* @__PURE__ */ R(_, {
2791
2832
  overflow: "hidden",
2792
2833
  position: t.isLeaf ? void 0 : "sticky",
2793
2834
  ai: "center",
2794
2835
  transition: "none",
2795
2836
  ps: p,
2796
- pe: _,
2797
- style: { insetInlineStart: t.pin ? void 0 : `var(${a.inlineStartEdgeVarName})` },
2837
+ pe: m,
2838
+ style: { insetInlineStart: t.pin ? void 0 : `var(${i.inlineStartEdgeVarName})` },
2798
2839
  children: [
2799
- /* @__PURE__ */ I(i, {
2840
+ /* @__PURE__ */ L(a, {
2800
2841
  overflow: "hidden",
2801
2842
  textOverflow: "ellipsis",
2802
2843
  textWrap: "nowrap",
2803
2844
  children: w
2804
2845
  }),
2805
- c.isSorted && /* @__PURE__ */ I(i, {
2846
+ c.isSorted && /* @__PURE__ */ L(a, {
2806
2847
  ps: (t.inlineWidth ?? 0) < 58 ? 0 : 2,
2807
- children: /* @__PURE__ */ I(Bt, {
2848
+ children: /* @__PURE__ */ L(Ut, {
2808
2849
  width: "16px",
2809
2850
  rotate: c.sortDirection === "ASC" ? 0 : 180,
2810
2851
  transition: "transform",
@@ -2814,37 +2855,37 @@ function Xt(e) {
2814
2855
  fill: "currentColor"
2815
2856
  })
2816
2857
  }),
2817
- f && /* @__PURE__ */ I(i, { minWidth: t.isEndAligned ? 4 : 10 })
2858
+ f && /* @__PURE__ */ L(a, { minWidth: t.isEndAligned ? 4 : 10 })
2818
2859
  ]
2819
2860
  })
2820
2861
  }),
2821
- d && /* @__PURE__ */ I(Yt, {
2862
+ u && /* @__PURE__ */ L(Qt, {
2822
2863
  column: t,
2823
2864
  controls: x
2824
2865
  }),
2825
- f && /* @__PURE__ */ I(Gt, { column: t })
2866
+ f && /* @__PURE__ */ L(Jt, { column: t })
2826
2867
  ] })
2827
2868
  });
2828
2869
  }
2829
- Xt.displayName = "DataGridHeaderCell";
2870
+ $t.displayName = "DataGridHeaderCell";
2830
2871
  //#endregion
2831
2872
  //#region src/components/dataGrid/components/dataGridHeader.tsx
2832
- function Zt(e) {
2833
- let { grid: t } = e, n = N(null), [r, a] = P(X.INITIAL), o = t.headerHover === "sliding", s = (e) => {
2873
+ function en(e) {
2874
+ let { grid: t } = e, n = P(null), [r, i] = F(X.INITIAL), o = t.headerHover === "sliding", s = (e) => {
2834
2875
  let t = n.current;
2835
2876
  if (!o || !t || e.pointerType === "touch") return;
2836
- if (X.isOnResizer(e.target)) return a((e) => X.pause(e));
2837
- let r = X.cellAt(t, e.target), i = r && X.bounds(t, r);
2838
- a((e) => X.hover(e, i));
2839
- }, c = () => a((e) => X.hover(e, void 0)), l = r.visible || r.paused;
2840
- A(() => {
2877
+ if (X.isOnResizer(e.target)) return i((e) => X.pause(e));
2878
+ let r = X.cellAt(t, e.target), a = r && X.bounds(t, r);
2879
+ i((e) => X.hover(e, a));
2880
+ }, c = () => i((e) => X.hover(e, void 0)), l = r.visible || r.paused;
2881
+ N(() => {
2841
2882
  if (l) return document.addEventListener("scroll", c, {
2842
2883
  capture: !0,
2843
2884
  passive: !0
2844
2885
  }), () => document.removeEventListener("scroll", c, { capture: !0 });
2845
2886
  }, [l]);
2846
2887
  let { bounds: u } = r;
2847
- return /* @__PURE__ */ L(x, {
2888
+ return /* @__PURE__ */ R(C, {
2848
2889
  ref: n,
2849
2890
  component: `${t.componentName}.header`,
2850
2891
  props: {
@@ -2854,20 +2895,20 @@ function Zt(e) {
2854
2895
  },
2855
2896
  style: { gridTemplateColumns: t.gridTemplateColumns.value },
2856
2897
  children: [
2857
- t.headerRows.value.map((e, t) => /* @__PURE__ */ I(i, {
2898
+ t.headerRows.value.map((e, t) => /* @__PURE__ */ L(a, {
2858
2899
  display: "contents",
2859
2900
  props: {
2860
2901
  role: "row",
2861
2902
  "aria-rowindex": t + 1
2862
2903
  },
2863
- children: e.map((e, n) => /* @__PURE__ */ I(Xt, {
2904
+ children: e.map((e, n) => /* @__PURE__ */ L($t, {
2864
2905
  column: e,
2865
2906
  row: t,
2866
2907
  columnIndex: n
2867
2908
  }, e.uniqueKey))
2868
2909
  }, t)),
2869
- /* @__PURE__ */ I(zt, { grid: t }),
2870
- o && u && /* @__PURE__ */ I(i, {
2910
+ /* @__PURE__ */ L(Ht, { grid: t }),
2911
+ o && u && /* @__PURE__ */ L(a, {
2871
2912
  tag: "span",
2872
2913
  component: `${t.componentName}.header.hover`,
2873
2914
  variant: {
@@ -2886,65 +2927,65 @@ function Zt(e) {
2886
2927
  ]
2887
2928
  });
2888
2929
  }
2889
- Zt.displayName = "DataGridHeader";
2890
- var Qt = D(Zt);
2930
+ en.displayName = "DataGridHeader";
2931
+ var tn = A(en);
2891
2932
  //#endregion
2892
2933
  //#region src/components/dataGrid/components/dataGridLoader.tsx
2893
- function $t(e) {
2934
+ function nn(e) {
2894
2935
  let { grid: t } = e;
2895
- return /* @__PURE__ */ I(i, {
2936
+ return /* @__PURE__ */ L(a, {
2896
2937
  component: `${t.componentName}.loader`,
2897
2938
  props: { "aria-hidden": !0 },
2898
- children: /* @__PURE__ */ I(i, {
2939
+ children: /* @__PURE__ */ L(a, {
2899
2940
  component: `${t.componentName}.loader.track`,
2900
2941
  style: { height: 3 },
2901
- children: /* @__PURE__ */ I(i, {
2942
+ children: /* @__PURE__ */ L(a, {
2902
2943
  component: `${t.componentName}.loader.track.bar`,
2903
2944
  width: "2/5"
2904
2945
  })
2905
2946
  })
2906
2947
  });
2907
2948
  }
2908
- $t.displayName = "DataGridLoader";
2949
+ nn.displayName = "DataGridLoader";
2909
2950
  //#endregion
2910
2951
  //#region src/components/dataGrid/components/dataGridContent.tsx
2911
- function en(e) {
2912
- let { grid: t } = e, n = N(null), [a, o] = P({
2952
+ function rn(e) {
2953
+ let { grid: t } = e, n = P(null), [i, o] = F({
2913
2954
  top: 0,
2914
2955
  direction: "down"
2915
- }), s = N(null), c = O((e) => {
2956
+ }), s = P(null), c = j((e) => {
2916
2957
  o((t) => e === t.top ? t : {
2917
2958
  top: e,
2918
- direction: ye.directionOf(t.top, e, t.direction)
2959
+ direction: xe.directionOf(t.top, e, t.direction)
2919
2960
  });
2920
- }, []), l = O((e) => {
2961
+ }, []), l = j((e) => {
2921
2962
  s.current !== null && cancelAnimationFrame(s.current), s.current = requestAnimationFrame(() => {
2922
2963
  c(e.target.scrollTop), s.current = null;
2923
2964
  });
2924
- }, [c]), { navigation: u, onKeyDown: d } = Ue({
2965
+ }, [c]), { navigation: u, onKeyDown: d } = Ke({
2925
2966
  grid: t,
2926
2967
  scrollerRef: n,
2927
- scroll: a,
2968
+ scroll: i,
2928
2969
  onScrollTo: c
2929
2970
  }), { source: f } = t, { queryVersion: p } = f;
2930
2971
  r(() => {
2931
2972
  f.enabled && n.current && (n.current.scrollTop = 0);
2932
- }, [f, p]), A(() => {
2973
+ }, [f, p]), N(() => {
2933
2974
  if (!f.enabled) return;
2934
- let { startIndex: e, take: r } = t.viewport.window(n.current?.scrollTop ?? 0, a.direction);
2975
+ let { startIndex: e, take: r } = t.viewport.window(n.current?.scrollTop ?? 0, i.direction);
2935
2976
  f.request(e, e + r);
2936
2977
  }, [
2937
2978
  t,
2938
2979
  f,
2939
2980
  p,
2940
- a,
2981
+ i,
2941
2982
  t.totalRowCount,
2942
2983
  t.page,
2943
2984
  t.pageSize,
2944
2985
  t.expansionVersion
2945
2986
  ]);
2946
2987
  let { range: m } = t, { isDragging: h } = m;
2947
- return A(() => {
2988
+ return N(() => {
2948
2989
  if (h) return window.addEventListener("pointerup", m.endDrag), window.addEventListener("pointercancel", m.endDrag), () => {
2949
2990
  window.removeEventListener("pointerup", m.endDrag), window.removeEventListener("pointercancel", m.endDrag);
2950
2991
  };
@@ -2955,9 +2996,9 @@ function en(e) {
2955
2996
  t.setContainerWidth(e.clientWidth), t.paintSizes();
2956
2997
  });
2957
2998
  return r.observe(e), () => r.disconnect();
2958
- }, [t]), t.hasVisibleColumns ? /* @__PURE__ */ I(ge.Provider, {
2999
+ }, [t]), t.hasVisibleColumns ? /* @__PURE__ */ L(ve.Provider, {
2959
3000
  value: u,
2960
- children: /* @__PURE__ */ L(i, {
3001
+ children: /* @__PURE__ */ R(a, {
2961
3002
  ref: n,
2962
3003
  component: `${t.componentName}.content`,
2963
3004
  overflowX: "auto",
@@ -2975,33 +3016,33 @@ function en(e) {
2975
3016
  onPaste: m.onPaste
2976
3017
  },
2977
3018
  children: [
2978
- /* @__PURE__ */ I(Qt, {
3019
+ /* @__PURE__ */ L(tn, {
2979
3020
  grid: t,
2980
3021
  version: t.headerVersion
2981
3022
  }),
2982
- (t.props.loading || f.isLoading) && /* @__PURE__ */ I($t, { grid: t }),
2983
- /* @__PURE__ */ I(Et, {
3023
+ (t.props.loading || f.isLoading) && /* @__PURE__ */ L(nn, { grid: t }),
3024
+ /* @__PURE__ */ L(kt, {
2984
3025
  grid: t,
2985
- scroll: a
3026
+ scroll: i
2986
3027
  })
2987
3028
  ]
2988
3029
  })
2989
- }) : /* @__PURE__ */ I(Dt, { grid: t });
3030
+ }) : /* @__PURE__ */ L(At, { grid: t });
2990
3031
  }
2991
- en.displayName = "DataGridContent";
3032
+ rn.displayName = "DataGridContent";
2992
3033
  //#endregion
2993
3034
  //#region src/components/dataGrid/components/dataGridDataSourceError.tsx
2994
- function tn(e) {
3035
+ function an(e) {
2995
3036
  let { grid: t } = e, { error: n } = t.source;
2996
3037
  if (n === void 0) return null;
2997
3038
  let r = n instanceof Error && n.message ? n.message : t.localeText.loadError;
2998
- return /* @__PURE__ */ L(h, {
3039
+ return /* @__PURE__ */ R(_, {
2999
3040
  component: `${t.componentName}.error`,
3000
3041
  props: { role: "alert" },
3001
- children: [/* @__PURE__ */ I(i, {
3042
+ children: [/* @__PURE__ */ L(a, {
3002
3043
  component: `${t.componentName}.error.message`,
3003
3044
  children: r
3004
- }), /* @__PURE__ */ I(p, {
3045
+ }), /* @__PURE__ */ L(h, {
3005
3046
  component: `${t.componentName}.error.retry`,
3006
3047
  type: "button",
3007
3048
  onClick: t.source.retry,
@@ -3009,31 +3050,31 @@ function tn(e) {
3009
3050
  })]
3010
3051
  });
3011
3052
  }
3012
- tn.displayName = "DataGridDataSourceError";
3053
+ an.displayName = "DataGridDataSourceError";
3013
3054
  //#endregion
3014
3055
  //#region src/components/dataGrid/components/dataGridColumnGroups.tsx
3015
- function nn(e) {
3056
+ function on(e) {
3016
3057
  let { grid: t } = e;
3017
- return t.groupColumns.size === 0 ? null : /* @__PURE__ */ L(h, {
3058
+ return t.groupColumns.size === 0 ? null : /* @__PURE__ */ R(_, {
3018
3059
  component: `${t.componentName}.topBar.columnGroups`,
3019
- children: [/* @__PURE__ */ I(C, {
3060
+ children: [/* @__PURE__ */ L(T, {
3020
3061
  component: `${t.componentName}.topBar.columnGroups.icon`,
3021
- children: /* @__PURE__ */ I(Ht, {
3062
+ children: /* @__PURE__ */ L(Gt, {
3022
3063
  width: "100%",
3023
3064
  fill: "currentColor"
3024
3065
  })
3025
- }), t.groupedColumns.map((e) => /* @__PURE__ */ L(ee.Fragment, { children: [/* @__PURE__ */ I(Y, {
3066
+ }), t.groupedColumns.map((e) => /* @__PURE__ */ R(D.Fragment, { children: [/* @__PURE__ */ L(Y, {
3026
3067
  fill: "currentColor",
3027
3068
  width: "14px",
3028
3069
  height: "14px",
3029
3070
  rotate: -90
3030
- }), /* @__PURE__ */ L(h, {
3071
+ }), /* @__PURE__ */ R(_, {
3031
3072
  component: `${t.componentName}.topBar.columnGroups.item`,
3032
- children: [e.header ?? e.key, /* @__PURE__ */ I(p, {
3073
+ children: [e.header ?? e.key, /* @__PURE__ */ L(h, {
3033
3074
  component: `${t.componentName}.topBar.columnGroups.item.icon`,
3034
3075
  onClick: () => t.toggleGrouping(e.key),
3035
3076
  props: { "aria-label": t.localeText.stopGrouping(String(e.header ?? e.key)) },
3036
- children: /* @__PURE__ */ I(i, {
3077
+ children: /* @__PURE__ */ L(a, {
3037
3078
  fontSize: 10,
3038
3079
  color: "base-400",
3039
3080
  hover: { color: "base-600" },
@@ -3043,53 +3084,53 @@ function nn(e) {
3043
3084
  })] }, e.key))]
3044
3085
  });
3045
3086
  }
3046
- nn.displayName = "DataGridColumnGroups";
3087
+ on.displayName = "DataGridColumnGroups";
3047
3088
  //#endregion
3048
3089
  //#region src/icons/searchIcon.tsx
3049
- function rn(e) {
3050
- return /* @__PURE__ */ I(f, {
3090
+ function sn(e) {
3091
+ return /* @__PURE__ */ L(m, {
3051
3092
  viewBox: "0 0 488.4 488.4",
3052
3093
  width: "1.5rem",
3053
3094
  ...e,
3054
- children: /* @__PURE__ */ I(d, { d: "M0 203.25c0 112.1 91.2 203.2 203.2 203.2 51.6 0 98.8-19.4 134.7-51.2l129.5 129.5c2.4 2.4 5.5 3.6 8.7 3.6s6.3-1.2 8.7-3.6c4.8-4.8 4.8-12.5 0-17.3l-129.6-129.5c31.8-35.9 51.2-83 51.2-134.7C406.4 91.15 315.2.05 203.2.05S0 91.15 0 203.25zm381.9 0c0 98.5-80.2 178.7-178.7 178.7s-178.7-80.2-178.7-178.7 80.2-178.7 178.7-178.7 178.7 80.1 178.7 178.7z" })
3095
+ children: /* @__PURE__ */ L(p, { d: "M0 203.25c0 112.1 91.2 203.2 203.2 203.2 51.6 0 98.8-19.4 134.7-51.2l129.5 129.5c2.4 2.4 5.5 3.6 8.7 3.6s6.3-1.2 8.7-3.6c4.8-4.8 4.8-12.5 0-17.3l-129.6-129.5c31.8-35.9 51.2-83 51.2-134.7C406.4 91.15 315.2.05 203.2.05S0 91.15 0 203.25zm381.9 0c0 98.5-80.2 178.7-178.7 178.7s-178.7-80.2-178.7-178.7 80.2-178.7 178.7-178.7 178.7 80.1 178.7 178.7z" })
3055
3096
  });
3056
3097
  }
3057
3098
  //#endregion
3058
3099
  //#region src/components/dataGrid/components/dataGridColumnsPanel.tsx
3059
- var an = 6;
3060
- function on(e) {
3061
- let { grid: t } = e, { columnVisibility: n, localeText: r, componentName: a } = t, { visibleCount: o, total: s, hasHidden: c } = n, [l, u] = P(!1), [m, h] = P(""), g = O((e) => {
3062
- u(e), e || h("");
3100
+ var cn = 6;
3101
+ function ln(e) {
3102
+ let { grid: t } = e, { columnVisibility: n, localeText: r, componentName: i } = t, { visibleCount: o, total: s, hasHidden: c } = n, [l, u] = F(!1), [d, g] = F(""), _ = j((e) => {
3103
+ u(e), e || g("");
3063
3104
  }, []);
3064
- return /* @__PURE__ */ I(w, {
3105
+ return /* @__PURE__ */ L(f, { children: /* @__PURE__ */ L(E, {
3065
3106
  label: r.columnsMenu,
3066
3107
  side: "bottom",
3067
3108
  align: "end",
3068
3109
  open: l,
3069
- onOpenChange: g,
3110
+ onOpenChange: _,
3070
3111
  autoFocus: !1,
3071
3112
  p: 0,
3072
3113
  overflow: "visible",
3073
- trigger: (e) => /* @__PURE__ */ L(p, {
3114
+ trigger: (e) => /* @__PURE__ */ R(h, {
3074
3115
  ...e,
3075
- component: `${a}.topBar.columnVisibility`,
3116
+ component: `${i}.topBar.columnVisibility`,
3076
3117
  props: {
3077
3118
  ...e.props,
3078
3119
  "aria-label": c ? r.columnsMenuLabel(o, s) : void 0
3079
3120
  },
3080
3121
  children: [
3081
- /* @__PURE__ */ I(f, {
3122
+ /* @__PURE__ */ L(m, {
3082
3123
  viewBox: "0 0 20 20",
3083
3124
  width: 16,
3084
3125
  height: 16,
3085
3126
  fill: "none",
3086
3127
  stroke: "currentColor",
3087
3128
  strokeWidth: 1.6,
3088
- children: /* @__PURE__ */ I(d, { d: "M4.5 3.5h11a1 1 0 0 1 1 1v11a1 1 0 0 1-1 1h-11a1 1 0 0 1-1-1v-11a1 1 0 0 1 1-1ZM8 3.5v13M12 3.5v13" })
3129
+ children: /* @__PURE__ */ L(p, { d: "M4.5 3.5h11a1 1 0 0 1 1 1v11a1 1 0 0 1-1 1h-11a1 1 0 0 1-1-1v-11a1 1 0 0 1 1-1ZM8 3.5v13M12 3.5v13" })
3089
3130
  }),
3090
3131
  r.columnsMenu,
3091
- c && /* @__PURE__ */ L(i, {
3092
- component: `${a}.topBar.columnVisibility.badge`,
3132
+ c && /* @__PURE__ */ R(a, {
3133
+ component: `${i}.topBar.columnVisibility.badge`,
3093
3134
  tag: "span",
3094
3135
  variant: { empty: o === 0 },
3095
3136
  props: { "aria-hidden": !0 },
@@ -3101,21 +3142,21 @@ function on(e) {
3101
3142
  })
3102
3143
  ]
3103
3144
  }),
3104
- children: /* @__PURE__ */ I(sn, {
3145
+ children: /* @__PURE__ */ L(un, {
3105
3146
  grid: t,
3106
3147
  open: l,
3107
- query: m,
3108
- onQueryChange: h
3148
+ query: d,
3149
+ onQueryChange: g
3109
3150
  })
3110
- });
3151
+ }) });
3111
3152
  }
3112
- on.displayName = "DataGridColumnsPanel";
3113
- function sn({ grid: e, open: t, query: n, onQueryChange: r }) {
3114
- let { columnVisibility: a, localeText: o, componentName: s } = e, c = `${s}.topBar.columnVisibility`, l = N(null), u = N(null), d = a.total > an, f = a.search(n), m = a.sections(f), g = f.every((e) => e.visible), _ = f.every((e) => !e.visible);
3115
- A(() => {
3153
+ ln.displayName = "DataGridColumnsPanel";
3154
+ function un({ grid: e, open: t, query: n, onQueryChange: r }) {
3155
+ let { columnVisibility: i, localeText: o, componentName: s } = e, c = `${s}.topBar.columnVisibility`, l = P(null), u = P(null), d = i.total > cn, f = i.search(n), p = i.sections(f), m = f.every((e) => e.visible), g = f.every((e) => !e.visible);
3156
+ N(() => {
3116
3157
  t && (u.current ?? l.current?.querySelector("input"))?.focus();
3117
3158
  }, [t]);
3118
- let v = O((e) => {
3159
+ let v = j((e) => {
3119
3160
  if (![
3120
3161
  "ArrowDown",
3121
3162
  "ArrowUp",
@@ -3132,20 +3173,20 @@ function sn({ grid: e, open: t, query: n, onQueryChange: r }) {
3132
3173
  }[e.key];
3133
3174
  e.preventDefault(), i?.focus();
3134
3175
  }, []);
3135
- return /* @__PURE__ */ L(h, {
3176
+ return /* @__PURE__ */ R(_, {
3136
3177
  ref: l,
3137
3178
  component: `${c}.panel`,
3138
3179
  props: { onKeyDown: v },
3139
3180
  children: [
3140
- d && /* @__PURE__ */ L(h, {
3181
+ d && /* @__PURE__ */ R(_, {
3141
3182
  component: `${c}.search`,
3142
- children: [/* @__PURE__ */ I(h, {
3183
+ children: [/* @__PURE__ */ L(_, {
3143
3184
  component: `${c}.searchIcon`,
3144
- children: /* @__PURE__ */ I(rn, {
3185
+ children: /* @__PURE__ */ L(sn, {
3145
3186
  fill: "currentColor",
3146
3187
  width: "14px"
3147
3188
  })
3148
- }), /* @__PURE__ */ I(y, {
3189
+ }), /* @__PURE__ */ L(x, {
3149
3190
  ref: u,
3150
3191
  component: `${c}.searchInput`,
3151
3192
  value: n,
@@ -3158,40 +3199,40 @@ function sn({ grid: e, open: t, query: n, onQueryChange: r }) {
3158
3199
  }
3159
3200
  })]
3160
3201
  }),
3161
- /* @__PURE__ */ L(h, {
3202
+ /* @__PURE__ */ R(_, {
3162
3203
  component: `${c}.toolbar`,
3163
- children: [/* @__PURE__ */ I(i, {
3204
+ children: [/* @__PURE__ */ L(a, {
3164
3205
  component: `${c}.count`,
3165
- children: o.columnsMenuShown(a.visibleCount, a.total)
3166
- }), /* @__PURE__ */ L(h, {
3206
+ children: o.columnsMenuShown(i.visibleCount, i.total)
3207
+ }), /* @__PURE__ */ R(_, {
3167
3208
  gap: 1,
3168
- children: [/* @__PURE__ */ I(p, {
3209
+ children: [/* @__PURE__ */ L(h, {
3169
3210
  component: `${c}.action`,
3170
- disabled: g,
3171
- onClick: () => a.setAll(!0, f),
3211
+ disabled: m,
3212
+ onClick: () => i.setAll(!0, f),
3172
3213
  children: o.columnsMenuShowAll
3173
- }), /* @__PURE__ */ I(p, {
3214
+ }), /* @__PURE__ */ L(h, {
3174
3215
  component: `${c}.action`,
3175
- disabled: _,
3176
- onClick: () => a.setAll(!1, f),
3216
+ disabled: g,
3217
+ onClick: () => i.setAll(!1, f),
3177
3218
  children: o.columnsMenuHideAll
3178
3219
  })]
3179
3220
  })]
3180
3221
  }),
3181
- /* @__PURE__ */ L(h, {
3222
+ /* @__PURE__ */ R(_, {
3182
3223
  component: `${c}.list`,
3183
- children: [m.map((e, t) => /* @__PURE__ */ L(h, {
3224
+ children: [p.map((e, t) => /* @__PURE__ */ R(_, {
3184
3225
  component: `${c}.section`,
3185
3226
  variant: { divided: t > 0 && !e.group },
3186
3227
  props: e.group ? {
3187
3228
  role: "group",
3188
3229
  "aria-label": e.group
3189
3230
  } : void 0,
3190
- children: [e.group && /* @__PURE__ */ I(i, {
3231
+ children: [e.group && /* @__PURE__ */ L(a, {
3191
3232
  component: `${c}.group`,
3192
3233
  props: { "aria-hidden": !0 },
3193
3234
  children: e.group
3194
- }), e.entries.map((e) => /* @__PURE__ */ I(T, {
3235
+ }), e.entries.map((e) => /* @__PURE__ */ L(ee, {
3195
3236
  checked: e.visible,
3196
3237
  onChange: () => e.column.toggleVisibility(),
3197
3238
  label: e.label,
@@ -3200,7 +3241,7 @@ function sn({ grid: e, open: t, query: n, onQueryChange: r }) {
3200
3241
  display: "flex"
3201
3242
  }
3202
3243
  }, e.id))]
3203
- }, `${e.group ?? ""}-${t}`)), f.length === 0 && /* @__PURE__ */ I(i, {
3244
+ }, `${e.group ?? ""}-${t}`)), f.length === 0 && /* @__PURE__ */ L(a, {
3204
3245
  component: `${c}.empty`,
3205
3246
  props: { role: "status" },
3206
3247
  children: o.columnsMenuNoMatch(n.trim())
@@ -3211,18 +3252,18 @@ function sn({ grid: e, open: t, query: n, onQueryChange: r }) {
3211
3252
  }
3212
3253
  //#endregion
3213
3254
  //#region src/components/dataGrid/components/dataGridExport.tsx
3214
- function cn(e) {
3215
- let { grid: t } = e, n = t.exportConfig, r = O(() => void t.exportCsv(n).catch(() => void 0), [t, n]), i = O(() => void t.exportXlsx(n).catch(() => void 0), [t, n]);
3216
- return n ? /* @__PURE__ */ L(h, {
3255
+ function dn(e) {
3256
+ let { grid: t } = e, n = t.exportConfig, r = j(() => void t.exportCsv(n).then(() => t.reportInteraction("export", "csv", "toolbar"), () => void 0), [t, n]), i = j(() => void t.exportXlsx(n).then(() => t.reportInteraction("export", "xlsx", "toolbar"), () => void 0), [t, n]);
3257
+ return n ? /* @__PURE__ */ R(_, {
3217
3258
  component: `${t.componentName}.topBar.export`,
3218
3259
  ai: "center",
3219
3260
  gap: 2,
3220
- children: [n.csv !== !1 && /* @__PURE__ */ I(ln, {
3261
+ children: [n.csv !== !1 && /* @__PURE__ */ L(fn, {
3221
3262
  componentName: t.componentName,
3222
3263
  onClick: r,
3223
3264
  label: t.localeText.exportCsvLabel,
3224
3265
  children: t.localeText.exportCsv
3225
- }), n.xlsx !== !1 && /* @__PURE__ */ I(ln, {
3266
+ }), n.xlsx !== !1 && /* @__PURE__ */ L(fn, {
3226
3267
  componentName: t.componentName,
3227
3268
  onClick: i,
3228
3269
  label: t.localeText.exportExcelLabel,
@@ -3230,25 +3271,25 @@ function cn(e) {
3230
3271
  })]
3231
3272
  }) : null;
3232
3273
  }
3233
- cn.displayName = "DataGridExport";
3234
- function ln(e) {
3274
+ dn.displayName = "DataGridExport";
3275
+ function fn(e) {
3235
3276
  let { componentName: t, onClick: n, label: r, children: i } = e;
3236
- return /* @__PURE__ */ L(p, {
3277
+ return /* @__PURE__ */ R(h, {
3237
3278
  component: `${t}.topBar.export.button`,
3238
3279
  onClick: n,
3239
3280
  props: { "aria-label": r },
3240
- children: [/* @__PURE__ */ L(f, {
3281
+ children: [/* @__PURE__ */ R(m, {
3241
3282
  viewBox: "0 0 20 20",
3242
3283
  width: 16,
3243
3284
  height: 16,
3244
3285
  fill: "none",
3245
3286
  stroke: "currentColor",
3246
3287
  strokeWidth: 1.6,
3247
- children: [/* @__PURE__ */ I(d, {
3288
+ children: [/* @__PURE__ */ L(p, {
3248
3289
  d: "M10 3v9m0 0 3.5-3.5M10 12 6.5 8.5",
3249
3290
  strokeLinecap: "round",
3250
3291
  strokeLinejoin: "round"
3251
- }), /* @__PURE__ */ I(d, {
3292
+ }), /* @__PURE__ */ L(p, {
3252
3293
  d: "M3.5 13.5v2a1 1 0 0 0 1 1h11a1 1 0 0 0 1-1v-2",
3253
3294
  strokeLinecap: "round"
3254
3295
  })]
@@ -3257,38 +3298,38 @@ function ln(e) {
3257
3298
  }
3258
3299
  //#endregion
3259
3300
  //#region src/components/dataGrid/components/dataGridGlobalFilter.tsx
3260
- function un(e) {
3261
- let { grid: t } = e, [n, r] = P(t.globalFilterValue), { debounce: a, cancel: o } = jt(t.globalFilterValue, (e) => e === n, r), s = O((e) => {
3301
+ function pn(e) {
3302
+ let { grid: t } = e, [n, r] = F(t.globalFilterValue), { debounce: i, cancel: o } = Pt(t.globalFilterValue, (e) => e === n, r), s = j((e) => {
3262
3303
  let n = e.target.value;
3263
- r(n), a("value", () => t.filter.setGlobalFilter(n));
3264
- }, [t, a]), c = O(() => {
3304
+ r(n), i("value", () => t.filter.setGlobalFilter(n));
3305
+ }, [t, i]), c = j(() => {
3265
3306
  o(), r(""), t.filter.setGlobalFilter("");
3266
3307
  }, [t, o]), { filtered: l, total: u } = t.filter.filterStats, d = !t.props.def.bottomBar && t.filter.hasActiveFilters && l !== u;
3267
- return /* @__PURE__ */ L(h, {
3308
+ return /* @__PURE__ */ R(_, {
3268
3309
  component: `${t.componentName}.topBar.globalFilter`,
3269
- children: [d && /* @__PURE__ */ L(i, {
3310
+ children: [d && /* @__PURE__ */ R(a, {
3270
3311
  component: `${t.componentName}.topBar.globalFilter.stats`,
3271
3312
  children: [
3272
3313
  l,
3273
3314
  "/",
3274
3315
  u
3275
3316
  ]
3276
- }), /* @__PURE__ */ L(h, {
3317
+ }), /* @__PURE__ */ R(_, {
3277
3318
  position: "relative",
3278
3319
  ai: "center",
3279
3320
  children: [
3280
- /* @__PURE__ */ I(h, {
3321
+ /* @__PURE__ */ L(_, {
3281
3322
  position: "absolute",
3282
3323
  insetStart: 3,
3283
3324
  pointerEvents: "none",
3284
3325
  color: "base-400",
3285
3326
  theme: { dark: { color: "base-500" } },
3286
- children: /* @__PURE__ */ I(rn, {
3327
+ children: /* @__PURE__ */ L(sn, {
3287
3328
  fill: "currentColor",
3288
3329
  width: "14px"
3289
3330
  })
3290
3331
  }),
3291
- /* @__PURE__ */ I(y, {
3332
+ /* @__PURE__ */ L(x, {
3292
3333
  placeholder: t.localeText.searchPlaceholder,
3293
3334
  variant: "compact",
3294
3335
  value: n,
@@ -3296,7 +3337,7 @@ function un(e) {
3296
3337
  ps: 8,
3297
3338
  pe: n ? 8 : 3
3298
3339
  }),
3299
- n && /* @__PURE__ */ I(i, {
3340
+ n && /* @__PURE__ */ L(a, {
3300
3341
  position: "absolute",
3301
3342
  insetEnd: 2,
3302
3343
  cursor: "pointer",
@@ -3308,7 +3349,7 @@ function un(e) {
3308
3349
  hover: { color: "base-300" }
3309
3350
  } },
3310
3351
  props: { onClick: c },
3311
- children: /* @__PURE__ */ I(i, {
3352
+ children: /* @__PURE__ */ L(a, {
3312
3353
  fontSize: 12,
3313
3354
  fontWeight: 600,
3314
3355
  children: "✕"
@@ -3320,52 +3361,52 @@ function un(e) {
3320
3361
  }
3321
3362
  //#endregion
3322
3363
  //#region src/components/dataGrid/components/dataGridTopBar.tsx
3323
- function dn(e) {
3324
- let { grid: t } = e, { title: n, topBarContent: r, globalFilter: a } = t.props.def;
3325
- return /* @__PURE__ */ L(h, {
3364
+ function mn(e) {
3365
+ let { grid: t } = e, { title: n, topBarContent: r, globalFilter: i } = t.props.def;
3366
+ return /* @__PURE__ */ R(_, {
3326
3367
  component: `${t.componentName}.topBar`,
3327
3368
  position: "relative",
3328
3369
  d: "column",
3329
3370
  gap: 3,
3330
- children: [/* @__PURE__ */ L(h, {
3371
+ children: [/* @__PURE__ */ R(_, {
3331
3372
  ai: "center",
3332
3373
  jc: "space-between",
3333
3374
  gap: 4,
3334
3375
  flexWrap: "wrap",
3335
3376
  width: "fit",
3336
- children: [/* @__PURE__ */ L(h, {
3377
+ children: [/* @__PURE__ */ R(_, {
3337
3378
  ai: "center",
3338
3379
  gap: 3,
3339
3380
  flexWrap: "wrap",
3340
3381
  minWidth: 0,
3341
- children: [n && /* @__PURE__ */ I(i, {
3382
+ children: [n && /* @__PURE__ */ L(a, {
3342
3383
  id: t.titleId,
3343
3384
  fontWeight: 600,
3344
3385
  fontSize: 16,
3345
3386
  color: "base-800",
3346
3387
  theme: { dark: { color: "base-100" } },
3347
3388
  children: n
3348
- }), /* @__PURE__ */ I(nn, { grid: t })]
3349
- }), /* @__PURE__ */ L(h, {
3389
+ }), /* @__PURE__ */ L(on, { grid: t })]
3390
+ }), /* @__PURE__ */ R(_, {
3350
3391
  ai: "center",
3351
3392
  gap: 3,
3352
3393
  flexWrap: "wrap",
3353
3394
  children: [
3354
- a && /* @__PURE__ */ I(un, { grid: t }),
3355
- /* @__PURE__ */ I(on, { grid: t }),
3356
- /* @__PURE__ */ I(cn, { grid: t })
3395
+ i && /* @__PURE__ */ L(pn, { grid: t }),
3396
+ /* @__PURE__ */ L(ln, { grid: t }),
3397
+ /* @__PURE__ */ L(dn, { grid: t })
3357
3398
  ]
3358
3399
  })]
3359
- }), r && /* @__PURE__ */ I(i, {
3400
+ }), r && /* @__PURE__ */ L(a, {
3360
3401
  width: "fit",
3361
3402
  children: r
3362
3403
  })]
3363
3404
  });
3364
3405
  }
3365
- dn.displayName = "DataGridTopBar";
3406
+ mn.displayName = "DataGridTopBar";
3366
3407
  //#endregion
3367
3408
  //#region src/utils/string/fuzzySearch.ts
3368
- function fn(e, t) {
3409
+ function hn(e, t) {
3369
3410
  if (!e) return {
3370
3411
  score: 1,
3371
3412
  matches: []
@@ -3378,16 +3419,16 @@ function fn(e, t) {
3378
3419
  matches: o
3379
3420
  });
3380
3421
  }
3381
- function pn(e, t) {
3382
- return fn(e, t) !== null;
3422
+ function gn(e, t) {
3423
+ return hn(e, t) !== null;
3383
3424
  }
3384
3425
  //#endregion
3385
3426
  //#region src/components/dataGrid/components/dataGridCellRowDetail.tsx
3386
- function mn(e) {
3387
- let { cell: t } = e, n = t.isExpanded, r = O((e) => {
3427
+ function _n(e) {
3428
+ let { cell: t } = e, n = t.isExpanded, r = j((e) => {
3388
3429
  e.stopPropagation(), t.toggleDetail();
3389
3430
  }, [t]);
3390
- return /* @__PURE__ */ I(p, {
3431
+ return /* @__PURE__ */ L(h, {
3391
3432
  component: `${t.grid.componentName}.body.cell.rowDetail`,
3392
3433
  variant: { isExpanded: n },
3393
3434
  type: "button",
@@ -3403,7 +3444,7 @@ function mn(e) {
3403
3444
  "aria-label": (n ? t.grid.localeText.collapseRowDetail : t.grid.localeText.expandRowDetail)(t.row.rowIndex + 1),
3404
3445
  "aria-expanded": n
3405
3446
  },
3406
- children: /* @__PURE__ */ I(Y, {
3447
+ children: /* @__PURE__ */ L(Y, {
3407
3448
  fill: "currentColor",
3408
3449
  width: "14px",
3409
3450
  height: "14px",
@@ -3411,14 +3452,14 @@ function mn(e) {
3411
3452
  })
3412
3453
  });
3413
3454
  }
3414
- mn.displayName = "DataGridCellRowDetail";
3455
+ _n.displayName = "DataGridCellRowDetail";
3415
3456
  //#endregion
3416
3457
  //#region src/components/dataGrid/components/dataGridCellRowSelection.tsx
3417
- function hn(e) {
3418
- let { cell: t } = e, n = O(() => {
3458
+ function vn(e) {
3459
+ let { cell: t } = e, n = j(() => {
3419
3460
  t.toggleSelection();
3420
3461
  }, [t]);
3421
- return /* @__PURE__ */ I(g, {
3462
+ return /* @__PURE__ */ L(v, {
3422
3463
  variant: "datagrid",
3423
3464
  checked: t.selected,
3424
3465
  indeterminate: t.indeterminate,
@@ -3429,15 +3470,15 @@ function hn(e) {
3429
3470
  }
3430
3471
  });
3431
3472
  }
3432
- hn.displayName = "DataGridCellRowSelection";
3473
+ vn.displayName = "DataGridCellRowSelection";
3433
3474
  //#endregion
3434
3475
  //#region src/components/dataGrid/contracts/dataGridContract.ts
3435
- function gn(e) {
3476
+ function yn(e) {
3436
3477
  if (e) return e === "LEFT" ? "START" : e === "RIGHT" ? "END" : e;
3437
3478
  }
3438
3479
  //#endregion
3439
3480
  //#region src/components/dataGrid/models/headerCellModel.ts
3440
- var _n = 1e3, vn = class {
3481
+ var bn = 1e3, xn = class {
3441
3482
  column;
3442
3483
  constructor(e) {
3443
3484
  this.column = e;
@@ -3514,7 +3555,7 @@ var _n = 1e3, vn = class {
3514
3555
  return Math.max(1, this.column.leafs.length) * this.grid.MIN_COLUMN_WIDTH_PX;
3515
3556
  }
3516
3557
  get maxWidth() {
3517
- return Math.max(this.grid.containerWidth || _n, this.width, this.minWidth);
3558
+ return Math.max(this.grid.containerWidth || bn, this.width, this.minWidth);
3518
3559
  }
3519
3560
  get paddingStart() {
3520
3561
  if (!this.column.isRowSelection) return this.column.isEndAligned ? 10 : 3;
@@ -3600,15 +3641,15 @@ var _n = 1e3, vn = class {
3600
3641
  pin: t.pin
3601
3642
  } : r, n, this)) ?? [], this.isLeaf) {
3602
3643
  let e = this.grid.columnWidths.get(this.key);
3603
- this._inlineWidth = e ?? this.def.width ?? this.grid.DEFAULT_COLUMN_WIDTH_PX, this._pin = gn(t.pin);
3644
+ this._inlineWidth = e ?? this.def.width ?? this.grid.DEFAULT_COLUMN_WIDTH_PX, this._pin = yn(t.pin);
3604
3645
  }
3605
3646
  }
3606
3647
  columns = [];
3607
3648
  get kind() {
3608
3649
  switch (this.key) {
3609
- case Ge: return "rowNumber";
3610
- case Ke: return "rowSelection";
3611
- case qe: return "rowDetail";
3650
+ case Je: return "rowNumber";
3651
+ case Ye: return "rowSelection";
3652
+ case Xe: return "rowDetail";
3612
3653
  case K: return "grouping";
3613
3654
  default: return "data";
3614
3655
  }
@@ -3664,7 +3705,7 @@ var _n = 1e3, vn = class {
3664
3705
  insetInlineEnd: t ? `var(${this.inlineEndVarName})` : void 0
3665
3706
  };
3666
3707
  }, () => [this.pinFlags]);
3667
- _headerCell = q(() => new vn(this));
3708
+ _headerCell = q(() => new xn(this));
3668
3709
  get headerCell() {
3669
3710
  return this._headerCell.value;
3670
3711
  }
@@ -3914,7 +3955,7 @@ var _n = 1e3, vn = class {
3914
3955
  this.applyResize(e), this.grid.notify();
3915
3956
  };
3916
3957
  endResize = () => {
3917
- this.grid.notify();
3958
+ this.grid.notify(), this.grid.reportInteraction("columnResize", this.leafs.reduce((e, t) => e + (t.inlineWidth ?? t.baseWidth), 0), "resize", { columnKey: this.key });
3918
3959
  };
3919
3960
  moveResizer = (e) => {
3920
3961
  this.beginResize(0), this.applyResize(e);
@@ -3924,8 +3965,12 @@ var _n = 1e3, vn = class {
3924
3965
  this.moveResizer((e - t) * this.resizeSign);
3925
3966
  };
3926
3967
  pinColumn = (e) => {
3927
- this.isLeaf ? this._pin = gn(e) : this.columns.forEach((t) => t.pinColumn(e)), this.grid.pinColumn(this.uniqueKey, e);
3968
+ let t = this.pin;
3969
+ this.setPin(e), this.pin !== t && this.grid.reportInteraction("columnPinChange", this.pin, this.pin ? "pin" : "unpin", { columnKey: this.key });
3928
3970
  };
3971
+ setPin(e) {
3972
+ this.isLeaf ? this._pin = yn(e) : this.columns.forEach((t) => t.setPin(e)), this.grid.pinColumn(this.uniqueKey, e);
3973
+ }
3929
3974
  toggleGrouping = () => {
3930
3975
  this.grid.toggleGrouping(this.key);
3931
3976
  };
@@ -3939,7 +3984,7 @@ var _n = 1e3, vn = class {
3939
3984
  toggleVisibility = () => {
3940
3985
  this.grid.toggleColumnVisibility(this.key);
3941
3986
  };
3942
- }, yn = class {
3987
+ }, Sn = class {
3943
3988
  grid;
3944
3989
  constructor(e) {
3945
3990
  this.grid = e;
@@ -3992,26 +4037,25 @@ var _n = 1e3, vn = class {
3992
4037
  });
3993
4038
  };
3994
4039
  setAll = (e, t = this.entries) => {
3995
- t.forEach((t) => {
3996
- t.visible !== e && t.column.toggleVisibility();
3997
- });
4040
+ let n = t.filter((t) => t.visible !== e);
4041
+ n.length !== 0 && (this.grid.quietly(() => n.forEach((e) => e.column.toggleVisibility())), this.grid.reportInteraction("columnVisibilityChange", e, e ? "show-all" : "hide-all", { columnKeys: n.map((e) => e.column.key) }));
3998
4042
  };
3999
4043
  };
4000
4044
  //#endregion
4001
4045
  //#region src/utils/array/lazyList.ts
4002
- function bn(e, t) {
4046
+ function Cn(e, t) {
4003
4047
  return new Proxy([], {
4004
4048
  get(n, r, i) {
4005
4049
  if (r === "length") return e;
4006
- let a = xn(r, e);
4050
+ let a = wn(r, e);
4007
4051
  return a === void 0 ? Reflect.get(n, r, i) : t(a);
4008
4052
  },
4009
4053
  has(t, n) {
4010
- return xn(n, e) !== void 0 || Reflect.has(t, n);
4054
+ return wn(n, e) !== void 0 || Reflect.has(t, n);
4011
4055
  },
4012
4056
  getOwnPropertyDescriptor(n, r) {
4013
- return xn(r, e) === void 0 ? Reflect.getOwnPropertyDescriptor(n, r) : {
4014
- value: t(xn(r, e)),
4057
+ return wn(r, e) === void 0 ? Reflect.getOwnPropertyDescriptor(n, r) : {
4058
+ value: t(wn(r, e)),
4015
4059
  writable: !0,
4016
4060
  enumerable: !0,
4017
4061
  configurable: !0
@@ -4019,7 +4063,7 @@ function bn(e, t) {
4019
4063
  }
4020
4064
  });
4021
4065
  }
4022
- function xn(e, t) {
4066
+ function wn(e, t) {
4023
4067
  if (typeof e != "string") return;
4024
4068
  let n = Number(e);
4025
4069
  return Number.isInteger(n) && n >= 0 && n < t ? n : void 0;
@@ -4150,7 +4194,7 @@ var $ = class e {
4150
4194
  }), this.source.changed());
4151
4195
  });
4152
4196
  }
4153
- }, Sn = class extends it {
4197
+ }, Tn = class extends st {
4154
4198
  level;
4155
4199
  constructor(e, t, n, r) {
4156
4200
  super(e, n, [], r, ""), this.level = t;
@@ -4172,7 +4216,7 @@ var $ = class e {
4172
4216
  return [...this.level.groupKeys, this.groupValue];
4173
4217
  }
4174
4218
  get key() {
4175
- return this.placeholder ? `${this.level.placeholderKey}-group-${this.rowIndex}` : Cn(this.groupKeys);
4219
+ return this.placeholder ? `${this.level.placeholderKey}-group-${this.rowIndex}` : En(this.groupKeys);
4176
4220
  }
4177
4221
  get depth() {
4178
4222
  return this.level.depth;
@@ -4208,21 +4252,21 @@ var $ = class e {
4208
4252
  this.placeholder || this.grid.toggleGroupRow(this.key);
4209
4253
  }
4210
4254
  };
4211
- function Cn(e) {
4255
+ function En(e) {
4212
4256
  return `rb-group:${$.keyOf(e)}`;
4213
4257
  }
4214
4258
  //#endregion
4215
4259
  //#region src/components/dataGrid/models/sourceRowModel.ts
4216
- var wn = {}, Tn = class extends U {
4260
+ var Dn = {}, On = class extends U {
4217
4261
  sourceLevel;
4218
4262
  constructor(e, t, n) {
4219
- super(e, wn, n), this.sourceLevel = t;
4263
+ super(e, Dn, n), this.sourceLevel = t;
4220
4264
  }
4221
4265
  get row() {
4222
4266
  return this.sourceLevel.rowAt(this.rowIndex);
4223
4267
  }
4224
4268
  get data() {
4225
- return this.row ?? wn;
4269
+ return this.row ?? Dn;
4226
4270
  }
4227
4271
  get placeholder() {
4228
4272
  return this.row === void 0;
@@ -4240,7 +4284,7 @@ var wn = {}, Tn = class extends U {
4240
4284
  get selected() {
4241
4285
  return !this.placeholder && super.selected;
4242
4286
  }
4243
- }, En = class extends Tn {
4287
+ }, kn = class extends On {
4244
4288
  isTreeRow = !0;
4245
4289
  get level() {
4246
4290
  return this.sourceLevel.depth;
@@ -4260,7 +4304,7 @@ var wn = {}, Tn = class extends U {
4260
4304
  toggleTree = () => {
4261
4305
  this.hasChildren && this.grid.tree.toggle(this.key, this.level);
4262
4306
  };
4263
- }, Dn = 100, On = 40, kn = class {
4307
+ }, An = 100, jn = 40, Mn = class {
4264
4308
  grid;
4265
4309
  constructor(e) {
4266
4310
  this.grid = e;
@@ -4286,11 +4330,11 @@ var wn = {}, Tn = class extends U {
4286
4330
  }
4287
4331
  get blockSize() {
4288
4332
  let e = this.config?.blockSize;
4289
- return e && e > 0 ? Math.floor(e) : this.grid.isPaginated ? this.grid.pageSize : Dn;
4333
+ return e && e > 0 ? Math.floor(e) : this.grid.isPaginated ? this.grid.pageSize : An;
4290
4334
  }
4291
4335
  get maxBlocks() {
4292
4336
  let e = this.config?.maxBlocks;
4293
- return e && e > 0 ? Math.floor(e) : On;
4337
+ return e && e > 0 ? Math.floor(e) : jn;
4294
4338
  }
4295
4339
  get queryVersion() {
4296
4340
  return this._query;
@@ -4345,7 +4389,7 @@ var wn = {}, Tn = class extends U {
4345
4389
  return e.loadedBlocks().forEach(({ index: a, rows: o }) => {
4346
4390
  o.forEach((o, s) => {
4347
4391
  let c = [...e.path, o[r]];
4348
- if (!t.has(Cn(c))) return;
4392
+ if (!t.has(En(c))) return;
4349
4393
  let l = a * n + s;
4350
4394
  i.push({
4351
4395
  rowIndex: l,
@@ -4399,20 +4443,20 @@ var wn = {}, Tn = class extends U {
4399
4443
  listLength = -1;
4400
4444
  rowList() {
4401
4445
  let { start: e } = this.visibleRange();
4402
- return this.listLength = this.visibleLength(), bn(this.listLength, (t) => this.rowModelAt(e + t));
4446
+ return this.listLength = this.visibleLength(), Cn(this.listLength, (t) => this.rowModelAt(e + t));
4403
4447
  }
4404
4448
  flatRowList(e) {
4405
4449
  let t = this.detailPositions();
4406
- return t.length === 0 ? e : bn(e.length + t.length, (n) => {
4407
- let r = jn(t, n);
4450
+ return t.length === 0 ? e : Cn(e.length + t.length, (n) => {
4451
+ let r = Pn(t, n);
4408
4452
  return t[r] === n ? new H(this.grid, e[n - r - 1]) : e[n - r];
4409
4453
  });
4410
4454
  }
4411
4455
  rowOffsets(e) {
4412
4456
  let { rowHeight: t } = this.grid, n = this.detailPositions(), r = [0];
4413
4457
  return n.forEach((t, n) => r.push(r[n] + e[t].heightForOffset)), {
4414
- offsets: bn(e.length, (e) => {
4415
- let i = jn(n, e);
4458
+ offsets: Cn(e.length, (e) => {
4459
+ let i = Pn(n, e);
4416
4460
  return (e - i) * t + r[i];
4417
4461
  }),
4418
4462
  totalHeight: (e.length - n.length) * t + r[n.length]
@@ -4441,7 +4485,7 @@ var wn = {}, Tn = class extends U {
4441
4485
  let i = this.levels.get(r);
4442
4486
  !i || i.isGroupLevel || i.loadedBlocks().forEach(({ index: r, rows: i }) => {
4443
4487
  i.forEach((i, a) => {
4444
- let o = An(n, r * t + a);
4488
+ let o = Nn(n, r * t + a);
4445
4489
  o !== void 0 && e(o, i);
4446
4490
  });
4447
4491
  });
@@ -4449,11 +4493,11 @@ var wn = {}, Tn = class extends U {
4449
4493
  }
4450
4494
  rowModelAt(e) {
4451
4495
  let t = this.segmentAt(e);
4452
- if (!t) return new Tn(this.grid, this.root, e);
4496
+ if (!t) return new On(this.grid, this.root, e);
4453
4497
  let { level: n } = t, r = t.levelStart + (e - t.start), i = this.models.get(n.key);
4454
4498
  i || this.models.set(n.key, i = /* @__PURE__ */ new Map());
4455
4499
  let a = i.get(r);
4456
- return a || (a = n.isGroupLevel ? new Sn(this.grid, n, this.groupColumnAt(n.depth), r) : this.isTree ? new En(this.grid, n, r) : new Tn(this.grid, n, r), i.set(r, a)), a;
4500
+ return a || (a = n.isGroupLevel ? new Tn(this.grid, n, this.groupColumnAt(n.depth), r) : this.isTree ? new kn(this.grid, n, r) : new On(this.grid, n, r), i.set(r, a)), a;
4457
4501
  }
4458
4502
  groupColumnAt(e) {
4459
4503
  return G.findOrThrow(this.grid.columns.value.leafs, (t) => t.key === this.groupBy[e]);
@@ -4505,7 +4549,7 @@ var wn = {}, Tn = class extends U {
4505
4549
  let e = !1;
4506
4550
  this.levels.forEach((t) => {
4507
4551
  t.failedBlocks().length !== 0 && (t.retry(), e = !0);
4508
- }), e && this.changed();
4552
+ }), e && (this.changed(), this.grid.reportInteraction("retry", void 0, "retry"));
4509
4553
  };
4510
4554
  invalidate() {
4511
4555
  if (!this.enabled) return;
@@ -4542,10 +4586,10 @@ var wn = {}, Tn = class extends U {
4542
4586
  this._segments = void 0, this._byLevel = void 0, this.listLength !== this.visibleLength() && this.grid.rows.clear(), this.grid.flatRows.clear(), this.grid.notify();
4543
4587
  }
4544
4588
  };
4545
- function An(e, t) {
4589
+ function Nn(e, t) {
4546
4590
  for (let n of e) if (t >= n.levelStart && t < n.levelStart + n.length) return n.start + (t - n.levelStart);
4547
4591
  }
4548
- function jn(e, t) {
4592
+ function Pn(e, t) {
4549
4593
  let n = 0, r = e.length;
4550
4594
  for (; n < r;) {
4551
4595
  let i = n + r >>> 1;
@@ -4555,7 +4599,7 @@ function jn(e, t) {
4555
4599
  }
4556
4600
  //#endregion
4557
4601
  //#region src/components/dataGrid/models/exportModel.ts
4558
- var Mn = 7, Nn = class {
4602
+ var Fn = 7, In = class {
4559
4603
  grid;
4560
4604
  constructor(e) {
4561
4605
  this.grid = e;
@@ -4569,7 +4613,7 @@ var Mn = 7, Nn = class {
4569
4613
  }
4570
4614
  width(e) {
4571
4615
  let t = e.inlineWidth ?? this.grid.DEFAULT_COLUMN_WIDTH_PX;
4572
- return Math.min(80, Math.max(6, Math.round(t / Mn * 10) / 10));
4616
+ return Math.min(80, Math.max(6, Math.round(t / Fn * 10) / 10));
4573
4617
  }
4574
4618
  value(e, t) {
4575
4619
  let { exportValue: n } = e.def, r = n ? n(t) : t[e.key];
@@ -4577,7 +4621,7 @@ var Mn = 7, Nn = class {
4577
4621
  }
4578
4622
  aggregateOf(e, t) {
4579
4623
  let n = e.aggregate;
4580
- return n ? et(n, t.map((t) => this.value(e, t)), t) : null;
4624
+ return n ? rt(n, t.map((t) => this.value(e, t)), t) : null;
4581
4625
  }
4582
4626
  table(e = {}) {
4583
4627
  let t = this.columns(e.columns), n = e.groups ?? !0, r = [], i = (e, a, o) => {
@@ -4641,7 +4685,7 @@ var Mn = 7, Nn = class {
4641
4685
  let { title: t } = this.grid.props.def, n = typeof t == "string" && t.trim() ? t.trim() : this.grid.localeText.exportFileName;
4642
4686
  return e.fileName?.trim() || n;
4643
4687
  }
4644
- }, Pn = class {
4688
+ }, Ln = class {
4645
4689
  grid;
4646
4690
  constructor(e) {
4647
4691
  this.grid = e;
@@ -4663,7 +4707,7 @@ var Mn = 7, Nn = class {
4663
4707
  }
4664
4708
  setGlobalFilter = (e) => this.grid.setGlobalFilter(e);
4665
4709
  clearAllFilters = () => this.grid.clearAllFilters();
4666
- }, Fn = class {
4710
+ }, Rn = class {
4667
4711
  grid;
4668
4712
  constructor(e) {
4669
4713
  this.grid = e;
@@ -4759,14 +4803,14 @@ var Mn = 7, Nn = class {
4759
4803
  this._limit = {
4760
4804
  query: this.query,
4761
4805
  count: this.count + this.batch
4762
- }, this.grid.notify();
4806
+ }, this.grid.notify(), this.grid.reportInteraction("showMore", this._limit.count, "more", { batch: this.batch });
4763
4807
  };
4764
4808
  _selecting = !1;
4765
4809
  get selecting() {
4766
4810
  return !!this.grid.props.def.rowSelection && this._selecting;
4767
4811
  }
4768
4812
  setSelecting = (e) => {
4769
- this._selecting !== e && (this._selecting = e, this.grid.notify());
4813
+ this._selecting !== e && (this._selecting = e, this.grid.notify(), this.grid.reportInteraction("selectModeChange", e, e ? "enter" : "exit"));
4770
4814
  };
4771
4815
  checkboxId(e) {
4772
4816
  return `${this.grid.identifier}-pick-${encodeURIComponent(String(e))}`;
@@ -4776,7 +4820,7 @@ var Mn = 7, Nn = class {
4776
4820
  return this._sheet;
4777
4821
  }
4778
4822
  openSheet = (e) => {
4779
- this._sheet !== e && (this._sheet = e, this.grid.notify());
4823
+ this._sheet !== e && (this._sheet = e, this.grid.notify(), this.grid.reportInteraction("sheetChange", e, e ? "open" : "close"));
4780
4824
  };
4781
4825
  get sortableColumns() {
4782
4826
  return this.grid.columns.value.visibleLeafs.filter((e) => e.isData && e.sortable);
@@ -4802,23 +4846,23 @@ var Mn = 7, Nn = class {
4802
4846
  describe(e, t) {
4803
4847
  switch (t.type) {
4804
4848
  case "text": return `“${t.value}”`;
4805
- case "number": return t.operator === "between" ? `${t.value}–${t.valueTo ?? ""}` : `${Ln[t.operator]} ${t.value}`;
4849
+ case "number": return t.operator === "between" ? `${t.value}–${t.valueTo ?? ""}` : `${Bn[t.operator]} ${t.value}`;
4806
4850
  case "multiselect": {
4807
4851
  let n = e.filterOptions, r = t.values.map((e) => e === null ? this.grid.localeText.filterEmptyValue : n.find((t) => t.value === e)?.label ?? String(e)), i = r.slice(0, 2).join(", ");
4808
4852
  return r.length > 2 ? `${i} +${r.length - 2}` : i;
4809
4853
  }
4810
- case "date": return t.operator === "between" ? we()?.describeDay(t.value, t.valueTo ?? t.value) ?? `${t.value}–${t.valueTo ?? ""}` : `${Rn[t.operator]} ${we()?.describeDay(t.value) ?? t.value}`;
4854
+ case "date": return t.operator === "between" ? Ee()?.describeDay(t.value, t.valueTo ?? t.value) ?? `${t.value}–${t.valueTo ?? ""}` : `${Vn[t.operator]} ${Ee()?.describeDay(t.value) ?? t.value}`;
4811
4855
  }
4812
4856
  }
4813
4857
  _record = null;
4814
4858
  get record() {
4815
4859
  if (!this._record) return;
4816
4860
  let e = this.grid.flatRows.value, { index: t, key: n } = this._record;
4817
- if (zn(e[t]) && e[t].key === n) return e[t];
4861
+ if (Hn(e[t]) && e[t].key === n) return e[t];
4818
4862
  let r = -1;
4819
- for (let t = 0; t < Math.min(e.length, In) && r === -1; t++) {
4863
+ for (let t = 0; t < Math.min(e.length, zn) && r === -1; t++) {
4820
4864
  let i = e[t];
4821
- zn(i) && i.key === n && (r = t);
4865
+ Hn(i) && i.key === n && (r = t);
4822
4866
  }
4823
4867
  if (r !== -1) return this._record = {
4824
4868
  index: r,
@@ -4832,17 +4876,17 @@ var Mn = 7, Nn = class {
4832
4876
  this._record = {
4833
4877
  index: t,
4834
4878
  key: e.key
4835
- }, this.grid.notify();
4879
+ }, this.grid.notify(), this.grid.reportInteraction("recordChange", e.key, "open", { index: t });
4836
4880
  };
4837
4881
  closeRecord = () => {
4838
- this._record && (this._record = null, this.grid.notify());
4882
+ this._record && (this._record = null, this.grid.notify(), this.grid.reportInteraction("recordChange", null, "close"));
4839
4883
  };
4840
4884
  neighbour(e) {
4841
4885
  if (!this.record || !this._record) return -1;
4842
4886
  let t = this.grid.flatRows.value;
4843
4887
  for (let n = this._record.index + e; n >= 0 && n < t.length; n += e) {
4844
4888
  let e = t[n];
4845
- if (zn(e) && !e.placeholder) return n;
4889
+ if (Hn(e) && !e.placeholder) return n;
4846
4890
  }
4847
4891
  return -1;
4848
4892
  }
@@ -4857,7 +4901,7 @@ var Mn = 7, Nn = class {
4857
4901
  t !== -1 && (this._record = {
4858
4902
  index: t,
4859
4903
  key: this.grid.flatRows.value[t].key
4860
- }, this._limit && t >= this._limit.count && (this._limit = {
4904
+ }, this.grid.reportInteraction("recordChange", this._record.key, e === 1 ? "next" : "previous", { index: t }), this._limit && t >= this._limit.count && (this._limit = {
4861
4905
  query: this.query,
4862
4906
  count: t + 1
4863
4907
  }), this.grid.notify());
@@ -4869,30 +4913,30 @@ var Mn = 7, Nn = class {
4869
4913
  total: this.grid.totalRowCount
4870
4914
  };
4871
4915
  let e = this.grid.flatRows.value, t = 0, n = 0;
4872
- for (let r = 0; r < e.length; r++) zn(e[r]) && (n++, r <= this._record.index && t++);
4916
+ for (let r = 0; r < e.length; r++) Hn(e[r]) && (n++, r <= this._record.index && t++);
4873
4917
  return {
4874
4918
  position: t,
4875
4919
  total: n
4876
4920
  };
4877
4921
  }
4878
- }, In = 1e4, Ln = {
4922
+ }, zn = 1e4, Bn = {
4879
4923
  eq: "=",
4880
4924
  ne: "≠",
4881
4925
  gt: ">",
4882
4926
  gte: "≥",
4883
4927
  lt: "<",
4884
4928
  lte: "≤"
4885
- }, Rn = {
4929
+ }, Vn = {
4886
4930
  on: "=",
4887
4931
  before: "<",
4888
4932
  after: ">"
4889
4933
  };
4890
- function zn(e) {
4934
+ function Hn(e) {
4891
4935
  return !!e && e.kind === "row";
4892
4936
  }
4893
4937
  //#endregion
4894
4938
  //#region src/components/dataGrid/models/localeText.ts
4895
- var Bn = {
4939
+ var Un = {
4896
4940
  searchPlaceholder: "Search...",
4897
4941
  columnsMenu: "Columns",
4898
4942
  columnsMenuLabel: (e, t) => `Columns, ${e} of ${t} shown`,
@@ -4989,7 +5033,7 @@ var Bn = {
4989
5033
  selectedRows: (e) => `${e} selected`,
4990
5034
  selectAll: "Select all",
4991
5035
  selectionAnnouncement: (e, t) => e === 0 ? "No rows selected" : `${e} of ${t} rows selected`
4992
- }, Vn = class {
5036
+ }, Wn = class {
4993
5037
  grid;
4994
5038
  constructor(e) {
4995
5039
  this.grid = e;
@@ -5045,16 +5089,16 @@ var Bn = {
5045
5089
  let t = parseInt(e, 10);
5046
5090
  isNaN(t) || this.grid.changePage(Math.max(1, Math.min(t, this.totalPages)));
5047
5091
  };
5048
- }, Hn = /["\t\r\n]/;
5049
- function Un(e) {
5092
+ }, Gn = /["\t\r\n]/;
5093
+ function Kn(e) {
5050
5094
  if (e == null) return "";
5051
5095
  let t = e instanceof Date ? e.toISOString() : String(e);
5052
- return Hn.test(t) ? `"${t.split("\"").join("\"\"")}"` : t;
5096
+ return Gn.test(t) ? `"${t.split("\"").join("\"\"")}"` : t;
5053
5097
  }
5054
- function Wn(e) {
5055
- return e.map((e) => e.map(Un).join(" ")).join("\r\n");
5098
+ function qn(e) {
5099
+ return e.map((e) => e.map(Kn).join(" ")).join("\r\n");
5056
5100
  }
5057
- function Gn(e) {
5101
+ function Jn(e) {
5058
5102
  let t = [], n = [], r = "", i = !1;
5059
5103
  for (let a = 0; a < e.length; a++) {
5060
5104
  let o = e[a];
@@ -5062,10 +5106,10 @@ function Gn(e) {
5062
5106
  }
5063
5107
  return (r !== "" || n.length > 0) && (n.push(r), t.push(n)), t;
5064
5108
  }
5065
- function Kn(e, t) {
5109
+ function Yn(e, t) {
5066
5110
  return e?.row === t?.row && e?.column === t?.column;
5067
5111
  }
5068
- var qn = class {
5112
+ var Xn = class {
5069
5113
  grid;
5070
5114
  constructor(e) {
5071
5115
  this.grid = e;
@@ -5111,7 +5155,7 @@ var qn = class {
5111
5155
  row: e,
5112
5156
  column: t
5113
5157
  }, i = n && this._anchor ? this._anchor : r;
5114
- Kn(this._focus, r) && Kn(this._anchor, i) || (this._anchor = i, this._focus = r, this.grid.notifyRows(), this.emit(n ? "extend" : "select"));
5158
+ Yn(this._focus, r) && Yn(this._anchor, i) || (this._anchor = i, this._focus = r, this.grid.notifyRows(), this.emit(n ? "extend" : "select"));
5115
5159
  }
5116
5160
  syncCurrent(e, t) {
5117
5161
  this.isCurrent(e, t) || this.setCurrent(e, t);
@@ -5126,7 +5170,7 @@ var qn = class {
5126
5170
  this._dragging && this.setCurrent(e, t, !0);
5127
5171
  }
5128
5172
  endDrag = () => {
5129
- this._dragging && (this._dragging = !1, this.grid.notifyRows());
5173
+ this._dragging && (this._dragging = !1, this.grid.notifyRows(), this.reportBlock());
5130
5174
  };
5131
5175
  columnsOf(e = this.bounds) {
5132
5176
  return e ? this.grid.columns.value.visibleLeafs.slice(e.startColumn, e.endColumn + 1) : [];
@@ -5156,13 +5200,24 @@ var qn = class {
5156
5200
  let e = this.bounds;
5157
5201
  return e && this.rangeOf(e);
5158
5202
  }
5203
+ get block() {
5204
+ let e = this.bounds;
5205
+ return e && {
5206
+ startRow: e.startRow,
5207
+ endRow: e.endRow,
5208
+ columns: this.columnsOf(e).map((e) => e.key)
5209
+ };
5210
+ }
5159
5211
  emit(e) {
5160
- this.grid.props.onRangeChange?.(this.range, { reason: e });
5212
+ this.grid.props.onRangeChange?.(this.range, { reason: e }), e === "extend" && !this._dragging && this.reportBlock();
5213
+ }
5214
+ reportBlock() {
5215
+ this.enabled && this._anchor && !Yn(this._anchor, this._focus) && this.grid.reportInteraction("rangeChange", this.block, "extend");
5161
5216
  }
5162
5217
  onCopy = (e) => {
5163
5218
  if (!this._focus || !e.clipboardData) return;
5164
5219
  let t = e.currentTarget.ownerDocument.defaultView?.getSelection();
5165
- t && !t.isCollapsed || (e.clipboardData.setData("text/plain", Wn(this.values())), e.preventDefault());
5220
+ t && !t.isCollapsed || (e.clipboardData.setData("text/plain", qn(this.values())), e.preventDefault(), this.grid.reportInteraction("copy", this.block, "copy"));
5166
5221
  };
5167
5222
  pasteBounds(e, t) {
5168
5223
  let n = this.bounds;
@@ -5179,10 +5234,10 @@ var qn = class {
5179
5234
  if (!this._focus || !e.clipboardData || this.grid.edits.isOpen || !this.grid.edits.enabled) return;
5180
5235
  let t = e.clipboardData.getData("text/plain");
5181
5236
  if (!t) return;
5182
- let n = Gn(t), r = n.reduce((e, t) => Math.max(e, t.length), 0), i = this.pasteBounds(n.length, r);
5237
+ let n = Jn(t), r = n.reduce((e, t) => Math.max(e, t.length), 0), i = this.pasteBounds(n.length, r);
5183
5238
  i && (e.preventDefault(), this.grid.edits.paste(i, (e, t) => n[e % n.length][t % r] ?? ""));
5184
5239
  };
5185
- }, Jn = class extends U {
5240
+ }, Zn = class extends U {
5186
5241
  node;
5187
5242
  level;
5188
5243
  position;
@@ -5233,10 +5288,10 @@ var qn = class {
5233
5288
  };
5234
5289
  //#endregion
5235
5290
  //#region src/components/dataGrid/models/treeModel.ts
5236
- function Yn(e) {
5291
+ function Qn(e) {
5237
5292
  return JSON.stringify(e);
5238
5293
  }
5239
- var Xn = class {
5294
+ var $n = class {
5240
5295
  grid;
5241
5296
  constructor(e) {
5242
5297
  this.grid = e;
@@ -5290,9 +5345,9 @@ var Xn = class {
5290
5345
  data: e,
5291
5346
  children: []
5292
5347
  };
5293
- n.set(Yn(r), i);
5348
+ n.set(Qn(r), i);
5294
5349
  let a;
5295
- for (let e = r.length - 1; e > 0 && !a; e--) a = n.get(Yn(r.slice(0, e)));
5350
+ for (let e = r.length - 1; e > 0 && !a; e--) a = n.get(Qn(r.slice(0, e)));
5296
5351
  (a ? a.children : t).push(i);
5297
5352
  }), t;
5298
5353
  }
@@ -5338,7 +5393,7 @@ var Xn = class {
5338
5393
  }
5339
5394
  rowList() {
5340
5395
  let e = 0, t = (n, r, i) => n.map((a, o) => {
5341
- let s = new Jn(this.grid, a, e++, r, o, n.length, i);
5396
+ let s = new Zn(this.grid, a, e++, r, o, n.length, i);
5342
5397
  return s.treeExpanded && (s.children = t(a.children, r + 1, s)), s;
5343
5398
  });
5344
5399
  return t(this.nodes.value, 0);
@@ -5378,10 +5433,12 @@ var Xn = class {
5378
5433
  }
5379
5434
  toggle = (e, t) => {
5380
5435
  let n = !this.isExpanded(e, t);
5381
- n ? (this._opened.add(e), this._closed.delete(e)) : (this._closed.add(e), this._opened.delete(e)), this.grid.treeExpansionChanged(), this.grid.props.onExpandedTreeKeysChange?.(this.expandedKeys(), { reason: n ? "expand" : "collapse" }), this.grid.notify();
5436
+ n ? (this._opened.add(e), this._closed.delete(e)) : (this._closed.add(e), this._opened.delete(e)), this.grid.treeExpansionChanged();
5437
+ let r = this.expandedKeys();
5438
+ this.grid.fire("expandedTreeKeysChange", r, n ? "expand" : "collapse", { details: { rowKey: e } }), this.grid.notify();
5382
5439
  };
5383
- }, Zn = {};
5384
- function Qn(e) {
5440
+ }, er = {};
5441
+ function tr(e) {
5385
5442
  if (typeof e == "string" && /^\d{4}-\d{2}-\d{2}$/.test(e)) return e;
5386
5443
  if (!(e instanceof Date) && typeof e != "string" && typeof e != "number") return null;
5387
5444
  let t = e instanceof Date ? e : new Date(e);
@@ -5389,7 +5446,7 @@ function Qn(e) {
5389
5446
  let n = (e) => String(e).padStart(2, "0");
5390
5447
  return `${String(t.getFullYear()).padStart(4, "0")}-${n(t.getMonth() + 1)}-${n(t.getDate())}`;
5391
5448
  }
5392
- var $n = class t {
5449
+ var nr = class e {
5393
5450
  props;
5394
5451
  constructor(e, t) {
5395
5452
  this.props = e, t && this.listeners.add(t);
@@ -5420,9 +5477,9 @@ var $n = class t {
5420
5477
  get headerVersion() {
5421
5478
  return `${this._epoch}:${this._selectionVersion}`;
5422
5479
  }
5423
- setProps(e) {
5480
+ setProps(t) {
5424
5481
  let n = this.props;
5425
- n !== e && (t.drawnPropsChanged(n, e) && this._epoch++, this.props = e, n.def !== e.def && this.sourceColumns.clear(), (n.data !== e.data || n.def !== e.def || n.globalFilterValue !== e.globalFilterValue || n.columnFilters !== e.columnFilters || n.filters !== e.filters || n.expandedRowKeys !== e.expandedRowKeys || n.expandedTreeKeys !== e.expandedTreeKeys || n.page !== e.page || n.pageSize !== e.pageSize) && this.rows.clear(), (n.globalFilterValue !== e.globalFilterValue || n.columnFilters !== e.columnFilters || n.filters !== e.filters) && this.leaveSelectionView(), (n.data !== e.data || n.def !== e.def || n.globalFilterValue !== e.globalFilterValue || n.columnFilters !== e.columnFilters || n.filters !== e.filters) && this.tree.nodes.clear());
5482
+ n !== t && (e.drawnPropsChanged(n, t) && this._epoch++, this.props = t, n.def !== t.def && this.sourceColumns.clear(), (n.data !== t.data || n.def !== t.def || n.globalFilterValue !== t.globalFilterValue || n.columnFilters !== t.columnFilters || n.filters !== t.filters || n.expandedRowKeys !== t.expandedRowKeys || n.expandedTreeKeys !== t.expandedTreeKeys || n.page !== t.page || n.pageSize !== t.pageSize) && this.rows.clear(), (n.globalFilterValue !== t.globalFilterValue || n.columnFilters !== t.columnFilters || n.filters !== t.filters) && this.leaveSelectionView(), (n.data !== t.data || n.def !== t.def || n.globalFilterValue !== t.globalFilterValue || n.columnFilters !== t.columnFilters || n.filters !== t.filters) && this.tree.nodes.clear());
5426
5483
  }
5427
5484
  get data() {
5428
5485
  return this.props.data ?? [];
@@ -5457,7 +5514,7 @@ var $n = class t {
5457
5514
  let e = this.props.def.localeText, t = this._localeText;
5458
5515
  if (t && t.from === e) return t.text;
5459
5516
  let n = {
5460
- ...Bn,
5517
+ ...Un,
5461
5518
  ...e
5462
5519
  };
5463
5520
  return this._localeText = {
@@ -5470,17 +5527,17 @@ var $n = class t {
5470
5527
  if (this.groupColumns.size > 0 && t.push(new Q({ key: K }, this)), t.push(...e.columns.map((e) => new Q(e, this))), e.rowSelection) {
5471
5528
  let n = typeof e.rowSelection == "object" && e.rowSelection.pinned ? "START" : void 0;
5472
5529
  t.unshift(new Q({
5473
- key: Ke,
5530
+ key: Ye,
5474
5531
  pin: n,
5475
5532
  width: 50,
5476
5533
  align: "center",
5477
- Cell: hn
5534
+ Cell: vn
5478
5535
  }, this));
5479
5536
  }
5480
5537
  if (e.showRowNumber) {
5481
5538
  let n, r = 70;
5482
5539
  typeof e.showRowNumber == "object" && (e.showRowNumber.pinned && (n = "START"), r = e.showRowNumber.width ?? 70), t.unshift(new Q({
5483
- key: Ge,
5540
+ key: Je,
5484
5541
  pin: n,
5485
5542
  width: r,
5486
5543
  align: "end"
@@ -5489,12 +5546,12 @@ var $n = class t {
5489
5546
  if (e.rowDetail) {
5490
5547
  let n = e.rowDetail.pinned ? "START" : void 0, r = e.rowDetail.expandColumnWidth ?? 50, i = e.rowDetail.expandColumnHeader ?? "";
5491
5548
  t.unshift(new Q({
5492
- key: qe,
5549
+ key: Xe,
5493
5550
  header: i,
5494
5551
  pin: n,
5495
5552
  width: r,
5496
5553
  align: "center",
5497
- Cell: mn
5554
+ Cell: _n
5498
5555
  }, this));
5499
5556
  }
5500
5557
  return t;
@@ -5513,10 +5570,10 @@ var $n = class t {
5513
5570
  leafs: i,
5514
5571
  visibleLeafs: a,
5515
5572
  userVisibleLeafs: a.filter((e) => ![
5516
- Ge,
5517
- Ke,
5573
+ Je,
5574
+ Ye,
5518
5575
  K,
5519
- qe
5576
+ Xe
5520
5577
  ].includes(e.key)),
5521
5578
  maxDeath: G.maxBy(r, (e) => e.death) + 1
5522
5579
  };
@@ -5553,7 +5610,7 @@ var $n = class t {
5553
5610
  let t = this.globalFilterValue.trim();
5554
5611
  return !t || this.globalFilterColumns.value.some((n) => {
5555
5612
  let r = e[n];
5556
- return r != null && pn(t, String(r));
5613
+ return r != null && gn(t, String(r));
5557
5614
  });
5558
5615
  }
5559
5616
  matchesColumnFilters(e) {
@@ -5565,7 +5622,7 @@ var $n = class t {
5565
5622
  }
5566
5623
  matchesFilter(e, t) {
5567
5624
  switch (t.type) {
5568
- case "text": return !t.value.trim() || e != null && pn(t.value, String(e));
5625
+ case "text": return !t.value.trim() || e != null && gn(t.value, String(e));
5569
5626
  case "number": {
5570
5627
  if (e == null) return !1;
5571
5628
  let n = typeof e == "number" ? e : parseFloat(String(e));
@@ -5583,7 +5640,7 @@ var $n = class t {
5583
5640
  }
5584
5641
  case "date": {
5585
5642
  if (!t.value) return !0;
5586
- let n = Qn(e);
5643
+ let n = tr(e);
5587
5644
  if (!n) return !1;
5588
5645
  switch (t.operator) {
5589
5646
  case "on": return n === t.value;
@@ -5605,6 +5662,30 @@ var $n = class t {
5605
5662
  }
5606
5663
  return this.hasRowFilters ? this.data.filter((e) => this.rowMatchesFilters(e)) : this.data;
5607
5664
  }
5665
+ reportInteraction(e, t, n, r, a) {
5666
+ this._batching || i({
5667
+ component: "datagrid",
5668
+ type: e,
5669
+ reason: n,
5670
+ value: t,
5671
+ details: r,
5672
+ content: a,
5673
+ target: this._sizingElement ?? void 0
5674
+ });
5675
+ }
5676
+ fire(e, t, n, r = {}) {
5677
+ let i = this.props[`on${e.charAt(0).toUpperCase()}${e.slice(1)}`];
5678
+ i?.(t, { reason: n }), r && this.reportInteraction(e, t, n, r.details, r.content);
5679
+ }
5680
+ _batching = !1;
5681
+ quietly(e) {
5682
+ this._batching = !0;
5683
+ try {
5684
+ e();
5685
+ } finally {
5686
+ this._batching = !1;
5687
+ }
5688
+ }
5608
5689
  fireServerStateChange(e, t) {
5609
5690
  this.props.onServerStateChange?.({
5610
5691
  page: t?.page ?? this.page,
@@ -5616,34 +5697,41 @@ var $n = class t {
5616
5697
  }, { reason: e });
5617
5698
  }
5618
5699
  firePaginationChange(e, t, n) {
5619
- this.props.onPaginationChange?.({
5700
+ this.fire("paginationChange", {
5620
5701
  page: e,
5621
5702
  pageSize: t
5622
- }, { reason: n }), this.props.onPageChange?.(e, t);
5703
+ }, n, (n === "page" || n === "page-size") && {}), this.props.onPageChange?.(e, t);
5623
5704
  }
5624
5705
  resetToFirstPage(e) {
5625
5706
  return !this.isPaginated || this.page === 1 ? this.page : (this._page = 1, this.firePaginationChange(1, this.pageSize, e), 1);
5626
5707
  }
5627
5708
  setGlobalFilter = (e) => {
5628
- let t = e === "" ? "clear" : "filter";
5629
- this._globalFilterValue = e, this.leaveSelectionView(), this.props.onGlobalFilterChange?.(e, { reason: t });
5630
- let n = this.resetToFirstPage(t);
5709
+ let t = e === "" ? "clear" : "filter", n = e !== this.globalFilterValue;
5710
+ this._globalFilterValue = e, this.leaveSelectionView(), this.fire("globalFilterChange", e, t, n && { content: ["value"] });
5711
+ let r = this.resetToFirstPage(t);
5631
5712
  this.fireServerStateChange(t, {
5632
5713
  globalFilterValue: e,
5633
- page: n
5714
+ page: r
5634
5715
  }), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
5635
5716
  };
5636
5717
  setColumnFilter = (e, t) => {
5637
- let n = { ...this.columnFilters }, r = t === void 0 ? "clear" : "filter";
5638
- t === void 0 ? delete n[e] : n[e] = t, this._columnFilters = n, this.leaveSelectionView(), this.props.onColumnFiltersChange?.(n, { reason: r });
5639
- let i = this.resetToFirstPage(r);
5718
+ let n = { ...this.columnFilters }, r = t === void 0 ? "clear" : "filter", i = t !== void 0 || e in n;
5719
+ t === void 0 ? delete n[e] : n[e] = t, this._columnFilters = n, this.leaveSelectionView(), this.fire("columnFiltersChange", n, r, i && {
5720
+ details: {
5721
+ columnKey: e,
5722
+ filter: t
5723
+ },
5724
+ content: ["value", "filter"]
5725
+ });
5726
+ let a = this.resetToFirstPage(r);
5640
5727
  this.fireServerStateChange(r, {
5641
5728
  columnFilters: n,
5642
- page: i
5729
+ page: a
5643
5730
  }), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
5644
5731
  };
5645
5732
  clearColumnFilters = () => {
5646
- this._columnFilters = {}, this.leaveSelectionView(), this.props.onColumnFiltersChange?.({}, { reason: "clear" }), this.fireServerStateChange("clear", { columnFilters: {} }), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
5733
+ let e = Object.keys(this.columnFilters).length > 0;
5734
+ this._columnFilters = {}, this.leaveSelectionView(), this.fire("columnFiltersChange", {}, "clear", e && {}), this.fireServerStateChange("clear", { columnFilters: {} }), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
5647
5735
  };
5648
5736
  clearAllFilters = () => {
5649
5737
  this.setGlobalFilter(""), this.clearColumnFilters();
@@ -5686,7 +5774,7 @@ var $n = class t {
5686
5774
  return this._sortColumn === "grouping-cell" && (e = G.sortBy(e, (e) => e[i], this._sortDirection)), G.groupBy(e, (e) => e[i]).map((e) => {
5687
5775
  let i;
5688
5776
  i = n.size > 0 ? t(e.values, new Set(n), r + 1) : e.values.map((e, t) => new U(this, e, r + 1 + t));
5689
- let o = new it(this, a, i, r, e.key);
5777
+ let o = new st(this, a, i, r, e.key);
5690
5778
  return r += 1, o.expanded && (r += i.length), o;
5691
5779
  });
5692
5780
  };
@@ -5736,7 +5824,7 @@ var $n = class t {
5736
5824
  e && Object.entries(this.sizes.value).forEach(([t, n]) => e.style.setProperty(t, n));
5737
5825
  };
5738
5826
  get isRtl() {
5739
- return e(this._sizingElement);
5827
+ return n(this._sizingElement);
5740
5828
  }
5741
5829
  setContainerWidth = (e) => {
5742
5830
  this._containerWidth !== e && (this._containerWidth = e, this.flexWidths.clear(), this.notify());
@@ -5774,7 +5862,7 @@ var $n = class t {
5774
5862
  let t = new Set(this.expandedDetailRows);
5775
5863
  t.has(e) ? t.delete(e) : t.add(e);
5776
5864
  let n = t.has(e);
5777
- this._revealDetailKey = n && this.props.def.rowDetail?.scrollIntoView !== !1 ? e : null, this._expandedDetailRows = t, this.props.onExpandedRowKeysChange?.(Array.from(t), { reason: n ? "expand" : "collapse" }), this.rows.clear(), this.notify();
5865
+ this._revealDetailKey = n && this.props.def.rowDetail?.scrollIntoView !== !1 ? e : null, this._expandedDetailRows = t, this.fire("expandedRowKeysChange", Array.from(t), n ? "expand" : "collapse", { details: { rowKey: e } }), this.rows.clear(), this.notify();
5778
5866
  };
5779
5867
  _page = 1;
5780
5868
  _pageSize;
@@ -5827,23 +5915,23 @@ var $n = class t {
5827
5915
  totalHeight: t
5828
5916
  };
5829
5917
  }, () => [this.flatRows]);
5830
- viewport = new ye(this);
5831
- columnVisibility = new yn(this);
5832
- filter = new Pn(this);
5833
- pagination = new Vn(this);
5834
- aggregation = new tt(this);
5835
- exporter = new Nn(this);
5836
- source = new kn(this);
5837
- tree = new Xn(this);
5838
- edits = new Re(this);
5839
- range = new qn(this);
5840
- list = new Fn(this);
5918
+ viewport = new xe(this);
5919
+ columnVisibility = new Sn(this);
5920
+ filter = new Ln(this);
5921
+ pagination = new Wn(this);
5922
+ aggregation = new it(this);
5923
+ exporter = new In(this);
5924
+ source = new Mn(this);
5925
+ tree = new $n(this);
5926
+ edits = new Ve(this);
5927
+ range = new Xn(this);
5928
+ list = new Rn(this);
5841
5929
  refresh = () => {
5842
5930
  this.edits.clearEdits(), this.source.invalidate();
5843
5931
  };
5844
5932
  get exportConfig() {
5845
5933
  let e = this.props.def.export;
5846
- if (e) return typeof e == "object" ? e : Zn;
5934
+ if (e) return typeof e == "object" ? e : er;
5847
5935
  }
5848
5936
  exportCsv = async (e = {}) => {
5849
5937
  let { downloadCsv: t } = await import("../gridExport.mjs");
@@ -5896,7 +5984,7 @@ var $n = class t {
5896
5984
  return !!this.props.def.rowSelection && !this.source.enabled && !this.isPaginated && !this.tree.isEager;
5897
5985
  }
5898
5986
  toggleSelectionView = () => {
5899
- this._selectionView = this._selectionView ? null : new Set(this.selectedRows), this.rows.clear(), this.notify();
5987
+ this._selectionView = this._selectionView ? null : new Set(this.selectedRows), this.reportInteraction("selectionViewChange", this._selectionView !== null, this._selectionView ? "show" : "hide"), this.rows.clear(), this.notify();
5900
5988
  };
5901
5989
  leaveSelectionView() {
5902
5990
  this._selectionView = null;
@@ -5937,7 +6025,7 @@ var $n = class t {
5937
6025
  columnKey: this._sortColumn,
5938
6026
  direction: this._sortDirection
5939
6027
  } : void 0;
5940
- this.props.onSortingChange?.(n, { reason: n ? "sort" : "clear" }), this.props.onSortChange?.(this._sortColumn, this._sortDirection);
6028
+ this.fire("sortingChange", n, n ? "sort" : "clear", { details: { columnKey: e } }), this.props.onSortChange?.(this._sortColumn, this._sortDirection);
5941
6029
  let r = this.resetToFirstPage("sort");
5942
6030
  this.fireServerStateChange("sort", {
5943
6031
  sortColumn: this._sortColumn,
@@ -5946,15 +6034,15 @@ var $n = class t {
5946
6034
  }), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
5947
6035
  };
5948
6036
  pinColumn = (e, t) => {
5949
- let n = gn(t), r = G.findOrThrow(this.columns.value.flat, (t) => t.uniqueKey === e);
6037
+ let n = yn(t), r = G.findOrThrow(this.columns.value.flat, (t) => t.uniqueKey === e);
5950
6038
  r.pin !== n && r.pinColumn(n), this.columns.clear(), this.notify();
5951
6039
  };
5952
6040
  toggleGrouping = (e) => {
5953
- this.groupColumns = new Set(this.groupColumns), this.hiddenColumns = new Set(this.hiddenColumns), this.groupColumns.has(e) ? (this.groupColumns.delete(e), this.hiddenColumns.delete(e)) : (this.groupColumns.add(e), this.hiddenColumns.add(e)), this.collapseGroups(), this.sourceColumns.clear(), this.notify();
6041
+ this.groupColumns = new Set(this.groupColumns), this.hiddenColumns = new Set(this.hiddenColumns), this.groupColumns.has(e) ? (this.groupColumns.delete(e), this.hiddenColumns.delete(e)) : (this.groupColumns.add(e), this.hiddenColumns.add(e)), this.reportInteraction("groupingChange", Array.from(this.groupColumns), this.groupColumns.has(e) ? "group" : "ungroup", { columnKey: e }), this.collapseGroups(), this.sourceColumns.clear(), this.notify();
5954
6042
  };
5955
6043
  unGroupAll = () => {
5956
6044
  let e = new Set(this.groupColumns);
5957
- this.groupColumns = /* @__PURE__ */ new Set(), this.hiddenColumns = new Set(Array.from(this.hiddenColumns).filter((t) => !e.has(t))), this.collapseGroups(), this.sourceColumns.clear(), this.notify();
6045
+ this.groupColumns = /* @__PURE__ */ new Set(), this.hiddenColumns = new Set(Array.from(this.hiddenColumns).filter((t) => !e.has(t))), this.reportInteraction("groupingChange", [], "clear"), this.collapseGroups(), this.sourceColumns.clear(), this.notify();
5958
6046
  };
5959
6047
  collapseGroups() {
5960
6048
  this.expandedGroupRow = /* @__PURE__ */ new Set(), this._collapsedGroupRow = /* @__PURE__ */ new Set(), this.source.expansionChanged(), this.source.invalidate();
@@ -5971,7 +6059,7 @@ var $n = class t {
5971
6059
  }
5972
6060
  _collapsedGroupRow = /* @__PURE__ */ new Set();
5973
6061
  toggleGroupRow = (e, t = this.expandedGroupRow.has(e)) => {
5974
- this._expansion++, this.expandedGroupRow = new Set(this.expandedGroupRow), this._collapsedGroupRow = new Set(this._collapsedGroupRow), t ? (this.expandedGroupRow.delete(e), this._collapsedGroupRow.add(e)) : (this.expandedGroupRow.add(e), this._collapsedGroupRow.delete(e)), this.source.expansionChanged(), this.rows.clear(), this.notify();
6062
+ this._expansion++, this.expandedGroupRow = new Set(this.expandedGroupRow), this._collapsedGroupRow = new Set(this._collapsedGroupRow), t ? (this.expandedGroupRow.delete(e), this._collapsedGroupRow.add(e)) : (this.expandedGroupRow.add(e), this._collapsedGroupRow.delete(e)), this.reportInteraction("groupExpandedChange", !t, t ? "collapse" : "expand", { groupRowKey: e }), this.source.expansionChanged(), this.rows.clear(), this.notify();
5975
6063
  };
5976
6064
  treeExpansionChanged() {
5977
6065
  this._expansion++, this.source.expansionChanged(), this.rows.clear();
@@ -5996,7 +6084,10 @@ var $n = class t {
5996
6084
  selectionChanged(e, t, n) {
5997
6085
  this._selectionVersion++, this.flatRows.clear(), this.notifyRows();
5998
6086
  let r = Array.from(this.selectedRows);
5999
- this.props.onSelectedRowKeysChange?.(r, { reason: n }), this.props.onSelectionChange?.({
6087
+ this.fire("selectedRowKeysChange", r, n, { details: {
6088
+ action: t,
6089
+ affectedRowKeys: e
6090
+ } }), this.props.onSelectionChange?.({
6000
6091
  action: t,
6001
6092
  affectedRowKeys: e,
6002
6093
  selectedRowKeys: r,
@@ -6004,7 +6095,7 @@ var $n = class t {
6004
6095
  });
6005
6096
  }
6006
6097
  toggleColumnVisibility = (e) => {
6007
- this.hiddenColumns = new Set(this.hiddenColumns), this.hiddenColumns.has(e) ? this.hiddenColumns.delete(e) : this.hiddenColumns.add(e), this.columns.clear(), this.notify();
6098
+ this.hiddenColumns = new Set(this.hiddenColumns), this.hiddenColumns.has(e) ? this.hiddenColumns.delete(e) : this.hiddenColumns.add(e), this.reportInteraction("columnVisibilityChange", !this.hiddenColumns.has(e), this.hiddenColumns.has(e) ? "hide" : "show", { columnKey: e }), this.columns.clear(), this.notify();
6008
6099
  };
6009
6100
  setWidth = (e, t) => {
6010
6101
  this.columnWidths.set(e, t);
@@ -6035,73 +6126,73 @@ var $n = class t {
6035
6126
  };
6036
6127
  //#endregion
6037
6128
  //#region src/components/dataGrid/useGrid.ts
6038
- function er(e) {
6039
- let [t] = P(() => new $n(e)), n = u("datagrid");
6040
- return t.setProps(e), t.setIdentifier(n), ae(t.subscribe, t.getSnapshot, t.getSnapshot), t;
6129
+ function rr(e) {
6130
+ let [t] = F(() => new nr(e)), n = d("datagrid");
6131
+ return t.setProps(e), t.setIdentifier(n), oe(t.subscribe, t.getSnapshot, t.getSnapshot), t;
6041
6132
  }
6042
6133
  //#endregion
6043
6134
  //#region src/components/dataGrid/useListLayout.ts
6044
- var tr, nr;
6045
- function rr() {
6046
- return nr ??= import("../dataGridList.mjs").then((e) => tr = e.default), nr;
6135
+ var ir, ar;
6136
+ function or() {
6137
+ return ar ??= import("../dataGridList.mjs").then((e) => ir = e.default), ar;
6047
6138
  }
6048
- t("(max-width: 36rem)")?.matches && rr();
6049
- function ir(e) {
6050
- let [t, n] = P(() => tr);
6051
- return A(() => {
6139
+ t("(max-width: 36rem)")?.matches && or();
6140
+ function sr(e) {
6141
+ let [t, n] = F(() => ir);
6142
+ return N(() => {
6052
6143
  if (!e || t) return;
6053
6144
  let r = !0;
6054
- return rr().then((e) => r && n(() => e)), () => {
6145
+ return or().then((e) => r && n(() => e)), () => {
6055
6146
  r = !1;
6056
6147
  };
6057
6148
  }, [e, t]), t;
6058
6149
  }
6059
6150
  //#endregion
6060
6151
  //#region src/components/dataGrid.tsx
6061
- function ar(e, t) {
6062
- let n = er(e), a = N(null);
6063
- j(t, () => ({
6152
+ function cr(e, t) {
6153
+ let n = rr(e), i = P(null);
6154
+ ne(t, () => ({
6064
6155
  get element() {
6065
- return a.current;
6156
+ return i.current;
6066
6157
  },
6067
6158
  exportCsv: n.exportCsv,
6068
6159
  exportXlsx: n.exportXlsx,
6069
6160
  refresh: n.refresh,
6070
6161
  clearEdits: n.edits.clearEdits
6071
6162
  }), [n]);
6072
- let { component: o, data: s, def: c, loading: l, filters: u, globalFilterValue: d, columnFilters: f, expandedRowKeys: p, expandedTreeKeys: h, page: g, pageSize: _, onSelectedRowKeysChange: v, onSelectionChange: y, onGlobalFilterChange: b, onColumnFiltersChange: x, onExpandedRowKeysChange: S, onExpandedTreeKeysChange: C, onCellEditsChange: w, onPaginationChange: T, onPageChange: ee, onPageSizeChange: te, onSortingChange: ne, onSortChange: E, onServerStateChange: D, style: O, ...k } = e;
6163
+ let { component: o, data: s, def: c, loading: l, filters: u, globalFilterValue: d, columnFilters: f, expandedRowKeys: p, expandedTreeKeys: m, page: h, pageSize: _, onSelectedRowKeysChange: v, onSelectionChange: y, onGlobalFilterChange: b, onColumnFiltersChange: x, onExpandedRowKeysChange: S, onExpandedTreeKeysChange: C, onCellEditsChange: w, onPaginationChange: T, onPageChange: E, onPageSizeChange: ee, onSortingChange: D, onSortChange: te, onServerStateChange: O, style: k, ...A } = e;
6073
6164
  re(() => {
6074
- let e = a.current;
6165
+ let e = i.current;
6075
6166
  if (e) return n.setSizingElement(e), () => n.setSizingElement(null);
6076
6167
  }, [n]), r(() => {
6077
- let e = a.current;
6168
+ let e = i.current;
6078
6169
  if (!e) return;
6079
6170
  n.list.setWidth(e.clientWidth);
6080
6171
  let t = new ResizeObserver(() => n.list.setWidth(e.clientWidth));
6081
6172
  return t.observe(e), () => t.disconnect();
6082
6173
  }, [n]);
6083
- let A = n.list.active, M = ir(A);
6084
- return /* @__PURE__ */ L(i, {
6085
- ref: a,
6174
+ let j = n.list.active, M = sr(j);
6175
+ return /* @__PURE__ */ R(a, {
6176
+ ref: i,
6086
6177
  component: n.componentName,
6087
- variant: { list: !!M && A },
6088
- ...k,
6178
+ variant: { list: !!M && j },
6179
+ ...A,
6089
6180
  style: {
6090
6181
  ...n.sizes.value,
6091
- ...O
6182
+ ...k
6092
6183
  },
6093
- children: [M && A ? /* @__PURE__ */ I(M, { grid: n }) : /* @__PURE__ */ L(F, { children: [
6094
- n.props.def.topBar && /* @__PURE__ */ I(dn, { grid: n }),
6095
- /* @__PURE__ */ I(tn, { grid: n }),
6096
- /* @__PURE__ */ I(en, { grid: n }),
6097
- n.props.def.bottomBar && /* @__PURE__ */ I(he, { grid: n })
6098
- ] }), /* @__PURE__ */ I(m, {
6184
+ children: [M && j ? /* @__PURE__ */ L(M, { grid: n }) : /* @__PURE__ */ R(I, { children: [
6185
+ n.props.def.topBar && /* @__PURE__ */ L(mn, { grid: n }),
6186
+ /* @__PURE__ */ L(an, { grid: n }),
6187
+ /* @__PURE__ */ L(rn, { grid: n }),
6188
+ n.props.def.bottomBar && /* @__PURE__ */ L(_e, { grid: n })
6189
+ ] }), /* @__PURE__ */ L(g, {
6099
6190
  props: { role: "status" },
6100
6191
  children: n.selectionAnnouncement
6101
6192
  })]
6102
6193
  });
6103
6194
  }
6104
- var or = E(ar);
6105
- ar.displayName = "DataGrid";
6195
+ var lr = k(cr);
6196
+ cr.displayName = "DataGrid";
6106
6197
  //#endregion
6107
- export { Bn as DATA_GRID_LOCALE_TEXT, $t as a, Z as c, gt as d, or as default, Y as f, tn as i, bt as l, Te as m, on as n, Bt as o, W as p, rn as r, jt as s, cn as t, yt as u };
6198
+ export { Un as DATA_GRID_LOCALE_TEXT, nn as a, Z as c, yt as d, lr as default, Y as f, an as i, Ct as l, De as m, ln as n, Ut as o, W as p, sn as r, Pt as s, dn as t, St as u };