react-luminus-components 1.1.22 → 1.1.24

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.
Files changed (36) hide show
  1. package/dist/.vite/manifest.json +52 -61
  2. package/dist/{DataKey-B7CWQXvv.js → DataKey-C2SXqWR2.js} +1 -1
  3. package/dist/{DataKey-DVMbPWFY.cjs → DataKey-CvRVDggK.cjs} +1 -1
  4. package/dist/{SimpleTooltip-Dk1A5Tpg.js → SimpleTooltip-Bldb-kTm.js} +2 -2
  5. package/dist/{SimpleTooltip-D91sCKFo.cjs → SimpleTooltip-C_bpFbwl.cjs} +1 -1
  6. package/dist/components/Tabs/Tabs.d.ts +3 -1
  7. package/dist/components/Tabs/comps/Tab/Tab.d.ts +1 -1
  8. package/dist/contexts/luminus-components/LuminusComponentsContext.d.ts +1 -0
  9. package/dist/contexts/luminus-components/LuminusComponentsProvider.d.ts +2 -1
  10. package/dist/contexts.cjs.js +1 -1
  11. package/dist/contexts.es.js +153 -151
  12. package/dist/{hasClass-DIHyDa4e.js → hasClass-BW_ewlE1.js} +1 -1
  13. package/dist/{hasClass-DjB0wTmj.cjs → hasClass-uRfdPyYB.cjs} +1 -1
  14. package/dist/hooks/useAxios/useAxios.d.ts +1 -1
  15. package/dist/hooks.cjs.js +1 -1
  16. package/dist/hooks.es.js +4 -4
  17. package/dist/layout.cjs.js +1 -1
  18. package/dist/layout.es.js +3 -3
  19. package/dist/main.cjs.js +1 -1
  20. package/dist/main.es.js +690 -690
  21. package/dist/style.css +1 -1
  22. package/dist/textUtils-CHVVh2oi.cjs +1 -0
  23. package/dist/textUtils-DW4f3rLU.js +36 -0
  24. package/dist/useAxios-CMffjGyX.cjs +231 -0
  25. package/dist/useAxios-hDu0KL-3.js +3314 -0
  26. package/dist/{useConfirm-CrTJszXF.cjs → useConfirm-BkwWgb-h.cjs} +1 -1
  27. package/dist/{useConfirm-CyietOP-.js → useConfirm-DYu6kYED.js} +1 -1
  28. package/dist/utils.cjs.js +1 -1
  29. package/dist/utils.es.js +5 -5
  30. package/package.json +2 -1
  31. package/dist/constants-CT2hnPeO.cjs +0 -1
  32. package/dist/constants-CzNy5yO3.js +0 -7
  33. package/dist/textUtils-Bb6c2XYw.cjs +0 -1
  34. package/dist/textUtils-Bd2QCbzF.js +0 -32
  35. package/dist/useAxios-B4X7zKtj.cjs +0 -212
  36. package/dist/useAxios-CHbKHRpj.js +0 -2883
