@unizap/uniui 1.0.44 → 1.0.45
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/uniui.js +439 -439
- package/dist/uniui.umd.cjs +46 -46
- package/package.json +1 -1
package/dist/uniui.js
CHANGED
|
@@ -155,7 +155,7 @@ function io() {
|
|
|
155
155
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
156
156
|
)), x = this.props.ref, x !== void 0 ? x : null;
|
|
157
157
|
}
|
|
158
|
-
function
|
|
158
|
+
function d(x, y, E, k, A, z, N, $) {
|
|
159
159
|
return E = z.ref, x = {
|
|
160
160
|
$$typeof: g,
|
|
161
161
|
type: x,
|
|
@@ -187,7 +187,7 @@ function io() {
|
|
|
187
187
|
value: $
|
|
188
188
|
}), Object.freeze && (Object.freeze(x.props), Object.freeze(x)), x;
|
|
189
189
|
}
|
|
190
|
-
function
|
|
190
|
+
function u(x, y, E, k, A, z, N, $) {
|
|
191
191
|
var R = y.children;
|
|
192
192
|
if (R !== void 0)
|
|
193
193
|
if (k)
|
|
@@ -226,7 +226,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
226
226
|
return R && s(
|
|
227
227
|
E,
|
|
228
228
|
typeof x == "function" ? x.displayName || x.name || "Unknown" : x
|
|
229
|
-
),
|
|
229
|
+
), d(
|
|
230
230
|
x,
|
|
231
231
|
R,
|
|
232
232
|
z,
|
|
@@ -240,21 +240,21 @@ React keys must be passed directly to JSX without using spread:
|
|
|
240
240
|
function f(x) {
|
|
241
241
|
typeof x == "object" && x !== null && x.$$typeof === g && x._store && (x._store.validated = 1);
|
|
242
242
|
}
|
|
243
|
-
var
|
|
243
|
+
var p = Se, g = Symbol.for("react.transitional.element"), v = Symbol.for("react.portal"), m = Symbol.for("react.fragment"), h = Symbol.for("react.strict_mode"), j = Symbol.for("react.profiler"), P = Symbol.for("react.consumer"), b = Symbol.for("react.context"), M = Symbol.for("react.forward_ref"), w = Symbol.for("react.suspense"), O = Symbol.for("react.suspense_list"), F = Symbol.for("react.memo"), V = Symbol.for("react.lazy"), q = Symbol.for("react.activity"), ee = Symbol.for("react.client.reference"), ae = p.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, ce = Object.prototype.hasOwnProperty, D = Array.isArray, I = console.createTask ? console.createTask : function() {
|
|
244
244
|
return null;
|
|
245
245
|
};
|
|
246
|
-
|
|
246
|
+
p = {
|
|
247
247
|
"react-stack-bottom-frame": function(x) {
|
|
248
248
|
return x();
|
|
249
249
|
}
|
|
250
250
|
};
|
|
251
|
-
var W, T = {}, J =
|
|
252
|
-
|
|
251
|
+
var W, T = {}, J = p["react-stack-bottom-frame"].bind(
|
|
252
|
+
p,
|
|
253
253
|
i
|
|
254
254
|
)(), de = I(o(i)), K = {};
|
|
255
255
|
De.Fragment = m, De.jsx = function(x, y, E, k, A) {
|
|
256
256
|
var z = 1e4 > ae.recentlyCreatedOwnerStacks++;
|
|
257
|
-
return
|
|
257
|
+
return u(
|
|
258
258
|
x,
|
|
259
259
|
y,
|
|
260
260
|
E,
|
|
@@ -266,7 +266,7 @@ React keys must be passed directly to JSX without using spread:
|
|
|
266
266
|
);
|
|
267
267
|
}, De.jsxs = function(x, y, E, k, A) {
|
|
268
268
|
var z = 1e4 > ae.recentlyCreatedOwnerStacks++;
|
|
269
|
-
return
|
|
269
|
+
return u(
|
|
270
270
|
x,
|
|
271
271
|
y,
|
|
272
272
|
E,
|
|
@@ -615,10 +615,10 @@ const xe = {
|
|
|
615
615
|
onClick: l,
|
|
616
616
|
className: s = "",
|
|
617
617
|
fullWidth: c = !1,
|
|
618
|
-
disabled:
|
|
619
|
-
roundedFull:
|
|
618
|
+
disabled: d = !1,
|
|
619
|
+
roundedFull: u = !1,
|
|
620
620
|
size: f = "medium",
|
|
621
|
-
type:
|
|
621
|
+
type: p = "button",
|
|
622
622
|
autoFocus: g = !1,
|
|
623
623
|
href: v,
|
|
624
624
|
target: m,
|
|
@@ -643,8 +643,8 @@ const xe = {
|
|
|
643
643
|
${s}
|
|
644
644
|
${f === "small" ? "text-sm h-8 px-3" : f === "large" ? "text-lg h-12 px-6" : "text-base h-10 px-5"}
|
|
645
645
|
${c ? "w-full" : ""}
|
|
646
|
-
${
|
|
647
|
-
${
|
|
646
|
+
${u ? "rounded-full" : "rounded-md"}
|
|
647
|
+
${d ? `${t === "filled" && "!bg-color-gray-300 !text-color-white"} ${t === "outlined" && "!border-color-gray-200 !text-color-gray-300"} cursor-not-allowed hover:bg-color-transparent !text-color-gray-300` : "cursor-pointer"}
|
|
648
648
|
`,
|
|
649
649
|
children: [
|
|
650
650
|
r && /* @__PURE__ */ a.jsx("span", { className: "mr-1", children: r }),
|
|
@@ -656,8 +656,8 @@ const xe = {
|
|
|
656
656
|
"button",
|
|
657
657
|
{
|
|
658
658
|
ref: j,
|
|
659
|
-
type:
|
|
660
|
-
disabled:
|
|
659
|
+
type: p,
|
|
660
|
+
disabled: d,
|
|
661
661
|
onClick: b,
|
|
662
662
|
className: `relative leading-none font-medium overflow-hidden flex items-center justify-center gap-1 transition-all focus:outline-0
|
|
663
663
|
${t === "outlined" && "border"}
|
|
@@ -665,8 +665,8 @@ const xe = {
|
|
|
665
665
|
${s}
|
|
666
666
|
${f === "small" ? "text-sm h-8 px-3" : f === "large" ? "text-lg h-12 px-6" : "text-base h-10 px-5"}
|
|
667
667
|
${c ? "w-full" : ""}
|
|
668
|
-
${
|
|
669
|
-
${
|
|
668
|
+
${u ? "rounded-full" : "rounded-md"}
|
|
669
|
+
${d ? `${t === "filled" && "!bg-color-gray-300 !text-color-white"} ${t === "outlined" && "!border-color-gray-200 !text-color-gray-300"} cursor-not-allowed hover:bg-color-transparent !text-color-gray-300` : "cursor-pointer"}
|
|
670
670
|
`,
|
|
671
671
|
autoFocus: g,
|
|
672
672
|
...h,
|
|
@@ -744,8 +744,8 @@ const xe = {
|
|
|
744
744
|
}) => {
|
|
745
745
|
const [i, l] = X(!1), s = pe(null);
|
|
746
746
|
return se(() => {
|
|
747
|
-
const c = (
|
|
748
|
-
s.current && !s.current.contains(
|
|
747
|
+
const c = (d) => {
|
|
748
|
+
s.current && !s.current.contains(d.target) && l(!1);
|
|
749
749
|
};
|
|
750
750
|
return document.addEventListener("mousedown", c), () => document.removeEventListener("mousedown", c);
|
|
751
751
|
}, []), /* @__PURE__ */ a.jsxs("div", { ref: s, className: "relative inline-block w-full", children: [
|
|
@@ -764,8 +764,8 @@ const xe = {
|
|
|
764
764
|
"ul",
|
|
765
765
|
{
|
|
766
766
|
className: `absolute mt-2 right-0 z-10 w-full rounded-xl bg-color-white shadow-lg shadow-color-zinc-200 dark:shadow-color-gray-900 border border-color-gray-100 py-2 ${o}`,
|
|
767
|
-
children: n.map((c,
|
|
768
|
-
const
|
|
767
|
+
children: n.map((c, d) => {
|
|
768
|
+
const u = c.label === (e == null ? void 0 : e.label);
|
|
769
769
|
return /* @__PURE__ */ a.jsx(
|
|
770
770
|
"li",
|
|
771
771
|
{
|
|
@@ -776,12 +776,12 @@ const xe = {
|
|
|
776
776
|
"div",
|
|
777
777
|
{
|
|
778
778
|
className: `block cursor-pointer w-full px-4 py-2 text-left text-sm text-color-gray-700
|
|
779
|
-
${
|
|
779
|
+
${u ? " bg-color-gray-200" : " hover:bg-color-gray-100 "}`,
|
|
780
780
|
children: c.label
|
|
781
781
|
}
|
|
782
782
|
)
|
|
783
783
|
},
|
|
784
|
-
|
|
784
|
+
d
|
|
785
785
|
);
|
|
786
786
|
})
|
|
787
787
|
}
|
|
@@ -801,7 +801,7 @@ var Yt;
|
|
|
801
801
|
function lo() {
|
|
802
802
|
if (Yt) return te;
|
|
803
803
|
Yt = 1;
|
|
804
|
-
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, o = e ? Symbol.for("react.fragment") : 60107, r = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, l = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111,
|
|
804
|
+
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, o = e ? Symbol.for("react.fragment") : 60107, r = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, l = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111, d = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, f = e ? Symbol.for("react.suspense") : 60113, p = e ? Symbol.for("react.suspense_list") : 60120, g = e ? Symbol.for("react.memo") : 60115, v = e ? Symbol.for("react.lazy") : 60116, m = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, j = e ? Symbol.for("react.responder") : 60118, P = e ? Symbol.for("react.scope") : 60119;
|
|
805
805
|
function b(w) {
|
|
806
806
|
if (typeof w == "object" && w !== null) {
|
|
807
807
|
var O = w.$$typeof;
|
|
@@ -809,7 +809,7 @@ function lo() {
|
|
|
809
809
|
case n:
|
|
810
810
|
switch (w = w.type, w) {
|
|
811
811
|
case c:
|
|
812
|
-
case
|
|
812
|
+
case d:
|
|
813
813
|
case o:
|
|
814
814
|
case i:
|
|
815
815
|
case r:
|
|
@@ -818,7 +818,7 @@ function lo() {
|
|
|
818
818
|
default:
|
|
819
819
|
switch (w = w && w.$$typeof, w) {
|
|
820
820
|
case s:
|
|
821
|
-
case
|
|
821
|
+
case u:
|
|
822
822
|
case v:
|
|
823
823
|
case g:
|
|
824
824
|
case l:
|
|
@@ -833,9 +833,9 @@ function lo() {
|
|
|
833
833
|
}
|
|
834
834
|
}
|
|
835
835
|
function M(w) {
|
|
836
|
-
return b(w) ===
|
|
836
|
+
return b(w) === d;
|
|
837
837
|
}
|
|
838
|
-
return te.AsyncMode = c, te.ConcurrentMode =
|
|
838
|
+
return te.AsyncMode = c, te.ConcurrentMode = d, te.ContextConsumer = s, te.ContextProvider = l, te.Element = n, te.ForwardRef = u, te.Fragment = o, te.Lazy = v, te.Memo = g, te.Portal = t, te.Profiler = i, te.StrictMode = r, te.Suspense = f, te.isAsyncMode = function(w) {
|
|
839
839
|
return M(w) || b(w) === c;
|
|
840
840
|
}, te.isConcurrentMode = M, te.isContextConsumer = function(w) {
|
|
841
841
|
return b(w) === s;
|
|
@@ -844,7 +844,7 @@ function lo() {
|
|
|
844
844
|
}, te.isElement = function(w) {
|
|
845
845
|
return typeof w == "object" && w !== null && w.$$typeof === n;
|
|
846
846
|
}, te.isForwardRef = function(w) {
|
|
847
|
-
return b(w) ===
|
|
847
|
+
return b(w) === u;
|
|
848
848
|
}, te.isFragment = function(w) {
|
|
849
849
|
return b(w) === o;
|
|
850
850
|
}, te.isLazy = function(w) {
|
|
@@ -860,7 +860,7 @@ function lo() {
|
|
|
860
860
|
}, te.isSuspense = function(w) {
|
|
861
861
|
return b(w) === f;
|
|
862
862
|
}, te.isValidElementType = function(w) {
|
|
863
|
-
return typeof w == "string" || typeof w == "function" || w === o || w ===
|
|
863
|
+
return typeof w == "string" || typeof w == "function" || w === o || w === d || w === i || w === r || w === f || w === p || typeof w == "object" && w !== null && (w.$$typeof === v || w.$$typeof === g || w.$$typeof === l || w.$$typeof === s || w.$$typeof === u || w.$$typeof === h || w.$$typeof === j || w.$$typeof === P || w.$$typeof === m);
|
|
864
864
|
}, te.typeOf = b, te;
|
|
865
865
|
}
|
|
866
866
|
var ne = {};
|
|
@@ -875,10 +875,10 @@ var ne = {};
|
|
|
875
875
|
var Zt;
|
|
876
876
|
function so() {
|
|
877
877
|
return Zt || (Zt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
878
|
-
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, o = e ? Symbol.for("react.fragment") : 60107, r = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, l = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111,
|
|
878
|
+
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, o = e ? Symbol.for("react.fragment") : 60107, r = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, l = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111, d = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, f = e ? Symbol.for("react.suspense") : 60113, p = e ? Symbol.for("react.suspense_list") : 60120, g = e ? Symbol.for("react.memo") : 60115, v = e ? Symbol.for("react.lazy") : 60116, m = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, j = e ? Symbol.for("react.responder") : 60118, P = e ? Symbol.for("react.scope") : 60119;
|
|
879
879
|
function b(S) {
|
|
880
880
|
return typeof S == "string" || typeof S == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
881
|
-
S === o || S ===
|
|
881
|
+
S === o || S === d || S === i || S === r || S === f || S === p || typeof S == "object" && S !== null && (S.$$typeof === v || S.$$typeof === g || S.$$typeof === l || S.$$typeof === s || S.$$typeof === u || S.$$typeof === h || S.$$typeof === j || S.$$typeof === P || S.$$typeof === m);
|
|
882
882
|
}
|
|
883
883
|
function M(S) {
|
|
884
884
|
if (typeof S == "object" && S !== null) {
|
|
@@ -888,7 +888,7 @@ function so() {
|
|
|
888
888
|
var Q = S.type;
|
|
889
889
|
switch (Q) {
|
|
890
890
|
case c:
|
|
891
|
-
case
|
|
891
|
+
case d:
|
|
892
892
|
case o:
|
|
893
893
|
case i:
|
|
894
894
|
case r:
|
|
@@ -898,7 +898,7 @@ function so() {
|
|
|
898
898
|
var C = Q && Q.$$typeof;
|
|
899
899
|
switch (C) {
|
|
900
900
|
case s:
|
|
901
|
-
case
|
|
901
|
+
case u:
|
|
902
902
|
case v:
|
|
903
903
|
case g:
|
|
904
904
|
case l:
|
|
@@ -912,12 +912,12 @@ function so() {
|
|
|
912
912
|
}
|
|
913
913
|
}
|
|
914
914
|
}
|
|
915
|
-
var w = c, O =
|
|
915
|
+
var w = c, O = d, F = s, V = l, q = n, ee = u, ae = o, ce = v, D = g, I = t, W = i, T = r, J = f, de = !1;
|
|
916
916
|
function K(S) {
|
|
917
917
|
return de || (de = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), x(S) || M(S) === c;
|
|
918
918
|
}
|
|
919
919
|
function x(S) {
|
|
920
|
-
return M(S) ===
|
|
920
|
+
return M(S) === d;
|
|
921
921
|
}
|
|
922
922
|
function y(S) {
|
|
923
923
|
return M(S) === s;
|
|
@@ -929,7 +929,7 @@ function so() {
|
|
|
929
929
|
return typeof S == "object" && S !== null && S.$$typeof === n;
|
|
930
930
|
}
|
|
931
931
|
function A(S) {
|
|
932
|
-
return M(S) ===
|
|
932
|
+
return M(S) === u;
|
|
933
933
|
}
|
|
934
934
|
function z(S) {
|
|
935
935
|
return M(S) === o;
|
|
@@ -983,28 +983,28 @@ function co() {
|
|
|
983
983
|
return !1;
|
|
984
984
|
for (var l = {}, s = 0; s < 10; s++)
|
|
985
985
|
l["_" + String.fromCharCode(s)] = s;
|
|
986
|
-
var c = Object.getOwnPropertyNames(l).map(function(
|
|
987
|
-
return l[
|
|
986
|
+
var c = Object.getOwnPropertyNames(l).map(function(u) {
|
|
987
|
+
return l[u];
|
|
988
988
|
});
|
|
989
989
|
if (c.join("") !== "0123456789")
|
|
990
990
|
return !1;
|
|
991
|
-
var
|
|
992
|
-
return "abcdefghijklmnopqrst".split("").forEach(function(
|
|
993
|
-
|
|
994
|
-
}), Object.keys(Object.assign({},
|
|
991
|
+
var d = {};
|
|
992
|
+
return "abcdefghijklmnopqrst".split("").forEach(function(u) {
|
|
993
|
+
d[u] = u;
|
|
994
|
+
}), Object.keys(Object.assign({}, d)).join("") === "abcdefghijklmnopqrst";
|
|
995
995
|
} catch {
|
|
996
996
|
return !1;
|
|
997
997
|
}
|
|
998
998
|
}
|
|
999
999
|
return ut = r() ? Object.assign : function(i, l) {
|
|
1000
|
-
for (var s, c = o(i),
|
|
1001
|
-
s = Object(arguments[
|
|
1000
|
+
for (var s, c = o(i), d, u = 1; u < arguments.length; u++) {
|
|
1001
|
+
s = Object(arguments[u]);
|
|
1002
1002
|
for (var f in s)
|
|
1003
1003
|
n.call(s, f) && (c[f] = s[f]);
|
|
1004
1004
|
if (e) {
|
|
1005
|
-
|
|
1006
|
-
for (var
|
|
1007
|
-
t.call(s, p
|
|
1005
|
+
d = e(s);
|
|
1006
|
+
for (var p = 0; p < d.length; p++)
|
|
1007
|
+
t.call(s, d[p]) && (c[d[p]] = s[d[p]]);
|
|
1008
1008
|
}
|
|
1009
1009
|
}
|
|
1010
1010
|
return c;
|
|
@@ -1038,27 +1038,27 @@ function uo() {
|
|
|
1038
1038
|
}
|
|
1039
1039
|
};
|
|
1040
1040
|
}
|
|
1041
|
-
function r(i, l, s, c,
|
|
1041
|
+
function r(i, l, s, c, d) {
|
|
1042
1042
|
if (process.env.NODE_ENV !== "production") {
|
|
1043
|
-
for (var
|
|
1044
|
-
if (o(i,
|
|
1043
|
+
for (var u in i)
|
|
1044
|
+
if (o(i, u)) {
|
|
1045
1045
|
var f;
|
|
1046
1046
|
try {
|
|
1047
|
-
if (typeof i[
|
|
1048
|
-
var
|
|
1049
|
-
(c || "React class") + ": " + s + " type `" +
|
|
1047
|
+
if (typeof i[u] != "function") {
|
|
1048
|
+
var p = Error(
|
|
1049
|
+
(c || "React class") + ": " + s + " type `" + u + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[u] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
1050
1050
|
);
|
|
1051
|
-
throw
|
|
1051
|
+
throw p.name = "Invariant Violation", p;
|
|
1052
1052
|
}
|
|
1053
|
-
f = i[
|
|
1053
|
+
f = i[u](l, u, c, s, null, n);
|
|
1054
1054
|
} catch (v) {
|
|
1055
1055
|
f = v;
|
|
1056
1056
|
}
|
|
1057
1057
|
if (f && !(f instanceof Error) && e(
|
|
1058
|
-
(c || "React class") + ": type specification of " + s + " `" +
|
|
1058
|
+
(c || "React class") + ": type specification of " + s + " `" + u + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof f + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
1059
1059
|
), f instanceof Error && !(f.message in t)) {
|
|
1060
1060
|
t[f.message] = !0;
|
|
1061
|
-
var g =
|
|
1061
|
+
var g = d ? d() : "";
|
|
1062
1062
|
e(
|
|
1063
1063
|
"Failed " + s + " type: " + f.message + (g ?? "")
|
|
1064
1064
|
);
|
|
@@ -1088,13 +1088,13 @@ function po() {
|
|
|
1088
1088
|
return null;
|
|
1089
1089
|
}
|
|
1090
1090
|
return ft = function(s, c) {
|
|
1091
|
-
var
|
|
1091
|
+
var d = typeof Symbol == "function" && Symbol.iterator, u = "@@iterator";
|
|
1092
1092
|
function f(x) {
|
|
1093
|
-
var y = x && (
|
|
1093
|
+
var y = x && (d && x[d] || x[u]);
|
|
1094
1094
|
if (typeof y == "function")
|
|
1095
1095
|
return y;
|
|
1096
1096
|
}
|
|
1097
|
-
var
|
|
1097
|
+
var p = "<<anonymous>>", g = {
|
|
1098
1098
|
array: j("array"),
|
|
1099
1099
|
bigint: j("bigint"),
|
|
1100
1100
|
bool: j("boolean"),
|
|
@@ -1126,7 +1126,7 @@ function po() {
|
|
|
1126
1126
|
if (process.env.NODE_ENV !== "production")
|
|
1127
1127
|
var y = {}, E = 0;
|
|
1128
1128
|
function k(z, N, $, R, H, B, re) {
|
|
1129
|
-
if (R = R ||
|
|
1129
|
+
if (R = R || p, B = B || $, re !== t) {
|
|
1130
1130
|
if (c) {
|
|
1131
1131
|
var S = new Error(
|
|
1132
1132
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
|
|
@@ -1205,7 +1205,7 @@ function po() {
|
|
|
1205
1205
|
function O(x) {
|
|
1206
1206
|
function y(E, k, A, z, N) {
|
|
1207
1207
|
if (!(E[k] instanceof x)) {
|
|
1208
|
-
var $ = x.name ||
|
|
1208
|
+
var $ = x.name || p, R = K(E[k]);
|
|
1209
1209
|
return new m("Invalid " + z + " `" + N + "` of type " + ("`" + R + "` supplied to `" + A + "`, expected ") + ("instance of `" + $ + "`."));
|
|
1210
1210
|
}
|
|
1211
1211
|
return null;
|
|
@@ -1386,7 +1386,7 @@ Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
|
|
|
1386
1386
|
}
|
|
1387
1387
|
}
|
|
1388
1388
|
function K(x) {
|
|
1389
|
-
return !x.constructor || !x.constructor.name ?
|
|
1389
|
+
return !x.constructor || !x.constructor.name ? p : x.constructor.name;
|
|
1390
1390
|
}
|
|
1391
1391
|
return g.checkPropTypes = r, g.resetWarningCache = r.resetWarningCache, g.PropTypes = g, g;
|
|
1392
1392
|
}, ft;
|
|
@@ -1401,12 +1401,12 @@ function go() {
|
|
|
1401
1401
|
function t() {
|
|
1402
1402
|
}
|
|
1403
1403
|
return t.resetWarningCache = n, mt = function() {
|
|
1404
|
-
function o(l, s, c,
|
|
1404
|
+
function o(l, s, c, d, u, f) {
|
|
1405
1405
|
if (f !== e) {
|
|
1406
|
-
var
|
|
1406
|
+
var p = new Error(
|
|
1407
1407
|
"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types"
|
|
1408
1408
|
);
|
|
1409
|
-
throw
|
|
1409
|
+
throw p.name = "Invariant Violation", p;
|
|
1410
1410
|
}
|
|
1411
1411
|
}
|
|
1412
1412
|
o.isRequired = o;
|
|
@@ -1458,24 +1458,24 @@ function Me(e, n, t, o) {
|
|
|
1458
1458
|
});
|
|
1459
1459
|
}
|
|
1460
1460
|
return new (t || (t = Promise))(function(i, l) {
|
|
1461
|
-
function s(
|
|
1461
|
+
function s(u) {
|
|
1462
1462
|
try {
|
|
1463
|
-
|
|
1463
|
+
d(o.next(u));
|
|
1464
1464
|
} catch (f) {
|
|
1465
1465
|
l(f);
|
|
1466
1466
|
}
|
|
1467
1467
|
}
|
|
1468
|
-
function c(
|
|
1468
|
+
function c(u) {
|
|
1469
1469
|
try {
|
|
1470
|
-
|
|
1470
|
+
d(o.throw(u));
|
|
1471
1471
|
} catch (f) {
|
|
1472
1472
|
l(f);
|
|
1473
1473
|
}
|
|
1474
1474
|
}
|
|
1475
|
-
function
|
|
1476
|
-
|
|
1475
|
+
function d(u) {
|
|
1476
|
+
u.done ? i(u.value) : r(u.value).then(s, c);
|
|
1477
1477
|
}
|
|
1478
|
-
|
|
1478
|
+
d((o = o.apply(e, n || [])).next());
|
|
1479
1479
|
});
|
|
1480
1480
|
}
|
|
1481
1481
|
const xo = /* @__PURE__ */ new Map([
|
|
@@ -2969,7 +2969,7 @@ function Ee(e) {
|
|
|
2969
2969
|
function qo(e) {
|
|
2970
2970
|
var n = e.files, t = e.accept, o = e.minSize, r = e.maxSize, i = e.multiple, l = e.maxFiles, s = e.validator;
|
|
2971
2971
|
return !i && n.length > 1 || i && l >= 1 && n.length > l ? !1 : n.every(function(c) {
|
|
2972
|
-
var
|
|
2972
|
+
var d = Fn(c, t), u = Ie(d, 1), f = u[0], p = An(c, o, r), g = Ie(p, 1), v = g[0], m = s ? s(c) : null;
|
|
2973
2973
|
return f && v && !m;
|
|
2974
2974
|
});
|
|
2975
2975
|
}
|
|
@@ -3350,7 +3350,7 @@ var Lt = {
|
|
|
3350
3350
|
fileRejections: []
|
|
3351
3351
|
};
|
|
3352
3352
|
function On() {
|
|
3353
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = ue(ue({}, Tn), e), t = n.accept, o = n.disabled, r = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles,
|
|
3353
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = ue(ue({}, Tn), e), t = n.accept, o = n.disabled, r = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles, d = n.onDragEnter, u = n.onDragLeave, f = n.onDragOver, p = n.onDrop, g = n.onDropAccepted, v = n.onDropRejected, m = n.onFileDialogCancel, h = n.onFileDialogOpen, j = n.useFsAccessApi, P = n.autoFocus, b = n.preventDropOnDocument, M = n.noClick, w = n.noKeyboard, O = n.noDrag, F = n.noDragEventsBubbling, V = n.onError, q = n.validator, ee = Pe(function() {
|
|
3354
3354
|
return Uo(t);
|
|
3355
3355
|
}, [t]), ae = Pe(function() {
|
|
3356
3356
|
return Wo(t);
|
|
@@ -3403,12 +3403,12 @@ function On() {
|
|
|
3403
3403
|
isDragReject: be,
|
|
3404
3404
|
isDragActive: !0,
|
|
3405
3405
|
type: "setDraggedFiles"
|
|
3406
|
-
}),
|
|
3406
|
+
}), d && d(L);
|
|
3407
3407
|
}
|
|
3408
3408
|
}).catch(function(G) {
|
|
3409
3409
|
return N(G);
|
|
3410
3410
|
});
|
|
3411
|
-
}, [r,
|
|
3411
|
+
}, [r, d, N, F, ee, l, i, s, c, q]), R = oe(function(L) {
|
|
3412
3412
|
L.preventDefault(), L.persist(), he(L);
|
|
3413
3413
|
var G = We(L);
|
|
3414
3414
|
if (G && L.dataTransfer)
|
|
@@ -3427,8 +3427,8 @@ function On() {
|
|
|
3427
3427
|
isDragActive: !1,
|
|
3428
3428
|
isDragAccept: !1,
|
|
3429
3429
|
isDragReject: !1
|
|
3430
|
-
}), We(L) &&
|
|
3431
|
-
}, [I,
|
|
3430
|
+
}), We(L) && u && u(L));
|
|
3431
|
+
}, [I, u, F]), B = oe(function(L, G) {
|
|
3432
3432
|
var fe = [], me = [];
|
|
3433
3433
|
L.forEach(function(be) {
|
|
3434
3434
|
var Ne = Fn(be, ee), Le = vt(Ne, 2), ot = Le[0], rt = Le[1], it = An(be, l, i), qe = vt(it, 2), at = qe[0], lt = qe[1], st = q ? q(be) : null;
|
|
@@ -3453,8 +3453,8 @@ function On() {
|
|
|
3453
3453
|
fileRejections: me,
|
|
3454
3454
|
isDragReject: me.length > 0,
|
|
3455
3455
|
type: "setFiles"
|
|
3456
|
-
}),
|
|
3457
|
-
}, [K, s, ee, l, i, c,
|
|
3456
|
+
}), p && p(fe, me, G), me.length > 0 && v && v(me, G), fe.length > 0 && g && g(fe, G);
|
|
3457
|
+
}, [K, s, ee, l, i, c, p, g, v, q]), re = oe(function(L) {
|
|
3458
3458
|
L.preventDefault(), L.persist(), he(L), A.current = [], We(L) && Promise.resolve(r(L)).then(function(G) {
|
|
3459
3459
|
et(L) && !F || B(G, L);
|
|
3460
3460
|
}).catch(function(G) {
|
|
@@ -3613,10 +3613,10 @@ const Pi = ({
|
|
|
3613
3613
|
disabled: l = !1,
|
|
3614
3614
|
label: s = "Upload PDF",
|
|
3615
3615
|
subLabel: c = "Maximum size: 2 MB",
|
|
3616
|
-
icon:
|
|
3617
|
-
wrapperClass:
|
|
3616
|
+
icon: d = /* @__PURE__ */ a.jsx("svg", { className: "size-4", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M3 19H21V21H3V19ZM13 5.82843V17H11V5.82843L4.92893 11.8995L3.51472 10.4853L12 2L20.4853 10.4853L19.0711 11.8995L13 5.82843Z" }) }),
|
|
3617
|
+
wrapperClass: u = "",
|
|
3618
3618
|
iconClass: f = "",
|
|
3619
|
-
labelClass:
|
|
3619
|
+
labelClass: p = "",
|
|
3620
3620
|
subLabelClass: g = "",
|
|
3621
3621
|
showList: v = !0,
|
|
3622
3622
|
listView: m = !0,
|
|
@@ -3678,7 +3678,7 @@ const Pi = ({
|
|
|
3678
3678
|
${ae ? "border-color-blue-500 bg-color-blue-50" : "border-color-gray-200 bg-color-gray-50"}
|
|
3679
3679
|
${ce ? "border-color-red-500 bg-color-red-50" : ""}
|
|
3680
3680
|
${l ? "opacity-50 cursor-not-allowed" : ""}
|
|
3681
|
-
${
|
|
3681
|
+
${u}
|
|
3682
3682
|
`,
|
|
3683
3683
|
children: [
|
|
3684
3684
|
/* @__PURE__ */ a.jsxs(
|
|
@@ -3688,8 +3688,8 @@ const Pi = ({
|
|
|
3688
3688
|
className: "flex flex-col items-center justify-center text-center px-6 pt-6 pb-4 cursor-pointer",
|
|
3689
3689
|
children: [
|
|
3690
3690
|
/* @__PURE__ */ a.jsx("input", { ...ee() }),
|
|
3691
|
-
/* @__PURE__ */ a.jsx("div", { className: `text-4xl mb-2 ${f}`, children:
|
|
3692
|
-
/* @__PURE__ */ a.jsx("p", { className: `text-sm font-medium ${
|
|
3691
|
+
/* @__PURE__ */ a.jsx("div", { className: `text-4xl mb-2 ${f}`, children: d }),
|
|
3692
|
+
/* @__PURE__ */ a.jsx("p", { className: `text-sm font-medium ${p}`, children: s }),
|
|
3693
3693
|
c && /* @__PURE__ */ a.jsx("p", { className: `text-xs mt-1 ${g}`, children: c })
|
|
3694
3694
|
]
|
|
3695
3695
|
}
|
|
@@ -3812,26 +3812,26 @@ const dr = {
|
|
|
3812
3812
|
disabled: l = !1,
|
|
3813
3813
|
size: s = "medium",
|
|
3814
3814
|
variant: c = "outlined",
|
|
3815
|
-
rounded:
|
|
3816
|
-
...
|
|
3815
|
+
rounded: d = "medium",
|
|
3816
|
+
...u
|
|
3817
3817
|
}, f) => {
|
|
3818
|
-
const
|
|
3818
|
+
const p = pe([]), g = (m, h) => {
|
|
3819
3819
|
var b;
|
|
3820
3820
|
const j = m.target.value.replace(/[^0-9]/g, "").slice(0, 1);
|
|
3821
3821
|
if (!j && t[h] === void 0) return;
|
|
3822
3822
|
const P = t.substring(0, h) + j + t.substring(h + 1, i);
|
|
3823
|
-
o == null || o(P), j && h < i - 1 && ((b =
|
|
3823
|
+
o == null || o(P), j && h < i - 1 && ((b = p.current[h + 1]) == null || b.focus()), r && P.length === i && !P.split("").some((M) => !M) && r(P);
|
|
3824
3824
|
}, v = (m, h) => {
|
|
3825
3825
|
var j, P, b;
|
|
3826
3826
|
m.key === "Backspace" && !t[h] && h > 0 ? (o == null || o(
|
|
3827
3827
|
t.substring(0, h - 1) + "" + t.substring(h, i)
|
|
3828
|
-
), (j =
|
|
3828
|
+
), (j = p.current[h - 1]) == null || j.focus(), m.preventDefault()) : m.key === "ArrowLeft" && h > 0 ? ((P = p.current[h - 1]) == null || P.focus(), m.preventDefault()) : m.key === "ArrowRight" && h < i - 1 && ((b = p.current[h + 1]) == null || b.focus(), m.preventDefault());
|
|
3829
3829
|
};
|
|
3830
3830
|
return /* @__PURE__ */ a.jsx("div", { className: `flex justify-center gap-2 ${e}`, children: Array.from({ length: i }).map((m, h) => /* @__PURE__ */ a.jsx(
|
|
3831
3831
|
"input",
|
|
3832
3832
|
{
|
|
3833
3833
|
ref: (j) => {
|
|
3834
|
-
|
|
3834
|
+
p.current[h] = j;
|
|
3835
3835
|
},
|
|
3836
3836
|
type: "text",
|
|
3837
3837
|
inputMode: "numeric",
|
|
@@ -3842,13 +3842,13 @@ const dr = {
|
|
|
3842
3842
|
text-center font-semibold focus:ring-1 ring-color-primary outline-0 transition-all
|
|
3843
3843
|
${dr[s]}
|
|
3844
3844
|
${fr[c]}
|
|
3845
|
-
${gr[
|
|
3845
|
+
${gr[d]}
|
|
3846
3846
|
${n}
|
|
3847
3847
|
`,
|
|
3848
3848
|
value: t[h] || "",
|
|
3849
3849
|
onChange: (j) => g(j, h),
|
|
3850
3850
|
onKeyDown: (j) => v(j, h),
|
|
3851
|
-
...
|
|
3851
|
+
...u
|
|
3852
3852
|
},
|
|
3853
3853
|
h
|
|
3854
3854
|
)) });
|
|
@@ -3873,17 +3873,17 @@ const xr = {
|
|
|
3873
3873
|
iconStyle: l = "",
|
|
3874
3874
|
startIcon: s,
|
|
3875
3875
|
endIcon: c,
|
|
3876
|
-
error:
|
|
3877
|
-
maxLength:
|
|
3876
|
+
error: d,
|
|
3877
|
+
maxLength: u,
|
|
3878
3878
|
label: f,
|
|
3879
|
-
labelClass:
|
|
3879
|
+
labelClass: p = "",
|
|
3880
3880
|
variant: g = "outlined",
|
|
3881
3881
|
size: v = "medium",
|
|
3882
3882
|
...m
|
|
3883
3883
|
}, h) => {
|
|
3884
|
-
const j =
|
|
3884
|
+
const j = d ? "border-color-red-500 focus-within:ring-color-red-500" : "border-color-gray-200", P = d ? "text-color-red-500" : l;
|
|
3885
3885
|
return /* @__PURE__ */ a.jsxs("div", { className: "w-full", children: [
|
|
3886
|
-
f && /* @__PURE__ */ a.jsx("label", { className: `text-sm font-medium text-color-gray-700 mb-1 block ${
|
|
3886
|
+
f && /* @__PURE__ */ a.jsx("label", { className: `text-sm font-medium text-color-gray-700 mb-1 block ${p}`, children: f }),
|
|
3887
3887
|
/* @__PURE__ */ a.jsxs("div", { className: `flex items-center w-full rounded-md border focus-within:ring-1 ${j} ${vr[g]} ${r}`, children: [
|
|
3888
3888
|
s && /* @__PURE__ */ a.jsx("span", { className: `pl-3 ${P}`, children: s }),
|
|
3889
3889
|
/* @__PURE__ */ a.jsx(
|
|
@@ -3894,14 +3894,14 @@ const xr = {
|
|
|
3894
3894
|
type: o,
|
|
3895
3895
|
placeholder: e,
|
|
3896
3896
|
defaultValue: n,
|
|
3897
|
-
maxLength:
|
|
3897
|
+
maxLength: u,
|
|
3898
3898
|
onChange: t,
|
|
3899
3899
|
className: `grow outline-0 w-full font-medium placeholder:font-normal bg-color-transparent ${xr[v]} ${i}`
|
|
3900
3900
|
}
|
|
3901
3901
|
),
|
|
3902
3902
|
c && /* @__PURE__ */ a.jsx("span", { className: `pr-3 ${P}`, children: c })
|
|
3903
3903
|
] }),
|
|
3904
|
-
|
|
3904
|
+
d && /* @__PURE__ */ a.jsx("p", { className: "text-color-red-500 text-xs mt-1", children: d })
|
|
3905
3905
|
] });
|
|
3906
3906
|
}
|
|
3907
3907
|
);
|
|
@@ -3938,7 +3938,7 @@ const Vn = ({
|
|
|
3938
3938
|
color: i = "pearl",
|
|
3939
3939
|
shape: l = "circle"
|
|
3940
3940
|
}) => {
|
|
3941
|
-
var
|
|
3941
|
+
var d;
|
|
3942
3942
|
const s = {
|
|
3943
3943
|
small: "w-8 h-8 text-sm",
|
|
3944
3944
|
medium: "w-10 h-10 text-base",
|
|
@@ -3960,7 +3960,7 @@ const Vn = ({
|
|
|
3960
3960
|
alt: n,
|
|
3961
3961
|
className: `object-cover w-full h-full ${c[l]}`
|
|
3962
3962
|
}
|
|
3963
|
-
) : o || ((
|
|
3963
|
+
) : o || ((d = n == null ? void 0 : n[0]) == null ? void 0 : d.toUpperCase()) || "?"
|
|
3964
3964
|
}
|
|
3965
3965
|
);
|
|
3966
3966
|
}, $e = ({
|
|
@@ -3973,24 +3973,24 @@ const Vn = ({
|
|
|
3973
3973
|
roundedFull: l = !1,
|
|
3974
3974
|
size: s = "medium",
|
|
3975
3975
|
autoFocus: c = !1,
|
|
3976
|
-
...
|
|
3976
|
+
...d
|
|
3977
3977
|
}) => {
|
|
3978
3978
|
var g;
|
|
3979
|
-
const
|
|
3980
|
-
const m =
|
|
3979
|
+
const u = pe(null), f = (v) => {
|
|
3980
|
+
const m = u.current;
|
|
3981
3981
|
if (!m) return;
|
|
3982
3982
|
const h = document.createElement("span"), j = m.getBoundingClientRect(), P = Math.max(j.width, j.height);
|
|
3983
3983
|
h.style.width = h.style.height = `${P}px`, h.style.left = `${v.clientX - j.left - P / 2}px`, h.style.top = `${v.clientY - j.top - P / 2}px`, h.className = "ripple_small", m.appendChild(h), setTimeout(() => h.remove(), 600), o == null || o(v);
|
|
3984
|
-
},
|
|
3984
|
+
}, p = ((g = xe[n]) == null ? void 0 : g[e === "filled" ? "filled" : e === "outlined" ? "outline" : "transparent"]) || "";
|
|
3985
3985
|
return /* @__PURE__ */ a.jsx(
|
|
3986
3986
|
"button",
|
|
3987
3987
|
{
|
|
3988
|
-
ref:
|
|
3988
|
+
ref: u,
|
|
3989
3989
|
type: "button",
|
|
3990
3990
|
disabled: i,
|
|
3991
3991
|
onClick: f,
|
|
3992
3992
|
className: `relative overflow-hidden flex items-center justify-center gap-1 transition-all focus:outline-0
|
|
3993
|
-
${
|
|
3993
|
+
${p}
|
|
3994
3994
|
${e === "outlined" && "border"}
|
|
3995
3995
|
${r}
|
|
3996
3996
|
${s === "small" ? "text-sm size-8" : s === "large" ? "text-lg size-12" : "text-base size-10"}
|
|
@@ -3998,7 +3998,7 @@ const Vn = ({
|
|
|
3998
3998
|
${i ? `!text-color-gray-400 hover:bg-color-transparent ${e === "filled" && "!bg-color-gray-200"} !border-color-gray-200 cursor-not-allowed` : "cursor-pointer hover:opacity-90"}
|
|
3999
3999
|
`,
|
|
4000
4000
|
autoFocus: c,
|
|
4001
|
-
...
|
|
4001
|
+
...d,
|
|
4002
4002
|
children: t && /* @__PURE__ */ a.jsx(a.Fragment, { children: t })
|
|
4003
4003
|
}
|
|
4004
4004
|
);
|
|
@@ -4020,13 +4020,13 @@ const Vn = ({
|
|
|
4020
4020
|
onDelete: l,
|
|
4021
4021
|
deleteIcon: s,
|
|
4022
4022
|
href: c,
|
|
4023
|
-
target:
|
|
4024
|
-
avatar:
|
|
4023
|
+
target: d = "_self",
|
|
4024
|
+
avatar: u,
|
|
4025
4025
|
icon: f
|
|
4026
4026
|
}) => {
|
|
4027
4027
|
var j, P;
|
|
4028
|
-
const
|
|
4029
|
-
|
|
4028
|
+
const p = (j = xe[n]) == null ? void 0 : j.filled, g = (P = xe[n]) == null ? void 0 : P.outline, v = br[o], m = `inline-flex items-center rounded-full font-medium leading-none ${t === "outlined" ? `border ${g}` : p} ${v} ${i ? "cursor-pointer transition hover:opacity-80" : ""}`.trim(), h = /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
4029
|
+
u && /* @__PURE__ */ a.jsx(Vn, { ...typeof u == "object" ? u : {}, className: `-ml-1 mr-1 ${mn[o]}` }),
|
|
4030
4030
|
f && /* @__PURE__ */ a.jsx("span", { className: "mr-1 -ml-1", children: f }),
|
|
4031
4031
|
/* @__PURE__ */ a.jsx("span", { children: e }),
|
|
4032
4032
|
l && /* @__PURE__ */ a.jsx(
|
|
@@ -4048,7 +4048,7 @@ const Vn = ({
|
|
|
4048
4048
|
"a",
|
|
4049
4049
|
{
|
|
4050
4050
|
href: c,
|
|
4051
|
-
target:
|
|
4051
|
+
target: d,
|
|
4052
4052
|
className: `no-underline ${m} ${r}`,
|
|
4053
4053
|
onClick: i,
|
|
4054
4054
|
children: h
|
|
@@ -4097,31 +4097,31 @@ const Vn = ({
|
|
|
4097
4097
|
iconCompletedClass: l = "",
|
|
4098
4098
|
labelClass: s = "",
|
|
4099
4099
|
activeLabelClass: c = "",
|
|
4100
|
-
separatorClass:
|
|
4101
|
-
onChange:
|
|
4102
|
-
}) => /* @__PURE__ */ a.jsx("div", { className: `flex items-center ${t}`, children: e.map((f,
|
|
4103
|
-
const g =
|
|
4100
|
+
separatorClass: d = "",
|
|
4101
|
+
onChange: u
|
|
4102
|
+
}) => /* @__PURE__ */ a.jsx("div", { className: `flex items-center ${t}`, children: e.map((f, p) => {
|
|
4103
|
+
const g = p === n, v = p < n;
|
|
4104
4104
|
return /* @__PURE__ */ a.jsxs(Se.Fragment, { children: [
|
|
4105
4105
|
/* @__PURE__ */ a.jsxs(
|
|
4106
4106
|
"div",
|
|
4107
4107
|
{
|
|
4108
4108
|
className: "flex items-center space-x-2 cursor-pointer",
|
|
4109
|
-
onClick: () =>
|
|
4109
|
+
onClick: () => u == null ? void 0 : u(p),
|
|
4110
4110
|
children: [
|
|
4111
4111
|
/* @__PURE__ */ a.jsx(
|
|
4112
4112
|
"div",
|
|
4113
4113
|
{
|
|
4114
4114
|
className: `flex items-center font-semibold justify-center w-7 h-7 rounded-full text-sm transition-color duration-200 leading-none
|
|
4115
4115
|
${g ? `bg-color-blue-500 text-color-white ${i} ` : v ? `bg-color-green-500 text-color-white ${l} ` : `bg-color-white text-color-gray-400 ring ${o} `}`,
|
|
4116
|
-
children: v ? /* @__PURE__ */ a.jsx("svg", { className: `size-5 ${r}`, xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M9.9997 15.1709L19.1921 5.97852L20.6063 7.39273L9.9997 17.9993L3.63574 11.6354L5.04996 10.2212L9.9997 15.1709Z" }) }) :
|
|
4116
|
+
children: v ? /* @__PURE__ */ a.jsx("svg", { className: `size-5 ${r}`, xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M9.9997 15.1709L19.1921 5.97852L20.6063 7.39273L9.9997 17.9993L3.63574 11.6354L5.04996 10.2212L9.9997 15.1709Z" }) }) : p + 1
|
|
4117
4117
|
}
|
|
4118
4118
|
),
|
|
4119
4119
|
/* @__PURE__ */ a.jsx("span", { className: `text-sm ${g ? `text-color-blue-600 ${c}` : `text-color-gray-600 ${s}`}`, children: f.label })
|
|
4120
4120
|
]
|
|
4121
4121
|
}
|
|
4122
4122
|
),
|
|
4123
|
-
|
|
4124
|
-
] },
|
|
4123
|
+
p < e.length - 1 && /* @__PURE__ */ a.jsx("svg", { className: `mx-4 text-color-gray-400 size-6 ${d}`, xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z" }) })
|
|
4124
|
+
] }, p);
|
|
4125
4125
|
}) });
|
|
4126
4126
|
/**
|
|
4127
4127
|
* table-core
|
|
@@ -4166,20 +4166,20 @@ function Y(e, n, t) {
|
|
|
4166
4166
|
let l;
|
|
4167
4167
|
t.key && t.debug && (l = Date.now());
|
|
4168
4168
|
const s = e(i);
|
|
4169
|
-
if (!(s.length !== o.length || s.some((
|
|
4169
|
+
if (!(s.length !== o.length || s.some((u, f) => o[f] !== u)))
|
|
4170
4170
|
return r;
|
|
4171
4171
|
o = s;
|
|
4172
|
-
let
|
|
4173
|
-
if (t.key && t.debug && (
|
|
4174
|
-
const
|
|
4172
|
+
let d;
|
|
4173
|
+
if (t.key && t.debug && (d = Date.now()), r = n(...s), t == null || t.onChange == null || t.onChange(r), t.key && t.debug && t != null && t.debug()) {
|
|
4174
|
+
const u = Math.round((Date.now() - l) * 100) / 100, f = Math.round((Date.now() - d) * 100) / 100, p = f / 16, g = (v, m) => {
|
|
4175
4175
|
for (v = String(v); v.length < m; )
|
|
4176
4176
|
v = " " + v;
|
|
4177
4177
|
return v;
|
|
4178
4178
|
};
|
|
4179
|
-
console.info(`%c⏱ ${g(f, 5)} /${g(
|
|
4179
|
+
console.info(`%c⏱ ${g(f, 5)} /${g(u, 5)} ms`, `
|
|
4180
4180
|
font-size: .6rem;
|
|
4181
4181
|
font-weight: bold;
|
|
4182
|
-
color: hsl(${Math.max(0, Math.min(120 - 120 *
|
|
4182
|
+
color: hsl(${Math.max(0, Math.min(120 - 120 * p, 120))}deg 100% 31%);`, t == null ? void 0 : t.key);
|
|
4183
4183
|
}
|
|
4184
4184
|
return r;
|
|
4185
4185
|
};
|
|
@@ -4204,13 +4204,13 @@ function Cr(e, n, t, o) {
|
|
|
4204
4204
|
column: t,
|
|
4205
4205
|
getValue: () => n.getValue(o),
|
|
4206
4206
|
renderValue: r,
|
|
4207
|
-
getContext: Y(() => [e, t, n, i], (l, s, c,
|
|
4207
|
+
getContext: Y(() => [e, t, n, i], (l, s, c, d) => ({
|
|
4208
4208
|
table: l,
|
|
4209
4209
|
column: s,
|
|
4210
4210
|
row: c,
|
|
4211
|
-
cell:
|
|
4212
|
-
getValue:
|
|
4213
|
-
renderValue:
|
|
4211
|
+
cell: d,
|
|
4212
|
+
getValue: d.getValue,
|
|
4213
|
+
renderValue: d.renderValue
|
|
4214
4214
|
}), Z(e.options, "debugCells", "cell.getContext"))
|
|
4215
4215
|
};
|
|
4216
4216
|
return e._features.forEach((l) => {
|
|
@@ -4223,38 +4223,38 @@ function jr(e, n, t, o) {
|
|
|
4223
4223
|
...e._getDefaultColumnDef(),
|
|
4224
4224
|
...n
|
|
4225
4225
|
}, c = s.accessorKey;
|
|
4226
|
-
let
|
|
4227
|
-
if (s.accessorFn ?
|
|
4228
|
-
let g =
|
|
4226
|
+
let d = (r = (i = s.id) != null ? i : c ? typeof String.prototype.replaceAll == "function" ? c.replaceAll(".", "_") : c.replace(/\./g, "_") : void 0) != null ? r : typeof s.header == "string" ? s.header : void 0, u;
|
|
4227
|
+
if (s.accessorFn ? u = s.accessorFn : c && (c.includes(".") ? u = (p) => {
|
|
4228
|
+
let g = p;
|
|
4229
4229
|
for (const m of c.split(".")) {
|
|
4230
4230
|
var v;
|
|
4231
4231
|
g = (v = g) == null ? void 0 : v[m], process.env.NODE_ENV !== "production" && g === void 0 && console.warn(`"${m}" in deeply nested key "${c}" returned undefined.`);
|
|
4232
4232
|
}
|
|
4233
4233
|
return g;
|
|
4234
|
-
} :
|
|
4234
|
+
} : u = (p) => p[s.accessorKey]), !d)
|
|
4235
4235
|
throw process.env.NODE_ENV !== "production" ? new Error(s.accessorFn ? "Columns require an id when using an accessorFn" : "Columns require an id when using a non-string header") : new Error();
|
|
4236
4236
|
let f = {
|
|
4237
|
-
id: `${String(
|
|
4238
|
-
accessorFn:
|
|
4237
|
+
id: `${String(d)}`,
|
|
4238
|
+
accessorFn: u,
|
|
4239
4239
|
parent: o,
|
|
4240
4240
|
depth: t,
|
|
4241
4241
|
columnDef: s,
|
|
4242
4242
|
columns: [],
|
|
4243
4243
|
getFlatColumns: Y(() => [!0], () => {
|
|
4244
|
-
var
|
|
4245
|
-
return [f, ...(
|
|
4244
|
+
var p;
|
|
4245
|
+
return [f, ...(p = f.columns) == null ? void 0 : p.flatMap((g) => g.getFlatColumns())];
|
|
4246
4246
|
}, Z(e.options, "debugColumns", "column.getFlatColumns")),
|
|
4247
|
-
getLeafColumns: Y(() => [e._getOrderColumnsFn()], (
|
|
4247
|
+
getLeafColumns: Y(() => [e._getOrderColumnsFn()], (p) => {
|
|
4248
4248
|
var g;
|
|
4249
4249
|
if ((g = f.columns) != null && g.length) {
|
|
4250
4250
|
let v = f.columns.flatMap((m) => m.getLeafColumns());
|
|
4251
|
-
return
|
|
4251
|
+
return p(v);
|
|
4252
4252
|
}
|
|
4253
4253
|
return [f];
|
|
4254
4254
|
}, Z(e.options, "debugColumns", "column.getLeafColumns"))
|
|
4255
4255
|
};
|
|
4256
|
-
for (const
|
|
4257
|
-
|
|
4256
|
+
for (const p of e._features)
|
|
4257
|
+
p.createColumn == null || p.createColumn(f, e);
|
|
4258
4258
|
return f;
|
|
4259
4259
|
}
|
|
4260
4260
|
const ve = "debugHeaders";
|
|
@@ -4291,8 +4291,8 @@ const Sr = {
|
|
|
4291
4291
|
createTable: (e) => {
|
|
4292
4292
|
e.getHeaderGroups = Y(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => {
|
|
4293
4293
|
var i, l;
|
|
4294
|
-
const s = (i = o == null ? void 0 : o.map((f) => t.find((
|
|
4295
|
-
return Ue(n, [...s, ...
|
|
4294
|
+
const s = (i = o == null ? void 0 : o.map((f) => t.find((p) => p.id === f)).filter(Boolean)) != null ? i : [], c = (l = r == null ? void 0 : r.map((f) => t.find((p) => p.id === f)).filter(Boolean)) != null ? l : [], d = t.filter((f) => !(o != null && o.includes(f.id)) && !(r != null && r.includes(f.id)));
|
|
4295
|
+
return Ue(n, [...s, ...d, ...c], e);
|
|
4296
4296
|
}, Z(e.options, ve, "getHeaderGroups")), e.getCenterHeaderGroups = Y(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => (t = t.filter((i) => !(o != null && o.includes(i.id)) && !(r != null && r.includes(i.id))), Ue(n, t, e, "center")), Z(e.options, ve, "getCenterHeaderGroups")), e.getLeftHeaderGroups = Y(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, o) => {
|
|
4297
4297
|
var r;
|
|
4298
4298
|
const i = (r = o == null ? void 0 : o.map((l) => t.find((s) => s.id === l)).filter(Boolean)) != null ? r : [];
|
|
@@ -4311,29 +4311,29 @@ const Sr = {
|
|
|
4311
4311
|
var o;
|
|
4312
4312
|
return !((o = t.subHeaders) != null && o.length);
|
|
4313
4313
|
}), Z(e.options, ve, "getRightLeafHeaders")), e.getLeafHeaders = Y(() => [e.getLeftHeaderGroups(), e.getCenterHeaderGroups(), e.getRightHeaderGroups()], (n, t, o) => {
|
|
4314
|
-
var r, i, l, s, c,
|
|
4315
|
-
return [...(r = (i = n[0]) == null ? void 0 : i.headers) != null ? r : [], ...(l = (s = t[0]) == null ? void 0 : s.headers) != null ? l : [], ...(c = (
|
|
4314
|
+
var r, i, l, s, c, d;
|
|
4315
|
+
return [...(r = (i = n[0]) == null ? void 0 : i.headers) != null ? r : [], ...(l = (s = t[0]) == null ? void 0 : s.headers) != null ? l : [], ...(c = (d = o[0]) == null ? void 0 : d.headers) != null ? c : []].map((u) => u.getLeafHeaders()).flat();
|
|
4316
4316
|
}, Z(e.options, ve, "getLeafHeaders"));
|
|
4317
4317
|
}
|
|
4318
4318
|
};
|
|
4319
4319
|
function Ue(e, n, t, o) {
|
|
4320
4320
|
var r, i;
|
|
4321
4321
|
let l = 0;
|
|
4322
|
-
const s = function(
|
|
4323
|
-
g === void 0 && (g = 1), l = Math.max(l, g),
|
|
4322
|
+
const s = function(p, g) {
|
|
4323
|
+
g === void 0 && (g = 1), l = Math.max(l, g), p.filter((v) => v.getIsVisible()).forEach((v) => {
|
|
4324
4324
|
var m;
|
|
4325
4325
|
(m = v.columns) != null && m.length && s(v.columns, g + 1);
|
|
4326
4326
|
}, 0);
|
|
4327
4327
|
};
|
|
4328
4328
|
s(e);
|
|
4329
4329
|
let c = [];
|
|
4330
|
-
const
|
|
4330
|
+
const d = (p, g) => {
|
|
4331
4331
|
const v = {
|
|
4332
4332
|
depth: g,
|
|
4333
4333
|
id: [o, `${g}`].filter(Boolean).join("_"),
|
|
4334
4334
|
headers: []
|
|
4335
4335
|
}, m = [];
|
|
4336
|
-
|
|
4336
|
+
p.forEach((h) => {
|
|
4337
4337
|
const j = [...m].reverse()[0], P = h.column.depth === v.depth;
|
|
4338
4338
|
let b, M = !1;
|
|
4339
4339
|
if (P && h.column.parent ? b = h.column.parent : (b = h.column, M = !0), j && (j == null ? void 0 : j.column) === b)
|
|
@@ -4349,13 +4349,13 @@ function Ue(e, n, t, o) {
|
|
|
4349
4349
|
w.subHeaders.push(h), m.push(w);
|
|
4350
4350
|
}
|
|
4351
4351
|
v.headers.push(h), h.headerGroup = v;
|
|
4352
|
-
}), c.push(v), g > 0 &&
|
|
4353
|
-
},
|
|
4352
|
+
}), c.push(v), g > 0 && d(m, g - 1);
|
|
4353
|
+
}, u = n.map((p, g) => xn(t, p, {
|
|
4354
4354
|
depth: l,
|
|
4355
4355
|
index: g
|
|
4356
4356
|
}));
|
|
4357
|
-
|
|
4358
|
-
const f = (
|
|
4357
|
+
d(u, l - 1), c.reverse();
|
|
4358
|
+
const f = (p) => p.filter((v) => v.column.getIsVisible()).map((v) => {
|
|
4359
4359
|
let m = 0, h = 0, j = [0];
|
|
4360
4360
|
v.subHeaders && v.subHeaders.length ? (j = [], f(v.subHeaders).forEach((b) => {
|
|
4361
4361
|
let {
|
|
@@ -4384,39 +4384,39 @@ const $r = (e, n, t, o, r, i, l) => {
|
|
|
4384
4384
|
getValue: (c) => {
|
|
4385
4385
|
if (s._valuesCache.hasOwnProperty(c))
|
|
4386
4386
|
return s._valuesCache[c];
|
|
4387
|
-
const
|
|
4388
|
-
if (
|
|
4389
|
-
return s._valuesCache[c] =
|
|
4387
|
+
const d = e.getColumn(c);
|
|
4388
|
+
if (d != null && d.accessorFn)
|
|
4389
|
+
return s._valuesCache[c] = d.accessorFn(s.original, o), s._valuesCache[c];
|
|
4390
4390
|
},
|
|
4391
4391
|
getUniqueValues: (c) => {
|
|
4392
4392
|
if (s._uniqueValuesCache.hasOwnProperty(c))
|
|
4393
4393
|
return s._uniqueValuesCache[c];
|
|
4394
|
-
const
|
|
4395
|
-
if (
|
|
4396
|
-
return
|
|
4394
|
+
const d = e.getColumn(c);
|
|
4395
|
+
if (d != null && d.accessorFn)
|
|
4396
|
+
return d.columnDef.getUniqueValues ? (s._uniqueValuesCache[c] = d.columnDef.getUniqueValues(s.original, o), s._uniqueValuesCache[c]) : (s._uniqueValuesCache[c] = [s.getValue(c)], s._uniqueValuesCache[c]);
|
|
4397
4397
|
},
|
|
4398
4398
|
renderValue: (c) => {
|
|
4399
|
-
var
|
|
4400
|
-
return (
|
|
4399
|
+
var d;
|
|
4400
|
+
return (d = s.getValue(c)) != null ? d : e.options.renderFallbackValue;
|
|
4401
4401
|
},
|
|
4402
4402
|
subRows: [],
|
|
4403
4403
|
getLeafRows: () => yr(s.subRows, (c) => c.subRows),
|
|
4404
4404
|
getParentRow: () => s.parentId ? e.getRow(s.parentId, !0) : void 0,
|
|
4405
4405
|
getParentRows: () => {
|
|
4406
|
-
let c = [],
|
|
4406
|
+
let c = [], d = s;
|
|
4407
4407
|
for (; ; ) {
|
|
4408
|
-
const
|
|
4409
|
-
if (!
|
|
4410
|
-
c.push(
|
|
4408
|
+
const u = d.getParentRow();
|
|
4409
|
+
if (!u) break;
|
|
4410
|
+
c.push(u), d = u;
|
|
4411
4411
|
}
|
|
4412
4412
|
return c.reverse();
|
|
4413
4413
|
},
|
|
4414
|
-
getAllCells: Y(() => [e.getAllLeafColumns()], (c) => c.map((
|
|
4415
|
-
_getAllCellsByColumnId: Y(() => [s.getAllCells()], (c) => c.reduce((
|
|
4414
|
+
getAllCells: Y(() => [e.getAllLeafColumns()], (c) => c.map((d) => Cr(e, s, d, d.id)), Z(e.options, "debugRows", "getAllCells")),
|
|
4415
|
+
_getAllCellsByColumnId: Y(() => [s.getAllCells()], (c) => c.reduce((d, u) => (d[u.column.id] = u, d), {}), Z(e.options, "debugRows", "getAllCellsByColumnId"))
|
|
4416
4416
|
};
|
|
4417
4417
|
for (let c = 0; c < e._features.length; c++) {
|
|
4418
|
-
const
|
|
4419
|
-
|
|
4418
|
+
const d = e._features[c];
|
|
4419
|
+
d == null || d.createRow == null || d.createRow(s, e);
|
|
4420
4420
|
}
|
|
4421
4421
|
return s;
|
|
4422
4422
|
}, kr = {
|
|
@@ -4523,18 +4523,18 @@ const Rr = {
|
|
|
4523
4523
|
return (t = (o = n.getState().columnFilters) == null ? void 0 : o.findIndex((r) => r.id === e.id)) != null ? t : -1;
|
|
4524
4524
|
}, e.setFilterValue = (t) => {
|
|
4525
4525
|
n.setColumnFilters((o) => {
|
|
4526
|
-
const r = e.getFilterFn(), i = o == null ? void 0 : o.find((
|
|
4526
|
+
const r = e.getFilterFn(), i = o == null ? void 0 : o.find((u) => u.id === e.id), l = Re(t, i ? i.value : void 0);
|
|
4527
4527
|
if (vn(r, l, e)) {
|
|
4528
4528
|
var s;
|
|
4529
|
-
return (s = o == null ? void 0 : o.filter((
|
|
4529
|
+
return (s = o == null ? void 0 : o.filter((u) => u.id !== e.id)) != null ? s : [];
|
|
4530
4530
|
}
|
|
4531
4531
|
const c = {
|
|
4532
4532
|
id: e.id,
|
|
4533
4533
|
value: l
|
|
4534
4534
|
};
|
|
4535
4535
|
if (i) {
|
|
4536
|
-
var
|
|
4537
|
-
return (
|
|
4536
|
+
var d;
|
|
4537
|
+
return (d = o == null ? void 0 : o.map((u) => u.id === e.id ? c : u)) != null ? d : [];
|
|
4538
4538
|
}
|
|
4539
4539
|
return o != null && o.length ? [...o, c] : [c];
|
|
4540
4540
|
});
|
|
@@ -4716,8 +4716,8 @@ const Or = {
|
|
|
4716
4716
|
else {
|
|
4717
4717
|
const l = [...n], s = [...r];
|
|
4718
4718
|
for (; s.length && l.length; ) {
|
|
4719
|
-
const c = l.shift(),
|
|
4720
|
-
|
|
4719
|
+
const c = l.shift(), d = s.findIndex((u) => u.id === c);
|
|
4720
|
+
d > -1 && i.push(s.splice(d, 1)[0]);
|
|
4721
4721
|
}
|
|
4722
4722
|
i = [...i, ...s];
|
|
4723
4723
|
}
|
|
@@ -4748,10 +4748,10 @@ const Or = {
|
|
|
4748
4748
|
};
|
|
4749
4749
|
}
|
|
4750
4750
|
if (t === "left") {
|
|
4751
|
-
var
|
|
4751
|
+
var d, u;
|
|
4752
4752
|
return {
|
|
4753
|
-
left: [...((
|
|
4754
|
-
right: ((
|
|
4753
|
+
left: [...((d = r == null ? void 0 : r.left) != null ? d : []).filter((f) => !(o != null && o.includes(f))), ...o],
|
|
4754
|
+
right: ((u = r == null ? void 0 : r.right) != null ? u : []).filter((f) => !(o != null && o.includes(f)))
|
|
4755
4755
|
};
|
|
4756
4756
|
}
|
|
4757
4757
|
return {
|
|
@@ -4868,13 +4868,13 @@ const Or = {
|
|
|
4868
4868
|
return (i) => {
|
|
4869
4869
|
if (!o || !r || (i.persist == null || i.persist(), yt(i) && i.touches && i.touches.length > 1))
|
|
4870
4870
|
return;
|
|
4871
|
-
const l = e.getSize(), s = e ? e.getLeafHeaders().map((j) => [j.column.id, j.column.getSize()]) : [[o.id, o.getSize()]], c = yt(i) ? Math.round(i.touches[0].clientX) : i.clientX,
|
|
4871
|
+
const l = e.getSize(), s = e ? e.getLeafHeaders().map((j) => [j.column.id, j.column.getSize()]) : [[o.id, o.getSize()]], c = yt(i) ? Math.round(i.touches[0].clientX) : i.clientX, d = {}, u = (j, P) => {
|
|
4872
4872
|
typeof P == "number" && (n.setColumnSizingInfo((b) => {
|
|
4873
4873
|
var M, w;
|
|
4874
4874
|
const O = n.options.columnResizeDirection === "rtl" ? -1 : 1, F = (P - ((M = b == null ? void 0 : b.startOffset) != null ? M : 0)) * O, V = Math.max(F / ((w = b == null ? void 0 : b.startSize) != null ? w : 0), -0.999999);
|
|
4875
4875
|
return b.columnSizingStart.forEach((q) => {
|
|
4876
4876
|
let [ee, ae] = q;
|
|
4877
|
-
|
|
4877
|
+
d[ee] = Math.round(Math.max(ae + ae * V, 0) * 100) / 100;
|
|
4878
4878
|
}), {
|
|
4879
4879
|
...b,
|
|
4880
4880
|
deltaOffset: F,
|
|
@@ -4882,10 +4882,10 @@ const Or = {
|
|
|
4882
4882
|
};
|
|
4883
4883
|
}), (n.options.columnResizeMode === "onChange" || j === "end") && n.setColumnSizing((b) => ({
|
|
4884
4884
|
...b,
|
|
4885
|
-
...
|
|
4885
|
+
...d
|
|
4886
4886
|
})));
|
|
4887
|
-
}, f = (j) =>
|
|
4888
|
-
|
|
4887
|
+
}, f = (j) => u("move", j), p = (j) => {
|
|
4888
|
+
u("end", j), n.setColumnSizingInfo((P) => ({
|
|
4889
4889
|
...P,
|
|
4890
4890
|
isResizingColumn: !1,
|
|
4891
4891
|
startOffset: null,
|
|
@@ -4897,13 +4897,13 @@ const Or = {
|
|
|
4897
4897
|
}, g = t || typeof document < "u" ? document : null, v = {
|
|
4898
4898
|
moveHandler: (j) => f(j.clientX),
|
|
4899
4899
|
upHandler: (j) => {
|
|
4900
|
-
g == null || g.removeEventListener("mousemove", v.moveHandler), g == null || g.removeEventListener("mouseup", v.upHandler),
|
|
4900
|
+
g == null || g.removeEventListener("mousemove", v.moveHandler), g == null || g.removeEventListener("mouseup", v.upHandler), p(j.clientX);
|
|
4901
4901
|
}
|
|
4902
4902
|
}, m = {
|
|
4903
4903
|
moveHandler: (j) => (j.cancelable && (j.preventDefault(), j.stopPropagation()), f(j.touches[0].clientX), !1),
|
|
4904
4904
|
upHandler: (j) => {
|
|
4905
4905
|
var P;
|
|
4906
|
-
g == null || g.removeEventListener("touchmove", m.moveHandler), g == null || g.removeEventListener("touchend", m.upHandler), j.cancelable && (j.preventDefault(), j.stopPropagation()),
|
|
4906
|
+
g == null || g.removeEventListener("touchmove", m.moveHandler), g == null || g.removeEventListener("touchend", m.upHandler), j.cancelable && (j.preventDefault(), j.stopPropagation()), p((P = j.touches[0]) == null ? void 0 : P.clientX);
|
|
4907
4907
|
}
|
|
4908
4908
|
}, h = Hr() ? {
|
|
4909
4909
|
passive: !1
|
|
@@ -5235,22 +5235,22 @@ const Br = {
|
|
|
5235
5235
|
e.pin = (t, o, r) => {
|
|
5236
5236
|
const i = o ? e.getLeafRows().map((c) => {
|
|
5237
5237
|
let {
|
|
5238
|
-
id:
|
|
5238
|
+
id: d
|
|
5239
5239
|
} = c;
|
|
5240
|
-
return
|
|
5240
|
+
return d;
|
|
5241
5241
|
}) : [], l = r ? e.getParentRows().map((c) => {
|
|
5242
5242
|
let {
|
|
5243
|
-
id:
|
|
5243
|
+
id: d
|
|
5244
5244
|
} = c;
|
|
5245
|
-
return
|
|
5245
|
+
return d;
|
|
5246
5246
|
}) : [], s = /* @__PURE__ */ new Set([...l, e.id, ...i]);
|
|
5247
5247
|
n.setRowPinning((c) => {
|
|
5248
|
-
var
|
|
5248
|
+
var d, u;
|
|
5249
5249
|
if (t === "bottom") {
|
|
5250
|
-
var f,
|
|
5250
|
+
var f, p;
|
|
5251
5251
|
return {
|
|
5252
5252
|
top: ((f = c == null ? void 0 : c.top) != null ? f : []).filter((m) => !(s != null && s.has(m))),
|
|
5253
|
-
bottom: [...((
|
|
5253
|
+
bottom: [...((p = c == null ? void 0 : c.bottom) != null ? p : []).filter((m) => !(s != null && s.has(m))), ...Array.from(s)]
|
|
5254
5254
|
};
|
|
5255
5255
|
}
|
|
5256
5256
|
if (t === "top") {
|
|
@@ -5261,8 +5261,8 @@ const Br = {
|
|
|
5261
5261
|
};
|
|
5262
5262
|
}
|
|
5263
5263
|
return {
|
|
5264
|
-
top: ((
|
|
5265
|
-
bottom: ((
|
|
5264
|
+
top: ((d = c == null ? void 0 : c.top) != null ? d : []).filter((m) => !(s != null && s.has(m))),
|
|
5265
|
+
bottom: ((u = c == null ? void 0 : c.bottom) != null ? u : []).filter((m) => !(s != null && s.has(m)))
|
|
5266
5266
|
};
|
|
5267
5267
|
});
|
|
5268
5268
|
}, e.getCanPin = () => {
|
|
@@ -5450,12 +5450,12 @@ const Br = {
|
|
|
5450
5450
|
function St(e, n) {
|
|
5451
5451
|
const t = e.getState().rowSelection, o = [], r = {}, i = function(l, s) {
|
|
5452
5452
|
return l.map((c) => {
|
|
5453
|
-
var
|
|
5454
|
-
const
|
|
5455
|
-
if (
|
|
5453
|
+
var d;
|
|
5454
|
+
const u = It(c, t);
|
|
5455
|
+
if (u && (o.push(c), r[c.id] = c), (d = c.subRows) != null && d.length && (c = {
|
|
5456
5456
|
...c,
|
|
5457
5457
|
subRows: i(c.subRows)
|
|
5458
|
-
}),
|
|
5458
|
+
}), u)
|
|
5459
5459
|
return c;
|
|
5460
5460
|
}).filter(Boolean);
|
|
5461
5461
|
};
|
|
@@ -5554,21 +5554,21 @@ const Te = {
|
|
|
5554
5554
|
const r = e.getNextSortingOrder(), i = typeof t < "u" && t !== null;
|
|
5555
5555
|
n.setSorting((l) => {
|
|
5556
5556
|
const s = l == null ? void 0 : l.find((g) => g.id === e.id), c = l == null ? void 0 : l.findIndex((g) => g.id === e.id);
|
|
5557
|
-
let
|
|
5558
|
-
if (l != null && l.length && e.getCanMultiSort() && o ? s ?
|
|
5559
|
-
var
|
|
5560
|
-
|
|
5557
|
+
let d = [], u, f = i ? t : r === "desc";
|
|
5558
|
+
if (l != null && l.length && e.getCanMultiSort() && o ? s ? u = "toggle" : u = "add" : l != null && l.length && c !== l.length - 1 ? u = "replace" : s ? u = "toggle" : u = "replace", u === "toggle" && (i || r || (u = "remove")), u === "add") {
|
|
5559
|
+
var p;
|
|
5560
|
+
d = [...l, {
|
|
5561
5561
|
id: e.id,
|
|
5562
5562
|
desc: f
|
|
5563
|
-
}],
|
|
5564
|
-
} else
|
|
5563
|
+
}], d.splice(0, d.length - ((p = n.options.maxMultiSortColCount) != null ? p : Number.MAX_SAFE_INTEGER));
|
|
5564
|
+
} else u === "toggle" ? d = l.map((g) => g.id === e.id ? {
|
|
5565
5565
|
...g,
|
|
5566
5566
|
desc: f
|
|
5567
|
-
} : g) :
|
|
5567
|
+
} : g) : u === "remove" ? d = l.filter((g) => g.id !== e.id) : d = [{
|
|
5568
5568
|
id: e.id,
|
|
5569
5569
|
desc: f
|
|
5570
5570
|
}];
|
|
5571
|
-
return
|
|
5571
|
+
return d;
|
|
5572
5572
|
});
|
|
5573
5573
|
}, e.getFirstSortDir = () => {
|
|
5574
5574
|
var t, o;
|
|
@@ -5633,20 +5633,20 @@ function ri(e) {
|
|
|
5633
5633
|
let r = {
|
|
5634
5634
|
_features: o
|
|
5635
5635
|
};
|
|
5636
|
-
const i = r._features.reduce((
|
|
5636
|
+
const i = r._features.reduce((p, g) => Object.assign(p, g.getDefaultOptions == null ? void 0 : g.getDefaultOptions(r)), {}), l = (p) => r.options.mergeOptions ? r.options.mergeOptions(i, p) : {
|
|
5637
5637
|
...i,
|
|
5638
|
-
...
|
|
5638
|
+
...p
|
|
5639
5639
|
};
|
|
5640
5640
|
let c = {
|
|
5641
5641
|
...{},
|
|
5642
5642
|
...(t = e.initialState) != null ? t : {}
|
|
5643
5643
|
};
|
|
5644
|
-
r._features.forEach((
|
|
5644
|
+
r._features.forEach((p) => {
|
|
5645
5645
|
var g;
|
|
5646
|
-
c = (g =
|
|
5646
|
+
c = (g = p.getInitialState == null ? void 0 : p.getInitialState(c)) != null ? g : c;
|
|
5647
5647
|
});
|
|
5648
|
-
const
|
|
5649
|
-
let
|
|
5648
|
+
const d = [];
|
|
5649
|
+
let u = !1;
|
|
5650
5650
|
const f = {
|
|
5651
5651
|
_features: o,
|
|
5652
5652
|
options: {
|
|
@@ -5654,11 +5654,11 @@ function ri(e) {
|
|
|
5654
5654
|
...e
|
|
5655
5655
|
},
|
|
5656
5656
|
initialState: c,
|
|
5657
|
-
_queue: (
|
|
5658
|
-
|
|
5659
|
-
for (;
|
|
5660
|
-
|
|
5661
|
-
|
|
5657
|
+
_queue: (p) => {
|
|
5658
|
+
d.push(p), u || (u = !0, Promise.resolve().then(() => {
|
|
5659
|
+
for (; d.length; )
|
|
5660
|
+
d.shift()();
|
|
5661
|
+
u = !1;
|
|
5662
5662
|
}).catch((g) => setTimeout(() => {
|
|
5663
5663
|
throw g;
|
|
5664
5664
|
})));
|
|
@@ -5666,32 +5666,32 @@ function ri(e) {
|
|
|
5666
5666
|
reset: () => {
|
|
5667
5667
|
r.setState(r.initialState);
|
|
5668
5668
|
},
|
|
5669
|
-
setOptions: (
|
|
5670
|
-
const g = Re(
|
|
5669
|
+
setOptions: (p) => {
|
|
5670
|
+
const g = Re(p, r.options);
|
|
5671
5671
|
r.options = l(g);
|
|
5672
5672
|
},
|
|
5673
5673
|
getState: () => r.options.state,
|
|
5674
|
-
setState: (
|
|
5675
|
-
r.options.onStateChange == null || r.options.onStateChange(
|
|
5674
|
+
setState: (p) => {
|
|
5675
|
+
r.options.onStateChange == null || r.options.onStateChange(p);
|
|
5676
5676
|
},
|
|
5677
|
-
_getRowId: (
|
|
5677
|
+
_getRowId: (p, g, v) => {
|
|
5678
5678
|
var m;
|
|
5679
|
-
return (m = r.options.getRowId == null ? void 0 : r.options.getRowId(
|
|
5679
|
+
return (m = r.options.getRowId == null ? void 0 : r.options.getRowId(p, g, v)) != null ? m : `${v ? [v.id, g].join(".") : g}`;
|
|
5680
5680
|
},
|
|
5681
5681
|
getCoreRowModel: () => (r._getCoreRowModel || (r._getCoreRowModel = r.options.getCoreRowModel(r)), r._getCoreRowModel()),
|
|
5682
5682
|
// The final calls start at the bottom of the model,
|
|
5683
5683
|
// expanded rows, which then work their way up
|
|
5684
5684
|
getRowModel: () => r.getPaginationRowModel(),
|
|
5685
5685
|
//in next version, we should just pass in the row model as the optional 2nd arg
|
|
5686
|
-
getRow: (
|
|
5687
|
-
let v = (g ? r.getPrePaginationRowModel() : r.getRowModel()).rowsById[
|
|
5688
|
-
if (!v && (v = r.getCoreRowModel().rowsById[
|
|
5689
|
-
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${
|
|
5686
|
+
getRow: (p, g) => {
|
|
5687
|
+
let v = (g ? r.getPrePaginationRowModel() : r.getRowModel()).rowsById[p];
|
|
5688
|
+
if (!v && (v = r.getCoreRowModel().rowsById[p], !v))
|
|
5689
|
+
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${p}`) : new Error();
|
|
5690
5690
|
return v;
|
|
5691
5691
|
},
|
|
5692
|
-
_getDefaultColumnDef: Y(() => [r.options.defaultColumn], (
|
|
5692
|
+
_getDefaultColumnDef: Y(() => [r.options.defaultColumn], (p) => {
|
|
5693
5693
|
var g;
|
|
5694
|
-
return
|
|
5694
|
+
return p = (g = p) != null ? g : {}, {
|
|
5695
5695
|
header: (v) => {
|
|
5696
5696
|
const m = v.header.column.columnDef;
|
|
5697
5697
|
return m.accessorKey ? m.accessorKey : m.accessorFn ? m.id : null;
|
|
@@ -5702,33 +5702,33 @@ function ri(e) {
|
|
|
5702
5702
|
return (m = (h = v.renderValue()) == null || h.toString == null ? void 0 : h.toString()) != null ? m : null;
|
|
5703
5703
|
},
|
|
5704
5704
|
...r._features.reduce((v, m) => Object.assign(v, m.getDefaultColumnDef == null ? void 0 : m.getDefaultColumnDef()), {}),
|
|
5705
|
-
...
|
|
5705
|
+
...p
|
|
5706
5706
|
};
|
|
5707
5707
|
}, Z(e, "debugColumns", "_getDefaultColumnDef")),
|
|
5708
5708
|
_getColumnDefs: () => r.options.columns,
|
|
5709
|
-
getAllColumns: Y(() => [r._getColumnDefs()], (
|
|
5709
|
+
getAllColumns: Y(() => [r._getColumnDefs()], (p) => {
|
|
5710
5710
|
const g = function(v, m, h) {
|
|
5711
5711
|
return h === void 0 && (h = 0), v.map((j) => {
|
|
5712
5712
|
const P = jr(r, j, h, m), b = j;
|
|
5713
5713
|
return P.columns = b.columns ? g(b.columns, P, h + 1) : [], P;
|
|
5714
5714
|
});
|
|
5715
5715
|
};
|
|
5716
|
-
return g(
|
|
5716
|
+
return g(p);
|
|
5717
5717
|
}, Z(e, "debugColumns", "getAllColumns")),
|
|
5718
|
-
getAllFlatColumns: Y(() => [r.getAllColumns()], (
|
|
5719
|
-
_getAllFlatColumnsById: Y(() => [r.getAllFlatColumns()], (
|
|
5720
|
-
getAllLeafColumns: Y(() => [r.getAllColumns(), r._getOrderColumnsFn()], (
|
|
5721
|
-
let v =
|
|
5718
|
+
getAllFlatColumns: Y(() => [r.getAllColumns()], (p) => p.flatMap((g) => g.getFlatColumns()), Z(e, "debugColumns", "getAllFlatColumns")),
|
|
5719
|
+
_getAllFlatColumnsById: Y(() => [r.getAllFlatColumns()], (p) => p.reduce((g, v) => (g[v.id] = v, g), {}), Z(e, "debugColumns", "getAllFlatColumnsById")),
|
|
5720
|
+
getAllLeafColumns: Y(() => [r.getAllColumns(), r._getOrderColumnsFn()], (p, g) => {
|
|
5721
|
+
let v = p.flatMap((m) => m.getLeafColumns());
|
|
5722
5722
|
return g(v);
|
|
5723
5723
|
}, Z(e, "debugColumns", "getAllLeafColumns")),
|
|
5724
|
-
getColumn: (
|
|
5725
|
-
const g = r._getAllFlatColumnsById()[
|
|
5726
|
-
return process.env.NODE_ENV !== "production" && !g && console.error(`[Table] Column with id '${
|
|
5724
|
+
getColumn: (p) => {
|
|
5725
|
+
const g = r._getAllFlatColumnsById()[p];
|
|
5726
|
+
return process.env.NODE_ENV !== "production" && !g && console.error(`[Table] Column with id '${p}' does not exist.`), g;
|
|
5727
5727
|
}
|
|
5728
5728
|
};
|
|
5729
5729
|
Object.assign(r, f);
|
|
5730
|
-
for (let
|
|
5731
|
-
const g = r._features[
|
|
5730
|
+
for (let p = 0; p < r._features.length; p++) {
|
|
5731
|
+
const g = r._features[p];
|
|
5732
5732
|
g == null || g.createTable == null || g.createTable(r);
|
|
5733
5733
|
}
|
|
5734
5734
|
return r;
|
|
@@ -5742,11 +5742,11 @@ function ii() {
|
|
|
5742
5742
|
}, o = function(r, i, l) {
|
|
5743
5743
|
i === void 0 && (i = 0);
|
|
5744
5744
|
const s = [];
|
|
5745
|
-
for (let
|
|
5746
|
-
const
|
|
5747
|
-
if (t.flatRows.push(
|
|
5745
|
+
for (let d = 0; d < r.length; d++) {
|
|
5746
|
+
const u = $r(e, e._getRowId(r[d], d, l), r[d], d, i, void 0, l == null ? void 0 : l.id);
|
|
5747
|
+
if (t.flatRows.push(u), t.rowsById[u.id] = u, s.push(u), e.options.getSubRows) {
|
|
5748
5748
|
var c;
|
|
5749
|
-
|
|
5749
|
+
u.originalSubRows = e.options.getSubRows(r[d], d), (c = u.originalSubRows) != null && c.length && (u.subRows = o(u.originalSubRows, i + 1, u));
|
|
5750
5750
|
}
|
|
5751
5751
|
}
|
|
5752
5752
|
return s;
|
|
@@ -5836,7 +5836,7 @@ const li = {
|
|
|
5836
5836
|
iconClass: l = "",
|
|
5837
5837
|
pageClass: s = ""
|
|
5838
5838
|
}) => {
|
|
5839
|
-
const c = Math.ceil(e / t),
|
|
5839
|
+
const c = Math.ceil(e / t), d = n === 1, u = n === c;
|
|
5840
5840
|
return c <= 1 ? null : /* @__PURE__ */ a.jsxs("div", { className: `flex items-center space-x-1 ${i}`, children: [
|
|
5841
5841
|
!r && /* @__PURE__ */ a.jsx(
|
|
5842
5842
|
$e,
|
|
@@ -5844,7 +5844,7 @@ const li = {
|
|
|
5844
5844
|
color: "dark",
|
|
5845
5845
|
icon: /* @__PURE__ */ a.jsx("svg", { className: "size-5", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M4.83582 12L11.0429 18.2071L12.4571 16.7929L7.66424 12L12.4571 7.20712L11.0429 5.79291L4.83582 12ZM10.4857 12L16.6928 18.2071L18.107 16.7929L13.3141 12L18.107 7.20712L16.6928 5.79291L10.4857 12Z" }) }),
|
|
5846
5846
|
onClick: () => o(1),
|
|
5847
|
-
disabled:
|
|
5847
|
+
disabled: d,
|
|
5848
5848
|
roundedFull: !0,
|
|
5849
5849
|
size: "small",
|
|
5850
5850
|
variant: "transparent",
|
|
@@ -5857,7 +5857,7 @@ const li = {
|
|
|
5857
5857
|
color: "dark",
|
|
5858
5858
|
icon: /* @__PURE__ */ a.jsx("svg", { className: "size-5", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M10.8284 12.0007L15.7782 16.9504L14.364 18.3646L8 12.0007L14.364 5.63672L15.7782 7.05093L10.8284 12.0007Z" }) }),
|
|
5859
5859
|
onClick: () => o(n - 1),
|
|
5860
|
-
disabled:
|
|
5860
|
+
disabled: d,
|
|
5861
5861
|
roundedFull: !0,
|
|
5862
5862
|
size: "small",
|
|
5863
5863
|
variant: "transparent",
|
|
@@ -5876,7 +5876,7 @@ const li = {
|
|
|
5876
5876
|
color: "dark",
|
|
5877
5877
|
icon: /* @__PURE__ */ a.jsx("svg", { className: "size-5", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z" }) }),
|
|
5878
5878
|
onClick: () => o(n + 1),
|
|
5879
|
-
disabled:
|
|
5879
|
+
disabled: u,
|
|
5880
5880
|
roundedFull: !0,
|
|
5881
5881
|
size: "small",
|
|
5882
5882
|
variant: "transparent",
|
|
@@ -5889,7 +5889,7 @@ const li = {
|
|
|
5889
5889
|
color: "dark",
|
|
5890
5890
|
icon: /* @__PURE__ */ a.jsx("svg", { className: "size-5", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M19.1642 12L12.9571 5.79291L11.5429 7.20712L16.3358 12L11.5429 16.7929L12.9571 18.2071L19.1642 12ZM13.5143 12L7.30722 5.79291L5.89301 7.20712L10.6859 12L5.89301 16.7929L7.30722 18.2071L13.5143 12Z" }) }),
|
|
5891
5891
|
onClick: () => o(c),
|
|
5892
|
-
disabled:
|
|
5892
|
+
disabled: u,
|
|
5893
5893
|
roundedFull: !0,
|
|
5894
5894
|
size: "small",
|
|
5895
5895
|
variant: "transparent",
|
|
@@ -5907,10 +5907,10 @@ const li = {
|
|
|
5907
5907
|
rowOptionArray: l = [5, 10, 15],
|
|
5908
5908
|
totalRecords: s = e.length,
|
|
5909
5909
|
className: c = "",
|
|
5910
|
-
paginationClassName:
|
|
5911
|
-
tdClassName:
|
|
5910
|
+
paginationClassName: d = "",
|
|
5911
|
+
tdClassName: u = "",
|
|
5912
5912
|
thClassName: f = "",
|
|
5913
|
-
responsive:
|
|
5913
|
+
responsive: p = !1
|
|
5914
5914
|
}) => {
|
|
5915
5915
|
const g = ai({
|
|
5916
5916
|
data: e,
|
|
@@ -5927,7 +5927,7 @@ const li = {
|
|
|
5927
5927
|
{
|
|
5928
5928
|
className: `relative overflow-y-auto flex flex-col ${c} `,
|
|
5929
5929
|
children: [
|
|
5930
|
-
/* @__PURE__ */ a.jsx("div", { className: `${
|
|
5930
|
+
/* @__PURE__ */ a.jsx("div", { className: `${p ? "overflow-x-auto" : ""}`, children: /* @__PURE__ */ a.jsxs("table", { className: "w-full relative border-collapse", children: [
|
|
5931
5931
|
/* @__PURE__ */ a.jsx("thead", { className: "sticky top-0 left-0 rounded-xl bg-color-[#FAFBFB] z-10 h-10", children: g.getHeaderGroups().map((v) => /* @__PURE__ */ a.jsx("tr", { children: v.headers.map((m) => /* @__PURE__ */ a.jsx(
|
|
5932
5932
|
"th",
|
|
5933
5933
|
{
|
|
@@ -5945,7 +5945,7 @@ const li = {
|
|
|
5945
5945
|
children: v.getVisibleCells().map((m) => /* @__PURE__ */ a.jsx(
|
|
5946
5946
|
"td",
|
|
5947
5947
|
{
|
|
5948
|
-
className: `px-2 py-4 font-normal text-sm text-color-gray-800 ${
|
|
5948
|
+
className: `px-2 py-4 font-normal text-sm text-color-gray-800 ${u}`,
|
|
5949
5949
|
children: m.column.columnDef.cell instanceof Function ? m.column.columnDef.cell(
|
|
5950
5950
|
m.getContext()
|
|
5951
5951
|
) : m.getValue()
|
|
@@ -5959,7 +5959,7 @@ const li = {
|
|
|
5959
5959
|
/* @__PURE__ */ a.jsxs(
|
|
5960
5960
|
"div",
|
|
5961
5961
|
{
|
|
5962
|
-
className: `w-full py-4 px-2 border-t border-color-gray-200 bg-color-[#FAFBFB] flex justify-between items-center ${
|
|
5962
|
+
className: `w-full py-4 px-2 border-t border-color-gray-200 bg-color-[#FAFBFB] flex justify-between items-center ${d} sticky bottom-0 z-10`,
|
|
5963
5963
|
children: [
|
|
5964
5964
|
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
5965
5965
|
/* @__PURE__ */ a.jsx(si, { variant: "body2", className: "hidden md:!flex", children: "Rows per page" }),
|
|
@@ -6058,8 +6058,8 @@ const li = {
|
|
|
6058
6058
|
defaultHeight: 100
|
|
6059
6059
|
};
|
|
6060
6060
|
}
|
|
6061
|
-
}, { classes: c, defaultWidth:
|
|
6062
|
-
f !== void 0 && (g.width = `${f}px`),
|
|
6061
|
+
}, { classes: c, defaultWidth: d, defaultHeight: u } = s(), f = t ?? d, p = o ?? u, g = {};
|
|
6062
|
+
f !== void 0 && (g.width = `${f}px`), p !== void 0 && (g.height = `${p}px`), n === "text" && t === void 0 && (g.width = "100%");
|
|
6063
6063
|
const v = [
|
|
6064
6064
|
i,
|
|
6065
6065
|
c,
|
|
@@ -6122,11 +6122,11 @@ const li = {
|
|
|
6122
6122
|
large: { track: "h-3", thumb: "w-5 h-5" }
|
|
6123
6123
|
};
|
|
6124
6124
|
function gi(e) {
|
|
6125
|
-
const n = pe(null), t = pe(null), o = pe(null), r = (c,
|
|
6126
|
-
if (c ===
|
|
6127
|
-
if (Array.isArray(c) && Array.isArray(
|
|
6128
|
-
if (c.length !==
|
|
6129
|
-
for (let
|
|
6125
|
+
const n = pe(null), t = pe(null), o = pe(null), r = (c, d) => {
|
|
6126
|
+
if (c === d) return !0;
|
|
6127
|
+
if (Array.isArray(c) && Array.isArray(d)) {
|
|
6128
|
+
if (c.length !== d.length) return !1;
|
|
6129
|
+
for (let u = 0; u < c.length; u++) if (c[u] !== d[u]) return !1;
|
|
6130
6130
|
return !0;
|
|
6131
6131
|
}
|
|
6132
6132
|
return !1;
|
|
@@ -6159,16 +6159,16 @@ const Vi = no(function({
|
|
|
6159
6159
|
max: l = 100,
|
|
6160
6160
|
step: s = 1,
|
|
6161
6161
|
color: c = "blue",
|
|
6162
|
-
size:
|
|
6163
|
-
disabled:
|
|
6162
|
+
size: d = "medium",
|
|
6163
|
+
disabled: u = !1,
|
|
6164
6164
|
className: f = "",
|
|
6165
|
-
showValue:
|
|
6165
|
+
showValue: p = !0,
|
|
6166
6166
|
showMarks: g = !1,
|
|
6167
6167
|
marks: v = [],
|
|
6168
6168
|
range: m = !1,
|
|
6169
6169
|
minDistance: h = 0
|
|
6170
6170
|
}) {
|
|
6171
|
-
const j = n !== void 0, [P, b] = X(() => t !== void 0 ? t : m ? [i, l] : i), M = j ? n : P, w = Array.isArray(M) ? M[0] : M, [O, F] = Array.isArray(M) ? M : [M, M], V = $t[c] || $t.blue, q = hn[
|
|
6171
|
+
const j = n !== void 0, [P, b] = X(() => t !== void 0 ? t : m ? [i, l] : i), M = j ? n : P, w = Array.isArray(M) ? M[0] : M, [O, F] = Array.isArray(M) ? M : [M, M], V = $t[c] || $t.blue, q = hn[d] ?? hn.medium, ee = oe(
|
|
6172
6172
|
(_) => (_ - i) / (l - i) * 100,
|
|
6173
6173
|
[i, l]
|
|
6174
6174
|
), ae = ee(w), ce = ee(O), D = ee(F), I = oe((_) => Math.max(i, Math.min(l, _)), [i, l]), W = oe((_) => Math.round(_ / s) * s, [s]), T = gi(o), J = oe(
|
|
@@ -6207,7 +6207,7 @@ const Vi = no(function({
|
|
|
6207
6207
|
), [k, A] = X(null), [z, N] = X(null), [$, R] = X(null), H = oe(
|
|
6208
6208
|
(_, Q) => {
|
|
6209
6209
|
var U, ie;
|
|
6210
|
-
if (
|
|
6210
|
+
if (u) return;
|
|
6211
6211
|
_.preventDefault(), (ie = (U = _.currentTarget).setPointerCapture) == null || ie.call(U, _.pointerId), R(_.pointerId);
|
|
6212
6212
|
const C = y(_.clientX);
|
|
6213
6213
|
if (m) {
|
|
@@ -6217,7 +6217,7 @@ const Vi = no(function({
|
|
|
6217
6217
|
A("single"), J(K(C, "single"));
|
|
6218
6218
|
},
|
|
6219
6219
|
[
|
|
6220
|
-
|
|
6220
|
+
u,
|
|
6221
6221
|
m,
|
|
6222
6222
|
y,
|
|
6223
6223
|
E,
|
|
@@ -6228,12 +6228,12 @@ const Vi = no(function({
|
|
|
6228
6228
|
]
|
|
6229
6229
|
), B = oe(
|
|
6230
6230
|
(_) => {
|
|
6231
|
-
if (
|
|
6231
|
+
if (u || $ == null || k == null) return;
|
|
6232
6232
|
const Q = y(_.clientX);
|
|
6233
6233
|
m ? k === "min" ? J(K([Q, F], "min")) : k === "max" && J(K([O, Q], "max")) : J(K(Q, "single"));
|
|
6234
6234
|
},
|
|
6235
6235
|
[
|
|
6236
|
-
|
|
6236
|
+
u,
|
|
6237
6237
|
$,
|
|
6238
6238
|
k,
|
|
6239
6239
|
m,
|
|
@@ -6247,7 +6247,7 @@ const Vi = no(function({
|
|
|
6247
6247
|
k != null && (A(null), R(null), de());
|
|
6248
6248
|
}, [k, de]), S = oe(
|
|
6249
6249
|
(_, Q) => {
|
|
6250
|
-
if (
|
|
6250
|
+
if (u) return;
|
|
6251
6251
|
const C = m ? Q === "min" ? O : F : w;
|
|
6252
6252
|
let U = C;
|
|
6253
6253
|
const ie = (l - i) / 10;
|
|
@@ -6278,7 +6278,7 @@ const Vi = no(function({
|
|
|
6278
6278
|
_.preventDefault(), J(m ? Q === "min" ? K([U, F], "min") : K([O, U], "max") : K(U, "single"), !1), r == null || r(j ? n : M);
|
|
6279
6279
|
},
|
|
6280
6280
|
[
|
|
6281
|
-
|
|
6281
|
+
u,
|
|
6282
6282
|
m,
|
|
6283
6283
|
w,
|
|
6284
6284
|
O,
|
|
@@ -6309,7 +6309,7 @@ const Vi = no(function({
|
|
|
6309
6309
|
ref: x,
|
|
6310
6310
|
className: `
|
|
6311
6311
|
relative w-full ${q.track} ${V.track} rounded-full
|
|
6312
|
-
${
|
|
6312
|
+
${u ? "opacity-60 cursor-not-allowed" : "cursor-pointer"}
|
|
6313
6313
|
`,
|
|
6314
6314
|
onPointerDown: (_) => H(_),
|
|
6315
6315
|
onPointerMove: B,
|
|
@@ -6346,19 +6346,19 @@ const Vi = no(function({
|
|
|
6346
6346
|
className: `
|
|
6347
6347
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2
|
|
6348
6348
|
${q.thumb} ${V.thumb} ${V.thumbHover} ${V.thumbActive}
|
|
6349
|
-
rounded-full border-2 ${
|
|
6349
|
+
rounded-full border-2 ${u ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6350
6350
|
${k === "single" ? "cursor-grabbing scale-110" : k ? "" : "transition-all duration-150"}
|
|
6351
6351
|
${z === "single" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6352
6352
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6353
6353
|
`,
|
|
6354
6354
|
style: { left: `${ae}%` },
|
|
6355
|
-
tabIndex:
|
|
6355
|
+
tabIndex: u ? -1 : 0,
|
|
6356
6356
|
role: "slider",
|
|
6357
6357
|
"aria-orientation": "horizontal",
|
|
6358
6358
|
"aria-valuemin": i,
|
|
6359
6359
|
"aria-valuemax": l,
|
|
6360
6360
|
"aria-valuenow": w,
|
|
6361
|
-
"aria-disabled":
|
|
6361
|
+
"aria-disabled": u,
|
|
6362
6362
|
onKeyDown: (_) => S(_, "single"),
|
|
6363
6363
|
onFocus: () => N("single"),
|
|
6364
6364
|
onBlur: () => N(null),
|
|
@@ -6372,19 +6372,19 @@ const Vi = no(function({
|
|
|
6372
6372
|
className: `
|
|
6373
6373
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2 z-10
|
|
6374
6374
|
${q.thumb} ${V.thumb} ${V.thumbHover} ${V.thumbActive}
|
|
6375
|
-
rounded-full border-2 ${
|
|
6375
|
+
rounded-full border-2 ${u ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6376
6376
|
${k === "min" ? "cursor-grabbing scale-110 z-20" : k ? "" : "transition-all duration-150"}
|
|
6377
6377
|
${z === "min" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6378
6378
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6379
6379
|
`,
|
|
6380
6380
|
style: { left: `${ce}%` },
|
|
6381
|
-
tabIndex:
|
|
6381
|
+
tabIndex: u ? -1 : 0,
|
|
6382
6382
|
role: "slider",
|
|
6383
6383
|
"aria-orientation": "horizontal",
|
|
6384
6384
|
"aria-valuemin": i,
|
|
6385
6385
|
"aria-valuemax": l,
|
|
6386
6386
|
"aria-valuenow": O,
|
|
6387
|
-
"aria-disabled":
|
|
6387
|
+
"aria-disabled": u,
|
|
6388
6388
|
"aria-label": "Minimum value",
|
|
6389
6389
|
onKeyDown: (_) => S(_, "min"),
|
|
6390
6390
|
onFocus: () => N("min"),
|
|
@@ -6398,19 +6398,19 @@ const Vi = no(function({
|
|
|
6398
6398
|
className: `
|
|
6399
6399
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2 z-10
|
|
6400
6400
|
${q.thumb} ${V.thumb} ${V.thumbHover} ${V.thumbActive}
|
|
6401
|
-
rounded-full border-2 ${
|
|
6401
|
+
rounded-full border-2 ${u ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6402
6402
|
${k === "max" ? "cursor-grabbing scale-110 z-20" : k ? "" : "transition-all duration-150"}
|
|
6403
6403
|
${z === "max" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6404
6404
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6405
6405
|
`,
|
|
6406
6406
|
style: { left: `${D}%` },
|
|
6407
|
-
tabIndex:
|
|
6407
|
+
tabIndex: u ? -1 : 0,
|
|
6408
6408
|
role: "slider",
|
|
6409
6409
|
"aria-orientation": "horizontal",
|
|
6410
6410
|
"aria-valuemin": i,
|
|
6411
6411
|
"aria-valuemax": l,
|
|
6412
6412
|
"aria-valuenow": F,
|
|
6413
|
-
"aria-disabled":
|
|
6413
|
+
"aria-disabled": u,
|
|
6414
6414
|
"aria-label": "Maximum value",
|
|
6415
6415
|
onKeyDown: (_) => S(_, "max"),
|
|
6416
6416
|
onFocus: () => N("max"),
|
|
@@ -6441,7 +6441,7 @@ const Vi = no(function({
|
|
|
6441
6441
|
}
|
|
6442
6442
|
)
|
|
6443
6443
|
] }),
|
|
6444
|
-
|
|
6444
|
+
p && /* @__PURE__ */ a.jsx("div", { className: "ml-3 text-sm font-medium text-color-gray-700 dark:text-color-gray-200 min-w-[2rem] text-right", children: m ? /* @__PURE__ */ a.jsx("div", { className: "range-max", children: /* @__PURE__ */ a.jsx("div", { children: F }) }) : /* @__PURE__ */ a.jsx("span", { children: w }) })
|
|
6445
6445
|
] }) });
|
|
6446
6446
|
}), Hi = ({
|
|
6447
6447
|
open: e = !1,
|
|
@@ -6456,23 +6456,23 @@ const Vi = no(function({
|
|
|
6456
6456
|
var f;
|
|
6457
6457
|
se(() => {
|
|
6458
6458
|
if (e && t > 0 && i) {
|
|
6459
|
-
const
|
|
6459
|
+
const p = setTimeout(() => {
|
|
6460
6460
|
i();
|
|
6461
6461
|
}, t);
|
|
6462
|
-
return () => clearTimeout(
|
|
6462
|
+
return () => clearTimeout(p);
|
|
6463
6463
|
}
|
|
6464
6464
|
}, [e, t, i]), se(() => {
|
|
6465
|
-
const
|
|
6465
|
+
const p = (g) => {
|
|
6466
6466
|
g.key === "Escape" && e && i && i();
|
|
6467
6467
|
};
|
|
6468
6468
|
if (e)
|
|
6469
|
-
return document.addEventListener("keydown",
|
|
6469
|
+
return document.addEventListener("keydown", p), () => document.removeEventListener("keydown", p);
|
|
6470
6470
|
}, [e, i]);
|
|
6471
6471
|
const c = oe(() => {
|
|
6472
6472
|
i && i();
|
|
6473
|
-
}, [i]),
|
|
6473
|
+
}, [i]), d = (p) => {
|
|
6474
6474
|
const g = "fixed z-50 transform transition-all duration-300 ease-in-out";
|
|
6475
|
-
switch (
|
|
6475
|
+
switch (p) {
|
|
6476
6476
|
case "top-center":
|
|
6477
6477
|
return `${g} top-4 left-1/2 -translate-x-1/2 ${e ? "translate-y-0 opacity-100" : "-translate-y-full opacity-0"}`;
|
|
6478
6478
|
case "top-left":
|
|
@@ -6487,7 +6487,7 @@ const Vi = no(function({
|
|
|
6487
6487
|
default:
|
|
6488
6488
|
return `${g} bottom-4 left-1/2 -translate-x-1/2 ${e ? "translate-y-0 opacity-100" : "translate-y-full opacity-0"}`;
|
|
6489
6489
|
}
|
|
6490
|
-
},
|
|
6490
|
+
}, u = (f = xe[r]) == null ? void 0 : f.filled;
|
|
6491
6491
|
return e ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6492
6492
|
e && /* @__PURE__ */ a.jsx(
|
|
6493
6493
|
"div",
|
|
@@ -6500,7 +6500,7 @@ const Vi = no(function({
|
|
|
6500
6500
|
"div",
|
|
6501
6501
|
{
|
|
6502
6502
|
className: `min-w-72 max-w-lg mx-4 px-4 py-2 rounded-lg shadow-xl flex items-center justify-between gap-3 backdrop-blur-sm border border-color-white/20
|
|
6503
|
-
${
|
|
6503
|
+
${d(o)} ${u} ${s}`,
|
|
6504
6504
|
role: "alert",
|
|
6505
6505
|
"aria-live": "assertive",
|
|
6506
6506
|
"aria-atomic": "true",
|
|
@@ -6533,15 +6533,15 @@ const Vi = no(function({
|
|
|
6533
6533
|
className: r = "",
|
|
6534
6534
|
...i
|
|
6535
6535
|
}) => {
|
|
6536
|
-
var
|
|
6537
|
-
const l = (
|
|
6536
|
+
var u, f;
|
|
6537
|
+
const l = (u = xe[t]) == null ? void 0 : u.outline, s = (f = xe[t]) == null ? void 0 : f.filled, c = Math.min(Math.max(n, 0), 100);
|
|
6538
6538
|
if (e === "circular") {
|
|
6539
|
-
const { size:
|
|
6539
|
+
const { size: p = 40, thickness: g = 4 } = i, v = o ? c / 100 * 360 : 270;
|
|
6540
6540
|
return /* @__PURE__ */ a.jsxs(
|
|
6541
6541
|
"div",
|
|
6542
6542
|
{
|
|
6543
6543
|
className: `relative inline-block ${r}`,
|
|
6544
|
-
style: { width:
|
|
6544
|
+
style: { width: p, height: p },
|
|
6545
6545
|
role: "progressbar",
|
|
6546
6546
|
"aria-valuenow": o ? c : void 0,
|
|
6547
6547
|
"aria-valuemin": 0,
|
|
@@ -6553,8 +6553,8 @@ const Vi = no(function({
|
|
|
6553
6553
|
className: "absolute inset-0 rounded-full border-4 border-color-gray-200 dark:border-color-gray-700",
|
|
6554
6554
|
style: {
|
|
6555
6555
|
borderWidth: g,
|
|
6556
|
-
width:
|
|
6557
|
-
height:
|
|
6556
|
+
width: p,
|
|
6557
|
+
height: p,
|
|
6558
6558
|
boxSizing: "border-box"
|
|
6559
6559
|
}
|
|
6560
6560
|
}
|
|
@@ -6564,8 +6564,8 @@ const Vi = no(function({
|
|
|
6564
6564
|
{
|
|
6565
6565
|
className: `absolute inset-0 rounded-full ${l} ${o ? "" : "animate-circular-indeterminate"}`,
|
|
6566
6566
|
style: {
|
|
6567
|
-
width:
|
|
6568
|
-
height:
|
|
6567
|
+
width: p,
|
|
6568
|
+
height: p,
|
|
6569
6569
|
borderWidth: g,
|
|
6570
6570
|
borderStyle: "solid",
|
|
6571
6571
|
transform: "rotate(-90deg)",
|
|
@@ -6582,7 +6582,7 @@ const Vi = no(function({
|
|
|
6582
6582
|
}
|
|
6583
6583
|
);
|
|
6584
6584
|
}
|
|
6585
|
-
const { thickness:
|
|
6585
|
+
const { thickness: d = 4 } = i;
|
|
6586
6586
|
return /* @__PURE__ */ a.jsx(
|
|
6587
6587
|
"div",
|
|
6588
6588
|
{
|
|
@@ -6595,7 +6595,7 @@ const Vi = no(function({
|
|
|
6595
6595
|
"div",
|
|
6596
6596
|
{
|
|
6597
6597
|
className: "w-full bg-color-gray-200 dark:bg-color-gray-700 rounded-full overflow-hidden relative",
|
|
6598
|
-
style: { height: `${
|
|
6598
|
+
style: { height: `${d}px` },
|
|
6599
6599
|
children: o ? /* @__PURE__ */ a.jsx(
|
|
6600
6600
|
"div",
|
|
6601
6601
|
{
|
|
@@ -6627,10 +6627,10 @@ const Vi = no(function({
|
|
|
6627
6627
|
size: l = "medium",
|
|
6628
6628
|
icon: s,
|
|
6629
6629
|
emptyIcon: c,
|
|
6630
|
-
className:
|
|
6631
|
-
showHoverValue:
|
|
6630
|
+
className: d = "",
|
|
6631
|
+
showHoverValue: u = !1,
|
|
6632
6632
|
showValue: f = !1,
|
|
6633
|
-
labels:
|
|
6633
|
+
labels: p = {}
|
|
6634
6634
|
// <-- Add this
|
|
6635
6635
|
}) => {
|
|
6636
6636
|
const [g, v] = Se.useState(null), m = (b, M) => {
|
|
@@ -6682,9 +6682,9 @@ const Vi = no(function({
|
|
|
6682
6682
|
)
|
|
6683
6683
|
);
|
|
6684
6684
|
}
|
|
6685
|
-
return /* @__PURE__ */ a.jsxs("div", { className: `flex items-center gap-1 ${
|
|
6685
|
+
return /* @__PURE__ */ a.jsxs("div", { className: `flex items-center gap-1 ${d}`, role: "radiogroup", "aria-disabled": o, children: [
|
|
6686
6686
|
P,
|
|
6687
|
-
|
|
6687
|
+
u && g !== null ? /* @__PURE__ */ a.jsx("span", { className: "ml-2 text-xs", children: p[g] || g }) : f ? /* @__PURE__ */ a.jsx("span", { className: "ml-2 text-xs", children: p[e] || e }) : null
|
|
6688
6688
|
] });
|
|
6689
6689
|
}, Gi = ({
|
|
6690
6690
|
children: e,
|
|
@@ -6696,10 +6696,10 @@ const Vi = no(function({
|
|
|
6696
6696
|
interval: l = 3e3,
|
|
6697
6697
|
infiniteLoop: s = !1,
|
|
6698
6698
|
perview: c = 1,
|
|
6699
|
-
gap:
|
|
6700
|
-
onClickItem:
|
|
6699
|
+
gap: d = 0,
|
|
6700
|
+
onClickItem: u,
|
|
6701
6701
|
showThumbs: f = !1,
|
|
6702
|
-
pauseOnHover:
|
|
6702
|
+
pauseOnHover: p = !1,
|
|
6703
6703
|
swipeable: g = !0,
|
|
6704
6704
|
thumbWidth: v = 60,
|
|
6705
6705
|
orientation: m = "horizontal",
|
|
@@ -6715,7 +6715,7 @@ const Vi = no(function({
|
|
|
6715
6715
|
s && T > 0 ? O(w >= T ? 0 : w + 1) : de(w + 1);
|
|
6716
6716
|
};
|
|
6717
6717
|
se(() => {
|
|
6718
|
-
if (!i ||
|
|
6718
|
+
if (!i || p && F || q || T === 0)
|
|
6719
6719
|
return;
|
|
6720
6720
|
const $ = setInterval(() => {
|
|
6721
6721
|
O((R) => {
|
|
@@ -6728,7 +6728,7 @@ const Vi = no(function({
|
|
|
6728
6728
|
i,
|
|
6729
6729
|
l,
|
|
6730
6730
|
F,
|
|
6731
|
-
|
|
6731
|
+
p,
|
|
6732
6732
|
q,
|
|
6733
6733
|
T,
|
|
6734
6734
|
s
|
|
@@ -6747,7 +6747,7 @@ const Vi = no(function({
|
|
|
6747
6747
|
const Q = m === "horizontal" ? D.current.offsetWidth : D.current.offsetHeight;
|
|
6748
6748
|
R = ae / Q * 100 * (M / b);
|
|
6749
6749
|
}
|
|
6750
|
-
const B = Math.min(w, T) * (100 / b) - R, re = w >= T, _ = w <= 0 ? 0 : re ?
|
|
6750
|
+
const B = Math.min(w, T) * (100 / b) - R, re = w >= T, _ = w <= 0 ? 0 : re ? d / (c / 2) : d / c;
|
|
6751
6751
|
return `translate${$}(calc(-${B}% - ${_}px))`;
|
|
6752
6752
|
}, z = () => M >= b ? 1 : Math.floor(T) + 1, N = () => T === 0 ? 0 : Math.round(w / T * (z() - 1));
|
|
6753
6753
|
return /* @__PURE__ */ a.jsxs(
|
|
@@ -6755,8 +6755,8 @@ const Vi = no(function({
|
|
|
6755
6755
|
{
|
|
6756
6756
|
className: `relative flex flex-col items-center select-none ${P}`,
|
|
6757
6757
|
style: { width: n, height: t },
|
|
6758
|
-
onMouseEnter: () =>
|
|
6759
|
-
onMouseLeave: () =>
|
|
6758
|
+
onMouseEnter: () => p && V(!0),
|
|
6759
|
+
onMouseLeave: () => p && V(!1),
|
|
6760
6760
|
children: [
|
|
6761
6761
|
/* @__PURE__ */ a.jsxs(
|
|
6762
6762
|
"div",
|
|
@@ -6784,7 +6784,7 @@ const Vi = no(function({
|
|
|
6784
6784
|
width: m === "horizontal" ? `${b * 100 / M}%` : "100%",
|
|
6785
6785
|
height: m === "vertical" ? `${b * 100 / M}%` : "100%",
|
|
6786
6786
|
transform: A(),
|
|
6787
|
-
gap: `${
|
|
6787
|
+
gap: `${d}px`,
|
|
6788
6788
|
transitionProperty: q ? "none" : "transform"
|
|
6789
6789
|
},
|
|
6790
6790
|
children: e.map(($, R) => /* @__PURE__ */ a.jsx(
|
|
@@ -6792,10 +6792,10 @@ const Vi = no(function({
|
|
|
6792
6792
|
{
|
|
6793
6793
|
className: "shrink-0 flex items-center justify-center",
|
|
6794
6794
|
style: {
|
|
6795
|
-
width: m === "horizontal" ? `calc(${100 / b}% - ${
|
|
6796
|
-
height: m === "vertical" ? `calc(${100 / b}% - ${
|
|
6795
|
+
width: m === "horizontal" ? `calc(${100 / b}% - ${d / c}px)` : "100%",
|
|
6796
|
+
height: m === "vertical" ? `calc(${100 / b}% - ${d * (b - 1) / b}px)` : "100%"
|
|
6797
6797
|
},
|
|
6798
|
-
onClick: () => !q && (
|
|
6798
|
+
onClick: () => !q && (u == null ? void 0 : u(R)),
|
|
6799
6799
|
children: $
|
|
6800
6800
|
},
|
|
6801
6801
|
R
|
|
@@ -6885,7 +6885,7 @@ const Vi = no(function({
|
|
|
6885
6885
|
children: l,
|
|
6886
6886
|
color: s = "gray",
|
|
6887
6887
|
titleClass: c = "",
|
|
6888
|
-
descriptionClass:
|
|
6888
|
+
descriptionClass: d = ""
|
|
6889
6889
|
}) => /* @__PURE__ */ a.jsxs(
|
|
6890
6890
|
"section",
|
|
6891
6891
|
{
|
|
@@ -6905,7 +6905,7 @@ const Vi = no(function({
|
|
|
6905
6905
|
}
|
|
6906
6906
|
),
|
|
6907
6907
|
/* @__PURE__ */ a.jsx("h2", { className: `text-lg mt-4 font-semibold text-color-gray-800 ${c}`, children: e }),
|
|
6908
|
-
n && /* @__PURE__ */ a.jsx("p", { className: `text-sm mt-2 text-color-gray-600 ${
|
|
6908
|
+
n && /* @__PURE__ */ a.jsx("p", { className: `text-sm mt-2 text-color-gray-600 ${d}`, children: n }),
|
|
6909
6909
|
t && o && /* @__PURE__ */ a.jsx(kt, { onClick: o, color: s, className: "mt-4", children: t }),
|
|
6910
6910
|
l
|
|
6911
6911
|
]
|
|
@@ -6919,17 +6919,17 @@ const Vi = no(function({
|
|
|
6919
6919
|
variant: i = "ios"
|
|
6920
6920
|
// <-- default to ios
|
|
6921
6921
|
}) => {
|
|
6922
|
-
var f,
|
|
6923
|
-
const [l, s] = X(e), [c,
|
|
6922
|
+
var f, p, g;
|
|
6923
|
+
const [l, s] = X(e), [c, d] = X(!1), u = async () => {
|
|
6924
6924
|
if (!(t || c))
|
|
6925
6925
|
if (n) {
|
|
6926
|
-
|
|
6926
|
+
d(!0);
|
|
6927
6927
|
try {
|
|
6928
6928
|
await n(!l), s(!l);
|
|
6929
6929
|
} catch (v) {
|
|
6930
6930
|
console.error("Toggle failed", v);
|
|
6931
6931
|
} finally {
|
|
6932
|
-
|
|
6932
|
+
d(!1);
|
|
6933
6933
|
}
|
|
6934
6934
|
} else
|
|
6935
6935
|
s(!l);
|
|
@@ -6937,7 +6937,7 @@ const Vi = no(function({
|
|
|
6937
6937
|
return i === "android" ? /* @__PURE__ */ a.jsxs(
|
|
6938
6938
|
"button",
|
|
6939
6939
|
{
|
|
6940
|
-
onClick:
|
|
6940
|
+
onClick: u,
|
|
6941
6941
|
type: o,
|
|
6942
6942
|
disabled: t,
|
|
6943
6943
|
className: `relative w-10 h-3 flex items-center transition-color duration-300
|
|
@@ -6947,7 +6947,7 @@ const Vi = no(function({
|
|
|
6947
6947
|
/* @__PURE__ */ a.jsx(
|
|
6948
6948
|
"div",
|
|
6949
6949
|
{
|
|
6950
|
-
className: `flex justify-center items-center absolute shadow-md top-0.5 left-0.5 size-5 rounded-full shadow transition-all duration-300 ${l ? `translate-x-5 ${(
|
|
6950
|
+
className: `flex justify-center items-center absolute shadow-md top-0.5 left-0.5 size-5 rounded-full shadow transition-all duration-300 ${l ? `translate-x-5 ${(p = xe[r]) == null ? void 0 : p.filled}` : "translate-x-0 bg-color-white"}`,
|
|
6951
6951
|
children: c ? /* @__PURE__ */ a.jsx("svg", { className: "animate-spin text-color-gray-500 size-3", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M11.9995 2C12.5518 2 12.9995 2.44772 12.9995 3V6C12.9995 6.55228 12.5518 7 11.9995 7C11.4472 7 10.9995 6.55228 10.9995 6V3C10.9995 2.44772 11.4472 2 11.9995 2ZM11.9995 17C12.5518 17 12.9995 17.4477 12.9995 18V21C12.9995 21.5523 12.5518 22 11.9995 22C11.4472 22 10.9995 21.5523 10.9995 21V18C10.9995 17.4477 11.4472 17 11.9995 17ZM20.6597 7C20.9359 7.47829 20.772 8.08988 20.2937 8.36602L17.6956 9.86602C17.2173 10.1422 16.6057 9.97829 16.3296 9.5C16.0535 9.02171 16.2173 8.41012 16.6956 8.13398L19.2937 6.63397C19.772 6.35783 20.3836 6.52171 20.6597 7ZM7.66935 14.5C7.94549 14.9783 7.78161 15.5899 7.30332 15.866L4.70525 17.366C4.22695 17.6422 3.61536 17.4783 3.33922 17C3.06308 16.5217 3.22695 15.9101 3.70525 15.634L6.30332 14.134C6.78161 13.8578 7.3932 14.0217 7.66935 14.5ZM20.6597 17C20.3836 17.4783 19.772 17.6422 19.2937 17.366L16.6956 15.866C16.2173 15.5899 16.0535 14.9783 16.3296 14.5C16.6057 14.0217 17.2173 13.8578 17.6956 14.134L20.2937 15.634C20.772 15.9101 20.9359 16.5217 20.6597 17ZM7.66935 9.5C7.3932 9.97829 6.78161 10.1422 6.30332 9.86602L3.70525 8.36602C3.22695 8.08988 3.06308 7.47829 3.33922 7C3.61536 6.52171 4.22695 6.35783 4.70525 6.63397L7.30332 8.13398C7.78161 8.41012 7.94549 9.02171 7.66935 9.5Z" }) }) : null
|
|
6952
6952
|
}
|
|
6953
6953
|
)
|
|
@@ -6956,7 +6956,7 @@ const Vi = no(function({
|
|
|
6956
6956
|
) : /* @__PURE__ */ a.jsx(
|
|
6957
6957
|
"button",
|
|
6958
6958
|
{
|
|
6959
|
-
onClick:
|
|
6959
|
+
onClick: u,
|
|
6960
6960
|
type: o,
|
|
6961
6961
|
disabled: t,
|
|
6962
6962
|
className: `relative w-11 h-6 flex items-center rounded-full transition-color duration-300 ${l ? (g = xe[r]) == null ? void 0 : g.filled : "bg-color-gray-300"} ${t ? "bg-color-gray-300 opacity-50 cursor-not-allowed" : "cursor-pointer"}`,
|
|
@@ -6983,44 +6983,44 @@ const Vi = no(function({
|
|
|
6983
6983
|
orientation: l = "horizontal",
|
|
6984
6984
|
className: s = "",
|
|
6985
6985
|
buttonClass: c = "",
|
|
6986
|
-
disabled:
|
|
6986
|
+
disabled: d = !1
|
|
6987
6987
|
}) => {
|
|
6988
|
-
const
|
|
6989
|
-
if (!
|
|
6988
|
+
const u = (p) => Array.isArray(e) ? e.includes(p) : e === p, f = (p) => {
|
|
6989
|
+
if (!d)
|
|
6990
6990
|
if (o) {
|
|
6991
6991
|
if (!Array.isArray(e)) return;
|
|
6992
|
-
e.includes(
|
|
6992
|
+
e.includes(p) ? n(e.filter((g) => g !== p)) : n([...e, p]);
|
|
6993
6993
|
} else
|
|
6994
|
-
n(
|
|
6994
|
+
n(p);
|
|
6995
6995
|
};
|
|
6996
6996
|
return /* @__PURE__ */ a.jsx(
|
|
6997
6997
|
"div",
|
|
6998
6998
|
{
|
|
6999
6999
|
className: `inline-flex ${l === "vertical" ? "flex-col" : "flex-row"} rounded-md overflow-hidden border border-color-gray-200 bg-color-white ${s}`,
|
|
7000
7000
|
role: "group",
|
|
7001
|
-
"aria-disabled":
|
|
7002
|
-
children: t.map((
|
|
7001
|
+
"aria-disabled": d,
|
|
7002
|
+
children: t.map((p, g) => {
|
|
7003
7003
|
var v;
|
|
7004
7004
|
return /* @__PURE__ */ a.jsxs(
|
|
7005
7005
|
"button",
|
|
7006
7006
|
{
|
|
7007
7007
|
type: "button",
|
|
7008
|
-
disabled:
|
|
7008
|
+
disabled: d || p.disabled,
|
|
7009
7009
|
className: `
|
|
7010
7010
|
flex items-center justify-center gap-2 border-0 ${l === "vertical" ? "not-last:border-b-1" : "not-last:border-r-1"} border-color-gray-200
|
|
7011
7011
|
${fi[r]}
|
|
7012
|
-
${
|
|
7013
|
-
${
|
|
7012
|
+
${u(p.value) ? ((v = xe[i]) == null ? void 0 : v.filled) || i : "bg-color-transparent text-color-gray-700"}
|
|
7013
|
+
${d || p.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer"}
|
|
7014
7014
|
${c}
|
|
7015
7015
|
`,
|
|
7016
|
-
"aria-pressed":
|
|
7017
|
-
onClick: () => !(
|
|
7016
|
+
"aria-pressed": u(p.value),
|
|
7017
|
+
onClick: () => !(d || p.disabled) && f(p.value),
|
|
7018
7018
|
children: [
|
|
7019
|
-
|
|
7020
|
-
|
|
7019
|
+
p.icon,
|
|
7020
|
+
p.label
|
|
7021
7021
|
]
|
|
7022
7022
|
},
|
|
7023
|
-
|
|
7023
|
+
p.value
|
|
7024
7024
|
);
|
|
7025
7025
|
})
|
|
7026
7026
|
}
|
|
@@ -7049,10 +7049,10 @@ const Vi = no(function({
|
|
|
7049
7049
|
actionMenu: l,
|
|
7050
7050
|
divider: s = !0,
|
|
7051
7051
|
children: c,
|
|
7052
|
-
className:
|
|
7053
|
-
hoverable:
|
|
7052
|
+
className: d = "",
|
|
7053
|
+
hoverable: u = !1,
|
|
7054
7054
|
bordered: f = !1,
|
|
7055
|
-
onClick:
|
|
7055
|
+
onClick: p,
|
|
7056
7056
|
loaderJsx: g = !1
|
|
7057
7057
|
}) => {
|
|
7058
7058
|
const v = [
|
|
@@ -7063,11 +7063,11 @@ const Vi = no(function({
|
|
|
7063
7063
|
yn[t] || yn.medium,
|
|
7064
7064
|
Cn[o] || Cn.small,
|
|
7065
7065
|
jn[r] || jn.medium,
|
|
7066
|
-
|
|
7066
|
+
u ? "hover:shadow-xl transition-shadow duration-300 cursor-pointer" : "",
|
|
7067
7067
|
f ? "border border-color-gray-200" : "",
|
|
7068
|
-
|
|
7068
|
+
d
|
|
7069
7069
|
].join(" ").trim();
|
|
7070
|
-
return /* @__PURE__ */ a.jsxs("div", { className: v, onClick:
|
|
7070
|
+
return /* @__PURE__ */ a.jsxs("div", { className: v, onClick: p, children: [
|
|
7071
7071
|
i && /* @__PURE__ */ a.jsx("img", { src: i, alt: "Card", className: "w-full h-auto mb-4 rounded" }),
|
|
7072
7072
|
(e || n) && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7073
7073
|
/* @__PURE__ */ a.jsxs("div", { className: "flex justify-between items-start mb-2", children: [
|
|
@@ -7129,23 +7129,23 @@ const Vi = no(function({
|
|
|
7129
7129
|
color: l = "blue",
|
|
7130
7130
|
className: s = "",
|
|
7131
7131
|
radioClass: c
|
|
7132
|
-
}) => /* @__PURE__ */ a.jsx("div", { className: `flex ${r === "row" ? "flex-row gap-6" : "flex-col gap-3"} ${s}`, children: n.map(({ label:
|
|
7132
|
+
}) => /* @__PURE__ */ a.jsx("div", { className: `flex ${r === "row" ? "flex-row gap-6" : "flex-col gap-3"} ${s}`, children: n.map(({ label: d, value: u, disabled: f }) => {
|
|
7133
7133
|
var g, v;
|
|
7134
|
-
const
|
|
7134
|
+
const p = i || f;
|
|
7135
7135
|
return /* @__PURE__ */ a.jsxs(
|
|
7136
7136
|
"label",
|
|
7137
7137
|
{
|
|
7138
|
-
className: `relative flex items-center cursor-pointer select-none transition ${
|
|
7138
|
+
className: `relative flex items-center cursor-pointer select-none transition ${p ? "opacity-50 cursor-not-allowed" : "hover:opacity-90"}`,
|
|
7139
7139
|
children: [
|
|
7140
7140
|
/* @__PURE__ */ a.jsx(
|
|
7141
7141
|
"input",
|
|
7142
7142
|
{
|
|
7143
7143
|
type: "radio",
|
|
7144
7144
|
name: e,
|
|
7145
|
-
value:
|
|
7146
|
-
disabled:
|
|
7147
|
-
checked: t ===
|
|
7148
|
-
onChange: () => !
|
|
7145
|
+
value: u,
|
|
7146
|
+
disabled: p,
|
|
7147
|
+
checked: t === u,
|
|
7148
|
+
onChange: () => !p && (o == null ? void 0 : o(u)),
|
|
7149
7149
|
className: "sr-only peer"
|
|
7150
7150
|
}
|
|
7151
7151
|
),
|
|
@@ -7155,10 +7155,10 @@ const Vi = no(function({
|
|
|
7155
7155
|
className: `w-5 h-5 rounded-full border-2 border-color-gray-400 peer-checked:border-[7px] transition-all duration-150 ${(g = xe[l]) == null ? void 0 : g.peer} ${c}`
|
|
7156
7156
|
}
|
|
7157
7157
|
),
|
|
7158
|
-
/* @__PURE__ */ a.jsx("span", { className: `ml-2 text-sm ${(v = xe[l]) == null ? void 0 : v.peer}`, children:
|
|
7158
|
+
/* @__PURE__ */ a.jsx("span", { className: `ml-2 text-sm ${(v = xe[l]) == null ? void 0 : v.peer}`, children: d })
|
|
7159
7159
|
]
|
|
7160
7160
|
},
|
|
7161
|
-
|
|
7161
|
+
u
|
|
7162
7162
|
);
|
|
7163
7163
|
}) }), Xi = ({
|
|
7164
7164
|
label: e,
|
|
@@ -7170,11 +7170,11 @@ const Vi = no(function({
|
|
|
7170
7170
|
inputClass: l = "",
|
|
7171
7171
|
disabled: s = !1,
|
|
7172
7172
|
size: c = "medium",
|
|
7173
|
-
variant:
|
|
7174
|
-
rounded:
|
|
7173
|
+
variant: d = "outlined",
|
|
7174
|
+
rounded: u = "medium",
|
|
7175
7175
|
shadow: f = !1
|
|
7176
7176
|
}) => {
|
|
7177
|
-
const
|
|
7177
|
+
const p = {
|
|
7178
7178
|
small: "p-2",
|
|
7179
7179
|
medium: "p-3",
|
|
7180
7180
|
large: "p-4"
|
|
@@ -7195,7 +7195,7 @@ const Vi = no(function({
|
|
|
7195
7195
|
disabled: s,
|
|
7196
7196
|
value: n,
|
|
7197
7197
|
onChange: (m) => t(m.target.value),
|
|
7198
|
-
className: `appearance-none focus:ring-1 text-color-gray-800 w-full border outline-none transition-all ${g[
|
|
7198
|
+
className: `appearance-none focus:ring-1 text-color-gray-800 w-full border outline-none transition-all ${g[u]} ${p[c]} ${v[d]} ${s ? "!bg-color-gray-50 opacity-60 cursor-not-allowed" : ""} ${f ? "shadow-md shadow-color-zinc-100" : ""} ${l}`,
|
|
7199
7199
|
children: o.map((m) => /* @__PURE__ */ a.jsx("option", { value: m.value, className: "text-color-gray-900", children: m.label }, m.value))
|
|
7200
7200
|
}
|
|
7201
7201
|
),
|
|
@@ -7210,23 +7210,23 @@ const Vi = no(function({
|
|
|
7210
7210
|
const [o, r] = X(!1), [i, l] = X({ top: 0, left: 0 }), s = pe(null), c = pe(null);
|
|
7211
7211
|
return se(() => {
|
|
7212
7212
|
if (o && s.current && c.current) {
|
|
7213
|
-
const
|
|
7214
|
-
let f = 0,
|
|
7213
|
+
const d = s.current.getBoundingClientRect(), u = c.current.getBoundingClientRect();
|
|
7214
|
+
let f = 0, p = 0;
|
|
7215
7215
|
switch (t) {
|
|
7216
7216
|
case "top":
|
|
7217
|
-
f =
|
|
7217
|
+
f = d.top - u.height - 8, p = d.left + d.width / 2 - u.width / 2;
|
|
7218
7218
|
break;
|
|
7219
7219
|
case "bottom":
|
|
7220
|
-
f =
|
|
7220
|
+
f = d.bottom + 8, p = d.left + d.width / 2 - u.width / 2;
|
|
7221
7221
|
break;
|
|
7222
7222
|
case "left":
|
|
7223
|
-
f =
|
|
7223
|
+
f = d.top + d.height / 2 - u.height / 2, p = d.left - u.width - 8;
|
|
7224
7224
|
break;
|
|
7225
7225
|
case "right":
|
|
7226
|
-
f =
|
|
7226
|
+
f = d.top + d.height / 2 - u.height / 2, p = d.right + 8;
|
|
7227
7227
|
break;
|
|
7228
7228
|
}
|
|
7229
|
-
l({ top: f, left:
|
|
7229
|
+
l({ top: f, left: p });
|
|
7230
7230
|
}
|
|
7231
7231
|
}, [o, t]), /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7232
7232
|
/* @__PURE__ */ a.jsx(
|
|
@@ -7275,15 +7275,15 @@ const vi = {
|
|
|
7275
7275
|
showCloseIcon: l = !0,
|
|
7276
7276
|
fullscreen: s = !1,
|
|
7277
7277
|
fullWidth: c = !1,
|
|
7278
|
-
maxWidth:
|
|
7279
|
-
},
|
|
7280
|
-
const [f,
|
|
7278
|
+
maxWidth: d
|
|
7279
|
+
}, u) => {
|
|
7280
|
+
const [f, p] = X(e || !1), [g, v] = X(!1), [m, h] = X(!1);
|
|
7281
7281
|
se(() => {
|
|
7282
|
-
e !== void 0 &&
|
|
7283
|
-
}, [e]), $n(
|
|
7284
|
-
open: () =>
|
|
7282
|
+
e !== void 0 && p(e);
|
|
7283
|
+
}, [e]), $n(u, () => ({
|
|
7284
|
+
open: () => p(!0),
|
|
7285
7285
|
close: () => {
|
|
7286
|
-
h(!1), setTimeout(() =>
|
|
7286
|
+
h(!1), setTimeout(() => p(!1), 300);
|
|
7287
7287
|
}
|
|
7288
7288
|
})), se(() => {
|
|
7289
7289
|
let P;
|
|
@@ -7313,14 +7313,14 @@ const vi = {
|
|
|
7313
7313
|
{
|
|
7314
7314
|
className: "fixed inset-0 bg-color-black/50",
|
|
7315
7315
|
onClick: () => {
|
|
7316
|
-
n == null || n(),
|
|
7316
|
+
n == null || n(), p(!1);
|
|
7317
7317
|
}
|
|
7318
7318
|
}
|
|
7319
7319
|
),
|
|
7320
7320
|
/* @__PURE__ */ a.jsxs(
|
|
7321
7321
|
"div",
|
|
7322
7322
|
{
|
|
7323
|
-
className: `relative flex flex-col z-50 bg-color-white rounded-xl shadow-lg transition-all duration-300 transform p-6 ${m ? "opacity-100 scale-100" : "opacity-0 scale-95"} ${s ? "w-full h-[calc(100%_-_40px)] m-5" : `${c ? "w-full" : "w-auto"} ${
|
|
7323
|
+
className: `relative flex flex-col z-50 bg-color-white rounded-xl shadow-lg transition-all duration-300 transform p-6 ${m ? "opacity-100 scale-100" : "opacity-0 scale-95"} ${s ? "w-full h-[calc(100%_-_40px)] m-5" : `${c ? "w-full" : "w-auto"} ${d ? vi[d] : ""} mx-5`} ${t}`,
|
|
7324
7324
|
onTransitionEnd: j,
|
|
7325
7325
|
children: [
|
|
7326
7326
|
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center justify-between mb-4", children: [
|
|
@@ -7333,7 +7333,7 @@ const vi = {
|
|
|
7333
7333
|
size: "small",
|
|
7334
7334
|
roundedFull: !0,
|
|
7335
7335
|
onClick: () => {
|
|
7336
|
-
n == null || n(),
|
|
7336
|
+
n == null || n(), p(!1);
|
|
7337
7337
|
},
|
|
7338
7338
|
variant: "transparent"
|
|
7339
7339
|
}
|
|
@@ -7352,21 +7352,21 @@ const vi = {
|
|
|
7352
7352
|
}
|
|
7353
7353
|
);
|
|
7354
7354
|
function Qi({ items: e, trigger: n, className: t, dropdownItemClass: o }) {
|
|
7355
|
-
const [r, i] = X(!1), [l, s] = X({ top: 0, left: 0 }), [c,
|
|
7356
|
-
v.stopPropagation(), i((m) => !m),
|
|
7355
|
+
const [r, i] = X(!1), [l, s] = X({ top: 0, left: 0 }), [c, d] = X(!1), u = pe(null), f = pe(null), p = (v) => {
|
|
7356
|
+
v.stopPropagation(), i((m) => !m), d(!1);
|
|
7357
7357
|
};
|
|
7358
7358
|
oo(() => {
|
|
7359
|
-
if (r &&
|
|
7360
|
-
const v =
|
|
7359
|
+
if (r && u.current && f.current) {
|
|
7360
|
+
const v = u.current.getBoundingClientRect(), m = f.current.getBoundingClientRect(), h = window.innerWidth, j = window.innerHeight;
|
|
7361
7361
|
let P = v.left + window.scrollX, b = v.bottom + window.scrollY;
|
|
7362
7362
|
v.right + m.width > h && (P = v.right + window.scrollX - m.width), P + m.width > h && (P = h - m.width - 12), b + m.height > j && (b = v.top + window.scrollY - m.height), s({ top: b, left: P }), setTimeout(() => {
|
|
7363
|
-
|
|
7363
|
+
d(!0);
|
|
7364
7364
|
}, 150);
|
|
7365
7365
|
}
|
|
7366
7366
|
}, [r]), se(() => {
|
|
7367
7367
|
const v = (m) => {
|
|
7368
7368
|
var h;
|
|
7369
|
-
f.current && !f.current.contains(m.target) && !((h =
|
|
7369
|
+
f.current && !f.current.contains(m.target) && !((h = u.current) != null && h.contains(m.target)) && i(!1);
|
|
7370
7370
|
};
|
|
7371
7371
|
return r && document.addEventListener("mousedown", v), () => {
|
|
7372
7372
|
document.removeEventListener("mousedown", v);
|
|
@@ -7400,7 +7400,7 @@ function Qi({ items: e, trigger: n, className: t, dropdownItemClass: o }) {
|
|
|
7400
7400
|
}
|
|
7401
7401
|
);
|
|
7402
7402
|
return /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7403
|
-
/* @__PURE__ */ a.jsx("div", { ref:
|
|
7403
|
+
/* @__PURE__ */ a.jsx("div", { ref: u, onClick: p, className: "cursor-pointer", children: n }),
|
|
7404
7404
|
r && He(g, document.body)
|
|
7405
7405
|
] });
|
|
7406
7406
|
}
|
|
@@ -7418,15 +7418,15 @@ const wi = ({
|
|
|
7418
7418
|
showCloseIcon: s = !0,
|
|
7419
7419
|
anchor: c = "left"
|
|
7420
7420
|
}) => {
|
|
7421
|
-
const [
|
|
7421
|
+
const [d, u] = X(!1), [f, p] = X(!1);
|
|
7422
7422
|
se(() => {
|
|
7423
7423
|
let h;
|
|
7424
|
-
return e ? (
|
|
7425
|
-
|
|
7426
|
-
}, 10)) :
|
|
7424
|
+
return e ? (u(!0), h = setTimeout(() => {
|
|
7425
|
+
p(!0);
|
|
7426
|
+
}, 10)) : p(!1), () => clearTimeout(h);
|
|
7427
7427
|
}, [e]);
|
|
7428
7428
|
const g = () => {
|
|
7429
|
-
e ||
|
|
7429
|
+
e || u(!1);
|
|
7430
7430
|
};
|
|
7431
7431
|
if (se(() => {
|
|
7432
7432
|
const h = (j) => {
|
|
@@ -7435,7 +7435,7 @@ const wi = ({
|
|
|
7435
7435
|
return e && document.addEventListener("keydown", h), () => document.removeEventListener("keydown", h);
|
|
7436
7436
|
}, [e, n]), se(() => (e ? document.body.style.overflow = "hidden" : document.body.style.overflow = "", () => {
|
|
7437
7437
|
document.body.style.overflow = "";
|
|
7438
|
-
}), [e]), !
|
|
7438
|
+
}), [e]), !d) return null;
|
|
7439
7439
|
const v = {
|
|
7440
7440
|
left: "left-0 top-0 h-full min-w-96 transition-all duration-300",
|
|
7441
7441
|
right: "right-0 top-0 h-full min-w-96 transition-all duration-300",
|
|
@@ -7501,14 +7501,14 @@ const wi = ({
|
|
|
7501
7501
|
onToggle: l,
|
|
7502
7502
|
className: s = "",
|
|
7503
7503
|
titleClass: c = "",
|
|
7504
|
-
contentClass:
|
|
7504
|
+
contentClass: d = ""
|
|
7505
7505
|
}) => {
|
|
7506
|
-
const [
|
|
7506
|
+
const [u, f] = X(i), p = r !== void 0, g = p ? r : u, v = () => {
|
|
7507
7507
|
const m = !g;
|
|
7508
|
-
|
|
7508
|
+
p || f(m), l == null || l(m);
|
|
7509
7509
|
};
|
|
7510
7510
|
return se(() => {
|
|
7511
|
-
|
|
7511
|
+
p && f(r);
|
|
7512
7512
|
}, [r]), /* @__PURE__ */ a.jsxs("div", { className: `overflow-hidden w-full border border-color-gray-100 ${s}`, children: [
|
|
7513
7513
|
/* @__PURE__ */ a.jsxs(
|
|
7514
7514
|
"button",
|
|
@@ -7527,7 +7527,7 @@ const wi = ({
|
|
|
7527
7527
|
]
|
|
7528
7528
|
}
|
|
7529
7529
|
),
|
|
7530
|
-
/* @__PURE__ */ a.jsx("div", { className: `grid overflow-hidden transition-all duration-300 ease-in-out grid-rows-[0fr] ${g ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"}`, children: /* @__PURE__ */ a.jsx("div", { className: "overflow-hidden", children: /* @__PURE__ */ a.jsx("div", { className: `p-4 text-sm text-color-gray-700 ${
|
|
7530
|
+
/* @__PURE__ */ a.jsx("div", { className: `grid overflow-hidden transition-all duration-300 ease-in-out grid-rows-[0fr] ${g ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"}`, children: /* @__PURE__ */ a.jsx("div", { className: "overflow-hidden", children: /* @__PURE__ */ a.jsx("div", { className: `p-4 text-sm text-color-gray-700 ${d}`, children: n }) }) })
|
|
7531
7531
|
] });
|
|
7532
7532
|
}, yi = {
|
|
7533
7533
|
info: "bg-color-blue-50 border-color-blue-300 text-color-blue-800",
|
|
@@ -7557,12 +7557,12 @@ const wi = ({
|
|
|
7557
7557
|
}) => {
|
|
7558
7558
|
const [l, s] = X(!0), c = pe(null);
|
|
7559
7559
|
return se(() => {
|
|
7560
|
-
let
|
|
7560
|
+
let d;
|
|
7561
7561
|
return o && (requestAnimationFrame(() => {
|
|
7562
7562
|
c.current && (c.current.style.transition = `width ${i}ms linear`, c.current.style.width = "0%");
|
|
7563
|
-
}),
|
|
7563
|
+
}), d = setTimeout(() => {
|
|
7564
7564
|
s(!1), t == null || t();
|
|
7565
|
-
}, i)), () => clearTimeout(
|
|
7565
|
+
}, i)), () => clearTimeout(d);
|
|
7566
7566
|
}, [o, i, t]), l ? /* @__PURE__ */ a.jsxs(
|
|
7567
7567
|
"div",
|
|
7568
7568
|
{
|
|
@@ -7603,15 +7603,15 @@ const wi = ({
|
|
|
7603
7603
|
position: i = "top-right"
|
|
7604
7604
|
}) => {
|
|
7605
7605
|
const l = () => {
|
|
7606
|
-
var
|
|
7606
|
+
var d, u;
|
|
7607
7607
|
if (t)
|
|
7608
|
-
return /* @__PURE__ */ a.jsx("span", { className: `h-2 w-2 rounded-full ${(
|
|
7608
|
+
return /* @__PURE__ */ a.jsx("span", { className: `h-2 w-2 rounded-full ${(d = xe[r]) == null ? void 0 : d.filled} block` });
|
|
7609
7609
|
if (n === 0 || n === void 0) return null;
|
|
7610
7610
|
const c = n > o ? `${o}+` : n;
|
|
7611
7611
|
return /* @__PURE__ */ a.jsx(
|
|
7612
7612
|
"span",
|
|
7613
7613
|
{
|
|
7614
|
-
className: `text-color-white text-xs px-[10px] py-1 rounded-full whitespace-nowrap ${(
|
|
7614
|
+
className: `text-color-white text-xs px-[10px] py-1 rounded-full whitespace-nowrap ${(u = xe[r]) == null ? void 0 : u.filled}`,
|
|
7615
7615
|
children: c
|
|
7616
7616
|
}
|
|
7617
7617
|
);
|
|
@@ -7649,7 +7649,7 @@ const wi = ({
|
|
|
7649
7649
|
}) => {
|
|
7650
7650
|
let s = "flex justify-around items-center bg-color-white shadow-sm text-color-gray-600 py-2 px-4";
|
|
7651
7651
|
return e === "fixed" ? s += " fixed bottom-0 left-0 right-0" : e === "floating" ? s += " fixed bottom-4 left-4 right-4 rounded-full" : e === "static" && (s += " static w-full"), /* @__PURE__ */ a.jsx("nav", { className: `${s} ${r}`, children: t.map((c) => {
|
|
7652
|
-
const
|
|
7652
|
+
const d = c.label === n;
|
|
7653
7653
|
return /* @__PURE__ */ a.jsxs(
|
|
7654
7654
|
"a",
|
|
7655
7655
|
{
|
|
@@ -7657,8 +7657,8 @@ const wi = ({
|
|
|
7657
7657
|
onClick: () => o(c.label),
|
|
7658
7658
|
className: `flex flex-col items-center text-sm cursor-pointer text-color-gray-500 no-underline ${l}`,
|
|
7659
7659
|
children: [
|
|
7660
|
-
/* @__PURE__ */ a.jsx("span", { className: `text-xl ${
|
|
7661
|
-
/* @__PURE__ */ a.jsx("span", { className: `text-xs font-medium mt-1 ${
|
|
7660
|
+
/* @__PURE__ */ a.jsx("span", { className: `text-xl ${d ? `text-color-blue-500 ${i}` : ""}`, children: c.icon }),
|
|
7661
|
+
/* @__PURE__ */ a.jsx("span", { className: `text-xs font-medium mt-1 ${d ? `text-color-blue-500 ${i}` : ""}`, children: c.label })
|
|
7662
7662
|
]
|
|
7663
7663
|
},
|
|
7664
7664
|
c.label
|
|
@@ -7684,29 +7684,29 @@ const wi = ({
|
|
|
7684
7684
|
placeholder: l = "Select date",
|
|
7685
7685
|
icon: s = /* @__PURE__ */ a.jsx("svg", { className: "text-color-gray-500 size-5", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ a.jsx("path", { d: "M7 3V1H9V3H15V1H17V3H21C21.5523 3 22 3.44772 22 4V9H20V5H17V7H15V5H9V7H7V5H4V19H10V21H3C2.44772 21 2 20.5523 2 20V4C2 3.44772 2.44772 3 3 3H7ZM17 12C14.7909 12 13 13.7909 13 16C13 18.2091 14.7909 20 17 20C19.2091 20 21 18.2091 21 16C21 13.7909 19.2091 12 17 12ZM11 16C11 12.6863 13.6863 10 17 10C20.3137 10 23 12.6863 23 16C23 19.3137 20.3137 22 17 22C13.6863 22 11 19.3137 11 16ZM16 13V16.4142L18.2929 18.7071L19.7071 17.2929L18 15.5858V13H16Z" }) }),
|
|
7686
7686
|
disableBefore: c,
|
|
7687
|
-
disableAfter:
|
|
7688
|
-
selectedDate:
|
|
7687
|
+
disableAfter: d,
|
|
7688
|
+
selectedDate: u,
|
|
7689
7689
|
hideFutureDates: f = !1,
|
|
7690
|
-
defaultDate:
|
|
7690
|
+
defaultDate: p,
|
|
7691
7691
|
fromDate: g,
|
|
7692
7692
|
toDate: v
|
|
7693
7693
|
}) => {
|
|
7694
7694
|
const [m, h] = X(!1), [j, P] = X(null), [b, M] = X(
|
|
7695
|
-
g || v ? /* @__PURE__ */ new Date() :
|
|
7695
|
+
g || v ? /* @__PURE__ */ new Date() : p ? new Date(typeof p == "string" ? parseInt(p) : p) : /* @__PURE__ */ new Date()
|
|
7696
7696
|
), [w, O] = X(
|
|
7697
|
-
|
|
7697
|
+
u ? new Date(u) : p && !u ? new Date(typeof p == "string" ? parseInt(p) : p) : null
|
|
7698
7698
|
), [F, V] = X(g ? new Date(g) : null), [q, ee] = X(v ? new Date(v) : null), [ae, ce] = X(null), [D, I] = X({ hour: 12, minute: 0, ampm: "AM" }), W = pe(null), [T, J] = X(
|
|
7699
|
-
|
|
7699
|
+
u ? new Date(u) : p && !u ? new Date(typeof p == "string" ? parseInt(p) : p) : null
|
|
7700
7700
|
), [de, K] = X(g ? new Date(g) : null), [x, y] = X(v ? new Date(v) : null);
|
|
7701
7701
|
se(() => {
|
|
7702
|
-
if (
|
|
7703
|
-
O(new Date(
|
|
7704
|
-
else if (!
|
|
7705
|
-
const C = new Date(typeof
|
|
7702
|
+
if (u)
|
|
7703
|
+
O(new Date(u)), J(new Date(u));
|
|
7704
|
+
else if (!u && p) {
|
|
7705
|
+
const C = new Date(typeof p == "string" ? parseInt(p) : p);
|
|
7706
7706
|
O(C), J(C);
|
|
7707
7707
|
} else
|
|
7708
7708
|
O(null), J(null);
|
|
7709
|
-
}, [
|
|
7709
|
+
}, [u, p]), se(() => {
|
|
7710
7710
|
g && (V(new Date(g)), K(new Date(g)), O(new Date(g)), J(new Date(g)));
|
|
7711
7711
|
}, [g]), se(() => {
|
|
7712
7712
|
v && (ee(new Date(v)), y(new Date(v)), O(new Date(v)), J(new Date(v)));
|
|
@@ -7715,7 +7715,7 @@ const wi = ({
|
|
|
7715
7715
|
C.stopPropagation(), P(C.currentTarget), h(!0);
|
|
7716
7716
|
}, k = () => {
|
|
7717
7717
|
h(!1);
|
|
7718
|
-
}, A = (C) => !!(c && C.getTime() < c ||
|
|
7718
|
+
}, A = (C) => !!(c && C.getTime() < c || d && C.getTime() > d || f && C.getTime() > (/* @__PURE__ */ new Date()).setHours(23, 59, 59, 999)), z = (C) => {
|
|
7719
7719
|
n === "inline" && W.current && !W.current.contains(C.target) && (e === "single" ? w || O(null) : e === "range" && (!F || !q) && (V(null), ee(null)), h(!1));
|
|
7720
7720
|
};
|
|
7721
7721
|
se(() => (m ? document.addEventListener("mousedown", z) : document.removeEventListener("mousedown", z), () => {
|
|
@@ -7905,7 +7905,7 @@ const wi = ({
|
|
|
7905
7905
|
variant: "outlined",
|
|
7906
7906
|
className: `!justify-between gap-2 ${r || ""}`,
|
|
7907
7907
|
children: [
|
|
7908
|
-
e === "single" ? T
|
|
7908
|
+
e === "single" ? T && u !== null ? S(T) : l : (
|
|
7909
7909
|
// Display rangeStart immediately if set, even if rangeEnd is null
|
|
7910
7910
|
F || de || x ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7911
7911
|
S(F || de, "start"),
|
|
@@ -7930,9 +7930,9 @@ const wi = ({
|
|
|
7930
7930
|
tabItemActiveClass: l = "",
|
|
7931
7931
|
tabContentClass: s = "",
|
|
7932
7932
|
indicatorClass: c = "",
|
|
7933
|
-
variant:
|
|
7933
|
+
variant: d = "horizontal"
|
|
7934
7934
|
}) => {
|
|
7935
|
-
const
|
|
7935
|
+
const u = e.find((p) => p.key === n), f = d === "vertical";
|
|
7936
7936
|
return /* @__PURE__ */ a.jsxs(
|
|
7937
7937
|
"div",
|
|
7938
7938
|
{
|
|
@@ -7942,30 +7942,30 @@ const wi = ({
|
|
|
7942
7942
|
"div",
|
|
7943
7943
|
{
|
|
7944
7944
|
className: `${f ? "flex flex-col min-w-[160px] border-r border-color-gray-200" : "flex space-x-6 border-b border-color-gray-200"} ${r}`,
|
|
7945
|
-
children: e.map((
|
|
7946
|
-
const g = n ===
|
|
7945
|
+
children: e.map((p) => {
|
|
7946
|
+
const g = n === p.key;
|
|
7947
7947
|
return /* @__PURE__ */ a.jsxs(
|
|
7948
7948
|
"button",
|
|
7949
7949
|
{
|
|
7950
|
-
onClick: () => t(
|
|
7950
|
+
onClick: () => t(p.key),
|
|
7951
7951
|
className: `relative flex ${f ? "flex-row items-center px-4 py-3" : "flex-col items-center py-4"}
|
|
7952
7952
|
text-sm font-medium transition-color duration-200 bg-color-transparent
|
|
7953
7953
|
${g ? `text-color-blue-500 ${l} ` : "text-color-gray-600 hover:text-color-blue-500 cursor-pointer"}
|
|
7954
7954
|
${i}`,
|
|
7955
7955
|
children: [
|
|
7956
7956
|
/* @__PURE__ */ a.jsxs("div", { className: `flex items-center ${f ? "space-x-3" : "space-x-2"}`, children: [
|
|
7957
|
-
|
|
7958
|
-
/* @__PURE__ */ a.jsx("span", { children:
|
|
7957
|
+
p.icon && /* @__PURE__ */ a.jsx("span", { children: p.icon }),
|
|
7958
|
+
/* @__PURE__ */ a.jsx("span", { children: p.label })
|
|
7959
7959
|
] }),
|
|
7960
7960
|
g && (f ? /* @__PURE__ */ a.jsx("div", { className: `absolute right-0 top-3 bottom-3 w-1 bg-color-blue-500 rounded-full ${c}` }) : /* @__PURE__ */ a.jsx("div", { className: `absolute bottom-0 left-0 right-0 h-1 bg-color-blue-500 rounded-full ${c}` }))
|
|
7961
7961
|
]
|
|
7962
7962
|
},
|
|
7963
|
-
|
|
7963
|
+
p.key
|
|
7964
7964
|
);
|
|
7965
7965
|
})
|
|
7966
7966
|
}
|
|
7967
7967
|
),
|
|
7968
|
-
/* @__PURE__ */ a.jsx("div", { className: `mt-4 ${f ? "ml-6 mt-0" : ""} ${s}`, children:
|
|
7968
|
+
/* @__PURE__ */ a.jsx("div", { className: `mt-4 ${f ? "ml-6 mt-0" : ""} ${s}`, children: u == null ? void 0 : u.content })
|
|
7969
7969
|
]
|
|
7970
7970
|
}
|
|
7971
7971
|
);
|
|
@@ -8003,8 +8003,8 @@ function sa({
|
|
|
8003
8003
|
onItemSelect: l,
|
|
8004
8004
|
className: s = ""
|
|
8005
8005
|
}) {
|
|
8006
|
-
const [c,
|
|
8007
|
-
|
|
8006
|
+
const [c, d] = X(o), u = (f) => {
|
|
8007
|
+
d(f), f.onClick && f.onClick(), l && l(f);
|
|
8008
8008
|
};
|
|
8009
8009
|
return /* @__PURE__ */ a.jsx(a.Fragment, { children: /* @__PURE__ */ a.jsx(
|
|
8010
8010
|
wi,
|
|
@@ -8028,7 +8028,7 @@ function sa({
|
|
|
8028
8028
|
className: `flex items-center gap-3 py-3 px-4 cursor-pointer rounded-full w-full no-underline
|
|
8029
8029
|
${f.label === (c == null ? void 0 : c.label) ? "bg-color-blue-500 text-color-white font-medium " : "hover:bg-color-gray-50 text-color-gray-600"}
|
|
8030
8030
|
`,
|
|
8031
|
-
onClick: () =>
|
|
8031
|
+
onClick: () => u(f),
|
|
8032
8032
|
children: [
|
|
8033
8033
|
/* @__PURE__ */ a.jsx("span", { className: "text-lg", children: f.icon }),
|
|
8034
8034
|
/* @__PURE__ */ a.jsx("span", { children: f.label })
|
|
@@ -8038,7 +8038,7 @@ function sa({
|
|
|
8038
8038
|
) : /* @__PURE__ */ a.jsxs(
|
|
8039
8039
|
"button",
|
|
8040
8040
|
{
|
|
8041
|
-
onClick: () =>
|
|
8041
|
+
onClick: () => u(f),
|
|
8042
8042
|
className: `flex items-center gap-3 py-3 px-4 cursor-pointer rounded-full w-full no-underline
|
|
8043
8043
|
${f.label === (c == null ? void 0 : c.label) ? "bg-color-blue-500 text-color-white font-medium " : "hover:bg-color-gray-50 text-color-gray-600 bg-color-transparent"}
|
|
8044
8044
|
`,
|