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