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