@das-fed/utils 6.4.0-hot.20 → 6.4.0-hot.22
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/api-services/index.js +1684 -1368
- package/api-services/index.js.gz +0 -0
- package/api-services/modules/app-manage/index.js +1928 -1612
- package/api-services/modules/app-manage/index.js.gz +0 -0
- package/api-services/modules/authentication/index.js +1928 -1612
- package/api-services/modules/authentication/index.js.gz +0 -0
- package/api-services/modules/bems/index.js +1931 -1615
- package/api-services/modules/bems/index.js.gz +0 -0
- package/api-services/modules/contract/index.js +1928 -1612
- package/api-services/modules/contract/index.js.gz +0 -0
- package/api-services/modules/duty-manage/index.js +1917 -1601
- package/api-services/modules/duty-manage/index.js.gz +0 -0
- package/api-services/modules/enterpriseright/index.js +1928 -1612
- package/api-services/modules/enterpriseright/index.js.gz +0 -0
- package/api-services/modules/file/index.js +119 -118
- package/api-services/modules/file/index.js.gz +0 -0
- package/api-services/modules/gateway-edge/index.js +1928 -1612
- package/api-services/modules/gateway-edge/index.js.gz +0 -0
- package/api-services/modules/index.js +1683 -1367
- package/api-services/modules/index.js.gz +0 -0
- package/api-services/modules/iot/index.js +1940 -1624
- package/api-services/modules/iot/index.js.gz +0 -0
- package/api-services/modules/justauth/index.js +1914 -1598
- package/api-services/modules/justauth/index.js.gz +0 -0
- package/api-services/modules/knowledge/index.js +1928 -1612
- package/api-services/modules/knowledge/index.js.gz +0 -0
- package/api-services/modules/link/index.js +1928 -1612
- package/api-services/modules/link/index.js.gz +0 -0
- package/api-services/modules/permission/index.js +1928 -1612
- package/api-services/modules/permission/index.js.gz +0 -0
- package/api-services/modules/platformManage/index.js +1935 -1619
- package/api-services/modules/platformManage/index.js.gz +0 -0
- package/api-services/modules/portal/index.js +1928 -1612
- package/api-services/modules/portal/index.js.gz +0 -0
- package/api-services/modules/space-manage/index.js +1928 -1612
- package/api-services/modules/space-manage/index.js.gz +0 -0
- package/api-services/modules/super-admin/index.js +1916 -1600
- package/api-services/modules/super-admin/index.js.gz +0 -0
- package/api-services/modules/supplier/index.js +1930 -1614
- package/api-services/modules/supplier/index.js.gz +0 -0
- package/api-services/modules/supplychain-manage/index.js +1928 -1612
- package/api-services/modules/supplychain-manage/index.js.gz +0 -0
- package/api-services/modules/systemConfiguration/index.js +1928 -1612
- package/api-services/modules/systemConfiguration/index.js.gz +0 -0
- package/api-services/modules/tool/index.js +1928 -1612
- package/api-services/modules/tool/index.js.gz +0 -0
- package/api-services/src/create-service/index.js +1912 -1596
- package/api-services/src/create-service/index.js.gz +0 -0
- package/common-info/getInfoFromUrl/index.js.gz +0 -0
- package/common-info/index.js.gz +0 -0
- package/common-info/set-personal-info/index.js +837 -570
- package/common-info/set-personal-info/index.js.gz +0 -0
- package/common-info/type.d.ts +104 -104
- package/common-tools/extract-file-name/index.js +922 -655
- package/common-tools/extract-file-name/index.js.gz +0 -0
- package/common-tools/get-url-params/index.js.gz +0 -0
- package/create-api-service/index.js +1912 -1596
- package/create-api-service/index.js.gz +0 -0
- package/create-api-service/sso/index.js +968 -701
- package/create-api-service/sso/index.js.gz +0 -0
- package/curring-http/index.js +1364 -1097
- package/curring-http/index.js.gz +0 -0
- package/curring-http/type.d.ts +87 -87
- package/directive/auth/index.js.gz +0 -0
- package/hooks/use-get-auth/index.js.gz +0 -0
- package/nextTiken/index.js.gz +0 -0
- package/package.json +4 -3
- package/pinyin-first-character/index.js +19799 -20879
- package/pinyin-first-character/index.js.gz +0 -0
- package/style/index.js +4 -2
- package/style/index.js.gz +0 -0
- package/token-tools/index.js.gz +0 -0
- package/use-low-code/index.js +3 -3
- package/use-low-code/index.js.gz +0 -0
- package/use-low-code/style.css +1 -1
- package/webSocket-service/index.js.gz +0 -0
- package/webSocket-service/type.d.ts +28 -28
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { unref as
|
|
2
|
-
import { encryption as
|
|
3
|
-
import { getConfig as
|
|
4
|
-
import { getUrlParams as
|
|
5
|
-
import { getAccessToken as
|
|
6
|
-
import { setProcessEngineToken as
|
|
7
|
-
import { setPersonalInfo as
|
|
8
|
-
function
|
|
1
|
+
import { unref as kt, getCurrentScope as Ct, onScopeDispose as Nt, ref as X, watch as ge } from "vue";
|
|
2
|
+
import { encryption as Lt } from "@das-fed/utils/atob";
|
|
3
|
+
import { getConfig as be } from "@das-fed/utils/config";
|
|
4
|
+
import { getUrlParams as Ge, funcUrlDel as Ut } from "@das-fed/utils/common-tools";
|
|
5
|
+
import { getAccessToken as M, removeAccessToken as Xe, getAccessTokenInfo as K, setAccessToken as Dt } from "@das-fed/utils/token-tools";
|
|
6
|
+
import { setProcessEngineToken as Ft, removeProcessEngineToken as Bt } from "@das-fed/utils/process-engine-info";
|
|
7
|
+
import { setPersonalInfo as Ze } from "@das-fed/utils/common-info/set-personal-info";
|
|
8
|
+
function Ye(e, t) {
|
|
9
9
|
return function() {
|
|
10
10
|
return e.apply(t, arguments);
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
const { toString:
|
|
14
|
-
const n =
|
|
13
|
+
const { toString: vt } = Object.prototype, { getPrototypeOf: Ee } = Object, ee = /* @__PURE__ */ ((e) => (t) => {
|
|
14
|
+
const n = vt.call(t);
|
|
15
15
|
return e[n] || (e[n] = n.slice(8, -1).toLowerCase());
|
|
16
|
-
})(/* @__PURE__ */ Object.create(null)),
|
|
17
|
-
function
|
|
18
|
-
return e !== null && !
|
|
16
|
+
})(/* @__PURE__ */ Object.create(null)), x = (e) => (e = e.toLowerCase(), (t) => ee(t) === e), te = (e) => (t) => typeof t === e, { isArray: v } = Array, H = te("undefined");
|
|
17
|
+
function It(e) {
|
|
18
|
+
return e !== null && !H(e) && e.constructor !== null && !H(e.constructor) && _(e.constructor.isBuffer) && e.constructor.isBuffer(e);
|
|
19
19
|
}
|
|
20
|
-
const
|
|
21
|
-
function
|
|
20
|
+
const et = x("ArrayBuffer");
|
|
21
|
+
function jt(e) {
|
|
22
22
|
let t;
|
|
23
|
-
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer &&
|
|
23
|
+
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && et(e.buffer), t;
|
|
24
24
|
}
|
|
25
|
-
const
|
|
26
|
-
if (
|
|
25
|
+
const qt = te("string"), _ = te("function"), tt = te("number"), ne = (e) => e !== null && typeof e == "object", Mt = (e) => e === !0 || e === !1, Q = (e) => {
|
|
26
|
+
if (ee(e) !== "object")
|
|
27
27
|
return !1;
|
|
28
|
-
const t =
|
|
28
|
+
const t = Ee(e);
|
|
29
29
|
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(Symbol.toStringTag in e) && !(Symbol.iterator in e);
|
|
30
|
-
},
|
|
30
|
+
}, Ht = x("Date"), zt = x("File"), $t = x("Blob"), Jt = x("FileList"), Vt = (e) => ne(e) && _(e.pipe), Wt = (e) => {
|
|
31
31
|
let t;
|
|
32
|
-
return e && (typeof FormData == "function" && e instanceof FormData ||
|
|
33
|
-
t === "object" &&
|
|
34
|
-
},
|
|
35
|
-
function
|
|
32
|
+
return e && (typeof FormData == "function" && e instanceof FormData || _(e.append) && ((t = ee(e)) === "formdata" || // detect form-data instance
|
|
33
|
+
t === "object" && _(e.toString) && e.toString() === "[object FormData]"));
|
|
34
|
+
}, Kt = x("URLSearchParams"), [Qt, Gt, Xt, Zt] = ["ReadableStream", "Request", "Response", "Headers"].map(x), Yt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
35
|
+
function J(e, t, { allOwnKeys: n = !1 } = {}) {
|
|
36
36
|
if (e === null || typeof e > "u")
|
|
37
37
|
return;
|
|
38
38
|
let r, s;
|
|
39
|
-
if (typeof e != "object" && (e = [e]),
|
|
39
|
+
if (typeof e != "object" && (e = [e]), v(e))
|
|
40
40
|
for (r = 0, s = e.length; r < s; r++)
|
|
41
41
|
t.call(null, e[r], r, e);
|
|
42
42
|
else {
|
|
@@ -46,7 +46,7 @@ function v(e, t, { allOwnKeys: n = !1 } = {}) {
|
|
|
46
46
|
c = o[r], t.call(null, e[c], c, e);
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
|
-
function
|
|
49
|
+
function nt(e, t) {
|
|
50
50
|
t = t.toLowerCase();
|
|
51
51
|
const n = Object.keys(e);
|
|
52
52
|
let r = n.length, s;
|
|
@@ -55,75 +55,75 @@ function He(e, t) {
|
|
|
55
55
|
return s;
|
|
56
56
|
return null;
|
|
57
57
|
}
|
|
58
|
-
const
|
|
59
|
-
function
|
|
60
|
-
const { caseless: e } =
|
|
61
|
-
const o = e &&
|
|
62
|
-
|
|
58
|
+
const L = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, rt = (e) => !H(e) && e !== L;
|
|
59
|
+
function ue() {
|
|
60
|
+
const { caseless: e } = rt(this) && this || {}, t = {}, n = (r, s) => {
|
|
61
|
+
const o = e && nt(t, s) || s;
|
|
62
|
+
Q(t[o]) && Q(r) ? t[o] = ue(t[o], r) : Q(r) ? t[o] = ue({}, r) : v(r) ? t[o] = r.slice() : t[o] = r;
|
|
63
63
|
};
|
|
64
64
|
for (let r = 0, s = arguments.length; r < s; r++)
|
|
65
|
-
arguments[r] &&
|
|
65
|
+
arguments[r] && J(arguments[r], n);
|
|
66
66
|
return t;
|
|
67
67
|
}
|
|
68
|
-
const
|
|
69
|
-
n &&
|
|
70
|
-
}, { allOwnKeys: r }), e),
|
|
68
|
+
const en = (e, t, n, { allOwnKeys: r } = {}) => (J(t, (s, o) => {
|
|
69
|
+
n && _(s) ? e[o] = Ye(s, n) : e[o] = s;
|
|
70
|
+
}, { allOwnKeys: r }), e), tn = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), nn = (e, t, n, r) => {
|
|
71
71
|
e.prototype = Object.create(t.prototype, r), e.prototype.constructor = e, Object.defineProperty(e, "super", {
|
|
72
72
|
value: t.prototype
|
|
73
73
|
}), n && Object.assign(e.prototype, n);
|
|
74
|
-
},
|
|
74
|
+
}, rn = (e, t, n, r) => {
|
|
75
75
|
let s, o, i;
|
|
76
76
|
const c = {};
|
|
77
77
|
if (t = t || {}, e == null) return t;
|
|
78
78
|
do {
|
|
79
79
|
for (s = Object.getOwnPropertyNames(e), o = s.length; o-- > 0; )
|
|
80
80
|
i = s[o], (!r || r(i, e, t)) && !c[i] && (t[i] = e[i], c[i] = !0);
|
|
81
|
-
e = n !== !1 &&
|
|
81
|
+
e = n !== !1 && Ee(e);
|
|
82
82
|
} while (e && (!n || n(e, t)) && e !== Object.prototype);
|
|
83
83
|
return t;
|
|
84
|
-
},
|
|
84
|
+
}, sn = (e, t, n) => {
|
|
85
85
|
e = String(e), (n === void 0 || n > e.length) && (n = e.length), n -= t.length;
|
|
86
86
|
const r = e.indexOf(t, n);
|
|
87
87
|
return r !== -1 && r === n;
|
|
88
|
-
},
|
|
88
|
+
}, on = (e) => {
|
|
89
89
|
if (!e) return null;
|
|
90
|
-
if (
|
|
90
|
+
if (v(e)) return e;
|
|
91
91
|
let t = e.length;
|
|
92
|
-
if (!
|
|
92
|
+
if (!tt(t)) return null;
|
|
93
93
|
const n = new Array(t);
|
|
94
94
|
for (; t-- > 0; )
|
|
95
95
|
n[t] = e[t];
|
|
96
96
|
return n;
|
|
97
|
-
},
|
|
97
|
+
}, an = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && Ee(Uint8Array)), cn = (e, t) => {
|
|
98
98
|
const r = (e && e[Symbol.iterator]).call(e);
|
|
99
99
|
let s;
|
|
100
100
|
for (; (s = r.next()) && !s.done; ) {
|
|
101
101
|
const o = s.value;
|
|
102
102
|
t.call(e, o[0], o[1]);
|
|
103
103
|
}
|
|
104
|
-
},
|
|
104
|
+
}, un = (e, t) => {
|
|
105
105
|
let n;
|
|
106
106
|
const r = [];
|
|
107
107
|
for (; (n = e.exec(t)) !== null; )
|
|
108
108
|
r.push(n);
|
|
109
109
|
return r;
|
|
110
|
-
},
|
|
110
|
+
}, ln = x("HTMLFormElement"), fn = (e) => e.toLowerCase().replace(
|
|
111
111
|
/[-_\s]([a-z\d])(\w*)/g,
|
|
112
112
|
function(n, r, s) {
|
|
113
113
|
return r.toUpperCase() + s;
|
|
114
114
|
}
|
|
115
|
-
),
|
|
115
|
+
), Pe = (({ hasOwnProperty: e }) => (t, n) => e.call(t, n))(Object.prototype), dn = x("RegExp"), st = (e, t) => {
|
|
116
116
|
const n = Object.getOwnPropertyDescriptors(e), r = {};
|
|
117
|
-
|
|
117
|
+
J(n, (s, o) => {
|
|
118
118
|
let i;
|
|
119
119
|
(i = t(s, o, e)) !== !1 && (r[o] = i || s);
|
|
120
120
|
}), Object.defineProperties(e, r);
|
|
121
|
-
},
|
|
122
|
-
|
|
123
|
-
if (
|
|
121
|
+
}, pn = (e) => {
|
|
122
|
+
st(e, (t, n) => {
|
|
123
|
+
if (_(e) && ["arguments", "caller", "callee"].indexOf(n) !== -1)
|
|
124
124
|
return !1;
|
|
125
125
|
const r = e[n];
|
|
126
|
-
if (
|
|
126
|
+
if (_(r)) {
|
|
127
127
|
if (t.enumerable = !1, "writable" in t) {
|
|
128
128
|
t.writable = !1;
|
|
129
129
|
return;
|
|
@@ -133,103 +133,116 @@ const Ut = (e, t, n, { allOwnKeys: r } = {}) => (v(t, (s, o) => {
|
|
|
133
133
|
});
|
|
134
134
|
}
|
|
135
135
|
});
|
|
136
|
-
},
|
|
136
|
+
}, hn = (e, t) => {
|
|
137
137
|
const n = {}, r = (s) => {
|
|
138
138
|
s.forEach((o) => {
|
|
139
139
|
n[o] = !0;
|
|
140
140
|
});
|
|
141
141
|
};
|
|
142
|
-
return
|
|
143
|
-
},
|
|
144
|
-
},
|
|
145
|
-
DIGIT:
|
|
146
|
-
ALPHA:
|
|
147
|
-
ALPHA_DIGIT:
|
|
148
|
-
},
|
|
142
|
+
return v(e) ? r(e) : r(String(e).split(t)), n;
|
|
143
|
+
}, mn = () => {
|
|
144
|
+
}, yn = (e, t) => e != null && Number.isFinite(e = +e) ? e : t, oe = "abcdefghijklmnopqrstuvwxyz", ke = "0123456789", ot = {
|
|
145
|
+
DIGIT: ke,
|
|
146
|
+
ALPHA: oe,
|
|
147
|
+
ALPHA_DIGIT: oe + oe.toUpperCase() + ke
|
|
148
|
+
}, wn = (e = 16, t = ot.ALPHA_DIGIT) => {
|
|
149
149
|
let n = "";
|
|
150
150
|
const { length: r } = t;
|
|
151
151
|
for (; e--; )
|
|
152
152
|
n += t[Math.random() * r | 0];
|
|
153
153
|
return n;
|
|
154
154
|
};
|
|
155
|
-
function
|
|
156
|
-
return !!(e &&
|
|
155
|
+
function gn(e) {
|
|
156
|
+
return !!(e && _(e.append) && e[Symbol.toStringTag] === "FormData" && e[Symbol.iterator]);
|
|
157
157
|
}
|
|
158
|
-
const
|
|
158
|
+
const bn = (e) => {
|
|
159
159
|
const t = new Array(10), n = (r, s) => {
|
|
160
|
-
if (
|
|
160
|
+
if (ne(r)) {
|
|
161
161
|
if (t.indexOf(r) >= 0)
|
|
162
162
|
return;
|
|
163
163
|
if (!("toJSON" in r)) {
|
|
164
164
|
t[s] = r;
|
|
165
|
-
const o =
|
|
166
|
-
return
|
|
165
|
+
const o = v(r) ? [] : {};
|
|
166
|
+
return J(r, (i, c) => {
|
|
167
167
|
const f = n(i, s + 1);
|
|
168
|
-
!
|
|
168
|
+
!H(f) && (o[c] = f);
|
|
169
169
|
}), t[s] = void 0, o;
|
|
170
170
|
}
|
|
171
171
|
}
|
|
172
172
|
return r;
|
|
173
173
|
};
|
|
174
174
|
return n(e, 0);
|
|
175
|
-
},
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
175
|
+
}, En = x("AsyncFunction"), Sn = (e) => e && (ne(e) || _(e)) && _(e.then) && _(e.catch), it = ((e, t) => e ? setImmediate : t ? ((n, r) => (L.addEventListener("message", ({ source: s, data: o }) => {
|
|
176
|
+
s === L && o === n && r.length && r.shift()();
|
|
177
|
+
}, !1), (s) => {
|
|
178
|
+
r.push(s), L.postMessage(n, "*");
|
|
179
|
+
}))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
|
|
180
|
+
typeof setImmediate == "function",
|
|
181
|
+
_(L.postMessage)
|
|
182
|
+
), Rn = typeof queueMicrotask < "u" ? queueMicrotask.bind(L) : typeof process < "u" && process.nextTick || it, a = {
|
|
183
|
+
isArray: v,
|
|
184
|
+
isArrayBuffer: et,
|
|
185
|
+
isBuffer: It,
|
|
186
|
+
isFormData: Wt,
|
|
187
|
+
isArrayBufferView: jt,
|
|
188
|
+
isString: qt,
|
|
189
|
+
isNumber: tt,
|
|
190
|
+
isBoolean: Mt,
|
|
191
|
+
isObject: ne,
|
|
192
|
+
isPlainObject: Q,
|
|
193
|
+
isReadableStream: Qt,
|
|
194
|
+
isRequest: Gt,
|
|
195
|
+
isResponse: Xt,
|
|
196
|
+
isHeaders: Zt,
|
|
197
|
+
isUndefined: H,
|
|
198
|
+
isDate: Ht,
|
|
199
|
+
isFile: zt,
|
|
200
|
+
isBlob: $t,
|
|
201
|
+
isRegExp: dn,
|
|
202
|
+
isFunction: _,
|
|
203
|
+
isStream: Vt,
|
|
204
|
+
isURLSearchParams: Kt,
|
|
205
|
+
isTypedArray: an,
|
|
206
|
+
isFileList: Jt,
|
|
207
|
+
forEach: J,
|
|
208
|
+
merge: ue,
|
|
209
|
+
extend: en,
|
|
210
|
+
trim: Yt,
|
|
211
|
+
stripBOM: tn,
|
|
212
|
+
inherits: nn,
|
|
213
|
+
toFlatObject: rn,
|
|
214
|
+
kindOf: ee,
|
|
215
|
+
kindOfTest: x,
|
|
216
|
+
endsWith: sn,
|
|
217
|
+
toArray: on,
|
|
218
|
+
forEachEntry: cn,
|
|
219
|
+
matchAll: un,
|
|
220
|
+
isHTMLForm: ln,
|
|
221
|
+
hasOwnProperty: Pe,
|
|
222
|
+
hasOwnProp: Pe,
|
|
212
223
|
// an alias to avoid ESLint no-prototype-builtins detection
|
|
213
|
-
reduceDescriptors:
|
|
214
|
-
freezeMethods:
|
|
215
|
-
toObjectSet:
|
|
216
|
-
toCamelCase:
|
|
217
|
-
noop:
|
|
218
|
-
toFiniteNumber:
|
|
219
|
-
findKey:
|
|
220
|
-
global:
|
|
221
|
-
isContextDefined:
|
|
222
|
-
ALPHABET:
|
|
223
|
-
generateString:
|
|
224
|
-
isSpecCompliantForm:
|
|
225
|
-
toJSONObject:
|
|
226
|
-
isAsyncFn:
|
|
227
|
-
isThenable:
|
|
224
|
+
reduceDescriptors: st,
|
|
225
|
+
freezeMethods: pn,
|
|
226
|
+
toObjectSet: hn,
|
|
227
|
+
toCamelCase: fn,
|
|
228
|
+
noop: mn,
|
|
229
|
+
toFiniteNumber: yn,
|
|
230
|
+
findKey: nt,
|
|
231
|
+
global: L,
|
|
232
|
+
isContextDefined: rt,
|
|
233
|
+
ALPHABET: ot,
|
|
234
|
+
generateString: wn,
|
|
235
|
+
isSpecCompliantForm: gn,
|
|
236
|
+
toJSONObject: bn,
|
|
237
|
+
isAsyncFn: En,
|
|
238
|
+
isThenable: Sn,
|
|
239
|
+
setImmediate: it,
|
|
240
|
+
asap: Rn
|
|
228
241
|
};
|
|
229
|
-
function
|
|
230
|
-
Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), s && (this.response = s);
|
|
242
|
+
function y(e, t, n, r, s) {
|
|
243
|
+
Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = e, this.name = "AxiosError", t && (this.code = t), n && (this.config = n), r && (this.request = r), s && (this.response = s, this.status = s.status ? s.status : null);
|
|
231
244
|
}
|
|
232
|
-
a.inherits(
|
|
245
|
+
a.inherits(y, Error, {
|
|
233
246
|
toJSON: function() {
|
|
234
247
|
return {
|
|
235
248
|
// Standard
|
|
@@ -246,11 +259,11 @@ a.inherits(m, Error, {
|
|
|
246
259
|
// Axios
|
|
247
260
|
config: a.toJSONObject(this.config),
|
|
248
261
|
code: this.code,
|
|
249
|
-
status: this.
|
|
262
|
+
status: this.status
|
|
250
263
|
};
|
|
251
264
|
}
|
|
252
265
|
});
|
|
253
|
-
const
|
|
266
|
+
const at = y.prototype, ct = {};
|
|
254
267
|
[
|
|
255
268
|
"ERR_BAD_OPTION_VALUE",
|
|
256
269
|
"ERR_BAD_OPTION",
|
|
@@ -266,96 +279,96 @@ const Je = m.prototype, Ve = {};
|
|
|
266
279
|
"ERR_INVALID_URL"
|
|
267
280
|
// eslint-disable-next-line func-names
|
|
268
281
|
].forEach((e) => {
|
|
269
|
-
|
|
282
|
+
ct[e] = { value: e };
|
|
270
283
|
});
|
|
271
|
-
Object.defineProperties(
|
|
272
|
-
Object.defineProperty(
|
|
273
|
-
|
|
274
|
-
const i = Object.create(
|
|
284
|
+
Object.defineProperties(y, ct);
|
|
285
|
+
Object.defineProperty(at, "isAxiosError", { value: !0 });
|
|
286
|
+
y.from = (e, t, n, r, s, o) => {
|
|
287
|
+
const i = Object.create(at);
|
|
275
288
|
return a.toFlatObject(e, i, function(f) {
|
|
276
289
|
return f !== Error.prototype;
|
|
277
|
-
}, (c) => c !== "isAxiosError"),
|
|
290
|
+
}, (c) => c !== "isAxiosError"), y.call(i, e.message, t, n, r, s), i.cause = e, i.name = e.name, o && Object.assign(i, o), i;
|
|
278
291
|
};
|
|
279
|
-
const
|
|
280
|
-
function
|
|
292
|
+
const Tn = null;
|
|
293
|
+
function le(e) {
|
|
281
294
|
return a.isPlainObject(e) || a.isArray(e);
|
|
282
295
|
}
|
|
283
|
-
function
|
|
296
|
+
function ut(e) {
|
|
284
297
|
return a.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
285
298
|
}
|
|
286
|
-
function
|
|
299
|
+
function Ce(e, t, n) {
|
|
287
300
|
return e ? e.concat(t).map(function(s, o) {
|
|
288
|
-
return s =
|
|
301
|
+
return s = ut(s), !n && o ? "[" + s + "]" : s;
|
|
289
302
|
}).join(n ? "." : "") : t;
|
|
290
303
|
}
|
|
291
|
-
function
|
|
292
|
-
return a.isArray(e) && !e.some(
|
|
304
|
+
function On(e) {
|
|
305
|
+
return a.isArray(e) && !e.some(le);
|
|
293
306
|
}
|
|
294
|
-
const
|
|
307
|
+
const An = a.toFlatObject(a, {}, null, function(t) {
|
|
295
308
|
return /^is[A-Z]/.test(t);
|
|
296
309
|
});
|
|
297
|
-
function
|
|
310
|
+
function re(e, t, n) {
|
|
298
311
|
if (!a.isObject(e))
|
|
299
312
|
throw new TypeError("target must be an object");
|
|
300
313
|
t = t || new FormData(), n = a.toFlatObject(n, {
|
|
301
314
|
metaTokens: !0,
|
|
302
315
|
dots: !1,
|
|
303
316
|
indexes: !1
|
|
304
|
-
}, !1, function(
|
|
305
|
-
return !a.isUndefined(
|
|
317
|
+
}, !1, function(m, h) {
|
|
318
|
+
return !a.isUndefined(h[m]);
|
|
306
319
|
});
|
|
307
|
-
const r = n.metaTokens, s = n.visitor ||
|
|
320
|
+
const r = n.metaTokens, s = n.visitor || u, o = n.dots, i = n.indexes, f = (n.Blob || typeof Blob < "u" && Blob) && a.isSpecCompliantForm(t);
|
|
308
321
|
if (!a.isFunction(s))
|
|
309
322
|
throw new TypeError("visitor must be a function");
|
|
310
|
-
function
|
|
323
|
+
function l(p) {
|
|
311
324
|
if (p === null) return "";
|
|
312
325
|
if (a.isDate(p))
|
|
313
326
|
return p.toISOString();
|
|
314
327
|
if (!f && a.isBlob(p))
|
|
315
|
-
throw new
|
|
328
|
+
throw new y("Blob is not supported. Use a Buffer instead.");
|
|
316
329
|
return a.isArrayBuffer(p) || a.isTypedArray(p) ? f && typeof Blob == "function" ? new Blob([p]) : Buffer.from(p) : p;
|
|
317
330
|
}
|
|
318
|
-
function
|
|
319
|
-
let
|
|
320
|
-
if (p && !
|
|
321
|
-
if (a.endsWith(
|
|
322
|
-
|
|
323
|
-
else if (a.isArray(p) &&
|
|
324
|
-
return
|
|
325
|
-
!(a.isUndefined(
|
|
331
|
+
function u(p, m, h) {
|
|
332
|
+
let b = p;
|
|
333
|
+
if (p && !h && typeof p == "object") {
|
|
334
|
+
if (a.endsWith(m, "{}"))
|
|
335
|
+
m = r ? m : m.slice(0, -2), p = JSON.stringify(p);
|
|
336
|
+
else if (a.isArray(p) && On(p) || (a.isFileList(p) || a.endsWith(m, "[]")) && (b = a.toArray(p)))
|
|
337
|
+
return m = ut(m), b.forEach(function(R, P) {
|
|
338
|
+
!(a.isUndefined(R) || R === null) && t.append(
|
|
326
339
|
// eslint-disable-next-line no-nested-ternary
|
|
327
|
-
i === !0 ?
|
|
328
|
-
|
|
340
|
+
i === !0 ? Ce([m], P, o) : i === null ? m : m + "[]",
|
|
341
|
+
l(R)
|
|
329
342
|
);
|
|
330
343
|
}), !1;
|
|
331
344
|
}
|
|
332
|
-
return
|
|
345
|
+
return le(p) ? !0 : (t.append(Ce(h, m, o), l(p)), !1);
|
|
333
346
|
}
|
|
334
|
-
const
|
|
335
|
-
defaultVisitor:
|
|
336
|
-
convertValue:
|
|
337
|
-
isVisitable:
|
|
347
|
+
const d = [], w = Object.assign(An, {
|
|
348
|
+
defaultVisitor: u,
|
|
349
|
+
convertValue: l,
|
|
350
|
+
isVisitable: le
|
|
338
351
|
});
|
|
339
|
-
function
|
|
352
|
+
function g(p, m) {
|
|
340
353
|
if (!a.isUndefined(p)) {
|
|
341
|
-
if (
|
|
342
|
-
throw Error("Circular reference detected in " +
|
|
343
|
-
|
|
344
|
-
(!(a.isUndefined(
|
|
354
|
+
if (d.indexOf(p) !== -1)
|
|
355
|
+
throw Error("Circular reference detected in " + m.join("."));
|
|
356
|
+
d.push(p), a.forEach(p, function(b, S) {
|
|
357
|
+
(!(a.isUndefined(b) || b === null) && s.call(
|
|
345
358
|
t,
|
|
346
|
-
|
|
347
|
-
a.isString(
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
)) === !0 &&
|
|
351
|
-
}),
|
|
359
|
+
b,
|
|
360
|
+
a.isString(S) ? S.trim() : S,
|
|
361
|
+
m,
|
|
362
|
+
w
|
|
363
|
+
)) === !0 && g(b, m ? m.concat(S) : [S]);
|
|
364
|
+
}), d.pop();
|
|
352
365
|
}
|
|
353
366
|
}
|
|
354
367
|
if (!a.isObject(e))
|
|
355
368
|
throw new TypeError("data must be an object");
|
|
356
|
-
return
|
|
369
|
+
return g(e), t;
|
|
357
370
|
}
|
|
358
|
-
function
|
|
371
|
+
function Ne(e) {
|
|
359
372
|
const t = {
|
|
360
373
|
"!": "%21",
|
|
361
374
|
"'": "%27",
|
|
@@ -369,36 +382,36 @@ function Ee(e) {
|
|
|
369
382
|
return t[r];
|
|
370
383
|
});
|
|
371
384
|
}
|
|
372
|
-
function
|
|
373
|
-
this._pairs = [], e &&
|
|
385
|
+
function Se(e, t) {
|
|
386
|
+
this._pairs = [], e && re(e, this, t);
|
|
374
387
|
}
|
|
375
|
-
const
|
|
376
|
-
|
|
388
|
+
const lt = Se.prototype;
|
|
389
|
+
lt.append = function(t, n) {
|
|
377
390
|
this._pairs.push([t, n]);
|
|
378
391
|
};
|
|
379
|
-
|
|
392
|
+
lt.toString = function(t) {
|
|
380
393
|
const n = t ? function(r) {
|
|
381
|
-
return t.call(this, r,
|
|
382
|
-
} :
|
|
394
|
+
return t.call(this, r, Ne);
|
|
395
|
+
} : Ne;
|
|
383
396
|
return this._pairs.map(function(s) {
|
|
384
397
|
return n(s[0]) + "=" + n(s[1]);
|
|
385
398
|
}, "").join("&");
|
|
386
399
|
};
|
|
387
|
-
function
|
|
400
|
+
function _n(e) {
|
|
388
401
|
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
|
|
389
402
|
}
|
|
390
|
-
function
|
|
403
|
+
function ft(e, t, n) {
|
|
391
404
|
if (!t)
|
|
392
405
|
return e;
|
|
393
|
-
const r = n && n.encode ||
|
|
406
|
+
const r = n && n.encode || _n, s = n && n.serialize;
|
|
394
407
|
let o;
|
|
395
|
-
if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new
|
|
408
|
+
if (s ? o = s(t, n) : o = a.isURLSearchParams(t) ? t.toString() : new Se(t, n).toString(r), o) {
|
|
396
409
|
const i = e.indexOf("#");
|
|
397
410
|
i !== -1 && (e = e.slice(0, i)), e += (e.indexOf("?") === -1 ? "?" : "&") + o;
|
|
398
411
|
}
|
|
399
412
|
return e;
|
|
400
413
|
}
|
|
401
|
-
class
|
|
414
|
+
class Le {
|
|
402
415
|
constructor() {
|
|
403
416
|
this.handlers = [];
|
|
404
417
|
}
|
|
@@ -452,39 +465,41 @@ class be {
|
|
|
452
465
|
});
|
|
453
466
|
}
|
|
454
467
|
}
|
|
455
|
-
const
|
|
468
|
+
const dt = {
|
|
456
469
|
silentJSONParsing: !0,
|
|
457
470
|
forcedJSONParsing: !0,
|
|
458
471
|
clarifyTimeoutError: !1
|
|
459
|
-
},
|
|
472
|
+
}, xn = typeof URLSearchParams < "u" ? URLSearchParams : Se, Pn = typeof FormData < "u" ? FormData : null, kn = typeof Blob < "u" ? Blob : null, Cn = {
|
|
460
473
|
isBrowser: !0,
|
|
461
474
|
classes: {
|
|
462
|
-
URLSearchParams:
|
|
463
|
-
FormData:
|
|
464
|
-
Blob:
|
|
475
|
+
URLSearchParams: xn,
|
|
476
|
+
FormData: Pn,
|
|
477
|
+
Blob: kn
|
|
465
478
|
},
|
|
466
479
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
467
|
-
},
|
|
468
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function",
|
|
480
|
+
}, Re = typeof window < "u" && typeof document < "u", fe = typeof navigator == "object" && navigator || void 0, Nn = Re && (!fe || ["ReactNative", "NativeScript", "NS"].indexOf(fe.product) < 0), Ln = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
481
|
+
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Un = Re && window.location.href || "http://localhost", Dn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
469
482
|
__proto__: null,
|
|
470
|
-
hasBrowserEnv:
|
|
471
|
-
hasStandardBrowserEnv:
|
|
472
|
-
hasStandardBrowserWebWorkerEnv:
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
483
|
+
hasBrowserEnv: Re,
|
|
484
|
+
hasStandardBrowserEnv: Nn,
|
|
485
|
+
hasStandardBrowserWebWorkerEnv: Ln,
|
|
486
|
+
navigator: fe,
|
|
487
|
+
origin: Un
|
|
488
|
+
}, Symbol.toStringTag, { value: "Module" })), O = {
|
|
489
|
+
...Dn,
|
|
490
|
+
...Cn
|
|
476
491
|
};
|
|
477
|
-
function
|
|
478
|
-
return
|
|
492
|
+
function Fn(e, t) {
|
|
493
|
+
return re(e, new O.classes.URLSearchParams(), Object.assign({
|
|
479
494
|
visitor: function(n, r, s, o) {
|
|
480
|
-
return
|
|
495
|
+
return O.isNode && a.isBuffer(n) ? (this.append(r, n.toString("base64")), !1) : o.defaultVisitor.apply(this, arguments);
|
|
481
496
|
}
|
|
482
497
|
}, t));
|
|
483
498
|
}
|
|
484
|
-
function
|
|
499
|
+
function Bn(e) {
|
|
485
500
|
return a.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
|
|
486
501
|
}
|
|
487
|
-
function
|
|
502
|
+
function vn(e) {
|
|
488
503
|
const t = {}, n = Object.keys(e);
|
|
489
504
|
let r;
|
|
490
505
|
const s = n.length;
|
|
@@ -493,22 +508,22 @@ function pn(e) {
|
|
|
493
508
|
o = n[r], t[o] = e[o];
|
|
494
509
|
return t;
|
|
495
510
|
}
|
|
496
|
-
function
|
|
511
|
+
function pt(e) {
|
|
497
512
|
function t(n, r, s, o) {
|
|
498
513
|
let i = n[o++];
|
|
499
514
|
if (i === "__proto__") return !0;
|
|
500
515
|
const c = Number.isFinite(+i), f = o >= n.length;
|
|
501
|
-
return i = !i && a.isArray(s) ? s.length : i, f ? (a.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !c) : ((!s[i] || !a.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && a.isArray(s[i]) && (s[i] =
|
|
516
|
+
return i = !i && a.isArray(s) ? s.length : i, f ? (a.hasOwnProp(s, i) ? s[i] = [s[i], r] : s[i] = r, !c) : ((!s[i] || !a.isObject(s[i])) && (s[i] = []), t(n, r, s[i], o) && a.isArray(s[i]) && (s[i] = vn(s[i])), !c);
|
|
502
517
|
}
|
|
503
518
|
if (a.isFormData(e) && a.isFunction(e.entries)) {
|
|
504
519
|
const n = {};
|
|
505
520
|
return a.forEachEntry(e, (r, s) => {
|
|
506
|
-
t(
|
|
521
|
+
t(Bn(r), s, n, 0);
|
|
507
522
|
}), n;
|
|
508
523
|
}
|
|
509
524
|
return null;
|
|
510
525
|
}
|
|
511
|
-
function
|
|
526
|
+
function In(e, t, n) {
|
|
512
527
|
if (a.isString(e))
|
|
513
528
|
try {
|
|
514
529
|
return (t || JSON.parse)(e), a.trim(e);
|
|
@@ -516,16 +531,16 @@ function hn(e, t, n) {
|
|
|
516
531
|
if (r.name !== "SyntaxError")
|
|
517
532
|
throw r;
|
|
518
533
|
}
|
|
519
|
-
return (
|
|
534
|
+
return (0, JSON.stringify)(e);
|
|
520
535
|
}
|
|
521
|
-
const
|
|
522
|
-
transitional:
|
|
523
|
-
adapter: ["xhr", "http"],
|
|
536
|
+
const V = {
|
|
537
|
+
transitional: dt,
|
|
538
|
+
adapter: ["xhr", "http", "fetch"],
|
|
524
539
|
transformRequest: [function(t, n) {
|
|
525
540
|
const r = n.getContentType() || "", s = r.indexOf("application/json") > -1, o = a.isObject(t);
|
|
526
541
|
if (o && a.isHTMLForm(t) && (t = new FormData(t)), a.isFormData(t))
|
|
527
|
-
return s ? JSON.stringify(
|
|
528
|
-
if (a.isArrayBuffer(t) || a.isBuffer(t) || a.isStream(t) || a.isFile(t) || a.isBlob(t))
|
|
542
|
+
return s ? JSON.stringify(pt(t)) : t;
|
|
543
|
+
if (a.isArrayBuffer(t) || a.isBuffer(t) || a.isStream(t) || a.isFile(t) || a.isBlob(t) || a.isReadableStream(t))
|
|
529
544
|
return t;
|
|
530
545
|
if (a.isArrayBufferView(t))
|
|
531
546
|
return t.buffer;
|
|
@@ -534,27 +549,29 @@ const H = {
|
|
|
534
549
|
let c;
|
|
535
550
|
if (o) {
|
|
536
551
|
if (r.indexOf("application/x-www-form-urlencoded") > -1)
|
|
537
|
-
return
|
|
552
|
+
return Fn(t, this.formSerializer).toString();
|
|
538
553
|
if ((c = a.isFileList(t)) || r.indexOf("multipart/form-data") > -1) {
|
|
539
554
|
const f = this.env && this.env.FormData;
|
|
540
|
-
return
|
|
555
|
+
return re(
|
|
541
556
|
c ? { "files[]": t } : t,
|
|
542
557
|
f && new f(),
|
|
543
558
|
this.formSerializer
|
|
544
559
|
);
|
|
545
560
|
}
|
|
546
561
|
}
|
|
547
|
-
return o || s ? (n.setContentType("application/json", !1),
|
|
562
|
+
return o || s ? (n.setContentType("application/json", !1), In(t)) : t;
|
|
548
563
|
}],
|
|
549
564
|
transformResponse: [function(t) {
|
|
550
|
-
const n = this.transitional ||
|
|
565
|
+
const n = this.transitional || V.transitional, r = n && n.forcedJSONParsing, s = this.responseType === "json";
|
|
566
|
+
if (a.isResponse(t) || a.isReadableStream(t))
|
|
567
|
+
return t;
|
|
551
568
|
if (t && a.isString(t) && (r && !this.responseType || s)) {
|
|
552
569
|
const i = !(n && n.silentJSONParsing) && s;
|
|
553
570
|
try {
|
|
554
571
|
return JSON.parse(t);
|
|
555
572
|
} catch (c) {
|
|
556
573
|
if (i)
|
|
557
|
-
throw c.name === "SyntaxError" ?
|
|
574
|
+
throw c.name === "SyntaxError" ? y.from(c, y.ERR_BAD_RESPONSE, this, null, this.response) : c;
|
|
558
575
|
}
|
|
559
576
|
}
|
|
560
577
|
return t;
|
|
@@ -569,8 +586,8 @@ const H = {
|
|
|
569
586
|
maxContentLength: -1,
|
|
570
587
|
maxBodyLength: -1,
|
|
571
588
|
env: {
|
|
572
|
-
FormData:
|
|
573
|
-
Blob:
|
|
589
|
+
FormData: O.classes.FormData,
|
|
590
|
+
Blob: O.classes.Blob
|
|
574
591
|
},
|
|
575
592
|
validateStatus: function(t) {
|
|
576
593
|
return t >= 200 && t < 300;
|
|
@@ -583,9 +600,9 @@ const H = {
|
|
|
583
600
|
}
|
|
584
601
|
};
|
|
585
602
|
a.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
586
|
-
|
|
603
|
+
V.headers[e] = {};
|
|
587
604
|
});
|
|
588
|
-
const
|
|
605
|
+
const jn = a.toObjectSet([
|
|
589
606
|
"age",
|
|
590
607
|
"authorization",
|
|
591
608
|
"content-length",
|
|
@@ -603,29 +620,29 @@ const mn = a.toObjectSet([
|
|
|
603
620
|
"referer",
|
|
604
621
|
"retry-after",
|
|
605
622
|
"user-agent"
|
|
606
|
-
]),
|
|
623
|
+
]), qn = (e) => {
|
|
607
624
|
const t = {};
|
|
608
625
|
let n, r, s;
|
|
609
626
|
return e && e.split(`
|
|
610
627
|
`).forEach(function(i) {
|
|
611
|
-
s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] &&
|
|
628
|
+
s = i.indexOf(":"), n = i.substring(0, s).trim().toLowerCase(), r = i.substring(s + 1).trim(), !(!n || t[n] && jn[n]) && (n === "set-cookie" ? t[n] ? t[n].push(r) : t[n] = [r] : t[n] = t[n] ? t[n] + ", " + r : r);
|
|
612
629
|
}), t;
|
|
613
|
-
},
|
|
614
|
-
function
|
|
630
|
+
}, Ue = Symbol("internals");
|
|
631
|
+
function j(e) {
|
|
615
632
|
return e && String(e).trim().toLowerCase();
|
|
616
633
|
}
|
|
617
|
-
function
|
|
618
|
-
return e === !1 || e == null ? e : a.isArray(e) ? e.map(
|
|
634
|
+
function G(e) {
|
|
635
|
+
return e === !1 || e == null ? e : a.isArray(e) ? e.map(G) : String(e);
|
|
619
636
|
}
|
|
620
|
-
function
|
|
637
|
+
function Mn(e) {
|
|
621
638
|
const t = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
622
639
|
let r;
|
|
623
640
|
for (; r = n.exec(e); )
|
|
624
641
|
t[r[1]] = r[2];
|
|
625
642
|
return t;
|
|
626
643
|
}
|
|
627
|
-
const
|
|
628
|
-
function
|
|
644
|
+
const Hn = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
645
|
+
function ie(e, t, n, r, s) {
|
|
629
646
|
if (a.isFunction(r))
|
|
630
647
|
return r.call(this, t, n);
|
|
631
648
|
if (s && (t = n), !!a.isString(t)) {
|
|
@@ -635,10 +652,10 @@ function X(e, t, n, r, s) {
|
|
|
635
652
|
return r.test(t);
|
|
636
653
|
}
|
|
637
654
|
}
|
|
638
|
-
function
|
|
655
|
+
function zn(e) {
|
|
639
656
|
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, n, r) => n.toUpperCase() + r);
|
|
640
657
|
}
|
|
641
|
-
function
|
|
658
|
+
function $n(e, t) {
|
|
642
659
|
const n = a.toCamelCase(" " + t);
|
|
643
660
|
["get", "set", "has"].forEach((r) => {
|
|
644
661
|
Object.defineProperty(e, r + n, {
|
|
@@ -649,31 +666,40 @@ function Sn(e, t) {
|
|
|
649
666
|
});
|
|
650
667
|
});
|
|
651
668
|
}
|
|
652
|
-
class
|
|
669
|
+
class A {
|
|
653
670
|
constructor(t) {
|
|
654
671
|
t && this.set(t);
|
|
655
672
|
}
|
|
656
673
|
set(t, n, r) {
|
|
657
674
|
const s = this;
|
|
658
|
-
function o(c, f,
|
|
659
|
-
const
|
|
660
|
-
if (!
|
|
675
|
+
function o(c, f, l) {
|
|
676
|
+
const u = j(f);
|
|
677
|
+
if (!u)
|
|
661
678
|
throw new Error("header name must be a non-empty string");
|
|
662
|
-
const
|
|
663
|
-
(!
|
|
679
|
+
const d = a.findKey(s, u);
|
|
680
|
+
(!d || s[d] === void 0 || l === !0 || l === void 0 && s[d] !== !1) && (s[d || f] = G(c));
|
|
664
681
|
}
|
|
665
|
-
const i = (c, f) => a.forEach(c, (
|
|
666
|
-
|
|
682
|
+
const i = (c, f) => a.forEach(c, (l, u) => o(l, u, f));
|
|
683
|
+
if (a.isPlainObject(t) || t instanceof this.constructor)
|
|
684
|
+
i(t, n);
|
|
685
|
+
else if (a.isString(t) && (t = t.trim()) && !Hn(t))
|
|
686
|
+
i(qn(t), n);
|
|
687
|
+
else if (a.isHeaders(t))
|
|
688
|
+
for (const [c, f] of t.entries())
|
|
689
|
+
o(f, c, r);
|
|
690
|
+
else
|
|
691
|
+
t != null && o(n, t, r);
|
|
692
|
+
return this;
|
|
667
693
|
}
|
|
668
694
|
get(t, n) {
|
|
669
|
-
if (t =
|
|
695
|
+
if (t = j(t), t) {
|
|
670
696
|
const r = a.findKey(this, t);
|
|
671
697
|
if (r) {
|
|
672
698
|
const s = this[r];
|
|
673
699
|
if (!n)
|
|
674
700
|
return s;
|
|
675
701
|
if (n === !0)
|
|
676
|
-
return
|
|
702
|
+
return Mn(s);
|
|
677
703
|
if (a.isFunction(n))
|
|
678
704
|
return n.call(this, s, r);
|
|
679
705
|
if (a.isRegExp(n))
|
|
@@ -683,9 +709,9 @@ class O {
|
|
|
683
709
|
}
|
|
684
710
|
}
|
|
685
711
|
has(t, n) {
|
|
686
|
-
if (t =
|
|
712
|
+
if (t = j(t), t) {
|
|
687
713
|
const r = a.findKey(this, t);
|
|
688
|
-
return !!(r && this[r] !== void 0 && (!n ||
|
|
714
|
+
return !!(r && this[r] !== void 0 && (!n || ie(this, this[r], r, n)));
|
|
689
715
|
}
|
|
690
716
|
return !1;
|
|
691
717
|
}
|
|
@@ -693,9 +719,9 @@ class O {
|
|
|
693
719
|
const r = this;
|
|
694
720
|
let s = !1;
|
|
695
721
|
function o(i) {
|
|
696
|
-
if (i =
|
|
722
|
+
if (i = j(i), i) {
|
|
697
723
|
const c = a.findKey(r, i);
|
|
698
|
-
c && (!n ||
|
|
724
|
+
c && (!n || ie(r, r[c], c, n)) && (delete r[c], s = !0);
|
|
699
725
|
}
|
|
700
726
|
}
|
|
701
727
|
return a.isArray(t) ? t.forEach(o) : o(t), s;
|
|
@@ -705,7 +731,7 @@ class O {
|
|
|
705
731
|
let r = n.length, s = !1;
|
|
706
732
|
for (; r--; ) {
|
|
707
733
|
const o = n[r];
|
|
708
|
-
(!t ||
|
|
734
|
+
(!t || ie(this, this[o], o, t, !0)) && (delete this[o], s = !0);
|
|
709
735
|
}
|
|
710
736
|
return s;
|
|
711
737
|
}
|
|
@@ -714,11 +740,11 @@ class O {
|
|
|
714
740
|
return a.forEach(this, (s, o) => {
|
|
715
741
|
const i = a.findKey(r, o);
|
|
716
742
|
if (i) {
|
|
717
|
-
n[i] =
|
|
743
|
+
n[i] = G(s), delete n[o];
|
|
718
744
|
return;
|
|
719
745
|
}
|
|
720
|
-
const c = t ?
|
|
721
|
-
c !== o && delete n[o], n[c] =
|
|
746
|
+
const c = t ? zn(o) : String(o).trim();
|
|
747
|
+
c !== o && delete n[o], n[c] = G(s), r[c] = !0;
|
|
722
748
|
}), this;
|
|
723
749
|
}
|
|
724
750
|
concat(...t) {
|
|
@@ -748,18 +774,18 @@ class O {
|
|
|
748
774
|
return n.forEach((s) => r.set(s)), r;
|
|
749
775
|
}
|
|
750
776
|
static accessor(t) {
|
|
751
|
-
const r = (this[
|
|
777
|
+
const r = (this[Ue] = this[Ue] = {
|
|
752
778
|
accessors: {}
|
|
753
779
|
}).accessors, s = this.prototype;
|
|
754
780
|
function o(i) {
|
|
755
|
-
const c =
|
|
756
|
-
r[c] || (
|
|
781
|
+
const c = j(i);
|
|
782
|
+
r[c] || ($n(s, i), r[c] = !0);
|
|
757
783
|
}
|
|
758
784
|
return a.isArray(t) ? t.forEach(o) : o(t), this;
|
|
759
785
|
}
|
|
760
786
|
}
|
|
761
|
-
|
|
762
|
-
a.reduceDescriptors(
|
|
787
|
+
A.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
|
|
788
|
+
a.reduceDescriptors(A.prototype, ({ value: e }, t) => {
|
|
763
789
|
let n = t[0].toUpperCase() + t.slice(1);
|
|
764
790
|
return {
|
|
765
791
|
get: () => e,
|
|
@@ -768,74 +794,96 @@ a.reduceDescriptors(O.prototype, ({ value: e }, t) => {
|
|
|
768
794
|
}
|
|
769
795
|
};
|
|
770
796
|
});
|
|
771
|
-
a.freezeMethods(
|
|
772
|
-
function
|
|
773
|
-
const n = this ||
|
|
797
|
+
a.freezeMethods(A);
|
|
798
|
+
function ae(e, t) {
|
|
799
|
+
const n = this || V, r = t || n, s = A.from(r.headers);
|
|
774
800
|
let o = r.data;
|
|
775
801
|
return a.forEach(e, function(c) {
|
|
776
802
|
o = c.call(n, o, s.normalize(), t ? t.status : void 0);
|
|
777
803
|
}), s.normalize(), o;
|
|
778
804
|
}
|
|
779
|
-
function
|
|
805
|
+
function ht(e) {
|
|
780
806
|
return !!(e && e.__CANCEL__);
|
|
781
807
|
}
|
|
782
|
-
function
|
|
783
|
-
|
|
808
|
+
function I(e, t, n) {
|
|
809
|
+
y.call(this, e ?? "canceled", y.ERR_CANCELED, t, n), this.name = "CanceledError";
|
|
784
810
|
}
|
|
785
|
-
a.inherits(
|
|
811
|
+
a.inherits(I, y, {
|
|
786
812
|
__CANCEL__: !0
|
|
787
813
|
});
|
|
788
|
-
function
|
|
814
|
+
function mt(e, t, n) {
|
|
789
815
|
const r = n.config.validateStatus;
|
|
790
|
-
!n.status || !r || r(n.status) ? e(n) : t(new
|
|
816
|
+
!n.status || !r || r(n.status) ? e(n) : t(new y(
|
|
791
817
|
"Request failed with status code " + n.status,
|
|
792
|
-
[
|
|
818
|
+
[y.ERR_BAD_REQUEST, y.ERR_BAD_RESPONSE][Math.floor(n.status / 100) - 4],
|
|
793
819
|
n.config,
|
|
794
820
|
n.request,
|
|
795
821
|
n
|
|
796
822
|
));
|
|
797
823
|
}
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
write(e, t, n, r, s, o) {
|
|
802
|
-
const i = [e + "=" + encodeURIComponent(t)];
|
|
803
|
-
a.isNumber(n) && i.push("expires=" + new Date(n).toGMTString()), a.isString(r) && i.push("path=" + r), a.isString(s) && i.push("domain=" + s), o === !0 && i.push("secure"), document.cookie = i.join("; ");
|
|
804
|
-
},
|
|
805
|
-
read(e) {
|
|
806
|
-
const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
|
|
807
|
-
return t ? decodeURIComponent(t[3]) : null;
|
|
808
|
-
},
|
|
809
|
-
remove(e) {
|
|
810
|
-
this.write(e, "", Date.now() - 864e5);
|
|
811
|
-
}
|
|
812
|
-
}
|
|
813
|
-
) : (
|
|
814
|
-
// Non-standard browser env (web workers, react-native) lack needed support.
|
|
815
|
-
{
|
|
816
|
-
write() {
|
|
817
|
-
},
|
|
818
|
-
read() {
|
|
819
|
-
return null;
|
|
820
|
-
},
|
|
821
|
-
remove() {
|
|
822
|
-
}
|
|
823
|
-
}
|
|
824
|
-
);
|
|
825
|
-
function Tn(e) {
|
|
826
|
-
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
|
|
824
|
+
function Jn(e) {
|
|
825
|
+
const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
|
|
826
|
+
return t && t[1] || "";
|
|
827
827
|
}
|
|
828
|
-
function
|
|
829
|
-
|
|
828
|
+
function Vn(e, t) {
|
|
829
|
+
e = e || 10;
|
|
830
|
+
const n = new Array(e), r = new Array(e);
|
|
831
|
+
let s = 0, o = 0, i;
|
|
832
|
+
return t = t !== void 0 ? t : 1e3, function(f) {
|
|
833
|
+
const l = Date.now(), u = r[o];
|
|
834
|
+
i || (i = l), n[s] = f, r[s] = l;
|
|
835
|
+
let d = o, w = 0;
|
|
836
|
+
for (; d !== s; )
|
|
837
|
+
w += n[d++], d = d % e;
|
|
838
|
+
if (s = (s + 1) % e, s === o && (o = (o + 1) % e), l - i < t)
|
|
839
|
+
return;
|
|
840
|
+
const g = u && l - u;
|
|
841
|
+
return g ? Math.round(w * 1e3 / g) : void 0;
|
|
842
|
+
};
|
|
830
843
|
}
|
|
831
|
-
function
|
|
832
|
-
|
|
844
|
+
function Wn(e, t) {
|
|
845
|
+
let n = 0, r = 1e3 / t, s, o;
|
|
846
|
+
const i = (l, u = Date.now()) => {
|
|
847
|
+
n = u, s = null, o && (clearTimeout(o), o = null), e.apply(null, l);
|
|
848
|
+
};
|
|
849
|
+
return [(...l) => {
|
|
850
|
+
const u = Date.now(), d = u - n;
|
|
851
|
+
d >= r ? i(l, u) : (s = l, o || (o = setTimeout(() => {
|
|
852
|
+
o = null, i(s);
|
|
853
|
+
}, r - d)));
|
|
854
|
+
}, () => s && i(s)];
|
|
833
855
|
}
|
|
834
|
-
const
|
|
856
|
+
const Z = (e, t, n = 3) => {
|
|
857
|
+
let r = 0;
|
|
858
|
+
const s = Vn(50, 250);
|
|
859
|
+
return Wn((o) => {
|
|
860
|
+
const i = o.loaded, c = o.lengthComputable ? o.total : void 0, f = i - r, l = s(f), u = i <= c;
|
|
861
|
+
r = i;
|
|
862
|
+
const d = {
|
|
863
|
+
loaded: i,
|
|
864
|
+
total: c,
|
|
865
|
+
progress: c ? i / c : void 0,
|
|
866
|
+
bytes: f,
|
|
867
|
+
rate: l || void 0,
|
|
868
|
+
estimated: l && c && u ? (c - i) / l : void 0,
|
|
869
|
+
event: o,
|
|
870
|
+
lengthComputable: c != null,
|
|
871
|
+
[t ? "download" : "upload"]: !0
|
|
872
|
+
};
|
|
873
|
+
e(d);
|
|
874
|
+
}, n);
|
|
875
|
+
}, De = (e, t) => {
|
|
876
|
+
const n = e != null;
|
|
877
|
+
return [(r) => t[0]({
|
|
878
|
+
lengthComputable: n,
|
|
879
|
+
total: e,
|
|
880
|
+
loaded: r
|
|
881
|
+
}), t[1]];
|
|
882
|
+
}, Fe = (e) => (...t) => a.asap(() => e(...t)), Kn = O.hasStandardBrowserEnv ? (
|
|
835
883
|
// Standard browser envs have full support of the APIs needed to test
|
|
836
884
|
// whether the request URL is of the same origin as current location.
|
|
837
885
|
function() {
|
|
838
|
-
const t = /(msie|trident)/i.test(navigator.userAgent), n = document.createElement("a");
|
|
886
|
+
const t = O.navigator && /(msie|trident)/i.test(O.navigator.userAgent), n = document.createElement("a");
|
|
839
887
|
let r;
|
|
840
888
|
function s(o) {
|
|
841
889
|
let i = o;
|
|
@@ -862,124 +910,399 @@ const An = T.hasStandardBrowserEnv ? (
|
|
|
862
910
|
return !0;
|
|
863
911
|
};
|
|
864
912
|
}()
|
|
913
|
+
), Qn = O.hasStandardBrowserEnv ? (
|
|
914
|
+
// Standard browser envs support document.cookie
|
|
915
|
+
{
|
|
916
|
+
write(e, t, n, r, s, o) {
|
|
917
|
+
const i = [e + "=" + encodeURIComponent(t)];
|
|
918
|
+
a.isNumber(n) && i.push("expires=" + new Date(n).toGMTString()), a.isString(r) && i.push("path=" + r), a.isString(s) && i.push("domain=" + s), o === !0 && i.push("secure"), document.cookie = i.join("; ");
|
|
919
|
+
},
|
|
920
|
+
read(e) {
|
|
921
|
+
const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
|
|
922
|
+
return t ? decodeURIComponent(t[3]) : null;
|
|
923
|
+
},
|
|
924
|
+
remove(e) {
|
|
925
|
+
this.write(e, "", Date.now() - 864e5);
|
|
926
|
+
}
|
|
927
|
+
}
|
|
928
|
+
) : (
|
|
929
|
+
// Non-standard browser env (web workers, react-native) lack needed support.
|
|
930
|
+
{
|
|
931
|
+
write() {
|
|
932
|
+
},
|
|
933
|
+
read() {
|
|
934
|
+
return null;
|
|
935
|
+
},
|
|
936
|
+
remove() {
|
|
937
|
+
}
|
|
938
|
+
}
|
|
865
939
|
);
|
|
866
|
-
function
|
|
867
|
-
|
|
868
|
-
return t && t[1] || "";
|
|
940
|
+
function Gn(e) {
|
|
941
|
+
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
|
|
869
942
|
}
|
|
870
|
-
function
|
|
871
|
-
|
|
872
|
-
const n = new Array(e), r = new Array(e);
|
|
873
|
-
let s = 0, o = 0, i;
|
|
874
|
-
return t = t !== void 0 ? t : 1e3, function(f) {
|
|
875
|
-
const d = Date.now(), l = r[o];
|
|
876
|
-
i || (i = d), n[s] = f, r[s] = d;
|
|
877
|
-
let u = o, y = 0;
|
|
878
|
-
for (; u !== s; )
|
|
879
|
-
y += n[u++], u = u % e;
|
|
880
|
-
if (s = (s + 1) % e, s === o && (o = (o + 1) % e), d - i < t)
|
|
881
|
-
return;
|
|
882
|
-
const E = l && d - l;
|
|
883
|
-
return E ? Math.round(y * 1e3 / E) : void 0;
|
|
884
|
-
};
|
|
943
|
+
function Xn(e, t) {
|
|
944
|
+
return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
|
|
885
945
|
}
|
|
886
|
-
function
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
};
|
|
901
|
-
|
|
946
|
+
function yt(e, t) {
|
|
947
|
+
return e && !Gn(t) ? Xn(e, t) : t;
|
|
948
|
+
}
|
|
949
|
+
const Be = (e) => e instanceof A ? { ...e } : e;
|
|
950
|
+
function D(e, t) {
|
|
951
|
+
t = t || {};
|
|
952
|
+
const n = {};
|
|
953
|
+
function r(l, u, d) {
|
|
954
|
+
return a.isPlainObject(l) && a.isPlainObject(u) ? a.merge.call({ caseless: d }, l, u) : a.isPlainObject(u) ? a.merge({}, u) : a.isArray(u) ? u.slice() : u;
|
|
955
|
+
}
|
|
956
|
+
function s(l, u, d) {
|
|
957
|
+
if (a.isUndefined(u)) {
|
|
958
|
+
if (!a.isUndefined(l))
|
|
959
|
+
return r(void 0, l, d);
|
|
960
|
+
} else return r(l, u, d);
|
|
961
|
+
}
|
|
962
|
+
function o(l, u) {
|
|
963
|
+
if (!a.isUndefined(u))
|
|
964
|
+
return r(void 0, u);
|
|
965
|
+
}
|
|
966
|
+
function i(l, u) {
|
|
967
|
+
if (a.isUndefined(u)) {
|
|
968
|
+
if (!a.isUndefined(l))
|
|
969
|
+
return r(void 0, l);
|
|
970
|
+
} else return r(void 0, u);
|
|
971
|
+
}
|
|
972
|
+
function c(l, u, d) {
|
|
973
|
+
if (d in t)
|
|
974
|
+
return r(l, u);
|
|
975
|
+
if (d in e)
|
|
976
|
+
return r(void 0, l);
|
|
977
|
+
}
|
|
978
|
+
const f = {
|
|
979
|
+
url: o,
|
|
980
|
+
method: o,
|
|
981
|
+
data: o,
|
|
982
|
+
baseURL: i,
|
|
983
|
+
transformRequest: i,
|
|
984
|
+
transformResponse: i,
|
|
985
|
+
paramsSerializer: i,
|
|
986
|
+
timeout: i,
|
|
987
|
+
timeoutMessage: i,
|
|
988
|
+
withCredentials: i,
|
|
989
|
+
withXSRFToken: i,
|
|
990
|
+
adapter: i,
|
|
991
|
+
responseType: i,
|
|
992
|
+
xsrfCookieName: i,
|
|
993
|
+
xsrfHeaderName: i,
|
|
994
|
+
onUploadProgress: i,
|
|
995
|
+
onDownloadProgress: i,
|
|
996
|
+
decompress: i,
|
|
997
|
+
maxContentLength: i,
|
|
998
|
+
maxBodyLength: i,
|
|
999
|
+
beforeRedirect: i,
|
|
1000
|
+
transport: i,
|
|
1001
|
+
httpAgent: i,
|
|
1002
|
+
httpsAgent: i,
|
|
1003
|
+
cancelToken: i,
|
|
1004
|
+
socketPath: i,
|
|
1005
|
+
responseEncoding: i,
|
|
1006
|
+
validateStatus: c,
|
|
1007
|
+
headers: (l, u) => s(Be(l), Be(u), !0)
|
|
902
1008
|
};
|
|
1009
|
+
return a.forEach(Object.keys(Object.assign({}, e, t)), function(u) {
|
|
1010
|
+
const d = f[u] || s, w = d(e[u], t[u], u);
|
|
1011
|
+
a.isUndefined(w) && d !== c || (n[u] = w);
|
|
1012
|
+
}), n;
|
|
903
1013
|
}
|
|
904
|
-
const
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
if (
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
o.setContentType([h || "multipart/form-data", ...b].join("; "));
|
|
919
|
-
}
|
|
1014
|
+
const wt = (e) => {
|
|
1015
|
+
const t = D({}, e);
|
|
1016
|
+
let { data: n, withXSRFToken: r, xsrfHeaderName: s, xsrfCookieName: o, headers: i, auth: c } = t;
|
|
1017
|
+
t.headers = i = A.from(i), t.url = ft(yt(t.baseURL, t.url), e.params, e.paramsSerializer), c && i.set(
|
|
1018
|
+
"Authorization",
|
|
1019
|
+
"Basic " + btoa((c.username || "") + ":" + (c.password ? unescape(encodeURIComponent(c.password)) : ""))
|
|
1020
|
+
);
|
|
1021
|
+
let f;
|
|
1022
|
+
if (a.isFormData(n)) {
|
|
1023
|
+
if (O.hasStandardBrowserEnv || O.hasStandardBrowserWebWorkerEnv)
|
|
1024
|
+
i.setContentType(void 0);
|
|
1025
|
+
else if ((f = i.getContentType()) !== !1) {
|
|
1026
|
+
const [l, ...u] = f ? f.split(";").map((d) => d.trim()).filter(Boolean) : [];
|
|
1027
|
+
i.setContentType([l || "multipart/form-data", ...u].join("; "));
|
|
920
1028
|
}
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
1029
|
+
}
|
|
1030
|
+
if (O.hasStandardBrowserEnv && (r && a.isFunction(r) && (r = r(t)), r || r !== !1 && Kn(t.url))) {
|
|
1031
|
+
const l = s && o && Qn.read(o);
|
|
1032
|
+
l && i.set(s, l);
|
|
1033
|
+
}
|
|
1034
|
+
return t;
|
|
1035
|
+
}, Zn = typeof XMLHttpRequest < "u", Yn = Zn && function(e) {
|
|
1036
|
+
return new Promise(function(n, r) {
|
|
1037
|
+
const s = wt(e);
|
|
1038
|
+
let o = s.data;
|
|
1039
|
+
const i = A.from(s.headers).normalize();
|
|
1040
|
+
let { responseType: c, onUploadProgress: f, onDownloadProgress: l } = s, u, d, w, g, p;
|
|
1041
|
+
function m() {
|
|
1042
|
+
g && g(), p && p(), s.cancelToken && s.cancelToken.unsubscribe(u), s.signal && s.signal.removeEventListener("abort", u);
|
|
925
1043
|
}
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
function
|
|
929
|
-
if (!
|
|
1044
|
+
let h = new XMLHttpRequest();
|
|
1045
|
+
h.open(s.method.toUpperCase(), s.url, !0), h.timeout = s.timeout;
|
|
1046
|
+
function b() {
|
|
1047
|
+
if (!h)
|
|
930
1048
|
return;
|
|
931
|
-
const
|
|
932
|
-
"getAllResponseHeaders" in
|
|
933
|
-
),
|
|
934
|
-
data: !
|
|
935
|
-
status:
|
|
936
|
-
statusText:
|
|
937
|
-
headers:
|
|
1049
|
+
const R = A.from(
|
|
1050
|
+
"getAllResponseHeaders" in h && h.getAllResponseHeaders()
|
|
1051
|
+
), T = {
|
|
1052
|
+
data: !c || c === "text" || c === "json" ? h.responseText : h.response,
|
|
1053
|
+
status: h.status,
|
|
1054
|
+
statusText: h.statusText,
|
|
1055
|
+
headers: R,
|
|
938
1056
|
config: e,
|
|
939
|
-
request:
|
|
1057
|
+
request: h
|
|
940
1058
|
};
|
|
941
|
-
|
|
942
|
-
n(
|
|
943
|
-
}, function(
|
|
944
|
-
r(
|
|
945
|
-
},
|
|
1059
|
+
mt(function(N) {
|
|
1060
|
+
n(N), m();
|
|
1061
|
+
}, function(N) {
|
|
1062
|
+
r(N), m();
|
|
1063
|
+
}, T), h = null;
|
|
946
1064
|
}
|
|
947
|
-
|
|
948
|
-
!
|
|
949
|
-
},
|
|
950
|
-
|
|
951
|
-
},
|
|
952
|
-
r(new
|
|
953
|
-
},
|
|
954
|
-
let
|
|
955
|
-
const
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
1065
|
+
"onloadend" in h ? h.onloadend = b : h.onreadystatechange = function() {
|
|
1066
|
+
!h || h.readyState !== 4 || h.status === 0 && !(h.responseURL && h.responseURL.indexOf("file:") === 0) || setTimeout(b);
|
|
1067
|
+
}, h.onabort = function() {
|
|
1068
|
+
h && (r(new y("Request aborted", y.ECONNABORTED, e, h)), h = null);
|
|
1069
|
+
}, h.onerror = function() {
|
|
1070
|
+
r(new y("Network Error", y.ERR_NETWORK, e, h)), h = null;
|
|
1071
|
+
}, h.ontimeout = function() {
|
|
1072
|
+
let P = s.timeout ? "timeout of " + s.timeout + "ms exceeded" : "timeout exceeded";
|
|
1073
|
+
const T = s.transitional || dt;
|
|
1074
|
+
s.timeoutErrorMessage && (P = s.timeoutErrorMessage), r(new y(
|
|
1075
|
+
P,
|
|
1076
|
+
T.clarifyTimeoutError ? y.ETIMEDOUT : y.ECONNABORTED,
|
|
959
1077
|
e,
|
|
960
|
-
|
|
961
|
-
)),
|
|
962
|
-
},
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
s
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
}, e.cancelToken && e.cancelToken.subscribe(f), e.signal && (e.signal.aborted ? f() : e.signal.addEventListener("abort", f)));
|
|
971
|
-
const p = _n(y);
|
|
972
|
-
if (p && T.protocols.indexOf(p) === -1) {
|
|
973
|
-
r(new m("Unsupported protocol " + p + ":", m.ERR_BAD_REQUEST, e));
|
|
1078
|
+
h
|
|
1079
|
+
)), h = null;
|
|
1080
|
+
}, o === void 0 && i.setContentType(null), "setRequestHeader" in h && a.forEach(i.toJSON(), function(P, T) {
|
|
1081
|
+
h.setRequestHeader(T, P);
|
|
1082
|
+
}), a.isUndefined(s.withCredentials) || (h.withCredentials = !!s.withCredentials), c && c !== "json" && (h.responseType = s.responseType), l && ([w, p] = Z(l, !0), h.addEventListener("progress", w)), f && h.upload && ([d, g] = Z(f), h.upload.addEventListener("progress", d), h.upload.addEventListener("loadend", g)), (s.cancelToken || s.signal) && (u = (R) => {
|
|
1083
|
+
h && (r(!R || R.type ? new I(null, e, h) : R), h.abort(), h = null);
|
|
1084
|
+
}, s.cancelToken && s.cancelToken.subscribe(u), s.signal && (s.signal.aborted ? u() : s.signal.addEventListener("abort", u)));
|
|
1085
|
+
const S = Jn(s.url);
|
|
1086
|
+
if (S && O.protocols.indexOf(S) === -1) {
|
|
1087
|
+
r(new y("Unsupported protocol " + S + ":", y.ERR_BAD_REQUEST, e));
|
|
974
1088
|
return;
|
|
975
1089
|
}
|
|
976
|
-
|
|
1090
|
+
h.send(o || null);
|
|
977
1091
|
});
|
|
978
|
-
},
|
|
979
|
-
|
|
980
|
-
|
|
1092
|
+
}, er = (e, t) => {
|
|
1093
|
+
const { length: n } = e = e ? e.filter(Boolean) : [];
|
|
1094
|
+
if (t || n) {
|
|
1095
|
+
let r = new AbortController(), s;
|
|
1096
|
+
const o = function(l) {
|
|
1097
|
+
if (!s) {
|
|
1098
|
+
s = !0, c();
|
|
1099
|
+
const u = l instanceof Error ? l : this.reason;
|
|
1100
|
+
r.abort(u instanceof y ? u : new I(u instanceof Error ? u.message : u));
|
|
1101
|
+
}
|
|
1102
|
+
};
|
|
1103
|
+
let i = t && setTimeout(() => {
|
|
1104
|
+
i = null, o(new y(`timeout ${t} of ms exceeded`, y.ETIMEDOUT));
|
|
1105
|
+
}, t);
|
|
1106
|
+
const c = () => {
|
|
1107
|
+
e && (i && clearTimeout(i), i = null, e.forEach((l) => {
|
|
1108
|
+
l.unsubscribe ? l.unsubscribe(o) : l.removeEventListener("abort", o);
|
|
1109
|
+
}), e = null);
|
|
1110
|
+
};
|
|
1111
|
+
e.forEach((l) => l.addEventListener("abort", o));
|
|
1112
|
+
const { signal: f } = r;
|
|
1113
|
+
return f.unsubscribe = () => a.asap(c), f;
|
|
1114
|
+
}
|
|
1115
|
+
}, tr = function* (e, t) {
|
|
1116
|
+
let n = e.byteLength;
|
|
1117
|
+
if (n < t) {
|
|
1118
|
+
yield e;
|
|
1119
|
+
return;
|
|
1120
|
+
}
|
|
1121
|
+
let r = 0, s;
|
|
1122
|
+
for (; r < n; )
|
|
1123
|
+
s = r + t, yield e.slice(r, s), r = s;
|
|
1124
|
+
}, nr = async function* (e, t) {
|
|
1125
|
+
for await (const n of rr(e))
|
|
1126
|
+
yield* tr(n, t);
|
|
1127
|
+
}, rr = async function* (e) {
|
|
1128
|
+
if (e[Symbol.asyncIterator]) {
|
|
1129
|
+
yield* e;
|
|
1130
|
+
return;
|
|
1131
|
+
}
|
|
1132
|
+
const t = e.getReader();
|
|
1133
|
+
try {
|
|
1134
|
+
for (; ; ) {
|
|
1135
|
+
const { done: n, value: r } = await t.read();
|
|
1136
|
+
if (n)
|
|
1137
|
+
break;
|
|
1138
|
+
yield r;
|
|
1139
|
+
}
|
|
1140
|
+
} finally {
|
|
1141
|
+
await t.cancel();
|
|
1142
|
+
}
|
|
1143
|
+
}, ve = (e, t, n, r) => {
|
|
1144
|
+
const s = nr(e, t);
|
|
1145
|
+
let o = 0, i, c = (f) => {
|
|
1146
|
+
i || (i = !0, r && r(f));
|
|
1147
|
+
};
|
|
1148
|
+
return new ReadableStream({
|
|
1149
|
+
async pull(f) {
|
|
1150
|
+
try {
|
|
1151
|
+
const { done: l, value: u } = await s.next();
|
|
1152
|
+
if (l) {
|
|
1153
|
+
c(), f.close();
|
|
1154
|
+
return;
|
|
1155
|
+
}
|
|
1156
|
+
let d = u.byteLength;
|
|
1157
|
+
if (n) {
|
|
1158
|
+
let w = o += d;
|
|
1159
|
+
n(w);
|
|
1160
|
+
}
|
|
1161
|
+
f.enqueue(new Uint8Array(u));
|
|
1162
|
+
} catch (l) {
|
|
1163
|
+
throw c(l), l;
|
|
1164
|
+
}
|
|
1165
|
+
},
|
|
1166
|
+
cancel(f) {
|
|
1167
|
+
return c(f), s.return();
|
|
1168
|
+
}
|
|
1169
|
+
}, {
|
|
1170
|
+
highWaterMark: 2
|
|
1171
|
+
});
|
|
1172
|
+
}, se = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", gt = se && typeof ReadableStream == "function", sr = se && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), bt = (e, ...t) => {
|
|
1173
|
+
try {
|
|
1174
|
+
return !!e(...t);
|
|
1175
|
+
} catch {
|
|
1176
|
+
return !1;
|
|
1177
|
+
}
|
|
1178
|
+
}, or = gt && bt(() => {
|
|
1179
|
+
let e = !1;
|
|
1180
|
+
const t = new Request(O.origin, {
|
|
1181
|
+
body: new ReadableStream(),
|
|
1182
|
+
method: "POST",
|
|
1183
|
+
get duplex() {
|
|
1184
|
+
return e = !0, "half";
|
|
1185
|
+
}
|
|
1186
|
+
}).headers.has("Content-Type");
|
|
1187
|
+
return e && !t;
|
|
1188
|
+
}), Ie = 64 * 1024, de = gt && bt(() => a.isReadableStream(new Response("").body)), Y = {
|
|
1189
|
+
stream: de && ((e) => e.body)
|
|
981
1190
|
};
|
|
982
|
-
|
|
1191
|
+
se && ((e) => {
|
|
1192
|
+
["text", "arrayBuffer", "blob", "formData", "stream"].forEach((t) => {
|
|
1193
|
+
!Y[t] && (Y[t] = a.isFunction(e[t]) ? (n) => n[t]() : (n, r) => {
|
|
1194
|
+
throw new y(`Response type '${t}' is not supported`, y.ERR_NOT_SUPPORT, r);
|
|
1195
|
+
});
|
|
1196
|
+
});
|
|
1197
|
+
})(new Response());
|
|
1198
|
+
const ir = async (e) => {
|
|
1199
|
+
if (e == null)
|
|
1200
|
+
return 0;
|
|
1201
|
+
if (a.isBlob(e))
|
|
1202
|
+
return e.size;
|
|
1203
|
+
if (a.isSpecCompliantForm(e))
|
|
1204
|
+
return (await new Request(O.origin, {
|
|
1205
|
+
method: "POST",
|
|
1206
|
+
body: e
|
|
1207
|
+
}).arrayBuffer()).byteLength;
|
|
1208
|
+
if (a.isArrayBufferView(e) || a.isArrayBuffer(e))
|
|
1209
|
+
return e.byteLength;
|
|
1210
|
+
if (a.isURLSearchParams(e) && (e = e + ""), a.isString(e))
|
|
1211
|
+
return (await sr(e)).byteLength;
|
|
1212
|
+
}, ar = async (e, t) => {
|
|
1213
|
+
const n = a.toFiniteNumber(e.getContentLength());
|
|
1214
|
+
return n ?? ir(t);
|
|
1215
|
+
}, cr = se && (async (e) => {
|
|
1216
|
+
let {
|
|
1217
|
+
url: t,
|
|
1218
|
+
method: n,
|
|
1219
|
+
data: r,
|
|
1220
|
+
signal: s,
|
|
1221
|
+
cancelToken: o,
|
|
1222
|
+
timeout: i,
|
|
1223
|
+
onDownloadProgress: c,
|
|
1224
|
+
onUploadProgress: f,
|
|
1225
|
+
responseType: l,
|
|
1226
|
+
headers: u,
|
|
1227
|
+
withCredentials: d = "same-origin",
|
|
1228
|
+
fetchOptions: w
|
|
1229
|
+
} = wt(e);
|
|
1230
|
+
l = l ? (l + "").toLowerCase() : "text";
|
|
1231
|
+
let g = er([s, o && o.toAbortSignal()], i), p;
|
|
1232
|
+
const m = g && g.unsubscribe && (() => {
|
|
1233
|
+
g.unsubscribe();
|
|
1234
|
+
});
|
|
1235
|
+
let h;
|
|
1236
|
+
try {
|
|
1237
|
+
if (f && or && n !== "get" && n !== "head" && (h = await ar(u, r)) !== 0) {
|
|
1238
|
+
let T = new Request(t, {
|
|
1239
|
+
method: "POST",
|
|
1240
|
+
body: r,
|
|
1241
|
+
duplex: "half"
|
|
1242
|
+
}), k;
|
|
1243
|
+
if (a.isFormData(r) && (k = T.headers.get("content-type")) && u.setContentType(k), T.body) {
|
|
1244
|
+
const [N, W] = De(
|
|
1245
|
+
h,
|
|
1246
|
+
Z(Fe(f))
|
|
1247
|
+
);
|
|
1248
|
+
r = ve(T.body, Ie, N, W);
|
|
1249
|
+
}
|
|
1250
|
+
}
|
|
1251
|
+
a.isString(d) || (d = d ? "include" : "omit");
|
|
1252
|
+
const b = "credentials" in Request.prototype;
|
|
1253
|
+
p = new Request(t, {
|
|
1254
|
+
...w,
|
|
1255
|
+
signal: g,
|
|
1256
|
+
method: n.toUpperCase(),
|
|
1257
|
+
headers: u.normalize().toJSON(),
|
|
1258
|
+
body: r,
|
|
1259
|
+
duplex: "half",
|
|
1260
|
+
credentials: b ? d : void 0
|
|
1261
|
+
});
|
|
1262
|
+
let S = await fetch(p);
|
|
1263
|
+
const R = de && (l === "stream" || l === "response");
|
|
1264
|
+
if (de && (c || R && m)) {
|
|
1265
|
+
const T = {};
|
|
1266
|
+
["status", "statusText", "headers"].forEach((xe) => {
|
|
1267
|
+
T[xe] = S[xe];
|
|
1268
|
+
});
|
|
1269
|
+
const k = a.toFiniteNumber(S.headers.get("content-length")), [N, W] = c && De(
|
|
1270
|
+
k,
|
|
1271
|
+
Z(Fe(c), !0)
|
|
1272
|
+
) || [];
|
|
1273
|
+
S = new Response(
|
|
1274
|
+
ve(S.body, Ie, N, () => {
|
|
1275
|
+
W && W(), m && m();
|
|
1276
|
+
}),
|
|
1277
|
+
T
|
|
1278
|
+
);
|
|
1279
|
+
}
|
|
1280
|
+
l = l || "text";
|
|
1281
|
+
let P = await Y[a.findKey(Y, l) || "text"](S, e);
|
|
1282
|
+
return !R && m && m(), await new Promise((T, k) => {
|
|
1283
|
+
mt(T, k, {
|
|
1284
|
+
data: P,
|
|
1285
|
+
headers: A.from(S.headers),
|
|
1286
|
+
status: S.status,
|
|
1287
|
+
statusText: S.statusText,
|
|
1288
|
+
config: e,
|
|
1289
|
+
request: p
|
|
1290
|
+
});
|
|
1291
|
+
});
|
|
1292
|
+
} catch (b) {
|
|
1293
|
+
throw m && m(), b && b.name === "TypeError" && /fetch/i.test(b.message) ? Object.assign(
|
|
1294
|
+
new y("Network Error", y.ERR_NETWORK, e, p),
|
|
1295
|
+
{
|
|
1296
|
+
cause: b.cause || b
|
|
1297
|
+
}
|
|
1298
|
+
) : y.from(b, b && b.code, e, p);
|
|
1299
|
+
}
|
|
1300
|
+
}), pe = {
|
|
1301
|
+
http: Tn,
|
|
1302
|
+
xhr: Yn,
|
|
1303
|
+
fetch: cr
|
|
1304
|
+
};
|
|
1305
|
+
a.forEach(pe, (e, t) => {
|
|
983
1306
|
if (e) {
|
|
984
1307
|
try {
|
|
985
1308
|
Object.defineProperty(e, "name", { value: t });
|
|
@@ -988,7 +1311,7 @@ a.forEach(ne, (e, t) => {
|
|
|
988
1311
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
989
1312
|
}
|
|
990
1313
|
});
|
|
991
|
-
const
|
|
1314
|
+
const je = (e) => `- ${e}`, ur = (e) => a.isFunction(e) || e === null || e === !1, Et = {
|
|
992
1315
|
getAdapter: (e) => {
|
|
993
1316
|
e = a.isArray(e) ? e : [e];
|
|
994
1317
|
const { length: t } = e;
|
|
@@ -997,8 +1320,8 @@ const Oe = (e) => `- ${e}`, Nn = (e) => a.isFunction(e) || e === null || e === !
|
|
|
997
1320
|
for (let o = 0; o < t; o++) {
|
|
998
1321
|
n = e[o];
|
|
999
1322
|
let i;
|
|
1000
|
-
if (r = n, !
|
|
1001
|
-
throw new
|
|
1323
|
+
if (r = n, !ur(n) && (r = pe[(i = String(n)).toLowerCase()], r === void 0))
|
|
1324
|
+
throw new y(`Unknown adapter '${i}'`);
|
|
1002
1325
|
if (r)
|
|
1003
1326
|
break;
|
|
1004
1327
|
s[i || "#" + o] = r;
|
|
@@ -1008,127 +1331,62 @@ const Oe = (e) => `- ${e}`, Nn = (e) => a.isFunction(e) || e === null || e === !
|
|
|
1008
1331
|
([c, f]) => `adapter ${c} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
|
|
1009
1332
|
);
|
|
1010
1333
|
let i = t ? o.length > 1 ? `since :
|
|
1011
|
-
` + o.map(
|
|
1012
|
-
`) : " " +
|
|
1013
|
-
throw new
|
|
1334
|
+
` + o.map(je).join(`
|
|
1335
|
+
`) : " " + je(o[0]) : "as no adapter specified";
|
|
1336
|
+
throw new y(
|
|
1014
1337
|
"There is no suitable adapter to dispatch the request " + i,
|
|
1015
1338
|
"ERR_NOT_SUPPORT"
|
|
1016
1339
|
);
|
|
1017
1340
|
}
|
|
1018
1341
|
return r;
|
|
1019
1342
|
},
|
|
1020
|
-
adapters:
|
|
1343
|
+
adapters: pe
|
|
1021
1344
|
};
|
|
1022
|
-
function
|
|
1345
|
+
function ce(e) {
|
|
1023
1346
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
1024
|
-
throw new
|
|
1347
|
+
throw new I(null, e);
|
|
1025
1348
|
}
|
|
1026
|
-
function
|
|
1027
|
-
return
|
|
1349
|
+
function qe(e) {
|
|
1350
|
+
return ce(e), e.headers = A.from(e.headers), e.data = ae.call(
|
|
1028
1351
|
e,
|
|
1029
1352
|
e.transformRequest
|
|
1030
|
-
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1),
|
|
1031
|
-
return
|
|
1353
|
+
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Et.getAdapter(e.adapter || V.adapter)(e).then(function(r) {
|
|
1354
|
+
return ce(e), r.data = ae.call(
|
|
1032
1355
|
e,
|
|
1033
1356
|
e.transformResponse,
|
|
1034
1357
|
r
|
|
1035
|
-
), r.headers =
|
|
1358
|
+
), r.headers = A.from(r.headers), r;
|
|
1036
1359
|
}, function(r) {
|
|
1037
|
-
return
|
|
1360
|
+
return ht(r) || (ce(e), r && r.response && (r.response.data = ae.call(
|
|
1038
1361
|
e,
|
|
1039
1362
|
e.transformResponse,
|
|
1040
1363
|
r.response
|
|
1041
|
-
), r.response.headers =
|
|
1364
|
+
), r.response.headers = A.from(r.response.headers))), Promise.reject(r);
|
|
1042
1365
|
});
|
|
1043
1366
|
}
|
|
1044
|
-
const
|
|
1045
|
-
function N(e, t) {
|
|
1046
|
-
t = t || {};
|
|
1047
|
-
const n = {};
|
|
1048
|
-
function r(d, l, u) {
|
|
1049
|
-
return a.isPlainObject(d) && a.isPlainObject(l) ? a.merge.call({ caseless: u }, d, l) : a.isPlainObject(l) ? a.merge({}, l) : a.isArray(l) ? l.slice() : l;
|
|
1050
|
-
}
|
|
1051
|
-
function s(d, l, u) {
|
|
1052
|
-
if (a.isUndefined(l)) {
|
|
1053
|
-
if (!a.isUndefined(d))
|
|
1054
|
-
return r(void 0, d, u);
|
|
1055
|
-
} else return r(d, l, u);
|
|
1056
|
-
}
|
|
1057
|
-
function o(d, l) {
|
|
1058
|
-
if (!a.isUndefined(l))
|
|
1059
|
-
return r(void 0, l);
|
|
1060
|
-
}
|
|
1061
|
-
function i(d, l) {
|
|
1062
|
-
if (a.isUndefined(l)) {
|
|
1063
|
-
if (!a.isUndefined(d))
|
|
1064
|
-
return r(void 0, d);
|
|
1065
|
-
} else return r(void 0, l);
|
|
1066
|
-
}
|
|
1067
|
-
function c(d, l, u) {
|
|
1068
|
-
if (u in t)
|
|
1069
|
-
return r(d, l);
|
|
1070
|
-
if (u in e)
|
|
1071
|
-
return r(void 0, d);
|
|
1072
|
-
}
|
|
1073
|
-
const f = {
|
|
1074
|
-
url: o,
|
|
1075
|
-
method: o,
|
|
1076
|
-
data: o,
|
|
1077
|
-
baseURL: i,
|
|
1078
|
-
transformRequest: i,
|
|
1079
|
-
transformResponse: i,
|
|
1080
|
-
paramsSerializer: i,
|
|
1081
|
-
timeout: i,
|
|
1082
|
-
timeoutMessage: i,
|
|
1083
|
-
withCredentials: i,
|
|
1084
|
-
withXSRFToken: i,
|
|
1085
|
-
adapter: i,
|
|
1086
|
-
responseType: i,
|
|
1087
|
-
xsrfCookieName: i,
|
|
1088
|
-
xsrfHeaderName: i,
|
|
1089
|
-
onUploadProgress: i,
|
|
1090
|
-
onDownloadProgress: i,
|
|
1091
|
-
decompress: i,
|
|
1092
|
-
maxContentLength: i,
|
|
1093
|
-
maxBodyLength: i,
|
|
1094
|
-
beforeRedirect: i,
|
|
1095
|
-
transport: i,
|
|
1096
|
-
httpAgent: i,
|
|
1097
|
-
httpsAgent: i,
|
|
1098
|
-
cancelToken: i,
|
|
1099
|
-
socketPath: i,
|
|
1100
|
-
responseEncoding: i,
|
|
1101
|
-
validateStatus: c,
|
|
1102
|
-
headers: (d, l) => s(Re(d), Re(l), !0)
|
|
1103
|
-
};
|
|
1104
|
-
return a.forEach(Object.keys(Object.assign({}, e, t)), function(l) {
|
|
1105
|
-
const u = f[l] || s, y = u(e[l], t[l], l);
|
|
1106
|
-
a.isUndefined(y) && u !== c || (n[l] = y);
|
|
1107
|
-
}), n;
|
|
1108
|
-
}
|
|
1109
|
-
const nt = "1.6.7", fe = {};
|
|
1367
|
+
const St = "1.7.7", Te = {};
|
|
1110
1368
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
|
|
1111
|
-
|
|
1369
|
+
Te[e] = function(r) {
|
|
1112
1370
|
return typeof r === e || "a" + (t < 1 ? "n " : " ") + e;
|
|
1113
1371
|
};
|
|
1114
1372
|
});
|
|
1115
|
-
const
|
|
1116
|
-
|
|
1373
|
+
const Me = {};
|
|
1374
|
+
Te.transitional = function(t, n, r) {
|
|
1117
1375
|
function s(o, i) {
|
|
1118
|
-
return "[Axios v" +
|
|
1376
|
+
return "[Axios v" + St + "] Transitional option '" + o + "'" + i + (r ? ". " + r : "");
|
|
1119
1377
|
}
|
|
1120
1378
|
return (o, i, c) => {
|
|
1121
1379
|
if (t === !1)
|
|
1122
|
-
throw new
|
|
1380
|
+
throw new y(
|
|
1123
1381
|
s(i, " has been removed" + (n ? " in " + n : "")),
|
|
1124
|
-
|
|
1382
|
+
y.ERR_DEPRECATED
|
|
1125
1383
|
);
|
|
1126
|
-
return n && !
|
|
1384
|
+
return n && !Me[i] && (Me[i] = !0), t ? t(o, i, c) : !0;
|
|
1127
1385
|
};
|
|
1128
1386
|
};
|
|
1129
|
-
function
|
|
1387
|
+
function lr(e, t, n) {
|
|
1130
1388
|
if (typeof e != "object")
|
|
1131
|
-
throw new
|
|
1389
|
+
throw new y("options must be an object", y.ERR_BAD_OPTION_VALUE);
|
|
1132
1390
|
const r = Object.keys(e);
|
|
1133
1391
|
let s = r.length;
|
|
1134
1392
|
for (; s-- > 0; ) {
|
|
@@ -1136,22 +1394,22 @@ function Cn(e, t, n) {
|
|
|
1136
1394
|
if (i) {
|
|
1137
1395
|
const c = e[o], f = c === void 0 || i(c, o, e);
|
|
1138
1396
|
if (f !== !0)
|
|
1139
|
-
throw new
|
|
1397
|
+
throw new y("option " + o + " must be " + f, y.ERR_BAD_OPTION_VALUE);
|
|
1140
1398
|
continue;
|
|
1141
1399
|
}
|
|
1142
1400
|
if (n !== !0)
|
|
1143
|
-
throw new
|
|
1401
|
+
throw new y("Unknown option " + o, y.ERR_BAD_OPTION);
|
|
1144
1402
|
}
|
|
1145
1403
|
}
|
|
1146
|
-
const
|
|
1147
|
-
assertOptions:
|
|
1148
|
-
validators:
|
|
1149
|
-
},
|
|
1150
|
-
class
|
|
1404
|
+
const he = {
|
|
1405
|
+
assertOptions: lr,
|
|
1406
|
+
validators: Te
|
|
1407
|
+
}, C = he.validators;
|
|
1408
|
+
class U {
|
|
1151
1409
|
constructor(t) {
|
|
1152
1410
|
this.defaults = t, this.interceptors = {
|
|
1153
|
-
request: new
|
|
1154
|
-
response: new
|
|
1411
|
+
request: new Le(),
|
|
1412
|
+
response: new Le()
|
|
1155
1413
|
};
|
|
1156
1414
|
}
|
|
1157
1415
|
/**
|
|
@@ -1170,24 +1428,27 @@ class x {
|
|
|
1170
1428
|
let s;
|
|
1171
1429
|
Error.captureStackTrace ? Error.captureStackTrace(s = {}) : s = new Error();
|
|
1172
1430
|
const o = s.stack ? s.stack.replace(/^.+\n/, "") : "";
|
|
1173
|
-
|
|
1431
|
+
try {
|
|
1432
|
+
r.stack ? o && !String(r.stack).endsWith(o.replace(/^.+\n.+\n/, "")) && (r.stack += `
|
|
1174
1433
|
` + o) : r.stack = o;
|
|
1434
|
+
} catch {
|
|
1435
|
+
}
|
|
1175
1436
|
}
|
|
1176
1437
|
throw r;
|
|
1177
1438
|
}
|
|
1178
1439
|
}
|
|
1179
1440
|
_request(t, n) {
|
|
1180
|
-
typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n =
|
|
1441
|
+
typeof t == "string" ? (n = n || {}, n.url = t) : n = t || {}, n = D(this.defaults, n);
|
|
1181
1442
|
const { transitional: r, paramsSerializer: s, headers: o } = n;
|
|
1182
|
-
r !== void 0 &&
|
|
1183
|
-
silentJSONParsing:
|
|
1184
|
-
forcedJSONParsing:
|
|
1185
|
-
clarifyTimeoutError:
|
|
1443
|
+
r !== void 0 && he.assertOptions(r, {
|
|
1444
|
+
silentJSONParsing: C.transitional(C.boolean),
|
|
1445
|
+
forcedJSONParsing: C.transitional(C.boolean),
|
|
1446
|
+
clarifyTimeoutError: C.transitional(C.boolean)
|
|
1186
1447
|
}, !1), s != null && (a.isFunction(s) ? n.paramsSerializer = {
|
|
1187
1448
|
serialize: s
|
|
1188
|
-
} :
|
|
1189
|
-
encode:
|
|
1190
|
-
serialize:
|
|
1449
|
+
} : he.assertOptions(s, {
|
|
1450
|
+
encode: C.function,
|
|
1451
|
+
serialize: C.function
|
|
1191
1452
|
}, !0)), n.method = (n.method || this.defaults.method || "get").toLowerCase();
|
|
1192
1453
|
let i = o && a.merge(
|
|
1193
1454
|
o.common,
|
|
@@ -1198,52 +1459,52 @@ class x {
|
|
|
1198
1459
|
(p) => {
|
|
1199
1460
|
delete o[p];
|
|
1200
1461
|
}
|
|
1201
|
-
), n.headers =
|
|
1462
|
+
), n.headers = A.concat(i, o);
|
|
1202
1463
|
const c = [];
|
|
1203
1464
|
let f = !0;
|
|
1204
|
-
this.interceptors.request.forEach(function(
|
|
1205
|
-
typeof
|
|
1465
|
+
this.interceptors.request.forEach(function(m) {
|
|
1466
|
+
typeof m.runWhen == "function" && m.runWhen(n) === !1 || (f = f && m.synchronous, c.unshift(m.fulfilled, m.rejected));
|
|
1206
1467
|
});
|
|
1207
|
-
const
|
|
1208
|
-
this.interceptors.response.forEach(function(
|
|
1209
|
-
|
|
1468
|
+
const l = [];
|
|
1469
|
+
this.interceptors.response.forEach(function(m) {
|
|
1470
|
+
l.push(m.fulfilled, m.rejected);
|
|
1210
1471
|
});
|
|
1211
|
-
let
|
|
1472
|
+
let u, d = 0, w;
|
|
1212
1473
|
if (!f) {
|
|
1213
|
-
const p = [
|
|
1214
|
-
for (p.unshift.apply(p, c), p.push.apply(p,
|
|
1215
|
-
|
|
1216
|
-
return
|
|
1474
|
+
const p = [qe.bind(this), void 0];
|
|
1475
|
+
for (p.unshift.apply(p, c), p.push.apply(p, l), w = p.length, u = Promise.resolve(n); d < w; )
|
|
1476
|
+
u = u.then(p[d++], p[d++]);
|
|
1477
|
+
return u;
|
|
1217
1478
|
}
|
|
1218
|
-
|
|
1219
|
-
let
|
|
1220
|
-
for (
|
|
1221
|
-
const p = c[
|
|
1479
|
+
w = c.length;
|
|
1480
|
+
let g = n;
|
|
1481
|
+
for (d = 0; d < w; ) {
|
|
1482
|
+
const p = c[d++], m = c[d++];
|
|
1222
1483
|
try {
|
|
1223
|
-
|
|
1224
|
-
} catch (
|
|
1225
|
-
|
|
1484
|
+
g = p(g);
|
|
1485
|
+
} catch (h) {
|
|
1486
|
+
m.call(this, h);
|
|
1226
1487
|
break;
|
|
1227
1488
|
}
|
|
1228
1489
|
}
|
|
1229
1490
|
try {
|
|
1230
|
-
|
|
1491
|
+
u = qe.call(this, g);
|
|
1231
1492
|
} catch (p) {
|
|
1232
1493
|
return Promise.reject(p);
|
|
1233
1494
|
}
|
|
1234
|
-
for (
|
|
1235
|
-
|
|
1236
|
-
return
|
|
1495
|
+
for (d = 0, w = l.length; d < w; )
|
|
1496
|
+
u = u.then(l[d++], l[d++]);
|
|
1497
|
+
return u;
|
|
1237
1498
|
}
|
|
1238
1499
|
getUri(t) {
|
|
1239
|
-
t =
|
|
1240
|
-
const n =
|
|
1241
|
-
return
|
|
1500
|
+
t = D(this.defaults, t);
|
|
1501
|
+
const n = yt(t.baseURL, t.url);
|
|
1502
|
+
return ft(n, t.params, t.paramsSerializer);
|
|
1242
1503
|
}
|
|
1243
1504
|
}
|
|
1244
1505
|
a.forEach(["delete", "get", "head", "options"], function(t) {
|
|
1245
|
-
|
|
1246
|
-
return this.request(
|
|
1506
|
+
U.prototype[t] = function(n, r) {
|
|
1507
|
+
return this.request(D(r || {}, {
|
|
1247
1508
|
method: t,
|
|
1248
1509
|
url: n,
|
|
1249
1510
|
data: (r || {}).data
|
|
@@ -1253,7 +1514,7 @@ a.forEach(["delete", "get", "head", "options"], function(t) {
|
|
|
1253
1514
|
a.forEach(["post", "put", "patch"], function(t) {
|
|
1254
1515
|
function n(r) {
|
|
1255
1516
|
return function(o, i, c) {
|
|
1256
|
-
return this.request(
|
|
1517
|
+
return this.request(D(c || {}, {
|
|
1257
1518
|
method: t,
|
|
1258
1519
|
headers: r ? {
|
|
1259
1520
|
"Content-Type": "multipart/form-data"
|
|
@@ -1263,9 +1524,9 @@ a.forEach(["post", "put", "patch"], function(t) {
|
|
|
1263
1524
|
}));
|
|
1264
1525
|
};
|
|
1265
1526
|
}
|
|
1266
|
-
|
|
1527
|
+
U.prototype[t] = n(), U.prototype[t + "Form"] = n(!0);
|
|
1267
1528
|
});
|
|
1268
|
-
class
|
|
1529
|
+
class Oe {
|
|
1269
1530
|
constructor(t) {
|
|
1270
1531
|
if (typeof t != "function")
|
|
1271
1532
|
throw new TypeError("executor must be a function.");
|
|
@@ -1289,7 +1550,7 @@ class de {
|
|
|
1289
1550
|
r.unsubscribe(o);
|
|
1290
1551
|
}, i;
|
|
1291
1552
|
}, t(function(o, i, c) {
|
|
1292
|
-
r.reason || (r.reason = new
|
|
1553
|
+
r.reason || (r.reason = new I(o, i, c), n(r.reason));
|
|
1293
1554
|
});
|
|
1294
1555
|
}
|
|
1295
1556
|
/**
|
|
@@ -1318,6 +1579,12 @@ class de {
|
|
|
1318
1579
|
const n = this._listeners.indexOf(t);
|
|
1319
1580
|
n !== -1 && this._listeners.splice(n, 1);
|
|
1320
1581
|
}
|
|
1582
|
+
toAbortSignal() {
|
|
1583
|
+
const t = new AbortController(), n = (r) => {
|
|
1584
|
+
t.abort(r);
|
|
1585
|
+
};
|
|
1586
|
+
return this.subscribe(n), t.signal.unsubscribe = () => this.unsubscribe(n), t.signal;
|
|
1587
|
+
}
|
|
1321
1588
|
/**
|
|
1322
1589
|
* Returns an object that contains a new `CancelToken` and a function that, when called,
|
|
1323
1590
|
* cancels the `CancelToken`.
|
|
@@ -1325,22 +1592,22 @@ class de {
|
|
|
1325
1592
|
static source() {
|
|
1326
1593
|
let t;
|
|
1327
1594
|
return {
|
|
1328
|
-
token: new
|
|
1595
|
+
token: new Oe(function(s) {
|
|
1329
1596
|
t = s;
|
|
1330
1597
|
}),
|
|
1331
1598
|
cancel: t
|
|
1332
1599
|
};
|
|
1333
1600
|
}
|
|
1334
1601
|
}
|
|
1335
|
-
function
|
|
1602
|
+
function fr(e) {
|
|
1336
1603
|
return function(n) {
|
|
1337
1604
|
return e.apply(null, n);
|
|
1338
1605
|
};
|
|
1339
1606
|
}
|
|
1340
|
-
function
|
|
1607
|
+
function dr(e) {
|
|
1341
1608
|
return a.isObject(e) && e.isAxiosError === !0;
|
|
1342
1609
|
}
|
|
1343
|
-
const
|
|
1610
|
+
const me = {
|
|
1344
1611
|
Continue: 100,
|
|
1345
1612
|
SwitchingProtocols: 101,
|
|
1346
1613
|
Processing: 102,
|
|
@@ -1405,43 +1672,43 @@ const se = {
|
|
|
1405
1672
|
NotExtended: 510,
|
|
1406
1673
|
NetworkAuthenticationRequired: 511
|
|
1407
1674
|
};
|
|
1408
|
-
Object.entries(
|
|
1409
|
-
|
|
1675
|
+
Object.entries(me).forEach(([e, t]) => {
|
|
1676
|
+
me[t] = e;
|
|
1410
1677
|
});
|
|
1411
|
-
function
|
|
1412
|
-
const t = new
|
|
1413
|
-
return a.extend(n,
|
|
1414
|
-
return
|
|
1678
|
+
function Rt(e) {
|
|
1679
|
+
const t = new U(e), n = Ye(U.prototype.request, t);
|
|
1680
|
+
return a.extend(n, U.prototype, t, { allOwnKeys: !0 }), a.extend(n, t, null, { allOwnKeys: !0 }), n.create = function(s) {
|
|
1681
|
+
return Rt(D(e, s));
|
|
1415
1682
|
}, n;
|
|
1416
1683
|
}
|
|
1417
|
-
const
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1684
|
+
const E = Rt(V);
|
|
1685
|
+
E.Axios = U;
|
|
1686
|
+
E.CanceledError = I;
|
|
1687
|
+
E.CancelToken = Oe;
|
|
1688
|
+
E.isCancel = ht;
|
|
1689
|
+
E.VERSION = St;
|
|
1690
|
+
E.toFormData = re;
|
|
1691
|
+
E.AxiosError = y;
|
|
1692
|
+
E.Cancel = E.CanceledError;
|
|
1693
|
+
E.all = function(t) {
|
|
1427
1694
|
return Promise.all(t);
|
|
1428
1695
|
};
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
var
|
|
1438
|
-
const
|
|
1696
|
+
E.spread = fr;
|
|
1697
|
+
E.isAxiosError = dr;
|
|
1698
|
+
E.mergeConfig = D;
|
|
1699
|
+
E.AxiosHeaders = A;
|
|
1700
|
+
E.formToJSON = (e) => pt(a.isHTMLForm(e) ? new FormData(e) : e);
|
|
1701
|
+
E.getAdapter = Et.getAdapter;
|
|
1702
|
+
E.HttpStatusCode = me;
|
|
1703
|
+
E.default = E;
|
|
1704
|
+
var He;
|
|
1705
|
+
const Tt = typeof window < "u", pr = (e) => typeof e == "string", ze = () => +Date.now(), ye = () => {
|
|
1439
1706
|
};
|
|
1440
|
-
|
|
1441
|
-
function
|
|
1442
|
-
return typeof e == "function" ? e() :
|
|
1707
|
+
Tt && ((He = window == null ? void 0 : window.navigator) != null && He.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent);
|
|
1708
|
+
function Ae(e) {
|
|
1709
|
+
return typeof e == "function" ? e() : kt(e);
|
|
1443
1710
|
}
|
|
1444
|
-
function
|
|
1711
|
+
function hr(e, t) {
|
|
1445
1712
|
function n(...r) {
|
|
1446
1713
|
return new Promise((s, o) => {
|
|
1447
1714
|
Promise.resolve(e(() => t.apply(this, r), { fn: t, thisArg: this, args: r })).then(s).catch(o);
|
|
@@ -1449,84 +1716,84 @@ function Ln(e, t) {
|
|
|
1449
1716
|
}
|
|
1450
1717
|
return n;
|
|
1451
1718
|
}
|
|
1452
|
-
function
|
|
1453
|
-
let s = 0, o, i = !0, c =
|
|
1454
|
-
const
|
|
1455
|
-
o && (clearTimeout(o), o = void 0, c(), c =
|
|
1719
|
+
function mr(e, t = !0, n = !0, r = !1) {
|
|
1720
|
+
let s = 0, o, i = !0, c = ye, f;
|
|
1721
|
+
const l = () => {
|
|
1722
|
+
o && (clearTimeout(o), o = void 0, c(), c = ye);
|
|
1456
1723
|
};
|
|
1457
|
-
return (
|
|
1458
|
-
const
|
|
1459
|
-
return
|
|
1460
|
-
c = r ?
|
|
1461
|
-
s = Date.now(), i = !0,
|
|
1462
|
-
}, Math.max(0,
|
|
1463
|
-
})), !n && !o && (o = setTimeout(() => i = !0,
|
|
1724
|
+
return (d) => {
|
|
1725
|
+
const w = Ae(e), g = Date.now() - s, p = () => f = d();
|
|
1726
|
+
return l(), w <= 0 ? (s = Date.now(), p()) : (g > w && (n || !i) ? (s = Date.now(), p()) : t && (f = new Promise((m, h) => {
|
|
1727
|
+
c = r ? h : m, o = setTimeout(() => {
|
|
1728
|
+
s = Date.now(), i = !0, m(p()), l();
|
|
1729
|
+
}, Math.max(0, w - g));
|
|
1730
|
+
})), !n && !o && (o = setTimeout(() => i = !0, w)), i = !1, f);
|
|
1464
1731
|
};
|
|
1465
1732
|
}
|
|
1466
|
-
function
|
|
1733
|
+
function yr(e) {
|
|
1467
1734
|
return e;
|
|
1468
1735
|
}
|
|
1469
|
-
function
|
|
1470
|
-
return
|
|
1736
|
+
function wr(e) {
|
|
1737
|
+
return Ct() ? (Nt(e), !0) : !1;
|
|
1471
1738
|
}
|
|
1472
|
-
function
|
|
1739
|
+
function gr(e) {
|
|
1473
1740
|
var t;
|
|
1474
|
-
const n =
|
|
1741
|
+
const n = Ae(e);
|
|
1475
1742
|
return (t = n == null ? void 0 : n.$el) != null ? t : n;
|
|
1476
1743
|
}
|
|
1477
|
-
const
|
|
1478
|
-
function
|
|
1744
|
+
const Ot = Tt ? window : void 0;
|
|
1745
|
+
function $e(...e) {
|
|
1479
1746
|
let t, n, r, s;
|
|
1480
|
-
if (
|
|
1481
|
-
return
|
|
1747
|
+
if (pr(e[0]) || Array.isArray(e[0]) ? ([n, r, s] = e, t = Ot) : [t, n, r, s] = e, !t)
|
|
1748
|
+
return ye;
|
|
1482
1749
|
Array.isArray(n) || (n = [n]), Array.isArray(r) || (r = [r]);
|
|
1483
1750
|
const o = [], i = () => {
|
|
1484
|
-
o.forEach((
|
|
1485
|
-
}, c = (
|
|
1486
|
-
i(),
|
|
1487
|
-
}, { immediate: !0, flush: "post" }),
|
|
1751
|
+
o.forEach((u) => u()), o.length = 0;
|
|
1752
|
+
}, c = (u, d, w, g) => (u.addEventListener(d, w, g), () => u.removeEventListener(d, w, g)), f = ge(() => [gr(t), Ae(s)], ([u, d]) => {
|
|
1753
|
+
i(), u && o.push(...n.flatMap((w) => r.map((g) => c(u, w, g, d))));
|
|
1754
|
+
}, { immediate: !0, flush: "post" }), l = () => {
|
|
1488
1755
|
f(), i();
|
|
1489
1756
|
};
|
|
1490
|
-
return
|
|
1757
|
+
return wr(l), l;
|
|
1491
1758
|
}
|
|
1492
|
-
const
|
|
1493
|
-
|
|
1494
|
-
const
|
|
1495
|
-
function
|
|
1759
|
+
const Je = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, Ve = "__vueuse_ssr_handlers__";
|
|
1760
|
+
Je[Ve] = Je[Ve] || {};
|
|
1761
|
+
const br = ["mousemove", "mousedown", "resize", "keydown", "touchstart", "wheel"], Er = 6e4;
|
|
1762
|
+
function Sr(e = Er, t = {}) {
|
|
1496
1763
|
const {
|
|
1497
1764
|
initialState: n = !1,
|
|
1498
1765
|
listenForVisibilityChange: r = !0,
|
|
1499
|
-
events: s =
|
|
1500
|
-
window: o =
|
|
1501
|
-
eventFilter: i =
|
|
1502
|
-
} = t, c =
|
|
1503
|
-
let
|
|
1504
|
-
const
|
|
1505
|
-
c.value = !1, f.value =
|
|
1766
|
+
events: s = br,
|
|
1767
|
+
window: o = Ot,
|
|
1768
|
+
eventFilter: i = mr(50)
|
|
1769
|
+
} = t, c = X(n), f = X(ze());
|
|
1770
|
+
let l;
|
|
1771
|
+
const u = hr(i, () => {
|
|
1772
|
+
c.value = !1, f.value = ze(), clearTimeout(l), l = setTimeout(() => c.value = !0, e);
|
|
1506
1773
|
});
|
|
1507
1774
|
if (o) {
|
|
1508
|
-
const
|
|
1509
|
-
for (const
|
|
1510
|
-
|
|
1511
|
-
r &&
|
|
1512
|
-
|
|
1775
|
+
const d = o.document;
|
|
1776
|
+
for (const w of s)
|
|
1777
|
+
$e(o, w, u, { passive: !0 });
|
|
1778
|
+
r && $e(d, "visibilitychange", () => {
|
|
1779
|
+
d.hidden || u();
|
|
1513
1780
|
});
|
|
1514
1781
|
}
|
|
1515
|
-
return
|
|
1782
|
+
return l = setTimeout(() => c.value = !0, e), { idle: c, lastActive: f };
|
|
1516
1783
|
}
|
|
1517
|
-
var
|
|
1784
|
+
var We;
|
|
1518
1785
|
(function(e) {
|
|
1519
1786
|
e.UP = "UP", e.RIGHT = "RIGHT", e.DOWN = "DOWN", e.LEFT = "LEFT", e.NONE = "NONE";
|
|
1520
|
-
})(
|
|
1521
|
-
var
|
|
1787
|
+
})(We || (We = {}));
|
|
1788
|
+
var Rr = Object.defineProperty, Ke = Object.getOwnPropertySymbols, Tr = Object.prototype.hasOwnProperty, Or = Object.prototype.propertyIsEnumerable, Qe = (e, t, n) => t in e ? Rr(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Ar = (e, t) => {
|
|
1522
1789
|
for (var n in t || (t = {}))
|
|
1523
|
-
|
|
1524
|
-
if (
|
|
1525
|
-
for (var n of
|
|
1526
|
-
|
|
1790
|
+
Tr.call(t, n) && Qe(e, n, t[n]);
|
|
1791
|
+
if (Ke)
|
|
1792
|
+
for (var n of Ke(t))
|
|
1793
|
+
Or.call(t, n) && Qe(e, n, t[n]);
|
|
1527
1794
|
return e;
|
|
1528
1795
|
};
|
|
1529
|
-
const
|
|
1796
|
+
const _r = {
|
|
1530
1797
|
easeInSine: [0.12, 0, 0.39, 0],
|
|
1531
1798
|
easeOutSine: [0.61, 1, 0.88, 1],
|
|
1532
1799
|
easeInOutSine: [0.37, 0, 0.63, 1],
|
|
@@ -1552,133 +1819,133 @@ const Wn = {
|
|
|
1552
1819
|
easeOutBack: [0.34, 1.56, 0.64, 1],
|
|
1553
1820
|
easeInOutBack: [0.68, -0.6, 0.32, 1.6]
|
|
1554
1821
|
};
|
|
1555
|
-
|
|
1556
|
-
linear:
|
|
1557
|
-
},
|
|
1558
|
-
let
|
|
1559
|
-
const
|
|
1560
|
-
|
|
1822
|
+
Ar({
|
|
1823
|
+
linear: yr
|
|
1824
|
+
}, _r);
|
|
1825
|
+
let we;
|
|
1826
|
+
const At = { triggerProxySso: "triggerProxySso" }, xr = () => {
|
|
1827
|
+
we = (e) => {
|
|
1561
1828
|
var n;
|
|
1562
1829
|
const { origin: t } = new URL(location.href);
|
|
1563
1830
|
(n = window.top) == null || n.postMessage(
|
|
1564
|
-
{ type:
|
|
1831
|
+
{ type: At.triggerProxySso, data: { ...e || {}, redirect_uri: `${t}/` } },
|
|
1565
1832
|
t
|
|
1566
1833
|
);
|
|
1567
1834
|
};
|
|
1568
|
-
},
|
|
1835
|
+
}, Pr = (e) => {
|
|
1569
1836
|
window.top === window.self && window.addEventListener("message", (t) => {
|
|
1570
1837
|
const { type: n, data: r } = t.data;
|
|
1571
|
-
n ===
|
|
1838
|
+
n === At.triggerProxySso && (e == null || e(r));
|
|
1572
1839
|
});
|
|
1573
1840
|
};
|
|
1574
|
-
window.top !== window.self &&
|
|
1575
|
-
const
|
|
1841
|
+
window.top !== window.self && xr();
|
|
1842
|
+
const _t = (e) => new URL(location.href).searchParams.get(e), _e = {
|
|
1576
1843
|
oauth: "/api/justauth/oauth-server/v1/visitor/oauth/authorize",
|
|
1577
1844
|
// 重定向到登录页
|
|
1578
1845
|
token: "/api/justauth/oauth-server/v1/visitor/oauth/token"
|
|
1579
1846
|
// 通过code获取token
|
|
1580
|
-
}, { baseURL:
|
|
1847
|
+
}, { baseURL: kr, noRedireLogin: Cr = !1 } = be(), z = `${location.origin}/`, F = {
|
|
1581
1848
|
response_type: "code",
|
|
1582
1849
|
scope: "sever",
|
|
1583
1850
|
client_id: "sys",
|
|
1584
|
-
client_secret:
|
|
1851
|
+
client_secret: Lt("das123"),
|
|
1585
1852
|
state: +/* @__PURE__ */ new Date()
|
|
1586
|
-
},
|
|
1587
|
-
const e =
|
|
1853
|
+
}, Nr = () => {
|
|
1854
|
+
const e = Ge(location.href, "redirect_url") || "";
|
|
1588
1855
|
if (e)
|
|
1589
1856
|
window.__isAutoCloseApp = !1, window.location.replace(decodeURIComponent(e));
|
|
1590
1857
|
else {
|
|
1591
1858
|
const t = ["code", "state", "kingdee_token", "redirect_url"];
|
|
1592
|
-
window.history.replaceState(null, "",
|
|
1859
|
+
window.history.replaceState(null, "", Ut(t)), window.__isAutoCloseApp = !1, window.location.reload();
|
|
1593
1860
|
}
|
|
1594
|
-
},
|
|
1861
|
+
}, xt = X(!1), Pt = (e) => {
|
|
1595
1862
|
if (e <= 0) return;
|
|
1596
|
-
const { idle: t } =
|
|
1597
|
-
|
|
1863
|
+
const { idle: t } = Sr(e);
|
|
1864
|
+
ge(
|
|
1598
1865
|
() => t.value,
|
|
1599
1866
|
(n) => {
|
|
1600
|
-
n === !0 && (
|
|
1867
|
+
n === !0 && (xt.value = !0);
|
|
1601
1868
|
}
|
|
1602
1869
|
);
|
|
1603
1870
|
};
|
|
1604
|
-
localStorage.getItem("idelTime") &&
|
|
1605
|
-
const
|
|
1606
|
-
const e =
|
|
1607
|
-
if (!e) return
|
|
1608
|
-
const { redirectUri: t } =
|
|
1871
|
+
localStorage.getItem("idelTime") && Pt(Number(localStorage.getItem("idelTime")));
|
|
1872
|
+
const Lr = async () => {
|
|
1873
|
+
const e = _t("code") || "";
|
|
1874
|
+
if (!e) return M();
|
|
1875
|
+
const { redirectUri: t } = B().getData(), n = Ge(location.href, "kingdee_token") || "";
|
|
1609
1876
|
let r = {};
|
|
1610
1877
|
const s = {
|
|
1611
1878
|
grant_type: "authorization_code",
|
|
1612
1879
|
code: e,
|
|
1613
|
-
client_id:
|
|
1614
|
-
client_secret:
|
|
1615
|
-
redirect_uri: t ||
|
|
1880
|
+
client_id: F.client_id,
|
|
1881
|
+
client_secret: F.client_secret,
|
|
1882
|
+
redirect_uri: t || z
|
|
1616
1883
|
};
|
|
1617
1884
|
n && (sessionStorage.setItem("kingdee_token", n), s.redirect_uri = `${s.redirect_uri}?kingdee_token=${n}`);
|
|
1618
1885
|
try {
|
|
1619
|
-
r = await
|
|
1620
|
-
|
|
1886
|
+
r = await E.create().post(
|
|
1887
|
+
_e.token,
|
|
1621
1888
|
{},
|
|
1622
1889
|
{
|
|
1623
|
-
baseURL:
|
|
1890
|
+
baseURL: kr,
|
|
1624
1891
|
params: s,
|
|
1625
1892
|
headers: {
|
|
1626
1893
|
"Content-Type": "application/x-www-form-urlencoded"
|
|
1627
1894
|
}
|
|
1628
1895
|
}
|
|
1629
1896
|
);
|
|
1630
|
-
const { access_token: o = "", expires_in: i = 0, refresh_token: c = "", refresh_exp: f = 0 } = r.data,
|
|
1897
|
+
const { access_token: o = "", expires_in: i = 0, refresh_token: c = "", refresh_exp: f = 0 } = r.data, l = {
|
|
1631
1898
|
accessToken: o,
|
|
1632
1899
|
accessTokenExpiredAt: +/* @__PURE__ */ new Date() + Number(i) * 1e3,
|
|
1633
1900
|
refreshToken: c,
|
|
1634
1901
|
info: r.data
|
|
1635
1902
|
};
|
|
1636
|
-
|
|
1637
|
-
const
|
|
1638
|
-
return
|
|
1903
|
+
B().save(l), await Ze(o);
|
|
1904
|
+
const u = Number(f) - (/* @__PURE__ */ new Date()).getTime();
|
|
1905
|
+
return u && u > 0 && (Pt(u), u && localStorage.setItem("idelTime", u.toString())), Nr(), o;
|
|
1639
1906
|
} catch {
|
|
1640
|
-
return
|
|
1907
|
+
return $({ ...F, redirect_uri: t || z });
|
|
1641
1908
|
}
|
|
1642
|
-
},
|
|
1909
|
+
}, q = X(!1), Mr = async (e) => {
|
|
1643
1910
|
if (e.public) return "";
|
|
1644
|
-
if (
|
|
1645
|
-
if (
|
|
1911
|
+
if (xt.value) return $({ ...F, redirect_uri: z });
|
|
1912
|
+
if (q.value)
|
|
1646
1913
|
return await new Promise(async (s) => {
|
|
1647
|
-
|
|
1648
|
-
() =>
|
|
1914
|
+
ge(
|
|
1915
|
+
() => q.value,
|
|
1649
1916
|
(o) => {
|
|
1650
1917
|
if (!o) {
|
|
1651
|
-
const i =
|
|
1918
|
+
const i = M();
|
|
1652
1919
|
s(i);
|
|
1653
1920
|
}
|
|
1654
1921
|
}
|
|
1655
1922
|
);
|
|
1656
1923
|
});
|
|
1657
|
-
const { accessTokenExpiredAt: t } =
|
|
1658
|
-
if ((!
|
|
1659
|
-
return
|
|
1660
|
-
let r =
|
|
1661
|
-
|
|
1924
|
+
const { accessTokenExpiredAt: t } = B().getData(), n = _t("code") || "";
|
|
1925
|
+
if ((!M() || t === 0) && !n)
|
|
1926
|
+
return $({ ...F, redirect_uri: z });
|
|
1927
|
+
let r = M();
|
|
1928
|
+
q.value = !0;
|
|
1662
1929
|
try {
|
|
1663
|
-
typeof t == "number" && t > 0 && +/* @__PURE__ */ new Date() + 6e4 > t && (r = await
|
|
1930
|
+
typeof t == "number" && t > 0 && +/* @__PURE__ */ new Date() + 6e4 > t && (r = await Ur(F)), r = await Lr(), q.value = !1;
|
|
1664
1931
|
} catch {
|
|
1665
|
-
|
|
1932
|
+
q.value = !1;
|
|
1666
1933
|
}
|
|
1667
1934
|
return r;
|
|
1668
|
-
},
|
|
1669
|
-
if (
|
|
1670
|
-
const { baseURL: t, ssoLocale: n } =
|
|
1671
|
-
if (
|
|
1935
|
+
}, $ = (e) => {
|
|
1936
|
+
if (Cr) return;
|
|
1937
|
+
const { baseURL: t, ssoLocale: n } = be();
|
|
1938
|
+
if (we) return we(e);
|
|
1672
1939
|
e.logout = "true", n && (e.locale = "locale");
|
|
1673
|
-
const r = Object.keys(e).filter((o) => o !== "client_secret").map((o) => `${o}=${e[o]}`).join("&"), s = `${t}${
|
|
1674
|
-
|
|
1940
|
+
const r = Object.keys(e).filter((o) => o !== "client_secret").map((o) => `${o}=${e[o]}`).join("&"), s = `${t}${_e.oauth}?${r}`;
|
|
1941
|
+
Xe(), sessionStorage.clear(), localStorage.removeItem("idelTime"), B().save({ redirectUri: e.redirect_uri }), window.__isAutoCloseApp = !1, location.replace(s);
|
|
1675
1942
|
};
|
|
1676
|
-
|
|
1677
|
-
const
|
|
1678
|
-
const { baseURL: t } =
|
|
1943
|
+
Pr($);
|
|
1944
|
+
const Ur = async (e) => {
|
|
1945
|
+
const { baseURL: t } = be(), { refreshToken: n, redirectUri: r } = B().getData();
|
|
1679
1946
|
try {
|
|
1680
|
-
const s = await
|
|
1681
|
-
|
|
1947
|
+
const s = await E.create().post(
|
|
1948
|
+
_e.token,
|
|
1682
1949
|
{},
|
|
1683
1950
|
{
|
|
1684
1951
|
baseURL: t,
|
|
@@ -1695,37 +1962,37 @@ const er = async (e) => {
|
|
|
1695
1962
|
refreshToken: c,
|
|
1696
1963
|
info: s.data
|
|
1697
1964
|
};
|
|
1698
|
-
return
|
|
1965
|
+
return B().save(f), await Ze(o), o;
|
|
1699
1966
|
} catch {
|
|
1700
|
-
return
|
|
1967
|
+
return $({ ...e, redirect_uri: r || z });
|
|
1701
1968
|
}
|
|
1702
|
-
},
|
|
1969
|
+
}, B = () => ({
|
|
1703
1970
|
getData: () => ({
|
|
1704
|
-
accessToken:
|
|
1705
|
-
accessTokenExpiredAt:
|
|
1706
|
-
refreshToken:
|
|
1707
|
-
redirectUri:
|
|
1971
|
+
accessToken: M(),
|
|
1972
|
+
accessTokenExpiredAt: K("accessTokenExpiredAt") ? Number(K("accessTokenExpiredAt")) : "",
|
|
1973
|
+
refreshToken: K("refreshToken"),
|
|
1974
|
+
redirectUri: K("redirectUri")
|
|
1708
1975
|
}),
|
|
1709
1976
|
save: (e) => {
|
|
1710
|
-
|
|
1977
|
+
Dt(
|
|
1711
1978
|
e.accessToken || "",
|
|
1712
1979
|
{
|
|
1713
1980
|
accessTokenExpiredAt: e.accessTokenExpiredAt,
|
|
1714
1981
|
refreshToken: e.refreshToken,
|
|
1715
1982
|
redirectUri: e.redirectUri
|
|
1716
1983
|
}
|
|
1717
|
-
),
|
|
1984
|
+
), Ft(e);
|
|
1718
1985
|
},
|
|
1719
1986
|
remove: () => {
|
|
1720
|
-
|
|
1987
|
+
Xe(), Bt();
|
|
1721
1988
|
}
|
|
1722
1989
|
});
|
|
1723
1990
|
export {
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1991
|
+
_t as getQuery,
|
|
1992
|
+
Mr as getToken,
|
|
1993
|
+
Lr as getTokenFromCode,
|
|
1994
|
+
F as getTokenParams,
|
|
1995
|
+
$ as login,
|
|
1996
|
+
z as real_uri,
|
|
1997
|
+
B as tokenStorage
|
|
1731
1998
|
};
|