@vtj/utils 0.17.4 → 0.17.6
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.cjs +11 -8
- package/dist/index.iife.js +5 -5
- package/dist/index.mjs +1603 -1365
- package/dist/index.umd.js +5 -5
- package/package.json +3 -3
- package/types/request.d.ts +2 -2
- package/types/version.d.ts +2 -2
package/dist/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { omit as
|
|
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
|
|
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.
|
|
19
|
+
* @version 0.17.6
|
|
20
20
|
* @license <a href="https://vtj.pro/license.html">MIT License</a>
|
|
21
21
|
*/
|
|
22
|
-
const
|
|
23
|
-
function
|
|
22
|
+
const Oo = "0.17.6";
|
|
23
|
+
function gt(t, e) {
|
|
24
24
|
return function() {
|
|
25
25
|
return t.apply(e, arguments);
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
|
-
const { toString:
|
|
29
|
-
const n =
|
|
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) =>
|
|
32
|
-
function
|
|
33
|
-
return t !== null && !
|
|
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
|
|
36
|
-
function
|
|
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 &&
|
|
38
|
+
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? e = ArrayBuffer.isView(t) : e = t && t.buffer && bt(t.buffer), e;
|
|
39
39
|
}
|
|
40
|
-
const
|
|
41
|
-
if (
|
|
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 =
|
|
44
|
-
return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(
|
|
45
|
-
},
|
|
46
|
-
if (!
|
|
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
|
-
},
|
|
54
|
-
function
|
|
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
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
e
|
|
61
|
-
|
|
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),
|
|
67
|
-
function
|
|
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,
|
|
71
|
-
if (typeof t != "object" && (t = [t]),
|
|
72
|
-
for (r = 0,
|
|
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 (
|
|
79
|
+
if (re(t))
|
|
76
80
|
return;
|
|
77
|
-
const
|
|
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 =
|
|
84
|
+
a = s[r], e.call(null, t[a], a, t);
|
|
81
85
|
}
|
|
82
86
|
}
|
|
83
|
-
function
|
|
84
|
-
if (
|
|
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,
|
|
92
|
+
let r = n.length, o;
|
|
89
93
|
for (; r-- > 0; )
|
|
90
|
-
if (
|
|
91
|
-
return
|
|
94
|
+
if (o = n[r], e === o.toLowerCase())
|
|
95
|
+
return o;
|
|
92
96
|
return null;
|
|
93
97
|
}
|
|
94
|
-
const
|
|
95
|
-
function
|
|
96
|
-
const { caseless:
|
|
97
|
-
if (
|
|
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
|
|
100
|
-
|
|
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,
|
|
103
|
-
|
|
104
|
-
return
|
|
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
|
|
110
|
+
const Rn = (t, e, n, { allOwnKeys: r } = {}) => (se(
|
|
107
111
|
e,
|
|
108
|
-
(
|
|
109
|
-
n &&
|
|
110
|
-
|
|
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,
|
|
115
|
-
|
|
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),
|
|
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
|
-
},
|
|
132
|
-
let
|
|
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 (
|
|
137
|
-
i = s
|
|
138
|
-
t = n !== !1 &&
|
|
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
|
-
},
|
|
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
|
-
},
|
|
155
|
+
}, Tn = (t) => {
|
|
146
156
|
if (!t) return null;
|
|
147
|
-
if (
|
|
157
|
+
if (X(t)) return t;
|
|
148
158
|
let e = t.length;
|
|
149
|
-
if (!
|
|
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
|
-
},
|
|
155
|
-
const r = (t && t[
|
|
156
|
-
let
|
|
157
|
-
for (; (
|
|
158
|
-
const
|
|
159
|
-
e.call(t,
|
|
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
|
-
},
|
|
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
|
-
},
|
|
168
|
-
return r.toUpperCase() +
|
|
169
|
-
}),
|
|
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
|
-
|
|
181
|
+
se(n, (o, s) => {
|
|
172
182
|
let i;
|
|
173
|
-
(i = e(
|
|
183
|
+
(i = e(o, s, t)) !== !1 && (r[s] = i || o);
|
|
174
184
|
}), Object.defineProperties(t, r);
|
|
175
|
-
},
|
|
176
|
-
|
|
177
|
-
if (
|
|
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 (
|
|
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
|
-
},
|
|
191
|
-
const n = {}, r = (
|
|
192
|
-
|
|
193
|
-
n[
|
|
200
|
+
}, Fn = (t, e) => {
|
|
201
|
+
const n = {}, r = (o) => {
|
|
202
|
+
o.forEach((s) => {
|
|
203
|
+
n[s] = !0;
|
|
194
204
|
});
|
|
195
205
|
};
|
|
196
|
-
return
|
|
197
|
-
},
|
|
198
|
-
},
|
|
199
|
-
function
|
|
200
|
-
return !!(t &&
|
|
201
|
-
}
|
|
202
|
-
const
|
|
203
|
-
const e = new
|
|
204
|
-
if (
|
|
205
|
-
if (e.
|
|
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 (
|
|
217
|
+
if (re(r))
|
|
208
218
|
return r;
|
|
209
219
|
if (!("toJSON" in r)) {
|
|
210
|
-
e
|
|
211
|
-
const o =
|
|
212
|
-
return
|
|
213
|
-
const
|
|
214
|
-
!
|
|
215
|
-
}), e
|
|
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
|
|
221
|
-
},
|
|
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:
|
|
224
|
-
|
|
233
|
+
({ source: o, data: s }) => {
|
|
234
|
+
o === $ && s === n && r.length && r.shift()();
|
|
225
235
|
},
|
|
226
236
|
!1
|
|
227
|
-
), (
|
|
228
|
-
r.push(
|
|
229
|
-
}))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(typeof setImmediate == "function",
|
|
230
|
-
isArray:
|
|
231
|
-
isArrayBuffer:
|
|
232
|
-
isBuffer:
|
|
233
|
-
isFormData:
|
|
234
|
-
isArrayBufferView:
|
|
235
|
-
isString:
|
|
236
|
-
isNumber:
|
|
237
|
-
isBoolean:
|
|
238
|
-
isObject:
|
|
239
|
-
isPlainObject:
|
|
240
|
-
isEmptyObject:
|
|
241
|
-
isReadableStream:
|
|
242
|
-
isRequest:
|
|
243
|
-
isResponse:
|
|
244
|
-
isHeaders:
|
|
245
|
-
isUndefined:
|
|
246
|
-
isDate:
|
|
247
|
-
isFile:
|
|
248
|
-
isReactNativeBlob:
|
|
249
|
-
isReactNative:
|
|
250
|
-
isBlob:
|
|
251
|
-
isRegExp:
|
|
252
|
-
isFunction:
|
|
253
|
-
isStream:
|
|
254
|
-
isURLSearchParams:
|
|
255
|
-
isTypedArray:
|
|
256
|
-
isFileList:
|
|
257
|
-
forEach:
|
|
258
|
-
merge:
|
|
259
|
-
extend:
|
|
260
|
-
trim:
|
|
261
|
-
stripBOM:
|
|
262
|
-
inherits:
|
|
263
|
-
toFlatObject:
|
|
264
|
-
kindOf:
|
|
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:
|
|
267
|
-
toArray:
|
|
268
|
-
forEachEntry:
|
|
269
|
-
matchAll:
|
|
270
|
-
isHTMLForm:
|
|
271
|
-
hasOwnProperty:
|
|
272
|
-
hasOwnProp:
|
|
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:
|
|
275
|
-
freezeMethods:
|
|
276
|
-
toObjectSet:
|
|
277
|
-
toCamelCase:
|
|
278
|
-
noop:
|
|
279
|
-
toFiniteNumber:
|
|
280
|
-
findKey:
|
|
281
|
-
global:
|
|
282
|
-
isContextDefined:
|
|
283
|
-
isSpecCompliantForm:
|
|
284
|
-
toJSONObject:
|
|
285
|
-
isAsyncFn:
|
|
286
|
-
isThenable:
|
|
287
|
-
setImmediate:
|
|
288
|
-
asap:
|
|
289
|
-
isIterable:
|
|
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
|
-
|
|
292
|
-
|
|
293
|
-
|
|
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,
|
|
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),
|
|
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:
|
|
617
|
+
config: r,
|
|
330
618
|
code: this.code,
|
|
331
619
|
status: this.status
|
|
332
620
|
};
|
|
333
621
|
}
|
|
334
622
|
};
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
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
|
|
641
|
+
function xt(t) {
|
|
352
642
|
return c.endsWith(t, "[]") ? t.slice(0, -2) : t;
|
|
353
643
|
}
|
|
354
|
-
function
|
|
355
|
-
return t ? t.concat(e).map(function(
|
|
356
|
-
return
|
|
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
|
|
360
|
-
return c.isArray(t) && !t.some(
|
|
649
|
+
function or(t) {
|
|
650
|
+
return c.isArray(t) && !t.some(je);
|
|
361
651
|
}
|
|
362
|
-
const
|
|
652
|
+
const sr = c.toFlatObject(c, {}, null, function(e) {
|
|
363
653
|
return /^is[A-Z]/.test(e);
|
|
364
654
|
});
|
|
365
|
-
function
|
|
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(
|
|
377
|
-
return !c.isUndefined(
|
|
666
|
+
function(d, m) {
|
|
667
|
+
return !c.isUndefined(m[d]);
|
|
378
668
|
}
|
|
379
669
|
);
|
|
380
|
-
const r = n.metaTokens,
|
|
381
|
-
if (!c.isFunction(
|
|
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(
|
|
384
|
-
if (
|
|
385
|
-
if (c.isDate(
|
|
386
|
-
return
|
|
387
|
-
if (c.isBoolean(
|
|
388
|
-
return
|
|
389
|
-
if (!f && c.isBlob(
|
|
390
|
-
throw new
|
|
391
|
-
return c.isArrayBuffer(
|
|
392
|
-
}
|
|
393
|
-
function
|
|
394
|
-
let
|
|
395
|
-
if (c.isReactNative(e) && c.isReactNativeBlob(
|
|
396
|
-
return e.append(
|
|
397
|
-
if (
|
|
398
|
-
if (c.endsWith(
|
|
399
|
-
|
|
400
|
-
else if (c.isArray(
|
|
401
|
-
return
|
|
402
|
-
!(c.isUndefined(
|
|
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 ?
|
|
405
|
-
u(
|
|
694
|
+
i === !0 ? Pe([d], P, s) : i === null ? d : d + "[]",
|
|
695
|
+
u(R)
|
|
406
696
|
);
|
|
407
697
|
}), !1;
|
|
408
698
|
}
|
|
409
|
-
return
|
|
699
|
+
return je(h) ? !0 : (e.append(Pe(m, d, s), u(h)), !1);
|
|
410
700
|
}
|
|
411
|
-
const
|
|
412
|
-
defaultVisitor:
|
|
701
|
+
const g = [], w = Object.assign(sr, {
|
|
702
|
+
defaultVisitor: p,
|
|
413
703
|
convertValue: u,
|
|
414
|
-
isVisitable:
|
|
704
|
+
isVisitable: je
|
|
415
705
|
});
|
|
416
|
-
function
|
|
417
|
-
if (!c.isUndefined(
|
|
418
|
-
if (
|
|
419
|
-
throw
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
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
|
|
722
|
+
return b(t), e;
|
|
428
723
|
}
|
|
429
|
-
function
|
|
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
|
|
733
|
+
return encodeURIComponent(t).replace(/[!'()~]|%20/g, function(r) {
|
|
440
734
|
return e[r];
|
|
441
735
|
});
|
|
442
736
|
}
|
|
443
|
-
function
|
|
444
|
-
this._pairs = [], t &&
|
|
737
|
+
function Me(t, e) {
|
|
738
|
+
this._pairs = [], t && Re(t, this, e);
|
|
445
739
|
}
|
|
446
|
-
const
|
|
447
|
-
|
|
740
|
+
const Ct = Me.prototype;
|
|
741
|
+
Ct.append = function(e, n) {
|
|
448
742
|
this._pairs.push([e, n]);
|
|
449
743
|
};
|
|
450
|
-
|
|
744
|
+
Ct.toString = function(e) {
|
|
451
745
|
const n = e ? function(r) {
|
|
452
|
-
return e.call(this, r,
|
|
453
|
-
} :
|
|
454
|
-
return this._pairs.map(function(
|
|
455
|
-
return n(
|
|
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
|
|
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
|
|
755
|
+
function Pt(t, e, n) {
|
|
462
756
|
if (!e)
|
|
463
757
|
return t;
|
|
464
|
-
const r = n && n.encode ||
|
|
758
|
+
const r = n && n.encode || ir, o = c.isFunction(n) ? {
|
|
465
759
|
serialize: n
|
|
466
|
-
} : n,
|
|
760
|
+
} : n, s = o && o.serialize;
|
|
467
761
|
let i;
|
|
468
|
-
if (
|
|
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
|
|
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
|
|
823
|
+
const He = {
|
|
530
824
|
silentJSONParsing: !0,
|
|
531
825
|
forcedJSONParsing: !0,
|
|
532
826
|
clarifyTimeoutError: !1,
|
|
533
827
|
legacyInterceptorReqResOrdering: !0
|
|
534
|
-
},
|
|
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:
|
|
538
|
-
FormData:
|
|
539
|
-
Blob:
|
|
831
|
+
URLSearchParams: ar,
|
|
832
|
+
FormData: cr,
|
|
833
|
+
Blob: lr
|
|
540
834
|
},
|
|
541
835
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
542
|
-
},
|
|
543
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function",
|
|
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:
|
|
546
|
-
hasStandardBrowserEnv:
|
|
547
|
-
hasStandardBrowserWebWorkerEnv:
|
|
548
|
-
navigator:
|
|
549
|
-
origin:
|
|
839
|
+
hasBrowserEnv: $e,
|
|
840
|
+
hasStandardBrowserEnv: fr,
|
|
841
|
+
hasStandardBrowserWebWorkerEnv: dr,
|
|
842
|
+
navigator: ke,
|
|
843
|
+
origin: pr
|
|
550
844
|
}, Symbol.toStringTag, { value: "Module" })), T = {
|
|
551
|
-
...
|
|
552
|
-
...
|
|
845
|
+
...hr,
|
|
846
|
+
...ur
|
|
553
847
|
};
|
|
554
|
-
function
|
|
555
|
-
return
|
|
556
|
-
visitor: function(n, r,
|
|
557
|
-
return T.isNode && c.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) :
|
|
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
|
|
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
|
|
859
|
+
function gr(t) {
|
|
566
860
|
const e = {}, n = Object.keys(t);
|
|
567
861
|
let r;
|
|
568
|
-
const
|
|
569
|
-
let
|
|
570
|
-
for (r = 0; r <
|
|
571
|
-
|
|
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
|
|
575
|
-
function e(n, r,
|
|
576
|
-
let i = n[
|
|
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),
|
|
579
|
-
return i = !i && c.isArray(
|
|
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,
|
|
584
|
-
e(
|
|
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
|
-
|
|
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
|
|
600
|
-
transitional:
|
|
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() || "",
|
|
605
|
-
if (
|
|
606
|
-
return
|
|
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 (
|
|
909
|
+
if (s) {
|
|
910
|
+
const l = V(this, "formSerializer");
|
|
615
911
|
if (r.indexOf("application/x-www-form-urlencoded") > -1)
|
|
616
|
-
return
|
|
912
|
+
return mr(e, l).toString();
|
|
617
913
|
if ((a = c.isFileList(e)) || r.indexOf("multipart/form-data") > -1) {
|
|
618
|
-
const f = this
|
|
619
|
-
return
|
|
914
|
+
const f = V(this, "env"), u = f && f.FormData;
|
|
915
|
+
return Re(
|
|
620
916
|
a ? { "files[]": e } : e,
|
|
621
|
-
|
|
622
|
-
|
|
917
|
+
u && new u(),
|
|
918
|
+
l
|
|
623
919
|
);
|
|
624
920
|
}
|
|
625
921
|
}
|
|
626
|
-
return
|
|
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
|
|
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 && !
|
|
635
|
-
const
|
|
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
|
|
638
|
-
} catch (
|
|
639
|
-
if (
|
|
640
|
-
throw
|
|
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
|
-
|
|
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
|
-
|
|
880
|
-
|
|
881
|
-
|
|
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
|
-
|
|
885
|
-
}),
|
|
972
|
+
s = a.call(n, s, o.normalize(), e ? e.status : void 0);
|
|
973
|
+
}), o.normalize(), s;
|
|
886
974
|
}
|
|
887
|
-
function
|
|
975
|
+
function Nt(t) {
|
|
888
976
|
return !!(t && t.__CANCEL__);
|
|
889
977
|
}
|
|
890
|
-
let
|
|
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",
|
|
989
|
+
super(e ?? "canceled", y.ERR_CANCELED, n, r), this.name = "CanceledError", this.__CANCEL__ = !0;
|
|
902
990
|
}
|
|
903
991
|
};
|
|
904
|
-
function
|
|
992
|
+
function Dt(t, e, n) {
|
|
905
993
|
const r = n.config.validateStatus;
|
|
906
|
-
!n.status || !r || r(n.status) ? t(n) : e(
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
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
|
|
1006
|
+
function Er(t, e) {
|
|
921
1007
|
t = t || 10;
|
|
922
1008
|
const n = new Array(t), r = new Array(t);
|
|
923
|
-
let
|
|
924
|
-
return e = e !== void 0 ? e : 1e3, function(
|
|
925
|
-
const
|
|
926
|
-
i || (i =
|
|
927
|
-
let
|
|
928
|
-
for (;
|
|
929
|
-
|
|
930
|
-
if (
|
|
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
|
|
933
|
-
return
|
|
1018
|
+
const w = u && f - u;
|
|
1019
|
+
return w ? Math.round(g * 1e3 / w) : void 0;
|
|
934
1020
|
};
|
|
935
1021
|
}
|
|
936
|
-
function
|
|
937
|
-
let n = 0, r = 1e3 / e,
|
|
938
|
-
const i = (
|
|
939
|
-
n =
|
|
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 [(...
|
|
942
|
-
const
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
}, r -
|
|
946
|
-
}, () =>
|
|
947
|
-
}
|
|
948
|
-
const
|
|
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
|
|
951
|
-
return
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
const
|
|
955
|
-
|
|
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 ?
|
|
1045
|
+
progress: a ? l / a : void 0,
|
|
958
1046
|
bytes: f,
|
|
959
1047
|
rate: u || void 0,
|
|
960
|
-
estimated: u && a
|
|
961
|
-
event:
|
|
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(
|
|
1053
|
+
t(p);
|
|
966
1054
|
}, n);
|
|
967
|
-
},
|
|
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
|
-
},
|
|
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,
|
|
1068
|
+
) : () => !0, Sr = T.hasStandardBrowserEnv ? (
|
|
981
1069
|
// Standard browser envs support document.cookie
|
|
982
1070
|
{
|
|
983
|
-
write(t, e, n, r,
|
|
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(
|
|
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.
|
|
991
|
-
|
|
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
|
|
1102
|
+
function _r(t) {
|
|
1010
1103
|
return typeof t != "string" ? !1 : /^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);
|
|
1011
1104
|
}
|
|
1012
|
-
function
|
|
1105
|
+
function Ar(t, e) {
|
|
1013
1106
|
return e ? t.replace(/\/?\/$/, "") + "/" + e.replace(/^\/+/, "") : t;
|
|
1014
1107
|
}
|
|
1015
|
-
function
|
|
1016
|
-
let r = !
|
|
1017
|
-
return t && (r || n
|
|
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
|
|
1020
|
-
function
|
|
1112
|
+
const it = (t) => t instanceof x ? { ...t } : t;
|
|
1113
|
+
function J(t, e) {
|
|
1021
1114
|
e = e || {};
|
|
1022
|
-
const n =
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
}
|
|
1032
|
-
function
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
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
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
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: (
|
|
1180
|
+
headers: (f, u, p) => o(it(f), it(u), p, !0)
|
|
1078
1181
|
};
|
|
1079
|
-
return c.forEach(Object.keys({ ...t, ...e }), function(
|
|
1080
|
-
if (
|
|
1081
|
-
const
|
|
1082
|
-
c.isUndefined(
|
|
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
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
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
|
-
),
|
|
1211
|
+
), l && a.set(
|
|
1093
1212
|
"Authorization",
|
|
1094
|
-
"Basic " + btoa(
|
|
1095
|
-
|
|
1096
|
-
)
|
|
1097
|
-
|
|
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
|
-
},
|
|
1219
|
+
}, Pr = typeof XMLHttpRequest < "u", Lr = Pr && function(t) {
|
|
1113
1220
|
return new Promise(function(n, r) {
|
|
1114
|
-
const
|
|
1115
|
-
let
|
|
1116
|
-
const i =
|
|
1117
|
-
let { responseType: a, onUploadProgress:
|
|
1118
|
-
function
|
|
1119
|
-
|
|
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
|
|
1122
|
-
|
|
1123
|
-
function
|
|
1124
|
-
if (!
|
|
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
|
|
1127
|
-
"getAllResponseHeaders" in
|
|
1233
|
+
const E = x.from(
|
|
1234
|
+
"getAllResponseHeaders" in d && d.getAllResponseHeaders()
|
|
1128
1235
|
), P = {
|
|
1129
|
-
data: !a || a === "text" || a === "json" ?
|
|
1130
|
-
status:
|
|
1131
|
-
statusText:
|
|
1132
|
-
headers:
|
|
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:
|
|
1241
|
+
request: d
|
|
1135
1242
|
};
|
|
1136
|
-
|
|
1137
|
-
function(
|
|
1138
|
-
n(
|
|
1243
|
+
Dt(
|
|
1244
|
+
function(G) {
|
|
1245
|
+
n(G), h();
|
|
1139
1246
|
},
|
|
1140
|
-
function(
|
|
1141
|
-
r(
|
|
1247
|
+
function(G) {
|
|
1248
|
+
r(G), h();
|
|
1142
1249
|
},
|
|
1143
1250
|
P
|
|
1144
|
-
),
|
|
1251
|
+
), d = null;
|
|
1145
1252
|
}
|
|
1146
|
-
"onloadend" in
|
|
1147
|
-
!
|
|
1148
|
-
},
|
|
1149
|
-
|
|
1150
|
-
},
|
|
1151
|
-
const P =
|
|
1152
|
-
|
|
1153
|
-
},
|
|
1154
|
-
let
|
|
1155
|
-
const P =
|
|
1156
|
-
|
|
1157
|
-
new
|
|
1158
|
-
|
|
1159
|
-
P.clarifyTimeoutError ?
|
|
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
|
-
|
|
1268
|
+
d
|
|
1162
1269
|
)
|
|
1163
|
-
),
|
|
1164
|
-
},
|
|
1165
|
-
|
|
1166
|
-
}), c.isUndefined(
|
|
1167
|
-
|
|
1168
|
-
},
|
|
1169
|
-
const
|
|
1170
|
-
if (
|
|
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
|
|
1173
|
-
"Unsupported protocol " +
|
|
1174
|
-
|
|
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
|
-
|
|
1287
|
+
d.send(s || null);
|
|
1181
1288
|
});
|
|
1182
|
-
},
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
)
|
|
1193
|
-
|
|
1194
|
-
}
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
};
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
},
|
|
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,
|
|
1320
|
+
let r = 0, o;
|
|
1214
1321
|
for (; r < n; )
|
|
1215
|
-
|
|
1216
|
-
},
|
|
1217
|
-
for await (const n of
|
|
1218
|
-
yield*
|
|
1219
|
-
},
|
|
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
|
-
},
|
|
1236
|
-
const
|
|
1237
|
-
let
|
|
1238
|
-
i || (i = !0, r && r(
|
|
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(
|
|
1349
|
+
async pull(l) {
|
|
1243
1350
|
try {
|
|
1244
|
-
const { done:
|
|
1245
|
-
if (
|
|
1246
|
-
a(),
|
|
1351
|
+
const { done: f, value: u } = await o.next();
|
|
1352
|
+
if (f) {
|
|
1353
|
+
a(), l.close();
|
|
1247
1354
|
return;
|
|
1248
1355
|
}
|
|
1249
|
-
let
|
|
1356
|
+
let p = u.byteLength;
|
|
1250
1357
|
if (n) {
|
|
1251
|
-
let
|
|
1252
|
-
n(
|
|
1358
|
+
let g = s += p;
|
|
1359
|
+
n(g);
|
|
1253
1360
|
}
|
|
1254
|
-
|
|
1255
|
-
} catch (
|
|
1256
|
-
throw a(
|
|
1361
|
+
l.enqueue(new Uint8Array(u));
|
|
1362
|
+
} catch (f) {
|
|
1363
|
+
throw a(f), f;
|
|
1257
1364
|
}
|
|
1258
1365
|
},
|
|
1259
|
-
cancel(
|
|
1260
|
-
return a(
|
|
1366
|
+
cancel(l) {
|
|
1367
|
+
return a(l), o.return();
|
|
1261
1368
|
}
|
|
1262
1369
|
},
|
|
1263
1370
|
{
|
|
1264
1371
|
highWaterMark: 2
|
|
1265
1372
|
}
|
|
1266
1373
|
);
|
|
1267
|
-
}
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
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
|
-
},
|
|
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
|
-
|
|
1425
|
+
{
|
|
1426
|
+
Request: e.Request,
|
|
1427
|
+
Response: e.Response
|
|
1428
|
+
},
|
|
1282
1429
|
t
|
|
1283
1430
|
);
|
|
1284
|
-
const { fetch:
|
|
1285
|
-
if (!
|
|
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
|
|
1288
|
-
let
|
|
1289
|
-
const
|
|
1290
|
-
body: new
|
|
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
|
|
1440
|
+
return m = !0, "half";
|
|
1294
1441
|
}
|
|
1295
|
-
}).headers.has("Content-Type");
|
|
1296
|
-
return
|
|
1297
|
-
}),
|
|
1298
|
-
stream:
|
|
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
|
-
|
|
1301
|
-
!
|
|
1302
|
-
let
|
|
1303
|
-
if (
|
|
1304
|
-
return
|
|
1305
|
-
throw new
|
|
1306
|
-
`Response type '${
|
|
1307
|
-
|
|
1308
|
-
|
|
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
|
|
1313
|
-
if (
|
|
1459
|
+
const h = async (m) => {
|
|
1460
|
+
if (m == null)
|
|
1314
1461
|
return 0;
|
|
1315
|
-
if (c.isBlob(
|
|
1316
|
-
return
|
|
1317
|
-
if (c.isSpecCompliantForm(
|
|
1318
|
-
return (await new
|
|
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:
|
|
1467
|
+
body: m
|
|
1321
1468
|
}).arrayBuffer()).byteLength;
|
|
1322
|
-
if (c.isArrayBufferView(
|
|
1323
|
-
return
|
|
1324
|
-
if (c.isURLSearchParams(
|
|
1325
|
-
return (await
|
|
1326
|
-
},
|
|
1327
|
-
const
|
|
1328
|
-
return
|
|
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 (
|
|
1477
|
+
return async (m) => {
|
|
1331
1478
|
let {
|
|
1332
|
-
url:
|
|
1333
|
-
method:
|
|
1334
|
-
data:
|
|
1335
|
-
signal:
|
|
1336
|
-
cancelToken:
|
|
1337
|
-
timeout:
|
|
1338
|
-
onDownloadProgress:
|
|
1339
|
-
onUploadProgress:
|
|
1340
|
-
responseType:
|
|
1341
|
-
headers:
|
|
1342
|
-
withCredentials:
|
|
1343
|
-
fetchOptions:
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
)
|
|
1350
|
-
|
|
1351
|
-
|
|
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
|
|
1504
|
+
let Ge;
|
|
1354
1505
|
try {
|
|
1355
|
-
if (
|
|
1356
|
-
|
|
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:
|
|
1526
|
+
body: R,
|
|
1359
1527
|
duplex: "half"
|
|
1360
|
-
}),
|
|
1361
|
-
if (c.isFormData(
|
|
1362
|
-
const [
|
|
1363
|
-
|
|
1364
|
-
|
|
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
|
-
|
|
1534
|
+
R = at(S.body, ct, le, ue);
|
|
1367
1535
|
}
|
|
1368
1536
|
}
|
|
1369
|
-
c.isString(
|
|
1370
|
-
const A =
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
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 ?
|
|
1551
|
+
credentials: A ? ce : void 0
|
|
1378
1552
|
};
|
|
1379
|
-
|
|
1380
|
-
let
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
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
|
|
1388
|
-
|
|
1389
|
-
|
|
1571
|
+
const W = c.toFiniteNumber(j.headers.get("content-length")), [le, ue] = Se && ot(
|
|
1572
|
+
W,
|
|
1573
|
+
ye(st(Se), !0)
|
|
1390
1574
|
) || [];
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
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
|
-
|
|
1590
|
+
S
|
|
1396
1591
|
);
|
|
1397
1592
|
}
|
|
1398
|
-
|
|
1399
|
-
let
|
|
1400
|
-
|
|
1401
|
-
|
|
1593
|
+
B = B || "text";
|
|
1594
|
+
let k = await b[c.findKey(b, B) || "text"](
|
|
1595
|
+
j,
|
|
1596
|
+
m
|
|
1402
1597
|
);
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
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
|
-
|
|
1415
|
-
|
|
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
|
-
|
|
1418
|
-
|
|
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
|
-
) :
|
|
1634
|
+
) : y.from(A, A && A.code, m, N, A && A.response);
|
|
1426
1635
|
}
|
|
1427
1636
|
};
|
|
1428
|
-
},
|
|
1637
|
+
}, Br = /* @__PURE__ */ new Map(), jt = (t) => {
|
|
1429
1638
|
let e = t && t.env || {};
|
|
1430
|
-
const { fetch: n, Request: r, Response:
|
|
1431
|
-
let i =
|
|
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
|
-
|
|
1434
|
-
return
|
|
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
|
-
|
|
1437
|
-
const
|
|
1438
|
-
http:
|
|
1439
|
-
xhr:
|
|
1645
|
+
jt();
|
|
1646
|
+
const Je = {
|
|
1647
|
+
http: rr,
|
|
1648
|
+
xhr: Lr,
|
|
1440
1649
|
fetch: {
|
|
1441
|
-
get:
|
|
1650
|
+
get: jt
|
|
1442
1651
|
}
|
|
1443
1652
|
};
|
|
1444
|
-
c.forEach(
|
|
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
|
|
1454
|
-
function
|
|
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,
|
|
1458
|
-
const
|
|
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 (
|
|
1463
|
-
throw new
|
|
1464
|
-
if (
|
|
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
|
-
|
|
1675
|
+
s[a || "#" + i] = o;
|
|
1467
1676
|
}
|
|
1468
|
-
if (!
|
|
1469
|
-
const i = Object.entries(
|
|
1470
|
-
([
|
|
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(
|
|
1474
|
-
`) : " " +
|
|
1475
|
-
throw new
|
|
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
|
|
1689
|
+
return o;
|
|
1481
1690
|
}
|
|
1482
|
-
const
|
|
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:
|
|
1696
|
+
getAdapter: Ir,
|
|
1488
1697
|
/**
|
|
1489
1698
|
* Exposes all known adapters
|
|
1490
1699
|
* @type {Object<string, Function|Object>}
|
|
1491
1700
|
*/
|
|
1492
|
-
adapters:
|
|
1701
|
+
adapters: Je
|
|
1493
1702
|
};
|
|
1494
|
-
function
|
|
1703
|
+
function Ne(t) {
|
|
1495
1704
|
if (t.cancelToken && t.cancelToken.throwIfRequested(), t.signal && t.signal.aborted)
|
|
1496
|
-
throw new
|
|
1705
|
+
throw new ae(null, t);
|
|
1497
1706
|
}
|
|
1498
|
-
function
|
|
1499
|
-
return
|
|
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
|
-
|
|
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
|
-
|
|
1505
|
-
t
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
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
|
|
1736
|
+
const Oe = {};
|
|
1513
1737
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((t, e) => {
|
|
1514
|
-
|
|
1738
|
+
Oe[t] = function(r) {
|
|
1515
1739
|
return typeof r === t || "a" + (e < 1 ? "n " : " ") + t;
|
|
1516
1740
|
};
|
|
1517
1741
|
});
|
|
1518
|
-
const
|
|
1519
|
-
|
|
1520
|
-
function s
|
|
1521
|
-
return "[Axios v" +
|
|
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 (
|
|
1747
|
+
return (s, i, a) => {
|
|
1524
1748
|
if (e === !1)
|
|
1525
|
-
throw new
|
|
1526
|
-
|
|
1527
|
-
|
|
1749
|
+
throw new y(
|
|
1750
|
+
o(i, " has been removed" + (n ? " in " + n : "")),
|
|
1751
|
+
y.ERR_DEPRECATED
|
|
1528
1752
|
);
|
|
1529
|
-
return n && !
|
|
1530
|
-
|
|
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(
|
|
1758
|
+
)), e ? e(s, i, a) : !0;
|
|
1535
1759
|
};
|
|
1536
1760
|
};
|
|
1537
|
-
|
|
1761
|
+
Oe.spelling = function(e) {
|
|
1538
1762
|
return (n, r) => (console.warn(`${r} is likely a misspelling of ${e}`), !0);
|
|
1539
1763
|
};
|
|
1540
|
-
function
|
|
1764
|
+
function qr(t, e, n) {
|
|
1541
1765
|
if (typeof t != "object")
|
|
1542
|
-
throw new
|
|
1766
|
+
throw new y("options must be an object", y.ERR_BAD_OPTION_VALUE);
|
|
1543
1767
|
const r = Object.keys(t);
|
|
1544
|
-
let
|
|
1545
|
-
for (;
|
|
1546
|
-
const
|
|
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[
|
|
1549
|
-
if (
|
|
1550
|
-
throw new
|
|
1551
|
-
"option " +
|
|
1552
|
-
|
|
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
|
|
1781
|
+
throw new y("Unknown option " + s, y.ERR_BAD_OPTION);
|
|
1558
1782
|
}
|
|
1559
1783
|
}
|
|
1560
|
-
const
|
|
1561
|
-
assertOptions:
|
|
1562
|
-
validators:
|
|
1563
|
-
},
|
|
1564
|
-
let
|
|
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
|
|
1568
|
-
response: new
|
|
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
|
|
1585
|
-
Error.captureStackTrace ? Error.captureStackTrace(
|
|
1586
|
-
const
|
|
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
|
-
|
|
1589
|
-
|
|
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 =
|
|
1598
|
-
const { transitional: r, paramsSerializer:
|
|
1599
|
-
r !== void 0 &&
|
|
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:
|
|
1603
|
-
forcedJSONParsing:
|
|
1604
|
-
clarifyTimeoutError:
|
|
1605
|
-
legacyInterceptorReqResOrdering:
|
|
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
|
-
),
|
|
1609
|
-
serialize:
|
|
1610
|
-
} :
|
|
1611
|
-
|
|
1845
|
+
), o != null && (c.isFunction(o) ? n.paramsSerializer = {
|
|
1846
|
+
serialize: o
|
|
1847
|
+
} : me.assertOptions(
|
|
1848
|
+
o,
|
|
1612
1849
|
{
|
|
1613
|
-
encode:
|
|
1614
|
-
serialize:
|
|
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),
|
|
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:
|
|
1621
|
-
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 =
|
|
1626
|
-
|
|
1627
|
-
delete
|
|
1628
|
-
}), n.headers =
|
|
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
|
|
1631
|
-
this.interceptors.request.forEach(function(
|
|
1632
|
-
if (typeof
|
|
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
|
-
|
|
1635
|
-
const
|
|
1636
|
-
|
|
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
|
|
1639
|
-
this.interceptors.response.forEach(function(
|
|
1640
|
-
|
|
1875
|
+
const f = [];
|
|
1876
|
+
this.interceptors.response.forEach(function(h) {
|
|
1877
|
+
f.push(h.fulfilled, h.rejected);
|
|
1641
1878
|
});
|
|
1642
|
-
let
|
|
1643
|
-
if (!
|
|
1644
|
-
const
|
|
1645
|
-
for (
|
|
1646
|
-
|
|
1647
|
-
return
|
|
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
|
-
|
|
1650
|
-
let
|
|
1651
|
-
for (;
|
|
1652
|
-
const
|
|
1886
|
+
g = a.length;
|
|
1887
|
+
let w = n;
|
|
1888
|
+
for (; p < g; ) {
|
|
1889
|
+
const b = a[p++], h = a[p++];
|
|
1653
1890
|
try {
|
|
1654
|
-
|
|
1655
|
-
} catch (
|
|
1656
|
-
|
|
1891
|
+
w = b(w);
|
|
1892
|
+
} catch (d) {
|
|
1893
|
+
h.call(this, d);
|
|
1657
1894
|
break;
|
|
1658
1895
|
}
|
|
1659
1896
|
}
|
|
1660
1897
|
try {
|
|
1661
|
-
|
|
1662
|
-
} catch (
|
|
1663
|
-
return Promise.reject(
|
|
1898
|
+
u = ft.call(this, w);
|
|
1899
|
+
} catch (b) {
|
|
1900
|
+
return Promise.reject(b);
|
|
1664
1901
|
}
|
|
1665
|
-
for (
|
|
1666
|
-
|
|
1667
|
-
return
|
|
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 =
|
|
1671
|
-
const n =
|
|
1672
|
-
return
|
|
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
|
-
|
|
1913
|
+
z.prototype[e] = function(n, r) {
|
|
1677
1914
|
return this.request(
|
|
1678
|
-
|
|
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(
|
|
1925
|
+
return function(s, i, a) {
|
|
1689
1926
|
return this.request(
|
|
1690
|
-
|
|
1927
|
+
J(a || {}, {
|
|
1691
1928
|
method: e,
|
|
1692
1929
|
headers: r ? {
|
|
1693
1930
|
"Content-Type": "multipart/form-data"
|
|
1694
1931
|
} : {},
|
|
1695
|
-
url:
|
|
1932
|
+
url: s,
|
|
1696
1933
|
data: i
|
|
1697
1934
|
})
|
|
1698
1935
|
);
|
|
1699
1936
|
};
|
|
1700
1937
|
}
|
|
1701
|
-
|
|
1938
|
+
z.prototype[e] = n(), e !== "query" && (z.prototype[e + "Form"] = n(!0));
|
|
1702
1939
|
});
|
|
1703
|
-
let
|
|
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(
|
|
1709
|
-
n =
|
|
1945
|
+
this.promise = new Promise(function(s) {
|
|
1946
|
+
n = s;
|
|
1710
1947
|
});
|
|
1711
1948
|
const r = this;
|
|
1712
|
-
this.promise.then((
|
|
1949
|
+
this.promise.then((o) => {
|
|
1713
1950
|
if (!r._listeners) return;
|
|
1714
|
-
let
|
|
1715
|
-
for (;
|
|
1716
|
-
r._listeners[
|
|
1951
|
+
let s = r._listeners.length;
|
|
1952
|
+
for (; s-- > 0; )
|
|
1953
|
+
r._listeners[s](o);
|
|
1717
1954
|
r._listeners = null;
|
|
1718
|
-
}), this.promise.then = (
|
|
1719
|
-
let
|
|
1955
|
+
}), this.promise.then = (o) => {
|
|
1956
|
+
let s;
|
|
1720
1957
|
const i = new Promise((a) => {
|
|
1721
|
-
r.subscribe(a),
|
|
1722
|
-
}).then(
|
|
1958
|
+
r.subscribe(a), s = a;
|
|
1959
|
+
}).then(o);
|
|
1723
1960
|
return i.cancel = function() {
|
|
1724
|
-
r.unsubscribe(
|
|
1961
|
+
r.unsubscribe(s);
|
|
1725
1962
|
}, i;
|
|
1726
|
-
}, e(function(
|
|
1727
|
-
r.reason || (r.reason = new
|
|
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
|
|
1770
|
-
e =
|
|
2006
|
+
token: new Bt(function(o) {
|
|
2007
|
+
e = o;
|
|
1771
2008
|
}),
|
|
1772
2009
|
cancel: e
|
|
1773
2010
|
};
|
|
1774
2011
|
}
|
|
1775
2012
|
};
|
|
1776
|
-
function
|
|
2013
|
+
function Hr(t) {
|
|
1777
2014
|
return function(n) {
|
|
1778
2015
|
return t.apply(null, n);
|
|
1779
2016
|
};
|
|
1780
2017
|
}
|
|
1781
|
-
function
|
|
2018
|
+
function $r(t) {
|
|
1782
2019
|
return c.isObject(t) && t.isAxiosError === !0;
|
|
1783
2020
|
}
|
|
1784
|
-
const
|
|
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(
|
|
1856
|
-
|
|
2092
|
+
Object.entries(Be).forEach(([t, e]) => {
|
|
2093
|
+
Be[e] = t;
|
|
1857
2094
|
});
|
|
1858
|
-
function
|
|
1859
|
-
const e = new
|
|
1860
|
-
return c.extend(n,
|
|
1861
|
-
return
|
|
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
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
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
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
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:
|
|
1886
|
-
AxiosError:
|
|
1887
|
-
CanceledError:
|
|
1888
|
-
isCancel:
|
|
1889
|
-
CancelToken:
|
|
1890
|
-
VERSION:
|
|
1891
|
-
all:
|
|
1892
|
-
Cancel:
|
|
1893
|
-
isAxiosError:
|
|
1894
|
-
spread:
|
|
1895
|
-
toFormData:
|
|
1896
|
-
AxiosHeaders:
|
|
1897
|
-
HttpStatusCode:
|
|
1898
|
-
formToJSON:
|
|
1899
|
-
getAdapter:
|
|
1900
|
-
mergeConfig:
|
|
1901
|
-
|
|
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
|
-
},
|
|
1906
|
-
class
|
|
2143
|
+
}, Jr = ["put", "post", "patch"], pt = "Local-Request-Id", Wr = 100, Vr = 300, Kr = "/api/proxy";
|
|
2144
|
+
class Xr {
|
|
1907
2145
|
constructor(e = {}) {
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
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 =
|
|
2154
|
+
const n = Te(e, [
|
|
1917
2155
|
"settings",
|
|
1918
2156
|
"query"
|
|
1919
2157
|
]);
|
|
1920
|
-
this.axios =
|
|
1921
|
-
|
|
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 =
|
|
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 =
|
|
1937
|
-
const n =
|
|
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 =
|
|
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
|
|
1954
|
-
"Content-Type":
|
|
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
|
-
...
|
|
2194
|
+
...o
|
|
1957
2195
|
};
|
|
1958
|
-
return n.skipWarn && (
|
|
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(([
|
|
1968
|
-
r.append(
|
|
2205
|
+
return Object.entries(e).forEach(([o, s]) => {
|
|
2206
|
+
r.append(o, s);
|
|
1969
2207
|
}), r;
|
|
1970
2208
|
}
|
|
1971
|
-
createSendData(e, n, r,
|
|
1972
|
-
const { type: i, skipWarn: a } = e, { name:
|
|
1973
|
-
let { data:
|
|
1974
|
-
const
|
|
1975
|
-
return
|
|
1976
|
-
...
|
|
1977
|
-
}) : i === "form" ?
|
|
1978
|
-
...
|
|
1979
|
-
...
|
|
1980
|
-
...
|
|
1981
|
-
} : (
|
|
1982
|
-
...
|
|
1983
|
-
...
|
|
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:
|
|
1986
|
-
params:
|
|
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
|
|
1993
|
-
const
|
|
2230
|
+
let o = Ye(n) ? new URL(n).origin : "";
|
|
2231
|
+
const s = o ? n.replace(o, "") : n;
|
|
1994
2232
|
try {
|
|
1995
|
-
const i =
|
|
2233
|
+
const i = Gt(s, {
|
|
1996
2234
|
encode: encodeURIComponent
|
|
1997
2235
|
});
|
|
1998
|
-
return
|
|
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
|
|
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:
|
|
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:
|
|
2029
|
-
if (r &&
|
|
2030
|
-
const
|
|
2031
|
-
|
|
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:
|
|
2036
|
-
return r &&
|
|
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 =
|
|
2280
|
+
const r = ee({}, this.settings, e.settings || {}), o = e.query || {}, s = Te(e, [
|
|
2043
2281
|
"settings",
|
|
2044
2282
|
"query"
|
|
2045
|
-
]), i =
|
|
2046
|
-
this.records[i] = { settings: r, config:
|
|
2047
|
-
const
|
|
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
|
-
|
|
2050
|
-
|
|
2287
|
+
s,
|
|
2288
|
+
p,
|
|
2051
2289
|
n,
|
|
2052
|
-
|
|
2290
|
+
o
|
|
2053
2291
|
);
|
|
2054
|
-
return this.showLoading(r), new Promise((
|
|
2292
|
+
return this.showLoading(r), new Promise((b, h) => {
|
|
2055
2293
|
this.axios({
|
|
2056
2294
|
cancelToken: a.token,
|
|
2057
|
-
...
|
|
2058
|
-
url:
|
|
2059
|
-
headers:
|
|
2060
|
-
data:
|
|
2061
|
-
params:
|
|
2062
|
-
}).then((
|
|
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,
|
|
2069
|
-
return () => r.eject(
|
|
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,
|
|
2073
|
-
return () => r.eject(
|
|
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:
|
|
2315
|
+
const { code: n, executor: r, callback: o, complete: s } = e.skipWarn;
|
|
2078
2316
|
this.stopSkipWarn = this.useResponse((i) => {
|
|
2079
|
-
const
|
|
2080
|
-
if (!
|
|
2081
|
-
const { data:
|
|
2082
|
-
if (!
|
|
2083
|
-
if (
|
|
2084
|
-
|
|
2085
|
-
const
|
|
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
|
-
...
|
|
2088
|
-
settings:
|
|
2325
|
+
...f.config,
|
|
2326
|
+
settings: f.settings
|
|
2089
2327
|
},
|
|
2090
2328
|
!0
|
|
2091
2329
|
));
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
}), i.promise =
|
|
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
|
|
2101
|
-
const e = new
|
|
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:
|
|
2108
|
-
useRequest:
|
|
2345
|
+
setConfig: o,
|
|
2346
|
+
useRequest: s,
|
|
2109
2347
|
useResponse: i
|
|
2110
2348
|
});
|
|
2111
2349
|
}
|
|
2112
|
-
const
|
|
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
|
|
2357
|
+
function Qr(t, e = It) {
|
|
2120
2358
|
const n = typeof t == "string" ? { url: t } : t;
|
|
2121
|
-
return (r,
|
|
2359
|
+
return (r, o) => e.send(ee({}, n, o || {}, { data: r }));
|
|
2122
2360
|
}
|
|
2123
|
-
function
|
|
2361
|
+
function $o(t, e = It) {
|
|
2124
2362
|
const n = {};
|
|
2125
|
-
for (const [r,
|
|
2126
|
-
n[r] =
|
|
2363
|
+
for (const [r, o] of Object.entries(t))
|
|
2364
|
+
n[r] = Qr(o, e);
|
|
2127
2365
|
return n;
|
|
2128
2366
|
}
|
|
2129
|
-
function
|
|
2130
|
-
const n =
|
|
2131
|
-
|
|
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
|
-
|
|
2374
|
+
o.value = !1;
|
|
2137
2375
|
});
|
|
2138
2376
|
};
|
|
2139
|
-
return
|
|
2377
|
+
return s(), {
|
|
2140
2378
|
data: n,
|
|
2141
2379
|
error: r,
|
|
2142
|
-
loading:
|
|
2143
|
-
reload:
|
|
2380
|
+
loading: o,
|
|
2381
|
+
reload: s
|
|
2144
2382
|
};
|
|
2145
2383
|
}
|
|
2146
|
-
const
|
|
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 = (
|
|
2151
|
-
n(
|
|
2388
|
+
}, r.onerror = (o) => {
|
|
2389
|
+
n(o);
|
|
2152
2390
|
};
|
|
2153
2391
|
});
|
|
2154
|
-
function
|
|
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
|
|
2398
|
+
function Vo(t) {
|
|
2161
2399
|
const e = t.split(","), n = e[0].match(/:(.*?);/)?.[1], r = atob(e[1]);
|
|
2162
|
-
let
|
|
2163
|
-
const
|
|
2164
|
-
for (;
|
|
2165
|
-
o
|
|
2166
|
-
return new Blob([
|
|
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
|
|
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
|
|
2173
|
-
class
|
|
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
|
-
|
|
2413
|
+
L(this, "options", {
|
|
2176
2414
|
type: "cache",
|
|
2177
2415
|
expired: 0,
|
|
2178
2416
|
prefix: "__VTJ_"
|
|
2179
2417
|
});
|
|
2180
|
-
|
|
2181
|
-
|
|
2418
|
+
L(this, "caches", {});
|
|
2419
|
+
L(this, "types");
|
|
2182
2420
|
this.types = {
|
|
2183
|
-
local:
|
|
2184
|
-
session:
|
|
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:
|
|
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:
|
|
2433
|
+
expired: s
|
|
2196
2434
|
};
|
|
2197
|
-
|
|
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:
|
|
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[
|
|
2441
|
+
a = i[s];
|
|
2204
2442
|
else {
|
|
2205
|
-
const
|
|
2206
|
-
if (
|
|
2443
|
+
const g = i.getItem(s);
|
|
2444
|
+
if (g)
|
|
2207
2445
|
try {
|
|
2208
|
-
a = JSON.parse(
|
|
2209
|
-
} catch (
|
|
2210
|
-
console.warn("[Storage] JSON.parse",
|
|
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:
|
|
2215
|
-
return
|
|
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:
|
|
2219
|
-
|
|
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
|
|
2227
|
-
function
|
|
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
|
|
2231
|
-
function
|
|
2232
|
-
return
|
|
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
|
-
})(
|
|
2236
|
-
var
|
|
2473
|
+
})(Zr, function(n, r) {
|
|
2474
|
+
var o = {
|
|
2237
2475
|
timeout: 5e3,
|
|
2238
2476
|
jsonpCallback: "callback"
|
|
2239
2477
|
};
|
|
2240
|
-
function
|
|
2478
|
+
function s() {
|
|
2241
2479
|
return "jsonp_" + Date.now() + "_" + Math.ceil(Math.random() * 1e5);
|
|
2242
2480
|
}
|
|
2243
|
-
function i(
|
|
2481
|
+
function i(f) {
|
|
2244
2482
|
try {
|
|
2245
|
-
delete window[
|
|
2483
|
+
delete window[f];
|
|
2246
2484
|
} catch {
|
|
2247
|
-
window[
|
|
2485
|
+
window[f] = void 0;
|
|
2248
2486
|
}
|
|
2249
2487
|
}
|
|
2250
|
-
function a(
|
|
2251
|
-
var
|
|
2252
|
-
|
|
2488
|
+
function a(f) {
|
|
2489
|
+
var u = document.getElementById(f);
|
|
2490
|
+
u && document.getElementsByTagName("head")[0].removeChild(u);
|
|
2253
2491
|
}
|
|
2254
|
-
function f
|
|
2255
|
-
var
|
|
2256
|
-
return new Promise(function(
|
|
2257
|
-
var
|
|
2258
|
-
window[
|
|
2259
|
-
|
|
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(
|
|
2501
|
+
return Promise.resolve(R);
|
|
2264
2502
|
}
|
|
2265
|
-
}),
|
|
2266
|
-
},
|
|
2267
|
-
var
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
i(
|
|
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
|
-
},
|
|
2273
|
-
|
|
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 =
|
|
2515
|
+
r.exports = l;
|
|
2278
2516
|
});
|
|
2279
|
-
})(
|
|
2517
|
+
})(te, te.exports)), te.exports;
|
|
2280
2518
|
}
|
|
2281
|
-
var
|
|
2282
|
-
const
|
|
2283
|
-
function
|
|
2284
|
-
if (
|
|
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
|
|
2291
|
-
const e = t.match(
|
|
2528
|
+
function oo(t = "") {
|
|
2529
|
+
const e = t.match(Yt);
|
|
2292
2530
|
return e ? e[0] : "";
|
|
2293
2531
|
}
|
|
2294
|
-
function
|
|
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
|
|
2538
|
+
function ve(t, e, n) {
|
|
2301
2539
|
const r = {};
|
|
2302
2540
|
t = (t || location.search).replace(/^[^]*\?/, ""), e = e || "&", n = n || "=";
|
|
2303
|
-
let
|
|
2304
|
-
const
|
|
2541
|
+
let o;
|
|
2542
|
+
const s = new RegExp(
|
|
2305
2543
|
"(?:^|\\" + e + ")([^\\" + n + "\\" + e + "]+)(?:\\" + n + "([^\\" + e + "]*))?",
|
|
2306
2544
|
"g"
|
|
2307
2545
|
);
|
|
2308
|
-
for (; (
|
|
2309
|
-
|
|
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
|
|
2313
|
-
e = typeof e == "string" ?
|
|
2314
|
-
const n = t.split("?")[0], r =
|
|
2315
|
-
return
|
|
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
|
|
2555
|
+
const Yo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2318
2556
|
__proto__: null,
|
|
2319
|
-
append:
|
|
2320
|
-
getCurrentHost:
|
|
2321
|
-
getHost:
|
|
2322
|
-
parse:
|
|
2323
|
-
stringify:
|
|
2557
|
+
append: Ht,
|
|
2558
|
+
getCurrentHost: ro,
|
|
2559
|
+
getHost: oo,
|
|
2560
|
+
parse: ve,
|
|
2561
|
+
stringify: Mt
|
|
2324
2562
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
2325
|
-
async function
|
|
2563
|
+
async function Zo(t, e = {}) {
|
|
2326
2564
|
const { query: n = {} } = e;
|
|
2327
|
-
t.includes("${") && (t =
|
|
2328
|
-
const r =
|
|
2329
|
-
return await (await
|
|
2330
|
-
}
|
|
2331
|
-
var
|
|
2332
|
-
function
|
|
2333
|
-
if (
|
|
2334
|
-
|
|
2335
|
-
var a = document.head || document.getElementsByTagName("head")[0],
|
|
2336
|
-
typeof
|
|
2337
|
-
},
|
|
2338
|
-
var
|
|
2339
|
-
|
|
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,
|
|
2342
|
-
for (var
|
|
2343
|
-
r.setAttribute(
|
|
2579
|
+
function t(r, o) {
|
|
2580
|
+
for (var s in o)
|
|
2581
|
+
r.setAttribute(s, o[s]);
|
|
2344
2582
|
}
|
|
2345
|
-
function e(r,
|
|
2583
|
+
function e(r, o) {
|
|
2346
2584
|
r.onload = function() {
|
|
2347
|
-
this.onerror = this.onload = null,
|
|
2585
|
+
this.onerror = this.onload = null, o(null, r);
|
|
2348
2586
|
}, r.onerror = function() {
|
|
2349
|
-
this.onerror = this.onload = null,
|
|
2587
|
+
this.onerror = this.onload = null, o(new Error("Failed to load " + this.src), r);
|
|
2350
2588
|
};
|
|
2351
2589
|
}
|
|
2352
|
-
function n(r,
|
|
2590
|
+
function n(r, o) {
|
|
2353
2591
|
r.onreadystatechange = function() {
|
|
2354
|
-
this.readyState != "complete" && this.readyState != "loaded" || (this.onreadystatechange = null,
|
|
2592
|
+
this.readyState != "complete" && this.readyState != "loaded" || (this.onreadystatechange = null, o(null, r));
|
|
2355
2593
|
};
|
|
2356
2594
|
}
|
|
2357
|
-
return
|
|
2595
|
+
return De;
|
|
2358
2596
|
}
|
|
2359
|
-
var
|
|
2360
|
-
const
|
|
2361
|
-
function
|
|
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:
|
|
2364
|
-
|
|
2365
|
-
|
|
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
|
|
2370
|
-
return function(...
|
|
2371
|
-
if (e &&
|
|
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,
|
|
2611
|
+
return console[t].apply(console, lo(o, n));
|
|
2374
2612
|
};
|
|
2375
2613
|
};
|
|
2376
|
-
function
|
|
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
|
|
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
|
|
2635
|
+
const fo = {
|
|
2398
2636
|
level: "warn",
|
|
2399
2637
|
bizName: "*"
|
|
2400
2638
|
};
|
|
2401
|
-
class
|
|
2639
|
+
class po {
|
|
2402
2640
|
constructor(e) {
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
this.options = { ...
|
|
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 =
|
|
2647
|
+
this.config = uo(r, e);
|
|
2410
2648
|
}
|
|
2411
2649
|
_log(e) {
|
|
2412
|
-
const { targetLevel: n, targetBizName: r } = this.config, { bizName:
|
|
2413
|
-
return
|
|
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
|
|
2432
|
-
return new
|
|
2669
|
+
function ho(t) {
|
|
2670
|
+
return new po(t);
|
|
2433
2671
|
}
|
|
2434
|
-
const
|
|
2672
|
+
const ts = ho({ level: "log", bizName: "VTJ" });
|
|
2435
2673
|
/*! js-cookie v3.0.8 | MIT */
|
|
2436
|
-
function
|
|
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
|
|
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
|
|
2456
|
-
function n(
|
|
2693
|
+
function Ie(t, e) {
|
|
2694
|
+
function n(o, s, i) {
|
|
2457
2695
|
if (!(typeof document > "u")) {
|
|
2458
|
-
i =
|
|
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
|
|
2461
|
-
i[
|
|
2462
|
-
return document.cookie =
|
|
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(
|
|
2466
|
-
if (!(typeof document > "u" || arguments.length && !
|
|
2467
|
-
for (var
|
|
2468
|
-
var
|
|
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
|
|
2471
|
-
if (
|
|
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
|
|
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(
|
|
2721
|
+
remove: function(o, s) {
|
|
2484
2722
|
n(
|
|
2485
|
-
|
|
2723
|
+
o,
|
|
2486
2724
|
"",
|
|
2487
|
-
|
|
2725
|
+
de({}, s, {
|
|
2488
2726
|
expires: -1
|
|
2489
2727
|
})
|
|
2490
2728
|
);
|
|
2491
2729
|
},
|
|
2492
|
-
withAttributes: function(
|
|
2493
|
-
return
|
|
2730
|
+
withAttributes: function(o) {
|
|
2731
|
+
return Ie(this.converter, de({}, this.attributes, o));
|
|
2494
2732
|
},
|
|
2495
|
-
withConverter: function(
|
|
2496
|
-
return
|
|
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
|
|
2506
|
-
function
|
|
2507
|
-
|
|
2743
|
+
var We = Ie(mo, { path: "/" });
|
|
2744
|
+
function yo(t, e, n) {
|
|
2745
|
+
We.set(t, e, n);
|
|
2508
2746
|
}
|
|
2509
|
-
function
|
|
2510
|
-
return
|
|
2747
|
+
function go(t) {
|
|
2748
|
+
return We.get(t);
|
|
2511
2749
|
}
|
|
2512
|
-
function
|
|
2513
|
-
|
|
2750
|
+
function wo(t, e) {
|
|
2751
|
+
We.remove(t, e);
|
|
2514
2752
|
}
|
|
2515
|
-
const
|
|
2753
|
+
const ns = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2516
2754
|
__proto__: null,
|
|
2517
|
-
get:
|
|
2518
|
-
remove:
|
|
2519
|
-
set:
|
|
2755
|
+
get: go,
|
|
2756
|
+
remove: wo,
|
|
2757
|
+
set: yo
|
|
2520
2758
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
2521
|
-
function
|
|
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
|
|
2526
|
-
const r = new Blob([t], { type: n }),
|
|
2527
|
-
|
|
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
|
|
2767
|
+
async function os(t, e = "", n) {
|
|
2530
2768
|
return fetch(t, { credentials: "include" }).then(async (r) => {
|
|
2531
|
-
const
|
|
2532
|
-
return
|
|
2769
|
+
const o = await r.blob();
|
|
2770
|
+
return $t(o, e, n), o;
|
|
2533
2771
|
});
|
|
2534
2772
|
}
|
|
2535
|
-
function
|
|
2773
|
+
function ss(t, e = "") {
|
|
2536
2774
|
const n = JSON.stringify(t);
|
|
2537
|
-
|
|
2775
|
+
$t(n, e, "application/json");
|
|
2538
2776
|
}
|
|
2539
|
-
function
|
|
2777
|
+
function is() {
|
|
2540
2778
|
const t = navigator.userAgent;
|
|
2541
|
-
let e = "Unknown", n = "Unknown", r = "Unknown",
|
|
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
|
-
},
|
|
2555
|
-
|
|
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",
|
|
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",
|
|
2813
|
+
r = "Firefox", o = a[1];
|
|
2576
2814
|
else {
|
|
2577
|
-
const
|
|
2578
|
-
if (
|
|
2579
|
-
r = "Opera",
|
|
2815
|
+
const l = t.match(/(Opera|OPR)\/(\d+)/i);
|
|
2816
|
+
if (l)
|
|
2817
|
+
r = "Opera", o = l[2];
|
|
2580
2818
|
else {
|
|
2581
|
-
const
|
|
2582
|
-
if (
|
|
2583
|
-
r = "Chrome",
|
|
2819
|
+
const f = t.match(/Chrome\/(\d+)/i);
|
|
2820
|
+
if (f)
|
|
2821
|
+
r = "Chrome", o = f[1];
|
|
2584
2822
|
else {
|
|
2585
|
-
const
|
|
2586
|
-
if (
|
|
2587
|
-
r = "Safari",
|
|
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
|
|
2590
|
-
|
|
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
|
|
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) && (
|
|
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:
|
|
2603
|
-
isMobile:
|
|
2840
|
+
browserVersion: o,
|
|
2841
|
+
isMobile: s
|
|
2604
2842
|
};
|
|
2605
2843
|
}
|
|
2606
2844
|
export {
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
-
|
|
2619
|
-
|
|
2620
|
-
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
|
|
2625
|
-
|
|
2626
|
-
|
|
2627
|
-
|
|
2628
|
-
|
|
2629
|
-
|
|
2630
|
-
|
|
2631
|
-
|
|
2632
|
-
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
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
|
};
|