@sesamy/sesamy-js 1.97.0 → 1.99.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/sesamy-js.cjs +5 -5
- package/dist/sesamy-js.d.ts +5 -1
- package/dist/sesamy-js.iife.js +5 -5
- package/dist/sesamy-js.mjs +458 -450
- package/package.json +1 -1
package/dist/sesamy-js.mjs
CHANGED
|
@@ -927,40 +927,40 @@ function lv() {
|
|
|
927
927
|
var e = Pe(), r = Le(), t = sr(), n = nv(), a = we(), i = cv(), o = hs(), s = ps(), u = dt(), c = Wr(), l = Ye(), f = ke(), v = Lt(), d = uv(), h = n.PROPER, p = n.CONFIGURABLE, S = d.IteratorPrototype, R = d.BUGGY_SAFARI_ITERATORS, I = f("iterator"), g = "keys", b = "values", y = "entries", A = function() {
|
|
928
928
|
return this;
|
|
929
929
|
};
|
|
930
|
-
return ci = function(
|
|
930
|
+
return ci = function($, j, G, z, re, x, M) {
|
|
931
931
|
i(G, j, z);
|
|
932
|
-
var N = function(
|
|
933
|
-
if (
|
|
934
|
-
if (!R &&
|
|
935
|
-
switch (
|
|
932
|
+
var N = function(Y) {
|
|
933
|
+
if (Y === re && w) return w;
|
|
934
|
+
if (!R && Y && Y in L) return L[Y];
|
|
935
|
+
switch (Y) {
|
|
936
936
|
case g:
|
|
937
937
|
return function() {
|
|
938
|
-
return new G(this,
|
|
938
|
+
return new G(this, Y);
|
|
939
939
|
};
|
|
940
940
|
case b:
|
|
941
941
|
return function() {
|
|
942
|
-
return new G(this,
|
|
942
|
+
return new G(this, Y);
|
|
943
943
|
};
|
|
944
944
|
case y:
|
|
945
945
|
return function() {
|
|
946
|
-
return new G(this,
|
|
946
|
+
return new G(this, Y);
|
|
947
947
|
};
|
|
948
948
|
}
|
|
949
949
|
return function() {
|
|
950
950
|
return new G(this);
|
|
951
951
|
};
|
|
952
|
-
}, m = j + " Iterator", C = !1,
|
|
953
|
-
if (T && (
|
|
952
|
+
}, m = j + " Iterator", C = !1, L = $.prototype, F = L[I] || L["@@iterator"] || re && L[re], w = !R && F || N(re), T = j === "Array" && L.entries || F, k, H, J;
|
|
953
|
+
if (T && (k = o(T.call(new $())), k !== Object.prototype && k.next && (!t && o(k) !== S && (s ? s(k, S) : a(k[I]) || l(k, I, A)), u(k, m, !0, !0), t && (v[m] = A))), h && re === b && F && F.name !== b && (!t && p ? c(L, "name", b) : (C = !0, w = function() {
|
|
954
954
|
return r(F, this);
|
|
955
955
|
})), re)
|
|
956
956
|
if (H = {
|
|
957
957
|
values: N(b),
|
|
958
|
-
keys:
|
|
958
|
+
keys: x ? w : N(g),
|
|
959
959
|
entries: N(y)
|
|
960
|
-
}, M) for (
|
|
961
|
-
(R || C || !(
|
|
960
|
+
}, M) for (J in H)
|
|
961
|
+
(R || C || !(J in L)) && l(L, J, H[J]);
|
|
962
962
|
else e({ target: j, proto: !0, forced: R || C }, H);
|
|
963
|
-
return (!t || M) &&
|
|
963
|
+
return (!t || M) && L[I] !== w && l(L, I, w, { name: re }), v[j] = w, H;
|
|
964
964
|
}, ci;
|
|
965
965
|
}
|
|
966
966
|
var li, yc;
|
|
@@ -1185,7 +1185,7 @@ var Oi, Nc;
|
|
|
1185
1185
|
function dv() {
|
|
1186
1186
|
if (Nc) return Oi;
|
|
1187
1187
|
Nc = 1, gs(), ep();
|
|
1188
|
-
var e = Pe(), r = me(), t = fv(), n = Je(), a = Le(), i = pe(), o = qe(), s = Sn(), u = Ye(), c = In(), l = rp(), f = dt(), v = cv(), d = ft(), h = ys(), p = we(), S = Ke(), R = vt(), I = xt(), g = er(), b = ze(), y = yr(), A = Ut(),
|
|
1188
|
+
var e = Pe(), r = me(), t = fv(), n = Je(), a = Le(), i = pe(), o = qe(), s = Sn(), u = Ye(), c = In(), l = rp(), f = dt(), v = cv(), d = ft(), h = ys(), p = we(), S = Ke(), R = vt(), I = xt(), g = er(), b = ze(), y = yr(), A = Ut(), $ = Gr(), j = ws(), G = Pn(), z = ms(), re = Vr(), x = ke(), M = np(), N = x("iterator"), m = "URLSearchParams", C = m + "Iterator", L = d.set, F = d.getterFor(m), w = d.getterFor(C), T = t("fetch"), k = t("Request"), H = t("Headers"), J = k && k.prototype, Y = H && H.prototype, le = r.TypeError, ne = r.encodeURIComponent, ue = String.fromCharCode, ae = n("String", "fromCodePoint"), Re = parseInt, xe = i("".charAt), je = i([].join), $e = i([].push), Qe = i("".replace), wr = i([].shift), Sr = i([].splice), _r = i("".split), Ar = i("".slice), yt = i(/./.exec), Kr = /\+/g, kr = "�", ye = /^[0-9a-f]+$/i, Xe = function(D, V) {
|
|
1189
1189
|
var K = Ar(D, V, V + 2);
|
|
1190
1190
|
return yt(ye, K) ? Re(K, 16) : NaN;
|
|
1191
1191
|
}, qr = function(D) {
|
|
@@ -1211,35 +1211,35 @@ function dv() {
|
|
|
1211
1211
|
return V > 1114111 ? null : V;
|
|
1212
1212
|
}, X = function(D) {
|
|
1213
1213
|
D = Qe(D, Kr, " ");
|
|
1214
|
-
for (var V = D.length, K = "",
|
|
1215
|
-
var ie = xe(D,
|
|
1214
|
+
for (var V = D.length, K = "", Q = 0; Q < V; ) {
|
|
1215
|
+
var ie = xe(D, Q);
|
|
1216
1216
|
if (ie === "%") {
|
|
1217
|
-
if (xe(D,
|
|
1218
|
-
K += "%",
|
|
1217
|
+
if (xe(D, Q + 1) === "%" || Q + 3 > V) {
|
|
1218
|
+
K += "%", Q++;
|
|
1219
1219
|
continue;
|
|
1220
1220
|
}
|
|
1221
|
-
var se = Xe(D,
|
|
1221
|
+
var se = Xe(D, Q + 1);
|
|
1222
1222
|
if (se !== se) {
|
|
1223
|
-
K += ie,
|
|
1223
|
+
K += ie, Q++;
|
|
1224
1224
|
continue;
|
|
1225
1225
|
}
|
|
1226
|
-
|
|
1226
|
+
Q += 2;
|
|
1227
1227
|
var ve = qr(se);
|
|
1228
1228
|
if (ve === 0)
|
|
1229
1229
|
ie = ue(se);
|
|
1230
1230
|
else {
|
|
1231
1231
|
if (ve === 1 || ve > 4) {
|
|
1232
|
-
K += kr,
|
|
1232
|
+
K += kr, Q++;
|
|
1233
1233
|
continue;
|
|
1234
1234
|
}
|
|
1235
|
-
for (var he = [se], Se = 1; Se < ve && (
|
|
1236
|
-
var Ue = Xe(D,
|
|
1235
|
+
for (var he = [se], Se = 1; Se < ve && (Q++, !(Q + 3 > V || xe(D, Q) !== "%")); ) {
|
|
1236
|
+
var Ue = Xe(D, Q + 1);
|
|
1237
1237
|
if (Ue !== Ue) {
|
|
1238
|
-
|
|
1238
|
+
Q += 3;
|
|
1239
1239
|
break;
|
|
1240
1240
|
}
|
|
1241
1241
|
if (Ue > 191 || Ue < 128) break;
|
|
1242
|
-
$e(he, Ue),
|
|
1242
|
+
$e(he, Ue), Q += 2, Se++;
|
|
1243
1243
|
}
|
|
1244
1244
|
if (he.length !== ve) {
|
|
1245
1245
|
K += kr;
|
|
@@ -1249,7 +1249,7 @@ function dv() {
|
|
|
1249
1249
|
tr === null ? K += kr : ie = ae(tr);
|
|
1250
1250
|
}
|
|
1251
1251
|
}
|
|
1252
|
-
K += ie,
|
|
1252
|
+
K += ie, Q++;
|
|
1253
1253
|
}
|
|
1254
1254
|
return K;
|
|
1255
1255
|
}, oe = /[!'()~]|%20/g, ce = {
|
|
@@ -1264,17 +1264,17 @@ function dv() {
|
|
|
1264
1264
|
}, He = function(D) {
|
|
1265
1265
|
return Qe(ne(D), oe, fe);
|
|
1266
1266
|
}, Te = v(function(V, K) {
|
|
1267
|
-
|
|
1267
|
+
L(this, {
|
|
1268
1268
|
type: C,
|
|
1269
1269
|
target: F(V).entries,
|
|
1270
1270
|
index: 0,
|
|
1271
1271
|
kind: K
|
|
1272
1272
|
});
|
|
1273
1273
|
}, m, function() {
|
|
1274
|
-
var V = w(this), K = V.target,
|
|
1275
|
-
if (!K ||
|
|
1274
|
+
var V = w(this), K = V.target, Q = V.index++;
|
|
1275
|
+
if (!K || Q >= K.length)
|
|
1276
1276
|
return V.target = null, z(void 0, !0);
|
|
1277
|
-
var ie = K[
|
|
1277
|
+
var ie = K[Q];
|
|
1278
1278
|
switch (V.kind) {
|
|
1279
1279
|
case "keys":
|
|
1280
1280
|
return z(ie.key, !1);
|
|
@@ -1291,9 +1291,9 @@ function dv() {
|
|
|
1291
1291
|
this.url = D, this.update();
|
|
1292
1292
|
},
|
|
1293
1293
|
parseObject: function(D) {
|
|
1294
|
-
var V = this.entries, K = G(D),
|
|
1294
|
+
var V = this.entries, K = G(D), Q, ie, se, ve, he, Se, Ue;
|
|
1295
1295
|
if (K)
|
|
1296
|
-
for (
|
|
1296
|
+
for (Q = j(D, K), ie = Q.next; !(se = a(ie, Q)).done; ) {
|
|
1297
1297
|
if (ve = j(g(se.value)), he = ve.next, (Se = a(he, ve)).done || (Ue = a(he, ve)).done || !a(he, ve).done) throw new le("Expected sequence with length 2");
|
|
1298
1298
|
$e(V, { key: y(Se.value), value: y(Ue.value) });
|
|
1299
1299
|
}
|
|
@@ -1301,15 +1301,15 @@ function dv() {
|
|
|
1301
1301
|
},
|
|
1302
1302
|
parseQuery: function(D) {
|
|
1303
1303
|
if (D)
|
|
1304
|
-
for (var V = this.entries, K = _r(D, "&"),
|
|
1305
|
-
ie = K[
|
|
1304
|
+
for (var V = this.entries, K = _r(D, "&"), Q = 0, ie, se; Q < K.length; )
|
|
1305
|
+
ie = K[Q++], ie.length && (se = _r(ie, "="), $e(V, {
|
|
1306
1306
|
key: X(wr(se)),
|
|
1307
1307
|
value: X(je(se, "="))
|
|
1308
1308
|
}));
|
|
1309
1309
|
},
|
|
1310
1310
|
serialize: function() {
|
|
1311
|
-
for (var D = this.entries, V = [], K = 0,
|
|
1312
|
-
|
|
1311
|
+
for (var D = this.entries, V = [], K = 0, Q; K < D.length; )
|
|
1312
|
+
Q = D[K++], $e(V, He(Q.key) + "=" + He(Q.value));
|
|
1313
1313
|
return je(V, "&");
|
|
1314
1314
|
},
|
|
1315
1315
|
update: function() {
|
|
@@ -1321,34 +1321,34 @@ function dv() {
|
|
|
1321
1321
|
};
|
|
1322
1322
|
var Oe = function() {
|
|
1323
1323
|
h(this, Ge);
|
|
1324
|
-
var V = arguments.length > 0 ? arguments[0] : void 0, K =
|
|
1324
|
+
var V = arguments.length > 0 ? arguments[0] : void 0, K = L(this, new De(V));
|
|
1325
1325
|
o || (this.size = K.entries.length);
|
|
1326
1326
|
}, Ge = Oe.prototype;
|
|
1327
1327
|
if (l(Ge, {
|
|
1328
1328
|
// `URLSearchParams.prototype.append` method
|
|
1329
1329
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-append
|
|
1330
1330
|
append: function(V, K) {
|
|
1331
|
-
var
|
|
1332
|
-
re(arguments.length, 2), $e(
|
|
1331
|
+
var Q = F(this);
|
|
1332
|
+
re(arguments.length, 2), $e(Q.entries, { key: y(V), value: y(K) }), o || this.length++, Q.updateURL();
|
|
1333
1333
|
},
|
|
1334
1334
|
// `URLSearchParams.prototype.delete` method
|
|
1335
1335
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-delete
|
|
1336
1336
|
delete: function(D) {
|
|
1337
|
-
for (var V = F(this), K = re(arguments.length, 1),
|
|
1338
|
-
var Se =
|
|
1337
|
+
for (var V = F(this), K = re(arguments.length, 1), Q = V.entries, ie = y(D), se = K < 2 ? void 0 : arguments[1], ve = se === void 0 ? se : y(se), he = 0; he < Q.length; ) {
|
|
1338
|
+
var Se = Q[he];
|
|
1339
1339
|
if (Se.key === ie && (ve === void 0 || Se.value === ve)) {
|
|
1340
|
-
if (Sr(
|
|
1340
|
+
if (Sr(Q, he, 1), ve !== void 0) break;
|
|
1341
1341
|
} else he++;
|
|
1342
1342
|
}
|
|
1343
|
-
o || (this.size =
|
|
1343
|
+
o || (this.size = Q.length), V.updateURL();
|
|
1344
1344
|
},
|
|
1345
1345
|
// `URLSearchParams.prototype.get` method
|
|
1346
1346
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-get
|
|
1347
1347
|
get: function(V) {
|
|
1348
1348
|
var K = F(this).entries;
|
|
1349
1349
|
re(arguments.length, 1);
|
|
1350
|
-
for (var
|
|
1351
|
-
if (K[ie].key ===
|
|
1350
|
+
for (var Q = y(V), ie = 0; ie < K.length; ie++)
|
|
1351
|
+
if (K[ie].key === Q) return K[ie].value;
|
|
1352
1352
|
return null;
|
|
1353
1353
|
},
|
|
1354
1354
|
// `URLSearchParams.prototype.getAll` method
|
|
@@ -1356,14 +1356,14 @@ function dv() {
|
|
|
1356
1356
|
getAll: function(V) {
|
|
1357
1357
|
var K = F(this).entries;
|
|
1358
1358
|
re(arguments.length, 1);
|
|
1359
|
-
for (var
|
|
1360
|
-
K[se].key ===
|
|
1359
|
+
for (var Q = y(V), ie = [], se = 0; se < K.length; se++)
|
|
1360
|
+
K[se].key === Q && $e(ie, K[se].value);
|
|
1361
1361
|
return ie;
|
|
1362
1362
|
},
|
|
1363
1363
|
// `URLSearchParams.prototype.has` method
|
|
1364
1364
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-has
|
|
1365
1365
|
has: function(V) {
|
|
1366
|
-
for (var K = F(this).entries,
|
|
1366
|
+
for (var K = F(this).entries, Q = re(arguments.length, 1), ie = y(V), se = Q < 2 ? void 0 : arguments[1], ve = se === void 0 ? se : y(se), he = 0; he < K.length; ) {
|
|
1367
1367
|
var Se = K[he++];
|
|
1368
1368
|
if (Se.key === ie && (ve === void 0 || Se.value === ve)) return !0;
|
|
1369
1369
|
}
|
|
@@ -1372,24 +1372,24 @@ function dv() {
|
|
|
1372
1372
|
// `URLSearchParams.prototype.set` method
|
|
1373
1373
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-set
|
|
1374
1374
|
set: function(V, K) {
|
|
1375
|
-
var
|
|
1375
|
+
var Q = F(this);
|
|
1376
1376
|
re(arguments.length, 1);
|
|
1377
|
-
for (var ie =
|
|
1377
|
+
for (var ie = Q.entries, se = !1, ve = y(V), he = y(K), Se = 0, Ue; Se < ie.length; Se++)
|
|
1378
1378
|
Ue = ie[Se], Ue.key === ve && (se ? Sr(ie, Se--, 1) : (se = !0, Ue.value = he));
|
|
1379
|
-
se || $e(ie, { key: ve, value: he }), o || (this.size = ie.length),
|
|
1379
|
+
se || $e(ie, { key: ve, value: he }), o || (this.size = ie.length), Q.updateURL();
|
|
1380
1380
|
},
|
|
1381
1381
|
// `URLSearchParams.prototype.sort` method
|
|
1382
1382
|
// https://url.spec.whatwg.org/#dom-urlsearchparams-sort
|
|
1383
1383
|
sort: function() {
|
|
1384
1384
|
var V = F(this);
|
|
1385
|
-
M(V.entries, function(K,
|
|
1386
|
-
return K.key >
|
|
1385
|
+
M(V.entries, function(K, Q) {
|
|
1386
|
+
return K.key > Q.key ? 1 : -1;
|
|
1387
1387
|
}), V.updateURL();
|
|
1388
1388
|
},
|
|
1389
1389
|
// `URLSearchParams.prototype.forEach` method
|
|
1390
1390
|
forEach: function(V) {
|
|
1391
|
-
for (var K = F(this).entries,
|
|
1392
|
-
se = K[ie++],
|
|
1391
|
+
for (var K = F(this).entries, Q = R(V, arguments.length > 1 ? arguments[1] : void 0), ie = 0, se; ie < K.length; )
|
|
1392
|
+
se = K[ie++], Q(se.value, se.key, this);
|
|
1393
1393
|
},
|
|
1394
1394
|
// `URLSearchParams.prototype.keys` method
|
|
1395
1395
|
keys: function() {
|
|
@@ -1414,13 +1414,13 @@ function dv() {
|
|
|
1414
1414
|
}), f(Oe, m), e({ global: !0, constructor: !0, forced: !s }, {
|
|
1415
1415
|
URLSearchParams: Oe
|
|
1416
1416
|
}), !s && p(H)) {
|
|
1417
|
-
var zr = i(
|
|
1417
|
+
var zr = i(Y.has), bt = i(Y.set), Jr = function(D) {
|
|
1418
1418
|
if (b(D)) {
|
|
1419
1419
|
var V = D.body, K;
|
|
1420
1420
|
if (I(V) === m)
|
|
1421
1421
|
return K = D.headers ? new H(D.headers) : new H(), zr(K, "content-type") || bt(K, "content-type", "application/x-www-form-urlencoded;charset=UTF-8"), A(D, {
|
|
1422
|
-
body:
|
|
1423
|
-
headers:
|
|
1422
|
+
body: $(0, y(V)),
|
|
1423
|
+
headers: $(0, K)
|
|
1424
1424
|
});
|
|
1425
1425
|
}
|
|
1426
1426
|
return D;
|
|
@@ -1429,11 +1429,11 @@ function dv() {
|
|
|
1429
1429
|
fetch: function(V) {
|
|
1430
1430
|
return T(V, arguments.length > 1 ? Jr(arguments[1]) : {});
|
|
1431
1431
|
}
|
|
1432
|
-
}), p(
|
|
1432
|
+
}), p(k)) {
|
|
1433
1433
|
var Yr = function(V) {
|
|
1434
|
-
return h(this,
|
|
1434
|
+
return h(this, J), new k(V, arguments.length > 1 ? Jr(arguments[1]) : {});
|
|
1435
1435
|
};
|
|
1436
|
-
|
|
1436
|
+
J.constructor = Yr, Yr.prototype = J, e({ global: !0, constructor: !0, dontCallGetSet: !0, forced: !0 }, {
|
|
1437
1437
|
Request: Yr
|
|
1438
1438
|
});
|
|
1439
1439
|
}
|
|
@@ -1456,8 +1456,8 @@ function ip() {
|
|
|
1456
1456
|
var v = arguments.length, d = v < 2 ? void 0 : arguments[1];
|
|
1457
1457
|
if (v && d === void 0) return s(this, f);
|
|
1458
1458
|
var h = [];
|
|
1459
|
-
u(this, function(A,
|
|
1460
|
-
c(h, { key:
|
|
1459
|
+
u(this, function(A, $) {
|
|
1460
|
+
c(h, { key: $, value: A });
|
|
1461
1461
|
}), n(v, 1);
|
|
1462
1462
|
for (var p = t(f), S = t(d), R = 0, I = 0, g = !1, b = h.length, y; R < b; )
|
|
1463
1463
|
y = h[R++], g || y.key === p ? (g = !0, s(this, y.key)) : I++;
|
|
@@ -1566,8 +1566,8 @@ function up() {
|
|
|
1566
1566
|
}), c({}, v)[h] !== 7 || a(c({}, d)).join("") !== p;
|
|
1567
1567
|
}) ? function(d, h) {
|
|
1568
1568
|
for (var p = s(d), S = arguments.length, R = 1, I = i.f, g = o.f; S > R; )
|
|
1569
|
-
for (var b = u(arguments[R++]), y = I ? f(a(b), I(b)) : a(b), A = y.length,
|
|
1570
|
-
j = y[
|
|
1569
|
+
for (var b = u(arguments[R++]), y = I ? f(a(b), I(b)) : a(b), A = y.length, $ = 0, j; A > $; )
|
|
1570
|
+
j = y[$++], (!e || t(g, b, j)) && (p[j] = b[j]);
|
|
1571
1571
|
return p;
|
|
1572
1572
|
} : c, ki;
|
|
1573
1573
|
}
|
|
@@ -1665,10 +1665,10 @@ function fp() {
|
|
|
1665
1665
|
return Ni = function(v) {
|
|
1666
1666
|
var d = t(v), h = i(this), p = arguments.length, S = p > 1 ? arguments[1] : void 0, R = S !== void 0;
|
|
1667
1667
|
R && (S = e(S, p > 2 ? arguments[2] : void 0));
|
|
1668
|
-
var I = c(d), g = 0, b, y, A,
|
|
1668
|
+
var I = c(d), g = 0, b, y, A, $, j, G;
|
|
1669
1669
|
if (I && !(this === l && a(I)))
|
|
1670
|
-
for (y = h ? new this() : [],
|
|
1671
|
-
G = R ? n(
|
|
1670
|
+
for (y = h ? new this() : [], $ = u(d, I), j = $.next; !(A = r(j, $)).done; g++)
|
|
1671
|
+
G = R ? n($, S, [A.value, g], !0) : A.value, s(y, g, G);
|
|
1672
1672
|
else
|
|
1673
1673
|
for (b = o(d), y = h ? new this(b) : l(b); b > g; g++)
|
|
1674
1674
|
G = R ? S(d[g], g) : d[g], s(y, g, G);
|
|
@@ -1679,56 +1679,56 @@ var ji, il;
|
|
|
1679
1679
|
function dp() {
|
|
1680
1680
|
if (il) return ji;
|
|
1681
1681
|
il = 1;
|
|
1682
|
-
var e = pe(), r = 2147483647, t = 36, n = 1, a = 26, i = 38, o = 700, s = 72, u = 128, c = "-", l = /[^\0-\u007E]/, f = /[.\u3002\uFF0E\uFF61]/g, v = "Overflow: input needs wider integers to process", d = t - n, h = RangeError, p = e(f.exec), S = Math.floor, R = String.fromCharCode, I = e("".charCodeAt), g = e([].join), b = e([].push), y = e("".replace), A = e("".split),
|
|
1683
|
-
for (var M = [], N = 0, m =
|
|
1684
|
-
var C = I(
|
|
1682
|
+
var e = pe(), r = 2147483647, t = 36, n = 1, a = 26, i = 38, o = 700, s = 72, u = 128, c = "-", l = /[^\0-\u007E]/, f = /[.\u3002\uFF0E\uFF61]/g, v = "Overflow: input needs wider integers to process", d = t - n, h = RangeError, p = e(f.exec), S = Math.floor, R = String.fromCharCode, I = e("".charCodeAt), g = e([].join), b = e([].push), y = e("".replace), A = e("".split), $ = e("".toLowerCase), j = function(x) {
|
|
1683
|
+
for (var M = [], N = 0, m = x.length; N < m; ) {
|
|
1684
|
+
var C = I(x, N++);
|
|
1685
1685
|
if (C >= 55296 && C <= 56319 && N < m) {
|
|
1686
|
-
var
|
|
1687
|
-
(
|
|
1686
|
+
var L = I(x, N++);
|
|
1687
|
+
(L & 64512) === 56320 ? b(M, ((C & 1023) << 10) + (L & 1023) + 65536) : (b(M, C), N--);
|
|
1688
1688
|
} else
|
|
1689
1689
|
b(M, C);
|
|
1690
1690
|
}
|
|
1691
1691
|
return M;
|
|
1692
|
-
}, G = function(
|
|
1693
|
-
return
|
|
1694
|
-
}, z = function(
|
|
1692
|
+
}, G = function(x) {
|
|
1693
|
+
return x + 22 + 75 * (x < 26);
|
|
1694
|
+
}, z = function(x, M, N) {
|
|
1695
1695
|
var m = 0;
|
|
1696
|
-
for (
|
|
1697
|
-
|
|
1698
|
-
return S(m + (d + 1) *
|
|
1699
|
-
}, re = function(
|
|
1696
|
+
for (x = N ? S(x / o) : x >> 1, x += S(x / M); x > d * a >> 1; )
|
|
1697
|
+
x = S(x / d), m += t;
|
|
1698
|
+
return S(m + (d + 1) * x / (x + i));
|
|
1699
|
+
}, re = function(x) {
|
|
1700
1700
|
var M = [];
|
|
1701
|
-
|
|
1702
|
-
var N =
|
|
1703
|
-
for (F = 0; F <
|
|
1704
|
-
w =
|
|
1705
|
-
var T = M.length,
|
|
1706
|
-
for (T && b(M, c);
|
|
1701
|
+
x = j(x);
|
|
1702
|
+
var N = x.length, m = u, C = 0, L = s, F, w;
|
|
1703
|
+
for (F = 0; F < x.length; F++)
|
|
1704
|
+
w = x[F], w < 128 && b(M, R(w));
|
|
1705
|
+
var T = M.length, k = T;
|
|
1706
|
+
for (T && b(M, c); k < N; ) {
|
|
1707
1707
|
var H = r;
|
|
1708
|
-
for (F = 0; F <
|
|
1709
|
-
w =
|
|
1710
|
-
var
|
|
1711
|
-
if (H - m > S((r - C) /
|
|
1708
|
+
for (F = 0; F < x.length; F++)
|
|
1709
|
+
w = x[F], w >= m && w < H && (H = w);
|
|
1710
|
+
var J = k + 1;
|
|
1711
|
+
if (H - m > S((r - C) / J))
|
|
1712
1712
|
throw new h(v);
|
|
1713
|
-
for (C += (H - m) *
|
|
1714
|
-
if (w =
|
|
1713
|
+
for (C += (H - m) * J, m = H, F = 0; F < x.length; F++) {
|
|
1714
|
+
if (w = x[F], w < m && ++C > r)
|
|
1715
1715
|
throw new h(v);
|
|
1716
1716
|
if (w === m) {
|
|
1717
|
-
for (var
|
|
1718
|
-
var ne = le <=
|
|
1719
|
-
if (
|
|
1720
|
-
var ue =
|
|
1721
|
-
b(M, R(G(ne + ue % ae))),
|
|
1717
|
+
for (var Y = C, le = t; ; ) {
|
|
1718
|
+
var ne = le <= L ? n : le >= L + a ? a : le - L;
|
|
1719
|
+
if (Y < ne) break;
|
|
1720
|
+
var ue = Y - ne, ae = t - ne;
|
|
1721
|
+
b(M, R(G(ne + ue % ae))), Y = S(ue / ae), le += t;
|
|
1722
1722
|
}
|
|
1723
|
-
b(M, R(G(
|
|
1723
|
+
b(M, R(G(Y))), L = z(C, J, k === T), C = 0, k++;
|
|
1724
1724
|
}
|
|
1725
1725
|
}
|
|
1726
1726
|
C++, m++;
|
|
1727
1727
|
}
|
|
1728
1728
|
return g(M, "");
|
|
1729
1729
|
};
|
|
1730
|
-
return ji = function(
|
|
1731
|
-
var M = [], N = A(y(
|
|
1730
|
+
return ji = function(x) {
|
|
1731
|
+
var M = [], N = A(y($(x), f, "."), "."), m, C;
|
|
1732
1732
|
for (m = 0; m < N.length; m++)
|
|
1733
1733
|
C = N[m], b(M, p(l, C) ? "xn--" + re(C) : C);
|
|
1734
1734
|
return g(M, ".");
|
|
@@ -1738,11 +1738,11 @@ var ol;
|
|
|
1738
1738
|
function vp() {
|
|
1739
1739
|
if (ol) return zc;
|
|
1740
1740
|
ol = 1, pv();
|
|
1741
|
-
var e = Pe(), r = qe(), t = Sn(), n = me(), a = vt(), i = pe(), o = Ye(), s = In(), u = ys(), c = Ke(), l = up(), f = fp(), v = En(), d = hv().codeAt, h = dp(), p = yr(), S = dt(), R = Vr(), I = dv(), g = ft(), b = g.set, y = g.getterFor("URL"), A = I.URLSearchParams,
|
|
1742
|
-
var
|
|
1743
|
-
if (
|
|
1741
|
+
var e = Pe(), r = qe(), t = Sn(), n = me(), a = vt(), i = pe(), o = Ye(), s = In(), u = ys(), c = Ke(), l = up(), f = fp(), v = En(), d = hv().codeAt, h = dp(), p = yr(), S = dt(), R = Vr(), I = dv(), g = ft(), b = g.set, y = g.getterFor("URL"), A = I.URLSearchParams, $ = I.getState, j = n.URL, G = n.TypeError, z = n.parseInt, re = Math.floor, x = Math.pow, M = i("".charAt), N = i(/./.exec), m = i([].join), C = i(1.1.toString), L = i([].pop), F = i([].push), w = i("".replace), T = i([].shift), k = i("".split), H = i("".slice), J = i("".toLowerCase), Y = i([].unshift), le = "Invalid authority", ne = "Invalid scheme", ue = "Invalid host", ae = "Invalid port", Re = /[a-z]/i, xe = /[\d+-.a-z]/i, je = /\d/, $e = /^0x/i, Qe = /^[0-7]+$/, wr = /^\d+$/, Sr = /^[\da-f]+$/i, _r = /[\0\t\n\r #%/:<>?@[\\\]^|]/, Ar = /[\0\t\n\r #/:<>?@[\\\]^|]/, yt = /^[\u0000-\u0020]+/, Kr = /(^|[^\u0000-\u0020])[\u0000-\u0020]+$/, kr = /[\t\n\r]/g, ye, Xe = function(E) {
|
|
1742
|
+
var U = k(E, "."), O, P, _, te, W, be, Ie;
|
|
1743
|
+
if (U.length && U[U.length - 1] === "" && U.length--, O = U.length, O > 4) return E;
|
|
1744
1744
|
for (P = [], _ = 0; _ < O; _++) {
|
|
1745
|
-
if (te =
|
|
1745
|
+
if (te = U[_], te === "") return E;
|
|
1746
1746
|
if (W = 10, te.length > 1 && M(te, 0) === "0" && (W = N($e, te) ? 16 : 8, te = H(te, W === 8 ? 1 : 2)), te === "")
|
|
1747
1747
|
be = 0;
|
|
1748
1748
|
else {
|
|
@@ -1753,13 +1753,13 @@ function vp() {
|
|
|
1753
1753
|
}
|
|
1754
1754
|
for (_ = 0; _ < O; _++)
|
|
1755
1755
|
if (be = P[_], _ === O - 1) {
|
|
1756
|
-
if (be >=
|
|
1756
|
+
if (be >= x(256, 5 - O)) return null;
|
|
1757
1757
|
} else if (be > 255) return null;
|
|
1758
|
-
for (Ie =
|
|
1759
|
-
Ie += P[_] *
|
|
1758
|
+
for (Ie = L(P), _ = 0; _ < P.length; _++)
|
|
1759
|
+
Ie += P[_] * x(256, 3 - _);
|
|
1760
1760
|
return Ie;
|
|
1761
1761
|
}, qr = function(E) {
|
|
1762
|
-
var
|
|
1762
|
+
var U = [0, 0, 0, 0, 0, 0, 0, 0], O = 0, P = null, _ = 0, te, W, be, Ie, Ce, Ve, q, Ee = function() {
|
|
1763
1763
|
return M(E, _);
|
|
1764
1764
|
};
|
|
1765
1765
|
if (Ee() === ":") {
|
|
@@ -1791,35 +1791,35 @@ function vp() {
|
|
|
1791
1791
|
if (Ie > 255) return;
|
|
1792
1792
|
_++;
|
|
1793
1793
|
}
|
|
1794
|
-
|
|
1794
|
+
U[O] = U[O] * 256 + Ie, be++, (be === 2 || be === 4) && O++;
|
|
1795
1795
|
}
|
|
1796
1796
|
if (be !== 4) return;
|
|
1797
1797
|
break;
|
|
1798
1798
|
} else if (Ee() === ":") {
|
|
1799
1799
|
if (_++, !Ee()) return;
|
|
1800
1800
|
} else if (Ee()) return;
|
|
1801
|
-
|
|
1801
|
+
U[O++] = te;
|
|
1802
1802
|
}
|
|
1803
1803
|
if (P !== null)
|
|
1804
1804
|
for (Ve = O - P, O = 7; O !== 0 && Ve > 0; )
|
|
1805
|
-
|
|
1805
|
+
q = U[O], U[O--] = U[P + Ve - 1], U[P + --Ve] = q;
|
|
1806
1806
|
else if (O !== 8) return;
|
|
1807
|
-
return
|
|
1807
|
+
return U;
|
|
1808
1808
|
}, B = function(E) {
|
|
1809
|
-
for (var
|
|
1810
|
-
E[te] !== 0 ? (_ > O && (
|
|
1811
|
-
return _ > O ? P :
|
|
1809
|
+
for (var U = null, O = 1, P = null, _ = 0, te = 0; te < 8; te++)
|
|
1810
|
+
E[te] !== 0 ? (_ > O && (U = P, O = _), P = null, _ = 0) : (P === null && (P = te), ++_);
|
|
1811
|
+
return _ > O ? P : U;
|
|
1812
1812
|
}, X = function(E) {
|
|
1813
|
-
var
|
|
1813
|
+
var U, O, P, _;
|
|
1814
1814
|
if (typeof E == "number") {
|
|
1815
|
-
for (
|
|
1816
|
-
|
|
1817
|
-
return m(
|
|
1815
|
+
for (U = [], O = 0; O < 4; O++)
|
|
1816
|
+
Y(U, E % 256), E = re(E / 256);
|
|
1817
|
+
return m(U, ".");
|
|
1818
1818
|
}
|
|
1819
1819
|
if (typeof E == "object") {
|
|
1820
|
-
for (
|
|
1821
|
-
_ && E[O] === 0 || (_ && (_ = !1), P === O ? (
|
|
1822
|
-
return "[" +
|
|
1820
|
+
for (U = "", P = B(E), O = 0; O < 8; O++)
|
|
1821
|
+
_ && E[O] === 0 || (_ && (_ = !1), P === O ? (U += O ? ":" : "::", _ = !0) : (U += C(E[O], 16), O < 7 && (U += ":")));
|
|
1822
|
+
return "[" + U + "]";
|
|
1823
1823
|
}
|
|
1824
1824
|
return E;
|
|
1825
1825
|
}, oe = {}, ce = l({}, oe, {
|
|
@@ -1844,9 +1844,9 @@ function vp() {
|
|
|
1844
1844
|
"]": 1,
|
|
1845
1845
|
"^": 1,
|
|
1846
1846
|
"|": 1
|
|
1847
|
-
}), Te = function(E,
|
|
1847
|
+
}), Te = function(E, U) {
|
|
1848
1848
|
var O = d(E, 0);
|
|
1849
|
-
return O > 32 && O < 127 && !c(
|
|
1849
|
+
return O > 32 && O < 127 && !c(U, E) ? E : encodeURIComponent(E);
|
|
1850
1850
|
}, De = {
|
|
1851
1851
|
ftp: 21,
|
|
1852
1852
|
file: null,
|
|
@@ -1854,93 +1854,93 @@ function vp() {
|
|
|
1854
1854
|
https: 443,
|
|
1855
1855
|
ws: 80,
|
|
1856
1856
|
wss: 443
|
|
1857
|
-
}, Oe = function(E,
|
|
1857
|
+
}, Oe = function(E, U) {
|
|
1858
1858
|
var O;
|
|
1859
|
-
return E.length === 2 && N(Re, M(E, 0)) && ((O = M(E, 1)) === ":" ||
|
|
1859
|
+
return E.length === 2 && N(Re, M(E, 0)) && ((O = M(E, 1)) === ":" || !U && O === "|");
|
|
1860
1860
|
}, Ge = function(E) {
|
|
1861
|
-
var
|
|
1862
|
-
return E.length > 1 && Oe(H(E, 0, 2)) && (E.length === 2 || (
|
|
1861
|
+
var U;
|
|
1862
|
+
return E.length > 1 && Oe(H(E, 0, 2)) && (E.length === 2 || (U = M(E, 2)) === "/" || U === "\\" || U === "?" || U === "#");
|
|
1863
1863
|
}, zr = function(E) {
|
|
1864
|
-
return E === "." ||
|
|
1864
|
+
return E === "." || J(E) === "%2e";
|
|
1865
1865
|
}, bt = function(E) {
|
|
1866
|
-
return E =
|
|
1867
|
-
}, Jr = {}, Yr = {}, D = {}, V = {}, K = {},
|
|
1866
|
+
return E = J(E), E === ".." || E === "%2e." || E === ".%2e" || E === "%2e%2e";
|
|
1867
|
+
}, Jr = {}, Yr = {}, D = {}, V = {}, K = {}, Q = {}, ie = {}, se = {}, ve = {}, he = {}, Se = {}, Ue = {}, tr = {}, $n = {}, Ns = {}, Un = {}, Qr = {}, nr = {}, js = {}, $r = {}, ur = {}, Ln = function(E, U, O) {
|
|
1868
1868
|
var P = p(E), _, te, W;
|
|
1869
|
-
if (
|
|
1869
|
+
if (U) {
|
|
1870
1870
|
if (te = this.parse(P), te) throw new G(te);
|
|
1871
1871
|
this.searchParams = null;
|
|
1872
1872
|
} else {
|
|
1873
1873
|
if (O !== void 0 && (_ = new Ln(O, !0)), te = this.parse(P, null, _), te) throw new G(te);
|
|
1874
|
-
W =
|
|
1874
|
+
W = $(new A()), W.bindURL(this), this.searchParams = W;
|
|
1875
1875
|
}
|
|
1876
1876
|
};
|
|
1877
1877
|
Ln.prototype = {
|
|
1878
1878
|
type: "URL",
|
|
1879
1879
|
// https://url.spec.whatwg.org/#url-parsing
|
|
1880
1880
|
// eslint-disable-next-line max-statements -- TODO
|
|
1881
|
-
parse: function(E,
|
|
1882
|
-
var P = this, _ =
|
|
1883
|
-
for (E = p(E),
|
|
1884
|
-
switch (
|
|
1881
|
+
parse: function(E, U, O) {
|
|
1882
|
+
var P = this, _ = U || Jr, te = 0, W = "", be = !1, Ie = !1, Ce = !1, Ve, q, Ee, cr;
|
|
1883
|
+
for (E = p(E), U || (P.scheme = "", P.username = "", P.password = "", P.host = null, P.port = null, P.path = [], P.query = null, P.fragment = null, P.cannotBeABaseURL = !1, E = w(E, yt, ""), E = w(E, Kr, "$1")), E = w(E, kr, ""), Ve = f(E); te <= Ve.length; ) {
|
|
1884
|
+
switch (q = Ve[te], _) {
|
|
1885
1885
|
case Jr:
|
|
1886
|
-
if (
|
|
1887
|
-
W +=
|
|
1886
|
+
if (q && N(Re, q))
|
|
1887
|
+
W += J(q), _ = Yr;
|
|
1888
1888
|
else {
|
|
1889
|
-
if (
|
|
1889
|
+
if (U)
|
|
1890
1890
|
return ne;
|
|
1891
1891
|
_ = D;
|
|
1892
1892
|
continue;
|
|
1893
1893
|
}
|
|
1894
1894
|
break;
|
|
1895
1895
|
case Yr:
|
|
1896
|
-
if (
|
|
1897
|
-
W +=
|
|
1898
|
-
else if (
|
|
1899
|
-
if (
|
|
1900
|
-
if (P.scheme = W,
|
|
1896
|
+
if (q && (N(xe, q) || q === "+" || q === "-" || q === "."))
|
|
1897
|
+
W += J(q);
|
|
1898
|
+
else if (q === ":") {
|
|
1899
|
+
if (U && (P.isSpecial() !== c(De, W) || W === "file" && (P.includesCredentials() || P.port !== null) || P.scheme === "file" && !P.host)) return;
|
|
1900
|
+
if (P.scheme = W, U) {
|
|
1901
1901
|
P.isSpecial() && De[P.scheme] === P.port && (P.port = null);
|
|
1902
1902
|
return;
|
|
1903
1903
|
}
|
|
1904
1904
|
W = "", P.scheme === "file" ? _ = $n : P.isSpecial() && O && O.scheme === P.scheme ? _ = V : P.isSpecial() ? _ = se : Ve[te + 1] === "/" ? (_ = K, te++) : (P.cannotBeABaseURL = !0, F(P.path, ""), _ = js);
|
|
1905
1905
|
} else {
|
|
1906
|
-
if (
|
|
1906
|
+
if (U)
|
|
1907
1907
|
return ne;
|
|
1908
1908
|
W = "", _ = D, te = 0;
|
|
1909
1909
|
continue;
|
|
1910
1910
|
}
|
|
1911
1911
|
break;
|
|
1912
1912
|
case D:
|
|
1913
|
-
if (!O || O.cannotBeABaseURL &&
|
|
1914
|
-
if (O.cannotBeABaseURL &&
|
|
1913
|
+
if (!O || O.cannotBeABaseURL && q !== "#") return ne;
|
|
1914
|
+
if (O.cannotBeABaseURL && q === "#") {
|
|
1915
1915
|
P.scheme = O.scheme, P.path = v(O.path), P.query = O.query, P.fragment = "", P.cannotBeABaseURL = !0, _ = ur;
|
|
1916
1916
|
break;
|
|
1917
1917
|
}
|
|
1918
|
-
_ = O.scheme === "file" ? $n :
|
|
1918
|
+
_ = O.scheme === "file" ? $n : Q;
|
|
1919
1919
|
continue;
|
|
1920
1920
|
case V:
|
|
1921
|
-
if (
|
|
1921
|
+
if (q === "/" && Ve[te + 1] === "/")
|
|
1922
1922
|
_ = ve, te++;
|
|
1923
1923
|
else {
|
|
1924
|
-
_ =
|
|
1924
|
+
_ = Q;
|
|
1925
1925
|
continue;
|
|
1926
1926
|
}
|
|
1927
1927
|
break;
|
|
1928
1928
|
case K:
|
|
1929
|
-
if (
|
|
1929
|
+
if (q === "/") {
|
|
1930
1930
|
_ = he;
|
|
1931
1931
|
break;
|
|
1932
1932
|
} else {
|
|
1933
1933
|
_ = nr;
|
|
1934
1934
|
continue;
|
|
1935
1935
|
}
|
|
1936
|
-
case
|
|
1937
|
-
if (P.scheme = O.scheme,
|
|
1936
|
+
case Q:
|
|
1937
|
+
if (P.scheme = O.scheme, q === ye)
|
|
1938
1938
|
P.username = O.username, P.password = O.password, P.host = O.host, P.port = O.port, P.path = v(O.path), P.query = O.query;
|
|
1939
|
-
else if (
|
|
1939
|
+
else if (q === "/" || q === "\\" && P.isSpecial())
|
|
1940
1940
|
_ = ie;
|
|
1941
|
-
else if (
|
|
1941
|
+
else if (q === "?")
|
|
1942
1942
|
P.username = O.username, P.password = O.password, P.host = O.host, P.port = O.port, P.path = v(O.path), P.query = "", _ = $r;
|
|
1943
|
-
else if (
|
|
1943
|
+
else if (q === "#")
|
|
1944
1944
|
P.username = O.username, P.password = O.password, P.host = O.host, P.port = O.port, P.path = v(O.path), P.query = O.query, P.fragment = "", _ = ur;
|
|
1945
1945
|
else {
|
|
1946
1946
|
P.username = O.username, P.password = O.password, P.host = O.host, P.port = O.port, P.path = v(O.path), P.path.length--, _ = nr;
|
|
@@ -1948,9 +1948,9 @@ function vp() {
|
|
|
1948
1948
|
}
|
|
1949
1949
|
break;
|
|
1950
1950
|
case ie:
|
|
1951
|
-
if (P.isSpecial() && (
|
|
1951
|
+
if (P.isSpecial() && (q === "/" || q === "\\"))
|
|
1952
1952
|
_ = ve;
|
|
1953
|
-
else if (
|
|
1953
|
+
else if (q === "/")
|
|
1954
1954
|
_ = he;
|
|
1955
1955
|
else {
|
|
1956
1956
|
P.username = O.username, P.password = O.password, P.host = O.host, P.port = O.port, _ = nr;
|
|
@@ -1958,17 +1958,17 @@ function vp() {
|
|
|
1958
1958
|
}
|
|
1959
1959
|
break;
|
|
1960
1960
|
case se:
|
|
1961
|
-
if (_ = ve,
|
|
1961
|
+
if (_ = ve, q !== "/" || M(W, te + 1) !== "/") continue;
|
|
1962
1962
|
te++;
|
|
1963
1963
|
break;
|
|
1964
1964
|
case ve:
|
|
1965
|
-
if (
|
|
1965
|
+
if (q !== "/" && q !== "\\") {
|
|
1966
1966
|
_ = he;
|
|
1967
1967
|
continue;
|
|
1968
1968
|
}
|
|
1969
1969
|
break;
|
|
1970
1970
|
case he:
|
|
1971
|
-
if (
|
|
1971
|
+
if (q === "@") {
|
|
1972
1972
|
be && (W = "%40" + W), be = !0, Ee = f(W);
|
|
1973
1973
|
for (var xn = 0; xn < Ee.length; xn++) {
|
|
1974
1974
|
var Fs = Ee[xn];
|
|
@@ -1980,47 +1980,47 @@ function vp() {
|
|
|
1980
1980
|
Ce ? P.password += Bs : P.username += Bs;
|
|
1981
1981
|
}
|
|
1982
1982
|
W = "";
|
|
1983
|
-
} else if (
|
|
1983
|
+
} else if (q === ye || q === "/" || q === "?" || q === "#" || q === "\\" && P.isSpecial()) {
|
|
1984
1984
|
if (be && W === "") return le;
|
|
1985
1985
|
te -= f(W).length + 1, W = "", _ = Se;
|
|
1986
|
-
} else W +=
|
|
1986
|
+
} else W += q;
|
|
1987
1987
|
break;
|
|
1988
1988
|
case Se:
|
|
1989
1989
|
case Ue:
|
|
1990
|
-
if (
|
|
1990
|
+
if (U && P.scheme === "file") {
|
|
1991
1991
|
_ = Un;
|
|
1992
1992
|
continue;
|
|
1993
|
-
} else if (
|
|
1993
|
+
} else if (q === ":" && !Ie) {
|
|
1994
1994
|
if (W === "") return ue;
|
|
1995
1995
|
if (cr = P.parseHost(W), cr) return cr;
|
|
1996
|
-
if (W = "", _ = tr,
|
|
1997
|
-
} else if (
|
|
1996
|
+
if (W = "", _ = tr, U === Ue) return;
|
|
1997
|
+
} else if (q === ye || q === "/" || q === "?" || q === "#" || q === "\\" && P.isSpecial()) {
|
|
1998
1998
|
if (P.isSpecial() && W === "") return ue;
|
|
1999
|
-
if (
|
|
1999
|
+
if (U && W === "" && (P.includesCredentials() || P.port !== null)) return;
|
|
2000
2000
|
if (cr = P.parseHost(W), cr) return cr;
|
|
2001
|
-
if (W = "", _ = Qr,
|
|
2001
|
+
if (W = "", _ = Qr, U) return;
|
|
2002
2002
|
continue;
|
|
2003
2003
|
} else
|
|
2004
|
-
|
|
2004
|
+
q === "[" ? Ie = !0 : q === "]" && (Ie = !1), W += q;
|
|
2005
2005
|
break;
|
|
2006
2006
|
case tr:
|
|
2007
|
-
if (N(je,
|
|
2008
|
-
W +=
|
|
2009
|
-
else if (
|
|
2007
|
+
if (N(je, q))
|
|
2008
|
+
W += q;
|
|
2009
|
+
else if (q === ye || q === "/" || q === "?" || q === "#" || q === "\\" && P.isSpecial() || U) {
|
|
2010
2010
|
if (W !== "") {
|
|
2011
2011
|
var Nn = z(W, 10);
|
|
2012
2012
|
if (Nn > 65535) return ae;
|
|
2013
2013
|
P.port = P.isSpecial() && Nn === De[P.scheme] ? null : Nn, W = "";
|
|
2014
2014
|
}
|
|
2015
|
-
if (
|
|
2015
|
+
if (U) return;
|
|
2016
2016
|
_ = Qr;
|
|
2017
2017
|
continue;
|
|
2018
2018
|
} else return ae;
|
|
2019
2019
|
break;
|
|
2020
2020
|
case $n:
|
|
2021
|
-
if (P.scheme = "file",
|
|
2021
|
+
if (P.scheme = "file", q === "/" || q === "\\") _ = Ns;
|
|
2022
2022
|
else if (O && O.scheme === "file")
|
|
2023
|
-
switch (
|
|
2023
|
+
switch (q) {
|
|
2024
2024
|
case ye:
|
|
2025
2025
|
P.host = O.host, P.path = v(O.path), P.query = O.query;
|
|
2026
2026
|
break;
|
|
@@ -2040,54 +2040,54 @@ function vp() {
|
|
|
2040
2040
|
}
|
|
2041
2041
|
break;
|
|
2042
2042
|
case Ns:
|
|
2043
|
-
if (
|
|
2043
|
+
if (q === "/" || q === "\\") {
|
|
2044
2044
|
_ = Un;
|
|
2045
2045
|
break;
|
|
2046
2046
|
}
|
|
2047
2047
|
O && O.scheme === "file" && !Ge(m(v(Ve, te), "")) && (Oe(O.path[0], !0) ? F(P.path, O.path[0]) : P.host = O.host), _ = nr;
|
|
2048
2048
|
continue;
|
|
2049
2049
|
case Un:
|
|
2050
|
-
if (
|
|
2051
|
-
if (
|
|
2050
|
+
if (q === ye || q === "/" || q === "\\" || q === "?" || q === "#") {
|
|
2051
|
+
if (!U && Oe(W))
|
|
2052
2052
|
_ = nr;
|
|
2053
2053
|
else if (W === "") {
|
|
2054
|
-
if (P.host = "",
|
|
2054
|
+
if (P.host = "", U) return;
|
|
2055
2055
|
_ = Qr;
|
|
2056
2056
|
} else {
|
|
2057
2057
|
if (cr = P.parseHost(W), cr) return cr;
|
|
2058
|
-
if (P.host === "localhost" && (P.host = ""),
|
|
2058
|
+
if (P.host === "localhost" && (P.host = ""), U) return;
|
|
2059
2059
|
W = "", _ = Qr;
|
|
2060
2060
|
}
|
|
2061
2061
|
continue;
|
|
2062
|
-
} else W +=
|
|
2062
|
+
} else W += q;
|
|
2063
2063
|
break;
|
|
2064
2064
|
case Qr:
|
|
2065
2065
|
if (P.isSpecial()) {
|
|
2066
|
-
if (_ = nr,
|
|
2067
|
-
} else if (
|
|
2066
|
+
if (_ = nr, q !== "/" && q !== "\\") continue;
|
|
2067
|
+
} else if (!U && q === "?")
|
|
2068
2068
|
P.query = "", _ = $r;
|
|
2069
|
-
else if (
|
|
2069
|
+
else if (!U && q === "#")
|
|
2070
2070
|
P.fragment = "", _ = ur;
|
|
2071
|
-
else if (
|
|
2071
|
+
else if (q !== ye && (_ = nr, q !== "/"))
|
|
2072
2072
|
continue;
|
|
2073
2073
|
break;
|
|
2074
2074
|
case nr:
|
|
2075
|
-
if (
|
|
2076
|
-
if (bt(W) ? (P.shortenPath(),
|
|
2075
|
+
if (q === ye || q === "/" || q === "\\" && P.isSpecial() || !U && (q === "?" || q === "#")) {
|
|
2076
|
+
if (bt(W) ? (P.shortenPath(), q !== "/" && !(q === "\\" && P.isSpecial()) && F(P.path, "")) : zr(W) ? q !== "/" && !(q === "\\" && P.isSpecial()) && F(P.path, "") : (P.scheme === "file" && !P.path.length && Oe(W) && (P.host && (P.host = ""), W = M(W, 0) + ":"), F(P.path, W)), W = "", P.scheme === "file" && (q === ye || q === "?" || q === "#"))
|
|
2077
2077
|
for (; P.path.length > 1 && P.path[0] === ""; )
|
|
2078
2078
|
T(P.path);
|
|
2079
|
-
|
|
2079
|
+
q === "?" ? (P.query = "", _ = $r) : q === "#" && (P.fragment = "", _ = ur);
|
|
2080
2080
|
} else
|
|
2081
|
-
W += Te(
|
|
2081
|
+
W += Te(q, fe);
|
|
2082
2082
|
break;
|
|
2083
2083
|
case js:
|
|
2084
|
-
|
|
2084
|
+
q === "?" ? (P.query = "", _ = $r) : q === "#" ? (P.fragment = "", _ = ur) : q !== ye && (P.path[0] += Te(q, oe));
|
|
2085
2085
|
break;
|
|
2086
2086
|
case $r:
|
|
2087
|
-
|
|
2087
|
+
!U && q === "#" ? (P.fragment = "", _ = ur) : q !== ye && (q === "'" && P.isSpecial() ? P.query += "%27" : q === "#" ? P.query += "%23" : P.query += Te(q, oe));
|
|
2088
2088
|
break;
|
|
2089
2089
|
case ur:
|
|
2090
|
-
|
|
2090
|
+
q !== ye && (P.fragment += Te(q, ce));
|
|
2091
2091
|
break;
|
|
2092
2092
|
}
|
|
2093
2093
|
te++;
|
|
@@ -2095,18 +2095,18 @@ function vp() {
|
|
|
2095
2095
|
},
|
|
2096
2096
|
// https://url.spec.whatwg.org/#host-parsing
|
|
2097
2097
|
parseHost: function(E) {
|
|
2098
|
-
var
|
|
2098
|
+
var U, O, P;
|
|
2099
2099
|
if (M(E, 0) === "[") {
|
|
2100
|
-
if (M(E, E.length - 1) !== "]" || (
|
|
2101
|
-
this.host =
|
|
2100
|
+
if (M(E, E.length - 1) !== "]" || (U = qr(H(E, 1, -1)), !U)) return ue;
|
|
2101
|
+
this.host = U;
|
|
2102
2102
|
} else if (this.isSpecial()) {
|
|
2103
|
-
if (E = h(E), N(_r, E) || (
|
|
2104
|
-
this.host =
|
|
2103
|
+
if (E = h(E), N(_r, E) || (U = Xe(E), U === null)) return ue;
|
|
2104
|
+
this.host = U;
|
|
2105
2105
|
} else {
|
|
2106
2106
|
if (N(Ar, E)) return ue;
|
|
2107
|
-
for (
|
|
2108
|
-
|
|
2109
|
-
this.host =
|
|
2107
|
+
for (U = "", O = f(E), P = 0; P < O.length; P++)
|
|
2108
|
+
U += Te(O[P], oe);
|
|
2109
|
+
this.host = U;
|
|
2110
2110
|
}
|
|
2111
2111
|
},
|
|
2112
2112
|
// https://url.spec.whatwg.org/#cannot-have-a-username-password-port
|
|
@@ -2123,29 +2123,29 @@ function vp() {
|
|
|
2123
2123
|
},
|
|
2124
2124
|
// https://url.spec.whatwg.org/#shorten-a-urls-path
|
|
2125
2125
|
shortenPath: function() {
|
|
2126
|
-
var E = this.path,
|
|
2127
|
-
|
|
2126
|
+
var E = this.path, U = E.length;
|
|
2127
|
+
U && (this.scheme !== "file" || U !== 1 || !Oe(E[0], !0)) && E.length--;
|
|
2128
2128
|
},
|
|
2129
2129
|
// https://url.spec.whatwg.org/#concept-url-serializer
|
|
2130
2130
|
serialize: function() {
|
|
2131
|
-
var E = this,
|
|
2132
|
-
return _ !== null ? (Ce += "//", E.includesCredentials() && (Ce += O + (P ? ":" + P : "") + "@"), Ce += X(_), te !== null && (Ce += ":" + te)) :
|
|
2131
|
+
var E = this, U = E.scheme, O = E.username, P = E.password, _ = E.host, te = E.port, W = E.path, be = E.query, Ie = E.fragment, Ce = U + ":";
|
|
2132
|
+
return _ !== null ? (Ce += "//", E.includesCredentials() && (Ce += O + (P ? ":" + P : "") + "@"), Ce += X(_), te !== null && (Ce += ":" + te)) : U === "file" && (Ce += "//"), Ce += E.cannotBeABaseURL ? W[0] : W.length ? "/" + m(W, "/") : "", be !== null && (Ce += "?" + be), Ie !== null && (Ce += "#" + Ie), Ce;
|
|
2133
2133
|
},
|
|
2134
2134
|
// https://url.spec.whatwg.org/#dom-url-href
|
|
2135
2135
|
setHref: function(E) {
|
|
2136
|
-
var
|
|
2137
|
-
if (
|
|
2136
|
+
var U = this.parse(E);
|
|
2137
|
+
if (U) throw new G(U);
|
|
2138
2138
|
this.searchParams.update();
|
|
2139
2139
|
},
|
|
2140
2140
|
// https://url.spec.whatwg.org/#dom-url-origin
|
|
2141
2141
|
getOrigin: function() {
|
|
2142
|
-
var E = this.scheme,
|
|
2142
|
+
var E = this.scheme, U = this.port;
|
|
2143
2143
|
if (E === "blob") try {
|
|
2144
2144
|
return new Xr(E.path[0]).origin;
|
|
2145
2145
|
} catch {
|
|
2146
2146
|
return "null";
|
|
2147
2147
|
}
|
|
2148
|
-
return E === "file" || !this.isSpecial() ? "null" : E + "://" + X(this.host) + (
|
|
2148
|
+
return E === "file" || !this.isSpecial() ? "null" : E + "://" + X(this.host) + (U !== null ? ":" + U : "");
|
|
2149
2149
|
},
|
|
2150
2150
|
// https://url.spec.whatwg.org/#dom-url-protocol
|
|
2151
2151
|
getProtocol: function() {
|
|
@@ -2159,11 +2159,11 @@ function vp() {
|
|
|
2159
2159
|
return this.username;
|
|
2160
2160
|
},
|
|
2161
2161
|
setUsername: function(E) {
|
|
2162
|
-
var
|
|
2162
|
+
var U = f(p(E));
|
|
2163
2163
|
if (!this.cannotHaveUsernamePasswordPort()) {
|
|
2164
2164
|
this.username = "";
|
|
2165
|
-
for (var O = 0; O <
|
|
2166
|
-
this.username += Te(
|
|
2165
|
+
for (var O = 0; O < U.length; O++)
|
|
2166
|
+
this.username += Te(U[O], He);
|
|
2167
2167
|
}
|
|
2168
2168
|
},
|
|
2169
2169
|
// https://url.spec.whatwg.org/#dom-url-password
|
|
@@ -2171,17 +2171,17 @@ function vp() {
|
|
|
2171
2171
|
return this.password;
|
|
2172
2172
|
},
|
|
2173
2173
|
setPassword: function(E) {
|
|
2174
|
-
var
|
|
2174
|
+
var U = f(p(E));
|
|
2175
2175
|
if (!this.cannotHaveUsernamePasswordPort()) {
|
|
2176
2176
|
this.password = "";
|
|
2177
|
-
for (var O = 0; O <
|
|
2178
|
-
this.password += Te(
|
|
2177
|
+
for (var O = 0; O < U.length; O++)
|
|
2178
|
+
this.password += Te(U[O], He);
|
|
2179
2179
|
}
|
|
2180
2180
|
},
|
|
2181
2181
|
// https://url.spec.whatwg.org/#dom-url-host
|
|
2182
2182
|
getHost: function() {
|
|
2183
|
-
var E = this.host,
|
|
2184
|
-
return E === null ? "" :
|
|
2183
|
+
var E = this.host, U = this.port;
|
|
2184
|
+
return E === null ? "" : U === null ? X(E) : X(E) + ":" + U;
|
|
2185
2185
|
},
|
|
2186
2186
|
setHost: function(E) {
|
|
2187
2187
|
this.cannotBeABaseURL || this.parse(E, Se);
|
|
@@ -2238,16 +2238,16 @@ function vp() {
|
|
|
2238
2238
|
this.query = this.searchParams.serialize() || null;
|
|
2239
2239
|
}
|
|
2240
2240
|
};
|
|
2241
|
-
var Xr = function(
|
|
2242
|
-
var O = u(this, Ne), P = R(arguments.length, 1) > 1 ? arguments[1] : void 0, _ = b(O, new Ln(
|
|
2241
|
+
var Xr = function(U) {
|
|
2242
|
+
var O = u(this, Ne), P = R(arguments.length, 1) > 1 ? arguments[1] : void 0, _ = b(O, new Ln(U, !1, P));
|
|
2243
2243
|
r || (O.href = _.serialize(), O.origin = _.getOrigin(), O.protocol = _.getProtocol(), O.username = _.getUsername(), O.password = _.getPassword(), O.host = _.getHost(), O.hostname = _.getHostname(), O.port = _.getPort(), O.pathname = _.getPathname(), O.search = _.getSearch(), O.searchParams = _.getSearchParams(), O.hash = _.getHash());
|
|
2244
|
-
}, Ne = Xr.prototype, We = function(E,
|
|
2244
|
+
}, Ne = Xr.prototype, We = function(E, U) {
|
|
2245
2245
|
return {
|
|
2246
2246
|
get: function() {
|
|
2247
2247
|
return y(this)[E]();
|
|
2248
2248
|
},
|
|
2249
|
-
set:
|
|
2250
|
-
return y(this)[
|
|
2249
|
+
set: U && function(O) {
|
|
2250
|
+
return y(this)[U](O);
|
|
2251
2251
|
},
|
|
2252
2252
|
configurable: !0,
|
|
2253
2253
|
enumerable: !0
|
|
@@ -2470,7 +2470,7 @@ function Nt() {
|
|
|
2470
2470
|
this.stopped = d, this.result = h;
|
|
2471
2471
|
}, v = f.prototype;
|
|
2472
2472
|
return Yi = function(d, h, p) {
|
|
2473
|
-
var S = p && p.that, R = !!(p && p.AS_ENTRIES), I = !!(p && p.IS_RECORD), g = !!(p && p.IS_ITERATOR), b = !!(p && p.INTERRUPTED), y = e(h, S), A,
|
|
2473
|
+
var S = p && p.that, R = !!(p && p.AS_ENTRIES), I = !!(p && p.IS_RECORD), g = !!(p && p.IS_ITERATOR), b = !!(p && p.INTERRUPTED), y = e(h, S), A, $, j, G, z, re, x, M = function(m) {
|
|
2474
2474
|
return A && c(A, "normal"), new f(!0, m);
|
|
2475
2475
|
}, N = function(m) {
|
|
2476
2476
|
return R ? (t(m), b ? y(m[0], m[1], M) : y(m[0], m[1])) : b ? y(m, M) : y(m);
|
|
@@ -2480,17 +2480,17 @@ function Nt() {
|
|
|
2480
2480
|
else if (g)
|
|
2481
2481
|
A = d;
|
|
2482
2482
|
else {
|
|
2483
|
-
if (
|
|
2484
|
-
if (a(
|
|
2483
|
+
if ($ = u(d), !$) throw new l(n(d) + " is not iterable");
|
|
2484
|
+
if (a($)) {
|
|
2485
2485
|
for (j = 0, G = i(d); G > j; j++)
|
|
2486
2486
|
if (z = N(d[j]), z && o(v, z)) return z;
|
|
2487
2487
|
return new f(!1);
|
|
2488
2488
|
}
|
|
2489
|
-
A = s(d,
|
|
2489
|
+
A = s(d, $);
|
|
2490
2490
|
}
|
|
2491
|
-
for (re = I ? d.next : A.next; !(
|
|
2491
|
+
for (re = I ? d.next : A.next; !(x = r(re, A)).done; ) {
|
|
2492
2492
|
try {
|
|
2493
|
-
z = N(
|
|
2493
|
+
z = N(x.value);
|
|
2494
2494
|
} catch (m) {
|
|
2495
2495
|
c(A, "throw", m);
|
|
2496
2496
|
}
|
|
@@ -2515,8 +2515,8 @@ function Ap() {
|
|
|
2515
2515
|
var e = Pe(), r = bn(), t = hs(), n = ps(), a = ov(), i = Ut(), o = Wr(), s = Gr(), u = Rp(), c = Cp(), l = Nt(), f = _p(), v = ke(), d = v("toStringTag"), h = Error, p = [].push, S = function(g, b) {
|
|
2516
2516
|
var y = r(R, this), A;
|
|
2517
2517
|
n ? A = n(new h(), y ? t(this) : R) : (A = y ? this : i(R), o(A, d, "Error")), b !== void 0 && o(A, "message", f(b)), c(A, S, A.stack, 1), arguments.length > 2 && u(A, arguments[2]);
|
|
2518
|
-
var
|
|
2519
|
-
return l(g, p, { that:
|
|
2518
|
+
var $ = [];
|
|
2519
|
+
return l(g, p, { that: $ }), o(A, "errors", $), A;
|
|
2520
2520
|
};
|
|
2521
2521
|
n ? n(S, h) : a(S, h, { name: !0 });
|
|
2522
2522
|
var R = S.prototype = i(h.prototype, {
|
|
@@ -2621,7 +2621,7 @@ var oo, Wl;
|
|
|
2621
2621
|
function Ev() {
|
|
2622
2622
|
if (Wl) return oo;
|
|
2623
2623
|
Wl = 1;
|
|
2624
|
-
var e = me(), r = Iv(), t = vt(), n = we(), a = Ke(), i = Ae(), o = ev(), s = En(), u = yn(), c = Vr(), l = Pv(), f = Ss(), v = e.setImmediate, d = e.clearImmediate, h = e.process, p = e.Dispatch, S = e.Function, R = e.MessageChannel, I = e.String, g = 0, b = {}, y = "onreadystatechange", A,
|
|
2624
|
+
var e = me(), r = Iv(), t = vt(), n = we(), a = Ke(), i = Ae(), o = ev(), s = En(), u = yn(), c = Vr(), l = Pv(), f = Ss(), v = e.setImmediate, d = e.clearImmediate, h = e.process, p = e.Dispatch, S = e.Function, R = e.MessageChannel, I = e.String, g = 0, b = {}, y = "onreadystatechange", A, $, j, G;
|
|
2625
2625
|
i(function() {
|
|
2626
2626
|
A = e.location;
|
|
2627
2627
|
});
|
|
@@ -2634,28 +2634,28 @@ function Ev() {
|
|
|
2634
2634
|
return function() {
|
|
2635
2635
|
z(N);
|
|
2636
2636
|
};
|
|
2637
|
-
},
|
|
2637
|
+
}, x = function(N) {
|
|
2638
2638
|
z(N.data);
|
|
2639
2639
|
}, M = function(N) {
|
|
2640
2640
|
e.postMessage(I(N), A.protocol + "//" + A.host);
|
|
2641
2641
|
};
|
|
2642
2642
|
return (!v || !d) && (v = function(m) {
|
|
2643
2643
|
c(arguments.length, 1);
|
|
2644
|
-
var C = n(m) ? m : S(m),
|
|
2644
|
+
var C = n(m) ? m : S(m), L = s(arguments, 1);
|
|
2645
2645
|
return b[++g] = function() {
|
|
2646
|
-
r(C, void 0,
|
|
2647
|
-
},
|
|
2646
|
+
r(C, void 0, L);
|
|
2647
|
+
}, $(g), g;
|
|
2648
2648
|
}, d = function(m) {
|
|
2649
2649
|
delete b[m];
|
|
2650
|
-
}, f ?
|
|
2650
|
+
}, f ? $ = function(N) {
|
|
2651
2651
|
h.nextTick(re(N));
|
|
2652
|
-
} : p && p.now ?
|
|
2652
|
+
} : p && p.now ? $ = function(N) {
|
|
2653
2653
|
p.now(re(N));
|
|
2654
|
-
} : R && !l ? (j = new R(), G = j.port2, j.port1.onmessage =
|
|
2654
|
+
} : R && !l ? (j = new R(), G = j.port2, j.port1.onmessage = x, $ = t(G.postMessage, G)) : e.addEventListener && n(e.postMessage) && !e.importScripts && A && A.protocol !== "file:" && !i(M) ? ($ = M, e.addEventListener("message", x, !1)) : y in u("script") ? $ = function(N) {
|
|
2655
2655
|
o.appendChild(u("script"))[y] = function() {
|
|
2656
2656
|
o.removeChild(this), z(N);
|
|
2657
2657
|
};
|
|
2658
|
-
} :
|
|
2658
|
+
} : $ = function(N) {
|
|
2659
2659
|
setTimeout(re(N), 0);
|
|
2660
2660
|
}), oo = {
|
|
2661
2661
|
set: v,
|
|
@@ -2707,8 +2707,8 @@ function jp() {
|
|
|
2707
2707
|
var y, A;
|
|
2708
2708
|
for (u && (y = f.domain) && y.exit(); A = g.get(); ) try {
|
|
2709
2709
|
A();
|
|
2710
|
-
} catch (
|
|
2711
|
-
throw g.head && h(),
|
|
2710
|
+
} catch ($) {
|
|
2711
|
+
throw g.head && h(), $;
|
|
2712
2712
|
}
|
|
2713
2713
|
y && y.enter();
|
|
2714
2714
|
};
|
|
@@ -2797,13 +2797,13 @@ var rf;
|
|
|
2797
2797
|
function Mp() {
|
|
2798
2798
|
if (rf) return Nl;
|
|
2799
2799
|
rf = 1;
|
|
2800
|
-
var e = Pe(), r = sr(), t = Ss(), n = me(), a = Rn(), i = Le(), o = Ye(), s = ps(), u = dt(), c = Up(), l = rr(), f = we(), v = ze(), d = ys(), h = Sv(), p = Ev().set, S = jp(), R = Dp(), I = ht(), g = Rv(), b = ft(), y = pt(), A = jt(),
|
|
2800
|
+
var e = Pe(), r = sr(), t = Ss(), n = me(), a = Rn(), i = Le(), o = Ye(), s = ps(), u = dt(), c = Up(), l = rr(), f = we(), v = ze(), d = ys(), h = Sv(), p = Ev().set, S = jp(), R = Dp(), I = ht(), g = Rv(), b = ft(), y = pt(), A = jt(), $ = br(), j = "Promise", G = A.CONSTRUCTOR, z = A.REJECTION_EVENT, re = A.SUBCLASSING, x = b.getterFor(j), M = b.set, N = y && y.prototype, m = y, C = N, L = n.TypeError, F = n.document, w = n.process, T = $.f, k = T, H = !!(F && F.createEvent && n.dispatchEvent), J = "unhandledrejection", Y = "rejectionhandled", le = 0, ne = 1, ue = 2, ae = 1, Re = 2, xe, je, $e, Qe, wr = function(B) {
|
|
2801
2801
|
var X;
|
|
2802
2802
|
return v(B) && f(X = B.then) ? X : !1;
|
|
2803
2803
|
}, Sr = function(B, X) {
|
|
2804
2804
|
var oe = X.value, ce = X.state === ne, fe = ce ? B.ok : B.fail, He = B.resolve, Te = B.reject, De = B.domain, Oe, Ge, zr;
|
|
2805
2805
|
try {
|
|
2806
|
-
fe ? (ce || (X.rejection === Re && kr(X), X.rejection = ae), fe === !0 ? Oe = oe : (De && De.enter(), Oe = fe(oe), De && (De.exit(), zr = !0)), Oe === B.promise ? Te(new
|
|
2806
|
+
fe ? (ce || (X.rejection === Re && kr(X), X.rejection = ae), fe === !0 ? Oe = oe : (De && De.enter(), Oe = fe(oe), De && (De.exit(), zr = !0)), Oe === B.promise ? Te(new L("Promise-chain cycle")) : (Ge = wr(Oe)) ? i(Ge, Oe, He, Te) : He(Oe)) : Te(oe);
|
|
2807
2807
|
} catch (bt) {
|
|
2808
2808
|
De && !zr && De.exit(), Te(bt);
|
|
2809
2809
|
}
|
|
@@ -2815,12 +2815,12 @@ function Mp() {
|
|
|
2815
2815
|
}));
|
|
2816
2816
|
}, Ar = function(B, X, oe) {
|
|
2817
2817
|
var ce, fe;
|
|
2818
|
-
H ? (ce = F.createEvent("Event"), ce.promise = X, ce.reason = oe, ce.initEvent(B, !1, !0), n.dispatchEvent(ce)) : ce = { promise: X, reason: oe }, !z && (fe = n["on" + B]) ? fe(ce) : B ===
|
|
2818
|
+
H ? (ce = F.createEvent("Event"), ce.promise = X, ce.reason = oe, ce.initEvent(B, !1, !0), n.dispatchEvent(ce)) : ce = { promise: X, reason: oe }, !z && (fe = n["on" + B]) ? fe(ce) : B === J && R("Unhandled promise rejection", oe);
|
|
2819
2819
|
}, yt = function(B) {
|
|
2820
2820
|
i(p, n, function() {
|
|
2821
2821
|
var X = B.facade, oe = B.value, ce = Kr(B), fe;
|
|
2822
2822
|
if (ce && (fe = I(function() {
|
|
2823
|
-
t ? w.emit("unhandledRejection", oe, X) : Ar(
|
|
2823
|
+
t ? w.emit("unhandledRejection", oe, X) : Ar(J, X, oe);
|
|
2824
2824
|
}), B.rejection = t || Kr(B) ? Re : ae, fe.error))
|
|
2825
2825
|
throw fe.value;
|
|
2826
2826
|
});
|
|
@@ -2829,7 +2829,7 @@ function Mp() {
|
|
|
2829
2829
|
}, kr = function(B) {
|
|
2830
2830
|
i(p, n, function() {
|
|
2831
2831
|
var X = B.facade;
|
|
2832
|
-
t ? w.emit("rejectionHandled", X) : Ar(
|
|
2832
|
+
t ? w.emit("rejectionHandled", X) : Ar(Y, X, B.value);
|
|
2833
2833
|
});
|
|
2834
2834
|
}, ye = function(B, X, oe) {
|
|
2835
2835
|
return function(ce) {
|
|
@@ -2841,7 +2841,7 @@ function Mp() {
|
|
|
2841
2841
|
if (!B.done) {
|
|
2842
2842
|
B.done = !0, oe && (B = oe);
|
|
2843
2843
|
try {
|
|
2844
|
-
if (B.facade === X) throw new
|
|
2844
|
+
if (B.facade === X) throw new L("Promise can't be resolved itself");
|
|
2845
2845
|
var ce = wr(X);
|
|
2846
2846
|
ce ? S(function() {
|
|
2847
2847
|
var fe = { done: !1 };
|
|
@@ -2863,7 +2863,7 @@ function Mp() {
|
|
|
2863
2863
|
};
|
|
2864
2864
|
if (G && (m = function(X) {
|
|
2865
2865
|
d(this, C), l(X), i(xe, this);
|
|
2866
|
-
var oe =
|
|
2866
|
+
var oe = x(this);
|
|
2867
2867
|
try {
|
|
2868
2868
|
X(ye(qr, oe), ye(Xe, oe));
|
|
2869
2869
|
} catch (ce) {
|
|
@@ -2881,15 +2881,15 @@ function Mp() {
|
|
|
2881
2881
|
value: null
|
|
2882
2882
|
});
|
|
2883
2883
|
}, xe.prototype = o(C, "then", function(X, oe) {
|
|
2884
|
-
var ce =
|
|
2884
|
+
var ce = x(this), fe = T(h(this, m));
|
|
2885
2885
|
return ce.parent = !0, fe.ok = f(X) ? X : !0, fe.fail = f(oe) && oe, fe.domain = t ? w.domain : void 0, ce.state === le ? ce.reactions.add(fe) : S(function() {
|
|
2886
2886
|
Sr(fe, ce);
|
|
2887
2887
|
}), fe.promise;
|
|
2888
2888
|
}), je = function() {
|
|
2889
|
-
var B = new xe(), X =
|
|
2889
|
+
var B = new xe(), X = x(B);
|
|
2890
2890
|
this.promise = B, this.resolve = ye(qr, X), this.reject = ye(Xe, X);
|
|
2891
|
-
},
|
|
2892
|
-
return B === m || B === $e ? new je(B) :
|
|
2891
|
+
}, $.f = T = function(B) {
|
|
2892
|
+
return B === m || B === $e ? new je(B) : k(B);
|
|
2893
2893
|
}, !r && f(y) && N !== Object.prototype)) {
|
|
2894
2894
|
Qe = N.then, re || o(N, "then", function(X, oe) {
|
|
2895
2895
|
var ce = this;
|
|
@@ -3081,11 +3081,11 @@ function Jp() {
|
|
|
3081
3081
|
var f = this, v = n("AggregateError"), d = a.f(f), h = d.resolve, p = d.reject, S = i(function() {
|
|
3082
3082
|
var R = t(f.resolve), I = [], g = 0, b = 1, y = !1;
|
|
3083
3083
|
o(l, function(A) {
|
|
3084
|
-
var
|
|
3084
|
+
var $ = g++, j = !1;
|
|
3085
3085
|
b++, r(R, f, A).then(function(G) {
|
|
3086
3086
|
j || y || (y = !0, h(G));
|
|
3087
3087
|
}, function(G) {
|
|
3088
|
-
j || y || (j = !0, I[
|
|
3088
|
+
j || y || (j = !0, I[$] = G, --b || p(new v(I, u)));
|
|
3089
3089
|
});
|
|
3090
3090
|
}), --b || p(new v(I, u));
|
|
3091
3091
|
});
|
|
@@ -3518,24 +3518,24 @@ const Cm = (e) => {
|
|
|
3518
3518
|
CAUSE: ` + d.stack, y.response = g, y.status = g.status, y.url = f, g.type === "opaque")
|
|
3519
3519
|
throw y;
|
|
3520
3520
|
const A = a.errorType === "json" || ((b = g.headers.get("Content-Type")) === null || b === void 0 ? void 0 : b.split(";")[0]) === "application/json";
|
|
3521
|
-
return (a.errorType ? A ? g.text() : g[a.errorType]() : Promise.resolve(g.body)).then((
|
|
3522
|
-
if (y.message = typeof
|
|
3523
|
-
if (A && typeof
|
|
3524
|
-
y.text =
|
|
3521
|
+
return (a.errorType ? A ? g.text() : g[a.errorType]() : Promise.resolve(g.body)).then(($) => {
|
|
3522
|
+
if (y.message = typeof $ == "string" ? $ : g.statusText, $)
|
|
3523
|
+
if (A && typeof $ == "string") {
|
|
3524
|
+
y.text = $;
|
|
3525
3525
|
try {
|
|
3526
|
-
y.json = JSON.parse(
|
|
3526
|
+
y.json = JSON.parse($);
|
|
3527
3527
|
} catch {
|
|
3528
3528
|
}
|
|
3529
3529
|
} else
|
|
3530
|
-
y[a.errorType] =
|
|
3530
|
+
y[a.errorType] = $;
|
|
3531
3531
|
throw y;
|
|
3532
3532
|
});
|
|
3533
3533
|
}
|
|
3534
3534
|
return g;
|
|
3535
3535
|
}), p = (g) => g.catch((b) => {
|
|
3536
|
-
const y = Object.prototype.hasOwnProperty.call(b, Zr), A = y ? b[Zr] : b,
|
|
3537
|
-
if (
|
|
3538
|
-
return
|
|
3536
|
+
const y = Object.prototype.hasOwnProperty.call(b, Zr), A = y ? b[Zr] : b, $ = A?.status && c.get(A.status) || c.get(A?.name) || y && c.has(Zr) && c.get(Zr);
|
|
3537
|
+
if ($)
|
|
3538
|
+
return $(A, e);
|
|
3539
3539
|
const j = c.get(xv);
|
|
3540
3540
|
if (j)
|
|
3541
3541
|
return j(A, e);
|
|
@@ -4600,7 +4600,7 @@ function Mv(e) {
|
|
|
4600
4600
|
localStorage.setItem(Bo, JSON.stringify({ value: t }));
|
|
4601
4601
|
}
|
|
4602
4602
|
}
|
|
4603
|
-
const Es = "@sesamy/sesamy-js", Dt = "1.
|
|
4603
|
+
const Es = "@sesamy/sesamy-js", Dt = "1.99.0", Fv = "sesamyFlags";
|
|
4604
4604
|
async function Bv(e) {
|
|
4605
4605
|
try {
|
|
4606
4606
|
localStorage.setItem(Fv, JSON.stringify(e));
|
|
@@ -4907,7 +4907,7 @@ async function Zv(e, r) {
|
|
|
4907
4907
|
if (!a)
|
|
4908
4908
|
throw new Error("User does not have access to the content");
|
|
4909
4909
|
let i;
|
|
4910
|
-
if (
|
|
4910
|
+
if (a.token)
|
|
4911
4911
|
i = a.token;
|
|
4912
4912
|
else {
|
|
4913
4913
|
const s = await Rr.entitlements.access(a.id);
|
|
@@ -4995,8 +4995,8 @@ function pg(e) {
|
|
|
4995
4995
|
tokenProvider: async () => {
|
|
4996
4996
|
if (await dr())
|
|
4997
4997
|
try {
|
|
4998
|
-
const
|
|
4999
|
-
return
|
|
4998
|
+
const L = await fr(!1);
|
|
4999
|
+
return L ? `Bearer ${L}` : null;
|
|
5000
5000
|
} catch {
|
|
5001
5001
|
}
|
|
5002
5002
|
const m = localStorage.getItem("__anon_id");
|
|
@@ -5009,27 +5009,27 @@ function pg(e) {
|
|
|
5009
5009
|
mode: rn.BROWSER,
|
|
5010
5010
|
storage: new tg()
|
|
5011
5011
|
}
|
|
5012
|
-
}), a = (m) => async (C,
|
|
5012
|
+
}), a = (m) => async (C, L) => {
|
|
5013
5013
|
let F = sessionStorage.getItem(Bf);
|
|
5014
5014
|
F || (F = Date.now().toString(), sessionStorage.setItem(Bf, F));
|
|
5015
5015
|
const w = {
|
|
5016
|
-
...
|
|
5017
|
-
headers: { ...
|
|
5016
|
+
...L,
|
|
5017
|
+
headers: { ...L.headers, "Cache-Timestamp": F }
|
|
5018
5018
|
};
|
|
5019
5019
|
return m(C, w);
|
|
5020
|
-
}, i = (m = !0) => (C) => async (
|
|
5020
|
+
}, i = (m = !0) => (C) => async (L, F) => {
|
|
5021
5021
|
const w = await fr(m);
|
|
5022
5022
|
if (!w) {
|
|
5023
5023
|
if (await dr()) {
|
|
5024
|
-
const
|
|
5024
|
+
const k = {
|
|
5025
5025
|
...F,
|
|
5026
5026
|
credentials: "include"
|
|
5027
5027
|
};
|
|
5028
|
-
return C(
|
|
5028
|
+
return C(L, k);
|
|
5029
5029
|
}
|
|
5030
5030
|
if (m)
|
|
5031
5031
|
throw new Error("No access token available");
|
|
5032
|
-
return C(
|
|
5032
|
+
return C(L, F);
|
|
5033
5033
|
}
|
|
5034
5034
|
const T = {
|
|
5035
5035
|
...F,
|
|
@@ -5038,7 +5038,7 @@ function pg(e) {
|
|
|
5038
5038
|
Authorization: `Bearer ${w}`
|
|
5039
5039
|
}
|
|
5040
5040
|
};
|
|
5041
|
-
return C(
|
|
5041
|
+
return C(L, T);
|
|
5042
5042
|
}, o = or(r).headers({ "Content-Type": "application/json" }).middlewares([
|
|
5043
5043
|
a,
|
|
5044
5044
|
i(),
|
|
@@ -5052,24 +5052,24 @@ function pg(e) {
|
|
|
5052
5052
|
})
|
|
5053
5053
|
]);
|
|
5054
5054
|
async function s(m = {}) {
|
|
5055
|
-
const { waitForEntitlementAfter: C, includeSignedLinks:
|
|
5055
|
+
const { waitForEntitlementAfter: C, includeSignedLinks: L = !0 } = m, F = await dr() ? await n.entitlements.list({
|
|
5056
5056
|
waitForEntitlementAfter: C?.toISOString()
|
|
5057
5057
|
}) : [];
|
|
5058
|
-
return
|
|
5058
|
+
return L && F.push(...Ps()), F;
|
|
5059
5059
|
}
|
|
5060
5060
|
async function u(m, C = []) {
|
|
5061
5061
|
return (await s())?.find((w) => {
|
|
5062
5062
|
if (m) {
|
|
5063
|
-
const { sku: T, purchaseOption:
|
|
5064
|
-
if ("sku" in w && T === w.sku ||
|
|
5063
|
+
const { sku: T, purchaseOption: k } = jv(m);
|
|
5064
|
+
if ("sku" in w && T === w.sku || k && "purchaseOptionsId" in w && k === w.purchaseOptionsId || Wf(m, w.url))
|
|
5065
5065
|
return !0;
|
|
5066
5066
|
}
|
|
5067
5067
|
return !!C.some((T) => Wf(T, w.url));
|
|
5068
5068
|
});
|
|
5069
5069
|
}
|
|
5070
|
-
async function c(m, C,
|
|
5070
|
+
async function c(m, C, L) {
|
|
5071
5071
|
const F = new URL(r, window.location.origin);
|
|
5072
|
-
return F.pathname = F.pathname.replace(/\/$/, "") + "/proxy", F.searchParams.set("url", C),
|
|
5072
|
+
return F.pathname = F.pathname.replace(/\/$/, "") + "/proxy", F.searchParams.set("url", C), L && F.searchParams.set("selector", L), or(F.toString()).headers({ Authorization: `Bearer ${m}` }).get().text();
|
|
5073
5073
|
}
|
|
5074
5074
|
async function l(m) {
|
|
5075
5075
|
if (!m)
|
|
@@ -5085,7 +5085,7 @@ function pg(e) {
|
|
|
5085
5085
|
return console.warn("getSubscriptions is deprecated, use getContracts instead"), o.get("/subscriptions").json();
|
|
5086
5086
|
}
|
|
5087
5087
|
async function d(m) {
|
|
5088
|
-
return (await n.transactions.list())?.find((
|
|
5088
|
+
return (await n.transactions.list())?.find((L) => L.id === m);
|
|
5089
5089
|
}
|
|
5090
5090
|
async function h() {
|
|
5091
5091
|
return await o.url("/tags").get().json();
|
|
@@ -5103,8 +5103,8 @@ function pg(e) {
|
|
|
5103
5103
|
}
|
|
5104
5104
|
async function I() {
|
|
5105
5105
|
const m = await n.tallies.list(), C = {};
|
|
5106
|
-
for (const
|
|
5107
|
-
C[
|
|
5106
|
+
for (const L of m)
|
|
5107
|
+
C[L.id] = L.value;
|
|
5108
5108
|
return C;
|
|
5109
5109
|
}
|
|
5110
5110
|
async function g(m) {
|
|
@@ -5120,7 +5120,7 @@ function pg(e) {
|
|
|
5120
5120
|
const C = await o.url("/profile").patch(m).res();
|
|
5121
5121
|
return vr(), C.ok;
|
|
5122
5122
|
}
|
|
5123
|
-
async function
|
|
5123
|
+
async function $() {
|
|
5124
5124
|
return (await o.url("/profile/spotify-link").get().json()).isSpotifyLinked;
|
|
5125
5125
|
}
|
|
5126
5126
|
async function j() {
|
|
@@ -5130,49 +5130,49 @@ function pg(e) {
|
|
|
5130
5130
|
const C = await fr(!1);
|
|
5131
5131
|
if (!C)
|
|
5132
5132
|
throw new Error("No access token available");
|
|
5133
|
-
const
|
|
5134
|
-
|
|
5133
|
+
const L = new URL(`${ar("access-sync", e.environment)}/spotify/sesamy-callback`);
|
|
5134
|
+
L.searchParams.set("access_token", C), L.searchParams.set("state", m), window.location.href = L.toString();
|
|
5135
5135
|
}
|
|
5136
5136
|
async function z(m) {
|
|
5137
5137
|
const C = await o.url(`/products/${encodeURIComponent(m)}/auto-onboard`).post().json();
|
|
5138
5138
|
return C.length && vr(), C;
|
|
5139
5139
|
}
|
|
5140
5140
|
async function re(m, C = 3600) {
|
|
5141
|
-
const { shortlink:
|
|
5142
|
-
return
|
|
5141
|
+
const { shortlink: L } = await or(rg).post({ url: m, ttl: C }).json();
|
|
5142
|
+
return L;
|
|
5143
5143
|
}
|
|
5144
|
-
async function
|
|
5144
|
+
async function x(m) {
|
|
5145
5145
|
const C = await fr(!1, !0);
|
|
5146
|
-
let
|
|
5146
|
+
let L;
|
|
5147
5147
|
const F = m.language || Qt(), w = tn();
|
|
5148
5148
|
switch (m.target) {
|
|
5149
5149
|
case "account":
|
|
5150
|
-
|
|
5150
|
+
L = new URL(
|
|
5151
5151
|
`${ar("account", e.environment)}/${encodeURIComponent(m.language || F)}/subscriptions/${encodeURIComponent(e.vendorId || e.clientId)}${m.contractId ? `/${encodeURIComponent(m.contractId)}` : ""}`
|
|
5152
|
-
),
|
|
5152
|
+
), L.searchParams.set("sesamy-redirect-url", m.redirectUrl || window.location.href);
|
|
5153
5153
|
break;
|
|
5154
5154
|
case "change-payment":
|
|
5155
|
-
|
|
5155
|
+
L = new URL(
|
|
5156
5156
|
`${ar("account", e.environment)}/${encodeURIComponent(m.language || F)}/subscriptions/${encodeURIComponent(e.vendorId || e.clientId)}/${encodeURIComponent(m.contractId)}/change-payment-method`
|
|
5157
|
-
),
|
|
5157
|
+
), L.searchParams.set("sesamy-redirect-url", m.redirectUrl || window.location.href);
|
|
5158
5158
|
break;
|
|
5159
5159
|
case "change-plan":
|
|
5160
|
-
|
|
5160
|
+
L = new URL(
|
|
5161
5161
|
`${ar("account", e.environment)}/${encodeURIComponent(m.language || F)}/subscriptions/${encodeURIComponent(e.vendorId || e.clientId)}/${encodeURIComponent(m.contractId)}/edit-plan`
|
|
5162
|
-
),
|
|
5162
|
+
), L.searchParams.set("sesamy-redirect-url", m.redirectUrl || window.location.href);
|
|
5163
5163
|
break;
|
|
5164
5164
|
case "consume":
|
|
5165
|
-
|
|
5165
|
+
L = new URL(
|
|
5166
5166
|
`${ar("consume", e.environment)}/${encodeURIComponent(m.language || F)}/@${encodeURIComponent(e.vendorId || e.clientId)}/${encodeURIComponent(m.sku)}`
|
|
5167
|
-
), m.episodeId ?
|
|
5167
|
+
), m.episodeId ? L.href += `/${m.episodeId}` : L.href += "/listen", L.searchParams.set("sesamy-redirect-url", m.redirectUrl || window.location.href);
|
|
5168
5168
|
break;
|
|
5169
5169
|
case "checkout":
|
|
5170
|
-
|
|
5170
|
+
L = ag(e, { language: F, ...m }, w);
|
|
5171
5171
|
break;
|
|
5172
5172
|
default:
|
|
5173
5173
|
throw new Error("Invalid target");
|
|
5174
5174
|
}
|
|
5175
|
-
return C && (
|
|
5175
|
+
return C && (L.hash = `#access_token=${C}`), m.shorten ? re(L.href, m.ttl) : L.href;
|
|
5176
5176
|
}
|
|
5177
5177
|
async function M() {
|
|
5178
5178
|
const m = await fr(!1), C = new URL(
|
|
@@ -5181,10 +5181,10 @@ function pg(e) {
|
|
|
5181
5181
|
m && (C.hash = `#access_token=${m}`), window.location.href = C.toString();
|
|
5182
5182
|
}
|
|
5183
5183
|
async function N(m) {
|
|
5184
|
-
const C = tn(),
|
|
5184
|
+
const C = tn(), L = ["_ga", "_gid", "_fbp", "_fbc"];
|
|
5185
5185
|
return document.cookie.split(";").forEach((F) => {
|
|
5186
5186
|
const [w, T] = F.trim().split("=");
|
|
5187
|
-
|
|
5187
|
+
L.includes(w) && !C[w] && (C[w] = T);
|
|
5188
5188
|
}), n.checkouts.create({
|
|
5189
5189
|
language: Qt(),
|
|
5190
5190
|
...m,
|
|
@@ -5211,13 +5211,13 @@ function pg(e) {
|
|
|
5211
5211
|
deleteTally: g,
|
|
5212
5212
|
entitlements: n.entitlements,
|
|
5213
5213
|
flags: { get: Gv, set: Hv, list: Mt, delete: Wv },
|
|
5214
|
-
generateLink:
|
|
5214
|
+
generateLink: x,
|
|
5215
5215
|
getProxyContent: c,
|
|
5216
5216
|
getEntitlements: s,
|
|
5217
5217
|
getFulfillments: l,
|
|
5218
5218
|
requestDelivery: f,
|
|
5219
5219
|
hasAccess: u,
|
|
5220
|
-
isSpotifyLinked:
|
|
5220
|
+
isSpotifyLinked: $,
|
|
5221
5221
|
linkSpotify: G,
|
|
5222
5222
|
openHostedAccountPage: M,
|
|
5223
5223
|
paywalls: n.paywalls,
|
|
@@ -5618,8 +5618,8 @@ function lh(e, r, t) {
|
|
|
5618
5618
|
var v = s.actions[f], d = v.plugin, h = v.payload.type, p = a[d][h];
|
|
5619
5619
|
if (p && Be(p)) {
|
|
5620
5620
|
var S, R = (function(b, y) {
|
|
5621
|
-
return b === void 0 && (b = {}), y === void 0 && (y = {}), [Ir, nt].reduce(function(A,
|
|
5622
|
-
return b.hasOwnProperty(
|
|
5621
|
+
return b === void 0 && (b = {}), y === void 0 && (y = {}), [Ir, nt].reduce(function(A, $) {
|
|
5622
|
+
return b.hasOwnProperty($) && y[$] && y[$] !== b[$] && (A[$] = y[$]), A;
|
|
5623
5623
|
}, b);
|
|
5624
5624
|
})(v.payload, u), I = n[R.meta.rid];
|
|
5625
5625
|
if (!I && (S = p({ payload: R, config: o[d].config, instance: t, abort: zg })) && Fe(S) && S.abort) return void (n[R.meta.rid] = !0);
|
|
@@ -5647,19 +5647,19 @@ var Ao = function(e) {
|
|
|
5647
5647
|
}));
|
|
5648
5648
|
var h = /* @__PURE__ */ (function(S, R) {
|
|
5649
5649
|
return function(I, g, b) {
|
|
5650
|
-
var y = g.config, A = g.name,
|
|
5651
|
-
b && (
|
|
5652
|
-
var j = I.type.match(it) ? /* @__PURE__ */ (function(G, z, re,
|
|
5650
|
+
var y = g.config, A = g.name, $ = A + "." + I.type;
|
|
5651
|
+
b && ($ = b.event);
|
|
5652
|
+
var j = I.type.match(it) ? /* @__PURE__ */ (function(G, z, re, x, M) {
|
|
5653
5653
|
return function(N, m) {
|
|
5654
|
-
var C =
|
|
5655
|
-
if (
|
|
5656
|
-
return ee({}, M, { abort: { reason: N, plugins:
|
|
5654
|
+
var C = x ? x.name : G, L = m && kt(m) ? m : re;
|
|
5655
|
+
if (x && (!(L = m && kt(m) ? m : [G]).includes(G) || L.length !== 1)) throw new Error("Method " + z + " can only abort " + G + " plugin. " + JSON.stringify(L) + " input valid");
|
|
5656
|
+
return ee({}, M, { abort: { reason: N, plugins: L, caller: z, _: C } });
|
|
5657
5657
|
};
|
|
5658
|
-
})(A,
|
|
5658
|
+
})(A, $, R, b, I) : /* @__PURE__ */ (function(G, z) {
|
|
5659
5659
|
return function() {
|
|
5660
5660
|
throw new Error(G.type + " action not cancellable. Remove abort in " + z);
|
|
5661
5661
|
};
|
|
5662
|
-
})(I,
|
|
5662
|
+
})(I, $);
|
|
5663
5663
|
return { payload: Jg(I), instance: S, config: y || {}, abort: j };
|
|
5664
5664
|
};
|
|
5665
5665
|
})(n, d), p = r.exact.reduce(function(S, R) {
|
|
@@ -5673,25 +5673,25 @@ var Ao = function(e) {
|
|
|
5673
5673
|
return Promise.resolve(b);
|
|
5674
5674
|
}
|
|
5675
5675
|
var A = (function() {
|
|
5676
|
-
if (r.namespaced && r.namespaced[g]) return Promise.resolve(r.namespaced[g].reduce(function(
|
|
5677
|
-
return Promise.resolve(
|
|
5676
|
+
if (r.namespaced && r.namespaced[g]) return Promise.resolve(r.namespaced[g].reduce(function($, j, G) {
|
|
5677
|
+
return Promise.resolve($).then(function(z) {
|
|
5678
5678
|
return j.method && Be(j.method) ? ((function(N, m) {
|
|
5679
5679
|
var C = sd(N);
|
|
5680
5680
|
if (C && C.name === m) {
|
|
5681
|
-
var
|
|
5682
|
-
throw new Error([m + " plugin is calling method " + N, "Plugins cant call self", "Use " + C.method + " " + (
|
|
5681
|
+
var L = sd(C.method);
|
|
5682
|
+
throw new Error([m + " plugin is calling method " + N, "Plugins cant call self", "Use " + C.method + " " + (L ? "or " + L.method : "") + " in " + m + " plugin insteadof " + N].join(`
|
|
5683
5683
|
`));
|
|
5684
5684
|
}
|
|
5685
|
-
})(j.methodName, j.pluginName), Promise.resolve(j.method({ payload: z, instance: n, abort: (re = z,
|
|
5686
|
-
return ee({}, re, { abort: { reason: N, plugins: m || [
|
|
5685
|
+
})(j.methodName, j.pluginName), Promise.resolve(j.method({ payload: z, instance: n, abort: (re = z, x = g, M = j.pluginName, function(N, m) {
|
|
5686
|
+
return ee({}, re, { abort: { reason: N, plugins: m || [x], caller: f, from: M || x } });
|
|
5687
5687
|
}), config: nd(j.pluginName, c, i), plugins: c })).then(function(N) {
|
|
5688
5688
|
var m = Fe(N) ? N : {};
|
|
5689
5689
|
return Promise.resolve(ee({}, z, m));
|
|
5690
5690
|
})) : z;
|
|
5691
|
-
var re,
|
|
5691
|
+
var re, x, M;
|
|
5692
5692
|
});
|
|
5693
|
-
}, Promise.resolve(t))).then(function(
|
|
5694
|
-
b[g] =
|
|
5693
|
+
}, Promise.resolve(t))).then(function($) {
|
|
5694
|
+
b[g] = $;
|
|
5695
5695
|
});
|
|
5696
5696
|
b[g] = t;
|
|
5697
5697
|
})();
|
|
@@ -5701,24 +5701,24 @@ var Ao = function(e) {
|
|
|
5701
5701
|
return Promise.resolve(r.exact.reduce(function(R, I, g) {
|
|
5702
5702
|
try {
|
|
5703
5703
|
var b = r.exact.length === g + 1, y = I.pluginName, A = i[y];
|
|
5704
|
-
return Promise.resolve(R).then(function(
|
|
5704
|
+
return Promise.resolve(R).then(function($) {
|
|
5705
5705
|
var j = S[y] ? S[y] : {};
|
|
5706
|
-
if (v && (j =
|
|
5707
|
-
if (qo(
|
|
5708
|
-
if (p.hasOwnProperty(y) && p[y] === !0) return s.dispatch({ type: "queue", plugin: y, payload: j, _: { called: "queue", from: "queueMechanism" } }), Promise.resolve(
|
|
5706
|
+
if (v && (j = $), qo(j, y)) return ko({ data: j, method: f, instance: n, pluginName: y, store: s }), Promise.resolve($);
|
|
5707
|
+
if (qo($, y)) return b && ko({ data: $, method: f, instance: n, store: s }), Promise.resolve($);
|
|
5708
|
+
if (p.hasOwnProperty(y) && p[y] === !0) return s.dispatch({ type: "queue", plugin: y, payload: j, _: { called: "queue", from: "queueMechanism" } }), Promise.resolve($);
|
|
5709
5709
|
var G = h(S[y], i[y]);
|
|
5710
5710
|
return Promise.resolve(A[f]({ abort: G.abort, payload: j, instance: n, config: nd(y, c, i), plugins: c })).then(function(z) {
|
|
5711
|
-
var re = Fe(z) ? z : {},
|
|
5711
|
+
var re = Fe(z) ? z : {}, x = ee({}, $, re), M = S[y];
|
|
5712
5712
|
if (qo(M, y)) ko({ data: M, method: f, instance: n, pluginName: y, store: s });
|
|
5713
5713
|
else {
|
|
5714
5714
|
var N = f + ":" + y;
|
|
5715
|
-
(N.match(/:/g) || []).length < 2 && !f.match(rd) && !f.match(td) && n.dispatch(ee({}, v ?
|
|
5715
|
+
(N.match(/:/g) || []).length < 2 && !f.match(rd) && !f.match(td) && n.dispatch(ee({}, v ? x : j, { type: N, _: { called: N, from: "submethod" } }));
|
|
5716
5716
|
}
|
|
5717
|
-
return Promise.resolve(
|
|
5717
|
+
return Promise.resolve(x);
|
|
5718
5718
|
});
|
|
5719
5719
|
});
|
|
5720
|
-
} catch (
|
|
5721
|
-
return Promise.reject(
|
|
5720
|
+
} catch ($) {
|
|
5721
|
+
return Promise.reject($);
|
|
5722
5722
|
}
|
|
5723
5723
|
}, Promise.resolve(t))).then(function(R) {
|
|
5724
5724
|
if (!(f.match(it) || f.match(/^registerPlugin/) || f.match(td) || f.match(rd) || f.match(/^params/) || f.match(/^userIdChanged/))) {
|
|
@@ -5794,9 +5794,9 @@ function Yg(e, r, t) {
|
|
|
5794
5794
|
}).map(function(b) {
|
|
5795
5795
|
return v[b];
|
|
5796
5796
|
}), p = [], S = [], R = o.disabled, I = h.map(function(b) {
|
|
5797
|
-
var y = b.loaded, A = b.name,
|
|
5797
|
+
var y = b.loaded, A = b.name, $ = b.config;
|
|
5798
5798
|
return ch(b, function() {
|
|
5799
|
-
return y({ config:
|
|
5799
|
+
return y({ config: $ });
|
|
5800
5800
|
}, 1e4).then(function(j) {
|
|
5801
5801
|
return n[A] || (a.dispatch({ type: Z.pluginReadyType(A), name: A, events: Object.keys(b).filter(function(G) {
|
|
5802
5802
|
return !Ko.includes(G);
|
|
@@ -5816,18 +5816,18 @@ function Yg(e, r, t) {
|
|
|
5816
5816
|
var g = (function() {
|
|
5817
5817
|
if (c !== Z.bootstrap) return /^ready:([^:]*)$/.test(c) && setTimeout(function() {
|
|
5818
5818
|
return lh(a, r, e);
|
|
5819
|
-
}, 0), Promise.resolve((function(b, y, A,
|
|
5819
|
+
}, 0), Promise.resolve((function(b, y, A, $, j) {
|
|
5820
5820
|
try {
|
|
5821
5821
|
var G = Be(y) ? y() : y, z = b.type, re = z.replace(it, "");
|
|
5822
5822
|
if (b._ && b._.called) return Promise.resolve(b);
|
|
5823
|
-
var
|
|
5823
|
+
var x = A.getState(), M = (C = G, (L = x.plugins) === void 0 && (L = {}), (F = b.options) === void 0 && (F = {}), Object.keys(C).filter(function(w) {
|
|
5824
5824
|
var T = F.plugins || {};
|
|
5825
|
-
return Ag(T[w]) ? T[w] : T.all !== !1 && (!
|
|
5825
|
+
return Ag(T[w]) ? T[w] : T.all !== !1 && (!L[w] || L[w].enabled !== !1);
|
|
5826
5826
|
}).map(function(w) {
|
|
5827
5827
|
return C[w];
|
|
5828
5828
|
}));
|
|
5829
|
-
z === Z.initializeStart && b.fromEnable && (M = Object.keys(
|
|
5830
|
-
var T =
|
|
5829
|
+
z === Z.initializeStart && b.fromEnable && (M = Object.keys(x.plugins).filter(function(w) {
|
|
5830
|
+
var T = x.plugins[w];
|
|
5831
5831
|
return b.plugins.includes(w) && !T.initialized;
|
|
5832
5832
|
}).map(function(w) {
|
|
5833
5833
|
return G[w];
|
|
@@ -5835,40 +5835,40 @@ function Yg(e, r, t) {
|
|
|
5835
5835
|
var N = M.map(function(w) {
|
|
5836
5836
|
return w.name;
|
|
5837
5837
|
}), m = (function(w, T) {
|
|
5838
|
-
var
|
|
5838
|
+
var k = id(w).map(function(H) {
|
|
5839
5839
|
return ad(H, T);
|
|
5840
5840
|
});
|
|
5841
|
-
return T.reduce(function(H,
|
|
5842
|
-
var
|
|
5841
|
+
return T.reduce(function(H, J) {
|
|
5842
|
+
var Y = J.name, le = id(w, Y).map(function(Re) {
|
|
5843
5843
|
return ad(Re, T);
|
|
5844
5844
|
}), ne = le[0], ue = le[1], ae = le[2];
|
|
5845
|
-
return ne.length && (H.beforeNS[
|
|
5846
|
-
}, { before:
|
|
5845
|
+
return ne.length && (H.beforeNS[Y] = ne), ue.length && (H.duringNS[Y] = ue), ae.length && (H.afterNS[Y] = ae), H;
|
|
5846
|
+
}, { before: k[0], beforeNS: {}, during: k[1], duringNS: {}, after: k[2], afterNS: {} });
|
|
5847
5847
|
})(z, M);
|
|
5848
|
-
return Promise.resolve(Ao({ action: b, data: { exact: m.before, namespaced: m.beforeNS }, state:
|
|
5848
|
+
return Promise.resolve(Ao({ action: b, data: { exact: m.before, namespaced: m.beforeNS }, state: x, allPlugins: G, allMatches: m, instance: A, store: $, EVENTS: j })).then(function(w) {
|
|
5849
5849
|
function T() {
|
|
5850
|
-
var
|
|
5851
|
-
if (z.match(it)) return Promise.resolve(Ao({ action: ee({},
|
|
5852
|
-
|
|
5850
|
+
var J = (function() {
|
|
5851
|
+
if (z.match(it)) return Promise.resolve(Ao({ action: ee({}, k, { type: re + "End" }), data: { exact: m.after, namespaced: m.afterNS }, state: x, allPlugins: G, allMatches: m, instance: A, store: $, EVENTS: j })).then(function(Y) {
|
|
5852
|
+
Y.meta && Y.meta.hasCallback && ed(Y.meta.rid, { payload: Y });
|
|
5853
5853
|
});
|
|
5854
5854
|
})();
|
|
5855
|
-
return
|
|
5855
|
+
return J && J.then ? J.then(function() {
|
|
5856
5856
|
return w;
|
|
5857
5857
|
}) : w;
|
|
5858
5858
|
}
|
|
5859
5859
|
if (fh(w, N.length)) return w;
|
|
5860
|
-
var
|
|
5861
|
-
if (z !== re) return Promise.resolve(Ao({ action: ee({}, w, { type: re }), data: { exact: m.during, namespaced: m.duringNS }, state:
|
|
5862
|
-
|
|
5860
|
+
var k, H = (function() {
|
|
5861
|
+
if (z !== re) return Promise.resolve(Ao({ action: ee({}, w, { type: re }), data: { exact: m.during, namespaced: m.duringNS }, state: x, allPlugins: G, allMatches: m, instance: A, store: $, EVENTS: j })).then(function(J) {
|
|
5862
|
+
k = J;
|
|
5863
5863
|
});
|
|
5864
|
-
|
|
5864
|
+
k = w;
|
|
5865
5865
|
})();
|
|
5866
5866
|
return H && H.then ? H.then(T) : T();
|
|
5867
5867
|
});
|
|
5868
5868
|
} catch (w) {
|
|
5869
5869
|
return Promise.reject(w);
|
|
5870
5870
|
}
|
|
5871
|
-
var C,
|
|
5871
|
+
var C, L, F;
|
|
5872
5872
|
})(o, r, e, a, t)).then(function(b) {
|
|
5873
5873
|
var y = i(b);
|
|
5874
5874
|
return s = 1, y;
|
|
@@ -6085,24 +6085,24 @@ function dy(e) {
|
|
|
6085
6085
|
if (Be(T)) return w.middlewares = w.middlewares.concat(T), w;
|
|
6086
6086
|
if (T.NAMESPACE && (T.name = T.NAMESPACE), !T.name) throw new Error("https://lytics.dev/errors/1");
|
|
6087
6087
|
T.config || (T.config = {});
|
|
6088
|
-
var
|
|
6089
|
-
return T.EVENTS[
|
|
6088
|
+
var k = T.EVENTS ? Object.keys(T.EVENTS).map(function(Y) {
|
|
6089
|
+
return T.EVENTS[Y];
|
|
6090
6090
|
}) : [];
|
|
6091
|
-
w.pluginEnabled[T.name] = !(T.enabled === !1 || T.config.enabled === !1), delete T.enabled, T.methods && (w.methods[T.name] = Object.keys(T.methods).reduce(function(
|
|
6091
|
+
w.pluginEnabled[T.name] = !(T.enabled === !1 || T.config.enabled === !1), delete T.enabled, T.methods && (w.methods[T.name] = Object.keys(T.methods).reduce(function(Y, le) {
|
|
6092
6092
|
var ne;
|
|
6093
|
-
return
|
|
6093
|
+
return Y[le] = (ne = T.methods[le], function() {
|
|
6094
6094
|
for (var ue = Array.prototype.slice.call(arguments), ae = new Array(ne.length), Re = 0; Re < ue.length; Re++) ae[Re] = ue[Re];
|
|
6095
6095
|
return ae[ae.length] = y, ne.apply({ instance: y }, ae);
|
|
6096
|
-
}),
|
|
6096
|
+
}), Y;
|
|
6097
6097
|
}, {}), delete T.methods);
|
|
6098
|
-
var H = Object.keys(T).concat(
|
|
6099
|
-
if (w.events = Array.from(
|
|
6098
|
+
var H = Object.keys(T).concat(k), J = new Set(w.events.concat(H));
|
|
6099
|
+
if (w.events = Array.from(J), w.pluginsArray = w.pluginsArray.concat(T), w.plugins[T.name]) throw new Error(T.name + "AlreadyLoaded");
|
|
6100
6100
|
return w.plugins[T.name] = T, w.plugins[T.name].loaded || (w.plugins[T.name].loaded = function() {
|
|
6101
6101
|
return !0;
|
|
6102
6102
|
}), w;
|
|
6103
6103
|
}, { plugins: {}, pluginEnabled: {}, methods: {}, pluginsArray: [], middlewares: [], events: [] }), a = e.storage ? e.storage : { getItem: Br, setItem: Hr, removeItem: mt }, i = /* @__PURE__ */ (function(w) {
|
|
6104
|
-
return function(T,
|
|
6105
|
-
return
|
|
6104
|
+
return function(T, k, H) {
|
|
6105
|
+
return k.getState("user")[T] || (H && Fe(H) && H[T] ? H[T] : Zf(w)[T] || Br(zo(T)) || null);
|
|
6106
6106
|
};
|
|
6107
6107
|
})(a), o = n.plugins, s = n.events.filter(function(w) {
|
|
6108
6108
|
return !Ko.includes(w);
|
|
@@ -6115,43 +6115,43 @@ function dy(e) {
|
|
|
6115
6115
|
}, S = Dg(), R = Zf(a), I = ee({}, R, t, S.an_uid ? { userId: S.an_uid } : {}, S.an_aid ? { anonymousId: S.an_aid } : {});
|
|
6116
6116
|
I.anonymousId || (I.anonymousId = _n());
|
|
6117
6117
|
var g = ee({ enable: function(w, T) {
|
|
6118
|
-
return new Promise(function(
|
|
6119
|
-
m.dispatch({ type: Z.enablePlugin, plugins: $o(w), _: { originalAction: Z.enablePlugin } },
|
|
6118
|
+
return new Promise(function(k) {
|
|
6119
|
+
m.dispatch({ type: Z.enablePlugin, plugins: $o(w), _: { originalAction: Z.enablePlugin } }, k, [T]);
|
|
6120
6120
|
});
|
|
6121
6121
|
}, disable: function(w, T) {
|
|
6122
|
-
return new Promise(function(
|
|
6123
|
-
m.dispatch({ type: Z.disablePlugin, plugins: $o(w), _: { originalAction: Z.disablePlugin } },
|
|
6122
|
+
return new Promise(function(k) {
|
|
6123
|
+
m.dispatch({ type: Z.disablePlugin, plugins: $o(w), _: { originalAction: Z.disablePlugin } }, k, [T]);
|
|
6124
6124
|
});
|
|
6125
|
-
} }, n.methods), b = !1, y = { identify: function(w, T,
|
|
6125
|
+
} }, n.methods), b = !1, y = { identify: function(w, T, k, H) {
|
|
6126
6126
|
try {
|
|
6127
|
-
var
|
|
6128
|
-
Hr(zo(Ir),
|
|
6129
|
-
var ue =
|
|
6127
|
+
var J = Tr(w) ? w : null, Y = Fe(w) ? w : T, le = k || {}, ne = y.user();
|
|
6128
|
+
Hr(zo(Ir), J);
|
|
6129
|
+
var ue = J || Y.userId || i(Ir, y, Y);
|
|
6130
6130
|
return Promise.resolve(new Promise(function(ae) {
|
|
6131
|
-
m.dispatch(ee({ type: Z.identifyStart, userId: ue, traits:
|
|
6131
|
+
m.dispatch(ee({ type: Z.identifyStart, userId: ue, traits: Y || {}, options: le, anonymousId: ne.anonymousId }, ne.id && ne.id !== J && { previousId: ne.id }), ae, [T, k, H]);
|
|
6132
6132
|
}));
|
|
6133
6133
|
} catch (ae) {
|
|
6134
6134
|
return Promise.reject(ae);
|
|
6135
6135
|
}
|
|
6136
|
-
}, track: function(w, T,
|
|
6136
|
+
}, track: function(w, T, k, H) {
|
|
6137
6137
|
try {
|
|
6138
|
-
var
|
|
6139
|
-
if (!
|
|
6140
|
-
var
|
|
6138
|
+
var J = Fe(w) ? w.event : w;
|
|
6139
|
+
if (!J || !Tr(J)) throw new Error("EventMissing");
|
|
6140
|
+
var Y = Fe(w) ? w : T || {}, le = Fe(k) ? k : {};
|
|
6141
6141
|
return Promise.resolve(new Promise(function(ne) {
|
|
6142
|
-
m.dispatch({ type: Z.trackStart, event:
|
|
6142
|
+
m.dispatch({ type: Z.trackStart, event: J, properties: Y, options: le, userId: i(Ir, y, T), anonymousId: i(nt, y, T) }, ne, [T, k, H]);
|
|
6143
6143
|
}));
|
|
6144
6144
|
} catch (ne) {
|
|
6145
6145
|
return Promise.reject(ne);
|
|
6146
6146
|
}
|
|
6147
|
-
}, page: function(w, T,
|
|
6147
|
+
}, page: function(w, T, k) {
|
|
6148
6148
|
try {
|
|
6149
|
-
var H = Fe(w) ? w : {},
|
|
6150
|
-
return Promise.resolve(new Promise(function(
|
|
6151
|
-
m.dispatch({ type: Z.pageStart, properties: iy(H), options:
|
|
6149
|
+
var H = Fe(w) ? w : {}, J = Fe(T) ? T : {};
|
|
6150
|
+
return Promise.resolve(new Promise(function(Y) {
|
|
6151
|
+
m.dispatch({ type: Z.pageStart, properties: iy(H), options: J, userId: i(Ir, y, H), anonymousId: i(nt, y, H) }, Y, [w, T, k]);
|
|
6152
6152
|
}));
|
|
6153
|
-
} catch (
|
|
6154
|
-
return Promise.reject(
|
|
6153
|
+
} catch (Y) {
|
|
6154
|
+
return Promise.reject(Y);
|
|
6155
6155
|
}
|
|
6156
6156
|
}, user: function(w) {
|
|
6157
6157
|
if (w === Ir || w === "id") return i(Ir, y);
|
|
@@ -6169,96 +6169,96 @@ function dy(e) {
|
|
|
6169
6169
|
}, on: function(w, T) {
|
|
6170
6170
|
if (!w || !Be(T)) return !1;
|
|
6171
6171
|
if (w === Z.bootstrap) throw new Error(".on disabled for " + w);
|
|
6172
|
-
var
|
|
6172
|
+
var k = /Start$|Start:/;
|
|
6173
6173
|
if (w === "*") {
|
|
6174
6174
|
var H = function(ne) {
|
|
6175
6175
|
return function(ue) {
|
|
6176
6176
|
return function(ae) {
|
|
6177
|
-
return ae.type.match(
|
|
6177
|
+
return ae.type.match(k) && T({ payload: ae, instance: y, plugins: o }), ue(ae);
|
|
6178
6178
|
};
|
|
6179
6179
|
};
|
|
6180
|
-
},
|
|
6180
|
+
}, J = function(ne) {
|
|
6181
6181
|
return function(ue) {
|
|
6182
6182
|
return function(ae) {
|
|
6183
|
-
return ae.type.match(
|
|
6183
|
+
return ae.type.match(k) || T({ payload: ae, instance: y, plugins: o }), ue(ae);
|
|
6184
6184
|
};
|
|
6185
6185
|
};
|
|
6186
6186
|
};
|
|
6187
|
-
return v(H, Kt), v(
|
|
6188
|
-
d(H, Kt), d(
|
|
6187
|
+
return v(H, Kt), v(J, zt), function() {
|
|
6188
|
+
d(H, Kt), d(J, zt);
|
|
6189
6189
|
};
|
|
6190
6190
|
}
|
|
6191
|
-
var
|
|
6191
|
+
var Y = w.match(k) ? Kt : zt, le = function(ne) {
|
|
6192
6192
|
return function(ue) {
|
|
6193
6193
|
return function(ae) {
|
|
6194
6194
|
return ae.type === w && T({ payload: ae, instance: y, plugins: o, abort: p }), ue(ae);
|
|
6195
6195
|
};
|
|
6196
6196
|
};
|
|
6197
6197
|
};
|
|
6198
|
-
return v(le,
|
|
6199
|
-
return d(le,
|
|
6198
|
+
return v(le, Y), function() {
|
|
6199
|
+
return d(le, Y);
|
|
6200
6200
|
};
|
|
6201
6201
|
}, once: function(w, T) {
|
|
6202
6202
|
if (!w || !Be(T)) return !1;
|
|
6203
6203
|
if (w === Z.bootstrap) throw new Error(".once disabled for " + w);
|
|
6204
|
-
var
|
|
6205
|
-
T({ payload: H.payload, instance: y, plugins: o, abort: p }),
|
|
6204
|
+
var k = y.on(w, function(H) {
|
|
6205
|
+
T({ payload: H.payload, instance: y, plugins: o, abort: p }), k();
|
|
6206
6206
|
});
|
|
6207
|
-
return
|
|
6207
|
+
return k;
|
|
6208
6208
|
}, getState: function(w) {
|
|
6209
6209
|
var T = m.getState();
|
|
6210
6210
|
return w ? Kf(T, w) : Object.assign({}, T);
|
|
6211
6211
|
}, dispatch: function(w) {
|
|
6212
6212
|
var T = Tr(w) ? { type: w } : w;
|
|
6213
6213
|
if (Xt.includes(T.type)) throw new Error("reserved action " + T.type);
|
|
6214
|
-
var
|
|
6215
|
-
m.dispatch(
|
|
6216
|
-
}, enablePlugin: g.enable, disablePlugin: g.disable, plugins: g, storage: { getItem: a.getItem, setItem: function(w, T,
|
|
6217
|
-
m.dispatch({ type: Z.setItemStart, key: w, value: T, options:
|
|
6214
|
+
var k = ee({}, T, { _: ee({ originalAction: T.type }, w._ || {}) });
|
|
6215
|
+
m.dispatch(k);
|
|
6216
|
+
}, enablePlugin: g.enable, disablePlugin: g.disable, plugins: g, storage: { getItem: a.getItem, setItem: function(w, T, k) {
|
|
6217
|
+
m.dispatch({ type: Z.setItemStart, key: w, value: T, options: k });
|
|
6218
6218
|
}, removeItem: function(w, T) {
|
|
6219
6219
|
m.dispatch({ type: Z.removeItemStart, key: w, options: T });
|
|
6220
6220
|
} }, setAnonymousId: function(w, T) {
|
|
6221
6221
|
y.storage.setItem(Or, w, T);
|
|
6222
6222
|
}, events: { core: Xt, plugins: s } }, A = n.middlewares.concat([function(w) {
|
|
6223
6223
|
return function(T) {
|
|
6224
|
-
return function(
|
|
6225
|
-
return
|
|
6224
|
+
return function(k) {
|
|
6225
|
+
return k.meta || (k.meta = dd()), T(k);
|
|
6226
6226
|
};
|
|
6227
6227
|
};
|
|
6228
|
-
}, h(Kt), Yg(y, l, { all: c, plugins: s }), Qg(a), Wg(y), Kg(y), h(zt)]),
|
|
6228
|
+
}, h(Kt), Yg(y, l, { all: c, plugins: s }), Qg(a), Wg(y), Kg(y), h(zt)]), $ = { context: uy, user: Vg(a), page: sy, track: ry, plugins: Zg(l), queue: ny }, j = lt, G = lt;
|
|
6229
6229
|
if (_e && e.debug) {
|
|
6230
6230
|
var z = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__;
|
|
6231
6231
|
z && (j = z({ trace: !0, traceLimit: 25 })), G = function() {
|
|
6232
6232
|
return arguments.length === 0 ? yh() : Fe(typeof arguments[0]) ? fd() : fd().apply(null, arguments);
|
|
6233
6233
|
};
|
|
6234
6234
|
}
|
|
6235
|
-
var re,
|
|
6236
|
-
return Object.keys(w).reduce(function(T,
|
|
6237
|
-
return cy.includes(
|
|
6235
|
+
var re, x = (function(w) {
|
|
6236
|
+
return Object.keys(w).reduce(function(T, k) {
|
|
6237
|
+
return cy.includes(k) || (T[k] = w[k]), T;
|
|
6238
6238
|
}, {});
|
|
6239
6239
|
})(e), M = n.pluginsArray.reduce(function(w, T) {
|
|
6240
|
-
var
|
|
6241
|
-
return w[
|
|
6242
|
-
}, {}), N = { context:
|
|
6243
|
-
for (var T = Object.keys(w),
|
|
6244
|
-
var
|
|
6245
|
-
typeof w[
|
|
6240
|
+
var k = T.name, H = T.config, J = T.loaded, Y = n.pluginEnabled[k];
|
|
6241
|
+
return w[k] = { enabled: Y, initialized: !!Y && !T.initialize, loaded: !!J({ config: H }), config: H }, w;
|
|
6242
|
+
}, {}), N = { context: x, user: I, plugins: M }, m = uh((function(w) {
|
|
6243
|
+
for (var T = Object.keys(w), k = {}, H = 0; H < T.length; H++) {
|
|
6244
|
+
var J = T[H];
|
|
6245
|
+
typeof w[J] === Pr && (k[J] = w[J]);
|
|
6246
6246
|
}
|
|
6247
|
-
var
|
|
6247
|
+
var Y, le = Object.keys(k);
|
|
6248
6248
|
try {
|
|
6249
6249
|
(function(ne) {
|
|
6250
6250
|
Object.keys(ne).forEach(function(ue) {
|
|
6251
6251
|
var ae = ne[ue];
|
|
6252
6252
|
if (typeof ae(void 0, { type: Wo }) === hr || typeof ae(void 0, { type: Bg }) === hr) throw new Error(_t + " " + ue + " " + hr);
|
|
6253
6253
|
});
|
|
6254
|
-
})(
|
|
6254
|
+
})(k);
|
|
6255
6255
|
} catch (ne) {
|
|
6256
|
-
|
|
6256
|
+
Y = ne;
|
|
6257
6257
|
}
|
|
6258
6258
|
return function(ne, ue) {
|
|
6259
|
-
if (ne === void 0 && (ne = {}),
|
|
6259
|
+
if (ne === void 0 && (ne = {}), Y) throw Y;
|
|
6260
6260
|
for (var ae = !1, Re = {}, xe = 0; xe < le.length; xe++) {
|
|
6261
|
-
var je = le[xe], $e = ne[je], Qe = (0,
|
|
6261
|
+
var je = le[xe], $e = ne[je], Qe = (0, k[je])($e, ue);
|
|
6262
6262
|
if (typeof Qe === hr) {
|
|
6263
6263
|
var wr = Hg(je, ue);
|
|
6264
6264
|
throw new Error(wr);
|
|
@@ -6267,26 +6267,26 @@ function dy(e) {
|
|
|
6267
6267
|
}
|
|
6268
6268
|
return ae ? Re : ne;
|
|
6269
6269
|
};
|
|
6270
|
-
})(ee({},
|
|
6271
|
-
m.dispatch = (re = m.dispatch, function(w, T,
|
|
6272
|
-
var H = ee({}, w, { meta: dd(w.meta, T, $o(
|
|
6270
|
+
})(ee({}, $, r)), N, G(j(Gg.apply(void 0, A))));
|
|
6271
|
+
m.dispatch = (re = m.dispatch, function(w, T, k) {
|
|
6272
|
+
var H = ee({}, w, { meta: dd(w.meta, T, $o(k)) });
|
|
6273
6273
|
return re.apply(null, [H]);
|
|
6274
6274
|
});
|
|
6275
6275
|
var C = Object.keys(o);
|
|
6276
|
-
m.dispatch({ type: Z.bootstrap, plugins: C, config:
|
|
6277
|
-
var
|
|
6276
|
+
m.dispatch({ type: Z.bootstrap, plugins: C, config: x, params: S, user: I, initialUser: t, persistedUser: R });
|
|
6277
|
+
var L = C.filter(function(w) {
|
|
6278
6278
|
return n.pluginEnabled[w];
|
|
6279
6279
|
}), F = C.filter(function(w) {
|
|
6280
6280
|
return !n.pluginEnabled[w];
|
|
6281
6281
|
});
|
|
6282
6282
|
return m.dispatch({ type: Z.registerPlugins, plugins: C, enabled: n.pluginEnabled }), n.pluginsArray.map(function(w, T) {
|
|
6283
|
-
var
|
|
6284
|
-
|
|
6283
|
+
var k = w.bootstrap, H = w.config, J = w.name;
|
|
6284
|
+
k && Be(k) && k({ instance: y, config: H, payload: w }), m.dispatch({ type: Z.registerPluginType(J), name: J, enabled: n.pluginEnabled[J], plugin: w }), n.pluginsArray.length === T + 1 && m.dispatch({ type: Z.initializeStart, plugins: L, disabled: F });
|
|
6285
6285
|
}), fy(function(w) {
|
|
6286
6286
|
m.dispatch({ type: w ? Z.offline : Z.online });
|
|
6287
|
-
}), (function(w, T,
|
|
6287
|
+
}), (function(w, T, k) {
|
|
6288
6288
|
setInterval(function() {
|
|
6289
|
-
return lh(w, T,
|
|
6289
|
+
return lh(w, T, k);
|
|
6290
6290
|
}, 3e3);
|
|
6291
6291
|
})(m, l, y), y;
|
|
6292
6292
|
}
|
|
@@ -6445,24 +6445,24 @@ function Oy(e) {
|
|
|
6445
6445
|
var d = v.map(function(p) {
|
|
6446
6446
|
return Number(p);
|
|
6447
6447
|
}), h = Fg(function() {
|
|
6448
|
-
var p = md(), S = (function(
|
|
6448
|
+
var p = md(), S = (function(x, M) {
|
|
6449
6449
|
return M.map(function(N) {
|
|
6450
|
-
return N === 100 ?
|
|
6450
|
+
return N === 100 ? x - 5 : x * (N / 100);
|
|
6451
6451
|
});
|
|
6452
6452
|
})(p, d), R = Jo(), I = pd(), g = Yt(I, p), b = Yt(R, p);
|
|
6453
6453
|
if (l = g > l ? g : l, f = b < f ? b : f, !(o.length >= d.length)) {
|
|
6454
6454
|
var y = c === I, A = Uo;
|
|
6455
6455
|
y ? A = "initial" : c <= I && (A = Lo);
|
|
6456
|
-
var
|
|
6457
|
-
(A === Uo || y) && (
|
|
6458
|
-
var G = j.reduce(function(
|
|
6459
|
-
var m =
|
|
6456
|
+
var $ = S, j = d;
|
|
6457
|
+
(A === Uo || y) && ($ = S.slice().reverse(), j = d.slice().reverse());
|
|
6458
|
+
var G = j.reduce(function(x, M, N) {
|
|
6459
|
+
var m = $[N];
|
|
6460
6460
|
return u.includes(M) && I <= m && (u = u.filter(function(C) {
|
|
6461
6461
|
return C !== M;
|
|
6462
|
-
}),
|
|
6462
|
+
}), x.singleFunction = M), A === Lo && !o.includes(M) && I >= m && M > i ? (s.push(M), x.callbacks = x.callbacks.concat(M), x) : A === Uo && !o.includes(M) && I <= m && M <= g ? (x.foundFunc = [M], x) : (y && I >= m && x.foundFunc.length === 0 && (x.foundFunc = [M]), !s.includes(M) && I >= m && (s.push(M), x.singleFunction ? u.push(M) : x.singleFunction = M), x);
|
|
6463
6463
|
}, { foundFunc: [], singleFunction: null, callbacks: [], direction: A });
|
|
6464
|
-
if (c = I, A === Lo && G.callbacks && G.callbacks.forEach(function(
|
|
6465
|
-
Be(e[
|
|
6464
|
+
if (c = I, A === Lo && G.callbacks && G.callbacks.forEach(function(x) {
|
|
6465
|
+
Be(e[x]) && (e[x]({ trigger: x, direction: A, scrollMin: f, scrollMax: l, range: [f, l] }), o.push(x));
|
|
6466
6466
|
}), G.singleFunction) {
|
|
6467
6467
|
var z = G.singleFunction, re = G.direction;
|
|
6468
6468
|
Be(e[z]) && e[z]({ trigger: z, direction: re, scrollMin: f, scrollMax: l, range: [f, l] }), o.push(z);
|
|
@@ -7628,17 +7628,17 @@ function ob(e) {
|
|
|
7628
7628
|
linkSpotify: b,
|
|
7629
7629
|
openHostedAccountPage: y,
|
|
7630
7630
|
paywalls: A,
|
|
7631
|
-
paymentIssues:
|
|
7631
|
+
paymentIssues: $,
|
|
7632
7632
|
products: j,
|
|
7633
7633
|
pushTally: G,
|
|
7634
7634
|
requestDelivery: z,
|
|
7635
7635
|
setTag: re,
|
|
7636
|
-
transactions:
|
|
7636
|
+
transactions: x,
|
|
7637
7637
|
unlinkSpotify: M,
|
|
7638
7638
|
updateProfile: N,
|
|
7639
7639
|
userMetadata: m,
|
|
7640
7640
|
vendor: C
|
|
7641
|
-
} = pg(e),
|
|
7641
|
+
} = pg(e), L = () => $.list(), T = {
|
|
7642
7642
|
analytics: { track: _h },
|
|
7643
7643
|
attribution: { get: tn, set: Mv },
|
|
7644
7644
|
auth: {
|
|
@@ -7667,20 +7667,20 @@ function ob(e) {
|
|
|
7667
7667
|
},
|
|
7668
7668
|
contracts: a,
|
|
7669
7669
|
diagnostics: {
|
|
7670
|
-
send: (
|
|
7670
|
+
send: (k) => ib({
|
|
7671
7671
|
clientId: e.clientId || e.vendorId,
|
|
7672
7672
|
environment: e.environment,
|
|
7673
|
-
fallbackId:
|
|
7673
|
+
fallbackId: k,
|
|
7674
7674
|
getProfile: () => f(),
|
|
7675
7675
|
getEntitlements: () => c(),
|
|
7676
7676
|
getContracts: () => a.list(),
|
|
7677
7677
|
getTags: () => h(),
|
|
7678
7678
|
getTallies: () => S()
|
|
7679
7679
|
}),
|
|
7680
|
-
collect: (
|
|
7680
|
+
collect: (k) => xh({
|
|
7681
7681
|
clientId: e.clientId || e.vendorId,
|
|
7682
7682
|
environment: e.environment,
|
|
7683
|
-
fallbackId:
|
|
7683
|
+
fallbackId: k,
|
|
7684
7684
|
getProfile: () => f(),
|
|
7685
7685
|
getEntitlements: () => c(),
|
|
7686
7686
|
getContracts: () => a.list(),
|
|
@@ -7690,7 +7690,15 @@ function ob(e) {
|
|
|
7690
7690
|
},
|
|
7691
7691
|
entitlements: {
|
|
7692
7692
|
...s,
|
|
7693
|
-
access:
|
|
7693
|
+
access: async (k) => {
|
|
7694
|
+
try {
|
|
7695
|
+
const J = (await c()).find((Y) => Y.id === k || Y.sku === k);
|
|
7696
|
+
if (J?.token && J?.url)
|
|
7697
|
+
return { id: J.id, url: J.url, token: J.token };
|
|
7698
|
+
} catch {
|
|
7699
|
+
}
|
|
7700
|
+
return s.getAccess(k);
|
|
7701
|
+
},
|
|
7694
7702
|
hasAccess: I,
|
|
7695
7703
|
list: c,
|
|
7696
7704
|
signedLinks: Ps
|
|
@@ -7699,12 +7707,12 @@ function ob(e) {
|
|
|
7699
7707
|
flags: { get: Gv, set: Hv, list: Mt, delete: Wv },
|
|
7700
7708
|
fulfillments: { list: l, requestDelivery: z },
|
|
7701
7709
|
generateLink: u,
|
|
7702
|
-
getPaymentIssues:
|
|
7710
|
+
getPaymentIssues: L,
|
|
7703
7711
|
getVersion: sb,
|
|
7704
7712
|
isReady: () => dn,
|
|
7705
7713
|
log: de,
|
|
7706
7714
|
paywalls: A,
|
|
7707
|
-
paymentIssues:
|
|
7715
|
+
paymentIssues: $,
|
|
7708
7716
|
products: { ...j, autoOnboard: r, linkSpotify: b },
|
|
7709
7717
|
profile: {
|
|
7710
7718
|
get: f,
|
|
@@ -7717,7 +7725,7 @@ function ob(e) {
|
|
|
7717
7725
|
subscriptions: { list: d },
|
|
7718
7726
|
tags: { delete: i, list: h, set: re },
|
|
7719
7727
|
tallies: { delete: o, get: p, list: S, push: G },
|
|
7720
|
-
transactions: { ...
|
|
7728
|
+
transactions: { ...x, get: R },
|
|
7721
7729
|
userMetadata: m,
|
|
7722
7730
|
vendor: C,
|
|
7723
7731
|
// Deprecated. This is to handle that the old apps used it on web components
|
|
@@ -8048,7 +8056,7 @@ function _b(e) {
|
|
|
8048
8056
|
function Ab(e, r) {
|
|
8049
8057
|
const t = new Date(e.exp * 1e3);
|
|
8050
8058
|
return {
|
|
8051
|
-
id: "",
|
|
8059
|
+
id: e.s?.toString() || "",
|
|
8052
8060
|
title: e.p?.toString(),
|
|
8053
8061
|
sku: e.s?.toString(),
|
|
8054
8062
|
purchaseOption: e.p?.toString(),
|