@unizap/uniui 1.0.57 → 1.0.59
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/uniui.js +786 -787
- package/dist/uniui.umd.cjs +42 -42
- package/package.json +91 -94
package/dist/uniui.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
"use client";
|
|
1
2
|
import * as Gt from "react";
|
|
2
|
-
import ke, { useRef as me, useState as ee, useEffect as pe, useMemo as Ae, useReducer as tr, useCallback as
|
|
3
|
+
import ke, { useRef as me, useState as ee, useEffect as pe, useMemo as Ae, useReducer as tr, useCallback as se, forwardRef as Oe, useImperativeHandle as _n, Fragment as nr, memo as rr, useLayoutEffect as or } from "react";
|
|
3
4
|
import { createPortal as Ge } from "react-dom";
|
|
4
5
|
function Mn(e) {
|
|
5
6
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
@@ -52,41 +53,41 @@ function ar() {
|
|
|
52
53
|
function e(x) {
|
|
53
54
|
if (x == null) return null;
|
|
54
55
|
if (typeof x == "function")
|
|
55
|
-
return x.$$typeof ===
|
|
56
|
+
return x.$$typeof === J ? null : x.displayName || x.name || null;
|
|
56
57
|
if (typeof x == "string") return x;
|
|
57
58
|
switch (x) {
|
|
58
|
-
case
|
|
59
|
+
case h:
|
|
59
60
|
return "Fragment";
|
|
60
|
-
case
|
|
61
|
+
case S:
|
|
61
62
|
return "Profiler";
|
|
62
|
-
case
|
|
63
|
+
case w:
|
|
63
64
|
return "StrictMode";
|
|
64
|
-
case b:
|
|
65
|
-
return "Suspense";
|
|
66
65
|
case A:
|
|
66
|
+
return "Suspense";
|
|
67
|
+
case k:
|
|
67
68
|
return "SuspenseList";
|
|
68
|
-
case
|
|
69
|
+
case Z:
|
|
69
70
|
return "Activity";
|
|
70
71
|
}
|
|
71
72
|
if (typeof x == "object")
|
|
72
73
|
switch (typeof x.tag == "number" && console.error(
|
|
73
74
|
"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."
|
|
74
75
|
), x.$$typeof) {
|
|
75
|
-
case
|
|
76
|
+
case g:
|
|
76
77
|
return "Portal";
|
|
78
|
+
case $:
|
|
79
|
+
return x.displayName || "Context";
|
|
77
80
|
case y:
|
|
78
|
-
return (x.displayName || "Context") + ".Provider";
|
|
79
|
-
case S:
|
|
80
81
|
return (x._context.displayName || "Context") + ".Consumer";
|
|
81
|
-
case
|
|
82
|
-
var
|
|
83
|
-
return x = x.displayName, x || (x =
|
|
84
|
-
case
|
|
85
|
-
return
|
|
86
|
-
case
|
|
87
|
-
|
|
82
|
+
case b:
|
|
83
|
+
var R = x.render;
|
|
84
|
+
return x = x.displayName, x || (x = R.displayName || R.name || "", x = x !== "" ? "ForwardRef(" + x + ")" : "ForwardRef"), x;
|
|
85
|
+
case T:
|
|
86
|
+
return R = x.displayName || null, R !== null ? R : e(x.type) || "Memo";
|
|
87
|
+
case K:
|
|
88
|
+
R = x._payload, x = x._init;
|
|
88
89
|
try {
|
|
89
|
-
return e(x(
|
|
90
|
+
return e(x(R));
|
|
90
91
|
} catch {
|
|
91
92
|
}
|
|
92
93
|
}
|
|
@@ -98,71 +99,72 @@ function ar() {
|
|
|
98
99
|
function t(x) {
|
|
99
100
|
try {
|
|
100
101
|
n(x);
|
|
101
|
-
var
|
|
102
|
+
var R = !1;
|
|
102
103
|
} catch {
|
|
103
|
-
|
|
104
|
+
R = !0;
|
|
104
105
|
}
|
|
105
|
-
if (
|
|
106
|
-
|
|
107
|
-
var
|
|
108
|
-
return
|
|
109
|
-
|
|
106
|
+
if (R) {
|
|
107
|
+
R = console;
|
|
108
|
+
var _ = R.error, L = typeof Symbol == "function" && Symbol.toStringTag && x[Symbol.toStringTag] || x.constructor.name || "Object";
|
|
109
|
+
return _.call(
|
|
110
|
+
R,
|
|
110
111
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
111
|
-
|
|
112
|
+
L
|
|
112
113
|
), n(x);
|
|
113
114
|
}
|
|
114
115
|
}
|
|
115
116
|
function r(x) {
|
|
116
|
-
if (x ===
|
|
117
|
-
if (typeof x == "object" && x !== null && x.$$typeof ===
|
|
117
|
+
if (x === h) return "<>";
|
|
118
|
+
if (typeof x == "object" && x !== null && x.$$typeof === K)
|
|
118
119
|
return "<...>";
|
|
119
120
|
try {
|
|
120
|
-
var
|
|
121
|
-
return
|
|
121
|
+
var R = e(x);
|
|
122
|
+
return R ? "<" + R + ">" : "<...>";
|
|
122
123
|
} catch {
|
|
123
124
|
return "<...>";
|
|
124
125
|
}
|
|
125
126
|
}
|
|
126
127
|
function o() {
|
|
127
|
-
var x =
|
|
128
|
+
var x = de.A;
|
|
128
129
|
return x === null ? null : x.getOwner();
|
|
129
130
|
}
|
|
130
131
|
function i() {
|
|
131
132
|
return Error("react-stack-top-frame");
|
|
132
133
|
}
|
|
133
134
|
function l(x) {
|
|
134
|
-
if (
|
|
135
|
-
var
|
|
136
|
-
if (
|
|
135
|
+
if (z.call(x, "key")) {
|
|
136
|
+
var R = Object.getOwnPropertyDescriptor(x, "key").get;
|
|
137
|
+
if (R && R.isReactWarning) return !1;
|
|
137
138
|
}
|
|
138
139
|
return x.key !== void 0;
|
|
139
140
|
}
|
|
140
|
-
function s(x,
|
|
141
|
-
function
|
|
142
|
-
|
|
141
|
+
function s(x, R) {
|
|
142
|
+
function _() {
|
|
143
|
+
Q || (Q = !0, console.error(
|
|
143
144
|
"%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
|
-
|
|
145
|
+
R
|
|
145
146
|
));
|
|
146
147
|
}
|
|
147
|
-
|
|
148
|
-
get:
|
|
148
|
+
_.isReactWarning = !0, Object.defineProperty(x, "key", {
|
|
149
|
+
get: _,
|
|
149
150
|
configurable: !0
|
|
150
151
|
});
|
|
151
152
|
}
|
|
152
153
|
function c() {
|
|
153
154
|
var x = e(this.type);
|
|
154
|
-
return
|
|
155
|
+
return I[x] || (I[x] = !0, console.error(
|
|
155
156
|
"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
157
|
)), x = this.props.ref, x !== void 0 ? x : null;
|
|
157
158
|
}
|
|
158
|
-
function d(x,
|
|
159
|
-
|
|
160
|
-
|
|
159
|
+
function d(x, R, _, L, B, M) {
|
|
160
|
+
var N = _.ref;
|
|
161
|
+
return x = {
|
|
162
|
+
$$typeof: v,
|
|
161
163
|
type: x,
|
|
162
|
-
key:
|
|
163
|
-
props:
|
|
164
|
-
_owner:
|
|
165
|
-
}, (
|
|
164
|
+
key: R,
|
|
165
|
+
props: _,
|
|
166
|
+
_owner: L
|
|
167
|
+
}, (N !== void 0 ? N : null) !== null ? Object.defineProperty(x, "ref", {
|
|
166
168
|
enumerable: !1,
|
|
167
169
|
get: c
|
|
168
170
|
}) : Object.defineProperty(x, "ref", { enumerable: !1, value: null }), x._store = {}, Object.defineProperty(x._store, "validated", {
|
|
@@ -179,102 +181,99 @@ function ar() {
|
|
|
179
181
|
configurable: !1,
|
|
180
182
|
enumerable: !1,
|
|
181
183
|
writable: !0,
|
|
182
|
-
value:
|
|
184
|
+
value: B
|
|
183
185
|
}), Object.defineProperty(x, "_debugTask", {
|
|
184
186
|
configurable: !1,
|
|
185
187
|
enumerable: !1,
|
|
186
188
|
writable: !0,
|
|
187
|
-
value:
|
|
189
|
+
value: M
|
|
188
190
|
}), Object.freeze && (Object.freeze(x.props), Object.freeze(x)), x;
|
|
189
191
|
}
|
|
190
|
-
function p(x,
|
|
191
|
-
var N =
|
|
192
|
+
function p(x, R, _, L, B, M) {
|
|
193
|
+
var N = R.children;
|
|
192
194
|
if (N !== void 0)
|
|
193
|
-
if (
|
|
194
|
-
if (
|
|
195
|
-
for (
|
|
196
|
-
m(N[
|
|
195
|
+
if (L)
|
|
196
|
+
if (O(N)) {
|
|
197
|
+
for (L = 0; L < N.length; L++)
|
|
198
|
+
m(N[L]);
|
|
197
199
|
Object.freeze && Object.freeze(N);
|
|
198
200
|
} else
|
|
199
201
|
console.error(
|
|
200
202
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
201
203
|
);
|
|
202
204
|
else m(N);
|
|
203
|
-
if (
|
|
205
|
+
if (z.call(R, "key")) {
|
|
204
206
|
N = e(x);
|
|
205
|
-
var
|
|
206
|
-
return
|
|
207
|
+
var H = Object.keys(R).filter(function(X) {
|
|
208
|
+
return X !== "key";
|
|
207
209
|
});
|
|
208
|
-
|
|
210
|
+
L = 0 < H.length ? "{key: someKey, " + H.join(": ..., ") + ": ...}" : "{key: someKey}", j[N + L] || (H = 0 < H.length ? "{" + H.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
209
211
|
`A props object containing a "key" prop is being spread into JSX:
|
|
210
212
|
let props = %s;
|
|
211
213
|
<%s {...props} />
|
|
212
214
|
React keys must be passed directly to JSX without using spread:
|
|
213
215
|
let props = %s;
|
|
214
216
|
<%s key={someKey} {...props} />`,
|
|
215
|
-
|
|
217
|
+
L,
|
|
216
218
|
N,
|
|
217
|
-
|
|
219
|
+
H,
|
|
218
220
|
N
|
|
219
|
-
),
|
|
221
|
+
), j[N + L] = !0);
|
|
220
222
|
}
|
|
221
|
-
if (N = null,
|
|
222
|
-
|
|
223
|
-
for (var
|
|
224
|
-
|
|
225
|
-
} else
|
|
223
|
+
if (N = null, _ !== void 0 && (t(_), N = "" + _), l(R) && (t(R.key), N = "" + R.key), "key" in R) {
|
|
224
|
+
_ = {};
|
|
225
|
+
for (var U in R)
|
|
226
|
+
U !== "key" && (_[U] = R[U]);
|
|
227
|
+
} else _ = R;
|
|
226
228
|
return N && s(
|
|
227
|
-
|
|
229
|
+
_,
|
|
228
230
|
typeof x == "function" ? x.displayName || x.name || "Unknown" : x
|
|
229
231
|
), d(
|
|
230
232
|
x,
|
|
231
233
|
N,
|
|
232
|
-
|
|
233
|
-
P,
|
|
234
|
+
_,
|
|
234
235
|
o(),
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
B
|
|
236
|
+
B,
|
|
237
|
+
M
|
|
238
238
|
);
|
|
239
239
|
}
|
|
240
240
|
function m(x) {
|
|
241
|
-
typeof x == "object" && x !== null && x.$$typeof ===
|
|
241
|
+
u(x) ? x._store && (x._store.validated = 1) : typeof x == "object" && x !== null && x.$$typeof === K && (x._payload.status === "fulfilled" ? u(x._payload.value) && x._payload.value._store && (x._payload.value._store.validated = 1) : x._store && (x._store.validated = 1));
|
|
242
|
+
}
|
|
243
|
+
function u(x) {
|
|
244
|
+
return typeof x == "object" && x !== null && x.$$typeof === v;
|
|
242
245
|
}
|
|
243
|
-
var
|
|
246
|
+
var f = ke, v = Symbol.for("react.transitional.element"), g = Symbol.for("react.portal"), h = Symbol.for("react.fragment"), w = Symbol.for("react.strict_mode"), S = Symbol.for("react.profiler"), y = Symbol.for("react.consumer"), $ = Symbol.for("react.context"), b = Symbol.for("react.forward_ref"), A = Symbol.for("react.suspense"), k = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), K = Symbol.for("react.lazy"), Z = Symbol.for("react.activity"), J = Symbol.for("react.client.reference"), de = f.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, z = Object.prototype.hasOwnProperty, O = Array.isArray, V = console.createTask ? console.createTask : function() {
|
|
244
247
|
return null;
|
|
245
248
|
};
|
|
246
|
-
|
|
247
|
-
|
|
249
|
+
f = {
|
|
250
|
+
react_stack_bottom_frame: function(x) {
|
|
248
251
|
return x();
|
|
249
252
|
}
|
|
250
253
|
};
|
|
251
|
-
var
|
|
252
|
-
|
|
254
|
+
var Q, I = {}, ve = f.react_stack_bottom_frame.bind(
|
|
255
|
+
f,
|
|
253
256
|
i
|
|
254
|
-
)(),
|
|
255
|
-
Ve.Fragment =
|
|
256
|
-
var
|
|
257
|
+
)(), W = V(r(i)), j = {};
|
|
258
|
+
Ve.Fragment = h, Ve.jsx = function(x, R, _) {
|
|
259
|
+
var L = 1e4 > de.recentlyCreatedOwnerStacks++;
|
|
257
260
|
return p(
|
|
258
261
|
x,
|
|
259
|
-
|
|
260
|
-
|
|
262
|
+
R,
|
|
263
|
+
_,
|
|
261
264
|
!1,
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
T ? Error("react-stack-top-frame") : V,
|
|
265
|
-
T ? z(r(x)) : ve
|
|
265
|
+
L ? Error("react-stack-top-frame") : ve,
|
|
266
|
+
L ? V(r(x)) : W
|
|
266
267
|
);
|
|
267
|
-
}, Ve.jsxs = function(x,
|
|
268
|
-
var
|
|
268
|
+
}, Ve.jsxs = function(x, R, _) {
|
|
269
|
+
var L = 1e4 > de.recentlyCreatedOwnerStacks++;
|
|
269
270
|
return p(
|
|
270
271
|
x,
|
|
271
|
-
|
|
272
|
-
|
|
272
|
+
R,
|
|
273
|
+
_,
|
|
273
274
|
!0,
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
T ? Error("react-stack-top-frame") : V,
|
|
277
|
-
T ? z(r(x)) : ve
|
|
275
|
+
L ? Error("react-stack-top-frame") : ve,
|
|
276
|
+
L ? V(r(x)) : W
|
|
278
277
|
);
|
|
279
278
|
};
|
|
280
279
|
}()), Ve;
|
|
@@ -626,11 +625,11 @@ const we = {
|
|
|
626
625
|
...w
|
|
627
626
|
}) => {
|
|
628
627
|
var A;
|
|
629
|
-
const S = me(null), y = me(null), $ = (
|
|
630
|
-
const
|
|
631
|
-
if (!
|
|
632
|
-
const
|
|
633
|
-
|
|
628
|
+
const S = me(null), y = me(null), $ = (k) => {
|
|
629
|
+
const T = S.current;
|
|
630
|
+
if (!T) return;
|
|
631
|
+
const K = document.createElement("span"), Z = T.getBoundingClientRect(), J = Math.max(Z.width, Z.height);
|
|
632
|
+
K.style.width = K.style.height = `${J}px`, K.style.left = `${k.clientX - Z.left - J / 2}px`, K.style.top = `${k.clientY - Z.top - J / 2}px`, K.className = "ripple", T.appendChild(K), setTimeout(() => K.remove(), 600), l == null || l(k);
|
|
634
633
|
}, b = ((A = we[r]) == null ? void 0 : A[t === "filled" ? "filled" : t === "outlined" ? "outline" : "transparent"]) || "";
|
|
635
634
|
return /* @__PURE__ */ a.jsx(a.Fragment, { children: v ? /* @__PURE__ */ a.jsxs(
|
|
636
635
|
"a",
|
|
@@ -879,16 +878,16 @@ var Xt;
|
|
|
879
878
|
function cr() {
|
|
880
879
|
return Xt || (Xt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
881
880
|
var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, t = e ? Symbol.for("react.portal") : 60106, r = e ? Symbol.for("react.fragment") : 60107, o = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, l = e ? Symbol.for("react.provider") : 60109, s = e ? Symbol.for("react.context") : 60110, c = e ? Symbol.for("react.async_mode") : 60111, d = e ? Symbol.for("react.concurrent_mode") : 60111, p = e ? Symbol.for("react.forward_ref") : 60112, m = e ? Symbol.for("react.suspense") : 60113, u = e ? Symbol.for("react.suspense_list") : 60120, f = e ? Symbol.for("react.memo") : 60115, v = e ? Symbol.for("react.lazy") : 60116, g = e ? Symbol.for("react.block") : 60121, h = e ? Symbol.for("react.fundamental") : 60117, w = e ? Symbol.for("react.responder") : 60118, S = e ? Symbol.for("react.scope") : 60119;
|
|
882
|
-
function y(
|
|
883
|
-
return typeof
|
|
884
|
-
|
|
881
|
+
function y(E) {
|
|
882
|
+
return typeof E == "string" || typeof E == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
883
|
+
E === r || E === d || E === i || E === o || E === m || E === u || typeof E == "object" && E !== null && (E.$$typeof === v || E.$$typeof === f || E.$$typeof === l || E.$$typeof === s || E.$$typeof === p || E.$$typeof === h || E.$$typeof === w || E.$$typeof === S || E.$$typeof === g);
|
|
885
884
|
}
|
|
886
|
-
function $(
|
|
887
|
-
if (typeof
|
|
888
|
-
var
|
|
889
|
-
switch (
|
|
885
|
+
function $(E) {
|
|
886
|
+
if (typeof E == "object" && E !== null) {
|
|
887
|
+
var P = E.$$typeof;
|
|
888
|
+
switch (P) {
|
|
890
889
|
case n:
|
|
891
|
-
var re =
|
|
890
|
+
var re = E.type;
|
|
892
891
|
switch (re) {
|
|
893
892
|
case c:
|
|
894
893
|
case d:
|
|
@@ -907,55 +906,55 @@ function cr() {
|
|
|
907
906
|
case l:
|
|
908
907
|
return oe;
|
|
909
908
|
default:
|
|
910
|
-
return
|
|
909
|
+
return P;
|
|
911
910
|
}
|
|
912
911
|
}
|
|
913
912
|
case t:
|
|
914
|
-
return
|
|
913
|
+
return P;
|
|
915
914
|
}
|
|
916
915
|
}
|
|
917
916
|
}
|
|
918
|
-
var b = c, A = d,
|
|
919
|
-
function
|
|
920
|
-
return ve || (ve = !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
|
+
var b = c, A = d, k = s, T = l, K = n, Z = p, J = r, de = v, z = f, O = t, V = i, Q = o, I = m, ve = !1;
|
|
918
|
+
function W(E) {
|
|
919
|
+
return ve || (ve = !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.")), j(E) || $(E) === c;
|
|
921
920
|
}
|
|
922
|
-
function
|
|
923
|
-
return $(
|
|
921
|
+
function j(E) {
|
|
922
|
+
return $(E) === d;
|
|
924
923
|
}
|
|
925
|
-
function
|
|
926
|
-
return $(
|
|
924
|
+
function x(E) {
|
|
925
|
+
return $(E) === s;
|
|
927
926
|
}
|
|
928
|
-
function
|
|
929
|
-
return $(
|
|
927
|
+
function R(E) {
|
|
928
|
+
return $(E) === l;
|
|
930
929
|
}
|
|
931
|
-
function E
|
|
932
|
-
return typeof
|
|
930
|
+
function _(E) {
|
|
931
|
+
return typeof E == "object" && E !== null && E.$$typeof === n;
|
|
933
932
|
}
|
|
934
|
-
function
|
|
935
|
-
return $(
|
|
933
|
+
function L(E) {
|
|
934
|
+
return $(E) === p;
|
|
936
935
|
}
|
|
937
|
-
function
|
|
938
|
-
return $(
|
|
936
|
+
function B(E) {
|
|
937
|
+
return $(E) === r;
|
|
939
938
|
}
|
|
940
|
-
function
|
|
941
|
-
return $(
|
|
939
|
+
function M(E) {
|
|
940
|
+
return $(E) === v;
|
|
942
941
|
}
|
|
943
|
-
function
|
|
944
|
-
return $(
|
|
942
|
+
function N(E) {
|
|
943
|
+
return $(E) === f;
|
|
945
944
|
}
|
|
946
|
-
function
|
|
947
|
-
return $(
|
|
945
|
+
function H(E) {
|
|
946
|
+
return $(E) === t;
|
|
948
947
|
}
|
|
949
|
-
function
|
|
950
|
-
return $(
|
|
948
|
+
function U(E) {
|
|
949
|
+
return $(E) === i;
|
|
951
950
|
}
|
|
952
|
-
function
|
|
953
|
-
return $(
|
|
951
|
+
function X(E) {
|
|
952
|
+
return $(E) === o;
|
|
954
953
|
}
|
|
955
|
-
function
|
|
956
|
-
return $(
|
|
954
|
+
function ce(E) {
|
|
955
|
+
return $(E) === m;
|
|
957
956
|
}
|
|
958
|
-
le.AsyncMode = b, le.ConcurrentMode = A, le.ContextConsumer =
|
|
957
|
+
le.AsyncMode = b, le.ConcurrentMode = A, le.ContextConsumer = k, le.ContextProvider = T, le.Element = K, le.ForwardRef = Z, le.Fragment = J, le.Lazy = de, le.Memo = z, le.Portal = O, le.Profiler = V, le.StrictMode = Q, le.Suspense = I, le.isAsyncMode = W, le.isConcurrentMode = j, le.isContextConsumer = x, le.isContextProvider = R, le.isElement = _, le.isForwardRef = L, le.isFragment = B, le.isLazy = M, le.isMemo = N, le.isPortal = H, le.isProfiler = U, le.isStrictMode = X, le.isSuspense = ce, le.isValidElementType = y, le.typeOf = $;
|
|
959
958
|
}()), le;
|
|
960
959
|
}
|
|
961
960
|
var Kt;
|
|
@@ -1092,10 +1091,10 @@ function dr() {
|
|
|
1092
1091
|
}
|
|
1093
1092
|
return vt = function(s, c) {
|
|
1094
1093
|
var d = typeof Symbol == "function" && Symbol.iterator, p = "@@iterator";
|
|
1095
|
-
function m(
|
|
1096
|
-
var
|
|
1097
|
-
if (typeof
|
|
1098
|
-
return
|
|
1094
|
+
function m(j) {
|
|
1095
|
+
var x = j && (d && j[d] || j[p]);
|
|
1096
|
+
if (typeof x == "function")
|
|
1097
|
+
return x;
|
|
1099
1098
|
}
|
|
1100
1099
|
var u = "<<anonymous>>", f = {
|
|
1101
1100
|
array: w("array"),
|
|
@@ -1111,241 +1110,241 @@ function dr() {
|
|
|
1111
1110
|
element: $(),
|
|
1112
1111
|
elementType: b(),
|
|
1113
1112
|
instanceOf: A,
|
|
1114
|
-
node:
|
|
1115
|
-
objectOf:
|
|
1116
|
-
oneOf:
|
|
1117
|
-
oneOfType:
|
|
1113
|
+
node: Z(),
|
|
1114
|
+
objectOf: T,
|
|
1115
|
+
oneOf: k,
|
|
1116
|
+
oneOfType: K,
|
|
1118
1117
|
shape: de,
|
|
1119
|
-
exact:
|
|
1118
|
+
exact: z
|
|
1120
1119
|
};
|
|
1121
|
-
function v(
|
|
1122
|
-
return
|
|
1120
|
+
function v(j, x) {
|
|
1121
|
+
return j === x ? j !== 0 || 1 / j === 1 / x : j !== j && x !== x;
|
|
1123
1122
|
}
|
|
1124
|
-
function g(
|
|
1125
|
-
this.message =
|
|
1123
|
+
function g(j, x) {
|
|
1124
|
+
this.message = j, this.data = x && typeof x == "object" ? x : {}, this.stack = "";
|
|
1126
1125
|
}
|
|
1127
1126
|
g.prototype = Error.prototype;
|
|
1128
|
-
function h(
|
|
1127
|
+
function h(j) {
|
|
1129
1128
|
if (process.env.NODE_ENV !== "production")
|
|
1130
|
-
var
|
|
1131
|
-
function
|
|
1132
|
-
if (
|
|
1129
|
+
var x = {}, R = 0;
|
|
1130
|
+
function _(B, M, N, H, U, X, ce) {
|
|
1131
|
+
if (H = H || u, X = X || N, ce !== t) {
|
|
1133
1132
|
if (c) {
|
|
1134
|
-
var
|
|
1133
|
+
var E = new Error(
|
|
1135
1134
|
"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"
|
|
1136
1135
|
);
|
|
1137
|
-
throw
|
|
1136
|
+
throw E.name = "Invariant Violation", E;
|
|
1138
1137
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
1139
|
-
var
|
|
1140
|
-
!
|
|
1141
|
-
|
|
1142
|
-
"You are manually calling a React.PropTypes validation function for the `" +
|
|
1143
|
-
),
|
|
1138
|
+
var P = H + ":" + N;
|
|
1139
|
+
!x[P] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
1140
|
+
R < 3 && (i(
|
|
1141
|
+
"You are manually calling a React.PropTypes validation function for the `" + X + "` prop on `" + H + "`. 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."
|
|
1142
|
+
), x[P] = !0, R++);
|
|
1144
1143
|
}
|
|
1145
1144
|
}
|
|
1146
|
-
return
|
|
1145
|
+
return M[N] == null ? B ? M[N] === null ? new g("The " + U + " `" + X + "` is marked as required " + ("in `" + H + "`, but its value is `null`.")) : new g("The " + U + " `" + X + "` is marked as required in " + ("`" + H + "`, but its value is `undefined`.")) : null : j(M, N, H, U, X);
|
|
1147
1146
|
}
|
|
1148
|
-
var
|
|
1149
|
-
return
|
|
1147
|
+
var L = _.bind(null, !1);
|
|
1148
|
+
return L.isRequired = _.bind(null, !0), L;
|
|
1150
1149
|
}
|
|
1151
|
-
function w(
|
|
1152
|
-
function
|
|
1153
|
-
var
|
|
1154
|
-
if (
|
|
1155
|
-
var
|
|
1150
|
+
function w(j) {
|
|
1151
|
+
function x(R, _, L, B, M, N) {
|
|
1152
|
+
var H = R[_], U = Q(H);
|
|
1153
|
+
if (U !== j) {
|
|
1154
|
+
var X = I(H);
|
|
1156
1155
|
return new g(
|
|
1157
|
-
"Invalid " +
|
|
1158
|
-
{ expectedType:
|
|
1156
|
+
"Invalid " + B + " `" + M + "` of type " + ("`" + X + "` supplied to `" + L + "`, expected ") + ("`" + j + "`."),
|
|
1157
|
+
{ expectedType: j }
|
|
1159
1158
|
);
|
|
1160
1159
|
}
|
|
1161
1160
|
return null;
|
|
1162
1161
|
}
|
|
1163
|
-
return h(
|
|
1162
|
+
return h(x);
|
|
1164
1163
|
}
|
|
1165
1164
|
function S() {
|
|
1166
1165
|
return h(l);
|
|
1167
1166
|
}
|
|
1168
|
-
function y(
|
|
1169
|
-
function
|
|
1170
|
-
if (typeof
|
|
1171
|
-
return new g("Property `" +
|
|
1172
|
-
var
|
|
1173
|
-
if (!Array.isArray(
|
|
1174
|
-
var
|
|
1175
|
-
return new g("Invalid " +
|
|
1167
|
+
function y(j) {
|
|
1168
|
+
function x(R, _, L, B, M) {
|
|
1169
|
+
if (typeof j != "function")
|
|
1170
|
+
return new g("Property `" + M + "` of component `" + L + "` has invalid PropType notation inside arrayOf.");
|
|
1171
|
+
var N = R[_];
|
|
1172
|
+
if (!Array.isArray(N)) {
|
|
1173
|
+
var H = Q(N);
|
|
1174
|
+
return new g("Invalid " + B + " `" + M + "` of type " + ("`" + H + "` supplied to `" + L + "`, expected an array."));
|
|
1176
1175
|
}
|
|
1177
|
-
for (var
|
|
1178
|
-
var
|
|
1179
|
-
if (
|
|
1180
|
-
return
|
|
1176
|
+
for (var U = 0; U < N.length; U++) {
|
|
1177
|
+
var X = j(N, U, L, B, M + "[" + U + "]", t);
|
|
1178
|
+
if (X instanceof Error)
|
|
1179
|
+
return X;
|
|
1181
1180
|
}
|
|
1182
1181
|
return null;
|
|
1183
1182
|
}
|
|
1184
|
-
return h(
|
|
1183
|
+
return h(x);
|
|
1185
1184
|
}
|
|
1186
1185
|
function $() {
|
|
1187
|
-
function x
|
|
1188
|
-
var
|
|
1189
|
-
if (!s(
|
|
1190
|
-
var
|
|
1191
|
-
return new g("Invalid " +
|
|
1186
|
+
function j(x, R, _, L, B) {
|
|
1187
|
+
var M = x[R];
|
|
1188
|
+
if (!s(M)) {
|
|
1189
|
+
var N = Q(M);
|
|
1190
|
+
return new g("Invalid " + L + " `" + B + "` of type " + ("`" + N + "` supplied to `" + _ + "`, expected a single ReactElement."));
|
|
1192
1191
|
}
|
|
1193
1192
|
return null;
|
|
1194
1193
|
}
|
|
1195
|
-
return h(
|
|
1194
|
+
return h(j);
|
|
1196
1195
|
}
|
|
1197
1196
|
function b() {
|
|
1198
|
-
function x
|
|
1199
|
-
var
|
|
1200
|
-
if (!e.isValidElementType(
|
|
1201
|
-
var
|
|
1202
|
-
return new g("Invalid " +
|
|
1197
|
+
function j(x, R, _, L, B) {
|
|
1198
|
+
var M = x[R];
|
|
1199
|
+
if (!e.isValidElementType(M)) {
|
|
1200
|
+
var N = Q(M);
|
|
1201
|
+
return new g("Invalid " + L + " `" + B + "` of type " + ("`" + N + "` supplied to `" + _ + "`, expected a single ReactElement type."));
|
|
1203
1202
|
}
|
|
1204
1203
|
return null;
|
|
1205
1204
|
}
|
|
1206
|
-
return h(
|
|
1205
|
+
return h(j);
|
|
1207
1206
|
}
|
|
1208
|
-
function A(
|
|
1209
|
-
function
|
|
1210
|
-
if (!(
|
|
1211
|
-
var
|
|
1212
|
-
return new g("Invalid " +
|
|
1207
|
+
function A(j) {
|
|
1208
|
+
function x(R, _, L, B, M) {
|
|
1209
|
+
if (!(R[_] instanceof j)) {
|
|
1210
|
+
var N = j.name || u, H = W(R[_]);
|
|
1211
|
+
return new g("Invalid " + B + " `" + M + "` of type " + ("`" + H + "` supplied to `" + L + "`, expected ") + ("instance of `" + N + "`."));
|
|
1213
1212
|
}
|
|
1214
1213
|
return null;
|
|
1215
1214
|
}
|
|
1216
|
-
return h(
|
|
1215
|
+
return h(x);
|
|
1217
1216
|
}
|
|
1218
|
-
function
|
|
1219
|
-
if (!Array.isArray(
|
|
1217
|
+
function k(j) {
|
|
1218
|
+
if (!Array.isArray(j))
|
|
1220
1219
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
|
|
1221
1220
|
"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])."
|
|
1222
1221
|
) : i("Invalid argument supplied to oneOf, expected an array.")), l;
|
|
1223
|
-
function
|
|
1224
|
-
for (var
|
|
1225
|
-
if (v(
|
|
1222
|
+
function x(R, _, L, B, M) {
|
|
1223
|
+
for (var N = R[_], H = 0; H < j.length; H++)
|
|
1224
|
+
if (v(N, j[H]))
|
|
1226
1225
|
return null;
|
|
1227
|
-
var
|
|
1228
|
-
var
|
|
1229
|
-
return
|
|
1226
|
+
var U = JSON.stringify(j, function(ce, E) {
|
|
1227
|
+
var P = I(E);
|
|
1228
|
+
return P === "symbol" ? String(E) : E;
|
|
1230
1229
|
});
|
|
1231
|
-
return new g("Invalid " +
|
|
1230
|
+
return new g("Invalid " + B + " `" + M + "` of value `" + String(N) + "` " + ("supplied to `" + L + "`, expected one of " + U + "."));
|
|
1232
1231
|
}
|
|
1233
|
-
return h(
|
|
1232
|
+
return h(x);
|
|
1234
1233
|
}
|
|
1235
|
-
function
|
|
1236
|
-
function
|
|
1237
|
-
if (typeof
|
|
1238
|
-
return new g("Property `" +
|
|
1239
|
-
var
|
|
1240
|
-
if (
|
|
1241
|
-
return new g("Invalid " +
|
|
1242
|
-
for (var
|
|
1243
|
-
if (r(
|
|
1244
|
-
var
|
|
1245
|
-
if (
|
|
1246
|
-
return
|
|
1234
|
+
function T(j) {
|
|
1235
|
+
function x(R, _, L, B, M) {
|
|
1236
|
+
if (typeof j != "function")
|
|
1237
|
+
return new g("Property `" + M + "` of component `" + L + "` has invalid PropType notation inside objectOf.");
|
|
1238
|
+
var N = R[_], H = Q(N);
|
|
1239
|
+
if (H !== "object")
|
|
1240
|
+
return new g("Invalid " + B + " `" + M + "` of type " + ("`" + H + "` supplied to `" + L + "`, expected an object."));
|
|
1241
|
+
for (var U in N)
|
|
1242
|
+
if (r(N, U)) {
|
|
1243
|
+
var X = j(N, U, L, B, M + "." + U, t);
|
|
1244
|
+
if (X instanceof Error)
|
|
1245
|
+
return X;
|
|
1247
1246
|
}
|
|
1248
1247
|
return null;
|
|
1249
1248
|
}
|
|
1250
|
-
return h(
|
|
1249
|
+
return h(x);
|
|
1251
1250
|
}
|
|
1252
|
-
function
|
|
1253
|
-
if (!Array.isArray(
|
|
1251
|
+
function K(j) {
|
|
1252
|
+
if (!Array.isArray(j))
|
|
1254
1253
|
return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), l;
|
|
1255
|
-
for (var
|
|
1256
|
-
var
|
|
1257
|
-
if (typeof
|
|
1254
|
+
for (var x = 0; x < j.length; x++) {
|
|
1255
|
+
var R = j[x];
|
|
1256
|
+
if (typeof R != "function")
|
|
1258
1257
|
return i(
|
|
1259
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ve(
|
|
1258
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ve(R) + " at index " + x + "."
|
|
1260
1259
|
), l;
|
|
1261
1260
|
}
|
|
1262
|
-
function
|
|
1263
|
-
for (var
|
|
1264
|
-
var
|
|
1265
|
-
if (
|
|
1261
|
+
function _(L, B, M, N, H) {
|
|
1262
|
+
for (var U = [], X = 0; X < j.length; X++) {
|
|
1263
|
+
var ce = j[X], E = ce(L, B, M, N, H, t);
|
|
1264
|
+
if (E == null)
|
|
1266
1265
|
return null;
|
|
1267
|
-
|
|
1266
|
+
E.data && r(E.data, "expectedType") && U.push(E.data.expectedType);
|
|
1268
1267
|
}
|
|
1269
|
-
var
|
|
1270
|
-
return new g("Invalid " +
|
|
1268
|
+
var P = U.length > 0 ? ", expected one of type [" + U.join(", ") + "]" : "";
|
|
1269
|
+
return new g("Invalid " + N + " `" + H + "` supplied to " + ("`" + M + "`" + P + "."));
|
|
1271
1270
|
}
|
|
1272
|
-
return h(
|
|
1271
|
+
return h(_);
|
|
1273
1272
|
}
|
|
1274
|
-
function
|
|
1275
|
-
function x
|
|
1276
|
-
return
|
|
1273
|
+
function Z() {
|
|
1274
|
+
function j(x, R, _, L, B) {
|
|
1275
|
+
return O(x[R]) ? null : new g("Invalid " + L + " `" + B + "` supplied to " + ("`" + _ + "`, expected a ReactNode."));
|
|
1277
1276
|
}
|
|
1278
|
-
return h(
|
|
1277
|
+
return h(j);
|
|
1279
1278
|
}
|
|
1280
|
-
function
|
|
1279
|
+
function J(j, x, R, _, L) {
|
|
1281
1280
|
return new g(
|
|
1282
|
-
(
|
|
1281
|
+
(j || "React class") + ": " + x + " type `" + R + "." + _ + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + L + "`."
|
|
1283
1282
|
);
|
|
1284
1283
|
}
|
|
1285
|
-
function de(
|
|
1286
|
-
function
|
|
1287
|
-
var
|
|
1288
|
-
if (
|
|
1289
|
-
return new g("Invalid " +
|
|
1290
|
-
for (var
|
|
1291
|
-
var
|
|
1292
|
-
if (typeof
|
|
1293
|
-
return
|
|
1294
|
-
var
|
|
1295
|
-
if (
|
|
1296
|
-
return
|
|
1284
|
+
function de(j) {
|
|
1285
|
+
function x(R, _, L, B, M) {
|
|
1286
|
+
var N = R[_], H = Q(N);
|
|
1287
|
+
if (H !== "object")
|
|
1288
|
+
return new g("Invalid " + B + " `" + M + "` of type `" + H + "` " + ("supplied to `" + L + "`, expected `object`."));
|
|
1289
|
+
for (var U in j) {
|
|
1290
|
+
var X = j[U];
|
|
1291
|
+
if (typeof X != "function")
|
|
1292
|
+
return J(L, B, M, U, I(X));
|
|
1293
|
+
var ce = X(N, U, L, B, M + "." + U, t);
|
|
1294
|
+
if (ce)
|
|
1295
|
+
return ce;
|
|
1297
1296
|
}
|
|
1298
1297
|
return null;
|
|
1299
1298
|
}
|
|
1300
|
-
return h(
|
|
1299
|
+
return h(x);
|
|
1301
1300
|
}
|
|
1302
|
-
function
|
|
1303
|
-
function
|
|
1304
|
-
var
|
|
1305
|
-
if (
|
|
1306
|
-
return new g("Invalid " +
|
|
1307
|
-
var
|
|
1308
|
-
for (var
|
|
1309
|
-
var
|
|
1310
|
-
if (r(
|
|
1311
|
-
return
|
|
1312
|
-
if (!
|
|
1301
|
+
function z(j) {
|
|
1302
|
+
function x(R, _, L, B, M) {
|
|
1303
|
+
var N = R[_], H = Q(N);
|
|
1304
|
+
if (H !== "object")
|
|
1305
|
+
return new g("Invalid " + B + " `" + M + "` of type `" + H + "` " + ("supplied to `" + L + "`, expected `object`."));
|
|
1306
|
+
var U = n({}, R[_], j);
|
|
1307
|
+
for (var X in U) {
|
|
1308
|
+
var ce = j[X];
|
|
1309
|
+
if (r(j, X) && typeof ce != "function")
|
|
1310
|
+
return J(L, B, M, X, I(ce));
|
|
1311
|
+
if (!ce)
|
|
1313
1312
|
return new g(
|
|
1314
|
-
"Invalid " +
|
|
1315
|
-
Valid keys: ` + JSON.stringify(Object.keys(
|
|
1313
|
+
"Invalid " + B + " `" + M + "` key `" + X + "` supplied to `" + L + "`.\nBad object: " + JSON.stringify(R[_], null, " ") + `
|
|
1314
|
+
Valid keys: ` + JSON.stringify(Object.keys(j), null, " ")
|
|
1316
1315
|
);
|
|
1317
|
-
var
|
|
1318
|
-
if (
|
|
1319
|
-
return
|
|
1316
|
+
var E = ce(N, X, L, B, M + "." + X, t);
|
|
1317
|
+
if (E)
|
|
1318
|
+
return E;
|
|
1320
1319
|
}
|
|
1321
1320
|
return null;
|
|
1322
1321
|
}
|
|
1323
|
-
return h(
|
|
1322
|
+
return h(x);
|
|
1324
1323
|
}
|
|
1325
|
-
function
|
|
1326
|
-
switch (typeof
|
|
1324
|
+
function O(j) {
|
|
1325
|
+
switch (typeof j) {
|
|
1327
1326
|
case "number":
|
|
1328
1327
|
case "string":
|
|
1329
1328
|
case "undefined":
|
|
1330
1329
|
return !0;
|
|
1331
1330
|
case "boolean":
|
|
1332
|
-
return !
|
|
1331
|
+
return !j;
|
|
1333
1332
|
case "object":
|
|
1334
|
-
if (Array.isArray(
|
|
1335
|
-
return
|
|
1336
|
-
if (
|
|
1333
|
+
if (Array.isArray(j))
|
|
1334
|
+
return j.every(O);
|
|
1335
|
+
if (j === null || s(j))
|
|
1337
1336
|
return !0;
|
|
1338
|
-
var
|
|
1339
|
-
if (
|
|
1340
|
-
var
|
|
1341
|
-
if (
|
|
1342
|
-
for (; !(
|
|
1343
|
-
if (!
|
|
1337
|
+
var x = m(j);
|
|
1338
|
+
if (x) {
|
|
1339
|
+
var R = x.call(j), _;
|
|
1340
|
+
if (x !== j.entries) {
|
|
1341
|
+
for (; !(_ = R.next()).done; )
|
|
1342
|
+
if (!O(_.value))
|
|
1344
1343
|
return !1;
|
|
1345
1344
|
} else
|
|
1346
|
-
for (; !(
|
|
1347
|
-
var
|
|
1348
|
-
if (
|
|
1345
|
+
for (; !(_ = R.next()).done; ) {
|
|
1346
|
+
var L = _.value;
|
|
1347
|
+
if (L && !O(L[1]))
|
|
1349
1348
|
return !1;
|
|
1350
1349
|
}
|
|
1351
1350
|
} else
|
|
@@ -1355,41 +1354,41 @@ Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
|
|
|
1355
1354
|
return !1;
|
|
1356
1355
|
}
|
|
1357
1356
|
}
|
|
1358
|
-
function
|
|
1359
|
-
return
|
|
1357
|
+
function V(j, x) {
|
|
1358
|
+
return j === "symbol" ? !0 : x ? x["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && x instanceof Symbol : !1;
|
|
1360
1359
|
}
|
|
1361
|
-
function Q(
|
|
1362
|
-
var
|
|
1363
|
-
return Array.isArray(
|
|
1360
|
+
function Q(j) {
|
|
1361
|
+
var x = typeof j;
|
|
1362
|
+
return Array.isArray(j) ? "array" : j instanceof RegExp ? "object" : V(x, j) ? "symbol" : x;
|
|
1364
1363
|
}
|
|
1365
|
-
function
|
|
1366
|
-
if (typeof
|
|
1367
|
-
return "" +
|
|
1368
|
-
var
|
|
1369
|
-
if (
|
|
1370
|
-
if (
|
|
1364
|
+
function I(j) {
|
|
1365
|
+
if (typeof j > "u" || j === null)
|
|
1366
|
+
return "" + j;
|
|
1367
|
+
var x = Q(j);
|
|
1368
|
+
if (x === "object") {
|
|
1369
|
+
if (j instanceof Date)
|
|
1371
1370
|
return "date";
|
|
1372
|
-
if (
|
|
1371
|
+
if (j instanceof RegExp)
|
|
1373
1372
|
return "regexp";
|
|
1374
1373
|
}
|
|
1375
|
-
return
|
|
1374
|
+
return x;
|
|
1376
1375
|
}
|
|
1377
|
-
function ve(
|
|
1378
|
-
var
|
|
1379
|
-
switch (
|
|
1376
|
+
function ve(j) {
|
|
1377
|
+
var x = I(j);
|
|
1378
|
+
switch (x) {
|
|
1380
1379
|
case "array":
|
|
1381
1380
|
case "object":
|
|
1382
|
-
return "an " +
|
|
1381
|
+
return "an " + x;
|
|
1383
1382
|
case "boolean":
|
|
1384
1383
|
case "date":
|
|
1385
1384
|
case "regexp":
|
|
1386
|
-
return "a " +
|
|
1385
|
+
return "a " + x;
|
|
1387
1386
|
default:
|
|
1388
|
-
return
|
|
1387
|
+
return x;
|
|
1389
1388
|
}
|
|
1390
1389
|
}
|
|
1391
|
-
function
|
|
1392
|
-
return !
|
|
1390
|
+
function W(j) {
|
|
1391
|
+
return !j.constructor || !j.constructor.name ? u : j.constructor.name;
|
|
1393
1392
|
}
|
|
1394
1393
|
return f.checkPropTypes = o, f.resetWarningCache = o.resetWarningCache, f.PropTypes = f, f;
|
|
1395
1394
|
}, vt;
|
|
@@ -3353,88 +3352,88 @@ var Nt = {
|
|
|
3353
3352
|
fileRejections: []
|
|
3354
3353
|
};
|
|
3355
3354
|
function Hn() {
|
|
3356
|
-
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = fe(fe({}, Vn), e), t = n.accept, r = n.disabled, o = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles, d = n.onDragEnter, p = n.onDragLeave, m = n.onDragOver, u = n.onDrop, f = n.onDropAccepted, v = n.onDropRejected, g = n.onFileDialogCancel, h = n.onFileDialogOpen, w = n.useFsAccessApi, S = n.autoFocus, y = n.preventDropOnDocument, $ = n.noClick, b = n.noKeyboard, A = n.noDrag,
|
|
3355
|
+
var e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = fe(fe({}, Vn), e), t = n.accept, r = n.disabled, o = n.getFilesFromEvent, i = n.maxSize, l = n.minSize, s = n.multiple, c = n.maxFiles, d = n.onDragEnter, p = n.onDragLeave, m = n.onDragOver, u = n.onDrop, f = n.onDropAccepted, v = n.onDropRejected, g = n.onFileDialogCancel, h = n.onFileDialogOpen, w = n.useFsAccessApi, S = n.autoFocus, y = n.preventDropOnDocument, $ = n.noClick, b = n.noKeyboard, A = n.noDrag, k = n.noDragEventsBubbling, T = n.onError, K = n.validator, Z = Ae(function() {
|
|
3357
3356
|
return Ur(t);
|
|
3358
|
-
}, [t]),
|
|
3357
|
+
}, [t]), J = Ae(function() {
|
|
3359
3358
|
return Wr(t);
|
|
3360
3359
|
}, [t]), de = Ae(function() {
|
|
3361
3360
|
return typeof h == "function" ? h : vn;
|
|
3362
|
-
}, [h]),
|
|
3361
|
+
}, [h]), z = Ae(function() {
|
|
3363
3362
|
return typeof g == "function" ? g : vn;
|
|
3364
|
-
}, [g]),
|
|
3365
|
-
!
|
|
3366
|
-
if (
|
|
3367
|
-
var
|
|
3368
|
-
|
|
3363
|
+
}, [g]), O = me(null), V = me(null), Q = tr(uo, Nt), I = bt(Q, 2), ve = I[0], W = I[1], j = ve.isFocused, x = ve.isFileDialogActive, R = me(typeof window < "u" && window.isSecureContext && w && Zr()), _ = function() {
|
|
3364
|
+
!R.current && x && setTimeout(function() {
|
|
3365
|
+
if (V.current) {
|
|
3366
|
+
var D = V.current.files;
|
|
3367
|
+
D.length || (W({
|
|
3369
3368
|
type: "closeDialog"
|
|
3370
|
-
}),
|
|
3369
|
+
}), z());
|
|
3371
3370
|
}
|
|
3372
3371
|
}, 300);
|
|
3373
3372
|
};
|
|
3374
3373
|
pe(function() {
|
|
3375
|
-
return window.addEventListener("focus",
|
|
3376
|
-
window.removeEventListener("focus",
|
|
3374
|
+
return window.addEventListener("focus", _, !1), function() {
|
|
3375
|
+
window.removeEventListener("focus", _, !1);
|
|
3377
3376
|
};
|
|
3378
|
-
}, [
|
|
3379
|
-
var
|
|
3380
|
-
|
|
3377
|
+
}, [V, x, z, R]);
|
|
3378
|
+
var L = me([]), B = function(D) {
|
|
3379
|
+
O.current && O.current.contains(D.target) || (D.preventDefault(), L.current = []);
|
|
3381
3380
|
};
|
|
3382
3381
|
pe(function() {
|
|
3383
|
-
return y && (document.addEventListener("dragover", mn, !1), document.addEventListener("drop",
|
|
3384
|
-
y && (document.removeEventListener("dragover", mn), document.removeEventListener("drop",
|
|
3382
|
+
return y && (document.addEventListener("dragover", mn, !1), document.addEventListener("drop", B, !1)), function() {
|
|
3383
|
+
y && (document.removeEventListener("dragover", mn), document.removeEventListener("drop", B));
|
|
3385
3384
|
};
|
|
3386
|
-
}, [
|
|
3387
|
-
return !r && S &&
|
|
3385
|
+
}, [O, y]), pe(function() {
|
|
3386
|
+
return !r && S && O.current && O.current.focus(), function() {
|
|
3388
3387
|
};
|
|
3389
|
-
}, [
|
|
3390
|
-
var
|
|
3391
|
-
|
|
3392
|
-
}, [
|
|
3393
|
-
|
|
3394
|
-
if (!(rt(
|
|
3395
|
-
var ne =
|
|
3396
|
-
files:
|
|
3397
|
-
accept:
|
|
3388
|
+
}, [O, S, r]);
|
|
3389
|
+
var M = se(function(F) {
|
|
3390
|
+
T ? T(F) : console.error(F);
|
|
3391
|
+
}, [T]), N = se(function(F) {
|
|
3392
|
+
F.preventDefault(), F.persist(), Se(F), L.current = [].concat(no(L.current), [F.target]), Ke(F) && Promise.resolve(o(F)).then(function(D) {
|
|
3393
|
+
if (!(rt(F) && !k)) {
|
|
3394
|
+
var ne = D.length, xe = ne > 0 && qr({
|
|
3395
|
+
files: D,
|
|
3396
|
+
accept: Z,
|
|
3398
3397
|
minSize: l,
|
|
3399
3398
|
maxSize: i,
|
|
3400
3399
|
multiple: s,
|
|
3401
3400
|
maxFiles: c,
|
|
3402
|
-
validator:
|
|
3401
|
+
validator: K
|
|
3403
3402
|
}), ye = ne > 0 && !xe;
|
|
3404
|
-
|
|
3403
|
+
W({
|
|
3405
3404
|
isDragAccept: xe,
|
|
3406
3405
|
isDragReject: ye,
|
|
3407
3406
|
isDragActive: !0,
|
|
3408
3407
|
type: "setDraggedFiles"
|
|
3409
|
-
}), d && d(
|
|
3408
|
+
}), d && d(F);
|
|
3410
3409
|
}
|
|
3411
|
-
}).catch(function(
|
|
3412
|
-
return
|
|
3410
|
+
}).catch(function(D) {
|
|
3411
|
+
return M(D);
|
|
3413
3412
|
});
|
|
3414
|
-
}, [o, d,
|
|
3415
|
-
|
|
3416
|
-
var
|
|
3417
|
-
if (
|
|
3413
|
+
}, [o, d, M, k, Z, l, i, s, c, K]), H = se(function(F) {
|
|
3414
|
+
F.preventDefault(), F.persist(), Se(F);
|
|
3415
|
+
var D = Ke(F);
|
|
3416
|
+
if (D && F.dataTransfer)
|
|
3418
3417
|
try {
|
|
3419
|
-
|
|
3418
|
+
F.dataTransfer.dropEffect = "copy";
|
|
3420
3419
|
} catch {
|
|
3421
3420
|
}
|
|
3422
|
-
return
|
|
3423
|
-
}, [m,
|
|
3424
|
-
|
|
3425
|
-
var
|
|
3426
|
-
return
|
|
3427
|
-
}), ne =
|
|
3428
|
-
ne !== -1 &&
|
|
3421
|
+
return D && m && m(F), !1;
|
|
3422
|
+
}, [m, k]), U = se(function(F) {
|
|
3423
|
+
F.preventDefault(), F.persist(), Se(F);
|
|
3424
|
+
var D = L.current.filter(function(xe) {
|
|
3425
|
+
return O.current && O.current.contains(xe);
|
|
3426
|
+
}), ne = D.indexOf(F.target);
|
|
3427
|
+
ne !== -1 && D.splice(ne, 1), L.current = D, !(D.length > 0) && (W({
|
|
3429
3428
|
type: "setDraggedFiles",
|
|
3430
3429
|
isDragActive: !1,
|
|
3431
3430
|
isDragAccept: !1,
|
|
3432
3431
|
isDragReject: !1
|
|
3433
|
-
}), Ke(
|
|
3434
|
-
}, [
|
|
3432
|
+
}), Ke(F) && p && p(F));
|
|
3433
|
+
}, [O, p, k]), X = se(function(F, D) {
|
|
3435
3434
|
var ne = [], xe = [];
|
|
3436
|
-
|
|
3437
|
-
var De = zn(ye,
|
|
3435
|
+
F.forEach(function(ye) {
|
|
3436
|
+
var De = zn(ye, Z), Ne = bt(De, 2), at = Ne[0], lt = Ne[1], st = Tn(ye, l, i), Ye = bt(st, 2), ct = Ye[0], ut = Ye[1], pt = K ? K(ye) : null;
|
|
3438
3437
|
if (at && ct && !pt)
|
|
3439
3438
|
ne.push(ye);
|
|
3440
3439
|
else {
|
|
@@ -3451,88 +3450,88 @@ function Hn() {
|
|
|
3451
3450
|
file: ye,
|
|
3452
3451
|
errors: [Hr]
|
|
3453
3452
|
});
|
|
3454
|
-
}), ne.splice(0)),
|
|
3453
|
+
}), ne.splice(0)), W({
|
|
3455
3454
|
acceptedFiles: ne,
|
|
3456
3455
|
fileRejections: xe,
|
|
3457
3456
|
isDragReject: xe.length > 0,
|
|
3458
3457
|
type: "setFiles"
|
|
3459
|
-
}), u && u(ne, xe,
|
|
3460
|
-
}, [
|
|
3461
|
-
|
|
3462
|
-
rt(
|
|
3463
|
-
}).catch(function(
|
|
3464
|
-
return
|
|
3465
|
-
}),
|
|
3458
|
+
}), u && u(ne, xe, D), xe.length > 0 && v && v(xe, D), ne.length > 0 && f && f(ne, D);
|
|
3459
|
+
}, [W, s, Z, l, i, c, u, f, v, K]), ce = se(function(F) {
|
|
3460
|
+
F.preventDefault(), F.persist(), Se(F), L.current = [], Ke(F) && Promise.resolve(o(F)).then(function(D) {
|
|
3461
|
+
rt(F) && !k || X(D, F);
|
|
3462
|
+
}).catch(function(D) {
|
|
3463
|
+
return M(D);
|
|
3464
|
+
}), W({
|
|
3466
3465
|
type: "reset"
|
|
3467
3466
|
});
|
|
3468
|
-
}, [o,
|
|
3469
|
-
if (
|
|
3470
|
-
|
|
3467
|
+
}, [o, X, M, k]), E = se(function() {
|
|
3468
|
+
if (R.current) {
|
|
3469
|
+
W({
|
|
3471
3470
|
type: "openDialog"
|
|
3472
3471
|
}), de();
|
|
3473
|
-
var
|
|
3472
|
+
var F = {
|
|
3474
3473
|
multiple: s,
|
|
3475
|
-
types:
|
|
3474
|
+
types: J
|
|
3476
3475
|
};
|
|
3477
|
-
window.showOpenFilePicker(
|
|
3478
|
-
return o(
|
|
3479
|
-
}).then(function(
|
|
3480
|
-
|
|
3476
|
+
window.showOpenFilePicker(F).then(function(D) {
|
|
3477
|
+
return o(D);
|
|
3478
|
+
}).then(function(D) {
|
|
3479
|
+
X(D, null), W({
|
|
3481
3480
|
type: "closeDialog"
|
|
3482
3481
|
});
|
|
3483
|
-
}).catch(function(
|
|
3484
|
-
Xr(
|
|
3482
|
+
}).catch(function(D) {
|
|
3483
|
+
Xr(D) ? (z(D), W({
|
|
3485
3484
|
type: "closeDialog"
|
|
3486
|
-
})) : Kr(
|
|
3485
|
+
})) : Kr(D) ? (R.current = !1, V.current ? (V.current.value = null, V.current.click()) : M(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."))) : M(D);
|
|
3487
3486
|
});
|
|
3488
3487
|
return;
|
|
3489
3488
|
}
|
|
3490
|
-
|
|
3489
|
+
V.current && (W({
|
|
3491
3490
|
type: "openDialog"
|
|
3492
|
-
}), de(),
|
|
3493
|
-
}, [
|
|
3494
|
-
!
|
|
3495
|
-
}, [
|
|
3496
|
-
|
|
3491
|
+
}), de(), V.current.value = null, V.current.click());
|
|
3492
|
+
}, [W, de, z, w, X, M, J, s]), P = se(function(F) {
|
|
3493
|
+
!O.current || !O.current.isEqualNode(F.target) || (F.key === " " || F.key === "Enter" || F.keyCode === 32 || F.keyCode === 13) && (F.preventDefault(), E());
|
|
3494
|
+
}, [O, E]), re = se(function() {
|
|
3495
|
+
W({
|
|
3497
3496
|
type: "focus"
|
|
3498
3497
|
});
|
|
3499
|
-
}, []), oe =
|
|
3500
|
-
|
|
3498
|
+
}, []), oe = se(function() {
|
|
3499
|
+
W({
|
|
3501
3500
|
type: "blur"
|
|
3502
3501
|
});
|
|
3503
|
-
}, []), ge =
|
|
3504
|
-
$ || (Yr() ? setTimeout(
|
|
3505
|
-
}, [$,
|
|
3506
|
-
return r ? null :
|
|
3507
|
-
}, te = function(
|
|
3508
|
-
return b ? null :
|
|
3509
|
-
}, je = function(
|
|
3510
|
-
return A ? null :
|
|
3511
|
-
}, Se = function(
|
|
3512
|
-
|
|
3502
|
+
}, []), ge = se(function() {
|
|
3503
|
+
$ || (Yr() ? setTimeout(E, 0) : E());
|
|
3504
|
+
}, [$, E]), q = function(D) {
|
|
3505
|
+
return r ? null : D;
|
|
3506
|
+
}, te = function(D) {
|
|
3507
|
+
return b ? null : q(D);
|
|
3508
|
+
}, je = function(D) {
|
|
3509
|
+
return A ? null : q(D);
|
|
3510
|
+
}, Se = function(D) {
|
|
3511
|
+
k && D.stopPropagation();
|
|
3513
3512
|
}, C = Ae(function() {
|
|
3514
3513
|
return function() {
|
|
3515
|
-
var
|
|
3514
|
+
var F = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, D = F.refKey, ne = D === void 0 ? "ref" : D, xe = F.role, ye = F.onKeyDown, De = F.onFocus, Ne = F.onBlur, at = F.onClick, lt = F.onDragEnter, st = F.onDragOver, Ye = F.onDragLeave, ct = F.onDrop, ut = ot(F, eo);
|
|
3516
3515
|
return fe(fe(Pt({
|
|
3517
|
-
onKeyDown: te(Re(ye,
|
|
3516
|
+
onKeyDown: te(Re(ye, P)),
|
|
3518
3517
|
onFocus: te(Re(De, re)),
|
|
3519
3518
|
onBlur: te(Re(Ne, oe)),
|
|
3520
|
-
onClick:
|
|
3521
|
-
onDragEnter: je(Re(lt,
|
|
3522
|
-
onDragOver: je(Re(st,
|
|
3523
|
-
onDragLeave: je(Re(Ye,
|
|
3524
|
-
onDrop: je(Re(ct,
|
|
3519
|
+
onClick: q(Re(at, ge)),
|
|
3520
|
+
onDragEnter: je(Re(lt, N)),
|
|
3521
|
+
onDragOver: je(Re(st, H)),
|
|
3522
|
+
onDragLeave: je(Re(Ye, U)),
|
|
3523
|
+
onDrop: je(Re(ct, ce)),
|
|
3525
3524
|
role: typeof xe == "string" && xe !== "" ? xe : "presentation"
|
|
3526
|
-
}, ne,
|
|
3525
|
+
}, ne, O), !r && !b ? {
|
|
3527
3526
|
tabIndex: 0
|
|
3528
3527
|
} : {}), ut);
|
|
3529
3528
|
};
|
|
3530
|
-
}, [
|
|
3531
|
-
|
|
3529
|
+
}, [O, P, re, oe, ge, N, H, U, ce, b, A, r]), ie = se(function(F) {
|
|
3530
|
+
F.stopPropagation();
|
|
3532
3531
|
}, []), he = Ae(function() {
|
|
3533
3532
|
return function() {
|
|
3534
|
-
var
|
|
3535
|
-
accept:
|
|
3533
|
+
var F = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, D = F.refKey, ne = D === void 0 ? "ref" : D, xe = F.onChange, ye = F.onClick, De = ot(F, to), Ne = Pt({
|
|
3534
|
+
accept: Z,
|
|
3536
3535
|
multiple: s,
|
|
3537
3536
|
type: "file",
|
|
3538
3537
|
style: {
|
|
@@ -3547,20 +3546,20 @@ function Hn() {
|
|
|
3547
3546
|
width: "1px",
|
|
3548
3547
|
whiteSpace: "nowrap"
|
|
3549
3548
|
},
|
|
3550
|
-
onChange:
|
|
3551
|
-
onClick:
|
|
3549
|
+
onChange: q(Re(xe, ce)),
|
|
3550
|
+
onClick: q(Re(ye, ie)),
|
|
3552
3551
|
tabIndex: -1
|
|
3553
|
-
}, ne,
|
|
3552
|
+
}, ne, V);
|
|
3554
3553
|
return fe(fe({}, Ne), De);
|
|
3555
3554
|
};
|
|
3556
|
-
}, [
|
|
3555
|
+
}, [V, t, s, ce, r]);
|
|
3557
3556
|
return fe(fe({}, ve), {}, {
|
|
3558
|
-
isFocused:
|
|
3557
|
+
isFocused: j && !r,
|
|
3559
3558
|
getRootProps: C,
|
|
3560
3559
|
getInputProps: he,
|
|
3561
|
-
rootRef:
|
|
3562
|
-
inputRef:
|
|
3563
|
-
open:
|
|
3560
|
+
rootRef: O,
|
|
3561
|
+
inputRef: V,
|
|
3562
|
+
open: q(E)
|
|
3564
3563
|
});
|
|
3565
3564
|
}
|
|
3566
3565
|
function uo(e, n) {
|
|
@@ -3632,29 +3631,29 @@ const Ti = ({
|
|
|
3632
3631
|
}) => {
|
|
3633
3632
|
const [y, $] = ee(w), [b, A] = ee([]);
|
|
3634
3633
|
pe(() => {
|
|
3635
|
-
(w.length !== y.length || w.some((
|
|
3634
|
+
(w.length !== y.length || w.some((z, O) => z !== y[O])) && $(w);
|
|
3636
3635
|
}, [w]);
|
|
3637
|
-
const
|
|
3638
|
-
(
|
|
3639
|
-
const
|
|
3640
|
-
if (
|
|
3641
|
-
Q.errors.forEach((
|
|
3642
|
-
|
|
3636
|
+
const k = se(
|
|
3637
|
+
(z, O) => {
|
|
3638
|
+
const V = [];
|
|
3639
|
+
if (O.length > 0 && O.forEach((Q) => {
|
|
3640
|
+
Q.errors.forEach((I) => {
|
|
3641
|
+
I.code === "file-too-large" && V.push(
|
|
3643
3642
|
`${Q.file.name} is too large (max ${(o / 1024 / 1024).toFixed(2)}MB)`
|
|
3644
|
-
),
|
|
3643
|
+
), I.code === "file-invalid-type" && V.push(
|
|
3645
3644
|
`${Q.file.name} has an invalid file type`
|
|
3646
3645
|
);
|
|
3647
3646
|
});
|
|
3648
|
-
}), i !== void 0 && (r ? y.length : 0) +
|
|
3647
|
+
}), i !== void 0 && (r ? y.length : 0) + z.length > i && V.push(
|
|
3649
3648
|
`You can only upload up to ${i} file${i > 1 ? "s" : ""}.`
|
|
3650
|
-
),
|
|
3651
|
-
A(
|
|
3649
|
+
), V.length > 0) {
|
|
3650
|
+
A(V), n == null || n(V);
|
|
3652
3651
|
return;
|
|
3653
3652
|
} else
|
|
3654
3653
|
A([]);
|
|
3655
|
-
|
|
3656
|
-
(Q) => r ? [...Q, ...
|
|
3657
|
-
), e(
|
|
3654
|
+
z.length > 0 && ($(
|
|
3655
|
+
(Q) => r ? [...Q, ...z] : z
|
|
3656
|
+
), e(z));
|
|
3658
3657
|
},
|
|
3659
3658
|
[
|
|
3660
3659
|
e,
|
|
@@ -3664,10 +3663,10 @@ const Ti = ({
|
|
|
3664
3663
|
y,
|
|
3665
3664
|
r
|
|
3666
3665
|
]
|
|
3667
|
-
),
|
|
3668
|
-
$((
|
|
3669
|
-
}, { getRootProps:
|
|
3670
|
-
onDrop:
|
|
3666
|
+
), T = (z) => {
|
|
3667
|
+
$((O) => O.filter((V, Q) => Q !== z)), S(y);
|
|
3668
|
+
}, { getRootProps: K, getInputProps: Z, isDragActive: J, isDragReject: de } = Hn({
|
|
3669
|
+
onDrop: k,
|
|
3671
3670
|
accept: t,
|
|
3672
3671
|
multiple: r,
|
|
3673
3672
|
maxSize: o,
|
|
@@ -3678,7 +3677,7 @@ const Ti = ({
|
|
|
3678
3677
|
{
|
|
3679
3678
|
className: `
|
|
3680
3679
|
border border-style-dashed rounded-lg p-0 overflow-hidden transition
|
|
3681
|
-
${
|
|
3680
|
+
${J ? "border-color-blue-500 bg-color-blue-50" : "border-color-gray-200 bg-color-gray-50"}
|
|
3682
3681
|
${de ? "border-color-red-500 bg-color-red-50" : ""}
|
|
3683
3682
|
${l ? "opacity-50 cursor-not-allowed" : ""}
|
|
3684
3683
|
${p}
|
|
@@ -3687,25 +3686,25 @@ const Ti = ({
|
|
|
3687
3686
|
/* @__PURE__ */ a.jsxs(
|
|
3688
3687
|
"div",
|
|
3689
3688
|
{
|
|
3690
|
-
...
|
|
3689
|
+
...K(),
|
|
3691
3690
|
className: "flex flex-col items-center justify-center text-center px-6 pt-6 pb-4 cursor-pointer",
|
|
3692
3691
|
children: [
|
|
3693
|
-
/* @__PURE__ */ a.jsx("input", { ...
|
|
3692
|
+
/* @__PURE__ */ a.jsx("input", { ...Z() }),
|
|
3694
3693
|
/* @__PURE__ */ a.jsx("div", { className: `text-4xl mb-2 ${m}`, children: d }),
|
|
3695
3694
|
/* @__PURE__ */ a.jsx("p", { className: `text-sm font-medium ${u}`, children: s }),
|
|
3696
3695
|
c && /* @__PURE__ */ a.jsx("p", { className: `text-xs mt-1 ${f}`, children: c })
|
|
3697
3696
|
]
|
|
3698
3697
|
}
|
|
3699
3698
|
),
|
|
3700
|
-
b.length > 0 && /* @__PURE__ */ a.jsx("div", { className: "text-left text-sm text-color-red-600 px-6 pb-2 space-y-1", children: b.map((
|
|
3699
|
+
b.length > 0 && /* @__PURE__ */ a.jsx("div", { className: "text-left text-sm text-color-red-600 px-6 pb-2 space-y-1", children: b.map((z, O) => /* @__PURE__ */ a.jsxs("p", { children: [
|
|
3701
3700
|
"• ",
|
|
3702
|
-
|
|
3703
|
-
] },
|
|
3701
|
+
z
|
|
3702
|
+
] }, O)) }),
|
|
3704
3703
|
v && y.length > 0 && /* @__PURE__ */ a.jsx(
|
|
3705
3704
|
"ul",
|
|
3706
3705
|
{
|
|
3707
3706
|
className: `w-full ${g ? "space-y-2" : "grid grid-columns-2 gap-2"} px-4 pb-4`,
|
|
3708
|
-
children: y.map((
|
|
3707
|
+
children: y.map((z, O) => /* @__PURE__ */ a.jsxs(
|
|
3709
3708
|
"li",
|
|
3710
3709
|
{
|
|
3711
3710
|
className: "flex items-center justify-between bg-color-white rounded-md px-4 py-2 shadow-sm",
|
|
@@ -3714,30 +3713,30 @@ const Ti = ({
|
|
|
3714
3713
|
h && /* @__PURE__ */ a.jsx("div", { className: "w-10 h-10 rounded bg-color-gray-100 overflow-hidden shrink-0", children: /* @__PURE__ */ a.jsx(
|
|
3715
3714
|
"img",
|
|
3716
3715
|
{
|
|
3717
|
-
src:
|
|
3716
|
+
src: z.type.startsWith("image/") ? URL.createObjectURL(z) : "https://img.icons8.com/ios-filled/50/pdf-2.png",
|
|
3718
3717
|
className: "w-full h-full object-cover",
|
|
3719
3718
|
alt: "preview"
|
|
3720
3719
|
}
|
|
3721
3720
|
) }),
|
|
3722
|
-
/* @__PURE__ */ a.jsx("div", { className: "text-sm max-w-[200px]", children: /* @__PURE__ */ a.jsx("p", { className: "font-medium truncate text-xs text-color-gray-700", children:
|
|
3721
|
+
/* @__PURE__ */ a.jsx("div", { className: "text-sm max-w-[200px]", children: /* @__PURE__ */ a.jsx("p", { className: "font-medium truncate text-xs text-color-gray-700", children: z.name }) })
|
|
3723
3722
|
] }),
|
|
3724
3723
|
/* @__PURE__ */ a.jsxs("div", { className: "flex items-center gap-3", children: [
|
|
3725
3724
|
/* @__PURE__ */ a.jsxs("p", { className: "text-xs text-color-gray-400", children: [
|
|
3726
|
-
(
|
|
3725
|
+
(z.size / 1024).toFixed(2),
|
|
3727
3726
|
" KB"
|
|
3728
3727
|
] }),
|
|
3729
3728
|
/* @__PURE__ */ a.jsx(
|
|
3730
3729
|
"button",
|
|
3731
3730
|
{
|
|
3732
3731
|
className: "ml-2 p-1 bg-color-red-50 rounded-full text-color-red-500 hover:text-color-red-700 cursor-pointer",
|
|
3733
|
-
onClick: () => O
|
|
3732
|
+
onClick: () => T(O),
|
|
3734
3733
|
children: /* @__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: "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" }) })
|
|
3735
3734
|
}
|
|
3736
3735
|
)
|
|
3737
3736
|
] })
|
|
3738
3737
|
]
|
|
3739
3738
|
},
|
|
3740
|
-
|
|
3739
|
+
O
|
|
3741
3740
|
))
|
|
3742
3741
|
}
|
|
3743
3742
|
)
|
|
@@ -4167,7 +4166,7 @@ function Co(e, n) {
|
|
|
4167
4166
|
};
|
|
4168
4167
|
return r(e), t;
|
|
4169
4168
|
}
|
|
4170
|
-
function
|
|
4169
|
+
function G(e, n, t) {
|
|
4171
4170
|
let r = [], o;
|
|
4172
4171
|
return (i) => {
|
|
4173
4172
|
let l;
|
|
@@ -4191,7 +4190,7 @@ function Z(e, n, t) {
|
|
|
4191
4190
|
return o;
|
|
4192
4191
|
};
|
|
4193
4192
|
}
|
|
4194
|
-
function
|
|
4193
|
+
function Y(e, n, t, r) {
|
|
4195
4194
|
return {
|
|
4196
4195
|
debug: () => {
|
|
4197
4196
|
var o;
|
|
@@ -4211,14 +4210,14 @@ function jo(e, n, t, r) {
|
|
|
4211
4210
|
column: t,
|
|
4212
4211
|
getValue: () => n.getValue(r),
|
|
4213
4212
|
renderValue: o,
|
|
4214
|
-
getContext:
|
|
4213
|
+
getContext: G(() => [e, t, n, i], (l, s, c, d) => ({
|
|
4215
4214
|
table: l,
|
|
4216
4215
|
column: s,
|
|
4217
4216
|
row: c,
|
|
4218
4217
|
cell: d,
|
|
4219
4218
|
getValue: d.getValue,
|
|
4220
4219
|
renderValue: d.renderValue
|
|
4221
|
-
}),
|
|
4220
|
+
}), Y(e.options, "debugCells", "cell.getContext"))
|
|
4222
4221
|
};
|
|
4223
4222
|
return e._features.forEach((l) => {
|
|
4224
4223
|
l.createCell == null || l.createCell(i, t, n, e);
|
|
@@ -4247,18 +4246,18 @@ function So(e, n, t, r) {
|
|
|
4247
4246
|
depth: t,
|
|
4248
4247
|
columnDef: s,
|
|
4249
4248
|
columns: [],
|
|
4250
|
-
getFlatColumns:
|
|
4249
|
+
getFlatColumns: G(() => [!0], () => {
|
|
4251
4250
|
var u;
|
|
4252
4251
|
return [m, ...(u = m.columns) == null ? void 0 : u.flatMap((f) => f.getFlatColumns())];
|
|
4253
|
-
},
|
|
4254
|
-
getLeafColumns:
|
|
4252
|
+
}, Y(e.options, "debugColumns", "column.getFlatColumns")),
|
|
4253
|
+
getLeafColumns: G(() => [e._getOrderColumnsFn()], (u) => {
|
|
4255
4254
|
var f;
|
|
4256
4255
|
if ((f = m.columns) != null && f.length) {
|
|
4257
4256
|
let v = m.columns.flatMap((g) => g.getLeafColumns());
|
|
4258
4257
|
return u(v);
|
|
4259
4258
|
}
|
|
4260
4259
|
return [m];
|
|
4261
|
-
},
|
|
4260
|
+
}, Y(e.options, "debugColumns", "column.getLeafColumns"))
|
|
4262
4261
|
};
|
|
4263
4262
|
for (const u of e._features)
|
|
4264
4263
|
u.createColumn == null || u.createColumn(m, e);
|
|
@@ -4296,31 +4295,31 @@ function wn(e, n, t) {
|
|
|
4296
4295
|
}
|
|
4297
4296
|
const $o = {
|
|
4298
4297
|
createTable: (e) => {
|
|
4299
|
-
e.getHeaderGroups =
|
|
4298
|
+
e.getHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, r, o) => {
|
|
4300
4299
|
var i, l;
|
|
4301
4300
|
const s = (i = r == null ? void 0 : r.map((m) => t.find((u) => u.id === m)).filter(Boolean)) != null ? i : [], c = (l = o == null ? void 0 : o.map((m) => t.find((u) => u.id === m)).filter(Boolean)) != null ? l : [], d = t.filter((m) => !(r != null && r.includes(m.id)) && !(o != null && o.includes(m.id)));
|
|
4302
4301
|
return Je(n, [...s, ...d, ...c], e);
|
|
4303
|
-
},
|
|
4302
|
+
}, Y(e.options, be, "getHeaderGroups")), e.getCenterHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, r, o) => (t = t.filter((i) => !(r != null && r.includes(i.id)) && !(o != null && o.includes(i.id))), Je(n, t, e, "center")), Y(e.options, be, "getCenterHeaderGroups")), e.getLeftHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.left], (n, t, r) => {
|
|
4304
4303
|
var o;
|
|
4305
4304
|
const i = (o = r == null ? void 0 : r.map((l) => t.find((s) => s.id === l)).filter(Boolean)) != null ? o : [];
|
|
4306
4305
|
return Je(n, i, e, "left");
|
|
4307
|
-
},
|
|
4306
|
+
}, Y(e.options, be, "getLeftHeaderGroups")), e.getRightHeaderGroups = G(() => [e.getAllColumns(), e.getVisibleLeafColumns(), e.getState().columnPinning.right], (n, t, r) => {
|
|
4308
4307
|
var o;
|
|
4309
4308
|
const i = (o = r == null ? void 0 : r.map((l) => t.find((s) => s.id === l)).filter(Boolean)) != null ? o : [];
|
|
4310
4309
|
return Je(n, i, e, "right");
|
|
4311
|
-
},
|
|
4310
|
+
}, Y(e.options, be, "getRightHeaderGroups")), e.getFooterGroups = G(() => [e.getHeaderGroups()], (n) => [...n].reverse(), Y(e.options, be, "getFooterGroups")), e.getLeftFooterGroups = G(() => [e.getLeftHeaderGroups()], (n) => [...n].reverse(), Y(e.options, be, "getLeftFooterGroups")), e.getCenterFooterGroups = G(() => [e.getCenterHeaderGroups()], (n) => [...n].reverse(), Y(e.options, be, "getCenterFooterGroups")), e.getRightFooterGroups = G(() => [e.getRightHeaderGroups()], (n) => [...n].reverse(), Y(e.options, be, "getRightFooterGroups")), e.getFlatHeaders = G(() => [e.getHeaderGroups()], (n) => n.map((t) => t.headers).flat(), Y(e.options, be, "getFlatHeaders")), e.getLeftFlatHeaders = G(() => [e.getLeftHeaderGroups()], (n) => n.map((t) => t.headers).flat(), Y(e.options, be, "getLeftFlatHeaders")), e.getCenterFlatHeaders = G(() => [e.getCenterHeaderGroups()], (n) => n.map((t) => t.headers).flat(), Y(e.options, be, "getCenterFlatHeaders")), e.getRightFlatHeaders = G(() => [e.getRightHeaderGroups()], (n) => n.map((t) => t.headers).flat(), Y(e.options, be, "getRightFlatHeaders")), e.getCenterLeafHeaders = G(() => [e.getCenterFlatHeaders()], (n) => n.filter((t) => {
|
|
4312
4311
|
var r;
|
|
4313
4312
|
return !((r = t.subHeaders) != null && r.length);
|
|
4314
|
-
}),
|
|
4313
|
+
}), Y(e.options, be, "getCenterLeafHeaders")), e.getLeftLeafHeaders = G(() => [e.getLeftFlatHeaders()], (n) => n.filter((t) => {
|
|
4315
4314
|
var r;
|
|
4316
4315
|
return !((r = t.subHeaders) != null && r.length);
|
|
4317
|
-
}),
|
|
4316
|
+
}), Y(e.options, be, "getLeftLeafHeaders")), e.getRightLeafHeaders = G(() => [e.getRightFlatHeaders()], (n) => n.filter((t) => {
|
|
4318
4317
|
var r;
|
|
4319
4318
|
return !((r = t.subHeaders) != null && r.length);
|
|
4320
|
-
}),
|
|
4319
|
+
}), Y(e.options, be, "getRightLeafHeaders")), e.getLeafHeaders = G(() => [e.getLeftHeaderGroups(), e.getCenterHeaderGroups(), e.getRightHeaderGroups()], (n, t, r) => {
|
|
4321
4320
|
var o, i, l, s, c, d;
|
|
4322
4321
|
return [...(o = (i = n[0]) == null ? void 0 : i.headers) != null ? o : [], ...(l = (s = t[0]) == null ? void 0 : s.headers) != null ? l : [], ...(c = (d = r[0]) == null ? void 0 : d.headers) != null ? c : []].map((p) => p.getLeafHeaders()).flat();
|
|
4323
|
-
},
|
|
4322
|
+
}, Y(e.options, be, "getLeafHeaders"));
|
|
4324
4323
|
}
|
|
4325
4324
|
};
|
|
4326
4325
|
function Je(e, n, t, r) {
|
|
@@ -4418,8 +4417,8 @@ const Ro = (e, n, t, r, o, i, l) => {
|
|
|
4418
4417
|
}
|
|
4419
4418
|
return c.reverse();
|
|
4420
4419
|
},
|
|
4421
|
-
getAllCells:
|
|
4422
|
-
_getAllCellsByColumnId:
|
|
4420
|
+
getAllCells: G(() => [e.getAllLeafColumns()], (c) => c.map((d) => jo(e, s, d, d.id)), Y(e.options, "debugRows", "getAllCells")),
|
|
4421
|
+
_getAllCellsByColumnId: G(() => [s.getAllCells()], (c) => c.reduce((d, p) => (d[p.column.id] = p, d), {}), Y(e.options, "debugRows", "getAllCellsByColumnId"))
|
|
4423
4422
|
};
|
|
4424
4423
|
for (let c = 0; c < e._features.length; c++) {
|
|
4425
4424
|
const d = e._features[c];
|
|
@@ -4703,7 +4702,7 @@ const Io = {
|
|
|
4703
4702
|
onColumnOrderChange: Ce("columnOrder", e)
|
|
4704
4703
|
}),
|
|
4705
4704
|
createColumn: (e, n) => {
|
|
4706
|
-
e.getIndex =
|
|
4705
|
+
e.getIndex = G((t) => [qe(n, t)], (t) => t.findIndex((r) => r.id === e.id), Y(n.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (t) => {
|
|
4707
4706
|
var r;
|
|
4708
4707
|
return ((r = qe(n, t)[0]) == null ? void 0 : r.id) === e.id;
|
|
4709
4708
|
}, e.getIsLastColumn = (t) => {
|
|
@@ -4716,7 +4715,7 @@ const Io = {
|
|
|
4716
4715
|
e.setColumnOrder = (n) => e.options.onColumnOrderChange == null ? void 0 : e.options.onColumnOrderChange(n), e.resetColumnOrder = (n) => {
|
|
4717
4716
|
var t;
|
|
4718
4717
|
e.setColumnOrder(n ? [] : (t = e.initialState.columnOrder) != null ? t : []);
|
|
4719
|
-
}, e._getOrderColumnsFn =
|
|
4718
|
+
}, e._getOrderColumnsFn = G(() => [e.getState().columnOrder, e.getState().grouping, e.options.groupedColumnMode], (n, t, r) => (o) => {
|
|
4720
4719
|
let i = [];
|
|
4721
4720
|
if (!(n != null && n.length))
|
|
4722
4721
|
i = o;
|
|
@@ -4729,7 +4728,7 @@ const Io = {
|
|
|
4729
4728
|
i = [...i, ...s];
|
|
4730
4729
|
}
|
|
4731
4730
|
return Do(i, t, r);
|
|
4732
|
-
},
|
|
4731
|
+
}, Y(e.options, "debugTable", "_getOrderColumnsFn"));
|
|
4733
4732
|
}
|
|
4734
4733
|
}, Ct = () => ({
|
|
4735
4734
|
left: [],
|
|
@@ -4782,16 +4781,16 @@ const Io = {
|
|
|
4782
4781
|
};
|
|
4783
4782
|
},
|
|
4784
4783
|
createRow: (e, n) => {
|
|
4785
|
-
e.getCenterVisibleCells =
|
|
4784
|
+
e.getCenterVisibleCells = G(() => [e._getAllVisibleCells(), n.getState().columnPinning.left, n.getState().columnPinning.right], (t, r, o) => {
|
|
4786
4785
|
const i = [...r ?? [], ...o ?? []];
|
|
4787
4786
|
return t.filter((l) => !i.includes(l.column.id));
|
|
4788
|
-
},
|
|
4787
|
+
}, Y(n.options, "debugRows", "getCenterVisibleCells")), e.getLeftVisibleCells = G(() => [e._getAllVisibleCells(), n.getState().columnPinning.left], (t, r) => (r ?? []).map((i) => t.find((l) => l.column.id === i)).filter(Boolean).map((i) => ({
|
|
4789
4788
|
...i,
|
|
4790
4789
|
position: "left"
|
|
4791
|
-
})),
|
|
4790
|
+
})), Y(n.options, "debugRows", "getLeftVisibleCells")), e.getRightVisibleCells = G(() => [e._getAllVisibleCells(), n.getState().columnPinning.right], (t, r) => (r ?? []).map((i) => t.find((l) => l.column.id === i)).filter(Boolean).map((i) => ({
|
|
4792
4791
|
...i,
|
|
4793
4792
|
position: "right"
|
|
4794
|
-
})),
|
|
4793
|
+
})), Y(n.options, "debugRows", "getRightVisibleCells"));
|
|
4795
4794
|
},
|
|
4796
4795
|
createTable: (e) => {
|
|
4797
4796
|
e.setColumnPinning = (n) => e.options.onColumnPinningChange == null ? void 0 : e.options.onColumnPinningChange(n), e.resetColumnPinning = (n) => {
|
|
@@ -4805,10 +4804,10 @@ const Io = {
|
|
|
4805
4804
|
return !!((o = r.left) != null && o.length || (i = r.right) != null && i.length);
|
|
4806
4805
|
}
|
|
4807
4806
|
return !!((t = r[n]) != null && t.length);
|
|
4808
|
-
}, e.getLeftLeafColumns =
|
|
4807
|
+
}, e.getLeftLeafColumns = G(() => [e.getAllLeafColumns(), e.getState().columnPinning.left], (n, t) => (t ?? []).map((r) => n.find((o) => o.id === r)).filter(Boolean), Y(e.options, "debugColumns", "getLeftLeafColumns")), e.getRightLeafColumns = G(() => [e.getAllLeafColumns(), e.getState().columnPinning.right], (n, t) => (t ?? []).map((r) => n.find((o) => o.id === r)).filter(Boolean), Y(e.options, "debugColumns", "getRightLeafColumns")), e.getCenterLeafColumns = G(() => [e.getAllLeafColumns(), e.getState().columnPinning.left, e.getState().columnPinning.right], (n, t, r) => {
|
|
4809
4808
|
const o = [...t ?? [], ...r ?? []];
|
|
4810
4809
|
return n.filter((i) => !o.includes(i.id));
|
|
4811
|
-
},
|
|
4810
|
+
}, Y(e.options, "debugColumns", "getCenterLeafColumns"));
|
|
4812
4811
|
}
|
|
4813
4812
|
}, Qe = {
|
|
4814
4813
|
size: 150,
|
|
@@ -4839,7 +4838,7 @@ const Io = {
|
|
|
4839
4838
|
var t, r, o;
|
|
4840
4839
|
const i = n.getState().columnSizing[e.id];
|
|
4841
4840
|
return Math.min(Math.max((t = e.columnDef.minSize) != null ? t : Qe.minSize, (r = i ?? e.columnDef.size) != null ? r : Qe.size), (o = e.columnDef.maxSize) != null ? o : Qe.maxSize);
|
|
4842
|
-
}, e.getStart =
|
|
4841
|
+
}, e.getStart = G((t) => [t, qe(n, t), n.getState().columnSizing], (t, r) => r.slice(0, e.getIndex(t)).reduce((o, i) => o + i.getSize(), 0), Y(n.options, "debugColumns", "getStart")), e.getAfter = G((t) => [t, qe(n, t), n.getState().columnSizing], (t, r) => r.slice(e.getIndex(t) + 1).reduce((o, i) => o + i.getSize(), 0), Y(n.options, "debugColumns", "getAfter")), e.resetSize = () => {
|
|
4843
4842
|
n.setColumnSizing((t) => {
|
|
4844
4843
|
let {
|
|
4845
4844
|
[e.id]: r,
|
|
@@ -4878,14 +4877,14 @@ const Io = {
|
|
|
4878
4877
|
const l = e.getSize(), s = e ? e.getLeafHeaders().map((w) => [w.column.id, w.column.getSize()]) : [[r.id, r.getSize()]], c = St(i) ? Math.round(i.touches[0].clientX) : i.clientX, d = {}, p = (w, S) => {
|
|
4879
4878
|
typeof S == "number" && (n.setColumnSizingInfo((y) => {
|
|
4880
4879
|
var $, b;
|
|
4881
|
-
const A = n.options.columnResizeDirection === "rtl" ? -1 : 1,
|
|
4882
|
-
return y.columnSizingStart.forEach((
|
|
4883
|
-
let [
|
|
4884
|
-
d[
|
|
4880
|
+
const A = n.options.columnResizeDirection === "rtl" ? -1 : 1, k = (S - (($ = y == null ? void 0 : y.startOffset) != null ? $ : 0)) * A, T = Math.max(k / ((b = y == null ? void 0 : y.startSize) != null ? b : 0), -0.999999);
|
|
4881
|
+
return y.columnSizingStart.forEach((K) => {
|
|
4882
|
+
let [Z, J] = K;
|
|
4883
|
+
d[Z] = Math.round(Math.max(J + J * T, 0) * 100) / 100;
|
|
4885
4884
|
}), {
|
|
4886
4885
|
...y,
|
|
4887
|
-
deltaOffset:
|
|
4888
|
-
deltaPercentage:
|
|
4886
|
+
deltaOffset: k,
|
|
4887
|
+
deltaPercentage: T
|
|
4889
4888
|
};
|
|
4890
4889
|
}), (n.options.columnResizeMode === "onChange" || w === "end") && n.setColumnSizing((y) => ({
|
|
4891
4890
|
...y,
|
|
@@ -4995,10 +4994,10 @@ const Bo = {
|
|
|
4995
4994
|
};
|
|
4996
4995
|
},
|
|
4997
4996
|
createRow: (e, n) => {
|
|
4998
|
-
e._getAllVisibleCells =
|
|
4997
|
+
e._getAllVisibleCells = G(() => [e.getAllCells(), n.getState().columnVisibility], (t) => t.filter((r) => r.column.getIsVisible()), Y(n.options, "debugRows", "_getAllVisibleCells")), e.getVisibleCells = G(() => [e.getLeftVisibleCells(), e.getCenterVisibleCells(), e.getRightVisibleCells()], (t, r, o) => [...t, ...r, ...o], Y(n.options, "debugRows", "getVisibleCells"));
|
|
4999
4998
|
},
|
|
5000
4999
|
createTable: (e) => {
|
|
5001
|
-
const n = (t, r) =>
|
|
5000
|
+
const n = (t, r) => G(() => [r(), r().filter((o) => o.getIsVisible()).map((o) => o.id).join("_")], (o) => o.filter((i) => i.getIsVisible == null ? void 0 : i.getIsVisible()), Y(e.options, "debugColumns", t));
|
|
5002
5001
|
e.getVisibleFlatColumns = n("getVisibleFlatColumns", () => e.getAllFlatColumns()), e.getVisibleLeafColumns = n("getVisibleLeafColumns", () => e.getAllLeafColumns()), e.getLeftVisibleLeafColumns = n("getLeftVisibleLeafColumns", () => e.getLeftLeafColumns()), e.getRightVisibleLeafColumns = n("getRightVisibleLeafColumns", () => e.getRightLeafColumns()), e.getCenterVisibleLeafColumns = n("getCenterVisibleLeafColumns", () => e.getCenterLeafColumns()), e.setColumnVisibility = (t) => e.options.onColumnVisibilityChange == null ? void 0 : e.options.onColumnVisibilityChange(t), e.resetColumnVisibility = (t) => {
|
|
5003
5002
|
var r;
|
|
5004
5003
|
e.setColumnVisibility(t ? {} : (r = e.initialState.columnVisibility) != null ? r : {});
|
|
@@ -5211,10 +5210,10 @@ const Go = {
|
|
|
5211
5210
|
...o,
|
|
5212
5211
|
pageCount: l
|
|
5213
5212
|
};
|
|
5214
|
-
}), e.getPageOptions =
|
|
5213
|
+
}), e.getPageOptions = G(() => [e.getPageCount()], (r) => {
|
|
5215
5214
|
let o = [];
|
|
5216
5215
|
return r && r > 0 && (o = [...new Array(r)].fill(null).map((i, l) => l)), o;
|
|
5217
|
-
},
|
|
5216
|
+
}, Y(e.options, "debugTable", "getPageOptions")), e.getCanPreviousPage = () => e.getState().pagination.pageIndex > 0, e.getCanNextPage = () => {
|
|
5218
5217
|
const {
|
|
5219
5218
|
pageIndex: r
|
|
5220
5219
|
} = e.getState().pagination, o = e.getPageCount();
|
|
@@ -5326,10 +5325,10 @@ const Go = {
|
|
|
5326
5325
|
...l,
|
|
5327
5326
|
position: r
|
|
5328
5327
|
}));
|
|
5329
|
-
}, e.getTopRows =
|
|
5328
|
+
}, e.getTopRows = G(() => [e.getRowModel().rows, e.getState().rowPinning.top], (n, t) => e._getPinnedRows(n, t, "top"), Y(e.options, "debugRows", "getTopRows")), e.getBottomRows = G(() => [e.getRowModel().rows, e.getState().rowPinning.bottom], (n, t) => e._getPinnedRows(n, t, "bottom"), Y(e.options, "debugRows", "getBottomRows")), e.getCenterRows = G(() => [e.getRowModel().rows, e.getState().rowPinning.top, e.getState().rowPinning.bottom], (n, t, r) => {
|
|
5330
5329
|
const o = /* @__PURE__ */ new Set([...t ?? [], ...r ?? []]);
|
|
5331
5330
|
return n.filter((i) => !o.has(i.id));
|
|
5332
|
-
},
|
|
5331
|
+
}, Y(e.options, "debugRows", "getCenterRows"));
|
|
5333
5332
|
}
|
|
5334
5333
|
}, Xo = {
|
|
5335
5334
|
getInitialState: (e) => ({
|
|
@@ -5368,19 +5367,19 @@ const Go = {
|
|
|
5368
5367
|
return e.getRowModel().rows.forEach((i) => {
|
|
5369
5368
|
Tt(o, i.id, r, !0, e);
|
|
5370
5369
|
}), o;
|
|
5371
|
-
}), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel =
|
|
5370
|
+
}), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = G(() => [e.getState().rowSelection, e.getCoreRowModel()], (n, t) => Object.keys(n).length ? kt(e, t) : {
|
|
5372
5371
|
rows: [],
|
|
5373
5372
|
flatRows: [],
|
|
5374
5373
|
rowsById: {}
|
|
5375
|
-
},
|
|
5374
|
+
}, Y(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = G(() => [e.getState().rowSelection, e.getFilteredRowModel()], (n, t) => Object.keys(n).length ? kt(e, t) : {
|
|
5376
5375
|
rows: [],
|
|
5377
5376
|
flatRows: [],
|
|
5378
5377
|
rowsById: {}
|
|
5379
|
-
},
|
|
5378
|
+
}, Y(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = G(() => [e.getState().rowSelection, e.getSortedRowModel()], (n, t) => Object.keys(n).length ? kt(e, t) : {
|
|
5380
5379
|
rows: [],
|
|
5381
5380
|
flatRows: [],
|
|
5382
5381
|
rowsById: {}
|
|
5383
|
-
},
|
|
5382
|
+
}, Y(e.options, "debugTable", "getGroupedSelectedRowModel")), e.getIsAllRowsSelected = () => {
|
|
5384
5383
|
const n = e.getFilteredRowModel().flatRows, {
|
|
5385
5384
|
rowSelection: t
|
|
5386
5385
|
} = e.getState();
|
|
@@ -5696,7 +5695,7 @@ function ii(e) {
|
|
|
5696
5695
|
throw process.env.NODE_ENV !== "production" ? new Error(`getRow could not find row with ID: ${u}`) : new Error();
|
|
5697
5696
|
return v;
|
|
5698
5697
|
},
|
|
5699
|
-
_getDefaultColumnDef:
|
|
5698
|
+
_getDefaultColumnDef: G(() => [o.options.defaultColumn], (u) => {
|
|
5700
5699
|
var f;
|
|
5701
5700
|
return u = (f = u) != null ? f : {}, {
|
|
5702
5701
|
header: (v) => {
|
|
@@ -5711,9 +5710,9 @@ function ii(e) {
|
|
|
5711
5710
|
...o._features.reduce((v, g) => Object.assign(v, g.getDefaultColumnDef == null ? void 0 : g.getDefaultColumnDef()), {}),
|
|
5712
5711
|
...u
|
|
5713
5712
|
};
|
|
5714
|
-
},
|
|
5713
|
+
}, Y(e, "debugColumns", "_getDefaultColumnDef")),
|
|
5715
5714
|
_getColumnDefs: () => o.options.columns,
|
|
5716
|
-
getAllColumns:
|
|
5715
|
+
getAllColumns: G(() => [o._getColumnDefs()], (u) => {
|
|
5717
5716
|
const f = function(v, g, h) {
|
|
5718
5717
|
return h === void 0 && (h = 0), v.map((w) => {
|
|
5719
5718
|
const S = So(o, w, h, g), y = w;
|
|
@@ -5721,13 +5720,13 @@ function ii(e) {
|
|
|
5721
5720
|
});
|
|
5722
5721
|
};
|
|
5723
5722
|
return f(u);
|
|
5724
|
-
},
|
|
5725
|
-
getAllFlatColumns:
|
|
5726
|
-
_getAllFlatColumnsById:
|
|
5727
|
-
getAllLeafColumns:
|
|
5723
|
+
}, Y(e, "debugColumns", "getAllColumns")),
|
|
5724
|
+
getAllFlatColumns: G(() => [o.getAllColumns()], (u) => u.flatMap((f) => f.getFlatColumns()), Y(e, "debugColumns", "getAllFlatColumns")),
|
|
5725
|
+
_getAllFlatColumnsById: G(() => [o.getAllFlatColumns()], (u) => u.reduce((f, v) => (f[v.id] = v, f), {}), Y(e, "debugColumns", "getAllFlatColumnsById")),
|
|
5726
|
+
getAllLeafColumns: G(() => [o.getAllColumns(), o._getOrderColumnsFn()], (u, f) => {
|
|
5728
5727
|
let v = u.flatMap((g) => g.getLeafColumns());
|
|
5729
5728
|
return f(v);
|
|
5730
|
-
},
|
|
5729
|
+
}, Y(e, "debugColumns", "getAllLeafColumns")),
|
|
5731
5730
|
getColumn: (u) => {
|
|
5732
5731
|
const f = o._getAllFlatColumnsById()[u];
|
|
5733
5732
|
return process.env.NODE_ENV !== "production" && !f && console.error(`[Table] Column with id '${u}' does not exist.`), f;
|
|
@@ -5741,7 +5740,7 @@ function ii(e) {
|
|
|
5741
5740
|
return o;
|
|
5742
5741
|
}
|
|
5743
5742
|
function ai() {
|
|
5744
|
-
return (e) =>
|
|
5743
|
+
return (e) => G(() => [e.options.data], (n) => {
|
|
5745
5744
|
const t = {
|
|
5746
5745
|
rows: [],
|
|
5747
5746
|
flatRows: [],
|
|
@@ -5759,7 +5758,7 @@ function ai() {
|
|
|
5759
5758
|
return s;
|
|
5760
5759
|
};
|
|
5761
5760
|
return t.rows = r(n), t;
|
|
5762
|
-
},
|
|
5761
|
+
}, Y(e.options, "debugTable", "getRowModel", () => e._autoResetPageIndex()));
|
|
5763
5762
|
}
|
|
5764
5763
|
/**
|
|
5765
5764
|
* react-table
|
|
@@ -6061,17 +6060,17 @@ const si = {
|
|
|
6061
6060
|
size: g = "medium",
|
|
6062
6061
|
...h
|
|
6063
6062
|
}, w) => {
|
|
6064
|
-
const [S, y] = ee(""), $ = n !== void 0, b = $ ? n : S, A = p ? "border-color-red-500 focus-within:ring-color-red-500" : "border-color-gray-200",
|
|
6065
|
-
let
|
|
6066
|
-
|
|
6067
|
-
...
|
|
6068
|
-
target: { ...
|
|
6069
|
-
}), $ || y(
|
|
6063
|
+
const [S, y] = ee(""), $ = n !== void 0, b = $ ? n : S, A = p ? "border-color-red-500 focus-within:ring-color-red-500" : "border-color-gray-200", k = p ? "text-color-red-500" : s, T = (K) => {
|
|
6064
|
+
let Z = K.target.value.replace(/(?!^\+)[^\d]/g, "");
|
|
6065
|
+
Z.startsWith("+") && (Z = "+" + Z.slice(1).replace(/\+/g, "")), Z = Z.replace(/\s/g, ""), (!m || Z.replace(/^\+/, "").length <= m) && (t && t({
|
|
6066
|
+
...K,
|
|
6067
|
+
target: { ...K.target, value: Z }
|
|
6068
|
+
}), $ || y(Z));
|
|
6070
6069
|
};
|
|
6071
6070
|
return /* @__PURE__ */ a.jsxs("div", { className: "w-full", children: [
|
|
6072
6071
|
u && /* @__PURE__ */ a.jsx("label", { className: `text-sm font-medium text-color-gray-700 mb-1 block ${f}`, children: u }),
|
|
6073
6072
|
/* @__PURE__ */ a.jsxs("div", { className: `flex items-center w-full rounded-md border focus-within:ring-1 ${A} ${di[v]} ${i}`, children: [
|
|
6074
|
-
c && /* @__PURE__ */ a.jsx("span", { className: `pl-3 ${
|
|
6073
|
+
c && /* @__PURE__ */ a.jsx("span", { className: `pl-3 ${k}`, children: c }),
|
|
6075
6074
|
/* @__PURE__ */ a.jsx(
|
|
6076
6075
|
"input",
|
|
6077
6076
|
{
|
|
@@ -6081,11 +6080,11 @@ const si = {
|
|
|
6081
6080
|
inputMode: "numeric",
|
|
6082
6081
|
placeholder: e,
|
|
6083
6082
|
value: b,
|
|
6084
|
-
onChange:
|
|
6083
|
+
onChange: T,
|
|
6085
6084
|
className: `grow outline-0 w-full font-medium placeholder:font-normal bg-color-transparent ${pi[g]} ${l}`
|
|
6086
6085
|
}
|
|
6087
6086
|
),
|
|
6088
|
-
d && /* @__PURE__ */ a.jsx("span", { className: `pr-3 ${
|
|
6087
|
+
d && /* @__PURE__ */ a.jsx("span", { className: `pr-3 ${k}`, children: d })
|
|
6089
6088
|
] }),
|
|
6090
6089
|
p && /* @__PURE__ */ a.jsx("p", { className: "text-color-red-500 text-xs mt-1", children: p })
|
|
6091
6090
|
] });
|
|
@@ -6208,19 +6207,19 @@ function vi(e) {
|
|
|
6208
6207
|
return !0;
|
|
6209
6208
|
}
|
|
6210
6209
|
return !1;
|
|
6211
|
-
}, i =
|
|
6210
|
+
}, i = se(
|
|
6212
6211
|
(c) => {
|
|
6213
6212
|
e && (o(c, r.current) || (r.current = c, e(c)));
|
|
6214
6213
|
},
|
|
6215
6214
|
[e]
|
|
6216
|
-
), l =
|
|
6215
|
+
), l = se(
|
|
6217
6216
|
(c) => {
|
|
6218
6217
|
t.current = c, n.current == null && (n.current = requestAnimationFrame(() => {
|
|
6219
6218
|
n.current = null, t.current != null && i(t.current);
|
|
6220
6219
|
}));
|
|
6221
6220
|
},
|
|
6222
6221
|
[i]
|
|
6223
|
-
), s =
|
|
6222
|
+
), s = se(() => {
|
|
6224
6223
|
n.current != null && cancelAnimationFrame(n.current), n.current = null;
|
|
6225
6224
|
}, []);
|
|
6226
6225
|
return { schedule: l, flush: i, cancel: s, last: t };
|
|
@@ -6246,90 +6245,90 @@ const Yi = rr(function({
|
|
|
6246
6245
|
range: g = !1,
|
|
6247
6246
|
minDistance: h = 0
|
|
6248
6247
|
}) {
|
|
6249
|
-
const w = n !== void 0, [S, y] = ee(() => t !== void 0 ? t : g ? [i, l] : i), $ = w ? n : S, b = Array.isArray($) ? $[0] : $, [A,
|
|
6250
|
-
(
|
|
6248
|
+
const w = n !== void 0, [S, y] = ee(() => t !== void 0 ? t : g ? [i, l] : i), $ = w ? n : S, b = Array.isArray($) ? $[0] : $, [A, k] = Array.isArray($) ? $ : [$, $], T = _t[c] || _t.blue, K = yn[d] ?? yn.medium, Z = se(
|
|
6249
|
+
(P) => (P - i) / (l - i) * 100,
|
|
6251
6250
|
[i, l]
|
|
6252
|
-
),
|
|
6253
|
-
(
|
|
6254
|
-
w || y(
|
|
6251
|
+
), J = Z(b), de = Z(A), z = Z(k), O = se((P) => Math.max(i, Math.min(l, P)), [i, l]), V = se((P) => Math.round(P / s) * s, [s]), Q = vi(r), I = se(
|
|
6252
|
+
(P, re = !0) => {
|
|
6253
|
+
w || y(P), re ? Q.schedule(P) : Q.flush(P);
|
|
6255
6254
|
},
|
|
6256
6255
|
[w, Q]
|
|
6257
|
-
), ve =
|
|
6258
|
-
const
|
|
6259
|
-
|
|
6260
|
-
}, [Q, o]),
|
|
6261
|
-
(
|
|
6262
|
-
if (g && Array.isArray(
|
|
6263
|
-
let [oe, ge] =
|
|
6264
|
-
return te -
|
|
6265
|
-
} else if (!g && typeof
|
|
6266
|
-
return
|
|
6267
|
-
return
|
|
6256
|
+
), ve = se(() => {
|
|
6257
|
+
const P = Q.last.current;
|
|
6258
|
+
P != null && (Q.flush(P), o == null || o(P));
|
|
6259
|
+
}, [Q, o]), W = se(
|
|
6260
|
+
(P, re) => {
|
|
6261
|
+
if (g && Array.isArray(P)) {
|
|
6262
|
+
let [oe, ge] = P, q = V(O(oe)), te = V(O(ge));
|
|
6263
|
+
return te - q < h && (re === "min" ? te = O(q + h) : re === "max" && (q = O(te - h))), q > te && (re === "min" ? q = te : te = q), [q, te];
|
|
6264
|
+
} else if (!g && typeof P == "number")
|
|
6265
|
+
return V(O(P));
|
|
6266
|
+
return P;
|
|
6268
6267
|
},
|
|
6269
|
-
[g,
|
|
6270
|
-
),
|
|
6271
|
-
(
|
|
6268
|
+
[g, O, V, h]
|
|
6269
|
+
), j = me(null), x = se(
|
|
6270
|
+
(P) => {
|
|
6272
6271
|
var ge;
|
|
6273
|
-
const re = (ge =
|
|
6272
|
+
const re = (ge = j.current) == null ? void 0 : ge.getBoundingClientRect();
|
|
6274
6273
|
if (!re) return g ? i : b;
|
|
6275
|
-
const oe = Math.max(0, Math.min(1, (
|
|
6274
|
+
const oe = Math.max(0, Math.min(1, (P - re.left) / re.width));
|
|
6276
6275
|
return i + oe * (l - i);
|
|
6277
6276
|
},
|
|
6278
6277
|
[i, l, g, b]
|
|
6279
|
-
),
|
|
6280
|
-
(
|
|
6281
|
-
const re = Math.abs(
|
|
6278
|
+
), R = se(
|
|
6279
|
+
(P) => {
|
|
6280
|
+
const re = Math.abs(P - A), oe = Math.abs(P - k);
|
|
6282
6281
|
return re <= oe ? "min" : "max";
|
|
6283
6282
|
},
|
|
6284
|
-
[A,
|
|
6285
|
-
), [
|
|
6286
|
-
(
|
|
6287
|
-
var ge,
|
|
6283
|
+
[A, k]
|
|
6284
|
+
), [_, L] = ee(null), [B, M] = ee(null), [N, H] = ee(null), U = se(
|
|
6285
|
+
(P, re) => {
|
|
6286
|
+
var ge, q;
|
|
6288
6287
|
if (p) return;
|
|
6289
|
-
|
|
6290
|
-
const oe =
|
|
6288
|
+
P.preventDefault(), (q = (ge = P.currentTarget).setPointerCapture) == null || q.call(ge, P.pointerId), H(P.pointerId);
|
|
6289
|
+
const oe = x(P.clientX);
|
|
6291
6290
|
if (g) {
|
|
6292
|
-
const te = re ||
|
|
6293
|
-
|
|
6291
|
+
const te = re || R(oe);
|
|
6292
|
+
L(te), I(te === "min" ? W([oe, k], "min") : W([A, oe], "max"));
|
|
6294
6293
|
} else
|
|
6295
|
-
|
|
6294
|
+
L("single"), I(W(oe, "single"));
|
|
6296
6295
|
},
|
|
6297
6296
|
[
|
|
6298
6297
|
p,
|
|
6299
6298
|
g,
|
|
6300
|
-
|
|
6301
|
-
L,
|
|
6302
|
-
X,
|
|
6303
|
-
A,
|
|
6299
|
+
x,
|
|
6304
6300
|
R,
|
|
6305
|
-
|
|
6301
|
+
W,
|
|
6302
|
+
A,
|
|
6303
|
+
k,
|
|
6304
|
+
I
|
|
6306
6305
|
]
|
|
6307
|
-
),
|
|
6308
|
-
(
|
|
6309
|
-
if (p ||
|
|
6310
|
-
const re =
|
|
6311
|
-
g ?
|
|
6306
|
+
), X = se(
|
|
6307
|
+
(P) => {
|
|
6308
|
+
if (p || N == null || _ == null) return;
|
|
6309
|
+
const re = x(P.clientX);
|
|
6310
|
+
g ? _ === "min" ? I(W([re, k], "min")) : _ === "max" && I(W([A, re], "max")) : I(W(re, "single"));
|
|
6312
6311
|
},
|
|
6313
6312
|
[
|
|
6314
6313
|
p,
|
|
6315
|
-
|
|
6316
|
-
|
|
6314
|
+
N,
|
|
6315
|
+
_,
|
|
6317
6316
|
g,
|
|
6318
|
-
|
|
6319
|
-
|
|
6317
|
+
x,
|
|
6318
|
+
W,
|
|
6320
6319
|
A,
|
|
6321
|
-
|
|
6322
|
-
|
|
6320
|
+
k,
|
|
6321
|
+
I
|
|
6323
6322
|
]
|
|
6324
|
-
),
|
|
6325
|
-
|
|
6326
|
-
}, [
|
|
6327
|
-
(
|
|
6323
|
+
), ce = se(() => {
|
|
6324
|
+
_ != null && (L(null), H(null), ve());
|
|
6325
|
+
}, [_, ve]), E = se(
|
|
6326
|
+
(P, re) => {
|
|
6328
6327
|
if (p) return;
|
|
6329
|
-
const oe = g ? re === "min" ? A :
|
|
6328
|
+
const oe = g ? re === "min" ? A : k : b;
|
|
6330
6329
|
let ge = oe;
|
|
6331
|
-
const
|
|
6332
|
-
switch (
|
|
6330
|
+
const q = (l - i) / 10;
|
|
6331
|
+
switch (P.key) {
|
|
6333
6332
|
case "ArrowLeft":
|
|
6334
6333
|
case "ArrowDown":
|
|
6335
6334
|
ge = oe - s;
|
|
@@ -6339,10 +6338,10 @@ const Yi = rr(function({
|
|
|
6339
6338
|
ge = oe + s;
|
|
6340
6339
|
break;
|
|
6341
6340
|
case "PageDown":
|
|
6342
|
-
ge = oe -
|
|
6341
|
+
ge = oe - q;
|
|
6343
6342
|
break;
|
|
6344
6343
|
case "PageUp":
|
|
6345
|
-
ge = oe +
|
|
6344
|
+
ge = oe + q;
|
|
6346
6345
|
break;
|
|
6347
6346
|
case "Home":
|
|
6348
6347
|
ge = i;
|
|
@@ -6353,19 +6352,19 @@ const Yi = rr(function({
|
|
|
6353
6352
|
default:
|
|
6354
6353
|
return;
|
|
6355
6354
|
}
|
|
6356
|
-
|
|
6355
|
+
P.preventDefault(), I(g ? re === "min" ? W([ge, k], "min") : W([A, ge], "max") : W(ge, "single"), !1), o == null || o(w ? n : $);
|
|
6357
6356
|
},
|
|
6358
6357
|
[
|
|
6359
6358
|
p,
|
|
6360
6359
|
g,
|
|
6361
6360
|
b,
|
|
6362
6361
|
A,
|
|
6363
|
-
|
|
6362
|
+
k,
|
|
6364
6363
|
s,
|
|
6365
6364
|
i,
|
|
6366
6365
|
l,
|
|
6367
|
-
|
|
6368
|
-
|
|
6366
|
+
W,
|
|
6367
|
+
I,
|
|
6369
6368
|
o,
|
|
6370
6369
|
w,
|
|
6371
6370
|
n,
|
|
@@ -6373,42 +6372,42 @@ const Yi = rr(function({
|
|
|
6373
6372
|
]
|
|
6374
6373
|
);
|
|
6375
6374
|
return pe(() => {
|
|
6376
|
-
if (!
|
|
6377
|
-
const
|
|
6375
|
+
if (!_) return;
|
|
6376
|
+
const P = document.body.style.userSelect;
|
|
6378
6377
|
return document.body.style.userSelect = "none", () => {
|
|
6379
|
-
document.body.style.userSelect =
|
|
6378
|
+
document.body.style.userSelect = P;
|
|
6380
6379
|
};
|
|
6381
|
-
}, [
|
|
6380
|
+
}, [_]), /* @__PURE__ */ a.jsx("div", { className: `w-full ${m}`, children: /* @__PURE__ */ a.jsxs("div", { className: "relative flex items-center", children: [
|
|
6382
6381
|
g && /* @__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: A }) }) }),
|
|
6383
6382
|
/* @__PURE__ */ a.jsxs("div", { className: "w-full", children: [
|
|
6384
6383
|
/* @__PURE__ */ a.jsxs(
|
|
6385
6384
|
"div",
|
|
6386
6385
|
{
|
|
6387
|
-
ref:
|
|
6386
|
+
ref: j,
|
|
6388
6387
|
className: `
|
|
6389
|
-
relative w-full ${
|
|
6388
|
+
relative w-full ${K.track} ${T.track} rounded-full
|
|
6390
6389
|
${p ? "opacity-60 cursor-not-allowed" : "cursor-pointer"}
|
|
6391
6390
|
`,
|
|
6392
|
-
onPointerDown: (
|
|
6393
|
-
onPointerMove:
|
|
6394
|
-
onPointerUp:
|
|
6395
|
-
onPointerCancel:
|
|
6391
|
+
onPointerDown: (P) => U(P),
|
|
6392
|
+
onPointerMove: X,
|
|
6393
|
+
onPointerUp: ce,
|
|
6394
|
+
onPointerCancel: ce,
|
|
6396
6395
|
children: [
|
|
6397
6396
|
g ? /* @__PURE__ */ a.jsx(
|
|
6398
6397
|
"div",
|
|
6399
6398
|
{
|
|
6400
|
-
className: `absolute top-0 ${
|
|
6401
|
-
style: { left: `${de}%`, width: `${
|
|
6399
|
+
className: `absolute top-0 ${K.track} ${T.progress} rounded-full ${_ ? "" : "transition-all duration-150"}`,
|
|
6400
|
+
style: { left: `${de}%`, width: `${z - de}%` }
|
|
6402
6401
|
}
|
|
6403
6402
|
) : /* @__PURE__ */ a.jsx(
|
|
6404
6403
|
"div",
|
|
6405
6404
|
{
|
|
6406
|
-
className: `absolute top-0 left-0 ${
|
|
6407
|
-
style: { width: `${
|
|
6405
|
+
className: `absolute top-0 left-0 ${K.track} ${T.progress} rounded-full ${_ ? "" : "transition-all duration-150"}`,
|
|
6406
|
+
style: { width: `${J}%` }
|
|
6408
6407
|
}
|
|
6409
6408
|
),
|
|
6410
|
-
f && v.map((
|
|
6411
|
-
const oe =
|
|
6409
|
+
f && v.map((P, re) => {
|
|
6410
|
+
const oe = Z(P.value);
|
|
6412
6411
|
return /* @__PURE__ */ a.jsx(
|
|
6413
6412
|
"div",
|
|
6414
6413
|
{
|
|
@@ -6423,13 +6422,13 @@ const Yi = rr(function({
|
|
|
6423
6422
|
{
|
|
6424
6423
|
className: `
|
|
6425
6424
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2
|
|
6426
|
-
${
|
|
6425
|
+
${K.thumb} ${T.thumb} ${T.thumbHover} ${T.thumbActive}
|
|
6427
6426
|
rounded-full border-2 ${p ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6428
|
-
${
|
|
6429
|
-
${
|
|
6427
|
+
${_ === "single" ? "cursor-grabbing scale-110" : _ ? "" : "transition-all duration-150"}
|
|
6428
|
+
${B === "single" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6430
6429
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6431
6430
|
`,
|
|
6432
|
-
style: { left: `${
|
|
6431
|
+
style: { left: `${J}%` },
|
|
6433
6432
|
tabIndex: p ? -1 : 0,
|
|
6434
6433
|
role: "slider",
|
|
6435
6434
|
"aria-orientation": "horizontal",
|
|
@@ -6437,10 +6436,10 @@ const Yi = rr(function({
|
|
|
6437
6436
|
"aria-valuemax": l,
|
|
6438
6437
|
"aria-valuenow": b,
|
|
6439
6438
|
"aria-disabled": p,
|
|
6440
|
-
onKeyDown: (
|
|
6441
|
-
onFocus: () =>
|
|
6442
|
-
onBlur: () =>
|
|
6443
|
-
onPointerDown: (
|
|
6439
|
+
onKeyDown: (P) => E(P, "single"),
|
|
6440
|
+
onFocus: () => M("single"),
|
|
6441
|
+
onBlur: () => M(null),
|
|
6442
|
+
onPointerDown: (P) => U(P, "single")
|
|
6444
6443
|
}
|
|
6445
6444
|
),
|
|
6446
6445
|
g && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
@@ -6449,10 +6448,10 @@ const Yi = rr(function({
|
|
|
6449
6448
|
{
|
|
6450
6449
|
className: `
|
|
6451
6450
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2 z-10
|
|
6452
|
-
${
|
|
6451
|
+
${K.thumb} ${T.thumb} ${T.thumbHover} ${T.thumbActive}
|
|
6453
6452
|
rounded-full border-2 ${p ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6454
|
-
${
|
|
6455
|
-
${
|
|
6453
|
+
${_ === "min" ? "cursor-grabbing scale-110 z-20" : _ ? "" : "transition-all duration-150"}
|
|
6454
|
+
${B === "min" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6456
6455
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6457
6456
|
`,
|
|
6458
6457
|
style: { left: `${de}%` },
|
|
@@ -6464,10 +6463,10 @@ const Yi = rr(function({
|
|
|
6464
6463
|
"aria-valuenow": A,
|
|
6465
6464
|
"aria-disabled": p,
|
|
6466
6465
|
"aria-label": "Minimum value",
|
|
6467
|
-
onKeyDown: (
|
|
6468
|
-
onFocus: () =>
|
|
6469
|
-
onBlur: () =>
|
|
6470
|
-
onPointerDown: (
|
|
6466
|
+
onKeyDown: (P) => E(P, "min"),
|
|
6467
|
+
onFocus: () => M("min"),
|
|
6468
|
+
onBlur: () => M(null),
|
|
6469
|
+
onPointerDown: (P) => U(P, "min")
|
|
6471
6470
|
}
|
|
6472
6471
|
),
|
|
6473
6472
|
/* @__PURE__ */ a.jsx(
|
|
@@ -6475,25 +6474,25 @@ const Yi = rr(function({
|
|
|
6475
6474
|
{
|
|
6476
6475
|
className: `
|
|
6477
6476
|
absolute top-1/2 transform -translate-y-1/2 -translate-x-1/2 z-10
|
|
6478
|
-
${
|
|
6477
|
+
${K.thumb} ${T.thumb} ${T.thumbHover} ${T.thumbActive}
|
|
6479
6478
|
rounded-full border-2 ${p ? "opacity-60 cursor-not-allowed" : "cursor-grab"}
|
|
6480
|
-
${
|
|
6481
|
-
${
|
|
6479
|
+
${_ === "max" ? "cursor-grabbing scale-110 z-20" : _ ? "" : "transition-all duration-150"}
|
|
6480
|
+
${B === "max" ? "ring-2 ring-offset-1 ring-blue-300" : ""}
|
|
6482
6481
|
shadow-md hover:shadow-lg focus:outline-none dark:shadow-none
|
|
6483
6482
|
`,
|
|
6484
|
-
style: { left: `${
|
|
6483
|
+
style: { left: `${z}%` },
|
|
6485
6484
|
tabIndex: p ? -1 : 0,
|
|
6486
6485
|
role: "slider",
|
|
6487
6486
|
"aria-orientation": "horizontal",
|
|
6488
6487
|
"aria-valuemin": i,
|
|
6489
6488
|
"aria-valuemax": l,
|
|
6490
|
-
"aria-valuenow":
|
|
6489
|
+
"aria-valuenow": k,
|
|
6491
6490
|
"aria-disabled": p,
|
|
6492
6491
|
"aria-label": "Maximum value",
|
|
6493
|
-
onKeyDown: (
|
|
6494
|
-
onFocus: () =>
|
|
6495
|
-
onBlur: () =>
|
|
6496
|
-
onPointerDown: (
|
|
6492
|
+
onKeyDown: (P) => E(P, "max"),
|
|
6493
|
+
onFocus: () => M("max"),
|
|
6494
|
+
onBlur: () => M(null),
|
|
6495
|
+
onPointerDown: (P) => U(P, "max")
|
|
6497
6496
|
}
|
|
6498
6497
|
)
|
|
6499
6498
|
] })
|
|
@@ -6504,14 +6503,14 @@ const Yi = rr(function({
|
|
|
6504
6503
|
"div",
|
|
6505
6504
|
{
|
|
6506
6505
|
className: "relative mt-2 text-xs text-color-gray-500 dark:text-color-gray-200",
|
|
6507
|
-
children: v.map((
|
|
6508
|
-
const oe =
|
|
6506
|
+
children: v.map((P, re) => {
|
|
6507
|
+
const oe = Z(P.value);
|
|
6509
6508
|
return /* @__PURE__ */ a.jsx(
|
|
6510
6509
|
"div",
|
|
6511
6510
|
{
|
|
6512
6511
|
className: "absolute transform -translate-x-1/2 text-xs",
|
|
6513
6512
|
style: { left: `${oe}%` },
|
|
6514
|
-
children:
|
|
6513
|
+
children: P.label || P.value
|
|
6515
6514
|
},
|
|
6516
6515
|
re
|
|
6517
6516
|
);
|
|
@@ -6519,7 +6518,7 @@ const Yi = rr(function({
|
|
|
6519
6518
|
}
|
|
6520
6519
|
)
|
|
6521
6520
|
] }),
|
|
6522
|
-
u && /* @__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: g ? /* @__PURE__ */ a.jsx("div", { className: "range-max", children: /* @__PURE__ */ a.jsx("div", { children:
|
|
6521
|
+
u && /* @__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: g ? /* @__PURE__ */ a.jsx("div", { className: "range-max", children: /* @__PURE__ */ a.jsx("div", { children: k }) }) : /* @__PURE__ */ a.jsx("span", { children: b }) })
|
|
6523
6522
|
] }) });
|
|
6524
6523
|
}), Zi = ({
|
|
6525
6524
|
open: e = !1,
|
|
@@ -6546,7 +6545,7 @@ const Yi = rr(function({
|
|
|
6546
6545
|
if (e)
|
|
6547
6546
|
return document.addEventListener("keydown", u), () => document.removeEventListener("keydown", u);
|
|
6548
6547
|
}, [e, i]);
|
|
6549
|
-
const c =
|
|
6548
|
+
const c = se(() => {
|
|
6550
6549
|
i && i();
|
|
6551
6550
|
}, [i]), d = (u) => {
|
|
6552
6551
|
const f = "fixed z-50 transform transition-all duration-300 ease-in-out";
|
|
@@ -6713,25 +6712,25 @@ const Yi = rr(function({
|
|
|
6713
6712
|
}) => {
|
|
6714
6713
|
const [f, v] = ke.useState(null), g = (y, $) => {
|
|
6715
6714
|
if (t || r || !n) return;
|
|
6716
|
-
const { left: b, width: A } = y.target.getBoundingClientRect(),
|
|
6717
|
-
let
|
|
6718
|
-
|
|
6715
|
+
const { left: b, width: A } = y.target.getBoundingClientRect(), k = (y.clientX - b) / A;
|
|
6716
|
+
let T = $ - 1 + Math.ceil(k / o) * o;
|
|
6717
|
+
T = Math.min(i, Math.max(o, Math.round(T / o) * o)), n(T);
|
|
6719
6718
|
}, h = (y, $) => {
|
|
6720
6719
|
if (t || r) return;
|
|
6721
|
-
const { left: b, width: A } = y.target.getBoundingClientRect(),
|
|
6722
|
-
let
|
|
6723
|
-
|
|
6720
|
+
const { left: b, width: A } = y.target.getBoundingClientRect(), k = (y.clientX - b) / A;
|
|
6721
|
+
let T = $ - 1 + Math.ceil(k / o) * o;
|
|
6722
|
+
T = Math.min(i, Math.max(o, Math.round(T / o) * o)), v(T);
|
|
6724
6723
|
}, w = () => v(null), S = [];
|
|
6725
6724
|
for (let y = 1; y <= i; y++) {
|
|
6726
6725
|
let $ = (f !== null ? f : e) >= y, b = !$ && (f !== null ? f : e) > y - 1, A = $ ? s || ke.cloneElement(Cn, { className: `fill-color-yellow-500 ${tt[l]}` }) : c || ke.cloneElement(jn, { className: `stroke-color-gray-300 ${tt[l]}` });
|
|
6727
6726
|
if (b) {
|
|
6728
|
-
const
|
|
6727
|
+
const k = ((f !== null ? f : e) - (y - 1)) * 100;
|
|
6729
6728
|
A = /* @__PURE__ */ a.jsxs("span", { className: "relative block", children: [
|
|
6730
6729
|
/* @__PURE__ */ a.jsx(
|
|
6731
6730
|
"span",
|
|
6732
6731
|
{
|
|
6733
6732
|
className: "absolute top-0 left-0 overflow-hidden",
|
|
6734
|
-
style: { width: `${
|
|
6733
|
+
style: { width: `${k}%` },
|
|
6735
6734
|
children: s || ke.cloneElement(Cn, {
|
|
6736
6735
|
className: `fill-color-yellow-500 ${tt[l]}`
|
|
6737
6736
|
})
|
|
@@ -6747,8 +6746,8 @@ const Yi = rr(function({
|
|
|
6747
6746
|
"span",
|
|
6748
6747
|
{
|
|
6749
6748
|
className: `inline-block ${r ? "opacity-50 cursor-not-allowed" : "cursor-pointer"}`,
|
|
6750
|
-
onClick: (
|
|
6751
|
-
onMouseMove: (
|
|
6749
|
+
onClick: (k) => g(k, y),
|
|
6750
|
+
onMouseMove: (k) => h(k, y),
|
|
6752
6751
|
onMouseLeave: w,
|
|
6753
6752
|
tabIndex: t || r ? -1 : 0,
|
|
6754
6753
|
"aria-label": `Rate ${y}`,
|
|
@@ -6808,31 +6807,31 @@ const Yi = rr(function({
|
|
|
6808
6807
|
tablet: $,
|
|
6809
6808
|
desktop: b
|
|
6810
6809
|
}) => {
|
|
6811
|
-
const A = hi(),
|
|
6810
|
+
const A = hi(), k = ze(
|
|
6812
6811
|
y == null ? void 0 : y.perview,
|
|
6813
6812
|
$ == null ? void 0 : $.perview,
|
|
6814
6813
|
b == null ? void 0 : b.perview,
|
|
6815
6814
|
c,
|
|
6816
6815
|
A
|
|
6817
|
-
),
|
|
6816
|
+
), T = ze(
|
|
6818
6817
|
y == null ? void 0 : y.gap,
|
|
6819
6818
|
$ == null ? void 0 : $.gap,
|
|
6820
6819
|
b == null ? void 0 : b.gap,
|
|
6821
6820
|
d,
|
|
6822
6821
|
A
|
|
6823
|
-
),
|
|
6822
|
+
), K = ze(
|
|
6824
6823
|
y == null ? void 0 : y.showArrows,
|
|
6825
6824
|
$ == null ? void 0 : $.showArrows,
|
|
6826
6825
|
b == null ? void 0 : b.showArrows,
|
|
6827
6826
|
o,
|
|
6828
6827
|
A
|
|
6829
|
-
),
|
|
6828
|
+
), Z = ze(
|
|
6830
6829
|
y == null ? void 0 : y.showIndicators,
|
|
6831
6830
|
$ == null ? void 0 : $.showIndicators,
|
|
6832
6831
|
b == null ? void 0 : b.showIndicators,
|
|
6833
6832
|
r,
|
|
6834
6833
|
A
|
|
6835
|
-
),
|
|
6834
|
+
), J = ze(
|
|
6836
6835
|
y == null ? void 0 : y.showThumbs,
|
|
6837
6836
|
$ == null ? void 0 : $.showThumbs,
|
|
6838
6837
|
b == null ? void 0 : b.showThumbs,
|
|
@@ -6844,51 +6843,51 @@ const Yi = rr(function({
|
|
|
6844
6843
|
b == null ? void 0 : b.swipeable,
|
|
6845
6844
|
f,
|
|
6846
6845
|
A
|
|
6847
|
-
),
|
|
6848
|
-
s &&
|
|
6849
|
-
),
|
|
6850
|
-
s &&
|
|
6851
|
-
},
|
|
6852
|
-
s &&
|
|
6846
|
+
), z = e.length, O = Math.min(Math.max(k, 0.1), z), [V, Q] = ee(0), [I, ve] = ee(!1), [W, j] = ee(!1), [x, R] = ee(0), _ = me(null), L = me(0), B = me(0), M = O >= z ? 0 : Math.max(0, z - O), N = (q) => Math.max(0, Math.min(q, M)), H = (q) => Q(
|
|
6847
|
+
s && M > 0 ? (q % (M + 1) + (M + 1)) % (M + 1) : N(q)
|
|
6848
|
+
), U = () => {
|
|
6849
|
+
s && M > 0 ? Q(V === 0 ? M : V - 1) : H(V - 1);
|
|
6850
|
+
}, X = () => {
|
|
6851
|
+
s && M > 0 ? Q(V >= M ? 0 : V + 1) : H(V + 1);
|
|
6853
6852
|
};
|
|
6854
6853
|
pe(() => {
|
|
6855
|
-
if (!i || u &&
|
|
6854
|
+
if (!i || u && I || W || M === 0)
|
|
6856
6855
|
return;
|
|
6857
|
-
const
|
|
6856
|
+
const q = setInterval(() => {
|
|
6858
6857
|
Q((te) => {
|
|
6859
6858
|
const je = te + 1;
|
|
6860
|
-
return je >
|
|
6859
|
+
return je > M ? s ? 0 : te : je;
|
|
6861
6860
|
});
|
|
6862
6861
|
}, l);
|
|
6863
|
-
return () => clearInterval(
|
|
6862
|
+
return () => clearInterval(q);
|
|
6864
6863
|
}, [
|
|
6865
6864
|
i,
|
|
6866
6865
|
l,
|
|
6867
|
-
|
|
6866
|
+
I,
|
|
6868
6867
|
u,
|
|
6869
|
-
|
|
6870
|
-
|
|
6868
|
+
W,
|
|
6869
|
+
M,
|
|
6871
6870
|
s
|
|
6872
6871
|
]), pe(() => {
|
|
6873
|
-
|
|
6874
|
-
}, [
|
|
6875
|
-
const
|
|
6876
|
-
!de ||
|
|
6877
|
-
},
|
|
6878
|
-
|
|
6879
|
-
},
|
|
6880
|
-
if (!
|
|
6881
|
-
Math.abs(
|
|
6872
|
+
V > M && Q(Math.min(V, M));
|
|
6873
|
+
}, [M, V]);
|
|
6874
|
+
const ce = (q, te) => {
|
|
6875
|
+
!de || M === 0 || (j(!0), L.current = g === "horizontal" ? q : te, B.current = L.current);
|
|
6876
|
+
}, E = (q, te) => {
|
|
6877
|
+
W && (B.current = g === "horizontal" ? q : te, R(B.current - L.current));
|
|
6878
|
+
}, P = () => {
|
|
6879
|
+
if (!W) return;
|
|
6880
|
+
Math.abs(B.current - L.current) > 50 && (B.current < L.current ? X() : U()), j(!1), R(0);
|
|
6882
6881
|
}, re = () => {
|
|
6883
|
-
const
|
|
6882
|
+
const q = g === "horizontal" ? "X" : "Y";
|
|
6884
6883
|
let te = 0;
|
|
6885
|
-
if (
|
|
6886
|
-
const
|
|
6887
|
-
te =
|
|
6884
|
+
if (W && _.current && M > 0) {
|
|
6885
|
+
const F = g === "horizontal" ? _.current.offsetWidth : _.current.offsetHeight;
|
|
6886
|
+
te = x / F * 100 * (O / z);
|
|
6888
6887
|
}
|
|
6889
|
-
const Se = Math.min(
|
|
6890
|
-
return `translate${
|
|
6891
|
-
}, oe = () =>
|
|
6888
|
+
const Se = Math.min(V, M) * (100 / z) - te, C = V >= M, he = V <= 0 ? 0 : C ? T / (k / 2) : T / k;
|
|
6889
|
+
return `translate${q}(calc(-${Se}% - ${he}px))`;
|
|
6890
|
+
}, oe = () => O >= z ? 1 : Math.floor(M) + 1, ge = () => M === 0 ? 0 : Math.round(V / M * (oe() - 1));
|
|
6892
6891
|
return /* @__PURE__ */ a.jsxs(
|
|
6893
6892
|
"div",
|
|
6894
6893
|
{
|
|
@@ -6900,53 +6899,53 @@ const Yi = rr(function({
|
|
|
6900
6899
|
/* @__PURE__ */ a.jsxs(
|
|
6901
6900
|
"div",
|
|
6902
6901
|
{
|
|
6903
|
-
ref:
|
|
6904
|
-
className: `w-full overflow-hidden relative ${de &&
|
|
6902
|
+
ref: _,
|
|
6903
|
+
className: `w-full overflow-hidden relative ${de && M > 0 ? W ? "cursor-grabbing" : "cursor-grab" : "cursor-default"}`,
|
|
6905
6904
|
style: {
|
|
6906
|
-
height:
|
|
6905
|
+
height: J ? `calc(${t} - ${v + 20}px)` : t
|
|
6907
6906
|
},
|
|
6908
|
-
onMouseDown: (
|
|
6909
|
-
|
|
6907
|
+
onMouseDown: (q) => {
|
|
6908
|
+
q.preventDefault(), ce(q.clientX, q.clientY);
|
|
6910
6909
|
},
|
|
6911
|
-
onMouseMove: (
|
|
6912
|
-
onMouseUp:
|
|
6913
|
-
onMouseLeave:
|
|
6914
|
-
onTouchStart: (
|
|
6915
|
-
onTouchMove: (
|
|
6916
|
-
onTouchEnd:
|
|
6910
|
+
onMouseMove: (q) => E(q.clientX, q.clientY),
|
|
6911
|
+
onMouseUp: P,
|
|
6912
|
+
onMouseLeave: P,
|
|
6913
|
+
onTouchStart: (q) => ce(q.touches[0].clientX, q.touches[0].clientY),
|
|
6914
|
+
onTouchMove: (q) => E(q.touches[0].clientX, q.touches[0].clientY),
|
|
6915
|
+
onTouchEnd: P,
|
|
6917
6916
|
children: [
|
|
6918
6917
|
/* @__PURE__ */ a.jsx(
|
|
6919
6918
|
"div",
|
|
6920
6919
|
{
|
|
6921
6920
|
className: `flex ${g === "horizontal" ? "flex-row" : "flex-col"} transition-all duration-300 ease-in-out`,
|
|
6922
6921
|
style: {
|
|
6923
|
-
width: g === "vertical" ? "100%" : `calc(${
|
|
6924
|
-
height: g === "vertical" ? `${
|
|
6922
|
+
width: g === "vertical" ? "100%" : `calc(${z * 100 / O}% + ${(z - 1) * T}px)`,
|
|
6923
|
+
height: g === "vertical" ? `${z * 100 / O}%` : "100%",
|
|
6925
6924
|
transform: re(),
|
|
6926
|
-
gap: `${
|
|
6927
|
-
transitionProperty:
|
|
6925
|
+
gap: `${T}px`,
|
|
6926
|
+
transitionProperty: W ? "none" : "transform"
|
|
6928
6927
|
},
|
|
6929
|
-
children: e.map((
|
|
6928
|
+
children: e.map((q, te) => /* @__PURE__ */ a.jsx(
|
|
6930
6929
|
"div",
|
|
6931
6930
|
{
|
|
6932
6931
|
className: "shrink-0 flex items-center justify-center",
|
|
6933
6932
|
style: {
|
|
6934
|
-
width: g === "horizontal" ? `calc(${100 /
|
|
6935
|
-
height: g === "vertical" ? `calc(${100 /
|
|
6933
|
+
width: g === "horizontal" ? `calc(${100 / z}% - ${T / k}px)` : "100%",
|
|
6934
|
+
height: g === "vertical" ? `calc(${100 / z}% - ${T * (z - 1) / z}px)` : "100%"
|
|
6936
6935
|
},
|
|
6937
|
-
onClick: () => !
|
|
6938
|
-
children:
|
|
6936
|
+
onClick: () => !W && (p == null ? void 0 : p(te)),
|
|
6937
|
+
children: q
|
|
6939
6938
|
},
|
|
6940
6939
|
te
|
|
6941
6940
|
))
|
|
6942
6941
|
}
|
|
6943
6942
|
),
|
|
6944
|
-
|
|
6943
|
+
K && M > 0 && /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
6945
6944
|
/* @__PURE__ */ a.jsx(
|
|
6946
6945
|
"button",
|
|
6947
6946
|
{
|
|
6948
6947
|
"aria-label": "prev",
|
|
6949
|
-
onClick:
|
|
6948
|
+
onClick: U,
|
|
6950
6949
|
className: `absolute z-20 bg-color-white/80 border border-color-gray-300 rounded-full w-8 h-8 md:w-10 md:h-10 flex items-center justify-center text-sm md:text-lg font-bold text-color-gray-800 hover:bg-color-white transition-color cursor-pointer
|
|
6951
6950
|
${g === "horizontal" ? "left-1 md:left-2 top-1/2 -translate-y-1/2" : "left-1/2 top-1 md:top-2 -translate-x-1/2"}`,
|
|
6952
6951
|
children: w || (g === "horizontal" ? "‹" : "↑")
|
|
@@ -6956,24 +6955,24 @@ const Yi = rr(function({
|
|
|
6956
6955
|
"button",
|
|
6957
6956
|
{
|
|
6958
6957
|
"aria-label": "next",
|
|
6959
|
-
onClick:
|
|
6958
|
+
onClick: X,
|
|
6960
6959
|
className: `absolute z-20 bg-color-white/80 border border-color-gray-300 rounded-full w-8 h-8 md:w-10 md:h-10 flex items-center justify-center text-sm md:text-lg font-bold text-color-gray-800 hover:bg-color-white transition-color cursor-pointer
|
|
6961
6960
|
${g === "horizontal" ? "right-1 md:right-2 top-1/2 -translate-y-1/2" : "left-1/2 bottom-1 md:bottom-2 -translate-x-1/2"}`,
|
|
6962
6961
|
children: h || (g === "horizontal" ? "›" : "↓")
|
|
6963
6962
|
}
|
|
6964
6963
|
)
|
|
6965
6964
|
] }),
|
|
6966
|
-
|
|
6965
|
+
Z && oe() > 1 && /* @__PURE__ */ a.jsx(
|
|
6967
6966
|
"div",
|
|
6968
6967
|
{
|
|
6969
6968
|
className: `uniui-indicator flex gap-1 mt-2 md:mt-3 justify-center absolute bg-color-white/90 py-1 px-[5px] rounded-full ${g === "horizontal" ? "bottom-2 md:bottom-3 left-1/2 -translate-x-1/2" : "top-1/2 right-2 md:right-3 -translate-y-1/2 rotate-90"} z-10`,
|
|
6970
6969
|
children: Array.from({ length: oe() }).map(
|
|
6971
|
-
(
|
|
6970
|
+
(q, te) => /* @__PURE__ */ a.jsx(
|
|
6972
6971
|
"button",
|
|
6973
6972
|
{
|
|
6974
|
-
onClick: () =>
|
|
6973
|
+
onClick: () => H(
|
|
6975
6974
|
Math.round(
|
|
6976
|
-
te / (oe() - 1) *
|
|
6975
|
+
te / (oe() - 1) * M
|
|
6977
6976
|
)
|
|
6978
6977
|
),
|
|
6979
6978
|
className: `w-2 h-2 md:w-[10px] md:h-[10px] rounded-full transition-color hover:bg-color-gray-600 cursor-pointer ${te === ge() ? "bg-color-gray-800" : "bg-color-gray-400"}`
|
|
@@ -6986,8 +6985,8 @@ const Yi = rr(function({
|
|
|
6986
6985
|
]
|
|
6987
6986
|
}
|
|
6988
6987
|
),
|
|
6989
|
-
|
|
6990
|
-
const je = te === Math.round(
|
|
6988
|
+
J && /* @__PURE__ */ a.jsx("div", { className: "uniui-thumb flex gap-1 md:gap-2 mt-2 md:mt-3 justify-center flex-wrap", children: e.map((q, te) => {
|
|
6989
|
+
const je = te === Math.round(V), Se = A === "mobile" ? v * 0.8 : v;
|
|
6991
6990
|
return /* @__PURE__ */ a.jsx(
|
|
6992
6991
|
"div",
|
|
6993
6992
|
{
|
|
@@ -6995,18 +6994,18 @@ const Yi = rr(function({
|
|
|
6995
6994
|
const C = Math.max(
|
|
6996
6995
|
0,
|
|
6997
6996
|
Math.min(
|
|
6998
|
-
|
|
6999
|
-
te - Math.floor(
|
|
6997
|
+
M,
|
|
6998
|
+
te - Math.floor(O / 2)
|
|
7000
6999
|
)
|
|
7001
7000
|
);
|
|
7002
|
-
|
|
7001
|
+
H(C);
|
|
7003
7002
|
},
|
|
7004
7003
|
className: `overflow-hidden rounded-md cursor-pointer transition-all hover:opacity-100 ${je ? "border-2 border-color-gray-800 opacity-100 scale-105" : "border-2 border-color-gray-300 opacity-70"}`,
|
|
7005
7004
|
style: {
|
|
7006
7005
|
width: Se,
|
|
7007
7006
|
height: Se
|
|
7008
7007
|
},
|
|
7009
|
-
children:
|
|
7008
|
+
children: q
|
|
7010
7009
|
},
|
|
7011
7010
|
te
|
|
7012
7011
|
);
|
|
@@ -7513,8 +7512,8 @@ function oa({ items: e, trigger: n, className: t, dropdownItemClass: r, position
|
|
|
7513
7512
|
if (o === "fixed")
|
|
7514
7513
|
S + g.width > h && (S = h - g.width - 12), S < 12 && (S = 12), y + g.height > w && (y = b - g.height), y < 12 && (y = 12);
|
|
7515
7514
|
else {
|
|
7516
|
-
const A = window.scrollX,
|
|
7517
|
-
S - A + g.width > h && (S = A + h - g.width - 12), S < A + 12 && (S = A + 12), y -
|
|
7515
|
+
const A = window.scrollX, k = window.scrollY;
|
|
7516
|
+
S - A + g.width > h && (S = A + h - g.width - 12), S < A + 12 && (S = A + 12), y - k + g.height > w && (y = b - g.height), y < k + 12 && (y = k + 12);
|
|
7518
7517
|
}
|
|
7519
7518
|
(S !== $ || y !== b) && c({ top: y, left: S }), setTimeout(() => {
|
|
7520
7519
|
p(!0);
|
|
@@ -7849,29 +7848,29 @@ const $i = ({
|
|
|
7849
7848
|
minimumDate: w,
|
|
7850
7849
|
maxDate: S
|
|
7851
7850
|
}) => {
|
|
7852
|
-
const [y, $] = ee(!1), [b, A] = ee(null), [
|
|
7851
|
+
const [y, $] = ee(!1), [b, A] = ee(null), [k, T] = ee(
|
|
7853
7852
|
g || h ? /* @__PURE__ */ new Date() : v ? new Date(typeof v == "string" ? parseInt(v) : v) : /* @__PURE__ */ new Date()
|
|
7854
|
-
), [
|
|
7853
|
+
), [K, Z] = ee(
|
|
7855
7854
|
u ? new Date(u) : v && !u ? new Date(typeof v == "string" ? parseInt(v) : v) : null
|
|
7856
|
-
), [
|
|
7855
|
+
), [J, de] = ee(g ? new Date(g) : null), [z, O] = ee(h ? new Date(h) : null), [V, Q] = ee(null), [I, ve] = ee({ hour: 12, minute: 0, ampm: "AM" }), W = me(null), [j, x] = ee(
|
|
7857
7856
|
u ? new Date(u) : v && !u ? new Date(typeof v == "string" ? parseInt(v) : v) : null
|
|
7858
|
-
), [
|
|
7857
|
+
), [R, _] = ee(g ? new Date(g) : null), [L, B] = ee(h ? new Date(h) : null);
|
|
7859
7858
|
pe(() => {
|
|
7860
7859
|
if (u)
|
|
7861
|
-
|
|
7860
|
+
Z(new Date(u)), x(new Date(u));
|
|
7862
7861
|
else if (!u && v) {
|
|
7863
7862
|
const C = new Date(typeof v == "string" ? parseInt(v) : v);
|
|
7864
|
-
|
|
7863
|
+
Z(C), x(C);
|
|
7865
7864
|
} else
|
|
7866
|
-
|
|
7865
|
+
Z(null), x(null);
|
|
7867
7866
|
}, [u, v]), pe(() => {
|
|
7868
|
-
g && (de(new Date(g)),
|
|
7867
|
+
g && (de(new Date(g)), _(new Date(g)), Z(new Date(g)), x(new Date(g)));
|
|
7869
7868
|
}, [g]), pe(() => {
|
|
7870
|
-
h && (
|
|
7869
|
+
h && (O(new Date(h)), B(new Date(h)), Z(new Date(h)), x(new Date(h)));
|
|
7871
7870
|
}, [h]);
|
|
7872
|
-
const
|
|
7873
|
-
C.stopPropagation(), A(C.currentTarget), $(!0),
|
|
7874
|
-
},
|
|
7871
|
+
const M = (C) => {
|
|
7872
|
+
C.stopPropagation(), A(C.currentTarget), $(!0), j ? T(new Date(j)) : v && !j && T(new Date(typeof v == "string" ? parseInt(v) : v));
|
|
7873
|
+
}, N = (C) => {
|
|
7875
7874
|
if (p && C.getTime() < p || m && C.getTime() > m || f && C.getTime() > (/* @__PURE__ */ new Date()).setHours(23, 59, 59, 999)) return !0;
|
|
7876
7875
|
if (S) {
|
|
7877
7876
|
const ie = typeof S == "string" ? new Date(S) : typeof S == "number" ? new Date(S) : S;
|
|
@@ -7882,102 +7881,102 @@ const $i = ({
|
|
|
7882
7881
|
if (C.getTime() < ie.getTime()) return !0;
|
|
7883
7882
|
}
|
|
7884
7883
|
return !1;
|
|
7885
|
-
},
|
|
7886
|
-
n === "inline" &&
|
|
7884
|
+
}, H = (C) => {
|
|
7885
|
+
n === "inline" && W.current && !W.current.contains(C.target) && (e === "single" ? K || Z(null) : e === "range" && (!J || !z) && (de(null), O(null)), $(!1));
|
|
7887
7886
|
};
|
|
7888
|
-
pe(() => (y ? document.addEventListener("mousedown",
|
|
7889
|
-
document.removeEventListener("mousedown",
|
|
7887
|
+
pe(() => (y ? document.addEventListener("mousedown", H) : document.removeEventListener("mousedown", H), () => {
|
|
7888
|
+
document.removeEventListener("mousedown", H);
|
|
7890
7889
|
}), [y]);
|
|
7891
|
-
const
|
|
7892
|
-
!C ||
|
|
7893
|
-
},
|
|
7894
|
-
if (!C ||
|
|
7890
|
+
const U = (C) => {
|
|
7891
|
+
!C || N(C) || (e === "single" ? Z(C) : e === "range" && (!J || J && z ? (de(C), O(null)) : C >= J ? O(C) : de(C)));
|
|
7892
|
+
}, X = (C) => {
|
|
7893
|
+
if (!C || N(C)) {
|
|
7895
7894
|
Q(null);
|
|
7896
7895
|
return;
|
|
7897
7896
|
}
|
|
7898
|
-
e === "range" &&
|
|
7899
|
-
},
|
|
7897
|
+
e === "range" && J && !z && Q(C);
|
|
7898
|
+
}, ce = () => {
|
|
7900
7899
|
Q(null);
|
|
7901
|
-
},
|
|
7900
|
+
}, E = () => {
|
|
7902
7901
|
if ($(!1), e === "single") {
|
|
7903
|
-
const C = r ? /* @__PURE__ */ new Date() :
|
|
7902
|
+
const C = r ? /* @__PURE__ */ new Date() : K, ie = C ? new Date(
|
|
7904
7903
|
C.getFullYear(),
|
|
7905
7904
|
C.getMonth(),
|
|
7906
7905
|
C.getDate(),
|
|
7907
|
-
|
|
7908
|
-
|
|
7906
|
+
I.ampm === "PM" && I.hour !== 12 ? I.hour + 12 : I.ampm === "AM" && I.hour === 12 ? 0 : I.hour,
|
|
7907
|
+
I.minute
|
|
7909
7908
|
) : null;
|
|
7910
|
-
|
|
7909
|
+
x(ie);
|
|
7911
7910
|
const he = ie ? ie.getTime() : null;
|
|
7912
7911
|
i == null || i(he), l == null || l(he);
|
|
7913
7912
|
} else if (e === "range") {
|
|
7914
|
-
|
|
7913
|
+
_(J), B(z);
|
|
7915
7914
|
const C = {
|
|
7916
|
-
startDate:
|
|
7917
|
-
endDate:
|
|
7915
|
+
startDate: J ? J.getTime() : null,
|
|
7916
|
+
endDate: z ? z.getTime() : null
|
|
7918
7917
|
};
|
|
7919
7918
|
i == null || i(C), l == null || l(C);
|
|
7920
7919
|
}
|
|
7921
|
-
},
|
|
7922
|
-
$(!1),
|
|
7920
|
+
}, P = () => {
|
|
7921
|
+
$(!1), Z(j), de(R), O(L), T(j ? new Date(j) : /* @__PURE__ */ new Date()), s == null || s();
|
|
7923
7922
|
}, re = () => {
|
|
7924
|
-
const C = new Date(
|
|
7925
|
-
for (let ne = 0; ne <
|
|
7926
|
-
|
|
7923
|
+
const C = new Date(k.getFullYear(), k.getMonth(), 1), ie = new Date(k.getFullYear(), k.getMonth() + 1, 0), he = (/* @__PURE__ */ new Date()).setHours(23, 59, 59, 999), F = [], D = C.getDay();
|
|
7924
|
+
for (let ne = 0; ne < D; ne++)
|
|
7925
|
+
F.push(null);
|
|
7927
7926
|
for (let ne = 1; ne <= ie.getDate(); ne++) {
|
|
7928
|
-
const xe = new Date(
|
|
7929
|
-
f && xe.getTime() > he ||
|
|
7927
|
+
const xe = new Date(k.getFullYear(), k.getMonth(), ne);
|
|
7928
|
+
f && xe.getTime() > he || F.push(xe);
|
|
7930
7929
|
}
|
|
7931
|
-
return
|
|
7930
|
+
return F;
|
|
7932
7931
|
}, oe = () => {
|
|
7933
7932
|
if (w) {
|
|
7934
7933
|
const C = typeof w == "string" ? new Date(w) : typeof w == "number" ? new Date(w) : w;
|
|
7935
|
-
if (
|
|
7934
|
+
if (k.getFullYear() < C.getFullYear() || k.getFullYear() === C.getFullYear() && k.getMonth() <= C.getMonth()) return !1;
|
|
7936
7935
|
}
|
|
7937
7936
|
if (p) {
|
|
7938
7937
|
const C = new Date(p);
|
|
7939
|
-
if (
|
|
7938
|
+
if (k.getFullYear() < C.getFullYear() || k.getFullYear() === C.getFullYear() && k.getMonth() <= C.getMonth()) return !1;
|
|
7940
7939
|
}
|
|
7941
7940
|
return !0;
|
|
7942
7941
|
}, ge = () => {
|
|
7943
7942
|
if (S) {
|
|
7944
7943
|
const C = typeof S == "string" ? new Date(S) : typeof S == "number" ? new Date(S) : S;
|
|
7945
|
-
if (
|
|
7944
|
+
if (k.getFullYear() > C.getFullYear() || k.getFullYear() === C.getFullYear() && k.getMonth() >= C.getMonth()) return !1;
|
|
7946
7945
|
}
|
|
7947
7946
|
if (m) {
|
|
7948
7947
|
const C = new Date(m);
|
|
7949
|
-
if (
|
|
7948
|
+
if (k.getFullYear() > C.getFullYear() || k.getFullYear() === C.getFullYear() && k.getMonth() >= C.getMonth()) return !1;
|
|
7950
7949
|
}
|
|
7951
7950
|
if (f) {
|
|
7952
7951
|
const C = /* @__PURE__ */ new Date();
|
|
7953
|
-
if (
|
|
7952
|
+
if (k.getFullYear() > C.getFullYear() || k.getFullYear() === C.getFullYear() && k.getMonth() >= C.getMonth()) return !1;
|
|
7954
7953
|
}
|
|
7955
7954
|
return !0;
|
|
7956
|
-
},
|
|
7955
|
+
}, q = (C) => {
|
|
7957
7956
|
if (!C) return !1;
|
|
7958
7957
|
if (e === "single")
|
|
7959
|
-
return (
|
|
7958
|
+
return (K == null ? void 0 : K.toDateString()) === C.toDateString();
|
|
7960
7959
|
if (e === "range") {
|
|
7961
|
-
if (
|
|
7962
|
-
const ie =
|
|
7960
|
+
if (J && !z && V) {
|
|
7961
|
+
const ie = J < V ? J : V, he = J < V ? V : J;
|
|
7963
7962
|
return C >= ie && C <= he;
|
|
7964
7963
|
}
|
|
7965
|
-
return
|
|
7964
|
+
return J && z && C >= J && C <= z;
|
|
7966
7965
|
}
|
|
7967
7966
|
return !1;
|
|
7968
7967
|
}, te = (C, ie) => {
|
|
7969
7968
|
if (!C)
|
|
7970
|
-
return e === "range" ? ie === "end" ? "End Date" : "Start Date" : r ? `${String(
|
|
7969
|
+
return e === "range" ? ie === "end" ? "End Date" : "Start Date" : r ? `${String(I.hour).padStart(2, "0")}:${String(I.minute).padStart(2, "0")} ${I.ampm}` : c;
|
|
7971
7970
|
if (r)
|
|
7972
|
-
return `${String(
|
|
7973
|
-
const he = C.getDate().toString().padStart(2, "0"),
|
|
7974
|
-
return `${he} ${
|
|
7971
|
+
return `${String(I.hour).padStart(2, "0")}:${String(I.minute).padStart(2, "0")} ${I.ampm}`;
|
|
7972
|
+
const he = C.getDate().toString().padStart(2, "0"), F = kn[C.getMonth()], D = C.getFullYear(), ne = t ? ` ${String(I.hour).padStart(2, "0")}:${String(I.minute).padStart(2, "0")} ${I.ampm}` : "";
|
|
7973
|
+
return `${he} ${F} ${D}${ne}`;
|
|
7975
7974
|
}, je = /* @__PURE__ */ a.jsxs("div", { className: "flex items-center justify-between w-full border border-color-gray-300 rounded-md p-2", children: [
|
|
7976
7975
|
/* @__PURE__ */ a.jsx(
|
|
7977
7976
|
"select",
|
|
7978
7977
|
{
|
|
7979
|
-
value:
|
|
7980
|
-
onChange: (C) => ve({ ...
|
|
7978
|
+
value: I.hour,
|
|
7979
|
+
onChange: (C) => ve({ ...I, hour: parseInt(C.target.value) }),
|
|
7981
7980
|
className: "w-16 border-0 text-center bg-color-transparent outline-0",
|
|
7982
7981
|
children: Array.from({ length: 12 }, (C, ie) => ie + 1).map((C) => /* @__PURE__ */ a.jsx("option", { value: C, children: C.toString().padStart(2, "0") }, C))
|
|
7983
7982
|
}
|
|
@@ -7985,8 +7984,8 @@ const $i = ({
|
|
|
7985
7984
|
/* @__PURE__ */ a.jsx(
|
|
7986
7985
|
"select",
|
|
7987
7986
|
{
|
|
7988
|
-
value:
|
|
7989
|
-
onChange: (C) => ve({ ...
|
|
7987
|
+
value: I.minute,
|
|
7988
|
+
onChange: (C) => ve({ ...I, minute: parseInt(C.target.value) }),
|
|
7990
7989
|
className: "w-16 border-0 text-center bg-color-transparent outline-0 border-l border-color-gray-300",
|
|
7991
7990
|
children: Array.from({ length: 60 }, (C, ie) => ie).map((C) => /* @__PURE__ */ a.jsx("option", { value: C, children: C.toString().padStart(2, "0") }, C))
|
|
7992
7991
|
}
|
|
@@ -7994,8 +7993,8 @@ const $i = ({
|
|
|
7994
7993
|
/* @__PURE__ */ a.jsxs(
|
|
7995
7994
|
"select",
|
|
7996
7995
|
{
|
|
7997
|
-
value:
|
|
7998
|
-
onChange: (C) => ve({ ...
|
|
7996
|
+
value: I.ampm,
|
|
7997
|
+
onChange: (C) => ve({ ...I, ampm: C.target.value }),
|
|
7999
7998
|
className: "w-16 border-0 text-center bg-color-transparent outline-0 border-l border-color-gray-300",
|
|
8000
7999
|
children: [
|
|
8001
8000
|
/* @__PURE__ */ a.jsx("option", { value: "AM", children: "AM" }),
|
|
@@ -8006,7 +8005,7 @@ const $i = ({
|
|
|
8006
8005
|
] }), Se = /* @__PURE__ */ a.jsxs(
|
|
8007
8006
|
"div",
|
|
8008
8007
|
{
|
|
8009
|
-
ref:
|
|
8008
|
+
ref: W,
|
|
8010
8009
|
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"}`,
|
|
8011
8010
|
style: n === "dialog" ? void 0 : {
|
|
8012
8011
|
position: "absolute",
|
|
@@ -8024,7 +8023,7 @@ const $i = ({
|
|
|
8024
8023
|
color: "gray",
|
|
8025
8024
|
roundedFull: !0,
|
|
8026
8025
|
disabled: !oe(),
|
|
8027
|
-
onClick: () =>
|
|
8026
|
+
onClick: () => T(new Date(k.getFullYear(), k.getMonth() - 1, 1)),
|
|
8028
8027
|
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" }) })
|
|
8029
8028
|
}
|
|
8030
8029
|
),
|
|
@@ -8033,20 +8032,20 @@ const $i = ({
|
|
|
8033
8032
|
"select",
|
|
8034
8033
|
{
|
|
8035
8034
|
className: "text-sm outline-none",
|
|
8036
|
-
value:
|
|
8037
|
-
onChange: (C) =>
|
|
8035
|
+
value: k.getMonth(),
|
|
8036
|
+
onChange: (C) => T(new Date(k.getFullYear(), parseInt(C.target.value), 1)),
|
|
8038
8037
|
children: kn.map((C, ie) => {
|
|
8039
|
-
const he =
|
|
8040
|
-
if (f && he ===
|
|
8038
|
+
const he = k.getFullYear(), F = ie, D = /* @__PURE__ */ new Date();
|
|
8039
|
+
if (f && he === D.getFullYear() && F > D.getMonth())
|
|
8041
8040
|
return null;
|
|
8042
8041
|
if (w) {
|
|
8043
8042
|
const ne = typeof w == "string" ? new Date(w) : typeof w == "number" ? new Date(w) : w;
|
|
8044
|
-
if (he === ne.getFullYear() &&
|
|
8043
|
+
if (he === ne.getFullYear() && F < ne.getMonth() || he < ne.getFullYear())
|
|
8045
8044
|
return null;
|
|
8046
8045
|
}
|
|
8047
8046
|
if (S || m) {
|
|
8048
8047
|
const ne = S ? typeof S == "string" ? new Date(S) : typeof S == "number" ? new Date(S) : S : m ? new Date(m) : null;
|
|
8049
|
-
if (ne && he === ne.getFullYear() &&
|
|
8048
|
+
if (ne && he === ne.getFullYear() && F > ne.getMonth() || ne && he > ne.getFullYear())
|
|
8050
8049
|
return null;
|
|
8051
8050
|
}
|
|
8052
8051
|
return /* @__PURE__ */ a.jsx("option", { value: ie, children: C }, C);
|
|
@@ -8057,8 +8056,8 @@ const $i = ({
|
|
|
8057
8056
|
"select",
|
|
8058
8057
|
{
|
|
8059
8058
|
className: "text-sm outline-none",
|
|
8060
|
-
value:
|
|
8061
|
-
onChange: (C) =>
|
|
8059
|
+
value: k.getFullYear(),
|
|
8060
|
+
onChange: (C) => T(new Date(parseInt(C.target.value), k.getMonth(), 1)),
|
|
8062
8061
|
children: Array.from({ length: 150 }, (C, ie) => (/* @__PURE__ */ new Date()).getFullYear() - 100 + ie).filter((C) => {
|
|
8063
8062
|
if (f && C > (/* @__PURE__ */ new Date()).getFullYear()) return !1;
|
|
8064
8063
|
if (w) {
|
|
@@ -8082,7 +8081,7 @@ const $i = ({
|
|
|
8082
8081
|
color: "gray",
|
|
8083
8082
|
roundedFull: !0,
|
|
8084
8083
|
disabled: !ge(),
|
|
8085
|
-
onClick: () =>
|
|
8084
|
+
onClick: () => T(new Date(k.getFullYear(), k.getMonth() + 1, 1)),
|
|
8086
8085
|
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" }) })
|
|
8087
8086
|
}
|
|
8088
8087
|
)
|
|
@@ -8094,11 +8093,11 @@ const $i = ({
|
|
|
8094
8093
|
{
|
|
8095
8094
|
className: `size-8 flex justify-center items-center text-sm rounded-full transition-all
|
|
8096
8095
|
${C ? "hover:bg-color-blue-100 cursor-pointer" : ""}
|
|
8097
|
-
${C &&
|
|
8098
|
-
${C &&
|
|
8099
|
-
onClick: () => C &&
|
|
8100
|
-
onMouseEnter: () => C &&
|
|
8101
|
-
onMouseLeave:
|
|
8096
|
+
${C && q(C) ? "bg-color-blue-500 hover:bg-color-blue-500 text-color-white" : ""}
|
|
8097
|
+
${C && N(C) ? "bg-color-gray-100 text-color-gray-400 !cursor-not-allowed hover:bg-color-gray-100" : ""}`,
|
|
8098
|
+
onClick: () => C && U(C),
|
|
8099
|
+
onMouseEnter: () => C && X(C),
|
|
8100
|
+
onMouseLeave: ce,
|
|
8102
8101
|
children: C ? C.getDate() : ""
|
|
8103
8102
|
},
|
|
8104
8103
|
ie
|
|
@@ -8110,9 +8109,9 @@ const $i = ({
|
|
|
8110
8109
|
Mt,
|
|
8111
8110
|
{
|
|
8112
8111
|
fullWidth: !0,
|
|
8113
|
-
onClick:
|
|
8114
|
-
disabled: e === "range" && !
|
|
8115
|
-
className: `${e === "range" && !
|
|
8112
|
+
onClick: E,
|
|
8113
|
+
disabled: e === "range" && !z && !r,
|
|
8114
|
+
className: `${e === "range" && !z && !r ? "bg-color-gray-400 cursor-not-allowed" : ""}`,
|
|
8116
8115
|
children: "Confirm"
|
|
8117
8116
|
}
|
|
8118
8117
|
) })
|
|
@@ -8123,26 +8122,26 @@ const $i = ({
|
|
|
8123
8122
|
/* @__PURE__ */ a.jsxs(
|
|
8124
8123
|
Mt,
|
|
8125
8124
|
{
|
|
8126
|
-
onClick:
|
|
8125
|
+
onClick: M,
|
|
8127
8126
|
fullWidth: !0,
|
|
8128
8127
|
color: "gray",
|
|
8129
8128
|
variant: "outlined",
|
|
8130
8129
|
className: `!justify-between gap-2 ${o || ""}`,
|
|
8131
8130
|
children: [
|
|
8132
|
-
e === "single" ?
|
|
8131
|
+
e === "single" ? j && u !== null ? te(j) : c : (
|
|
8133
8132
|
// Display rangeStart immediately if set, even if rangeEnd is null
|
|
8134
|
-
|
|
8135
|
-
te(
|
|
8133
|
+
J || R || L ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
8134
|
+
te(J || R, "start"),
|
|
8136
8135
|
" -",
|
|
8137
8136
|
" ",
|
|
8138
|
-
te(
|
|
8137
|
+
te(z || L, "end")
|
|
8139
8138
|
] }) : c
|
|
8140
8139
|
),
|
|
8141
8140
|
d
|
|
8142
8141
|
]
|
|
8143
8142
|
}
|
|
8144
8143
|
),
|
|
8145
|
-
n === "inline" ? /* @__PURE__ */ a.jsx(a.Fragment, { children: y && Ge(Se, document.body) }) : /* @__PURE__ */ a.jsx(ji, { open: y, title: r ? "Select Time" : c, onClose:
|
|
8144
|
+
n === "inline" ? /* @__PURE__ */ a.jsx(a.Fragment, { children: y && Ge(Se, document.body) }) : /* @__PURE__ */ a.jsx(ji, { open: y, title: r ? "Select Time" : c, onClose: P, children: /* @__PURE__ */ a.jsx("div", { className: "w-72", children: Se }) })
|
|
8146
8145
|
] });
|
|
8147
8146
|
}, pa = ({
|
|
8148
8147
|
tabs: e,
|