@@ -1,2883 +0,0 @@
1
- import * as N from "react";
2
- import q, { createContext as he, useEffect as lt, useCallback as ne, useState as fn, useContext as or } from "react";
3
- import { t as dn, e as pn } from "./textUtils-Bd2QCbzF.js";
4
- function hn(e) {
5
- return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
6
- }
7
- var et = { exports: {} }, ce = {};
8
- /**
9
- * @license React
10
- * react-jsx-runtime.production.min.js
11
- *
12
- * Copyright (c) Facebook, Inc. and its affiliates.
13
- *
14
- * This source code is licensed under the MIT license found in the
15
- * LICENSE file in the root directory of this source tree.
16
- */
17
- var Bt;
18
- function mn() {
19
- if (Bt)
20
- return ce;
21
- Bt = 1;
22
- var e = q, t = Symbol.for("react.element"), r = Symbol.for("react.fragment"), n = Object.prototype.hasOwnProperty, s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, o = { key: !0, ref: !0, __self: !0, __source: !0 };
23
- function i(c, l, h) {
24
- var p, f = {}, v = null, R = null;
25
- h !== void 0 && (v = "" + h), l.key !== void 0 && (v = "" + l.key), l.ref !== void 0 && (R = l.ref);
26
- for (p in l)
27
- n.call(l, p) && !o.hasOwnProperty(p) && (f[p] = l[p]);
28
- if (c && c.defaultProps)
29
- for (p in l = c.defaultProps, l)
30
- f[p] === void 0 && (f[p] = l[p]);
31
- return { $$typeof: t, type: c, key: v, ref: R, props: f, _owner: s.current };
32
- }
33
- return ce.Fragment = r, ce.jsx = i, ce.jsxs = i, ce;
34
- }
35
- var le = {};
36
- /**
37
- * @license React
38
- * react-jsx-runtime.development.js
39
- *
40
- * Copyright (c) Facebook, Inc. and its affiliates.
41
- *
42
- * This source code is licensed under the MIT license found in the
43
- * LICENSE file in the root directory of this source tree.
44
- */
45
- var It;
46
- function gn() {
47
- return It || (It = 1, process.env.NODE_ENV !== "production" && function() {
48
- var e = q, t = Symbol.for("react.element"), r = Symbol.for("react.portal"), n = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), o = Symbol.for("react.profiler"), i = Symbol.for("react.provider"), c = Symbol.for("react.context"), l = Symbol.for("react.forward_ref"), h = Symbol.for("react.suspense"), p = Symbol.for("react.suspense_list"), f = Symbol.for("react.memo"), v = Symbol.for("react.lazy"), R = Symbol.for("react.offscreen"), g = Symbol.iterator, y = "@@iterator";
49
- function j(a) {
50
- if (a === null || typeof a != "object")
51
- return null;
52
- var d = g && a[g] || a[y];
53
- return typeof d == "function" ? d : null;
54
- }
55
- var _ = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
56
- function T(a) {
57
- {
58
- for (var d = arguments.length, m = new Array(d > 1 ? d - 1 : 0), b = 1; b < d; b++)
59
- m[b - 1] = arguments[b];
60
- U("error", a, m);
61
- }
62
- }
63
- function U(a, d, m) {
64
- {
65
- var b = _.ReactDebugCurrentFrame, O = b.getStackAddendum();
66
- O !== "" && (d += "%s", m = m.concat([O]));
67
- var S = m.map(function(E) {
68
- return String(E);
69
- });
70
- S.unshift("Warning: " + d), Function.prototype.apply.call(console[a], console, S);
71
- }
72
- }
73
- var Ie = !1, kr = !1, Dr = !1, Fr = !1, Mr = !1, gt;
74
- gt = Symbol.for("react.module.reference");
75
- function Lr(a) {
76
- return !!(typeof a == "string" || typeof a == "function" || a === n || a === o || Mr || a === s || a === h || a === p || Fr || a === R || Ie || kr || Dr || typeof a == "object" && a !== null && (a.$$typeof === v || a.$$typeof === f || a.$$typeof === i || a.$$typeof === c || a.$$typeof === l || // This needs to include all possible module reference object
77
- // types supported by any Flight configuration anywhere since
78
- // we don't know which Flight build this will end up being used
79
- // with.
80
- a.$$typeof === gt || a.getModuleId !== void 0));
81
- }
82
- function zr(a, d, m) {
83
- var b = a.displayName;
84
- if (b)
85
- return b;
86
- var O = d.displayName || d.name || "";
87
- return O !== "" ? m + "(" + O + ")" : m;
88
- }
89
- function yt(a) {
90
- return a.displayName || "Context";
91
- }
92
- function H(a) {
93
- if (a == null)
94
- return null;
95
- if (typeof a.tag == "number" && T("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof a == "function")
96
- return a.displayName || a.name || null;
97
- if (typeof a == "string")
98
- return a;
99
- switch (a) {
100
- case n:
101
- return "Fragment";
102
- case r:
103
- return "Portal";
104
- case o:
105
- return "Profiler";
106
- case s:
107
- return "StrictMode";
108
- case h:
109
- return "Suspense";
110
- case p:
111
- return "SuspenseList";
112
- }
113
- if (typeof a == "object")
114
- switch (a.$$typeof) {
115
- case c:
116
- var d = a;
117
- return yt(d) + ".Consumer";
118
- case i:
119
- var m = a;
120
- return yt(m._context) + ".Provider";
121
- case l:
122
- return zr(a, a.render, "ForwardRef");
123
- case f:
124
- var b = a.displayName || null;
125
- return b !== null ? b : H(a.type) || "Memo";
126
- case v: {
127
- var O = a, S = O._payload, E = O._init;
128
- try {
129
- return H(E(S));
130
- } catch {
131
- return null;
132
- }
133
- }
134
- }
135
- return null;
136
- }
137
- var Q = Object.assign, ie = 0, bt, vt, wt, Et, xt, Ot, Rt;
138
- function St() {
139
- }
140
- St.__reactDisabledLog = !0;
141
- function Ur() {
142
- {
143
- if (ie === 0) {
144
- bt = console.log, vt = console.info, wt = console.warn, Et = console.error, xt = console.group, Ot = console.groupCollapsed, Rt = console.groupEnd;
145
- var a = {
146
- configurable: !0,
147
- enumerable: !0,
148
- value: St,
149
- writable: !0
150
- };
151
- Object.defineProperties(console, {
152
- info: a,
153
- log: a,
154
- warn: a,
155
- error: a,
156
- group: a,
157
- groupCollapsed: a,
158
- groupEnd: a
159
- });
160
- }
161
- ie++;
162
- }
163
- }
164
- function Br() {
165
- {
166
- if (ie--, ie === 0) {
167
- var a = {
168
- configurable: !0,
169
- enumerable: !0,
170
- writable: !0
171
- };
172
- Object.defineProperties(console, {
173
- log: Q({}, a, {
174
- value: bt
175
- }),
176
- info: Q({}, a, {
177
- value: vt
178
- }),
179
- warn: Q({}, a, {
180
- value: wt
181
- }),
182
- error: Q({}, a, {
183
- value: Et
184
- }),
185
- group: Q({}, a, {
186
- value: xt
187
- }),
188
- groupCollapsed: Q({}, a, {
189
- value: Ot
190
- }),
191
- groupEnd: Q({}, a, {
192
- value: Rt
193
- })
194
- });
195
- }
196
- ie < 0 && T("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
197
- }
198
- }
199
- var He = _.ReactCurrentDispatcher, $e;
200
- function be(a, d, m) {
201
- {
202
- if ($e === void 0)
203
- try {
204
- throw Error();
205
- } catch (O) {
206
- var b = O.stack.trim().match(/\n( *(at )?)/);
207
- $e = b && b[1] || "";
208
- }
209
- return `
210
- ` + $e + a;
211
- }
212
- }
213
- var Ve = !1, ve;
214
- {
215
- var Ir = typeof WeakMap == "function" ? WeakMap : Map;
216
- ve = new Ir();
217
- }
218
- function Tt(a, d) {
219
- if (!a || Ve)
220
- return "";
221
- {
222
- var m = ve.get(a);
223
- if (m !== void 0)
224
- return m;
225
- }
226
- var b;
227
- Ve = !0;
228
- var O = Error.prepareStackTrace;
229
- Error.prepareStackTrace = void 0;
230
- var S;
231
- S = He.current, He.current = null, Ur();
232
- try {
233
- if (d) {
234
- var E = function() {
235
- throw Error();
236
- };
237
- if (Object.defineProperty(E.prototype, "props", {
238
- set: function() {
239
- throw Error();
240
- }
241
- }), typeof Reflect == "object" && Reflect.construct) {
242
- try {
243
- Reflect.construct(E, []);
244
- } catch ($) {
245
- b = $;
246
- }
247
- Reflect.construct(a, [], E);
248
- } else {
249
- try {
250
- E.call();
251
- } catch ($) {
252
- b = $;
253
- }
254
- a.call(E.prototype);
255
- }
256
- } else {
257
- try {
258
- throw Error();
259
- } catch ($) {
260
- b = $;
261
- }
262
- a();
263
- }
264
- } catch ($) {
265
- if ($ && b && typeof $.stack == "string") {
266
- for (var w = $.stack.split(`
267
- `), F = b.stack.split(`
268
- `), C = w.length - 1, A = F.length - 1; C >= 1 && A >= 0 && w[C] !== F[A]; )
269
- A--;
270
- for (; C >= 1 && A >= 0; C--, A--)
271
- if (w[C] !== F[A]) {
272
- if (C !== 1 || A !== 1)
273
- do
274
- if (C--, A--, A < 0 || w[C] !== F[A]) {
275
- var L = `
276
- ` + w[C].replace(" at new ", " at ");
277
- return a.displayName && L.includes("<anonymous>") && (L = L.replace("<anonymous>", a.displayName)), typeof a == "function" && ve.set(a, L), L;
278
- }
279
- while (C >= 1 && A >= 0);
280
- break;
281
- }
282
- }
283
- } finally {
284
- Ve = !1, He.current = S, Br(), Error.prepareStackTrace = O;
285
- }
286
- var te = a ? a.displayName || a.name : "", Ut = te ? be(te) : "";
287
- return typeof a == "function" && ve.set(a, Ut), Ut;
288
- }
289
- function Hr(a, d, m) {
290
- return Tt(a, !1);
291
- }
292
- function $r(a) {
293
- var d = a.prototype;
294
- return !!(d && d.isReactComponent);
295
- }
296
- function we(a, d, m) {
297
- if (a == null)
298
- return "";
299
- if (typeof a == "function")
300
- return Tt(a, $r(a));
301
- if (typeof a == "string")
302
- return be(a);
303
- switch (a) {
304
- case h:
305
- return be("Suspense");
306
- case p:
307
- return be("SuspenseList");
308
- }
309
- if (typeof a == "object")
310
- switch (a.$$typeof) {
311
- case l:
312
- return Hr(a.render);
313
- case f:
314
- return we(a.type, d, m);
315
- case v: {
316
- var b = a, O = b._payload, S = b._init;
317
- try {
318
- return we(S(O), d, m);
319
- } catch {
320
- }
321
- }
322
- }
323
- return "";
324
- }
325
- var Ee = Object.prototype.hasOwnProperty, _t = {}, Pt = _.ReactDebugCurrentFrame;
326
- function xe(a) {
327
- if (a) {
328
- var d = a._owner, m = we(a.type, a._source, d ? d.type : null);
329
- Pt.setExtraStackFrame(m);
330
- } else
331
- Pt.setExtraStackFrame(null);
332
- }
333
- function Vr(a, d, m, b, O) {
334
- {
335
- var S = Function.call.bind(Ee);
336
- for (var E in a)
337
- if (S(a, E)) {
338
- var w = void 0;
339
- try {
340
- if (typeof a[E] != "function") {
341
- var F = Error((b || "React class") + ": " + m + " type `" + E + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[E] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
342
- throw F.name = "Invariant Violation", F;
343
- }
344
- w = a[E](d, E, b, m, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
345
- } catch (C) {
346
- w = C;
347
- }
348
- w && !(w instanceof Error) && (xe(O), T("%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", m, E, typeof w), xe(null)), w instanceof Error && !(w.message in _t) && (_t[w.message] = !0, xe(O), T("Failed %s type: %s", m, w.message), xe(null));
349
- }
350
- }
351
- }
352
- var qr = Array.isArray;
353
- function qe(a) {
354
- return qr(a);
355
- }
356
- function Wr(a) {
357
- {
358
- var d = typeof Symbol == "function" && Symbol.toStringTag, m = d && a[Symbol.toStringTag] || a.constructor.name || "Object";
359
- return m;
360
- }
361
- }
362
- function Jr(a) {
363
- try {
364
- return Ct(a), !1;
365
- } catch {
366
- return !0;
367
- }
368
- }
369
- function Ct(a) {
370
- return "" + a;
371
- }
372
- function At(a) {
373
- if (Jr(a))
374
- return T("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Wr(a)), Ct(a);
375
- }
376
- var ae = _.ReactCurrentOwner, Yr = {
377
- key: !0,
378
- ref: !0,
379
- __self: !0,
380
- __source: !0
381
- }, jt, Nt, We;
382
- We = {};
383
- function Kr(a) {
384
- if (Ee.call(a, "ref")) {
385
- var d = Object.getOwnPropertyDescriptor(a, "ref").get;
386
- if (d && d.isReactWarning)
387
- return !1;
388
- }
389
- return a.ref !== void 0;
390
- }
391
- function Gr(a) {
392
- if (Ee.call(a, "key")) {
393
- var d = Object.getOwnPropertyDescriptor(a, "key").get;
394
- if (d && d.isReactWarning)
395
- return !1;
396
- }
397
- return a.key !== void 0;
398
- }
399
- function Xr(a, d) {
400
- if (typeof a.ref == "string" && ae.current && d && ae.current.stateNode !== d) {
401
- var m = H(ae.current.type);
402
- We[m] || (T('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref', H(ae.current.type), a.ref), We[m] = !0);
403
- }
404
- }
405
- function Qr(a, d) {
406
- {
407
- var m = function() {
408
- jt || (jt = !0, T("%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)", d));
409
- };
410
- m.isReactWarning = !0, Object.defineProperty(a, "key", {
411
- get: m,
412
- configurable: !0
413
- });
414
- }
415
- }
416
- function Zr(a, d) {
417
- {
418
- var m = function() {
419
- Nt || (Nt = !0, T("%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)", d));
420
- };
421
- m.isReactWarning = !0, Object.defineProperty(a, "ref", {
422
- get: m,
423
- configurable: !0
424
- });
425
- }
426
- }
427
- var en = function(a, d, m, b, O, S, E) {
428
- var w = {
429
- // This tag allows us to uniquely identify this as a React Element
430
- $$typeof: t,
431
- // Built-in properties that belong on the element
432
- type: a,
433
- key: d,
434
- ref: m,
435
- props: E,
436
- // Record the component responsible for creating this element.
437
- _owner: S
438
- };
439
- return w._store = {}, Object.defineProperty(w._store, "validated", {
440
- configurable: !1,
441
- enumerable: !1,
442
- writable: !0,
443
- value: !1
444
- }), Object.defineProperty(w, "_self", {
445
- configurable: !1,
446
- enumerable: !1,
447
- writable: !1,
448
- value: b
449
- }), Object.defineProperty(w, "_source", {
450
- configurable: !1,
451
- enumerable: !1,
452
- writable: !1,
453
- value: O
454
- }), Object.freeze && (Object.freeze(w.props), Object.freeze(w)), w;
455
- };
456
- function tn(a, d, m, b, O) {
457
- {
458
- var S, E = {}, w = null, F = null;
459
- m !== void 0 && (At(m), w = "" + m), Gr(d) && (At(d.key), w = "" + d.key), Kr(d) && (F = d.ref, Xr(d, O));
460
- for (S in d)
461
- Ee.call(d, S) && !Yr.hasOwnProperty(S) && (E[S] = d[S]);
462
- if (a && a.defaultProps) {
463
- var C = a.defaultProps;
464
- for (S in C)
465
- E[S] === void 0 && (E[S] = C[S]);
466
- }
467
- if (w || F) {
468
- var A = typeof a == "function" ? a.displayName || a.name || "Unknown" : a;
469
- w && Qr(E, A), F && Zr(E, A);
470
- }
471
- return en(a, w, F, O, b, ae.current, E);
472
- }
473
- }
474
- var Je = _.ReactCurrentOwner, kt = _.ReactDebugCurrentFrame;
475
- function ee(a) {
476
- if (a) {
477
- var d = a._owner, m = we(a.type, a._source, d ? d.type : null);
478
- kt.setExtraStackFrame(m);
479
- } else
480
- kt.setExtraStackFrame(null);
481
- }
482
- var Ye;
483
- Ye = !1;
484
- function Ke(a) {
485
- return typeof a == "object" && a !== null && a.$$typeof === t;
486
- }
487
- function Dt() {
488
- {
489
- if (Je.current) {
490
- var a = H(Je.current.type);
491
- if (a)
492
- return `
493
-
494
- Check the render method of \`` + a + "`.";
495
- }
496
- return "";
497
- }
498
- }
499
- function rn(a) {
500
- {
501
- if (a !== void 0) {
502
- var d = a.fileName.replace(/^.*[\\\/]/, ""), m = a.lineNumber;
503
- return `
504
-
505
- Check your code at ` + d + ":" + m + ".";
506
- }
507
- return "";
508
- }
509
- }
510
- var Ft = {};
511
- function nn(a) {
512
- {
513
- var d = Dt();
514
- if (!d) {
515
- var m = typeof a == "string" ? a : a.displayName || a.name;
516
- m && (d = `
517
-
518
- Check the top-level render call using <` + m + ">.");
519
- }
520
- return d;
521
- }
522
- }
523
- function Mt(a, d) {
524
- {
525
- if (!a._store || a._store.validated || a.key != null)
526
- return;
527
- a._store.validated = !0;
528
- var m = nn(d);
529
- if (Ft[m])
530
- return;
531
- Ft[m] = !0;
532
- var b = "";
533
- a && a._owner && a._owner !== Je.current && (b = " It was passed a child from " + H(a._owner.type) + "."), ee(a), T('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', m, b), ee(null);
534
- }
535
- }
536
- function Lt(a, d) {
537
- {
538
- if (typeof a != "object")
539
- return;
540
- if (qe(a))
541
- for (var m = 0; m < a.length; m++) {
542
- var b = a[m];
543
- Ke(b) && Mt(b, d);
544
- }
545
- else if (Ke(a))
546
- a._store && (a._store.validated = !0);
547
- else if (a) {
548
- var O = j(a);
549
- if (typeof O == "function" && O !== a.entries)
550
- for (var S = O.call(a), E; !(E = S.next()).done; )
551
- Ke(E.value) && Mt(E.value, d);
552
- }
553
- }
554
- }
555
- function on(a) {
556
- {
557
- var d = a.type;
558
- if (d == null || typeof d == "string")
559
- return;
560
- var m;
561
- if (typeof d == "function")
562
- m = d.propTypes;
563
- else if (typeof d == "object" && (d.$$typeof === l || // Note: Memo only checks outer props here.
564
- // Inner props are checked in the reconciler.
565
- d.$$typeof === f))
566
- m = d.propTypes;
567
- else
568
- return;
569
- if (m) {
570
- var b = H(d);
571
- Vr(m, a.props, "prop", b, a);
572
- } else if (d.PropTypes !== void 0 && !Ye) {
573
- Ye = !0;
574
- var O = H(d);
575
- T("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", O || "Unknown");
576
- }
577
- typeof d.getDefaultProps == "function" && !d.getDefaultProps.isReactClassApproved && T("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
578
- }
579
- }
580
- function sn(a) {
581
- {
582
- for (var d = Object.keys(a.props), m = 0; m < d.length; m++) {
583
- var b = d[m];
584
- if (b !== "children" && b !== "key") {
585
- ee(a), T("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", b), ee(null);
586
- break;
587
- }
588
- }
589
- a.ref !== null && (ee(a), T("Invalid attribute `ref` supplied to `React.Fragment`."), ee(null));
590
- }
591
- }
592
- function zt(a, d, m, b, O, S) {
593
- {
594
- var E = Lr(a);
595
- if (!E) {
596
- var w = "";
597
- (a === void 0 || typeof a == "object" && a !== null && Object.keys(a).length === 0) && (w += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
598
- var F = rn(O);
599
- F ? w += F : w += Dt();
600
- var C;
601
- a === null ? C = "null" : qe(a) ? C = "array" : a !== void 0 && a.$$typeof === t ? (C = "<" + (H(a.type) || "Unknown") + " />", w = " Did you accidentally export a JSX literal instead of a component?") : C = typeof a, T("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", C, w);
602
- }
603
- var A = tn(a, d, m, O, S);
604
- if (A == null)
605
- return A;
606
- if (E) {
607
- var L = d.children;
608
- if (L !== void 0)
609
- if (b)
610
- if (qe(L)) {
611
- for (var te = 0; te < L.length; te++)
612
- Lt(L[te], a);
613
- Object.freeze && Object.freeze(L);
614
- } else
615
- T("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
616
- else
617
- Lt(L, a);
618
- }
619
- return a === n ? sn(A) : on(A), A;
620
- }
621
- }
622
- function an(a, d, m) {
623
- return zt(a, d, m, !0);
624
- }
625
- function cn(a, d, m) {
626
- return zt(a, d, m, !1);
627
- }
628
- var ln = cn, un = an;
629
- le.Fragment = n, le.jsx = ln, le.jsxs = un;
630
- }()), le;
631
- }
632
- process.env.NODE_ENV === "production" ? et.exports = mn() : et.exports = gn();
633
- var Y = et.exports, sr = { exports: {} };
634
- /*!
635
- Copyright (c) 2018 Jed Watson.
636
- Licensed under the MIT License (MIT), see
637
- http://jedwatson.github.io/classnames
638
- */
639
- (function(e) {
640
- (function() {
641
- var t = {}.hasOwnProperty;
642
- function r() {
643
- for (var o = "", i = 0; i < arguments.length; i++) {
644
- var c = arguments[i];
645
- c && (o = s(o, n(c)));
646
- }
647
- return o;
648
- }
649
- function n(o) {
650
- if (typeof o == "string" || typeof o == "number")
651
- return o;
652
- if (typeof o != "object")
653
- return "";
654
- if (Array.isArray(o))
655
- return r.apply(null, o);
656
- if (o.toString !== Object.prototype.toString && !o.toString.toString().includes("[native code]"))
657
- return o.toString();
658
- var i = "";
659
- for (var c in o)
660
- t.call(o, c) && o[c] && (i = s(i, c));
661
- return i;
662
- }
663
- function s(o, i) {
664
- return i ? o ? o + " " + i : o + i : o;
665
- }
666
- e.exports ? (r.default = r, e.exports = r) : window.classNames = r;
667
- })();
668
- })(sr);
669
- var yn = sr.exports;
670
- const ue = /* @__PURE__ */ hn(yn);
671
- var ir = {
672
- color: void 0,
673
- size: void 0,
674
- className: void 0,
675
- style: void 0,
676
- attr: void 0
677
- }, Ht = q.createContext && /* @__PURE__ */ q.createContext(ir), bn = ["attr", "size", "title"];
678
- function vn(e, t) {
679
- if (e == null)
680
- return {};
681
- var r = wn(e, t), n, s;
682
- if (Object.getOwnPropertySymbols) {
683
- var o = Object.getOwnPropertySymbols(e);
684
- for (s = 0; s < o.length; s++)
685
- n = o[s], !(t.indexOf(n) >= 0) && Object.prototype.propertyIsEnumerable.call(e, n) && (r[n] = e[n]);
686
- }
687
- return r;
688
- }
689
- function wn(e, t) {
690
- if (e == null)
691
- return {};
692
- var r = {}, n = Object.keys(e), s, o;
693
- for (o = 0; o < n.length; o++)
694
- s = n[o], !(t.indexOf(s) >= 0) && (r[s] = e[s]);
695
- return r;
696
- }
697
- function je() {
698
- return je = Object.assign ? Object.assign.bind() : function(e) {
699
- for (var t = 1; t < arguments.length; t++) {
700
- var r = arguments[t];
701
- for (var n in r)
702
- Object.prototype.hasOwnProperty.call(r, n) && (e[n] = r[n]);
703
- }
704
- return e;
705
- }, je.apply(this, arguments);
706
- }
707
- function $t(e, t) {
708
- var r = Object.keys(e);
709
- if (Object.getOwnPropertySymbols) {
710
- var n = Object.getOwnPropertySymbols(e);
711
- t && (n = n.filter(function(s) {
712
- return Object.getOwnPropertyDescriptor(e, s).enumerable;
713
- })), r.push.apply(r, n);
714
- }
715
- return r;
716
- }
717
- function Ne(e) {
718
- for (var t = 1; t < arguments.length; t++) {
719
- var r = arguments[t] != null ? arguments[t] : {};
720
- t % 2 ? $t(Object(r), !0).forEach(function(n) {
721
- En(e, n, r[n]);
722
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : $t(Object(r)).forEach(function(n) {
723
- Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
724
- });
725
- }
726
- return e;
727
- }
728
- function En(e, t, r) {
729
- return t = xn(t), t in e ? Object.defineProperty(e, t, { value: r, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = r, e;
730
- }
731
- function xn(e) {
732
- var t = On(e, "string");
733
- return typeof t == "symbol" ? t : String(t);
734
- }
735
- function On(e, t) {
736
- if (typeof e != "object" || e === null)
737
- return e;
738
- var r = e[Symbol.toPrimitive];
739
- if (r !== void 0) {
740
- var n = r.call(e, t || "default");
741
- if (typeof n != "object")
742
- return n;
743
- throw new TypeError("@@toPrimitive must return a primitive value.");
744
- }
745
- return (t === "string" ? String : Number)(e);
746
- }
747
- function ar(e) {
748
- return e && e.map((t, r) => /* @__PURE__ */ q.createElement(t.tag, Ne({
749
- key: r
750
- }, t.attr), ar(t.child)));
751
- }
752
- function k(e) {
753
- return (t) => /* @__PURE__ */ q.createElement(Rn, je({
754
- attr: Ne({}, e.attr)
755
- }, t), ar(e.child));
756
- }
757
- function Rn(e) {
758
- var t = (r) => {
759
- var {
760
- attr: n,
761
- size: s,
762
- title: o
763
- } = e, i = vn(e, bn), c = s || r.size || "1em", l;
764
- return r.className && (l = r.className), e.className && (l = (l ? l + " " : "") + e.className), /* @__PURE__ */ q.createElement("svg", je({
765
- stroke: "currentColor",
766
- fill: "currentColor",
767
- strokeWidth: "0"
768
- }, r.attr, n, i, {
769
- className: l,
770
- style: Ne(Ne({
771
- color: e.color || r.color
772
- }, r.style), e.style),
773
- height: c,
774
- width: c,
775
- xmlns: "http://www.w3.org/2000/svg"
776
- }), o && /* @__PURE__ */ q.createElement("title", null, o), e.children);
777
- };
778
- return Ht !== void 0 ? /* @__PURE__ */ q.createElement(Ht.Consumer, null, (r) => t(r)) : t(ir);
779
- }
780
- function Ys(e) {
781
- return k({ 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);
782
- }
783
- function Ks(e) {
784
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z" }, child: [] }] })(e);
785
- }
786
- function Gs(e) {
787
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M6 6v2h8.59L5 17.59 6.41 19 16 9.41V18h2V6z" }, child: [] }] })(e);
788
- }
789
- function Sn(e) {
790
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M20 8h-2.81a5.985 5.985 0 0 0-1.82-1.96L17 4.41 15.59 3l-2.17 2.17C12.96 5.06 12.49 5 12 5s-.96.06-1.41.17L8.41 3 7 4.41l1.62 1.63C7.88 6.55 7.26 7.22 6.81 8H4v2h2.09c-.05.33-.09.66-.09 1v1H4v2h2v1c0 .34.04.67.09 1H4v2h2.81c1.04 1.79 2.97 3 5.19 3s4.15-1.21 5.19-3H20v-2h-2.09c.05-.33.09-.66.09-1v-1h2v-2h-2v-1c0-.34-.04-.67-.09-1H20V8zm-4 4v3c0 .22-.03.47-.07.7l-.1.65-.37.65c-.72 1.24-2.04 2-3.46 2s-2.74-.77-3.46-2l-.37-.64-.1-.65A4.27 4.27 0 0 1 8 15v-4c0-.23.03-.48.07-.7l.1-.65.37-.65c.3-.52.72-.97 1.21-1.31l.57-.39.74-.18a3.787 3.787 0 0 1 1.89 0l.68.16.61.42c.5.34.91.78 1.21 1.31l.38.65.1.65c.04.22.07.47.07.69v1zm-6 2h4v2h-4zm0-4h4v2h-4z" }, child: [] }] })(e);
791
- }
792
- function Xs(e) {
793
- return k({ 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);
794
- }
795
- function Qs(e) {
796
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M4 20h16v2H4zM4 2h16v2H4zM9.41 13.59 8 15l4 4 4-4-1.41-1.41L13 15.17V8.83l1.59 1.58L16 9l-4-4-4 4 1.41 1.41L11 8.83v6.34z" }, child: [] }] })(e);
797
- }
798
- function Tn(e) {
799
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M11.07 12.85c.77-1.39 2.25-2.21 3.11-3.44.91-1.29.4-3.7-2.18-3.7-1.69 0-2.52 1.28-2.87 2.34L6.54 6.96C7.25 4.83 9.18 3 11.99 3c2.35 0 3.96 1.07 4.78 2.41.7 1.15 1.11 3.3.03 4.9-1.2 1.77-2.35 2.31-2.97 3.45-.25.46-.35.76-.35 2.24h-2.89c-.01-.78-.13-2.05.48-3.15zM14 20c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2z" }, child: [] }] })(e);
800
- }
801
- function _n(e) {
802
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" }, child: [] }, { tag: "path", attr: { d: "M20 4H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h16c1.1 0 2-.9 2-2V6a2 2 0 0 0-2-2zm0 14H4V8h16v10zm-2-1h-6v-2h6v2zM7.5 17l-1.41-1.41L8.67 13l-2.59-2.59L7.5 9l4 4-4 4z" }, child: [] }] })(e);
803
- }
804
- function Pn(e) {
805
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z" }, child: [] }] })(e);
806
- }
807
- function Zs(e) {
808
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z" }, child: [] }] })(e);
809
- }
810
- function ei(e) {
811
- return k({ 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);
812
- }
813
- function ti(e) {
814
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M15.41 16.59 10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z" }, child: [] }] })(e);
815
- }
816
- function ri(e) {
817
- return k({ 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);
818
- }
819
- function ni(e) {
820
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "m14.06 9.02.92.92L5.92 19H5v-.92l9.06-9.06M17.66 3c-.25 0-.51.1-.7.29l-1.83 1.83 3.75 3.75 1.83-1.83a.996.996 0 0 0 0-1.41l-2.34-2.34c-.2-.2-.45-.29-.71-.29zm-3.6 3.19L3 17.25V21h3.75L17.81 9.94l-3.75-3.75z" }, child: [] }] })(e);
821
- }
822
- function Cn(e) {
823
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41L9 16.17z" }, child: [] }] })(e);
824
- }
825
- function oi(e) {
826
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, child: [] }, { tag: "path", attr: { d: "M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6-6-6z" }, child: [] }] })(e);
827
- }
828
- function An(e) {
829
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, 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 12 19 6.41z" }, child: [] }] })(e);
830
- }
831
- function si(e) {
832
- return k({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0V0z" }, 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);
833
- }
834
- const cr = he({
835
- axiosInstance: {},
836
- LinkComponent: {},
837
- language: "",
838
- axiosTexts: {},
839
- confirmTexts: {},
840
- formValidationTexts: {},
841
- homeDashboardTexts: {},
842
- formSubmitTexts: {}
843
- });
844
- let jn = { data: "" }, Nn = (e) => typeof window == "object" ? ((e ? e.querySelector("#_goober") : window._goober) || Object.assign((e || document.head).appendChild(document.createElement("style")), { innerHTML: " ", id: "_goober" })).firstChild : e || jn, kn = /(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g, Dn = /\/\*[^]*?\*\/| +/g, Vt = /\n+/g, G = (e, t) => {
845
- let r = "", n = "", s = "";
846
- for (let o in e) {
847
- let i = e[o];
848
- o[0] == "@" ? o[1] == "i" ? r = o + " " + i + ";" : n += o[1] == "f" ? G(i, o) : o + "{" + G(i, o[1] == "k" ? "" : t) + "}" : typeof i == "object" ? n += G(i, t ? t.replace(/([^,])+/g, (c) => o.replace(/(^:.*)|([^,])+/g, (l) => /&/.test(l) ? l.replace(/&/g, c) : c ? c + " " + l : l)) : o) : i != null && (o = /^--/.test(o) ? o : o.replace(/[A-Z]/g, "-$&").toLowerCase(), s += G.p ? G.p(o, i) : o + ":" + i + ";");
849
- }
850
- return r + (t && s ? t + "{" + s + "}" : s) + n;
851
- }, V = {}, lr = (e) => {
852
- if (typeof e == "object") {
853
- let t = "";
854
- for (let r in e)
855
- t += r + lr(e[r]);
856
- return t;
857
- }
858
- return e;
859
- }, Fn = (e, t, r, n, s) => {
860
- let o = lr(e), i = V[o] || (V[o] = ((l) => {
861
- let h = 0, p = 11;
862
- for (; h < l.length; )
863
- p = 101 * p + l.charCodeAt(h++) >>> 0;
864
- return "go" + p;
865
- })(o));
866
- if (!V[i]) {
867
- let l = o !== e ? e : ((h) => {
868
- let p, f, v = [{}];
869
- for (; p = kn.exec(h.replace(Dn, "")); )
870
- p[4] ? v.shift() : p[3] ? (f = p[3].replace(Vt, " ").trim(), v.unshift(v[0][f] = v[0][f] || {})) : v[0][p[1]] = p[2].replace(Vt, " ").trim();
871
- return v[0];
872
- })(e);
873
- V[i] = G(s ? { ["@keyframes " + i]: l } : l, r ? "" : "." + i);
874
- }
875
- let c = r && V.g ? V.g : null;
876
- return r && (V.g = V[i]), ((l, h, p, f) => {
877
- f ? h.data = h.data.replace(f, l) : h.data.indexOf(l) === -1 && (h.data = p ? l + h.data : h.data + l);
878
- })(V[i], t, n, c), i;
879
- }, Mn = (e, t, r) => e.reduce((n, s, o) => {
880
- let i = t[o];
881
- if (i && i.call) {
882
- let c = i(r), l = c && c.props && c.props.className || /^go/.test(c) && c;
883
- i = l ? "." + l : c && typeof c == "object" ? c.props ? "" : G(c, "") : c === !1 ? "" : c;
884
- }
885
- return n + s + (i ?? "");
886
- }, "");
887
- function Fe(e) {
888
- let t = this || {}, r = e.call ? e(t.p) : e;
889
- return Fn(r.unshift ? r.raw ? Mn(r, [].slice.call(arguments, 1), t.p) : r.reduce((n, s) => Object.assign(n, s && s.call ? s(t.p) : s), {}) : r, Nn(t.target), t.g, t.o, t.k);
890
- }
891
- let ur, tt, rt;
892
- Fe.bind({ g: 1 });
893
- let J = Fe.bind({ k: 1 });
894
- function Ln(e, t, r, n) {
895
- G.p = t, ur = e, tt = r, rt = n;
896
- }
897
- function X(e, t) {
898
- let r = this || {};
899
- return function() {
900
- let n = arguments;
901
- function s(o, i) {
902
- let c = Object.assign({}, o), l = c.className || s.className;
903
- r.p = Object.assign({ theme: tt && tt() }, c), r.o = / *go\d+/.test(l), c.className = Fe.apply(r, n) + (l ? " " + l : ""), t && (c.ref = i);
904
- let h = e;
905
- return e[0] && (h = c.as || e, delete c.as), rt && h[0] && rt(c), ur(h, c);
906
- }
907
- return t ? t(s) : s;
908
- };
909
- }
910
- var zn = (e) => typeof e == "function", ke = (e, t) => zn(e) ? e(t) : e, Un = /* @__PURE__ */ (() => {
911
- let e = 0;
912
- return () => (++e).toString();
913
- })(), fr = /* @__PURE__ */ (() => {
914
- let e;
915
- return () => {
916
- if (e === void 0 && typeof window < "u") {
917
- let t = matchMedia("(prefers-reduced-motion: reduce)");
918
- e = !t || t.matches;
919
- }
920
- return e;
921
- };
922
- })(), Bn = 20, Se = /* @__PURE__ */ new Map(), In = 1e3, qt = (e) => {
923
- if (Se.has(e))
924
- return;
925
- let t = setTimeout(() => {
926
- Se.delete(e), Z({ type: 4, toastId: e });
927
- }, In);
928
- Se.set(e, t);
929
- }, Hn = (e) => {
930
- let t = Se.get(e);
931
- t && clearTimeout(t);
932
- }, nt = (e, t) => {
933
- switch (t.type) {
934
- case 0:
935
- return { ...e, toasts: [t.toast, ...e.toasts].slice(0, Bn) };
936
- case 1:
937
- return t.toast.id && Hn(t.toast.id), { ...e, toasts: e.toasts.map((o) => o.id === t.toast.id ? { ...o, ...t.toast } : o) };
938
- case 2:
939
- let { toast: r } = t;
940
- return e.toasts.find((o) => o.id === r.id) ? nt(e, { type: 1, toast: r }) : nt(e, { type: 0, toast: r });
941
- case 3:
942
- let { toastId: n } = t;
943
- return n ? qt(n) : e.toasts.forEach((o) => {
944
- qt(o.id);
945
- }), { ...e, toasts: e.toasts.map((o) => o.id === n || n === void 0 ? { ...o, visible: !1 } : o) };
946
- case 4:
947
- return t.toastId === void 0 ? { ...e, toasts: [] } : { ...e, toasts: e.toasts.filter((o) => o.id !== t.toastId) };
948
- case 5:
949
- return { ...e, pausedAt: t.time };
950
- case 6:
951
- let s = t.time - (e.pausedAt || 0);
952
- return { ...e, pausedAt: void 0, toasts: e.toasts.map((o) => ({ ...o, pauseDuration: o.pauseDuration + s })) };
953
- }
954
- }, Te = [], _e = { toasts: [], pausedAt: void 0 }, Z = (e) => {
955
- _e = nt(_e, e), Te.forEach((t) => {
956
- t(_e);
957
- });
958
- }, $n = { blank: 4e3, error: 4e3, success: 2e3, loading: 1 / 0, custom: 4e3 }, Vn = (e = {}) => {
959
- let [t, r] = fn(_e);
960
- lt(() => (Te.push(r), () => {
961
- let s = Te.indexOf(r);
962
- s > -1 && Te.splice(s, 1);
963
- }), [t]);
964
- let n = t.toasts.map((s) => {
965
- var o, i;
966
- return { ...e, ...e[s.type], ...s, duration: s.duration || ((o = e[s.type]) == null ? void 0 : o.duration) || (e == null ? void 0 : e.duration) || $n[s.type], style: { ...e.style, ...(i = e[s.type]) == null ? void 0 : i.style, ...s.style } };
967
- });
968
- return { ...t, toasts: n };
969
- }, qn = (e, t = "blank", r) => ({ createdAt: Date.now(), visible: !0, type: t, ariaProps: { role: "status", "aria-live": "polite" }, message: e, pauseDuration: 0, ...r, id: (r == null ? void 0 : r.id) || Un() }), me = (e) => (t, r) => {
970
- let n = qn(t, e, r);
971
- return Z({ type: 2, toast: n }), n.id;
972
- }, M = (e, t) => me("blank")(e, t);
973
- M.error = me("error");
974
- M.success = me("success");
975
- M.loading = me("loading");
976
- M.custom = me("custom");
977
- M.dismiss = (e) => {
978
- Z({ type: 3, toastId: e });
979
- };
980
- M.remove = (e) => Z({ type: 4, toastId: e });
981
- M.promise = (e, t, r) => {
982
- let n = M.loading(t.loading, { ...r, ...r == null ? void 0 : r.loading });
983
- return e.then((s) => (M.success(ke(t.success, s), { id: n, ...r, ...r == null ? void 0 : r.success }), s)).catch((s) => {
984
- M.error(ke(t.error, s), { id: n, ...r, ...r == null ? void 0 : r.error });
985
- }), e;
986
- };
987
- var Wn = (e, t) => {
988
- Z({ type: 1, toast: { id: e, height: t } });
989
- }, Jn = () => {
990
- Z({ type: 5, time: Date.now() });
991
- }, Yn = (e) => {
992
- let { toasts: t, pausedAt: r } = Vn(e);
993
- lt(() => {
994
- if (r)
995
- return;
996
- let o = Date.now(), i = t.map((c) => {
997
- if (c.duration === 1 / 0)
998
- return;
999
- let l = (c.duration || 0) + c.pauseDuration - (o - c.createdAt);
1000
- if (l < 0) {
1001
- c.visible && M.dismiss(c.id);
1002
- return;
1003
- }
1004
- return setTimeout(() => M.dismiss(c.id), l);
1005
- });
1006
- return () => {
1007
- i.forEach((c) => c && clearTimeout(c));
1008
- };
1009
- }, [t, r]);
1010
- let n = ne(() => {
1011
- r && Z({ type: 6, time: Date.now() });
1012
- }, [r]), s = ne((o, i) => {
1013
- let { reverseOrder: c = !1, gutter: l = 8, defaultPosition: h } = i || {}, p = t.filter((R) => (R.position || h) === (o.position || h) && R.height), f = p.findIndex((R) => R.id === o.id), v = p.filter((R, g) => g < f && R.visible).length;
1014
- return p.filter((R) => R.visible).slice(...c ? [v + 1] : [0, v]).reduce((R, g) => R + (g.height || 0) + l, 0);
1015
- }, [t]);
1016
- return { toasts: t, handlers: { updateHeight: Wn, startPause: Jn, endPause: n, calculateOffset: s } };
1017
- }, Kn = J`
1018
- from {
1019
- transform: scale(0) rotate(45deg);
1020
- opacity: 0;
1021
- }
1022
- to {
1023
- transform: scale(1) rotate(45deg);
1024
- opacity: 1;
1025
- }`, Gn = J`
1026
- from {
1027
- transform: scale(0);
1028
- opacity: 0;
1029
- }
1030
- to {
1031
- transform: scale(1);
1032
- opacity: 1;
1033
- }`, Xn = J`
1034
- from {
1035
- transform: scale(0) rotate(90deg);
1036
- opacity: 0;
1037
- }
1038
- to {
1039
- transform: scale(1) rotate(90deg);
1040
- opacity: 1;
1041
- }`, Qn = X("div")`
1042
- width: 20px;
1043
- opacity: 0;
1044
- height: 20px;
1045
- border-radius: 10px;
1046
- background: ${(e) => e.primary || "#ff4b4b"};
1047
- position: relative;
1048
- transform: rotate(45deg);
1049
-
1050
- animation: ${Kn} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
1051
- forwards;
1052
- animation-delay: 100ms;
1053
-
1054
- &:after,
1055
- &:before {
1056
- content: '';
1057
- animation: ${Gn} 0.15s ease-out forwards;
1058
- animation-delay: 150ms;
1059
- position: absolute;
1060
- border-radius: 3px;
1061
- opacity: 0;
1062
- background: ${(e) => e.secondary || "#fff"};
1063
- bottom: 9px;
1064
- left: 4px;
1065
- height: 2px;
1066
- width: 12px;
1067
- }
1068
-
1069
- &:before {
1070
- animation: ${Xn} 0.15s ease-out forwards;
1071
- animation-delay: 180ms;
1072
- transform: rotate(90deg);
1073
- }
1074
- `, Zn = J`
1075
- from {
1076
- transform: rotate(0deg);
1077
- }
1078
- to {
1079
- transform: rotate(360deg);
1080
- }
1081
- `, eo = X("div")`
1082
- width: 12px;
1083
- height: 12px;
1084
- box-sizing: border-box;
1085
- border: 2px solid;
1086
- border-radius: 100%;
1087
- border-color: ${(e) => e.secondary || "#e0e0e0"};
1088
- border-right-color: ${(e) => e.primary || "#616161"};
1089
- animation: ${Zn} 1s linear infinite;
1090
- `, to = J`
1091
- from {
1092
- transform: scale(0) rotate(45deg);
1093
- opacity: 0;
1094
- }
1095
- to {
1096
- transform: scale(1) rotate(45deg);
1097
- opacity: 1;
1098
- }`, ro = J`
1099
- 0% {
1100
- height: 0;
1101
- width: 0;
1102
- opacity: 0;
1103
- }
1104
- 40% {
1105
- height: 0;
1106
- width: 6px;
1107
- opacity: 1;
1108
- }
1109
- 100% {
1110
- opacity: 1;
1111
- height: 10px;
1112
- }`, no = X("div")`
1113
- width: 20px;
1114
- opacity: 0;
1115
- height: 20px;
1116
- border-radius: 10px;
1117
- background: ${(e) => e.primary || "#61d345"};
1118
- position: relative;
1119
- transform: rotate(45deg);
1120
-
1121
- animation: ${to} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
1122
- forwards;
1123
- animation-delay: 100ms;
1124
- &:after {
1125
- content: '';
1126
- box-sizing: border-box;
1127
- animation: ${ro} 0.2s ease-out forwards;
1128
- opacity: 0;
1129
- animation-delay: 200ms;
1130
- position: absolute;
1131
- border-right: 2px solid;
1132
- border-bottom: 2px solid;
1133
- border-color: ${(e) => e.secondary || "#fff"};
1134
- bottom: 6px;
1135
- left: 6px;
1136
- height: 10px;
1137
- width: 6px;
1138
- }
1139
- `, oo = X("div")`
1140
- position: absolute;
1141
- `, so = X("div")`
1142
- position: relative;
1143
- display: flex;
1144
- justify-content: center;
1145
- align-items: center;
1146
- min-width: 20px;
1147
- min-height: 20px;
1148
- `, io = J`
1149
- from {
1150
- transform: scale(0.6);
1151
- opacity: 0.4;
1152
- }
1153
- to {
1154
- transform: scale(1);
1155
- opacity: 1;
1156
- }`, ao = X("div")`
1157
- position: relative;
1158
- transform: scale(0.6);
1159
- opacity: 0.4;
1160
- min-width: 20px;
1161
- animation: ${io} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
1162
- forwards;
1163
- `, co = ({ toast: e }) => {
1164
- let { icon: t, type: r, iconTheme: n } = e;
1165
- return t !== void 0 ? typeof t == "string" ? N.createElement(ao, null, t) : t : r === "blank" ? null : N.createElement(so, null, N.createElement(eo, { ...n }), r !== "loading" && N.createElement(oo, null, r === "error" ? N.createElement(Qn, { ...n }) : N.createElement(no, { ...n })));
1166
- }, lo = (e) => `
1167
- 0% {transform: translate3d(0,${e * -200}%,0) scale(.6); opacity:.5;}
1168
- 100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
1169
- `, uo = (e) => `
1170
- 0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
1171
- 100% {transform: translate3d(0,${e * -150}%,-1px) scale(.6); opacity:0;}
1172
- `, fo = "0%{opacity:0;} 100%{opacity:1;}", po = "0%{opacity:1;} 100%{opacity:0;}", ho = X("div")`
1173
- display: flex;
1174
- align-items: center;
1175
- background: #fff;
1176
- color: #363636;
1177
- line-height: 1.3;
1178
- will-change: transform;
1179
- box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);
1180
- max-width: 350px;
1181
- pointer-events: auto;
1182
- padding: 8px 10px;
1183
- border-radius: 8px;
1184
- `, mo = X("div")`
1185
- display: flex;
1186
- justify-content: center;
1187
- margin: 4px 10px;
1188
- color: inherit;
1189
- flex: 1 1 auto;
1190
- white-space: pre-line;
1191
- `, go = (e, t) => {
1192
- let r = e.includes("top") ? 1 : -1, [n, s] = fr() ? [fo, po] : [lo(r), uo(r)];
1193
- return { animation: t ? `${J(n)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards` : `${J(s)} 0.4s forwards cubic-bezier(.06,.71,.55,1)` };
1194
- }, yo = N.memo(({ toast: e, position: t, style: r, children: n }) => {
1195
- let s = e.height ? go(e.position || t || "top-center", e.visible) : { opacity: 0 }, o = N.createElement(co, { toast: e }), i = N.createElement(mo, { ...e.ariaProps }, ke(e.message, e));
1196
- return N.createElement(ho, { className: e.className, style: { ...s, ...r, ...e.style } }, typeof n == "function" ? n({ icon: o, message: i }) : N.createElement(N.Fragment, null, o, i));
1197
- });
1198
- Ln(N.createElement);
1199
- var bo = ({ id: e, className: t, style: r, onHeightUpdate: n, children: s }) => {
1200
- let o = N.useCallback((i) => {
1201
- if (i) {
1202
- let c = () => {
1203
- let l = i.getBoundingClientRect().height;
1204
- n(e, l);
1205
- };
1206
- c(), new MutationObserver(c).observe(i, { subtree: !0, childList: !0, characterData: !0 });
1207
- }
1208
- }, [e, n]);
1209
- return N.createElement("div", { ref: o, className: t, style: r }, s);
1210
- }, vo = (e, t) => {
1211
- let r = e.includes("top"), n = r ? { top: 0 } : { bottom: 0 }, s = e.includes("center") ? { justifyContent: "center" } : e.includes("right") ? { justifyContent: "flex-end" } : {};
1212
- return { left: 0, right: 0, display: "flex", position: "absolute", transition: fr() ? void 0 : "all 230ms cubic-bezier(.21,1.02,.73,1)", transform: `translateY(${t * (r ? 1 : -1)}px)`, ...n, ...s };
1213
- }, wo = Fe`
1214
- z-index: 9999;
1215
- > * {
1216
- pointer-events: auto;
1217
- }
1218
- `, Oe = 16, ii = ({ reverseOrder: e, position: t = "top-center", toastOptions: r, gutter: n, children: s, containerStyle: o, containerClassName: i }) => {
1219
- let { toasts: c, handlers: l } = Yn(r);
1220
- return N.createElement("div", { style: { position: "fixed", zIndex: 9999, top: Oe, left: Oe, right: Oe, bottom: Oe, pointerEvents: "none", ...o }, className: i, onMouseEnter: l.startPause, onMouseLeave: l.endPause }, c.map((h) => {
1221
- let p = h.position || t, f = l.calculateOffset(h, { reverseOrder: e, gutter: n, defaultPosition: t }), v = vo(p, f);
1222
- return N.createElement(bo, { id: h.id, key: h.id, onHeightUpdate: l.updateHeight, className: h.visible ? wo : "", style: v }, h.type === "custom" ? ke(h.message, h) : s ? s(h) : N.createElement(yo, { toast: h, position: p }));
1223
- }));
1224
- }, re = M;
1225
- const ai = he({
1226
- isShown: !1,
1227
- text: "",
1228
- hidePrompt: () => {
1229
- },
1230
- showPrompt: () => {
1231
- },
1232
- resolveRef: { current: () => {
1233
- } }
1234
- }), ci = he({
1235
- show: !1,
1236
- text: "",
1237
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
1238
- showConfirm: (e) => {
1239
- },
1240
- hideConfirm: () => {
1241
- }
1242
- }), li = he({
1243
- isLoading: !1,
1244
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
1245
- startLoading: (e) => {
1246
- },
1247
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
1248
- stopLoading: (e) => {
1249
- }
1250
- }), ui = he({
1251
- user: null,
1252
- loginUser: () => Promise.resolve(!0),
1253
- logoutUser: () => {
1254
- }
1255
- }), Eo = () => {
1256
- const { axiosInstance: e } = or(cr), t = ne(() => localStorage.getItem("token") ?? null, []), r = ne(() => {
1257
- const o = t();
1258
- return o !== null && o.length > 0;
1259
- }, [t]), n = ne(async (o, i) => {
1260
- let c = !1;
1261
- return await e.post("/user/login", { kid: o, password: i }).then((l) => {
1262
- localStorage.setItem("token", l.data), c = !0;
1263
- }).catch((l) => {
1264
- console.log(l), c = !1;
1265
- }), c;
1266
- }, [e]), s = ne(() => {
1267
- localStorage.removeItem("token"), localStorage.removeItem("user");
1268
- }, []);
1269
- return {
1270
- isAuthenticated: r,
1271
- getToken: t,
1272
- authenticate: n,
1273
- logout: s
1274
- };
1275
- };
1276
- let Re;
1277
- const xo = new Uint8Array(16);
1278
- function Oo() {
1279
- if (!Re && (Re = typeof crypto < "u" && crypto.getRandomValues && crypto.getRandomValues.bind(crypto), !Re))
1280
- throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
1281
- return Re(xo);
1282
- }
1283
- const D = [];
1284
- for (let e = 0; e < 256; ++e)
1285
- D.push((e + 256).toString(16).slice(1));
1286
- function Ro(e, t = 0) {
1287
- return D[e[t + 0]] + D[e[t + 1]] + D[e[t + 2]] + D[e[t + 3]] + "-" + D[e[t + 4]] + D[e[t + 5]] + "-" + D[e[t + 6]] + D[e[t + 7]] + "-" + D[e[t + 8]] + D[e[t + 9]] + "-" + D[e[t + 10]] + D[e[t + 11]] + D[e[t + 12]] + D[e[t + 13]] + D[e[t + 14]] + D[e[t + 15]];
1288
- }
1289
- const So = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), Wt = {
1290
- randomUUID: So
1291
- };
1292
- function To(e, t, r) {
1293
- if (Wt.randomUUID && !t && !e)
1294
- return Wt.randomUUID();
1295
- e = e || {};
1296
- const n = e.random || (e.rng || Oo)();
1297
- if (n[6] = n[6] & 15 | 64, n[8] = n[8] & 63 | 128, t) {
1298
- r = r || 0;
1299
- for (let s = 0; s < 16; ++s)
1300
- t[r + s] = n[s];
1301
- return t;
1302
- }
1303
- return Ro(n);
1304
- }
1305
- const _o = "_toast_1s57i_1", fe = {
1306
- toast: _o
1307
- }, Po = (e) => {
1308
- switch (e) {
1309
- case "success":
1310
- return 5e3;
1311
- case "info":
1312
- return 5e3;
1313
- case "danger":
1314
- return 1e4;
1315
- case "warning":
1316
- return 1e4;
1317
- case "prompt":
1318
- return 1e4;
1319
- default:
1320
- return 5e3;
1321
- }
1322
- }, Co = () => ({ addNotification: (t, r) => {
1323
- const n = To(), s = dn(t), o = Po(r), i = /* @__PURE__ */ Y.jsxs(Y.Fragment, { children: [
1324
- s,
1325
- /* @__PURE__ */ Y.jsx(An, { onClick: () => re.dismiss(n), type: "button", style: {
1326
- position: "absolute",
1327
- fontSize: "12px",
1328
- top: "calc(50% - 6px)",
1329
- right: "8px"
1330
- } })
1331
- ] });
1332
- switch (r) {
1333
- case "success": {
1334
- re(i, {
1335
- id: n,
1336
- duration: o,
1337
- position: "top-center",
1338
- icon: /* @__PURE__ */ Y.jsx(Cn, { size: 12 }),
1339
- className: ue("luminus-toast-success rounded shadow bg-success", fe.toast)
1340
- });
1341
- break;
1342
- }
1343
- case "danger": {
1344
- re(i, {
1345
- id: n,
1346
- duration: o,
1347
- position: "top-center",
1348
- icon: /* @__PURE__ */ Y.jsx(Pn, { size: 12 }),
1349
- className: ue("luminus-toast-danger rounded shadow bg-danger", fe.toast)
1350
- });
1351
- break;
1352
- }
1353
- case "warning": {
1354
- re(i, {
1355
- id: n,
1356
- duration: o,
1357
- position: "top-center",
1358
- icon: /* @__PURE__ */ Y.jsx(Sn, { size: 12 }),
1359
- className: ue("luminus-toast-warning rounded shadow bg-warning", fe.toast)
1360
- });
1361
- break;
1362
- }
1363
- case "info": {
1364
- re(i, {
1365
- id: n,
1366
- duration: o,
1367
- position: "top-center",
1368
- icon: /* @__PURE__ */ Y.jsx(Tn, { size: 12 }),
1369
- className: ue("luminus-toast-info rounded shadow bg-info", fe.toast)
1370
- });
1371
- break;
1372
- }
1373
- case "prompt": {
1374
- re(i, {
1375
- id: n,
1376
- duration: o,
1377
- position: "top-center",
1378
- icon: /* @__PURE__ */ Y.jsx(_n, { size: 12 }),
1379
- className: ue("luminus-toast-prompt rounded shadow bg-light", fe.toast)
1380
- });
1381
- break;
1382
- }
1383
- }
1384
- } });
1385
- function dr(e, t) {
1386
- return function() {
1387
- return e.apply(t, arguments);
1388
- };
1389
- }
1390
- const { toString: Ao } = Object.prototype, { getPrototypeOf: ut } = Object, Me = /* @__PURE__ */ ((e) => (t) => {
1391
- const r = Ao.call(t);
1392
- return e[r] || (e[r] = r.slice(8, -1).toLowerCase());
1393
- })(/* @__PURE__ */ Object.create(null)), I = (e) => (e = e.toLowerCase(), (t) => Me(t) === e), Le = (e) => (t) => typeof t === e, { isArray: se } = Array, pe = Le("undefined");
1394
- function jo(e) {
1395
- return e !== null && !pe(e) && e.constructor !== null && !pe(e.constructor) && z(e.constructor.isBuffer) && e.constructor.isBuffer(e);
1396
- }
1397
- const pr = I("ArrayBuffer");
1398
- function No(e) {
1399
- let t;
1400
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && pr(e.buffer), t;
1401
- }
1402
- const ko = Le("string"), z = Le("function"), hr = Le("number"), ze = (e) => e !== null && typeof e == "object", Do = (e) => e === !0 || e === !1, Pe = (e) => {
1403
- if (Me(e) !== "object")
1404
- return !1;
1405
- const t = ut(e);
1406
- return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e);
1407
- }, Fo = I("Date"), Mo = I("File"), Lo = I("Blob"), zo = I("FileList"), Uo = (e) => ze(e) && z(e.pipe), Bo = (e) => {
1408
- let t;
1409
- return e && (typeof FormData == "function" && e instanceof FormData || z(e.append) && ((t = Me(e)) === "formdata" || // detect form-data instance
1410
- t === "object" && z(e.toString) && e.toString() === "[object FormData]"));
1411
- }, Io = I("URLSearchParams"), Ho = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
1412
- function ge(e, t, { allOwnKeys: r = !1 } = {}) {
1413
- if (e === null || typeof e > "u")
1414
- return;
1415
- let n, s;
1416
- if (typeof e != "object" && (e = [e]), se(e))
1417
- for (n = 0, s = e.length; n < s; n++)
1418
- t.call(null, e[n], n, e);
1419
- else {
1420
- const o = r ? Object.getOwnPropertyNames(e) : Object.keys(e), i = o.length;
1421
- let c;
1422
- for (n = 0; n < i; n++)
1423
- c = o[n], t.call(null, e[c], c, e);
1424
- }
1425
- }
1426
- function mr(e, t) {
1427
- t = t.toLowerCase();
1428
- const r = Object.keys(e);
1429
- let n = r.length, s;
1430
- for (; n-- > 0; )
1431
- if (s = r[n], t === s.toLowerCase())
1432
- return s;
1433
- return null;
1434
- }
1435
- const gr = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, yr = (e) => !pe(e) && e !== gr;
1436
- function ot() {
1437
- const { caseless: e } = yr(this) && this || {}, t = {}, r = (n, s) => {
1438
- const o = e && mr(t, s) || s;
1439
- Pe(t[o]) && Pe(n) ? t[o] = ot(t[o], n) : Pe(n) ? t[o] = ot({}, n) : se(n) ? t[o] = n.slice() : t[o] = n;
1440
- };
1441
- for (let n = 0, s = arguments.length; n < s; n++)
1442
- arguments[n] && ge(arguments[n], r);
1443
- return t;
1444
- }
1445
- const $o = (e, t, r, { allOwnKeys: n } = {}) => (ge(t, (s, o) => {
1446
- r && z(s) ? e[o] = dr(s, r) : e[o] = s;
1447
- }, { allOwnKeys: n }), e), Vo = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), qo = (e, t, r, n) => {
1448
- e.prototype = Object.create(t.prototype, n), e.prototype.constructor = e, Object.defineProperty(e, "super", {
1449
- value: t.prototype
1450
- }), r && Object.assign(e.prototype, r);
1451
- }, Wo = (e, t, r, n) => {
1452
- let s, o, i;
1453
- const c = {};
1454
- if (t = t || {}, e == null)
1455
- return t;
1456
- do {
1457
- for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
1458
- i = s[o], (!n || n(i, e, t)) && !c[i] && (t[i] = e[i], c[i] = !0);
1459
- e = r !== !1 && ut(e);
1460
- } while (e && (!r || r(e, t)) && e !== Object.prototype);
1461
- return t;
1462
- }, Jo = (e, t, r) => {
1463
- e = String(e), (r === void 0 || r > e.length) && (r = e.length), r -= t.length;
1464
- const n = e.indexOf(t, r);
1465
- return n !== -1 && n === r;
1466
- }, Yo = (e) => {
1467
- if (!e)
1468
- return null;
1469
- if (se(e))
1470
- return e;
1471
- let t = e.length;
1472
- if (!hr(t))
1473
- return null;
1474
- const r = new Array(t);
1475
- for (; t-- > 0; )
1476
- r[t] = e[t];
1477
- return r;
1478
- }, Ko = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && ut(Uint8Array)), Go = (e, t) => {
1479
- const n = (e && e[Symbol.iterator]).call(e);
1480
- let s;
1481
- for (; (s = n.next()) && !s.done; ) {
1482
- const o = s.value;
1483
- t.call(e, o[0], o[1]);
1484
- }
1485
- }, Xo = (e, t) => {
1486
- let r;
1487
- const n = [];
1488
- for (; (r = e.exec(t)) !== null; )
1489
- n.push(r);
1490
- return n;
1491
- }, Qo = I("HTMLFormElement"), Zo = (e) => e.toLowerCase().replace(
1492
- /[-_\s]([a-z\d])(\w*)/g,
1493
- function(r, n, s) {
1494
- return n.toUpperCase() + s;
1495
- }
1496
- ), Jt = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), es = I("RegExp"), br = (e, t) => {
1497
- const r = Object.getOwnPropertyDescriptors(e), n = {};
1498
- ge(r, (s, o) => {
1499
- let i;
1500
- (i = t(s, o, e)) !== !1 && (n[o] = i || s);
1501
- }), Object.defineProperties(e, n);
1502
- }, ts = (e) => {
1503
- br(e, (t, r) => {
1504
- if (z(e) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
1505
- return !1;
1506
- const n = e[r];
1507
- if (z(n)) {
1508
- if (t.enumerable = !1, "writable" in t) {
1509
- t.writable = !1;
1510
- return;
1511
- }
1512
- t.set || (t.set = () => {
1513
- throw Error("Can not rewrite read-only method '" + r + "'");
1514
- });
1515
- }
1516
- });
1517
- }, rs = (e, t) => {
1518
- const r = {}, n = (s) => {
1519
- s.forEach((o) => {
1520
- r[o] = !0;
1521
- });
1522
- };
1523
- return se(e) ? n(e) : n(String(e).split(t)), r;
1524
- }, ns = () => {
1525
- }, os = (e, t) => (e = +e, Number.isFinite(e) ? e : t), Ge = "abcdefghijklmnopqrstuvwxyz", Yt = "0123456789", vr = {
1526
- DIGIT: Yt,
1527
- ALPHA: Ge,
1528
- ALPHA_DIGIT: Ge + Ge.toUpperCase() + Yt
1529
- }, ss = (e = 16, t = vr.ALPHA_DIGIT) => {
1530
- let r = "";
1531
- const { length: n } = t;
1532
- for (; e--; )
1533
- r += t[Math.random() * n | 0];
1534
- return r;
1535
- };
1536
- function is(e) {
1537
- return !!(e && z(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]);
1538
- }
1539
- const as = (e) => {
1540
- const t = new Array(10), r = (n, s) => {
1541
- if (ze(n)) {
1542
- if (t.indexOf(n) >= 0)
1543
- return;
1544
- if (!("toJSON" in n)) {
1545
- t[s] = n;
1546
- const o = se(n) ? [] : {};
1547
- return ge(n, (i, c) => {
1548
- const l = r(i, s + 1);
1549
- !pe(l) && (o[c] = l);
1550
- }), t[s] = void 0, o;
1551
- }
1552
- }
1553
- return n;
1554
- };
1555
- return r(e, 0);
1556
- }, cs = I("AsyncFunction"), ls = (e) => e && (ze(e) || z(e)) && z(e.then) && z(e.catch), u = {
1557
- isArray: se,
1558
- isArrayBuffer: pr,
1559
- isBuffer: jo,
1560
- isFormData: Bo,
1561
- isArrayBufferView: No,
1562
- isString: ko,
1563
- isNumber: hr,
1564
- isBoolean: Do,
1565
- isObject: ze,
1566
- isPlainObject: Pe,
1567
- isUndefined: pe,
1568
- isDate: Fo,
1569
- isFile: Mo,
1570
- isBlob: Lo,
1571
- isRegExp: es,
1572
- isFunction: z,
1573
- isStream: Uo,
1574
- isURLSearchParams: Io,
1575
- isTypedArray: Ko,
1576
- isFileList: zo,
1577
- forEach: ge,
1578
- merge: ot,
1579
- extend: $o,
1580
- trim: Ho,
1581
- stripBOM: Vo,
1582
- inherits: qo,
1583
- toFlatObject: Wo,
1584
- kindOf: Me,
1585
- kindOfTest: I,
1586
- endsWith: Jo,
1587
- toArray: Yo,
1588
- forEachEntry: Go,
1589
- matchAll: Xo,
1590
- isHTMLForm: Qo,
1591
- hasOwnProperty: Jt,
1592
- hasOwnProp: Jt,
1593
- // an alias to avoid ESLint no-prototype-builtins detection
1594
- reduceDescriptors: br,
1595
- freezeMethods: ts,
1596
- toObjectSet: rs,
1597
- toCamelCase: Zo,
1598
- noop: ns,
1599
- toFiniteNumber: os,
1600
- findKey: mr,
1601
- global: gr,
1602
- isContextDefined: yr,
1603
- ALPHABET: vr,
1604
- generateString: ss,
1605
- isSpecCompliantForm: is,
1606
- toJSONObject: as,
1607
- isAsyncFn: cs,
1608
- isThenable: ls
1609
- };
1610
- function x(e, t, r, n, s) {
1611
- Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), r && (this.config = r), n && (this.request = n), s && (this.response = s);
1612
- }
1613
- u.inherits(x, Error, {
1614
- toJSON: function() {
1615
- return {
1616
- // Standard
1617
- message: this.message,
1618
- name: this.name,
1619
- // Microsoft
1620
- description: this.description,
1621
- number: this.number,
1622
- // Mozilla
1623
- fileName: this.fileName,
1624
- lineNumber: this.lineNumber,
1625
- columnNumber: this.columnNumber,
1626
- stack: this.stack,
1627
- // Axios
1628
- config: u.toJSONObject(this.config),
1629
- code: this.code,
1630
- status: this.response && this.response.status ? this.response.status : null
1631
- };
1632
- }
1633
- });
1634
- const wr = x.prototype, Er = {};
1635
- [
1636
- "ERR_BAD_OPTION_VALUE",
1637
- "ERR_BAD_OPTION",
1638
- "ECONNABORTED",
1639
- "ETIMEDOUT",
1640
- "ERR_NETWORK",
1641
- "ERR_FR_TOO_MANY_REDIRECTS",
1642
- "ERR_DEPRECATED",
1643
- "ERR_BAD_RESPONSE",
1644
- "ERR_BAD_REQUEST",
1645
- "ERR_CANCELED",
1646
- "ERR_NOT_SUPPORT",
1647
- "ERR_INVALID_URL"
1648
- // eslint-disable-next-line func-names
1649
- ].forEach((e) => {
1650
- Er[e] = { value: e };
1651
- });
1652
- Object.defineProperties(x, Er);
1653
- Object.defineProperty(wr, "isAxiosError", { value: !0 });
1654
- x.from = (e, t, r, n, s, o) => {
1655
- const i = Object.create(wr);
1656
- return u.toFlatObject(e, i, function(l) {
1657
- return l !== Error.prototype;
1658
- }, (c) => c !== "isAxiosError"), x.call(i, e.message, t, r, n, s), i.cause = e, i.name = e.name, o && Object.assign(i, o), i;
1659
- };
1660
- const us = null;
1661
- function st(e) {
1662
- return u.isPlainObject(e) || u.isArray(e);
1663
- }
1664
- function xr(e) {
1665
- return u.endsWith(e, "[]") ? e.slice(0, -2) : e;
1666
- }
1667
- function Kt(e, t, r) {
1668
- return e ? e.concat(t).map(function(s, o) {
1669
- return s = xr(s), !r && o ? "[" + s + "]" : s;
1670
- }).join(r ? "." : "") : t;
1671
- }
1672
- function fs(e) {
1673
- return u.isArray(e) && !e.some(st);
1674
- }
1675
- const ds = u.toFlatObject(u, {}, null, function(t) {
1676
- return /^is[A-Z]/.test(t);
1677
- });
1678
- function Ue(e, t, r) {
1679
- if (!u.isObject(e))
1680
- throw new TypeError("target must be an object");
1681
- t = t || new FormData(), r = u.toFlatObject(r, {
1682
- metaTokens: !0,
1683
- dots: !1,
1684
- indexes: !1
1685
- }, !1, function(y, j) {
1686
- return !u.isUndefined(j[y]);
1687
- });
1688
- const n = r.metaTokens, s = r.visitor || p, o = r.dots, i = r.indexes, l = (r.Blob || typeof Blob < "u" && Blob) && u.isSpecCompliantForm(t);
1689
- if (!u.isFunction(s))
1690
- throw new TypeError("visitor must be a function");
1691
- function h(g) {
1692
- if (g === null)
1693
- return "";
1694
- if (u.isDate(g))
1695
- return g.toISOString();
1696
- if (!l && u.isBlob(g))
1697
- throw new x("Blob is not supported. Use a Buffer instead.");
1698
- return u.isArrayBuffer(g) || u.isTypedArray(g) ? l && typeof Blob == "function" ? new Blob([g]) : Buffer.from(g) : g;
1699
- }
1700
- function p(g, y, j) {
1701
- let _ = g;
1702
- if (g && !j && typeof g == "object") {
1703
- if (u.endsWith(y, "{}"))
1704
- y = n ? y : y.slice(0, -2), g = JSON.stringify(g);
1705
- else if (u.isArray(g) && fs(g) || (u.isFileList(g) || u.endsWith(y, "[]")) && (_ = u.toArray(g)))
1706
- return y = xr(y), _.forEach(function(U, Ie) {
1707
- !(u.isUndefined(U) || U === null) && t.append(
1708
- // eslint-disable-next-line no-nested-ternary
1709
- i === !0 ? Kt([y], Ie, o) : i === null ? y : y + "[]",
1710
- h(U)
1711
- );
1712
- }), !1;
1713
- }
1714
- return st(g) ? !0 : (t.append(Kt(j, y, o), h(g)), !1);
1715
- }
1716
- const f = [], v = Object.assign(ds, {
1717
- defaultVisitor: p,
1718
- convertValue: h,
1719
- isVisitable: st
1720
- });
1721
- function R(g, y) {
1722
- if (!u.isUndefined(g)) {
1723
- if (f.indexOf(g) !== -1)
1724
- throw Error("Circular reference detected in " + y.join("."));
1725
- f.push(g), u.forEach(g, function(_, T) {
1726
- (!(u.isUndefined(_) || _ === null) && s.call(
1727
- t,
1728
- _,
1729
- u.isString(T) ? T.trim() : T,
1730
- y,
1731
- v
1732
- )) === !0 && R(_, y ? y.concat(T) : [T]);
1733
- }), f.pop();
1734
- }
1735
- }
1736
- if (!u.isObject(e))
1737
- throw new TypeError("data must be an object");
1738
- return R(e), t;
1739
- }
1740
- function Gt(e) {
1741
- const t = {
1742
- "!": "%21",
1743
- "'": "%27",
1744
- "(": "%28",
1745
- ")": "%29",
1746
- "~": "%7E",
1747
- "%20": "+",
1748
- "%00": "\0"
1749
- };
1750
- return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g, function(n) {
1751
- return t[n];
1752
- });
1753
- }
1754
- function ft(e, t) {
1755
- this._pairs = [], e && Ue(e, this, t);
1756
- }
1757
- const Or = ft.prototype;
1758
- Or.append = function(t, r) {
1759
- this._pairs.push([t, r]);
1760
- };
1761
- Or.toString = function(t) {
1762
- const r = t ? function(n) {
1763
- return t.call(this, n, Gt);
1764
- } : Gt;
1765
- return this._pairs.map(function(s) {
1766
- return r(s[0]) + "=" + r(s[1]);
1767
- }, "").join("&");
1768
- };
1769
- function ps(e) {
1770
- return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
1771
- }
1772
- function Rr(e, t, r) {
1773
- if (!t)
1774
- return e;
1775
- const n = r && r.encode || ps, s = r && r.serialize;
1776
- let o;
1777
- if (s ? o = s(t, r) : o = u.isURLSearchParams(t) ? t.toString() : new ft(t, r).toString(n), o) {
1778
- const i = e.indexOf("#");
1779
- i !== -1 && (e = e.slice(0, i)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
1780
- }
1781
- return e;
1782
- }
1783
- class Xt {
1784
- constructor() {
1785
- this.handlers = [];
1786
- }
1787
- /**
1788
- * Add a new interceptor to the stack
1789
- *
1790
- * @param {Function} fulfilled The function to handle `then` for a `Promise`
1791
- * @param {Function} rejected The function to handle `reject` for a `Promise`
1792
- *
1793
- * @return {Number} An ID used to remove interceptor later
1794
- */
1795
- use(t, r, n) {
1796
- return this.handlers.push({
1797
- fulfilled: t,
1798
- rejected: r,
1799
- synchronous: n ? n.synchronous : !1,
1800
- runWhen: n ? n.runWhen : null
1801
- }), this.handlers.length - 1;
1802
- }
1803
- /**
1804
- * Remove an interceptor from the stack
1805
- *
1806
- * @param {Number} id The ID that was returned by `use`
1807
- *
1808
- * @returns {Boolean} `true` if the interceptor was removed, `false` otherwise
1809
- */
1810
- eject(t) {
1811
- this.handlers[t] && (this.handlers[t] = null);
1812
- }
1813
- /**
1814
- * Clear all interceptors from the stack
1815
- *
1816
- * @returns {void}
1817
- */
1818
- clear() {
1819
- this.handlers && (this.handlers = []);
1820
- }
1821
- /**
1822
- * Iterate over all the registered interceptors
1823
- *
1824
- * This method is particularly useful for skipping over any
1825
- * interceptors that may have become `null` calling `eject`.
1826
- *
1827
- * @param {Function} fn The function to call for each interceptor
1828
- *
1829
- * @returns {void}
1830
- */
1831
- forEach(t) {
1832
- u.forEach(this.handlers, function(n) {
1833
- n !== null && t(n);
1834
- });
1835
- }
1836
- }
1837
- const Sr = {
1838
- silentJSONParsing: !0,
1839
- forcedJSONParsing: !0,
1840
- clarifyTimeoutError: !1
1841
- }, hs = typeof URLSearchParams < "u" ? URLSearchParams : ft, ms = typeof FormData < "u" ? FormData : null, gs = typeof Blob < "u" ? Blob : null, ys = {
1842
- isBrowser: !0,
1843
- classes: {
1844
- URLSearchParams: hs,
1845
- FormData: ms,
1846
- Blob: gs
1847
- },
1848
- protocols: ["http", "https", "file", "blob", "url", "data"]
1849
- }, Tr = typeof window < "u" && typeof document < "u", bs = ((e) => Tr && ["ReactNative", "NativeScript", "NS"].indexOf(e) < 0)(typeof navigator < "u" && navigator.product), vs = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
1850
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function", ws = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1851
- __proto__: null,
1852
- hasBrowserEnv: Tr,
1853
- hasStandardBrowserEnv: bs,
1854
- hasStandardBrowserWebWorkerEnv: vs
1855
- }, Symbol.toStringTag, { value: "Module" })), B = {
1856
- ...ws,
1857
- ...ys
1858
- };
1859
- function Es(e, t) {
1860
- return Ue(e, new B.classes.URLSearchParams(), Object.assign({
1861
- visitor: function(r, n, s, o) {
1862
- return B.isNode && u.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
1863
- }
1864
- }, t));
1865
- }
1866
- function xs(e) {
1867
- return u.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
1868
- }
1869
- function Os(e) {
1870
- const t = {}, r = Object.keys(e);
1871
- let n;
1872
- const s = r.length;
1873
- let o;
1874
- for (n = 0; n < s; n++)
1875
- o = r[n], t[o] = e[o];
1876
- return t;
1877
- }
1878
- function _r(e) {
1879
- function t(r, n, s, o) {
1880
- let i = r[o++];
1881
- if (i === "__proto__")
1882
- return !0;
1883
- const c = Number.isFinite(+i), l = o >= r.length;
1884
- return i = !i && u.isArray(s) ? s.length : i, l ? (u.hasOwnProp(s, i) ? s[i] = [s[i], n] : s[i] = n, !c) : ((!s[i] || !u.isObject(s[i])) && (s[i] = []), t(r, n, s[i], o) && u.isArray(s[i]) && (s[i] = Os(s[i])), !c);
1885
- }
1886
- if (u.isFormData(e) && u.isFunction(e.entries)) {
1887
- const r = {};
1888
- return u.forEachEntry(e, (n, s) => {
1889
- t(xs(n), s, r, 0);
1890
- }), r;
1891
- }
1892
- return null;
1893
- }
1894
- function Rs(e, t, r) {
1895
- if (u.isString(e))
1896
- try {
1897
- return (t || JSON.parse)(e), u.trim(e);
1898
- } catch (n) {
1899
- if (n.name !== "SyntaxError")
1900
- throw n;
1901
- }
1902
- return (r || JSON.stringify)(e);
1903
- }
1904
- const dt = {
1905
- transitional: Sr,
1906
- adapter: ["xhr", "http"],
1907
- transformRequest: [function(t, r) {
1908
- const n = r.getContentType() || "", s = n.indexOf("application/json") > -1, o = u.isObject(t);
1909
- if (o && u.isHTMLForm(t) && (t = new FormData(t)), u.isFormData(t))
1910
- return s ? JSON.stringify(_r(t)) : t;
1911
- if (u.isArrayBuffer(t) || u.isBuffer(t) || u.isStream(t) || u.isFile(t) || u.isBlob(t))
1912
- return t;
1913
- if (u.isArrayBufferView(t))
1914
- return t.buffer;
1915
- if (u.isURLSearchParams(t))
1916
- return r.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
1917
- let c;
1918
- if (o) {
1919
- if (n.indexOf("application/x-www-form-urlencoded") > -1)
1920
- return Es(t, this.formSerializer).toString();
1921
- if ((c = u.isFileList(t)) || n.indexOf("multipart/form-data") > -1) {
1922
- const l = this.env && this.env.FormData;
1923
- return Ue(
1924
- c ? { "files[]": t } : t,
1925
- l && new l(),
1926
- this.formSerializer
1927
- );
1928
- }
1929
- }
1930
- return o || s ? (r.setContentType("application/json", !1), Rs(t)) : t;
1931
- }],
1932
- transformResponse: [function(t) {
1933
- const r = this.transitional || dt.transitional, n = r && r.forcedJSONParsing, s = this.responseType === "json";
1934
- if (t && u.isString(t) && (n && !this.responseType || s)) {
1935
- const i = !(r && r.silentJSONParsing) && s;
1936
- try {
1937
- return JSON.parse(t);
1938
- } catch (c) {
1939
- if (i)
1940
- throw c.name === "SyntaxError" ? x.from(c, x.ERR_BAD_RESPONSE, this, null, this.response) : c;
1941
- }
1942
- }
1943
- return t;
1944
- }],
1945
- /**
1946
- * A timeout in milliseconds to abort a request. If set to 0 (default) a
1947
- * timeout is not created.
1948
- */
1949
- timeout: 0,
1950
- xsrfCookieName: "XSRF-TOKEN",
1951
- xsrfHeaderName: "X-XSRF-TOKEN",
1952
- maxContentLength: -1,
1953
- maxBodyLength: -1,
1954
- env: {
1955
- FormData: B.classes.FormData,
1956
- Blob: B.classes.Blob
1957
- },
1958
- validateStatus: function(t) {
1959
- return t >= 200 && t < 300;
1960
- },
1961
- headers: {
1962
- common: {
1963
- Accept: "application/json, text/plain, */*",
1964
- "Content-Type": void 0
1965
- }
1966
- }
1967
- };
1968
- u.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
1969
- dt.headers[e] = {};
1970
- });
1971
- const pt = dt, Ss = u.toObjectSet([
1972
- "age",
1973
- "authorization",
1974
- "content-length",
1975
- "content-type",
1976
- "etag",
1977
- "expires",
1978
- "from",
1979
- "host",
1980
- "if-modified-since",
1981
- "if-unmodified-since",
1982
- "last-modified",
1983
- "location",
1984
- "max-forwards",
1985
- "proxy-authorization",
1986
- "referer",
1987
- "retry-after",
1988
- "user-agent"
1989
- ]), Ts = (e) => {
1990
- const t = {};
1991
- let r, n, s;
1992
- return e && e.split(`
1993
- `).forEach(function(i) {
1994
- s = i.indexOf(":"), r = i.substring(0, s).trim().toLowerCase(), n = i.substring(s + 1).trim(), !(!r || t[r] && Ss[r]) && (r === "set-cookie" ? t[r] ? t[r].push(n) : t[r] = [n] : t[r] = t[r] ? t[r] + ", " + n : n);
1995
- }), t;
1996
- }, Qt = Symbol("internals");
1997
- function de(e) {
1998
- return e && String(e).trim().toLowerCase();
1999
- }
2000
- function Ce(e) {
2001
- return e === !1 || e == null ? e : u.isArray(e) ? e.map(Ce) : String(e);
2002
- }
2003
- function _s(e) {
2004
- const t = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
2005
- let n;
2006
- for (; n = r.exec(e); )
2007
- t[n[1]] = n[2];
2008
- return t;
2009
- }
2010
- const Ps = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
2011
- function Xe(e, t, r, n, s) {
2012
- if (u.isFunction(n))
2013
- return n.call(this, t, r);
2014
- if (s && (t = r), !!u.isString(t)) {
2015
- if (u.isString(n))
2016
- return t.indexOf(n) !== -1;
2017
- if (u.isRegExp(n))
2018
- return n.test(t);
2019
- }
2020
- }
2021
- function Cs(e) {
2022
- return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, n) => r.toUpperCase() + n);
2023
- }
2024
- function As(e, t) {
2025
- const r = u.toCamelCase(" " + t);
2026
- ["get", "set", "has"].forEach((n) => {
2027
- Object.defineProperty(e, n + r, {
2028
- value: function(s, o, i) {
2029
- return this[n].call(this, t, s, o, i);
2030
- },
2031
- configurable: !0
2032
- });
2033
- });
2034
- }
2035
- class Be {
2036
- constructor(t) {
2037
- t && this.set(t);
2038
- }
2039
- set(t, r, n) {
2040
- const s = this;
2041
- function o(c, l, h) {
2042
- const p = de(l);
2043
- if (!p)
2044
- throw new Error("header name must be a non-empty string");
2045
- const f = u.findKey(s, p);
2046
- (!f || s[f] === void 0 || h === !0 || h === void 0 && s[f] !== !1) && (s[f || l] = Ce(c));
2047
- }
2048
- const i = (c, l) => u.forEach(c, (h, p) => o(h, p, l));
2049
- return u.isPlainObject(t) || t instanceof this.constructor ? i(t, r) : u.isString(t) && (t = t.trim()) && !Ps(t) ? i(Ts(t), r) : t != null && o(r, t, n), this;
2050
- }
2051
- get(t, r) {
2052
- if (t = de(t), t) {
2053
- const n = u.findKey(this, t);
2054
- if (n) {
2055
- const s = this[n];
2056
- if (!r)
2057
- return s;
2058
- if (r === !0)
2059
- return _s(s);
2060
- if (u.isFunction(r))
2061
- return r.call(this, s, n);
2062
- if (u.isRegExp(r))
2063
- return r.exec(s);
2064
- throw new TypeError("parser must be boolean|regexp|function");
2065
- }
2066
- }
2067
- }
2068
- has(t, r) {
2069
- if (t = de(t), t) {
2070
- const n = u.findKey(this, t);
2071
- return !!(n && this[n] !== void 0 && (!r || Xe(this, this[n], n, r)));
2072
- }
2073
- return !1;
2074
- }
2075
- delete(t, r) {
2076
- const n = this;
2077
- let s = !1;
2078
- function o(i) {
2079
- if (i = de(i), i) {
2080
- const c = u.findKey(n, i);
2081
- c && (!r || Xe(n, n[c], c, r)) && (delete n[c], s = !0);
2082
- }
2083
- }
2084
- return u.isArray(t) ? t.forEach(o) : o(t), s;
2085
- }
2086
- clear(t) {
2087
- const r = Object.keys(this);
2088
- let n = r.length, s = !1;
2089
- for (; n--; ) {
2090
- const o = r[n];
2091
- (!t || Xe(this, this[o], o, t, !0)) && (delete this[o], s = !0);
2092
- }
2093
- return s;
2094
- }
2095
- normalize(t) {
2096
- const r = this, n = {};
2097
- return u.forEach(this, (s, o) => {
2098
- const i = u.findKey(n, o);
2099
- if (i) {
2100
- r[i] = Ce(s), delete r[o];
2101
- return;
2102
- }
2103
- const c = t ? Cs(o) : String(o).trim();
2104
- c !== o && delete r[o], r[c] = Ce(s), n[c] = !0;
2105
- }), this;
2106
- }
2107
- concat(...t) {
2108
- return this.constructor.concat(this, ...t);
2109
- }
2110
- toJSON(t) {
2111
- const r = /* @__PURE__ */ Object.create(null);
2112
- return u.forEach(this, (n, s) => {
2113
- n != null && n !== !1 && (r[s] = t && u.isArray(n) ? n.join(", ") : n);
2114
- }), r;
2115
- }
2116
- [Symbol.iterator]() {
2117
- return Object.entries(this.toJSON())[Symbol.iterator]();
2118
- }
2119
- toString() {
2120
- return Object.entries(this.toJSON()).map(([t, r]) => t + ": " + r).join(`
2121
- `);
2122
- }
2123
- get [Symbol.toStringTag]() {
2124
- return "AxiosHeaders";
2125
- }
2126
- static from(t) {
2127
- return t instanceof this ? t : new this(t);
2128
- }
2129
- static concat(t, ...r) {
2130
- const n = new this(t);
2131
- return r.forEach((s) => n.set(s)), n;
2132
- }
2133
- static accessor(t) {
2134
- const n = (this[Qt] = this[Qt] = {
2135
- accessors: {}
2136
- }).accessors, s = this.prototype;
2137
- function o(i) {
2138
- const c = de(i);
2139
- n[c] || (As(s, i), n[c] = !0);
2140
- }
2141
- return u.isArray(t) ? t.forEach(o) : o(t), this;
2142
- }
2143
- }
2144
- Be.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
2145
- u.reduceDescriptors(Be.prototype, ({ value: e }, t) => {
2146
- let r = t[0].toUpperCase() + t.slice(1);
2147
- return {
2148
- get: () => e,
2149
- set(n) {
2150
- this[r] = n;
2151
- }
2152
- };
2153
- });
2154
- u.freezeMethods(Be);
2155
- const W = Be;
2156
- function Qe(e, t) {
2157
- const r = this || pt, n = t || r, s = W.from(n.headers);
2158
- let o = n.data;
2159
- return u.forEach(e, function(c) {
2160
- o = c.call(r, o, s.normalize(), t ? t.status : void 0);
2161
- }), s.normalize(), o;
2162
- }
2163
- function Pr(e) {
2164
- return !!(e && e.__CANCEL__);
2165
- }
2166
- function ye(e, t, r) {
2167
- x.call(this, e ?? "canceled", x.ERR_CANCELED, t, r), this.name = "CanceledError";
2168
- }
2169
- u.inherits(ye, x, {
2170
- __CANCEL__: !0
2171
- });
2172
- function js(e, t, r) {
2173
- const n = r.config.validateStatus;
2174
- !r.status || !n || n(r.status) ? e(r) : t(new x(
2175
- "Request failed with status code " + r.status,
2176
- [x.ERR_BAD_REQUEST, x.ERR_BAD_RESPONSE][Math.floor(r.status / 100) - 4],
2177
- r.config,
2178
- r.request,
2179
- r
2180
- ));
2181
- }
2182
- const Ns = B.hasStandardBrowserEnv ? (
2183
- // Standard browser envs support document.cookie
2184
- {
2185
- write(e, t, r, n, s, o) {
2186
- const i = [e + "=" + encodeURIComponent(t)];
2187
- u.isNumber(r) && i.push("expires=" + new Date(r).toGMTString()), u.isString(n) && i.push("path=" + n), u.isString(s) && i.push("domain=" + s), o === !0 && i.push("secure"), document.cookie = i.join("; ");
2188
- },
2189
- read(e) {
2190
- const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
2191
- return t ? decodeURIComponent(t[3]) : null;
2192
- },
2193
- remove(e) {
2194
- this.write(e, "", Date.now() - 864e5);
2195
- }
2196
- }
2197
- ) : (
2198
- // Non-standard browser env (web workers, react-native) lack needed support.
2199
- {
2200
- write() {
2201
- },
2202
- read() {
2203
- return null;
2204
- },
2205
- remove() {
2206
- }
2207
- }
2208
- );
2209
- function ks(e) {
2210
- return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
2211
- }
2212
- function Ds(e, t) {
2213
- return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
2214
- }
2215
- function Cr(e, t) {
2216
- return e && !ks(t) ? Ds(e, t) : t;
2217
- }
2218
- const Fs = B.hasStandardBrowserEnv ? (
2219
- // Standard browser envs have full support of the APIs needed to test
2220
- // whether the request URL is of the same origin as current location.
2221
- function() {
2222
- const t = /(msie|trident)/i.test(navigator.userAgent), r = document.createElement("a");
2223
- let n;
2224
- function s(o) {
2225
- let i = o;
2226
- return t && (r.setAttribute("href", i), i = r.href), r.setAttribute("href", i), {
2227
- href: r.href,
2228
- protocol: r.protocol ? r.protocol.replace(/:$/, "") : "",
2229
- host: r.host,
2230
- search: r.search ? r.search.replace(/^\?/, "") : "",
2231
- hash: r.hash ? r.hash.replace(/^#/, "") : "",
2232
- hostname: r.hostname,
2233
- port: r.port,
2234
- pathname: r.pathname.charAt(0) === "/" ? r.pathname : "/" + r.pathname
2235
- };
2236
- }
2237
- return n = s(window.location.href), function(i) {
2238
- const c = u.isString(i) ? s(i) : i;
2239
- return c.protocol === n.protocol && c.host === n.host;
2240
- };
2241
- }()
2242
- ) : (
2243
- // Non standard browser envs (web workers, react-native) lack needed support.
2244
- /* @__PURE__ */ function() {
2245
- return function() {
2246
- return !0;
2247
- };
2248
- }()
2249
- );
2250
- function Ms(e) {
2251
- const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
2252
- return t && t[1] || "";
2253
- }
2254
- function Ls(e, t) {
2255
- e = e || 10;
2256
- const r = new Array(e), n = new Array(e);
2257
- let s = 0, o = 0, i;
2258
- return t = t !== void 0 ? t : 1e3, function(l) {
2259
- const h = Date.now(), p = n[o];
2260
- i || (i = h), r[s] = l, n[s] = h;
2261
- let f = o, v = 0;
2262
- for (; f !== s; )
2263
- v += r[f++], f = f % e;
2264
- if (s = (s + 1) % e, s === o && (o = (o + 1) % e), h - i < t)
2265
- return;
2266
- const R = p && h - p;
2267
- return R ? Math.round(v * 1e3 / R) : void 0;
2268
- };
2269
- }
2270
- function Zt(e, t) {
2271
- let r = 0;
2272
- const n = Ls(50, 250);
2273
- return (s) => {
2274
- const o = s.loaded, i = s.lengthComputable ? s.total : void 0, c = o - r, l = n(c), h = o <= i;
2275
- r = o;
2276
- const p = {
2277
- loaded: o,
2278
- total: i,
2279
- progress: i ? o / i : void 0,
2280
- bytes: c,
2281
- rate: l || void 0,
2282
- estimated: l && i && h ? (i - o) / l : void 0,
2283
- event: s
2284
- };
2285
- p[t ? "download" : "upload"] = !0, e(p);
2286
- };
2287
- }
2288
- const zs = typeof XMLHttpRequest < "u", Us = zs && function(e) {
2289
- return new Promise(function(r, n) {
2290
- let s = e.data;
2291
- const o = W.from(e.headers).normalize();
2292
- let { responseType: i, withXSRFToken: c } = e, l;
2293
- function h() {
2294
- e.cancelToken && e.cancelToken.unsubscribe(l), e.signal && e.signal.removeEventListener("abort", l);
2295
- }
2296
- let p;
2297
- if (u.isFormData(s)) {
2298
- if (B.hasStandardBrowserEnv || B.hasStandardBrowserWebWorkerEnv)
2299
- o.setContentType(!1);
2300
- else if ((p = o.getContentType()) !== !1) {
2301
- const [y, ...j] = p ? p.split(";").map((_) => _.trim()).filter(Boolean) : [];
2302
- o.setContentType([y || "multipart/form-data", ...j].join("; "));
2303
- }
2304
- }
2305
- let f = new XMLHttpRequest();
2306
- if (e.auth) {
2307
- const y = e.auth.username || "", j = e.auth.password ? unescape(encodeURIComponent(e.auth.password)) : "";
2308
- o.set("Authorization", "Basic " + btoa(y + ":" + j));
2309
- }
2310
- const v = Cr(e.baseURL, e.url);
2311
- f.open(e.method.toUpperCase(), Rr(v, e.params, e.paramsSerializer), !0), f.timeout = e.timeout;
2312
- function R() {
2313
- if (!f)
2314
- return;
2315
- const y = W.from(
2316
- "getAllResponseHeaders" in f && f.getAllResponseHeaders()
2317
- ), _ = {
2318
- data: !i || i === "text" || i === "json" ? f.responseText : f.response,
2319
- status: f.status,
2320
- statusText: f.statusText,
2321
- headers: y,
2322
- config: e,
2323
- request: f
2324
- };
2325
- js(function(U) {
2326
- r(U), h();
2327
- }, function(U) {
2328
- n(U), h();
2329
- }, _), f = null;
2330
- }
2331
- if ("onloadend" in f ? f.onloadend = R : f.onreadystatechange = function() {
2332
- !f || f.readyState !== 4 || f.status === 0 && !(f.responseURL && f.responseURL.indexOf("file:") === 0) || setTimeout(R);
2333
- }, f.onabort = function() {
2334
- f && (n(new x("Request aborted", x.ECONNABORTED, e, f)), f = null);
2335
- }, f.onerror = function() {
2336
- n(new x("Network Error", x.ERR_NETWORK, e, f)), f = null;
2337
- }, f.ontimeout = function() {
2338
- let j = e.timeout ? "timeout of " + e.timeout + "ms exceeded" : "timeout exceeded";
2339
- const _ = e.transitional || Sr;
2340
- e.timeoutErrorMessage && (j = e.timeoutErrorMessage), n(new x(
2341
- j,
2342
- _.clarifyTimeoutError ? x.ETIMEDOUT : x.ECONNABORTED,
2343
- e,
2344
- f
2345
- )), f = null;
2346
- }, B.hasStandardBrowserEnv && (c && u.isFunction(c) && (c = c(e)), c || c !== !1 && Fs(v))) {
2347
- const y = e.xsrfHeaderName && e.xsrfCookieName && Ns.read(e.xsrfCookieName);
2348
- y && o.set(e.xsrfHeaderName, y);
2349
- }
2350
- s === void 0 && o.setContentType(null), "setRequestHeader" in f && u.forEach(o.toJSON(), function(j, _) {
2351
- f.setRequestHeader(_, j);
2352
- }), u.isUndefined(e.withCredentials) || (f.withCredentials = !!e.withCredentials), i && i !== "json" && (f.responseType = e.responseType), typeof e.onDownloadProgress == "function" && f.addEventListener("progress", Zt(e.onDownloadProgress, !0)), typeof e.onUploadProgress == "function" && f.upload && f.upload.addEventListener("progress", Zt(e.onUploadProgress)), (e.cancelToken || e.signal) && (l = (y) => {
2353
- f && (n(!y || y.type ? new ye(null, e, f) : y), f.abort(), f = null);
2354
- }, e.cancelToken && e.cancelToken.subscribe(l), e.signal && (e.signal.aborted ? l() : e.signal.addEventListener("abort", l)));
2355
- const g = Ms(v);
2356
- if (g && B.protocols.indexOf(g) === -1) {
2357
- n(new x("Unsupported protocol " + g + ":", x.ERR_BAD_REQUEST, e));
2358
- return;
2359
- }
2360
- f.send(s || null);
2361
- });
2362
- }, it = {
2363
- http: us,
2364
- xhr: Us
2365
- };
2366
- u.forEach(it, (e, t) => {
2367
- if (e) {
2368
- try {
2369
- Object.defineProperty(e, "name", { value: t });
2370
- } catch {
2371
- }
2372
- Object.defineProperty(e, "adapterName", { value: t });
2373
- }
2374
- });
2375
- const er = (e) => `- ${e}`, Bs = (e) => u.isFunction(e) || e === null || e === !1, Ar = {
2376
- getAdapter: (e) => {
2377
- e = u.isArray(e) ? e : [e];
2378
- const { length: t } = e;
2379
- let r, n;
2380
- const s = {};
2381
- for (let o = 0; o < t; o++) {
2382
- r = e[o];
2383
- let i;
2384
- if (n = r, !Bs(r) && (n = it[(i = String(r)).toLowerCase()], n === void 0))
2385
- throw new x(`Unknown adapter '${i}'`);
2386
- if (n)
2387
- break;
2388
- s[i || "#" + o] = n;
2389
- }
2390
- if (!n) {
2391
- const o = Object.entries(s).map(
2392
- ([c, l]) => `adapter ${c} ` + (l === !1 ? "is not supported by the environment" : "is not available in the build")
2393
- );
2394
- let i = t ? o.length > 1 ? `since :
2395
- ` + o.map(er).join(`
2396
- `) : " " + er(o[0]) : "as no adapter specified";
2397
- throw new x(
2398
- "There is no suitable adapter to dispatch the request " + i,
2399
- "ERR_NOT_SUPPORT"
2400
- );
2401
- }
2402
- return n;
2403
- },
2404
- adapters: it
2405
- };
2406
- function Ze(e) {
2407
- if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
2408
- throw new ye(null, e);
2409
- }
2410
- function tr(e) {
2411
- return Ze(e), e.headers = W.from(e.headers), e.data = Qe.call(
2412
- e,
2413
- e.transformRequest
2414
- ), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Ar.getAdapter(e.adapter || pt.adapter)(e).then(function(n) {
2415
- return Ze(e), n.data = Qe.call(
2416
- e,
2417
- e.transformResponse,
2418
- n
2419
- ), n.headers = W.from(n.headers), n;
2420
- }, function(n) {
2421
- return Pr(n) || (Ze(e), n && n.response && (n.response.data = Qe.call(
2422
- e,
2423
- e.transformResponse,
2424
- n.response
2425
- ), n.response.headers = W.from(n.response.headers))), Promise.reject(n);
2426
- });
2427
- }
2428
- const rr = (e) => e instanceof W ? { ...e } : e;
2429
- function oe(e, t) {
2430
- t = t || {};
2431
- const r = {};
2432
- function n(h, p, f) {
2433
- return u.isPlainObject(h) && u.isPlainObject(p) ? u.merge.call({ caseless: f }, h, p) : u.isPlainObject(p) ? u.merge({}, p) : u.isArray(p) ? p.slice() : p;
2434
- }
2435
- function s(h, p, f) {
2436
- if (u.isUndefined(p)) {
2437
- if (!u.isUndefined(h))
2438
- return n(void 0, h, f);
2439
- } else
2440
- return n(h, p, f);
2441
- }
2442
- function o(h, p) {
2443
- if (!u.isUndefined(p))
2444
- return n(void 0, p);
2445
- }
2446
- function i(h, p) {
2447
- if (u.isUndefined(p)) {
2448
- if (!u.isUndefined(h))
2449
- return n(void 0, h);
2450
- } else
2451
- return n(void 0, p);
2452
- }
2453
- function c(h, p, f) {
2454
- if (f in t)
2455
- return n(h, p);
2456
- if (f in e)
2457
- return n(void 0, h);
2458
- }
2459
- const l = {
2460
- url: o,
2461
- method: o,
2462
- data: o,
2463
- baseURL: i,
2464
- transformRequest: i,
2465
- transformResponse: i,
2466
- paramsSerializer: i,
2467
- timeout: i,
2468
- timeoutMessage: i,
2469
- withCredentials: i,
2470
- withXSRFToken: i,
2471
- adapter: i,
2472
- responseType: i,
2473
- xsrfCookieName: i,
2474
- xsrfHeaderName: i,
2475
- onUploadProgress: i,
2476
- onDownloadProgress: i,
2477
- decompress: i,
2478
- maxContentLength: i,
2479
- maxBodyLength: i,
2480
- beforeRedirect: i,
2481
- transport: i,
2482
- httpAgent: i,
2483
- httpsAgent: i,
2484
- cancelToken: i,
2485
- socketPath: i,
2486
- responseEncoding: i,
2487
- validateStatus: c,
2488
- headers: (h, p) => s(rr(h), rr(p), !0)
2489
- };
2490
- return u.forEach(Object.keys(Object.assign({}, e, t)), function(p) {
2491
- const f = l[p] || s, v = f(e[p], t[p], p);
2492
- u.isUndefined(v) && f !== c || (r[p] = v);
2493
- }), r;
2494
- }
2495
- const jr = "1.6.8", ht = {};
2496
- ["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
2497
- ht[e] = function(n) {
2498
- return typeof n === e || "a" + (t < 1 ? "n " : " ") + e;
2499
- };
2500
- });
2501
- const nr = {};
2502
- ht.transitional = function(t, r, n) {
2503
- function s(o, i) {
2504
- return "[Axios v" + jr + "] Transitional option '" + o + "'" + i + (n ? ". " + n : "");
2505
- }
2506
- return (o, i, c) => {
2507
- if (t === !1)
2508
- throw new x(
2509
- s(i, " has been removed" + (r ? " in " + r : "")),
2510
- x.ERR_DEPRECATED
2511
- );
2512
- return r && !nr[i] && (nr[i] = !0, console.warn(
2513
- s(
2514
- i,
2515
- " has been deprecated since v" + r + " and will be removed in the near future"
2516
- )
2517
- )), t ? t(o, i, c) : !0;
2518
- };
2519
- };
2520
- function Is(e, t, r) {
2521
- if (typeof e != "object")
2522
- throw new x("options must be an object", x.ERR_BAD_OPTION_VALUE);
2523
- const n = Object.keys(e);
2524
- let s = n.length;
2525
- for (; s-- > 0; ) {
2526
- const o = n[s], i = t[o];
2527
- if (i) {
2528
- const c = e[o], l = c === void 0 || i(c, o, e);
2529
- if (l !== !0)
2530
- throw new x("option " + o + " must be " + l, x.ERR_BAD_OPTION_VALUE);
2531
- continue;
2532
- }
2533
- if (r !== !0)
2534
- throw new x("Unknown option " + o, x.ERR_BAD_OPTION);
2535
- }
2536
- }
2537
- const at = {
2538
- assertOptions: Is,
2539
- validators: ht
2540
- }, K = at.validators;
2541
- class De {
2542
- constructor(t) {
2543
- this.defaults = t, this.interceptors = {
2544
- request: new Xt(),
2545
- response: new Xt()
2546
- };
2547
- }
2548
- /**
2549
- * Dispatch a request
2550
- *
2551
- * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
2552
- * @param {?Object} config
2553
- *
2554
- * @returns {Promise} The Promise to be fulfilled
2555
- */
2556
- async request(t, r) {
2557
- try {
2558
- return await this._request(t, r);
2559
- } catch (n) {
2560
- if (n instanceof Error) {
2561
- let s;
2562
- Error.captureStackTrace ? Error.captureStackTrace(s = {}) : s = new Error();
2563
- const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
2564
- n.stack ? o && !String(n.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (n.stack += `
2565
- ` + o) : n.stack = o;
2566
- }
2567
- throw n;
2568
- }
2569
- }
2570
- _request(t, r) {
2571
- typeof t == "string" ? (r = r || {}, r.url = t) : r = t || {}, r = oe(this.defaults, r);
2572
- const { transitional: n, paramsSerializer: s, headers: o } = r;
2573
- n !== void 0 && at.assertOptions(n, {
2574
- silentJSONParsing: K.transitional(K.boolean),
2575
- forcedJSONParsing: K.transitional(K.boolean),
2576
- clarifyTimeoutError: K.transitional(K.boolean)
2577
- }, !1), s != null && (u.isFunction(s) ? r.paramsSerializer = {
2578
- serialize: s
2579
- } : at.assertOptions(s, {
2580
- encode: K.function,
2581
- serialize: K.function
2582
- }, !0)), r.method = (r.method || this.defaults.method || "get").toLowerCase();
2583
- let i = o && u.merge(
2584
- o.common,
2585
- o[r.method]
2586
- );
2587
- o && u.forEach(
2588
- ["delete", "get", "head", "post", "put", "patch", "common"],
2589
- (g) => {
2590
- delete o[g];
2591
- }
2592
- ), r.headers = W.concat(i, o);
2593
- const c = [];
2594
- let l = !0;
2595
- this.interceptors.request.forEach(function(y) {
2596
- typeof y.runWhen == "function" && y.runWhen(r) === !1 || (l = l && y.synchronous, c.unshift(y.fulfilled, y.rejected));
2597
- });
2598
- const h = [];
2599
- this.interceptors.response.forEach(function(y) {
2600
- h.push(y.fulfilled, y.rejected);
2601
- });
2602
- let p, f = 0, v;
2603
- if (!l) {
2604
- const g = [tr.bind(this), void 0];
2605
- for (g.unshift.apply(g, c), g.push.apply(g, h), v = g.length, p = Promise.resolve(r); f < v; )
2606
- p = p.then(g[f++], g[f++]);
2607
- return p;
2608
- }
2609
- v = c.length;
2610
- let R = r;
2611
- for (f = 0; f < v; ) {
2612
- const g = c[f++], y = c[f++];
2613
- try {
2614
- R = g(R);
2615
- } catch (j) {
2616
- y.call(this, j);
2617
- break;
2618
- }
2619
- }
2620
- try {
2621
- p = tr.call(this, R);
2622
- } catch (g) {
2623
- return Promise.reject(g);
2624
- }
2625
- for (f = 0, v = h.length; f < v; )
2626
- p = p.then(h[f++], h[f++]);
2627
- return p;
2628
- }
2629
- getUri(t) {
2630
- t = oe(this.defaults, t);
2631
- const r = Cr(t.baseURL, t.url);
2632
- return Rr(r, t.params, t.paramsSerializer);
2633
- }
2634
- }
2635
- u.forEach(["delete", "get", "head", "options"], function(t) {
2636
- De.prototype[t] = function(r, n) {
2637
- return this.request(oe(n || {}, {
2638
- method: t,
2639
- url: r,
2640
- data: (n || {}).data
2641
- }));
2642
- };
2643
- });
2644
- u.forEach(["post", "put", "patch"], function(t) {
2645
- function r(n) {
2646
- return function(o, i, c) {
2647
- return this.request(oe(c || {}, {
2648
- method: t,
2649
- headers: n ? {
2650
- "Content-Type": "multipart/form-data"
2651
- } : {},
2652
- url: o,
2653
- data: i
2654
- }));
2655
- };
2656
- }
2657
- De.prototype[t] = r(), De.prototype[t + "Form"] = r(!0);
2658
- });
2659
- const Ae = De;
2660
- class mt {
2661
- constructor(t) {
2662
- if (typeof t != "function")
2663
- throw new TypeError("executor must be a function.");
2664
- let r;
2665
- this.promise = new Promise(function(o) {
2666
- r = o;
2667
- });
2668
- const n = this;
2669
- this.promise.then((s) => {
2670
- if (!n._listeners)
2671
- return;
2672
- let o = n._listeners.length;
2673
- for (; o-- > 0; )
2674
- n._listeners[o](s);
2675
- n._listeners = null;
2676
- }), this.promise.then = (s) => {
2677
- let o;
2678
- const i = new Promise((c) => {
2679
- n.subscribe(c), o = c;
2680
- }).then(s);
2681
- return i.cancel = function() {
2682
- n.unsubscribe(o);
2683
- }, i;
2684
- }, t(function(o, i, c) {
2685
- n.reason || (n.reason = new ye(o, i, c), r(n.reason));
2686
- });
2687
- }
2688
- /**
2689
- * Throws a `CanceledError` if cancellation has been requested.
2690
- */
2691
- throwIfRequested() {
2692
- if (this.reason)
2693
- throw this.reason;
2694
- }
2695
- /**
2696
- * Subscribe to the cancel signal
2697
- */
2698
- subscribe(t) {
2699
- if (this.reason) {
2700
- t(this.reason);
2701
- return;
2702
- }
2703
- this._listeners ? this._listeners.push(t) : this._listeners = [t];
2704
- }
2705
- /**
2706
- * Unsubscribe from the cancel signal
2707
- */
2708
- unsubscribe(t) {
2709
- if (!this._listeners)
2710
- return;
2711
- const r = this._listeners.indexOf(t);
2712
- r !== -1 && this._listeners.splice(r, 1);
2713
- }
2714
- /**
2715
- * Returns an object that contains a new `CancelToken` and a function that, when called,
2716
- * cancels the `CancelToken`.
2717
- */
2718
- static source() {
2719
- let t;
2720
- return {
2721
- token: new mt(function(s) {
2722
- t = s;
2723
- }),
2724
- cancel: t
2725
- };
2726
- }
2727
- }
2728
- const Hs = mt;
2729
- function $s(e) {
2730
- return function(r) {
2731
- return e.apply(null, r);
2732
- };
2733
- }
2734
- function Vs(e) {
2735
- return u.isObject(e) && e.isAxiosError === !0;
2736
- }
2737
- const ct = {
2738
- Continue: 100,
2739
- SwitchingProtocols: 101,
2740
- Processing: 102,
2741
- EarlyHints: 103,
2742
- Ok: 200,
2743
- Created: 201,
2744
- Accepted: 202,
2745
- NonAuthoritativeInformation: 203,
2746
- NoContent: 204,
2747
- ResetContent: 205,
2748
- PartialContent: 206,
2749
- MultiStatus: 207,
2750
- AlreadyReported: 208,
2751
- ImUsed: 226,
2752
- MultipleChoices: 300,
2753
- MovedPermanently: 301,
2754
- Found: 302,
2755
- SeeOther: 303,
2756
- NotModified: 304,
2757
- UseProxy: 305,
2758
- Unused: 306,
2759
- TemporaryRedirect: 307,
2760
- PermanentRedirect: 308,
2761
- BadRequest: 400,
2762
- Unauthorized: 401,
2763
- PaymentRequired: 402,
2764
- Forbidden: 403,
2765
- NotFound: 404,
2766
- MethodNotAllowed: 405,
2767
- NotAcceptable: 406,
2768
- ProxyAuthenticationRequired: 407,
2769
- RequestTimeout: 408,
2770
- Conflict: 409,
2771
- Gone: 410,
2772
- LengthRequired: 411,
2773
- PreconditionFailed: 412,
2774
- PayloadTooLarge: 413,
2775
- UriTooLong: 414,
2776
- UnsupportedMediaType: 415,
2777
- RangeNotSatisfiable: 416,
2778
- ExpectationFailed: 417,
2779
- ImATeapot: 418,
2780
- MisdirectedRequest: 421,
2781
- UnprocessableEntity: 422,
2782
- Locked: 423,
2783
- FailedDependency: 424,
2784
- TooEarly: 425,
2785
- UpgradeRequired: 426,
2786
- PreconditionRequired: 428,
2787
- TooManyRequests: 429,
2788
- RequestHeaderFieldsTooLarge: 431,
2789
- UnavailableForLegalReasons: 451,
2790
- InternalServerError: 500,
2791
- NotImplemented: 501,
2792
- BadGateway: 502,
2793
- ServiceUnavailable: 503,
2794
- GatewayTimeout: 504,
2795
- HttpVersionNotSupported: 505,
2796
- VariantAlsoNegotiates: 506,
2797
- InsufficientStorage: 507,
2798
- LoopDetected: 508,
2799
- NotExtended: 510,
2800
- NetworkAuthenticationRequired: 511
2801
- };
2802
- Object.entries(ct).forEach(([e, t]) => {
2803
- ct[t] = e;
2804
- });
2805
- const qs = ct;
2806
- function Nr(e) {
2807
- const t = new Ae(e), r = dr(Ae.prototype.request, t);
2808
- return u.extend(r, Ae.prototype, t, { allOwnKeys: !0 }), u.extend(r, t, null, { allOwnKeys: !0 }), r.create = function(s) {
2809
- return Nr(oe(e, s));
2810
- }, r;
2811
- }
2812
- const P = Nr(pt);
2813
- P.Axios = Ae;
2814
- P.CanceledError = ye;
2815
- P.CancelToken = Hs;
2816
- P.isCancel = Pr;
2817
- P.VERSION = jr;
2818
- P.toFormData = Ue;
2819
- P.AxiosError = x;
2820
- P.Cancel = P.CanceledError;
2821
- P.all = function(t) {
2822
- return Promise.all(t);
2823
- };
2824
- P.spread = $s;
2825
- P.isAxiosError = Vs;
2826
- P.mergeConfig = oe;
2827
- P.AxiosHeaders = W;
2828
- P.formToJSON = (e) => _r(u.isHTMLForm(e) ? new FormData(e) : e);
2829
- P.getAdapter = Ar.getAdapter;
2830
- P.HttpStatusCode = qs;
2831
- P.default = P;
2832
- const fi = P.CancelToken, di = (e = !0) => {
2833
- const { axiosInstance: t, language: r, axiosTexts: n } = or(cr), { addNotification: s } = Co(), { getToken: o } = Eo();
2834
- return lt(() => {
2835
- t.interceptors.request.clear(), t.interceptors.response.clear();
2836
- const i = t.interceptors.request.use((l) => {
2837
- var h, p, f;
2838
- return e && !l.headers.Authorization && (l.headers.Authorization = `Bearer ${o()}`), (h = l.url) != null && h.includes("culture=") ? l.url = (p = l.url) == null ? void 0 : p.replace(/culture=[a-z]{2}/, `culture=${r}`) : l.url = `${l.url}${(f = l.url) != null && f.includes("?") ? "&" : "?"}culture=${r}`, l;
2839
- }, (l) => Promise.reject(l)), c = t.interceptors.response.use((l) => l, (l) => {
2840
- if (P.isCancel(l))
2841
- return Promise.reject(l);
2842
- const h = pn(l);
2843
- if (h.length > 0) {
2844
- const p = h.find((f) => f.name.toLowerCase() === "others");
2845
- return p ? (s(p.errors, "danger"), Promise.reject(l)) : (s(n.validationError, "warning"), Promise.reject(l));
2846
- }
2847
- return l.message && l.message === "Network Error" ? (s(n.networkError, "danger"), Promise.reject(l)) : (P.isCancel(l) || s(n.unexpectedError, "danger"), Promise.reject(l));
2848
- });
2849
- return () => {
2850
- t.interceptors.request.eject(i), t.interceptors.response.eject(c);
2851
- };
2852
- }, [t, s, r, o, e, n]), t;
2853
- };
2854
- export {
2855
- ci as C,
2856
- k as G,
2857
- ii as I,
2858
- cr as L,
2859
- ri as M,
2860
- ai as P,
2861
- ui as U,
2862
- Co as a,
2863
- di as b,
2864
- fi as c,
2865
- ue as d,
2866
- li as e,
2867
- ti as f,
2868
- hn as g,
2869
- Ks as h,
2870
- An as i,
2871
- Y as j,
2872
- Gs as k,
2873
- ei as l,
2874
- Zs as m,
2875
- Xs as n,
2876
- Qs as o,
2877
- Cn as p,
2878
- ni as q,
2879
- oi as r,
2880
- Ys as s,
2881
- si as t,
2882
- Eo as u
2883
- };