@snowpact/react-tanstack-query-table 1.1.3 → 1.2.0
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/dist/index.cjs +9 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +430 -425
- package/dist/index.js.map +1 -1
- package/package.json +4 -2
package/dist/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { jsxs as B, jsx as p, Fragment as
|
|
1
|
+
import { jsxs as B, jsx as p, Fragment as un } from "react/jsx-runtime";
|
|
2
2
|
import { useMutation as da, useQuery as Rr, keepPreviousData as fa } from "@tanstack/react-query";
|
|
3
3
|
import * as f from "react";
|
|
4
|
-
import Ze, { useState as ge, useEffect as Tt, useRef as
|
|
5
|
-
import * as
|
|
4
|
+
import Ze, { useState as ge, useEffect as Tt, useRef as Gn, useCallback as We, useMemo as Pe, forwardRef as Ar, useLayoutEffect as pa } from "react";
|
|
5
|
+
import * as dn from "react-dom";
|
|
6
6
|
import ma from "react-dom";
|
|
7
7
|
import { useReactTable as ha, getFilteredRowModel as ga, getPaginationRowModel as va, getSortedRowModel as ba, getCoreRowModel as wa, flexRender as zo } from "@tanstack/react-table";
|
|
8
8
|
const ve = ({ children: e, ...t }) => /* @__PURE__ */ p(
|
|
@@ -105,7 +105,7 @@ const Fa = (e) => {
|
|
|
105
105
|
loadingOverlay: "bg-background/50"
|
|
106
106
|
}
|
|
107
107
|
};
|
|
108
|
-
let
|
|
108
|
+
let Kn = JSON.parse(JSON.stringify(Va));
|
|
109
109
|
const Ua = (e, t) => {
|
|
110
110
|
const n = JSON.parse(JSON.stringify(e));
|
|
111
111
|
for (const o in t) {
|
|
@@ -114,18 +114,18 @@ const Ua = (e, t) => {
|
|
|
114
114
|
}
|
|
115
115
|
return n;
|
|
116
116
|
}, Ba = (e) => {
|
|
117
|
-
|
|
118
|
-
},
|
|
117
|
+
Kn = Ua(Kn, e);
|
|
118
|
+
}, de = () => Kn;
|
|
119
119
|
let _r = () => ({
|
|
120
120
|
t: (e) => e
|
|
121
121
|
});
|
|
122
122
|
const za = (e) => {
|
|
123
123
|
_r = e;
|
|
124
124
|
}, ht = () => _r();
|
|
125
|
-
let
|
|
125
|
+
let jn = !1;
|
|
126
126
|
const Lm = (e) => {
|
|
127
|
-
|
|
128
|
-
}, Fm = () =>
|
|
127
|
+
jn || (za(e.useTranslation), Fa(e.LinkComponent), Oa(e.useConfirm), e.styles && Ba(e.styles), (e.onActionHover || e.onActionUnhover) && Na(e.onActionHover, e.onActionUnhover), jn = !0);
|
|
128
|
+
}, Fm = () => jn, Wa = (e, t) => {
|
|
129
129
|
const n = new Array(e.length + t.length);
|
|
130
130
|
for (let o = 0; o < e.length; o++)
|
|
131
131
|
n[o] = e[o];
|
|
@@ -139,7 +139,7 @@ const Lm = (e) => {
|
|
|
139
139
|
nextPart: e,
|
|
140
140
|
validators: t,
|
|
141
141
|
classGroupId: n
|
|
142
|
-
}),
|
|
142
|
+
}), tn = "-", Ho = [], Ga = "arbitrary..", Ka = (e) => {
|
|
143
143
|
const t = Ya(e), {
|
|
144
144
|
conflictingClassGroups: n,
|
|
145
145
|
conflictingClassGroupModifiers: o
|
|
@@ -148,7 +148,7 @@ const Lm = (e) => {
|
|
|
148
148
|
getClassGroupId: (i) => {
|
|
149
149
|
if (i.startsWith("[") && i.endsWith("]"))
|
|
150
150
|
return ja(i);
|
|
151
|
-
const a = i.split(
|
|
151
|
+
const a = i.split(tn), l = a[0] === "" && a.length > 1 ? 1 : 0;
|
|
152
152
|
return Dr(a, l, t);
|
|
153
153
|
},
|
|
154
154
|
getConflictingClassGroupIds: (i, a) => {
|
|
@@ -170,7 +170,7 @@ const Lm = (e) => {
|
|
|
170
170
|
const i = n.validators;
|
|
171
171
|
if (i === null)
|
|
172
172
|
return;
|
|
173
|
-
const a = t === 0 ? e.join(
|
|
173
|
+
const a = t === 0 ? e.join(tn) : e.slice(t).join(tn), l = i.length;
|
|
174
174
|
for (let c = 0; c < l; c++) {
|
|
175
175
|
const d = i[c];
|
|
176
176
|
if (d.validator(a))
|
|
@@ -225,7 +225,7 @@ const Lm = (e) => {
|
|
|
225
225
|
}
|
|
226
226
|
}, Lr = (e, t) => {
|
|
227
227
|
let n = e;
|
|
228
|
-
const o = t.split(
|
|
228
|
+
const o = t.split(tn), r = o.length;
|
|
229
229
|
for (let s = 0; s < r; s++) {
|
|
230
230
|
const i = o[s];
|
|
231
231
|
let a = n.nextPart.get(i);
|
|
@@ -256,7 +256,7 @@ const Lm = (e) => {
|
|
|
256
256
|
s in n ? n[s] = i : r(s, i);
|
|
257
257
|
}
|
|
258
258
|
};
|
|
259
|
-
},
|
|
259
|
+
}, Yn = "!", Go = ":", nc = [], Ko = (e, t, n, o, r) => ({
|
|
260
260
|
modifiers: e,
|
|
261
261
|
hasImportantModifier: t,
|
|
262
262
|
baseClassName: n,
|
|
@@ -287,12 +287,12 @@ const Lm = (e) => {
|
|
|
287
287
|
}
|
|
288
288
|
const u = s.length === 0 ? r : r.slice(l);
|
|
289
289
|
let h = u, g = !1;
|
|
290
|
-
u.endsWith(
|
|
290
|
+
u.endsWith(Yn) ? (h = u.slice(0, -1), g = !0) : (
|
|
291
291
|
/**
|
|
292
292
|
* In Tailwind CSS v3 the important modifier was at the start of the base class name. This is still supported for legacy reasons.
|
|
293
293
|
* @see https://github.com/dcastil/tailwind-merge/issues/513#issuecomment-2614029864
|
|
294
294
|
*/
|
|
295
|
-
u.startsWith(
|
|
295
|
+
u.startsWith(Yn) && (h = u.slice(1), g = !0)
|
|
296
296
|
);
|
|
297
297
|
const b = c && c > l ? c - l : void 0;
|
|
298
298
|
return Ko(s, g, h, b);
|
|
@@ -359,7 +359,7 @@ const Lm = (e) => {
|
|
|
359
359
|
}
|
|
360
360
|
v = !1;
|
|
361
361
|
}
|
|
362
|
-
const x = h.length === 0 ? "" : h.length === 1 ? h[0] : s(h).join(":"), w = g ? x +
|
|
362
|
+
const x = h.length === 0 ? "" : h.length === 1 ? h[0] : s(h).join(":"), w = g ? x + Yn : x, S = w + y;
|
|
363
363
|
if (i.indexOf(S) > -1)
|
|
364
364
|
continue;
|
|
365
365
|
i.push(S);
|
|
@@ -399,12 +399,12 @@ const Lm = (e) => {
|
|
|
399
399
|
}, uc = [], se = (e) => {
|
|
400
400
|
const t = (n) => n[e] || uc;
|
|
401
401
|
return t.isThemeGetter = !0, t;
|
|
402
|
-
}, $r = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, Vr = /^\((?:(\w[\w-]*):)?(.+)\)$/i, dc = /^\d+\/\d+$/, fc = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, pc = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, mc = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, hc = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, gc = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, ct = (e) => dc.test(e), W = (e) => !!e && !Number.isNaN(Number(e)), Ue = (e) => !!e && Number.isInteger(Number(e)),
|
|
402
|
+
}, $r = /^\[(?:(\w[\w-]*):)?(.+)\]$/i, Vr = /^\((?:(\w[\w-]*):)?(.+)\)$/i, dc = /^\d+\/\d+$/, fc = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, pc = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, mc = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/, hc = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, gc = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, ct = (e) => dc.test(e), W = (e) => !!e && !Number.isNaN(Number(e)), Ue = (e) => !!e && Number.isInteger(Number(e)), Mn = (e) => e.endsWith("%") && W(e.slice(0, -1)), Fe = (e) => fc.test(e), vc = () => !0, bc = (e) => (
|
|
403
403
|
// `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.
|
|
404
404
|
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
|
|
405
405
|
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
|
|
406
406
|
pc.test(e) && !mc.test(e)
|
|
407
|
-
), Ur = () => !1, wc = (e) => hc.test(e), yc = (e) => gc.test(e), xc = (e) => !k(e) && !_(e), Cc = (e) => gt(e, Wr, Ur), k = (e) => $r.test(e), Je = (e) => gt(e, Hr, bc),
|
|
407
|
+
), Ur = () => !1, wc = (e) => hc.test(e), yc = (e) => gc.test(e), xc = (e) => !k(e) && !_(e), Cc = (e) => gt(e, Wr, Ur), k = (e) => $r.test(e), Je = (e) => gt(e, Hr, bc), Nn = (e) => gt(e, Tc, W), jo = (e) => gt(e, Br, Ur), Sc = (e) => gt(e, zr, yc), Ut = (e) => gt(e, Gr, wc), _ = (e) => Vr.test(e), Ct = (e) => vt(e, Hr), Ec = (e) => vt(e, Ic), Yo = (e) => vt(e, Br), Rc = (e) => vt(e, Wr), Ac = (e) => vt(e, zr), Bt = (e) => vt(e, Gr, !0), gt = (e, t, n) => {
|
|
408
408
|
const o = $r.exec(e);
|
|
409
409
|
return o ? o[1] ? t(o[1]) : n(o[2]) : !1;
|
|
410
410
|
}, vt = (e, t, n = !1) => {
|
|
@@ -429,15 +429,15 @@ const Lm = (e) => {
|
|
|
429
429
|
"bottom-left",
|
|
430
430
|
// Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378
|
|
431
431
|
"left-bottom"
|
|
432
|
-
], A = () => [...S(), _, k], T = () => ["auto", "hidden", "clip", "visible", "scroll"], R = () => ["auto", "contain", "none"], C = () => [_, k, l], M = () => [ct, "full", "auto", ...C()], N = () => [Ue, "none", "subgrid", _, k],
|
|
432
|
+
], A = () => [...S(), _, k], T = () => ["auto", "hidden", "clip", "visible", "scroll"], R = () => ["auto", "contain", "none"], C = () => [_, k, l], M = () => [ct, "full", "auto", ...C()], N = () => [Ue, "none", "subgrid", _, k], F = () => ["auto", {
|
|
433
433
|
span: ["full", Ue, _, k]
|
|
434
|
-
}, Ue, _, k],
|
|
434
|
+
}, Ue, _, k], V = () => [Ue, "auto", _, k], U = () => ["auto", "min", "max", "fr", _, k], $ = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], H = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], O = () => ["auto", ...C()], D = () => [ct, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...C()], E = () => [e, _, k], P = () => [...S(), Yo, jo, {
|
|
435
435
|
position: [_, k]
|
|
436
436
|
}], q = () => ["no-repeat", {
|
|
437
437
|
repeat: ["", "x", "y", "space", "round"]
|
|
438
438
|
}], te = () => ["auto", "cover", "contain", Rc, Cc, {
|
|
439
439
|
size: [_, k]
|
|
440
|
-
}], re = () => [
|
|
440
|
+
}], re = () => [Mn, Ct, Je], J = () => [
|
|
441
441
|
// Deprecated since Tailwind CSS v4.0.0
|
|
442
442
|
"",
|
|
443
443
|
"none",
|
|
@@ -445,14 +445,14 @@ const Lm = (e) => {
|
|
|
445
445
|
c,
|
|
446
446
|
_,
|
|
447
447
|
k
|
|
448
|
-
], Z = () => ["", W, Ct, Je], le = () => ["solid", "dashed", "dotted", "double"], ie = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], I = () => [W,
|
|
448
|
+
], Z = () => ["", W, Ct, Je], le = () => ["solid", "dashed", "dotted", "double"], ie = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], I = () => [W, Mn, Yo, jo], j = () => [
|
|
449
449
|
// Deprecated since Tailwind CSS v4.0.0
|
|
450
450
|
"",
|
|
451
451
|
"none",
|
|
452
452
|
b,
|
|
453
453
|
_,
|
|
454
454
|
k
|
|
455
|
-
],
|
|
455
|
+
], G = () => ["none", W, _, k], K = () => ["none", W, _, k], Y = () => [W, _, k], z = () => [ct, "full", ...C()];
|
|
456
456
|
return {
|
|
457
457
|
cacheSize: 500,
|
|
458
458
|
theme: {
|
|
@@ -764,21 +764,21 @@ const Lm = (e) => {
|
|
|
764
764
|
* @see https://tailwindcss.com/docs/grid-column
|
|
765
765
|
*/
|
|
766
766
|
"col-start-end": [{
|
|
767
|
-
col:
|
|
767
|
+
col: F()
|
|
768
768
|
}],
|
|
769
769
|
/**
|
|
770
770
|
* Grid Column Start
|
|
771
771
|
* @see https://tailwindcss.com/docs/grid-column
|
|
772
772
|
*/
|
|
773
773
|
"col-start": [{
|
|
774
|
-
"col-start":
|
|
774
|
+
"col-start": V()
|
|
775
775
|
}],
|
|
776
776
|
/**
|
|
777
777
|
* Grid Column End
|
|
778
778
|
* @see https://tailwindcss.com/docs/grid-column
|
|
779
779
|
*/
|
|
780
780
|
"col-end": [{
|
|
781
|
-
"col-end":
|
|
781
|
+
"col-end": V()
|
|
782
782
|
}],
|
|
783
783
|
/**
|
|
784
784
|
* Grid Template Rows
|
|
@@ -792,21 +792,21 @@ const Lm = (e) => {
|
|
|
792
792
|
* @see https://tailwindcss.com/docs/grid-row
|
|
793
793
|
*/
|
|
794
794
|
"row-start-end": [{
|
|
795
|
-
row:
|
|
795
|
+
row: F()
|
|
796
796
|
}],
|
|
797
797
|
/**
|
|
798
798
|
* Grid Row Start
|
|
799
799
|
* @see https://tailwindcss.com/docs/grid-row
|
|
800
800
|
*/
|
|
801
801
|
"row-start": [{
|
|
802
|
-
"row-start":
|
|
802
|
+
"row-start": V()
|
|
803
803
|
}],
|
|
804
804
|
/**
|
|
805
805
|
* Grid Row End
|
|
806
806
|
* @see https://tailwindcss.com/docs/grid-row
|
|
807
807
|
*/
|
|
808
808
|
"row-end": [{
|
|
809
|
-
"row-end":
|
|
809
|
+
"row-end": V()
|
|
810
810
|
}],
|
|
811
811
|
/**
|
|
812
812
|
* Grid Auto Flow
|
|
@@ -820,14 +820,14 @@ const Lm = (e) => {
|
|
|
820
820
|
* @see https://tailwindcss.com/docs/grid-auto-columns
|
|
821
821
|
*/
|
|
822
822
|
"auto-cols": [{
|
|
823
|
-
"auto-cols":
|
|
823
|
+
"auto-cols": U()
|
|
824
824
|
}],
|
|
825
825
|
/**
|
|
826
826
|
* Grid Auto Rows
|
|
827
827
|
* @see https://tailwindcss.com/docs/grid-auto-rows
|
|
828
828
|
*/
|
|
829
829
|
"auto-rows": [{
|
|
830
|
-
"auto-rows":
|
|
830
|
+
"auto-rows": U()
|
|
831
831
|
}],
|
|
832
832
|
/**
|
|
833
833
|
* Gap
|
|
@@ -855,35 +855,35 @@ const Lm = (e) => {
|
|
|
855
855
|
* @see https://tailwindcss.com/docs/justify-content
|
|
856
856
|
*/
|
|
857
857
|
"justify-content": [{
|
|
858
|
-
justify: [
|
|
858
|
+
justify: [...$(), "normal"]
|
|
859
859
|
}],
|
|
860
860
|
/**
|
|
861
861
|
* Justify Items
|
|
862
862
|
* @see https://tailwindcss.com/docs/justify-items
|
|
863
863
|
*/
|
|
864
864
|
"justify-items": [{
|
|
865
|
-
"justify-items": [...
|
|
865
|
+
"justify-items": [...H(), "normal"]
|
|
866
866
|
}],
|
|
867
867
|
/**
|
|
868
868
|
* Justify Self
|
|
869
869
|
* @see https://tailwindcss.com/docs/justify-self
|
|
870
870
|
*/
|
|
871
871
|
"justify-self": [{
|
|
872
|
-
"justify-self": ["auto", ...
|
|
872
|
+
"justify-self": ["auto", ...H()]
|
|
873
873
|
}],
|
|
874
874
|
/**
|
|
875
875
|
* Align Content
|
|
876
876
|
* @see https://tailwindcss.com/docs/align-content
|
|
877
877
|
*/
|
|
878
878
|
"align-content": [{
|
|
879
|
-
content: ["normal",
|
|
879
|
+
content: ["normal", ...$()]
|
|
880
880
|
}],
|
|
881
881
|
/**
|
|
882
882
|
* Align Items
|
|
883
883
|
* @see https://tailwindcss.com/docs/align-items
|
|
884
884
|
*/
|
|
885
885
|
"align-items": [{
|
|
886
|
-
items: [...
|
|
886
|
+
items: [...H(), {
|
|
887
887
|
baseline: ["", "last"]
|
|
888
888
|
}]
|
|
889
889
|
}],
|
|
@@ -892,7 +892,7 @@ const Lm = (e) => {
|
|
|
892
892
|
* @see https://tailwindcss.com/docs/align-self
|
|
893
893
|
*/
|
|
894
894
|
"align-self": [{
|
|
895
|
-
self: ["auto", ...
|
|
895
|
+
self: ["auto", ...H(), {
|
|
896
896
|
baseline: ["", "last"]
|
|
897
897
|
}]
|
|
898
898
|
}],
|
|
@@ -901,21 +901,21 @@ const Lm = (e) => {
|
|
|
901
901
|
* @see https://tailwindcss.com/docs/place-content
|
|
902
902
|
*/
|
|
903
903
|
"place-content": [{
|
|
904
|
-
"place-content":
|
|
904
|
+
"place-content": $()
|
|
905
905
|
}],
|
|
906
906
|
/**
|
|
907
907
|
* Place Items
|
|
908
908
|
* @see https://tailwindcss.com/docs/place-items
|
|
909
909
|
*/
|
|
910
910
|
"place-items": [{
|
|
911
|
-
"place-items": [...
|
|
911
|
+
"place-items": [...H(), "baseline"]
|
|
912
912
|
}],
|
|
913
913
|
/**
|
|
914
914
|
* Place Self
|
|
915
915
|
* @see https://tailwindcss.com/docs/place-self
|
|
916
916
|
*/
|
|
917
917
|
"place-self": [{
|
|
918
|
-
"place-self": ["auto", ...
|
|
918
|
+
"place-self": ["auto", ...H()]
|
|
919
919
|
}],
|
|
920
920
|
// Spacing
|
|
921
921
|
/**
|
|
@@ -1162,14 +1162,14 @@ const Lm = (e) => {
|
|
|
1162
1162
|
* @see https://tailwindcss.com/docs/font-weight
|
|
1163
1163
|
*/
|
|
1164
1164
|
"font-weight": [{
|
|
1165
|
-
font: [o, _,
|
|
1165
|
+
font: [o, _, Nn]
|
|
1166
1166
|
}],
|
|
1167
1167
|
/**
|
|
1168
1168
|
* Font Stretch
|
|
1169
1169
|
* @see https://tailwindcss.com/docs/font-stretch
|
|
1170
1170
|
*/
|
|
1171
1171
|
"font-stretch": [{
|
|
1172
|
-
"font-stretch": ["ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "normal", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded",
|
|
1172
|
+
"font-stretch": ["ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "normal", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded", Mn, k]
|
|
1173
1173
|
}],
|
|
1174
1174
|
/**
|
|
1175
1175
|
* Font Family
|
|
@@ -1220,7 +1220,7 @@ const Lm = (e) => {
|
|
|
1220
1220
|
* @see https://tailwindcss.com/docs/line-clamp
|
|
1221
1221
|
*/
|
|
1222
1222
|
"line-clamp": [{
|
|
1223
|
-
"line-clamp": [W, "none", _,
|
|
1223
|
+
"line-clamp": [W, "none", _, Nn]
|
|
1224
1224
|
}],
|
|
1225
1225
|
/**
|
|
1226
1226
|
* Line Height
|
|
@@ -2399,56 +2399,56 @@ const Lm = (e) => {
|
|
|
2399
2399
|
* @see https://tailwindcss.com/docs/rotate
|
|
2400
2400
|
*/
|
|
2401
2401
|
rotate: [{
|
|
2402
|
-
rotate:
|
|
2402
|
+
rotate: G()
|
|
2403
2403
|
}],
|
|
2404
2404
|
/**
|
|
2405
2405
|
* Rotate X
|
|
2406
2406
|
* @see https://tailwindcss.com/docs/rotate
|
|
2407
2407
|
*/
|
|
2408
2408
|
"rotate-x": [{
|
|
2409
|
-
"rotate-x":
|
|
2409
|
+
"rotate-x": G()
|
|
2410
2410
|
}],
|
|
2411
2411
|
/**
|
|
2412
2412
|
* Rotate Y
|
|
2413
2413
|
* @see https://tailwindcss.com/docs/rotate
|
|
2414
2414
|
*/
|
|
2415
2415
|
"rotate-y": [{
|
|
2416
|
-
"rotate-y":
|
|
2416
|
+
"rotate-y": G()
|
|
2417
2417
|
}],
|
|
2418
2418
|
/**
|
|
2419
2419
|
* Rotate Z
|
|
2420
2420
|
* @see https://tailwindcss.com/docs/rotate
|
|
2421
2421
|
*/
|
|
2422
2422
|
"rotate-z": [{
|
|
2423
|
-
"rotate-z":
|
|
2423
|
+
"rotate-z": G()
|
|
2424
2424
|
}],
|
|
2425
2425
|
/**
|
|
2426
2426
|
* Scale
|
|
2427
2427
|
* @see https://tailwindcss.com/docs/scale
|
|
2428
2428
|
*/
|
|
2429
2429
|
scale: [{
|
|
2430
|
-
scale:
|
|
2430
|
+
scale: K()
|
|
2431
2431
|
}],
|
|
2432
2432
|
/**
|
|
2433
2433
|
* Scale X
|
|
2434
2434
|
* @see https://tailwindcss.com/docs/scale
|
|
2435
2435
|
*/
|
|
2436
2436
|
"scale-x": [{
|
|
2437
|
-
"scale-x":
|
|
2437
|
+
"scale-x": K()
|
|
2438
2438
|
}],
|
|
2439
2439
|
/**
|
|
2440
2440
|
* Scale Y
|
|
2441
2441
|
* @see https://tailwindcss.com/docs/scale
|
|
2442
2442
|
*/
|
|
2443
2443
|
"scale-y": [{
|
|
2444
|
-
"scale-y":
|
|
2444
|
+
"scale-y": K()
|
|
2445
2445
|
}],
|
|
2446
2446
|
/**
|
|
2447
2447
|
* Scale Z
|
|
2448
2448
|
* @see https://tailwindcss.com/docs/scale
|
|
2449
2449
|
*/
|
|
2450
2450
|
"scale-z": [{
|
|
2451
|
-
"scale-z":
|
|
2451
|
+
"scale-z": K()
|
|
2452
2452
|
}],
|
|
2453
2453
|
/**
|
|
2454
2454
|
* Scale 3D
|
|
@@ -2805,7 +2805,7 @@ const Lm = (e) => {
|
|
|
2805
2805
|
* @see https://tailwindcss.com/docs/stroke-width
|
|
2806
2806
|
*/
|
|
2807
2807
|
"stroke-w": [{
|
|
2808
|
-
stroke: [W, Ct, Je,
|
|
2808
|
+
stroke: [W, Ct, Je, Nn]
|
|
2809
2809
|
}],
|
|
2810
2810
|
/**
|
|
2811
2811
|
* Stroke
|
|
@@ -2898,26 +2898,26 @@ function ee(...e) {
|
|
|
2898
2898
|
n(o);
|
|
2899
2899
|
return Mc(t.join(" "));
|
|
2900
2900
|
}
|
|
2901
|
-
const
|
|
2901
|
+
const kn = 768;
|
|
2902
2902
|
function Nc() {
|
|
2903
2903
|
const [e, t] = ge(void 0);
|
|
2904
2904
|
return Tt(() => {
|
|
2905
2905
|
if (typeof window > "u" || !window.matchMedia)
|
|
2906
2906
|
return;
|
|
2907
|
-
const n = window.matchMedia(`(max-width: ${
|
|
2908
|
-
t(window.innerWidth <
|
|
2907
|
+
const n = window.matchMedia(`(max-width: ${kn - 1}px)`), o = () => {
|
|
2908
|
+
t(window.innerWidth < kn);
|
|
2909
2909
|
};
|
|
2910
|
-
return n.addEventListener("change", o), t(window.innerWidth <
|
|
2910
|
+
return n.addEventListener("change", o), t(window.innerWidth < kn), () => n.removeEventListener("change", o);
|
|
2911
2911
|
}, []), !!e;
|
|
2912
2912
|
}
|
|
2913
|
-
const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null || e === void 0, _c = (e) => kc(e) ? String(e) : JSON.stringify(e, null, 2), Yt = "dt_prefilter", Xt = "dt_search", qt = "dt_page",
|
|
2913
|
+
const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null || e === void 0, _c = (e) => kc(e) ? String(e) : JSON.stringify(e, null, 2), Yt = "dt_prefilter", Xt = "dt_search", qt = "dt_page", Xn = "dt_pageSize", Zt = "dt_filters", St = "dt_sortBy", Et = "dt_sortDesc", Qe = (e) => {
|
|
2914
2914
|
if (typeof window > "u") return null;
|
|
2915
2915
|
try {
|
|
2916
2916
|
return new URL(window.location.href).searchParams.get(e);
|
|
2917
2917
|
} catch {
|
|
2918
2918
|
return null;
|
|
2919
2919
|
}
|
|
2920
|
-
},
|
|
2920
|
+
}, pe = (e, t) => {
|
|
2921
2921
|
if (typeof window > "u" || new URL(window.location.href).searchParams.get(e) === t) return;
|
|
2922
2922
|
const o = new URL(window.location.href);
|
|
2923
2923
|
t ? o.searchParams.set(e, t) : o.searchParams.delete(e), window.history.replaceState(window.history.state, "", o.toString());
|
|
@@ -2928,19 +2928,19 @@ const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "b
|
|
|
2928
2928
|
defaultSortBy: o,
|
|
2929
2929
|
defaultSortOrder: r = "asc"
|
|
2930
2930
|
}) => {
|
|
2931
|
-
const s =
|
|
2931
|
+
const s = Gn(e), i = Gn(n), [a, l] = ge(() => {
|
|
2932
2932
|
if (e) {
|
|
2933
2933
|
const C = Qe(Yt);
|
|
2934
2934
|
if (C) return C;
|
|
2935
2935
|
}
|
|
2936
2936
|
return t;
|
|
2937
2937
|
}), c = We((C) => {
|
|
2938
|
-
l(C), s.current &&
|
|
2938
|
+
l(C), s.current && pe(Yt, C ?? null);
|
|
2939
2939
|
}, []), [d, u] = ge(() => e ? Qe(Xt) ?? "" : ""), h = We((C) => {
|
|
2940
|
-
u(C), s.current &&
|
|
2940
|
+
u(C), s.current && pe(Xt, C || null);
|
|
2941
2941
|
}, []), [g, b] = ge(() => {
|
|
2942
2942
|
if (e) {
|
|
2943
|
-
const C = Qe(qt), M = Qe(
|
|
2943
|
+
const C = Qe(qt), M = Qe(Xn);
|
|
2944
2944
|
return {
|
|
2945
2945
|
pageIndex: C ? parseInt(C, 10) - 1 : 0,
|
|
2946
2946
|
pageSize: M ? parseInt(M, 10) : n
|
|
@@ -2950,14 +2950,14 @@ const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "b
|
|
|
2950
2950
|
}), m = We((C) => {
|
|
2951
2951
|
b((M) => {
|
|
2952
2952
|
const N = typeof C == "function" ? C(M) : C;
|
|
2953
|
-
return s.current && (M.pageIndex !== N.pageIndex || M.pageSize !== N.pageSize) && (
|
|
2954
|
-
|
|
2953
|
+
return s.current && (M.pageIndex !== N.pageIndex || M.pageSize !== N.pageSize) && (pe(qt, N.pageIndex > 0 ? String(N.pageIndex + 1) : null), pe(
|
|
2954
|
+
Xn,
|
|
2955
2955
|
N.pageSize !== i.current ? String(N.pageSize) : null
|
|
2956
2956
|
)), N;
|
|
2957
2957
|
});
|
|
2958
2958
|
}, []), [v, y] = ge(() => {
|
|
2959
2959
|
if (e) {
|
|
2960
|
-
const C = Qe(
|
|
2960
|
+
const C = Qe(Zt);
|
|
2961
2961
|
if (C)
|
|
2962
2962
|
return Oc(C);
|
|
2963
2963
|
}
|
|
@@ -2965,7 +2965,7 @@ const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "b
|
|
|
2965
2965
|
}), x = We((C) => {
|
|
2966
2966
|
if (y(C), s.current) {
|
|
2967
2967
|
const N = Object.keys(C).length > 0 ? jr(C) : null;
|
|
2968
|
-
|
|
2968
|
+
pe(Zt, N);
|
|
2969
2969
|
}
|
|
2970
2970
|
}, []), [w, S] = ge(() => {
|
|
2971
2971
|
if (e) {
|
|
@@ -2977,13 +2977,13 @@ const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "b
|
|
|
2977
2977
|
}), A = We((C) => {
|
|
2978
2978
|
S((M) => {
|
|
2979
2979
|
const N = typeof C == "function" ? C(M) : C;
|
|
2980
|
-
return s.current && (N.length > 0 ? (
|
|
2980
|
+
return s.current && (N.length > 0 ? (pe(St, N[0].id), pe(Et, String(N[0].desc))) : (pe(St, null), pe(Et, null))), N;
|
|
2981
2981
|
});
|
|
2982
2982
|
}, []), T = Pe(() => {
|
|
2983
2983
|
const C = o ? [{ id: o, desc: r === "desc" }] : [];
|
|
2984
2984
|
return d !== "" || a !== t || Object.keys(v).length > 0 || w.length !== C.length || w.length > 0 && C.length > 0 && (w[0].id !== C[0].id || w[0].desc !== C[0].desc);
|
|
2985
2985
|
}, [d, a, t, v, w, o, r]), R = We(() => {
|
|
2986
|
-
s.current && (
|
|
2986
|
+
s.current && (pe(Yt, null), pe(Xt, null), pe(qt, null), pe(Zt, null), pe(St, null), pe(Et, null)), l(t), u(""), b((C) => ({ pageIndex: 0, pageSize: C.pageSize })), y({}), S(o ? [{ id: o, desc: r === "desc" }] : []);
|
|
2987
2987
|
}, [t, o, r]);
|
|
2988
2988
|
return {
|
|
2989
2989
|
activePrefilter: a,
|
|
@@ -3021,11 +3021,11 @@ const kc = (e) => typeof e == "string" || typeof e == "number" || typeof e == "b
|
|
|
3021
3021
|
if (t) {
|
|
3022
3022
|
if (t.prefilter && n.searchParams.set(Yt, t.prefilter), t.search && n.searchParams.set(Xt, t.search), t.pagination) {
|
|
3023
3023
|
const { pageIndex: o, pageSize: r } = t.pagination;
|
|
3024
|
-
o > 0 && n.searchParams.set(qt, String(o + 1)), r && n.searchParams.set(
|
|
3024
|
+
o > 0 && n.searchParams.set(qt, String(o + 1)), r && n.searchParams.set(Xn, String(r));
|
|
3025
3025
|
}
|
|
3026
3026
|
if (t.filters && Object.keys(t.filters).length > 0) {
|
|
3027
3027
|
const o = jr(t.filters);
|
|
3028
|
-
n.searchParams.set(
|
|
3028
|
+
n.searchParams.set(Zt, o);
|
|
3029
3029
|
}
|
|
3030
3030
|
if (t.sorting && t.sorting.length > 0) {
|
|
3031
3031
|
const o = t.sorting[0];
|
|
@@ -3655,7 +3655,7 @@ const Hc = (e, t, n, o) => {
|
|
|
3655
3655
|
title: l,
|
|
3656
3656
|
...c
|
|
3657
3657
|
}, d) => {
|
|
3658
|
-
const u =
|
|
3658
|
+
const u = de();
|
|
3659
3659
|
return /* @__PURE__ */ p(
|
|
3660
3660
|
"button",
|
|
3661
3661
|
{
|
|
@@ -3694,7 +3694,7 @@ function Qo(e, t) {
|
|
|
3694
3694
|
return e(t);
|
|
3695
3695
|
e != null && (e.current = t);
|
|
3696
3696
|
}
|
|
3697
|
-
function
|
|
3697
|
+
function fn(...e) {
|
|
3698
3698
|
return (t) => {
|
|
3699
3699
|
let n = !1;
|
|
3700
3700
|
const o = e.map((r) => {
|
|
@@ -3711,7 +3711,7 @@ function pn(...e) {
|
|
|
3711
3711
|
};
|
|
3712
3712
|
}
|
|
3713
3713
|
function ne(...e) {
|
|
3714
|
-
return f.useCallback(
|
|
3714
|
+
return f.useCallback(fn(...e), e);
|
|
3715
3715
|
}
|
|
3716
3716
|
function rt(e, t = []) {
|
|
3717
3717
|
let n = [];
|
|
@@ -3763,8 +3763,8 @@ function Xc(...e) {
|
|
|
3763
3763
|
};
|
|
3764
3764
|
return n.scopeName = t.scopeName, n;
|
|
3765
3765
|
}
|
|
3766
|
-
var
|
|
3767
|
-
}, qc = f[" useInsertionEffect ".trim().toString()] ||
|
|
3766
|
+
var ue = globalThis != null && globalThis.document ? f.useLayoutEffect : () => {
|
|
3767
|
+
}, qc = f[" useInsertionEffect ".trim().toString()] || ue;
|
|
3768
3768
|
function It({
|
|
3769
3769
|
prop: e,
|
|
3770
3770
|
defaultProp: t,
|
|
@@ -3831,7 +3831,7 @@ function Qc(e) {
|
|
|
3831
3831
|
const { children: r, ...s } = n;
|
|
3832
3832
|
if (f.isValidElement(r)) {
|
|
3833
3833
|
const i = ol(r), a = nl(s, r.props);
|
|
3834
|
-
return r.type !== f.Fragment && (a.ref = o ?
|
|
3834
|
+
return r.type !== f.Fragment && (a.ref = o ? fn(o, i) : i), f.cloneElement(r, a);
|
|
3835
3835
|
}
|
|
3836
3836
|
return f.Children.count(r) > 1 ? f.Children.only(null) : null;
|
|
3837
3837
|
});
|
|
@@ -3883,7 +3883,7 @@ var rl = [
|
|
|
3883
3883
|
return o.displayName = `Primitive.${t}`, { ...e, [t]: o };
|
|
3884
3884
|
}, {});
|
|
3885
3885
|
function qr(e, t) {
|
|
3886
|
-
e &&
|
|
3886
|
+
e && dn.flushSync(() => e.dispatchEvent(t));
|
|
3887
3887
|
}
|
|
3888
3888
|
function uo(e) {
|
|
3889
3889
|
const t = e + "CollectionProvider", [n, o] = rt(t), [r, s] = n(
|
|
@@ -3926,7 +3926,7 @@ function uo(e) {
|
|
|
3926
3926
|
];
|
|
3927
3927
|
}
|
|
3928
3928
|
var sl = f.createContext(void 0);
|
|
3929
|
-
function
|
|
3929
|
+
function pn(e) {
|
|
3930
3930
|
const t = f.useContext(sl);
|
|
3931
3931
|
return e || t || "ltr";
|
|
3932
3932
|
}
|
|
@@ -4064,12 +4064,12 @@ function Jr(e, t, n, { discrete: o }) {
|
|
|
4064
4064
|
const r = n.originalEvent.target, s = new CustomEvent(e, { bubbles: !1, cancelable: !0, detail: n });
|
|
4065
4065
|
t && r.addEventListener(e, t, { once: !0 }), o ? qr(r, s) : r.dispatchEvent(s);
|
|
4066
4066
|
}
|
|
4067
|
-
var
|
|
4067
|
+
var _n = 0;
|
|
4068
4068
|
function Qr() {
|
|
4069
4069
|
f.useEffect(() => {
|
|
4070
4070
|
const e = document.querySelectorAll("[data-radix-focus-guard]");
|
|
4071
|
-
return document.body.insertAdjacentElement("afterbegin", e[0] ?? nr()), document.body.insertAdjacentElement("beforeend", e[1] ?? nr()),
|
|
4072
|
-
|
|
4071
|
+
return document.body.insertAdjacentElement("afterbegin", e[0] ?? nr()), document.body.insertAdjacentElement("beforeend", e[1] ?? nr()), _n++, () => {
|
|
4072
|
+
_n === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((t) => t.remove()), _n--;
|
|
4073
4073
|
};
|
|
4074
4074
|
}, []);
|
|
4075
4075
|
}
|
|
@@ -4077,7 +4077,7 @@ function nr() {
|
|
|
4077
4077
|
const e = document.createElement("span");
|
|
4078
4078
|
return e.setAttribute("data-radix-focus-guard", ""), e.tabIndex = 0, e.style.outline = "none", e.style.opacity = "0", e.style.position = "fixed", e.style.pointerEvents = "none", e;
|
|
4079
4079
|
}
|
|
4080
|
-
var
|
|
4080
|
+
var On = "focusScope.autoFocusOnMount", Dn = "focusScope.autoFocusOnUnmount", or = { bubbles: !1, cancelable: !0 }, ml = "FocusScope", po = f.forwardRef((e, t) => {
|
|
4081
4081
|
const {
|
|
4082
4082
|
loop: n = !1,
|
|
4083
4083
|
trapped: o = !1,
|
|
@@ -4119,13 +4119,13 @@ var Dn = "focusScope.autoFocusOnMount", Ln = "focusScope.autoFocusOnUnmount", or
|
|
|
4119
4119
|
sr.add(g);
|
|
4120
4120
|
const m = document.activeElement;
|
|
4121
4121
|
if (!a.contains(m)) {
|
|
4122
|
-
const y = new CustomEvent(
|
|
4123
|
-
a.addEventListener(
|
|
4122
|
+
const y = new CustomEvent(On, or);
|
|
4123
|
+
a.addEventListener(On, c), a.dispatchEvent(y), y.defaultPrevented || (hl(yl(es(a)), { select: !0 }), document.activeElement === m && ze(a));
|
|
4124
4124
|
}
|
|
4125
4125
|
return () => {
|
|
4126
|
-
a.removeEventListener(
|
|
4127
|
-
const y = new CustomEvent(
|
|
4128
|
-
a.addEventListener(
|
|
4126
|
+
a.removeEventListener(On, c), setTimeout(() => {
|
|
4127
|
+
const y = new CustomEvent(Dn, or);
|
|
4128
|
+
a.addEventListener(Dn, d), a.dispatchEvent(y), y.defaultPrevented || ze(m ?? document.body, { select: !0 }), a.removeEventListener(Dn, d), sr.remove(g);
|
|
4129
4129
|
}, 0);
|
|
4130
4130
|
};
|
|
4131
4131
|
}
|
|
@@ -4210,11 +4210,11 @@ var xl = f[" useId ".trim().toString()] || (() => {
|
|
|
4210
4210
|
}), Cl = 0;
|
|
4211
4211
|
function et(e) {
|
|
4212
4212
|
const [t, n] = f.useState(xl());
|
|
4213
|
-
return
|
|
4213
|
+
return ue(() => {
|
|
4214
4214
|
n((o) => o ?? String(Cl++));
|
|
4215
4215
|
}, [e]), e || (t ? `radix-${t}` : "");
|
|
4216
4216
|
}
|
|
4217
|
-
const Sl = ["top", "right", "bottom", "left"], He = Math.min, be = Math.max,
|
|
4217
|
+
const Sl = ["top", "right", "bottom", "left"], He = Math.min, be = Math.max, nn = Math.round, zt = Math.floor, ke = (e) => ({
|
|
4218
4218
|
x: e,
|
|
4219
4219
|
y: e
|
|
4220
4220
|
}), El = {
|
|
@@ -4255,10 +4255,10 @@ function Tl(e, t, n) {
|
|
|
4255
4255
|
n === void 0 && (n = !1);
|
|
4256
4256
|
const o = bt(e), r = go(e), s = ho(r);
|
|
4257
4257
|
let i = r === "x" ? o === (n ? "end" : "start") ? "right" : "left" : o === "start" ? "bottom" : "top";
|
|
4258
|
-
return t.reference[s] > t.floating[s] && (i =
|
|
4258
|
+
return t.reference[s] > t.floating[s] && (i = on(i)), [i, on(i)];
|
|
4259
4259
|
}
|
|
4260
4260
|
function Il(e) {
|
|
4261
|
-
const t =
|
|
4261
|
+
const t = on(e);
|
|
4262
4262
|
return [Jn(e), t, Jn(t)];
|
|
4263
4263
|
}
|
|
4264
4264
|
function Jn(e) {
|
|
@@ -4282,7 +4282,7 @@ function kl(e, t, n, o) {
|
|
|
4282
4282
|
let s = Nl(Ve(e), n === "start", o);
|
|
4283
4283
|
return r && (s = s.map((i) => i + "-" + r), t && (s = s.concat(s.map(Jn)))), s;
|
|
4284
4284
|
}
|
|
4285
|
-
function
|
|
4285
|
+
function on(e) {
|
|
4286
4286
|
return e.replace(/left|right|bottom|top/g, (t) => El[t]);
|
|
4287
4287
|
}
|
|
4288
4288
|
function _l(e) {
|
|
@@ -4302,7 +4302,7 @@ function ts(e) {
|
|
|
4302
4302
|
left: e
|
|
4303
4303
|
};
|
|
4304
4304
|
}
|
|
4305
|
-
function
|
|
4305
|
+
function rn(e) {
|
|
4306
4306
|
const {
|
|
4307
4307
|
x: t,
|
|
4308
4308
|
y: n,
|
|
@@ -4445,7 +4445,7 @@ async function Mt(e, t) {
|
|
|
4445
4445
|
elementContext: u = "floating",
|
|
4446
4446
|
altBoundary: h = !1,
|
|
4447
4447
|
padding: g = 0
|
|
4448
|
-
} = $e(t, e), b = ts(g), v = a[h ? u === "floating" ? "reference" : "floating" : u], y =
|
|
4448
|
+
} = $e(t, e), b = ts(g), v = a[h ? u === "floating" ? "reference" : "floating" : u], y = rn(await s.getClippingRect({
|
|
4449
4449
|
element: (n = await (s.isElement == null ? void 0 : s.isElement(v))) == null || n ? v : v.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(a.floating)),
|
|
4450
4450
|
boundary: c,
|
|
4451
4451
|
rootBoundary: d,
|
|
@@ -4461,7 +4461,7 @@ async function Mt(e, t) {
|
|
|
4461
4461
|
} : {
|
|
4462
4462
|
x: 1,
|
|
4463
4463
|
y: 1
|
|
4464
|
-
}, A =
|
|
4464
|
+
}, A = rn(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
4465
4465
|
elements: a,
|
|
4466
4466
|
rect: x,
|
|
4467
4467
|
offsetParent: w,
|
|
@@ -4498,12 +4498,12 @@ const Dl = (e) => ({
|
|
|
4498
4498
|
}, g = go(r), b = ho(g), m = await i.getDimensions(c), v = g === "y", y = v ? "top" : "left", x = v ? "bottom" : "right", w = v ? "clientHeight" : "clientWidth", S = s.reference[b] + s.reference[g] - h[g] - s.floating[b], A = h[g] - s.reference[g], T = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(c));
|
|
4499
4499
|
let R = T ? T[w] : 0;
|
|
4500
4500
|
(!R || !await (i.isElement == null ? void 0 : i.isElement(T))) && (R = a.floating[w] || s.floating[b]);
|
|
4501
|
-
const C = S / 2 - A / 2, M = R / 2 - m[b] / 2 - 1, N = He(u[y], M),
|
|
4501
|
+
const C = S / 2 - A / 2, M = R / 2 - m[b] / 2 - 1, N = He(u[y], M), F = He(u[x], M), V = N, U = R - m[b] - F, $ = R / 2 - m[b] / 2 + C, H = Zn(V, $, U), O = !l.arrow && bt(r) != null && $ !== H && s.reference[b] / 2 - ($ < V ? N : F) - m[b] / 2 < 0, D = O ? $ < V ? $ - V : $ - U : 0;
|
|
4502
4502
|
return {
|
|
4503
4503
|
[g]: h[g] + D,
|
|
4504
4504
|
data: {
|
|
4505
|
-
[g]:
|
|
4506
|
-
centerOffset:
|
|
4505
|
+
[g]: H,
|
|
4506
|
+
centerOffset: $ - H - D,
|
|
4507
4507
|
...O && {
|
|
4508
4508
|
alignmentOffset: D
|
|
4509
4509
|
}
|
|
@@ -4535,38 +4535,38 @@ const Dl = (e) => ({
|
|
|
4535
4535
|
} = $e(e, t);
|
|
4536
4536
|
if ((n = s.arrow) != null && n.alignmentOffset)
|
|
4537
4537
|
return {};
|
|
4538
|
-
const y = Ve(r), x = Ne(a), w = Ve(a) === a, S = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), A = h || (w || !m ? [
|
|
4538
|
+
const y = Ve(r), x = Ne(a), w = Ve(a) === a, S = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), A = h || (w || !m ? [on(a)] : Il(a)), T = b !== "none";
|
|
4539
4539
|
!h && T && A.push(...kl(a, m, b, S));
|
|
4540
4540
|
const R = [a, ...A], C = await Mt(t, v), M = [];
|
|
4541
4541
|
let N = ((o = s.flip) == null ? void 0 : o.overflows) || [];
|
|
4542
4542
|
if (d && M.push(C[y]), u) {
|
|
4543
|
-
const
|
|
4544
|
-
M.push(C[
|
|
4543
|
+
const $ = Tl(r, i, S);
|
|
4544
|
+
M.push(C[$[0]], C[$[1]]);
|
|
4545
4545
|
}
|
|
4546
4546
|
if (N = [...N, {
|
|
4547
4547
|
placement: r,
|
|
4548
4548
|
overflows: M
|
|
4549
|
-
}], !M.every((
|
|
4550
|
-
var
|
|
4551
|
-
const
|
|
4552
|
-
if (
|
|
4549
|
+
}], !M.every(($) => $ <= 0)) {
|
|
4550
|
+
var F, V;
|
|
4551
|
+
const $ = (((F = s.flip) == null ? void 0 : F.index) || 0) + 1, H = R[$];
|
|
4552
|
+
if (H && (!(u === "alignment" ? x !== Ne(H) : !1) || // We leave the current main axis only if every placement on that axis
|
|
4553
4553
|
// overflows the main axis.
|
|
4554
4554
|
N.every((E) => Ne(E.placement) === x ? E.overflows[0] > 0 : !0)))
|
|
4555
4555
|
return {
|
|
4556
4556
|
data: {
|
|
4557
|
-
index:
|
|
4557
|
+
index: $,
|
|
4558
4558
|
overflows: N
|
|
4559
4559
|
},
|
|
4560
4560
|
reset: {
|
|
4561
|
-
placement:
|
|
4561
|
+
placement: H
|
|
4562
4562
|
}
|
|
4563
4563
|
};
|
|
4564
|
-
let O = (
|
|
4564
|
+
let O = (V = N.filter((D) => D.overflows[0] <= 0).sort((D, E) => D.overflows[1] - E.overflows[1])[0]) == null ? void 0 : V.placement;
|
|
4565
4565
|
if (!O)
|
|
4566
4566
|
switch (g) {
|
|
4567
4567
|
case "bestFit": {
|
|
4568
|
-
var
|
|
4569
|
-
const D = (
|
|
4568
|
+
var U;
|
|
4569
|
+
const D = (U = N.filter((E) => {
|
|
4570
4570
|
if (T) {
|
|
4571
4571
|
const P = Ne(E.placement);
|
|
4572
4572
|
return P === x || // Create a bias to the `y` side axis due to horizontal
|
|
@@ -4574,7 +4574,7 @@ const Dl = (e) => ({
|
|
|
4574
4574
|
P === "y";
|
|
4575
4575
|
}
|
|
4576
4576
|
return !0;
|
|
4577
|
-
}).map((E) => [E.placement, E.overflows.filter((P) => P > 0).reduce((P, q) => P + q, 0)]).sort((E, P) => E[1] - P[1])[0]) == null ? void 0 :
|
|
4577
|
+
}).map((E) => [E.placement, E.overflows.filter((P) => P > 0).reduce((P, q) => P + q, 0)]).sort((E, P) => E[1] - P[1])[0]) == null ? void 0 : U[0];
|
|
4578
4578
|
D && (O = D);
|
|
4579
4579
|
break;
|
|
4580
4580
|
}
|
|
@@ -4817,8 +4817,8 @@ const Vl = function(e) {
|
|
|
4817
4817
|
const x = m - d.top - d.bottom, w = b - d.left - d.right, S = He(m - d[v], x), A = He(b - d[y], w), T = !t.middlewareData.shift;
|
|
4818
4818
|
let R = S, C = A;
|
|
4819
4819
|
if ((n = t.middlewareData.shift) != null && n.enabled.x && (C = w), (o = t.middlewareData.shift) != null && o.enabled.y && (R = x), T && !h) {
|
|
4820
|
-
const N = be(d.left, 0),
|
|
4821
|
-
g ? C = b - 2 * (N !== 0 ||
|
|
4820
|
+
const N = be(d.left, 0), F = be(d.right, 0), V = be(d.top, 0), U = be(d.bottom, 0);
|
|
4821
|
+
g ? C = b - 2 * (N !== 0 || F !== 0 ? N + F : be(d.left, d.right)) : R = m - 2 * (V !== 0 || U !== 0 ? V + U : be(d.top, d.bottom));
|
|
4822
4822
|
}
|
|
4823
4823
|
await l({
|
|
4824
4824
|
...t,
|
|
@@ -4834,7 +4834,7 @@ const Vl = function(e) {
|
|
|
4834
4834
|
}
|
|
4835
4835
|
};
|
|
4836
4836
|
};
|
|
4837
|
-
function
|
|
4837
|
+
function mn() {
|
|
4838
4838
|
return typeof window < "u";
|
|
4839
4839
|
}
|
|
4840
4840
|
function wt(e) {
|
|
@@ -4849,16 +4849,16 @@ function De(e) {
|
|
|
4849
4849
|
return (t = (os(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
|
|
4850
4850
|
}
|
|
4851
4851
|
function os(e) {
|
|
4852
|
-
return
|
|
4852
|
+
return mn() ? e instanceof Node || e instanceof we(e).Node : !1;
|
|
4853
4853
|
}
|
|
4854
4854
|
function Re(e) {
|
|
4855
|
-
return
|
|
4855
|
+
return mn() ? e instanceof Element || e instanceof we(e).Element : !1;
|
|
4856
4856
|
}
|
|
4857
4857
|
function Oe(e) {
|
|
4858
|
-
return
|
|
4858
|
+
return mn() ? e instanceof HTMLElement || e instanceof we(e).HTMLElement : !1;
|
|
4859
4859
|
}
|
|
4860
4860
|
function fr(e) {
|
|
4861
|
-
return !
|
|
4861
|
+
return !mn() || typeof ShadowRoot > "u" ? !1 : e instanceof ShadowRoot || e instanceof we(e).ShadowRoot;
|
|
4862
4862
|
}
|
|
4863
4863
|
const Wl = /* @__PURE__ */ new Set(["inline", "contents"]);
|
|
4864
4864
|
function Ot(e) {
|
|
@@ -4875,7 +4875,7 @@ function Gl(e) {
|
|
|
4875
4875
|
return Hl.has(wt(e));
|
|
4876
4876
|
}
|
|
4877
4877
|
const Kl = [":popover-open", ":modal"];
|
|
4878
|
-
function
|
|
4878
|
+
function hn(e) {
|
|
4879
4879
|
return Kl.some((t) => {
|
|
4880
4880
|
try {
|
|
4881
4881
|
return e.matches(t);
|
|
@@ -4894,7 +4894,7 @@ function ql(e) {
|
|
|
4894
4894
|
for (; Oe(t) && !mt(t); ) {
|
|
4895
4895
|
if (vo(t))
|
|
4896
4896
|
return t;
|
|
4897
|
-
if (
|
|
4897
|
+
if (hn(t))
|
|
4898
4898
|
return null;
|
|
4899
4899
|
t = Ge(t);
|
|
4900
4900
|
}
|
|
@@ -4910,7 +4910,7 @@ function mt(e) {
|
|
|
4910
4910
|
function Ae(e) {
|
|
4911
4911
|
return we(e).getComputedStyle(e);
|
|
4912
4912
|
}
|
|
4913
|
-
function
|
|
4913
|
+
function gn(e) {
|
|
4914
4914
|
return Re(e) ? {
|
|
4915
4915
|
scrollLeft: e.scrollLeft,
|
|
4916
4916
|
scrollTop: e.scrollTop
|
|
@@ -4951,7 +4951,7 @@ function Qn(e) {
|
|
|
4951
4951
|
function ss(e) {
|
|
4952
4952
|
const t = Ae(e);
|
|
4953
4953
|
let n = parseFloat(t.width) || 0, o = parseFloat(t.height) || 0;
|
|
4954
|
-
const r = Oe(e), s = r ? e.offsetWidth : n, i = r ? e.offsetHeight : o, a =
|
|
4954
|
+
const r = Oe(e), s = r ? e.offsetWidth : n, i = r ? e.offsetHeight : o, a = nn(n) !== s || nn(o) !== i;
|
|
4955
4955
|
return a && (n = s, o = i), {
|
|
4956
4956
|
width: n,
|
|
4957
4957
|
height: o,
|
|
@@ -4970,7 +4970,7 @@ function ft(e) {
|
|
|
4970
4970
|
height: r,
|
|
4971
4971
|
$: s
|
|
4972
4972
|
} = ss(t);
|
|
4973
|
-
let i = (s ?
|
|
4973
|
+
let i = (s ? nn(n.width) : n.width) / o, a = (s ? nn(n.height) : n.height) / r;
|
|
4974
4974
|
return (!i || !Number.isFinite(i)) && (i = 1), (!a || !Number.isFinite(a)) && (a = 1), {
|
|
4975
4975
|
x: i,
|
|
4976
4976
|
y: a
|
|
@@ -5002,19 +5002,19 @@ function tt(e, t, n, o) {
|
|
|
5002
5002
|
l *= v.x, c *= v.y, d *= v.x, u *= v.y, l += w, c += S, b = we(m), m = Qn(b);
|
|
5003
5003
|
}
|
|
5004
5004
|
}
|
|
5005
|
-
return
|
|
5005
|
+
return rn({
|
|
5006
5006
|
width: d,
|
|
5007
5007
|
height: u,
|
|
5008
5008
|
x: l,
|
|
5009
5009
|
y: c
|
|
5010
5010
|
});
|
|
5011
5011
|
}
|
|
5012
|
-
function
|
|
5013
|
-
const n =
|
|
5012
|
+
function vn(e, t) {
|
|
5013
|
+
const n = gn(e).scrollLeft;
|
|
5014
5014
|
return t ? t.left + n : tt(De(e)).left + n;
|
|
5015
5015
|
}
|
|
5016
5016
|
function as(e, t) {
|
|
5017
|
-
const n = e.getBoundingClientRect(), o = n.left + t.scrollLeft -
|
|
5017
|
+
const n = e.getBoundingClientRect(), o = n.left + t.scrollLeft - vn(e, n), r = n.top + t.scrollTop;
|
|
5018
5018
|
return {
|
|
5019
5019
|
x: o,
|
|
5020
5020
|
y: r
|
|
@@ -5027,7 +5027,7 @@ function eu(e) {
|
|
|
5027
5027
|
offsetParent: o,
|
|
5028
5028
|
strategy: r
|
|
5029
5029
|
} = e;
|
|
5030
|
-
const s = r === "fixed", i = De(o), a = t ?
|
|
5030
|
+
const s = r === "fixed", i = De(o), a = t ? hn(t.floating) : !1;
|
|
5031
5031
|
if (o === i || a && s)
|
|
5032
5032
|
return n;
|
|
5033
5033
|
let l = {
|
|
@@ -5035,7 +5035,7 @@ function eu(e) {
|
|
|
5035
5035
|
scrollTop: 0
|
|
5036
5036
|
}, c = ke(1);
|
|
5037
5037
|
const d = ke(0), u = Oe(o);
|
|
5038
|
-
if ((u || !u && !s) && ((wt(o) !== "body" || Ot(i)) && (l =
|
|
5038
|
+
if ((u || !u && !s) && ((wt(o) !== "body" || Ot(i)) && (l = gn(o)), Oe(o))) {
|
|
5039
5039
|
const g = tt(o);
|
|
5040
5040
|
c = ft(o), d.x = g.x + o.clientLeft, d.y = g.y + o.clientTop;
|
|
5041
5041
|
}
|
|
@@ -5051,8 +5051,8 @@ function tu(e) {
|
|
|
5051
5051
|
return Array.from(e.getClientRects());
|
|
5052
5052
|
}
|
|
5053
5053
|
function nu(e) {
|
|
5054
|
-
const t = De(e), n =
|
|
5055
|
-
let i = -n.scrollLeft +
|
|
5054
|
+
const t = De(e), n = gn(e), o = e.ownerDocument.body, r = be(t.scrollWidth, t.clientWidth, o.scrollWidth, o.clientWidth), s = be(t.scrollHeight, t.clientHeight, o.scrollHeight, o.clientHeight);
|
|
5055
|
+
let i = -n.scrollLeft + vn(e);
|
|
5056
5056
|
const a = -n.scrollTop;
|
|
5057
5057
|
return Ae(o).direction === "rtl" && (i += be(t.clientWidth, o.clientWidth) - r), {
|
|
5058
5058
|
width: r,
|
|
@@ -5070,7 +5070,7 @@ function ou(e, t) {
|
|
|
5070
5070
|
const d = bo();
|
|
5071
5071
|
(!d || d && t === "fixed") && (a = r.offsetLeft, l = r.offsetTop);
|
|
5072
5072
|
}
|
|
5073
|
-
const c =
|
|
5073
|
+
const c = vn(o);
|
|
5074
5074
|
if (c <= 0) {
|
|
5075
5075
|
const d = o.ownerDocument, u = d.body, h = getComputedStyle(u), g = d.compatMode === "CSS1Compat" && parseFloat(h.marginLeft) + parseFloat(h.marginRight) || 0, b = Math.abs(o.clientWidth - u.clientWidth - g);
|
|
5076
5076
|
b <= pr && (s -= b);
|
|
@@ -5109,7 +5109,7 @@ function mr(e, t, n) {
|
|
|
5109
5109
|
height: t.height
|
|
5110
5110
|
};
|
|
5111
5111
|
}
|
|
5112
|
-
return
|
|
5112
|
+
return rn(o);
|
|
5113
5113
|
}
|
|
5114
5114
|
function cs(e, t) {
|
|
5115
5115
|
const n = Ge(e);
|
|
@@ -5135,7 +5135,7 @@ function au(e) {
|
|
|
5135
5135
|
rootBoundary: o,
|
|
5136
5136
|
strategy: r
|
|
5137
5137
|
} = e;
|
|
5138
|
-
const i = [...n === "clippingAncestors" ?
|
|
5138
|
+
const i = [...n === "clippingAncestors" ? hn(t) ? [] : iu(t, this._c) : [].concat(n), o], a = i[0], l = i.reduce((c, d) => {
|
|
5139
5139
|
const u = mr(t, d, r);
|
|
5140
5140
|
return c.top = be(u.top, c.top), c.right = He(u.right, c.right), c.bottom = He(u.bottom, c.bottom), c.left = be(u.left, c.left), c;
|
|
5141
5141
|
}, mr(t, a, r));
|
|
@@ -5164,10 +5164,10 @@ function lu(e, t, n) {
|
|
|
5164
5164
|
};
|
|
5165
5165
|
const l = ke(0);
|
|
5166
5166
|
function c() {
|
|
5167
|
-
l.x =
|
|
5167
|
+
l.x = vn(r);
|
|
5168
5168
|
}
|
|
5169
5169
|
if (o || !o && !s)
|
|
5170
|
-
if ((wt(t) !== "body" || Ot(r)) && (a =
|
|
5170
|
+
if ((wt(t) !== "body" || Ot(r)) && (a = gn(t)), o) {
|
|
5171
5171
|
const g = tt(t, !0, s, t);
|
|
5172
5172
|
l.x = g.x + t.clientLeft, l.y = g.y + t.clientTop;
|
|
5173
5173
|
} else r && c();
|
|
@@ -5180,7 +5180,7 @@ function lu(e, t, n) {
|
|
|
5180
5180
|
height: i.height
|
|
5181
5181
|
};
|
|
5182
5182
|
}
|
|
5183
|
-
function
|
|
5183
|
+
function Ln(e) {
|
|
5184
5184
|
return Ae(e).position === "static";
|
|
5185
5185
|
}
|
|
5186
5186
|
function hr(e, t) {
|
|
@@ -5193,21 +5193,21 @@ function hr(e, t) {
|
|
|
5193
5193
|
}
|
|
5194
5194
|
function ls(e, t) {
|
|
5195
5195
|
const n = we(e);
|
|
5196
|
-
if (
|
|
5196
|
+
if (hn(e))
|
|
5197
5197
|
return n;
|
|
5198
5198
|
if (!Oe(e)) {
|
|
5199
5199
|
let r = Ge(e);
|
|
5200
5200
|
for (; r && !mt(r); ) {
|
|
5201
|
-
if (Re(r) && !
|
|
5201
|
+
if (Re(r) && !Ln(r))
|
|
5202
5202
|
return r;
|
|
5203
5203
|
r = Ge(r);
|
|
5204
5204
|
}
|
|
5205
5205
|
return n;
|
|
5206
5206
|
}
|
|
5207
5207
|
let o = hr(e, t);
|
|
5208
|
-
for (; o && Gl(o) &&
|
|
5208
|
+
for (; o && Gl(o) && Ln(o); )
|
|
5209
5209
|
o = hr(o, t);
|
|
5210
|
-
return o && mt(o) &&
|
|
5210
|
+
return o && mt(o) && Ln(o) && !vo(o) ? n : o || ql(e) || n;
|
|
5211
5211
|
}
|
|
5212
5212
|
const uu = async function(e) {
|
|
5213
5213
|
const t = this.getOffsetParent || ls, n = this.getDimensions, o = await n(e.floating);
|
|
@@ -5335,8 +5335,8 @@ const hu = Vl, gu = Ul, vu = Ll, bu = zl, wu = Fl, gr = Dl, yu = Bl, xu = (e, t,
|
|
|
5335
5335
|
});
|
|
5336
5336
|
};
|
|
5337
5337
|
var Cu = typeof document < "u", Su = function() {
|
|
5338
|
-
},
|
|
5339
|
-
function
|
|
5338
|
+
}, Jt = Cu ? pa : Su;
|
|
5339
|
+
function sn(e, t) {
|
|
5340
5340
|
if (e === t)
|
|
5341
5341
|
return !0;
|
|
5342
5342
|
if (typeof e != typeof t)
|
|
@@ -5348,7 +5348,7 @@ function an(e, t) {
|
|
|
5348
5348
|
if (Array.isArray(e)) {
|
|
5349
5349
|
if (n = e.length, n !== t.length) return !1;
|
|
5350
5350
|
for (o = n; o-- !== 0; )
|
|
5351
|
-
if (!
|
|
5351
|
+
if (!sn(e[o], t[o]))
|
|
5352
5352
|
return !1;
|
|
5353
5353
|
return !0;
|
|
5354
5354
|
}
|
|
@@ -5359,7 +5359,7 @@ function an(e, t) {
|
|
|
5359
5359
|
return !1;
|
|
5360
5360
|
for (o = n; o-- !== 0; ) {
|
|
5361
5361
|
const s = r[o];
|
|
5362
|
-
if (!(s === "_owner" && e.$$typeof) && !
|
|
5362
|
+
if (!(s === "_owner" && e.$$typeof) && !sn(e[s], t[s]))
|
|
5363
5363
|
return !1;
|
|
5364
5364
|
}
|
|
5365
5365
|
return !0;
|
|
@@ -5373,9 +5373,9 @@ function vr(e, t) {
|
|
|
5373
5373
|
const n = ds(e);
|
|
5374
5374
|
return Math.round(t * n) / n;
|
|
5375
5375
|
}
|
|
5376
|
-
function
|
|
5376
|
+
function Fn(e) {
|
|
5377
5377
|
const t = f.useRef(e);
|
|
5378
|
-
return
|
|
5378
|
+
return Jt(() => {
|
|
5379
5379
|
t.current = e;
|
|
5380
5380
|
}), t;
|
|
5381
5381
|
}
|
|
@@ -5401,12 +5401,12 @@ function Eu(e) {
|
|
|
5401
5401
|
middlewareData: {},
|
|
5402
5402
|
isPositioned: !1
|
|
5403
5403
|
}), [h, g] = f.useState(o);
|
|
5404
|
-
|
|
5404
|
+
sn(h, o) || g(o);
|
|
5405
5405
|
const [b, m] = f.useState(null), [v, y] = f.useState(null), x = f.useCallback((E) => {
|
|
5406
5406
|
E !== T.current && (T.current = E, m(E));
|
|
5407
5407
|
}, []), w = f.useCallback((E) => {
|
|
5408
5408
|
E !== R.current && (R.current = E, y(E));
|
|
5409
|
-
}, []), S = s || b, A = i || v, T = f.useRef(null), R = f.useRef(null), C = f.useRef(d), M = l != null, N =
|
|
5409
|
+
}, []), S = s || b, A = i || v, T = f.useRef(null), R = f.useRef(null), C = f.useRef(d), M = l != null, N = Fn(l), F = Fn(r), V = Fn(c), U = f.useCallback(() => {
|
|
5410
5410
|
if (!T.current || !R.current)
|
|
5411
5411
|
return;
|
|
5412
5412
|
const E = {
|
|
@@ -5414,37 +5414,37 @@ function Eu(e) {
|
|
|
5414
5414
|
strategy: n,
|
|
5415
5415
|
middleware: h
|
|
5416
5416
|
};
|
|
5417
|
-
|
|
5417
|
+
F.current && (E.platform = F.current), xu(T.current, R.current, E).then((P) => {
|
|
5418
5418
|
const q = {
|
|
5419
5419
|
...P,
|
|
5420
5420
|
// The floating element's position may be recomputed while it's closed
|
|
5421
5421
|
// but still mounted (such as when transitioning out). To ensure
|
|
5422
5422
|
// `isPositioned` will be `false` initially on the next open, avoid
|
|
5423
5423
|
// setting it to `true` when `open === false` (must be specified).
|
|
5424
|
-
isPositioned:
|
|
5424
|
+
isPositioned: V.current !== !1
|
|
5425
5425
|
};
|
|
5426
|
-
|
|
5426
|
+
$.current && !sn(C.current, q) && (C.current = q, dn.flushSync(() => {
|
|
5427
5427
|
u(q);
|
|
5428
5428
|
}));
|
|
5429
5429
|
});
|
|
5430
|
-
}, [h, t, n,
|
|
5431
|
-
|
|
5430
|
+
}, [h, t, n, F, V]);
|
|
5431
|
+
Jt(() => {
|
|
5432
5432
|
c === !1 && C.current.isPositioned && (C.current.isPositioned = !1, u((E) => ({
|
|
5433
5433
|
...E,
|
|
5434
5434
|
isPositioned: !1
|
|
5435
5435
|
})));
|
|
5436
5436
|
}, [c]);
|
|
5437
|
-
const
|
|
5438
|
-
|
|
5439
|
-
|
|
5440
|
-
}), []),
|
|
5437
|
+
const $ = f.useRef(!1);
|
|
5438
|
+
Jt(() => ($.current = !0, () => {
|
|
5439
|
+
$.current = !1;
|
|
5440
|
+
}), []), Jt(() => {
|
|
5441
5441
|
if (S && (T.current = S), A && (R.current = A), S && A) {
|
|
5442
5442
|
if (N.current)
|
|
5443
|
-
return N.current(S, A,
|
|
5444
|
-
|
|
5443
|
+
return N.current(S, A, U);
|
|
5444
|
+
U();
|
|
5445
5445
|
}
|
|
5446
|
-
}, [S, A,
|
|
5447
|
-
const
|
|
5446
|
+
}, [S, A, U, N, M]);
|
|
5447
|
+
const H = f.useMemo(() => ({
|
|
5448
5448
|
reference: T,
|
|
5449
5449
|
floating: R,
|
|
5450
5450
|
setReference: x,
|
|
@@ -5475,11 +5475,11 @@ function Eu(e) {
|
|
|
5475
5475
|
}, [n, a, O.floating, d.x, d.y]);
|
|
5476
5476
|
return f.useMemo(() => ({
|
|
5477
5477
|
...d,
|
|
5478
|
-
update:
|
|
5479
|
-
refs:
|
|
5478
|
+
update: U,
|
|
5479
|
+
refs: H,
|
|
5480
5480
|
elements: O,
|
|
5481
5481
|
floatingStyles: D
|
|
5482
|
-
}), [d,
|
|
5482
|
+
}), [d, U, H, O, D]);
|
|
5483
5483
|
}
|
|
5484
5484
|
const Ru = (e) => {
|
|
5485
5485
|
function t(n) {
|
|
@@ -5543,7 +5543,7 @@ fs.displayName = _u;
|
|
|
5543
5543
|
var Ou = fs;
|
|
5544
5544
|
function Du(e) {
|
|
5545
5545
|
const [t, n] = f.useState(void 0);
|
|
5546
|
-
return
|
|
5546
|
+
return ue(() => {
|
|
5547
5547
|
if (e) {
|
|
5548
5548
|
n({ width: e.offsetWidth, height: e.offsetHeight });
|
|
5549
5549
|
const o = new ResizeObserver((r) => {
|
|
@@ -5563,7 +5563,7 @@ function Du(e) {
|
|
|
5563
5563
|
n(void 0);
|
|
5564
5564
|
}, [e]), t;
|
|
5565
5565
|
}
|
|
5566
|
-
var yo = "Popper", [ps,
|
|
5566
|
+
var yo = "Popper", [ps, bn] = rt(yo), [Lu, ms] = ps(yo), hs = (e) => {
|
|
5567
5567
|
const { __scopePopper: t, children: n } = e, [o, r] = f.useState(null);
|
|
5568
5568
|
return /* @__PURE__ */ p(Lu, { scope: t, anchor: o, onAnchorChange: r, children: n });
|
|
5569
5569
|
};
|
|
@@ -5580,7 +5580,7 @@ var gs = "PopperAnchor", vs = f.forwardRef(
|
|
|
5580
5580
|
vs.displayName = gs;
|
|
5581
5581
|
var xo = "PopperContent", [Fu, $u] = ps(xo), bs = f.forwardRef(
|
|
5582
5582
|
(e, t) => {
|
|
5583
|
-
var I, j,
|
|
5583
|
+
var I, j, G, K, Y, z;
|
|
5584
5584
|
const {
|
|
5585
5585
|
__scopePopper: n,
|
|
5586
5586
|
side: o = "bottom",
|
|
@@ -5596,16 +5596,16 @@ var xo = "PopperContent", [Fu, $u] = ps(xo), bs = f.forwardRef(
|
|
|
5596
5596
|
updatePositionStrategy: g = "optimized",
|
|
5597
5597
|
onPlaced: b,
|
|
5598
5598
|
...m
|
|
5599
|
-
} = e, v = ms(xo, n), [y, x] = f.useState(null), w = ne(t, (
|
|
5599
|
+
} = e, v = ms(xo, n), [y, x] = f.useState(null), w = ne(t, (fe) => x(fe)), [S, A] = f.useState(null), T = Du(S), R = (T == null ? void 0 : T.width) ?? 0, C = (T == null ? void 0 : T.height) ?? 0, M = o + (s !== "center" ? "-" + s : ""), N = typeof d == "number" ? d : { top: 0, right: 0, bottom: 0, left: 0, ...d }, F = Array.isArray(c) ? c : [c], V = F.length > 0, U = {
|
|
5600
5600
|
padding: N,
|
|
5601
|
-
boundary:
|
|
5601
|
+
boundary: F.filter(Uu),
|
|
5602
5602
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
5603
|
-
altBoundary:
|
|
5604
|
-
}, { refs:
|
|
5603
|
+
altBoundary: V
|
|
5604
|
+
}, { refs: $, floatingStyles: H, placement: O, isPositioned: D, middlewareData: E } = Eu({
|
|
5605
5605
|
// default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
|
|
5606
5606
|
strategy: "fixed",
|
|
5607
5607
|
placement: M,
|
|
5608
|
-
whileElementsMounted: (...
|
|
5608
|
+
whileElementsMounted: (...fe) => mu(...fe, {
|
|
5609
5609
|
animationFrame: g === "always"
|
|
5610
5610
|
}),
|
|
5611
5611
|
elements: {
|
|
@@ -5617,40 +5617,40 @@ var xo = "PopperContent", [Fu, $u] = ps(xo), bs = f.forwardRef(
|
|
|
5617
5617
|
mainAxis: !0,
|
|
5618
5618
|
crossAxis: !1,
|
|
5619
5619
|
limiter: u === "partial" ? Iu() : void 0,
|
|
5620
|
-
...
|
|
5620
|
+
...U
|
|
5621
5621
|
}),
|
|
5622
|
-
l && Pu({ ...
|
|
5622
|
+
l && Pu({ ...U }),
|
|
5623
5623
|
Mu({
|
|
5624
|
-
...
|
|
5625
|
-
apply: ({ elements:
|
|
5626
|
-
const { width: qe, height:
|
|
5627
|
-
at.setProperty("--radix-popper-available-width", `${Ye}px`), at.setProperty("--radix-popper-available-height", `${Xe}px`), at.setProperty("--radix-popper-anchor-width", `${qe}px`), at.setProperty("--radix-popper-anchor-height", `${
|
|
5624
|
+
...U,
|
|
5625
|
+
apply: ({ elements: fe, rects: ye, availableWidth: Ye, availableHeight: Xe }) => {
|
|
5626
|
+
const { width: qe, height: Pn } = ye.reference, at = fe.floating.style;
|
|
5627
|
+
at.setProperty("--radix-popper-available-width", `${Ye}px`), at.setProperty("--radix-popper-available-height", `${Xe}px`), at.setProperty("--radix-popper-anchor-width", `${qe}px`), at.setProperty("--radix-popper-anchor-height", `${Pn}px`);
|
|
5628
5628
|
}
|
|
5629
5629
|
}),
|
|
5630
5630
|
S && ku({ element: S, padding: a }),
|
|
5631
5631
|
Bu({ arrowWidth: R, arrowHeight: C }),
|
|
5632
|
-
h && Nu({ strategy: "referenceHidden", ...
|
|
5632
|
+
h && Nu({ strategy: "referenceHidden", ...U })
|
|
5633
5633
|
]
|
|
5634
5634
|
}), [P, q] = xs(O), te = _e(b);
|
|
5635
|
-
|
|
5635
|
+
ue(() => {
|
|
5636
5636
|
D && (te == null || te());
|
|
5637
5637
|
}, [D, te]);
|
|
5638
|
-
const re = (I = E.arrow) == null ? void 0 : I.x, J = (j = E.arrow) == null ? void 0 : j.y, Z = ((
|
|
5639
|
-
return
|
|
5638
|
+
const re = (I = E.arrow) == null ? void 0 : I.x, J = (j = E.arrow) == null ? void 0 : j.y, Z = ((G = E.arrow) == null ? void 0 : G.centerOffset) !== 0, [le, ie] = f.useState();
|
|
5639
|
+
return ue(() => {
|
|
5640
5640
|
y && ie(window.getComputedStyle(y).zIndex);
|
|
5641
5641
|
}, [y]), /* @__PURE__ */ p(
|
|
5642
5642
|
"div",
|
|
5643
5643
|
{
|
|
5644
|
-
ref:
|
|
5644
|
+
ref: $.setFloating,
|
|
5645
5645
|
"data-radix-popper-content-wrapper": "",
|
|
5646
5646
|
style: {
|
|
5647
|
-
...
|
|
5648
|
-
transform: D ?
|
|
5647
|
+
...H,
|
|
5648
|
+
transform: D ? H.transform : "translate(0, -200%)",
|
|
5649
5649
|
// keep off the page when measuring
|
|
5650
5650
|
minWidth: "max-content",
|
|
5651
5651
|
zIndex: le,
|
|
5652
5652
|
"--radix-popper-transform-origin": [
|
|
5653
|
-
(
|
|
5653
|
+
(K = E.transformOrigin) == null ? void 0 : K.x,
|
|
5654
5654
|
(Y = E.transformOrigin) == null ? void 0 : Y.y
|
|
5655
5655
|
].join(" "),
|
|
5656
5656
|
// hide the content if using the hide middleware and should be hidden
|
|
@@ -5764,7 +5764,7 @@ function xs(e) {
|
|
|
5764
5764
|
var Cs = hs, Ss = vs, Es = bs, Rs = ys, zu = "Portal", Co = f.forwardRef((e, t) => {
|
|
5765
5765
|
var a;
|
|
5766
5766
|
const { container: n, ...o } = e, [r, s] = f.useState(!1);
|
|
5767
|
-
|
|
5767
|
+
ue(() => s(!0), []);
|
|
5768
5768
|
const i = n || r && ((a = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : a.body);
|
|
5769
5769
|
return i ? ma.createPortal(/* @__PURE__ */ p(X.div, { ...o, ref: t }), i) : null;
|
|
5770
5770
|
});
|
|
@@ -5794,13 +5794,13 @@ function Hu(e) {
|
|
|
5794
5794
|
return f.useEffect(() => {
|
|
5795
5795
|
const c = Wt(o.current);
|
|
5796
5796
|
s.current = a === "mounted" ? c : "none";
|
|
5797
|
-
}, [a]),
|
|
5797
|
+
}, [a]), ue(() => {
|
|
5798
5798
|
const c = o.current, d = r.current;
|
|
5799
5799
|
if (d !== e) {
|
|
5800
5800
|
const h = s.current, g = Wt(c);
|
|
5801
5801
|
e ? l("MOUNT") : g === "none" || (c == null ? void 0 : c.display) === "none" ? l("UNMOUNT") : l(d && h !== g ? "ANIMATION_OUT" : "UNMOUNT"), r.current = e;
|
|
5802
5802
|
}
|
|
5803
|
-
}, [e, l]),
|
|
5803
|
+
}, [e, l]), ue(() => {
|
|
5804
5804
|
if (t) {
|
|
5805
5805
|
let c;
|
|
5806
5806
|
const d = t.ownerDocument.defaultView ?? window, u = (g) => {
|
|
@@ -5834,7 +5834,7 @@ function Gu(e) {
|
|
|
5834
5834
|
let t = (o = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : o.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
5835
5835
|
return n ? e.ref : (t = (r = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : r.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
5836
5836
|
}
|
|
5837
|
-
var
|
|
5837
|
+
var $n = "rovingFocusGroup.onEntryFocus", Ku = { bubbles: !1, cancelable: !0 }, Dt = "RovingFocusGroup", [eo, As, ju] = uo(Dt), [Yu, wn] = rt(
|
|
5838
5838
|
Dt,
|
|
5839
5839
|
[ju]
|
|
5840
5840
|
), [Xu, qu] = Yu(Dt), Ts = f.forwardRef(
|
|
@@ -5853,7 +5853,7 @@ var Zu = f.forwardRef((e, t) => {
|
|
|
5853
5853
|
onEntryFocus: c,
|
|
5854
5854
|
preventScrollOnEntryFocus: d = !1,
|
|
5855
5855
|
...u
|
|
5856
|
-
} = e, h = f.useRef(null), g = ne(t, h), b =
|
|
5856
|
+
} = e, h = f.useRef(null), g = ne(t, h), b = pn(s), [m, v] = It({
|
|
5857
5857
|
prop: i,
|
|
5858
5858
|
defaultProp: a ?? null,
|
|
5859
5859
|
onChange: l,
|
|
@@ -5862,7 +5862,7 @@ var Zu = f.forwardRef((e, t) => {
|
|
|
5862
5862
|
return f.useEffect(() => {
|
|
5863
5863
|
const C = h.current;
|
|
5864
5864
|
if (C)
|
|
5865
|
-
return C.addEventListener(
|
|
5865
|
+
return C.addEventListener($n, w), () => C.removeEventListener($n, w);
|
|
5866
5866
|
}, [w]), /* @__PURE__ */ p(
|
|
5867
5867
|
Xu,
|
|
5868
5868
|
{
|
|
@@ -5898,12 +5898,12 @@ var Zu = f.forwardRef((e, t) => {
|
|
|
5898
5898
|
onFocus: L(e.onFocus, (C) => {
|
|
5899
5899
|
const M = !A.current;
|
|
5900
5900
|
if (C.target === C.currentTarget && M && !y) {
|
|
5901
|
-
const N = new CustomEvent(
|
|
5901
|
+
const N = new CustomEvent($n, Ku);
|
|
5902
5902
|
if (C.currentTarget.dispatchEvent(N), !N.defaultPrevented) {
|
|
5903
|
-
const
|
|
5903
|
+
const F = S().filter((O) => O.focusable), V = F.find((O) => O.active), U = F.find((O) => O.id === m), H = [V, U, ...F].filter(
|
|
5904
5904
|
Boolean
|
|
5905
5905
|
).map((O) => O.ref.current);
|
|
5906
|
-
Ms(
|
|
5906
|
+
Ms(H, d);
|
|
5907
5907
|
}
|
|
5908
5908
|
}
|
|
5909
5909
|
A.current = !1;
|
|
@@ -6003,7 +6003,7 @@ var Ns = Ts, ks = Ps, nd = function(e) {
|
|
|
6003
6003
|
return null;
|
|
6004
6004
|
var t = Array.isArray(e) ? e[0] : e;
|
|
6005
6005
|
return t.ownerDocument.body;
|
|
6006
|
-
}, lt = /* @__PURE__ */ new WeakMap(), Ht = /* @__PURE__ */ new WeakMap(), Gt = {},
|
|
6006
|
+
}, lt = /* @__PURE__ */ new WeakMap(), Ht = /* @__PURE__ */ new WeakMap(), Gt = {}, Vn = 0, _s = function(e) {
|
|
6007
6007
|
return e && (e.host || _s(e.parentNode));
|
|
6008
6008
|
}, od = function(e, t) {
|
|
6009
6009
|
return t.map(function(n) {
|
|
@@ -6034,11 +6034,11 @@ var Ns = Ts, ks = Ps, nd = function(e) {
|
|
|
6034
6034
|
}
|
|
6035
6035
|
});
|
|
6036
6036
|
};
|
|
6037
|
-
return d(t), a.clear(),
|
|
6037
|
+
return d(t), a.clear(), Vn++, function() {
|
|
6038
6038
|
i.forEach(function(u) {
|
|
6039
6039
|
var h = lt.get(u) - 1, g = s.get(u) - 1;
|
|
6040
6040
|
lt.set(u, h), s.set(u, g), h || (Ht.has(u) || u.removeAttribute(o), Ht.delete(u)), g || u.removeAttribute(n);
|
|
6041
|
-
}),
|
|
6041
|
+
}), Vn--, Vn || (lt = /* @__PURE__ */ new WeakMap(), lt = /* @__PURE__ */ new WeakMap(), Ht = /* @__PURE__ */ new WeakMap(), Gt = {});
|
|
6042
6042
|
};
|
|
6043
6043
|
}, Os = function(e, t, n) {
|
|
6044
6044
|
n === void 0 && (n = "data-aria-hidden");
|
|
@@ -6068,8 +6068,8 @@ function sd(e, t, n) {
|
|
|
6068
6068
|
(s || !(o in t)) && (s || (s = Array.prototype.slice.call(t, 0, o)), s[o] = t[o]);
|
|
6069
6069
|
return e.concat(s || Array.prototype.slice.call(t));
|
|
6070
6070
|
}
|
|
6071
|
-
var
|
|
6072
|
-
function
|
|
6071
|
+
var Qt = "right-scroll-bar-position", en = "width-before-scroll-bar", id = "with-scroll-bars-hidden", ad = "--removed-body-scroll-bar-size";
|
|
6072
|
+
function Un(e, t) {
|
|
6073
6073
|
return typeof e == "function" ? e(t) : e && (e.current = t), e;
|
|
6074
6074
|
}
|
|
6075
6075
|
function cd(e, t) {
|
|
@@ -6097,7 +6097,7 @@ var ld = typeof window < "u" ? f.useLayoutEffect : f.useEffect, br = /* @__PURE_
|
|
|
6097
6097
|
function ud(e, t) {
|
|
6098
6098
|
var n = cd(null, function(o) {
|
|
6099
6099
|
return e.forEach(function(r) {
|
|
6100
|
-
return
|
|
6100
|
+
return Un(r, o);
|
|
6101
6101
|
});
|
|
6102
6102
|
});
|
|
6103
6103
|
return ld(function() {
|
|
@@ -6105,9 +6105,9 @@ function ud(e, t) {
|
|
|
6105
6105
|
if (o) {
|
|
6106
6106
|
var r = new Set(o), s = new Set(e), i = n.current;
|
|
6107
6107
|
r.forEach(function(a) {
|
|
6108
|
-
s.has(a) ||
|
|
6108
|
+
s.has(a) || Un(a, null);
|
|
6109
6109
|
}), s.forEach(function(a) {
|
|
6110
|
-
r.has(a) ||
|
|
6110
|
+
r.has(a) || Un(a, i);
|
|
6111
6111
|
});
|
|
6112
6112
|
}
|
|
6113
6113
|
br.set(n, e);
|
|
@@ -6189,12 +6189,12 @@ Ls.isSideCarExport = !0;
|
|
|
6189
6189
|
function md(e, t) {
|
|
6190
6190
|
return e.useMedium(t), Ls;
|
|
6191
6191
|
}
|
|
6192
|
-
var Fs = pd(),
|
|
6193
|
-
},
|
|
6192
|
+
var Fs = pd(), Bn = function() {
|
|
6193
|
+
}, yn = f.forwardRef(function(e, t) {
|
|
6194
6194
|
var n = f.useRef(null), o = f.useState({
|
|
6195
|
-
onScrollCapture:
|
|
6196
|
-
onWheelCapture:
|
|
6197
|
-
onTouchMoveCapture:
|
|
6195
|
+
onScrollCapture: Bn,
|
|
6196
|
+
onWheelCapture: Bn,
|
|
6197
|
+
onTouchMoveCapture: Bn
|
|
6198
6198
|
}), r = o[0], s = o[1], i = e.forwardProps, a = e.children, l = e.className, c = e.removeScrollBar, d = e.enabled, u = e.shards, h = e.sideCar, g = e.noRelative, b = e.noIsolation, m = e.inert, v = e.allowPinchZoom, y = e.as, x = y === void 0 ? "div" : y, w = e.gapMode, S = Ds(e, ["forwardProps", "children", "className", "removeScrollBar", "enabled", "shards", "sideCar", "noRelative", "noIsolation", "inert", "allowPinchZoom", "as", "gapMode"]), A = h, T = ud([n, t]), R = Te(Te({}, S), r);
|
|
6199
6199
|
return f.createElement(
|
|
6200
6200
|
f.Fragment,
|
|
@@ -6203,14 +6203,14 @@ var Fs = pd(), zn = function() {
|
|
|
6203
6203
|
i ? f.cloneElement(f.Children.only(a), Te(Te({}, R), { ref: T })) : f.createElement(x, Te({}, R, { className: l, ref: T }), a)
|
|
6204
6204
|
);
|
|
6205
6205
|
});
|
|
6206
|
-
|
|
6206
|
+
yn.defaultProps = {
|
|
6207
6207
|
enabled: !0,
|
|
6208
6208
|
removeScrollBar: !0,
|
|
6209
6209
|
inert: !1
|
|
6210
6210
|
};
|
|
6211
|
-
|
|
6212
|
-
fullWidth:
|
|
6213
|
-
zeroRight:
|
|
6211
|
+
yn.classNames = {
|
|
6212
|
+
fullWidth: en,
|
|
6213
|
+
zeroRight: Qt
|
|
6214
6214
|
};
|
|
6215
6215
|
var hd = function() {
|
|
6216
6216
|
if (typeof __webpack_nonce__ < "u")
|
|
@@ -6261,11 +6261,11 @@ var wd = function() {
|
|
|
6261
6261
|
top: 0,
|
|
6262
6262
|
right: 0,
|
|
6263
6263
|
gap: 0
|
|
6264
|
-
},
|
|
6264
|
+
}, zn = function(e) {
|
|
6265
6265
|
return parseInt(e || "", 10) || 0;
|
|
6266
6266
|
}, Cd = function(e) {
|
|
6267
6267
|
var t = window.getComputedStyle(document.body), n = t[e === "padding" ? "paddingLeft" : "marginLeft"], o = t[e === "padding" ? "paddingTop" : "marginTop"], r = t[e === "padding" ? "paddingRight" : "marginRight"];
|
|
6268
|
-
return [
|
|
6268
|
+
return [zn(n), zn(o), zn(r)];
|
|
6269
6269
|
}, Sd = function(e) {
|
|
6270
6270
|
if (e === void 0 && (e = "margin"), typeof window > "u")
|
|
6271
6271
|
return xd;
|
|
@@ -6300,19 +6300,19 @@ var wd = function() {
|
|
|
6300
6300
|
].filter(Boolean).join(""), `
|
|
6301
6301
|
}
|
|
6302
6302
|
|
|
6303
|
-
.`).concat(
|
|
6303
|
+
.`).concat(Qt, ` {
|
|
6304
6304
|
right: `).concat(a, "px ").concat(o, `;
|
|
6305
6305
|
}
|
|
6306
6306
|
|
|
6307
|
-
.`).concat(
|
|
6307
|
+
.`).concat(en, ` {
|
|
6308
6308
|
margin-right: `).concat(a, "px ").concat(o, `;
|
|
6309
6309
|
}
|
|
6310
6310
|
|
|
6311
|
-
.`).concat(
|
|
6311
|
+
.`).concat(Qt, " .").concat(Qt, ` {
|
|
6312
6312
|
right: 0 `).concat(o, `;
|
|
6313
6313
|
}
|
|
6314
6314
|
|
|
6315
|
-
.`).concat(
|
|
6315
|
+
.`).concat(en, " .").concat(en, ` {
|
|
6316
6316
|
margin-right: 0 `).concat(o, `;
|
|
6317
6317
|
}
|
|
6318
6318
|
|
|
@@ -6452,15 +6452,15 @@ function $d(e) {
|
|
|
6452
6452
|
var C = window.getSelection(), M = C && C.anchorNode, N = M ? M === T || M.contains(T) : !1;
|
|
6453
6453
|
if (N)
|
|
6454
6454
|
return !1;
|
|
6455
|
-
var
|
|
6456
|
-
if (
|
|
6455
|
+
var F = yr(R, T);
|
|
6456
|
+
if (!F)
|
|
6457
6457
|
return !0;
|
|
6458
|
-
if (
|
|
6458
|
+
if (F ? A = R : (A = R === "v" ? "h" : "v", F = yr(R, T)), !F)
|
|
6459
6459
|
return !1;
|
|
6460
6460
|
if (!o.current && "changedTouches" in m && (w || S) && (o.current = A), !A)
|
|
6461
6461
|
return !0;
|
|
6462
|
-
var
|
|
6463
|
-
return Od(
|
|
6462
|
+
var V = o.current || A;
|
|
6463
|
+
return Od(V, v, m, V === "h" ? w : S);
|
|
6464
6464
|
}, []), l = f.useCallback(function(m) {
|
|
6465
6465
|
var v = m;
|
|
6466
6466
|
if (!(!dt.length || dt[dt.length - 1] !== s)) {
|
|
@@ -6518,9 +6518,9 @@ function Vd(e) {
|
|
|
6518
6518
|
}
|
|
6519
6519
|
const Ud = md(Fs, $d);
|
|
6520
6520
|
var So = f.forwardRef(function(e, t) {
|
|
6521
|
-
return f.createElement(
|
|
6521
|
+
return f.createElement(yn, Te({}, e, { ref: t, sideCar: Ud }));
|
|
6522
6522
|
});
|
|
6523
|
-
So.classNames =
|
|
6523
|
+
So.classNames = yn.classNames;
|
|
6524
6524
|
var no = ["Enter", " "], Bd = ["ArrowDown", "PageUp", "Home"], zs = ["ArrowUp", "PageDown", "End"], zd = [...Bd, ...zs], Wd = {
|
|
6525
6525
|
ltr: [...no, "ArrowRight"],
|
|
6526
6526
|
rtl: [...no, "ArrowLeft"]
|
|
@@ -6529,10 +6529,10 @@ var no = ["Enter", " "], Bd = ["ArrowDown", "PageUp", "Home"], zs = ["ArrowUp",
|
|
|
6529
6529
|
rtl: ["ArrowRight"]
|
|
6530
6530
|
}, Lt = "Menu", [kt, Gd, Kd] = uo(Lt), [st, Ws] = rt(Lt, [
|
|
6531
6531
|
Kd,
|
|
6532
|
-
|
|
6533
|
-
|
|
6534
|
-
]),
|
|
6535
|
-
const { __scopeMenu: t, open: n = !1, children: o, dir: r, onOpenChange: s, modal: i = !0 } = e, a =
|
|
6532
|
+
bn,
|
|
6533
|
+
wn
|
|
6534
|
+
]), xn = bn(), Hs = wn(), [jd, it] = st(Lt), [Yd, Ft] = st(Lt), Gs = (e) => {
|
|
6535
|
+
const { __scopeMenu: t, open: n = !1, children: o, dir: r, onOpenChange: s, modal: i = !0 } = e, a = xn(t), [l, c] = f.useState(null), d = f.useRef(!1), u = _e(s), h = pn(r);
|
|
6536
6536
|
return f.useEffect(() => {
|
|
6537
6537
|
const g = () => {
|
|
6538
6538
|
d.current = !0, document.addEventListener("pointerdown", b, { capture: !0, once: !0 }), document.addEventListener("pointermove", b, { capture: !0, once: !0 });
|
|
@@ -6565,7 +6565,7 @@ var no = ["Enter", " "], Bd = ["ArrowDown", "PageUp", "Home"], zs = ["ArrowUp",
|
|
|
6565
6565
|
Gs.displayName = Lt;
|
|
6566
6566
|
var Xd = "MenuAnchor", Eo = f.forwardRef(
|
|
6567
6567
|
(e, t) => {
|
|
6568
|
-
const { __scopeMenu: n, ...o } = e, r =
|
|
6568
|
+
const { __scopeMenu: n, ...o } = e, r = xn(n);
|
|
6569
6569
|
return /* @__PURE__ */ p(Ss, { ...r, ...o, ref: t });
|
|
6570
6570
|
}
|
|
6571
6571
|
);
|
|
@@ -6635,17 +6635,17 @@ var Se = "MenuContent", [Zd, Ao] = st(Se), Ys = f.forwardRef(
|
|
|
6635
6635
|
onDismiss: g,
|
|
6636
6636
|
disableOutsideScroll: b,
|
|
6637
6637
|
...m
|
|
6638
|
-
} = e, v = it(Se, n), y = Ft(Se, n), x =
|
|
6638
|
+
} = e, v = it(Se, n), y = Ft(Se, n), x = xn(n), w = Hs(n), S = Gd(n), [A, T] = f.useState(null), R = f.useRef(null), C = ne(t, R, v.onContentChange), M = f.useRef(0), N = f.useRef(""), F = f.useRef(0), V = f.useRef(null), U = f.useRef("right"), $ = f.useRef(0), H = b ? So : f.Fragment, O = b ? { as: ef, allowPinchZoom: !0 } : void 0, D = (P) => {
|
|
6639
6639
|
var I, j;
|
|
6640
|
-
const q = N.current + P, te = S().filter((
|
|
6641
|
-
(function
|
|
6642
|
-
N.current =
|
|
6640
|
+
const q = N.current + P, te = S().filter((G) => !G.disabled), re = document.activeElement, J = (I = te.find((G) => G.ref.current === re)) == null ? void 0 : I.textValue, Z = te.map((G) => G.textValue), le = pf(Z, q, J), ie = (j = te.find((G) => G.textValue === le)) == null ? void 0 : j.ref.current;
|
|
6641
|
+
(function G(K) {
|
|
6642
|
+
N.current = K, window.clearTimeout(M.current), K !== "" && (M.current = window.setTimeout(() => G(""), 1e3));
|
|
6643
6643
|
})(q), ie && setTimeout(() => ie.focus());
|
|
6644
6644
|
};
|
|
6645
6645
|
f.useEffect(() => () => window.clearTimeout(M.current), []), Qr();
|
|
6646
6646
|
const E = f.useCallback((P) => {
|
|
6647
6647
|
var te, re;
|
|
6648
|
-
return
|
|
6648
|
+
return U.current === ((te = V.current) == null ? void 0 : te.side) && hf(P, (re = V.current) == null ? void 0 : re.area);
|
|
6649
6649
|
}, []);
|
|
6650
6650
|
return /* @__PURE__ */ p(
|
|
6651
6651
|
Zd,
|
|
@@ -6671,11 +6671,11 @@ var Se = "MenuContent", [Zd, Ao] = st(Se), Ys = f.forwardRef(
|
|
|
6671
6671
|
},
|
|
6672
6672
|
[E]
|
|
6673
6673
|
),
|
|
6674
|
-
pointerGraceTimerRef:
|
|
6674
|
+
pointerGraceTimerRef: F,
|
|
6675
6675
|
onPointerGraceIntentChange: f.useCallback((P) => {
|
|
6676
|
-
|
|
6676
|
+
V.current = P;
|
|
6677
6677
|
}, []),
|
|
6678
|
-
children: /* @__PURE__ */ p(
|
|
6678
|
+
children: /* @__PURE__ */ p(H, { ...O, children: /* @__PURE__ */ p(
|
|
6679
6679
|
po,
|
|
6680
6680
|
{
|
|
6681
6681
|
asChild: !0,
|
|
@@ -6736,10 +6736,10 @@ var Se = "MenuContent", [Zd, Ao] = st(Se), Ys = f.forwardRef(
|
|
|
6736
6736
|
onPointerMove: L(
|
|
6737
6737
|
e.onPointerMove,
|
|
6738
6738
|
_t((P) => {
|
|
6739
|
-
const q = P.target, te =
|
|
6739
|
+
const q = P.target, te = $.current !== P.clientX;
|
|
6740
6740
|
if (P.currentTarget.contains(q) && te) {
|
|
6741
|
-
const re = P.clientX >
|
|
6742
|
-
|
|
6741
|
+
const re = P.clientX > $.current ? "right" : "left";
|
|
6742
|
+
U.current = re, $.current = P.clientX;
|
|
6743
6743
|
}
|
|
6744
6744
|
})
|
|
6745
6745
|
)
|
|
@@ -6770,9 +6770,9 @@ var nf = "MenuLabel", Xs = f.forwardRef(
|
|
|
6770
6770
|
}
|
|
6771
6771
|
);
|
|
6772
6772
|
Xs.displayName = nf;
|
|
6773
|
-
var
|
|
6773
|
+
var an = "MenuItem", Sr = "menu.itemSelect", Cn = f.forwardRef(
|
|
6774
6774
|
(e, t) => {
|
|
6775
|
-
const { disabled: n = !1, onSelect: o, ...r } = e, s = f.useRef(null), i = Ft(
|
|
6775
|
+
const { disabled: n = !1, onSelect: o, ...r } = e, s = f.useRef(null), i = Ft(an, e.__scopeMenu), a = Ao(an, e.__scopeMenu), l = ne(t, s), c = f.useRef(!1), d = () => {
|
|
6776
6776
|
const u = s.current;
|
|
6777
6777
|
if (!n && u) {
|
|
6778
6778
|
const h = new CustomEvent(Sr, { bubbles: !0, cancelable: !0 });
|
|
@@ -6802,10 +6802,10 @@ var cn = "MenuItem", Sr = "menu.itemSelect", Sn = f.forwardRef(
|
|
|
6802
6802
|
);
|
|
6803
6803
|
}
|
|
6804
6804
|
);
|
|
6805
|
-
|
|
6805
|
+
Cn.displayName = an;
|
|
6806
6806
|
var qs = f.forwardRef(
|
|
6807
6807
|
(e, t) => {
|
|
6808
|
-
const { __scopeMenu: n, disabled: o = !1, textValue: r, ...s } = e, i = Ao(
|
|
6808
|
+
const { __scopeMenu: n, disabled: o = !1, textValue: r, ...s } = e, i = Ao(an, n), a = Hs(n), l = f.useRef(null), c = ne(t, l), [d, u] = f.useState(!1), [h, g] = f.useState("");
|
|
6809
6809
|
return f.useEffect(() => {
|
|
6810
6810
|
const b = l.current;
|
|
6811
6811
|
b && g((b.textContent ?? "").trim());
|
|
@@ -6845,16 +6845,16 @@ var qs = f.forwardRef(
|
|
|
6845
6845
|
(e, t) => {
|
|
6846
6846
|
const { checked: n = !1, onCheckedChange: o, ...r } = e;
|
|
6847
6847
|
return /* @__PURE__ */ p(ni, { scope: e.__scopeMenu, checked: n, children: /* @__PURE__ */ p(
|
|
6848
|
-
|
|
6848
|
+
Cn,
|
|
6849
6849
|
{
|
|
6850
6850
|
role: "menuitemcheckbox",
|
|
6851
|
-
"aria-checked":
|
|
6851
|
+
"aria-checked": cn(n) ? "mixed" : n,
|
|
6852
6852
|
...r,
|
|
6853
6853
|
ref: t,
|
|
6854
6854
|
"data-state": Mo(n),
|
|
6855
6855
|
onSelect: L(
|
|
6856
6856
|
r.onSelect,
|
|
6857
|
-
() => o == null ? void 0 : o(
|
|
6857
|
+
() => o == null ? void 0 : o(cn(n) ? !0 : !n),
|
|
6858
6858
|
{ checkForDefaultPrevented: !1 }
|
|
6859
6859
|
)
|
|
6860
6860
|
}
|
|
@@ -6877,7 +6877,7 @@ var ei = "MenuRadioItem", ti = f.forwardRef(
|
|
|
6877
6877
|
(e, t) => {
|
|
6878
6878
|
const { value: n, ...o } = e, r = sf(ei, e.__scopeMenu), s = n === r.value;
|
|
6879
6879
|
return /* @__PURE__ */ p(ni, { scope: e.__scopeMenu, checked: s, children: /* @__PURE__ */ p(
|
|
6880
|
-
|
|
6880
|
+
Cn,
|
|
6881
6881
|
{
|
|
6882
6882
|
role: "menuitemradio",
|
|
6883
6883
|
"aria-checked": s,
|
|
@@ -6906,7 +6906,7 @@ var Po = "MenuItemIndicator", [ni, af] = st(
|
|
|
6906
6906
|
return /* @__PURE__ */ p(
|
|
6907
6907
|
yt,
|
|
6908
6908
|
{
|
|
6909
|
-
present: o ||
|
|
6909
|
+
present: o || cn(s.checked) || s.checked === !0,
|
|
6910
6910
|
children: /* @__PURE__ */ p(
|
|
6911
6911
|
X.span,
|
|
6912
6912
|
{
|
|
@@ -6937,7 +6937,7 @@ var cf = "MenuSeparator", ri = f.forwardRef(
|
|
|
6937
6937
|
ri.displayName = cf;
|
|
6938
6938
|
var lf = "MenuArrow", si = f.forwardRef(
|
|
6939
6939
|
(e, t) => {
|
|
6940
|
-
const { __scopeMenu: n, ...o } = e, r =
|
|
6940
|
+
const { __scopeMenu: n, ...o } = e, r = xn(n);
|
|
6941
6941
|
return /* @__PURE__ */ p(Rs, { ...r, ...o, ref: t });
|
|
6942
6942
|
}
|
|
6943
6943
|
);
|
|
@@ -6961,7 +6961,7 @@ var uf = "MenuSub", [Vm, ii] = st(uf), Rt = "MenuSubTrigger", ai = f.forwardRef(
|
|
|
6961
6961
|
"aria-controls": r.contentId,
|
|
6962
6962
|
"data-state": ui(n.open),
|
|
6963
6963
|
...e,
|
|
6964
|
-
ref:
|
|
6964
|
+
ref: fn(t, r.onTriggerChange),
|
|
6965
6965
|
onClick: (u) => {
|
|
6966
6966
|
var h;
|
|
6967
6967
|
(h = e.onClick) == null || h.call(e, u), !(e.disabled || u.defaultPrevented) && (u.currentTarget.focus(), n.open || n.onOpenChange(!0));
|
|
@@ -7052,11 +7052,11 @@ li.displayName = ci;
|
|
|
7052
7052
|
function ui(e) {
|
|
7053
7053
|
return e ? "open" : "closed";
|
|
7054
7054
|
}
|
|
7055
|
-
function
|
|
7055
|
+
function cn(e) {
|
|
7056
7056
|
return e === "indeterminate";
|
|
7057
7057
|
}
|
|
7058
7058
|
function Mo(e) {
|
|
7059
|
-
return
|
|
7059
|
+
return cn(e) ? "indeterminate" : e ? "checked" : "unchecked";
|
|
7060
7060
|
}
|
|
7061
7061
|
function df(e) {
|
|
7062
7062
|
const t = document.activeElement;
|
|
@@ -7092,10 +7092,10 @@ function hf(e, t) {
|
|
|
7092
7092
|
function _t(e) {
|
|
7093
7093
|
return (t) => t.pointerType === "mouse" ? e(t) : void 0;
|
|
7094
7094
|
}
|
|
7095
|
-
var gf = Gs, vf = Eo, bf = js, wf = Ys, yf = Io, xf = Xs, Cf =
|
|
7096
|
-
|
|
7095
|
+
var gf = Gs, vf = Eo, bf = js, wf = Ys, yf = Io, xf = Xs, Cf = Cn, Sf = Zs, Ef = Qs, Rf = ti, Af = oi, Tf = ri, If = si, Pf = ai, Mf = li, Sn = "DropdownMenu", [Nf] = rt(
|
|
7096
|
+
Sn,
|
|
7097
7097
|
[Ws]
|
|
7098
|
-
), me = Ws(), [kf, di] = Nf(
|
|
7098
|
+
), me = Ws(), [kf, di] = Nf(Sn), fi = (e) => {
|
|
7099
7099
|
const {
|
|
7100
7100
|
__scopeDropdownMenu: t,
|
|
7101
7101
|
children: n,
|
|
@@ -7108,7 +7108,7 @@ var gf = Gs, vf = Eo, bf = js, wf = Ys, yf = Io, xf = Xs, Cf = Sn, Sf = Zs, Ef =
|
|
|
7108
7108
|
prop: r,
|
|
7109
7109
|
defaultProp: s ?? !1,
|
|
7110
7110
|
onChange: i,
|
|
7111
|
-
caller:
|
|
7111
|
+
caller: Sn
|
|
7112
7112
|
});
|
|
7113
7113
|
return /* @__PURE__ */ p(
|
|
7114
7114
|
kf,
|
|
@@ -7125,7 +7125,7 @@ var gf = Gs, vf = Eo, bf = js, wf = Ys, yf = Io, xf = Xs, Cf = Sn, Sf = Zs, Ef =
|
|
|
7125
7125
|
}
|
|
7126
7126
|
);
|
|
7127
7127
|
};
|
|
7128
|
-
fi.displayName =
|
|
7128
|
+
fi.displayName = Sn;
|
|
7129
7129
|
var pi = "DropdownMenuTrigger", mi = f.forwardRef(
|
|
7130
7130
|
(e, t) => {
|
|
7131
7131
|
const { __scopeDropdownMenu: n, disabled: o = !1, ...r } = e, s = di(pi, n), i = me(n);
|
|
@@ -7141,7 +7141,7 @@ var pi = "DropdownMenuTrigger", mi = f.forwardRef(
|
|
|
7141
7141
|
"data-disabled": o ? "" : void 0,
|
|
7142
7142
|
disabled: o,
|
|
7143
7143
|
...r,
|
|
7144
|
-
ref:
|
|
7144
|
+
ref: fn(t, s.triggerRef),
|
|
7145
7145
|
onPointerDown: L(e.onPointerDown, (a) => {
|
|
7146
7146
|
!o && a.button === 0 && a.ctrlKey === !1 && (s.onOpenToggle(), s.open || a.preventDefault());
|
|
7147
7147
|
}),
|
|
@@ -7277,7 +7277,7 @@ function dp({ asChild: e, children: t }) {
|
|
|
7277
7277
|
return /* @__PURE__ */ p(Qf, { asChild: e, children: t });
|
|
7278
7278
|
}
|
|
7279
7279
|
function fp({ align: e = "end", sideOffset: t = 4, className: n, children: o }) {
|
|
7280
|
-
const r =
|
|
7280
|
+
const r = de();
|
|
7281
7281
|
return /* @__PURE__ */ p(ep, { children: /* @__PURE__ */ p(
|
|
7282
7282
|
tp,
|
|
7283
7283
|
{
|
|
@@ -7289,7 +7289,7 @@ function fp({ align: e = "end", sideOffset: t = 4, className: n, children: o })
|
|
|
7289
7289
|
) });
|
|
7290
7290
|
}
|
|
7291
7291
|
function pp({ onClick: e, disabled: t, className: n, asChild: o, children: r }) {
|
|
7292
|
-
const s =
|
|
7292
|
+
const s = de();
|
|
7293
7293
|
return /* @__PURE__ */ p(
|
|
7294
7294
|
np,
|
|
7295
7295
|
{
|
|
@@ -7302,7 +7302,7 @@ function pp({ onClick: e, disabled: t, className: n, asChild: o, children: r })
|
|
|
7302
7302
|
);
|
|
7303
7303
|
}
|
|
7304
7304
|
function mp({ checked: e, onCheckedChange: t, className: n, children: o }) {
|
|
7305
|
-
const r =
|
|
7305
|
+
const r = de();
|
|
7306
7306
|
return /* @__PURE__ */ B(
|
|
7307
7307
|
op,
|
|
7308
7308
|
{
|
|
@@ -7317,7 +7317,7 @@ function mp({ checked: e, onCheckedChange: t, className: n, children: o }) {
|
|
|
7317
7317
|
);
|
|
7318
7318
|
}
|
|
7319
7319
|
function hp() {
|
|
7320
|
-
const e =
|
|
7320
|
+
const e = de();
|
|
7321
7321
|
return /* @__PURE__ */ p(sp, { className: ee(lp, e.dropdown.separator) });
|
|
7322
7322
|
}
|
|
7323
7323
|
const ce = {
|
|
@@ -7329,7 +7329,7 @@ const ce = {
|
|
|
7329
7329
|
Separator: hp
|
|
7330
7330
|
};
|
|
7331
7331
|
function gp({ table: e }) {
|
|
7332
|
-
const { t } = ht(), n =
|
|
7332
|
+
const { t } = ht(), n = Gn(jc()), o = Pe(() => e.getAllColumns().filter((a) => {
|
|
7333
7333
|
const l = a.columnDef.header;
|
|
7334
7334
|
return !(!l || typeof l == "string" && l.trim() === "" || a.columnDef.enableHiding === !1);
|
|
7335
7335
|
}), [e]), r = () => {
|
|
@@ -7393,7 +7393,7 @@ function gp({ table: e }) {
|
|
|
7393
7393
|
] });
|
|
7394
7394
|
}
|
|
7395
7395
|
function vp({ className: e }) {
|
|
7396
|
-
const t =
|
|
7396
|
+
const t = de();
|
|
7397
7397
|
return /* @__PURE__ */ p("div", { className: ee(t.skeleton, e) });
|
|
7398
7398
|
}
|
|
7399
7399
|
function Er(e, [t, n]) {
|
|
@@ -7426,10 +7426,10 @@ var Ci = Object.freeze({
|
|
|
7426
7426
|
)
|
|
7427
7427
|
);
|
|
7428
7428
|
yp.displayName = wp;
|
|
7429
|
-
var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Select", [
|
|
7429
|
+
var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Select", [En, Rn, Sp] = uo(nt), [xt] = rt(nt, [
|
|
7430
7430
|
Sp,
|
|
7431
|
-
|
|
7432
|
-
]),
|
|
7431
|
+
bn
|
|
7432
|
+
]), An = bn(), [Ep, Ke] = xt(nt), [Rp, Ap] = xt(nt), Si = (e) => {
|
|
7433
7433
|
const {
|
|
7434
7434
|
__scopeSelect: t,
|
|
7435
7435
|
children: n,
|
|
@@ -7445,7 +7445,7 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7445
7445
|
disabled: h,
|
|
7446
7446
|
required: g,
|
|
7447
7447
|
form: b
|
|
7448
|
-
} = e, m =
|
|
7448
|
+
} = e, m = An(t), [v, y] = f.useState(null), [x, w] = f.useState(null), [S, A] = f.useState(!1), T = pn(c), [R, C] = It({
|
|
7449
7449
|
prop: o,
|
|
7450
7450
|
defaultProp: r ?? !1,
|
|
7451
7451
|
onChange: s,
|
|
@@ -7455,7 +7455,7 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7455
7455
|
defaultProp: a,
|
|
7456
7456
|
onChange: l,
|
|
7457
7457
|
caller: nt
|
|
7458
|
-
}),
|
|
7458
|
+
}), F = f.useRef(null), V = v ? b || !!v.closest("form") : !0, [U, $] = f.useState(/* @__PURE__ */ new Set()), H = Array.from(U).map((O) => O.props.value).join(";");
|
|
7459
7459
|
return /* @__PURE__ */ p(Cs, { ...m, children: /* @__PURE__ */ B(
|
|
7460
7460
|
Ep,
|
|
7461
7461
|
{
|
|
@@ -7473,18 +7473,18 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7473
7473
|
open: R,
|
|
7474
7474
|
onOpenChange: C,
|
|
7475
7475
|
dir: T,
|
|
7476
|
-
triggerPointerDownPosRef:
|
|
7476
|
+
triggerPointerDownPosRef: F,
|
|
7477
7477
|
disabled: h,
|
|
7478
7478
|
children: [
|
|
7479
|
-
/* @__PURE__ */ p(
|
|
7479
|
+
/* @__PURE__ */ p(En.Provider, { scope: t, children: /* @__PURE__ */ p(
|
|
7480
7480
|
Rp,
|
|
7481
7481
|
{
|
|
7482
7482
|
scope: e.__scopeSelect,
|
|
7483
7483
|
onNativeOptionAdd: f.useCallback((O) => {
|
|
7484
|
-
|
|
7484
|
+
$((D) => new Set(D).add(O));
|
|
7485
7485
|
}, []),
|
|
7486
7486
|
onNativeOptionRemove: f.useCallback((O) => {
|
|
7487
|
-
|
|
7487
|
+
$((D) => {
|
|
7488
7488
|
const E = new Set(D);
|
|
7489
7489
|
return E.delete(O), E;
|
|
7490
7490
|
});
|
|
@@ -7492,7 +7492,7 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7492
7492
|
children: n
|
|
7493
7493
|
}
|
|
7494
7494
|
) }),
|
|
7495
|
-
|
|
7495
|
+
V ? /* @__PURE__ */ B(
|
|
7496
7496
|
Wi,
|
|
7497
7497
|
{
|
|
7498
7498
|
"aria-hidden": !0,
|
|
@@ -7506,10 +7506,10 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7506
7506
|
form: b,
|
|
7507
7507
|
children: [
|
|
7508
7508
|
M === void 0 ? /* @__PURE__ */ p("option", { value: "" }) : null,
|
|
7509
|
-
Array.from(
|
|
7509
|
+
Array.from(U)
|
|
7510
7510
|
]
|
|
7511
7511
|
},
|
|
7512
|
-
|
|
7512
|
+
H
|
|
7513
7513
|
) : null
|
|
7514
7514
|
]
|
|
7515
7515
|
}
|
|
@@ -7518,7 +7518,7 @@ var xp = [" ", "Enter", "ArrowUp", "ArrowDown"], Cp = [" ", "Enter"], nt = "Sele
|
|
|
7518
7518
|
Si.displayName = nt;
|
|
7519
7519
|
var Ei = "SelectTrigger", Ri = f.forwardRef(
|
|
7520
7520
|
(e, t) => {
|
|
7521
|
-
const { __scopeSelect: n, disabled: o = !1, ...r } = e, s =
|
|
7521
|
+
const { __scopeSelect: n, disabled: o = !1, ...r } = e, s = An(n), i = Ke(Ei, n), a = i.disabled || o, l = ne(t, i.onTriggerChange), c = Rn(n), d = f.useRef("touch"), [u, h, g] = Gi((m) => {
|
|
7522
7522
|
const v = c().filter((w) => !w.disabled), y = v.find((w) => w.value === i.value), x = Ki(v, m, y);
|
|
7523
7523
|
x !== void 0 && i.onValueChange(x.value);
|
|
7524
7524
|
}), b = (m) => {
|
|
@@ -7563,7 +7563,7 @@ Ri.displayName = Ei;
|
|
|
7563
7563
|
var Ai = "SelectValue", Ti = f.forwardRef(
|
|
7564
7564
|
(e, t) => {
|
|
7565
7565
|
const { __scopeSelect: n, className: o, style: r, children: s, placeholder: i = "", ...a } = e, l = Ke(Ai, n), { onValueNodeHasChildrenChange: c } = l, d = s !== void 0, u = ne(t, l.onValueNodeChange);
|
|
7566
|
-
return
|
|
7566
|
+
return ue(() => {
|
|
7567
7567
|
c(d);
|
|
7568
7568
|
}, [c, d]), /* @__PURE__ */ p(
|
|
7569
7569
|
X.span,
|
|
@@ -7571,7 +7571,7 @@ var Ai = "SelectValue", Ti = f.forwardRef(
|
|
|
7571
7571
|
...a,
|
|
7572
7572
|
ref: u,
|
|
7573
7573
|
style: { pointerEvents: "none" },
|
|
7574
|
-
children: Hi(l.value) ? /* @__PURE__ */ p(
|
|
7574
|
+
children: Hi(l.value) ? /* @__PURE__ */ p(un, { children: i }) : s
|
|
7575
7575
|
}
|
|
7576
7576
|
);
|
|
7577
7577
|
}
|
|
@@ -7589,12 +7589,12 @@ Pi.displayName = Ip;
|
|
|
7589
7589
|
var ot = "SelectContent", Mi = f.forwardRef(
|
|
7590
7590
|
(e, t) => {
|
|
7591
7591
|
const n = Ke(ot, e.__scopeSelect), [o, r] = f.useState();
|
|
7592
|
-
if (
|
|
7592
|
+
if (ue(() => {
|
|
7593
7593
|
r(new DocumentFragment());
|
|
7594
7594
|
}, []), !n.open) {
|
|
7595
7595
|
const s = o;
|
|
7596
|
-
return s ?
|
|
7597
|
-
/* @__PURE__ */ p(Ni, { scope: e.__scopeSelect, children: /* @__PURE__ */ p(
|
|
7596
|
+
return s ? dn.createPortal(
|
|
7597
|
+
/* @__PURE__ */ p(Ni, { scope: e.__scopeSelect, children: /* @__PURE__ */ p(En.Slot, { scope: e.__scopeSelect, children: /* @__PURE__ */ p("div", { children: e.children }) }) }),
|
|
7598
7598
|
s
|
|
7599
7599
|
) : null;
|
|
7600
7600
|
}
|
|
@@ -7624,41 +7624,41 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7624
7624
|
avoidCollisions: v,
|
|
7625
7625
|
//
|
|
7626
7626
|
...y
|
|
7627
|
-
} = e, x = Ke(ot, n), [w, S] = f.useState(null), [A, T] = f.useState(null), R = ne(t, (I) => S(I)), [C, M] = f.useState(null), [N,
|
|
7627
|
+
} = e, x = Ke(ot, n), [w, S] = f.useState(null), [A, T] = f.useState(null), R = ne(t, (I) => S(I)), [C, M] = f.useState(null), [N, F] = f.useState(
|
|
7628
7628
|
null
|
|
7629
|
-
),
|
|
7629
|
+
), V = Rn(n), [U, $] = f.useState(!1), H = f.useRef(!1);
|
|
7630
7630
|
f.useEffect(() => {
|
|
7631
7631
|
if (w) return Os(w);
|
|
7632
7632
|
}, [w]), Qr();
|
|
7633
7633
|
const O = f.useCallback(
|
|
7634
7634
|
(I) => {
|
|
7635
|
-
const [j, ...
|
|
7635
|
+
const [j, ...G] = V().map((z) => z.ref.current), [K] = G.slice(-1), Y = document.activeElement;
|
|
7636
7636
|
for (const z of I)
|
|
7637
|
-
if (z === Y || (z == null || z.scrollIntoView({ block: "nearest" }), z === j && A && (A.scrollTop = 0), z ===
|
|
7637
|
+
if (z === Y || (z == null || z.scrollIntoView({ block: "nearest" }), z === j && A && (A.scrollTop = 0), z === K && A && (A.scrollTop = A.scrollHeight), z == null || z.focus(), document.activeElement !== Y)) return;
|
|
7638
7638
|
},
|
|
7639
|
-
[
|
|
7639
|
+
[V, A]
|
|
7640
7640
|
), D = f.useCallback(
|
|
7641
7641
|
() => O([C, w]),
|
|
7642
7642
|
[O, C, w]
|
|
7643
7643
|
);
|
|
7644
7644
|
f.useEffect(() => {
|
|
7645
|
-
|
|
7646
|
-
}, [
|
|
7645
|
+
U && D();
|
|
7646
|
+
}, [U, D]);
|
|
7647
7647
|
const { onOpenChange: E, triggerPointerDownPosRef: P } = x;
|
|
7648
7648
|
f.useEffect(() => {
|
|
7649
7649
|
if (w) {
|
|
7650
7650
|
let I = { x: 0, y: 0 };
|
|
7651
|
-
const j = (
|
|
7651
|
+
const j = (K) => {
|
|
7652
7652
|
var Y, z;
|
|
7653
7653
|
I = {
|
|
7654
|
-
x: Math.abs(Math.round(
|
|
7655
|
-
y: Math.abs(Math.round(
|
|
7654
|
+
x: Math.abs(Math.round(K.pageX) - (((Y = P.current) == null ? void 0 : Y.x) ?? 0)),
|
|
7655
|
+
y: Math.abs(Math.round(K.pageY) - (((z = P.current) == null ? void 0 : z.y) ?? 0))
|
|
7656
7656
|
};
|
|
7657
|
-
},
|
|
7658
|
-
I.x <= 10 && I.y <= 10 ?
|
|
7657
|
+
}, G = (K) => {
|
|
7658
|
+
I.x <= 10 && I.y <= 10 ? K.preventDefault() : w.contains(K.target) || E(!1), document.removeEventListener("pointermove", j), P.current = null;
|
|
7659
7659
|
};
|
|
7660
|
-
return P.current !== null && (document.addEventListener("pointermove", j), document.addEventListener("pointerup",
|
|
7661
|
-
document.removeEventListener("pointermove", j), document.removeEventListener("pointerup",
|
|
7660
|
+
return P.current !== null && (document.addEventListener("pointermove", j), document.addEventListener("pointerup", G, { capture: !0, once: !0 })), () => {
|
|
7661
|
+
document.removeEventListener("pointermove", j), document.removeEventListener("pointerup", G, { capture: !0 });
|
|
7662
7662
|
};
|
|
7663
7663
|
}
|
|
7664
7664
|
}, [w, E, P]), f.useEffect(() => {
|
|
@@ -7668,18 +7668,18 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7668
7668
|
};
|
|
7669
7669
|
}, [E]);
|
|
7670
7670
|
const [q, te] = Gi((I) => {
|
|
7671
|
-
const j =
|
|
7672
|
-
|
|
7671
|
+
const j = V().filter((Y) => !Y.disabled), G = j.find((Y) => Y.ref.current === document.activeElement), K = Ki(j, I, G);
|
|
7672
|
+
K && setTimeout(() => K.ref.current.focus());
|
|
7673
7673
|
}), re = f.useCallback(
|
|
7674
|
-
(I, j,
|
|
7675
|
-
const
|
|
7676
|
-
(x.value !== void 0 && x.value === j ||
|
|
7674
|
+
(I, j, G) => {
|
|
7675
|
+
const K = !H.current && !G;
|
|
7676
|
+
(x.value !== void 0 && x.value === j || K) && (M(I), K && (H.current = !0));
|
|
7677
7677
|
},
|
|
7678
7678
|
[x.value]
|
|
7679
7679
|
), J = f.useCallback(() => w == null ? void 0 : w.focus(), [w]), Z = f.useCallback(
|
|
7680
|
-
(I, j,
|
|
7681
|
-
const
|
|
7682
|
-
(x.value !== void 0 && x.value === j ||
|
|
7680
|
+
(I, j, G) => {
|
|
7681
|
+
const K = !H.current && !G;
|
|
7682
|
+
(x.value !== void 0 && x.value === j || K) && F(I);
|
|
7683
7683
|
},
|
|
7684
7684
|
[x.value]
|
|
7685
7685
|
), le = o === "popper" ? oo : _i, ie = le === oo ? {
|
|
@@ -7708,7 +7708,7 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7708
7708
|
focusSelectedItem: D,
|
|
7709
7709
|
selectedItemText: N,
|
|
7710
7710
|
position: o,
|
|
7711
|
-
isPositioned:
|
|
7711
|
+
isPositioned: U,
|
|
7712
7712
|
searchRef: q,
|
|
7713
7713
|
children: /* @__PURE__ */ p(So, { as: Mp, allowPinchZoom: !0, children: /* @__PURE__ */ p(
|
|
7714
7714
|
po,
|
|
@@ -7741,7 +7741,7 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7741
7741
|
onContextMenu: (I) => I.preventDefault(),
|
|
7742
7742
|
...y,
|
|
7743
7743
|
...ie,
|
|
7744
|
-
onPlaced: () =>
|
|
7744
|
+
onPlaced: () => $(!0),
|
|
7745
7745
|
ref: R,
|
|
7746
7746
|
style: {
|
|
7747
7747
|
// flex layout so we can place the scroll buttons properly
|
|
@@ -7754,12 +7754,12 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7754
7754
|
onKeyDown: L(y.onKeyDown, (I) => {
|
|
7755
7755
|
const j = I.ctrlKey || I.altKey || I.metaKey;
|
|
7756
7756
|
if (I.key === "Tab" && I.preventDefault(), !j && I.key.length === 1 && te(I.key), ["ArrowUp", "ArrowDown", "Home", "End"].includes(I.key)) {
|
|
7757
|
-
let
|
|
7758
|
-
if (["ArrowUp", "End"].includes(I.key) && (
|
|
7759
|
-
const Y = I.target, z =
|
|
7760
|
-
|
|
7757
|
+
let K = V().filter((Y) => !Y.disabled).map((Y) => Y.ref.current);
|
|
7758
|
+
if (["ArrowUp", "End"].includes(I.key) && (K = K.slice().reverse()), ["ArrowUp", "ArrowDown"].includes(I.key)) {
|
|
7759
|
+
const Y = I.target, z = K.indexOf(Y);
|
|
7760
|
+
K = K.slice(z + 1);
|
|
7761
7761
|
}
|
|
7762
|
-
setTimeout(() => O(
|
|
7762
|
+
setTimeout(() => O(K)), I.preventDefault();
|
|
7763
7763
|
}
|
|
7764
7764
|
})
|
|
7765
7765
|
}
|
|
@@ -7774,11 +7774,11 @@ var Ee = 10, [Ni, je] = xt(ot), Pp = "SelectContentImpl", Mp = /* @__PURE__ */ P
|
|
|
7774
7774
|
);
|
|
7775
7775
|
ki.displayName = Pp;
|
|
7776
7776
|
var Np = "SelectItemAlignedPosition", _i = f.forwardRef((e, t) => {
|
|
7777
|
-
const { __scopeSelect: n, onPlaced: o, ...r } = e, s = Ke(ot, n), i = je(ot, n), [a, l] = f.useState(null), [c, d] = f.useState(null), u = ne(t, (R) => d(R)), h =
|
|
7777
|
+
const { __scopeSelect: n, onPlaced: o, ...r } = e, s = Ke(ot, n), i = je(ot, n), [a, l] = f.useState(null), [c, d] = f.useState(null), u = ne(t, (R) => d(R)), h = Rn(n), g = f.useRef(!1), b = f.useRef(!0), { viewport: m, selectedItem: v, selectedItemText: y, focusSelectedItem: x } = i, w = f.useCallback(() => {
|
|
7778
7778
|
if (s.trigger && s.valueNode && a && c && m && v && y) {
|
|
7779
7779
|
const R = s.trigger.getBoundingClientRect(), C = c.getBoundingClientRect(), M = s.valueNode.getBoundingClientRect(), N = y.getBoundingClientRect();
|
|
7780
7780
|
if (s.dir !== "rtl") {
|
|
7781
|
-
const Y = N.left - C.left, z = M.left - Y,
|
|
7781
|
+
const Y = N.left - C.left, z = M.left - Y, fe = R.left - z, ye = R.width + fe, Ye = Math.max(ye, C.width), Xe = window.innerWidth - Ee, qe = Er(z, [
|
|
7782
7782
|
Ee,
|
|
7783
7783
|
// Prevents the content from going off the starting edge of the
|
|
7784
7784
|
// viewport. It may still go off the ending edge, but this can be
|
|
@@ -7789,33 +7789,33 @@ var Np = "SelectItemAlignedPosition", _i = f.forwardRef((e, t) => {
|
|
|
7789
7789
|
]);
|
|
7790
7790
|
a.style.minWidth = ye + "px", a.style.left = qe + "px";
|
|
7791
7791
|
} else {
|
|
7792
|
-
const Y = C.right - N.right, z = window.innerWidth - M.right - Y,
|
|
7792
|
+
const Y = C.right - N.right, z = window.innerWidth - M.right - Y, fe = window.innerWidth - R.right - z, ye = R.width + fe, Ye = Math.max(ye, C.width), Xe = window.innerWidth - Ee, qe = Er(z, [
|
|
7793
7793
|
Ee,
|
|
7794
7794
|
Math.max(Ee, Xe - Ye)
|
|
7795
7795
|
]);
|
|
7796
7796
|
a.style.minWidth = ye + "px", a.style.right = qe + "px";
|
|
7797
7797
|
}
|
|
7798
|
-
const
|
|
7798
|
+
const F = h(), V = window.innerHeight - Ee * 2, U = m.scrollHeight, $ = window.getComputedStyle(c), H = parseInt($.borderTopWidth, 10), O = parseInt($.paddingTop, 10), D = parseInt($.borderBottomWidth, 10), E = parseInt($.paddingBottom, 10), P = H + O + U + E + D, q = Math.min(v.offsetHeight * 5, P), te = window.getComputedStyle(m), re = parseInt(te.paddingTop, 10), J = parseInt(te.paddingBottom, 10), Z = R.top + R.height / 2 - Ee, le = V - Z, ie = v.offsetHeight / 2, I = v.offsetTop + ie, j = H + O + I, G = P - j;
|
|
7799
7799
|
if (j <= Z) {
|
|
7800
|
-
const Y =
|
|
7800
|
+
const Y = F.length > 0 && v === F[F.length - 1].ref.current;
|
|
7801
7801
|
a.style.bottom = "0px";
|
|
7802
|
-
const z = c.clientHeight - m.offsetTop - m.offsetHeight,
|
|
7802
|
+
const z = c.clientHeight - m.offsetTop - m.offsetHeight, fe = Math.max(
|
|
7803
7803
|
le,
|
|
7804
7804
|
ie + // viewport might have padding bottom, include it to avoid a scrollable viewport
|
|
7805
7805
|
(Y ? J : 0) + z + D
|
|
7806
|
-
), ye = j +
|
|
7806
|
+
), ye = j + fe;
|
|
7807
7807
|
a.style.height = ye + "px";
|
|
7808
7808
|
} else {
|
|
7809
|
-
const Y =
|
|
7809
|
+
const Y = F.length > 0 && v === F[0].ref.current;
|
|
7810
7810
|
a.style.top = "0px";
|
|
7811
|
-
const
|
|
7811
|
+
const fe = Math.max(
|
|
7812
7812
|
Z,
|
|
7813
|
-
|
|
7813
|
+
H + m.offsetTop + // viewport might have padding top, include it to avoid a scrollable viewport
|
|
7814
7814
|
(Y ? re : 0) + ie
|
|
7815
|
-
) +
|
|
7816
|
-
a.style.height =
|
|
7815
|
+
) + G;
|
|
7816
|
+
a.style.height = fe + "px", m.scrollTop = j - Z + m.offsetTop;
|
|
7817
7817
|
}
|
|
7818
|
-
a.style.margin = `${Ee}px 0`, a.style.minHeight = q + "px", a.style.maxHeight =
|
|
7818
|
+
a.style.margin = `${Ee}px 0`, a.style.minHeight = q + "px", a.style.maxHeight = V + "px", o == null || o(), requestAnimationFrame(() => g.current = !0);
|
|
7819
7819
|
}
|
|
7820
7820
|
}, [
|
|
7821
7821
|
h,
|
|
@@ -7829,9 +7829,9 @@ var Np = "SelectItemAlignedPosition", _i = f.forwardRef((e, t) => {
|
|
|
7829
7829
|
s.dir,
|
|
7830
7830
|
o
|
|
7831
7831
|
]);
|
|
7832
|
-
|
|
7832
|
+
ue(() => w(), [w]);
|
|
7833
7833
|
const [S, A] = f.useState();
|
|
7834
|
-
|
|
7834
|
+
ue(() => {
|
|
7835
7835
|
c && A(window.getComputedStyle(c).zIndex);
|
|
7836
7836
|
}, [c]);
|
|
7837
7837
|
const T = f.useCallback(
|
|
@@ -7884,7 +7884,7 @@ var kp = "SelectPopperPosition", oo = f.forwardRef((e, t) => {
|
|
|
7884
7884
|
align: o = "start",
|
|
7885
7885
|
collisionPadding: r = Ee,
|
|
7886
7886
|
...s
|
|
7887
|
-
} = e, i =
|
|
7887
|
+
} = e, i = An(n);
|
|
7888
7888
|
return /* @__PURE__ */ p(
|
|
7889
7889
|
Es,
|
|
7890
7890
|
{
|
|
@@ -7910,7 +7910,7 @@ oo.displayName = kp;
|
|
|
7910
7910
|
var [_p, No] = xt(ot, {}), ro = "SelectViewport", Oi = f.forwardRef(
|
|
7911
7911
|
(e, t) => {
|
|
7912
7912
|
const { __scopeSelect: n, nonce: o, ...r } = e, s = je(ro, n), i = No(ro, n), a = ne(t, s.onViewportChange), l = f.useRef(0);
|
|
7913
|
-
return /* @__PURE__ */ B(
|
|
7913
|
+
return /* @__PURE__ */ B(un, { children: [
|
|
7914
7914
|
/* @__PURE__ */ p(
|
|
7915
7915
|
"style",
|
|
7916
7916
|
{
|
|
@@ -7920,7 +7920,7 @@ var [_p, No] = xt(ot, {}), ro = "SelectViewport", Oi = f.forwardRef(
|
|
|
7920
7920
|
nonce: o
|
|
7921
7921
|
}
|
|
7922
7922
|
),
|
|
7923
|
-
/* @__PURE__ */ p(
|
|
7923
|
+
/* @__PURE__ */ p(En.Slot, { scope: n, children: /* @__PURE__ */ p(
|
|
7924
7924
|
X.div,
|
|
7925
7925
|
{
|
|
7926
7926
|
"data-radix-select-viewport": "",
|
|
@@ -7974,7 +7974,7 @@ var Li = "SelectLabel", Fp = f.forwardRef(
|
|
|
7974
7974
|
}
|
|
7975
7975
|
);
|
|
7976
7976
|
Fp.displayName = Li;
|
|
7977
|
-
var
|
|
7977
|
+
var ln = "SelectItem", [$p, Fi] = xt(ln), $i = f.forwardRef(
|
|
7978
7978
|
(e, t) => {
|
|
7979
7979
|
const {
|
|
7980
7980
|
__scopeSelect: n,
|
|
@@ -7982,7 +7982,7 @@ var un = "SelectItem", [$p, Fi] = xt(un), $i = f.forwardRef(
|
|
|
7982
7982
|
disabled: r = !1,
|
|
7983
7983
|
textValue: s,
|
|
7984
7984
|
...i
|
|
7985
|
-
} = e, a = Ke(
|
|
7985
|
+
} = e, a = Ke(ln, n), l = je(ln, n), c = a.value === o, [d, u] = f.useState(s ?? ""), [h, g] = f.useState(!1), b = ne(
|
|
7986
7986
|
t,
|
|
7987
7987
|
(x) => {
|
|
7988
7988
|
var w;
|
|
@@ -8007,7 +8007,7 @@ var un = "SelectItem", [$p, Fi] = xt(un), $i = f.forwardRef(
|
|
|
8007
8007
|
u((w) => w || ((x == null ? void 0 : x.textContent) ?? "").trim());
|
|
8008
8008
|
}, []),
|
|
8009
8009
|
children: /* @__PURE__ */ p(
|
|
8010
|
-
|
|
8010
|
+
En.ItemSlot,
|
|
8011
8011
|
{
|
|
8012
8012
|
scope: n,
|
|
8013
8013
|
value: o,
|
|
@@ -8057,7 +8057,7 @@ var un = "SelectItem", [$p, Fi] = xt(un), $i = f.forwardRef(
|
|
|
8057
8057
|
);
|
|
8058
8058
|
}
|
|
8059
8059
|
);
|
|
8060
|
-
$i.displayName =
|
|
8060
|
+
$i.displayName = ln;
|
|
8061
8061
|
var At = "SelectItemText", Vi = f.forwardRef(
|
|
8062
8062
|
(e, t) => {
|
|
8063
8063
|
const { __scopeSelect: n, className: o, style: r, ...s } = e, i = Ke(At, n), a = je(At, n), l = Fi(At, n), c = Ap(At, n), [d, u] = f.useState(null), h = ne(
|
|
@@ -8072,9 +8072,9 @@ var At = "SelectItemText", Vi = f.forwardRef(
|
|
|
8072
8072
|
() => /* @__PURE__ */ p("option", { value: l.value, disabled: l.disabled, children: g }, l.value),
|
|
8073
8073
|
[l.disabled, l.value, g]
|
|
8074
8074
|
), { onNativeOptionAdd: m, onNativeOptionRemove: v } = c;
|
|
8075
|
-
return
|
|
8075
|
+
return ue(() => (m(b), () => v(b)), [m, v, b]), /* @__PURE__ */ B(un, { children: [
|
|
8076
8076
|
/* @__PURE__ */ p(X.span, { id: l.textId, ...s, ref: h }),
|
|
8077
|
-
l.isSelected && i.valueNode && !i.valueNodeHasChildren ?
|
|
8077
|
+
l.isSelected && i.valueNode && !i.valueNodeHasChildren ? dn.createPortal(s.children, i.valueNode) : null
|
|
8078
8078
|
] });
|
|
8079
8079
|
}
|
|
8080
8080
|
);
|
|
@@ -8088,7 +8088,7 @@ var Ui = "SelectItemIndicator", Bi = f.forwardRef(
|
|
|
8088
8088
|
Bi.displayName = Ui;
|
|
8089
8089
|
var so = "SelectScrollUpButton", Vp = f.forwardRef((e, t) => {
|
|
8090
8090
|
const n = je(so, e.__scopeSelect), o = No(so, e.__scopeSelect), [r, s] = f.useState(!1), i = ne(t, o.onScrollButtonChange);
|
|
8091
|
-
return
|
|
8091
|
+
return ue(() => {
|
|
8092
8092
|
if (n.viewport && n.isPositioned) {
|
|
8093
8093
|
let a = function() {
|
|
8094
8094
|
const c = l.scrollTop > 0;
|
|
@@ -8112,7 +8112,7 @@ var so = "SelectScrollUpButton", Vp = f.forwardRef((e, t) => {
|
|
|
8112
8112
|
Vp.displayName = so;
|
|
8113
8113
|
var io = "SelectScrollDownButton", Up = f.forwardRef((e, t) => {
|
|
8114
8114
|
const n = je(io, e.__scopeSelect), o = No(io, e.__scopeSelect), [r, s] = f.useState(!1), i = ne(t, o.onScrollButtonChange);
|
|
8115
|
-
return
|
|
8115
|
+
return ue(() => {
|
|
8116
8116
|
if (n.viewport && n.isPositioned) {
|
|
8117
8117
|
let a = function() {
|
|
8118
8118
|
const c = l.scrollHeight - l.clientHeight, d = Math.ceil(l.scrollTop) < c;
|
|
@@ -8135,10 +8135,10 @@ var io = "SelectScrollDownButton", Up = f.forwardRef((e, t) => {
|
|
|
8135
8135
|
});
|
|
8136
8136
|
Up.displayName = io;
|
|
8137
8137
|
var zi = f.forwardRef((e, t) => {
|
|
8138
|
-
const { __scopeSelect: n, onAutoScroll: o, ...r } = e, s = je("SelectScrollButton", n), i = f.useRef(null), a =
|
|
8138
|
+
const { __scopeSelect: n, onAutoScroll: o, ...r } = e, s = je("SelectScrollButton", n), i = f.useRef(null), a = Rn(n), l = f.useCallback(() => {
|
|
8139
8139
|
i.current !== null && (window.clearInterval(i.current), i.current = null);
|
|
8140
8140
|
}, []);
|
|
8141
|
-
return f.useEffect(() => () => l(), [l]),
|
|
8141
|
+
return f.useEffect(() => () => l(), [l]), ue(() => {
|
|
8142
8142
|
var d;
|
|
8143
8143
|
const c = a().find((u) => u.ref.current === document.activeElement);
|
|
8144
8144
|
(d = c == null ? void 0 : c.ref.current) == null || d.scrollIntoView({ block: "nearest" });
|
|
@@ -8170,7 +8170,7 @@ var zi = f.forwardRef((e, t) => {
|
|
|
8170
8170
|
zp.displayName = Bp;
|
|
8171
8171
|
var ao = "SelectArrow", Wp = f.forwardRef(
|
|
8172
8172
|
(e, t) => {
|
|
8173
|
-
const { __scopeSelect: n, ...o } = e, r =
|
|
8173
|
+
const { __scopeSelect: n, ...o } = e, r = An(n), s = Ke(ao, n), i = je(ao, n);
|
|
8174
8174
|
return s.open && i.position === "popper" ? /* @__PURE__ */ p(Rs, { ...r, ...o, ref: t }) : null;
|
|
8175
8175
|
}
|
|
8176
8176
|
);
|
|
@@ -8236,7 +8236,7 @@ function im({ value: e, onValueChange: t, children: n }) {
|
|
|
8236
8236
|
return /* @__PURE__ */ p(Kp, { value: e, onValueChange: t, children: n });
|
|
8237
8237
|
}
|
|
8238
8238
|
function am({ className: e, children: t }) {
|
|
8239
|
-
const n =
|
|
8239
|
+
const n = de();
|
|
8240
8240
|
return /* @__PURE__ */ B(jp, { className: ee(nm, n.select.trigger, e), children: [
|
|
8241
8241
|
t,
|
|
8242
8242
|
/* @__PURE__ */ p(Xp, { asChild: !0, children: /* @__PURE__ */ p(Ma, { className: "h-4 w-4 opacity-50" }) })
|
|
@@ -8246,7 +8246,7 @@ function cm({ placeholder: e }) {
|
|
|
8246
8246
|
return /* @__PURE__ */ p(Yp, { placeholder: e });
|
|
8247
8247
|
}
|
|
8248
8248
|
function lm({ children: e }) {
|
|
8249
|
-
const t =
|
|
8249
|
+
const t = de();
|
|
8250
8250
|
return /* @__PURE__ */ p(qp, { children: /* @__PURE__ */ p(
|
|
8251
8251
|
Zp,
|
|
8252
8252
|
{
|
|
@@ -8258,7 +8258,7 @@ function lm({ children: e }) {
|
|
|
8258
8258
|
) });
|
|
8259
8259
|
}
|
|
8260
8260
|
function um({ value: e, children: t }) {
|
|
8261
|
-
const n =
|
|
8261
|
+
const n = de();
|
|
8262
8262
|
return /* @__PURE__ */ B(
|
|
8263
8263
|
Qp,
|
|
8264
8264
|
{
|
|
@@ -8277,7 +8277,7 @@ const Ie = {
|
|
|
8277
8277
|
Value: cm,
|
|
8278
8278
|
Content: lm,
|
|
8279
8279
|
Item: um
|
|
8280
|
-
},
|
|
8280
|
+
}, Tn = [25, 50, 100];
|
|
8281
8281
|
function dm({ table: e, isLoading: t }) {
|
|
8282
8282
|
return /* @__PURE__ */ p("div", { className: "flex items-center justify-center px-2 py-4", children: /* @__PURE__ */ B("div", { className: "flex items-center gap-2", children: [
|
|
8283
8283
|
/* @__PURE__ */ p(
|
|
@@ -8327,7 +8327,7 @@ function dm({ table: e, isLoading: t }) {
|
|
|
8327
8327
|
}
|
|
8328
8328
|
function fm({
|
|
8329
8329
|
table: e,
|
|
8330
|
-
paginationSizes: t =
|
|
8330
|
+
paginationSizes: t = Tn,
|
|
8331
8331
|
enableElementLabel: n = !0
|
|
8332
8332
|
}) {
|
|
8333
8333
|
const { t: o } = ht();
|
|
@@ -8348,9 +8348,9 @@ function fm({
|
|
|
8348
8348
|
)
|
|
8349
8349
|
] });
|
|
8350
8350
|
}
|
|
8351
|
-
var
|
|
8352
|
-
|
|
8353
|
-
]), ji =
|
|
8351
|
+
var In = "Tabs", [pm] = rt(In, [
|
|
8352
|
+
wn
|
|
8353
|
+
]), ji = wn(), [mm, ko] = pm(In), Yi = f.forwardRef(
|
|
8354
8354
|
(e, t) => {
|
|
8355
8355
|
const {
|
|
8356
8356
|
__scopeTabs: n,
|
|
@@ -8361,11 +8361,11 @@ var Pn = "Tabs", [pm] = rt(Pn, [
|
|
|
8361
8361
|
dir: a,
|
|
8362
8362
|
activationMode: l = "automatic",
|
|
8363
8363
|
...c
|
|
8364
|
-
} = e, d =
|
|
8364
|
+
} = e, d = pn(a), [u, h] = It({
|
|
8365
8365
|
prop: o,
|
|
8366
8366
|
onChange: r,
|
|
8367
8367
|
defaultProp: s ?? "",
|
|
8368
|
-
caller:
|
|
8368
|
+
caller: In
|
|
8369
8369
|
});
|
|
8370
8370
|
return /* @__PURE__ */ p(
|
|
8371
8371
|
mm,
|
|
@@ -8390,7 +8390,7 @@ var Pn = "Tabs", [pm] = rt(Pn, [
|
|
|
8390
8390
|
);
|
|
8391
8391
|
}
|
|
8392
8392
|
);
|
|
8393
|
-
Yi.displayName =
|
|
8393
|
+
Yi.displayName = In;
|
|
8394
8394
|
var Xi = "TabsList", qi = f.forwardRef(
|
|
8395
8395
|
(e, t) => {
|
|
8396
8396
|
const { __scopeTabs: n, loop: o = !0, ...r } = e, s = ko(Xi, n), i = ji(n);
|
|
@@ -8496,11 +8496,11 @@ function xm({ value: e, onValueChange: t, children: n }) {
|
|
|
8496
8496
|
return /* @__PURE__ */ p(gm, { value: e, onValueChange: t, children: n });
|
|
8497
8497
|
}
|
|
8498
8498
|
function Cm({ children: e, className: t }) {
|
|
8499
|
-
const n =
|
|
8499
|
+
const n = de();
|
|
8500
8500
|
return /* @__PURE__ */ p(vm, { className: ee(wm, n.tabs.list, t), children: e });
|
|
8501
8501
|
}
|
|
8502
8502
|
function Sm({ value: e, children: t }) {
|
|
8503
|
-
const n =
|
|
8503
|
+
const n = de();
|
|
8504
8504
|
return /* @__PURE__ */ p(
|
|
8505
8505
|
bm,
|
|
8506
8506
|
{
|
|
@@ -8510,22 +8510,22 @@ function Sm({ value: e, children: t }) {
|
|
|
8510
8510
|
}
|
|
8511
8511
|
);
|
|
8512
8512
|
}
|
|
8513
|
-
const
|
|
8513
|
+
const Wn = {
|
|
8514
8514
|
Root: xm,
|
|
8515
8515
|
List: Cm,
|
|
8516
8516
|
Trigger: Sm
|
|
8517
8517
|
};
|
|
8518
8518
|
function Em({ prefilters: e, activePrefilter: t, onPrefilterChange: n }) {
|
|
8519
8519
|
var l;
|
|
8520
|
-
const o = Nc(), { t: r } = ht(), s =
|
|
8520
|
+
const o = Nc(), { t: r } = ht(), s = de(), i = e.find((c) => c.id === t), a = e.length > 0 && t !== ((l = e[0]) == null ? void 0 : l.id);
|
|
8521
8521
|
return o || e.length > 4 ? /* @__PURE__ */ B(Ie.Root, { value: t, onValueChange: n, children: [
|
|
8522
8522
|
/* @__PURE__ */ p(Ie.Trigger, { className: `w-fit min-w-32 ${a ? s.state.active : ""}`, children: /* @__PURE__ */ p(Ie.Value, { children: (i == null ? void 0 : i.label) || r("dataTable.selectFilter") }) }),
|
|
8523
8523
|
/* @__PURE__ */ p(Ie.Content, { children: e.map((c) => /* @__PURE__ */ p(Ie.Item, { value: c.id, children: c.label }, c.id)) })
|
|
8524
|
-
] }) : /* @__PURE__ */ p(
|
|
8524
|
+
] }) : /* @__PURE__ */ p(Wn.Root, { value: t, onValueChange: n, children: /* @__PURE__ */ p(Wn.List, { className: a ? s.state.active : "", children: e.map((c) => /* @__PURE__ */ p(Wn.Trigger, { value: c.id, children: c.label }, c.id)) }) });
|
|
8525
8525
|
}
|
|
8526
8526
|
const Rm = "flex h-9 w-full min-w-0 px-3 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50", _o = Ar(
|
|
8527
8527
|
({ value: e, onChange: t, onKeyDown: n, placeholder: o, className: r, type: s = "text", isActive: i, ...a }, l) => {
|
|
8528
|
-
const c =
|
|
8528
|
+
const c = de();
|
|
8529
8529
|
return /* @__PURE__ */ p(
|
|
8530
8530
|
"input",
|
|
8531
8531
|
{
|
|
@@ -8544,7 +8544,7 @@ const Rm = "flex h-9 w-full min-w-0 px-3 py-1 text-sm shadow-xs transition-[colo
|
|
|
8544
8544
|
_o.displayName = "Input";
|
|
8545
8545
|
const Am = 500;
|
|
8546
8546
|
function Tm({ value: e = "", onDebouncedChange: t, placeholder: n }) {
|
|
8547
|
-
const o =
|
|
8547
|
+
const o = de(), [r, s] = ge(e);
|
|
8548
8548
|
Tt(() => {
|
|
8549
8549
|
s(e);
|
|
8550
8550
|
}, [e]), Tt(() => {
|
|
@@ -8574,7 +8574,7 @@ function Im({
|
|
|
8574
8574
|
selectedValues: t = [],
|
|
8575
8575
|
onFilterChange: n
|
|
8576
8576
|
}) {
|
|
8577
|
-
const { t: o } = ht(), r =
|
|
8577
|
+
const { t: o } = ht(), r = de(), [s, i] = ge(""), a = t.length, l = Pe(() => t.map((g) => {
|
|
8578
8578
|
var b;
|
|
8579
8579
|
return (b = e.options.find((m) => m.value === g)) == null ? void 0 : b.label;
|
|
8580
8580
|
}).filter(Boolean), [t, e.options]), c = Pe(() => {
|
|
@@ -8593,9 +8593,11 @@ function Im({
|
|
|
8593
8593
|
if (e.options.length === 0) return null;
|
|
8594
8594
|
const h = () => a === 0 ? e.label : a === 1 ? l[0] : a === 2 ? l.join(", ") : `${l.slice(0, 2).join(", ")} +${a - 2}`;
|
|
8595
8595
|
return /* @__PURE__ */ B(ce.Root, { children: [
|
|
8596
|
-
/* @__PURE__ */ p(ce.Trigger, { asChild: !0, children: /* @__PURE__ */ B(Me, { className: `gap-1.5
|
|
8597
|
-
/* @__PURE__ */
|
|
8598
|
-
|
|
8596
|
+
/* @__PURE__ */ p(ce.Trigger, { asChild: !0, children: /* @__PURE__ */ B(Me, { className: `gap-1.5 w-full justify-between ${a > 0 ? r.state.active : ""}`, children: [
|
|
8597
|
+
/* @__PURE__ */ B("div", { className: "flex items-center gap-1.5 min-w-0", children: [
|
|
8598
|
+
/* @__PURE__ */ p(Aa, { className: `h-4 w-4 shrink-0 ${a > 0 ? r.state.activeText : ""}` }),
|
|
8599
|
+
/* @__PURE__ */ p("span", { className: "truncate", children: h() })
|
|
8600
|
+
] }),
|
|
8599
8601
|
/* @__PURE__ */ p(co, { className: "h-3.5 w-3.5 opacity-50 shrink-0" })
|
|
8600
8602
|
] }) }),
|
|
8601
8603
|
/* @__PURE__ */ B(ce.Content, { align: "start", className: "w-56", children: [
|
|
@@ -8624,16 +8626,16 @@ function Im({
|
|
|
8624
8626
|
},
|
|
8625
8627
|
g.value
|
|
8626
8628
|
)),
|
|
8627
|
-
a > 0 && /* @__PURE__ */ B(
|
|
8629
|
+
a > 0 && /* @__PURE__ */ B(un, { children: [
|
|
8628
8630
|
/* @__PURE__ */ p(ce.Separator, {}),
|
|
8629
8631
|
/* @__PURE__ */ p(ce.Item, { onClick: u, className: "text-xs cursor-pointer", children: o("dataTable.resetFilters") })
|
|
8630
8632
|
] })
|
|
8631
8633
|
] })
|
|
8632
8634
|
] });
|
|
8633
8635
|
}
|
|
8634
|
-
const
|
|
8636
|
+
const Hn = "h-[15px] w-[15px] text-black";
|
|
8635
8637
|
function Pm({ column: e }) {
|
|
8636
|
-
return e.getCanSort() === !1 ? null : e.getIsSorted() ? e.getIsSorted() === "desc" ? /* @__PURE__ */ p(co, { className:
|
|
8638
|
+
return e.getCanSort() === !1 ? null : e.getIsSorted() ? e.getIsSorted() === "desc" ? /* @__PURE__ */ p(co, { className: Hn }) : /* @__PURE__ */ p(ya, { className: Hn }) : /* @__PURE__ */ p(Ra, { className: Hn });
|
|
8637
8639
|
}
|
|
8638
8640
|
function na({
|
|
8639
8641
|
// Data
|
|
@@ -8672,26 +8674,26 @@ function na({
|
|
|
8672
8674
|
activeRowId: C,
|
|
8673
8675
|
displayTotalNumber: M = !0,
|
|
8674
8676
|
enableElementLabel: N = !0,
|
|
8675
|
-
enablePagination:
|
|
8676
|
-
|
|
8677
|
-
|
|
8677
|
+
enablePagination: F = !0,
|
|
8678
|
+
paginationSizes: V,
|
|
8679
|
+
enableResponsive: U = !0,
|
|
8680
|
+
texts: $,
|
|
8678
8681
|
// Reset
|
|
8679
|
-
onResetFilters:
|
|
8680
|
-
enableResetFilters: K = !0
|
|
8682
|
+
onResetFilters: H
|
|
8681
8683
|
}) {
|
|
8682
8684
|
var Do;
|
|
8683
|
-
const { t: O } = ht(), D =
|
|
8685
|
+
const { t: O } = ht(), D = de(), [E, P] = ge({
|
|
8684
8686
|
pageIndex: 0,
|
|
8685
|
-
pageSize:
|
|
8686
|
-
}), [q, te] = ge(""), [re, J] = ge({}), [Z, le] = ge([]), [ie, I] = ge({}), j = s ?? E,
|
|
8687
|
+
pageSize: Tn[0]
|
|
8688
|
+
}), [q, te] = ge(""), [re, J] = ge({}), [Z, le] = ge([]), [ie, I] = ge({}), j = s ?? E, G = i ?? P, K = l ?? q, Y = c ?? te, z = h ?? re, fe = g ?? J, ye = y ?? Z, Ye = x ?? le, Xe = S ?? ie, qe = A ?? I, Pn = We(
|
|
8687
8689
|
(Q) => {
|
|
8688
|
-
Y(Q),
|
|
8690
|
+
Y(Q), G((oe) => ({ ...oe, pageIndex: 0 }));
|
|
8689
8691
|
},
|
|
8690
|
-
[Y,
|
|
8692
|
+
[Y, G]
|
|
8691
8693
|
), at = Pe(() => JSON.stringify(z), [z]);
|
|
8692
8694
|
Tt(() => {
|
|
8693
|
-
|
|
8694
|
-
}, [m, at,
|
|
8695
|
+
G((Q) => Q.pageIndex === 0 ? Q : { ...Q, pageIndex: 0 });
|
|
8696
|
+
}, [m, at, G]);
|
|
8695
8697
|
const xe = r === "server", ra = a !== void 0 ? Math.ceil(a / j.pageSize) : void 0, sa = !xe || a !== void 0, ia = Pe(() => Object.entries(z).map(([Q, oe]) => ({ id: Q, value: oe })), [z]), aa = We((Q, oe, ae) => {
|
|
8696
8698
|
const Ce = Q.getValue(oe);
|
|
8697
8699
|
return ae.includes(String(Ce));
|
|
@@ -8702,11 +8704,11 @@ function na({
|
|
|
8702
8704
|
state: {
|
|
8703
8705
|
pagination: j,
|
|
8704
8706
|
sorting: w ? ye : void 0,
|
|
8705
|
-
globalFilter: !xe && d ?
|
|
8707
|
+
globalFilter: !xe && d ? K : void 0,
|
|
8706
8708
|
columnFilters: !xe && (u != null && u.length) ? ia : void 0,
|
|
8707
8709
|
columnVisibility: T ? Xe : void 0
|
|
8708
8710
|
},
|
|
8709
|
-
onPaginationChange:
|
|
8711
|
+
onPaginationChange: G,
|
|
8710
8712
|
onSortingChange: w ? Ye : void 0,
|
|
8711
8713
|
onColumnVisibilityChange: T ? qe : void 0,
|
|
8712
8714
|
// Manual modes (when pageCount is provided)
|
|
@@ -8716,7 +8718,7 @@ function na({
|
|
|
8716
8718
|
// Row models
|
|
8717
8719
|
getCoreRowModel: wa(),
|
|
8718
8720
|
getSortedRowModel: ba(),
|
|
8719
|
-
getPaginationRowModel:
|
|
8721
|
+
getPaginationRowModel: F ? va() : void 0,
|
|
8720
8722
|
// Client-side filtering (only when not in manual mode)
|
|
8721
8723
|
...!xe && (u != null && u.length || d) ? {
|
|
8722
8724
|
getFilteredRowModel: ga(),
|
|
@@ -8727,12 +8729,12 @@ function na({
|
|
|
8727
8729
|
} : {}
|
|
8728
8730
|
}), ca = (Q, oe) => {
|
|
8729
8731
|
const ae = String(Q), Ce = { ...z };
|
|
8730
|
-
oe.length === 0 ? delete Ce[ae] : Ce[ae] = oe,
|
|
8732
|
+
oe.length === 0 ? delete Ce[ae] : Ce[ae] = oe, fe(Ce);
|
|
8731
8733
|
}, la = d || M || u && u.length > 0 || T, Oo = Pe(() => xe ? e.length : Le.getRowModel().rows.length, [xe, e.length, Le]), ua = Pe(() => xe && a !== void 0 ? a : Le.getFilteredRowModel().rows.length, [xe, a, Le]);
|
|
8732
|
-
return /* @__PURE__ */ B("div", { className: ee("relative flex flex-col flex-1", D.table.root), "data-testid": "datatable", children: [
|
|
8734
|
+
return /* @__PURE__ */ B("div", { className: ee("snow-table-container relative flex flex-col flex-1", D.table.root), "data-testid": "datatable", children: [
|
|
8733
8735
|
o && !n && /* @__PURE__ */ p("div", { className: ee("absolute inset-0 z-10 pointer-events-none", D.table.loadingOverlay) }),
|
|
8734
|
-
la && /* @__PURE__ */ B("div", { className: "
|
|
8735
|
-
/* @__PURE__ */ p("div", { className: "flex items-center gap-2", children: b && b.length > 0 && v && /* @__PURE__ */ p(
|
|
8736
|
+
la && /* @__PURE__ */ B("div", { className: "snow-table-top-bar grid grid-cols-1 lg:grid-cols-[auto_1fr_auto] py-4 gap-4 items-center", children: [
|
|
8737
|
+
/* @__PURE__ */ p("div", { className: "snow-table-prefilters flex items-center gap-2", children: b && b.length > 0 && v && /* @__PURE__ */ p(
|
|
8736
8738
|
Em,
|
|
8737
8739
|
{
|
|
8738
8740
|
prefilters: b,
|
|
@@ -8740,15 +8742,15 @@ function na({
|
|
|
8740
8742
|
onPrefilterChange: v
|
|
8741
8743
|
}
|
|
8742
8744
|
) }),
|
|
8743
|
-
/* @__PURE__ */ p("div", { className: "
|
|
8745
|
+
/* @__PURE__ */ p("div", { className: "snow-table-search flex justify-center", children: d && /* @__PURE__ */ p("div", { className: "w-full max-w-sm", children: /* @__PURE__ */ p(
|
|
8744
8746
|
Tm,
|
|
8745
8747
|
{
|
|
8746
|
-
value:
|
|
8747
|
-
onDebouncedChange:
|
|
8748
|
-
placeholder: (
|
|
8748
|
+
value: K,
|
|
8749
|
+
onDebouncedChange: Pn,
|
|
8750
|
+
placeholder: ($ == null ? void 0 : $.searchPlaceholder) || O("dataTable.search")
|
|
8749
8751
|
}
|
|
8750
8752
|
) }) }),
|
|
8751
|
-
/* @__PURE__ */ B("div", { className: "flex
|
|
8753
|
+
/* @__PURE__ */ B("div", { className: "snow-table-filters grid grid-cols-1 sm:flex sm:flex-row gap-2 items-center", children: [
|
|
8752
8754
|
u == null ? void 0 : u.map((Q) => /* @__PURE__ */ p(
|
|
8753
8755
|
Im,
|
|
8754
8756
|
{
|
|
@@ -8758,16 +8760,18 @@ function na({
|
|
|
8758
8760
|
},
|
|
8759
8761
|
String(Q.key)
|
|
8760
8762
|
)),
|
|
8761
|
-
|
|
8762
|
-
|
|
8763
|
-
|
|
8764
|
-
|
|
8765
|
-
|
|
8766
|
-
|
|
8767
|
-
|
|
8768
|
-
|
|
8769
|
-
|
|
8770
|
-
|
|
8763
|
+
/* @__PURE__ */ B("div", { className: "snow-table-actions flex items-center gap-2 justify-end lg:justify-start", children: [
|
|
8764
|
+
T && /* @__PURE__ */ p(gp, { table: Le }),
|
|
8765
|
+
(d || b && b.length > 0 || u && u.length > 0) && H && /* @__PURE__ */ p(
|
|
8766
|
+
Me,
|
|
8767
|
+
{
|
|
8768
|
+
onClick: H,
|
|
8769
|
+
title: O("dataTable.resetFilters"),
|
|
8770
|
+
"data-testid": "datatable-reset-filters",
|
|
8771
|
+
children: /* @__PURE__ */ p(Ta, { className: "h-4 w-4" })
|
|
8772
|
+
}
|
|
8773
|
+
)
|
|
8774
|
+
] })
|
|
8771
8775
|
] })
|
|
8772
8776
|
] }),
|
|
8773
8777
|
/* @__PURE__ */ p(
|
|
@@ -8776,10 +8780,10 @@ function na({
|
|
|
8776
8780
|
className: ee(
|
|
8777
8781
|
"sm:overflow-x-auto",
|
|
8778
8782
|
D.table.container,
|
|
8779
|
-
|
|
8783
|
+
U && Be.container.base
|
|
8780
8784
|
),
|
|
8781
8785
|
children: /* @__PURE__ */ B("table", { className: ee("w-full text-sm"), "data-testid": "datatable-table", children: [
|
|
8782
|
-
/* @__PURE__ */ p("thead", { className: ee(D.table.header,
|
|
8786
|
+
/* @__PURE__ */ p("thead", { className: ee(D.table.header, U && Be.thead.base), children: Le.getHeaderGroups().map((Q) => /* @__PURE__ */ p("tr", { children: Q.headers.map((oe) => {
|
|
8783
8787
|
var ae, Ce, $t, Vt;
|
|
8784
8788
|
return /* @__PURE__ */ p(
|
|
8785
8789
|
"th",
|
|
@@ -8805,7 +8809,7 @@ function na({
|
|
|
8805
8809
|
n ? /* @__PURE__ */ p("tbody", { className: D.table.divider, "data-testid": "datatable-loading", children: Array.from({ length: j.pageSize > 10 ? 10 : j.pageSize }).map((Q, oe) => /* @__PURE__ */ p("tr", { className: ee({ [D.table.rowAlternate]: oe % 2 === 1 }), children: t.map((ae, Ce) => /* @__PURE__ */ p("td", { className: "px-4 py-3 align-middle", children: /* @__PURE__ */ p(vp, { className: "h-4 w-full" }) }, `skeleton-table-${Ce}`)) }, oe)) }) : Oo > 0 ? /* @__PURE__ */ p(
|
|
8806
8810
|
"tbody",
|
|
8807
8811
|
{
|
|
8808
|
-
className: ee(D.table.divider,
|
|
8812
|
+
className: ee(D.table.divider, U && Be.tbody.base),
|
|
8809
8813
|
"data-testid": "datatable-body",
|
|
8810
8814
|
children: Le.getRowModel().rows.map((Q, oe) => /* @__PURE__ */ p(
|
|
8811
8815
|
"tr",
|
|
@@ -8819,7 +8823,7 @@ function na({
|
|
|
8819
8823
|
[D.table.rowAlternate]: oe % 2 === 1,
|
|
8820
8824
|
[D.table.rowActive]: C !== void 0 && "id" in Q.original && C === Q.original.id
|
|
8821
8825
|
},
|
|
8822
|
-
|
|
8826
|
+
U && Be.row.base
|
|
8823
8827
|
),
|
|
8824
8828
|
children: Q.getVisibleCells().map((ae, Ce) => {
|
|
8825
8829
|
var Lo, Fo, $o, Vo;
|
|
@@ -8834,11 +8838,11 @@ function na({
|
|
|
8834
8838
|
className: ee(
|
|
8835
8839
|
R && !((Fo = (Lo = ae.column.columnDef) == null ? void 0 : Lo.meta) != null && Fo.disableColumnClick) && "cursor-pointer",
|
|
8836
8840
|
((Vo = ($o = ae.column.columnDef) == null ? void 0 : $o.meta) == null ? void 0 : Vo.center) && "align-middle text-center",
|
|
8837
|
-
|
|
8841
|
+
U ? ee(Be.cell.base, Vt && Be.cell.last) : "px-4 py-3"
|
|
8838
8842
|
),
|
|
8839
8843
|
children: [
|
|
8840
|
-
|
|
8841
|
-
/* @__PURE__ */ p("span", { className: ee(
|
|
8844
|
+
U && /* @__PURE__ */ p("span", { className: Be.cellLabel.base, children: $t }),
|
|
8845
|
+
/* @__PURE__ */ p("span", { className: ee(U && Be.cellContent.base), children: zo(ae.column.columnDef.cell, ae.getContext()) })
|
|
8842
8846
|
]
|
|
8843
8847
|
},
|
|
8844
8848
|
ae.id
|
|
@@ -8853,16 +8857,16 @@ function na({
|
|
|
8853
8857
|
{
|
|
8854
8858
|
className: ee("h-24 flex items-center justify-center w-full pl-10", D.table.empty),
|
|
8855
8859
|
"data-testid": "datatable-empty",
|
|
8856
|
-
children: (
|
|
8860
|
+
children: ($ == null ? void 0 : $.emptyTitle) || O("dataTable.searchEmpty")
|
|
8857
8861
|
}
|
|
8858
8862
|
)
|
|
8859
8863
|
] })
|
|
8860
8864
|
}
|
|
8861
8865
|
),
|
|
8862
|
-
/* @__PURE__ */ B("div", { className: "
|
|
8863
|
-
M && /* @__PURE__ */ p("div", { className: ee("text-sm order-3
|
|
8864
|
-
/* @__PURE__ */ p("div", { className: "
|
|
8865
|
-
/* @__PURE__ */ p("div", { className: "order-2
|
|
8866
|
+
/* @__PURE__ */ B("div", { className: "snow-table-bottom-bar grid grid-cols-1 lg:grid-cols-[auto_1fr_auto] gap-4 py-4 items-center", children: [
|
|
8867
|
+
M && /* @__PURE__ */ p("div", { className: ee("snow-table-count text-sm order-3 lg:order-1 text-center lg:text-left", D.table.empty), "data-testid": "datatable-count", children: O("dataTable.element", { count: Oo, total: ua }) }),
|
|
8868
|
+
/* @__PURE__ */ p("div", { className: "snow-table-pagination flex justify-center order-1 lg:order-2", children: F && sa && /* @__PURE__ */ p(dm, { table: Le, isLoading: o }) }),
|
|
8869
|
+
F && /* @__PURE__ */ p("div", { className: "snow-table-pagesize order-2 lg:order-3 flex justify-center lg:justify-end", children: /* @__PURE__ */ p(fm, { table: Le, enableElementLabel: N, paginationSizes: V }) })
|
|
8866
8870
|
] })
|
|
8867
8871
|
] });
|
|
8868
8872
|
}
|
|
@@ -9042,12 +9046,12 @@ const oa = ({
|
|
|
9042
9046
|
prefilterFn: s,
|
|
9043
9047
|
defaultSortBy: i,
|
|
9044
9048
|
defaultSortOrder: a = "asc",
|
|
9045
|
-
defaultPageSize: l =
|
|
9049
|
+
defaultPageSize: l = Tn[0],
|
|
9046
9050
|
persistState: c = !1,
|
|
9047
9051
|
fetchAllItemsEndpoint: d,
|
|
9048
9052
|
...u
|
|
9049
9053
|
}) => {
|
|
9050
|
-
var
|
|
9054
|
+
var F;
|
|
9051
9055
|
const {
|
|
9052
9056
|
pagination: h,
|
|
9053
9057
|
setPagination: g,
|
|
@@ -9062,14 +9066,14 @@ const oa = ({
|
|
|
9062
9066
|
resetToDefaults: T
|
|
9063
9067
|
} = Kr({
|
|
9064
9068
|
enabled: c,
|
|
9065
|
-
defaultPrefilter: (
|
|
9069
|
+
defaultPrefilter: (F = r == null ? void 0 : r[0]) == null ? void 0 : F.id,
|
|
9066
9070
|
defaultPageSize: l,
|
|
9067
9071
|
defaultSortBy: i,
|
|
9068
9072
|
defaultSortOrder: a
|
|
9069
9073
|
}), { data: R = [], isLoading: C } = Rr({
|
|
9070
9074
|
queryKey: e,
|
|
9071
9075
|
queryFn: d
|
|
9072
|
-
}), M = Pe(() => !R || !v || !s ? R : R.filter((
|
|
9076
|
+
}), M = Pe(() => !R || !v || !s ? R : R.filter((V) => s(V, v)), [R, v, s]), { columns: N } = oa({
|
|
9073
9077
|
columnConfig: t,
|
|
9074
9078
|
actions: n,
|
|
9075
9079
|
filters: o,
|
|
@@ -9106,7 +9110,7 @@ const oa = ({
|
|
|
9106
9110
|
prefilters: r,
|
|
9107
9111
|
defaultSortBy: s,
|
|
9108
9112
|
defaultSortOrder: i = "asc",
|
|
9109
|
-
defaultPageSize: a =
|
|
9113
|
+
defaultPageSize: a = Tn[0],
|
|
9110
9114
|
persistState: l = !1,
|
|
9111
9115
|
fetchServerEndpoint: c,
|
|
9112
9116
|
...d
|
|
@@ -9133,15 +9137,15 @@ const oa = ({
|
|
|
9133
9137
|
}), T = Rr({
|
|
9134
9138
|
queryKey: [...e, "server", u, g, m, y, w],
|
|
9135
9139
|
queryFn: async () => {
|
|
9136
|
-
var
|
|
9140
|
+
var F, V;
|
|
9137
9141
|
return c({
|
|
9138
9142
|
limit: u.pageSize,
|
|
9139
9143
|
offset: u.pageIndex * u.pageSize,
|
|
9140
9144
|
search: g || void 0,
|
|
9141
9145
|
prefilter: m,
|
|
9142
9146
|
filters: Object.keys(y).length > 0 ? y : void 0,
|
|
9143
|
-
sortBy: (
|
|
9144
|
-
sortOrder: (
|
|
9147
|
+
sortBy: (F = w[0]) == null ? void 0 : F.id,
|
|
9148
|
+
sortOrder: (V = w[0]) != null && V.desc ? "DESC" : "ASC"
|
|
9145
9149
|
});
|
|
9146
9150
|
},
|
|
9147
9151
|
placeholderData: fa
|
|
@@ -9173,14 +9177,15 @@ const oa = ({
|
|
|
9173
9177
|
sorting: w,
|
|
9174
9178
|
onSortingChange: S,
|
|
9175
9179
|
onResetFilters: A,
|
|
9176
|
-
...d
|
|
9180
|
+
...d,
|
|
9181
|
+
enablePagination: !0
|
|
9177
9182
|
}
|
|
9178
9183
|
);
|
|
9179
9184
|
};
|
|
9180
9185
|
export {
|
|
9181
9186
|
Mm as ActionCell,
|
|
9182
9187
|
gp as ColumnConfiguration,
|
|
9183
|
-
|
|
9188
|
+
Tn as DEFAULT_PAGE_SIZES,
|
|
9184
9189
|
na as DataTable,
|
|
9185
9190
|
fm as PageSizeSelector,
|
|
9186
9191
|
dm as Pagination,
|