oauth0-js-lib 2.2.6 → 2.2.7
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/authApi.d.ts +13 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +331 -325
- package/dist/index.umd.js +13 -13
- package/dist/main.d.ts +1 -13
- package/dist/modal.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var x = (e, t, r) =>
|
|
4
|
-
const
|
|
1
|
+
var xn = Object.defineProperty;
|
|
2
|
+
var Fn = (e, t, r) => t in e ? xn(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
|
+
var x = (e, t, r) => Fn(e, typeof t != "symbol" ? t + "" : t, r);
|
|
4
|
+
const Mn = {
|
|
5
5
|
baseUrl: "",
|
|
6
6
|
createEndpoint: "/api/oauth0/create",
|
|
7
7
|
authEventEndpoint: "/api/oauth0/auth-events",
|
|
8
8
|
authConfirmEndpoint: "/api/oauth0/auth-confirm"
|
|
9
|
-
},
|
|
9
|
+
}, Dn = typeof __OAUTH_LIB_CONFIG__ < "u" ? __OAUTH_LIB_CONFIG__ : void 0, kn = typeof globalThis < "u" && globalThis.OAUTH_LIB_CONFIG ? globalThis.OAUTH_LIB_CONFIG : void 0;
|
|
10
10
|
let nt = {
|
|
11
|
-
...Fn,
|
|
12
11
|
...Mn,
|
|
13
|
-
...Dn
|
|
12
|
+
...Dn,
|
|
13
|
+
...kn
|
|
14
14
|
};
|
|
15
15
|
function Vo(e) {
|
|
16
16
|
nt = { ...nt, ...e };
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function rn() {
|
|
19
19
|
return nt;
|
|
20
20
|
}
|
|
21
21
|
function on(e, t) {
|
|
@@ -35,12 +35,12 @@ function jn(e) {
|
|
|
35
35
|
let t;
|
|
36
36
|
return typeof ArrayBuffer < "u" && ArrayBuffer.isView ? t = ArrayBuffer.isView(e) : t = e && e.buffer && an(e.buffer), t;
|
|
37
37
|
}
|
|
38
|
-
const Hn = Be("string"), M = Be("function"), un = Be("number"), he = (e) => e !== null && typeof e == "object", zn = (e) => e === !0 || e === !1,
|
|
38
|
+
const Hn = Be("string"), M = Be("function"), un = Be("number"), he = (e) => e !== null && typeof e == "object", zn = (e) => e === !0 || e === !1, Ee = (e) => {
|
|
39
39
|
if (Ae(e) !== "object")
|
|
40
40
|
return !1;
|
|
41
41
|
const t = at(e);
|
|
42
42
|
return (t === null || t === Object.prototype || Object.getPrototypeOf(t) === null) && !(sn in e) && !(Te in e);
|
|
43
|
-
},
|
|
43
|
+
}, $n = (e) => {
|
|
44
44
|
if (!he(e) || de(e))
|
|
45
45
|
return !1;
|
|
46
46
|
try {
|
|
@@ -48,7 +48,7 @@ const Hn = Be("string"), M = Be("function"), un = Be("number"), he = (e) => e !=
|
|
|
48
48
|
} catch {
|
|
49
49
|
return !1;
|
|
50
50
|
}
|
|
51
|
-
},
|
|
51
|
+
}, Vn = H("Date"), Jn = H("File"), Kn = H("Blob"), Wn = H("FileList"), Gn = (e) => he(e) && M(e.pipe), Qn = (e) => {
|
|
52
52
|
let t;
|
|
53
53
|
return e && (typeof FormData == "function" && e instanceof FormData || M(e.append) && ((t = Ae(e)) === "formdata" || // detect form-data instance
|
|
54
54
|
t === "object" && M(e.toString) && e.toString() === "[object FormData]"));
|
|
@@ -84,7 +84,7 @@ const Q = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : type
|
|
|
84
84
|
function rt() {
|
|
85
85
|
const { caseless: e, skipUndefined: t } = ln(this) && this || {}, r = {}, n = (o, i) => {
|
|
86
86
|
const s = e && cn(r, i) || i;
|
|
87
|
-
|
|
87
|
+
Ee(r[s]) && Ee(o) ? r[s] = rt(r[s], o) : Ee(o) ? r[s] = rt({}, o) : se(o) ? r[s] = o.slice() : (!t || !ie(o)) && (r[s] = o);
|
|
88
88
|
};
|
|
89
89
|
for (let o = 0, i = arguments.length; o < i; o++)
|
|
90
90
|
arguments[o] && pe(arguments[o], n);
|
|
@@ -137,7 +137,7 @@ const rr = (e, t, r, { allOwnKeys: n } = {}) => (pe(t, (o, i) => {
|
|
|
137
137
|
function(r, n, o) {
|
|
138
138
|
return n.toUpperCase() + o;
|
|
139
139
|
}
|
|
140
|
-
),
|
|
140
|
+
), ht = (({ hasOwnProperty: e }) => (t, r) => e.call(t, r))(Object.prototype), pr = H("RegExp"), fn = (e, t) => {
|
|
141
141
|
const r = Object.getOwnPropertyDescriptors(e), n = {};
|
|
142
142
|
pe(r, (o, i) => {
|
|
143
143
|
let s;
|
|
@@ -167,10 +167,10 @@ const rr = (e, t, r, { allOwnKeys: n } = {}) => (pe(t, (o, i) => {
|
|
|
167
167
|
return se(e) ? n(e) : n(String(e).split(t)), r;
|
|
168
168
|
}, yr = () => {
|
|
169
169
|
}, wr = (e, t) => e != null && Number.isFinite(e = +e) ? e : t;
|
|
170
|
-
function
|
|
170
|
+
function br(e) {
|
|
171
171
|
return !!(e && M(e.append) && e[sn] === "FormData" && e[Te]);
|
|
172
172
|
}
|
|
173
|
-
const
|
|
173
|
+
const Er = (e) => {
|
|
174
174
|
const t = new Array(10), r = (n, o) => {
|
|
175
175
|
if (he(n)) {
|
|
176
176
|
if (t.indexOf(n) >= 0)
|
|
@@ -206,14 +206,14 @@ const br = (e) => {
|
|
|
206
206
|
isNumber: un,
|
|
207
207
|
isBoolean: zn,
|
|
208
208
|
isObject: he,
|
|
209
|
-
isPlainObject:
|
|
210
|
-
isEmptyObject:
|
|
209
|
+
isPlainObject: Ee,
|
|
210
|
+
isEmptyObject: $n,
|
|
211
211
|
isReadableStream: Xn,
|
|
212
212
|
isRequest: Zn,
|
|
213
213
|
isResponse: er,
|
|
214
214
|
isHeaders: tr,
|
|
215
215
|
isUndefined: ie,
|
|
216
|
-
isDate:
|
|
216
|
+
isDate: Vn,
|
|
217
217
|
isFile: Jn,
|
|
218
218
|
isBlob: Kn,
|
|
219
219
|
isRegExp: pr,
|
|
@@ -236,8 +236,8 @@ const br = (e) => {
|
|
|
236
236
|
forEachEntry: lr,
|
|
237
237
|
matchAll: fr,
|
|
238
238
|
isHTMLForm: dr,
|
|
239
|
-
hasOwnProperty:
|
|
240
|
-
hasOwnProp:
|
|
239
|
+
hasOwnProperty: ht,
|
|
240
|
+
hasOwnProp: ht,
|
|
241
241
|
// an alias to avoid ESLint no-prototype-builtins detection
|
|
242
242
|
reduceDescriptors: fn,
|
|
243
243
|
freezeMethods: gr,
|
|
@@ -248,8 +248,8 @@ const br = (e) => {
|
|
|
248
248
|
findKey: cn,
|
|
249
249
|
global: Q,
|
|
250
250
|
isContextDefined: ln,
|
|
251
|
-
isSpecCompliantForm:
|
|
252
|
-
toJSONObject:
|
|
251
|
+
isSpecCompliantForm: br,
|
|
252
|
+
toJSONObject: Er,
|
|
253
253
|
isAsyncFn: Cr,
|
|
254
254
|
isThenable: Sr,
|
|
255
255
|
setImmediate: dn,
|
|
@@ -315,7 +315,7 @@ function ot(e) {
|
|
|
315
315
|
function gn(e) {
|
|
316
316
|
return f.endsWith(e, "[]") ? e.slice(0, -2) : e;
|
|
317
317
|
}
|
|
318
|
-
function
|
|
318
|
+
function pt(e, t, r) {
|
|
319
319
|
return e ? e.concat(t).map(function(o, i) {
|
|
320
320
|
return o = gn(o), !r && i ? "[" + o + "]" : o;
|
|
321
321
|
}).join(r ? "." : "") : t;
|
|
@@ -355,15 +355,15 @@ function Ne(e, t, r) {
|
|
|
355
355
|
if (f.endsWith(p, "{}"))
|
|
356
356
|
p = n ? p : p.slice(0, -2), d = JSON.stringify(d);
|
|
357
357
|
else if (f.isArray(d) && Br(d) || (f.isFileList(d) || f.endsWith(p, "[]")) && (w = f.toArray(d)))
|
|
358
|
-
return p = gn(p), w.forEach(function(
|
|
359
|
-
!(f.isUndefined(
|
|
358
|
+
return p = gn(p), w.forEach(function(E, R) {
|
|
359
|
+
!(f.isUndefined(E) || E === null) && t.append(
|
|
360
360
|
// eslint-disable-next-line no-nested-ternary
|
|
361
|
-
s === !0 ?
|
|
362
|
-
c(
|
|
361
|
+
s === !0 ? pt([p], R, i) : s === null ? p : p + "[]",
|
|
362
|
+
c(E)
|
|
363
363
|
);
|
|
364
364
|
}), !1;
|
|
365
365
|
}
|
|
366
|
-
return ot(d) ? !0 : (t.append(
|
|
366
|
+
return ot(d) ? !0 : (t.append(pt(g, p, i), c(d)), !1);
|
|
367
367
|
}
|
|
368
368
|
const h = [], m = Object.assign(Nr, {
|
|
369
369
|
defaultVisitor: l,
|
|
@@ -389,7 +389,7 @@ function Ne(e, t, r) {
|
|
|
389
389
|
throw new TypeError("data must be an object");
|
|
390
390
|
return y(e), t;
|
|
391
391
|
}
|
|
392
|
-
function
|
|
392
|
+
function gt(e) {
|
|
393
393
|
const t = {
|
|
394
394
|
"!": "%21",
|
|
395
395
|
"'": "%27",
|
|
@@ -412,8 +412,8 @@ mn.append = function(t, r) {
|
|
|
412
412
|
};
|
|
413
413
|
mn.toString = function(t) {
|
|
414
414
|
const r = t ? function(n) {
|
|
415
|
-
return t.call(this, n,
|
|
416
|
-
} :
|
|
415
|
+
return t.call(this, n, gt);
|
|
416
|
+
} : gt;
|
|
417
417
|
return this._pairs.map(function(o) {
|
|
418
418
|
return r(o[0]) + "=" + r(o[1]);
|
|
419
419
|
}, "").join("&");
|
|
@@ -436,7 +436,7 @@ function yn(e, t, r) {
|
|
|
436
436
|
}
|
|
437
437
|
return e;
|
|
438
438
|
}
|
|
439
|
-
class
|
|
439
|
+
class mt {
|
|
440
440
|
constructor() {
|
|
441
441
|
this.handlers = [];
|
|
442
442
|
}
|
|
@@ -502,12 +502,12 @@ const wn = {
|
|
|
502
502
|
Blob: Ir
|
|
503
503
|
},
|
|
504
504
|
protocols: ["http", "https", "file", "blob", "url", "data"]
|
|
505
|
-
}, ct = typeof window < "u" && typeof document < "u", it = typeof navigator == "object" && navigator || void 0,
|
|
505
|
+
}, ct = typeof window < "u" && typeof document < "u", it = typeof navigator == "object" && navigator || void 0, Ur = ct && (!it || ["ReactNative", "NativeScript", "NS"].indexOf(it.product) < 0), vr = typeof WorkerGlobalScope < "u" && // eslint-disable-next-line no-undef
|
|
506
506
|
self instanceof WorkerGlobalScope && typeof self.importScripts == "function", xr = ct && window.location.href || "http://localhost", Fr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
507
507
|
__proto__: null,
|
|
508
508
|
hasBrowserEnv: ct,
|
|
509
|
-
hasStandardBrowserEnv:
|
|
510
|
-
hasStandardBrowserWebWorkerEnv:
|
|
509
|
+
hasStandardBrowserEnv: Ur,
|
|
510
|
+
hasStandardBrowserWebWorkerEnv: vr,
|
|
511
511
|
navigator: it,
|
|
512
512
|
origin: xr
|
|
513
513
|
}, Symbol.toStringTag, { value: "Module" })), F = {
|
|
@@ -534,7 +534,7 @@ function kr(e) {
|
|
|
534
534
|
i = r[n], t[i] = e[i];
|
|
535
535
|
return t;
|
|
536
536
|
}
|
|
537
|
-
function
|
|
537
|
+
function bn(e) {
|
|
538
538
|
function t(r, n, o, i) {
|
|
539
539
|
let s = r[i++];
|
|
540
540
|
if (s === "__proto__") return !0;
|
|
@@ -565,7 +565,7 @@ const ge = {
|
|
|
565
565
|
transformRequest: [function(t, r) {
|
|
566
566
|
const n = r.getContentType() || "", o = n.indexOf("application/json") > -1, i = f.isObject(t);
|
|
567
567
|
if (i && f.isHTMLForm(t) && (t = new FormData(t)), f.isFormData(t))
|
|
568
|
-
return o ? JSON.stringify(
|
|
568
|
+
return o ? JSON.stringify(bn(t)) : t;
|
|
569
569
|
if (f.isArrayBuffer(t) || f.isBuffer(t) || f.isStream(t) || f.isFile(t) || f.isBlob(t) || f.isReadableStream(t))
|
|
570
570
|
return t;
|
|
571
571
|
if (f.isArrayBufferView(t))
|
|
@@ -653,7 +653,7 @@ const jr = f.toObjectSet([
|
|
|
653
653
|
`).forEach(function(s) {
|
|
654
654
|
o = s.indexOf(":"), r = s.substring(0, o).trim().toLowerCase(), n = s.substring(o + 1).trim(), !(!r || t[r] && jr[r]) && (r === "set-cookie" ? t[r] ? t[r].push(n) : t[r] = [n] : t[r] = t[r] ? t[r] + ", " + n : n);
|
|
655
655
|
}), t;
|
|
656
|
-
},
|
|
656
|
+
}, yt = Symbol("internals");
|
|
657
657
|
function ce(e) {
|
|
658
658
|
return e && String(e).trim().toLowerCase();
|
|
659
659
|
}
|
|
@@ -667,7 +667,7 @@ function zr(e) {
|
|
|
667
667
|
t[n[1]] = n[2];
|
|
668
668
|
return t;
|
|
669
669
|
}
|
|
670
|
-
const
|
|
670
|
+
const $r = (e) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());
|
|
671
671
|
function Le(e, t, r, n, o) {
|
|
672
672
|
if (f.isFunction(n))
|
|
673
673
|
return n.call(this, t, r);
|
|
@@ -678,7 +678,7 @@ function Le(e, t, r, n, o) {
|
|
|
678
678
|
return n.test(t);
|
|
679
679
|
}
|
|
680
680
|
}
|
|
681
|
-
function
|
|
681
|
+
function Vr(e) {
|
|
682
682
|
return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (t, r, n) => r.toUpperCase() + n);
|
|
683
683
|
}
|
|
684
684
|
function Jr(e, t) {
|
|
@@ -708,7 +708,7 @@ let D = class {
|
|
|
708
708
|
const s = (a, u) => f.forEach(a, (c, l) => i(c, l, u));
|
|
709
709
|
if (f.isPlainObject(t) || t instanceof this.constructor)
|
|
710
710
|
s(t, r);
|
|
711
|
-
else if (f.isString(t) && (t = t.trim()) &&
|
|
711
|
+
else if (f.isString(t) && (t = t.trim()) && !$r(t))
|
|
712
712
|
s(Hr(t), r);
|
|
713
713
|
else if (f.isObject(t) && f.isIterable(t)) {
|
|
714
714
|
let a = {}, u, c;
|
|
@@ -774,7 +774,7 @@ let D = class {
|
|
|
774
774
|
r[s] = Ce(o), delete r[i];
|
|
775
775
|
return;
|
|
776
776
|
}
|
|
777
|
-
const a = t ?
|
|
777
|
+
const a = t ? Vr(i) : String(i).trim();
|
|
778
778
|
a !== i && delete r[i], r[a] = Ce(o), n[a] = !0;
|
|
779
779
|
}), this;
|
|
780
780
|
}
|
|
@@ -808,7 +808,7 @@ let D = class {
|
|
|
808
808
|
return r.forEach((o) => n.set(o)), n;
|
|
809
809
|
}
|
|
810
810
|
static accessor(t) {
|
|
811
|
-
const n = (this[
|
|
811
|
+
const n = (this[yt] = this[yt] = {
|
|
812
812
|
accessors: {}
|
|
813
813
|
}).accessors, o = this.prototype;
|
|
814
814
|
function i(s) {
|
|
@@ -836,7 +836,7 @@ function Ie(e, t) {
|
|
|
836
836
|
i = a.call(r, i, o.normalize(), t ? t.status : void 0);
|
|
837
837
|
}), o.normalize(), i;
|
|
838
838
|
}
|
|
839
|
-
function
|
|
839
|
+
function En(e) {
|
|
840
840
|
return !!(e && e.__CANCEL__);
|
|
841
841
|
}
|
|
842
842
|
function ae(e, t, r) {
|
|
@@ -906,7 +906,7 @@ const Re = (e, t, r = 3) => {
|
|
|
906
906
|
};
|
|
907
907
|
e(h);
|
|
908
908
|
}, r);
|
|
909
|
-
},
|
|
909
|
+
}, wt = (e, t) => {
|
|
910
910
|
const r = e != null;
|
|
911
911
|
return [(n) => t[0]({
|
|
912
912
|
lengthComputable: r,
|
|
@@ -955,7 +955,7 @@ function Sn(e, t, r) {
|
|
|
955
955
|
let n = !Xr(t);
|
|
956
956
|
return e && (n || r == !1) ? Zr(e, t) : t;
|
|
957
957
|
}
|
|
958
|
-
const
|
|
958
|
+
const Et = (e) => e instanceof D ? { ...e } : e;
|
|
959
959
|
function X(e, t) {
|
|
960
960
|
t = t || {};
|
|
961
961
|
const r = {};
|
|
@@ -1013,7 +1013,7 @@ function X(e, t) {
|
|
|
1013
1013
|
socketPath: s,
|
|
1014
1014
|
responseEncoding: s,
|
|
1015
1015
|
validateStatus: a,
|
|
1016
|
-
headers: (c, l, h) => o(
|
|
1016
|
+
headers: (c, l, h) => o(Et(c), Et(l), h, !0)
|
|
1017
1017
|
};
|
|
1018
1018
|
return f.forEach(Object.keys({ ...e, ...t }), function(l) {
|
|
1019
1019
|
const h = u[l] || o, m = h(e[l], t[l], l);
|
|
@@ -1055,13 +1055,13 @@ const Rn = (e) => {
|
|
|
1055
1055
|
function w() {
|
|
1056
1056
|
if (!g)
|
|
1057
1057
|
return;
|
|
1058
|
-
const
|
|
1058
|
+
const E = D.from(
|
|
1059
1059
|
"getAllResponseHeaders" in g && g.getAllResponseHeaders()
|
|
1060
1060
|
), _ = {
|
|
1061
1061
|
data: !a || a === "text" || a === "json" ? g.responseText : g.response,
|
|
1062
1062
|
status: g.status,
|
|
1063
1063
|
statusText: g.statusText,
|
|
1064
|
-
headers:
|
|
1064
|
+
headers: E,
|
|
1065
1065
|
config: e,
|
|
1066
1066
|
request: g
|
|
1067
1067
|
};
|
|
@@ -1076,8 +1076,8 @@ const Rn = (e) => {
|
|
|
1076
1076
|
}, g.onabort = function() {
|
|
1077
1077
|
g && (n(new I("Request aborted", I.ECONNABORTED, e, g)), g = null);
|
|
1078
1078
|
}, g.onerror = function(R) {
|
|
1079
|
-
const _ = R && R.message ? R.message : "Network Error",
|
|
1080
|
-
|
|
1079
|
+
const _ = R && R.message ? R.message : "Network Error", b = new I(_, I.ERR_NETWORK, e, g);
|
|
1080
|
+
b.event = R || null, n(b), g = null;
|
|
1081
1081
|
}, g.ontimeout = function() {
|
|
1082
1082
|
let R = o.timeout ? "timeout of " + o.timeout + "ms exceeded" : "timeout exceeded";
|
|
1083
1083
|
const _ = o.transitional || wn;
|
|
@@ -1089,8 +1089,8 @@ const Rn = (e) => {
|
|
|
1089
1089
|
)), g = null;
|
|
1090
1090
|
}, i === void 0 && s.setContentType(null), "setRequestHeader" in g && f.forEach(s.toJSON(), function(R, _) {
|
|
1091
1091
|
g.setRequestHeader(_, R);
|
|
1092
|
-
}), f.isUndefined(o.withCredentials) || (g.withCredentials = !!o.withCredentials), a && a !== "json" && (g.responseType = o.responseType), c && ([m, d] = Re(c, !0), g.addEventListener("progress", m)), u && g.upload && ([h, y] = Re(u), g.upload.addEventListener("progress", h), g.upload.addEventListener("loadend", y)), (o.cancelToken || o.signal) && (l = (
|
|
1093
|
-
g && (n(!
|
|
1092
|
+
}), f.isUndefined(o.withCredentials) || (g.withCredentials = !!o.withCredentials), a && a !== "json" && (g.responseType = o.responseType), c && ([m, d] = Re(c, !0), g.addEventListener("progress", m)), u && g.upload && ([h, y] = Re(u), g.upload.addEventListener("progress", h), g.upload.addEventListener("loadend", y)), (o.cancelToken || o.signal) && (l = (E) => {
|
|
1093
|
+
g && (n(!E || E.type ? new ae(null, e, g) : E), g.abort(), g = null);
|
|
1094
1094
|
}, o.cancelToken && o.cancelToken.subscribe(l), o.signal && (o.signal.aborted ? l() : o.signal.addEventListener("abort", l)));
|
|
1095
1095
|
const P = Kr(o.url);
|
|
1096
1096
|
if (P && F.protocols.indexOf(P) === -1) {
|
|
@@ -1150,7 +1150,7 @@ const Rn = (e) => {
|
|
|
1150
1150
|
} finally {
|
|
1151
1151
|
await t.cancel();
|
|
1152
1152
|
}
|
|
1153
|
-
},
|
|
1153
|
+
}, Ct = (e, t, r, n) => {
|
|
1154
1154
|
const o = oo(e, t);
|
|
1155
1155
|
let i = 0, s, a = (u) => {
|
|
1156
1156
|
s || (s = !0, n && n(u));
|
|
@@ -1179,13 +1179,13 @@ const Rn = (e) => {
|
|
|
1179
1179
|
}, {
|
|
1180
1180
|
highWaterMark: 2
|
|
1181
1181
|
});
|
|
1182
|
-
},
|
|
1182
|
+
}, St = 64 * 1024, { isFunction: we } = f, so = (({ Request: e, Response: t }) => ({
|
|
1183
1183
|
Request: e,
|
|
1184
1184
|
Response: t
|
|
1185
1185
|
}))(f.global), {
|
|
1186
|
-
ReadableStream:
|
|
1187
|
-
TextEncoder:
|
|
1188
|
-
} = f.global,
|
|
1186
|
+
ReadableStream: Rt,
|
|
1187
|
+
TextEncoder: Tt
|
|
1188
|
+
} = f.global, At = (e, ...t) => {
|
|
1189
1189
|
try {
|
|
1190
1190
|
return !!e(...t);
|
|
1191
1191
|
} catch {
|
|
@@ -1198,17 +1198,17 @@ const Rn = (e) => {
|
|
|
1198
1198
|
const { fetch: t, Request: r, Response: n } = e, o = t ? we(t) : typeof fetch == "function", i = we(r), s = we(n);
|
|
1199
1199
|
if (!o)
|
|
1200
1200
|
return !1;
|
|
1201
|
-
const a = o && we(
|
|
1201
|
+
const a = o && we(Rt), u = o && (typeof Tt == "function" ? /* @__PURE__ */ ((d) => (p) => d.encode(p))(new Tt()) : async (d) => new Uint8Array(await new r(d).arrayBuffer())), c = i && a && At(() => {
|
|
1202
1202
|
let d = !1;
|
|
1203
1203
|
const p = new r(F.origin, {
|
|
1204
|
-
body: new
|
|
1204
|
+
body: new Rt(),
|
|
1205
1205
|
method: "POST",
|
|
1206
1206
|
get duplex() {
|
|
1207
1207
|
return d = !0, "half";
|
|
1208
1208
|
}
|
|
1209
1209
|
}).headers.has("Content-Type");
|
|
1210
1210
|
return d && !p;
|
|
1211
|
-
}), l = s && a &&
|
|
1211
|
+
}), l = s && a && At(() => f.isReadableStream(new n("").body)), h = {
|
|
1212
1212
|
stream: l && ((d) => d.body)
|
|
1213
1213
|
};
|
|
1214
1214
|
o && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((d) => {
|
|
@@ -1243,45 +1243,45 @@ const Rn = (e) => {
|
|
|
1243
1243
|
method: g,
|
|
1244
1244
|
data: w,
|
|
1245
1245
|
signal: P,
|
|
1246
|
-
cancelToken:
|
|
1246
|
+
cancelToken: E,
|
|
1247
1247
|
timeout: R,
|
|
1248
1248
|
onDownloadProgress: _,
|
|
1249
|
-
onUploadProgress:
|
|
1249
|
+
onUploadProgress: b,
|
|
1250
1250
|
responseType: S,
|
|
1251
1251
|
headers: A,
|
|
1252
1252
|
withCredentials: C = "same-origin",
|
|
1253
1253
|
fetchOptions: L
|
|
1254
1254
|
} = Rn(d), B = t || fetch;
|
|
1255
1255
|
S = S ? (S + "").toLowerCase() : "text";
|
|
1256
|
-
let N = no([P,
|
|
1256
|
+
let N = no([P, E && E.toAbortSignal()], R), T = null;
|
|
1257
1257
|
const O = N && N.unsubscribe && (() => {
|
|
1258
1258
|
N.unsubscribe();
|
|
1259
1259
|
});
|
|
1260
1260
|
let q;
|
|
1261
1261
|
try {
|
|
1262
|
-
if (
|
|
1262
|
+
if (b && c && g !== "get" && g !== "head" && (q = await y(A, w)) !== 0) {
|
|
1263
1263
|
let k = new r(p, {
|
|
1264
1264
|
method: "POST",
|
|
1265
1265
|
body: w,
|
|
1266
1266
|
duplex: "half"
|
|
1267
|
-
}),
|
|
1268
|
-
if (f.isFormData(w) && (
|
|
1269
|
-
const [G, te] =
|
|
1267
|
+
}), V;
|
|
1268
|
+
if (f.isFormData(w) && (V = k.headers.get("content-type")) && A.setContentType(V), k.body) {
|
|
1269
|
+
const [G, te] = wt(
|
|
1270
1270
|
q,
|
|
1271
|
-
Re(bt(
|
|
1271
|
+
Re(bt(b))
|
|
1272
1272
|
);
|
|
1273
|
-
w =
|
|
1273
|
+
w = Ct(k.body, St, G, te);
|
|
1274
1274
|
}
|
|
1275
1275
|
}
|
|
1276
1276
|
f.isString(C) || (C = C ? "include" : "omit");
|
|
1277
|
-
const
|
|
1277
|
+
const v = i && "credentials" in r.prototype, me = {
|
|
1278
1278
|
...L,
|
|
1279
1279
|
signal: N,
|
|
1280
1280
|
method: g.toUpperCase(),
|
|
1281
1281
|
headers: A.normalize().toJSON(),
|
|
1282
1282
|
body: w,
|
|
1283
1283
|
duplex: "half",
|
|
1284
|
-
credentials:
|
|
1284
|
+
credentials: v ? C : void 0
|
|
1285
1285
|
};
|
|
1286
1286
|
T = i && new r(p, me);
|
|
1287
1287
|
let j = await (i ? B(T, L) : B(p, me));
|
|
@@ -1291,12 +1291,12 @@ const Rn = (e) => {
|
|
|
1291
1291
|
["status", "statusText", "headers"].forEach((ne) => {
|
|
1292
1292
|
k[ne] = j[ne];
|
|
1293
1293
|
});
|
|
1294
|
-
const
|
|
1295
|
-
|
|
1294
|
+
const V = f.toFiniteNumber(j.headers.get("content-length")), [G, te] = _ && wt(
|
|
1295
|
+
V,
|
|
1296
1296
|
Re(bt(_), !0)
|
|
1297
1297
|
) || [];
|
|
1298
1298
|
j = new n(
|
|
1299
|
-
|
|
1299
|
+
Ct(j.body, St, G, () => {
|
|
1300
1300
|
te && te(), O && O();
|
|
1301
1301
|
}),
|
|
1302
1302
|
k
|
|
@@ -1304,8 +1304,8 @@ const Rn = (e) => {
|
|
|
1304
1304
|
}
|
|
1305
1305
|
S = S || "text";
|
|
1306
1306
|
let ue = await h[f.findKey(h, S) || "text"](j, d);
|
|
1307
|
-
return !ye && O && O(), await new Promise((k,
|
|
1308
|
-
Cn(k,
|
|
1307
|
+
return !ye && O && O(), await new Promise((k, V) => {
|
|
1308
|
+
Cn(k, V, {
|
|
1309
1309
|
data: ue,
|
|
1310
1310
|
headers: D.from(j.headers),
|
|
1311
1311
|
status: j.status,
|
|
@@ -1314,13 +1314,13 @@ const Rn = (e) => {
|
|
|
1314
1314
|
request: T
|
|
1315
1315
|
});
|
|
1316
1316
|
});
|
|
1317
|
-
} catch (
|
|
1318
|
-
throw O && O(),
|
|
1317
|
+
} catch (v) {
|
|
1318
|
+
throw O && O(), v && v.name === "TypeError" && /Load failed|fetch/i.test(v.message) ? Object.assign(
|
|
1319
1319
|
new I("Network Error", I.ERR_NETWORK, d, T),
|
|
1320
1320
|
{
|
|
1321
|
-
cause:
|
|
1321
|
+
cause: v.cause || v
|
|
1322
1322
|
}
|
|
1323
|
-
) : I.from(
|
|
1323
|
+
) : I.from(v, v && v.code, d, T);
|
|
1324
1324
|
}
|
|
1325
1325
|
};
|
|
1326
1326
|
}, uo = /* @__PURE__ */ new Map(), Tn = (e) => {
|
|
@@ -1352,7 +1352,7 @@ f.forEach(lt, (e, t) => {
|
|
|
1352
1352
|
Object.defineProperty(e, "adapterName", { value: t });
|
|
1353
1353
|
}
|
|
1354
1354
|
});
|
|
1355
|
-
const
|
|
1355
|
+
const Bt = (e) => `- ${e}`, co = (e) => f.isFunction(e) || e === null || e === !1;
|
|
1356
1356
|
function lo(e, t) {
|
|
1357
1357
|
e = f.isArray(e) ? e : [e];
|
|
1358
1358
|
const { length: r } = e;
|
|
@@ -1372,8 +1372,8 @@ function lo(e, t) {
|
|
|
1372
1372
|
([u, c]) => `adapter ${u} ` + (c === !1 ? "is not supported by the environment" : "is not available in the build")
|
|
1373
1373
|
);
|
|
1374
1374
|
let a = r ? s.length > 1 ? `since :
|
|
1375
|
-
` + s.map(
|
|
1376
|
-
`) : " " +
|
|
1375
|
+
` + s.map(Bt).join(`
|
|
1376
|
+
`) : " " + Bt(s[0]) : "as no adapter specified";
|
|
1377
1377
|
throw new I(
|
|
1378
1378
|
"There is no suitable adapter to dispatch the request " + a,
|
|
1379
1379
|
"ERR_NOT_SUPPORT"
|
|
@@ -1397,7 +1397,7 @@ function _e(e) {
|
|
|
1397
1397
|
if (e.cancelToken && e.cancelToken.throwIfRequested(), e.signal && e.signal.aborted)
|
|
1398
1398
|
throw new ae(null, e);
|
|
1399
1399
|
}
|
|
1400
|
-
function
|
|
1400
|
+
function Nt(e) {
|
|
1401
1401
|
return _e(e), e.headers = D.from(e.headers), e.data = Ie.call(
|
|
1402
1402
|
e,
|
|
1403
1403
|
e.transformRequest
|
|
@@ -1408,7 +1408,7 @@ function Pt(e) {
|
|
|
1408
1408
|
n
|
|
1409
1409
|
), n.headers = D.from(n.headers), n;
|
|
1410
1410
|
}, function(n) {
|
|
1411
|
-
return
|
|
1411
|
+
return En(n) || (_e(e), n && n.response && (n.response.data = Ie.call(
|
|
1412
1412
|
e,
|
|
1413
1413
|
e.transformResponse,
|
|
1414
1414
|
n.response
|
|
@@ -1421,7 +1421,7 @@ const Bn = "1.13.1", Pe = {};
|
|
|
1421
1421
|
return typeof n === e || "a" + (t < 1 ? "n " : " ") + e;
|
|
1422
1422
|
};
|
|
1423
1423
|
});
|
|
1424
|
-
const
|
|
1424
|
+
const Pt = {};
|
|
1425
1425
|
Pe.transitional = function(t, r, n) {
|
|
1426
1426
|
function o(i, s) {
|
|
1427
1427
|
return "[Axios v" + Bn + "] Transitional option '" + i + "'" + s + (n ? ". " + n : "");
|
|
@@ -1432,7 +1432,7 @@ Pe.transitional = function(t, r, n) {
|
|
|
1432
1432
|
o(s, " has been removed" + (r ? " in " + r : "")),
|
|
1433
1433
|
I.ERR_DEPRECATED
|
|
1434
1434
|
);
|
|
1435
|
-
return r && !
|
|
1435
|
+
return r && !Pt[s] && (Pt[s] = !0, console.warn(
|
|
1436
1436
|
o(
|
|
1437
1437
|
s,
|
|
1438
1438
|
" has been deprecated since v" + r + " and will be removed in the near future"
|
|
@@ -1467,8 +1467,8 @@ const Se = {
|
|
|
1467
1467
|
let Y = class {
|
|
1468
1468
|
constructor(t) {
|
|
1469
1469
|
this.defaults = t || {}, this.interceptors = {
|
|
1470
|
-
request: new
|
|
1471
|
-
response: new
|
|
1470
|
+
request: new mt(),
|
|
1471
|
+
response: new mt()
|
|
1472
1472
|
};
|
|
1473
1473
|
}
|
|
1474
1474
|
/**
|
|
@@ -1533,7 +1533,7 @@ let Y = class {
|
|
|
1533
1533
|
});
|
|
1534
1534
|
let l, h = 0, m;
|
|
1535
1535
|
if (!u) {
|
|
1536
|
-
const d = [
|
|
1536
|
+
const d = [Nt.bind(this), void 0];
|
|
1537
1537
|
for (d.unshift(...a), d.push(...c), m = d.length, l = Promise.resolve(r); h < m; )
|
|
1538
1538
|
l = l.then(d[h++], d[h++]);
|
|
1539
1539
|
return l;
|
|
@@ -1550,7 +1550,7 @@ let Y = class {
|
|
|
1550
1550
|
}
|
|
1551
1551
|
}
|
|
1552
1552
|
try {
|
|
1553
|
-
l =
|
|
1553
|
+
l = Nt.call(this, y);
|
|
1554
1554
|
} catch (d) {
|
|
1555
1555
|
return Promise.reject(d);
|
|
1556
1556
|
}
|
|
@@ -1749,44 +1749,44 @@ function Pn(e) {
|
|
|
1749
1749
|
return Pn(X(e, o));
|
|
1750
1750
|
}, r;
|
|
1751
1751
|
}
|
|
1752
|
-
const
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1752
|
+
const U = Pn(ge);
|
|
1753
|
+
U.Axios = Y;
|
|
1754
|
+
U.CanceledError = ae;
|
|
1755
|
+
U.CancelToken = ho;
|
|
1756
|
+
U.isCancel = En;
|
|
1757
|
+
U.VERSION = Bn;
|
|
1758
|
+
U.toFormData = Ne;
|
|
1759
|
+
U.AxiosError = I;
|
|
1760
|
+
U.Cancel = U.CanceledError;
|
|
1761
|
+
U.all = function(t) {
|
|
1762
1762
|
return Promise.all(t);
|
|
1763
1763
|
};
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1764
|
+
U.spread = po;
|
|
1765
|
+
U.isAxiosError = go;
|
|
1766
|
+
U.mergeConfig = X;
|
|
1767
|
+
U.AxiosHeaders = D;
|
|
1768
|
+
U.formToJSON = (e) => bn(f.isHTMLForm(e) ? new FormData(e) : e);
|
|
1769
|
+
U.getAdapter = An.getAdapter;
|
|
1770
|
+
U.HttpStatusCode = st;
|
|
1771
|
+
U.default = U;
|
|
1772
1772
|
const {
|
|
1773
|
-
Axios:
|
|
1774
|
-
AxiosError:
|
|
1775
|
-
CanceledError:
|
|
1776
|
-
isCancel:
|
|
1777
|
-
CancelToken:
|
|
1778
|
-
VERSION:
|
|
1779
|
-
all:
|
|
1780
|
-
Cancel:
|
|
1781
|
-
isAxiosError:
|
|
1782
|
-
spread:
|
|
1783
|
-
toFormData:
|
|
1784
|
-
AxiosHeaders:
|
|
1785
|
-
HttpStatusCode:
|
|
1786
|
-
formToJSON:
|
|
1787
|
-
getAdapter:
|
|
1788
|
-
mergeConfig:
|
|
1789
|
-
} =
|
|
1773
|
+
Axios: Wo,
|
|
1774
|
+
AxiosError: Go,
|
|
1775
|
+
CanceledError: Qo,
|
|
1776
|
+
isCancel: Yo,
|
|
1777
|
+
CancelToken: Xo,
|
|
1778
|
+
VERSION: Zo,
|
|
1779
|
+
all: ei,
|
|
1780
|
+
Cancel: ti,
|
|
1781
|
+
isAxiosError: ni,
|
|
1782
|
+
spread: ri,
|
|
1783
|
+
toFormData: oi,
|
|
1784
|
+
AxiosHeaders: ii,
|
|
1785
|
+
HttpStatusCode: si,
|
|
1786
|
+
formToJSON: ai,
|
|
1787
|
+
getAdapter: ui,
|
|
1788
|
+
mergeConfig: ci
|
|
1789
|
+
} = U, mo = `.oauth-modal-overlay {\r
|
|
1790
1790
|
position: fixed;\r
|
|
1791
1791
|
top: 0;\r
|
|
1792
1792
|
left: 0;\r
|
|
@@ -1955,16 +1955,16 @@ const {
|
|
|
1955
1955
|
margin-top: -10px;\r
|
|
1956
1956
|
margin-bottom: 10px;\r
|
|
1957
1957
|
}`;
|
|
1958
|
-
var oe = {},
|
|
1958
|
+
var oe = {}, Ue, Ot;
|
|
1959
1959
|
function yo() {
|
|
1960
|
-
return
|
|
1960
|
+
return Ot || (Ot = 1, Ue = function() {
|
|
1961
1961
|
return typeof Promise == "function" && Promise.prototype && Promise.prototype.then;
|
|
1962
|
-
}),
|
|
1962
|
+
}), Ue;
|
|
1963
1963
|
}
|
|
1964
|
-
var
|
|
1964
|
+
var ve = {}, W = {}, Lt;
|
|
1965
1965
|
function Z() {
|
|
1966
|
-
if (
|
|
1967
|
-
|
|
1966
|
+
if (Lt) return W;
|
|
1967
|
+
Lt = 1;
|
|
1968
1968
|
let e;
|
|
1969
1969
|
const t = [
|
|
1970
1970
|
0,
|
|
@@ -2031,9 +2031,9 @@ function Z() {
|
|
|
2031
2031
|
return e(n);
|
|
2032
2032
|
}, W;
|
|
2033
2033
|
}
|
|
2034
|
-
var xe = {},
|
|
2034
|
+
var xe = {}, It;
|
|
2035
2035
|
function ft() {
|
|
2036
|
-
return
|
|
2036
|
+
return It || (It = 1, (function(e) {
|
|
2037
2037
|
e.L = { bit: 1 }, e.M = { bit: 0 }, e.Q = { bit: 3 }, e.H = { bit: 2 };
|
|
2038
2038
|
function t(r) {
|
|
2039
2039
|
if (typeof r != "string")
|
|
@@ -2068,10 +2068,10 @@ function ft() {
|
|
|
2068
2068
|
};
|
|
2069
2069
|
})(xe)), xe;
|
|
2070
2070
|
}
|
|
2071
|
-
var Fe,
|
|
2071
|
+
var Fe, _t;
|
|
2072
2072
|
function wo() {
|
|
2073
|
-
if (
|
|
2074
|
-
|
|
2073
|
+
if (_t) return Fe;
|
|
2074
|
+
_t = 1;
|
|
2075
2075
|
function e() {
|
|
2076
2076
|
this.buffer = [], this.length = 0;
|
|
2077
2077
|
}
|
|
@@ -2094,7 +2094,7 @@ function wo() {
|
|
|
2094
2094
|
}, Fe = e, Fe;
|
|
2095
2095
|
}
|
|
2096
2096
|
var Me, Ut;
|
|
2097
|
-
function
|
|
2097
|
+
function bo() {
|
|
2098
2098
|
if (Ut) return Me;
|
|
2099
2099
|
Ut = 1;
|
|
2100
2100
|
function e(t) {
|
|
@@ -2113,9 +2113,9 @@ function Eo() {
|
|
|
2113
2113
|
return this.reservedBit[t * this.size + r];
|
|
2114
2114
|
}, Me = e, Me;
|
|
2115
2115
|
}
|
|
2116
|
-
var De = {},
|
|
2117
|
-
function
|
|
2118
|
-
return
|
|
2116
|
+
var De = {}, vt;
|
|
2117
|
+
function Eo() {
|
|
2118
|
+
return vt || (vt = 1, (function(e) {
|
|
2119
2119
|
const t = Z().getSymbolSize;
|
|
2120
2120
|
e.getRowColCoords = function(n) {
|
|
2121
2121
|
if (n === 1) return [];
|
|
@@ -2134,10 +2134,10 @@ function bo() {
|
|
|
2134
2134
|
};
|
|
2135
2135
|
})(De)), De;
|
|
2136
2136
|
}
|
|
2137
|
-
var ke = {},
|
|
2137
|
+
var ke = {}, xt;
|
|
2138
2138
|
function Co() {
|
|
2139
|
-
if (
|
|
2140
|
-
|
|
2139
|
+
if (xt) return ke;
|
|
2140
|
+
xt = 1;
|
|
2141
2141
|
const e = Z().getSymbolSize, t = 7;
|
|
2142
2142
|
return ke.getPositions = function(n) {
|
|
2143
2143
|
const o = e(n);
|
|
@@ -2151,9 +2151,9 @@ function Co() {
|
|
|
2151
2151
|
];
|
|
2152
2152
|
}, ke;
|
|
2153
2153
|
}
|
|
2154
|
-
var qe = {},
|
|
2154
|
+
var qe = {}, Ft;
|
|
2155
2155
|
function So() {
|
|
2156
|
-
return
|
|
2156
|
+
return Ft || (Ft = 1, (function(e) {
|
|
2157
2157
|
e.Patterns = {
|
|
2158
2158
|
PATTERN000: 0,
|
|
2159
2159
|
PATTERN001: 1,
|
|
@@ -2249,10 +2249,10 @@ function So() {
|
|
|
2249
2249
|
};
|
|
2250
2250
|
})(qe)), qe;
|
|
2251
2251
|
}
|
|
2252
|
-
var
|
|
2252
|
+
var be = {}, Mt;
|
|
2253
2253
|
function On() {
|
|
2254
|
-
if (
|
|
2255
|
-
|
|
2254
|
+
if (Mt) return be;
|
|
2255
|
+
Mt = 1;
|
|
2256
2256
|
const e = ft(), t = [
|
|
2257
2257
|
// L M Q H
|
|
2258
2258
|
1,
|
|
@@ -2578,7 +2578,7 @@ function On() {
|
|
|
2578
2578
|
2040,
|
|
2579
2579
|
2430
|
|
2580
2580
|
];
|
|
2581
|
-
return
|
|
2581
|
+
return be.getBlocksCount = function(o, i) {
|
|
2582
2582
|
switch (i) {
|
|
2583
2583
|
case e.L:
|
|
2584
2584
|
return t[(o - 1) * 4 + 0];
|
|
@@ -2591,7 +2591,7 @@ function On() {
|
|
|
2591
2591
|
default:
|
|
2592
2592
|
return;
|
|
2593
2593
|
}
|
|
2594
|
-
},
|
|
2594
|
+
}, be.getTotalCodewordsCount = function(o, i) {
|
|
2595
2595
|
switch (i) {
|
|
2596
2596
|
case e.L:
|
|
2597
2597
|
return r[(o - 1) * 4 + 0];
|
|
@@ -2604,12 +2604,12 @@ function On() {
|
|
|
2604
2604
|
default:
|
|
2605
2605
|
return;
|
|
2606
2606
|
}
|
|
2607
|
-
},
|
|
2607
|
+
}, be;
|
|
2608
2608
|
}
|
|
2609
|
-
var je = {}, le = {},
|
|
2609
|
+
var je = {}, le = {}, Dt;
|
|
2610
2610
|
function Ro() {
|
|
2611
|
-
if (
|
|
2612
|
-
|
|
2611
|
+
if (Dt) return le;
|
|
2612
|
+
Dt = 1;
|
|
2613
2613
|
const e = new Uint8Array(512), t = new Uint8Array(256);
|
|
2614
2614
|
return (function() {
|
|
2615
2615
|
let n = 1;
|
|
@@ -2626,9 +2626,9 @@ function Ro() {
|
|
|
2626
2626
|
return n === 0 || o === 0 ? 0 : e[t[n] + t[o]];
|
|
2627
2627
|
}, le;
|
|
2628
2628
|
}
|
|
2629
|
-
var
|
|
2629
|
+
var kt;
|
|
2630
2630
|
function To() {
|
|
2631
|
-
return
|
|
2631
|
+
return kt || (kt = 1, (function(e) {
|
|
2632
2632
|
const t = Ro();
|
|
2633
2633
|
e.mul = function(n, o) {
|
|
2634
2634
|
const i = new Uint8Array(n.length + o.length - 1);
|
|
@@ -2655,10 +2655,10 @@ function To() {
|
|
|
2655
2655
|
};
|
|
2656
2656
|
})(je)), je;
|
|
2657
2657
|
}
|
|
2658
|
-
var He,
|
|
2658
|
+
var He, qt;
|
|
2659
2659
|
function Ao() {
|
|
2660
|
-
if (
|
|
2661
|
-
|
|
2660
|
+
if (qt) return He;
|
|
2661
|
+
qt = 1;
|
|
2662
2662
|
const e = To();
|
|
2663
2663
|
function t(r) {
|
|
2664
2664
|
this.genPoly = void 0, this.degree = r, this.degree && this.initialize(this.degree);
|
|
@@ -2678,34 +2678,34 @@ function Ao() {
|
|
|
2678
2678
|
return i;
|
|
2679
2679
|
}, He = t, He;
|
|
2680
2680
|
}
|
|
2681
|
-
var ze = {},
|
|
2681
|
+
var ze = {}, $e = {}, Ve = {}, jt;
|
|
2682
2682
|
function Ln() {
|
|
2683
|
-
return
|
|
2683
|
+
return jt || (jt = 1, Ve.isValid = function(t) {
|
|
2684
2684
|
return !isNaN(t) && t >= 1 && t <= 40;
|
|
2685
|
-
}),
|
|
2685
|
+
}), Ve;
|
|
2686
2686
|
}
|
|
2687
|
-
var
|
|
2687
|
+
var $ = {}, Ht;
|
|
2688
2688
|
function In() {
|
|
2689
|
-
if (
|
|
2690
|
-
|
|
2689
|
+
if (Ht) return $;
|
|
2690
|
+
Ht = 1;
|
|
2691
2691
|
const e = "[0-9]+", t = "[A-Z $%*+\\-./:]+";
|
|
2692
2692
|
let r = "(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";
|
|
2693
2693
|
r = r.replace(/u/g, "\\u");
|
|
2694
2694
|
const n = "(?:(?![A-Z0-9 $%*+\\-./:]|" + r + `)(?:.|[\r
|
|
2695
2695
|
]))+`;
|
|
2696
|
-
|
|
2696
|
+
$.KANJI = new RegExp(r, "g"), $.BYTE_KANJI = new RegExp("[^A-Z0-9 $%*+\\-./:]+", "g"), $.BYTE = new RegExp(n, "g"), $.NUMERIC = new RegExp(e, "g"), $.ALPHANUMERIC = new RegExp(t, "g");
|
|
2697
2697
|
const o = new RegExp("^" + r + "$"), i = new RegExp("^" + e + "$"), s = new RegExp("^[A-Z0-9 $%*+\\-./:]+$");
|
|
2698
|
-
return
|
|
2698
|
+
return $.testKanji = function(u) {
|
|
2699
2699
|
return o.test(u);
|
|
2700
|
-
},
|
|
2700
|
+
}, $.testNumeric = function(u) {
|
|
2701
2701
|
return i.test(u);
|
|
2702
|
-
},
|
|
2702
|
+
}, $.testAlphanumeric = function(u) {
|
|
2703
2703
|
return s.test(u);
|
|
2704
|
-
},
|
|
2704
|
+
}, $;
|
|
2705
2705
|
}
|
|
2706
|
-
var
|
|
2706
|
+
var zt;
|
|
2707
2707
|
function ee() {
|
|
2708
|
-
return
|
|
2708
|
+
return zt || (zt = 1, (function(e) {
|
|
2709
2709
|
const t = Ln(), r = In();
|
|
2710
2710
|
e.NUMERIC = {
|
|
2711
2711
|
id: "Numeric",
|
|
@@ -2763,7 +2763,7 @@ function ee() {
|
|
|
2763
2763
|
return s;
|
|
2764
2764
|
}
|
|
2765
2765
|
};
|
|
2766
|
-
})(
|
|
2766
|
+
})($e)), $e;
|
|
2767
2767
|
}
|
|
2768
2768
|
var $t;
|
|
2769
2769
|
function Bo() {
|
|
@@ -2797,17 +2797,17 @@ function Bo() {
|
|
|
2797
2797
|
typeof p > "u" && (p = o.BYTE);
|
|
2798
2798
|
const g = t.getSymbolTotalCodewords(y), w = r.getTotalCodewordsCount(y, d), P = (g - w) * 8;
|
|
2799
2799
|
if (p === o.MIXED) return P;
|
|
2800
|
-
const
|
|
2800
|
+
const E = P - c(p, y);
|
|
2801
2801
|
switch (p) {
|
|
2802
2802
|
case o.NUMERIC:
|
|
2803
|
-
return Math.floor(
|
|
2803
|
+
return Math.floor(E / 10 * 3);
|
|
2804
2804
|
case o.ALPHANUMERIC:
|
|
2805
|
-
return Math.floor(
|
|
2805
|
+
return Math.floor(E / 11 * 2);
|
|
2806
2806
|
case o.KANJI:
|
|
2807
|
-
return Math.floor(
|
|
2807
|
+
return Math.floor(E / 13);
|
|
2808
2808
|
case o.BYTE:
|
|
2809
2809
|
default:
|
|
2810
|
-
return Math.floor(
|
|
2810
|
+
return Math.floor(E / 8);
|
|
2811
2811
|
}
|
|
2812
2812
|
}, e.getBestVersionForData = function(y, d) {
|
|
2813
2813
|
let p;
|
|
@@ -2831,10 +2831,10 @@ function Bo() {
|
|
|
2831
2831
|
};
|
|
2832
2832
|
})(ze)), ze;
|
|
2833
2833
|
}
|
|
2834
|
-
var Je = {},
|
|
2834
|
+
var Je = {}, Vt;
|
|
2835
2835
|
function No() {
|
|
2836
|
-
if (
|
|
2837
|
-
|
|
2836
|
+
if (Vt) return Je;
|
|
2837
|
+
Vt = 1;
|
|
2838
2838
|
const e = Z(), t = 1335, r = 21522, n = e.getBCHDigit(t);
|
|
2839
2839
|
return Je.getEncodedBits = function(i, s) {
|
|
2840
2840
|
const a = i.bit << 3 | s;
|
|
@@ -2844,10 +2844,10 @@ function No() {
|
|
|
2844
2844
|
return (a << 10 | u) ^ r;
|
|
2845
2845
|
}, Je;
|
|
2846
2846
|
}
|
|
2847
|
-
var Ke = {}, We,
|
|
2847
|
+
var Ke = {}, We, Jt;
|
|
2848
2848
|
function Po() {
|
|
2849
|
-
if (
|
|
2850
|
-
|
|
2849
|
+
if (Jt) return We;
|
|
2850
|
+
Jt = 1;
|
|
2851
2851
|
const e = ee();
|
|
2852
2852
|
function t(r) {
|
|
2853
2853
|
this.mode = e.NUMERIC, this.data = r.toString();
|
|
@@ -2866,10 +2866,10 @@ function Po() {
|
|
|
2866
2866
|
a > 0 && (i = this.data.substr(o), s = parseInt(i, 10), n.put(s, a * 3 + 1));
|
|
2867
2867
|
}, We = t, We;
|
|
2868
2868
|
}
|
|
2869
|
-
var Ge,
|
|
2869
|
+
var Ge, Kt;
|
|
2870
2870
|
function Oo() {
|
|
2871
|
-
if (
|
|
2872
|
-
|
|
2871
|
+
if (Kt) return Ge;
|
|
2872
|
+
Kt = 1;
|
|
2873
2873
|
const e = ee(), t = [
|
|
2874
2874
|
"0",
|
|
2875
2875
|
"1",
|
|
@@ -2935,10 +2935,10 @@ function Oo() {
|
|
|
2935
2935
|
this.data.length % 2 && o.put(t.indexOf(this.data[i]), 6);
|
|
2936
2936
|
}, Ge = r, Ge;
|
|
2937
2937
|
}
|
|
2938
|
-
var Qe,
|
|
2938
|
+
var Qe, Wt;
|
|
2939
2939
|
function Lo() {
|
|
2940
|
-
if (
|
|
2941
|
-
|
|
2940
|
+
if (Wt) return Qe;
|
|
2941
|
+
Wt = 1;
|
|
2942
2942
|
const e = ee();
|
|
2943
2943
|
function t(r) {
|
|
2944
2944
|
this.mode = e.BYTE, typeof r == "string" ? this.data = new TextEncoder().encode(r) : this.data = new Uint8Array(r);
|
|
@@ -2954,10 +2954,10 @@ function Lo() {
|
|
|
2954
2954
|
r.put(this.data[n], 8);
|
|
2955
2955
|
}, Qe = t, Qe;
|
|
2956
2956
|
}
|
|
2957
|
-
var Ye,
|
|
2957
|
+
var Ye, Gt;
|
|
2958
2958
|
function Io() {
|
|
2959
|
-
if (
|
|
2960
|
-
|
|
2959
|
+
if (Gt) return Ye;
|
|
2960
|
+
Gt = 1;
|
|
2961
2961
|
const e = ee(), t = Z();
|
|
2962
2962
|
function r(n) {
|
|
2963
2963
|
this.mode = e.KANJI, this.data = n;
|
|
@@ -2985,9 +2985,9 @@ Make sure your charset is UTF-8`
|
|
|
2985
2985
|
}
|
|
2986
2986
|
}, Ye = r, Ye;
|
|
2987
2987
|
}
|
|
2988
|
-
var Xe = { exports: {} },
|
|
2988
|
+
var Xe = { exports: {} }, Qt;
|
|
2989
2989
|
function _o() {
|
|
2990
|
-
return
|
|
2990
|
+
return Qt || (Qt = 1, (function(e) {
|
|
2991
2991
|
var t = {
|
|
2992
2992
|
single_source_shortest_paths: function(r, n, o) {
|
|
2993
2993
|
var i = {}, s = {};
|
|
@@ -3053,17 +3053,17 @@ function _o() {
|
|
|
3053
3053
|
e.exports = t;
|
|
3054
3054
|
})(Xe)), Xe.exports;
|
|
3055
3055
|
}
|
|
3056
|
-
var
|
|
3057
|
-
function
|
|
3058
|
-
return
|
|
3056
|
+
var Yt;
|
|
3057
|
+
function Uo() {
|
|
3058
|
+
return Yt || (Yt = 1, (function(e) {
|
|
3059
3059
|
const t = ee(), r = Po(), n = Oo(), o = Lo(), i = Io(), s = In(), a = Z(), u = _o();
|
|
3060
3060
|
function c(w) {
|
|
3061
3061
|
return unescape(encodeURIComponent(w)).length;
|
|
3062
3062
|
}
|
|
3063
|
-
function l(w, P,
|
|
3063
|
+
function l(w, P, E) {
|
|
3064
3064
|
const R = [];
|
|
3065
3065
|
let _;
|
|
3066
|
-
for (; (_ = w.exec(
|
|
3066
|
+
for (; (_ = w.exec(E)) !== null; )
|
|
3067
3067
|
R.push({
|
|
3068
3068
|
data: _[0],
|
|
3069
3069
|
index: _.index,
|
|
@@ -3073,9 +3073,9 @@ function vo() {
|
|
|
3073
3073
|
return R;
|
|
3074
3074
|
}
|
|
3075
3075
|
function h(w) {
|
|
3076
|
-
const P = l(s.NUMERIC, t.NUMERIC, w),
|
|
3076
|
+
const P = l(s.NUMERIC, t.NUMERIC, w), E = l(s.ALPHANUMERIC, t.ALPHANUMERIC, w);
|
|
3077
3077
|
let R, _;
|
|
3078
|
-
return a.isKanjiModeEnabled() ? (R = l(s.BYTE, t.BYTE, w), _ = l(s.KANJI, t.KANJI, w)) : (R = l(s.BYTE_KANJI, t.BYTE, w), _ = []), P.concat(
|
|
3078
|
+
return a.isKanjiModeEnabled() ? (R = l(s.BYTE, t.BYTE, w), _ = l(s.KANJI, t.KANJI, w)) : (R = l(s.BYTE_KANJI, t.BYTE, w), _ = []), P.concat(E, R, _).sort(function(S, A) {
|
|
3079
3079
|
return S.index - A.index;
|
|
3080
3080
|
}).map(function(S) {
|
|
3081
3081
|
return {
|
|
@@ -3098,15 +3098,15 @@ function vo() {
|
|
|
3098
3098
|
}
|
|
3099
3099
|
}
|
|
3100
3100
|
function y(w) {
|
|
3101
|
-
return w.reduce(function(P,
|
|
3101
|
+
return w.reduce(function(P, E) {
|
|
3102
3102
|
const R = P.length - 1 >= 0 ? P[P.length - 1] : null;
|
|
3103
|
-
return R && R.mode ===
|
|
3103
|
+
return R && R.mode === E.mode ? (P[P.length - 1].data += E.data, P) : (P.push(E), P);
|
|
3104
3104
|
}, []);
|
|
3105
3105
|
}
|
|
3106
3106
|
function d(w) {
|
|
3107
3107
|
const P = [];
|
|
3108
|
-
for (let
|
|
3109
|
-
const R = w[
|
|
3108
|
+
for (let E = 0; E < w.length; E++) {
|
|
3109
|
+
const R = w[E];
|
|
3110
3110
|
switch (R.mode) {
|
|
3111
3111
|
case t.NUMERIC:
|
|
3112
3112
|
P.push([
|
|
@@ -3136,31 +3136,31 @@ function vo() {
|
|
|
3136
3136
|
return P;
|
|
3137
3137
|
}
|
|
3138
3138
|
function p(w, P) {
|
|
3139
|
-
const
|
|
3139
|
+
const E = {}, R = { start: {} };
|
|
3140
3140
|
let _ = ["start"];
|
|
3141
|
-
for (let
|
|
3142
|
-
const S = w[
|
|
3141
|
+
for (let b = 0; b < w.length; b++) {
|
|
3142
|
+
const S = w[b], A = [];
|
|
3143
3143
|
for (let C = 0; C < S.length; C++) {
|
|
3144
|
-
const L = S[C], B = "" +
|
|
3145
|
-
A.push(B),
|
|
3144
|
+
const L = S[C], B = "" + b + C;
|
|
3145
|
+
A.push(B), E[B] = { node: L, lastCount: 0 }, R[B] = {};
|
|
3146
3146
|
for (let N = 0; N < _.length; N++) {
|
|
3147
3147
|
const T = _[N];
|
|
3148
|
-
|
|
3148
|
+
E[T] && E[T].node.mode === L.mode ? (R[T][B] = m(E[T].lastCount + L.length, L.mode) - m(E[T].lastCount, L.mode), E[T].lastCount += L.length) : (E[T] && (E[T].lastCount = L.length), R[T][B] = m(L.length, L.mode) + 4 + t.getCharCountIndicator(L.mode, P));
|
|
3149
3149
|
}
|
|
3150
3150
|
}
|
|
3151
3151
|
_ = A;
|
|
3152
3152
|
}
|
|
3153
|
-
for (let
|
|
3154
|
-
R[_[
|
|
3155
|
-
return { map: R, table:
|
|
3153
|
+
for (let b = 0; b < _.length; b++)
|
|
3154
|
+
R[_[b]].end = 0;
|
|
3155
|
+
return { map: R, table: E };
|
|
3156
3156
|
}
|
|
3157
3157
|
function g(w, P) {
|
|
3158
|
-
let
|
|
3158
|
+
let E;
|
|
3159
3159
|
const R = t.getBestModeForData(w);
|
|
3160
|
-
if (
|
|
3161
|
-
throw new Error('"' + w + '" cannot be encoded with mode ' + t.toString(
|
|
3160
|
+
if (E = t.from(P, R), E !== t.BYTE && E.bit < R.bit)
|
|
3161
|
+
throw new Error('"' + w + '" cannot be encoded with mode ' + t.toString(E) + `.
|
|
3162
3162
|
Suggested mode is: ` + t.toString(R));
|
|
3163
|
-
switch (
|
|
3163
|
+
switch (E === t.KANJI && !a.isKanjiModeEnabled() && (E = t.BYTE), E) {
|
|
3164
3164
|
case t.NUMERIC:
|
|
3165
3165
|
return new r(w);
|
|
3166
3166
|
case t.ALPHANUMERIC:
|
|
@@ -3172,13 +3172,13 @@ function vo() {
|
|
|
3172
3172
|
}
|
|
3173
3173
|
}
|
|
3174
3174
|
e.fromArray = function(P) {
|
|
3175
|
-
return P.reduce(function(
|
|
3176
|
-
return typeof R == "string" ?
|
|
3175
|
+
return P.reduce(function(E, R) {
|
|
3176
|
+
return typeof R == "string" ? E.push(g(R, null)) : R.data && E.push(g(R.data, R.mode)), E;
|
|
3177
3177
|
}, []);
|
|
3178
|
-
}, e.fromString = function(P,
|
|
3179
|
-
const R = h(P, a.isKanjiModeEnabled()), _ = d(R),
|
|
3178
|
+
}, e.fromString = function(P, E) {
|
|
3179
|
+
const R = h(P, a.isKanjiModeEnabled()), _ = d(R), b = p(_, E), S = u.find_path(b.map, "start", "end"), A = [];
|
|
3180
3180
|
for (let C = 1; C < S.length - 1; C++)
|
|
3181
|
-
A.push(
|
|
3181
|
+
A.push(b.table[S[C]].node);
|
|
3182
3182
|
return e.fromArray(y(A));
|
|
3183
3183
|
}, e.rawSplit = function(P) {
|
|
3184
3184
|
return e.fromArray(
|
|
@@ -3187,59 +3187,59 @@ function vo() {
|
|
|
3187
3187
|
};
|
|
3188
3188
|
})(Ke)), Ke;
|
|
3189
3189
|
}
|
|
3190
|
-
var
|
|
3191
|
-
function
|
|
3192
|
-
if (
|
|
3193
|
-
|
|
3194
|
-
const e = Z(), t = ft(), r = wo(), n =
|
|
3195
|
-
function y(
|
|
3196
|
-
const A =
|
|
3190
|
+
var Xt;
|
|
3191
|
+
function vo() {
|
|
3192
|
+
if (Xt) return ve;
|
|
3193
|
+
Xt = 1;
|
|
3194
|
+
const e = Z(), t = ft(), r = wo(), n = bo(), o = Eo(), i = Co(), s = So(), a = On(), u = Ao(), c = Bo(), l = No(), h = ee(), m = Uo();
|
|
3195
|
+
function y(b, S) {
|
|
3196
|
+
const A = b.size, C = i.getPositions(S);
|
|
3197
3197
|
for (let L = 0; L < C.length; L++) {
|
|
3198
3198
|
const B = C[L][0], N = C[L][1];
|
|
3199
3199
|
for (let T = -1; T <= 7; T++)
|
|
3200
3200
|
if (!(B + T <= -1 || A <= B + T))
|
|
3201
3201
|
for (let O = -1; O <= 7; O++)
|
|
3202
|
-
N + O <= -1 || A <= N + O || (T >= 0 && T <= 6 && (O === 0 || O === 6) || O >= 0 && O <= 6 && (T === 0 || T === 6) || T >= 2 && T <= 4 && O >= 2 && O <= 4 ?
|
|
3202
|
+
N + O <= -1 || A <= N + O || (T >= 0 && T <= 6 && (O === 0 || O === 6) || O >= 0 && O <= 6 && (T === 0 || T === 6) || T >= 2 && T <= 4 && O >= 2 && O <= 4 ? b.set(B + T, N + O, !0, !0) : b.set(B + T, N + O, !1, !0));
|
|
3203
3203
|
}
|
|
3204
3204
|
}
|
|
3205
|
-
function d(
|
|
3206
|
-
const S =
|
|
3205
|
+
function d(b) {
|
|
3206
|
+
const S = b.size;
|
|
3207
3207
|
for (let A = 8; A < S - 8; A++) {
|
|
3208
3208
|
const C = A % 2 === 0;
|
|
3209
|
-
|
|
3209
|
+
b.set(A, 6, C, !0), b.set(6, A, C, !0);
|
|
3210
3210
|
}
|
|
3211
3211
|
}
|
|
3212
|
-
function p(
|
|
3212
|
+
function p(b, S) {
|
|
3213
3213
|
const A = o.getPositions(S);
|
|
3214
3214
|
for (let C = 0; C < A.length; C++) {
|
|
3215
3215
|
const L = A[C][0], B = A[C][1];
|
|
3216
3216
|
for (let N = -2; N <= 2; N++)
|
|
3217
3217
|
for (let T = -2; T <= 2; T++)
|
|
3218
|
-
N === -2 || N === 2 || T === -2 || T === 2 || N === 0 && T === 0 ?
|
|
3218
|
+
N === -2 || N === 2 || T === -2 || T === 2 || N === 0 && T === 0 ? b.set(L + N, B + T, !0, !0) : b.set(L + N, B + T, !1, !0);
|
|
3219
3219
|
}
|
|
3220
3220
|
}
|
|
3221
|
-
function g(
|
|
3222
|
-
const A =
|
|
3221
|
+
function g(b, S) {
|
|
3222
|
+
const A = b.size, C = c.getEncodedBits(S);
|
|
3223
3223
|
let L, B, N;
|
|
3224
3224
|
for (let T = 0; T < 18; T++)
|
|
3225
|
-
L = Math.floor(T / 3), B = T % 3 + A - 8 - 3, N = (C >> T & 1) === 1,
|
|
3225
|
+
L = Math.floor(T / 3), B = T % 3 + A - 8 - 3, N = (C >> T & 1) === 1, b.set(L, B, N, !0), b.set(B, L, N, !0);
|
|
3226
3226
|
}
|
|
3227
|
-
function w(
|
|
3228
|
-
const C =
|
|
3227
|
+
function w(b, S, A) {
|
|
3228
|
+
const C = b.size, L = l.getEncodedBits(S, A);
|
|
3229
3229
|
let B, N;
|
|
3230
3230
|
for (B = 0; B < 15; B++)
|
|
3231
|
-
N = (L >> B & 1) === 1, B < 6 ?
|
|
3232
|
-
|
|
3231
|
+
N = (L >> B & 1) === 1, B < 6 ? b.set(B, 8, N, !0) : B < 8 ? b.set(B + 1, 8, N, !0) : b.set(C - 15 + B, 8, N, !0), B < 8 ? b.set(8, C - B - 1, N, !0) : B < 9 ? b.set(8, 15 - B - 1 + 1, N, !0) : b.set(8, 15 - B - 1, N, !0);
|
|
3232
|
+
b.set(C - 8, 8, 1, !0);
|
|
3233
3233
|
}
|
|
3234
|
-
function P(
|
|
3235
|
-
const A =
|
|
3234
|
+
function P(b, S) {
|
|
3235
|
+
const A = b.size;
|
|
3236
3236
|
let C = -1, L = A - 1, B = 7, N = 0;
|
|
3237
3237
|
for (let T = A - 1; T > 0; T -= 2)
|
|
3238
3238
|
for (T === 6 && T--; ; ) {
|
|
3239
3239
|
for (let O = 0; O < 2; O++)
|
|
3240
|
-
if (!
|
|
3240
|
+
if (!b.isReserved(L, T - O)) {
|
|
3241
3241
|
let q = !1;
|
|
3242
|
-
N < S.length && (q = (S[N] >>> B & 1) === 1),
|
|
3242
|
+
N < S.length && (q = (S[N] >>> B & 1) === 1), b.set(L, T - O, q), B--, B === -1 && (N++, B = 7);
|
|
3243
3243
|
}
|
|
3244
3244
|
if (L += C, L < 0 || A <= L) {
|
|
3245
3245
|
L -= C, C = -C;
|
|
@@ -3247,50 +3247,50 @@ function Uo() {
|
|
|
3247
3247
|
}
|
|
3248
3248
|
}
|
|
3249
3249
|
}
|
|
3250
|
-
function b
|
|
3250
|
+
function E(b, S, A) {
|
|
3251
3251
|
const C = new r();
|
|
3252
3252
|
A.forEach(function(O) {
|
|
3253
|
-
C.put(O.mode.bit, 4), C.put(O.getLength(), h.getCharCountIndicator(O.mode,
|
|
3253
|
+
C.put(O.mode.bit, 4), C.put(O.getLength(), h.getCharCountIndicator(O.mode, b)), O.write(C);
|
|
3254
3254
|
});
|
|
3255
|
-
const L = e.getSymbolTotalCodewords(
|
|
3255
|
+
const L = e.getSymbolTotalCodewords(b), B = a.getTotalCodewordsCount(b, S), N = (L - B) * 8;
|
|
3256
3256
|
for (C.getLengthInBits() + 4 <= N && C.put(0, 4); C.getLengthInBits() % 8 !== 0; )
|
|
3257
3257
|
C.putBit(0);
|
|
3258
3258
|
const T = (N - C.getLengthInBits()) / 8;
|
|
3259
3259
|
for (let O = 0; O < T; O++)
|
|
3260
3260
|
C.put(O % 2 ? 17 : 236, 8);
|
|
3261
|
-
return R(C,
|
|
3261
|
+
return R(C, b, S);
|
|
3262
3262
|
}
|
|
3263
|
-
function R(
|
|
3264
|
-
const C = e.getSymbolTotalCodewords(S), L = a.getTotalCodewordsCount(S, A), B = C - L, N = a.getBlocksCount(S, A), T = C % N, O = N - T, q = Math.floor(C / N),
|
|
3263
|
+
function R(b, S, A) {
|
|
3264
|
+
const C = e.getSymbolTotalCodewords(S), L = a.getTotalCodewordsCount(S, A), B = C - L, N = a.getBlocksCount(S, A), T = C % N, O = N - T, q = Math.floor(C / N), v = Math.floor(B / N), me = v + 1, j = q - v, ye = new u(j);
|
|
3265
3265
|
let ue = 0;
|
|
3266
|
-
const k = new Array(N),
|
|
3266
|
+
const k = new Array(N), V = new Array(N);
|
|
3267
3267
|
let G = 0;
|
|
3268
|
-
const te = new Uint8Array(
|
|
3268
|
+
const te = new Uint8Array(b.buffer);
|
|
3269
3269
|
for (let re = 0; re < N; re++) {
|
|
3270
|
-
const Oe = re < O ?
|
|
3271
|
-
k[re] = te.slice(ue, ue + Oe),
|
|
3270
|
+
const Oe = re < O ? v : me;
|
|
3271
|
+
k[re] = te.slice(ue, ue + Oe), V[re] = ye.encode(k[re]), ue += Oe, G = Math.max(G, Oe);
|
|
3272
3272
|
}
|
|
3273
3273
|
const ne = new Uint8Array(C);
|
|
3274
|
-
let
|
|
3274
|
+
let dt = 0, J, K;
|
|
3275
3275
|
for (J = 0; J < G; J++)
|
|
3276
3276
|
for (K = 0; K < N; K++)
|
|
3277
|
-
J < k[K].length && (ne[
|
|
3277
|
+
J < k[K].length && (ne[dt++] = k[K][J]);
|
|
3278
3278
|
for (J = 0; J < j; J++)
|
|
3279
3279
|
for (K = 0; K < N; K++)
|
|
3280
|
-
ne[
|
|
3280
|
+
ne[dt++] = V[K][J];
|
|
3281
3281
|
return ne;
|
|
3282
3282
|
}
|
|
3283
|
-
function _(
|
|
3283
|
+
function _(b, S, A, C) {
|
|
3284
3284
|
let L;
|
|
3285
|
-
if (Array.isArray(
|
|
3286
|
-
L = m.fromArray(
|
|
3287
|
-
else if (typeof
|
|
3285
|
+
if (Array.isArray(b))
|
|
3286
|
+
L = m.fromArray(b);
|
|
3287
|
+
else if (typeof b == "string") {
|
|
3288
3288
|
let q = S;
|
|
3289
3289
|
if (!q) {
|
|
3290
|
-
const
|
|
3291
|
-
q = c.getBestVersionForData(
|
|
3290
|
+
const v = m.rawSplit(b);
|
|
3291
|
+
q = c.getBestVersionForData(v, A);
|
|
3292
3292
|
}
|
|
3293
|
-
L = m.fromString(
|
|
3293
|
+
L = m.fromString(b, q || 40);
|
|
3294
3294
|
} else
|
|
3295
3295
|
throw new Error("Invalid data");
|
|
3296
3296
|
const B = c.getBestVersionForData(L, A);
|
|
@@ -3305,7 +3305,7 @@ The chosen QR Code version cannot contain this amount of data.
|
|
|
3305
3305
|
Minimum version required to store current data is: ` + B + `.
|
|
3306
3306
|
`
|
|
3307
3307
|
);
|
|
3308
|
-
const N =
|
|
3308
|
+
const N = E(S, A, L), T = e.getSymbolSize(S), O = new n(T);
|
|
3309
3309
|
return y(O, S), d(O), p(O, S), w(O, A, 0), S >= 7 && g(O, S), P(O, N), isNaN(C) && (C = s.getBestMask(
|
|
3310
3310
|
O,
|
|
3311
3311
|
w.bind(null, O, A)
|
|
@@ -3317,16 +3317,16 @@ Minimum version required to store current data is: ` + B + `.
|
|
|
3317
3317
|
segments: L
|
|
3318
3318
|
};
|
|
3319
3319
|
}
|
|
3320
|
-
return
|
|
3320
|
+
return ve.create = function(S, A) {
|
|
3321
3321
|
if (typeof S > "u" || S === "")
|
|
3322
3322
|
throw new Error("No input text");
|
|
3323
3323
|
let C = t.M, L, B;
|
|
3324
3324
|
return typeof A < "u" && (C = t.from(A.errorCorrectionLevel, t.M), L = c.from(A.version), B = s.from(A.maskPattern), A.toSJISFunc && e.setToSJISFunction(A.toSJISFunc)), _(S, L, C, B);
|
|
3325
|
-
},
|
|
3325
|
+
}, ve;
|
|
3326
3326
|
}
|
|
3327
|
-
var Ze = {}, et = {},
|
|
3327
|
+
var Ze = {}, et = {}, Zt;
|
|
3328
3328
|
function _n() {
|
|
3329
|
-
return
|
|
3329
|
+
return Zt || (Zt = 1, (function(e) {
|
|
3330
3330
|
function t(r) {
|
|
3331
3331
|
if (typeof r == "number" && (r = r.toString()), typeof r != "string")
|
|
3332
3332
|
throw new Error("Color should be defined as hex string");
|
|
@@ -3378,9 +3378,9 @@ function _n() {
|
|
|
3378
3378
|
};
|
|
3379
3379
|
})(et)), et;
|
|
3380
3380
|
}
|
|
3381
|
-
var
|
|
3381
|
+
var en;
|
|
3382
3382
|
function xo() {
|
|
3383
|
-
return
|
|
3383
|
+
return en || (en = 1, (function(e) {
|
|
3384
3384
|
const t = _n();
|
|
3385
3385
|
function r(o, i, s) {
|
|
3386
3386
|
o.clearRect(0, 0, i.width, i.height), i.style || (i.style = {}), i.height = s, i.width = s, i.style.height = s + "px", i.style.width = s + "px";
|
|
@@ -3405,10 +3405,10 @@ function xo() {
|
|
|
3405
3405
|
};
|
|
3406
3406
|
})(Ze)), Ze;
|
|
3407
3407
|
}
|
|
3408
|
-
var tt = {},
|
|
3408
|
+
var tt = {}, tn;
|
|
3409
3409
|
function Fo() {
|
|
3410
|
-
if (
|
|
3411
|
-
|
|
3410
|
+
if (tn) return tt;
|
|
3411
|
+
tn = 1;
|
|
3412
3412
|
const e = _n();
|
|
3413
3413
|
function t(o, i) {
|
|
3414
3414
|
const s = o.a / 255, a = i + '="' + o.hex + '"';
|
|
@@ -3432,11 +3432,11 @@ function Fo() {
|
|
|
3432
3432
|
return typeof a == "function" && a(null, g), g;
|
|
3433
3433
|
}, tt;
|
|
3434
3434
|
}
|
|
3435
|
-
var
|
|
3435
|
+
var nn;
|
|
3436
3436
|
function Mo() {
|
|
3437
|
-
if (
|
|
3438
|
-
|
|
3439
|
-
const e = yo(), t =
|
|
3437
|
+
if (nn) return oe;
|
|
3438
|
+
nn = 1;
|
|
3439
|
+
const e = yo(), t = vo(), r = xo(), n = Fo();
|
|
3440
3440
|
function o(i, s, a, u, c) {
|
|
3441
3441
|
const l = [].slice.call(arguments, 1), h = l.length, m = typeof l[h - 1] == "function";
|
|
3442
3442
|
if (!m && !e())
|
|
@@ -3469,7 +3469,35 @@ function Mo() {
|
|
|
3469
3469
|
}), oe;
|
|
3470
3470
|
}
|
|
3471
3471
|
var Do = Mo();
|
|
3472
|
-
|
|
3472
|
+
const fe = rn(), Un = U.create({
|
|
3473
|
+
baseURL: fe.baseUrl
|
|
3474
|
+
});
|
|
3475
|
+
async function ko(e = {}) {
|
|
3476
|
+
return (await Un.post(fe.createEndpoint, e, {
|
|
3477
|
+
withCredentials: !0
|
|
3478
|
+
})).data;
|
|
3479
|
+
}
|
|
3480
|
+
function qo(e = () => {
|
|
3481
|
+
}, t = () => {
|
|
3482
|
+
}) {
|
|
3483
|
+
const r = new URL(fe.authEventEndpoint, fe.baseUrl), n = new EventSource(r, {
|
|
3484
|
+
withCredentials: !0
|
|
3485
|
+
});
|
|
3486
|
+
return n.addEventListener("auth-success", async (o) => {
|
|
3487
|
+
try {
|
|
3488
|
+
await Un.post(fe.authConfirmEndpoint, null, {
|
|
3489
|
+
withCredentials: !0
|
|
3490
|
+
}), e();
|
|
3491
|
+
} catch (i) {
|
|
3492
|
+
console.error(i), t(i);
|
|
3493
|
+
} finally {
|
|
3494
|
+
n.close();
|
|
3495
|
+
}
|
|
3496
|
+
}), n.onerror = (o) => {
|
|
3497
|
+
console.error("EventSource failed:", o), n.close();
|
|
3498
|
+
}, n;
|
|
3499
|
+
}
|
|
3500
|
+
class jo {
|
|
3473
3501
|
constructor() {
|
|
3474
3502
|
x(this, "overlay", null);
|
|
3475
3503
|
x(this, "isOpen", !1);
|
|
@@ -3530,7 +3558,7 @@ class ko {
|
|
|
3530
3558
|
renderSuccessState(t) {
|
|
3531
3559
|
this.loader.style.display = "none", this.errorContainer.style.display = "none", this.qrContainer.style.display = "flex", this.separator.style.display = "block", this.loginButton.style.display = "block";
|
|
3532
3560
|
const r = t.links[0].link;
|
|
3533
|
-
this.generateQR(this.qrContainer, r), this.loginButton.onclick = () => window.open(r), this.authEvent =
|
|
3561
|
+
this.generateQR(this.qrContainer, r), this.loginButton.onclick = () => window.open(r), this.authEvent = qo(() => {
|
|
3534
3562
|
this.close(), this.resolvePromise();
|
|
3535
3563
|
}, (n) => this.renderErrorState(n)), t.validUntil ? (this.timerContainer.style.display = "block", this.startTimer(t.validUntil)) : this.timerContainer.style.display = "none";
|
|
3536
3564
|
}
|
|
@@ -3562,7 +3590,7 @@ class ko {
|
|
|
3562
3590
|
if (this.requestData) {
|
|
3563
3591
|
this.setLoadingState();
|
|
3564
3592
|
try {
|
|
3565
|
-
const t = await
|
|
3593
|
+
const t = await ko(this.requestData);
|
|
3566
3594
|
this.renderSuccessState(t);
|
|
3567
3595
|
} catch (t) {
|
|
3568
3596
|
this.renderErrorState(t);
|
|
@@ -3575,50 +3603,28 @@ class ko {
|
|
|
3575
3603
|
}, 400));
|
|
3576
3604
|
}
|
|
3577
3605
|
}
|
|
3578
|
-
|
|
3579
|
-
const
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
|
|
3584
|
-
}
|
|
3585
|
-
|
|
3586
|
-
dt.close();
|
|
3587
|
-
}
|
|
3588
|
-
async function qo(e = {}) {
|
|
3589
|
-
return (await vn.post(fe.createEndpoint, e, {
|
|
3590
|
-
withCredentials: !0
|
|
3591
|
-
})).data;
|
|
3606
|
+
zo();
|
|
3607
|
+
const Ho = rn();
|
|
3608
|
+
U.create({
|
|
3609
|
+
baseURL: Ho.baseUrl
|
|
3610
|
+
});
|
|
3611
|
+
const vn = new jo();
|
|
3612
|
+
async function li(e = {}) {
|
|
3613
|
+
return vn.show(e);
|
|
3592
3614
|
}
|
|
3593
|
-
function
|
|
3594
|
-
|
|
3595
|
-
const r = new URL(fe.authEventEndpoint, fe.baseUrl), n = new EventSource(r, {
|
|
3596
|
-
withCredentials: !0
|
|
3597
|
-
});
|
|
3598
|
-
return n.addEventListener("auth-success", async (o) => {
|
|
3599
|
-
try {
|
|
3600
|
-
await vn.post(fe.authConfirmEndpoint, null, {
|
|
3601
|
-
withCredentials: !0
|
|
3602
|
-
}), e();
|
|
3603
|
-
} catch (i) {
|
|
3604
|
-
console.error(i), t(i);
|
|
3605
|
-
} finally {
|
|
3606
|
-
n.close();
|
|
3607
|
-
}
|
|
3608
|
-
}), n.onerror = (o) => {
|
|
3609
|
-
console.error("EventSource failed:", o), n.close();
|
|
3610
|
-
}, n;
|
|
3615
|
+
function fi() {
|
|
3616
|
+
vn.close();
|
|
3611
3617
|
}
|
|
3612
|
-
function
|
|
3618
|
+
function zo() {
|
|
3613
3619
|
if (document.getElementById("oauth0-js-lib-styles")) return;
|
|
3614
3620
|
const e = document.createElement("style");
|
|
3615
3621
|
e.id = "oauth0-js-lib-styles", e.innerHTML = mo, document.head.appendChild(e);
|
|
3616
3622
|
}
|
|
3617
3623
|
export {
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3624
|
+
fi as closeQrLogin,
|
|
3625
|
+
qo as createAuthEvent,
|
|
3626
|
+
ko as createAuthSession,
|
|
3627
|
+
rn as getConfig,
|
|
3622
3628
|
Vo as setConfig,
|
|
3623
|
-
|
|
3629
|
+
li as showQrLogin
|
|
3624
3630
|
};
|