@vtj/utils 0.17.5 → 0.17.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,9 +1,9 @@
1
- var Dt = Object.defineProperty;
2
- var Bt = (t, e, n) => e in t ? Dt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
- var C = (t, e, n) => Bt(t, typeof e != "symbol" ? e + "" : e, n);
4
- import { omit as me, merge as W, debounce as vt, throttle as It, isUrl as qe, pathToRegexpCompile as qt, uuid as Mt, rURL as Ht, template as $t } from "@vtj/base";
1
+ var Wt = Object.defineProperty;
2
+ var Vt = (t, e, n) => e in t ? Wt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
+ var L = (t, e, n) => Vt(t, typeof e != "symbol" ? e + "" : e, n);
4
+ import { omit as Te, merge as ee, debounce as Kt, throttle as Xt, isUrl as Ye, pathToRegexpCompile as Gt, uuid as Qt, rURL as Yt, template as Zt } from "@vtj/base";
5
5
  export * from "@vtj/base";
6
- import { ref as ge } from "vue";
6
+ import { ref as xe } from "vue";
7
7
  (function() {
8
8
  if (typeof window > "u" || typeof EventTarget > "u")
9
9
  return;
@@ -16,168 +16,178 @@ import { ref as ge } from "vue";
16
16
  * Copyright (c) 2026, VTJ.PRO All rights reserved.
17
17
  * @name @vtj/utils
18
18
  * @author CHC chenhuachun1549@dingtalk.com
19
- * @version 0.17.5
19
+ * @version 0.17.7
20
20
  * @license <a href="https://vtj.pro/license.html">MIT License</a>
21
21
  */
22
- const es = "0.17.5";
23
- function ct(t, e) {
22
+ const Oo = "0.17.7";
23
+ function gt(t, e) {
24
24
  return function() {
25
25
  return t.apply(e, arguments);
26
26
  };
27
27
  }
28
- const { toString: Jt } = Object.prototype, { getPrototypeOf: Ce } = Object, { iterator: ce, toStringTag: lt } = Symbol, le = /* @__PURE__ */ ((t) => (e) => {
29
- const n = Jt.call(e);
28
+ const { toString: en } = Object.prototype, { getPrototypeOf: ge } = Object, { iterator: we, toStringTag: wt } = Symbol, be = /* @__PURE__ */ ((t) => (e) => {
29
+ const n = en.call(e);
30
30
  return t[n] || (t[n] = n.slice(8, -1).toLowerCase());
31
- })(/* @__PURE__ */ Object.create(null)), U = (t) => (t = t.toLowerCase(), (e) => le(e) === t), ue = (t) => (e) => typeof e === t, { isArray: H } = Array, M = ue("undefined");
32
- function K(t) {
33
- return t !== null && !M(t) && t.constructor !== null && !M(t.constructor) && x(t.constructor.isBuffer) && t.constructor.isBuffer(t);
31
+ })(/* @__PURE__ */ Object.create(null)), U = (t) => (t = t.toLowerCase(), (e) => be(e) === t), Ee = (t) => (e) => typeof e === t, { isArray: X } = Array, K = Ee("undefined");
32
+ function re(t) {
33
+ return t !== null && !K(t) && t.constructor !== null && !K(t.constructor) && C(t.constructor.isBuffer) && t.constructor.isBuffer(t);
34
34
  }
35
- const ut = U("ArrayBuffer");
36
- function Wt(t) {
35
+ const bt = U("ArrayBuffer");
36
+ function tn(t) {
37
37
  let e;
38
- return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(t) : e = t && t.buffer && ut(t.buffer), e;
38
+ return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(t) : e = t && t.buffer && bt(t.buffer), e;
39
39
  }
40
- const zt = ue("string"), x = ue("function"), ft = ue("number"), X = (t) => t !== null && typeof t == "object", Vt = (t) => t === !0 || t === !1, se = (t) => {
41
- if (le(t) !== "object")
40
+ const nn = Ee("string"), C = Ee("function"), Et = Ee("number"), oe = (t) => t !== null && typeof t == "object", rn = (t) => t === !0 || t === !1, pe = (t) => {
41
+ if (be(t) !== "object")
42
42
  return !1;
43
- const e = Ce(t);
44
- return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(lt in t) && !(ce in t);
45
- }, Kt = (t) => {
46
- if (!X(t) || K(t))
43
+ const e = ge(t);
44
+ return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(wt in t) && !(we in t);
45
+ }, on = (t) => {
46
+ if (!oe(t) || re(t))
47
47
  return !1;
48
48
  try {
49
49
  return Object.keys(t).length === 0 && Object.getPrototypeOf(t) === Object.prototype;
50
50
  } catch {
51
51
  return !1;
52
52
  }
53
- }, Xt = U("Date"), Gt = U("File"), Qt = (t) => !!(t && typeof t.uri < "u"), Yt = (t) => t && typeof t.getParts < "u", Zt = U("Blob"), en = U("FileList"), tn = (t) => X(t) && x(t.pipe);
54
- function nn() {
53
+ }, sn = U("Date"), an = U("File"), cn = (t) => !!(t && typeof t.uri < "u"), ln = (t) => t && typeof t.getParts < "u", un = U("Blob"), fn = U("FileList"), dn = (t) => oe(t) && C(t.pipe);
54
+ function pn() {
55
55
  return typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : typeof global < "u" ? global : {};
56
56
  }
57
- const Me = nn(), He = typeof Me.FormData < "u" ? Me.FormData : void 0, rn = (t) => {
58
- let e;
59
- return t && (He && t instanceof He || x(t.append) && ((e = le(t)) === "formdata" || // detect form-data instance
60
- e === "object" && x(t.toString) && t.toString() === "[object FormData]"));
61
- }, sn = U("URLSearchParams"), [on, an, cn, ln] = [
57
+ const Ze = pn(), et = typeof Ze.FormData < "u" ? Ze.FormData : void 0, hn = (t) => {
58
+ if (!t) return !1;
59
+ if (et && t instanceof et) return !0;
60
+ const e = ge(t);
61
+ if (!e || e === Object.prototype || !C(t.append)) return !1;
62
+ const n = be(t);
63
+ return n === "formdata" || // detect form-data instance
64
+ n === "object" && C(t.toString) && t.toString() === "[object FormData]";
65
+ }, mn = U("URLSearchParams"), [yn, gn, wn, bn] = [
62
66
  "ReadableStream",
63
67
  "Request",
64
68
  "Response",
65
69
  "Headers"
66
- ].map(U), un = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
67
- function G(t, e, { allOwnKeys: n = !1 } = {}) {
70
+ ].map(U), En = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
71
+ function se(t, e, { allOwnKeys: n = !1 } = {}) {
68
72
  if (t === null || typeof t > "u")
69
73
  return;
70
- let r, s;
71
- if (typeof t != "object" && (t = [t]), H(t))
72
- for (r = 0, s = t.length; r < s; r++)
74
+ let r, o;
75
+ if (typeof t != "object" && (t = [t]), X(t))
76
+ for (r = 0, o = t.length; r < o; r++)
73
77
  e.call(null, t[r], r, t);
74
78
  else {
75
- if (K(t))
79
+ if (re(t))
76
80
  return;
77
- const o = n ? Object.getOwnPropertyNames(t) : Object.keys(t), i = o.length;
81
+ const s = n ? Object.getOwnPropertyNames(t) : Object.keys(t), i = s.length;
78
82
  let a;
79
83
  for (r = 0; r < i; r++)
80
- a = o[r], e.call(null, t[a], a, t);
84
+ a = s[r], e.call(null, t[a], a, t);
81
85
  }
82
86
  }
83
- function dt(t, e) {
84
- if (K(t))
87
+ function Rt(t, e) {
88
+ if (re(t))
85
89
  return null;
86
90
  e = e.toLowerCase();
87
91
  const n = Object.keys(t);
88
- let r = n.length, s;
92
+ let r = n.length, o;
89
93
  for (; r-- > 0; )
90
- if (s = n[r], e === s.toLowerCase())
91
- return s;
94
+ if (o = n[r], e === o.toLowerCase())
95
+ return o;
92
96
  return null;
93
97
  }
94
- const B = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, pt = (t) => !M(t) && t !== B;
95
- function Se() {
96
- const { caseless: t, skipUndefined: e } = pt(this) && this || {}, n = {}, r = (s, o) => {
97
- if (o === "__proto__" || o === "constructor" || o === "prototype")
98
+ const $ = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Ot = (t) => !K(t) && t !== $;
99
+ function Ue(...t) {
100
+ const { caseless: e, skipUndefined: n } = Ot(this) && this || {}, r = {}, o = (s, i) => {
101
+ if (i === "__proto__" || i === "constructor" || i === "prototype")
98
102
  return;
99
- const i = t && dt(n, o) || o;
100
- se(n[i]) && se(s) ? n[i] = Se(n[i], s) : se(s) ? n[i] = Se({}, s) : H(s) ? n[i] = s.slice() : (!e || !M(s)) && (n[i] = s);
103
+ const a = e && Rt(r, i) || i, l = Fe(r, a) ? r[a] : void 0;
104
+ pe(l) && pe(s) ? r[a] = Ue(l, s) : pe(s) ? r[a] = Ue({}, s) : X(s) ? r[a] = s.slice() : (!n || !K(s)) && (r[a] = s);
101
105
  };
102
- for (let s = 0, o = arguments.length; s < o; s++)
103
- arguments[s] && G(arguments[s], r);
104
- return n;
106
+ for (let s = 0, i = t.length; s < i; s++)
107
+ t[s] && se(t[s], o);
108
+ return r;
105
109
  }
106
- const fn = (t, e, n, { allOwnKeys: r } = {}) => (G(
110
+ const Rn = (t, e, n, { allOwnKeys: r } = {}) => (se(
107
111
  e,
108
- (s, o) => {
109
- n && x(s) ? Object.defineProperty(t, o, {
110
- value: ct(s, n),
112
+ (o, s) => {
113
+ n && C(o) ? Object.defineProperty(t, s, {
114
+ // Null-proto descriptor so a polluted Object.prototype.get cannot
115
+ // hijack defineProperty's accessor-vs-data resolution.
116
+ __proto__: null,
117
+ value: gt(o, n),
111
118
  writable: !0,
112
119
  enumerable: !0,
113
120
  configurable: !0
114
- }) : Object.defineProperty(t, o, {
115
- value: s,
121
+ }) : Object.defineProperty(t, s, {
122
+ __proto__: null,
123
+ value: o,
116
124
  writable: !0,
117
125
  enumerable: !0,
118
126
  configurable: !0
119
127
  });
120
128
  },
121
129
  { allOwnKeys: r }
122
- ), t), dn = (t) => (t.charCodeAt(0) === 65279 && (t = t.slice(1)), t), pn = (t, e, n, r) => {
130
+ ), t), On = (t) => (t.charCodeAt(0) === 65279 && (t = t.slice(1)), t), Sn = (t, e, n, r) => {
123
131
  t.prototype = Object.create(e.prototype, r), Object.defineProperty(t.prototype, "constructor", {
132
+ __proto__: null,
124
133
  value: t,
125
134
  writable: !0,
126
135
  enumerable: !1,
127
136
  configurable: !0
128
137
  }), Object.defineProperty(t, "super", {
138
+ __proto__: null,
129
139
  value: e.prototype
130
140
  }), n && Object.assign(t.prototype, n);
131
- }, hn = (t, e, n, r) => {
132
- let s, o, i;
141
+ }, _n = (t, e, n, r) => {
142
+ let o, s, i;
133
143
  const a = {};
134
144
  if (e = e || {}, t == null) return e;
135
145
  do {
136
- for (s = Object.getOwnPropertyNames(t), o = s.length; o-- > 0; )
137
- i = s[o], (!r || r(i, t, e)) && !a[i] && (e[i] = t[i], a[i] = !0);
138
- t = n !== !1 && Ce(t);
146
+ for (o = Object.getOwnPropertyNames(t), s = o.length; s-- > 0; )
147
+ i = o[s], (!r || r(i, t, e)) && !a[i] && (e[i] = t[i], a[i] = !0);
148
+ t = n !== !1 && ge(t);
139
149
  } while (t && (!n || n(t, e)) && t !== Object.prototype);
140
150
  return e;
141
- }, mn = (t, e, n) => {
151
+ }, An = (t, e, n) => {
142
152
  t = String(t), (n === void 0 || n > t.length) && (n = t.length), n -= e.length;
143
153
  const r = t.indexOf(e, n);
144
154
  return r !== -1 && r === n;
145
- }, gn = (t) => {
155
+ }, Tn = (t) => {
146
156
  if (!t) return null;
147
- if (H(t)) return t;
157
+ if (X(t)) return t;
148
158
  let e = t.length;
149
- if (!ft(e)) return null;
159
+ if (!Et(e)) return null;
150
160
  const n = new Array(e);
151
161
  for (; e-- > 0; )
152
162
  n[e] = t[e];
153
163
  return n;
154
- }, yn = /* @__PURE__ */ ((t) => (e) => t && e instanceof t)(typeof Uint8Array < "u" && Ce(Uint8Array)), wn = (t, e) => {
155
- const r = (t && t[ce]).call(t);
156
- let s;
157
- for (; (s = r.next()) && !s.done; ) {
158
- const o = s.value;
159
- e.call(t, o[0], o[1]);
164
+ }, xn = /* @__PURE__ */ ((t) => (e) => t && e instanceof t)(typeof Uint8Array < "u" && ge(Uint8Array)), Cn = (t, e) => {
165
+ const r = (t && t[we]).call(t);
166
+ let o;
167
+ for (; (o = r.next()) && !o.done; ) {
168
+ const s = o.value;
169
+ e.call(t, s[0], s[1]);
160
170
  }
161
- }, bn = (t, e) => {
171
+ }, Pn = (t, e) => {
162
172
  let n;
163
173
  const r = [];
164
174
  for (; (n = t.exec(e)) !== null; )
165
175
  r.push(n);
166
176
  return r;
167
- }, Rn = U("HTMLFormElement"), En = (t) => t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function(n, r, s) {
168
- return r.toUpperCase() + s;
169
- }), $e = (({ hasOwnProperty: t }) => (e, n) => t.call(e, n))(Object.prototype), Sn = U("RegExp"), ht = (t, e) => {
177
+ }, Ln = U("HTMLFormElement"), Nn = (t) => t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function(n, r, o) {
178
+ return r.toUpperCase() + o;
179
+ }), Fe = (({ hasOwnProperty: t }) => (e, n) => t.call(e, n))(Object.prototype), Dn = U("RegExp"), St = (t, e) => {
170
180
  const n = Object.getOwnPropertyDescriptors(t), r = {};
171
- G(n, (s, o) => {
181
+ se(n, (o, s) => {
172
182
  let i;
173
- (i = e(s, o, t)) !== !1 && (r[o] = i || s);
183
+ (i = e(o, s, t)) !== !1 && (r[s] = i || o);
174
184
  }), Object.defineProperties(t, r);
175
- }, On = (t) => {
176
- ht(t, (e, n) => {
177
- if (x(t) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
185
+ }, Un = (t) => {
186
+ St(t, (e, n) => {
187
+ if (C(t) && ["arguments", "caller", "callee"].includes(n))
178
188
  return !1;
179
189
  const r = t[n];
180
- if (x(r)) {
190
+ if (C(r)) {
181
191
  if (e.enumerable = !1, "writable" in e) {
182
192
  e.writable = !1;
183
193
  return;
@@ -187,110 +197,384 @@ const fn = (t, e, n, { allOwnKeys: r } = {}) => (G(
187
197
  });
188
198
  }
189
199
  });
190
- }, Tn = (t, e) => {
191
- const n = {}, r = (s) => {
192
- s.forEach((o) => {
193
- n[o] = !0;
200
+ }, Fn = (t, e) => {
201
+ const n = {}, r = (o) => {
202
+ o.forEach((s) => {
203
+ n[s] = !0;
194
204
  });
195
205
  };
196
- return H(t) ? r(t) : r(String(t).split(e)), n;
197
- }, An = () => {
198
- }, xn = (t, e) => t != null && Number.isFinite(t = +t) ? t : e;
199
- function _n(t) {
200
- return !!(t && x(t.append) && t[lt] === "FormData" && t[ce]);
201
- }
202
- const Cn = (t) => {
203
- const e = new Array(10), n = (r, s) => {
204
- if (X(r)) {
205
- if (e.indexOf(r) >= 0)
206
+ return X(t) ? r(t) : r(String(t).split(e)), n;
207
+ }, jn = () => {
208
+ }, kn = (t, e) => t != null && Number.isFinite(t = +t) ? t : e;
209
+ function Bn(t) {
210
+ return !!(t && C(t.append) && t[wt] === "FormData" && t[we]);
211
+ }
212
+ const vn = (t) => {
213
+ const e = /* @__PURE__ */ new WeakSet(), n = (r) => {
214
+ if (oe(r)) {
215
+ if (e.has(r))
206
216
  return;
207
- if (K(r))
217
+ if (re(r))
208
218
  return r;
209
219
  if (!("toJSON" in r)) {
210
- e[s] = r;
211
- const o = H(r) ? [] : {};
212
- return G(r, (i, a) => {
213
- const f = n(i, s + 1);
214
- !M(f) && (o[a] = f);
215
- }), e[s] = void 0, o;
220
+ e.add(r);
221
+ const o = X(r) ? [] : {};
222
+ return se(r, (s, i) => {
223
+ const a = n(s);
224
+ !K(a) && (o[i] = a);
225
+ }), e.delete(r), o;
216
226
  }
217
227
  }
218
228
  return r;
219
229
  };
220
- return n(t, 0);
221
- }, Pn = U("AsyncFunction"), Ln = (t) => t && (X(t) || x(t)) && x(t.then) && x(t.catch), mt = ((t, e) => t ? setImmediate : e ? ((n, r) => (B.addEventListener(
230
+ return n(t);
231
+ }, In = U("AsyncFunction"), qn = (t) => t && (oe(t) || C(t)) && C(t.then) && C(t.catch), _t = ((t, e) => t ? setImmediate : e ? ((n, r) => ($.addEventListener(
222
232
  "message",
223
- ({ source: s, data: o }) => {
224
- s === B && o === n && r.length && r.shift()();
233
+ ({ source: o, data: s }) => {
234
+ o === $ && s === n && r.length && r.shift()();
225
235
  },
226
236
  !1
227
- ), (s) => {
228
- r.push(s), B.postMessage(n, "*");
229
- }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(typeof setImmediate == "function", x(B.postMessage)), Nn = typeof queueMicrotask < "u" ? queueMicrotask.bind(B) : typeof process < "u" && process.nextTick || mt, Un = (t) => t != null && x(t[ce]), c = {
230
- isArray: H,
231
- isArrayBuffer: ut,
232
- isBuffer: K,
233
- isFormData: rn,
234
- isArrayBufferView: Wt,
235
- isString: zt,
236
- isNumber: ft,
237
- isBoolean: Vt,
238
- isObject: X,
239
- isPlainObject: se,
240
- isEmptyObject: Kt,
241
- isReadableStream: on,
242
- isRequest: an,
243
- isResponse: cn,
244
- isHeaders: ln,
245
- isUndefined: M,
246
- isDate: Xt,
247
- isFile: Gt,
248
- isReactNativeBlob: Qt,
249
- isReactNative: Yt,
250
- isBlob: Zt,
251
- isRegExp: Sn,
252
- isFunction: x,
253
- isStream: tn,
254
- isURLSearchParams: sn,
255
- isTypedArray: yn,
256
- isFileList: en,
257
- forEach: G,
258
- merge: Se,
259
- extend: fn,
260
- trim: un,
261
- stripBOM: dn,
262
- inherits: pn,
263
- toFlatObject: hn,
264
- kindOf: le,
237
+ ), (o) => {
238
+ r.push(o), $.postMessage(n, "*");
239
+ }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(typeof setImmediate == "function", C($.postMessage)), Mn = typeof queueMicrotask < "u" ? queueMicrotask.bind($) : typeof process < "u" && process.nextTick || _t, Hn = (t) => t != null && C(t[we]), c = {
240
+ isArray: X,
241
+ isArrayBuffer: bt,
242
+ isBuffer: re,
243
+ isFormData: hn,
244
+ isArrayBufferView: tn,
245
+ isString: nn,
246
+ isNumber: Et,
247
+ isBoolean: rn,
248
+ isObject: oe,
249
+ isPlainObject: pe,
250
+ isEmptyObject: on,
251
+ isReadableStream: yn,
252
+ isRequest: gn,
253
+ isResponse: wn,
254
+ isHeaders: bn,
255
+ isUndefined: K,
256
+ isDate: sn,
257
+ isFile: an,
258
+ isReactNativeBlob: cn,
259
+ isReactNative: ln,
260
+ isBlob: un,
261
+ isRegExp: Dn,
262
+ isFunction: C,
263
+ isStream: dn,
264
+ isURLSearchParams: mn,
265
+ isTypedArray: xn,
266
+ isFileList: fn,
267
+ forEach: se,
268
+ merge: Ue,
269
+ extend: Rn,
270
+ trim: En,
271
+ stripBOM: On,
272
+ inherits: Sn,
273
+ toFlatObject: _n,
274
+ kindOf: be,
265
275
  kindOfTest: U,
266
- endsWith: mn,
267
- toArray: gn,
268
- forEachEntry: wn,
269
- matchAll: bn,
270
- isHTMLForm: Rn,
271
- hasOwnProperty: $e,
272
- hasOwnProp: $e,
276
+ endsWith: An,
277
+ toArray: Tn,
278
+ forEachEntry: Cn,
279
+ matchAll: Pn,
280
+ isHTMLForm: Ln,
281
+ hasOwnProperty: Fe,
282
+ hasOwnProp: Fe,
273
283
  // an alias to avoid ESLint no-prototype-builtins detection
274
- reduceDescriptors: ht,
275
- freezeMethods: On,
276
- toObjectSet: Tn,
277
- toCamelCase: En,
278
- noop: An,
279
- toFiniteNumber: xn,
280
- findKey: dt,
281
- global: B,
282
- isContextDefined: pt,
283
- isSpecCompliantForm: _n,
284
- toJSONObject: Cn,
285
- isAsyncFn: Pn,
286
- isThenable: Ln,
287
- setImmediate: mt,
288
- asap: Nn,
289
- isIterable: Un
284
+ reduceDescriptors: St,
285
+ freezeMethods: Un,
286
+ toObjectSet: Fn,
287
+ toCamelCase: Nn,
288
+ noop: jn,
289
+ toFiniteNumber: kn,
290
+ findKey: Rt,
291
+ global: $,
292
+ isContextDefined: Ot,
293
+ isSpecCompliantForm: Bn,
294
+ toJSONObject: vn,
295
+ isAsyncFn: In,
296
+ isThenable: qn,
297
+ setImmediate: _t,
298
+ asap: Mn,
299
+ isIterable: Hn
300
+ }, $n = c.toObjectSet([
301
+ "age",
302
+ "authorization",
303
+ "content-length",
304
+ "content-type",
305
+ "etag",
306
+ "expires",
307
+ "from",
308
+ "host",
309
+ "if-modified-since",
310
+ "if-unmodified-since",
311
+ "last-modified",
312
+ "location",
313
+ "max-forwards",
314
+ "proxy-authorization",
315
+ "referer",
316
+ "retry-after",
317
+ "user-agent"
318
+ ]), zn = (t) => {
319
+ const e = {};
320
+ let n, r, o;
321
+ return t && t.split(`
322
+ `).forEach(function(i) {
323
+ o = i.indexOf(":"), n = i.substring(0, o).trim().toLowerCase(), r = i.substring(o + 1).trim(), !(!n || e[n] && $n[n]) && (n === "set-cookie" ? e[n] ? e[n].push(r) : e[n] = [r] : e[n] = e[n] ? e[n] + ", " + r : r);
324
+ }), e;
325
+ };
326
+ function Jn(t) {
327
+ let e = 0, n = t.length;
328
+ for (; e < n; ) {
329
+ const r = t.charCodeAt(e);
330
+ if (r !== 9 && r !== 32)
331
+ break;
332
+ e += 1;
333
+ }
334
+ for (; n > e; ) {
335
+ const r = t.charCodeAt(n - 1);
336
+ if (r !== 9 && r !== 32)
337
+ break;
338
+ n -= 1;
339
+ }
340
+ return e === 0 && n === t.length ? t : t.slice(e, n);
341
+ }
342
+ const Wn = new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+", "g"), Vn = new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+", "g");
343
+ function qe(t, e) {
344
+ return c.isArray(t) ? t.map((n) => qe(n, e)) : Jn(String(t).replace(e, ""));
345
+ }
346
+ const Kn = (t) => qe(t, Wn), Xn = (t) => qe(t, Vn);
347
+ function At(t) {
348
+ const e = /* @__PURE__ */ Object.create(null);
349
+ return c.forEach(t.toJSON(), (n, r) => {
350
+ e[r] = Xn(n);
351
+ }), e;
352
+ }
353
+ const tt = Symbol("internals");
354
+ function Z(t) {
355
+ return t && String(t).trim().toLowerCase();
356
+ }
357
+ function he(t) {
358
+ return t === !1 || t == null ? t : c.isArray(t) ? t.map(he) : Kn(String(t));
359
+ }
360
+ function Gn(t) {
361
+ const e = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
362
+ let r;
363
+ for (; r = n.exec(t); )
364
+ e[r[1]] = r[2];
365
+ return e;
366
+ }
367
+ const Qn = (t) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());
368
+ function Ce(t, e, n, r, o) {
369
+ if (c.isFunction(r))
370
+ return r.call(this, e, n);
371
+ if (o && (e = n), !!c.isString(e)) {
372
+ if (c.isString(r))
373
+ return e.indexOf(r) !== -1;
374
+ if (c.isRegExp(r))
375
+ return r.test(e);
376
+ }
377
+ }
378
+ function Yn(t) {
379
+ return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, n, r) => n.toUpperCase() + r);
380
+ }
381
+ function Zn(t, e) {
382
+ const n = c.toCamelCase(" " + e);
383
+ ["get", "set", "has"].forEach((r) => {
384
+ Object.defineProperty(t, r + n, {
385
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
386
+ // this data descriptor into an accessor descriptor on the way in.
387
+ __proto__: null,
388
+ value: function(o, s, i) {
389
+ return this[r].call(this, e, o, s, i);
390
+ },
391
+ configurable: !0
392
+ });
393
+ });
394
+ }
395
+ let x = class {
396
+ constructor(e) {
397
+ e && this.set(e);
398
+ }
399
+ set(e, n, r) {
400
+ const o = this;
401
+ function s(a, l, f) {
402
+ const u = Z(l);
403
+ if (!u)
404
+ throw new Error("header name must be a non-empty string");
405
+ const p = c.findKey(o, u);
406
+ (!p || o[p] === void 0 || f === !0 || f === void 0 && o[p] !== !1) && (o[p || l] = he(a));
407
+ }
408
+ const i = (a, l) => c.forEach(a, (f, u) => s(f, u, l));
409
+ if (c.isPlainObject(e) || e instanceof this.constructor)
410
+ i(e, n);
411
+ else if (c.isString(e) && (e = e.trim()) && !Qn(e))
412
+ i(zn(e), n);
413
+ else if (c.isObject(e) && c.isIterable(e)) {
414
+ let a = {}, l, f;
415
+ for (const u of e) {
416
+ if (!c.isArray(u))
417
+ throw TypeError("Object iterator must return a key-value pair");
418
+ a[f = u[0]] = (l = a[f]) ? c.isArray(l) ? [...l, u[1]] : [l, u[1]] : u[1];
419
+ }
420
+ i(a, n);
421
+ } else
422
+ e != null && s(n, e, r);
423
+ return this;
424
+ }
425
+ get(e, n) {
426
+ if (e = Z(e), e) {
427
+ const r = c.findKey(this, e);
428
+ if (r) {
429
+ const o = this[r];
430
+ if (!n)
431
+ return o;
432
+ if (n === !0)
433
+ return Gn(o);
434
+ if (c.isFunction(n))
435
+ return n.call(this, o, r);
436
+ if (c.isRegExp(n))
437
+ return n.exec(o);
438
+ throw new TypeError("parser must be boolean|regexp|function");
439
+ }
440
+ }
441
+ }
442
+ has(e, n) {
443
+ if (e = Z(e), e) {
444
+ const r = c.findKey(this, e);
445
+ return !!(r && this[r] !== void 0 && (!n || Ce(this, this[r], r, n)));
446
+ }
447
+ return !1;
448
+ }
449
+ delete(e, n) {
450
+ const r = this;
451
+ let o = !1;
452
+ function s(i) {
453
+ if (i = Z(i), i) {
454
+ const a = c.findKey(r, i);
455
+ a && (!n || Ce(r, r[a], a, n)) && (delete r[a], o = !0);
456
+ }
457
+ }
458
+ return c.isArray(e) ? e.forEach(s) : s(e), o;
459
+ }
460
+ clear(e) {
461
+ const n = Object.keys(this);
462
+ let r = n.length, o = !1;
463
+ for (; r--; ) {
464
+ const s = n[r];
465
+ (!e || Ce(this, this[s], s, e, !0)) && (delete this[s], o = !0);
466
+ }
467
+ return o;
468
+ }
469
+ normalize(e) {
470
+ const n = this, r = {};
471
+ return c.forEach(this, (o, s) => {
472
+ const i = c.findKey(r, s);
473
+ if (i) {
474
+ n[i] = he(o), delete n[s];
475
+ return;
476
+ }
477
+ const a = e ? Yn(s) : String(s).trim();
478
+ a !== s && delete n[s], n[a] = he(o), r[a] = !0;
479
+ }), this;
480
+ }
481
+ concat(...e) {
482
+ return this.constructor.concat(this, ...e);
483
+ }
484
+ toJSON(e) {
485
+ const n = /* @__PURE__ */ Object.create(null);
486
+ return c.forEach(this, (r, o) => {
487
+ r != null && r !== !1 && (n[o] = e && c.isArray(r) ? r.join(", ") : r);
488
+ }), n;
489
+ }
490
+ [Symbol.iterator]() {
491
+ return Object.entries(this.toJSON())[Symbol.iterator]();
492
+ }
493
+ toString() {
494
+ return Object.entries(this.toJSON()).map(([e, n]) => e + ": " + n).join(`
495
+ `);
496
+ }
497
+ getSetCookie() {
498
+ return this.get("set-cookie") || [];
499
+ }
500
+ get [Symbol.toStringTag]() {
501
+ return "AxiosHeaders";
502
+ }
503
+ static from(e) {
504
+ return e instanceof this ? e : new this(e);
505
+ }
506
+ static concat(e, ...n) {
507
+ const r = new this(e);
508
+ return n.forEach((o) => r.set(o)), r;
509
+ }
510
+ static accessor(e) {
511
+ const r = (this[tt] = this[tt] = {
512
+ accessors: {}
513
+ }).accessors, o = this.prototype;
514
+ function s(i) {
515
+ const a = Z(i);
516
+ r[a] || (Zn(o, i), r[a] = !0);
517
+ }
518
+ return c.isArray(e) ? e.forEach(s) : s(e), this;
519
+ }
290
520
  };
291
- let g = class gt extends Error {
292
- static from(e, n, r, s, o, i) {
293
- const a = new gt(e.message, n || e.code, r, s, o);
521
+ x.accessor([
522
+ "Content-Type",
523
+ "Content-Length",
524
+ "Accept",
525
+ "Accept-Encoding",
526
+ "User-Agent",
527
+ "Authorization"
528
+ ]);
529
+ c.reduceDescriptors(x.prototype, ({ value: t }, e) => {
530
+ let n = e[0].toUpperCase() + e.slice(1);
531
+ return {
532
+ get: () => t,
533
+ set(r) {
534
+ this[n] = r;
535
+ }
536
+ };
537
+ });
538
+ c.freezeMethods(x);
539
+ const er = "[REDACTED ****]";
540
+ function tr(t) {
541
+ if (c.hasOwnProp(t, "toJSON"))
542
+ return !0;
543
+ let e = Object.getPrototypeOf(t);
544
+ for (; e && e !== Object.prototype; ) {
545
+ if (c.hasOwnProp(e, "toJSON"))
546
+ return !0;
547
+ e = Object.getPrototypeOf(e);
548
+ }
549
+ return !1;
550
+ }
551
+ function nr(t, e) {
552
+ const n = new Set(e.map((s) => String(s).toLowerCase())), r = [], o = (s) => {
553
+ if (s === null || typeof s != "object" || c.isBuffer(s)) return s;
554
+ if (r.indexOf(s) !== -1) return;
555
+ s instanceof x && (s = s.toJSON()), r.push(s);
556
+ let i;
557
+ if (c.isArray(s))
558
+ i = [], s.forEach((a, l) => {
559
+ const f = o(a);
560
+ c.isUndefined(f) || (i[l] = f);
561
+ });
562
+ else {
563
+ if (!c.isPlainObject(s) && tr(s))
564
+ return r.pop(), s;
565
+ i = /* @__PURE__ */ Object.create(null);
566
+ for (const [a, l] of Object.entries(s)) {
567
+ const f = n.has(a.toLowerCase()) ? er : o(l);
568
+ c.isUndefined(f) || (i[a] = f);
569
+ }
570
+ }
571
+ return r.pop(), i;
572
+ };
573
+ return o(t);
574
+ }
575
+ let y = class Tt extends Error {
576
+ static from(e, n, r, o, s, i) {
577
+ const a = new Tt(e.message, n || e.code, r, o, s);
294
578
  return a.cause = e, a.name = e.name, e.status != null && a.status == null && (a.status = e.status), i && Object.assign(a, i), a;
295
579
  }
296
580
  /**
@@ -304,15 +588,19 @@ let g = class gt extends Error {
304
588
  *
305
589
  * @returns {Error} The created error.
306
590
  */
307
- constructor(e, n, r, s, o) {
591
+ constructor(e, n, r, o, s) {
308
592
  super(e), Object.defineProperty(this, "message", {
593
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
594
+ // this data descriptor into an accessor descriptor on the way in.
595
+ __proto__: null,
309
596
  value: e,
310
597
  enumerable: !0,
311
598
  writable: !0,
312
599
  configurable: !0
313
- }), this.name = "AxiosError", this.isAxiosError = !0, n && (this.code = n), r && (this.config = r), s && (this.request = s), o && (this.response = o, this.status = o.status);
600
+ }), this.name = "AxiosError", this.isAxiosError = !0, n && (this.code = n), r && (this.config = r), o && (this.request = o), s && (this.response = s, this.status = s.status);
314
601
  }
315
602
  toJSON() {
603
+ const e = this.config, n = e && c.hasOwnProp(e, "redact") ? e.redact : void 0, r = c.isArray(n) && n.length > 0 ? nr(e, n) : c.toJSONObject(e);
316
604
  return {
317
605
  // Standard
318
606
  message: this.message,
@@ -326,43 +614,45 @@ let g = class gt extends Error {
326
614
  columnNumber: this.columnNumber,
327
615
  stack: this.stack,
328
616
  // Axios
329
- config: c.toJSONObject(this.config),
617
+ config: r,
330
618
  code: this.code,
331
619
  status: this.status
332
620
  };
333
621
  }
334
622
  };
335
- g.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
336
- g.ERR_BAD_OPTION = "ERR_BAD_OPTION";
337
- g.ECONNABORTED = "ECONNABORTED";
338
- g.ETIMEDOUT = "ETIMEDOUT";
339
- g.ERR_NETWORK = "ERR_NETWORK";
340
- g.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
341
- g.ERR_DEPRECATED = "ERR_DEPRECATED";
342
- g.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
343
- g.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
344
- g.ERR_CANCELED = "ERR_CANCELED";
345
- g.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
346
- g.ERR_INVALID_URL = "ERR_INVALID_URL";
347
- const Fn = null;
348
- function Oe(t) {
623
+ y.ERR_BAD_OPTION_VALUE = "ERR_BAD_OPTION_VALUE";
624
+ y.ERR_BAD_OPTION = "ERR_BAD_OPTION";
625
+ y.ECONNABORTED = "ECONNABORTED";
626
+ y.ETIMEDOUT = "ETIMEDOUT";
627
+ y.ECONNREFUSED = "ECONNREFUSED";
628
+ y.ERR_NETWORK = "ERR_NETWORK";
629
+ y.ERR_FR_TOO_MANY_REDIRECTS = "ERR_FR_TOO_MANY_REDIRECTS";
630
+ y.ERR_DEPRECATED = "ERR_DEPRECATED";
631
+ y.ERR_BAD_RESPONSE = "ERR_BAD_RESPONSE";
632
+ y.ERR_BAD_REQUEST = "ERR_BAD_REQUEST";
633
+ y.ERR_CANCELED = "ERR_CANCELED";
634
+ y.ERR_NOT_SUPPORT = "ERR_NOT_SUPPORT";
635
+ y.ERR_INVALID_URL = "ERR_INVALID_URL";
636
+ y.ERR_FORM_DATA_DEPTH_EXCEEDED = "ERR_FORM_DATA_DEPTH_EXCEEDED";
637
+ const rr = null;
638
+ function je(t) {
349
639
  return c.isPlainObject(t) || c.isArray(t);
350
640
  }
351
- function yt(t) {
641
+ function xt(t) {
352
642
  return c.endsWith(t, "[]") ? t.slice(0, -2) : t;
353
643
  }
354
- function ye(t, e, n) {
355
- return t ? t.concat(e).map(function(s, o) {
356
- return s = yt(s), !n && o ? "[" + s + "]" : s;
644
+ function Pe(t, e, n) {
645
+ return t ? t.concat(e).map(function(o, s) {
646
+ return o = xt(o), !n && s ? "[" + o + "]" : o;
357
647
  }).join(n ? "." : "") : e;
358
648
  }
359
- function jn(t) {
360
- return c.isArray(t) && !t.some(Oe);
649
+ function or(t) {
650
+ return c.isArray(t) && !t.some(je);
361
651
  }
362
- const kn = c.toFlatObject(c, {}, null, function(e) {
652
+ const sr = c.toFlatObject(c, {}, null, function(e) {
363
653
  return /^is[A-Z]/.test(e);
364
654
  });
365
- function fe(t, e, n) {
655
+ function Re(t, e, n) {
366
656
  if (!c.isObject(t))
367
657
  throw new TypeError("target must be an object");
368
658
  e = e || new FormData(), n = c.toFlatObject(
@@ -373,105 +663,109 @@ function fe(t, e, n) {
373
663
  indexes: !1
374
664
  },
375
665
  !1,
376
- function(m, p) {
377
- return !c.isUndefined(p[m]);
666
+ function(d, m) {
667
+ return !c.isUndefined(m[d]);
378
668
  }
379
669
  );
380
- const r = n.metaTokens, s = n.visitor || l, o = n.dots, i = n.indexes, f = (n.Blob || typeof Blob < "u" && Blob) && c.isSpecCompliantForm(e);
381
- if (!c.isFunction(s))
670
+ const r = n.metaTokens, o = n.visitor || p, s = n.dots, i = n.indexes, a = n.Blob || typeof Blob < "u" && Blob, l = n.maxDepth === void 0 ? 100 : n.maxDepth, f = a && c.isSpecCompliantForm(e);
671
+ if (!c.isFunction(o))
382
672
  throw new TypeError("visitor must be a function");
383
- function u(d) {
384
- if (d === null) return "";
385
- if (c.isDate(d))
386
- return d.toISOString();
387
- if (c.isBoolean(d))
388
- return d.toString();
389
- if (!f && c.isBlob(d))
390
- throw new g("Blob is not supported. Use a Buffer instead.");
391
- return c.isArrayBuffer(d) || c.isTypedArray(d) ? f && typeof Blob == "function" ? new Blob([d]) : Buffer.from(d) : d;
392
- }
393
- function l(d, m, p) {
394
- let w = d;
395
- if (c.isReactNative(e) && c.isReactNativeBlob(d))
396
- return e.append(ye(p, m, o), u(d)), !1;
397
- if (d && !p && typeof d == "object") {
398
- if (c.endsWith(m, "{}"))
399
- m = r ? m : m.slice(0, -2), d = JSON.stringify(d);
400
- else if (c.isArray(d) && jn(d) || (c.isFileList(d) || c.endsWith(m, "[]")) && (w = c.toArray(d)))
401
- return m = yt(m), w.forEach(function(b, O) {
402
- !(c.isUndefined(b) || b === null) && e.append(
673
+ function u(h) {
674
+ if (h === null) return "";
675
+ if (c.isDate(h))
676
+ return h.toISOString();
677
+ if (c.isBoolean(h))
678
+ return h.toString();
679
+ if (!f && c.isBlob(h))
680
+ throw new y("Blob is not supported. Use a Buffer instead.");
681
+ return c.isArrayBuffer(h) || c.isTypedArray(h) ? f && typeof Blob == "function" ? new Blob([h]) : Buffer.from(h) : h;
682
+ }
683
+ function p(h, d, m) {
684
+ let O = h;
685
+ if (c.isReactNative(e) && c.isReactNativeBlob(h))
686
+ return e.append(Pe(m, d, s), u(h)), !1;
687
+ if (h && !m && typeof h == "object") {
688
+ if (c.endsWith(d, "{}"))
689
+ d = r ? d : d.slice(0, -2), h = JSON.stringify(h);
690
+ else if (c.isArray(h) && or(h) || (c.isFileList(h) || c.endsWith(d, "[]")) && (O = c.toArray(h)))
691
+ return d = xt(d), O.forEach(function(R, P) {
692
+ !(c.isUndefined(R) || R === null) && e.append(
403
693
  // eslint-disable-next-line no-nested-ternary
404
- i === !0 ? ye([m], O, o) : i === null ? m : m + "[]",
405
- u(b)
694
+ i === !0 ? Pe([d], P, s) : i === null ? d : d + "[]",
695
+ u(R)
406
696
  );
407
697
  }), !1;
408
698
  }
409
- return Oe(d) ? !0 : (e.append(ye(p, m, o), u(d)), !1);
699
+ return je(h) ? !0 : (e.append(Pe(m, d, s), u(h)), !1);
410
700
  }
411
- const h = [], y = Object.assign(kn, {
412
- defaultVisitor: l,
701
+ const g = [], w = Object.assign(sr, {
702
+ defaultVisitor: p,
413
703
  convertValue: u,
414
- isVisitable: Oe
704
+ isVisitable: je
415
705
  });
416
- function R(d, m) {
417
- if (!c.isUndefined(d)) {
418
- if (h.indexOf(d) !== -1)
419
- throw Error("Circular reference detected in " + m.join("."));
420
- h.push(d), c.forEach(d, function(w, S) {
421
- (!(c.isUndefined(w) || w === null) && s.call(e, w, c.isString(S) ? S.trim() : S, m, y)) === !0 && R(w, m ? m.concat(S) : [S]);
422
- }), h.pop();
706
+ function b(h, d, m = 0) {
707
+ if (!c.isUndefined(h)) {
708
+ if (m > l)
709
+ throw new y(
710
+ "Object is too deeply nested (" + m + " levels). Max depth: " + l,
711
+ y.ERR_FORM_DATA_DEPTH_EXCEEDED
712
+ );
713
+ if (g.indexOf(h) !== -1)
714
+ throw Error("Circular reference detected in " + d.join("."));
715
+ g.push(h), c.forEach(h, function(E, R) {
716
+ (!(c.isUndefined(E) || E === null) && o.call(e, E, c.isString(R) ? R.trim() : R, d, w)) === !0 && b(E, d ? d.concat(R) : [R], m + 1);
717
+ }), g.pop();
423
718
  }
424
719
  }
425
720
  if (!c.isObject(t))
426
721
  throw new TypeError("data must be an object");
427
- return R(t), e;
722
+ return b(t), e;
428
723
  }
429
- function Je(t) {
724
+ function nt(t) {
430
725
  const e = {
431
726
  "!": "%21",
432
727
  "'": "%27",
433
728
  "(": "%28",
434
729
  ")": "%29",
435
730
  "~": "%7E",
436
- "%20": "+",
437
- "%00": "\0"
731
+ "%20": "+"
438
732
  };
439
- return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g, function(r) {
733
+ return encodeURIComponent(t).replace(/[!'()~]|%20/g, function(r) {
440
734
  return e[r];
441
735
  });
442
736
  }
443
- function Pe(t, e) {
444
- this._pairs = [], t && fe(t, this, e);
737
+ function Me(t, e) {
738
+ this._pairs = [], t && Re(t, this, e);
445
739
  }
446
- const wt = Pe.prototype;
447
- wt.append = function(e, n) {
740
+ const Ct = Me.prototype;
741
+ Ct.append = function(e, n) {
448
742
  this._pairs.push([e, n]);
449
743
  };
450
- wt.toString = function(e) {
744
+ Ct.toString = function(e) {
451
745
  const n = e ? function(r) {
452
- return e.call(this, r, Je);
453
- } : Je;
454
- return this._pairs.map(function(s) {
455
- return n(s[0]) + "=" + n(s[1]);
746
+ return e.call(this, r, nt);
747
+ } : nt;
748
+ return this._pairs.map(function(o) {
749
+ return n(o[0]) + "=" + n(o[1]);
456
750
  }, "").join("&");
457
751
  };
458
- function Dn(t) {
752
+ function ir(t) {
459
753
  return encodeURIComponent(t).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
460
754
  }
461
- function bt(t, e, n) {
755
+ function Pt(t, e, n) {
462
756
  if (!e)
463
757
  return t;
464
- const r = n && n.encode || Dn, s = c.isFunction(n) ? {
758
+ const r = n && n.encode || ir, o = c.isFunction(n) ? {
465
759
  serialize: n
466
- } : n, o = s && s.serialize;
760
+ } : n, s = o && o.serialize;
467
761
  let i;
468
- if (o ? i = o(e, s) : i = c.isURLSearchParams(e) ? e.toString() : new Pe(e, s).toString(r), i) {
762
+ if (s ? i = s(e, o) : i = c.isURLSearchParams(e) ? e.toString() : new Me(e, o).toString(r), i) {
469
763
  const a = t.indexOf("#");
470
764
  a !== -1 && (t = t.slice(0, a)), t += (t.indexOf("?") === -1 ? "?" : "&") + i;
471
765
  }
472
766
  return t;
473
767
  }
474
- class We {
768
+ class rt {
475
769
  constructor() {
476
770
  this.handlers = [];
477
771
  }
@@ -526,67 +820,68 @@ class We {
526
820
  });
527
821
  }
528
822
  }
529
- const Le = {
823
+ const He = {
530
824
  silentJSONParsing: !0,
531
825
  forcedJSONParsing: !0,
532
826
  clarifyTimeoutError: !1,
533
827
  legacyInterceptorReqResOrdering: !0
534
- }, Bn = typeof URLSearchParams < "u" ? URLSearchParams : Pe, vn = typeof FormData < "u" ? FormData : null, In = typeof Blob < "u" ? Blob : null, qn = {
828
+ }, ar = typeof URLSearchParams < "u" ? URLSearchParams : Me, cr = typeof FormData < "u" ? FormData : null, lr = typeof Blob < "u" ? Blob : null, ur = {
535
829
  isBrowser: !0,
536
830
  classes: {
537
- URLSearchParams: Bn,
538
- FormData: vn,
539
- Blob: In
831
+ URLSearchParams: ar,
832
+ FormData: cr,
833
+ Blob: lr
540
834
  },
541
835
  protocols: ["http", "https", "file", "blob", "url", "data"]
542
- }, Ne = typeof window < "u" && typeof document < "u", Te = typeof navigator == "object" && navigator || void 0, Mn = Ne && (!Te || ["ReactNative", "NativeScript", "NS"].indexOf(Te.product) < 0), Hn = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
543
- self instanceof WorkerGlobalScope && typeof self.importScripts == "function", $n = Ne && window.location.href || "http://localhost", Jn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
836
+ }, $e = typeof window < "u" && typeof document < "u", ke = typeof navigator == "object" && navigator || void 0, fr = $e && (!ke || ["ReactNative", "NativeScript", "NS"].indexOf(ke.product) < 0), dr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
837
+ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", pr = $e && window.location.href || "http://localhost", hr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
544
838
  __proto__: null,
545
- hasBrowserEnv: Ne,
546
- hasStandardBrowserEnv: Mn,
547
- hasStandardBrowserWebWorkerEnv: Hn,
548
- navigator: Te,
549
- origin: $n
839
+ hasBrowserEnv: $e,
840
+ hasStandardBrowserEnv: fr,
841
+ hasStandardBrowserWebWorkerEnv: dr,
842
+ navigator: ke,
843
+ origin: pr
550
844
  }, Symbol.toStringTag, { value: "Module" })), T = {
551
- ...Jn,
552
- ...qn
845
+ ...hr,
846
+ ...ur
553
847
  };
554
- function Wn(t, e) {
555
- return fe(t, new T.classes.URLSearchParams(), {
556
- visitor: function(n, r, s, o) {
557
- return T.isNode && c.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
848
+ function mr(t, e) {
849
+ return Re(t, new T.classes.URLSearchParams(), {
850
+ visitor: function(n, r, o, s) {
851
+ return T.isNode && c.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : s.defaultVisitor.apply(this, arguments);
558
852
  },
559
853
  ...e
560
854
  });
561
855
  }
562
- function zn(t) {
856
+ function yr(t) {
563
857
  return c.matchAll(/\w+|\[(\w*)]/g, t).map((e) => e[0] === "[]" ? "" : e[1] || e[0]);
564
858
  }
565
- function Vn(t) {
859
+ function gr(t) {
566
860
  const e = {}, n = Object.keys(t);
567
861
  let r;
568
- const s = n.length;
569
- let o;
570
- for (r = 0; r < s; r++)
571
- o = n[r], e[o] = t[o];
862
+ const o = n.length;
863
+ let s;
864
+ for (r = 0; r < o; r++)
865
+ s = n[r], e[s] = t[s];
572
866
  return e;
573
867
  }
574
- function Rt(t) {
575
- function e(n, r, s, o) {
576
- let i = n[o++];
868
+ function Lt(t) {
869
+ function e(n, r, o, s) {
870
+ let i = n[s++];
577
871
  if (i === "__proto__") return !0;
578
- const a = Number.isFinite(+i), f = o >= n.length;
579
- return i = !i && c.isArray(s) ? s.length : i, f ? (c.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !a) : ((!s[i] || !c.isObject(s[i])) && (s[i] = []), e(n, r, s[i], o) && c.isArray(s[i]) && (s[i] = Vn(s[i])), !a);
872
+ const a = Number.isFinite(+i), l = s >= n.length;
873
+ return i = !i && c.isArray(o) ? o.length : i, l ? (c.hasOwnProp(o, i) ? o[i] = c.isArray(o[i]) ? o[i].concat(r) : [o[i], r] : o[i] = r, !a) : ((!c.hasOwnProp(o, i) || !c.isObject(o[i])) && (o[i] = []), e(n, r, o[i], s) && c.isArray(o[i]) && (o[i] = gr(o[i])), !a);
580
874
  }
581
875
  if (c.isFormData(t) && c.isFunction(t.entries)) {
582
876
  const n = {};
583
- return c.forEachEntry(t, (r, s) => {
584
- e(zn(r), s, n, 0);
877
+ return c.forEachEntry(t, (r, o) => {
878
+ e(yr(r), o, n, 0);
585
879
  }), n;
586
880
  }
587
881
  return null;
588
882
  }
589
- function Kn(t, e, n) {
883
+ const V = (t, e) => t != null && c.hasOwnProp(t, e) ? t[e] : void 0;
884
+ function wr(t, e, n) {
590
885
  if (c.isString(t))
591
886
  try {
592
887
  return (e || JSON.parse)(t), c.trim(t);
@@ -596,14 +891,14 @@ function Kn(t, e, n) {
596
891
  }
597
892
  return (n || JSON.stringify)(t);
598
893
  }
599
- const Q = {
600
- transitional: Le,
894
+ const ie = {
895
+ transitional: He,
601
896
  adapter: ["xhr", "http", "fetch"],
602
897
  transformRequest: [
603
898
  function(e, n) {
604
- const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = c.isObject(e);
605
- if (o && c.isHTMLForm(e) && (e = new FormData(e)), c.isFormData(e))
606
- return s ? JSON.stringify(Rt(e)) : e;
899
+ const r = n.getContentType() || "", o = r.indexOf("application/json") > -1, s = c.isObject(e);
900
+ if (s && c.isHTMLForm(e) && (e = new FormData(e)), c.isFormData(e))
901
+ return o ? JSON.stringify(Lt(e)) : e;
607
902
  if (c.isArrayBuffer(e) || c.isBuffer(e) || c.isStream(e) || c.isFile(e) || c.isBlob(e) || c.isReadableStream(e))
608
903
  return e;
609
904
  if (c.isArrayBufferView(e))
@@ -611,33 +906,34 @@ const Q = {
611
906
  if (c.isURLSearchParams(e))
612
907
  return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), e.toString();
613
908
  let a;
614
- if (o) {
909
+ if (s) {
910
+ const l = V(this, "formSerializer");
615
911
  if (r.indexOf("application/x-www-form-urlencoded") > -1)
616
- return Wn(e, this.formSerializer).toString();
912
+ return mr(e, l).toString();
617
913
  if ((a = c.isFileList(e)) || r.indexOf("multipart/form-data") > -1) {
618
- const f = this.env && this.env.FormData;
619
- return fe(
914
+ const f = V(this, "env"), u = f && f.FormData;
915
+ return Re(
620
916
  a ? { "files[]": e } : e,
621
- f && new f(),
622
- this.formSerializer
917
+ u && new u(),
918
+ l
623
919
  );
624
920
  }
625
921
  }
626
- return o || s ? (n.setContentType("application/json", !1), Kn(e)) : e;
922
+ return s || o ? (n.setContentType("application/json", !1), wr(e)) : e;
627
923
  }
628
924
  ],
629
925
  transformResponse: [
630
926
  function(e) {
631
- const n = this.transitional || Q.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
927
+ const n = V(this, "transitional") || ie.transitional, r = n && n.forcedJSONParsing, o = V(this, "responseType"), s = o === "json";
632
928
  if (c.isResponse(e) || c.isReadableStream(e))
633
929
  return e;
634
- if (e && c.isString(e) && (r && !this.responseType || s)) {
635
- const i = !(n && n.silentJSONParsing) && s;
930
+ if (e && c.isString(e) && (r && !o || s)) {
931
+ const a = !(n && n.silentJSONParsing) && s;
636
932
  try {
637
- return JSON.parse(e, this.parseReviver);
638
- } catch (a) {
639
- if (i)
640
- throw a.name === "SyntaxError" ? g.from(a, g.ERR_BAD_RESPONSE, this, null, this.response) : a;
933
+ return JSON.parse(e, V(this, "parseReviver"));
934
+ } catch (l) {
935
+ if (a)
936
+ throw l.name === "SyntaxError" ? y.from(l, y.ERR_BAD_RESPONSE, this, null, V(this, "response")) : l;
641
937
  }
642
938
  }
643
939
  return e;
@@ -666,228 +962,20 @@ const Q = {
666
962
  }
667
963
  }
668
964
  };
669
- c.forEach(["delete", "get", "head", "post", "put", "patch"], (t) => {
670
- Q.headers[t] = {};
671
- });
672
- const Xn = c.toObjectSet([
673
- "age",
674
- "authorization",
675
- "content-length",
676
- "content-type",
677
- "etag",
678
- "expires",
679
- "from",
680
- "host",
681
- "if-modified-since",
682
- "if-unmodified-since",
683
- "last-modified",
684
- "location",
685
- "max-forwards",
686
- "proxy-authorization",
687
- "referer",
688
- "retry-after",
689
- "user-agent"
690
- ]), Gn = (t) => {
691
- const e = {};
692
- let n, r, s;
693
- return t && t.split(`
694
- `).forEach(function(i) {
695
- s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || e[n] && Xn[n]) && (n === "set-cookie" ? e[n] ? e[n].push(r) : e[n] = [r] : e[n] = e[n] ? e[n] + ", " + r : r);
696
- }), e;
697
- }, ze = Symbol("internals");
698
- function J(t) {
699
- return t && String(t).trim().toLowerCase();
700
- }
701
- function oe(t) {
702
- return t === !1 || t == null ? t : c.isArray(t) ? t.map(oe) : String(t);
703
- }
704
- function Qn(t) {
705
- const e = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
706
- let r;
707
- for (; r = n.exec(t); )
708
- e[r[1]] = r[2];
709
- return e;
710
- }
711
- const Yn = (t) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());
712
- function we(t, e, n, r, s) {
713
- if (c.isFunction(r))
714
- return r.call(this, e, n);
715
- if (s && (e = n), !!c.isString(e)) {
716
- if (c.isString(r))
717
- return e.indexOf(r) !== -1;
718
- if (c.isRegExp(r))
719
- return r.test(e);
720
- }
721
- }
722
- function Zn(t) {
723
- return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, n, r) => n.toUpperCase() + r);
724
- }
725
- function er(t, e) {
726
- const n = c.toCamelCase(" " + e);
727
- ["get", "set", "has"].forEach((r) => {
728
- Object.defineProperty(t, r + n, {
729
- value: function(s, o, i) {
730
- return this[r].call(this, e, s, o, i);
731
- },
732
- configurable: !0
733
- });
734
- });
735
- }
736
- let _ = class {
737
- constructor(e) {
738
- e && this.set(e);
739
- }
740
- set(e, n, r) {
741
- const s = this;
742
- function o(a, f, u) {
743
- const l = J(f);
744
- if (!l)
745
- throw new Error("header name must be a non-empty string");
746
- const h = c.findKey(s, l);
747
- (!h || s[h] === void 0 || u === !0 || u === void 0 && s[h] !== !1) && (s[h || f] = oe(a));
748
- }
749
- const i = (a, f) => c.forEach(a, (u, l) => o(u, l, f));
750
- if (c.isPlainObject(e) || e instanceof this.constructor)
751
- i(e, n);
752
- else if (c.isString(e) && (e = e.trim()) && !Yn(e))
753
- i(Gn(e), n);
754
- else if (c.isObject(e) && c.isIterable(e)) {
755
- let a = {}, f, u;
756
- for (const l of e) {
757
- if (!c.isArray(l))
758
- throw TypeError("Object iterator must return a key-value pair");
759
- a[u = l[0]] = (f = a[u]) ? c.isArray(f) ? [...f, l[1]] : [f, l[1]] : l[1];
760
- }
761
- i(a, n);
762
- } else
763
- e != null && o(n, e, r);
764
- return this;
765
- }
766
- get(e, n) {
767
- if (e = J(e), e) {
768
- const r = c.findKey(this, e);
769
- if (r) {
770
- const s = this[r];
771
- if (!n)
772
- return s;
773
- if (n === !0)
774
- return Qn(s);
775
- if (c.isFunction(n))
776
- return n.call(this, s, r);
777
- if (c.isRegExp(n))
778
- return n.exec(s);
779
- throw new TypeError("parser must be boolean|regexp|function");
780
- }
781
- }
782
- }
783
- has(e, n) {
784
- if (e = J(e), e) {
785
- const r = c.findKey(this, e);
786
- return !!(r && this[r] !== void 0 && (!n || we(this, this[r], r, n)));
787
- }
788
- return !1;
789
- }
790
- delete(e, n) {
791
- const r = this;
792
- let s = !1;
793
- function o(i) {
794
- if (i = J(i), i) {
795
- const a = c.findKey(r, i);
796
- a && (!n || we(r, r[a], a, n)) && (delete r[a], s = !0);
797
- }
798
- }
799
- return c.isArray(e) ? e.forEach(o) : o(e), s;
800
- }
801
- clear(e) {
802
- const n = Object.keys(this);
803
- let r = n.length, s = !1;
804
- for (; r--; ) {
805
- const o = n[r];
806
- (!e || we(this, this[o], o, e, !0)) && (delete this[o], s = !0);
807
- }
808
- return s;
809
- }
810
- normalize(e) {
811
- const n = this, r = {};
812
- return c.forEach(this, (s, o) => {
813
- const i = c.findKey(r, o);
814
- if (i) {
815
- n[i] = oe(s), delete n[o];
816
- return;
817
- }
818
- const a = e ? Zn(o) : String(o).trim();
819
- a !== o && delete n[o], n[a] = oe(s), r[a] = !0;
820
- }), this;
821
- }
822
- concat(...e) {
823
- return this.constructor.concat(this, ...e);
824
- }
825
- toJSON(e) {
826
- const n = /* @__PURE__ */ Object.create(null);
827
- return c.forEach(this, (r, s) => {
828
- r != null && r !== !1 && (n[s] = e && c.isArray(r) ? r.join(", ") : r);
829
- }), n;
830
- }
831
- [Symbol.iterator]() {
832
- return Object.entries(this.toJSON())[Symbol.iterator]();
833
- }
834
- toString() {
835
- return Object.entries(this.toJSON()).map(([e, n]) => e + ": " + n).join(`
836
- `);
837
- }
838
- getSetCookie() {
839
- return this.get("set-cookie") || [];
840
- }
841
- get [Symbol.toStringTag]() {
842
- return "AxiosHeaders";
843
- }
844
- static from(e) {
845
- return e instanceof this ? e : new this(e);
846
- }
847
- static concat(e, ...n) {
848
- const r = new this(e);
849
- return n.forEach((s) => r.set(s)), r;
850
- }
851
- static accessor(e) {
852
- const r = (this[ze] = this[ze] = {
853
- accessors: {}
854
- }).accessors, s = this.prototype;
855
- function o(i) {
856
- const a = J(i);
857
- r[a] || (er(s, i), r[a] = !0);
858
- }
859
- return c.isArray(e) ? e.forEach(o) : o(e), this;
860
- }
861
- };
862
- _.accessor([
863
- "Content-Type",
864
- "Content-Length",
865
- "Accept",
866
- "Accept-Encoding",
867
- "User-Agent",
868
- "Authorization"
869
- ]);
870
- c.reduceDescriptors(_.prototype, ({ value: t }, e) => {
871
- let n = e[0].toUpperCase() + e.slice(1);
872
- return {
873
- get: () => t,
874
- set(r) {
875
- this[n] = r;
876
- }
877
- };
965
+ c.forEach(["delete", "get", "head", "post", "put", "patch", "query"], (t) => {
966
+ ie.headers[t] = {};
878
967
  });
879
- c.freezeMethods(_);
880
- function be(t, e) {
881
- const n = this || Q, r = e || n, s = _.from(r.headers);
882
- let o = r.data;
968
+ function Le(t, e) {
969
+ const n = this || ie, r = e || n, o = x.from(r.headers);
970
+ let s = r.data;
883
971
  return c.forEach(t, function(a) {
884
- o = a.call(n, o, s.normalize(), e ? e.status : void 0);
885
- }), s.normalize(), o;
972
+ s = a.call(n, s, o.normalize(), e ? e.status : void 0);
973
+ }), o.normalize(), s;
886
974
  }
887
- function Et(t) {
975
+ function Nt(t) {
888
976
  return !!(t && t.__CANCEL__);
889
977
  }
890
- let Y = class extends g {
978
+ let ae = class extends y {
891
979
  /**
892
980
  * A `CanceledError` is an object that is thrown when an operation is canceled.
893
981
  *
@@ -898,73 +986,73 @@ let Y = class extends g {
898
986
  * @returns {CanceledError} The created error.
899
987
  */
900
988
  constructor(e, n, r) {
901
- super(e ?? "canceled", g.ERR_CANCELED, n, r), this.name = "CanceledError", this.__CANCEL__ = !0;
989
+ super(e ?? "canceled", y.ERR_CANCELED, n, r), this.name = "CanceledError", this.__CANCEL__ = !0;
902
990
  }
903
991
  };
904
- function St(t, e, n) {
992
+ function Dt(t, e, n) {
905
993
  const r = n.config.validateStatus;
906
- !n.status || !r || r(n.status) ? t(n) : e(
907
- new g(
908
- "Request failed with status code " + n.status,
909
- [g.ERR_BAD_REQUEST, g.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
910
- n.config,
911
- n.request,
912
- n
913
- )
914
- );
915
- }
916
- function tr(t) {
917
- const e = /^([-+\w]{1,25})(:?\/\/|:)/.exec(t);
994
+ !n.status || !r || r(n.status) ? t(n) : e(new y(
995
+ "Request failed with status code " + n.status,
996
+ n.status >= 400 && n.status < 500 ? y.ERR_BAD_REQUEST : y.ERR_BAD_RESPONSE,
997
+ n.config,
998
+ n.request,
999
+ n
1000
+ ));
1001
+ }
1002
+ function br(t) {
1003
+ const e = /^([-+\w]{1,25}):(?:\/\/)?/.exec(t);
918
1004
  return e && e[1] || "";
919
1005
  }
920
- function nr(t, e) {
1006
+ function Er(t, e) {
921
1007
  t = t || 10;
922
1008
  const n = new Array(t), r = new Array(t);
923
- let s = 0, o = 0, i;
924
- return e = e !== void 0 ? e : 1e3, function(f) {
925
- const u = Date.now(), l = r[o];
926
- i || (i = u), n[s] = f, r[s] = u;
927
- let h = o, y = 0;
928
- for (; h !== s; )
929
- y += n[h++], h = h % t;
930
- if (s = (s + 1) % t, s === o && (o = (o + 1) % t), u - i < e)
1009
+ let o = 0, s = 0, i;
1010
+ return e = e !== void 0 ? e : 1e3, function(l) {
1011
+ const f = Date.now(), u = r[s];
1012
+ i || (i = f), n[o] = l, r[o] = f;
1013
+ let p = s, g = 0;
1014
+ for (; p !== o; )
1015
+ g += n[p++], p = p % t;
1016
+ if (o = (o + 1) % t, o === s && (s = (s + 1) % t), f - i < e)
931
1017
  return;
932
- const R = l && u - l;
933
- return R ? Math.round(y * 1e3 / R) : void 0;
1018
+ const w = u && f - u;
1019
+ return w ? Math.round(g * 1e3 / w) : void 0;
934
1020
  };
935
1021
  }
936
- function rr(t, e) {
937
- let n = 0, r = 1e3 / e, s, o;
938
- const i = (u, l = Date.now()) => {
939
- n = l, s = null, o && (clearTimeout(o), o = null), t(...u);
1022
+ function Rr(t, e) {
1023
+ let n = 0, r = 1e3 / e, o, s;
1024
+ const i = (f, u = Date.now()) => {
1025
+ n = u, o = null, s && (clearTimeout(s), s = null), t(...f);
940
1026
  };
941
- return [(...u) => {
942
- const l = Date.now(), h = l - n;
943
- h >= r ? i(u, l) : (s = u, o || (o = setTimeout(() => {
944
- o = null, i(s);
945
- }, r - h)));
946
- }, () => s && i(s)];
947
- }
948
- const ae = (t, e, n = 3) => {
1027
+ return [(...f) => {
1028
+ const u = Date.now(), p = u - n;
1029
+ p >= r ? i(f, u) : (o = f, s || (s = setTimeout(() => {
1030
+ s = null, i(o);
1031
+ }, r - p)));
1032
+ }, () => o && i(o)];
1033
+ }
1034
+ const ye = (t, e, n = 3) => {
949
1035
  let r = 0;
950
- const s = nr(50, 250);
951
- return rr((o) => {
952
- const i = o.loaded, a = o.lengthComputable ? o.total : void 0, f = i - r, u = s(f), l = i <= a;
953
- r = i;
954
- const h = {
955
- loaded: i,
1036
+ const o = Er(50, 250);
1037
+ return Rr((s) => {
1038
+ if (!s || typeof s.loaded != "number")
1039
+ return;
1040
+ const i = s.loaded, a = s.lengthComputable ? s.total : void 0, l = a != null ? Math.min(i, a) : i, f = Math.max(0, l - r), u = o(f);
1041
+ r = Math.max(r, l);
1042
+ const p = {
1043
+ loaded: l,
956
1044
  total: a,
957
- progress: a ? i / a : void 0,
1045
+ progress: a ? l / a : void 0,
958
1046
  bytes: f,
959
1047
  rate: u || void 0,
960
- estimated: u && a && l ? (a - i) / u : void 0,
961
- event: o,
1048
+ estimated: u && a ? (a - l) / u : void 0,
1049
+ event: s,
962
1050
  lengthComputable: a != null,
963
1051
  [e ? "download" : "upload"]: !0
964
1052
  };
965
- t(h);
1053
+ t(p);
966
1054
  }, n);
967
- }, Ve = (t, e) => {
1055
+ }, ot = (t, e) => {
968
1056
  const n = t != null;
969
1057
  return [
970
1058
  (r) => e[0]({
@@ -974,21 +1062,26 @@ const ae = (t, e, n = 3) => {
974
1062
  }),
975
1063
  e[1]
976
1064
  ];
977
- }, Ke = (t) => (...e) => c.asap(() => t(...e)), sr = T.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (n) => (n = new URL(n, T.origin), t.protocol === n.protocol && t.host === n.host && (e || t.port === n.port)))(
1065
+ }, st = (t) => (...e) => c.asap(() => t(...e)), Or = T.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (n) => (n = new URL(n, T.origin), t.protocol === n.protocol && t.host === n.host && (e || t.port === n.port)))(
978
1066
  new URL(T.origin),
979
1067
  T.navigator && /(msie|trident)/i.test(T.navigator.userAgent)
980
- ) : () => !0, or = T.hasStandardBrowserEnv ? (
1068
+ ) : () => !0, Sr = T.hasStandardBrowserEnv ? (
981
1069
  // Standard browser envs support document.cookie
982
1070
  {
983
- write(t, e, n, r, s, o, i) {
1071
+ write(t, e, n, r, o, s, i) {
984
1072
  if (typeof document > "u") return;
985
1073
  const a = [`${t}=${encodeURIComponent(e)}`];
986
- c.isNumber(n) && a.push(`expires=${new Date(n).toUTCString()}`), c.isString(r) && a.push(`path=${r}`), c.isString(s) && a.push(`domain=${s}`), o === !0 && a.push("secure"), c.isString(i) && a.push(`SameSite=${i}`), document.cookie = a.join("; ");
1074
+ c.isNumber(n) && a.push(`expires=${new Date(n).toUTCString()}`), c.isString(r) && a.push(`path=${r}`), c.isString(o) && a.push(`domain=${o}`), s === !0 && a.push("secure"), c.isString(i) && a.push(`SameSite=${i}`), document.cookie = a.join("; ");
987
1075
  },
988
1076
  read(t) {
989
1077
  if (typeof document > "u") return null;
990
- const e = document.cookie.match(new RegExp("(?:^|; )" + t + "=([^;]*)"));
991
- return e ? decodeURIComponent(e[1]) : null;
1078
+ const e = document.cookie.split(";");
1079
+ for (let n = 0; n < e.length; n++) {
1080
+ const r = e[n].replace(/^\s+/, ""), o = r.indexOf("=");
1081
+ if (o !== -1 && r.slice(0, o) === t)
1082
+ return decodeURIComponent(r.slice(o + 1));
1083
+ }
1084
+ return null;
992
1085
  },
993
1086
  remove(t) {
994
1087
  this.write(t, "", Date.now() - 864e5, "/");
@@ -1006,49 +1099,58 @@ const ae = (t, e, n = 3) => {
1006
1099
  }
1007
1100
  }
1008
1101
  );
1009
- function ir(t) {
1102
+ function _r(t) {
1010
1103
  return typeof t != "string" ? !1 : /^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);
1011
1104
  }
1012
- function ar(t, e) {
1105
+ function Ar(t, e) {
1013
1106
  return e ? t.replace(/\/?\/$/, "") + "/" + e.replace(/^\/+/, "") : t;
1014
1107
  }
1015
- function Ot(t, e, n) {
1016
- let r = !ir(e);
1017
- return t && (r || n == !1) ? ar(t, e) : e;
1108
+ function Ut(t, e, n) {
1109
+ let r = !_r(e);
1110
+ return t && (r || n === !1) ? Ar(t, e) : e;
1018
1111
  }
1019
- const Xe = (t) => t instanceof _ ? { ...t } : t;
1020
- function I(t, e) {
1112
+ const it = (t) => t instanceof x ? { ...t } : t;
1113
+ function J(t, e) {
1021
1114
  e = e || {};
1022
- const n = {};
1023
- function r(u, l, h, y) {
1024
- return c.isPlainObject(u) && c.isPlainObject(l) ? c.merge.call({ caseless: y }, u, l) : c.isPlainObject(l) ? c.merge({}, l) : c.isArray(l) ? l.slice() : l;
1025
- }
1026
- function s(u, l, h, y) {
1027
- if (c.isUndefined(l)) {
1028
- if (!c.isUndefined(u))
1029
- return r(void 0, u, h, y);
1030
- } else return r(u, l, h, y);
1031
- }
1032
- function o(u, l) {
1033
- if (!c.isUndefined(l))
1034
- return r(void 0, l);
1035
- }
1036
- function i(u, l) {
1037
- if (c.isUndefined(l)) {
1038
- if (!c.isUndefined(u))
1039
- return r(void 0, u);
1040
- } else return r(void 0, l);
1041
- }
1042
- function a(u, l, h) {
1043
- if (h in e)
1044
- return r(u, l);
1045
- if (h in t)
1115
+ const n = /* @__PURE__ */ Object.create(null);
1116
+ Object.defineProperty(n, "hasOwnProperty", {
1117
+ // Null-proto descriptor so a polluted Object.prototype.get cannot turn
1118
+ // this data descriptor into an accessor descriptor on the way in.
1119
+ __proto__: null,
1120
+ value: Object.prototype.hasOwnProperty,
1121
+ enumerable: !1,
1122
+ writable: !0,
1123
+ configurable: !0
1124
+ });
1125
+ function r(f, u, p, g) {
1126
+ return c.isPlainObject(f) && c.isPlainObject(u) ? c.merge.call({ caseless: g }, f, u) : c.isPlainObject(u) ? c.merge({}, u) : c.isArray(u) ? u.slice() : u;
1127
+ }
1128
+ function o(f, u, p, g) {
1129
+ if (c.isUndefined(u)) {
1130
+ if (!c.isUndefined(f))
1131
+ return r(void 0, f, p, g);
1132
+ } else return r(f, u, p, g);
1133
+ }
1134
+ function s(f, u) {
1135
+ if (!c.isUndefined(u))
1046
1136
  return r(void 0, u);
1047
1137
  }
1048
- const f = {
1049
- url: o,
1050
- method: o,
1051
- data: o,
1138
+ function i(f, u) {
1139
+ if (c.isUndefined(u)) {
1140
+ if (!c.isUndefined(f))
1141
+ return r(void 0, f);
1142
+ } else return r(void 0, u);
1143
+ }
1144
+ function a(f, u, p) {
1145
+ if (c.hasOwnProp(e, p))
1146
+ return r(f, u);
1147
+ if (c.hasOwnProp(t, p))
1148
+ return r(void 0, f);
1149
+ }
1150
+ const l = {
1151
+ url: s,
1152
+ method: s,
1153
+ data: s,
1052
1154
  baseURL: i,
1053
1155
  transformRequest: i,
1054
1156
  transformResponse: i,
@@ -1072,151 +1174,156 @@ function I(t, e) {
1072
1174
  httpsAgent: i,
1073
1175
  cancelToken: i,
1074
1176
  socketPath: i,
1177
+ allowedSocketPaths: i,
1075
1178
  responseEncoding: i,
1076
1179
  validateStatus: a,
1077
- headers: (u, l, h) => s(Xe(u), Xe(l), h, !0)
1180
+ headers: (f, u, p) => o(it(f), it(u), p, !0)
1078
1181
  };
1079
- return c.forEach(Object.keys({ ...t, ...e }), function(l) {
1080
- if (l === "__proto__" || l === "constructor" || l === "prototype") return;
1081
- const h = c.hasOwnProp(f, l) ? f[l] : s, y = h(t[l], e[l], l);
1082
- c.isUndefined(y) && h !== a || (n[l] = y);
1182
+ return c.forEach(Object.keys({ ...t, ...e }), function(u) {
1183
+ if (u === "__proto__" || u === "constructor" || u === "prototype") return;
1184
+ const p = c.hasOwnProp(l, u) ? l[u] : o, g = c.hasOwnProp(t, u) ? t[u] : void 0, w = c.hasOwnProp(e, u) ? e[u] : void 0, b = p(g, w, u);
1185
+ c.isUndefined(b) && p !== a || (n[u] = b);
1083
1186
  }), n;
1084
1187
  }
1085
- const Tt = (t) => {
1086
- const e = I({}, t);
1087
- let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: a } = e;
1088
- if (e.headers = i = _.from(i), e.url = bt(
1089
- Ot(e.baseURL, e.url, e.allowAbsoluteUrls),
1188
+ const Tr = ["content-type", "content-length"];
1189
+ function xr(t, e, n) {
1190
+ if (n !== "content-only") {
1191
+ t.set(e);
1192
+ return;
1193
+ }
1194
+ Object.entries(e).forEach(([r, o]) => {
1195
+ Tr.includes(r.toLowerCase()) && t.set(r, o);
1196
+ });
1197
+ }
1198
+ const Cr = (t) => encodeURIComponent(t).replace(
1199
+ /%([0-9A-F]{2})/gi,
1200
+ (e, n) => String.fromCharCode(parseInt(n, 16))
1201
+ ), Ft = (t) => {
1202
+ const e = J({}, t), n = (g) => c.hasOwnProp(e, g) ? e[g] : void 0, r = n("data");
1203
+ let o = n("withXSRFToken");
1204
+ const s = n("xsrfHeaderName"), i = n("xsrfCookieName");
1205
+ let a = n("headers");
1206
+ const l = n("auth"), f = n("baseURL"), u = n("allowAbsoluteUrls"), p = n("url");
1207
+ if (e.headers = a = x.from(a), e.url = Pt(
1208
+ Ut(f, p, u),
1090
1209
  t.params,
1091
1210
  t.paramsSerializer
1092
- ), a && i.set(
1211
+ ), l && a.set(
1093
1212
  "Authorization",
1094
- "Basic " + btoa(
1095
- (a.username || "") + ":" + (a.password ? unescape(encodeURIComponent(a.password)) : "")
1096
- )
1097
- ), c.isFormData(n)) {
1098
- if (T.hasStandardBrowserEnv || T.hasStandardBrowserWebWorkerEnv)
1099
- i.setContentType(void 0);
1100
- else if (c.isFunction(n.getHeaders)) {
1101
- const f = n.getHeaders(), u = ["content-type", "content-length"];
1102
- Object.entries(f).forEach(([l, h]) => {
1103
- u.includes(l.toLowerCase()) && i.set(l, h);
1104
- });
1105
- }
1106
- }
1107
- if (T.hasStandardBrowserEnv && (r && c.isFunction(r) && (r = r(e)), r || r !== !1 && sr(e.url))) {
1108
- const f = s && o && or.read(o);
1109
- f && i.set(s, f);
1213
+ "Basic " + btoa((l.username || "") + ":" + (l.password ? Cr(l.password) : ""))
1214
+ ), c.isFormData(r) && (T.hasStandardBrowserEnv || T.hasStandardBrowserWebWorkerEnv ? a.setContentType(void 0) : c.isFunction(r.getHeaders) && xr(a, r.getHeaders(), n("formDataHeaderPolicy"))), T.hasStandardBrowserEnv && (c.isFunction(o) && (o = o(e)), o === !0 || o == null && Or(e.url))) {
1215
+ const w = s && i && Sr.read(i);
1216
+ w && a.set(s, w);
1110
1217
  }
1111
1218
  return e;
1112
- }, cr = typeof XMLHttpRequest < "u", lr = cr && function(t) {
1219
+ }, Pr = typeof XMLHttpRequest < "u", Lr = Pr && function(t) {
1113
1220
  return new Promise(function(n, r) {
1114
- const s = Tt(t);
1115
- let o = s.data;
1116
- const i = _.from(s.headers).normalize();
1117
- let { responseType: a, onUploadProgress: f, onDownloadProgress: u } = s, l, h, y, R, d;
1118
- function m() {
1119
- R && R(), d && d(), s.cancelToken && s.cancelToken.unsubscribe(l), s.signal && s.signal.removeEventListener("abort", l);
1221
+ const o = Ft(t);
1222
+ let s = o.data;
1223
+ const i = x.from(o.headers).normalize();
1224
+ let { responseType: a, onUploadProgress: l, onDownloadProgress: f } = o, u, p, g, w, b;
1225
+ function h() {
1226
+ w && w(), b && b(), o.cancelToken && o.cancelToken.unsubscribe(u), o.signal && o.signal.removeEventListener("abort", u);
1120
1227
  }
1121
- let p = new XMLHttpRequest();
1122
- p.open(s.method.toUpperCase(), s.url, !0), p.timeout = s.timeout;
1123
- function w() {
1124
- if (!p)
1228
+ let d = new XMLHttpRequest();
1229
+ d.open(o.method.toUpperCase(), o.url, !0), d.timeout = o.timeout;
1230
+ function m() {
1231
+ if (!d)
1125
1232
  return;
1126
- const b = _.from(
1127
- "getAllResponseHeaders" in p && p.getAllResponseHeaders()
1233
+ const E = x.from(
1234
+ "getAllResponseHeaders" in d && d.getAllResponseHeaders()
1128
1235
  ), P = {
1129
- data: !a || a === "text" || a === "json" ? p.responseText : p.response,
1130
- status: p.status,
1131
- statusText: p.statusText,
1132
- headers: b,
1236
+ data: !a || a === "text" || a === "json" ? d.responseText : d.response,
1237
+ status: d.status,
1238
+ statusText: d.statusText,
1239
+ headers: E,
1133
1240
  config: t,
1134
- request: p
1241
+ request: d
1135
1242
  };
1136
- St(
1137
- function(L) {
1138
- n(L), m();
1243
+ Dt(
1244
+ function(G) {
1245
+ n(G), h();
1139
1246
  },
1140
- function(L) {
1141
- r(L), m();
1247
+ function(G) {
1248
+ r(G), h();
1142
1249
  },
1143
1250
  P
1144
- ), p = null;
1251
+ ), d = null;
1145
1252
  }
1146
- "onloadend" in p ? p.onloadend = w : p.onreadystatechange = function() {
1147
- !p || p.readyState !== 4 || p.status === 0 && !(p.responseURL && p.responseURL.indexOf("file:") === 0) || setTimeout(w);
1148
- }, p.onabort = function() {
1149
- p && (r(new g("Request aborted", g.ECONNABORTED, t, p)), p = null);
1150
- }, p.onerror = function(O) {
1151
- const P = O && O.message ? O.message : "Network Error", k = new g(P, g.ERR_NETWORK, t, p);
1152
- k.event = O || null, r(k), p = null;
1153
- }, p.ontimeout = function() {
1154
- let O = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
1155
- const P = s.transitional || Le;
1156
- s.timeoutErrorMessage && (O = s.timeoutErrorMessage), r(
1157
- new g(
1158
- O,
1159
- P.clarifyTimeoutError ? g.ETIMEDOUT : g.ECONNABORTED,
1253
+ "onloadend" in d ? d.onloadend = m : d.onreadystatechange = function() {
1254
+ !d || d.readyState !== 4 || d.status === 0 && !(d.responseURL && d.responseURL.startsWith("file:")) || setTimeout(m);
1255
+ }, d.onabort = function() {
1256
+ d && (r(new y("Request aborted", y.ECONNABORTED, t, d)), h(), d = null);
1257
+ }, d.onerror = function(R) {
1258
+ const P = R && R.message ? R.message : "Network Error", q = new y(P, y.ERR_NETWORK, t, d);
1259
+ q.event = R || null, r(q), h(), d = null;
1260
+ }, d.ontimeout = function() {
1261
+ let R = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
1262
+ const P = o.transitional || He;
1263
+ o.timeoutErrorMessage && (R = o.timeoutErrorMessage), r(
1264
+ new y(
1265
+ R,
1266
+ P.clarifyTimeoutError ? y.ETIMEDOUT : y.ECONNABORTED,
1160
1267
  t,
1161
- p
1268
+ d
1162
1269
  )
1163
- ), p = null;
1164
- }, o === void 0 && i.setContentType(null), "setRequestHeader" in p && c.forEach(i.toJSON(), function(O, P) {
1165
- p.setRequestHeader(P, O);
1166
- }), c.isUndefined(s.withCredentials) || (p.withCredentials = !!s.withCredentials), a && a !== "json" && (p.responseType = s.responseType), u && ([y, d] = ae(u, !0), p.addEventListener("progress", y)), f && p.upload && ([h, R] = ae(f), p.upload.addEventListener("progress", h), p.upload.addEventListener("loadend", R)), (s.cancelToken || s.signal) && (l = (b) => {
1167
- p && (r(!b || b.type ? new Y(null, t, p) : b), p.abort(), p = null);
1168
- }, s.cancelToken && s.cancelToken.subscribe(l), s.signal && (s.signal.aborted ? l() : s.signal.addEventListener("abort", l)));
1169
- const S = tr(s.url);
1170
- if (S && T.protocols.indexOf(S) === -1) {
1270
+ ), h(), d = null;
1271
+ }, s === void 0 && i.setContentType(null), "setRequestHeader" in d && c.forEach(At(i), function(R, P) {
1272
+ d.setRequestHeader(P, R);
1273
+ }), c.isUndefined(o.withCredentials) || (d.withCredentials = !!o.withCredentials), a && a !== "json" && (d.responseType = o.responseType), f && ([g, b] = ye(f, !0), d.addEventListener("progress", g)), l && d.upload && ([p, w] = ye(l), d.upload.addEventListener("progress", p), d.upload.addEventListener("loadend", w)), (o.cancelToken || o.signal) && (u = (E) => {
1274
+ d && (r(!E || E.type ? new ae(null, t, d) : E), d.abort(), h(), d = null);
1275
+ }, o.cancelToken && o.cancelToken.subscribe(u), o.signal && (o.signal.aborted ? u() : o.signal.addEventListener("abort", u)));
1276
+ const O = br(o.url);
1277
+ if (O && !T.protocols.includes(O)) {
1171
1278
  r(
1172
- new g(
1173
- "Unsupported protocol " + S + ":",
1174
- g.ERR_BAD_REQUEST,
1279
+ new y(
1280
+ "Unsupported protocol " + O + ":",
1281
+ y.ERR_BAD_REQUEST,
1175
1282
  t
1176
1283
  )
1177
1284
  );
1178
1285
  return;
1179
1286
  }
1180
- p.send(o || null);
1287
+ d.send(s || null);
1181
1288
  });
1182
- }, ur = (t, e) => {
1183
- const { length: n } = t = t ? t.filter(Boolean) : [];
1184
- if (e || n) {
1185
- let r = new AbortController(), s;
1186
- const o = function(u) {
1187
- if (!s) {
1188
- s = !0, a();
1189
- const l = u instanceof Error ? u : this.reason;
1190
- r.abort(
1191
- l instanceof g ? l : new Y(l instanceof Error ? l.message : l)
1192
- );
1193
- }
1194
- };
1195
- let i = e && setTimeout(() => {
1196
- i = null, o(new g(`timeout of ${e}ms exceeded`, g.ETIMEDOUT));
1197
- }, e);
1198
- const a = () => {
1199
- t && (i && clearTimeout(i), i = null, t.forEach((u) => {
1200
- u.unsubscribe ? u.unsubscribe(o) : u.removeEventListener("abort", o);
1201
- }), t = null);
1202
- };
1203
- t.forEach((u) => u.addEventListener("abort", o));
1204
- const { signal: f } = r;
1205
- return f.unsubscribe = () => c.asap(a), f;
1206
- }
1207
- }, fr = function* (t, e) {
1289
+ }, Nr = (t, e) => {
1290
+ if (t = t ? t.filter(Boolean) : [], !e && !t.length)
1291
+ return;
1292
+ const n = new AbortController();
1293
+ let r = !1;
1294
+ const o = function(l) {
1295
+ if (!r) {
1296
+ r = !0, i();
1297
+ const f = l instanceof Error ? l : this.reason;
1298
+ n.abort(
1299
+ f instanceof y ? f : new ae(f instanceof Error ? f.message : f)
1300
+ );
1301
+ }
1302
+ };
1303
+ let s = e && setTimeout(() => {
1304
+ s = null, o(new y(`timeout of ${e}ms exceeded`, y.ETIMEDOUT));
1305
+ }, e);
1306
+ const i = () => {
1307
+ t && (s && clearTimeout(s), s = null, t.forEach((l) => {
1308
+ l.unsubscribe ? l.unsubscribe(o) : l.removeEventListener("abort", o);
1309
+ }), t = null);
1310
+ };
1311
+ t.forEach((l) => l.addEventListener("abort", o));
1312
+ const { signal: a } = n;
1313
+ return a.unsubscribe = () => c.asap(i), a;
1314
+ }, Dr = function* (t, e) {
1208
1315
  let n = t.byteLength;
1209
1316
  if (n < e) {
1210
1317
  yield t;
1211
1318
  return;
1212
1319
  }
1213
- let r = 0, s;
1320
+ let r = 0, o;
1214
1321
  for (; r < n; )
1215
- s = r + e, yield t.slice(r, s), r = s;
1216
- }, dr = async function* (t, e) {
1217
- for await (const n of pr(t))
1218
- yield* fr(n, e);
1219
- }, pr = async function* (t) {
1322
+ o = r + e, yield t.slice(r, o), r = o;
1323
+ }, Ur = async function* (t, e) {
1324
+ for await (const n of Fr(t))
1325
+ yield* Dr(n, e);
1326
+ }, Fr = async function* (t) {
1220
1327
  if (t[Symbol.asyncIterator]) {
1221
1328
  yield* t;
1222
1329
  return;
@@ -1232,340 +1339,457 @@ const Tt = (t) => {
1232
1339
  } finally {
1233
1340
  await e.cancel();
1234
1341
  }
1235
- }, Ge = (t, e, n, r) => {
1236
- const s = dr(t, e);
1237
- let o = 0, i, a = (f) => {
1238
- i || (i = !0, r && r(f));
1342
+ }, at = (t, e, n, r) => {
1343
+ const o = Ur(t, e);
1344
+ let s = 0, i, a = (l) => {
1345
+ i || (i = !0, r && r(l));
1239
1346
  };
1240
1347
  return new ReadableStream(
1241
1348
  {
1242
- async pull(f) {
1349
+ async pull(l) {
1243
1350
  try {
1244
- const { done: u, value: l } = await s.next();
1245
- if (u) {
1246
- a(), f.close();
1351
+ const { done: f, value: u } = await o.next();
1352
+ if (f) {
1353
+ a(), l.close();
1247
1354
  return;
1248
1355
  }
1249
- let h = l.byteLength;
1356
+ let p = u.byteLength;
1250
1357
  if (n) {
1251
- let y = o += h;
1252
- n(y);
1358
+ let g = s += p;
1359
+ n(g);
1253
1360
  }
1254
- f.enqueue(new Uint8Array(l));
1255
- } catch (u) {
1256
- throw a(u), u;
1361
+ l.enqueue(new Uint8Array(u));
1362
+ } catch (f) {
1363
+ throw a(f), f;
1257
1364
  }
1258
1365
  },
1259
- cancel(f) {
1260
- return a(f), s.return();
1366
+ cancel(l) {
1367
+ return a(l), o.return();
1261
1368
  }
1262
1369
  },
1263
1370
  {
1264
1371
  highWaterMark: 2
1265
1372
  }
1266
1373
  );
1267
- }, Qe = 64 * 1024, { isFunction: ne } = c, hr = (({ Request: t, Response: e }) => ({
1268
- Request: t,
1269
- Response: e
1270
- }))(c.global), { ReadableStream: Ye, TextEncoder: Ze } = c.global, et = (t, ...e) => {
1374
+ };
1375
+ function jr(t) {
1376
+ if (!t || typeof t != "string" || !t.startsWith("data:")) return 0;
1377
+ const e = t.indexOf(",");
1378
+ if (e < 0) return 0;
1379
+ const n = t.slice(5, e), r = t.slice(e + 1);
1380
+ if (/;base64/i.test(n)) {
1381
+ let i = r.length;
1382
+ const a = r.length;
1383
+ for (let w = 0; w < a; w++)
1384
+ if (r.charCodeAt(w) === 37 && w + 2 < a) {
1385
+ const b = r.charCodeAt(w + 1), h = r.charCodeAt(w + 2);
1386
+ (b >= 48 && b <= 57 || b >= 65 && b <= 70 || b >= 97 && b <= 102) && (h >= 48 && h <= 57 || h >= 65 && h <= 70 || h >= 97 && h <= 102) && (i -= 2, w += 2);
1387
+ }
1388
+ let l = 0, f = a - 1;
1389
+ const u = (w) => w >= 2 && r.charCodeAt(w - 2) === 37 && // '%'
1390
+ r.charCodeAt(w - 1) === 51 && // '3'
1391
+ (r.charCodeAt(w) === 68 || r.charCodeAt(w) === 100);
1392
+ f >= 0 && (r.charCodeAt(f) === 61 ? (l++, f--) : u(f) && (l++, f -= 3)), l === 1 && f >= 0 && (r.charCodeAt(f) === 61 || u(f)) && l++;
1393
+ const g = Math.floor(i / 4) * 3 - (l || 0);
1394
+ return g > 0 ? g : 0;
1395
+ }
1396
+ if (typeof Buffer < "u" && typeof Buffer.byteLength == "function")
1397
+ return Buffer.byteLength(r, "utf8");
1398
+ let s = 0;
1399
+ for (let i = 0, a = r.length; i < a; i++) {
1400
+ const l = r.charCodeAt(i);
1401
+ if (l < 128)
1402
+ s += 1;
1403
+ else if (l < 2048)
1404
+ s += 2;
1405
+ else if (l >= 55296 && l <= 56319 && i + 1 < a) {
1406
+ const f = r.charCodeAt(i + 1);
1407
+ f >= 56320 && f <= 57343 ? (s += 4, i++) : s += 3;
1408
+ } else
1409
+ s += 3;
1410
+ }
1411
+ return s;
1412
+ }
1413
+ const ze = "1.16.1", ct = 64 * 1024, { isFunction: fe } = c, lt = (t, ...e) => {
1271
1414
  try {
1272
1415
  return !!t(...e);
1273
1416
  } catch {
1274
1417
  return !1;
1275
1418
  }
1276
- }, mr = (t) => {
1419
+ }, kr = (t) => {
1420
+ const e = c.global !== void 0 && c.global !== null ? c.global : globalThis, { ReadableStream: n, TextEncoder: r } = e;
1277
1421
  t = c.merge.call(
1278
1422
  {
1279
1423
  skipUndefined: !0
1280
1424
  },
1281
- hr,
1425
+ {
1426
+ Request: e.Request,
1427
+ Response: e.Response
1428
+ },
1282
1429
  t
1283
1430
  );
1284
- const { fetch: e, Request: n, Response: r } = t, s = e ? ne(e) : typeof fetch == "function", o = ne(n), i = ne(r);
1285
- if (!s)
1431
+ const { fetch: o, Request: s, Response: i } = t, a = o ? fe(o) : typeof fetch == "function", l = fe(s), f = fe(i);
1432
+ if (!a)
1286
1433
  return !1;
1287
- const a = s && ne(Ye), f = s && (typeof Ze == "function" ? /* @__PURE__ */ ((d) => (m) => d.encode(m))(new Ze()) : async (d) => new Uint8Array(await new n(d).arrayBuffer())), u = o && a && et(() => {
1288
- let d = !1;
1289
- const m = new n(T.origin, {
1290
- body: new Ye(),
1434
+ const u = a && fe(n), p = a && (typeof r == "function" ? /* @__PURE__ */ ((m) => (O) => m.encode(O))(new r()) : async (m) => new Uint8Array(await new s(m).arrayBuffer())), g = l && u && lt(() => {
1435
+ let m = !1;
1436
+ const O = new s(T.origin, {
1437
+ body: new n(),
1291
1438
  method: "POST",
1292
1439
  get duplex() {
1293
- return d = !0, "half";
1440
+ return m = !0, "half";
1294
1441
  }
1295
- }).headers.has("Content-Type");
1296
- return d && !m;
1297
- }), l = i && a && et(() => c.isReadableStream(new r("").body)), h = {
1298
- stream: l && ((d) => d.body)
1442
+ }), E = O.headers.has("Content-Type");
1443
+ return O.body != null && O.body.cancel(), m && !E;
1444
+ }), w = f && u && lt(() => c.isReadableStream(new i("").body)), b = {
1445
+ stream: w && ((m) => m.body)
1299
1446
  };
1300
- s && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((d) => {
1301
- !h[d] && (h[d] = (m, p) => {
1302
- let w = m && m[d];
1303
- if (w)
1304
- return w.call(m);
1305
- throw new g(
1306
- `Response type '${d}' is not supported`,
1307
- g.ERR_NOT_SUPPORT,
1308
- p
1447
+ a && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((m) => {
1448
+ !b[m] && (b[m] = (O, E) => {
1449
+ let R = O && O[m];
1450
+ if (R)
1451
+ return R.call(O);
1452
+ throw new y(
1453
+ `Response type '${m}' is not supported`,
1454
+ y.ERR_NOT_SUPPORT,
1455
+ E
1309
1456
  );
1310
1457
  });
1311
1458
  });
1312
- const y = async (d) => {
1313
- if (d == null)
1459
+ const h = async (m) => {
1460
+ if (m == null)
1314
1461
  return 0;
1315
- if (c.isBlob(d))
1316
- return d.size;
1317
- if (c.isSpecCompliantForm(d))
1318
- return (await new n(T.origin, {
1462
+ if (c.isBlob(m))
1463
+ return m.size;
1464
+ if (c.isSpecCompliantForm(m))
1465
+ return (await new s(T.origin, {
1319
1466
  method: "POST",
1320
- body: d
1467
+ body: m
1321
1468
  }).arrayBuffer()).byteLength;
1322
- if (c.isArrayBufferView(d) || c.isArrayBuffer(d))
1323
- return d.byteLength;
1324
- if (c.isURLSearchParams(d) && (d = d + ""), c.isString(d))
1325
- return (await f(d)).byteLength;
1326
- }, R = async (d, m) => {
1327
- const p = c.toFiniteNumber(d.getContentLength());
1328
- return p ?? y(m);
1469
+ if (c.isArrayBufferView(m) || c.isArrayBuffer(m))
1470
+ return m.byteLength;
1471
+ if (c.isURLSearchParams(m) && (m = m + ""), c.isString(m))
1472
+ return (await p(m)).byteLength;
1473
+ }, d = async (m, O) => {
1474
+ const E = c.toFiniteNumber(m.getContentLength());
1475
+ return E ?? h(O);
1329
1476
  };
1330
- return async (d) => {
1477
+ return async (m) => {
1331
1478
  let {
1332
- url: m,
1333
- method: p,
1334
- data: w,
1335
- signal: S,
1336
- cancelToken: b,
1337
- timeout: O,
1338
- onDownloadProgress: P,
1339
- onUploadProgress: k,
1340
- responseType: L,
1341
- headers: pe,
1342
- withCredentials: Z = "same-origin",
1343
- fetchOptions: je
1344
- } = Tt(d), ke = e || fetch;
1345
- L = L ? (L + "").toLowerCase() : "text";
1346
- let ee = ur(
1347
- [S, b && b.toAbortSignal()],
1348
- O
1349
- ), $ = null;
1350
- const D = ee && ee.unsubscribe && (() => {
1351
- ee.unsubscribe();
1479
+ url: O,
1480
+ method: E,
1481
+ data: R,
1482
+ signal: P,
1483
+ cancelToken: q,
1484
+ timeout: G,
1485
+ onDownloadProgress: Se,
1486
+ onUploadProgress: Ve,
1487
+ responseType: B,
1488
+ headers: M,
1489
+ withCredentials: ce = "same-origin",
1490
+ fetchOptions: Ke,
1491
+ maxContentLength: F,
1492
+ maxBodyLength: _e
1493
+ } = Ft(m);
1494
+ const Q = c.isNumber(F) && F > -1, zt = c.isNumber(_e) && _e > -1;
1495
+ let Xe = o || fetch;
1496
+ B = B ? (B + "").toLowerCase() : "text";
1497
+ let v = Nr(
1498
+ [P, q && q.toAbortSignal()],
1499
+ G
1500
+ ), N = null;
1501
+ const H = v && v.unsubscribe && (() => {
1502
+ v.unsubscribe();
1352
1503
  });
1353
- let De;
1504
+ let Ge;
1354
1505
  try {
1355
- if (k && u && p !== "get" && p !== "head" && (De = await R(pe, w)) !== 0) {
1356
- let j = new n(m, {
1506
+ if (Q && typeof O == "string" && O.startsWith("data:") && jr(O) > F)
1507
+ throw new y(
1508
+ "maxContentLength size of " + F + " exceeded",
1509
+ y.ERR_BAD_RESPONSE,
1510
+ m,
1511
+ N
1512
+ );
1513
+ if (zt && E !== "get" && E !== "head") {
1514
+ const S = await d(M, R);
1515
+ if (typeof S == "number" && isFinite(S) && S > _e)
1516
+ throw new y(
1517
+ "Request body larger than maxBodyLength limit",
1518
+ y.ERR_BAD_REQUEST,
1519
+ m,
1520
+ N
1521
+ );
1522
+ }
1523
+ if (Ve && g && E !== "get" && E !== "head" && (Ge = await d(M, R)) !== 0) {
1524
+ let S = new s(O, {
1357
1525
  method: "POST",
1358
- body: w,
1526
+ body: R,
1359
1527
  duplex: "half"
1360
- }), q;
1361
- if (c.isFormData(w) && (q = j.headers.get("content-type")) && pe.setContentType(q), j.body) {
1362
- const [he, te] = Ve(
1363
- De,
1364
- ae(Ke(k))
1528
+ }), W;
1529
+ if (c.isFormData(R) && (W = S.headers.get("content-type")) && M.setContentType(W), S.body) {
1530
+ const [le, ue] = ot(
1531
+ Ge,
1532
+ ye(st(Ve))
1365
1533
  );
1366
- w = Ge(j.body, Qe, he, te);
1534
+ R = at(S.body, ct, le, ue);
1367
1535
  }
1368
1536
  }
1369
- c.isString(Z) || (Z = Z ? "include" : "omit");
1370
- const A = o && "credentials" in n.prototype, Be = {
1371
- ...je,
1372
- signal: ee,
1373
- method: p.toUpperCase(),
1374
- headers: pe.normalize().toJSON(),
1375
- body: w,
1537
+ c.isString(ce) || (ce = ce ? "include" : "omit");
1538
+ const A = l && "credentials" in s.prototype;
1539
+ if (c.isFormData(R)) {
1540
+ const S = M.getContentType();
1541
+ S && /^multipart\/form-data/i.test(S) && !/boundary=/i.test(S) && M.delete("content-type");
1542
+ }
1543
+ M.set("User-Agent", "axios/" + ze, !1);
1544
+ const I = {
1545
+ ...Ke,
1546
+ signal: v,
1547
+ method: E.toUpperCase(),
1548
+ headers: At(M.normalize()),
1549
+ body: R,
1376
1550
  duplex: "half",
1377
- credentials: A ? Z : void 0
1551
+ credentials: A ? ce : void 0
1378
1552
  };
1379
- $ = o && new n(m, Be);
1380
- let F = await (o ? ke($, je) : ke(m, Be));
1381
- const ve = l && (L === "stream" || L === "response");
1382
- if (l && (P || ve && D)) {
1383
- const j = {};
1384
- ["status", "statusText", "headers"].forEach((Ie) => {
1385
- j[Ie] = F[Ie];
1553
+ N = l && new s(O, I);
1554
+ let j = await (l ? Xe(N, Ke) : Xe(O, I));
1555
+ if (Q) {
1556
+ const S = c.toFiniteNumber(j.headers.get("content-length"));
1557
+ if (S != null && S > F)
1558
+ throw new y(
1559
+ "maxContentLength size of " + F + " exceeded",
1560
+ y.ERR_BAD_RESPONSE,
1561
+ m,
1562
+ N
1563
+ );
1564
+ }
1565
+ const Ae = w && (B === "stream" || B === "response");
1566
+ if (w && j.body && (Se || Q || Ae && H)) {
1567
+ const S = {};
1568
+ ["status", "statusText", "headers"].forEach((Y) => {
1569
+ S[Y] = j[Y];
1386
1570
  });
1387
- const q = c.toFiniteNumber(F.headers.get("content-length")), [he, te] = P && Ve(
1388
- q,
1389
- ae(Ke(P), !0)
1571
+ const W = c.toFiniteNumber(j.headers.get("content-length")), [le, ue] = Se && ot(
1572
+ W,
1573
+ ye(st(Se), !0)
1390
1574
  ) || [];
1391
- F = new r(
1392
- Ge(F.body, Qe, he, () => {
1393
- te && te(), D && D();
1575
+ let Qe = 0;
1576
+ const Jt = (Y) => {
1577
+ if (Q && (Qe = Y, Qe > F))
1578
+ throw new y(
1579
+ "maxContentLength size of " + F + " exceeded",
1580
+ y.ERR_BAD_RESPONSE,
1581
+ m,
1582
+ N
1583
+ );
1584
+ le && le(Y);
1585
+ };
1586
+ j = new i(
1587
+ at(j.body, ct, Jt, () => {
1588
+ ue && ue(), H && H();
1394
1589
  }),
1395
- j
1590
+ S
1396
1591
  );
1397
1592
  }
1398
- L = L || "text";
1399
- let kt = await h[c.findKey(h, L) || "text"](
1400
- F,
1401
- d
1593
+ B = B || "text";
1594
+ let k = await b[c.findKey(b, B) || "text"](
1595
+ j,
1596
+ m
1402
1597
  );
1403
- return !ve && D && D(), await new Promise((j, q) => {
1404
- St(j, q, {
1405
- data: kt,
1406
- headers: _.from(F.headers),
1407
- status: F.status,
1408
- statusText: F.statusText,
1409
- config: d,
1410
- request: $
1598
+ if (Q && !w && !Ae) {
1599
+ let S;
1600
+ if (k != null && (typeof k.byteLength == "number" ? S = k.byteLength : typeof k.size == "number" ? S = k.size : typeof k == "string" && (S = typeof r == "function" ? new r().encode(k).byteLength : k.length)), typeof S == "number" && S > F)
1601
+ throw new y(
1602
+ "maxContentLength size of " + F + " exceeded",
1603
+ y.ERR_BAD_RESPONSE,
1604
+ m,
1605
+ N
1606
+ );
1607
+ }
1608
+ return !Ae && H && H(), await new Promise((S, W) => {
1609
+ Dt(S, W, {
1610
+ data: k,
1611
+ headers: x.from(j.headers),
1612
+ status: j.status,
1613
+ statusText: j.statusText,
1614
+ config: m,
1615
+ request: N
1411
1616
  });
1412
1617
  });
1413
1618
  } catch (A) {
1414
- throw D && D(), A && A.name === "TypeError" && /Load failed|fetch/i.test(A.message) ? Object.assign(
1415
- new g(
1619
+ if (H && H(), v && v.aborted && v.reason instanceof y) {
1620
+ const I = v.reason;
1621
+ throw I.config = m, N && (I.request = N), A !== I && (I.cause = A), I;
1622
+ }
1623
+ throw A && A.name === "TypeError" && /Load failed|fetch/i.test(A.message) ? Object.assign(
1624
+ new y(
1416
1625
  "Network Error",
1417
- g.ERR_NETWORK,
1418
- d,
1419
- $,
1626
+ y.ERR_NETWORK,
1627
+ m,
1628
+ N,
1420
1629
  A && A.response
1421
1630
  ),
1422
1631
  {
1423
1632
  cause: A.cause || A
1424
1633
  }
1425
- ) : g.from(A, A && A.code, d, $, A && A.response);
1634
+ ) : y.from(A, A && A.code, m, N, A && A.response);
1426
1635
  }
1427
1636
  };
1428
- }, gr = /* @__PURE__ */ new Map(), At = (t) => {
1637
+ }, Br = /* @__PURE__ */ new Map(), jt = (t) => {
1429
1638
  let e = t && t.env || {};
1430
- const { fetch: n, Request: r, Response: s } = e, o = [r, s, n];
1431
- let i = o.length, a = i, f, u, l = gr;
1639
+ const { fetch: n, Request: r, Response: o } = e, s = [r, o, n];
1640
+ let i = s.length, a = i, l, f, u = Br;
1432
1641
  for (; a--; )
1433
- f = o[a], u = l.get(f), u === void 0 && l.set(f, u = a ? /* @__PURE__ */ new Map() : mr(e)), l = u;
1434
- return u;
1642
+ l = s[a], f = u.get(l), f === void 0 && u.set(l, f = a ? /* @__PURE__ */ new Map() : kr(e)), u = f;
1643
+ return f;
1435
1644
  };
1436
- At();
1437
- const Ue = {
1438
- http: Fn,
1439
- xhr: lr,
1645
+ jt();
1646
+ const Je = {
1647
+ http: rr,
1648
+ xhr: Lr,
1440
1649
  fetch: {
1441
- get: At
1650
+ get: jt
1442
1651
  }
1443
1652
  };
1444
- c.forEach(Ue, (t, e) => {
1653
+ c.forEach(Je, (t, e) => {
1445
1654
  if (t) {
1446
1655
  try {
1447
- Object.defineProperty(t, "name", { value: e });
1656
+ Object.defineProperty(t, "name", { __proto__: null, value: e });
1448
1657
  } catch {
1449
1658
  }
1450
- Object.defineProperty(t, "adapterName", { value: e });
1659
+ Object.defineProperty(t, "adapterName", { __proto__: null, value: e });
1451
1660
  }
1452
1661
  });
1453
- const tt = (t) => `- ${t}`, yr = (t) => c.isFunction(t) || t === null || t === !1;
1454
- function wr(t, e) {
1662
+ const ut = (t) => `- ${t}`, vr = (t) => c.isFunction(t) || t === null || t === !1;
1663
+ function Ir(t, e) {
1455
1664
  t = c.isArray(t) ? t : [t];
1456
1665
  const { length: n } = t;
1457
- let r, s;
1458
- const o = {};
1666
+ let r, o;
1667
+ const s = {};
1459
1668
  for (let i = 0; i < n; i++) {
1460
1669
  r = t[i];
1461
1670
  let a;
1462
- if (s = r, !yr(r) && (s = Ue[(a = String(r)).toLowerCase()], s === void 0))
1463
- throw new g(`Unknown adapter '${a}'`);
1464
- if (s && (c.isFunction(s) || (s = s.get(e))))
1671
+ if (o = r, !vr(r) && (o = Je[(a = String(r)).toLowerCase()], o === void 0))
1672
+ throw new y(`Unknown adapter '${a}'`);
1673
+ if (o && (c.isFunction(o) || (o = o.get(e))))
1465
1674
  break;
1466
- o[a || "#" + i] = s;
1675
+ s[a || "#" + i] = o;
1467
1676
  }
1468
- if (!s) {
1469
- const i = Object.entries(o).map(
1470
- ([f, u]) => `adapter ${f} ` + (u === !1 ? "is not supported by the environment" : "is not available in the build")
1677
+ if (!o) {
1678
+ const i = Object.entries(s).map(
1679
+ ([l, f]) => `adapter ${l} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
1471
1680
  );
1472
1681
  let a = n ? i.length > 1 ? `since :
1473
- ` + i.map(tt).join(`
1474
- `) : " " + tt(i[0]) : "as no adapter specified";
1475
- throw new g(
1682
+ ` + i.map(ut).join(`
1683
+ `) : " " + ut(i[0]) : "as no adapter specified";
1684
+ throw new y(
1476
1685
  "There is no suitable adapter to dispatch the request " + a,
1477
1686
  "ERR_NOT_SUPPORT"
1478
1687
  );
1479
1688
  }
1480
- return s;
1689
+ return o;
1481
1690
  }
1482
- const xt = {
1691
+ const kt = {
1483
1692
  /**
1484
1693
  * Resolve an adapter from a list of adapter names or functions.
1485
1694
  * @type {Function}
1486
1695
  */
1487
- getAdapter: wr,
1696
+ getAdapter: Ir,
1488
1697
  /**
1489
1698
  * Exposes all known adapters
1490
1699
  * @type {Object<string, Function|Object>}
1491
1700
  */
1492
- adapters: Ue
1701
+ adapters: Je
1493
1702
  };
1494
- function Re(t) {
1703
+ function Ne(t) {
1495
1704
  if (t.cancelToken && t.cancelToken.throwIfRequested(), t.signal && t.signal.aborted)
1496
- throw new Y(null, t);
1705
+ throw new ae(null, t);
1497
1706
  }
1498
- function nt(t) {
1499
- return Re(t), t.headers = _.from(t.headers), t.data = be.call(t, t.transformRequest), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), xt.getAdapter(t.adapter || Q.adapter, t)(t).then(
1707
+ function ft(t) {
1708
+ return Ne(t), t.headers = x.from(t.headers), t.data = Le.call(t, t.transformRequest), ["post", "put", "patch"].indexOf(t.method) !== -1 && t.headers.setContentType("application/x-www-form-urlencoded", !1), kt.getAdapter(t.adapter || ie.adapter, t)(t).then(
1500
1709
  function(r) {
1501
- return Re(t), r.data = be.call(t, t.transformResponse, r), r.headers = _.from(r.headers), r;
1710
+ Ne(t), t.response = r;
1711
+ try {
1712
+ r.data = Le.call(t, t.transformResponse, r);
1713
+ } finally {
1714
+ delete t.response;
1715
+ }
1716
+ return r.headers = x.from(r.headers), r;
1502
1717
  },
1503
1718
  function(r) {
1504
- return Et(r) || (Re(t), r && r.response && (r.response.data = be.call(
1505
- t,
1506
- t.transformResponse,
1507
- r.response
1508
- ), r.response.headers = _.from(r.response.headers))), Promise.reject(r);
1719
+ if (!Nt(r) && (Ne(t), r && r.response)) {
1720
+ t.response = r.response;
1721
+ try {
1722
+ r.response.data = Le.call(
1723
+ t,
1724
+ t.transformResponse,
1725
+ r.response
1726
+ );
1727
+ } finally {
1728
+ delete t.response;
1729
+ }
1730
+ r.response.headers = x.from(r.response.headers);
1731
+ }
1732
+ return Promise.reject(r);
1509
1733
  }
1510
1734
  );
1511
1735
  }
1512
- const _t = "1.13.6", de = {};
1736
+ const Oe = {};
1513
1737
  ["object", "boolean", "number", "function", "string", "symbol"].forEach((t, e) => {
1514
- de[t] = function(r) {
1738
+ Oe[t] = function(r) {
1515
1739
  return typeof r === t || "a" + (e < 1 ? "n " : " ") + t;
1516
1740
  };
1517
1741
  });
1518
- const rt = {};
1519
- de.transitional = function(e, n, r) {
1520
- function s(o, i) {
1521
- return "[Axios v" + _t + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
1742
+ const dt = {};
1743
+ Oe.transitional = function(e, n, r) {
1744
+ function o(s, i) {
1745
+ return "[Axios v" + ze + "] Transitional option '" + s + "'" + i + (r ? ". " + r : "");
1522
1746
  }
1523
- return (o, i, a) => {
1747
+ return (s, i, a) => {
1524
1748
  if (e === !1)
1525
- throw new g(
1526
- s(i, " has been removed" + (n ? " in " + n : "")),
1527
- g.ERR_DEPRECATED
1749
+ throw new y(
1750
+ o(i, " has been removed" + (n ? " in " + n : "")),
1751
+ y.ERR_DEPRECATED
1528
1752
  );
1529
- return n && !rt[i] && (rt[i] = !0, console.warn(
1530
- s(
1753
+ return n && !dt[i] && (dt[i] = !0, console.warn(
1754
+ o(
1531
1755
  i,
1532
1756
  " has been deprecated since v" + n + " and will be removed in the near future"
1533
1757
  )
1534
- )), e ? e(o, i, a) : !0;
1758
+ )), e ? e(s, i, a) : !0;
1535
1759
  };
1536
1760
  };
1537
- de.spelling = function(e) {
1761
+ Oe.spelling = function(e) {
1538
1762
  return (n, r) => (console.warn(`${r} is likely a misspelling of ${e}`), !0);
1539
1763
  };
1540
- function br(t, e, n) {
1764
+ function qr(t, e, n) {
1541
1765
  if (typeof t != "object")
1542
- throw new g("options must be an object", g.ERR_BAD_OPTION_VALUE);
1766
+ throw new y("options must be an object", y.ERR_BAD_OPTION_VALUE);
1543
1767
  const r = Object.keys(t);
1544
- let s = r.length;
1545
- for (; s-- > 0; ) {
1546
- const o = r[s], i = e[o];
1768
+ let o = r.length;
1769
+ for (; o-- > 0; ) {
1770
+ const s = r[o], i = Object.prototype.hasOwnProperty.call(e, s) ? e[s] : void 0;
1547
1771
  if (i) {
1548
- const a = t[o], f = a === void 0 || i(a, o, t);
1549
- if (f !== !0)
1550
- throw new g(
1551
- "option " + o + " must be " + f,
1552
- g.ERR_BAD_OPTION_VALUE
1772
+ const a = t[s], l = a === void 0 || i(a, s, t);
1773
+ if (l !== !0)
1774
+ throw new y(
1775
+ "option " + s + " must be " + l,
1776
+ y.ERR_BAD_OPTION_VALUE
1553
1777
  );
1554
1778
  continue;
1555
1779
  }
1556
1780
  if (n !== !0)
1557
- throw new g("Unknown option " + o, g.ERR_BAD_OPTION);
1781
+ throw new y("Unknown option " + s, y.ERR_BAD_OPTION);
1558
1782
  }
1559
1783
  }
1560
- const ie = {
1561
- assertOptions: br,
1562
- validators: de
1563
- }, N = ie.validators;
1564
- let v = class {
1784
+ const me = {
1785
+ assertOptions: qr,
1786
+ validators: Oe
1787
+ }, D = me.validators;
1788
+ let z = class {
1565
1789
  constructor(e) {
1566
1790
  this.defaults = e || {}, this.interceptors = {
1567
- request: new We(),
1568
- response: new We()
1791
+ request: new rt(),
1792
+ response: new rt()
1569
1793
  };
1570
1794
  }
1571
1795
  /**
@@ -1581,12 +1805,25 @@ let v = class {
1581
1805
  return await this._request(e, n);
1582
1806
  } catch (r) {
1583
1807
  if (r instanceof Error) {
1584
- let s = {};
1585
- Error.captureStackTrace ? Error.captureStackTrace(s) : s = new Error();
1586
- const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
1808
+ let o = {};
1809
+ Error.captureStackTrace ? Error.captureStackTrace(o) : o = new Error();
1810
+ const s = (() => {
1811
+ if (!o.stack)
1812
+ return "";
1813
+ const i = o.stack.indexOf(`
1814
+ `);
1815
+ return i === -1 ? "" : o.stack.slice(i + 1);
1816
+ })();
1587
1817
  try {
1588
- r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
1589
- ` + o) : r.stack = o;
1818
+ if (!r.stack)
1819
+ r.stack = s;
1820
+ else if (s) {
1821
+ const i = s.indexOf(`
1822
+ `), a = i === -1 ? -1 : s.indexOf(`
1823
+ `, i + 1), l = a === -1 ? "" : s.slice(a + 1);
1824
+ String(r.stack).endsWith(l) || (r.stack += `
1825
+ ` + s);
1826
+ }
1590
1827
  } catch {
1591
1828
  }
1592
1829
  }
@@ -1594,88 +1831,88 @@ let v = class {
1594
1831
  }
1595
1832
  }
1596
1833
  _request(e, n) {
1597
- typeof e == "string" ? (n = n || {}, n.url = e) : n = e || {}, n = I(this.defaults, n);
1598
- const { transitional: r, paramsSerializer: s, headers: o } = n;
1599
- r !== void 0 && ie.assertOptions(
1834
+ typeof e == "string" ? (n = n || {}, n.url = e) : n = e || {}, n = J(this.defaults, n);
1835
+ const { transitional: r, paramsSerializer: o, headers: s } = n;
1836
+ r !== void 0 && me.assertOptions(
1600
1837
  r,
1601
1838
  {
1602
- silentJSONParsing: N.transitional(N.boolean),
1603
- forcedJSONParsing: N.transitional(N.boolean),
1604
- clarifyTimeoutError: N.transitional(N.boolean),
1605
- legacyInterceptorReqResOrdering: N.transitional(N.boolean)
1839
+ silentJSONParsing: D.transitional(D.boolean),
1840
+ forcedJSONParsing: D.transitional(D.boolean),
1841
+ clarifyTimeoutError: D.transitional(D.boolean),
1842
+ legacyInterceptorReqResOrdering: D.transitional(D.boolean)
1606
1843
  },
1607
1844
  !1
1608
- ), s != null && (c.isFunction(s) ? n.paramsSerializer = {
1609
- serialize: s
1610
- } : ie.assertOptions(
1611
- s,
1845
+ ), o != null && (c.isFunction(o) ? n.paramsSerializer = {
1846
+ serialize: o
1847
+ } : me.assertOptions(
1848
+ o,
1612
1849
  {
1613
- encode: N.function,
1614
- serialize: N.function
1850
+ encode: D.function,
1851
+ serialize: D.function
1615
1852
  },
1616
1853
  !0
1617
- )), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), ie.assertOptions(
1854
+ )), n.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? n.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : n.allowAbsoluteUrls = !0), me.assertOptions(
1618
1855
  n,
1619
1856
  {
1620
- baseUrl: N.spelling("baseURL"),
1621
- withXsrfToken: N.spelling("withXSRFToken")
1857
+ baseUrl: D.spelling("baseURL"),
1858
+ withXsrfToken: D.spelling("withXSRFToken")
1622
1859
  },
1623
1860
  !0
1624
1861
  ), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1625
- let i = o && c.merge(o.common, o[n.method]);
1626
- o && c.forEach(["delete", "get", "head", "post", "put", "patch", "common"], (d) => {
1627
- delete o[d];
1628
- }), n.headers = _.concat(i, o);
1862
+ let i = s && c.merge(s.common, s[n.method]);
1863
+ s && c.forEach(["delete", "get", "head", "post", "put", "patch", "query", "common"], (b) => {
1864
+ delete s[b];
1865
+ }), n.headers = x.concat(i, s);
1629
1866
  const a = [];
1630
- let f = !0;
1631
- this.interceptors.request.forEach(function(m) {
1632
- if (typeof m.runWhen == "function" && m.runWhen(n) === !1)
1867
+ let l = !0;
1868
+ this.interceptors.request.forEach(function(h) {
1869
+ if (typeof h.runWhen == "function" && h.runWhen(n) === !1)
1633
1870
  return;
1634
- f = f && m.synchronous;
1635
- const p = n.transitional || Le;
1636
- p && p.legacyInterceptorReqResOrdering ? a.unshift(m.fulfilled, m.rejected) : a.push(m.fulfilled, m.rejected);
1871
+ l = l && h.synchronous;
1872
+ const d = n.transitional || He;
1873
+ d && d.legacyInterceptorReqResOrdering ? a.unshift(h.fulfilled, h.rejected) : a.push(h.fulfilled, h.rejected);
1637
1874
  });
1638
- const u = [];
1639
- this.interceptors.response.forEach(function(m) {
1640
- u.push(m.fulfilled, m.rejected);
1875
+ const f = [];
1876
+ this.interceptors.response.forEach(function(h) {
1877
+ f.push(h.fulfilled, h.rejected);
1641
1878
  });
1642
- let l, h = 0, y;
1643
- if (!f) {
1644
- const d = [nt.bind(this), void 0];
1645
- for (d.unshift(...a), d.push(...u), y = d.length, l = Promise.resolve(n); h < y; )
1646
- l = l.then(d[h++], d[h++]);
1647
- return l;
1879
+ let u, p = 0, g;
1880
+ if (!l) {
1881
+ const b = [ft.bind(this), void 0];
1882
+ for (b.unshift(...a), b.push(...f), g = b.length, u = Promise.resolve(n); p < g; )
1883
+ u = u.then(b[p++], b[p++]);
1884
+ return u;
1648
1885
  }
1649
- y = a.length;
1650
- let R = n;
1651
- for (; h < y; ) {
1652
- const d = a[h++], m = a[h++];
1886
+ g = a.length;
1887
+ let w = n;
1888
+ for (; p < g; ) {
1889
+ const b = a[p++], h = a[p++];
1653
1890
  try {
1654
- R = d(R);
1655
- } catch (p) {
1656
- m.call(this, p);
1891
+ w = b(w);
1892
+ } catch (d) {
1893
+ h.call(this, d);
1657
1894
  break;
1658
1895
  }
1659
1896
  }
1660
1897
  try {
1661
- l = nt.call(this, R);
1662
- } catch (d) {
1663
- return Promise.reject(d);
1898
+ u = ft.call(this, w);
1899
+ } catch (b) {
1900
+ return Promise.reject(b);
1664
1901
  }
1665
- for (h = 0, y = u.length; h < y; )
1666
- l = l.then(u[h++], u[h++]);
1667
- return l;
1902
+ for (p = 0, g = f.length; p < g; )
1903
+ u = u.then(f[p++], f[p++]);
1904
+ return u;
1668
1905
  }
1669
1906
  getUri(e) {
1670
- e = I(this.defaults, e);
1671
- const n = Ot(e.baseURL, e.url, e.allowAbsoluteUrls);
1672
- return bt(n, e.params, e.paramsSerializer);
1907
+ e = J(this.defaults, e);
1908
+ const n = Ut(e.baseURL, e.url, e.allowAbsoluteUrls);
1909
+ return Pt(n, e.params, e.paramsSerializer);
1673
1910
  }
1674
1911
  };
1675
1912
  c.forEach(["delete", "get", "head", "options"], function(e) {
1676
- v.prototype[e] = function(n, r) {
1913
+ z.prototype[e] = function(n, r) {
1677
1914
  return this.request(
1678
- I(r || {}, {
1915
+ J(r || {}, {
1679
1916
  method: e,
1680
1917
  url: n,
1681
1918
  data: (r || {}).data
@@ -1683,48 +1920,48 @@ c.forEach(["delete", "get", "head", "options"], function(e) {
1683
1920
  );
1684
1921
  };
1685
1922
  });
1686
- c.forEach(["post", "put", "patch"], function(e) {
1923
+ c.forEach(["post", "put", "patch", "query"], function(e) {
1687
1924
  function n(r) {
1688
- return function(o, i, a) {
1925
+ return function(s, i, a) {
1689
1926
  return this.request(
1690
- I(a || {}, {
1927
+ J(a || {}, {
1691
1928
  method: e,
1692
1929
  headers: r ? {
1693
1930
  "Content-Type": "multipart/form-data"
1694
1931
  } : {},
1695
- url: o,
1932
+ url: s,
1696
1933
  data: i
1697
1934
  })
1698
1935
  );
1699
1936
  };
1700
1937
  }
1701
- v.prototype[e] = n(), v.prototype[e + "Form"] = n(!0);
1938
+ z.prototype[e] = n(), e !== "query" && (z.prototype[e + "Form"] = n(!0));
1702
1939
  });
1703
- let Rr = class Ct {
1940
+ let Mr = class Bt {
1704
1941
  constructor(e) {
1705
1942
  if (typeof e != "function")
1706
1943
  throw new TypeError("executor must be a function.");
1707
1944
  let n;
1708
- this.promise = new Promise(function(o) {
1709
- n = o;
1945
+ this.promise = new Promise(function(s) {
1946
+ n = s;
1710
1947
  });
1711
1948
  const r = this;
1712
- this.promise.then((s) => {
1949
+ this.promise.then((o) => {
1713
1950
  if (!r._listeners) return;
1714
- let o = r._listeners.length;
1715
- for (; o-- > 0; )
1716
- r._listeners[o](s);
1951
+ let s = r._listeners.length;
1952
+ for (; s-- > 0; )
1953
+ r._listeners[s](o);
1717
1954
  r._listeners = null;
1718
- }), this.promise.then = (s) => {
1719
- let o;
1955
+ }), this.promise.then = (o) => {
1956
+ let s;
1720
1957
  const i = new Promise((a) => {
1721
- r.subscribe(a), o = a;
1722
- }).then(s);
1958
+ r.subscribe(a), s = a;
1959
+ }).then(o);
1723
1960
  return i.cancel = function() {
1724
- r.unsubscribe(o);
1961
+ r.unsubscribe(s);
1725
1962
  }, i;
1726
- }, e(function(o, i, a) {
1727
- r.reason || (r.reason = new Y(o, i, a), n(r.reason));
1963
+ }, e(function(s, i, a) {
1964
+ r.reason || (r.reason = new ae(s, i, a), n(r.reason));
1728
1965
  });
1729
1966
  }
1730
1967
  /**
@@ -1766,22 +2003,22 @@ let Rr = class Ct {
1766
2003
  static source() {
1767
2004
  let e;
1768
2005
  return {
1769
- token: new Ct(function(s) {
1770
- e = s;
2006
+ token: new Bt(function(o) {
2007
+ e = o;
1771
2008
  }),
1772
2009
  cancel: e
1773
2010
  };
1774
2011
  }
1775
2012
  };
1776
- function Er(t) {
2013
+ function Hr(t) {
1777
2014
  return function(n) {
1778
2015
  return t.apply(null, n);
1779
2016
  };
1780
2017
  }
1781
- function Sr(t) {
2018
+ function $r(t) {
1782
2019
  return c.isObject(t) && t.isAxiosError === !0;
1783
2020
  }
1784
- const Ae = {
2021
+ const Be = {
1785
2022
  Continue: 100,
1786
2023
  SwitchingProtocols: 101,
1787
2024
  Processing: 102,
@@ -1852,73 +2089,74 @@ const Ae = {
1852
2089
  SslHandshakeFailed: 525,
1853
2090
  InvalidSslCertificate: 526
1854
2091
  };
1855
- Object.entries(Ae).forEach(([t, e]) => {
1856
- Ae[e] = t;
2092
+ Object.entries(Be).forEach(([t, e]) => {
2093
+ Be[e] = t;
1857
2094
  });
1858
- function Pt(t) {
1859
- const e = new v(t), n = ct(v.prototype.request, e);
1860
- return c.extend(n, v.prototype, e, { allOwnKeys: !0 }), c.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(s) {
1861
- return Pt(I(t, s));
2095
+ function vt(t) {
2096
+ const e = new z(t), n = gt(z.prototype.request, e);
2097
+ return c.extend(n, z.prototype, e, { allOwnKeys: !0 }), c.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(o) {
2098
+ return vt(J(t, o));
1862
2099
  }, n;
1863
2100
  }
1864
- const E = Pt(Q);
1865
- E.Axios = v;
1866
- E.CanceledError = Y;
1867
- E.CancelToken = Rr;
1868
- E.isCancel = Et;
1869
- E.VERSION = _t;
1870
- E.toFormData = fe;
1871
- E.AxiosError = g;
1872
- E.Cancel = E.CanceledError;
1873
- E.all = function(e) {
2101
+ const _ = vt(ie);
2102
+ _.Axios = z;
2103
+ _.CanceledError = ae;
2104
+ _.CancelToken = Mr;
2105
+ _.isCancel = Nt;
2106
+ _.VERSION = ze;
2107
+ _.toFormData = Re;
2108
+ _.AxiosError = y;
2109
+ _.Cancel = _.CanceledError;
2110
+ _.all = function(e) {
1874
2111
  return Promise.all(e);
1875
2112
  };
1876
- E.spread = Er;
1877
- E.isAxiosError = Sr;
1878
- E.mergeConfig = I;
1879
- E.AxiosHeaders = _;
1880
- E.formToJSON = (t) => Rt(c.isHTMLForm(t) ? new FormData(t) : t);
1881
- E.getAdapter = xt.getAdapter;
1882
- E.HttpStatusCode = Ae;
1883
- E.default = E;
2113
+ _.spread = Hr;
2114
+ _.isAxiosError = $r;
2115
+ _.mergeConfig = J;
2116
+ _.AxiosHeaders = x;
2117
+ _.formToJSON = (t) => Lt(c.isHTMLForm(t) ? new FormData(t) : t);
2118
+ _.getAdapter = kt.getAdapter;
2119
+ _.HttpStatusCode = Be;
2120
+ _.default = _;
1884
2121
  const {
1885
- Axios: ss,
1886
- AxiosError: os,
1887
- CanceledError: is,
1888
- isCancel: as,
1889
- CancelToken: cs,
1890
- VERSION: ls,
1891
- all: us,
1892
- Cancel: fs,
1893
- isAxiosError: ds,
1894
- spread: ps,
1895
- toFormData: hs,
1896
- AxiosHeaders: ms,
1897
- HttpStatusCode: gs,
1898
- formToJSON: ys,
1899
- getAdapter: ws,
1900
- mergeConfig: bs
1901
- } = E, Or = {
2122
+ Axios: To,
2123
+ AxiosError: xo,
2124
+ CanceledError: Co,
2125
+ isCancel: Po,
2126
+ CancelToken: Lo,
2127
+ VERSION: No,
2128
+ all: Do,
2129
+ Cancel: Uo,
2130
+ isAxiosError: Fo,
2131
+ spread: jo,
2132
+ toFormData: ko,
2133
+ AxiosHeaders: Bo,
2134
+ HttpStatusCode: vo,
2135
+ formToJSON: Io,
2136
+ getAdapter: qo,
2137
+ mergeConfig: Mo,
2138
+ create: Ho
2139
+ } = _, zr = {
1902
2140
  form: "application/x-www-form-urlencoded",
1903
2141
  json: "application/json",
1904
2142
  data: "multipart/form-data"
1905
- }, Tr = ["put", "post", "patch"], st = "Local-Request-Id", Ar = 100, xr = 300, _r = "/api/proxy";
1906
- class Cr {
2143
+ }, Jr = ["put", "post", "patch"], pt = "Local-Request-Id", Wr = 100, Vr = 300, Kr = "/api/proxy";
2144
+ class Xr {
1907
2145
  constructor(e = {}) {
1908
- C(this, "axios");
1909
- C(this, "settings");
1910
- C(this, "records", {});
1911
- C(this, "isLoading", !1);
1912
- C(this, "stopSkipWarn");
1913
- C(this, "showLoading");
1914
- C(this, "showError");
2146
+ L(this, "axios");
2147
+ L(this, "settings");
2148
+ L(this, "records", {});
2149
+ L(this, "isLoading", !1);
2150
+ L(this, "stopSkipWarn");
2151
+ L(this, "showLoading");
2152
+ L(this, "showError");
1915
2153
  this.settings = Object.assign({ type: "form" }, e.settings || {});
1916
- const n = me(e, [
2154
+ const n = Te(e, [
1917
2155
  "settings",
1918
2156
  "query"
1919
2157
  ]);
1920
- this.axios = E.create(
1921
- W(
2158
+ this.axios = _.create(
2159
+ ee(
1922
2160
  {
1923
2161
  headers: {
1924
2162
  "Content-Type": "application/x-www-form-urlencoded"
@@ -1927,18 +2165,18 @@ class Cr {
1927
2165
  },
1928
2166
  n
1929
2167
  )
1930
- ), this.setupSkipWarn(this.settings), this.showLoading = vt(this.openLoading.bind(this), Ar), this.showError = It(this._showError.bind(this), xr, {
2168
+ ), this.setupSkipWarn(this.settings), this.showLoading = Kt(this.openLoading.bind(this), Wr), this.showError = Xt(this._showError.bind(this), Vr, {
1931
2169
  leading: !0,
1932
2170
  trailing: !1
1933
2171
  });
1934
2172
  }
1935
2173
  setConfig(e = {}) {
1936
- this.settings = W(this.settings, e.settings || {});
1937
- const n = me(e, [
2174
+ this.settings = ee(this.settings, e.settings || {});
2175
+ const n = Te(e, [
1938
2176
  "settings",
1939
2177
  "query"
1940
2178
  ]);
1941
- this.axios.defaults = W(this.axios.defaults, n), this.setupSkipWarn(this.settings);
2179
+ this.axios.defaults = ee(this.axios.defaults, n), this.setupSkipWarn(this.settings);
1942
2180
  }
1943
2181
  cancel(e, n = "请求已取消") {
1944
2182
  if (e) {
@@ -1950,12 +2188,12 @@ class Cr {
1950
2188
  r.source.cancel(n);
1951
2189
  }
1952
2190
  createHeaders(e, n, r) {
1953
- const s = n.injectHeaders ? typeof n.headers == "function" ? n.headers(e, r, n) : n.headers || {} : {}, o = {
1954
- "Content-Type": Or[n.type || "form"],
2191
+ const o = n.injectHeaders ? typeof n.headers == "function" ? n.headers(e, r, n) : n.headers || {} : {}, s = {
2192
+ "Content-Type": zr[n.type || "form"],
1955
2193
  ...r.headers,
1956
- ...s
2194
+ ...o
1957
2195
  };
1958
- return n.skipWarn && (o[st] = e), o;
2196
+ return n.skipWarn && (s[pt] = e), s;
1959
2197
  }
1960
2198
  isJsonType(e) {
1961
2199
  return Object.entries(e).some(([n, r]) => n.toLowerCase() === "content-type" && String(r).includes("application/json"));
@@ -1964,38 +2202,38 @@ class Cr {
1964
2202
  if (e instanceof FormData || e instanceof URLSearchParams)
1965
2203
  return e;
1966
2204
  const r = n === "data" ? new FormData() : new URLSearchParams();
1967
- return Object.entries(e).forEach(([s, o]) => {
1968
- r.append(s, o);
2205
+ return Object.entries(e).forEach(([o, s]) => {
2206
+ r.append(o, s);
1969
2207
  }), r;
1970
2208
  }
1971
- createSendData(e, n, r, s, o = {}) {
1972
- const { type: i, skipWarn: a } = e, { name: f = "skipWarn" } = a || {};
1973
- let { data: u, params: l = {}, method: h = "get" } = n;
1974
- const y = s ? { [f]: !0 } : {};
1975
- return Tr.includes(h.toLowerCase()) ? (u = Object.assign(u || {}, y), u = i !== "json" || !this.isJsonType(r) ? this.toFormData(u, i) : u, l = {
1976
- ...o
1977
- }) : i === "form" ? l = {
1978
- ...u || {},
1979
- ...o,
1980
- ...y
1981
- } : (u && (i !== "json" || !this.isJsonType(r)) && (u = this.toFormData(u, i)), l = {
1982
- ...o,
1983
- ...y
2209
+ createSendData(e, n, r, o, s = {}) {
2210
+ const { type: i, skipWarn: a } = e, { name: l = "skipWarn" } = a || {};
2211
+ let { data: f, params: u = {}, method: p = "get" } = n;
2212
+ const g = o ? { [l]: !0 } : {};
2213
+ return Jr.includes(p.toLowerCase()) ? (f = Object.assign(f || {}, g), f = i !== "json" || !this.isJsonType(r) ? this.toFormData(f, i) : f, u = {
2214
+ ...s
2215
+ }) : i === "form" ? u = {
2216
+ ...f || {},
2217
+ ...s,
2218
+ ...g
2219
+ } : (f && (i !== "json" || !this.isJsonType(r)) && (f = this.toFormData(f, i)), u = {
2220
+ ...s,
2221
+ ...g
1984
2222
  }), {
1985
- data: u,
1986
- params: l
2223
+ data: f,
2224
+ params: u
1987
2225
  };
1988
2226
  }
1989
2227
  createUrl(e) {
1990
2228
  let { url: n, params: r } = e;
1991
2229
  if (n) {
1992
- let s = qe(n) ? new URL(n).origin : "";
1993
- const o = s ? n.replace(s, "") : n;
2230
+ let o = Ye(n) ? new URL(n).origin : "";
2231
+ const s = o ? n.replace(o, "") : n;
1994
2232
  try {
1995
- const i = qt(o, {
2233
+ const i = Gt(s, {
1996
2234
  encode: encodeURIComponent
1997
2235
  });
1998
- return s + i(r || {});
2236
+ return o + i(r || {});
1999
2237
  } catch {
2000
2238
  console.warn("createUrl", "pathToRegexpCompile error", n);
2001
2239
  }
@@ -2008,9 +2246,9 @@ class Cr {
2008
2246
  url: n,
2009
2247
  headers: r
2010
2248
  };
2011
- const s = e.proxyPath || _r, { protocol: o, host: i } = location || {}, a = qe(n) ? n : `${o}//${i}${n}`;
2249
+ const o = e.proxyPath || Kr, { protocol: s, host: i } = location || {}, a = Ye(n) ? n : `${s}//${i}${n}`;
2012
2250
  return r.Target = a, {
2013
- url: s,
2251
+ url: o,
2014
2252
  headers: r
2015
2253
  };
2016
2254
  }
@@ -2025,163 +2263,163 @@ class Cr {
2025
2263
  n && r.length === 0 && (this.isLoading = !1, n());
2026
2264
  }
2027
2265
  _showError(e, n) {
2028
- const { failMessage: r, showError: s } = e;
2029
- if (r && s) {
2030
- const o = n?.response?.data, i = o?.message || o?.msg || n?.message || n?.msg || "未知错误";
2031
- s(i, n);
2266
+ const { failMessage: r, showError: o } = e;
2267
+ if (r && o) {
2268
+ const s = n?.response?.data, i = s?.message || s?.msg || n?.message || n?.msg || "未知错误";
2269
+ o(i, n);
2032
2270
  }
2033
2271
  }
2034
2272
  validResponse(e, n) {
2035
- const { validSuccess: r, validate: s } = e;
2036
- return r && s ? !!s(n) : !0;
2273
+ const { validSuccess: r, validate: o } = e;
2274
+ return r && o ? !!o(n) : !0;
2037
2275
  }
2038
2276
  isSkipWarnResponse(e) {
2039
2277
  return !!e.promise;
2040
2278
  }
2041
2279
  send(e = {}, n = !1) {
2042
- const r = W({}, this.settings, e.settings || {}), s = e.query || {}, o = me(e, [
2280
+ const r = ee({}, this.settings, e.settings || {}), o = e.query || {}, s = Te(e, [
2043
2281
  "settings",
2044
2282
  "query"
2045
- ]), i = Mt(!1), a = E.CancelToken.source();
2046
- this.records[i] = { settings: r, config: o, source: a };
2047
- const f = this.createUrl(o) || "", u = this.createHeaders(i, r, o), { url: l, headers: h } = this.createProxy(r, f, u), { data: y, params: R } = this.createSendData(
2283
+ ]), i = Qt(!1), a = _.CancelToken.source();
2284
+ this.records[i] = { settings: r, config: s, source: a };
2285
+ const l = this.createUrl(s) || "", f = this.createHeaders(i, r, s), { url: u, headers: p } = this.createProxy(r, l, f), { data: g, params: w } = this.createSendData(
2048
2286
  r,
2049
- o,
2050
- h,
2287
+ s,
2288
+ p,
2051
2289
  n,
2052
- s
2290
+ o
2053
2291
  );
2054
- return this.showLoading(r), new Promise((d, m) => {
2292
+ return this.showLoading(r), new Promise((b, h) => {
2055
2293
  this.axios({
2056
2294
  cancelToken: a.token,
2057
- ...o,
2058
- url: l,
2059
- headers: h,
2060
- data: y,
2061
- params: R
2062
- }).then((p) => this.isSkipWarnResponse(p) ? d(p.promise) : this.validResponse(r, p) ? d(r.originResponse ? p : p.data?.data) : (this.showError(r, p.data), m(p.data))).catch((p) => (this.showError(r, p), m(p))).finally(() => {
2295
+ ...s,
2296
+ url: u,
2297
+ headers: p,
2298
+ data: g,
2299
+ params: w
2300
+ }).then((d) => this.isSkipWarnResponse(d) ? b(d.promise) : this.validResponse(r, d) ? b(r.originResponse ? d : d.data?.data) : (this.showError(r, d.data), h(d.data))).catch((d) => (this.showError(r, d), h(d))).finally(() => {
2063
2301
  delete this.records[i], this.closeLoading(r);
2064
2302
  });
2065
2303
  });
2066
2304
  }
2067
2305
  useResponse(e, n) {
2068
- const { response: r } = this.axios.interceptors, s = r.use(e, n);
2069
- return () => r.eject(s);
2306
+ const { response: r } = this.axios.interceptors, o = r.use(e, n);
2307
+ return () => r.eject(o);
2070
2308
  }
2071
2309
  useRequest(e, n) {
2072
- const { request: r } = this.axios.interceptors, s = r.use(e, n);
2073
- return () => r.eject(s);
2310
+ const { request: r } = this.axios.interceptors, o = r.use(e, n);
2311
+ return () => r.eject(o);
2074
2312
  }
2075
2313
  setupSkipWarn(e) {
2076
2314
  if (this.stopSkipWarn && (this.stopSkipWarn(), this.stopSkipWarn = void 0), !e.skipWarn) return;
2077
- const { code: n, executor: r, callback: s, complete: o } = e.skipWarn;
2315
+ const { code: n, executor: r, callback: o, complete: s } = e.skipWarn;
2078
2316
  this.stopSkipWarn = this.useResponse((i) => {
2079
- const f = (i.config.headers || {})[st], u = this.records[f];
2080
- if (!u) return i;
2081
- const { data: l } = i;
2082
- if (!l || typeof l != "object") return i;
2083
- if (l?.code === n) {
2084
- s && s(i);
2085
- const h = new Promise(r).then(() => this.send(
2317
+ const l = (i.config.headers || {})[pt], f = this.records[l];
2318
+ if (!f) return i;
2319
+ const { data: u } = i;
2320
+ if (!u || typeof u != "object") return i;
2321
+ if (u?.code === n) {
2322
+ o && o(i);
2323
+ const p = new Promise(r).then(() => this.send(
2086
2324
  {
2087
- ...u.config,
2088
- settings: u.settings
2325
+ ...f.config,
2326
+ settings: f.settings
2089
2327
  },
2090
2328
  !0
2091
2329
  ));
2092
- h.catch((y) => y).finally(() => {
2093
- o && o();
2094
- }), i.promise = h;
2330
+ p.catch((g) => g).finally(() => {
2331
+ s && s();
2332
+ }), i.promise = p;
2095
2333
  }
2096
2334
  return i;
2097
2335
  });
2098
2336
  }
2099
2337
  }
2100
- function Pr(t = {}) {
2101
- const e = new Cr(t), n = e.send.bind(e), r = e.cancel.bind(e), s = e.setConfig.bind(e), o = e.useRequest.bind(e), i = e.useResponse.bind(e);
2338
+ function Gr(t = {}) {
2339
+ const e = new Xr(t), n = e.send.bind(e), r = e.cancel.bind(e), o = e.setConfig.bind(e), s = e.useRequest.bind(e), i = e.useResponse.bind(e);
2102
2340
  return Object.assign(n, {
2103
2341
  ...e,
2104
2342
  instance: e,
2105
2343
  send: n,
2106
2344
  cancel: r,
2107
- setConfig: s,
2108
- useRequest: o,
2345
+ setConfig: o,
2346
+ useRequest: s,
2109
2347
  useResponse: i
2110
2348
  });
2111
2349
  }
2112
- const Lt = Pr({
2350
+ const It = Gr({
2113
2351
  settings: {
2114
2352
  injectHeaders: !0,
2115
2353
  loading: !0,
2116
2354
  originResponse: !0
2117
2355
  }
2118
2356
  });
2119
- function Lr(t, e = Lt) {
2357
+ function Qr(t, e = It) {
2120
2358
  const n = typeof t == "string" ? { url: t } : t;
2121
- return (r, s) => e.send(W({}, n, s || {}, { data: r }));
2359
+ return (r, o) => e.send(ee({}, n, o || {}, { data: r }));
2122
2360
  }
2123
- function Rs(t, e = Lt) {
2361
+ function $o(t, e = It) {
2124
2362
  const n = {};
2125
- for (const [r, s] of Object.entries(t))
2126
- n[r] = Lr(s, e);
2363
+ for (const [r, o] of Object.entries(t))
2364
+ n[r] = Qr(o, e);
2127
2365
  return n;
2128
2366
  }
2129
- function Es(t, e) {
2130
- const n = ge(null), r = ge(), s = ge(!0), o = () => {
2131
- s.value = !0, r.value = void 0, (typeof t == "function" ? t() : t).then((a) => {
2367
+ function zo(t, e) {
2368
+ const n = xe(null), r = xe(), o = xe(!0), s = () => {
2369
+ o.value = !0, r.value = void 0, (typeof t == "function" ? t() : t).then((a) => {
2132
2370
  n.value = e ? e(a) : a;
2133
2371
  }).catch((a) => {
2134
2372
  r.value = a;
2135
2373
  }).finally(() => {
2136
- s.value = !1;
2374
+ o.value = !1;
2137
2375
  });
2138
2376
  };
2139
- return o(), {
2377
+ return s(), {
2140
2378
  data: n,
2141
2379
  error: r,
2142
- loading: s,
2143
- reload: o
2380
+ loading: o,
2381
+ reload: s
2144
2382
  };
2145
2383
  }
2146
- const V = typeof window < "u", Ss = (t) => new Promise((e, n) => {
2384
+ const ne = typeof window < "u", Jo = (t) => new Promise((e, n) => {
2147
2385
  const r = new FileReader();
2148
2386
  r.readAsDataURL(t), r.onload = () => {
2149
2387
  e(r.result);
2150
- }, r.onerror = (s) => {
2151
- n(s);
2388
+ }, r.onerror = (o) => {
2389
+ n(o);
2152
2390
  };
2153
2391
  });
2154
- function Os(t) {
2392
+ function Wo(t) {
2155
2393
  const e = {};
2156
2394
  return t ? (t.forEach((n, r) => {
2157
2395
  e[r] = typeof n == "string" ? decodeURIComponent(n) : n;
2158
2396
  }), e) : {};
2159
2397
  }
2160
- function Ts(t) {
2398
+ function Vo(t) {
2161
2399
  const e = t.split(","), n = e[0].match(/:(.*?);/)?.[1], r = atob(e[1]);
2162
- let s = r.length;
2163
- const o = new Uint8Array(s);
2164
- for (; s--; )
2165
- o[s] = r.charCodeAt(s);
2166
- return new Blob([o], { type: n });
2400
+ let o = r.length;
2401
+ const s = new Uint8Array(o);
2402
+ for (; o--; )
2403
+ s[o] = r.charCodeAt(o);
2404
+ return new Blob([s], { type: n });
2167
2405
  }
2168
- function As(t, e) {
2406
+ function Ko(t, e) {
2169
2407
  const n = t;
2170
2408
  return n.lastModified = Date.now(), n.lastModifiedDate = /* @__PURE__ */ new Date(), n.name = e, n;
2171
2409
  }
2172
- const xs = (t) => V ? window.requestAnimationFrame(t) : setTimeout(t, 16), _s = (t) => V ? window.cancelAnimationFrame(t) : clearTimeout(t);
2173
- class Nr {
2410
+ const Xo = (t) => ne ? window.requestAnimationFrame(t) : setTimeout(t, 16), Go = (t) => ne ? window.cancelAnimationFrame(t) : clearTimeout(t);
2411
+ class Yr {
2174
2412
  constructor(e = {}) {
2175
- C(this, "options", {
2413
+ L(this, "options", {
2176
2414
  type: "cache",
2177
2415
  expired: 0,
2178
2416
  prefix: "__VTJ_"
2179
2417
  });
2180
- C(this, "caches", {});
2181
- C(this, "types");
2418
+ L(this, "caches", {});
2419
+ L(this, "types");
2182
2420
  this.types = {
2183
- local: V ? window.localStorage : this.caches,
2184
- session: V ? window.sessionStorage : this.caches,
2421
+ local: ne ? window.localStorage : this.caches,
2422
+ session: ne ? window.sessionStorage : this.caches,
2185
2423
  cache: this.caches
2186
2424
  }, this.config(e);
2187
2425
  }
@@ -2189,194 +2427,194 @@ class Nr {
2189
2427
  this.options = Object.assign(this.options, e);
2190
2428
  }
2191
2429
  save(e, n, r = {}) {
2192
- const { type: s, expired: o, prefix: i } = { ...this.options, ...r }, a = Date.now(), f = i + e, u = this.types[s] || this.caches, l = {
2430
+ const { type: o, expired: s, prefix: i } = { ...this.options, ...r }, a = Date.now(), l = i + e, f = this.types[o] || this.caches, u = {
2193
2431
  value: n,
2194
2432
  timestamp: a,
2195
- expired: o
2433
+ expired: s
2196
2434
  };
2197
- u === this.caches ? u[f] = l : u.setItem(f, JSON.stringify(l));
2435
+ f === this.caches ? f[l] = u : f.setItem(l, JSON.stringify(u));
2198
2436
  }
2199
2437
  get(e, n = {}) {
2200
- const { type: r, prefix: s } = { ...this.options, ...n }, o = s + e, i = this.types[r] || this.caches;
2438
+ const { type: r, prefix: o } = { ...this.options, ...n }, s = o + e, i = this.types[r] || this.caches;
2201
2439
  let a;
2202
2440
  if (i === this.caches)
2203
- a = i[o];
2441
+ a = i[s];
2204
2442
  else {
2205
- const y = i.getItem(o);
2206
- if (y)
2443
+ const g = i.getItem(s);
2444
+ if (g)
2207
2445
  try {
2208
- a = JSON.parse(y);
2209
- } catch (R) {
2210
- console.warn("[Storage] JSON.parse", R);
2446
+ a = JSON.parse(g);
2447
+ } catch (w) {
2448
+ console.warn("[Storage] JSON.parse", w);
2211
2449
  }
2212
2450
  }
2213
2451
  if (!a) return null;
2214
- const { value: f, timestamp: u, expired: l } = a;
2215
- return l > 0 && u + l < Date.now() ? (this.remove(e, n), null) : f;
2452
+ const { value: l, timestamp: f, expired: u } = a;
2453
+ return u > 0 && f + u < Date.now() ? (this.remove(e, n), null) : l;
2216
2454
  }
2217
2455
  remove(e, n = {}) {
2218
- const { type: r, prefix: s } = { ...this.options, ...n }, o = this.types[r] || this.caches, i = s + e;
2219
- o === this.caches ? delete o[i] : o.removeItem(i);
2456
+ const { type: r, prefix: o } = { ...this.options, ...n }, s = this.types[r] || this.caches, i = o + e;
2457
+ s === this.caches ? delete s[i] : s.removeItem(i);
2220
2458
  }
2221
2459
  clear(e = {}) {
2222
2460
  const { type: n } = { ...this.options, ...e }, r = this.types[n] || this.caches;
2223
2461
  r === this.caches ? this.caches = {} : r.clear();
2224
2462
  }
2225
2463
  }
2226
- const Cs = new Nr();
2227
- function Nt(t) {
2464
+ const Qo = new Yr();
2465
+ function qt(t) {
2228
2466
  return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
2229
2467
  }
2230
- var z = { exports: {} }, Ur = z.exports, ot;
2231
- function Fr() {
2232
- return ot || (ot = 1, (function(t, e) {
2468
+ var te = { exports: {} }, Zr = te.exports, ht;
2469
+ function eo() {
2470
+ return ht || (ht = 1, (function(t, e) {
2233
2471
  (function(n, r) {
2234
2472
  r(e, t);
2235
- })(Ur, function(n, r) {
2236
- var s = {
2473
+ })(Zr, function(n, r) {
2474
+ var o = {
2237
2475
  timeout: 5e3,
2238
2476
  jsonpCallback: "callback"
2239
2477
  };
2240
- function o() {
2478
+ function s() {
2241
2479
  return "jsonp_" + Date.now() + "_" + Math.ceil(Math.random() * 1e5);
2242
2480
  }
2243
- function i(u) {
2481
+ function i(f) {
2244
2482
  try {
2245
- delete window[u];
2483
+ delete window[f];
2246
2484
  } catch {
2247
- window[u] = void 0;
2485
+ window[f] = void 0;
2248
2486
  }
2249
2487
  }
2250
- function a(u) {
2251
- var l = document.getElementById(u);
2252
- l && document.getElementsByTagName("head")[0].removeChild(l);
2488
+ function a(f) {
2489
+ var u = document.getElementById(f);
2490
+ u && document.getElementsByTagName("head")[0].removeChild(u);
2253
2491
  }
2254
- function f(u) {
2255
- var l = arguments.length <= 1 || arguments[1] === void 0 ? {} : arguments[1], h = u, y = l.timeout || s.timeout, R = l.jsonpCallback || s.jsonpCallback, d = void 0;
2256
- return new Promise(function(m, p) {
2257
- var w = l.jsonpCallbackFunction || o(), S = R + "_" + w;
2258
- window[w] = function(O) {
2259
- m({
2492
+ function l(f) {
2493
+ var u = arguments.length <= 1 || arguments[1] === void 0 ? {} : arguments[1], p = f, g = u.timeout || o.timeout, w = u.jsonpCallback || o.jsonpCallback, b = void 0;
2494
+ return new Promise(function(h, d) {
2495
+ var m = u.jsonpCallbackFunction || s(), O = w + "_" + m;
2496
+ window[m] = function(R) {
2497
+ h({
2260
2498
  ok: !0,
2261
2499
  // keep consistent with fetch API
2262
2500
  json: function() {
2263
- return Promise.resolve(O);
2501
+ return Promise.resolve(R);
2264
2502
  }
2265
- }), d && clearTimeout(d), a(S), i(w);
2266
- }, h += h.indexOf("?") === -1 ? "?" : "&";
2267
- var b = document.createElement("script");
2268
- b.setAttribute("src", "" + h + R + "=" + w), l.charset && b.setAttribute("charset", l.charset), l.nonce && b.setAttribute("nonce", l.nonce), l.referrerPolicy && b.setAttribute("referrerPolicy", l.referrerPolicy), l.crossorigin && b.setAttribute("crossorigin", "true"), b.id = S, document.getElementsByTagName("head")[0].appendChild(b), d = setTimeout(function() {
2269
- p(new Error("JSONP request to " + u + " timed out")), i(w), a(S), window[w] = function() {
2270
- i(w);
2503
+ }), b && clearTimeout(b), a(O), i(m);
2504
+ }, p += p.indexOf("?") === -1 ? "?" : "&";
2505
+ var E = document.createElement("script");
2506
+ E.setAttribute("src", "" + p + w + "=" + m), u.charset && E.setAttribute("charset", u.charset), u.nonce && E.setAttribute("nonce", u.nonce), u.referrerPolicy && E.setAttribute("referrerPolicy", u.referrerPolicy), u.crossorigin && E.setAttribute("crossorigin", "true"), E.id = O, document.getElementsByTagName("head")[0].appendChild(E), b = setTimeout(function() {
2507
+ d(new Error("JSONP request to " + f + " timed out")), i(m), a(O), window[m] = function() {
2508
+ i(m);
2271
2509
  };
2272
- }, y), b.onerror = function() {
2273
- p(new Error("JSONP request to " + u + " failed")), i(w), a(S), d && clearTimeout(d);
2510
+ }, g), E.onerror = function() {
2511
+ d(new Error("JSONP request to " + f + " failed")), i(m), a(O), b && clearTimeout(b);
2274
2512
  };
2275
2513
  });
2276
2514
  }
2277
- r.exports = f;
2515
+ r.exports = l;
2278
2516
  });
2279
- })(z, z.exports)), z.exports;
2517
+ })(te, te.exports)), te.exports;
2280
2518
  }
2281
- var jr = Fr();
2282
- const kr = /* @__PURE__ */ Nt(jr);
2283
- function Dr(t) {
2284
- if (V) {
2519
+ var to = eo();
2520
+ const no = /* @__PURE__ */ qt(to);
2521
+ function ro(t) {
2522
+ if (ne) {
2285
2523
  const { protocol: e, host: n, pathname: r } = location;
2286
2524
  return `${e}//${n}${t ? r : ""}`;
2287
2525
  } else
2288
2526
  return null;
2289
2527
  }
2290
- function Br(t = "") {
2291
- const e = t.match(Ht);
2528
+ function oo(t = "") {
2529
+ const e = t.match(Yt);
2292
2530
  return e ? e[0] : "";
2293
2531
  }
2294
- function Ut(t) {
2532
+ function Mt(t) {
2295
2533
  const e = [];
2296
2534
  for (const n in t)
2297
2535
  Object.prototype.hasOwnProperty.call(t, n) && e.push([n, encodeURIComponent(t[n])].join("="));
2298
2536
  return e.join("&");
2299
2537
  }
2300
- function xe(t, e, n) {
2538
+ function ve(t, e, n) {
2301
2539
  const r = {};
2302
2540
  t = (t || location.search).replace(/^[^]*\?/, ""), e = e || "&", n = n || "=";
2303
- let s;
2304
- const o = new RegExp(
2541
+ let o;
2542
+ const s = new RegExp(
2305
2543
  "(?:^|\\" + e + ")([^\\" + n + "\\" + e + "]+)(?:\\" + n + "([^\\" + e + "]*))?",
2306
2544
  "g"
2307
2545
  );
2308
- for (; (s = o.exec(t)) !== null; )
2309
- s[1] !== t && (r[decodeURIComponent(s[1])] = decodeURIComponent(s[2] || ""));
2546
+ for (; (o = s.exec(t)) !== null; )
2547
+ o[1] !== t && (r[decodeURIComponent(o[1])] = decodeURIComponent(o[2] || ""));
2310
2548
  return r;
2311
2549
  }
2312
- function Ft(t, e) {
2313
- e = typeof e == "string" ? xe(e) : e;
2314
- const n = t.split("?")[0], r = xe(t), s = Object.assign({}, r, e), o = Ut(s);
2315
- return o ? [n, o].join("?") : t;
2550
+ function Ht(t, e) {
2551
+ e = typeof e == "string" ? ve(e) : e;
2552
+ const n = t.split("?")[0], r = ve(t), o = Object.assign({}, r, e), s = Mt(o);
2553
+ return s ? [n, s].join("?") : t;
2316
2554
  }
2317
- const Ps = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2555
+ const Yo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2318
2556
  __proto__: null,
2319
- append: Ft,
2320
- getCurrentHost: Dr,
2321
- getHost: Br,
2322
- parse: xe,
2323
- stringify: Ut
2557
+ append: Ht,
2558
+ getCurrentHost: ro,
2559
+ getHost: oo,
2560
+ parse: ve,
2561
+ stringify: Mt
2324
2562
  }, Symbol.toStringTag, { value: "Module" }));
2325
- async function Ls(t, e = {}) {
2563
+ async function Zo(t, e = {}) {
2326
2564
  const { query: n = {} } = e;
2327
- t.includes("${") && (t = $t(t)(n || {}));
2328
- const r = Ft(t, n);
2329
- return await (await kr(r, e)).json();
2330
- }
2331
- var Ee, it;
2332
- function vr() {
2333
- if (it) return Ee;
2334
- it = 1, Ee = function(s, o, i) {
2335
- var a = document.head || document.getElementsByTagName("head")[0], f = document.createElement("script");
2336
- typeof o == "function" && (i = o, o = {}), o = o || {}, i = i || function() {
2337
- }, f.type = o.type || "text/javascript", f.charset = o.charset || "utf8", f.async = "async" in o ? !!o.async : !0, f.src = s, o.attrs && t(f, o.attrs), o.text && (f.text = "" + o.text);
2338
- var u = "onload" in f ? e : n;
2339
- u(f, i), f.onload || e(f, i), a.appendChild(f);
2565
+ t.includes("${") && (t = Zt(t)(n || {}));
2566
+ const r = Ht(t, n);
2567
+ return await (await no(r, e)).json();
2568
+ }
2569
+ var De, mt;
2570
+ function so() {
2571
+ if (mt) return De;
2572
+ mt = 1, De = function(o, s, i) {
2573
+ var a = document.head || document.getElementsByTagName("head")[0], l = document.createElement("script");
2574
+ typeof s == "function" && (i = s, s = {}), s = s || {}, i = i || function() {
2575
+ }, l.type = s.type || "text/javascript", l.charset = s.charset || "utf8", l.async = "async" in s ? !!s.async : !0, l.src = o, s.attrs && t(l, s.attrs), s.text && (l.text = "" + s.text);
2576
+ var f = "onload" in l ? e : n;
2577
+ f(l, i), l.onload || e(l, i), a.appendChild(l);
2340
2578
  };
2341
- function t(r, s) {
2342
- for (var o in s)
2343
- r.setAttribute(o, s[o]);
2579
+ function t(r, o) {
2580
+ for (var s in o)
2581
+ r.setAttribute(s, o[s]);
2344
2582
  }
2345
- function e(r, s) {
2583
+ function e(r, o) {
2346
2584
  r.onload = function() {
2347
- this.onerror = this.onload = null, s(null, r);
2585
+ this.onerror = this.onload = null, o(null, r);
2348
2586
  }, r.onerror = function() {
2349
- this.onerror = this.onload = null, s(new Error("Failed to load " + this.src), r);
2587
+ this.onerror = this.onload = null, o(new Error("Failed to load " + this.src), r);
2350
2588
  };
2351
2589
  }
2352
- function n(r, s) {
2590
+ function n(r, o) {
2353
2591
  r.onreadystatechange = function() {
2354
- this.readyState != "complete" && this.readyState != "loaded" || (this.onreadystatechange = null, s(null, r));
2592
+ this.readyState != "complete" && this.readyState != "loaded" || (this.onreadystatechange = null, o(null, r));
2355
2593
  };
2356
2594
  }
2357
- return Ee;
2595
+ return De;
2358
2596
  }
2359
- var Ir = vr();
2360
- const qr = /* @__PURE__ */ Nt(Ir);
2361
- function Ns(t, e = {}) {
2597
+ var io = so();
2598
+ const ao = /* @__PURE__ */ qt(io);
2599
+ function es(t, e = {}) {
2362
2600
  return new Promise((n, r) => {
2363
- const { library: s } = e;
2364
- qr(t, e, (o, i) => {
2365
- o ? r(o) : n(s ? window[s] : void 0);
2601
+ const { library: o } = e;
2602
+ ao(t, e, (s, i) => {
2603
+ s ? r(s) : n(o ? window[o] : void 0);
2366
2604
  });
2367
2605
  });
2368
2606
  }
2369
- const at = { debug: -1, log: 0, info: 0, warn: 1, error: 2 }, Mr = function(t, e, n, r) {
2370
- return function(...s) {
2371
- if (e && at[e] <= at[t] && // @ts-ignore
2607
+ const yt = { debug: -1, log: 0, info: 0, warn: 1, error: 2 }, co = function(t, e, n, r) {
2608
+ return function(...o) {
2609
+ if (e && yt[e] <= yt[t] && // @ts-ignore
2372
2610
  console[t].apply && (r === "*" || n.startsWith(r)))
2373
- return console[t].apply(console, Hr(s, n));
2611
+ return console[t].apply(console, lo(o, n));
2374
2612
  };
2375
2613
  };
2376
- function Hr(t, e) {
2614
+ function lo(t, e) {
2377
2615
  return e !== "*" && (typeof t[0] == "string" ? t[0] = `[${e}] ${t[0]}` : t = ["[" + e + "]"].concat(t)), t;
2378
2616
  }
2379
- function $r(t, e) {
2617
+ function uo(t, e) {
2380
2618
  if (!t)
2381
2619
  return {
2382
2620
  targetLevel: e.level,
@@ -2394,23 +2632,23 @@ function $r(t, e) {
2394
2632
  targetBizName: "*"
2395
2633
  };
2396
2634
  }
2397
- const Jr = {
2635
+ const fo = {
2398
2636
  level: "warn",
2399
2637
  bizName: "*"
2400
2638
  };
2401
- class Wr {
2639
+ class po {
2402
2640
  constructor(e) {
2403
- C(this, "config");
2404
- C(this, "options");
2405
- this.options = { ...Jr, ...e };
2641
+ L(this, "config");
2642
+ L(this, "options");
2643
+ this.options = { ...fo, ...e };
2406
2644
  const n = typeof location < "u" ? location : {}, r = (/__(?:logConf|logLevel)__=([^#/&]*)/.exec(
2407
2645
  n.href
2408
2646
  ) || [])[1];
2409
- this.config = $r(r, e);
2647
+ this.config = uo(r, e);
2410
2648
  }
2411
2649
  _log(e) {
2412
- const { targetLevel: n, targetBizName: r } = this.config, { bizName: s } = this.options;
2413
- return Mr(e, n, s, r);
2650
+ const { targetLevel: n, targetBizName: r } = this.config, { bizName: o } = this.options;
2651
+ return co(e, n, o, r);
2414
2652
  }
2415
2653
  debug(...e) {
2416
2654
  return this._log("debug")(...e);
@@ -2428,12 +2666,12 @@ class Wr {
2428
2666
  return this._log("error")(...e);
2429
2667
  }
2430
2668
  }
2431
- function zr(t) {
2432
- return new Wr(t);
2669
+ function ho(t) {
2670
+ return new po(t);
2433
2671
  }
2434
- const Us = zr({ level: "log", bizName: "VTJ" });
2672
+ const ts = ho({ level: "log", bizName: "VTJ" });
2435
2673
  /*! js-cookie v3.0.8 | MIT */
2436
- function re(t) {
2674
+ function de(t) {
2437
2675
  for (var e = 1; e < arguments.length; e++) {
2438
2676
  var n = arguments[e];
2439
2677
  for (var r in n)
@@ -2441,7 +2679,7 @@ function re(t) {
2441
2679
  }
2442
2680
  return t;
2443
2681
  }
2444
- var Vr = {
2682
+ var mo = {
2445
2683
  read: function(t) {
2446
2684
  return t[0] === '"' && (t = t.slice(1, -1)), t.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
2447
2685
  },
@@ -2452,48 +2690,48 @@ var Vr = {
2452
2690
  );
2453
2691
  }
2454
2692
  };
2455
- function _e(t, e) {
2456
- function n(s, o, i) {
2693
+ function Ie(t, e) {
2694
+ function n(o, s, i) {
2457
2695
  if (!(typeof document > "u")) {
2458
- i = re({}, e, i), typeof i.expires == "number" && (i.expires = new Date(Date.now() + i.expires * 864e5)), i.expires && (i.expires = i.expires.toUTCString()), s = encodeURIComponent(s).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
2696
+ i = de({}, e, i), typeof i.expires == "number" && (i.expires = new Date(Date.now() + i.expires * 864e5)), i.expires && (i.expires = i.expires.toUTCString()), o = encodeURIComponent(o).replace(/%(2[346B]|5E|60|7C)/g, decodeURIComponent).replace(/[()]/g, escape);
2459
2697
  var a = "";
2460
- for (var f in i)
2461
- i[f] && (a += "; " + f, i[f] !== !0 && (a += "=" + i[f].split(";")[0]));
2462
- return document.cookie = s + "=" + t.write(o, s) + a;
2698
+ for (var l in i)
2699
+ i[l] && (a += "; " + l, i[l] !== !0 && (a += "=" + i[l].split(";")[0]));
2700
+ return document.cookie = o + "=" + t.write(s, o) + a;
2463
2701
  }
2464
2702
  }
2465
- function r(s) {
2466
- if (!(typeof document > "u" || arguments.length && !s)) {
2467
- for (var o = document.cookie ? document.cookie.split("; ") : [], i = {}, a = 0; a < o.length; a++) {
2468
- var f = o[a].split("="), u = f.slice(1).join("=");
2703
+ function r(o) {
2704
+ if (!(typeof document > "u" || arguments.length && !o)) {
2705
+ for (var s = document.cookie ? document.cookie.split("; ") : [], i = {}, a = 0; a < s.length; a++) {
2706
+ var l = s[a].split("="), f = l.slice(1).join("=");
2469
2707
  try {
2470
- var l = decodeURIComponent(f[0]);
2471
- if (l in i || (i[l] = t.read(u, l)), s === l)
2708
+ var u = decodeURIComponent(l[0]);
2709
+ if (u in i || (i[u] = t.read(f, u)), o === u)
2472
2710
  break;
2473
2711
  } catch {
2474
2712
  }
2475
2713
  }
2476
- return s ? i[s] : i;
2714
+ return o ? i[o] : i;
2477
2715
  }
2478
2716
  }
2479
2717
  return Object.create(
2480
2718
  {
2481
2719
  set: n,
2482
2720
  get: r,
2483
- remove: function(s, o) {
2721
+ remove: function(o, s) {
2484
2722
  n(
2485
- s,
2723
+ o,
2486
2724
  "",
2487
- re({}, o, {
2725
+ de({}, s, {
2488
2726
  expires: -1
2489
2727
  })
2490
2728
  );
2491
2729
  },
2492
- withAttributes: function(s) {
2493
- return _e(this.converter, re({}, this.attributes, s));
2730
+ withAttributes: function(o) {
2731
+ return Ie(this.converter, de({}, this.attributes, o));
2494
2732
  },
2495
- withConverter: function(s) {
2496
- return _e(re({}, this.converter, s), this.attributes);
2733
+ withConverter: function(o) {
2734
+ return Ie(de({}, this.converter, o), this.attributes);
2497
2735
  }
2498
2736
  },
2499
2737
  {
@@ -2502,43 +2740,43 @@ function _e(t, e) {
2502
2740
  }
2503
2741
  );
2504
2742
  }
2505
- var Fe = _e(Vr, { path: "/" });
2506
- function Kr(t, e, n) {
2507
- Fe.set(t, e, n);
2743
+ var We = Ie(mo, { path: "/" });
2744
+ function yo(t, e, n) {
2745
+ We.set(t, e, n);
2508
2746
  }
2509
- function Xr(t) {
2510
- return Fe.get(t);
2747
+ function go(t) {
2748
+ return We.get(t);
2511
2749
  }
2512
- function Gr(t, e) {
2513
- Fe.remove(t, e);
2750
+ function wo(t, e) {
2751
+ We.remove(t, e);
2514
2752
  }
2515
- const Fs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2753
+ const ns = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2516
2754
  __proto__: null,
2517
- get: Xr,
2518
- remove: Gr,
2519
- set: Kr
2755
+ get: go,
2756
+ remove: wo,
2757
+ set: yo
2520
2758
  }, Symbol.toStringTag, { value: "Module" }));
2521
- function js(t, e = "") {
2759
+ function rs(t, e = "") {
2522
2760
  const n = document.createElement("a");
2523
2761
  n.download = e, n.href = t, n.target = "_blank", n.click();
2524
2762
  }
2525
- function jt(t, e = "", n) {
2526
- const r = new Blob([t], { type: n }), s = document.createElement("a");
2527
- s.download = e, s.style.display = "none", s.href = URL.createObjectURL(r), s.click(), URL.revokeObjectURL(s.href);
2763
+ function $t(t, e = "", n) {
2764
+ const r = new Blob([t], { type: n }), o = document.createElement("a");
2765
+ o.download = e, o.style.display = "none", o.href = URL.createObjectURL(r), o.click(), URL.revokeObjectURL(o.href);
2528
2766
  }
2529
- async function ks(t, e = "", n) {
2767
+ async function os(t, e = "", n) {
2530
2768
  return fetch(t, { credentials: "include" }).then(async (r) => {
2531
- const s = await r.blob();
2532
- return jt(s, e, n), s;
2769
+ const o = await r.blob();
2770
+ return $t(o, e, n), o;
2533
2771
  });
2534
2772
  }
2535
- function Ds(t, e = "") {
2773
+ function ss(t, e = "") {
2536
2774
  const n = JSON.stringify(t);
2537
- jt(n, e, "application/json");
2775
+ $t(n, e, "application/json");
2538
2776
  }
2539
- function Bs() {
2777
+ function is() {
2540
2778
  const t = navigator.userAgent;
2541
- let e = "Unknown", n = "Unknown", r = "Unknown", s = "Unknown", o = !1;
2779
+ let e = "Unknown", n = "Unknown", r = "Unknown", o = "Unknown", s = !1;
2542
2780
  if (/Windows NT/i.test(t)) {
2543
2781
  e = "Windows";
2544
2782
  const a = {
@@ -2551,8 +2789,8 @@ function Bs() {
2551
2789
  "6.0": "Vista",
2552
2790
  "5.2": "XP 64-bit",
2553
2791
  "5.1": "XP"
2554
- }, f = t.match(/Windows NT (\d+\.\d+)/);
2555
- f && (n = a[f[1]] || f[1]);
2792
+ }, l = t.match(/Windows NT (\d+\.\d+)/);
2793
+ l && (n = a[l[1]] || l[1]);
2556
2794
  } else if (/Mac OS X/i.test(t)) {
2557
2795
  e = "Mac OS";
2558
2796
  const a = t.match(/Mac OS X (\d+[._]\d+[._]?\d*)/);
@@ -2568,70 +2806,70 @@ function Bs() {
2568
2806
  } else /Linux/i.test(t) && (e = "Linux");
2569
2807
  const i = t.match(/(Edge|Edg|Edga|EdgA)\/(\d+)/i);
2570
2808
  if (i)
2571
- r = "Microsoft Edge", s = i[2];
2809
+ r = "Microsoft Edge", o = i[2];
2572
2810
  else {
2573
2811
  const a = t.match(/Firefox\/(\d+)/i);
2574
2812
  if (a)
2575
- r = "Firefox", s = a[1];
2813
+ r = "Firefox", o = a[1];
2576
2814
  else {
2577
- const f = t.match(/(Opera|OPR)\/(\d+)/i);
2578
- if (f)
2579
- r = "Opera", s = f[2];
2815
+ const l = t.match(/(Opera|OPR)\/(\d+)/i);
2816
+ if (l)
2817
+ r = "Opera", o = l[2];
2580
2818
  else {
2581
- const u = t.match(/Chrome\/(\d+)/i);
2582
- if (u)
2583
- r = "Chrome", s = u[1];
2819
+ const f = t.match(/Chrome\/(\d+)/i);
2820
+ if (f)
2821
+ r = "Chrome", o = f[1];
2584
2822
  else {
2585
- const l = t.match(/Version\/(\d+\.\d+)/i);
2586
- if (l && /Safari/i.test(t))
2587
- r = "Safari", s = l[1];
2823
+ const u = t.match(/Version\/(\d+\.\d+)/i);
2824
+ if (u && /Safari/i.test(t))
2825
+ r = "Safari", o = u[1];
2588
2826
  else {
2589
- const h = t.match(/(MSIE |Trident.*rv:)(\d+)/i);
2590
- h && (r = "Internet Explorer", s = h[2]);
2827
+ const p = t.match(/(MSIE |Trident.*rv:)(\d+)/i);
2828
+ p && (r = "Internet Explorer", o = p[2]);
2591
2829
  }
2592
2830
  }
2593
2831
  }
2594
2832
  }
2595
2833
  }
2596
- return o = // 移动设备通用检测
2834
+ return s = // 移动设备通用检测
2597
2835
  /(iPhone|iPod|iPad|Android|Windows Phone|Mobile)/i.test(t) || // 根据已识别的操作系统补充判断
2598
- ["iOS", "Android"].includes(e), /(iPad|Tablet|Android(?!.*Mobile))/i.test(t) && (o = !0), {
2836
+ ["iOS", "Android"].includes(e), /(iPad|Tablet|Android(?!.*Mobile))/i.test(t) && (s = !0), {
2599
2837
  os: e,
2600
2838
  osVersion: n,
2601
2839
  browser: r,
2602
- browserVersion: s,
2603
- isMobile: o
2840
+ browserVersion: o,
2841
+ isMobile: s
2604
2842
  };
2605
2843
  }
2606
2844
  export {
2607
- st as LOCAL_REQUEST_ID,
2608
- Wr as Logger,
2609
- Cr as Request,
2610
- Nr as Storage,
2611
- es as VTJ_UTILS_VERSION,
2612
- E as axios,
2613
- As as blobToFile,
2614
- _s as cAF,
2615
- Fs as cookie,
2616
- Lr as createApi,
2617
- Rs as createApis,
2618
- Pr as createRequest,
2619
- Ts as dataURLtoBlob,
2620
- jt as downloadBlob,
2621
- Ds as downloadJson,
2622
- ks as downloadRemoteFile,
2623
- js as downloadUrl,
2624
- Ss as fileToBase64,
2625
- Os as formDataToJson,
2626
- Bs as getClientInfo,
2627
- zr as getLogger,
2628
- V as isClient,
2629
- Ls as jsonp,
2630
- Ns as loadScript,
2631
- Us as logger,
2632
- xs as rAF,
2633
- Lt as request,
2634
- Cs as storage,
2635
- Ps as url,
2636
- Es as useApi
2845
+ pt as LOCAL_REQUEST_ID,
2846
+ po as Logger,
2847
+ Xr as Request,
2848
+ Yr as Storage,
2849
+ Oo as VTJ_UTILS_VERSION,
2850
+ _ as axios,
2851
+ Ko as blobToFile,
2852
+ Go as cAF,
2853
+ ns as cookie,
2854
+ Qr as createApi,
2855
+ $o as createApis,
2856
+ Gr as createRequest,
2857
+ Vo as dataURLtoBlob,
2858
+ $t as downloadBlob,
2859
+ ss as downloadJson,
2860
+ os as downloadRemoteFile,
2861
+ rs as downloadUrl,
2862
+ Jo as fileToBase64,
2863
+ Wo as formDataToJson,
2864
+ is as getClientInfo,
2865
+ ho as getLogger,
2866
+ ne as isClient,
2867
+ Zo as jsonp,
2868
+ es as loadScript,
2869
+ ts as logger,
2870
+ Xo as rAF,
2871
+ It as request,
2872
+ Qo as storage,
2873
+ Yo as url,
2874
+ zo as useApi
2637
2875
  };