@cubone/react-file-manager 1.16.3 → 1.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -38
- package/dist/react-file-manager.es.js +1039 -1029
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as De from "react";
|
|
2
|
-
import Pe, { useState as L, useRef as de, useEffect as se, createContext as Ie, useContext as $e, useCallback as
|
|
3
|
-
function
|
|
2
|
+
import Pe, { useState as L, useRef as de, useEffect as se, createContext as Ie, useContext as $e, useCallback as fr, useLayoutEffect as un, useMemo as yt } from "react";
|
|
3
|
+
function dn(e) {
|
|
4
4
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
5
5
|
}
|
|
6
6
|
var vt = { exports: {} }, ze = {};
|
|
@@ -14,18 +14,18 @@ var vt = { exports: {} }, ze = {};
|
|
|
14
14
|
* LICENSE file in the root directory of this source tree.
|
|
15
15
|
*/
|
|
16
16
|
var _t;
|
|
17
|
-
function
|
|
17
|
+
function fn() {
|
|
18
18
|
if (_t) return ze;
|
|
19
19
|
_t = 1;
|
|
20
|
-
var e = Pe, r = Symbol.for("react.element"), n = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, a = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,
|
|
21
|
-
function
|
|
22
|
-
var f,
|
|
23
|
-
|
|
24
|
-
for (f in d) s.call(d, f) && !
|
|
25
|
-
if (l && l.defaultProps) for (f in d = l.defaultProps, d)
|
|
26
|
-
return { $$typeof: r, type: l, key:
|
|
20
|
+
var e = Pe, r = Symbol.for("react.element"), n = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, a = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
21
|
+
function c(l, d, p) {
|
|
22
|
+
var f, h = {}, w = null, S = null;
|
|
23
|
+
p !== void 0 && (w = "" + p), d.key !== void 0 && (w = "" + d.key), d.ref !== void 0 && (S = d.ref);
|
|
24
|
+
for (f in d) s.call(d, f) && !i.hasOwnProperty(f) && (h[f] = d[f]);
|
|
25
|
+
if (l && l.defaultProps) for (f in d = l.defaultProps, d) h[f] === void 0 && (h[f] = d[f]);
|
|
26
|
+
return { $$typeof: r, type: l, key: w, ref: S, props: h, _owner: a.current };
|
|
27
27
|
}
|
|
28
|
-
return ze.Fragment = n, ze.jsx =
|
|
28
|
+
return ze.Fragment = n, ze.jsx = c, ze.jsxs = c, ze;
|
|
29
29
|
}
|
|
30
30
|
var Ae = {};
|
|
31
31
|
/**
|
|
@@ -38,13 +38,13 @@ var Ae = {};
|
|
|
38
38
|
* LICENSE file in the root directory of this source tree.
|
|
39
39
|
*/
|
|
40
40
|
var Nt;
|
|
41
|
-
function
|
|
41
|
+
function hn() {
|
|
42
42
|
return Nt || (Nt = 1, process.env.NODE_ENV !== "production" && function() {
|
|
43
|
-
var e = Pe, r = Symbol.for("react.element"), n = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), a = Symbol.for("react.strict_mode"),
|
|
44
|
-
function
|
|
43
|
+
var e = Pe, r = Symbol.for("react.element"), n = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), a = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), c = Symbol.for("react.provider"), l = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), p = Symbol.for("react.suspense"), f = Symbol.for("react.suspense_list"), h = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), S = Symbol.for("react.offscreen"), M = Symbol.iterator, z = "@@iterator";
|
|
44
|
+
function D(o) {
|
|
45
45
|
if (o === null || typeof o != "object")
|
|
46
46
|
return null;
|
|
47
|
-
var v =
|
|
47
|
+
var v = M && o[M] || o[z];
|
|
48
48
|
return typeof v == "function" ? v : null;
|
|
49
49
|
}
|
|
50
50
|
var C = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
@@ -65,26 +65,26 @@ function fn() {
|
|
|
65
65
|
ie.unshift("Warning: " + v), Function.prototype.apply.call(console[o], console, ie);
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
-
var b = !1, u = !1, g = !1,
|
|
68
|
+
var b = !1, u = !1, g = !1, _ = !1, x = !1, R;
|
|
69
69
|
R = Symbol.for("react.module.reference");
|
|
70
70
|
function F(o) {
|
|
71
|
-
return !!(typeof o == "string" || typeof o == "function" || o === s || o ===
|
|
71
|
+
return !!(typeof o == "string" || typeof o == "function" || o === s || o === i || x || o === a || o === p || o === f || _ || o === S || b || u || g || typeof o == "object" && o !== null && (o.$$typeof === w || o.$$typeof === h || o.$$typeof === c || o.$$typeof === l || o.$$typeof === d || // This needs to include all possible module reference object
|
|
72
72
|
// types supported by any Flight configuration anywhere since
|
|
73
73
|
// we don't know which Flight build this will end up being used
|
|
74
74
|
// with.
|
|
75
75
|
o.$$typeof === R || o.getModuleId !== void 0));
|
|
76
76
|
}
|
|
77
|
-
function
|
|
77
|
+
function A(o, v, T) {
|
|
78
78
|
var B = o.displayName;
|
|
79
79
|
if (B)
|
|
80
80
|
return B;
|
|
81
81
|
var te = v.displayName || v.name || "";
|
|
82
82
|
return te !== "" ? T + "(" + te + ")" : T;
|
|
83
83
|
}
|
|
84
|
-
function
|
|
84
|
+
function N(o) {
|
|
85
85
|
return o.displayName || "Context";
|
|
86
86
|
}
|
|
87
|
-
function
|
|
87
|
+
function k(o) {
|
|
88
88
|
if (o == null)
|
|
89
89
|
return null;
|
|
90
90
|
if (typeof o.tag == "number" && j("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof o == "function")
|
|
@@ -96,11 +96,11 @@ function fn() {
|
|
|
96
96
|
return "Fragment";
|
|
97
97
|
case n:
|
|
98
98
|
return "Portal";
|
|
99
|
-
case
|
|
99
|
+
case i:
|
|
100
100
|
return "Profiler";
|
|
101
101
|
case a:
|
|
102
102
|
return "StrictMode";
|
|
103
|
-
case
|
|
103
|
+
case p:
|
|
104
104
|
return "Suspense";
|
|
105
105
|
case f:
|
|
106
106
|
return "SuspenseList";
|
|
@@ -109,19 +109,19 @@ function fn() {
|
|
|
109
109
|
switch (o.$$typeof) {
|
|
110
110
|
case l:
|
|
111
111
|
var v = o;
|
|
112
|
-
return
|
|
113
|
-
case
|
|
112
|
+
return N(v) + ".Consumer";
|
|
113
|
+
case c:
|
|
114
114
|
var T = o;
|
|
115
|
-
return
|
|
115
|
+
return N(T._context) + ".Provider";
|
|
116
116
|
case d:
|
|
117
|
-
return
|
|
118
|
-
case
|
|
117
|
+
return A(o, o.render, "ForwardRef");
|
|
118
|
+
case h:
|
|
119
119
|
var B = o.displayName || null;
|
|
120
|
-
return B !== null ? B :
|
|
121
|
-
case
|
|
120
|
+
return B !== null ? B : k(o.type) || "Memo";
|
|
121
|
+
case w: {
|
|
122
122
|
var te = o, ie = te._payload, ee = te._init;
|
|
123
123
|
try {
|
|
124
|
-
return
|
|
124
|
+
return k(ee(ie));
|
|
125
125
|
} catch {
|
|
126
126
|
return null;
|
|
127
127
|
}
|
|
@@ -129,14 +129,14 @@ function fn() {
|
|
|
129
129
|
}
|
|
130
130
|
return null;
|
|
131
131
|
}
|
|
132
|
-
var X = Object.assign, oe = 0, ae, Q,
|
|
132
|
+
var X = Object.assign, oe = 0, ae, Q, he, xe, m, P, V;
|
|
133
133
|
function W() {
|
|
134
134
|
}
|
|
135
135
|
W.__reactDisabledLog = !0;
|
|
136
136
|
function I() {
|
|
137
137
|
{
|
|
138
138
|
if (oe === 0) {
|
|
139
|
-
ae = console.log, Q = console.info,
|
|
139
|
+
ae = console.log, Q = console.info, he = console.warn, xe = console.error, m = console.group, P = console.groupCollapsed, V = console.groupEnd;
|
|
140
140
|
var o = {
|
|
141
141
|
configurable: !0,
|
|
142
142
|
enumerable: !0,
|
|
@@ -172,10 +172,10 @@ function fn() {
|
|
|
172
172
|
value: Q
|
|
173
173
|
}),
|
|
174
174
|
warn: X({}, o, {
|
|
175
|
-
value:
|
|
175
|
+
value: he
|
|
176
176
|
}),
|
|
177
177
|
error: X({}, o, {
|
|
178
|
-
value:
|
|
178
|
+
value: xe
|
|
179
179
|
}),
|
|
180
180
|
group: X({}, o, {
|
|
181
181
|
value: m
|
|
@@ -205,13 +205,13 @@ function fn() {
|
|
|
205
205
|
` + $ + o;
|
|
206
206
|
}
|
|
207
207
|
}
|
|
208
|
-
var
|
|
208
|
+
var Z = !1, q;
|
|
209
209
|
{
|
|
210
210
|
var fe = typeof WeakMap == "function" ? WeakMap : Map;
|
|
211
211
|
q = new fe();
|
|
212
212
|
}
|
|
213
|
-
function
|
|
214
|
-
if (!o ||
|
|
213
|
+
function E(o, v) {
|
|
214
|
+
if (!o || Z)
|
|
215
215
|
return "";
|
|
216
216
|
{
|
|
217
217
|
var T = q.get(o);
|
|
@@ -219,7 +219,7 @@ function fn() {
|
|
|
219
219
|
return T;
|
|
220
220
|
}
|
|
221
221
|
var B;
|
|
222
|
-
|
|
222
|
+
Z = !0;
|
|
223
223
|
var te = Error.prepareStackTrace;
|
|
224
224
|
Error.prepareStackTrace = void 0;
|
|
225
225
|
var ie;
|
|
@@ -236,39 +236,39 @@ function fn() {
|
|
|
236
236
|
}), typeof Reflect == "object" && Reflect.construct) {
|
|
237
237
|
try {
|
|
238
238
|
Reflect.construct(ee, []);
|
|
239
|
-
} catch (
|
|
240
|
-
B =
|
|
239
|
+
} catch (Ce) {
|
|
240
|
+
B = Ce;
|
|
241
241
|
}
|
|
242
242
|
Reflect.construct(o, [], ee);
|
|
243
243
|
} else {
|
|
244
244
|
try {
|
|
245
245
|
ee.call();
|
|
246
|
-
} catch (
|
|
247
|
-
B =
|
|
246
|
+
} catch (Ce) {
|
|
247
|
+
B = Ce;
|
|
248
248
|
}
|
|
249
249
|
o.call(ee.prototype);
|
|
250
250
|
}
|
|
251
251
|
} else {
|
|
252
252
|
try {
|
|
253
253
|
throw Error();
|
|
254
|
-
} catch (
|
|
255
|
-
B =
|
|
254
|
+
} catch (Ce) {
|
|
255
|
+
B = Ce;
|
|
256
256
|
}
|
|
257
257
|
o();
|
|
258
258
|
}
|
|
259
|
-
} catch (
|
|
260
|
-
if (
|
|
261
|
-
for (var
|
|
259
|
+
} catch (Ce) {
|
|
260
|
+
if (Ce && B && typeof Ce.stack == "string") {
|
|
261
|
+
for (var J = Ce.stack.split(`
|
|
262
262
|
`), me = B.stack.split(`
|
|
263
|
-
`), ce =
|
|
263
|
+
`), ce = J.length - 1, ue = me.length - 1; ce >= 1 && ue >= 0 && J[ce] !== me[ue]; )
|
|
264
264
|
ue--;
|
|
265
265
|
for (; ce >= 1 && ue >= 0; ce--, ue--)
|
|
266
|
-
if (
|
|
266
|
+
if (J[ce] !== me[ue]) {
|
|
267
267
|
if (ce !== 1 || ue !== 1)
|
|
268
268
|
do
|
|
269
|
-
if (ce--, ue--, ue < 0 ||
|
|
269
|
+
if (ce--, ue--, ue < 0 || J[ce] !== me[ue]) {
|
|
270
270
|
var be = `
|
|
271
|
-
` +
|
|
271
|
+
` + J[ce].replace(" at new ", " at ");
|
|
272
272
|
return o.displayName && be.includes("<anonymous>") && (be = be.replace("<anonymous>", o.displayName)), typeof o == "function" && q.set(o, be), be;
|
|
273
273
|
}
|
|
274
274
|
while (ce >= 1 && ue >= 0);
|
|
@@ -276,13 +276,13 @@ function fn() {
|
|
|
276
276
|
}
|
|
277
277
|
}
|
|
278
278
|
} finally {
|
|
279
|
-
|
|
279
|
+
Z = !1, O.current = ie, K(), Error.prepareStackTrace = te;
|
|
280
280
|
}
|
|
281
281
|
var ke = o ? o.displayName || o.name : "", Me = ke ? U(ke) : "";
|
|
282
282
|
return typeof o == "function" && q.set(o, Me), Me;
|
|
283
283
|
}
|
|
284
284
|
function ve(o, v, T) {
|
|
285
|
-
return
|
|
285
|
+
return E(o, !1);
|
|
286
286
|
}
|
|
287
287
|
function Te(o) {
|
|
288
288
|
var v = o.prototype;
|
|
@@ -292,11 +292,11 @@ function fn() {
|
|
|
292
292
|
if (o == null)
|
|
293
293
|
return "";
|
|
294
294
|
if (typeof o == "function")
|
|
295
|
-
return
|
|
295
|
+
return E(o, Te(o));
|
|
296
296
|
if (typeof o == "string")
|
|
297
297
|
return U(o);
|
|
298
298
|
switch (o) {
|
|
299
|
-
case
|
|
299
|
+
case p:
|
|
300
300
|
return U("Suspense");
|
|
301
301
|
case f:
|
|
302
302
|
return U("SuspenseList");
|
|
@@ -305,9 +305,9 @@ function fn() {
|
|
|
305
305
|
switch (o.$$typeof) {
|
|
306
306
|
case d:
|
|
307
307
|
return ve(o.render);
|
|
308
|
-
case
|
|
308
|
+
case h:
|
|
309
309
|
return Y(o.type, v, T);
|
|
310
|
-
case
|
|
310
|
+
case w: {
|
|
311
311
|
var B = o, te = B._payload, ie = B._init;
|
|
312
312
|
try {
|
|
313
313
|
return Y(ie(te), v, T);
|
|
@@ -330,17 +330,17 @@ function fn() {
|
|
|
330
330
|
var ie = Function.call.bind(le);
|
|
331
331
|
for (var ee in o)
|
|
332
332
|
if (ie(o, ee)) {
|
|
333
|
-
var
|
|
333
|
+
var J = void 0;
|
|
334
334
|
try {
|
|
335
335
|
if (typeof o[ee] != "function") {
|
|
336
336
|
var me = Error((B || "React class") + ": " + T + " type `" + ee + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof o[ee] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
337
337
|
throw me.name = "Invariant Violation", me;
|
|
338
338
|
}
|
|
339
|
-
|
|
339
|
+
J = o[ee](v, ee, B, T, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
340
340
|
} catch (ce) {
|
|
341
|
-
|
|
341
|
+
J = ce;
|
|
342
342
|
}
|
|
343
|
-
|
|
343
|
+
J && !(J instanceof Error) && (we(te), j("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", B || "React class", T, ee, typeof J), we(null)), J instanceof Error && !(J.message in je) && (je[J.message] = !0, we(te), j("Failed %s type: %s", T, J.message), we(null));
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
346
|
}
|
|
@@ -348,13 +348,13 @@ function fn() {
|
|
|
348
348
|
function et(o) {
|
|
349
349
|
return Qe(o);
|
|
350
350
|
}
|
|
351
|
-
function
|
|
351
|
+
function Wr(o) {
|
|
352
352
|
{
|
|
353
353
|
var v = typeof Symbol == "function" && Symbol.toStringTag, T = v && o[Symbol.toStringTag] || o.constructor.name || "Object";
|
|
354
354
|
return T;
|
|
355
355
|
}
|
|
356
356
|
}
|
|
357
|
-
function
|
|
357
|
+
function Vr(o) {
|
|
358
358
|
try {
|
|
359
359
|
return bt(o), !1;
|
|
360
360
|
} catch {
|
|
@@ -365,16 +365,16 @@ function fn() {
|
|
|
365
365
|
return "" + o;
|
|
366
366
|
}
|
|
367
367
|
function wt(o) {
|
|
368
|
-
if (
|
|
369
|
-
return j("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",
|
|
368
|
+
if (Vr(o))
|
|
369
|
+
return j("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Wr(o)), bt(o);
|
|
370
370
|
}
|
|
371
|
-
var Et = C.ReactCurrentOwner,
|
|
371
|
+
var Et = C.ReactCurrentOwner, Yr = {
|
|
372
372
|
key: !0,
|
|
373
373
|
ref: !0,
|
|
374
374
|
__self: !0,
|
|
375
375
|
__source: !0
|
|
376
376
|
}, Rt, Pt;
|
|
377
|
-
function
|
|
377
|
+
function Ur(o) {
|
|
378
378
|
if (le.call(o, "ref")) {
|
|
379
379
|
var v = Object.getOwnPropertyDescriptor(o, "ref").get;
|
|
380
380
|
if (v && v.isReactWarning)
|
|
@@ -382,7 +382,7 @@ function fn() {
|
|
|
382
382
|
}
|
|
383
383
|
return o.ref !== void 0;
|
|
384
384
|
}
|
|
385
|
-
function
|
|
385
|
+
function qr(o) {
|
|
386
386
|
if (le.call(o, "key")) {
|
|
387
387
|
var v = Object.getOwnPropertyDescriptor(o, "key").get;
|
|
388
388
|
if (v && v.isReactWarning)
|
|
@@ -390,10 +390,10 @@ function fn() {
|
|
|
390
390
|
}
|
|
391
391
|
return o.key !== void 0;
|
|
392
392
|
}
|
|
393
|
-
function
|
|
393
|
+
function Kr(o, v) {
|
|
394
394
|
typeof o.ref == "string" && Et.current;
|
|
395
395
|
}
|
|
396
|
-
function
|
|
396
|
+
function Xr(o, v) {
|
|
397
397
|
{
|
|
398
398
|
var T = function() {
|
|
399
399
|
Rt || (Rt = !0, j("%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://reactjs.org/link/special-props)", v));
|
|
@@ -404,7 +404,7 @@ function fn() {
|
|
|
404
404
|
});
|
|
405
405
|
}
|
|
406
406
|
}
|
|
407
|
-
function
|
|
407
|
+
function Gr(o, v) {
|
|
408
408
|
{
|
|
409
409
|
var T = function() {
|
|
410
410
|
Pt || (Pt = !0, j("%s: `ref` 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://reactjs.org/link/special-props)", v));
|
|
@@ -415,8 +415,8 @@ function fn() {
|
|
|
415
415
|
});
|
|
416
416
|
}
|
|
417
417
|
}
|
|
418
|
-
var
|
|
419
|
-
var
|
|
418
|
+
var Jr = function(o, v, T, B, te, ie, ee) {
|
|
419
|
+
var J = {
|
|
420
420
|
// This tag allows us to uniquely identify this as a React Element
|
|
421
421
|
$$typeof: r,
|
|
422
422
|
// Built-in properties that belong on the element
|
|
@@ -427,39 +427,39 @@ function fn() {
|
|
|
427
427
|
// Record the component responsible for creating this element.
|
|
428
428
|
_owner: ie
|
|
429
429
|
};
|
|
430
|
-
return
|
|
430
|
+
return J._store = {}, Object.defineProperty(J._store, "validated", {
|
|
431
431
|
configurable: !1,
|
|
432
432
|
enumerable: !1,
|
|
433
433
|
writable: !0,
|
|
434
434
|
value: !1
|
|
435
|
-
}), Object.defineProperty(
|
|
435
|
+
}), Object.defineProperty(J, "_self", {
|
|
436
436
|
configurable: !1,
|
|
437
437
|
enumerable: !1,
|
|
438
438
|
writable: !1,
|
|
439
439
|
value: B
|
|
440
|
-
}), Object.defineProperty(
|
|
440
|
+
}), Object.defineProperty(J, "_source", {
|
|
441
441
|
configurable: !1,
|
|
442
442
|
enumerable: !1,
|
|
443
443
|
writable: !1,
|
|
444
444
|
value: te
|
|
445
|
-
}), Object.freeze && (Object.freeze(
|
|
445
|
+
}), Object.freeze && (Object.freeze(J.props), Object.freeze(J)), J;
|
|
446
446
|
};
|
|
447
|
-
function
|
|
447
|
+
function Zr(o, v, T, B, te) {
|
|
448
448
|
{
|
|
449
|
-
var ie, ee = {},
|
|
450
|
-
T !== void 0 && (wt(T),
|
|
449
|
+
var ie, ee = {}, J = null, me = null;
|
|
450
|
+
T !== void 0 && (wt(T), J = "" + T), qr(v) && (wt(v.key), J = "" + v.key), Ur(v) && (me = v.ref, Kr(v, te));
|
|
451
451
|
for (ie in v)
|
|
452
|
-
le.call(v, ie) && !
|
|
452
|
+
le.call(v, ie) && !Yr.hasOwnProperty(ie) && (ee[ie] = v[ie]);
|
|
453
453
|
if (o && o.defaultProps) {
|
|
454
454
|
var ce = o.defaultProps;
|
|
455
455
|
for (ie in ce)
|
|
456
456
|
ee[ie] === void 0 && (ee[ie] = ce[ie]);
|
|
457
457
|
}
|
|
458
|
-
if (
|
|
458
|
+
if (J || me) {
|
|
459
459
|
var ue = typeof o == "function" ? o.displayName || o.name || "Unknown" : o;
|
|
460
|
-
|
|
460
|
+
J && Xr(ee, ue), me && Gr(ee, ue);
|
|
461
461
|
}
|
|
462
|
-
return
|
|
462
|
+
return Jr(o, J, me, te, B, Et.current, ee);
|
|
463
463
|
}
|
|
464
464
|
}
|
|
465
465
|
var tt = C.ReactCurrentOwner, Tt = C.ReactDebugCurrentFrame;
|
|
@@ -478,7 +478,7 @@ function fn() {
|
|
|
478
478
|
function Ft() {
|
|
479
479
|
{
|
|
480
480
|
if (tt.current) {
|
|
481
|
-
var o =
|
|
481
|
+
var o = k(tt.current.type);
|
|
482
482
|
if (o)
|
|
483
483
|
return `
|
|
484
484
|
|
|
@@ -487,11 +487,11 @@ Check the render method of \`` + o + "`.";
|
|
|
487
487
|
return "";
|
|
488
488
|
}
|
|
489
489
|
}
|
|
490
|
-
function
|
|
490
|
+
function Qr(o) {
|
|
491
491
|
return "";
|
|
492
492
|
}
|
|
493
493
|
var St = {};
|
|
494
|
-
function
|
|
494
|
+
function en(o) {
|
|
495
495
|
{
|
|
496
496
|
var v = Ft();
|
|
497
497
|
if (!v) {
|
|
@@ -508,12 +508,12 @@ Check the top-level render call using <` + T + ">.");
|
|
|
508
508
|
if (!o._store || o._store.validated || o.key != null)
|
|
509
509
|
return;
|
|
510
510
|
o._store.validated = !0;
|
|
511
|
-
var T =
|
|
511
|
+
var T = en(v);
|
|
512
512
|
if (St[T])
|
|
513
513
|
return;
|
|
514
514
|
St[T] = !0;
|
|
515
515
|
var B = "";
|
|
516
|
-
o && o._owner && o._owner !== tt.current && (B = " It was passed a child from " +
|
|
516
|
+
o && o._owner && o._owner !== tt.current && (B = " It was passed a child from " + k(o._owner.type) + "."), Oe(o), j('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', T, B), Oe(null);
|
|
517
517
|
}
|
|
518
518
|
}
|
|
519
519
|
function Lt(o, v) {
|
|
@@ -528,14 +528,14 @@ Check the top-level render call using <` + T + ">.");
|
|
|
528
528
|
else if (nt(o))
|
|
529
529
|
o._store && (o._store.validated = !0);
|
|
530
530
|
else if (o) {
|
|
531
|
-
var te =
|
|
531
|
+
var te = D(o);
|
|
532
532
|
if (typeof te == "function" && te !== o.entries)
|
|
533
533
|
for (var ie = te.call(o), ee; !(ee = ie.next()).done; )
|
|
534
534
|
nt(ee.value) && Mt(ee.value, v);
|
|
535
535
|
}
|
|
536
536
|
}
|
|
537
537
|
}
|
|
538
|
-
function
|
|
538
|
+
function tn(o) {
|
|
539
539
|
{
|
|
540
540
|
var v = o.type;
|
|
541
541
|
if (v == null || typeof v == "string")
|
|
@@ -545,22 +545,22 @@ Check the top-level render call using <` + T + ">.");
|
|
|
545
545
|
T = v.propTypes;
|
|
546
546
|
else if (typeof v == "object" && (v.$$typeof === d || // Note: Memo only checks outer props here.
|
|
547
547
|
// Inner props are checked in the reconciler.
|
|
548
|
-
v.$$typeof ===
|
|
548
|
+
v.$$typeof === h))
|
|
549
549
|
T = v.propTypes;
|
|
550
550
|
else
|
|
551
551
|
return;
|
|
552
552
|
if (T) {
|
|
553
|
-
var B =
|
|
553
|
+
var B = k(v);
|
|
554
554
|
He(T, o.props, "prop", B, o);
|
|
555
555
|
} else if (v.PropTypes !== void 0 && !rt) {
|
|
556
556
|
rt = !0;
|
|
557
|
-
var te =
|
|
557
|
+
var te = k(v);
|
|
558
558
|
j("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", te || "Unknown");
|
|
559
559
|
}
|
|
560
560
|
typeof v.getDefaultProps == "function" && !v.getDefaultProps.isReactClassApproved && j("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
561
561
|
}
|
|
562
562
|
}
|
|
563
|
-
function
|
|
563
|
+
function rn(o) {
|
|
564
564
|
{
|
|
565
565
|
for (var v = Object.keys(o.props), T = 0; T < v.length; T++) {
|
|
566
566
|
var B = v[T];
|
|
@@ -577,14 +577,14 @@ Check the top-level render call using <` + T + ">.");
|
|
|
577
577
|
{
|
|
578
578
|
var ee = F(o);
|
|
579
579
|
if (!ee) {
|
|
580
|
-
var
|
|
581
|
-
(o === void 0 || typeof o == "object" && o !== null && Object.keys(o).length === 0) && (
|
|
582
|
-
var me =
|
|
583
|
-
me ?
|
|
580
|
+
var J = "";
|
|
581
|
+
(o === void 0 || typeof o == "object" && o !== null && Object.keys(o).length === 0) && (J += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
582
|
+
var me = Qr();
|
|
583
|
+
me ? J += me : J += Ft();
|
|
584
584
|
var ce;
|
|
585
|
-
o === null ? ce = "null" : et(o) ? ce = "array" : o !== void 0 && o.$$typeof === r ? (ce = "<" + (
|
|
585
|
+
o === null ? ce = "null" : et(o) ? ce = "array" : o !== void 0 && o.$$typeof === r ? (ce = "<" + (k(o.type) || "Unknown") + " />", J = " Did you accidentally export a JSX literal instead of a component?") : ce = typeof o, j("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ce, J);
|
|
586
586
|
}
|
|
587
|
-
var ue =
|
|
587
|
+
var ue = Zr(o, v, T, te, ie);
|
|
588
588
|
if (ue == null)
|
|
589
589
|
return ue;
|
|
590
590
|
if (ee) {
|
|
@@ -601,51 +601,51 @@ Check the top-level render call using <` + T + ">.");
|
|
|
601
601
|
Lt(be, o);
|
|
602
602
|
}
|
|
603
603
|
if (le.call(v, "key")) {
|
|
604
|
-
var Me =
|
|
605
|
-
return
|
|
606
|
-
}), st =
|
|
604
|
+
var Me = k(o), Ce = Object.keys(v).filter(function(ln) {
|
|
605
|
+
return ln !== "key";
|
|
606
|
+
}), st = Ce.length > 0 ? "{key: someKey, " + Ce.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
607
607
|
if (!Ot[Me + st]) {
|
|
608
|
-
var
|
|
608
|
+
var cn = Ce.length > 0 ? "{" + Ce.join(": ..., ") + ": ...}" : "{}";
|
|
609
609
|
j(`A props object containing a "key" prop is being spread into JSX:
|
|
610
610
|
let props = %s;
|
|
611
611
|
<%s {...props} />
|
|
612
612
|
React keys must be passed directly to JSX without using spread:
|
|
613
613
|
let props = %s;
|
|
614
|
-
<%s key={someKey} {...props} />`, st, Me,
|
|
614
|
+
<%s key={someKey} {...props} />`, st, Me, cn, Me), Ot[Me + st] = !0;
|
|
615
615
|
}
|
|
616
616
|
}
|
|
617
|
-
return o === s ?
|
|
617
|
+
return o === s ? rn(ue) : tn(ue), ue;
|
|
618
618
|
}
|
|
619
619
|
}
|
|
620
|
-
function
|
|
620
|
+
function nn(o, v, T) {
|
|
621
621
|
return kt(o, v, T, !0);
|
|
622
622
|
}
|
|
623
|
-
function
|
|
623
|
+
function sn(o, v, T) {
|
|
624
624
|
return kt(o, v, T, !1);
|
|
625
625
|
}
|
|
626
|
-
var
|
|
627
|
-
Ae.Fragment = s, Ae.jsx =
|
|
626
|
+
var on = sn, an = nn;
|
|
627
|
+
Ae.Fragment = s, Ae.jsx = on, Ae.jsxs = an;
|
|
628
628
|
}()), Ae;
|
|
629
629
|
}
|
|
630
|
-
process.env.NODE_ENV === "production" ? vt.exports =
|
|
631
|
-
var t = vt.exports,
|
|
630
|
+
process.env.NODE_ENV === "production" ? vt.exports = fn() : vt.exports = hn();
|
|
631
|
+
var t = vt.exports, hr = {
|
|
632
632
|
color: void 0,
|
|
633
633
|
size: void 0,
|
|
634
634
|
className: void 0,
|
|
635
635
|
style: void 0,
|
|
636
636
|
attr: void 0
|
|
637
|
-
}, zt = Pe.createContext && /* @__PURE__ */ Pe.createContext(
|
|
638
|
-
function
|
|
637
|
+
}, zt = Pe.createContext && /* @__PURE__ */ Pe.createContext(hr), pn = ["attr", "size", "title"];
|
|
638
|
+
function vn(e, r) {
|
|
639
639
|
if (e == null) return {};
|
|
640
|
-
var n =
|
|
640
|
+
var n = mn(e, r), s, a;
|
|
641
641
|
if (Object.getOwnPropertySymbols) {
|
|
642
|
-
var
|
|
643
|
-
for (a = 0; a <
|
|
644
|
-
s =
|
|
642
|
+
var i = Object.getOwnPropertySymbols(e);
|
|
643
|
+
for (a = 0; a < i.length; a++)
|
|
644
|
+
s = i[a], !(r.indexOf(s) >= 0) && Object.prototype.propertyIsEnumerable.call(e, s) && (n[s] = e[s]);
|
|
645
645
|
}
|
|
646
646
|
return n;
|
|
647
647
|
}
|
|
648
|
-
function
|
|
648
|
+
function mn(e, r) {
|
|
649
649
|
if (e == null) return {};
|
|
650
650
|
var n = {};
|
|
651
651
|
for (var s in e)
|
|
@@ -679,21 +679,21 @@ function Ye(e) {
|
|
|
679
679
|
for (var r = 1; r < arguments.length; r++) {
|
|
680
680
|
var n = arguments[r] != null ? arguments[r] : {};
|
|
681
681
|
r % 2 ? At(Object(n), !0).forEach(function(s) {
|
|
682
|
-
|
|
682
|
+
gn(e, s, n[s]);
|
|
683
683
|
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : At(Object(n)).forEach(function(s) {
|
|
684
684
|
Object.defineProperty(e, s, Object.getOwnPropertyDescriptor(n, s));
|
|
685
685
|
});
|
|
686
686
|
}
|
|
687
687
|
return e;
|
|
688
688
|
}
|
|
689
|
-
function
|
|
690
|
-
return r =
|
|
689
|
+
function gn(e, r, n) {
|
|
690
|
+
return r = yn(r), r in e ? Object.defineProperty(e, r, { value: n, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = n, e;
|
|
691
691
|
}
|
|
692
|
-
function
|
|
693
|
-
var r =
|
|
692
|
+
function yn(e) {
|
|
693
|
+
var r = xn(e, "string");
|
|
694
694
|
return typeof r == "symbol" ? r : r + "";
|
|
695
695
|
}
|
|
696
|
-
function
|
|
696
|
+
function xn(e, r) {
|
|
697
697
|
if (typeof e != "object" || !e) return e;
|
|
698
698
|
var n = e[Symbol.toPrimitive];
|
|
699
699
|
if (n !== void 0) {
|
|
@@ -703,28 +703,28 @@ function yn(e, r) {
|
|
|
703
703
|
}
|
|
704
704
|
return (r === "string" ? String : Number)(e);
|
|
705
705
|
}
|
|
706
|
-
function
|
|
706
|
+
function pr(e) {
|
|
707
707
|
return e && e.map((r, n) => /* @__PURE__ */ Pe.createElement(r.tag, Ye({
|
|
708
708
|
key: n
|
|
709
|
-
}, r.attr),
|
|
709
|
+
}, r.attr), pr(r.child)));
|
|
710
710
|
}
|
|
711
711
|
function H(e) {
|
|
712
|
-
return (r) => /* @__PURE__ */ Pe.createElement(
|
|
712
|
+
return (r) => /* @__PURE__ */ Pe.createElement(Cn, Ve({
|
|
713
713
|
attr: Ye({}, e.attr)
|
|
714
|
-
}, r),
|
|
714
|
+
}, r), pr(e.child));
|
|
715
715
|
}
|
|
716
|
-
function
|
|
716
|
+
function Cn(e) {
|
|
717
717
|
var r = (n) => {
|
|
718
718
|
var {
|
|
719
719
|
attr: s,
|
|
720
720
|
size: a,
|
|
721
|
-
title:
|
|
722
|
-
} = e,
|
|
721
|
+
title: i
|
|
722
|
+
} = e, c = vn(e, pn), l = a || n.size || "1em", d;
|
|
723
723
|
return n.className && (d = n.className), e.className && (d = (d ? d + " " : "") + e.className), /* @__PURE__ */ Pe.createElement("svg", Ve({
|
|
724
724
|
stroke: "currentColor",
|
|
725
725
|
fill: "currentColor",
|
|
726
726
|
strokeWidth: "0"
|
|
727
|
-
}, n.attr, s,
|
|
727
|
+
}, n.attr, s, c, {
|
|
728
728
|
className: d,
|
|
729
729
|
style: Ye(Ye({
|
|
730
730
|
color: e.color || n.color
|
|
@@ -732,72 +732,72 @@ function xn(e) {
|
|
|
732
732
|
height: l,
|
|
733
733
|
width: l,
|
|
734
734
|
xmlns: "http://www.w3.org/2000/svg"
|
|
735
|
-
}),
|
|
735
|
+
}), i && /* @__PURE__ */ Pe.createElement("title", null, i), e.children);
|
|
736
736
|
};
|
|
737
|
-
return zt !== void 0 ? /* @__PURE__ */ Pe.createElement(zt.Consumer, null, (n) => r(n)) : r(
|
|
737
|
+
return zt !== void 0 ? /* @__PURE__ */ Pe.createElement(zt.Consumer, null, (n) => r(n)) : r(hr);
|
|
738
738
|
}
|
|
739
|
-
function
|
|
739
|
+
function jn(e) {
|
|
740
740
|
return H({ tag: "svg", attr: { version: "1.1", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "M16 8c-0.020-1.045-0.247-2.086-0.665-3.038-0.417-0.953-1.023-1.817-1.766-2.53s-1.624-1.278-2.578-1.651c-0.953-0.374-1.978-0.552-2.991-0.531-1.013 0.020-2.021 0.24-2.943 0.646-0.923 0.405-1.758 0.992-2.449 1.712s-1.237 1.574-1.597 2.497c-0.361 0.923-0.533 1.914-0.512 2.895 0.020 0.981 0.234 1.955 0.627 2.847 0.392 0.892 0.961 1.7 1.658 2.368s1.523 1.195 2.416 1.543c0.892 0.348 1.851 0.514 2.799 0.493 0.949-0.020 1.89-0.227 2.751-0.608 0.862-0.379 1.642-0.929 2.287-1.604s1.154-1.472 1.488-2.335c0.204-0.523 0.342-1.069 0.415-1.622 0.019 0.001 0.039 0.002 0.059 0.002 0.552 0 1-0.448 1-1 0-0.028-0.001-0.056-0.004-0.083h0.004zM14.411 10.655c-0.367 0.831-0.898 1.584-1.55 2.206s-1.422 1.112-2.254 1.434c-0.832 0.323-1.723 0.476-2.608 0.454-0.884-0.020-1.759-0.215-2.56-0.57-0.801-0.354-1.526-0.867-2.125-1.495s-1.071-1.371-1.38-2.173c-0.31-0.801-0.457-1.66-0.435-2.512s0.208-1.694 0.551-2.464c0.342-0.77 0.836-1.468 1.441-2.044s1.321-1.029 2.092-1.326c0.771-0.298 1.596-0.438 2.416-0.416s1.629 0.202 2.368 0.532c0.74 0.329 1.41 0.805 1.963 1.387s0.988 1.27 1.272 2.011c0.285 0.74 0.418 1.532 0.397 2.32h0.004c-0.002 0.027-0.004 0.055-0.004 0.083 0 0.516 0.39 0.94 0.892 0.994-0.097 0.544-0.258 1.075-0.481 1.578z" }, child: [] }] })(e);
|
|
741
741
|
}
|
|
742
|
-
const xt = ({ loading: e = !1, className: r }) => e ? /* @__PURE__ */ t.jsx("div", { className: `loader-container ${r}`, children: /* @__PURE__ */ t.jsx(
|
|
743
|
-
function
|
|
742
|
+
const xt = ({ loading: e = !1, className: r }) => e ? /* @__PURE__ */ t.jsx("div", { className: `loader-container ${r}`, children: /* @__PURE__ */ t.jsx(jn, { className: "spinner" }) }) : null;
|
|
743
|
+
function vr(e) {
|
|
744
744
|
return H({ tag: "svg", attr: { fill: "currentColor", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { fillRule: "evenodd", d: "M4 2a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm2-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1zM2 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1v-1h1v1a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h1v1z" }, child: [] }] })(e);
|
|
745
745
|
}
|
|
746
|
-
function
|
|
746
|
+
function mr(e) {
|
|
747
747
|
return H({ tag: "svg", attr: { fill: "currentColor", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "m.5 3 .04.87a2 2 0 0 0-.342 1.311l.637 7A2 2 0 0 0 2.826 14H9v-1H2.826a1 1 0 0 1-.995-.91l-.637-7A1 1 0 0 1 2.19 4h11.62a1 1 0 0 1 .996 1.09L14.54 8h1.005l.256-2.819A2 2 0 0 0 13.81 3H9.828a2 2 0 0 1-1.414-.586l-.828-.828A2 2 0 0 0 6.172 1H2.5a2 2 0 0 0-2 2m5.672-1a1 1 0 0 1 .707.293L7.586 3H2.19q-.362.002-.683.12L1.5 2.98a1 1 0 0 1 1-.98z" }, child: [] }, { tag: "path", attr: { d: "M13.5 9a.5.5 0 0 1 .5.5V11h1.5a.5.5 0 1 1 0 1H14v1.5a.5.5 0 1 1-1 0V12h-1.5a.5.5 0 0 1 0-1H13V9.5a.5.5 0 0 1 .5-.5" }, child: [] }] })(e);
|
|
748
748
|
}
|
|
749
|
-
function
|
|
749
|
+
function gr(e) {
|
|
750
750
|
return H({ tag: "svg", attr: { fill: "currentColor", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "M1 2.5A1.5 1.5 0 0 1 2.5 1h3A1.5 1.5 0 0 1 7 2.5v3A1.5 1.5 0 0 1 5.5 7h-3A1.5 1.5 0 0 1 1 5.5zm8 0A1.5 1.5 0 0 1 10.5 1h3A1.5 1.5 0 0 1 15 2.5v3A1.5 1.5 0 0 1 13.5 7h-3A1.5 1.5 0 0 1 9 5.5zm-8 8A1.5 1.5 0 0 1 2.5 9h3A1.5 1.5 0 0 1 7 10.5v3A1.5 1.5 0 0 1 5.5 15h-3A1.5 1.5 0 0 1 1 13.5zm8 0A1.5 1.5 0 0 1 10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-3A1.5 1.5 0 0 1 9 13.5z" }, child: [] }] })(e);
|
|
751
751
|
}
|
|
752
752
|
function Dt(e) {
|
|
753
753
|
return H({ tag: "svg", attr: { fill: "currentColor", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "M1 2.5A1.5 1.5 0 0 1 2.5 1h3A1.5 1.5 0 0 1 7 2.5v3A1.5 1.5 0 0 1 5.5 7h-3A1.5 1.5 0 0 1 1 5.5zM2.5 2a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zm6.5.5A1.5 1.5 0 0 1 10.5 1h3A1.5 1.5 0 0 1 15 2.5v3A1.5 1.5 0 0 1 13.5 7h-3A1.5 1.5 0 0 1 9 5.5zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zM1 10.5A1.5 1.5 0 0 1 2.5 9h3A1.5 1.5 0 0 1 7 10.5v3A1.5 1.5 0 0 1 5.5 15h-3A1.5 1.5 0 0 1 1 13.5zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5zm6.5.5A1.5 1.5 0 0 1 10.5 9h3a1.5 1.5 0 0 1 1.5 1.5v3a1.5 1.5 0 0 1-1.5 1.5h-3A1.5 1.5 0 0 1 9 13.5zm1.5-.5a.5.5 0 0 0-.5.5v3a.5.5 0 0 0 .5.5h3a.5.5 0 0 0 .5-.5v-3a.5.5 0 0 0-.5-.5z" }, child: [] }] })(e);
|
|
754
754
|
}
|
|
755
|
-
function
|
|
755
|
+
function yr(e) {
|
|
756
756
|
return H({ tag: "svg", attr: { fill: "currentColor", viewBox: "0 0 16 16" }, child: [{ tag: "path", attr: { d: "M3.5 3.5c-.614-.884-.074-1.962.858-2.5L8 7.226 11.642 1c.932.538 1.472 1.616.858 2.5L8.81 8.61l1.556 2.661a2.5 2.5 0 1 1-.794.637L8 9.73l-1.572 2.177a2.5 2.5 0 1 1-.794-.637L7.19 8.61zm2.5 10a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0m7 0a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0" }, child: [] }] })(e);
|
|
757
757
|
}
|
|
758
|
-
function
|
|
758
|
+
function xr(e) {
|
|
759
759
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "polyline", attr: { points: "23 4 23 10 17 10" }, child: [] }, { tag: "polyline", attr: { points: "1 20 1 14 7 14" }, child: [] }, { tag: "path", attr: { d: "M3.51 9a9 9 0 0 1 14.85-3.36L23 10M1 14l4.64 4.36A9 9 0 0 0 20.49 15" }, child: [] }] })(e);
|
|
760
760
|
}
|
|
761
|
-
function
|
|
761
|
+
function bn(e) {
|
|
762
762
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z" }, child: [] }] })(e);
|
|
763
763
|
}
|
|
764
|
-
function
|
|
764
|
+
function wn(e) {
|
|
765
765
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }, child: [] }] })(e);
|
|
766
766
|
}
|
|
767
|
-
function
|
|
767
|
+
function En(e) {
|
|
768
768
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z" }, child: [] }] })(e);
|
|
769
769
|
}
|
|
770
|
-
function
|
|
770
|
+
function Rn(e) {
|
|
771
771
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }, child: [] }] })(e);
|
|
772
772
|
}
|
|
773
|
-
function
|
|
773
|
+
function Pn(e) {
|
|
774
774
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z" }, child: [] }] })(e);
|
|
775
775
|
}
|
|
776
|
-
function
|
|
776
|
+
function Cr(e) {
|
|
777
777
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M16 9v10H8V9h8m-1.5-6h-5l-1 1H5v2h14V4h-3.5l-1-1zM18 7H6v12c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7z" }, child: [] }] })(e);
|
|
778
778
|
}
|
|
779
779
|
function Ct(e) {
|
|
780
780
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M18 15v3H6v-3H4v3c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-3h-2zm-1-4-1.41-1.41L13 12.17V4h-2v8.17L8.41 9.59 7 11l5 5 5-5z" }, child: [] }] })(e);
|
|
781
781
|
}
|
|
782
|
-
function
|
|
782
|
+
function jr(e) {
|
|
783
783
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M18 15v3H6v-3H4v3c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-3h-2zM7 9l1.41 1.41L11 7.83V16h2V7.83l2.59 2.58L17 9l-5-5-5 5z" }, child: [] }] })(e);
|
|
784
784
|
}
|
|
785
|
-
function
|
|
785
|
+
function Tn(e) {
|
|
786
786
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M10.02 6 8.61 7.41 13.19 12l-4.58 4.59L10.02 18l6-6-6-6z" }, child: [] }] })(e);
|
|
787
787
|
}
|
|
788
|
-
function
|
|
788
|
+
function br(e) {
|
|
789
789
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M20.005 5.995h-1v2h1v8h-1v2h1c1.103 0 2-.897 2-2v-8c0-1.102-.898-2-2-2zm-14 4H15v4H6.005z" }, child: [] }, { tag: "path", attr: { d: "M17.005 17.995V4H20V2h-8v2h3.005v1.995h-11c-1.103 0-2 .897-2 2v8c0 1.103.897 2 2 2h11V20H12v2h8v-2h-2.995v-2.005zm-13-2v-8h11v8h-11z" }, child: [] }] })(e);
|
|
790
790
|
}
|
|
791
|
-
function
|
|
791
|
+
function Fn(e) {
|
|
792
792
|
return H({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M20 2H8c-1.103 0-2 .897-2 2v12c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2V4c0-1.103-.897-2-2-2zM8 16V4h12l.002 12H8z" }, child: [] }, { tag: "path", attr: { d: "M4 8H2v12c0 1.103.897 2 2 2h12v-2H4V8zm8.933 3.519-1.726-1.726-1.414 1.414 3.274 3.274 5.702-6.84-1.538-1.282z" }, child: [] }] })(e);
|
|
793
793
|
}
|
|
794
|
-
function
|
|
794
|
+
function wr(e) {
|
|
795
795
|
return H({ tag: "svg", attr: { viewBox: "0 0 448 512" }, child: [{ tag: "path", attr: { d: "M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z" }, child: [] }] })(e);
|
|
796
796
|
}
|
|
797
|
-
function
|
|
797
|
+
function Sn(e) {
|
|
798
798
|
return H({ tag: "svg", attr: { viewBox: "0 0 320 512" }, child: [{ tag: "path", attr: { d: "M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z" }, child: [] }] })(e);
|
|
799
799
|
}
|
|
800
|
-
function
|
|
800
|
+
function Mn(e) {
|
|
801
801
|
return H({ tag: "svg", attr: { viewBox: "0 0 640 512" }, child: [{ tag: "path", attr: { d: "M128 0C92.7 0 64 28.7 64 64l0 224-44.8 0C8.6 288 0 296.6 0 307.2C0 349.6 34.4 384 76.8 384L320 384l0-96-192 0 0-224 320 0 0 32 64 0 0-32c0-35.3-28.7-64-64-64L128 0zM512 128l-112 0c-26.5 0-48 21.5-48 48l0 288c0 26.5 21.5 48 48 48l192 0c26.5 0 48-21.5 48-48l0-208-96 0c-17.7 0-32-14.3-32-32l0-96zm32 0l0 96 96 0-96-96z" }, child: [] }] })(e);
|
|
802
802
|
}
|
|
803
803
|
function Ue(e) {
|
|
@@ -806,7 +806,7 @@ function Ue(e) {
|
|
|
806
806
|
function It(e) {
|
|
807
807
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M64 464l256 0c8.8 0 16-7.2 16-16l0-288-80 0c-17.7 0-32-14.3-32-32l0-80L64 48c-8.8 0-16 7.2-16 16l0 384c0 8.8 7.2 16 16 16zM0 64C0 28.7 28.7 0 64 0L229.5 0c17 0 33.3 6.7 45.3 18.7l90.5 90.5c12 12 18.7 28.3 18.7 45.3L384 448c0 35.3-28.7 64-64 64L64 512c-35.3 0-64-28.7-64-64L0 64zM192 272l0 128c0 6.5-3.9 12.3-9.9 14.8s-12.9 1.1-17.4-3.5L129.4 376 112 376c-8.8 0-16-7.2-16-16l0-48c0-8.8 7.2-16 16-16l17.4 0 35.3-35.3c4.6-4.6 11.5-5.9 17.4-3.5s9.9 8.3 9.9 14.8zm85.8-4c11.6 20 18.2 43.3 18.2 68s-6.6 48-18.2 68c-6.6 11.5-21.3 15.4-32.8 8.8s-15.4-21.3-8.8-32.8c7.5-12.9 11.8-27.9 11.8-44s-4.3-31.1-11.8-44c-6.6-11.5-2.7-26.2 8.8-32.8s26.2-2.7 32.8 8.8z" }, child: [] }] })(e);
|
|
808
808
|
}
|
|
809
|
-
function
|
|
809
|
+
function pe(e) {
|
|
810
810
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M64 464c-8.8 0-16-7.2-16-16L48 64c0-8.8 7.2-16 16-16l160 0 0 80c0 17.7 14.3 32 32 32l80 0 0 288c0 8.8-7.2 16-16 16L64 464zM64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-293.5c0-17-6.7-33.3-18.7-45.3L274.7 18.7C262.7 6.7 246.5 0 229.5 0L64 0zm97 289c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0L79 303c-9.4 9.4-9.4 24.6 0 33.9l48 48c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-31-31 31-31zM257 255c-9.4-9.4-24.6-9.4-33.9 0s-9.4 24.6 0 33.9l31 31-31 31c-9.4 9.4-9.4 24.6 0 33.9s24.6 9.4 33.9 0l48-48c9.4-9.4 9.4-24.6 0-33.9l-48-48z" }, child: [] }] })(e);
|
|
811
811
|
}
|
|
812
812
|
function $t(e) {
|
|
@@ -815,10 +815,10 @@ function $t(e) {
|
|
|
815
815
|
function ot(e) {
|
|
816
816
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M64 464c-8.8 0-16-7.2-16-16L48 64c0-8.8 7.2-16 16-16l160 0 0 80c0 17.7 14.3 32 32 32l80 0 0 288c0 8.8-7.2 16-16 16L64 464zM64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-293.5c0-17-6.7-33.3-18.7-45.3L274.7 18.7C262.7 6.7 246.5 0 229.5 0L64 0zm96 256a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zm69.2 46.9c-3-4.3-7.9-6.9-13.2-6.9s-10.2 2.6-13.2 6.9l-41.3 59.7-11.9-19.1c-2.9-4.7-8.1-7.5-13.6-7.5s-10.6 2.8-13.6 7.5l-40 64c-3.1 4.9-3.2 11.1-.4 16.2s8.2 8.2 14 8.2l48 0 32 0 40 0 72 0c6 0 11.4-3.3 14.2-8.6s2.4-11.6-1-16.5l-72-104z" }, child: [] }] })(e);
|
|
817
817
|
}
|
|
818
|
-
function
|
|
818
|
+
function Ln(e) {
|
|
819
819
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M64 464c-8.8 0-16-7.2-16-16L48 64c0-8.8 7.2-16 16-16l160 0 0 80c0 17.7 14.3 32 32 32l80 0 0 288c0 8.8-7.2 16-16 16L64 464zM64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-293.5c0-17-6.7-33.3-18.7-45.3L274.7 18.7C262.7 6.7 246.5 0 229.5 0L64 0zm56 256c-13.3 0-24 10.7-24 24s10.7 24 24 24l144 0c13.3 0 24-10.7 24-24s-10.7-24-24-24l-144 0zm0 96c-13.3 0-24 10.7-24 24s10.7 24 24 24l144 0c13.3 0 24-10.7 24-24s-10.7-24-24-24l-144 0z" }, child: [] }] })(e);
|
|
820
820
|
}
|
|
821
|
-
function
|
|
821
|
+
function On(e) {
|
|
822
822
|
return H({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { d: "M64 464l48 0 0 48-48 0c-35.3 0-64-28.7-64-64L0 64C0 28.7 28.7 0 64 0L229.5 0c17 0 33.3 6.7 45.3 18.7l90.5 90.5c12 12 18.7 28.3 18.7 45.3L384 304l-48 0 0-144-80 0c-17.7 0-32-14.3-32-32l0-80L64 48c-8.8 0-16 7.2-16 16l0 384c0 8.8 7.2 16 16 16zM176 352l32 0c30.9 0 56 25.1 56 56s-25.1 56-56 56l-16 0 0 32c0 8.8-7.2 16-16 16s-16-7.2-16-16l0-48 0-80c0-8.8 7.2-16 16-16zm32 80c13.3 0 24-10.7 24-24s-10.7-24-24-24l-16 0 0 48 16 0zm96-80l32 0c26.5 0 48 21.5 48 48l0 64c0 26.5-21.5 48-48 48l-32 0c-8.8 0-16-7.2-16-16l0-128c0-8.8 7.2-16 16-16zm32 128c8.8 0 16-7.2 16-16l0-64c0-8.8-7.2-16-16-16l-16 0 0 96 16 0zm80-112c0-8.8 7.2-16 16-16l48 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-32 0 0 32 32 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-32 0 0 48c0 8.8-7.2 16-16 16s-16-7.2-16-16l0-64 0-64z" }, child: [] }] })(e);
|
|
823
823
|
}
|
|
824
824
|
function Bt(e) {
|
|
@@ -830,7 +830,7 @@ function Ht(e) {
|
|
|
830
830
|
function Wt(e) {
|
|
831
831
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M48 448L48 64c0-8.8 7.2-16 16-16l160 0 0 80c0 17.7 14.3 32 32 32l80 0 0 288c0 8.8-7.2 16-16 16L64 464c-8.8 0-16-7.2-16-16zM64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-293.5c0-17-6.7-33.3-18.7-45.3L274.7 18.7C262.7 6.7 246.5 0 229.5 0L64 0zm55 241.1c-3.8-12.7-17.2-19.9-29.9-16.1s-19.9 17.2-16.1 29.9l48 160c3 10.2 12.4 17.1 23 17.1s19.9-7 23-17.1l25-83.4 25 83.4c3 10.2 12.4 17.1 23 17.1s19.9-7 23-17.1l48-160c3.8-12.7-3.4-26.1-16.1-29.9s-26.1 3.4-29.9 16.1l-25 83.4-25-83.4c-3-10.2-12.4-17.1-23-17.1s-19.9 7-23 17.1l-25 83.4-25-83.4z" }, child: [] }] })(e);
|
|
832
832
|
}
|
|
833
|
-
function
|
|
833
|
+
function kn(e) {
|
|
834
834
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M64 464c-8.8 0-16-7.2-16-16L48 64c0-8.8 7.2-16 16-16l48 0c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16l48 0 0 80c0 17.7 14.3 32 32 32l80 0 0 288c0 8.8-7.2 16-16 16L64 464zM64 0C28.7 0 0 28.7 0 64L0 448c0 35.3 28.7 64 64 64l256 0c35.3 0 64-28.7 64-64l0-293.5c0-17-6.7-33.3-18.7-45.3L274.7 18.7C262.7 6.7 246.5 0 229.5 0L64 0zm48 112c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm0 64c0 8.8 7.2 16 16 16l32 0c8.8 0 16-7.2 16-16s-7.2-16-16-16l-32 0c-8.8 0-16 7.2-16 16zm-6.3 71.8L82.1 335.9c-1.4 5.4-2.1 10.9-2.1 16.4c0 35.2 28.8 63.7 64 63.7s64-28.5 64-63.7c0-5.5-.7-11.1-2.1-16.4l-23.5-88.2c-3.7-14-16.4-23.8-30.9-23.8l-14.8 0c-14.5 0-27.2 9.7-30.9 23.8zM128 336l32 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-32 0c-8.8 0-16-7.2-16-16s7.2-16 16-16z" }, child: [] }] })(e);
|
|
835
835
|
}
|
|
836
836
|
function qe(e) {
|
|
@@ -844,78 +844,84 @@ function mt(e) {
|
|
|
844
844
|
}
|
|
845
845
|
const Be = (e = () => {
|
|
846
846
|
}) => {
|
|
847
|
-
const [r, n] = L(!1), s = de(null), a = (
|
|
848
|
-
var
|
|
849
|
-
(
|
|
847
|
+
const [r, n] = L(!1), s = de(null), a = (i) => {
|
|
848
|
+
var c;
|
|
849
|
+
(c = s.current) != null && c.contains(i.target) ? n(!1) : (n(!0), e(i, s));
|
|
850
850
|
};
|
|
851
851
|
return se(() => (document.addEventListener("click", a, !0), document.addEventListener("mousedown", a, !0), () => {
|
|
852
852
|
document.removeEventListener("click", a, !0), document.removeEventListener("mousedown", a, !0);
|
|
853
853
|
}), []), { ref: s, isClicked: r, setIsClicked: n };
|
|
854
|
-
},
|
|
854
|
+
}, Er = Ie(), _n = ({ children: e, layout: r }) => {
|
|
855
855
|
const [n, s] = L(() => a(r));
|
|
856
|
-
function a(
|
|
857
|
-
return ["list", "grid"].includes(
|
|
856
|
+
function a(i) {
|
|
857
|
+
return ["list", "grid"].includes(i) ? i : "grid";
|
|
858
858
|
}
|
|
859
|
-
return /* @__PURE__ */ t.jsx(
|
|
860
|
-
}, Se = () => $e(
|
|
859
|
+
return /* @__PURE__ */ t.jsx(Er.Provider, { value: { activeLayout: n, setActiveLayout: s }, children: e });
|
|
860
|
+
}, Se = () => $e(Er), Nn = ({ setShowToggleViewMenu: e, onLayoutChange: r }) => {
|
|
861
861
|
const n = Be(() => {
|
|
862
862
|
e(!1);
|
|
863
|
-
}), { activeLayout: s, setActiveLayout: a } = Se(),
|
|
863
|
+
}), { activeLayout: s, setActiveLayout: a } = Se(), i = [
|
|
864
864
|
{
|
|
865
865
|
key: "grid",
|
|
866
866
|
name: "Grid",
|
|
867
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
867
|
+
icon: /* @__PURE__ */ t.jsx(gr, { size: 18 })
|
|
868
868
|
},
|
|
869
869
|
{
|
|
870
870
|
key: "list",
|
|
871
871
|
name: "List",
|
|
872
872
|
icon: /* @__PURE__ */ t.jsx(Ue, { size: 18 })
|
|
873
873
|
}
|
|
874
|
-
],
|
|
874
|
+
], c = (l) => {
|
|
875
875
|
a(l), r(l), e(!1);
|
|
876
876
|
};
|
|
877
|
-
return /* @__PURE__ */ t.jsx("div", { ref: n.ref, className: "toggle-view", role: "dropdown", children: /* @__PURE__ */ t.jsx("ul", { role: "menu", "aria-orientation": "vertical", children:
|
|
877
|
+
return /* @__PURE__ */ t.jsx("div", { ref: n.ref, className: "toggle-view", role: "dropdown", children: /* @__PURE__ */ t.jsx("ul", { role: "menu", "aria-orientation": "vertical", children: i.map((l) => /* @__PURE__ */ t.jsxs(
|
|
878
878
|
"li",
|
|
879
879
|
{
|
|
880
880
|
role: "menuitem",
|
|
881
|
-
onClick: () =>
|
|
882
|
-
onKeyDown: () =>
|
|
881
|
+
onClick: () => c(l.key),
|
|
882
|
+
onKeyDown: () => c(l.key),
|
|
883
883
|
children: [
|
|
884
|
-
/* @__PURE__ */ t.jsx("span", { children: l.key === s && /* @__PURE__ */ t.jsx(
|
|
884
|
+
/* @__PURE__ */ t.jsx("span", { children: l.key === s && /* @__PURE__ */ t.jsx(wr, { size: 13 }) }),
|
|
885
885
|
/* @__PURE__ */ t.jsx("span", { children: l.icon }),
|
|
886
886
|
/* @__PURE__ */ t.jsx("span", { children: l.name })
|
|
887
887
|
]
|
|
888
888
|
},
|
|
889
889
|
l.key
|
|
890
890
|
)) }) });
|
|
891
|
-
},
|
|
891
|
+
}, Rr = Ie(), zn = ({ children: e, filesData: r, onError: n }) => {
|
|
892
892
|
const [s, a] = L([]);
|
|
893
893
|
se(() => {
|
|
894
894
|
a(r);
|
|
895
895
|
}, [r]);
|
|
896
|
-
const
|
|
897
|
-
return /* @__PURE__ */ t.jsx(
|
|
898
|
-
}, Ge = () => $e(
|
|
899
|
-
const
|
|
896
|
+
const i = (c) => c.isDirectory ? s.filter((l) => l.path === `${c.path}/${l.name}`) : [];
|
|
897
|
+
return /* @__PURE__ */ t.jsx(Rr.Provider, { value: { files: s, setFiles: a, getChildren: i, onError: n }, children: e });
|
|
898
|
+
}, Ge = () => $e(Rr), Yt = (e) => e.sort((r, n) => r.name.localeCompare(n.name)), An = (e) => {
|
|
899
|
+
const r = e.filter((i) => i.isDirectory), n = e.filter((i) => !i.isDirectory), s = Yt(r), a = Yt(n);
|
|
900
|
+
return [...s, ...a];
|
|
901
|
+
}, Pr = Ie(), Dn = ({ children: e, initialPath: r }) => {
|
|
902
|
+
const { files: n } = Ge(), s = de(!1), [a, i] = L(""), [c, l] = L(null), [d, p] = L([]);
|
|
900
903
|
return se(() => {
|
|
901
|
-
Array.isArray(n) && n.length > 0 && (
|
|
904
|
+
Array.isArray(n) && n.length > 0 && (p(() => {
|
|
905
|
+
const f = n.filter((h) => h.path === `${a}/${h.name}`);
|
|
906
|
+
return An(f);
|
|
907
|
+
}), l(() => n.find((f) => f.path === a) ?? null));
|
|
902
908
|
}, [n, a]), se(() => {
|
|
903
|
-
!s.current && Array.isArray(n) && n.length > 0 && (
|
|
909
|
+
!s.current && Array.isArray(n) && n.length > 0 && (i(n.some((f) => f.path === r) ? r : ""), s.current = !0);
|
|
904
910
|
}, [r, n]), /* @__PURE__ */ t.jsx(
|
|
905
|
-
|
|
911
|
+
Pr.Provider,
|
|
906
912
|
{
|
|
907
913
|
value: {
|
|
908
914
|
currentPath: a,
|
|
909
|
-
setCurrentPath:
|
|
910
|
-
currentFolder:
|
|
915
|
+
setCurrentPath: i,
|
|
916
|
+
currentFolder: c,
|
|
911
917
|
setCurrentFolder: l,
|
|
912
918
|
currentPathFiles: d,
|
|
913
|
-
setCurrentPathFiles:
|
|
919
|
+
setCurrentPathFiles: p
|
|
914
920
|
},
|
|
915
921
|
children: e
|
|
916
922
|
}
|
|
917
923
|
);
|
|
918
|
-
}, Ee = () => $e(
|
|
924
|
+
}, Ee = () => $e(Pr), Le = (e, r, ...n) => {
|
|
919
925
|
try {
|
|
920
926
|
if (typeof e == "function")
|
|
921
927
|
e(...n);
|
|
@@ -926,24 +932,24 @@ const Be = (e = () => {
|
|
|
926
932
|
} catch (s) {
|
|
927
933
|
console.error(s.message);
|
|
928
934
|
}
|
|
929
|
-
},
|
|
935
|
+
}, Tr = Ie(), In = ({ children: e, onDownload: r }) => {
|
|
930
936
|
const [n, s] = L([]), a = () => {
|
|
931
937
|
Le(r, "onDownload", n);
|
|
932
938
|
};
|
|
933
|
-
return /* @__PURE__ */ t.jsx(
|
|
934
|
-
}, Fe = () => $e(
|
|
935
|
-
const [
|
|
936
|
-
|
|
937
|
-
files:
|
|
938
|
-
isMoving:
|
|
939
|
-
});
|
|
940
|
-
},
|
|
941
|
-
if (
|
|
942
|
-
const h =
|
|
943
|
-
Le(r, "onPaste", h,
|
|
939
|
+
return /* @__PURE__ */ t.jsx(Tr.Provider, { value: { selectedFiles: n, setSelectedFiles: s, handleDownload: a }, children: e });
|
|
940
|
+
}, Fe = () => $e(Tr), Fr = Ie(), $n = ({ children: e, onPaste: r, onCut: n, onCopy: s }) => {
|
|
941
|
+
const [a, i] = L(null), { selectedFiles: c, setSelectedFiles: l } = Fe(), d = (f) => {
|
|
942
|
+
i({
|
|
943
|
+
files: c,
|
|
944
|
+
isMoving: f
|
|
945
|
+
}), f ? n && n(c) : s && s(c);
|
|
946
|
+
}, p = (f) => {
|
|
947
|
+
if (f && !f.isDirectory) return;
|
|
948
|
+
const h = a.files, w = a.isMoving ? "move" : "copy";
|
|
949
|
+
Le(r, "onPaste", h, f, w), a.isMoving && i(null), l([]);
|
|
944
950
|
};
|
|
945
|
-
return /* @__PURE__ */ t.jsx(
|
|
946
|
-
}, Je = () => $e(
|
|
951
|
+
return /* @__PURE__ */ t.jsx(Fr.Provider, { value: { clipBoard: a, setClipBoard: i, handleCutCopy: d, handlePasting: p }, children: e });
|
|
952
|
+
}, Je = () => $e(Fr), Sr = ({
|
|
947
953
|
allowCreateFolder: e = !0,
|
|
948
954
|
allowUploadFile: r = !0,
|
|
949
955
|
onLayoutChange: n,
|
|
@@ -951,15 +957,15 @@ const Be = (e = () => {
|
|
|
951
957
|
triggerAction: a
|
|
952
958
|
}) => {
|
|
953
959
|
var b;
|
|
954
|
-
const [
|
|
960
|
+
const [i, c] = L(!1), { currentFolder: l } = Ee(), { selectedFiles: d, setSelectedFiles: p, handleDownload: f } = Fe(), { clipBoard: h, setClipBoard: w, handleCutCopy: S, handlePasting: M } = Je(), { activeLayout: z } = Se(), D = [
|
|
955
961
|
{
|
|
956
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
962
|
+
icon: /* @__PURE__ */ t.jsx(mr, { size: 17, strokeWidth: 0.3 }),
|
|
957
963
|
text: "New folder",
|
|
958
964
|
permission: e,
|
|
959
965
|
onClick: () => a.show("createFolder")
|
|
960
966
|
},
|
|
961
967
|
{
|
|
962
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
968
|
+
icon: /* @__PURE__ */ t.jsx(jr, { size: 18 }),
|
|
963
969
|
text: "Upload",
|
|
964
970
|
permission: r,
|
|
965
971
|
onClick: () => a.show("uploadFile")
|
|
@@ -967,40 +973,40 @@ const Be = (e = () => {
|
|
|
967
973
|
{
|
|
968
974
|
icon: /* @__PURE__ */ t.jsx(mt, { size: 18 }),
|
|
969
975
|
text: "Paste",
|
|
970
|
-
permission: !!
|
|
976
|
+
permission: !!h,
|
|
971
977
|
onClick: j
|
|
972
978
|
}
|
|
973
979
|
], C = [
|
|
974
980
|
{
|
|
975
|
-
icon: z === "grid" ? /* @__PURE__ */ t.jsx(
|
|
981
|
+
icon: z === "grid" ? /* @__PURE__ */ t.jsx(gr, { size: 16 }) : /* @__PURE__ */ t.jsx(Ue, { size: 16 }),
|
|
976
982
|
title: "Change View",
|
|
977
|
-
onClick: () =>
|
|
983
|
+
onClick: () => c((u) => !u)
|
|
978
984
|
},
|
|
979
985
|
{
|
|
980
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
986
|
+
icon: /* @__PURE__ */ t.jsx(xr, { size: 16 }),
|
|
981
987
|
title: "Refresh",
|
|
982
988
|
onClick: () => {
|
|
983
|
-
Le(s, "onRefresh"),
|
|
989
|
+
Le(s, "onRefresh"), w(null);
|
|
984
990
|
}
|
|
985
991
|
}
|
|
986
992
|
];
|
|
987
993
|
function j() {
|
|
988
|
-
|
|
994
|
+
M(l);
|
|
989
995
|
}
|
|
990
996
|
const y = () => {
|
|
991
|
-
f(),
|
|
997
|
+
f(), p([]);
|
|
992
998
|
};
|
|
993
999
|
return d.length > 0 ? /* @__PURE__ */ t.jsx("div", { className: "toolbar file-selected", children: /* @__PURE__ */ t.jsxs("div", { className: "file-action-container", children: [
|
|
994
1000
|
/* @__PURE__ */ t.jsxs("div", { children: [
|
|
995
|
-
/* @__PURE__ */ t.jsxs("button", { className: "item-action file-action", onClick: () =>
|
|
996
|
-
/* @__PURE__ */ t.jsx(
|
|
1001
|
+
/* @__PURE__ */ t.jsxs("button", { className: "item-action file-action", onClick: () => S(!0), children: [
|
|
1002
|
+
/* @__PURE__ */ t.jsx(yr, { size: 18 }),
|
|
997
1003
|
/* @__PURE__ */ t.jsx("span", { children: "Cut" })
|
|
998
1004
|
] }),
|
|
999
|
-
/* @__PURE__ */ t.jsxs("button", { className: "item-action file-action", onClick: () =>
|
|
1000
|
-
/* @__PURE__ */ t.jsx(
|
|
1005
|
+
/* @__PURE__ */ t.jsxs("button", { className: "item-action file-action", onClick: () => S(!1), children: [
|
|
1006
|
+
/* @__PURE__ */ t.jsx(vr, { strokeWidth: 0.1, size: 17 }),
|
|
1001
1007
|
/* @__PURE__ */ t.jsx("span", { children: "Copy" })
|
|
1002
1008
|
] }),
|
|
1003
|
-
((b =
|
|
1009
|
+
((b = h == null ? void 0 : h.files) == null ? void 0 : b.length) > 0 && /* @__PURE__ */ t.jsxs(
|
|
1004
1010
|
"button",
|
|
1005
1011
|
{
|
|
1006
1012
|
className: "item-action file-action",
|
|
@@ -1017,7 +1023,7 @@ const Be = (e = () => {
|
|
|
1017
1023
|
className: "item-action file-action",
|
|
1018
1024
|
onClick: () => a.show("rename"),
|
|
1019
1025
|
children: [
|
|
1020
|
-
/* @__PURE__ */ t.jsx(
|
|
1026
|
+
/* @__PURE__ */ t.jsx(br, { size: 19 }),
|
|
1021
1027
|
/* @__PURE__ */ t.jsx("span", { children: "Rename" })
|
|
1022
1028
|
]
|
|
1023
1029
|
}
|
|
@@ -1032,7 +1038,7 @@ const Be = (e = () => {
|
|
|
1032
1038
|
className: "item-action file-action",
|
|
1033
1039
|
onClick: () => a.show("delete"),
|
|
1034
1040
|
children: [
|
|
1035
|
-
/* @__PURE__ */ t.jsx(
|
|
1041
|
+
/* @__PURE__ */ t.jsx(Cr, { size: 19 }),
|
|
1036
1042
|
/* @__PURE__ */ t.jsx("span", { children: "Delete" })
|
|
1037
1043
|
]
|
|
1038
1044
|
}
|
|
@@ -1043,7 +1049,7 @@ const Be = (e = () => {
|
|
|
1043
1049
|
{
|
|
1044
1050
|
className: "item-action file-action",
|
|
1045
1051
|
title: "Clear selection",
|
|
1046
|
-
onClick: () =>
|
|
1052
|
+
onClick: () => p([]),
|
|
1047
1053
|
children: [
|
|
1048
1054
|
/* @__PURE__ */ t.jsxs("span", { children: [
|
|
1049
1055
|
d.length,
|
|
@@ -1051,12 +1057,12 @@ const Be = (e = () => {
|
|
|
1051
1057
|
d.length > 1 && "s",
|
|
1052
1058
|
" selected"
|
|
1053
1059
|
] }),
|
|
1054
|
-
/* @__PURE__ */ t.jsx(
|
|
1060
|
+
/* @__PURE__ */ t.jsx(wn, { size: 18 })
|
|
1055
1061
|
]
|
|
1056
1062
|
}
|
|
1057
1063
|
)
|
|
1058
1064
|
] }) }) : /* @__PURE__ */ t.jsx("div", { className: "toolbar", children: /* @__PURE__ */ t.jsxs("div", { className: "fm-toolbar", children: [
|
|
1059
|
-
/* @__PURE__ */ t.jsx("div", { children:
|
|
1065
|
+
/* @__PURE__ */ t.jsx("div", { children: D.filter((u) => u.permission).map((u, g) => /* @__PURE__ */ t.jsxs("button", { className: "item-action", onClick: u.onClick, children: [
|
|
1060
1066
|
u.icon,
|
|
1061
1067
|
/* @__PURE__ */ t.jsx("span", { children: u.text })
|
|
1062
1068
|
] }, g)) }),
|
|
@@ -1065,20 +1071,20 @@ const Be = (e = () => {
|
|
|
1065
1071
|
/* @__PURE__ */ t.jsx("button", { className: "item-action icon-only", title: u.title, onClick: u.onClick, children: u.icon }),
|
|
1066
1072
|
g !== C.length - 1 && /* @__PURE__ */ t.jsx("div", { className: "item-separator" })
|
|
1067
1073
|
] }, g)),
|
|
1068
|
-
|
|
1069
|
-
|
|
1074
|
+
i && /* @__PURE__ */ t.jsx(
|
|
1075
|
+
Nn,
|
|
1070
1076
|
{
|
|
1071
|
-
setShowToggleViewMenu:
|
|
1077
|
+
setShowToggleViewMenu: c,
|
|
1072
1078
|
onLayoutChange: n
|
|
1073
1079
|
}
|
|
1074
1080
|
)
|
|
1075
1081
|
] })
|
|
1076
1082
|
] }) });
|
|
1077
1083
|
};
|
|
1078
|
-
|
|
1079
|
-
var
|
|
1080
|
-
function
|
|
1081
|
-
if (!
|
|
1084
|
+
Sr.displayName = "Toolbar";
|
|
1085
|
+
var Bn = process.env.NODE_ENV === "production";
|
|
1086
|
+
function Hn(e, r) {
|
|
1087
|
+
if (!Bn) {
|
|
1082
1088
|
if (e)
|
|
1083
1089
|
return;
|
|
1084
1090
|
var n = "Warning: " + r;
|
|
@@ -1099,45 +1105,45 @@ function $n(e, r) {
|
|
|
1099
1105
|
*
|
|
1100
1106
|
* @license MIT
|
|
1101
1107
|
*/
|
|
1102
|
-
var
|
|
1108
|
+
var Wn = class extends Error {
|
|
1103
1109
|
constructor(e) {
|
|
1104
1110
|
super(`react-collapsed: ${e}`);
|
|
1105
1111
|
}
|
|
1106
|
-
}, Ke = (...e) =>
|
|
1107
|
-
function
|
|
1112
|
+
}, Ke = (...e) => Hn(e[0], `[react-collapsed] -- ${e[1]}`);
|
|
1113
|
+
function Mr(e) {
|
|
1108
1114
|
const r = de(e);
|
|
1109
1115
|
return se(() => {
|
|
1110
1116
|
r.current = e;
|
|
1111
|
-
}),
|
|
1117
|
+
}), fr((...n) => {
|
|
1112
1118
|
var s;
|
|
1113
1119
|
return (s = r.current) == null ? void 0 : s.call(r, ...n);
|
|
1114
1120
|
}, []);
|
|
1115
1121
|
}
|
|
1116
|
-
function
|
|
1117
|
-
const [s, a] = L(r),
|
|
1118
|
-
(
|
|
1119
|
-
const
|
|
1120
|
-
|
|
1122
|
+
function Vn(e, r, n) {
|
|
1123
|
+
const [s, a] = L(r), i = de(typeof e < "u"), c = i.current ? e : s, l = Mr(n), d = fr(
|
|
1124
|
+
(p) => {
|
|
1125
|
+
const h = typeof p == "function" ? p(c) : p;
|
|
1126
|
+
i.current || a(h), l == null || l(h);
|
|
1121
1127
|
},
|
|
1122
|
-
[l,
|
|
1128
|
+
[l, c]
|
|
1123
1129
|
);
|
|
1124
1130
|
return se(() => {
|
|
1125
1131
|
Ke(
|
|
1126
|
-
!(
|
|
1132
|
+
!(i.current && e == null),
|
|
1127
1133
|
"`isExpanded` state is changing from controlled to uncontrolled. useCollapse should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled collapse for the lifetime of the component. Check the `isExpanded` prop."
|
|
1128
1134
|
), Ke(
|
|
1129
|
-
!(!
|
|
1135
|
+
!(!i.current && e != null),
|
|
1130
1136
|
"`isExpanded` state is changing from uncontrolled to controlled. useCollapse should not switch from uncontrolled to controlled (or vice versa). Decide between using a controlled or uncontrolled collapse for the lifetime of the component. Check the `isExpanded` prop."
|
|
1131
1137
|
);
|
|
1132
|
-
}, [e]), [
|
|
1138
|
+
}, [e]), [c, d];
|
|
1133
1139
|
}
|
|
1134
|
-
var
|
|
1135
|
-
function
|
|
1140
|
+
var Yn = "(prefers-reduced-motion: reduce)";
|
|
1141
|
+
function Un() {
|
|
1136
1142
|
const [e, r] = L(!1);
|
|
1137
1143
|
return se(() => {
|
|
1138
1144
|
if (typeof window > "u" || typeof window.matchMedia != "function")
|
|
1139
1145
|
return;
|
|
1140
|
-
const n = window.matchMedia(
|
|
1146
|
+
const n = window.matchMedia(Yn);
|
|
1141
1147
|
r(n.matches);
|
|
1142
1148
|
const s = (a) => {
|
|
1143
1149
|
r(a.matches);
|
|
@@ -1152,49 +1158,49 @@ function Vn() {
|
|
|
1152
1158
|
};
|
|
1153
1159
|
}, []), e;
|
|
1154
1160
|
}
|
|
1155
|
-
var
|
|
1161
|
+
var qn = De.useId || (() => {
|
|
1156
1162
|
});
|
|
1157
|
-
function
|
|
1158
|
-
return
|
|
1159
|
-
}
|
|
1160
|
-
var
|
|
1161
|
-
function
|
|
1162
|
-
const r = e || (at ?
|
|
1163
|
-
return
|
|
1164
|
-
n === null && s(
|
|
1163
|
+
function Kn() {
|
|
1164
|
+
return qn() ?? "";
|
|
1165
|
+
}
|
|
1166
|
+
var Xn = typeof window < "u" ? De.useLayoutEffect : De.useEffect, at = !1, Gn = 0, Ut = () => ++Gn;
|
|
1167
|
+
function Jn(e) {
|
|
1168
|
+
const r = e || (at ? Ut() : null), [n, s] = De.useState(r);
|
|
1169
|
+
return Xn(() => {
|
|
1170
|
+
n === null && s(Ut());
|
|
1165
1171
|
}, []), De.useEffect(() => {
|
|
1166
1172
|
at === !1 && (at = !0);
|
|
1167
1173
|
}, []), n != null ? String(n) : void 0;
|
|
1168
1174
|
}
|
|
1169
|
-
function
|
|
1170
|
-
const r =
|
|
1175
|
+
function Zn(e) {
|
|
1176
|
+
const r = Kn(), n = Jn(e);
|
|
1171
1177
|
return typeof e == "string" ? e : typeof r == "string" ? r : n;
|
|
1172
1178
|
}
|
|
1173
|
-
function
|
|
1179
|
+
function Qn(e, r) {
|
|
1174
1180
|
const n = performance.now(), s = {};
|
|
1175
1181
|
function a() {
|
|
1176
|
-
s.id = requestAnimationFrame((
|
|
1177
|
-
|
|
1182
|
+
s.id = requestAnimationFrame((i) => {
|
|
1183
|
+
i - n > r ? e() : a();
|
|
1178
1184
|
});
|
|
1179
1185
|
}
|
|
1180
1186
|
return a(), s;
|
|
1181
1187
|
}
|
|
1182
|
-
function
|
|
1188
|
+
function qt(e) {
|
|
1183
1189
|
e.id && cancelAnimationFrame(e.id);
|
|
1184
1190
|
}
|
|
1185
|
-
function
|
|
1191
|
+
function Kt(e) {
|
|
1186
1192
|
return e != null && e.current ? e.current.scrollHeight : (Ke(
|
|
1187
1193
|
!0,
|
|
1188
1194
|
"Was not able to find a ref to the collapse element via `getCollapseProps`. Ensure that the element exposes its `ref` prop. If it exposes the ref prop under a different name (like `innerRef`), use the `refKey` property to change it. Example:\n\nconst collapseProps = getCollapseProps({refKey: 'innerRef'})"
|
|
1189
1195
|
), 0);
|
|
1190
1196
|
}
|
|
1191
|
-
function
|
|
1197
|
+
function es(e) {
|
|
1192
1198
|
if (!e || typeof e == "string")
|
|
1193
1199
|
return 0;
|
|
1194
1200
|
const r = e / 36;
|
|
1195
1201
|
return Math.round((4 + 15 * r ** 0.25 + r / 5) * 10);
|
|
1196
1202
|
}
|
|
1197
|
-
function
|
|
1203
|
+
function ts(e, r) {
|
|
1198
1204
|
if (e != null)
|
|
1199
1205
|
if (typeof e == "function")
|
|
1200
1206
|
e(r);
|
|
@@ -1202,17 +1208,17 @@ function Qn(e, r) {
|
|
|
1202
1208
|
try {
|
|
1203
1209
|
e.current = r;
|
|
1204
1210
|
} catch {
|
|
1205
|
-
throw new
|
|
1211
|
+
throw new Wn(`Cannot assign value "${r}" to ref "${e}"`);
|
|
1206
1212
|
}
|
|
1207
1213
|
}
|
|
1208
|
-
function
|
|
1214
|
+
function Xt(...e) {
|
|
1209
1215
|
return e.every((r) => r == null) ? null : (r) => {
|
|
1210
1216
|
e.forEach((n) => {
|
|
1211
|
-
|
|
1217
|
+
ts(n, r);
|
|
1212
1218
|
});
|
|
1213
1219
|
};
|
|
1214
1220
|
}
|
|
1215
|
-
function
|
|
1221
|
+
function rs(e) {
|
|
1216
1222
|
let r = (n) => {
|
|
1217
1223
|
};
|
|
1218
1224
|
r = (n) => {
|
|
@@ -1235,101 +1241,101 @@ After: <div {...getCollapseProps()}>
|
|
|
1235
1241
|
r(e);
|
|
1236
1242
|
}, [e]);
|
|
1237
1243
|
}
|
|
1238
|
-
var
|
|
1239
|
-
function
|
|
1244
|
+
var ns = typeof window > "u" ? se : un;
|
|
1245
|
+
function ss({
|
|
1240
1246
|
duration: e,
|
|
1241
1247
|
easing: r = "cubic-bezier(0.4, 0, 0.2, 1)",
|
|
1242
1248
|
onTransitionStateChange: n = () => {
|
|
1243
1249
|
},
|
|
1244
1250
|
isExpanded: s,
|
|
1245
1251
|
defaultExpanded: a = !1,
|
|
1246
|
-
hasDisabledAnimation:
|
|
1247
|
-
id:
|
|
1252
|
+
hasDisabledAnimation: i,
|
|
1253
|
+
id: c,
|
|
1248
1254
|
...l
|
|
1249
1255
|
} = {}) {
|
|
1250
|
-
const d =
|
|
1256
|
+
const d = Mr(n), p = Zn(c ? `${c}` : void 0), [f, h] = Vn(
|
|
1251
1257
|
s,
|
|
1252
1258
|
a
|
|
1253
|
-
),
|
|
1254
|
-
|
|
1259
|
+
), w = de(f), [S, M] = L(!1), z = Un(), D = i ?? z, C = de(), j = de(), y = de(null), [b, u] = L(null);
|
|
1260
|
+
rs(y);
|
|
1255
1261
|
const g = `${l.collapsedHeight || 0}px`;
|
|
1256
|
-
function
|
|
1262
|
+
function _(x) {
|
|
1257
1263
|
if (!y.current)
|
|
1258
1264
|
return;
|
|
1259
1265
|
const R = y.current;
|
|
1260
1266
|
for (const F in x) {
|
|
1261
|
-
const
|
|
1262
|
-
|
|
1267
|
+
const A = x[F];
|
|
1268
|
+
A ? R.style[F] = A : R.style.removeProperty(F);
|
|
1263
1269
|
}
|
|
1264
1270
|
}
|
|
1265
|
-
return
|
|
1266
|
-
if (!y.current || f ===
|
|
1271
|
+
return ns(() => {
|
|
1272
|
+
if (!y.current || f === w.current)
|
|
1267
1273
|
return;
|
|
1268
|
-
|
|
1269
|
-
function R(
|
|
1270
|
-
return
|
|
1274
|
+
w.current = f;
|
|
1275
|
+
function R(N) {
|
|
1276
|
+
return D ? 0 : e ?? es(N);
|
|
1271
1277
|
}
|
|
1272
|
-
const F = (
|
|
1273
|
-
function
|
|
1274
|
-
f ? (
|
|
1278
|
+
const F = (N) => `height ${R(N)}ms ${r}`, A = (N) => {
|
|
1279
|
+
function k() {
|
|
1280
|
+
f ? (_({
|
|
1275
1281
|
height: "",
|
|
1276
1282
|
overflow: "",
|
|
1277
1283
|
transition: "",
|
|
1278
1284
|
display: ""
|
|
1279
|
-
}), d("expandEnd")) : (
|
|
1285
|
+
}), d("expandEnd")) : (_({ transition: "" }), d("collapseEnd")), M(!1);
|
|
1280
1286
|
}
|
|
1281
|
-
j.current &&
|
|
1287
|
+
j.current && qt(j.current), j.current = Qn(k, N);
|
|
1282
1288
|
};
|
|
1283
|
-
return
|
|
1284
|
-
d("expandStart"),
|
|
1289
|
+
return M(!0), f ? C.current = requestAnimationFrame(() => {
|
|
1290
|
+
d("expandStart"), _({
|
|
1285
1291
|
display: "block",
|
|
1286
1292
|
overflow: "hidden",
|
|
1287
1293
|
height: g
|
|
1288
1294
|
}), C.current = requestAnimationFrame(() => {
|
|
1289
1295
|
d("expanding");
|
|
1290
|
-
const
|
|
1291
|
-
|
|
1296
|
+
const N = Kt(y);
|
|
1297
|
+
A(R(N)), y.current && (y.current.style.transition = F(N), y.current.style.height = `${N}px`);
|
|
1292
1298
|
});
|
|
1293
1299
|
}) : C.current = requestAnimationFrame(() => {
|
|
1294
1300
|
d("collapseStart");
|
|
1295
|
-
const
|
|
1296
|
-
|
|
1297
|
-
transition: F(
|
|
1298
|
-
height: `${
|
|
1301
|
+
const N = Kt(y);
|
|
1302
|
+
A(R(N)), _({
|
|
1303
|
+
transition: F(N),
|
|
1304
|
+
height: `${N}px`
|
|
1299
1305
|
}), C.current = requestAnimationFrame(() => {
|
|
1300
|
-
d("collapsing"),
|
|
1306
|
+
d("collapsing"), _({
|
|
1301
1307
|
height: g,
|
|
1302
1308
|
overflow: "hidden"
|
|
1303
1309
|
});
|
|
1304
1310
|
});
|
|
1305
1311
|
}), () => {
|
|
1306
|
-
C.current && cancelAnimationFrame(C.current), j.current &&
|
|
1312
|
+
C.current && cancelAnimationFrame(C.current), j.current && qt(j.current);
|
|
1307
1313
|
};
|
|
1308
1314
|
}, [
|
|
1309
1315
|
f,
|
|
1310
1316
|
g,
|
|
1311
|
-
|
|
1317
|
+
D,
|
|
1312
1318
|
e,
|
|
1313
1319
|
r,
|
|
1314
1320
|
d
|
|
1315
1321
|
]), {
|
|
1316
1322
|
isExpanded: f,
|
|
1317
|
-
setExpanded:
|
|
1323
|
+
setExpanded: h,
|
|
1318
1324
|
getToggleProps(x) {
|
|
1319
|
-
const { disabled: R, onClick: F, refKey:
|
|
1325
|
+
const { disabled: R, onClick: F, refKey: A, ...N } = {
|
|
1320
1326
|
refKey: "ref",
|
|
1321
1327
|
onClick() {
|
|
1322
1328
|
},
|
|
1323
1329
|
disabled: !1,
|
|
1324
1330
|
...x
|
|
1325
|
-
},
|
|
1326
|
-
id: `react-collapsed-toggle-${
|
|
1327
|
-
"aria-controls": `react-collapsed-panel-${
|
|
1331
|
+
}, k = b ? b.tagName === "BUTTON" : void 0, X = x == null ? void 0 : x[A || "ref"], oe = {
|
|
1332
|
+
id: `react-collapsed-toggle-${p}`,
|
|
1333
|
+
"aria-controls": `react-collapsed-panel-${p}`,
|
|
1328
1334
|
"aria-expanded": f,
|
|
1329
|
-
onClick(
|
|
1330
|
-
R || (F == null || F(
|
|
1335
|
+
onClick(he) {
|
|
1336
|
+
R || (F == null || F(he), h((xe) => !xe));
|
|
1331
1337
|
},
|
|
1332
|
-
[
|
|
1338
|
+
[A || "ref"]: Xt(X, u)
|
|
1333
1339
|
}, ae = {
|
|
1334
1340
|
type: "button",
|
|
1335
1341
|
disabled: R ? !0 : void 0
|
|
@@ -1338,25 +1344,25 @@ function rs({
|
|
|
1338
1344
|
role: "button",
|
|
1339
1345
|
tabIndex: R ? -1 : 0
|
|
1340
1346
|
};
|
|
1341
|
-
return
|
|
1347
|
+
return k === !1 ? { ...oe, ...Q, ...N } : k === !0 ? { ...oe, ...ae, ...N } : {
|
|
1342
1348
|
...oe,
|
|
1343
1349
|
...ae,
|
|
1344
1350
|
...Q,
|
|
1345
|
-
...
|
|
1351
|
+
...N
|
|
1346
1352
|
};
|
|
1347
1353
|
},
|
|
1348
1354
|
getCollapseProps(x) {
|
|
1349
|
-
const { style: R, refKey: F } = { refKey: "ref", style: {}, ...x },
|
|
1355
|
+
const { style: R, refKey: F } = { refKey: "ref", style: {}, ...x }, A = x == null ? void 0 : x[F || "ref"];
|
|
1350
1356
|
return {
|
|
1351
|
-
id: `react-collapsed-panel-${
|
|
1357
|
+
id: `react-collapsed-panel-${p}`,
|
|
1352
1358
|
"aria-hidden": !f,
|
|
1353
|
-
"aria-labelledby": `react-collapsed-toggle-${
|
|
1359
|
+
"aria-labelledby": `react-collapsed-toggle-${p}`,
|
|
1354
1360
|
role: "region",
|
|
1355
1361
|
...x,
|
|
1356
|
-
[F || "ref"]:
|
|
1362
|
+
[F || "ref"]: Xt(y, A),
|
|
1357
1363
|
style: {
|
|
1358
1364
|
boxSizing: "border-box",
|
|
1359
|
-
...!
|
|
1365
|
+
...!S && !f ? {
|
|
1360
1366
|
// collapsed and not animating
|
|
1361
1367
|
display: g === "0px" ? "none" : "block",
|
|
1362
1368
|
height: g,
|
|
@@ -1369,8 +1375,8 @@ function rs({
|
|
|
1369
1375
|
}
|
|
1370
1376
|
};
|
|
1371
1377
|
}
|
|
1372
|
-
const
|
|
1373
|
-
const [n, s] = L(e), { getCollapseProps: a } =
|
|
1378
|
+
const os = ({ open: e, children: r }) => {
|
|
1379
|
+
const [n, s] = L(e), { getCollapseProps: a } = ss({
|
|
1374
1380
|
isExpanded: n,
|
|
1375
1381
|
duration: 500
|
|
1376
1382
|
});
|
|
@@ -1378,29 +1384,29 @@ const ns = ({ open: e, children: r }) => {
|
|
|
1378
1384
|
s(e);
|
|
1379
1385
|
}, [e, s]), /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsx("div", { ...a(), children: r }) });
|
|
1380
1386
|
};
|
|
1381
|
-
function
|
|
1387
|
+
function as(e) {
|
|
1382
1388
|
return H({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { d: "M256 8C119.033 8 8 119.033 8 256s111.033 248 248 248 248-111.033 248-248S392.967 8 256 8zm0 48c110.532 0 200 89.451 200 200 0 110.532-89.451 200-200 200-110.532 0-200-89.451-200-200 0-110.532 89.451-200 200-200m140.204 130.267l-22.536-22.718c-4.667-4.705-12.265-4.736-16.97-.068L215.346 303.697l-59.792-60.277c-4.667-4.705-12.265-4.736-16.97-.069l-22.719 22.536c-4.705 4.667-4.736 12.265-.068 16.971l90.781 91.516c4.667 4.705 12.265 4.736 16.97.068l172.589-171.204c4.704-4.668 4.734-12.266.067-16.971z" }, child: [] }] })(e);
|
|
1383
1389
|
}
|
|
1384
|
-
function
|
|
1390
|
+
function is(e) {
|
|
1385
1391
|
return H({ tag: "svg", attr: { viewBox: "0 0 384 512" }, child: [{ tag: "path", attr: { d: "M288 248v28c0 6.6-5.4 12-12 12H108c-6.6 0-12-5.4-12-12v-28c0-6.6 5.4-12 12-12h168c6.6 0 12 5.4 12 12zm-12 72H108c-6.6 0-12 5.4-12 12v28c0 6.6 5.4 12 12 12h168c6.6 0 12-5.4 12-12v-28c0-6.6-5.4-12-12-12zm108-188.1V464c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V48C0 21.5 21.5 0 48 0h204.1C264.8 0 277 5.1 286 14.1L369.9 98c9 8.9 14.1 21.2 14.1 33.9zm-128-80V128h76.1L256 51.9zM336 464V176H232c-13.3 0-24-10.7-24-24V48H48v416h288z" }, child: [] }] })(e);
|
|
1386
1392
|
}
|
|
1387
|
-
function
|
|
1393
|
+
function Gt(e) {
|
|
1388
1394
|
return H({ tag: "svg", attr: { viewBox: "0 0 576 512" }, child: [{ tag: "path", attr: { d: "M527.9 224H480v-48c0-26.5-21.5-48-48-48H272l-64-64H48C21.5 64 0 85.5 0 112v288c0 26.5 21.5 48 48 48h400c16.5 0 31.9-8.5 40.7-22.6l79.9-128c20-31.9-3-73.4-40.7-73.4zM48 118c0-3.3 2.7-6 6-6h134.1l64 64H426c3.3 0 6 2.7 6 6v42H152c-16.8 0-32.4 8.8-41.1 23.2L48 351.4zm400 282H72l77.2-128H528z" }, child: [] }] })(e);
|
|
1389
1395
|
}
|
|
1390
|
-
function
|
|
1396
|
+
function Jt(e) {
|
|
1391
1397
|
return H({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { d: "M464 128H272l-54.63-54.63c-6-6-14.14-9.37-22.63-9.37H48C21.49 64 0 85.49 0 112v288c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V176c0-26.51-21.49-48-48-48zm0 272H48V112h140.12l54.63 54.63c6 6 14.14 9.37 22.63 9.37H464v224z" }, child: [] }] })(e);
|
|
1392
1398
|
}
|
|
1393
|
-
const
|
|
1394
|
-
const [r, n] = L(!1), [s, a] = L(!1), { currentPath:
|
|
1395
|
-
a(!0),
|
|
1396
|
-
}, d = (
|
|
1397
|
-
|
|
1399
|
+
const Lr = ({ folder: e }) => {
|
|
1400
|
+
const [r, n] = L(!1), [s, a] = L(!1), { currentPath: i, setCurrentPath: c } = Ee(), l = () => {
|
|
1401
|
+
a(!0), c(e.path);
|
|
1402
|
+
}, d = (p) => {
|
|
1403
|
+
p.stopPropagation(), n((f) => !f);
|
|
1398
1404
|
};
|
|
1399
1405
|
return se(() => {
|
|
1400
|
-
a(
|
|
1401
|
-
const
|
|
1402
|
-
|
|
1403
|
-
}, [
|
|
1406
|
+
a(i === e.path);
|
|
1407
|
+
const p = i.split("/");
|
|
1408
|
+
p.pop(), p.join("/") === e.path && n(!0);
|
|
1409
|
+
}, [i]), e.subDirectories.length > 0 ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1404
1410
|
/* @__PURE__ */ t.jsxs(
|
|
1405
1411
|
"div",
|
|
1406
1412
|
{
|
|
@@ -1408,20 +1414,20 @@ const Mr = ({ folder: e }) => {
|
|
|
1408
1414
|
onClick: l,
|
|
1409
1415
|
children: [
|
|
1410
1416
|
/* @__PURE__ */ t.jsx("span", { onClick: d, children: /* @__PURE__ */ t.jsx(
|
|
1411
|
-
|
|
1417
|
+
En,
|
|
1412
1418
|
{
|
|
1413
1419
|
size: 20,
|
|
1414
1420
|
className: `folder-icon-default ${r ? "folder-rotate-down" : ""}`
|
|
1415
1421
|
}
|
|
1416
1422
|
) }),
|
|
1417
1423
|
/* @__PURE__ */ t.jsxs("div", { className: "sb-folder-details", children: [
|
|
1418
|
-
r || s ? /* @__PURE__ */ t.jsx(
|
|
1424
|
+
r || s ? /* @__PURE__ */ t.jsx(Gt, { size: 20, className: "folder-open-icon" }) : /* @__PURE__ */ t.jsx(Jt, { size: 17, className: "folder-close-icon" }),
|
|
1419
1425
|
/* @__PURE__ */ t.jsx("span", { className: "sb-folder-name", title: e.name, children: e.name })
|
|
1420
1426
|
] })
|
|
1421
1427
|
]
|
|
1422
1428
|
}
|
|
1423
1429
|
),
|
|
1424
|
-
/* @__PURE__ */ t.jsx(
|
|
1430
|
+
/* @__PURE__ */ t.jsx(os, { open: r, children: /* @__PURE__ */ t.jsx("div", { className: "folder-collapsible", children: e.subDirectories.map((p, f) => /* @__PURE__ */ t.jsx(Lr, { folder: p }, f)) }) })
|
|
1425
1431
|
] }) : /* @__PURE__ */ t.jsxs(
|
|
1426
1432
|
"div",
|
|
1427
1433
|
{
|
|
@@ -1430,30 +1436,30 @@ const Mr = ({ folder: e }) => {
|
|
|
1430
1436
|
children: [
|
|
1431
1437
|
/* @__PURE__ */ t.jsx("span", { className: "non-expanable" }),
|
|
1432
1438
|
/* @__PURE__ */ t.jsxs("div", { className: "sb-folder-details", children: [
|
|
1433
|
-
s ? /* @__PURE__ */ t.jsx(
|
|
1439
|
+
s ? /* @__PURE__ */ t.jsx(Gt, { size: 20, className: "folder-open-icon" }) : /* @__PURE__ */ t.jsx(Jt, { size: 17, className: "folder-close-icon" }),
|
|
1434
1440
|
/* @__PURE__ */ t.jsx("span", { className: "sb-folder-name", title: e.name, children: e.name })
|
|
1435
1441
|
] })
|
|
1436
1442
|
]
|
|
1437
1443
|
}
|
|
1438
1444
|
);
|
|
1439
|
-
},
|
|
1440
|
-
const [e, r] = L([]), { files: n } = Ge(), s = (a,
|
|
1441
|
-
var
|
|
1442
|
-
return
|
|
1445
|
+
}, cs = (e) => e == null ? void 0 : e.split("/").slice(0, -1).join("/"), Or = () => {
|
|
1446
|
+
const [e, r] = L([]), { files: n } = Ge(), s = (a, i) => {
|
|
1447
|
+
var c;
|
|
1448
|
+
return i[a] ? (c = i[a]) == null ? void 0 : c.map((l) => ({
|
|
1443
1449
|
...l,
|
|
1444
|
-
subDirectories: s(l.path,
|
|
1450
|
+
subDirectories: s(l.path, i)
|
|
1445
1451
|
})) : [];
|
|
1446
1452
|
};
|
|
1447
1453
|
return se(() => {
|
|
1448
1454
|
if (Array.isArray(n)) {
|
|
1449
|
-
const a = n.filter((
|
|
1450
|
-
r(() => s("",
|
|
1455
|
+
const a = n.filter((c) => c.isDirectory), i = Object.groupBy(a, ({ path: c }) => cs(c));
|
|
1456
|
+
r(() => s("", i));
|
|
1451
1457
|
}
|
|
1452
|
-
}, [n]), /* @__PURE__ */ t.jsx("div", { className: "sb-folders-list", children: (e == null ? void 0 : e.length) > 0 ? /* @__PURE__ */ t.jsx(t.Fragment, { children: e == null ? void 0 : e.map((a,
|
|
1458
|
+
}, [n]), /* @__PURE__ */ t.jsx("div", { className: "sb-folders-list", children: (e == null ? void 0 : e.length) > 0 ? /* @__PURE__ */ t.jsx(t.Fragment, { children: e == null ? void 0 : e.map((a, i) => /* @__PURE__ */ t.jsx(Lr, { folder: a }, i)) }) : /* @__PURE__ */ t.jsx("div", { className: "empty-nav-pane", children: "Nothing here yet" }) });
|
|
1453
1459
|
};
|
|
1454
|
-
|
|
1455
|
-
const
|
|
1456
|
-
const [e, r] = L([]), [n, s] = L([]), [a,
|
|
1460
|
+
Or.displayName = "NavigationPane";
|
|
1461
|
+
const kr = () => {
|
|
1462
|
+
const [e, r] = L([]), [n, s] = L([]), [a, i] = L([]), [c, l] = L(!1), { currentPath: d, setCurrentPath: p } = Ee(), f = de(null), h = de([]), w = de(null), S = Be(() => {
|
|
1457
1463
|
l(!1);
|
|
1458
1464
|
});
|
|
1459
1465
|
se(() => {
|
|
@@ -1463,26 +1469,26 @@ const Or = () => {
|
|
|
1463
1469
|
name: y || "Home",
|
|
1464
1470
|
path: y === "" ? y : j += `/${y}`
|
|
1465
1471
|
}));
|
|
1466
|
-
}), s([]),
|
|
1472
|
+
}), s([]), i([]);
|
|
1467
1473
|
}, [d]);
|
|
1468
|
-
const
|
|
1469
|
-
|
|
1474
|
+
const M = (j) => {
|
|
1475
|
+
p(j);
|
|
1470
1476
|
}, z = () => {
|
|
1471
1477
|
const j = f.current.clientWidth, y = getComputedStyle(f.current), b = parseFloat(y.paddingLeft), u = n.length > 0 ? 1 : 0, g = parseFloat(y.gap) * (e.length + u);
|
|
1472
1478
|
return j - (b + g);
|
|
1473
|
-
},
|
|
1479
|
+
}, D = () => {
|
|
1474
1480
|
var u;
|
|
1475
|
-
const j = z(), y =
|
|
1481
|
+
const j = z(), y = h.current.reduce((g, _) => _ ? g + _.clientWidth : g, 0), b = ((u = w.current) == null ? void 0 : u.clientWidth) || 0;
|
|
1476
1482
|
return j - (y + b);
|
|
1477
1483
|
}, C = () => f.current.scrollWidth > f.current.clientWidth;
|
|
1478
1484
|
return se(() => {
|
|
1479
1485
|
var j;
|
|
1480
1486
|
if (C()) {
|
|
1481
|
-
const y = e[1], b = (j =
|
|
1482
|
-
|
|
1483
|
-
} else if (n.length > 0 &&
|
|
1487
|
+
const y = e[1], b = (j = h.current[1]) == null ? void 0 : j.clientWidth;
|
|
1488
|
+
i((u) => [...u, b]), s((u) => [...u, y]), r((u) => u.filter((g, _) => _ !== 1));
|
|
1489
|
+
} else if (n.length > 0 && D() > a.at(-1)) {
|
|
1484
1490
|
const y = [e[0], n.at(-1), ...e.slice(1)];
|
|
1485
|
-
r(y), s((b) => b.slice(0, -1)),
|
|
1491
|
+
r(y), s((b) => b.slice(0, -1)), i((b) => b.slice(0, -1));
|
|
1486
1492
|
}
|
|
1487
1493
|
}, [C]), /* @__PURE__ */ t.jsxs("div", { className: "bread-crumb-container", children: [
|
|
1488
1494
|
/* @__PURE__ */ t.jsx("div", { className: "breadcrumb", ref: f, children: e.map((j, y) => /* @__PURE__ */ t.jsxs("div", { style: { display: "contents" }, children: [
|
|
@@ -1490,10 +1496,10 @@ const Or = () => {
|
|
|
1490
1496
|
"span",
|
|
1491
1497
|
{
|
|
1492
1498
|
className: "folder-name",
|
|
1493
|
-
onClick: () =>
|
|
1494
|
-
ref: (b) =>
|
|
1499
|
+
onClick: () => M(j.path),
|
|
1500
|
+
ref: (b) => h.current[y] = b,
|
|
1495
1501
|
children: [
|
|
1496
|
-
y === 0 ? /* @__PURE__ */ t.jsx(
|
|
1502
|
+
y === 0 ? /* @__PURE__ */ t.jsx(bn, {}) : /* @__PURE__ */ t.jsx(Tn, {}),
|
|
1497
1503
|
j.name
|
|
1498
1504
|
]
|
|
1499
1505
|
}
|
|
@@ -1503,17 +1509,17 @@ const Or = () => {
|
|
|
1503
1509
|
{
|
|
1504
1510
|
className: "folder-name folder-name-btn",
|
|
1505
1511
|
onClick: () => l(!0),
|
|
1506
|
-
ref:
|
|
1512
|
+
ref: w,
|
|
1507
1513
|
title: "Show more folders",
|
|
1508
|
-
children: /* @__PURE__ */ t.jsx(
|
|
1514
|
+
children: /* @__PURE__ */ t.jsx(Pn, { size: 22, className: "hidden-folders" })
|
|
1509
1515
|
}
|
|
1510
1516
|
)
|
|
1511
1517
|
] }, y)) }),
|
|
1512
|
-
|
|
1518
|
+
c && /* @__PURE__ */ t.jsx("ul", { ref: S.ref, className: "hidden-folders-container", children: n.map((j, y) => /* @__PURE__ */ t.jsx(
|
|
1513
1519
|
"li",
|
|
1514
1520
|
{
|
|
1515
1521
|
onClick: () => {
|
|
1516
|
-
|
|
1522
|
+
M(j.path), l(!1);
|
|
1517
1523
|
},
|
|
1518
1524
|
children: j.name
|
|
1519
1525
|
},
|
|
@@ -1521,59 +1527,59 @@ const Or = () => {
|
|
|
1521
1527
|
)) })
|
|
1522
1528
|
] });
|
|
1523
1529
|
};
|
|
1524
|
-
|
|
1530
|
+
kr.displayName = "BreadCrumb";
|
|
1525
1531
|
const Xe = (e) => ({
|
|
1526
|
-
pdf: /* @__PURE__ */ t.jsx(
|
|
1532
|
+
pdf: /* @__PURE__ */ t.jsx(On, { size: e }),
|
|
1527
1533
|
jpg: /* @__PURE__ */ t.jsx(ot, { size: e }),
|
|
1528
1534
|
jpeg: /* @__PURE__ */ t.jsx(ot, { size: e }),
|
|
1529
1535
|
png: /* @__PURE__ */ t.jsx(ot, { size: e }),
|
|
1530
|
-
txt: /* @__PURE__ */ t.jsx(
|
|
1536
|
+
txt: /* @__PURE__ */ t.jsx(Ln, { size: e }),
|
|
1531
1537
|
doc: /* @__PURE__ */ t.jsx(Wt, { size: e }),
|
|
1532
1538
|
docx: /* @__PURE__ */ t.jsx(Wt, { size: e }),
|
|
1533
1539
|
mp4: /* @__PURE__ */ t.jsx(Ht, { size: e }),
|
|
1534
1540
|
webm: /* @__PURE__ */ t.jsx(Ht, { size: e }),
|
|
1535
1541
|
mp3: /* @__PURE__ */ t.jsx(It, { size: e }),
|
|
1536
1542
|
m4a: /* @__PURE__ */ t.jsx(It, { size: e }),
|
|
1537
|
-
zip: /* @__PURE__ */ t.jsx(
|
|
1543
|
+
zip: /* @__PURE__ */ t.jsx(kn, { size: e }),
|
|
1538
1544
|
ppt: /* @__PURE__ */ t.jsx(Bt, { size: e }),
|
|
1539
1545
|
pptx: /* @__PURE__ */ t.jsx(Bt, { size: e }),
|
|
1540
1546
|
xls: /* @__PURE__ */ t.jsx($t, { size: e }),
|
|
1541
1547
|
xlsx: /* @__PURE__ */ t.jsx($t, { size: e }),
|
|
1542
|
-
exe: /* @__PURE__ */ t.jsx(
|
|
1543
|
-
html: /* @__PURE__ */ t.jsx(
|
|
1544
|
-
css: /* @__PURE__ */ t.jsx(
|
|
1545
|
-
js: /* @__PURE__ */ t.jsx(
|
|
1546
|
-
php: /* @__PURE__ */ t.jsx(
|
|
1547
|
-
py: /* @__PURE__ */ t.jsx(
|
|
1548
|
-
java: /* @__PURE__ */ t.jsx(
|
|
1549
|
-
cpp: /* @__PURE__ */ t.jsx(
|
|
1550
|
-
c: /* @__PURE__ */ t.jsx(
|
|
1551
|
-
ts: /* @__PURE__ */ t.jsx(
|
|
1552
|
-
jsx: /* @__PURE__ */ t.jsx(
|
|
1553
|
-
tsx: /* @__PURE__ */ t.jsx(
|
|
1554
|
-
json: /* @__PURE__ */ t.jsx(
|
|
1555
|
-
xml: /* @__PURE__ */ t.jsx(
|
|
1556
|
-
sql: /* @__PURE__ */ t.jsx(
|
|
1557
|
-
csv: /* @__PURE__ */ t.jsx(
|
|
1558
|
-
md: /* @__PURE__ */ t.jsx(
|
|
1559
|
-
svg: /* @__PURE__ */ t.jsx(
|
|
1560
|
-
}),
|
|
1548
|
+
exe: /* @__PURE__ */ t.jsx(Mn, { size: e }),
|
|
1549
|
+
html: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1550
|
+
css: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1551
|
+
js: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1552
|
+
php: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1553
|
+
py: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1554
|
+
java: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1555
|
+
cpp: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1556
|
+
c: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1557
|
+
ts: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1558
|
+
jsx: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1559
|
+
tsx: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1560
|
+
json: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1561
|
+
xml: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1562
|
+
sql: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1563
|
+
csv: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1564
|
+
md: /* @__PURE__ */ t.jsx(pe, { size: e }),
|
|
1565
|
+
svg: /* @__PURE__ */ t.jsx(pe, { size: e })
|
|
1566
|
+
}), _r = (e, r, n) => {
|
|
1561
1567
|
if (n.find((s) => s.name === e)) {
|
|
1562
1568
|
const s = "", a = e;
|
|
1563
|
-
let
|
|
1564
|
-
const
|
|
1565
|
-
n.forEach((
|
|
1566
|
-
const f =
|
|
1567
|
-
if (
|
|
1568
|
-
const
|
|
1569
|
-
!isNaN(
|
|
1569
|
+
let i = 0;
|
|
1570
|
+
const c = new RegExp(`${a} \\(\\d+\\)`);
|
|
1571
|
+
n.forEach((p) => {
|
|
1572
|
+
const f = p.isDirectory ? p.name : p.name.split(".").slice(0, -1).join(".");
|
|
1573
|
+
if (c.test(f)) {
|
|
1574
|
+
const h = f.split(`${a} (`).pop().slice(0, -1), w = parseInt(h);
|
|
1575
|
+
!isNaN(w) && w > i && (i = w);
|
|
1570
1576
|
}
|
|
1571
1577
|
});
|
|
1572
|
-
const l = ` (${++
|
|
1578
|
+
const l = ` (${++i})`;
|
|
1573
1579
|
return a + l + s;
|
|
1574
1580
|
} else
|
|
1575
1581
|
return e;
|
|
1576
|
-
},
|
|
1582
|
+
}, Nr = ({ nameInputRef: e, maxLength: r, value: n, onChange: s, onKeyDown: a, onClick: i, rows: c }) => /* @__PURE__ */ t.jsx(
|
|
1577
1583
|
"textarea",
|
|
1578
1584
|
{
|
|
1579
1585
|
ref: e,
|
|
@@ -1582,55 +1588,55 @@ const Xe = (e) => ({
|
|
|
1582
1588
|
value: n,
|
|
1583
1589
|
onChange: s,
|
|
1584
1590
|
onKeyDown: a,
|
|
1585
|
-
onClick:
|
|
1586
|
-
rows:
|
|
1591
|
+
onClick: i,
|
|
1592
|
+
rows: c
|
|
1587
1593
|
}
|
|
1588
|
-
),
|
|
1589
|
-
const [a,
|
|
1594
|
+
), zr = ({ message: e, xPlacement: r, yPlacement: n }) => /* @__PURE__ */ t.jsx("p", { className: `error-tooltip ${r} ${n}`, children: e }), ls = 220, us = ({ filesViewRef: e, file: r, onCreateFolder: n, triggerAction: s }) => {
|
|
1595
|
+
const [a, i] = L(r.name), [c, l] = L(!1), [d, p] = L(""), [f, h] = L("right"), [w, S] = L("bottom"), M = Be((g) => {
|
|
1590
1596
|
g.preventDefault(), g.stopPropagation();
|
|
1591
|
-
}), { currentFolder: z, currentPathFiles:
|
|
1592
|
-
|
|
1597
|
+
}), { currentFolder: z, currentPathFiles: D, setCurrentPathFiles: C } = Ee(), { activeLayout: j } = Se(), y = (g) => {
|
|
1598
|
+
i(g.target.value), l(!1);
|
|
1593
1599
|
}, b = (g) => {
|
|
1594
1600
|
if (g.stopPropagation(), g.key === "Enter") {
|
|
1595
1601
|
g.preventDefault(), u();
|
|
1596
1602
|
return;
|
|
1597
1603
|
}
|
|
1598
|
-
g.key === "Escape" && (g.preventDefault(), s.close(), C((x) => x.filter((R) => R.key !== r.key))), /[\\/:*?"<>|]/.test(g.key) ? (g.preventDefault(),
|
|
1604
|
+
g.key === "Escape" && (g.preventDefault(), s.close(), C((x) => x.filter((R) => R.key !== r.key))), /[\\/:*?"<>|]/.test(g.key) ? (g.preventDefault(), p(
|
|
1599
1605
|
`A file name can't contain any of the following characters: \\ / : * ? " < > |`
|
|
1600
|
-
), l(!0)) : (l(!1),
|
|
1606
|
+
), l(!0)) : (l(!1), p(""));
|
|
1601
1607
|
};
|
|
1602
1608
|
se(() => {
|
|
1603
|
-
if (
|
|
1609
|
+
if (c) {
|
|
1604
1610
|
const g = setTimeout(() => {
|
|
1605
|
-
l(!1),
|
|
1611
|
+
l(!1), p("");
|
|
1606
1612
|
}, 7e3);
|
|
1607
1613
|
return () => clearTimeout(g);
|
|
1608
1614
|
}
|
|
1609
|
-
}, [
|
|
1615
|
+
}, [c]);
|
|
1610
1616
|
function u() {
|
|
1611
1617
|
var R, F;
|
|
1612
1618
|
let g = a.trim();
|
|
1613
|
-
const
|
|
1614
|
-
if (
|
|
1615
|
-
|
|
1619
|
+
const _ = D.filter((A) => !(A.key && A.key === r.key));
|
|
1620
|
+
if (_.find((A) => A.name.toLowerCase() === g.toLowerCase())) {
|
|
1621
|
+
p(`This destination already contains a folder named '${g}'.`), l(!0), (R = M.ref.current) == null || R.focus(), (F = M.ref.current) == null || F.select(), M.setIsClicked(!1);
|
|
1616
1622
|
return;
|
|
1617
1623
|
}
|
|
1618
|
-
g === "" && (g =
|
|
1624
|
+
g === "" && (g = _r("New Folder", !0, _)), Le(n, "onCreateFolder", g, z), C((A) => A.filter((N) => N.key !== r.key)), s.close();
|
|
1619
1625
|
}
|
|
1620
1626
|
return se(() => {
|
|
1621
|
-
var g,
|
|
1622
|
-
if ((g =
|
|
1623
|
-
const
|
|
1624
|
-
|
|
1627
|
+
var g, _, x;
|
|
1628
|
+
if ((g = M.ref.current) == null || g.focus(), (_ = M.ref.current) == null || _.select(), (x = M.ref) != null && x.current) {
|
|
1629
|
+
const N = e.current.getBoundingClientRect(), k = M.ref.current, X = k.getBoundingClientRect();
|
|
1630
|
+
N.right - X.left > 313 ? h("right") : h("left"), N.bottom - (X.top + k.clientHeight) > 88 ? S("bottom") : S("top");
|
|
1625
1631
|
}
|
|
1626
1632
|
}, []), se(() => {
|
|
1627
|
-
|
|
1628
|
-
}, [
|
|
1633
|
+
M.isClicked && u();
|
|
1634
|
+
}, [M.isClicked]), /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1629
1635
|
/* @__PURE__ */ t.jsx(
|
|
1630
|
-
|
|
1636
|
+
Nr,
|
|
1631
1637
|
{
|
|
1632
|
-
nameInputRef:
|
|
1633
|
-
maxLength:
|
|
1638
|
+
nameInputRef: M.ref,
|
|
1639
|
+
maxLength: ls,
|
|
1634
1640
|
value: a,
|
|
1635
1641
|
onChange: y,
|
|
1636
1642
|
onKeyDown: b,
|
|
@@ -1638,12 +1644,12 @@ const Xe = (e) => ({
|
|
|
1638
1644
|
...j === "list" && { rows: 1 }
|
|
1639
1645
|
}
|
|
1640
1646
|
),
|
|
1641
|
-
|
|
1642
|
-
|
|
1647
|
+
c && /* @__PURE__ */ t.jsx(
|
|
1648
|
+
zr,
|
|
1643
1649
|
{
|
|
1644
1650
|
message: d,
|
|
1645
1651
|
xPlacement: f,
|
|
1646
|
-
yPlacement:
|
|
1652
|
+
yPlacement: w
|
|
1647
1653
|
}
|
|
1648
1654
|
)
|
|
1649
1655
|
] });
|
|
@@ -1657,20 +1663,20 @@ const Xe = (e) => ({
|
|
|
1657
1663
|
children: a
|
|
1658
1664
|
}
|
|
1659
1665
|
);
|
|
1660
|
-
function
|
|
1666
|
+
function ds(e) {
|
|
1661
1667
|
return H({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { fill: "none", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "32", d: "M85.57 446.25h340.86a32 32 0 0 0 28.17-47.17L284.18 82.58c-12.09-22.44-44.27-22.44-56.36 0L57.4 399.08a32 32 0 0 0 28.17 47.17z" }, child: [] }, { tag: "path", attr: { fill: "none", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: "32", d: "m250.26 195.39 5.74 122 5.73-121.95a5.74 5.74 0 0 0-5.79-6h0a5.74 5.74 0 0 0-5.68 5.95z" }, child: [] }, { tag: "path", attr: { d: "M256 397.25a20 20 0 1 1 20-20 20 20 0 0 1-20 20z" }, child: [] }] })(e);
|
|
1662
1668
|
}
|
|
1663
|
-
const
|
|
1669
|
+
const Ar = ({
|
|
1664
1670
|
children: e,
|
|
1665
1671
|
show: r,
|
|
1666
1672
|
setShow: n,
|
|
1667
1673
|
heading: s,
|
|
1668
1674
|
dialogWidth: a = "25%",
|
|
1669
|
-
contentClassName:
|
|
1670
|
-
closeButton:
|
|
1675
|
+
contentClassName: i = "",
|
|
1676
|
+
closeButton: c = !0
|
|
1671
1677
|
}) => {
|
|
1672
|
-
const l = de(null), d = (
|
|
1673
|
-
|
|
1678
|
+
const l = de(null), d = (p) => {
|
|
1679
|
+
p.key === "Escape" && n(!1);
|
|
1674
1680
|
};
|
|
1675
1681
|
return se(() => {
|
|
1676
1682
|
r ? l.current.showModal() : l.current.close();
|
|
@@ -1684,14 +1690,14 @@ const zr = ({
|
|
|
1684
1690
|
children: [
|
|
1685
1691
|
/* @__PURE__ */ t.jsxs("div", { className: "fm-modal-header", children: [
|
|
1686
1692
|
/* @__PURE__ */ t.jsx("span", { className: "fm-modal-heading", children: s }),
|
|
1687
|
-
|
|
1693
|
+
c && /* @__PURE__ */ t.jsx(Rn, { size: 18, onClick: () => n(!1), className: "close-icon", title: "Close" })
|
|
1688
1694
|
] }),
|
|
1689
1695
|
e
|
|
1690
1696
|
]
|
|
1691
1697
|
}
|
|
1692
1698
|
);
|
|
1693
|
-
}, _e = (e) => e.split(".").pop(),
|
|
1694
|
-
const [a,
|
|
1699
|
+
}, _e = (e) => e.split(".").pop(), fs = 220, hs = ({ filesViewRef: e, file: r, onRename: n, triggerAction: s }) => {
|
|
1700
|
+
const [a, i] = L(r == null ? void 0 : r.name), [c, l] = L(!1), [d, p] = L(!1), [f, h] = L(""), [w, S] = L("right"), [M, z] = L("bottom"), { currentPathFiles: D, setCurrentPathFiles: C } = Ee(), { activeLayout: j } = Se(), y = de(null), b = Be((x) => {
|
|
1695
1701
|
var R;
|
|
1696
1702
|
(R = y.current) != null && R.contains(x.target) || (x.preventDefault(), x.stopPropagation());
|
|
1697
1703
|
}), u = (x) => {
|
|
@@ -1699,14 +1705,14 @@ const zr = ({
|
|
|
1699
1705
|
x.preventDefault(), b.setIsClicked(!0);
|
|
1700
1706
|
return;
|
|
1701
1707
|
}
|
|
1702
|
-
/[\\/:*?"<>|]/.test(x.key) ? (x.preventDefault(),
|
|
1708
|
+
/[\\/:*?"<>|]/.test(x.key) ? (x.preventDefault(), h(
|
|
1703
1709
|
`A file name can't contain any of the following characters: \\ / : * ? " < > |`
|
|
1704
|
-
),
|
|
1710
|
+
), p(!0)) : p(!1);
|
|
1705
1711
|
};
|
|
1706
1712
|
se(() => {
|
|
1707
1713
|
if (d) {
|
|
1708
1714
|
const x = setTimeout(() => {
|
|
1709
|
-
|
|
1715
|
+
p(!1), h("");
|
|
1710
1716
|
}, 7e3);
|
|
1711
1717
|
return () => clearTimeout(x);
|
|
1712
1718
|
}
|
|
@@ -1717,8 +1723,8 @@ const zr = ({
|
|
|
1717
1723
|
(R) => R.map((F) => (F.key === r.key && (F.isEditing = !1), F))
|
|
1718
1724
|
), s.close();
|
|
1719
1725
|
return;
|
|
1720
|
-
} else if (
|
|
1721
|
-
|
|
1726
|
+
} else if (D.some((R) => R.name === a)) {
|
|
1727
|
+
p(!0), h(`This destination already contains a folder named '${a}'.`), b.setIsClicked(!1);
|
|
1722
1728
|
return;
|
|
1723
1729
|
} else if (!r.isDirectory && !x) {
|
|
1724
1730
|
const R = _e(r.name), F = _e(a);
|
|
@@ -1727,34 +1733,34 @@ const zr = ({
|
|
|
1727
1733
|
return;
|
|
1728
1734
|
}
|
|
1729
1735
|
}
|
|
1730
|
-
|
|
1736
|
+
p(!1), Le(n, "onRename", r, a), C((R) => R.filter((F) => F.key !== r.key)), s.close();
|
|
1731
1737
|
}
|
|
1732
|
-
const
|
|
1733
|
-
var x, R, F,
|
|
1738
|
+
const _ = () => {
|
|
1739
|
+
var x, R, F, A, N, k;
|
|
1734
1740
|
if ((R = (x = b.ref) == null ? void 0 : x.current) == null || R.focus(), r.isDirectory)
|
|
1735
|
-
(
|
|
1741
|
+
(A = (F = b.ref) == null ? void 0 : F.current) == null || A.select();
|
|
1736
1742
|
else {
|
|
1737
1743
|
const X = _e(r.name), oe = r.name.length - X.length - 1;
|
|
1738
|
-
(
|
|
1744
|
+
(k = (N = b.ref) == null ? void 0 : N.current) == null || k.setSelectionRange(0, oe);
|
|
1739
1745
|
}
|
|
1740
1746
|
};
|
|
1741
1747
|
return se(() => {
|
|
1742
1748
|
var x;
|
|
1743
|
-
if (
|
|
1744
|
-
const
|
|
1745
|
-
|
|
1749
|
+
if (_(), (x = b.ref) != null && x.current) {
|
|
1750
|
+
const N = e.current.getBoundingClientRect(), k = b.ref.current, X = k.getBoundingClientRect();
|
|
1751
|
+
N.right - X.left > 313 ? S("right") : S("left"), N.bottom - (X.top + k.clientHeight) > 88 ? z("bottom") : z("top");
|
|
1746
1752
|
}
|
|
1747
1753
|
}, []), se(() => {
|
|
1748
|
-
b.isClicked && g(!1),
|
|
1754
|
+
b.isClicked && g(!1), _();
|
|
1749
1755
|
}, [b.isClicked]), /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1750
1756
|
/* @__PURE__ */ t.jsx(
|
|
1751
|
-
|
|
1757
|
+
Nr,
|
|
1752
1758
|
{
|
|
1753
1759
|
nameInputRef: b.ref,
|
|
1754
|
-
maxLength:
|
|
1760
|
+
maxLength: fs,
|
|
1755
1761
|
value: a,
|
|
1756
1762
|
onChange: (x) => {
|
|
1757
|
-
|
|
1763
|
+
i(x.target.value), p(!1);
|
|
1758
1764
|
},
|
|
1759
1765
|
onKeyDown: u,
|
|
1760
1766
|
onClick: (x) => x.stopPropagation(),
|
|
@@ -1762,24 +1768,24 @@ const zr = ({
|
|
|
1762
1768
|
}
|
|
1763
1769
|
),
|
|
1764
1770
|
d && /* @__PURE__ */ t.jsx(
|
|
1765
|
-
|
|
1771
|
+
zr,
|
|
1766
1772
|
{
|
|
1767
1773
|
message: f,
|
|
1768
|
-
xPlacement:
|
|
1769
|
-
yPlacement:
|
|
1774
|
+
xPlacement: w,
|
|
1775
|
+
yPlacement: M
|
|
1770
1776
|
}
|
|
1771
1777
|
),
|
|
1772
1778
|
/* @__PURE__ */ t.jsx(
|
|
1773
|
-
|
|
1779
|
+
Ar,
|
|
1774
1780
|
{
|
|
1775
1781
|
heading: "Rename",
|
|
1776
|
-
show:
|
|
1782
|
+
show: c,
|
|
1777
1783
|
setShow: l,
|
|
1778
1784
|
dialogWidth: "25vw",
|
|
1779
1785
|
closeButton: !1,
|
|
1780
1786
|
children: /* @__PURE__ */ t.jsxs("div", { className: "fm-rename-folder-container", ref: y, children: [
|
|
1781
1787
|
/* @__PURE__ */ t.jsx("div", { className: "fm-rename-folder-input", children: /* @__PURE__ */ t.jsxs("div", { className: "fm-rename-warning", children: [
|
|
1782
|
-
/* @__PURE__ */ t.jsx(
|
|
1788
|
+
/* @__PURE__ */ t.jsx(ds, { size: 70, color: "orange" }),
|
|
1783
1789
|
/* @__PURE__ */ t.jsx("div", { children: "If you change a file name extension, the file might become unusable. Are you sure you want to change it?" })
|
|
1784
1790
|
] }) }),
|
|
1785
1791
|
/* @__PURE__ */ t.jsxs("div", { className: "fm-rename-folder-action", children: [
|
|
@@ -1819,44 +1825,44 @@ const zr = ({
|
|
|
1819
1825
|
return `${s.toFixed(r)} MB`;
|
|
1820
1826
|
if (s >= 1024)
|
|
1821
1827
|
return `${a.toFixed(r)} GB`;
|
|
1822
|
-
},
|
|
1828
|
+
}, ps = (e) => {
|
|
1823
1829
|
if (!e || isNaN(Date.parse(e))) return "";
|
|
1824
1830
|
e = new Date(e);
|
|
1825
1831
|
let r = e.getHours();
|
|
1826
1832
|
const n = e.getMinutes(), s = r >= 12 ? "PM" : "AM";
|
|
1827
1833
|
r = r % 12, r = r || 12;
|
|
1828
|
-
const a = e.getMonth() + 1,
|
|
1829
|
-
return `${a}/${
|
|
1830
|
-
},
|
|
1834
|
+
const a = e.getMonth() + 1, i = e.getDate(), c = e.getFullYear();
|
|
1835
|
+
return `${a}/${i}/${c} ${r}:${n < 10 ? "0" + n : n} ${s}`;
|
|
1836
|
+
}, Dr = ({ name: e, id: r, checked: n, onClick: s, onChange: a, className: i = "", title: c, disabled: l = !1 }) => /* @__PURE__ */ t.jsx(
|
|
1831
1837
|
"input",
|
|
1832
1838
|
{
|
|
1833
|
-
className: `fm-checkbox ${
|
|
1839
|
+
className: `fm-checkbox ${i}`,
|
|
1834
1840
|
type: "checkbox",
|
|
1835
1841
|
name: e,
|
|
1836
1842
|
id: r,
|
|
1837
1843
|
checked: n,
|
|
1838
1844
|
onClick: s,
|
|
1839
1845
|
onChange: a,
|
|
1840
|
-
title:
|
|
1846
|
+
title: c,
|
|
1841
1847
|
disabled: l
|
|
1842
1848
|
}
|
|
1843
|
-
), it = 50,
|
|
1849
|
+
), it = 50, vs = ({
|
|
1844
1850
|
index: e,
|
|
1845
1851
|
file: r,
|
|
1846
1852
|
onCreateFolder: n,
|
|
1847
1853
|
onRename: s,
|
|
1848
1854
|
enableFilePreview: a,
|
|
1849
|
-
onFileOpen:
|
|
1850
|
-
filesViewRef:
|
|
1855
|
+
onFileOpen: i,
|
|
1856
|
+
filesViewRef: c,
|
|
1851
1857
|
selectedFileIndexes: l,
|
|
1852
1858
|
triggerAction: d,
|
|
1853
|
-
handleContextMenu:
|
|
1859
|
+
handleContextMenu: p,
|
|
1854
1860
|
setLastSelectedFile: f
|
|
1855
1861
|
}) => {
|
|
1856
|
-
var fe,
|
|
1857
|
-
const [
|
|
1858
|
-
|
|
1859
|
-
},
|
|
1862
|
+
var fe, E, ve, Te;
|
|
1863
|
+
const [h, w] = L(!1), [S, M] = L(0), [z, D] = L("hidden"), [C, j] = L(""), [y, b] = L(null), { activeLayout: u } = Se(), g = u === "grid" ? 48 : 20, _ = Xe(g), { setCurrentPath: x, currentPathFiles: R } = Ee(), { setSelectedFiles: F } = Fe(), { clipBoard: A, handleCutCopy: N, setClipBoard: k, handlePasting: X } = Je(), oe = de(null), ae = Xe(it), Q = (A == null ? void 0 : A.isMoving) && A.files.find((Y) => Y.name === r.name && Y.path === r.path), he = () => {
|
|
1864
|
+
i(r), r.isDirectory ? (x(r.path), F([])) : a && d.show("previewFile");
|
|
1865
|
+
}, xe = (Y, le) => {
|
|
1860
1866
|
if (l.length > 0 && Y) {
|
|
1861
1867
|
let je = !1, Re = l[0], we = e;
|
|
1862
1868
|
if (Re >= we) {
|
|
@@ -1871,38 +1877,38 @@ const zr = ({
|
|
|
1871
1877
|
}) : F([r]);
|
|
1872
1878
|
}, m = (Y) => {
|
|
1873
1879
|
if (Y.stopPropagation(), r.isEditing) return;
|
|
1874
|
-
|
|
1880
|
+
xe(Y.shiftKey, Y.ctrlKey);
|
|
1875
1881
|
const le = (/* @__PURE__ */ new Date()).getTime();
|
|
1876
|
-
if (le -
|
|
1877
|
-
|
|
1882
|
+
if (le - S < 300) {
|
|
1883
|
+
he();
|
|
1878
1884
|
return;
|
|
1879
1885
|
}
|
|
1880
|
-
|
|
1886
|
+
M(le);
|
|
1881
1887
|
}, P = (Y) => {
|
|
1882
|
-
Y.key === "Enter" && (Y.stopPropagation(), F([r]),
|
|
1888
|
+
Y.key === "Enter" && (Y.stopPropagation(), F([r]), he());
|
|
1883
1889
|
}, V = (Y) => {
|
|
1884
|
-
Y.stopPropagation(), Y.preventDefault(), !r.isEditing && (
|
|
1890
|
+
Y.stopPropagation(), Y.preventDefault(), !r.isEditing && (h || F([r]), f(r), p(Y, !0));
|
|
1885
1891
|
}, W = () => {
|
|
1886
|
-
|
|
1892
|
+
D("visible");
|
|
1887
1893
|
}, I = () => {
|
|
1888
|
-
!
|
|
1894
|
+
!h && D("hidden");
|
|
1889
1895
|
}, K = (Y) => {
|
|
1890
|
-
Y.target.checked ? F((le) => [...le, r]) : F((le) => le.filter((je) => je.name !== r.name && je.path !== r.path)),
|
|
1896
|
+
Y.target.checked ? F((le) => [...le, r]) : F((le) => le.filter((je) => je.name !== r.name && je.path !== r.path)), w(Y.target.checked);
|
|
1891
1897
|
}, O = (Y) => {
|
|
1892
|
-
Y.dataTransfer.setDragImage(oe.current, 30, 50), Y.dataTransfer.effectAllowed = "copy",
|
|
1893
|
-
}, $ = () =>
|
|
1894
|
-
Y.preventDefault(),
|
|
1895
|
-
},
|
|
1898
|
+
Y.dataTransfer.setDragImage(oe.current, 30, 50), Y.dataTransfer.effectAllowed = "copy", N(!0);
|
|
1899
|
+
}, $ = () => k(null), U = (Y) => {
|
|
1900
|
+
Y.preventDefault(), h || !r.isDirectory ? Y.dataTransfer.dropEffect = "none" : (b({ x: Y.clientX, y: Y.clientY + 12 }), Y.dataTransfer.dropEffect = "copy", j("file-drop-zone"));
|
|
1901
|
+
}, Z = (Y) => {
|
|
1896
1902
|
Y.currentTarget.contains(Y.relatedTarget) || (j((le) => le && ""), b(null));
|
|
1897
1903
|
}, q = (Y) => {
|
|
1898
|
-
Y.preventDefault(), !(
|
|
1904
|
+
Y.preventDefault(), !(h || !r.isDirectory) && (X(r), j((le) => le && ""), b(null));
|
|
1899
1905
|
};
|
|
1900
1906
|
return se(() => {
|
|
1901
|
-
|
|
1907
|
+
w(l.includes(e)), D(l.includes(e) ? "visible" : "hidden");
|
|
1902
1908
|
}, [l]), /* @__PURE__ */ t.jsxs(
|
|
1903
1909
|
"div",
|
|
1904
1910
|
{
|
|
1905
|
-
className: `file-item-container ${C} ${
|
|
1911
|
+
className: `file-item-container ${C} ${h || r.isEditing ? "file-selected" : ""} ${Q ? "file-moving" : ""}`,
|
|
1906
1912
|
tabIndex: 0,
|
|
1907
1913
|
title: r.name,
|
|
1908
1914
|
onClick: m,
|
|
@@ -1910,39 +1916,39 @@ const zr = ({
|
|
|
1910
1916
|
onContextMenu: V,
|
|
1911
1917
|
onMouseOver: W,
|
|
1912
1918
|
onMouseLeave: I,
|
|
1913
|
-
draggable:
|
|
1919
|
+
draggable: h,
|
|
1914
1920
|
onDragStart: O,
|
|
1915
1921
|
onDragEnd: $,
|
|
1916
1922
|
onDragEnter: U,
|
|
1917
1923
|
onDragOver: U,
|
|
1918
|
-
onDragLeave:
|
|
1924
|
+
onDragLeave: Z,
|
|
1919
1925
|
onDrop: q,
|
|
1920
1926
|
children: [
|
|
1921
1927
|
/* @__PURE__ */ t.jsxs("div", { className: "file-item", children: [
|
|
1922
1928
|
!r.isEditing && /* @__PURE__ */ t.jsx(
|
|
1923
|
-
|
|
1929
|
+
Dr,
|
|
1924
1930
|
{
|
|
1925
1931
|
name: r.name,
|
|
1926
1932
|
id: r.name,
|
|
1927
|
-
checked:
|
|
1933
|
+
checked: h,
|
|
1928
1934
|
className: `selection-checkbox ${z}`,
|
|
1929
1935
|
onChange: K,
|
|
1930
1936
|
onClick: (Y) => Y.stopPropagation()
|
|
1931
1937
|
}
|
|
1932
1938
|
),
|
|
1933
|
-
r.isDirectory ? /* @__PURE__ */ t.jsx(Vt, { size: g }) : /* @__PURE__ */ t.jsx(t.Fragment, { children:
|
|
1939
|
+
r.isDirectory ? /* @__PURE__ */ t.jsx(Vt, { size: g }) : /* @__PURE__ */ t.jsx(t.Fragment, { children: _[(E = (fe = r.name) == null ? void 0 : fe.split(".").pop()) == null ? void 0 : E.toLowerCase()] ?? /* @__PURE__ */ t.jsx(qe, { size: g }) }),
|
|
1934
1940
|
r.isEditing ? /* @__PURE__ */ t.jsx("div", { className: `rename-file-container ${u}`, children: d.actionType === "createFolder" ? /* @__PURE__ */ t.jsx(
|
|
1935
|
-
|
|
1941
|
+
us,
|
|
1936
1942
|
{
|
|
1937
|
-
filesViewRef:
|
|
1943
|
+
filesViewRef: c,
|
|
1938
1944
|
file: r,
|
|
1939
1945
|
onCreateFolder: n,
|
|
1940
1946
|
triggerAction: d
|
|
1941
1947
|
}
|
|
1942
1948
|
) : /* @__PURE__ */ t.jsx(
|
|
1943
|
-
|
|
1949
|
+
hs,
|
|
1944
1950
|
{
|
|
1945
|
-
filesViewRef:
|
|
1951
|
+
filesViewRef: c,
|
|
1946
1952
|
file: r,
|
|
1947
1953
|
onRename: s,
|
|
1948
1954
|
triggerAction: d
|
|
@@ -1950,7 +1956,7 @@ const zr = ({
|
|
|
1950
1956
|
) }) : /* @__PURE__ */ t.jsx("span", { className: "text-truncate file-name", children: r.name })
|
|
1951
1957
|
] }),
|
|
1952
1958
|
u === "list" && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
1953
|
-
/* @__PURE__ */ t.jsx("div", { className: "modified-date", children:
|
|
1959
|
+
/* @__PURE__ */ t.jsx("div", { className: "modified-date", children: ps(r.updatedAt) }),
|
|
1954
1960
|
/* @__PURE__ */ t.jsx("div", { className: "size", children: (r == null ? void 0 : r.size) > 0 ? Ze(r == null ? void 0 : r.size) : "" })
|
|
1955
1961
|
] }),
|
|
1956
1962
|
y && /* @__PURE__ */ t.jsxs(
|
|
@@ -1971,21 +1977,21 @@ const zr = ({
|
|
|
1971
1977
|
]
|
|
1972
1978
|
}
|
|
1973
1979
|
);
|
|
1974
|
-
},
|
|
1975
|
-
/* @__PURE__ */ t.jsx("span", { className: "item-selected", children: s.selected && /* @__PURE__ */ t.jsx(
|
|
1980
|
+
}, ms = ({ subMenuRef: e, list: r, position: n = "right" }) => /* @__PURE__ */ t.jsx("ul", { ref: e, className: `sub-menu ${n}`, children: r == null ? void 0 : r.map((s) => /* @__PURE__ */ t.jsxs("li", { onClick: s.onClick, children: [
|
|
1981
|
+
/* @__PURE__ */ t.jsx("span", { className: "item-selected", children: s.selected && /* @__PURE__ */ t.jsx(wr, { size: 13 }) }),
|
|
1976
1982
|
s.icon,
|
|
1977
1983
|
/* @__PURE__ */ t.jsx("span", { children: s.title })
|
|
1978
|
-
] }, s.title)) }),
|
|
1979
|
-
const [
|
|
1980
|
-
const { clickX: C, clickY: j } = a, y = e.current, b = y.getBoundingClientRect(), u = y.offsetWidth - y.clientWidth, g = r.current.getBoundingClientRect(),
|
|
1981
|
-
F ? (
|
|
1984
|
+
] }, s.title)) }), gs = ({ filesViewRef: e, contextMenuRef: r, menuItems: n, visible: s, clickPosition: a }) => {
|
|
1985
|
+
const [i, c] = L(0), [l, d] = L(0), [p, f] = L(null), [h, w] = L("right"), S = de(null), M = () => {
|
|
1986
|
+
const { clickX: C, clickY: j } = a, y = e.current, b = y.getBoundingClientRect(), u = y.offsetWidth - y.clientWidth, g = r.current.getBoundingClientRect(), _ = g.width, x = g.height, R = C - b.left, F = b.width - (R + u) > _, A = !F, N = j - b.top, k = b.height - N > x, X = !k;
|
|
1987
|
+
F ? (c(`${R}px`), w("right")) : A && (c(`${R - _}px`), w("left")), k ? d(`${N + y.scrollTop}px`) : X && d(`${N + y.scrollTop - x}px`);
|
|
1982
1988
|
}, z = (C) => {
|
|
1983
1989
|
C.preventDefault(), C.stopPropagation();
|
|
1984
|
-
},
|
|
1990
|
+
}, D = (C) => {
|
|
1985
1991
|
f(C);
|
|
1986
1992
|
};
|
|
1987
1993
|
if (se(() => {
|
|
1988
|
-
s && r.current ?
|
|
1994
|
+
s && r.current ? M() : (d(0), c(0), f(null));
|
|
1989
1995
|
}, [s]), s)
|
|
1990
1996
|
return /* @__PURE__ */ t.jsx(
|
|
1991
1997
|
"div",
|
|
@@ -1996,28 +2002,28 @@ const zr = ({
|
|
|
1996
2002
|
className: `fm-context-menu ${l ? "visible" : "hidden"}`,
|
|
1997
2003
|
style: {
|
|
1998
2004
|
top: l,
|
|
1999
|
-
left:
|
|
2005
|
+
left: i
|
|
2000
2006
|
},
|
|
2001
2007
|
children: /* @__PURE__ */ t.jsx("div", { className: "file-context-menu-list", children: /* @__PURE__ */ t.jsx("ul", { children: n.filter((C) => !C.hidden).map((C, j) => {
|
|
2002
|
-
const y = C.hasOwnProperty("children"), b =
|
|
2008
|
+
const y = C.hasOwnProperty("children"), b = p === j && y;
|
|
2003
2009
|
return /* @__PURE__ */ t.jsxs("div", { children: [
|
|
2004
2010
|
/* @__PURE__ */ t.jsxs(
|
|
2005
2011
|
"li",
|
|
2006
2012
|
{
|
|
2007
2013
|
onClick: C.onClick,
|
|
2008
2014
|
className: `${C.className ?? ""} ${b ? "active" : ""}`,
|
|
2009
|
-
onMouseOver: () =>
|
|
2015
|
+
onMouseOver: () => D(j),
|
|
2010
2016
|
children: [
|
|
2011
2017
|
C.icon,
|
|
2012
2018
|
/* @__PURE__ */ t.jsx("span", { children: C.title }),
|
|
2013
2019
|
y && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
2014
|
-
/* @__PURE__ */ t.jsx(
|
|
2020
|
+
/* @__PURE__ */ t.jsx(Sn, { size: 14, className: "list-expand-icon" }),
|
|
2015
2021
|
b && /* @__PURE__ */ t.jsx(
|
|
2016
|
-
|
|
2022
|
+
ms,
|
|
2017
2023
|
{
|
|
2018
|
-
subMenuRef:
|
|
2024
|
+
subMenuRef: S,
|
|
2019
2025
|
list: C.children,
|
|
2020
|
-
position:
|
|
2026
|
+
position: h
|
|
2021
2027
|
}
|
|
2022
2028
|
)
|
|
2023
2029
|
] })
|
|
@@ -2030,30 +2036,30 @@ const zr = ({
|
|
|
2030
2036
|
}
|
|
2031
2037
|
);
|
|
2032
2038
|
};
|
|
2033
|
-
function
|
|
2039
|
+
function ys(e) {
|
|
2034
2040
|
return H({ tag: "svg", attr: { viewBox: "0 0 256 256", fill: "currentColor" }, child: [{ tag: "path", attr: { d: "M245,110.64A16,16,0,0,0,232,104H216V88a16,16,0,0,0-16-16H130.67L102.94,51.2a16.14,16.14,0,0,0-9.6-3.2H40A16,16,0,0,0,24,64V208h0a8,8,0,0,0,8,8H211.1a8,8,0,0,0,7.59-5.47l28.49-85.47A16.05,16.05,0,0,0,245,110.64ZM93.34,64,123.2,86.4A8,8,0,0,0,128,88h72v16H69.77a16,16,0,0,0-15.18,10.94L40,158.7V64Zm112,136H43.1l26.67-80H232Z" }, child: [] }] })(e);
|
|
2035
2041
|
}
|
|
2036
|
-
const
|
|
2037
|
-
const [s, a] = L([]), [
|
|
2038
|
-
|
|
2039
|
-
},
|
|
2040
|
-
z(O),
|
|
2041
|
-
}, _ = () => {
|
|
2042
|
-
A(p), i(!1);
|
|
2042
|
+
const xs = (e, r, n) => {
|
|
2043
|
+
const [s, a] = L([]), [i, c] = L(!1), [l, d] = L(!1), [p, f] = L({ clickX: 0, clickY: 0 }), [h, w] = L(null), { clipBoard: S, setClipBoard: M, handleCutCopy: z, handlePasting: D } = Je(), { selectedFiles: C, setSelectedFiles: j, handleDownload: y } = Fe(), { currentPath: b, setCurrentPath: u, currentPathFiles: g, setCurrentPathFiles: _ } = Ee(), { activeLayout: x, setActiveLayout: R } = Se(), F = () => {
|
|
2044
|
+
h.isDirectory ? (u(h.path), a([]), j([])) : r && n.show("previewFile"), c(!1);
|
|
2045
|
+
}, A = (O) => {
|
|
2046
|
+
z(O), c(!1);
|
|
2043
2047
|
}, N = () => {
|
|
2044
|
-
|
|
2048
|
+
D(h), c(!1);
|
|
2049
|
+
}, k = () => {
|
|
2050
|
+
c(!1), n.show("rename");
|
|
2045
2051
|
}, X = () => {
|
|
2046
|
-
y(),
|
|
2052
|
+
y(), c(!1);
|
|
2047
2053
|
}, oe = () => {
|
|
2048
|
-
|
|
2054
|
+
c(!1), n.show("delete");
|
|
2049
2055
|
}, ae = () => {
|
|
2050
|
-
|
|
2056
|
+
c(!1), Le(e, "onRefresh"), M(null);
|
|
2051
2057
|
}, Q = () => {
|
|
2052
|
-
n.show("createFolder"),
|
|
2053
|
-
},
|
|
2054
|
-
|
|
2055
|
-
},
|
|
2056
|
-
j(g),
|
|
2058
|
+
n.show("createFolder"), c(!1);
|
|
2059
|
+
}, he = () => {
|
|
2060
|
+
c(!1), n.show("uploadFile");
|
|
2061
|
+
}, xe = () => {
|
|
2062
|
+
j(g), c(!1);
|
|
2057
2063
|
}, m = [
|
|
2058
2064
|
{
|
|
2059
2065
|
title: "View",
|
|
@@ -2066,7 +2072,7 @@ const gs = (e, r, n) => {
|
|
|
2066
2072
|
icon: /* @__PURE__ */ t.jsx(Dt, { size: 18 }),
|
|
2067
2073
|
selected: x === "grid",
|
|
2068
2074
|
onClick: () => {
|
|
2069
|
-
R("grid"),
|
|
2075
|
+
R("grid"), c(!1);
|
|
2070
2076
|
}
|
|
2071
2077
|
},
|
|
2072
2078
|
{
|
|
@@ -2074,81 +2080,81 @@ const gs = (e, r, n) => {
|
|
|
2074
2080
|
icon: /* @__PURE__ */ t.jsx(Ue, { size: 18 }),
|
|
2075
2081
|
selected: x === "list",
|
|
2076
2082
|
onClick: () => {
|
|
2077
|
-
R("list"),
|
|
2083
|
+
R("list"), c(!1);
|
|
2078
2084
|
}
|
|
2079
2085
|
}
|
|
2080
2086
|
]
|
|
2081
2087
|
},
|
|
2082
2088
|
{
|
|
2083
2089
|
title: "Refresh",
|
|
2084
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2090
|
+
icon: /* @__PURE__ */ t.jsx(xr, { size: 18 }),
|
|
2085
2091
|
onClick: ae,
|
|
2086
2092
|
divider: !0
|
|
2087
2093
|
},
|
|
2088
2094
|
{
|
|
2089
2095
|
title: "New folder",
|
|
2090
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2096
|
+
icon: /* @__PURE__ */ t.jsx(mr, { size: 18 }),
|
|
2091
2097
|
onClick: Q
|
|
2092
2098
|
},
|
|
2093
2099
|
{
|
|
2094
2100
|
title: "Upload",
|
|
2095
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2096
|
-
onClick:
|
|
2101
|
+
icon: /* @__PURE__ */ t.jsx(jr, { size: 18 }),
|
|
2102
|
+
onClick: he,
|
|
2097
2103
|
divider: !0
|
|
2098
2104
|
},
|
|
2099
2105
|
{
|
|
2100
2106
|
title: "Select all",
|
|
2101
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2102
|
-
onClick:
|
|
2107
|
+
icon: /* @__PURE__ */ t.jsx(Fn, { size: 18 }),
|
|
2108
|
+
onClick: xe
|
|
2103
2109
|
}
|
|
2104
2110
|
], P = [
|
|
2105
2111
|
{
|
|
2106
2112
|
title: "Open",
|
|
2107
|
-
icon:
|
|
2113
|
+
icon: h != null && h.isDirectory ? /* @__PURE__ */ t.jsx(ys, { size: 20 }) : /* @__PURE__ */ t.jsx(qe, { size: 16 }),
|
|
2108
2114
|
onClick: F,
|
|
2109
2115
|
divider: !0
|
|
2110
2116
|
},
|
|
2111
2117
|
{
|
|
2112
2118
|
title: "Cut",
|
|
2113
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2114
|
-
onClick: () =>
|
|
2119
|
+
icon: /* @__PURE__ */ t.jsx(yr, { size: 19 }),
|
|
2120
|
+
onClick: () => A(!0)
|
|
2115
2121
|
},
|
|
2116
2122
|
{
|
|
2117
2123
|
title: "Copy",
|
|
2118
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2119
|
-
onClick: () =>
|
|
2120
|
-
divider: !(
|
|
2124
|
+
icon: /* @__PURE__ */ t.jsx(vr, { strokeWidth: 0.1, size: 17 }),
|
|
2125
|
+
onClick: () => A(!1),
|
|
2126
|
+
divider: !(h != null && h.isDirectory)
|
|
2121
2127
|
},
|
|
2122
2128
|
{
|
|
2123
2129
|
title: "Paste",
|
|
2124
2130
|
icon: /* @__PURE__ */ t.jsx(mt, { size: 18 }),
|
|
2125
|
-
onClick:
|
|
2126
|
-
className: `${
|
|
2127
|
-
hidden: !(
|
|
2131
|
+
onClick: N,
|
|
2132
|
+
className: `${S ? "" : "disable-paste"}`,
|
|
2133
|
+
hidden: !(h != null && h.isDirectory),
|
|
2128
2134
|
divider: !0
|
|
2129
2135
|
},
|
|
2130
2136
|
{
|
|
2131
2137
|
title: "Rename",
|
|
2132
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2133
|
-
onClick:
|
|
2138
|
+
icon: /* @__PURE__ */ t.jsx(br, { size: 19 }),
|
|
2139
|
+
onClick: k,
|
|
2134
2140
|
hidden: C.length > 1
|
|
2135
2141
|
},
|
|
2136
2142
|
{
|
|
2137
2143
|
title: "Download",
|
|
2138
2144
|
icon: /* @__PURE__ */ t.jsx(Ct, { size: 18 }),
|
|
2139
2145
|
onClick: X,
|
|
2140
|
-
hidden:
|
|
2146
|
+
hidden: h == null ? void 0 : h.isDirectory
|
|
2141
2147
|
},
|
|
2142
2148
|
{
|
|
2143
2149
|
title: "Delete",
|
|
2144
|
-
icon: /* @__PURE__ */ t.jsx(
|
|
2150
|
+
icon: /* @__PURE__ */ t.jsx(Cr, { size: 19 }),
|
|
2145
2151
|
onClick: oe
|
|
2146
2152
|
}
|
|
2147
2153
|
], V = () => {
|
|
2148
|
-
|
|
2154
|
+
_((O) => [
|
|
2149
2155
|
...O,
|
|
2150
2156
|
{
|
|
2151
|
-
name:
|
|
2157
|
+
name: _r("New Folder", !0, O),
|
|
2152
2158
|
isDirectory: !0,
|
|
2153
2159
|
path: b,
|
|
2154
2160
|
isEditing: !0,
|
|
@@ -2156,11 +2162,11 @@ const gs = (e, r, n) => {
|
|
|
2156
2162
|
}
|
|
2157
2163
|
]);
|
|
2158
2164
|
}, W = () => {
|
|
2159
|
-
|
|
2165
|
+
_((O) => (O[s.at(-1)] && (O[s.at(-1)].isEditing = !0), O)), a([]), j([]);
|
|
2160
2166
|
}, I = () => {
|
|
2161
2167
|
a([]), j((O) => O.length > 0 ? [] : O);
|
|
2162
2168
|
}, K = (O, $ = !1) => {
|
|
2163
|
-
O.preventDefault(), f({ clickX: O.clientX, clickY: O.clientY }), d($), !$ && I(),
|
|
2169
|
+
O.preventDefault(), f({ clickX: O.clientX, clickY: O.clientY }), d($), !$ && I(), c(!0);
|
|
2164
2170
|
};
|
|
2165
2171
|
return se(() => {
|
|
2166
2172
|
if (n.isActive)
|
|
@@ -2181,16 +2187,16 @@ const gs = (e, r, n) => {
|
|
|
2181
2187
|
selecCtxItems: P,
|
|
2182
2188
|
handleContextMenu: K,
|
|
2183
2189
|
unselectFiles: I,
|
|
2184
|
-
visible:
|
|
2185
|
-
setVisible:
|
|
2186
|
-
setLastSelectedFile:
|
|
2190
|
+
visible: i,
|
|
2191
|
+
setVisible: c,
|
|
2192
|
+
setLastSelectedFile: w,
|
|
2187
2193
|
selectedFileIndexes: s,
|
|
2188
|
-
clickPosition:
|
|
2194
|
+
clickPosition: p,
|
|
2189
2195
|
isSelectionCtx: l
|
|
2190
2196
|
};
|
|
2191
|
-
},
|
|
2192
|
-
const [r, n] = L(!1), { selectedFiles: s, setSelectedFiles: a } = Fe(), { currentPathFiles:
|
|
2193
|
-
d.target.checked ? (a(
|
|
2197
|
+
}, Cs = ({ unselectFiles: e }) => {
|
|
2198
|
+
const [r, n] = L(!1), { selectedFiles: s, setSelectedFiles: a } = Fe(), { currentPathFiles: i } = Ee(), c = yt(() => i.length > 0 && s.length === i.length, [s, i]), l = (d) => {
|
|
2199
|
+
d.target.checked ? (a(i), n(!0)) : e();
|
|
2194
2200
|
};
|
|
2195
2201
|
return /* @__PURE__ */ t.jsxs(
|
|
2196
2202
|
"div",
|
|
@@ -2199,44 +2205,44 @@ const gs = (e, r, n) => {
|
|
|
2199
2205
|
onMouseOver: () => n(!0),
|
|
2200
2206
|
onMouseLeave: () => n(!1),
|
|
2201
2207
|
children: [
|
|
2202
|
-
/* @__PURE__ */ t.jsx("div", { className: "file-select-all", children: (r ||
|
|
2208
|
+
/* @__PURE__ */ t.jsx("div", { className: "file-select-all", children: (r || c) && /* @__PURE__ */ t.jsx(Dr, { checked: c, onChange: l, title: "Select all", disabled: i.length === 0 }) }),
|
|
2203
2209
|
/* @__PURE__ */ t.jsx("div", { className: "file-name", children: "Name" }),
|
|
2204
2210
|
/* @__PURE__ */ t.jsx("div", { className: "file-date", children: "Modified" }),
|
|
2205
2211
|
/* @__PURE__ */ t.jsx("div", { className: "file-size", children: "Size" })
|
|
2206
2212
|
]
|
|
2207
2213
|
}
|
|
2208
2214
|
);
|
|
2209
|
-
},
|
|
2215
|
+
}, Ir = ({
|
|
2210
2216
|
onCreateFolder: e,
|
|
2211
2217
|
onRename: r,
|
|
2212
2218
|
onFileOpen: n,
|
|
2213
2219
|
onRefresh: s,
|
|
2214
2220
|
enableFilePreview: a,
|
|
2215
|
-
triggerAction:
|
|
2221
|
+
triggerAction: i
|
|
2216
2222
|
}) => {
|
|
2217
|
-
const { currentPathFiles:
|
|
2218
|
-
emptySelecCtxItems:
|
|
2223
|
+
const { currentPathFiles: c } = Ee(), l = de(null), { activeLayout: d } = Se(), {
|
|
2224
|
+
emptySelecCtxItems: p,
|
|
2219
2225
|
selecCtxItems: f,
|
|
2220
|
-
handleContextMenu:
|
|
2221
|
-
unselectFiles:
|
|
2222
|
-
visible:
|
|
2223
|
-
setVisible:
|
|
2226
|
+
handleContextMenu: h,
|
|
2227
|
+
unselectFiles: w,
|
|
2228
|
+
visible: S,
|
|
2229
|
+
setVisible: M,
|
|
2224
2230
|
setLastSelectedFile: z,
|
|
2225
|
-
selectedFileIndexes:
|
|
2231
|
+
selectedFileIndexes: D,
|
|
2226
2232
|
clickPosition: C,
|
|
2227
2233
|
isSelectionCtx: j
|
|
2228
|
-
} =
|
|
2234
|
+
} = xs(s, a, i), y = Be(() => M(!1));
|
|
2229
2235
|
return /* @__PURE__ */ t.jsxs(
|
|
2230
2236
|
"div",
|
|
2231
2237
|
{
|
|
2232
2238
|
ref: l,
|
|
2233
2239
|
className: `files ${d}`,
|
|
2234
|
-
onContextMenu:
|
|
2235
|
-
onClick:
|
|
2240
|
+
onContextMenu: h,
|
|
2241
|
+
onClick: w,
|
|
2236
2242
|
children: [
|
|
2237
|
-
d === "list" && /* @__PURE__ */ t.jsx(
|
|
2238
|
-
(
|
|
2239
|
-
|
|
2243
|
+
d === "list" && /* @__PURE__ */ t.jsx(Cs, { unselectFiles: w }),
|
|
2244
|
+
(c == null ? void 0 : c.length) > 0 ? /* @__PURE__ */ t.jsx(t.Fragment, { children: c.map((b, u) => /* @__PURE__ */ t.jsx(
|
|
2245
|
+
vs,
|
|
2240
2246
|
{
|
|
2241
2247
|
index: u,
|
|
2242
2248
|
file: b,
|
|
@@ -2244,23 +2250,23 @@ const gs = (e, r, n) => {
|
|
|
2244
2250
|
onRename: r,
|
|
2245
2251
|
onFileOpen: n,
|
|
2246
2252
|
enableFilePreview: a,
|
|
2247
|
-
triggerAction:
|
|
2253
|
+
triggerAction: i,
|
|
2248
2254
|
filesViewRef: l,
|
|
2249
|
-
selectedFileIndexes:
|
|
2250
|
-
handleContextMenu:
|
|
2251
|
-
setVisible:
|
|
2255
|
+
selectedFileIndexes: D,
|
|
2256
|
+
handleContextMenu: h,
|
|
2257
|
+
setVisible: M,
|
|
2252
2258
|
setLastSelectedFile: z
|
|
2253
2259
|
},
|
|
2254
2260
|
u
|
|
2255
2261
|
)) }) : /* @__PURE__ */ t.jsx("div", { className: "empty-folder", children: "This folder is empty." }),
|
|
2256
2262
|
/* @__PURE__ */ t.jsx(
|
|
2257
|
-
|
|
2263
|
+
gs,
|
|
2258
2264
|
{
|
|
2259
2265
|
filesViewRef: l,
|
|
2260
2266
|
contextMenuRef: y.ref,
|
|
2261
|
-
menuItems: j ? f :
|
|
2262
|
-
visible:
|
|
2263
|
-
setVisible:
|
|
2267
|
+
menuItems: j ? f : p,
|
|
2268
|
+
visible: S,
|
|
2269
|
+
setVisible: M,
|
|
2264
2270
|
clickPosition: C
|
|
2265
2271
|
}
|
|
2266
2272
|
)
|
|
@@ -2268,9 +2274,9 @@ const gs = (e, r, n) => {
|
|
|
2268
2274
|
}
|
|
2269
2275
|
);
|
|
2270
2276
|
};
|
|
2271
|
-
|
|
2272
|
-
const
|
|
2273
|
-
const [n, s] = L(""), { selectedFiles: a, setSelectedFiles:
|
|
2277
|
+
Ir.displayName = "FileList";
|
|
2278
|
+
const js = ({ triggerAction: e, onDelete: r }) => {
|
|
2279
|
+
const [n, s] = L(""), { selectedFiles: a, setSelectedFiles: i } = Fe();
|
|
2274
2280
|
se(() => {
|
|
2275
2281
|
s(() => {
|
|
2276
2282
|
if (a.length === 1)
|
|
@@ -2279,46 +2285,46 @@ const xs = ({ triggerAction: e, onDelete: r }) => {
|
|
|
2279
2285
|
return `Are you sure you want to delete these ${a.length} items?`;
|
|
2280
2286
|
});
|
|
2281
2287
|
}, []);
|
|
2282
|
-
const
|
|
2283
|
-
r(a),
|
|
2288
|
+
const c = () => {
|
|
2289
|
+
r(a), i([]), e.close();
|
|
2284
2290
|
};
|
|
2285
2291
|
return /* @__PURE__ */ t.jsxs("div", { className: "file-delete-confirm", children: [
|
|
2286
2292
|
/* @__PURE__ */ t.jsx("p", { className: "file-delete-confirm-text", children: n }),
|
|
2287
2293
|
/* @__PURE__ */ t.jsxs("div", { className: "file-delete-confirm-actions", children: [
|
|
2288
2294
|
/* @__PURE__ */ t.jsx(Ne, { type: "secondary", onClick: () => e.close(), children: "Cancel" }),
|
|
2289
|
-
/* @__PURE__ */ t.jsx(Ne, { type: "danger", onClick:
|
|
2295
|
+
/* @__PURE__ */ t.jsx(Ne, { type: "danger", onClick: c, children: "Delete" })
|
|
2290
2296
|
] })
|
|
2291
2297
|
] });
|
|
2292
2298
|
};
|
|
2293
|
-
function
|
|
2299
|
+
function bs(e) {
|
|
2294
2300
|
return H({ tag: "svg", attr: { viewBox: "0 0 1024 1024", fill: "currentColor", fillRule: "evenodd" }, child: [{ tag: "path", attr: { d: "M799.855 166.312c.023.007.043.018.084.059l57.69 57.69c.041.041.052.06.059.084a.118.118 0 0 1 0 .069c-.007.023-.018.042-.059.083L569.926 512l287.703 287.703c.041.04.052.06.059.083a.118.118 0 0 1 0 .07c-.007.022-.018.042-.059.083l-57.69 57.69c-.041.041-.06.052-.084.059a.118.118 0 0 1-.069 0c-.023-.007-.042-.018-.083-.059L512 569.926 224.297 857.629c-.04.041-.06.052-.083.059a.118.118 0 0 1-.07 0c-.022-.007-.042-.018-.083-.059l-57.69-57.69c-.041-.041-.052-.06-.059-.084a.118.118 0 0 1 0-.069c.007-.023.018-.042.059-.083L454.073 512 166.371 224.297c-.041-.04-.052-.06-.059-.083a.118.118 0 0 1 0-.07c.007-.022.018-.042.059-.083l57.69-57.69c.041-.041.06-.052.084-.059a.118.118 0 0 1 .069 0c.023.007.042.018.083.059L512 454.073l287.703-287.702c.04-.041.06-.052.083-.059a.118.118 0 0 1 .07 0Z" }, child: [] }] })(e);
|
|
2295
2301
|
}
|
|
2296
|
-
function
|
|
2302
|
+
function ws(e) {
|
|
2297
2303
|
return H({ tag: "svg", attr: { viewBox: "0 0 1024 1024" }, child: [{ tag: "path", attr: { d: "M518.3 459a8 8 0 0 0-12.6 0l-112 141.7a7.98 7.98 0 0 0 6.3 12.9h73.9V856c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V613.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 459z" }, child: [] }, { tag: "path", attr: { d: "M811.4 366.7C765.6 245.9 648.9 160 512.2 160S258.8 245.8 213 366.6C127.3 389.1 64 467.2 64 560c0 110.5 89.5 200 199.9 200H304c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8h-40.1c-33.7 0-65.4-13.4-89-37.7-23.5-24.2-36-56.8-34.9-90.6.9-26.4 9.9-51.2 26.2-72.1 16.7-21.3 40.1-36.8 66.1-43.7l37.9-9.9 13.9-36.6c8.6-22.8 20.6-44.1 35.7-63.4a245.6 245.6 0 0 1 52.4-49.9c41.1-28.9 89.5-44.2 140-44.2s98.9 15.3 140 44.2c19.9 14 37.5 30.8 52.4 49.9 15.1 19.3 27.1 40.7 35.7 63.4l13.8 36.5 37.8 10C846.1 454.5 884 503.8 884 560c0 33.1-12.9 64.3-36.3 87.7a123.07 123.07 0 0 1-87.6 36.3H720c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h40.1C870.5 760 960 670.5 960 560c0-92.7-63.1-170.7-148.6-193.3z" }, child: [] }] })(e);
|
|
2298
2304
|
}
|
|
2299
|
-
const
|
|
2305
|
+
const Es = ({ percent: e = 0, isCanceled: r = !1, isCompleted: n = !1, error: s }) => /* @__PURE__ */ t.jsxs("div", { role: "progressbar", className: "fm-progress", children: [
|
|
2300
2306
|
!s && /* @__PURE__ */ t.jsx("div", { className: "fm-progress-bar", children: /* @__PURE__ */ t.jsx("div", { className: "fm-progress-bar-fill", style: { width: `${e}%` } }) }),
|
|
2301
2307
|
r ? /* @__PURE__ */ t.jsx("span", { className: "fm-upload-canceled", children: "Canceled" }) : s ? /* @__PURE__ */ t.jsx("span", { className: "fm-upload-canceled", children: s }) : /* @__PURE__ */ t.jsx("div", { className: "fm-progress-status", children: /* @__PURE__ */ t.jsx("span", { children: n ? "Completed" : e + "% done" }) })
|
|
2302
2308
|
] });
|
|
2303
|
-
function
|
|
2309
|
+
function Rs(e) {
|
|
2304
2310
|
return H({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "path", attr: { d: "M256 388c-72.597 0-132-59.405-132-132 0-72.601 59.403-132 132-132 36.3 0 69.299 15.4 92.406 39.601L278 234h154V80l-51.698 51.702C348.406 99.798 304.406 80 256 80c-96.797 0-176 79.203-176 176s78.094 176 176 176c81.045 0 148.287-54.134 169.401-128H378.85c-18.745 49.561-67.138 84-122.85 84z" }, child: [] }] })(e);
|
|
2305
2311
|
}
|
|
2306
|
-
const
|
|
2312
|
+
const Ps = ({
|
|
2307
2313
|
index: e,
|
|
2308
2314
|
fileData: r,
|
|
2309
2315
|
setFiles: n,
|
|
2310
2316
|
setIsUploading: s,
|
|
2311
2317
|
fileUploadConfig: a,
|
|
2312
|
-
onFileUploaded:
|
|
2313
|
-
handleFileRemove:
|
|
2318
|
+
onFileUploaded: i,
|
|
2319
|
+
handleFileRemove: c
|
|
2314
2320
|
}) => {
|
|
2315
|
-
var g,
|
|
2316
|
-
const [l, d] = L(0), [
|
|
2317
|
-
d(0), s((
|
|
2318
|
-
...
|
|
2321
|
+
var g, _, x, R;
|
|
2322
|
+
const [l, d] = L(0), [p, f] = L(!1), [h, w] = L(!1), [S, M] = L(!1), z = Xe(33), D = de(), { onError: C } = Ge(), j = (F) => {
|
|
2323
|
+
d(0), s((N) => ({
|
|
2324
|
+
...N,
|
|
2319
2325
|
[e]: !1
|
|
2320
2326
|
}));
|
|
2321
|
-
const
|
|
2327
|
+
const A = {
|
|
2322
2328
|
type: "upload",
|
|
2323
2329
|
message: "Upload failed.",
|
|
2324
2330
|
response: {
|
|
@@ -2328,114 +2334,114 @@ const Es = ({
|
|
|
2328
2334
|
}
|
|
2329
2335
|
};
|
|
2330
2336
|
n(
|
|
2331
|
-
(
|
|
2332
|
-
...
|
|
2333
|
-
error:
|
|
2334
|
-
} :
|
|
2335
|
-
),
|
|
2337
|
+
(N) => N.map((k, X) => e === X ? {
|
|
2338
|
+
...k,
|
|
2339
|
+
error: A.message
|
|
2340
|
+
} : k)
|
|
2341
|
+
), M(!0), C(A, r.file);
|
|
2336
2342
|
}, y = (F) => {
|
|
2337
2343
|
if (!F.error)
|
|
2338
|
-
return new Promise((
|
|
2339
|
-
const
|
|
2340
|
-
|
|
2344
|
+
return new Promise((A, N) => {
|
|
2345
|
+
const k = new XMLHttpRequest();
|
|
2346
|
+
D.current = k, s((Q) => ({
|
|
2341
2347
|
...Q,
|
|
2342
2348
|
[e]: !0
|
|
2343
|
-
})),
|
|
2349
|
+
})), k.upload.onprogress = (Q) => {
|
|
2344
2350
|
if (Q.lengthComputable) {
|
|
2345
|
-
const
|
|
2346
|
-
d(
|
|
2351
|
+
const he = Math.round(Q.loaded / Q.total * 100);
|
|
2352
|
+
d(he);
|
|
2347
2353
|
}
|
|
2348
|
-
},
|
|
2354
|
+
}, k.onload = () => {
|
|
2349
2355
|
s((Q) => ({
|
|
2350
2356
|
...Q,
|
|
2351
2357
|
[e]: !1
|
|
2352
|
-
})),
|
|
2353
|
-
},
|
|
2354
|
-
|
|
2355
|
-
},
|
|
2358
|
+
})), k.status === 200 || k.status === 201 ? (f(!0), i(k.response), A(k.response)) : (N(k.statusText), j(k));
|
|
2359
|
+
}, k.onerror = () => {
|
|
2360
|
+
N(k.statusText), j(k);
|
|
2361
|
+
}, k.open("POST", a == null ? void 0 : a.url, !0);
|
|
2356
2362
|
const X = a == null ? void 0 : a.headers;
|
|
2357
2363
|
for (let Q in X)
|
|
2358
|
-
|
|
2364
|
+
k.setRequestHeader(Q, X[Q]);
|
|
2359
2365
|
const oe = new FormData(), ae = F == null ? void 0 : F.appendData;
|
|
2360
2366
|
for (let Q in ae)
|
|
2361
2367
|
ae[Q] && oe.append(Q, ae[Q]);
|
|
2362
|
-
oe.append("file", F.file),
|
|
2368
|
+
oe.append("file", F.file), k.send(oe);
|
|
2363
2369
|
});
|
|
2364
2370
|
};
|
|
2365
2371
|
se(() => {
|
|
2366
|
-
|
|
2372
|
+
D.current || y(r);
|
|
2367
2373
|
}, []);
|
|
2368
2374
|
const b = () => {
|
|
2369
|
-
|
|
2375
|
+
D.current && (D.current.abort(), s((F) => ({
|
|
2370
2376
|
...F,
|
|
2371
2377
|
[e]: !1
|
|
2372
|
-
})),
|
|
2378
|
+
})), w(!0), d(0));
|
|
2373
2379
|
}, u = () => {
|
|
2374
2380
|
r != null && r.file && (n(
|
|
2375
|
-
(F) => F.map((
|
|
2376
|
-
...
|
|
2381
|
+
(F) => F.map((A, N) => e === N ? {
|
|
2382
|
+
...A,
|
|
2377
2383
|
error: !1
|
|
2378
|
-
} :
|
|
2379
|
-
), y({ ...r, error: !1 }),
|
|
2384
|
+
} : A)
|
|
2385
|
+
), y({ ...r, error: !1 }), w(!1), M(!1));
|
|
2380
2386
|
};
|
|
2381
2387
|
return r.removed ? null : /* @__PURE__ */ t.jsxs("li", { children: [
|
|
2382
2388
|
/* @__PURE__ */ t.jsx("div", { className: "file-icon", children: z[_e((g = r.file) == null ? void 0 : g.name)] ?? /* @__PURE__ */ t.jsx(qe, { size: 33 }) }),
|
|
2383
2389
|
/* @__PURE__ */ t.jsxs("div", { className: "file", children: [
|
|
2384
2390
|
/* @__PURE__ */ t.jsxs("div", { className: "file-details", children: [
|
|
2385
2391
|
/* @__PURE__ */ t.jsxs("div", { className: "file-info", children: [
|
|
2386
|
-
/* @__PURE__ */ t.jsx("span", { className: "file-name text-truncate", title: (
|
|
2392
|
+
/* @__PURE__ */ t.jsx("span", { className: "file-name text-truncate", title: (_ = r.file) == null ? void 0 : _.name, children: (x = r.file) == null ? void 0 : x.name }),
|
|
2387
2393
|
/* @__PURE__ */ t.jsx("span", { className: "file-size", children: Ze((R = r.file) == null ? void 0 : R.size) })
|
|
2388
2394
|
] }),
|
|
2389
|
-
|
|
2395
|
+
p ? /* @__PURE__ */ t.jsx(as, { title: "Uploaded", className: "upload-success" }) : h || S ? /* @__PURE__ */ t.jsx(Rs, { className: "retry-upload", title: "Retry", onClick: u }) : /* @__PURE__ */ t.jsx(
|
|
2390
2396
|
"div",
|
|
2391
2397
|
{
|
|
2392
2398
|
className: "rm-file",
|
|
2393
2399
|
title: `${r.error ? "Remove" : "Abort Upload"}`,
|
|
2394
|
-
onClick: r.error ? () =>
|
|
2395
|
-
children: /* @__PURE__ */ t.jsx(
|
|
2400
|
+
onClick: r.error ? () => c(e) : b,
|
|
2401
|
+
children: /* @__PURE__ */ t.jsx(bs, {})
|
|
2396
2402
|
}
|
|
2397
2403
|
)
|
|
2398
2404
|
] }),
|
|
2399
2405
|
/* @__PURE__ */ t.jsx(
|
|
2400
|
-
|
|
2406
|
+
Es,
|
|
2401
2407
|
{
|
|
2402
2408
|
percent: l,
|
|
2403
|
-
isCanceled:
|
|
2404
|
-
isCompleted:
|
|
2409
|
+
isCanceled: h,
|
|
2410
|
+
isCompleted: p,
|
|
2405
2411
|
error: r.error
|
|
2406
2412
|
}
|
|
2407
2413
|
)
|
|
2408
2414
|
] })
|
|
2409
2415
|
] });
|
|
2410
|
-
},
|
|
2416
|
+
}, Ts = ({
|
|
2411
2417
|
fileUploadConfig: e,
|
|
2412
2418
|
maxFileSize: r,
|
|
2413
2419
|
acceptedFileTypes: n,
|
|
2414
2420
|
onFileUploading: s,
|
|
2415
2421
|
onFileUploaded: a
|
|
2416
2422
|
}) => {
|
|
2417
|
-
const [
|
|
2418
|
-
u.key === "Enter" &&
|
|
2419
|
-
},
|
|
2423
|
+
const [i, c] = L([]), [l, d] = L(!1), [p, f] = L({}), { currentFolder: h, currentPathFiles: w } = Ee(), { onError: S } = Ge(), M = de(null), z = (u) => {
|
|
2424
|
+
u.key === "Enter" && M.current.click();
|
|
2425
|
+
}, D = (u) => {
|
|
2420
2426
|
if (n && !n.includes(_e(u.name)))
|
|
2421
2427
|
return "File type is not allowed.";
|
|
2422
|
-
if (
|
|
2428
|
+
if (w.some(
|
|
2423
2429
|
(x) => x.name.toLowerCase() === u.name.toLowerCase() && !x.isDirectory
|
|
2424
2430
|
)) return "File already exists.";
|
|
2425
2431
|
if (r && u.size > r) return `Maximum upload size is ${Ze(r, 0)}.`;
|
|
2426
2432
|
}, C = (u) => {
|
|
2427
2433
|
if (u = u.filter(
|
|
2428
|
-
(g) => !
|
|
2434
|
+
(g) => !i.some((_) => _.file.name.toLowerCase() === g.name.toLowerCase())
|
|
2429
2435
|
), u.length > 0) {
|
|
2430
|
-
const g = u.map((
|
|
2431
|
-
const x = s(
|
|
2432
|
-
return R &&
|
|
2433
|
-
file:
|
|
2436
|
+
const g = u.map((_) => {
|
|
2437
|
+
const x = s(_, h), R = D(_);
|
|
2438
|
+
return R && S({ type: "upload", message: R }, _), {
|
|
2439
|
+
file: _,
|
|
2434
2440
|
appendData: x,
|
|
2435
2441
|
...R && { error: R }
|
|
2436
2442
|
};
|
|
2437
2443
|
});
|
|
2438
|
-
|
|
2444
|
+
c((_) => [..._, ...g]);
|
|
2439
2445
|
}
|
|
2440
2446
|
}, j = (u) => {
|
|
2441
2447
|
u.preventDefault(), d(!1);
|
|
@@ -2445,15 +2451,15 @@ const Es = ({
|
|
|
2445
2451
|
const g = Array.from(u.target.files);
|
|
2446
2452
|
C(g);
|
|
2447
2453
|
}, b = (u) => {
|
|
2448
|
-
|
|
2449
|
-
const
|
|
2454
|
+
c((g) => {
|
|
2455
|
+
const _ = g.map((x, R) => u === R ? {
|
|
2450
2456
|
...x,
|
|
2451
2457
|
removed: !0
|
|
2452
2458
|
} : x);
|
|
2453
|
-
return
|
|
2459
|
+
return _.every((x) => !!x.removed) ? [] : _;
|
|
2454
2460
|
});
|
|
2455
2461
|
};
|
|
2456
|
-
return /* @__PURE__ */ t.jsxs("div", { className: `fm-upload-file ${
|
|
2462
|
+
return /* @__PURE__ */ t.jsxs("div", { className: `fm-upload-file ${i.length > 0 ? "file-selcted" : ""}`, children: [
|
|
2457
2463
|
/* @__PURE__ */ t.jsxs("div", { className: "select-files", children: [
|
|
2458
2464
|
/* @__PURE__ */ t.jsx(
|
|
2459
2465
|
"div",
|
|
@@ -2464,7 +2470,7 @@ const Es = ({
|
|
|
2464
2470
|
onDragEnter: () => d(!0),
|
|
2465
2471
|
onDragLeave: () => d(!1),
|
|
2466
2472
|
children: /* @__PURE__ */ t.jsxs("div", { className: "input-text", children: [
|
|
2467
|
-
/* @__PURE__ */ t.jsx(
|
|
2473
|
+
/* @__PURE__ */ t.jsx(ws, { size: 30 }),
|
|
2468
2474
|
/* @__PURE__ */ t.jsx("span", { children: "Drag files to upload" })
|
|
2469
2475
|
] })
|
|
2470
2476
|
}
|
|
@@ -2474,7 +2480,7 @@ const Es = ({
|
|
|
2474
2480
|
/* @__PURE__ */ t.jsx(
|
|
2475
2481
|
"input",
|
|
2476
2482
|
{
|
|
2477
|
-
ref:
|
|
2483
|
+
ref: M,
|
|
2478
2484
|
type: "file",
|
|
2479
2485
|
id: "chooseFile",
|
|
2480
2486
|
className: "choose-file-input",
|
|
@@ -2485,17 +2491,17 @@ const Es = ({
|
|
|
2485
2491
|
)
|
|
2486
2492
|
] }) })
|
|
2487
2493
|
] }),
|
|
2488
|
-
|
|
2489
|
-
/* @__PURE__ */ t.jsx("div", { className: "heading", children: Object.values(
|
|
2494
|
+
i.length > 0 && /* @__PURE__ */ t.jsxs("div", { className: "files-progress", children: [
|
|
2495
|
+
/* @__PURE__ */ t.jsx("div", { className: "heading", children: Object.values(p).some((u) => u) ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
2490
2496
|
/* @__PURE__ */ t.jsx("h2", { children: "Uploading" }),
|
|
2491
2497
|
/* @__PURE__ */ t.jsx(xt, { loading: !0, className: "upload-loading" })
|
|
2492
2498
|
] }) : /* @__PURE__ */ t.jsx("h2", { children: "Completed" }) }),
|
|
2493
|
-
/* @__PURE__ */ t.jsx("ul", { children:
|
|
2494
|
-
|
|
2499
|
+
/* @__PURE__ */ t.jsx("ul", { children: i.map((u, g) => /* @__PURE__ */ t.jsx(
|
|
2500
|
+
Ps,
|
|
2495
2501
|
{
|
|
2496
2502
|
index: g,
|
|
2497
2503
|
fileData: u,
|
|
2498
|
-
setFiles:
|
|
2504
|
+
setFiles: c,
|
|
2499
2505
|
fileUploadConfig: e,
|
|
2500
2506
|
setIsUploading: f,
|
|
2501
2507
|
onFileUploaded: a,
|
|
@@ -2505,77 +2511,77 @@ const Es = ({
|
|
|
2505
2511
|
)) })
|
|
2506
2512
|
] })
|
|
2507
2513
|
] });
|
|
2508
|
-
},
|
|
2509
|
-
var
|
|
2510
|
-
const [n, s] = L(!0), [a,
|
|
2511
|
-
() => r == null ? void 0 : r(
|
|
2514
|
+
}, Zt = ["jpg", "jpeg", "png"], Qt = ["mp4", "mov", "avi"], er = ["mp3", "wav", "m4a"], tr = ["txt", "pdf"], Fs = ({ filePreviewPath: e, filePreviewComponent: r }) => {
|
|
2515
|
+
var M;
|
|
2516
|
+
const [n, s] = L(!0), [a, i] = L(!1), { selectedFiles: c } = Fe(), l = Xe(73), d = (M = _e(c[0].name)) == null ? void 0 : M.toLowerCase(), p = `${e}${c[0].path}`, f = yt(
|
|
2517
|
+
() => r == null ? void 0 : r(c[0]),
|
|
2512
2518
|
[r]
|
|
2513
|
-
),
|
|
2514
|
-
s(!1),
|
|
2515
|
-
},
|
|
2516
|
-
s(!1),
|
|
2517
|
-
},
|
|
2518
|
-
window.location.href =
|
|
2519
|
+
), h = () => {
|
|
2520
|
+
s(!1), i(!1);
|
|
2521
|
+
}, w = () => {
|
|
2522
|
+
s(!1), i(!0);
|
|
2523
|
+
}, S = () => {
|
|
2524
|
+
window.location.href = p;
|
|
2519
2525
|
};
|
|
2520
2526
|
return Pe.isValidElement(f) ? f : /* @__PURE__ */ t.jsxs("section", { className: `file-previewer ${d === "pdf" ? "pdf-previewer" : ""}`, children: [
|
|
2521
2527
|
a || ![
|
|
2522
|
-
...Jt,
|
|
2523
2528
|
...Zt,
|
|
2524
2529
|
...Qt,
|
|
2525
|
-
...er
|
|
2530
|
+
...er,
|
|
2531
|
+
...tr
|
|
2526
2532
|
].includes(d) && /* @__PURE__ */ t.jsxs("div", { className: "preview-error", children: [
|
|
2527
|
-
/* @__PURE__ */ t.jsx("span", { className: "error-icon", children: l[d] ?? /* @__PURE__ */ t.jsx(
|
|
2533
|
+
/* @__PURE__ */ t.jsx("span", { className: "error-icon", children: l[d] ?? /* @__PURE__ */ t.jsx(is, { size: 73 }) }),
|
|
2528
2534
|
/* @__PURE__ */ t.jsx("span", { className: "error-msg", children: "Sorry! Preview is not available for this file." }),
|
|
2529
2535
|
/* @__PURE__ */ t.jsxs("div", { className: "file-info", children: [
|
|
2530
|
-
/* @__PURE__ */ t.jsx("span", { className: "file-name", children:
|
|
2531
|
-
|
|
2532
|
-
/* @__PURE__ */ t.jsx("span", { className: "file-size", children: Ze(
|
|
2536
|
+
/* @__PURE__ */ t.jsx("span", { className: "file-name", children: c[0].name }),
|
|
2537
|
+
c[0].size && /* @__PURE__ */ t.jsx("span", { children: "-" }),
|
|
2538
|
+
/* @__PURE__ */ t.jsx("span", { className: "file-size", children: Ze(c[0].size) })
|
|
2533
2539
|
] }),
|
|
2534
|
-
/* @__PURE__ */ t.jsx(Ne, { onClick:
|
|
2540
|
+
/* @__PURE__ */ t.jsx(Ne, { onClick: S, padding: "0.45rem .9rem", children: /* @__PURE__ */ t.jsxs("div", { className: "download-btn", children: [
|
|
2535
2541
|
/* @__PURE__ */ t.jsx(Ct, { size: 18 }),
|
|
2536
2542
|
/* @__PURE__ */ t.jsx("span", { children: "Download" })
|
|
2537
2543
|
] }) })
|
|
2538
2544
|
] }),
|
|
2539
|
-
|
|
2545
|
+
Zt.includes(d) && /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
|
|
2540
2546
|
/* @__PURE__ */ t.jsx(xt, { isLoading: n }),
|
|
2541
2547
|
/* @__PURE__ */ t.jsx(
|
|
2542
2548
|
"img",
|
|
2543
2549
|
{
|
|
2544
|
-
src:
|
|
2550
|
+
src: p,
|
|
2545
2551
|
alt: "Preview Unavailable",
|
|
2546
2552
|
className: `photo-popup-image ${n ? "img-loading" : ""}`,
|
|
2547
|
-
onLoad:
|
|
2548
|
-
onError:
|
|
2553
|
+
onLoad: h,
|
|
2554
|
+
onError: w,
|
|
2549
2555
|
loading: "lazy"
|
|
2550
2556
|
}
|
|
2551
2557
|
)
|
|
2552
2558
|
] }),
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2559
|
+
Qt.includes(d) && /* @__PURE__ */ t.jsx("video", { src: p, className: "video-preview", controls: !0, autoPlay: !0 }),
|
|
2560
|
+
er.includes(d) && /* @__PURE__ */ t.jsx("audio", { src: p, controls: !0, autoPlay: !0, className: "audio-preview" }),
|
|
2561
|
+
tr.includes(d) && /* @__PURE__ */ t.jsx(t.Fragment, { children: /* @__PURE__ */ t.jsx(
|
|
2556
2562
|
"iframe",
|
|
2557
2563
|
{
|
|
2558
|
-
src:
|
|
2559
|
-
onLoad:
|
|
2560
|
-
onError:
|
|
2564
|
+
src: p,
|
|
2565
|
+
onLoad: h,
|
|
2566
|
+
onError: w,
|
|
2561
2567
|
frameBorder: "0",
|
|
2562
2568
|
className: `photo-popup-iframe ${n ? "img-loading" : ""}`
|
|
2563
2569
|
}
|
|
2564
2570
|
) })
|
|
2565
2571
|
] });
|
|
2566
2572
|
}, ct = (e) => e.toLowerCase(), ge = (e, r, n = !1) => {
|
|
2567
|
-
const s = de(/* @__PURE__ */ new Set([])), a = yt(() => new Set(e.map((d) => ct(d))), [e]),
|
|
2573
|
+
const s = de(/* @__PURE__ */ new Set([])), a = yt(() => new Set(e.map((d) => ct(d))), [e]), i = (d) => {
|
|
2568
2574
|
if (!d.repeat && (s.current.add(ct(d.key)), a.isSubsetOf(s.current) && !n)) {
|
|
2569
2575
|
d.preventDefault(), r(d);
|
|
2570
2576
|
return;
|
|
2571
2577
|
}
|
|
2572
|
-
},
|
|
2578
|
+
}, c = (d) => {
|
|
2573
2579
|
s.current.delete(ct(d.key));
|
|
2574
2580
|
}, l = () => {
|
|
2575
2581
|
s.current.clear();
|
|
2576
2582
|
};
|
|
2577
|
-
se(() => (window.addEventListener("keydown",
|
|
2578
|
-
window.removeEventListener("keydown",
|
|
2583
|
+
se(() => (window.addEventListener("keydown", i), window.addEventListener("keyup", c), window.addEventListener("blur", l), () => {
|
|
2584
|
+
window.removeEventListener("keydown", i), window.removeEventListener("keyup", c), window.removeEventListener("blur", l);
|
|
2579
2585
|
}), [a, r, n]);
|
|
2580
2586
|
}, ye = {
|
|
2581
2587
|
createFolder: ["Alt", "Shift", "N"],
|
|
@@ -2599,61 +2605,61 @@ const Es = ({
|
|
|
2599
2605
|
// Act as Ctrl + Shift + 2 but could cause problems for QWERTZ or DVORAK etc. keyborad layouts.
|
|
2600
2606
|
refresh: ["F5"],
|
|
2601
2607
|
clearSelection: ["Escape"]
|
|
2602
|
-
},
|
|
2603
|
-
const { setClipBoard: n, handleCutCopy: s, handlePasting: a } = Je(), { currentFolder:
|
|
2608
|
+
}, Ss = (e, r) => {
|
|
2609
|
+
const { setClipBoard: n, handleCutCopy: s, handlePasting: a } = Je(), { currentFolder: i, currentPathFiles: c } = Ee(), { setSelectedFiles: l, handleDownload: d } = Fe(), { setActiveLayout: p } = Se(), f = () => {
|
|
2604
2610
|
e.show("createFolder");
|
|
2605
|
-
},
|
|
2611
|
+
}, h = () => {
|
|
2606
2612
|
e.show("uploadFile");
|
|
2607
|
-
},
|
|
2613
|
+
}, w = () => {
|
|
2608
2614
|
s(!0);
|
|
2609
|
-
}, M = () => {
|
|
2610
|
-
s(!1);
|
|
2611
2615
|
}, S = () => {
|
|
2612
|
-
|
|
2616
|
+
s(!1);
|
|
2617
|
+
}, M = () => {
|
|
2618
|
+
a(i);
|
|
2613
2619
|
}, z = () => {
|
|
2614
2620
|
e.show("rename");
|
|
2615
|
-
},
|
|
2621
|
+
}, D = () => {
|
|
2616
2622
|
d();
|
|
2617
2623
|
}, C = () => {
|
|
2618
2624
|
e.show("delete");
|
|
2619
2625
|
}, j = () => {
|
|
2620
|
-
|
|
2626
|
+
c.length > 0 && l([c[0]]);
|
|
2621
2627
|
}, y = () => {
|
|
2622
|
-
|
|
2628
|
+
c.length > 0 && l([c.at(-1)]);
|
|
2623
2629
|
}, b = () => {
|
|
2624
|
-
l(
|
|
2630
|
+
l(c);
|
|
2625
2631
|
}, u = () => {
|
|
2626
2632
|
l((R) => R.length > 0 ? [] : R);
|
|
2627
2633
|
}, g = () => {
|
|
2628
2634
|
Le(r, "onRefresh"), n(null);
|
|
2629
|
-
},
|
|
2630
|
-
|
|
2635
|
+
}, _ = () => {
|
|
2636
|
+
p("grid");
|
|
2631
2637
|
}, x = () => {
|
|
2632
|
-
|
|
2638
|
+
p("list");
|
|
2633
2639
|
};
|
|
2634
|
-
ge(ye.createFolder, f, e.isActive), ge(ye.uploadFiles,
|
|
2635
|
-
},
|
|
2640
|
+
ge(ye.createFolder, f, e.isActive), ge(ye.uploadFiles, h, e.isActive), ge(ye.cut, w, e.isActive), ge(ye.copy, S, e.isActive), ge(ye.paste, M, e.isActive), ge(ye.rename, z, e.isActive), ge(ye.download, D, e.isActive), ge(ye.delete, C, e.isActive), ge(ye.jumpToFirst, j, e.isActive), ge(ye.jumpToLast, y, e.isActive), ge(ye.selectAll, b, e.isActive), ge(ye.clearSelection, u, e.isActive), ge(ye.refresh, g, e.isActive), ge(ye.gridLayout, _, e.isActive), ge(ye.listLayout, x, e.isActive);
|
|
2641
|
+
}, Ms = ({
|
|
2636
2642
|
fileUploadConfig: e,
|
|
2637
2643
|
onFileUploading: r,
|
|
2638
2644
|
onFileUploaded: n,
|
|
2639
2645
|
onDelete: s,
|
|
2640
2646
|
onRefresh: a,
|
|
2641
|
-
maxFileSize:
|
|
2642
|
-
filePreviewPath:
|
|
2647
|
+
maxFileSize: i,
|
|
2648
|
+
filePreviewPath: c,
|
|
2643
2649
|
filePreviewComponent: l,
|
|
2644
2650
|
acceptedFileTypes: d,
|
|
2645
|
-
triggerAction:
|
|
2651
|
+
triggerAction: p
|
|
2646
2652
|
}) => {
|
|
2647
|
-
const [f,
|
|
2648
|
-
|
|
2649
|
-
const
|
|
2653
|
+
const [f, h] = L(null), { selectedFiles: w } = Fe();
|
|
2654
|
+
Ss(p, a);
|
|
2655
|
+
const S = {
|
|
2650
2656
|
uploadFile: {
|
|
2651
2657
|
title: "Upload",
|
|
2652
2658
|
component: /* @__PURE__ */ t.jsx(
|
|
2653
|
-
|
|
2659
|
+
Ts,
|
|
2654
2660
|
{
|
|
2655
2661
|
fileUploadConfig: e,
|
|
2656
|
-
maxFileSize:
|
|
2662
|
+
maxFileSize: i,
|
|
2657
2663
|
acceptedFileTypes: d,
|
|
2658
2664
|
onFileUploading: r,
|
|
2659
2665
|
onFileUploaded: n
|
|
@@ -2663,15 +2669,15 @@ const Es = ({
|
|
|
2663
2669
|
},
|
|
2664
2670
|
delete: {
|
|
2665
2671
|
title: "Delete",
|
|
2666
|
-
component: /* @__PURE__ */ t.jsx(
|
|
2672
|
+
component: /* @__PURE__ */ t.jsx(js, { triggerAction: p, onDelete: s }),
|
|
2667
2673
|
width: "25%"
|
|
2668
2674
|
},
|
|
2669
2675
|
previewFile: {
|
|
2670
2676
|
title: "Preview",
|
|
2671
2677
|
component: /* @__PURE__ */ t.jsx(
|
|
2672
|
-
|
|
2678
|
+
Fs,
|
|
2673
2679
|
{
|
|
2674
|
-
filePreviewPath:
|
|
2680
|
+
filePreviewPath: c,
|
|
2675
2681
|
filePreviewComponent: l
|
|
2676
2682
|
}
|
|
2677
2683
|
),
|
|
@@ -2679,52 +2685,52 @@ const Es = ({
|
|
|
2679
2685
|
}
|
|
2680
2686
|
};
|
|
2681
2687
|
if (se(() => {
|
|
2682
|
-
if (
|
|
2683
|
-
const
|
|
2684
|
-
|
|
2688
|
+
if (p.isActive) {
|
|
2689
|
+
const M = p.actionType;
|
|
2690
|
+
M === "previewFile" && (S[M].title = (w == null ? void 0 : w.name) ?? "Preview"), h(S[M]);
|
|
2685
2691
|
} else
|
|
2686
|
-
|
|
2687
|
-
}, [
|
|
2692
|
+
h(null);
|
|
2693
|
+
}, [p.isActive]), f)
|
|
2688
2694
|
return /* @__PURE__ */ t.jsx(
|
|
2689
|
-
|
|
2695
|
+
Ar,
|
|
2690
2696
|
{
|
|
2691
2697
|
heading: f.title,
|
|
2692
|
-
show:
|
|
2693
|
-
setShow:
|
|
2698
|
+
show: p.isActive,
|
|
2699
|
+
setShow: p.close,
|
|
2694
2700
|
dialogWidth: f.width,
|
|
2695
2701
|
children: f == null ? void 0 : f.component
|
|
2696
2702
|
}
|
|
2697
2703
|
);
|
|
2698
|
-
},
|
|
2704
|
+
}, Ls = () => {
|
|
2699
2705
|
const [e, r] = L(!1), [n, s] = L(null);
|
|
2700
2706
|
return {
|
|
2701
2707
|
isActive: e,
|
|
2702
2708
|
actionType: n,
|
|
2703
|
-
show: (
|
|
2704
|
-
r(!0), s(
|
|
2709
|
+
show: (c) => {
|
|
2710
|
+
r(!0), s(c);
|
|
2705
2711
|
},
|
|
2706
2712
|
close: () => {
|
|
2707
2713
|
r(!1), s(null);
|
|
2708
2714
|
}
|
|
2709
2715
|
};
|
|
2710
|
-
},
|
|
2711
|
-
const [n, s] = L({ col1: e, col2: r }), [a,
|
|
2716
|
+
}, Os = (e, r) => {
|
|
2717
|
+
const [n, s] = L({ col1: e, col2: r }), [a, i] = L(!1), c = de(null);
|
|
2712
2718
|
return {
|
|
2713
|
-
containerRef:
|
|
2719
|
+
containerRef: c,
|
|
2714
2720
|
colSizes: n,
|
|
2715
2721
|
setColSizes: s,
|
|
2716
2722
|
isDragging: a,
|
|
2717
2723
|
handleMouseDown: () => {
|
|
2718
|
-
|
|
2724
|
+
i(!0);
|
|
2719
2725
|
},
|
|
2720
2726
|
handleMouseUp: () => {
|
|
2721
|
-
|
|
2727
|
+
i(!1);
|
|
2722
2728
|
},
|
|
2723
2729
|
handleMouseMove: (f) => {
|
|
2724
2730
|
if (!a) return;
|
|
2725
2731
|
f.preventDefault();
|
|
2726
|
-
const
|
|
2727
|
-
|
|
2732
|
+
const w = c.current.getBoundingClientRect(), S = (f.clientX - w.left) / w.width * 100;
|
|
2733
|
+
S >= 15 && S <= 60 && s({ col1: S, col2: 100 - S });
|
|
2728
2734
|
}
|
|
2729
2735
|
};
|
|
2730
2736
|
};
|
|
@@ -2737,11 +2743,11 @@ var gt = { exports: {} }, We = { exports: {} }, re = {};
|
|
|
2737
2743
|
* This source code is licensed under the MIT license found in the
|
|
2738
2744
|
* LICENSE file in the root directory of this source tree.
|
|
2739
2745
|
*/
|
|
2740
|
-
var
|
|
2741
|
-
function
|
|
2742
|
-
if (
|
|
2743
|
-
|
|
2744
|
-
var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, s = e ? Symbol.for("react.fragment") : 60107, a = e ? Symbol.for("react.strict_mode") : 60108,
|
|
2746
|
+
var rr;
|
|
2747
|
+
function ks() {
|
|
2748
|
+
if (rr) return re;
|
|
2749
|
+
rr = 1;
|
|
2750
|
+
var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, s = e ? Symbol.for("react.fragment") : 60107, a = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, c = e ? Symbol.for("react.provider") : 60109, l = e ? Symbol.for("react.context") : 60110, d = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, f = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, w = e ? Symbol.for("react.suspense_list") : 60120, S = e ? Symbol.for("react.memo") : 60115, M = e ? Symbol.for("react.lazy") : 60116, z = e ? Symbol.for("react.block") : 60121, D = e ? Symbol.for("react.fundamental") : 60117, C = e ? Symbol.for("react.responder") : 60118, j = e ? Symbol.for("react.scope") : 60119;
|
|
2745
2751
|
function y(u) {
|
|
2746
2752
|
if (typeof u == "object" && u !== null) {
|
|
2747
2753
|
var g = u.$$typeof;
|
|
@@ -2749,19 +2755,19 @@ function Ls() {
|
|
|
2749
2755
|
case r:
|
|
2750
2756
|
switch (u = u.type, u) {
|
|
2751
2757
|
case d:
|
|
2752
|
-
case
|
|
2758
|
+
case p:
|
|
2753
2759
|
case s:
|
|
2754
|
-
case
|
|
2760
|
+
case i:
|
|
2755
2761
|
case a:
|
|
2756
|
-
case
|
|
2762
|
+
case h:
|
|
2757
2763
|
return u;
|
|
2758
2764
|
default:
|
|
2759
2765
|
switch (u = u && u.$$typeof, u) {
|
|
2760
2766
|
case l:
|
|
2761
2767
|
case f:
|
|
2762
|
-
case S:
|
|
2763
2768
|
case M:
|
|
2764
|
-
case
|
|
2769
|
+
case S:
|
|
2770
|
+
case c:
|
|
2765
2771
|
return u;
|
|
2766
2772
|
default:
|
|
2767
2773
|
return g;
|
|
@@ -2773,14 +2779,14 @@ function Ls() {
|
|
|
2773
2779
|
}
|
|
2774
2780
|
}
|
|
2775
2781
|
function b(u) {
|
|
2776
|
-
return y(u) ===
|
|
2782
|
+
return y(u) === p;
|
|
2777
2783
|
}
|
|
2778
|
-
return re.AsyncMode = d, re.ConcurrentMode =
|
|
2784
|
+
return re.AsyncMode = d, re.ConcurrentMode = p, re.ContextConsumer = l, re.ContextProvider = c, re.Element = r, re.ForwardRef = f, re.Fragment = s, re.Lazy = M, re.Memo = S, re.Portal = n, re.Profiler = i, re.StrictMode = a, re.Suspense = h, re.isAsyncMode = function(u) {
|
|
2779
2785
|
return b(u) || y(u) === d;
|
|
2780
2786
|
}, re.isConcurrentMode = b, re.isContextConsumer = function(u) {
|
|
2781
2787
|
return y(u) === l;
|
|
2782
2788
|
}, re.isContextProvider = function(u) {
|
|
2783
|
-
return y(u) ===
|
|
2789
|
+
return y(u) === c;
|
|
2784
2790
|
}, re.isElement = function(u) {
|
|
2785
2791
|
return typeof u == "object" && u !== null && u.$$typeof === r;
|
|
2786
2792
|
}, re.isForwardRef = function(u) {
|
|
@@ -2788,19 +2794,19 @@ function Ls() {
|
|
|
2788
2794
|
}, re.isFragment = function(u) {
|
|
2789
2795
|
return y(u) === s;
|
|
2790
2796
|
}, re.isLazy = function(u) {
|
|
2791
|
-
return y(u) === S;
|
|
2792
|
-
}, re.isMemo = function(u) {
|
|
2793
2797
|
return y(u) === M;
|
|
2798
|
+
}, re.isMemo = function(u) {
|
|
2799
|
+
return y(u) === S;
|
|
2794
2800
|
}, re.isPortal = function(u) {
|
|
2795
2801
|
return y(u) === n;
|
|
2796
2802
|
}, re.isProfiler = function(u) {
|
|
2797
|
-
return y(u) ===
|
|
2803
|
+
return y(u) === i;
|
|
2798
2804
|
}, re.isStrictMode = function(u) {
|
|
2799
2805
|
return y(u) === a;
|
|
2800
2806
|
}, re.isSuspense = function(u) {
|
|
2801
|
-
return y(u) ===
|
|
2807
|
+
return y(u) === h;
|
|
2802
2808
|
}, re.isValidElementType = function(u) {
|
|
2803
|
-
return typeof u == "string" || typeof u == "function" || u === s || u ===
|
|
2809
|
+
return typeof u == "string" || typeof u == "function" || u === s || u === p || u === i || u === a || u === h || u === w || typeof u == "object" && u !== null && (u.$$typeof === M || u.$$typeof === S || u.$$typeof === c || u.$$typeof === l || u.$$typeof === f || u.$$typeof === D || u.$$typeof === C || u.$$typeof === j || u.$$typeof === z);
|
|
2804
2810
|
}, re.typeOf = y, re;
|
|
2805
2811
|
}
|
|
2806
2812
|
var ne = {};
|
|
@@ -2812,36 +2818,36 @@ var ne = {};
|
|
|
2812
2818
|
* This source code is licensed under the MIT license found in the
|
|
2813
2819
|
* LICENSE file in the root directory of this source tree.
|
|
2814
2820
|
*/
|
|
2815
|
-
var
|
|
2816
|
-
function
|
|
2817
|
-
return
|
|
2818
|
-
var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, s = e ? Symbol.for("react.fragment") : 60107, a = e ? Symbol.for("react.strict_mode") : 60108,
|
|
2819
|
-
function y(
|
|
2820
|
-
return typeof
|
|
2821
|
-
|
|
2822
|
-
}
|
|
2823
|
-
function b(
|
|
2824
|
-
if (typeof
|
|
2825
|
-
var ve =
|
|
2821
|
+
var nr;
|
|
2822
|
+
function _s() {
|
|
2823
|
+
return nr || (nr = 1, process.env.NODE_ENV !== "production" && function() {
|
|
2824
|
+
var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, s = e ? Symbol.for("react.fragment") : 60107, a = e ? Symbol.for("react.strict_mode") : 60108, i = e ? Symbol.for("react.profiler") : 60114, c = e ? Symbol.for("react.provider") : 60109, l = e ? Symbol.for("react.context") : 60110, d = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, f = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, w = e ? Symbol.for("react.suspense_list") : 60120, S = e ? Symbol.for("react.memo") : 60115, M = e ? Symbol.for("react.lazy") : 60116, z = e ? Symbol.for("react.block") : 60121, D = e ? Symbol.for("react.fundamental") : 60117, C = e ? Symbol.for("react.responder") : 60118, j = e ? Symbol.for("react.scope") : 60119;
|
|
2825
|
+
function y(E) {
|
|
2826
|
+
return typeof E == "string" || typeof E == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
2827
|
+
E === s || E === p || E === i || E === a || E === h || E === w || typeof E == "object" && E !== null && (E.$$typeof === M || E.$$typeof === S || E.$$typeof === c || E.$$typeof === l || E.$$typeof === f || E.$$typeof === D || E.$$typeof === C || E.$$typeof === j || E.$$typeof === z);
|
|
2828
|
+
}
|
|
2829
|
+
function b(E) {
|
|
2830
|
+
if (typeof E == "object" && E !== null) {
|
|
2831
|
+
var ve = E.$$typeof;
|
|
2826
2832
|
switch (ve) {
|
|
2827
2833
|
case r:
|
|
2828
|
-
var Te =
|
|
2834
|
+
var Te = E.type;
|
|
2829
2835
|
switch (Te) {
|
|
2830
2836
|
case d:
|
|
2831
|
-
case
|
|
2837
|
+
case p:
|
|
2832
2838
|
case s:
|
|
2833
|
-
case
|
|
2839
|
+
case i:
|
|
2834
2840
|
case a:
|
|
2835
|
-
case
|
|
2841
|
+
case h:
|
|
2836
2842
|
return Te;
|
|
2837
2843
|
default:
|
|
2838
2844
|
var Y = Te && Te.$$typeof;
|
|
2839
2845
|
switch (Y) {
|
|
2840
2846
|
case l:
|
|
2841
2847
|
case f:
|
|
2842
|
-
case S:
|
|
2843
2848
|
case M:
|
|
2844
|
-
case
|
|
2849
|
+
case S:
|
|
2850
|
+
case c:
|
|
2845
2851
|
return Y;
|
|
2846
2852
|
default:
|
|
2847
2853
|
return ve;
|
|
@@ -2852,155 +2858,155 @@ function Os() {
|
|
|
2852
2858
|
}
|
|
2853
2859
|
}
|
|
2854
2860
|
}
|
|
2855
|
-
var u = d, g =
|
|
2856
|
-
function
|
|
2857
|
-
return
|
|
2861
|
+
var u = d, g = p, _ = l, x = c, R = r, F = f, A = s, N = M, k = S, X = n, oe = i, ae = a, Q = h, he = !1;
|
|
2862
|
+
function xe(E) {
|
|
2863
|
+
return he || (he = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), m(E) || b(E) === d;
|
|
2858
2864
|
}
|
|
2859
|
-
function m(
|
|
2860
|
-
return b(
|
|
2865
|
+
function m(E) {
|
|
2866
|
+
return b(E) === p;
|
|
2861
2867
|
}
|
|
2862
|
-
function P(
|
|
2863
|
-
return b(
|
|
2868
|
+
function P(E) {
|
|
2869
|
+
return b(E) === l;
|
|
2864
2870
|
}
|
|
2865
|
-
function V(
|
|
2866
|
-
return b(
|
|
2871
|
+
function V(E) {
|
|
2872
|
+
return b(E) === c;
|
|
2867
2873
|
}
|
|
2868
|
-
function W(
|
|
2869
|
-
return typeof
|
|
2874
|
+
function W(E) {
|
|
2875
|
+
return typeof E == "object" && E !== null && E.$$typeof === r;
|
|
2870
2876
|
}
|
|
2871
|
-
function I(
|
|
2872
|
-
return b(
|
|
2877
|
+
function I(E) {
|
|
2878
|
+
return b(E) === f;
|
|
2873
2879
|
}
|
|
2874
|
-
function K(
|
|
2875
|
-
return b(
|
|
2880
|
+
function K(E) {
|
|
2881
|
+
return b(E) === s;
|
|
2876
2882
|
}
|
|
2877
|
-
function O(
|
|
2878
|
-
return b(
|
|
2883
|
+
function O(E) {
|
|
2884
|
+
return b(E) === M;
|
|
2879
2885
|
}
|
|
2880
|
-
function $(
|
|
2881
|
-
return b(
|
|
2886
|
+
function $(E) {
|
|
2887
|
+
return b(E) === S;
|
|
2882
2888
|
}
|
|
2883
|
-
function U(
|
|
2884
|
-
return b(
|
|
2889
|
+
function U(E) {
|
|
2890
|
+
return b(E) === n;
|
|
2885
2891
|
}
|
|
2886
|
-
function
|
|
2887
|
-
return b(
|
|
2892
|
+
function Z(E) {
|
|
2893
|
+
return b(E) === i;
|
|
2888
2894
|
}
|
|
2889
|
-
function q(
|
|
2890
|
-
return b(
|
|
2895
|
+
function q(E) {
|
|
2896
|
+
return b(E) === a;
|
|
2891
2897
|
}
|
|
2892
|
-
function fe(
|
|
2893
|
-
return b(
|
|
2898
|
+
function fe(E) {
|
|
2899
|
+
return b(E) === h;
|
|
2894
2900
|
}
|
|
2895
|
-
ne.AsyncMode = u, ne.ConcurrentMode = g, ne.ContextConsumer =
|
|
2901
|
+
ne.AsyncMode = u, ne.ConcurrentMode = g, ne.ContextConsumer = _, ne.ContextProvider = x, ne.Element = R, ne.ForwardRef = F, ne.Fragment = A, ne.Lazy = N, ne.Memo = k, ne.Portal = X, ne.Profiler = oe, ne.StrictMode = ae, ne.Suspense = Q, ne.isAsyncMode = xe, ne.isConcurrentMode = m, ne.isContextConsumer = P, ne.isContextProvider = V, ne.isElement = W, ne.isForwardRef = I, ne.isFragment = K, ne.isLazy = O, ne.isMemo = $, ne.isPortal = U, ne.isProfiler = Z, ne.isStrictMode = q, ne.isSuspense = fe, ne.isValidElementType = y, ne.typeOf = b;
|
|
2896
2902
|
}()), ne;
|
|
2897
2903
|
}
|
|
2898
|
-
var
|
|
2899
|
-
function
|
|
2900
|
-
return
|
|
2904
|
+
var sr;
|
|
2905
|
+
function $r() {
|
|
2906
|
+
return sr || (sr = 1, process.env.NODE_ENV === "production" ? We.exports = ks() : We.exports = _s()), We.exports;
|
|
2901
2907
|
}
|
|
2902
2908
|
/*
|
|
2903
2909
|
object-assign
|
|
2904
2910
|
(c) Sindre Sorhus
|
|
2905
2911
|
@license MIT
|
|
2906
2912
|
*/
|
|
2907
|
-
var lt,
|
|
2908
|
-
function
|
|
2909
|
-
if (
|
|
2910
|
-
|
|
2913
|
+
var lt, or;
|
|
2914
|
+
function Ns() {
|
|
2915
|
+
if (or) return lt;
|
|
2916
|
+
or = 1;
|
|
2911
2917
|
var e = Object.getOwnPropertySymbols, r = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable;
|
|
2912
|
-
function s(
|
|
2913
|
-
if (
|
|
2918
|
+
function s(i) {
|
|
2919
|
+
if (i == null)
|
|
2914
2920
|
throw new TypeError("Object.assign cannot be called with null or undefined");
|
|
2915
|
-
return Object(
|
|
2921
|
+
return Object(i);
|
|
2916
2922
|
}
|
|
2917
2923
|
function a() {
|
|
2918
2924
|
try {
|
|
2919
2925
|
if (!Object.assign)
|
|
2920
2926
|
return !1;
|
|
2921
|
-
var
|
|
2922
|
-
if (
|
|
2927
|
+
var i = new String("abc");
|
|
2928
|
+
if (i[5] = "de", Object.getOwnPropertyNames(i)[0] === "5")
|
|
2923
2929
|
return !1;
|
|
2924
|
-
for (var
|
|
2925
|
-
|
|
2926
|
-
var d = Object.getOwnPropertyNames(
|
|
2927
|
-
return
|
|
2930
|
+
for (var c = {}, l = 0; l < 10; l++)
|
|
2931
|
+
c["_" + String.fromCharCode(l)] = l;
|
|
2932
|
+
var d = Object.getOwnPropertyNames(c).map(function(f) {
|
|
2933
|
+
return c[f];
|
|
2928
2934
|
});
|
|
2929
2935
|
if (d.join("") !== "0123456789")
|
|
2930
2936
|
return !1;
|
|
2931
|
-
var
|
|
2937
|
+
var p = {};
|
|
2932
2938
|
return "abcdefghijklmnopqrst".split("").forEach(function(f) {
|
|
2933
|
-
|
|
2934
|
-
}), Object.keys(Object.assign({},
|
|
2939
|
+
p[f] = f;
|
|
2940
|
+
}), Object.keys(Object.assign({}, p)).join("") === "abcdefghijklmnopqrst";
|
|
2935
2941
|
} catch {
|
|
2936
2942
|
return !1;
|
|
2937
2943
|
}
|
|
2938
2944
|
}
|
|
2939
|
-
return lt = a() ? Object.assign : function(
|
|
2940
|
-
for (var l, d = s(
|
|
2945
|
+
return lt = a() ? Object.assign : function(i, c) {
|
|
2946
|
+
for (var l, d = s(i), p, f = 1; f < arguments.length; f++) {
|
|
2941
2947
|
l = Object(arguments[f]);
|
|
2942
|
-
for (var
|
|
2943
|
-
r.call(l,
|
|
2948
|
+
for (var h in l)
|
|
2949
|
+
r.call(l, h) && (d[h] = l[h]);
|
|
2944
2950
|
if (e) {
|
|
2945
|
-
|
|
2946
|
-
for (var
|
|
2947
|
-
n.call(l,
|
|
2951
|
+
p = e(l);
|
|
2952
|
+
for (var w = 0; w < p.length; w++)
|
|
2953
|
+
n.call(l, p[w]) && (d[p[w]] = l[p[w]]);
|
|
2948
2954
|
}
|
|
2949
2955
|
}
|
|
2950
2956
|
return d;
|
|
2951
2957
|
}, lt;
|
|
2952
2958
|
}
|
|
2953
|
-
var ut,
|
|
2959
|
+
var ut, ar;
|
|
2954
2960
|
function jt() {
|
|
2955
|
-
if (
|
|
2956
|
-
|
|
2961
|
+
if (ar) return ut;
|
|
2962
|
+
ar = 1;
|
|
2957
2963
|
var e = "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";
|
|
2958
2964
|
return ut = e, ut;
|
|
2959
2965
|
}
|
|
2960
|
-
var dt,
|
|
2961
|
-
function
|
|
2962
|
-
return
|
|
2966
|
+
var dt, ir;
|
|
2967
|
+
function Br() {
|
|
2968
|
+
return ir || (ir = 1, dt = Function.call.bind(Object.prototype.hasOwnProperty)), dt;
|
|
2963
2969
|
}
|
|
2964
|
-
var ft,
|
|
2965
|
-
function
|
|
2966
|
-
if (
|
|
2967
|
-
|
|
2970
|
+
var ft, cr;
|
|
2971
|
+
function zs() {
|
|
2972
|
+
if (cr) return ft;
|
|
2973
|
+
cr = 1;
|
|
2968
2974
|
var e = function() {
|
|
2969
2975
|
};
|
|
2970
2976
|
if (process.env.NODE_ENV !== "production") {
|
|
2971
|
-
var r = jt(), n = {}, s =
|
|
2972
|
-
e = function(
|
|
2973
|
-
var
|
|
2974
|
-
typeof console < "u" && console.error(
|
|
2977
|
+
var r = jt(), n = {}, s = Br();
|
|
2978
|
+
e = function(i) {
|
|
2979
|
+
var c = "Warning: " + i;
|
|
2980
|
+
typeof console < "u" && console.error(c);
|
|
2975
2981
|
try {
|
|
2976
|
-
throw new Error(
|
|
2982
|
+
throw new Error(c);
|
|
2977
2983
|
} catch {
|
|
2978
2984
|
}
|
|
2979
2985
|
};
|
|
2980
2986
|
}
|
|
2981
|
-
function a(
|
|
2987
|
+
function a(i, c, l, d, p) {
|
|
2982
2988
|
if (process.env.NODE_ENV !== "production") {
|
|
2983
|
-
for (var f in
|
|
2984
|
-
if (s(
|
|
2985
|
-
var
|
|
2989
|
+
for (var f in i)
|
|
2990
|
+
if (s(i, f)) {
|
|
2991
|
+
var h;
|
|
2986
2992
|
try {
|
|
2987
|
-
if (typeof
|
|
2988
|
-
var
|
|
2989
|
-
(d || "React class") + ": " + l + " type `" + f + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof
|
|
2993
|
+
if (typeof i[f] != "function") {
|
|
2994
|
+
var w = Error(
|
|
2995
|
+
(d || "React class") + ": " + l + " type `" + f + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof i[f] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`."
|
|
2990
2996
|
);
|
|
2991
|
-
throw
|
|
2997
|
+
throw w.name = "Invariant Violation", w;
|
|
2992
2998
|
}
|
|
2993
|
-
|
|
2994
|
-
} catch (
|
|
2995
|
-
|
|
2999
|
+
h = i[f](c, f, d, l, null, r);
|
|
3000
|
+
} catch (M) {
|
|
3001
|
+
h = M;
|
|
2996
3002
|
}
|
|
2997
|
-
if (
|
|
2998
|
-
(d || "React class") + ": type specification of " + l + " `" + f + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof
|
|
2999
|
-
),
|
|
3000
|
-
n[
|
|
3001
|
-
var
|
|
3003
|
+
if (h && !(h instanceof Error) && e(
|
|
3004
|
+
(d || "React class") + ": type specification of " + l + " `" + f + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof h + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
|
|
3005
|
+
), h instanceof Error && !(h.message in n)) {
|
|
3006
|
+
n[h.message] = !0;
|
|
3007
|
+
var S = p ? p() : "";
|
|
3002
3008
|
e(
|
|
3003
|
-
"Failed " + l + " type: " +
|
|
3009
|
+
"Failed " + l + " type: " + h.message + (S ?? "")
|
|
3004
3010
|
);
|
|
3005
3011
|
}
|
|
3006
3012
|
}
|
|
@@ -3010,13 +3016,13 @@ function _s() {
|
|
|
3010
3016
|
process.env.NODE_ENV !== "production" && (n = {});
|
|
3011
3017
|
}, ft = a, ft;
|
|
3012
3018
|
}
|
|
3013
|
-
var ht,
|
|
3014
|
-
function
|
|
3015
|
-
if (
|
|
3016
|
-
|
|
3017
|
-
var e =
|
|
3019
|
+
var ht, lr;
|
|
3020
|
+
function As() {
|
|
3021
|
+
if (lr) return ht;
|
|
3022
|
+
lr = 1;
|
|
3023
|
+
var e = $r(), r = Ns(), n = jt(), s = Br(), a = zs(), i = function() {
|
|
3018
3024
|
};
|
|
3019
|
-
process.env.NODE_ENV !== "production" && (
|
|
3025
|
+
process.env.NODE_ENV !== "production" && (i = function(l) {
|
|
3020
3026
|
var d = "Warning: " + l;
|
|
3021
3027
|
typeof console < "u" && console.error(d);
|
|
3022
3028
|
try {
|
|
@@ -3024,17 +3030,17 @@ function Ns() {
|
|
|
3024
3030
|
} catch {
|
|
3025
3031
|
}
|
|
3026
3032
|
});
|
|
3027
|
-
function
|
|
3033
|
+
function c() {
|
|
3028
3034
|
return null;
|
|
3029
3035
|
}
|
|
3030
3036
|
return ht = function(l, d) {
|
|
3031
|
-
var
|
|
3032
|
-
function
|
|
3033
|
-
var P = m && (
|
|
3037
|
+
var p = typeof Symbol == "function" && Symbol.iterator, f = "@@iterator";
|
|
3038
|
+
function h(m) {
|
|
3039
|
+
var P = m && (p && m[p] || m[f]);
|
|
3034
3040
|
if (typeof P == "function")
|
|
3035
3041
|
return P;
|
|
3036
3042
|
}
|
|
3037
|
-
var
|
|
3043
|
+
var w = "<<anonymous>>", S = {
|
|
3038
3044
|
array: C("array"),
|
|
3039
3045
|
bigint: C("bigint"),
|
|
3040
3046
|
bool: C("boolean"),
|
|
@@ -3050,45 +3056,45 @@ function Ns() {
|
|
|
3050
3056
|
instanceOf: g,
|
|
3051
3057
|
node: F(),
|
|
3052
3058
|
objectOf: x,
|
|
3053
|
-
oneOf:
|
|
3059
|
+
oneOf: _,
|
|
3054
3060
|
oneOfType: R,
|
|
3055
|
-
shape:
|
|
3056
|
-
exact:
|
|
3061
|
+
shape: N,
|
|
3062
|
+
exact: k
|
|
3057
3063
|
};
|
|
3058
|
-
function
|
|
3064
|
+
function M(m, P) {
|
|
3059
3065
|
return m === P ? m !== 0 || 1 / m === 1 / P : m !== m && P !== P;
|
|
3060
3066
|
}
|
|
3061
3067
|
function z(m, P) {
|
|
3062
3068
|
this.message = m, this.data = P && typeof P == "object" ? P : {}, this.stack = "";
|
|
3063
3069
|
}
|
|
3064
3070
|
z.prototype = Error.prototype;
|
|
3065
|
-
function
|
|
3071
|
+
function D(m) {
|
|
3066
3072
|
if (process.env.NODE_ENV !== "production")
|
|
3067
3073
|
var P = {}, V = 0;
|
|
3068
|
-
function W(K, O, $, U,
|
|
3069
|
-
if (U = U ||
|
|
3074
|
+
function W(K, O, $, U, Z, q, fe) {
|
|
3075
|
+
if (U = U || w, q = q || $, fe !== n) {
|
|
3070
3076
|
if (d) {
|
|
3071
|
-
var
|
|
3077
|
+
var E = new Error(
|
|
3072
3078
|
"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"
|
|
3073
3079
|
);
|
|
3074
|
-
throw
|
|
3080
|
+
throw E.name = "Invariant Violation", E;
|
|
3075
3081
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
3076
3082
|
var ve = U + ":" + $;
|
|
3077
3083
|
!P[ve] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
3078
|
-
V < 3 && (
|
|
3084
|
+
V < 3 && (i(
|
|
3079
3085
|
"You are manually calling a React.PropTypes validation function for the `" + q + "` prop on `" + U + "`. 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."
|
|
3080
3086
|
), P[ve] = !0, V++);
|
|
3081
3087
|
}
|
|
3082
3088
|
}
|
|
3083
|
-
return O[$] == null ? K ? O[$] === null ? new z("The " +
|
|
3089
|
+
return O[$] == null ? K ? O[$] === null ? new z("The " + Z + " `" + q + "` is marked as required " + ("in `" + U + "`, but its value is `null`.")) : new z("The " + Z + " `" + q + "` is marked as required in " + ("`" + U + "`, but its value is `undefined`.")) : null : m(O, $, U, Z, q);
|
|
3084
3090
|
}
|
|
3085
3091
|
var I = W.bind(null, !1);
|
|
3086
3092
|
return I.isRequired = W.bind(null, !0), I;
|
|
3087
3093
|
}
|
|
3088
3094
|
function C(m) {
|
|
3089
3095
|
function P(V, W, I, K, O, $) {
|
|
3090
|
-
var U = V[W],
|
|
3091
|
-
if (
|
|
3096
|
+
var U = V[W], Z = ae(U);
|
|
3097
|
+
if (Z !== m) {
|
|
3092
3098
|
var q = Q(U);
|
|
3093
3099
|
return new z(
|
|
3094
3100
|
"Invalid " + K + " `" + O + "` of type " + ("`" + q + "` supplied to `" + I + "`, expected ") + ("`" + m + "`."),
|
|
@@ -3097,10 +3103,10 @@ function Ns() {
|
|
|
3097
3103
|
}
|
|
3098
3104
|
return null;
|
|
3099
3105
|
}
|
|
3100
|
-
return
|
|
3106
|
+
return D(P);
|
|
3101
3107
|
}
|
|
3102
3108
|
function j() {
|
|
3103
|
-
return
|
|
3109
|
+
return D(c);
|
|
3104
3110
|
}
|
|
3105
3111
|
function y(m) {
|
|
3106
3112
|
function P(V, W, I, K, O) {
|
|
@@ -3111,14 +3117,14 @@ function Ns() {
|
|
|
3111
3117
|
var U = ae($);
|
|
3112
3118
|
return new z("Invalid " + K + " `" + O + "` of type " + ("`" + U + "` supplied to `" + I + "`, expected an array."));
|
|
3113
3119
|
}
|
|
3114
|
-
for (var
|
|
3115
|
-
var q = m($,
|
|
3120
|
+
for (var Z = 0; Z < $.length; Z++) {
|
|
3121
|
+
var q = m($, Z, I, K, O + "[" + Z + "]", n);
|
|
3116
3122
|
if (q instanceof Error)
|
|
3117
3123
|
return q;
|
|
3118
3124
|
}
|
|
3119
3125
|
return null;
|
|
3120
3126
|
}
|
|
3121
|
-
return
|
|
3127
|
+
return D(P);
|
|
3122
3128
|
}
|
|
3123
3129
|
function b() {
|
|
3124
3130
|
function m(P, V, W, I, K) {
|
|
@@ -3129,7 +3135,7 @@ function Ns() {
|
|
|
3129
3135
|
}
|
|
3130
3136
|
return null;
|
|
3131
3137
|
}
|
|
3132
|
-
return
|
|
3138
|
+
return D(m);
|
|
3133
3139
|
}
|
|
3134
3140
|
function u() {
|
|
3135
3141
|
function m(P, V, W, I, K) {
|
|
@@ -3140,34 +3146,34 @@ function Ns() {
|
|
|
3140
3146
|
}
|
|
3141
3147
|
return null;
|
|
3142
3148
|
}
|
|
3143
|
-
return
|
|
3149
|
+
return D(m);
|
|
3144
3150
|
}
|
|
3145
3151
|
function g(m) {
|
|
3146
3152
|
function P(V, W, I, K, O) {
|
|
3147
3153
|
if (!(V[W] instanceof m)) {
|
|
3148
|
-
var $ = m.name ||
|
|
3154
|
+
var $ = m.name || w, U = xe(V[W]);
|
|
3149
3155
|
return new z("Invalid " + K + " `" + O + "` of type " + ("`" + U + "` supplied to `" + I + "`, expected ") + ("instance of `" + $ + "`."));
|
|
3150
3156
|
}
|
|
3151
3157
|
return null;
|
|
3152
3158
|
}
|
|
3153
|
-
return
|
|
3159
|
+
return D(P);
|
|
3154
3160
|
}
|
|
3155
|
-
function
|
|
3161
|
+
function _(m) {
|
|
3156
3162
|
if (!Array.isArray(m))
|
|
3157
|
-
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ?
|
|
3163
|
+
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
|
|
3158
3164
|
"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])."
|
|
3159
|
-
) :
|
|
3165
|
+
) : i("Invalid argument supplied to oneOf, expected an array.")), c;
|
|
3160
3166
|
function P(V, W, I, K, O) {
|
|
3161
3167
|
for (var $ = V[W], U = 0; U < m.length; U++)
|
|
3162
|
-
if (
|
|
3168
|
+
if (M($, m[U]))
|
|
3163
3169
|
return null;
|
|
3164
|
-
var
|
|
3165
|
-
var ve = Q(
|
|
3166
|
-
return ve === "symbol" ? String(
|
|
3170
|
+
var Z = JSON.stringify(m, function(fe, E) {
|
|
3171
|
+
var ve = Q(E);
|
|
3172
|
+
return ve === "symbol" ? String(E) : E;
|
|
3167
3173
|
});
|
|
3168
|
-
return new z("Invalid " + K + " `" + O + "` of value `" + String($) + "` " + ("supplied to `" + I + "`, expected one of " +
|
|
3174
|
+
return new z("Invalid " + K + " `" + O + "` of value `" + String($) + "` " + ("supplied to `" + I + "`, expected one of " + Z + "."));
|
|
3169
3175
|
}
|
|
3170
|
-
return
|
|
3176
|
+
return D(P);
|
|
3171
3177
|
}
|
|
3172
3178
|
function x(m) {
|
|
3173
3179
|
function P(V, W, I, K, O) {
|
|
@@ -3176,88 +3182,88 @@ function Ns() {
|
|
|
3176
3182
|
var $ = V[W], U = ae($);
|
|
3177
3183
|
if (U !== "object")
|
|
3178
3184
|
return new z("Invalid " + K + " `" + O + "` of type " + ("`" + U + "` supplied to `" + I + "`, expected an object."));
|
|
3179
|
-
for (var
|
|
3180
|
-
if (s($,
|
|
3181
|
-
var q = m($,
|
|
3185
|
+
for (var Z in $)
|
|
3186
|
+
if (s($, Z)) {
|
|
3187
|
+
var q = m($, Z, I, K, O + "." + Z, n);
|
|
3182
3188
|
if (q instanceof Error)
|
|
3183
3189
|
return q;
|
|
3184
3190
|
}
|
|
3185
3191
|
return null;
|
|
3186
3192
|
}
|
|
3187
|
-
return
|
|
3193
|
+
return D(P);
|
|
3188
3194
|
}
|
|
3189
3195
|
function R(m) {
|
|
3190
3196
|
if (!Array.isArray(m))
|
|
3191
|
-
return process.env.NODE_ENV !== "production" &&
|
|
3197
|
+
return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), c;
|
|
3192
3198
|
for (var P = 0; P < m.length; P++) {
|
|
3193
3199
|
var V = m[P];
|
|
3194
3200
|
if (typeof V != "function")
|
|
3195
|
-
return
|
|
3196
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " +
|
|
3197
|
-
),
|
|
3201
|
+
return i(
|
|
3202
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + he(V) + " at index " + P + "."
|
|
3203
|
+
), c;
|
|
3198
3204
|
}
|
|
3199
3205
|
function W(I, K, O, $, U) {
|
|
3200
|
-
for (var
|
|
3201
|
-
var fe = m[q],
|
|
3202
|
-
if (
|
|
3206
|
+
for (var Z = [], q = 0; q < m.length; q++) {
|
|
3207
|
+
var fe = m[q], E = fe(I, K, O, $, U, n);
|
|
3208
|
+
if (E == null)
|
|
3203
3209
|
return null;
|
|
3204
|
-
|
|
3210
|
+
E.data && s(E.data, "expectedType") && Z.push(E.data.expectedType);
|
|
3205
3211
|
}
|
|
3206
|
-
var ve =
|
|
3212
|
+
var ve = Z.length > 0 ? ", expected one of type [" + Z.join(", ") + "]" : "";
|
|
3207
3213
|
return new z("Invalid " + $ + " `" + U + "` supplied to " + ("`" + O + "`" + ve + "."));
|
|
3208
3214
|
}
|
|
3209
|
-
return
|
|
3215
|
+
return D(W);
|
|
3210
3216
|
}
|
|
3211
3217
|
function F() {
|
|
3212
3218
|
function m(P, V, W, I, K) {
|
|
3213
3219
|
return X(P[V]) ? null : new z("Invalid " + I + " `" + K + "` supplied to " + ("`" + W + "`, expected a ReactNode."));
|
|
3214
3220
|
}
|
|
3215
|
-
return
|
|
3221
|
+
return D(m);
|
|
3216
3222
|
}
|
|
3217
|
-
function
|
|
3223
|
+
function A(m, P, V, W, I) {
|
|
3218
3224
|
return new z(
|
|
3219
3225
|
(m || "React class") + ": " + P + " type `" + V + "." + W + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + I + "`."
|
|
3220
3226
|
);
|
|
3221
3227
|
}
|
|
3222
|
-
function
|
|
3228
|
+
function N(m) {
|
|
3223
3229
|
function P(V, W, I, K, O) {
|
|
3224
3230
|
var $ = V[W], U = ae($);
|
|
3225
3231
|
if (U !== "object")
|
|
3226
3232
|
return new z("Invalid " + K + " `" + O + "` of type `" + U + "` " + ("supplied to `" + I + "`, expected `object`."));
|
|
3227
|
-
for (var
|
|
3228
|
-
var q = m[
|
|
3233
|
+
for (var Z in m) {
|
|
3234
|
+
var q = m[Z];
|
|
3229
3235
|
if (typeof q != "function")
|
|
3230
|
-
return
|
|
3231
|
-
var fe = q($,
|
|
3236
|
+
return A(I, K, O, Z, Q(q));
|
|
3237
|
+
var fe = q($, Z, I, K, O + "." + Z, n);
|
|
3232
3238
|
if (fe)
|
|
3233
3239
|
return fe;
|
|
3234
3240
|
}
|
|
3235
3241
|
return null;
|
|
3236
3242
|
}
|
|
3237
|
-
return
|
|
3243
|
+
return D(P);
|
|
3238
3244
|
}
|
|
3239
|
-
function
|
|
3245
|
+
function k(m) {
|
|
3240
3246
|
function P(V, W, I, K, O) {
|
|
3241
3247
|
var $ = V[W], U = ae($);
|
|
3242
3248
|
if (U !== "object")
|
|
3243
3249
|
return new z("Invalid " + K + " `" + O + "` of type `" + U + "` " + ("supplied to `" + I + "`, expected `object`."));
|
|
3244
|
-
var
|
|
3245
|
-
for (var q in
|
|
3250
|
+
var Z = r({}, V[W], m);
|
|
3251
|
+
for (var q in Z) {
|
|
3246
3252
|
var fe = m[q];
|
|
3247
3253
|
if (s(m, q) && typeof fe != "function")
|
|
3248
|
-
return
|
|
3254
|
+
return A(I, K, O, q, Q(fe));
|
|
3249
3255
|
if (!fe)
|
|
3250
3256
|
return new z(
|
|
3251
3257
|
"Invalid " + K + " `" + O + "` key `" + q + "` supplied to `" + I + "`.\nBad object: " + JSON.stringify(V[W], null, " ") + `
|
|
3252
3258
|
Valid keys: ` + JSON.stringify(Object.keys(m), null, " ")
|
|
3253
3259
|
);
|
|
3254
|
-
var
|
|
3255
|
-
if (
|
|
3256
|
-
return
|
|
3260
|
+
var E = fe($, q, I, K, O + "." + q, n);
|
|
3261
|
+
if (E)
|
|
3262
|
+
return E;
|
|
3257
3263
|
}
|
|
3258
3264
|
return null;
|
|
3259
3265
|
}
|
|
3260
|
-
return
|
|
3266
|
+
return D(P);
|
|
3261
3267
|
}
|
|
3262
3268
|
function X(m) {
|
|
3263
3269
|
switch (typeof m) {
|
|
@@ -3272,7 +3278,7 @@ Valid keys: ` + JSON.stringify(Object.keys(m), null, " ")
|
|
|
3272
3278
|
return m.every(X);
|
|
3273
3279
|
if (m === null || l(m))
|
|
3274
3280
|
return !0;
|
|
3275
|
-
var P =
|
|
3281
|
+
var P = h(m);
|
|
3276
3282
|
if (P) {
|
|
3277
3283
|
var V = P.call(m), W;
|
|
3278
3284
|
if (P !== m.entries) {
|
|
@@ -3311,7 +3317,7 @@ Valid keys: ` + JSON.stringify(Object.keys(m), null, " ")
|
|
|
3311
3317
|
}
|
|
3312
3318
|
return P;
|
|
3313
3319
|
}
|
|
3314
|
-
function
|
|
3320
|
+
function he(m) {
|
|
3315
3321
|
var P = Q(m);
|
|
3316
3322
|
switch (P) {
|
|
3317
3323
|
case "array":
|
|
@@ -3325,35 +3331,35 @@ Valid keys: ` + JSON.stringify(Object.keys(m), null, " ")
|
|
|
3325
3331
|
return P;
|
|
3326
3332
|
}
|
|
3327
3333
|
}
|
|
3328
|
-
function
|
|
3329
|
-
return !m.constructor || !m.constructor.name ?
|
|
3334
|
+
function xe(m) {
|
|
3335
|
+
return !m.constructor || !m.constructor.name ? w : m.constructor.name;
|
|
3330
3336
|
}
|
|
3331
|
-
return
|
|
3337
|
+
return S.checkPropTypes = a, S.resetWarningCache = a.resetWarningCache, S.PropTypes = S, S;
|
|
3332
3338
|
}, ht;
|
|
3333
3339
|
}
|
|
3334
|
-
var pt,
|
|
3335
|
-
function
|
|
3336
|
-
if (
|
|
3337
|
-
|
|
3340
|
+
var pt, ur;
|
|
3341
|
+
function Ds() {
|
|
3342
|
+
if (ur) return pt;
|
|
3343
|
+
ur = 1;
|
|
3338
3344
|
var e = jt();
|
|
3339
3345
|
function r() {
|
|
3340
3346
|
}
|
|
3341
3347
|
function n() {
|
|
3342
3348
|
}
|
|
3343
3349
|
return n.resetWarningCache = r, pt = function() {
|
|
3344
|
-
function s(
|
|
3345
|
-
if (
|
|
3346
|
-
var
|
|
3350
|
+
function s(c, l, d, p, f, h) {
|
|
3351
|
+
if (h !== e) {
|
|
3352
|
+
var w = new Error(
|
|
3347
3353
|
"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"
|
|
3348
3354
|
);
|
|
3349
|
-
throw
|
|
3355
|
+
throw w.name = "Invariant Violation", w;
|
|
3350
3356
|
}
|
|
3351
3357
|
}
|
|
3352
3358
|
s.isRequired = s;
|
|
3353
3359
|
function a() {
|
|
3354
3360
|
return s;
|
|
3355
3361
|
}
|
|
3356
|
-
var
|
|
3362
|
+
var i = {
|
|
3357
3363
|
array: s,
|
|
3358
3364
|
bigint: s,
|
|
3359
3365
|
bool: s,
|
|
@@ -3376,22 +3382,22 @@ function zs() {
|
|
|
3376
3382
|
checkPropTypes: n,
|
|
3377
3383
|
resetWarningCache: r
|
|
3378
3384
|
};
|
|
3379
|
-
return
|
|
3385
|
+
return i.PropTypes = i, i;
|
|
3380
3386
|
}, pt;
|
|
3381
3387
|
}
|
|
3382
3388
|
if (process.env.NODE_ENV !== "production") {
|
|
3383
|
-
var
|
|
3384
|
-
gt.exports =
|
|
3389
|
+
var Is = $r(), $s = !0;
|
|
3390
|
+
gt.exports = As()(Is.isElement, $s);
|
|
3385
3391
|
} else
|
|
3386
|
-
gt.exports =
|
|
3387
|
-
var
|
|
3388
|
-
const
|
|
3392
|
+
gt.exports = Ds()();
|
|
3393
|
+
var Bs = gt.exports;
|
|
3394
|
+
const G = /* @__PURE__ */ dn(Bs), Hs = (e, r, n) => {
|
|
3389
3395
|
const s = e[r];
|
|
3390
3396
|
if (s && isNaN(Date.parse(s)))
|
|
3391
3397
|
return new Error(
|
|
3392
3398
|
`Invalid prop \`${r}\` supplied to \`${n}\`. Expected a valid date string (ISO 8601) but received \`${s}\`.`
|
|
3393
3399
|
);
|
|
3394
|
-
},
|
|
3400
|
+
}, dr = (e, r, n) => {
|
|
3395
3401
|
const s = e[r];
|
|
3396
3402
|
try {
|
|
3397
3403
|
new URL(s);
|
|
@@ -3401,86 +3407,88 @@ const Z = /* @__PURE__ */ un(Is), $s = (e, r, n) => {
|
|
|
3401
3407
|
`Invalid prop \`${r}\` supplied to \`${n}\`. Expected a valid URL but received \`${s}\`.`
|
|
3402
3408
|
);
|
|
3403
3409
|
}
|
|
3404
|
-
},
|
|
3410
|
+
}, Hr = ({
|
|
3405
3411
|
files: e,
|
|
3406
3412
|
fileUploadConfig: r,
|
|
3407
3413
|
isLoading: n,
|
|
3408
3414
|
onCreateFolder: s,
|
|
3409
3415
|
onFileUploading: a = () => {
|
|
3410
3416
|
},
|
|
3411
|
-
onFileUploaded:
|
|
3417
|
+
onFileUploaded: i = () => {
|
|
3412
3418
|
},
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3419
|
+
onCut: c,
|
|
3420
|
+
onCopy: l,
|
|
3421
|
+
onPaste: d,
|
|
3422
|
+
onRename: p,
|
|
3423
|
+
onDownload: f,
|
|
3416
3424
|
onDelete: h = () => null,
|
|
3417
|
-
onLayoutChange:
|
|
3425
|
+
onLayoutChange: w = () => {
|
|
3418
3426
|
},
|
|
3419
|
-
onRefresh:
|
|
3420
|
-
onFileOpen:
|
|
3427
|
+
onRefresh: S,
|
|
3428
|
+
onFileOpen: M = () => {
|
|
3421
3429
|
},
|
|
3422
|
-
onError:
|
|
3430
|
+
onError: z = () => {
|
|
3423
3431
|
},
|
|
3424
|
-
layout:
|
|
3425
|
-
enableFilePreview:
|
|
3426
|
-
maxFileSize:
|
|
3427
|
-
filePreviewPath:
|
|
3428
|
-
acceptedFileTypes:
|
|
3429
|
-
height:
|
|
3430
|
-
width:
|
|
3431
|
-
initialPath:
|
|
3432
|
-
filePreviewComponent:
|
|
3433
|
-
primaryColor:
|
|
3434
|
-
fontFamily:
|
|
3432
|
+
layout: D = "grid",
|
|
3433
|
+
enableFilePreview: C = !0,
|
|
3434
|
+
maxFileSize: j,
|
|
3435
|
+
filePreviewPath: y,
|
|
3436
|
+
acceptedFileTypes: b,
|
|
3437
|
+
height: u = "600px",
|
|
3438
|
+
width: g = "100%",
|
|
3439
|
+
initialPath: _ = "",
|
|
3440
|
+
filePreviewComponent: x,
|
|
3441
|
+
primaryColor: R = "#6155b4",
|
|
3442
|
+
fontFamily: F = "Nunito Sans, sans-serif"
|
|
3435
3443
|
}) => {
|
|
3436
|
-
const
|
|
3437
|
-
"--file-manager-font-family":
|
|
3438
|
-
"--file-manager-primary-color":
|
|
3439
|
-
height:
|
|
3440
|
-
width:
|
|
3444
|
+
const A = Ls(), { containerRef: N, colSizes: k, isDragging: X, handleMouseMove: oe, handleMouseUp: ae, handleMouseDown: Q } = Os(20, 80), he = {
|
|
3445
|
+
"--file-manager-font-family": F,
|
|
3446
|
+
"--file-manager-primary-color": R,
|
|
3447
|
+
height: u,
|
|
3448
|
+
width: g
|
|
3441
3449
|
};
|
|
3442
|
-
return /* @__PURE__ */ t.jsxs("main", { className: "file-explorer", onContextMenu: (
|
|
3450
|
+
return /* @__PURE__ */ t.jsxs("main", { className: "file-explorer", onContextMenu: (xe) => xe.preventDefault(), style: he, children: [
|
|
3443
3451
|
/* @__PURE__ */ t.jsx(xt, { loading: n }),
|
|
3444
|
-
/* @__PURE__ */ t.jsx(
|
|
3452
|
+
/* @__PURE__ */ t.jsx(zn, { filesData: e, onError: z, children: /* @__PURE__ */ t.jsx(Dn, { initialPath: _, children: /* @__PURE__ */ t.jsx(In, { onDownload: f, children: /* @__PURE__ */ t.jsx($n, { onPaste: d, onCut: c, onCopy: l, children: /* @__PURE__ */ t.jsxs(_n, { layout: D, children: [
|
|
3445
3453
|
/* @__PURE__ */ t.jsx(
|
|
3446
|
-
|
|
3454
|
+
Sr,
|
|
3447
3455
|
{
|
|
3448
3456
|
allowCreateFolder: !0,
|
|
3449
3457
|
allowUploadFile: !0,
|
|
3450
|
-
onLayoutChange:
|
|
3451
|
-
onRefresh:
|
|
3452
|
-
triggerAction:
|
|
3458
|
+
onLayoutChange: w,
|
|
3459
|
+
onRefresh: S,
|
|
3460
|
+
triggerAction: A
|
|
3453
3461
|
}
|
|
3454
3462
|
),
|
|
3455
3463
|
/* @__PURE__ */ t.jsxs(
|
|
3456
3464
|
"section",
|
|
3457
3465
|
{
|
|
3458
|
-
ref:
|
|
3459
|
-
onMouseMove:
|
|
3460
|
-
onMouseUp:
|
|
3466
|
+
ref: N,
|
|
3467
|
+
onMouseMove: oe,
|
|
3468
|
+
onMouseUp: ae,
|
|
3461
3469
|
className: "files-container",
|
|
3462
3470
|
children: [
|
|
3463
|
-
/* @__PURE__ */ t.jsxs("div", { className: "navigation-pane", style: { width:
|
|
3464
|
-
/* @__PURE__ */ t.jsx(
|
|
3471
|
+
/* @__PURE__ */ t.jsxs("div", { className: "navigation-pane", style: { width: k.col1 + "%" }, children: [
|
|
3472
|
+
/* @__PURE__ */ t.jsx(Or, {}),
|
|
3465
3473
|
/* @__PURE__ */ t.jsx(
|
|
3466
3474
|
"div",
|
|
3467
3475
|
{
|
|
3468
|
-
className: `sidebar-resize ${
|
|
3469
|
-
onMouseDown:
|
|
3476
|
+
className: `sidebar-resize ${X ? "sidebar-dragging" : ""}`,
|
|
3477
|
+
onMouseDown: Q
|
|
3470
3478
|
}
|
|
3471
3479
|
)
|
|
3472
3480
|
] }),
|
|
3473
|
-
/* @__PURE__ */ t.jsxs("div", { className: "folders-preview", style: { width:
|
|
3474
|
-
/* @__PURE__ */ t.jsx(
|
|
3481
|
+
/* @__PURE__ */ t.jsxs("div", { className: "folders-preview", style: { width: k.col2 + "%" }, children: [
|
|
3482
|
+
/* @__PURE__ */ t.jsx(kr, {}),
|
|
3475
3483
|
/* @__PURE__ */ t.jsx(
|
|
3476
|
-
|
|
3484
|
+
Ir,
|
|
3477
3485
|
{
|
|
3478
3486
|
onCreateFolder: s,
|
|
3479
|
-
onRename:
|
|
3480
|
-
onFileOpen:
|
|
3481
|
-
onRefresh:
|
|
3482
|
-
enableFilePreview:
|
|
3483
|
-
triggerAction:
|
|
3487
|
+
onRename: p,
|
|
3488
|
+
onFileOpen: M,
|
|
3489
|
+
onRefresh: S,
|
|
3490
|
+
enableFilePreview: C,
|
|
3491
|
+
triggerAction: A
|
|
3484
3492
|
}
|
|
3485
3493
|
)
|
|
3486
3494
|
] })
|
|
@@ -3488,62 +3496,64 @@ const Z = /* @__PURE__ */ un(Is), $s = (e, r, n) => {
|
|
|
3488
3496
|
}
|
|
3489
3497
|
),
|
|
3490
3498
|
/* @__PURE__ */ t.jsx(
|
|
3491
|
-
|
|
3499
|
+
Ms,
|
|
3492
3500
|
{
|
|
3493
3501
|
fileUploadConfig: r,
|
|
3494
3502
|
onFileUploading: a,
|
|
3495
|
-
onFileUploaded:
|
|
3503
|
+
onFileUploaded: i,
|
|
3496
3504
|
onDelete: h,
|
|
3497
|
-
onRefresh:
|
|
3498
|
-
maxFileSize:
|
|
3499
|
-
filePreviewPath:
|
|
3500
|
-
filePreviewComponent:
|
|
3501
|
-
acceptedFileTypes:
|
|
3502
|
-
triggerAction:
|
|
3505
|
+
onRefresh: S,
|
|
3506
|
+
maxFileSize: j,
|
|
3507
|
+
filePreviewPath: y,
|
|
3508
|
+
filePreviewComponent: x,
|
|
3509
|
+
acceptedFileTypes: b,
|
|
3510
|
+
triggerAction: A
|
|
3503
3511
|
}
|
|
3504
3512
|
)
|
|
3505
3513
|
] }) }) }) }) })
|
|
3506
3514
|
] });
|
|
3507
3515
|
};
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
files:
|
|
3511
|
-
|
|
3512
|
-
name:
|
|
3513
|
-
isDirectory:
|
|
3514
|
-
path:
|
|
3515
|
-
updatedAt:
|
|
3516
|
-
size:
|
|
3516
|
+
Hr.displayName = "FileManager";
|
|
3517
|
+
Hr.propTypes = {
|
|
3518
|
+
files: G.arrayOf(
|
|
3519
|
+
G.shape({
|
|
3520
|
+
name: G.string.isRequired,
|
|
3521
|
+
isDirectory: G.bool.isRequired,
|
|
3522
|
+
path: G.string.isRequired,
|
|
3523
|
+
updatedAt: Hs,
|
|
3524
|
+
size: G.number
|
|
3517
3525
|
})
|
|
3518
3526
|
).isRequired,
|
|
3519
|
-
fileUploadConfig:
|
|
3520
|
-
url:
|
|
3521
|
-
headers:
|
|
3527
|
+
fileUploadConfig: G.shape({
|
|
3528
|
+
url: dr,
|
|
3529
|
+
headers: G.objectOf(G.string)
|
|
3522
3530
|
}),
|
|
3523
|
-
isLoading:
|
|
3524
|
-
onCreateFolder:
|
|
3525
|
-
onFileUploading:
|
|
3526
|
-
onFileUploaded:
|
|
3527
|
-
onRename:
|
|
3528
|
-
onDelete:
|
|
3529
|
-
|
|
3530
|
-
|
|
3531
|
-
|
|
3532
|
-
|
|
3533
|
-
|
|
3534
|
-
|
|
3535
|
-
|
|
3536
|
-
|
|
3537
|
-
|
|
3538
|
-
|
|
3539
|
-
|
|
3540
|
-
|
|
3541
|
-
|
|
3542
|
-
|
|
3543
|
-
|
|
3544
|
-
|
|
3545
|
-
|
|
3531
|
+
isLoading: G.bool,
|
|
3532
|
+
onCreateFolder: G.func,
|
|
3533
|
+
onFileUploading: G.func,
|
|
3534
|
+
onFileUploaded: G.func,
|
|
3535
|
+
onRename: G.func,
|
|
3536
|
+
onDelete: G.func,
|
|
3537
|
+
onCut: G.func,
|
|
3538
|
+
onCopy: G.func,
|
|
3539
|
+
onPaste: G.func,
|
|
3540
|
+
onDownload: G.func,
|
|
3541
|
+
onLayoutChange: G.func,
|
|
3542
|
+
onRefresh: G.func,
|
|
3543
|
+
onFileOpen: G.func,
|
|
3544
|
+
onError: G.func,
|
|
3545
|
+
layout: G.oneOf(["grid", "list"]),
|
|
3546
|
+
maxFileSize: G.number,
|
|
3547
|
+
enableFilePreview: G.bool,
|
|
3548
|
+
filePreviewPath: dr,
|
|
3549
|
+
acceptedFileTypes: G.string,
|
|
3550
|
+
height: G.oneOfType([G.string, G.number]),
|
|
3551
|
+
width: G.oneOfType([G.string, G.number]),
|
|
3552
|
+
initialPath: G.string,
|
|
3553
|
+
filePreviewComponent: G.func,
|
|
3554
|
+
primaryColor: G.string,
|
|
3555
|
+
fontFamily: G.string
|
|
3546
3556
|
};
|
|
3547
3557
|
export {
|
|
3548
|
-
|
|
3558
|
+
Hr as FileManager
|
|
3549
3559
|
};
|