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