@wral/report-it 0.1.0 → 0.1.2
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var
|
|
1
|
+
var hn = /* @__PURE__ */ (function() {
|
|
2
2
|
function n(t) {
|
|
3
3
|
var r = t || {}, i = r.ValidationData, s = r.Username, o = r.Password, l = r.AuthParameters, h = r.ClientMetadata;
|
|
4
4
|
this.validationData = i || {}, this.authParameters = l || {}, this.clientMetadata = h || {}, this.username = s, this.password = o;
|
|
@@ -41,56 +41,56 @@ function Ut(n) {
|
|
|
41
41
|
}), t;
|
|
42
42
|
}
|
|
43
43
|
var rt = {}, ye = {}, zt;
|
|
44
|
-
function
|
|
44
|
+
function fn() {
|
|
45
45
|
if (zt) return ye;
|
|
46
46
|
zt = 1, ye.byteLength = l, ye.toByteArray = d, ye.fromByteArray = v;
|
|
47
47
|
for (var n = [], e = [], t = typeof Uint8Array < "u" ? Uint8Array : Array, r = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", i = 0, s = r.length; i < s; ++i)
|
|
48
48
|
n[i] = r[i], e[r.charCodeAt(i)] = i;
|
|
49
49
|
e[45] = 62, e[95] = 63;
|
|
50
50
|
function o(y) {
|
|
51
|
-
var
|
|
52
|
-
if (
|
|
51
|
+
var b = y.length;
|
|
52
|
+
if (b % 4 > 0)
|
|
53
53
|
throw new Error("Invalid string. Length must be a multiple of 4");
|
|
54
54
|
var _ = y.indexOf("=");
|
|
55
|
-
_ === -1 && (_ =
|
|
56
|
-
var E = _ ===
|
|
55
|
+
_ === -1 && (_ = b);
|
|
56
|
+
var E = _ === b ? 0 : 4 - _ % 4;
|
|
57
57
|
return [_, E];
|
|
58
58
|
}
|
|
59
59
|
function l(y) {
|
|
60
|
-
var
|
|
60
|
+
var b = o(y), _ = b[0], E = b[1];
|
|
61
61
|
return (_ + E) * 3 / 4 - E;
|
|
62
62
|
}
|
|
63
|
-
function h(y,
|
|
64
|
-
return (
|
|
63
|
+
function h(y, b, _) {
|
|
64
|
+
return (b + _) * 3 / 4 - _;
|
|
65
65
|
}
|
|
66
66
|
function d(y) {
|
|
67
|
-
var
|
|
67
|
+
var b, _ = o(y), E = _[0], x = _[1], U = new t(h(y, E, x)), P = 0, B = x > 0 ? E - 4 : E, F;
|
|
68
68
|
for (F = 0; F < B; F += 4)
|
|
69
|
-
|
|
70
|
-
return x === 2 && (
|
|
69
|
+
b = e[y.charCodeAt(F)] << 18 | e[y.charCodeAt(F + 1)] << 12 | e[y.charCodeAt(F + 2)] << 6 | e[y.charCodeAt(F + 3)], U[P++] = b >> 16 & 255, U[P++] = b >> 8 & 255, U[P++] = b & 255;
|
|
70
|
+
return x === 2 && (b = e[y.charCodeAt(F)] << 2 | e[y.charCodeAt(F + 1)] >> 4, U[P++] = b & 255), x === 1 && (b = e[y.charCodeAt(F)] << 10 | e[y.charCodeAt(F + 1)] << 4 | e[y.charCodeAt(F + 2)] >> 2, U[P++] = b >> 8 & 255, U[P++] = b & 255), U;
|
|
71
71
|
}
|
|
72
72
|
function p(y) {
|
|
73
73
|
return n[y >> 18 & 63] + n[y >> 12 & 63] + n[y >> 6 & 63] + n[y & 63];
|
|
74
74
|
}
|
|
75
|
-
function m(y,
|
|
76
|
-
for (var E, x = [], U =
|
|
75
|
+
function m(y, b, _) {
|
|
76
|
+
for (var E, x = [], U = b; U < _; U += 3)
|
|
77
77
|
E = (y[U] << 16 & 16711680) + (y[U + 1] << 8 & 65280) + (y[U + 2] & 255), x.push(p(E));
|
|
78
78
|
return x.join("");
|
|
79
79
|
}
|
|
80
80
|
function v(y) {
|
|
81
|
-
for (var
|
|
81
|
+
for (var b, _ = y.length, E = _ % 3, x = [], U = 16383, P = 0, B = _ - E; P < B; P += U)
|
|
82
82
|
x.push(m(y, P, P + U > B ? B : P + U));
|
|
83
|
-
return E === 1 ? (
|
|
84
|
-
n[
|
|
85
|
-
)) : E === 2 && (
|
|
86
|
-
n[
|
|
83
|
+
return E === 1 ? (b = y[_ - 1], x.push(
|
|
84
|
+
n[b >> 2] + n[b << 4 & 63] + "=="
|
|
85
|
+
)) : E === 2 && (b = (y[_ - 2] << 8) + y[_ - 1], x.push(
|
|
86
|
+
n[b >> 10] + n[b >> 4 & 63] + n[b << 2 & 63] + "="
|
|
87
87
|
)), x.join("");
|
|
88
88
|
}
|
|
89
89
|
return ye;
|
|
90
90
|
}
|
|
91
91
|
var Ke = {};
|
|
92
92
|
var Wt;
|
|
93
|
-
function
|
|
93
|
+
function dn() {
|
|
94
94
|
return Wt || (Wt = 1, Ke.read = function(n, e, t, r, i) {
|
|
95
95
|
var s, o, l = i * 8 - r - 1, h = (1 << l) - 1, d = h >> 1, p = -7, m = t ? i - 1 : 0, v = t ? -1 : 1, y = n[e + m];
|
|
96
96
|
for (m += v, s = y & (1 << -p) - 1, y >>= -p, p += l; p > 0; s = s * 256 + n[e + m], m += v, p -= 8)
|
|
@@ -106,16 +106,16 @@ function fn() {
|
|
|
106
106
|
}
|
|
107
107
|
return (y ? -1 : 1) * o * Math.pow(2, s - r);
|
|
108
108
|
}, Ke.write = function(n, e, t, r, i, s) {
|
|
109
|
-
var o, l, h, d = s * 8 - i - 1, p = (1 << d) - 1, m = p >> 1, v = i === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, y = r ? 0 : s - 1,
|
|
110
|
-
for (e = Math.abs(e), isNaN(e) || e === 1 / 0 ? (l = isNaN(e) ? 1 : 0, o = p) : (o = Math.floor(Math.log(e) / Math.LN2), e * (h = Math.pow(2, -o)) < 1 && (o--, h *= 2), o + m >= 1 ? e += v / h : e += v * Math.pow(2, 1 - m), e * h >= 2 && (o++, h /= 2), o + m >= p ? (l = 0, o = p) : o + m >= 1 ? (l = (e * h - 1) * Math.pow(2, i), o = o + m) : (l = e * Math.pow(2, m - 1) * Math.pow(2, i), o = 0)); i >= 8; n[t + y] = l & 255, y +=
|
|
109
|
+
var o, l, h, d = s * 8 - i - 1, p = (1 << d) - 1, m = p >> 1, v = i === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, y = r ? 0 : s - 1, b = r ? 1 : -1, _ = e < 0 || e === 0 && 1 / e < 0 ? 1 : 0;
|
|
110
|
+
for (e = Math.abs(e), isNaN(e) || e === 1 / 0 ? (l = isNaN(e) ? 1 : 0, o = p) : (o = Math.floor(Math.log(e) / Math.LN2), e * (h = Math.pow(2, -o)) < 1 && (o--, h *= 2), o + m >= 1 ? e += v / h : e += v * Math.pow(2, 1 - m), e * h >= 2 && (o++, h /= 2), o + m >= p ? (l = 0, o = p) : o + m >= 1 ? (l = (e * h - 1) * Math.pow(2, i), o = o + m) : (l = e * Math.pow(2, m - 1) * Math.pow(2, i), o = 0)); i >= 8; n[t + y] = l & 255, y += b, l /= 256, i -= 8)
|
|
111
111
|
;
|
|
112
|
-
for (o = o << i | l, d += i; d > 0; n[t + y] = o & 255, y +=
|
|
112
|
+
for (o = o << i | l, d += i; d > 0; n[t + y] = o & 255, y += b, o /= 256, d -= 8)
|
|
113
113
|
;
|
|
114
|
-
n[t + y -
|
|
114
|
+
n[t + y - b] |= _ * 128;
|
|
115
115
|
}), Ke;
|
|
116
116
|
}
|
|
117
117
|
var nt, Yt;
|
|
118
|
-
function
|
|
118
|
+
function pn() {
|
|
119
119
|
if (Yt) return nt;
|
|
120
120
|
Yt = 1;
|
|
121
121
|
var n = {}.toString;
|
|
@@ -124,9 +124,9 @@ function dn() {
|
|
|
124
124
|
}, nt;
|
|
125
125
|
}
|
|
126
126
|
var Gt;
|
|
127
|
-
function
|
|
127
|
+
function gn() {
|
|
128
128
|
return Gt || (Gt = 1, (function(n) {
|
|
129
|
-
var e =
|
|
129
|
+
var e = fn(), t = dn(), r = pn();
|
|
130
130
|
n.Buffer = l, n.SlowBuffer = x, n.INSPECT_MAX_BYTES = 50, l.TYPED_ARRAY_SUPPORT = globalThis.TYPED_ARRAY_SUPPORT !== void 0 ? globalThis.TYPED_ARRAY_SUPPORT : i(), n.kMaxLength = s();
|
|
131
131
|
function i() {
|
|
132
132
|
try {
|
|
@@ -166,7 +166,7 @@ function pn() {
|
|
|
166
166
|
function h(c, a, u, f) {
|
|
167
167
|
if (typeof a == "number")
|
|
168
168
|
throw new TypeError('"value" argument must not be a number');
|
|
169
|
-
return typeof ArrayBuffer < "u" && a instanceof ArrayBuffer ?
|
|
169
|
+
return typeof ArrayBuffer < "u" && a instanceof ArrayBuffer ? b(c, a, u, f) : typeof a == "string" ? v(c, a, u) : _(c, a);
|
|
170
170
|
}
|
|
171
171
|
l.from = function(c, a, u) {
|
|
172
172
|
return h(null, c, a, u);
|
|
@@ -212,7 +212,7 @@ function pn() {
|
|
|
212
212
|
c[f] = a[f] & 255;
|
|
213
213
|
return c;
|
|
214
214
|
}
|
|
215
|
-
function
|
|
215
|
+
function b(c, a, u, f) {
|
|
216
216
|
if (a.byteLength, u < 0 || a.byteLength < u)
|
|
217
217
|
throw new RangeError("'offset' is out of bounds");
|
|
218
218
|
if (a.byteLength < u + (f || 0))
|
|
@@ -226,7 +226,7 @@ function pn() {
|
|
|
226
226
|
}
|
|
227
227
|
if (a) {
|
|
228
228
|
if (typeof ArrayBuffer < "u" && a.buffer instanceof ArrayBuffer || "length" in a)
|
|
229
|
-
return typeof a.length != "number" ||
|
|
229
|
+
return typeof a.length != "number" || cn(a.length) ? o(c, 0) : y(c, a);
|
|
230
230
|
if (a.type === "Buffer" && r(a.data))
|
|
231
231
|
return y(c, a.data);
|
|
232
232
|
}
|
|
@@ -246,7 +246,7 @@ function pn() {
|
|
|
246
246
|
if (!l.isBuffer(a) || !l.isBuffer(u))
|
|
247
247
|
throw new TypeError("Arguments must be Buffers");
|
|
248
248
|
if (a === u) return 0;
|
|
249
|
-
for (var f = a.length, g = u.length, w = 0,
|
|
249
|
+
for (var f = a.length, g = u.length, w = 0, S = Math.min(f, g); w < S; ++w)
|
|
250
250
|
if (a[w] !== u[w]) {
|
|
251
251
|
f = a[w], g = u[w];
|
|
252
252
|
break;
|
|
@@ -280,10 +280,10 @@ function pn() {
|
|
|
280
280
|
u += a[f].length;
|
|
281
281
|
var g = l.allocUnsafe(u), w = 0;
|
|
282
282
|
for (f = 0; f < a.length; ++f) {
|
|
283
|
-
var
|
|
284
|
-
if (!l.isBuffer(
|
|
283
|
+
var S = a[f];
|
|
284
|
+
if (!l.isBuffer(S))
|
|
285
285
|
throw new TypeError('"list" argument must be an Array of Buffers');
|
|
286
|
-
|
|
286
|
+
S.copy(g, w), w += S.length;
|
|
287
287
|
}
|
|
288
288
|
return g;
|
|
289
289
|
};
|
|
@@ -327,22 +327,22 @@ function pn() {
|
|
|
327
327
|
for (c || (c = "utf8"); ; )
|
|
328
328
|
switch (c) {
|
|
329
329
|
case "hex":
|
|
330
|
-
return
|
|
330
|
+
return tn(this, a, u);
|
|
331
331
|
case "utf8":
|
|
332
332
|
case "utf-8":
|
|
333
333
|
return ve(this, a, u);
|
|
334
334
|
case "ascii":
|
|
335
|
-
return
|
|
335
|
+
return Qr(this, a, u);
|
|
336
336
|
case "latin1":
|
|
337
337
|
case "binary":
|
|
338
|
-
return
|
|
338
|
+
return en(this, a, u);
|
|
339
339
|
case "base64":
|
|
340
340
|
return le(this, a, u);
|
|
341
341
|
case "ucs2":
|
|
342
342
|
case "ucs-2":
|
|
343
343
|
case "utf16le":
|
|
344
344
|
case "utf-16le":
|
|
345
|
-
return
|
|
345
|
+
return rn(this, a, u);
|
|
346
346
|
default:
|
|
347
347
|
if (f) throw new TypeError("Unknown encoding: " + c);
|
|
348
348
|
c = (c + "").toLowerCase(), f = !0;
|
|
@@ -395,12 +395,12 @@ function pn() {
|
|
|
395
395
|
if (u >= f)
|
|
396
396
|
return 1;
|
|
397
397
|
if (u >>>= 0, f >>>= 0, g >>>= 0, w >>>= 0, this === a) return 0;
|
|
398
|
-
for (var
|
|
398
|
+
for (var S = w - g, I = f - u, D = Math.min(S, I), k = this.slice(g, w), O = a.slice(u, f), $ = 0; $ < D; ++$)
|
|
399
399
|
if (k[$] !== O[$]) {
|
|
400
|
-
|
|
400
|
+
S = k[$], I = O[$];
|
|
401
401
|
break;
|
|
402
402
|
}
|
|
403
|
-
return
|
|
403
|
+
return S < I ? -1 : I < S ? 1 : 0;
|
|
404
404
|
};
|
|
405
405
|
function F(c, a, u, f, g) {
|
|
406
406
|
if (c.length === 0) return -1;
|
|
@@ -417,11 +417,11 @@ function pn() {
|
|
|
417
417
|
throw new TypeError("val must be string, number or Buffer");
|
|
418
418
|
}
|
|
419
419
|
function X(c, a, u, f, g) {
|
|
420
|
-
var w = 1,
|
|
420
|
+
var w = 1, S = c.length, I = a.length;
|
|
421
421
|
if (f !== void 0 && (f = String(f).toLowerCase(), f === "ucs2" || f === "ucs-2" || f === "utf16le" || f === "utf-16le")) {
|
|
422
422
|
if (c.length < 2 || a.length < 2)
|
|
423
423
|
return -1;
|
|
424
|
-
w = 2,
|
|
424
|
+
w = 2, S /= 2, I /= 2, u /= 2;
|
|
425
425
|
}
|
|
426
426
|
function D(jt, Ht) {
|
|
427
427
|
return w === 1 ? jt[Ht] : jt.readUInt16BE(Ht * w);
|
|
@@ -429,13 +429,13 @@ function pn() {
|
|
|
429
429
|
var k;
|
|
430
430
|
if (g) {
|
|
431
431
|
var O = -1;
|
|
432
|
-
for (k = u; k <
|
|
432
|
+
for (k = u; k < S; k++)
|
|
433
433
|
if (D(c, k) === D(a, O === -1 ? 0 : k - O)) {
|
|
434
434
|
if (O === -1 && (O = k), k - O + 1 === I) return O * w;
|
|
435
435
|
} else
|
|
436
436
|
O !== -1 && (k -= k - O), O = -1;
|
|
437
437
|
} else
|
|
438
|
-
for (u + I >
|
|
438
|
+
for (u + I > S && (u = S - I), k = u; k >= 0; k--) {
|
|
439
439
|
for (var $ = !0, Le = 0; Le < I; Le++)
|
|
440
440
|
if (D(c, k + Le) !== D(a, Le)) {
|
|
441
441
|
$ = !1;
|
|
@@ -459,18 +459,18 @@ function pn() {
|
|
|
459
459
|
var w = a.length;
|
|
460
460
|
if (w % 2 !== 0) throw new TypeError("Invalid hex string");
|
|
461
461
|
f > w / 2 && (f = w / 2);
|
|
462
|
-
for (var
|
|
463
|
-
var I = parseInt(a.substr(
|
|
464
|
-
if (isNaN(I)) return
|
|
465
|
-
c[u +
|
|
462
|
+
for (var S = 0; S < f; ++S) {
|
|
463
|
+
var I = parseInt(a.substr(S * 2, 2), 16);
|
|
464
|
+
if (isNaN(I)) return S;
|
|
465
|
+
c[u + S] = I;
|
|
466
466
|
}
|
|
467
|
-
return
|
|
467
|
+
return S;
|
|
468
468
|
}
|
|
469
469
|
function G(c, a, u, f) {
|
|
470
470
|
return qe(Ne(a, c.length - u), c, u, f);
|
|
471
471
|
}
|
|
472
472
|
function K(c, a, u, f) {
|
|
473
|
-
return qe(
|
|
473
|
+
return qe(un(a), c, u, f);
|
|
474
474
|
}
|
|
475
475
|
function Q(c, a, u, f) {
|
|
476
476
|
return K(c, a, u, f);
|
|
@@ -479,7 +479,7 @@ function pn() {
|
|
|
479
479
|
return qe(Vt(a), c, u, f);
|
|
480
480
|
}
|
|
481
481
|
function me(c, a, u, f) {
|
|
482
|
-
return qe(
|
|
482
|
+
return qe(ln(a, c.length - u), c, u, f);
|
|
483
483
|
}
|
|
484
484
|
l.prototype.write = function(a, u, f, g) {
|
|
485
485
|
if (u === void 0)
|
|
@@ -496,7 +496,7 @@ function pn() {
|
|
|
496
496
|
if ((f === void 0 || f > w) && (f = w), a.length > 0 && (f < 0 || u < 0) || u > this.length)
|
|
497
497
|
throw new RangeError("Attempt to write outside buffer bounds");
|
|
498
498
|
g || (g = "utf8");
|
|
499
|
-
for (var
|
|
499
|
+
for (var S = !1; ; )
|
|
500
500
|
switch (g) {
|
|
501
501
|
case "hex":
|
|
502
502
|
return ge(this, a, u, f);
|
|
@@ -516,8 +516,8 @@ function pn() {
|
|
|
516
516
|
case "utf-16le":
|
|
517
517
|
return me(this, a, u, f);
|
|
518
518
|
default:
|
|
519
|
-
if (
|
|
520
|
-
g = ("" + g).toLowerCase(),
|
|
519
|
+
if (S) throw new TypeError("Unknown encoding: " + g);
|
|
520
|
+
g = ("" + g).toLowerCase(), S = !0;
|
|
521
521
|
}
|
|
522
522
|
}, l.prototype.toJSON = function() {
|
|
523
523
|
return {
|
|
@@ -531,24 +531,24 @@ function pn() {
|
|
|
531
531
|
function ve(c, a, u) {
|
|
532
532
|
u = Math.min(c.length, u);
|
|
533
533
|
for (var f = [], g = a; g < u; ) {
|
|
534
|
-
var w = c[g],
|
|
534
|
+
var w = c[g], S = null, I = w > 239 ? 4 : w > 223 ? 3 : w > 191 ? 2 : 1;
|
|
535
535
|
if (g + I <= u) {
|
|
536
536
|
var D, k, O, $;
|
|
537
537
|
switch (I) {
|
|
538
538
|
case 1:
|
|
539
|
-
w < 128 && (
|
|
539
|
+
w < 128 && (S = w);
|
|
540
540
|
break;
|
|
541
541
|
case 2:
|
|
542
|
-
D = c[g + 1], (D & 192) === 128 && ($ = (w & 31) << 6 | D & 63, $ > 127 && (
|
|
542
|
+
D = c[g + 1], (D & 192) === 128 && ($ = (w & 31) << 6 | D & 63, $ > 127 && (S = $));
|
|
543
543
|
break;
|
|
544
544
|
case 3:
|
|
545
|
-
D = c[g + 1], k = c[g + 2], (D & 192) === 128 && (k & 192) === 128 && ($ = (w & 15) << 12 | (D & 63) << 6 | k & 63, $ > 2047 && ($ < 55296 || $ > 57343) && (
|
|
545
|
+
D = c[g + 1], k = c[g + 2], (D & 192) === 128 && (k & 192) === 128 && ($ = (w & 15) << 12 | (D & 63) << 6 | k & 63, $ > 2047 && ($ < 55296 || $ > 57343) && (S = $));
|
|
546
546
|
break;
|
|
547
547
|
case 4:
|
|
548
|
-
D = c[g + 1], k = c[g + 2], O = c[g + 3], (D & 192) === 128 && (k & 192) === 128 && (O & 192) === 128 && ($ = (w & 15) << 18 | (D & 63) << 12 | (k & 63) << 6 | O & 63, $ > 65535 && $ < 1114112 && (
|
|
548
|
+
D = c[g + 1], k = c[g + 2], O = c[g + 3], (D & 192) === 128 && (k & 192) === 128 && (O & 192) === 128 && ($ = (w & 15) << 18 | (D & 63) << 12 | (k & 63) << 6 | O & 63, $ > 65535 && $ < 1114112 && (S = $));
|
|
549
549
|
}
|
|
550
550
|
}
|
|
551
|
-
|
|
551
|
+
S === null ? (S = 65533, I = 1) : S > 65535 && (S -= 65536, f.push(S >>> 10 & 1023 | 55296), S = 56320 | S & 1023), f.push(S), g += I;
|
|
552
552
|
}
|
|
553
553
|
return tt(f);
|
|
554
554
|
}
|
|
@@ -564,28 +564,28 @@ function pn() {
|
|
|
564
564
|
);
|
|
565
565
|
return u;
|
|
566
566
|
}
|
|
567
|
-
function
|
|
567
|
+
function Qr(c, a, u) {
|
|
568
568
|
var f = "";
|
|
569
569
|
u = Math.min(c.length, u);
|
|
570
570
|
for (var g = a; g < u; ++g)
|
|
571
571
|
f += String.fromCharCode(c[g] & 127);
|
|
572
572
|
return f;
|
|
573
573
|
}
|
|
574
|
-
function
|
|
574
|
+
function en(c, a, u) {
|
|
575
575
|
var f = "";
|
|
576
576
|
u = Math.min(c.length, u);
|
|
577
577
|
for (var g = a; g < u; ++g)
|
|
578
578
|
f += String.fromCharCode(c[g]);
|
|
579
579
|
return f;
|
|
580
580
|
}
|
|
581
|
-
function
|
|
581
|
+
function tn(c, a, u) {
|
|
582
582
|
var f = c.length;
|
|
583
583
|
(!a || a < 0) && (a = 0), (!u || u < 0 || u > f) && (u = f);
|
|
584
584
|
for (var g = "", w = a; w < u; ++w)
|
|
585
|
-
g +=
|
|
585
|
+
g += an(c[w]);
|
|
586
586
|
return g;
|
|
587
587
|
}
|
|
588
|
-
function
|
|
588
|
+
function rn(c, a, u) {
|
|
589
589
|
for (var f = c.slice(a, u), g = "", w = 0; w < f.length; w += 2)
|
|
590
590
|
g += String.fromCharCode(f[w] + f[w + 1] * 256);
|
|
591
591
|
return g;
|
|
@@ -599,8 +599,8 @@ function pn() {
|
|
|
599
599
|
else {
|
|
600
600
|
var w = u - a;
|
|
601
601
|
g = new l(w, void 0);
|
|
602
|
-
for (var
|
|
603
|
-
g[
|
|
602
|
+
for (var S = 0; S < w; ++S)
|
|
603
|
+
g[S] = this[S + a];
|
|
604
604
|
}
|
|
605
605
|
return g;
|
|
606
606
|
};
|
|
@@ -610,8 +610,8 @@ function pn() {
|
|
|
610
610
|
}
|
|
611
611
|
l.prototype.readUIntLE = function(a, u, f) {
|
|
612
612
|
a = a | 0, u = u | 0, f || M(a, u, this.length);
|
|
613
|
-
for (var g = this[a], w = 1,
|
|
614
|
-
g += this[a +
|
|
613
|
+
for (var g = this[a], w = 1, S = 0; ++S < u && (w *= 256); )
|
|
614
|
+
g += this[a + S] * w;
|
|
615
615
|
return g;
|
|
616
616
|
}, l.prototype.readUIntBE = function(a, u, f) {
|
|
617
617
|
a = a | 0, u = u | 0, f || M(a, u, this.length);
|
|
@@ -630,14 +630,14 @@ function pn() {
|
|
|
630
630
|
return u || M(a, 4, this.length), this[a] * 16777216 + (this[a + 1] << 16 | this[a + 2] << 8 | this[a + 3]);
|
|
631
631
|
}, l.prototype.readIntLE = function(a, u, f) {
|
|
632
632
|
a = a | 0, u = u | 0, f || M(a, u, this.length);
|
|
633
|
-
for (var g = this[a], w = 1,
|
|
634
|
-
g += this[a +
|
|
633
|
+
for (var g = this[a], w = 1, S = 0; ++S < u && (w *= 256); )
|
|
634
|
+
g += this[a + S] * w;
|
|
635
635
|
return w *= 128, g >= w && (g -= Math.pow(2, 8 * u)), g;
|
|
636
636
|
}, l.prototype.readIntBE = function(a, u, f) {
|
|
637
637
|
a = a | 0, u = u | 0, f || M(a, u, this.length);
|
|
638
|
-
for (var g = u, w = 1,
|
|
639
|
-
|
|
640
|
-
return w *= 128,
|
|
638
|
+
for (var g = u, w = 1, S = this[a + --g]; g > 0 && (w *= 256); )
|
|
639
|
+
S += this[a + --g] * w;
|
|
640
|
+
return w *= 128, S >= w && (S -= Math.pow(2, 8 * u)), S;
|
|
641
641
|
}, l.prototype.readInt8 = function(a, u) {
|
|
642
642
|
return u || M(a, 1, this.length), this[a] & 128 ? (255 - this[a] + 1) * -1 : this[a];
|
|
643
643
|
}, l.prototype.readInt16LE = function(a, u) {
|
|
@@ -671,18 +671,18 @@ function pn() {
|
|
|
671
671
|
var w = Math.pow(2, 8 * f) - 1;
|
|
672
672
|
L(this, a, u, f, w, 0);
|
|
673
673
|
}
|
|
674
|
-
var
|
|
675
|
-
for (this[u] = a & 255; ++I < f && (
|
|
676
|
-
this[u + I] = a /
|
|
674
|
+
var S = 1, I = 0;
|
|
675
|
+
for (this[u] = a & 255; ++I < f && (S *= 256); )
|
|
676
|
+
this[u + I] = a / S & 255;
|
|
677
677
|
return u + f;
|
|
678
678
|
}, l.prototype.writeUIntBE = function(a, u, f, g) {
|
|
679
679
|
if (a = +a, u = u | 0, f = f | 0, !g) {
|
|
680
680
|
var w = Math.pow(2, 8 * f) - 1;
|
|
681
681
|
L(this, a, u, f, w, 0);
|
|
682
682
|
}
|
|
683
|
-
var
|
|
684
|
-
for (this[u +
|
|
685
|
-
this[u +
|
|
683
|
+
var S = f - 1, I = 1;
|
|
684
|
+
for (this[u + S] = a & 255; --S >= 0 && (I *= 256); )
|
|
685
|
+
this[u + S] = a / I & 255;
|
|
686
686
|
return u + f;
|
|
687
687
|
}, l.prototype.writeUInt8 = function(a, u, f) {
|
|
688
688
|
return a = +a, u = u | 0, f || L(this, a, u, 1, 255, 0), l.TYPED_ARRAY_SUPPORT || (a = Math.floor(a)), this[u] = a & 255, u + 1;
|
|
@@ -711,18 +711,18 @@ function pn() {
|
|
|
711
711
|
var w = Math.pow(2, 8 * f - 1);
|
|
712
712
|
L(this, a, u, f, w - 1, -w);
|
|
713
713
|
}
|
|
714
|
-
var
|
|
715
|
-
for (this[u] = a & 255; ++
|
|
716
|
-
a < 0 && D === 0 && this[u +
|
|
714
|
+
var S = 0, I = 1, D = 0;
|
|
715
|
+
for (this[u] = a & 255; ++S < f && (I *= 256); )
|
|
716
|
+
a < 0 && D === 0 && this[u + S - 1] !== 0 && (D = 1), this[u + S] = (a / I >> 0) - D & 255;
|
|
717
717
|
return u + f;
|
|
718
718
|
}, l.prototype.writeIntBE = function(a, u, f, g) {
|
|
719
719
|
if (a = +a, u = u | 0, !g) {
|
|
720
720
|
var w = Math.pow(2, 8 * f - 1);
|
|
721
721
|
L(this, a, u, f, w - 1, -w);
|
|
722
722
|
}
|
|
723
|
-
var
|
|
724
|
-
for (this[u +
|
|
725
|
-
a < 0 && D === 0 && this[u +
|
|
723
|
+
var S = f - 1, I = 1, D = 0;
|
|
724
|
+
for (this[u + S] = a & 255; --S >= 0 && (I *= 256); )
|
|
725
|
+
a < 0 && D === 0 && this[u + S + 1] !== 0 && (D = 1), this[u + S] = (a / I >> 0) - D & 255;
|
|
726
726
|
return u + f;
|
|
727
727
|
}, l.prototype.writeInt8 = function(a, u, f) {
|
|
728
728
|
return a = +a, u = u | 0, f || L(this, a, u, 1, 127, -128), l.TYPED_ARRAY_SUPPORT || (a = Math.floor(a)), a < 0 && (a = 255 + a + 1), this[u] = a & 255, u + 1;
|
|
@@ -761,13 +761,13 @@ function pn() {
|
|
|
761
761
|
if (f < 0 || f >= this.length) throw new RangeError("sourceStart out of bounds");
|
|
762
762
|
if (g < 0) throw new RangeError("sourceEnd out of bounds");
|
|
763
763
|
g > this.length && (g = this.length), a.length - u < g - f && (g = a.length - u + f);
|
|
764
|
-
var w = g - f,
|
|
764
|
+
var w = g - f, S;
|
|
765
765
|
if (this === a && f < u && u < g)
|
|
766
|
-
for (
|
|
767
|
-
a[
|
|
766
|
+
for (S = w - 1; S >= 0; --S)
|
|
767
|
+
a[S + u] = this[S + f];
|
|
768
768
|
else if (w < 1e3 || !l.TYPED_ARRAY_SUPPORT)
|
|
769
|
-
for (
|
|
770
|
-
a[
|
|
769
|
+
for (S = 0; S < w; ++S)
|
|
770
|
+
a[S + u] = this[S + f];
|
|
771
771
|
else
|
|
772
772
|
Uint8Array.prototype.set.call(
|
|
773
773
|
a,
|
|
@@ -791,39 +791,39 @@ function pn() {
|
|
|
791
791
|
if (f <= u)
|
|
792
792
|
return this;
|
|
793
793
|
u = u >>> 0, f = f === void 0 ? this.length : f >>> 0, a || (a = 0);
|
|
794
|
-
var
|
|
794
|
+
var S;
|
|
795
795
|
if (typeof a == "number")
|
|
796
|
-
for (
|
|
797
|
-
this[
|
|
796
|
+
for (S = u; S < f; ++S)
|
|
797
|
+
this[S] = a;
|
|
798
798
|
else {
|
|
799
799
|
var I = l.isBuffer(a) ? a : Ne(new l(a, g).toString()), D = I.length;
|
|
800
|
-
for (
|
|
801
|
-
this[
|
|
800
|
+
for (S = 0; S < f - u; ++S)
|
|
801
|
+
this[S + u] = I[S % D];
|
|
802
802
|
}
|
|
803
803
|
return this;
|
|
804
804
|
};
|
|
805
|
-
var
|
|
806
|
-
function
|
|
807
|
-
if (c =
|
|
805
|
+
var nn = /[^+\/0-9A-Za-z-_]/g;
|
|
806
|
+
function sn(c) {
|
|
807
|
+
if (c = on(c).replace(nn, ""), c.length < 2) return "";
|
|
808
808
|
for (; c.length % 4 !== 0; )
|
|
809
809
|
c = c + "=";
|
|
810
810
|
return c;
|
|
811
811
|
}
|
|
812
|
-
function
|
|
812
|
+
function on(c) {
|
|
813
813
|
return c.trim ? c.trim() : c.replace(/^\s+|\s+$/g, "");
|
|
814
814
|
}
|
|
815
|
-
function
|
|
815
|
+
function an(c) {
|
|
816
816
|
return c < 16 ? "0" + c.toString(16) : c.toString(16);
|
|
817
817
|
}
|
|
818
818
|
function Ne(c, a) {
|
|
819
819
|
a = a || 1 / 0;
|
|
820
|
-
for (var u, f = c.length, g = null, w = [],
|
|
821
|
-
if (u = c.charCodeAt(
|
|
820
|
+
for (var u, f = c.length, g = null, w = [], S = 0; S < f; ++S) {
|
|
821
|
+
if (u = c.charCodeAt(S), u > 55295 && u < 57344) {
|
|
822
822
|
if (!g) {
|
|
823
823
|
if (u > 56319) {
|
|
824
824
|
(a -= 3) > -1 && w.push(239, 191, 189);
|
|
825
825
|
continue;
|
|
826
|
-
} else if (
|
|
826
|
+
} else if (S + 1 === f) {
|
|
827
827
|
(a -= 3) > -1 && w.push(239, 191, 189);
|
|
828
828
|
continue;
|
|
829
829
|
}
|
|
@@ -865,30 +865,30 @@ function pn() {
|
|
|
865
865
|
}
|
|
866
866
|
return w;
|
|
867
867
|
}
|
|
868
|
-
function
|
|
868
|
+
function un(c) {
|
|
869
869
|
for (var a = [], u = 0; u < c.length; ++u)
|
|
870
870
|
a.push(c.charCodeAt(u) & 255);
|
|
871
871
|
return a;
|
|
872
872
|
}
|
|
873
|
-
function
|
|
874
|
-
for (var u, f, g, w = [],
|
|
875
|
-
u = c.charCodeAt(
|
|
873
|
+
function ln(c, a) {
|
|
874
|
+
for (var u, f, g, w = [], S = 0; S < c.length && !((a -= 2) < 0); ++S)
|
|
875
|
+
u = c.charCodeAt(S), f = u >> 8, g = u % 256, w.push(g), w.push(f);
|
|
876
876
|
return w;
|
|
877
877
|
}
|
|
878
878
|
function Vt(c) {
|
|
879
|
-
return e.toByteArray(
|
|
879
|
+
return e.toByteArray(sn(c));
|
|
880
880
|
}
|
|
881
881
|
function qe(c, a, u, f) {
|
|
882
882
|
for (var g = 0; g < f && !(g + u >= a.length || g >= c.length); ++g)
|
|
883
883
|
a[g + u] = c[g];
|
|
884
884
|
return g;
|
|
885
885
|
}
|
|
886
|
-
function
|
|
886
|
+
function cn(c) {
|
|
887
887
|
return c !== c;
|
|
888
888
|
}
|
|
889
889
|
})(rt)), rt;
|
|
890
890
|
}
|
|
891
|
-
var R =
|
|
891
|
+
var R = gn(), W;
|
|
892
892
|
typeof window < "u" && window.crypto && (W = window.crypto);
|
|
893
893
|
!W && typeof window < "u" && window.msCrypto && (W = window.msCrypto);
|
|
894
894
|
!W && typeof globalThis < "u" && globalThis.crypto && (W = globalThis.crypto);
|
|
@@ -897,7 +897,7 @@ if (!W && typeof require == "function")
|
|
|
897
897
|
W = require("crypto");
|
|
898
898
|
} catch {
|
|
899
899
|
}
|
|
900
|
-
function
|
|
900
|
+
function mn() {
|
|
901
901
|
if (W) {
|
|
902
902
|
if (typeof W.getRandomValues == "function")
|
|
903
903
|
try {
|
|
@@ -912,24 +912,24 @@ function gn() {
|
|
|
912
912
|
}
|
|
913
913
|
throw new Error("Native crypto module could not be used to get secure random number.");
|
|
914
914
|
}
|
|
915
|
-
function
|
|
915
|
+
function vn(n) {
|
|
916
916
|
for (var e = n.words, t = n.sigBytes, r = [], i = 0; i < t; i++) {
|
|
917
917
|
var s = e[i >>> 2] >>> 24 - i % 4 * 8 & 255;
|
|
918
918
|
r.push((s >>> 4).toString(16)), r.push((s & 15).toString(16));
|
|
919
919
|
}
|
|
920
920
|
return r.join("");
|
|
921
921
|
}
|
|
922
|
-
var
|
|
922
|
+
var Dr = /* @__PURE__ */ (function() {
|
|
923
923
|
function n(t, r) {
|
|
924
924
|
t = this.words = t || [], r != null ? this.sigBytes = r : this.sigBytes = t.length * 4;
|
|
925
925
|
}
|
|
926
926
|
var e = n.prototype;
|
|
927
927
|
return e.random = function(r) {
|
|
928
928
|
for (var i = [], s = 0; s < r; s += 4)
|
|
929
|
-
i.push(
|
|
929
|
+
i.push(mn());
|
|
930
930
|
return new n(i, r);
|
|
931
931
|
}, e.toString = function() {
|
|
932
|
-
return
|
|
932
|
+
return vn(this);
|
|
933
933
|
}, n;
|
|
934
934
|
})(), it = {};
|
|
935
935
|
var ht = function(n, e) {
|
|
@@ -939,7 +939,7 @@ var ht = function(n, e) {
|
|
|
939
939
|
for (var i in r) r.hasOwnProperty(i) && (t[i] = r[i]);
|
|
940
940
|
}, ht(n, e);
|
|
941
941
|
};
|
|
942
|
-
function
|
|
942
|
+
function yn(n, e) {
|
|
943
943
|
ht(n, e);
|
|
944
944
|
function t() {
|
|
945
945
|
this.constructor = n;
|
|
@@ -955,7 +955,7 @@ var ft = function() {
|
|
|
955
955
|
return e;
|
|
956
956
|
}, ft.apply(this, arguments);
|
|
957
957
|
};
|
|
958
|
-
function
|
|
958
|
+
function wn(n, e) {
|
|
959
959
|
var t = {};
|
|
960
960
|
for (var r in n) Object.prototype.hasOwnProperty.call(n, r) && e.indexOf(r) < 0 && (t[r] = n[r]);
|
|
961
961
|
if (n != null && typeof Object.getOwnPropertySymbols == "function")
|
|
@@ -963,7 +963,7 @@ function yn(n, e) {
|
|
|
963
963
|
e.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(n, r[i]) && (t[r[i]] = n[r[i]]);
|
|
964
964
|
return t;
|
|
965
965
|
}
|
|
966
|
-
function
|
|
966
|
+
function bn(n, e, t, r) {
|
|
967
967
|
var i = arguments.length, s = i < 3 ? e : r === null ? r = Object.getOwnPropertyDescriptor(e, t) : r, o;
|
|
968
968
|
if (typeof Reflect == "object" && typeof Reflect.decorate == "function") s = Reflect.decorate(n, e, t, r);
|
|
969
969
|
else for (var l = n.length - 1; l >= 0; l--) (o = n[l]) && (s = (i < 3 ? o(s) : i > 3 ? o(e, t, s) : o(e, t)) || s);
|
|
@@ -974,10 +974,10 @@ function Sn(n, e) {
|
|
|
974
974
|
e(t, r, n);
|
|
975
975
|
};
|
|
976
976
|
}
|
|
977
|
-
function
|
|
977
|
+
function _n(n, e) {
|
|
978
978
|
if (typeof Reflect == "object" && typeof Reflect.metadata == "function") return Reflect.metadata(n, e);
|
|
979
979
|
}
|
|
980
|
-
function
|
|
980
|
+
function An(n, e, t, r) {
|
|
981
981
|
function i(s) {
|
|
982
982
|
return s instanceof t ? s : new t(function(o) {
|
|
983
983
|
o(s);
|
|
@@ -1004,7 +1004,7 @@ function _n(n, e, t, r) {
|
|
|
1004
1004
|
d((r = r.apply(n, e || [])).next());
|
|
1005
1005
|
});
|
|
1006
1006
|
}
|
|
1007
|
-
function
|
|
1007
|
+
function Cn(n, e) {
|
|
1008
1008
|
var t = { label: 0, sent: function() {
|
|
1009
1009
|
if (s[0] & 1) throw s[1];
|
|
1010
1010
|
return s[1];
|
|
@@ -1064,10 +1064,10 @@ function An(n, e) {
|
|
|
1064
1064
|
return { value: d[0] ? d[1] : void 0, done: !0 };
|
|
1065
1065
|
}
|
|
1066
1066
|
}
|
|
1067
|
-
function
|
|
1067
|
+
function xn(n, e, t, r) {
|
|
1068
1068
|
r === void 0 && (r = t), n[r] = e[t];
|
|
1069
1069
|
}
|
|
1070
|
-
function
|
|
1070
|
+
function En(n, e) {
|
|
1071
1071
|
for (var t in n) t !== "default" && !e.hasOwnProperty(t) && (e[t] = n[t]);
|
|
1072
1072
|
}
|
|
1073
1073
|
function dt(n) {
|
|
@@ -1080,7 +1080,7 @@ function dt(n) {
|
|
|
1080
1080
|
};
|
|
1081
1081
|
throw new TypeError(e ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
1082
1082
|
}
|
|
1083
|
-
function
|
|
1083
|
+
function Rr(n, e) {
|
|
1084
1084
|
var t = typeof Symbol == "function" && n[Symbol.iterator];
|
|
1085
1085
|
if (!t) return n;
|
|
1086
1086
|
var r = t.call(n), i, s = [], o;
|
|
@@ -1097,12 +1097,12 @@ function Dr(n, e) {
|
|
|
1097
1097
|
}
|
|
1098
1098
|
return s;
|
|
1099
1099
|
}
|
|
1100
|
-
function
|
|
1100
|
+
function Un() {
|
|
1101
1101
|
for (var n = [], e = 0; e < arguments.length; e++)
|
|
1102
|
-
n = n.concat(
|
|
1102
|
+
n = n.concat(Rr(arguments[e]));
|
|
1103
1103
|
return n;
|
|
1104
1104
|
}
|
|
1105
|
-
function
|
|
1105
|
+
function Tn() {
|
|
1106
1106
|
for (var n = 0, e = 0, t = arguments.length; e < t; e++) n += arguments[e].length;
|
|
1107
1107
|
for (var r = Array(n), i = 0, e = 0; e < t; e++)
|
|
1108
1108
|
for (var s = arguments[e], o = 0, l = s.length; o < l; o++, i++)
|
|
@@ -1112,7 +1112,7 @@ function Un() {
|
|
|
1112
1112
|
function Re(n) {
|
|
1113
1113
|
return this instanceof Re ? (this.v = n, this) : new Re(n);
|
|
1114
1114
|
}
|
|
1115
|
-
function
|
|
1115
|
+
function In(n, e, t) {
|
|
1116
1116
|
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
1117
1117
|
var r = t.apply(n, e || []), i, s = [];
|
|
1118
1118
|
return i = {}, o("next"), o("throw"), o("return"), i[Symbol.asyncIterator] = function() {
|
|
@@ -1120,16 +1120,16 @@ function Tn(n, e, t) {
|
|
|
1120
1120
|
}, i;
|
|
1121
1121
|
function o(v) {
|
|
1122
1122
|
r[v] && (i[v] = function(y) {
|
|
1123
|
-
return new Promise(function(
|
|
1124
|
-
s.push([v, y,
|
|
1123
|
+
return new Promise(function(b, _) {
|
|
1124
|
+
s.push([v, y, b, _]) > 1 || l(v, y);
|
|
1125
1125
|
});
|
|
1126
1126
|
});
|
|
1127
1127
|
}
|
|
1128
1128
|
function l(v, y) {
|
|
1129
1129
|
try {
|
|
1130
1130
|
h(r[v](y));
|
|
1131
|
-
} catch (
|
|
1132
|
-
m(s[0][3],
|
|
1131
|
+
} catch (b) {
|
|
1132
|
+
m(s[0][3], b);
|
|
1133
1133
|
}
|
|
1134
1134
|
}
|
|
1135
1135
|
function h(v) {
|
|
@@ -1145,7 +1145,7 @@ function Tn(n, e, t) {
|
|
|
1145
1145
|
v(y), s.shift(), s.length && l(s[0][0], s[0][1]);
|
|
1146
1146
|
}
|
|
1147
1147
|
}
|
|
1148
|
-
function
|
|
1148
|
+
function Dn(n) {
|
|
1149
1149
|
var e, t;
|
|
1150
1150
|
return e = {}, r("next"), r("throw", function(i) {
|
|
1151
1151
|
throw i;
|
|
@@ -1158,7 +1158,7 @@ function In(n) {
|
|
|
1158
1158
|
} : s;
|
|
1159
1159
|
}
|
|
1160
1160
|
}
|
|
1161
|
-
function
|
|
1161
|
+
function Rn(n) {
|
|
1162
1162
|
if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
|
|
1163
1163
|
var e = n[Symbol.asyncIterator], t;
|
|
1164
1164
|
return e ? e.call(n) : (n = typeof dt == "function" ? dt(n) : n[Symbol.iterator](), t = {}, r("next"), r("throw"), r("return"), t[Symbol.asyncIterator] = function() {
|
|
@@ -1177,59 +1177,59 @@ function Dn(n) {
|
|
|
1177
1177
|
}, o);
|
|
1178
1178
|
}
|
|
1179
1179
|
}
|
|
1180
|
-
function
|
|
1180
|
+
function kn(n, e) {
|
|
1181
1181
|
return Object.defineProperty ? Object.defineProperty(n, "raw", { value: e }) : n.raw = e, n;
|
|
1182
1182
|
}
|
|
1183
|
-
function
|
|
1183
|
+
function $n(n) {
|
|
1184
1184
|
if (n && n.__esModule) return n;
|
|
1185
1185
|
var e = {};
|
|
1186
1186
|
if (n != null)
|
|
1187
1187
|
for (var t in n) Object.hasOwnProperty.call(n, t) && (e[t] = n[t]);
|
|
1188
1188
|
return e.default = n, e;
|
|
1189
1189
|
}
|
|
1190
|
-
function
|
|
1190
|
+
function Pn(n) {
|
|
1191
1191
|
return n && n.__esModule ? n : { default: n };
|
|
1192
1192
|
}
|
|
1193
|
-
function
|
|
1193
|
+
function Fn(n, e) {
|
|
1194
1194
|
if (!e.has(n))
|
|
1195
1195
|
throw new TypeError("attempted to get private field on non-instance");
|
|
1196
1196
|
return e.get(n);
|
|
1197
1197
|
}
|
|
1198
|
-
function
|
|
1198
|
+
function Bn(n, e, t) {
|
|
1199
1199
|
if (!e.has(n))
|
|
1200
1200
|
throw new TypeError("attempted to set private field on non-instance");
|
|
1201
1201
|
return e.set(n, t), t;
|
|
1202
1202
|
}
|
|
1203
|
-
const
|
|
1203
|
+
const Mn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1204
1204
|
__proto__: null,
|
|
1205
1205
|
get __assign() {
|
|
1206
1206
|
return ft;
|
|
1207
1207
|
},
|
|
1208
|
-
__asyncDelegator:
|
|
1209
|
-
__asyncGenerator:
|
|
1210
|
-
__asyncValues:
|
|
1208
|
+
__asyncDelegator: Dn,
|
|
1209
|
+
__asyncGenerator: In,
|
|
1210
|
+
__asyncValues: Rn,
|
|
1211
1211
|
__await: Re,
|
|
1212
|
-
__awaiter:
|
|
1213
|
-
__classPrivateFieldGet:
|
|
1214
|
-
__classPrivateFieldSet:
|
|
1215
|
-
__createBinding:
|
|
1216
|
-
__decorate:
|
|
1217
|
-
__exportStar:
|
|
1218
|
-
__extends:
|
|
1219
|
-
__generator:
|
|
1220
|
-
__importDefault:
|
|
1221
|
-
__importStar:
|
|
1222
|
-
__makeTemplateObject:
|
|
1223
|
-
__metadata:
|
|
1212
|
+
__awaiter: An,
|
|
1213
|
+
__classPrivateFieldGet: Fn,
|
|
1214
|
+
__classPrivateFieldSet: Bn,
|
|
1215
|
+
__createBinding: xn,
|
|
1216
|
+
__decorate: bn,
|
|
1217
|
+
__exportStar: En,
|
|
1218
|
+
__extends: yn,
|
|
1219
|
+
__generator: Cn,
|
|
1220
|
+
__importDefault: Pn,
|
|
1221
|
+
__importStar: $n,
|
|
1222
|
+
__makeTemplateObject: kn,
|
|
1223
|
+
__metadata: _n,
|
|
1224
1224
|
__param: Sn,
|
|
1225
|
-
__read:
|
|
1226
|
-
__rest:
|
|
1227
|
-
__spread:
|
|
1228
|
-
__spreadArrays:
|
|
1225
|
+
__read: Rr,
|
|
1226
|
+
__rest: wn,
|
|
1227
|
+
__spread: Un,
|
|
1228
|
+
__spreadArrays: Tn,
|
|
1229
1229
|
__values: dt
|
|
1230
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1230
|
+
}, Symbol.toStringTag, { value: "Module" })), kr = /* @__PURE__ */ Ut(Mn);
|
|
1231
1231
|
var we = {}, V = {}, Jt;
|
|
1232
|
-
function
|
|
1232
|
+
function $r() {
|
|
1233
1233
|
return Jt || (Jt = 1, Object.defineProperty(V, "__esModule", { value: !0 }), V.MAX_HASHABLE_LENGTH = V.INIT = V.KEY = V.DIGEST_LENGTH = V.BLOCK_SIZE = void 0, V.BLOCK_SIZE = 64, V.DIGEST_LENGTH = 32, V.KEY = new Uint32Array([
|
|
1234
1234
|
1116352408,
|
|
1235
1235
|
1899447441,
|
|
@@ -1306,11 +1306,11 @@ function kr() {
|
|
|
1306
1306
|
1541459225
|
|
1307
1307
|
], V.MAX_HASHABLE_LENGTH = Math.pow(2, 53) - 1), V;
|
|
1308
1308
|
}
|
|
1309
|
-
var
|
|
1310
|
-
function
|
|
1311
|
-
if (Zt) return
|
|
1312
|
-
Zt = 1, Object.defineProperty(
|
|
1313
|
-
var n =
|
|
1309
|
+
var be = {}, Zt;
|
|
1310
|
+
function On() {
|
|
1311
|
+
if (Zt) return be;
|
|
1312
|
+
Zt = 1, Object.defineProperty(be, "__esModule", { value: !0 }), be.RawSha256 = void 0;
|
|
1313
|
+
var n = $r(), e = (
|
|
1314
1314
|
/** @class */
|
|
1315
1315
|
(function() {
|
|
1316
1316
|
function t() {
|
|
@@ -1340,26 +1340,26 @@ function Mn() {
|
|
|
1340
1340
|
l[o * 4] = this.state[o] >>> 24 & 255, l[o * 4 + 1] = this.state[o] >>> 16 & 255, l[o * 4 + 2] = this.state[o] >>> 8 & 255, l[o * 4 + 3] = this.state[o] >>> 0 & 255;
|
|
1341
1341
|
return l;
|
|
1342
1342
|
}, t.prototype.hashBuffer = function() {
|
|
1343
|
-
for (var r = this, i = r.buffer, s = r.state, o = s[0], l = s[1], h = s[2], d = s[3], p = s[4], m = s[5], v = s[6], y = s[7],
|
|
1344
|
-
if (
|
|
1345
|
-
this.temp[
|
|
1343
|
+
for (var r = this, i = r.buffer, s = r.state, o = s[0], l = s[1], h = s[2], d = s[3], p = s[4], m = s[5], v = s[6], y = s[7], b = 0; b < n.BLOCK_SIZE; b++) {
|
|
1344
|
+
if (b < 16)
|
|
1345
|
+
this.temp[b] = (i[b * 4] & 255) << 24 | (i[b * 4 + 1] & 255) << 16 | (i[b * 4 + 2] & 255) << 8 | i[b * 4 + 3] & 255;
|
|
1346
1346
|
else {
|
|
1347
|
-
var _ = this.temp[
|
|
1348
|
-
_ = this.temp[
|
|
1347
|
+
var _ = this.temp[b - 2], E = (_ >>> 17 | _ << 15) ^ (_ >>> 19 | _ << 13) ^ _ >>> 10;
|
|
1348
|
+
_ = this.temp[b - 15];
|
|
1349
1349
|
var x = (_ >>> 7 | _ << 25) ^ (_ >>> 18 | _ << 14) ^ _ >>> 3;
|
|
1350
|
-
this.temp[
|
|
1350
|
+
this.temp[b] = (E + this.temp[b - 7] | 0) + (x + this.temp[b - 16] | 0);
|
|
1351
1351
|
}
|
|
1352
|
-
var U = (((p >>> 6 | p << 26) ^ (p >>> 11 | p << 21) ^ (p >>> 25 | p << 7)) + (p & m ^ ~p & v) | 0) + (y + (n.KEY[
|
|
1352
|
+
var U = (((p >>> 6 | p << 26) ^ (p >>> 11 | p << 21) ^ (p >>> 25 | p << 7)) + (p & m ^ ~p & v) | 0) + (y + (n.KEY[b] + this.temp[b] | 0) | 0) | 0, P = ((o >>> 2 | o << 30) ^ (o >>> 13 | o << 19) ^ (o >>> 22 | o << 10)) + (o & l ^ o & h ^ l & h) | 0;
|
|
1353
1353
|
y = v, v = m, m = p, p = d + U | 0, d = h, h = l, l = o, o = U + P | 0;
|
|
1354
1354
|
}
|
|
1355
1355
|
s[0] += o, s[1] += l, s[2] += h, s[3] += d, s[4] += p, s[5] += m, s[6] += v, s[7] += y;
|
|
1356
1356
|
}, t;
|
|
1357
1357
|
})()
|
|
1358
1358
|
);
|
|
1359
|
-
return
|
|
1359
|
+
return be.RawSha256 = e, be;
|
|
1360
1360
|
}
|
|
1361
|
-
var st = {},
|
|
1362
|
-
const
|
|
1361
|
+
var st = {}, Se = {};
|
|
1362
|
+
const Nn = (n) => {
|
|
1363
1363
|
const e = [];
|
|
1364
1364
|
for (let t = 0, r = n.length; t < r; t++) {
|
|
1365
1365
|
const i = n.charCodeAt(t);
|
|
@@ -1374,7 +1374,7 @@ const On = (n) => {
|
|
|
1374
1374
|
e.push(i >> 12 | 224, i >> 6 & 63 | 128, i & 63 | 128);
|
|
1375
1375
|
}
|
|
1376
1376
|
return Uint8Array.from(e);
|
|
1377
|
-
},
|
|
1377
|
+
}, qn = (n) => {
|
|
1378
1378
|
let e = "";
|
|
1379
1379
|
for (let t = 0, r = n.length; t < r; t++) {
|
|
1380
1380
|
const i = n[t];
|
|
@@ -1391,31 +1391,31 @@ const On = (n) => {
|
|
|
1391
1391
|
}
|
|
1392
1392
|
return e;
|
|
1393
1393
|
};
|
|
1394
|
-
function
|
|
1394
|
+
function Ln(n) {
|
|
1395
1395
|
return new TextEncoder().encode(n);
|
|
1396
1396
|
}
|
|
1397
|
-
function
|
|
1397
|
+
function Kn(n) {
|
|
1398
1398
|
return new TextDecoder("utf-8").decode(n);
|
|
1399
1399
|
}
|
|
1400
|
-
const
|
|
1400
|
+
const Vn = (n) => typeof TextEncoder == "function" ? Ln(n) : Nn(n), jn = (n) => typeof TextDecoder == "function" ? Kn(n) : qn(n), Hn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1401
1401
|
__proto__: null,
|
|
1402
|
-
fromUtf8:
|
|
1403
|
-
toUtf8:
|
|
1404
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1402
|
+
fromUtf8: Vn,
|
|
1403
|
+
toUtf8: jn
|
|
1404
|
+
}, Symbol.toStringTag, { value: "Module" })), zn = /* @__PURE__ */ Ut(Hn);
|
|
1405
1405
|
var Xt;
|
|
1406
|
-
function
|
|
1407
|
-
if (Xt) return
|
|
1408
|
-
Xt = 1, Object.defineProperty(
|
|
1409
|
-
var n =
|
|
1406
|
+
function Wn() {
|
|
1407
|
+
if (Xt) return Se;
|
|
1408
|
+
Xt = 1, Object.defineProperty(Se, "__esModule", { value: !0 }), Se.convertToBuffer = void 0;
|
|
1409
|
+
var n = zn, e = typeof Buffer < "u" && Buffer.from ? function(r) {
|
|
1410
1410
|
return Buffer.from(r, "utf8");
|
|
1411
1411
|
} : n.fromUtf8;
|
|
1412
1412
|
function t(r) {
|
|
1413
1413
|
return r instanceof Uint8Array ? r : typeof r == "string" ? e(r) : ArrayBuffer.isView(r) ? new Uint8Array(r.buffer, r.byteOffset, r.byteLength / Uint8Array.BYTES_PER_ELEMENT) : new Uint8Array(r);
|
|
1414
1414
|
}
|
|
1415
|
-
return
|
|
1415
|
+
return Se.convertToBuffer = t, Se;
|
|
1416
1416
|
}
|
|
1417
1417
|
var _e = {}, Qt;
|
|
1418
|
-
function
|
|
1418
|
+
function Yn() {
|
|
1419
1419
|
if (Qt) return _e;
|
|
1420
1420
|
Qt = 1, Object.defineProperty(_e, "__esModule", { value: !0 }), _e.isEmptyData = void 0;
|
|
1421
1421
|
function n(e) {
|
|
@@ -1424,7 +1424,7 @@ function Wn() {
|
|
|
1424
1424
|
return _e.isEmptyData = n, _e;
|
|
1425
1425
|
}
|
|
1426
1426
|
var Ae = {}, er;
|
|
1427
|
-
function
|
|
1427
|
+
function Gn() {
|
|
1428
1428
|
if (er) return Ae;
|
|
1429
1429
|
er = 1, Object.defineProperty(Ae, "__esModule", { value: !0 }), Ae.numToUint8 = void 0;
|
|
1430
1430
|
function n(e) {
|
|
@@ -1438,7 +1438,7 @@ function Yn() {
|
|
|
1438
1438
|
return Ae.numToUint8 = n, Ae;
|
|
1439
1439
|
}
|
|
1440
1440
|
var Ce = {}, tr;
|
|
1441
|
-
function
|
|
1441
|
+
function Jn() {
|
|
1442
1442
|
if (tr) return Ce;
|
|
1443
1443
|
tr = 1, Object.defineProperty(Ce, "__esModule", { value: !0 }), Ce.uint32ArrayFrom = void 0;
|
|
1444
1444
|
function n(e) {
|
|
@@ -1452,32 +1452,32 @@ function Gn() {
|
|
|
1452
1452
|
return Ce.uint32ArrayFrom = n, Ce;
|
|
1453
1453
|
}
|
|
1454
1454
|
var rr;
|
|
1455
|
-
function
|
|
1455
|
+
function Zn() {
|
|
1456
1456
|
return rr || (rr = 1, (function(n) {
|
|
1457
1457
|
Object.defineProperty(n, "__esModule", { value: !0 }), n.uint32ArrayFrom = n.numToUint8 = n.isEmptyData = n.convertToBuffer = void 0;
|
|
1458
|
-
var e =
|
|
1458
|
+
var e = Wn();
|
|
1459
1459
|
Object.defineProperty(n, "convertToBuffer", { enumerable: !0, get: function() {
|
|
1460
1460
|
return e.convertToBuffer;
|
|
1461
1461
|
} });
|
|
1462
|
-
var t =
|
|
1462
|
+
var t = Yn();
|
|
1463
1463
|
Object.defineProperty(n, "isEmptyData", { enumerable: !0, get: function() {
|
|
1464
1464
|
return t.isEmptyData;
|
|
1465
1465
|
} });
|
|
1466
|
-
var r =
|
|
1466
|
+
var r = Gn();
|
|
1467
1467
|
Object.defineProperty(n, "numToUint8", { enumerable: !0, get: function() {
|
|
1468
1468
|
return r.numToUint8;
|
|
1469
1469
|
} });
|
|
1470
|
-
var i =
|
|
1470
|
+
var i = Jn();
|
|
1471
1471
|
Object.defineProperty(n, "uint32ArrayFrom", { enumerable: !0, get: function() {
|
|
1472
1472
|
return i.uint32ArrayFrom;
|
|
1473
1473
|
} });
|
|
1474
1474
|
})(st)), st;
|
|
1475
1475
|
}
|
|
1476
1476
|
var nr;
|
|
1477
|
-
function
|
|
1477
|
+
function Xn() {
|
|
1478
1478
|
if (nr) return we;
|
|
1479
1479
|
nr = 1, Object.defineProperty(we, "__esModule", { value: !0 }), we.Sha256 = void 0;
|
|
1480
|
-
var n =
|
|
1480
|
+
var n = kr, e = $r(), t = On(), r = Zn(), i = (
|
|
1481
1481
|
/** @class */
|
|
1482
1482
|
(function() {
|
|
1483
1483
|
function o(l) {
|
|
@@ -1525,36 +1525,36 @@ function Zn() {
|
|
|
1525
1525
|
return we;
|
|
1526
1526
|
}
|
|
1527
1527
|
var ir;
|
|
1528
|
-
function
|
|
1528
|
+
function Qn() {
|
|
1529
1529
|
return ir || (ir = 1, (function(n) {
|
|
1530
1530
|
Object.defineProperty(n, "__esModule", { value: !0 });
|
|
1531
|
-
var e =
|
|
1532
|
-
(0, e.__exportStar)(
|
|
1531
|
+
var e = kr;
|
|
1532
|
+
(0, e.__exportStar)(Xn(), n);
|
|
1533
1533
|
})(it)), it;
|
|
1534
1534
|
}
|
|
1535
|
-
var Ie =
|
|
1535
|
+
var Ie = Qn();
|
|
1536
1536
|
function A(n, e) {
|
|
1537
1537
|
n != null && this.fromString(n, e);
|
|
1538
1538
|
}
|
|
1539
1539
|
function q() {
|
|
1540
1540
|
return new A(null);
|
|
1541
1541
|
}
|
|
1542
|
-
var Z,
|
|
1543
|
-
function
|
|
1542
|
+
var Z, ei = 244837814094590, sr = (ei & 16777215) == 15715070;
|
|
1543
|
+
function ti(n, e, t, r, i, s) {
|
|
1544
1544
|
for (; --s >= 0; ) {
|
|
1545
1545
|
var o = e * this[n++] + t[r] + i;
|
|
1546
1546
|
i = Math.floor(o / 67108864), t[r++] = o & 67108863;
|
|
1547
1547
|
}
|
|
1548
1548
|
return i;
|
|
1549
1549
|
}
|
|
1550
|
-
function
|
|
1550
|
+
function ri(n, e, t, r, i, s) {
|
|
1551
1551
|
for (var o = e & 32767, l = e >> 15; --s >= 0; ) {
|
|
1552
1552
|
var h = this[n] & 32767, d = this[n++] >> 15, p = l * h + d * o;
|
|
1553
1553
|
h = o * h + ((p & 32767) << 15) + t[r] + (i & 1073741823), i = (h >>> 30) + (p >>> 15) + l * d + (i >>> 30), t[r++] = h & 1073741823;
|
|
1554
1554
|
}
|
|
1555
1555
|
return i;
|
|
1556
1556
|
}
|
|
1557
|
-
function
|
|
1557
|
+
function ni(n, e, t, r, i, s) {
|
|
1558
1558
|
for (var o = e & 16383, l = e >> 14; --s >= 0; ) {
|
|
1559
1559
|
var h = this[n] & 16383, d = this[n++] >> 14, p = l * h + d * o;
|
|
1560
1560
|
h = o * h + ((p & 16383) << 14) + t[r] + i, i = (h >> 28) + (p >> 14) + l * d, t[r++] = h & 268435455;
|
|
@@ -1562,7 +1562,7 @@ function ri(n, e, t, r, i, s) {
|
|
|
1562
1562
|
return i;
|
|
1563
1563
|
}
|
|
1564
1564
|
var or = typeof navigator < "u";
|
|
1565
|
-
or && sr && navigator.appName == "Microsoft Internet Explorer" ? (A.prototype.am =
|
|
1565
|
+
or && sr && navigator.appName == "Microsoft Internet Explorer" ? (A.prototype.am = ri, Z = 30) : or && sr && navigator.appName != "Netscape" ? (A.prototype.am = ti, Z = 26) : (A.prototype.am = ni, Z = 28);
|
|
1566
1566
|
A.prototype.DB = Z;
|
|
1567
1567
|
A.prototype.DM = (1 << Z) - 1;
|
|
1568
1568
|
A.prototype.DV = 1 << Z;
|
|
@@ -1570,7 +1570,7 @@ var Tt = 52;
|
|
|
1570
1570
|
A.prototype.FV = Math.pow(2, Tt);
|
|
1571
1571
|
A.prototype.F1 = Tt - Z;
|
|
1572
1572
|
A.prototype.F2 = 2 * Z - Tt;
|
|
1573
|
-
var
|
|
1573
|
+
var ii = "0123456789abcdefghijklmnopqrstuvwxyz", Xe = new Array(), de, Y;
|
|
1574
1574
|
de = 48;
|
|
1575
1575
|
for (Y = 0; Y <= 9; ++Y) Xe[de++] = Y;
|
|
1576
1576
|
de = 97;
|
|
@@ -1578,24 +1578,24 @@ for (Y = 10; Y < 36; ++Y) Xe[de++] = Y;
|
|
|
1578
1578
|
de = 65;
|
|
1579
1579
|
for (Y = 10; Y < 36; ++Y) Xe[de++] = Y;
|
|
1580
1580
|
function ar(n) {
|
|
1581
|
-
return
|
|
1581
|
+
return ii.charAt(n);
|
|
1582
1582
|
}
|
|
1583
|
-
function
|
|
1583
|
+
function si(n, e) {
|
|
1584
1584
|
var t = Xe[n.charCodeAt(e)];
|
|
1585
1585
|
return t ?? -1;
|
|
1586
1586
|
}
|
|
1587
|
-
function
|
|
1587
|
+
function oi(n) {
|
|
1588
1588
|
for (var e = this.t - 1; e >= 0; --e) n[e] = this[e];
|
|
1589
1589
|
n.t = this.t, n.s = this.s;
|
|
1590
1590
|
}
|
|
1591
|
-
function
|
|
1591
|
+
function ai(n) {
|
|
1592
1592
|
this.t = 1, this.s = n < 0 ? -1 : 0, n > 0 ? this[0] = n : n < -1 ? this[0] = n + this.DV : this.t = 0;
|
|
1593
1593
|
}
|
|
1594
1594
|
function It(n) {
|
|
1595
1595
|
var e = q();
|
|
1596
1596
|
return e.fromInt(n), e;
|
|
1597
1597
|
}
|
|
1598
|
-
function
|
|
1598
|
+
function ui(n, e) {
|
|
1599
1599
|
var t;
|
|
1600
1600
|
if (e == 16) t = 4;
|
|
1601
1601
|
else if (e == 8) t = 3;
|
|
@@ -1605,7 +1605,7 @@ function ai(n, e) {
|
|
|
1605
1605
|
else throw new Error("Only radix 2, 4, 8, 16, 32 are supported");
|
|
1606
1606
|
this.t = 0, this.s = 0;
|
|
1607
1607
|
for (var r = n.length, i = !1, s = 0; --r >= 0; ) {
|
|
1608
|
-
var o =
|
|
1608
|
+
var o = si(n, r);
|
|
1609
1609
|
if (o < 0) {
|
|
1610
1610
|
n.charAt(r) == "-" && (i = !0);
|
|
1611
1611
|
continue;
|
|
@@ -1614,10 +1614,10 @@ function ai(n, e) {
|
|
|
1614
1614
|
}
|
|
1615
1615
|
this.clamp(), i && A.ZERO.subTo(this, this);
|
|
1616
1616
|
}
|
|
1617
|
-
function
|
|
1617
|
+
function li() {
|
|
1618
1618
|
for (var n = this.s & this.DM; this.t > 0 && this[this.t - 1] == n; ) --this.t;
|
|
1619
1619
|
}
|
|
1620
|
-
function
|
|
1620
|
+
function ci(n) {
|
|
1621
1621
|
if (this.s < 0) return "-" + this.negate().toString(n);
|
|
1622
1622
|
var e;
|
|
1623
1623
|
if (n == 16) e = 4;
|
|
@@ -1632,14 +1632,14 @@ function li(n) {
|
|
|
1632
1632
|
l < e ? (r = (this[o] & (1 << l) - 1) << e - l, r |= this[--o] >> (l += this.DB - e)) : (r = this[o] >> (l -= e) & t, l <= 0 && (l += this.DB, --o)), r > 0 && (i = !0), i && (s += ar(r));
|
|
1633
1633
|
return i ? s : "0";
|
|
1634
1634
|
}
|
|
1635
|
-
function
|
|
1635
|
+
function hi() {
|
|
1636
1636
|
var n = q();
|
|
1637
1637
|
return A.ZERO.subTo(this, n), n;
|
|
1638
1638
|
}
|
|
1639
|
-
function
|
|
1639
|
+
function fi() {
|
|
1640
1640
|
return this.s < 0 ? this.negate() : this;
|
|
1641
1641
|
}
|
|
1642
|
-
function
|
|
1642
|
+
function di(n) {
|
|
1643
1643
|
var e = this.s - n.s;
|
|
1644
1644
|
if (e != 0) return e;
|
|
1645
1645
|
var t = this.t;
|
|
@@ -1651,27 +1651,27 @@ function Dt(n) {
|
|
|
1651
1651
|
var e = 1, t;
|
|
1652
1652
|
return (t = n >>> 16) != 0 && (n = t, e += 16), (t = n >> 8) != 0 && (n = t, e += 8), (t = n >> 4) != 0 && (n = t, e += 4), (t = n >> 2) != 0 && (n = t, e += 2), (t = n >> 1) != 0 && (n = t, e += 1), e;
|
|
1653
1653
|
}
|
|
1654
|
-
function
|
|
1654
|
+
function pi() {
|
|
1655
1655
|
return this.t <= 0 ? 0 : this.DB * (this.t - 1) + Dt(this[this.t - 1] ^ this.s & this.DM);
|
|
1656
1656
|
}
|
|
1657
|
-
function
|
|
1657
|
+
function gi(n, e) {
|
|
1658
1658
|
var t;
|
|
1659
1659
|
for (t = this.t - 1; t >= 0; --t) e[t + n] = this[t];
|
|
1660
1660
|
for (t = n - 1; t >= 0; --t) e[t] = 0;
|
|
1661
1661
|
e.t = this.t + n, e.s = this.s;
|
|
1662
1662
|
}
|
|
1663
|
-
function
|
|
1663
|
+
function mi(n, e) {
|
|
1664
1664
|
for (var t = n; t < this.t; ++t) e[t - n] = this[t];
|
|
1665
1665
|
e.t = Math.max(this.t - n, 0), e.s = this.s;
|
|
1666
1666
|
}
|
|
1667
|
-
function
|
|
1667
|
+
function vi(n, e) {
|
|
1668
1668
|
var t = n % this.DB, r = this.DB - t, i = (1 << r) - 1, s = Math.floor(n / this.DB), o = this.s << t & this.DM, l;
|
|
1669
1669
|
for (l = this.t - 1; l >= 0; --l)
|
|
1670
1670
|
e[l + s + 1] = this[l] >> r | o, o = (this[l] & i) << t;
|
|
1671
1671
|
for (l = s - 1; l >= 0; --l) e[l] = 0;
|
|
1672
1672
|
e[s] = o, e.t = this.t + s + 1, e.s = this.s, e.clamp();
|
|
1673
1673
|
}
|
|
1674
|
-
function
|
|
1674
|
+
function yi(n, e) {
|
|
1675
1675
|
e.s = this.s;
|
|
1676
1676
|
var t = Math.floor(n / this.DB);
|
|
1677
1677
|
if (t >= this.t) {
|
|
@@ -1684,7 +1684,7 @@ function vi(n, e) {
|
|
|
1684
1684
|
e[o - t - 1] |= (this[o] & s) << i, e[o - t] = this[o] >> r;
|
|
1685
1685
|
r > 0 && (e[this.t - t - 1] |= (this.s & s) << i), e.t = this.t - t, e.clamp();
|
|
1686
1686
|
}
|
|
1687
|
-
function
|
|
1687
|
+
function wi(n, e) {
|
|
1688
1688
|
for (var t = 0, r = 0, i = Math.min(n.t, this.t); t < i; )
|
|
1689
1689
|
r += this[t] - n[t], e[t++] = r & this.DM, r >>= this.DB;
|
|
1690
1690
|
if (n.t < this.t) {
|
|
@@ -1698,7 +1698,7 @@ function yi(n, e) {
|
|
|
1698
1698
|
}
|
|
1699
1699
|
e.s = r < 0 ? -1 : 0, r < -1 ? e[t++] = this.DV + r : r > 0 && (e[t++] = r), e.t = t, e.clamp();
|
|
1700
1700
|
}
|
|
1701
|
-
function
|
|
1701
|
+
function bi(n, e) {
|
|
1702
1702
|
var t = this.abs(), r = n.abs(), i = t.t;
|
|
1703
1703
|
for (e.t = i + r.t; --i >= 0; ) e[i] = 0;
|
|
1704
1704
|
for (i = 0; i < r.t; ++i) e[i + t.t] = t.am(0, r[i], e, i, 0, t.t);
|
|
@@ -1712,7 +1712,7 @@ function Si(n) {
|
|
|
1712
1712
|
}
|
|
1713
1713
|
n.t > 0 && (n[n.t - 1] += e.am(t, e[t], n, 2 * t, 0, 1)), n.s = 0, n.clamp();
|
|
1714
1714
|
}
|
|
1715
|
-
function
|
|
1715
|
+
function _i(n, e, t) {
|
|
1716
1716
|
var r = n.abs();
|
|
1717
1717
|
if (!(r.t <= 0)) {
|
|
1718
1718
|
var i = this.abs();
|
|
@@ -1725,10 +1725,10 @@ function bi(n, e, t) {
|
|
|
1725
1725
|
h > 0 ? (r.lShiftTo(h, s), i.lShiftTo(h, t)) : (r.copyTo(s), i.copyTo(t));
|
|
1726
1726
|
var d = s.t, p = s[d - 1];
|
|
1727
1727
|
if (p != 0) {
|
|
1728
|
-
var m = p * (1 << this.F1) + (d > 1 ? s[d - 2] >> this.F2 : 0), v = this.FV / m, y = (1 << this.F1) / m,
|
|
1728
|
+
var m = p * (1 << this.F1) + (d > 1 ? s[d - 2] >> this.F2 : 0), v = this.FV / m, y = (1 << this.F1) / m, b = 1 << this.F2, _ = t.t, E = _ - d, x = e ?? q();
|
|
1729
1729
|
for (s.dlShiftTo(E, x), t.compareTo(x) >= 0 && (t[t.t++] = 1, t.subTo(x, t)), A.ONE.dlShiftTo(d, x), x.subTo(s, s); s.t < d; ) s[s.t++] = 0;
|
|
1730
1730
|
for (; --E >= 0; ) {
|
|
1731
|
-
var U = t[--_] == p ? this.DM : Math.floor(t[_] * v + (t[_ - 1] +
|
|
1731
|
+
var U = t[--_] == p ? this.DM : Math.floor(t[_] * v + (t[_ - 1] + b) * y);
|
|
1732
1732
|
if ((t[_] += s.am(0, U, t, E, 0, d)) < U)
|
|
1733
1733
|
for (s.dlShiftTo(E, x), t.subTo(x, t); t[_] < --U; ) t.subTo(x, t);
|
|
1734
1734
|
}
|
|
@@ -1736,21 +1736,21 @@ function bi(n, e, t) {
|
|
|
1736
1736
|
}
|
|
1737
1737
|
}
|
|
1738
1738
|
}
|
|
1739
|
-
function
|
|
1739
|
+
function Ai(n) {
|
|
1740
1740
|
var e = q();
|
|
1741
1741
|
return this.abs().divRemTo(n, null, e), this.s < 0 && e.compareTo(A.ZERO) > 0 && n.subTo(e, e), e;
|
|
1742
1742
|
}
|
|
1743
|
-
function
|
|
1743
|
+
function Ci() {
|
|
1744
1744
|
if (this.t < 1) return 0;
|
|
1745
1745
|
var n = this[0];
|
|
1746
1746
|
if ((n & 1) == 0) return 0;
|
|
1747
1747
|
var e = n & 3;
|
|
1748
1748
|
return e = e * (2 - (n & 15) * e) & 15, e = e * (2 - (n & 255) * e) & 255, e = e * (2 - ((n & 65535) * e & 65535)) & 65535, e = e * (2 - n * e % this.DV) % this.DV, e > 0 ? this.DV - e : -e;
|
|
1749
1749
|
}
|
|
1750
|
-
function
|
|
1750
|
+
function xi(n) {
|
|
1751
1751
|
return this.compareTo(n) == 0;
|
|
1752
1752
|
}
|
|
1753
|
-
function
|
|
1753
|
+
function Ei(n, e) {
|
|
1754
1754
|
for (var t = 0, r = 0, i = Math.min(n.t, this.t); t < i; )
|
|
1755
1755
|
r += this[t] + n[t], e[t++] = r & this.DM, r >>= this.DB;
|
|
1756
1756
|
if (n.t < this.t) {
|
|
@@ -1764,34 +1764,34 @@ function xi(n, e) {
|
|
|
1764
1764
|
}
|
|
1765
1765
|
e.s = r < 0 ? -1 : 0, r > 0 ? e[t++] = r : r < -1 && (e[t++] = this.DV + r), e.t = t, e.clamp();
|
|
1766
1766
|
}
|
|
1767
|
-
function
|
|
1767
|
+
function Ui(n) {
|
|
1768
1768
|
var e = q();
|
|
1769
1769
|
return this.addTo(n, e), e;
|
|
1770
1770
|
}
|
|
1771
|
-
function
|
|
1771
|
+
function Ti(n) {
|
|
1772
1772
|
var e = q();
|
|
1773
1773
|
return this.subTo(n, e), e;
|
|
1774
1774
|
}
|
|
1775
|
-
function
|
|
1775
|
+
function Ii(n) {
|
|
1776
1776
|
var e = q();
|
|
1777
1777
|
return this.multiplyTo(n, e), e;
|
|
1778
1778
|
}
|
|
1779
|
-
function
|
|
1779
|
+
function Di(n) {
|
|
1780
1780
|
var e = q();
|
|
1781
1781
|
return this.divRemTo(n, e, null), e;
|
|
1782
1782
|
}
|
|
1783
1783
|
function pe(n) {
|
|
1784
1784
|
this.m = n, this.mp = n.invDigit(), this.mpl = this.mp & 32767, this.mph = this.mp >> 15, this.um = (1 << n.DB - 15) - 1, this.mt2 = 2 * n.t;
|
|
1785
1785
|
}
|
|
1786
|
-
function
|
|
1786
|
+
function Ri(n) {
|
|
1787
1787
|
var e = q();
|
|
1788
1788
|
return n.abs().dlShiftTo(this.m.t, e), e.divRemTo(this.m, null, e), n.s < 0 && e.compareTo(A.ZERO) > 0 && this.m.subTo(e, e), e;
|
|
1789
1789
|
}
|
|
1790
|
-
function
|
|
1790
|
+
function ki(n) {
|
|
1791
1791
|
var e = q();
|
|
1792
1792
|
return n.copyTo(e), this.reduce(e), e;
|
|
1793
1793
|
}
|
|
1794
|
-
function
|
|
1794
|
+
function $i(n) {
|
|
1795
1795
|
for (; n.t <= this.mt2; )
|
|
1796
1796
|
n[n.t++] = 0;
|
|
1797
1797
|
for (var e = 0; e < this.m.t; ++e) {
|
|
@@ -1801,18 +1801,18 @@ function ki(n) {
|
|
|
1801
1801
|
}
|
|
1802
1802
|
n.clamp(), n.drShiftTo(this.m.t, n), n.compareTo(this.m) >= 0 && n.subTo(this.m, n);
|
|
1803
1803
|
}
|
|
1804
|
-
function
|
|
1804
|
+
function Pi(n, e) {
|
|
1805
1805
|
n.squareTo(e), this.reduce(e);
|
|
1806
1806
|
}
|
|
1807
|
-
function
|
|
1807
|
+
function Fi(n, e, t) {
|
|
1808
1808
|
n.multiplyTo(e, t), this.reduce(t);
|
|
1809
1809
|
}
|
|
1810
|
-
pe.prototype.convert =
|
|
1811
|
-
pe.prototype.revert =
|
|
1812
|
-
pe.prototype.reduce =
|
|
1813
|
-
pe.prototype.mulTo =
|
|
1814
|
-
pe.prototype.sqrTo =
|
|
1815
|
-
function
|
|
1810
|
+
pe.prototype.convert = Ri;
|
|
1811
|
+
pe.prototype.revert = ki;
|
|
1812
|
+
pe.prototype.reduce = $i;
|
|
1813
|
+
pe.prototype.mulTo = Fi;
|
|
1814
|
+
pe.prototype.sqrTo = Pi;
|
|
1815
|
+
function Bi(n, e, t) {
|
|
1816
1816
|
var r = n.bitLength(), i, s = It(1), o = new pe(e);
|
|
1817
1817
|
if (r <= 0) return s;
|
|
1818
1818
|
r < 18 ? i = 1 : r < 48 ? i = 3 : r < 144 ? i = 4 : r < 768 ? i = 5 : i = 6;
|
|
@@ -1822,12 +1822,12 @@ function Fi(n, e, t) {
|
|
|
1822
1822
|
for (o.sqrTo(l[1], m); h <= p; )
|
|
1823
1823
|
l[h] = q(), o.mulTo(m, l[h - 2], l[h]), h += 2;
|
|
1824
1824
|
}
|
|
1825
|
-
var v = n.t - 1, y,
|
|
1825
|
+
var v = n.t - 1, y, b = !0, _ = q(), E;
|
|
1826
1826
|
for (r = Dt(n[v]) - 1; v >= 0; ) {
|
|
1827
1827
|
for (r >= d ? y = n[v] >> r - d & p : (y = (n[v] & (1 << r + 1) - 1) << d - r, v > 0 && (y |= n[v - 1] >> this.DB + r - d)), h = i; (y & 1) == 0; )
|
|
1828
1828
|
y >>= 1, --h;
|
|
1829
|
-
if ((r -= h) < 0 && (r += this.DB, --v),
|
|
1830
|
-
l[y].copyTo(s),
|
|
1829
|
+
if ((r -= h) < 0 && (r += this.DB, --v), b)
|
|
1830
|
+
l[y].copyTo(s), b = !1;
|
|
1831
1831
|
else {
|
|
1832
1832
|
for (; h > 1; )
|
|
1833
1833
|
o.sqrTo(s, _), o.sqrTo(_, s), h -= 2;
|
|
@@ -1839,40 +1839,40 @@ function Fi(n, e, t) {
|
|
|
1839
1839
|
var x = o.revert(s);
|
|
1840
1840
|
return t(null, x), x;
|
|
1841
1841
|
}
|
|
1842
|
-
A.prototype.copyTo =
|
|
1843
|
-
A.prototype.fromInt =
|
|
1844
|
-
A.prototype.fromString =
|
|
1845
|
-
A.prototype.clamp =
|
|
1846
|
-
A.prototype.dlShiftTo =
|
|
1847
|
-
A.prototype.drShiftTo =
|
|
1848
|
-
A.prototype.lShiftTo =
|
|
1849
|
-
A.prototype.rShiftTo =
|
|
1850
|
-
A.prototype.subTo =
|
|
1851
|
-
A.prototype.multiplyTo =
|
|
1842
|
+
A.prototype.copyTo = oi;
|
|
1843
|
+
A.prototype.fromInt = ai;
|
|
1844
|
+
A.prototype.fromString = ui;
|
|
1845
|
+
A.prototype.clamp = li;
|
|
1846
|
+
A.prototype.dlShiftTo = gi;
|
|
1847
|
+
A.prototype.drShiftTo = mi;
|
|
1848
|
+
A.prototype.lShiftTo = vi;
|
|
1849
|
+
A.prototype.rShiftTo = yi;
|
|
1850
|
+
A.prototype.subTo = wi;
|
|
1851
|
+
A.prototype.multiplyTo = bi;
|
|
1852
1852
|
A.prototype.squareTo = Si;
|
|
1853
|
-
A.prototype.divRemTo =
|
|
1854
|
-
A.prototype.invDigit =
|
|
1855
|
-
A.prototype.addTo =
|
|
1856
|
-
A.prototype.toString =
|
|
1857
|
-
A.prototype.negate =
|
|
1858
|
-
A.prototype.abs =
|
|
1859
|
-
A.prototype.compareTo =
|
|
1860
|
-
A.prototype.bitLength =
|
|
1861
|
-
A.prototype.mod =
|
|
1862
|
-
A.prototype.equals =
|
|
1863
|
-
A.prototype.add =
|
|
1864
|
-
A.prototype.subtract =
|
|
1865
|
-
A.prototype.multiply =
|
|
1866
|
-
A.prototype.divide =
|
|
1867
|
-
A.prototype.modPow =
|
|
1853
|
+
A.prototype.divRemTo = _i;
|
|
1854
|
+
A.prototype.invDigit = Ci;
|
|
1855
|
+
A.prototype.addTo = Ei;
|
|
1856
|
+
A.prototype.toString = ci;
|
|
1857
|
+
A.prototype.negate = hi;
|
|
1858
|
+
A.prototype.abs = fi;
|
|
1859
|
+
A.prototype.compareTo = di;
|
|
1860
|
+
A.prototype.bitLength = pi;
|
|
1861
|
+
A.prototype.mod = Ai;
|
|
1862
|
+
A.prototype.equals = xi;
|
|
1863
|
+
A.prototype.add = Ui;
|
|
1864
|
+
A.prototype.subtract = Ti;
|
|
1865
|
+
A.prototype.multiply = Ii;
|
|
1866
|
+
A.prototype.divide = Di;
|
|
1867
|
+
A.prototype.modPow = Bi;
|
|
1868
1868
|
A.ZERO = It(0);
|
|
1869
1869
|
A.ONE = It(1);
|
|
1870
1870
|
function ot(n) {
|
|
1871
|
-
return R.Buffer.from(new
|
|
1871
|
+
return R.Buffer.from(new Dr().random(n).toString(), "hex");
|
|
1872
1872
|
}
|
|
1873
|
-
var
|
|
1873
|
+
var Mi = /^[89a-f]/i, Oi = "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD129024E088A67CC74020BBEA63B139B22514A08798E3404DDEF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7EDEE386BFB5A899FA5AE9F24117C4B1FE649286651ECE45B3DC2007CB8A163BF0598DA48361C55D39A69163FA8FD24CF5F83655D23DCA3AD961C62F356208552BB9ED529077096966D670C354E4ABC9804F1746C08CA18217C32905E462E36CE3BE39E772C180E86039B2783A2EC07A28FB5C55DF06F4C52C9DE2BCBF6955817183995497CEA956AE515D2261898FA051015728E5A8AAAC42DAD33170D04507A33A85521ABDF1CBA64ECFB850458DBEF0A8AEA71575D060C7DB3970F85A6E1E4C7ABF5AE8CDB0933D71E8C94E04A25619DCEE3D2261AD2EE6BF12FFA06D98A0864D87602733EC86A64521F2B18177B200CBBE117577A615D6C770988C0BAD946E208E24FA074E5AB3143DB5BFCE0FD108E4B82D120A93AD2CAFFFFFFFFFFFFFFFF", Ni = "userAttributes.", ne = /* @__PURE__ */ (function() {
|
|
1874
1874
|
function n(t) {
|
|
1875
|
-
this.N = new A(
|
|
1875
|
+
this.N = new A(Oi, 16), this.g = new A("2", 16), this.k = new A(this.hexHash("" + this.padHex(this.N) + this.padHex(this.g)), 16), this.smallAValue = this.generateRandomSmallA(), this.getLargeAValue(function() {
|
|
1876
1876
|
}), this.infoBits = R.Buffer.from("Caldera Derived Key", "utf8"), this.poolName = t;
|
|
1877
1877
|
}
|
|
1878
1878
|
var e = n.prototype;
|
|
@@ -1933,8 +1933,8 @@ var Bi = /^[89a-f]/i, Mi = "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD12902
|
|
|
1933
1933
|
var d = "" + this.poolName + r + ":" + i, p = this.hash(d), m = new A(this.hexHash(this.padHex(o) + p), 16);
|
|
1934
1934
|
this.calculateS(m, s, function(v, y) {
|
|
1935
1935
|
v && l(v, null);
|
|
1936
|
-
var
|
|
1937
|
-
l(null,
|
|
1936
|
+
var b = h.computehkdf(R.Buffer.from(h.padHex(y), "hex"), R.Buffer.from(h.padHex(h.UValue), "hex"));
|
|
1937
|
+
l(null, b);
|
|
1938
1938
|
});
|
|
1939
1939
|
}, e.calculateS = function(r, i, s) {
|
|
1940
1940
|
var o = this;
|
|
@@ -1946,12 +1946,12 @@ var Bi = /^[89a-f]/i, Mi = "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD12902
|
|
|
1946
1946
|
});
|
|
1947
1947
|
});
|
|
1948
1948
|
}, e.getNewPasswordRequiredChallengeUserAttributePrefix = function() {
|
|
1949
|
-
return
|
|
1949
|
+
return Ni;
|
|
1950
1950
|
}, e.padHex = function(r) {
|
|
1951
1951
|
if (!(r instanceof A))
|
|
1952
1952
|
throw new Error("Not a BigInteger");
|
|
1953
1953
|
var i = r.compareTo(A.ZERO) < 0, s = r.abs().toString(16);
|
|
1954
|
-
if (s = s.length % 2 !== 0 ? "0" + s : s, s =
|
|
1954
|
+
if (s = s.length % 2 !== 0 ? "0" + s : s, s = Mi.test(s) ? "00" + s : s, i) {
|
|
1955
1955
|
var o = s.split("").map(function(h) {
|
|
1956
1956
|
var d = ~parseInt(h, 16) & 15;
|
|
1957
1957
|
return "0123456789ABCDEF".charAt(d);
|
|
@@ -1961,7 +1961,7 @@ var Bi = /^[89a-f]/i, Mi = "FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD12902
|
|
|
1961
1961
|
return s;
|
|
1962
1962
|
}, n;
|
|
1963
1963
|
})();
|
|
1964
|
-
var
|
|
1964
|
+
var Pr = /* @__PURE__ */ (function() {
|
|
1965
1965
|
function n(t) {
|
|
1966
1966
|
this.jwtToken = t || "", this.payload = this.decodePayload();
|
|
1967
1967
|
}
|
|
@@ -1981,7 +1981,7 @@ var $r = /* @__PURE__ */ (function() {
|
|
|
1981
1981
|
}
|
|
1982
1982
|
}, n;
|
|
1983
1983
|
})();
|
|
1984
|
-
function
|
|
1984
|
+
function qi(n, e) {
|
|
1985
1985
|
n.prototype = Object.create(e.prototype), n.prototype.constructor = n, pt(n, e);
|
|
1986
1986
|
}
|
|
1987
1987
|
function pt(n, e) {
|
|
@@ -1994,9 +1994,9 @@ var gt = /* @__PURE__ */ (function(n) {
|
|
|
1994
1994
|
var r = t === void 0 ? {} : t, i = r.AccessToken;
|
|
1995
1995
|
return n.call(this, i || "") || this;
|
|
1996
1996
|
}
|
|
1997
|
-
return
|
|
1998
|
-
})(
|
|
1999
|
-
function
|
|
1997
|
+
return qi(e, n), e;
|
|
1998
|
+
})(Pr);
|
|
1999
|
+
function Li(n, e) {
|
|
2000
2000
|
n.prototype = Object.create(e.prototype), n.prototype.constructor = n, mt(n, e);
|
|
2001
2001
|
}
|
|
2002
2002
|
function mt(n, e) {
|
|
@@ -2009,8 +2009,8 @@ var vt = /* @__PURE__ */ (function(n) {
|
|
|
2009
2009
|
var r = t === void 0 ? {} : t, i = r.IdToken;
|
|
2010
2010
|
return n.call(this, i || "") || this;
|
|
2011
2011
|
}
|
|
2012
|
-
return
|
|
2013
|
-
})(
|
|
2012
|
+
return Li(e, n), e;
|
|
2013
|
+
})(Pr);
|
|
2014
2014
|
var yt = /* @__PURE__ */ (function() {
|
|
2015
2015
|
function n(t) {
|
|
2016
2016
|
var r = t === void 0 ? {} : t, i = r.RefreshToken;
|
|
@@ -2020,12 +2020,12 @@ var yt = /* @__PURE__ */ (function() {
|
|
|
2020
2020
|
return e.getToken = function() {
|
|
2021
2021
|
return this.token;
|
|
2022
2022
|
}, n;
|
|
2023
|
-
})(),
|
|
2024
|
-
var
|
|
2025
|
-
userAgent:
|
|
2023
|
+
})(), Ki = "5.0.4";
|
|
2024
|
+
var Vi = "aws-amplify/" + Ki, Fr = {
|
|
2025
|
+
userAgent: Vi,
|
|
2026
2026
|
isReactNative: typeof navigator < "u" && navigator.product === "ReactNative"
|
|
2027
|
-
},
|
|
2028
|
-
return
|
|
2027
|
+
}, ji = function() {
|
|
2028
|
+
return Fr.userAgent;
|
|
2029
2029
|
};
|
|
2030
2030
|
var wt = /* @__PURE__ */ (function() {
|
|
2031
2031
|
function n(t) {
|
|
@@ -2051,12 +2051,12 @@ var wt = /* @__PURE__ */ (function() {
|
|
|
2051
2051
|
return i < this.accessToken.getExpiration() && i < this.idToken.getExpiration();
|
|
2052
2052
|
}, n;
|
|
2053
2053
|
})();
|
|
2054
|
-
var
|
|
2054
|
+
var Hi = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], zi = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], bt = /* @__PURE__ */ (function() {
|
|
2055
2055
|
function n() {
|
|
2056
2056
|
}
|
|
2057
2057
|
var e = n.prototype;
|
|
2058
2058
|
return e.getNowString = function() {
|
|
2059
|
-
var r = /* @__PURE__ */ new Date(), i =
|
|
2059
|
+
var r = /* @__PURE__ */ new Date(), i = zi[r.getUTCDay()], s = Hi[r.getUTCMonth()], o = r.getUTCDate(), l = r.getUTCHours();
|
|
2060
2060
|
l < 10 && (l = "0" + l);
|
|
2061
2061
|
var h = r.getUTCMinutes();
|
|
2062
2062
|
h < 10 && (h = "0" + h);
|
|
@@ -2066,7 +2066,7 @@ var ji = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct",
|
|
|
2066
2066
|
return m;
|
|
2067
2067
|
}, n;
|
|
2068
2068
|
})();
|
|
2069
|
-
var
|
|
2069
|
+
var Br = /* @__PURE__ */ (function() {
|
|
2070
2070
|
function n(t) {
|
|
2071
2071
|
var r = t === void 0 ? {} : t, i = r.Name, s = r.Value;
|
|
2072
2072
|
this.Name = i || "", this.Value = s || "";
|
|
@@ -2089,7 +2089,7 @@ var Fr = /* @__PURE__ */ (function() {
|
|
|
2089
2089
|
};
|
|
2090
2090
|
}, n;
|
|
2091
2091
|
})();
|
|
2092
|
-
var te = {},
|
|
2092
|
+
var te = {}, Wi = /* @__PURE__ */ (function() {
|
|
2093
2093
|
function n() {
|
|
2094
2094
|
}
|
|
2095
2095
|
return n.setItem = function(t, r) {
|
|
@@ -2101,12 +2101,12 @@ var te = {}, zi = /* @__PURE__ */ (function() {
|
|
|
2101
2101
|
}, n.clear = function() {
|
|
2102
2102
|
return te = {}, te;
|
|
2103
2103
|
}, n;
|
|
2104
|
-
})(),
|
|
2104
|
+
})(), Mr = /* @__PURE__ */ (function() {
|
|
2105
2105
|
function n() {
|
|
2106
2106
|
try {
|
|
2107
2107
|
this.storageWindow = window.localStorage, this.storageWindow.setItem("aws.cognito.test-ls", 1), this.storageWindow.removeItem("aws.cognito.test-ls");
|
|
2108
2108
|
} catch {
|
|
2109
|
-
this.storageWindow =
|
|
2109
|
+
this.storageWindow = Wi;
|
|
2110
2110
|
}
|
|
2111
2111
|
}
|
|
2112
2112
|
var e = n.prototype;
|
|
@@ -2114,11 +2114,11 @@ var te = {}, zi = /* @__PURE__ */ (function() {
|
|
|
2114
2114
|
return this.storageWindow;
|
|
2115
2115
|
}, n;
|
|
2116
2116
|
})();
|
|
2117
|
-
var
|
|
2117
|
+
var Yi = typeof navigator < "u", ur = Yi ? Fr.isReactNative ? "react-native" : navigator.userAgent : "nodejs", St = /* @__PURE__ */ (function() {
|
|
2118
2118
|
function n(t) {
|
|
2119
2119
|
if (t == null || t.Username == null || t.Pool == null)
|
|
2120
2120
|
throw new Error("Username and Pool information are required.");
|
|
2121
|
-
this.username = t.Username || "", this.pool = t.Pool, this.Session = null, this.client = t.Pool.client, this.signInUserSession = null, this.authenticationFlowType = "USER_SRP_AUTH", this.storage = t.Storage || new
|
|
2121
|
+
this.username = t.Username || "", this.pool = t.Pool, this.Session = null, this.client = t.Pool.client, this.signInUserSession = null, this.authenticationFlowType = "USER_SRP_AUTH", this.storage = t.Storage || new Mr().getStorage(), this.keyPrefix = "CognitoIdentityServiceProvider." + this.pool.getClientId(), this.userDataKey = this.keyPrefix + "." + this.username + ".userData";
|
|
2122
2122
|
}
|
|
2123
2123
|
var e = n.prototype;
|
|
2124
2124
|
return e.setSignInUserSession = function(r) {
|
|
@@ -2149,16 +2149,16 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2149
2149
|
}, e.authenticateUser = function(r, i) {
|
|
2150
2150
|
return this.authenticationFlowType === "USER_PASSWORD_AUTH" ? this.authenticateUserPlainUsernamePassword(r, i) : this.authenticationFlowType === "USER_SRP_AUTH" || this.authenticationFlowType === "CUSTOM_AUTH" ? this.authenticateUserDefaultAuth(r, i) : i.onFailure(new Error("Authentication flow type is invalid."));
|
|
2151
2151
|
}, e.authenticateUserDefaultAuth = function(r, i) {
|
|
2152
|
-
var s = this, o = new ne(this.pool.getUserPoolName()), l = new
|
|
2152
|
+
var s = this, o = new ne(this.pool.getUserPoolName()), l = new bt(), h, d, p = {};
|
|
2153
2153
|
this.deviceKey != null && (p.DEVICE_KEY = this.deviceKey), p.USERNAME = this.username, o.getLargeAValue(function(m, v) {
|
|
2154
2154
|
m && i.onFailure(m), p.SRP_A = v.toString(16), s.authenticationFlowType === "CUSTOM_AUTH" && (p.CHALLENGE_NAME = "SRP_A");
|
|
2155
|
-
var y = Object.keys(r.getValidationData()).length !== 0 ? r.getValidationData() : r.getClientMetadata(),
|
|
2155
|
+
var y = Object.keys(r.getValidationData()).length !== 0 ? r.getValidationData() : r.getClientMetadata(), b = {
|
|
2156
2156
|
AuthFlow: s.authenticationFlowType,
|
|
2157
2157
|
ClientId: s.pool.getClientId(),
|
|
2158
2158
|
AuthParameters: p,
|
|
2159
2159
|
ClientMetadata: y
|
|
2160
2160
|
};
|
|
2161
|
-
s.getUserContextData(s.username) && (
|
|
2161
|
+
s.getUserContextData(s.username) && (b.UserContextData = s.getUserContextData(s.username)), s.client.request("InitiateAuth", b, function(_, E) {
|
|
2162
2162
|
if (_)
|
|
2163
2163
|
return i.onFailure(_);
|
|
2164
2164
|
var x = E.ChallengeParameters;
|
|
@@ -2227,8 +2227,8 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2227
2227
|
return;
|
|
2228
2228
|
}
|
|
2229
2229
|
this.signInUserSession = this.getCognitoUserSession(r.AuthenticationResult), this.challengeName = l, this.cacheTokens();
|
|
2230
|
-
var
|
|
2231
|
-
if (
|
|
2230
|
+
var b = r.AuthenticationResult.NewDeviceMetadata;
|
|
2231
|
+
if (b == null)
|
|
2232
2232
|
return s.onSuccess(this.signInUserSession);
|
|
2233
2233
|
i.generateHashDevice(r.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey, r.AuthenticationResult.NewDeviceMetadata.DeviceKey, function(_) {
|
|
2234
2234
|
if (_)
|
|
@@ -2237,8 +2237,8 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2237
2237
|
Salt: R.Buffer.from(i.getSaltDevices(), "hex").toString("base64"),
|
|
2238
2238
|
PasswordVerifier: R.Buffer.from(i.getVerifierDevices(), "hex").toString("base64")
|
|
2239
2239
|
};
|
|
2240
|
-
o.verifierDevices = E.PasswordVerifier, o.deviceGroupKey =
|
|
2241
|
-
DeviceKey:
|
|
2240
|
+
o.verifierDevices = E.PasswordVerifier, o.deviceGroupKey = b.DeviceGroupKey, o.randomPassword = i.getRandomPassword(), o.client.request("ConfirmDevice", {
|
|
2241
|
+
DeviceKey: b.DeviceKey,
|
|
2242
2242
|
AccessToken: o.signInUserSession.getAccessToken().getJwtToken(),
|
|
2243
2243
|
DeviceSecretVerifierConfig: E,
|
|
2244
2244
|
DeviceName: ur
|
|
@@ -2265,7 +2265,7 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2265
2265
|
return v ? s.onFailure(v) : l.authenticateUserInternal(y, h, s);
|
|
2266
2266
|
});
|
|
2267
2267
|
}, e.getDeviceResponse = function(r, i) {
|
|
2268
|
-
var s = this, o = new ne(this.deviceGroupKey), l = new
|
|
2268
|
+
var s = this, o = new ne(this.deviceGroupKey), l = new bt(), h = {};
|
|
2269
2269
|
h.USERNAME = this.username, h.DEVICE_KEY = this.deviceKey, o.getLargeAValue(function(d, p) {
|
|
2270
2270
|
d && r.onFailure(d), h.SRP_A = p.toString(16);
|
|
2271
2271
|
var m = {
|
|
@@ -2278,14 +2278,14 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2278
2278
|
s.getUserContextData() && (m.UserContextData = s.getUserContextData()), s.client.request("RespondToAuthChallenge", m, function(v, y) {
|
|
2279
2279
|
if (v)
|
|
2280
2280
|
return r.onFailure(v);
|
|
2281
|
-
var
|
|
2281
|
+
var b = y.ChallengeParameters, _ = new A(b.SRP_B, 16), E = new A(b.SALT, 16);
|
|
2282
2282
|
o.getPasswordAuthenticationKey(s.deviceKey, s.randomPassword, _, E, function(x, U) {
|
|
2283
2283
|
if (x)
|
|
2284
2284
|
return r.onFailure(x);
|
|
2285
|
-
var P = l.getNowString(), B = R.Buffer.concat([R.Buffer.from(s.deviceGroupKey, "utf8"), R.Buffer.from(s.deviceKey, "utf8"), R.Buffer.from(
|
|
2285
|
+
var P = l.getNowString(), B = R.Buffer.concat([R.Buffer.from(s.deviceGroupKey, "utf8"), R.Buffer.from(s.deviceKey, "utf8"), R.Buffer.from(b.SECRET_BLOCK, "base64"), R.Buffer.from(P, "utf8")]), F = new Ie.Sha256(U);
|
|
2286
2286
|
F.update(B);
|
|
2287
2287
|
var X = F.digestSync(), ge = R.Buffer.from(X).toString("base64"), G = {};
|
|
2288
|
-
G.USERNAME = s.username, G.PASSWORD_CLAIM_SECRET_BLOCK =
|
|
2288
|
+
G.USERNAME = s.username, G.PASSWORD_CLAIM_SECRET_BLOCK = b.SECRET_BLOCK, G.TIMESTAMP = P, G.PASSWORD_CLAIM_SIGNATURE = ge, G.DEVICE_KEY = s.deviceKey;
|
|
2289
2289
|
var K = {
|
|
2290
2290
|
ChallengeName: "DEVICE_PASSWORD_VERIFIER",
|
|
2291
2291
|
ClientId: s.pool.getClientId(),
|
|
@@ -2346,15 +2346,15 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2346
2346
|
}
|
|
2347
2347
|
if (l.signInUserSession = l.getCognitoUserSession(v.AuthenticationResult), l.cacheTokens(), v.AuthenticationResult.NewDeviceMetadata == null)
|
|
2348
2348
|
return i.onSuccess(l.signInUserSession);
|
|
2349
|
-
var
|
|
2350
|
-
|
|
2349
|
+
var b = new ne(l.pool.getUserPoolName());
|
|
2350
|
+
b.generateHashDevice(v.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey, v.AuthenticationResult.NewDeviceMetadata.DeviceKey, function(_) {
|
|
2351
2351
|
if (_)
|
|
2352
2352
|
return i.onFailure(_);
|
|
2353
2353
|
var E = {
|
|
2354
|
-
Salt: R.Buffer.from(
|
|
2355
|
-
PasswordVerifier: R.Buffer.from(
|
|
2354
|
+
Salt: R.Buffer.from(b.getSaltDevices(), "hex").toString("base64"),
|
|
2355
|
+
PasswordVerifier: R.Buffer.from(b.getVerifierDevices(), "hex").toString("base64")
|
|
2356
2356
|
};
|
|
2357
|
-
l.verifierDevices = E.PasswordVerifier, l.deviceGroupKey = v.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey, l.randomPassword =
|
|
2357
|
+
l.verifierDevices = E.PasswordVerifier, l.deviceGroupKey = v.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey, l.randomPassword = b.getRandomPassword(), l.client.request("ConfirmDevice", {
|
|
2358
2358
|
DeviceKey: v.AuthenticationResult.NewDeviceMetadata.DeviceKey,
|
|
2359
2359
|
AccessToken: l.signInUserSession.getAccessToken().getJwtToken(),
|
|
2360
2360
|
DeviceSecretVerifierConfig: E,
|
|
@@ -2445,7 +2445,7 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2445
2445
|
var h = {
|
|
2446
2446
|
Name: s.UserAttributes[l].Name,
|
|
2447
2447
|
Value: s.UserAttributes[l].Value
|
|
2448
|
-
}, d = new
|
|
2448
|
+
}, d = new Br(h);
|
|
2449
2449
|
o.push(d);
|
|
2450
2450
|
}
|
|
2451
2451
|
return r(null, o);
|
|
@@ -2543,12 +2543,12 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2543
2543
|
AccessToken: this.storage.getItem(l)
|
|
2544
2544
|
}), v = new yt({
|
|
2545
2545
|
RefreshToken: this.storage.getItem(h)
|
|
2546
|
-
}), y = parseInt(this.storage.getItem(d), 0) || 0,
|
|
2546
|
+
}), y = parseInt(this.storage.getItem(d), 0) || 0, b = {
|
|
2547
2547
|
IdToken: p,
|
|
2548
2548
|
AccessToken: m,
|
|
2549
2549
|
RefreshToken: v,
|
|
2550
2550
|
ClockDrift: y
|
|
2551
|
-
}, _ = new wt(
|
|
2551
|
+
}, _ = new wt(b);
|
|
2552
2552
|
if (_.isValid())
|
|
2553
2553
|
return this.signInUserSession = _, r(null, this.signInUserSession);
|
|
2554
2554
|
if (!v.getToken())
|
|
@@ -2571,11 +2571,11 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2571
2571
|
AuthParameters: h,
|
|
2572
2572
|
ClientMetadata: s
|
|
2573
2573
|
};
|
|
2574
|
-
this.getUserContextData() && (v.UserContextData = this.getUserContextData()), this.client.requestWithRetry("InitiateAuth", v, function(y,
|
|
2574
|
+
this.getUserContextData() && (v.UserContextData = this.getUserContextData()), this.client.requestWithRetry("InitiateAuth", v, function(y, b) {
|
|
2575
2575
|
if (y)
|
|
2576
2576
|
return y.code === "NotAuthorizedException" && o.clearCachedUser(), l(y, null);
|
|
2577
|
-
if (
|
|
2578
|
-
var _ =
|
|
2577
|
+
if (b) {
|
|
2578
|
+
var _ = b.AuthenticationResult;
|
|
2579
2579
|
return Object.prototype.hasOwnProperty.call(_, "RefreshToken") || (_.RefreshToken = r.getToken()), o.signInUserSession = o.getCognitoUserSession(_), o.cacheTokens(), l(null, o.signInUserSession);
|
|
2580
2580
|
}
|
|
2581
2581
|
});
|
|
@@ -2825,7 +2825,7 @@ var Wi = typeof navigator < "u", ur = Wi ? Pr.isReactNative ? "react-native" : n
|
|
|
2825
2825
|
});
|
|
2826
2826
|
}, n;
|
|
2827
2827
|
})();
|
|
2828
|
-
function
|
|
2828
|
+
function Gi(n, e) {
|
|
2829
2829
|
return e = e || {}, new Promise(function(t, r) {
|
|
2830
2830
|
var i = new XMLHttpRequest(), s = [], o = [], l = {}, h = function() {
|
|
2831
2831
|
return { ok: (i.status / 100 | 0) == 2, statusText: i.statusText, status: i.status, url: i.responseURL, text: function() {
|
|
@@ -2852,60 +2852,60 @@ function Yi(n, e) {
|
|
|
2852
2852
|
i.send(e.body || null);
|
|
2853
2853
|
});
|
|
2854
2854
|
}
|
|
2855
|
-
const
|
|
2855
|
+
const Ji = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2856
2856
|
__proto__: null,
|
|
2857
|
-
default:
|
|
2858
|
-
}, Symbol.toStringTag, { value: "Module" })), lr = /* @__PURE__ */ Ut(
|
|
2857
|
+
default: Gi
|
|
2858
|
+
}, Symbol.toStringTag, { value: "Module" })), lr = /* @__PURE__ */ Ut(Ji);
|
|
2859
2859
|
var at, cr;
|
|
2860
|
-
function
|
|
2860
|
+
function Zi() {
|
|
2861
2861
|
return cr || (cr = 1, at = self.fetch || (self.fetch = lr.default || lr)), at;
|
|
2862
2862
|
}
|
|
2863
|
-
|
|
2863
|
+
Zi();
|
|
2864
2864
|
function j() {
|
|
2865
2865
|
}
|
|
2866
|
-
j.prototype.userAgent =
|
|
2867
|
-
var
|
|
2866
|
+
j.prototype.userAgent = ji();
|
|
2867
|
+
var Xi = function(e) {
|
|
2868
2868
|
e && (j.prototype.userAgent && !j.prototype.userAgent.includes(e) && (j.prototype.userAgent = j.prototype.userAgent.concat(" ", e)), (!j.prototype.userAgent || j.prototype.userAgent === "") && (j.prototype.userAgent = e));
|
|
2869
|
-
},
|
|
2869
|
+
}, Qi = function(e) {
|
|
2870
2870
|
var t = j.category ? " " + j.category : "", r = j.framework ? " framework/" + j.framework : "", i = "" + j.prototype.userAgent + t + r;
|
|
2871
2871
|
return i;
|
|
2872
2872
|
};
|
|
2873
|
-
function
|
|
2873
|
+
function es(n, e) {
|
|
2874
2874
|
n.prototype = Object.create(e.prototype), n.prototype.constructor = n, ke(n, e);
|
|
2875
2875
|
}
|
|
2876
2876
|
function _t(n) {
|
|
2877
2877
|
var e = typeof Map == "function" ? /* @__PURE__ */ new Map() : void 0;
|
|
2878
2878
|
return _t = function(r) {
|
|
2879
|
-
if (r === null || !
|
|
2879
|
+
if (r === null || !rs(r)) return r;
|
|
2880
2880
|
if (typeof r != "function") throw new TypeError("Super expression must either be null or a function");
|
|
2881
2881
|
if (e !== void 0) {
|
|
2882
2882
|
if (e.has(r)) return e.get(r);
|
|
2883
2883
|
e.set(r, i);
|
|
2884
2884
|
}
|
|
2885
2885
|
function i() {
|
|
2886
|
-
return
|
|
2886
|
+
return ts(r, arguments, At(this).constructor);
|
|
2887
2887
|
}
|
|
2888
2888
|
return i.prototype = Object.create(r.prototype, { constructor: { value: i, enumerable: !1, writable: !0, configurable: !0 } }), ke(i, r);
|
|
2889
2889
|
}, _t(n);
|
|
2890
2890
|
}
|
|
2891
|
-
function
|
|
2892
|
-
if (
|
|
2891
|
+
function ts(n, e, t) {
|
|
2892
|
+
if (Or()) return Reflect.construct.apply(null, arguments);
|
|
2893
2893
|
var r = [null];
|
|
2894
2894
|
r.push.apply(r, e);
|
|
2895
2895
|
var i = new (n.bind.apply(n, r))();
|
|
2896
2896
|
return t && ke(i, t.prototype), i;
|
|
2897
2897
|
}
|
|
2898
|
-
function
|
|
2898
|
+
function Or() {
|
|
2899
2899
|
try {
|
|
2900
2900
|
var n = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
|
|
2901
2901
|
}));
|
|
2902
2902
|
} catch {
|
|
2903
2903
|
}
|
|
2904
|
-
return (
|
|
2904
|
+
return (Or = function() {
|
|
2905
2905
|
return !!n;
|
|
2906
2906
|
})();
|
|
2907
2907
|
}
|
|
2908
|
-
function
|
|
2908
|
+
function rs(n) {
|
|
2909
2909
|
try {
|
|
2910
2910
|
return Function.toString.call(n).indexOf("[native code]") !== -1;
|
|
2911
2911
|
} catch {
|
|
@@ -2922,13 +2922,13 @@ function At(n) {
|
|
|
2922
2922
|
return e.__proto__ || Object.getPrototypeOf(e);
|
|
2923
2923
|
}, At(n);
|
|
2924
2924
|
}
|
|
2925
|
-
var
|
|
2925
|
+
var ns = /* @__PURE__ */ (function(n) {
|
|
2926
2926
|
function e(t, r, i, s) {
|
|
2927
2927
|
var o;
|
|
2928
2928
|
return o = n.call(this, t) || this, o.code = r, o.name = i, o.statusCode = s, o;
|
|
2929
2929
|
}
|
|
2930
|
-
return
|
|
2931
|
-
})(/* @__PURE__ */ _t(Error)),
|
|
2930
|
+
return es(e, n), e;
|
|
2931
|
+
})(/* @__PURE__ */ _t(Error)), is = /* @__PURE__ */ (function() {
|
|
2932
2932
|
function n(t, r, i) {
|
|
2933
2933
|
this.endpoint = r || "https://cognito-idp." + t + ".amazonaws.com/";
|
|
2934
2934
|
var s = i || {}, o = s.credentials;
|
|
@@ -2941,12 +2941,12 @@ var rs = /* @__PURE__ */ (function(n) {
|
|
|
2941
2941
|
var s = this;
|
|
2942
2942
|
return new Promise(function(o, l) {
|
|
2943
2943
|
s.request(r, i, function(h, d) {
|
|
2944
|
-
h ? l(new
|
|
2944
|
+
h ? l(new ns(h.message, h.code, h.name, h.statusCode)) : o(d);
|
|
2945
2945
|
});
|
|
2946
2946
|
});
|
|
2947
2947
|
}, e.requestWithRetry = function(r, i, s) {
|
|
2948
2948
|
var o = this, l = 5 * 1e3;
|
|
2949
|
-
|
|
2949
|
+
as(function(h) {
|
|
2950
2950
|
return new Promise(function(d, p) {
|
|
2951
2951
|
o.request(r, h, function(m, v) {
|
|
2952
2952
|
m ? p(m) : d(v);
|
|
@@ -2961,7 +2961,7 @@ var rs = /* @__PURE__ */ (function(n) {
|
|
|
2961
2961
|
var o = {
|
|
2962
2962
|
"Content-Type": "application/x-amz-json-1.1",
|
|
2963
2963
|
"X-Amz-Target": "AWSCognitoIdentityProviderService." + r,
|
|
2964
|
-
"X-Amz-User-Agent":
|
|
2964
|
+
"X-Amz-User-Agent": Qi(),
|
|
2965
2965
|
"Cache-Control": "no-store"
|
|
2966
2966
|
}, l = Object.assign({}, this.fetchOptions, {
|
|
2967
2967
|
headers: o,
|
|
@@ -2996,45 +2996,45 @@ var rs = /* @__PURE__ */ (function(n) {
|
|
|
2996
2996
|
})(), Ve = {
|
|
2997
2997
|
debug: function() {
|
|
2998
2998
|
}
|
|
2999
|
-
},
|
|
2999
|
+
}, ss = function(e) {
|
|
3000
3000
|
var t = "nonRetryable";
|
|
3001
3001
|
return e && e[t];
|
|
3002
3002
|
};
|
|
3003
|
-
function
|
|
3003
|
+
function Nr(n, e, t, r) {
|
|
3004
3004
|
if (r === void 0 && (r = 1), typeof n != "function")
|
|
3005
3005
|
throw Error("functionToRetry must be a function");
|
|
3006
3006
|
return Ve.debug(n.name + " attempt #" + r + " with args: " + JSON.stringify(e)), n.apply(void 0, e).catch(function(i) {
|
|
3007
|
-
if (Ve.debug("error on " + n.name, i),
|
|
3007
|
+
if (Ve.debug("error on " + n.name, i), ss(i))
|
|
3008
3008
|
throw Ve.debug(n.name + " non retryable error", i), i;
|
|
3009
3009
|
var s = t(r, e, i);
|
|
3010
3010
|
if (Ve.debug(n.name + " retrying in " + s + " ms"), s !== !1)
|
|
3011
3011
|
return new Promise(function(o) {
|
|
3012
3012
|
return setTimeout(o, s);
|
|
3013
3013
|
}).then(function() {
|
|
3014
|
-
return
|
|
3014
|
+
return Nr(n, e, t, r + 1);
|
|
3015
3015
|
});
|
|
3016
3016
|
throw i;
|
|
3017
3017
|
});
|
|
3018
3018
|
}
|
|
3019
|
-
function
|
|
3019
|
+
function os(n) {
|
|
3020
3020
|
var e = 100, t = 100;
|
|
3021
3021
|
return function(r) {
|
|
3022
3022
|
var i = Math.pow(2, r) * e + t * Math.random();
|
|
3023
3023
|
return i > n ? !1 : i;
|
|
3024
3024
|
};
|
|
3025
3025
|
}
|
|
3026
|
-
function
|
|
3027
|
-
return
|
|
3026
|
+
function as(n, e, t) {
|
|
3027
|
+
return Nr(n, e, os(t));
|
|
3028
3028
|
}
|
|
3029
|
-
var
|
|
3029
|
+
var us = 55, ls = /* @__PURE__ */ (function() {
|
|
3030
3030
|
function n(t, r) {
|
|
3031
3031
|
var i = t || {}, s = i.UserPoolId, o = i.ClientId, l = i.endpoint, h = i.fetchOptions, d = i.AdvancedSecurityDataCollectionFlag;
|
|
3032
3032
|
if (!s || !o)
|
|
3033
3033
|
throw new Error("Both UserPoolId and ClientId are required.");
|
|
3034
|
-
if (s.length >
|
|
3034
|
+
if (s.length > us || !/^[\w-]+_[0-9a-zA-Z]+$/.test(s))
|
|
3035
3035
|
throw new Error("Invalid UserPoolId format.");
|
|
3036
3036
|
var p = s.split("_")[0];
|
|
3037
|
-
this.userPoolId = s, this.clientId = o, this.client = new
|
|
3037
|
+
this.userPoolId = s, this.clientId = o, this.client = new is(p, l, h), this.advancedSecurityDataCollectionFlag = d !== !1, this.storage = t.Storage || new Mr().getStorage(), r && (this.wrapRefreshSessionCallback = r);
|
|
3038
3038
|
}
|
|
3039
3039
|
var e = n.prototype;
|
|
3040
3040
|
return e.getUserPoolId = function() {
|
|
@@ -3059,13 +3059,13 @@ var as = 55, us = /* @__PURE__ */ (function() {
|
|
|
3059
3059
|
Username: r,
|
|
3060
3060
|
Pool: d,
|
|
3061
3061
|
Storage: d.storage
|
|
3062
|
-
},
|
|
3063
|
-
user: new
|
|
3062
|
+
}, b = {
|
|
3063
|
+
user: new St(y),
|
|
3064
3064
|
userConfirmed: v.UserConfirmed,
|
|
3065
3065
|
userSub: v.UserSub,
|
|
3066
3066
|
codeDeliveryDetails: v.CodeDeliveryDetails
|
|
3067
3067
|
};
|
|
3068
|
-
return l(null,
|
|
3068
|
+
return l(null, b);
|
|
3069
3069
|
});
|
|
3070
3070
|
}, e.getCurrentUser = function() {
|
|
3071
3071
|
var r = "CognitoIdentityServiceProvider." + this.clientId + ".LastAuthUser", i = this.storage.getItem(r);
|
|
@@ -3075,7 +3075,7 @@ var as = 55, us = /* @__PURE__ */ (function() {
|
|
|
3075
3075
|
Pool: this,
|
|
3076
3076
|
Storage: this.storage
|
|
3077
3077
|
};
|
|
3078
|
-
return new
|
|
3078
|
+
return new St(s);
|
|
3079
3079
|
}
|
|
3080
3080
|
return null;
|
|
3081
3081
|
}, e.getUserContextData = function(r) {
|
|
@@ -3102,7 +3102,7 @@ function je(n) {
|
|
|
3102
3102
|
}
|
|
3103
3103
|
return n;
|
|
3104
3104
|
}
|
|
3105
|
-
var
|
|
3105
|
+
var cs = {
|
|
3106
3106
|
read: function(n) {
|
|
3107
3107
|
return n[0] === '"' && (n = n.slice(1, -1)), n.replace(/(%[\dA-F]{2})+/gi, decodeURIComponent);
|
|
3108
3108
|
},
|
|
@@ -3163,7 +3163,7 @@ function Ct(n, e) {
|
|
|
3163
3163
|
}
|
|
3164
3164
|
);
|
|
3165
3165
|
}
|
|
3166
|
-
var xe = Ct(
|
|
3166
|
+
var xe = Ct(cs, { path: "/" }), hs = /* @__PURE__ */ (function() {
|
|
3167
3167
|
function n(t) {
|
|
3168
3168
|
if (t === void 0 && (t = {}), t.domain && (this.domain = t.domain), t.path ? this.path = t.path : this.path = "/", Object.prototype.hasOwnProperty.call(t, "expires") ? this.expires = t.expires : this.expires = 365, Object.prototype.hasOwnProperty.call(t, "secure") ? this.secure = t.secure : this.secure = !0, Object.prototype.hasOwnProperty.call(t, "sameSite")) {
|
|
3169
3169
|
if (!["strict", "lax", "none"].includes(t.sameSite))
|
|
@@ -3200,24 +3200,24 @@ var xe = Ct(ls, { path: "/" }), cs = /* @__PURE__ */ (function() {
|
|
|
3200
3200
|
return {};
|
|
3201
3201
|
}, n;
|
|
3202
3202
|
})();
|
|
3203
|
-
const
|
|
3203
|
+
const fs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3204
3204
|
__proto__: null,
|
|
3205
|
-
AuthenticationDetails:
|
|
3205
|
+
AuthenticationDetails: hn,
|
|
3206
3206
|
AuthenticationHelper: ne,
|
|
3207
3207
|
CognitoAccessToken: gt,
|
|
3208
3208
|
CognitoIdToken: vt,
|
|
3209
3209
|
CognitoRefreshToken: yt,
|
|
3210
|
-
CognitoUser:
|
|
3211
|
-
CognitoUserAttribute:
|
|
3212
|
-
CognitoUserPool:
|
|
3210
|
+
CognitoUser: St,
|
|
3211
|
+
CognitoUserAttribute: Br,
|
|
3212
|
+
CognitoUserPool: ls,
|
|
3213
3213
|
CognitoUserSession: wt,
|
|
3214
|
-
CookieStorage:
|
|
3215
|
-
DateHelper:
|
|
3216
|
-
WordArray:
|
|
3217
|
-
appendToCognitoUserAgent:
|
|
3214
|
+
CookieStorage: hs,
|
|
3215
|
+
DateHelper: bt,
|
|
3216
|
+
WordArray: Dr,
|
|
3217
|
+
appendToCognitoUserAgent: Xi
|
|
3218
3218
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
3219
3219
|
const ze = globalThis, Rt = ze.ShadowRoot && (ze.ShadyCSS === void 0 || ze.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, kt = /* @__PURE__ */ Symbol(), hr = /* @__PURE__ */ new WeakMap();
|
|
3220
|
-
let
|
|
3220
|
+
let qr = class {
|
|
3221
3221
|
constructor(e, t, r) {
|
|
3222
3222
|
if (this._$cssResult$ = !0, r !== kt) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
3223
3223
|
this.cssText = e, this.t = t;
|
|
@@ -3235,14 +3235,14 @@ let Nr = class {
|
|
|
3235
3235
|
return this.cssText;
|
|
3236
3236
|
}
|
|
3237
3237
|
};
|
|
3238
|
-
const
|
|
3238
|
+
const ds = (n) => new qr(typeof n == "string" ? n : n + "", void 0, kt), H = (n, ...e) => {
|
|
3239
3239
|
const t = n.length === 1 ? n[0] : e.reduce((r, i, s) => r + ((o) => {
|
|
3240
3240
|
if (o._$cssResult$ === !0) return o.cssText;
|
|
3241
3241
|
if (typeof o == "number") return o;
|
|
3242
3242
|
throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
|
|
3243
3243
|
})(i) + n[s + 1], n[0]);
|
|
3244
|
-
return new
|
|
3245
|
-
},
|
|
3244
|
+
return new qr(t, n, kt);
|
|
3245
|
+
}, ps = (n, e) => {
|
|
3246
3246
|
if (Rt) n.adoptedStyleSheets = e.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet);
|
|
3247
3247
|
else for (const t of e) {
|
|
3248
3248
|
const r = document.createElement("style"), i = ze.litNonce;
|
|
@@ -3251,9 +3251,9 @@ const fs = (n) => new Nr(typeof n == "string" ? n : n + "", void 0, kt), H = (n,
|
|
|
3251
3251
|
}, fr = Rt ? (n) => n : (n) => n instanceof CSSStyleSheet ? ((e) => {
|
|
3252
3252
|
let t = "";
|
|
3253
3253
|
for (const r of e.cssRules) t += r.cssText;
|
|
3254
|
-
return
|
|
3254
|
+
return ds(t);
|
|
3255
3255
|
})(n) : n;
|
|
3256
|
-
const { is:
|
|
3256
|
+
const { is: gs, defineProperty: ms, getOwnPropertyDescriptor: vs, getOwnPropertyNames: ys, getOwnPropertySymbols: ws, getPrototypeOf: bs } = Object, Qe = globalThis, dr = Qe.trustedTypes, Ss = dr ? dr.emptyScript : "", _s = Qe.reactiveElementPolyfillSupport, De = (n, e) => n, xt = { toAttribute(n, e) {
|
|
3257
3257
|
switch (e) {
|
|
3258
3258
|
case Boolean:
|
|
3259
3259
|
n = n ? Ss : null;
|
|
@@ -3281,7 +3281,7 @@ const { is: ps, defineProperty: gs, getOwnPropertyDescriptor: ms, getOwnProperty
|
|
|
3281
3281
|
}
|
|
3282
3282
|
}
|
|
3283
3283
|
return t;
|
|
3284
|
-
} },
|
|
3284
|
+
} }, Lr = (n, e) => !gs(n, e), pr = { attribute: !0, type: String, converter: xt, reflect: !1, useDefault: !1, hasChanged: Lr };
|
|
3285
3285
|
Symbol.metadata ??= /* @__PURE__ */ Symbol("metadata"), Qe.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap();
|
|
3286
3286
|
let ce = class extends HTMLElement {
|
|
3287
3287
|
static addInitializer(e) {
|
|
@@ -3293,11 +3293,11 @@ let ce = class extends HTMLElement {
|
|
|
3293
3293
|
static createProperty(e, t = pr) {
|
|
3294
3294
|
if (t.state && (t.attribute = !1), this._$Ei(), this.prototype.hasOwnProperty(e) && ((t = Object.create(t)).wrapped = !0), this.elementProperties.set(e, t), !t.noAccessor) {
|
|
3295
3295
|
const r = /* @__PURE__ */ Symbol(), i = this.getPropertyDescriptor(e, r, t);
|
|
3296
|
-
i !== void 0 &&
|
|
3296
|
+
i !== void 0 && ms(this.prototype, e, i);
|
|
3297
3297
|
}
|
|
3298
3298
|
}
|
|
3299
3299
|
static getPropertyDescriptor(e, t, r) {
|
|
3300
|
-
const { get: i, set: s } =
|
|
3300
|
+
const { get: i, set: s } = vs(this.prototype, e) ?? { get() {
|
|
3301
3301
|
return this[t];
|
|
3302
3302
|
}, set(o) {
|
|
3303
3303
|
this[t] = o;
|
|
@@ -3312,13 +3312,13 @@ let ce = class extends HTMLElement {
|
|
|
3312
3312
|
}
|
|
3313
3313
|
static _$Ei() {
|
|
3314
3314
|
if (this.hasOwnProperty(De("elementProperties"))) return;
|
|
3315
|
-
const e =
|
|
3315
|
+
const e = bs(this);
|
|
3316
3316
|
e.finalize(), e.l !== void 0 && (this.l = [...e.l]), this.elementProperties = new Map(e.elementProperties);
|
|
3317
3317
|
}
|
|
3318
3318
|
static finalize() {
|
|
3319
3319
|
if (this.hasOwnProperty(De("finalized"))) return;
|
|
3320
3320
|
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(De("properties"))) {
|
|
3321
|
-
const t = this.properties, r = [...
|
|
3321
|
+
const t = this.properties, r = [...ys(t), ...ws(t)];
|
|
3322
3322
|
for (const i of r) this.createProperty(i, t[i]);
|
|
3323
3323
|
}
|
|
3324
3324
|
const e = this[Symbol.metadata];
|
|
@@ -3364,7 +3364,7 @@ let ce = class extends HTMLElement {
|
|
|
3364
3364
|
}
|
|
3365
3365
|
createRenderRoot() {
|
|
3366
3366
|
const e = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
3367
|
-
return
|
|
3367
|
+
return ps(e, this.constructor.elementStyles), e;
|
|
3368
3368
|
}
|
|
3369
3369
|
connectedCallback() {
|
|
3370
3370
|
this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(!0), this._$EO?.forEach((e) => e.hostConnected?.());
|
|
@@ -3396,7 +3396,7 @@ let ce = class extends HTMLElement {
|
|
|
3396
3396
|
requestUpdate(e, t, r, i = !1, s) {
|
|
3397
3397
|
if (e !== void 0) {
|
|
3398
3398
|
const o = this.constructor;
|
|
3399
|
-
if (i === !1 && (s = this[e]), r ??= o.getPropertyOptions(e), !((r.hasChanged ??
|
|
3399
|
+
if (i === !1 && (s = this[e]), r ??= o.getPropertyOptions(e), !((r.hasChanged ?? Lr)(s, t) || r.useDefault && r.reflect && s === this._$Ej?.get(e) && !this.hasAttribute(o._$Eu(e, r)))) return;
|
|
3400
3400
|
this.C(e, t, r);
|
|
3401
3401
|
}
|
|
3402
3402
|
this.isUpdatePending === !1 && (this._$ES = this._$EP());
|
|
@@ -3464,43 +3464,43 @@ let ce = class extends HTMLElement {
|
|
|
3464
3464
|
firstUpdated(e) {
|
|
3465
3465
|
}
|
|
3466
3466
|
};
|
|
3467
|
-
ce.elementStyles = [], ce.shadowRootOptions = { mode: "open" }, ce[De("elementProperties")] = /* @__PURE__ */ new Map(), ce[De("finalized")] = /* @__PURE__ */ new Map(),
|
|
3468
|
-
const $t = globalThis, gr = (n) => n, Ye = $t.trustedTypes, mr = Ye ? Ye.createPolicy("lit-html", { createHTML: (n) => n }) : void 0,
|
|
3467
|
+
ce.elementStyles = [], ce.shadowRootOptions = { mode: "open" }, ce[De("elementProperties")] = /* @__PURE__ */ new Map(), ce[De("finalized")] = /* @__PURE__ */ new Map(), _s?.({ ReactiveElement: ce }), (Qe.reactiveElementVersions ??= []).push("2.1.2");
|
|
3468
|
+
const $t = globalThis, gr = (n) => n, Ye = $t.trustedTypes, mr = Ye ? Ye.createPolicy("lit-html", { createHTML: (n) => n }) : void 0, Kr = "$lit$", J = `lit$${Math.random().toFixed(9).slice(2)}$`, Vr = "?" + J, As = `<${Vr}>`, oe = document, $e = () => oe.createComment(""), Pe = (n) => n === null || typeof n != "object" && typeof n != "function", Pt = Array.isArray, Cs = (n) => Pt(n) || typeof n?.[Symbol.iterator] == "function", ut = `[
|
|
3469
3469
|
\f\r]`, Ee = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, vr = /-->/g, yr = />/g, re = RegExp(`>|${ut}(?:([^\\s"'>=/]+)(${ut}*=${ut}*(?:[^
|
|
3470
|
-
\f\r"'\`<>=]|("|')|))|$)`, "g"), wr = /'/g,
|
|
3471
|
-
function
|
|
3470
|
+
\f\r"'\`<>=]|("|')|))|$)`, "g"), wr = /'/g, br = /"/g, jr = /^(?:script|style|textarea|title)$/i, xs = (n) => (e, ...t) => ({ _$litType$: n, strings: e, values: t }), C = xs(1), he = /* @__PURE__ */ Symbol.for("lit-noChange"), T = /* @__PURE__ */ Symbol.for("lit-nothing"), Sr = /* @__PURE__ */ new WeakMap(), ie = oe.createTreeWalker(oe, 129);
|
|
3471
|
+
function Hr(n, e) {
|
|
3472
3472
|
if (!Pt(n) || !n.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
3473
3473
|
return mr !== void 0 ? mr.createHTML(e) : e;
|
|
3474
3474
|
}
|
|
3475
|
-
const
|
|
3475
|
+
const Es = (n, e) => {
|
|
3476
3476
|
const t = n.length - 1, r = [];
|
|
3477
3477
|
let i, s = e === 2 ? "<svg>" : e === 3 ? "<math>" : "", o = Ee;
|
|
3478
3478
|
for (let l = 0; l < t; l++) {
|
|
3479
3479
|
const h = n[l];
|
|
3480
3480
|
let d, p, m = -1, v = 0;
|
|
3481
|
-
for (; v < h.length && (o.lastIndex = v, p = o.exec(h), p !== null); ) v = o.lastIndex, o === Ee ? p[1] === "!--" ? o = vr : p[1] !== void 0 ? o = yr : p[2] !== void 0 ? (
|
|
3481
|
+
for (; v < h.length && (o.lastIndex = v, p = o.exec(h), p !== null); ) v = o.lastIndex, o === Ee ? p[1] === "!--" ? o = vr : p[1] !== void 0 ? o = yr : p[2] !== void 0 ? (jr.test(p[2]) && (i = RegExp("</" + p[2], "g")), o = re) : p[3] !== void 0 && (o = re) : o === re ? p[0] === ">" ? (o = i ?? Ee, m = -1) : p[1] === void 0 ? m = -2 : (m = o.lastIndex - p[2].length, d = p[1], o = p[3] === void 0 ? re : p[3] === '"' ? br : wr) : o === br || o === wr ? o = re : o === vr || o === yr ? o = Ee : (o = re, i = void 0);
|
|
3482
3482
|
const y = o === re && n[l + 1].startsWith("/>") ? " " : "";
|
|
3483
|
-
s += o === Ee ? h +
|
|
3483
|
+
s += o === Ee ? h + As : m >= 0 ? (r.push(d), h.slice(0, m) + Kr + h.slice(m) + J + y) : h + J + (m === -2 ? l : y);
|
|
3484
3484
|
}
|
|
3485
|
-
return [
|
|
3485
|
+
return [Hr(n, s + (n[t] || "<?>") + (e === 2 ? "</svg>" : e === 3 ? "</math>" : "")), r];
|
|
3486
3486
|
};
|
|
3487
3487
|
class Fe {
|
|
3488
3488
|
constructor({ strings: e, _$litType$: t }, r) {
|
|
3489
3489
|
let i;
|
|
3490
3490
|
this.parts = [];
|
|
3491
3491
|
let s = 0, o = 0;
|
|
3492
|
-
const l = e.length - 1, h = this.parts, [d, p] =
|
|
3492
|
+
const l = e.length - 1, h = this.parts, [d, p] = Es(e, t);
|
|
3493
3493
|
if (this.el = Fe.createElement(d, r), ie.currentNode = this.el.content, t === 2 || t === 3) {
|
|
3494
3494
|
const m = this.el.content.firstChild;
|
|
3495
3495
|
m.replaceWith(...m.childNodes);
|
|
3496
3496
|
}
|
|
3497
3497
|
for (; (i = ie.nextNode()) !== null && h.length < l; ) {
|
|
3498
3498
|
if (i.nodeType === 1) {
|
|
3499
|
-
if (i.hasAttributes()) for (const m of i.getAttributeNames()) if (m.endsWith(
|
|
3500
|
-
const v = p[o++], y = i.getAttribute(m).split(J),
|
|
3501
|
-
h.push({ type: 1, index: s, name:
|
|
3499
|
+
if (i.hasAttributes()) for (const m of i.getAttributeNames()) if (m.endsWith(Kr)) {
|
|
3500
|
+
const v = p[o++], y = i.getAttribute(m).split(J), b = /([.?@])?(.*)/.exec(v);
|
|
3501
|
+
h.push({ type: 1, index: s, name: b[2], strings: y, ctor: b[1] === "." ? Ts : b[1] === "?" ? Is : b[1] === "@" ? Ds : et }), i.removeAttribute(m);
|
|
3502
3502
|
} else m.startsWith(J) && (h.push({ type: 6, index: s }), i.removeAttribute(m));
|
|
3503
|
-
if (
|
|
3503
|
+
if (jr.test(i.tagName)) {
|
|
3504
3504
|
const m = i.textContent.split(J), v = m.length - 1;
|
|
3505
3505
|
if (v > 0) {
|
|
3506
3506
|
i.textContent = Ye ? Ye.emptyScript : "";
|
|
@@ -3508,7 +3508,7 @@ class Fe {
|
|
|
3508
3508
|
i.append(m[v], $e());
|
|
3509
3509
|
}
|
|
3510
3510
|
}
|
|
3511
|
-
} else if (i.nodeType === 8) if (i.data ===
|
|
3511
|
+
} else if (i.nodeType === 8) if (i.data === Vr) h.push({ type: 2, index: s });
|
|
3512
3512
|
else {
|
|
3513
3513
|
let m = -1;
|
|
3514
3514
|
for (; (m = i.data.indexOf(J, m + 1)) !== -1; ) h.push({ type: 7, index: s }), m += J.length - 1;
|
|
@@ -3527,7 +3527,7 @@ function fe(n, e, t = n, r) {
|
|
|
3527
3527
|
const s = Pe(e) ? void 0 : e._$litDirective$;
|
|
3528
3528
|
return i?.constructor !== s && (i?._$AO?.(!1), s === void 0 ? i = void 0 : (i = new s(n), i._$AT(n, t, r)), r !== void 0 ? (t._$Co ??= [])[r] = i : t._$Cl = i), i !== void 0 && (e = fe(n, i._$AS(n, e.values), i, r)), e;
|
|
3529
3529
|
}
|
|
3530
|
-
class
|
|
3530
|
+
class Us {
|
|
3531
3531
|
constructor(e, t) {
|
|
3532
3532
|
this._$AV = [], this._$AN = void 0, this._$AD = e, this._$AM = t;
|
|
3533
3533
|
}
|
|
@@ -3544,7 +3544,7 @@ class Es {
|
|
|
3544
3544
|
for (; h !== void 0; ) {
|
|
3545
3545
|
if (o === h.index) {
|
|
3546
3546
|
let d;
|
|
3547
|
-
h.type === 2 ? d = new Be(s, s.nextSibling, this, e) : h.type === 1 ? d = new h.ctor(s, h.name, h.strings, this, e) : h.type === 6 && (d = new
|
|
3547
|
+
h.type === 2 ? d = new Be(s, s.nextSibling, this, e) : h.type === 1 ? d = new h.ctor(s, h.name, h.strings, this, e) : h.type === 6 && (d = new Rs(s, this, e)), this._$AV.push(d), h = r[++l];
|
|
3548
3548
|
}
|
|
3549
3549
|
o !== h?.index && (s = ie.nextNode(), o++);
|
|
3550
3550
|
}
|
|
@@ -3574,7 +3574,7 @@ class Be {
|
|
|
3574
3574
|
return this._$AB;
|
|
3575
3575
|
}
|
|
3576
3576
|
_$AI(e, t = this) {
|
|
3577
|
-
e = fe(this, e, t), Pe(e) ? e === T || e == null || e === "" ? (this._$AH !== T && this._$AR(), this._$AH = T) : e !== this._$AH && e !== he && this._(e) : e._$litType$ !== void 0 ? this.$(e) : e.nodeType !== void 0 ? this.T(e) :
|
|
3577
|
+
e = fe(this, e, t), Pe(e) ? e === T || e == null || e === "" ? (this._$AH !== T && this._$AR(), this._$AH = T) : e !== this._$AH && e !== he && this._(e) : e._$litType$ !== void 0 ? this.$(e) : e.nodeType !== void 0 ? this.T(e) : Cs(e) ? this.k(e) : this._(e);
|
|
3578
3578
|
}
|
|
3579
3579
|
O(e) {
|
|
3580
3580
|
return this._$AA.parentNode.insertBefore(e, this._$AB);
|
|
@@ -3586,16 +3586,16 @@ class Be {
|
|
|
3586
3586
|
this._$AH !== T && Pe(this._$AH) ? this._$AA.nextSibling.data = e : this.T(oe.createTextNode(e)), this._$AH = e;
|
|
3587
3587
|
}
|
|
3588
3588
|
$(e) {
|
|
3589
|
-
const { values: t, _$litType$: r } = e, i = typeof r == "number" ? this._$AC(e) : (r.el === void 0 && (r.el = Fe.createElement(
|
|
3589
|
+
const { values: t, _$litType$: r } = e, i = typeof r == "number" ? this._$AC(e) : (r.el === void 0 && (r.el = Fe.createElement(Hr(r.h, r.h[0]), this.options)), r);
|
|
3590
3590
|
if (this._$AH?._$AD === i) this._$AH.p(t);
|
|
3591
3591
|
else {
|
|
3592
|
-
const s = new
|
|
3592
|
+
const s = new Us(i, this), o = s.u(this.options);
|
|
3593
3593
|
s.p(t), this.T(o), this._$AH = s;
|
|
3594
3594
|
}
|
|
3595
3595
|
}
|
|
3596
3596
|
_$AC(e) {
|
|
3597
|
-
let t =
|
|
3598
|
-
return t === void 0 &&
|
|
3597
|
+
let t = Sr.get(e.strings);
|
|
3598
|
+
return t === void 0 && Sr.set(e.strings, t = new Fe(e)), t;
|
|
3599
3599
|
}
|
|
3600
3600
|
k(e) {
|
|
3601
3601
|
Pt(this._$AH) || (this._$AH = [], this._$AR());
|
|
@@ -3639,7 +3639,7 @@ class et {
|
|
|
3639
3639
|
e === T ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, e ?? "");
|
|
3640
3640
|
}
|
|
3641
3641
|
}
|
|
3642
|
-
class
|
|
3642
|
+
class Ts extends et {
|
|
3643
3643
|
constructor() {
|
|
3644
3644
|
super(...arguments), this.type = 3;
|
|
3645
3645
|
}
|
|
@@ -3647,7 +3647,7 @@ class Us extends et {
|
|
|
3647
3647
|
this.element[this.name] = e === T ? void 0 : e;
|
|
3648
3648
|
}
|
|
3649
3649
|
}
|
|
3650
|
-
class
|
|
3650
|
+
class Is extends et {
|
|
3651
3651
|
constructor() {
|
|
3652
3652
|
super(...arguments), this.type = 4;
|
|
3653
3653
|
}
|
|
@@ -3655,7 +3655,7 @@ class Ts extends et {
|
|
|
3655
3655
|
this.element.toggleAttribute(this.name, !!e && e !== T);
|
|
3656
3656
|
}
|
|
3657
3657
|
}
|
|
3658
|
-
class
|
|
3658
|
+
class Ds extends et {
|
|
3659
3659
|
constructor(e, t, r, i, s) {
|
|
3660
3660
|
super(e, t, r, i, s), this.type = 5;
|
|
3661
3661
|
}
|
|
@@ -3668,7 +3668,7 @@ class Is extends et {
|
|
|
3668
3668
|
typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, e) : this._$AH.handleEvent(e);
|
|
3669
3669
|
}
|
|
3670
3670
|
}
|
|
3671
|
-
class
|
|
3671
|
+
class Rs {
|
|
3672
3672
|
constructor(e, t, r) {
|
|
3673
3673
|
this.element = e, this.type = 6, this._$AN = void 0, this._$AM = t, this.options = r;
|
|
3674
3674
|
}
|
|
@@ -3679,9 +3679,9 @@ class Ds {
|
|
|
3679
3679
|
fe(this, e);
|
|
3680
3680
|
}
|
|
3681
3681
|
}
|
|
3682
|
-
const
|
|
3683
|
-
|
|
3684
|
-
const
|
|
3682
|
+
const ks = $t.litHtmlPolyfillSupport;
|
|
3683
|
+
ks?.(Fe, Be), ($t.litHtmlVersions ??= []).push("3.3.3");
|
|
3684
|
+
const $s = (n, e, t) => {
|
|
3685
3685
|
const r = t?.renderBefore ?? e;
|
|
3686
3686
|
let i = r._$litPart$;
|
|
3687
3687
|
if (i === void 0) {
|
|
@@ -3701,7 +3701,7 @@ class se extends ce {
|
|
|
3701
3701
|
}
|
|
3702
3702
|
update(e) {
|
|
3703
3703
|
const t = this.render();
|
|
3704
|
-
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(e), this._$Do =
|
|
3704
|
+
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(e), this._$Do = $s(t, this.renderRoot, this.renderOptions);
|
|
3705
3705
|
}
|
|
3706
3706
|
connectedCallback() {
|
|
3707
3707
|
super.connectedCallback(), this._$Do?.setConnected(!0);
|
|
@@ -3714,10 +3714,10 @@ class se extends ce {
|
|
|
3714
3714
|
}
|
|
3715
3715
|
}
|
|
3716
3716
|
se._$litElement$ = !0, se.finalized = !0, Ft.litElementHydrateSupport?.({ LitElement: se });
|
|
3717
|
-
const
|
|
3718
|
-
|
|
3717
|
+
const Ps = Ft.litElementPolyfillSupport;
|
|
3718
|
+
Ps?.({ LitElement: se });
|
|
3719
3719
|
(Ft.litElementVersions ??= []).push("4.2.2");
|
|
3720
|
-
const
|
|
3720
|
+
const Fs = H`
|
|
3721
3721
|
:host {
|
|
3722
3722
|
display: block;
|
|
3723
3723
|
box-sizing: border-box;
|
|
@@ -3734,13 +3734,14 @@ const Ps = H`
|
|
|
3734
3734
|
display: flex;
|
|
3735
3735
|
flex-direction: column;
|
|
3736
3736
|
gap: 10px;
|
|
3737
|
+
min-height: 70vh;
|
|
3737
3738
|
}
|
|
3738
3739
|
.chat > * { scroll-margin-bottom: 84px; }
|
|
3739
3740
|
.sr-only {
|
|
3740
3741
|
position: absolute; width: 1px; height: 1px; overflow: hidden;
|
|
3741
3742
|
clip: rect(0 0 0 0); white-space: nowrap;
|
|
3742
3743
|
}
|
|
3743
|
-
`,
|
|
3744
|
+
`, Bs = H`
|
|
3744
3745
|
@keyframes pop-in {
|
|
3745
3746
|
0% { opacity: 0; transform: translateY(16px) scale(0.95); }
|
|
3746
3747
|
100% { opacity: 1; transform: translateY(0) scale(1); }
|
|
@@ -3771,7 +3772,7 @@ const Ps = H`
|
|
|
3771
3772
|
animation: none !important;
|
|
3772
3773
|
}
|
|
3773
3774
|
}
|
|
3774
|
-
`,
|
|
3775
|
+
`, Ms = H`
|
|
3775
3776
|
.msg { max-width: 85%; padding: 12px 16px; border-radius: 14px; font-size: 15px; }
|
|
3776
3777
|
.msg.bot {
|
|
3777
3778
|
background: var(--wral-semantic-surface-default, #FFFFFF);
|
|
@@ -3793,7 +3794,7 @@ const Ps = H`
|
|
|
3793
3794
|
.msg .sub { display: block; font-size: 13px; color: var(--wral-semantic-fg-muted, #64748B); margin-top: 4px; }
|
|
3794
3795
|
.msg.user .sub { color: rgba(255, 255, 255, 0.75); }
|
|
3795
3796
|
.msg.error { border-left: 3px solid var(--wral-base-red-on-light, #D1232A); }
|
|
3796
|
-
`,
|
|
3797
|
+
`, Os = H`
|
|
3797
3798
|
.options { display: flex; flex-wrap: wrap; gap: 8px; align-self: flex-start; max-width: 92%; padding: 2px 0 6px; }
|
|
3798
3799
|
.chip {
|
|
3799
3800
|
font-family: var(--wral-base-font-ui, 'IBM Plex Sans Condensed', sans-serif);
|
|
@@ -3807,7 +3808,7 @@ const Ps = H`
|
|
|
3807
3808
|
.chip:hover { background: var(--wral-base-secondary-1, #2594E3); color: #FFFFFF; }
|
|
3808
3809
|
.chip:focus-visible { outline: 2px solid var(--wral-base-secondary-1, #2594E3); outline-offset: 2px; }
|
|
3809
3810
|
.chip:active { transform: scale(0.97); }
|
|
3810
|
-
`,
|
|
3811
|
+
`, Ns = H`
|
|
3811
3812
|
.form-card {
|
|
3812
3813
|
align-self: stretch;
|
|
3813
3814
|
background: var(--wral-semantic-surface-default, #FFFFFF);
|
|
@@ -3872,7 +3873,7 @@ const Ps = H`
|
|
|
3872
3873
|
.btn-ghost:hover { border-color: var(--wral-base-secondary-1, #2594E3); }
|
|
3873
3874
|
.btn-ghost:active { transform: scale(0.97); }
|
|
3874
3875
|
.btn-ghost:focus-visible { outline: 2px solid var(--wral-base-secondary-1, #2594E3); outline-offset: 2px; }
|
|
3875
|
-
`,
|
|
3876
|
+
`, qs = H`
|
|
3876
3877
|
.login-card { padding: 28px 26px; }
|
|
3877
3878
|
.login-card h2 {
|
|
3878
3879
|
font-family: var(--wral-base-font-display, 'IBM Plex Sans Condensed', sans-serif);
|
|
@@ -3917,7 +3918,14 @@ const Ps = H`
|
|
|
3917
3918
|
}
|
|
3918
3919
|
.login-why ul { margin: 0; padding-left: 20px; font-size: 14px; color: var(--color-gray-6, #565454); }
|
|
3919
3920
|
.login-why li { margin-bottom: 4px; line-height: 1.5; }
|
|
3920
|
-
|
|
3921
|
+
.login-why a { color: var(--color-secondary, #2594E3); font-weight: 600; text-decoration: underline; }
|
|
3922
|
+
.login-anon {
|
|
3923
|
+
border-top: 1px solid var(--color-gray-2, #E7E5E4); margin: 16px 0 0; padding-top: 14px;
|
|
3924
|
+
font-size: 14px; color: var(--color-gray-6, #565454); line-height: 1.5;
|
|
3925
|
+
}
|
|
3926
|
+
.login-anon a { color: var(--color-primary-dark, #00144A); font-weight: 600; text-decoration: none; white-space: nowrap; }
|
|
3927
|
+
.login-anon a:hover { text-decoration: underline; }
|
|
3928
|
+
`, Ls = H`
|
|
3921
3929
|
.review-list { margin: 0; padding: 0; list-style: none; font-size: 14px; }
|
|
3922
3930
|
.review-list li {
|
|
3923
3931
|
display: grid; grid-template-columns: 130px 1fr; gap: 10px;
|
|
@@ -3949,7 +3957,7 @@ const Ps = H`
|
|
|
3949
3957
|
color: var(--wral-base-primary-1, #001D68);
|
|
3950
3958
|
}
|
|
3951
3959
|
@media (max-width: 540px) { .review-list li { grid-template-columns: 1fr; gap: 2px; } }
|
|
3952
|
-
`,
|
|
3960
|
+
`, Ks = H`
|
|
3953
3961
|
.upload-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 13.5px; }
|
|
3954
3962
|
.upload-row .name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
3955
3963
|
.upload-row .state { font-size: 12px; color: var(--wral-semantic-fg-subtle, #64748B); }
|
|
@@ -3965,7 +3973,7 @@ const Ps = H`
|
|
|
3965
3973
|
border-radius: 999px; padding: 3px 12px; cursor: pointer;
|
|
3966
3974
|
}
|
|
3967
3975
|
.retry-chip:focus-visible { outline: 2px solid var(--wral-base-secondary-1, #2594E3); outline-offset: 2px; }
|
|
3968
|
-
`,
|
|
3976
|
+
`, Vs = H`
|
|
3969
3977
|
.confirm-card {
|
|
3970
3978
|
align-self: stretch;
|
|
3971
3979
|
background: var(--wral-base-primary-1, #001D68);
|
|
@@ -4015,7 +4023,7 @@ const Ps = H`
|
|
|
4015
4023
|
.c-again:hover { background: rgba(255, 255, 255, 0.12); }
|
|
4016
4024
|
.c-again:focus-visible { outline: 2px solid var(--wral-base-secondary-2, #50A9E8); outline-offset: 2px; }
|
|
4017
4025
|
.c-again:active { transform: scale(0.97); }
|
|
4018
|
-
`,
|
|
4026
|
+
`, js = H`
|
|
4019
4027
|
.journey {
|
|
4020
4028
|
align-self: stretch;
|
|
4021
4029
|
background: var(--wral-semantic-surface-default, #FFFFFF);
|
|
@@ -4056,7 +4064,7 @@ const Ps = H`
|
|
|
4056
4064
|
color: var(--wral-base-primary-1, #001D68); margin-bottom: 2px;
|
|
4057
4065
|
}
|
|
4058
4066
|
.j-body .j-d { font-size: 13.5px; color: var(--wral-semantic-fg-muted, #475569); line-height: 1.55; }
|
|
4059
|
-
`,
|
|
4067
|
+
`, Hs = H`
|
|
4060
4068
|
.bottom-bar {
|
|
4061
4069
|
position: sticky; bottom: 0; z-index: 20;
|
|
4062
4070
|
background: var(--wral-semantic-surface-default, #FFFFFF);
|
|
@@ -4069,7 +4077,7 @@ const Ps = H`
|
|
|
4069
4077
|
}
|
|
4070
4078
|
.bottom-bar .note { margin-left: auto; font-size: 12px; color: var(--wral-semantic-fg-subtle, #64748B); }
|
|
4071
4079
|
@media (max-width: 540px) { .bottom-bar .note { display: none; } }
|
|
4072
|
-
`,
|
|
4080
|
+
`, zs = [Fs, Bs, Ms, Os, Ns, qs, Ls, Ks, Vs, js, Hs];
|
|
4073
4081
|
function z(n, e, { noAnim: t = !1, error: r = !1 } = {}) {
|
|
4074
4082
|
return C`
|
|
4075
4083
|
<div class="msg bot ${t ? "no-anim" : ""} ${r ? "error" : ""}">
|
|
@@ -4084,17 +4092,17 @@ function He(n, { noAnim: e = !1 } = {}) {
|
|
|
4084
4092
|
function lt() {
|
|
4085
4093
|
return C`<div class="msg bot typing"><span></span><span></span><span></span></div>`;
|
|
4086
4094
|
}
|
|
4087
|
-
function
|
|
4095
|
+
function Ws(n) {
|
|
4088
4096
|
return n ? C`<span class="flag-pill ${n}">${n === "urgent" ? "Urgent" : "Moderate"}</span>` : T;
|
|
4089
4097
|
}
|
|
4090
|
-
function
|
|
4098
|
+
function Ys() {
|
|
4091
4099
|
return C`
|
|
4092
4100
|
<svg viewBox="0 0 24 24" fill="none" stroke="#FFFFFF" stroke-width="3"
|
|
4093
4101
|
stroke-linecap="round" stroke-linejoin="round" width="20" height="20"
|
|
4094
4102
|
aria-hidden="true"><path d="M20 6L9 17l-5-5"/></svg>
|
|
4095
4103
|
`;
|
|
4096
4104
|
}
|
|
4097
|
-
const
|
|
4105
|
+
const Gs = (n = {}) => ({
|
|
4098
4106
|
userPoolId: n.userPoolId || "us-east-1_5Hz6i23GR",
|
|
4099
4107
|
clientId: n.clientId || "835efrp61536otaeun4ob6iqn",
|
|
4100
4108
|
region: n.region || "us-east-1",
|
|
@@ -4112,7 +4120,7 @@ const Ys = (n = {}) => ({
|
|
|
4112
4120
|
} catch {
|
|
4113
4121
|
return null;
|
|
4114
4122
|
}
|
|
4115
|
-
},
|
|
4123
|
+
}, Js = () => {
|
|
4116
4124
|
const n = "ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz23456789", e = "!@#$%^&*";
|
|
4117
4125
|
return [...Array(12)].map(() => n.charAt(Math.floor(Math.random() * n.length))).join("") + "Aa1" + e.charAt(Math.floor(Math.random() * e.length));
|
|
4118
4126
|
}, Bt = (n) => new AmazonCognitoIdentity.CognitoUserPool({
|
|
@@ -4125,7 +4133,7 @@ const Ys = (n = {}) => ({
|
|
|
4125
4133
|
idToken: n.getIdToken().getJwtToken(),
|
|
4126
4134
|
accessToken: n.getAccessToken().getJwtToken(),
|
|
4127
4135
|
refreshToken: n.getRefreshToken().getToken()
|
|
4128
|
-
}),
|
|
4136
|
+
}), zr = () => ({
|
|
4129
4137
|
get: (n) => localStorage.getItem(n),
|
|
4130
4138
|
set: (n, e) => localStorage.setItem(n, e),
|
|
4131
4139
|
remove: (n) => localStorage.removeItem(n),
|
|
@@ -4134,7 +4142,7 @@ const Ys = (n = {}) => ({
|
|
|
4134
4142
|
n.set(N.idToken, e.idToken), n.set(N.accessToken, e.accessToken), n.set(N.refreshToken, e.refreshToken);
|
|
4135
4143
|
const r = t(e.idToken), i = r?.exp ? (r.exp * 1e3).toString() : (Date.now() + 3600 * 1e3).toString();
|
|
4136
4144
|
n.set(N.idTokenExpiry, i), n.set(N.userEmail, r?.email || ""), n.set(N.userId, r?.sub || "");
|
|
4137
|
-
},
|
|
4145
|
+
}, Zs = (n, e, t) => new Promise((r) => {
|
|
4138
4146
|
const i = t();
|
|
4139
4147
|
e.signUp(
|
|
4140
4148
|
n,
|
|
@@ -4149,27 +4157,27 @@ const Ys = (n = {}) => ({
|
|
|
4149
4157
|
r({ exists: !1, result: o });
|
|
4150
4158
|
}
|
|
4151
4159
|
);
|
|
4152
|
-
}),
|
|
4160
|
+
}), Xs = async (n, e, t, r, i, s, o, l, h) => {
|
|
4153
4161
|
const d = e.toLowerCase().trim(), p = r(n);
|
|
4154
|
-
await i(d, p,
|
|
4162
|
+
await i(d, p, Js);
|
|
4155
4163
|
const m = s(d, p);
|
|
4156
4164
|
return m.setAuthenticationFlowType("CUSTOM_AUTH"), new Promise((v, y) => {
|
|
4157
4165
|
m.initiateAuth(new AmazonCognitoIdentity.AuthenticationDetails({
|
|
4158
4166
|
Username: d
|
|
4159
4167
|
}), {
|
|
4160
|
-
onSuccess: (
|
|
4161
|
-
const _ = o(
|
|
4168
|
+
onSuccess: (b) => {
|
|
4169
|
+
const _ = o(b);
|
|
4162
4170
|
l(t, _, h), v({ success: !0, authenticated: !0, cognitoUser: m });
|
|
4163
4171
|
},
|
|
4164
|
-
onFailure: (
|
|
4165
|
-
console.error("[sendCode] initiateAuth failed:",
|
|
4172
|
+
onFailure: (b) => {
|
|
4173
|
+
console.error("[sendCode] initiateAuth failed:", b), y(b);
|
|
4166
4174
|
},
|
|
4167
4175
|
customChallenge: () => {
|
|
4168
4176
|
console.log("[sendCode] Custom challenge issued - code sent to email"), v({ success: !0, challengeRequired: !0, cognitoUser: m });
|
|
4169
4177
|
}
|
|
4170
4178
|
});
|
|
4171
4179
|
});
|
|
4172
|
-
},
|
|
4180
|
+
}, Qs = (n, e, t, r, i, s) => new Promise((o, l) => {
|
|
4173
4181
|
n.sendCustomChallengeAnswer(e, {
|
|
4174
4182
|
onSuccess: (h) => {
|
|
4175
4183
|
const d = r(h);
|
|
@@ -4178,7 +4186,7 @@ const Ys = (n = {}) => ({
|
|
|
4178
4186
|
onFailure: l,
|
|
4179
4187
|
customChallenge: () => l(new Error("Invalid code"))
|
|
4180
4188
|
});
|
|
4181
|
-
}),
|
|
4189
|
+
}), Wr = async (n, e, t, r, i, s, o) => {
|
|
4182
4190
|
const l = e.get(N.refreshToken);
|
|
4183
4191
|
if (!l) return null;
|
|
4184
4192
|
const h = e.get(N.userEmail);
|
|
@@ -4187,17 +4195,17 @@ const Ys = (n = {}) => ({
|
|
|
4187
4195
|
RefreshToken: l
|
|
4188
4196
|
});
|
|
4189
4197
|
return new Promise((v) => {
|
|
4190
|
-
p.refreshSession(m, (y,
|
|
4198
|
+
p.refreshSession(m, (y, b) => {
|
|
4191
4199
|
if (y)
|
|
4192
4200
|
return e.clear(), v(null);
|
|
4193
|
-
const _ = i(
|
|
4201
|
+
const _ = i(b);
|
|
4194
4202
|
s(e, _, o), v(_.accessToken);
|
|
4195
4203
|
});
|
|
4196
4204
|
});
|
|
4197
|
-
},
|
|
4205
|
+
}, eo = async (n, e) => {
|
|
4198
4206
|
let t = e.get(N.accessToken);
|
|
4199
4207
|
if (!t) {
|
|
4200
|
-
const r = await
|
|
4208
|
+
const r = await Wr(
|
|
4201
4209
|
n,
|
|
4202
4210
|
e,
|
|
4203
4211
|
Bt,
|
|
@@ -4216,11 +4224,11 @@ const Ys = (n = {}) => ({
|
|
|
4216
4224
|
};
|
|
4217
4225
|
let ct = null, _r = null;
|
|
4218
4226
|
function Ot() {
|
|
4219
|
-
return ct || (ct =
|
|
4227
|
+
return ct || (ct = Gs(window.authConfig || {}), _r = zr()), { config: ct, storage: _r };
|
|
4220
4228
|
}
|
|
4221
|
-
async function
|
|
4229
|
+
async function Yr() {
|
|
4222
4230
|
const { config: n, storage: e } = Ot();
|
|
4223
|
-
return
|
|
4231
|
+
return Wr(
|
|
4224
4232
|
n,
|
|
4225
4233
|
e,
|
|
4226
4234
|
Bt,
|
|
@@ -4230,16 +4238,16 @@ async function Wr() {
|
|
|
4230
4238
|
Ge
|
|
4231
4239
|
);
|
|
4232
4240
|
}
|
|
4233
|
-
async function
|
|
4241
|
+
async function to() {
|
|
4234
4242
|
const { storage: n } = Ot(), e = n.get(N.accessToken), t = n.get(N.idTokenExpiry);
|
|
4235
|
-
return e && t && Date.now() < Number(t) ? !0 : !!await
|
|
4243
|
+
return e && t && Date.now() < Number(t) ? !0 : !!await Yr();
|
|
4236
4244
|
}
|
|
4237
4245
|
class Ue extends Error {
|
|
4238
4246
|
constructor(e, t) {
|
|
4239
4247
|
super(`api-forms request failed with status ${e}`), this.status = e, this.body = t;
|
|
4240
4248
|
}
|
|
4241
4249
|
}
|
|
4242
|
-
function
|
|
4250
|
+
function ro({
|
|
4243
4251
|
baseUrl: n,
|
|
4244
4252
|
fetchFn: e = (...i) => fetch(...i),
|
|
4245
4253
|
xhrFactory: t = () => new XMLHttpRequest(),
|
|
@@ -4288,8 +4296,8 @@ function to({
|
|
|
4288
4296
|
} }) => {
|
|
4289
4297
|
const p = t();
|
|
4290
4298
|
return { promise: new Promise((v, y) => {
|
|
4291
|
-
p.open("PUT", o), p.setRequestHeader("Content-Type", h || l.type), p.upload && (p.upload.onprogress = (
|
|
4292
|
-
d({ loaded:
|
|
4299
|
+
p.open("PUT", o), p.setRequestHeader("Content-Type", h || l.type), p.upload && (p.upload.onprogress = (b) => {
|
|
4300
|
+
d({ loaded: b.loaded, total: b.total || l.size });
|
|
4293
4301
|
}), p.onload = () => {
|
|
4294
4302
|
p.status >= 200 && p.status < 300 ? v({ status: p.status }) : y(new Ue(p.status, null));
|
|
4295
4303
|
}, p.onerror = () => y(new Ue(0, null)), p.onabort = () => y(new Ue(0, { aborted: !0 })), p.send(l);
|
|
@@ -4299,24 +4307,24 @@ function to({
|
|
|
4299
4307
|
putRequest: async (o, l) => await s(`/v1/requests/${o}`, { method: "PUT", body: l, auth: !0 })
|
|
4300
4308
|
};
|
|
4301
4309
|
}
|
|
4302
|
-
function
|
|
4310
|
+
function no() {
|
|
4303
4311
|
const { config: n, storage: e } = Ot();
|
|
4304
4312
|
let t = null;
|
|
4305
4313
|
return {
|
|
4306
|
-
isAuthenticated: () =>
|
|
4314
|
+
isAuthenticated: () => to(),
|
|
4307
4315
|
signedInEmail: () => e.get(N.userEmail) || null,
|
|
4308
|
-
getAuthHeaders: () =>
|
|
4316
|
+
getAuthHeaders: () => eo(n, e),
|
|
4309
4317
|
/**
|
|
4310
4318
|
* Email step. Keeps the challenge user in memory for verifyCode.
|
|
4311
4319
|
* @returns {{challengeRequired?: boolean, authenticated?: boolean}}
|
|
4312
4320
|
*/
|
|
4313
4321
|
sendCode: async (r) => {
|
|
4314
|
-
const i = await
|
|
4322
|
+
const i = await Xs(
|
|
4315
4323
|
n,
|
|
4316
4324
|
r,
|
|
4317
4325
|
e,
|
|
4318
4326
|
Bt,
|
|
4319
|
-
|
|
4327
|
+
Zs,
|
|
4320
4328
|
Mt,
|
|
4321
4329
|
Je,
|
|
4322
4330
|
Ze,
|
|
@@ -4335,7 +4343,7 @@ function ro() {
|
|
|
4335
4343
|
if (!t)
|
|
4336
4344
|
throw new Error("Please enter your email again to get a new code.");
|
|
4337
4345
|
try {
|
|
4338
|
-
await
|
|
4346
|
+
await Qs(
|
|
4339
4347
|
t,
|
|
4340
4348
|
r,
|
|
4341
4349
|
e,
|
|
@@ -4346,11 +4354,11 @@ function ro() {
|
|
|
4346
4354
|
} catch {
|
|
4347
4355
|
throw new Error("Invalid or expired code. Please request a new one and try again.");
|
|
4348
4356
|
}
|
|
4349
|
-
return await
|
|
4357
|
+
return await Yr(), { success: !0 };
|
|
4350
4358
|
},
|
|
4351
4359
|
/** Local sign-out only ("use a different email"). */
|
|
4352
4360
|
signOut: () => {
|
|
4353
|
-
t = null,
|
|
4361
|
+
t = null, zr().clear();
|
|
4354
4362
|
},
|
|
4355
4363
|
/**
|
|
4356
4364
|
* Detect a login completed in ANOTHER tab (the storage event
|
|
@@ -4364,14 +4372,14 @@ function ro() {
|
|
|
4364
4372
|
}
|
|
4365
4373
|
};
|
|
4366
4374
|
}
|
|
4367
|
-
function
|
|
4368
|
-
const e =
|
|
4369
|
-
return { ...
|
|
4375
|
+
function io({ baseUrl: n }) {
|
|
4376
|
+
const e = no();
|
|
4377
|
+
return { ...ro({ baseUrl: n, getAuthHeaders: e.getAuthHeaders }), ...e };
|
|
4370
4378
|
}
|
|
4371
4379
|
function ae(n, e) {
|
|
4372
4380
|
return (n?.nodes || []).find((t) => t.id === e);
|
|
4373
4381
|
}
|
|
4374
|
-
function
|
|
4382
|
+
function Gr(n, e = []) {
|
|
4375
4383
|
const t = [];
|
|
4376
4384
|
let r = n?.start;
|
|
4377
4385
|
for (const s of e) {
|
|
@@ -4392,9 +4400,9 @@ function Yr(n, e = []) {
|
|
|
4392
4400
|
r = o.next;
|
|
4393
4401
|
}
|
|
4394
4402
|
const i = ae(n, r);
|
|
4395
|
-
return i ? { nodeId: r, node: i, flags:
|
|
4403
|
+
return i ? { nodeId: r, node: i, flags: Zr(t), error: null } : { nodeId: null, node: null, flags: t, error: { step: null, reason: `unknown node: ${r}` } };
|
|
4396
4404
|
}
|
|
4397
|
-
function
|
|
4405
|
+
function so(n, e = []) {
|
|
4398
4406
|
const t = [];
|
|
4399
4407
|
for (const r of e) {
|
|
4400
4408
|
if (r.kind !== "collect") continue;
|
|
@@ -4403,37 +4411,37 @@ function io(n, e = []) {
|
|
|
4403
4411
|
}
|
|
4404
4412
|
return t;
|
|
4405
4413
|
}
|
|
4406
|
-
function
|
|
4414
|
+
function oo(n = []) {
|
|
4407
4415
|
const e = {};
|
|
4408
4416
|
for (const t of n)
|
|
4409
4417
|
t.kind === "collect" && Object.assign(e, t.values || {});
|
|
4410
4418
|
return e;
|
|
4411
4419
|
}
|
|
4412
|
-
function
|
|
4420
|
+
function ao(n = []) {
|
|
4413
4421
|
return n.filter((e) => e.kind === "choice").map((e) => `${e.nodeId}:${e.optionId}`);
|
|
4414
4422
|
}
|
|
4415
|
-
function
|
|
4423
|
+
function Jr(n, e = []) {
|
|
4416
4424
|
const t = [];
|
|
4417
4425
|
for (const r of e) {
|
|
4418
4426
|
if (r.kind !== "choice") continue;
|
|
4419
4427
|
const s = (ae(n, r.nodeId)?.options || []).find((o) => o.id === r.optionId);
|
|
4420
4428
|
t.push(...s?.flags || []);
|
|
4421
4429
|
}
|
|
4422
|
-
return
|
|
4430
|
+
return Zr(t);
|
|
4423
4431
|
}
|
|
4424
|
-
function
|
|
4432
|
+
function uo(n = []) {
|
|
4425
4433
|
return n.includes("urgent") ? "urgent" : n.includes("moderate") ? "moderate" : null;
|
|
4426
4434
|
}
|
|
4427
|
-
function
|
|
4435
|
+
function Zr(n) {
|
|
4428
4436
|
return [...new Set(n)];
|
|
4429
4437
|
}
|
|
4430
|
-
const
|
|
4438
|
+
const lo = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}(:\d{2})?(\.\d+)?(Z|[+-]\d{2}:\d{2})?$/, Ar = {
|
|
4431
4439
|
text: 500,
|
|
4432
4440
|
textarea: 5e3,
|
|
4433
4441
|
url: 2048
|
|
4434
4442
|
};
|
|
4435
|
-
function
|
|
4436
|
-
if (e == null || e === "" || n.kind === "location" &&
|
|
4443
|
+
function co(n, e) {
|
|
4444
|
+
if (e == null || e === "" || n.kind === "location" && ho(e))
|
|
4437
4445
|
return n.required ? `Please fill in: ${n.label.toLowerCase()}.` : null;
|
|
4438
4446
|
switch (n.kind) {
|
|
4439
4447
|
case "text":
|
|
@@ -4451,30 +4459,30 @@ function lo(n, e) {
|
|
|
4451
4459
|
}
|
|
4452
4460
|
}
|
|
4453
4461
|
case "datetime":
|
|
4454
|
-
return
|
|
4462
|
+
return lo.test(String(e)) ? null : "Please pick a date and time.";
|
|
4455
4463
|
case "select":
|
|
4456
4464
|
return (n.options || []).map((i) => i.id).includes(e) ? null : `Please choose one of the options for ${n.label.toLowerCase()}.`;
|
|
4457
4465
|
case "consent":
|
|
4458
4466
|
return e === !0 ? null : "Please confirm the rights statement so we can use what you send.";
|
|
4459
4467
|
case "location":
|
|
4460
|
-
return
|
|
4468
|
+
return fo(n, e);
|
|
4461
4469
|
case "media":
|
|
4462
4470
|
return null;
|
|
4463
4471
|
default:
|
|
4464
4472
|
return `Unsupported field: ${n.kind}`;
|
|
4465
4473
|
}
|
|
4466
4474
|
}
|
|
4467
|
-
function
|
|
4475
|
+
function ho(n) {
|
|
4468
4476
|
return n == null ? !0 : typeof n != "object" ? !1 : !n.county && !n.where && !(Array.isArray(n.gps) && n.gps.length);
|
|
4469
4477
|
}
|
|
4470
|
-
function
|
|
4478
|
+
function fo(n, e) {
|
|
4471
4479
|
return typeof e != "object" || Array.isArray(e) ? "Please tell us where this was." : e.county !== void 0 && (typeof e.county != "string" || e.county.length > 100) ? "Please choose a county." : e.where !== void 0 && (typeof e.where != "string" || e.where.length > 500) ? "Please shorten the location description." : e.gps !== void 0 && !(Array.isArray(e.gps) && e.gps.length === 2 && e.gps.every((r) => typeof r == "number" && Number.isFinite(r))) ? "Location coordinates look wrong; try re-sharing your location." : n.required && !e.county && !e.where ? `Please fill in: ${n.label.toLowerCase()}.` : null;
|
|
4472
4480
|
}
|
|
4473
4481
|
function Cr(n, e = {}) {
|
|
4474
4482
|
const t = {};
|
|
4475
4483
|
for (const r of n) {
|
|
4476
4484
|
if (r.kind === "media") continue;
|
|
4477
|
-
const i =
|
|
4485
|
+
const i = co(r, e[r.key]);
|
|
4478
4486
|
i && (t[r.key] = i);
|
|
4479
4487
|
}
|
|
4480
4488
|
return { ok: Object.keys(t).length === 0, errors: t };
|
|
@@ -4507,8 +4515,8 @@ function xr({ formId: n, requestId: e, files: t }) {
|
|
|
4507
4515
|
files: t.map((r) => ({ contentType: r.type, size: r.size }))
|
|
4508
4516
|
};
|
|
4509
4517
|
}
|
|
4510
|
-
function
|
|
4511
|
-
const r =
|
|
4518
|
+
function po({ form: n, steps: e, media: t = [] }) {
|
|
4519
|
+
const r = so(n, e), i = oo(e), s = {};
|
|
4512
4520
|
for (const o of r) {
|
|
4513
4521
|
if (o.kind === "media") continue;
|
|
4514
4522
|
const l = i[o.key];
|
|
@@ -4524,12 +4532,12 @@ function fo({ form: n, steps: e, media: t = [] }) {
|
|
|
4524
4532
|
return {
|
|
4525
4533
|
formId: n.formId,
|
|
4526
4534
|
flowVersion: n.flowVersion,
|
|
4527
|
-
path:
|
|
4535
|
+
path: ao(e),
|
|
4528
4536
|
answers: s,
|
|
4529
4537
|
media: t.map(({ assetId: o, type: l }) => ({ assetId: o, type: l }))
|
|
4530
4538
|
};
|
|
4531
4539
|
}
|
|
4532
|
-
function
|
|
4540
|
+
function go(n, e) {
|
|
4533
4541
|
if (n === 429)
|
|
4534
4542
|
return {
|
|
4535
4543
|
kind: "throttled",
|
|
@@ -4567,15 +4575,15 @@ function po(n, e) {
|
|
|
4567
4575
|
message: "Something went wrong on our end; please try again."
|
|
4568
4576
|
};
|
|
4569
4577
|
}
|
|
4570
|
-
const
|
|
4578
|
+
const mo = 34, vo = 44;
|
|
4571
4579
|
function Er(n, e) {
|
|
4572
4580
|
const t = String(n);
|
|
4573
4581
|
return t.length > e ? `${t.slice(0, e)}…` : t;
|
|
4574
4582
|
}
|
|
4575
|
-
function
|
|
4583
|
+
function yo(n) {
|
|
4576
4584
|
return !n || typeof n != "object" ? "" : [n.county, n.where].filter(Boolean).join(", ");
|
|
4577
4585
|
}
|
|
4578
|
-
function
|
|
4586
|
+
function wo(n, e = {}, t = []) {
|
|
4579
4587
|
const r = [];
|
|
4580
4588
|
for (const i of n) {
|
|
4581
4589
|
if (i.kind === "consent") continue;
|
|
@@ -4583,18 +4591,18 @@ function yo(n, e = {}, t = []) {
|
|
|
4583
4591
|
t.length && r.push(`${t.length} ${t.length === 1 ? "file" : "files"}`);
|
|
4584
4592
|
continue;
|
|
4585
4593
|
}
|
|
4586
|
-
const s = i.kind === "location" ?
|
|
4587
|
-
s == null || s === "" || (i.kind === "textarea" ? r.push(`"${Er(s,
|
|
4594
|
+
const s = i.kind === "location" ? yo(e[i.key]) : e[i.key];
|
|
4595
|
+
s == null || s === "" || (i.kind === "textarea" ? r.push(`"${Er(s, vo)}"`) : r.push(Er(s, mo)));
|
|
4588
4596
|
}
|
|
4589
4597
|
return r.join(" · ") || "Details provided";
|
|
4590
4598
|
}
|
|
4591
|
-
function
|
|
4599
|
+
function bo(n, e = [], t = null) {
|
|
4592
4600
|
const r = [];
|
|
4593
4601
|
for (const s of e) {
|
|
4594
4602
|
const o = ae(n, s.nodeId);
|
|
4595
4603
|
s.kind === "choice" && o && r.push({ k: (o.prompt || "").replace(/\?$/, ""), v: s.label || s.optionId }), s.kind === "collect" && r.push({ k: "Details", v: s.summary || "Details provided" }), s.kind === "gate" && (s.email || t) && r.push({ k: "Verified email", v: s.email || t });
|
|
4596
4604
|
}
|
|
4597
|
-
const i =
|
|
4605
|
+
const i = uo(Jr(n, e));
|
|
4598
4606
|
return i && r.push({ k: "Priority", v: i === "urgent" ? "Urgent" : "Moderate", pill: i }), r;
|
|
4599
4607
|
}
|
|
4600
4608
|
function So(n, e = []) {
|
|
@@ -4605,11 +4613,11 @@ function So(n, e = []) {
|
|
|
4605
4613
|
urgentNote: e.includes("urgent") ? t.urgentNote : void 0
|
|
4606
4614
|
};
|
|
4607
4615
|
}
|
|
4608
|
-
function
|
|
4616
|
+
function _o(n, e) {
|
|
4609
4617
|
const t = e === "failed" ? " The notification is queued for a delivery retry." : "";
|
|
4610
4618
|
return n?.startsWith("studio+email:") ? `Sent to the Studio review queue; the desk is emailed.${t}` : n?.startsWith("studio:") ? "Sent to the Studio review queue." : n?.startsWith("jsm:") ? `A ticket is opened for tech support with your details as fields, not prose.${t}` : n?.startsWith("email:") ? `Emailed to the owning desk with a link to your report.${t}` : "Routed to the right team.";
|
|
4611
4619
|
}
|
|
4612
|
-
function
|
|
4620
|
+
function Ao({ routing: n = {}, flags: e = [], reference: t = "" }) {
|
|
4613
4621
|
const r = e.includes("urgent");
|
|
4614
4622
|
return [
|
|
4615
4623
|
{
|
|
@@ -4618,7 +4626,7 @@ function _o({ routing: n = {}, flags: e = [], reference: t = "" }) {
|
|
|
4618
4626
|
},
|
|
4619
4627
|
{
|
|
4620
4628
|
title: "Routed",
|
|
4621
|
-
body:
|
|
4629
|
+
body: _o(n.destination, n.state),
|
|
4622
4630
|
pill: r ? "Urgent · pinned first" : void 0
|
|
4623
4631
|
},
|
|
4624
4632
|
{
|
|
@@ -4635,19 +4643,19 @@ function _o({ routing: n = {}, flags: e = [], reference: t = "" }) {
|
|
|
4635
4643
|
}
|
|
4636
4644
|
];
|
|
4637
4645
|
}
|
|
4638
|
-
const Nt = "wral-report-it:draft:v1",
|
|
4639
|
-
function
|
|
4646
|
+
const Nt = "wral-report-it:draft:v1", Xr = 1;
|
|
4647
|
+
function Co(n, e) {
|
|
4640
4648
|
try {
|
|
4641
|
-
n.setItem(Nt, JSON.stringify({ ...e, v:
|
|
4649
|
+
n.setItem(Nt, JSON.stringify({ ...e, v: Xr, savedAt: Date.now() }));
|
|
4642
4650
|
} catch {
|
|
4643
4651
|
}
|
|
4644
4652
|
}
|
|
4645
|
-
function
|
|
4653
|
+
function xo(n) {
|
|
4646
4654
|
try {
|
|
4647
4655
|
const e = n.getItem(Nt);
|
|
4648
4656
|
if (!e) return null;
|
|
4649
4657
|
const t = JSON.parse(e);
|
|
4650
|
-
return t?.v !==
|
|
4658
|
+
return t?.v !== Xr ? null : t;
|
|
4651
4659
|
} catch {
|
|
4652
4660
|
return null;
|
|
4653
4661
|
}
|
|
@@ -4658,7 +4666,7 @@ function Ur(n) {
|
|
|
4658
4666
|
} catch {
|
|
4659
4667
|
}
|
|
4660
4668
|
}
|
|
4661
|
-
function
|
|
4669
|
+
function Eo({ apiOrigin: n, form: e, steps: t, requestId: r = null, mediaMeta: i = {} }) {
|
|
4662
4670
|
return {
|
|
4663
4671
|
apiOrigin: n,
|
|
4664
4672
|
formId: e.formId,
|
|
@@ -4668,13 +4676,13 @@ function xo({ apiOrigin: n, form: e, steps: t, requestId: r = null, mediaMeta: i
|
|
|
4668
4676
|
media: i
|
|
4669
4677
|
};
|
|
4670
4678
|
}
|
|
4671
|
-
function
|
|
4679
|
+
function Uo(n, e, { apiOrigin: t } = {}) {
|
|
4672
4680
|
if (!n) return { status: "discarded" };
|
|
4673
4681
|
if (t && n.apiOrigin && n.apiOrigin !== t)
|
|
4674
4682
|
return { status: "discarded" };
|
|
4675
4683
|
const r = (e || []).find((o) => o.formId === n.formId);
|
|
4676
4684
|
if (!r) return { status: "discarded" };
|
|
4677
|
-
const { error: i } =
|
|
4685
|
+
const { error: i } = Gr(r, n.steps || []);
|
|
4678
4686
|
if (i) return { status: "discarded" };
|
|
4679
4687
|
const s = {};
|
|
4680
4688
|
for (const [o, l] of Object.entries(n.media || {}))
|
|
@@ -4707,7 +4715,7 @@ function We(n = []) {
|
|
|
4707
4715
|
error: null
|
|
4708
4716
|
};
|
|
4709
4717
|
}
|
|
4710
|
-
function
|
|
4718
|
+
function To(n, e) {
|
|
4711
4719
|
switch (e.type) {
|
|
4712
4720
|
case "START":
|
|
4713
4721
|
return { ...n, stage: n.files.length ? "minting" : "requesting", error: null };
|
|
@@ -4734,7 +4742,7 @@ function Uo(n, e) {
|
|
|
4734
4742
|
}));
|
|
4735
4743
|
case "FILE_DONE": {
|
|
4736
4744
|
const t = Te(n, e.i, (r) => ({ ...r, status: "done", progress: 1 }));
|
|
4737
|
-
return
|
|
4745
|
+
return Io(t);
|
|
4738
4746
|
}
|
|
4739
4747
|
case "FILE_FAIL":
|
|
4740
4748
|
return { ...Te(n, e.i, (r) => ({
|
|
@@ -4775,14 +4783,14 @@ function Te(n, e, t) {
|
|
|
4775
4783
|
const r = n.files.map((i, s) => s === e ? t(i) : i);
|
|
4776
4784
|
return { ...n, files: r };
|
|
4777
4785
|
}
|
|
4778
|
-
function
|
|
4786
|
+
function Io(n) {
|
|
4779
4787
|
const e = n.files.every((r) => r.status === "done"), t = n.files.some((r) => r.status === "failed");
|
|
4780
4788
|
return e ? { ...n, stage: "requesting" } : t ? { ...n, stage: "uploading-error" } : n;
|
|
4781
4789
|
}
|
|
4782
4790
|
function Tr(n) {
|
|
4783
4791
|
return n.files.map((e, t) => ({ ...e, i: t })).filter((e) => e.status === "failed");
|
|
4784
4792
|
}
|
|
4785
|
-
const
|
|
4793
|
+
const Do = [
|
|
4786
4794
|
"Wake",
|
|
4787
4795
|
"Durham",
|
|
4788
4796
|
"Orange",
|
|
@@ -4799,9 +4807,14 @@ const Io = [
|
|
|
4799
4807
|
"Moore",
|
|
4800
4808
|
"Sampson",
|
|
4801
4809
|
"Other / outside the area"
|
|
4802
|
-
],
|
|
4803
|
-
|
|
4804
|
-
|
|
4810
|
+
], Ir = "(919) 821-8600", Ro = "https://www.wral.com/my-wral/";
|
|
4811
|
+
function ko(n) {
|
|
4812
|
+
const e = String(n).replace(/\D/g, "");
|
|
4813
|
+
return `tel:+1${e.length === 11 && e.startsWith("1") ? e.slice(1) : e}`;
|
|
4814
|
+
}
|
|
4815
|
+
const $o = "https://api.wral.com/forms", Po = 480, Fo = 2;
|
|
4816
|
+
class Bo extends se {
|
|
4817
|
+
static styles = zs;
|
|
4805
4818
|
static properties = {
|
|
4806
4819
|
api: { type: String },
|
|
4807
4820
|
_phase: { state: !0 },
|
|
@@ -4828,10 +4841,10 @@ class $o extends se {
|
|
|
4828
4841
|
#m = !1;
|
|
4829
4842
|
#u = null;
|
|
4830
4843
|
constructor() {
|
|
4831
|
-
super(), this.api =
|
|
4844
|
+
super(), this.api = $o, this._phase = "loading", this._forms = [], this._form = null, this._steps = [], this._typing = !1, this._cardValues = {}, this._fieldErrors = {}, this._gate = { stage: null, email: "", error: "", loading: !1 }, this._submit = We([]), this._banner = null, this._notice = null, this._result = null;
|
|
4832
4845
|
}
|
|
4833
4846
|
get client() {
|
|
4834
|
-
return this.#a ? this.#a : ((!this.#s || this.#h !== this.api) && (this.#s =
|
|
4847
|
+
return this.#a ? this.#a : ((!this.#s || this.#h !== this.api) && (this.#s = io({ baseUrl: this.api }), this.#h = this.api), this.#s);
|
|
4835
4848
|
}
|
|
4836
4849
|
set client(e) {
|
|
4837
4850
|
this.#a = e || null, this.isConnected && this.#v();
|
|
@@ -4869,7 +4882,7 @@ class $o extends se {
|
|
|
4869
4882
|
this._phase = "load-error";
|
|
4870
4883
|
return;
|
|
4871
4884
|
}
|
|
4872
|
-
const e =
|
|
4885
|
+
const e = Uo(xo(this.#f), this._forms, { apiOrigin: this.api });
|
|
4873
4886
|
if (e.status === "ok" || e.status === "review-required") {
|
|
4874
4887
|
this._form = e.form, this._steps = e.steps, this.#t = e.requestId, this.#n = e.lostMedia || {}, e.status === "review-required" ? this._notice = "This form changed since your last visit — please review your answers." : Object.keys(this.#n).length && (this._notice = "Welcome back — your answers were saved, but attachments need to be re-attached."), this.#o({ animate: !1 });
|
|
4875
4888
|
return;
|
|
@@ -4881,7 +4894,7 @@ class $o extends se {
|
|
|
4881
4894
|
const e = {};
|
|
4882
4895
|
for (const [t, r] of Object.entries(this.#r))
|
|
4883
4896
|
r.length && (e[t] = r.map(({ name: i, type: s, size: o }) => ({ name: i, type: s, size: o })));
|
|
4884
|
-
|
|
4897
|
+
Co(this.#f, Eo({
|
|
4885
4898
|
apiOrigin: this.api,
|
|
4886
4899
|
form: this._form,
|
|
4887
4900
|
steps: this._steps,
|
|
@@ -4893,10 +4906,10 @@ class $o extends se {
|
|
|
4893
4906
|
#o({ animate: e = !0 } = {}) {
|
|
4894
4907
|
this._phase = "walk", this._cardValues = {}, this._fieldErrors = {}, this._gate = { stage: null, email: "", error: "", loading: !1 }, e && !this.#D ? (this._typing = !0, clearTimeout(this.#g), this.#g = setTimeout(() => {
|
|
4895
4908
|
this._typing = !1;
|
|
4896
|
-
},
|
|
4909
|
+
}, Po)) : this._typing = !1;
|
|
4897
4910
|
}
|
|
4898
4911
|
get #A() {
|
|
4899
|
-
return this._form ?
|
|
4912
|
+
return this._form ? Gr(this._form, this._steps) : { node: null };
|
|
4900
4913
|
}
|
|
4901
4914
|
#R(e) {
|
|
4902
4915
|
this._form = e, this._steps = [], this.#t = null, this.#r = {}, this.#n = {}, this._notice = null, this.#l(), this.#o();
|
|
@@ -4921,7 +4934,7 @@ class $o extends se {
|
|
|
4921
4934
|
this._form = null, this._steps = [], this.#t = null, this.#r = {}, this.#n = {}, this._result = null, this._banner = null, this._notice = null, this._submit = We([]), Ur(this.#f), this._phase = "pick";
|
|
4922
4935
|
}
|
|
4923
4936
|
// ── Collect card ────────────────────────────────────────────────
|
|
4924
|
-
#
|
|
4937
|
+
#b(e, t) {
|
|
4925
4938
|
this._cardValues = { ...this._cardValues, [e]: t };
|
|
4926
4939
|
}
|
|
4927
4940
|
#$(e) {
|
|
@@ -4942,7 +4955,7 @@ class $o extends se {
|
|
|
4942
4955
|
nodeId: e.id,
|
|
4943
4956
|
kind: "collect",
|
|
4944
4957
|
values: { ...this._cardValues },
|
|
4945
|
-
summary:
|
|
4958
|
+
summary: wo(t, this._cardValues, l)
|
|
4946
4959
|
});
|
|
4947
4960
|
}
|
|
4948
4961
|
// ── Gate ────────────────────────────────────────────────────────
|
|
@@ -4960,7 +4973,7 @@ class $o extends se {
|
|
|
4960
4973
|
}));
|
|
4961
4974
|
}
|
|
4962
4975
|
}
|
|
4963
|
-
async #
|
|
4976
|
+
async #S() {
|
|
4964
4977
|
const e = this._gate.email.trim();
|
|
4965
4978
|
if (!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)) {
|
|
4966
4979
|
this._gate = { ...this._gate, error: "Please enter a valid email address." };
|
|
@@ -5011,7 +5024,7 @@ class $o extends se {
|
|
|
5011
5024
|
return e;
|
|
5012
5025
|
}
|
|
5013
5026
|
#e(e) {
|
|
5014
|
-
this._submit =
|
|
5027
|
+
this._submit = To(this._submit, e);
|
|
5015
5028
|
}
|
|
5016
5029
|
async #F() {
|
|
5017
5030
|
this._banner = null;
|
|
@@ -5058,7 +5071,7 @@ class $o extends se {
|
|
|
5058
5071
|
#U() {
|
|
5059
5072
|
const e = this._submit.files, t = this.#i.size;
|
|
5060
5073
|
let r = 0;
|
|
5061
|
-
for (let i = 0; i < e.length && t + r <
|
|
5074
|
+
for (let i = 0; i < e.length && t + r < Fo; i++)
|
|
5062
5075
|
e[i].status !== "uploading" || this.#i.has(i) || (r += 1, this.#M(i));
|
|
5063
5076
|
}
|
|
5064
5077
|
#M(e) {
|
|
@@ -5099,7 +5112,7 @@ class $o extends se {
|
|
|
5099
5112
|
}
|
|
5100
5113
|
async #N() {
|
|
5101
5114
|
try {
|
|
5102
|
-
const e = this._submit.files.map(({ assetId: r, type: i }) => ({ assetId: r, type: i })), t = await this.client.putRequest(this.#t,
|
|
5115
|
+
const e = this._submit.files.map(({ assetId: r, type: i }) => ({ assetId: r, type: i })), t = await this.client.putRequest(this.#t, po({
|
|
5103
5116
|
form: this._form,
|
|
5104
5117
|
steps: this._steps,
|
|
5105
5118
|
media: e
|
|
@@ -5110,7 +5123,7 @@ class $o extends se {
|
|
|
5110
5123
|
}
|
|
5111
5124
|
}
|
|
5112
5125
|
#_(e) {
|
|
5113
|
-
const t =
|
|
5126
|
+
const t = go(e?.status ?? 0, e?.body ?? null);
|
|
5114
5127
|
if (t.kind === "auth") {
|
|
5115
5128
|
this.#e({ type: "AUTH_REQUIRED" }), this._gate = { stage: "email", email: "", error: "", loading: !1 };
|
|
5116
5129
|
return;
|
|
@@ -5243,7 +5256,7 @@ class $o extends se {
|
|
|
5243
5256
|
`;
|
|
5244
5257
|
}
|
|
5245
5258
|
#Y(e, t, r) {
|
|
5246
|
-
const i = (s) => (o) => this.#
|
|
5259
|
+
const i = (s) => (o) => this.#b(s, o.target.value);
|
|
5247
5260
|
switch (t.kind) {
|
|
5248
5261
|
case "text":
|
|
5249
5262
|
return C`<input type="text" id="f-${t.key}" .value=${r || ""}
|
|
@@ -5272,7 +5285,7 @@ class $o extends se {
|
|
|
5272
5285
|
return C`
|
|
5273
5286
|
<div class="consent-row">
|
|
5274
5287
|
<input type="checkbox" id="f-${t.key}" .checked=${r === !0}
|
|
5275
|
-
@change=${(s) => this.#
|
|
5288
|
+
@change=${(s) => this.#b(t.key, s.target.checked)}>
|
|
5276
5289
|
<label for="f-${t.key}" style="all: unset; cursor: pointer;">
|
|
5277
5290
|
I took or own this material and give WRAL permission to use it
|
|
5278
5291
|
on air and online with credit to me.
|
|
@@ -5296,7 +5309,7 @@ class $o extends se {
|
|
|
5296
5309
|
}
|
|
5297
5310
|
}
|
|
5298
5311
|
#G(e, t) {
|
|
5299
|
-
const r = e.counties ||
|
|
5312
|
+
const r = e.counties || Do, i = (s) => this.#b(e.key, { ...t, ...s });
|
|
5300
5313
|
return C`
|
|
5301
5314
|
<select id="f-${e.key}" aria-label="County"
|
|
5302
5315
|
@change=${(s) => i({ county: s.target.value || void 0 })}>
|
|
@@ -5344,12 +5357,12 @@ class $o extends se {
|
|
|
5344
5357
|
this._gate = { ...t, email: i.target.value };
|
|
5345
5358
|
}}
|
|
5346
5359
|
@keydown=${(i) => {
|
|
5347
|
-
i.key === "Enter" && this.#
|
|
5360
|
+
i.key === "Enter" && this.#S();
|
|
5348
5361
|
}}>
|
|
5349
5362
|
</div>
|
|
5350
5363
|
${t.error ? C`<div class="err" role="alert">${t.error}</div>` : T}
|
|
5351
5364
|
<button type="button" class="login-btn" ?disabled=${t.loading}
|
|
5352
|
-
@click=${() => this.#
|
|
5365
|
+
@click=${() => this.#S()}>
|
|
5353
5366
|
${t.loading ? "Sending…" : "Continue with email"}
|
|
5354
5367
|
</button>
|
|
5355
5368
|
<div class="login-why">
|
|
@@ -5358,8 +5371,13 @@ class $o extends se {
|
|
|
5358
5371
|
<li>We can follow up on your report</li>
|
|
5359
5372
|
<li>Your contact information fills in automatically next time</li>
|
|
5360
5373
|
<li>You are credited by name when we use your photos or video</li>
|
|
5374
|
+
<li><a href=${Ro} target="_blank" rel="noopener">All other My WRAL account benefits</a></li>
|
|
5361
5375
|
</ul>
|
|
5362
5376
|
</div>
|
|
5377
|
+
<p class="login-anon">
|
|
5378
|
+
Want to remain anonymous? Call us at
|
|
5379
|
+
<a href=${ko(Ir)}>${Ir}</a>.
|
|
5380
|
+
</p>
|
|
5363
5381
|
</div>
|
|
5364
5382
|
` : C`
|
|
5365
5383
|
${r}
|
|
@@ -5388,7 +5406,7 @@ class $o extends se {
|
|
|
5388
5406
|
</button>
|
|
5389
5407
|
<p class="login-help">
|
|
5390
5408
|
Didn’t receive a code? Check your spam folder or
|
|
5391
|
-
<button type="button" @click=${() => this.#
|
|
5409
|
+
<button type="button" @click=${() => this.#S()}>resend a new code</button>.
|
|
5392
5410
|
</p>
|
|
5393
5411
|
</div>
|
|
5394
5412
|
` : C`${r}${lt()}`;
|
|
@@ -5413,7 +5431,7 @@ class $o extends se {
|
|
|
5413
5431
|
`;
|
|
5414
5432
|
}
|
|
5415
5433
|
#I() {
|
|
5416
|
-
const e =
|
|
5434
|
+
const e = bo(this._form, this._steps);
|
|
5417
5435
|
return C`
|
|
5418
5436
|
${z("Here is what you are sending.", "Check it over, then submit.")}
|
|
5419
5437
|
<div class="form-card">
|
|
@@ -5421,7 +5439,7 @@ class $o extends se {
|
|
|
5421
5439
|
${e.map((t) => C`
|
|
5422
5440
|
<li>
|
|
5423
5441
|
<span class="k">${t.k}</span>
|
|
5424
|
-
<span>${t.pill ?
|
|
5442
|
+
<span>${t.pill ? Ws(t.pill) : t.v}</span>
|
|
5425
5443
|
</li>
|
|
5426
5444
|
`)}
|
|
5427
5445
|
</ul>
|
|
@@ -5481,7 +5499,7 @@ class $o extends se {
|
|
|
5481
5499
|
`;
|
|
5482
5500
|
}
|
|
5483
5501
|
#X() {
|
|
5484
|
-
const e =
|
|
5502
|
+
const e = Jr(this._form, this._steps), t = So(this._result, e), r = Ao({
|
|
5485
5503
|
routing: this._result?.routing || {},
|
|
5486
5504
|
flags: e,
|
|
5487
5505
|
reference: this._result?.reference || ""
|
|
@@ -5489,7 +5507,7 @@ class $o extends se {
|
|
|
5489
5507
|
return C`
|
|
5490
5508
|
<div class="confirm-card">
|
|
5491
5509
|
<div class="c-head">
|
|
5492
|
-
<div class="c-check">${
|
|
5510
|
+
<div class="c-check">${Ys()}</div>
|
|
5493
5511
|
<div>
|
|
5494
5512
|
<div class="eyebrow">Report received</div>
|
|
5495
5513
|
<h2>${t.title}</h2>
|
|
@@ -5539,7 +5557,7 @@ class $o extends se {
|
|
|
5539
5557
|
this.renderRoot?.querySelector(".chat")?.lastElementChild?.scrollIntoView?.({ block: "nearest" });
|
|
5540
5558
|
}
|
|
5541
5559
|
}
|
|
5542
|
-
class
|
|
5560
|
+
class Mo extends se {
|
|
5543
5561
|
static properties = {
|
|
5544
5562
|
files: { attribute: !1 },
|
|
5545
5563
|
lostMeta: { attribute: !1 },
|
|
@@ -5599,7 +5617,7 @@ class Po extends se {
|
|
|
5599
5617
|
${e.map((r, i) => C`
|
|
5600
5618
|
<li>
|
|
5601
5619
|
<span>${r.name}</span>
|
|
5602
|
-
<span class="size">${
|
|
5620
|
+
<span class="size">${Oo(r.size)}</span>
|
|
5603
5621
|
<button type="button" class="remove"
|
|
5604
5622
|
aria-label="Remove ${r.name}"
|
|
5605
5623
|
@click=${() => this.#t(i)}>✕</button>
|
|
@@ -5618,15 +5636,15 @@ class Po extends se {
|
|
|
5618
5636
|
`;
|
|
5619
5637
|
}
|
|
5620
5638
|
}
|
|
5621
|
-
function
|
|
5639
|
+
function Oo(n) {
|
|
5622
5640
|
return Number.isFinite(n) ? n >= 1024 * 1024 ? `${(n / (1024 * 1024)).toFixed(1)} MB` : n >= 1024 ? `${Math.round(n / 1024)} KB` : `${n} B` : "";
|
|
5623
5641
|
}
|
|
5624
|
-
const
|
|
5642
|
+
const No = (n, e, t, r) => {
|
|
5625
5643
|
const i = e.target.value.replace(/\D/g, "").slice(-1), s = [...t];
|
|
5626
5644
|
s[n] = i;
|
|
5627
5645
|
const o = s.join(""), l = s.every((h) => h !== "");
|
|
5628
5646
|
return r("code-change", { value: o, complete: l }), i && l && r("code-complete", { value: o }), s;
|
|
5629
|
-
},
|
|
5647
|
+
}, qo = (n, e, t, r) => {
|
|
5630
5648
|
if (e.key === "Backspace") {
|
|
5631
5649
|
const i = [...t];
|
|
5632
5650
|
!i[n] && n > 0 ? i[n - 1] = "" : i[n] && (i[n] = "");
|
|
@@ -5634,7 +5652,7 @@ const Bo = (n, e, t, r) => {
|
|
|
5634
5652
|
return r("code-change", { value: s, complete: !1 }), i;
|
|
5635
5653
|
}
|
|
5636
5654
|
return t;
|
|
5637
|
-
},
|
|
5655
|
+
}, Lo = (n, e, t) => {
|
|
5638
5656
|
n.preventDefault();
|
|
5639
5657
|
const r = n.clipboardData.getData("text").replace(/\D/g, "").slice(0, 6);
|
|
5640
5658
|
if (r.length === 0) return e;
|
|
@@ -5644,7 +5662,7 @@ const Bo = (n, e, t, r) => {
|
|
|
5644
5662
|
const s = i.join(""), o = i.every((l) => l !== "");
|
|
5645
5663
|
return t("code-change", { value: s, complete: o }), r.length === 6 && t("code-complete", { value: s }), i;
|
|
5646
5664
|
};
|
|
5647
|
-
class
|
|
5665
|
+
class Ko extends se {
|
|
5648
5666
|
static formAssociated = !0;
|
|
5649
5667
|
static properties = {
|
|
5650
5668
|
_values: { type: Array, state: !0 },
|
|
@@ -5749,7 +5767,7 @@ class No extends se {
|
|
|
5749
5767
|
this.getInputs()[e]?.focus();
|
|
5750
5768
|
}
|
|
5751
5769
|
inputHandler(e, t) {
|
|
5752
|
-
this._values =
|
|
5770
|
+
this._values = No(
|
|
5753
5771
|
e,
|
|
5754
5772
|
t,
|
|
5755
5773
|
this._values,
|
|
@@ -5759,7 +5777,7 @@ class No extends se {
|
|
|
5759
5777
|
keydownHandler(e, t) {
|
|
5760
5778
|
if (t.key === "Backspace") {
|
|
5761
5779
|
const r = !this._values[e];
|
|
5762
|
-
this._values =
|
|
5780
|
+
this._values = qo(
|
|
5763
5781
|
e,
|
|
5764
5782
|
t,
|
|
5765
5783
|
this._values,
|
|
@@ -5768,7 +5786,7 @@ class No extends se {
|
|
|
5768
5786
|
}
|
|
5769
5787
|
}
|
|
5770
5788
|
pasteHandler(e) {
|
|
5771
|
-
this._values =
|
|
5789
|
+
this._values = Lo(e, this._values, this.dispatchCustomEvent.bind(this));
|
|
5772
5790
|
}
|
|
5773
5791
|
render() {
|
|
5774
5792
|
return C`
|
|
@@ -5792,19 +5810,19 @@ class No extends se {
|
|
|
5792
5810
|
`;
|
|
5793
5811
|
}
|
|
5794
5812
|
}
|
|
5795
|
-
typeof window < "u" && !window.AmazonCognitoIdentity && (window.AmazonCognitoIdentity =
|
|
5796
|
-
const
|
|
5797
|
-
"wral-report-it":
|
|
5798
|
-
"wral-report-media":
|
|
5799
|
-
"wral-code-input":
|
|
5813
|
+
typeof window < "u" && !window.AmazonCognitoIdentity && (window.AmazonCognitoIdentity = fs);
|
|
5814
|
+
const Vo = {
|
|
5815
|
+
"wral-report-it": Bo,
|
|
5816
|
+
"wral-report-media": Mo,
|
|
5817
|
+
"wral-code-input": Ko
|
|
5800
5818
|
};
|
|
5801
|
-
function
|
|
5819
|
+
function jo() {
|
|
5802
5820
|
const n = globalThis?.customElements;
|
|
5803
5821
|
if (n)
|
|
5804
|
-
for (const [e, t] of Object.entries(
|
|
5822
|
+
for (const [e, t] of Object.entries(Vo))
|
|
5805
5823
|
n.get(e) || n.define(e, t);
|
|
5806
5824
|
}
|
|
5807
|
-
typeof window < "u" && globalThis.customElements &&
|
|
5825
|
+
typeof window < "u" && globalThis.customElements && jo();
|
|
5808
5826
|
export {
|
|
5809
|
-
|
|
5827
|
+
jo as defineAll
|
|
5810
5828
|
};
|