@slotted/react 0.1.0-beta.11 → 0.1.0-beta.12

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.
@@ -216,10 +216,10 @@ function An({ index: e, measure: t, node: n, rowIndex: r }) {
216
216
  ...c ? { "data-disabled": "" } : {},
217
217
  ...f ? { "data-editing": "" } : {},
218
218
  children: [
219
- o.columnIds.includes("__selection") ? /* @__PURE__ */ w(Mn, { rowKey: i }) : null,
220
- o.columnIds.includes("__drag") ? /* @__PURE__ */ w(O, { node: n }) : null,
221
- o.columnIds.includes("__expander") ? /* @__PURE__ */ w(Nn, { node: n }) : null,
222
- o.mountedColumns.map((e) => /* @__PURE__ */ w(k, {
219
+ o.columnIds.includes("__selection") ? /* @__PURE__ */ w(O, { rowKey: i }) : null,
220
+ o.columnIds.includes("__drag") ? /* @__PURE__ */ w(Mn, { node: n }) : null,
221
+ o.columnIds.includes("__expander") ? /* @__PURE__ */ w(k, { node: n }) : null,
222
+ o.mountedColumns.map((e) => /* @__PURE__ */ w(Nn, {
223
223
  column: e,
224
224
  node: n
225
225
  }, e.id)),
@@ -243,7 +243,7 @@ function An({ index: e, measure: t, node: n, rowIndex: r }) {
243
243
  }) : null] });
244
244
  }
245
245
  var jn = Ie(An);
246
- function Mn({ rowKey: e }) {
246
+ function O({ rowKey: e }) {
247
247
  let t = D(), n = {
248
248
  row: e,
249
249
  column: un
@@ -280,7 +280,7 @@ function Mn({ rowKey: e }) {
280
280
  })
281
281
  });
282
282
  }
283
- function O({ node: e }) {
283
+ function Mn({ node: e }) {
284
284
  let t = D(), i = {
285
285
  row: e.key,
286
286
  column: fn
@@ -312,7 +312,7 @@ function O({ node: e }) {
312
312
  })
313
313
  });
314
314
  }
315
- function Nn({ node: e }) {
315
+ function k({ node: e }) {
316
316
  let t = D(), i = {
317
317
  row: e.key,
318
318
  column: dn
@@ -345,7 +345,7 @@ function Nn({ node: e }) {
345
345
  }) : null
346
346
  });
347
347
  }
