qlfy-ecological-login 1.2.2 → 1.2.3
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/lib/index.mjs +279 -274
- package/lib/index.mjs.gz +0 -0
- package/lib/index.umd.js +6 -6
- package/lib/index.umd.js.gz +0 -0
- package/package.json +1 -1
package/lib/index.mjs
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
function
|
|
1
|
+
import { defineComponent as ct, onBeforeUnmount as lt, watch as Ee, nextTick as ut } from "vue";
|
|
2
|
+
function Fe(e, t) {
|
|
3
3
|
return function() {
|
|
4
4
|
return e.apply(t, arguments);
|
|
5
5
|
};
|
|
6
6
|
}
|
|
7
|
-
const { toString:
|
|
8
|
-
const r =
|
|
7
|
+
const { toString: ft } = Object.prototype, { getPrototypeOf: pe } = Object, { iterator: Z, toStringTag: qe } = Symbol, Y = /* @__PURE__ */ ((e) => (t) => {
|
|
8
|
+
const r = ft.call(t);
|
|
9
9
|
return e[r] || (e[r] = r.slice(8, -1).toLowerCase());
|
|
10
10
|
})(/* @__PURE__ */ Object.create(null)), C = (e) => (e = e.toLowerCase(), (t) => Y(t) === e), ee = (e) => (t) => typeof t === e, { isArray: $ } = Array, v = ee("undefined");
|
|
11
|
-
function
|
|
12
|
-
return e !== null && !v(e) && e.constructor !== null && !v(e.constructor) &&
|
|
11
|
+
function dt(e) {
|
|
12
|
+
return e !== null && !v(e) && e.constructor !== null && !v(e.constructor) && P(e.constructor.isBuffer) && e.constructor.isBuffer(e);
|
|
13
13
|
}
|
|
14
14
|
const Ue = C("ArrayBuffer");
|
|
15
|
-
function
|
|
15
|
+
function ht(e) {
|
|
16
16
|
let t;
|
|
17
17
|
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && Ue(e.buffer), t;
|
|
18
18
|
}
|
|
19
|
-
const
|
|
19
|
+
const pt = ee("string"), P = ee("function"), Ie = ee("number"), te = (e) => e !== null && typeof e == "object", mt = (e) => e === !0 || e === !1, W = (e) => {
|
|
20
20
|
if (Y(e) !== "object")
|
|
21
21
|
return !1;
|
|
22
22
|
const t = pe(e);
|
|
23
|
-
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(
|
|
24
|
-
},
|
|
23
|
+
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(qe in e) && !(Z in e);
|
|
24
|
+
}, gt = C("Date"), wt = C("File"), yt = C("Blob"), bt = C("FileList"), Et = (e) => te(e) && P(e.pipe), St = (e) => {
|
|
25
25
|
let t;
|
|
26
|
-
return e && (typeof FormData == "function" && e instanceof FormData ||
|
|
27
|
-
t === "object" &&
|
|
28
|
-
},
|
|
26
|
+
return e && (typeof FormData == "function" && e instanceof FormData || P(e.append) && ((t = Y(e)) === "formdata" || // detect form-data instance
|
|
27
|
+
t === "object" && P(e.toString) && e.toString() === "[object FormData]"));
|
|
28
|
+
}, Rt = C("URLSearchParams"), [Tt, Ot, xt, At] = ["ReadableStream", "Request", "Response", "Headers"].map(C), Lt = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
29
29
|
function J(e, t, { allOwnKeys: r = !1 } = {}) {
|
|
30
30
|
if (e === null || typeof e > "u")
|
|
31
31
|
return;
|
|
@@ -40,7 +40,7 @@ function J(e, t, { allOwnKeys: r = !1 } = {}) {
|
|
|
40
40
|
c = s[n], t.call(null, e[c], c, e);
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
function
|
|
43
|
+
function Me(e, t) {
|
|
44
44
|
t = t.toLowerCase();
|
|
45
45
|
const r = Object.keys(e);
|
|
46
46
|
let n = r.length, o;
|
|
@@ -49,10 +49,10 @@ function Ie(e, t) {
|
|
|
49
49
|
return o;
|
|
50
50
|
return null;
|
|
51
51
|
}
|
|
52
|
-
const
|
|
52
|
+
const q = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, $e = (e) => !v(e) && e !== q;
|
|
53
53
|
function ce() {
|
|
54
|
-
const { caseless: e } =
|
|
55
|
-
const s = e &&
|
|
54
|
+
const { caseless: e } = $e(this) && this || {}, t = {}, r = (n, o) => {
|
|
55
|
+
const s = e && Me(t, o) || o;
|
|
56
56
|
W(t[s]) && W(n) ? t[s] = ce(t[s], n) : W(n) ? t[s] = ce({}, n) : $(n) ? t[s] = n.slice() : t[s] = n;
|
|
57
57
|
};
|
|
58
58
|
for (let n = 0, o = arguments.length; n < o; n++)
|
|
@@ -60,12 +60,12 @@ function ce() {
|
|
|
60
60
|
return t;
|
|
61
61
|
}
|
|
62
62
|
const Pt = (e, t, r, { allOwnKeys: n } = {}) => (J(t, (o, s) => {
|
|
63
|
-
r &&
|
|
64
|
-
}, { allOwnKeys: n }), e),
|
|
63
|
+
r && P(o) ? e[s] = Fe(o, r) : e[s] = o;
|
|
64
|
+
}, { allOwnKeys: n }), e), kt = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), Ct = (e, t, r, n) => {
|
|
65
65
|
e.prototype = Object.create(t.prototype, n), e.prototype.constructor = e, Object.defineProperty(e, "super", {
|
|
66
66
|
value: t.prototype
|
|
67
67
|
}), r && Object.assign(e.prototype, r);
|
|
68
|
-
},
|
|
68
|
+
}, Nt = (e, t, r, n) => {
|
|
69
69
|
let o, s, i;
|
|
70
70
|
const c = {};
|
|
71
71
|
if (t = t || {}, e == null) return t;
|
|
@@ -75,49 +75,49 @@ const Pt = (e, t, r, { allOwnKeys: n } = {}) => (J(t, (o, s) => {
|
|
|
75
75
|
e = r !== !1 && pe(e);
|
|
76
76
|
} while (e && (!r || r(e, t)) && e !== Object.prototype);
|
|
77
77
|
return t;
|
|
78
|
-
},
|
|
78
|
+
}, Dt = (e, t, r) => {
|
|
79
79
|
e = String(e), (r === void 0 || r > e.length) && (r = e.length), r -= t.length;
|
|
80
80
|
const n = e.indexOf(t, r);
|
|
81
81
|
return n !== -1 && n === r;
|
|
82
|
-
},
|
|
82
|
+
}, Bt = (e) => {
|
|
83
83
|
if (!e) return null;
|
|
84
84
|
if ($(e)) return e;
|
|
85
85
|
let t = e.length;
|
|
86
|
-
if (!
|
|
86
|
+
if (!Ie(t)) return null;
|
|
87
87
|
const r = new Array(t);
|
|
88
88
|
for (; t-- > 0; )
|
|
89
89
|
r[t] = e[t];
|
|
90
90
|
return r;
|
|
91
|
-
},
|
|
91
|
+
}, _t = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && pe(Uint8Array)), Ft = (e, t) => {
|
|
92
92
|
const n = (e && e[Z]).call(e);
|
|
93
93
|
let o;
|
|
94
94
|
for (; (o = n.next()) && !o.done; ) {
|
|
95
95
|
const s = o.value;
|
|
96
96
|
t.call(e, s[0], s[1]);
|
|
97
97
|
}
|
|
98
|
-
},
|
|
98
|
+
}, qt = (e, t) => {
|
|
99
99
|
let r;
|
|
100
100
|
const n = [];
|
|
101
101
|
for (; (r = e.exec(t)) !== null; )
|
|
102
102
|
n.push(r);
|
|
103
103
|
return n;
|
|
104
|
-
}, Ut = C("HTMLFormElement"),
|
|
104
|
+
}, Ut = C("HTMLFormElement"), It = (e) => e.toLowerCase().replace(
|
|
105
105
|
/[-_\s]([a-z\d])(\w*)/g,
|
|
106
106
|
function(r, n, o) {
|
|
107
107
|
return n.toUpperCase() + o;
|
|
108
108
|
}
|
|
109
|
-
), Se = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype),
|
|
109
|
+
), Se = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), Mt = C("RegExp"), je = (e, t) => {
|
|
110
110
|
const r = Object.getOwnPropertyDescriptors(e), n = {};
|
|
111
111
|
J(r, (o, s) => {
|
|
112
112
|
let i;
|
|
113
113
|
(i = t(o, s, e)) !== !1 && (n[s] = i || o);
|
|
114
114
|
}), Object.defineProperties(e, n);
|
|
115
|
-
},
|
|
116
|
-
|
|
117
|
-
if (
|
|
115
|
+
}, $t = (e) => {
|
|
116
|
+
je(e, (t, r) => {
|
|
117
|
+
if (P(e) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
|
|
118
118
|
return !1;
|
|
119
119
|
const n = e[r];
|
|
120
|
-
if (
|
|
120
|
+
if (P(n)) {
|
|
121
121
|
if (t.enumerable = !1, "writable" in t) {
|
|
122
122
|
t.writable = !1;
|
|
123
123
|
return;
|
|
@@ -127,19 +127,19 @@ const Pt = (e, t, r, { allOwnKeys: n } = {}) => (J(t, (o, s) => {
|
|
|
127
127
|
});
|
|
128
128
|
}
|
|
129
129
|
});
|
|
130
|
-
},
|
|
130
|
+
}, jt = (e, t) => {
|
|
131
131
|
const r = {}, n = (o) => {
|
|
132
132
|
o.forEach((s) => {
|
|
133
133
|
r[s] = !0;
|
|
134
134
|
});
|
|
135
135
|
};
|
|
136
136
|
return $(e) ? n(e) : n(String(e).split(t)), r;
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
|
-
function
|
|
140
|
-
return !!(e &&
|
|
137
|
+
}, Ht = () => {
|
|
138
|
+
}, zt = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
|
|
139
|
+
function vt(e) {
|
|
140
|
+
return !!(e && P(e.append) && e[qe] === "FormData" && e[Z]);
|
|
141
141
|
}
|
|
142
|
-
const
|
|
142
|
+
const Jt = (e) => {
|
|
143
143
|
const t = new Array(10), r = (n, o) => {
|
|
144
144
|
if (te(n)) {
|
|
145
145
|
if (t.indexOf(n) >= 0)
|
|
@@ -156,71 +156,71 @@ const vt = (e) => {
|
|
|
156
156
|
return n;
|
|
157
157
|
};
|
|
158
158
|
return r(e, 0);
|
|
159
|
-
},
|
|
160
|
-
o ===
|
|
159
|
+
}, Vt = C("AsyncFunction"), Wt = (e) => e && (te(e) || P(e)) && P(e.then) && P(e.catch), He = ((e, t) => e ? setImmediate : t ? ((r, n) => (q.addEventListener("message", ({ source: o, data: s }) => {
|
|
160
|
+
o === q && s === r && n.length && n.shift()();
|
|
161
161
|
}, !1), (o) => {
|
|
162
|
-
n.push(o),
|
|
162
|
+
n.push(o), q.postMessage(r, "*");
|
|
163
163
|
}))(`axios@${Math.random()}`, []) : (r) => setTimeout(r))(
|
|
164
164
|
typeof setImmediate == "function",
|
|
165
|
-
|
|
166
|
-
),
|
|
165
|
+
P(q.postMessage)
|
|
166
|
+
), Kt = typeof queueMicrotask < "u" ? queueMicrotask.bind(q) : typeof process < "u" && process.nextTick || He, Xt = (e) => e != null && P(e[Z]), a = {
|
|
167
167
|
isArray: $,
|
|
168
168
|
isArrayBuffer: Ue,
|
|
169
|
-
isBuffer:
|
|
170
|
-
isFormData:
|
|
171
|
-
isArrayBufferView:
|
|
172
|
-
isString:
|
|
173
|
-
isNumber:
|
|
174
|
-
isBoolean:
|
|
169
|
+
isBuffer: dt,
|
|
170
|
+
isFormData: St,
|
|
171
|
+
isArrayBufferView: ht,
|
|
172
|
+
isString: pt,
|
|
173
|
+
isNumber: Ie,
|
|
174
|
+
isBoolean: mt,
|
|
175
175
|
isObject: te,
|
|
176
176
|
isPlainObject: W,
|
|
177
|
-
isReadableStream:
|
|
178
|
-
isRequest:
|
|
179
|
-
isResponse:
|
|
180
|
-
isHeaders:
|
|
177
|
+
isReadableStream: Tt,
|
|
178
|
+
isRequest: Ot,
|
|
179
|
+
isResponse: xt,
|
|
180
|
+
isHeaders: At,
|
|
181
181
|
isUndefined: v,
|
|
182
|
-
isDate:
|
|
183
|
-
isFile:
|
|
184
|
-
isBlob:
|
|
185
|
-
isRegExp:
|
|
186
|
-
isFunction:
|
|
187
|
-
isStream:
|
|
188
|
-
isURLSearchParams:
|
|
189
|
-
isTypedArray:
|
|
190
|
-
isFileList:
|
|
182
|
+
isDate: gt,
|
|
183
|
+
isFile: wt,
|
|
184
|
+
isBlob: yt,
|
|
185
|
+
isRegExp: Mt,
|
|
186
|
+
isFunction: P,
|
|
187
|
+
isStream: Et,
|
|
188
|
+
isURLSearchParams: Rt,
|
|
189
|
+
isTypedArray: _t,
|
|
190
|
+
isFileList: bt,
|
|
191
191
|
forEach: J,
|
|
192
192
|
merge: ce,
|
|
193
193
|
extend: Pt,
|
|
194
|
-
trim:
|
|
195
|
-
stripBOM:
|
|
196
|
-
inherits:
|
|
197
|
-
toFlatObject:
|
|
194
|
+
trim: Lt,
|
|
195
|
+
stripBOM: kt,
|
|
196
|
+
inherits: Ct,
|
|
197
|
+
toFlatObject: Nt,
|
|
198
198
|
kindOf: Y,
|
|
199
199
|
kindOfTest: C,
|
|
200
|
-
endsWith:
|
|
201
|
-
toArray:
|
|
202
|
-
forEachEntry:
|
|
203
|
-
matchAll:
|
|
200
|
+
endsWith: Dt,
|
|
201
|
+
toArray: Bt,
|
|
202
|
+
forEachEntry: Ft,
|
|
203
|
+
matchAll: qt,
|
|
204
204
|
isHTMLForm: Ut,
|
|
205
205
|
hasOwnProperty: Se,
|
|
206
206
|
hasOwnProp: Se,
|
|
207
207
|
// an alias to avoid ESLint no-prototype-builtins detection
|
|
208
|
-
reduceDescriptors:
|
|
209
|
-
freezeMethods:
|
|
210
|
-
toObjectSet:
|
|
211
|
-
toCamelCase:
|
|
212
|
-
noop:
|
|
213
|
-
toFiniteNumber:
|
|
214
|
-
findKey:
|
|
215
|
-
global:
|
|
216
|
-
isContextDefined:
|
|
217
|
-
isSpecCompliantForm:
|
|
218
|
-
toJSONObject:
|
|
219
|
-
isAsyncFn:
|
|
220
|
-
isThenable:
|
|
221
|
-
setImmediate:
|
|
222
|
-
asap:
|
|
223
|
-
isIterable:
|
|
208
|
+
reduceDescriptors: je,
|
|
209
|
+
freezeMethods: $t,
|
|
210
|
+
toObjectSet: jt,
|
|
211
|
+
toCamelCase: It,
|
|
212
|
+
noop: Ht,
|
|
213
|
+
toFiniteNumber: zt,
|
|
214
|
+
findKey: Me,
|
|
215
|
+
global: q,
|
|
216
|
+
isContextDefined: $e,
|
|
217
|
+
isSpecCompliantForm: vt,
|
|
218
|
+
toJSONObject: Jt,
|
|
219
|
+
isAsyncFn: Vt,
|
|
220
|
+
isThenable: Wt,
|
|
221
|
+
setImmediate: He,
|
|
222
|
+
asap: Kt,
|
|
223
|
+
isIterable: Xt
|
|
224
224
|
};
|
|
225
225
|
function g(e, t, r, n, o) {
|
|
226
226
|
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), r && (this.config = r), n && (this.request = n), o && (this.response = o, this.status = o.status ? o.status : null);
|
|
@@ -246,7 +246,7 @@ a.inherits(g, Error, {
|
|
|
246
246
|
};
|
|
247
247
|
}
|
|
248
248
|
});
|
|
249
|
-
const
|
|
249
|
+
const ze = g.prototype, ve = {};
|
|
250
250
|
[
|
|
251
251
|
"ERR_BAD_OPTION_VALUE",
|
|
252
252
|
"ERR_BAD_OPTION",
|
|
@@ -262,32 +262,32 @@ const He = g.prototype, ze = {};
|
|
|
262
262
|
"ERR_INVALID_URL"
|
|
263
263
|
// eslint-disable-next-line func-names
|
|
264
264
|
].forEach((e) => {
|
|
265
|
-
|
|
265
|
+
ve[e] = { value: e };
|
|
266
266
|
});
|
|
267
|
-
Object.defineProperties(g,
|
|
268
|
-
Object.defineProperty(
|
|
267
|
+
Object.defineProperties(g, ve);
|
|
268
|
+
Object.defineProperty(ze, "isAxiosError", { value: !0 });
|
|
269
269
|
g.from = (e, t, r, n, o, s) => {
|
|
270
|
-
const i = Object.create(
|
|
270
|
+
const i = Object.create(ze);
|
|
271
271
|
return a.toFlatObject(e, i, function(f) {
|
|
272
272
|
return f !== Error.prototype;
|
|
273
273
|
}, (c) => c !== "isAxiosError"), g.call(i, e.message, t, r, n, o), i.cause = e, i.name = e.name, s && Object.assign(i, s), i;
|
|
274
274
|
};
|
|
275
|
-
const
|
|
275
|
+
const Gt = null;
|
|
276
276
|
function le(e) {
|
|
277
277
|
return a.isPlainObject(e) || a.isArray(e);
|
|
278
278
|
}
|
|
279
|
-
function
|
|
279
|
+
function Je(e) {
|
|
280
280
|
return a.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
281
281
|
}
|
|
282
282
|
function Re(e, t, r) {
|
|
283
283
|
return e ? e.concat(t).map(function(o, s) {
|
|
284
|
-
return o =
|
|
284
|
+
return o = Je(o), !r && s ? "[" + o + "]" : o;
|
|
285
285
|
}).join(r ? "." : "") : t;
|
|
286
286
|
}
|
|
287
|
-
function
|
|
287
|
+
function Qt(e) {
|
|
288
288
|
return a.isArray(e) && !e.some(le);
|
|
289
289
|
}
|
|
290
|
-
const
|
|
290
|
+
const Zt = a.toFlatObject(a, {}, null, function(t) {
|
|
291
291
|
return /^is[A-Z]/.test(t);
|
|
292
292
|
});
|
|
293
293
|
function ne(e, t, r) {
|
|
@@ -318,18 +318,18 @@ function ne(e, t, r) {
|
|
|
318
318
|
if (h && !p && typeof h == "object") {
|
|
319
319
|
if (a.endsWith(m, "{}"))
|
|
320
320
|
m = n ? m : m.slice(0, -2), h = JSON.stringify(h);
|
|
321
|
-
else if (a.isArray(h) &&
|
|
322
|
-
return m =
|
|
323
|
-
!(a.isUndefined(
|
|
321
|
+
else if (a.isArray(h) && Qt(h) || (a.isFileList(h) || a.endsWith(m, "[]")) && (E = a.toArray(h)))
|
|
322
|
+
return m = Je(m), E.forEach(function(T, w) {
|
|
323
|
+
!(a.isUndefined(T) || T === null) && t.append(
|
|
324
324
|
// eslint-disable-next-line no-nested-ternary
|
|
325
325
|
i === !0 ? Re([m], w, s) : i === null ? m : m + "[]",
|
|
326
|
-
l(
|
|
326
|
+
l(T)
|
|
327
327
|
);
|
|
328
328
|
}), !1;
|
|
329
329
|
}
|
|
330
330
|
return le(h) ? !0 : (t.append(Re(p, m, s), l(h)), !1);
|
|
331
331
|
}
|
|
332
|
-
const d = [], y = Object.assign(
|
|
332
|
+
const d = [], y = Object.assign(Zt, {
|
|
333
333
|
defaultVisitor: u,
|
|
334
334
|
convertValue: l,
|
|
335
335
|
isVisitable: le
|
|
@@ -338,14 +338,14 @@ function ne(e, t, r) {
|
|
|
338
338
|
if (!a.isUndefined(h)) {
|
|
339
339
|
if (d.indexOf(h) !== -1)
|
|
340
340
|
throw Error("Circular reference detected in " + m.join("."));
|
|
341
|
-
d.push(h), a.forEach(h, function(E,
|
|
341
|
+
d.push(h), a.forEach(h, function(E, O) {
|
|
342
342
|
(!(a.isUndefined(E) || E === null) && o.call(
|
|
343
343
|
t,
|
|
344
344
|
E,
|
|
345
|
-
a.isString(
|
|
345
|
+
a.isString(O) ? O.trim() : O,
|
|
346
346
|
m,
|
|
347
347
|
y
|
|
348
|
-
)) === !0 && b(E, m ? m.concat(
|
|
348
|
+
)) === !0 && b(E, m ? m.concat(O) : [O]);
|
|
349
349
|
}), d.pop();
|
|
350
350
|
}
|
|
351
351
|
}
|
|
@@ -370,11 +370,11 @@ function Te(e) {
|
|
|
370
370
|
function me(e, t) {
|
|
371
371
|
this._pairs = [], e && ne(e, this, t);
|
|
372
372
|
}
|
|
373
|
-
const
|
|
374
|
-
|
|
373
|
+
const Ve = me.prototype;
|
|
374
|
+
Ve.append = function(t, r) {
|
|
375
375
|
this._pairs.push([t, r]);
|
|
376
376
|
};
|
|
377
|
-
|
|
377
|
+
Ve.toString = function(t) {
|
|
378
378
|
const r = t ? function(n) {
|
|
379
379
|
return t.call(this, n, Te);
|
|
380
380
|
} : Te;
|
|
@@ -382,13 +382,13 @@ Je.toString = function(t) {
|
|
|
382
382
|
return r(o[0]) + "=" + r(o[1]);
|
|
383
383
|
}, "").join("&");
|
|
384
384
|
};
|
|
385
|
-
function
|
|
385
|
+
function Yt(e) {
|
|
386
386
|
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
|
|
387
387
|
}
|
|
388
|
-
function
|
|
388
|
+
function We(e, t, r) {
|
|
389
389
|
if (!t)
|
|
390
390
|
return e;
|
|
391
|
-
const n = r && r.encode ||
|
|
391
|
+
const n = r && r.encode || Yt;
|
|
392
392
|
a.isFunction(r) && (r = {
|
|
393
393
|
serialize: r
|
|
394
394
|
});
|
|
@@ -454,41 +454,41 @@ class Oe {
|
|
|
454
454
|
});
|
|
455
455
|
}
|
|
456
456
|
}
|
|
457
|
-
const
|
|
457
|
+
const Ke = {
|
|
458
458
|
silentJSONParsing: !0,
|
|
459
459
|
forcedJSONParsing: !0,
|
|
460
460
|
clarifyTimeoutError: !1
|
|
461
|
-
},
|
|
461
|
+
}, en = typeof URLSearchParams < "u" ? URLSearchParams : me, tn = typeof FormData < "u" ? FormData : null, nn = typeof Blob < "u" ? Blob : null, rn = {
|
|
462
462
|
isBrowser: !0,
|
|
463
463
|
classes: {
|
|
464
|
-
URLSearchParams:
|
|
465
|
-
FormData:
|
|
466
|
-
Blob:
|
|
464
|
+
URLSearchParams: en,
|
|
465
|
+
FormData: tn,
|
|
466
|
+
Blob: nn
|
|
467
467
|
},
|
|
468
468
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
469
|
-
}, ge = typeof window < "u" && typeof document < "u", ue = typeof navigator == "object" && navigator || void 0,
|
|
470
|
-
self instanceof WorkerGlobalScope && typeof self.importScripts == "function",
|
|
469
|
+
}, ge = typeof window < "u" && typeof document < "u", ue = typeof navigator == "object" && navigator || void 0, on = ge && (!ue || ["ReactNative", "NativeScript", "NS"].indexOf(ue.product) < 0), sn = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
470
|
+
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", an = ge && window.location.href || "http://localhost", cn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
471
471
|
__proto__: null,
|
|
472
472
|
hasBrowserEnv: ge,
|
|
473
|
-
hasStandardBrowserEnv:
|
|
474
|
-
hasStandardBrowserWebWorkerEnv:
|
|
473
|
+
hasStandardBrowserEnv: on,
|
|
474
|
+
hasStandardBrowserWebWorkerEnv: sn,
|
|
475
475
|
navigator: ue,
|
|
476
|
-
origin:
|
|
477
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
478
|
-
...
|
|
479
|
-
...
|
|
476
|
+
origin: an
|
|
477
|
+
}, Symbol.toStringTag, { value: "Module" })), L = {
|
|
478
|
+
...cn,
|
|
479
|
+
...rn
|
|
480
480
|
};
|
|
481
|
-
function
|
|
482
|
-
return ne(e, new
|
|
481
|
+
function ln(e, t) {
|
|
482
|
+
return ne(e, new L.classes.URLSearchParams(), Object.assign({
|
|
483
483
|
visitor: function(r, n, o, s) {
|
|
484
|
-
return
|
|
484
|
+
return L.isNode && a.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : s.defaultVisitor.apply(this, arguments);
|
|
485
485
|
}
|
|
486
486
|
}, t));
|
|
487
487
|
}
|
|
488
|
-
function
|
|
488
|
+
function un(e) {
|
|
489
489
|
return a.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
|
|
490
490
|
}
|
|
491
|
-
function
|
|
491
|
+
function fn(e) {
|
|
492
492
|
const t = {}, r = Object.keys(e);
|
|
493
493
|
let n;
|
|
494
494
|
const o = r.length;
|
|
@@ -497,22 +497,22 @@ function un(e) {
|
|
|
497
497
|
s = r[n], t[s] = e[s];
|
|
498
498
|
return t;
|
|
499
499
|
}
|
|
500
|
-
function
|
|
500
|
+
function Xe(e) {
|
|
501
501
|
function t(r, n, o, s) {
|
|
502
502
|
let i = r[s++];
|
|
503
503
|
if (i === "__proto__") return !0;
|
|
504
504
|
const c = Number.isFinite(+i), f = s >= r.length;
|
|
505
|
-
return i = !i && a.isArray(o) ? o.length : i, f ? (a.hasOwnProp(o, i) ? o[i] = [o[i], n] : o[i] = n, !c) : ((!o[i] || !a.isObject(o[i])) && (o[i] = []), t(r, n, o[i], s) && a.isArray(o[i]) && (o[i] =
|
|
505
|
+
return i = !i && a.isArray(o) ? o.length : i, f ? (a.hasOwnProp(o, i) ? o[i] = [o[i], n] : o[i] = n, !c) : ((!o[i] || !a.isObject(o[i])) && (o[i] = []), t(r, n, o[i], s) && a.isArray(o[i]) && (o[i] = fn(o[i])), !c);
|
|
506
506
|
}
|
|
507
507
|
if (a.isFormData(e) && a.isFunction(e.entries)) {
|
|
508
508
|
const r = {};
|
|
509
509
|
return a.forEachEntry(e, (n, o) => {
|
|
510
|
-
t(
|
|
510
|
+
t(un(n), o, r, 0);
|
|
511
511
|
}), r;
|
|
512
512
|
}
|
|
513
513
|
return null;
|
|
514
514
|
}
|
|
515
|
-
function
|
|
515
|
+
function dn(e, t, r) {
|
|
516
516
|
if (a.isString(e))
|
|
517
517
|
try {
|
|
518
518
|
return (t || JSON.parse)(e), a.trim(e);
|
|
@@ -523,12 +523,12 @@ function fn(e, t, r) {
|
|
|
523
523
|
return (r || JSON.stringify)(e);
|
|
524
524
|
}
|
|
525
525
|
const V = {
|
|
526
|
-
transitional:
|
|
526
|
+
transitional: Ke,
|
|
527
527
|
adapter: ["xhr", "http", "fetch"],
|
|
528
528
|
transformRequest: [function(t, r) {
|
|
529
529
|
const n = r.getContentType() || "", o = n.indexOf("application/json") > -1, s = a.isObject(t);
|
|
530
530
|
if (s && a.isHTMLForm(t) && (t = new FormData(t)), a.isFormData(t))
|
|
531
|
-
return o ? JSON.stringify(
|
|
531
|
+
return o ? JSON.stringify(Xe(t)) : t;
|
|
532
532
|
if (a.isArrayBuffer(t) || a.isBuffer(t) || a.isStream(t) || a.isFile(t) || a.isBlob(t) || a.isReadableStream(t))
|
|
533
533
|
return t;
|
|
534
534
|
if (a.isArrayBufferView(t))
|
|
@@ -538,7 +538,7 @@ const V = {
|
|
|
538
538
|
let c;
|
|
539
539
|
if (s) {
|
|
540
540
|
if (n.indexOf("application/x-www-form-urlencoded") > -1)
|
|
541
|
-
return
|
|
541
|
+
return ln(t, this.formSerializer).toString();
|
|
542
542
|
if ((c = a.isFileList(t)) || n.indexOf("multipart/form-data") > -1) {
|
|
543
543
|
const f = this.env && this.env.FormData;
|
|
544
544
|
return ne(
|
|
@@ -548,7 +548,7 @@ const V = {
|
|
|
548
548
|
);
|
|
549
549
|
}
|
|
550
550
|
}
|
|
551
|
-
return s || o ? (r.setContentType("application/json", !1),
|
|
551
|
+
return s || o ? (r.setContentType("application/json", !1), dn(t)) : t;
|
|
552
552
|
}],
|
|
553
553
|
transformResponse: [function(t) {
|
|
554
554
|
const r = this.transitional || V.transitional, n = r && r.forcedJSONParsing, o = this.responseType === "json";
|
|
@@ -575,8 +575,8 @@ const V = {
|
|
|
575
575
|
maxContentLength: -1,
|
|
576
576
|
maxBodyLength: -1,
|
|
577
577
|
env: {
|
|
578
|
-
FormData:
|
|
579
|
-
Blob:
|
|
578
|
+
FormData: L.classes.FormData,
|
|
579
|
+
Blob: L.classes.Blob
|
|
580
580
|
},
|
|
581
581
|
validateStatus: function(t) {
|
|
582
582
|
return t >= 200 && t < 300;
|
|
@@ -591,7 +591,7 @@ const V = {
|
|
|
591
591
|
a.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
592
592
|
V.headers[e] = {};
|
|
593
593
|
});
|
|
594
|
-
const
|
|
594
|
+
const hn = a.toObjectSet([
|
|
595
595
|
"age",
|
|
596
596
|
"authorization",
|
|
597
597
|
"content-length",
|
|
@@ -609,12 +609,12 @@ const dn = a.toObjectSet([
|
|
|
609
609
|
"referer",
|
|
610
610
|
"retry-after",
|
|
611
611
|
"user-agent"
|
|
612
|
-
]),
|
|
612
|
+
]), pn = (e) => {
|
|
613
613
|
const t = {};
|
|
614
614
|
let r, n, o;
|
|
615
615
|
return e && e.split(`
|
|
616
616
|
`).forEach(function(i) {
|
|
617
|
-
o = i.indexOf(":"), r = i.substring(0, o).trim().toLowerCase(), n = i.substring(o + 1).trim(), !(!r || t[r] &&
|
|
617
|
+
o = i.indexOf(":"), r = i.substring(0, o).trim().toLowerCase(), n = i.substring(o + 1).trim(), !(!r || t[r] && hn[r]) && (r === "set-cookie" ? t[r] ? t[r].push(n) : t[r] = [n] : t[r] = t[r] ? t[r] + ", " + n : n);
|
|
618
618
|
}), t;
|
|
619
619
|
}, xe = Symbol("internals");
|
|
620
620
|
function H(e) {
|
|
@@ -623,14 +623,14 @@ function H(e) {
|
|
|
623
623
|
function K(e) {
|
|
624
624
|
return e === !1 || e == null ? e : a.isArray(e) ? e.map(K) : String(e);
|
|
625
625
|
}
|
|
626
|
-
function
|
|
626
|
+
function mn(e) {
|
|
627
627
|
const t = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
628
628
|
let n;
|
|
629
629
|
for (; n = r.exec(e); )
|
|
630
630
|
t[n[1]] = n[2];
|
|
631
631
|
return t;
|
|
632
632
|
}
|
|
633
|
-
const
|
|
633
|
+
const gn = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
634
634
|
function se(e, t, r, n, o) {
|
|
635
635
|
if (a.isFunction(n))
|
|
636
636
|
return n.call(this, t, r);
|
|
@@ -641,10 +641,10 @@ function se(e, t, r, n, o) {
|
|
|
641
641
|
return n.test(t);
|
|
642
642
|
}
|
|
643
643
|
}
|
|
644
|
-
function
|
|
644
|
+
function wn(e) {
|
|
645
645
|
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, n) => r.toUpperCase() + n);
|
|
646
646
|
}
|
|
647
|
-
function
|
|
647
|
+
function yn(e, t) {
|
|
648
648
|
const r = a.toCamelCase(" " + t);
|
|
649
649
|
["get", "set", "has"].forEach((n) => {
|
|
650
650
|
Object.defineProperty(e, n + r, {
|
|
@@ -671,8 +671,8 @@ let k = class {
|
|
|
671
671
|
const i = (c, f) => a.forEach(c, (l, u) => s(l, u, f));
|
|
672
672
|
if (a.isPlainObject(t) || t instanceof this.constructor)
|
|
673
673
|
i(t, r);
|
|
674
|
-
else if (a.isString(t) && (t = t.trim()) && !
|
|
675
|
-
i(
|
|
674
|
+
else if (a.isString(t) && (t = t.trim()) && !gn(t))
|
|
675
|
+
i(pn(t), r);
|
|
676
676
|
else if (a.isObject(t) && a.isIterable(t)) {
|
|
677
677
|
let c = {}, f, l;
|
|
678
678
|
for (const u of t) {
|
|
@@ -693,7 +693,7 @@ let k = class {
|
|
|
693
693
|
if (!r)
|
|
694
694
|
return o;
|
|
695
695
|
if (r === !0)
|
|
696
|
-
return
|
|
696
|
+
return mn(o);
|
|
697
697
|
if (a.isFunction(r))
|
|
698
698
|
return r.call(this, o, n);
|
|
699
699
|
if (a.isRegExp(r))
|
|
@@ -737,7 +737,7 @@ let k = class {
|
|
|
737
737
|
r[i] = K(o), delete r[s];
|
|
738
738
|
return;
|
|
739
739
|
}
|
|
740
|
-
const c = t ?
|
|
740
|
+
const c = t ? wn(s) : String(s).trim();
|
|
741
741
|
c !== s && delete r[s], r[c] = K(o), n[c] = !0;
|
|
742
742
|
}), this;
|
|
743
743
|
}
|
|
@@ -776,7 +776,7 @@ let k = class {
|
|
|
776
776
|
}).accessors, o = this.prototype;
|
|
777
777
|
function s(i) {
|
|
778
778
|
const c = H(i);
|
|
779
|
-
n[c] || (
|
|
779
|
+
n[c] || (yn(o, i), n[c] = !0);
|
|
780
780
|
}
|
|
781
781
|
return a.isArray(t) ? t.forEach(s) : s(t), this;
|
|
782
782
|
}
|
|
@@ -799,7 +799,7 @@ function ie(e, t) {
|
|
|
799
799
|
s = c.call(r, s, o.normalize(), t ? t.status : void 0);
|
|
800
800
|
}), o.normalize(), s;
|
|
801
801
|
}
|
|
802
|
-
function
|
|
802
|
+
function Ge(e) {
|
|
803
803
|
return !!(e && e.__CANCEL__);
|
|
804
804
|
}
|
|
805
805
|
function j(e, t, r) {
|
|
@@ -808,7 +808,7 @@ function j(e, t, r) {
|
|
|
808
808
|
a.inherits(j, g, {
|
|
809
809
|
__CANCEL__: !0
|
|
810
810
|
});
|
|
811
|
-
function
|
|
811
|
+
function Qe(e, t, r) {
|
|
812
812
|
const n = r.config.validateStatus;
|
|
813
813
|
!r.status || !n || n(r.status) ? e(r) : t(new g(
|
|
814
814
|
"Request failed with status code " + r.status,
|
|
@@ -818,11 +818,11 @@ function Ge(e, t, r) {
|
|
|
818
818
|
r
|
|
819
819
|
));
|
|
820
820
|
}
|
|
821
|
-
function
|
|
821
|
+
function bn(e) {
|
|
822
822
|
const t = /^([-+\w]{1,25})(:?\/\/|:)/.exec(e);
|
|
823
823
|
return t && t[1] || "";
|
|
824
824
|
}
|
|
825
|
-
function
|
|
825
|
+
function En(e, t) {
|
|
826
826
|
e = e || 10;
|
|
827
827
|
const r = new Array(e), n = new Array(e);
|
|
828
828
|
let o = 0, s = 0, i;
|
|
@@ -838,7 +838,7 @@ function bn(e, t) {
|
|
|
838
838
|
return b ? Math.round(y * 1e3 / b) : void 0;
|
|
839
839
|
};
|
|
840
840
|
}
|
|
841
|
-
function
|
|
841
|
+
function Sn(e, t) {
|
|
842
842
|
let r = 0, n = 1e3 / t, o, s;
|
|
843
843
|
const i = (l, u = Date.now()) => {
|
|
844
844
|
r = u, o = null, s && (clearTimeout(s), s = null), e.apply(null, l);
|
|
@@ -852,8 +852,8 @@ function En(e, t) {
|
|
|
852
852
|
}
|
|
853
853
|
const G = (e, t, r = 3) => {
|
|
854
854
|
let n = 0;
|
|
855
|
-
const o =
|
|
856
|
-
return
|
|
855
|
+
const o = En(50, 250);
|
|
856
|
+
return Sn((s) => {
|
|
857
857
|
const i = s.loaded, c = s.lengthComputable ? s.total : void 0, f = i - n, l = o(f), u = i <= c;
|
|
858
858
|
n = i;
|
|
859
859
|
const d = {
|
|
@@ -876,10 +876,10 @@ const G = (e, t, r = 3) => {
|
|
|
876
876
|
total: e,
|
|
877
877
|
loaded: n
|
|
878
878
|
}), t[1]];
|
|
879
|
-
},
|
|
880
|
-
new URL(
|
|
881
|
-
|
|
882
|
-
) : () => !0,
|
|
879
|
+
}, Le = (e) => (...t) => a.asap(() => e(...t)), Rn = L.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (r) => (r = new URL(r, L.origin), e.protocol === r.protocol && e.host === r.host && (t || e.port === r.port)))(
|
|
880
|
+
new URL(L.origin),
|
|
881
|
+
L.navigator && /(msie|trident)/i.test(L.navigator.userAgent)
|
|
882
|
+
) : () => !0, Tn = L.hasStandardBrowserEnv ? (
|
|
883
883
|
// Standard browser envs support document.cookie
|
|
884
884
|
{
|
|
885
885
|
write(e, t, r, n, o, s) {
|
|
@@ -906,17 +906,17 @@ const G = (e, t, r = 3) => {
|
|
|
906
906
|
}
|
|
907
907
|
}
|
|
908
908
|
);
|
|
909
|
-
function
|
|
909
|
+
function On(e) {
|
|
910
910
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(e);
|
|
911
911
|
}
|
|
912
|
-
function
|
|
912
|
+
function xn(e, t) {
|
|
913
913
|
return t ? e.replace(/\/?\/$/, "") + "/" + t.replace(/^\/+/, "") : e;
|
|
914
914
|
}
|
|
915
|
-
function
|
|
916
|
-
let n = !
|
|
917
|
-
return e && (n || r == !1) ?
|
|
915
|
+
function Ze(e, t, r) {
|
|
916
|
+
let n = !On(t);
|
|
917
|
+
return e && (n || r == !1) ? xn(e, t) : t;
|
|
918
918
|
}
|
|
919
|
-
const
|
|
919
|
+
const Pe = (e) => e instanceof k ? { ...e } : e;
|
|
920
920
|
function M(e, t) {
|
|
921
921
|
t = t || {};
|
|
922
922
|
const r = {};
|
|
@@ -974,37 +974,37 @@ function M(e, t) {
|
|
|
974
974
|
socketPath: i,
|
|
975
975
|
responseEncoding: i,
|
|
976
976
|
validateStatus: c,
|
|
977
|
-
headers: (l, u, d) => o(
|
|
977
|
+
headers: (l, u, d) => o(Pe(l), Pe(u), d, !0)
|
|
978
978
|
};
|
|
979
979
|
return a.forEach(Object.keys(Object.assign({}, e, t)), function(u) {
|
|
980
980
|
const d = f[u] || o, y = d(e[u], t[u], u);
|
|
981
981
|
a.isUndefined(y) && d !== c || (r[u] = y);
|
|
982
982
|
}), r;
|
|
983
983
|
}
|
|
984
|
-
const
|
|
984
|
+
const Ye = (e) => {
|
|
985
985
|
const t = M({}, e);
|
|
986
986
|
let { data: r, withXSRFToken: n, xsrfHeaderName: o, xsrfCookieName: s, headers: i, auth: c } = t;
|
|
987
|
-
t.headers = i = k.from(i), t.url =
|
|
987
|
+
t.headers = i = k.from(i), t.url = We(Ze(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), c && i.set(
|
|
988
988
|
"Authorization",
|
|
989
989
|
"Basic " + btoa((c.username || "") + ":" + (c.password ? unescape(encodeURIComponent(c.password)) : ""))
|
|
990
990
|
);
|
|
991
991
|
let f;
|
|
992
992
|
if (a.isFormData(r)) {
|
|
993
|
-
if (
|
|
993
|
+
if (L.hasStandardBrowserEnv || L.hasStandardBrowserWebWorkerEnv)
|
|
994
994
|
i.setContentType(void 0);
|
|
995
995
|
else if ((f = i.getContentType()) !== !1) {
|
|
996
996
|
const [l, ...u] = f ? f.split(";").map((d) => d.trim()).filter(Boolean) : [];
|
|
997
997
|
i.setContentType([l || "multipart/form-data", ...u].join("; "));
|
|
998
998
|
}
|
|
999
999
|
}
|
|
1000
|
-
if (
|
|
1001
|
-
const l = o && s &&
|
|
1000
|
+
if (L.hasStandardBrowserEnv && (n && a.isFunction(n) && (n = n(t)), n || n !== !1 && Rn(t.url))) {
|
|
1001
|
+
const l = o && s && Tn.read(s);
|
|
1002
1002
|
l && i.set(o, l);
|
|
1003
1003
|
}
|
|
1004
1004
|
return t;
|
|
1005
|
-
},
|
|
1005
|
+
}, An = typeof XMLHttpRequest < "u", Ln = An && function(e) {
|
|
1006
1006
|
return new Promise(function(r, n) {
|
|
1007
|
-
const o =
|
|
1007
|
+
const o = Ye(e);
|
|
1008
1008
|
let s = o.data;
|
|
1009
1009
|
const i = k.from(o.headers).normalize();
|
|
1010
1010
|
let { responseType: c, onUploadProgress: f, onDownloadProgress: l } = o, u, d, y, b, h;
|
|
@@ -1016,17 +1016,17 @@ const Ze = (e) => {
|
|
|
1016
1016
|
function E() {
|
|
1017
1017
|
if (!p)
|
|
1018
1018
|
return;
|
|
1019
|
-
const
|
|
1019
|
+
const T = k.from(
|
|
1020
1020
|
"getAllResponseHeaders" in p && p.getAllResponseHeaders()
|
|
1021
1021
|
), S = {
|
|
1022
1022
|
data: !c || c === "text" || c === "json" ? p.responseText : p.response,
|
|
1023
1023
|
status: p.status,
|
|
1024
1024
|
statusText: p.statusText,
|
|
1025
|
-
headers:
|
|
1025
|
+
headers: T,
|
|
1026
1026
|
config: e,
|
|
1027
1027
|
request: p
|
|
1028
1028
|
};
|
|
1029
|
-
|
|
1029
|
+
Qe(function(A) {
|
|
1030
1030
|
r(A), m();
|
|
1031
1031
|
}, function(A) {
|
|
1032
1032
|
n(A), m();
|
|
@@ -1040,7 +1040,7 @@ const Ze = (e) => {
|
|
|
1040
1040
|
n(new g("Network Error", g.ERR_NETWORK, e, p)), p = null;
|
|
1041
1041
|
}, p.ontimeout = function() {
|
|
1042
1042
|
let w = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
|
|
1043
|
-
const S = o.transitional ||
|
|
1043
|
+
const S = o.transitional || Ke;
|
|
1044
1044
|
o.timeoutErrorMessage && (w = o.timeoutErrorMessage), n(new g(
|
|
1045
1045
|
w,
|
|
1046
1046
|
S.clarifyTimeoutError ? g.ETIMEDOUT : g.ECONNABORTED,
|
|
@@ -1049,12 +1049,12 @@ const Ze = (e) => {
|
|
|
1049
1049
|
)), p = null;
|
|
1050
1050
|
}, s === void 0 && i.setContentType(null), "setRequestHeader" in p && a.forEach(i.toJSON(), function(w, S) {
|
|
1051
1051
|
p.setRequestHeader(S, w);
|
|
1052
|
-
}), a.isUndefined(o.withCredentials) || (p.withCredentials = !!o.withCredentials), c && c !== "json" && (p.responseType = o.responseType), l && ([y, h] = G(l, !0), p.addEventListener("progress", y)), f && p.upload && ([d, b] = G(f), p.upload.addEventListener("progress", d), p.upload.addEventListener("loadend", b)), (o.cancelToken || o.signal) && (u = (
|
|
1053
|
-
p && (n(!
|
|
1052
|
+
}), a.isUndefined(o.withCredentials) || (p.withCredentials = !!o.withCredentials), c && c !== "json" && (p.responseType = o.responseType), l && ([y, h] = G(l, !0), p.addEventListener("progress", y)), f && p.upload && ([d, b] = G(f), p.upload.addEventListener("progress", d), p.upload.addEventListener("loadend", b)), (o.cancelToken || o.signal) && (u = (T) => {
|
|
1053
|
+
p && (n(!T || T.type ? new j(null, e, p) : T), p.abort(), p = null);
|
|
1054
1054
|
}, o.cancelToken && o.cancelToken.subscribe(u), o.signal && (o.signal.aborted ? u() : o.signal.addEventListener("abort", u)));
|
|
1055
|
-
const
|
|
1056
|
-
if (
|
|
1057
|
-
n(new g("Unsupported protocol " +
|
|
1055
|
+
const O = bn(o.url);
|
|
1056
|
+
if (O && L.protocols.indexOf(O) === -1) {
|
|
1057
|
+
n(new g("Unsupported protocol " + O + ":", g.ERR_BAD_REQUEST, e));
|
|
1058
1058
|
return;
|
|
1059
1059
|
}
|
|
1060
1060
|
p.send(s || null);
|
|
@@ -1082,7 +1082,7 @@ const Ze = (e) => {
|
|
|
1082
1082
|
const { signal: f } = n;
|
|
1083
1083
|
return f.unsubscribe = () => a.asap(c), f;
|
|
1084
1084
|
}
|
|
1085
|
-
},
|
|
1085
|
+
}, kn = function* (e, t) {
|
|
1086
1086
|
let r = e.byteLength;
|
|
1087
1087
|
if (r < t) {
|
|
1088
1088
|
yield e;
|
|
@@ -1091,10 +1091,10 @@ const Ze = (e) => {
|
|
|
1091
1091
|
let n = 0, o;
|
|
1092
1092
|
for (; n < r; )
|
|
1093
1093
|
o = n + t, yield e.slice(n, o), n = o;
|
|
1094
|
-
},
|
|
1095
|
-
for await (const r of
|
|
1096
|
-
yield*
|
|
1097
|
-
},
|
|
1094
|
+
}, Cn = async function* (e, t) {
|
|
1095
|
+
for await (const r of Nn(e))
|
|
1096
|
+
yield* kn(r, t);
|
|
1097
|
+
}, Nn = async function* (e) {
|
|
1098
1098
|
if (e[Symbol.asyncIterator]) {
|
|
1099
1099
|
yield* e;
|
|
1100
1100
|
return;
|
|
@@ -1111,7 +1111,7 @@ const Ze = (e) => {
|
|
|
1111
1111
|
await t.cancel();
|
|
1112
1112
|
}
|
|
1113
1113
|
}, ke = (e, t, r, n) => {
|
|
1114
|
-
const o =
|
|
1114
|
+
const o = Cn(e, t);
|
|
1115
1115
|
let s = 0, i, c = (f) => {
|
|
1116
1116
|
i || (i = !0, n && n(f));
|
|
1117
1117
|
};
|
|
@@ -1139,15 +1139,15 @@ const Ze = (e) => {
|
|
|
1139
1139
|
}, {
|
|
1140
1140
|
highWaterMark: 2
|
|
1141
1141
|
});
|
|
1142
|
-
}, re = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function",
|
|
1142
|
+
}, re = typeof fetch == "function" && typeof Request == "function" && typeof Response == "function", et = re && typeof ReadableStream == "function", Dn = re && (typeof TextEncoder == "function" ? /* @__PURE__ */ ((e) => (t) => e.encode(t))(new TextEncoder()) : async (e) => new Uint8Array(await new Response(e).arrayBuffer())), tt = (e, ...t) => {
|
|
1143
1143
|
try {
|
|
1144
1144
|
return !!e(...t);
|
|
1145
1145
|
} catch {
|
|
1146
1146
|
return !1;
|
|
1147
1147
|
}
|
|
1148
|
-
},
|
|
1148
|
+
}, Bn = et && tt(() => {
|
|
1149
1149
|
let e = !1;
|
|
1150
|
-
const t = new Request(
|
|
1150
|
+
const t = new Request(L.origin, {
|
|
1151
1151
|
body: new ReadableStream(),
|
|
1152
1152
|
method: "POST",
|
|
1153
1153
|
get duplex() {
|
|
@@ -1155,7 +1155,7 @@ const Ze = (e) => {
|
|
|
1155
1155
|
}
|
|
1156
1156
|
}).headers.has("Content-Type");
|
|
1157
1157
|
return e && !t;
|
|
1158
|
-
}), Ce = 64 * 1024, fe =
|
|
1158
|
+
}), Ce = 64 * 1024, fe = et && tt(() => a.isReadableStream(new Response("").body)), Q = {
|
|
1159
1159
|
stream: fe && ((e) => e.body)
|
|
1160
1160
|
};
|
|
1161
1161
|
re && ((e) => {
|
|
@@ -1165,24 +1165,24 @@ re && ((e) => {
|
|
|
1165
1165
|
});
|
|
1166
1166
|
});
|
|
1167
1167
|
})(new Response());
|
|
1168
|
-
const
|
|
1168
|
+
const _n = async (e) => {
|
|
1169
1169
|
if (e == null)
|
|
1170
1170
|
return 0;
|
|
1171
1171
|
if (a.isBlob(e))
|
|
1172
1172
|
return e.size;
|
|
1173
1173
|
if (a.isSpecCompliantForm(e))
|
|
1174
|
-
return (await new Request(
|
|
1174
|
+
return (await new Request(L.origin, {
|
|
1175
1175
|
method: "POST",
|
|
1176
1176
|
body: e
|
|
1177
1177
|
}).arrayBuffer()).byteLength;
|
|
1178
1178
|
if (a.isArrayBufferView(e) || a.isArrayBuffer(e))
|
|
1179
1179
|
return e.byteLength;
|
|
1180
1180
|
if (a.isURLSearchParams(e) && (e = e + ""), a.isString(e))
|
|
1181
|
-
return (await
|
|
1182
|
-
},
|
|
1181
|
+
return (await Dn(e)).byteLength;
|
|
1182
|
+
}, Fn = async (e, t) => {
|
|
1183
1183
|
const r = a.toFiniteNumber(e.getContentLength());
|
|
1184
|
-
return r ??
|
|
1185
|
-
},
|
|
1184
|
+
return r ?? _n(t);
|
|
1185
|
+
}, qn = re && (async (e) => {
|
|
1186
1186
|
let {
|
|
1187
1187
|
url: t,
|
|
1188
1188
|
method: r,
|
|
@@ -1196,7 +1196,7 @@ const Bn = async (e) => {
|
|
|
1196
1196
|
headers: u,
|
|
1197
1197
|
withCredentials: d = "same-origin",
|
|
1198
1198
|
fetchOptions: y
|
|
1199
|
-
} =
|
|
1199
|
+
} = Ye(e);
|
|
1200
1200
|
l = l ? (l + "").toLowerCase() : "text";
|
|
1201
1201
|
let b = Pn([o, s && s.toAbortSignal()], i), h;
|
|
1202
1202
|
const m = b && b.unsubscribe && (() => {
|
|
@@ -1204,7 +1204,7 @@ const Bn = async (e) => {
|
|
|
1204
1204
|
});
|
|
1205
1205
|
let p;
|
|
1206
1206
|
try {
|
|
1207
|
-
if (f &&
|
|
1207
|
+
if (f && Bn && r !== "get" && r !== "head" && (p = await Fn(u, n)) !== 0) {
|
|
1208
1208
|
let S = new Request(t, {
|
|
1209
1209
|
method: "POST",
|
|
1210
1210
|
body: n,
|
|
@@ -1213,7 +1213,7 @@ const Bn = async (e) => {
|
|
|
1213
1213
|
if (a.isFormData(n) && (x = S.headers.get("content-type")) && u.setContentType(x), S.body) {
|
|
1214
1214
|
const [A, B] = Ae(
|
|
1215
1215
|
p,
|
|
1216
|
-
G(
|
|
1216
|
+
G(Le(f))
|
|
1217
1217
|
);
|
|
1218
1218
|
n = ke(S.body, Ce, A, B);
|
|
1219
1219
|
}
|
|
@@ -1229,32 +1229,32 @@ const Bn = async (e) => {
|
|
|
1229
1229
|
duplex: "half",
|
|
1230
1230
|
credentials: E ? d : void 0
|
|
1231
1231
|
});
|
|
1232
|
-
let
|
|
1233
|
-
const
|
|
1234
|
-
if (fe && (c ||
|
|
1232
|
+
let O = await fetch(h, y);
|
|
1233
|
+
const T = fe && (l === "stream" || l === "response");
|
|
1234
|
+
if (fe && (c || T && m)) {
|
|
1235
1235
|
const S = {};
|
|
1236
1236
|
["status", "statusText", "headers"].forEach((be) => {
|
|
1237
|
-
S[be] =
|
|
1237
|
+
S[be] = O[be];
|
|
1238
1238
|
});
|
|
1239
|
-
const x = a.toFiniteNumber(
|
|
1239
|
+
const x = a.toFiniteNumber(O.headers.get("content-length")), [A, B] = c && Ae(
|
|
1240
1240
|
x,
|
|
1241
|
-
G(
|
|
1241
|
+
G(Le(c), !0)
|
|
1242
1242
|
) || [];
|
|
1243
|
-
|
|
1244
|
-
ke(
|
|
1243
|
+
O = new Response(
|
|
1244
|
+
ke(O.body, Ce, A, () => {
|
|
1245
1245
|
B && B(), m && m();
|
|
1246
1246
|
}),
|
|
1247
1247
|
S
|
|
1248
1248
|
);
|
|
1249
1249
|
}
|
|
1250
1250
|
l = l || "text";
|
|
1251
|
-
let w = await Q[a.findKey(Q, l) || "text"](
|
|
1252
|
-
return !
|
|
1253
|
-
|
|
1251
|
+
let w = await Q[a.findKey(Q, l) || "text"](O, e);
|
|
1252
|
+
return !T && m && m(), await new Promise((S, x) => {
|
|
1253
|
+
Qe(S, x, {
|
|
1254
1254
|
data: w,
|
|
1255
|
-
headers: k.from(
|
|
1256
|
-
status:
|
|
1257
|
-
statusText:
|
|
1255
|
+
headers: k.from(O.headers),
|
|
1256
|
+
status: O.status,
|
|
1257
|
+
statusText: O.statusText,
|
|
1258
1258
|
config: e,
|
|
1259
1259
|
request: h
|
|
1260
1260
|
});
|
|
@@ -1268,9 +1268,9 @@ const Bn = async (e) => {
|
|
|
1268
1268
|
) : g.from(E, E && E.code, e, h);
|
|
1269
1269
|
}
|
|
1270
1270
|
}), de = {
|
|
1271
|
-
http:
|
|
1272
|
-
xhr:
|
|
1273
|
-
fetch:
|
|
1271
|
+
http: Gt,
|
|
1272
|
+
xhr: Ln,
|
|
1273
|
+
fetch: qn
|
|
1274
1274
|
};
|
|
1275
1275
|
a.forEach(de, (e, t) => {
|
|
1276
1276
|
if (e) {
|
|
@@ -1281,7 +1281,7 @@ a.forEach(de, (e, t) => {
|
|
|
1281
1281
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
1282
1282
|
}
|
|
1283
1283
|
});
|
|
1284
|
-
const Ne = (e) => `- ${e}`, Un = (e) => a.isFunction(e) || e === null || e === !1,
|
|
1284
|
+
const Ne = (e) => `- ${e}`, Un = (e) => a.isFunction(e) || e === null || e === !1, nt = {
|
|
1285
1285
|
getAdapter: (e) => {
|
|
1286
1286
|
e = a.isArray(e) ? e : [e];
|
|
1287
1287
|
const { length: t } = e;
|
|
@@ -1320,21 +1320,21 @@ function De(e) {
|
|
|
1320
1320
|
return ae(e), e.headers = k.from(e.headers), e.data = ie.call(
|
|
1321
1321
|
e,
|
|
1322
1322
|
e.transformRequest
|
|
1323
|
-
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1),
|
|
1323
|
+
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), nt.getAdapter(e.adapter || V.adapter)(e).then(function(n) {
|
|
1324
1324
|
return ae(e), n.data = ie.call(
|
|
1325
1325
|
e,
|
|
1326
1326
|
e.transformResponse,
|
|
1327
1327
|
n
|
|
1328
1328
|
), n.headers = k.from(n.headers), n;
|
|
1329
1329
|
}, function(n) {
|
|
1330
|
-
return
|
|
1330
|
+
return Ge(n) || (ae(e), n && n.response && (n.response.data = ie.call(
|
|
1331
1331
|
e,
|
|
1332
1332
|
e.transformResponse,
|
|
1333
1333
|
n.response
|
|
1334
1334
|
), n.response.headers = k.from(n.response.headers))), Promise.reject(n);
|
|
1335
1335
|
});
|
|
1336
1336
|
}
|
|
1337
|
-
const
|
|
1337
|
+
const rt = "1.10.0", oe = {};
|
|
1338
1338
|
["object", "boolean", "number", "function", "string", "symbol"].forEach((e, t) => {
|
|
1339
1339
|
oe[e] = function(n) {
|
|
1340
1340
|
return typeof n === e || "a" + (t < 1 ? "n " : " ") + e;
|
|
@@ -1343,7 +1343,7 @@ const nt = "1.10.0", oe = {};
|
|
|
1343
1343
|
const Be = {};
|
|
1344
1344
|
oe.transitional = function(t, r, n) {
|
|
1345
1345
|
function o(s, i) {
|
|
1346
|
-
return "[Axios v" +
|
|
1346
|
+
return "[Axios v" + rt + "] Transitional option '" + s + "'" + i + (n ? ". " + n : "");
|
|
1347
1347
|
}
|
|
1348
1348
|
return (s, i, c) => {
|
|
1349
1349
|
if (t === !1)
|
|
@@ -1362,7 +1362,7 @@ oe.transitional = function(t, r, n) {
|
|
|
1362
1362
|
oe.spelling = function(t) {
|
|
1363
1363
|
return (r, n) => (console.warn(`${n} is likely a misspelling of ${t}`), !0);
|
|
1364
1364
|
};
|
|
1365
|
-
function
|
|
1365
|
+
function In(e, t, r) {
|
|
1366
1366
|
if (typeof e != "object")
|
|
1367
1367
|
throw new g("options must be an object", g.ERR_BAD_OPTION_VALUE);
|
|
1368
1368
|
const n = Object.keys(e);
|
|
@@ -1380,10 +1380,10 @@ function qn(e, t, r) {
|
|
|
1380
1380
|
}
|
|
1381
1381
|
}
|
|
1382
1382
|
const X = {
|
|
1383
|
-
assertOptions:
|
|
1383
|
+
assertOptions: In,
|
|
1384
1384
|
validators: oe
|
|
1385
1385
|
}, N = X.validators;
|
|
1386
|
-
let
|
|
1386
|
+
let U = class {
|
|
1387
1387
|
constructor(t) {
|
|
1388
1388
|
this.defaults = t || {}, this.interceptors = {
|
|
1389
1389
|
request: new Oe(),
|
|
@@ -1479,12 +1479,12 @@ let q = class {
|
|
|
1479
1479
|
}
|
|
1480
1480
|
getUri(t) {
|
|
1481
1481
|
t = M(this.defaults, t);
|
|
1482
|
-
const r =
|
|
1483
|
-
return
|
|
1482
|
+
const r = Ze(t.baseURL, t.url, t.allowAbsoluteUrls);
|
|
1483
|
+
return We(r, t.params, t.paramsSerializer);
|
|
1484
1484
|
}
|
|
1485
1485
|
};
|
|
1486
1486
|
a.forEach(["delete", "get", "head", "options"], function(t) {
|
|
1487
|
-
|
|
1487
|
+
U.prototype[t] = function(r, n) {
|
|
1488
1488
|
return this.request(M(n || {}, {
|
|
1489
1489
|
method: t,
|
|
1490
1490
|
url: r,
|
|
@@ -1505,9 +1505,9 @@ a.forEach(["post", "put", "patch"], function(t) {
|
|
|
1505
1505
|
}));
|
|
1506
1506
|
};
|
|
1507
1507
|
}
|
|
1508
|
-
|
|
1508
|
+
U.prototype[t] = r(), U.prototype[t + "Form"] = r(!0);
|
|
1509
1509
|
});
|
|
1510
|
-
let
|
|
1510
|
+
let Mn = class ot {
|
|
1511
1511
|
constructor(t) {
|
|
1512
1512
|
if (typeof t != "function")
|
|
1513
1513
|
throw new TypeError("executor must be a function.");
|
|
@@ -1573,19 +1573,19 @@ let In = class rt {
|
|
|
1573
1573
|
static source() {
|
|
1574
1574
|
let t;
|
|
1575
1575
|
return {
|
|
1576
|
-
token: new
|
|
1576
|
+
token: new ot(function(o) {
|
|
1577
1577
|
t = o;
|
|
1578
1578
|
}),
|
|
1579
1579
|
cancel: t
|
|
1580
1580
|
};
|
|
1581
1581
|
}
|
|
1582
1582
|
};
|
|
1583
|
-
function
|
|
1583
|
+
function $n(e) {
|
|
1584
1584
|
return function(r) {
|
|
1585
1585
|
return e.apply(null, r);
|
|
1586
1586
|
};
|
|
1587
1587
|
}
|
|
1588
|
-
function
|
|
1588
|
+
function jn(e) {
|
|
1589
1589
|
return a.isObject(e) && e.isAxiosError === !0;
|
|
1590
1590
|
}
|
|
1591
1591
|
const he = {
|
|
@@ -1656,30 +1656,30 @@ const he = {
|
|
|
1656
1656
|
Object.entries(he).forEach(([e, t]) => {
|
|
1657
1657
|
he[t] = e;
|
|
1658
1658
|
});
|
|
1659
|
-
function
|
|
1660
|
-
const t = new
|
|
1661
|
-
return a.extend(r,
|
|
1662
|
-
return
|
|
1659
|
+
function st(e) {
|
|
1660
|
+
const t = new U(e), r = Fe(U.prototype.request, t);
|
|
1661
|
+
return a.extend(r, U.prototype, t, { allOwnKeys: !0 }), a.extend(r, t, null, { allOwnKeys: !0 }), r.create = function(o) {
|
|
1662
|
+
return st(M(e, o));
|
|
1663
1663
|
}, r;
|
|
1664
1664
|
}
|
|
1665
|
-
const R =
|
|
1666
|
-
R.Axios =
|
|
1665
|
+
const R = st(V);
|
|
1666
|
+
R.Axios = U;
|
|
1667
1667
|
R.CanceledError = j;
|
|
1668
|
-
R.CancelToken =
|
|
1669
|
-
R.isCancel =
|
|
1670
|
-
R.VERSION =
|
|
1668
|
+
R.CancelToken = Mn;
|
|
1669
|
+
R.isCancel = Ge;
|
|
1670
|
+
R.VERSION = rt;
|
|
1671
1671
|
R.toFormData = ne;
|
|
1672
1672
|
R.AxiosError = g;
|
|
1673
1673
|
R.Cancel = R.CanceledError;
|
|
1674
1674
|
R.all = function(t) {
|
|
1675
1675
|
return Promise.all(t);
|
|
1676
1676
|
};
|
|
1677
|
-
R.spread =
|
|
1678
|
-
R.isAxiosError =
|
|
1677
|
+
R.spread = $n;
|
|
1678
|
+
R.isAxiosError = jn;
|
|
1679
1679
|
R.mergeConfig = M;
|
|
1680
1680
|
R.AxiosHeaders = k;
|
|
1681
|
-
R.formToJSON = (e) =>
|
|
1682
|
-
R.getAdapter =
|
|
1681
|
+
R.formToJSON = (e) => Xe(a.isHTMLForm(e) ? new FormData(e) : e);
|
|
1682
|
+
R.getAdapter = nt.getAdapter;
|
|
1683
1683
|
R.HttpStatusCode = he;
|
|
1684
1684
|
R.default = R;
|
|
1685
1685
|
const {
|
|
@@ -1700,7 +1700,7 @@ const {
|
|
|
1700
1700
|
getAdapter: gr,
|
|
1701
1701
|
mergeConfig: wr
|
|
1702
1702
|
} = R;
|
|
1703
|
-
class
|
|
1703
|
+
class Hn {
|
|
1704
1704
|
/**
|
|
1705
1705
|
* 初始化 IndexedDB 管理器
|
|
1706
1706
|
* @param dbName 数据库名称
|
|
@@ -1875,7 +1875,7 @@ class jn {
|
|
|
1875
1875
|
});
|
|
1876
1876
|
}
|
|
1877
1877
|
}
|
|
1878
|
-
class
|
|
1878
|
+
class zn {
|
|
1879
1879
|
// 构造
|
|
1880
1880
|
constructor() {
|
|
1881
1881
|
}
|
|
@@ -1934,12 +1934,12 @@ class Hn {
|
|
|
1934
1934
|
localStorage.clear();
|
|
1935
1935
|
}
|
|
1936
1936
|
}
|
|
1937
|
-
function
|
|
1937
|
+
function vn() {
|
|
1938
1938
|
return typeof window < "u" && "indexedDB" in window && indexedDB !== null && indexedDB !== void 0;
|
|
1939
1939
|
}
|
|
1940
|
-
class
|
|
1940
|
+
class Jn {
|
|
1941
1941
|
constructor() {
|
|
1942
|
-
this.isInitialized = !1, this.indexedDBManager = new
|
|
1942
|
+
this.isInitialized = !1, this.indexedDBManager = new Hn("qlfyEcologicalLogin", "loginData");
|
|
1943
1943
|
}
|
|
1944
1944
|
async ensureInitialized() {
|
|
1945
1945
|
this.isInitialized || (await this.indexedDBManager.open(), this.isInitialized = !0);
|
|
@@ -1956,9 +1956,9 @@ class vn {
|
|
|
1956
1956
|
await this.ensureInitialized(), await this.indexedDBManager.delete(t);
|
|
1957
1957
|
}
|
|
1958
1958
|
}
|
|
1959
|
-
class
|
|
1959
|
+
class Vn {
|
|
1960
1960
|
constructor() {
|
|
1961
|
-
this.localStorageManager = new
|
|
1961
|
+
this.localStorageManager = new zn();
|
|
1962
1962
|
}
|
|
1963
1963
|
set(t, r) {
|
|
1964
1964
|
this.localStorageManager.set(t, r);
|
|
@@ -1970,11 +1970,11 @@ class Jn {
|
|
|
1970
1970
|
this.localStorageManager.remove(t);
|
|
1971
1971
|
}
|
|
1972
1972
|
}
|
|
1973
|
-
function
|
|
1974
|
-
return
|
|
1973
|
+
function Wn() {
|
|
1974
|
+
return vn() ? new Jn() : new Vn();
|
|
1975
1975
|
}
|
|
1976
1976
|
let I = "qlfyEcologicalLogin_";
|
|
1977
|
-
const we =
|
|
1977
|
+
const we = Wn();
|
|
1978
1978
|
async function _(e) {
|
|
1979
1979
|
I.indexOf(e.props.clientId) == -1 && (I += e.props.clientId);
|
|
1980
1980
|
const t = we.set(I, e);
|
|
@@ -1998,7 +1998,7 @@ async function D(e) {
|
|
|
1998
1998
|
userPermission: {}
|
|
1999
1999
|
};
|
|
2000
2000
|
}
|
|
2001
|
-
async function
|
|
2001
|
+
async function _e(e = !0, t, r) {
|
|
2002
2002
|
let n = await D();
|
|
2003
2003
|
const o = n.props;
|
|
2004
2004
|
if (o.openDebugger)
|
|
@@ -2062,7 +2062,7 @@ async function Gn() {
|
|
|
2062
2062
|
return console.error("未配置应用id或应用密钥!"), "";
|
|
2063
2063
|
if (!t.loginPageBaseAddress)
|
|
2064
2064
|
return console.error("未配置登录页基础地址!"), "";
|
|
2065
|
-
let r = await
|
|
2065
|
+
let r = await it(["token", "refreshToken"], !1), n = t.redirectUrl || encodeURIComponent(r);
|
|
2066
2066
|
return `${t.loginPageBaseAddress}/#/login?clientId=${t.clientId}&clientSecret=${t.clientSecret}&redirectUrl=${n}`;
|
|
2067
2067
|
}
|
|
2068
2068
|
function Qn() {
|
|
@@ -2073,7 +2073,7 @@ function Qn() {
|
|
|
2073
2073
|
}
|
|
2074
2074
|
return "history";
|
|
2075
2075
|
}
|
|
2076
|
-
async function
|
|
2076
|
+
async function it(e, t = !1, r = window.location.href, n) {
|
|
2077
2077
|
if (n || (n = (await D()).routerMode), !["hash", "history"].includes(n))
|
|
2078
2078
|
throw new Error('路由模式必须是 "hash" 或 "history"');
|
|
2079
2079
|
let o, s, i;
|
|
@@ -2127,7 +2127,7 @@ function Zn(e) {
|
|
|
2127
2127
|
return typeof window < "u" && ((i = window.location) != null && i.hash) && window.location.hash !== "#" ? "hash" : "";
|
|
2128
2128
|
})().toLowerCase() === "hash";
|
|
2129
2129
|
}
|
|
2130
|
-
const
|
|
2130
|
+
const at = /* @__PURE__ */ ct({
|
|
2131
2131
|
__name: "index",
|
|
2132
2132
|
props: {
|
|
2133
2133
|
clientId: {},
|
|
@@ -2150,7 +2150,7 @@ const it = /* @__PURE__ */ at({
|
|
|
2150
2150
|
let c = !0, f = null, l = null, u = !1, d = null;
|
|
2151
2151
|
t({
|
|
2152
2152
|
// 退出统一登陆
|
|
2153
|
-
logout: async () => await
|
|
2153
|
+
logout: async () => await _e(),
|
|
2154
2154
|
// 获取统一登录token
|
|
2155
2155
|
getToken: async () => await Kn(),
|
|
2156
2156
|
// 获取登录信息
|
|
@@ -2161,11 +2161,11 @@ const it = /* @__PURE__ */ at({
|
|
|
2161
2161
|
// refreshToken,
|
|
2162
2162
|
}), o.beforeEach(async (w, S, x) => {
|
|
2163
2163
|
n.forceMode && !u ? (n.showLog && console.log("【qlfyEcologicalLogin】【路由拦截中】等待登陆放行..."), d = z(w.query), (u || await E()) && (n.showLog && console.log("【qlfyEcologicalLogin】【路由拦截中】登陆成功路由放行"), d = null, delete w.query.token, delete w.query.refreshToken, x(w))) : x();
|
|
2164
|
-
}),
|
|
2164
|
+
}), lt(() => {
|
|
2165
2165
|
}), Ee(
|
|
2166
2166
|
() => s.value.path,
|
|
2167
2167
|
(w, S) => {
|
|
2168
|
-
f && clearTimeout(f),
|
|
2168
|
+
f && clearTimeout(f), ut(() => {
|
|
2169
2169
|
f = setTimeout(() => {
|
|
2170
2170
|
n.isEnabled && y();
|
|
2171
2171
|
}, 300);
|
|
@@ -2184,7 +2184,7 @@ const it = /* @__PURE__ */ at({
|
|
|
2184
2184
|
async function y() {
|
|
2185
2185
|
if (n.openDebugger)
|
|
2186
2186
|
debugger;
|
|
2187
|
-
n.isEnabled && (l = await D(n.clientId), await
|
|
2187
|
+
n.isEnabled && (l = await D(n.clientId), await O(), b());
|
|
2188
2188
|
}
|
|
2189
2189
|
async function b() {
|
|
2190
2190
|
if (n.showLog && console.log("【qlfyEcologicalLogin】登陆流程执行..."), n.token) {
|
|
@@ -2192,7 +2192,7 @@ const it = /* @__PURE__ */ at({
|
|
|
2192
2192
|
return;
|
|
2193
2193
|
}
|
|
2194
2194
|
if ((s.value.query.token || d != null && d.token) && c) {
|
|
2195
|
-
n.showLog && console.log("【qlfyEcologicalLogin】读取链接中的token"), l.token = s.value.query.token || (d == null ? void 0 : d.token), l.refreshToken = s.value.query.refreshToken, await _(l), await
|
|
2195
|
+
n.showLog && console.log("【qlfyEcologicalLogin】读取链接中的token"), l.token = s.value.query.token || (d == null ? void 0 : d.token), l.refreshToken = s.value.query.refreshToken, await _(l), await T(), c && i("loggingIn", l.token), m(l.token, c), c = !1;
|
|
2196
2196
|
return;
|
|
2197
2197
|
}
|
|
2198
2198
|
const w = l.token;
|
|
@@ -2242,7 +2242,12 @@ const it = /* @__PURE__ */ at({
|
|
|
2242
2242
|
i("loginFail", { message: "用户配置获取失败" }), u = !1;
|
|
2243
2243
|
return;
|
|
2244
2244
|
}
|
|
2245
|
-
n.showLog && console.log("【qlfyEcologicalLogin】用户配置获取成功"),
|
|
2245
|
+
if (n.showLog && console.log("【qlfyEcologicalLogin】用户配置获取成功"), !A.data.menus.length) {
|
|
2246
|
+
if (n.showLog && console.log("【qlfyEcologicalLogin】本账号无菜单访问权限"), await T(), n.forceMode) return _e();
|
|
2247
|
+
i("loginFail", { message: "token无效失效" }), u = !1;
|
|
2248
|
+
return;
|
|
2249
|
+
}
|
|
2250
|
+
l.userPermission = A.data, await _(l), await T(), i("loginSuccess", z(l.userPermission)), u = !0;
|
|
2246
2251
|
}).catch((A) => {
|
|
2247
2252
|
if (n.showLog && console.log("【qlfyEcologicalLogin】用户配置数据获取失败"), n.forceMode) return F();
|
|
2248
2253
|
i("loginFail", { message: "用户配置获取失败", data: A }), u = !1;
|
|
@@ -2258,20 +2263,20 @@ const it = /* @__PURE__ */ at({
|
|
|
2258
2263
|
}, 1e4);
|
|
2259
2264
|
});
|
|
2260
2265
|
}
|
|
2261
|
-
async function
|
|
2266
|
+
async function O() {
|
|
2262
2267
|
const w = { ...n };
|
|
2263
2268
|
delete w.useRouter, l.props = z(w), l.routerMode = Zn(o) ? "hash" : "history", await _(l);
|
|
2264
2269
|
}
|
|
2265
|
-
async function
|
|
2266
|
-
await
|
|
2270
|
+
async function T() {
|
|
2271
|
+
await it(["token", "refreshToken"], !0);
|
|
2267
2272
|
let w = z(s.value.query);
|
|
2268
2273
|
delete w.token, delete w.refreshToken, o.currentRoute.value.query = w;
|
|
2269
2274
|
}
|
|
2270
2275
|
return (w, S) => null;
|
|
2271
2276
|
}
|
|
2272
|
-
}), Er =
|
|
2277
|
+
}), Er = at, Sr = {
|
|
2273
2278
|
install(e) {
|
|
2274
|
-
e.component("qlfyEcologicalLogin",
|
|
2279
|
+
e.component("qlfyEcologicalLogin", at);
|
|
2275
2280
|
}
|
|
2276
2281
|
};
|
|
2277
2282
|
export {
|
|
@@ -2281,6 +2286,6 @@ export {
|
|
|
2281
2286
|
Kn as getToken,
|
|
2282
2287
|
yr as getUserPermission,
|
|
2283
2288
|
F as goLogin,
|
|
2284
|
-
|
|
2289
|
+
_e as logout,
|
|
2285
2290
|
Er as qlfyEcologicalLogin
|
|
2286
2291
|
};
|