@unizap/uniui 1.0.36 → 1.0.38
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/components/CollapsableCard/CollapsableCard.d.ts +5 -0
- package/dist/components/CollapsableCard/CollapsableCard.types.d.ts +19 -0
- package/dist/components/CollapsableCard/index.d.ts +1 -0
- package/dist/components/Table/Table.d.ts +1 -1
- package/dist/components/Table/Table.types.d.ts +1 -0
- package/dist/uniui.css +1 -1
- package/dist/uniui.js +687 -671
- package/dist/uniui.umd.cjs +48 -48
- package/package.json +1 -1
package/dist/uniui.js
CHANGED
|
@@ -49,13 +49,13 @@ var Ae = {};
|
|
|
49
49
|
var qt;
|
|
50
50
|
function io() {
|
|
51
51
|
return qt || (qt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
52
|
-
function e(
|
|
53
|
-
if (
|
|
54
|
-
if (typeof
|
|
55
|
-
return
|
|
56
|
-
if (typeof
|
|
57
|
-
switch (
|
|
58
|
-
case
|
|
52
|
+
function e(m) {
|
|
53
|
+
if (m == null) return null;
|
|
54
|
+
if (typeof m == "function")
|
|
55
|
+
return m.$$typeof === ee ? null : m.displayName || m.name || null;
|
|
56
|
+
if (typeof m == "string") return m;
|
|
57
|
+
switch (m) {
|
|
58
|
+
case f:
|
|
59
59
|
return "Fragment";
|
|
60
60
|
case C:
|
|
61
61
|
return "Profiler";
|
|
@@ -68,126 +68,126 @@ function io() {
|
|
|
68
68
|
case N:
|
|
69
69
|
return "Activity";
|
|
70
70
|
}
|
|
71
|
-
if (typeof
|
|
72
|
-
switch (typeof
|
|
71
|
+
if (typeof m == "object")
|
|
72
|
+
switch (typeof m.tag == "number" && console.error(
|
|
73
73
|
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
74
|
-
),
|
|
74
|
+
), m.$$typeof) {
|
|
75
75
|
case x:
|
|
76
76
|
return "Portal";
|
|
77
77
|
case w:
|
|
78
|
-
return (
|
|
79
|
-
case
|
|
80
|
-
return (
|
|
78
|
+
return (m.displayName || "Context") + ".Provider";
|
|
79
|
+
case M:
|
|
80
|
+
return (m._context.displayName || "Context") + ".Consumer";
|
|
81
81
|
case L:
|
|
82
|
-
var y =
|
|
83
|
-
return
|
|
82
|
+
var y = m.render;
|
|
83
|
+
return m = m.displayName, m || (m = y.displayName || y.name || "", m = m !== "" ? "ForwardRef(" + m + ")" : "ForwardRef"), m;
|
|
84
84
|
case T:
|
|
85
|
-
return y =
|
|
85
|
+
return y = m.displayName || null, y !== null ? y : e(m.type) || "Memo";
|
|
86
86
|
case H:
|
|
87
|
-
y =
|
|
87
|
+
y = m._payload, m = m._init;
|
|
88
88
|
try {
|
|
89
|
-
return e(
|
|
89
|
+
return e(m(y));
|
|
90
90
|
} catch {
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
93
|
return null;
|
|
94
94
|
}
|
|
95
|
-
function n(
|
|
96
|
-
return "" +
|
|
95
|
+
function n(m) {
|
|
96
|
+
return "" + m;
|
|
97
97
|
}
|
|
98
|
-
function t(
|
|
98
|
+
function t(m) {
|
|
99
99
|
try {
|
|
100
|
-
n(
|
|
100
|
+
n(m);
|
|
101
101
|
var y = !1;
|
|
102
102
|
} catch {
|
|
103
103
|
y = !0;
|
|
104
104
|
}
|
|
105
105
|
if (y) {
|
|
106
106
|
y = console;
|
|
107
|
-
var
|
|
108
|
-
return
|
|
107
|
+
var E = y.error, _ = typeof Symbol == "function" && Symbol.toStringTag && m[Symbol.toStringTag] || m.constructor.name || "Object";
|
|
108
|
+
return E.call(
|
|
109
109
|
y,
|
|
110
110
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
111
111
|
_
|
|
112
|
-
), n(
|
|
112
|
+
), n(m);
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
|
-
function o(
|
|
116
|
-
if (
|
|
117
|
-
if (typeof
|
|
115
|
+
function o(m) {
|
|
116
|
+
if (m === f) return "<>";
|
|
117
|
+
if (typeof m == "object" && m !== null && m.$$typeof === H)
|
|
118
118
|
return "<...>";
|
|
119
119
|
try {
|
|
120
|
-
var y = e(
|
|
120
|
+
var y = e(m);
|
|
121
121
|
return y ? "<" + y + ">" : "<...>";
|
|
122
122
|
} catch {
|
|
123
123
|
return "<...>";
|
|
124
124
|
}
|
|
125
125
|
}
|
|
126
126
|
function r() {
|
|
127
|
-
var
|
|
128
|
-
return
|
|
127
|
+
var m = ie.A;
|
|
128
|
+
return m === null ? null : m.getOwner();
|
|
129
129
|
}
|
|
130
130
|
function i() {
|
|
131
131
|
return Error("react-stack-top-frame");
|
|
132
132
|
}
|
|
133
|
-
function l(
|
|
134
|
-
if (ce.call(
|
|
135
|
-
var y = Object.getOwnPropertyDescriptor(
|
|
133
|
+
function l(m) {
|
|
134
|
+
if (ce.call(m, "key")) {
|
|
135
|
+
var y = Object.getOwnPropertyDescriptor(m, "key").get;
|
|
136
136
|
if (y && y.isReactWarning) return !1;
|
|
137
137
|
}
|
|
138
|
-
return
|
|
138
|
+
return m.key !== void 0;
|
|
139
139
|
}
|
|
140
|
-
function s(
|
|
141
|
-
function
|
|
140
|
+
function s(m, y) {
|
|
141
|
+
function E() {
|
|
142
142
|
Y || (Y = !0, console.error(
|
|
143
143
|
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
144
144
|
y
|
|
145
145
|
));
|
|
146
146
|
}
|
|
147
|
-
|
|
148
|
-
get:
|
|
147
|
+
E.isReactWarning = !0, Object.defineProperty(m, "key", {
|
|
148
|
+
get: E,
|
|
149
149
|
configurable: !0
|
|
150
150
|
});
|
|
151
151
|
}
|
|
152
152
|
function c() {
|
|
153
|
-
var
|
|
154
|
-
return D[
|
|
153
|
+
var m = e(this.type);
|
|
154
|
+
return D[m] || (D[m] = !0, console.error(
|
|
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
|
+
)), m = this.props.ref, m !== void 0 ? m : null;
|
|
157
157
|
}
|
|
158
|
-
function p(
|
|
159
|
-
return
|
|
160
|
-
$$typeof:
|
|
161
|
-
type:
|
|
158
|
+
function p(m, y, E, _, F, z, A, R) {
|
|
159
|
+
return E = z.ref, m = {
|
|
160
|
+
$$typeof: g,
|
|
161
|
+
type: m,
|
|
162
162
|
key: y,
|
|
163
163
|
props: z,
|
|
164
164
|
_owner: F
|
|
165
|
-
}, (
|
|
165
|
+
}, (E !== void 0 ? E : null) !== null ? Object.defineProperty(m, "ref", {
|
|
166
166
|
enumerable: !1,
|
|
167
167
|
get: c
|
|
168
|
-
}) : Object.defineProperty(
|
|
168
|
+
}) : Object.defineProperty(m, "ref", { enumerable: !1, value: null }), m._store = {}, Object.defineProperty(m._store, "validated", {
|
|
169
169
|
configurable: !1,
|
|
170
170
|
enumerable: !1,
|
|
171
171
|
writable: !0,
|
|
172
172
|
value: 0
|
|
173
|
-
}), Object.defineProperty(
|
|
173
|
+
}), Object.defineProperty(m, "_debugInfo", {
|
|
174
174
|
configurable: !1,
|
|
175
175
|
enumerable: !1,
|
|
176
176
|
writable: !0,
|
|
177
177
|
value: null
|
|
178
|
-
}), Object.defineProperty(
|
|
178
|
+
}), Object.defineProperty(m, "_debugStack", {
|
|
179
179
|
configurable: !1,
|
|
180
180
|
enumerable: !1,
|
|
181
181
|
writable: !0,
|
|
182
182
|
value: A
|
|
183
|
-
}), Object.defineProperty(
|
|
183
|
+
}), Object.defineProperty(m, "_debugTask", {
|
|
184
184
|
configurable: !1,
|
|
185
185
|
enumerable: !1,
|
|
186
186
|
writable: !0,
|
|
187
187
|
value: R
|
|
188
|
-
}), Object.freeze && (Object.freeze(
|
|
188
|
+
}), Object.freeze && (Object.freeze(m.props), Object.freeze(m)), m;
|
|
189
189
|
}
|
|
190
|
-
function u(
|
|
190
|
+
function u(m, y, E, _, F, z, A, R) {
|
|
191
191
|
var $ = y.children;
|
|
192
192
|
if ($ !== void 0)
|
|
193
193
|
if (_)
|
|
@@ -201,7 +201,7 @@ function io() {
|
|
|
201
201
|
);
|
|
202
202
|
else v($);
|
|
203
203
|
if (ce.call(y, "key")) {
|
|
204
|
-
$ = e(
|
|
204
|
+
$ = e(m);
|
|
205
205
|
var V = Object.keys(y).filter(function(j) {
|
|
206
206
|
return j !== "key";
|
|
207
207
|
});
|
|
@@ -218,63 +218,63 @@ React keys must be passed directly to JSX without using spread:
|
|
|
218
218
|
$
|
|
219
219
|
), K[$ + _] = !0);
|
|
220
220
|
}
|
|
221
|
-
if ($ = null,
|
|
222
|
-
|
|
221
|
+
if ($ = null, E !== void 0 && (t(E), $ = "" + E), l(y) && (t(y.key), $ = "" + y.key), "key" in y) {
|
|
222
|
+
E = {};
|
|
223
223
|
for (var q in y)
|
|
224
|
-
q !== "key" && (
|
|
225
|
-
} else
|
|
224
|
+
q !== "key" && (E[q] = y[q]);
|
|
225
|
+
} else E = y;
|
|
226
226
|
return $ && s(
|
|
227
|
-
|
|
228
|
-
typeof
|
|
227
|
+
E,
|
|
228
|
+
typeof m == "function" ? m.displayName || m.name || "Unknown" : m
|
|
229
229
|
), p(
|
|
230
|
-
|
|
230
|
+
m,
|
|
231
231
|
$,
|
|
232
232
|
z,
|
|
233
233
|
F,
|
|
234
234
|
r(),
|
|
235
|
-
|
|
235
|
+
E,
|
|
236
236
|
A,
|
|
237
237
|
R
|
|
238
238
|
);
|
|
239
239
|
}
|
|
240
|
-
function v(
|
|
241
|
-
typeof
|
|
240
|
+
function v(m) {
|
|
241
|
+
typeof m == "object" && m !== null && m.$$typeof === g && m._store && (m._store.validated = 1);
|
|
242
242
|
}
|
|
243
|
-
var
|
|
243
|
+
var d = Ce, g = Symbol.for("react.transitional.element"), x = Symbol.for("react.portal"), f = Symbol.for("react.fragment"), h = Symbol.for("react.strict_mode"), C = Symbol.for("react.profiler"), M = Symbol.for("react.consumer"), w = Symbol.for("react.context"), L = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), I = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), H = Symbol.for("react.lazy"), N = Symbol.for("react.activity"), ee = Symbol.for("react.client.reference"), ie = d.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, ce = Object.prototype.hasOwnProperty, U = Array.isArray, O = console.createTask ? console.createTask : function() {
|
|
244
244
|
return null;
|
|
245
245
|
};
|
|
246
|
-
|
|
247
|
-
"react-stack-bottom-frame": function(
|
|
248
|
-
return
|
|
246
|
+
d = {
|
|
247
|
+
"react-stack-bottom-frame": function(m) {
|
|
248
|
+
return m();
|
|
249
249
|
}
|
|
250
250
|
};
|
|
251
|
-
var Y, D = {}, Q =
|
|
252
|
-
|
|
251
|
+
var Y, D = {}, Q = d["react-stack-bottom-frame"].bind(
|
|
252
|
+
d,
|
|
253
253
|
i
|
|
254
254
|
)(), pe = O(o(i)), K = {};
|
|
255
|
-
Ae.Fragment =
|
|
255
|
+
Ae.Fragment = f, Ae.jsx = function(m, y, E, _, F) {
|
|
256
256
|
var z = 1e4 > ie.recentlyCreatedOwnerStacks++;
|
|
257
257
|
return u(
|
|
258
|
-
|
|
258
|
+
m,
|
|
259
259
|
y,
|
|
260
|
-
|
|
260
|
+
E,
|
|
261
261
|
!1,
|
|
262
262
|
_,
|
|
263
263
|
F,
|
|
264
264
|
z ? Error("react-stack-top-frame") : Q,
|
|
265
|
-
z ? O(o(
|
|
265
|
+
z ? O(o(m)) : pe
|
|
266
266
|
);
|
|
267
|
-
}, Ae.jsxs = function(
|
|
267
|
+
}, Ae.jsxs = function(m, y, E, _, F) {
|
|
268
268
|
var z = 1e4 > ie.recentlyCreatedOwnerStacks++;
|
|
269
269
|
return u(
|
|
270
|
-
|
|
270
|
+
m,
|
|
271
271
|
y,
|
|
272
|
-
|
|
272
|
+
E,
|
|
273
273
|
!0,
|
|
274
274
|
_,
|
|
275
275
|
F,
|
|
276
276
|
z ? Error("react-stack-top-frame") : Q,
|
|
277
|
-
z ? O(o(
|
|
277
|
+
z ? O(o(m)) : pe
|
|
278
278
|
);
|
|
279
279
|
};
|
|
280
280
|
}()), Ae;
|
|
@@ -618,14 +618,14 @@ const me = {
|
|
|
618
618
|
disabled: p = !1,
|
|
619
619
|
roundedFull: u = !1,
|
|
620
620
|
size: v = "medium",
|
|
621
|
-
type:
|
|
622
|
-
autoFocus:
|
|
621
|
+
type: d = "button",
|
|
622
|
+
autoFocus: g = !1,
|
|
623
623
|
href: x,
|
|
624
|
-
target:
|
|
624
|
+
target: f,
|
|
625
625
|
...h
|
|
626
626
|
}) => {
|
|
627
627
|
var b;
|
|
628
|
-
const C = le(null),
|
|
628
|
+
const C = le(null), M = le(null), w = (I) => {
|
|
629
629
|
const T = C.current;
|
|
630
630
|
if (!T) return;
|
|
631
631
|
const H = document.createElement("span"), N = T.getBoundingClientRect(), ee = Math.max(N.width, N.height);
|
|
@@ -634,9 +634,9 @@ const me = {
|
|
|
634
634
|
return /* @__PURE__ */ a.jsx(a.Fragment, { children: x ? /* @__PURE__ */ a.jsxs(
|
|
635
635
|
"a",
|
|
636
636
|
{
|
|
637
|
-
ref:
|
|
637
|
+
ref: M,
|
|
638
638
|
href: x,
|
|
639
|
-
target:
|
|
639
|
+
target: f,
|
|
640
640
|
className: `relative leading-none no-underline inline-flex font-medium overflow-hidden flex items-center justify-center gap-1 transition-all focus:outline-0
|
|
641
641
|
${t === "outlined" && "border"}
|
|
642
642
|
${L}
|
|
@@ -656,7 +656,7 @@ const me = {
|
|
|
656
656
|
"button",
|
|
657
657
|
{
|
|
658
658
|
ref: C,
|
|
659
|
-
type:
|
|
659
|
+
type: d,
|
|
660
660
|
disabled: p,
|
|
661
661
|
onClick: w,
|
|
662
662
|
className: `relative leading-none font-medium overflow-hidden flex items-center justify-center gap-1 transition-all focus:outline-0
|
|
@@ -668,7 +668,7 @@ const me = {
|
|
|
668
668
|
${u ? "rounded-full" : "rounded-md"}
|
|
669
669
|
${p ? `${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
|
-
autoFocus:
|
|
671
|
+
autoFocus: g,
|
|
672
672
|
...h,
|
|
673
673
|
children: [
|
|
674
674
|
r && /* @__PURE__ */ a.jsx("span", { className: "mr-1", children: r }),
|
|
@@ -801,7 +801,7 @@ var Gt;
|
|
|
801
801
|
function lo() {
|
|
802
802
|
if (Gt) return te;
|
|
803
803
|
Gt = 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, p = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, v = e ? Symbol.for("react.suspense") : 60113,
|
|
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, p = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, v = e ? Symbol.for("react.suspense") : 60113, d = e ? Symbol.for("react.suspense_list") : 60120, g = e ? Symbol.for("react.memo") : 60115, x = e ? Symbol.for("react.lazy") : 60116, f = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, C = e ? Symbol.for("react.responder") : 60118, M = e ? Symbol.for("react.scope") : 60119;
|
|
805
805
|
function w(b) {
|
|
806
806
|
if (typeof b == "object" && b !== null) {
|
|
807
807
|
var I = b.$$typeof;
|
|
@@ -820,7 +820,7 @@ function lo() {
|
|
|
820
820
|
case s:
|
|
821
821
|
case u:
|
|
822
822
|
case x:
|
|
823
|
-
case
|
|
823
|
+
case g:
|
|
824
824
|
case l:
|
|
825
825
|
return b;
|
|
826
826
|
default:
|
|
@@ -835,7 +835,7 @@ function lo() {
|
|
|
835
835
|
function L(b) {
|
|
836
836
|
return w(b) === p;
|
|
837
837
|
}
|
|
838
|
-
return te.AsyncMode = c, te.ConcurrentMode = p, te.ContextConsumer = s, te.ContextProvider = l, te.Element = n, te.ForwardRef = u, te.Fragment = o, te.Lazy = x, te.Memo =
|
|
838
|
+
return te.AsyncMode = c, te.ConcurrentMode = p, te.ContextConsumer = s, te.ContextProvider = l, te.Element = n, te.ForwardRef = u, te.Fragment = o, te.Lazy = x, te.Memo = g, te.Portal = t, te.Profiler = i, te.StrictMode = r, te.Suspense = v, te.isAsyncMode = function(b) {
|
|
839
839
|
return L(b) || w(b) === c;
|
|
840
840
|
}, te.isConcurrentMode = L, te.isContextConsumer = function(b) {
|
|
841
841
|
return w(b) === s;
|
|
@@ -850,7 +850,7 @@ function lo() {
|
|
|
850
850
|
}, te.isLazy = function(b) {
|
|
851
851
|
return w(b) === x;
|
|
852
852
|
}, te.isMemo = function(b) {
|
|
853
|
-
return w(b) ===
|
|
853
|
+
return w(b) === g;
|
|
854
854
|
}, te.isPortal = function(b) {
|
|
855
855
|
return w(b) === t;
|
|
856
856
|
}, te.isProfiler = function(b) {
|
|
@@ -860,7 +860,7 @@ function lo() {
|
|
|
860
860
|
}, te.isSuspense = function(b) {
|
|
861
861
|
return w(b) === v;
|
|
862
862
|
}, te.isValidElementType = function(b) {
|
|
863
|
-
return typeof b == "string" || typeof b == "function" || b === o || b === p || b === i || b === r || b === v || b ===
|
|
863
|
+
return typeof b == "string" || typeof b == "function" || b === o || b === p || b === i || b === r || b === v || b === d || typeof b == "object" && b !== null && (b.$$typeof === x || b.$$typeof === g || b.$$typeof === l || b.$$typeof === s || b.$$typeof === u || b.$$typeof === h || b.$$typeof === C || b.$$typeof === M || b.$$typeof === f);
|
|
864
864
|
}, te.typeOf = w, 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, p = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, v = e ? Symbol.for("react.suspense") : 60113,
|
|
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, p = e ? Symbol.for("react.concurrent_mode") : 60111, u = e ? Symbol.for("react.forward_ref") : 60112, v = e ? Symbol.for("react.suspense") : 60113, d = e ? Symbol.for("react.suspense_list") : 60120, g = e ? Symbol.for("react.memo") : 60115, x = e ? Symbol.for("react.lazy") : 60116, f = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, C = e ? Symbol.for("react.responder") : 60118, M = e ? Symbol.for("react.scope") : 60119;
|
|
879
879
|
function w(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 === p || S === i || S === r || S === v || S ===
|
|
881
|
+
S === o || S === p || S === i || S === r || S === v || S === d || typeof S == "object" && S !== null && (S.$$typeof === x || S.$$typeof === g || S.$$typeof === l || S.$$typeof === s || S.$$typeof === u || S.$$typeof === h || S.$$typeof === C || S.$$typeof === M || S.$$typeof === f);
|
|
882
882
|
}
|
|
883
883
|
function L(S) {
|
|
884
884
|
if (typeof S == "object" && S !== null) {
|
|
@@ -900,7 +900,7 @@ function so() {
|
|
|
900
900
|
case s:
|
|
901
901
|
case u:
|
|
902
902
|
case x:
|
|
903
|
-
case
|
|
903
|
+
case g:
|
|
904
904
|
case l:
|
|
905
905
|
return J;
|
|
906
906
|
default:
|
|
@@ -912,17 +912,17 @@ function so() {
|
|
|
912
912
|
}
|
|
913
913
|
}
|
|
914
914
|
}
|
|
915
|
-
var b = c, I = p, T = s, H = l, N = n, ee = u, ie = o, ce = x, U =
|
|
915
|
+
var b = c, I = p, T = s, H = l, N = n, ee = u, ie = o, ce = x, U = g, O = t, Y = i, D = r, Q = v, pe = !1;
|
|
916
916
|
function K(S) {
|
|
917
|
-
return pe || (pe = !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.")),
|
|
917
|
+
return pe || (pe = !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.")), m(S) || L(S) === c;
|
|
918
918
|
}
|
|
919
|
-
function
|
|
919
|
+
function m(S) {
|
|
920
920
|
return L(S) === p;
|
|
921
921
|
}
|
|
922
922
|
function y(S) {
|
|
923
923
|
return L(S) === s;
|
|
924
924
|
}
|
|
925
|
-
function
|
|
925
|
+
function E(S) {
|
|
926
926
|
return L(S) === l;
|
|
927
927
|
}
|
|
928
928
|
function _(S) {
|
|
@@ -938,7 +938,7 @@ function so() {
|
|
|
938
938
|
return L(S) === x;
|
|
939
939
|
}
|
|
940
940
|
function R(S) {
|
|
941
|
-
return L(S) ===
|
|
941
|
+
return L(S) === g;
|
|
942
942
|
}
|
|
943
943
|
function $(S) {
|
|
944
944
|
return L(S) === t;
|
|
@@ -952,7 +952,7 @@ function so() {
|
|
|
952
952
|
function j(S) {
|
|
953
953
|
return L(S) === v;
|
|
954
954
|
}
|
|
955
|
-
ne.AsyncMode = b, ne.ConcurrentMode = I, ne.ContextConsumer = T, ne.ContextProvider = H, ne.Element = N, ne.ForwardRef = ee, ne.Fragment = ie, ne.Lazy = ce, ne.Memo = U, ne.Portal = O, ne.Profiler = Y, ne.StrictMode = D, ne.Suspense = Q, ne.isAsyncMode = K, ne.isConcurrentMode =
|
|
955
|
+
ne.AsyncMode = b, ne.ConcurrentMode = I, ne.ContextConsumer = T, ne.ContextProvider = H, ne.Element = N, ne.ForwardRef = ee, ne.Fragment = ie, ne.Lazy = ce, ne.Memo = U, ne.Portal = O, ne.Profiler = Y, ne.StrictMode = D, ne.Suspense = Q, ne.isAsyncMode = K, ne.isConcurrentMode = m, ne.isContextConsumer = y, ne.isContextProvider = E, ne.isElement = _, ne.isForwardRef = F, ne.isFragment = z, ne.isLazy = A, ne.isMemo = R, ne.isPortal = $, ne.isProfiler = V, ne.isStrictMode = q, ne.isSuspense = j, ne.isValidElementType = w, ne.typeOf = L;
|
|
956
956
|
}()), ne;
|
|
957
957
|
}
|
|
958
958
|
var Yt;
|
|
@@ -1003,8 +1003,8 @@ function co() {
|
|
|
1003
1003
|
n.call(s, v) && (c[v] = s[v]);
|
|
1004
1004
|
if (e) {
|
|
1005
1005
|
p = e(s);
|
|
1006
|
-
for (var
|
|
1007
|
-
t.call(s, p[
|
|
1006
|
+
for (var d = 0; d < p.length; d++)
|
|
1007
|
+
t.call(s, p[d]) && (c[p[d]] = s[p[d]]);
|
|
1008
1008
|
}
|
|
1009
1009
|
}
|
|
1010
1010
|
return c;
|
|
@@ -1045,10 +1045,10 @@ function uo() {
|
|
|
1045
1045
|
var v;
|
|
1046
1046
|
try {
|
|
1047
1047
|
if (typeof i[u] != "function") {
|
|
1048
|
-
var
|
|
1048
|
+
var d = Error(
|
|
1049
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 d.name = "Invariant Violation", d;
|
|
1052
1052
|
}
|
|
1053
1053
|
v = i[u](l, u, c, s, null, n);
|
|
1054
1054
|
} catch (x) {
|
|
@@ -1058,9 +1058,9 @@ function uo() {
|
|
|
1058
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 v + ". 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
|
), v instanceof Error && !(v.message in t)) {
|
|
1060
1060
|
t[v.message] = !0;
|
|
1061
|
-
var
|
|
1061
|
+
var g = p ? p() : "";
|
|
1062
1062
|
e(
|
|
1063
|
-
"Failed " + s + " type: " + v.message + (
|
|
1063
|
+
"Failed " + s + " type: " + v.message + (g ?? "")
|
|
1064
1064
|
);
|
|
1065
1065
|
}
|
|
1066
1066
|
}
|
|
@@ -1089,12 +1089,12 @@ function po() {
|
|
|
1089
1089
|
}
|
|
1090
1090
|
return gt = function(s, c) {
|
|
1091
1091
|
var p = typeof Symbol == "function" && Symbol.iterator, u = "@@iterator";
|
|
1092
|
-
function v(
|
|
1093
|
-
var y =
|
|
1092
|
+
function v(m) {
|
|
1093
|
+
var y = m && (p && m[p] || m[u]);
|
|
1094
1094
|
if (typeof y == "function")
|
|
1095
1095
|
return y;
|
|
1096
1096
|
}
|
|
1097
|
-
var
|
|
1097
|
+
var d = "<<anonymous>>", g = {
|
|
1098
1098
|
array: C("array"),
|
|
1099
1099
|
bigint: C("bigint"),
|
|
1100
1100
|
bool: C("boolean"),
|
|
@@ -1103,7 +1103,7 @@ function po() {
|
|
|
1103
1103
|
object: C("object"),
|
|
1104
1104
|
string: C("string"),
|
|
1105
1105
|
symbol: C("symbol"),
|
|
1106
|
-
any:
|
|
1106
|
+
any: M(),
|
|
1107
1107
|
arrayOf: w,
|
|
1108
1108
|
element: L(),
|
|
1109
1109
|
elementType: b(),
|
|
@@ -1115,18 +1115,18 @@ function po() {
|
|
|
1115
1115
|
shape: ce,
|
|
1116
1116
|
exact: U
|
|
1117
1117
|
};
|
|
1118
|
-
function x(
|
|
1119
|
-
return
|
|
1118
|
+
function x(m, y) {
|
|
1119
|
+
return m === y ? m !== 0 || 1 / m === 1 / y : m !== m && y !== y;
|
|
1120
1120
|
}
|
|
1121
|
-
function m
|
|
1122
|
-
this.message =
|
|
1121
|
+
function f(m, y) {
|
|
1122
|
+
this.message = m, this.data = y && typeof y == "object" ? y : {}, this.stack = "";
|
|
1123
1123
|
}
|
|
1124
|
-
|
|
1125
|
-
function h(
|
|
1124
|
+
f.prototype = Error.prototype;
|
|
1125
|
+
function h(m) {
|
|
1126
1126
|
if (process.env.NODE_ENV !== "production")
|
|
1127
|
-
var y = {},
|
|
1127
|
+
var y = {}, E = 0;
|
|
1128
1128
|
function _(z, A, R, $, V, q, j) {
|
|
1129
|
-
if ($ = $ ||
|
|
1129
|
+
if ($ = $ || d, q = q || R, j !== 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"
|
|
@@ -1135,44 +1135,44 @@ function po() {
|
|
|
1135
1135
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
1136
1136
|
var k = $ + ":" + R;
|
|
1137
1137
|
!y[k] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
1138
|
-
|
|
1138
|
+
E < 3 && (i(
|
|
1139
1139
|
"You are manually calling a React.PropTypes validation function for the `" + q + "` prop on `" + $ + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
|
|
1140
|
-
), y[k] = !0,
|
|
1140
|
+
), y[k] = !0, E++);
|
|
1141
1141
|
}
|
|
1142
1142
|
}
|
|
1143
|
-
return A[R] == null ? z ? A[R] === null ? new
|
|
1143
|
+
return A[R] == null ? z ? A[R] === null ? new f("The " + V + " `" + q + "` is marked as required " + ("in `" + $ + "`, but its value is `null`.")) : new f("The " + V + " `" + q + "` is marked as required in " + ("`" + $ + "`, but its value is `undefined`.")) : null : m(A, R, $, V, q);
|
|
1144
1144
|
}
|
|
1145
1145
|
var F = _.bind(null, !1);
|
|
1146
1146
|
return F.isRequired = _.bind(null, !0), F;
|
|
1147
1147
|
}
|
|
1148
|
-
function C(
|
|
1149
|
-
function y(
|
|
1150
|
-
var $ =
|
|
1151
|
-
if (V !==
|
|
1148
|
+
function C(m) {
|
|
1149
|
+
function y(E, _, F, z, A, R) {
|
|
1150
|
+
var $ = E[_], V = D($);
|
|
1151
|
+
if (V !== m) {
|
|
1152
1152
|
var q = Q($);
|
|
1153
|
-
return new
|
|
1154
|
-
"Invalid " + z + " `" + A + "` of type " + ("`" + q + "` supplied to `" + F + "`, expected ") + ("`" +
|
|
1155
|
-
{ expectedType:
|
|
1153
|
+
return new f(
|
|
1154
|
+
"Invalid " + z + " `" + A + "` of type " + ("`" + q + "` supplied to `" + F + "`, expected ") + ("`" + m + "`."),
|
|
1155
|
+
{ expectedType: m }
|
|
1156
1156
|
);
|
|
1157
1157
|
}
|
|
1158
1158
|
return null;
|
|
1159
1159
|
}
|
|
1160
1160
|
return h(y);
|
|
1161
1161
|
}
|
|
1162
|
-
function
|
|
1162
|
+
function M() {
|
|
1163
1163
|
return h(l);
|
|
1164
1164
|
}
|
|
1165
|
-
function w(
|
|
1166
|
-
function y(
|
|
1167
|
-
if (typeof
|
|
1168
|
-
return new
|
|
1169
|
-
var R =
|
|
1165
|
+
function w(m) {
|
|
1166
|
+
function y(E, _, F, z, A) {
|
|
1167
|
+
if (typeof m != "function")
|
|
1168
|
+
return new f("Property `" + A + "` of component `" + F + "` has invalid PropType notation inside arrayOf.");
|
|
1169
|
+
var R = E[_];
|
|
1170
1170
|
if (!Array.isArray(R)) {
|
|
1171
1171
|
var $ = D(R);
|
|
1172
|
-
return new
|
|
1172
|
+
return new f("Invalid " + z + " `" + A + "` of type " + ("`" + $ + "` supplied to `" + F + "`, expected an array."));
|
|
1173
1173
|
}
|
|
1174
1174
|
for (var V = 0; V < R.length; V++) {
|
|
1175
|
-
var q =
|
|
1175
|
+
var q = m(R, V, F, z, A + "[" + V + "]", t);
|
|
1176
1176
|
if (q instanceof Error)
|
|
1177
1177
|
return q;
|
|
1178
1178
|
}
|
|
@@ -1181,64 +1181,64 @@ function po() {
|
|
|
1181
1181
|
return h(y);
|
|
1182
1182
|
}
|
|
1183
1183
|
function L() {
|
|
1184
|
-
function
|
|
1185
|
-
var A = y[
|
|
1184
|
+
function m(y, E, _, F, z) {
|
|
1185
|
+
var A = y[E];
|
|
1186
1186
|
if (!s(A)) {
|
|
1187
1187
|
var R = D(A);
|
|
1188
|
-
return new
|
|
1188
|
+
return new f("Invalid " + F + " `" + z + "` of type " + ("`" + R + "` supplied to `" + _ + "`, expected a single ReactElement."));
|
|
1189
1189
|
}
|
|
1190
1190
|
return null;
|
|
1191
1191
|
}
|
|
1192
|
-
return h(
|
|
1192
|
+
return h(m);
|
|
1193
1193
|
}
|
|
1194
1194
|
function b() {
|
|
1195
|
-
function
|
|
1196
|
-
var A = y[
|
|
1195
|
+
function m(y, E, _, F, z) {
|
|
1196
|
+
var A = y[E];
|
|
1197
1197
|
if (!e.isValidElementType(A)) {
|
|
1198
1198
|
var R = D(A);
|
|
1199
|
-
return new
|
|
1199
|
+
return new f("Invalid " + F + " `" + z + "` of type " + ("`" + R + "` supplied to `" + _ + "`, expected a single ReactElement type."));
|
|
1200
1200
|
}
|
|
1201
1201
|
return null;
|
|
1202
1202
|
}
|
|
1203
|
-
return h(
|
|
1203
|
+
return h(m);
|
|
1204
1204
|
}
|
|
1205
|
-
function I(
|
|
1206
|
-
function y(
|
|
1207
|
-
if (!(
|
|
1208
|
-
var R =
|
|
1209
|
-
return new
|
|
1205
|
+
function I(m) {
|
|
1206
|
+
function y(E, _, F, z, A) {
|
|
1207
|
+
if (!(E[_] instanceof m)) {
|
|
1208
|
+
var R = m.name || d, $ = K(E[_]);
|
|
1209
|
+
return new f("Invalid " + z + " `" + A + "` of type " + ("`" + $ + "` supplied to `" + F + "`, expected ") + ("instance of `" + R + "`."));
|
|
1210
1210
|
}
|
|
1211
1211
|
return null;
|
|
1212
1212
|
}
|
|
1213
1213
|
return h(y);
|
|
1214
1214
|
}
|
|
1215
|
-
function T(
|
|
1216
|
-
if (!Array.isArray(
|
|
1215
|
+
function T(m) {
|
|
1216
|
+
if (!Array.isArray(m))
|
|
1217
1217
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
|
|
1218
1218
|
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
|
|
1219
1219
|
) : i("Invalid argument supplied to oneOf, expected an array.")), l;
|
|
1220
|
-
function y(
|
|
1221
|
-
for (var R =
|
|
1222
|
-
if (x(R,
|
|
1220
|
+
function y(E, _, F, z, A) {
|
|
1221
|
+
for (var R = E[_], $ = 0; $ < m.length; $++)
|
|
1222
|
+
if (x(R, m[$]))
|
|
1223
1223
|
return null;
|
|
1224
|
-
var V = JSON.stringify(
|
|
1224
|
+
var V = JSON.stringify(m, function(j, S) {
|
|
1225
1225
|
var k = Q(S);
|
|
1226
1226
|
return k === "symbol" ? String(S) : S;
|
|
1227
1227
|
});
|
|
1228
|
-
return new
|
|
1228
|
+
return new f("Invalid " + z + " `" + A + "` of value `" + String(R) + "` " + ("supplied to `" + F + "`, expected one of " + V + "."));
|
|
1229
1229
|
}
|
|
1230
1230
|
return h(y);
|
|
1231
1231
|
}
|
|
1232
|
-
function H(
|
|
1233
|
-
function y(
|
|
1234
|
-
if (typeof
|
|
1235
|
-
return new
|
|
1236
|
-
var R =
|
|
1232
|
+
function H(m) {
|
|
1233
|
+
function y(E, _, F, z, A) {
|
|
1234
|
+
if (typeof m != "function")
|
|
1235
|
+
return new f("Property `" + A + "` of component `" + F + "` has invalid PropType notation inside objectOf.");
|
|
1236
|
+
var R = E[_], $ = D(R);
|
|
1237
1237
|
if ($ !== "object")
|
|
1238
|
-
return new
|
|
1238
|
+
return new f("Invalid " + z + " `" + A + "` of type " + ("`" + $ + "` supplied to `" + F + "`, expected an object."));
|
|
1239
1239
|
for (var V in R)
|
|
1240
1240
|
if (o(R, V)) {
|
|
1241
|
-
var q =
|
|
1241
|
+
var q = m(R, V, F, z, A + "." + V, t);
|
|
1242
1242
|
if (q instanceof Error)
|
|
1243
1243
|
return q;
|
|
1244
1244
|
}
|
|
@@ -1246,46 +1246,46 @@ function po() {
|
|
|
1246
1246
|
}
|
|
1247
1247
|
return h(y);
|
|
1248
1248
|
}
|
|
1249
|
-
function N(
|
|
1250
|
-
if (!Array.isArray(
|
|
1249
|
+
function N(m) {
|
|
1250
|
+
if (!Array.isArray(m))
|
|
1251
1251
|
return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), l;
|
|
1252
|
-
for (var y = 0; y <
|
|
1253
|
-
var
|
|
1254
|
-
if (typeof
|
|
1252
|
+
for (var y = 0; y < m.length; y++) {
|
|
1253
|
+
var E = m[y];
|
|
1254
|
+
if (typeof E != "function")
|
|
1255
1255
|
return i(
|
|
1256
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + pe(
|
|
1256
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + pe(E) + " at index " + y + "."
|
|
1257
1257
|
), l;
|
|
1258
1258
|
}
|
|
1259
1259
|
function _(F, z, A, R, $) {
|
|
1260
|
-
for (var V = [], q = 0; q <
|
|
1261
|
-
var j =
|
|
1260
|
+
for (var V = [], q = 0; q < m.length; q++) {
|
|
1261
|
+
var j = m[q], S = j(F, z, A, R, $, t);
|
|
1262
1262
|
if (S == null)
|
|
1263
1263
|
return null;
|
|
1264
1264
|
S.data && o(S.data, "expectedType") && V.push(S.data.expectedType);
|
|
1265
1265
|
}
|
|
1266
1266
|
var k = V.length > 0 ? ", expected one of type [" + V.join(", ") + "]" : "";
|
|
1267
|
-
return new
|
|
1267
|
+
return new f("Invalid " + R + " `" + $ + "` supplied to " + ("`" + A + "`" + k + "."));
|
|
1268
1268
|
}
|
|
1269
1269
|
return h(_);
|
|
1270
1270
|
}
|
|
1271
1271
|
function ee() {
|
|
1272
|
-
function
|
|
1273
|
-
return O(y[
|
|
1272
|
+
function m(y, E, _, F, z) {
|
|
1273
|
+
return O(y[E]) ? null : new f("Invalid " + F + " `" + z + "` supplied to " + ("`" + _ + "`, expected a ReactNode."));
|
|
1274
1274
|
}
|
|
1275
|
-
return h(
|
|
1275
|
+
return h(m);
|
|
1276
1276
|
}
|
|
1277
|
-
function ie(
|
|
1278
|
-
return new
|
|
1279
|
-
(
|
|
1277
|
+
function ie(m, y, E, _, F) {
|
|
1278
|
+
return new f(
|
|
1279
|
+
(m || "React class") + ": " + y + " type `" + E + "." + _ + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + F + "`."
|
|
1280
1280
|
);
|
|
1281
1281
|
}
|
|
1282
|
-
function ce(
|
|
1283
|
-
function y(
|
|
1284
|
-
var R =
|
|
1282
|
+
function ce(m) {
|
|
1283
|
+
function y(E, _, F, z, A) {
|
|
1284
|
+
var R = E[_], $ = D(R);
|
|
1285
1285
|
if ($ !== "object")
|
|
1286
|
-
return new
|
|
1287
|
-
for (var V in
|
|
1288
|
-
var q =
|
|
1286
|
+
return new f("Invalid " + z + " `" + A + "` of type `" + $ + "` " + ("supplied to `" + F + "`, expected `object`."));
|
|
1287
|
+
for (var V in m) {
|
|
1288
|
+
var q = m[V];
|
|
1289
1289
|
if (typeof q != "function")
|
|
1290
1290
|
return ie(F, z, A, V, Q(q));
|
|
1291
1291
|
var j = q(R, V, F, z, A + "." + V, t);
|
|
@@ -1296,20 +1296,20 @@ function po() {
|
|
|
1296
1296
|
}
|
|
1297
1297
|
return h(y);
|
|
1298
1298
|
}
|
|
1299
|
-
function U(
|
|
1300
|
-
function y(
|
|
1301
|
-
var R =
|
|
1299
|
+
function U(m) {
|
|
1300
|
+
function y(E, _, F, z, A) {
|
|
1301
|
+
var R = E[_], $ = D(R);
|
|
1302
1302
|
if ($ !== "object")
|
|
1303
|
-
return new
|
|
1304
|
-
var V = n({},
|
|
1303
|
+
return new f("Invalid " + z + " `" + A + "` of type `" + $ + "` " + ("supplied to `" + F + "`, expected `object`."));
|
|
1304
|
+
var V = n({}, E[_], m);
|
|
1305
1305
|
for (var q in V) {
|
|
1306
|
-
var j =
|
|
1307
|
-
if (o(
|
|
1306
|
+
var j = m[q];
|
|
1307
|
+
if (o(m, q) && typeof j != "function")
|
|
1308
1308
|
return ie(F, z, A, q, Q(j));
|
|
1309
1309
|
if (!j)
|
|
1310
|
-
return new
|
|
1311
|
-
"Invalid " + z + " `" + A + "` key `" + q + "` supplied to `" + F + "`.\nBad object: " + JSON.stringify(
|
|
1312
|
-
Valid keys: ` + JSON.stringify(Object.keys(
|
|
1310
|
+
return new f(
|
|
1311
|
+
"Invalid " + z + " `" + A + "` key `" + q + "` supplied to `" + F + "`.\nBad object: " + JSON.stringify(E[_], null, " ") + `
|
|
1312
|
+
Valid keys: ` + JSON.stringify(Object.keys(m), null, " ")
|
|
1313
1313
|
);
|
|
1314
1314
|
var S = j(R, q, F, z, A + "." + q, t);
|
|
1315
1315
|
if (S)
|
|
@@ -1319,28 +1319,28 @@ Valid keys: ` + JSON.stringify(Object.keys(f), null, " ")
|
|
|
1319
1319
|
}
|
|
1320
1320
|
return h(y);
|
|
1321
1321
|
}
|
|
1322
|
-
function O(
|
|
1323
|
-
switch (typeof
|
|
1322
|
+
function O(m) {
|
|
1323
|
+
switch (typeof m) {
|
|
1324
1324
|
case "number":
|
|
1325
1325
|
case "string":
|
|
1326
1326
|
case "undefined":
|
|
1327
1327
|
return !0;
|
|
1328
1328
|
case "boolean":
|
|
1329
|
-
return !
|
|
1329
|
+
return !m;
|
|
1330
1330
|
case "object":
|
|
1331
|
-
if (Array.isArray(
|
|
1332
|
-
return
|
|
1333
|
-
if (
|
|
1331
|
+
if (Array.isArray(m))
|
|
1332
|
+
return m.every(O);
|
|
1333
|
+
if (m === null || s(m))
|
|
1334
1334
|
return !0;
|
|
1335
|
-
var y = v(
|
|
1335
|
+
var y = v(m);
|
|
1336
1336
|
if (y) {
|
|
1337
|
-
var
|
|
1338
|
-
if (y !==
|
|
1339
|
-
for (; !(_ =
|
|
1337
|
+
var E = y.call(m), _;
|
|
1338
|
+
if (y !== m.entries) {
|
|
1339
|
+
for (; !(_ = E.next()).done; )
|
|
1340
1340
|
if (!O(_.value))
|
|
1341
1341
|
return !1;
|
|
1342
1342
|
} else
|
|
1343
|
-
for (; !(_ =
|
|
1343
|
+
for (; !(_ = E.next()).done; ) {
|
|
1344
1344
|
var F = _.value;
|
|
1345
1345
|
if (F && !O(F[1]))
|
|
1346
1346
|
return !1;
|
|
@@ -1352,27 +1352,27 @@ Valid keys: ` + JSON.stringify(Object.keys(f), null, " ")
|
|
|
1352
1352
|
return !1;
|
|
1353
1353
|
}
|
|
1354
1354
|
}
|
|
1355
|
-
function Y(
|
|
1356
|
-
return
|
|
1355
|
+
function Y(m, y) {
|
|
1356
|
+
return m === "symbol" ? !0 : y ? y["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && y instanceof Symbol : !1;
|
|
1357
1357
|
}
|
|
1358
|
-
function D(
|
|
1359
|
-
var y = typeof
|
|
1360
|
-
return Array.isArray(
|
|
1358
|
+
function D(m) {
|
|
1359
|
+
var y = typeof m;
|
|
1360
|
+
return Array.isArray(m) ? "array" : m instanceof RegExp ? "object" : Y(y, m) ? "symbol" : y;
|
|
1361
1361
|
}
|
|
1362
|
-
function Q(
|
|
1363
|
-
if (typeof
|
|
1364
|
-
return "" +
|
|
1365
|
-
var y = D(
|
|
1362
|
+
function Q(m) {
|
|
1363
|
+
if (typeof m > "u" || m === null)
|
|
1364
|
+
return "" + m;
|
|
1365
|
+
var y = D(m);
|
|
1366
1366
|
if (y === "object") {
|
|
1367
|
-
if (
|
|
1367
|
+
if (m instanceof Date)
|
|
1368
1368
|
return "date";
|
|
1369
|
-
if (
|
|
1369
|
+
if (m instanceof RegExp)
|
|
1370
1370
|
return "regexp";
|
|
1371
1371
|
}
|
|
1372
1372
|
return y;
|
|
1373
1373
|
}
|
|
1374
|
-
function pe(
|
|
1375
|
-
var y = Q(
|
|
1374
|
+
function pe(m) {
|
|
1375
|
+
var y = Q(m);
|
|
1376
1376
|
switch (y) {
|
|
1377
1377
|
case "array":
|
|
1378
1378
|
case "object":
|
|
@@ -1385,10 +1385,10 @@ Valid keys: ` + JSON.stringify(Object.keys(f), null, " ")
|
|
|
1385
1385
|
return y;
|
|
1386
1386
|
}
|
|
1387
1387
|
}
|
|
1388
|
-
function K(
|
|
1389
|
-
return !
|
|
1388
|
+
function K(m) {
|
|
1389
|
+
return !m.constructor || !m.constructor.name ? d : m.constructor.name;
|
|
1390
1390
|
}
|
|
1391
|
-
return
|
|
1391
|
+
return g.checkPropTypes = r, g.resetWarningCache = r.resetWarningCache, g.PropTypes = g, g;
|
|
1392
1392
|
}, gt;
|
|
1393
1393
|
}
|
|
1394
1394
|
var ft, Qt;
|
|
@@ -1403,10 +1403,10 @@ function go() {
|
|
|
1403
1403
|
return t.resetWarningCache = n, ft = function() {
|
|
1404
1404
|
function o(l, s, c, p, u, v) {
|
|
1405
1405
|
if (v !== e) {
|
|
1406
|
-
var
|
|
1406
|
+
var d = 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 d.name = "Invariant Violation", d;
|
|
1410
1410
|
}
|
|
1411
1411
|
}
|
|
1412
1412
|
o.isRequired = o;
|
|
@@ -2969,8 +2969,8 @@ function $e(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 p = Pn(c, t), u = ze(p, 1), v = u[0],
|
|
2973
|
-
return v && x && !
|
|
2972
|
+
var p = Pn(c, t), u = ze(p, 1), v = u[0], d = Fn(c, o, r), g = ze(d, 1), x = g[0], f = s ? s(c) : null;
|
|
2973
|
+
return v && x && !f;
|
|
2974
2974
|
});
|
|
2975
2975
|
}
|
|
2976
2976
|
function Qe(e) {
|
|
@@ -3350,16 +3350,16 @@ var Mt = {
|
|
|
3350
3350
|
fileRejections: []
|
|
3351
3351
|
};
|
|
3352
3352
|
function Tn() {
|
|
3353
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = ae(ae({}, zn), e), t = n.accept, o = n.disabled, r = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles, p = n.onDragEnter, u = n.onDragLeave, v = n.onDragOver,
|
|
3353
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = ae(ae({}, zn), e), t = n.accept, o = n.disabled, r = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles, p = n.onDragEnter, u = n.onDragLeave, v = n.onDragOver, d = n.onDrop, g = n.onDropAccepted, x = n.onDropRejected, f = n.onFileDialogCancel, h = n.onFileDialogOpen, C = n.useFsAccessApi, M = n.autoFocus, w = n.preventDropOnDocument, L = n.noClick, b = n.noKeyboard, I = n.noDrag, T = n.noDragEventsBubbling, H = n.onError, N = n.validator, ee = Me(function() {
|
|
3354
3354
|
return Uo(t);
|
|
3355
3355
|
}, [t]), ie = Me(function() {
|
|
3356
3356
|
return Wo(t);
|
|
3357
3357
|
}, [t]), ce = Me(function() {
|
|
3358
3358
|
return typeof h == "function" ? h : gn;
|
|
3359
3359
|
}, [h]), U = Me(function() {
|
|
3360
|
-
return typeof
|
|
3361
|
-
}, [
|
|
3362
|
-
!
|
|
3360
|
+
return typeof f == "function" ? f : gn;
|
|
3361
|
+
}, [f]), O = le(null), Y = le(null), D = eo(ur, Mt), Q = xt(D, 2), pe = Q[0], K = Q[1], m = pe.isFocused, y = pe.isFileDialogActive, E = le(typeof window < "u" && window.isSecureContext && C && Yo()), _ = function() {
|
|
3362
|
+
!E.current && y && setTimeout(function() {
|
|
3363
3363
|
if (Y.current) {
|
|
3364
3364
|
var B = Y.current.files;
|
|
3365
3365
|
B.length || (K({
|
|
@@ -3372,7 +3372,7 @@ function Tn() {
|
|
|
3372
3372
|
return window.addEventListener("focus", _, !1), function() {
|
|
3373
3373
|
window.removeEventListener("focus", _, !1);
|
|
3374
3374
|
};
|
|
3375
|
-
}, [Y, y, U,
|
|
3375
|
+
}, [Y, y, U, E]);
|
|
3376
3376
|
var F = le([]), z = function(B) {
|
|
3377
3377
|
O.current && O.current.contains(B.target) || (B.preventDefault(), F.current = []);
|
|
3378
3378
|
};
|
|
@@ -3381,9 +3381,9 @@ function Tn() {
|
|
|
3381
3381
|
w && (document.removeEventListener("dragover", pn), document.removeEventListener("drop", z));
|
|
3382
3382
|
};
|
|
3383
3383
|
}, [O, w]), se(function() {
|
|
3384
|
-
return !o &&
|
|
3384
|
+
return !o && M && O.current && O.current.focus(), function() {
|
|
3385
3385
|
};
|
|
3386
|
-
}, [O,
|
|
3386
|
+
}, [O, M, o]);
|
|
3387
3387
|
var A = oe(function(P) {
|
|
3388
3388
|
H ? H(P) : console.error(P);
|
|
3389
3389
|
}, [H]), R = oe(function(P) {
|
|
@@ -3453,8 +3453,8 @@ function Tn() {
|
|
|
3453
3453
|
fileRejections: fe,
|
|
3454
3454
|
isDragReject: fe.length > 0,
|
|
3455
3455
|
type: "setFiles"
|
|
3456
|
-
}),
|
|
3457
|
-
}, [K, s, ee, l, i, c,
|
|
3456
|
+
}), d && d(ge, fe, B), fe.length > 0 && x && x(fe, B), ge.length > 0 && g && g(ge, B);
|
|
3457
|
+
}, [K, s, ee, l, i, c, d, g, x, N]), j = oe(function(P) {
|
|
3458
3458
|
P.preventDefault(), P.persist(), Ve(P), F.current = [], Ye(P) && Promise.resolve(r(P)).then(function(B) {
|
|
3459
3459
|
Qe(P) && !T || q(B, P);
|
|
3460
3460
|
}).catch(function(B) {
|
|
@@ -3463,7 +3463,7 @@ function Tn() {
|
|
|
3463
3463
|
type: "reset"
|
|
3464
3464
|
});
|
|
3465
3465
|
}, [r, q, A, T]), S = oe(function() {
|
|
3466
|
-
if (
|
|
3466
|
+
if (E.current) {
|
|
3467
3467
|
K({
|
|
3468
3468
|
type: "openDialog"
|
|
3469
3469
|
}), ce();
|
|
@@ -3480,7 +3480,7 @@ function Tn() {
|
|
|
3480
3480
|
}).catch(function(B) {
|
|
3481
3481
|
Ko(B) ? (U(B), K({
|
|
3482
3482
|
type: "closeDialog"
|
|
3483
|
-
})) : Xo(B) ? (
|
|
3483
|
+
})) : Xo(B) ? (E.current = !1, Y.current ? (Y.current.value = null, Y.current.click()) : A(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))) : A(B);
|
|
3484
3484
|
});
|
|
3485
3485
|
return;
|
|
3486
3486
|
}
|
|
@@ -3552,7 +3552,7 @@ function Tn() {
|
|
|
3552
3552
|
};
|
|
3553
3553
|
}, [Y, t, s, j, o]);
|
|
3554
3554
|
return ae(ae({}, pe), {}, {
|
|
3555
|
-
isFocused:
|
|
3555
|
+
isFocused: m && !o,
|
|
3556
3556
|
getRootProps: Kn,
|
|
3557
3557
|
getInputProps: Jn,
|
|
3558
3558
|
rootRef: O,
|
|
@@ -3616,14 +3616,14 @@ const Pi = ({
|
|
|
3616
3616
|
icon: p = /* @__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
3617
|
wrapperClass: u = "",
|
|
3618
3618
|
iconClass: v = "",
|
|
3619
|
-
labelClass:
|
|
3620
|
-
subLabelClass:
|
|
3619
|
+
labelClass: d = "",
|
|
3620
|
+
subLabelClass: g = "",
|
|
3621
3621
|
showList: x = !0,
|
|
3622
|
-
listView:
|
|
3622
|
+
listView: f = !0,
|
|
3623
3623
|
showListImage: h = !1,
|
|
3624
3624
|
uploadedFiles: C = [],
|
|
3625
3625
|
// New prop for pre-uploaded files
|
|
3626
|
-
onDeleteCallback:
|
|
3626
|
+
onDeleteCallback: M = () => {
|
|
3627
3627
|
}
|
|
3628
3628
|
//
|
|
3629
3629
|
}) => {
|
|
@@ -3662,7 +3662,7 @@ const Pi = ({
|
|
|
3662
3662
|
o
|
|
3663
3663
|
]
|
|
3664
3664
|
), H = (U) => {
|
|
3665
|
-
L((O) => O.filter((Y, D) => D !== U)),
|
|
3665
|
+
L((O) => O.filter((Y, D) => D !== U)), M(w);
|
|
3666
3666
|
}, { getRootProps: N, getInputProps: ee, isDragActive: ie, isDragReject: ce } = Tn({
|
|
3667
3667
|
onDrop: T,
|
|
3668
3668
|
accept: t,
|
|
@@ -3689,8 +3689,8 @@ const Pi = ({
|
|
|
3689
3689
|
children: [
|
|
3690
3690
|
/* @__PURE__ */ a.jsx("input", { ...ee() }),
|
|
3691
3691
|
/* @__PURE__ */ a.jsx("div", { className: `text-4xl mb-2 ${v}`, children: p }),
|
|
3692
|
-
/* @__PURE__ */ a.jsx("p", { className: `text-sm font-medium ${
|
|
3693
|
-
c && /* @__PURE__ */ a.jsx("p", { className: `text-xs mt-1 ${
|
|
3692
|
+
/* @__PURE__ */ a.jsx("p", { className: `text-sm font-medium ${d}`, children: s }),
|
|
3693
|
+
c && /* @__PURE__ */ a.jsx("p", { className: `text-xs mt-1 ${g}`, children: c })
|
|
3694
3694
|
]
|
|
3695
3695
|
}
|
|
3696
3696
|
),
|
|
@@ -3701,7 +3701,7 @@ const Pi = ({
|
|
|
3701
3701
|
x && w.length > 0 && /* @__PURE__ */ a.jsx(
|
|
3702
3702
|
"ul",
|
|
3703
3703
|
{
|
|
3704
|
-
className: `w-full ${
|
|
3704
|
+
className: `w-full ${f ? "space-y-2" : "grid grid-columns-2 gap-2"} px-4 pb-4`,
|
|
3705
3705
|
children: w.map((U, O) => /* @__PURE__ */ a.jsxs(
|
|
3706
3706
|
"li",
|
|
3707
3707
|
{
|
|
@@ -3815,23 +3815,23 @@ const dr = {
|
|
|
3815
3815
|
rounded: p = "medium",
|
|
3816
3816
|
...u
|
|
3817
3817
|
}, v) => {
|
|
3818
|
-
const
|
|
3818
|
+
const d = le([]), g = (f, h) => {
|
|
3819
3819
|
var w;
|
|
3820
|
-
const C =
|
|
3820
|
+
const C = f.target.value.replace(/[^0-9]/g, "").slice(0, 1);
|
|
3821
3821
|
if (!C && t[h] === void 0) return;
|
|
3822
|
-
const
|
|
3823
|
-
o == null || o(
|
|
3824
|
-
}, x = (
|
|
3825
|
-
var C,
|
|
3826
|
-
|
|
3822
|
+
const M = t.substring(0, h) + C + t.substring(h + 1, i);
|
|
3823
|
+
o == null || o(M), C && h < i - 1 && ((w = d.current[h + 1]) == null || w.focus()), r && M.length === i && !M.split("").some((L) => !L) && r(M);
|
|
3824
|
+
}, x = (f, h) => {
|
|
3825
|
+
var C, M, w;
|
|
3826
|
+
f.key === "Backspace" && !t[h] && h > 0 ? (o == null || o(
|
|
3827
3827
|
t.substring(0, h - 1) + "" + t.substring(h, i)
|
|
3828
|
-
), (C =
|
|
3828
|
+
), (C = d.current[h - 1]) == null || C.focus(), f.preventDefault()) : f.key === "ArrowLeft" && h > 0 ? ((M = d.current[h - 1]) == null || M.focus(), f.preventDefault()) : f.key === "ArrowRight" && h < i - 1 && ((w = d.current[h + 1]) == null || w.focus(), f.preventDefault());
|
|
3829
3829
|
};
|
|
3830
|
-
return /* @__PURE__ */ a.jsx("div", { className: `flex justify-center gap-2 ${e}`, children: Array.from({ length: i }).map((
|
|
3830
|
+
return /* @__PURE__ */ a.jsx("div", { className: `flex justify-center gap-2 ${e}`, children: Array.from({ length: i }).map((f, h) => /* @__PURE__ */ a.jsx(
|
|
3831
3831
|
"input",
|
|
3832
3832
|
{
|
|
3833
3833
|
ref: (C) => {
|
|
3834
|
-
|
|
3834
|
+
d.current[h] = C;
|
|
3835
3835
|
},
|
|
3836
3836
|
type: "text",
|
|
3837
3837
|
inputMode: "numeric",
|
|
@@ -3846,7 +3846,7 @@ const dr = {
|
|
|
3846
3846
|
${n}
|
|
3847
3847
|
`,
|
|
3848
3848
|
value: t[h] || "",
|
|
3849
|
-
onChange: (C) =>
|
|
3849
|
+
onChange: (C) => g(C, h),
|
|
3850
3850
|
onKeyDown: (C) => x(C, h),
|
|
3851
3851
|
...u
|
|
3852
3852
|
},
|
|
@@ -3876,20 +3876,20 @@ const xr = {
|
|
|
3876
3876
|
error: p,
|
|
3877
3877
|
maxLength: u,
|
|
3878
3878
|
label: v,
|
|
3879
|
-
labelClassName:
|
|
3880
|
-
variant:
|
|
3879
|
+
labelClassName: d = "",
|
|
3880
|
+
variant: g = "outlined",
|
|
3881
3881
|
size: x = "medium",
|
|
3882
|
-
...
|
|
3882
|
+
...f
|
|
3883
3883
|
}, h) => {
|
|
3884
|
-
const C = p ? "border-color-red-500 focus-within:ring-color-red-500" : "border-color-gray-200",
|
|
3884
|
+
const C = p ? "border-color-red-500 focus-within:ring-color-red-500" : "border-color-gray-200", M = p ? "text-color-red-500" : l;
|
|
3885
3885
|
return /* @__PURE__ */ a.jsxs("div", { className: "w-full", children: [
|
|
3886
|
-
v && /* @__PURE__ */ a.jsx("label", { className: `text-sm font-medium text-color-gray-700 mb-1 block ${
|
|
3887
|
-
/* @__PURE__ */ a.jsxs("div", { className: `flex items-center w-full rounded-md border focus-within:ring-1 ${C} ${vr[
|
|
3888
|
-
s && /* @__PURE__ */ a.jsx("span", { className: `pl-3 ${
|
|
3886
|
+
v && /* @__PURE__ */ a.jsx("label", { className: `text-sm font-medium text-color-gray-700 mb-1 block ${d}`, children: v }),
|
|
3887
|
+
/* @__PURE__ */ a.jsxs("div", { className: `flex items-center w-full rounded-md border focus-within:ring-1 ${C} ${vr[g]} ${r}`, children: [
|
|
3888
|
+
s && /* @__PURE__ */ a.jsx("span", { className: `pl-3 ${M}`, children: s }),
|
|
3889
3889
|
/* @__PURE__ */ a.jsx(
|
|
3890
3890
|
"input",
|
|
3891
3891
|
{
|
|
3892
|
-
...
|
|
3892
|
+
...f,
|
|
3893
3893
|
ref: h,
|
|
3894
3894
|
type: o,
|
|
3895
3895
|
placeholder: e,
|
|
@@ -3899,7 +3899,7 @@ const xr = {
|
|
|
3899
3899
|
className: `grow outline-0 w-full font-medium placeholder:font-normal bg-color-transparent ${xr[x]} ${i}`
|
|
3900
3900
|
}
|
|
3901
3901
|
),
|
|
3902
|
-
c && /* @__PURE__ */ a.jsx("span", { className: `pr-3 ${
|
|
3902
|
+
c && /* @__PURE__ */ a.jsx("span", { className: `pr-3 ${M}`, children: c })
|
|
3903
3903
|
] }),
|
|
3904
3904
|
p && /* @__PURE__ */ a.jsx("p", { className: "text-color-red-500 text-xs mt-1", children: p })
|
|
3905
3905
|
] });
|
|
@@ -3975,13 +3975,13 @@ const In = ({
|
|
|
3975
3975
|
autoFocus: c = !1,
|
|
3976
3976
|
...p
|
|
3977
3977
|
}) => {
|
|
3978
|
-
var
|
|
3978
|
+
var g;
|
|
3979
3979
|
const u = le(null), v = (x) => {
|
|
3980
|
-
const
|
|
3981
|
-
if (!
|
|
3982
|
-
const h = document.createElement("span"), C =
|
|
3983
|
-
h.style.width = h.style.height = `${
|
|
3984
|
-
},
|
|
3980
|
+
const f = u.current;
|
|
3981
|
+
if (!f) return;
|
|
3982
|
+
const h = document.createElement("span"), C = f.getBoundingClientRect(), M = Math.max(C.width, C.height);
|
|
3983
|
+
h.style.width = h.style.height = `${M}px`, h.style.left = `${x.clientX - C.left - M / 2}px`, h.style.top = `${x.clientY - C.top - M / 2}px`, h.className = "ripple_small", f.appendChild(h), setTimeout(() => h.remove(), 600), o == null || o(x);
|
|
3984
|
+
}, d = ((g = me[n]) == null ? void 0 : g[e === "filled" ? "filled" : e === "outlined" ? "outline" : "transparent"]) || "";
|
|
3985
3985
|
return /* @__PURE__ */ a.jsx(
|
|
3986
3986
|
"button",
|
|
3987
3987
|
{
|
|
@@ -3990,7 +3990,7 @@ const In = ({
|
|
|
3990
3990
|
disabled: i,
|
|
3991
3991
|
onClick: v,
|
|
3992
3992
|
className: `relative overflow-hidden flex items-center justify-center gap-1 transition-all focus:outline-0
|
|
3993
|
-
${
|
|
3993
|
+
${d}
|
|
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"}
|
|
@@ -4024,8 +4024,8 @@ const In = ({
|
|
|
4024
4024
|
avatar: u,
|
|
4025
4025
|
icon: v
|
|
4026
4026
|
}) => {
|
|
4027
|
-
var C,
|
|
4028
|
-
const
|
|
4027
|
+
var C, M;
|
|
4028
|
+
const d = (C = me[n]) == null ? void 0 : C.filled, g = (M = me[n]) == null ? void 0 : M.outline, x = br[o], f = `inline-flex items-center rounded-full font-medium leading-none ${t === "outlined" ? `border ${g}` : d} ${x} ${i ? "cursor-pointer transition hover:opacity-80" : ""}`.trim(), h = /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
4029
4029
|
u && /* @__PURE__ */ a.jsx(In, { ...typeof u == "object" ? u : {}, className: `-ml-1 mr-1 ${fn[o]}` }),
|
|
4030
4030
|
v && /* @__PURE__ */ a.jsx("span", { className: "mr-1 -ml-1", children: v }),
|
|
4031
4031
|
/* @__PURE__ */ a.jsx("span", { children: e }),
|
|
@@ -4049,14 +4049,14 @@ const In = ({
|
|
|
4049
4049
|
{
|
|
4050
4050
|
href: c,
|
|
4051
4051
|
target: p,
|
|
4052
|
-
className: `no-underline ${
|
|
4052
|
+
className: `no-underline ${f} ${r}`,
|
|
4053
4053
|
onClick: i,
|
|
4054
4054
|
children: h
|
|
4055
4055
|
}
|
|
4056
4056
|
) : /* @__PURE__ */ a.jsx(
|
|
4057
4057
|
"span",
|
|
4058
4058
|
{
|
|
4059
|
-
className: `${
|
|
4059
|
+
className: `${f} ${r}`,
|
|
4060
4060
|
onClick: i,
|
|
4061
4061
|
children: h
|
|
4062
4062
|
}
|
|
@@ -4157,15 +4157,15 @@ function G(e, n, t) {
|
|
|
4157
4157
|
o = s;
|
|
4158
4158
|
let p;
|
|
4159
4159
|
if (t.key && t.debug && (p = Date.now()), r = n(...s), t == null || t.onChange == null || t.onChange(r), t.key && t.debug && t != null && t.debug()) {
|
|
4160
|
-
const u = Math.round((Date.now() - l) * 100) / 100, v = Math.round((Date.now() - p) * 100) / 100,
|
|
4161
|
-
for (x = String(x); x.length <
|
|
4160
|
+
const u = Math.round((Date.now() - l) * 100) / 100, v = Math.round((Date.now() - p) * 100) / 100, d = v / 16, g = (x, f) => {
|
|
4161
|
+
for (x = String(x); x.length < f; )
|
|
4162
4162
|
x = " " + x;
|
|
4163
4163
|
return x;
|
|
4164
4164
|
};
|
|
4165
|
-
console.info(`%c⏱ ${
|
|
4165
|
+
console.info(`%c⏱ ${g(v, 5)} /${g(u, 5)} ms`, `
|
|
4166
4166
|
font-size: .6rem;
|
|
4167
4167
|
font-weight: bold;
|
|
4168
|
-
color: hsl(${Math.max(0, Math.min(120 - 120 *
|
|
4168
|
+
color: hsl(${Math.max(0, Math.min(120 - 120 * d, 120))}deg 100% 31%);`, t == null ? void 0 : t.key);
|
|
4169
4169
|
}
|
|
4170
4170
|
return r;
|
|
4171
4171
|
};
|
|
@@ -4210,14 +4210,14 @@ function jr(e, n, t, o) {
|
|
|
4210
4210
|
...n
|
|
4211
4211
|
}, c = s.accessorKey;
|
|
4212
4212
|
let p = (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;
|
|
4213
|
-
if (s.accessorFn ? u = s.accessorFn : c && (c.includes(".") ? u = (
|
|
4214
|
-
let
|
|
4215
|
-
for (const
|
|
4213
|
+
if (s.accessorFn ? u = s.accessorFn : c && (c.includes(".") ? u = (d) => {
|
|
4214
|
+
let g = d;
|
|
4215
|
+
for (const f of c.split(".")) {
|
|
4216
4216
|
var x;
|
|
4217
|
-
|
|
4217
|
+
g = (x = g) == null ? void 0 : x[f], process.env.NODE_ENV !== "production" && g === void 0 && console.warn(`"${f}" in deeply nested key "${c}" returned undefined.`);
|
|
4218
4218
|
}
|
|
4219
|
-
return
|
|
4220
|
-
} : u = (
|
|
4219
|
+
return g;
|
|
4220
|
+
} : u = (d) => d[s.accessorKey]), !p)
|
|
4221
4221
|
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();
|
|
4222
4222
|
let v = {
|
|
4223
4223
|
id: `${String(p)}`,
|
|
@@ -4227,20 +4227,20 @@ function jr(e, n, t, o) {
|
|
|
4227
4227
|
columnDef: s,
|
|
4228
4228
|
columns: [],
|
|
4229
4229
|
getFlatColumns: G(() => [!0], () => {
|
|
4230
|
-
var g;
|
|
4231
|
-
return [v, ...(g = v.columns) == null ? void 0 : g.flatMap((d) => d.getFlatColumns())];
|
|
4232
|
-
}, Z(e.options, "debugColumns", "column.getFlatColumns")),
|
|
4233
|
-
getLeafColumns: G(() => [e._getOrderColumnsFn()], (g) => {
|
|
4234
4230
|
var d;
|
|
4235
|
-
|
|
4236
|
-
|
|
4237
|
-
|
|
4231
|
+
return [v, ...(d = v.columns) == null ? void 0 : d.flatMap((g) => g.getFlatColumns())];
|
|
4232
|
+
}, Z(e.options, "debugColumns", "column.getFlatColumns")),
|
|
4233
|
+
getLeafColumns: G(() => [e._getOrderColumnsFn()], (d) => {
|
|
4234
|
+
var g;
|
|
4235
|
+
if ((g = v.columns) != null && g.length) {
|
|
4236
|
+
let x = v.columns.flatMap((f) => f.getLeafColumns());
|
|
4237
|
+
return d(x);
|
|
4238
4238
|
}
|
|
4239
4239
|
return [v];
|
|
4240
4240
|
}, Z(e.options, "debugColumns", "column.getLeafColumns"))
|
|
4241
4241
|
};
|
|
4242
|
-
for (const
|
|
4243
|
-
|
|
4242
|
+
for (const d of e._features)
|
|
4243
|
+
d.createColumn == null || d.createColumn(v, e);
|
|
4244
4244
|
return v;
|
|
4245
4245
|
}
|
|
4246
4246
|
const xe = "debugHeaders";
|
|
@@ -4277,7 +4277,7 @@ const Sr = {
|
|
|
4277
4277
|
createTable: (e) => {
|
|
4278
4278
|
e.getHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, o, r) => {
|
|
4279
4279
|
var i, l;
|
|
4280
|
-
const s = (i = o == null ? void 0 : o.map((v) => t.find((
|
|
4280
|
+
const s = (i = o == null ? void 0 : o.map((v) => t.find((d) => d.id === v)).filter(Boolean)) != null ? i : [], c = (l = r == null ? void 0 : r.map((v) => t.find((d) => d.id === v)).filter(Boolean)) != null ? l : [], p = t.filter((v) => !(o != null && o.includes(v.id)) && !(r != null && r.includes(v.id)));
|
|
4281
4281
|
return We(n, [...s, ...p, ...c], e);
|
|
4282
4282
|
}, Z(e.options, xe, "getHeaderGroups")), e.getCenterHeaderGroups = G(() => [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))), We(n, t, e, "center")), Z(e.options, xe, "getCenterHeaderGroups")), e.getLeftHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, o) => {
|
|
4283
4283
|
var r;
|
|
@@ -4305,54 +4305,54 @@ const Sr = {
|
|
|
4305
4305
|
function We(e, n, t, o) {
|
|
4306
4306
|
var r, i;
|
|
4307
4307
|
let l = 0;
|
|
4308
|
-
const s = function(
|
|
4309
|
-
|
|
4310
|
-
var
|
|
4311
|
-
(
|
|
4308
|
+
const s = function(d, g) {
|
|
4309
|
+
g === void 0 && (g = 1), l = Math.max(l, g), d.filter((x) => x.getIsVisible()).forEach((x) => {
|
|
4310
|
+
var f;
|
|
4311
|
+
(f = x.columns) != null && f.length && s(x.columns, g + 1);
|
|
4312
4312
|
}, 0);
|
|
4313
4313
|
};
|
|
4314
4314
|
s(e);
|
|
4315
4315
|
let c = [];
|
|
4316
|
-
const p = (
|
|
4316
|
+
const p = (d, g) => {
|
|
4317
4317
|
const x = {
|
|
4318
|
-
depth:
|
|
4319
|
-
id: [o, `${
|
|
4318
|
+
depth: g,
|
|
4319
|
+
id: [o, `${g}`].filter(Boolean).join("_"),
|
|
4320
4320
|
headers: []
|
|
4321
|
-
},
|
|
4322
|
-
|
|
4323
|
-
const C = [...
|
|
4321
|
+
}, f = [];
|
|
4322
|
+
d.forEach((h) => {
|
|
4323
|
+
const C = [...f].reverse()[0], M = h.column.depth === x.depth;
|
|
4324
4324
|
let w, L = !1;
|
|
4325
|
-
if (
|
|
4325
|
+
if (M && h.column.parent ? w = h.column.parent : (w = h.column, L = !0), C && (C == null ? void 0 : C.column) === w)
|
|
4326
4326
|
C.subHeaders.push(h);
|
|
4327
4327
|
else {
|
|
4328
4328
|
const b = mn(t, w, {
|
|
4329
|
-
id: [o,
|
|
4329
|
+
id: [o, g, w.id, h == null ? void 0 : h.id].filter(Boolean).join("_"),
|
|
4330
4330
|
isPlaceholder: L,
|
|
4331
|
-
placeholderId: L ? `${
|
|
4332
|
-
depth:
|
|
4333
|
-
index:
|
|
4331
|
+
placeholderId: L ? `${f.filter((I) => I.column === w).length}` : void 0,
|
|
4332
|
+
depth: g,
|
|
4333
|
+
index: f.length
|
|
4334
4334
|
});
|
|
4335
|
-
b.subHeaders.push(h),
|
|
4335
|
+
b.subHeaders.push(h), f.push(b);
|
|
4336
4336
|
}
|
|
4337
4337
|
x.headers.push(h), h.headerGroup = x;
|
|
4338
|
-
}), c.push(x),
|
|
4339
|
-
}, u = n.map((
|
|
4338
|
+
}), c.push(x), g > 0 && p(f, g - 1);
|
|
4339
|
+
}, u = n.map((d, g) => mn(t, d, {
|
|
4340
4340
|
depth: l,
|
|
4341
|
-
index:
|
|
4341
|
+
index: g
|
|
4342
4342
|
}));
|
|
4343
4343
|
p(u, l - 1), c.reverse();
|
|
4344
|
-
const v = (
|
|
4345
|
-
let
|
|
4344
|
+
const v = (d) => d.filter((x) => x.column.getIsVisible()).map((x) => {
|
|
4345
|
+
let f = 0, h = 0, C = [0];
|
|
4346
4346
|
x.subHeaders && x.subHeaders.length ? (C = [], v(x.subHeaders).forEach((w) => {
|
|
4347
4347
|
let {
|
|
4348
4348
|
colSpan: L,
|
|
4349
4349
|
rowSpan: b
|
|
4350
4350
|
} = w;
|
|
4351
|
-
|
|
4352
|
-
})) :
|
|
4353
|
-
const
|
|
4354
|
-
return h = h +
|
|
4355
|
-
colSpan:
|
|
4351
|
+
f += L, C.push(b);
|
|
4352
|
+
})) : f = 1;
|
|
4353
|
+
const M = Math.min(...C);
|
|
4354
|
+
return h = h + M, x.colSpan = f, x.rowSpan = h, {
|
|
4355
|
+
colSpan: f,
|
|
4356
4356
|
rowSpan: h
|
|
4357
4357
|
};
|
|
4358
4358
|
});
|
|
@@ -4854,10 +4854,10 @@ const Or = {
|
|
|
4854
4854
|
return (i) => {
|
|
4855
4855
|
if (!o || !r || (i.persist == null || i.persist(), wt(i) && i.touches && i.touches.length > 1))
|
|
4856
4856
|
return;
|
|
4857
|
-
const l = e.getSize(), s = e ? e.getLeafHeaders().map((C) => [C.column.id, C.column.getSize()]) : [[o.id, o.getSize()]], c = wt(i) ? Math.round(i.touches[0].clientX) : i.clientX, p = {}, u = (C,
|
|
4858
|
-
typeof
|
|
4857
|
+
const l = e.getSize(), s = e ? e.getLeafHeaders().map((C) => [C.column.id, C.column.getSize()]) : [[o.id, o.getSize()]], c = wt(i) ? Math.round(i.touches[0].clientX) : i.clientX, p = {}, u = (C, M) => {
|
|
4858
|
+
typeof M == "number" && (n.setColumnSizingInfo((w) => {
|
|
4859
4859
|
var L, b;
|
|
4860
|
-
const I = n.options.columnResizeDirection === "rtl" ? -1 : 1, T = (
|
|
4860
|
+
const I = n.options.columnResizeDirection === "rtl" ? -1 : 1, T = (M - ((L = w == null ? void 0 : w.startOffset) != null ? L : 0)) * I, H = Math.max(T / ((b = w == null ? void 0 : w.startSize) != null ? b : 0), -0.999999);
|
|
4861
4861
|
return w.columnSizingStart.forEach((N) => {
|
|
4862
4862
|
let [ee, ie] = N;
|
|
4863
4863
|
p[ee] = Math.round(Math.max(ie + ie * H, 0) * 100) / 100;
|
|
@@ -4870,9 +4870,9 @@ const Or = {
|
|
|
4870
4870
|
...w,
|
|
4871
4871
|
...p
|
|
4872
4872
|
})));
|
|
4873
|
-
}, v = (C) => u("move", C),
|
|
4874
|
-
u("end", C), n.setColumnSizingInfo((
|
|
4875
|
-
...
|
|
4873
|
+
}, v = (C) => u("move", C), d = (C) => {
|
|
4874
|
+
u("end", C), n.setColumnSizingInfo((M) => ({
|
|
4875
|
+
...M,
|
|
4876
4876
|
isResizingColumn: !1,
|
|
4877
4877
|
startOffset: null,
|
|
4878
4878
|
startSize: null,
|
|
@@ -4880,21 +4880,21 @@ const Or = {
|
|
|
4880
4880
|
deltaPercentage: null,
|
|
4881
4881
|
columnSizingStart: []
|
|
4882
4882
|
}));
|
|
4883
|
-
},
|
|
4883
|
+
}, g = t || typeof document < "u" ? document : null, x = {
|
|
4884
4884
|
moveHandler: (C) => v(C.clientX),
|
|
4885
4885
|
upHandler: (C) => {
|
|
4886
|
-
|
|
4886
|
+
g == null || g.removeEventListener("mousemove", x.moveHandler), g == null || g.removeEventListener("mouseup", x.upHandler), d(C.clientX);
|
|
4887
4887
|
}
|
|
4888
|
-
},
|
|
4888
|
+
}, f = {
|
|
4889
4889
|
moveHandler: (C) => (C.cancelable && (C.preventDefault(), C.stopPropagation()), v(C.touches[0].clientX), !1),
|
|
4890
4890
|
upHandler: (C) => {
|
|
4891
|
-
var
|
|
4892
|
-
|
|
4891
|
+
var M;
|
|
4892
|
+
g == null || g.removeEventListener("touchmove", f.moveHandler), g == null || g.removeEventListener("touchend", f.upHandler), C.cancelable && (C.preventDefault(), C.stopPropagation()), d((M = C.touches[0]) == null ? void 0 : M.clientX);
|
|
4893
4893
|
}
|
|
4894
4894
|
}, h = Hr() ? {
|
|
4895
4895
|
passive: !1
|
|
4896
4896
|
} : !1;
|
|
4897
|
-
wt(i) ? (
|
|
4897
|
+
wt(i) ? (g == null || g.addEventListener("touchmove", f.moveHandler, h), g == null || g.addEventListener("touchend", f.upHandler, h)) : (g == null || g.addEventListener("mousemove", x.moveHandler, h), g == null || g.addEventListener("mouseup", x.upHandler, h)), n.setColumnSizingInfo((C) => ({
|
|
4898
4898
|
...C,
|
|
4899
4899
|
startOffset: c,
|
|
4900
4900
|
startSize: l,
|
|
@@ -5233,22 +5233,22 @@ const Br = {
|
|
|
5233
5233
|
n.setRowPinning((c) => {
|
|
5234
5234
|
var p, u;
|
|
5235
5235
|
if (t === "bottom") {
|
|
5236
|
-
var v,
|
|
5236
|
+
var v, d;
|
|
5237
5237
|
return {
|
|
5238
|
-
top: ((v = c == null ? void 0 : c.top) != null ? v : []).filter((
|
|
5239
|
-
bottom: [...((
|
|
5238
|
+
top: ((v = c == null ? void 0 : c.top) != null ? v : []).filter((f) => !(s != null && s.has(f))),
|
|
5239
|
+
bottom: [...((d = c == null ? void 0 : c.bottom) != null ? d : []).filter((f) => !(s != null && s.has(f))), ...Array.from(s)]
|
|
5240
5240
|
};
|
|
5241
5241
|
}
|
|
5242
5242
|
if (t === "top") {
|
|
5243
|
-
var
|
|
5243
|
+
var g, x;
|
|
5244
5244
|
return {
|
|
5245
|
-
top: [...((
|
|
5246
|
-
bottom: ((x = c == null ? void 0 : c.bottom) != null ? x : []).filter((
|
|
5245
|
+
top: [...((g = c == null ? void 0 : c.top) != null ? g : []).filter((f) => !(s != null && s.has(f))), ...Array.from(s)],
|
|
5246
|
+
bottom: ((x = c == null ? void 0 : c.bottom) != null ? x : []).filter((f) => !(s != null && s.has(f)))
|
|
5247
5247
|
};
|
|
5248
5248
|
}
|
|
5249
5249
|
return {
|
|
5250
|
-
top: ((p = c == null ? void 0 : c.top) != null ? p : []).filter((
|
|
5251
|
-
bottom: ((u = c == null ? void 0 : c.bottom) != null ? u : []).filter((
|
|
5250
|
+
top: ((p = c == null ? void 0 : c.top) != null ? p : []).filter((f) => !(s != null && s.has(f))),
|
|
5251
|
+
bottom: ((u = c == null ? void 0 : c.bottom) != null ? u : []).filter((f) => !(s != null && s.has(f)))
|
|
5252
5252
|
};
|
|
5253
5253
|
});
|
|
5254
5254
|
}, e.getCanPin = () => {
|
|
@@ -5539,18 +5539,18 @@ const Ne = {
|
|
|
5539
5539
|
}, e.toggleSorting = (t, o) => {
|
|
5540
5540
|
const r = e.getNextSortingOrder(), i = typeof t < "u" && t !== null;
|
|
5541
5541
|
n.setSorting((l) => {
|
|
5542
|
-
const s = l == null ? void 0 : l.find((
|
|
5542
|
+
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);
|
|
5543
5543
|
let p = [], u, v = i ? t : r === "desc";
|
|
5544
5544
|
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") {
|
|
5545
|
-
var
|
|
5545
|
+
var d;
|
|
5546
5546
|
p = [...l, {
|
|
5547
5547
|
id: e.id,
|
|
5548
5548
|
desc: v
|
|
5549
|
-
}], p.splice(0, p.length - ((
|
|
5550
|
-
} else u === "toggle" ? p = l.map((
|
|
5551
|
-
...
|
|
5549
|
+
}], p.splice(0, p.length - ((d = n.options.maxMultiSortColCount) != null ? d : Number.MAX_SAFE_INTEGER));
|
|
5550
|
+
} else u === "toggle" ? p = l.map((g) => g.id === e.id ? {
|
|
5551
|
+
...g,
|
|
5552
5552
|
desc: v
|
|
5553
|
-
} :
|
|
5553
|
+
} : g) : u === "remove" ? p = l.filter((g) => g.id !== e.id) : p = [{
|
|
5554
5554
|
id: e.id,
|
|
5555
5555
|
desc: v
|
|
5556
5556
|
}];
|
|
@@ -5619,17 +5619,17 @@ function ri(e) {
|
|
|
5619
5619
|
let r = {
|
|
5620
5620
|
_features: o
|
|
5621
5621
|
};
|
|
5622
|
-
const i = r._features.reduce((
|
|
5622
|
+
const i = r._features.reduce((d, g) => Object.assign(d, g.getDefaultOptions == null ? void 0 : g.getDefaultOptions(r)), {}), l = (d) => r.options.mergeOptions ? r.options.mergeOptions(i, d) : {
|
|
5623
5623
|
...i,
|
|
5624
|
-
...
|
|
5624
|
+
...d
|
|
5625
5625
|
};
|
|
5626
5626
|
let c = {
|
|
5627
5627
|
...{},
|
|
5628
5628
|
...(t = e.initialState) != null ? t : {}
|
|
5629
5629
|
};
|
|
5630
|
-
r._features.forEach((
|
|
5631
|
-
var
|
|
5632
|
-
c = (
|
|
5630
|
+
r._features.forEach((d) => {
|
|
5631
|
+
var g;
|
|
5632
|
+
c = (g = d.getInitialState == null ? void 0 : d.getInitialState(c)) != null ? g : c;
|
|
5633
5633
|
});
|
|
5634
5634
|
const p = [];
|
|
5635
5635
|
let u = !1;
|
|
@@ -5640,82 +5640,82 @@ function ri(e) {
|
|
|
5640
5640
|
...e
|
|
5641
5641
|
},
|
|
5642
5642
|
initialState: c,
|
|
5643
|
-
_queue: (
|
|
5644
|
-
p.push(
|
|
5643
|
+
_queue: (d) => {
|
|
5644
|
+
p.push(d), u || (u = !0, Promise.resolve().then(() => {
|
|
5645
5645
|
for (; p.length; )
|
|
5646
5646
|
p.shift()();
|
|
5647
5647
|
u = !1;
|
|
5648
|
-
}).catch((
|
|
5649
|
-
throw
|
|
5648
|
+
}).catch((g) => setTimeout(() => {
|
|
5649
|
+
throw g;
|
|
5650
5650
|
})));
|
|
5651
5651
|
},
|
|
5652
5652
|
reset: () => {
|
|
5653
5653
|
r.setState(r.initialState);
|
|
5654
5654
|
},
|
|
5655
|
-
setOptions: (
|
|
5656
|
-
const
|
|
5657
|
-
r.options = l(
|
|
5655
|
+
setOptions: (d) => {
|
|
5656
|
+
const g = ke(d, r.options);
|
|
5657
|
+
r.options = l(g);
|
|
5658
5658
|
},
|
|
5659
5659
|
getState: () => r.options.state,
|
|
5660
|
-
setState: (
|
|
5661
|
-
r.options.onStateChange == null || r.options.onStateChange(
|
|
5660
|
+
setState: (d) => {
|
|
5661
|
+
r.options.onStateChange == null || r.options.onStateChange(d);
|
|
5662
5662
|
},
|
|
5663
|
-
_getRowId: (
|
|
5664
|
-
var
|
|
5665
|
-
return (
|
|
5663
|
+
_getRowId: (d, g, x) => {
|
|
5664
|
+
var f;
|
|
5665
|
+
return (f = r.options.getRowId == null ? void 0 : r.options.getRowId(d, g, x)) != null ? f : `${x ? [x.id, g].join(".") : g}`;
|
|
5666
5666
|
},
|
|
5667
5667
|
getCoreRowModel: () => (r._getCoreRowModel || (r._getCoreRowModel = r.options.getCoreRowModel(r)), r._getCoreRowModel()),
|
|
5668
5668
|
// The final calls start at the bottom of the model,
|
|
5669
5669
|
// expanded rows, which then work their way up
|
|
5670
5670
|
getRowModel: () => r.getPaginationRowModel(),
|
|
5671
5671
|
//in next version, we should just pass in the row model as the optional 2nd arg
|
|
5672
|
-
getRow: (
|
|
5673
|
-
let x = (
|
|
5674
|
-
if (!x && (x = r.getCoreRowModel().rowsById[
|
|
5675
|
-
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${
|
|
5672
|
+
getRow: (d, g) => {
|
|
5673
|
+
let x = (g ? r.getPrePaginationRowModel() : r.getRowModel()).rowsById[d];
|
|
5674
|
+
if (!x && (x = r.getCoreRowModel().rowsById[d], !x))
|
|
5675
|
+
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${d}`) : new Error();
|
|
5676
5676
|
return x;
|
|
5677
5677
|
},
|
|
5678
|
-
_getDefaultColumnDef: G(() => [r.options.defaultColumn], (
|
|
5679
|
-
var
|
|
5680
|
-
return
|
|
5678
|
+
_getDefaultColumnDef: G(() => [r.options.defaultColumn], (d) => {
|
|
5679
|
+
var g;
|
|
5680
|
+
return d = (g = d) != null ? g : {}, {
|
|
5681
5681
|
header: (x) => {
|
|
5682
|
-
const
|
|
5683
|
-
return
|
|
5682
|
+
const f = x.header.column.columnDef;
|
|
5683
|
+
return f.accessorKey ? f.accessorKey : f.accessorFn ? f.id : null;
|
|
5684
5684
|
},
|
|
5685
5685
|
// footer: props => props.header.column.id,
|
|
5686
5686
|
cell: (x) => {
|
|
5687
|
-
var
|
|
5688
|
-
return (
|
|
5687
|
+
var f, h;
|
|
5688
|
+
return (f = (h = x.renderValue()) == null || h.toString == null ? void 0 : h.toString()) != null ? f : null;
|
|
5689
5689
|
},
|
|
5690
|
-
...r._features.reduce((x,
|
|
5691
|
-
...
|
|
5690
|
+
...r._features.reduce((x, f) => Object.assign(x, f.getDefaultColumnDef == null ? void 0 : f.getDefaultColumnDef()), {}),
|
|
5691
|
+
...d
|
|
5692
5692
|
};
|
|
5693
5693
|
}, Z(e, "debugColumns", "_getDefaultColumnDef")),
|
|
5694
5694
|
_getColumnDefs: () => r.options.columns,
|
|
5695
|
-
getAllColumns: G(() => [r._getColumnDefs()], (
|
|
5696
|
-
const
|
|
5695
|
+
getAllColumns: G(() => [r._getColumnDefs()], (d) => {
|
|
5696
|
+
const g = function(x, f, h) {
|
|
5697
5697
|
return h === void 0 && (h = 0), x.map((C) => {
|
|
5698
|
-
const
|
|
5699
|
-
return
|
|
5698
|
+
const M = jr(r, C, h, f), w = C;
|
|
5699
|
+
return M.columns = w.columns ? g(w.columns, M, h + 1) : [], M;
|
|
5700
5700
|
});
|
|
5701
5701
|
};
|
|
5702
|
-
return d
|
|
5702
|
+
return g(d);
|
|
5703
5703
|
}, Z(e, "debugColumns", "getAllColumns")),
|
|
5704
|
-
getAllFlatColumns: G(() => [r.getAllColumns()], (
|
|
5705
|
-
_getAllFlatColumnsById: G(() => [r.getAllFlatColumns()], (
|
|
5706
|
-
getAllLeafColumns: G(() => [r.getAllColumns(), r._getOrderColumnsFn()], (
|
|
5707
|
-
let x =
|
|
5708
|
-
return
|
|
5704
|
+
getAllFlatColumns: G(() => [r.getAllColumns()], (d) => d.flatMap((g) => g.getFlatColumns()), Z(e, "debugColumns", "getAllFlatColumns")),
|
|
5705
|
+
_getAllFlatColumnsById: G(() => [r.getAllFlatColumns()], (d) => d.reduce((g, x) => (g[x.id] = x, g), {}), Z(e, "debugColumns", "getAllFlatColumnsById")),
|
|
5706
|
+
getAllLeafColumns: G(() => [r.getAllColumns(), r._getOrderColumnsFn()], (d, g) => {
|
|
5707
|
+
let x = d.flatMap((f) => f.getLeafColumns());
|
|
5708
|
+
return g(x);
|
|
5709
5709
|
}, Z(e, "debugColumns", "getAllLeafColumns")),
|
|
5710
|
-
getColumn: (
|
|
5711
|
-
const
|
|
5712
|
-
return process.env.NODE_ENV !== "production" && !
|
|
5710
|
+
getColumn: (d) => {
|
|
5711
|
+
const g = r._getAllFlatColumnsById()[d];
|
|
5712
|
+
return process.env.NODE_ENV !== "production" && !g && console.error(`[Table] Column with id '${d}' does not exist.`), g;
|
|
5713
5713
|
}
|
|
5714
5714
|
};
|
|
5715
5715
|
Object.assign(r, v);
|
|
5716
|
-
for (let
|
|
5717
|
-
const
|
|
5718
|
-
|
|
5716
|
+
for (let d = 0; d < r._features.length; d++) {
|
|
5717
|
+
const g = r._features[d];
|
|
5718
|
+
g == null || g.createTable == null || g.createTable(r);
|
|
5719
5719
|
}
|
|
5720
5720
|
return r;
|
|
5721
5721
|
}
|
|
@@ -5889,7 +5889,8 @@ const li = {
|
|
|
5889
5889
|
className: c = "",
|
|
5890
5890
|
paginationClassName: p = "",
|
|
5891
5891
|
tdClassName: u = "",
|
|
5892
|
-
thClassName: v = ""
|
|
5892
|
+
thClassName: v = "",
|
|
5893
|
+
responsive: d = !1
|
|
5893
5894
|
}) => {
|
|
5894
5895
|
const g = ai({
|
|
5895
5896
|
data: e,
|
|
@@ -5901,51 +5902,74 @@ const li = {
|
|
|
5901
5902
|
pagination: { pageIndex: o, pageSize: t }
|
|
5902
5903
|
}
|
|
5903
5904
|
});
|
|
5904
|
-
return /* @__PURE__ */ a.jsx(a.Fragment, { children: /* @__PURE__ */ a.jsxs(
|
|
5905
|
-
|
|
5906
|
-
|
|
5907
|
-
|
|
5908
|
-
|
|
5909
|
-
|
|
5910
|
-
|
|
5911
|
-
|
|
5912
|
-
|
|
5913
|
-
|
|
5914
|
-
|
|
5915
|
-
|
|
5916
|
-
|
|
5917
|
-
|
|
5918
|
-
|
|
5919
|
-
|
|
5920
|
-
|
|
5921
|
-
|
|
5922
|
-
|
|
5923
|
-
|
|
5924
|
-
|
|
5925
|
-
|
|
5926
|
-
|
|
5927
|
-
|
|
5905
|
+
return /* @__PURE__ */ a.jsx(a.Fragment, { children: /* @__PURE__ */ a.jsxs(
|
|
5906
|
+
"div",
|
|
5907
|
+
{
|
|
5908
|
+
className: `relative overflow-y-auto flex flex-col ${c} `,
|
|
5909
|
+
children: [
|
|
5910
|
+
/* @__PURE__ */ a.jsx("div", { className: `${d ? "overflow-x-auto" : ""}`, children: /* @__PURE__ */ a.jsxs("table", { className: "w-full relative border-collapse", children: [
|
|
5911
|
+
/* @__PURE__ */ a.jsx("thead", { className: "sticky top-0 left-0 rounded-xl bg-color-[#FAFBFB] z-10 h-10", children: g.getHeaderGroups().map((x) => /* @__PURE__ */ a.jsx("tr", { children: x.headers.map((f) => /* @__PURE__ */ a.jsx(
|
|
5912
|
+
"th",
|
|
5913
|
+
{
|
|
5914
|
+
className: `bg-color-[#FAFBFB] p-2 text-left text-xs font-semibold text-color-gray-500 border-b border-color-gray-200 ${v}`,
|
|
5915
|
+
children: f.isPlaceholder ? null : f.column.columnDef.header instanceof Function ? f.column.columnDef.header(
|
|
5916
|
+
f.getContext()
|
|
5917
|
+
) : f.column.columnDef.header
|
|
5918
|
+
},
|
|
5919
|
+
f.id
|
|
5920
|
+
)) }, x.id)) }),
|
|
5921
|
+
/* @__PURE__ */ a.jsx("tbody", { className: "", children: g.getRowModel().rows.map((x) => /* @__PURE__ */ a.jsx(
|
|
5922
|
+
"tr",
|
|
5923
|
+
{
|
|
5924
|
+
className: "border-b border-color-gray-200",
|
|
5925
|
+
children: x.getVisibleCells().map((f) => /* @__PURE__ */ a.jsx(
|
|
5926
|
+
"td",
|
|
5927
|
+
{
|
|
5928
|
+
className: `px-2 py-4 font-normal text-sm text-color-gray-800 ${u}`,
|
|
5929
|
+
children: f.column.columnDef.cell instanceof Function ? f.column.columnDef.cell(
|
|
5930
|
+
f.getContext()
|
|
5931
|
+
) : f.getValue()
|
|
5932
|
+
},
|
|
5933
|
+
f.id
|
|
5934
|
+
))
|
|
5935
|
+
},
|
|
5936
|
+
x.id
|
|
5937
|
+
)) })
|
|
5938
|
+
] }) }),
|
|
5939
|
+
/* @__PURE__ */ a.jsxs(
|
|
5940
|
+
"div",
|
|
5928
5941
|
{
|
|
5929
|
-
|
|
5930
|
-
|
|
5931
|
-
|
|
5932
|
-
|
|
5933
|
-
|
|
5934
|
-
|
|
5942
|
+
className: `w-full py-4 px-2 border-t border-color-gray-200 bg-color-[#FAFBFB] flex justify-between items-center ${p} sticky bottom-0 z-10`,
|
|
5943
|
+
children: [
|
|
5944
|
+
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
5945
|
+
/* @__PURE__ */ a.jsx(si, { variant: "body2", className: "hidden md:!flex", children: "Rows per page" }),
|
|
5946
|
+
/* @__PURE__ */ a.jsx(
|
|
5947
|
+
pr,
|
|
5948
|
+
{
|
|
5949
|
+
options: l,
|
|
5950
|
+
selectedValue: t,
|
|
5951
|
+
placementTop: !0,
|
|
5952
|
+
onChange: (x) => {
|
|
5953
|
+
r(x), i(0);
|
|
5954
|
+
}
|
|
5955
|
+
}
|
|
5956
|
+
)
|
|
5957
|
+
] }),
|
|
5958
|
+
/* @__PURE__ */ a.jsx(
|
|
5959
|
+
ci,
|
|
5960
|
+
{
|
|
5961
|
+
total: s,
|
|
5962
|
+
pageSize: t,
|
|
5963
|
+
currentPage: o + 1,
|
|
5964
|
+
onPageChange: (x) => i(x - 1)
|
|
5965
|
+
}
|
|
5966
|
+
)
|
|
5967
|
+
]
|
|
5935
5968
|
}
|
|
5936
5969
|
)
|
|
5937
|
-
]
|
|
5938
|
-
|
|
5939
|
-
|
|
5940
|
-
{
|
|
5941
|
-
total: s,
|
|
5942
|
-
pageSize: t,
|
|
5943
|
-
currentPage: o + 1,
|
|
5944
|
-
onPageChange: (d) => i(d - 1)
|
|
5945
|
-
}
|
|
5946
|
-
)
|
|
5947
|
-
] })
|
|
5948
|
-
] }) });
|
|
5970
|
+
]
|
|
5971
|
+
}
|
|
5972
|
+
) });
|
|
5949
5973
|
}, zi = ({ children: e, className: n = "" }) => /* @__PURE__ */ a.jsx("ul", { className: `divide-y divide-color-gray-200 rounded-md bg-color-white shadow-sm border border-color-gray-200 ${n}`, children: e }), Ti = ({ children: e, secondaryAction: n, className: t = "" }) => /* @__PURE__ */ a.jsxs("li", { className: `flex items-center justify-between overflow-hidden px-4 py-3 hover:bg-color-gray-50 transition ${t}`, children: [
|
|
5950
5974
|
/* @__PURE__ */ a.jsx("div", { className: "flex-1", children: e }),
|
|
5951
5975
|
n && /* @__PURE__ */ a.jsx("div", { className: "ml-4", children: n })
|
|
@@ -6014,15 +6038,15 @@ const li = {
|
|
|
6014
6038
|
defaultHeight: 100
|
|
6015
6039
|
};
|
|
6016
6040
|
}
|
|
6017
|
-
}, { classes: c, defaultWidth: p, defaultHeight: u } = s(), v = t ?? p,
|
|
6018
|
-
v !== void 0 && (
|
|
6041
|
+
}, { classes: c, defaultWidth: p, defaultHeight: u } = s(), v = t ?? p, d = o ?? u, g = {};
|
|
6042
|
+
v !== void 0 && (g.width = `${v}px`), d !== void 0 && (g.height = `${d}px`), n === "text" && t === void 0 && (g.width = "100%");
|
|
6019
6043
|
const x = [
|
|
6020
6044
|
i,
|
|
6021
6045
|
c,
|
|
6022
6046
|
l[e],
|
|
6023
6047
|
r
|
|
6024
6048
|
].filter(Boolean).join(" ");
|
|
6025
|
-
return /* @__PURE__ */ a.jsx("div", { className: x, style:
|
|
6049
|
+
return /* @__PURE__ */ a.jsx("div", { className: x, style: g, children: e === "wave" && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6026
6050
|
/* @__PURE__ */ a.jsx(
|
|
6027
6051
|
"div",
|
|
6028
6052
|
{
|
|
@@ -6118,13 +6142,13 @@ const Vi = no(function({
|
|
|
6118
6142
|
size: p = "medium",
|
|
6119
6143
|
disabled: u = !1,
|
|
6120
6144
|
className: v = "",
|
|
6121
|
-
showValue:
|
|
6122
|
-
showMarks:
|
|
6145
|
+
showValue: d = !0,
|
|
6146
|
+
showMarks: g = !1,
|
|
6123
6147
|
marks: x = [],
|
|
6124
|
-
range:
|
|
6148
|
+
range: f = !1,
|
|
6125
6149
|
minDistance: h = 0
|
|
6126
6150
|
}) {
|
|
6127
|
-
const C = n !== void 0, [
|
|
6151
|
+
const C = n !== void 0, [M, w] = W(() => t !== void 0 ? t : f ? [i, l] : i), L = C ? n : M, b = Array.isArray(L) ? L[0] : L, [I, T] = Array.isArray(L) ? L : [L, L], H = St[c] || St.blue, N = vn[p] ?? vn.medium, ee = oe(
|
|
6128
6152
|
(k) => (k - i) / (l - i) * 100,
|
|
6129
6153
|
[i, l]
|
|
6130
6154
|
), ie = ee(b), ce = ee(I), U = ee(T), O = oe((k) => Math.max(i, Math.min(l, k)), [i, l]), Y = oe((k) => Math.round(k / s) * s, [s]), D = gi(o), Q = oe(
|
|
@@ -6137,24 +6161,24 @@ const Vi = no(function({
|
|
|
6137
6161
|
k != null && (D.flush(k), r == null || r(k));
|
|
6138
6162
|
}, [D, r]), K = oe(
|
|
6139
6163
|
(k, X) => {
|
|
6140
|
-
if (
|
|
6164
|
+
if (f && Array.isArray(k)) {
|
|
6141
6165
|
let [J, ue] = k, de = Y(O(J)), ve = Y(O(ue));
|
|
6142
6166
|
return ve - de < h && (X === "min" ? ve = O(de + h) : X === "max" && (de = O(ve - h))), de > ve && (X === "min" ? de = ve : ve = de), [de, ve];
|
|
6143
|
-
} else if (!
|
|
6167
|
+
} else if (!f && typeof k == "number")
|
|
6144
6168
|
return Y(O(k));
|
|
6145
6169
|
return k;
|
|
6146
6170
|
},
|
|
6147
|
-
[
|
|
6148
|
-
),
|
|
6171
|
+
[f, O, Y, h]
|
|
6172
|
+
), m = le(null), y = oe(
|
|
6149
6173
|
(k) => {
|
|
6150
6174
|
var ue;
|
|
6151
|
-
const X = (ue =
|
|
6152
|
-
if (!X) return
|
|
6175
|
+
const X = (ue = m.current) == null ? void 0 : ue.getBoundingClientRect();
|
|
6176
|
+
if (!X) return f ? i : b;
|
|
6153
6177
|
const J = Math.max(0, Math.min(1, (k - X.left) / X.width));
|
|
6154
6178
|
return i + J * (l - i);
|
|
6155
6179
|
},
|
|
6156
|
-
[i, l,
|
|
6157
|
-
),
|
|
6180
|
+
[i, l, f, b]
|
|
6181
|
+
), E = oe(
|
|
6158
6182
|
(k) => {
|
|
6159
6183
|
const X = Math.abs(k - I), J = Math.abs(k - T);
|
|
6160
6184
|
return X <= J ? "min" : "max";
|
|
@@ -6166,17 +6190,17 @@ const Vi = no(function({
|
|
|
6166
6190
|
if (u) return;
|
|
6167
6191
|
k.preventDefault(), (de = (ue = k.currentTarget).setPointerCapture) == null || de.call(ue, k.pointerId), $(k.pointerId);
|
|
6168
6192
|
const J = y(k.clientX);
|
|
6169
|
-
if (
|
|
6170
|
-
const ve = X ||
|
|
6193
|
+
if (f) {
|
|
6194
|
+
const ve = X || E(J);
|
|
6171
6195
|
F(ve), Q(ve === "min" ? K([J, T], "min") : K([I, J], "max"));
|
|
6172
6196
|
} else
|
|
6173
6197
|
F("single"), Q(K(J, "single"));
|
|
6174
6198
|
},
|
|
6175
6199
|
[
|
|
6176
6200
|
u,
|
|
6177
|
-
|
|
6201
|
+
f,
|
|
6178
6202
|
y,
|
|
6179
|
-
|
|
6203
|
+
E,
|
|
6180
6204
|
K,
|
|
6181
6205
|
I,
|
|
6182
6206
|
T,
|
|
@@ -6186,13 +6210,13 @@ const Vi = no(function({
|
|
|
6186
6210
|
(k) => {
|
|
6187
6211
|
if (u || R == null || _ == null) return;
|
|
6188
6212
|
const X = y(k.clientX);
|
|
6189
|
-
|
|
6213
|
+
f ? _ === "min" ? Q(K([X, T], "min")) : _ === "max" && Q(K([I, X], "max")) : Q(K(X, "single"));
|
|
6190
6214
|
},
|
|
6191
6215
|
[
|
|
6192
6216
|
u,
|
|
6193
6217
|
R,
|
|
6194
6218
|
_,
|
|
6195
|
-
|
|
6219
|
+
f,
|
|
6196
6220
|
y,
|
|
6197
6221
|
K,
|
|
6198
6222
|
I,
|
|
@@ -6204,7 +6228,7 @@ const Vi = no(function({
|
|
|
6204
6228
|
}, [_, pe]), S = oe(
|
|
6205
6229
|
(k, X) => {
|
|
6206
6230
|
if (u) return;
|
|
6207
|
-
const J =
|
|
6231
|
+
const J = f ? X === "min" ? I : T : b;
|
|
6208
6232
|
let ue = J;
|
|
6209
6233
|
const de = (l - i) / 10;
|
|
6210
6234
|
switch (k.key) {
|
|
@@ -6231,11 +6255,11 @@ const Vi = no(function({
|
|
|
6231
6255
|
default:
|
|
6232
6256
|
return;
|
|
6233
6257
|
}
|
|
6234
|
-
k.preventDefault(), Q(
|
|
6258
|
+
k.preventDefault(), Q(f ? X === "min" ? K([ue, T], "min") : K([I, ue], "max") : K(ue, "single"), !1), r == null || r(C ? n : L);
|
|
6235
6259
|
},
|
|
6236
6260
|
[
|
|
6237
6261
|
u,
|
|
6238
|
-
|
|
6262
|
+
f,
|
|
6239
6263
|
b,
|
|
6240
6264
|
I,
|
|
6241
6265
|
T,
|
|
@@ -6257,12 +6281,12 @@ const Vi = no(function({
|
|
|
6257
6281
|
document.body.style.userSelect = k;
|
|
6258
6282
|
};
|
|
6259
6283
|
}, [_]), /* @__PURE__ */ a.jsx("div", { className: `w-full ${v}`, children: /* @__PURE__ */ a.jsxs("div", { className: "relative flex items-center", children: [
|
|
6260
|
-
|
|
6284
|
+
f && /* @__PURE__ */ a.jsx("div", { className: "mr-3 text-sm font-medium text-color-gray-700 dark:text-color-gray-200 min-w-[2rem]", children: /* @__PURE__ */ a.jsx("div", { className: "range-min", children: /* @__PURE__ */ a.jsx("div", { children: I }) }) }),
|
|
6261
6285
|
/* @__PURE__ */ a.jsxs("div", { className: "w-full", children: [
|
|
6262
6286
|
/* @__PURE__ */ a.jsxs(
|
|
6263
6287
|
"div",
|
|
6264
6288
|
{
|
|
6265
|
-
ref:
|
|
6289
|
+
ref: m,
|
|
6266
6290
|
className: `
|
|
6267
6291
|
relative w-full ${N.track} ${H.track} rounded-full
|
|
6268
6292
|
${u ? "opacity-60 cursor-not-allowed" : "cursor-pointer"}
|
|
@@ -6272,7 +6296,7 @@ const Vi = no(function({
|
|
|
6272
6296
|
onPointerUp: j,
|
|
6273
6297
|
onPointerCancel: j,
|
|
6274
6298
|
children: [
|
|
6275
|
-
|
|
6299
|
+
f ? /* @__PURE__ */ a.jsx(
|
|
6276
6300
|
"div",
|
|
6277
6301
|
{
|
|
6278
6302
|
className: `absolute top-0 ${N.track} ${H.progress} rounded-full ${_ ? "" : "transition-all duration-150"}`,
|
|
@@ -6285,7 +6309,7 @@ const Vi = no(function({
|
|
|
6285
6309
|
style: { width: `${ie}%` }
|
|
6286
6310
|
}
|
|
6287
6311
|
),
|
|
6288
|
-
|
|
6312
|
+
g && x.map((k, X) => {
|
|
6289
6313
|
const J = ee(k.value);
|
|
6290
6314
|
return /* @__PURE__ */ a.jsx(
|
|
6291
6315
|
"div",
|
|
@@ -6296,7 +6320,7 @@ const Vi = no(function({
|
|
|
6296
6320
|
X
|
|
6297
6321
|
);
|
|
6298
6322
|
}),
|
|
6299
|
-
!
|
|
6323
|
+
!f && /* @__PURE__ */ a.jsx(
|
|
6300
6324
|
"div",
|
|
6301
6325
|
{
|
|
6302
6326
|
className: `
|
|
@@ -6321,7 +6345,7 @@ const Vi = no(function({
|
|
|
6321
6345
|
onPointerDown: (k) => V(k, "single")
|
|
6322
6346
|
}
|
|
6323
6347
|
),
|
|
6324
|
-
|
|
6348
|
+
f && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6325
6349
|
/* @__PURE__ */ a.jsx(
|
|
6326
6350
|
"div",
|
|
6327
6351
|
{
|
|
@@ -6378,7 +6402,7 @@ const Vi = no(function({
|
|
|
6378
6402
|
]
|
|
6379
6403
|
}
|
|
6380
6404
|
),
|
|
6381
|
-
|
|
6405
|
+
g && x.length > 0 && /* @__PURE__ */ a.jsx(
|
|
6382
6406
|
"div",
|
|
6383
6407
|
{
|
|
6384
6408
|
className: "relative mt-2 text-xs text-color-gray-500 dark:text-color-gray-200",
|
|
@@ -6397,7 +6421,7 @@ const Vi = no(function({
|
|
|
6397
6421
|
}
|
|
6398
6422
|
)
|
|
6399
6423
|
] }),
|
|
6400
|
-
|
|
6424
|
+
d && /* @__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: f ? /* @__PURE__ */ a.jsx("div", { className: "range-max", children: /* @__PURE__ */ a.jsx("div", { children: T }) }) : /* @__PURE__ */ a.jsx("span", { children: b }) })
|
|
6401
6425
|
] }) });
|
|
6402
6426
|
}), Hi = ({
|
|
6403
6427
|
open: e = !1,
|
|
@@ -6412,36 +6436,36 @@ const Vi = no(function({
|
|
|
6412
6436
|
var v;
|
|
6413
6437
|
se(() => {
|
|
6414
6438
|
if (e && t > 0 && i) {
|
|
6415
|
-
const
|
|
6439
|
+
const d = setTimeout(() => {
|
|
6416
6440
|
i();
|
|
6417
6441
|
}, t);
|
|
6418
|
-
return () => clearTimeout(
|
|
6442
|
+
return () => clearTimeout(d);
|
|
6419
6443
|
}
|
|
6420
6444
|
}, [e, t, i]), se(() => {
|
|
6421
|
-
const
|
|
6422
|
-
|
|
6445
|
+
const d = (g) => {
|
|
6446
|
+
g.key === "Escape" && e && i && i();
|
|
6423
6447
|
};
|
|
6424
6448
|
if (e)
|
|
6425
|
-
return document.addEventListener("keydown",
|
|
6449
|
+
return document.addEventListener("keydown", d), () => document.removeEventListener("keydown", d);
|
|
6426
6450
|
}, [e, i]);
|
|
6427
6451
|
const c = oe(() => {
|
|
6428
6452
|
i && i();
|
|
6429
|
-
}, [i]), p = (
|
|
6430
|
-
const
|
|
6431
|
-
switch (
|
|
6453
|
+
}, [i]), p = (d) => {
|
|
6454
|
+
const g = "fixed z-50 transform transition-all duration-300 ease-in-out";
|
|
6455
|
+
switch (d) {
|
|
6432
6456
|
case "top-center":
|
|
6433
|
-
return `${
|
|
6457
|
+
return `${g} top-4 left-1/2 -translate-x-1/2 ${e ? "translate-y-0 opacity-100" : "-translate-y-full opacity-0"}`;
|
|
6434
6458
|
case "top-left":
|
|
6435
|
-
return `${
|
|
6459
|
+
return `${g} top-4 left-4 ${e ? "translate-y-0 opacity-100" : "-translate-y-full opacity-0"}`;
|
|
6436
6460
|
case "top-right":
|
|
6437
|
-
return `${
|
|
6461
|
+
return `${g} top-4 right-4 ${e ? "translate-y-0 opacity-100" : "-translate-y-full opacity-0"}`;
|
|
6438
6462
|
case "bottom-left":
|
|
6439
|
-
return `${
|
|
6463
|
+
return `${g} bottom-4 left-4 ${e ? "translate-y-0 opacity-100" : "translate-y-full opacity-0"}`;
|
|
6440
6464
|
case "bottom-right":
|
|
6441
|
-
return `${
|
|
6465
|
+
return `${g} bottom-4 right-4 ${e ? "translate-y-0 opacity-100" : "translate-y-full opacity-0"}`;
|
|
6442
6466
|
case "bottom-center":
|
|
6443
6467
|
default:
|
|
6444
|
-
return `${
|
|
6468
|
+
return `${g} bottom-4 left-1/2 -translate-x-1/2 ${e ? "translate-y-0 opacity-100" : "translate-y-full opacity-0"}`;
|
|
6445
6469
|
}
|
|
6446
6470
|
}, u = (v = me[r]) == null ? void 0 : v.filled;
|
|
6447
6471
|
return e ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -6489,87 +6513,79 @@ const Vi = no(function({
|
|
|
6489
6513
|
className: r = "",
|
|
6490
6514
|
...i
|
|
6491
6515
|
}) => {
|
|
6492
|
-
var
|
|
6493
|
-
const l =
|
|
6516
|
+
var u, v;
|
|
6517
|
+
const l = (u = me[t]) == null ? void 0 : u.outline, s = (v = me[t]) == null ? void 0 : v.filled, c = Math.min(Math.max(n, 0), 100);
|
|
6494
6518
|
if (e === "circular") {
|
|
6495
|
-
const { size: d = 40, thickness:
|
|
6496
|
-
return /* @__PURE__ */ a.
|
|
6519
|
+
const { size: d = 40, thickness: g = 4 } = i, x = o ? c / 100 * 360 : 270;
|
|
6520
|
+
return /* @__PURE__ */ a.jsxs(
|
|
6497
6521
|
"div",
|
|
6498
6522
|
{
|
|
6499
|
-
className:
|
|
6523
|
+
className: `relative inline-block ${r}`,
|
|
6500
6524
|
style: { width: d, height: d },
|
|
6501
6525
|
role: "progressbar",
|
|
6502
|
-
"aria-valuenow": o ?
|
|
6526
|
+
"aria-valuenow": o ? c : void 0,
|
|
6503
6527
|
"aria-valuemin": 0,
|
|
6504
6528
|
"aria-valuemax": 100,
|
|
6505
|
-
children:
|
|
6506
|
-
|
|
6507
|
-
|
|
6508
|
-
|
|
6509
|
-
|
|
6510
|
-
|
|
6511
|
-
|
|
6512
|
-
|
|
6513
|
-
|
|
6514
|
-
"
|
|
6515
|
-
|
|
6516
|
-
|
|
6517
|
-
|
|
6518
|
-
|
|
6519
|
-
|
|
6520
|
-
|
|
6521
|
-
|
|
6522
|
-
|
|
6523
|
-
|
|
6524
|
-
|
|
6525
|
-
|
|
6526
|
-
"
|
|
6527
|
-
|
|
6528
|
-
|
|
6529
|
-
|
|
6530
|
-
|
|
6531
|
-
|
|
6532
|
-
|
|
6533
|
-
|
|
6534
|
-
|
|
6535
|
-
|
|
6536
|
-
|
|
6537
|
-
|
|
6538
|
-
strokeDashoffset: o ? E : h * 0.75,
|
|
6539
|
-
transformOrigin: "center"
|
|
6540
|
-
}
|
|
6541
|
-
}
|
|
6542
|
-
)
|
|
6543
|
-
]
|
|
6544
|
-
}
|
|
6545
|
-
)
|
|
6529
|
+
children: [
|
|
6530
|
+
/* @__PURE__ */ a.jsx(
|
|
6531
|
+
"div",
|
|
6532
|
+
{
|
|
6533
|
+
className: "absolute inset-0 rounded-full border-4 border-color-gray-200 dark:border-color-gray-700",
|
|
6534
|
+
style: {
|
|
6535
|
+
borderWidth: g,
|
|
6536
|
+
width: d,
|
|
6537
|
+
height: d,
|
|
6538
|
+
boxSizing: "border-box"
|
|
6539
|
+
}
|
|
6540
|
+
}
|
|
6541
|
+
),
|
|
6542
|
+
/* @__PURE__ */ a.jsx(
|
|
6543
|
+
"div",
|
|
6544
|
+
{
|
|
6545
|
+
className: `absolute inset-0 rounded-full ${l} ${o ? "" : "animate-circular-indeterminate"}`,
|
|
6546
|
+
style: {
|
|
6547
|
+
width: d,
|
|
6548
|
+
height: d,
|
|
6549
|
+
borderWidth: g,
|
|
6550
|
+
borderStyle: "solid",
|
|
6551
|
+
transform: "rotate(-90deg)",
|
|
6552
|
+
borderRadius: "50%",
|
|
6553
|
+
boxSizing: "border-box",
|
|
6554
|
+
transition: "all 0.3s",
|
|
6555
|
+
background: "transparent",
|
|
6556
|
+
maskImage: `conic-gradient(black 0deg, black ${x}deg, transparent ${x}deg 360deg)`,
|
|
6557
|
+
WebkitMaskImage: `conic-gradient(black 0deg, black ${x}deg, transparent ${x}deg 360deg)`
|
|
6558
|
+
}
|
|
6559
|
+
}
|
|
6560
|
+
)
|
|
6561
|
+
]
|
|
6546
6562
|
}
|
|
6547
6563
|
);
|
|
6548
6564
|
}
|
|
6549
|
-
const { thickness:
|
|
6565
|
+
const { thickness: p = 4 } = i;
|
|
6550
6566
|
return /* @__PURE__ */ a.jsx(
|
|
6551
6567
|
"div",
|
|
6552
6568
|
{
|
|
6553
|
-
className:
|
|
6569
|
+
className: `inline-block w-full ${r}`,
|
|
6554
6570
|
role: "progressbar",
|
|
6555
|
-
"aria-valuenow": o ?
|
|
6571
|
+
"aria-valuenow": o ? c : void 0,
|
|
6556
6572
|
"aria-valuemin": 0,
|
|
6557
6573
|
"aria-valuemax": 100,
|
|
6558
6574
|
children: /* @__PURE__ */ a.jsx(
|
|
6559
6575
|
"div",
|
|
6560
6576
|
{
|
|
6561
6577
|
className: "w-full bg-color-gray-200 dark:bg-color-gray-700 rounded-full overflow-hidden relative",
|
|
6562
|
-
style: { height: `${
|
|
6578
|
+
style: { height: `${p}px` },
|
|
6563
6579
|
children: o ? /* @__PURE__ */ a.jsx(
|
|
6564
6580
|
"div",
|
|
6565
6581
|
{
|
|
6566
|
-
className: `h-full ${
|
|
6567
|
-
style: { width: `${
|
|
6582
|
+
className: `h-full ${s} transition-all duration-300 ease-out`,
|
|
6583
|
+
style: { width: `${c}%` }
|
|
6568
6584
|
}
|
|
6569
6585
|
) : /* @__PURE__ */ a.jsx(
|
|
6570
6586
|
"div",
|
|
6571
6587
|
{
|
|
6572
|
-
className: `absolute left-0 top-0 h-full ${
|
|
6588
|
+
className: `absolute left-0 top-0 h-full ${s} animate-progress-indeterminate-gpu`,
|
|
6573
6589
|
style: { width: "40%" }
|
|
6574
6590
|
}
|
|
6575
6591
|
)
|
|
@@ -6594,10 +6610,10 @@ const Vi = no(function({
|
|
|
6594
6610
|
className: p = "",
|
|
6595
6611
|
showHoverValue: u = !1,
|
|
6596
6612
|
showValue: v = !1,
|
|
6597
|
-
labels:
|
|
6613
|
+
labels: d = {}
|
|
6598
6614
|
// <-- Add this
|
|
6599
6615
|
}) => {
|
|
6600
|
-
const [
|
|
6616
|
+
const [g, x] = Ce.useState(null), f = (w, L) => {
|
|
6601
6617
|
if (t || o || !n) return;
|
|
6602
6618
|
const { left: b, width: I } = w.target.getBoundingClientRect(), T = (w.clientX - b) / I;
|
|
6603
6619
|
let H = L - 1 + Math.ceil(T / r) * r;
|
|
@@ -6607,11 +6623,11 @@ const Vi = no(function({
|
|
|
6607
6623
|
const { left: b, width: I } = w.target.getBoundingClientRect(), T = (w.clientX - b) / I;
|
|
6608
6624
|
let H = L - 1 + Math.ceil(T / r) * r;
|
|
6609
6625
|
H = Math.min(i, Math.max(r, Math.round(H / r) * r)), x(H);
|
|
6610
|
-
}, C = () => x(null),
|
|
6626
|
+
}, C = () => x(null), M = [];
|
|
6611
6627
|
for (let w = 1; w <= i; w++) {
|
|
6612
|
-
let L = (
|
|
6628
|
+
let L = (g !== null ? g : e) >= w, b = !L && (g !== null ? g : e) > w - 1, I = L ? s || Ce.cloneElement(hn, { className: `fill-color-yellow-500 ${Xe[l]}` }) : c || Ce.cloneElement(bn, { className: `stroke-color-gray-300 ${Xe[l]}` });
|
|
6613
6629
|
if (b) {
|
|
6614
|
-
const T = ((
|
|
6630
|
+
const T = ((g !== null ? g : e) - (w - 1)) * 100;
|
|
6615
6631
|
I = /* @__PURE__ */ a.jsxs("span", { className: "relative block", children: [
|
|
6616
6632
|
/* @__PURE__ */ a.jsx(
|
|
6617
6633
|
"span",
|
|
@@ -6628,12 +6644,12 @@ const Vi = no(function({
|
|
|
6628
6644
|
})
|
|
6629
6645
|
] });
|
|
6630
6646
|
}
|
|
6631
|
-
|
|
6647
|
+
M.push(
|
|
6632
6648
|
/* @__PURE__ */ a.jsx(
|
|
6633
6649
|
"span",
|
|
6634
6650
|
{
|
|
6635
6651
|
className: `inline-block ${o ? "opacity-50 cursor-not-allowed" : "cursor-pointer"}`,
|
|
6636
|
-
onClick: (T) =>
|
|
6652
|
+
onClick: (T) => f(T, w),
|
|
6637
6653
|
onMouseMove: (T) => h(T, w),
|
|
6638
6654
|
onMouseLeave: C,
|
|
6639
6655
|
tabIndex: t || o ? -1 : 0,
|
|
@@ -6647,8 +6663,8 @@ const Vi = no(function({
|
|
|
6647
6663
|
);
|
|
6648
6664
|
}
|
|
6649
6665
|
return /* @__PURE__ */ a.jsxs("div", { className: `flex items-center gap-1 ${p}`, role: "radiogroup", "aria-disabled": o, children: [
|
|
6650
|
-
|
|
6651
|
-
u &&
|
|
6666
|
+
M,
|
|
6667
|
+
u && g !== null ? /* @__PURE__ */ a.jsx("span", { className: "ml-2 text-xs text-gray-500", children: d[g] || g }) : v ? /* @__PURE__ */ a.jsx("span", { className: "ml-2 text-xs text-gray-500", children: d[e] || e }) : null
|
|
6652
6668
|
] });
|
|
6653
6669
|
}, Gi = ({
|
|
6654
6670
|
children: e,
|
|
@@ -6663,23 +6679,23 @@ const Vi = no(function({
|
|
|
6663
6679
|
gap: p = 0,
|
|
6664
6680
|
onClickItem: u,
|
|
6665
6681
|
showThumbs: v = !1,
|
|
6666
|
-
pauseOnHover:
|
|
6667
|
-
swipeable:
|
|
6682
|
+
pauseOnHover: d = !1,
|
|
6683
|
+
swipeable: g = !0,
|
|
6668
6684
|
thumbWidth: x = 60,
|
|
6669
|
-
orientation:
|
|
6685
|
+
orientation: f = "horizontal",
|
|
6670
6686
|
nextIcon: h,
|
|
6671
6687
|
prevIcon: C,
|
|
6672
|
-
className:
|
|
6688
|
+
className: M
|
|
6673
6689
|
}) => {
|
|
6674
6690
|
const w = e.length, L = Math.min(Math.max(c, 0.1), w), [b, I] = W(0), [T, H] = W(!1), [N, ee] = W(!1), [ie, ce] = W(0), U = le(null), O = le(0), Y = le(0), D = L >= w ? 0 : Math.max(0, w - L), Q = (R) => Math.max(0, Math.min(R, D)), pe = (R) => I(
|
|
6675
6691
|
s && D > 0 ? (R % (D + 1) + (D + 1)) % (D + 1) : Q(R)
|
|
6676
6692
|
), K = () => {
|
|
6677
6693
|
s && D > 0 ? I(b === 0 ? D : b - 1) : pe(b - 1);
|
|
6678
|
-
},
|
|
6694
|
+
}, m = () => {
|
|
6679
6695
|
s && D > 0 ? I(b >= D ? 0 : b + 1) : pe(b + 1);
|
|
6680
6696
|
};
|
|
6681
6697
|
se(() => {
|
|
6682
|
-
if (!i ||
|
|
6698
|
+
if (!i || d && T || N || D === 0)
|
|
6683
6699
|
return;
|
|
6684
6700
|
const R = setInterval(() => {
|
|
6685
6701
|
I(($) => {
|
|
@@ -6692,23 +6708,23 @@ const Vi = no(function({
|
|
|
6692
6708
|
i,
|
|
6693
6709
|
l,
|
|
6694
6710
|
T,
|
|
6695
|
-
|
|
6711
|
+
d,
|
|
6696
6712
|
N,
|
|
6697
6713
|
D,
|
|
6698
6714
|
s
|
|
6699
6715
|
]);
|
|
6700
6716
|
const y = (R, $) => {
|
|
6701
|
-
!
|
|
6702
|
-
},
|
|
6703
|
-
N && (Y.current =
|
|
6717
|
+
!g || D === 0 || (ee(!0), O.current = f === "horizontal" ? R : $, Y.current = O.current);
|
|
6718
|
+
}, E = (R, $) => {
|
|
6719
|
+
N && (Y.current = f === "horizontal" ? R : $, ce(Y.current - O.current));
|
|
6704
6720
|
}, _ = () => {
|
|
6705
6721
|
if (!N) return;
|
|
6706
|
-
Math.abs(Y.current - O.current) > 50 && (Y.current < O.current ?
|
|
6722
|
+
Math.abs(Y.current - O.current) > 50 && (Y.current < O.current ? m() : K()), ee(!1), ce(0);
|
|
6707
6723
|
}, F = () => {
|
|
6708
|
-
const R =
|
|
6724
|
+
const R = f === "horizontal" ? "X" : "Y";
|
|
6709
6725
|
let $ = 0;
|
|
6710
6726
|
if (N && U.current && D > 0) {
|
|
6711
|
-
const X =
|
|
6727
|
+
const X = f === "horizontal" ? U.current.offsetWidth : U.current.offsetHeight;
|
|
6712
6728
|
$ = ie / X * 100 * (L / w);
|
|
6713
6729
|
}
|
|
6714
6730
|
const q = Math.min(b, D) * (100 / w) - $, j = b >= D, k = b <= 0 ? 0 : j ? p / (c / 2) : p / c;
|
|
@@ -6717,36 +6733,36 @@ const Vi = no(function({
|
|
|
6717
6733
|
return /* @__PURE__ */ a.jsxs(
|
|
6718
6734
|
"div",
|
|
6719
6735
|
{
|
|
6720
|
-
className: `relative flex flex-col items-center select-none ${
|
|
6736
|
+
className: `relative flex flex-col items-center select-none ${M}`,
|
|
6721
6737
|
style: { width: n, height: t },
|
|
6722
|
-
onMouseEnter: () =>
|
|
6723
|
-
onMouseLeave: () =>
|
|
6738
|
+
onMouseEnter: () => d && H(!0),
|
|
6739
|
+
onMouseLeave: () => d && H(!1),
|
|
6724
6740
|
children: [
|
|
6725
6741
|
/* @__PURE__ */ a.jsxs(
|
|
6726
6742
|
"div",
|
|
6727
6743
|
{
|
|
6728
6744
|
ref: U,
|
|
6729
|
-
className: `w-full overflow-hidden relative ${
|
|
6745
|
+
className: `w-full overflow-hidden relative ${g && D > 0 ? N ? "cursor-grabbing" : "cursor-grab" : "cursor-default"}`,
|
|
6730
6746
|
style: {
|
|
6731
6747
|
height: v ? `calc(${t} - ${x + 20}px)` : t
|
|
6732
6748
|
},
|
|
6733
6749
|
onMouseDown: (R) => {
|
|
6734
6750
|
R.preventDefault(), y(R.clientX, R.clientY);
|
|
6735
6751
|
},
|
|
6736
|
-
onMouseMove: (R) =>
|
|
6752
|
+
onMouseMove: (R) => E(R.clientX, R.clientY),
|
|
6737
6753
|
onMouseUp: _,
|
|
6738
6754
|
onMouseLeave: _,
|
|
6739
6755
|
onTouchStart: (R) => y(R.touches[0].clientX, R.touches[0].clientY),
|
|
6740
|
-
onTouchMove: (R) =>
|
|
6756
|
+
onTouchMove: (R) => E(R.touches[0].clientX, R.touches[0].clientY),
|
|
6741
6757
|
onTouchEnd: _,
|
|
6742
6758
|
children: [
|
|
6743
6759
|
/* @__PURE__ */ a.jsx(
|
|
6744
6760
|
"div",
|
|
6745
6761
|
{
|
|
6746
|
-
className: `flex ${
|
|
6762
|
+
className: `flex ${f === "horizontal" ? "flex-row" : "flex-col"} transition-transform duration-300 ease-in-out`,
|
|
6747
6763
|
style: {
|
|
6748
|
-
width:
|
|
6749
|
-
height:
|
|
6764
|
+
width: f === "horizontal" ? `${w * 100 / L}%` : "100%",
|
|
6765
|
+
height: f === "vertical" ? `${w * 100 / L}%` : "100%",
|
|
6750
6766
|
transform: F(),
|
|
6751
6767
|
gap: `${p}px`,
|
|
6752
6768
|
transitionProperty: N ? "none" : "transform"
|
|
@@ -6756,8 +6772,8 @@ const Vi = no(function({
|
|
|
6756
6772
|
{
|
|
6757
6773
|
className: "shrink-0 flex items-center justify-center",
|
|
6758
6774
|
style: {
|
|
6759
|
-
width:
|
|
6760
|
-
height:
|
|
6775
|
+
width: f === "horizontal" ? `calc(${100 / w}% - ${p / c}px)` : "100%",
|
|
6776
|
+
height: f === "vertical" ? `calc(${100 / w}% - ${p * (w - 1) / w}px)` : "100%"
|
|
6761
6777
|
},
|
|
6762
6778
|
onClick: () => !N && (u == null ? void 0 : u($)),
|
|
6763
6779
|
children: R
|
|
@@ -6773,25 +6789,25 @@ const Vi = no(function({
|
|
|
6773
6789
|
"aria-label": "prev",
|
|
6774
6790
|
onClick: K,
|
|
6775
6791
|
className: `absolute z-20 bg-color-white/80 border border-color-gray-300 rounded-full w-10 h-10 flex items-center justify-center text-lg font-bold text-color-gray-800 hover:bg-color-white transition-color cursor-pointer
|
|
6776
|
-
${
|
|
6777
|
-
children: C || (
|
|
6792
|
+
${f === "horizontal" ? "left-2 top-1/2 -translate-y-1/2" : "left-1/2 top-2 -translate-x-1/2"}`,
|
|
6793
|
+
children: C || (f === "horizontal" ? "‹" : "↑")
|
|
6778
6794
|
}
|
|
6779
6795
|
),
|
|
6780
6796
|
/* @__PURE__ */ a.jsx(
|
|
6781
6797
|
"button",
|
|
6782
6798
|
{
|
|
6783
6799
|
"aria-label": "next",
|
|
6784
|
-
onClick:
|
|
6800
|
+
onClick: m,
|
|
6785
6801
|
className: `absolute z-20 bg-color-white/80 border border-color-gray-300 rounded-full w-10 h-10 flex items-center justify-center text-lg font-bold text-color-gray-800 hover:bg-color-white transition-colo cursor-pointer
|
|
6786
|
-
${
|
|
6787
|
-
children: h || (
|
|
6802
|
+
${f === "horizontal" ? "right-2 top-1/2 -translate-y-1/2" : "left-1/2 bottom-2 -translate-x-1/2"}`,
|
|
6803
|
+
children: h || (f === "horizontal" ? "›" : "↓")
|
|
6788
6804
|
}
|
|
6789
6805
|
)
|
|
6790
6806
|
] }),
|
|
6791
6807
|
o && z() > 1 && /* @__PURE__ */ a.jsx(
|
|
6792
6808
|
"div",
|
|
6793
6809
|
{
|
|
6794
|
-
className: `flex gap-1 mt-3 justify-center absolute bg-color-white/90 py-1 px-[5px] rounded-full ${
|
|
6810
|
+
className: `flex gap-1 mt-3 justify-center absolute bg-color-white/90 py-1 px-[5px] rounded-full ${f === "horizontal" ? "bottom-3 left-1/2 -translate-x-1/2" : "top-1/2 right-3 -translate-y-1/2 rotate-90"} z-10`,
|
|
6795
6811
|
children: Array.from({ length: z() }).map(
|
|
6796
6812
|
(R, $) => /* @__PURE__ */ a.jsx(
|
|
6797
6813
|
"button",
|
|
@@ -6881,7 +6897,7 @@ const Vi = no(function({
|
|
|
6881
6897
|
variant: i = "ios"
|
|
6882
6898
|
// <-- default to ios
|
|
6883
6899
|
}) => {
|
|
6884
|
-
var v,
|
|
6900
|
+
var v, d, g;
|
|
6885
6901
|
const [l, s] = W(e), [c, p] = W(!1), u = async () => {
|
|
6886
6902
|
if (!(t || c))
|
|
6887
6903
|
if (n) {
|
|
@@ -6909,7 +6925,7 @@ const Vi = no(function({
|
|
|
6909
6925
|
/* @__PURE__ */ a.jsx(
|
|
6910
6926
|
"div",
|
|
6911
6927
|
{
|
|
6912
|
-
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 ${(
|
|
6928
|
+
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 ${(d = me[r]) == null ? void 0 : d.filled}` : "translate-x-0 bg-color-white"}`,
|
|
6913
6929
|
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
|
|
6914
6930
|
}
|
|
6915
6931
|
)
|
|
@@ -6921,7 +6937,7 @@ const Vi = no(function({
|
|
|
6921
6937
|
onClick: u,
|
|
6922
6938
|
type: o,
|
|
6923
6939
|
disabled: t,
|
|
6924
|
-
className: `relative w-11 h-6 flex items-center rounded-full transition-color duration-300 ${l ? (
|
|
6940
|
+
className: `relative w-11 h-6 flex items-center rounded-full transition-color duration-300 ${l ? (g = me[r]) == null ? void 0 : g.filled : "bg-color-gray-300"} ${t ? "bg-color-gray-300 opacity-50 cursor-not-allowed" : "cursor-pointer"}`,
|
|
6925
6941
|
children: /* @__PURE__ */ a.jsx(
|
|
6926
6942
|
"div",
|
|
6927
6943
|
{
|
|
@@ -6947,13 +6963,13 @@ const Vi = no(function({
|
|
|
6947
6963
|
buttonClass: c = "",
|
|
6948
6964
|
disabled: p = !1
|
|
6949
6965
|
}) => {
|
|
6950
|
-
const u = (
|
|
6966
|
+
const u = (d) => Array.isArray(e) ? e.includes(d) : e === d, v = (d) => {
|
|
6951
6967
|
if (!p)
|
|
6952
6968
|
if (o) {
|
|
6953
6969
|
if (!Array.isArray(e)) return;
|
|
6954
|
-
e.includes(
|
|
6970
|
+
e.includes(d) ? n(e.filter((g) => g !== d)) : n([...e, d]);
|
|
6955
6971
|
} else
|
|
6956
|
-
n(
|
|
6972
|
+
n(d);
|
|
6957
6973
|
};
|
|
6958
6974
|
return /* @__PURE__ */ a.jsx(
|
|
6959
6975
|
"div",
|
|
@@ -6961,28 +6977,28 @@ const Vi = no(function({
|
|
|
6961
6977
|
className: `inline-flex ${l === "vertical" ? "flex-col" : "flex-row"} rounded-md overflow-hidden border border-color-gray-200 bg-color-white ${s}`,
|
|
6962
6978
|
role: "group",
|
|
6963
6979
|
"aria-disabled": p,
|
|
6964
|
-
children: t.map((
|
|
6980
|
+
children: t.map((d, g) => {
|
|
6965
6981
|
var x;
|
|
6966
6982
|
return /* @__PURE__ */ a.jsxs(
|
|
6967
6983
|
"button",
|
|
6968
6984
|
{
|
|
6969
6985
|
type: "button",
|
|
6970
|
-
disabled: p ||
|
|
6986
|
+
disabled: p || d.disabled,
|
|
6971
6987
|
className: `
|
|
6972
6988
|
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
|
|
6973
6989
|
${fi[r]}
|
|
6974
|
-
${u(
|
|
6975
|
-
${p ||
|
|
6990
|
+
${u(d.value) ? ((x = me[i]) == null ? void 0 : x.filled) || i : "bg-color-transparent text-color-gray-700"}
|
|
6991
|
+
${p || d.disabled ? "opacity-50 cursor-not-allowed" : "cursor-pointer"}
|
|
6976
6992
|
${c}
|
|
6977
6993
|
`,
|
|
6978
|
-
"aria-pressed": u(
|
|
6979
|
-
onClick: () => !(p ||
|
|
6994
|
+
"aria-pressed": u(d.value),
|
|
6995
|
+
onClick: () => !(p || d.disabled) && v(d.value),
|
|
6980
6996
|
children: [
|
|
6981
|
-
|
|
6982
|
-
|
|
6997
|
+
d.icon,
|
|
6998
|
+
d.label
|
|
6983
6999
|
]
|
|
6984
7000
|
},
|
|
6985
|
-
|
|
7001
|
+
d.value
|
|
6986
7002
|
);
|
|
6987
7003
|
})
|
|
6988
7004
|
}
|
|
@@ -7014,8 +7030,8 @@ const Vi = no(function({
|
|
|
7014
7030
|
className: p = "",
|
|
7015
7031
|
hoverable: u = !1,
|
|
7016
7032
|
bordered: v = !1,
|
|
7017
|
-
onClick:
|
|
7018
|
-
loaderJsx:
|
|
7033
|
+
onClick: d,
|
|
7034
|
+
loaderJsx: g = !1
|
|
7019
7035
|
}) => {
|
|
7020
7036
|
const x = [
|
|
7021
7037
|
"relative",
|
|
@@ -7029,7 +7045,7 @@ const Vi = no(function({
|
|
|
7029
7045
|
v ? "border border-color-gray-200" : "",
|
|
7030
7046
|
p
|
|
7031
7047
|
].join(" ").trim();
|
|
7032
|
-
return /* @__PURE__ */ a.jsxs("div", { className: x, onClick:
|
|
7048
|
+
return /* @__PURE__ */ a.jsxs("div", { className: x, onClick: d, children: [
|
|
7033
7049
|
i && /* @__PURE__ */ a.jsx("img", { src: i, alt: "Card", className: "w-full h-auto mb-4 rounded" }),
|
|
7034
7050
|
(e || n) && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7035
7051
|
/* @__PURE__ */ a.jsxs("div", { className: "flex justify-between items-start mb-2", children: [
|
|
@@ -7042,7 +7058,7 @@ const Vi = no(function({
|
|
|
7042
7058
|
s && /* @__PURE__ */ a.jsx("hr", { className: "h-px my-5 bg-color-gray-200 border-0" })
|
|
7043
7059
|
] }),
|
|
7044
7060
|
/* @__PURE__ */ a.jsx("div", { children: c }),
|
|
7045
|
-
|
|
7061
|
+
g && /* @__PURE__ */ a.jsx("div", { className: "absolute w-full h-full top-0 left-0 flex items-center justify-center bg-color-white bg-opacity-50", children: /* @__PURE__ */ a.jsx(ui, { animation: "wave", className: "!w-full !h-full" }) })
|
|
7046
7062
|
] });
|
|
7047
7063
|
}, Ui = ({
|
|
7048
7064
|
orientation: e = "horizontal",
|
|
@@ -7092,12 +7108,12 @@ const Vi = no(function({
|
|
|
7092
7108
|
className: s = "",
|
|
7093
7109
|
radioClass: c
|
|
7094
7110
|
}) => /* @__PURE__ */ a.jsx("div", { className: `flex ${r === "row" ? "flex-row gap-6" : "flex-col gap-3"} ${s}`, children: n.map(({ label: p, value: u, disabled: v }) => {
|
|
7095
|
-
var
|
|
7096
|
-
const
|
|
7111
|
+
var g, x;
|
|
7112
|
+
const d = i || v;
|
|
7097
7113
|
return /* @__PURE__ */ a.jsxs(
|
|
7098
7114
|
"label",
|
|
7099
7115
|
{
|
|
7100
|
-
className: `relative flex items-center cursor-pointer select-none transition ${
|
|
7116
|
+
className: `relative flex items-center cursor-pointer select-none transition ${d ? "opacity-50 cursor-not-allowed" : "hover:opacity-90"}`,
|
|
7101
7117
|
children: [
|
|
7102
7118
|
/* @__PURE__ */ a.jsx(
|
|
7103
7119
|
"input",
|
|
@@ -7105,16 +7121,16 @@ const Vi = no(function({
|
|
|
7105
7121
|
type: "radio",
|
|
7106
7122
|
name: e,
|
|
7107
7123
|
value: u,
|
|
7108
|
-
disabled:
|
|
7124
|
+
disabled: d,
|
|
7109
7125
|
checked: t === u,
|
|
7110
|
-
onChange: () => !
|
|
7126
|
+
onChange: () => !d && (o == null ? void 0 : o(u)),
|
|
7111
7127
|
className: "sr-only peer"
|
|
7112
7128
|
}
|
|
7113
7129
|
),
|
|
7114
7130
|
/* @__PURE__ */ a.jsx(
|
|
7115
7131
|
"div",
|
|
7116
7132
|
{
|
|
7117
|
-
className: `w-5 h-5 rounded-full border-2 border-color-gray-400 peer-checked:border-[7px] transition-all duration-150 ${(
|
|
7133
|
+
className: `w-5 h-5 rounded-full border-2 border-color-gray-400 peer-checked:border-[7px] transition-all duration-150 ${(g = me[l]) == null ? void 0 : g.peer} ${c}`
|
|
7118
7134
|
}
|
|
7119
7135
|
),
|
|
7120
7136
|
/* @__PURE__ */ a.jsx("span", { className: `ml-2 text-sm text-color-gray-800 ${(x = me[l]) == null ? void 0 : x.peer}`, children: p })
|
|
@@ -7139,11 +7155,11 @@ const Vi = no(function({
|
|
|
7139
7155
|
small: "p-2",
|
|
7140
7156
|
medium: "p-3",
|
|
7141
7157
|
large: "p-4"
|
|
7142
|
-
},
|
|
7158
|
+
}, d = {
|
|
7143
7159
|
small: "rounded-md",
|
|
7144
7160
|
medium: "rounded-lg",
|
|
7145
7161
|
full: "rounded-full"
|
|
7146
|
-
},
|
|
7162
|
+
}, g = {
|
|
7147
7163
|
filled: "bg-color-gray-100 border-color-gray-200",
|
|
7148
7164
|
outlined: "border-color-gray-300 bg-color-transparent"
|
|
7149
7165
|
};
|
|
@@ -7156,7 +7172,7 @@ const Vi = no(function({
|
|
|
7156
7172
|
disabled: l,
|
|
7157
7173
|
value: n,
|
|
7158
7174
|
onChange: (x) => t(x.target.value),
|
|
7159
|
-
className: `appearance-none focus:ring-1 text-color-gray-800 w-full border outline-none transition-all ${
|
|
7175
|
+
className: `appearance-none focus:ring-1 text-color-gray-800 w-full border outline-none transition-all ${d[p]} ${v[s]} ${g[c]} ${l ? "!bg-color-gray-50 opacity-60 cursor-not-allowed" : ""} ${u ? "shadow-md shadow-color-zinc-100" : ""}`,
|
|
7160
7176
|
children: o.map((x) => /* @__PURE__ */ a.jsx("option", { value: x.value, className: "text-color-gray-900", children: x.label }, x.value))
|
|
7161
7177
|
}
|
|
7162
7178
|
),
|
|
@@ -7172,22 +7188,22 @@ const Vi = no(function({
|
|
|
7172
7188
|
return se(() => {
|
|
7173
7189
|
if (o && s.current && c.current) {
|
|
7174
7190
|
const p = s.current.getBoundingClientRect(), u = c.current.getBoundingClientRect();
|
|
7175
|
-
let v = 0,
|
|
7191
|
+
let v = 0, d = 0;
|
|
7176
7192
|
switch (t) {
|
|
7177
7193
|
case "top":
|
|
7178
|
-
v = p.top - u.height - 8,
|
|
7194
|
+
v = p.top - u.height - 8, d = p.left + p.width / 2 - u.width / 2;
|
|
7179
7195
|
break;
|
|
7180
7196
|
case "bottom":
|
|
7181
|
-
v = p.bottom + 8,
|
|
7197
|
+
v = p.bottom + 8, d = p.left + p.width / 2 - u.width / 2;
|
|
7182
7198
|
break;
|
|
7183
7199
|
case "left":
|
|
7184
|
-
v = p.top + p.height / 2 - u.height / 2,
|
|
7200
|
+
v = p.top + p.height / 2 - u.height / 2, d = p.left - u.width - 8;
|
|
7185
7201
|
break;
|
|
7186
7202
|
case "right":
|
|
7187
|
-
v = p.top + p.height / 2 - u.height / 2,
|
|
7203
|
+
v = p.top + p.height / 2 - u.height / 2, d = p.right + 8;
|
|
7188
7204
|
break;
|
|
7189
7205
|
}
|
|
7190
|
-
l({ top: v, left:
|
|
7206
|
+
l({ top: v, left: d });
|
|
7191
7207
|
}
|
|
7192
7208
|
}, [o, t]), /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7193
7209
|
/* @__PURE__ */ a.jsx(
|
|
@@ -7238,35 +7254,35 @@ const vi = {
|
|
|
7238
7254
|
fullWidth: c = !1,
|
|
7239
7255
|
maxWidth: p
|
|
7240
7256
|
}, u) => {
|
|
7241
|
-
const [v,
|
|
7257
|
+
const [v, d] = W(e || !1), [g, x] = W(!1), [f, h] = W(!1);
|
|
7242
7258
|
se(() => {
|
|
7243
|
-
e !== void 0 &&
|
|
7259
|
+
e !== void 0 && d(e);
|
|
7244
7260
|
}, [e]), Sn(u, () => ({
|
|
7245
|
-
open: () =>
|
|
7261
|
+
open: () => d(!0),
|
|
7246
7262
|
close: () => {
|
|
7247
|
-
h(!1), setTimeout(() =>
|
|
7263
|
+
h(!1), setTimeout(() => d(!1), 300);
|
|
7248
7264
|
}
|
|
7249
7265
|
})), se(() => {
|
|
7250
|
-
let
|
|
7251
|
-
return v ? (x(!0),
|
|
7266
|
+
let M;
|
|
7267
|
+
return v ? (x(!0), M = setTimeout(() => h(!0), 10)) : h(!1), () => clearTimeout(M);
|
|
7252
7268
|
}, [v]);
|
|
7253
7269
|
const C = () => {
|
|
7254
7270
|
v || x(!1);
|
|
7255
7271
|
};
|
|
7256
7272
|
return se(() => {
|
|
7257
|
-
const
|
|
7273
|
+
const M = (w) => {
|
|
7258
7274
|
w.key === "Escape" && (n == null || n());
|
|
7259
7275
|
};
|
|
7260
|
-
return v && document.addEventListener("keydown",
|
|
7276
|
+
return v && document.addEventListener("keydown", M), () => document.removeEventListener("keydown", M);
|
|
7261
7277
|
}, [v, n]), se(() => (v ? document.body.style.overflow = "hidden" : document.body.style.overflow = "", () => {
|
|
7262
7278
|
document.body.style.overflow = "";
|
|
7263
|
-
}), [v]),
|
|
7279
|
+
}), [v]), g ? Oe(
|
|
7264
7280
|
/* @__PURE__ */ a.jsxs(
|
|
7265
7281
|
"div",
|
|
7266
7282
|
{
|
|
7267
7283
|
className: xi(
|
|
7268
7284
|
"fixed inset-0 z-50 flex items-center justify-center transition-opacity duration-300",
|
|
7269
|
-
|
|
7285
|
+
f ? "opacity-100" : "opacity-0 pointer-events-none"
|
|
7270
7286
|
),
|
|
7271
7287
|
children: [
|
|
7272
7288
|
/* @__PURE__ */ a.jsx(
|
|
@@ -7274,14 +7290,14 @@ const vi = {
|
|
|
7274
7290
|
{
|
|
7275
7291
|
className: "fixed inset-0 bg-color-black/50",
|
|
7276
7292
|
onClick: () => {
|
|
7277
|
-
n == null || n(),
|
|
7293
|
+
n == null || n(), d(!1);
|
|
7278
7294
|
}
|
|
7279
7295
|
}
|
|
7280
7296
|
),
|
|
7281
7297
|
/* @__PURE__ */ a.jsxs(
|
|
7282
7298
|
"div",
|
|
7283
7299
|
{
|
|
7284
|
-
className: `relative flex flex-col z-50 bg-color-white rounded-xl shadow-lg transition-all duration-300 transform p-6 ${
|
|
7300
|
+
className: `relative flex flex-col z-50 bg-color-white rounded-xl shadow-lg transition-all duration-300 transform p-6 ${f ? "opacity-100 scale-100" : "opacity-0 scale-95"} ${s ? "w-full h-[calc(100%_-_40px)] m-5" : `${c ? "w-full" : "w-auto"} ${p ? vi[p] : ""} mx-5`} ${t}`,
|
|
7285
7301
|
onTransitionEnd: C,
|
|
7286
7302
|
children: [
|
|
7287
7303
|
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center justify-between mb-4", children: [
|
|
@@ -7294,7 +7310,7 @@ const vi = {
|
|
|
7294
7310
|
size: "small",
|
|
7295
7311
|
roundedFull: !0,
|
|
7296
7312
|
onClick: () => {
|
|
7297
|
-
n == null || n(),
|
|
7313
|
+
n == null || n(), d(!1);
|
|
7298
7314
|
},
|
|
7299
7315
|
variant: "transparent"
|
|
7300
7316
|
}
|
|
@@ -7313,27 +7329,27 @@ const vi = {
|
|
|
7313
7329
|
}
|
|
7314
7330
|
);
|
|
7315
7331
|
function Qi({ items: e, trigger: n, className: t, dropdownItemClass: o }) {
|
|
7316
|
-
const [r, i] = W(!1), [l, s] = W({ top: 0, left: 0 }), [c, p] = W(!1), u = le(null), v = le(null),
|
|
7317
|
-
x.stopPropagation(), i((
|
|
7332
|
+
const [r, i] = W(!1), [l, s] = W({ top: 0, left: 0 }), [c, p] = W(!1), u = le(null), v = le(null), d = (x) => {
|
|
7333
|
+
x.stopPropagation(), i((f) => !f), p(!1);
|
|
7318
7334
|
};
|
|
7319
7335
|
oo(() => {
|
|
7320
7336
|
if (r && u.current && v.current) {
|
|
7321
|
-
const x = u.current.getBoundingClientRect(),
|
|
7322
|
-
let
|
|
7323
|
-
x.right +
|
|
7337
|
+
const x = u.current.getBoundingClientRect(), f = v.current.getBoundingClientRect(), h = window.innerWidth, C = window.innerHeight;
|
|
7338
|
+
let M = x.left + window.scrollX, w = x.bottom + window.scrollY;
|
|
7339
|
+
x.right + f.width > h && (M = x.right + window.scrollX - f.width), M + f.width > h && (M = h - f.width - 12), w + f.height > C && (w = x.top + window.scrollY - f.height), s({ top: w, left: M }), setTimeout(() => {
|
|
7324
7340
|
p(!0);
|
|
7325
7341
|
}, 150);
|
|
7326
7342
|
}
|
|
7327
7343
|
}, [r]), se(() => {
|
|
7328
|
-
const x = (
|
|
7344
|
+
const x = (f) => {
|
|
7329
7345
|
var h;
|
|
7330
|
-
v.current && !v.current.contains(
|
|
7346
|
+
v.current && !v.current.contains(f.target) && !((h = u.current) != null && h.contains(f.target)) && i(!1);
|
|
7331
7347
|
};
|
|
7332
7348
|
return r && document.addEventListener("mousedown", x), () => {
|
|
7333
7349
|
document.removeEventListener("mousedown", x);
|
|
7334
7350
|
};
|
|
7335
7351
|
}, [r]);
|
|
7336
|
-
const
|
|
7352
|
+
const g = /* @__PURE__ */ a.jsx(
|
|
7337
7353
|
"div",
|
|
7338
7354
|
{
|
|
7339
7355
|
ref: v,
|
|
@@ -7342,7 +7358,7 @@ function Qi({ items: e, trigger: n, className: t, dropdownItemClass: o }) {
|
|
|
7342
7358
|
top: l.top,
|
|
7343
7359
|
left: l.left
|
|
7344
7360
|
},
|
|
7345
|
-
children: e.map((x,
|
|
7361
|
+
children: e.map((x, f) => /* @__PURE__ */ a.jsxs(
|
|
7346
7362
|
"button",
|
|
7347
7363
|
{
|
|
7348
7364
|
disabled: x.disabled,
|
|
@@ -7356,13 +7372,13 @@ function Qi({ items: e, trigger: n, className: t, dropdownItemClass: o }) {
|
|
|
7356
7372
|
/* @__PURE__ */ a.jsx("span", { children: x.label })
|
|
7357
7373
|
]
|
|
7358
7374
|
},
|
|
7359
|
-
|
|
7375
|
+
f
|
|
7360
7376
|
))
|
|
7361
7377
|
}
|
|
7362
7378
|
);
|
|
7363
7379
|
return /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
7364
|
-
/* @__PURE__ */ a.jsx("div", { ref: u, onClick:
|
|
7365
|
-
r && Oe(
|
|
7380
|
+
/* @__PURE__ */ a.jsx("div", { ref: u, onClick: d, className: "cursor-pointer", children: n }),
|
|
7381
|
+
r && Oe(g, document.body)
|
|
7366
7382
|
] });
|
|
7367
7383
|
}
|
|
7368
7384
|
function bi(...e) {
|
|
@@ -7379,14 +7395,14 @@ const wi = ({
|
|
|
7379
7395
|
showCloseIcon: s = !0,
|
|
7380
7396
|
anchor: c = "left"
|
|
7381
7397
|
}) => {
|
|
7382
|
-
const [p, u] = W(!1), [v,
|
|
7398
|
+
const [p, u] = W(!1), [v, d] = W(!1);
|
|
7383
7399
|
se(() => {
|
|
7384
7400
|
let h;
|
|
7385
7401
|
return e ? (u(!0), h = setTimeout(() => {
|
|
7386
|
-
|
|
7387
|
-
}, 10)) :
|
|
7402
|
+
d(!0);
|
|
7403
|
+
}, 10)) : d(!1), () => clearTimeout(h);
|
|
7388
7404
|
}, [e]);
|
|
7389
|
-
const
|
|
7405
|
+
const g = () => {
|
|
7390
7406
|
e || u(!1);
|
|
7391
7407
|
};
|
|
7392
7408
|
if (se(() => {
|
|
@@ -7402,7 +7418,7 @@ const wi = ({
|
|
|
7402
7418
|
right: "right-0 top-0 h-full min-w-96 transition-all duration-300",
|
|
7403
7419
|
top: "top-0 left-0 w-full min-h-40 transition-all duration-300",
|
|
7404
7420
|
bottom: "bottom-0 left-0 w-full min-h-40 transition-all duration-300"
|
|
7405
|
-
},
|
|
7421
|
+
}, f = {
|
|
7406
7422
|
left: v ? "translate-x-0" : "-translate-x-full",
|
|
7407
7423
|
right: v ? "translate-x-0" : "translate-x-full",
|
|
7408
7424
|
top: v ? "translate-y-0" : "-translate-y-full",
|
|
@@ -7424,10 +7440,10 @@ const wi = ({
|
|
|
7424
7440
|
className: `
|
|
7425
7441
|
fixed bg-color-white shadow-lg z-50 p-6 flex flex-col
|
|
7426
7442
|
${x[c]}
|
|
7427
|
-
${
|
|
7443
|
+
${f[c]}
|
|
7428
7444
|
${t}
|
|
7429
7445
|
`,
|
|
7430
|
-
onTransitionEnd:
|
|
7446
|
+
onTransitionEnd: g,
|
|
7431
7447
|
children: [
|
|
7432
7448
|
s && /* @__PURE__ */ a.jsx(
|
|
7433
7449
|
je,
|
|
@@ -7436,7 +7452,7 @@ const wi = ({
|
|
|
7436
7452
|
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: "M11.9997 10.5865L16.9495 5.63672L18.3637 7.05093L13.4139 12.0007L18.3637 16.9504L16.9495 18.3646L11.9997 13.4149L7.04996 18.3646L5.63574 16.9504L10.5855 12.0007L5.63574 7.05093L7.04996 5.63672L11.9997 10.5865Z" }) }),
|
|
7437
7453
|
size: "small",
|
|
7438
7454
|
roundedFull: !0,
|
|
7439
|
-
className: "!absolute right-3 top-3",
|
|
7455
|
+
className: "!absolute right-3 top-3 z-99",
|
|
7440
7456
|
onClick: n,
|
|
7441
7457
|
variant: "transparent"
|
|
7442
7458
|
}
|
|
@@ -7464,12 +7480,12 @@ const wi = ({
|
|
|
7464
7480
|
titleClass: c = "",
|
|
7465
7481
|
contentClass: p = ""
|
|
7466
7482
|
}) => {
|
|
7467
|
-
const [u, v] = W(i),
|
|
7468
|
-
const
|
|
7469
|
-
|
|
7483
|
+
const [u, v] = W(i), d = r !== void 0, g = d ? r : u, x = () => {
|
|
7484
|
+
const f = !g;
|
|
7485
|
+
d || v(f), l == null || l(f);
|
|
7470
7486
|
};
|
|
7471
7487
|
return se(() => {
|
|
7472
|
-
|
|
7488
|
+
d && v(r);
|
|
7473
7489
|
}, [r]), /* @__PURE__ */ a.jsxs("div", { className: `overflow-hidden w-full border border-color-gray-100 ${s}`, children: [
|
|
7474
7490
|
/* @__PURE__ */ a.jsxs(
|
|
7475
7491
|
"button",
|
|
@@ -7482,13 +7498,13 @@ const wi = ({
|
|
|
7482
7498
|
"div",
|
|
7483
7499
|
{
|
|
7484
7500
|
className: "transition-transform duration-300",
|
|
7485
|
-
children:
|
|
7501
|
+
children: g ? t : o
|
|
7486
7502
|
}
|
|
7487
7503
|
)
|
|
7488
7504
|
]
|
|
7489
7505
|
}
|
|
7490
7506
|
),
|
|
7491
|
-
/* @__PURE__ */ a.jsx("div", { className: `grid overflow-hidden transition-all duration-300 ease-in-out grid-rows-[0fr] ${
|
|
7507
|
+
/* @__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 ${p}`, children: n }) }) })
|
|
7492
7508
|
] });
|
|
7493
7509
|
}, yi = {
|
|
7494
7510
|
info: "bg-color-blue-50 border-color-blue-300 text-color-blue-800",
|
|
@@ -7648,28 +7664,28 @@ const wi = ({
|
|
|
7648
7664
|
disableAfter: p,
|
|
7649
7665
|
selectedDate: u
|
|
7650
7666
|
}) => {
|
|
7651
|
-
const [v,
|
|
7667
|
+
const [v, d] = W(!1), [g, x] = W(null), [f, h] = W(/* @__PURE__ */ new Date()), [C, M] = W(
|
|
7652
7668
|
u ? new Date(u) : null
|
|
7653
7669
|
), [w, L] = W(null), [b, I] = W(null), [T, H] = W(null), [N, ee] = W({ hour: 12, minute: 0, ampm: "AM" }), ie = le(null), [ce, U] = W(
|
|
7654
7670
|
u ? new Date(u) : null
|
|
7655
7671
|
), [O, Y] = W(null), [D, Q] = W(null);
|
|
7656
7672
|
se(() => {
|
|
7657
|
-
|
|
7673
|
+
M(u ? new Date(u) : null), U(u ? new Date(u) : null);
|
|
7658
7674
|
}, [u]);
|
|
7659
7675
|
const pe = (j) => {
|
|
7660
|
-
j.stopPropagation(), x(j.currentTarget),
|
|
7676
|
+
j.stopPropagation(), x(j.currentTarget), d(!0);
|
|
7661
7677
|
}, K = () => {
|
|
7662
|
-
|
|
7663
|
-
},
|
|
7664
|
-
n === "inline" && ie.current && !ie.current.contains(j.target) && (e === "single" ? C ||
|
|
7678
|
+
d(!1);
|
|
7679
|
+
}, m = (j) => !!(c && j.getTime() < c || p && j.getTime() > p), y = (j) => {
|
|
7680
|
+
n === "inline" && ie.current && !ie.current.contains(j.target) && (e === "single" ? C || M(null) : e === "range" && (!w || !b) && (L(null), I(null)), d(!1));
|
|
7665
7681
|
};
|
|
7666
7682
|
se(() => (v ? document.addEventListener("mousedown", y) : document.removeEventListener("mousedown", y), () => {
|
|
7667
7683
|
document.removeEventListener("mousedown", y);
|
|
7668
7684
|
}), [v]);
|
|
7669
|
-
const
|
|
7670
|
-
!j ||
|
|
7685
|
+
const E = (j) => {
|
|
7686
|
+
!j || m(j) || (e === "single" ? M(j) : e === "range" && (!w || w && b ? (L(j), I(null)) : j >= w ? I(j) : L(j)));
|
|
7671
7687
|
}, _ = (j) => {
|
|
7672
|
-
if (!j ||
|
|
7688
|
+
if (!j || m(j)) {
|
|
7673
7689
|
H(null);
|
|
7674
7690
|
return;
|
|
7675
7691
|
}
|
|
@@ -7677,7 +7693,7 @@ const wi = ({
|
|
|
7677
7693
|
}, F = () => {
|
|
7678
7694
|
H(null);
|
|
7679
7695
|
}, z = () => {
|
|
7680
|
-
if (
|
|
7696
|
+
if (d(!1), e === "single") {
|
|
7681
7697
|
const j = o ? /* @__PURE__ */ new Date() : C, S = j ? new Date(
|
|
7682
7698
|
j.getFullYear(),
|
|
7683
7699
|
j.getMonth(),
|
|
@@ -7691,11 +7707,11 @@ const wi = ({
|
|
|
7691
7707
|
endDate: b ? b.getTime() : null
|
|
7692
7708
|
}));
|
|
7693
7709
|
}, A = () => {
|
|
7694
|
-
const j = new Date(
|
|
7710
|
+
const j = new Date(f.getFullYear(), f.getMonth(), 1), S = new Date(f.getFullYear(), f.getMonth() + 1, 0), k = [], X = j.getDay();
|
|
7695
7711
|
for (let J = 0; J < X; J++)
|
|
7696
7712
|
k.push(null);
|
|
7697
7713
|
for (let J = 1; J <= S.getDate(); J++)
|
|
7698
|
-
k.push(new Date(
|
|
7714
|
+
k.push(new Date(f.getFullYear(), f.getMonth(), J));
|
|
7699
7715
|
return k;
|
|
7700
7716
|
}, R = (j) => {
|
|
7701
7717
|
if (!j) return !1;
|
|
@@ -7754,8 +7770,8 @@ const wi = ({
|
|
|
7754
7770
|
className: `${n === "dialog" ? "relative w-full" : "absolute z-50 mt-2 w-72 rounded-lg border border-color-gray-200 bg-color-white shadow-xl p-4"}`,
|
|
7755
7771
|
style: n === "dialog" ? void 0 : {
|
|
7756
7772
|
position: "absolute",
|
|
7757
|
-
left:
|
|
7758
|
-
top:
|
|
7773
|
+
left: g == null ? void 0 : g.getBoundingClientRect().left,
|
|
7774
|
+
top: g ? g.getBoundingClientRect().bottom + window.scrollY : 0
|
|
7759
7775
|
},
|
|
7760
7776
|
children: [
|
|
7761
7777
|
!o && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -7767,7 +7783,7 @@ const wi = ({
|
|
|
7767
7783
|
size: "small",
|
|
7768
7784
|
color: "gray",
|
|
7769
7785
|
roundedFull: !0,
|
|
7770
|
-
onClick: () => h(new Date(
|
|
7786
|
+
onClick: () => h(new Date(f.getFullYear(), f.getMonth() - 1, 1)),
|
|
7771
7787
|
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" }) })
|
|
7772
7788
|
}
|
|
7773
7789
|
),
|
|
@@ -7776,8 +7792,8 @@ const wi = ({
|
|
|
7776
7792
|
"select",
|
|
7777
7793
|
{
|
|
7778
7794
|
className: "text-sm outline-none",
|
|
7779
|
-
value:
|
|
7780
|
-
onChange: (j) => h(new Date(
|
|
7795
|
+
value: f.getMonth(),
|
|
7796
|
+
onChange: (j) => h(new Date(f.getFullYear(), parseInt(j.target.value), 1)),
|
|
7781
7797
|
children: jn.map((j, S) => /* @__PURE__ */ a.jsx("option", { value: S, children: j }, j))
|
|
7782
7798
|
}
|
|
7783
7799
|
),
|
|
@@ -7785,8 +7801,8 @@ const wi = ({
|
|
|
7785
7801
|
"select",
|
|
7786
7802
|
{
|
|
7787
7803
|
className: "text-sm outline-none",
|
|
7788
|
-
value:
|
|
7789
|
-
onChange: (j) => h(new Date(parseInt(j.target.value),
|
|
7804
|
+
value: f.getFullYear(),
|
|
7805
|
+
onChange: (j) => h(new Date(parseInt(j.target.value), f.getMonth(), 1)),
|
|
7790
7806
|
children: Array.from({ length: 150 }, (j, S) => (/* @__PURE__ */ new Date()).getFullYear() - 100 + S).map((j) => /* @__PURE__ */ a.jsx("option", { value: j, children: j }, j))
|
|
7791
7807
|
}
|
|
7792
7808
|
)
|
|
@@ -7798,7 +7814,7 @@ const wi = ({
|
|
|
7798
7814
|
size: "small",
|
|
7799
7815
|
color: "gray",
|
|
7800
7816
|
roundedFull: !0,
|
|
7801
|
-
onClick: () => h(new Date(
|
|
7817
|
+
onClick: () => h(new Date(f.getFullYear(), f.getMonth() + 1, 1)),
|
|
7802
7818
|
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" }) })
|
|
7803
7819
|
}
|
|
7804
7820
|
)
|
|
@@ -7811,8 +7827,8 @@ const wi = ({
|
|
|
7811
7827
|
className: `size-8 flex justify-center items-center text-sm rounded-full transition-all
|
|
7812
7828
|
${j ? "hover:bg-color-blue-100 cursor-pointer" : ""}
|
|
7813
7829
|
${j && R(j) ? "bg-color-blue-500 hover:bg-color-blue-500 text-color-white" : ""}
|
|
7814
|
-
${j &&
|
|
7815
|
-
onClick: () => j &&
|
|
7830
|
+
${j && m(j) ? "bg-color-gray-100 text-color-gray-400 !cursor-not-allowed hover:bg-color-gray-100" : ""}`,
|
|
7831
|
+
onClick: () => j && E(j),
|
|
7816
7832
|
onMouseEnter: () => j && _(j),
|
|
7817
7833
|
onMouseLeave: F,
|
|
7818
7834
|
children: j ? j.getDate() : ""
|