@box-kite/react 2.3.1 → 2.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/rules/box-kite-rules.md +58 -94
- package/.claude/skills/box-kite/SKILL.md +69 -104
- package/.claude/skills/box-kite/references/components.md +8 -1
- package/.claude/skills/box-kite/references/patterns.md +1 -1
- package/.claude/skills/box-kite/references/rules.md +115 -0
- package/.claude/skills/box-kite/references/styling.md +5 -3
- package/.cursor/rules/box-kite.mdc +60 -96
- package/AGENTS.md +61 -97
- package/BOX_AI_CONTEXT.md +111 -40
- package/BOX_KITE_AI_CONTEXT.md +111 -40
- package/README.md +200 -721
- package/box.cjs +1 -1
- package/box.d.ts +5 -0
- package/box.mjs +5 -5
- package/catalog.cjs +1 -1
- package/catalog.mjs +53 -18
- package/client.cjs +1 -1
- package/client.mjs +85 -85
- package/components/accordion.cjs +1 -1
- package/components/accordion.mjs +1 -1
- package/components/button.cjs +1 -1
- package/components/button.mjs +1 -1
- package/components/calendar.cjs +1 -1
- package/components/calendar.mjs +1 -1
- package/components/chart.cjs +1 -1
- package/components/chart.mjs +3 -3
- package/components/checkbox.cjs +1 -1
- package/components/checkbox.mjs +1 -1
- package/components/combobox/comboboxListbox.d.ts +2 -1
- package/components/combobox.cjs +1 -1
- package/components/combobox.d.ts +1 -1
- package/components/combobox.mjs +200 -189
- package/components/dashboard.cjs +1 -1
- package/components/dashboard.mjs +1 -1
- package/components/dataGrid/contracts/dataGridContract.d.ts +2 -1
- package/components/dataGrid/useListLayout.d.ts +1 -1
- package/components/dataGrid.cjs +3 -3
- package/components/dataGrid.mjs +453 -453
- package/components/dateField.cjs +1 -1
- package/components/dateField.mjs +16 -16
- package/components/datePicker.cjs +1 -1
- package/components/datePicker.mjs +1 -1
- package/components/dateTime.cjs +1 -1
- package/components/dateTime.mjs +1 -1
- package/components/dialog.cjs +1 -1
- package/components/dialog.mjs +1 -1
- package/components/flex.cjs +1 -1
- package/components/flex.mjs +1 -1
- package/components/flow.cjs +1 -0
- package/components/flow.d.ts +56 -0
- package/components/flow.mjs +98 -0
- package/components/form.cjs +1 -1
- package/components/form.mjs +1 -1
- package/components/grid.cjs +1 -1
- package/components/grid.mjs +1 -1
- package/components/icon.cjs +1 -1
- package/components/icon.mjs +1 -1
- package/components/list.cjs +1 -1
- package/components/list.mjs +1 -1
- package/components/menu.cjs +1 -1
- package/components/menu.mjs +1 -1
- package/components/popover.cjs +1 -1
- package/components/popover.mjs +1 -1
- package/components/radioButton.cjs +1 -1
- package/components/radioButton.mjs +1 -1
- package/components/radioGroup.cjs +1 -1
- package/components/radioGroup.mjs +2 -1
- package/components/semantics.cjs +1 -1
- package/components/semantics.d.ts +32 -30
- package/components/semantics.mjs +3 -3
- package/components/skeleton.cjs +1 -1
- package/components/skeleton.d.ts +1 -1
- package/components/skeleton.mjs +3 -1
- package/components/slider.cjs +1 -1
- package/components/slider.mjs +1 -1
- package/components/sortableList.cjs +1 -1
- package/components/sortableList.mjs +1 -1
- package/components/svg.cjs +1 -1
- package/components/svg.mjs +14 -14
- package/components/swipeItem.cjs +1 -1
- package/components/swipeItem.mjs +1 -1
- package/components/tabs.cjs +1 -1
- package/components/tabs.mjs +1 -1
- package/components/textarea.cjs +1 -1
- package/components/textarea.d.ts +1 -1
- package/components/textarea.mjs +1 -1
- package/components/textbox.cjs +1 -1
- package/components/textbox.d.ts +1 -1
- package/components/textbox.mjs +1 -1
- package/components/timeZoneSelect.d.ts +1 -1
- package/components/toaster.cjs +1 -1
- package/components/toaster.mjs +14 -15
- package/components/tooltip.cjs +1 -1
- package/components/tooltip.mjs +1 -1
- package/components/virtualList.cjs +1 -1
- package/components/virtualList.mjs +1 -1
- package/components/visuallyHidden.cjs +1 -1
- package/components/visuallyHidden.mjs +1 -1
- package/docs/a11y.md +1 -2
- package/docs/components.md +1 -0
- package/docs/index.md +1 -1
- package/docs/props.md +1 -1
- package/effects.cjs +1 -1
- package/effects.mjs +2 -2
- package/identity.cjs +1 -1
- package/identity.mjs +5 -7
- package/package.json +50 -36
- package/react/boxClassNames.d.ts +2 -2
- package/react/effects.d.ts +5 -6
- package/react/identity/useIdentifier.d.ts +0 -3
- package/react-shared.cjs +1 -1
- package/react-shared.mjs +42 -3
- package/rsc.cjs +1 -1
- package/rsc.d.ts +1 -0
- package/rsc.mjs +2 -2
- package/utils/catalog/catalogContracts.d.ts +0 -10
- package/utils/flow/flowPalette.d.ts +17 -0
- package/utils/flow/flowUtils.d.ts +47 -0
package/components/dataGrid.mjs
CHANGED
|
@@ -23,9 +23,8 @@ import te from "./switch.mjs";
|
|
|
23
23
|
import E, { Fragment as ne, createContext as D, forwardRef as O, memo as k, useCallback as A, useContext as j, useEffect as M, useImperativeHandle as re, useLayoutEffect as ie, useMemo as ae, useRef as N, useState as P, useSyncExternalStore as oe } from "react";
|
|
24
24
|
import { Fragment as F, jsx as I, jsxs as L } from "react/jsx-runtime";
|
|
25
25
|
import { flushSync as se } from "react-dom";
|
|
26
|
-
import { useSyncExternalStore as ce } from "use-sync-external-store/shim";
|
|
27
26
|
//#region src/components/dataGrid/components/dataGridBottomBarSelection.tsx
|
|
28
|
-
function
|
|
27
|
+
function ce(e) {
|
|
29
28
|
let { grid: t } = e, n = t.selectedRows.size, r = t.isSelectionView;
|
|
30
29
|
return /* @__PURE__ */ L(_, {
|
|
31
30
|
component: `${t.componentName}.bottomBar.selection`,
|
|
@@ -57,7 +56,7 @@ function le(e) {
|
|
|
57
56
|
}
|
|
58
57
|
//#endregion
|
|
59
58
|
//#region src/components/dataGrid/components/dataGridPagination.tsx
|
|
60
|
-
function
|
|
59
|
+
function le(e) {
|
|
61
60
|
let { grid: t } = e, { pagination: n } = t, r = n.state, i = A(() => n.firstPage(), [n]), o = A(() => n.prevPage(), [n]), s = A(() => n.nextPage(), [n]), c = A(() => n.lastPage(), [n]);
|
|
62
61
|
if (!r) return null;
|
|
63
62
|
let { canGoPrev: l, canGoNext: u, totalPages: d } = n;
|
|
@@ -66,30 +65,30 @@ function ue(e) {
|
|
|
66
65
|
gap: .5,
|
|
67
66
|
ai: "center",
|
|
68
67
|
children: [
|
|
69
|
-
/* @__PURE__ */ I(
|
|
68
|
+
/* @__PURE__ */ I(ue, {
|
|
70
69
|
grid: t,
|
|
71
70
|
pageSize: r.pageSize
|
|
72
71
|
}),
|
|
73
|
-
/* @__PURE__ */ I(
|
|
72
|
+
/* @__PURE__ */ I(fe, {
|
|
74
73
|
componentName: t.componentName,
|
|
75
74
|
label: t.localeText.firstPage,
|
|
76
75
|
onClick: i,
|
|
77
76
|
disabled: !l,
|
|
78
|
-
children: /* @__PURE__ */ I(
|
|
77
|
+
children: /* @__PURE__ */ I(ge, {})
|
|
79
78
|
}),
|
|
80
|
-
/* @__PURE__ */ I(
|
|
79
|
+
/* @__PURE__ */ I(fe, {
|
|
81
80
|
componentName: t.componentName,
|
|
82
81
|
label: t.localeText.previousPage,
|
|
83
82
|
onClick: o,
|
|
84
83
|
disabled: !l,
|
|
85
|
-
children: /* @__PURE__ */ I(
|
|
84
|
+
children: /* @__PURE__ */ I(me, {})
|
|
86
85
|
}),
|
|
87
86
|
/* @__PURE__ */ L(_, {
|
|
88
87
|
ai: "center",
|
|
89
88
|
gap: 1.5,
|
|
90
89
|
px: 2,
|
|
91
90
|
userSelect: "none",
|
|
92
|
-
children: [/* @__PURE__ */ I(
|
|
91
|
+
children: [/* @__PURE__ */ I(de, {
|
|
93
92
|
grid: t,
|
|
94
93
|
page: r.page,
|
|
95
94
|
totalPages: d
|
|
@@ -100,25 +99,25 @@ function ue(e) {
|
|
|
100
99
|
children: t.localeText.pageCount(d)
|
|
101
100
|
})]
|
|
102
101
|
}),
|
|
103
|
-
/* @__PURE__ */ I(
|
|
102
|
+
/* @__PURE__ */ I(fe, {
|
|
104
103
|
componentName: t.componentName,
|
|
105
104
|
label: t.localeText.nextPage,
|
|
106
105
|
onClick: s,
|
|
107
106
|
disabled: !u,
|
|
108
|
-
children: /* @__PURE__ */ I(
|
|
107
|
+
children: /* @__PURE__ */ I(he, {})
|
|
109
108
|
}),
|
|
110
|
-
/* @__PURE__ */ I(
|
|
109
|
+
/* @__PURE__ */ I(fe, {
|
|
111
110
|
componentName: t.componentName,
|
|
112
111
|
label: t.localeText.lastPage,
|
|
113
112
|
onClick: c,
|
|
114
113
|
disabled: !u,
|
|
115
|
-
children: /* @__PURE__ */ I(
|
|
114
|
+
children: /* @__PURE__ */ I(_e, {})
|
|
116
115
|
})
|
|
117
116
|
]
|
|
118
117
|
});
|
|
119
118
|
}
|
|
120
|
-
|
|
121
|
-
function
|
|
119
|
+
le.displayName = "DataGridPagination";
|
|
120
|
+
function ue({ grid: e, pageSize: t }) {
|
|
122
121
|
let n = e.pagination.pageSizeOptions;
|
|
123
122
|
return !n || n.length === 0 ? null : /* @__PURE__ */ I(_, {
|
|
124
123
|
ai: "center",
|
|
@@ -142,7 +141,7 @@ function de({ grid: e, pageSize: t }) {
|
|
|
142
141
|
})
|
|
143
142
|
});
|
|
144
143
|
}
|
|
145
|
-
function
|
|
144
|
+
function de({ grid: e, page: t, totalPages: n }) {
|
|
146
145
|
let [r, i] = P(String(t)), [a, o] = P(t);
|
|
147
146
|
t !== a && (o(t), i(String(t)));
|
|
148
147
|
let s = A(() => {
|
|
@@ -153,6 +152,7 @@ function fe({ grid: e, page: t, totalPages: n }) {
|
|
|
153
152
|
return /* @__PURE__ */ I(x, {
|
|
154
153
|
type: "number",
|
|
155
154
|
variant: "compact",
|
|
155
|
+
width: "auto",
|
|
156
156
|
value: r,
|
|
157
157
|
onChange: (e) => i(e.target.value),
|
|
158
158
|
textAlign: "center",
|
|
@@ -166,7 +166,7 @@ function fe({ grid: e, page: t, totalPages: n }) {
|
|
|
166
166
|
}
|
|
167
167
|
});
|
|
168
168
|
}
|
|
169
|
-
function
|
|
169
|
+
function fe(e) {
|
|
170
170
|
let { componentName: t, label: n, onClick: r, disabled: i, children: a } = e;
|
|
171
171
|
return /* @__PURE__ */ I(h, {
|
|
172
172
|
component: `${t}.bottomBar.pagination.button`,
|
|
@@ -188,7 +188,7 @@ function pe(e) {
|
|
|
188
188
|
children: a
|
|
189
189
|
});
|
|
190
190
|
}
|
|
191
|
-
function
|
|
191
|
+
function pe(e) {
|
|
192
192
|
return /* @__PURE__ */ I(m, {
|
|
193
193
|
viewBox: "0 0 24 24",
|
|
194
194
|
width: "14",
|
|
@@ -201,21 +201,21 @@ function me(e) {
|
|
|
201
201
|
children: /* @__PURE__ */ I(p, { d: e.d })
|
|
202
202
|
});
|
|
203
203
|
}
|
|
204
|
+
function me() {
|
|
205
|
+
return /* @__PURE__ */ I(pe, { d: "M15 18l-6-6 6-6" });
|
|
206
|
+
}
|
|
204
207
|
function he() {
|
|
205
|
-
return /* @__PURE__ */ I(
|
|
208
|
+
return /* @__PURE__ */ I(pe, { d: "M9 18l6-6-6-6" });
|
|
206
209
|
}
|
|
207
210
|
function ge() {
|
|
208
|
-
return /* @__PURE__ */ I(
|
|
211
|
+
return /* @__PURE__ */ I(pe, { d: "M18 18l-6-6 6-6M11 18l-6-6 6-6" });
|
|
209
212
|
}
|
|
210
213
|
function _e() {
|
|
211
|
-
return /* @__PURE__ */ I(
|
|
212
|
-
}
|
|
213
|
-
function ve() {
|
|
214
|
-
return /* @__PURE__ */ I(me, { d: "M6 18l6-6-6-6M13 18l6-6-6-6" });
|
|
214
|
+
return /* @__PURE__ */ I(pe, { d: "M6 18l6-6-6-6M13 18l6-6-6-6" });
|
|
215
215
|
}
|
|
216
216
|
//#endregion
|
|
217
217
|
//#region src/components/dataGrid/components/dataGridBottomBar.tsx
|
|
218
|
-
function
|
|
218
|
+
function ve(e) {
|
|
219
219
|
let { grid: t } = e, { pagination: n, filter: r } = t;
|
|
220
220
|
if (n.state) {
|
|
221
221
|
let { totalItems: e, startItem: r, endItem: i } = n;
|
|
@@ -226,8 +226,8 @@ function ye(e) {
|
|
|
226
226
|
component: `${t.componentName}.bottomBar.info`,
|
|
227
227
|
children: t.localeText.pageRowRange(r, i, e)
|
|
228
228
|
}),
|
|
229
|
-
t.props.def.rowSelection && /* @__PURE__ */ I(
|
|
230
|
-
/* @__PURE__ */ I(
|
|
229
|
+
t.props.def.rowSelection && /* @__PURE__ */ I(ce, { grid: t }),
|
|
230
|
+
/* @__PURE__ */ I(le, { grid: t })
|
|
231
231
|
]
|
|
232
232
|
});
|
|
233
233
|
}
|
|
@@ -249,19 +249,19 @@ function ye(e) {
|
|
|
249
249
|
children: "✕"
|
|
250
250
|
}), t.localeText.clearFilters]
|
|
251
251
|
}),
|
|
252
|
-
t.props.def.rowSelection && /* @__PURE__ */ I(
|
|
252
|
+
t.props.def.rowSelection && /* @__PURE__ */ I(ce, { grid: t })
|
|
253
253
|
]
|
|
254
254
|
});
|
|
255
255
|
}
|
|
256
256
|
//#endregion
|
|
257
257
|
//#region src/components/dataGrid/gridNavigationContext.ts
|
|
258
|
-
var
|
|
258
|
+
var ye = D(null);
|
|
259
259
|
function R() {
|
|
260
|
-
return j(
|
|
260
|
+
return j(ye);
|
|
261
261
|
}
|
|
262
|
-
var
|
|
263
|
-
function
|
|
264
|
-
let r = oe(e?.activeCell.subscribe ??
|
|
262
|
+
var be = () => () => {};
|
|
263
|
+
function z(e, t, n) {
|
|
264
|
+
let r = oe(e?.activeCell.subscribe ?? be, () => !!e?.activeCell.isActive(t, n), () => !!e?.activeCell.isActive(t, n));
|
|
265
265
|
return e ? {
|
|
266
266
|
...e.cellProps(t, n),
|
|
267
267
|
tabIndex: r ? 0 : -1
|
|
@@ -269,7 +269,7 @@ function Se(e, t, n) {
|
|
|
269
269
|
}
|
|
270
270
|
//#endregion
|
|
271
271
|
//#region src/components/dataGrid/models/viewportModel.ts
|
|
272
|
-
var
|
|
272
|
+
var xe = class e {
|
|
273
273
|
grid;
|
|
274
274
|
static DEFAULT_VISIBLE_ROWS_COUNT = 10;
|
|
275
275
|
static ROWS_AHEAD = 12;
|
|
@@ -331,7 +331,7 @@ var Ce = class e {
|
|
|
331
331
|
viewHeight: this.viewHeight
|
|
332
332
|
};
|
|
333
333
|
}
|
|
334
|
-
},
|
|
334
|
+
}, Se = class {
|
|
335
335
|
row;
|
|
336
336
|
column;
|
|
337
337
|
listeners = /* @__PURE__ */ new Set();
|
|
@@ -345,65 +345,65 @@ var Ce = class e {
|
|
|
345
345
|
set(e, t) {
|
|
346
346
|
(e !== this.row || t !== this.column) && (this.row = e, this.column = t, this.listeners.forEach((e) => e()));
|
|
347
347
|
}
|
|
348
|
-
},
|
|
349
|
-
function
|
|
350
|
-
return
|
|
348
|
+
}, B, Ce;
|
|
349
|
+
function we() {
|
|
350
|
+
return Ce ??= import("../dataGridDateParts.mjs").then((e) => B = e.default), Ce;
|
|
351
351
|
}
|
|
352
|
-
function
|
|
353
|
-
return
|
|
352
|
+
function Te() {
|
|
353
|
+
return B;
|
|
354
354
|
}
|
|
355
|
-
function
|
|
355
|
+
function Ee(e) {
|
|
356
356
|
let [t, n] = P(void 0);
|
|
357
357
|
return r(() => {
|
|
358
358
|
if (!e || t) return;
|
|
359
|
-
if (
|
|
360
|
-
n(() =>
|
|
359
|
+
if (B) {
|
|
360
|
+
n(() => B);
|
|
361
361
|
return;
|
|
362
362
|
}
|
|
363
363
|
let r = !0;
|
|
364
|
-
return
|
|
364
|
+
return we().then((e) => r && n(() => e)), () => {
|
|
365
365
|
r = !1;
|
|
366
366
|
};
|
|
367
367
|
}, [e, t]), t;
|
|
368
368
|
}
|
|
369
369
|
//#endregion
|
|
370
370
|
//#region src/components/dataGrid/models/editModel.ts
|
|
371
|
-
function
|
|
371
|
+
function V(e, t) {
|
|
372
372
|
return JSON.stringify([e, t]);
|
|
373
373
|
}
|
|
374
|
-
var
|
|
375
|
-
function
|
|
376
|
-
return typeof e == "number" ? "number" : typeof e == "boolean" ? "checkbox" : e instanceof Date ? "datetime" : typeof e == "string" ?
|
|
374
|
+
var De = 1e3;
|
|
375
|
+
function Oe(e) {
|
|
376
|
+
return typeof e == "number" ? "number" : typeof e == "boolean" ? "checkbox" : e instanceof Date ? "datetime" : typeof e == "string" ? Ae.test(e) ? "date" : je.test(e) ? "time" : Me.test(e) ? "datetime" : "text" : "text";
|
|
377
377
|
}
|
|
378
|
-
var
|
|
378
|
+
var ke = /* @__PURE__ */ new Set([
|
|
379
379
|
"date",
|
|
380
380
|
"time",
|
|
381
381
|
"datetime"
|
|
382
|
-
]),
|
|
383
|
-
function
|
|
384
|
-
return
|
|
382
|
+
]), Ae = /^\d{4}-\d{2}-\d{2}$/, je = /^\d{2}:\d{2}(:\d{2}(\.\d+)?)?$/, Me = /^\d{4}-\d{2}-\d{2}[T ]\d{2}:\d{2}/;
|
|
383
|
+
function Ne(e) {
|
|
384
|
+
return ke.has(e);
|
|
385
385
|
}
|
|
386
|
-
function
|
|
386
|
+
function Pe(e, t) {
|
|
387
387
|
if (e === "text") return t;
|
|
388
388
|
if (e !== "number" || t.trim() === "") return;
|
|
389
389
|
let n = Number(t);
|
|
390
390
|
return Number.isFinite(n) ? n : void 0;
|
|
391
391
|
}
|
|
392
|
-
var
|
|
392
|
+
var Fe = [
|
|
393
393
|
"value",
|
|
394
394
|
"oldValue",
|
|
395
395
|
"error"
|
|
396
|
-
],
|
|
396
|
+
], Ie = /* @__PURE__ */ new Set([
|
|
397
397
|
"true",
|
|
398
398
|
"1",
|
|
399
399
|
"yes"
|
|
400
|
-
]),
|
|
400
|
+
]), Le = /* @__PURE__ */ new Set([
|
|
401
401
|
"false",
|
|
402
402
|
"0",
|
|
403
403
|
"no",
|
|
404
404
|
""
|
|
405
405
|
]);
|
|
406
|
-
function
|
|
406
|
+
function Re(e, t, n) {
|
|
407
407
|
if (e.type === "number") {
|
|
408
408
|
if (n.trim() === "") return { value: null };
|
|
409
409
|
let e = Number(n);
|
|
@@ -411,17 +411,17 @@ function Be(e, t, n) {
|
|
|
411
411
|
}
|
|
412
412
|
if (e.type === "checkbox") {
|
|
413
413
|
let e = n.trim().toLowerCase();
|
|
414
|
-
return
|
|
414
|
+
return Ie.has(e) ? { value: !0 } : Le.has(e) ? { value: !1 } : void 0;
|
|
415
415
|
}
|
|
416
|
-
if (
|
|
416
|
+
if (Ne(e.type)) {
|
|
417
417
|
if (n.trim() === "") return { value: null };
|
|
418
|
-
let t =
|
|
418
|
+
let t = Te();
|
|
419
419
|
if (t) {
|
|
420
420
|
let r = t.parsePasted(e, n);
|
|
421
421
|
return r ? { value: r } : void 0;
|
|
422
422
|
}
|
|
423
423
|
let r = n.trim();
|
|
424
|
-
return (e.type === "date" ?
|
|
424
|
+
return (e.type === "date" ? Ae : e.type === "time" ? je : Me).test(r) ? { value: r } : void 0;
|
|
425
425
|
}
|
|
426
426
|
if (e.type === "select") {
|
|
427
427
|
let e = t.find((e) => String(e.value) === n);
|
|
@@ -429,10 +429,10 @@ function Be(e, t, n) {
|
|
|
429
429
|
}
|
|
430
430
|
return { value: n };
|
|
431
431
|
}
|
|
432
|
-
function
|
|
432
|
+
function ze(e) {
|
|
433
433
|
return e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey;
|
|
434
434
|
}
|
|
435
|
-
var
|
|
435
|
+
var Be = class {
|
|
436
436
|
grid;
|
|
437
437
|
constructor(e) {
|
|
438
438
|
this.grid = e;
|
|
@@ -457,7 +457,7 @@ var He = class {
|
|
|
457
457
|
}
|
|
458
458
|
editorFor(e, t) {
|
|
459
459
|
let { editor: n } = e.def;
|
|
460
|
-
return typeof n == "object" ? n : n ? { type: n } : { type:
|
|
460
|
+
return typeof n == "object" ? n : n ? { type: n } : { type: Oe(t) };
|
|
461
461
|
}
|
|
462
462
|
isEditing(e, t) {
|
|
463
463
|
return this._active?.rowKey === e && this._active.columnKey === t;
|
|
@@ -470,7 +470,7 @@ var He = class {
|
|
|
470
470
|
return !!this._active;
|
|
471
471
|
}
|
|
472
472
|
isRejected(e, t) {
|
|
473
|
-
return this.rejected.size > 0 && this.rejected.has(
|
|
473
|
+
return this.rejected.size > 0 && this.rejected.has(V(e, t));
|
|
474
474
|
}
|
|
475
475
|
get draft() {
|
|
476
476
|
return this._active?.draft;
|
|
@@ -482,8 +482,8 @@ var He = class {
|
|
|
482
482
|
return !!this._active?.pending;
|
|
483
483
|
}
|
|
484
484
|
begin(e, t, n, r) {
|
|
485
|
-
let i = r === void 0 ? void 0 :
|
|
486
|
-
this.rejected.delete(
|
|
485
|
+
let i = r === void 0 ? void 0 : Pe(this.editorFor(t, n).type, r);
|
|
486
|
+
this.rejected.delete(V(e.key, t.key)), this._active = {
|
|
487
487
|
row: e,
|
|
488
488
|
rowKey: e.key,
|
|
489
489
|
columnKey: t.key,
|
|
@@ -549,19 +549,19 @@ var He = class {
|
|
|
549
549
|
columnKey: t.columnKey,
|
|
550
550
|
oldValue: t.oldValue,
|
|
551
551
|
error: this._active.error
|
|
552
|
-
},
|
|
552
|
+
}, Fe);
|
|
553
553
|
return;
|
|
554
554
|
}
|
|
555
|
-
this.values.set(
|
|
555
|
+
this.values.set(V(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", {
|
|
556
556
|
rowKey: t.rowKey,
|
|
557
557
|
columnKey: t.columnKey,
|
|
558
558
|
oldValue: t.oldValue
|
|
559
|
-
},
|
|
559
|
+
}, Fe);
|
|
560
560
|
}
|
|
561
561
|
}
|
|
562
562
|
valueOf(e, t, n) {
|
|
563
563
|
if (this.values.size === 0) return n;
|
|
564
|
-
let r =
|
|
564
|
+
let r = V(e, t);
|
|
565
565
|
return this.values.has(r) ? this.values.get(r) : n;
|
|
566
566
|
}
|
|
567
567
|
get edits() {
|
|
@@ -580,7 +580,7 @@ var He = class {
|
|
|
580
580
|
c++;
|
|
581
581
|
continue;
|
|
582
582
|
}
|
|
583
|
-
let f = this.valueOf(l.key, u.key, l.data[u.key]), p =
|
|
583
|
+
let f = this.valueOf(l.key, u.key, l.data[u.key]), p = Re(this.editorFor(u, f), this.optionsFor(u, l), d), m = {
|
|
584
584
|
rowKey: l.key,
|
|
585
585
|
columnKey: u.key,
|
|
586
586
|
row: l.data,
|
|
@@ -606,13 +606,13 @@ var He = class {
|
|
|
606
606
|
this.rejected.clear(), n.forEach((e, t) => {
|
|
607
607
|
let n = r[t];
|
|
608
608
|
if (typeof n == "string" || n === !1) {
|
|
609
|
-
this.rejected.add(
|
|
609
|
+
this.rejected.add(V(e.rowKey, e.columnKey)), o.push({
|
|
610
610
|
...e,
|
|
611
611
|
error: typeof n == "string" ? n : this.invalidValue
|
|
612
612
|
});
|
|
613
613
|
return;
|
|
614
614
|
}
|
|
615
|
-
Object.is(e.value, e.oldValue) || (this.values.set(
|
|
615
|
+
Object.is(e.value, e.oldValue) || (this.values.set(V(e.rowKey, e.columnKey), e.value), a.push(e));
|
|
616
616
|
}), a.length > 0 && (this._edits = [...this._edits, ...a]), this.grid.notify(), a.length > 0 && this.grid.props.onCellEditsChange?.(this._edits, { reason: "paste" });
|
|
617
617
|
let s = this.grid.range.rangeOf(t);
|
|
618
618
|
this.grid.props.onPaste?.({
|
|
@@ -639,8 +639,8 @@ var He = class {
|
|
|
639
639
|
}, ["cells"]);
|
|
640
640
|
}
|
|
641
641
|
nextEditable(e, t, n = !1) {
|
|
642
|
-
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 +
|
|
643
|
-
for (let e = o; e >= Math.max(0, o -
|
|
642
|
+
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 + De);
|
|
643
|
+
for (let e = o; e >= Math.max(0, o - De) && e <= s; e += a) {
|
|
644
644
|
let t = Math.floor(e / i.length), n = e % i.length, a = r[t], o = i[n];
|
|
645
645
|
if (!(!o || a?.kind !== "row" || !this.isEditable(a, o))) return {
|
|
646
646
|
row: t,
|
|
@@ -648,7 +648,7 @@ var He = class {
|
|
|
648
648
|
};
|
|
649
649
|
}
|
|
650
650
|
}
|
|
651
|
-
},
|
|
651
|
+
}, H = class {
|
|
652
652
|
grid;
|
|
653
653
|
row;
|
|
654
654
|
column;
|
|
@@ -720,7 +720,7 @@ var He = class {
|
|
|
720
720
|
columnKey: this.column.key
|
|
721
721
|
}, ["value"]);
|
|
722
722
|
};
|
|
723
|
-
},
|
|
723
|
+
}, Ve = class e {
|
|
724
724
|
grid;
|
|
725
725
|
parentRow;
|
|
726
726
|
constructor(e, t) {
|
|
@@ -753,7 +753,7 @@ var He = class {
|
|
|
753
753
|
get allRows() {
|
|
754
754
|
return [];
|
|
755
755
|
}
|
|
756
|
-
},
|
|
756
|
+
}, U = class {
|
|
757
757
|
grid;
|
|
758
758
|
rowIndex;
|
|
759
759
|
constructor(e, t, n) {
|
|
@@ -784,7 +784,7 @@ var He = class {
|
|
|
784
784
|
let e = this.grid.columns.value.visibleLeafs;
|
|
785
785
|
return this._cells?.leafs !== e && (this._cells = {
|
|
786
786
|
leafs: e,
|
|
787
|
-
cells: e.map((e) => new
|
|
787
|
+
cells: e.map((e) => new H(this.grid, this, e))
|
|
788
788
|
}), this._cells.cells;
|
|
789
789
|
}
|
|
790
790
|
get cellCount() {
|
|
@@ -806,7 +806,7 @@ var He = class {
|
|
|
806
806
|
return this.grid.expandedDetailRows.has(this.key);
|
|
807
807
|
}
|
|
808
808
|
get flatRows() {
|
|
809
|
-
return this.grid.props.def.rowDetail && this.expanded ? [this, new
|
|
809
|
+
return this.grid.props.def.rowDetail && this.expanded ? [this, new Ve(this.grid, this)] : [this];
|
|
810
810
|
}
|
|
811
811
|
get allRows() {
|
|
812
812
|
return this;
|
|
@@ -814,14 +814,14 @@ var He = class {
|
|
|
814
814
|
};
|
|
815
815
|
//#endregion
|
|
816
816
|
//#region src/components/dataGrid/models/treeRow.ts
|
|
817
|
-
function
|
|
817
|
+
function W(e) {
|
|
818
818
|
return !!e && e.isTreeRow === !0;
|
|
819
819
|
}
|
|
820
820
|
//#endregion
|
|
821
821
|
//#region src/components/dataGrid/useGridNavigation.ts
|
|
822
|
-
var
|
|
823
|
-
function
|
|
824
|
-
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 ?
|
|
822
|
+
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 = [];
|
|
823
|
+
function Ke(e) {
|
|
824
|
+
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 = A((e) => {
|
|
825
825
|
if (e < o.length) return o[e]?.length ?? 0;
|
|
826
826
|
if (e < l || e >= l + d.length) return f;
|
|
827
827
|
let t = d[e - l];
|
|
@@ -843,7 +843,7 @@ function Je(e) {
|
|
|
843
843
|
return;
|
|
844
844
|
}
|
|
845
845
|
let { startIndex: u, take: f } = o.window(i.top, i.direction);
|
|
846
|
-
if (s >= u +
|
|
846
|
+
if (s >= u + We && s < u + f - We) return;
|
|
847
847
|
let p = o.rowTop(s);
|
|
848
848
|
c.scrollTop = p, a(p);
|
|
849
849
|
}, [
|
|
@@ -885,12 +885,12 @@ function Je(e) {
|
|
|
885
885
|
let C = A((e, n, r) => {
|
|
886
886
|
if (!t.tree.enabled || e.key !== "ArrowRight" && e.key !== "ArrowLeft") return !1;
|
|
887
887
|
let i = d[n - l];
|
|
888
|
-
if (!
|
|
888
|
+
if (!W(i) || t.columns.value.visibleLeafs[r]?.key !== t.tree.columnKey) return !1;
|
|
889
889
|
if (e.key === (t.isRtl ? "ArrowLeft" : "ArrowRight")) return !i.hasChildren || i.treeExpanded ? !1 : (i.toggleTree(), !0);
|
|
890
890
|
if (i.hasChildren && i.treeExpanded) return i.toggleTree(), !0;
|
|
891
891
|
for (let e = n - 1; e >= l; e--) {
|
|
892
892
|
let t = d[e - l];
|
|
893
|
-
if (!(!
|
|
893
|
+
if (!(!W(t) || t.level >= i.level)) return x.setActiveCell(e, r, { reason: "keyboard" }), !0;
|
|
894
894
|
}
|
|
895
895
|
return !1;
|
|
896
896
|
}, [
|
|
@@ -911,18 +911,18 @@ function Je(e) {
|
|
|
911
911
|
if (!t.props.def.rowSelection) return !1;
|
|
912
912
|
if (e < l) return e >= o.length || !t.columns.value.visibleLeafs[n]?.isRowSelection ? !1 : (t.toggleSelectAllRows(), !0);
|
|
913
913
|
let r = t.flatRows.value[e - l];
|
|
914
|
-
return r instanceof
|
|
914
|
+
return r instanceof U && (r.toggleSelection(), !0);
|
|
915
915
|
}, [
|
|
916
916
|
t,
|
|
917
917
|
l,
|
|
918
918
|
o.length
|
|
919
919
|
]), ee = A((e, t, n) => {
|
|
920
|
-
let r = Array.from(e.querySelectorAll(
|
|
920
|
+
let r = Array.from(e.querySelectorAll(Ue));
|
|
921
921
|
if (r.length < 2) return !1;
|
|
922
922
|
let i = r.indexOf(t);
|
|
923
923
|
return i !== -1 && (r[(i + (n ? -1 : 1) + r.length) % r.length].focus(), !0);
|
|
924
924
|
}, []), te = x.onKeyDown, E = A((e) => {
|
|
925
|
-
let n = e.target, r = n.closest?.(
|
|
925
|
+
let n = e.target, r = n.closest?.(He);
|
|
926
926
|
if (r) {
|
|
927
927
|
if (n !== r) {
|
|
928
928
|
if (e.key === "Escape" && !r.querySelector("[aria-expanded=\"true\"]")) {
|
|
@@ -950,13 +950,13 @@ function Je(e) {
|
|
|
950
950
|
e.preventDefault();
|
|
951
951
|
return;
|
|
952
952
|
}
|
|
953
|
-
let i = r.querySelector(
|
|
953
|
+
let i = r.querySelector(Ue);
|
|
954
954
|
if (i) {
|
|
955
955
|
e.preventDefault(), i.focus();
|
|
956
956
|
return;
|
|
957
957
|
}
|
|
958
958
|
}
|
|
959
|
-
if (t.edits.enabled &&
|
|
959
|
+
if (t.edits.enabled && ze(e) && t.edits.beginAt(x.activeIndex - l, x.activeColumn, e.key)) {
|
|
960
960
|
e.preventDefault();
|
|
961
961
|
return;
|
|
962
962
|
}
|
|
@@ -977,7 +977,7 @@ function Je(e) {
|
|
|
977
977
|
ee,
|
|
978
978
|
T,
|
|
979
979
|
C
|
|
980
|
-
]), { setActiveCell: ne, activeIndex: D, activeColumn: O } = x, k = c(x.cellProps), [j] = P(() => new
|
|
980
|
+
]), { setActiveCell: ne, activeIndex: D, activeColumn: O } = x, k = c(x.cellProps), [j] = P(() => new Se(D, O));
|
|
981
981
|
r(() => j.set(D, O), [
|
|
982
982
|
j,
|
|
983
983
|
O,
|
|
@@ -1011,7 +1011,7 @@ function Je(e) {
|
|
|
1011
1011
|
}
|
|
1012
1012
|
//#endregion
|
|
1013
1013
|
//#region src/utils/array/arrayUtils.ts
|
|
1014
|
-
var
|
|
1014
|
+
var qe;
|
|
1015
1015
|
(function(e) {
|
|
1016
1016
|
function t(e, t, n = 0) {
|
|
1017
1017
|
return e.slice(n, n + t);
|
|
@@ -1058,11 +1058,11 @@ var Ye;
|
|
|
1058
1058
|
}));
|
|
1059
1059
|
}
|
|
1060
1060
|
e.groupBy = s;
|
|
1061
|
-
})(
|
|
1062
|
-
var
|
|
1061
|
+
})(qe ||= {});
|
|
1062
|
+
var G = qe, Je = "row-number-cell", Ye = "row-selection-cell", K = "grouping-cell", Xe = "row-detail-cell", Ze = Symbol("memo.unset"), Qe = class {
|
|
1063
1063
|
action;
|
|
1064
1064
|
deps;
|
|
1065
|
-
cache =
|
|
1065
|
+
cache = Ze;
|
|
1066
1066
|
dependents = /* @__PURE__ */ new Set();
|
|
1067
1067
|
wired = !1;
|
|
1068
1068
|
constructor(e, t) {
|
|
@@ -1075,46 +1075,46 @@ var W = Ye, Xe = "row-number-cell", Ze = "row-selection-cell", G = "grouping-cel
|
|
|
1075
1075
|
}
|
|
1076
1076
|
}
|
|
1077
1077
|
get value() {
|
|
1078
|
-
return this.wire(), this.cache ===
|
|
1078
|
+
return this.wire(), this.cache === Ze && (this.cache = this.action()), this.cache;
|
|
1079
1079
|
}
|
|
1080
1080
|
clear() {
|
|
1081
|
-
if (this.wire(), this.cache !==
|
|
1082
|
-
this.cache =
|
|
1081
|
+
if (this.wire(), this.cache !== Ze) {
|
|
1082
|
+
this.cache = Ze;
|
|
1083
1083
|
for (let e of this.dependents) e.clear();
|
|
1084
1084
|
}
|
|
1085
1085
|
}
|
|
1086
1086
|
};
|
|
1087
1087
|
function q(e, t = () => []) {
|
|
1088
|
-
return new
|
|
1088
|
+
return new Qe(e, t);
|
|
1089
1089
|
}
|
|
1090
1090
|
//#endregion
|
|
1091
1091
|
//#region src/components/dataGrid/models/aggregationModel.ts
|
|
1092
|
-
function
|
|
1092
|
+
function $e(e) {
|
|
1093
1093
|
return e.filter((e) => typeof e == "number" && !Number.isNaN(e));
|
|
1094
1094
|
}
|
|
1095
|
-
var
|
|
1095
|
+
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 = {
|
|
1096
1096
|
sum: (e) => {
|
|
1097
|
-
let t =
|
|
1098
|
-
return t.length ?
|
|
1097
|
+
let t = $e(e);
|
|
1098
|
+
return t.length ? et(t) : null;
|
|
1099
1099
|
},
|
|
1100
1100
|
avg: (e) => {
|
|
1101
|
-
let t =
|
|
1102
|
-
return t.length ? Math.round(
|
|
1101
|
+
let t = $e(e);
|
|
1102
|
+
return t.length ? Math.round(et(t) / t.length * 100) / 100 : null;
|
|
1103
1103
|
},
|
|
1104
1104
|
min: (e) => {
|
|
1105
|
-
let t =
|
|
1106
|
-
return t.length ?
|
|
1105
|
+
let t = $e(e);
|
|
1106
|
+
return t.length ? tt(t, !0) : null;
|
|
1107
1107
|
},
|
|
1108
1108
|
max: (e) => {
|
|
1109
|
-
let t =
|
|
1110
|
-
return t.length ?
|
|
1109
|
+
let t = $e(e);
|
|
1110
|
+
return t.length ? tt(t, !1) : null;
|
|
1111
1111
|
},
|
|
1112
1112
|
count: (e, t) => t.length
|
|
1113
1113
|
};
|
|
1114
|
-
function
|
|
1115
|
-
return typeof e == "function" ? e(t, n) :
|
|
1114
|
+
function rt(e, t, n) {
|
|
1115
|
+
return typeof e == "function" ? e(t, n) : nt[e]?.(t, n) ?? null;
|
|
1116
1116
|
}
|
|
1117
|
-
var
|
|
1117
|
+
var it = class {
|
|
1118
1118
|
grid;
|
|
1119
1119
|
constructor(e) {
|
|
1120
1120
|
this.grid = e;
|
|
@@ -1135,8 +1135,8 @@ var at = class {
|
|
|
1135
1135
|
get footerLabelColumn() {
|
|
1136
1136
|
return this.grid.columns.value.visibleLeafs.find((e) => (e.isData || e.isGrouping) && !e.aggregate);
|
|
1137
1137
|
}
|
|
1138
|
-
footerCells = q(() => this.grid.columns.value.visibleLeafs.map((e) => new
|
|
1139
|
-
},
|
|
1138
|
+
footerCells = q(() => this.grid.columns.value.visibleLeafs.map((e) => new at(this.grid, e, this.grid.filteredData, "footer")), () => [this.grid.rows]);
|
|
1139
|
+
}, at = class {
|
|
1140
1140
|
grid;
|
|
1141
1141
|
column;
|
|
1142
1142
|
rows;
|
|
@@ -1151,7 +1151,7 @@ var at = class {
|
|
|
1151
1151
|
}
|
|
1152
1152
|
_value = q(() => {
|
|
1153
1153
|
let e = this.column.aggregate;
|
|
1154
|
-
return e ?
|
|
1154
|
+
return e ? rt(e, this.values, this.rows) : null;
|
|
1155
1155
|
});
|
|
1156
1156
|
get value() {
|
|
1157
1157
|
let e = this.given?.();
|
|
@@ -1166,7 +1166,7 @@ var at = class {
|
|
|
1166
1166
|
get isLast() {
|
|
1167
1167
|
return !1;
|
|
1168
1168
|
}
|
|
1169
|
-
},
|
|
1169
|
+
}, ot = class {
|
|
1170
1170
|
grid;
|
|
1171
1171
|
row;
|
|
1172
1172
|
column;
|
|
@@ -1188,7 +1188,7 @@ var at = class {
|
|
|
1188
1188
|
get cellKind() {
|
|
1189
1189
|
return this.column.isGrouping ? "grouping" : this.column.isRowSelection ? this.row.selectable ? "selection" : "spacer" : this.row.spans(this.column) ? "hidden" : this.column.aggregate ? "aggregate" : "spacer";
|
|
1190
1190
|
}
|
|
1191
|
-
_aggregate = q(() => this.column.aggregate ? new
|
|
1191
|
+
_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);
|
|
1192
1192
|
get aggregate() {
|
|
1193
1193
|
return this._aggregate.value;
|
|
1194
1194
|
}
|
|
@@ -1207,7 +1207,7 @@ var at = class {
|
|
|
1207
1207
|
get hasGroupingBorder() {
|
|
1208
1208
|
return this.row.groupingColumn.pin === "START";
|
|
1209
1209
|
}
|
|
1210
|
-
},
|
|
1210
|
+
}, st = class {
|
|
1211
1211
|
grid;
|
|
1212
1212
|
groupColumn;
|
|
1213
1213
|
rows;
|
|
@@ -1241,7 +1241,7 @@ var at = class {
|
|
|
1241
1241
|
let e = this.grid.columns.value.visibleLeafs;
|
|
1242
1242
|
return this._cells?.leafs !== e && (this._cells = {
|
|
1243
1243
|
leafs: e,
|
|
1244
|
-
cells: e.map((e) => new
|
|
1244
|
+
cells: e.map((e) => new ot(this.grid, this, e))
|
|
1245
1245
|
}), this._cells;
|
|
1246
1246
|
}
|
|
1247
1247
|
get renderedCells() {
|
|
@@ -1272,7 +1272,7 @@ var at = class {
|
|
|
1272
1272
|
return this.parentRow ? this.parentRow.depth + 1 : 0;
|
|
1273
1273
|
}
|
|
1274
1274
|
get count() {
|
|
1275
|
-
return
|
|
1275
|
+
return G.sumBy(this.rows, (e) => e.count, 0);
|
|
1276
1276
|
}
|
|
1277
1277
|
get flatRows() {
|
|
1278
1278
|
return this.expanded ? [this, ...this.rows.flatMap((e) => e.flatRows)] : [this];
|
|
@@ -1281,7 +1281,7 @@ var at = class {
|
|
|
1281
1281
|
return this.rows.flatMap((e) => e.allRows);
|
|
1282
1282
|
}
|
|
1283
1283
|
get groupingColumn() {
|
|
1284
|
-
return
|
|
1284
|
+
return G.findOrThrow(this.grid.columns.value.leafs, (e) => e.key === K);
|
|
1285
1285
|
}
|
|
1286
1286
|
get groupingColumnGridColumn() {
|
|
1287
1287
|
return this.grid.groupingSpan.value.length;
|
|
@@ -1299,8 +1299,8 @@ var at = class {
|
|
|
1299
1299
|
};
|
|
1300
1300
|
//#endregion
|
|
1301
1301
|
//#region src/components/dataGrid/components/dataGridDetailRow.tsx
|
|
1302
|
-
function
|
|
1303
|
-
let { row: t, index: n } = e, { grid: i, parentRow: o } = t, s = i.props.def.rowDetail, c = R(), l = (c?.headerRowCount ?? 0) + n, { ref: u, tabIndex: d, onFocus: f } =
|
|
1302
|
+
function ct(e) {
|
|
1303
|
+
let { row: t, index: n } = e, { grid: i, parentRow: o } = t, s = i.props.def.rowDetail, c = R(), l = (c?.headerRowCount ?? 0) + n, { ref: u, tabIndex: d, onFocus: f } = z(c, l, 0), p = t.isAutoHeight, m = N(null);
|
|
1304
1304
|
return r(() => {
|
|
1305
1305
|
i.takeDetailReveal(o.key) && m.current?.scrollIntoView?.({ block: "nearest" });
|
|
1306
1306
|
}), /* @__PURE__ */ I(_, {
|
|
@@ -1335,11 +1335,11 @@ function lt(e) {
|
|
|
1335
1335
|
})
|
|
1336
1336
|
});
|
|
1337
1337
|
}
|
|
1338
|
-
|
|
1339
|
-
var
|
|
1338
|
+
ct.displayName = "DataGridDetailRow";
|
|
1339
|
+
var lt = k(ct);
|
|
1340
1340
|
//#endregion
|
|
1341
1341
|
//#region src/components/dataGrid/components/dataGridAggregateValue.tsx
|
|
1342
|
-
function
|
|
1342
|
+
function ut(e) {
|
|
1343
1343
|
let { cell: t } = e, { column: n } = t;
|
|
1344
1344
|
if (n.AggregateCell) return /* @__PURE__ */ I(n.AggregateCell, { cell: t });
|
|
1345
1345
|
let r = t.scope === "footer" ? "footer.cell" : "body.groupRow.aggregate";
|
|
@@ -1352,12 +1352,12 @@ function dt(e) {
|
|
|
1352
1352
|
children: t.value
|
|
1353
1353
|
});
|
|
1354
1354
|
}
|
|
1355
|
-
|
|
1355
|
+
ut.displayName = "DataGridAggregateValue";
|
|
1356
1356
|
//#endregion
|
|
1357
1357
|
//#region src/components/dataGrid/components/dataGridCell.tsx
|
|
1358
|
-
var
|
|
1358
|
+
var dt = "button,a[href],input,select,textarea";
|
|
1359
1359
|
function J(e) {
|
|
1360
|
-
let { children: n, cell: r, row: i, columnIndex: a, ariaColIndex: o, ariaColSpan: s, style: c, ...l } = e, { column: u } = r, d = R(), { ref: f, tabIndex: p, onFocus: m } =
|
|
1360
|
+
let { children: n, cell: r, row: i, columnIndex: a, ariaColIndex: o, ariaColSpan: s, style: c, ...l } = e, { column: u } = r, d = R(), { ref: f, tabIndex: p, onFocus: m } = z(d, i, a), { range: h } = u.grid, g = r instanceof H ? i - (d?.headerRowCount ?? 0) : -1, v = g >= 0 && h.isCurrent(g, a), y = g >= 0 && h.isSelected(g, a);
|
|
1361
1361
|
u.hasAlign && (l.jc = u.align);
|
|
1362
1362
|
let b = r.isExpanded ? {
|
|
1363
1363
|
...u.cellVariant.value,
|
|
@@ -1370,8 +1370,8 @@ function J(e) {
|
|
|
1370
1370
|
isInRange: y && !v,
|
|
1371
1371
|
isCurrentCell: v
|
|
1372
1372
|
});
|
|
1373
|
-
let x = r instanceof
|
|
1374
|
-
r instanceof
|
|
1373
|
+
let x = r instanceof H && !r.editing && r.rejected;
|
|
1374
|
+
r instanceof H && r.editing ? b = {
|
|
1375
1375
|
...b,
|
|
1376
1376
|
isEditing: !0,
|
|
1377
1377
|
isInvalid: !!r.error
|
|
@@ -1379,10 +1379,10 @@ function J(e) {
|
|
|
1379
1379
|
...b,
|
|
1380
1380
|
isInvalid: !0
|
|
1381
1381
|
});
|
|
1382
|
-
let S = r instanceof
|
|
1383
|
-
e.target.closest(
|
|
1382
|
+
let S = r instanceof H ? (e) => {
|
|
1383
|
+
e.target.closest(dt) || (t(e.currentTarget), r.beginEdit());
|
|
1384
1384
|
} : void 0, C = h.enabled && g >= 0, w = C ? (e) => {
|
|
1385
|
-
e.button === 0 && e.pointerType !== "touch" && (e.target.closest(
|
|
1385
|
+
e.button === 0 && e.pointerType !== "touch" && (e.target.closest(dt) || h.press(g, a, e.shiftKey));
|
|
1386
1386
|
} : void 0, T = C && h.isDragging ? (e) => {
|
|
1387
1387
|
h.dragTo(g, a), e.currentTarget.focus();
|
|
1388
1388
|
} : void 0;
|
|
@@ -1413,7 +1413,7 @@ function J(e) {
|
|
|
1413
1413
|
J.displayName = "DataGridCell";
|
|
1414
1414
|
//#endregion
|
|
1415
1415
|
//#region src/components/dataGrid/components/dataGridFooter.tsx
|
|
1416
|
-
function
|
|
1416
|
+
function ft(e) {
|
|
1417
1417
|
let { grid: t } = e, { aggregation: n } = t, r = R();
|
|
1418
1418
|
if (!n.hasFooter) return null;
|
|
1419
1419
|
let i = (r?.rowCount ?? 1) - 1, { footerLabelColumn: o, footerLabel: s } = n;
|
|
@@ -1431,7 +1431,7 @@ function pt(e) {
|
|
|
1431
1431
|
cell: e,
|
|
1432
1432
|
row: i,
|
|
1433
1433
|
columnIndex: n,
|
|
1434
|
-
children: e.column.aggregate ? /* @__PURE__ */ I(
|
|
1434
|
+
children: e.column.aggregate ? /* @__PURE__ */ I(ut, { cell: e }) : e.column === o ? /* @__PURE__ */ I(a, {
|
|
1435
1435
|
component: `${t.componentName}.footer.label`,
|
|
1436
1436
|
px: 3,
|
|
1437
1437
|
textWrap: "nowrap",
|
|
@@ -1441,8 +1441,8 @@ function pt(e) {
|
|
|
1441
1441
|
})
|
|
1442
1442
|
});
|
|
1443
1443
|
}
|
|
1444
|
-
|
|
1445
|
-
var
|
|
1444
|
+
ft.displayName = "DataGridFooter";
|
|
1445
|
+
var pt = k(ft);
|
|
1446
1446
|
//#endregion
|
|
1447
1447
|
//#region src/icons/expandIcon.tsx
|
|
1448
1448
|
function Y(e) {
|
|
@@ -1460,15 +1460,15 @@ function Y(e) {
|
|
|
1460
1460
|
}
|
|
1461
1461
|
//#endregion
|
|
1462
1462
|
//#region src/components/dataGrid/components/dataGridCellPlaceholder.tsx
|
|
1463
|
-
var
|
|
1463
|
+
var mt = [
|
|
1464
1464
|
"3/5",
|
|
1465
1465
|
"2/5",
|
|
1466
1466
|
"4/5",
|
|
1467
1467
|
"1/2",
|
|
1468
1468
|
"7/12"
|
|
1469
1469
|
];
|
|
1470
|
-
function
|
|
1471
|
-
let { cell: t, columnIndex: n } = e, r =
|
|
1470
|
+
function ht(e) {
|
|
1471
|
+
let { cell: t, columnIndex: n } = e, r = mt[(t.row.rowIndex + n) % mt.length];
|
|
1472
1472
|
return /* @__PURE__ */ I(_, {
|
|
1473
1473
|
component: `${t.grid.componentName}.body.cell.placeholder`,
|
|
1474
1474
|
ai: "center",
|
|
@@ -1480,10 +1480,10 @@ function gt(e) {
|
|
|
1480
1480
|
})
|
|
1481
1481
|
});
|
|
1482
1482
|
}
|
|
1483
|
-
|
|
1483
|
+
ht.displayName = "DataGridCellPlaceholder";
|
|
1484
1484
|
//#endregion
|
|
1485
1485
|
//#region src/components/dataGrid/components/dataGridGroupRow.tsx
|
|
1486
|
-
function
|
|
1486
|
+
function gt(e) {
|
|
1487
1487
|
let { row: t, index: n } = e, { selected: r, indeterminate: i, expanded: o, placeholder: s } = t, c = (R()?.headerRowCount ?? 0) + n, l = A(() => t.toggleSelectAll(), [t]);
|
|
1488
1488
|
return /* @__PURE__ */ I(_, {
|
|
1489
1489
|
component: `${t.grid.componentName}.body.groupRow`,
|
|
@@ -1512,7 +1512,7 @@ function _t(e) {
|
|
|
1512
1512
|
gridColumn: e.gridColumnSpan,
|
|
1513
1513
|
ps: e.depthPadding,
|
|
1514
1514
|
overflow: "hidden",
|
|
1515
|
-
children: s ? /* @__PURE__ */ I(
|
|
1515
|
+
children: s ? /* @__PURE__ */ I(ht, {
|
|
1516
1516
|
cell: e,
|
|
1517
1517
|
columnIndex: u
|
|
1518
1518
|
}) : /* @__PURE__ */ I(a, {
|
|
@@ -1560,7 +1560,7 @@ function _t(e) {
|
|
|
1560
1560
|
row: c,
|
|
1561
1561
|
columnIndex: u,
|
|
1562
1562
|
ariaColIndex: n + 1,
|
|
1563
|
-
children: e.aggregate && /* @__PURE__ */ I(
|
|
1563
|
+
children: e.aggregate && /* @__PURE__ */ I(ut, { cell: e.aggregate })
|
|
1564
1564
|
}, e.column.key);
|
|
1565
1565
|
case "spacer": return /* @__PURE__ */ I(J, {
|
|
1566
1566
|
cell: e,
|
|
@@ -1575,16 +1575,16 @@ function _t(e) {
|
|
|
1575
1575
|
})
|
|
1576
1576
|
});
|
|
1577
1577
|
}
|
|
1578
|
-
|
|
1579
|
-
var
|
|
1580
|
-
function
|
|
1578
|
+
gt.displayName = "DataGridGroupRow";
|
|
1579
|
+
var _t = k(gt), vt = "input:not([type=\"hidden\"]),select,textarea,button,[role=\"spinbutton\"]";
|
|
1580
|
+
function yt(e) {
|
|
1581
1581
|
let { options: t } = e.editor;
|
|
1582
1582
|
return typeof t == "function" ? t(e.row.data) : t ?? [];
|
|
1583
1583
|
}
|
|
1584
|
-
function
|
|
1584
|
+
function bt(e) {
|
|
1585
1585
|
let { cell: t, row: n, columnIndex: i } = e, { grid: a } = t, o = R(), s = N(null), c = d("datagrid-cell-error"), { error: l, pending: u } = t;
|
|
1586
1586
|
r(() => {
|
|
1587
|
-
let e = s.current?.querySelector(
|
|
1587
|
+
let e = s.current?.querySelector(vt);
|
|
1588
1588
|
e?.focus(), e instanceof HTMLInputElement && e.type !== "checkbox" && e.select();
|
|
1589
1589
|
}, []);
|
|
1590
1590
|
let f = A(() => {
|
|
@@ -1630,7 +1630,7 @@ function xt(e) {
|
|
|
1630
1630
|
width: "fit",
|
|
1631
1631
|
height: "fit",
|
|
1632
1632
|
ai: "center",
|
|
1633
|
-
children: [/* @__PURE__ */ I(
|
|
1633
|
+
children: [/* @__PURE__ */ I(xt, {
|
|
1634
1634
|
cell: t,
|
|
1635
1635
|
errorId: l ? c : void 0,
|
|
1636
1636
|
onBlur: h,
|
|
@@ -1648,12 +1648,12 @@ function xt(e) {
|
|
|
1648
1648
|
})]
|
|
1649
1649
|
});
|
|
1650
1650
|
}
|
|
1651
|
-
function
|
|
1651
|
+
function xt(e) {
|
|
1652
1652
|
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 = {
|
|
1653
1653
|
"aria-label": t.grid.localeText.editCell(String(d)),
|
|
1654
1654
|
"aria-invalid": n ? !0 : void 0,
|
|
1655
1655
|
"aria-describedby": n
|
|
1656
|
-
}, m =
|
|
1656
|
+
}, m = Ee(Ne(o));
|
|
1657
1657
|
if (a) return /* @__PURE__ */ I(a, { cell: t });
|
|
1658
1658
|
if (o === "checkbox") return /* @__PURE__ */ I(v, {
|
|
1659
1659
|
checked: !!t.draft,
|
|
@@ -1677,12 +1677,12 @@ function St(e) {
|
|
|
1677
1677
|
t.setDraft(e ?? null), t.commitEdit(), i();
|
|
1678
1678
|
},
|
|
1679
1679
|
props: p,
|
|
1680
|
-
children:
|
|
1680
|
+
children: yt(t).map((e) => /* @__PURE__ */ I(w.Item, {
|
|
1681
1681
|
value: e.value,
|
|
1682
1682
|
children: e.label ?? String(e.value)
|
|
1683
1683
|
}, String(e.value)))
|
|
1684
1684
|
}) });
|
|
1685
|
-
if (
|
|
1685
|
+
if (Ne(o)) return m ? /* @__PURE__ */ I(m.DateEditor, {
|
|
1686
1686
|
cell: t,
|
|
1687
1687
|
label: p["aria-label"],
|
|
1688
1688
|
errorId: n,
|
|
@@ -1711,10 +1711,10 @@ function St(e) {
|
|
|
1711
1711
|
}
|
|
1712
1712
|
});
|
|
1713
1713
|
}
|
|
1714
|
-
|
|
1714
|
+
bt.displayName = "DataGridCellEditor";
|
|
1715
1715
|
//#endregion
|
|
1716
1716
|
//#region src/components/dataGrid/components/dataGridBooleanValue.tsx
|
|
1717
|
-
function
|
|
1717
|
+
function St(e) {
|
|
1718
1718
|
let { value: t, text: n } = e;
|
|
1719
1719
|
return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ I(m, {
|
|
1720
1720
|
viewBox: "0 0 16 16",
|
|
@@ -1735,26 +1735,26 @@ function Ct(e) {
|
|
|
1735
1735
|
children: t ? n.booleanTrue : n.booleanFalse
|
|
1736
1736
|
})] });
|
|
1737
1737
|
}
|
|
1738
|
-
|
|
1738
|
+
St.displayName = "DataGridBooleanValue";
|
|
1739
1739
|
//#endregion
|
|
1740
1740
|
//#region src/components/dataGrid/components/dataGridDateValue.tsx
|
|
1741
|
-
function
|
|
1741
|
+
function Ct(e, t) {
|
|
1742
1742
|
if (e.def.dateFormat) return e.def.dateFormat;
|
|
1743
1743
|
let { editor: n } = e.def, r = typeof n == "object" ? n.type : n;
|
|
1744
|
-
return r &&
|
|
1744
|
+
return r && Ne(r) ? r : t instanceof Date ? "datetime" : null;
|
|
1745
1745
|
}
|
|
1746
|
-
function
|
|
1747
|
-
let { value: t, format: n } = e, r =
|
|
1746
|
+
function wt(e) {
|
|
1747
|
+
let { value: t, format: n } = e, r = Ee(!0);
|
|
1748
1748
|
return r ? /* @__PURE__ */ I(r.DateValue, {
|
|
1749
1749
|
value: t,
|
|
1750
1750
|
format: n
|
|
1751
1751
|
}) : /* @__PURE__ */ I(F, { children: t instanceof Date ? t.toISOString() : t == null ? "" : String(t) });
|
|
1752
1752
|
}
|
|
1753
|
-
|
|
1753
|
+
wt.displayName = "DataGridDateValue";
|
|
1754
1754
|
//#endregion
|
|
1755
1755
|
//#region src/components/dataGrid/components/dataGridCellText.tsx
|
|
1756
|
-
function
|
|
1757
|
-
let { cell: t } = e, { value: n } = t, r =
|
|
1756
|
+
function Tt(e) {
|
|
1757
|
+
let { cell: t } = e, { value: n } = t, r = Ct(t.column, n);
|
|
1758
1758
|
return /* @__PURE__ */ I(_, {
|
|
1759
1759
|
component: `${t.grid.componentName}.body.cell.text`,
|
|
1760
1760
|
height: "fit",
|
|
@@ -1767,20 +1767,20 @@ function Et(e) {
|
|
|
1767
1767
|
textOverflow: "ellipsis",
|
|
1768
1768
|
overflow: "hidden",
|
|
1769
1769
|
textWrap: "nowrap",
|
|
1770
|
-
children: typeof n == "boolean" ? /* @__PURE__ */ I(
|
|
1770
|
+
children: typeof n == "boolean" ? /* @__PURE__ */ I(St, {
|
|
1771
1771
|
value: n,
|
|
1772
1772
|
text: t.grid.localeText
|
|
1773
|
-
}) : r ? /* @__PURE__ */ I(
|
|
1773
|
+
}) : r ? /* @__PURE__ */ I(wt, {
|
|
1774
1774
|
value: n,
|
|
1775
1775
|
format: r
|
|
1776
1776
|
}) : n
|
|
1777
1777
|
})
|
|
1778
1778
|
});
|
|
1779
1779
|
}
|
|
1780
|
-
|
|
1780
|
+
Tt.displayName = "DataGridCellText";
|
|
1781
1781
|
//#endregion
|
|
1782
1782
|
//#region src/components/dataGrid/components/dataGridCellTree.tsx
|
|
1783
|
-
function
|
|
1783
|
+
function Et(e) {
|
|
1784
1784
|
let { cell: t, row: n, children: r } = e, { hasChildren: i, treeExpanded: o, level: s } = n, c = n.grid.componentName, l = A((e) => {
|
|
1785
1785
|
e.stopPropagation(), n.toggleTree();
|
|
1786
1786
|
}, [n]), u = t.value == null || t.value === "" ? t.grid.localeText.unnamedRow(n.rowIndex + 1) : String(t.value);
|
|
@@ -1816,23 +1816,23 @@ function Dt(e) {
|
|
|
1816
1816
|
})]
|
|
1817
1817
|
});
|
|
1818
1818
|
}
|
|
1819
|
-
|
|
1819
|
+
Et.displayName = "DataGridCellTree";
|
|
1820
1820
|
//#endregion
|
|
1821
1821
|
//#region src/components/dataGrid/components/dataGridRow.tsx
|
|
1822
|
-
function
|
|
1823
|
-
let { row: t, index: n } = e, { selected: r, expandOnRowClick: i } = t, a = (R()?.headerRowCount ?? 0) + n, o =
|
|
1822
|
+
function Dt(e) {
|
|
1823
|
+
let { row: t, index: n } = e, { selected: r, expandOnRowClick: i } = t, a = (R()?.headerRowCount ?? 0) + n, o = W(t) ? t : void 0, s = o && t.grid.tree.columnKey, c = A(() => {
|
|
1824
1824
|
t.toggleDetail();
|
|
1825
1825
|
}, [t]), l = (e, n) => {
|
|
1826
|
-
if (e.editing) return /* @__PURE__ */ I(
|
|
1826
|
+
if (e.editing) return /* @__PURE__ */ I(bt, {
|
|
1827
1827
|
cell: e,
|
|
1828
1828
|
row: a,
|
|
1829
1829
|
columnIndex: n
|
|
1830
1830
|
});
|
|
1831
|
-
let r = t.placeholder && !e.column.isRowNumber ? /* @__PURE__ */ I(
|
|
1831
|
+
let r = t.placeholder && !e.column.isRowNumber ? /* @__PURE__ */ I(ht, {
|
|
1832
1832
|
cell: e,
|
|
1833
1833
|
columnIndex: n
|
|
1834
|
-
}) : e.column.Cell ? /* @__PURE__ */ I(e.column.Cell, { cell: e }) : /* @__PURE__ */ I(
|
|
1835
|
-
return !o || e.column.key !== s ? r : /* @__PURE__ */ I(
|
|
1834
|
+
}) : e.column.Cell ? /* @__PURE__ */ I(e.column.Cell, { cell: e }) : /* @__PURE__ */ I(Tt, { cell: e });
|
|
1835
|
+
return !o || e.column.key !== s ? r : /* @__PURE__ */ I(Et, {
|
|
1836
1836
|
cell: e,
|
|
1837
1837
|
row: o,
|
|
1838
1838
|
children: r
|
|
@@ -1862,27 +1862,27 @@ function Ot(e) {
|
|
|
1862
1862
|
}, e.column.key))
|
|
1863
1863
|
});
|
|
1864
1864
|
}
|
|
1865
|
-
|
|
1866
|
-
var
|
|
1865
|
+
Dt.displayName = "DataGridRow";
|
|
1866
|
+
var Ot = k(Dt);
|
|
1867
1867
|
//#endregion
|
|
1868
1868
|
//#region src/components/dataGrid/components/dataGridBody.tsx
|
|
1869
|
-
function
|
|
1870
|
-
return e instanceof
|
|
1869
|
+
function kt(e, t, n) {
|
|
1870
|
+
return e instanceof Ve ? /* @__PURE__ */ I(lt, {
|
|
1871
1871
|
row: e,
|
|
1872
1872
|
index: t,
|
|
1873
1873
|
version: n
|
|
1874
|
-
}, e.key) : e instanceof
|
|
1874
|
+
}, e.key) : e instanceof st ? /* @__PURE__ */ I(_t, {
|
|
1875
1875
|
row: e,
|
|
1876
1876
|
index: t,
|
|
1877
1877
|
version: n
|
|
1878
|
-
}, e.key) : /* @__PURE__ */ I(
|
|
1878
|
+
}, e.key) : /* @__PURE__ */ I(Ot, {
|
|
1879
1879
|
row: e,
|
|
1880
1880
|
index: t,
|
|
1881
1881
|
version: n
|
|
1882
1882
|
}, e.key);
|
|
1883
1883
|
}
|
|
1884
|
-
function
|
|
1885
|
-
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 = ae(() => d ? null :
|
|
1884
|
+
function At(e) {
|
|
1885
|
+
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 = ae(() => d ? null : G.take(f, o, i).map((e, n) => kt(e, i + n, t.rowVersion(e, i + n))), [
|
|
1886
1886
|
f,
|
|
1887
1887
|
t,
|
|
1888
1888
|
d,
|
|
@@ -1918,7 +1918,7 @@ function jt(e) {
|
|
|
1918
1918
|
props: { role: "rowgroup" },
|
|
1919
1919
|
style: { gridTemplateColumns: t.gridTemplateColumns.value },
|
|
1920
1920
|
children: m
|
|
1921
|
-
}), /* @__PURE__ */ I(
|
|
1921
|
+
}), /* @__PURE__ */ I(pt, {
|
|
1922
1922
|
grid: t,
|
|
1923
1923
|
version: t.headerVersion
|
|
1924
1924
|
})] }) : /* @__PURE__ */ L(a, {
|
|
@@ -1943,16 +1943,16 @@ function jt(e) {
|
|
|
1943
1943
|
},
|
|
1944
1944
|
children: m
|
|
1945
1945
|
})
|
|
1946
|
-
}), /* @__PURE__ */ I(
|
|
1946
|
+
}), /* @__PURE__ */ I(pt, {
|
|
1947
1947
|
grid: t,
|
|
1948
1948
|
version: t.headerVersion
|
|
1949
1949
|
})]
|
|
1950
1950
|
});
|
|
1951
1951
|
}
|
|
1952
|
-
|
|
1952
|
+
At.displayName = "DataGridBody";
|
|
1953
1953
|
//#endregion
|
|
1954
1954
|
//#region src/components/dataGrid/components/dataGridEmptyColumns.tsx
|
|
1955
|
-
function
|
|
1955
|
+
function jt(e) {
|
|
1956
1956
|
let { grid: t } = e;
|
|
1957
1957
|
return /* @__PURE__ */ I(_, {
|
|
1958
1958
|
component: `${t.componentName}.emptyColumns`,
|
|
@@ -2013,7 +2013,7 @@ function Mt(e) {
|
|
|
2013
2013
|
}
|
|
2014
2014
|
//#endregion
|
|
2015
2015
|
//#region src/utils/dataGrid/headerCellUtils.ts
|
|
2016
|
-
var
|
|
2016
|
+
var Mt;
|
|
2017
2017
|
(function(e) {
|
|
2018
2018
|
let t = e.CELL_SELECTOR = "[role=\"columnheader\"][aria-sort]", n = ".resizer", r = `button, input, a, [role="menu"], [role="separator"], ${n}`;
|
|
2019
2019
|
function i(e, t) {
|
|
@@ -2088,8 +2088,8 @@ var Nt;
|
|
|
2088
2088
|
} : e;
|
|
2089
2089
|
}
|
|
2090
2090
|
e.pause = u;
|
|
2091
|
-
})(
|
|
2092
|
-
var X =
|
|
2091
|
+
})(Mt ||= {});
|
|
2092
|
+
var X = Mt, Nt;
|
|
2093
2093
|
(function(e) {
|
|
2094
2094
|
function t(e, t) {
|
|
2095
2095
|
return (t?.type === "text" ? t.value : "") === (e.trim() ? e : "");
|
|
@@ -2116,16 +2116,16 @@ var X = Nt, Pt;
|
|
|
2116
2116
|
return t.valueTo === void 0 ? isNaN(r) : t.valueTo === r;
|
|
2117
2117
|
}
|
|
2118
2118
|
e.numberMatches = r;
|
|
2119
|
-
})(
|
|
2120
|
-
var Z =
|
|
2121
|
-
function
|
|
2119
|
+
})(Nt ||= {});
|
|
2120
|
+
var Z = Nt, Pt = 300;
|
|
2121
|
+
function Ft(e, t, n) {
|
|
2122
2122
|
let i = N(/* @__PURE__ */ new Map()), a = A(() => {
|
|
2123
2123
|
for (let e of i.current.values()) clearTimeout(e);
|
|
2124
2124
|
i.current.clear();
|
|
2125
2125
|
}, []), s = A((e, t) => {
|
|
2126
2126
|
clearTimeout(i.current.get(e)), i.current.set(e, setTimeout(() => {
|
|
2127
2127
|
i.current.delete(e), t();
|
|
2128
|
-
},
|
|
2128
|
+
}, Pt));
|
|
2129
2129
|
}, []);
|
|
2130
2130
|
M(() => a, [a]);
|
|
2131
2131
|
let c = o(() => {
|
|
@@ -2138,7 +2138,7 @@ function It(e, t, n) {
|
|
|
2138
2138
|
}
|
|
2139
2139
|
//#endregion
|
|
2140
2140
|
//#region src/components/dataGrid/components/dataGridColumnFilter.tsx
|
|
2141
|
-
function
|
|
2141
|
+
function It(e) {
|
|
2142
2142
|
let { label: t, onClear: n } = e;
|
|
2143
2143
|
return /* @__PURE__ */ I(h, {
|
|
2144
2144
|
clean: !0,
|
|
@@ -2163,8 +2163,8 @@ function Lt(e) {
|
|
|
2163
2163
|
})
|
|
2164
2164
|
});
|
|
2165
2165
|
}
|
|
2166
|
-
function
|
|
2167
|
-
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 } =
|
|
2166
|
+
function Lt({ column: e }) {
|
|
2167
|
+
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 } = Ft(t, (e) => Z.textMatches(a, e), (e) => o(e?.type === "text" ? e.value : "")), l = A((t) => {
|
|
2168
2168
|
let n = t.target.value;
|
|
2169
2169
|
o(n), s("value", () => e.setTextFilter(n));
|
|
2170
2170
|
}, [e, s]), u = A(() => {
|
|
@@ -2185,16 +2185,16 @@ function Rt({ column: e }) {
|
|
|
2185
2185
|
tabIndex: -1,
|
|
2186
2186
|
"aria-label": i.filterColumn(r)
|
|
2187
2187
|
}
|
|
2188
|
-
}), a && /* @__PURE__ */ I(
|
|
2188
|
+
}), a && /* @__PURE__ */ I(It, {
|
|
2189
2189
|
label: i.clearFilter(r),
|
|
2190
2190
|
onClear: u
|
|
2191
2191
|
})]
|
|
2192
2192
|
});
|
|
2193
2193
|
}
|
|
2194
|
-
function
|
|
2194
|
+
function Rt({ column: e }) {
|
|
2195
2195
|
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 = A((e) => {
|
|
2196
2196
|
s.current = e, o(e);
|
|
2197
|
-
}, []), { debounce: l, cancel: u } =
|
|
2197
|
+
}, []), { debounce: l, cancel: u } = Ft(t, (e) => Z.numberMatches(a, e), (e) => c(Z.numberDraft(e))), { operator: d, value: p, valueTo: m } = a, h = e.filterConfig, g = A(() => {
|
|
2198
2198
|
let { operator: t, value: n, valueTo: r } = s.current;
|
|
2199
2199
|
e.setNumberFilter(t, n, r);
|
|
2200
2200
|
}, [e]), v = A((e, t) => {
|
|
@@ -2284,7 +2284,7 @@ function zt({ column: e }) {
|
|
|
2284
2284
|
tabIndex: -1,
|
|
2285
2285
|
"aria-label": i.filterFrom(r)
|
|
2286
2286
|
}
|
|
2287
|
-
}), (p !== "" || m !== "") && /* @__PURE__ */ I(
|
|
2287
|
+
}), (p !== "" || m !== "") && /* @__PURE__ */ I(It, {
|
|
2288
2288
|
label: i.clearFilter(r),
|
|
2289
2289
|
onClear: C
|
|
2290
2290
|
})]
|
|
@@ -2327,18 +2327,18 @@ function zt({ column: e }) {
|
|
|
2327
2327
|
tabIndex: -1,
|
|
2328
2328
|
"aria-label": i.filterColumn(r)
|
|
2329
2329
|
}
|
|
2330
|
-
}), p !== "" && /* @__PURE__ */ I(
|
|
2330
|
+
}), p !== "" && /* @__PURE__ */ I(It, {
|
|
2331
2331
|
label: i.clearFilter(r),
|
|
2332
2332
|
onClear: C
|
|
2333
2333
|
})]
|
|
2334
2334
|
})]
|
|
2335
2335
|
});
|
|
2336
2336
|
}
|
|
2337
|
-
function
|
|
2338
|
-
let t =
|
|
2337
|
+
function zt({ column: e }) {
|
|
2338
|
+
let t = Ee(!0);
|
|
2339
2339
|
return t ? /* @__PURE__ */ I(t.DateFilter, { column: e }) : null;
|
|
2340
2340
|
}
|
|
2341
|
-
function
|
|
2341
|
+
function Bt({ column: e }) {
|
|
2342
2342
|
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 = A((t, n) => {
|
|
2343
2343
|
e.setMultiselectFilter(n);
|
|
2344
2344
|
}, [e]);
|
|
@@ -2379,21 +2379,21 @@ function Vt({ column: e }) {
|
|
|
2379
2379
|
}) })
|
|
2380
2380
|
});
|
|
2381
2381
|
}
|
|
2382
|
-
function
|
|
2382
|
+
function Vt(e) {
|
|
2383
2383
|
let { column: t } = e, n = t.filterConfig;
|
|
2384
2384
|
if (!n) return null;
|
|
2385
2385
|
switch (n.type) {
|
|
2386
|
-
case "number": return /* @__PURE__ */ I(
|
|
2387
|
-
case "multiselect": return /* @__PURE__ */ I(
|
|
2388
|
-
case "date": return /* @__PURE__ */ I(
|
|
2389
|
-
default: return /* @__PURE__ */ I(
|
|
2386
|
+
case "number": return /* @__PURE__ */ I(Rt, { column: t });
|
|
2387
|
+
case "multiselect": return /* @__PURE__ */ I(Bt, { column: t });
|
|
2388
|
+
case "date": return /* @__PURE__ */ I(zt, { column: t });
|
|
2389
|
+
default: return /* @__PURE__ */ I(Lt, { column: t });
|
|
2390
2390
|
}
|
|
2391
2391
|
}
|
|
2392
|
-
|
|
2392
|
+
Vt.displayName = "DataGridColumnFilter";
|
|
2393
2393
|
//#endregion
|
|
2394
2394
|
//#region src/components/dataGrid/components/dataGridFilterCell.tsx
|
|
2395
|
-
function
|
|
2396
|
-
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 } =
|
|
2395
|
+
function Ht(e) {
|
|
2396
|
+
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 } = z(R(), r, i), b = t.isGrouping || t.isRowNumber || t.isRowSelection;
|
|
2397
2397
|
return /* @__PURE__ */ I(_, {
|
|
2398
2398
|
ref: g,
|
|
2399
2399
|
component: `${n.componentName}.filter.cell`,
|
|
@@ -2416,13 +2416,13 @@ function Ut(e) {
|
|
|
2416
2416
|
insetInlineStart: l ? `var(${o})` : void 0,
|
|
2417
2417
|
insetInlineEnd: u ? `var(${s})` : void 0
|
|
2418
2418
|
},
|
|
2419
|
-
children: !b && c && /* @__PURE__ */ I(
|
|
2419
|
+
children: !b && c && /* @__PURE__ */ I(Vt, { column: t })
|
|
2420
2420
|
});
|
|
2421
2421
|
}
|
|
2422
|
-
|
|
2422
|
+
Ht.displayName = "DataGridFilterCell";
|
|
2423
2423
|
//#endregion
|
|
2424
2424
|
//#region src/components/dataGrid/components/dataGridFilterRow.tsx
|
|
2425
|
-
function
|
|
2425
|
+
function Ut(e) {
|
|
2426
2426
|
let { grid: t } = e;
|
|
2427
2427
|
if (!t.filter.hasFilterableColumns) return null;
|
|
2428
2428
|
let n = t.headerRows.value.length;
|
|
@@ -2432,7 +2432,7 @@ function Wt(e) {
|
|
|
2432
2432
|
role: "row",
|
|
2433
2433
|
"aria-rowindex": n + 1
|
|
2434
2434
|
},
|
|
2435
|
-
children: t.columns.value.visibleLeafs.map((e, r) => /* @__PURE__ */ I(
|
|
2435
|
+
children: t.columns.value.visibleLeafs.map((e, r) => /* @__PURE__ */ I(Ht, {
|
|
2436
2436
|
column: e,
|
|
2437
2437
|
grid: t,
|
|
2438
2438
|
row: n,
|
|
@@ -2440,10 +2440,10 @@ function Wt(e) {
|
|
|
2440
2440
|
}, e.uniqueKey))
|
|
2441
2441
|
});
|
|
2442
2442
|
}
|
|
2443
|
-
|
|
2443
|
+
Ut.displayName = "DataGridFilterRow";
|
|
2444
2444
|
//#endregion
|
|
2445
2445
|
//#region src/icons/sortIcon.tsx
|
|
2446
|
-
function
|
|
2446
|
+
function Wt(e) {
|
|
2447
2447
|
return /* @__PURE__ */ I(m, {
|
|
2448
2448
|
viewBox: "0 0 24 24",
|
|
2449
2449
|
width: "1.5rem",
|
|
@@ -2453,7 +2453,7 @@ function Gt(e) {
|
|
|
2453
2453
|
}
|
|
2454
2454
|
//#endregion
|
|
2455
2455
|
//#region src/icons/dotsIcon.tsx
|
|
2456
|
-
function
|
|
2456
|
+
function Gt(e) {
|
|
2457
2457
|
return /* @__PURE__ */ I(m, {
|
|
2458
2458
|
viewBox: "0 0 16 16",
|
|
2459
2459
|
width: "18",
|
|
@@ -2466,7 +2466,7 @@ function Kt(e) {
|
|
|
2466
2466
|
}
|
|
2467
2467
|
//#endregion
|
|
2468
2468
|
//#region src/icons/groupingIcon.tsx
|
|
2469
|
-
function
|
|
2469
|
+
function Kt(e) {
|
|
2470
2470
|
return /* @__PURE__ */ I(m, {
|
|
2471
2471
|
viewBox: "0 0 24 24",
|
|
2472
2472
|
width: "1.5rem",
|
|
@@ -2476,7 +2476,7 @@ function qt(e) {
|
|
|
2476
2476
|
}
|
|
2477
2477
|
//#endregion
|
|
2478
2478
|
//#region src/icons/pinIcon.tsx
|
|
2479
|
-
function
|
|
2479
|
+
function qt(e) {
|
|
2480
2480
|
return /* @__PURE__ */ I(m, {
|
|
2481
2481
|
viewBox: "0 0 1024 1024",
|
|
2482
2482
|
width: "1.5rem",
|
|
@@ -2486,7 +2486,7 @@ function Jt(e) {
|
|
|
2486
2486
|
}
|
|
2487
2487
|
//#endregion
|
|
2488
2488
|
//#region src/components/dataGrid/components/dataGridHeaderCellContextMenu.tsx
|
|
2489
|
-
function
|
|
2489
|
+
function Jt(e) {
|
|
2490
2490
|
let { side: t, left: n, right: r } = e;
|
|
2491
2491
|
return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ I(T, {
|
|
2492
2492
|
rtl: { display: "none" },
|
|
@@ -2496,21 +2496,21 @@ function Yt(e) {
|
|
|
2496
2496
|
children: t === "start" ? r : n
|
|
2497
2497
|
})] });
|
|
2498
2498
|
}
|
|
2499
|
-
function
|
|
2499
|
+
function Yt(e) {
|
|
2500
2500
|
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] = P(!1), S = N(null), C = N(null), w = N(!1), ee = i ? 3 : void 0, te = i ? void 0 : 3, E = ae(() => {
|
|
2501
2501
|
let e = (e) => /* @__PURE__ */ I(T, {
|
|
2502
2502
|
component: `${n.componentName}.header.cell.contextMenu.tooltip.item.icon`,
|
|
2503
2503
|
children: e
|
|
2504
|
-
}), r = (t) => e(/* @__PURE__ */ I(
|
|
2504
|
+
}), r = (t) => e(/* @__PURE__ */ I(Wt, {
|
|
2505
2505
|
width: "100%",
|
|
2506
2506
|
fill: "currentColor",
|
|
2507
2507
|
rotate: t
|
|
2508
|
-
})), i = (t, n) => e(/* @__PURE__ */ I(
|
|
2508
|
+
})), i = (t, n) => e(/* @__PURE__ */ I(qt, {
|
|
2509
2509
|
width: "100%",
|
|
2510
2510
|
fill: "currentColor",
|
|
2511
2511
|
rotate: t,
|
|
2512
2512
|
rtl: { rotate: n }
|
|
2513
|
-
})), o = e(/* @__PURE__ */ I(
|
|
2513
|
+
})), o = e(/* @__PURE__ */ I(Kt, {
|
|
2514
2514
|
width: "100%",
|
|
2515
2515
|
fill: "currentColor"
|
|
2516
2516
|
})), s = /* @__PURE__ */ I(a, { width: 4 });
|
|
@@ -2542,7 +2542,7 @@ function Xt(e) {
|
|
|
2542
2542
|
f.canPinStart && {
|
|
2543
2543
|
key: "pin-start",
|
|
2544
2544
|
icon: i(0, -90),
|
|
2545
|
-
label: /* @__PURE__ */ I(
|
|
2545
|
+
label: /* @__PURE__ */ I(Jt, {
|
|
2546
2546
|
side: "start",
|
|
2547
2547
|
left: m.pinLeft,
|
|
2548
2548
|
right: m.pinRight
|
|
@@ -2553,7 +2553,7 @@ function Xt(e) {
|
|
|
2553
2553
|
f.canPinEnd && {
|
|
2554
2554
|
key: "pin-end",
|
|
2555
2555
|
icon: i(-90, 0),
|
|
2556
|
-
label: /* @__PURE__ */ I(
|
|
2556
|
+
label: /* @__PURE__ */ I(Jt, {
|
|
2557
2557
|
side: "end",
|
|
2558
2558
|
left: m.pinLeft,
|
|
2559
2559
|
right: m.pinRight
|
|
@@ -2644,7 +2644,7 @@ function Xt(e) {
|
|
|
2644
2644
|
},
|
|
2645
2645
|
children: /* @__PURE__ */ I(T, {
|
|
2646
2646
|
component: `${n.componentName}.header.cell.contextMenu.icon`,
|
|
2647
|
-
children: /* @__PURE__ */ I(
|
|
2647
|
+
children: /* @__PURE__ */ I(Gt, { fill: "currentColor" })
|
|
2648
2648
|
})
|
|
2649
2649
|
}), /* @__PURE__ */ I(b, {
|
|
2650
2650
|
present: v,
|
|
@@ -2690,20 +2690,20 @@ function Xt(e) {
|
|
|
2690
2690
|
})]
|
|
2691
2691
|
});
|
|
2692
2692
|
}
|
|
2693
|
-
|
|
2693
|
+
Yt.displayName = "DataGridHeaderCellContextMenu";
|
|
2694
2694
|
//#endregion
|
|
2695
2695
|
//#region src/components/dataGrid/components/dataGridHeaderCellResizer.tsx
|
|
2696
|
-
var
|
|
2697
|
-
function
|
|
2696
|
+
var Xt = (e) => "touches" in e ? e.touches[0]?.pageX ?? 0 : e.pageX, Zt = 16, Qt = 150;
|
|
2697
|
+
function $t(e) {
|
|
2698
2698
|
let { column: t, controls: n } = e, r = t.grid.resizerStyle, i = t.headerCell, o = A((e) => {
|
|
2699
2699
|
let { grid: n } = t;
|
|
2700
|
-
e.type === "mousedown" && e.preventDefault(), t.beginResize(
|
|
2701
|
-
let r = new AbortController(), { signal: i } = r, a = 0, o =
|
|
2700
|
+
e.type === "mousedown" && e.preventDefault(), t.beginResize(Xt(e.nativeEvent));
|
|
2701
|
+
let r = new AbortController(), { signal: i } = r, a = 0, o = Xt(e.nativeEvent), s = () => {
|
|
2702
2702
|
t.applyResize(o), n.paintSizes();
|
|
2703
2703
|
}, c = n.resizeMode === "instant" ? (e) => {
|
|
2704
|
-
o =
|
|
2704
|
+
o = Xt(e), s();
|
|
2705
2705
|
} : (e) => {
|
|
2706
|
-
o =
|
|
2706
|
+
o = Xt(e), a ||= requestAnimationFrame(() => {
|
|
2707
2707
|
a = 0, s();
|
|
2708
2708
|
});
|
|
2709
2709
|
}, l = () => {
|
|
@@ -2728,7 +2728,7 @@ function en(e) {
|
|
|
2728
2728
|
let d = A((e) => {
|
|
2729
2729
|
switch (e.key) {
|
|
2730
2730
|
case "ArrowRight":
|
|
2731
|
-
t.moveResizer(
|
|
2731
|
+
t.moveResizer(Zt);
|
|
2732
2732
|
break;
|
|
2733
2733
|
case "ArrowLeft":
|
|
2734
2734
|
t.moveResizer(-16);
|
|
@@ -2741,7 +2741,7 @@ function en(e) {
|
|
|
2741
2741
|
break;
|
|
2742
2742
|
default: return;
|
|
2743
2743
|
}
|
|
2744
|
-
e.preventDefault(), l(), clearTimeout(s.current), s.current = setTimeout(u,
|
|
2744
|
+
e.preventDefault(), l(), clearTimeout(s.current), s.current = setTimeout(u, Qt);
|
|
2745
2745
|
}, [
|
|
2746
2746
|
t,
|
|
2747
2747
|
u,
|
|
@@ -2788,11 +2788,11 @@ function en(e) {
|
|
|
2788
2788
|
})
|
|
2789
2789
|
});
|
|
2790
2790
|
}
|
|
2791
|
-
|
|
2791
|
+
$t.displayName = "DataGridHeaderCellResizer";
|
|
2792
2792
|
//#endregion
|
|
2793
2793
|
//#region src/components/dataGrid/components/dataGridHeaderCell.tsx
|
|
2794
|
-
function
|
|
2795
|
-
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 } =
|
|
2794
|
+
function en(e) {
|
|
2795
|
+
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 } = z(R(), n, r), x = d("datagrid-columnheader"), S = N(null), C = A(() => {
|
|
2796
2796
|
i.toggleSelectAllRows();
|
|
2797
2797
|
}, [i]), w = t.isRowSelection ? /* @__PURE__ */ I(v, {
|
|
2798
2798
|
variant: "datagrid",
|
|
@@ -2856,7 +2856,7 @@ function tn(e) {
|
|
|
2856
2856
|
}),
|
|
2857
2857
|
c.isSorted && /* @__PURE__ */ I(a, {
|
|
2858
2858
|
ps: (t.inlineWidth ?? 0) < 58 ? 0 : 2,
|
|
2859
|
-
children: /* @__PURE__ */ I(
|
|
2859
|
+
children: /* @__PURE__ */ I(Wt, {
|
|
2860
2860
|
width: "16px",
|
|
2861
2861
|
rotate: c.sortDirection === "ASC" ? 0 : 180,
|
|
2862
2862
|
transition: "transform",
|
|
@@ -2870,18 +2870,18 @@ function tn(e) {
|
|
|
2870
2870
|
]
|
|
2871
2871
|
})
|
|
2872
2872
|
}),
|
|
2873
|
-
u && /* @__PURE__ */ I(
|
|
2873
|
+
u && /* @__PURE__ */ I($t, {
|
|
2874
2874
|
column: t,
|
|
2875
2875
|
controls: x
|
|
2876
2876
|
}),
|
|
2877
|
-
f && /* @__PURE__ */ I(
|
|
2877
|
+
f && /* @__PURE__ */ I(Yt, { column: t })
|
|
2878
2878
|
] })
|
|
2879
2879
|
});
|
|
2880
2880
|
}
|
|
2881
|
-
|
|
2881
|
+
en.displayName = "DataGridHeaderCell";
|
|
2882
2882
|
//#endregion
|
|
2883
2883
|
//#region src/components/dataGrid/components/dataGridHeader.tsx
|
|
2884
|
-
function
|
|
2884
|
+
function tn(e) {
|
|
2885
2885
|
let { grid: t } = e, n = N(null), [r, i] = P(X.INITIAL), o = t.headerHover === "sliding", s = (e) => {
|
|
2886
2886
|
let t = n.current;
|
|
2887
2887
|
if (!o || !t || e.pointerType === "touch") return;
|
|
@@ -2912,13 +2912,13 @@ function nn(e) {
|
|
|
2912
2912
|
role: "row",
|
|
2913
2913
|
"aria-rowindex": t + 1
|
|
2914
2914
|
},
|
|
2915
|
-
children: e.map((e, n) => /* @__PURE__ */ I(
|
|
2915
|
+
children: e.map((e, n) => /* @__PURE__ */ I(en, {
|
|
2916
2916
|
column: e,
|
|
2917
2917
|
row: t,
|
|
2918
2918
|
columnIndex: n
|
|
2919
2919
|
}, e.uniqueKey))
|
|
2920
2920
|
}, t)),
|
|
2921
|
-
/* @__PURE__ */ I(
|
|
2921
|
+
/* @__PURE__ */ I(Ut, { grid: t }),
|
|
2922
2922
|
o && u && /* @__PURE__ */ I(a, {
|
|
2923
2923
|
tag: "span",
|
|
2924
2924
|
component: `${t.componentName}.header.hover`,
|
|
@@ -2938,11 +2938,11 @@ function nn(e) {
|
|
|
2938
2938
|
]
|
|
2939
2939
|
});
|
|
2940
2940
|
}
|
|
2941
|
-
|
|
2942
|
-
var
|
|
2941
|
+
tn.displayName = "DataGridHeader";
|
|
2942
|
+
var nn = k(tn);
|
|
2943
2943
|
//#endregion
|
|
2944
2944
|
//#region src/components/dataGrid/components/dataGridLoader.tsx
|
|
2945
|
-
function
|
|
2945
|
+
function rn(e) {
|
|
2946
2946
|
let { grid: t } = e;
|
|
2947
2947
|
return /* @__PURE__ */ I(a, {
|
|
2948
2948
|
component: `${t.componentName}.loader`,
|
|
@@ -2957,23 +2957,23 @@ function an(e) {
|
|
|
2957
2957
|
})
|
|
2958
2958
|
});
|
|
2959
2959
|
}
|
|
2960
|
-
|
|
2960
|
+
rn.displayName = "DataGridLoader";
|
|
2961
2961
|
//#endregion
|
|
2962
2962
|
//#region src/components/dataGrid/components/dataGridContent.tsx
|
|
2963
|
-
function
|
|
2963
|
+
function an(e) {
|
|
2964
2964
|
let { grid: t } = e, n = N(null), [i, o] = P({
|
|
2965
2965
|
top: 0,
|
|
2966
2966
|
direction: "down"
|
|
2967
2967
|
}), s = N(null), c = A((e) => {
|
|
2968
2968
|
o((t) => e === t.top ? t : {
|
|
2969
2969
|
top: e,
|
|
2970
|
-
direction:
|
|
2970
|
+
direction: xe.directionOf(t.top, e, t.direction)
|
|
2971
2971
|
});
|
|
2972
2972
|
}, []), l = A((e) => {
|
|
2973
2973
|
s.current !== null && cancelAnimationFrame(s.current), s.current = requestAnimationFrame(() => {
|
|
2974
2974
|
s.current = null, se(() => c(e.target.scrollTop));
|
|
2975
2975
|
});
|
|
2976
|
-
}, [c]), { navigation: u, onKeyDown: d } =
|
|
2976
|
+
}, [c]), { navigation: u, onKeyDown: d } = Ke({
|
|
2977
2977
|
grid: t,
|
|
2978
2978
|
scrollerRef: n,
|
|
2979
2979
|
scroll: i,
|
|
@@ -3007,7 +3007,7 @@ function on(e) {
|
|
|
3007
3007
|
t.setContainerWidth(e.clientWidth), t.paintSizes();
|
|
3008
3008
|
});
|
|
3009
3009
|
return r.observe(e), () => r.disconnect();
|
|
3010
|
-
}, [t]), t.hasVisibleColumns ? /* @__PURE__ */ I(
|
|
3010
|
+
}, [t]), t.hasVisibleColumns ? /* @__PURE__ */ I(ye.Provider, {
|
|
3011
3011
|
value: u,
|
|
3012
3012
|
children: /* @__PURE__ */ L(a, {
|
|
3013
3013
|
ref: n,
|
|
@@ -3027,23 +3027,23 @@ function on(e) {
|
|
|
3027
3027
|
onPaste: m.onPaste
|
|
3028
3028
|
},
|
|
3029
3029
|
children: [
|
|
3030
|
-
/* @__PURE__ */ I(
|
|
3030
|
+
/* @__PURE__ */ I(nn, {
|
|
3031
3031
|
grid: t,
|
|
3032
3032
|
version: t.headerVersion
|
|
3033
3033
|
}),
|
|
3034
|
-
(t.props.loading || f.isLoading) && /* @__PURE__ */ I(
|
|
3035
|
-
/* @__PURE__ */ I(
|
|
3034
|
+
(t.props.loading || f.isLoading) && /* @__PURE__ */ I(rn, { grid: t }),
|
|
3035
|
+
/* @__PURE__ */ I(At, {
|
|
3036
3036
|
grid: t,
|
|
3037
3037
|
scroll: i
|
|
3038
3038
|
})
|
|
3039
3039
|
]
|
|
3040
3040
|
})
|
|
3041
|
-
}) : /* @__PURE__ */ I(
|
|
3041
|
+
}) : /* @__PURE__ */ I(jt, { grid: t });
|
|
3042
3042
|
}
|
|
3043
|
-
|
|
3043
|
+
an.displayName = "DataGridContent";
|
|
3044
3044
|
//#endregion
|
|
3045
3045
|
//#region src/components/dataGrid/components/dataGridDataSourceError.tsx
|
|
3046
|
-
function
|
|
3046
|
+
function on(e) {
|
|
3047
3047
|
let { grid: t } = e, { error: n } = t.source;
|
|
3048
3048
|
if (n === void 0) return null;
|
|
3049
3049
|
let r = n instanceof Error && n.message ? n.message : t.localeText.loadError;
|
|
@@ -3061,16 +3061,16 @@ function sn(e) {
|
|
|
3061
3061
|
})]
|
|
3062
3062
|
});
|
|
3063
3063
|
}
|
|
3064
|
-
|
|
3064
|
+
on.displayName = "DataGridDataSourceError";
|
|
3065
3065
|
//#endregion
|
|
3066
3066
|
//#region src/components/dataGrid/components/dataGridColumnGroups.tsx
|
|
3067
|
-
function
|
|
3067
|
+
function sn(e) {
|
|
3068
3068
|
let { grid: t } = e;
|
|
3069
3069
|
return t.groupColumns.size === 0 ? null : /* @__PURE__ */ L(_, {
|
|
3070
3070
|
component: `${t.componentName}.topBar.columnGroups`,
|
|
3071
3071
|
children: [/* @__PURE__ */ I(T, {
|
|
3072
3072
|
component: `${t.componentName}.topBar.columnGroups.icon`,
|
|
3073
|
-
children: /* @__PURE__ */ I(
|
|
3073
|
+
children: /* @__PURE__ */ I(Kt, {
|
|
3074
3074
|
width: "100%",
|
|
3075
3075
|
fill: "currentColor"
|
|
3076
3076
|
})
|
|
@@ -3095,10 +3095,10 @@ function cn(e) {
|
|
|
3095
3095
|
})] }, e.key))]
|
|
3096
3096
|
});
|
|
3097
3097
|
}
|
|
3098
|
-
|
|
3098
|
+
sn.displayName = "DataGridColumnGroups";
|
|
3099
3099
|
//#endregion
|
|
3100
3100
|
//#region src/icons/searchIcon.tsx
|
|
3101
|
-
function
|
|
3101
|
+
function cn(e) {
|
|
3102
3102
|
return /* @__PURE__ */ I(m, {
|
|
3103
3103
|
viewBox: "0 0 488.4 488.4",
|
|
3104
3104
|
width: "1.5rem",
|
|
@@ -3108,8 +3108,8 @@ function ln(e) {
|
|
|
3108
3108
|
}
|
|
3109
3109
|
//#endregion
|
|
3110
3110
|
//#region src/components/dataGrid/components/dataGridColumnsPanel.tsx
|
|
3111
|
-
var
|
|
3112
|
-
function
|
|
3111
|
+
var ln = 6;
|
|
3112
|
+
function un(e) {
|
|
3113
3113
|
let { grid: t } = e, { columnVisibility: n, localeText: r, componentName: i } = t, { visibleCount: o, total: s, hasHidden: c } = n, [l, u] = P(!1), [d, g] = P(""), _ = A((e) => {
|
|
3114
3114
|
u(e), e || g("");
|
|
3115
3115
|
}, []);
|
|
@@ -3153,7 +3153,7 @@ function dn(e) {
|
|
|
3153
3153
|
})
|
|
3154
3154
|
]
|
|
3155
3155
|
}),
|
|
3156
|
-
children: /* @__PURE__ */ I(
|
|
3156
|
+
children: /* @__PURE__ */ I(dn, {
|
|
3157
3157
|
grid: t,
|
|
3158
3158
|
open: l,
|
|
3159
3159
|
query: d,
|
|
@@ -3161,9 +3161,9 @@ function dn(e) {
|
|
|
3161
3161
|
})
|
|
3162
3162
|
}) });
|
|
3163
3163
|
}
|
|
3164
|
-
|
|
3165
|
-
function
|
|
3166
|
-
let { columnVisibility: i, localeText: o, componentName: s } = e, c = `${s}.topBar.columnVisibility`, l = N(null), u = N(null), d = i.total >
|
|
3164
|
+
un.displayName = "DataGridColumnsPanel";
|
|
3165
|
+
function dn({ grid: e, open: t, query: n, onQueryChange: r }) {
|
|
3166
|
+
let { columnVisibility: i, localeText: o, componentName: s } = e, c = `${s}.topBar.columnVisibility`, l = N(null), u = N(null), d = i.total > ln, f = i.search(n), p = i.sections(f), m = f.every((e) => e.visible), g = f.every((e) => !e.visible);
|
|
3167
3167
|
M(() => {
|
|
3168
3168
|
t && (u.current ?? l.current?.querySelector("input"))?.focus();
|
|
3169
3169
|
}, [t]);
|
|
@@ -3193,7 +3193,7 @@ function fn({ grid: e, open: t, query: n, onQueryChange: r }) {
|
|
|
3193
3193
|
component: `${c}.search`,
|
|
3194
3194
|
children: [/* @__PURE__ */ I(_, {
|
|
3195
3195
|
component: `${c}.searchIcon`,
|
|
3196
|
-
children: /* @__PURE__ */ I(
|
|
3196
|
+
children: /* @__PURE__ */ I(cn, {
|
|
3197
3197
|
fill: "currentColor",
|
|
3198
3198
|
width: "14px"
|
|
3199
3199
|
})
|
|
@@ -3263,18 +3263,18 @@ function fn({ grid: e, open: t, query: n, onQueryChange: r }) {
|
|
|
3263
3263
|
}
|
|
3264
3264
|
//#endregion
|
|
3265
3265
|
//#region src/components/dataGrid/components/dataGridExport.tsx
|
|
3266
|
-
function
|
|
3266
|
+
function fn(e) {
|
|
3267
3267
|
let { grid: t } = e, n = t.exportConfig, r = A(() => void t.exportCsv(n).then(() => t.reportInteraction("export", "csv", "toolbar"), () => void 0), [t, n]), i = A(() => void t.exportXlsx(n).then(() => t.reportInteraction("export", "xlsx", "toolbar"), () => void 0), [t, n]);
|
|
3268
3268
|
return n ? /* @__PURE__ */ L(_, {
|
|
3269
3269
|
component: `${t.componentName}.topBar.export`,
|
|
3270
3270
|
ai: "center",
|
|
3271
3271
|
gap: 2,
|
|
3272
|
-
children: [n.csv !== !1 && /* @__PURE__ */ I(
|
|
3272
|
+
children: [n.csv !== !1 && /* @__PURE__ */ I(pn, {
|
|
3273
3273
|
componentName: t.componentName,
|
|
3274
3274
|
onClick: r,
|
|
3275
3275
|
label: t.localeText.exportCsvLabel,
|
|
3276
3276
|
children: t.localeText.exportCsv
|
|
3277
|
-
}), n.xlsx !== !1 && /* @__PURE__ */ I(
|
|
3277
|
+
}), n.xlsx !== !1 && /* @__PURE__ */ I(pn, {
|
|
3278
3278
|
componentName: t.componentName,
|
|
3279
3279
|
onClick: i,
|
|
3280
3280
|
label: t.localeText.exportExcelLabel,
|
|
@@ -3282,8 +3282,8 @@ function pn(e) {
|
|
|
3282
3282
|
})]
|
|
3283
3283
|
}) : null;
|
|
3284
3284
|
}
|
|
3285
|
-
|
|
3286
|
-
function
|
|
3285
|
+
fn.displayName = "DataGridExport";
|
|
3286
|
+
function pn(e) {
|
|
3287
3287
|
let { componentName: t, onClick: n, label: r, children: i } = e;
|
|
3288
3288
|
return /* @__PURE__ */ L(h, {
|
|
3289
3289
|
component: `${t}.topBar.export.button`,
|
|
@@ -3309,8 +3309,8 @@ function mn(e) {
|
|
|
3309
3309
|
}
|
|
3310
3310
|
//#endregion
|
|
3311
3311
|
//#region src/components/dataGrid/components/dataGridGlobalFilter.tsx
|
|
3312
|
-
function
|
|
3313
|
-
let { grid: t } = e, [n, r] = P(t.globalFilterValue), { debounce: i, cancel: o } =
|
|
3312
|
+
function mn(e) {
|
|
3313
|
+
let { grid: t } = e, [n, r] = P(t.globalFilterValue), { debounce: i, cancel: o } = Ft(t.globalFilterValue, (e) => e === n, r), s = A((e) => {
|
|
3314
3314
|
let n = e.target.value;
|
|
3315
3315
|
r(n), i("value", () => t.filter.setGlobalFilter(n));
|
|
3316
3316
|
}, [t, i]), c = A(() => {
|
|
@@ -3335,7 +3335,7 @@ function hn(e) {
|
|
|
3335
3335
|
pointerEvents: "none",
|
|
3336
3336
|
color: "base-400",
|
|
3337
3337
|
theme: { dark: { color: "base-500" } },
|
|
3338
|
-
children: /* @__PURE__ */ I(
|
|
3338
|
+
children: /* @__PURE__ */ I(cn, {
|
|
3339
3339
|
fill: "currentColor",
|
|
3340
3340
|
width: "14px"
|
|
3341
3341
|
})
|
|
@@ -3372,7 +3372,7 @@ function hn(e) {
|
|
|
3372
3372
|
}
|
|
3373
3373
|
//#endregion
|
|
3374
3374
|
//#region src/components/dataGrid/components/dataGridTopBar.tsx
|
|
3375
|
-
function
|
|
3375
|
+
function hn(e) {
|
|
3376
3376
|
let { grid: t } = e, { title: n, topBarContent: r, globalFilter: i } = t.props.def;
|
|
3377
3377
|
return /* @__PURE__ */ L(_, {
|
|
3378
3378
|
component: `${t.componentName}.topBar`,
|
|
@@ -3397,15 +3397,15 @@ function gn(e) {
|
|
|
3397
3397
|
color: "base-800",
|
|
3398
3398
|
theme: { dark: { color: "base-100" } },
|
|
3399
3399
|
children: n
|
|
3400
|
-
}), /* @__PURE__ */ I(
|
|
3400
|
+
}), /* @__PURE__ */ I(sn, { grid: t })]
|
|
3401
3401
|
}), /* @__PURE__ */ L(_, {
|
|
3402
3402
|
ai: "center",
|
|
3403
3403
|
gap: 3,
|
|
3404
3404
|
flexWrap: "wrap",
|
|
3405
3405
|
children: [
|
|
3406
|
-
i && /* @__PURE__ */ I(
|
|
3407
|
-
/* @__PURE__ */ I(
|
|
3408
|
-
/* @__PURE__ */ I(
|
|
3406
|
+
i && /* @__PURE__ */ I(mn, { grid: t }),
|
|
3407
|
+
/* @__PURE__ */ I(un, { grid: t }),
|
|
3408
|
+
/* @__PURE__ */ I(fn, { grid: t })
|
|
3409
3409
|
]
|
|
3410
3410
|
})]
|
|
3411
3411
|
}), r && /* @__PURE__ */ I(a, {
|
|
@@ -3414,10 +3414,10 @@ function gn(e) {
|
|
|
3414
3414
|
})]
|
|
3415
3415
|
});
|
|
3416
3416
|
}
|
|
3417
|
-
|
|
3417
|
+
hn.displayName = "DataGridTopBar";
|
|
3418
3418
|
//#endregion
|
|
3419
3419
|
//#region src/utils/string/fuzzySearch.ts
|
|
3420
|
-
function
|
|
3420
|
+
function gn(e, t) {
|
|
3421
3421
|
if (!e) return {
|
|
3422
3422
|
score: 1,
|
|
3423
3423
|
matches: []
|
|
@@ -3430,12 +3430,12 @@ function _n(e, t) {
|
|
|
3430
3430
|
matches: o
|
|
3431
3431
|
});
|
|
3432
3432
|
}
|
|
3433
|
-
function
|
|
3434
|
-
return
|
|
3433
|
+
function _n(e, t) {
|
|
3434
|
+
return gn(e, t) !== null;
|
|
3435
3435
|
}
|
|
3436
3436
|
//#endregion
|
|
3437
3437
|
//#region src/components/dataGrid/components/dataGridCellRowDetail.tsx
|
|
3438
|
-
function
|
|
3438
|
+
function vn(e) {
|
|
3439
3439
|
let { cell: t } = e, n = t.isExpanded, r = A((e) => {
|
|
3440
3440
|
e.stopPropagation(), t.toggleDetail();
|
|
3441
3441
|
}, [t]);
|
|
@@ -3463,10 +3463,10 @@ function yn(e) {
|
|
|
3463
3463
|
})
|
|
3464
3464
|
});
|
|
3465
3465
|
}
|
|
3466
|
-
|
|
3466
|
+
vn.displayName = "DataGridCellRowDetail";
|
|
3467
3467
|
//#endregion
|
|
3468
3468
|
//#region src/components/dataGrid/components/dataGridCellRowSelection.tsx
|
|
3469
|
-
function
|
|
3469
|
+
function yn(e) {
|
|
3470
3470
|
let { cell: t } = e, n = A(() => {
|
|
3471
3471
|
t.toggleSelection();
|
|
3472
3472
|
}, [t]);
|
|
@@ -3481,15 +3481,15 @@ function bn(e) {
|
|
|
3481
3481
|
}
|
|
3482
3482
|
});
|
|
3483
3483
|
}
|
|
3484
|
-
|
|
3484
|
+
yn.displayName = "DataGridCellRowSelection";
|
|
3485
3485
|
//#endregion
|
|
3486
3486
|
//#region src/components/dataGrid/contracts/dataGridContract.ts
|
|
3487
|
-
function
|
|
3487
|
+
function bn(e) {
|
|
3488
3488
|
if (e) return e === "LEFT" ? "START" : e === "RIGHT" ? "END" : e;
|
|
3489
3489
|
}
|
|
3490
3490
|
//#endregion
|
|
3491
3491
|
//#region src/components/dataGrid/models/headerCellModel.ts
|
|
3492
|
-
var
|
|
3492
|
+
var xn = 1e3, Sn = class {
|
|
3493
3493
|
column;
|
|
3494
3494
|
constructor(e) {
|
|
3495
3495
|
this.column = e;
|
|
@@ -3502,7 +3502,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3502
3502
|
if (e.isRowNumber || e.isRowSelection) return null;
|
|
3503
3503
|
if (e.isGrouping) {
|
|
3504
3504
|
if (this.grid.groupColumns.size === 1) {
|
|
3505
|
-
let e = this.grid.groupColumns.values().next().value, t =
|
|
3505
|
+
let e = this.grid.groupColumns.values().next().value, t = G.findOrThrow(this.grid.columns.value.leafs, (t) => t.key === e);
|
|
3506
3506
|
return t.header ?? t.key;
|
|
3507
3507
|
}
|
|
3508
3508
|
return this.grid.localeText.groupHeader;
|
|
@@ -3566,7 +3566,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3566
3566
|
return Math.max(1, this.column.leafs.length) * this.grid.MIN_COLUMN_WIDTH_PX;
|
|
3567
3567
|
}
|
|
3568
3568
|
get maxWidth() {
|
|
3569
|
-
return Math.max(this.grid.containerWidth ||
|
|
3569
|
+
return Math.max(this.grid.containerWidth || xn, this.width, this.minWidth);
|
|
3570
3570
|
}
|
|
3571
3571
|
get paddingStart() {
|
|
3572
3572
|
if (!this.column.isRowSelection) return this.column.isEndAligned ? 10 : 3;
|
|
@@ -3652,16 +3652,16 @@ var Sn = 1e3, Cn = class {
|
|
|
3652
3652
|
pin: t.pin
|
|
3653
3653
|
} : r, n, this)) ?? [], this.isLeaf) {
|
|
3654
3654
|
let e = this.grid.columnWidths.get(this.key);
|
|
3655
|
-
this._inlineWidth = e ?? this.def.width ?? this.grid.DEFAULT_COLUMN_WIDTH_PX, this._pin =
|
|
3655
|
+
this._inlineWidth = e ?? this.def.width ?? this.grid.DEFAULT_COLUMN_WIDTH_PX, this._pin = bn(t.pin);
|
|
3656
3656
|
}
|
|
3657
3657
|
}
|
|
3658
3658
|
columns = [];
|
|
3659
3659
|
get kind() {
|
|
3660
3660
|
switch (this.key) {
|
|
3661
|
-
case
|
|
3662
|
-
case
|
|
3663
|
-
case
|
|
3664
|
-
case
|
|
3661
|
+
case Je: return "rowNumber";
|
|
3662
|
+
case Ye: return "rowSelection";
|
|
3663
|
+
case Xe: return "rowDetail";
|
|
3664
|
+
case K: return "grouping";
|
|
3665
3665
|
default: return "data";
|
|
3666
3666
|
}
|
|
3667
3667
|
}
|
|
@@ -3716,7 +3716,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3716
3716
|
insetInlineEnd: t ? `var(${this.inlineEndVarName})` : void 0
|
|
3717
3717
|
};
|
|
3718
3718
|
}, () => [this.pinFlags]);
|
|
3719
|
-
_headerCell = q(() => new
|
|
3719
|
+
_headerCell = q(() => new Sn(this));
|
|
3720
3720
|
get headerCell() {
|
|
3721
3721
|
return this._headerCell.value;
|
|
3722
3722
|
}
|
|
@@ -3892,16 +3892,16 @@ var Sn = 1e3, Cn = class {
|
|
|
3892
3892
|
get inlineWidth() {
|
|
3893
3893
|
if (this.isLeaf) return this.grid.getFlexWidth(this.key) ?? this._inlineWidth;
|
|
3894
3894
|
let e = this.visibleColumns.map((e) => e.inlineWidth).filter((e) => typeof e == "number");
|
|
3895
|
-
if (e.length !== 0) return
|
|
3895
|
+
if (e.length !== 0) return G.sumBy(e, (e) => e);
|
|
3896
3896
|
}
|
|
3897
3897
|
get startOffset() {
|
|
3898
3898
|
let e = 0;
|
|
3899
3899
|
if (this.parent) {
|
|
3900
3900
|
let { visibleColumns: t, startOffset: n } = this.parent, r = t.findIndex((e) => e === this);
|
|
3901
|
-
e +=
|
|
3901
|
+
e += G.sumBy(t, (e, t) => t < r ? e.inlineWidth ?? 0 : 0), e += n;
|
|
3902
3902
|
} else {
|
|
3903
3903
|
let t = this.grid.columns.value.start.filter((e) => e.isVisible), n = t.findIndex((e) => e === this);
|
|
3904
|
-
e +=
|
|
3904
|
+
e += G.sumBy(t, (e, t) => t < n ? e.inlineWidth ?? 0 : 0);
|
|
3905
3905
|
}
|
|
3906
3906
|
return e;
|
|
3907
3907
|
}
|
|
@@ -3909,10 +3909,10 @@ var Sn = 1e3, Cn = class {
|
|
|
3909
3909
|
let e = 0;
|
|
3910
3910
|
if (this.parent) {
|
|
3911
3911
|
let { visibleColumns: t } = this.parent, n = t.reverse(), r = n.findIndex((e) => e === this);
|
|
3912
|
-
e +=
|
|
3912
|
+
e += G.sumBy(n, (e, t) => t < r ? e.inlineWidth ?? 0 : 0), e += this.parent.endOffset;
|
|
3913
3913
|
} else {
|
|
3914
3914
|
let t = this.grid.columns.value.end.filter((e) => e.isVisible).reverse(), n = t.findIndex((e) => e === this);
|
|
3915
|
-
e +=
|
|
3915
|
+
e += G.sumBy(t, (e, t) => t < n ? e.inlineWidth ?? 0 : 0);
|
|
3916
3916
|
}
|
|
3917
3917
|
return e;
|
|
3918
3918
|
}
|
|
@@ -3950,7 +3950,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3950
3950
|
_resizeTotalWidth = 0;
|
|
3951
3951
|
beginResize = (e) => {
|
|
3952
3952
|
let { MIN_COLUMN_WIDTH_PX: t } = this.grid;
|
|
3953
|
-
this._resizeStartX = e, this._resizeSizes =
|
|
3953
|
+
this._resizeStartX = e, this._resizeSizes = G.toRecord(this.leafs, (e) => [e.key, e.inlineWidth ?? e.baseWidth]), this._resizeTotalWidth = G.sumBy(this.leafs, (e) => this._resizeSizes[e.key]) - this.leafs.length * t;
|
|
3954
3954
|
};
|
|
3955
3955
|
get resizeSign() {
|
|
3956
3956
|
return this.pin === "END" === this.grid.isRtl ? 1 : -1;
|
|
@@ -3980,7 +3980,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3980
3980
|
this.setPin(e), this.pin !== t && this.grid.reportInteraction("columnPinChange", this.pin, this.pin ? "pin" : "unpin", { columnKey: this.key });
|
|
3981
3981
|
};
|
|
3982
3982
|
setPin(e) {
|
|
3983
|
-
this.isLeaf ? this._pin =
|
|
3983
|
+
this.isLeaf ? this._pin = bn(e) : this.columns.forEach((t) => t.setPin(e)), this.grid.pinColumn(this.uniqueKey, e);
|
|
3984
3984
|
}
|
|
3985
3985
|
toggleGrouping = () => {
|
|
3986
3986
|
this.grid.toggleGrouping(this.key);
|
|
@@ -3995,7 +3995,7 @@ var Sn = 1e3, Cn = class {
|
|
|
3995
3995
|
toggleVisibility = () => {
|
|
3996
3996
|
this.grid.toggleColumnVisibility(this.key);
|
|
3997
3997
|
};
|
|
3998
|
-
},
|
|
3998
|
+
}, Cn = class {
|
|
3999
3999
|
grid;
|
|
4000
4000
|
constructor(e) {
|
|
4001
4001
|
this.grid = e;
|
|
@@ -4054,19 +4054,19 @@ var Sn = 1e3, Cn = class {
|
|
|
4054
4054
|
};
|
|
4055
4055
|
//#endregion
|
|
4056
4056
|
//#region src/utils/array/lazyList.ts
|
|
4057
|
-
function
|
|
4057
|
+
function wn(e, t) {
|
|
4058
4058
|
return new Proxy([], {
|
|
4059
4059
|
get(n, r, i) {
|
|
4060
4060
|
if (r === "length") return e;
|
|
4061
|
-
let a =
|
|
4061
|
+
let a = Tn(r, e);
|
|
4062
4062
|
return a === void 0 ? Reflect.get(n, r, i) : t(a);
|
|
4063
4063
|
},
|
|
4064
4064
|
has(t, n) {
|
|
4065
|
-
return
|
|
4065
|
+
return Tn(n, e) !== void 0 || Reflect.has(t, n);
|
|
4066
4066
|
},
|
|
4067
4067
|
getOwnPropertyDescriptor(n, r) {
|
|
4068
|
-
return
|
|
4069
|
-
value: t(
|
|
4068
|
+
return Tn(r, e) === void 0 ? Reflect.getOwnPropertyDescriptor(n, r) : {
|
|
4069
|
+
value: t(Tn(r, e)),
|
|
4070
4070
|
writable: !0,
|
|
4071
4071
|
enumerable: !0,
|
|
4072
4072
|
configurable: !0
|
|
@@ -4074,7 +4074,7 @@ function Tn(e, t) {
|
|
|
4074
4074
|
}
|
|
4075
4075
|
});
|
|
4076
4076
|
}
|
|
4077
|
-
function
|
|
4077
|
+
function Tn(e, t) {
|
|
4078
4078
|
if (typeof e != "string") return;
|
|
4079
4079
|
let n = Number(e);
|
|
4080
4080
|
return Number.isInteger(n) && n >= 0 && n < t ? n : void 0;
|
|
@@ -4205,7 +4205,7 @@ var $ = class e {
|
|
|
4205
4205
|
}), this.source.changed());
|
|
4206
4206
|
});
|
|
4207
4207
|
}
|
|
4208
|
-
},
|
|
4208
|
+
}, En = class extends st {
|
|
4209
4209
|
level;
|
|
4210
4210
|
levelIndex;
|
|
4211
4211
|
constructor(e, t, n, r, i = r) {
|
|
@@ -4228,7 +4228,7 @@ var $ = class e {
|
|
|
4228
4228
|
return [...this.level.groupKeys, this.groupValue];
|
|
4229
4229
|
}
|
|
4230
4230
|
get key() {
|
|
4231
|
-
return this.placeholder ? `${this.level.placeholderKey}-group-${this.levelIndex}` :
|
|
4231
|
+
return this.placeholder ? `${this.level.placeholderKey}-group-${this.levelIndex}` : Dn(this.groupKeys);
|
|
4232
4232
|
}
|
|
4233
4233
|
get depth() {
|
|
4234
4234
|
return this.level.depth;
|
|
@@ -4264,22 +4264,22 @@ var $ = class e {
|
|
|
4264
4264
|
this.placeholder || this.grid.toggleGroupRow(this.key);
|
|
4265
4265
|
}
|
|
4266
4266
|
};
|
|
4267
|
-
function
|
|
4267
|
+
function Dn(e) {
|
|
4268
4268
|
return `rb-group:${$.keyOf(e)}`;
|
|
4269
4269
|
}
|
|
4270
4270
|
//#endregion
|
|
4271
4271
|
//#region src/components/dataGrid/models/sourceRowModel.ts
|
|
4272
|
-
var
|
|
4272
|
+
var On = {}, kn = class extends U {
|
|
4273
4273
|
sourceLevel;
|
|
4274
4274
|
levelIndex;
|
|
4275
4275
|
constructor(e, t, n, r = n) {
|
|
4276
|
-
super(e,
|
|
4276
|
+
super(e, On, r), this.sourceLevel = t, this.levelIndex = n;
|
|
4277
4277
|
}
|
|
4278
4278
|
get row() {
|
|
4279
4279
|
return this.sourceLevel.rowAt(this.levelIndex);
|
|
4280
4280
|
}
|
|
4281
4281
|
get data() {
|
|
4282
|
-
return this.row ??
|
|
4282
|
+
return this.row ?? On;
|
|
4283
4283
|
}
|
|
4284
4284
|
get placeholder() {
|
|
4285
4285
|
return this.row === void 0;
|
|
@@ -4297,7 +4297,7 @@ var kn = {}, An = class extends H {
|
|
|
4297
4297
|
get selected() {
|
|
4298
4298
|
return !this.placeholder && super.selected;
|
|
4299
4299
|
}
|
|
4300
|
-
},
|
|
4300
|
+
}, An = class extends kn {
|
|
4301
4301
|
isTreeRow = !0;
|
|
4302
4302
|
get level() {
|
|
4303
4303
|
return this.sourceLevel.depth;
|
|
@@ -4317,7 +4317,7 @@ var kn = {}, An = class extends H {
|
|
|
4317
4317
|
toggleTree = () => {
|
|
4318
4318
|
this.hasChildren && this.grid.tree.toggle(this.key, this.level);
|
|
4319
4319
|
};
|
|
4320
|
-
},
|
|
4320
|
+
}, jn = 100, Mn = 40, Nn = class {
|
|
4321
4321
|
grid;
|
|
4322
4322
|
constructor(e) {
|
|
4323
4323
|
this.grid = e;
|
|
@@ -4343,11 +4343,11 @@ var kn = {}, An = class extends H {
|
|
|
4343
4343
|
}
|
|
4344
4344
|
get blockSize() {
|
|
4345
4345
|
let e = this.config?.blockSize;
|
|
4346
|
-
return e && e > 0 ? Math.floor(e) : this.grid.isPaginated ? this.grid.pageSize :
|
|
4346
|
+
return e && e > 0 ? Math.floor(e) : this.grid.isPaginated ? this.grid.pageSize : jn;
|
|
4347
4347
|
}
|
|
4348
4348
|
get maxBlocks() {
|
|
4349
4349
|
let e = this.config?.maxBlocks;
|
|
4350
|
-
return e && e > 0 ? Math.floor(e) :
|
|
4350
|
+
return e && e > 0 ? Math.floor(e) : Mn;
|
|
4351
4351
|
}
|
|
4352
4352
|
get queryVersion() {
|
|
4353
4353
|
return this._query;
|
|
@@ -4402,7 +4402,7 @@ var kn = {}, An = class extends H {
|
|
|
4402
4402
|
return e.loadedBlocks().forEach(({ index: a, rows: o }) => {
|
|
4403
4403
|
o.forEach((o, s) => {
|
|
4404
4404
|
let c = [...e.path, o[r]];
|
|
4405
|
-
if (!t.has(
|
|
4405
|
+
if (!t.has(Dn(c))) return;
|
|
4406
4406
|
let l = a * n + s;
|
|
4407
4407
|
i.push({
|
|
4408
4408
|
rowIndex: l,
|
|
@@ -4456,20 +4456,20 @@ var kn = {}, An = class extends H {
|
|
|
4456
4456
|
listLength = -1;
|
|
4457
4457
|
rowList() {
|
|
4458
4458
|
let { start: e } = this.visibleRange();
|
|
4459
|
-
return this.listLength = this.visibleLength(),
|
|
4459
|
+
return this.listLength = this.visibleLength(), wn(this.listLength, (t) => this.rowModelAt(e + t));
|
|
4460
4460
|
}
|
|
4461
4461
|
flatRowList(e) {
|
|
4462
4462
|
let t = this.detailPositions();
|
|
4463
|
-
return t.length === 0 ? e :
|
|
4464
|
-
let r =
|
|
4465
|
-
return t[r] === n ? new
|
|
4463
|
+
return t.length === 0 ? e : wn(e.length + t.length, (n) => {
|
|
4464
|
+
let r = Fn(t, n);
|
|
4465
|
+
return t[r] === n ? new Ve(this.grid, e[n - r - 1]) : e[n - r];
|
|
4466
4466
|
});
|
|
4467
4467
|
}
|
|
4468
4468
|
rowOffsets(e) {
|
|
4469
4469
|
let { rowHeight: t } = this.grid, n = this.detailPositions(), r = [0];
|
|
4470
4470
|
return n.forEach((t, n) => r.push(r[n] + e[t].heightForOffset)), {
|
|
4471
|
-
offsets:
|
|
4472
|
-
let i =
|
|
4471
|
+
offsets: wn(e.length, (e) => {
|
|
4472
|
+
let i = Fn(n, e);
|
|
4473
4473
|
return (e - i) * t + r[i];
|
|
4474
4474
|
}),
|
|
4475
4475
|
totalHeight: (e.length - n.length) * t + r[n.length]
|
|
@@ -4498,7 +4498,7 @@ var kn = {}, An = class extends H {
|
|
|
4498
4498
|
let i = this.levels.get(r);
|
|
4499
4499
|
!i || i.isGroupLevel || i.loadedBlocks().forEach(({ index: r, rows: i }) => {
|
|
4500
4500
|
i.forEach((i, a) => {
|
|
4501
|
-
let o =
|
|
4501
|
+
let o = Pn(n, r * t + a);
|
|
4502
4502
|
o !== void 0 && e(o, i);
|
|
4503
4503
|
});
|
|
4504
4504
|
});
|
|
@@ -4506,14 +4506,14 @@ var kn = {}, An = class extends H {
|
|
|
4506
4506
|
}
|
|
4507
4507
|
rowModelAt(e) {
|
|
4508
4508
|
let t = this.segmentAt(e);
|
|
4509
|
-
if (!t) return new
|
|
4509
|
+
if (!t) return new kn(this.grid, this.root, e);
|
|
4510
4510
|
let { level: n } = t, r = t.levelStart + (e - t.start), i = this.models.get(n.key);
|
|
4511
4511
|
i || this.models.set(n.key, i = /* @__PURE__ */ new Map());
|
|
4512
4512
|
let a = i.get(r);
|
|
4513
|
-
return a || (a = n.isGroupLevel ? new
|
|
4513
|
+
return a || (a = n.isGroupLevel ? new En(this.grid, n, this.groupColumnAt(n.depth), r) : this.isTree ? new An(this.grid, n, r) : new kn(this.grid, n, r), i.set(r, a)), a.rowIndex = e, a;
|
|
4514
4514
|
}
|
|
4515
4515
|
groupColumnAt(e) {
|
|
4516
|
-
return
|
|
4516
|
+
return G.findOrThrow(this.grid.columns.value.leafs, (t) => t.key === this.groupBy[e]);
|
|
4517
4517
|
}
|
|
4518
4518
|
visibleLength() {
|
|
4519
4519
|
let { start: e, end: t } = this.visibleRange();
|
|
@@ -4599,10 +4599,10 @@ var kn = {}, An = class extends H {
|
|
|
4599
4599
|
this._segments = void 0, this._byLevel = void 0, this.listLength !== this.visibleLength() && this.grid.rows.clear(), this.grid.flatRows.clear(), this.grid.notify();
|
|
4600
4600
|
}
|
|
4601
4601
|
};
|
|
4602
|
-
function
|
|
4602
|
+
function Pn(e, t) {
|
|
4603
4603
|
for (let n of e) if (t >= n.levelStart && t < n.levelStart + n.length) return n.start + (t - n.levelStart);
|
|
4604
4604
|
}
|
|
4605
|
-
function
|
|
4605
|
+
function Fn(e, t) {
|
|
4606
4606
|
let n = 0, r = e.length;
|
|
4607
4607
|
for (; n < r;) {
|
|
4608
4608
|
let i = n + r >>> 1;
|
|
@@ -4612,7 +4612,7 @@ function In(e, t) {
|
|
|
4612
4612
|
}
|
|
4613
4613
|
//#endregion
|
|
4614
4614
|
//#region src/components/dataGrid/models/exportModel.ts
|
|
4615
|
-
var
|
|
4615
|
+
var In = 7, Ln = class {
|
|
4616
4616
|
grid;
|
|
4617
4617
|
constructor(e) {
|
|
4618
4618
|
this.grid = e;
|
|
@@ -4626,7 +4626,7 @@ var Ln = 7, Rn = class {
|
|
|
4626
4626
|
}
|
|
4627
4627
|
width(e) {
|
|
4628
4628
|
let t = e.inlineWidth ?? this.grid.DEFAULT_COLUMN_WIDTH_PX;
|
|
4629
|
-
return Math.min(80, Math.max(6, Math.round(t /
|
|
4629
|
+
return Math.min(80, Math.max(6, Math.round(t / In * 10) / 10));
|
|
4630
4630
|
}
|
|
4631
4631
|
value(e, t) {
|
|
4632
4632
|
let { exportValue: n } = e.def, r = n ? n(t) : t[e.key];
|
|
@@ -4634,7 +4634,7 @@ var Ln = 7, Rn = class {
|
|
|
4634
4634
|
}
|
|
4635
4635
|
aggregateOf(e, t) {
|
|
4636
4636
|
let n = e.aggregate;
|
|
4637
|
-
return n ?
|
|
4637
|
+
return n ? rt(n, t.map((t) => this.value(e, t)), t) : null;
|
|
4638
4638
|
}
|
|
4639
4639
|
table(e = {}) {
|
|
4640
4640
|
let t = this.columns(e.columns), n = e.groups ?? !0, r = [], i = (e, a, o) => {
|
|
@@ -4649,7 +4649,7 @@ var Ln = 7, Rn = class {
|
|
|
4649
4649
|
}), i(s.rows, n ? a + 1 : a, o || n && e);
|
|
4650
4650
|
} else {
|
|
4651
4651
|
if (s.placeholder) continue;
|
|
4652
|
-
let e =
|
|
4652
|
+
let e = W(s) ? s.level : a;
|
|
4653
4653
|
r.push({
|
|
4654
4654
|
kind: "data",
|
|
4655
4655
|
level: e,
|
|
@@ -4698,7 +4698,7 @@ var Ln = 7, Rn = class {
|
|
|
4698
4698
|
let { title: t } = this.grid.props.def, n = typeof t == "string" && t.trim() ? t.trim() : this.grid.localeText.exportFileName;
|
|
4699
4699
|
return e.fileName?.trim() || n;
|
|
4700
4700
|
}
|
|
4701
|
-
},
|
|
4701
|
+
}, Rn = class {
|
|
4702
4702
|
grid;
|
|
4703
4703
|
constructor(e) {
|
|
4704
4704
|
this.grid = e;
|
|
@@ -4720,7 +4720,7 @@ var Ln = 7, Rn = class {
|
|
|
4720
4720
|
}
|
|
4721
4721
|
setGlobalFilter = (e) => this.grid.setGlobalFilter(e);
|
|
4722
4722
|
clearAllFilters = () => this.grid.clearAllFilters();
|
|
4723
|
-
},
|
|
4723
|
+
}, zn = class {
|
|
4724
4724
|
grid;
|
|
4725
4725
|
constructor(e) {
|
|
4726
4726
|
this.grid = e;
|
|
@@ -4859,23 +4859,23 @@ var Ln = 7, Rn = class {
|
|
|
4859
4859
|
describe(e, t) {
|
|
4860
4860
|
switch (t.type) {
|
|
4861
4861
|
case "text": return `“${t.value}”`;
|
|
4862
|
-
case "number": return t.operator === "between" ? `${t.value}–${t.valueTo ?? ""}` : `${
|
|
4862
|
+
case "number": return t.operator === "between" ? `${t.value}–${t.valueTo ?? ""}` : `${Vn[t.operator]} ${t.value}`;
|
|
4863
4863
|
case "multiselect": {
|
|
4864
4864
|
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(", ");
|
|
4865
4865
|
return r.length > 2 ? `${i} +${r.length - 2}` : i;
|
|
4866
4866
|
}
|
|
4867
|
-
case "date": return t.operator === "between" ?
|
|
4867
|
+
case "date": return t.operator === "between" ? Te()?.describeDay(t.value, t.valueTo ?? t.value) ?? `${t.value}–${t.valueTo ?? ""}` : `${Hn[t.operator]} ${Te()?.describeDay(t.value) ?? t.value}`;
|
|
4868
4868
|
}
|
|
4869
4869
|
}
|
|
4870
4870
|
_record = null;
|
|
4871
4871
|
get record() {
|
|
4872
4872
|
if (!this._record) return;
|
|
4873
4873
|
let e = this.grid.flatRows.value, { index: t, key: n } = this._record;
|
|
4874
|
-
if (
|
|
4874
|
+
if (Un(e[t]) && e[t].key === n) return e[t];
|
|
4875
4875
|
let r = -1;
|
|
4876
|
-
for (let t = 0; t < Math.min(e.length,
|
|
4876
|
+
for (let t = 0; t < Math.min(e.length, Bn) && r === -1; t++) {
|
|
4877
4877
|
let i = e[t];
|
|
4878
|
-
|
|
4878
|
+
Un(i) && i.key === n && (r = t);
|
|
4879
4879
|
}
|
|
4880
4880
|
if (r !== -1) return this._record = {
|
|
4881
4881
|
index: r,
|
|
@@ -4899,7 +4899,7 @@ var Ln = 7, Rn = class {
|
|
|
4899
4899
|
let t = this.grid.flatRows.value;
|
|
4900
4900
|
for (let n = this._record.index + e; n >= 0 && n < t.length; n += e) {
|
|
4901
4901
|
let e = t[n];
|
|
4902
|
-
if (
|
|
4902
|
+
if (Un(e) && !e.placeholder) return n;
|
|
4903
4903
|
}
|
|
4904
4904
|
return -1;
|
|
4905
4905
|
}
|
|
@@ -4926,30 +4926,30 @@ var Ln = 7, Rn = class {
|
|
|
4926
4926
|
total: this.grid.totalRowCount
|
|
4927
4927
|
};
|
|
4928
4928
|
let e = this.grid.flatRows.value, t = 0, n = 0;
|
|
4929
|
-
for (let r = 0; r < e.length; r++)
|
|
4929
|
+
for (let r = 0; r < e.length; r++) Un(e[r]) && (n++, r <= this._record.index && t++);
|
|
4930
4930
|
return {
|
|
4931
4931
|
position: t,
|
|
4932
4932
|
total: n
|
|
4933
4933
|
};
|
|
4934
4934
|
}
|
|
4935
|
-
},
|
|
4935
|
+
}, Bn = 1e4, Vn = {
|
|
4936
4936
|
eq: "=",
|
|
4937
4937
|
ne: "≠",
|
|
4938
4938
|
gt: ">",
|
|
4939
4939
|
gte: "≥",
|
|
4940
4940
|
lt: "<",
|
|
4941
4941
|
lte: "≤"
|
|
4942
|
-
},
|
|
4942
|
+
}, Hn = {
|
|
4943
4943
|
on: "=",
|
|
4944
4944
|
before: "<",
|
|
4945
4945
|
after: ">"
|
|
4946
4946
|
};
|
|
4947
|
-
function
|
|
4947
|
+
function Un(e) {
|
|
4948
4948
|
return !!e && e.kind === "row";
|
|
4949
4949
|
}
|
|
4950
4950
|
//#endregion
|
|
4951
4951
|
//#region src/components/dataGrid/models/localeText.ts
|
|
4952
|
-
var
|
|
4952
|
+
var Wn = {
|
|
4953
4953
|
searchPlaceholder: "Search...",
|
|
4954
4954
|
columnsMenu: "Columns",
|
|
4955
4955
|
columnsMenuLabel: (e, t) => `Columns, ${e} of ${t} shown`,
|
|
@@ -5046,7 +5046,7 @@ var Gn = {
|
|
|
5046
5046
|
selectedRows: (e) => `${e} selected`,
|
|
5047
5047
|
selectAll: "Select all",
|
|
5048
5048
|
selectionAnnouncement: (e, t) => e === 0 ? "No rows selected" : `${e} of ${t} rows selected`
|
|
5049
|
-
},
|
|
5049
|
+
}, Gn = class {
|
|
5050
5050
|
grid;
|
|
5051
5051
|
constructor(e) {
|
|
5052
5052
|
this.grid = e;
|
|
@@ -5102,16 +5102,16 @@ var Gn = {
|
|
|
5102
5102
|
let t = parseInt(e, 10);
|
|
5103
5103
|
isNaN(t) || this.grid.changePage(Math.max(1, Math.min(t, this.totalPages)));
|
|
5104
5104
|
};
|
|
5105
|
-
},
|
|
5106
|
-
function
|
|
5105
|
+
}, Kn = /["\t\r\n]/;
|
|
5106
|
+
function qn(e) {
|
|
5107
5107
|
if (e == null) return "";
|
|
5108
5108
|
let t = e instanceof Date ? e.toISOString() : String(e);
|
|
5109
|
-
return
|
|
5109
|
+
return Kn.test(t) ? `"${t.split("\"").join("\"\"")}"` : t;
|
|
5110
5110
|
}
|
|
5111
|
-
function
|
|
5112
|
-
return e.map((e) => e.map(
|
|
5111
|
+
function Jn(e) {
|
|
5112
|
+
return e.map((e) => e.map(qn).join(" ")).join("\r\n");
|
|
5113
5113
|
}
|
|
5114
|
-
function
|
|
5114
|
+
function Yn(e) {
|
|
5115
5115
|
let t = [], n = [], r = "", i = !1;
|
|
5116
5116
|
for (let a = 0; a < e.length; a++) {
|
|
5117
5117
|
let o = e[a];
|
|
@@ -5119,10 +5119,10 @@ function Xn(e) {
|
|
|
5119
5119
|
}
|
|
5120
5120
|
return (r !== "" || n.length > 0) && (n.push(r), t.push(n)), t;
|
|
5121
5121
|
}
|
|
5122
|
-
function
|
|
5122
|
+
function Xn(e, t) {
|
|
5123
5123
|
return e?.row === t?.row && e?.column === t?.column;
|
|
5124
5124
|
}
|
|
5125
|
-
var
|
|
5125
|
+
var Zn = class {
|
|
5126
5126
|
grid;
|
|
5127
5127
|
constructor(e) {
|
|
5128
5128
|
this.grid = e;
|
|
@@ -5168,7 +5168,7 @@ var Qn = class {
|
|
|
5168
5168
|
row: e,
|
|
5169
5169
|
column: t
|
|
5170
5170
|
}, i = n && this._anchor ? this._anchor : r;
|
|
5171
|
-
|
|
5171
|
+
Xn(this._focus, r) && Xn(this._anchor, i) || (this._anchor = i, this._focus = r, this.grid.notifyRows(), this.emit(n ? "extend" : "select"));
|
|
5172
5172
|
}
|
|
5173
5173
|
syncCurrent(e, t) {
|
|
5174
5174
|
this.isCurrent(e, t) || this.setCurrent(e, t);
|
|
@@ -5225,12 +5225,12 @@ var Qn = class {
|
|
|
5225
5225
|
this.grid.props.onRangeChange?.(this.range, { reason: e }), e === "extend" && !this._dragging && this.reportBlock();
|
|
5226
5226
|
}
|
|
5227
5227
|
reportBlock() {
|
|
5228
|
-
this.enabled && this._anchor && !
|
|
5228
|
+
this.enabled && this._anchor && !Xn(this._anchor, this._focus) && this.grid.reportInteraction("rangeChange", this.block, "extend");
|
|
5229
5229
|
}
|
|
5230
5230
|
onCopy = (e) => {
|
|
5231
5231
|
if (!this._focus || !e.clipboardData) return;
|
|
5232
5232
|
let t = e.currentTarget.ownerDocument.defaultView?.getSelection();
|
|
5233
|
-
t && !t.isCollapsed || (e.clipboardData.setData("text/plain",
|
|
5233
|
+
t && !t.isCollapsed || (e.clipboardData.setData("text/plain", Jn(this.values())), e.preventDefault(), this.grid.reportInteraction("copy", this.block, "copy"));
|
|
5234
5234
|
};
|
|
5235
5235
|
pasteBounds(e, t) {
|
|
5236
5236
|
let n = this.bounds;
|
|
@@ -5247,10 +5247,10 @@ var Qn = class {
|
|
|
5247
5247
|
if (!this._focus || !e.clipboardData || this.grid.edits.isOpen || !this.grid.edits.enabled) return;
|
|
5248
5248
|
let t = e.clipboardData.getData("text/plain");
|
|
5249
5249
|
if (!t) return;
|
|
5250
|
-
let n =
|
|
5250
|
+
let n = Yn(t), r = n.reduce((e, t) => Math.max(e, t.length), 0), i = this.pasteBounds(n.length, r);
|
|
5251
5251
|
i && (e.preventDefault(), this.grid.edits.paste(i, (e, t) => n[e % n.length][t % r] ?? ""));
|
|
5252
5252
|
};
|
|
5253
|
-
},
|
|
5253
|
+
}, Qn = class extends U {
|
|
5254
5254
|
node;
|
|
5255
5255
|
level;
|
|
5256
5256
|
position;
|
|
@@ -5301,10 +5301,10 @@ var Qn = class {
|
|
|
5301
5301
|
};
|
|
5302
5302
|
//#endregion
|
|
5303
5303
|
//#region src/components/dataGrid/models/treeModel.ts
|
|
5304
|
-
function
|
|
5304
|
+
function $n(e) {
|
|
5305
5305
|
return JSON.stringify(e);
|
|
5306
5306
|
}
|
|
5307
|
-
var
|
|
5307
|
+
var er = class {
|
|
5308
5308
|
grid;
|
|
5309
5309
|
constructor(e) {
|
|
5310
5310
|
this.grid = e;
|
|
@@ -5358,9 +5358,9 @@ var tr = class {
|
|
|
5358
5358
|
data: e,
|
|
5359
5359
|
children: []
|
|
5360
5360
|
};
|
|
5361
|
-
n.set(
|
|
5361
|
+
n.set($n(r), i);
|
|
5362
5362
|
let a;
|
|
5363
|
-
for (let e = r.length - 1; e > 0 && !a; e--) a = n.get(
|
|
5363
|
+
for (let e = r.length - 1; e > 0 && !a; e--) a = n.get($n(r.slice(0, e)));
|
|
5364
5364
|
(a ? a.children : t).push(i);
|
|
5365
5365
|
}), t;
|
|
5366
5366
|
}
|
|
@@ -5376,7 +5376,7 @@ var tr = class {
|
|
|
5376
5376
|
}
|
|
5377
5377
|
sortNodes(e) {
|
|
5378
5378
|
let { sortColumn: t, sortDirection: n } = this.grid;
|
|
5379
|
-
return t === void 0 ? e :
|
|
5379
|
+
return t === void 0 ? e : G.sortBy(e, (e) => e.data[t], n).map((e) => ({
|
|
5380
5380
|
data: e.data,
|
|
5381
5381
|
children: this.sortNodes(e.children)
|
|
5382
5382
|
}));
|
|
@@ -5406,7 +5406,7 @@ var tr = class {
|
|
|
5406
5406
|
}
|
|
5407
5407
|
rowList() {
|
|
5408
5408
|
let e = 0, t = (n, r, i) => n.map((a, o) => {
|
|
5409
|
-
let s = new
|
|
5409
|
+
let s = new Qn(this.grid, a, e++, r, o, n.length, i);
|
|
5410
5410
|
return s.treeExpanded && (s.children = t(a.children, r + 1, s)), s;
|
|
5411
5411
|
});
|
|
5412
5412
|
return t(this.nodes.value, 0);
|
|
@@ -5450,8 +5450,8 @@ var tr = class {
|
|
|
5450
5450
|
let r = this.expandedKeys();
|
|
5451
5451
|
this.grid.fire("expandedTreeKeysChange", r, n ? "expand" : "collapse", { details: { rowKey: e } }), this.grid.notify();
|
|
5452
5452
|
};
|
|
5453
|
-
},
|
|
5454
|
-
function
|
|
5453
|
+
}, tr = {};
|
|
5454
|
+
function nr(e) {
|
|
5455
5455
|
if (typeof e == "string" && /^\d{4}-\d{2}-\d{2}$/.test(e)) return e;
|
|
5456
5456
|
if (!(e instanceof Date) && typeof e != "string" && typeof e != "number") return null;
|
|
5457
5457
|
let t = e instanceof Date ? e : new Date(e);
|
|
@@ -5459,7 +5459,7 @@ function rr(e) {
|
|
|
5459
5459
|
let n = (e) => String(e).padStart(2, "0");
|
|
5460
5460
|
return `${String(t.getFullYear()).padStart(4, "0")}-${n(t.getMonth() + 1)}-${n(t.getDate())}`;
|
|
5461
5461
|
}
|
|
5462
|
-
var
|
|
5462
|
+
var rr = class t {
|
|
5463
5463
|
props;
|
|
5464
5464
|
constructor(e, t) {
|
|
5465
5465
|
this.props = e, t && this.listeners.add(t);
|
|
@@ -5531,7 +5531,7 @@ var ir = class t {
|
|
|
5531
5531
|
let e = this.props.def.localeText, t = this._localeText;
|
|
5532
5532
|
if (t && t.from === e) return t.text;
|
|
5533
5533
|
let n = {
|
|
5534
|
-
...
|
|
5534
|
+
...Wn,
|
|
5535
5535
|
...e
|
|
5536
5536
|
};
|
|
5537
5537
|
return this._localeText = {
|
|
@@ -5541,20 +5541,20 @@ var ir = class t {
|
|
|
5541
5541
|
}
|
|
5542
5542
|
sourceColumns = q(() => {
|
|
5543
5543
|
let { def: e } = this.props, t = [];
|
|
5544
|
-
if (this.groupColumns.size > 0 && t.push(new Q({ key:
|
|
5544
|
+
if (this.groupColumns.size > 0 && t.push(new Q({ key: K }, this)), t.push(...e.columns.map((e) => new Q(e, this))), e.rowSelection) {
|
|
5545
5545
|
let n = typeof e.rowSelection == "object" && e.rowSelection.pinned ? "START" : void 0;
|
|
5546
5546
|
t.unshift(new Q({
|
|
5547
|
-
key:
|
|
5547
|
+
key: Ye,
|
|
5548
5548
|
pin: n,
|
|
5549
5549
|
width: 50,
|
|
5550
5550
|
align: "center",
|
|
5551
|
-
Cell:
|
|
5551
|
+
Cell: yn
|
|
5552
5552
|
}, this));
|
|
5553
5553
|
}
|
|
5554
5554
|
if (e.showRowNumber) {
|
|
5555
5555
|
let n, r = 70;
|
|
5556
5556
|
typeof e.showRowNumber == "object" && (e.showRowNumber.pinned && (n = "START"), r = e.showRowNumber.width ?? 70), t.unshift(new Q({
|
|
5557
|
-
key:
|
|
5557
|
+
key: Je,
|
|
5558
5558
|
pin: n,
|
|
5559
5559
|
width: r,
|
|
5560
5560
|
align: "end"
|
|
@@ -5563,12 +5563,12 @@ var ir = class t {
|
|
|
5563
5563
|
if (e.rowDetail) {
|
|
5564
5564
|
let n = e.rowDetail.pinned ? "START" : void 0, r = e.rowDetail.expandColumnWidth ?? 50, i = e.rowDetail.expandColumnHeader ?? "";
|
|
5565
5565
|
t.unshift(new Q({
|
|
5566
|
-
key:
|
|
5566
|
+
key: Xe,
|
|
5567
5567
|
header: i,
|
|
5568
5568
|
pin: n,
|
|
5569
5569
|
width: r,
|
|
5570
5570
|
align: "center",
|
|
5571
|
-
Cell:
|
|
5571
|
+
Cell: vn
|
|
5572
5572
|
}, this));
|
|
5573
5573
|
}
|
|
5574
5574
|
return t;
|
|
@@ -5587,16 +5587,16 @@ var ir = class t {
|
|
|
5587
5587
|
leafs: i,
|
|
5588
5588
|
visibleLeafs: a,
|
|
5589
5589
|
userVisibleLeafs: a.filter((e) => ![
|
|
5590
|
-
|
|
5591
|
-
|
|
5592
|
-
|
|
5593
|
-
|
|
5590
|
+
Je,
|
|
5591
|
+
Ye,
|
|
5592
|
+
K,
|
|
5593
|
+
Xe
|
|
5594
5594
|
].includes(e.key)),
|
|
5595
|
-
maxDeath:
|
|
5595
|
+
maxDeath: G.maxBy(r, (e) => e.death) + 1
|
|
5596
5596
|
};
|
|
5597
5597
|
}, () => [this.sourceColumns]);
|
|
5598
|
-
headerRows = q(() =>
|
|
5599
|
-
let t =
|
|
5598
|
+
headerRows = q(() => G.sortBy(G.groupBy(this.columns.value.flat, (e) => e.death), (e) => e.key).map((e) => {
|
|
5599
|
+
let t = G.toRecord(G.groupBy(e.values, (e) => e.pin ?? "NO_PIN"), (e) => [e.key, e.values]);
|
|
5600
5600
|
return [
|
|
5601
5601
|
...t.START?.filter((e) => e.isVisible) ?? [],
|
|
5602
5602
|
...t.NO_PIN?.filter((e) => e.isVisible) ?? [],
|
|
@@ -5604,7 +5604,7 @@ var ir = class t {
|
|
|
5604
5604
|
];
|
|
5605
5605
|
}), () => [this.columns]);
|
|
5606
5606
|
gridTemplateColumns = q(() => {
|
|
5607
|
-
let { visibleLeafs: e } = this.columns.value, t =
|
|
5607
|
+
let { visibleLeafs: e } = this.columns.value, t = G.sumBy(e, (e) => +(e.pin === "END")), n = e.length - t;
|
|
5608
5608
|
return `${n > 0 ? `repeat(${n}, max-content)` : ""} ${t > 0 ? `repeat(${t}, max-content)` : ""}`.trim();
|
|
5609
5609
|
}, () => [this.columns]);
|
|
5610
5610
|
_globalFilterValue = "";
|
|
@@ -5627,7 +5627,7 @@ var ir = class t {
|
|
|
5627
5627
|
let t = this.globalFilterValue.trim();
|
|
5628
5628
|
return !t || this.globalFilterColumns.value.some((n) => {
|
|
5629
5629
|
let r = e[n];
|
|
5630
|
-
return r != null &&
|
|
5630
|
+
return r != null && _n(t, String(r));
|
|
5631
5631
|
});
|
|
5632
5632
|
}
|
|
5633
5633
|
matchesColumnFilters(e) {
|
|
@@ -5639,7 +5639,7 @@ var ir = class t {
|
|
|
5639
5639
|
}
|
|
5640
5640
|
matchesFilter(e, t) {
|
|
5641
5641
|
switch (t.type) {
|
|
5642
|
-
case "text": return !t.value.trim() || e != null &&
|
|
5642
|
+
case "text": return !t.value.trim() || e != null && _n(t.value, String(e));
|
|
5643
5643
|
case "number": {
|
|
5644
5644
|
if (e == null) return !1;
|
|
5645
5645
|
let n = typeof e == "number" ? e : parseFloat(String(e));
|
|
@@ -5657,7 +5657,7 @@ var ir = class t {
|
|
|
5657
5657
|
}
|
|
5658
5658
|
case "date": {
|
|
5659
5659
|
if (!t.value) return !0;
|
|
5660
|
-
let n =
|
|
5660
|
+
let n = nr(e);
|
|
5661
5661
|
if (!n) return !1;
|
|
5662
5662
|
switch (t.operator) {
|
|
5663
5663
|
case "on": return n === t.value;
|
|
@@ -5804,22 +5804,22 @@ var ir = class t {
|
|
|
5804
5804
|
n,
|
|
5805
5805
|
r,
|
|
5806
5806
|
this._sortDirection
|
|
5807
|
-
], () =>
|
|
5807
|
+
], () => G.sortBy(n, (e) => e[r], this._sortDirection));
|
|
5808
5808
|
}
|
|
5809
5809
|
if (this.groupColumns.size > 0) {
|
|
5810
5810
|
let t = (e, n) => {
|
|
5811
5811
|
let r = n.values().next().value;
|
|
5812
5812
|
n.delete(r);
|
|
5813
|
-
let i =
|
|
5814
|
-
return this._sortColumn === "grouping-cell" && (e =
|
|
5815
|
-
let a = n.size > 0 ? t(e.values, new Set(n)) : e.values.map((e, t) => new
|
|
5816
|
-
return new
|
|
5813
|
+
let i = G.findOrThrow(this.columns.value.leafs, (e) => e.key === r);
|
|
5814
|
+
return this._sortColumn === "grouping-cell" && (e = G.sortBy(e, (e) => e[r], this._sortDirection)), G.groupBy(e, (e) => e[r]).map((e, r) => {
|
|
5815
|
+
let a = n.size > 0 ? t(e.values, new Set(n)) : e.values.map((e, t) => new U(this, e, t));
|
|
5816
|
+
return new st(this, i, a, r, e.key);
|
|
5817
5817
|
});
|
|
5818
5818
|
};
|
|
5819
5819
|
return t(e, new Set(this.groupColumns));
|
|
5820
5820
|
}
|
|
5821
5821
|
let n = e;
|
|
5822
|
-
return t.reuse(this._rowModels, [n, this.props.def.rowKey], () => n.map((e, t) => new
|
|
5822
|
+
return t.reuse(this._rowModels, [n, this.props.def.rowKey], () => n.map((e, t) => new U(this, e, t)));
|
|
5823
5823
|
}, () => [this.columns]);
|
|
5824
5824
|
groupingSpan = q(() => {
|
|
5825
5825
|
let { visibleLeafs: e } = this.columns.value, t = e.findIndex((e) => e.isGrouping);
|
|
@@ -5845,14 +5845,14 @@ var ir = class t {
|
|
|
5845
5845
|
return typeof n == "number" && (e[t.widthVarName] = `${t.inlineWidth}px`), t.pin === "START" && (e[t.inlineStartVarName] = `${t.startOffset}px`), t.pin === "END" && (e[t.inlineEndVarName] = `${t.endOffset}px`), e;
|
|
5846
5846
|
}, {});
|
|
5847
5847
|
e[this.rowHeightVarName] = `${this.rowHeight}px`, e[this.inlineStartEdgeVarName] = `${this.inlineStartEdge}px`, this._containerWidth > 0 && (e[this.viewportWidthVarName] = `${this._containerWidth}px`);
|
|
5848
|
-
let { visibleLeafs: t } = this.columns.value, n = t.find((e) => e.key ===
|
|
5848
|
+
let { visibleLeafs: t } = this.columns.value, n = t.find((e) => e.key === K);
|
|
5849
5849
|
if (n) {
|
|
5850
|
-
let t =
|
|
5850
|
+
let t = G.sumBy(this.groupingSpan.value, (e) => e.inlineWidth ?? 0);
|
|
5851
5851
|
e[n.groupColumnWidthVarName] = `${t}px`;
|
|
5852
5852
|
}
|
|
5853
5853
|
return this.groupColumns.forEach((n) => {
|
|
5854
|
-
let r =
|
|
5855
|
-
e[r.groupColumnWidthVarName] = `${
|
|
5854
|
+
let r = G.findOrThrow(this.columns.value.leafs, (e) => e.key === n);
|
|
5855
|
+
e[r.groupColumnWidthVarName] = `${G.sumBy(t, (e) => e.pin === r.pin ? e.inlineWidth ?? 0 : 0)}px`;
|
|
5856
5856
|
}), e;
|
|
5857
5857
|
}, () => [this.columns, this.flexWidths]);
|
|
5858
5858
|
_containerWidth = 0;
|
|
@@ -5879,8 +5879,8 @@ var ir = class t {
|
|
|
5879
5879
|
flexWidths = q(() => {
|
|
5880
5880
|
let e = this._containerWidth;
|
|
5881
5881
|
if (e <= 0) return {};
|
|
5882
|
-
let t = this.columns.value.visibleLeafs, n = (e) => !e.isFlexible || this.columnWidths.has(e.key), r =
|
|
5883
|
-
if (o <= a) return
|
|
5882
|
+
let t = this.columns.value.visibleLeafs, n = (e) => !e.isFlexible || this.columnWidths.has(e.key), r = G.sumBy(t.filter(n), (e) => e.baseWidth), i = t.filter((e) => !n(e)), a = G.sumBy(i, (e) => e.baseWidth), o = e - r;
|
|
5883
|
+
if (o <= a) return G.toRecord(i, (e) => [e.key, e.baseWidth]);
|
|
5884
5884
|
let s = {}, c = 0;
|
|
5885
5885
|
return i.forEach((e, t) => {
|
|
5886
5886
|
if (t === i.length - 1) s[e.key] = o - c;
|
|
@@ -5956,29 +5956,29 @@ var ir = class t {
|
|
|
5956
5956
|
rowOffsets = q(() => {
|
|
5957
5957
|
if (this.source.enabled) return this.source.rowOffsets(this.flatRows.value);
|
|
5958
5958
|
let e = [], t = 0;
|
|
5959
|
-
for (let n of this.flatRows.value) e.push(t), t += n instanceof
|
|
5959
|
+
for (let n of this.flatRows.value) e.push(t), t += n instanceof Ve ? n.heightForOffset : this.rowHeight;
|
|
5960
5960
|
return {
|
|
5961
5961
|
offsets: e,
|
|
5962
5962
|
totalHeight: t
|
|
5963
5963
|
};
|
|
5964
5964
|
}, () => [this.flatRows]);
|
|
5965
|
-
viewport = new
|
|
5966
|
-
columnVisibility = new
|
|
5967
|
-
filter = new
|
|
5968
|
-
pagination = new
|
|
5969
|
-
aggregation = new
|
|
5970
|
-
exporter = new
|
|
5971
|
-
source = new
|
|
5972
|
-
tree = new
|
|
5973
|
-
edits = new
|
|
5974
|
-
range = new
|
|
5975
|
-
list = new
|
|
5965
|
+
viewport = new xe(this);
|
|
5966
|
+
columnVisibility = new Cn(this);
|
|
5967
|
+
filter = new Rn(this);
|
|
5968
|
+
pagination = new Gn(this);
|
|
5969
|
+
aggregation = new it(this);
|
|
5970
|
+
exporter = new Ln(this);
|
|
5971
|
+
source = new Nn(this);
|
|
5972
|
+
tree = new er(this);
|
|
5973
|
+
edits = new Be(this);
|
|
5974
|
+
range = new Zn(this);
|
|
5975
|
+
list = new zn(this);
|
|
5976
5976
|
refresh = () => {
|
|
5977
5977
|
this.edits.clearEdits(), this.source.invalidate();
|
|
5978
5978
|
};
|
|
5979
5979
|
get exportConfig() {
|
|
5980
5980
|
let e = this.props.def.export;
|
|
5981
|
-
if (e) return typeof e == "object" ? e :
|
|
5981
|
+
if (e) return typeof e == "object" ? e : tr;
|
|
5982
5982
|
}
|
|
5983
5983
|
exportCsv = async (e = {}) => {
|
|
5984
5984
|
let { downloadCsv: t } = await import("../gridExport.mjs");
|
|
@@ -6043,14 +6043,14 @@ var ir = class t {
|
|
|
6043
6043
|
return this.localeText.selectionAnnouncement(e, this.totalRowCount);
|
|
6044
6044
|
}
|
|
6045
6045
|
get groupedColumns() {
|
|
6046
|
-
return Array.from(this.groupColumns, (e) =>
|
|
6046
|
+
return Array.from(this.groupColumns, (e) => G.findOrThrow(this.columns.value.leafs, (t) => t.key === e));
|
|
6047
6047
|
}
|
|
6048
6048
|
selectedRows = /* @__PURE__ */ new Set();
|
|
6049
6049
|
get inlineStartEdge() {
|
|
6050
|
-
return
|
|
6050
|
+
return G.sumBy(this.columns.value.start, (e) => e.inlineWidth ?? 0);
|
|
6051
6051
|
}
|
|
6052
6052
|
get inlineEndEdge() {
|
|
6053
|
-
return
|
|
6053
|
+
return G.sumBy(this.columns.value.end, (e) => e.inlineWidth ?? 0);
|
|
6054
6054
|
}
|
|
6055
6055
|
inlineStartEdgeVarName = "--inline-start-edge";
|
|
6056
6056
|
rowHeightVarName = "--row-height";
|
|
@@ -6081,7 +6081,7 @@ var ir = class t {
|
|
|
6081
6081
|
}), this.source.invalidate(), this.tree.nodes.clear(), this.rows.clear(), this.notify();
|
|
6082
6082
|
};
|
|
6083
6083
|
pinColumn = (e, t) => {
|
|
6084
|
-
let n =
|
|
6084
|
+
let n = bn(t), r = G.findOrThrow(this.columns.value.flat, (t) => t.uniqueKey === e);
|
|
6085
6085
|
r.pin !== n && r.pinColumn(n), this.columns.clear(), this.notify();
|
|
6086
6086
|
};
|
|
6087
6087
|
toggleGrouping = (e) => {
|
|
@@ -6176,31 +6176,31 @@ var ir = class t {
|
|
|
6176
6176
|
};
|
|
6177
6177
|
//#endregion
|
|
6178
6178
|
//#region src/components/dataGrid/useGrid.ts
|
|
6179
|
-
function
|
|
6180
|
-
let [t] = P(() => new
|
|
6181
|
-
return t.setProps(e), t.setIdentifier(n),
|
|
6179
|
+
function ir(e) {
|
|
6180
|
+
let [t] = P(() => new rr(e)), n = d("datagrid");
|
|
6181
|
+
return t.setProps(e), t.setIdentifier(n), oe(t.subscribe, t.getSnapshot, t.getSnapshot), t;
|
|
6182
6182
|
}
|
|
6183
6183
|
//#endregion
|
|
6184
6184
|
//#region src/components/dataGrid/useListLayout.ts
|
|
6185
|
-
var
|
|
6186
|
-
function
|
|
6187
|
-
return
|
|
6185
|
+
var ar, or;
|
|
6186
|
+
function sr() {
|
|
6187
|
+
return or ??= import("../dataGridList.mjs").then((e) => ar = e.default), or;
|
|
6188
6188
|
}
|
|
6189
|
-
n("(max-width: 36rem)")?.matches &&
|
|
6190
|
-
function
|
|
6191
|
-
let [t, n] = P(() =>
|
|
6189
|
+
n("(max-width: 36rem)")?.matches && sr();
|
|
6190
|
+
function cr(e) {
|
|
6191
|
+
let [t, n] = P(() => ar);
|
|
6192
6192
|
return M(() => {
|
|
6193
6193
|
if (!e || t) return;
|
|
6194
6194
|
let r = !0;
|
|
6195
|
-
return
|
|
6195
|
+
return sr().then((e) => r && n(() => e)), () => {
|
|
6196
6196
|
r = !1;
|
|
6197
6197
|
};
|
|
6198
6198
|
}, [e, t]), t;
|
|
6199
6199
|
}
|
|
6200
6200
|
//#endregion
|
|
6201
6201
|
//#region src/components/dataGrid.tsx
|
|
6202
|
-
function
|
|
6203
|
-
let n =
|
|
6202
|
+
function lr(e, t) {
|
|
6203
|
+
let n = ir(e), i = N(null);
|
|
6204
6204
|
re(t, () => ({
|
|
6205
6205
|
get element() {
|
|
6206
6206
|
return i.current;
|
|
@@ -6221,7 +6221,7 @@ function ur(e, t) {
|
|
|
6221
6221
|
let t = new ResizeObserver(() => n.list.setWidth(e.clientWidth));
|
|
6222
6222
|
return t.observe(e), () => t.disconnect();
|
|
6223
6223
|
}, [n]);
|
|
6224
|
-
let A = n.list.active, j =
|
|
6224
|
+
let A = n.list.active, j = cr(A);
|
|
6225
6225
|
return /* @__PURE__ */ L(a, {
|
|
6226
6226
|
ref: i,
|
|
6227
6227
|
component: n.componentName,
|
|
@@ -6232,17 +6232,17 @@ function ur(e, t) {
|
|
|
6232
6232
|
...O
|
|
6233
6233
|
},
|
|
6234
6234
|
children: [j && A ? /* @__PURE__ */ I(j, { grid: n }) : /* @__PURE__ */ L(F, { children: [
|
|
6235
|
-
n.props.def.topBar && /* @__PURE__ */ I(
|
|
6236
|
-
/* @__PURE__ */ I(sn, { grid: n }),
|
|
6235
|
+
n.props.def.topBar && /* @__PURE__ */ I(hn, { grid: n }),
|
|
6237
6236
|
/* @__PURE__ */ I(on, { grid: n }),
|
|
6238
|
-
|
|
6237
|
+
/* @__PURE__ */ I(an, { grid: n }),
|
|
6238
|
+
n.props.def.bottomBar && /* @__PURE__ */ I(ve, { grid: n })
|
|
6239
6239
|
] }), /* @__PURE__ */ I(g, {
|
|
6240
6240
|
props: { role: "status" },
|
|
6241
6241
|
children: n.selectionAnnouncement
|
|
6242
6242
|
})]
|
|
6243
6243
|
});
|
|
6244
6244
|
}
|
|
6245
|
-
var
|
|
6246
|
-
|
|
6245
|
+
var ur = k(O(lr));
|
|
6246
|
+
lr.displayName = "DataGrid";
|
|
6247
6247
|
//#endregion
|
|
6248
|
-
export {
|
|
6248
|
+
export { Wn as DATA_GRID_LOCALE_TEXT, rn as a, Z as c, bt as d, ur as default, Y as f, on as i, wt as l, Ee as m, un as n, Wt as o, W as p, cn as r, Ft as s, fn as t, Ct as u };
|