348
- function k({ column: e, node: t }) {
348
+ function Nn({ column: e, node: t }) {
349
349
  let i = D(), a = t.key, o = {
350
350
  row: a,
351
351
  column: e.id
@@ -857,19 +857,19 @@ var Yn = [
857
857
  "boolean",
858
858
  "set"
859
859
  ];
860
- function Xn(e) {
860
+ function A(e) {
861
861
  return Yn.includes(e.kind) ? e.kind : null;
862
862
  }
863
- function A(e, t) {
863
+ function j(e, t) {
864
864
  return on(e) === on(t);
865
865
  }
866
- var j = [
866
+ var Xn = [
867
867
  "date",
868
868
  "time",
869
869
  "datetime"
870
870
  ];
871
871
  function Zn(e, t) {
872
- return nn(t) === 2 && j.includes(e);
872
+ return nn(t) === 2 && Xn.includes(e);
873
873
  }
874
874
  function Qn({ kind: e, start: t, end: n, onChange: r, t: i, locale: a, variant: o, autoFocus: s }) {
875
875
  let c = {
@@ -1009,7 +1009,7 @@ function $n({ autoFocus: e, column: t, counts: n, kind: r, label: i, t: a, local
1009
1009
  }
1010
1010
  }
1011
1011
  function er({ column: e, children: t }) {
1012
- let n = D(), r = Xn(e), i = n.filterOpen === e.id && r !== null, a = n.filterOf(e.id), o = n.t, s = S(null), c = y((e) => {
1012
+ let n = D(), r = A(e), i = n.filterOpen === e.id && r !== null, a = n.filterOf(e.id), o = n.t, s = S(null), c = y((e) => {
1013
1013
  s.current = e;
1014
1014
  }, []), u = y(() => r ? Qt(r) : null, [r]), [d, f] = C(a ?? u()), p = S(!1);
1015
1015
  if (b(() => {
@@ -1028,7 +1028,7 @@ function er({ column: e, children: t }) {
1028
1028
  }
1029
1029
  function ce(t, r) {
1030
1030
  let i = tn(v);
1031
- A(i, a) || n.setFilter(e.id, i, r, t), n.announce(i ? o("filterApplied", {
1031
+ j(i, a) || n.setFilter(e.id, i, r, t), n.announce(i ? o("filterApplied", {
1032
1032
  column: h,
1033
1033
  filter: Zt(i, g)
1034
1034
  }) : o("filterCleared", { column: h })), se();
@@ -1192,7 +1192,7 @@ function er({ column: e, children: t }) {
1192
1192
  });
1193
1193
  }
1194
1194
  function tr({ column: e }) {
1195
- let t = D(), n = Xn(e), r = t.columnIds.indexOf(e.id) + 1, o = {
1195
+ let t = D(), n = A(e), r = t.columnIds.indexOf(e.id) + 1, o = {
1196
1196
  row: ct,
1197
1197
  column: e.id
1198
1198
  }, l = t.current !== null && t.current.row === ct && t.current.column === e.id, u = t.filterOf(e.id), d = t.t, f = u?.conditions[0] ?? null, [p, m] = C(f?.operator ?? (n ? Xt(n) : "contains")), [h, g] = C({
@@ -1236,7 +1236,7 @@ function tr({ column: e }) {
1236
1236
  end: n.end
1237
1237
  }]
1238
1238
  });
1239
- A(i, u) || t.setFilter(e.id, i, r, void 0);
1239
+ j(i, u) || t.setFilter(e.id, i, r, void 0);
1240
1240
  }
1241
1241
  function ae(e, r) {
1242
1242
  g(e), clearTimeout(_.current);
@@ -1352,8 +1352,8 @@ function tr({ column: e }) {
1352
1352
  }
1353
1353
  //#endregion
1354
1354
  //#region src/data-grid/data-grid-header.tsx
1355
- var nr = 4;
1356
- function rr({ columnGroups: e, headerRowCount: t }) {
1355
+ var M = 4;
1356
+ function nr({ columnGroups: e, headerRowCount: t }) {
1357
1357
  let n = D(), r = n.columnIds.length - n.resolved.length, i = e !== void 0 && e.length > 0;
1358
1358
  return /* @__PURE__ */ T("div", {
1359
1359
  "data-part": "head",
@@ -1365,7 +1365,7 @@ function rr({ columnGroups: e, headerRowCount: t }) {
1365
1365
  "data-part": "header-row",
1366
1366
  "data-part-header-row": "",
1367
1367
  role: "row",
1368
- children: M(n.mountedColumns, e, r)
1368
+ children: rr(n.mountedColumns, e, r)
1369
1369
  }) : null,
1370
1370
  /* @__PURE__ */ T("div", {
1371
1371
  "aria-rowindex": i ? 2 : 1,
@@ -1443,7 +1443,7 @@ function rr({ columnGroups: e, headerRowCount: t }) {
1443
1443
  ]
1444
1444
  });
1445
1445
  }
1446
- function M(e, t, n) {
1446
+ function rr(e, t, n) {
1447
1447
  let r = [], i = 0;
1448
1448
  for (; i < e.length;) {
1449
1449
  let a = e[i], o = t.find((e) => e.columns.includes(a.id)), s = 1;
@@ -1635,7 +1635,7 @@ function lr({ column: e, descriptionId: t, open: l }) {
1635
1635
  finalFocus: m ? u.menuAnchor.returnTo : void 0,
1636
1636
  onOpenChange: (t) => u.setMenuOpen(t ? e.id : null),
1637
1637
  open: l,
1638
- sideOffset: nr,
1638
+ sideOffset: M,
1639
1639
  size: "sm",
1640
1640
  children: [/* @__PURE__ */ w(s, { render: (e) => /* @__PURE__ */ w("button", {
1641
1641
  ...Me(e, "part", "column-menu"),
@@ -1718,20 +1718,19 @@ function lr({ column: e, descriptionId: t, open: l }) {
1718
1718
  function ur({ column: e }) {
1719
1719
  let t = D(), [n, r] = C(null), i = S(n);
1720
1720
  i.current = n;
1721
- let a = S(null), o = S(null), s = t.resizeMode === "deferred";
1721
+ let a = S(null), o = S(null);
1722
1722
  b(() => {
1723
1723
  if (!n) return;
1724
- let i = (i) => {
1725
- i.key === "Escape" && (i.preventDefault(), i.stopPropagation(), s || t.resizeTo(e.id, n.startWidth, "pointer"), o.current = null, r(null), t.setResizing(null));
1724
+ let e = (e) => {
1725
+ e.key === "Escape" && (e.preventDefault(), e.stopPropagation(), o.current = null, r(null), t.setResizing(null));
1726
1726
  };
1727
- return document.addEventListener("keydown", i, !0), () => document.removeEventListener("keydown", i, !0);
1727
+ return document.addEventListener("keydown", e, !0), () => document.removeEventListener("keydown", e, !0);
1728
1728
  }, [
1729
1729
  n,
1730
1730
  t,
1731
- e.id,
1732
- s
1731
+ e.id
1733
1732
  ]);
1734
- let c = (n) => {
1733
+ let s = (n) => {
1735
1734
  if (n.button !== 0) return;
1736
1735
  n.preventDefault(), n.stopPropagation(), n.currentTarget.setPointerCapture(n.pointerId);
1737
1736
  let i = getComputedStyle(n.currentTarget).direction === "rtl", a = n.currentTarget.closest("[data-part=\"column-header\"]"), s = n.currentTarget.closest("[data-part=\"scroll\"]");
@@ -1741,21 +1740,16 @@ function ur({ column: e }) {
1741
1740
  rtl: i,
1742
1741
  span: s?.clientHeight ?? 0
1743
1742
  }), t.setResizing(e.id);
1743
+ }, c = (t) => {
1744
+ let n = i.current;
1745
+ if (!n) return;
1746
+ let r = (t.clientX - n.startX) * (n.rtl ? -1 : 1), s = _t(e.column, n.startWidth + r);
1747
+ o.current = s, a.current?.style.setProperty("translate", `${String((s - n.startWidth) * (n.rtl ? -1 : 1))}px 0`);
1744
1748
  }, l = (n) => {
1745
- let r = i.current;
1746
- if (!r) return;
1747
- let c = (n.clientX - r.startX) * (r.rtl ? -1 : 1);
1748
- if (!s) {
1749
- t.resizeTo(e.id, r.startWidth + c, "pointer", n);
1750
- return;
1751
- }
1752
- let l = _t(e.column, r.startWidth + c);
1753
- o.current = l, a.current?.style.setProperty("translate", `${String((l - r.startWidth) * (r.rtl ? -1 : 1))}px 0`);
1754
- }, u = (n) => {
1755
1749
  if (!i.current) return;
1756
1750
  n.currentTarget.releasePointerCapture(n.pointerId);
1757
1751
  let a = o.current;
1758
- o.current = null, r(null), t.setResizing(null), s && a !== null && n.type === "pointerup" && t.resizeTo(e.id, a, "pointer", n);
1752
+ o.current = null, r(null), t.setResizing(null), a !== null && n.type === "pointerup" && t.resizeTo(e.id, a, "pointer", n);
1759
1753
  };
1760
1754
  return /* @__PURE__ */ w("div", {
1761
1755
  "aria-hidden": !0,
@@ -1765,13 +1759,13 @@ function ur({ column: e }) {
1765
1759
  onDoubleClick: (n) => {
1766
1760
  n.stopPropagation(), t.autofit(n.shiftKey ? null : e.id, "pointer", n);
1767
1761
  },
1768
- onPointerCancel: u,
1769
- onPointerDown: c,
1770
- onPointerMove: l,
1771
- onPointerUp: u,
1762
+ onPointerCancel: l,
1763
+ onPointerDown: s,
1764
+ onPointerMove: c,
1765
+ onPointerUp: l,
1772
1766
  title: t.t("resize"),
1773
1767
  ...n ? { "data-resizing": "" } : {},
1774
- children: s && n ? /* @__PURE__ */ w("div", {
1768
+ children: n ? /* @__PURE__ */ w("div", {
1775
1769
  "aria-hidden": !0,
1776
1770
  "data-part": "resize-guide",
1777
1771
  "data-part-resize-guide": "",
@@ -1846,87 +1840,87 @@ function kr(e) {
1846
1840
  }
1847
1841
  return i + Math.max(0, a - 1) * r + n;
1848
1842
  }
1849
- function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow: a, dataSource: o, columnState: s, columns: c, current: u, density: d, defaultColumnState: f, defaultCurrent: p, defaultExpanded: m, defaultExpandedGroups: h, defaultQuery: g, defaultRange: _, defaultValue: ee, disabledKeys: te, editMode: ne, editorRenderers: re, error: ie, expandable: v, expanded: ue, expandedGroups: de, filterDebounce: fe, filterRow: pe, footer: me, handle: he, hasMore: ge, height: _e, highlightChanges: ve, labelledBy: ye, loadMoreThreshold: be, loadMoreTrigger: xe, loadMoreFailed: Se, loading: Ce, locale: we, messages: Te, mode: Ee, onActivate: De, onColumnStateChange: Oe, onCurrentChange: ke, onEditCancel: Ae, onEditCommit: je, onEditStart: Me, onExpandedChange: Ne, onExpandedGroupsChange: Pe, onLoadChildren: Fe, onRowsReorder: Ie, onKeyDown: Le, onLoadMore: Ve, onManageColumns: He, onOutOfSpaceChange: Je, onQueryChange: Ye, onRangeChange: Xe, onRetry: Ze, onValueChange: Qe, overscan: $e, pinnedRows: et, pageSizes: tt, query: nt, range: _t, ref: xt, resizeMode: Dt, renderCell: Ft, renderDetail: It, renderEditor: Xt, renderEmpty: Zt, renderFilterOperand: Qt, renderGroup: $t, renderHeader: en, rowHeight: tn, rowKey: nn, rowsReorderable: rn, rows: on, selectionMode: sn, showRange: cn, skeletonRows: mn, stickyHeader: hn, stickyTo: D, striped: yn, style: bn, timeZone: Sn, totalCount: Cn, tree: wn, value: En, variant: An, virtualize: jn, ...Mn }) {
1850
- let O = Bn(), Nn = Re(), k = S(null), Pn = S(null), Fn = S({
1843
+ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow: a, dataSource: o, columnState: s, columns: c, current: u, density: d, defaultColumnState: f, defaultCurrent: p, defaultExpanded: m, defaultExpandedGroups: h, defaultQuery: g, defaultRange: _, defaultValue: ee, disabledKeys: te, editMode: ne, editorRenderers: re, error: ie, expandable: v, expanded: ue, expandedGroups: de, filterDebounce: fe, filterRow: pe, footer: me, handle: he, hasMore: ge, height: _e, highlightChanges: ve, labelledBy: ye, loadMoreThreshold: be, loadMoreTrigger: xe, loadMoreFailed: Se, loading: Ce, locale: we, messages: Te, mode: Ee, onActivate: De, onColumnStateChange: Oe, onCurrentChange: ke, onEditCancel: Ae, onEditCommit: je, onEditStart: Me, onExpandedChange: Ne, onExpandedGroupsChange: Pe, onLoadChildren: Fe, onRowsReorder: Ie, onKeyDown: Le, onLoadMore: Ve, onManageColumns: He, onOutOfSpaceChange: Je, onQueryChange: Ye, onRangeChange: Xe, onRetry: Ze, onValueChange: Qe, overscan: $e, pinnedRows: et, pageSizes: tt, query: nt, range: _t, ref: xt, renderCell: Dt, renderDetail: Ft, renderEditor: It, renderEmpty: Xt, renderFilterOperand: Zt, renderGroup: Qt, renderHeader: $t, rowHeight: en, rowKey: tn, rowsReorderable: nn, rows: rn, selectionMode: on, showRange: sn, skeletonRows: cn, stickyHeader: mn, stickyTo: hn, striped: D, style: yn, timeZone: bn, totalCount: Sn, tree: Cn, value: wn, variant: En, virtualize: An, ...jn }) {
1844
+ let O = Bn(), Mn = Re(), k = S(null), Nn = S(null), Pn = S({
1851
1845
  cellRenderers: r,
1852
1846
  editorRenderers: re,
1853
- tree: wn
1847
+ tree: Cn
1854
1848
  });
1855
- Fn.current = {
1849
+ Pn.current = {
1856
1850
  cellRenderers: r,
1857
1851
  editorRenderers: re,
1858
- tree: wn
1852
+ tree: Cn
1859
1853
  };
1860
- let Rn = xr(Ft), zn = xr(It), Vn = xr(Xt), Hn = xr($t), Gn = xr(en), Kn = r ? Object.keys(r).join() : null, qn = re ? Object.keys(re).join() : null, Yn = wn?.column, Xn = wn?.hasChildren !== void 0, A = x(() => wn === void 0 ? void 0 : {
1861
- column: Yn,
1862
- parentKey: (e) => Fn.current.tree.parentKey(e),
1863
- hasChildren: Xn ? (e) => Fn.current.tree.hasChildren?.(e) === !0 : void 0
1854
+ let Fn = xr(Dt), Rn = xr(Ft), zn = xr(It), Vn = xr(Qt), Hn = xr($t), Gn = r ? Object.keys(r).join() : null, Kn = re ? Object.keys(re).join() : null, qn = Cn?.column, Yn = Cn?.hasChildren !== void 0, A = x(() => Cn === void 0 ? void 0 : {
1855
+ column: qn,
1856
+ parentKey: (e) => Pn.current.tree.parentKey(e),
1857
+ hasChildren: Yn ? (e) => Pn.current.tree.hasChildren?.(e) === !0 : void 0
1864
1858
  }, [
1865
- wn === void 0,
1866
- Yn,
1867
- Xn
1868
- ]), j = t(We, Te), Zn = t(Ge), Qn = e(), $n = An ?? O.variant ?? "ruled", er = yn ?? O.striped ?? !1, tr = hn ?? O.stickyHeader ?? !0, nr = D ?? O.stickyTo ?? "scroll", M = sn ?? O.selectionMode ?? "none", ir = ne ?? O.editMode ?? "cell", ar = pe ?? O.filterRow ?? !1, or = jn ?? O.virtualize ?? "auto", sr = tn ?? O.rowHeight, cr = a ?? O.columnOverflow ?? "auto", lr = $e ?? O.overscan ?? 6, ur = fe ?? O.filterDebounce ?? 300, Ar = be ?? O.loadMoreThreshold ?? 20, Nr = xe ?? O.loadMoreTrigger ?? "scroll", Pr = Dt ?? O.resizeMode ?? "live", Fr = mn ?? O.skeletonRows ?? 8, N = we ?? Qn, Ir = n ?? !1, P = y((e) => typeof nn == "function" ? nn(e) : String(e[nn]), [nn]), Lr = j("filterYes"), Rr = j("filterNo"), zr = x(() => ({
1859
+ Cn === void 0,
1860
+ qn,
1861
+ Yn
1862
+ ]), j = t(We, Te), Xn = t(Ge), Zn = e(), Qn = En ?? O.variant ?? "ruled", $n = D ?? O.striped ?? !1, er = mn ?? O.stickyHeader ?? !0, tr = hn ?? O.stickyTo ?? "scroll", M = on ?? O.selectionMode ?? "none", rr = ne ?? O.editMode ?? "cell", ir = pe ?? O.filterRow ?? !1, ar = An ?? O.virtualize ?? "auto", or = en ?? O.rowHeight, sr = a ?? O.columnOverflow ?? "auto", cr = $e ?? O.overscan ?? 6, lr = fe ?? O.filterDebounce ?? 300, ur = be ?? O.loadMoreThreshold ?? 20, Ar = xe ?? O.loadMoreTrigger ?? "scroll", Nr = cn ?? O.skeletonRows ?? 8, N = we ?? Zn, Pr = n ?? !1, P = y((e) => typeof tn == "function" ? tn(e) : String(e[tn]), [tn]), Fr = j("filterYes"), Ir = j("filterNo"), Lr = x(() => ({
1869
1863
  locale: N,
1870
- timeZone: Sn,
1864
+ timeZone: bn,
1871
1865
  booleans: {
1872
- true: Lr,
1873
- false: Rr
1866
+ true: Fr,
1867
+ false: Ir
1874
1868
  }
1875
1869
  }), [
1876
1870
  N,
1877
- Sn,
1878
- Lr,
1879
- Rr
1880
- ]), Br = y((e, t) => ht(e, t, zr), [zr]), Vr = x(() => new Set(te ?? []), [te]), Hr = y((e) => Vr.has(e), [Vr]), F = y((e, t) => {
1881
- if (Vr.has(P(t))) return !1;
1871
+ bn,
1872
+ Fr,
1873
+ Ir
1874
+ ]), Rr = y((e, t) => ht(e, t, Lr), [Lr]), zr = x(() => new Set(te ?? []), [te]), Br = y((e) => zr.has(e), [zr]), F = y((e, t) => {
1875
+ if (zr.has(P(t))) return !1;
1882
1876
  let n = e.editable;
1883
1877
  return typeof n == "function" ? n(t) : n === !0;
1884
- }, [Vr, P]), Ur = x(() => c.some((e) => e.editable), [c]), Wr = y((e) => zn ? v === void 0 ? !0 : typeof v == "function" ? v(e) : v : !1, [v, zn]), [I, Gr] = dr(nt, g ?? St(), Ye, Cr), Kr = Un(o, I), L = o ? Kr.rows : on ?? Or, qr = o ? Kr.total : Cn, Jr = o ? Kr.hasMore : ge, Yr = o ? Kr.loading : Ce, Xr = Yr !== void 0 && Yr !== !1, Zr = o ? Kr.error : ie, Qr = o ? Kr.retry : Ze, $r = Ee ?? (o || qr !== void 0 || Jr !== void 0 ? "server" : "client"), ei = x(() => Et(s ?? f, c), [s, c]), [ti, ni] = dr(s === void 0 ? void 0 : ei, ei, Oe, wr), R = x(() => Et(ti, c), [ti, c]), [ri, ii] = dr(En, ee ?? (M === "multiple" ? [] : null), Qe, Dr), [ai, oi] = dr(_t, _ ?? null, Xe, Er), [z, si] = dr(u, p ?? null, ke, E), [ci, li] = dr(ue, m ?? [], Ne, Tr), [ui, di] = dr(de, h ?? "all", Pe, Tr), fi = M === "single" || M === "multiple", pi = rn === !0, mi = zn !== void 0, hi = x(() => {
1878
+ }, [zr, P]), Vr = x(() => c.some((e) => e.editable), [c]), Hr = y((e) => Rn ? v === void 0 ? !0 : typeof v == "function" ? v(e) : v : !1, [v, Rn]), [I, Ur] = dr(nt, g ?? St(), Ye, Cr), Wr = Un(o, I), L = o ? Wr.rows : rn ?? Or, Gr = o ? Wr.total : Sn, Kr = o ? Wr.hasMore : ge, qr = o ? Wr.loading : Ce, Jr = qr !== void 0 && qr !== !1, Yr = o ? Wr.error : ie, Xr = o ? Wr.retry : Ze, Zr = Ee ?? (o || Gr !== void 0 || Kr !== void 0 ? "server" : "client"), Qr = x(() => Et(s ?? f, c), [s, c]), [$r, ei] = dr(s === void 0 ? void 0 : Qr, Qr, Oe, wr), R = x(() => Et($r, c), [$r, c]), [ti, ni] = dr(wn, ee ?? (M === "multiple" ? [] : null), Qe, Dr), [ri, ii] = dr(_t, _ ?? null, Xe, Er), [z, ai] = dr(u, p ?? null, ke, E), [oi, si] = dr(ue, m ?? [], Ne, Tr), [ci, li] = dr(de, h ?? "all", Pe, Tr), ui = M === "single" || M === "multiple", di = nn === !0, fi = Rn !== void 0, pi = x(() => {
1885
1879
  let e = [];
1886
- return fi && e.push(48), pi && e.push(40), mi && e.push(40), e;
1880
+ return ui && e.push(48), di && e.push(40), fi && e.push(40), e;
1887
1881
  }, [
1888
- fi,
1889
- pi,
1890
- mi
1891
- ]), gi = hi.reduce((e, t) => e + t, 0), _i = x(() => Nt(c, R, { leading: gi }), [
1882
+ ui,
1883
+ di,
1884
+ fi
1885
+ ]), mi = pi.reduce((e, t) => e + t, 0), hi = x(() => Nt(c, R, { leading: mi }), [
1892
1886
  c,
1893
1887
  R,
1894
- gi
1895
- ]), [vi, yi] = C(0), [bi, xi] = C(!1);
1888
+ mi
1889
+ ]), [gi, _i] = C(0), [vi, yi] = C(!1);
1896
1890
  b(() => {
1897
1891
  if (typeof window > "u" || typeof window.matchMedia != "function") return;
1898
- let e = window.matchMedia("(pointer: coarse)"), t = () => xi(e.matches);
1892
+ let e = window.matchMedia("(pointer: coarse)"), t = () => yi(e.matches);
1899
1893
  return t(), e.addEventListener("change", t), () => e.removeEventListener("change", t);
1900
1894
  }, []);
1901
- let Si = vi <= 0 || Mt(cr, vi, bi) === "scroll" ? _r : bt(_i, vi, { leading: gi }), Ci = `${Si.popin.join("\0")}\u0001${Si.hidden.join("\0")}`, B = x(() => Si, [Ci]), V = x(() => B.popin.length === 0 && B.hidden.length === 0 ? _i : Nt(c, {
1895
+ let bi = gi <= 0 || Mt(sr, gi, vi) === "scroll" ? _r : bt(hi, gi, { leading: mi }), xi = `${bi.popin.join("\0")}\u0001${bi.hidden.join("\0")}`, B = x(() => bi, [xi]), V = x(() => B.popin.length === 0 && B.hidden.length === 0 ? hi : Nt(c, {
1902
1896
  ...R,
1903
1897
  hidden: [
1904
1898
  ...R.hidden,
1905
1899
  ...B.popin,
1906
1900
  ...B.hidden
1907
1901
  ]
1908
- }, { leading: gi }), [
1909
- _i,
1902
+ }, { leading: mi }), [
1903
+ hi,
1910
1904
  B,
1911
1905
  c,
1912
1906
  R,
1913
- gi
1914
- ]), wi = x(() => B.popin.length === 0 ? [] : _i.filter((e) => B.popin.includes(e.id)), [_i, B]), Ti = wi.length > 0, Ei = S(_r);
1907
+ mi
1908
+ ]), Si = x(() => B.popin.length === 0 ? [] : hi.filter((e) => B.popin.includes(e.id)), [hi, B]), Ci = Si.length > 0, wi = S(_r);
1915
1909
  b(() => {
1916
- let e = Ei.current;
1917
- Tr(B.popin, e.popin) && Tr(B.hidden, e.hidden) || (Ei.current = B, Je?.(B));
1910
+ let e = wi.current;
1911
+ Tr(B.popin, e.popin) && Tr(B.hidden, e.hidden) || (wi.current = B, Je?.(B));
1918
1912
  }, [B, Je]);
1919
1913
  let H = x(() => new Map(V.map((e) => [e.id, e])), [V]), U = x(() => [
1920
- ...fi ? [un] : [],
1921
- ...pi ? [fn] : [],
1922
- ...mi ? [dn] : [],
1914
+ ...ui ? [un] : [],
1915
+ ...di ? [fn] : [],
1916
+ ...fi ? [dn] : [],
1923
1917
  ...V.map((e) => e.id)
1924
1918
  ], [
1919
+ ui,
1920
+ di,
1925
1921
  fi,
1926
- pi,
1927
- mi,
1928
1922
  V
1929
- ]), Di = U.length + +!!Ti, Oi = U.length + 1, ki = x(() => Ti ? [...U, dt] : U, [Ti, U]), Ai = x(() => yt(V, hi), [V, hi]), W = x(() => {
1923
+ ]), Ti = U.length + +!!Ci, Ei = U.length + 1, Di = x(() => Ci ? [...U, dt] : U, [Ci, U]), Oi = x(() => yt(V, pi), [V, pi]), W = x(() => {
1930
1924
  let e = et?.top ?? [], t = et?.bottom ?? [];
1931
1925
  if (e.length === 0 && t.length === 0) return {
1932
1926
  top: [],
@@ -1958,80 +1952,80 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
1958
1952
  et,
1959
1953
  L,
1960
1954
  P
1961
- ]), ji = x(() => W.keys ? L.filter((e) => !W.keys.has(P(e))) : L, [
1955
+ ]), ki = x(() => W.keys ? L.filter((e) => !W.keys.has(P(e))) : L, [
1962
1956
  L,
1963
1957
  W.keys,
1964
1958
  P
1965
- ]), Mi = x(() => {
1966
- let e = ji;
1967
- if ($r === "server") return {
1959
+ ]), Ai = x(() => {
1960
+ let e = ki;
1961
+ if (Zr === "server") return {
1968
1962
  nodes: Ct(e, c, I.group, {
1969
1963
  rowKey: P,
1970
- expandedGroups: ui,
1964
+ expandedGroups: ci,
1971
1965
  offset: I.page && "index" in I.page ? I.page.index * I.page.size : 0,
1972
1966
  locale: N,
1973
- timeZone: Sn,
1974
- booleans: zr.booleans
1967
+ timeZone: bn,
1968
+ booleans: Lr.booleans
1975
1969
  }),
1976
1970
  rows: e,
1977
- total: qr ?? null,
1978
- hasMore: Jr ?? !1,
1971
+ total: Gr ?? null,
1972
+ hasMore: Kr ?? !1,
1979
1973
  aggregates: {}
1980
1974
  };
1981
1975
  let t = mt(e, c, I, {
1982
1976
  rowKey: P,
1983
- expandedGroups: ui,
1977
+ expandedGroups: ci,
1984
1978
  tree: A,
1985
- expanded: A ? ci : void 0,
1979
+ expanded: A ? oi : void 0,
1986
1980
  locale: N,
1987
- timeZone: Sn,
1988
- booleans: zr.booleans
1981
+ timeZone: bn,
1982
+ booleans: Lr.booleans
1989
1983
  });
1990
1984
  return {
1991
1985
  ...t,
1992
1986
  total: t.total
1993
1987
  };
1994
1988
  }, [
1995
- $r,
1996
- ji,
1989
+ Zr,
1990
+ ki,
1997
1991
  c,
1998
1992
  I,
1999
1993
  P,
2000
- ui,
2001
- A,
2002
1994
  ci,
1995
+ A,
1996
+ oi,
2003
1997
  N,
2004
- Sn,
2005
- zr.booleans,
2006
- qr,
2007
- Jr
2008
- ]), G = Mi.nodes, Ni = Mi.total, Pi = x(() => wi.filter((e) => e.column.aggregate !== void 0), [wi]), Fi = (V.some((e) => e.column.aggregate !== void 0) || Pi.length > 0) && $r === "client", Ii = y((e) => Ti ? e === pt ? Pi.length > 0 : Mr(e) : !1, [Ti, Pi]), Li = y((e) => e.column !== dt || Ii(e.row) ? e : {
1998
+ bn,
1999
+ Lr.booleans,
2000
+ Gr,
2001
+ Kr
2002
+ ]), G = Ai.nodes, ji = Ai.total, Mi = x(() => Si.filter((e) => e.column.aggregate !== void 0), [Si]), Ni = (V.some((e) => e.column.aggregate !== void 0) || Mi.length > 0) && Zr === "client", Pi = y((e) => Ci ? e === pt ? Mi.length > 0 : Mr(e) : !1, [Ci, Mi]), Fi = y((e) => e.column !== dt || Pi(e.row) ? e : {
2009
2003
  row: e.row,
2010
2004
  column: U[U.length - 1]
2011
- }, [Ii, U]), Ri = 1 + (i && i.length > 0 ? 1 : 0) + +!!ar, zi = x(() => {
2005
+ }, [Pi, U]), Ii = 1 + (i && i.length > 0 ? 1 : 0) + +!!ir, Li = x(() => {
2012
2006
  let e = [ut];
2013
- ar && e.push(ct);
2007
+ ir && e.push(ct);
2014
2008
  for (let t of W.top) e.push(t.key);
2015
2009
  for (let t of G) e.push(t.kind === "group" ? `${lt}${t.key}` : t.key);
2016
2010
  for (let t of W.bottom) e.push(t.key);
2017
- return Fi && e.push(pt), e;
2011
+ return Ni && e.push(pt), e;
2018
2012
  }, [
2019
2013
  G,
2020
2014
  W,
2021
- ar,
2022
- Fi
2023
- ]), Bi = 1 + +!!ar, Vi = Bi + W.top.length + G.length + W.bottom.length, [Hi, Ui] = C(0), [Wi, Gi] = C(0), [K, Ki] = C({
2015
+ ir,
2016
+ Ni
2017
+ ]), Ri = 1 + +!!ir, zi = Ri + W.top.length + G.length + W.bottom.length, [Bi, Vi] = C(0), [Hi, Ui] = C(0), [K, Wi] = C({
2024
2018
  width: 0,
2025
2019
  height: 0
2026
- }), [qi, Ji] = C(null), [Yi, Xi] = C(/* @__PURE__ */ new Map()), Zi = sr === "auto" || Ti, q = typeof sr == "number" ? sr : qi ?? fr, Qi = or === !0 || or === "auto" && G.length > pr, $i = x(() => {
2027
- if (Zi) return rt(G.map((e, t) => Yi.get(t) ?? q));
2020
+ }), [Gi, Ki] = C(null), [qi, Ji] = C(/* @__PURE__ */ new Map()), Yi = or === "auto" || Ci, q = typeof or == "number" ? or : Gi ?? fr, Xi = ar === !0 || ar === "auto" && G.length > pr, Zi = x(() => {
2021
+ if (Yi) return rt(G.map((e, t) => qi.get(t) ?? q));
2028
2022
  }, [
2029
- Zi,
2030
- G,
2031
2023
  Yi,
2024
+ G,
2025
+ qi,
2032
2026
  q
2033
- ]), ea = x(() => {
2034
- if (!Qi) return {
2027
+ ]), Qi = x(() => {
2028
+ if (!Xi) return {
2035
2029
  startIndex: 0,
2036
2030
  endIndex: G.length,
2037
2031
  startOffset: 0,
@@ -2040,9 +2034,9 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2040
2034
  let e = at({
2041
2035
  itemCount: G.length,
2042
2036
  itemSize: q,
2043
- metrics: $i,
2044
- overscan: lr,
2045
- scrollOffset: Math.max(0, Hi),
2037
+ metrics: Zi,
2038
+ overscan: cr,
2039
+ scrollOffset: Math.max(0, Bi),
2046
2040
  viewportSize: K.height || hr
2047
2041
  });
2048
2042
  return {
@@ -2052,219 +2046,219 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2052
2046
  totalSize: e.totalSize
2053
2047
  };
2054
2048
  }, [
2055
- Qi,
2049
+ Xi,
2056
2050
  K.height,
2057
2051
  G.length,
2058
2052
  q,
2059
- $i,
2060
- lr,
2061
- Hi
2062
- ]), ta = x(() => Qi ? G.slice(ea.startIndex, ea.endIndex) : G, [
2063
- Qi,
2053
+ Zi,
2054
+ cr,
2055
+ Bi
2056
+ ]), $i = x(() => Xi ? G.slice(Qi.startIndex, Qi.endIndex) : G, [
2057
+ Xi,
2064
2058
  G,
2065
- ea.startIndex,
2066
- ea.endIndex
2067
- ]), [na, ra] = C([]), ia = x(() => V.filter((e) => e.pinned === null), [V]), aa = or === !0 || or === "auto" && ia.length > mr, oa = x(() => {
2068
- if (!aa || K.width === 0) return V;
2069
- let e = hi.reduce((e, t) => e + t, 0), t = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0), n = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), r = Wi - gr, i = Wi + K.width - n + gr, a = e + t, o = /* @__PURE__ */ new Set();
2070
- for (let e of ia) {
2059
+ Qi.startIndex,
2060
+ Qi.endIndex
2061
+ ]), [ea, ta] = C([]), na = x(() => V.filter((e) => e.pinned === null), [V]), ra = ar === !0 || ar === "auto" && na.length > mr, ia = x(() => {
2062
+ if (!ra || K.width === 0) return V;
2063
+ let e = pi.reduce((e, t) => e + t, 0), t = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0), n = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), r = Hi - gr, i = Hi + K.width - n + gr, a = e + t, o = /* @__PURE__ */ new Set();
2064
+ for (let e of na) {
2071
2065
  let t = a + e.width;
2072
2066
  t >= r && a <= i && o.add(e.id), a = t;
2073
2067
  }
2074
2068
  return V.filter((e) => e.pinned !== null || o.has(e.id) || z !== null && z.column === e.id);
2075
2069
  }, [
2076
- aa,
2070
+ ra,
2077
2071
  K.width,
2078
2072
  V,
2079
- hi,
2080
- Wi,
2081
- ia,
2073
+ pi,
2074
+ Hi,
2075
+ na,
2082
2076
  z
2083
2077
  ]), J = x(() => {
2084
- let e = $r === "client" ? Mi.rows : ji;
2078
+ let e = Zr === "client" ? Ai.rows : ki;
2085
2079
  return [
2086
2080
  ...W.top.map((e) => e.key),
2087
2081
  ...e.map(P),
2088
2082
  ...W.bottom.map((e) => e.key)
2089
- ].filter((e) => !Vr.has(e));
2083
+ ].filter((e) => !zr.has(e));
2090
2084
  }, [
2091
- $r,
2092
- Mi.rows,
2093
- ji,
2085
+ Zr,
2086
+ Ai.rows,
2087
+ ki,
2094
2088
  W,
2095
2089
  P,
2096
- Vr
2097
- ]), sa = x(() => Array.isArray(ri) ? ri : ri == null ? [] : [ri], [ri]), ca = x(() => new Set(sa), [sa]), la = S(void 0), ua = y((e) => ca.has(e), [ca]), da = x(() => new Set(J), [J]), fa = x(() => sa.filter((e) => da.has(e)).length, [sa, da]), pa = fa === 0 ? "none" : fa >= J.length ? "all" : "some", ma = y((e, t, n) => {
2090
+ zr
2091
+ ]), aa = x(() => Array.isArray(ti) ? ti : ti == null ? [] : [ti], [ti]), oa = x(() => new Set(aa), [aa]), sa = S(void 0), ca = y((e) => oa.has(e), [oa]), la = x(() => new Set(J), [J]), ua = x(() => aa.filter((e) => la.has(e)).length, [aa, la]), da = ua === 0 ? "none" : ua >= J.length ? "all" : "some", fa = y((e, t, n) => {
2098
2092
  let r = M === "multiple" ? e : e[0] ?? null;
2099
- ii(r, t, n);
2100
- }, [M, ii]), ha = y((e, t) => {
2101
- if (M === "none" || M === "range" || Vr.has(e)) return;
2093
+ ni(r, t, n);
2094
+ }, [M, ni]), pa = y((e, t) => {
2095
+ if (M === "none" || M === "range" || zr.has(e)) return;
2102
2096
  let n = it({
2103
2097
  action: t.range ? "range" : "toggle",
2104
2098
  mode: M,
2105
- selected: sa,
2099
+ selected: aa,
2106
2100
  keys: J,
2107
2101
  key: e,
2108
- anchor: la.current,
2109
- disabled: (e) => Vr.has(e)
2102
+ anchor: sa.current,
2103
+ disabled: (e) => zr.has(e)
2110
2104
  });
2111
- t.range || (la.current = e), n.changed && ma(n.selected, t.reason ?? "pointer", t.source);
2105
+ t.range || (sa.current = e), n.changed && fa(n.selected, t.reason ?? "pointer", t.source);
2112
2106
  }, [
2113
2107
  M,
2114
- Vr,
2115
- sa,
2108
+ zr,
2109
+ aa,
2116
2110
  J,
2117
- ma
2118
- ]), ga = y((e) => {
2111
+ fa
2112
+ ]), ma = y((e) => {
2119
2113
  if (M !== "multiple") return;
2120
2114
  let t = it({
2121
2115
  action: "all",
2122
2116
  mode: "multiple",
2123
- selected: sa,
2117
+ selected: aa,
2124
2118
  keys: J
2125
2119
  });
2126
- t.changed && ma(t.selected, "select", e);
2120
+ t.changed && fa(t.selected, "select", e);
2127
2121
  }, [
2128
2122
  M,
2129
- sa,
2123
+ aa,
2130
2124
  J,
2131
- ma
2132
- ]), _a = Math.max(1, Math.floor((K.height || 400) / q) - 1), Y = x(() => ({
2133
- rows: zi,
2134
- columns: ki,
2135
- pageSize: _a,
2136
- bodyStart: Bi,
2137
- bodyEnd: Vi
2125
+ fa
2126
+ ]), ha = Math.max(1, Math.floor((K.height || 400) / q) - 1), Y = x(() => ({
2127
+ rows: Li,
2128
+ columns: Di,
2129
+ pageSize: ha,
2130
+ bodyStart: Ri,
2131
+ bodyEnd: zi
2138
2132
  }), [
2139
- zi,
2140
- ki,
2141
- _a,
2142
- Bi,
2143
- Vi
2144
- ]), X = x(() => M === "range" ? Ot(Y, ai) : null, [
2133
+ Li,
2134
+ Di,
2135
+ ha,
2136
+ Ri,
2137
+ zi
2138
+ ]), X = x(() => M === "range" ? Ot(Y, ri) : null, [
2145
2139
  M,
2146
2140
  Y,
2147
- ai
2148
- ]), va = y((e) => At(Y, X, e), [Y, X]), [ya, ba] = C(!1), xa = S(null), Sa = y((e, t, n) => {
2141
+ ri
2142
+ ]), ga = y((e) => At(Y, X, e), [Y, X]), [_a, va] = C(!1), ya = S(null), ba = y((e, t, n) => {
2149
2143
  if (M !== "range" || !Mr(e.row)) return;
2150
- let r = t && ai ? ai.anchor : e;
2151
- xa.current = r, oi({
2144
+ let r = t && ri ? ri.anchor : e;
2145
+ ya.current = r, ii({
2152
2146
  anchor: r,
2153
2147
  focus: e
2154
2148
  }, "pointer", n);
2155
2149
  }, [
2156
2150
  M,
2157
- ai,
2158
- oi
2159
- ]), Ca = y((e, t) => {
2151
+ ri,
2152
+ ii
2153
+ ]), xa = y((e, t) => {
2160
2154
  if (M !== "range" || !Mr(e.row)) return;
2161
- let n = xa.current ?? ai?.anchor ?? e;
2162
- oi({
2155
+ let n = ya.current ?? ri?.anchor ?? e;
2156
+ ii({
2163
2157
  anchor: n,
2164
2158
  focus: e
2165
2159
  }, "pointer", t);
2166
2160
  }, [
2167
2161
  M,
2168
- ai,
2169
- oi
2162
+ ri,
2163
+ ii
2170
2164
  ]), Z = y((e) => {
2171
2165
  qe(k.current?.ownerDocument).announce(e);
2172
- }, []), [wa, Ta] = C(!1), Ea = S(null), Da = y((e) => {
2166
+ }, []), [Sa, Ca] = C(!1), wa = S(null), Ta = y((e) => {
2173
2167
  let t = k.current?.querySelector(`[data-row="${CSS.escape(e.row)}"] [data-column="${CSS.escape(e.column)}"]`);
2174
2168
  if (!t) return !1;
2175
2169
  let n = t.matches("[data-part=\"column-header\"], [data-part=\"filter-cell\"]") || t.querySelector("[data-part=\"group-toggle\"]") !== null, r = t.querySelector("[data-part=\"editor\"]");
2176
2170
  if (r) return (r.querySelector("input:not([type=\"checkbox\"]):not([type=\"radio\"]):not([disabled]), textarea:not([disabled]), [role=\"combobox\"]:not([disabled]), [role=\"spinbutton\"]:not([disabled]), [role=\"checkbox\"], [role=\"switch\"]") ?? r.querySelector("a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"]), [contenteditable=\"true\"]") ?? t).focus({ preventScroll: !1 }), !0;
2177
2171
  let i = n ? [] : [...t.querySelectorAll(pn)];
2178
2172
  return ((i.length === 1 && i[0].matches("a[href], button, input[type=\"checkbox\"], input[type=\"radio\"], [role=\"switch\"], [role=\"button\"], [role=\"checkbox\"]") ? i[0] : null) ?? t).focus({ preventScroll: !1 }), !0;
2179
- }, []), Oa = y((e, t, n) => {
2180
- if (E(e, z) || si(e, t, n), Ea.current = e, Mr(e.row) && !zi.includes(e.row)) return;
2181
- let r = zi.indexOf(e.row) - Bi;
2182
- if (Qi && r >= 0 && (r < ea.startIndex || r >= ea.endIndex)) {
2183
- ra([e.row]);
2184
- let t = $i ? $i.offsetOf(r) : r * q;
2185
- Pn.current?.scrollTo({ top: t - K.height / 2 + q });
2173
+ }, []), Ea = y((e, t, n) => {
2174
+ if (E(e, z) || ai(e, t, n), wa.current = e, Mr(e.row) && !Li.includes(e.row)) return;
2175
+ let r = Li.indexOf(e.row) - Ri;
2176
+ if (Xi && r >= 0 && (r < Qi.startIndex || r >= Qi.endIndex)) {
2177
+ ta([e.row]);
2178
+ let t = Zi ? Zi.offsetOf(r) : r * q;
2179
+ Nn.current?.scrollTo({ top: t - K.height / 2 + q });
2186
2180
  }
2187
2181
  }, [
2188
2182
  z,
2189
- si,
2190
- zi,
2191
- Bi,
2183
+ ai,
2184
+ Li,
2185
+ Ri,
2186
+ Xi,
2192
2187
  Qi,
2193
- ea,
2194
- $i,
2188
+ Zi,
2195
2189
  q,
2196
2190
  K.height
2197
2191
  ]);
2198
2192
  Be(() => {
2199
- let e = Ea.current;
2200
- e && Da(e) && (Ea.current = null);
2193
+ let e = wa.current;
2194
+ e && Ta(e) && (wa.current = null);
2201
2195
  });
2202
- let ka = S(0);
2196
+ let Da = S(0);
2203
2197
  b(() => {
2204
- if (z && zi.includes(z.row) && (ka.current = zi.indexOf(z.row), ki.includes(z.column)) || !z) return;
2205
- let e = zi.includes(z.row) && B.popin.includes(z.column) && Ii(z.row) ? {
2198
+ if (z && Li.includes(z.row) && (Da.current = Li.indexOf(z.row), Di.includes(z.column)) || !z) return;
2199
+ let e = Li.includes(z.row) && B.popin.includes(z.column) && Pi(z.row) ? {
2206
2200
  row: z.row,
2207
2201
  column: dt
2208
- } : Lt(Y, z, ka.current);
2209
- e && !E(e, z) ? (si(e, "programmatic"), wa && (Ea.current = e)) : !e && wa && k.current?.querySelector("[data-part=\"empty\"] [tabindex]")?.focus();
2202
+ } : Lt(Y, z, Da.current);
2203
+ e && !E(e, z) ? (ai(e, "programmatic"), Sa && (wa.current = e)) : !e && Sa && k.current?.querySelector("[data-part=\"empty\"] [tabindex]")?.focus();
2210
2204
  }, [
2211
2205
  Y,
2212
- zi,
2213
- ki,
2206
+ Li,
2207
+ Di,
2214
2208
  B,
2215
- Ii,
2209
+ Pi,
2216
2210
  z,
2217
- si,
2218
- wa
2211
+ ai,
2212
+ Sa
2219
2213
  ]);
2220
- let Aa = y((e) => {
2214
+ let Oa = y((e) => {
2221
2215
  let t = I.sort.findIndex((t) => t.column === e);
2222
2216
  return t === -1 ? null : {
2223
2217
  direction: I.sort[t].direction,
2224
2218
  index: t + 1
2225
2219
  };
2226
- }, [I.sort]), ja = y((e) => H.get(e)?.column.label ?? e, [H]), Ma = y((e) => {
2220
+ }, [I.sort]), ka = y((e) => H.get(e)?.column.label ?? e, [H]), Aa = y((e) => {
2227
2221
  if (e.sort.length === 0) {
2228
2222
  Z(j("sortCleared"));
2229
2223
  return;
2230
2224
  }
2231
- let t = e.sort.map((e) => j(e.direction === "ascending" ? "sortAscending" : "sortDescending", { column: ja(e.column) })).join(", ");
2225
+ let t = e.sort.map((e) => j(e.direction === "ascending" ? "sortAscending" : "sortDescending", { column: ka(e.column) })).join(", ");
2232
2226
  Z(j("sortedBy", { order: t }));
2233
2227
  }, [
2234
2228
  Z,
2235
2229
  j,
2236
- ja
2237
- ]), Na = y((e, t, n, r = "pointer") => {
2230
+ ka
2231
+ ]), ja = y((e, t, n, r = "pointer") => {
2238
2232
  let i = H.get(e);
2239
2233
  if (!i || !i.sortable) return;
2240
2234
  let a = Kt(I, e, t);
2241
- Gr(a.query, r, n, { change: a.change }), Ma(a.query);
2235
+ Ur(a.query, r, n, { change: a.change }), Aa(a.query);
2242
2236
  }, [
2243
2237
  H,
2244
2238
  I,
2245
- Gr,
2246
- Ma
2247
- ]), Pa = y((e, t, n) => {
2239
+ Ur,
2240
+ Aa
2241
+ ]), Ma = y((e, t, n) => {
2248
2242
  let r = Gt(I, e, t);
2249
- Gr(r.query, "pointer", n, { change: r.change }), Ma(r.query);
2243
+ Ur(r.query, "pointer", n, { change: r.change }), Aa(r.query);
2250
2244
  }, [
2251
2245
  I,
2252
- Gr,
2253
- Ma
2254
- ]), Fa = y((e) => an(I.filter, e) ?? null, [I.filter]), Ia = y((e, t, n, r) => {
2246
+ Ur,
2247
+ Aa
2248
+ ]), Na = y((e) => an(I.filter, e) ?? null, [I.filter]), Pa = y((e, t, n, r) => {
2255
2249
  let i = Bt(I, e, t);
2256
- Gr(i.query, n, r, { change: i.change });
2257
- }, [I, Gr]), [La, Ra] = C(null), [za, Ba] = C(null), [Va, Ha] = C(null), Ua = S(-Infinity), Wa = y((e, t, n) => {
2258
- Ha({
2250
+ Ur(i.query, n, r, { change: i.change });
2251
+ }, [I, Ur]), [Fa, Ia] = C(null), [La, Ra] = C(null), [za, Ba] = C(null), Va = S(-Infinity), Ha = y((e, t, n) => {
2252
+ Ba({
2259
2253
  column: e,
2260
2254
  anchor: t,
2261
2255
  returnTo: n
2262
- }), Ba(e);
2263
- }, []), Ga = y(() => Ha(null), []), Ka = y((e, t) => {
2256
+ }), Ra(e);
2257
+ }, []), Ua = y(() => Ba(null), []), Wa = y((e, t) => {
2264
2258
  let n = e.target;
2265
- n instanceof Element && e.currentTarget.contains(n) && (e.shiftKey || n.closest(vr) || (e.preventDefault(), !(Date.now() - Ua.current < yr) && Wa(t, Sr(e.clientX, e.clientY), e.currentTarget)));
2266
- }, [Wa]), qa = S(/* @__PURE__ */ new Map()), Ja = y((e) => {
2267
- let t = `${e}|${JSON.stringify(I.filter)}|${I.search}|${L.length}`, n = qa.current.get(t);
2259
+ n instanceof Element && e.currentTarget.contains(n) && (e.shiftKey || n.closest(vr) || (e.preventDefault(), !(Date.now() - Va.current < yr) && Ha(t, Sr(e.clientX, e.clientY), e.currentTarget)));
2260
+ }, [Ha]), Ga = S(/* @__PURE__ */ new Map()), Ka = y((e) => {
2261
+ let t = `${e}|${JSON.stringify(I.filter)}|${I.search}|${L.length}`, n = Ga.current.get(t);
2268
2262
  if (n) return n;
2269
2263
  let r = c.find((t) => t.id === e), i = /* @__PURE__ */ new Map();
2270
2264
  if (r) {
@@ -2282,107 +2276,107 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2282
2276
  }
2283
2277
  }
2284
2278
  }
2285
- return qa.current = /* @__PURE__ */ new Map([[t, i]]), i;
2279
+ return Ga.current = /* @__PURE__ */ new Map([[t, i]]), i;
2286
2280
  }, [
2287
2281
  c,
2288
2282
  I.filter,
2289
2283
  I.search,
2290
2284
  L,
2291
2285
  N
2292
- ]), Ya = y((e, t, n, r) => {
2293
- ni(e, n, r, { change: t });
2294
- }, [ni]), Xa = y((e, t, n) => {
2295
- Ya(Ut(R, e, t), "pinned", "pointer", n);
2296
- }, [R, Ya]), Za = y((e, t, n = "programmatic") => {
2286
+ ]), qa = y((e, t, n, r) => {
2287
+ ei(e, n, r, { change: t });
2288
+ }, [ei]), Ja = y((e, t, n) => {
2289
+ qa(Ut(R, e, t), "pinned", "pointer", n);
2290
+ }, [R, qa]), Ya = y((e, t, n = "programmatic") => {
2297
2291
  let r = c.find((t) => t.id === e);
2298
- r && !R.hidden.includes(e) && (Ya(Vt(R, e, !0), "hidden", n, t), Z(j("columnHidden", { column: r.label })));
2292
+ r && !R.hidden.includes(e) && (qa(Vt(R, e, !0), "hidden", n, t), Z(j("columnHidden", { column: r.label })));
2299
2293
  }, [
2300
2294
  c,
2301
2295
  R,
2302
- Ya,
2296
+ qa,
2303
2297
  Z,
2304
2298
  j
2305
- ]), Qa = y((e, t, n, r) => {
2299
+ ]), Xa = y((e, t, n, r) => {
2306
2300
  let i = c.find((t) => t.id === e);
2307
2301
  if (!i) return;
2308
2302
  let a = Wt(R, i, t);
2309
- Ya(a, "width", n, r), n === "keyboard" && Z(j("resized", {
2303
+ qa(a, "width", n, r), n === "keyboard" && Z(j("resized", {
2310
2304
  column: i.label,
2311
2305
  width: String(a.widths[e] ?? t)
2312
2306
  }));
2313
2307
  }, [
2314
2308
  c,
2315
2309
  R,
2316
- Ya,
2310
+ qa,
2317
2311
  Z,
2318
2312
  j
2319
- ]), $a = y((e, t, n) => {
2313
+ ]), Za = y((e, t, n) => {
2320
2314
  let r = H.get(e);
2321
- r && r.resizable && Qa(e, r.width + t, "keyboard", n);
2322
- }, [H, Qa]), eo = y((e) => {
2315
+ r && r.resizable && Xa(e, r.width + t, "keyboard", n);
2316
+ }, [H, Xa]), Qa = y((e) => {
2323
2317
  let t = k.current;
2324
2318
  if (!t) return null;
2325
2319
  let n = 0;
2326
2320
  for (let r of t.querySelectorAll(`[data-column="${CSS.escape(e)}"]`)) n = Math.max(n, kr(r));
2327
2321
  return n > 0 ? Math.ceil(n) : null;
2328
- }, []), to = y((e, t, n) => {
2322
+ }, []), $a = y((e, t, n) => {
2329
2323
  if (!H.has(e)) return;
2330
- let r = eo(e);
2331
- r !== null && Qa(e, r, t, n);
2324
+ let r = Qa(e);
2325
+ r !== null && Xa(e, r, t, n);
2332
2326
  }, [
2333
2327
  H,
2334
- eo,
2335
- Qa
2336
- ]), no = y((e, t) => {
2328
+ Qa,
2329
+ Xa
2330
+ ]), eo = y((e, t) => {
2337
2331
  let n = R;
2338
2332
  for (let e of V) {
2339
2333
  if (!e.resizable) continue;
2340
- let t = eo(e.id);
2334
+ let t = Qa(e.id);
2341
2335
  t !== null && (n = Wt(n, e.column, t));
2342
2336
  }
2343
- n !== R && Ya(n, "width", e, t);
2337
+ n !== R && qa(n, "width", e, t);
2344
2338
  }, [
2345
2339
  R,
2346
2340
  V,
2347
- eo,
2348
- Ya
2349
- ]), ro = y((e, t, n) => e === null ? no(t, n) : to(e, t, n), [no, to]), io = y((e, t, n) => {
2341
+ Qa,
2342
+ qa
2343
+ ]), to = y((e, t, n) => e === null ? eo(t, n) : $a(e, t, n), [eo, $a]), no = y((e, t, n) => {
2350
2344
  let r = H.get(e);
2351
2345
  if (!r || !r.reorderable) return;
2352
2346
  let i = Jt(V, e), a = i.indexOf(e) + t;
2353
- a < 0 || a >= i.length || Ya(Ht(R, e, a, i), "order", "keyboard", n);
2347
+ a < 0 || a >= i.length || qa(Ht(R, e, a, i), "order", "keyboard", n);
2354
2348
  }, [
2355
2349
  H,
2356
2350
  V,
2357
2351
  R,
2358
- Ya
2359
- ]), [ao, oo] = C(null), [so, co] = C({
2352
+ qa
2353
+ ]), [ro, io] = C(null), [ao, oo] = C({
2360
2354
  dragging: null,
2361
2355
  target: null,
2362
2356
  offset: null,
2363
2357
  scrollTop: 0
2364
- }), lo = S(null), uo = S({
2358
+ }), so = S(null), co = S({
2365
2359
  resolved: V,
2366
2360
  effectiveState: R,
2367
- requestState: Ya,
2368
- gutters: hi,
2369
- labelOf: ja,
2361
+ requestState: qa,
2362
+ gutters: pi,
2363
+ labelOf: ka,
2370
2364
  t: j,
2371
- dragT: Zn
2365
+ dragT: Xn
2372
2366
  });
2373
- uo.current = {
2367
+ co.current = {
2374
2368
  resolved: V,
2375
2369
  effectiveState: R,
2376
- requestState: Ya,
2377
- gutters: hi,
2378
- labelOf: ja,
2370
+ requestState: qa,
2371
+ gutters: pi,
2372
+ labelOf: ka,
2379
2373
  t: j,
2380
- dragT: Zn
2374
+ dragT: Xn
2381
2375
  };
2382
- let fo = S(/* @__PURE__ */ new Map()), po = S(!1), mo = S(/* @__PURE__ */ new Map()), ho = y((e, t) => {
2383
- let n = lo.current, r = fo.current.get(t);
2384
- if (r && (r(), fo.current.delete(t)), !e || !n) return;
2385
- let i = uo.current.resolved.find((e) => e.id === t);
2376
+ let lo = S(/* @__PURE__ */ new Map()), uo = S(!1), fo = S(/* @__PURE__ */ new Map()), po = y((e, t) => {
2377
+ let n = so.current, r = lo.current.get(t);
2378
+ if (r && (r(), lo.current.delete(t)), !e || !n) return;
2379
+ let i = co.current.resolved.find((e) => e.id === t);
2386
2380
  if (!i || !i.reorderable) return;
2387
2381
  let a = n.attachDraggable(e, {
2388
2382
  container: "columns",
@@ -2391,38 +2385,38 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2391
2385
  canDrag: (e) => !(e.target instanceof Element && e.target.closest("[data-part=\"resizer\"]")),
2392
2386
  distance: 6
2393
2387
  });
2394
- fo.current.set(t, a);
2395
- }, []), go = y((e, t) => {
2396
- e ? mo.current.set(t, e) : mo.current.delete(t), ho(e, t);
2397
- }, [ho]), _o = V.map((e) => e.id).join("\0");
2388
+ lo.current.set(t, a);
2389
+ }, []), mo = y((e, t) => {
2390
+ e ? fo.current.set(t, e) : fo.current.delete(t), po(e, t);
2391
+ }, [po]), ho = V.map((e) => e.id).join("\0");
2398
2392
  b(() => {
2399
- for (let [e, t] of mo.current) ho(t, e);
2400
- }, [_o, ho]), b(() => {
2393
+ for (let [e, t] of fo.current) po(t, e);
2394
+ }, [ho, po]), b(() => {
2401
2395
  let e = k.current;
2402
2396
  if (!e) return;
2403
2397
  let t = st({
2404
2398
  document: e.ownerDocument,
2405
- t: (e, t) => uo.current.dragT(e, t),
2399
+ t: (e, t) => co.current.dragT(e, t),
2406
2400
  preview: !1,
2407
2401
  autoScroll: { axis: "x" },
2408
2402
  onDrop: ({ items: e, target: t, reason: n, event: r }) => {
2409
2403
  if (t.kind !== "between") return;
2410
- let { resolved: i, effectiveState: a, requestState: o } = uo.current, s = e[0], c = Jt(i, s), l = jr(i, c, s, t.index);
2404
+ let { resolved: i, effectiveState: a, requestState: o } = co.current, s = e[0], c = Jt(i, s), l = jr(i, c, s, t.index);
2411
2405
  l !== null && o(Ht(a, s, l, c), "order", n === "keyboard" ? "keyboard" : "pointer", r);
2412
2406
  }
2413
- }), n = () => uo.current.resolved.map((e) => e.id), r = (t) => e.querySelector(`[data-part="column-header"][data-column="${CSS.escape(t)}"]`);
2407
+ }), n = () => co.current.resolved.map((e) => e.id), r = (t) => e.querySelector(`[data-part="column-header"][data-column="${CSS.escape(t)}"]`);
2414
2408
  t.registerContainer({
2415
2409
  key: "columns",
2416
2410
  items: n,
2417
2411
  orientation: "horizontal",
2418
2412
  element: () => e.querySelector("[data-part=\"head\"] > [data-part=\"header-row\"]:last-of-type"),
2419
2413
  itemElement: r,
2420
- label: () => uo.current.t("dragColumns"),
2421
- itemLabel: (e) => uo.current.labelOf(e)
2414
+ label: () => co.current.t("dragColumns"),
2415
+ itemLabel: (e) => co.current.labelOf(e)
2422
2416
  });
2423
2417
  let i = !1, a = t.subscribe((e) => {
2424
2418
  if (e.status !== "dragging") {
2425
- i && (po.current = !0), i = !1, co({
2419
+ i && (uo.current = !0), i = !1, oo({
2426
2420
  dragging: null,
2427
2421
  target: null,
2428
2422
  offset: null,
@@ -2433,78 +2427,78 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2433
2427
  i = !0;
2434
2428
  let t = e.items[0] ?? null, a = e.target && e.target.kind === "between" ? e.target : null, o = null, s = 0, c = null;
2435
2429
  if (a && t) {
2436
- let e = uo.current.resolved, i = Jt(e, t), l = e.find((e) => e.id === i[0]), u = e.find((e) => e.id === i[i.length - 1]), d = Math.max(l ? l.index - 1 : 0, Math.min(u ? u.index : e.length, a.index)), f = Pn.current, p = n(), m = d >= p.length, h = p[m ? p.length - 1 : d], g = h ? r(h) : null;
2430
+ let e = co.current.resolved, i = Jt(e, t), l = e.find((e) => e.id === i[0]), u = e.find((e) => e.id === i[i.length - 1]), d = Math.max(l ? l.index - 1 : 0, Math.min(u ? u.index : e.length, a.index)), f = Nn.current, p = n(), m = d >= p.length, h = p[m ? p.length - 1 : d], g = h ? r(h) : null;
2437
2431
  if (g && f) {
2438
2432
  let e = g.getBoundingClientRect(), t = f.getBoundingClientRect(), n = getComputedStyle(f).direction === "rtl", r = m === n ? e.left : e.right;
2439
2433
  o = n ? t.right - r - f.scrollLeft : r - t.left + f.scrollLeft, s = f.scrollTop, c = p[d] ?? null;
2440
2434
  }
2441
2435
  }
2442
- co({
2436
+ oo({
2443
2437
  dragging: t,
2444
2438
  target: c,
2445
2439
  offset: o,
2446
2440
  scrollTop: s
2447
2441
  });
2448
2442
  });
2449
- lo.current = t;
2450
- for (let [e, t] of mo.current) ho(t, e);
2451
- let o = fo.current;
2443
+ so.current = t;
2444
+ for (let [e, t] of fo.current) po(t, e);
2445
+ let o = lo.current;
2452
2446
  return () => {
2453
2447
  a();
2454
2448
  for (let e of o.values()) e();
2455
- o.clear(), t.destroy(), lo.current = null;
2449
+ o.clear(), t.destroy(), so.current = null;
2456
2450
  };
2457
2451
  }, []);
2458
- let vo = x(() => {
2452
+ let go = x(() => {
2459
2453
  let e = /* @__PURE__ */ new Map();
2460
2454
  for (let t of W.top) e.set(t.key, t);
2461
2455
  for (let t of G) t.kind === "row" && e.set(t.key, t);
2462
2456
  for (let t of W.bottom) e.set(t.key, t);
2463
2457
  return e;
2464
- }, [G, W]), yo = pi && !A && $r === "client" && I.sort.length === 0 && I.filter === null && I.search.trim() === "" && I.group.length === 0, [bo, xo] = C({
2458
+ }, [G, W]), _o = di && !A && Zr === "client" && I.sort.length === 0 && I.filter === null && I.search.trim() === "" && I.group.length === 0, [vo, yo] = C({
2465
2459
  dragging: null,
2466
2460
  offset: null,
2467
2461
  scrollLeft: 0
2468
- }), So = S(null), Co = S(/* @__PURE__ */ new Map()), wo = S(/* @__PURE__ */ new Map()), To = y((e) => {
2469
- let t = vo.get(e), n = c.find((e) => e.rowHeader);
2470
- return t && n ? ht(n, t.row, zr) : e;
2462
+ }), bo = S(null), xo = S(/* @__PURE__ */ new Map()), So = S(/* @__PURE__ */ new Map()), Co = y((e) => {
2463
+ let t = go.get(e), n = c.find((e) => e.rowHeader);
2464
+ return t && n ? ht(n, t.row, Lr) : e;
2471
2465
  }, [
2472
- vo,
2466
+ go,
2473
2467
  c,
2474
- zr
2475
- ]), Eo = S({
2476
- nodeByKey: vo,
2477
- mountedNodes: ta,
2478
- rowsReorderableNow: yo,
2468
+ Lr
2469
+ ]), wo = S({
2470
+ nodeByKey: go,
2471
+ mountedNodes: $i,
2472
+ rowsReorderableNow: _o,
2479
2473
  onRowsReorder: Ie,
2480
- labelOf: To,
2474
+ labelOf: Co,
2481
2475
  t: j,
2482
- dragT: Zn
2476
+ dragT: Xn
2483
2477
  });
2484
- Eo.current = {
2485
- nodeByKey: vo,
2486
- mountedNodes: ta,
2487
- rowsReorderableNow: yo,
2478
+ wo.current = {
2479
+ nodeByKey: go,
2480
+ mountedNodes: $i,
2481
+ rowsReorderableNow: _o,
2488
2482
  onRowsReorder: Ie,
2489
- labelOf: To,
2483
+ labelOf: Co,
2490
2484
  t: j,
2491
- dragT: Zn
2485
+ dragT: Xn
2492
2486
  };
2493
- let Do = y((e, t) => {
2494
- let n = So.current;
2495
- if (wo.current.get(t)?.(), wo.current.delete(t), !e || !n) return;
2487
+ let To = y((e, t) => {
2488
+ let n = bo.current;
2489
+ if (So.current.get(t)?.(), So.current.delete(t), !e || !n) return;
2496
2490
  let r = n.attachDraggable(e, {
2497
2491
  container: "rows",
2498
2492
  key: t,
2499
2493
  handle: () => e.querySelector("[data-part=\"row-handle\"]"),
2500
- disabled: () => !Eo.current.rowsReorderableNow,
2494
+ disabled: () => !wo.current.rowsReorderableNow,
2501
2495
  distance: 6
2502
2496
  });
2503
- wo.current.set(t, r);
2504
- }, []), Oo = y((e, t) => {
2505
- e ? Co.current.set(t, e) : Co.current.delete(t), Do(e, t);
2506
- }, [Do]), ko = y((e, t) => {
2507
- let { nodeByKey: n, mountedNodes: r } = Eo.current, i = n.get(e);
2497
+ So.current.set(t, r);
2498
+ }, []), Eo = y((e, t) => {
2499
+ e ? xo.current.set(t, e) : xo.current.delete(t), To(e, t);
2500
+ }, [To]), Do = y((e, t) => {
2501
+ let { nodeByKey: n, mountedNodes: r } = wo.current, i = n.get(e);
2508
2502
  if (!i) return null;
2509
2503
  let a = r.filter((e) => e.kind === "row"), o = a[a.length - 1], s = a[t], c = s && s.kind === "row" ? s.index : o && o.kind === "row" ? o.index + 1 : 0, l = i.index < c ? c - 1 : c;
2510
2504
  return l === i.index ? null : {
@@ -2516,41 +2510,41 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2516
2510
  }, []);
2517
2511
  b(() => {
2518
2512
  let e = k.current;
2519
- if (!e || !pi) return;
2513
+ if (!e || !di) return;
2520
2514
  let t = st({
2521
2515
  document: e.ownerDocument,
2522
- t: (e, t) => Eo.current.dragT(e, t),
2516
+ t: (e, t) => wo.current.dragT(e, t),
2523
2517
  preview: !1,
2524
2518
  autoScroll: { axis: "y" },
2525
2519
  onDrop: ({ items: e, target: t, reason: n, event: r }) => {
2526
2520
  if (t.kind !== "between") return;
2527
- let i = ko(e[0], t.index);
2528
- i && Eo.current.onRowsReorder?.({
2521
+ let i = Do(e[0], t.index);
2522
+ i && wo.current.onRowsReorder?.({
2529
2523
  ...i,
2530
2524
  reason: n === "keyboard" ? "keyboard" : "pointer",
2531
2525
  event: r
2532
2526
  });
2533
2527
  }
2534
- }), n = () => Eo.current.mountedNodes.flatMap((e) => e.kind === "row" ? [e.key] : []), r = (t) => e.querySelector(`[data-part="body"] > [data-part="row"][data-row="${CSS.escape(t)}"]`);
2528
+ }), n = () => wo.current.mountedNodes.flatMap((e) => e.kind === "row" ? [e.key] : []), r = (t) => e.querySelector(`[data-part="body"] > [data-part="row"][data-row="${CSS.escape(t)}"]`);
2535
2529
  t.registerContainer({
2536
2530
  key: "rows",
2537
2531
  items: n,
2538
2532
  orientation: "vertical",
2539
2533
  element: () => e.querySelector("[data-part=\"body\"]"),
2540
2534
  itemElement: r,
2541
- label: () => Eo.current.t("dragRows"),
2542
- itemLabel: (e) => Eo.current.labelOf(e)
2535
+ label: () => wo.current.t("dragRows"),
2536
+ itemLabel: (e) => wo.current.labelOf(e)
2543
2537
  });
2544
2538
  let i = t.subscribe((e) => {
2545
2539
  if (e.status !== "dragging") {
2546
- xo({
2540
+ yo({
2547
2541
  dragging: null,
2548
2542
  offset: null,
2549
2543
  scrollLeft: 0
2550
2544
  });
2551
2545
  return;
2552
2546
  }
2553
- let t = e.items[0] ?? null, i = e.target && e.target.kind === "between" ? e.target : null, a = null, o = 0, s = Pn.current;
2547
+ let t = e.items[0] ?? null, i = e.target && e.target.kind === "between" ? e.target : null, a = null, o = 0, s = Nn.current;
2554
2548
  if (i && s) {
2555
2549
  let e = n(), t = i.index >= e.length, c = e[t ? e.length - 1 : i.index], l = c ? r(c) : null;
2556
2550
  if (l) {
@@ -2558,150 +2552,150 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2558
2552
  a = (t ? e.bottom : e.top) - n.top + s.scrollTop, o = Math.abs(s.scrollLeft);
2559
2553
  }
2560
2554
  }
2561
- xo({
2555
+ yo({
2562
2556
  dragging: t,
2563
2557
  offset: a,
2564
2558
  scrollLeft: o
2565
2559
  });
2566
2560
  });
2567
- So.current = t;
2568
- for (let [e, t] of Co.current) Do(t, e);
2569
- let a = wo.current;
2561
+ bo.current = t;
2562
+ for (let [e, t] of xo.current) To(t, e);
2563
+ let a = So.current;
2570
2564
  return () => {
2571
2565
  i();
2572
2566
  for (let e of a.values()) e();
2573
- a.clear(), t.destroy(), So.current = null;
2567
+ a.clear(), t.destroy(), bo.current = null;
2574
2568
  };
2575
2569
  }, [
2576
- pi,
2577
- Do,
2578
- ko
2570
+ di,
2571
+ To,
2572
+ Do
2579
2573
  ]);
2580
- let Ao = y((e, t, n) => {
2581
- if (!Eo.current.rowsReorderableNow) return;
2582
- let r = Eo.current.mountedNodes.filter((e) => e.kind === "row").findIndex((t) => t.key === e);
2574
+ let Oo = y((e, t, n) => {
2575
+ if (!wo.current.rowsReorderableNow) return;
2576
+ let r = wo.current.mountedNodes.filter((e) => e.kind === "row").findIndex((t) => t.key === e);
2583
2577
  if (r < 0) return;
2584
2578
  let i = t > 0 ? r + 2 : r - 1;
2585
2579
  if (i < 0) return;
2586
- let a = ko(e, i);
2580
+ let a = Do(e, i);
2587
2581
  a && (Ie?.({
2588
2582
  ...a,
2589
2583
  reason: "keyboard",
2590
2584
  event: n
2591
2585
  }), Z(j("rowMoved", {
2592
- row: Eo.current.labelOf(e),
2586
+ row: wo.current.labelOf(e),
2593
2587
  position: a.to + 1
2594
2588
  })));
2595
2589
  }, [
2596
- ko,
2590
+ Do,
2597
2591
  Ie,
2598
2592
  Z,
2599
2593
  j
2600
- ]), jo = ve === !0 ? _n : ve || 0, Mo = S(/* @__PURE__ */ new Map()), No = S(0), [Po, Fo] = C(0), Io = S(null), Lo = S(null);
2594
+ ]), ko = ve === !0 ? _n : ve || 0, Ao = S(/* @__PURE__ */ new Map()), jo = S(0), [Mo, No] = C(0), Po = S(null), Fo = S(null);
2601
2595
  b(() => {
2602
- if (jo <= 0) {
2603
- Lo.current = null;
2596
+ if (ko <= 0) {
2597
+ Fo.current = null;
2604
2598
  return;
2605
2599
  }
2606
- let e = Lo.current, t = /* @__PURE__ */ new Map();
2600
+ let e = Fo.current, t = /* @__PURE__ */ new Map();
2607
2601
  for (let e of L) t.set(P(e), e);
2608
- if (Lo.current = {
2602
+ if (Fo.current = {
2609
2603
  rows: L,
2610
2604
  byKey: t
2611
2605
  }, !e || e.rows === L) return;
2612
2606
  let n = Date.now(), r = !1;
2613
2607
  for (let t of [
2614
2608
  ...W.top,
2615
- ...ta,
2609
+ ...$i,
2616
2610
  ...W.bottom
2617
2611
  ]) {
2618
2612
  if (t.kind !== "row") continue;
2619
2613
  let i = e.byKey.get(t.key);
2620
- if (i !== void 0 && i !== t.row) for (let e of V) Object.is(gt(e.column, i), gt(e.column, t.row)) || (Mo.current.set(`${t.key}\u0000${e.id}`, {
2621
- until: n + jo,
2622
- generation: No.current + 1
2614
+ if (i !== void 0 && i !== t.row) for (let e of V) Object.is(gt(e.column, i), gt(e.column, t.row)) || (Ao.current.set(`${t.key}\u0000${e.id}`, {
2615
+ until: n + ko,
2616
+ generation: jo.current + 1
2623
2617
  }), r = !0);
2624
2618
  }
2625
- if (r && (No.current += 1, Fo((e) => e + 1), Io.current === null)) {
2619
+ if (r && (jo.current += 1, No((e) => e + 1), Po.current === null)) {
2626
2620
  let e = () => {
2627
- Io.current = null;
2621
+ Po.current = null;
2628
2622
  let t = Date.now(), n = Infinity;
2629
- for (let [e, r] of Mo.current) r.until <= t ? Mo.current.delete(e) : n = Math.min(n, r.until);
2630
- Fo((e) => e + 1), n !== Infinity && (Io.current = setTimeout(e, Math.max(16, n - t)));
2623
+ for (let [e, r] of Ao.current) r.until <= t ? Ao.current.delete(e) : n = Math.min(n, r.until);
2624
+ No((e) => e + 1), n !== Infinity && (Po.current = setTimeout(e, Math.max(16, n - t)));
2631
2625
  };
2632
- Io.current = setTimeout(e, jo);
2626
+ Po.current = setTimeout(e, ko);
2633
2627
  }
2634
2628
  }, [
2635
2629
  L,
2636
2630
  P,
2637
- ta,
2631
+ $i,
2638
2632
  W,
2639
2633
  V,
2640
- jo
2634
+ ko
2641
2635
  ]), b(() => () => {
2642
- Io.current !== null && clearTimeout(Io.current);
2636
+ Po.current !== null && clearTimeout(Po.current);
2643
2637
  }, []);
2644
- let Ro = y((e) => {
2645
- let t = Mo.current.get(`${e.row}\u0000${e.column}`);
2638
+ let Io = y((e) => {
2639
+ let t = Ao.current.get(`${e.row}\u0000${e.column}`);
2646
2640
  return t ? t.generation % 2 == 0 ? "a" : "b" : null;
2647
- }, [Po]), zo = x(() => new Set(ci), [ci]), Bo = y((e) => zo.has(e), [zo]), Vo = y((e, t, n = "pointer") => {
2648
- let r = zo.has(e) ? ci.filter((t) => t !== e) : [...ci, e];
2649
- li(r, n, t);
2641
+ }, [Mo]), Lo = x(() => new Set(oi), [oi]), Ro = y((e) => Lo.has(e), [Lo]), zo = y((e, t, n = "pointer") => {
2642
+ let r = Lo.has(e) ? oi.filter((t) => t !== e) : [...oi, e];
2643
+ si(r, n, t);
2650
2644
  }, [
2651
- zo,
2652
- ci,
2653
- li
2654
- ]), Ho = x(() => A ? A.column && H.has(A.column) ? A.column : V[0]?.id ?? null : null, [
2645
+ Lo,
2646
+ oi,
2647
+ si
2648
+ ]), Bo = x(() => A ? A.column && H.has(A.column) ? A.column : V[0]?.id ?? null : null, [
2655
2649
  A,
2656
2650
  H,
2657
2651
  V
2658
- ]), [Uo, Wo] = C(/* @__PURE__ */ new Set()), Go = y((e) => Uo.has(e), [Uo]), Ko = y((e) => A?.hasChildren?.(e) === !0, [A]);
2652
+ ]), [Vo, Ho] = C(/* @__PURE__ */ new Set()), Uo = y((e) => Vo.has(e), [Vo]), Wo = y((e) => A?.hasChildren?.(e) === !0, [A]);
2659
2653
  b(() => {
2660
- if (Uo.size === 0) return;
2661
- let e = new Set(Uo);
2662
- for (let t of Uo) {
2663
- let n = vo.get(t);
2664
- (!n || !zo.has(t) || n.childCount > 0) && e.delete(t);
2654
+ if (Vo.size === 0) return;
2655
+ let e = new Set(Vo);
2656
+ for (let t of Vo) {
2657
+ let n = go.get(t);
2658
+ (!n || !Lo.has(t) || n.childCount > 0) && e.delete(t);
2665
2659
  }
2666
- e.size !== Uo.size && Wo(e);
2660
+ e.size !== Vo.size && Ho(e);
2667
2661
  }, [
2668
- Uo,
2669
- vo,
2670
- zo
2662
+ Vo,
2663
+ go,
2664
+ Lo
2671
2665
  ]);
2672
- let qo = y((e, t, n = "pointer") => {
2673
- let r = vo.get(e);
2666
+ let Go = y((e, t, n = "pointer") => {
2667
+ let r = go.get(e);
2674
2668
  if (!r) return;
2675
- let i = !zo.has(e);
2676
- Vo(e, t, n), i && r.childCount === 0 && A?.hasChildren?.(r.row) && Fe && (Wo((t) => new Set(t).add(e)), Fe({
2669
+ let i = !Lo.has(e);
2670
+ zo(e, t, n), i && r.childCount === 0 && A?.hasChildren?.(r.row) && Fe && (Ho((t) => new Set(t).add(e)), Fe({
2677
2671
  key: e,
2678
2672
  row: r.row
2679
2673
  }));
2680
2674
  }, [
2681
- vo,
2675
+ go,
2676
+ Lo,
2682
2677
  zo,
2683
- Vo,
2684
2678
  A,
2685
2679
  Fe
2686
- ]), Jo = x(() => G.filter((e) => e.kind === "group").map((e) => e.key), [G]), Yo = y((e, t, n = "pointer") => {
2687
- let r = ui === "all" || ui.includes(e), i;
2688
- i = ui === "all" ? Jo.filter((t) => t !== e && !t.startsWith(`${e}/`)) : r ? ui.filter((t) => t !== e) : [...ui, e], di(i, n, t);
2680
+ ]), Ko = x(() => G.filter((e) => e.kind === "group").map((e) => e.key), [G]), qo = y((e, t, n = "pointer") => {
2681
+ let r = ci === "all" || ci.includes(e), i;
2682
+ i = ci === "all" ? Ko.filter((t) => t !== e && !t.startsWith(`${e}/`)) : r ? ci.filter((t) => t !== e) : [...ci, e], li(i, n, t);
2689
2683
  }, [
2690
- ui,
2691
- Jo,
2692
- di
2693
- ]), [Xo, Zo] = C(null), Qo = S(Xo);
2694
- Qo.current = Xo;
2695
- let Q = y((e) => vo.get(e)?.row, [vo]), $o = y((e, t = null) => {
2684
+ ci,
2685
+ Ko,
2686
+ li
2687
+ ]), [Jo, Yo] = C(null), Xo = S(Jo);
2688
+ Xo.current = Jo;
2689
+ let Q = y((e) => go.get(e)?.row, [go]), Zo = y((e, t = null) => {
2696
2690
  let n = Q(e.row), r = c.find((t) => t.id === e.column);
2697
2691
  if (!n || !r || !F(r, n)) return;
2698
- let i = ir === "row" ? c.filter((e) => F(e, n)).map((e) => e.id) : [e.column], a = {};
2692
+ let i = rr === "row" ? c.filter((e) => F(e, n)).map((e) => e.id) : [e.column], a = {};
2699
2693
  for (let e of i) {
2700
2694
  let t = c.find((t) => t.id === e);
2701
2695
  a[e] = gt(t, n);
2702
2696
  }
2703
2697
  let o = { ...a };
2704
- t !== null && (o[e.column] = r.kind === "number" ? Number(t) : t), Zo({
2698
+ t !== null && (o[e.column] = r.kind === "number" ? Number(t) : t), Yo({
2705
2699
  cell: e,
2706
2700
  columns: i,
2707
2701
  drafts: o,
@@ -2709,14 +2703,14 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2709
2703
  status: "editing",
2710
2704
  messages: {},
2711
2705
  seed: t
2712
- }), Me?.(e), Ea.current = e;
2706
+ }), Me?.(e), wa.current = e;
2713
2707
  }, [
2714
2708
  Q,
2715
2709
  c,
2716
2710
  F,
2717
- ir,
2711
+ rr,
2718
2712
  Me
2719
- ]), es = y((e, t) => {
2713
+ ]), Qo = y((e, t) => {
2720
2714
  let n = (n) => n && {
2721
2715
  ...n,
2722
2716
  drafts: {
@@ -2725,11 +2719,11 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2725
2719
  },
2726
2720
  status: "editing"
2727
2721
  };
2728
- Qo.current = n(Qo.current), Zo(n);
2729
- }, []), ts = y(() => {
2730
- let e = Qo.current;
2731
- e && (Zo(null), Ae?.(e.cell), Ea.current = e.cell);
2732
- }, [Ae]), ns = y((e, t) => {
2722
+ Xo.current = n(Xo.current), Yo(n);
2723
+ }, []), $o = y(() => {
2724
+ let e = Xo.current;
2725
+ e && (Yo(null), Ae?.(e.cell), wa.current = e.cell);
2726
+ }, [Ae]), es = y((e, t) => {
2733
2727
  if (t === "down") {
2734
2728
  let t = Tt(Y, e, "down");
2735
2729
  return E(t, e) || !Mr(t.row) ? null : t;
@@ -2751,18 +2745,18 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2751
2745
  c,
2752
2746
  F
2753
2747
  ]), $ = y((e, t = {}) => {
2754
- let n = Qo.current;
2748
+ let n = Xo.current;
2755
2749
  if (!n || n.status === "pending") return;
2756
2750
  let r = Q(n.cell.row);
2757
2751
  if (!r) {
2758
- Zo(null);
2752
+ Yo(null);
2759
2753
  return;
2760
2754
  }
2761
2755
  let i = {};
2762
2756
  for (let e of n.columns) Object.is(n.drafts[e], n.originals[e]) || (i[e] = n.drafts[e]);
2763
2757
  let a = () => {
2764
- let e = t.move ?? "stay", r = e === "stay" ? null : ns(n.cell, e);
2765
- Zo(null), r ? (Oa(r, "keyboard"), ir === "cell" && e !== "down" && $o(r)) : Ea.current = n.cell;
2758
+ let e = t.move ?? "stay", r = e === "stay" ? null : es(n.cell, e);
2759
+ Yo(null), r ? (Ea(r, "keyboard"), rr === "cell" && e !== "down" && Zo(r)) : wa.current = n.cell;
2766
2760
  };
2767
2761
  if (Object.keys(i).length === 0) {
2768
2762
  a();
@@ -2779,17 +2773,17 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2779
2773
  return e;
2780
2774
  };
2781
2775
  (async () => {
2782
- Zo((e) => e && {
2776
+ Yo((e) => e && {
2783
2777
  ...e,
2784
2778
  status: "pending"
2785
2779
  });
2786
2780
  let t = await o();
2787
2781
  if (Object.keys(t).length > 0) {
2788
- Zo((e) => e && {
2782
+ Yo((e) => e && {
2789
2783
  ...e,
2790
2784
  status: "invalid",
2791
2785
  messages: t
2792
- }), Ea.current = n.cell;
2786
+ }), wa.current = n.cell;
2793
2787
  return;
2794
2788
  }
2795
2789
  let s = n.cell.column in i ? n.cell.column : Object.keys(i)[0];
@@ -2805,34 +2799,34 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2805
2799
  }), a();
2806
2800
  } catch (e) {
2807
2801
  let t = e instanceof Error && e.message ? e.message : j("editFailed");
2808
- Zo((e) => e && {
2802
+ Yo((e) => e && {
2809
2803
  ...e,
2810
2804
  status: "invalid",
2811
2805
  messages: { [s]: t }
2812
- }), Ea.current = n.cell;
2806
+ }), wa.current = n.cell;
2813
2807
  }
2814
2808
  })();
2815
2809
  }, [
2816
2810
  Q,
2817
- ns,
2818
- Oa,
2819
- ir,
2820
- $o,
2811
+ es,
2812
+ Ea,
2813
+ rr,
2814
+ Zo,
2821
2815
  c,
2822
2816
  je,
2823
2817
  j
2824
- ]), rs = j("editConflict");
2818
+ ]), ts = j("editConflict");
2825
2819
  b(() => {
2826
- let e = Qo.current;
2820
+ let e = Xo.current;
2827
2821
  if (!e || e.status === "pending") return;
2828
2822
  let t = Q(e.cell.row);
2829
2823
  if (!t) return;
2830
2824
  let n = {};
2831
2825
  for (let r of e.columns) {
2832
2826
  let i = c.find((e) => e.id === r);
2833
- i && !Object.is(gt(i, t), e.originals[r]) && (n[r] = rs);
2827
+ i && !Object.is(gt(i, t), e.originals[r]) && (n[r] = ts);
2834
2828
  }
2835
- Object.keys(n).length > 0 && Zo({
2829
+ Object.keys(n).length > 0 && Yo({
2836
2830
  ...e,
2837
2831
  status: "invalid",
2838
2832
  messages: {
@@ -2844,9 +2838,9 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2844
2838
  L,
2845
2839
  Q,
2846
2840
  c,
2847
- rs
2841
+ ts
2848
2842
  ]);
2849
- let is = y((e, t, n) => {
2843
+ let ns = y((e, t, n) => {
2850
2844
  De?.({
2851
2845
  key: e,
2852
2846
  reason: t,
@@ -2854,10 +2848,10 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2854
2848
  });
2855
2849
  }, [De]);
2856
2850
  b(() => {
2857
- let e = Pn.current;
2851
+ let e = Nn.current;
2858
2852
  if (!e) return;
2859
2853
  let t = 0, n = () => {
2860
- t = 0, Ui(e.scrollTop), Gi(Math.abs(e.scrollLeft));
2854
+ t = 0, Vi(e.scrollTop), Ui(Math.abs(e.scrollLeft));
2861
2855
  }, r = () => {
2862
2856
  t === 0 && (t = requestAnimationFrame(n));
2863
2857
  };
@@ -2866,17 +2860,17 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2866
2860
  let t = e.querySelector(":scope > [data-part=\"head\"]"), n = e.querySelector(":scope > [data-part=\"summary\"]");
2867
2861
  e.style.setProperty("--slotted-data-grid-pinned-top-offset", `${t?.offsetHeight ?? 0}px`), e.style.setProperty("--slotted-data-grid-pinned-bottom-offset", `${n?.offsetHeight ?? 0}px`);
2868
2862
  }, a = typeof ResizeObserver > "u" ? null : new ResizeObserver(() => {
2869
- Ki({
2863
+ Wi({
2870
2864
  width: e.clientWidth,
2871
2865
  height: e.clientHeight
2872
- }), yi(e.clientWidth), i();
2866
+ }), _i(e.clientWidth), i();
2873
2867
  });
2874
2868
  a?.observe(e);
2875
2869
  for (let t of e.querySelectorAll(":scope > [data-part=\"head\"], :scope > [data-part=\"summary\"]")) a?.observe(t);
2876
- Ki({
2870
+ Wi({
2877
2871
  width: e.clientWidth,
2878
2872
  height: e.clientHeight
2879
- }), a && yi(e.clientWidth), i();
2873
+ }), a && _i(e.clientWidth), i();
2880
2874
  let o = Ue(e, {
2881
2875
  orientation: () => "horizontal",
2882
2876
  onChange: (t) => {
@@ -2887,34 +2881,34 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2887
2881
  e.removeEventListener("scroll", r), t && cancelAnimationFrame(t), a?.disconnect(), o.destroy();
2888
2882
  };
2889
2883
  }, []);
2890
- let as = Ti ? `${Ci}\u0002${vi}` : Ci, os = y((e, t) => {
2884
+ let rs = Ci ? `${xi}\u0002${gi}` : xi, is = y((e, t) => {
2891
2885
  if (!t) return;
2892
- let n = typeof sr != "number" && qi === null;
2893
- if (!n && !Zi) return;
2886
+ let n = typeof or != "number" && Gi === null;
2887
+ if (!n && !Yi) return;
2894
2888
  let r = t.getBoundingClientRect().height;
2895
- r !== 0 && (n && Ji(Math.round(r)), Zi && Xi((t) => t.get(e) === r ? t : new Map(t).set(e, r)));
2889
+ r !== 0 && (n && Ki(Math.round(r)), Yi && Ji((t) => t.get(e) === r ? t : new Map(t).set(e, r)));
2896
2890
  }, [
2897
- sr,
2898
- qi,
2899
- Zi,
2900
- as
2901
- ]), ss = Ve !== void 0 && Jr === !0 && !Xr && Nr !== "button" && Se !== !0, cs = Math.max(0, G.length - Ar), ls = $i ? $i.offsetOf(cs) : cs * q, us = S(null), ds = S(Ve);
2902
- ds.current = Ve, b(() => {
2903
- let e = us.current;
2904
- if (!ss || e === null || typeof IntersectionObserver > "u") return;
2891
+ or,
2892
+ Gi,
2893
+ Yi,
2894
+ rs
2895
+ ]), as = Ve !== void 0 && Kr === !0 && !Jr && Ar !== "button" && Se !== !0, os = Math.max(0, G.length - ur), ss = Zi ? Zi.offsetOf(os) : os * q, cs = S(null), ls = S(Ve);
2896
+ ls.current = Ve, b(() => {
2897
+ let e = cs.current;
2898
+ if (!as || e === null || typeof IntersectionObserver > "u") return;
2905
2899
  let t = new IntersectionObserver((e) => {
2906
- e.some((e) => e.isIntersecting) && ds.current?.();
2900
+ e.some((e) => e.isIntersecting) && ls.current?.();
2907
2901
  });
2908
2902
  return t.observe(e), () => t.disconnect();
2909
2903
  }, [
2910
- ss,
2904
+ as,
2911
2905
  G.length,
2912
- ls
2906
+ ss
2913
2907
  ]);
2914
- let fs = () => k.current ? getComputedStyle(k.current).direction === "rtl" : !1, ps = y(async (e) => {
2908
+ let us = () => k.current ? getComputedStyle(k.current).direction === "rtl" : !1, ds = y(async (e) => {
2915
2909
  let t = X ? kt(Y, X) : [[e]], n = jt(t, (e) => {
2916
2910
  let t = Q(e.row), n = c.find((t) => t.id === e.column);
2917
- return t && n ? Br(n, t) : "";
2911
+ return t && n ? Rr(n, t) : "";
2918
2912
  });
2919
2913
  await ot(n, k.current?.ownerDocument) !== "refused" && Z(j("copied", { count: t.reduce((e, t) => e + t.length, 0) }));
2920
2914
  }, [
@@ -2922,23 +2916,23 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2922
2916
  Y,
2923
2917
  Q,
2924
2918
  c,
2925
- Br,
2919
+ Rr,
2926
2920
  Z,
2927
2921
  j
2928
- ]), ms = y((e, t) => {
2922
+ ]), fs = y((e, t) => {
2929
2923
  if (e.defaultPrevented) return;
2930
- let n = Qo.current, r = e.target, i = e.currentTarget, a = r !== i, o = e.key, s = fs();
2924
+ let n = Xo.current, r = e.target, i = e.currentTarget, a = r !== i, o = e.key, s = us();
2931
2925
  if (n && E(n.cell, t)) {
2932
2926
  if (o === "Escape") {
2933
- e.preventDefault(), e.stopPropagation(), ts();
2927
+ e.preventDefault(), e.stopPropagation(), $o();
2934
2928
  return;
2935
2929
  }
2936
2930
  if (o === "Enter") {
2937
- e.preventDefault(), $("keyboard", { move: ir === "cell" ? "down" : "stay" });
2931
+ e.preventDefault(), $("keyboard", { move: rr === "cell" ? "down" : "stay" });
2938
2932
  return;
2939
2933
  }
2940
2934
  if (o === "Tab") {
2941
- ns(t, e.shiftKey ? "previous" : "next") ? (e.preventDefault(), $("keyboard", { move: e.shiftKey ? "previous" : "next" })) : $("keyboard", { move: "stay" });
2935
+ es(t, e.shiftKey ? "previous" : "next") ? (e.preventDefault(), $("keyboard", { move: e.shiftKey ? "previous" : "next" })) : $("keyboard", { move: "stay" });
2942
2936
  return;
2943
2937
  }
2944
2938
  if (o === "F2") {
@@ -2949,7 +2943,7 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2949
2943
  }
2950
2944
  if (n && n.columns.includes(t.column) && n.cell.row === t.row) {
2951
2945
  if (o === "Escape") {
2952
- e.preventDefault(), ts();
2946
+ e.preventDefault(), $o();
2953
2947
  return;
2954
2948
  }
2955
2949
  if (o === "Enter") {
@@ -2992,17 +2986,17 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
2992
2986
  };
2993
2987
  if (c && l) {
2994
2988
  if ((o === "ContextMenu" || o === "F10" && e.shiftKey) && !r.closest(vr)) {
2995
- e.preventDefault(), Ua.current = Date.now(), Wa(t.column, i, i);
2989
+ e.preventDefault(), Va.current = Date.now(), Ha(t.column, i, i);
2996
2990
  return;
2997
2991
  }
2998
2992
  if ((e.ctrlKey || e.metaKey) && e.shiftKey && (o === "ArrowLeft" || o === "ArrowRight")) {
2999
2993
  e.preventDefault();
3000
2994
  let n = o === "ArrowRight" !== s;
3001
- $a(t.column, n ? ft : -ft, e);
2995
+ Za(t.column, n ? ft : -ft, e);
3002
2996
  return;
3003
2997
  }
3004
2998
  if ((e.ctrlKey || e.metaKey) && e.shiftKey && o === "Enter") {
3005
- e.preventDefault(), ro(t.column, "keyboard", e);
2999
+ e.preventDefault(), to(t.column, "keyboard", e);
3006
3000
  return;
3007
3001
  }
3008
3002
  if (o === "F2" && !a) {
@@ -3013,56 +3007,56 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3013
3007
  if (e.altKey && (o === "ArrowLeft" || o === "ArrowRight")) {
3014
3008
  e.preventDefault();
3015
3009
  let n = o === "ArrowRight" !== s;
3016
- io(t.column, n ? 1 : -1, e), Ea.current = t;
3010
+ no(t.column, n ? 1 : -1, e), wa.current = t;
3017
3011
  return;
3018
3012
  }
3019
3013
  if ((e.ctrlKey || e.metaKey) && o === "Enter") {
3020
- e.preventDefault(), Ga(), Ba(t.column);
3014
+ e.preventDefault(), Ua(), Ra(t.column);
3021
3015
  return;
3022
3016
  }
3023
3017
  if (o === "Enter" || o === " ") {
3024
3018
  if (a) return;
3025
- e.preventDefault(), Na(t.column, e.shiftKey, e, "keyboard");
3019
+ e.preventDefault(), ja(t.column, e.shiftKey, e, "keyboard");
3026
3020
  return;
3027
3021
  }
3028
3022
  }
3029
3023
  if (wt(t.row) && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
3030
- let n = t.row.slice(lt.length), r = ui === "all" || ui.includes(n);
3024
+ let n = t.row.slice(lt.length), r = ci === "all" || ci.includes(n);
3031
3025
  if (o === "ArrowRight" !== s !== r) {
3032
- e.preventDefault(), Yo(n, e, "keyboard");
3026
+ e.preventDefault(), qo(n, e, "keyboard");
3033
3027
  return;
3034
3028
  }
3035
3029
  }
3036
3030
  if (u && e.altKey && (o === "ArrowUp" || o === "ArrowDown")) {
3037
- e.preventDefault(), Ao(t.row, o === "ArrowDown" ? 1 : -1, e), Ea.current = t;
3031
+ e.preventDefault(), Oo(t.row, o === "ArrowDown" ? 1 : -1, e), wa.current = t;
3038
3032
  return;
3039
3033
  }
3040
- if (u && Ho !== null && t.column === Ho && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
3041
- let n = vo.get(t.row), r = n !== void 0 && (n.childCount > 0 || A?.hasChildren?.(u) === !0), i = o === "ArrowRight" !== s;
3034
+ if (u && Bo !== null && t.column === Bo && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey) {
3035
+ let n = go.get(t.row), r = n !== void 0 && (n.childCount > 0 || A?.hasChildren?.(u) === !0), i = o === "ArrowRight" !== s;
3042
3036
  if (n && r && i !== n.open) {
3043
- e.preventDefault(), qo(t.row, e, "keyboard");
3037
+ e.preventDefault(), Go(t.row, e, "keyboard");
3044
3038
  return;
3045
3039
  }
3046
3040
  if (n && !i && n.parent !== null) {
3047
- e.preventDefault(), Oa({
3041
+ e.preventDefault(), Ea({
3048
3042
  row: n.parent,
3049
3043
  column: t.column
3050
3044
  }, "keyboard", e);
3051
3045
  return;
3052
3046
  }
3053
3047
  }
3054
- if (u && t.column === "__expander" && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey && Wr(u)) {
3055
- let n = zo.has(t.row);
3048
+ if (u && t.column === "__expander" && (o === "ArrowRight" || o === "ArrowLeft") && !e.shiftKey && Hr(u)) {
3049
+ let n = Lo.has(t.row);
3056
3050
  if (o === "ArrowRight" !== s !== n) {
3057
- e.preventDefault(), Vo(t.row, e, "keyboard");
3051
+ e.preventDefault(), zo(t.row, e, "keyboard");
3058
3052
  return;
3059
3053
  }
3060
3054
  }
3061
3055
  if (o === " " && e.shiftKey && u) {
3062
3056
  if (e.preventDefault(), M === "range") {
3063
3057
  let n = Pt(Y, t.row);
3064
- n && oi(n, "keyboard", e);
3065
- } else ha(t.row, {
3058
+ n && ii(n, "keyboard", e);
3059
+ } else pa(t.row, {
3066
3060
  range: !1,
3067
3061
  source: e,
3068
3062
  reason: "keyboard"
@@ -3072,7 +3066,7 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3072
3066
  if (o === " " && (e.ctrlKey || e.metaKey) && M === "range" && l) {
3073
3067
  e.preventDefault();
3074
3068
  let n = vt(Y, t.column);
3075
- n && oi(n, "keyboard", e);
3069
+ n && ii(n, "keyboard", e);
3076
3070
  return;
3077
3071
  }
3078
3072
  if ((o === "a" || o === "A") && (e.ctrlKey || e.metaKey) && !a) {
@@ -3080,31 +3074,31 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3080
3074
  e.preventDefault(), (it({
3081
3075
  action: "all",
3082
3076
  mode: "multiple",
3083
- selected: sa,
3077
+ selected: aa,
3084
3078
  keys: J
3085
- }).changed || fa < J.length) && ma(J, "select", e);
3079
+ }).changed || ua < J.length) && fa(J, "select", e);
3086
3080
  return;
3087
3081
  }
3088
3082
  if (M === "range") {
3089
3083
  e.preventDefault();
3090
3084
  let t = zt(Y);
3091
- t && oi(t, "keyboard", e);
3085
+ t && ii(t, "keyboard", e);
3092
3086
  return;
3093
3087
  }
3094
3088
  }
3095
3089
  if ((o === "c" || o === "C") && (e.ctrlKey || e.metaKey) && !a) {
3096
3090
  let n = i.ownerDocument.getSelection();
3097
3091
  if (n && n.toString().length > 0) return;
3098
- e.preventDefault(), ps(t);
3092
+ e.preventDefault(), ds(t);
3099
3093
  return;
3100
3094
  }
3101
- if (o === "Escape" && M === "range" && ai) {
3102
- e.preventDefault(), oi(null, "clear", e);
3095
+ if (o === "Escape" && M === "range" && ri) {
3096
+ e.preventDefault(), ii(null, "clear", e);
3103
3097
  return;
3104
3098
  }
3105
3099
  if (u && (l || t.column === dt) && (o === "Enter" || o === "F2")) {
3106
3100
  if (l !== void 0 && F(l.column, u) && !a) {
3107
- e.preventDefault(), $o(t);
3101
+ e.preventDefault(), Zo(t);
3108
3102
  return;
3109
3103
  }
3110
3104
  let n = i.querySelectorAll(pn);
@@ -3112,166 +3106,166 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3112
3106
  e.preventDefault(), n[0].focus();
3113
3107
  return;
3114
3108
  }
3115
- if (o === "Enter" && Ir && !a) {
3116
- e.preventDefault(), is(t.row, "keyboard", e);
3109
+ if (o === "Enter" && Pr && !a) {
3110
+ e.preventDefault(), ns(t.row, "keyboard", e);
3117
3111
  return;
3118
3112
  }
3119
3113
  }
3120
3114
  if (u && l && !a && o.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey && (l.kind === "text" || l.kind === "number") && F(l.column, u)) {
3121
3115
  if (l.kind === "number" && !/[0-9.,-]/.test(o)) return;
3122
- e.preventDefault(), $o(t, o);
3116
+ e.preventDefault(), Zo(t, o);
3123
3117
  return;
3124
3118
  }
3125
3119
  let f = d[o];
3126
3120
  if (!f || a && (o === "ArrowLeft" || o === "ArrowRight" || o === "Home" || o === "End") && r.matches("input:not([type=\"checkbox\"]):not([type=\"radio\"]), textarea")) return;
3127
3121
  e.preventDefault();
3128
- let p = Li(Tt(Y, t, f));
3122
+ let p = Fi(Tt(Y, t, f));
3129
3123
  if (e.shiftKey && o.startsWith("Arrow")) {
3130
3124
  if (M === "range" && Mr(p.row)) {
3131
- let n = ai?.anchor ?? t;
3132
- oi({
3125
+ let n = ri?.anchor ?? t;
3126
+ ii({
3133
3127
  anchor: n,
3134
3128
  focus: p
3135
3129
  }, "keyboard", e);
3136
- } else M === "multiple" && (o === "ArrowUp" || o === "ArrowDown") && Mr(p.row) && ha(p.row, {
3130
+ } else M === "multiple" && (o === "ArrowUp" || o === "ArrowDown") && Mr(p.row) && pa(p.row, {
3137
3131
  range: !0,
3138
3132
  source: e,
3139
3133
  reason: "keyboard"
3140
3134
  });
3141
3135
  }
3142
- E(p, t) || Oa(p, "keyboard", e);
3136
+ E(p, t) || Ea(p, "keyboard", e);
3143
3137
  }, [
3144
- ts,
3138
+ $o,
3145
3139
  $,
3146
- ir,
3147
- ns,
3140
+ rr,
3141
+ es,
3148
3142
  H,
3149
3143
  Q,
3150
- $a,
3151
- ro,
3152
- io,
3153
- Na,
3154
- ui,
3155
- Yo,
3156
- Wr,
3144
+ Za,
3145
+ to,
3146
+ no,
3147
+ ja,
3148
+ ci,
3149
+ qo,
3150
+ Hr,
3151
+ Lo,
3157
3152
  zo,
3158
- Vo,
3159
- Ho,
3160
- vo,
3153
+ Bo,
3154
+ go,
3161
3155
  A,
3162
- qo,
3163
- Ao,
3156
+ Go,
3157
+ Oo,
3164
3158
  M,
3165
3159
  Y,
3166
- oi,
3167
- ha,
3168
- sa,
3160
+ ii,
3161
+ pa,
3162
+ aa,
3169
3163
  J,
3164
+ ua,
3170
3165
  fa,
3171
- ma,
3172
- ps,
3173
- ai,
3166
+ ds,
3167
+ ri,
3174
3168
  F,
3175
- $o,
3176
- Ir,
3177
- is,
3178
- Oa,
3179
- Wa,
3180
- Ga,
3181
- Li
3182
- ]), hs = S(""), gs = S(-Infinity), _s = y((e, t) => {
3183
- if (hs.current = e.pointerType ?? "", e.button !== 0) return;
3184
- po.current = !1;
3185
- let n = Qo.current;
3186
- n && !E(n.cell, t) && !(n.cell.row === t.row && n.columns.includes(t.column)) && $("blur", { move: "stay" }), E(t, z) || si(t, "pointer", e), M === "range" && Mr(t.row) && (gn(e) || (Sa(t, e.shiftKey, e), ba(!0)));
3169
+ Zo,
3170
+ Pr,
3171
+ ns,
3172
+ Ea,
3173
+ Ha,
3174
+ Ua,
3175
+ Fi
3176
+ ]), ps = S(""), ms = S(-Infinity), hs = y((e, t) => {
3177
+ if (ps.current = e.pointerType ?? "", e.button !== 0) return;
3178
+ uo.current = !1;
3179
+ let n = Xo.current;
3180
+ n && !E(n.cell, t) && !(n.cell.row === t.row && n.columns.includes(t.column)) && $("blur", { move: "stay" }), E(t, z) || ai(t, "pointer", e), M === "range" && Mr(t.row) && (gn(e) || (ba(t, e.shiftKey, e), va(!0)));
3187
3181
  }, [
3188
3182
  $,
3189
3183
  z,
3190
- si,
3184
+ ai,
3191
3185
  M,
3192
- Sa
3193
- ]), vs = y((e, t) => {
3194
- ya && e.buttons === 1 && Ca(t, e);
3195
- }, [ya, Ca]);
3186
+ ba
3187
+ ]), gs = y((e, t) => {
3188
+ _a && e.buttons === 1 && xa(t, e);
3189
+ }, [_a, xa]);
3196
3190
  b(() => {
3197
- if (!ya) return;
3198
- let e = () => ba(!1), t = k.current?.ownerDocument ?? document;
3191
+ if (!_a) return;
3192
+ let e = () => va(!1), t = k.current?.ownerDocument ?? document;
3199
3193
  return t.addEventListener("pointerup", e), t.addEventListener("pointercancel", e), () => {
3200
3194
  t.removeEventListener("pointerup", e), t.removeEventListener("pointercancel", e);
3201
3195
  };
3202
- }, [ya]);
3203
- let ys = y((e, t) => {
3204
- let n = hs.current;
3205
- if (hs.current = "", po.current) {
3206
- po.current = !1;
3196
+ }, [_a]);
3197
+ let _s = y((e, t) => {
3198
+ let n = ps.current;
3199
+ if (ps.current = "", uo.current) {
3200
+ uo.current = !1;
3207
3201
  return;
3208
3202
  }
3209
3203
  if (gn(e)) return;
3210
3204
  if (t.row === ut && H.get(t.column)?.sortable) {
3211
- Na(t.column, e.shiftKey, e, "pointer");
3205
+ ja(t.column, e.shiftKey, e, "pointer");
3212
3206
  return;
3213
3207
  }
3214
3208
  if (wt(t.row)) {
3215
- Yo(t.row.slice(lt.length), e);
3209
+ qo(t.row.slice(lt.length), e);
3216
3210
  return;
3217
3211
  }
3218
3212
  if (!Mr(t.row)) return;
3219
- M === "single" && !Vr.has(t.row) && ha(t.row, {
3213
+ M === "single" && !zr.has(t.row) && pa(t.row, {
3220
3214
  range: !1,
3221
3215
  source: e
3222
3216
  });
3223
- let r = Qo.current, i = r !== null && r.cell.row === t.row && r.columns.includes(t.column);
3224
- Ir && (n === "touch" || n === "pen") && !i && (gs.current = Date.now(), is(t.row, "pointer", e));
3217
+ let r = Xo.current, i = r !== null && r.cell.row === t.row && r.columns.includes(t.column);
3218
+ Pr && (n === "touch" || n === "pen") && !i && (ms.current = Date.now(), ns(t.row, "pointer", e));
3225
3219
  }, [
3226
3220
  H,
3227
- Na,
3228
- Yo,
3221
+ ja,
3222
+ qo,
3229
3223
  M,
3230
- Vr,
3231
- ha,
3232
- Ir,
3233
- is
3234
- ]), bs = y((e, t) => {
3235
- if (gn(e) || Date.now() - gs.current < br) return;
3224
+ zr,
3225
+ pa,
3226
+ Pr,
3227
+ ns
3228
+ ]), vs = y((e, t) => {
3229
+ if (gn(e) || Date.now() - ms.current < br) return;
3236
3230
  let n = Q(t.row), r = c.find((e) => e.id === t.column);
3237
3231
  if (n) {
3238
- if (r && F(r, n) && !Ir) {
3239
- $o(t);
3232
+ if (r && F(r, n) && !Pr) {
3233
+ Zo(t);
3240
3234
  return;
3241
3235
  }
3242
- Ir ? is(t.row, "pointer", e) : r && F(r, n) && $o(t);
3236
+ Pr ? ns(t.row, "pointer", e) : r && F(r, n) && Zo(t);
3243
3237
  }
3244
3238
  }, [
3245
3239
  Q,
3246
3240
  c,
3247
3241
  F,
3248
- Ir,
3249
- $o,
3250
- is
3251
- ]), xs = y((e) => {
3252
- Ta(!0), E(e, z) || si(e, "programmatic");
3253
- }, [z, si]), Ss = y(() => {}, []), Cs = y((e) => {
3242
+ Pr,
3243
+ Zo,
3244
+ ns
3245
+ ]), ys = y((e) => {
3246
+ Ca(!0), E(e, z) || ai(e, "programmatic");
3247
+ }, [z, ai]), bs = y(() => {}, []), xs = y((e) => {
3254
3248
  let t = e.relatedTarget;
3255
3249
  if (!t || !e.currentTarget.contains(t)) {
3256
- Ta(!1);
3257
- let e = Qo.current;
3250
+ Ca(!1);
3251
+ let e = Xo.current;
3258
3252
  e && e.status === "editing" && $("blur", { move: "stay" });
3259
3253
  }
3260
- }, [$]), ws = y((e) => {
3261
- let t = Fn.current.cellRenderers?.[e.column.id];
3262
- return t ? t(e) : Rn ? Rn(e) : Wn(e);
3263
- }, [Kn, Rn]), Ts = y((e) => {
3264
- let t = Fn.current.editorRenderers?.[e.column.id];
3265
- return t ? t(e) : Vn ? Vn(e) : Jn(e, j, N);
3254
+ }, [$]), Ss = y((e) => {
3255
+ let t = Pn.current.cellRenderers?.[e.column.id];
3256
+ return t ? t(e) : Fn ? Fn(e) : Wn(e);
3257
+ }, [Gn, Fn]), Cs = y((e) => {
3258
+ let t = Pn.current.editorRenderers?.[e.column.id];
3259
+ return t ? t(e) : zn ? zn(e) : Jn(e, j, N);
3266
3260
  }, [
3267
- qn,
3268
- Vn,
3261
+ Kn,
3262
+ zn,
3269
3263
  j,
3270
3264
  N
3271
- ]), Es = y((e, t = "nearest") => {
3272
- let n = G.findIndex((t) => t.key === e), r = Pn.current;
3265
+ ]), ws = y((e, t = "nearest") => {
3266
+ let n = G.findIndex((t) => t.key === e), r = Nn.current;
3273
3267
  if (n === -1 || !r) return;
3274
- let i = $i ? $i.offsetOf(n) : n * q, a = r.querySelector("[data-part=\"head\"]")?.offsetHeight ?? 0, o = i;
3268
+ let i = Zi ? Zi.offsetOf(n) : n * q, a = r.querySelector("[data-part=\"head\"]")?.offsetHeight ?? 0, o = i;
3275
3269
  if (t === "center") o = i - K.height / 2 + q;
3276
3270
  else if (t === "end") o = i - K.height + q + a;
3277
3271
  else if (t === "nearest") {
@@ -3279,367 +3273,365 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3279
3273
  if (i >= e && i + q <= t) return;
3280
3274
  o = i < e ? i : i - K.height + q + a;
3281
3275
  }
3282
- r.scrollTo({ top: Math.max(0, o) }), Qi && ra([e]);
3276
+ r.scrollTo({ top: Math.max(0, o) }), Xi && ta([e]);
3283
3277
  }, [
3284
3278
  G,
3285
- $i,
3279
+ Zi,
3286
3280
  q,
3287
3281
  K.height,
3288
- Qi
3289
- ]), Ds = y((e) => {
3290
- let t = Pn.current, n = H.get(e);
3282
+ Xi
3283
+ ]), Ts = y((e) => {
3284
+ let t = Nn.current, n = H.get(e);
3291
3285
  if (!t || !n || n.pinned) return;
3292
- let r = hi.reduce((e, t) => e + t, 0);
3286
+ let r = pi.reduce((e, t) => e + t, 0);
3293
3287
  for (let t of V) {
3294
3288
  if (t.id === e) break;
3295
3289
  (t.pinned === null || t.pinned === "start") && (r += t.width);
3296
3290
  }
3297
- let i = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0) + hi.reduce((e, t) => e + t, 0), a = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), o = Math.abs(t.scrollLeft);
3291
+ let i = V.filter((e) => e.pinned === "start").reduce((e, t) => e + t.width, 0) + pi.reduce((e, t) => e + t, 0), a = V.filter((e) => e.pinned === "end").reduce((e, t) => e + t.width, 0), o = Math.abs(t.scrollLeft);
3298
3292
  r < o + i ? t.scrollTo({ left: r - i }) : r + n.width > o + K.width - a && t.scrollTo({ left: r + n.width - K.width + a });
3299
3293
  }, [
3300
3294
  H,
3301
- hi,
3295
+ pi,
3302
3296
  V,
3303
3297
  K.width
3304
- ]), Os = y((e = {}) => {
3305
- let { filename: t, rows: n, columns: r, ...i } = e, a = $r === "client" ? Mi.rows : L, o = n === "selected" ? a.filter((e) => ca.has(P(e))) : a, s = r === "all" ? c : V.map((e) => e.column);
3298
+ ]), Es = y((e = {}) => {
3299
+ let { filename: t, rows: n, columns: r, ...i } = e, a = Zr === "client" ? Ai.rows : L, o = n === "selected" ? a.filter((e) => oa.has(P(e))) : a, s = r === "all" ? c : V.map((e) => e.column);
3306
3300
  return Rt(o, s, {
3307
3301
  locale: N,
3308
- timeZone: Sn,
3302
+ timeZone: bn,
3309
3303
  ...i,
3310
- booleans: i.booleans ?? zr.booleans
3304
+ booleans: i.booleans ?? Lr.booleans
3311
3305
  });
3312
3306
  }, [
3313
- $r,
3314
- Mi.rows,
3307
+ Zr,
3308
+ Ai.rows,
3315
3309
  L,
3316
- ca,
3310
+ oa,
3317
3311
  P,
3318
3312
  c,
3319
3313
  V,
3320
3314
  N,
3321
- Sn,
3322
- zr.booleans
3315
+ bn,
3316
+ Lr.booleans
3323
3317
  ]);
3324
3318
  ze(he, () => ({
3325
- focusCell: (e) => Oa(e, "programmatic"),
3326
- scrollToRow: Es,
3327
- scrollToColumn: Ds,
3319
+ focusCell: (e) => Ea(e, "programmatic"),
3320
+ scrollToRow: ws,
3321
+ scrollToColumn: Ts,
3328
3322
  scrollToCell: (e) => {
3329
- Es(e.row), Ds(e.column);
3323
+ ws(e.row), Ts(e.column);
3330
3324
  },
3331
3325
  startEdit: (e) => {
3332
- Oa(e, "programmatic"), $o(e);
3326
+ Ea(e, "programmatic"), Zo(e);
3333
3327
  },
3334
- stopEdit: (e) => e?.commit === !1 ? ts() : $("programmatic"),
3335
- autofit: (e) => ro(e ?? null, "programmatic"),
3328
+ stopEdit: (e) => e?.commit === !1 ? $o() : $("programmatic"),
3329
+ autofit: (e) => to(e ?? null, "programmatic"),
3336
3330
  getOutOfSpace: () => B,
3337
- getVisibleRows: () => $r === "client" ? Mi.rows : L,
3338
- toCsv: Os,
3339
- reload: Kr.reload,
3331
+ getVisibleRows: () => Zr === "client" ? Ai.rows : L,
3332
+ toCsv: Es,
3333
+ reload: Wr.reload,
3340
3334
  exportCsv: (e = {}) => {
3341
- let t = Os(e), n = k.current?.ownerDocument ?? document, r = URL.createObjectURL(new Blob([t], { type: "text/csv;charset=utf-8" })), i = n.createElement("a");
3335
+ let t = Es(e), n = k.current?.ownerDocument ?? document, r = URL.createObjectURL(new Blob([t], { type: "text/csv;charset=utf-8" })), i = n.createElement("a");
3342
3336
  i.href = r, i.download = e.filename ?? "export.csv", i.click(), URL.revokeObjectURL(r);
3343
3337
  },
3344
- selectAll: () => ma(J, "programmatic", void 0),
3345
- clearSelection: () => ma([], "programmatic", void 0),
3338
+ selectAll: () => fa(J, "programmatic", void 0),
3339
+ clearSelection: () => fa([], "programmatic", void 0),
3346
3340
  get element() {
3347
3341
  return k.current;
3348
3342
  }
3349
3343
  }), [
3350
- Oa,
3351
- Es,
3352
- Ds,
3344
+ Ea,
3345
+ ws,
3346
+ Ts,
3347
+ Zo,
3353
3348
  $o,
3354
- ts,
3355
3349
  $,
3356
- ro,
3350
+ to,
3357
3351
  B,
3358
- $r,
3359
- Mi.rows,
3352
+ Zr,
3353
+ Ai.rows,
3360
3354
  L,
3361
- Os,
3362
- Kr.reload,
3363
- ma,
3355
+ Es,
3356
+ Wr.reload,
3357
+ fa,
3364
3358
  J
3365
3359
  ]);
3366
- let ks = y((e) => {
3360
+ let Ds = y((e) => {
3367
3361
  k.current = e, typeof xt == "function" ? xt(e) : xt && (xt.current = e);
3368
- }, [xt]), As = x(() => X ? `${X.rowEnd - X.rowStart + 1} × ${X.columnEnd - X.columnStart + 1}` : null, [X]), js = S(null), Ms = Yr === "initial" || Yr === !0 && js.current !== "empty";
3369
- !Xr && !Zr && (js.current = L.length > 0 ? "rows" : "empty");
3370
- let Ns = Zr ? "error" : Ms && L.length === 0 ? "loading" : G.length > 0 ? "rows" : I.filter || I.search.trim() ? "no-results" : "empty", Ps = x(() => {
3362
+ }, [xt]), Os = x(() => X ? `${X.rowEnd - X.rowStart + 1} × ${X.columnEnd - X.columnStart + 1}` : null, [X]), ks = S(null), As = qr === "initial" || qr === !0 && ks.current !== "empty";
3363
+ !Jr && !Yr && (ks.current = L.length > 0 ? "rows" : "empty");
3364
+ let js = Yr ? "error" : As && L.length === 0 ? "loading" : G.length > 0 ? "rows" : I.filter || I.search.trim() ? "no-results" : "empty", Ms = x(() => {
3371
3365
  let e = I.page?.size;
3372
- return K.height === 0 ? Fr : Math.max(1, Math.min(e ?? Infinity, Math.ceil(K.height / q)));
3366
+ return K.height === 0 ? Nr : Math.max(1, Math.min(e ?? Infinity, Math.ceil(K.height / q)));
3373
3367
  }, [
3374
3368
  I.page?.size,
3375
3369
  K.height,
3376
3370
  q,
3377
- Fr
3378
- ]), Fs = x(() => z ?? {
3371
+ Nr
3372
+ ]), Ns = x(() => z ?? {
3379
3373
  row: ut,
3380
3374
  column: U[0] ?? ""
3381
- }, [z, U]), Is = x(() => ({
3382
- id: Nn,
3375
+ }, [z, U]), Ps = x(() => ({
3376
+ id: Mn,
3383
3377
  t: j,
3384
3378
  locale: N,
3385
- booleans: zr.booleans,
3386
- timeZone: Sn,
3379
+ booleans: Lr.booleans,
3380
+ timeZone: bn,
3387
3381
  columns: c,
3388
3382
  resolved: V,
3389
3383
  resolvedById: H,
3390
3384
  columnIds: U,
3391
- mountedColumns: oa,
3392
- columnsWindowed: aa,
3393
- popinColumns: wi,
3394
- popinAggregated: Pi,
3395
- popinIndex: Oi,
3396
- hasPopinCell: Ii,
3385
+ mountedColumns: ia,
3386
+ columnsWindowed: ra,
3387
+ popinColumns: Si,
3388
+ popinAggregated: Mi,
3389
+ popinIndex: Ei,
3390
+ hasPopinCell: Pi,
3397
3391
  query: I,
3398
3392
  nodes: G,
3399
- total: Ni,
3393
+ total: ji,
3400
3394
  selectionMode: M,
3401
- editMode: ir,
3402
- filterRow: ar,
3403
- activatable: Ir,
3395
+ editMode: rr,
3396
+ filterRow: ir,
3397
+ activatable: Pr,
3404
3398
  rowKeyOf: P,
3405
- textOf: Br,
3399
+ textOf: Rr,
3406
3400
  valueOf: gt,
3407
3401
  isEditable: F,
3408
- anyEditable: Ur,
3409
- isDisabled: Hr,
3410
- isExpandable: Wr,
3402
+ anyEditable: Vr,
3403
+ isDisabled: Br,
3404
+ isExpandable: Hr,
3411
3405
  current: z,
3412
- tabStop: Fs,
3413
- focused: wa,
3414
- setCurrent: Oa,
3415
- isSelected: ua,
3416
- selectedCount: fa,
3417
- toggleSelected: ha,
3418
- toggleAll: ga,
3419
- allState: pa,
3406
+ tabStop: Ns,
3407
+ focused: Sa,
3408
+ setCurrent: Ea,
3409
+ isSelected: ca,
3410
+ selectedCount: ua,
3411
+ toggleSelected: pa,
3412
+ toggleAll: ma,
3413
+ allState: da,
3420
3414
  selectableCount: J.length,
3421
3415
  rangeBounds: X,
3422
- rangeInfo: va,
3423
- changedOf: Ro,
3424
- beginRange: Sa,
3425
- extendRange: Ca,
3426
- rangeDragging: ya,
3427
- isExpanded: Bo,
3428
- toggleExpanded: Vo,
3429
- toggleBranch: qo,
3430
- treeColumn: Ho,
3431
- hasChildren: Ko,
3432
- rowsReorderable: yo,
3433
- attachRowDraggable: Oo,
3434
- rowLabelOf: To,
3435
- isLoadingChildren: Go,
3436
- toggleGroup: Yo,
3437
- sortOf: Aa,
3438
- pressSort: Na,
3439
- setSort: Pa,
3440
- filterOf: Fa,
3441
- setFilter: Ia,
3442
- filterOpen: La,
3443
- setFilterOpen: Ra,
3444
- menuOpen: za,
3445
- setMenuOpen: Ba,
3446
- menuAnchor: Va,
3447
- anchorToButton: Ga,
3448
- onHeaderContextMenu: Ka,
3449
- filterDebounce: ur,
3450
- countsFor: Ja,
3451
- pin: Xa,
3452
- hide: Za,
3453
- resizeBy: $a,
3454
- resizeTo: Qa,
3455
- autofit: ro,
3456
- moveColumn: io,
3457
- resizing: ao,
3458
- setResizing: oo,
3459
- resizeMode: Pr,
3460
- dragging: so.dragging,
3461
- dropTarget: so.target,
3462
- draggingRow: bo.dragging,
3463
- dropOffset: so.offset,
3464
- attachDraggable: go,
3416
+ rangeInfo: ga,
3417
+ changedOf: Io,
3418
+ beginRange: ba,
3419
+ extendRange: xa,
3420
+ rangeDragging: _a,
3421
+ isExpanded: Ro,
3422
+ toggleExpanded: zo,
3423
+ toggleBranch: Go,
3424
+ treeColumn: Bo,
3425
+ hasChildren: Wo,
3426
+ rowsReorderable: _o,
3427
+ attachRowDraggable: Eo,
3428
+ rowLabelOf: Co,
3429
+ isLoadingChildren: Uo,
3430
+ toggleGroup: qo,
3431
+ sortOf: Oa,
3432
+ pressSort: ja,
3433
+ setSort: Ma,
3434
+ filterOf: Na,
3435
+ setFilter: Pa,
3436
+ filterOpen: Fa,
3437
+ setFilterOpen: Ia,
3438
+ menuOpen: La,
3439
+ setMenuOpen: Ra,
3440
+ menuAnchor: za,
3441
+ anchorToButton: Ua,
3442
+ onHeaderContextMenu: Wa,
3443
+ filterDebounce: lr,
3444
+ countsFor: Ka,
3445
+ pin: Ja,
3446
+ hide: Ya,
3447
+ resizeBy: Za,
3448
+ resizeTo: Xa,
3449
+ autofit: to,
3450
+ moveColumn: no,
3451
+ resizing: ro,
3452
+ setResizing: io,
3453
+ dragging: ao.dragging,
3454
+ dropTarget: ao.target,
3455
+ draggingRow: vo.dragging,
3456
+ dropOffset: ao.offset,
3457
+ attachDraggable: mo,
3465
3458
  onManageColumns: He,
3466
- edit: Xo,
3467
- startEdit: $o,
3468
- setDraft: es,
3459
+ edit: Jo,
3460
+ startEdit: Zo,
3461
+ setDraft: Qo,
3469
3462
  commitEdit: $,
3470
- cancelEdit: ts,
3471
- activate: is,
3472
- renderCellContent: ws,
3473
- renderEditorContent: Ts,
3474
- renderHeaderContent: Gn,
3475
- renderDetail: zn,
3476
- renderGroup: Hn,
3477
- renderFilterOperand: Qt,
3478
- onCellPointerDown: _s,
3479
- onCellPointerEnter: vs,
3480
- onCellClick: ys,
3481
- onCellDoubleClick: bs,
3482
- onCellKeyDown: ms,
3483
- onCellFocus: xs,
3484
- onCellBlur: Ss,
3463
+ cancelEdit: $o,
3464
+ activate: ns,
3465
+ renderCellContent: Ss,
3466
+ renderEditorContent: Cs,
3467
+ renderHeaderContent: Hn,
3468
+ renderDetail: Rn,
3469
+ renderGroup: Vn,
3470
+ renderFilterOperand: Zt,
3471
+ onCellPointerDown: hs,
3472
+ onCellPointerEnter: gs,
3473
+ onCellClick: _s,
3474
+ onCellDoubleClick: vs,
3475
+ onCellKeyDown: fs,
3476
+ onCellFocus: ys,
3477
+ onCellBlur: bs,
3485
3478
  announce: Z,
3486
- detailId: (e) => `${Nn}detail-${e}`,
3487
- rangeSummary: As
3479
+ detailId: (e) => `${Mn}detail-${e}`,
3480
+ rangeSummary: Os
3488
3481
  }), [
3489
- Nn,
3482
+ Mn,
3490
3483
  j,
3491
3484
  N,
3492
- zr.booleans,
3493
- Sn,
3485
+ Lr.booleans,
3486
+ bn,
3494
3487
  c,
3495
3488
  V,
3496
3489
  H,
3497
3490
  U,
3498
- oa,
3499
- aa,
3500
- wi,
3491
+ ia,
3492
+ ra,
3493
+ Si,
3494
+ Mi,
3495
+ Ei,
3501
3496
  Pi,
3502
- Oi,
3503
- Ii,
3504
3497
  I,
3505
3498
  G,
3506
- Ni,
3499
+ ji,
3507
3500
  M,
3501
+ rr,
3508
3502
  ir,
3509
- ar,
3510
- Ir,
3503
+ Pr,
3511
3504
  P,
3512
- Br,
3505
+ Rr,
3513
3506
  F,
3514
- Ur,
3507
+ Vr,
3508
+ Br,
3515
3509
  Hr,
3516
- Wr,
3517
3510
  z,
3518
- Fs,
3519
- wa,
3520
- Oa,
3511
+ Ns,
3512
+ Sa,
3513
+ Ea,
3514
+ ca,
3521
3515
  ua,
3522
- fa,
3523
- ha,
3524
- ga,
3525
3516
  pa,
3517
+ ma,
3518
+ da,
3526
3519
  J.length,
3527
3520
  X,
3528
- va,
3521
+ ga,
3522
+ Io,
3523
+ ba,
3524
+ xa,
3525
+ _a,
3529
3526
  Ro,
3530
- Sa,
3531
- Ca,
3532
- ya,
3527
+ zo,
3528
+ Go,
3533
3529
  Bo,
3534
- Vo,
3530
+ Wo,
3531
+ _o,
3532
+ Eo,
3533
+ Co,
3534
+ Uo,
3535
3535
  qo,
3536
- Ho,
3537
- Ko,
3538
- yo,
3539
- Oo,
3540
- To,
3541
- Go,
3542
- Yo,
3543
- Aa,
3536
+ Oa,
3537
+ ja,
3538
+ Ma,
3544
3539
  Na,
3545
3540
  Pa,
3546
3541
  Fa,
3547
- Ia,
3548
3542
  La,
3549
3543
  za,
3550
- Va,
3551
- Ga,
3544
+ Ua,
3545
+ Wa,
3546
+ lr,
3552
3547
  Ka,
3553
- ur,
3554
3548
  Ja,
3555
- Xa,
3549
+ Ya,
3556
3550
  Za,
3557
- $a,
3558
- Qa,
3551
+ Xa,
3552
+ to,
3553
+ no,
3559
3554
  ro,
3560
- io,
3561
3555
  ao,
3562
- Pr,
3563
- so,
3564
- bo.dragging,
3565
- go,
3556
+ vo.dragging,
3557
+ mo,
3566
3558
  He,
3567
- Xo,
3568
- $o,
3569
- es,
3559
+ Jo,
3560
+ Zo,
3561
+ Qo,
3570
3562
  $,
3571
- ts,
3572
- is,
3573
- ws,
3574
- Ts,
3575
- Gn,
3576
- zn,
3563
+ $o,
3564
+ ns,
3565
+ Ss,
3566
+ Cs,
3577
3567
  Hn,
3578
- Qt,
3568
+ Rn,
3569
+ Vn,
3570
+ Zt,
3571
+ hs,
3572
+ gs,
3579
3573
  _s,
3580
3574
  vs,
3575
+ fs,
3581
3576
  ys,
3582
3577
  bs,
3583
- ms,
3584
- xs,
3585
- Ss,
3586
3578
  Z,
3587
- As
3588
- ]), [Ls] = C(() => xn(Is));
3589
- Ls.set(Is), Be(() => Ls.publish(), [Is, Ls]);
3590
- let Rs = {
3591
- ...bn,
3592
- "--slotted-data-grid-template": Ai,
3579
+ Os
3580
+ ]), [Fs] = C(() => xn(Ps));
3581
+ Fs.set(Ps), Be(() => Fs.publish(), [Ps, Fs]);
3582
+ let Is = {
3583
+ ...yn,
3584
+ "--slotted-data-grid-template": Oi,
3593
3585
  ..._e === void 0 ? {} : { "--slotted-data-grid-block-size": typeof _e == "number" ? `${_e}px` : _e },
3594
- ...typeof sr == "number" ? { "--slotted-data-grid-row-block-size": `${sr}px` } : {},
3595
- ...jo > 0 ? { "--slotted-data-grid-changed-duration": `${jo}ms` } : {},
3596
- ...Ti ? { "--slotted-data-grid-leading": `${gi}px` } : {},
3586
+ ...typeof or == "number" ? { "--slotted-data-grid-row-block-size": `${or}px` } : {},
3587
+ ...ko > 0 ? { "--slotted-data-grid-changed-duration": `${ko}ms` } : {},
3588
+ ...Ci ? { "--slotted-data-grid-leading": `${mi}px` } : {},
3597
3589
  ...K.width > 0 ? { "--slotted-data-grid-viewport": `${K.width}px` } : {}
3598
- }, zs = Qi ? {
3599
- "--slotted-data-grid-window-total": `${ea.totalSize}px`,
3600
- "--slotted-data-grid-window-start": `${ea.startOffset}px`
3601
- } : void 0, Bs = (() => {
3602
- if (cn === !1 || !I.page || G.length === 0) return null;
3603
- let e = ("index" in I.page ? I.page.index * I.page.size : 0) + 1, t = e + ($r === "client" ? G.filter((e) => e.kind === "row").length : L.length) - 1;
3604
- return Ni === null || Ni < 0 ? j("rangeUnknown", {
3590
+ }, Ls = Xi ? {
3591
+ "--slotted-data-grid-window-total": `${Qi.totalSize}px`,
3592
+ "--slotted-data-grid-window-start": `${Qi.startOffset}px`
3593
+ } : void 0, Rs = (() => {
3594
+ if (sn === !1 || !I.page || G.length === 0) return null;
3595
+ let e = ("index" in I.page ? I.page.index * I.page.size : 0) + 1, t = e + (Zr === "client" ? G.filter((e) => e.kind === "row").length : L.length) - 1;
3596
+ return ji === null || ji < 0 ? j("rangeUnknown", {
3605
3597
  start: e,
3606
3598
  end: t
3607
3599
  }) : j("range", {
3608
3600
  start: e,
3609
3601
  end: t,
3610
- total: Ni
3602
+ total: ji
3611
3603
  });
3612
- })(), Vs = !Jr || !Ve ? null : Nr === "scroll" && Se !== !0 ? Xr ? /* @__PURE__ */ w("span", {
3604
+ })(), zs = !Kr || !Ve ? null : Ar === "scroll" && Se !== !0 ? Jr ? /* @__PURE__ */ w("span", {
3613
3605
  "data-loading-more": "",
3614
3606
  role: "status",
3615
3607
  children: j("loadingMore")
3616
3608
  }) : null : /* @__PURE__ */ w("div", { children: /* @__PURE__ */ w(l, {
3617
- disabled: Xr,
3609
+ disabled: Jr,
3618
3610
  onClick: () => Ve(),
3619
3611
  size: "sm",
3620
3612
  tone: "secondary",
3621
3613
  variant: "outline",
3622
3614
  children: j(Se === !0 ? "retry" : "loadMore")
3623
- }) }), Hs = (() => {
3624
- if (Ns === "rows" || Ns === "loading") return null;
3625
- let e = Ns;
3626
- if (Zt) return Zt(e);
3615
+ }) }), Bs = (() => {
3616
+ if (js === "rows" || js === "loading") return null;
3617
+ let e = js;
3618
+ if (Xt) return Xt(e);
3627
3619
  let t = j(e === "error" ? "error" : e === "no-results" ? "noResults" : "empty");
3628
3620
  return /* @__PURE__ */ T(le, {
3629
3621
  reach: "section",
3630
3622
  status: e,
3631
3623
  tabIndex: -1,
3632
- children: [/* @__PURE__ */ T(ce, { children: [/* @__PURE__ */ w(se, { children: t }), e === "error" && Zr ? /* @__PURE__ */ w(ae, { children: Zr }) : null] }), e === "no-results" || e === "error" && Qr ? /* @__PURE__ */ w(oe, { children: e === "no-results" ? /* @__PURE__ */ w(l, {
3624
+ children: [/* @__PURE__ */ T(ce, { children: [/* @__PURE__ */ w(se, { children: t }), e === "error" && Yr ? /* @__PURE__ */ w(ae, { children: Yr }) : null] }), e === "no-results" || e === "error" && Xr ? /* @__PURE__ */ w(oe, { children: e === "no-results" ? /* @__PURE__ */ w(l, {
3633
3625
  onClick: (e) => {
3634
3626
  let t = qt(I);
3635
- Gr(t.query, "clear", e, { change: t.change });
3627
+ Ur(t.query, "clear", e, { change: t.change });
3636
3628
  },
3637
3629
  size: "sm",
3638
3630
  tone: "secondary",
3639
3631
  variant: "outline",
3640
3632
  children: j("clearFilters")
3641
3633
  }) : /* @__PURE__ */ w(l, {
3642
- onClick: () => Qr?.(),
3634
+ onClick: () => Xr?.(),
3643
3635
  size: "sm",
3644
3636
  tone: "secondary",
3645
3637
  variant: "outline",
@@ -3648,108 +3640,108 @@ function Ar({ activatable: n, cellRenderers: r, columnGroups: i, columnOverflow:
3648
3640
  });
3649
3641
  })();
3650
3642
  return /* @__PURE__ */ w(vn.Provider, {
3651
- value: Ls.grid,
3643
+ value: Fs.grid,
3652
3644
  children: /* @__PURE__ */ w(Tn.Provider, {
3653
- value: Ls,
3645
+ value: Fs,
3654
3646
  children: /* @__PURE__ */ T("div", {
3655
- ...Mn,
3656
- "aria-busy": Xr && Ns !== "loading" ? !0 : void 0,
3657
- "aria-colcount": Di,
3658
- "aria-label": Mn["aria-label"] ?? (ye ? void 0 : j("grid")),
3647
+ ...jn,
3648
+ "aria-busy": Jr && js !== "loading" ? !0 : void 0,
3649
+ "aria-colcount": Ti,
3650
+ "aria-label": jn["aria-label"] ?? (ye ? void 0 : j("grid")),
3659
3651
  "aria-labelledby": ye,
3660
3652
  "aria-multiselectable": M === "multiple" || M === "range" || void 0,
3661
- "aria-rowcount": (Ni === null ? -1 : Ni) + W.top.length + W.bottom.length + Ri + +!!Fi,
3653
+ "aria-rowcount": (ji === null ? -1 : ji) + W.top.length + W.bottom.length + Ii + +!!Ni,
3662
3654
  "data-part": "root",
3663
3655
  "data-part-root": "",
3664
- "data-popin": Ti ? B.popin.length : void 0,
3656
+ "data-popin": Ci ? B.popin.length : void 0,
3665
3657
  "data-narrow": K.width > 0 && K.width < Ke ? "" : void 0,
3666
- "data-rows": Zi ? "auto" : "fixed",
3658
+ "data-rows": Yi ? "auto" : "fixed",
3667
3659
  "data-slotted-density": d ?? void 0,
3668
3660
  "data-ui": "data-grid",
3669
3661
  "data-ui-data-grid": "",
3670
- "data-variant": $n,
3671
- onBlur: Cs,
3662
+ "data-variant": Qn,
3663
+ onBlur: xs,
3672
3664
  onKeyDown: (e) => {
3673
- Le?.(e), !e.defaultPrevented && (lo.current?.handleKeydown(e.nativeEvent) || So.current?.handleKeydown(e.nativeEvent));
3665
+ Le?.(e), !e.defaultPrevented && (so.current?.handleKeydown(e.nativeEvent) || bo.current?.handleKeydown(e.nativeEvent));
3674
3666
  },
3675
- ref: ks,
3667
+ ref: Ds,
3676
3668
  role: A ? "treegrid" : "grid",
3677
- style: Rs,
3678
- ...er ? { "data-striped": "" } : {},
3679
- ...tr ? { "data-sticky-header": "" } : {},
3680
- ...ar ? { "data-filter-row": "" } : {},
3681
- ...nr === "page" ? { "data-sticky-to": "page" } : {},
3669
+ style: Is,
3670
+ ...$n ? { "data-striped": "" } : {},
3671
+ ...er ? { "data-sticky-header": "" } : {},
3672
+ ...ir ? { "data-filter-row": "" } : {},
3673
+ ...tr === "page" ? { "data-sticky-to": "page" } : {},
3682
3674
  ...M === "none" ? {} : { "data-selection": M },
3683
3675
  children: [/* @__PURE__ */ T("div", {
3684
3676
  "data-part": "scroll",
3685
3677
  "data-part-scroll": "",
3686
- ref: Pn,
3678
+ ref: Nn,
3687
3679
  children: [
3688
- /* @__PURE__ */ w(rr, {
3680
+ /* @__PURE__ */ w(nr, {
3689
3681
  columnGroups: i,
3690
- headerRowCount: Ri
3682
+ headerRowCount: Ii
3691
3683
  }),
3692
3684
  W.top.length > 0 ? /* @__PURE__ */ w(On, {
3693
3685
  edge: "top",
3694
- firstRowIndex: Ri + 1,
3686
+ firstRowIndex: Ii + 1,
3695
3687
  nodes: W.top
3696
3688
  }) : null,
3697
- Ns === "loading" ? /* @__PURE__ */ w(In, {
3689
+ js === "loading" ? /* @__PURE__ */ w(In, {
3698
3690
  rowSize: q,
3699
- rows: Ps
3691
+ rows: Ms
3700
3692
  }) : /* @__PURE__ */ w(Dn, {
3701
- bodyStyle: zs,
3702
- firstIndex: Qi ? ea.startIndex : 0,
3703
- headerRowCount: Ri + W.top.length,
3704
- measureRow: Zi || qi === null ? os : void 0,
3705
- loadMore: ss ? {
3706
- top: ls,
3707
- ref: us
3693
+ bodyStyle: Ls,
3694
+ firstIndex: Xi ? Qi.startIndex : 0,
3695
+ headerRowCount: Ii + W.top.length,
3696
+ measureRow: Yi || Gi === null ? is : void 0,
3697
+ loadMore: as ? {
3698
+ top: ss,
3699
+ ref: cs
3708
3700
  } : void 0,
3709
- nodes: ta,
3710
- heldRows: na,
3701
+ nodes: $i,
3702
+ heldRows: ea,
3711
3703
  allNodes: G
3712
3704
  }),
3713
- Hs !== null && Ns !== "loading" ? /* @__PURE__ */ w(kn, { children: Hs }) : null,
3705
+ Bs !== null && js !== "loading" ? /* @__PURE__ */ w(kn, { children: Bs }) : null,
3714
3706
  W.bottom.length > 0 ? /* @__PURE__ */ w(On, {
3715
3707
  edge: "bottom",
3716
- firstRowIndex: Ri + W.top.length + (Ni ?? G.length) + 1,
3708
+ firstRowIndex: Ii + W.top.length + (ji ?? G.length) + 1,
3717
3709
  nodes: W.bottom
3718
3710
  }) : null,
3719
- Fi && Ns === "rows" ? /* @__PURE__ */ w(Ln, {
3720
- aggregates: Mi.aggregates,
3721
- rowIndex: Ri + W.top.length + (Ni ?? G.length) + W.bottom.length + 1
3711
+ Ni && js === "rows" ? /* @__PURE__ */ w(Ln, {
3712
+ aggregates: Ai.aggregates,
3713
+ rowIndex: Ii + W.top.length + (ji ?? G.length) + W.bottom.length + 1
3722
3714
  }) : null,
3723
- so.offset === null ? null : /* @__PURE__ */ w("div", {
3715
+ ao.offset === null ? null : /* @__PURE__ */ w("div", {
3724
3716
  "aria-hidden": !0,
3725
3717
  "data-part": "drop-indicator",
3726
3718
  "data-part-drop-indicator": "",
3727
3719
  style: {
3728
- "--slotted-data-grid-drop-offset": `${so.offset}px`,
3729
- "--slotted-data-grid-drop-scroll": `${so.scrollTop}px`
3720
+ "--slotted-data-grid-drop-offset": `${ao.offset}px`,
3721
+ "--slotted-data-grid-drop-scroll": `${ao.scrollTop}px`
3730
3722
  }
3731
3723
  }),
3732
- bo.offset === null ? null : /* @__PURE__ */ w("div", {
3724
+ vo.offset === null ? null : /* @__PURE__ */ w("div", {
3733
3725
  "aria-hidden": !0,
3734
3726
  "data-axis": "row",
3735
3727
  "data-part": "drop-indicator",
3736
3728
  "data-part-drop-indicator": "",
3737
3729
  style: {
3738
- "--slotted-data-grid-drop-offset": `${bo.offset}px`,
3739
- "--slotted-data-grid-drop-scroll": `${bo.scrollLeft}px`
3730
+ "--slotted-data-grid-drop-offset": `${vo.offset}px`,
3731
+ "--slotted-data-grid-drop-scroll": `${vo.scrollLeft}px`
3740
3732
  }
3741
3733
  })
3742
3734
  ]
3743
- }), me !== void 0 || Bs !== null || Vs !== null ? /* @__PURE__ */ T("div", {
3735
+ }), me !== void 0 || Rs !== null || zs !== null ? /* @__PURE__ */ T("div", {
3744
3736
  "data-part": "footer",
3745
3737
  "data-part-footer": "",
3746
3738
  children: [
3747
- Bs === null ? null : /* @__PURE__ */ w("span", {
3739
+ Rs === null ? null : /* @__PURE__ */ w("span", {
3748
3740
  "data-range": "",
3749
- children: Bs
3741
+ children: Rs
3750
3742
  }),
3751
3743
  me,
3752
- me === void 0 ? Vs : null
3744
+ me === void 0 ? zs : null
3753
3745
  ]
3754
3746
  }) : null]
3755
3747
  })
@@ -3772,7 +3764,7 @@ function Nr() {
3772
3764
  return null;
3773
3765
  }
3774
3766
  }
3775
- function Pr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnState: i, defaultDensity: a, ...o }) {
3767
+ function N({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnState: i, defaultDensity: a, ...o }) {
3776
3768
  let s = x(() => n === void 0 ? Nr() : n, [n]), c = x(() => ({
3777
3769
  columns: Et(i ?? null, t),
3778
3770
  query: r ?? xt(o.defaultPageSize).query,
@@ -3853,4 +3845,4 @@ function Pr({ key: e, columns: t, storage: n, defaultQuery: r, defaultColumnStat
3853
3845
  };
3854
3846
  }
3855
3847
  //#endregion
3856
- export { fn as a, Bn as i, Ar as n, dn as o, zn as r, un as s, Pr as t };
3848
+ export { fn as a, Bn as i, Ar as n, dn as o, zn as r, un as s, N as t };