@turtleclub/ui 0.7.0-beta.2 → 0.7.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.turbo/turbo-build.log +50 -50
- package/CHANGELOG.md +4 -0
- package/dist/index.cjs +10 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +151 -139
- package/dist/index.js.map +1 -1
- package/dist/types/components/features/data-table/data-table.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/components/features/data-table/data-table.tsx +11 -1
package/dist/index.js
CHANGED
|
@@ -321,7 +321,7 @@ function $P(e) {
|
|
|
321
321
|
}
|
|
322
322
|
const FP = (e) => {
|
|
323
323
|
var t, n, r, o, i, a, s, l, c;
|
|
324
|
-
const { invert: d, toast: f, unstyled: p, interacting: m, setHeights: v, visibleToasts: g, heights: y, index: b, toasts: w, expanded: x, removeToast: C, defaultRichColors: S, closeButton: T, style: P, cancelButtonStyle: E, actionButtonStyle: A, className: O = "", descriptionClassName: I = "", duration: Y, position: j, gap: F, expandByDefault:
|
|
324
|
+
const { invert: d, toast: f, unstyled: p, interacting: m, setHeights: v, visibleToasts: g, heights: y, index: b, toasts: w, expanded: x, removeToast: C, defaultRichColors: S, closeButton: T, style: P, cancelButtonStyle: E, actionButtonStyle: A, className: O = "", descriptionClassName: I = "", duration: Y, position: j, gap: F, expandByDefault: W, classNames: D, icons: z, closeButtonAriaLabel: N = "Close toast" } = e, [V, ne] = M.useState(null), [ue, k] = M.useState(null), [L, q] = M.useState(!1), [H, ee] = M.useState(!1), [$, Z] = M.useState(!1), [J, se] = M.useState(!1), [G, K] = M.useState(!1), [ge, te] = M.useState(0), [je, X] = M.useState(0), de = M.useRef(f.duration || Y || Yh), Te = M.useRef(null), ze = M.useRef(null), Ss = b === 0, ir = b + 1 <= g, De = f.type, tn = f.dismissible !== !1, _s = f.className || "", Rs = f.descriptionClassName || "", Xr = M.useMemo(() => y.findIndex((pe) => pe.toastId === f.id) || 0, [
|
|
325
325
|
y,
|
|
326
326
|
f.id
|
|
327
327
|
]), Zr = M.useMemo(() => {
|
|
@@ -450,7 +450,7 @@ const FP = (e) => {
|
|
|
450
450
|
"data-styled": !(f.jsx || f.unstyled || p),
|
|
451
451
|
"data-mounted": L,
|
|
452
452
|
"data-promise": !!f.promise,
|
|
453
|
-
"data-swiped":
|
|
453
|
+
"data-swiped": G,
|
|
454
454
|
"data-removed": H,
|
|
455
455
|
"data-visible": ir,
|
|
456
456
|
"data-y-position": An,
|
|
@@ -463,14 +463,14 @@ const FP = (e) => {
|
|
|
463
463
|
"data-invert": tP,
|
|
464
464
|
"data-swipe-out": J,
|
|
465
465
|
"data-swipe-direction": ue,
|
|
466
|
-
"data-expanded": !!(x ||
|
|
466
|
+
"data-expanded": !!(x || W && L),
|
|
467
467
|
"data-testid": f.testId,
|
|
468
468
|
style: {
|
|
469
469
|
"--index": b,
|
|
470
470
|
"--toasts-before": b,
|
|
471
471
|
"--z-index": w.length - b,
|
|
472
472
|
"--offset": `${H ? ge : me.current}px`,
|
|
473
|
-
"--initial-height":
|
|
473
|
+
"--initial-height": W ? "auto" : `${je}px`,
|
|
474
474
|
...P,
|
|
475
475
|
...f.style
|
|
476
476
|
},
|
|
@@ -609,7 +609,7 @@ const BP = /* @__PURE__ */ M.forwardRef(function(t, n) {
|
|
|
609
609
|
].concat(E.filter((L) => L.position).map((L) => L.position)))), [
|
|
610
610
|
E,
|
|
611
611
|
i
|
|
612
|
-
]), [O, I] = M.useState([]), [Y, j] = M.useState(!1), [F,
|
|
612
|
+
]), [O, I] = M.useState([]), [Y, j] = M.useState(!1), [F, W] = M.useState(!1), [D, z] = M.useState(p !== "system" ? p : typeof window < "u" && window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light"), N = M.useRef(null), V = a.join("+").replace(/Key/g, "").replace(/Digit/g, ""), ne = M.useRef(null), ue = M.useRef(!1), k = M.useCallback((L) => {
|
|
613
613
|
P((q) => {
|
|
614
614
|
var H;
|
|
615
615
|
return (H = q.find((ee) => ee.id === L.id)) != null && H.delete || Ye.dismiss(L.id), q.filter(({ id: ee }) => ee !== L.id);
|
|
@@ -736,11 +736,11 @@ const BP = /* @__PURE__ */ M.forwardRef(function(t, n) {
|
|
|
736
736
|
},
|
|
737
737
|
onDragEnd: () => j(!1),
|
|
738
738
|
onPointerDown: (Z) => {
|
|
739
|
-
Z.target instanceof HTMLElement && Z.target.dataset.dismissible === "false" ||
|
|
739
|
+
Z.target instanceof HTMLElement && Z.target.dataset.dismissible === "false" || W(!0);
|
|
740
740
|
},
|
|
741
|
-
onPointerUp: () =>
|
|
741
|
+
onPointerUp: () => W(!1)
|
|
742
742
|
}, E.filter((Z) => !Z.position && q === 0 || Z.position === L).map((Z, J) => {
|
|
743
|
-
var se,
|
|
743
|
+
var se, G;
|
|
744
744
|
return /* @__PURE__ */ M.createElement(FP, {
|
|
745
745
|
key: Z.id,
|
|
746
746
|
icons: C,
|
|
@@ -752,7 +752,7 @@ const BP = /* @__PURE__ */ M.forwardRef(function(t, n) {
|
|
|
752
752
|
descriptionClassName: b?.descriptionClassName,
|
|
753
753
|
invert: o,
|
|
754
754
|
visibleToasts: y,
|
|
755
|
-
closeButton: (
|
|
755
|
+
closeButton: (G = b?.closeButton) != null ? G : l,
|
|
756
756
|
interacting: F,
|
|
757
757
|
position: L,
|
|
758
758
|
style: b?.style,
|
|
@@ -1466,7 +1466,7 @@ const rE = (e, t) => {
|
|
|
1466
1466
|
"left-bottom"
|
|
1467
1467
|
], S = () => [...C(), oe, re], T = () => ["auto", "hidden", "clip", "visible", "scroll"], P = () => ["auto", "contain", "none"], E = () => [oe, re, l], A = () => [ar, "full", "auto", ...E()], O = () => [rn, "none", "subgrid", oe, re], I = () => ["auto", {
|
|
1468
1468
|
span: ["full", rn, oe, re]
|
|
1469
|
-
}, rn, oe, re], Y = () => [rn, "auto", oe, re], j = () => ["auto", "min", "max", "fr", oe, re], F = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"],
|
|
1469
|
+
}, rn, oe, re], Y = () => [rn, "auto", oe, re], j = () => ["auto", "min", "max", "fr", oe, re], F = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], W = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], D = () => ["auto", ...E()], z = () => [ar, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...E()], N = () => [e, oe, re], V = () => [...C(), nm, tm, {
|
|
1470
1470
|
position: [oe, re]
|
|
1471
1471
|
}], ne = () => ["no-repeat", {
|
|
1472
1472
|
repeat: ["", "x", "y", "space", "round"]
|
|
@@ -1487,7 +1487,7 @@ const rE = (e, t) => {
|
|
|
1487
1487
|
v,
|
|
1488
1488
|
oe,
|
|
1489
1489
|
re
|
|
1490
|
-
], J = () => ["none", he, oe, re], se = () => ["none", he, oe, re],
|
|
1490
|
+
], J = () => ["none", he, oe, re], se = () => ["none", he, oe, re], G = () => [he, oe, re], K = () => [ar, "full", ...E()];
|
|
1491
1491
|
return {
|
|
1492
1492
|
cacheSize: 500,
|
|
1493
1493
|
theme: {
|
|
@@ -1897,14 +1897,14 @@ const rE = (e, t) => {
|
|
|
1897
1897
|
* @see https://tailwindcss.com/docs/justify-items
|
|
1898
1898
|
*/
|
|
1899
1899
|
"justify-items": [{
|
|
1900
|
-
"justify-items": [...
|
|
1900
|
+
"justify-items": [...W(), "normal"]
|
|
1901
1901
|
}],
|
|
1902
1902
|
/**
|
|
1903
1903
|
* Justify Self
|
|
1904
1904
|
* @see https://tailwindcss.com/docs/justify-self
|
|
1905
1905
|
*/
|
|
1906
1906
|
"justify-self": [{
|
|
1907
|
-
"justify-self": ["auto", ...
|
|
1907
|
+
"justify-self": ["auto", ...W()]
|
|
1908
1908
|
}],
|
|
1909
1909
|
/**
|
|
1910
1910
|
* Align Content
|
|
@@ -1918,7 +1918,7 @@ const rE = (e, t) => {
|
|
|
1918
1918
|
* @see https://tailwindcss.com/docs/align-items
|
|
1919
1919
|
*/
|
|
1920
1920
|
"align-items": [{
|
|
1921
|
-
items: [...
|
|
1921
|
+
items: [...W(), {
|
|
1922
1922
|
baseline: ["", "last"]
|
|
1923
1923
|
}]
|
|
1924
1924
|
}],
|
|
@@ -1927,7 +1927,7 @@ const rE = (e, t) => {
|
|
|
1927
1927
|
* @see https://tailwindcss.com/docs/align-self
|
|
1928
1928
|
*/
|
|
1929
1929
|
"align-self": [{
|
|
1930
|
-
self: ["auto", ...
|
|
1930
|
+
self: ["auto", ...W(), {
|
|
1931
1931
|
baseline: ["", "last"]
|
|
1932
1932
|
}]
|
|
1933
1933
|
}],
|
|
@@ -1943,14 +1943,14 @@ const rE = (e, t) => {
|
|
|
1943
1943
|
* @see https://tailwindcss.com/docs/place-items
|
|
1944
1944
|
*/
|
|
1945
1945
|
"place-items": [{
|
|
1946
|
-
"place-items": [...
|
|
1946
|
+
"place-items": [...W(), "baseline"]
|
|
1947
1947
|
}],
|
|
1948
1948
|
/**
|
|
1949
1949
|
* Place Self
|
|
1950
1950
|
* @see https://tailwindcss.com/docs/place-self
|
|
1951
1951
|
*/
|
|
1952
1952
|
"place-self": [{
|
|
1953
|
-
"place-self": ["auto", ...
|
|
1953
|
+
"place-self": ["auto", ...W()]
|
|
1954
1954
|
}],
|
|
1955
1955
|
// Spacing
|
|
1956
1956
|
/**
|
|
@@ -3495,21 +3495,21 @@ const rE = (e, t) => {
|
|
|
3495
3495
|
* @see https://tailwindcss.com/docs/skew
|
|
3496
3496
|
*/
|
|
3497
3497
|
skew: [{
|
|
3498
|
-
skew:
|
|
3498
|
+
skew: G()
|
|
3499
3499
|
}],
|
|
3500
3500
|
/**
|
|
3501
3501
|
* Skew X
|
|
3502
3502
|
* @see https://tailwindcss.com/docs/skew
|
|
3503
3503
|
*/
|
|
3504
3504
|
"skew-x": [{
|
|
3505
|
-
"skew-x":
|
|
3505
|
+
"skew-x": G()
|
|
3506
3506
|
}],
|
|
3507
3507
|
/**
|
|
3508
3508
|
* Skew Y
|
|
3509
3509
|
* @see https://tailwindcss.com/docs/skew
|
|
3510
3510
|
*/
|
|
3511
3511
|
"skew-y": [{
|
|
3512
|
-
"skew-y":
|
|
3512
|
+
"skew-y": G()
|
|
3513
3513
|
}],
|
|
3514
3514
|
/**
|
|
3515
3515
|
* Transform
|
|
@@ -4069,10 +4069,10 @@ var QE = h.forwardRef((e, t) => {
|
|
|
4069
4069
|
if (E.target === E.currentTarget && A && !b) {
|
|
4070
4070
|
const O = new CustomEvent(Ns, KE);
|
|
4071
4071
|
if (E.currentTarget.dispatchEvent(O), !O.defaultPrevented) {
|
|
4072
|
-
const I = C().filter((D) => D.focusable), Y = I.find((D) => D.active), j = I.find((D) => D.id === g),
|
|
4072
|
+
const I = C().filter((D) => D.focusable), Y = I.find((D) => D.active), j = I.find((D) => D.id === g), W = [Y, j, ...I].filter(
|
|
4073
4073
|
Boolean
|
|
4074
4074
|
).map((D) => D.ref.current);
|
|
4075
|
-
y1(
|
|
4075
|
+
y1(W, d);
|
|
4076
4076
|
}
|
|
4077
4077
|
}
|
|
4078
4078
|
S.current = !1;
|
|
@@ -5597,12 +5597,12 @@ const ET = (e) => ({
|
|
|
5597
5597
|
}, m = Yf(o), v = Kf(m), g = await a.getDimensions(c), y = m === "y", b = y ? "top" : "left", w = y ? "bottom" : "right", x = y ? "clientHeight" : "clientWidth", C = i.reference[v] + i.reference[m] - p[m] - i.floating[v], S = p[m] - i.reference[m], T = await (a.getOffsetParent == null ? void 0 : a.getOffsetParent(c));
|
|
5598
5598
|
let P = T ? T[x] : 0;
|
|
5599
5599
|
(!P || !await (a.isElement == null ? void 0 : a.isElement(T))) && (P = s.floating[x] || i.floating[v]);
|
|
5600
|
-
const E = C / 2 - S / 2, A = P / 2 - g[v] / 2 - 1, O = hn(f[b], A), I = hn(f[w], A), Y = O, j = P - g[v] - I, F = P / 2 - g[v] / 2 + E,
|
|
5600
|
+
const E = C / 2 - S / 2, A = P / 2 - g[v] / 2 - 1, O = hn(f[b], A), I = hn(f[w], A), Y = O, j = P - g[v] - I, F = P / 2 - g[v] / 2 + E, W = Pd(Y, F, j), D = !l.arrow && Br(o) != null && F !== W && i.reference[v] / 2 - (F < Y ? O : I) - g[v] / 2 < 0, z = D ? F < Y ? F - Y : F - j : 0;
|
|
5601
5601
|
return {
|
|
5602
5602
|
[m]: p[m] + z,
|
|
5603
5603
|
data: {
|
|
5604
|
-
[m]:
|
|
5605
|
-
centerOffset: F -
|
|
5604
|
+
[m]: W,
|
|
5605
|
+
centerOffset: F - W - z,
|
|
5606
5606
|
...D && {
|
|
5607
5607
|
alignmentOffset: z
|
|
5608
5608
|
}
|
|
@@ -5647,8 +5647,8 @@ const ET = (e) => ({
|
|
|
5647
5647
|
overflows: A
|
|
5648
5648
|
}], !A.every((F) => F <= 0)) {
|
|
5649
5649
|
var I, Y;
|
|
5650
|
-
const F = (((I = i.flip) == null ? void 0 : I.index) || 0) + 1,
|
|
5651
|
-
if (
|
|
5650
|
+
const F = (((I = i.flip) == null ? void 0 : I.index) || 0) + 1, W = P[F];
|
|
5651
|
+
if (W && (!(f === "alignment" ? w !== Dt(W) : !1) || // We leave the current main axis only if every placement on that axis
|
|
5652
5652
|
// overflows the main axis.
|
|
5653
5653
|
O.every((N) => Dt(N.placement) === w ? N.overflows[0] > 0 : !0)))
|
|
5654
5654
|
return {
|
|
@@ -5657,7 +5657,7 @@ const ET = (e) => ({
|
|
|
5657
5657
|
overflows: O
|
|
5658
5658
|
},
|
|
5659
5659
|
reset: {
|
|
5660
|
-
placement:
|
|
5660
|
+
placement: W
|
|
5661
5661
|
}
|
|
5662
5662
|
};
|
|
5663
5663
|
let D = (Y = O.filter((z) => z.overflows[0] <= 0).sort((z, N) => z.overflows[1] - N.overflows[1])[0]) == null ? void 0 : Y.placement;
|
|
@@ -6543,7 +6543,7 @@ function gA(e) {
|
|
|
6543
6543
|
j();
|
|
6544
6544
|
}
|
|
6545
6545
|
}, [C, S, j, O, A]);
|
|
6546
|
-
const
|
|
6546
|
+
const W = h.useMemo(() => ({
|
|
6547
6547
|
reference: T,
|
|
6548
6548
|
floating: P,
|
|
6549
6549
|
setReference: w,
|
|
@@ -6575,10 +6575,10 @@ function gA(e) {
|
|
|
6575
6575
|
return h.useMemo(() => ({
|
|
6576
6576
|
...d,
|
|
6577
6577
|
update: j,
|
|
6578
|
-
refs:
|
|
6578
|
+
refs: W,
|
|
6579
6579
|
elements: D,
|
|
6580
6580
|
floatingStyles: z
|
|
6581
|
-
}), [d, j,
|
|
6581
|
+
}), [d, j, W, D, z]);
|
|
6582
6582
|
}
|
|
6583
6583
|
const vA = (e) => {
|
|
6584
6584
|
function t(n) {
|
|
@@ -6676,7 +6676,7 @@ var ep = "PopperContent", [TA, AA] = tw(ep), aw = h.forwardRef(
|
|
|
6676
6676
|
boundary: I.filter(MA),
|
|
6677
6677
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
6678
6678
|
altBoundary: Y
|
|
6679
|
-
}, { refs: F, floatingStyles:
|
|
6679
|
+
}, { refs: F, floatingStyles: W, placement: D, isPositioned: z, middlewareData: N } = gA({
|
|
6680
6680
|
// default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
|
|
6681
6681
|
strategy: "fixed",
|
|
6682
6682
|
placement: A,
|
|
@@ -6698,8 +6698,8 @@ var ep = "PopperContent", [TA, AA] = tw(ep), aw = h.forwardRef(
|
|
|
6698
6698
|
CA({
|
|
6699
6699
|
...j,
|
|
6700
6700
|
apply: ({ elements: $, rects: Z, availableWidth: J, availableHeight: se }) => {
|
|
6701
|
-
const { width:
|
|
6702
|
-
ge.setProperty("--radix-popper-available-width", `${J}px`), ge.setProperty("--radix-popper-available-height", `${se}px`), ge.setProperty("--radix-popper-anchor-width", `${
|
|
6701
|
+
const { width: G, height: K } = Z.reference, ge = $.floating.style;
|
|
6702
|
+
ge.setProperty("--radix-popper-available-width", `${J}px`), ge.setProperty("--radix-popper-available-height", `${se}px`), ge.setProperty("--radix-popper-anchor-width", `${G}px`), ge.setProperty("--radix-popper-anchor-height", `${K}px`);
|
|
6703
6703
|
}
|
|
6704
6704
|
}),
|
|
6705
6705
|
C && _A({ element: C, padding: s }),
|
|
@@ -6719,8 +6719,8 @@ var ep = "PopperContent", [TA, AA] = tw(ep), aw = h.forwardRef(
|
|
|
6719
6719
|
ref: F.setFloating,
|
|
6720
6720
|
"data-radix-popper-content-wrapper": "",
|
|
6721
6721
|
style: {
|
|
6722
|
-
...
|
|
6723
|
-
transform: z ?
|
|
6722
|
+
...W,
|
|
6723
|
+
transform: z ? W.transform : "translate(0, -200%)",
|
|
6724
6724
|
// keep off the page when measuring
|
|
6725
6725
|
minWidth: "max-content",
|
|
6726
6726
|
zIndex: H,
|
|
@@ -11162,10 +11162,10 @@ function JI(e) {
|
|
|
11162
11162
|
Zd(N) && Zd(V) ? ne = !Xx(N, V) : ne = N !== V, ne ? N != null ? F(z) : p.add(z) : N !== void 0 && p.has(z) ? F(z) : w.protectedKeys[z] = !0;
|
|
11163
11163
|
}
|
|
11164
11164
|
w.prevProp = x, w.prevResolvedValues = I, w.isActive && (m = { ...m, ...I }), r && e.blockInitialAnimation && (E = !1);
|
|
11165
|
-
const
|
|
11166
|
-
E && (!
|
|
11165
|
+
const W = T && P;
|
|
11166
|
+
E && (!W || A) && f.push(...O.map((z) => {
|
|
11167
11167
|
const N = { type: b };
|
|
11168
|
-
if (typeof z == "string" && r && !
|
|
11168
|
+
if (typeof z == "string" && r && !W && e.manuallyAnimateOnMount && e.parent) {
|
|
11169
11169
|
const { parent: V } = e, ne = wr(V, z);
|
|
11170
11170
|
if (V.enteringChildren && ne) {
|
|
11171
11171
|
const { delayChildren: ue } = ne.transition || {};
|
|
@@ -13629,7 +13629,7 @@ function rk() {
|
|
|
13629
13629
|
}
|
|
13630
13630
|
}
|
|
13631
13631
|
}
|
|
13632
|
-
var T = a, P = i, E = e, A = l, O = n, I = p, Y = f, j = t, F = o,
|
|
13632
|
+
var T = a, P = i, E = e, A = l, O = n, I = p, Y = f, j = t, F = o, W = r, D = c, z = d, N = !1, V = !1;
|
|
13633
13633
|
function ne(te) {
|
|
13634
13634
|
return N || (N = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")), !1;
|
|
13635
13635
|
}
|
|
@@ -13663,7 +13663,7 @@ function rk() {
|
|
|
13663
13663
|
function se(te) {
|
|
13664
13664
|
return S(te) === o;
|
|
13665
13665
|
}
|
|
13666
|
-
function
|
|
13666
|
+
function G(te) {
|
|
13667
13667
|
return S(te) === r;
|
|
13668
13668
|
}
|
|
13669
13669
|
function K(te) {
|
|
@@ -13672,7 +13672,7 @@ function rk() {
|
|
|
13672
13672
|
function ge(te) {
|
|
13673
13673
|
return S(te) === d;
|
|
13674
13674
|
}
|
|
13675
|
-
ye.ContextConsumer = T, ye.ContextProvider = P, ye.Element = E, ye.ForwardRef = A, ye.Fragment = O, ye.Lazy = I, ye.Memo = Y, ye.Portal = j, ye.Profiler = F, ye.StrictMode =
|
|
13675
|
+
ye.ContextConsumer = T, ye.ContextProvider = P, ye.Element = E, ye.ForwardRef = A, ye.Fragment = O, ye.Lazy = I, ye.Memo = Y, ye.Portal = j, ye.Profiler = F, ye.StrictMode = W, ye.Suspense = D, ye.SuspenseList = z, ye.isAsyncMode = ne, ye.isConcurrentMode = ue, ye.isContextConsumer = k, ye.isContextProvider = L, ye.isElement = q, ye.isForwardRef = H, ye.isFragment = ee, ye.isLazy = $, ye.isMemo = Z, ye.isPortal = J, ye.isProfiler = se, ye.isStrictMode = G, ye.isSuspense = K, ye.isSuspenseList = ge, ye.isValidElementType = C, ye.typeOf = S;
|
|
13676
13676
|
})()), ye;
|
|
13677
13677
|
}
|
|
13678
13678
|
var jv;
|
|
@@ -14927,9 +14927,9 @@ function wD() {
|
|
|
14927
14927
|
var F = A & a;
|
|
14928
14928
|
if (j || (j = i), T.size != P.size && !F)
|
|
14929
14929
|
return !1;
|
|
14930
|
-
var
|
|
14931
|
-
if (
|
|
14932
|
-
return
|
|
14930
|
+
var W = Y.get(T);
|
|
14931
|
+
if (W)
|
|
14932
|
+
return W == P;
|
|
14933
14933
|
A |= s, Y.set(T, P);
|
|
14934
14934
|
var D = r(j(T), j(P), A, O, I, Y);
|
|
14935
14935
|
return Y.delete(T), D;
|
|
@@ -15309,8 +15309,8 @@ function jD() {
|
|
|
15309
15309
|
if (!(b & l)) {
|
|
15310
15310
|
var Y = A && m.call(g, "__wrapped__"), j = O && m.call(y, "__wrapped__");
|
|
15311
15311
|
if (Y || j) {
|
|
15312
|
-
var F = Y ? g.value() : g,
|
|
15313
|
-
return C || (C = new e()), x(F,
|
|
15312
|
+
var F = Y ? g.value() : g, W = j ? y.value() : y;
|
|
15313
|
+
return C || (C = new e()), x(F, W, b, w, C);
|
|
15314
15314
|
}
|
|
15315
15315
|
}
|
|
15316
15316
|
return I ? (C || (C = new e()), r(g, y, b, w, x, C)) : !1;
|
|
@@ -16291,7 +16291,7 @@ var e6 = function(t) {
|
|
|
16291
16291
|
var Y = {
|
|
16292
16292
|
padding: 0,
|
|
16293
16293
|
margin: 0
|
|
16294
|
-
}, j = (p ? q9(d, p) : d).map(function(F,
|
|
16294
|
+
}, j = (p ? q9(d, p) : d).map(function(F, W) {
|
|
16295
16295
|
if (F.type === "none")
|
|
16296
16296
|
return null;
|
|
16297
16297
|
var D = Ku({
|
|
@@ -16301,7 +16301,7 @@ var e6 = function(t) {
|
|
|
16301
16301
|
color: F.color || "#000"
|
|
16302
16302
|
}, s), z = F.formatter || f || Q9, N = F.value, V = F.name, ne = N, ue = V;
|
|
16303
16303
|
if (z && ne != null && ue != null) {
|
|
16304
|
-
var k = z(N, V, F,
|
|
16304
|
+
var k = z(N, V, F, W, d);
|
|
16305
16305
|
if (Array.isArray(k)) {
|
|
16306
16306
|
var L = U9(k, 2);
|
|
16307
16307
|
ne = L[0], ue = L[1];
|
|
@@ -16312,7 +16312,7 @@ var e6 = function(t) {
|
|
|
16312
16312
|
// eslint-disable-next-line react/no-array-index-key
|
|
16313
16313
|
/* @__PURE__ */ M.createElement("li", {
|
|
16314
16314
|
className: "recharts-tooltip-item",
|
|
16315
|
-
key: "tooltip-item-".concat(
|
|
16315
|
+
key: "tooltip-item-".concat(W),
|
|
16316
16316
|
style: D
|
|
16317
16317
|
}, ra(ue) ? /* @__PURE__ */ M.createElement("span", {
|
|
16318
16318
|
className: "recharts-tooltip-item-name"
|
|
@@ -16879,19 +16879,19 @@ function I6() {
|
|
|
16879
16879
|
throw new TypeError(r);
|
|
16880
16880
|
l = n(l) || 0, e(c) && (b = !!c.leading, w = "maxWait" in c, p = w ? o(n(c.maxWait) || 0, l) : p, x = "trailing" in c ? !!c.trailing : x);
|
|
16881
16881
|
function C(j) {
|
|
16882
|
-
var F = d,
|
|
16883
|
-
return d = f = void 0, y = j, m = s.apply(
|
|
16882
|
+
var F = d, W = f;
|
|
16883
|
+
return d = f = void 0, y = j, m = s.apply(W, F), m;
|
|
16884
16884
|
}
|
|
16885
16885
|
function S(j) {
|
|
16886
16886
|
return y = j, v = setTimeout(E, l), b ? C(j) : m;
|
|
16887
16887
|
}
|
|
16888
16888
|
function T(j) {
|
|
16889
|
-
var F = j - g,
|
|
16890
|
-
return w ? i(D, p -
|
|
16889
|
+
var F = j - g, W = j - y, D = l - F;
|
|
16890
|
+
return w ? i(D, p - W) : D;
|
|
16891
16891
|
}
|
|
16892
16892
|
function P(j) {
|
|
16893
|
-
var F = j - g,
|
|
16894
|
-
return g === void 0 || F >= l || F < 0 || w &&
|
|
16893
|
+
var F = j - g, W = j - y;
|
|
16894
|
+
return g === void 0 || F >= l || F < 0 || w && W >= p;
|
|
16895
16895
|
}
|
|
16896
16896
|
function E() {
|
|
16897
16897
|
var j = t();
|
|
@@ -17045,9 +17045,9 @@ var q6 = /* @__PURE__ */ xa(function(e, t) {
|
|
|
17045
17045
|
containerWidth: o.width,
|
|
17046
17046
|
containerHeight: o.height
|
|
17047
17047
|
}), E = V6(P, 2), A = E[0], O = E[1], I = Ct(function(j, F) {
|
|
17048
|
-
O(function(
|
|
17048
|
+
O(function(W) {
|
|
17049
17049
|
var D = Math.round(j), z = Math.round(F);
|
|
17050
|
-
return
|
|
17050
|
+
return W.containerWidth === D && W.containerHeight === z ? W : {
|
|
17051
17051
|
containerWidth: D,
|
|
17052
17052
|
containerHeight: z
|
|
17053
17053
|
};
|
|
@@ -17062,7 +17062,7 @@ var q6 = /* @__PURE__ */ xa(function(e, t) {
|
|
|
17062
17062
|
trailing: !0,
|
|
17063
17063
|
leading: !1
|
|
17064
17064
|
}));
|
|
17065
|
-
var F = new ResizeObserver(j),
|
|
17065
|
+
var F = new ResizeObserver(j), W = S.current.getBoundingClientRect(), D = W.width, z = W.height;
|
|
17066
17066
|
return I(D, z), F.observe(S.current), function() {
|
|
17067
17067
|
F.disconnect();
|
|
17068
17068
|
};
|
|
@@ -17073,22 +17073,22 @@ var q6 = /* @__PURE__ */ xa(function(e, t) {
|
|
|
17073
17073
|
return null;
|
|
17074
17074
|
Di(mi(a) || mi(l), `The width(%s) and height(%s) are both fixed numbers,
|
|
17075
17075
|
maybe you don't need to use a ResponsiveContainer.`, a, l), Di(!n || n > 0, "The aspect(%s) must be greater than zero.", n);
|
|
17076
|
-
var
|
|
17077
|
-
n && n > 0 && (
|
|
17076
|
+
var W = mi(a) ? j : a, D = mi(l) ? F : l;
|
|
17077
|
+
n && n > 0 && (W ? D = W / n : D && (W = D * n), p && D > p && (D = p)), Di(W > 0 || D > 0, `The width(%s) and height(%s) of chart should be greater than 0,
|
|
17078
17078
|
please check the style of container, or the props width(%s) and height(%s),
|
|
17079
17079
|
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
17080
|
-
height and width.`,
|
|
17080
|
+
height and width.`, W, D, a, l, d, f, n);
|
|
17081
17081
|
var z = !Array.isArray(m) && hk(m.type).endsWith("Chart");
|
|
17082
17082
|
return M.Children.map(m, function(N) {
|
|
17083
17083
|
return /* @__PURE__ */ M.isValidElement(N) ? /* @__PURE__ */ cP(N, yi({
|
|
17084
|
-
width:
|
|
17084
|
+
width: W,
|
|
17085
17085
|
height: D
|
|
17086
17086
|
}, z ? {
|
|
17087
17087
|
style: yi({
|
|
17088
17088
|
height: "100%",
|
|
17089
17089
|
width: "100%",
|
|
17090
17090
|
maxHeight: D,
|
|
17091
|
-
maxWidth:
|
|
17091
|
+
maxWidth: W
|
|
17092
17092
|
}, N.props.style)
|
|
17093
17093
|
} : {})) : N;
|
|
17094
17094
|
});
|
|
@@ -18037,7 +18037,7 @@ var H8 = [" ", "Enter", "ArrowUp", "ArrowDown"], q8 = [" ", "Enter"], qn = "Sele
|
|
|
18037
18037
|
defaultProp: s,
|
|
18038
18038
|
onChange: l,
|
|
18039
18039
|
caller: qn
|
|
18040
|
-
}), I = h.useRef(null), Y = y ? v || !!y.closest("form") : !0, [j, F] = h.useState(/* @__PURE__ */ new Set()),
|
|
18040
|
+
}), I = h.useRef(null), Y = y ? v || !!y.closest("form") : !0, [j, F] = h.useState(/* @__PURE__ */ new Set()), W = Array.from(j).map((D) => D.props.value).join(";");
|
|
18041
18041
|
return /* @__PURE__ */ u(zr, { ...g, children: /* @__PURE__ */ _(
|
|
18042
18042
|
G8,
|
|
18043
18043
|
{
|
|
@@ -18091,7 +18091,7 @@ var H8 = [" ", "Enter", "ArrowUp", "ArrowDown"], q8 = [" ", "Enter"], qn = "Sele
|
|
|
18091
18091
|
Array.from(j)
|
|
18092
18092
|
]
|
|
18093
18093
|
},
|
|
18094
|
-
|
|
18094
|
+
W
|
|
18095
18095
|
) : null
|
|
18096
18096
|
]
|
|
18097
18097
|
}
|
|
@@ -18208,15 +18208,15 @@ var wt = 10, [bS, Pn] = Kr(Un), Z8 = "SelectContentImpl", J8 = /* @__PURE__ */ j
|
|
|
18208
18208
|
...b
|
|
18209
18209
|
} = e, w = Rn(Un, n), [x, C] = h.useState(null), [S, T] = h.useState(null), P = ae(t, ($) => C($)), [E, A] = h.useState(null), [O, I] = h.useState(
|
|
18210
18210
|
null
|
|
18211
|
-
), Y = ns(n), [j, F] = h.useState(!1),
|
|
18211
|
+
), Y = ns(n), [j, F] = h.useState(!1), W = h.useRef(!1);
|
|
18212
18212
|
h.useEffect(() => {
|
|
18213
18213
|
if (x) return Qa(x);
|
|
18214
18214
|
}, [x]), Ja();
|
|
18215
18215
|
const D = h.useCallback(
|
|
18216
18216
|
($) => {
|
|
18217
|
-
const [Z, ...J] = Y().map((K) => K.ref.current), [se] = J.slice(-1),
|
|
18217
|
+
const [Z, ...J] = Y().map((K) => K.ref.current), [se] = J.slice(-1), G = document.activeElement;
|
|
18218
18218
|
for (const K of $)
|
|
18219
|
-
if (K ===
|
|
18219
|
+
if (K === G || (K?.scrollIntoView({ block: "nearest" }), K === Z && S && (S.scrollTop = 0), K === se && S && (S.scrollTop = S.scrollHeight), K?.focus(), document.activeElement !== G)) return;
|
|
18220
18220
|
},
|
|
18221
18221
|
[Y, S]
|
|
18222
18222
|
), z = h.useCallback(
|
|
@@ -18249,17 +18249,17 @@ var wt = 10, [bS, Pn] = Kr(Un), Z8 = "SelectContentImpl", J8 = /* @__PURE__ */ j
|
|
|
18249
18249
|
};
|
|
18250
18250
|
}, [N]);
|
|
18251
18251
|
const [ne, ue] = FS(($) => {
|
|
18252
|
-
const Z = Y().filter((
|
|
18252
|
+
const Z = Y().filter((G) => !G.disabled), J = Z.find((G) => G.ref.current === document.activeElement), se = VS(Z, $, J);
|
|
18253
18253
|
se && setTimeout(() => se.ref.current.focus());
|
|
18254
18254
|
}), k = h.useCallback(
|
|
18255
18255
|
($, Z, J) => {
|
|
18256
|
-
const se = !
|
|
18257
|
-
(w.value !== void 0 && w.value === Z || se) && (A($), se && (
|
|
18256
|
+
const se = !W.current && !J;
|
|
18257
|
+
(w.value !== void 0 && w.value === Z || se) && (A($), se && (W.current = !0));
|
|
18258
18258
|
},
|
|
18259
18259
|
[w.value]
|
|
18260
18260
|
), L = h.useCallback(() => x?.focus(), [x]), q = h.useCallback(
|
|
18261
18261
|
($, Z, J) => {
|
|
18262
|
-
const se = !
|
|
18262
|
+
const se = !W.current && !J;
|
|
18263
18263
|
(w.value !== void 0 && w.value === Z || se) && I($);
|
|
18264
18264
|
},
|
|
18265
18265
|
[w.value]
|
|
@@ -18334,9 +18334,9 @@ var wt = 10, [bS, Pn] = Kr(Un), Z8 = "SelectContentImpl", J8 = /* @__PURE__ */ j
|
|
|
18334
18334
|
onKeyDown: B(b.onKeyDown, ($) => {
|
|
18335
18335
|
const Z = $.ctrlKey || $.altKey || $.metaKey;
|
|
18336
18336
|
if ($.key === "Tab" && $.preventDefault(), !Z && $.key.length === 1 && ue($.key), ["ArrowUp", "ArrowDown", "Home", "End"].includes($.key)) {
|
|
18337
|
-
let se = Y().filter((
|
|
18337
|
+
let se = Y().filter((G) => !G.disabled).map((G) => G.ref.current);
|
|
18338
18338
|
if (["ArrowUp", "End"].includes($.key) && (se = se.slice().reverse()), ["ArrowUp", "ArrowDown"].includes($.key)) {
|
|
18339
|
-
const
|
|
18339
|
+
const G = $.target, K = se.indexOf(G);
|
|
18340
18340
|
se = se.slice(K + 1);
|
|
18341
18341
|
}
|
|
18342
18342
|
setTimeout(() => D(se)), $.preventDefault();
|
|
@@ -18358,7 +18358,7 @@ var Q8 = "SelectItemAlignedPosition", xS = h.forwardRef((e, t) => {
|
|
|
18358
18358
|
if (i.trigger && i.valueNode && s && c && g && y && b) {
|
|
18359
18359
|
const P = i.trigger.getBoundingClientRect(), E = c.getBoundingClientRect(), A = i.valueNode.getBoundingClientRect(), O = b.getBoundingClientRect();
|
|
18360
18360
|
if (i.dir !== "rtl") {
|
|
18361
|
-
const
|
|
18361
|
+
const G = O.left - E.left, K = A.left - G, ge = P.left - K, te = P.width + ge, je = Math.max(te, E.width), X = window.innerWidth - wt, de = Ao(K, [
|
|
18362
18362
|
wt,
|
|
18363
18363
|
// Prevents the content from going off the starting edge of the
|
|
18364
18364
|
// viewport. It may still go off the ending edge, but this can be
|
|
@@ -18369,29 +18369,29 @@ var Q8 = "SelectItemAlignedPosition", xS = h.forwardRef((e, t) => {
|
|
|
18369
18369
|
]);
|
|
18370
18370
|
s.style.minWidth = te + "px", s.style.left = de + "px";
|
|
18371
18371
|
} else {
|
|
18372
|
-
const
|
|
18372
|
+
const G = E.right - O.right, K = window.innerWidth - A.right - G, ge = window.innerWidth - P.right - K, te = P.width + ge, je = Math.max(te, E.width), X = window.innerWidth - wt, de = Ao(K, [
|
|
18373
18373
|
wt,
|
|
18374
18374
|
Math.max(wt, X - je)
|
|
18375
18375
|
]);
|
|
18376
18376
|
s.style.minWidth = te + "px", s.style.right = de + "px";
|
|
18377
18377
|
}
|
|
18378
|
-
const I = p(), Y = window.innerHeight - wt * 2, j = g.scrollHeight, F = window.getComputedStyle(c),
|
|
18378
|
+
const I = p(), Y = window.innerHeight - wt * 2, j = g.scrollHeight, F = window.getComputedStyle(c), W = parseInt(F.borderTopWidth, 10), D = parseInt(F.paddingTop, 10), z = parseInt(F.borderBottomWidth, 10), N = parseInt(F.paddingBottom, 10), V = W + D + j + N + z, ne = Math.min(y.offsetHeight * 5, V), ue = window.getComputedStyle(g), k = parseInt(ue.paddingTop, 10), L = parseInt(ue.paddingBottom, 10), q = P.top + P.height / 2 - wt, H = Y - q, ee = y.offsetHeight / 2, $ = y.offsetTop + ee, Z = W + D + $, J = V - Z;
|
|
18379
18379
|
if (Z <= q) {
|
|
18380
|
-
const
|
|
18380
|
+
const G = I.length > 0 && y === I[I.length - 1].ref.current;
|
|
18381
18381
|
s.style.bottom = "0px";
|
|
18382
18382
|
const K = c.clientHeight - g.offsetTop - g.offsetHeight, ge = Math.max(
|
|
18383
18383
|
H,
|
|
18384
18384
|
ee + // viewport might have padding bottom, include it to avoid a scrollable viewport
|
|
18385
|
-
(
|
|
18385
|
+
(G ? L : 0) + K + z
|
|
18386
18386
|
), te = Z + ge;
|
|
18387
18387
|
s.style.height = te + "px";
|
|
18388
18388
|
} else {
|
|
18389
|
-
const
|
|
18389
|
+
const G = I.length > 0 && y === I[0].ref.current;
|
|
18390
18390
|
s.style.top = "0px";
|
|
18391
18391
|
const ge = Math.max(
|
|
18392
18392
|
q,
|
|
18393
|
-
|
|
18394
|
-
(
|
|
18393
|
+
W + g.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
|
|
18394
|
+
(G ? k : 0) + ee
|
|
18395
18395
|
) + J;
|
|
18396
18396
|
s.style.height = ge + "px", g.scrollTop = Z - q + g.offsetTop;
|
|
18397
18397
|
}
|
|
@@ -20753,7 +20753,7 @@ var pt = "MenuContent", [v7, uh] = nr(pt), w_ = h.forwardRef(
|
|
|
20753
20753
|
onDismiss: m,
|
|
20754
20754
|
disableOutsideScroll: v,
|
|
20755
20755
|
...g
|
|
20756
|
-
} = e, y = En(pt, n), b = Yo(pt, n), w = Ko(n), x = m_(n), C = f7(n), [S, T] = h.useState(null), P = h.useRef(null), E = ae(t, P, y.onContentChange), A = h.useRef(0), O = h.useRef(""), I = h.useRef(0), Y = h.useRef(null), j = h.useRef("right"), F = h.useRef(0),
|
|
20756
|
+
} = e, y = En(pt, n), b = Yo(pt, n), w = Ko(n), x = m_(n), C = f7(n), [S, T] = h.useState(null), P = h.useRef(null), E = ae(t, P, y.onContentChange), A = h.useRef(0), O = h.useRef(""), I = h.useRef(0), Y = h.useRef(null), j = h.useRef("right"), F = h.useRef(0), W = v ? Uo : h.Fragment, D = v ? { as: w7, allowPinchZoom: !0 } : void 0, z = (V) => {
|
|
20757
20757
|
const ne = O.current + V, ue = C().filter(($) => !$.disabled), k = document.activeElement, L = ue.find(($) => $.ref.current === k)?.textValue, q = ue.map(($) => $.textValue), H = I7(q, ne, L), ee = ue.find(($) => $.textValue === H)?.ref.current;
|
|
20758
20758
|
(function $(Z) {
|
|
20759
20759
|
O.current = Z, window.clearTimeout(A.current), Z !== "" && (A.current = window.setTimeout(() => $(""), 1e3));
|
|
@@ -20788,7 +20788,7 @@ var pt = "MenuContent", [v7, uh] = nr(pt), w_ = h.forwardRef(
|
|
|
20788
20788
|
onPointerGraceIntentChange: h.useCallback((V) => {
|
|
20789
20789
|
Y.current = V;
|
|
20790
20790
|
}, []),
|
|
20791
|
-
children: /* @__PURE__ */ u(
|
|
20791
|
+
children: /* @__PURE__ */ u(W, { ...D, children: /* @__PURE__ */ u(
|
|
20792
20792
|
qo,
|
|
20793
20793
|
{
|
|
20794
20794
|
asChild: !0,
|
|
@@ -22730,7 +22730,7 @@ var x2 = ["PageUp", "PageDown"], C2 = ["ArrowUp", "ArrowDown", "ArrowLeft", "Arr
|
|
|
22730
22730
|
C[b.current] !== I && p(C);
|
|
22731
22731
|
}
|
|
22732
22732
|
function O(I, Y, { commit: j } = { commit: !1 }) {
|
|
22733
|
-
const F = xF(i),
|
|
22733
|
+
const F = xF(i), W = CF(Math.round((I - r) / i) * i + r, F), D = Ao(W, [r, o]);
|
|
22734
22734
|
S((z = []) => {
|
|
22735
22735
|
const N = mF(z, D, Y);
|
|
22736
22736
|
if (wF(N, l * i)) {
|
|
@@ -22774,7 +22774,7 @@ var x2 = ["PageUp", "PageDown"], C2 = ["ArrowUp", "ArrowDown", "ArrowLeft", "Arr
|
|
|
22774
22774
|
onEndKeyDown: () => !s && O(o, C.length - 1, { commit: !0 }),
|
|
22775
22775
|
onStepKeyDown: ({ event: I, direction: Y }) => {
|
|
22776
22776
|
if (!s) {
|
|
22777
|
-
const
|
|
22777
|
+
const W = x2.includes(I.key) || I.shiftKey && C2.includes(I.key) ? 10 : 1, D = b.current, z = C[D], N = i * W * Y;
|
|
22778
22778
|
O(z + N, D, { commit: !0 });
|
|
22779
22779
|
}
|
|
22780
22780
|
}
|
|
@@ -23996,7 +23996,7 @@ var to = '[cmdk-group=""]', ud = '[cmdk-group-items=""]', CV = '[cmdk-group-head
|
|
|
23996
23996
|
}), L.push([H, $]);
|
|
23997
23997
|
});
|
|
23998
23998
|
let q = S.current;
|
|
23999
|
-
|
|
23999
|
+
W().sort((H, ee) => {
|
|
24000
24000
|
var $, Z;
|
|
24001
24001
|
let J = H.getAttribute("id"), se = ee.getAttribute("id");
|
|
24002
24002
|
return (($ = k.get(se)) != null ? $ : 0) - ((Z = k.get(J)) != null ? Z : 0);
|
|
@@ -24010,7 +24010,7 @@ var to = '[cmdk-group=""]', ud = '[cmdk-group-items=""]', CV = '[cmdk-group-head
|
|
|
24010
24010
|
});
|
|
24011
24011
|
}
|
|
24012
24012
|
function I() {
|
|
24013
|
-
let k =
|
|
24013
|
+
let k = W().find((q) => q.getAttribute("aria-disabled") !== "true"), L = k?.getAttribute(ur);
|
|
24014
24014
|
P.setState("value", L || void 0);
|
|
24015
24015
|
}
|
|
24016
24016
|
function Y() {
|
|
@@ -24040,17 +24040,17 @@ var to = '[cmdk-group=""]', ud = '[cmdk-group-items=""]', CV = '[cmdk-group-head
|
|
|
24040
24040
|
var k;
|
|
24041
24041
|
return (k = S.current) == null ? void 0 : k.querySelector(`${sR}[aria-selected="true"]`);
|
|
24042
24042
|
}
|
|
24043
|
-
function
|
|
24043
|
+
function W() {
|
|
24044
24044
|
var k;
|
|
24045
24045
|
return Array.from(((k = S.current) == null ? void 0 : k.querySelectorAll(Eb)) || []);
|
|
24046
24046
|
}
|
|
24047
24047
|
function D(k) {
|
|
24048
|
-
let L =
|
|
24048
|
+
let L = W()[k];
|
|
24049
24049
|
L && P.setState("value", L.getAttribute(ur));
|
|
24050
24050
|
}
|
|
24051
24051
|
function z(k) {
|
|
24052
24052
|
var L;
|
|
24053
|
-
let q = F(), H =
|
|
24053
|
+
let q = F(), H = W(), ee = H.findIndex((Z) => Z === q), $ = H[ee + k];
|
|
24054
24054
|
(L = s.current) != null && L.loop && ($ = ee + k < 0 ? H[H.length - 1] : ee + k === H.length ? H[0] : H[ee + k]), $ && P.setState("value", $.getAttribute(ur));
|
|
24055
24055
|
}
|
|
24056
24056
|
function N(k) {
|
|
@@ -24058,7 +24058,7 @@ var to = '[cmdk-group=""]', ud = '[cmdk-group-items=""]', CV = '[cmdk-group-head
|
|
|
24058
24058
|
for (; q && !H; ) q = k > 0 ? IV(q, to) : OV(q, to), H = q?.querySelector(Eb);
|
|
24059
24059
|
H ? P.setState("value", H.getAttribute(ur)) : z(k);
|
|
24060
24060
|
}
|
|
24061
|
-
let V = () => D(
|
|
24061
|
+
let V = () => D(W().length - 1), ne = (k) => {
|
|
24062
24062
|
k.preventDefault(), k.metaKey ? V() : k.altKey ? N(1) : z(1);
|
|
24063
24063
|
}, ue = (k) => {
|
|
24064
24064
|
k.preventDefault(), k.metaKey ? D(0) : k.altKey ? N(-1) : z(-1);
|
|
@@ -24401,7 +24401,7 @@ const FV = h.forwardRef(
|
|
|
24401
24401
|
closeOnSelect: S = !1,
|
|
24402
24402
|
...T
|
|
24403
24403
|
}, P) => {
|
|
24404
|
-
const [E, A] = h.useState(n), [O, I] = h.useState(!1), [Y, j] = h.useState(!1), [F,
|
|
24404
|
+
const [E, A] = h.useState(n), [O, I] = h.useState(!1), [Y, j] = h.useState(!1), [F, W] = h.useState(""), [D, z] = h.useState(""), [N, V] = h.useState(""), ne = h.useRef(E.length), ue = h.useRef(O), k = h.useRef(F), L = h.useCallback(
|
|
24405
24405
|
(U, ie = "polite") => {
|
|
24406
24406
|
ie === "assertive" ? (V(U), setTimeout(() => V(""), 100)) : (z(U), setTimeout(() => z(""), 100));
|
|
24407
24407
|
},
|
|
@@ -24416,13 +24416,13 @@ const FV = h.forwardRef(
|
|
|
24416
24416
|
return me.every((be, An) => be === Ae[An]);
|
|
24417
24417
|
},
|
|
24418
24418
|
[]
|
|
24419
|
-
),
|
|
24420
|
-
A(n), I(!1),
|
|
24419
|
+
), G = h.useCallback(() => {
|
|
24420
|
+
A(n), I(!1), W(""), t(n);
|
|
24421
24421
|
}, [n, t]), K = h.useRef(null);
|
|
24422
24422
|
h.useImperativeHandle(
|
|
24423
24423
|
P,
|
|
24424
24424
|
() => ({
|
|
24425
|
-
reset:
|
|
24425
|
+
reset: G,
|
|
24426
24426
|
getSelectedValues: () => E,
|
|
24427
24427
|
setSelectedValues: (U) => {
|
|
24428
24428
|
A(U), t(U);
|
|
@@ -24440,7 +24440,7 @@ const FV = h.forwardRef(
|
|
|
24440
24440
|
}
|
|
24441
24441
|
}
|
|
24442
24442
|
}),
|
|
24443
|
-
[
|
|
24443
|
+
[G, E, t]
|
|
24444
24444
|
);
|
|
24445
24445
|
const [ge, te] = h.useState("desktop");
|
|
24446
24446
|
h.useEffect(() => {
|
|
@@ -24547,7 +24547,7 @@ const FV = h.forwardRef(
|
|
|
24547
24547
|
width: p ? "auto" : "100%"
|
|
24548
24548
|
};
|
|
24549
24549
|
return h.useEffect(() => {
|
|
24550
|
-
O ||
|
|
24550
|
+
O || W("");
|
|
24551
24551
|
}, [O]), h.useEffect(() => {
|
|
24552
24552
|
const U = E.length, ie = de(), me = ie.filter((Ae) => !Ae.disabled).length;
|
|
24553
24553
|
if (U !== ne.current) {
|
|
@@ -24786,7 +24786,7 @@ const FV = h.forwardRef(
|
|
|
24786
24786
|
placeholder: "Search options...",
|
|
24787
24787
|
onKeyDown: Ss,
|
|
24788
24788
|
value: F,
|
|
24789
|
-
onValueChange:
|
|
24789
|
+
onValueChange: W,
|
|
24790
24790
|
"aria-label": "Search through available options",
|
|
24791
24791
|
"aria-describedby": `${q}-search-help`
|
|
24792
24792
|
}
|
|
@@ -24983,7 +24983,7 @@ const VV = (e, t) => {
|
|
|
24983
24983
|
maxWidth: y,
|
|
24984
24984
|
closeOnSelect: b = !1,
|
|
24985
24985
|
...w
|
|
24986
|
-
} = e, [x, C] = h.useState(o), [S, T] = h.useState(!1), [P, E] = h.useState(!1), [A, O] = h.useState(""), [I, Y] = h.useState(""), [j, F] = h.useState(""),
|
|
24986
|
+
} = e, [x, C] = h.useState(o), [S, T] = h.useState(!1), [P, E] = h.useState(!1), [A, O] = h.useState(""), [I, Y] = h.useState(""), [j, F] = h.useState(""), W = h.useRef(S), D = h.useRef(A), z = (X) => {
|
|
24987
24987
|
m || se(X)?.disabled || (C(X), r(X), b && T(!1));
|
|
24988
24988
|
}, N = h.useCallback(
|
|
24989
24989
|
(X, de = "polite") => {
|
|
@@ -25059,7 +25059,7 @@ const VV = (e, t) => {
|
|
|
25059
25059
|
), de;
|
|
25060
25060
|
},
|
|
25061
25061
|
[J]
|
|
25062
|
-
),
|
|
25062
|
+
), G = h.useMemo(() => !c || !A ? n : n.length === 0 ? [] : n.filter(
|
|
25063
25063
|
(X) => X.label.toLowerCase().includes(A.toLowerCase()) || String(X.value).toLowerCase().includes(A.toLowerCase())
|
|
25064
25064
|
), [n, A, c]), K = () => {
|
|
25065
25065
|
m || (C(""), r(""));
|
|
@@ -25074,9 +25074,9 @@ const VV = (e, t) => {
|
|
|
25074
25074
|
S || O("");
|
|
25075
25075
|
}, [S]), h.useEffect(() => {
|
|
25076
25076
|
const X = J(), de = X.filter((Te) => !Te.disabled).length;
|
|
25077
|
-
if (S !==
|
|
25077
|
+
if (S !== W.current && (N(
|
|
25078
25078
|
S ? `Dropdown opened. ${de} options available. Use arrow keys to navigate.` : "Dropdown closed."
|
|
25079
|
-
),
|
|
25079
|
+
), W.current = S), A !== D.current && A !== void 0) {
|
|
25080
25080
|
if (A && S) {
|
|
25081
25081
|
const Te = X.filter(
|
|
25082
25082
|
(ze) => ze.label.toLowerCase().includes(A.toLowerCase()) || String(ze.value).toLowerCase().includes(A.toLowerCase())
|
|
@@ -25223,7 +25223,7 @@ const VV = (e, t) => {
|
|
|
25223
25223
|
children: [
|
|
25224
25224
|
/* @__PURE__ */ u(gR, { children: d || "No results found." }),
|
|
25225
25225
|
" ",
|
|
25226
|
-
/* @__PURE__ */ u(lo, { children:
|
|
25226
|
+
/* @__PURE__ */ u(lo, { children: G.map((X) => {
|
|
25227
25227
|
const de = x === X.value;
|
|
25228
25228
|
return /* @__PURE__ */ _(
|
|
25229
25229
|
fr,
|
|
@@ -30167,13 +30167,13 @@ function Eq({
|
|
|
30167
30167
|
}) {
|
|
30168
30168
|
const [I, Y] = M.useState(
|
|
30169
30169
|
d ?? {}
|
|
30170
|
-
), [j, F] = M.useState({}), [
|
|
30170
|
+
), [j, F] = M.useState({}), [W, D] = M.useState({}), [z, N] = M.useState(""), [V, ne] = M.useState(c), [ue, k] = M.useState({
|
|
30171
30171
|
pageIndex: 0,
|
|
30172
30172
|
pageSize: 10
|
|
30173
|
-
}), L = P ?? z, q = S ?? V, H = A ?? ue, ee = (
|
|
30174
|
-
E ? E(
|
|
30175
|
-
}, $ = (
|
|
30176
|
-
const K = typeof
|
|
30173
|
+
}), L = P ?? z, q = S ?? V, H = A ?? ue, ee = (G) => {
|
|
30174
|
+
E ? E(G) : N(G);
|
|
30175
|
+
}, $ = (G) => {
|
|
30176
|
+
const K = typeof G == "function" ? G(q) : G;
|
|
30177
30177
|
T ? T(K) : ne(K);
|
|
30178
30178
|
}, J = Gj({
|
|
30179
30179
|
data: t,
|
|
@@ -30182,7 +30182,7 @@ function Eq({
|
|
|
30182
30182
|
fuzzy: rz
|
|
30183
30183
|
},
|
|
30184
30184
|
state: {
|
|
30185
|
-
expanded:
|
|
30185
|
+
expanded: W,
|
|
30186
30186
|
rowSelection: j,
|
|
30187
30187
|
sorting: q,
|
|
30188
30188
|
globalFilter: L,
|
|
@@ -30194,8 +30194,8 @@ function Eq({
|
|
|
30194
30194
|
onSortingChange: $,
|
|
30195
30195
|
// onColumnFiltersChange: setColumnFilters,
|
|
30196
30196
|
onGlobalFilterChange: ee,
|
|
30197
|
-
onPaginationChange: (
|
|
30198
|
-
const K = typeof
|
|
30197
|
+
onPaginationChange: (G) => {
|
|
30198
|
+
const K = typeof G == "function" ? G(H) : G;
|
|
30199
30199
|
O ? O(K) : k(K);
|
|
30200
30200
|
},
|
|
30201
30201
|
onExpandedChange: D,
|
|
@@ -30218,7 +30218,7 @@ function Eq({
|
|
|
30218
30218
|
// debugHeaders: true,
|
|
30219
30219
|
// debugColumns: false,
|
|
30220
30220
|
}), se = Ge(
|
|
30221
|
-
() => J.getHeaderGroups().map((
|
|
30221
|
+
() => J.getHeaderGroups().map((G) => G.headers).flat(),
|
|
30222
30222
|
[J]
|
|
30223
30223
|
);
|
|
30224
30224
|
return /* @__PURE__ */ _("div", { className: "space-y-3", children: [
|
|
@@ -30230,8 +30230,8 @@ function Eq({
|
|
|
30230
30230
|
{
|
|
30231
30231
|
headers: se,
|
|
30232
30232
|
currentSort: q.length > 0 ? q[0] : null,
|
|
30233
|
-
onSortChange: (
|
|
30234
|
-
$([{ id:
|
|
30233
|
+
onSortChange: (G, K) => {
|
|
30234
|
+
$([{ id: G, desc: K }]);
|
|
30235
30235
|
},
|
|
30236
30236
|
onClearSort: () => $([])
|
|
30237
30237
|
}
|
|
@@ -30241,7 +30241,7 @@ function Eq({
|
|
|
30241
30241
|
{
|
|
30242
30242
|
id: "search-bar",
|
|
30243
30243
|
value: L ?? "",
|
|
30244
|
-
onChange: (
|
|
30244
|
+
onChange: (G) => ee(String(G)),
|
|
30245
30245
|
placeholder: "Search..."
|
|
30246
30246
|
}
|
|
30247
30247
|
)
|
|
@@ -30268,29 +30268,29 @@ function Eq({
|
|
|
30268
30268
|
// "grid-cols-1 md:grid-cols-2 xl:grid-cols-3",
|
|
30269
30269
|
p.className
|
|
30270
30270
|
),
|
|
30271
|
-
children: J.getRowModel().rows.map((
|
|
30271
|
+
children: J.getRowModel().rows.map((G) => /* @__PURE__ */ u("div", { onClick: () => g?.(G.original), children: /* @__PURE__ */ _(
|
|
30272
30272
|
ht,
|
|
30273
30273
|
{
|
|
30274
30274
|
className: R(
|
|
30275
30275
|
"max-w-none",
|
|
30276
30276
|
g ? "hover:bg-neutral-alpha-5 cursor-pointer" : ""
|
|
30277
30277
|
),
|
|
30278
|
-
"data-state":
|
|
30278
|
+
"data-state": G.getIsSelected() && "selected",
|
|
30279
30279
|
variant: "border",
|
|
30280
30280
|
children: [
|
|
30281
30281
|
/* @__PURE__ */ _(v5, { className: "flex items-center gap-2", children: [
|
|
30282
|
-
/* @__PURE__ */ u(y5, { className: "line-clamp-1 grow text-base", children:
|
|
30282
|
+
/* @__PURE__ */ u(y5, { className: "line-clamp-1 grow text-base", children: G.getVisibleCells().filter(
|
|
30283
30283
|
(K) => K.column.id === p.headerSlot
|
|
30284
30284
|
)?.map((K) => /* @__PURE__ */ u(Bi, { children: ln(
|
|
30285
30285
|
K.column.columnDef.cell,
|
|
30286
30286
|
K.getContext()
|
|
30287
30287
|
) }, K.id)) }),
|
|
30288
|
-
|
|
30288
|
+
G.getVisibleCells().filter((K) => K.column.id === p?.rightSlot)?.map((K) => /* @__PURE__ */ u("div", { className: "text-lg", children: ln(
|
|
30289
30289
|
K.column.columnDef.cell,
|
|
30290
30290
|
K.getContext()
|
|
30291
30291
|
) }, K.id))
|
|
30292
30292
|
] }),
|
|
30293
|
-
/* @__PURE__ */ u(k1, { className: "flex flex-wrap justify-between", children:
|
|
30293
|
+
/* @__PURE__ */ u(k1, { className: "flex flex-wrap justify-between", children: G.getVisibleCells().filter(
|
|
30294
30294
|
(K) => K.column.id !== p.headerSlot && K.column.id !== p.rightSlot && // @ts-expect-error I know that column id by defintion is keyof TData
|
|
30295
30295
|
!p.excludeColumns?.includes(K.column.id)
|
|
30296
30296
|
).map((K) => /* @__PURE__ */ u(
|
|
@@ -30310,28 +30310,40 @@ function Eq({
|
|
|
30310
30310
|
},
|
|
30311
30311
|
K.id
|
|
30312
30312
|
)) }),
|
|
30313
|
-
|
|
30313
|
+
G.getIsExpanded() && l({ row: G })
|
|
30314
30314
|
]
|
|
30315
30315
|
}
|
|
30316
|
-
) },
|
|
30316
|
+
) }, G.id))
|
|
30317
30317
|
}
|
|
30318
30318
|
) : /* @__PURE__ */ _(e7, { children: [
|
|
30319
|
-
/* @__PURE__ */ u(t7, { children: /* @__PURE__ */ u(_f, { children: se.map((
|
|
30320
|
-
|
|
30319
|
+
/* @__PURE__ */ u(t7, { children: /* @__PURE__ */ u(_f, { children: se.map((G) => /* @__PURE__ */ u(
|
|
30320
|
+
r7,
|
|
30321
|
+
{
|
|
30322
|
+
style: {
|
|
30323
|
+
width: G.column.columnDef.size,
|
|
30324
|
+
minWidth: G.column.columnDef.minSize,
|
|
30325
|
+
maxWidth: G.column.columnDef.maxSize
|
|
30326
|
+
},
|
|
30327
|
+
className: G.column.columnDef.meta?.className,
|
|
30328
|
+
children: /* @__PURE__ */ u(Wj, { header: G })
|
|
30329
|
+
},
|
|
30330
|
+
G.id
|
|
30331
|
+
)) }) }),
|
|
30332
|
+
/* @__PURE__ */ u(n7, { children: n ? /* @__PURE__ */ u(iz, { headers: se.map((G) => G.id) }) : J.getRowModel().rows.map((G) => /* @__PURE__ */ _(Bi, { children: [
|
|
30321
30333
|
/* @__PURE__ */ u(
|
|
30322
30334
|
_f,
|
|
30323
30335
|
{
|
|
30324
|
-
onClick: () => g?.(
|
|
30325
|
-
"data-state":
|
|
30336
|
+
onClick: () => g?.(G.original),
|
|
30337
|
+
"data-state": G.getIsSelected() && "selected",
|
|
30326
30338
|
className: g ? "hover:bg-neutral-alpha-5 cursor-pointer" : "",
|
|
30327
|
-
children:
|
|
30339
|
+
children: G.getVisibleCells().map((K) => /* @__PURE__ */ u(o_, { children: ln(
|
|
30328
30340
|
K.column.columnDef.cell,
|
|
30329
30341
|
K.getContext()
|
|
30330
30342
|
) }, K.id))
|
|
30331
30343
|
}
|
|
30332
30344
|
),
|
|
30333
|
-
|
|
30334
|
-
] },
|
|
30345
|
+
G.getIsExpanded() && /* @__PURE__ */ u("tr", { children: /* @__PURE__ */ u("td", { colSpan: G.getVisibleCells().length, children: l({ row: G }) }) })
|
|
30346
|
+
] }, G.id)) })
|
|
30335
30347
|
] }) : m ?? /* @__PURE__ */ u("div", { className: "bg-neutral-alpha-2 m-12 flex h-48 items-center justify-center rounded-lg shadow", children: "No results available." })
|
|
30336
30348
|
}
|
|
30337
30349
|
),
|
|
@@ -30343,18 +30355,18 @@ function Eq({
|
|
|
30343
30355
|
className: J.getCanPreviousPage() ? "cursor-pointer" : "pointer-events-none opacity-50"
|
|
30344
30356
|
}
|
|
30345
30357
|
) }),
|
|
30346
|
-
Array.from({ length: J.getPageCount() }, (
|
|
30347
|
-
(
|
|
30348
|
-
const K = J.getState().pagination.pageIndex, ge = J.getPageCount(), te =
|
|
30349
|
-
return je || X ? /* @__PURE__ */ u(Si, { children: /* @__PURE__ */ u(LB, {}) },
|
|
30358
|
+
Array.from({ length: J.getPageCount() }, (G, K) => K).map(
|
|
30359
|
+
(G) => {
|
|
30360
|
+
const K = J.getState().pagination.pageIndex, ge = J.getPageCount(), te = G === 0 || G === ge - 1 || G >= K - 1 && G <= K + 1, je = G === K - 2 && K > 2, X = G === K + 2 && K < ge - 3;
|
|
30361
|
+
return je || X ? /* @__PURE__ */ u(Si, { children: /* @__PURE__ */ u(LB, {}) }, G) : te ? /* @__PURE__ */ u(Si, { children: /* @__PURE__ */ u(
|
|
30350
30362
|
Lh,
|
|
30351
30363
|
{
|
|
30352
|
-
onClick: () => J.setPageIndex(
|
|
30353
|
-
isActive: K ===
|
|
30364
|
+
onClick: () => J.setPageIndex(G),
|
|
30365
|
+
isActive: K === G,
|
|
30354
30366
|
className: "cursor-pointer",
|
|
30355
|
-
children:
|
|
30367
|
+
children: G + 1
|
|
30356
30368
|
}
|
|
30357
|
-
) },
|
|
30369
|
+
) }, G) : null;
|
|
30358
30370
|
}
|
|
30359
30371
|
),
|
|
30360
30372
|
/* @__PURE__ */ u(Si, { children: /* @__PURE__ */ u(
|