leadal-portal-base 0.0.11 → 0.0.13
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/dist/index.cjs.js +8 -8
- package/dist/index.esm.js +1183 -663
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -7,16 +7,16 @@ function hr(e, t) {
|
|
|
7
7
|
const { toString: tn } = Object.prototype, { getPrototypeOf: Ze } = Object, { iterator: Te, toStringTag: pr } = Symbol, Re = /* @__PURE__ */ ((e) => (t) => {
|
|
8
8
|
const r = tn.call(t);
|
|
9
9
|
return e[r] || (e[r] = r.slice(8, -1).toLowerCase());
|
|
10
|
-
})(/* @__PURE__ */ Object.create(null)),
|
|
10
|
+
})(/* @__PURE__ */ Object.create(null)), c0 = (e) => (e = e.toLowerCase(), (t) => Re(t) === e), Oe = (e) => (t) => typeof t === e, { isArray: w0 } = Array, g0 = Oe("undefined");
|
|
11
11
|
function q0(e) {
|
|
12
|
-
return e !== null && !g0(e) && e.constructor !== null && !g0(e.constructor) &&
|
|
12
|
+
return e !== null && !g0(e) && e.constructor !== null && !g0(e.constructor) && t0(e.constructor.isBuffer) && e.constructor.isBuffer(e);
|
|
13
13
|
}
|
|
14
|
-
const vr =
|
|
14
|
+
const vr = c0("ArrayBuffer");
|
|
15
15
|
function rn(e) {
|
|
16
16
|
let t;
|
|
17
17
|
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && vr(e.buffer), t;
|
|
18
18
|
}
|
|
19
|
-
const nn = Oe("string"),
|
|
19
|
+
const nn = Oe("string"), t0 = Oe("function"), Er = Oe("number"), N0 = (e) => e !== null && typeof e == "object", on = (e) => e === !0 || e === !1, $0 = (e) => {
|
|
20
20
|
if (Re(e) !== "object")
|
|
21
21
|
return !1;
|
|
22
22
|
const t = Ze(e);
|
|
@@ -29,16 +29,16 @@ const nn = Oe("string"), e0 = Oe("function"), Er = Oe("number"), N0 = (e) => e !
|
|
|
29
29
|
} catch {
|
|
30
30
|
return !1;
|
|
31
31
|
}
|
|
32
|
-
}, sn =
|
|
32
|
+
}, sn = c0("Date"), xn = c0("File"), cn = c0("Blob"), fn = c0("FileList"), ln = (e) => N0(e) && t0(e.pipe), un = (e) => {
|
|
33
33
|
let t;
|
|
34
|
-
return e && (typeof FormData == "function" && e instanceof FormData ||
|
|
35
|
-
t === "object" &&
|
|
36
|
-
}, dn =
|
|
34
|
+
return e && (typeof FormData == "function" && e instanceof FormData || t0(e.append) && ((t = Re(e)) === "formdata" || // detect form-data instance
|
|
35
|
+
t === "object" && t0(e.toString) && e.toString() === "[object FormData]"));
|
|
36
|
+
}, dn = c0("URLSearchParams"), [hn, pn, vn, En] = ["ReadableStream", "Request", "Response", "Headers"].map(c0), Bn = (e) => e.trim ? e.trim() : e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
|
|
37
37
|
function L0(e, t, { allOwnKeys: r = !1 } = {}) {
|
|
38
38
|
if (e === null || typeof e > "u")
|
|
39
39
|
return;
|
|
40
40
|
let n, o;
|
|
41
|
-
if (typeof e != "object" && (e = [e]),
|
|
41
|
+
if (typeof e != "object" && (e = [e]), w0(e))
|
|
42
42
|
for (n = 0, o = e.length; n < o; n++)
|
|
43
43
|
t.call(null, e[n], n, e);
|
|
44
44
|
else {
|
|
@@ -65,14 +65,14 @@ const p0 = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typ
|
|
|
65
65
|
function Me() {
|
|
66
66
|
const { caseless: e, skipUndefined: t } = Cr(this) && this || {}, r = {}, n = (o, a) => {
|
|
67
67
|
const x = e && Br(r, a) || a;
|
|
68
|
-
$0(r[x]) && $0(o) ? r[x] = Me(r[x], o) : $0(o) ? r[x] = Me({}, o) :
|
|
68
|
+
$0(r[x]) && $0(o) ? r[x] = Me(r[x], o) : $0(o) ? r[x] = Me({}, o) : w0(o) ? r[x] = o.slice() : (!t || !g0(o)) && (r[x] = o);
|
|
69
69
|
};
|
|
70
70
|
for (let o = 0, a = arguments.length; o < a; o++)
|
|
71
71
|
arguments[o] && L0(arguments[o], n);
|
|
72
72
|
return r;
|
|
73
73
|
}
|
|
74
74
|
const Cn = (e, t, r, { allOwnKeys: n } = {}) => (L0(t, (o, a) => {
|
|
75
|
-
r &&
|
|
75
|
+
r && t0(o) ? e[a] = hr(o, r) : e[a] = o;
|
|
76
76
|
}, { allOwnKeys: n }), e), An = (e) => (e.charCodeAt(0) === 65279 && (e = e.slice(1)), e), mn = (e, t, r, n) => {
|
|
77
77
|
e.prototype = Object.create(t.prototype, n), e.prototype.constructor = e, Object.defineProperty(e, "super", {
|
|
78
78
|
value: t.prototype
|
|
@@ -93,32 +93,32 @@ const Cn = (e, t, r, { allOwnKeys: n } = {}) => (L0(t, (o, a) => {
|
|
|
93
93
|
return n !== -1 && n === r;
|
|
94
94
|
}, gn = (e) => {
|
|
95
95
|
if (!e) return null;
|
|
96
|
-
if (
|
|
96
|
+
if (w0(e)) return e;
|
|
97
97
|
let t = e.length;
|
|
98
98
|
if (!Er(t)) return null;
|
|
99
99
|
const r = new Array(t);
|
|
100
100
|
for (; t-- > 0; )
|
|
101
101
|
r[t] = e[t];
|
|
102
102
|
return r;
|
|
103
|
-
},
|
|
103
|
+
}, wn = /* @__PURE__ */ ((e) => (t) => e && t instanceof e)(typeof Uint8Array < "u" && Ze(Uint8Array)), bn = (e, t) => {
|
|
104
104
|
const n = (e && e[Te]).call(e);
|
|
105
105
|
let o;
|
|
106
106
|
for (; (o = n.next()) && !o.done; ) {
|
|
107
107
|
const a = o.value;
|
|
108
108
|
t.call(e, a[0], a[1]);
|
|
109
109
|
}
|
|
110
|
-
},
|
|
110
|
+
}, Dn = (e, t) => {
|
|
111
111
|
let r;
|
|
112
112
|
const n = [];
|
|
113
113
|
for (; (r = e.exec(t)) !== null; )
|
|
114
114
|
n.push(r);
|
|
115
115
|
return n;
|
|
116
|
-
}, _n =
|
|
116
|
+
}, _n = c0("HTMLFormElement"), Sn = (e) => e.toLowerCase().replace(
|
|
117
117
|
/[-_\s]([a-z\d])(\w*)/g,
|
|
118
118
|
function(r, n, o) {
|
|
119
119
|
return n.toUpperCase() + o;
|
|
120
120
|
}
|
|
121
|
-
), pt = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), kn =
|
|
121
|
+
), pt = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), kn = c0("RegExp"), Ar = (e, t) => {
|
|
122
122
|
const r = Object.getOwnPropertyDescriptors(e), n = {};
|
|
123
123
|
L0(r, (o, a) => {
|
|
124
124
|
let x;
|
|
@@ -126,10 +126,10 @@ const Cn = (e, t, r, { allOwnKeys: n } = {}) => (L0(t, (o, a) => {
|
|
|
126
126
|
}), Object.defineProperties(e, n);
|
|
127
127
|
}, Tn = (e) => {
|
|
128
128
|
Ar(e, (t, r) => {
|
|
129
|
-
if (
|
|
129
|
+
if (t0(e) && ["arguments", "caller", "callee"].indexOf(r) !== -1)
|
|
130
130
|
return !1;
|
|
131
131
|
const n = e[r];
|
|
132
|
-
if (
|
|
132
|
+
if (t0(n)) {
|
|
133
133
|
if (t.enumerable = !1, "writable" in t) {
|
|
134
134
|
t.writable = !1;
|
|
135
135
|
return;
|
|
@@ -145,11 +145,11 @@ const Cn = (e, t, r, { allOwnKeys: n } = {}) => (L0(t, (o, a) => {
|
|
|
145
145
|
r[a] = !0;
|
|
146
146
|
});
|
|
147
147
|
};
|
|
148
|
-
return
|
|
148
|
+
return w0(e) ? n(e) : n(String(e).split(t)), r;
|
|
149
149
|
}, On = () => {
|
|
150
150
|
}, Hn = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
|
|
151
151
|
function Pn(e) {
|
|
152
|
-
return !!(e &&
|
|
152
|
+
return !!(e && t0(e.append) && e[pr] === "FormData" && e[Te]);
|
|
153
153
|
}
|
|
154
154
|
const qn = (e) => {
|
|
155
155
|
const t = new Array(10), r = (n, o) => {
|
|
@@ -160,7 +160,7 @@ const qn = (e) => {
|
|
|
160
160
|
return n;
|
|
161
161
|
if (!("toJSON" in n)) {
|
|
162
162
|
t[o] = n;
|
|
163
|
-
const a =
|
|
163
|
+
const a = w0(n) ? [] : {};
|
|
164
164
|
return L0(n, (x, f) => {
|
|
165
165
|
const v = r(x, o + 1);
|
|
166
166
|
!g0(v) && (a[f] = v);
|
|
@@ -170,15 +170,15 @@ const qn = (e) => {
|
|
|
170
170
|
return n;
|
|
171
171
|
};
|
|
172
172
|
return r(e, 0);
|
|
173
|
-
}, Nn =
|
|
173
|
+
}, Nn = c0("AsyncFunction"), Ln = (e) => e && (N0(e) || t0(e)) && t0(e.then) && t0(e.catch), mr = ((e, t) => e ? setImmediate : t ? ((r, n) => (p0.addEventListener("message", ({ source: o, data: a }) => {
|
|
174
174
|
o === p0 && a === r && n.length && n.shift()();
|
|
175
175
|
}, !1), (o) => {
|
|
176
176
|
n.push(o), p0.postMessage(r, "*");
|
|
177
177
|
}))(`axios@${Math.random()}`, []) : (r) => setTimeout(r))(
|
|
178
178
|
typeof setImmediate == "function",
|
|
179
|
-
|
|
180
|
-
), zn = typeof queueMicrotask < "u" ? queueMicrotask.bind(p0) : typeof process < "u" && process.nextTick || mr, Un = (e) => e != null &&
|
|
181
|
-
isArray:
|
|
179
|
+
t0(p0.postMessage)
|
|
180
|
+
), zn = typeof queueMicrotask < "u" ? queueMicrotask.bind(p0) : typeof process < "u" && process.nextTick || mr, Un = (e) => e != null && t0(e[Te]), w = {
|
|
181
|
+
isArray: w0,
|
|
182
182
|
isArrayBuffer: vr,
|
|
183
183
|
isBuffer: q0,
|
|
184
184
|
isFormData: un,
|
|
@@ -198,10 +198,10 @@ const qn = (e) => {
|
|
|
198
198
|
isFile: xn,
|
|
199
199
|
isBlob: cn,
|
|
200
200
|
isRegExp: kn,
|
|
201
|
-
isFunction:
|
|
201
|
+
isFunction: t0,
|
|
202
202
|
isStream: ln,
|
|
203
203
|
isURLSearchParams: dn,
|
|
204
|
-
isTypedArray:
|
|
204
|
+
isTypedArray: wn,
|
|
205
205
|
isFileList: fn,
|
|
206
206
|
forEach: L0,
|
|
207
207
|
merge: Me,
|
|
@@ -211,11 +211,11 @@ const qn = (e) => {
|
|
|
211
211
|
inherits: mn,
|
|
212
212
|
toFlatObject: Fn,
|
|
213
213
|
kindOf: Re,
|
|
214
|
-
kindOfTest:
|
|
214
|
+
kindOfTest: c0,
|
|
215
215
|
endsWith: yn,
|
|
216
216
|
toArray: gn,
|
|
217
|
-
forEachEntry:
|
|
218
|
-
matchAll:
|
|
217
|
+
forEachEntry: bn,
|
|
218
|
+
matchAll: Dn,
|
|
219
219
|
isHTMLForm: _n,
|
|
220
220
|
hasOwnProperty: pt,
|
|
221
221
|
hasOwnProp: pt,
|
|
@@ -240,7 +240,7 @@ const qn = (e) => {
|
|
|
240
240
|
function L(e, t, r, n, o) {
|
|
241
241
|
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);
|
|
242
242
|
}
|
|
243
|
-
|
|
243
|
+
w.inherits(L, Error, {
|
|
244
244
|
toJSON: function() {
|
|
245
245
|
return {
|
|
246
246
|
// Standard
|
|
@@ -255,7 +255,7 @@ b.inherits(L, Error, {
|
|
|
255
255
|
columnNumber: this.columnNumber,
|
|
256
256
|
stack: this.stack,
|
|
257
257
|
// Axios
|
|
258
|
-
config:
|
|
258
|
+
config: w.toJSONObject(this.config),
|
|
259
259
|
code: this.code,
|
|
260
260
|
status: this.status
|
|
261
261
|
};
|
|
@@ -283,7 +283,7 @@ Object.defineProperties(L, yr);
|
|
|
283
283
|
Object.defineProperty(Fr, "isAxiosError", { value: !0 });
|
|
284
284
|
L.from = (e, t, r, n, o, a) => {
|
|
285
285
|
const x = Object.create(Fr);
|
|
286
|
-
|
|
286
|
+
w.toFlatObject(e, x, function(s) {
|
|
287
287
|
return s !== Error.prototype;
|
|
288
288
|
}, (i) => i !== "isAxiosError");
|
|
289
289
|
const f = e && e.message ? e.message : "Error", v = t == null && e ? e.code : t;
|
|
@@ -291,10 +291,10 @@ L.from = (e, t, r, n, o, a) => {
|
|
|
291
291
|
};
|
|
292
292
|
const In = null;
|
|
293
293
|
function Ke(e) {
|
|
294
|
-
return
|
|
294
|
+
return w.isPlainObject(e) || w.isArray(e);
|
|
295
295
|
}
|
|
296
296
|
function gr(e) {
|
|
297
|
-
return
|
|
297
|
+
return w.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
298
298
|
}
|
|
299
299
|
function vt(e, t, r) {
|
|
300
300
|
return e ? e.concat(t).map(function(o, a) {
|
|
@@ -302,42 +302,42 @@ function vt(e, t, r) {
|
|
|
302
302
|
}).join(r ? "." : "") : t;
|
|
303
303
|
}
|
|
304
304
|
function jn(e) {
|
|
305
|
-
return
|
|
305
|
+
return w.isArray(e) && !e.some(Ke);
|
|
306
306
|
}
|
|
307
|
-
const Wn =
|
|
307
|
+
const Wn = w.toFlatObject(w, {}, null, function(t) {
|
|
308
308
|
return /^is[A-Z]/.test(t);
|
|
309
309
|
});
|
|
310
310
|
function He(e, t, r) {
|
|
311
|
-
if (!
|
|
311
|
+
if (!w.isObject(e))
|
|
312
312
|
throw new TypeError("target must be an object");
|
|
313
|
-
t = t || new FormData(), r =
|
|
313
|
+
t = t || new FormData(), r = w.toFlatObject(r, {
|
|
314
314
|
metaTokens: !0,
|
|
315
315
|
dots: !1,
|
|
316
316
|
indexes: !1
|
|
317
317
|
}, !1, function(p, u) {
|
|
318
|
-
return !
|
|
318
|
+
return !w.isUndefined(u[p]);
|
|
319
319
|
});
|
|
320
|
-
const n = r.metaTokens, o = r.visitor || s, a = r.dots, x = r.indexes, v = (r.Blob || typeof Blob < "u" && Blob) &&
|
|
321
|
-
if (!
|
|
320
|
+
const n = r.metaTokens, o = r.visitor || s, a = r.dots, x = r.indexes, v = (r.Blob || typeof Blob < "u" && Blob) && w.isSpecCompliantForm(t);
|
|
321
|
+
if (!w.isFunction(o))
|
|
322
322
|
throw new TypeError("visitor must be a function");
|
|
323
323
|
function i(c) {
|
|
324
324
|
if (c === null) return "";
|
|
325
|
-
if (
|
|
325
|
+
if (w.isDate(c))
|
|
326
326
|
return c.toISOString();
|
|
327
|
-
if (
|
|
327
|
+
if (w.isBoolean(c))
|
|
328
328
|
return c.toString();
|
|
329
|
-
if (!v &&
|
|
329
|
+
if (!v && w.isBlob(c))
|
|
330
330
|
throw new L("Blob is not supported. Use a Buffer instead.");
|
|
331
|
-
return
|
|
331
|
+
return w.isArrayBuffer(c) || w.isTypedArray(c) ? v && typeof Blob == "function" ? new Blob([c]) : Buffer.from(c) : c;
|
|
332
332
|
}
|
|
333
333
|
function s(c, p, u) {
|
|
334
334
|
let A = c;
|
|
335
335
|
if (c && !u && typeof c == "object") {
|
|
336
|
-
if (
|
|
336
|
+
if (w.endsWith(p, "{}"))
|
|
337
337
|
p = n ? p : p.slice(0, -2), c = JSON.stringify(c);
|
|
338
|
-
else if (
|
|
338
|
+
else if (w.isArray(c) && jn(c) || (w.isFileList(c) || w.endsWith(p, "[]")) && (A = w.toArray(c)))
|
|
339
339
|
return p = gr(p), A.forEach(function(d, C) {
|
|
340
|
-
!(
|
|
340
|
+
!(w.isUndefined(d) || d === null) && t.append(
|
|
341
341
|
// eslint-disable-next-line no-nested-ternary
|
|
342
342
|
x === !0 ? vt([p], C, a) : x === null ? p : p + "[]",
|
|
343
343
|
i(d)
|
|
@@ -352,21 +352,21 @@ function He(e, t, r) {
|
|
|
352
352
|
isVisitable: Ke
|
|
353
353
|
});
|
|
354
354
|
function E(c, p) {
|
|
355
|
-
if (!
|
|
355
|
+
if (!w.isUndefined(c)) {
|
|
356
356
|
if (B.indexOf(c) !== -1)
|
|
357
357
|
throw Error("Circular reference detected in " + p.join("."));
|
|
358
|
-
B.push(c),
|
|
359
|
-
(!(
|
|
358
|
+
B.push(c), w.forEach(c, function(A, h) {
|
|
359
|
+
(!(w.isUndefined(A) || A === null) && o.call(
|
|
360
360
|
t,
|
|
361
361
|
A,
|
|
362
|
-
|
|
362
|
+
w.isString(h) ? h.trim() : h,
|
|
363
363
|
p,
|
|
364
364
|
l
|
|
365
365
|
)) === !0 && E(A, p ? p.concat(h) : [h]);
|
|
366
366
|
}), B.pop();
|
|
367
367
|
}
|
|
368
368
|
}
|
|
369
|
-
if (!
|
|
369
|
+
if (!w.isObject(e))
|
|
370
370
|
throw new TypeError("data must be an object");
|
|
371
371
|
return E(e), t;
|
|
372
372
|
}
|
|
@@ -387,11 +387,11 @@ function Et(e) {
|
|
|
387
387
|
function Je(e, t) {
|
|
388
388
|
this._pairs = [], e && He(e, this, t);
|
|
389
389
|
}
|
|
390
|
-
const
|
|
391
|
-
|
|
390
|
+
const wr = Je.prototype;
|
|
391
|
+
wr.append = function(t, r) {
|
|
392
392
|
this._pairs.push([t, r]);
|
|
393
393
|
};
|
|
394
|
-
|
|
394
|
+
wr.toString = function(t) {
|
|
395
395
|
const r = t ? function(n) {
|
|
396
396
|
return t.call(this, n, Et);
|
|
397
397
|
} : Et;
|
|
@@ -402,16 +402,16 @@ br.toString = function(t) {
|
|
|
402
402
|
function $n(e) {
|
|
403
403
|
return encodeURIComponent(e).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+");
|
|
404
404
|
}
|
|
405
|
-
function
|
|
405
|
+
function br(e, t, r) {
|
|
406
406
|
if (!t)
|
|
407
407
|
return e;
|
|
408
408
|
const n = r && r.encode || $n;
|
|
409
|
-
|
|
409
|
+
w.isFunction(r) && (r = {
|
|
410
410
|
serialize: r
|
|
411
411
|
});
|
|
412
412
|
const o = r && r.serialize;
|
|
413
413
|
let a;
|
|
414
|
-
if (o ? a = o(t, r) : a =
|
|
414
|
+
if (o ? a = o(t, r) : a = w.isURLSearchParams(t) ? t.toString() : new Je(t, r).toString(n), a) {
|
|
415
415
|
const x = e.indexOf("#");
|
|
416
416
|
x !== -1 && (e = e.slice(0, x)), e += (e.indexOf("?") === -1 ? "?" : "&") + a;
|
|
417
417
|
}
|
|
@@ -466,16 +466,16 @@ class Bt {
|
|
|
466
466
|
* @returns {void}
|
|
467
467
|
*/
|
|
468
468
|
forEach(t) {
|
|
469
|
-
|
|
469
|
+
w.forEach(this.handlers, function(n) {
|
|
470
470
|
n !== null && t(n);
|
|
471
471
|
});
|
|
472
472
|
}
|
|
473
473
|
}
|
|
474
|
-
const
|
|
474
|
+
const Dr = {
|
|
475
475
|
silentJSONParsing: !0,
|
|
476
476
|
forcedJSONParsing: !0,
|
|
477
477
|
clarifyTimeoutError: !1
|
|
478
|
-
}, Mn = typeof URLSearchParams < "u" ? URLSearchParams : Je, Kn = typeof FormData < "u" ? FormData : null, Xn = typeof Blob < "u" ? Blob : null,
|
|
478
|
+
}, Mn = typeof URLSearchParams < "u" ? URLSearchParams : Je, Kn = typeof FormData < "u" ? FormData : null, Xn = typeof Blob < "u" ? Blob : null, Vn = {
|
|
479
479
|
isBrowser: !0,
|
|
480
480
|
classes: {
|
|
481
481
|
URLSearchParams: Mn,
|
|
@@ -483,28 +483,28 @@ const wr = {
|
|
|
483
483
|
Blob: Xn
|
|
484
484
|
},
|
|
485
485
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
486
|
-
}, Ye = typeof window < "u" && typeof document < "u", Xe = typeof navigator == "object" && navigator || void 0,
|
|
486
|
+
}, Ye = typeof window < "u" && typeof document < "u", Xe = typeof navigator == "object" && navigator || void 0, Gn = Ye && (!Xe || ["ReactNative", "NativeScript", "NS"].indexOf(Xe.product) < 0), Qn = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
487
487
|
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", Zn = Ye && window.location.href || "http://localhost", Jn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
488
488
|
__proto__: null,
|
|
489
489
|
hasBrowserEnv: Ye,
|
|
490
|
-
hasStandardBrowserEnv:
|
|
490
|
+
hasStandardBrowserEnv: Gn,
|
|
491
491
|
hasStandardBrowserWebWorkerEnv: Qn,
|
|
492
492
|
navigator: Xe,
|
|
493
493
|
origin: Zn
|
|
494
494
|
}, Symbol.toStringTag, { value: "Module" })), Q = {
|
|
495
495
|
...Jn,
|
|
496
|
-
...
|
|
496
|
+
...Vn
|
|
497
497
|
};
|
|
498
498
|
function Yn(e, t) {
|
|
499
499
|
return He(e, new Q.classes.URLSearchParams(), {
|
|
500
500
|
visitor: function(r, n, o, a) {
|
|
501
|
-
return Q.isNode &&
|
|
501
|
+
return Q.isNode && w.isBuffer(r) ? (this.append(n, r.toString("base64")), !1) : a.defaultVisitor.apply(this, arguments);
|
|
502
502
|
},
|
|
503
503
|
...t
|
|
504
504
|
});
|
|
505
505
|
}
|
|
506
506
|
function eo(e) {
|
|
507
|
-
return
|
|
507
|
+
return w.matchAll(/\w+|\[(\w*)]/g, e).map((t) => t[0] === "[]" ? "" : t[1] || t[0]);
|
|
508
508
|
}
|
|
509
509
|
function to(e) {
|
|
510
510
|
const t = {}, r = Object.keys(e);
|
|
@@ -520,20 +520,20 @@ function _r(e) {
|
|
|
520
520
|
let x = r[a++];
|
|
521
521
|
if (x === "__proto__") return !0;
|
|
522
522
|
const f = Number.isFinite(+x), v = a >= r.length;
|
|
523
|
-
return x = !x &&
|
|
523
|
+
return x = !x && w.isArray(o) ? o.length : x, v ? (w.hasOwnProp(o, x) ? o[x] = [o[x], n] : o[x] = n, !f) : ((!o[x] || !w.isObject(o[x])) && (o[x] = []), t(r, n, o[x], a) && w.isArray(o[x]) && (o[x] = to(o[x])), !f);
|
|
524
524
|
}
|
|
525
|
-
if (
|
|
525
|
+
if (w.isFormData(e) && w.isFunction(e.entries)) {
|
|
526
526
|
const r = {};
|
|
527
|
-
return
|
|
527
|
+
return w.forEachEntry(e, (n, o) => {
|
|
528
528
|
t(eo(n), o, r, 0);
|
|
529
529
|
}), r;
|
|
530
530
|
}
|
|
531
531
|
return null;
|
|
532
532
|
}
|
|
533
533
|
function ro(e, t, r) {
|
|
534
|
-
if (
|
|
534
|
+
if (w.isString(e))
|
|
535
535
|
try {
|
|
536
|
-
return (t || JSON.parse)(e),
|
|
536
|
+
return (t || JSON.parse)(e), w.trim(e);
|
|
537
537
|
} catch (n) {
|
|
538
538
|
if (n.name !== "SyntaxError")
|
|
539
539
|
throw n;
|
|
@@ -541,23 +541,23 @@ function ro(e, t, r) {
|
|
|
541
541
|
return (r || JSON.stringify)(e);
|
|
542
542
|
}
|
|
543
543
|
const z0 = {
|
|
544
|
-
transitional:
|
|
544
|
+
transitional: Dr,
|
|
545
545
|
adapter: ["xhr", "http", "fetch"],
|
|
546
546
|
transformRequest: [function(t, r) {
|
|
547
|
-
const n = r.getContentType() || "", o = n.indexOf("application/json") > -1, a =
|
|
548
|
-
if (a &&
|
|
547
|
+
const n = r.getContentType() || "", o = n.indexOf("application/json") > -1, a = w.isObject(t);
|
|
548
|
+
if (a && w.isHTMLForm(t) && (t = new FormData(t)), w.isFormData(t))
|
|
549
549
|
return o ? JSON.stringify(_r(t)) : t;
|
|
550
|
-
if (
|
|
550
|
+
if (w.isArrayBuffer(t) || w.isBuffer(t) || w.isStream(t) || w.isFile(t) || w.isBlob(t) || w.isReadableStream(t))
|
|
551
551
|
return t;
|
|
552
|
-
if (
|
|
552
|
+
if (w.isArrayBufferView(t))
|
|
553
553
|
return t.buffer;
|
|
554
|
-
if (
|
|
554
|
+
if (w.isURLSearchParams(t))
|
|
555
555
|
return r.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), t.toString();
|
|
556
556
|
let f;
|
|
557
557
|
if (a) {
|
|
558
558
|
if (n.indexOf("application/x-www-form-urlencoded") > -1)
|
|
559
559
|
return Yn(t, this.formSerializer).toString();
|
|
560
|
-
if ((f =
|
|
560
|
+
if ((f = w.isFileList(t)) || n.indexOf("multipart/form-data") > -1) {
|
|
561
561
|
const v = this.env && this.env.FormData;
|
|
562
562
|
return He(
|
|
563
563
|
f ? { "files[]": t } : t,
|
|
@@ -570,9 +570,9 @@ const z0 = {
|
|
|
570
570
|
}],
|
|
571
571
|
transformResponse: [function(t) {
|
|
572
572
|
const r = this.transitional || z0.transitional, n = r && r.forcedJSONParsing, o = this.responseType === "json";
|
|
573
|
-
if (
|
|
573
|
+
if (w.isResponse(t) || w.isReadableStream(t))
|
|
574
574
|
return t;
|
|
575
|
-
if (t &&
|
|
575
|
+
if (t && w.isString(t) && (n && !this.responseType || o)) {
|
|
576
576
|
const x = !(r && r.silentJSONParsing) && o;
|
|
577
577
|
try {
|
|
578
578
|
return JSON.parse(t, this.parseReviver);
|
|
@@ -606,10 +606,10 @@ const z0 = {
|
|
|
606
606
|
}
|
|
607
607
|
}
|
|
608
608
|
};
|
|
609
|
-
|
|
609
|
+
w.forEach(["delete", "get", "head", "post", "put", "patch"], (e) => {
|
|
610
610
|
z0.headers[e] = {};
|
|
611
611
|
});
|
|
612
|
-
const no =
|
|
612
|
+
const no = w.toObjectSet([
|
|
613
613
|
"age",
|
|
614
614
|
"authorization",
|
|
615
615
|
"content-length",
|
|
@@ -639,7 +639,7 @@ function H0(e) {
|
|
|
639
639
|
return e && String(e).trim().toLowerCase();
|
|
640
640
|
}
|
|
641
641
|
function M0(e) {
|
|
642
|
-
return e === !1 || e == null ? e :
|
|
642
|
+
return e === !1 || e == null ? e : w.isArray(e) ? e.map(M0) : String(e);
|
|
643
643
|
}
|
|
644
644
|
function ao(e) {
|
|
645
645
|
const t = /* @__PURE__ */ Object.create(null), r = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
@@ -650,12 +650,12 @@ function ao(e) {
|
|
|
650
650
|
}
|
|
651
651
|
const io = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
652
652
|
function Ie(e, t, r, n, o) {
|
|
653
|
-
if (
|
|
653
|
+
if (w.isFunction(n))
|
|
654
654
|
return n.call(this, t, r);
|
|
655
|
-
if (o && (t = r), !!
|
|
656
|
-
if (
|
|
655
|
+
if (o && (t = r), !!w.isString(t)) {
|
|
656
|
+
if (w.isString(n))
|
|
657
657
|
return t.indexOf(n) !== -1;
|
|
658
|
-
if (
|
|
658
|
+
if (w.isRegExp(n))
|
|
659
659
|
return n.test(t);
|
|
660
660
|
}
|
|
661
661
|
}
|
|
@@ -663,7 +663,7 @@ function so(e) {
|
|
|
663
663
|
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, n) => r.toUpperCase() + n);
|
|
664
664
|
}
|
|
665
665
|
function xo(e, t) {
|
|
666
|
-
const r =
|
|
666
|
+
const r = w.toCamelCase(" " + t);
|
|
667
667
|
["get", "set", "has"].forEach((n) => {
|
|
668
668
|
Object.defineProperty(e, n + r, {
|
|
669
669
|
value: function(o, a, x) {
|
|
@@ -673,7 +673,7 @@ function xo(e, t) {
|
|
|
673
673
|
});
|
|
674
674
|
});
|
|
675
675
|
}
|
|
676
|
-
let
|
|
676
|
+
let r0 = class {
|
|
677
677
|
constructor(t) {
|
|
678
678
|
t && this.set(t);
|
|
679
679
|
}
|
|
@@ -683,20 +683,20 @@ let t0 = class {
|
|
|
683
683
|
const s = H0(v);
|
|
684
684
|
if (!s)
|
|
685
685
|
throw new Error("header name must be a non-empty string");
|
|
686
|
-
const B =
|
|
686
|
+
const B = w.findKey(o, s);
|
|
687
687
|
(!B || o[B] === void 0 || i === !0 || i === void 0 && o[B] !== !1) && (o[B || v] = M0(f));
|
|
688
688
|
}
|
|
689
|
-
const x = (f, v) =>
|
|
690
|
-
if (
|
|
689
|
+
const x = (f, v) => w.forEach(f, (i, s) => a(i, s, v));
|
|
690
|
+
if (w.isPlainObject(t) || t instanceof this.constructor)
|
|
691
691
|
x(t, r);
|
|
692
|
-
else if (
|
|
692
|
+
else if (w.isString(t) && (t = t.trim()) && !io(t))
|
|
693
693
|
x(oo(t), r);
|
|
694
|
-
else if (
|
|
694
|
+
else if (w.isObject(t) && w.isIterable(t)) {
|
|
695
695
|
let f = {}, v, i;
|
|
696
696
|
for (const s of t) {
|
|
697
|
-
if (!
|
|
697
|
+
if (!w.isArray(s))
|
|
698
698
|
throw TypeError("Object iterator must return a key-value pair");
|
|
699
|
-
f[i = s[0]] = (v = f[i]) ?
|
|
699
|
+
f[i = s[0]] = (v = f[i]) ? w.isArray(v) ? [...v, s[1]] : [v, s[1]] : s[1];
|
|
700
700
|
}
|
|
701
701
|
x(f, r);
|
|
702
702
|
} else
|
|
@@ -705,16 +705,16 @@ let t0 = class {
|
|
|
705
705
|
}
|
|
706
706
|
get(t, r) {
|
|
707
707
|
if (t = H0(t), t) {
|
|
708
|
-
const n =
|
|
708
|
+
const n = w.findKey(this, t);
|
|
709
709
|
if (n) {
|
|
710
710
|
const o = this[n];
|
|
711
711
|
if (!r)
|
|
712
712
|
return o;
|
|
713
713
|
if (r === !0)
|
|
714
714
|
return ao(o);
|
|
715
|
-
if (
|
|
715
|
+
if (w.isFunction(r))
|
|
716
716
|
return r.call(this, o, n);
|
|
717
|
-
if (
|
|
717
|
+
if (w.isRegExp(r))
|
|
718
718
|
return r.exec(o);
|
|
719
719
|
throw new TypeError("parser must be boolean|regexp|function");
|
|
720
720
|
}
|
|
@@ -722,7 +722,7 @@ let t0 = class {
|
|
|
722
722
|
}
|
|
723
723
|
has(t, r) {
|
|
724
724
|
if (t = H0(t), t) {
|
|
725
|
-
const n =
|
|
725
|
+
const n = w.findKey(this, t);
|
|
726
726
|
return !!(n && this[n] !== void 0 && (!r || Ie(this, this[n], n, r)));
|
|
727
727
|
}
|
|
728
728
|
return !1;
|
|
@@ -732,11 +732,11 @@ let t0 = class {
|
|
|
732
732
|
let o = !1;
|
|
733
733
|
function a(x) {
|
|
734
734
|
if (x = H0(x), x) {
|
|
735
|
-
const f =
|
|
735
|
+
const f = w.findKey(n, x);
|
|
736
736
|
f && (!r || Ie(n, n[f], f, r)) && (delete n[f], o = !0);
|
|
737
737
|
}
|
|
738
738
|
}
|
|
739
|
-
return
|
|
739
|
+
return w.isArray(t) ? t.forEach(a) : a(t), o;
|
|
740
740
|
}
|
|
741
741
|
clear(t) {
|
|
742
742
|
const r = Object.keys(this);
|
|
@@ -749,8 +749,8 @@ let t0 = class {
|
|
|
749
749
|
}
|
|
750
750
|
normalize(t) {
|
|
751
751
|
const r = this, n = {};
|
|
752
|
-
return
|
|
753
|
-
const x =
|
|
752
|
+
return w.forEach(this, (o, a) => {
|
|
753
|
+
const x = w.findKey(n, a);
|
|
754
754
|
if (x) {
|
|
755
755
|
r[x] = M0(o), delete r[a];
|
|
756
756
|
return;
|
|
@@ -764,8 +764,8 @@ let t0 = class {
|
|
|
764
764
|
}
|
|
765
765
|
toJSON(t) {
|
|
766
766
|
const r = /* @__PURE__ */ Object.create(null);
|
|
767
|
-
return
|
|
768
|
-
n != null && n !== !1 && (r[o] = t &&
|
|
767
|
+
return w.forEach(this, (n, o) => {
|
|
768
|
+
n != null && n !== !1 && (r[o] = t && w.isArray(n) ? n.join(", ") : n);
|
|
769
769
|
}), r;
|
|
770
770
|
}
|
|
771
771
|
[Symbol.iterator]() {
|
|
@@ -796,11 +796,11 @@ let t0 = class {
|
|
|
796
796
|
const f = H0(x);
|
|
797
797
|
n[f] || (xo(o, x), n[f] = !0);
|
|
798
798
|
}
|
|
799
|
-
return
|
|
799
|
+
return w.isArray(t) ? t.forEach(a) : a(t), this;
|
|
800
800
|
}
|
|
801
801
|
};
|
|
802
|
-
|
|
803
|
-
|
|
802
|
+
r0.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
|
|
803
|
+
w.reduceDescriptors(r0.prototype, ({ value: e }, t) => {
|
|
804
804
|
let r = t[0].toUpperCase() + t.slice(1);
|
|
805
805
|
return {
|
|
806
806
|
get: () => e,
|
|
@@ -809,21 +809,21 @@ b.reduceDescriptors(t0.prototype, ({ value: e }, t) => {
|
|
|
809
809
|
}
|
|
810
810
|
};
|
|
811
811
|
});
|
|
812
|
-
|
|
812
|
+
w.freezeMethods(r0);
|
|
813
813
|
function je(e, t) {
|
|
814
|
-
const r = this || z0, n = t || r, o =
|
|
814
|
+
const r = this || z0, n = t || r, o = r0.from(n.headers);
|
|
815
815
|
let a = n.data;
|
|
816
|
-
return
|
|
816
|
+
return w.forEach(e, function(f) {
|
|
817
817
|
a = f.call(r, a, o.normalize(), t ? t.status : void 0);
|
|
818
818
|
}), o.normalize(), a;
|
|
819
819
|
}
|
|
820
820
|
function Sr(e) {
|
|
821
821
|
return !!(e && e.__CANCEL__);
|
|
822
822
|
}
|
|
823
|
-
function
|
|
823
|
+
function b0(e, t, r) {
|
|
824
824
|
L.call(this, e ?? "canceled", L.ERR_CANCELED, t, r), this.name = "CanceledError";
|
|
825
825
|
}
|
|
826
|
-
|
|
826
|
+
w.inherits(b0, L, {
|
|
827
827
|
__CANCEL__: !0
|
|
828
828
|
});
|
|
829
829
|
function kr(e, t, r) {
|
|
@@ -894,7 +894,7 @@ const Se = (e, t, r = 3) => {
|
|
|
894
894
|
total: e,
|
|
895
895
|
loaded: n
|
|
896
896
|
}), t[1]];
|
|
897
|
-
}, mt = (e) => (...t) =>
|
|
897
|
+
}, mt = (e) => (...t) => w.asap(() => e(...t)), uo = Q.hasStandardBrowserEnv ? /* @__PURE__ */ ((e, t) => (r) => (r = new URL(r, Q.origin), e.protocol === r.protocol && e.host === r.host && (t || e.port === r.port)))(
|
|
898
898
|
new URL(Q.origin),
|
|
899
899
|
Q.navigator && /(msie|trident)/i.test(Q.navigator.userAgent)
|
|
900
900
|
) : () => !0, ho = Q.hasStandardBrowserEnv ? (
|
|
@@ -902,7 +902,7 @@ const Se = (e, t, r = 3) => {
|
|
|
902
902
|
{
|
|
903
903
|
write(e, t, r, n, o, a) {
|
|
904
904
|
const x = [e + "=" + encodeURIComponent(t)];
|
|
905
|
-
|
|
905
|
+
w.isNumber(r) && x.push("expires=" + new Date(r).toGMTString()), w.isString(n) && x.push("path=" + n), w.isString(o) && x.push("domain=" + o), a === !0 && x.push("secure"), document.cookie = x.join("; ");
|
|
906
906
|
},
|
|
907
907
|
read(e) {
|
|
908
908
|
const t = document.cookie.match(new RegExp("(^|;\\s*)(" + e + ")=([^;]*)"));
|
|
@@ -934,26 +934,26 @@ function Tr(e, t, r) {
|
|
|
934
934
|
let n = !po(t);
|
|
935
935
|
return e && (n || r == !1) ? vo(e, t) : t;
|
|
936
936
|
}
|
|
937
|
-
const Ft = (e) => e instanceof
|
|
937
|
+
const Ft = (e) => e instanceof r0 ? { ...e } : e;
|
|
938
938
|
function E0(e, t) {
|
|
939
939
|
t = t || {};
|
|
940
940
|
const r = {};
|
|
941
941
|
function n(i, s, B, l) {
|
|
942
|
-
return
|
|
942
|
+
return w.isPlainObject(i) && w.isPlainObject(s) ? w.merge.call({ caseless: l }, i, s) : w.isPlainObject(s) ? w.merge({}, s) : w.isArray(s) ? s.slice() : s;
|
|
943
943
|
}
|
|
944
944
|
function o(i, s, B, l) {
|
|
945
|
-
if (
|
|
946
|
-
if (!
|
|
945
|
+
if (w.isUndefined(s)) {
|
|
946
|
+
if (!w.isUndefined(i))
|
|
947
947
|
return n(void 0, i, B, l);
|
|
948
948
|
} else return n(i, s, B, l);
|
|
949
949
|
}
|
|
950
950
|
function a(i, s) {
|
|
951
|
-
if (!
|
|
951
|
+
if (!w.isUndefined(s))
|
|
952
952
|
return n(void 0, s);
|
|
953
953
|
}
|
|
954
954
|
function x(i, s) {
|
|
955
|
-
if (
|
|
956
|
-
if (!
|
|
955
|
+
if (w.isUndefined(s)) {
|
|
956
|
+
if (!w.isUndefined(i))
|
|
957
957
|
return n(void 0, i);
|
|
958
958
|
} else return n(void 0, s);
|
|
959
959
|
}
|
|
@@ -994,28 +994,28 @@ function E0(e, t) {
|
|
|
994
994
|
validateStatus: f,
|
|
995
995
|
headers: (i, s, B) => o(Ft(i), Ft(s), B, !0)
|
|
996
996
|
};
|
|
997
|
-
return
|
|
997
|
+
return w.forEach(Object.keys({ ...e, ...t }), function(s) {
|
|
998
998
|
const B = v[s] || o, l = B(e[s], t[s], s);
|
|
999
|
-
|
|
999
|
+
w.isUndefined(l) && B !== f || (r[s] = l);
|
|
1000
1000
|
}), r;
|
|
1001
1001
|
}
|
|
1002
1002
|
const Rr = (e) => {
|
|
1003
1003
|
const t = E0({}, e);
|
|
1004
1004
|
let { data: r, withXSRFToken: n, xsrfHeaderName: o, xsrfCookieName: a, headers: x, auth: f } = t;
|
|
1005
|
-
if (t.headers = x =
|
|
1005
|
+
if (t.headers = x = r0.from(x), t.url = br(Tr(t.baseURL, t.url, t.allowAbsoluteUrls), e.params, e.paramsSerializer), f && x.set(
|
|
1006
1006
|
"Authorization",
|
|
1007
1007
|
"Basic " + btoa((f.username || "") + ":" + (f.password ? unescape(encodeURIComponent(f.password)) : ""))
|
|
1008
|
-
),
|
|
1008
|
+
), w.isFormData(r)) {
|
|
1009
1009
|
if (Q.hasStandardBrowserEnv || Q.hasStandardBrowserWebWorkerEnv)
|
|
1010
1010
|
x.setContentType(void 0);
|
|
1011
|
-
else if (
|
|
1011
|
+
else if (w.isFunction(r.getHeaders)) {
|
|
1012
1012
|
const v = r.getHeaders(), i = ["content-type", "content-length"];
|
|
1013
1013
|
Object.entries(v).forEach(([s, B]) => {
|
|
1014
1014
|
i.includes(s.toLowerCase()) && x.set(s, B);
|
|
1015
1015
|
});
|
|
1016
1016
|
}
|
|
1017
1017
|
}
|
|
1018
|
-
if (Q.hasStandardBrowserEnv && (n &&
|
|
1018
|
+
if (Q.hasStandardBrowserEnv && (n && w.isFunction(n) && (n = n(t)), n || n !== !1 && uo(t.url))) {
|
|
1019
1019
|
const v = o && a && ho.read(a);
|
|
1020
1020
|
v && x.set(o, v);
|
|
1021
1021
|
}
|
|
@@ -1024,7 +1024,7 @@ const Rr = (e) => {
|
|
|
1024
1024
|
return new Promise(function(r, n) {
|
|
1025
1025
|
const o = Rr(e);
|
|
1026
1026
|
let a = o.data;
|
|
1027
|
-
const x =
|
|
1027
|
+
const x = r0.from(o.headers).normalize();
|
|
1028
1028
|
let { responseType: f, onUploadProgress: v, onDownloadProgress: i } = o, s, B, l, E, c;
|
|
1029
1029
|
function p() {
|
|
1030
1030
|
E && E(), c && c(), o.cancelToken && o.cancelToken.unsubscribe(s), o.signal && o.signal.removeEventListener("abort", s);
|
|
@@ -1034,7 +1034,7 @@ const Rr = (e) => {
|
|
|
1034
1034
|
function A() {
|
|
1035
1035
|
if (!u)
|
|
1036
1036
|
return;
|
|
1037
|
-
const d =
|
|
1037
|
+
const d = r0.from(
|
|
1038
1038
|
"getAllResponseHeaders" in u && u.getAllResponseHeaders()
|
|
1039
1039
|
), F = {
|
|
1040
1040
|
data: !f || f === "text" || f === "json" ? u.responseText : u.response,
|
|
@@ -1059,17 +1059,17 @@ const Rr = (e) => {
|
|
|
1059
1059
|
y.event = C || null, n(y), u = null;
|
|
1060
1060
|
}, u.ontimeout = function() {
|
|
1061
1061
|
let C = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
|
|
1062
|
-
const F = o.transitional ||
|
|
1062
|
+
const F = o.transitional || Dr;
|
|
1063
1063
|
o.timeoutErrorMessage && (C = o.timeoutErrorMessage), n(new L(
|
|
1064
1064
|
C,
|
|
1065
1065
|
F.clarifyTimeoutError ? L.ETIMEDOUT : L.ECONNABORTED,
|
|
1066
1066
|
e,
|
|
1067
1067
|
u
|
|
1068
1068
|
)), u = null;
|
|
1069
|
-
}, a === void 0 && x.setContentType(null), "setRequestHeader" in u &&
|
|
1069
|
+
}, a === void 0 && x.setContentType(null), "setRequestHeader" in u && w.forEach(x.toJSON(), function(C, F) {
|
|
1070
1070
|
u.setRequestHeader(F, C);
|
|
1071
|
-
}),
|
|
1072
|
-
u && (n(!d || d.type ? new
|
|
1071
|
+
}), w.isUndefined(o.withCredentials) || (u.withCredentials = !!o.withCredentials), f && f !== "json" && (u.responseType = o.responseType), i && ([l, c] = Se(i, !0), u.addEventListener("progress", l)), v && u.upload && ([B, E] = Se(v), u.upload.addEventListener("progress", B), u.upload.addEventListener("loadend", E)), (o.cancelToken || o.signal) && (s = (d) => {
|
|
1072
|
+
u && (n(!d || d.type ? new b0(null, e, u) : d), u.abort(), u = null);
|
|
1073
1073
|
}, o.cancelToken && o.cancelToken.subscribe(s), o.signal && (o.signal.aborted ? s() : o.signal.addEventListener("abort", s)));
|
|
1074
1074
|
const h = co(o.url);
|
|
1075
1075
|
if (h && Q.protocols.indexOf(h) === -1) {
|
|
@@ -1086,7 +1086,7 @@ const Rr = (e) => {
|
|
|
1086
1086
|
if (!o) {
|
|
1087
1087
|
o = !0, f();
|
|
1088
1088
|
const s = i instanceof Error ? i : this.reason;
|
|
1089
|
-
n.abort(s instanceof L ? s : new
|
|
1089
|
+
n.abort(s instanceof L ? s : new b0(s instanceof Error ? s.message : s));
|
|
1090
1090
|
}
|
|
1091
1091
|
};
|
|
1092
1092
|
let x = t && setTimeout(() => {
|
|
@@ -1099,7 +1099,7 @@ const Rr = (e) => {
|
|
|
1099
1099
|
};
|
|
1100
1100
|
e.forEach((i) => i.addEventListener("abort", a));
|
|
1101
1101
|
const { signal: v } = n;
|
|
1102
|
-
return v.unsubscribe = () =>
|
|
1102
|
+
return v.unsubscribe = () => w.asap(f), v;
|
|
1103
1103
|
}
|
|
1104
1104
|
}, Ao = function* (e, t) {
|
|
1105
1105
|
let r = e.byteLength;
|
|
@@ -1158,36 +1158,36 @@ const Rr = (e) => {
|
|
|
1158
1158
|
}, {
|
|
1159
1159
|
highWaterMark: 2
|
|
1160
1160
|
});
|
|
1161
|
-
}, gt = 64 * 1024, { isFunction: W0 } =
|
|
1161
|
+
}, gt = 64 * 1024, { isFunction: W0 } = w, yo = (({ Request: e, Response: t }) => ({
|
|
1162
1162
|
Request: e,
|
|
1163
1163
|
Response: t
|
|
1164
|
-
}))(
|
|
1165
|
-
ReadableStream:
|
|
1166
|
-
TextEncoder:
|
|
1167
|
-
} =
|
|
1164
|
+
}))(w.global), {
|
|
1165
|
+
ReadableStream: wt,
|
|
1166
|
+
TextEncoder: bt
|
|
1167
|
+
} = w.global, Dt = (e, ...t) => {
|
|
1168
1168
|
try {
|
|
1169
1169
|
return !!e(...t);
|
|
1170
1170
|
} catch {
|
|
1171
1171
|
return !1;
|
|
1172
1172
|
}
|
|
1173
1173
|
}, go = (e) => {
|
|
1174
|
-
e =
|
|
1174
|
+
e = w.merge.call({
|
|
1175
1175
|
skipUndefined: !0
|
|
1176
1176
|
}, yo, e);
|
|
1177
1177
|
const { fetch: t, Request: r, Response: n } = e, o = t ? W0(t) : typeof fetch == "function", a = W0(r), x = W0(n);
|
|
1178
1178
|
if (!o)
|
|
1179
1179
|
return !1;
|
|
1180
|
-
const f = o && W0(
|
|
1180
|
+
const f = o && W0(wt), v = o && (typeof bt == "function" ? /* @__PURE__ */ ((c) => (p) => c.encode(p))(new bt()) : async (c) => new Uint8Array(await new r(c).arrayBuffer())), i = a && f && Dt(() => {
|
|
1181
1181
|
let c = !1;
|
|
1182
1182
|
const p = new r(Q.origin, {
|
|
1183
|
-
body: new
|
|
1183
|
+
body: new wt(),
|
|
1184
1184
|
method: "POST",
|
|
1185
1185
|
get duplex() {
|
|
1186
1186
|
return c = !0, "half";
|
|
1187
1187
|
}
|
|
1188
1188
|
}).headers.has("Content-Type");
|
|
1189
1189
|
return c && !p;
|
|
1190
|
-
}), s = x && f &&
|
|
1190
|
+
}), s = x && f && Dt(() => w.isReadableStream(new n("").body)), B = {
|
|
1191
1191
|
stream: s && ((c) => c.body)
|
|
1192
1192
|
};
|
|
1193
1193
|
o && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((c) => {
|
|
@@ -1201,19 +1201,19 @@ const Rr = (e) => {
|
|
|
1201
1201
|
const l = async (c) => {
|
|
1202
1202
|
if (c == null)
|
|
1203
1203
|
return 0;
|
|
1204
|
-
if (
|
|
1204
|
+
if (w.isBlob(c))
|
|
1205
1205
|
return c.size;
|
|
1206
|
-
if (
|
|
1206
|
+
if (w.isSpecCompliantForm(c))
|
|
1207
1207
|
return (await new r(Q.origin, {
|
|
1208
1208
|
method: "POST",
|
|
1209
1209
|
body: c
|
|
1210
1210
|
}).arrayBuffer()).byteLength;
|
|
1211
|
-
if (
|
|
1211
|
+
if (w.isArrayBufferView(c) || w.isArrayBuffer(c))
|
|
1212
1212
|
return c.byteLength;
|
|
1213
|
-
if (
|
|
1213
|
+
if (w.isURLSearchParams(c) && (c = c + ""), w.isString(c))
|
|
1214
1214
|
return (await v(c)).byteLength;
|
|
1215
1215
|
}, E = async (c, p) => {
|
|
1216
|
-
const u =
|
|
1216
|
+
const u = w.toFiniteNumber(c.getContentLength());
|
|
1217
1217
|
return u ?? l(p);
|
|
1218
1218
|
};
|
|
1219
1219
|
return async (c) => {
|
|
@@ -1227,10 +1227,10 @@ const Rr = (e) => {
|
|
|
1227
1227
|
onDownloadProgress: F,
|
|
1228
1228
|
onUploadProgress: y,
|
|
1229
1229
|
responseType: g,
|
|
1230
|
-
headers:
|
|
1230
|
+
headers: D,
|
|
1231
1231
|
withCredentials: H = "same-origin",
|
|
1232
1232
|
fetchOptions: m
|
|
1233
|
-
} = Rr(c),
|
|
1233
|
+
} = Rr(c), b = t || fetch;
|
|
1234
1234
|
g = g ? (g + "").toLowerCase() : "text";
|
|
1235
1235
|
let k = Co([h, d && d.toAbortSignal()], C), S = null;
|
|
1236
1236
|
const P = k && k.unsubscribe && (() => {
|
|
@@ -1238,13 +1238,13 @@ const Rr = (e) => {
|
|
|
1238
1238
|
});
|
|
1239
1239
|
let q;
|
|
1240
1240
|
try {
|
|
1241
|
-
if (y && i && u !== "get" && u !== "head" && (q = await E(
|
|
1241
|
+
if (y && i && u !== "get" && u !== "head" && (q = await E(D, A)) !== 0) {
|
|
1242
1242
|
let _ = new r(p, {
|
|
1243
1243
|
method: "POST",
|
|
1244
1244
|
body: A,
|
|
1245
1245
|
duplex: "half"
|
|
1246
1246
|
}), R;
|
|
1247
|
-
if (
|
|
1247
|
+
if (w.isFormData(A) && (R = _.headers.get("content-type")) && D.setContentType(R), _.body) {
|
|
1248
1248
|
const [O, T] = At(
|
|
1249
1249
|
q,
|
|
1250
1250
|
Se(mt(y))
|
|
@@ -1252,25 +1252,25 @@ const Rr = (e) => {
|
|
|
1252
1252
|
A = yt(_.body, gt, O, T);
|
|
1253
1253
|
}
|
|
1254
1254
|
}
|
|
1255
|
-
|
|
1255
|
+
w.isString(H) || (H = H ? "include" : "omit");
|
|
1256
1256
|
const N = a && "credentials" in r.prototype, M = {
|
|
1257
1257
|
...m,
|
|
1258
1258
|
signal: k,
|
|
1259
1259
|
method: u.toUpperCase(),
|
|
1260
|
-
headers:
|
|
1260
|
+
headers: D.normalize().toJSON(),
|
|
1261
1261
|
body: A,
|
|
1262
1262
|
duplex: "half",
|
|
1263
1263
|
credentials: N ? H : void 0
|
|
1264
1264
|
};
|
|
1265
1265
|
S = a && new r(p, M);
|
|
1266
|
-
let z = await (a ?
|
|
1266
|
+
let z = await (a ? b(S, m) : b(p, M));
|
|
1267
1267
|
const $ = s && (g === "stream" || g === "response");
|
|
1268
1268
|
if (s && (F || $ && P)) {
|
|
1269
1269
|
const _ = {};
|
|
1270
1270
|
["status", "statusText", "headers"].forEach((K) => {
|
|
1271
1271
|
_[K] = z[K];
|
|
1272
1272
|
});
|
|
1273
|
-
const R =
|
|
1273
|
+
const R = w.toFiniteNumber(z.headers.get("content-length")), [O, T] = F && At(
|
|
1274
1274
|
R,
|
|
1275
1275
|
Se(mt(F), !0)
|
|
1276
1276
|
) || [];
|
|
@@ -1282,11 +1282,11 @@ const Rr = (e) => {
|
|
|
1282
1282
|
);
|
|
1283
1283
|
}
|
|
1284
1284
|
g = g || "text";
|
|
1285
|
-
let W = await B[
|
|
1285
|
+
let W = await B[w.findKey(B, g) || "text"](z, c);
|
|
1286
1286
|
return !$ && P && P(), await new Promise((_, R) => {
|
|
1287
1287
|
kr(_, R, {
|
|
1288
1288
|
data: W,
|
|
1289
|
-
headers:
|
|
1289
|
+
headers: r0.from(z.headers),
|
|
1290
1290
|
status: z.status,
|
|
1291
1291
|
statusText: z.statusText,
|
|
1292
1292
|
config: c,
|
|
@@ -1302,27 +1302,27 @@ const Rr = (e) => {
|
|
|
1302
1302
|
) : L.from(N, N && N.code, c, S);
|
|
1303
1303
|
}
|
|
1304
1304
|
};
|
|
1305
|
-
},
|
|
1305
|
+
}, wo = /* @__PURE__ */ new Map(), Or = (e) => {
|
|
1306
1306
|
let t = e ? e.env : {};
|
|
1307
1307
|
const { fetch: r, Request: n, Response: o } = t, a = [
|
|
1308
1308
|
n,
|
|
1309
1309
|
o,
|
|
1310
1310
|
r
|
|
1311
1311
|
];
|
|
1312
|
-
let x = a.length, f = x, v, i, s =
|
|
1312
|
+
let x = a.length, f = x, v, i, s = wo;
|
|
1313
1313
|
for (; f--; )
|
|
1314
1314
|
v = a[f], i = s.get(v), i === void 0 && s.set(v, i = f ? /* @__PURE__ */ new Map() : go(t)), s = i;
|
|
1315
1315
|
return i;
|
|
1316
1316
|
};
|
|
1317
1317
|
Or();
|
|
1318
|
-
const
|
|
1318
|
+
const Ve = {
|
|
1319
1319
|
http: In,
|
|
1320
1320
|
xhr: Bo,
|
|
1321
1321
|
fetch: {
|
|
1322
1322
|
get: Or
|
|
1323
1323
|
}
|
|
1324
1324
|
};
|
|
1325
|
-
|
|
1325
|
+
w.forEach(Ve, (e, t) => {
|
|
1326
1326
|
if (e) {
|
|
1327
1327
|
try {
|
|
1328
1328
|
Object.defineProperty(e, "name", { value: t });
|
|
@@ -1331,18 +1331,18 @@ b.forEach(Ge, (e, t) => {
|
|
|
1331
1331
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
1332
1332
|
}
|
|
1333
1333
|
});
|
|
1334
|
-
const _t = (e) => `- ${e}`,
|
|
1334
|
+
const _t = (e) => `- ${e}`, bo = (e) => w.isFunction(e) || e === null || e === !1, Hr = {
|
|
1335
1335
|
getAdapter: (e, t) => {
|
|
1336
|
-
e =
|
|
1336
|
+
e = w.isArray(e) ? e : [e];
|
|
1337
1337
|
const { length: r } = e;
|
|
1338
1338
|
let n, o;
|
|
1339
1339
|
const a = {};
|
|
1340
1340
|
for (let x = 0; x < r; x++) {
|
|
1341
1341
|
n = e[x];
|
|
1342
1342
|
let f;
|
|
1343
|
-
if (o = n, !
|
|
1343
|
+
if (o = n, !bo(n) && (o = Ve[(f = String(n)).toLowerCase()], o === void 0))
|
|
1344
1344
|
throw new L(`Unknown adapter '${f}'`);
|
|
1345
|
-
if (o && (
|
|
1345
|
+
if (o && (w.isFunction(o) || (o = o.get(t))))
|
|
1346
1346
|
break;
|
|
1347
1347
|
a[f || "#" + x] = o;
|
|
1348
1348
|
}
|
|
@@ -1360,14 +1360,14 @@ const _t = (e) => `- ${e}`, Do = (e) => b.isFunction(e) || e === null || e === !
|
|
|
1360
1360
|
}
|
|
1361
1361
|
return o;
|
|
1362
1362
|
},
|
|
1363
|
-
adapters:
|
|
1363
|
+
adapters: Ve
|
|
1364
1364
|
};
|
|
1365
1365
|
function We(e) {
|
|
1366
1366
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
1367
|
-
throw new
|
|
1367
|
+
throw new b0(null, e);
|
|
1368
1368
|
}
|
|
1369
1369
|
function St(e) {
|
|
1370
|
-
return We(e), e.headers =
|
|
1370
|
+
return We(e), e.headers = r0.from(e.headers), e.data = je.call(
|
|
1371
1371
|
e,
|
|
1372
1372
|
e.transformRequest
|
|
1373
1373
|
), ["post", "put", "patch"].indexOf(e.method) !== -1 && e.headers.setContentType("application/x-www-form-urlencoded", !1), Hr.getAdapter(e.adapter || z0.adapter, e)(e).then(function(n) {
|
|
@@ -1375,13 +1375,13 @@ function St(e) {
|
|
|
1375
1375
|
e,
|
|
1376
1376
|
e.transformResponse,
|
|
1377
1377
|
n
|
|
1378
|
-
), n.headers =
|
|
1378
|
+
), n.headers = r0.from(n.headers), n;
|
|
1379
1379
|
}, function(n) {
|
|
1380
1380
|
return Sr(n) || (We(e), n && n.response && (n.response.data = je.call(
|
|
1381
1381
|
e,
|
|
1382
1382
|
e.transformResponse,
|
|
1383
1383
|
n.response
|
|
1384
|
-
), n.response.headers =
|
|
1384
|
+
), n.response.headers = r0.from(n.response.headers))), Promise.reject(n);
|
|
1385
1385
|
});
|
|
1386
1386
|
}
|
|
1387
1387
|
const Pr = "1.12.2", Pe = {};
|
|
@@ -1412,7 +1412,7 @@ Pe.transitional = function(t, r, n) {
|
|
|
1412
1412
|
Pe.spelling = function(t) {
|
|
1413
1413
|
return (r, n) => (console.warn(`${n} is likely a misspelling of ${t}`), !0);
|
|
1414
1414
|
};
|
|
1415
|
-
function
|
|
1415
|
+
function Do(e, t, r) {
|
|
1416
1416
|
if (typeof e != "object")
|
|
1417
1417
|
throw new L("options must be an object", L.ERR_BAD_OPTION_VALUE);
|
|
1418
1418
|
const n = Object.keys(e);
|
|
@@ -1430,9 +1430,9 @@ function wo(e, t, r) {
|
|
|
1430
1430
|
}
|
|
1431
1431
|
}
|
|
1432
1432
|
const K0 = {
|
|
1433
|
-
assertOptions:
|
|
1433
|
+
assertOptions: Do,
|
|
1434
1434
|
validators: Pe
|
|
1435
|
-
},
|
|
1435
|
+
}, f0 = K0.validators;
|
|
1436
1436
|
let v0 = class {
|
|
1437
1437
|
constructor(t) {
|
|
1438
1438
|
this.defaults = t || {}, this.interceptors = {
|
|
@@ -1469,28 +1469,28 @@ let v0 = class {
|
|
|
1469
1469
|
typeof t == "string" ? (r = r || {}, r.url = t) : r = t || {}, r = E0(this.defaults, r);
|
|
1470
1470
|
const { transitional: n, paramsSerializer: o, headers: a } = r;
|
|
1471
1471
|
n !== void 0 && K0.assertOptions(n, {
|
|
1472
|
-
silentJSONParsing:
|
|
1473
|
-
forcedJSONParsing:
|
|
1474
|
-
clarifyTimeoutError:
|
|
1475
|
-
}, !1), o != null && (
|
|
1472
|
+
silentJSONParsing: f0.transitional(f0.boolean),
|
|
1473
|
+
forcedJSONParsing: f0.transitional(f0.boolean),
|
|
1474
|
+
clarifyTimeoutError: f0.transitional(f0.boolean)
|
|
1475
|
+
}, !1), o != null && (w.isFunction(o) ? r.paramsSerializer = {
|
|
1476
1476
|
serialize: o
|
|
1477
1477
|
} : K0.assertOptions(o, {
|
|
1478
|
-
encode:
|
|
1479
|
-
serialize:
|
|
1478
|
+
encode: f0.function,
|
|
1479
|
+
serialize: f0.function
|
|
1480
1480
|
}, !0)), r.allowAbsoluteUrls !== void 0 || (this.defaults.allowAbsoluteUrls !== void 0 ? r.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls : r.allowAbsoluteUrls = !0), K0.assertOptions(r, {
|
|
1481
|
-
baseUrl:
|
|
1482
|
-
withXsrfToken:
|
|
1481
|
+
baseUrl: f0.spelling("baseURL"),
|
|
1482
|
+
withXsrfToken: f0.spelling("withXSRFToken")
|
|
1483
1483
|
}, !0), r.method = (r.method || this.defaults.method || "get").toLowerCase();
|
|
1484
|
-
let x = a &&
|
|
1484
|
+
let x = a && w.merge(
|
|
1485
1485
|
a.common,
|
|
1486
1486
|
a[r.method]
|
|
1487
1487
|
);
|
|
1488
|
-
a &&
|
|
1488
|
+
a && w.forEach(
|
|
1489
1489
|
["delete", "get", "head", "post", "put", "patch", "common"],
|
|
1490
1490
|
(c) => {
|
|
1491
1491
|
delete a[c];
|
|
1492
1492
|
}
|
|
1493
|
-
), r.headers =
|
|
1493
|
+
), r.headers = r0.concat(x, a);
|
|
1494
1494
|
const f = [];
|
|
1495
1495
|
let v = !0;
|
|
1496
1496
|
this.interceptors.request.forEach(function(p) {
|
|
@@ -1530,10 +1530,10 @@ let v0 = class {
|
|
|
1530
1530
|
getUri(t) {
|
|
1531
1531
|
t = E0(this.defaults, t);
|
|
1532
1532
|
const r = Tr(t.baseURL, t.url, t.allowAbsoluteUrls);
|
|
1533
|
-
return
|
|
1533
|
+
return br(r, t.params, t.paramsSerializer);
|
|
1534
1534
|
}
|
|
1535
1535
|
};
|
|
1536
|
-
|
|
1536
|
+
w.forEach(["delete", "get", "head", "options"], function(t) {
|
|
1537
1537
|
v0.prototype[t] = function(r, n) {
|
|
1538
1538
|
return this.request(E0(n || {}, {
|
|
1539
1539
|
method: t,
|
|
@@ -1542,7 +1542,7 @@ b.forEach(["delete", "get", "head", "options"], function(t) {
|
|
|
1542
1542
|
}));
|
|
1543
1543
|
};
|
|
1544
1544
|
});
|
|
1545
|
-
|
|
1545
|
+
w.forEach(["post", "put", "patch"], function(t) {
|
|
1546
1546
|
function r(n) {
|
|
1547
1547
|
return function(a, x, f) {
|
|
1548
1548
|
return this.request(E0(f || {}, {
|
|
@@ -1581,7 +1581,7 @@ let _o = class qr {
|
|
|
1581
1581
|
n.unsubscribe(a);
|
|
1582
1582
|
}, x;
|
|
1583
1583
|
}, t(function(a, x, f) {
|
|
1584
|
-
n.reason || (n.reason = new
|
|
1584
|
+
n.reason || (n.reason = new b0(a, x, f), r(n.reason));
|
|
1585
1585
|
});
|
|
1586
1586
|
}
|
|
1587
1587
|
/**
|
|
@@ -1636,9 +1636,9 @@ function So(e) {
|
|
|
1636
1636
|
};
|
|
1637
1637
|
}
|
|
1638
1638
|
function ko(e) {
|
|
1639
|
-
return
|
|
1639
|
+
return w.isObject(e) && e.isAxiosError === !0;
|
|
1640
1640
|
}
|
|
1641
|
-
const
|
|
1641
|
+
const Ge = {
|
|
1642
1642
|
Continue: 100,
|
|
1643
1643
|
SwitchingProtocols: 101,
|
|
1644
1644
|
Processing: 102,
|
|
@@ -1703,35 +1703,35 @@ const Ve = {
|
|
|
1703
1703
|
NotExtended: 510,
|
|
1704
1704
|
NetworkAuthenticationRequired: 511
|
|
1705
1705
|
};
|
|
1706
|
-
Object.entries(
|
|
1707
|
-
|
|
1706
|
+
Object.entries(Ge).forEach(([e, t]) => {
|
|
1707
|
+
Ge[t] = e;
|
|
1708
1708
|
});
|
|
1709
1709
|
function Nr(e) {
|
|
1710
1710
|
const t = new v0(e), r = hr(v0.prototype.request, t);
|
|
1711
|
-
return
|
|
1711
|
+
return w.extend(r, v0.prototype, t, { allOwnKeys: !0 }), w.extend(r, t, null, { allOwnKeys: !0 }), r.create = function(o) {
|
|
1712
1712
|
return Nr(E0(e, o));
|
|
1713
1713
|
}, r;
|
|
1714
1714
|
}
|
|
1715
|
-
const
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1715
|
+
const V = Nr(z0);
|
|
1716
|
+
V.Axios = v0;
|
|
1717
|
+
V.CanceledError = b0;
|
|
1718
|
+
V.CancelToken = _o;
|
|
1719
|
+
V.isCancel = Sr;
|
|
1720
|
+
V.VERSION = Pr;
|
|
1721
|
+
V.toFormData = He;
|
|
1722
|
+
V.AxiosError = L;
|
|
1723
|
+
V.Cancel = V.CanceledError;
|
|
1724
|
+
V.all = function(t) {
|
|
1725
1725
|
return Promise.all(t);
|
|
1726
1726
|
};
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1727
|
+
V.spread = So;
|
|
1728
|
+
V.isAxiosError = ko;
|
|
1729
|
+
V.mergeConfig = E0;
|
|
1730
|
+
V.AxiosHeaders = r0;
|
|
1731
|
+
V.formToJSON = (e) => _r(w.isHTMLForm(e) ? new FormData(e) : e);
|
|
1732
|
+
V.getAdapter = Hr.getAdapter;
|
|
1733
|
+
V.HttpStatusCode = Ge;
|
|
1734
|
+
V.default = V;
|
|
1735
1735
|
const {
|
|
1736
1736
|
Axios: ti,
|
|
1737
1737
|
AxiosError: ri,
|
|
@@ -1749,21 +1749,21 @@ const {
|
|
|
1749
1749
|
formToJSON: hi,
|
|
1750
1750
|
getAdapter: pi,
|
|
1751
1751
|
mergeConfig: vi
|
|
1752
|
-
} =
|
|
1752
|
+
} = V;
|
|
1753
1753
|
function To() {
|
|
1754
|
-
return
|
|
1754
|
+
return j.request({
|
|
1755
1755
|
url: "/wuji-portal-visual/organ/getUserRole",
|
|
1756
1756
|
method: "GET"
|
|
1757
1757
|
});
|
|
1758
1758
|
}
|
|
1759
1759
|
function Ro() {
|
|
1760
|
-
return
|
|
1760
|
+
return j.request({
|
|
1761
1761
|
url: "/wuji-portal-visual/auth/api/currentUser",
|
|
1762
1762
|
method: "GET"
|
|
1763
1763
|
});
|
|
1764
1764
|
}
|
|
1765
1765
|
function Tt(e) {
|
|
1766
|
-
return
|
|
1766
|
+
return j.request({
|
|
1767
1767
|
url: "/wuji-portal-visual/portalServerDomain/getDomainAll",
|
|
1768
1768
|
method: "GET",
|
|
1769
1769
|
params: e
|
|
@@ -1772,10 +1772,10 @@ function Tt(e) {
|
|
|
1772
1772
|
const P0 = {
|
|
1773
1773
|
/**
|
|
1774
1774
|
* @doc
|
|
1775
|
-
* @API
|
|
1775
|
+
* @API utils
|
|
1776
1776
|
* @desc 获取域名列表信息
|
|
1777
1777
|
* @return {Promise<Array>} 域名信息数组的Promise对象
|
|
1778
|
-
* @example getDomains() => Promise.resolve([{serverCode: 'home', serverDomain: 'home.zhwz.lz', ...}])
|
|
1778
|
+
* @example-exe getDomains() => Promise.resolve([{serverCode: 'home', serverDomain: 'home.zhwz.lz', ...}])
|
|
1779
1779
|
* */
|
|
1780
1780
|
async getDomains() {
|
|
1781
1781
|
let e = [];
|
|
@@ -1789,11 +1789,11 @@ const P0 = {
|
|
|
1789
1789
|
},
|
|
1790
1790
|
/**
|
|
1791
1791
|
* @doc
|
|
1792
|
-
* @API
|
|
1792
|
+
* @API utils
|
|
1793
1793
|
* @desc 将对象转化为FormData形式参数
|
|
1794
1794
|
* @param {Object} data - 需要转换的对象
|
|
1795
1795
|
* @return {FormData} 转换后的FormData对象
|
|
1796
|
-
* @example transToFormdata({id: '1', name: 'test'})
|
|
1796
|
+
* @example-exe transToFormdata({id: '1', name: 'test'})
|
|
1797
1797
|
* @warning 只处理对象自身的属性
|
|
1798
1798
|
* */
|
|
1799
1799
|
transToFormdata(e) {
|
|
@@ -1804,11 +1804,11 @@ const P0 = {
|
|
|
1804
1804
|
},
|
|
1805
1805
|
/**
|
|
1806
1806
|
* @doc
|
|
1807
|
-
* @API
|
|
1807
|
+
* @API utils
|
|
1808
1808
|
* @desc IP地址检测函数
|
|
1809
1809
|
* @param {String} url - 需要检测的字符串
|
|
1810
1810
|
* @return {Boolean} 是否为IP地址
|
|
1811
|
-
* @example isIp('192.168.1.1') => true
|
|
1811
|
+
* @example-exe utils.isIp('192.168.1.1') => true
|
|
1812
1812
|
* @warning 仅支持IPv4地址检测
|
|
1813
1813
|
* */
|
|
1814
1814
|
isIp(e) {
|
|
@@ -1816,11 +1816,11 @@ const P0 = {
|
|
|
1816
1816
|
},
|
|
1817
1817
|
/**
|
|
1818
1818
|
* @doc
|
|
1819
|
-
* @API
|
|
1819
|
+
* @API utils
|
|
1820
1820
|
* @desc 从地址栏参数中获取指定参数值
|
|
1821
1821
|
* @param {String} name - 参数名称
|
|
1822
1822
|
* @return {String} 参数值
|
|
1823
|
-
* @example utils.getQueryString('id') => '123'
|
|
1823
|
+
* @example-exe utils.utils.getQueryString('id') => '123'
|
|
1824
1824
|
* @warning 解决地址栏有重复"?"的问题
|
|
1825
1825
|
* */
|
|
1826
1826
|
getQueryString(e) {
|
|
@@ -1832,11 +1832,11 @@ const P0 = {
|
|
|
1832
1832
|
},
|
|
1833
1833
|
/**
|
|
1834
1834
|
* @doc
|
|
1835
|
-
* @API
|
|
1835
|
+
* @API utils
|
|
1836
1836
|
* @desc 深度复制对象或数组
|
|
1837
1837
|
* @param {Object|Array} target - 需要复制的目标
|
|
1838
1838
|
* @return {Object|Array} 复制后的新对象或数组
|
|
1839
|
-
* @example deepCopy({a: 1, b: {c: 2}})
|
|
1839
|
+
* @example-exe utils.deepCopy({a: 1, b: {c: 2}})
|
|
1840
1840
|
* */
|
|
1841
1841
|
deepCopy(e) {
|
|
1842
1842
|
if (typeof e == "object") {
|
|
@@ -1849,11 +1849,11 @@ const P0 = {
|
|
|
1849
1849
|
},
|
|
1850
1850
|
/**
|
|
1851
1851
|
* @doc
|
|
1852
|
-
* @API
|
|
1852
|
+
* @API utils
|
|
1853
1853
|
* @desc 将数字转换为中文数字表示
|
|
1854
1854
|
* @param {Number} num - 需要转换的数字
|
|
1855
1855
|
* @return {String} 中文数字字符串
|
|
1856
|
-
* @example toChinesNum(123) => '一百二十三'
|
|
1856
|
+
* @example-exe utils.toChinesNum(123) => '一百二十三'
|
|
1857
1857
|
* */
|
|
1858
1858
|
toChinesNum(e) {
|
|
1859
1859
|
let t = ["零", "一", "二", "三", "四", "五", "六", "七", "八", "九"], r = ["", "十", "百", "千", "万"], n = parseInt(e), o = (f) => {
|
|
@@ -1872,12 +1872,12 @@ const P0 = {
|
|
|
1872
1872
|
},
|
|
1873
1873
|
/**
|
|
1874
1874
|
* @doc
|
|
1875
|
-
* @API
|
|
1875
|
+
* @API utils
|
|
1876
1876
|
* @desc 复制文本到剪贴板
|
|
1877
1877
|
* @param {String} text - 要复制的内容
|
|
1878
1878
|
* @param {Function} callback - 复制完成后的回调函数
|
|
1879
1879
|
* @return 无返回值
|
|
1880
|
-
* @example copyText('hello world', () => { console.log('copied') })
|
|
1880
|
+
* @example-exe utils.copyText('hello world', () => { console.log('copied') })
|
|
1881
1881
|
* */
|
|
1882
1882
|
copyText(e, t) {
|
|
1883
1883
|
const r = document.createElement("input");
|
|
@@ -1885,12 +1885,12 @@ const P0 = {
|
|
|
1885
1885
|
},
|
|
1886
1886
|
/**
|
|
1887
1887
|
* @doc
|
|
1888
|
-
* @API
|
|
1888
|
+
* @API utils
|
|
1889
1889
|
* @desc 安全解析JSON,提供默认值
|
|
1890
1890
|
* @param {String|Object} e - 需要解析的JSON字符串或对象
|
|
1891
1891
|
* @param {any} defaultVal - 默认值
|
|
1892
1892
|
* @return {Object|any} 解析后的对象或默认值
|
|
1893
|
-
* @example jsonFormat('{"a":1}', {}) => {a: 1}
|
|
1893
|
+
* @example-exe utils.jsonFormat('{"a":1}', {}) => {a: 1}
|
|
1894
1894
|
* */
|
|
1895
1895
|
jsonFormat(e, t) {
|
|
1896
1896
|
if (!(e === void 0 || t === void 0))
|
|
@@ -1898,11 +1898,11 @@ const P0 = {
|
|
|
1898
1898
|
},
|
|
1899
1899
|
/**
|
|
1900
1900
|
* @doc
|
|
1901
|
-
* @API
|
|
1901
|
+
* @API utils
|
|
1902
1902
|
* @desc 将数组转化为键值对形式的对象
|
|
1903
1903
|
* @param {Array} arr - 包含key和defaultValue的对象数组
|
|
1904
1904
|
* @return {Object} - 转换后的键值对对象
|
|
1905
|
-
* @example arrayToObject([{key: 'name', defaultValue: 'test'}]) => {name: 'test'}
|
|
1905
|
+
* @example-exe utils.arrayToObject([{key: 'name', defaultValue: 'test'}]) => {name: 'test'}
|
|
1906
1906
|
* @warning 数组元素必须包含key和defaultValue属性
|
|
1907
1907
|
* */
|
|
1908
1908
|
arrayToObject(e) {
|
|
@@ -1913,10 +1913,10 @@ const P0 = {
|
|
|
1913
1913
|
},
|
|
1914
1914
|
/**
|
|
1915
1915
|
* @doc
|
|
1916
|
-
* @API
|
|
1916
|
+
* @API utils
|
|
1917
1917
|
* @desc 用户获取客户端类型,返回字符串
|
|
1918
1918
|
* @return String qax:奇安信浏览器;ldtC:立达通客户端;ldt:立达通浏览器;portal:门户浏览器;iframe:门户适配浏览器模式
|
|
1919
|
-
* @example
|
|
1919
|
+
* @example-exe utils.getClientType() === 'portal';
|
|
1920
1920
|
* */
|
|
1921
1921
|
getClientType() {
|
|
1922
1922
|
var t, r;
|
|
@@ -1925,13 +1925,13 @@ const P0 = {
|
|
|
1925
1925
|
},
|
|
1926
1926
|
/**
|
|
1927
1927
|
* @doc
|
|
1928
|
-
* @API
|
|
1928
|
+
* @API utils
|
|
1929
1929
|
* @desc 防抖函数
|
|
1930
1930
|
* @param {String} name - 防抖标识名称
|
|
1931
1931
|
* @param {Function} fn - 需要防抖的函数
|
|
1932
1932
|
* @param {Number} [time=300] - 防抖时间间隔(毫秒)
|
|
1933
1933
|
* @return 无返回值
|
|
1934
|
-
* @example timerDebounce('search', () => { console.log('searching') }, 500)
|
|
1934
|
+
* @example-exe utils.timerDebounce('search', () => { console.log('searching') }, 500)
|
|
1935
1935
|
* @warning 使用全局对象window.superTimerDebounceFun存储定时器,需确保名称唯一性
|
|
1936
1936
|
* */
|
|
1937
1937
|
timerDebounce(e, t, r = 300) {
|
|
@@ -1941,12 +1941,28 @@ const P0 = {
|
|
|
1941
1941
|
},
|
|
1942
1942
|
/**
|
|
1943
1943
|
* @doc
|
|
1944
|
-
* @API
|
|
1944
|
+
* @API utils
|
|
1945
|
+
* @desc 节流函数
|
|
1946
|
+
* @param {String} name - 节流标识名称
|
|
1947
|
+
* @param {Function} fn - 需要节流的函数
|
|
1948
|
+
* @param {Number} [time=300] - 节流时间间隔(毫秒)
|
|
1949
|
+
* @return 无返回值
|
|
1950
|
+
* @example-exe utils.timerThrottle('search', () => { console.log('searching') }, 500)
|
|
1951
|
+
* @warning 使用全局对象window.superTimerThrottleFun存储定时器,需确保名称唯一性
|
|
1952
|
+
* */
|
|
1953
|
+
timerThrottle(e, t, r = 300) {
|
|
1954
|
+
window.leadal_superTimerThrottleFun || (window.leadal_superTimerThrottleFun = {}), window.leadal_superTimerThrottleFun[e] && (clearTimeout(window.leadal_superTimerThrottleFun[e]), delete window.leadal_superTimerThrottleFun[e]), window.leadal_superTimerThrottleFun[e] = setTimeout(() => {
|
|
1955
|
+
t();
|
|
1956
|
+
}, r);
|
|
1957
|
+
},
|
|
1958
|
+
/**
|
|
1959
|
+
* @doc
|
|
1960
|
+
* @API utils
|
|
1945
1961
|
* @desc 将base64转为文件流
|
|
1946
1962
|
* @param {String} data base64格式的图片数据
|
|
1947
1963
|
* @param {String} fileName 文件名
|
|
1948
1964
|
* @return {File} 文件流对象
|
|
1949
|
-
* @example base64toFile('data:image/jpeg;base64,...', 'avatar')
|
|
1965
|
+
* @example-exe utils.base64toFile('data:image/jpeg;base64,...', 'avatar')
|
|
1950
1966
|
* @warning 默认转换为jpeg格式图片
|
|
1951
1967
|
* */
|
|
1952
1968
|
base64toFile(e, t) {
|
|
@@ -1960,25 +1976,25 @@ const P0 = {
|
|
|
1960
1976
|
},
|
|
1961
1977
|
/**
|
|
1962
1978
|
* @doc
|
|
1963
|
-
* @API
|
|
1979
|
+
* @API utils
|
|
1964
1980
|
* @desc 本地文件转为base64
|
|
1965
1981
|
* @param {String} url 文件URL地址
|
|
1966
1982
|
* @return {Promise<String>} base64格式的图片数据
|
|
1967
|
-
* @example loadBase64Image('/assets/logo.png')
|
|
1983
|
+
* @example-exe utils.loadBase64Image('/assets/logo.png')
|
|
1968
1984
|
* @warning 需要axios库支持,且URL需支持跨域访问
|
|
1969
1985
|
* */
|
|
1970
1986
|
async loadBase64Image(e) {
|
|
1971
1987
|
if (!e) return;
|
|
1972
|
-
const t = await
|
|
1988
|
+
const t = await V.get(e, { responseType: "blob" }), r = new Blob([t.data], { type: "image/png" });
|
|
1973
1989
|
return await blobToBase64(r);
|
|
1974
1990
|
},
|
|
1975
1991
|
/**
|
|
1976
1992
|
* @doc
|
|
1977
|
-
* @API
|
|
1993
|
+
* @API utils
|
|
1978
1994
|
* @desc 将Blob对象转为base64
|
|
1979
1995
|
* @param {Blob} blob Blob对象
|
|
1980
1996
|
* @return {Promise<String>} base64格式的图片数据
|
|
1981
|
-
* @example blobToBase64(new Blob([data], {type: 'image/png'}))
|
|
1997
|
+
* @example-exe utils.blobToBase64(new Blob([data], {type: 'image/png'}))
|
|
1982
1998
|
* @warning 无
|
|
1983
1999
|
* */
|
|
1984
2000
|
blobToBase64(e) {
|
|
@@ -1990,11 +2006,28 @@ const P0 = {
|
|
|
1990
2006
|
}, n.onerror = r, n.readAsDataURL(e);
|
|
1991
2007
|
});
|
|
1992
2008
|
},
|
|
2009
|
+
/**
|
|
2010
|
+
* @doc
|
|
2011
|
+
* @API utils
|
|
2012
|
+
* @desc 根据服务编码获取服务配置信息
|
|
2013
|
+
* @param {String} code - 服务编码
|
|
2014
|
+
* @return {String|undefined} 服务URL地址或undefined
|
|
2015
|
+
* @example-exe utils.getService('user-service') => 'http://user.leadal.com/'
|
|
2016
|
+
* @warning 若本地存储中不存在服务映射,会自动调用setServiceMapToStorage更新
|
|
2017
|
+
* */
|
|
1993
2018
|
getService(e) {
|
|
1994
2019
|
if (!e) return;
|
|
1995
2020
|
const t = window.localStorage.getItem("com.leadal.portal.service.map");
|
|
1996
2021
|
return t || P0.setServiceMapToStorage(), JSON.parse(t || "{}")[e];
|
|
1997
2022
|
},
|
|
2023
|
+
/**
|
|
2024
|
+
* @doc
|
|
2025
|
+
* @API utils
|
|
2026
|
+
* @desc 获取所有服务域名信息并设置到本地存储中
|
|
2027
|
+
* @return {Promise<Object>} 服务映射对象的Promise
|
|
2028
|
+
* @example-exe utils.setServiceMapToStorage().then(serviceMap => console.log(serviceMap))
|
|
2029
|
+
* @warning 异常处理:捕获并记录错误,reject时返回空数组
|
|
2030
|
+
* */
|
|
1998
2031
|
setServiceMapToStorage() {
|
|
1999
2032
|
return new Promise(async (e, t) => {
|
|
2000
2033
|
try {
|
|
@@ -2038,13 +2071,13 @@ var X0 = { exports: {} };
|
|
|
2038
2071
|
function Po(e) {
|
|
2039
2072
|
throw new Error('Could not dynamically require "' + e + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
2040
2073
|
}
|
|
2041
|
-
var
|
|
2074
|
+
var V0 = { exports: {} };
|
|
2042
2075
|
const qo = {}, No = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2043
2076
|
__proto__: null,
|
|
2044
2077
|
default: qo
|
|
2045
2078
|
}, Symbol.toStringTag, { value: "Module" })), Lo = /* @__PURE__ */ Ho(No);
|
|
2046
|
-
var zo =
|
|
2047
|
-
function
|
|
2079
|
+
var zo = V0.exports, Rt;
|
|
2080
|
+
function I() {
|
|
2048
2081
|
return Rt || (Rt = 1, (function(e, t) {
|
|
2049
2082
|
(function(r, n) {
|
|
2050
2083
|
e.exports = n();
|
|
@@ -2209,8 +2242,8 @@ function j() {
|
|
|
2209
2242
|
var d = this.words, C = h.words, F = this.sigBytes, y = h.sigBytes;
|
|
2210
2243
|
if (this.clamp(), F % 4)
|
|
2211
2244
|
for (var g = 0; g < y; g++) {
|
|
2212
|
-
var
|
|
2213
|
-
d[F + g >>> 2] |=
|
|
2245
|
+
var D = C[g >>> 2] >>> 24 - g % 4 * 8 & 255;
|
|
2246
|
+
d[F + g >>> 2] |= D << 24 - (F + g) % 4 * 8;
|
|
2214
2247
|
}
|
|
2215
2248
|
else
|
|
2216
2249
|
for (var H = 0; H < y; H += 4)
|
|
@@ -2413,15 +2446,15 @@ function j() {
|
|
|
2413
2446
|
* var processedData = bufferedBlockAlgorithm._process(!!'flush');
|
|
2414
2447
|
*/
|
|
2415
2448
|
_process: function(h) {
|
|
2416
|
-
var d, C = this._data, F = C.words, y = C.sigBytes, g = this.blockSize,
|
|
2449
|
+
var d, C = this._data, F = C.words, y = C.sigBytes, g = this.blockSize, D = g * 4, H = y / D;
|
|
2417
2450
|
h ? H = n.ceil(H) : H = n.max((H | 0) - this._minBufferSize, 0);
|
|
2418
|
-
var m = H * g,
|
|
2451
|
+
var m = H * g, b = n.min(m * 4, y);
|
|
2419
2452
|
if (m) {
|
|
2420
2453
|
for (var k = 0; k < m; k += g)
|
|
2421
2454
|
this._doProcessBlock(F, k);
|
|
2422
|
-
d = F.splice(0, m), C.sigBytes -=
|
|
2455
|
+
d = F.splice(0, m), C.sigBytes -= b;
|
|
2423
2456
|
}
|
|
2424
|
-
return new B.init(d,
|
|
2457
|
+
return new B.init(d, b);
|
|
2425
2458
|
},
|
|
2426
2459
|
/**
|
|
2427
2460
|
* Creates a copy of this object.
|
|
@@ -2542,13 +2575,13 @@ function j() {
|
|
|
2542
2575
|
})(Math);
|
|
2543
2576
|
return r;
|
|
2544
2577
|
});
|
|
2545
|
-
})(
|
|
2578
|
+
})(V0)), V0.exports;
|
|
2546
2579
|
}
|
|
2547
|
-
var
|
|
2580
|
+
var G0 = { exports: {} }, Uo = G0.exports, Ot;
|
|
2548
2581
|
function qe() {
|
|
2549
2582
|
return Ot || (Ot = 1, (function(e, t) {
|
|
2550
2583
|
(function(r, n) {
|
|
2551
|
-
e.exports = n(
|
|
2584
|
+
e.exports = n(I());
|
|
2552
2585
|
})(Uo, function(r) {
|
|
2553
2586
|
return (function(n) {
|
|
2554
2587
|
var o = r, a = o.lib, x = a.Base, f = a.WordArray, v = o.x64 = {};
|
|
@@ -2772,13 +2805,13 @@ function qe() {
|
|
|
2772
2805
|
});
|
|
2773
2806
|
})(), r;
|
|
2774
2807
|
});
|
|
2775
|
-
})(
|
|
2808
|
+
})(G0)), G0.exports;
|
|
2776
2809
|
}
|
|
2777
2810
|
var Q0 = { exports: {} }, Io = Q0.exports, Ht;
|
|
2778
2811
|
function jo() {
|
|
2779
2812
|
return Ht || (Ht = 1, (function(e, t) {
|
|
2780
2813
|
(function(r, n) {
|
|
2781
|
-
e.exports = n(
|
|
2814
|
+
e.exports = n(I());
|
|
2782
2815
|
})(Io, function(r) {
|
|
2783
2816
|
return (function() {
|
|
2784
2817
|
if (typeof ArrayBuffer == "function") {
|
|
@@ -2800,7 +2833,7 @@ var Z0 = { exports: {} }, Wo = Z0.exports, Pt;
|
|
|
2800
2833
|
function $o() {
|
|
2801
2834
|
return Pt || (Pt = 1, (function(e, t) {
|
|
2802
2835
|
(function(r, n) {
|
|
2803
|
-
e.exports = n(
|
|
2836
|
+
e.exports = n(I());
|
|
2804
2837
|
})(Wo, function(r) {
|
|
2805
2838
|
return (function() {
|
|
2806
2839
|
var n = r, o = n.lib, a = o.WordArray, x = n.enc;
|
|
@@ -2894,7 +2927,7 @@ var J0 = { exports: {} }, Mo = J0.exports, qt;
|
|
|
2894
2927
|
function B0() {
|
|
2895
2928
|
return qt || (qt = 1, (function(e, t) {
|
|
2896
2929
|
(function(r, n) {
|
|
2897
|
-
e.exports = n(
|
|
2930
|
+
e.exports = n(I());
|
|
2898
2931
|
})(Mo, function(r) {
|
|
2899
2932
|
return (function() {
|
|
2900
2933
|
var n = r, o = n.lib, a = o.WordArray, x = n.enc;
|
|
@@ -2969,7 +3002,7 @@ var Y0 = { exports: {} }, Ko = Y0.exports, Nt;
|
|
|
2969
3002
|
function Xo() {
|
|
2970
3003
|
return Nt || (Nt = 1, (function(e, t) {
|
|
2971
3004
|
(function(r, n) {
|
|
2972
|
-
e.exports = n(
|
|
3005
|
+
e.exports = n(I());
|
|
2973
3006
|
})(Ko, function(r) {
|
|
2974
3007
|
return (function() {
|
|
2975
3008
|
var n = r, o = n.lib, a = o.WordArray, x = n.enc;
|
|
@@ -3047,12 +3080,12 @@ function Xo() {
|
|
|
3047
3080
|
});
|
|
3048
3081
|
})(Y0)), Y0.exports;
|
|
3049
3082
|
}
|
|
3050
|
-
var ee = { exports: {} },
|
|
3083
|
+
var ee = { exports: {} }, Vo = ee.exports, Lt;
|
|
3051
3084
|
function C0() {
|
|
3052
3085
|
return Lt || (Lt = 1, (function(e, t) {
|
|
3053
3086
|
(function(r, n) {
|
|
3054
|
-
e.exports = n(
|
|
3055
|
-
})(
|
|
3087
|
+
e.exports = n(I());
|
|
3088
|
+
})(Vo, function(r) {
|
|
3056
3089
|
return (function(n) {
|
|
3057
3090
|
var o = r, a = o.lib, x = a.WordArray, f = a.Hasher, v = o.algo, i = [];
|
|
3058
3091
|
(function() {
|
|
@@ -3073,8 +3106,8 @@ function C0() {
|
|
|
3073
3106
|
var h = u + A, d = p[h];
|
|
3074
3107
|
p[h] = (d << 8 | d >>> 24) & 16711935 | (d << 24 | d >>> 8) & 4278255360;
|
|
3075
3108
|
}
|
|
3076
|
-
var C = this._hash.words, F = p[u + 0], y = p[u + 1], g = p[u + 2],
|
|
3077
|
-
_ = B(_, R, O, T, F, 7, i[0]), T = B(T, _, R, O, y, 12, i[1]), O = B(O, T, _, R, g, 17, i[2]), R = B(R, O, T, _,
|
|
3109
|
+
var C = this._hash.words, F = p[u + 0], y = p[u + 1], g = p[u + 2], D = p[u + 3], H = p[u + 4], m = p[u + 5], b = p[u + 6], k = p[u + 7], S = p[u + 8], P = p[u + 9], q = p[u + 10], N = p[u + 11], M = p[u + 12], z = p[u + 13], $ = p[u + 14], W = p[u + 15], _ = C[0], R = C[1], O = C[2], T = C[3];
|
|
3110
|
+
_ = B(_, R, O, T, F, 7, i[0]), T = B(T, _, R, O, y, 12, i[1]), O = B(O, T, _, R, g, 17, i[2]), R = B(R, O, T, _, D, 22, i[3]), _ = B(_, R, O, T, H, 7, i[4]), T = B(T, _, R, O, m, 12, i[5]), O = B(O, T, _, R, b, 17, i[6]), R = B(R, O, T, _, k, 22, i[7]), _ = B(_, R, O, T, S, 7, i[8]), T = B(T, _, R, O, P, 12, i[9]), O = B(O, T, _, R, q, 17, i[10]), R = B(R, O, T, _, N, 22, i[11]), _ = B(_, R, O, T, M, 7, i[12]), T = B(T, _, R, O, z, 12, i[13]), O = B(O, T, _, R, $, 17, i[14]), R = B(R, O, T, _, W, 22, i[15]), _ = l(_, R, O, T, y, 5, i[16]), T = l(T, _, R, O, b, 9, i[17]), O = l(O, T, _, R, N, 14, i[18]), R = l(R, O, T, _, F, 20, i[19]), _ = l(_, R, O, T, m, 5, i[20]), T = l(T, _, R, O, q, 9, i[21]), O = l(O, T, _, R, W, 14, i[22]), R = l(R, O, T, _, H, 20, i[23]), _ = l(_, R, O, T, P, 5, i[24]), T = l(T, _, R, O, $, 9, i[25]), O = l(O, T, _, R, D, 14, i[26]), R = l(R, O, T, _, S, 20, i[27]), _ = l(_, R, O, T, z, 5, i[28]), T = l(T, _, R, O, g, 9, i[29]), O = l(O, T, _, R, k, 14, i[30]), R = l(R, O, T, _, M, 20, i[31]), _ = E(_, R, O, T, m, 4, i[32]), T = E(T, _, R, O, S, 11, i[33]), O = E(O, T, _, R, N, 16, i[34]), R = E(R, O, T, _, $, 23, i[35]), _ = E(_, R, O, T, y, 4, i[36]), T = E(T, _, R, O, H, 11, i[37]), O = E(O, T, _, R, k, 16, i[38]), R = E(R, O, T, _, q, 23, i[39]), _ = E(_, R, O, T, z, 4, i[40]), T = E(T, _, R, O, F, 11, i[41]), O = E(O, T, _, R, D, 16, i[42]), R = E(R, O, T, _, b, 23, i[43]), _ = E(_, R, O, T, P, 4, i[44]), T = E(T, _, R, O, M, 11, i[45]), O = E(O, T, _, R, W, 16, i[46]), R = E(R, O, T, _, g, 23, i[47]), _ = c(_, R, O, T, F, 6, i[48]), T = c(T, _, R, O, k, 10, i[49]), O = c(O, T, _, R, $, 15, i[50]), R = c(R, O, T, _, m, 21, i[51]), _ = c(_, R, O, T, M, 6, i[52]), T = c(T, _, R, O, D, 10, i[53]), O = c(O, T, _, R, q, 15, i[54]), R = c(R, O, T, _, y, 21, i[55]), _ = c(_, R, O, T, S, 6, i[56]), T = c(T, _, R, O, W, 10, i[57]), O = c(O, T, _, R, b, 15, i[58]), R = c(R, O, T, _, z, 21, i[59]), _ = c(_, R, O, T, H, 6, i[60]), T = c(T, _, R, O, N, 10, i[61]), O = c(O, T, _, R, g, 15, i[62]), R = c(R, O, T, _, P, 21, i[63]), C[0] = C[0] + _ | 0, C[1] = C[1] + R | 0, C[2] = C[2] + O | 0, C[3] = C[3] + T | 0;
|
|
3078
3111
|
},
|
|
3079
3112
|
_doFinalize: function() {
|
|
3080
3113
|
var p = this._data, u = p.words, A = this._nDataBytes * 8, h = p.sigBytes * 8;
|
|
@@ -3082,8 +3115,8 @@ function C0() {
|
|
|
3082
3115
|
var d = n.floor(A / 4294967296), C = A;
|
|
3083
3116
|
u[(h + 64 >>> 9 << 4) + 15] = (d << 8 | d >>> 24) & 16711935 | (d << 24 | d >>> 8) & 4278255360, u[(h + 64 >>> 9 << 4) + 14] = (C << 8 | C >>> 24) & 16711935 | (C << 24 | C >>> 8) & 4278255360, p.sigBytes = (u.length + 1) * 4, this._process();
|
|
3084
3117
|
for (var F = this._hash, y = F.words, g = 0; g < 4; g++) {
|
|
3085
|
-
var
|
|
3086
|
-
y[g] = (
|
|
3118
|
+
var D = y[g];
|
|
3119
|
+
y[g] = (D << 8 | D >>> 24) & 16711935 | (D << 24 | D >>> 8) & 4278255360;
|
|
3087
3120
|
}
|
|
3088
3121
|
return F;
|
|
3089
3122
|
},
|
|
@@ -3113,12 +3146,12 @@ function C0() {
|
|
|
3113
3146
|
});
|
|
3114
3147
|
})(ee)), ee.exports;
|
|
3115
3148
|
}
|
|
3116
|
-
var te = { exports: {} },
|
|
3149
|
+
var te = { exports: {} }, Go = te.exports, zt;
|
|
3117
3150
|
function Lr() {
|
|
3118
3151
|
return zt || (zt = 1, (function(e, t) {
|
|
3119
3152
|
(function(r, n) {
|
|
3120
|
-
e.exports = n(
|
|
3121
|
-
})(
|
|
3153
|
+
e.exports = n(I());
|
|
3154
|
+
})(Go, function(r) {
|
|
3122
3155
|
return (function() {
|
|
3123
3156
|
var n = r, o = n.lib, a = o.WordArray, x = o.Hasher, f = n.algo, v = [], i = f.SHA1 = x.extend({
|
|
3124
3157
|
_doReset: function() {
|
|
@@ -3161,7 +3194,7 @@ var re = { exports: {} }, Qo = re.exports, Ut;
|
|
|
3161
3194
|
function et() {
|
|
3162
3195
|
return Ut || (Ut = 1, (function(e, t) {
|
|
3163
3196
|
(function(r, n) {
|
|
3164
|
-
e.exports = n(
|
|
3197
|
+
e.exports = n(I());
|
|
3165
3198
|
})(Qo, function(r) {
|
|
3166
3199
|
return (function(n) {
|
|
3167
3200
|
var o = r, a = o.lib, x = a.WordArray, f = a.Hasher, v = o.algo, i = [], s = [];
|
|
@@ -3183,14 +3216,14 @@ function et() {
|
|
|
3183
3216
|
this._hash = new x.init(i.slice(0));
|
|
3184
3217
|
},
|
|
3185
3218
|
_doProcessBlock: function(E, c) {
|
|
3186
|
-
for (var p = this._hash.words, u = p[0], A = p[1], h = p[2], d = p[3], C = p[4], F = p[5], y = p[6], g = p[7],
|
|
3187
|
-
if (
|
|
3188
|
-
B[
|
|
3219
|
+
for (var p = this._hash.words, u = p[0], A = p[1], h = p[2], d = p[3], C = p[4], F = p[5], y = p[6], g = p[7], D = 0; D < 64; D++) {
|
|
3220
|
+
if (D < 16)
|
|
3221
|
+
B[D] = E[c + D] | 0;
|
|
3189
3222
|
else {
|
|
3190
|
-
var H = B[
|
|
3191
|
-
B[
|
|
3223
|
+
var H = B[D - 15], m = (H << 25 | H >>> 7) ^ (H << 14 | H >>> 18) ^ H >>> 3, b = B[D - 2], k = (b << 15 | b >>> 17) ^ (b << 13 | b >>> 19) ^ b >>> 10;
|
|
3224
|
+
B[D] = m + B[D - 7] + k + B[D - 16];
|
|
3192
3225
|
}
|
|
3193
|
-
var S = C & F ^ ~C & y, P = u & A ^ u & h ^ A & h, q = (u << 30 | u >>> 2) ^ (u << 19 | u >>> 13) ^ (u << 10 | u >>> 22), N = (C << 26 | C >>> 6) ^ (C << 21 | C >>> 11) ^ (C << 7 | C >>> 25), M = g + N + S + s[
|
|
3226
|
+
var S = C & F ^ ~C & y, P = u & A ^ u & h ^ A & h, q = (u << 30 | u >>> 2) ^ (u << 19 | u >>> 13) ^ (u << 10 | u >>> 22), N = (C << 26 | C >>> 6) ^ (C << 21 | C >>> 11) ^ (C << 7 | C >>> 25), M = g + N + S + s[D] + B[D], z = q + P;
|
|
3194
3227
|
g = y, y = F, F = C, C = d + M | 0, d = h, h = A, A = u, u = M + z | 0;
|
|
3195
3228
|
}
|
|
3196
3229
|
p[0] = p[0] + u | 0, p[1] = p[1] + A | 0, p[2] = p[2] + h | 0, p[3] = p[3] + d | 0, p[4] = p[4] + C | 0, p[5] = p[5] + F | 0, p[6] = p[6] + y | 0, p[7] = p[7] + g | 0;
|
|
@@ -3213,7 +3246,7 @@ var ne = { exports: {} }, Zo = ne.exports, It;
|
|
|
3213
3246
|
function Jo() {
|
|
3214
3247
|
return It || (It = 1, (function(e, t) {
|
|
3215
3248
|
(function(r, n, o) {
|
|
3216
|
-
e.exports = n(
|
|
3249
|
+
e.exports = n(I(), et());
|
|
3217
3250
|
})(Zo, function(r) {
|
|
3218
3251
|
return (function() {
|
|
3219
3252
|
var n = r, o = n.lib, a = o.WordArray, x = n.algo, f = x.SHA256, v = x.SHA224 = f.extend({
|
|
@@ -3243,7 +3276,7 @@ var oe = { exports: {} }, Yo = oe.exports, jt;
|
|
|
3243
3276
|
function zr() {
|
|
3244
3277
|
return jt || (jt = 1, (function(e, t) {
|
|
3245
3278
|
(function(r, n, o) {
|
|
3246
|
-
e.exports = n(
|
|
3279
|
+
e.exports = n(I(), qe());
|
|
3247
3280
|
})(Yo, function(r) {
|
|
3248
3281
|
return (function() {
|
|
3249
3282
|
var n = r, o = n.lib, a = o.Hasher, x = n.x64, f = x.Word, v = x.WordArray, i = n.algo;
|
|
@@ -3350,18 +3383,18 @@ function zr() {
|
|
|
3350
3383
|
]);
|
|
3351
3384
|
},
|
|
3352
3385
|
_doProcessBlock: function(c, p) {
|
|
3353
|
-
for (var u = this._hash.words, A = u[0], h = u[1], d = u[2], C = u[3], F = u[4], y = u[5], g = u[6],
|
|
3354
|
-
var
|
|
3355
|
-
if (
|
|
3356
|
-
l0 = j0.high = c[p +
|
|
3386
|
+
for (var u = this._hash.words, A = u[0], h = u[1], d = u[2], C = u[3], F = u[4], y = u[5], g = u[6], D = u[7], H = A.high, m = A.low, b = h.high, k = h.low, S = d.high, P = d.low, q = C.high, N = C.low, M = F.high, z = F.low, $ = y.high, W = y.low, _ = g.high, R = g.low, O = D.high, T = D.low, K = H, X = m, Z = b, U = k, D0 = S, A0 = P, Le = q, _0 = N, i0 = M, n0 = z, U0 = $, S0 = W, I0 = _, k0 = R, ze = O, T0 = T, s0 = 0; s0 < 80; s0++) {
|
|
3387
|
+
var a0, l0, j0 = l[s0];
|
|
3388
|
+
if (s0 < 16)
|
|
3389
|
+
l0 = j0.high = c[p + s0 * 2] | 0, a0 = j0.low = c[p + s0 * 2 + 1] | 0;
|
|
3357
3390
|
else {
|
|
3358
|
-
var nt = l[
|
|
3359
|
-
|
|
3391
|
+
var nt = l[s0 - 15], m0 = nt.high, R0 = nt.low, jr = (m0 >>> 1 | R0 << 31) ^ (m0 >>> 8 | R0 << 24) ^ m0 >>> 7, ot = (R0 >>> 1 | m0 << 31) ^ (R0 >>> 8 | m0 << 24) ^ (R0 >>> 7 | m0 << 25), at = l[s0 - 2], F0 = at.high, O0 = at.low, Wr = (F0 >>> 19 | O0 << 13) ^ (F0 << 3 | O0 >>> 29) ^ F0 >>> 6, it = (O0 >>> 19 | F0 << 13) ^ (O0 << 3 | F0 >>> 29) ^ (O0 >>> 6 | F0 << 26), st = l[s0 - 7], $r = st.high, Mr = st.low, xt = l[s0 - 16], Kr = xt.high, ct = xt.low;
|
|
3392
|
+
a0 = ot + Mr, l0 = jr + $r + (a0 >>> 0 < ot >>> 0 ? 1 : 0), a0 = a0 + it, l0 = l0 + Wr + (a0 >>> 0 < it >>> 0 ? 1 : 0), a0 = a0 + ct, l0 = l0 + Kr + (a0 >>> 0 < ct >>> 0 ? 1 : 0), j0.high = l0, j0.low = a0;
|
|
3360
3393
|
}
|
|
3361
|
-
var Xr =
|
|
3362
|
-
ze = I0, T0 = k0, I0 = U0, k0 = S0, U0 =
|
|
3394
|
+
var Xr = i0 & U0 ^ ~i0 & I0, ft = n0 & S0 ^ ~n0 & k0, Vr = K & Z ^ K & D0 ^ Z & D0, Gr = X & U ^ X & A0 ^ U & A0, Qr = (K >>> 28 | X << 4) ^ (K << 30 | X >>> 2) ^ (K << 25 | X >>> 7), lt = (X >>> 28 | K << 4) ^ (X << 30 | K >>> 2) ^ (X << 25 | K >>> 7), Zr = (i0 >>> 14 | n0 << 18) ^ (i0 >>> 18 | n0 << 14) ^ (i0 << 23 | n0 >>> 9), Jr = (n0 >>> 14 | i0 << 18) ^ (n0 >>> 18 | i0 << 14) ^ (n0 << 23 | i0 >>> 9), ut = B[s0], Yr = ut.high, dt = ut.low, o0 = T0 + Jr, u0 = ze + Zr + (o0 >>> 0 < T0 >>> 0 ? 1 : 0), o0 = o0 + ft, u0 = u0 + Xr + (o0 >>> 0 < ft >>> 0 ? 1 : 0), o0 = o0 + dt, u0 = u0 + Yr + (o0 >>> 0 < dt >>> 0 ? 1 : 0), o0 = o0 + a0, u0 = u0 + l0 + (o0 >>> 0 < a0 >>> 0 ? 1 : 0), ht = lt + Gr, en = Qr + Vr + (ht >>> 0 < lt >>> 0 ? 1 : 0);
|
|
3395
|
+
ze = I0, T0 = k0, I0 = U0, k0 = S0, U0 = i0, S0 = n0, n0 = _0 + o0 | 0, i0 = Le + u0 + (n0 >>> 0 < _0 >>> 0 ? 1 : 0) | 0, Le = D0, _0 = A0, D0 = Z, A0 = U, Z = K, U = X, X = o0 + ht | 0, K = u0 + en + (X >>> 0 < o0 >>> 0 ? 1 : 0) | 0;
|
|
3363
3396
|
}
|
|
3364
|
-
m = A.low = m + X, A.high = H + K + (m >>> 0 < X >>> 0 ? 1 : 0), k = h.low = k + U, h.high =
|
|
3397
|
+
m = A.low = m + X, A.high = H + K + (m >>> 0 < X >>> 0 ? 1 : 0), k = h.low = k + U, h.high = b + Z + (k >>> 0 < U >>> 0 ? 1 : 0), P = d.low = P + A0, d.high = S + D0 + (P >>> 0 < A0 >>> 0 ? 1 : 0), N = C.low = N + _0, C.high = q + Le + (N >>> 0 < _0 >>> 0 ? 1 : 0), z = F.low = z + n0, F.high = M + i0 + (z >>> 0 < n0 >>> 0 ? 1 : 0), W = y.low = W + S0, y.high = $ + U0 + (W >>> 0 < S0 >>> 0 ? 1 : 0), R = g.low = R + k0, g.high = _ + I0 + (R >>> 0 < k0 >>> 0 ? 1 : 0), T = D.low = T + T0, D.high = O + ze + (T >>> 0 < T0 >>> 0 ? 1 : 0);
|
|
3365
3398
|
},
|
|
3366
3399
|
_doFinalize: function() {
|
|
3367
3400
|
var c = this._data, p = c.words, u = this._nDataBytes * 8, A = c.sigBytes * 8;
|
|
@@ -3384,7 +3417,7 @@ var ae = { exports: {} }, ea = ae.exports, Wt;
|
|
|
3384
3417
|
function ta() {
|
|
3385
3418
|
return Wt || (Wt = 1, (function(e, t) {
|
|
3386
3419
|
(function(r, n, o) {
|
|
3387
|
-
e.exports = n(
|
|
3420
|
+
e.exports = n(I(), qe(), zr());
|
|
3388
3421
|
})(ea, function(r) {
|
|
3389
3422
|
return (function() {
|
|
3390
3423
|
var n = r, o = n.x64, a = o.Word, x = o.WordArray, f = n.algo, v = f.SHA512, i = f.SHA384 = v.extend({
|
|
@@ -3414,7 +3447,7 @@ var ie = { exports: {} }, ra = ie.exports, $t;
|
|
|
3414
3447
|
function na() {
|
|
3415
3448
|
return $t || ($t = 1, (function(e, t) {
|
|
3416
3449
|
(function(r, n, o) {
|
|
3417
|
-
e.exports = n(
|
|
3450
|
+
e.exports = n(I(), qe());
|
|
3418
3451
|
})(ra, function(r) {
|
|
3419
3452
|
return (function(n) {
|
|
3420
3453
|
var o = r, a = o.lib, x = a.WordArray, f = a.Hasher, v = o.x64, i = v.Word, s = o.algo, B = [], l = [], E = [];
|
|
@@ -3428,14 +3461,14 @@ function na() {
|
|
|
3428
3461
|
for (var A = 0; A < 5; A++)
|
|
3429
3462
|
l[u + 5 * A] = A + (2 * u + 3 * A) % 5 * 5;
|
|
3430
3463
|
for (var F = 1, y = 0; y < 24; y++) {
|
|
3431
|
-
for (var g = 0,
|
|
3464
|
+
for (var g = 0, D = 0, H = 0; H < 7; H++) {
|
|
3432
3465
|
if (F & 1) {
|
|
3433
3466
|
var m = (1 << H) - 1;
|
|
3434
|
-
m < 32 ?
|
|
3467
|
+
m < 32 ? D ^= 1 << m : g ^= 1 << m - 32;
|
|
3435
3468
|
}
|
|
3436
3469
|
F & 128 ? F = F << 1 ^ 113 : F <<= 1;
|
|
3437
3470
|
}
|
|
3438
|
-
E[y] = i.create(g,
|
|
3471
|
+
E[y] = i.create(g, D);
|
|
3439
3472
|
}
|
|
3440
3473
|
})();
|
|
3441
3474
|
var c = [];
|
|
@@ -3467,25 +3500,25 @@ function na() {
|
|
|
3467
3500
|
var g = h[C];
|
|
3468
3501
|
g.high ^= y, g.low ^= F;
|
|
3469
3502
|
}
|
|
3470
|
-
for (var
|
|
3503
|
+
for (var D = 0; D < 24; D++) {
|
|
3471
3504
|
for (var H = 0; H < 5; H++) {
|
|
3472
|
-
for (var m = 0,
|
|
3505
|
+
for (var m = 0, b = 0, k = 0; k < 5; k++) {
|
|
3473
3506
|
var g = h[H + 5 * k];
|
|
3474
|
-
m ^= g.high,
|
|
3507
|
+
m ^= g.high, b ^= g.low;
|
|
3475
3508
|
}
|
|
3476
3509
|
var S = c[H];
|
|
3477
|
-
S.high = m, S.low =
|
|
3510
|
+
S.high = m, S.low = b;
|
|
3478
3511
|
}
|
|
3479
3512
|
for (var H = 0; H < 5; H++)
|
|
3480
|
-
for (var P = c[(H + 4) % 5], q = c[(H + 1) % 5], N = q.high, M = q.low, m = P.high ^ (N << 1 | M >>> 31),
|
|
3513
|
+
for (var P = c[(H + 4) % 5], q = c[(H + 1) % 5], N = q.high, M = q.low, m = P.high ^ (N << 1 | M >>> 31), b = P.low ^ (M << 1 | N >>> 31), k = 0; k < 5; k++) {
|
|
3481
3514
|
var g = h[H + 5 * k];
|
|
3482
|
-
g.high ^= m, g.low ^=
|
|
3515
|
+
g.high ^= m, g.low ^= b;
|
|
3483
3516
|
}
|
|
3484
3517
|
for (var z = 1; z < 25; z++) {
|
|
3485
|
-
var m,
|
|
3486
|
-
_ < 32 ? (m = $ << _ | W >>> 32 - _,
|
|
3518
|
+
var m, b, g = h[z], $ = g.high, W = g.low, _ = B[z];
|
|
3519
|
+
_ < 32 ? (m = $ << _ | W >>> 32 - _, b = W << _ | $ >>> 32 - _) : (m = W << _ - 32 | $ >>> 64 - _, b = $ << _ - 32 | W >>> 64 - _);
|
|
3487
3520
|
var R = c[l[z]];
|
|
3488
|
-
R.high = m, R.low =
|
|
3521
|
+
R.high = m, R.low = b;
|
|
3489
3522
|
}
|
|
3490
3523
|
var O = c[0], T = h[0];
|
|
3491
3524
|
O.high = T.high, O.low = T.low;
|
|
@@ -3494,7 +3527,7 @@ function na() {
|
|
|
3494
3527
|
var z = H + 5 * k, g = h[z], K = c[z], X = c[(H + 1) % 5 + 5 * k], Z = c[(H + 2) % 5 + 5 * k];
|
|
3495
3528
|
g.high = K.high ^ ~X.high & Z.high, g.low = K.low ^ ~X.low & Z.low;
|
|
3496
3529
|
}
|
|
3497
|
-
var g = h[0], U = E[
|
|
3530
|
+
var g = h[0], U = E[D];
|
|
3498
3531
|
g.high ^= U.high, g.low ^= U.low;
|
|
3499
3532
|
}
|
|
3500
3533
|
},
|
|
@@ -3503,9 +3536,9 @@ function na() {
|
|
|
3503
3536
|
this._nDataBytes * 8;
|
|
3504
3537
|
var h = u.sigBytes * 8, d = this.blockSize * 32;
|
|
3505
3538
|
A[h >>> 5] |= 1 << 24 - h % 32, A[(n.ceil((h + 1) / d) * d >>> 5) - 1] |= 128, u.sigBytes = A.length * 4, this._process();
|
|
3506
|
-
for (var C = this._state, F = this.cfg.outputLength / 8, y = F / 8, g = [],
|
|
3507
|
-
var H = C[
|
|
3508
|
-
m = (m << 8 | m >>> 24) & 16711935 | (m << 24 | m >>> 8) & 4278255360,
|
|
3539
|
+
for (var C = this._state, F = this.cfg.outputLength / 8, y = F / 8, g = [], D = 0; D < y; D++) {
|
|
3540
|
+
var H = C[D], m = H.high, b = H.low;
|
|
3541
|
+
m = (m << 8 | m >>> 24) & 16711935 | (m << 24 | m >>> 8) & 4278255360, b = (b << 8 | b >>> 24) & 16711935 | (b << 24 | b >>> 8) & 4278255360, g.push(b), g.push(m);
|
|
3509
3542
|
}
|
|
3510
3543
|
return new x.init(g, F);
|
|
3511
3544
|
},
|
|
@@ -3524,7 +3557,7 @@ var se = { exports: {} }, oa = se.exports, Mt;
|
|
|
3524
3557
|
function aa() {
|
|
3525
3558
|
return Mt || (Mt = 1, (function(e, t) {
|
|
3526
3559
|
(function(r, n) {
|
|
3527
|
-
e.exports = n(
|
|
3560
|
+
e.exports = n(I());
|
|
3528
3561
|
})(oa, function(r) {
|
|
3529
3562
|
/** @preserve
|
|
3530
3563
|
(c) 2012 by Cédric Mesnil. All rights reserved.
|
|
@@ -3866,22 +3899,22 @@ function aa() {
|
|
|
3866
3899
|
this._hash = x.create([1732584193, 4023233417, 2562383102, 271733878, 3285377520]);
|
|
3867
3900
|
},
|
|
3868
3901
|
_doProcessBlock: function(y, g) {
|
|
3869
|
-
for (var
|
|
3870
|
-
var H = g +
|
|
3902
|
+
for (var D = 0; D < 16; D++) {
|
|
3903
|
+
var H = g + D, m = y[H];
|
|
3871
3904
|
y[H] = (m << 8 | m >>> 24) & 16711935 | (m << 24 | m >>> 8) & 4278255360;
|
|
3872
3905
|
}
|
|
3873
|
-
var
|
|
3874
|
-
O = z =
|
|
3875
|
-
for (var U,
|
|
3876
|
-
U = z + y[g + P[
|
|
3877
|
-
U =
|
|
3906
|
+
var b = this._hash.words, k = E.words, S = c.words, P = i.words, q = s.words, N = B.words, M = l.words, z, $, W, _, R, O, T, K, X, Z;
|
|
3907
|
+
O = z = b[0], T = $ = b[1], K = W = b[2], X = _ = b[3], Z = R = b[4];
|
|
3908
|
+
for (var U, D = 0; D < 80; D += 1)
|
|
3909
|
+
U = z + y[g + P[D]] | 0, D < 16 ? U += u($, W, _) + k[0] : D < 32 ? U += A($, W, _) + k[1] : D < 48 ? U += h($, W, _) + k[2] : D < 64 ? U += d($, W, _) + k[3] : U += C($, W, _) + k[4], U = U | 0, U = F(U, N[D]), U = U + R | 0, z = R, R = _, _ = F(W, 10), W = $, $ = U, U = O + y[g + q[D]] | 0, D < 16 ? U += C(T, K, X) + S[0] : D < 32 ? U += d(T, K, X) + S[1] : D < 48 ? U += h(T, K, X) + S[2] : D < 64 ? U += A(T, K, X) + S[3] : U += u(T, K, X) + S[4], U = U | 0, U = F(U, M[D]), U = U + Z | 0, O = Z, Z = X, X = F(K, 10), K = T, T = U;
|
|
3910
|
+
U = b[1] + W + X | 0, b[1] = b[2] + _ + Z | 0, b[2] = b[3] + R + O | 0, b[3] = b[4] + z + T | 0, b[4] = b[0] + $ + K | 0, b[0] = U;
|
|
3878
3911
|
},
|
|
3879
3912
|
_doFinalize: function() {
|
|
3880
|
-
var y = this._data, g = y.words,
|
|
3881
|
-
g[H >>> 5] |= 128 << 24 - H % 32, g[(H + 64 >>> 9 << 4) + 14] = (
|
|
3882
|
-
for (var m = this._hash,
|
|
3883
|
-
var S =
|
|
3884
|
-
|
|
3913
|
+
var y = this._data, g = y.words, D = this._nDataBytes * 8, H = y.sigBytes * 8;
|
|
3914
|
+
g[H >>> 5] |= 128 << 24 - H % 32, g[(H + 64 >>> 9 << 4) + 14] = (D << 8 | D >>> 24) & 16711935 | (D << 24 | D >>> 8) & 4278255360, y.sigBytes = (g.length + 1) * 4, this._process();
|
|
3915
|
+
for (var m = this._hash, b = m.words, k = 0; k < 5; k++) {
|
|
3916
|
+
var S = b[k];
|
|
3917
|
+
b[k] = (S << 8 | S >>> 24) & 16711935 | (S << 24 | S >>> 8) & 4278255360;
|
|
3885
3918
|
}
|
|
3886
3919
|
return m;
|
|
3887
3920
|
},
|
|
@@ -3890,20 +3923,20 @@ function aa() {
|
|
|
3890
3923
|
return y._hash = this._hash.clone(), y;
|
|
3891
3924
|
}
|
|
3892
3925
|
});
|
|
3893
|
-
function u(y, g,
|
|
3894
|
-
return y ^ g ^
|
|
3926
|
+
function u(y, g, D) {
|
|
3927
|
+
return y ^ g ^ D;
|
|
3895
3928
|
}
|
|
3896
|
-
function A(y, g,
|
|
3897
|
-
return y & g | ~y &
|
|
3929
|
+
function A(y, g, D) {
|
|
3930
|
+
return y & g | ~y & D;
|
|
3898
3931
|
}
|
|
3899
|
-
function h(y, g,
|
|
3900
|
-
return (y | ~g) ^
|
|
3932
|
+
function h(y, g, D) {
|
|
3933
|
+
return (y | ~g) ^ D;
|
|
3901
3934
|
}
|
|
3902
|
-
function d(y, g,
|
|
3903
|
-
return y &
|
|
3935
|
+
function d(y, g, D) {
|
|
3936
|
+
return y & D | g & ~D;
|
|
3904
3937
|
}
|
|
3905
|
-
function C(y, g,
|
|
3906
|
-
return y ^ (g | ~
|
|
3938
|
+
function C(y, g, D) {
|
|
3939
|
+
return y ^ (g | ~D);
|
|
3907
3940
|
}
|
|
3908
3941
|
function F(y, g) {
|
|
3909
3942
|
return y << g | y >>> 32 - g;
|
|
@@ -3917,7 +3950,7 @@ var xe = { exports: {} }, ia = xe.exports, Kt;
|
|
|
3917
3950
|
function tt() {
|
|
3918
3951
|
return Kt || (Kt = 1, (function(e, t) {
|
|
3919
3952
|
(function(r, n) {
|
|
3920
|
-
e.exports = n(
|
|
3953
|
+
e.exports = n(I());
|
|
3921
3954
|
})(ia, function(r) {
|
|
3922
3955
|
(function() {
|
|
3923
3956
|
var n = r, o = n.lib, a = o.Base, x = n.enc, f = x.Utf8, v = n.algo;
|
|
@@ -3995,7 +4028,7 @@ var ce = { exports: {} }, sa = ce.exports, Xt;
|
|
|
3995
4028
|
function xa() {
|
|
3996
4029
|
return Xt || (Xt = 1, (function(e, t) {
|
|
3997
4030
|
(function(r, n, o) {
|
|
3998
|
-
e.exports = n(
|
|
4031
|
+
e.exports = n(I(), et(), tt());
|
|
3999
4032
|
})(sa, function(r) {
|
|
4000
4033
|
return (function() {
|
|
4001
4034
|
var n = r, o = n.lib, a = o.Base, x = o.WordArray, f = n.algo, v = f.SHA256, i = f.HMAC, s = f.PBKDF2 = a.extend({
|
|
@@ -4041,10 +4074,10 @@ function xa() {
|
|
|
4041
4074
|
for (var E = this.cfg, c = i.create(E.hasher, B), p = x.create(), u = x.create([1]), A = p.words, h = u.words, d = E.keySize, C = E.iterations; A.length < d; ) {
|
|
4042
4075
|
var F = c.update(l).finalize(u);
|
|
4043
4076
|
c.reset();
|
|
4044
|
-
for (var y = F.words, g = y.length,
|
|
4045
|
-
|
|
4046
|
-
for (var m =
|
|
4047
|
-
y[
|
|
4077
|
+
for (var y = F.words, g = y.length, D = F, H = 1; H < C; H++) {
|
|
4078
|
+
D = c.finalize(D), c.reset();
|
|
4079
|
+
for (var m = D.words, b = 0; b < g; b++)
|
|
4080
|
+
y[b] ^= m[b];
|
|
4048
4081
|
}
|
|
4049
4082
|
p.concat(F), h[0]++;
|
|
4050
4083
|
}
|
|
@@ -4058,11 +4091,11 @@ function xa() {
|
|
|
4058
4091
|
});
|
|
4059
4092
|
})(ce)), ce.exports;
|
|
4060
4093
|
}
|
|
4061
|
-
var fe = { exports: {} }, ca = fe.exports,
|
|
4094
|
+
var fe = { exports: {} }, ca = fe.exports, Vt;
|
|
4062
4095
|
function h0() {
|
|
4063
|
-
return
|
|
4096
|
+
return Vt || (Vt = 1, (function(e, t) {
|
|
4064
4097
|
(function(r, n, o) {
|
|
4065
|
-
e.exports = n(
|
|
4098
|
+
e.exports = n(I(), Lr(), tt());
|
|
4066
4099
|
})(ca, function(r) {
|
|
4067
4100
|
return (function() {
|
|
4068
4101
|
var n = r, o = n.lib, a = o.Base, x = o.WordArray, f = n.algo, v = f.MD5, i = f.EvpKDF = a.extend({
|
|
@@ -4121,11 +4154,11 @@ function h0() {
|
|
|
4121
4154
|
});
|
|
4122
4155
|
})(fe)), fe.exports;
|
|
4123
4156
|
}
|
|
4124
|
-
var le = { exports: {} }, fa = le.exports,
|
|
4125
|
-
function
|
|
4126
|
-
return
|
|
4157
|
+
var le = { exports: {} }, fa = le.exports, Gt;
|
|
4158
|
+
function G() {
|
|
4159
|
+
return Gt || (Gt = 1, (function(e, t) {
|
|
4127
4160
|
(function(r, n, o) {
|
|
4128
|
-
e.exports = n(
|
|
4161
|
+
e.exports = n(I(), h0());
|
|
4129
4162
|
})(fa, function(r) {
|
|
4130
4163
|
r.lib.Cipher || (function(n) {
|
|
4131
4164
|
var o = r, a = o.lib, x = a.Base, f = a.WordArray, v = a.BufferedBlockAlgorithm, i = o.enc;
|
|
@@ -4151,8 +4184,8 @@ function V() {
|
|
|
4151
4184
|
*
|
|
4152
4185
|
* var cipher = CryptoJS.algo.AES.createEncryptor(keyWordArray, { iv: ivWordArray });
|
|
4153
4186
|
*/
|
|
4154
|
-
createEncryptor: function(m,
|
|
4155
|
-
return this.create(this._ENC_XFORM_MODE, m,
|
|
4187
|
+
createEncryptor: function(m, b) {
|
|
4188
|
+
return this.create(this._ENC_XFORM_MODE, m, b);
|
|
4156
4189
|
},
|
|
4157
4190
|
/**
|
|
4158
4191
|
* Creates this cipher in decryption mode.
|
|
@@ -4168,8 +4201,8 @@ function V() {
|
|
|
4168
4201
|
*
|
|
4169
4202
|
* var cipher = CryptoJS.algo.AES.createDecryptor(keyWordArray, { iv: ivWordArray });
|
|
4170
4203
|
*/
|
|
4171
|
-
createDecryptor: function(m,
|
|
4172
|
-
return this.create(this._DEC_XFORM_MODE, m,
|
|
4204
|
+
createDecryptor: function(m, b) {
|
|
4205
|
+
return this.create(this._DEC_XFORM_MODE, m, b);
|
|
4173
4206
|
},
|
|
4174
4207
|
/**
|
|
4175
4208
|
* Initializes a newly created cipher.
|
|
@@ -4182,8 +4215,8 @@ function V() {
|
|
|
4182
4215
|
*
|
|
4183
4216
|
* var cipher = CryptoJS.algo.AES.create(CryptoJS.algo.AES._ENC_XFORM_MODE, keyWordArray, { iv: ivWordArray });
|
|
4184
4217
|
*/
|
|
4185
|
-
init: function(m,
|
|
4186
|
-
this.cfg = this.cfg.extend(k), this._xformMode = m, this._key =
|
|
4218
|
+
init: function(m, b, k) {
|
|
4219
|
+
this.cfg = this.cfg.extend(k), this._xformMode = m, this._key = b, this.reset();
|
|
4187
4220
|
},
|
|
4188
4221
|
/**
|
|
4189
4222
|
* Resets this cipher to its initial state.
|
|
@@ -4226,8 +4259,8 @@ function V() {
|
|
|
4226
4259
|
*/
|
|
4227
4260
|
finalize: function(m) {
|
|
4228
4261
|
m && this._append(m);
|
|
4229
|
-
var
|
|
4230
|
-
return
|
|
4262
|
+
var b = this._doFinalize();
|
|
4263
|
+
return b;
|
|
4231
4264
|
},
|
|
4232
4265
|
keySize: 128 / 32,
|
|
4233
4266
|
ivSize: 128 / 32,
|
|
@@ -4247,16 +4280,16 @@ function V() {
|
|
|
4247
4280
|
* var AES = CryptoJS.lib.Cipher._createHelper(CryptoJS.algo.AES);
|
|
4248
4281
|
*/
|
|
4249
4282
|
_createHelper: /* @__PURE__ */ (function() {
|
|
4250
|
-
function m(
|
|
4251
|
-
return typeof
|
|
4283
|
+
function m(b) {
|
|
4284
|
+
return typeof b == "string" ? H : y;
|
|
4252
4285
|
}
|
|
4253
|
-
return function(
|
|
4286
|
+
return function(b) {
|
|
4254
4287
|
return {
|
|
4255
4288
|
encrypt: function(k, S, P) {
|
|
4256
|
-
return m(S).encrypt(
|
|
4289
|
+
return m(S).encrypt(b, k, S, P);
|
|
4257
4290
|
},
|
|
4258
4291
|
decrypt: function(k, S, P) {
|
|
4259
|
-
return m(S).decrypt(
|
|
4292
|
+
return m(S).decrypt(b, k, S, P);
|
|
4260
4293
|
}
|
|
4261
4294
|
};
|
|
4262
4295
|
};
|
|
@@ -4282,8 +4315,8 @@ function V() {
|
|
|
4282
4315
|
*
|
|
4283
4316
|
* var mode = CryptoJS.mode.CBC.createEncryptor(cipher, iv.words);
|
|
4284
4317
|
*/
|
|
4285
|
-
createEncryptor: function(m,
|
|
4286
|
-
return this.Encryptor.create(m,
|
|
4318
|
+
createEncryptor: function(m, b) {
|
|
4319
|
+
return this.Encryptor.create(m, b);
|
|
4287
4320
|
},
|
|
4288
4321
|
/**
|
|
4289
4322
|
* Creates this mode for decryption.
|
|
@@ -4297,8 +4330,8 @@ function V() {
|
|
|
4297
4330
|
*
|
|
4298
4331
|
* var mode = CryptoJS.mode.CBC.createDecryptor(cipher, iv.words);
|
|
4299
4332
|
*/
|
|
4300
|
-
createDecryptor: function(m,
|
|
4301
|
-
return this.Decryptor.create(m,
|
|
4333
|
+
createDecryptor: function(m, b) {
|
|
4334
|
+
return this.Decryptor.create(m, b);
|
|
4302
4335
|
},
|
|
4303
4336
|
/**
|
|
4304
4337
|
* Initializes a newly created mode.
|
|
@@ -4310,8 +4343,8 @@ function V() {
|
|
|
4310
4343
|
*
|
|
4311
4344
|
* var mode = CryptoJS.mode.CBC.Encryptor.create(cipher, iv.words);
|
|
4312
4345
|
*/
|
|
4313
|
-
init: function(m,
|
|
4314
|
-
this._cipher = m, this._iv =
|
|
4346
|
+
init: function(m, b) {
|
|
4347
|
+
this._cipher = m, this._iv = b;
|
|
4315
4348
|
}
|
|
4316
4349
|
}), u = c.CBC = (function() {
|
|
4317
4350
|
var m = p.extend();
|
|
@@ -4328,7 +4361,7 @@ function V() {
|
|
|
4328
4361
|
*/
|
|
4329
4362
|
processBlock: function(k, S) {
|
|
4330
4363
|
var P = this._cipher, q = P.blockSize;
|
|
4331
|
-
|
|
4364
|
+
b.call(this, k, S, q), P.encryptBlock(k, S), this._prevBlock = k.slice(S, S + q);
|
|
4332
4365
|
}
|
|
4333
4366
|
}), m.Decryptor = m.extend({
|
|
4334
4367
|
/**
|
|
@@ -4343,10 +4376,10 @@ function V() {
|
|
|
4343
4376
|
*/
|
|
4344
4377
|
processBlock: function(k, S) {
|
|
4345
4378
|
var P = this._cipher, q = P.blockSize, N = k.slice(S, S + q);
|
|
4346
|
-
P.decryptBlock(k, S),
|
|
4379
|
+
P.decryptBlock(k, S), b.call(this, k, S, q), this._prevBlock = N;
|
|
4347
4380
|
}
|
|
4348
4381
|
});
|
|
4349
|
-
function
|
|
4382
|
+
function b(k, S, P) {
|
|
4350
4383
|
var q, N = this._iv;
|
|
4351
4384
|
N ? (q = N, this._iv = n) : q = this._prevBlock;
|
|
4352
4385
|
for (var M = 0; M < P; M++)
|
|
@@ -4366,8 +4399,8 @@ function V() {
|
|
|
4366
4399
|
*
|
|
4367
4400
|
* CryptoJS.pad.Pkcs7.pad(wordArray, 4);
|
|
4368
4401
|
*/
|
|
4369
|
-
pad: function(m,
|
|
4370
|
-
for (var k =
|
|
4402
|
+
pad: function(m, b) {
|
|
4403
|
+
for (var k = b * 4, S = k - m.sigBytes % k, P = S << 24 | S << 16 | S << 8 | S, q = [], N = 0; N < S; N += 4)
|
|
4371
4404
|
q.push(P);
|
|
4372
4405
|
var M = f.create(q, S);
|
|
4373
4406
|
m.concat(M);
|
|
@@ -4384,8 +4417,8 @@ function V() {
|
|
|
4384
4417
|
* CryptoJS.pad.Pkcs7.unpad(wordArray);
|
|
4385
4418
|
*/
|
|
4386
4419
|
unpad: function(m) {
|
|
4387
|
-
var
|
|
4388
|
-
m.sigBytes -=
|
|
4420
|
+
var b = m.words[m.sigBytes - 1 >>> 2] & 255;
|
|
4421
|
+
m.sigBytes -= b;
|
|
4389
4422
|
}
|
|
4390
4423
|
};
|
|
4391
4424
|
a.BlockCipher = E.extend({
|
|
@@ -4402,15 +4435,15 @@ function V() {
|
|
|
4402
4435
|
reset: function() {
|
|
4403
4436
|
var m;
|
|
4404
4437
|
E.reset.call(this);
|
|
4405
|
-
var
|
|
4438
|
+
var b = this.cfg, k = b.iv, S = b.mode;
|
|
4406
4439
|
this._xformMode == this._ENC_XFORM_MODE ? m = S.createEncryptor : (m = S.createDecryptor, this._minBufferSize = 1), this._mode && this._mode.__creator == m ? this._mode.init(this, k && k.words) : (this._mode = m.call(S, this, k && k.words), this._mode.__creator = m);
|
|
4407
4440
|
},
|
|
4408
|
-
_doProcessBlock: function(m,
|
|
4409
|
-
this._mode.processBlock(m,
|
|
4441
|
+
_doProcessBlock: function(m, b) {
|
|
4442
|
+
this._mode.processBlock(m, b);
|
|
4410
4443
|
},
|
|
4411
4444
|
_doFinalize: function() {
|
|
4412
|
-
var m,
|
|
4413
|
-
return this._xformMode == this._ENC_XFORM_MODE ? (
|
|
4445
|
+
var m, b = this.cfg.padding;
|
|
4446
|
+
return this._xformMode == this._ENC_XFORM_MODE ? (b.pad(this._data, this.blockSize), m = this._process(!0)) : (m = this._process(!0), b.unpad(m)), m;
|
|
4414
4447
|
},
|
|
4415
4448
|
blockSize: 128 / 32
|
|
4416
4449
|
});
|
|
@@ -4470,8 +4503,8 @@ function V() {
|
|
|
4470
4503
|
* var openSSLString = CryptoJS.format.OpenSSL.stringify(cipherParams);
|
|
4471
4504
|
*/
|
|
4472
4505
|
stringify: function(m) {
|
|
4473
|
-
var
|
|
4474
|
-
return S ?
|
|
4506
|
+
var b, k = m.ciphertext, S = m.salt;
|
|
4507
|
+
return S ? b = f.create([1398893684, 1701076831]).concat(S).concat(k) : b = k, b.toString(s);
|
|
4475
4508
|
},
|
|
4476
4509
|
/**
|
|
4477
4510
|
* Converts an OpenSSL-compatible string to a cipher params object.
|
|
@@ -4487,8 +4520,8 @@ function V() {
|
|
|
4487
4520
|
* var cipherParams = CryptoJS.format.OpenSSL.parse(openSSLString);
|
|
4488
4521
|
*/
|
|
4489
4522
|
parse: function(m) {
|
|
4490
|
-
var
|
|
4491
|
-
return S[0] == 1398893684 && S[1] == 1701076831 && (
|
|
4523
|
+
var b, k = s.parse(m), S = k.words;
|
|
4524
|
+
return S[0] == 1398893684 && S[1] == 1701076831 && (b = f.create(S.slice(2, 4)), S.splice(0, 4), k.sigBytes -= 16), d.create({ ciphertext: k, salt: b });
|
|
4492
4525
|
}
|
|
4493
4526
|
}, y = a.SerializableCipher = x.extend({
|
|
4494
4527
|
/**
|
|
@@ -4517,9 +4550,9 @@ function V() {
|
|
|
4517
4550
|
* var ciphertextParams = CryptoJS.lib.SerializableCipher.encrypt(CryptoJS.algo.AES, message, key, { iv: iv });
|
|
4518
4551
|
* var ciphertextParams = CryptoJS.lib.SerializableCipher.encrypt(CryptoJS.algo.AES, message, key, { iv: iv, format: CryptoJS.format.OpenSSL });
|
|
4519
4552
|
*/
|
|
4520
|
-
encrypt: function(m,
|
|
4553
|
+
encrypt: function(m, b, k, S) {
|
|
4521
4554
|
S = this.cfg.extend(S);
|
|
4522
|
-
var P = m.createEncryptor(k, S), q = P.finalize(
|
|
4555
|
+
var P = m.createEncryptor(k, S), q = P.finalize(b), N = P.cfg;
|
|
4523
4556
|
return d.create({
|
|
4524
4557
|
ciphertext: q,
|
|
4525
4558
|
key: k,
|
|
@@ -4548,9 +4581,9 @@ function V() {
|
|
|
4548
4581
|
* var plaintext = CryptoJS.lib.SerializableCipher.decrypt(CryptoJS.algo.AES, formattedCiphertext, key, { iv: iv, format: CryptoJS.format.OpenSSL });
|
|
4549
4582
|
* var plaintext = CryptoJS.lib.SerializableCipher.decrypt(CryptoJS.algo.AES, ciphertextParams, key, { iv: iv, format: CryptoJS.format.OpenSSL });
|
|
4550
4583
|
*/
|
|
4551
|
-
decrypt: function(m,
|
|
4552
|
-
S = this.cfg.extend(S),
|
|
4553
|
-
var P = m.createDecryptor(k, S).finalize(
|
|
4584
|
+
decrypt: function(m, b, k, S) {
|
|
4585
|
+
S = this.cfg.extend(S), b = this._parse(b, S.format);
|
|
4586
|
+
var P = m.createDecryptor(k, S).finalize(b.ciphertext);
|
|
4554
4587
|
return P;
|
|
4555
4588
|
},
|
|
4556
4589
|
/**
|
|
@@ -4568,10 +4601,10 @@ function V() {
|
|
|
4568
4601
|
*
|
|
4569
4602
|
* var ciphertextParams = CryptoJS.lib.SerializableCipher._parse(ciphertextStringOrParams, format);
|
|
4570
4603
|
*/
|
|
4571
|
-
_parse: function(m,
|
|
4572
|
-
return typeof m == "string" ?
|
|
4604
|
+
_parse: function(m, b) {
|
|
4605
|
+
return typeof m == "string" ? b.parse(m, this) : m;
|
|
4573
4606
|
}
|
|
4574
|
-
}), g = o.kdf = {},
|
|
4607
|
+
}), g = o.kdf = {}, D = g.OpenSSL = {
|
|
4575
4608
|
/**
|
|
4576
4609
|
* Derives a key and IV from a password.
|
|
4577
4610
|
*
|
|
@@ -4589,13 +4622,13 @@ function V() {
|
|
|
4589
4622
|
* var derivedParams = CryptoJS.kdf.OpenSSL.execute('Password', 256/32, 128/32);
|
|
4590
4623
|
* var derivedParams = CryptoJS.kdf.OpenSSL.execute('Password', 256/32, 128/32, 'saltsalt');
|
|
4591
4624
|
*/
|
|
4592
|
-
execute: function(m,
|
|
4625
|
+
execute: function(m, b, k, S, P) {
|
|
4593
4626
|
if (S || (S = f.random(64 / 8)), P)
|
|
4594
|
-
var q = l.create({ keySize:
|
|
4627
|
+
var q = l.create({ keySize: b + k, hasher: P }).compute(m, S);
|
|
4595
4628
|
else
|
|
4596
|
-
var q = l.create({ keySize:
|
|
4597
|
-
var N = f.create(q.words.slice(
|
|
4598
|
-
return q.sigBytes =
|
|
4629
|
+
var q = l.create({ keySize: b + k }).compute(m, S);
|
|
4630
|
+
var N = f.create(q.words.slice(b), k * 4);
|
|
4631
|
+
return q.sigBytes = b * 4, d.create({ key: q, iv: N, salt: S });
|
|
4599
4632
|
}
|
|
4600
4633
|
}, H = a.PasswordBasedCipher = y.extend({
|
|
4601
4634
|
/**
|
|
@@ -4604,7 +4637,7 @@ function V() {
|
|
|
4604
4637
|
* @property {KDF} kdf The key derivation function to use to generate a key and IV from a password. Default: OpenSSL
|
|
4605
4638
|
*/
|
|
4606
4639
|
cfg: y.cfg.extend({
|
|
4607
|
-
kdf:
|
|
4640
|
+
kdf: D
|
|
4608
4641
|
}),
|
|
4609
4642
|
/**
|
|
4610
4643
|
* Encrypts a message using a password.
|
|
@@ -4623,11 +4656,11 @@ function V() {
|
|
|
4623
4656
|
* var ciphertextParams = CryptoJS.lib.PasswordBasedCipher.encrypt(CryptoJS.algo.AES, message, 'password');
|
|
4624
4657
|
* var ciphertextParams = CryptoJS.lib.PasswordBasedCipher.encrypt(CryptoJS.algo.AES, message, 'password', { format: CryptoJS.format.OpenSSL });
|
|
4625
4658
|
*/
|
|
4626
|
-
encrypt: function(m,
|
|
4659
|
+
encrypt: function(m, b, k, S) {
|
|
4627
4660
|
S = this.cfg.extend(S);
|
|
4628
4661
|
var P = S.kdf.execute(k, m.keySize, m.ivSize, S.salt, S.hasher);
|
|
4629
4662
|
S.iv = P.iv;
|
|
4630
|
-
var q = y.encrypt.call(this, m,
|
|
4663
|
+
var q = y.encrypt.call(this, m, b, P.key, S);
|
|
4631
4664
|
return q.mixIn(P), q;
|
|
4632
4665
|
},
|
|
4633
4666
|
/**
|
|
@@ -4647,11 +4680,11 @@ function V() {
|
|
|
4647
4680
|
* var plaintext = CryptoJS.lib.PasswordBasedCipher.decrypt(CryptoJS.algo.AES, formattedCiphertext, 'password', { format: CryptoJS.format.OpenSSL });
|
|
4648
4681
|
* var plaintext = CryptoJS.lib.PasswordBasedCipher.decrypt(CryptoJS.algo.AES, ciphertextParams, 'password', { format: CryptoJS.format.OpenSSL });
|
|
4649
4682
|
*/
|
|
4650
|
-
decrypt: function(m,
|
|
4651
|
-
S = this.cfg.extend(S),
|
|
4652
|
-
var P = S.kdf.execute(k, m.keySize, m.ivSize,
|
|
4683
|
+
decrypt: function(m, b, k, S) {
|
|
4684
|
+
S = this.cfg.extend(S), b = this._parse(b, S.format);
|
|
4685
|
+
var P = S.kdf.execute(k, m.keySize, m.ivSize, b.salt, S.hasher);
|
|
4653
4686
|
S.iv = P.iv;
|
|
4654
|
-
var q = y.decrypt.call(this, m,
|
|
4687
|
+
var q = y.decrypt.call(this, m, b, P.key, S);
|
|
4655
4688
|
return q;
|
|
4656
4689
|
}
|
|
4657
4690
|
});
|
|
@@ -4663,7 +4696,7 @@ var ue = { exports: {} }, la = ue.exports, Qt;
|
|
|
4663
4696
|
function ua() {
|
|
4664
4697
|
return Qt || (Qt = 1, (function(e, t) {
|
|
4665
4698
|
(function(r, n, o) {
|
|
4666
|
-
e.exports = n(
|
|
4699
|
+
e.exports = n(I(), G());
|
|
4667
4700
|
})(la, function(r) {
|
|
4668
4701
|
return r.mode.CFB = (function() {
|
|
4669
4702
|
var n = r.lib.BlockCipherMode.extend();
|
|
@@ -4693,7 +4726,7 @@ var de = { exports: {} }, da = de.exports, Zt;
|
|
|
4693
4726
|
function ha() {
|
|
4694
4727
|
return Zt || (Zt = 1, (function(e, t) {
|
|
4695
4728
|
(function(r, n, o) {
|
|
4696
|
-
e.exports = n(
|
|
4729
|
+
e.exports = n(I(), G());
|
|
4697
4730
|
})(da, function(r) {
|
|
4698
4731
|
return r.mode.CTR = (function() {
|
|
4699
4732
|
var n = r.lib.BlockCipherMode.extend(), o = n.Encryptor = n.extend({
|
|
@@ -4715,7 +4748,7 @@ var he = { exports: {} }, pa = he.exports, Jt;
|
|
|
4715
4748
|
function va() {
|
|
4716
4749
|
return Jt || (Jt = 1, (function(e, t) {
|
|
4717
4750
|
(function(r, n, o) {
|
|
4718
|
-
e.exports = n(
|
|
4751
|
+
e.exports = n(I(), G());
|
|
4719
4752
|
})(pa, function(r) {
|
|
4720
4753
|
/** @preserve
|
|
4721
4754
|
* Counter block mode compatible with Dr Brian Gladman fileenc.c
|
|
@@ -4754,7 +4787,7 @@ var pe = { exports: {} }, Ea = pe.exports, Yt;
|
|
|
4754
4787
|
function Ba() {
|
|
4755
4788
|
return Yt || (Yt = 1, (function(e, t) {
|
|
4756
4789
|
(function(r, n, o) {
|
|
4757
|
-
e.exports = n(
|
|
4790
|
+
e.exports = n(I(), G());
|
|
4758
4791
|
})(Ea, function(r) {
|
|
4759
4792
|
return r.mode.OFB = (function() {
|
|
4760
4793
|
var n = r.lib.BlockCipherMode.extend(), o = n.Encryptor = n.extend({
|
|
@@ -4774,7 +4807,7 @@ var ve = { exports: {} }, Ca = ve.exports, er;
|
|
|
4774
4807
|
function Aa() {
|
|
4775
4808
|
return er || (er = 1, (function(e, t) {
|
|
4776
4809
|
(function(r, n, o) {
|
|
4777
|
-
e.exports = n(
|
|
4810
|
+
e.exports = n(I(), G());
|
|
4778
4811
|
})(Ca, function(r) {
|
|
4779
4812
|
return r.mode.ECB = (function() {
|
|
4780
4813
|
var n = r.lib.BlockCipherMode.extend();
|
|
@@ -4795,7 +4828,7 @@ var Ee = { exports: {} }, ma = Ee.exports, tr;
|
|
|
4795
4828
|
function Fa() {
|
|
4796
4829
|
return tr || (tr = 1, (function(e, t) {
|
|
4797
4830
|
(function(r, n, o) {
|
|
4798
|
-
e.exports = n(
|
|
4831
|
+
e.exports = n(I(), G());
|
|
4799
4832
|
})(ma, function(r) {
|
|
4800
4833
|
return r.pad.AnsiX923 = {
|
|
4801
4834
|
pad: function(n, o) {
|
|
@@ -4814,7 +4847,7 @@ var Be = { exports: {} }, ya = Be.exports, rr;
|
|
|
4814
4847
|
function ga() {
|
|
4815
4848
|
return rr || (rr = 1, (function(e, t) {
|
|
4816
4849
|
(function(r, n, o) {
|
|
4817
|
-
e.exports = n(
|
|
4850
|
+
e.exports = n(I(), G());
|
|
4818
4851
|
})(ya, function(r) {
|
|
4819
4852
|
return r.pad.Iso10126 = {
|
|
4820
4853
|
pad: function(n, o) {
|
|
@@ -4829,12 +4862,12 @@ function ga() {
|
|
|
4829
4862
|
});
|
|
4830
4863
|
})(Be)), Be.exports;
|
|
4831
4864
|
}
|
|
4832
|
-
var Ce = { exports: {} },
|
|
4833
|
-
function
|
|
4865
|
+
var Ce = { exports: {} }, wa = Ce.exports, nr;
|
|
4866
|
+
function ba() {
|
|
4834
4867
|
return nr || (nr = 1, (function(e, t) {
|
|
4835
4868
|
(function(r, n, o) {
|
|
4836
|
-
e.exports = n(
|
|
4837
|
-
})(
|
|
4869
|
+
e.exports = n(I(), G());
|
|
4870
|
+
})(wa, function(r) {
|
|
4838
4871
|
return r.pad.Iso97971 = {
|
|
4839
4872
|
pad: function(n, o) {
|
|
4840
4873
|
n.concat(r.lib.WordArray.create([2147483648], 1)), r.pad.ZeroPadding.pad(n, o);
|
|
@@ -4846,12 +4879,12 @@ function Da() {
|
|
|
4846
4879
|
});
|
|
4847
4880
|
})(Ce)), Ce.exports;
|
|
4848
4881
|
}
|
|
4849
|
-
var Ae = { exports: {} },
|
|
4882
|
+
var Ae = { exports: {} }, Da = Ae.exports, or;
|
|
4850
4883
|
function _a() {
|
|
4851
4884
|
return or || (or = 1, (function(e, t) {
|
|
4852
4885
|
(function(r, n, o) {
|
|
4853
|
-
e.exports = n(
|
|
4854
|
-
})(
|
|
4886
|
+
e.exports = n(I(), G());
|
|
4887
|
+
})(Da, function(r) {
|
|
4855
4888
|
return r.pad.ZeroPadding = {
|
|
4856
4889
|
pad: function(n, o) {
|
|
4857
4890
|
var a = o * 4;
|
|
@@ -4872,7 +4905,7 @@ var me = { exports: {} }, Sa = me.exports, ar;
|
|
|
4872
4905
|
function ka() {
|
|
4873
4906
|
return ar || (ar = 1, (function(e, t) {
|
|
4874
4907
|
(function(r, n, o) {
|
|
4875
|
-
e.exports = n(
|
|
4908
|
+
e.exports = n(I(), G());
|
|
4876
4909
|
})(Sa, function(r) {
|
|
4877
4910
|
return r.pad.NoPadding = {
|
|
4878
4911
|
pad: function() {
|
|
@@ -4887,7 +4920,7 @@ var Fe = { exports: {} }, Ta = Fe.exports, ir;
|
|
|
4887
4920
|
function Ra() {
|
|
4888
4921
|
return ir || (ir = 1, (function(e, t) {
|
|
4889
4922
|
(function(r, n, o) {
|
|
4890
|
-
e.exports = n(
|
|
4923
|
+
e.exports = n(I(), G());
|
|
4891
4924
|
})(Ta, function(r) {
|
|
4892
4925
|
return (function(n) {
|
|
4893
4926
|
var o = r, a = o.lib, x = a.CipherParams, f = o.enc, v = f.Hex, i = o.format;
|
|
@@ -4934,7 +4967,7 @@ var ye = { exports: {} }, Oa = ye.exports, sr;
|
|
|
4934
4967
|
function Ha() {
|
|
4935
4968
|
return sr || (sr = 1, (function(e, t) {
|
|
4936
4969
|
(function(r, n, o) {
|
|
4937
|
-
e.exports = n(
|
|
4970
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
4938
4971
|
})(Oa, function(r) {
|
|
4939
4972
|
return (function() {
|
|
4940
4973
|
var n = r, o = n.lib, a = o.BlockCipher, x = n.algo, f = [], v = [], i = [], s = [], B = [], l = [], E = [], c = [], p = [], u = [];
|
|
@@ -4944,25 +4977,25 @@ function Ha() {
|
|
|
4944
4977
|
for (var F = 0, y = 0, C = 0; C < 256; C++) {
|
|
4945
4978
|
var g = y ^ y << 1 ^ y << 2 ^ y << 3 ^ y << 4;
|
|
4946
4979
|
g = g >>> 8 ^ g & 255 ^ 99, f[F] = g, v[g] = F;
|
|
4947
|
-
var
|
|
4948
|
-
i[F] =
|
|
4949
|
-
var
|
|
4950
|
-
E[g] =
|
|
4980
|
+
var D = d[F], H = d[D], m = d[H], b = d[g] * 257 ^ g * 16843008;
|
|
4981
|
+
i[F] = b << 24 | b >>> 8, s[F] = b << 16 | b >>> 16, B[F] = b << 8 | b >>> 24, l[F] = b;
|
|
4982
|
+
var b = m * 16843009 ^ H * 65537 ^ D * 257 ^ F * 16843008;
|
|
4983
|
+
E[g] = b << 24 | b >>> 8, c[g] = b << 16 | b >>> 16, p[g] = b << 8 | b >>> 24, u[g] = b, F ? (F = D ^ d[d[d[m ^ D]]], y ^= d[d[y]]) : F = y = 1;
|
|
4951
4984
|
}
|
|
4952
4985
|
})();
|
|
4953
4986
|
var A = [0, 1, 2, 4, 8, 16, 32, 64, 128, 27, 54], h = x.AES = a.extend({
|
|
4954
4987
|
_doReset: function() {
|
|
4955
4988
|
var d;
|
|
4956
4989
|
if (!(this._nRounds && this._keyPriorReset === this._key)) {
|
|
4957
|
-
for (var C = this._keyPriorReset = this._key, F = C.words, y = C.sigBytes / 4, g = this._nRounds = y + 6,
|
|
4990
|
+
for (var C = this._keyPriorReset = this._key, F = C.words, y = C.sigBytes / 4, g = this._nRounds = y + 6, D = (g + 1) * 4, H = this._keySchedule = [], m = 0; m < D; m++)
|
|
4958
4991
|
m < y ? H[m] = F[m] : (d = H[m - 1], m % y ? y > 6 && m % y == 4 && (d = f[d >>> 24] << 24 | f[d >>> 16 & 255] << 16 | f[d >>> 8 & 255] << 8 | f[d & 255]) : (d = d << 8 | d >>> 24, d = f[d >>> 24] << 24 | f[d >>> 16 & 255] << 16 | f[d >>> 8 & 255] << 8 | f[d & 255], d ^= A[m / y | 0] << 24), H[m] = H[m - y] ^ d);
|
|
4959
|
-
for (var
|
|
4960
|
-
var m =
|
|
4992
|
+
for (var b = this._invKeySchedule = [], k = 0; k < D; k++) {
|
|
4993
|
+
var m = D - k;
|
|
4961
4994
|
if (k % 4)
|
|
4962
4995
|
var d = H[m];
|
|
4963
4996
|
else
|
|
4964
4997
|
var d = H[m - 4];
|
|
4965
|
-
k < 4 || m <= 4 ?
|
|
4998
|
+
k < 4 || m <= 4 ? b[k] = d : b[k] = E[f[d >>> 24]] ^ c[f[d >>> 16 & 255]] ^ p[f[d >>> 8 & 255]] ^ u[f[d & 255]];
|
|
4966
4999
|
}
|
|
4967
5000
|
}
|
|
4968
5001
|
},
|
|
@@ -4975,9 +5008,9 @@ function Ha() {
|
|
|
4975
5008
|
var F = d[C + 1];
|
|
4976
5009
|
d[C + 1] = d[C + 3], d[C + 3] = F;
|
|
4977
5010
|
},
|
|
4978
|
-
_doCryptBlock: function(d, C, F, y, g,
|
|
4979
|
-
for (var
|
|
4980
|
-
var z = y[k >>> 24] ^ g[S >>> 16 & 255] ^
|
|
5011
|
+
_doCryptBlock: function(d, C, F, y, g, D, H, m) {
|
|
5012
|
+
for (var b = this._nRounds, k = d[C] ^ F[0], S = d[C + 1] ^ F[1], P = d[C + 2] ^ F[2], q = d[C + 3] ^ F[3], N = 4, M = 1; M < b; M++) {
|
|
5013
|
+
var z = y[k >>> 24] ^ g[S >>> 16 & 255] ^ D[P >>> 8 & 255] ^ H[q & 255] ^ F[N++], $ = y[S >>> 24] ^ g[P >>> 16 & 255] ^ D[q >>> 8 & 255] ^ H[k & 255] ^ F[N++], W = y[P >>> 24] ^ g[q >>> 16 & 255] ^ D[k >>> 8 & 255] ^ H[S & 255] ^ F[N++], _ = y[q >>> 24] ^ g[k >>> 16 & 255] ^ D[S >>> 8 & 255] ^ H[P & 255] ^ F[N++];
|
|
4981
5014
|
k = z, S = $, P = W, q = _;
|
|
4982
5015
|
}
|
|
4983
5016
|
var z = (m[k >>> 24] << 24 | m[S >>> 16 & 255] << 16 | m[P >>> 8 & 255] << 8 | m[q & 255]) ^ F[N++], $ = (m[S >>> 24] << 24 | m[P >>> 16 & 255] << 16 | m[q >>> 8 & 255] << 8 | m[k & 255]) ^ F[N++], W = (m[P >>> 24] << 24 | m[q >>> 16 & 255] << 16 | m[k >>> 8 & 255] << 8 | m[S & 255]) ^ F[N++], _ = (m[q >>> 24] << 24 | m[k >>> 16 & 255] << 16 | m[S >>> 8 & 255] << 8 | m[P & 255]) ^ F[N++];
|
|
@@ -4994,7 +5027,7 @@ var ge = { exports: {} }, Pa = ge.exports, xr;
|
|
|
4994
5027
|
function qa() {
|
|
4995
5028
|
return xr || (xr = 1, (function(e, t) {
|
|
4996
5029
|
(function(r, n, o) {
|
|
4997
|
-
e.exports = n(
|
|
5030
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
4998
5031
|
})(Pa, function(r) {
|
|
4999
5032
|
return (function() {
|
|
5000
5033
|
var n = r, o = n.lib, a = o.WordArray, x = o.BlockCipher, f = n.algo, v = [
|
|
@@ -5648,12 +5681,12 @@ function qa() {
|
|
|
5648
5681
|
d[C] = h[F >>> 5] >>> 31 - F % 32 & 1;
|
|
5649
5682
|
}
|
|
5650
5683
|
for (var y = this._subKeys = [], g = 0; g < 16; g++) {
|
|
5651
|
-
for (var
|
|
5652
|
-
|
|
5653
|
-
|
|
5684
|
+
for (var D = y[g] = [], H = s[g], C = 0; C < 24; C++)
|
|
5685
|
+
D[C / 6 | 0] |= d[(i[C] - 1 + H) % 28] << 31 - C % 6, D[4 + (C / 6 | 0)] |= d[28 + (i[C + 24] - 1 + H) % 28] << 31 - C % 6;
|
|
5686
|
+
D[0] = D[0] << 1 | D[0] >>> 31;
|
|
5654
5687
|
for (var C = 1; C < 7; C++)
|
|
5655
|
-
|
|
5656
|
-
|
|
5688
|
+
D[C] = D[C] >>> (C - 1) * 4 + 3;
|
|
5689
|
+
D[7] = D[7] << 5 | D[7] >>> 27;
|
|
5657
5690
|
}
|
|
5658
5691
|
for (var m = this._invSubKeys = [], C = 0; C < 16; C++)
|
|
5659
5692
|
m[C] = y[15 - C];
|
|
@@ -5667,9 +5700,9 @@ function qa() {
|
|
|
5667
5700
|
_doCryptBlock: function(A, h, d) {
|
|
5668
5701
|
this._lBlock = A[h], this._rBlock = A[h + 1], c.call(this, 4, 252645135), c.call(this, 16, 65535), p.call(this, 2, 858993459), p.call(this, 8, 16711935), c.call(this, 1, 1431655765);
|
|
5669
5702
|
for (var C = 0; C < 16; C++) {
|
|
5670
|
-
for (var F = d[C], y = this._lBlock, g = this._rBlock,
|
|
5671
|
-
|
|
5672
|
-
this._lBlock = g, this._rBlock = y ^
|
|
5703
|
+
for (var F = d[C], y = this._lBlock, g = this._rBlock, D = 0, H = 0; H < 8; H++)
|
|
5704
|
+
D |= B[H][((g ^ F[H]) & l[H]) >>> 0];
|
|
5705
|
+
this._lBlock = g, this._rBlock = y ^ D;
|
|
5673
5706
|
}
|
|
5674
5707
|
var m = this._lBlock;
|
|
5675
5708
|
this._lBlock = this._rBlock, this._rBlock = m, c.call(this, 1, 1431655765), p.call(this, 8, 16711935), p.call(this, 2, 858993459), c.call(this, 16, 65535), c.call(this, 4, 252645135), A[h] = this._lBlock, A[h + 1] = this._rBlock;
|
|
@@ -5710,11 +5743,11 @@ function qa() {
|
|
|
5710
5743
|
});
|
|
5711
5744
|
})(ge)), ge.exports;
|
|
5712
5745
|
}
|
|
5713
|
-
var
|
|
5746
|
+
var we = { exports: {} }, Na = we.exports, cr;
|
|
5714
5747
|
function La() {
|
|
5715
5748
|
return cr || (cr = 1, (function(e, t) {
|
|
5716
5749
|
(function(r, n, o) {
|
|
5717
|
-
e.exports = n(
|
|
5750
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
5718
5751
|
})(Na, function(r) {
|
|
5719
5752
|
return (function() {
|
|
5720
5753
|
var n = r, o = n.lib, a = o.StreamCipher, x = n.algo, f = x.RC4 = a.extend({
|
|
@@ -5762,13 +5795,13 @@ function La() {
|
|
|
5762
5795
|
n.RC4Drop = a._createHelper(i);
|
|
5763
5796
|
})(), r.RC4;
|
|
5764
5797
|
});
|
|
5765
|
-
})(
|
|
5798
|
+
})(we)), we.exports;
|
|
5766
5799
|
}
|
|
5767
|
-
var
|
|
5800
|
+
var be = { exports: {} }, za = be.exports, fr;
|
|
5768
5801
|
function Ua() {
|
|
5769
5802
|
return fr || (fr = 1, (function(e, t) {
|
|
5770
5803
|
(function(r, n, o) {
|
|
5771
|
-
e.exports = n(
|
|
5804
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
5772
5805
|
})(za, function(r) {
|
|
5773
5806
|
return (function() {
|
|
5774
5807
|
var n = r, o = n.lib, a = o.StreamCipher, x = n.algo, f = [], v = [], i = [], s = x.Rabbit = a.extend({
|
|
@@ -5828,13 +5861,13 @@ function Ua() {
|
|
|
5828
5861
|
n.Rabbit = a._createHelper(s);
|
|
5829
5862
|
})(), r.Rabbit;
|
|
5830
5863
|
});
|
|
5831
|
-
})(
|
|
5864
|
+
})(be)), be.exports;
|
|
5832
5865
|
}
|
|
5833
|
-
var
|
|
5866
|
+
var De = { exports: {} }, Ia = De.exports, lr;
|
|
5834
5867
|
function ja() {
|
|
5835
5868
|
return lr || (lr = 1, (function(e, t) {
|
|
5836
5869
|
(function(r, n, o) {
|
|
5837
|
-
e.exports = n(
|
|
5870
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
5838
5871
|
})(Ia, function(r) {
|
|
5839
5872
|
return (function() {
|
|
5840
5873
|
var n = r, o = n.lib, a = o.StreamCipher, x = n.algo, f = [], v = [], i = [], s = x.RabbitLegacy = a.extend({
|
|
@@ -5892,13 +5925,13 @@ function ja() {
|
|
|
5892
5925
|
n.RabbitLegacy = a._createHelper(s);
|
|
5893
5926
|
})(), r.RabbitLegacy;
|
|
5894
5927
|
});
|
|
5895
|
-
})(
|
|
5928
|
+
})(De)), De.exports;
|
|
5896
5929
|
}
|
|
5897
5930
|
var _e = { exports: {} }, Wa = _e.exports, ur;
|
|
5898
5931
|
function $a() {
|
|
5899
5932
|
return ur || (ur = 1, (function(e, t) {
|
|
5900
5933
|
(function(r, n, o) {
|
|
5901
|
-
e.exports = n(
|
|
5934
|
+
e.exports = n(I(), B0(), C0(), h0(), G());
|
|
5902
5935
|
})(Wa, function(r) {
|
|
5903
5936
|
return (function() {
|
|
5904
5937
|
var n = r, o = n.lib, a = o.BlockCipher, x = n.algo;
|
|
@@ -6978,8 +7011,8 @@ function $a() {
|
|
|
6978
7011
|
function c(u, A, h) {
|
|
6979
7012
|
for (let g = 0; g < 4; g++) {
|
|
6980
7013
|
u.sbox[g] = [];
|
|
6981
|
-
for (let
|
|
6982
|
-
u.sbox[g][
|
|
7014
|
+
for (let D = 0; D < 256; D++)
|
|
7015
|
+
u.sbox[g][D] = i[g][D];
|
|
6983
7016
|
}
|
|
6984
7017
|
let d = 0;
|
|
6985
7018
|
for (let g = 0; g < f + 2; g++)
|
|
@@ -6988,8 +7021,8 @@ function $a() {
|
|
|
6988
7021
|
for (let g = 0; g < f + 2; g += 2)
|
|
6989
7022
|
y = l(u, C, F), C = y.left, F = y.right, u.pbox[g] = C, u.pbox[g + 1] = F;
|
|
6990
7023
|
for (let g = 0; g < 4; g++)
|
|
6991
|
-
for (let
|
|
6992
|
-
y = l(u, C, F), C = y.left, F = y.right, u.sbox[g][
|
|
7024
|
+
for (let D = 0; D < 256; D += 2)
|
|
7025
|
+
y = l(u, C, F), C = y.left, F = y.right, u.sbox[g][D] = C, u.sbox[g][D + 1] = F;
|
|
6993
7026
|
return !0;
|
|
6994
7027
|
}
|
|
6995
7028
|
var p = x.Blowfish = a.extend({
|
|
@@ -7020,7 +7053,7 @@ var Ma = X0.exports, dr;
|
|
|
7020
7053
|
function Ka() {
|
|
7021
7054
|
return dr || (dr = 1, (function(e, t) {
|
|
7022
7055
|
(function(r, n, o) {
|
|
7023
|
-
e.exports = n(
|
|
7056
|
+
e.exports = n(I(), qe(), jo(), $o(), B0(), Xo(), C0(), Lr(), et(), Jo(), zr(), ta(), na(), aa(), tt(), xa(), h0(), G(), ua(), ha(), va(), Ba(), Aa(), Fa(), ga(), ba(), _a(), ka(), Ra(), Ha(), qa(), La(), Ua(), ja(), $a());
|
|
7024
7057
|
})(Ma, function(r) {
|
|
7025
7058
|
return r;
|
|
7026
7059
|
});
|
|
@@ -7028,6 +7061,14 @@ function Ka() {
|
|
|
7028
7061
|
}
|
|
7029
7062
|
var Xa = Ka();
|
|
7030
7063
|
const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
7064
|
+
/**
|
|
7065
|
+
* @doc
|
|
7066
|
+
* @API utils
|
|
7067
|
+
* @desc 验证指定类型的存储是否可用
|
|
7068
|
+
* @param {String} type - 存储类型,如'localStorage'、'sessionStorage'
|
|
7069
|
+
* @return {Boolean} 存储是否可用
|
|
7070
|
+
* @example-exe utils.storage.validate('localStorage') => true
|
|
7071
|
+
*/
|
|
7031
7072
|
validate(e) {
|
|
7032
7073
|
try {
|
|
7033
7074
|
const t = window[e], r = "__storage_test__";
|
|
@@ -7036,7 +7077,16 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7036
7077
|
return !1;
|
|
7037
7078
|
}
|
|
7038
7079
|
},
|
|
7039
|
-
|
|
7080
|
+
/**
|
|
7081
|
+
* @doc
|
|
7082
|
+
* @API utils
|
|
7083
|
+
* @desc 存储数据到localStorage,支持加密选项
|
|
7084
|
+
* @param {String} key - 存储键名
|
|
7085
|
+
* @param {any} value - 要存储的值
|
|
7086
|
+
* @param {Boolean} [isEncrypt=false] - 是否需要加密存储
|
|
7087
|
+
* @return {any} 存储后的值(通过get方法获取)
|
|
7088
|
+
* @example-exe utils.storage.set('userInfo', {name: '张三'}, true)
|
|
7089
|
+
*/
|
|
7040
7090
|
set(e, t, r) {
|
|
7041
7091
|
if (e && t) {
|
|
7042
7092
|
const n = (o, a) => {
|
|
@@ -7055,7 +7105,15 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7055
7105
|
return n(e, t);
|
|
7056
7106
|
}
|
|
7057
7107
|
},
|
|
7058
|
-
|
|
7108
|
+
/**
|
|
7109
|
+
* @doc
|
|
7110
|
+
* @API utils
|
|
7111
|
+
* @desc 从localStorage获取数据,支持解密选项
|
|
7112
|
+
* @param {String} key - 存储键名
|
|
7113
|
+
* @param {Boolean} [isUnEncrypt=false] - 是否需要解密获取
|
|
7114
|
+
* @return {any} 获取的数据
|
|
7115
|
+
* @example-exe utils.storage.get('userInfo', true) => {name: '张三'}
|
|
7116
|
+
*/
|
|
7059
7117
|
get(e, t) {
|
|
7060
7118
|
if (!e)
|
|
7061
7119
|
return;
|
|
@@ -7083,12 +7141,30 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7083
7141
|
}
|
|
7084
7142
|
return r();
|
|
7085
7143
|
},
|
|
7144
|
+
/**
|
|
7145
|
+
* @doc
|
|
7146
|
+
* @API utils
|
|
7147
|
+
* @desc 从localStorage移除指定键名的数据
|
|
7148
|
+
* @param {String} key - 要移除的存储键名
|
|
7149
|
+
* @return {undefined} 无返回值
|
|
7150
|
+
* @example-exe utils.storage.remove('userInfo')
|
|
7151
|
+
*/
|
|
7086
7152
|
remove(e) {
|
|
7087
7153
|
if (Y.validate("localStorage")) {
|
|
7088
7154
|
const t = localStorage;
|
|
7089
7155
|
e && t.removeItem(e);
|
|
7090
7156
|
}
|
|
7091
7157
|
},
|
|
7158
|
+
/**
|
|
7159
|
+
* @doc
|
|
7160
|
+
* @API utils
|
|
7161
|
+
* @desc 设置cookie,支持加密选项
|
|
7162
|
+
* @param {String} cName - cookie名称
|
|
7163
|
+
* @param {String} value - cookie值
|
|
7164
|
+
* @param {Number} expiredays - 过期天数
|
|
7165
|
+
* @return {undefined} 无返回值
|
|
7166
|
+
* @example-exe utils.storage.setCookie('token', 'abc123', 7)
|
|
7167
|
+
*/
|
|
7092
7168
|
setCookie(e, t, r) {
|
|
7093
7169
|
const n = /* @__PURE__ */ new Date();
|
|
7094
7170
|
n.setDate(n.getDate() + r);
|
|
@@ -7098,6 +7174,14 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7098
7174
|
};
|
|
7099
7175
|
document.cookie = e + "=" + o(t) + (r == null ? "" : ";expires=" + n.toGMTString());
|
|
7100
7176
|
},
|
|
7177
|
+
/**
|
|
7178
|
+
* @doc
|
|
7179
|
+
* @API utils
|
|
7180
|
+
* @desc 获取cookie值,支持解密
|
|
7181
|
+
* @param {String} cName - cookie名称
|
|
7182
|
+
* @return {String} cookie值
|
|
7183
|
+
* @example-exe utils.storage.getCookie('token') => 'abc123'
|
|
7184
|
+
*/
|
|
7101
7185
|
getCookie(e) {
|
|
7102
7186
|
const t = (r) => {
|
|
7103
7187
|
let n;
|
|
@@ -7110,6 +7194,13 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7110
7194
|
}
|
|
7111
7195
|
return "";
|
|
7112
7196
|
},
|
|
7197
|
+
/**
|
|
7198
|
+
* @doc
|
|
7199
|
+
* @API utils
|
|
7200
|
+
* @desc 清除所有cookie
|
|
7201
|
+
* @return {undefined} 无返回值
|
|
7202
|
+
* @example-exe utils.storage.clearAllCookie()
|
|
7203
|
+
*/
|
|
7113
7204
|
clearAllCookie() {
|
|
7114
7205
|
const e = /* @__PURE__ */ new Date();
|
|
7115
7206
|
e.setTime(e.getTime() - 1e4);
|
|
@@ -7117,6 +7208,16 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7117
7208
|
if (t)
|
|
7118
7209
|
for (let r = t.length; r--; ) document.cookie = t[r] + "=0; expire=" + e.toGMTString() + "; path=/";
|
|
7119
7210
|
},
|
|
7211
|
+
/**
|
|
7212
|
+
* @doc
|
|
7213
|
+
* @API utils
|
|
7214
|
+
* @desc 设置简单cookie(不带加密)
|
|
7215
|
+
* @param {String} cName - cookie名称
|
|
7216
|
+
* @param {String} value - cookie值
|
|
7217
|
+
* @param {Number} expiredays - 过期天数
|
|
7218
|
+
* @return {undefined} 无返回值
|
|
7219
|
+
* @example-exe utils.storage.newSetCookie('username', 'admin', 1)
|
|
7220
|
+
*/
|
|
7120
7221
|
newSetCookie(e, t, r) {
|
|
7121
7222
|
const n = (/* @__PURE__ */ new Date()).setDate((/* @__PURE__ */ new Date()).getDate() + r);
|
|
7122
7223
|
document.cookie = e + "=" + t + (r === null ? "" : ";expires=" + n + ";path=/;");
|
|
@@ -7195,12 +7296,12 @@ const J = /* @__PURE__ */ Oo(Xa), Y = {
|
|
|
7195
7296
|
}
|
|
7196
7297
|
}
|
|
7197
7298
|
}
|
|
7198
|
-
}, Ne =
|
|
7299
|
+
}, Ne = V.create({
|
|
7199
7300
|
baseURL: "",
|
|
7200
7301
|
withCredentials: !0,
|
|
7201
7302
|
timeout: 1 / 0
|
|
7202
7303
|
});
|
|
7203
|
-
async function
|
|
7304
|
+
async function Va(e) {
|
|
7204
7305
|
return new Promise(async (t, r) => {
|
|
7205
7306
|
e = e.trim(), e.endsWith("/") && (e = e.slice(0, -1)), Ne.defaults.baseURL = e;
|
|
7206
7307
|
const n = await P0.setServiceMapToStorage();
|
|
@@ -7251,15 +7352,15 @@ Ne.interceptors.response.use(
|
|
|
7251
7352
|
}), Promise.reject(e);
|
|
7252
7353
|
}
|
|
7253
7354
|
);
|
|
7254
|
-
const
|
|
7355
|
+
const j = { ...P0, storage: Y, request: Ne }, x0 = {
|
|
7255
7356
|
/**
|
|
7256
7357
|
* @doc
|
|
7257
|
-
* @API
|
|
7358
|
+
* @API user
|
|
7258
7359
|
* @desc 从localStorage获取token并验证有效性
|
|
7259
7360
|
* @param {String} tokenKey - token存储的键名
|
|
7260
7361
|
* @param {String} time - 时间戳存储的键名
|
|
7261
7362
|
* @return {Object|null} - 有效的token对象或null
|
|
7262
|
-
* @example getlocalStorageToken('userToken', 'tokenTimestamp')
|
|
7363
|
+
* @example-exe user.getlocalStorageToken('userToken', 'tokenTimestamp')
|
|
7263
7364
|
* */
|
|
7264
7365
|
getlocalStorageToken(e, t) {
|
|
7265
7366
|
const r = localStorage.getItem(e), n = localStorage.getItem(t);
|
|
@@ -7272,52 +7373,52 @@ const I = { ...P0, storage: Y, request: Ne }, s0 = {
|
|
|
7272
7373
|
},
|
|
7273
7374
|
/**
|
|
7274
7375
|
* @doc
|
|
7275
|
-
* @API
|
|
7376
|
+
* @API user
|
|
7276
7377
|
* @desc 处理URL并添加token参数
|
|
7277
7378
|
* @param {Object} opts - 配置选项
|
|
7278
7379
|
* @param {String} opts.serverType - token类型:15s、15s-local、leadal
|
|
7279
7380
|
* @param {String} opts.url - 需要拼接token的地址,支持@token和@15token替换
|
|
7280
7381
|
* @param {String} opts.id - 应用ID
|
|
7281
7382
|
* @return {Object} 包含处理后url和token的opts对象
|
|
7282
|
-
* @example setUrlToken({id: 'app1', url: 'https://example.com', serverType: '15s'})
|
|
7383
|
+
* @example-exe user.setUrlToken({id: 'app1', url: 'https://example.com', serverType: '15s'})
|
|
7283
7384
|
* */
|
|
7284
7385
|
async setUrlToken(e) {
|
|
7285
7386
|
var r, n;
|
|
7286
7387
|
let t = null;
|
|
7287
7388
|
try {
|
|
7288
|
-
t = await
|
|
7389
|
+
t = await x0.getCommonToken(e);
|
|
7289
7390
|
let o = e.url;
|
|
7290
7391
|
const a = o.split("#/"), x = t.tokenName ? t.tokenName : "access_token", f = t.tokenName ? t.tokenValue : t.access_token;
|
|
7291
7392
|
a.length > 1 ? a[0].indexOf("?") == -1 ? o = o.replace("#/", `?${x}=${f}#/`) : o = o.replace("#/", `&${x}=${f}#/`) : (o.indexOf("?") === -1 ? o += "?" : o += "&", o += x + "=" + f), e.url = o;
|
|
7292
7393
|
} catch (o) {
|
|
7293
7394
|
console.error("Failed to get or append token:", o);
|
|
7294
7395
|
}
|
|
7295
|
-
return ((r = e == null ? void 0 : e.url) == null ? void 0 : r.indexOf("@token")) !== -1 && (t = await
|
|
7396
|
+
return ((r = e == null ? void 0 : e.url) == null ? void 0 : r.indexOf("@token")) !== -1 && (t = await x0.getToken(e.id), e.url = e.url.replace("@token", t)), ((n = e == null ? void 0 : e.url) == null ? void 0 : n.indexOf("@15token")) !== -1 && (t = (await x0.get15sToken(e.id)).access_token, e.url = e.url.replace("@15token", t)), e.token = t, e;
|
|
7296
7397
|
},
|
|
7297
7398
|
/**
|
|
7298
7399
|
* @doc
|
|
7299
|
-
* @API
|
|
7400
|
+
* @API user
|
|
7300
7401
|
* @desc 根据服务器类型获取通用token
|
|
7301
7402
|
* @param {Object} opts - 配置选项
|
|
7302
7403
|
* @param {String} opts.serverType - token类型:15s、15s-local、leadal
|
|
7303
7404
|
* @param {String} opts.id - 应用ID
|
|
7304
7405
|
* @return {Object} token信息对象
|
|
7305
|
-
* @example getCommonToken({id: 'app1', serverType: '15s-local'})
|
|
7406
|
+
* @example-exe user.getCommonToken({id: 'app1', serverType: '15s-local'})
|
|
7306
7407
|
* */
|
|
7307
7408
|
async getCommonToken(e) {
|
|
7308
7409
|
let t = e.id + "_" + (/* @__PURE__ */ new Date()).getTime();
|
|
7309
|
-
return e.serverType === "15s" ? await
|
|
7410
|
+
return e.serverType === "15s" ? await x0.get15sToken() : await x0.getToken(t);
|
|
7310
7411
|
},
|
|
7311
7412
|
/**
|
|
7312
7413
|
* @doc
|
|
7313
|
-
* @API
|
|
7414
|
+
* @API user
|
|
7314
7415
|
* @desc 获取token
|
|
7315
7416
|
* @param {String} clientId - 客户端ID
|
|
7316
7417
|
* @return {String} token字符串
|
|
7317
|
-
* @example getToken('client123')
|
|
7418
|
+
* @example-exe user.getToken('client123')
|
|
7318
7419
|
* */
|
|
7319
7420
|
async getToken(e) {
|
|
7320
|
-
let t = await
|
|
7421
|
+
let t = await Ga("userToken", "tokenTimestamp");
|
|
7321
7422
|
if (!t) {
|
|
7322
7423
|
const r = {
|
|
7323
7424
|
client_secret: (await rt.getUser()).id,
|
|
@@ -7326,7 +7427,7 @@ const I = { ...P0, storage: Y, request: Ne }, s0 = {
|
|
|
7326
7427
|
};
|
|
7327
7428
|
e || (r.client_id = r.client_secret + "_" + (/* @__PURE__ */ new Date()).getTime());
|
|
7328
7429
|
const n = (/* @__PURE__ */ new Date()).getTime();
|
|
7329
|
-
t = await
|
|
7430
|
+
t = await j.request({
|
|
7330
7431
|
url: "/wuji-portal-visual/auth/api/getToken",
|
|
7331
7432
|
method: "POST",
|
|
7332
7433
|
data: r
|
|
@@ -7336,16 +7437,16 @@ const I = { ...P0, storage: Y, request: Ne }, s0 = {
|
|
|
7336
7437
|
},
|
|
7337
7438
|
/**
|
|
7338
7439
|
* @doc
|
|
7339
|
-
* @API
|
|
7440
|
+
* @API user
|
|
7340
7441
|
* @desc 获取15s token
|
|
7341
7442
|
* @return {Object} 包含access_token的token对象
|
|
7342
|
-
* @example get15sToken()
|
|
7443
|
+
* @example-exe user.get15sToken()
|
|
7343
7444
|
* */
|
|
7344
7445
|
async get15sToken() {
|
|
7345
7446
|
var t;
|
|
7346
|
-
let e = await
|
|
7447
|
+
let e = await x0.getlocalStorageToken("user15sToken", "token15sTimestamp");
|
|
7347
7448
|
if (!e) {
|
|
7348
|
-
const r = await
|
|
7449
|
+
const r = await j.request({
|
|
7349
7450
|
url: "/wuji-portal-visual/auth/api/out-token",
|
|
7350
7451
|
method: "GET"
|
|
7351
7452
|
});
|
|
@@ -7360,14 +7461,14 @@ const I = { ...P0, storage: Y, request: Ne }, s0 = {
|
|
|
7360
7461
|
},
|
|
7361
7462
|
/**
|
|
7362
7463
|
* @doc
|
|
7363
|
-
* @API
|
|
7464
|
+
* @API user
|
|
7364
7465
|
* @desc token登陆(单点)
|
|
7365
7466
|
* @param {Object} data - 登录参数
|
|
7366
7467
|
* @return {Promise} 登录请求的Promise对象
|
|
7367
|
-
* @example loginBySSO({token: 'xxx'})
|
|
7468
|
+
* @example-exe user.loginBySSO({token: 'xxx'})
|
|
7368
7469
|
* */
|
|
7369
7470
|
loginBySSO(e) {
|
|
7370
|
-
return
|
|
7471
|
+
return j.request({
|
|
7371
7472
|
url: "/wuji-soft-center/auth/api/loginBySSO",
|
|
7372
7473
|
method: "POST",
|
|
7373
7474
|
data: e,
|
|
@@ -7375,7 +7476,7 @@ const I = { ...P0, storage: Y, request: Ne }, s0 = {
|
|
|
7375
7476
|
});
|
|
7376
7477
|
}
|
|
7377
7478
|
};
|
|
7378
|
-
function
|
|
7479
|
+
function Ga(e, t) {
|
|
7379
7480
|
const r = localStorage.getItem(e), n = localStorage.getItem(t);
|
|
7380
7481
|
if (r && n) {
|
|
7381
7482
|
const o = (/* @__PURE__ */ new Date()).getTime(), a = parseInt(n, 10);
|
|
@@ -7386,17 +7487,19 @@ function Va(e, t) {
|
|
|
7386
7487
|
const rt = {
|
|
7387
7488
|
/**
|
|
7388
7489
|
* @doc
|
|
7389
|
-
* @API
|
|
7390
|
-
* @desc
|
|
7391
|
-
* @param {String} softId - 应用ID
|
|
7392
|
-
* @return 无返回值
|
|
7393
|
-
* @example
|
|
7394
|
-
*
|
|
7490
|
+
* @API user
|
|
7491
|
+
* @desc 存储应用打开记录,统计应用打开次数
|
|
7492
|
+
* @param {String} softId - 应用ID,用于标识具体的应用
|
|
7493
|
+
* @return {void} 无返回值
|
|
7494
|
+
* @example-exe
|
|
7495
|
+
* // 记录应用ID为'app123'的打开次数
|
|
7496
|
+
* user.softLogById('app123');
|
|
7497
|
+
*/
|
|
7395
7498
|
softLogById(e) {
|
|
7396
|
-
e &&
|
|
7499
|
+
e && j.timerDebounce(
|
|
7397
7500
|
"loginSoft",
|
|
7398
7501
|
() => {
|
|
7399
|
-
|
|
7502
|
+
j.request({
|
|
7400
7503
|
url: "/wuji-soft-center/softLoginLog/loginSoft",
|
|
7401
7504
|
method: "POST",
|
|
7402
7505
|
data: { softId: e }
|
|
@@ -7407,13 +7510,21 @@ const rt = {
|
|
|
7407
7510
|
},
|
|
7408
7511
|
/**
|
|
7409
7512
|
* @doc
|
|
7410
|
-
* @API
|
|
7513
|
+
* @API user
|
|
7411
7514
|
* @desc 用户登出系统
|
|
7412
|
-
* @return {Promise} 返回登出请求的Promise
|
|
7413
|
-
* @example
|
|
7414
|
-
*
|
|
7515
|
+
* @return {Promise<Object>} 返回登出请求的Promise对象,包含登出操作的结果
|
|
7516
|
+
* @example-exe
|
|
7517
|
+
* // 执行用户登出
|
|
7518
|
+
* user.logOut()
|
|
7519
|
+
* .then(response => {
|
|
7520
|
+
* console.log('登出成功', response);
|
|
7521
|
+
* })
|
|
7522
|
+
* .catch(error => {
|
|
7523
|
+
* console.error('登出失败', error);
|
|
7524
|
+
* });
|
|
7525
|
+
*/
|
|
7415
7526
|
logOut() {
|
|
7416
|
-
return
|
|
7527
|
+
return j.request({
|
|
7417
7528
|
url: "/wuji-portal-visual/auth/api/logOut",
|
|
7418
7529
|
method: "GET",
|
|
7419
7530
|
timeout: 6e3
|
|
@@ -7421,14 +7532,16 @@ const rt = {
|
|
|
7421
7532
|
},
|
|
7422
7533
|
/**
|
|
7423
7534
|
* @doc
|
|
7424
|
-
* @API
|
|
7425
|
-
* @desc
|
|
7426
|
-
* @param {String} softUniqueName -
|
|
7427
|
-
* @return 无返回值
|
|
7428
|
-
* @example
|
|
7429
|
-
*
|
|
7535
|
+
* @API user
|
|
7536
|
+
* @desc 通过应用别名统计应用打开次数
|
|
7537
|
+
* @param {String} softUniqueName - 应用唯一别名,用于标识具体的应用
|
|
7538
|
+
* @return {void} 无返回值
|
|
7539
|
+
* @example-exe
|
|
7540
|
+
* // 通过别名'example-app'记录应用打开次数
|
|
7541
|
+
* user.softLogByAlias('example-app');
|
|
7542
|
+
*/
|
|
7430
7543
|
softLogByAlias(e) {
|
|
7431
|
-
e &&
|
|
7544
|
+
e && j.timerDebounce(
|
|
7432
7545
|
"loginSoftByUniqueName",
|
|
7433
7546
|
() => {
|
|
7434
7547
|
loginSoftByUniqueName({ softUniqueName: e });
|
|
@@ -7436,44 +7549,89 @@ const rt = {
|
|
|
7436
7549
|
200
|
|
7437
7550
|
);
|
|
7438
7551
|
},
|
|
7439
|
-
/**
|
|
7440
|
-
*
|
|
7441
|
-
*
|
|
7552
|
+
/**
|
|
7553
|
+
* @doc
|
|
7554
|
+
* @API user
|
|
7555
|
+
* @desc 设置URL中的Token参数
|
|
7556
|
+
* @param {Object} opts - 配置选项对象
|
|
7557
|
+
* @param {String} opts.serverType - Token类型,可选值:'15s'、'15s-local'、'leadal'
|
|
7558
|
+
* @param {String} opts.url - 需要拼接Token的URL地址,支持@token和@15token占位符替换
|
|
7559
|
+
* @param {String} [opts.id] - 当URL包含@token或@15token占位符时的客户端ID
|
|
7560
|
+
* @return {Promise<Object>} 返回更新后的配置选项对象,包含处理后的URL和Token信息
|
|
7561
|
+
* @throws {Error} 获取Token失败时会抛出异常
|
|
7562
|
+
* @example-exe
|
|
7563
|
+
* // 为URL添加Token参数
|
|
7564
|
+
* const result = await user.setUrlToken({
|
|
7565
|
+
* serverType: 'leadal',
|
|
7566
|
+
* url: 'https://example.com/api/data'
|
|
7567
|
+
* });
|
|
7568
|
+
* // 使用替换占位符
|
|
7569
|
+
* const result2 = await user.setUrlToken({
|
|
7570
|
+
* id: 'client123',
|
|
7571
|
+
* url: 'https://example.com/api/data?token=@token'
|
|
7572
|
+
* });
|
|
7442
7573
|
*/
|
|
7443
7574
|
async setUrlToken(e) {
|
|
7444
7575
|
var r, n;
|
|
7445
7576
|
let t = null;
|
|
7446
7577
|
try {
|
|
7447
|
-
t = await
|
|
7578
|
+
t = await x0.getCommonToken(e);
|
|
7448
7579
|
let o = e.url;
|
|
7449
7580
|
const a = o.split("#/"), x = t.tokenName ? t.tokenName : "access_token", f = t.tokenName ? t.tokenValue : t.access_token;
|
|
7450
7581
|
a.length > 1 && o.indexOf(".nsp") !== -1 ? a[0].indexOf("?") == -1 ? o = o.replace("#/", `?${x}=${f}#/`) : o = o.replace("#/", `&${x}=${f}#/`) : (o.indexOf("?") === -1 ? o += "?" : o += "&", o += x + "=" + f), e.url = o;
|
|
7451
7582
|
} catch (o) {
|
|
7452
7583
|
console.error("Failed to get or append token:", o);
|
|
7453
7584
|
}
|
|
7454
|
-
return ((r = e == null ? void 0 : e.url) == null ? void 0 : r.indexOf("@token")) !== -1 && (t = await
|
|
7585
|
+
return ((r = e == null ? void 0 : e.url) == null ? void 0 : r.indexOf("@token")) !== -1 && (t = await x0.getToken(e.id), e.url = e.url.replace("@token", t)), ((n = e == null ? void 0 : e.url) == null ? void 0 : n.indexOf("@15token")) !== -1 && (t = (await x0.get15sToken(e.id)).access_token, e.url = e.url.replace("@15token", t)), e.token = t, e;
|
|
7455
7586
|
},
|
|
7456
|
-
|
|
7587
|
+
/**
|
|
7588
|
+
* @doc
|
|
7589
|
+
* @API user
|
|
7590
|
+
* @desc 传入地址获取并替换Token
|
|
7591
|
+
* @param {String} url - 包含@token占位符的URL地址
|
|
7592
|
+
* @param {String} clientId - 客户端ID,用于获取Token
|
|
7593
|
+
* @return {Promise<String>} 返回已替换Token的URL字符串
|
|
7594
|
+
* @example-exe
|
|
7595
|
+
* const tokenizedUrl = await user.getUrlToken('https://example.com/api?token=@token', 'client123');
|
|
7596
|
+
*/
|
|
7457
7597
|
async getUrlToken(e, t) {
|
|
7458
7598
|
let r = "";
|
|
7459
|
-
return r = e.replace("@token", (await
|
|
7599
|
+
return r = e.replace("@token", (await x0.getToken(t)).access_token), r;
|
|
7460
7600
|
},
|
|
7601
|
+
/**
|
|
7602
|
+
* @doc
|
|
7603
|
+
* @API user
|
|
7604
|
+
* @param {Object} data - 用户信息对象
|
|
7605
|
+
* @return {Promise<void>} 无返回值
|
|
7606
|
+
* @desc 根据客户端类型,将用户信息存储到不同位置:普通客户端存储到本地存储,特殊客户端通过chrome API存储
|
|
7607
|
+
* @example-exe
|
|
7608
|
+
* // 设置用户信息
|
|
7609
|
+
* await user.setUser({
|
|
7610
|
+
* userId: '12345',
|
|
7611
|
+
* userName: '张三',
|
|
7612
|
+
* roles: ['admin']
|
|
7613
|
+
* });
|
|
7614
|
+
*/
|
|
7461
7615
|
async setUser(e) {
|
|
7462
|
-
const t =
|
|
7463
|
-
t !== "ldtC" && t !== "portal" ?
|
|
7616
|
+
const t = j.getClientType();
|
|
7617
|
+
t !== "ldtC" && t !== "portal" ? j.storage.set("login_user_info_cookie", e, !0) : window.chrome.setUser(e);
|
|
7464
7618
|
},
|
|
7465
7619
|
/**
|
|
7466
7620
|
* @doc
|
|
7467
|
-
* @API
|
|
7468
|
-
* @desc
|
|
7469
|
-
* @return {Object} 用户信息对象
|
|
7470
|
-
* @example
|
|
7471
|
-
*
|
|
7621
|
+
* @API user
|
|
7622
|
+
* @desc 获取用户信息,优先从缓存获取用户信息,如果缓存中不存在,则通过API获取并存储
|
|
7623
|
+
* @return {Promise<Object>} 用户信息对象
|
|
7624
|
+
* @example-exe
|
|
7625
|
+
* // 获取用户信息
|
|
7626
|
+
* const userInfo = await user.getUser();
|
|
7627
|
+
* console.log('用户姓名:', userInfo.userName);
|
|
7628
|
+
* console.log('用户角色:', userInfo.userType);
|
|
7629
|
+
*/
|
|
7472
7630
|
async getUser() {
|
|
7473
7631
|
var r, n, o;
|
|
7474
7632
|
let e = "";
|
|
7475
|
-
const t =
|
|
7476
|
-
if (t !== "ldtC" && t !== "portal" ? e = await
|
|
7633
|
+
const t = j.getClientType();
|
|
7634
|
+
if (t !== "ldtC" && t !== "portal" ? e = await j.storage.get("login_user_info_cookie", !0) : e = await window.chrome.getUser(), e && typeof e == "object" && Object.keys(e).length > 0)
|
|
7477
7635
|
return e;
|
|
7478
7636
|
{
|
|
7479
7637
|
let a = (r = await Ro()) == null ? void 0 : r.data;
|
|
@@ -7482,15 +7640,25 @@ const rt = {
|
|
|
7482
7640
|
}
|
|
7483
7641
|
return e;
|
|
7484
7642
|
}
|
|
7485
|
-
}, ke = { ...rt, ...
|
|
7643
|
+
}, ke = { ...rt, ...x0 }, y0 = {
|
|
7486
7644
|
/**
|
|
7487
|
-
*
|
|
7488
|
-
* @
|
|
7489
|
-
*
|
|
7490
|
-
*
|
|
7645
|
+
* @doc
|
|
7646
|
+
* @API chrome
|
|
7647
|
+
* @desc 通过mini服务调用本地接口打开外部浏览器
|
|
7648
|
+
* @param {Object} params - 浏览器调用参数
|
|
7649
|
+
* @param {string} params.url - 要打开的网页地址
|
|
7650
|
+
* @param {string} params.type - 浏览器类型
|
|
7651
|
+
* @returns {Promise} - 返回请求Promise对象,包含操作结果
|
|
7652
|
+
* @example
|
|
7653
|
+
* chrome.openBrowser({
|
|
7654
|
+
* url: 'https://www.example.com',
|
|
7655
|
+
* type: 'chrome'
|
|
7656
|
+
* }).then(response => {
|
|
7657
|
+
* console.log('浏览器打开结果:', response);
|
|
7658
|
+
* });
|
|
7491
7659
|
*/
|
|
7492
7660
|
openBrowser(e) {
|
|
7493
|
-
return
|
|
7661
|
+
return j.request({
|
|
7494
7662
|
url: "http://127.0.0.1:2267/api/mini/BrowserCall/accessBrowser",
|
|
7495
7663
|
method: "GET",
|
|
7496
7664
|
withCredentials: !1,
|
|
@@ -7498,13 +7666,26 @@ const rt = {
|
|
|
7498
7666
|
});
|
|
7499
7667
|
},
|
|
7500
7668
|
/**
|
|
7501
|
-
*
|
|
7502
|
-
* @
|
|
7669
|
+
* @doc
|
|
7670
|
+
* @API chrome
|
|
7671
|
+
* @desc 根据客户端类型调用不同的方法打开本地可执行程序
|
|
7672
|
+
* @param {Object} params - 程序执行参数
|
|
7673
|
+
* @param {string} params.path - 可执行程序的路径
|
|
7674
|
+
* @returns {Promise|null} - 返回portal类型下的请求Promise,其他类型返回null
|
|
7675
|
+
* @example
|
|
7676
|
+
* // portal客户端下会返回Promise
|
|
7677
|
+
* chrome.openExec({ path: 'C:/Program Files/example.exe' })
|
|
7678
|
+
* .then(response => {
|
|
7679
|
+
* console.log('程序执行结果:', response);
|
|
7680
|
+
* });
|
|
7681
|
+
*
|
|
7682
|
+
* // ldt或ldtC客户端下直接执行无返回值
|
|
7683
|
+
* chrome.openExec({ path: 'C:/Program Files/example.exe' });
|
|
7503
7684
|
*/
|
|
7504
7685
|
openExec(e) {
|
|
7505
|
-
switch (
|
|
7686
|
+
switch (j.getClientType()) {
|
|
7506
7687
|
case "portal":
|
|
7507
|
-
return
|
|
7688
|
+
return j.request({
|
|
7508
7689
|
url: "http://127.0.0.1:2267/api/cis/service/openExec",
|
|
7509
7690
|
method: "GET",
|
|
7510
7691
|
withCredentials: !1,
|
|
@@ -7517,53 +7698,83 @@ const rt = {
|
|
|
7517
7698
|
}
|
|
7518
7699
|
},
|
|
7519
7700
|
/**
|
|
7520
|
-
*
|
|
7521
|
-
*
|
|
7522
|
-
*
|
|
7523
|
-
* @
|
|
7701
|
+
* @doc
|
|
7702
|
+
* @API chrome
|
|
7703
|
+
* @desc 客户端打开指定软件,通过桌面系统服务启动
|
|
7704
|
+
* @param {Object} params - 程序启动参数
|
|
7705
|
+
* @param {string} params.exe - 软件可执行文件路径
|
|
7706
|
+
* @param {string} params.param - 程序启动参数,如token等
|
|
7707
|
+
* @returns {Promise} - 返回请求Promise对象,包含操作结果
|
|
7708
|
+
* @example
|
|
7709
|
+
* chrome.startExec({
|
|
7710
|
+
* exe: 'C:/Program Files/App/example.exe',
|
|
7711
|
+
* param: 'token=abc123'
|
|
7712
|
+
* }).then(response => {
|
|
7713
|
+
* console.log('软件启动结果:', response);
|
|
7714
|
+
* }).catch(error => {
|
|
7715
|
+
* console.error('启动失败:', error);
|
|
7716
|
+
* });
|
|
7524
7717
|
*/
|
|
7525
7718
|
startExec(e) {
|
|
7526
|
-
return
|
|
7719
|
+
return j.request({
|
|
7527
7720
|
url: "http://127.0.0.1:2267/api/desktop/sysServer/startExec",
|
|
7528
7721
|
method: "GET",
|
|
7529
7722
|
withCredentials: !1,
|
|
7530
7723
|
params: e
|
|
7531
7724
|
});
|
|
7532
7725
|
},
|
|
7533
|
-
|
|
7726
|
+
/**
|
|
7727
|
+
* @doc 打开应用日志
|
|
7728
|
+
* @API chrome
|
|
7729
|
+
* @desc 记录或打开应用日志功能
|
|
7730
|
+
* @note 当前接口暂未实现,函数体为空
|
|
7731
|
+
* @returns {undefined} - 无返回值
|
|
7732
|
+
* @example
|
|
7733
|
+
* // 暂未实现,调用无效果
|
|
7734
|
+
* chrome.openAppLog();
|
|
7735
|
+
*/
|
|
7534
7736
|
openAppLog() {
|
|
7535
7737
|
},
|
|
7536
7738
|
/**
|
|
7537
|
-
*
|
|
7739
|
+
* @doc
|
|
7740
|
+
* @API chrome
|
|
7741
|
+
* @desc 从本地指纹设备获取指纹信息用于登录验证
|
|
7742
|
+
* @returns {Promise} - 返回包含指纹信息的Promise对象
|
|
7743
|
+
* @throws {Error} - 指纹获取超时或失败时抛出异常
|
|
7744
|
+
* @example
|
|
7745
|
+
* chrome.fecthFinger()
|
|
7746
|
+
* .then(fingerprintData => {
|
|
7747
|
+
* console.log('获取到指纹信息:', fingerprintData);
|
|
7748
|
+
* // 进行指纹验证
|
|
7749
|
+
* })
|
|
7750
|
+
* .catch(error => {
|
|
7751
|
+
* console.error('指纹获取失败:', error);
|
|
7752
|
+
* // 提示用户指纹获取失败或超时
|
|
7753
|
+
* });
|
|
7538
7754
|
*/
|
|
7539
7755
|
fecthFinger() {
|
|
7540
|
-
return
|
|
7541
|
-
url: "http://127.0.0.1:2267/api/finger/login/3000",
|
|
7542
|
-
method: "GET",
|
|
7543
|
-
withCredentials: !1,
|
|
7544
|
-
timeout: 5e3
|
|
7545
|
-
});
|
|
7756
|
+
return V.get("http://127.0.0.1:2267/api/finger/login/3000");
|
|
7546
7757
|
}
|
|
7547
7758
|
}, Qe = {
|
|
7548
7759
|
/**
|
|
7549
7760
|
* @doc
|
|
7550
|
-
* @API
|
|
7761
|
+
* @API chrome
|
|
7551
7762
|
* @desc 获取主站聚焦页签信息
|
|
7552
7763
|
* @param {Function} fn - 回调函数
|
|
7553
|
-
* @return
|
|
7554
|
-
* @example chrome.getWindowActiveTab((tabInfo) => { console.log(tabInfo) })
|
|
7764
|
+
* @return {Object} tabInfo - 页签信息对象(异步)
|
|
7765
|
+
* @example-exe chrome.getWindowActiveTab((tabInfo) => { console.log(tabInfo) })
|
|
7555
7766
|
* */
|
|
7556
7767
|
getWindowActiveTab(e) {
|
|
7557
7768
|
return window.chrome.getWindowActiveTab(1, e);
|
|
7558
7769
|
},
|
|
7559
7770
|
/**
|
|
7560
7771
|
* @doc
|
|
7561
|
-
* @API
|
|
7772
|
+
* @API chrome
|
|
7562
7773
|
* @desc 打开居中弹窗,按比例显示
|
|
7563
7774
|
* @param {Number} opt - 窗口大小比例,默认0.85
|
|
7564
7775
|
* @param {String} url - 要打开的URL地址
|
|
7565
7776
|
* @return 无返回值
|
|
7566
|
-
* @example chrome.openTab2center(0.8, 'https://example.com')
|
|
7777
|
+
* @example-exe chrome.openTab2center(0.8, 'https://example.com')
|
|
7567
7778
|
* @warning 在chrome下比例高于0.85会自动最大化
|
|
7568
7779
|
* */
|
|
7569
7780
|
openTab2center(e = 0.85, t) {
|
|
@@ -7579,7 +7790,7 @@ const rt = {
|
|
|
7579
7790
|
},
|
|
7580
7791
|
/**
|
|
7581
7792
|
* @doc
|
|
7582
|
-
* @API
|
|
7793
|
+
* @API chrome
|
|
7583
7794
|
* @desc 打开内嵌窗口
|
|
7584
7795
|
* @param {Object} opts - 配置项
|
|
7585
7796
|
* @param {String} opts.url - 地址
|
|
@@ -7592,19 +7803,23 @@ const rt = {
|
|
|
7592
7803
|
* @param {Boolean} opts.secondLoginValidate - 是否需要二次认证
|
|
7593
7804
|
* @param {String} opts.appId - 系统标识
|
|
7594
7805
|
* @return 无返回值
|
|
7595
|
-
* @example chrome.openWithTab({url: 'https://example.com', title: '示例应用'})
|
|
7806
|
+
* @example-exe chrome.openWithTab({url: 'https://example.com', title: '示例应用'})
|
|
7596
7807
|
* */
|
|
7597
7808
|
async openWithTab(e) {
|
|
7598
|
-
e.title = e.title || e.caption || e.name, e.url = e.url || e.homeLink || e.homePage, e.secondLoginValidate === "Y" && (e.url = "/home-client/appAuth.html#/index?target=" + encodeURIComponent(e.url)), e.appId && e.url.startsWith("/") && (e.url =
|
|
7809
|
+
e.title = e.title || e.caption || e.name, e.url = e.url || e.homeLink || e.homePage, e.secondLoginValidate === "Y" && (e.url = "/home-client/appAuth.html#/index?target=" + encodeURIComponent(e.url)), e.appId && e.url.startsWith("/") && (e.url = j.getService(e.appId) + e.url), e.audit && y0.openAppLog(e.id), (e.rocketName === "httptoken" || e.authMode === "httptoken" || e.authMode === "token") && (e = await ke.setUrlToken(e)), e0._doOpen(e);
|
|
7599
7810
|
},
|
|
7600
7811
|
/**
|
|
7601
|
-
*
|
|
7602
|
-
* @
|
|
7812
|
+
* @doc
|
|
7813
|
+
* @API chrome
|
|
7814
|
+
* @desc 移动页签,用于弹窗或调整页签位置
|
|
7815
|
+
* @param {String} windowId 目标窗口ID
|
|
7816
|
+
* @return {Function} 返回chrome API调用
|
|
7817
|
+
* @example-exe tabs.tabMove('window-123');
|
|
7603
7818
|
*/
|
|
7604
|
-
tabMove(e
|
|
7605
|
-
return window.chrome.getActiveTab((
|
|
7606
|
-
const
|
|
7607
|
-
e = e ||
|
|
7819
|
+
tabMove(e) {
|
|
7820
|
+
return window.chrome.getActiveTab((t) => {
|
|
7821
|
+
const r = t._id;
|
|
7822
|
+
e = e || t.windowId, r && window.chrome.tabMove([r], e, 0);
|
|
7608
7823
|
});
|
|
7609
7824
|
}
|
|
7610
7825
|
}, d0 = {
|
|
@@ -7665,20 +7880,35 @@ const rt = {
|
|
|
7665
7880
|
}
|
|
7666
7881
|
}
|
|
7667
7882
|
};
|
|
7668
|
-
let
|
|
7883
|
+
let e0 = {
|
|
7884
|
+
/**
|
|
7885
|
+
* @doc
|
|
7886
|
+
* @API chrome
|
|
7887
|
+
* @desc 判断是否为特定客户端环境
|
|
7888
|
+
* @returns {Boolean} 返回是否为特定客户端环境的布尔值
|
|
7889
|
+
* @example-exe
|
|
7890
|
+
* if (chrome.isClients()) {
|
|
7891
|
+
* console.log('当前在特定客户端环境中');
|
|
7892
|
+
* }
|
|
7893
|
+
*/
|
|
7669
7894
|
isClients() {
|
|
7670
7895
|
const e = window.navigator.userAgent;
|
|
7671
7896
|
return (e.indexOf("netiler") !== -1 || e.indexOf("Firefox") !== -1) && typeof window.chrome < "u" && parseInt(window.chrome.version) >= 78;
|
|
7672
7897
|
},
|
|
7673
7898
|
/**
|
|
7674
7899
|
* @doc
|
|
7675
|
-
* @API
|
|
7900
|
+
* @API chrome
|
|
7676
7901
|
* @desc 获取客户端类型及版本信息
|
|
7677
|
-
* @
|
|
7678
|
-
* @
|
|
7902
|
+
* @returns {Object} 包含客户端类型和版本号的对象
|
|
7903
|
+
* @returns {String} returns.type - 客户端类型标识
|
|
7904
|
+
* @returns {Number} returns.version - 客户端版本号数字
|
|
7905
|
+
* @example-exe
|
|
7906
|
+
* const versionInfo = chrome.getVersion();
|
|
7907
|
+
* console.log('客户端类型:', versionInfo.type); // 输出: portal, ldt或ldtC
|
|
7908
|
+
* console.log('客户端版本号:', versionInfo.version); // 输出: 如304627
|
|
7679
7909
|
* */
|
|
7680
7910
|
getVersion() {
|
|
7681
|
-
const e =
|
|
7911
|
+
const e = j.getClientType();
|
|
7682
7912
|
let t = null;
|
|
7683
7913
|
if (e == "portal")
|
|
7684
7914
|
t = parseInt(window.chrome.version);
|
|
@@ -7696,20 +7926,24 @@ let f0 = {
|
|
|
7696
7926
|
},
|
|
7697
7927
|
/**
|
|
7698
7928
|
* @doc
|
|
7699
|
-
* @API
|
|
7700
|
-
* @desc
|
|
7701
|
-
* @
|
|
7702
|
-
* @example
|
|
7929
|
+
* @API chrome
|
|
7930
|
+
* @desc 刷新全部标签页,清除缓存
|
|
7931
|
+
* @returns {void} 无返回值
|
|
7932
|
+
* @example-exe
|
|
7933
|
+
* // 刷新所有标签页并清除缓存
|
|
7934
|
+
* chrome.refreshAll();
|
|
7703
7935
|
* */
|
|
7704
7936
|
refreshAll() {
|
|
7705
|
-
window.chrome.
|
|
7937
|
+
window.chrome.refreshAll();
|
|
7706
7938
|
},
|
|
7707
7939
|
/**
|
|
7708
7940
|
* @doc
|
|
7709
|
-
* @API
|
|
7941
|
+
* @API chrome
|
|
7710
7942
|
* @desc 刷新当前标签页
|
|
7711
|
-
* @
|
|
7712
|
-
* @example
|
|
7943
|
+
* @returns {void} 无返回值
|
|
7944
|
+
* @example-exe
|
|
7945
|
+
* // 刷新当前活动标签页
|
|
7946
|
+
* chrome.refresh();
|
|
7713
7947
|
* @warning 首页刷新会刷新全部内容
|
|
7714
7948
|
* */
|
|
7715
7949
|
refresh() {
|
|
@@ -7720,24 +7954,38 @@ let f0 = {
|
|
|
7720
7954
|
},
|
|
7721
7955
|
/**
|
|
7722
7956
|
* @doc
|
|
7723
|
-
* @API
|
|
7724
|
-
* @desc
|
|
7725
|
-
* @
|
|
7726
|
-
* @
|
|
7957
|
+
* @API chrome
|
|
7958
|
+
* @desc 退出客户端,先最小化,执行用户登出,再完全退出
|
|
7959
|
+
* @returns {Promise<void>} 无返回值
|
|
7960
|
+
* @throws {Error} 登出过程中可能抛出错误
|
|
7961
|
+
* @example-exe
|
|
7962
|
+
* // 退出客户端
|
|
7963
|
+
* chrome.quit()
|
|
7964
|
+
* .then(() => {
|
|
7965
|
+
* console.log('客户端已退出');
|
|
7966
|
+
* })
|
|
7967
|
+
* .catch(error => {
|
|
7968
|
+
* console.error('退出客户端失败:', error);
|
|
7969
|
+
* });
|
|
7727
7970
|
* */
|
|
7728
7971
|
async quit() {
|
|
7729
7972
|
window.chrome.minimize(), await ke.logOut(), window.chrome.quit();
|
|
7730
7973
|
},
|
|
7731
7974
|
/**
|
|
7732
7975
|
* @doc
|
|
7733
|
-
* @API
|
|
7734
|
-
* @desc
|
|
7735
|
-
* @param {String} key -
|
|
7736
|
-
* @
|
|
7737
|
-
* @example
|
|
7976
|
+
* @API chrome
|
|
7977
|
+
* @desc 关闭当前页或指定标签页
|
|
7978
|
+
* @param {String} [key] - 可选参数,指定要关闭的标签页的唯一标识key
|
|
7979
|
+
* @returns {void} 无返回值
|
|
7980
|
+
* @example-exe
|
|
7981
|
+
* // 关闭当前活动标签页
|
|
7982
|
+
* chrome.close();
|
|
7983
|
+
*
|
|
7984
|
+
* // 关闭指定key的标签页
|
|
7985
|
+
* chrome.close('tab123');
|
|
7738
7986
|
* */
|
|
7739
7987
|
close(e) {
|
|
7740
|
-
if (
|
|
7988
|
+
if (e0.isChromeOpen()) {
|
|
7741
7989
|
if (e) {
|
|
7742
7990
|
window.chrome.close(e);
|
|
7743
7991
|
return;
|
|
@@ -7749,13 +7997,16 @@ let f0 = {
|
|
|
7749
7997
|
},
|
|
7750
7998
|
/**
|
|
7751
7999
|
* @doc
|
|
7752
|
-
* @API
|
|
7753
|
-
* @desc
|
|
7754
|
-
* @
|
|
7755
|
-
* @
|
|
8000
|
+
* @API chrome
|
|
8001
|
+
* @desc 客户端窗口最大化
|
|
8002
|
+
* @returns {void} 无返回值
|
|
8003
|
+
* @description 根据不同客户端类型执行不同的最大化操作:portal类型通过resize方法,ldt/ldtC类型通过maximize方法
|
|
8004
|
+
* @example-exe
|
|
8005
|
+
* // 将客户端窗口最大化
|
|
8006
|
+
* chrome.maximize();
|
|
7756
8007
|
* */
|
|
7757
8008
|
maximize() {
|
|
7758
|
-
switch (
|
|
8009
|
+
switch (j.getClientType()) {
|
|
7759
8010
|
case "portal":
|
|
7760
8011
|
window.chrome.resize(-1, -1);
|
|
7761
8012
|
break;
|
|
@@ -7767,11 +8018,17 @@ let f0 = {
|
|
|
7767
8018
|
},
|
|
7768
8019
|
/**
|
|
7769
8020
|
* @doc
|
|
7770
|
-
* @API
|
|
7771
|
-
* @desc
|
|
7772
|
-
* @param {String} windowId -
|
|
7773
|
-
* @
|
|
7774
|
-
* @
|
|
8021
|
+
* @API chrome
|
|
8022
|
+
* @desc 将指定标签页扩展至双屏显示
|
|
8023
|
+
* @param {String} [windowId] - 新打开窗口的ID,可选,默认使用当前标签页的windowId
|
|
8024
|
+
* @returns {void} 无返回值
|
|
8025
|
+
* @description 将当前活动标签页移动到指定窗口并调整大小以适应双屏显示
|
|
8026
|
+
* @example-exe
|
|
8027
|
+
* // 将当前活动标签页扩展到双屏显示
|
|
8028
|
+
* chrome.fullScreen2();
|
|
8029
|
+
*
|
|
8030
|
+
* // 指定窗口ID将标签页扩展到双屏显示
|
|
8031
|
+
* chrome.fullScreen2('customWindowId');
|
|
7775
8032
|
* @warning 2020年合同功能点,需要特定环境支持
|
|
7776
8033
|
* */
|
|
7777
8034
|
fullScreen2(e) {
|
|
@@ -7784,20 +8041,33 @@ let f0 = {
|
|
|
7784
8041
|
},
|
|
7785
8042
|
/**
|
|
7786
8043
|
* @doc
|
|
7787
|
-
* @API
|
|
8044
|
+
* @API chrome
|
|
7788
8045
|
* @desc 显示首页标签页
|
|
7789
|
-
* @
|
|
7790
|
-
* @example
|
|
8046
|
+
* @returns {void} 无返回值
|
|
8047
|
+
* @example-exe
|
|
8048
|
+
* // 显示首页标签页
|
|
8049
|
+
* chrome.showHome();
|
|
7791
8050
|
* */
|
|
7792
8051
|
showHome() {
|
|
7793
8052
|
return window.chrome.showTab2id("NETILER_BROWSER_DEFAULT");
|
|
7794
8053
|
},
|
|
7795
8054
|
/**
|
|
7796
|
-
*
|
|
7797
|
-
|
|
8055
|
+
* @doc
|
|
8056
|
+
* @API chrome
|
|
8057
|
+
* @desc 浏览器原生打开页签方式
|
|
8058
|
+
* @param {String|Object} url - 要打开的URL字符串或包含url属性的对象
|
|
8059
|
+
* @returns {void} 无返回值
|
|
8060
|
+
* @description 根据当前环境选择不同的打开方式:客户端环境使用openWithTab,齐安信环境使用openTab2center,其他环境使用window.open
|
|
8061
|
+
* @example-exe
|
|
8062
|
+
* // 使用URL字符串打开
|
|
8063
|
+
* chrome.open('https://example.com');
|
|
8064
|
+
*
|
|
8065
|
+
* // 使用包含url属性的对象打开
|
|
8066
|
+
* chrome.open({ url: 'https://example.com' });
|
|
8067
|
+
* */
|
|
7798
8068
|
open(e) {
|
|
7799
|
-
const t =
|
|
7800
|
-
if (
|
|
8069
|
+
const t = j.getClientType();
|
|
8070
|
+
if (e0.isChromeOpen())
|
|
7801
8071
|
this.openWithTab(e);
|
|
7802
8072
|
else
|
|
7803
8073
|
switch (t) {
|
|
@@ -7813,17 +8083,45 @@ let f0 = {
|
|
|
7813
8083
|
break;
|
|
7814
8084
|
}
|
|
7815
8085
|
},
|
|
8086
|
+
/**
|
|
8087
|
+
* @doc
|
|
8088
|
+
* @API chrome
|
|
8089
|
+
* @desc 内部方法:处理各种打开窗口的模式
|
|
8090
|
+
* @name _doOpen
|
|
8091
|
+
* @param {Object} opts - 打开窗口的配置选项
|
|
8092
|
+
* @param {String} [opts.id] - 窗口唯一标识,如不提供则自动生成
|
|
8093
|
+
* @param {String} [opts.type] - 窗口类型,默认为'_stab'
|
|
8094
|
+
* @param {Number} [opts.winMode] - 窗口打开模式,与openType功能相同
|
|
8095
|
+
* @param {Number} [opts.openType] - 窗口打开模式:1当前窗口;2弹出窗口;3打开外部浏览器;5创建隐藏IFRAME;6弹出独立窗口;7弹出页签窗口;8扩展至第二屏幕;9执行运行程序地址
|
|
8096
|
+
* @param {String} opts.url - 要打开的URL地址
|
|
8097
|
+
* @param {Boolean} [opts.autoFullscreen] - 是否自动全屏
|
|
8098
|
+
* @param {String} [opts.browserType] - 浏览器类型,用于指定打开外部浏览器
|
|
8099
|
+
* @param {Number} [opts.width] - 窗口宽度
|
|
8100
|
+
* @param {Number} [opts.height] - 窗口高度
|
|
8101
|
+
* @param {Number} [opts.left] - 窗口左侧位置
|
|
8102
|
+
* @param {Number} [opts.top] - 窗口顶部位置
|
|
8103
|
+
* @returns {void} 无返回值
|
|
8104
|
+
* @private
|
|
8105
|
+
* @example-exe
|
|
8106
|
+
* // 内部使用示例
|
|
8107
|
+
* chrome._doOpen({
|
|
8108
|
+
* id: 'app123',
|
|
8109
|
+
* url: 'https://example.com',
|
|
8110
|
+
* winMode: 1,
|
|
8111
|
+
* autoFullscreen: true
|
|
8112
|
+
* });
|
|
8113
|
+
*/
|
|
7816
8114
|
// eslint-disable-next-line no-underscore-dangle
|
|
7817
8115
|
_doOpen(e) {
|
|
7818
8116
|
e.id || (e.id = "date_id_" + (/* @__PURE__ */ new Date()).getTime()), typeof e.id != "string" && (e.id = e.id.toString()), e.type = e.type || "_stab";
|
|
7819
8117
|
const t = e.winMode || e.openType;
|
|
7820
|
-
if (
|
|
8118
|
+
if (j.getClientType() === "OnlyWebView")
|
|
7821
8119
|
window.chrome.open(e);
|
|
7822
8120
|
else if (e.url.indexOf(".exe") !== -1 || parseInt(t) === 9)
|
|
7823
8121
|
y0.openExec({
|
|
7824
8122
|
path: e.url
|
|
7825
8123
|
});
|
|
7826
|
-
else if (
|
|
8124
|
+
else if (e0.isChromeOpen()) {
|
|
7827
8125
|
let r = !1;
|
|
7828
8126
|
switch (parseInt(t)) {
|
|
7829
8127
|
case 2:
|
|
@@ -7857,8 +8155,26 @@ let f0 = {
|
|
|
7857
8155
|
ke.softLogById(e.id);
|
|
7858
8156
|
},
|
|
7859
8157
|
/**
|
|
7860
|
-
*
|
|
7861
|
-
* @
|
|
8158
|
+
* @doc
|
|
8159
|
+
* @API chrome
|
|
8160
|
+
* @desc 打开外部浏览器访问指定URL
|
|
8161
|
+
* @param {Object} opts - 浏览器打开配置选项
|
|
8162
|
+
* @param {String} opts.url - 要在外部浏览器中打开的URL
|
|
8163
|
+
* @param {Number} [opts.browserType] - 浏览器类型:0默认浏览器;1Firefox;3Chrome;4齐安信浏览器;5齐安信客户端;13InnerChrome
|
|
8164
|
+
* @returns {void} 无返回值
|
|
8165
|
+
* @private
|
|
8166
|
+
* @example-exe
|
|
8167
|
+
* // 打开默认浏览器
|
|
8168
|
+
* chrome._openBrowser({
|
|
8169
|
+
* url: 'https://example.com',
|
|
8170
|
+
* browserType: 0
|
|
8171
|
+
* });
|
|
8172
|
+
*
|
|
8173
|
+
* // 打开Chrome浏览器
|
|
8174
|
+
* chrome._openBrowser({
|
|
8175
|
+
* url: 'https://example.com',
|
|
8176
|
+
* browserType: 3
|
|
8177
|
+
* });
|
|
7862
8178
|
*/
|
|
7863
8179
|
_openBrowser(e) {
|
|
7864
8180
|
let t = "", r = decodeURIComponent(e.url);
|
|
@@ -7895,35 +8211,84 @@ let f0 = {
|
|
|
7895
8211
|
url: r
|
|
7896
8212
|
}));
|
|
7897
8213
|
},
|
|
7898
|
-
|
|
8214
|
+
/**
|
|
8215
|
+
* @doc
|
|
8216
|
+
* @API chrome
|
|
8217
|
+
* @desc 打开齐安信客户端或浏览器
|
|
8218
|
+
* @param {Object} data - 配置数据
|
|
8219
|
+
* @param {String} data.type - 打开类型,'browser'表示浏览器,'client'表示客户端
|
|
8220
|
+
* @param {String} data.url - 要打开的URL地址
|
|
8221
|
+
* @returns {Promise<void>} 无返回值
|
|
8222
|
+
* @description 根据操作系统和客户端类型,构造命令并通过API调用打开齐安信浏览器或客户端
|
|
8223
|
+
* @example-exe
|
|
8224
|
+
* // 打开齐安信浏览器
|
|
8225
|
+
* chrome.openBrowser2QAX({
|
|
8226
|
+
* type: 'browser',
|
|
8227
|
+
* url: 'https://example.com'
|
|
8228
|
+
* });
|
|
8229
|
+
*
|
|
8230
|
+
* // 打开齐安信客户端
|
|
8231
|
+
* chrome.openBrowser2QAX({
|
|
8232
|
+
* type: 'client',
|
|
8233
|
+
* url: 'https://example.com'
|
|
8234
|
+
* });
|
|
8235
|
+
*/
|
|
7899
8236
|
openBrowser2QAX(e) {
|
|
7900
8237
|
let { type: t, url: r } = e;
|
|
7901
|
-
const n =
|
|
8238
|
+
const n = j.getClientType();
|
|
7902
8239
|
if (n === "ldt" || n === "ldtC") {
|
|
7903
8240
|
window.chrome.openByQax(encodeURI(`--app="${r}"`));
|
|
7904
8241
|
return;
|
|
7905
8242
|
}
|
|
7906
8243
|
const o = window.navigator.userAgent;
|
|
7907
8244
|
let a = "";
|
|
7908
|
-
o.indexOf("Windows") !== -1 ? a = `"C:/Program Files (x86)/Qaxbrowser/Application/qaxbrowser.exe" --app="${r}" --user-data-dir="C:/Program Files/leadalSoft/qax/UserData" --start-maximized` : t === "client" ? a = `/opt/qianxin.com/qaxbrowser/qaxbrowser-safe --app="${r}" --Kiosk -ignore-certificate-errors --start-maximized --user-data-dir="/opt/leadalSoft/qax/UserData"` : a = `/opt/qianxin.com.browser/qaxbrowser/qaxbrowser-safe --app="${r}" --Kiosk -ignore-certificate-errors --start-maximized --user-data-dir="/opt/leadalSoft/qax/UserData"`, a = encodeURIComponent(encodeURIComponent(a)), r = "http://127.0.0.1:2267/api/app/customCommandPost?command=" + a,
|
|
8245
|
+
o.indexOf("Windows") !== -1 ? a = `"C:/Program Files (x86)/Qaxbrowser/Application/qaxbrowser.exe" --app="${r}" --user-data-dir="C:/Program Files/leadalSoft/qax/UserData" --start-maximized` : t === "client" ? a = `/opt/qianxin.com/qaxbrowser/qaxbrowser-safe --app="${r}" --Kiosk -ignore-certificate-errors --start-maximized --user-data-dir="/opt/leadalSoft/qax/UserData"` : a = `/opt/qianxin.com.browser/qaxbrowser/qaxbrowser-safe --app="${r}" --Kiosk -ignore-certificate-errors --start-maximized --user-data-dir="/opt/leadalSoft/qax/UserData"`, a = encodeURIComponent(encodeURIComponent(a)), r = "http://127.0.0.1:2267/api/app/customCommandPost?command=" + a, V.post(r, {}).then((x) => {
|
|
7909
8246
|
}).catch(() => {
|
|
7910
8247
|
});
|
|
7911
8248
|
},
|
|
7912
8249
|
/**
|
|
7913
|
-
*
|
|
7914
|
-
|
|
8250
|
+
* @doc
|
|
8251
|
+
* @API chrome
|
|
8252
|
+
* @desc 关闭客户端头部框架
|
|
8253
|
+
* @param {String} [id] - 要关闭的头部框架ID
|
|
8254
|
+
* @returns {void} 无返回值
|
|
8255
|
+
* @description 仅在ldtC和portal客户端类型中有效,先隐藏再关闭头部框架
|
|
8256
|
+
* @example-exe
|
|
8257
|
+
* // 关闭默认头部框架
|
|
8258
|
+
* chrome.closeHeaderFrame();
|
|
8259
|
+
*
|
|
8260
|
+
* // 关闭指定ID的头部框架
|
|
8261
|
+
* chrome.closeHeaderFrame('header123');
|
|
8262
|
+
* */
|
|
7915
8263
|
closeHeaderFrame(e) {
|
|
7916
|
-
const t =
|
|
8264
|
+
const t = j.getClientType();
|
|
7917
8265
|
if (!(t !== "ldtC" && t !== "portal"))
|
|
7918
8266
|
return window.chrome.hideHeaderFrame(e), window.chrome.closeHeaderFrame(e);
|
|
7919
8267
|
},
|
|
7920
8268
|
/**
|
|
7921
|
-
*
|
|
7922
|
-
|
|
8269
|
+
* @doc
|
|
8270
|
+
* @API chrome
|
|
8271
|
+
* @desc 关闭客户端底部框架
|
|
8272
|
+
* @returns {void} 无返回值
|
|
8273
|
+
* @description 先隐藏再关闭底部框架,使用可选链操作符确保兼容性
|
|
8274
|
+
* @example-exe
|
|
8275
|
+
* // 关闭客户端底部框架
|
|
8276
|
+
* chrome.closeFooterFrame();
|
|
8277
|
+
* */
|
|
7923
8278
|
closeFooterFrame() {
|
|
7924
8279
|
var e, t;
|
|
7925
8280
|
return (e = window == null ? void 0 : window.chrome) == null || e.hideFooterFrame(), (t = window == null ? void 0 : window.chrome) == null ? void 0 : t.closeFooterFrame();
|
|
7926
8281
|
},
|
|
8282
|
+
/**
|
|
8283
|
+
* @doc
|
|
8284
|
+
* @API chrome
|
|
8285
|
+
* @desc 重新尝试指纹登录验证
|
|
8286
|
+
* @returns {Promise<void>} 无返回值
|
|
8287
|
+
* @description 获取指纹信息并验证用户身份,如果验证失败则触发登出
|
|
8288
|
+
* @example-exe
|
|
8289
|
+
* // 重新验证指纹登录
|
|
8290
|
+
* chrome.retryFingerLogin();
|
|
8291
|
+
* */
|
|
7927
8292
|
retryFingerLogin() {
|
|
7928
8293
|
y0.fecthFinger().then(async (e) => {
|
|
7929
8294
|
var t;
|
|
@@ -7935,6 +8300,16 @@ let f0 = {
|
|
|
7935
8300
|
this.fireLogout();
|
|
7936
8301
|
});
|
|
7937
8302
|
},
|
|
8303
|
+
/**
|
|
8304
|
+
* @doc
|
|
8305
|
+
* @API chrome
|
|
8306
|
+
* @desc 触发用户登出操作
|
|
8307
|
+
* @returns {void} 无返回值
|
|
8308
|
+
* @description 退出IM,关闭除首页外的所有窗口,并触发logout2事件
|
|
8309
|
+
* @example-exe
|
|
8310
|
+
* // 触发用户登出流程
|
|
8311
|
+
* chrome.fireLogout();
|
|
8312
|
+
* */
|
|
7938
8313
|
fireLogout() {
|
|
7939
8314
|
const e = this;
|
|
7940
8315
|
this.quitIM();
|
|
@@ -7945,28 +8320,62 @@ let f0 = {
|
|
|
7945
8320
|
}), e.fireEvent("logout2");
|
|
7946
8321
|
});
|
|
7947
8322
|
},
|
|
8323
|
+
/**
|
|
8324
|
+
* @doc
|
|
8325
|
+
* @API chrome
|
|
8326
|
+
* @desc 判断是否在客户端环境中打开
|
|
8327
|
+
* @returns {Boolean} 返回是否在客户端环境中的布尔值
|
|
8328
|
+
* @description 检查当前客户端类型是否为portal、iframe、ldtC、ldt或OnlyWebView
|
|
8329
|
+
* @example-exe
|
|
8330
|
+
* if (chrome.isChromeOpen()) {
|
|
8331
|
+
* console.log('当前在客户端环境中');
|
|
8332
|
+
* } else {
|
|
8333
|
+
* console.log('当前在普通浏览器环境中');
|
|
8334
|
+
* }
|
|
8335
|
+
*/
|
|
7948
8336
|
isChromeOpen() {
|
|
7949
|
-
const e =
|
|
8337
|
+
const e = j.getClientType();
|
|
7950
8338
|
return ["portal", "iframe", "ldtC", "ldt", "OnlyWebView"].indexOf(e) !== -1;
|
|
7951
8339
|
}
|
|
7952
8340
|
};
|
|
7953
8341
|
const Qa = {
|
|
7954
8342
|
/**
|
|
7955
|
-
*
|
|
7956
|
-
|
|
7957
|
-
|
|
7958
|
-
|
|
7959
|
-
|
|
7960
|
-
|
|
7961
|
-
|
|
8343
|
+
* @doc
|
|
8344
|
+
* @API chrome
|
|
8345
|
+
* @desc 打开即时通讯功能
|
|
8346
|
+
* @returns {void} 无返回值
|
|
8347
|
+
* @description 检查系统服务可用性,并通过本地API和token打开即时通讯窗口
|
|
8348
|
+
* @example-exe
|
|
8349
|
+
* // 打开用户即时通讯
|
|
8350
|
+
* chrome.openIM();
|
|
8351
|
+
* @throws {Error} 获取token失败时可能抛出错误
|
|
8352
|
+
* */
|
|
8353
|
+
openIM() {
|
|
8354
|
+
window.SysService && typeof window.SysService.openNewIM == "function" && mini.getToken("ZHWZ").then((e) => {
|
|
8355
|
+
const t = new XMLHttpRequest();
|
|
8356
|
+
t.open("GET", "http://127.0.0.1:2069/api/show", !0), t.setRequestHeader("Access-Control-Allow-Origin", "*"), t.timeout = 1e3, t.send(), t.ontimeout = () => {
|
|
8357
|
+
window.SysService.openNewIM(e.access_token);
|
|
7962
8358
|
};
|
|
7963
|
-
}).catch((
|
|
7964
|
-
console.error(
|
|
8359
|
+
}).catch((e) => {
|
|
8360
|
+
console.error(e);
|
|
7965
8361
|
});
|
|
7966
8362
|
},
|
|
7967
8363
|
/**
|
|
7968
|
-
*
|
|
7969
|
-
|
|
8364
|
+
* @doc
|
|
8365
|
+
* @API chrome
|
|
8366
|
+
* @desc 退出即时通讯功能
|
|
8367
|
+
* @param {Function} [callback] - 可选的回调函数,在操作完成后执行
|
|
8368
|
+
* @returns {void} 无返回值
|
|
8369
|
+
* @description 通过本地API发送退出请求,设置超时处理,确保在各种情况下都能执行回调
|
|
8370
|
+
* @example-exe
|
|
8371
|
+
* // 退出即时通讯并执行回调
|
|
8372
|
+
* chrome.quitIM(() => {
|
|
8373
|
+
* console.log('退出即时通讯后执行的操作');
|
|
8374
|
+
* });
|
|
8375
|
+
*
|
|
8376
|
+
* // 退出即时通讯不使用回调
|
|
8377
|
+
* im.quitIM();
|
|
8378
|
+
* */
|
|
7970
8379
|
quitIM(e) {
|
|
7971
8380
|
const t = new XMLHttpRequest();
|
|
7972
8381
|
t.open("GET", "http://127.0.0.1:2069/api/quit", !0), t.setRequestHeader("Access-Control-Allow-Origin", "*"), t.send(null);
|
|
@@ -7981,8 +8390,18 @@ const Qa = {
|
|
|
7981
8390
|
}
|
|
7982
8391
|
}, Ur = {
|
|
7983
8392
|
/**
|
|
7984
|
-
*
|
|
7985
|
-
* @
|
|
8393
|
+
* @doc
|
|
8394
|
+
* @API chrome
|
|
8395
|
+
* @desc 处理弹窗参数并调用openPopup方法显示弹窗
|
|
8396
|
+
* @param {Object} options - 弹窗配置选项
|
|
8397
|
+
* @param {Number} options.width - 弹窗宽度
|
|
8398
|
+
* @param {Number} options.height - 弹窗高度
|
|
8399
|
+
* @param {String} options.src - 弹窗内容源地址
|
|
8400
|
+
* @param {String} options.id - 弹窗唯一标识符
|
|
8401
|
+
* @param {Number} options.top - 弹窗顶部位置
|
|
8402
|
+
* @param {Number} options.left - 弹窗左侧位置
|
|
8403
|
+
* @return {*} 返回openPopup方法的返回值
|
|
8404
|
+
* @example-exe chrome.showPopup78({width: 800, height: 600, src: 'https://example.com', id: 'popup1'})
|
|
7986
8405
|
*/
|
|
7987
8406
|
showPopup78(e) {
|
|
7988
8407
|
const t = JSON.parse(JSON.stringify(e, ["width", "height", "src", "id", "top", "left"]));
|
|
@@ -7990,93 +8409,133 @@ const Qa = {
|
|
|
7990
8409
|
},
|
|
7991
8410
|
/**
|
|
7992
8411
|
* @doc
|
|
7993
|
-
* @API
|
|
7994
|
-
* @desc
|
|
8412
|
+
* @API chrome
|
|
8413
|
+
* @desc 根据客户端类型打开弹窗,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
7995
8414
|
* @param {Object} data - 弹窗配置
|
|
8415
|
+
* @param {String} data.id - 弹窗ID
|
|
8416
|
+
* @param {Number} data.width - 弹窗宽度
|
|
8417
|
+
* @param {Number} data.height - 弹窗高度
|
|
8418
|
+
* @param {Number} data.left - 弹窗左侧位置
|
|
8419
|
+
* @param {Number} data.top - 弹窗顶部位置
|
|
8420
|
+
* @param {String} data.src - 弹窗内容源地址
|
|
8421
|
+
* @param {Boolean} data.active - 是否立即显示激活,默认为true
|
|
8422
|
+
* @param {Boolean} data.moveable - 是否可拖拽移动,默认false
|
|
7996
8423
|
* @return 无返回值
|
|
7997
|
-
* @example chrome.openPopup({
|
|
7998
|
-
|
|
8424
|
+
* @example-exe chrome.openPopup({id: 'popup123', width: 800, height: 600, src: 'https://www.baidu.com', top: 200, left: 200})
|
|
8425
|
+
*/
|
|
7999
8426
|
openPopup(e) {
|
|
8000
|
-
const t =
|
|
8427
|
+
const t = j.getClientType();
|
|
8001
8428
|
t !== "ldtC" && t !== "portal" ? d0.createFrame(e) : window.chrome.openPopup(e);
|
|
8002
8429
|
},
|
|
8003
8430
|
/**
|
|
8004
8431
|
* @doc
|
|
8005
|
-
* @API
|
|
8006
|
-
* @desc
|
|
8007
|
-
* @param {Object} data -
|
|
8432
|
+
* @API chrome
|
|
8433
|
+
* @desc 根据客户端类型打开弹窗,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
8434
|
+
* @param {Object} data - 弹窗配置
|
|
8435
|
+
* @param {String} data.id - 弹窗ID
|
|
8436
|
+
* @param {Number} data.width - 弹窗宽度
|
|
8437
|
+
* @param {Number} data.height - 弹窗高度
|
|
8438
|
+
* @param {Number} data.left - 弹窗左侧位置
|
|
8439
|
+
* @param {Number} data.top - 弹窗顶部位置
|
|
8440
|
+
* @param {String} data.src - 弹窗内容源地址
|
|
8441
|
+
* @param {Boolean} data.active - 是否立即显示激活,默认为true
|
|
8442
|
+
* @param {Boolean} data.moveable - 是否可拖拽移动,默认false
|
|
8008
8443
|
* @return 无返回值
|
|
8009
|
-
* @example chrome.openDialog({
|
|
8010
|
-
|
|
8444
|
+
* @example-exe chrome.openDialog({id: 'popup123', width: 800, height: 600, src: 'https://www.baidu.com', top: 200, left: 200})
|
|
8445
|
+
*/
|
|
8011
8446
|
openDialog(e) {
|
|
8012
|
-
const t =
|
|
8447
|
+
const t = j.getClientType();
|
|
8013
8448
|
t !== "ldtC" && t !== "portal" ? d0.createFrame(e) : window.chrome.openDialog(e);
|
|
8014
8449
|
},
|
|
8015
8450
|
/**
|
|
8016
8451
|
* @doc
|
|
8017
|
-
* @API
|
|
8018
|
-
* @desc
|
|
8452
|
+
* @API chrome
|
|
8453
|
+
* @desc 根据客户端类型关闭弹窗,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
8019
8454
|
* @param {String} id - 弹窗ID
|
|
8020
8455
|
* @return 无返回值
|
|
8021
|
-
* @example chrome.closePopup('popup123')
|
|
8022
|
-
|
|
8456
|
+
* @example-exe chrome.closePopup('popup123')
|
|
8457
|
+
*/
|
|
8023
8458
|
closePopup(e) {
|
|
8024
|
-
const t =
|
|
8459
|
+
const t = j.getClientType();
|
|
8025
8460
|
t !== "ldtC" && t !== "portal" ? d0.hideLeadalFrame(e) : window.chrome.closePopup(e);
|
|
8026
8461
|
},
|
|
8027
8462
|
/**
|
|
8028
8463
|
* @doc
|
|
8029
|
-
* @API
|
|
8030
|
-
* @desc
|
|
8464
|
+
* @API chrome
|
|
8465
|
+
* @desc 根据客户端类型关闭对话框,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
8031
8466
|
* @param {String} id - 对话框ID
|
|
8032
8467
|
* @return 无返回值
|
|
8033
|
-
* @example chrome.closeDialog('dialog123')
|
|
8034
|
-
|
|
8468
|
+
* @example-exe chrome.closeDialog('dialog123')
|
|
8469
|
+
*/
|
|
8035
8470
|
closeDialog(e) {
|
|
8036
|
-
const t =
|
|
8471
|
+
const t = j.getClientType();
|
|
8037
8472
|
t !== "ldtC" && t !== "portal" ? d0.hideLeadalFrame() : window.chrome.closeDialog(e);
|
|
8038
8473
|
},
|
|
8039
8474
|
/**
|
|
8040
8475
|
* @doc
|
|
8041
|
-
* @API
|
|
8042
|
-
* @desc
|
|
8476
|
+
* @API chrome
|
|
8477
|
+
* @desc 根据客户端类型隐藏弹窗,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
8043
8478
|
* @param {String} id - 弹窗ID
|
|
8044
8479
|
* @return 无返回值
|
|
8045
|
-
* @example chrome.hidePopup('popup123')
|
|
8046
|
-
|
|
8480
|
+
* @example-exe chrome.hidePopup('popup123')
|
|
8481
|
+
*/
|
|
8047
8482
|
hidePopup(e) {
|
|
8048
|
-
const t =
|
|
8483
|
+
const t = j.getClientType();
|
|
8049
8484
|
t !== "ldtC" && t !== "portal" ? d0.hideLeadalFrame(e) : window.chrome.hidePopup(e);
|
|
8050
8485
|
},
|
|
8051
8486
|
/**
|
|
8052
8487
|
* @doc
|
|
8053
|
-
* @API
|
|
8054
|
-
* @desc
|
|
8488
|
+
* @API chrome
|
|
8489
|
+
* @desc 根据客户端类型隐藏对话框,非ldtC和portal客户端使用frame模块,否则使用window.chrome
|
|
8055
8490
|
* @param {String} id - 对话框ID
|
|
8056
8491
|
* @return 无返回值
|
|
8057
|
-
* @example chrome.hideDialog('dialog123')
|
|
8058
|
-
|
|
8492
|
+
* @example-exe chrome.hideDialog('dialog123')
|
|
8493
|
+
*/
|
|
8059
8494
|
hideDialog(e) {
|
|
8060
|
-
const t =
|
|
8495
|
+
const t = j.getClientType();
|
|
8061
8496
|
t !== "ldtC" && t !== "portal" ? d0.hideLeadalFrame() : window.chrome.hideDialog(e);
|
|
8062
8497
|
}
|
|
8063
8498
|
}, Ir = {
|
|
8499
|
+
/**
|
|
8500
|
+
* @doc 获取本地窗口屏幕信息
|
|
8501
|
+
* @API chrome
|
|
8502
|
+
* @desc 根据客户端类型获取本地窗口屏幕信息,portal客户端使用window.chrome.getScreens,其他使用本地服务API
|
|
8503
|
+
* @return {Promise<Object>} 返回包含屏幕信息的Promise对象
|
|
8504
|
+
* @return {number} 返回.code - 状态码,成功为200
|
|
8505
|
+
* @return {Array} 返回.data - 屏幕信息数组
|
|
8506
|
+
* @example-exe chrome.getLocalWindowScreens().then(result => console.log(result.data))
|
|
8507
|
+
* @throws {Error} 获取屏幕信息失败时抛出异常
|
|
8508
|
+
*/
|
|
8064
8509
|
getLocalWindowScreens() {
|
|
8065
|
-
return
|
|
8510
|
+
return j.getClientType() == "portal" && typeof window.chrome.getScreens == "function" ? new Promise(async (t, r) => {
|
|
8066
8511
|
try {
|
|
8067
8512
|
let o = { code: 200, data: await window.chrome.getScreens() };
|
|
8068
8513
|
t(o);
|
|
8069
8514
|
} catch (n) {
|
|
8070
8515
|
r(n);
|
|
8071
8516
|
}
|
|
8072
|
-
}) :
|
|
8073
|
-
url: "http://127.0.0.1:2267/api/cis/service/getScreens",
|
|
8074
|
-
method: "GET",
|
|
8075
|
-
withCredentials: !1
|
|
8076
|
-
});
|
|
8517
|
+
}) : V.get("http://127.0.0.1:2267/api/cis/service/getScreens");
|
|
8077
8518
|
},
|
|
8519
|
+
/**
|
|
8520
|
+
* @doc 获取系统信息
|
|
8521
|
+
* @API chrome
|
|
8522
|
+
* @desc 根据客户端类型获取系统信息,portal客户端使用window.chrome.getSystem,其他返回默认空对象
|
|
8523
|
+
* @return {Promise<Object>|Object} 系统信息对象或Promise包装的系统信息对象
|
|
8524
|
+
* @return {string} 返回.electronVersion - Electron版本
|
|
8525
|
+
* @return {string} 返回.appVersion - 应用版本
|
|
8526
|
+
* @return {string} 返回.osType - 操作系统类型
|
|
8527
|
+
* @return {string} 返回.osPlatform - 操作系统平台
|
|
8528
|
+
* @return {string} 返回.osRelease - 操作系统发行版本
|
|
8529
|
+
* @return {string} 返回.osArch - 操作系统架构
|
|
8530
|
+
* @return {string} 返回.osTypeName - 操作系统类型名称
|
|
8531
|
+
* @return {string} 返回.macAddress - MAC地址
|
|
8532
|
+
* @return {Array} 返回.ipAddress - IP地址数组
|
|
8533
|
+
* @return {string} 返回.hostname - 主机名
|
|
8534
|
+
* @example-exe chrome.getSystem().then(sysInfo => console.log(sysInfo.osType))
|
|
8535
|
+
* @warning 依赖electron客户端,firefox客户端不支持;
|
|
8536
|
+
*/
|
|
8078
8537
|
getSystem() {
|
|
8079
|
-
return
|
|
8538
|
+
return e0.getVersion().type === "portal" && typeof window.chrome.getSystem == "function" ? window.chrome.getSystem() : new Promise((t, r) => {
|
|
8080
8539
|
t({
|
|
8081
8540
|
electronVersion: "",
|
|
8082
8541
|
appVersion: "",
|
|
@@ -8091,20 +8550,81 @@ const Qa = {
|
|
|
8091
8550
|
});
|
|
8092
8551
|
});
|
|
8093
8552
|
},
|
|
8553
|
+
/**
|
|
8554
|
+
* @doc 获取客户端IP地址
|
|
8555
|
+
* @API chrome
|
|
8556
|
+
* @desc 根据客户端类型和版本获取客户端IP地址,ldtC客户端且版本>=304645使用chrome.getClientIp,其他通过getSystem获取
|
|
8557
|
+
* @return {Promise<string>} 返回IP地址字符串,多个IP用逗号分隔
|
|
8558
|
+
* @example-exe chrome.getClientIp().then(ip => console.log(ip))
|
|
8559
|
+
* @warning 依赖electron客户端,firefox客户端不支持;
|
|
8560
|
+
*/
|
|
8094
8561
|
async getClientIp() {
|
|
8095
8562
|
var r, n;
|
|
8096
|
-
const e =
|
|
8563
|
+
const e = e0.getVersion();
|
|
8097
8564
|
let t = "";
|
|
8098
|
-
return e.type === "ldtC" && e.version >= 304645 ? t = (r =
|
|
8565
|
+
return e.type === "ldtC" && e.version >= 304645 ? t = (r = e0 == null ? void 0 : e0.getClientIp()) == null ? void 0 : r.join(",").replaceAll(" ", "") : t = (n = (await Ir.getSystem()).ipAddress) == null ? void 0 : n.join(",").replaceAll(" ", ""), t;
|
|
8566
|
+
},
|
|
8567
|
+
/**
|
|
8568
|
+
* @doc 执行系统命令
|
|
8569
|
+
* @API chrome
|
|
8570
|
+
* @desc 根据客户端类型执行系统命令,portal客户端使用window.chrome.execCommand,其他返回默认空对象
|
|
8571
|
+
* @param {string} command - 要执行的系统命令
|
|
8572
|
+
* @return {Promise<Object>|Object} 命令执行结果对象或Promise包装的结果对象
|
|
8573
|
+
* @example-exe chrome.execCommand('ipconfig').then(result => console.log(result))
|
|
8574
|
+
*/
|
|
8575
|
+
execCommand(e) {
|
|
8576
|
+
return e0.getVersion().type === "portal" && typeof window.chrome.execCommand == "function" ? window.chrome.execCommand(e) : new Promise((r, n) => {
|
|
8577
|
+
r(!1);
|
|
8578
|
+
});
|
|
8579
|
+
},
|
|
8580
|
+
/**
|
|
8581
|
+
* @doc 检查资源是否存在
|
|
8582
|
+
* @API chrome
|
|
8583
|
+
* @desc 根据客户端类型检查资源是否存在,portal客户端使用window.chrome.checkResource,其他返回默认false
|
|
8584
|
+
* @param {string} resource - 要检查的资源路径
|
|
8585
|
+
* @return {Promise<boolean>|boolean} 资源是否存在的Promise对象或直接结果
|
|
8586
|
+
* @example-exe chrome.checkResource('//path//to//resource').then(exists => console.log(exists))
|
|
8587
|
+
* @warning 1、依赖electron客户端,firefox客户端不支持;2、地址注意需将单斜杠替换为双斜杠
|
|
8588
|
+
*/
|
|
8589
|
+
checkResource(e) {
|
|
8590
|
+
return e0.getVersion().type === "portal" && typeof window.chrome.checkResource == "function" ? window.chrome.checkResource(e) : new Promise((r, n) => {
|
|
8591
|
+
r(!1);
|
|
8592
|
+
});
|
|
8593
|
+
},
|
|
8594
|
+
/**
|
|
8595
|
+
* @doc 打开文件路径
|
|
8596
|
+
* @API chrome
|
|
8597
|
+
* @desc 根据客户端类型打开文件路径,portal客户端使用window.chrome.openPath
|
|
8598
|
+
* @param {string} path - 要打开的文件路径
|
|
8599
|
+
* @example-exe chrome.openPath('//path//to//file.txt').then(result => console.log(result))
|
|
8600
|
+
* @warning 1、依赖electron客户端,firefox客户端不支持;2、地址注意需将单斜杠替换为双斜杠
|
|
8601
|
+
*/
|
|
8602
|
+
openPath(e) {
|
|
8603
|
+
return e0.getVersion().type === "portal" && typeof window.chrome.openPath == "function" ? window.chrome.openPath(e) : new Promise((r, n) => {
|
|
8604
|
+
r(!1);
|
|
8605
|
+
});
|
|
8606
|
+
},
|
|
8607
|
+
/**
|
|
8608
|
+
* @doc 打开文件
|
|
8609
|
+
* @API chrome
|
|
8610
|
+
* @desc 根据客户端类型打开文件,portal客户端使用window.chrome.openFile
|
|
8611
|
+
* @param {string} path - 要打开的文件路径
|
|
8612
|
+
* @example-exe chrome.openFile('//path//to//file.txt').then(result => console.log(result))
|
|
8613
|
+
* @warning 1、依赖electron客户端,firefox客户端不支持;2、地址注意需将单斜杠替换为双斜杠
|
|
8614
|
+
*/
|
|
8615
|
+
openFile(e) {
|
|
8616
|
+
return e0.getVersion().type === "portal" && typeof window.chrome.openFile == "function" ? window.chrome.openFile(e) : new Promise((r, n) => {
|
|
8617
|
+
r(!1);
|
|
8618
|
+
});
|
|
8099
8619
|
}
|
|
8100
8620
|
}, Za = {
|
|
8101
|
-
...
|
|
8621
|
+
...e0,
|
|
8102
8622
|
...Qa,
|
|
8103
8623
|
...y0,
|
|
8104
8624
|
...Ur,
|
|
8105
8625
|
...Ir,
|
|
8106
8626
|
...Qe
|
|
8107
|
-
}, Ei =
|
|
8627
|
+
}, Ei = j, Bi = ke, Ci = Za, Ai = Va, mi = {
|
|
8108
8628
|
LOGO: new URL("../assets/images/logo.png", import.meta.url).href
|
|
8109
8629
|
}, Fi = {
|
|
8110
8630
|
Alibaba: new URL("../assets/fonts/Alibaba-PuHuiTi-Medium.ttf", import.meta.url).href
|