@2uinc/frontend-component-xpert-chatbot 1.40.6-beta.11 → 1.40.6-beta.12
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/lib/index.min.js +1068 -1068
- package/package.json +1 -1
package/dist/lib/index.min.js
CHANGED
|
@@ -187,8 +187,8 @@ Qn.exports;
|
|
|
187
187
|
var Au;
|
|
188
188
|
function B0() {
|
|
189
189
|
return Au || (Au = 1, (function(e, t) {
|
|
190
|
-
var n = 200, r = "__lodash_hash_undefined__", a = 800, i = 16, u = 9007199254740991, s = "[object Arguments]", l = "[object Array]", c = "[object AsyncFunction]", d = "[object Boolean]", f = "[object Date]", p = "[object Error]", h = "[object Function]", b = "[object GeneratorFunction]", m = "[object Map]", T = "[object Number]", g = "[object Null]", D = "[object Object]", P = "[object Proxy]",
|
|
191
|
-
v[Y] = v[$] = v[
|
|
190
|
+
var n = 200, r = "__lodash_hash_undefined__", a = 800, i = 16, u = 9007199254740991, s = "[object Arguments]", l = "[object Array]", c = "[object AsyncFunction]", d = "[object Boolean]", f = "[object Date]", p = "[object Error]", h = "[object Function]", b = "[object GeneratorFunction]", m = "[object Map]", T = "[object Number]", g = "[object Null]", D = "[object Object]", P = "[object Proxy]", X = "[object RegExp]", F = "[object Set]", x = "[object String]", w = "[object Undefined]", V = "[object WeakMap]", q = "[object ArrayBuffer]", te = "[object DataView]", Y = "[object Float32Array]", $ = "[object Float64Array]", k = "[object Int8Array]", I = "[object Int16Array]", L = "[object Int32Array]", B = "[object Uint8Array]", W = "[object Uint8ClampedArray]", H = "[object Uint16Array]", z = "[object Uint32Array]", y = /[\\^$.*+?()[\]{}|]/g, ne = /^\[object .+?Constructor\]$/, ae = /^(?:0|[1-9]\d*)$/, v = {};
|
|
191
|
+
v[Y] = v[$] = v[k] = v[I] = v[L] = v[B] = v[W] = v[H] = v[z] = !0, v[s] = v[l] = v[q] = v[d] = v[te] = v[f] = v[p] = v[h] = v[m] = v[T] = v[D] = v[X] = v[F] = v[x] = v[V] = !1;
|
|
192
192
|
var se = typeof Ar == "object" && Ar && Ar.Object === Object && Ar, _e = typeof self == "object" && self && self.Object === Object && self, pe = se || _e || Function("return this")(), Se = t && !t.nodeType && t, Oe = Se && !0 && e && !e.nodeType && e, ze = Oe && Oe.exports === Se, Ie = ze && se.process, nt = (function() {
|
|
193
193
|
try {
|
|
194
194
|
var S = Oe && Oe.require && Oe.require("util").types;
|
|
@@ -230,7 +230,7 @@ function B0() {
|
|
|
230
230
|
var Qt = Array.prototype, Bn = Function.prototype, ue = Object.prototype, be = pe["__core-js_shared__"], Me = Bn.toString, ye = ue.hasOwnProperty, Ye = (function() {
|
|
231
231
|
var S = /[^.]+$/.exec(be && be.keys && be.keys.IE_PROTO || "");
|
|
232
232
|
return S ? "Symbol(src)_1." + S : "";
|
|
233
|
-
})(), Fe = ue.toString, Ce = Me.call(Object),
|
|
233
|
+
})(), Fe = ue.toString, Ce = Me.call(Object), U = RegExp(
|
|
234
234
|
"^" + Me.call(ye).replace(y, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
|
|
235
235
|
), K = ze ? pe.Buffer : void 0, ie = pe.Symbol, Ee = pe.Uint8Array;
|
|
236
236
|
K && K.allocUnsafe;
|
|
@@ -403,7 +403,7 @@ function B0() {
|
|
|
403
403
|
}
|
|
404
404
|
var Kd = l0();
|
|
405
405
|
function yr(S) {
|
|
406
|
-
return S == null ? S === void 0 ?
|
|
406
|
+
return S == null ? S === void 0 ? w : g : Be && Be in Object(S) ? c0(S) : g0(S);
|
|
407
407
|
}
|
|
408
408
|
function cu(S) {
|
|
409
409
|
return Un(S) && yr(S) == s;
|
|
@@ -411,7 +411,7 @@ function B0() {
|
|
|
411
411
|
function Qd(S) {
|
|
412
412
|
if (!Jt(S) || p0(S))
|
|
413
413
|
return !1;
|
|
414
|
-
var N = ha(S) ?
|
|
414
|
+
var N = ha(S) ? U : ne;
|
|
415
415
|
return N.test(y0(S));
|
|
416
416
|
}
|
|
417
417
|
function Zd(S) {
|
|
@@ -1610,14 +1610,14 @@ const Ou = 991, Z0 = () => {
|
|
|
1610
1610
|
externalLoadingHistory: n = !1,
|
|
1611
1611
|
externalStreaming: r = !1
|
|
1612
1612
|
}) => {
|
|
1613
|
-
const [a, i] = le(!1), [u, s] = le(!1), [l, c] = le(!1), [d, f] = le(!0), [p, h] = le(!1), [b, m] = le(!1), [T, g] = le(!1), [D, P] = le(Nt.XPERT),
|
|
1613
|
+
const [a, i] = le(!1), [u, s] = le(!1), [l, c] = le(!1), [d, f] = le(!0), [p, h] = le(!1), [b, m] = le(!1), [T, g] = le(!1), [D, P] = le(Nt.XPERT), X = Z0(), F = {
|
|
1614
1614
|
disabledScroll: a,
|
|
1615
1615
|
externalStreaming: r,
|
|
1616
1616
|
hasError: u,
|
|
1617
1617
|
hasNewMessage: l,
|
|
1618
1618
|
internalStreaming: T,
|
|
1619
|
-
isMobile:
|
|
1620
|
-
isNormalSize: d ||
|
|
1619
|
+
isMobile: X,
|
|
1620
|
+
isNormalSize: d || X,
|
|
1621
1621
|
loading: p || t,
|
|
1622
1622
|
loadingHistory: b || n,
|
|
1623
1623
|
streaming: T || r,
|
|
@@ -1631,7 +1631,7 @@ const Ou = 991, Z0 = () => {
|
|
|
1631
1631
|
setStreaming: g,
|
|
1632
1632
|
setMode: P
|
|
1633
1633
|
};
|
|
1634
|
-
return /* @__PURE__ */ _.jsx(tt.Provider, { value:
|
|
1634
|
+
return /* @__PURE__ */ _.jsx(tt.Provider, { value: F, children: e });
|
|
1635
1635
|
};
|
|
1636
1636
|
Ms.propTypes = {
|
|
1637
1637
|
children: A.element.isRequired,
|
|
@@ -1689,7 +1689,7 @@ const $t = Xr({}), ve = {
|
|
|
1689
1689
|
onFeedbackSelection: n,
|
|
1690
1690
|
onMessageSent: r,
|
|
1691
1691
|
onStreamingStop: a,
|
|
1692
|
-
pushXpertMessage: (
|
|
1692
|
+
pushXpertMessage: (X) => m((F) => [...F, X]),
|
|
1693
1693
|
setConversationId: f,
|
|
1694
1694
|
setDeleteConversationModal: h,
|
|
1695
1695
|
setXpertMessages: m,
|
|
@@ -1809,8 +1809,8 @@ eyes follow your mouse when you hover near it.`, js = ({
|
|
|
1809
1809
|
i.current.querySelectorAll(
|
|
1810
1810
|
".xpert_chatbot__animated_graduate__pupil"
|
|
1811
1811
|
).forEach((g) => {
|
|
1812
|
-
const D = g.getBoundingClientRect(), P = (b.pageX - window.scrollX - D.left) / 30 / 16 + "rem",
|
|
1813
|
-
g.style.transform = "translate3d(" + P + "," +
|
|
1812
|
+
const D = g.getBoundingClientRect(), P = (b.pageX - window.scrollX - D.left) / 30 / 16 + "rem", X = (b.pageY - window.scrollY - D.top) / 30 / 16 + "rem";
|
|
1813
|
+
g.style.transform = "translate3d(" + P + "," + X + ", 0rem)";
|
|
1814
1814
|
});
|
|
1815
1815
|
};
|
|
1816
1816
|
return window.addEventListener("mousemove", h), () => {
|
|
@@ -2374,70 +2374,70 @@ var wu = {
|
|
|
2374
2374
|
delayInitialFocusTimer: void 0,
|
|
2375
2375
|
// the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any
|
|
2376
2376
|
recentNavEvent: void 0
|
|
2377
|
-
}, s, l = function(
|
|
2378
|
-
return
|
|
2379
|
-
}, c = function(
|
|
2380
|
-
var
|
|
2381
|
-
return u.containerGroups.findIndex(function(
|
|
2382
|
-
var
|
|
2383
|
-
return
|
|
2384
|
-
return z ===
|
|
2377
|
+
}, s, l = function(k, I, L) {
|
|
2378
|
+
return k && k[I] !== void 0 ? k[I] : i[L || I];
|
|
2379
|
+
}, c = function(k, I) {
|
|
2380
|
+
var L = typeof I?.composedPath == "function" ? I.composedPath() : void 0;
|
|
2381
|
+
return u.containerGroups.findIndex(function(B) {
|
|
2382
|
+
var W = B.container, H = B.tabbableNodes;
|
|
2383
|
+
return W.contains(k) || L?.includes(W) || H.find(function(z) {
|
|
2384
|
+
return z === k;
|
|
2385
2385
|
});
|
|
2386
2386
|
});
|
|
2387
|
-
}, d = function(
|
|
2388
|
-
var I = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {},
|
|
2389
|
-
if (typeof z == "function" && (z = z.apply(void 0, vf(
|
|
2387
|
+
}, d = function(k) {
|
|
2388
|
+
var I = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, L = I.hasFallback, B = L === void 0 ? !1 : L, W = I.params, H = W === void 0 ? [] : W, z = i[k];
|
|
2389
|
+
if (typeof z == "function" && (z = z.apply(void 0, vf(H))), z === !0 && (z = void 0), !z) {
|
|
2390
2390
|
if (z === void 0 || z === !1)
|
|
2391
2391
|
return z;
|
|
2392
|
-
throw new Error("`".concat(
|
|
2392
|
+
throw new Error("`".concat(k, "` was specified but was not a node, or did not return a node"));
|
|
2393
2393
|
}
|
|
2394
2394
|
var y = z;
|
|
2395
2395
|
if (typeof z == "string") {
|
|
2396
2396
|
try {
|
|
2397
2397
|
y = r.querySelector(z);
|
|
2398
2398
|
} catch (ne) {
|
|
2399
|
-
throw new Error("`".concat(
|
|
2399
|
+
throw new Error("`".concat(k, '` appears to be an invalid selector; error="').concat(ne.message, '"'));
|
|
2400
2400
|
}
|
|
2401
|
-
if (!y && !
|
|
2402
|
-
throw new Error("`".concat(
|
|
2401
|
+
if (!y && !B)
|
|
2402
|
+
throw new Error("`".concat(k, "` as selector refers to no known node"));
|
|
2403
2403
|
}
|
|
2404
2404
|
return y;
|
|
2405
2405
|
}, f = function() {
|
|
2406
|
-
var
|
|
2406
|
+
var k = d("initialFocus", {
|
|
2407
2407
|
hasFallback: !0
|
|
2408
2408
|
});
|
|
2409
|
-
if (
|
|
2409
|
+
if (k === !1)
|
|
2410
2410
|
return !1;
|
|
2411
|
-
if (
|
|
2411
|
+
if (k === void 0 || k && !wr(k, i.tabbableOptions))
|
|
2412
2412
|
if (c(r.activeElement) >= 0)
|
|
2413
|
-
|
|
2413
|
+
k = r.activeElement;
|
|
2414
2414
|
else {
|
|
2415
|
-
var I = u.tabbableGroups[0],
|
|
2416
|
-
|
|
2415
|
+
var I = u.tabbableGroups[0], L = I && I.firstTabbableNode;
|
|
2416
|
+
k = L || d("fallbackFocus");
|
|
2417
2417
|
}
|
|
2418
|
-
else
|
|
2419
|
-
if (!
|
|
2418
|
+
else k === null && (k = d("fallbackFocus"));
|
|
2419
|
+
if (!k)
|
|
2420
2420
|
throw new Error("Your focus-trap needs to have at least one focusable element");
|
|
2421
|
-
return
|
|
2421
|
+
return k;
|
|
2422
2422
|
}, p = function() {
|
|
2423
|
-
if (u.containerGroups = u.containers.map(function(
|
|
2424
|
-
var I = Ks(
|
|
2423
|
+
if (u.containerGroups = u.containers.map(function(k) {
|
|
2424
|
+
var I = Ks(k, i.tabbableOptions), L = Qs(k, i.tabbableOptions), B = I.length > 0 ? I[0] : void 0, W = I.length > 0 ? I[I.length - 1] : void 0, H = L.find(function(ne) {
|
|
2425
2425
|
return rn(ne);
|
|
2426
|
-
}), z =
|
|
2426
|
+
}), z = L.slice().reverse().find(function(ne) {
|
|
2427
2427
|
return rn(ne);
|
|
2428
2428
|
}), y = !!I.find(function(ne) {
|
|
2429
2429
|
return Xt(ne) > 0;
|
|
2430
2430
|
});
|
|
2431
2431
|
return {
|
|
2432
|
-
container:
|
|
2432
|
+
container: k,
|
|
2433
2433
|
tabbableNodes: I,
|
|
2434
|
-
focusableNodes:
|
|
2434
|
+
focusableNodes: L,
|
|
2435
2435
|
/** True if at least one node with positive `tabindex` was found in this container. */
|
|
2436
2436
|
posTabIndexesFound: y,
|
|
2437
2437
|
/** First tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
2438
|
-
firstTabbableNode:
|
|
2438
|
+
firstTabbableNode: B,
|
|
2439
2439
|
/** Last tabbable node in container, __tabindex__ order; `undefined` if none. */
|
|
2440
|
-
lastTabbableNode:
|
|
2440
|
+
lastTabbableNode: W,
|
|
2441
2441
|
// NOTE: DOM order is NOT NECESSARILY "document position" order, but figuring that out
|
|
2442
2442
|
// would require more than just https://developer.mozilla.org/en-US/docs/Web/API/Node/compareDocumentPosition
|
|
2443
2443
|
// because that API doesn't work with Shadow DOM as well as it should (@see
|
|
@@ -2446,7 +2446,7 @@ var wu = {
|
|
|
2446
2446
|
// "close enough most of the time" alternative for positive tabindexes which should generally
|
|
2447
2447
|
// be avoided anyway...
|
|
2448
2448
|
/** First tabbable node in container, __DOM__ order; `undefined` if none. */
|
|
2449
|
-
firstDomTabbableNode:
|
|
2449
|
+
firstDomTabbableNode: H,
|
|
2450
2450
|
/** Last tabbable node in container, __DOM__ order; `undefined` if none. */
|
|
2451
2451
|
lastDomTabbableNode: z,
|
|
2452
2452
|
/**
|
|
@@ -2459,57 +2459,57 @@ var wu = {
|
|
|
2459
2459
|
*/
|
|
2460
2460
|
nextTabbableNode: function(ae) {
|
|
2461
2461
|
var v = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, se = I.indexOf(ae);
|
|
2462
|
-
return se < 0 ? v ?
|
|
2462
|
+
return se < 0 ? v ? L.slice(L.indexOf(ae) + 1).find(function(_e) {
|
|
2463
2463
|
return rn(_e);
|
|
2464
|
-
}) :
|
|
2464
|
+
}) : L.slice(0, L.indexOf(ae)).reverse().find(function(_e) {
|
|
2465
2465
|
return rn(_e);
|
|
2466
2466
|
}) : I[se + (v ? 1 : -1)];
|
|
2467
2467
|
}
|
|
2468
2468
|
};
|
|
2469
|
-
}), u.tabbableGroups = u.containerGroups.filter(function(
|
|
2470
|
-
return
|
|
2469
|
+
}), u.tabbableGroups = u.containerGroups.filter(function(k) {
|
|
2470
|
+
return k.tabbableNodes.length > 0;
|
|
2471
2471
|
}), u.tabbableGroups.length <= 0 && !d("fallbackFocus"))
|
|
2472
2472
|
throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");
|
|
2473
|
-
if (u.containerGroups.find(function(
|
|
2474
|
-
return
|
|
2473
|
+
if (u.containerGroups.find(function(k) {
|
|
2474
|
+
return k.posTabIndexesFound;
|
|
2475
2475
|
}) && u.containerGroups.length > 1)
|
|
2476
2476
|
throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.");
|
|
2477
|
-
}, h = function(
|
|
2478
|
-
var I =
|
|
2477
|
+
}, h = function(k) {
|
|
2478
|
+
var I = k.activeElement;
|
|
2479
2479
|
if (I)
|
|
2480
2480
|
return I.shadowRoot && I.shadowRoot.activeElement !== null ? h(I.shadowRoot) : I;
|
|
2481
|
-
}, b = function(
|
|
2482
|
-
if (
|
|
2483
|
-
if (!
|
|
2481
|
+
}, b = function(k) {
|
|
2482
|
+
if (k !== !1 && k !== h(document)) {
|
|
2483
|
+
if (!k || !k.focus) {
|
|
2484
2484
|
b(f());
|
|
2485
2485
|
return;
|
|
2486
2486
|
}
|
|
2487
|
-
|
|
2487
|
+
k.focus({
|
|
2488
2488
|
preventScroll: !!i.preventScroll
|
|
2489
|
-
}), u.mostRecentlyFocusedNode =
|
|
2489
|
+
}), u.mostRecentlyFocusedNode = k, kf(k) && k.select();
|
|
2490
2490
|
}
|
|
2491
|
-
}, m = function(
|
|
2491
|
+
}, m = function(k) {
|
|
2492
2492
|
var I = d("setReturnFocus", {
|
|
2493
|
-
params: [
|
|
2493
|
+
params: [k]
|
|
2494
2494
|
});
|
|
2495
|
-
return I || (I === !1 ? !1 :
|
|
2496
|
-
}, T = function(
|
|
2497
|
-
var I =
|
|
2498
|
-
I = I || xr(
|
|
2499
|
-
var
|
|
2495
|
+
return I || (I === !1 ? !1 : k);
|
|
2496
|
+
}, T = function(k) {
|
|
2497
|
+
var I = k.target, L = k.event, B = k.isBackward, W = B === void 0 ? !1 : B;
|
|
2498
|
+
I = I || xr(L), p();
|
|
2499
|
+
var H = null;
|
|
2500
2500
|
if (u.tabbableGroups.length > 0) {
|
|
2501
|
-
var z = c(I,
|
|
2501
|
+
var z = c(I, L), y = z >= 0 ? u.containerGroups[z] : void 0;
|
|
2502
2502
|
if (z < 0)
|
|
2503
|
-
|
|
2504
|
-
else if (
|
|
2503
|
+
W ? H = u.tabbableGroups[u.tabbableGroups.length - 1].lastTabbableNode : H = u.tabbableGroups[0].firstTabbableNode;
|
|
2504
|
+
else if (W) {
|
|
2505
2505
|
var ne = u.tabbableGroups.findIndex(function(Se) {
|
|
2506
2506
|
var Oe = Se.firstTabbableNode;
|
|
2507
2507
|
return I === Oe;
|
|
2508
2508
|
});
|
|
2509
2509
|
if (ne < 0 && (y.container === I || wr(I, i.tabbableOptions) && !rn(I, i.tabbableOptions) && !y.nextTabbableNode(I, !1)) && (ne = z), ne >= 0) {
|
|
2510
2510
|
var ae = ne === 0 ? u.tabbableGroups.length - 1 : ne - 1, v = u.tabbableGroups[ae];
|
|
2511
|
-
|
|
2512
|
-
} else Jn(
|
|
2511
|
+
H = Xt(I) >= 0 ? v.lastTabbableNode : v.lastDomTabbableNode;
|
|
2512
|
+
} else Jn(L) || (H = y.nextTabbableNode(I, !1));
|
|
2513
2513
|
} else {
|
|
2514
2514
|
var se = u.tabbableGroups.findIndex(function(Se) {
|
|
2515
2515
|
var Oe = Se.lastTabbableNode;
|
|
@@ -2517,16 +2517,16 @@ var wu = {
|
|
|
2517
2517
|
});
|
|
2518
2518
|
if (se < 0 && (y.container === I || wr(I, i.tabbableOptions) && !rn(I, i.tabbableOptions) && !y.nextTabbableNode(I)) && (se = z), se >= 0) {
|
|
2519
2519
|
var _e = se === u.tabbableGroups.length - 1 ? 0 : se + 1, pe = u.tabbableGroups[_e];
|
|
2520
|
-
|
|
2521
|
-
} else Jn(
|
|
2520
|
+
H = Xt(I) >= 0 ? pe.firstTabbableNode : pe.firstDomTabbableNode;
|
|
2521
|
+
} else Jn(L) || (H = y.nextTabbableNode(I));
|
|
2522
2522
|
}
|
|
2523
2523
|
} else
|
|
2524
|
-
|
|
2525
|
-
return
|
|
2526
|
-
}, g = function(
|
|
2527
|
-
var I = xr(
|
|
2528
|
-
if (!(c(I,
|
|
2529
|
-
if (qn(i.clickOutsideDeactivates,
|
|
2524
|
+
H = d("fallbackFocus");
|
|
2525
|
+
return H;
|
|
2526
|
+
}, g = function(k) {
|
|
2527
|
+
var I = xr(k);
|
|
2528
|
+
if (!(c(I, k) >= 0)) {
|
|
2529
|
+
if (qn(i.clickOutsideDeactivates, k)) {
|
|
2530
2530
|
s.deactivate({
|
|
2531
2531
|
// NOTE: by setting `returnFocus: false`, deactivate() will do nothing,
|
|
2532
2532
|
// which will result in the outside click setting focus to the node
|
|
@@ -2538,56 +2538,56 @@ var wu = {
|
|
|
2538
2538
|
});
|
|
2539
2539
|
return;
|
|
2540
2540
|
}
|
|
2541
|
-
qn(i.allowOutsideClick,
|
|
2541
|
+
qn(i.allowOutsideClick, k) || k.preventDefault();
|
|
2542
2542
|
}
|
|
2543
|
-
}, D = function(
|
|
2544
|
-
var I = xr(
|
|
2545
|
-
if (
|
|
2546
|
-
|
|
2543
|
+
}, D = function(k) {
|
|
2544
|
+
var I = xr(k), L = c(I, k) >= 0;
|
|
2545
|
+
if (L || I instanceof Document)
|
|
2546
|
+
L && (u.mostRecentlyFocusedNode = I);
|
|
2547
2547
|
else {
|
|
2548
|
-
|
|
2549
|
-
var
|
|
2548
|
+
k.stopImmediatePropagation();
|
|
2549
|
+
var B, W = !0;
|
|
2550
2550
|
if (u.mostRecentlyFocusedNode)
|
|
2551
2551
|
if (Xt(u.mostRecentlyFocusedNode) > 0) {
|
|
2552
|
-
var
|
|
2552
|
+
var H = c(u.mostRecentlyFocusedNode), z = u.containerGroups[H].tabbableNodes;
|
|
2553
2553
|
if (z.length > 0) {
|
|
2554
2554
|
var y = z.findIndex(function(ne) {
|
|
2555
2555
|
return ne === u.mostRecentlyFocusedNode;
|
|
2556
2556
|
});
|
|
2557
|
-
y >= 0 && (i.isKeyForward(u.recentNavEvent) ? y + 1 < z.length && (
|
|
2557
|
+
y >= 0 && (i.isKeyForward(u.recentNavEvent) ? y + 1 < z.length && (B = z[y + 1], W = !1) : y - 1 >= 0 && (B = z[y - 1], W = !1));
|
|
2558
2558
|
}
|
|
2559
2559
|
} else
|
|
2560
2560
|
u.containerGroups.some(function(ne) {
|
|
2561
2561
|
return ne.tabbableNodes.some(function(ae) {
|
|
2562
2562
|
return Xt(ae) > 0;
|
|
2563
2563
|
});
|
|
2564
|
-
}) || (
|
|
2564
|
+
}) || (W = !1);
|
|
2565
2565
|
else
|
|
2566
|
-
|
|
2567
|
-
|
|
2566
|
+
W = !1;
|
|
2567
|
+
W && (B = T({
|
|
2568
2568
|
// move FROM the MRU node, not event-related node (which will be the node that is
|
|
2569
2569
|
// outside the trap causing the focus escape we're trying to fix)
|
|
2570
2570
|
target: u.mostRecentlyFocusedNode,
|
|
2571
2571
|
isBackward: i.isKeyBackward(u.recentNavEvent)
|
|
2572
|
-
})), b(
|
|
2572
|
+
})), b(B || u.mostRecentlyFocusedNode || f());
|
|
2573
2573
|
}
|
|
2574
2574
|
u.recentNavEvent = void 0;
|
|
2575
|
-
}, P = function(
|
|
2575
|
+
}, P = function(k) {
|
|
2576
2576
|
var I = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1;
|
|
2577
|
-
u.recentNavEvent =
|
|
2578
|
-
var
|
|
2579
|
-
event:
|
|
2577
|
+
u.recentNavEvent = k;
|
|
2578
|
+
var L = T({
|
|
2579
|
+
event: k,
|
|
2580
2580
|
isBackward: I
|
|
2581
2581
|
});
|
|
2582
|
-
|
|
2583
|
-
},
|
|
2584
|
-
(i.isKeyForward(
|
|
2585
|
-
},
|
|
2586
|
-
Lf(
|
|
2587
|
-
}, x = function(
|
|
2588
|
-
var I = xr(
|
|
2589
|
-
c(I,
|
|
2590
|
-
},
|
|
2582
|
+
L && (Jn(k) && k.preventDefault(), b(L));
|
|
2583
|
+
}, X = function(k) {
|
|
2584
|
+
(i.isKeyForward(k) || i.isKeyBackward(k)) && P(k, i.isKeyBackward(k));
|
|
2585
|
+
}, F = function(k) {
|
|
2586
|
+
Lf(k) && qn(i.escapeDeactivates, k) !== !1 && (k.preventDefault(), s.deactivate());
|
|
2587
|
+
}, x = function(k) {
|
|
2588
|
+
var I = xr(k);
|
|
2589
|
+
c(I, k) >= 0 || qn(i.clickOutsideDeactivates, k) || qn(i.allowOutsideClick, k) || (k.preventDefault(), k.stopImmediatePropagation());
|
|
2590
|
+
}, w = function() {
|
|
2591
2591
|
if (u.active)
|
|
2592
2592
|
return wu.activateTrap(a, s), u.delayInitialFocusTimer = i.delayInitialFocus ? Ru(function() {
|
|
2593
2593
|
b(f());
|
|
@@ -2600,24 +2600,24 @@ var wu = {
|
|
|
2600
2600
|
}), r.addEventListener("click", x, {
|
|
2601
2601
|
capture: !0,
|
|
2602
2602
|
passive: !1
|
|
2603
|
-
}), r.addEventListener("keydown",
|
|
2603
|
+
}), r.addEventListener("keydown", X, {
|
|
2604
2604
|
capture: !0,
|
|
2605
2605
|
passive: !1
|
|
2606
|
-
}), r.addEventListener("keydown",
|
|
2607
|
-
},
|
|
2606
|
+
}), r.addEventListener("keydown", F), s;
|
|
2607
|
+
}, V = function() {
|
|
2608
2608
|
if (u.active)
|
|
2609
|
-
return r.removeEventListener("focusin", D, !0), r.removeEventListener("mousedown", g, !0), r.removeEventListener("touchstart", g, !0), r.removeEventListener("click", x, !0), r.removeEventListener("keydown",
|
|
2610
|
-
}, q = function(
|
|
2611
|
-
var I =
|
|
2612
|
-
var
|
|
2613
|
-
return
|
|
2614
|
-
return
|
|
2609
|
+
return r.removeEventListener("focusin", D, !0), r.removeEventListener("mousedown", g, !0), r.removeEventListener("touchstart", g, !0), r.removeEventListener("click", x, !0), r.removeEventListener("keydown", X, !0), r.removeEventListener("keydown", F), s;
|
|
2610
|
+
}, q = function(k) {
|
|
2611
|
+
var I = k.some(function(L) {
|
|
2612
|
+
var B = Array.from(L.removedNodes);
|
|
2613
|
+
return B.some(function(W) {
|
|
2614
|
+
return W === u.mostRecentlyFocusedNode;
|
|
2615
2615
|
});
|
|
2616
2616
|
});
|
|
2617
2617
|
I && b(f());
|
|
2618
2618
|
}, te = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(q) : void 0, Y = function() {
|
|
2619
|
-
te && (te.disconnect(), u.active && !u.paused && u.containers.map(function(
|
|
2620
|
-
te.observe(
|
|
2619
|
+
te && (te.disconnect(), u.active && !u.paused && u.containers.map(function(k) {
|
|
2620
|
+
te.observe(k, {
|
|
2621
2621
|
subtree: !0,
|
|
2622
2622
|
childList: !0
|
|
2623
2623
|
});
|
|
@@ -2630,44 +2630,44 @@ var wu = {
|
|
|
2630
2630
|
get paused() {
|
|
2631
2631
|
return u.paused;
|
|
2632
2632
|
},
|
|
2633
|
-
activate: function(
|
|
2633
|
+
activate: function(k) {
|
|
2634
2634
|
if (u.active)
|
|
2635
2635
|
return this;
|
|
2636
|
-
var I = l(
|
|
2637
|
-
|
|
2638
|
-
var
|
|
2639
|
-
|
|
2636
|
+
var I = l(k, "onActivate"), L = l(k, "onPostActivate"), B = l(k, "checkCanFocusTrap");
|
|
2637
|
+
B || p(), u.active = !0, u.paused = !1, u.nodeFocusedBeforeActivation = h(r), I?.();
|
|
2638
|
+
var W = function() {
|
|
2639
|
+
B && p(), w(), Y(), L?.();
|
|
2640
2640
|
};
|
|
2641
|
-
return
|
|
2641
|
+
return B ? (B(u.containers.concat()).then(W, W), this) : (W(), this);
|
|
2642
2642
|
},
|
|
2643
|
-
deactivate: function(
|
|
2643
|
+
deactivate: function(k) {
|
|
2644
2644
|
if (!u.active)
|
|
2645
2645
|
return this;
|
|
2646
2646
|
var I = Lu({
|
|
2647
2647
|
onDeactivate: i.onDeactivate,
|
|
2648
2648
|
onPostDeactivate: i.onPostDeactivate,
|
|
2649
2649
|
checkCanReturnFocus: i.checkCanReturnFocus
|
|
2650
|
-
},
|
|
2651
|
-
clearTimeout(u.delayInitialFocusTimer), u.delayInitialFocusTimer = void 0,
|
|
2652
|
-
var
|
|
2653
|
-
|
|
2650
|
+
}, k);
|
|
2651
|
+
clearTimeout(u.delayInitialFocusTimer), u.delayInitialFocusTimer = void 0, V(), u.active = !1, u.paused = !1, Y(), wu.deactivateTrap(a, s);
|
|
2652
|
+
var L = l(I, "onDeactivate"), B = l(I, "onPostDeactivate"), W = l(I, "checkCanReturnFocus"), H = l(I, "returnFocus", "returnFocusOnDeactivate");
|
|
2653
|
+
L?.();
|
|
2654
2654
|
var z = function() {
|
|
2655
2655
|
Ru(function() {
|
|
2656
|
-
|
|
2656
|
+
H && b(m(u.nodeFocusedBeforeActivation)), B?.();
|
|
2657
2657
|
});
|
|
2658
2658
|
};
|
|
2659
|
-
return
|
|
2659
|
+
return H && W ? (W(m(u.nodeFocusedBeforeActivation)).then(z, z), this) : (z(), this);
|
|
2660
2660
|
},
|
|
2661
|
-
pause: function(
|
|
2662
|
-
return u.active ? (u.manuallyPaused = !0, this._setPausedState(!0,
|
|
2661
|
+
pause: function(k) {
|
|
2662
|
+
return u.active ? (u.manuallyPaused = !0, this._setPausedState(!0, k)) : this;
|
|
2663
2663
|
},
|
|
2664
|
-
unpause: function(
|
|
2665
|
-
return u.active ? (u.manuallyPaused = !1, a[a.length - 1] !== this ? this : this._setPausedState(!1,
|
|
2664
|
+
unpause: function(k) {
|
|
2665
|
+
return u.active ? (u.manuallyPaused = !1, a[a.length - 1] !== this ? this : this._setPausedState(!1, k)) : this;
|
|
2666
2666
|
},
|
|
2667
|
-
updateContainerElements: function(
|
|
2668
|
-
var I = [].concat(
|
|
2669
|
-
return u.containers = I.map(function(
|
|
2670
|
-
return typeof
|
|
2667
|
+
updateContainerElements: function(k) {
|
|
2668
|
+
var I = [].concat(k).filter(Boolean);
|
|
2669
|
+
return u.containers = I.map(function(L) {
|
|
2670
|
+
return typeof L == "string" ? r.querySelector(L) : L;
|
|
2671
2671
|
}), u.active && p(), Y(), this;
|
|
2672
2672
|
}
|
|
2673
2673
|
}, Object.defineProperties(s, {
|
|
@@ -2677,15 +2677,15 @@ var wu = {
|
|
|
2677
2677
|
}
|
|
2678
2678
|
},
|
|
2679
2679
|
_setPausedState: {
|
|
2680
|
-
value: function(
|
|
2681
|
-
if (u.paused ===
|
|
2680
|
+
value: function(k, I) {
|
|
2681
|
+
if (u.paused === k)
|
|
2682
2682
|
return this;
|
|
2683
|
-
if (u.paused =
|
|
2684
|
-
var
|
|
2685
|
-
|
|
2683
|
+
if (u.paused = k, k) {
|
|
2684
|
+
var L = l(I, "onPause"), B = l(I, "onPostPause");
|
|
2685
|
+
L?.(), V(), Y(), B?.();
|
|
2686
2686
|
} else {
|
|
2687
|
-
var
|
|
2688
|
-
|
|
2687
|
+
var W = l(I, "onUnpause"), H = l(I, "onPostUnpause");
|
|
2688
|
+
W?.(), p(), w(), Y(), H?.();
|
|
2689
2689
|
}
|
|
2690
2690
|
return this;
|
|
2691
2691
|
}
|
|
@@ -2702,30 +2702,30 @@ function Hf() {
|
|
|
2702
2702
|
Du = 1;
|
|
2703
2703
|
function e(x) {
|
|
2704
2704
|
"@babel/helpers - typeof";
|
|
2705
|
-
return e = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(
|
|
2706
|
-
return typeof
|
|
2707
|
-
} : function(
|
|
2708
|
-
return
|
|
2705
|
+
return e = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(w) {
|
|
2706
|
+
return typeof w;
|
|
2707
|
+
} : function(w) {
|
|
2708
|
+
return w && typeof Symbol == "function" && w.constructor === Symbol && w !== Symbol.prototype ? "symbol" : typeof w;
|
|
2709
2709
|
}, e(x);
|
|
2710
2710
|
}
|
|
2711
|
-
function t(x,
|
|
2712
|
-
if (!(x instanceof
|
|
2711
|
+
function t(x, w) {
|
|
2712
|
+
if (!(x instanceof w)) throw new TypeError("Cannot call a class as a function");
|
|
2713
2713
|
}
|
|
2714
|
-
function n(x,
|
|
2715
|
-
for (var
|
|
2716
|
-
var q =
|
|
2714
|
+
function n(x, w) {
|
|
2715
|
+
for (var V = 0; V < w.length; V++) {
|
|
2716
|
+
var q = w[V];
|
|
2717
2717
|
q.enumerable = q.enumerable || !1, q.configurable = !0, "value" in q && (q.writable = !0), Object.defineProperty(x, p(q.key), q);
|
|
2718
2718
|
}
|
|
2719
2719
|
}
|
|
2720
|
-
function r(x,
|
|
2721
|
-
return
|
|
2720
|
+
function r(x, w, V) {
|
|
2721
|
+
return w && n(x.prototype, w), Object.defineProperty(x, "prototype", { writable: !1 }), x;
|
|
2722
2722
|
}
|
|
2723
|
-
function a(x,
|
|
2724
|
-
return
|
|
2723
|
+
function a(x, w, V) {
|
|
2724
|
+
return w = l(w), i(x, s() ? Reflect.construct(w, V || [], l(x).constructor) : w.apply(x, V));
|
|
2725
2725
|
}
|
|
2726
|
-
function i(x,
|
|
2727
|
-
if (
|
|
2728
|
-
if (
|
|
2726
|
+
function i(x, w) {
|
|
2727
|
+
if (w && (e(w) == "object" || typeof w == "function")) return w;
|
|
2728
|
+
if (w !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
|
|
2729
2729
|
return u(x);
|
|
2730
2730
|
}
|
|
2731
2731
|
function u(x) {
|
|
@@ -2743,58 +2743,58 @@ function Hf() {
|
|
|
2743
2743
|
})();
|
|
2744
2744
|
}
|
|
2745
2745
|
function l(x) {
|
|
2746
|
-
return l = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(
|
|
2747
|
-
return
|
|
2746
|
+
return l = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(w) {
|
|
2747
|
+
return w.__proto__ || Object.getPrototypeOf(w);
|
|
2748
2748
|
}, l(x);
|
|
2749
2749
|
}
|
|
2750
|
-
function c(x,
|
|
2751
|
-
if (typeof
|
|
2752
|
-
x.prototype = Object.create(
|
|
2750
|
+
function c(x, w) {
|
|
2751
|
+
if (typeof w != "function" && w !== null) throw new TypeError("Super expression must either be null or a function");
|
|
2752
|
+
x.prototype = Object.create(w && w.prototype, { constructor: { value: x, writable: !0, configurable: !0 } }), Object.defineProperty(x, "prototype", { writable: !1 }), w && d(x, w);
|
|
2753
2753
|
}
|
|
2754
|
-
function d(x,
|
|
2755
|
-
return d = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(
|
|
2756
|
-
return
|
|
2757
|
-
}, d(x,
|
|
2754
|
+
function d(x, w) {
|
|
2755
|
+
return d = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(V, q) {
|
|
2756
|
+
return V.__proto__ = q, V;
|
|
2757
|
+
}, d(x, w);
|
|
2758
2758
|
}
|
|
2759
|
-
function f(x,
|
|
2760
|
-
return (
|
|
2759
|
+
function f(x, w, V) {
|
|
2760
|
+
return (w = p(w)) in x ? Object.defineProperty(x, w, { value: V, enumerable: !0, configurable: !0, writable: !0 }) : x[w] = V, x;
|
|
2761
2761
|
}
|
|
2762
2762
|
function p(x) {
|
|
2763
|
-
var
|
|
2764
|
-
return e(
|
|
2763
|
+
var w = h(x, "string");
|
|
2764
|
+
return e(w) == "symbol" ? w : w + "";
|
|
2765
2765
|
}
|
|
2766
|
-
function h(x,
|
|
2766
|
+
function h(x, w) {
|
|
2767
2767
|
if (e(x) != "object" || !x) return x;
|
|
2768
|
-
var
|
|
2769
|
-
if (
|
|
2770
|
-
var q =
|
|
2768
|
+
var V = x[Symbol.toPrimitive];
|
|
2769
|
+
if (V !== void 0) {
|
|
2770
|
+
var q = V.call(x, w);
|
|
2771
2771
|
if (e(q) != "object") return q;
|
|
2772
2772
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
2773
2773
|
}
|
|
2774
|
-
return (
|
|
2774
|
+
return (w === "string" ? String : Number)(x);
|
|
2775
2775
|
}
|
|
2776
|
-
var b = Ct, m = /* @__PURE__ */ Ds(), T = Ff, g = T.createFocusTrap, D = Bf, P = D.isFocusable,
|
|
2777
|
-
function
|
|
2776
|
+
var b = Ct, m = /* @__PURE__ */ Ds(), T = Ff, g = T.createFocusTrap, D = Bf, P = D.isFocusable, X = /* @__PURE__ */ (function(x) {
|
|
2777
|
+
function w(V) {
|
|
2778
2778
|
var q;
|
|
2779
|
-
t(this,
|
|
2780
|
-
var
|
|
2779
|
+
t(this, w), q = a(this, w, [V]), f(q, "getNodeForOption", function($) {
|
|
2780
|
+
var k, I = (k = this.internalOptions[$]) !== null && k !== void 0 ? k : this.originalOptions[$];
|
|
2781
2781
|
if (typeof I == "function") {
|
|
2782
|
-
for (var
|
|
2783
|
-
|
|
2784
|
-
I = I.apply(void 0,
|
|
2782
|
+
for (var L = arguments.length, B = new Array(L > 1 ? L - 1 : 0), W = 1; W < L; W++)
|
|
2783
|
+
B[W - 1] = arguments[W];
|
|
2784
|
+
I = I.apply(void 0, B);
|
|
2785
2785
|
}
|
|
2786
2786
|
if (I === !0 && (I = void 0), !I) {
|
|
2787
2787
|
if (I === void 0 || I === !1)
|
|
2788
2788
|
return I;
|
|
2789
2789
|
throw new Error("`".concat($, "` was specified but was not a node, or did not return a node"));
|
|
2790
2790
|
}
|
|
2791
|
-
var
|
|
2791
|
+
var H = I;
|
|
2792
2792
|
if (typeof I == "string") {
|
|
2793
2793
|
var z;
|
|
2794
|
-
if (
|
|
2794
|
+
if (H = (z = this.getDocument()) === null || z === void 0 ? void 0 : z.querySelector(I), !H)
|
|
2795
2795
|
throw new Error("`".concat($, "` as selector refers to no known node"));
|
|
2796
2796
|
}
|
|
2797
|
-
return
|
|
2797
|
+
return H;
|
|
2798
2798
|
}), q.handleDeactivate = q.handleDeactivate.bind(q), q.handlePostDeactivate = q.handlePostDeactivate.bind(q), q.handleClickOutsideDeactivates = q.handleClickOutsideDeactivates.bind(q), q.internalOptions = {
|
|
2799
2799
|
// We need to hijack the returnFocusOnDeactivate option,
|
|
2800
2800
|
// because React can move focus into the element before we arrived at
|
|
@@ -2825,7 +2825,7 @@ function Hf() {
|
|
|
2825
2825
|
// the user's setting, defaulted to false since focus-trap defaults this to false
|
|
2826
2826
|
clickOutsideDeactivates: !1
|
|
2827
2827
|
};
|
|
2828
|
-
var te =
|
|
2828
|
+
var te = V.focusTrapOptions;
|
|
2829
2829
|
for (var Y in te)
|
|
2830
2830
|
if (Object.prototype.hasOwnProperty.call(te, Y)) {
|
|
2831
2831
|
if (Y === "returnFocusOnDeactivate" || Y === "onDeactivate" || Y === "onPostDeactivate" || Y === "checkCanReturnFocus" || Y === "clickOutsideDeactivates") {
|
|
@@ -2834,9 +2834,9 @@ function Hf() {
|
|
|
2834
2834
|
}
|
|
2835
2835
|
q.internalOptions[Y] = te[Y];
|
|
2836
2836
|
}
|
|
2837
|
-
return q.outsideClick = null, q.focusTrapElements =
|
|
2837
|
+
return q.outsideClick = null, q.focusTrapElements = V.containerElements || [], q.updatePreviousElement(), q;
|
|
2838
2838
|
}
|
|
2839
|
-
return c(
|
|
2839
|
+
return c(w, x), r(w, [{
|
|
2840
2840
|
key: "getDocument",
|
|
2841
2841
|
value: function() {
|
|
2842
2842
|
return this.props.focusTrapOptions.document || (typeof document < "u" ? document : void 0);
|
|
@@ -2892,16 +2892,16 @@ function Hf() {
|
|
|
2892
2892
|
key: "handlePostDeactivate",
|
|
2893
2893
|
value: function() {
|
|
2894
2894
|
var q = this, te = function() {
|
|
2895
|
-
var $ = q.getReturnFocusNode(),
|
|
2895
|
+
var $ = q.getReturnFocusNode(), k = !!// did the consumer allow it?
|
|
2896
2896
|
(q.originalOptions.returnFocusOnDeactivate && // can we actually focus the node?
|
|
2897
2897
|
$ !== null && $ !== void 0 && $.focus && // was there an outside click that allowed deactivation?
|
|
2898
2898
|
(!q.outsideClick || // did the consumer allow deactivation when the outside node was clicked?
|
|
2899
2899
|
q.outsideClick.allowDeactivation && // is the outside node NOT focusable (implying that it did NOT receive focus
|
|
2900
2900
|
// as a result of the click-through) -- in which case do NOT restore focus
|
|
2901
2901
|
// to `returnFocusNode` because focus should remain on the outside node
|
|
2902
|
-
!P(q.outsideClick.target, q.internalOptions.tabbableOptions))), I = q.internalOptions.preventScroll,
|
|
2903
|
-
|
|
2904
|
-
preventScroll:
|
|
2902
|
+
!P(q.outsideClick.target, q.internalOptions.tabbableOptions))), I = q.internalOptions.preventScroll, L = I === void 0 ? !1 : I;
|
|
2903
|
+
k && $.focus({
|
|
2904
|
+
preventScroll: L
|
|
2905
2905
|
}), q.originalOptions.onPostDeactivate && q.originalOptions.onPostDeactivate.call(null), q.outsideClick = null;
|
|
2906
2906
|
};
|
|
2907
2907
|
this.originalOptions.checkCanReturnFocus ? this.originalOptions.checkCanReturnFocus.call(null, this.getReturnFocusNode()).then(te, te) : te();
|
|
@@ -2926,12 +2926,12 @@ function Hf() {
|
|
|
2926
2926
|
value: function(q) {
|
|
2927
2927
|
if (this.focusTrap) {
|
|
2928
2928
|
q.containerElements !== this.props.containerElements && this.focusTrap.updateContainerElements(this.props.containerElements);
|
|
2929
|
-
var te = !q.active && this.props.active, Y = q.active && !this.props.active, $ = !q.paused && this.props.paused,
|
|
2929
|
+
var te = !q.active && this.props.active, Y = q.active && !this.props.active, $ = !q.paused && this.props.paused, k = q.paused && !this.props.paused;
|
|
2930
2930
|
if (te && (this.updatePreviousElement(), this.focusTrap.activate()), Y) {
|
|
2931
2931
|
this.deactivateTrap();
|
|
2932
2932
|
return;
|
|
2933
2933
|
}
|
|
2934
|
-
$ && this.focusTrap.pause(),
|
|
2934
|
+
$ && this.focusTrap.pause(), k && this.focusTrap.unpause();
|
|
2935
2935
|
} else
|
|
2936
2936
|
q.containerElements !== this.props.containerElements && (this.focusTrapElements = this.props.containerElements), this.props.active && (this.updatePreviousElement(), this.setupFocusTrap());
|
|
2937
2937
|
}
|
|
@@ -2948,8 +2948,8 @@ function Hf() {
|
|
|
2948
2948
|
if (te.type && te.type === b.Fragment)
|
|
2949
2949
|
throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");
|
|
2950
2950
|
var Y = function(I) {
|
|
2951
|
-
var
|
|
2952
|
-
te && (typeof te.ref == "function" ? te.ref(I) : te.ref && (te.ref.current = I)), q.focusTrapElements =
|
|
2951
|
+
var L = q.props.containerElements;
|
|
2952
|
+
te && (typeof te.ref == "function" ? te.ref(I) : te.ref && (te.ref.current = I)), q.focusTrapElements = L || [I];
|
|
2953
2953
|
}, $ = b.cloneElement(te, {
|
|
2954
2954
|
ref: Y
|
|
2955
2955
|
});
|
|
@@ -2958,8 +2958,8 @@ function Hf() {
|
|
|
2958
2958
|
return null;
|
|
2959
2959
|
}
|
|
2960
2960
|
}]);
|
|
2961
|
-
})(b.Component),
|
|
2962
|
-
return
|
|
2961
|
+
})(b.Component), F = typeof Element > "u" ? Function : Element;
|
|
2962
|
+
return X.propTypes = {
|
|
2963
2963
|
active: m.bool,
|
|
2964
2964
|
paused: m.bool,
|
|
2965
2965
|
focusTrapOptions: m.shape({
|
|
@@ -2974,9 +2974,9 @@ function Hf() {
|
|
|
2974
2974
|
onDeactivate: m.func,
|
|
2975
2975
|
onPostDeactivate: m.func,
|
|
2976
2976
|
checkCanReturnFocus: m.func,
|
|
2977
|
-
initialFocus: m.oneOfType([m.instanceOf(
|
|
2977
|
+
initialFocus: m.oneOfType([m.instanceOf(F), m.string, m.bool, m.func]),
|
|
2978
2978
|
fallbackFocus: m.oneOfType([
|
|
2979
|
-
m.instanceOf(
|
|
2979
|
+
m.instanceOf(F),
|
|
2980
2980
|
m.string,
|
|
2981
2981
|
// NOTE: does not support `false` as value (or return value from function)
|
|
2982
2982
|
m.func
|
|
@@ -2984,7 +2984,7 @@ function Hf() {
|
|
|
2984
2984
|
escapeDeactivates: m.oneOfType([m.bool, m.func]),
|
|
2985
2985
|
clickOutsideDeactivates: m.oneOfType([m.bool, m.func]),
|
|
2986
2986
|
returnFocusOnDeactivate: m.bool,
|
|
2987
|
-
setReturnFocus: m.oneOfType([m.instanceOf(
|
|
2987
|
+
setReturnFocus: m.oneOfType([m.instanceOf(F), m.string, m.bool, m.func]),
|
|
2988
2988
|
allowOutsideClick: m.oneOfType([m.bool, m.func]),
|
|
2989
2989
|
preventScroll: m.bool,
|
|
2990
2990
|
tabbableOptions: m.shape({
|
|
@@ -2995,23 +2995,23 @@ function Hf() {
|
|
|
2995
2995
|
isKeyForward: m.func,
|
|
2996
2996
|
isKeyBackward: m.func
|
|
2997
2997
|
}),
|
|
2998
|
-
containerElements: m.arrayOf(m.instanceOf(
|
|
2998
|
+
containerElements: m.arrayOf(m.instanceOf(F)),
|
|
2999
2999
|
// DOM element ONLY
|
|
3000
3000
|
children: m.oneOfType([
|
|
3001
3001
|
m.element,
|
|
3002
3002
|
// React element
|
|
3003
|
-
m.instanceOf(
|
|
3003
|
+
m.instanceOf(F)
|
|
3004
3004
|
// DOM element
|
|
3005
3005
|
])
|
|
3006
3006
|
// NOTE: _createFocusTrap is internal, for testing purposes only, so we don't
|
|
3007
3007
|
// specify it here. It's expected to be set to the function returned from
|
|
3008
3008
|
// require('focus-trap'), or one with a compatible interface.
|
|
3009
|
-
},
|
|
3009
|
+
}, X.defaultProps = {
|
|
3010
3010
|
active: !0,
|
|
3011
3011
|
paused: !1,
|
|
3012
3012
|
focusTrapOptions: {},
|
|
3013
3013
|
_createFocusTrap: g
|
|
3014
|
-
}, Ca =
|
|
3014
|
+
}, Ca = X, Ca;
|
|
3015
3015
|
}
|
|
3016
3016
|
var Uf = Hf();
|
|
3017
3017
|
const jf = /* @__PURE__ */ Ft(Uf);
|
|
@@ -3347,19 +3347,19 @@ function nh(e, t) {
|
|
|
3347
3347
|
const T = [], g = m.hFlip, D = m.vFlip;
|
|
3348
3348
|
let P = m.rotate;
|
|
3349
3349
|
g ? D ? P += 2 : (T.push("translate(" + (a.width + a.left).toString() + " " + (0 - a.top).toString() + ")"), T.push("scale(-1 1)"), a.top = a.left = 0) : D && (T.push("translate(" + (0 - a.left).toString() + " " + (a.height + a.top).toString() + ")"), T.push("scale(1 -1)"), a.top = a.left = 0);
|
|
3350
|
-
let
|
|
3350
|
+
let X;
|
|
3351
3351
|
switch (P < 0 && (P -= Math.floor(P / 4) * 4), P = P % 4, P) {
|
|
3352
3352
|
case 1:
|
|
3353
|
-
|
|
3353
|
+
X = a.height / 2 + a.top, T.unshift("rotate(90 " + X.toString() + " " + X.toString() + ")");
|
|
3354
3354
|
break;
|
|
3355
3355
|
case 2:
|
|
3356
3356
|
T.unshift("rotate(180 " + (a.width / 2 + a.left).toString() + " " + (a.height / 2 + a.top).toString() + ")");
|
|
3357
3357
|
break;
|
|
3358
3358
|
case 3:
|
|
3359
|
-
|
|
3359
|
+
X = a.width / 2 + a.left, T.unshift("rotate(-90 " + X.toString() + " " + X.toString() + ")");
|
|
3360
3360
|
break;
|
|
3361
3361
|
}
|
|
3362
|
-
P % 2 === 1 && (a.left !== a.top && (
|
|
3362
|
+
P % 2 === 1 && (a.left !== a.top && (X = a.left, a.left = a.top, a.top = X), a.width !== a.height && (X = a.width, a.width = a.height, a.height = X)), T.length && (i = eh(i, '<g transform="' + T.join(" ") + '">', "</g>"));
|
|
3363
3363
|
});
|
|
3364
3364
|
const u = r.width, s = r.height, l = a.width, c = a.height;
|
|
3365
3365
|
let d, f;
|
|
@@ -3619,8 +3619,8 @@ function Ch(e, t, n, r) {
|
|
|
3619
3619
|
if (e.random) {
|
|
3620
3620
|
let x = e.resources.slice(0);
|
|
3621
3621
|
for (u = []; x.length > 1; ) {
|
|
3622
|
-
const
|
|
3623
|
-
u.push(x[
|
|
3622
|
+
const w = Math.floor(Math.random() * x.length);
|
|
3623
|
+
u.push(x[w]), x = x.slice(0, w).concat(x.slice(w + 1));
|
|
3624
3624
|
}
|
|
3625
3625
|
u = u.concat(x);
|
|
3626
3626
|
} else u = e.resources.slice(i).concat(e.resources.slice(0, i));
|
|
@@ -3635,8 +3635,8 @@ function Ch(e, t, n, r) {
|
|
|
3635
3635
|
x.status === "pending" && (x.status = "aborted");
|
|
3636
3636
|
}), p = [];
|
|
3637
3637
|
}
|
|
3638
|
-
function T(x,
|
|
3639
|
-
|
|
3638
|
+
function T(x, w) {
|
|
3639
|
+
w && (h = []), typeof x == "function" && h.push(x);
|
|
3640
3640
|
}
|
|
3641
3641
|
function g() {
|
|
3642
3642
|
return {
|
|
@@ -3659,8 +3659,8 @@ function Ch(e, t, n, r) {
|
|
|
3659
3659
|
x.status === "pending" && (x.status = "aborted");
|
|
3660
3660
|
}), p = [];
|
|
3661
3661
|
}
|
|
3662
|
-
function
|
|
3663
|
-
const q =
|
|
3662
|
+
function X(x, w, V) {
|
|
3663
|
+
const q = w !== "success";
|
|
3664
3664
|
switch (p = p.filter((te) => te !== x), l) {
|
|
3665
3665
|
case "pending":
|
|
3666
3666
|
break;
|
|
@@ -3670,12 +3670,12 @@ function Ch(e, t, n, r) {
|
|
|
3670
3670
|
default:
|
|
3671
3671
|
return;
|
|
3672
3672
|
}
|
|
3673
|
-
if (
|
|
3674
|
-
d =
|
|
3673
|
+
if (w === "abort") {
|
|
3674
|
+
d = V, D();
|
|
3675
3675
|
return;
|
|
3676
3676
|
}
|
|
3677
3677
|
if (q) {
|
|
3678
|
-
d =
|
|
3678
|
+
d = V, p.length || (u.length ? F() : D());
|
|
3679
3679
|
return;
|
|
3680
3680
|
}
|
|
3681
3681
|
if (b(), P(), !e.random) {
|
|
@@ -3683,10 +3683,10 @@ function Ch(e, t, n, r) {
|
|
|
3683
3683
|
te !== -1 && te !== e.index && (e.index = te);
|
|
3684
3684
|
}
|
|
3685
3685
|
l = "completed", h.forEach((te) => {
|
|
3686
|
-
te(
|
|
3686
|
+
te(V);
|
|
3687
3687
|
});
|
|
3688
3688
|
}
|
|
3689
|
-
function
|
|
3689
|
+
function F() {
|
|
3690
3690
|
if (l !== "pending") return;
|
|
3691
3691
|
b();
|
|
3692
3692
|
const x = u.shift();
|
|
@@ -3700,16 +3700,16 @@ function Ch(e, t, n, r) {
|
|
|
3700
3700
|
D();
|
|
3701
3701
|
return;
|
|
3702
3702
|
}
|
|
3703
|
-
const
|
|
3703
|
+
const w = {
|
|
3704
3704
|
status: "pending",
|
|
3705
3705
|
resource: x,
|
|
3706
|
-
callback: (
|
|
3707
|
-
|
|
3706
|
+
callback: (V, q) => {
|
|
3707
|
+
X(w, V, q);
|
|
3708
3708
|
}
|
|
3709
3709
|
};
|
|
3710
|
-
p.push(
|
|
3710
|
+
p.push(w), c++, f = setTimeout(F, e.rotate), n(x, t, w.callback);
|
|
3711
3711
|
}
|
|
3712
|
-
return setTimeout(
|
|
3712
|
+
return setTimeout(F), g;
|
|
3713
3713
|
}
|
|
3714
3714
|
function cl(e) {
|
|
3715
3715
|
const t = {
|
|
@@ -4185,30 +4185,30 @@ function Ni({
|
|
|
4185
4185
|
inputRef: r,
|
|
4186
4186
|
handleChange: a
|
|
4187
4187
|
}) {
|
|
4188
|
-
const i = et(!1), { conversationScreen: u } = oe($e), { handleStop:
|
|
4189
|
-
hasError:
|
|
4190
|
-
hasNewMessage:
|
|
4191
|
-
loading:
|
|
4192
|
-
loadingHistory:
|
|
4193
|
-
streaming:
|
|
4194
|
-
internalStreaming:
|
|
4195
|
-
externalStreaming:
|
|
4196
|
-
} = oe(tt), [
|
|
4197
|
-
(
|
|
4198
|
-
|
|
4188
|
+
const i = et(!1), { conversationScreen: u, primaryColor: s } = oe($e), { handleStop: l, onStreamingStop: c } = oe($t), {
|
|
4189
|
+
hasError: d,
|
|
4190
|
+
hasNewMessage: f,
|
|
4191
|
+
loading: p,
|
|
4192
|
+
loadingHistory: h,
|
|
4193
|
+
streaming: b,
|
|
4194
|
+
internalStreaming: m,
|
|
4195
|
+
externalStreaming: T
|
|
4196
|
+
} = oe(tt), [g, D] = le(""), P = dt(
|
|
4197
|
+
(V) => {
|
|
4198
|
+
V.preventDefault(), D(V.target.value), a && a(V);
|
|
4199
4199
|
},
|
|
4200
|
-
[a,
|
|
4201
|
-
),
|
|
4202
|
-
|
|
4203
|
-
},
|
|
4200
|
+
[a, D]
|
|
4201
|
+
), X = () => {
|
|
4202
|
+
D(""), r.current && (r.current.style.height = "auto");
|
|
4203
|
+
}, F = e || p || h || b;
|
|
4204
4204
|
Le(() => {
|
|
4205
|
-
i.current && !
|
|
4206
|
-
}, [
|
|
4207
|
-
(
|
|
4208
|
-
}, [
|
|
4209
|
-
const
|
|
4210
|
-
|
|
4211
|
-
},
|
|
4205
|
+
i.current && !F && r.current?.focus(), i.current = F;
|
|
4206
|
+
}, [F, r]), Le(() => {
|
|
4207
|
+
(d || f) && r.current?.focus();
|
|
4208
|
+
}, [f, d, r]);
|
|
4209
|
+
const x = (V) => {
|
|
4210
|
+
V.key === "Enter" && g.trim() === "" || V.key === "Enter" && !V.shiftKey && (V.preventDefault(), t(g), X());
|
|
4211
|
+
}, w = () => {
|
|
4212
4212
|
/* istanbul ignore next @preserve */
|
|
4213
4213
|
r.current && (r.current.style.height = "auto", r.current.style.height = `${Math.min(
|
|
4214
4214
|
r.current?.scrollHeight,
|
|
@@ -4220,16 +4220,16 @@ function Ni({
|
|
|
4220
4220
|
"textarea",
|
|
4221
4221
|
{
|
|
4222
4222
|
"data-testid": "ConversationInput",
|
|
4223
|
-
disabled:
|
|
4224
|
-
value:
|
|
4223
|
+
disabled: F,
|
|
4224
|
+
value: g,
|
|
4225
4225
|
ref: r,
|
|
4226
|
-
onInput:
|
|
4227
|
-
onChange:
|
|
4226
|
+
onInput: w,
|
|
4227
|
+
onChange: P,
|
|
4228
4228
|
placeholder: "Write a message",
|
|
4229
4229
|
cols: "5",
|
|
4230
4230
|
rows: "1",
|
|
4231
4231
|
maxLength: u?.input?.maxLength ?? 5e3,
|
|
4232
|
-
onKeyDown:
|
|
4232
|
+
onKeyDown: x,
|
|
4233
4233
|
style: {
|
|
4234
4234
|
margin: "0",
|
|
4235
4235
|
borderRadius: "1rem",
|
|
@@ -4243,17 +4243,17 @@ function Ni({
|
|
|
4243
4243
|
padding: "12.5px 45px 12.5px 12.5px",
|
|
4244
4244
|
resize: "none",
|
|
4245
4245
|
width: "100%",
|
|
4246
|
-
outlineColor:
|
|
4246
|
+
outlineColor: s
|
|
4247
4247
|
}
|
|
4248
4248
|
}
|
|
4249
4249
|
),
|
|
4250
|
-
|
|
4250
|
+
T && c || p || m ? /* @__PURE__ */ _.jsx(
|
|
4251
4251
|
"button",
|
|
4252
4252
|
{
|
|
4253
4253
|
"data-testid": "Stop",
|
|
4254
4254
|
className: "xpert-chatbot-popup__input--stop-btn",
|
|
4255
|
-
onClick: (
|
|
4256
|
-
|
|
4255
|
+
onClick: (V) => {
|
|
4256
|
+
V.preventDefault(), l();
|
|
4257
4257
|
},
|
|
4258
4258
|
"aria-label": "Stop streaming",
|
|
4259
4259
|
children: /* @__PURE__ */ _.jsx(kt, { icon: "material-symbols:stop", style: { fontSize: "1.75rem" } })
|
|
@@ -4262,10 +4262,10 @@ function Ni({
|
|
|
4262
4262
|
"button",
|
|
4263
4263
|
{
|
|
4264
4264
|
"data-testid": "Send",
|
|
4265
|
-
disabled:
|
|
4265
|
+
disabled: F,
|
|
4266
4266
|
className: "xpert-chatbot-popup__input--send-btn",
|
|
4267
|
-
onClick: (
|
|
4268
|
-
|
|
4267
|
+
onClick: (V) => {
|
|
4268
|
+
V.preventDefault(), t(g), X();
|
|
4269
4269
|
},
|
|
4270
4270
|
"aria-label": "Send message",
|
|
4271
4271
|
children: /* @__PURE__ */ _.jsx(kt, { icon: "material-symbols:send", style: { fontSize: "1.75rem" } })
|
|
@@ -4946,45 +4946,45 @@ function bl() {
|
|
|
4946
4946
|
function l(m, ...T) {
|
|
4947
4947
|
let g;
|
|
4948
4948
|
if (wa("use", r), m != null) if (typeof m == "function")
|
|
4949
|
-
|
|
4949
|
+
F(m, ...T);
|
|
4950
4950
|
else if (typeof m == "object")
|
|
4951
|
-
Array.isArray(m) ?
|
|
4951
|
+
Array.isArray(m) ? X(m) : P(m);
|
|
4952
4952
|
else
|
|
4953
4953
|
throw new TypeError("Expected usable value, not `" + m + "`");
|
|
4954
4954
|
return g && (n.settings = Object.assign(n.settings || {}, g)), i;
|
|
4955
4955
|
function D(x) {
|
|
4956
4956
|
if (typeof x == "function")
|
|
4957
|
-
|
|
4957
|
+
F(x);
|
|
4958
4958
|
else if (typeof x == "object")
|
|
4959
4959
|
if (Array.isArray(x)) {
|
|
4960
|
-
const [
|
|
4961
|
-
|
|
4960
|
+
const [w, ...V] = x;
|
|
4961
|
+
F(w, ...V);
|
|
4962
4962
|
} else
|
|
4963
4963
|
P(x);
|
|
4964
4964
|
else
|
|
4965
4965
|
throw new TypeError("Expected usable value, not `" + x + "`");
|
|
4966
4966
|
}
|
|
4967
4967
|
function P(x) {
|
|
4968
|
-
|
|
4968
|
+
X(x.plugins), x.settings && (g = Object.assign(g || {}, x.settings));
|
|
4969
4969
|
}
|
|
4970
|
-
function
|
|
4971
|
-
let
|
|
4970
|
+
function X(x) {
|
|
4971
|
+
let w = -1;
|
|
4972
4972
|
if (x != null) if (Array.isArray(x))
|
|
4973
|
-
for (; ++
|
|
4974
|
-
const
|
|
4975
|
-
D(
|
|
4973
|
+
for (; ++w < x.length; ) {
|
|
4974
|
+
const V = x[w];
|
|
4975
|
+
D(V);
|
|
4976
4976
|
}
|
|
4977
4977
|
else
|
|
4978
4978
|
throw new TypeError("Expected a list of plugins, not `" + x + "`");
|
|
4979
4979
|
}
|
|
4980
|
-
function
|
|
4981
|
-
let
|
|
4982
|
-
for (; ++
|
|
4983
|
-
if (t[
|
|
4984
|
-
q = t[
|
|
4980
|
+
function F(x, w) {
|
|
4981
|
+
let V = -1, q;
|
|
4982
|
+
for (; ++V < t.length; )
|
|
4983
|
+
if (t[V][0] === x) {
|
|
4984
|
+
q = t[V];
|
|
4985
4985
|
break;
|
|
4986
4986
|
}
|
|
4987
|
-
q ? (oi(q[1]) && oi(
|
|
4987
|
+
q ? (oi(q[1]) && oi(w) && (w = Ju(!0, q[1], w)), q[1] = w) : t.push([...arguments]);
|
|
4988
4988
|
}
|
|
4989
4989
|
}
|
|
4990
4990
|
function c(m) {
|
|
@@ -5001,18 +5001,18 @@ function bl() {
|
|
|
5001
5001
|
if (to(m), i.freeze(), !g && typeof T == "function" && (g = T, T = void 0), !g)
|
|
5002
5002
|
return new Promise(D);
|
|
5003
5003
|
D(null, g);
|
|
5004
|
-
function D(P,
|
|
5005
|
-
e.run(m, $n(T),
|
|
5006
|
-
function
|
|
5007
|
-
|
|
5004
|
+
function D(P, X) {
|
|
5005
|
+
e.run(m, $n(T), F);
|
|
5006
|
+
function F(x, w, V) {
|
|
5007
|
+
w = w || m, x ? X(x) : P ? P(w) : g(null, w, V);
|
|
5008
5008
|
}
|
|
5009
5009
|
}
|
|
5010
5010
|
}
|
|
5011
5011
|
function p(m, T) {
|
|
5012
5012
|
let g, D;
|
|
5013
5013
|
return i.run(m, T, P), no("runSync", "run", D), g;
|
|
5014
|
-
function P(
|
|
5015
|
-
Qu(
|
|
5014
|
+
function P(X, F) {
|
|
5015
|
+
Qu(X), g = F, D = !0;
|
|
5016
5016
|
}
|
|
5017
5017
|
}
|
|
5018
5018
|
function h(m, T) {
|
|
@@ -5020,17 +5020,17 @@ function bl() {
|
|
|
5020
5020
|
return new Promise(g);
|
|
5021
5021
|
g(null, T);
|
|
5022
5022
|
function g(D, P) {
|
|
5023
|
-
const
|
|
5024
|
-
i.run(i.parse(
|
|
5025
|
-
if (x || !
|
|
5026
|
-
|
|
5023
|
+
const X = $n(m);
|
|
5024
|
+
i.run(i.parse(X), X, (x, w, V) => {
|
|
5025
|
+
if (x || !w || !V)
|
|
5026
|
+
F(x);
|
|
5027
5027
|
else {
|
|
5028
|
-
const q = i.stringify(
|
|
5029
|
-
q == null || (cp(q) ?
|
|
5028
|
+
const q = i.stringify(w, V);
|
|
5029
|
+
q == null || (cp(q) ? V.value = q : V.result = q), F(x, V);
|
|
5030
5030
|
}
|
|
5031
5031
|
});
|
|
5032
|
-
function
|
|
5033
|
-
x || !
|
|
5032
|
+
function F(x, w) {
|
|
5033
|
+
x || !w ? P(x) : D ? D(w) : T(null, w);
|
|
5034
5034
|
}
|
|
5035
5035
|
}
|
|
5036
5036
|
}
|
|
@@ -5227,9 +5227,9 @@ function yp(e) {
|
|
|
5227
5227
|
return s;
|
|
5228
5228
|
function s(P) {
|
|
5229
5229
|
if (r < n.length) {
|
|
5230
|
-
const
|
|
5231
|
-
return t.containerState =
|
|
5232
|
-
|
|
5230
|
+
const X = n[r];
|
|
5231
|
+
return t.containerState = X[1], e.attempt(
|
|
5232
|
+
X[0].continuation,
|
|
5233
5233
|
l,
|
|
5234
5234
|
c
|
|
5235
5235
|
)(P);
|
|
@@ -5239,23 +5239,23 @@ function yp(e) {
|
|
|
5239
5239
|
function l(P) {
|
|
5240
5240
|
if (r++, t.containerState._closeFlow) {
|
|
5241
5241
|
t.containerState._closeFlow = void 0, a && D();
|
|
5242
|
-
const
|
|
5243
|
-
let
|
|
5244
|
-
for (;
|
|
5245
|
-
if (t.events[
|
|
5246
|
-
x = t.events[
|
|
5242
|
+
const X = t.events.length;
|
|
5243
|
+
let F = X, x;
|
|
5244
|
+
for (; F--; )
|
|
5245
|
+
if (t.events[F][0] === "exit" && t.events[F][1].type === "chunkFlow") {
|
|
5246
|
+
x = t.events[F][1].end;
|
|
5247
5247
|
break;
|
|
5248
5248
|
}
|
|
5249
5249
|
g(r);
|
|
5250
|
-
let
|
|
5251
|
-
for (;
|
|
5252
|
-
t.events[
|
|
5250
|
+
let w = X;
|
|
5251
|
+
for (; w < t.events.length; )
|
|
5252
|
+
t.events[w][1].end = Object.assign({}, x), w++;
|
|
5253
5253
|
return Mt(
|
|
5254
5254
|
t.events,
|
|
5255
|
-
|
|
5255
|
+
F + 1,
|
|
5256
5256
|
0,
|
|
5257
|
-
t.events.slice(
|
|
5258
|
-
), t.events.length =
|
|
5257
|
+
t.events.slice(X)
|
|
5258
|
+
), t.events.length = w, c(P);
|
|
5259
5259
|
}
|
|
5260
5260
|
return s(P);
|
|
5261
5261
|
}
|
|
@@ -5307,9 +5307,9 @@ function yp(e) {
|
|
|
5307
5307
|
}
|
|
5308
5308
|
return ki(P) ? (e.consume(P), T(e.exit("chunkFlow")), r = 0, t.interrupt = void 0, s) : (e.consume(P), m);
|
|
5309
5309
|
}
|
|
5310
|
-
function T(P,
|
|
5311
|
-
const
|
|
5312
|
-
if (
|
|
5310
|
+
function T(P, X) {
|
|
5311
|
+
const F = t.sliceStream(P);
|
|
5312
|
+
if (X && F.push(null), P.previous = i, i && (i.next = P), i = P, a.defineSkip(P.start), a.write(F), t.parser.lazy[P.start.line]) {
|
|
5313
5313
|
let x = a.events.length;
|
|
5314
5314
|
for (; x--; )
|
|
5315
5315
|
if (
|
|
@@ -5319,31 +5319,31 @@ function yp(e) {
|
|
|
5319
5319
|
a.events[x][1].end.offset > u)
|
|
5320
5320
|
)
|
|
5321
5321
|
return;
|
|
5322
|
-
const
|
|
5323
|
-
let
|
|
5324
|
-
for (;
|
|
5325
|
-
if (t.events[
|
|
5322
|
+
const w = t.events.length;
|
|
5323
|
+
let V = w, q, te;
|
|
5324
|
+
for (; V--; )
|
|
5325
|
+
if (t.events[V][0] === "exit" && t.events[V][1].type === "chunkFlow") {
|
|
5326
5326
|
if (q) {
|
|
5327
|
-
te = t.events[
|
|
5327
|
+
te = t.events[V][1].end;
|
|
5328
5328
|
break;
|
|
5329
5329
|
}
|
|
5330
5330
|
q = !0;
|
|
5331
5331
|
}
|
|
5332
|
-
for (g(r), x =
|
|
5332
|
+
for (g(r), x = w; x < t.events.length; )
|
|
5333
5333
|
t.events[x][1].end = Object.assign({}, te), x++;
|
|
5334
5334
|
Mt(
|
|
5335
5335
|
t.events,
|
|
5336
|
-
|
|
5336
|
+
V + 1,
|
|
5337
5337
|
0,
|
|
5338
|
-
t.events.slice(
|
|
5338
|
+
t.events.slice(w)
|
|
5339
5339
|
), t.events.length = x;
|
|
5340
5340
|
}
|
|
5341
5341
|
}
|
|
5342
5342
|
function g(P) {
|
|
5343
|
-
let
|
|
5344
|
-
for (;
|
|
5345
|
-
const
|
|
5346
|
-
t.containerState =
|
|
5343
|
+
let X = n.length;
|
|
5344
|
+
for (; X-- > P; ) {
|
|
5345
|
+
const F = n[X];
|
|
5346
|
+
t.containerState = F[1], F[0].exit.call(t, e);
|
|
5347
5347
|
}
|
|
5348
5348
|
n.length = P;
|
|
5349
5349
|
}
|
|
@@ -5642,7 +5642,7 @@ const co = {
|
|
|
5642
5642
|
};
|
|
5643
5643
|
function Up(e, t, n) {
|
|
5644
5644
|
const r = this, a = {
|
|
5645
|
-
tokenize:
|
|
5645
|
+
tokenize: F,
|
|
5646
5646
|
partial: !0
|
|
5647
5647
|
};
|
|
5648
5648
|
let i = 0, u = 0, s;
|
|
@@ -5651,14 +5651,14 @@ function Up(e, t, n) {
|
|
|
5651
5651
|
return c(x);
|
|
5652
5652
|
}
|
|
5653
5653
|
function c(x) {
|
|
5654
|
-
const
|
|
5655
|
-
return i =
|
|
5654
|
+
const w = r.events[r.events.length - 1];
|
|
5655
|
+
return i = w && w[1].type === "linePrefix" ? w[2].sliceSerialize(w[1], !0).length : 0, s = x, e.enter("codeFenced"), e.enter("codeFencedFence"), e.enter("codeFencedFenceSequence"), d(x);
|
|
5656
5656
|
}
|
|
5657
5657
|
function d(x) {
|
|
5658
5658
|
return x === s ? (u++, e.consume(x), d) : u < 3 ? n(x) : (e.exit("codeFencedFenceSequence"), ke(x) ? Pe(e, f, "whitespace")(x) : f(x));
|
|
5659
5659
|
}
|
|
5660
5660
|
function f(x) {
|
|
5661
|
-
return x === null || ge(x) ? (e.exit("codeFencedFence"), r.interrupt ? t(x) : e.check(co, m,
|
|
5661
|
+
return x === null || ge(x) ? (e.exit("codeFencedFence"), r.interrupt ? t(x) : e.check(co, m, X)(x)) : (e.enter("codeFencedFenceInfo"), e.enter("chunkString", {
|
|
5662
5662
|
contentType: "string"
|
|
5663
5663
|
}), p(x));
|
|
5664
5664
|
}
|
|
@@ -5674,7 +5674,7 @@ function Up(e, t, n) {
|
|
|
5674
5674
|
return x === null || ge(x) ? (e.exit("chunkString"), e.exit("codeFencedFenceMeta"), f(x)) : x === 96 && x === s ? n(x) : (e.consume(x), b);
|
|
5675
5675
|
}
|
|
5676
5676
|
function m(x) {
|
|
5677
|
-
return e.attempt(a,
|
|
5677
|
+
return e.attempt(a, X, T)(x);
|
|
5678
5678
|
}
|
|
5679
5679
|
function T(x) {
|
|
5680
5680
|
return e.enter("lineEnding"), e.consume(x), e.exit("lineEnding"), g;
|
|
@@ -5688,36 +5688,36 @@ function Up(e, t, n) {
|
|
|
5688
5688
|
)(x) : D(x);
|
|
5689
5689
|
}
|
|
5690
5690
|
function D(x) {
|
|
5691
|
-
return x === null || ge(x) ? e.check(co, m,
|
|
5691
|
+
return x === null || ge(x) ? e.check(co, m, X)(x) : (e.enter("codeFlowValue"), P(x));
|
|
5692
5692
|
}
|
|
5693
5693
|
function P(x) {
|
|
5694
5694
|
return x === null || ge(x) ? (e.exit("codeFlowValue"), D(x)) : (e.consume(x), P);
|
|
5695
5695
|
}
|
|
5696
|
-
function
|
|
5696
|
+
function X(x) {
|
|
5697
5697
|
return e.exit("codeFenced"), t(x);
|
|
5698
5698
|
}
|
|
5699
|
-
function
|
|
5699
|
+
function F(x, w, V) {
|
|
5700
5700
|
let q = 0;
|
|
5701
5701
|
return te;
|
|
5702
|
-
function te(
|
|
5703
|
-
return x.enter("lineEnding"), x.consume(
|
|
5702
|
+
function te(L) {
|
|
5703
|
+
return x.enter("lineEnding"), x.consume(L), x.exit("lineEnding"), Y;
|
|
5704
5704
|
}
|
|
5705
|
-
function Y(
|
|
5706
|
-
return x.enter("codeFencedFence"), ke(
|
|
5705
|
+
function Y(L) {
|
|
5706
|
+
return x.enter("codeFencedFence"), ke(L) ? Pe(
|
|
5707
5707
|
x,
|
|
5708
5708
|
$,
|
|
5709
5709
|
"linePrefix",
|
|
5710
5710
|
r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4
|
|
5711
|
-
)(
|
|
5711
|
+
)(L) : $(L);
|
|
5712
5712
|
}
|
|
5713
|
-
function $(
|
|
5714
|
-
return
|
|
5713
|
+
function $(L) {
|
|
5714
|
+
return L === s ? (x.enter("codeFencedFenceSequence"), k(L)) : V(L);
|
|
5715
5715
|
}
|
|
5716
|
-
function L
|
|
5717
|
-
return
|
|
5716
|
+
function k(L) {
|
|
5717
|
+
return L === s ? (q++, x.consume(L), k) : q >= u ? (x.exit("codeFencedFenceSequence"), ke(L) ? Pe(x, I, "whitespace")(L) : I(L)) : V(L);
|
|
5718
5718
|
}
|
|
5719
|
-
function I(
|
|
5720
|
-
return
|
|
5719
|
+
function I(L) {
|
|
5720
|
+
return L === null || ge(L) ? (x.exit("codeFencedFence"), w(L)) : V(L);
|
|
5721
5721
|
}
|
|
5722
5722
|
}
|
|
5723
5723
|
}
|
|
@@ -6271,22 +6271,22 @@ function y1(e, t, n) {
|
|
|
6271
6271
|
return ke(v) ? (e.consume(v), D) : te(v);
|
|
6272
6272
|
}
|
|
6273
6273
|
function P(v) {
|
|
6274
|
-
return v === 47 ? (e.consume(v), te) : v === 58 || v === 95 || Pt(v) ? (e.consume(v),
|
|
6274
|
+
return v === 47 ? (e.consume(v), te) : v === 58 || v === 95 || Pt(v) ? (e.consume(v), X) : ke(v) ? (e.consume(v), P) : te(v);
|
|
6275
6275
|
}
|
|
6276
|
-
function
|
|
6277
|
-
return v === 45 || v === 46 || v === 58 || v === 95 || It(v) ? (e.consume(v),
|
|
6276
|
+
function X(v) {
|
|
6277
|
+
return v === 45 || v === 46 || v === 58 || v === 95 || It(v) ? (e.consume(v), X) : F(v);
|
|
6278
6278
|
}
|
|
6279
|
-
function
|
|
6280
|
-
return v === 61 ? (e.consume(v), x) : ke(v) ? (e.consume(v),
|
|
6279
|
+
function F(v) {
|
|
6280
|
+
return v === 61 ? (e.consume(v), x) : ke(v) ? (e.consume(v), F) : P(v);
|
|
6281
6281
|
}
|
|
6282
6282
|
function x(v) {
|
|
6283
|
-
return v === null || v === 60 || v === 61 || v === 62 || v === 96 ? n(v) : v === 34 || v === 39 ? (e.consume(v), l = v,
|
|
6283
|
+
return v === null || v === 60 || v === 61 || v === 62 || v === 96 ? n(v) : v === 34 || v === 39 ? (e.consume(v), l = v, w) : ke(v) ? (e.consume(v), x) : V(v);
|
|
6284
6284
|
}
|
|
6285
|
-
function
|
|
6286
|
-
return v === l ? (e.consume(v), l = null, q) : v === null || ge(v) ? n(v) : (e.consume(v),
|
|
6285
|
+
function w(v) {
|
|
6286
|
+
return v === l ? (e.consume(v), l = null, q) : v === null || ge(v) ? n(v) : (e.consume(v), w);
|
|
6287
6287
|
}
|
|
6288
|
-
function
|
|
6289
|
-
return v === null || v === 34 || v === 39 || v === 47 || v === 60 || v === 61 || v === 62 || v === 96 || At(v) ?
|
|
6288
|
+
function V(v) {
|
|
6289
|
+
return v === null || v === 34 || v === 39 || v === 47 || v === 60 || v === 61 || v === 62 || v === 96 || At(v) ? F(v) : (e.consume(v), V);
|
|
6290
6290
|
}
|
|
6291
6291
|
function q(v) {
|
|
6292
6292
|
return v === 47 || v === 62 || ke(v) ? P(v) : n(v);
|
|
@@ -6298,13 +6298,13 @@ function y1(e, t, n) {
|
|
|
6298
6298
|
return v === null || ge(v) ? $(v) : ke(v) ? (e.consume(v), Y) : n(v);
|
|
6299
6299
|
}
|
|
6300
6300
|
function $(v) {
|
|
6301
|
-
return v === 45 && a === 2 ? (e.consume(v),
|
|
6301
|
+
return v === 45 && a === 2 ? (e.consume(v), B) : v === 60 && a === 1 ? (e.consume(v), W) : v === 62 && a === 4 ? (e.consume(v), ne) : v === 63 && a === 3 ? (e.consume(v), y) : v === 93 && a === 5 ? (e.consume(v), z) : ge(v) && (a === 6 || a === 7) ? (e.exit("htmlFlowData"), e.check(
|
|
6302
6302
|
b1,
|
|
6303
6303
|
ae,
|
|
6304
|
-
|
|
6305
|
-
)(v)) : v === null || ge(v) ? (e.exit("htmlFlowData"),
|
|
6304
|
+
k
|
|
6305
|
+
)(v)) : v === null || ge(v) ? (e.exit("htmlFlowData"), k(v)) : (e.consume(v), $);
|
|
6306
6306
|
}
|
|
6307
|
-
function
|
|
6307
|
+
function k(v) {
|
|
6308
6308
|
return e.check(
|
|
6309
6309
|
E1,
|
|
6310
6310
|
I,
|
|
@@ -6312,23 +6312,23 @@ function y1(e, t, n) {
|
|
|
6312
6312
|
)(v);
|
|
6313
6313
|
}
|
|
6314
6314
|
function I(v) {
|
|
6315
|
-
return e.enter("lineEnding"), e.consume(v), e.exit("lineEnding"),
|
|
6315
|
+
return e.enter("lineEnding"), e.consume(v), e.exit("lineEnding"), L;
|
|
6316
6316
|
}
|
|
6317
|
-
function
|
|
6318
|
-
return v === null || ge(v) ?
|
|
6317
|
+
function L(v) {
|
|
6318
|
+
return v === null || ge(v) ? k(v) : (e.enter("htmlFlowData"), $(v));
|
|
6319
6319
|
}
|
|
6320
|
-
function
|
|
6320
|
+
function B(v) {
|
|
6321
6321
|
return v === 45 ? (e.consume(v), y) : $(v);
|
|
6322
6322
|
}
|
|
6323
|
-
function
|
|
6324
|
-
return v === 47 ? (e.consume(v), u = "",
|
|
6323
|
+
function W(v) {
|
|
6324
|
+
return v === 47 ? (e.consume(v), u = "", H) : $(v);
|
|
6325
6325
|
}
|
|
6326
|
-
function
|
|
6326
|
+
function H(v) {
|
|
6327
6327
|
if (v === 62) {
|
|
6328
6328
|
const se = u.toLowerCase();
|
|
6329
6329
|
return go.includes(se) ? (e.consume(v), ne) : $(v);
|
|
6330
6330
|
}
|
|
6331
|
-
return Pt(v) && u.length < 8 ? (e.consume(v), u += String.fromCharCode(v),
|
|
6331
|
+
return Pt(v) && u.length < 8 ? (e.consume(v), u += String.fromCharCode(v), H) : $(v);
|
|
6332
6332
|
}
|
|
6333
6333
|
function z(v) {
|
|
6334
6334
|
return v === 93 ? (e.consume(v), y) : $(v);
|
|
@@ -6371,7 +6371,7 @@ function S1(e, t, n) {
|
|
|
6371
6371
|
return e.enter("htmlText"), e.enter("htmlTextData"), e.consume(y), l;
|
|
6372
6372
|
}
|
|
6373
6373
|
function l(y) {
|
|
6374
|
-
return y === 33 ? (e.consume(y), c) : y === 47 ? (e.consume(y),
|
|
6374
|
+
return y === 33 ? (e.consume(y), c) : y === 47 ? (e.consume(y), F) : y === 63 ? (e.consume(y), P) : Pt(y) ? (e.consume(y), V) : n(y);
|
|
6375
6375
|
}
|
|
6376
6376
|
function c(y) {
|
|
6377
6377
|
return y === 45 ? (e.consume(y), d) : y === 91 ? (e.consume(y), i = 0, b) : Pt(y) ? (e.consume(y), D) : n(y);
|
|
@@ -6380,76 +6380,76 @@ function S1(e, t, n) {
|
|
|
6380
6380
|
return y === 45 ? (e.consume(y), h) : n(y);
|
|
6381
6381
|
}
|
|
6382
6382
|
function f(y) {
|
|
6383
|
-
return y === null ? n(y) : y === 45 ? (e.consume(y), p) : ge(y) ? (u = f,
|
|
6383
|
+
return y === null ? n(y) : y === 45 ? (e.consume(y), p) : ge(y) ? (u = f, W(y)) : (e.consume(y), f);
|
|
6384
6384
|
}
|
|
6385
6385
|
function p(y) {
|
|
6386
6386
|
return y === 45 ? (e.consume(y), h) : f(y);
|
|
6387
6387
|
}
|
|
6388
6388
|
function h(y) {
|
|
6389
|
-
return y === 62 ?
|
|
6389
|
+
return y === 62 ? B(y) : y === 45 ? p(y) : f(y);
|
|
6390
6390
|
}
|
|
6391
6391
|
function b(y) {
|
|
6392
6392
|
const ne = "CDATA[";
|
|
6393
6393
|
return y === ne.charCodeAt(i++) ? (e.consume(y), i === ne.length ? m : b) : n(y);
|
|
6394
6394
|
}
|
|
6395
6395
|
function m(y) {
|
|
6396
|
-
return y === null ? n(y) : y === 93 ? (e.consume(y), T) : ge(y) ? (u = m,
|
|
6396
|
+
return y === null ? n(y) : y === 93 ? (e.consume(y), T) : ge(y) ? (u = m, W(y)) : (e.consume(y), m);
|
|
6397
6397
|
}
|
|
6398
6398
|
function T(y) {
|
|
6399
6399
|
return y === 93 ? (e.consume(y), g) : m(y);
|
|
6400
6400
|
}
|
|
6401
6401
|
function g(y) {
|
|
6402
|
-
return y === 62 ?
|
|
6402
|
+
return y === 62 ? B(y) : y === 93 ? (e.consume(y), g) : m(y);
|
|
6403
6403
|
}
|
|
6404
6404
|
function D(y) {
|
|
6405
|
-
return y === null || y === 62 ?
|
|
6405
|
+
return y === null || y === 62 ? B(y) : ge(y) ? (u = D, W(y)) : (e.consume(y), D);
|
|
6406
6406
|
}
|
|
6407
6407
|
function P(y) {
|
|
6408
|
-
return y === null ? n(y) : y === 63 ? (e.consume(y),
|
|
6408
|
+
return y === null ? n(y) : y === 63 ? (e.consume(y), X) : ge(y) ? (u = P, W(y)) : (e.consume(y), P);
|
|
6409
6409
|
}
|
|
6410
|
-
function
|
|
6411
|
-
return y === 62 ?
|
|
6410
|
+
function X(y) {
|
|
6411
|
+
return y === 62 ? B(y) : P(y);
|
|
6412
6412
|
}
|
|
6413
|
-
function
|
|
6413
|
+
function F(y) {
|
|
6414
6414
|
return Pt(y) ? (e.consume(y), x) : n(y);
|
|
6415
6415
|
}
|
|
6416
6416
|
function x(y) {
|
|
6417
|
-
return y === 45 || It(y) ? (e.consume(y), x) :
|
|
6417
|
+
return y === 45 || It(y) ? (e.consume(y), x) : w(y);
|
|
6418
6418
|
}
|
|
6419
|
-
function
|
|
6420
|
-
return ge(y) ? (u =
|
|
6419
|
+
function w(y) {
|
|
6420
|
+
return ge(y) ? (u = w, W(y)) : ke(y) ? (e.consume(y), w) : B(y);
|
|
6421
6421
|
}
|
|
6422
|
-
function
|
|
6423
|
-
return y === 45 || It(y) ? (e.consume(y),
|
|
6422
|
+
function V(y) {
|
|
6423
|
+
return y === 45 || It(y) ? (e.consume(y), V) : y === 47 || y === 62 || At(y) ? q(y) : n(y);
|
|
6424
6424
|
}
|
|
6425
6425
|
function q(y) {
|
|
6426
|
-
return y === 47 ? (e.consume(y),
|
|
6426
|
+
return y === 47 ? (e.consume(y), B) : y === 58 || y === 95 || Pt(y) ? (e.consume(y), te) : ge(y) ? (u = q, W(y)) : ke(y) ? (e.consume(y), q) : B(y);
|
|
6427
6427
|
}
|
|
6428
6428
|
function te(y) {
|
|
6429
6429
|
return y === 45 || y === 46 || y === 58 || y === 95 || It(y) ? (e.consume(y), te) : Y(y);
|
|
6430
6430
|
}
|
|
6431
6431
|
function Y(y) {
|
|
6432
|
-
return y === 61 ? (e.consume(y), $) : ge(y) ? (u = Y,
|
|
6432
|
+
return y === 61 ? (e.consume(y), $) : ge(y) ? (u = Y, W(y)) : ke(y) ? (e.consume(y), Y) : q(y);
|
|
6433
6433
|
}
|
|
6434
6434
|
function $(y) {
|
|
6435
|
-
return y === null || y === 60 || y === 61 || y === 62 || y === 96 ? n(y) : y === 34 || y === 39 ? (e.consume(y), a = y,
|
|
6435
|
+
return y === null || y === 60 || y === 61 || y === 62 || y === 96 ? n(y) : y === 34 || y === 39 ? (e.consume(y), a = y, k) : ge(y) ? (u = $, W(y)) : ke(y) ? (e.consume(y), $) : (e.consume(y), I);
|
|
6436
6436
|
}
|
|
6437
|
-
function
|
|
6438
|
-
return y === a ? (e.consume(y), a = void 0,
|
|
6437
|
+
function k(y) {
|
|
6438
|
+
return y === a ? (e.consume(y), a = void 0, L) : y === null ? n(y) : ge(y) ? (u = k, W(y)) : (e.consume(y), k);
|
|
6439
6439
|
}
|
|
6440
6440
|
function I(y) {
|
|
6441
6441
|
return y === null || y === 34 || y === 39 || y === 60 || y === 61 || y === 96 ? n(y) : y === 47 || y === 62 || At(y) ? q(y) : (e.consume(y), I);
|
|
6442
6442
|
}
|
|
6443
|
-
function
|
|
6443
|
+
function L(y) {
|
|
6444
6444
|
return y === 47 || y === 62 || At(y) ? q(y) : n(y);
|
|
6445
6445
|
}
|
|
6446
|
-
function
|
|
6446
|
+
function B(y) {
|
|
6447
6447
|
return y === 62 ? (e.consume(y), e.exit("htmlTextData"), e.exit("htmlText"), t) : n(y);
|
|
6448
6448
|
}
|
|
6449
|
-
function
|
|
6450
|
-
return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(y), e.exit("lineEnding"),
|
|
6449
|
+
function W(y) {
|
|
6450
|
+
return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(y), e.exit("lineEnding"), H;
|
|
6451
6451
|
}
|
|
6452
|
-
function
|
|
6452
|
+
function H(y) {
|
|
6453
6453
|
return ke(y) ? Pe(
|
|
6454
6454
|
e,
|
|
6455
6455
|
z,
|
|
@@ -7011,10 +7011,10 @@ function tm(e, t, n) {
|
|
|
7011
7011
|
const l = {
|
|
7012
7012
|
consume: D,
|
|
7013
7013
|
enter: P,
|
|
7014
|
-
exit:
|
|
7015
|
-
attempt:
|
|
7016
|
-
check:
|
|
7017
|
-
interrupt:
|
|
7014
|
+
exit: X,
|
|
7015
|
+
attempt: w(F),
|
|
7016
|
+
check: w(x),
|
|
7017
|
+
interrupt: w(x, {
|
|
7018
7018
|
interrupt: !0
|
|
7019
7019
|
})
|
|
7020
7020
|
}, c = {
|
|
@@ -7032,7 +7032,7 @@ function tm(e, t, n) {
|
|
|
7032
7032
|
let d = t.tokenize.call(c, l);
|
|
7033
7033
|
return t.resolveAll && i.push(t), c;
|
|
7034
7034
|
function f(Y) {
|
|
7035
|
-
return u = yt(u, Y), T(), u[u.length - 1] !== null ? [] : (
|
|
7035
|
+
return u = yt(u, Y), T(), u[u.length - 1] !== null ? [] : (V(t, 0), c.events = Li(i, c.events, c), c.events);
|
|
7036
7036
|
}
|
|
7037
7037
|
function p(Y, $) {
|
|
7038
7038
|
return rm(h(Y), $);
|
|
@@ -7041,13 +7041,13 @@ function tm(e, t, n) {
|
|
|
7041
7041
|
return nm(u, Y);
|
|
7042
7042
|
}
|
|
7043
7043
|
function b() {
|
|
7044
|
-
const { line: Y, column: $, offset:
|
|
7044
|
+
const { line: Y, column: $, offset: k, _index: I, _bufferIndex: L } = r;
|
|
7045
7045
|
return {
|
|
7046
7046
|
line: Y,
|
|
7047
7047
|
column: $,
|
|
7048
|
-
offset:
|
|
7048
|
+
offset: k,
|
|
7049
7049
|
_index: I,
|
|
7050
|
-
_bufferIndex:
|
|
7050
|
+
_bufferIndex: L
|
|
7051
7051
|
};
|
|
7052
7052
|
}
|
|
7053
7053
|
function m(Y) {
|
|
@@ -7071,23 +7071,23 @@ function tm(e, t, n) {
|
|
|
7071
7071
|
ki(Y) ? (r.line++, r.column = 1, r.offset += Y === -3 ? 2 : 1, te()) : Y !== -1 && (r.column++, r.offset++), r._bufferIndex < 0 ? r._index++ : (r._bufferIndex++, r._bufferIndex === u[r._index].length && (r._bufferIndex = -1, r._index++)), c.previous = Y;
|
|
7072
7072
|
}
|
|
7073
7073
|
function P(Y, $) {
|
|
7074
|
-
const
|
|
7075
|
-
return
|
|
7074
|
+
const k = $ || {};
|
|
7075
|
+
return k.type = Y, k.start = b(), c.events.push(["enter", k, c]), s.push(k), k;
|
|
7076
7076
|
}
|
|
7077
|
-
function
|
|
7077
|
+
function X(Y) {
|
|
7078
7078
|
const $ = s.pop();
|
|
7079
7079
|
return $.end = b(), c.events.push(["exit", $, c]), $;
|
|
7080
7080
|
}
|
|
7081
|
-
function
|
|
7082
|
-
|
|
7081
|
+
function F(Y, $) {
|
|
7082
|
+
V(Y, $.from);
|
|
7083
7083
|
}
|
|
7084
7084
|
function x(Y, $) {
|
|
7085
7085
|
$.restore();
|
|
7086
7086
|
}
|
|
7087
|
-
function
|
|
7088
|
-
return
|
|
7089
|
-
function
|
|
7090
|
-
let
|
|
7087
|
+
function w(Y, $) {
|
|
7088
|
+
return k;
|
|
7089
|
+
function k(I, L, B) {
|
|
7090
|
+
let W, H, z, y;
|
|
7091
7091
|
return Array.isArray(I) ? ae(I) : "tokenize" in I ? (
|
|
7092
7092
|
// @ts-expect-error Looks like a construct.
|
|
7093
7093
|
ae([I])
|
|
@@ -7105,7 +7105,7 @@ function tm(e, t, n) {
|
|
|
7105
7105
|
}
|
|
7106
7106
|
}
|
|
7107
7107
|
function ae(pe) {
|
|
7108
|
-
return
|
|
7108
|
+
return W = pe, H = 0, pe.length === 0 ? B : v(pe[H]);
|
|
7109
7109
|
}
|
|
7110
7110
|
function v(pe) {
|
|
7111
7111
|
return Se;
|
|
@@ -7122,14 +7122,14 @@ function tm(e, t, n) {
|
|
|
7122
7122
|
}
|
|
7123
7123
|
}
|
|
7124
7124
|
function se(pe) {
|
|
7125
|
-
return Y(z, y),
|
|
7125
|
+
return Y(z, y), L;
|
|
7126
7126
|
}
|
|
7127
7127
|
function _e(pe) {
|
|
7128
|
-
return y.restore(), ++
|
|
7128
|
+
return y.restore(), ++H < W.length ? v(W[H]) : B;
|
|
7129
7129
|
}
|
|
7130
7130
|
}
|
|
7131
7131
|
}
|
|
7132
|
-
function
|
|
7132
|
+
function V(Y, $) {
|
|
7133
7133
|
Y.resolveAll && !i.includes(Y) && i.push(Y), Y.resolve && Mt(
|
|
7134
7134
|
c.events,
|
|
7135
7135
|
$,
|
|
@@ -7138,13 +7138,13 @@ function tm(e, t, n) {
|
|
|
7138
7138
|
), Y.resolveTo && (c.events = Y.resolveTo(c.events, c));
|
|
7139
7139
|
}
|
|
7140
7140
|
function q() {
|
|
7141
|
-
const Y = b(), $ = c.previous,
|
|
7141
|
+
const Y = b(), $ = c.previous, k = c.currentConstruct, I = c.events.length, L = Array.from(s);
|
|
7142
7142
|
return {
|
|
7143
|
-
restore:
|
|
7143
|
+
restore: B,
|
|
7144
7144
|
from: I
|
|
7145
7145
|
};
|
|
7146
|
-
function
|
|
7147
|
-
r = Y, c.previous = $, c.currentConstruct =
|
|
7146
|
+
function B() {
|
|
7147
|
+
r = Y, c.previous = $, c.currentConstruct = k, c.events.length = I, s = L, te();
|
|
7148
7148
|
}
|
|
7149
7149
|
}
|
|
7150
7150
|
function te() {
|
|
@@ -7427,7 +7427,7 @@ function _m(e) {
|
|
|
7427
7427
|
},
|
|
7428
7428
|
exit: {
|
|
7429
7429
|
atxHeading: d(),
|
|
7430
|
-
atxHeadingSequence:
|
|
7430
|
+
atxHeadingSequence: w,
|
|
7431
7431
|
autolink: d(),
|
|
7432
7432
|
autolinkEmail: Ie,
|
|
7433
7433
|
autolinkProtocol: ze,
|
|
@@ -7442,25 +7442,25 @@ function _m(e) {
|
|
|
7442
7442
|
codeFencedFenceMeta: T,
|
|
7443
7443
|
codeFlowValue: $,
|
|
7444
7444
|
codeIndented: d(P),
|
|
7445
|
-
codeText: d(
|
|
7445
|
+
codeText: d(W),
|
|
7446
7446
|
codeTextData: $,
|
|
7447
7447
|
data: $,
|
|
7448
7448
|
definition: d(),
|
|
7449
7449
|
definitionDestinationString: x,
|
|
7450
|
-
definitionLabelString:
|
|
7451
|
-
definitionTitleString:
|
|
7450
|
+
definitionLabelString: X,
|
|
7451
|
+
definitionTitleString: F,
|
|
7452
7452
|
emphasis: d(),
|
|
7453
7453
|
hardBreakEscape: d(I),
|
|
7454
7454
|
hardBreakTrailing: d(I),
|
|
7455
|
-
htmlFlow: d(
|
|
7455
|
+
htmlFlow: d(L),
|
|
7456
7456
|
htmlFlowData: $,
|
|
7457
|
-
htmlText: d(
|
|
7457
|
+
htmlText: d(B),
|
|
7458
7458
|
htmlTextData: $,
|
|
7459
7459
|
image: d(z),
|
|
7460
7460
|
label: ne,
|
|
7461
7461
|
labelText: y,
|
|
7462
|
-
lineEnding:
|
|
7463
|
-
link: d(
|
|
7462
|
+
lineEnding: k,
|
|
7463
|
+
link: d(H),
|
|
7464
7464
|
listItem: d(),
|
|
7465
7465
|
listOrdered: d(),
|
|
7466
7466
|
listUnordered: d(),
|
|
@@ -7471,7 +7471,7 @@ function _m(e) {
|
|
|
7471
7471
|
resource: se,
|
|
7472
7472
|
setextHeading: d(te),
|
|
7473
7473
|
setextHeadingLineSequence: q,
|
|
7474
|
-
setextHeadingText:
|
|
7474
|
+
setextHeadingText: V,
|
|
7475
7475
|
strong: d(),
|
|
7476
7476
|
thematicBreak: d()
|
|
7477
7477
|
}
|
|
@@ -7479,7 +7479,7 @@ function _m(e) {
|
|
|
7479
7479
|
Ll(t, (e || {}).mdastExtensions || []);
|
|
7480
7480
|
const n = {};
|
|
7481
7481
|
return r;
|
|
7482
|
-
function r(
|
|
7482
|
+
function r(U) {
|
|
7483
7483
|
let K = {
|
|
7484
7484
|
type: "root",
|
|
7485
7485
|
children: []
|
|
@@ -7496,24 +7496,24 @@ function _m(e) {
|
|
|
7496
7496
|
getData: u
|
|
7497
7497
|
}, Ee = [];
|
|
7498
7498
|
let he = -1;
|
|
7499
|
-
for (; ++he <
|
|
7500
|
-
if (
|
|
7501
|
-
if (
|
|
7499
|
+
for (; ++he < U.length; )
|
|
7500
|
+
if (U[he][1].type === "listOrdered" || U[he][1].type === "listUnordered")
|
|
7501
|
+
if (U[he][0] === "enter")
|
|
7502
7502
|
Ee.push(he);
|
|
7503
7503
|
else {
|
|
7504
7504
|
const Qe = Ee.pop();
|
|
7505
|
-
he = a(
|
|
7505
|
+
he = a(U, Qe, he);
|
|
7506
7506
|
}
|
|
7507
|
-
for (he = -1; ++he <
|
|
7508
|
-
const Qe = t[
|
|
7509
|
-
kl.call(Qe,
|
|
7507
|
+
for (he = -1; ++he < U.length; ) {
|
|
7508
|
+
const Qe = t[U[he][0]];
|
|
7509
|
+
kl.call(Qe, U[he][1].type) && Qe[U[he][1].type].call(
|
|
7510
7510
|
Object.assign(
|
|
7511
7511
|
{
|
|
7512
|
-
sliceSerialize:
|
|
7512
|
+
sliceSerialize: U[he][2].sliceSerialize
|
|
7513
7513
|
},
|
|
7514
7514
|
ie
|
|
7515
7515
|
),
|
|
7516
|
-
|
|
7516
|
+
U[he][1]
|
|
7517
7517
|
);
|
|
7518
7518
|
}
|
|
7519
7519
|
if (ie.tokenStack.length > 0) {
|
|
@@ -7522,14 +7522,14 @@ function _m(e) {
|
|
|
7522
7522
|
}
|
|
7523
7523
|
for (K.position = {
|
|
7524
7524
|
start: Vt(
|
|
7525
|
-
|
|
7525
|
+
U.length > 0 ? U[0][1].start : {
|
|
7526
7526
|
line: 1,
|
|
7527
7527
|
column: 1,
|
|
7528
7528
|
offset: 0
|
|
7529
7529
|
}
|
|
7530
7530
|
),
|
|
7531
7531
|
end: Vt(
|
|
7532
|
-
|
|
7532
|
+
U.length > 0 ? U[U.length - 2][1].end : {
|
|
7533
7533
|
line: 1,
|
|
7534
7534
|
column: 1,
|
|
7535
7535
|
offset: 0
|
|
@@ -7539,24 +7539,24 @@ function _m(e) {
|
|
|
7539
7539
|
K = t.transforms[he](K) || K;
|
|
7540
7540
|
return K;
|
|
7541
7541
|
}
|
|
7542
|
-
function a(
|
|
7542
|
+
function a(U, K, ie) {
|
|
7543
7543
|
let Ee = K - 1, he = -1, Qe = !1, ut, Ve, Be, rt;
|
|
7544
7544
|
for (; ++Ee <= ie; ) {
|
|
7545
|
-
const He =
|
|
7545
|
+
const He = U[Ee];
|
|
7546
7546
|
if (He[1].type === "listUnordered" || He[1].type === "listOrdered" || He[1].type === "blockQuote" ? (He[0] === "enter" ? he++ : he--, rt = void 0) : He[1].type === "lineEndingBlank" ? He[0] === "enter" && (ut && !rt && !he && !Be && (Be = Ee), rt = void 0) : He[1].type === "linePrefix" || He[1].type === "listItemValue" || He[1].type === "listItemMarker" || He[1].type === "listItemPrefix" || He[1].type === "listItemPrefixWhitespace" || (rt = void 0), !he && He[0] === "enter" && He[1].type === "listItemPrefix" || he === -1 && He[0] === "exit" && (He[1].type === "listUnordered" || He[1].type === "listOrdered")) {
|
|
7547
7547
|
if (ut) {
|
|
7548
7548
|
let ot = Ee;
|
|
7549
7549
|
for (Ve = void 0; ot--; ) {
|
|
7550
|
-
const vt =
|
|
7550
|
+
const vt = U[ot];
|
|
7551
7551
|
if (vt[1].type === "lineEnding" || vt[1].type === "lineEndingBlank") {
|
|
7552
7552
|
if (vt[0] === "exit") continue;
|
|
7553
|
-
Ve && (
|
|
7553
|
+
Ve && (U[Ve][1].type = "lineEndingBlank", Qe = !0), vt[1].type = "lineEnding", Ve = ot;
|
|
7554
7554
|
} else if (!(vt[1].type === "linePrefix" || vt[1].type === "blockQuotePrefix" || vt[1].type === "blockQuotePrefixWhitespace" || vt[1].type === "blockQuoteMarker" || vt[1].type === "listItemIndent")) break;
|
|
7555
7555
|
}
|
|
7556
7556
|
Be && (!Ve || Be < Ve) && (ut._spread = !0), ut.end = Object.assign(
|
|
7557
7557
|
{},
|
|
7558
|
-
Ve ?
|
|
7559
|
-
),
|
|
7558
|
+
Ve ? U[Ve][1].start : He[1].end
|
|
7559
|
+
), U.splice(Ve || Ee, 0, ["exit", ut, He[2]]), Ee++, ie++;
|
|
7560
7560
|
}
|
|
7561
7561
|
He[1].type === "listItemPrefix" && (ut = {
|
|
7562
7562
|
type: "listItem",
|
|
@@ -7564,21 +7564,21 @@ function _m(e) {
|
|
|
7564
7564
|
start: Object.assign({}, He[1].start),
|
|
7565
7565
|
// @ts-expect-error: we’ll add `end` in a second.
|
|
7566
7566
|
end: void 0
|
|
7567
|
-
},
|
|
7567
|
+
}, U.splice(Ee, 0, ["enter", ut, He[2]]), Ee++, ie++, Be = void 0, rt = !0);
|
|
7568
7568
|
}
|
|
7569
7569
|
}
|
|
7570
|
-
return
|
|
7570
|
+
return U[K][1]._spread = Qe, ie;
|
|
7571
7571
|
}
|
|
7572
|
-
function i(
|
|
7573
|
-
n[
|
|
7572
|
+
function i(U, K) {
|
|
7573
|
+
n[U] = K;
|
|
7574
7574
|
}
|
|
7575
|
-
function u(
|
|
7576
|
-
return n[
|
|
7575
|
+
function u(U) {
|
|
7576
|
+
return n[U];
|
|
7577
7577
|
}
|
|
7578
|
-
function s(
|
|
7578
|
+
function s(U, K) {
|
|
7579
7579
|
return ie;
|
|
7580
7580
|
function ie(Ee) {
|
|
7581
|
-
c.call(this,
|
|
7581
|
+
c.call(this, U(Ee), Ee), K && K.call(this, Ee);
|
|
7582
7582
|
}
|
|
7583
7583
|
}
|
|
7584
7584
|
function l() {
|
|
@@ -7587,28 +7587,28 @@ function _m(e) {
|
|
|
7587
7587
|
children: []
|
|
7588
7588
|
});
|
|
7589
7589
|
}
|
|
7590
|
-
function c(
|
|
7591
|
-
return this.stack[this.stack.length - 1].children.push(
|
|
7590
|
+
function c(U, K, ie) {
|
|
7591
|
+
return this.stack[this.stack.length - 1].children.push(U), this.stack.push(U), this.tokenStack.push([K, ie]), U.position = {
|
|
7592
7592
|
start: Vt(K.start)
|
|
7593
|
-
},
|
|
7593
|
+
}, U;
|
|
7594
7594
|
}
|
|
7595
|
-
function d(
|
|
7595
|
+
function d(U) {
|
|
7596
7596
|
return K;
|
|
7597
7597
|
function K(ie) {
|
|
7598
|
-
|
|
7598
|
+
U && U.call(this, ie), f.call(this, ie);
|
|
7599
7599
|
}
|
|
7600
7600
|
}
|
|
7601
|
-
function f(
|
|
7601
|
+
function f(U, K) {
|
|
7602
7602
|
const ie = this.stack.pop(), Ee = this.tokenStack.pop();
|
|
7603
7603
|
if (Ee)
|
|
7604
|
-
Ee[0].type !==
|
|
7604
|
+
Ee[0].type !== U.type && (K ? K.call(this, U, Ee[0]) : (Ee[1] || To).call(this, U, Ee[0]));
|
|
7605
7605
|
else throw new Error(
|
|
7606
|
-
"Cannot close `" +
|
|
7607
|
-
start:
|
|
7608
|
-
end:
|
|
7606
|
+
"Cannot close `" + U.type + "` (" + tr({
|
|
7607
|
+
start: U.start,
|
|
7608
|
+
end: U.end
|
|
7609
7609
|
}) + "): it’s not open"
|
|
7610
7610
|
);
|
|
7611
|
-
return ie.position.end = Vt(
|
|
7611
|
+
return ie.position.end = Vt(U.end), ie;
|
|
7612
7612
|
}
|
|
7613
7613
|
function p() {
|
|
7614
7614
|
return fp(this.stack.pop());
|
|
@@ -7616,134 +7616,134 @@ function _m(e) {
|
|
|
7616
7616
|
function h() {
|
|
7617
7617
|
i("expectingFirstListItemValue", !0);
|
|
7618
7618
|
}
|
|
7619
|
-
function b(
|
|
7619
|
+
function b(U) {
|
|
7620
7620
|
if (u("expectingFirstListItemValue")) {
|
|
7621
7621
|
const K = this.stack[this.stack.length - 2];
|
|
7622
|
-
K.start = Number.parseInt(this.sliceSerialize(
|
|
7622
|
+
K.start = Number.parseInt(this.sliceSerialize(U), 10), i("expectingFirstListItemValue");
|
|
7623
7623
|
}
|
|
7624
7624
|
}
|
|
7625
7625
|
function m() {
|
|
7626
|
-
const
|
|
7627
|
-
K.lang =
|
|
7626
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7627
|
+
K.lang = U;
|
|
7628
7628
|
}
|
|
7629
7629
|
function T() {
|
|
7630
|
-
const
|
|
7631
|
-
K.meta =
|
|
7630
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7631
|
+
K.meta = U;
|
|
7632
7632
|
}
|
|
7633
7633
|
function g() {
|
|
7634
7634
|
u("flowCodeInside") || (this.buffer(), i("flowCodeInside", !0));
|
|
7635
7635
|
}
|
|
7636
7636
|
function D() {
|
|
7637
|
-
const
|
|
7638
|
-
K.value =
|
|
7637
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7638
|
+
K.value = U.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g, ""), i("flowCodeInside");
|
|
7639
7639
|
}
|
|
7640
7640
|
function P() {
|
|
7641
|
-
const
|
|
7642
|
-
K.value =
|
|
7641
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7642
|
+
K.value = U.replace(/(\r?\n|\r)$/g, "");
|
|
7643
7643
|
}
|
|
7644
|
-
function
|
|
7644
|
+
function X(U) {
|
|
7645
7645
|
const K = this.resume(), ie = this.stack[this.stack.length - 1];
|
|
7646
7646
|
ie.label = K, ie.identifier = Cn(
|
|
7647
|
-
this.sliceSerialize(
|
|
7647
|
+
this.sliceSerialize(U)
|
|
7648
7648
|
).toLowerCase();
|
|
7649
7649
|
}
|
|
7650
|
-
function
|
|
7651
|
-
const
|
|
7652
|
-
K.title =
|
|
7650
|
+
function F() {
|
|
7651
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7652
|
+
K.title = U;
|
|
7653
7653
|
}
|
|
7654
7654
|
function x() {
|
|
7655
|
-
const
|
|
7656
|
-
K.url =
|
|
7655
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7656
|
+
K.url = U;
|
|
7657
7657
|
}
|
|
7658
|
-
function
|
|
7658
|
+
function w(U) {
|
|
7659
7659
|
const K = this.stack[this.stack.length - 1];
|
|
7660
7660
|
if (!K.depth) {
|
|
7661
|
-
const ie = this.sliceSerialize(
|
|
7661
|
+
const ie = this.sliceSerialize(U).length;
|
|
7662
7662
|
K.depth = ie;
|
|
7663
7663
|
}
|
|
7664
7664
|
}
|
|
7665
|
-
function
|
|
7665
|
+
function V() {
|
|
7666
7666
|
i("setextHeadingSlurpLineEnding", !0);
|
|
7667
7667
|
}
|
|
7668
|
-
function q(
|
|
7668
|
+
function q(U) {
|
|
7669
7669
|
const K = this.stack[this.stack.length - 1];
|
|
7670
|
-
K.depth = this.sliceSerialize(
|
|
7670
|
+
K.depth = this.sliceSerialize(U).charCodeAt(0) === 61 ? 1 : 2;
|
|
7671
7671
|
}
|
|
7672
7672
|
function te() {
|
|
7673
7673
|
i("setextHeadingSlurpLineEnding");
|
|
7674
7674
|
}
|
|
7675
|
-
function Y(
|
|
7675
|
+
function Y(U) {
|
|
7676
7676
|
const K = this.stack[this.stack.length - 1];
|
|
7677
7677
|
let ie = K.children[K.children.length - 1];
|
|
7678
7678
|
(!ie || ie.type !== "text") && (ie = Fe(), ie.position = {
|
|
7679
|
-
start: Vt(
|
|
7679
|
+
start: Vt(U.start)
|
|
7680
7680
|
}, K.children.push(ie)), this.stack.push(ie);
|
|
7681
7681
|
}
|
|
7682
|
-
function $(
|
|
7682
|
+
function $(U) {
|
|
7683
7683
|
const K = this.stack.pop();
|
|
7684
|
-
K.value += this.sliceSerialize(
|
|
7684
|
+
K.value += this.sliceSerialize(U), K.position.end = Vt(U.end);
|
|
7685
7685
|
}
|
|
7686
|
-
function
|
|
7686
|
+
function k(U) {
|
|
7687
7687
|
const K = this.stack[this.stack.length - 1];
|
|
7688
7688
|
if (u("atHardBreak")) {
|
|
7689
7689
|
const ie = K.children[K.children.length - 1];
|
|
7690
|
-
ie.position.end = Vt(
|
|
7690
|
+
ie.position.end = Vt(U.end), i("atHardBreak");
|
|
7691
7691
|
return;
|
|
7692
7692
|
}
|
|
7693
|
-
!u("setextHeadingSlurpLineEnding") && t.canContainEols.includes(K.type) && (Y.call(this,
|
|
7693
|
+
!u("setextHeadingSlurpLineEnding") && t.canContainEols.includes(K.type) && (Y.call(this, U), $.call(this, U));
|
|
7694
7694
|
}
|
|
7695
7695
|
function I() {
|
|
7696
7696
|
i("atHardBreak", !0);
|
|
7697
7697
|
}
|
|
7698
|
-
function
|
|
7699
|
-
const
|
|
7700
|
-
K.value =
|
|
7698
|
+
function L() {
|
|
7699
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7700
|
+
K.value = U;
|
|
7701
7701
|
}
|
|
7702
|
-
function
|
|
7703
|
-
const
|
|
7704
|
-
K.value =
|
|
7702
|
+
function B() {
|
|
7703
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7704
|
+
K.value = U;
|
|
7705
7705
|
}
|
|
7706
|
-
function
|
|
7707
|
-
const
|
|
7708
|
-
K.value =
|
|
7706
|
+
function W() {
|
|
7707
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7708
|
+
K.value = U;
|
|
7709
7709
|
}
|
|
7710
|
-
function
|
|
7711
|
-
const
|
|
7710
|
+
function H() {
|
|
7711
|
+
const U = this.stack[this.stack.length - 1];
|
|
7712
7712
|
if (u("inReference")) {
|
|
7713
7713
|
const K = u("referenceType") || "shortcut";
|
|
7714
|
-
|
|
7714
|
+
U.type += "Reference", U.referenceType = K, delete U.url, delete U.title;
|
|
7715
7715
|
} else
|
|
7716
|
-
delete
|
|
7716
|
+
delete U.identifier, delete U.label;
|
|
7717
7717
|
i("referenceType");
|
|
7718
7718
|
}
|
|
7719
7719
|
function z() {
|
|
7720
|
-
const
|
|
7720
|
+
const U = this.stack[this.stack.length - 1];
|
|
7721
7721
|
if (u("inReference")) {
|
|
7722
7722
|
const K = u("referenceType") || "shortcut";
|
|
7723
|
-
|
|
7723
|
+
U.type += "Reference", U.referenceType = K, delete U.url, delete U.title;
|
|
7724
7724
|
} else
|
|
7725
|
-
delete
|
|
7725
|
+
delete U.identifier, delete U.label;
|
|
7726
7726
|
i("referenceType");
|
|
7727
7727
|
}
|
|
7728
|
-
function y(
|
|
7729
|
-
const K = this.sliceSerialize(
|
|
7728
|
+
function y(U) {
|
|
7729
|
+
const K = this.sliceSerialize(U), ie = this.stack[this.stack.length - 2];
|
|
7730
7730
|
ie.label = Em(K), ie.identifier = Cn(K).toLowerCase();
|
|
7731
7731
|
}
|
|
7732
7732
|
function ne() {
|
|
7733
|
-
const
|
|
7733
|
+
const U = this.stack[this.stack.length - 1], K = this.resume(), ie = this.stack[this.stack.length - 1];
|
|
7734
7734
|
if (i("inReference", !0), ie.type === "link") {
|
|
7735
|
-
const Ee =
|
|
7735
|
+
const Ee = U.children;
|
|
7736
7736
|
ie.children = Ee;
|
|
7737
7737
|
} else
|
|
7738
7738
|
ie.alt = K;
|
|
7739
7739
|
}
|
|
7740
7740
|
function ae() {
|
|
7741
|
-
const
|
|
7742
|
-
K.url =
|
|
7741
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7742
|
+
K.url = U;
|
|
7743
7743
|
}
|
|
7744
7744
|
function v() {
|
|
7745
|
-
const
|
|
7746
|
-
K.title =
|
|
7745
|
+
const U = this.resume(), K = this.stack[this.stack.length - 1];
|
|
7746
|
+
K.title = U;
|
|
7747
7747
|
}
|
|
7748
7748
|
function se() {
|
|
7749
7749
|
i("inReference");
|
|
@@ -7751,34 +7751,34 @@ function _m(e) {
|
|
|
7751
7751
|
function _e() {
|
|
7752
7752
|
i("referenceType", "collapsed");
|
|
7753
7753
|
}
|
|
7754
|
-
function pe(
|
|
7754
|
+
function pe(U) {
|
|
7755
7755
|
const K = this.resume(), ie = this.stack[this.stack.length - 1];
|
|
7756
7756
|
ie.label = K, ie.identifier = Cn(
|
|
7757
|
-
this.sliceSerialize(
|
|
7757
|
+
this.sliceSerialize(U)
|
|
7758
7758
|
).toLowerCase(), i("referenceType", "full");
|
|
7759
7759
|
}
|
|
7760
|
-
function Se(
|
|
7761
|
-
i("characterReferenceType",
|
|
7760
|
+
function Se(U) {
|
|
7761
|
+
i("characterReferenceType", U.type);
|
|
7762
7762
|
}
|
|
7763
|
-
function Oe(
|
|
7764
|
-
const K = this.sliceSerialize(
|
|
7763
|
+
function Oe(U) {
|
|
7764
|
+
const K = this.sliceSerialize(U), ie = u("characterReferenceType");
|
|
7765
7765
|
let Ee;
|
|
7766
7766
|
ie ? (Ee = Nl(
|
|
7767
7767
|
K,
|
|
7768
7768
|
ie === "characterReferenceMarkerNumeric" ? 10 : 16
|
|
7769
7769
|
), i("characterReferenceType")) : Ee = wi(K);
|
|
7770
7770
|
const he = this.stack.pop();
|
|
7771
|
-
he.value += Ee, he.position.end = Vt(
|
|
7771
|
+
he.value += Ee, he.position.end = Vt(U.end);
|
|
7772
7772
|
}
|
|
7773
|
-
function ze(
|
|
7774
|
-
$.call(this,
|
|
7773
|
+
function ze(U) {
|
|
7774
|
+
$.call(this, U);
|
|
7775
7775
|
const K = this.stack[this.stack.length - 1];
|
|
7776
|
-
K.url = this.sliceSerialize(
|
|
7776
|
+
K.url = this.sliceSerialize(U);
|
|
7777
7777
|
}
|
|
7778
|
-
function Ie(
|
|
7779
|
-
$.call(this,
|
|
7778
|
+
function Ie(U) {
|
|
7779
|
+
$.call(this, U);
|
|
7780
7780
|
const K = this.stack[this.stack.length - 1];
|
|
7781
|
-
K.url = "mailto:" + this.sliceSerialize(
|
|
7781
|
+
K.url = "mailto:" + this.sliceSerialize(U);
|
|
7782
7782
|
}
|
|
7783
7783
|
function nt() {
|
|
7784
7784
|
return {
|
|
@@ -7849,19 +7849,19 @@ function _m(e) {
|
|
|
7849
7849
|
children: []
|
|
7850
7850
|
};
|
|
7851
7851
|
}
|
|
7852
|
-
function be(
|
|
7852
|
+
function be(U) {
|
|
7853
7853
|
return {
|
|
7854
7854
|
type: "list",
|
|
7855
|
-
ordered:
|
|
7855
|
+
ordered: U.type === "listOrdered",
|
|
7856
7856
|
start: null,
|
|
7857
|
-
spread:
|
|
7857
|
+
spread: U._spread,
|
|
7858
7858
|
children: []
|
|
7859
7859
|
};
|
|
7860
7860
|
}
|
|
7861
|
-
function Me(
|
|
7861
|
+
function Me(U) {
|
|
7862
7862
|
return {
|
|
7863
7863
|
type: "listItem",
|
|
7864
|
-
spread:
|
|
7864
|
+
spread: U._spread,
|
|
7865
7865
|
checked: null,
|
|
7866
7866
|
children: []
|
|
7867
7867
|
};
|
|
@@ -10010,78 +10010,78 @@ function L2() {
|
|
|
10010
10010
|
if (!m) return [];
|
|
10011
10011
|
T = T || {};
|
|
10012
10012
|
var g = 1, D = 1;
|
|
10013
|
-
function P(
|
|
10014
|
-
var I =
|
|
10013
|
+
function P(k) {
|
|
10014
|
+
var I = k.match(t);
|
|
10015
10015
|
I && (g += I.length);
|
|
10016
|
-
var
|
|
10017
|
-
D = ~
|
|
10016
|
+
var L = k.lastIndexOf(l);
|
|
10017
|
+
D = ~L ? k.length - L : D + k.length;
|
|
10018
10018
|
}
|
|
10019
|
-
function
|
|
10020
|
-
var
|
|
10019
|
+
function X() {
|
|
10020
|
+
var k = { line: g, column: D };
|
|
10021
10021
|
return function(I) {
|
|
10022
|
-
return I.position = new
|
|
10022
|
+
return I.position = new F(k), V(), I;
|
|
10023
10023
|
};
|
|
10024
10024
|
}
|
|
10025
|
-
function
|
|
10026
|
-
this.start =
|
|
10025
|
+
function F(k) {
|
|
10026
|
+
this.start = k, this.end = { line: g, column: D }, this.source = T.source;
|
|
10027
10027
|
}
|
|
10028
|
-
|
|
10029
|
-
function x(
|
|
10028
|
+
F.prototype.content = m;
|
|
10029
|
+
function x(k) {
|
|
10030
10030
|
var I = new Error(
|
|
10031
|
-
T.source + ":" + g + ":" + D + ": " +
|
|
10031
|
+
T.source + ":" + g + ":" + D + ": " + k
|
|
10032
10032
|
);
|
|
10033
|
-
if (I.reason =
|
|
10033
|
+
if (I.reason = k, I.filename = T.source, I.line = g, I.column = D, I.source = m, !T.silent) throw I;
|
|
10034
10034
|
}
|
|
10035
|
-
function k
|
|
10036
|
-
var I =
|
|
10035
|
+
function w(k) {
|
|
10036
|
+
var I = k.exec(m);
|
|
10037
10037
|
if (I) {
|
|
10038
|
-
var
|
|
10039
|
-
return P(
|
|
10038
|
+
var L = I[0];
|
|
10039
|
+
return P(L), m = m.slice(L.length), I;
|
|
10040
10040
|
}
|
|
10041
10041
|
}
|
|
10042
|
-
function
|
|
10043
|
-
|
|
10042
|
+
function V() {
|
|
10043
|
+
w(n);
|
|
10044
10044
|
}
|
|
10045
|
-
function q(
|
|
10045
|
+
function q(k) {
|
|
10046
10046
|
var I;
|
|
10047
|
-
for (
|
|
10048
|
-
I !== !1 &&
|
|
10049
|
-
return
|
|
10047
|
+
for (k = k || []; I = te(); )
|
|
10048
|
+
I !== !1 && k.push(I);
|
|
10049
|
+
return k;
|
|
10050
10050
|
}
|
|
10051
10051
|
function te() {
|
|
10052
|
-
var
|
|
10052
|
+
var k = X();
|
|
10053
10053
|
if (!(c != m.charAt(0) || d != m.charAt(1))) {
|
|
10054
10054
|
for (var I = 2; f != m.charAt(I) && (d != m.charAt(I) || c != m.charAt(I + 1)); )
|
|
10055
10055
|
++I;
|
|
10056
10056
|
if (I += 2, f === m.charAt(I - 1))
|
|
10057
10057
|
return x("End of comment missing");
|
|
10058
|
-
var
|
|
10059
|
-
return D += 2, P(
|
|
10058
|
+
var L = m.slice(2, I - 2);
|
|
10059
|
+
return D += 2, P(L), m = m.slice(I), D += 2, k({
|
|
10060
10060
|
type: p,
|
|
10061
|
-
comment:
|
|
10061
|
+
comment: L
|
|
10062
10062
|
});
|
|
10063
10063
|
}
|
|
10064
10064
|
}
|
|
10065
10065
|
function Y() {
|
|
10066
|
-
var
|
|
10066
|
+
var k = X(), I = w(r);
|
|
10067
10067
|
if (I) {
|
|
10068
|
-
if (te(), !
|
|
10069
|
-
var
|
|
10068
|
+
if (te(), !w(a)) return x("property missing ':'");
|
|
10069
|
+
var L = w(i), B = k({
|
|
10070
10070
|
type: h,
|
|
10071
10071
|
property: b(I[0].replace(e, f)),
|
|
10072
|
-
value:
|
|
10072
|
+
value: L ? b(L[0].replace(e, f)) : f
|
|
10073
10073
|
});
|
|
10074
|
-
return
|
|
10074
|
+
return w(u), B;
|
|
10075
10075
|
}
|
|
10076
10076
|
}
|
|
10077
10077
|
function $() {
|
|
10078
|
-
var
|
|
10079
|
-
q(
|
|
10078
|
+
var k = [];
|
|
10079
|
+
q(k);
|
|
10080
10080
|
for (var I; I = Y(); )
|
|
10081
|
-
I !== !1 && (
|
|
10082
|
-
return
|
|
10081
|
+
I !== !1 && (k.push(I), q(k));
|
|
10082
|
+
return k;
|
|
10083
10083
|
}
|
|
10084
|
-
return
|
|
10084
|
+
return V(), $();
|
|
10085
10085
|
};
|
|
10086
10086
|
function b(m) {
|
|
10087
10087
|
return m ? m.replace(s, f) : f;
|
|
@@ -13303,10 +13303,10 @@ function Ac(e) {
|
|
|
13303
13303
|
function Sc(e) {
|
|
13304
13304
|
return e >= 64976 && e <= 65007 || Pg.has(e);
|
|
13305
13305
|
}
|
|
13306
|
-
var
|
|
13306
|
+
var j;
|
|
13307
13307
|
(function(e) {
|
|
13308
13308
|
e.controlCharacterInInputStream = "control-character-in-input-stream", e.noncharacterInInputStream = "noncharacter-in-input-stream", e.surrogateInInputStream = "surrogate-in-input-stream", e.nonVoidHtmlElementStartTagWithTrailingSolidus = "non-void-html-element-start-tag-with-trailing-solidus", e.endTagWithAttributes = "end-tag-with-attributes", e.endTagWithTrailingSolidus = "end-tag-with-trailing-solidus", e.unexpectedSolidusInTag = "unexpected-solidus-in-tag", e.unexpectedNullCharacter = "unexpected-null-character", e.unexpectedQuestionMarkInsteadOfTagName = "unexpected-question-mark-instead-of-tag-name", e.invalidFirstCharacterOfTagName = "invalid-first-character-of-tag-name", e.unexpectedEqualsSignBeforeAttributeName = "unexpected-equals-sign-before-attribute-name", e.missingEndTagName = "missing-end-tag-name", e.unexpectedCharacterInAttributeName = "unexpected-character-in-attribute-name", e.unknownNamedCharacterReference = "unknown-named-character-reference", e.missingSemicolonAfterCharacterReference = "missing-semicolon-after-character-reference", e.unexpectedCharacterAfterDoctypeSystemIdentifier = "unexpected-character-after-doctype-system-identifier", e.unexpectedCharacterInUnquotedAttributeValue = "unexpected-character-in-unquoted-attribute-value", e.eofBeforeTagName = "eof-before-tag-name", e.eofInTag = "eof-in-tag", e.missingAttributeValue = "missing-attribute-value", e.missingWhitespaceBetweenAttributes = "missing-whitespace-between-attributes", e.missingWhitespaceAfterDoctypePublicKeyword = "missing-whitespace-after-doctype-public-keyword", e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers = "missing-whitespace-between-doctype-public-and-system-identifiers", e.missingWhitespaceAfterDoctypeSystemKeyword = "missing-whitespace-after-doctype-system-keyword", e.missingQuoteBeforeDoctypePublicIdentifier = "missing-quote-before-doctype-public-identifier", e.missingQuoteBeforeDoctypeSystemIdentifier = "missing-quote-before-doctype-system-identifier", e.missingDoctypePublicIdentifier = "missing-doctype-public-identifier", e.missingDoctypeSystemIdentifier = "missing-doctype-system-identifier", e.abruptDoctypePublicIdentifier = "abrupt-doctype-public-identifier", e.abruptDoctypeSystemIdentifier = "abrupt-doctype-system-identifier", e.cdataInHtmlContent = "cdata-in-html-content", e.incorrectlyOpenedComment = "incorrectly-opened-comment", e.eofInScriptHtmlCommentLikeText = "eof-in-script-html-comment-like-text", e.eofInDoctype = "eof-in-doctype", e.nestedComment = "nested-comment", e.abruptClosingOfEmptyComment = "abrupt-closing-of-empty-comment", e.eofInComment = "eof-in-comment", e.incorrectlyClosedComment = "incorrectly-closed-comment", e.eofInCdata = "eof-in-cdata", e.absenceOfDigitsInNumericCharacterReference = "absence-of-digits-in-numeric-character-reference", e.nullCharacterReference = "null-character-reference", e.surrogateCharacterReference = "surrogate-character-reference", e.characterReferenceOutsideUnicodeRange = "character-reference-outside-unicode-range", e.controlCharacterReference = "control-character-reference", e.noncharacterCharacterReference = "noncharacter-character-reference", e.missingWhitespaceBeforeDoctypeName = "missing-whitespace-before-doctype-name", e.missingDoctypeName = "missing-doctype-name", e.invalidCharacterSequenceAfterDoctypeName = "invalid-character-sequence-after-doctype-name", e.duplicateAttribute = "duplicate-attribute", e.nonConformingDoctype = "non-conforming-doctype", e.missingDoctype = "missing-doctype", e.misplacedDoctype = "misplaced-doctype", e.endTagWithoutMatchingOpenElement = "end-tag-without-matching-open-element", e.closingOfElementWithOpenChildElements = "closing-of-element-with-open-child-elements", e.disallowedContentInNoscriptInHead = "disallowed-content-in-noscript-in-head", e.openElementsLeftAfterEof = "open-elements-left-after-eof", e.abandonedHeadElementChild = "abandoned-head-element-child", e.misplacedStartTagForHeadElement = "misplaced-start-tag-for-head-element", e.nestedNoscriptInHead = "nested-noscript-in-head", e.eofInElementThatCanContainOnlyText = "eof-in-element-that-can-contain-only-text";
|
|
13309
|
-
})(
|
|
13309
|
+
})(j || (j = {}));
|
|
13310
13310
|
const Bg = 65536;
|
|
13311
13311
|
class Hg {
|
|
13312
13312
|
constructor(t) {
|
|
@@ -13344,7 +13344,7 @@ class Hg {
|
|
|
13344
13344
|
return this.pos++, this._addGap(), Fg(t, n);
|
|
13345
13345
|
} else if (!this.lastChunkWritten)
|
|
13346
13346
|
return this.endOfChunkHit = !0, E.EOF;
|
|
13347
|
-
return this._err(
|
|
13347
|
+
return this._err(j.surrogateInInputStream), t;
|
|
13348
13348
|
}
|
|
13349
13349
|
willDropParsedChunk() {
|
|
13350
13350
|
return this.pos > this.bufferWaterline;
|
|
@@ -13382,7 +13382,7 @@ class Hg {
|
|
|
13382
13382
|
return t === E.CARRIAGE_RETURN ? (this.isEol = !0, this.skipNextNewLine = !0, E.LINE_FEED) : t === E.LINE_FEED && (this.isEol = !0, this.skipNextNewLine) ? (this.line--, this.skipNextNewLine = !1, this._addGap(), this.advance()) : (this.skipNextNewLine = !1, Cc(t) && (t = this._processSurrogate(t)), this.handler.onParseError === null || t > 31 && t < 127 || t === E.LINE_FEED || t === E.CARRIAGE_RETURN || t > 159 && t < 64976 || this._checkForProblematicCharacters(t), t);
|
|
13383
13383
|
}
|
|
13384
13384
|
_checkForProblematicCharacters(t) {
|
|
13385
|
-
Ac(t) ? this._err(
|
|
13385
|
+
Ac(t) ? this._err(j.controlCharacterInInputStream) : Sc(t) && this._err(j.noncharacterInInputStream);
|
|
13386
13386
|
}
|
|
13387
13387
|
retreat(t) {
|
|
13388
13388
|
for (this.pos -= t; this.pos < this.lastGapPos; )
|
|
@@ -13675,10 +13675,10 @@ function Gg(e, t, n, r) {
|
|
|
13675
13675
|
}
|
|
13676
13676
|
return -1;
|
|
13677
13677
|
}
|
|
13678
|
-
var
|
|
13678
|
+
var G;
|
|
13679
13679
|
(function(e) {
|
|
13680
13680
|
e.HTML = "http://www.w3.org/1999/xhtml", e.MATHML = "http://www.w3.org/1998/Math/MathML", e.SVG = "http://www.w3.org/2000/svg", e.XLINK = "http://www.w3.org/1999/xlink", e.XML = "http://www.w3.org/XML/1998/namespace", e.XMLNS = "http://www.w3.org/2000/xmlns/";
|
|
13681
|
-
})(
|
|
13681
|
+
})(G || (G = {}));
|
|
13682
13682
|
var on;
|
|
13683
13683
|
(function(e) {
|
|
13684
13684
|
e.TYPE = "type", e.ACTION = "action", e.ENCODING = "encoding", e.PROMPT = "prompt", e.NAME = "name", e.COLOR = "color", e.FACE = "face", e.SIZE = "size";
|
|
@@ -13825,7 +13825,7 @@ function Dn(e) {
|
|
|
13825
13825
|
return (t = Xg.get(e)) !== null && t !== void 0 ? t : o.UNKNOWN;
|
|
13826
13826
|
}
|
|
13827
13827
|
const Q = o, Kg = {
|
|
13828
|
-
[
|
|
13828
|
+
[G.HTML]: /* @__PURE__ */ new Set([
|
|
13829
13829
|
Q.ADDRESS,
|
|
13830
13830
|
Q.APPLET,
|
|
13831
13831
|
Q.AREA,
|
|
@@ -13908,11 +13908,11 @@ const Q = o, Kg = {
|
|
|
13908
13908
|
Q.WBR,
|
|
13909
13909
|
Q.XMP
|
|
13910
13910
|
]),
|
|
13911
|
-
[
|
|
13912
|
-
[
|
|
13913
|
-
[
|
|
13914
|
-
[
|
|
13915
|
-
[
|
|
13911
|
+
[G.MATHML]: /* @__PURE__ */ new Set([Q.MI, Q.MO, Q.MN, Q.MS, Q.MTEXT, Q.ANNOTATION_XML]),
|
|
13912
|
+
[G.SVG]: /* @__PURE__ */ new Set([Q.TITLE, Q.FOREIGN_OBJECT, Q.DESC]),
|
|
13913
|
+
[G.XLINK]: /* @__PURE__ */ new Set(),
|
|
13914
|
+
[G.XML]: /* @__PURE__ */ new Set(),
|
|
13915
|
+
[G.XMLNS]: /* @__PURE__ */ new Set()
|
|
13916
13916
|
}, yi = /* @__PURE__ */ new Set([Q.H1, Q.H2, Q.H3, Q.H4, Q.H5, Q.H6]);
|
|
13917
13917
|
R.STYLE, R.SCRIPT, R.XMP, R.IFRAME, R.NOEMBED, R.NOFRAMES, R.PLAINTEXT;
|
|
13918
13918
|
var C;
|
|
@@ -13952,7 +13952,7 @@ function Qo(e) {
|
|
|
13952
13952
|
return vc(e) || e === E.SOLIDUS || e === E.GREATER_THAN_SIGN;
|
|
13953
13953
|
}
|
|
13954
13954
|
function Jg(e) {
|
|
13955
|
-
return e === E.NULL ?
|
|
13955
|
+
return e === E.NULL ? j.nullCharacterReference : e > 1114111 ? j.characterReferenceOutsideUnicodeRange : Cc(e) ? j.surrogateCharacterReference : Sc(e) ? j.noncharacterCharacterReference : Ac(e) || e === E.CARRIAGE_RETURN ? j.controlCharacterReference : null;
|
|
13956
13956
|
}
|
|
13957
13957
|
class eb {
|
|
13958
13958
|
constructor(t, n) {
|
|
@@ -13960,10 +13960,10 @@ class eb {
|
|
|
13960
13960
|
this.preprocessor.pos = this.entityStartPos + a - 1, this._flushCodePointConsumedAsCharacterReference(r);
|
|
13961
13961
|
}, n.onParseError ? {
|
|
13962
13962
|
missingSemicolonAfterCharacterReference: () => {
|
|
13963
|
-
this._err(
|
|
13963
|
+
this._err(j.missingSemicolonAfterCharacterReference, 1);
|
|
13964
13964
|
},
|
|
13965
13965
|
absenceOfDigitsInNumericCharacterReference: (r) => {
|
|
13966
|
-
this._err(
|
|
13966
|
+
this._err(j.absenceOfDigitsInNumericCharacterReference, this.entityStartPos - this.preprocessor.pos + r);
|
|
13967
13967
|
},
|
|
13968
13968
|
validateNumericCharacterReference: (r) => {
|
|
13969
13969
|
const a = Jg(r);
|
|
@@ -14091,7 +14091,7 @@ class eb {
|
|
|
14091
14091
|
a[this.currentAttr.name] = this.currentLocation, this._leaveAttrValue();
|
|
14092
14092
|
}
|
|
14093
14093
|
} else
|
|
14094
|
-
this._err(
|
|
14094
|
+
this._err(j.duplicateAttribute);
|
|
14095
14095
|
}
|
|
14096
14096
|
_leaveAttrValue() {
|
|
14097
14097
|
this.currentLocation && (this.currentLocation.endLine = this.preprocessor.line, this.currentLocation.endCol = this.preprocessor.col, this.currentLocation.endOffset = this.preprocessor.offset);
|
|
@@ -14102,7 +14102,7 @@ class eb {
|
|
|
14102
14102
|
}
|
|
14103
14103
|
emitCurrentTagToken() {
|
|
14104
14104
|
const t = this.currentToken;
|
|
14105
|
-
this.prepareToken(t), t.tagID = Dn(t.tagName), t.type === me.START_TAG ? (this.lastStartTagName = t.tagName, this.handler.onStartTag(t)) : (t.attrs.length > 0 && this._err(
|
|
14105
|
+
this.prepareToken(t), t.tagID = Dn(t.tagName), t.type === me.START_TAG ? (this.lastStartTagName = t.tagName, this.handler.onStartTag(t)) : (t.attrs.length > 0 && this._err(j.endTagWithAttributes), t.selfClosing && this._err(j.endTagWithTrailingSolidus), this.handler.onEndTag(t)), this.preprocessor.dropParsedChunk();
|
|
14106
14106
|
}
|
|
14107
14107
|
emitCurrentComment(t) {
|
|
14108
14108
|
this.prepareToken(t), this.handler.onComment(t), this.preprocessor.dropParsedChunk();
|
|
@@ -14483,7 +14483,7 @@ class eb {
|
|
|
14483
14483
|
break;
|
|
14484
14484
|
}
|
|
14485
14485
|
case E.NULL: {
|
|
14486
|
-
this._err(
|
|
14486
|
+
this._err(j.unexpectedNullCharacter), this._emitCodePoint(t);
|
|
14487
14487
|
break;
|
|
14488
14488
|
}
|
|
14489
14489
|
case E.EOF: {
|
|
@@ -14507,7 +14507,7 @@ class eb {
|
|
|
14507
14507
|
break;
|
|
14508
14508
|
}
|
|
14509
14509
|
case E.NULL: {
|
|
14510
|
-
this._err(
|
|
14510
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14511
14511
|
break;
|
|
14512
14512
|
}
|
|
14513
14513
|
case E.EOF: {
|
|
@@ -14527,7 +14527,7 @@ class eb {
|
|
|
14527
14527
|
break;
|
|
14528
14528
|
}
|
|
14529
14529
|
case E.NULL: {
|
|
14530
|
-
this._err(
|
|
14530
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14531
14531
|
break;
|
|
14532
14532
|
}
|
|
14533
14533
|
case E.EOF: {
|
|
@@ -14547,7 +14547,7 @@ class eb {
|
|
|
14547
14547
|
break;
|
|
14548
14548
|
}
|
|
14549
14549
|
case E.NULL: {
|
|
14550
|
-
this._err(
|
|
14550
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14551
14551
|
break;
|
|
14552
14552
|
}
|
|
14553
14553
|
case E.EOF: {
|
|
@@ -14563,7 +14563,7 @@ class eb {
|
|
|
14563
14563
|
_statePlaintext(t) {
|
|
14564
14564
|
switch (t) {
|
|
14565
14565
|
case E.NULL: {
|
|
14566
|
-
this._err(
|
|
14566
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14567
14567
|
break;
|
|
14568
14568
|
}
|
|
14569
14569
|
case E.EOF: {
|
|
@@ -14590,15 +14590,15 @@ class eb {
|
|
|
14590
14590
|
break;
|
|
14591
14591
|
}
|
|
14592
14592
|
case E.QUESTION_MARK: {
|
|
14593
|
-
this._err(
|
|
14593
|
+
this._err(j.unexpectedQuestionMarkInsteadOfTagName), this._createCommentToken(1), this.state = C.BOGUS_COMMENT, this._stateBogusComment(t);
|
|
14594
14594
|
break;
|
|
14595
14595
|
}
|
|
14596
14596
|
case E.EOF: {
|
|
14597
|
-
this._err(
|
|
14597
|
+
this._err(j.eofBeforeTagName), this._emitChars("<"), this._emitEOFToken();
|
|
14598
14598
|
break;
|
|
14599
14599
|
}
|
|
14600
14600
|
default:
|
|
14601
|
-
this._err(
|
|
14601
|
+
this._err(j.invalidFirstCharacterOfTagName), this._emitChars("<"), this.state = C.DATA, this._stateData(t);
|
|
14602
14602
|
}
|
|
14603
14603
|
}
|
|
14604
14604
|
// End tag open state
|
|
@@ -14609,15 +14609,15 @@ class eb {
|
|
|
14609
14609
|
else
|
|
14610
14610
|
switch (t) {
|
|
14611
14611
|
case E.GREATER_THAN_SIGN: {
|
|
14612
|
-
this._err(
|
|
14612
|
+
this._err(j.missingEndTagName), this.state = C.DATA;
|
|
14613
14613
|
break;
|
|
14614
14614
|
}
|
|
14615
14615
|
case E.EOF: {
|
|
14616
|
-
this._err(
|
|
14616
|
+
this._err(j.eofBeforeTagName), this._emitChars("</"), this._emitEOFToken();
|
|
14617
14617
|
break;
|
|
14618
14618
|
}
|
|
14619
14619
|
default:
|
|
14620
|
-
this._err(
|
|
14620
|
+
this._err(j.invalidFirstCharacterOfTagName), this._createCommentToken(2), this.state = C.BOGUS_COMMENT, this._stateBogusComment(t);
|
|
14621
14621
|
}
|
|
14622
14622
|
}
|
|
14623
14623
|
// Tag name state
|
|
@@ -14641,11 +14641,11 @@ class eb {
|
|
|
14641
14641
|
break;
|
|
14642
14642
|
}
|
|
14643
14643
|
case E.NULL: {
|
|
14644
|
-
this._err(
|
|
14644
|
+
this._err(j.unexpectedNullCharacter), n.tagName += qe;
|
|
14645
14645
|
break;
|
|
14646
14646
|
}
|
|
14647
14647
|
case E.EOF: {
|
|
14648
|
-
this._err(
|
|
14648
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
14649
14649
|
break;
|
|
14650
14650
|
}
|
|
14651
14651
|
default:
|
|
@@ -14750,11 +14750,11 @@ class eb {
|
|
|
14750
14750
|
break;
|
|
14751
14751
|
}
|
|
14752
14752
|
case E.NULL: {
|
|
14753
|
-
this._err(
|
|
14753
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14754
14754
|
break;
|
|
14755
14755
|
}
|
|
14756
14756
|
case E.EOF: {
|
|
14757
|
-
this._err(
|
|
14757
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14758
14758
|
break;
|
|
14759
14759
|
}
|
|
14760
14760
|
default:
|
|
@@ -14774,11 +14774,11 @@ class eb {
|
|
|
14774
14774
|
break;
|
|
14775
14775
|
}
|
|
14776
14776
|
case E.NULL: {
|
|
14777
|
-
this._err(
|
|
14777
|
+
this._err(j.unexpectedNullCharacter), this.state = C.SCRIPT_DATA_ESCAPED, this._emitChars(qe);
|
|
14778
14778
|
break;
|
|
14779
14779
|
}
|
|
14780
14780
|
case E.EOF: {
|
|
14781
|
-
this._err(
|
|
14781
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14782
14782
|
break;
|
|
14783
14783
|
}
|
|
14784
14784
|
default:
|
|
@@ -14802,11 +14802,11 @@ class eb {
|
|
|
14802
14802
|
break;
|
|
14803
14803
|
}
|
|
14804
14804
|
case E.NULL: {
|
|
14805
|
-
this._err(
|
|
14805
|
+
this._err(j.unexpectedNullCharacter), this.state = C.SCRIPT_DATA_ESCAPED, this._emitChars(qe);
|
|
14806
14806
|
break;
|
|
14807
14807
|
}
|
|
14808
14808
|
case E.EOF: {
|
|
14809
|
-
this._err(
|
|
14809
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14810
14810
|
break;
|
|
14811
14811
|
}
|
|
14812
14812
|
default:
|
|
@@ -14851,11 +14851,11 @@ class eb {
|
|
|
14851
14851
|
break;
|
|
14852
14852
|
}
|
|
14853
14853
|
case E.NULL: {
|
|
14854
|
-
this._err(
|
|
14854
|
+
this._err(j.unexpectedNullCharacter), this._emitChars(qe);
|
|
14855
14855
|
break;
|
|
14856
14856
|
}
|
|
14857
14857
|
case E.EOF: {
|
|
14858
|
-
this._err(
|
|
14858
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14859
14859
|
break;
|
|
14860
14860
|
}
|
|
14861
14861
|
default:
|
|
@@ -14875,11 +14875,11 @@ class eb {
|
|
|
14875
14875
|
break;
|
|
14876
14876
|
}
|
|
14877
14877
|
case E.NULL: {
|
|
14878
|
-
this._err(
|
|
14878
|
+
this._err(j.unexpectedNullCharacter), this.state = C.SCRIPT_DATA_DOUBLE_ESCAPED, this._emitChars(qe);
|
|
14879
14879
|
break;
|
|
14880
14880
|
}
|
|
14881
14881
|
case E.EOF: {
|
|
14882
|
-
this._err(
|
|
14882
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14883
14883
|
break;
|
|
14884
14884
|
}
|
|
14885
14885
|
default:
|
|
@@ -14903,11 +14903,11 @@ class eb {
|
|
|
14903
14903
|
break;
|
|
14904
14904
|
}
|
|
14905
14905
|
case E.NULL: {
|
|
14906
|
-
this._err(
|
|
14906
|
+
this._err(j.unexpectedNullCharacter), this.state = C.SCRIPT_DATA_DOUBLE_ESCAPED, this._emitChars(qe);
|
|
14907
14907
|
break;
|
|
14908
14908
|
}
|
|
14909
14909
|
case E.EOF: {
|
|
14910
|
-
this._err(
|
|
14910
|
+
this._err(j.eofInScriptHtmlCommentLikeText), this._emitEOFToken();
|
|
14911
14911
|
break;
|
|
14912
14912
|
}
|
|
14913
14913
|
default:
|
|
@@ -14945,7 +14945,7 @@ class eb {
|
|
|
14945
14945
|
break;
|
|
14946
14946
|
}
|
|
14947
14947
|
case E.EQUALS_SIGN: {
|
|
14948
|
-
this._err(
|
|
14948
|
+
this._err(j.unexpectedEqualsSignBeforeAttributeName), this._createAttr("="), this.state = C.ATTRIBUTE_NAME;
|
|
14949
14949
|
break;
|
|
14950
14950
|
}
|
|
14951
14951
|
default:
|
|
@@ -14973,11 +14973,11 @@ class eb {
|
|
|
14973
14973
|
case E.QUOTATION_MARK:
|
|
14974
14974
|
case E.APOSTROPHE:
|
|
14975
14975
|
case E.LESS_THAN_SIGN: {
|
|
14976
|
-
this._err(
|
|
14976
|
+
this._err(j.unexpectedCharacterInAttributeName), this.currentAttr.name += String.fromCodePoint(t);
|
|
14977
14977
|
break;
|
|
14978
14978
|
}
|
|
14979
14979
|
case E.NULL: {
|
|
14980
|
-
this._err(
|
|
14980
|
+
this._err(j.unexpectedNullCharacter), this.currentAttr.name += qe;
|
|
14981
14981
|
break;
|
|
14982
14982
|
}
|
|
14983
14983
|
default:
|
|
@@ -15006,7 +15006,7 @@ class eb {
|
|
|
15006
15006
|
break;
|
|
15007
15007
|
}
|
|
15008
15008
|
case E.EOF: {
|
|
15009
|
-
this._err(
|
|
15009
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15010
15010
|
break;
|
|
15011
15011
|
}
|
|
15012
15012
|
default:
|
|
@@ -15031,7 +15031,7 @@ class eb {
|
|
|
15031
15031
|
break;
|
|
15032
15032
|
}
|
|
15033
15033
|
case E.GREATER_THAN_SIGN: {
|
|
15034
|
-
this._err(
|
|
15034
|
+
this._err(j.missingAttributeValue), this.state = C.DATA, this.emitCurrentTagToken();
|
|
15035
15035
|
break;
|
|
15036
15036
|
}
|
|
15037
15037
|
default:
|
|
@@ -15051,11 +15051,11 @@ class eb {
|
|
|
15051
15051
|
break;
|
|
15052
15052
|
}
|
|
15053
15053
|
case E.NULL: {
|
|
15054
|
-
this._err(
|
|
15054
|
+
this._err(j.unexpectedNullCharacter), this.currentAttr.value += qe;
|
|
15055
15055
|
break;
|
|
15056
15056
|
}
|
|
15057
15057
|
case E.EOF: {
|
|
15058
|
-
this._err(
|
|
15058
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15059
15059
|
break;
|
|
15060
15060
|
}
|
|
15061
15061
|
default:
|
|
@@ -15075,11 +15075,11 @@ class eb {
|
|
|
15075
15075
|
break;
|
|
15076
15076
|
}
|
|
15077
15077
|
case E.NULL: {
|
|
15078
|
-
this._err(
|
|
15078
|
+
this._err(j.unexpectedNullCharacter), this.currentAttr.value += qe;
|
|
15079
15079
|
break;
|
|
15080
15080
|
}
|
|
15081
15081
|
case E.EOF: {
|
|
15082
|
-
this._err(
|
|
15082
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15083
15083
|
break;
|
|
15084
15084
|
}
|
|
15085
15085
|
default:
|
|
@@ -15106,7 +15106,7 @@ class eb {
|
|
|
15106
15106
|
break;
|
|
15107
15107
|
}
|
|
15108
15108
|
case E.NULL: {
|
|
15109
|
-
this._err(
|
|
15109
|
+
this._err(j.unexpectedNullCharacter), this.currentAttr.value += qe;
|
|
15110
15110
|
break;
|
|
15111
15111
|
}
|
|
15112
15112
|
case E.QUOTATION_MARK:
|
|
@@ -15114,11 +15114,11 @@ class eb {
|
|
|
15114
15114
|
case E.LESS_THAN_SIGN:
|
|
15115
15115
|
case E.EQUALS_SIGN:
|
|
15116
15116
|
case E.GRAVE_ACCENT: {
|
|
15117
|
-
this._err(
|
|
15117
|
+
this._err(j.unexpectedCharacterInUnquotedAttributeValue), this.currentAttr.value += String.fromCodePoint(t);
|
|
15118
15118
|
break;
|
|
15119
15119
|
}
|
|
15120
15120
|
case E.EOF: {
|
|
15121
|
-
this._err(
|
|
15121
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15122
15122
|
break;
|
|
15123
15123
|
}
|
|
15124
15124
|
default:
|
|
@@ -15145,11 +15145,11 @@ class eb {
|
|
|
15145
15145
|
break;
|
|
15146
15146
|
}
|
|
15147
15147
|
case E.EOF: {
|
|
15148
|
-
this._err(
|
|
15148
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15149
15149
|
break;
|
|
15150
15150
|
}
|
|
15151
15151
|
default:
|
|
15152
|
-
this._err(
|
|
15152
|
+
this._err(j.missingWhitespaceBetweenAttributes), this.state = C.BEFORE_ATTRIBUTE_NAME, this._stateBeforeAttributeName(t);
|
|
15153
15153
|
}
|
|
15154
15154
|
}
|
|
15155
15155
|
// Self-closing start tag state
|
|
@@ -15162,11 +15162,11 @@ class eb {
|
|
|
15162
15162
|
break;
|
|
15163
15163
|
}
|
|
15164
15164
|
case E.EOF: {
|
|
15165
|
-
this._err(
|
|
15165
|
+
this._err(j.eofInTag), this._emitEOFToken();
|
|
15166
15166
|
break;
|
|
15167
15167
|
}
|
|
15168
15168
|
default:
|
|
15169
|
-
this._err(
|
|
15169
|
+
this._err(j.unexpectedSolidusInTag), this.state = C.BEFORE_ATTRIBUTE_NAME, this._stateBeforeAttributeName(t);
|
|
15170
15170
|
}
|
|
15171
15171
|
}
|
|
15172
15172
|
// Bogus comment state
|
|
@@ -15183,7 +15183,7 @@ class eb {
|
|
|
15183
15183
|
break;
|
|
15184
15184
|
}
|
|
15185
15185
|
case E.NULL: {
|
|
15186
|
-
this._err(
|
|
15186
|
+
this._err(j.unexpectedNullCharacter), n.data += qe;
|
|
15187
15187
|
break;
|
|
15188
15188
|
}
|
|
15189
15189
|
default:
|
|
@@ -15193,7 +15193,7 @@ class eb {
|
|
|
15193
15193
|
// Markup declaration open state
|
|
15194
15194
|
//------------------------------------------------------------------
|
|
15195
15195
|
_stateMarkupDeclarationOpen(t) {
|
|
15196
|
-
this._consumeSequenceIfMatch(lt.DASH_DASH, !0) ? (this._createCommentToken(lt.DASH_DASH.length + 1), this.state = C.COMMENT_START) : this._consumeSequenceIfMatch(lt.DOCTYPE, !1) ? (this.currentLocation = this.getCurrentLocation(lt.DOCTYPE.length + 1), this.state = C.DOCTYPE) : this._consumeSequenceIfMatch(lt.CDATA_START, !0) ? this.inForeignNode ? this.state = C.CDATA_SECTION : (this._err(
|
|
15196
|
+
this._consumeSequenceIfMatch(lt.DASH_DASH, !0) ? (this._createCommentToken(lt.DASH_DASH.length + 1), this.state = C.COMMENT_START) : this._consumeSequenceIfMatch(lt.DOCTYPE, !1) ? (this.currentLocation = this.getCurrentLocation(lt.DOCTYPE.length + 1), this.state = C.DOCTYPE) : this._consumeSequenceIfMatch(lt.CDATA_START, !0) ? this.inForeignNode ? this.state = C.CDATA_SECTION : (this._err(j.cdataInHtmlContent), this._createCommentToken(lt.CDATA_START.length + 1), this.currentToken.data = "[CDATA[", this.state = C.BOGUS_COMMENT) : this._ensureHibernation() || (this._err(j.incorrectlyOpenedComment), this._createCommentToken(2), this.state = C.BOGUS_COMMENT, this._stateBogusComment(t));
|
|
15197
15197
|
}
|
|
15198
15198
|
// Comment start state
|
|
15199
15199
|
//------------------------------------------------------------------
|
|
@@ -15204,7 +15204,7 @@ class eb {
|
|
|
15204
15204
|
break;
|
|
15205
15205
|
}
|
|
15206
15206
|
case E.GREATER_THAN_SIGN: {
|
|
15207
|
-
this._err(
|
|
15207
|
+
this._err(j.abruptClosingOfEmptyComment), this.state = C.DATA;
|
|
15208
15208
|
const n = this.currentToken;
|
|
15209
15209
|
this.emitCurrentComment(n);
|
|
15210
15210
|
break;
|
|
@@ -15223,11 +15223,11 @@ class eb {
|
|
|
15223
15223
|
break;
|
|
15224
15224
|
}
|
|
15225
15225
|
case E.GREATER_THAN_SIGN: {
|
|
15226
|
-
this._err(
|
|
15226
|
+
this._err(j.abruptClosingOfEmptyComment), this.state = C.DATA, this.emitCurrentComment(n);
|
|
15227
15227
|
break;
|
|
15228
15228
|
}
|
|
15229
15229
|
case E.EOF: {
|
|
15230
|
-
this._err(
|
|
15230
|
+
this._err(j.eofInComment), this.emitCurrentComment(n), this._emitEOFToken();
|
|
15231
15231
|
break;
|
|
15232
15232
|
}
|
|
15233
15233
|
default:
|
|
@@ -15248,11 +15248,11 @@ class eb {
|
|
|
15248
15248
|
break;
|
|
15249
15249
|
}
|
|
15250
15250
|
case E.NULL: {
|
|
15251
|
-
this._err(
|
|
15251
|
+
this._err(j.unexpectedNullCharacter), n.data += qe;
|
|
15252
15252
|
break;
|
|
15253
15253
|
}
|
|
15254
15254
|
case E.EOF: {
|
|
15255
|
-
this._err(
|
|
15255
|
+
this._err(j.eofInComment), this.emitCurrentComment(n), this._emitEOFToken();
|
|
15256
15256
|
break;
|
|
15257
15257
|
}
|
|
15258
15258
|
default:
|
|
@@ -15289,7 +15289,7 @@ class eb {
|
|
|
15289
15289
|
// Comment less-than sign bang dash dash state
|
|
15290
15290
|
//------------------------------------------------------------------
|
|
15291
15291
|
_stateCommentLessThanSignBangDashDash(t) {
|
|
15292
|
-
t !== E.GREATER_THAN_SIGN && t !== E.EOF && this._err(
|
|
15292
|
+
t !== E.GREATER_THAN_SIGN && t !== E.EOF && this._err(j.nestedComment), this.state = C.COMMENT_END, this._stateCommentEnd(t);
|
|
15293
15293
|
}
|
|
15294
15294
|
// Comment end dash state
|
|
15295
15295
|
//------------------------------------------------------------------
|
|
@@ -15301,7 +15301,7 @@ class eb {
|
|
|
15301
15301
|
break;
|
|
15302
15302
|
}
|
|
15303
15303
|
case E.EOF: {
|
|
15304
|
-
this._err(
|
|
15304
|
+
this._err(j.eofInComment), this.emitCurrentComment(n), this._emitEOFToken();
|
|
15305
15305
|
break;
|
|
15306
15306
|
}
|
|
15307
15307
|
default:
|
|
@@ -15326,7 +15326,7 @@ class eb {
|
|
|
15326
15326
|
break;
|
|
15327
15327
|
}
|
|
15328
15328
|
case E.EOF: {
|
|
15329
|
-
this._err(
|
|
15329
|
+
this._err(j.eofInComment), this.emitCurrentComment(n), this._emitEOFToken();
|
|
15330
15330
|
break;
|
|
15331
15331
|
}
|
|
15332
15332
|
default:
|
|
@@ -15343,11 +15343,11 @@ class eb {
|
|
|
15343
15343
|
break;
|
|
15344
15344
|
}
|
|
15345
15345
|
case E.GREATER_THAN_SIGN: {
|
|
15346
|
-
this._err(
|
|
15346
|
+
this._err(j.incorrectlyClosedComment), this.state = C.DATA, this.emitCurrentComment(n);
|
|
15347
15347
|
break;
|
|
15348
15348
|
}
|
|
15349
15349
|
case E.EOF: {
|
|
15350
|
-
this._err(
|
|
15350
|
+
this._err(j.eofInComment), this.emitCurrentComment(n), this._emitEOFToken();
|
|
15351
15351
|
break;
|
|
15352
15352
|
}
|
|
15353
15353
|
default:
|
|
@@ -15370,13 +15370,13 @@ class eb {
|
|
|
15370
15370
|
break;
|
|
15371
15371
|
}
|
|
15372
15372
|
case E.EOF: {
|
|
15373
|
-
this._err(
|
|
15373
|
+
this._err(j.eofInDoctype), this._createDoctypeToken(null);
|
|
15374
15374
|
const n = this.currentToken;
|
|
15375
15375
|
n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15376
15376
|
break;
|
|
15377
15377
|
}
|
|
15378
15378
|
default:
|
|
15379
|
-
this._err(
|
|
15379
|
+
this._err(j.missingWhitespaceBeforeDoctypeName), this.state = C.BEFORE_DOCTYPE_NAME, this._stateBeforeDoctypeName(t);
|
|
15380
15380
|
}
|
|
15381
15381
|
}
|
|
15382
15382
|
// Before DOCTYPE name state
|
|
@@ -15392,17 +15392,17 @@ class eb {
|
|
|
15392
15392
|
case E.FORM_FEED:
|
|
15393
15393
|
break;
|
|
15394
15394
|
case E.NULL: {
|
|
15395
|
-
this._err(
|
|
15395
|
+
this._err(j.unexpectedNullCharacter), this._createDoctypeToken(qe), this.state = C.DOCTYPE_NAME;
|
|
15396
15396
|
break;
|
|
15397
15397
|
}
|
|
15398
15398
|
case E.GREATER_THAN_SIGN: {
|
|
15399
|
-
this._err(
|
|
15399
|
+
this._err(j.missingDoctypeName), this._createDoctypeToken(null);
|
|
15400
15400
|
const n = this.currentToken;
|
|
15401
15401
|
n.forceQuirks = !0, this.emitCurrentDoctype(n), this.state = C.DATA;
|
|
15402
15402
|
break;
|
|
15403
15403
|
}
|
|
15404
15404
|
case E.EOF: {
|
|
15405
|
-
this._err(
|
|
15405
|
+
this._err(j.eofInDoctype), this._createDoctypeToken(null);
|
|
15406
15406
|
const n = this.currentToken;
|
|
15407
15407
|
n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15408
15408
|
break;
|
|
@@ -15428,11 +15428,11 @@ class eb {
|
|
|
15428
15428
|
break;
|
|
15429
15429
|
}
|
|
15430
15430
|
case E.NULL: {
|
|
15431
|
-
this._err(
|
|
15431
|
+
this._err(j.unexpectedNullCharacter), n.name += qe;
|
|
15432
15432
|
break;
|
|
15433
15433
|
}
|
|
15434
15434
|
case E.EOF: {
|
|
15435
|
-
this._err(
|
|
15435
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15436
15436
|
break;
|
|
15437
15437
|
}
|
|
15438
15438
|
default:
|
|
@@ -15454,11 +15454,11 @@ class eb {
|
|
|
15454
15454
|
break;
|
|
15455
15455
|
}
|
|
15456
15456
|
case E.EOF: {
|
|
15457
|
-
this._err(
|
|
15457
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15458
15458
|
break;
|
|
15459
15459
|
}
|
|
15460
15460
|
default:
|
|
15461
|
-
this._consumeSequenceIfMatch(lt.PUBLIC, !1) ? this.state = C.AFTER_DOCTYPE_PUBLIC_KEYWORD : this._consumeSequenceIfMatch(lt.SYSTEM, !1) ? this.state = C.AFTER_DOCTYPE_SYSTEM_KEYWORD : this._ensureHibernation() || (this._err(
|
|
15461
|
+
this._consumeSequenceIfMatch(lt.PUBLIC, !1) ? this.state = C.AFTER_DOCTYPE_PUBLIC_KEYWORD : this._consumeSequenceIfMatch(lt.SYSTEM, !1) ? this.state = C.AFTER_DOCTYPE_SYSTEM_KEYWORD : this._ensureHibernation() || (this._err(j.invalidCharacterSequenceAfterDoctypeName), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t));
|
|
15462
15462
|
}
|
|
15463
15463
|
}
|
|
15464
15464
|
// After DOCTYPE public keyword state
|
|
@@ -15474,23 +15474,23 @@ class eb {
|
|
|
15474
15474
|
break;
|
|
15475
15475
|
}
|
|
15476
15476
|
case E.QUOTATION_MARK: {
|
|
15477
|
-
this._err(
|
|
15477
|
+
this._err(j.missingWhitespaceAfterDoctypePublicKeyword), n.publicId = "", this.state = C.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;
|
|
15478
15478
|
break;
|
|
15479
15479
|
}
|
|
15480
15480
|
case E.APOSTROPHE: {
|
|
15481
|
-
this._err(
|
|
15481
|
+
this._err(j.missingWhitespaceAfterDoctypePublicKeyword), n.publicId = "", this.state = C.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;
|
|
15482
15482
|
break;
|
|
15483
15483
|
}
|
|
15484
15484
|
case E.GREATER_THAN_SIGN: {
|
|
15485
|
-
this._err(
|
|
15485
|
+
this._err(j.missingDoctypePublicIdentifier), n.forceQuirks = !0, this.state = C.DATA, this.emitCurrentDoctype(n);
|
|
15486
15486
|
break;
|
|
15487
15487
|
}
|
|
15488
15488
|
case E.EOF: {
|
|
15489
|
-
this._err(
|
|
15489
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15490
15490
|
break;
|
|
15491
15491
|
}
|
|
15492
15492
|
default:
|
|
15493
|
-
this._err(
|
|
15493
|
+
this._err(j.missingQuoteBeforeDoctypePublicIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15494
15494
|
}
|
|
15495
15495
|
}
|
|
15496
15496
|
// Before DOCTYPE public identifier state
|
|
@@ -15512,15 +15512,15 @@ class eb {
|
|
|
15512
15512
|
break;
|
|
15513
15513
|
}
|
|
15514
15514
|
case E.GREATER_THAN_SIGN: {
|
|
15515
|
-
this._err(
|
|
15515
|
+
this._err(j.missingDoctypePublicIdentifier), n.forceQuirks = !0, this.state = C.DATA, this.emitCurrentDoctype(n);
|
|
15516
15516
|
break;
|
|
15517
15517
|
}
|
|
15518
15518
|
case E.EOF: {
|
|
15519
|
-
this._err(
|
|
15519
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15520
15520
|
break;
|
|
15521
15521
|
}
|
|
15522
15522
|
default:
|
|
15523
|
-
this._err(
|
|
15523
|
+
this._err(j.missingQuoteBeforeDoctypePublicIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15524
15524
|
}
|
|
15525
15525
|
}
|
|
15526
15526
|
// DOCTYPE public identifier (double-quoted) state
|
|
@@ -15533,15 +15533,15 @@ class eb {
|
|
|
15533
15533
|
break;
|
|
15534
15534
|
}
|
|
15535
15535
|
case E.NULL: {
|
|
15536
|
-
this._err(
|
|
15536
|
+
this._err(j.unexpectedNullCharacter), n.publicId += qe;
|
|
15537
15537
|
break;
|
|
15538
15538
|
}
|
|
15539
15539
|
case E.GREATER_THAN_SIGN: {
|
|
15540
|
-
this._err(
|
|
15540
|
+
this._err(j.abruptDoctypePublicIdentifier), n.forceQuirks = !0, this.emitCurrentDoctype(n), this.state = C.DATA;
|
|
15541
15541
|
break;
|
|
15542
15542
|
}
|
|
15543
15543
|
case E.EOF: {
|
|
15544
|
-
this._err(
|
|
15544
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15545
15545
|
break;
|
|
15546
15546
|
}
|
|
15547
15547
|
default:
|
|
@@ -15558,15 +15558,15 @@ class eb {
|
|
|
15558
15558
|
break;
|
|
15559
15559
|
}
|
|
15560
15560
|
case E.NULL: {
|
|
15561
|
-
this._err(
|
|
15561
|
+
this._err(j.unexpectedNullCharacter), n.publicId += qe;
|
|
15562
15562
|
break;
|
|
15563
15563
|
}
|
|
15564
15564
|
case E.GREATER_THAN_SIGN: {
|
|
15565
|
-
this._err(
|
|
15565
|
+
this._err(j.abruptDoctypePublicIdentifier), n.forceQuirks = !0, this.emitCurrentDoctype(n), this.state = C.DATA;
|
|
15566
15566
|
break;
|
|
15567
15567
|
}
|
|
15568
15568
|
case E.EOF: {
|
|
15569
|
-
this._err(
|
|
15569
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15570
15570
|
break;
|
|
15571
15571
|
}
|
|
15572
15572
|
default:
|
|
@@ -15590,19 +15590,19 @@ class eb {
|
|
|
15590
15590
|
break;
|
|
15591
15591
|
}
|
|
15592
15592
|
case E.QUOTATION_MARK: {
|
|
15593
|
-
this._err(
|
|
15593
|
+
this._err(j.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers), n.systemId = "", this.state = C.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;
|
|
15594
15594
|
break;
|
|
15595
15595
|
}
|
|
15596
15596
|
case E.APOSTROPHE: {
|
|
15597
|
-
this._err(
|
|
15597
|
+
this._err(j.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers), n.systemId = "", this.state = C.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;
|
|
15598
15598
|
break;
|
|
15599
15599
|
}
|
|
15600
15600
|
case E.EOF: {
|
|
15601
|
-
this._err(
|
|
15601
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15602
15602
|
break;
|
|
15603
15603
|
}
|
|
15604
15604
|
default:
|
|
15605
|
-
this._err(
|
|
15605
|
+
this._err(j.missingQuoteBeforeDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15606
15606
|
}
|
|
15607
15607
|
}
|
|
15608
15608
|
// Between DOCTYPE public and system identifiers state
|
|
@@ -15628,11 +15628,11 @@ class eb {
|
|
|
15628
15628
|
break;
|
|
15629
15629
|
}
|
|
15630
15630
|
case E.EOF: {
|
|
15631
|
-
this._err(
|
|
15631
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15632
15632
|
break;
|
|
15633
15633
|
}
|
|
15634
15634
|
default:
|
|
15635
|
-
this._err(
|
|
15635
|
+
this._err(j.missingQuoteBeforeDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15636
15636
|
}
|
|
15637
15637
|
}
|
|
15638
15638
|
// After DOCTYPE system keyword state
|
|
@@ -15648,23 +15648,23 @@ class eb {
|
|
|
15648
15648
|
break;
|
|
15649
15649
|
}
|
|
15650
15650
|
case E.QUOTATION_MARK: {
|
|
15651
|
-
this._err(
|
|
15651
|
+
this._err(j.missingWhitespaceAfterDoctypeSystemKeyword), n.systemId = "", this.state = C.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;
|
|
15652
15652
|
break;
|
|
15653
15653
|
}
|
|
15654
15654
|
case E.APOSTROPHE: {
|
|
15655
|
-
this._err(
|
|
15655
|
+
this._err(j.missingWhitespaceAfterDoctypeSystemKeyword), n.systemId = "", this.state = C.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;
|
|
15656
15656
|
break;
|
|
15657
15657
|
}
|
|
15658
15658
|
case E.GREATER_THAN_SIGN: {
|
|
15659
|
-
this._err(
|
|
15659
|
+
this._err(j.missingDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.DATA, this.emitCurrentDoctype(n);
|
|
15660
15660
|
break;
|
|
15661
15661
|
}
|
|
15662
15662
|
case E.EOF: {
|
|
15663
|
-
this._err(
|
|
15663
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15664
15664
|
break;
|
|
15665
15665
|
}
|
|
15666
15666
|
default:
|
|
15667
|
-
this._err(
|
|
15667
|
+
this._err(j.missingQuoteBeforeDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15668
15668
|
}
|
|
15669
15669
|
}
|
|
15670
15670
|
// Before DOCTYPE system identifier state
|
|
@@ -15686,15 +15686,15 @@ class eb {
|
|
|
15686
15686
|
break;
|
|
15687
15687
|
}
|
|
15688
15688
|
case E.GREATER_THAN_SIGN: {
|
|
15689
|
-
this._err(
|
|
15689
|
+
this._err(j.missingDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.DATA, this.emitCurrentDoctype(n);
|
|
15690
15690
|
break;
|
|
15691
15691
|
}
|
|
15692
15692
|
case E.EOF: {
|
|
15693
|
-
this._err(
|
|
15693
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15694
15694
|
break;
|
|
15695
15695
|
}
|
|
15696
15696
|
default:
|
|
15697
|
-
this._err(
|
|
15697
|
+
this._err(j.missingQuoteBeforeDoctypeSystemIdentifier), n.forceQuirks = !0, this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15698
15698
|
}
|
|
15699
15699
|
}
|
|
15700
15700
|
// DOCTYPE system identifier (double-quoted) state
|
|
@@ -15707,15 +15707,15 @@ class eb {
|
|
|
15707
15707
|
break;
|
|
15708
15708
|
}
|
|
15709
15709
|
case E.NULL: {
|
|
15710
|
-
this._err(
|
|
15710
|
+
this._err(j.unexpectedNullCharacter), n.systemId += qe;
|
|
15711
15711
|
break;
|
|
15712
15712
|
}
|
|
15713
15713
|
case E.GREATER_THAN_SIGN: {
|
|
15714
|
-
this._err(
|
|
15714
|
+
this._err(j.abruptDoctypeSystemIdentifier), n.forceQuirks = !0, this.emitCurrentDoctype(n), this.state = C.DATA;
|
|
15715
15715
|
break;
|
|
15716
15716
|
}
|
|
15717
15717
|
case E.EOF: {
|
|
15718
|
-
this._err(
|
|
15718
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15719
15719
|
break;
|
|
15720
15720
|
}
|
|
15721
15721
|
default:
|
|
@@ -15732,15 +15732,15 @@ class eb {
|
|
|
15732
15732
|
break;
|
|
15733
15733
|
}
|
|
15734
15734
|
case E.NULL: {
|
|
15735
|
-
this._err(
|
|
15735
|
+
this._err(j.unexpectedNullCharacter), n.systemId += qe;
|
|
15736
15736
|
break;
|
|
15737
15737
|
}
|
|
15738
15738
|
case E.GREATER_THAN_SIGN: {
|
|
15739
|
-
this._err(
|
|
15739
|
+
this._err(j.abruptDoctypeSystemIdentifier), n.forceQuirks = !0, this.emitCurrentDoctype(n), this.state = C.DATA;
|
|
15740
15740
|
break;
|
|
15741
15741
|
}
|
|
15742
15742
|
case E.EOF: {
|
|
15743
|
-
this._err(
|
|
15743
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15744
15744
|
break;
|
|
15745
15745
|
}
|
|
15746
15746
|
default:
|
|
@@ -15762,11 +15762,11 @@ class eb {
|
|
|
15762
15762
|
break;
|
|
15763
15763
|
}
|
|
15764
15764
|
case E.EOF: {
|
|
15765
|
-
this._err(
|
|
15765
|
+
this._err(j.eofInDoctype), n.forceQuirks = !0, this.emitCurrentDoctype(n), this._emitEOFToken();
|
|
15766
15766
|
break;
|
|
15767
15767
|
}
|
|
15768
15768
|
default:
|
|
15769
|
-
this._err(
|
|
15769
|
+
this._err(j.unexpectedCharacterAfterDoctypeSystemIdentifier), this.state = C.BOGUS_DOCTYPE, this._stateBogusDoctype(t);
|
|
15770
15770
|
}
|
|
15771
15771
|
}
|
|
15772
15772
|
// Bogus DOCTYPE state
|
|
@@ -15779,7 +15779,7 @@ class eb {
|
|
|
15779
15779
|
break;
|
|
15780
15780
|
}
|
|
15781
15781
|
case E.NULL: {
|
|
15782
|
-
this._err(
|
|
15782
|
+
this._err(j.unexpectedNullCharacter);
|
|
15783
15783
|
break;
|
|
15784
15784
|
}
|
|
15785
15785
|
case E.EOF: {
|
|
@@ -15797,7 +15797,7 @@ class eb {
|
|
|
15797
15797
|
break;
|
|
15798
15798
|
}
|
|
15799
15799
|
case E.EOF: {
|
|
15800
|
-
this._err(
|
|
15800
|
+
this._err(j.eofInCdata), this._emitEOFToken();
|
|
15801
15801
|
break;
|
|
15802
15802
|
}
|
|
15803
15803
|
default:
|
|
@@ -15841,7 +15841,7 @@ class eb {
|
|
|
15841
15841
|
// Ambiguos ampersand state
|
|
15842
15842
|
//------------------------------------------------------------------
|
|
15843
15843
|
_stateAmbiguousAmpersand(t) {
|
|
15844
|
-
Ko(t) ? this._flushCodePointConsumedAsCharacterReference(t) : (t === E.SEMICOLON && this._err(
|
|
15844
|
+
Ko(t) ? this._flushCodePointConsumedAsCharacterReference(t) : (t === E.SEMICOLON && this._err(j.unknownNamedCharacterReference), this.state = this.returnState, this._callState(t));
|
|
15845
15845
|
}
|
|
15846
15846
|
}
|
|
15847
15847
|
const Oc = /* @__PURE__ */ new Set([o.DD, o.DT, o.LI, o.OPTGROUP, o.OPTION, o.P, o.RB, o.RP, o.RT, o.RTC]), Zo = /* @__PURE__ */ new Set([
|
|
@@ -15878,7 +15878,7 @@ class ob {
|
|
|
15878
15878
|
}
|
|
15879
15879
|
//Update current element
|
|
15880
15880
|
_isInTemplate() {
|
|
15881
|
-
return this.currentTagId === o.TEMPLATE && this.treeAdapter.getNamespaceURI(this.current) ===
|
|
15881
|
+
return this.currentTagId === o.TEMPLATE && this.treeAdapter.getNamespaceURI(this.current) === G.HTML;
|
|
15882
15882
|
}
|
|
15883
15883
|
_updateCurrentElement() {
|
|
15884
15884
|
this.current = this.items[this.stackTop], this.currentTagId = this.tagIDs[this.stackTop];
|
|
@@ -15903,7 +15903,7 @@ class ob {
|
|
|
15903
15903
|
let n = this.stackTop + 1;
|
|
15904
15904
|
do
|
|
15905
15905
|
n = this.tagIDs.lastIndexOf(t, n - 1);
|
|
15906
|
-
while (n > 0 && this.treeAdapter.getNamespaceURI(this.items[n]) !==
|
|
15906
|
+
while (n > 0 && this.treeAdapter.getNamespaceURI(this.items[n]) !== G.HTML);
|
|
15907
15907
|
this.shortenToLength(Math.max(n, 0));
|
|
15908
15908
|
}
|
|
15909
15909
|
shortenToLength(t) {
|
|
@@ -15921,10 +15921,10 @@ class ob {
|
|
|
15921
15921
|
this.shortenToLength(Math.max(r, 0));
|
|
15922
15922
|
}
|
|
15923
15923
|
popUntilNumberedHeaderPopped() {
|
|
15924
|
-
this.popUntilPopped(yi,
|
|
15924
|
+
this.popUntilPopped(yi, G.HTML);
|
|
15925
15925
|
}
|
|
15926
15926
|
popUntilTableCellPopped() {
|
|
15927
|
-
this.popUntilPopped(ub,
|
|
15927
|
+
this.popUntilPopped(ub, G.HTML);
|
|
15928
15928
|
}
|
|
15929
15929
|
popAllUpToHtmlElement() {
|
|
15930
15930
|
this.tmplCount = 0, this.shortenToLength(1);
|
|
@@ -15940,13 +15940,13 @@ class ob {
|
|
|
15940
15940
|
this.shortenToLength(r + 1);
|
|
15941
15941
|
}
|
|
15942
15942
|
clearBackToTableContext() {
|
|
15943
|
-
this.clearBackTo(ib,
|
|
15943
|
+
this.clearBackTo(ib, G.HTML);
|
|
15944
15944
|
}
|
|
15945
15945
|
clearBackToTableBodyContext() {
|
|
15946
|
-
this.clearBackTo(ab,
|
|
15946
|
+
this.clearBackTo(ab, G.HTML);
|
|
15947
15947
|
}
|
|
15948
15948
|
clearBackToTableRowContext() {
|
|
15949
|
-
this.clearBackTo(rb,
|
|
15949
|
+
this.clearBackTo(rb, G.HTML);
|
|
15950
15950
|
}
|
|
15951
15951
|
remove(t) {
|
|
15952
15952
|
const n = this._indexOf(t);
|
|
@@ -15971,19 +15971,19 @@ class ob {
|
|
|
15971
15971
|
for (let r = this.stackTop; r >= 0; r--) {
|
|
15972
15972
|
const a = this.tagIDs[r];
|
|
15973
15973
|
switch (this.treeAdapter.getNamespaceURI(this.items[r])) {
|
|
15974
|
-
case
|
|
15974
|
+
case G.HTML: {
|
|
15975
15975
|
if (a === t)
|
|
15976
15976
|
return !0;
|
|
15977
15977
|
if (n.has(a))
|
|
15978
15978
|
return !1;
|
|
15979
15979
|
break;
|
|
15980
15980
|
}
|
|
15981
|
-
case
|
|
15981
|
+
case G.SVG: {
|
|
15982
15982
|
if (es.has(a))
|
|
15983
15983
|
return !1;
|
|
15984
15984
|
break;
|
|
15985
15985
|
}
|
|
15986
|
-
case
|
|
15986
|
+
case G.MATHML: {
|
|
15987
15987
|
if (Jo.has(a))
|
|
15988
15988
|
return !1;
|
|
15989
15989
|
break;
|
|
@@ -16005,19 +16005,19 @@ class ob {
|
|
|
16005
16005
|
for (let t = this.stackTop; t >= 0; t--) {
|
|
16006
16006
|
const n = this.tagIDs[t];
|
|
16007
16007
|
switch (this.treeAdapter.getNamespaceURI(this.items[t])) {
|
|
16008
|
-
case
|
|
16008
|
+
case G.HTML: {
|
|
16009
16009
|
if (yi.has(n))
|
|
16010
16010
|
return !0;
|
|
16011
16011
|
if (Vr.has(n))
|
|
16012
16012
|
return !1;
|
|
16013
16013
|
break;
|
|
16014
16014
|
}
|
|
16015
|
-
case
|
|
16015
|
+
case G.SVG: {
|
|
16016
16016
|
if (es.has(n))
|
|
16017
16017
|
return !1;
|
|
16018
16018
|
break;
|
|
16019
16019
|
}
|
|
16020
|
-
case
|
|
16020
|
+
case G.MATHML: {
|
|
16021
16021
|
if (Jo.has(n))
|
|
16022
16022
|
return !1;
|
|
16023
16023
|
break;
|
|
@@ -16028,7 +16028,7 @@ class ob {
|
|
|
16028
16028
|
}
|
|
16029
16029
|
hasInTableScope(t) {
|
|
16030
16030
|
for (let n = this.stackTop; n >= 0; n--)
|
|
16031
|
-
if (this.treeAdapter.getNamespaceURI(this.items[n]) ===
|
|
16031
|
+
if (this.treeAdapter.getNamespaceURI(this.items[n]) === G.HTML)
|
|
16032
16032
|
switch (this.tagIDs[n]) {
|
|
16033
16033
|
case t:
|
|
16034
16034
|
return !0;
|
|
@@ -16040,7 +16040,7 @@ class ob {
|
|
|
16040
16040
|
}
|
|
16041
16041
|
hasTableBodyContextInTableScope() {
|
|
16042
16042
|
for (let t = this.stackTop; t >= 0; t--)
|
|
16043
|
-
if (this.treeAdapter.getNamespaceURI(this.items[t]) ===
|
|
16043
|
+
if (this.treeAdapter.getNamespaceURI(this.items[t]) === G.HTML)
|
|
16044
16044
|
switch (this.tagIDs[t]) {
|
|
16045
16045
|
case o.TBODY:
|
|
16046
16046
|
case o.THEAD:
|
|
@@ -16054,7 +16054,7 @@ class ob {
|
|
|
16054
16054
|
}
|
|
16055
16055
|
hasInSelectScope(t) {
|
|
16056
16056
|
for (let n = this.stackTop; n >= 0; n--)
|
|
16057
|
-
if (this.treeAdapter.getNamespaceURI(this.items[n]) ===
|
|
16057
|
+
if (this.treeAdapter.getNamespaceURI(this.items[n]) === G.HTML)
|
|
16058
16058
|
switch (this.tagIDs[n]) {
|
|
16059
16059
|
case t:
|
|
16060
16060
|
return !0;
|
|
@@ -16474,17 +16474,17 @@ const rs = {
|
|
|
16474
16474
|
"yChannelSelector",
|
|
16475
16475
|
"zoomAndPan"
|
|
16476
16476
|
].map((e) => [e.toLowerCase(), e])), Tb = /* @__PURE__ */ new Map([
|
|
16477
|
-
["xlink:actuate", { prefix: "xlink", name: "actuate", namespace:
|
|
16478
|
-
["xlink:arcrole", { prefix: "xlink", name: "arcrole", namespace:
|
|
16479
|
-
["xlink:href", { prefix: "xlink", name: "href", namespace:
|
|
16480
|
-
["xlink:role", { prefix: "xlink", name: "role", namespace:
|
|
16481
|
-
["xlink:show", { prefix: "xlink", name: "show", namespace:
|
|
16482
|
-
["xlink:title", { prefix: "xlink", name: "title", namespace:
|
|
16483
|
-
["xlink:type", { prefix: "xlink", name: "type", namespace:
|
|
16484
|
-
["xml:lang", { prefix: "xml", name: "lang", namespace:
|
|
16485
|
-
["xml:space", { prefix: "xml", name: "space", namespace:
|
|
16486
|
-
["xmlns", { prefix: "", name: "xmlns", namespace:
|
|
16487
|
-
["xmlns:xlink", { prefix: "xmlns", name: "xlink", namespace:
|
|
16477
|
+
["xlink:actuate", { prefix: "xlink", name: "actuate", namespace: G.XLINK }],
|
|
16478
|
+
["xlink:arcrole", { prefix: "xlink", name: "arcrole", namespace: G.XLINK }],
|
|
16479
|
+
["xlink:href", { prefix: "xlink", name: "href", namespace: G.XLINK }],
|
|
16480
|
+
["xlink:role", { prefix: "xlink", name: "role", namespace: G.XLINK }],
|
|
16481
|
+
["xlink:show", { prefix: "xlink", name: "show", namespace: G.XLINK }],
|
|
16482
|
+
["xlink:title", { prefix: "xlink", name: "title", namespace: G.XLINK }],
|
|
16483
|
+
["xlink:type", { prefix: "xlink", name: "type", namespace: G.XLINK }],
|
|
16484
|
+
["xml:lang", { prefix: "xml", name: "lang", namespace: G.XML }],
|
|
16485
|
+
["xml:space", { prefix: "xml", name: "space", namespace: G.XML }],
|
|
16486
|
+
["xmlns", { prefix: "", name: "xmlns", namespace: G.XMLNS }],
|
|
16487
|
+
["xmlns:xlink", { prefix: "xmlns", name: "xlink", namespace: G.XMLNS }]
|
|
16488
16488
|
]), yb = new Map([
|
|
16489
16489
|
"altGlyph",
|
|
16490
16490
|
"altGlyphDef",
|
|
@@ -16596,20 +16596,20 @@ function Ab(e) {
|
|
|
16596
16596
|
t != null && (e.tagName = t, e.tagID = Dn(e.tagName));
|
|
16597
16597
|
}
|
|
16598
16598
|
function Sb(e, t) {
|
|
16599
|
-
return t ===
|
|
16599
|
+
return t === G.MATHML && (e === o.MI || e === o.MO || e === o.MN || e === o.MS || e === o.MTEXT);
|
|
16600
16600
|
}
|
|
16601
16601
|
function xb(e, t, n) {
|
|
16602
|
-
if (t ===
|
|
16602
|
+
if (t === G.MATHML && e === o.ANNOTATION_XML) {
|
|
16603
16603
|
for (let r = 0; r < n.length; r++)
|
|
16604
16604
|
if (n[r].name === on.ENCODING) {
|
|
16605
16605
|
const a = n[r].value.toLowerCase();
|
|
16606
16606
|
return a === rs.TEXT_HTML || a === rs.APPLICATION_XML;
|
|
16607
16607
|
}
|
|
16608
16608
|
}
|
|
16609
|
-
return t ===
|
|
16609
|
+
return t === G.SVG && (e === o.FOREIGN_OBJECT || e === o.DESC || e === o.TITLE);
|
|
16610
16610
|
}
|
|
16611
16611
|
function vb(e, t, n, r) {
|
|
16612
|
-
return (!r || r ===
|
|
16612
|
+
return (!r || r === G.HTML) && xb(e, t, n) || (!r || r === G.MATHML) && Sb(e, t);
|
|
16613
16613
|
}
|
|
16614
16614
|
const Ob = "hidden", Ib = 8, Nb = 3;
|
|
16615
16615
|
var O;
|
|
@@ -16646,8 +16646,8 @@ class is {
|
|
|
16646
16646
|
...as,
|
|
16647
16647
|
...n
|
|
16648
16648
|
};
|
|
16649
|
-
t ?? (t = r.treeAdapter.createElement(R.TEMPLATE,
|
|
16650
|
-
const a = r.treeAdapter.createElement("documentmock",
|
|
16649
|
+
t ?? (t = r.treeAdapter.createElement(R.TEMPLATE, G.HTML, []));
|
|
16650
|
+
const a = r.treeAdapter.createElement("documentmock", G.HTML, []), i = new this(r, a, t);
|
|
16651
16651
|
return i.fragmentContextID === o.TEMPLATE && i.tmplInsertionModeStack.unshift(O.IN_TEMPLATE), i._initTokenizerForFragmentParsing(), i._insertFakeRootElement(), i._resetInsertionMode(), i._findFormInFragmentContext(), i;
|
|
16652
16652
|
}
|
|
16653
16653
|
getFragment() {
|
|
@@ -16686,12 +16686,12 @@ class is {
|
|
|
16686
16686
|
}
|
|
16687
16687
|
}
|
|
16688
16688
|
_setContextModes(t, n) {
|
|
16689
|
-
const r = t === this.document || t && this.treeAdapter.getNamespaceURI(t) ===
|
|
16689
|
+
const r = t === this.document || t && this.treeAdapter.getNamespaceURI(t) === G.HTML;
|
|
16690
16690
|
this.currentNotInHTML = !r, this.tokenizer.inForeignNode = !r && t !== void 0 && n !== void 0 && !this._isIntegrationPoint(n, t);
|
|
16691
16691
|
}
|
|
16692
16692
|
/** @protected */
|
|
16693
16693
|
_switchToTextParsing(t, n) {
|
|
16694
|
-
this._insertElement(t,
|
|
16694
|
+
this._insertElement(t, G.HTML), this.tokenizer.state = n, this.originalInsertionMode = this.insertionMode, this.insertionMode = O.TEXT;
|
|
16695
16695
|
}
|
|
16696
16696
|
switchToPlaintextParsing() {
|
|
16697
16697
|
this.insertionMode = O.TEXT, this.originalInsertionMode = O.IN_BODY, this.tokenizer.state = We.PLAINTEXT;
|
|
@@ -16713,7 +16713,7 @@ class is {
|
|
|
16713
16713
|
}
|
|
16714
16714
|
}
|
|
16715
16715
|
_initTokenizerForFragmentParsing() {
|
|
16716
|
-
if (!(!this.fragmentContext || this.treeAdapter.getNamespaceURI(this.fragmentContext) !==
|
|
16716
|
+
if (!(!this.fragmentContext || this.treeAdapter.getNamespaceURI(this.fragmentContext) !== G.HTML))
|
|
16717
16717
|
switch (this.fragmentContextID) {
|
|
16718
16718
|
case o.TITLE:
|
|
16719
16719
|
case o.TEXTAREA: {
|
|
@@ -16780,17 +16780,17 @@ class is {
|
|
|
16780
16780
|
}
|
|
16781
16781
|
/** @protected */
|
|
16782
16782
|
_insertFakeElement(t, n) {
|
|
16783
|
-
const r = this.treeAdapter.createElement(t,
|
|
16783
|
+
const r = this.treeAdapter.createElement(t, G.HTML, []);
|
|
16784
16784
|
this._attachElementToTree(r, null), this.openElements.push(r, n);
|
|
16785
16785
|
}
|
|
16786
16786
|
/** @protected */
|
|
16787
16787
|
_insertTemplate(t) {
|
|
16788
|
-
const n = this.treeAdapter.createElement(t.tagName,
|
|
16788
|
+
const n = this.treeAdapter.createElement(t.tagName, G.HTML, t.attrs), r = this.treeAdapter.createDocumentFragment();
|
|
16789
16789
|
this.treeAdapter.setTemplateContent(n, r), this._attachElementToTree(n, t.location), this.openElements.push(n, t.tagID), this.options.sourceCodeLocationInfo && this.treeAdapter.setNodeSourceCodeLocation(r, null);
|
|
16790
16790
|
}
|
|
16791
16791
|
/** @protected */
|
|
16792
16792
|
_insertFakeRootElement() {
|
|
16793
|
-
const t = this.treeAdapter.createElement(R.HTML,
|
|
16793
|
+
const t = this.treeAdapter.createElement(R.HTML, G.HTML, []);
|
|
16794
16794
|
this.options.sourceCodeLocationInfo && this.treeAdapter.setNodeSourceCodeLocation(t, null), this.treeAdapter.appendChild(this.openElements.current, t), this.openElements.push(t, o.HTML);
|
|
16795
16795
|
}
|
|
16796
16796
|
/** @protected */
|
|
@@ -16839,11 +16839,11 @@ class is {
|
|
|
16839
16839
|
if (!this.currentNotInHTML)
|
|
16840
16840
|
return !1;
|
|
16841
16841
|
let n, r;
|
|
16842
|
-
return this.openElements.stackTop === 0 && this.fragmentContext ? (n = this.fragmentContext, r = this.fragmentContextID) : { current: n, currentTagId: r } = this.openElements, t.tagID === o.SVG && this.treeAdapter.getTagName(n) === R.ANNOTATION_XML && this.treeAdapter.getNamespaceURI(n) ===
|
|
16842
|
+
return this.openElements.stackTop === 0 && this.fragmentContext ? (n = this.fragmentContext, r = this.fragmentContextID) : { current: n, currentTagId: r } = this.openElements, t.tagID === o.SVG && this.treeAdapter.getTagName(n) === R.ANNOTATION_XML && this.treeAdapter.getNamespaceURI(n) === G.MATHML ? !1 : (
|
|
16843
16843
|
// Check that `current` is not an integration point for HTML or MathML elements.
|
|
16844
16844
|
this.tokenizer.inForeignNode || // If it _is_ an integration point, then we might have to check that it is not an HTML
|
|
16845
16845
|
// integration point.
|
|
16846
|
-
(t.tagID === o.MGLYPH || t.tagID === o.MALIGNMARK) && r !== void 0 && !this._isIntegrationPoint(r, n,
|
|
16846
|
+
(t.tagID === o.MGLYPH || t.tagID === o.MALIGNMARK) && r !== void 0 && !this._isIntegrationPoint(r, n, G.HTML)
|
|
16847
16847
|
);
|
|
16848
16848
|
}
|
|
16849
16849
|
/** @protected */
|
|
@@ -17004,7 +17004,7 @@ class is {
|
|
|
17004
17004
|
const n = this.openElements.items[t];
|
|
17005
17005
|
switch (this.openElements.tagIDs[t]) {
|
|
17006
17006
|
case o.TEMPLATE: {
|
|
17007
|
-
if (this.treeAdapter.getNamespaceURI(n) ===
|
|
17007
|
+
if (this.treeAdapter.getNamespaceURI(n) === G.HTML)
|
|
17008
17008
|
return { parent: this.treeAdapter.getTemplateContent(n), beforeElement: null };
|
|
17009
17009
|
break;
|
|
17010
17010
|
}
|
|
@@ -17204,7 +17204,7 @@ class is {
|
|
|
17204
17204
|
case O.IN_HEAD:
|
|
17205
17205
|
case O.IN_HEAD_NO_SCRIPT:
|
|
17206
17206
|
case O.AFTER_HEAD: {
|
|
17207
|
-
this._err(t,
|
|
17207
|
+
this._err(t, j.misplacedDoctype);
|
|
17208
17208
|
break;
|
|
17209
17209
|
}
|
|
17210
17210
|
case O.IN_TABLE_TEXT: {
|
|
@@ -17215,7 +17215,7 @@ class is {
|
|
|
17215
17215
|
}
|
|
17216
17216
|
/** @internal */
|
|
17217
17217
|
onStartTag(t) {
|
|
17218
|
-
this.skipNextNewLine = !1, this.currentToken = t, this._processStartTag(t), t.selfClosing && !t.ackSelfClosing && this._err(t,
|
|
17218
|
+
this.skipNextNewLine = !1, this.currentToken = t, this._processStartTag(t), t.selfClosing && !t.ackSelfClosing && this._err(t, j.nonVoidHtmlElementStartTagWithTrailingSolidus);
|
|
17219
17219
|
}
|
|
17220
17220
|
/**
|
|
17221
17221
|
* Processes a given start tag.
|
|
@@ -17562,7 +17562,7 @@ function Pb(e, t, n) {
|
|
|
17562
17562
|
e._fosterParentElement(n);
|
|
17563
17563
|
else {
|
|
17564
17564
|
const i = e.treeAdapter.getNamespaceURI(t);
|
|
17565
|
-
a === o.TEMPLATE && i ===
|
|
17565
|
+
a === o.TEMPLATE && i === G.HTML && (t = e.treeAdapter.getTemplateContent(t)), e.treeAdapter.appendChild(t, n);
|
|
17566
17566
|
}
|
|
17567
17567
|
}
|
|
17568
17568
|
function Mb(e, t, n) {
|
|
@@ -17608,13 +17608,13 @@ function Qi(e, t) {
|
|
|
17608
17608
|
function Hb(e, t) {
|
|
17609
17609
|
e._setDocumentType(t);
|
|
17610
17610
|
const n = t.forceQuirks ? _t.QUIRKS : mb(t);
|
|
17611
|
-
pb(t) || e._err(t,
|
|
17611
|
+
pb(t) || e._err(t, j.nonConformingDoctype), e.treeAdapter.setDocumentMode(e.document, n), e.insertionMode = O.BEFORE_HTML;
|
|
17612
17612
|
}
|
|
17613
17613
|
function Wn(e, t) {
|
|
17614
|
-
e._err(t,
|
|
17614
|
+
e._err(t, j.missingDoctype, !0), e.treeAdapter.setDocumentMode(e.document, _t.QUIRKS), e.insertionMode = O.BEFORE_HTML, e._processToken(t);
|
|
17615
17615
|
}
|
|
17616
17616
|
function Ub(e, t) {
|
|
17617
|
-
t.tagID === o.HTML ? (e._insertElement(t,
|
|
17617
|
+
t.tagID === o.HTML ? (e._insertElement(t, G.HTML), e.insertionMode = O.BEFORE_HEAD) : ar(e, t);
|
|
17618
17618
|
}
|
|
17619
17619
|
function jb(e, t) {
|
|
17620
17620
|
const n = t.tagID;
|
|
@@ -17630,7 +17630,7 @@ function qb(e, t) {
|
|
|
17630
17630
|
break;
|
|
17631
17631
|
}
|
|
17632
17632
|
case o.HEAD: {
|
|
17633
|
-
e._insertElement(t,
|
|
17633
|
+
e._insertElement(t, G.HTML), e.headElement = e.openElements.current, e.insertionMode = O.IN_HEAD;
|
|
17634
17634
|
break;
|
|
17635
17635
|
}
|
|
17636
17636
|
default:
|
|
@@ -17639,7 +17639,7 @@ function qb(e, t) {
|
|
|
17639
17639
|
}
|
|
17640
17640
|
function zb(e, t) {
|
|
17641
17641
|
const n = t.tagID;
|
|
17642
|
-
n === o.HEAD || n === o.BODY || n === o.HTML || n === o.BR ? ir(e, t) : e._err(t,
|
|
17642
|
+
n === o.HEAD || n === o.BODY || n === o.HTML || n === o.BR ? ir(e, t) : e._err(t, j.endTagWithoutMatchingOpenElement);
|
|
17643
17643
|
}
|
|
17644
17644
|
function ir(e, t) {
|
|
17645
17645
|
e._insertFakeElement(R.HEAD, o.HEAD), e.headElement = e.openElements.current, e.insertionMode = O.IN_HEAD, e._processToken(t);
|
|
@@ -17655,7 +17655,7 @@ function Lt(e, t) {
|
|
|
17655
17655
|
case o.BGSOUND:
|
|
17656
17656
|
case o.LINK:
|
|
17657
17657
|
case o.META: {
|
|
17658
|
-
e._appendElement(t,
|
|
17658
|
+
e._appendElement(t, G.HTML), t.ackSelfClosing = !0;
|
|
17659
17659
|
break;
|
|
17660
17660
|
}
|
|
17661
17661
|
case o.TITLE: {
|
|
@@ -17663,7 +17663,7 @@ function Lt(e, t) {
|
|
|
17663
17663
|
break;
|
|
17664
17664
|
}
|
|
17665
17665
|
case o.NOSCRIPT: {
|
|
17666
|
-
e.options.scriptingEnabled ? e._switchToTextParsing(t, We.RAWTEXT) : (e._insertElement(t,
|
|
17666
|
+
e.options.scriptingEnabled ? e._switchToTextParsing(t, We.RAWTEXT) : (e._insertElement(t, G.HTML), e.insertionMode = O.IN_HEAD_NO_SCRIPT);
|
|
17667
17667
|
break;
|
|
17668
17668
|
}
|
|
17669
17669
|
case o.NOFRAMES:
|
|
@@ -17680,7 +17680,7 @@ function Lt(e, t) {
|
|
|
17680
17680
|
break;
|
|
17681
17681
|
}
|
|
17682
17682
|
case o.HEAD: {
|
|
17683
|
-
e._err(t,
|
|
17683
|
+
e._err(t, j.misplacedStartTagForHeadElement);
|
|
17684
17684
|
break;
|
|
17685
17685
|
}
|
|
17686
17686
|
default:
|
|
@@ -17704,11 +17704,11 @@ function Yb(e, t) {
|
|
|
17704
17704
|
break;
|
|
17705
17705
|
}
|
|
17706
17706
|
default:
|
|
17707
|
-
e._err(t,
|
|
17707
|
+
e._err(t, j.endTagWithoutMatchingOpenElement);
|
|
17708
17708
|
}
|
|
17709
17709
|
}
|
|
17710
17710
|
function fn(e, t) {
|
|
17711
|
-
e.openElements.tmplCount > 0 ? (e.openElements.generateImpliedEndTagsThoroughly(), e.openElements.currentTagId !== o.TEMPLATE && e._err(t,
|
|
17711
|
+
e.openElements.tmplCount > 0 ? (e.openElements.generateImpliedEndTagsThoroughly(), e.openElements.currentTagId !== o.TEMPLATE && e._err(t, j.closingOfElementWithOpenChildElements), e.openElements.popUntilTagNamePopped(o.TEMPLATE), e.activeFormattingElements.clearToLastMarker(), e.tmplInsertionModeStack.shift(), e._resetInsertionMode()) : e._err(t, j.endTagWithoutMatchingOpenElement);
|
|
17712
17712
|
}
|
|
17713
17713
|
function ur(e, t) {
|
|
17714
17714
|
e.openElements.pop(), e.insertionMode = O.AFTER_HEAD, e._processToken(t);
|
|
@@ -17730,7 +17730,7 @@ function $b(e, t) {
|
|
|
17730
17730
|
break;
|
|
17731
17731
|
}
|
|
17732
17732
|
case o.NOSCRIPT: {
|
|
17733
|
-
e._err(t,
|
|
17733
|
+
e._err(t, j.nestedNoscriptInHead);
|
|
17734
17734
|
break;
|
|
17735
17735
|
}
|
|
17736
17736
|
default:
|
|
@@ -17748,11 +17748,11 @@ function Vb(e, t) {
|
|
|
17748
17748
|
break;
|
|
17749
17749
|
}
|
|
17750
17750
|
default:
|
|
17751
|
-
e._err(t,
|
|
17751
|
+
e._err(t, j.endTagWithoutMatchingOpenElement);
|
|
17752
17752
|
}
|
|
17753
17753
|
}
|
|
17754
17754
|
function or(e, t) {
|
|
17755
|
-
const n = t.type === me.EOF ?
|
|
17755
|
+
const n = t.type === me.EOF ? j.openElementsLeftAfterEof : j.disallowedContentInNoscriptInHead;
|
|
17756
17756
|
e._err(t, n), e.openElements.pop(), e.insertionMode = O.IN_HEAD, e._processToken(t);
|
|
17757
17757
|
}
|
|
17758
17758
|
function Wb(e, t) {
|
|
@@ -17762,11 +17762,11 @@ function Wb(e, t) {
|
|
|
17762
17762
|
break;
|
|
17763
17763
|
}
|
|
17764
17764
|
case o.BODY: {
|
|
17765
|
-
e._insertElement(t,
|
|
17765
|
+
e._insertElement(t, G.HTML), e.framesetOk = !1, e.insertionMode = O.IN_BODY;
|
|
17766
17766
|
break;
|
|
17767
17767
|
}
|
|
17768
17768
|
case o.FRAMESET: {
|
|
17769
|
-
e._insertElement(t,
|
|
17769
|
+
e._insertElement(t, G.HTML), e.insertionMode = O.IN_FRAMESET;
|
|
17770
17770
|
break;
|
|
17771
17771
|
}
|
|
17772
17772
|
case o.BASE:
|
|
@@ -17779,11 +17779,11 @@ function Wb(e, t) {
|
|
|
17779
17779
|
case o.STYLE:
|
|
17780
17780
|
case o.TEMPLATE:
|
|
17781
17781
|
case o.TITLE: {
|
|
17782
|
-
e._err(t,
|
|
17782
|
+
e._err(t, j.abandonedHeadElementChild), e.openElements.push(e.headElement, o.HEAD), Lt(e, t), e.openElements.remove(e.headElement);
|
|
17783
17783
|
break;
|
|
17784
17784
|
}
|
|
17785
17785
|
case o.HEAD: {
|
|
17786
|
-
e._err(t,
|
|
17786
|
+
e._err(t, j.misplacedStartTagForHeadElement);
|
|
17787
17787
|
break;
|
|
17788
17788
|
}
|
|
17789
17789
|
default:
|
|
@@ -17803,7 +17803,7 @@ function Gb(e, t) {
|
|
|
17803
17803
|
break;
|
|
17804
17804
|
}
|
|
17805
17805
|
default:
|
|
17806
|
-
e._err(t,
|
|
17806
|
+
e._err(t, j.endTagWithoutMatchingOpenElement);
|
|
17807
17807
|
}
|
|
17808
17808
|
}
|
|
17809
17809
|
function sr(e, t) {
|
|
@@ -17852,20 +17852,20 @@ function Kb(e, t) {
|
|
|
17852
17852
|
}
|
|
17853
17853
|
function Qb(e, t) {
|
|
17854
17854
|
const n = e.openElements.tryPeekProperlyNestedBodyElement();
|
|
17855
|
-
e.framesetOk && n && (e.treeAdapter.detachNode(n), e.openElements.popAllUpToHtmlElement(), e._insertElement(t,
|
|
17855
|
+
e.framesetOk && n && (e.treeAdapter.detachNode(n), e.openElements.popAllUpToHtmlElement(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_FRAMESET);
|
|
17856
17856
|
}
|
|
17857
17857
|
function Zb(e, t) {
|
|
17858
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17858
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML);
|
|
17859
17859
|
}
|
|
17860
17860
|
function Jb(e, t) {
|
|
17861
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e.openElements.currentTagId !== void 0 && yi.has(e.openElements.currentTagId) && e.openElements.pop(), e._insertElement(t,
|
|
17861
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e.openElements.currentTagId !== void 0 && yi.has(e.openElements.currentTagId) && e.openElements.pop(), e._insertElement(t, G.HTML);
|
|
17862
17862
|
}
|
|
17863
17863
|
function eE(e, t) {
|
|
17864
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17864
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML), e.skipNextNewLine = !0, e.framesetOk = !1;
|
|
17865
17865
|
}
|
|
17866
17866
|
function tE(e, t) {
|
|
17867
17867
|
const n = e.openElements.tmplCount > 0;
|
|
17868
|
-
(!e.formElement || n) && (e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17868
|
+
(!e.formElement || n) && (e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML), n || (e.formElement = e.openElements.current));
|
|
17869
17869
|
}
|
|
17870
17870
|
function nE(e, t) {
|
|
17871
17871
|
e.framesetOk = !1;
|
|
@@ -17879,51 +17879,51 @@ function nE(e, t) {
|
|
|
17879
17879
|
if (a !== o.ADDRESS && a !== o.DIV && a !== o.P && e._isSpecialElement(e.openElements.items[r], a))
|
|
17880
17880
|
break;
|
|
17881
17881
|
}
|
|
17882
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17882
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML);
|
|
17883
17883
|
}
|
|
17884
17884
|
function rE(e, t) {
|
|
17885
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17885
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML), e.tokenizer.state = We.PLAINTEXT;
|
|
17886
17886
|
}
|
|
17887
17887
|
function aE(e, t) {
|
|
17888
|
-
e.openElements.hasInScope(o.BUTTON) && (e.openElements.generateImpliedEndTags(), e.openElements.popUntilTagNamePopped(o.BUTTON)), e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17888
|
+
e.openElements.hasInScope(o.BUTTON) && (e.openElements.generateImpliedEndTags(), e.openElements.popUntilTagNamePopped(o.BUTTON)), e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML), e.framesetOk = !1;
|
|
17889
17889
|
}
|
|
17890
17890
|
function iE(e, t) {
|
|
17891
17891
|
const n = e.activeFormattingElements.getElementEntryInScopeWithTagName(R.A);
|
|
17892
|
-
n && (Ki(e, t), e.openElements.remove(n.element), e.activeFormattingElements.removeEntry(n)), e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17892
|
+
n && (Ki(e, t), e.openElements.remove(n.element), e.activeFormattingElements.removeEntry(n)), e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML), e.activeFormattingElements.pushElement(e.openElements.current, t);
|
|
17893
17893
|
}
|
|
17894
17894
|
function uE(e, t) {
|
|
17895
|
-
e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17895
|
+
e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML), e.activeFormattingElements.pushElement(e.openElements.current, t);
|
|
17896
17896
|
}
|
|
17897
17897
|
function oE(e, t) {
|
|
17898
|
-
e._reconstructActiveFormattingElements(), e.openElements.hasInScope(o.NOBR) && (Ki(e, t), e._reconstructActiveFormattingElements()), e._insertElement(t,
|
|
17898
|
+
e._reconstructActiveFormattingElements(), e.openElements.hasInScope(o.NOBR) && (Ki(e, t), e._reconstructActiveFormattingElements()), e._insertElement(t, G.HTML), e.activeFormattingElements.pushElement(e.openElements.current, t);
|
|
17899
17899
|
}
|
|
17900
17900
|
function sE(e, t) {
|
|
17901
|
-
e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17901
|
+
e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML), e.activeFormattingElements.insertMarker(), e.framesetOk = !1;
|
|
17902
17902
|
}
|
|
17903
17903
|
function lE(e, t) {
|
|
17904
|
-
e.treeAdapter.getDocumentMode(e.document) !== _t.QUIRKS && e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t,
|
|
17904
|
+
e.treeAdapter.getDocumentMode(e.document) !== _t.QUIRKS && e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._insertElement(t, G.HTML), e.framesetOk = !1, e.insertionMode = O.IN_TABLE;
|
|
17905
17905
|
}
|
|
17906
17906
|
function Mc(e, t) {
|
|
17907
|
-
e._reconstructActiveFormattingElements(), e._appendElement(t,
|
|
17907
|
+
e._reconstructActiveFormattingElements(), e._appendElement(t, G.HTML), e.framesetOk = !1, t.ackSelfClosing = !0;
|
|
17908
17908
|
}
|
|
17909
17909
|
function Fc(e) {
|
|
17910
17910
|
const t = xc(e, on.TYPE);
|
|
17911
17911
|
return t != null && t.toLowerCase() === Ob;
|
|
17912
17912
|
}
|
|
17913
17913
|
function cE(e, t) {
|
|
17914
|
-
e._reconstructActiveFormattingElements(), e._appendElement(t,
|
|
17914
|
+
e._reconstructActiveFormattingElements(), e._appendElement(t, G.HTML), Fc(t) || (e.framesetOk = !1), t.ackSelfClosing = !0;
|
|
17915
17915
|
}
|
|
17916
17916
|
function dE(e, t) {
|
|
17917
|
-
e._appendElement(t,
|
|
17917
|
+
e._appendElement(t, G.HTML), t.ackSelfClosing = !0;
|
|
17918
17918
|
}
|
|
17919
17919
|
function fE(e, t) {
|
|
17920
|
-
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._appendElement(t,
|
|
17920
|
+
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._appendElement(t, G.HTML), e.framesetOk = !1, t.ackSelfClosing = !0;
|
|
17921
17921
|
}
|
|
17922
17922
|
function hE(e, t) {
|
|
17923
17923
|
t.tagName = R.IMG, t.tagID = o.IMG, Mc(e, t);
|
|
17924
17924
|
}
|
|
17925
17925
|
function pE(e, t) {
|
|
17926
|
-
e._insertElement(t,
|
|
17926
|
+
e._insertElement(t, G.HTML), e.skipNextNewLine = !0, e.tokenizer.state = We.RCDATA, e.originalInsertionMode = e.insertionMode, e.framesetOk = !1, e.insertionMode = O.TEXT;
|
|
17927
17927
|
}
|
|
17928
17928
|
function mE(e, t) {
|
|
17929
17929
|
e.openElements.hasInButtonScope(o.P) && e._closePElement(), e._reconstructActiveFormattingElements(), e.framesetOk = !1, e._switchToTextParsing(t, We.RAWTEXT);
|
|
@@ -17935,25 +17935,25 @@ function us(e, t) {
|
|
|
17935
17935
|
e._switchToTextParsing(t, We.RAWTEXT);
|
|
17936
17936
|
}
|
|
17937
17937
|
function bE(e, t) {
|
|
17938
|
-
e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17938
|
+
e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML), e.framesetOk = !1, e.insertionMode = e.insertionMode === O.IN_TABLE || e.insertionMode === O.IN_CAPTION || e.insertionMode === O.IN_TABLE_BODY || e.insertionMode === O.IN_ROW || e.insertionMode === O.IN_CELL ? O.IN_SELECT_IN_TABLE : O.IN_SELECT;
|
|
17939
17939
|
}
|
|
17940
17940
|
function EE(e, t) {
|
|
17941
|
-
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17941
|
+
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML);
|
|
17942
17942
|
}
|
|
17943
17943
|
function TE(e, t) {
|
|
17944
|
-
e.openElements.hasInScope(o.RUBY) && e.openElements.generateImpliedEndTags(), e._insertElement(t,
|
|
17944
|
+
e.openElements.hasInScope(o.RUBY) && e.openElements.generateImpliedEndTags(), e._insertElement(t, G.HTML);
|
|
17945
17945
|
}
|
|
17946
17946
|
function yE(e, t) {
|
|
17947
|
-
e.openElements.hasInScope(o.RUBY) && e.openElements.generateImpliedEndTagsWithExclusion(o.RTC), e._insertElement(t,
|
|
17947
|
+
e.openElements.hasInScope(o.RUBY) && e.openElements.generateImpliedEndTagsWithExclusion(o.RTC), e._insertElement(t, G.HTML);
|
|
17948
17948
|
}
|
|
17949
17949
|
function _E(e, t) {
|
|
17950
|
-
e._reconstructActiveFormattingElements(), Lc(t), Xi(t), t.selfClosing ? e._appendElement(t,
|
|
17950
|
+
e._reconstructActiveFormattingElements(), Lc(t), Xi(t), t.selfClosing ? e._appendElement(t, G.MATHML) : e._insertElement(t, G.MATHML), t.ackSelfClosing = !0;
|
|
17951
17951
|
}
|
|
17952
17952
|
function CE(e, t) {
|
|
17953
|
-
e._reconstructActiveFormattingElements(), wc(t), Xi(t), t.selfClosing ? e._appendElement(t,
|
|
17953
|
+
e._reconstructActiveFormattingElements(), wc(t), Xi(t), t.selfClosing ? e._appendElement(t, G.SVG) : e._insertElement(t, G.SVG), t.ackSelfClosing = !0;
|
|
17954
17954
|
}
|
|
17955
17955
|
function os(e, t) {
|
|
17956
|
-
e._reconstructActiveFormattingElements(), e._insertElement(t,
|
|
17956
|
+
e._reconstructActiveFormattingElements(), e._insertElement(t, G.HTML);
|
|
17957
17957
|
}
|
|
17958
17958
|
function it(e, t) {
|
|
17959
17959
|
switch (t.tagID) {
|
|
@@ -18323,7 +18323,7 @@ function RE(e, t) {
|
|
|
18323
18323
|
t.tagID === o.SCRIPT && ((n = e.scriptHandler) === null || n === void 0 || n.call(e, e.openElements.current)), e.openElements.pop(), e.insertionMode = e.originalInsertionMode;
|
|
18324
18324
|
}
|
|
18325
18325
|
function DE(e, t) {
|
|
18326
|
-
e._err(t,
|
|
18326
|
+
e._err(t, j.eofInElementThatCanContainOnlyText), e.openElements.pop(), e.insertionMode = e.originalInsertionMode, e.onEof(t);
|
|
18327
18327
|
}
|
|
18328
18328
|
function qa(e, t) {
|
|
18329
18329
|
if (e.openElements.currentTagId !== void 0 && Rc.has(e.openElements.currentTagId))
|
|
@@ -18341,16 +18341,16 @@ function qa(e, t) {
|
|
|
18341
18341
|
gr(e, t);
|
|
18342
18342
|
}
|
|
18343
18343
|
function PE(e, t) {
|
|
18344
|
-
e.openElements.clearBackToTableContext(), e.activeFormattingElements.insertMarker(), e._insertElement(t,
|
|
18344
|
+
e.openElements.clearBackToTableContext(), e.activeFormattingElements.insertMarker(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_CAPTION;
|
|
18345
18345
|
}
|
|
18346
18346
|
function ME(e, t) {
|
|
18347
|
-
e.openElements.clearBackToTableContext(), e._insertElement(t,
|
|
18347
|
+
e.openElements.clearBackToTableContext(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_COLUMN_GROUP;
|
|
18348
18348
|
}
|
|
18349
18349
|
function FE(e, t) {
|
|
18350
18350
|
e.openElements.clearBackToTableContext(), e._insertFakeElement(R.COLGROUP, o.COLGROUP), e.insertionMode = O.IN_COLUMN_GROUP, Zi(e, t);
|
|
18351
18351
|
}
|
|
18352
18352
|
function BE(e, t) {
|
|
18353
|
-
e.openElements.clearBackToTableContext(), e._insertElement(t,
|
|
18353
|
+
e.openElements.clearBackToTableContext(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_TABLE_BODY;
|
|
18354
18354
|
}
|
|
18355
18355
|
function HE(e, t) {
|
|
18356
18356
|
e.openElements.clearBackToTableContext(), e._insertFakeElement(R.TBODY, o.TBODY), e.insertionMode = O.IN_TABLE_BODY, ra(e, t);
|
|
@@ -18359,10 +18359,10 @@ function UE(e, t) {
|
|
|
18359
18359
|
e.openElements.hasInTableScope(o.TABLE) && (e.openElements.popUntilTagNamePopped(o.TABLE), e._resetInsertionMode(), e._processStartTag(t));
|
|
18360
18360
|
}
|
|
18361
18361
|
function jE(e, t) {
|
|
18362
|
-
Fc(t) ? e._appendElement(t,
|
|
18362
|
+
Fc(t) ? e._appendElement(t, G.HTML) : gr(e, t), t.ackSelfClosing = !0;
|
|
18363
18363
|
}
|
|
18364
18364
|
function qE(e, t) {
|
|
18365
|
-
!e.formElement && e.openElements.tmplCount === 0 && (e._insertElement(t,
|
|
18365
|
+
!e.formElement && e.openElements.tmplCount === 0 && (e._insertElement(t, G.HTML), e.formElement = e.openElements.current, e.openElements.pop());
|
|
18366
18366
|
}
|
|
18367
18367
|
function On(e, t) {
|
|
18368
18368
|
switch (t.tagID) {
|
|
@@ -18493,7 +18493,7 @@ function Zi(e, t) {
|
|
|
18493
18493
|
break;
|
|
18494
18494
|
}
|
|
18495
18495
|
case o.COL: {
|
|
18496
|
-
e._appendElement(t,
|
|
18496
|
+
e._appendElement(t, G.HTML), t.ackSelfClosing = !0;
|
|
18497
18497
|
break;
|
|
18498
18498
|
}
|
|
18499
18499
|
case o.TEMPLATE: {
|
|
@@ -18526,7 +18526,7 @@ function Wr(e, t) {
|
|
|
18526
18526
|
function ra(e, t) {
|
|
18527
18527
|
switch (t.tagID) {
|
|
18528
18528
|
case o.TR: {
|
|
18529
|
-
e.openElements.clearBackToTableBodyContext(), e._insertElement(t,
|
|
18529
|
+
e.openElements.clearBackToTableBodyContext(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_ROW;
|
|
18530
18530
|
break;
|
|
18531
18531
|
}
|
|
18532
18532
|
case o.TH:
|
|
@@ -18577,7 +18577,7 @@ function aa(e, t) {
|
|
|
18577
18577
|
switch (t.tagID) {
|
|
18578
18578
|
case o.TH:
|
|
18579
18579
|
case o.TD: {
|
|
18580
|
-
e.openElements.clearBackToTableRowContext(), e._insertElement(t,
|
|
18580
|
+
e.openElements.clearBackToTableRowContext(), e._insertElement(t, G.HTML), e.insertionMode = O.IN_CELL, e.activeFormattingElements.insertMarker();
|
|
18581
18581
|
break;
|
|
18582
18582
|
}
|
|
18583
18583
|
case o.CAPTION:
|
|
@@ -18659,15 +18659,15 @@ function Yc(e, t) {
|
|
|
18659
18659
|
break;
|
|
18660
18660
|
}
|
|
18661
18661
|
case o.OPTION: {
|
|
18662
|
-
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e._insertElement(t,
|
|
18662
|
+
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e._insertElement(t, G.HTML);
|
|
18663
18663
|
break;
|
|
18664
18664
|
}
|
|
18665
18665
|
case o.OPTGROUP: {
|
|
18666
|
-
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e.openElements.currentTagId === o.OPTGROUP && e.openElements.pop(), e._insertElement(t,
|
|
18666
|
+
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e.openElements.currentTagId === o.OPTGROUP && e.openElements.pop(), e._insertElement(t, G.HTML);
|
|
18667
18667
|
break;
|
|
18668
18668
|
}
|
|
18669
18669
|
case o.HR: {
|
|
18670
|
-
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e.openElements.currentTagId === o.OPTGROUP && e.openElements.pop(), e._appendElement(t,
|
|
18670
|
+
e.openElements.currentTagId === o.OPTION && e.openElements.pop(), e.openElements.currentTagId === o.OPTGROUP && e.openElements.pop(), e._appendElement(t, G.HTML), t.ackSelfClosing = !0;
|
|
18671
18671
|
break;
|
|
18672
18672
|
}
|
|
18673
18673
|
case o.INPUT:
|
|
@@ -18784,11 +18784,11 @@ function JE(e, t) {
|
|
|
18784
18784
|
break;
|
|
18785
18785
|
}
|
|
18786
18786
|
case o.FRAMESET: {
|
|
18787
|
-
e._insertElement(t,
|
|
18787
|
+
e._insertElement(t, G.HTML);
|
|
18788
18788
|
break;
|
|
18789
18789
|
}
|
|
18790
18790
|
case o.FRAME: {
|
|
18791
|
-
e._appendElement(t,
|
|
18791
|
+
e._appendElement(t, G.HTML), t.ackSelfClosing = !0;
|
|
18792
18792
|
break;
|
|
18793
18793
|
}
|
|
18794
18794
|
case o.NOFRAMES: {
|
|
@@ -18840,7 +18840,7 @@ function uT(e, t) {
|
|
|
18840
18840
|
e._insertCharacters(t), e.framesetOk = !1;
|
|
18841
18841
|
}
|
|
18842
18842
|
function Gc(e) {
|
|
18843
|
-
for (; e.treeAdapter.getNamespaceURI(e.openElements.current) !==
|
|
18843
|
+
for (; e.treeAdapter.getNamespaceURI(e.openElements.current) !== G.HTML && e.openElements.currentTagId !== void 0 && !e._isIntegrationPoint(e.openElements.currentTagId, e.openElements.current); )
|
|
18844
18844
|
e.openElements.pop();
|
|
18845
18845
|
}
|
|
18846
18846
|
function oT(e, t) {
|
|
@@ -18848,7 +18848,7 @@ function oT(e, t) {
|
|
|
18848
18848
|
Gc(e), e._startTagOutsideForeignContent(t);
|
|
18849
18849
|
else {
|
|
18850
18850
|
const n = e._getAdjustedCurrentElement(), r = e.treeAdapter.getNamespaceURI(n);
|
|
18851
|
-
r ===
|
|
18851
|
+
r === G.MATHML ? Lc(t) : r === G.SVG && (Ab(t), wc(t)), Xi(t), t.selfClosing ? e._appendElement(t, r) : e._insertElement(t, r), t.ackSelfClosing = !0;
|
|
18852
18852
|
}
|
|
18853
18853
|
}
|
|
18854
18854
|
function sT(e, t) {
|
|
@@ -18858,7 +18858,7 @@ function sT(e, t) {
|
|
|
18858
18858
|
}
|
|
18859
18859
|
for (let n = e.openElements.stackTop; n > 0; n--) {
|
|
18860
18860
|
const r = e.openElements.items[n];
|
|
18861
|
-
if (e.treeAdapter.getNamespaceURI(r) ===
|
|
18861
|
+
if (e.treeAdapter.getNamespaceURI(r) === G.HTML) {
|
|
18862
18862
|
e._endTagOutsideForeignContent(t);
|
|
18863
18863
|
break;
|
|
18864
18864
|
}
|
|
@@ -19234,95 +19234,95 @@ function DT() {
|
|
|
19234
19234
|
e.exports = r();
|
|
19235
19235
|
})(RT, (function() {
|
|
19236
19236
|
var n = 1e3, r = 6e4, a = 36e5, i = "millisecond", u = "second", s = "minute", l = "hour", c = "day", d = "week", f = "month", p = "quarter", h = "year", b = "date", m = "Invalid Date", T = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, g = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, D = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(I) {
|
|
19237
|
-
var
|
|
19238
|
-
return "[" + I + (
|
|
19239
|
-
} }, P = function(I,
|
|
19240
|
-
var
|
|
19241
|
-
return !
|
|
19242
|
-
},
|
|
19243
|
-
var
|
|
19244
|
-
return (
|
|
19245
|
-
}, m: function I(
|
|
19246
|
-
if (
|
|
19247
|
-
var
|
|
19248
|
-
return +(-(
|
|
19237
|
+
var L = ["th", "st", "nd", "rd"], B = I % 100;
|
|
19238
|
+
return "[" + I + (L[(B - 20) % 10] || L[B] || L[0]) + "]";
|
|
19239
|
+
} }, P = function(I, L, B) {
|
|
19240
|
+
var W = String(I);
|
|
19241
|
+
return !W || W.length >= L ? I : "" + Array(L + 1 - W.length).join(B) + I;
|
|
19242
|
+
}, X = { s: P, z: function(I) {
|
|
19243
|
+
var L = -I.utcOffset(), B = Math.abs(L), W = Math.floor(B / 60), H = B % 60;
|
|
19244
|
+
return (L <= 0 ? "+" : "-") + P(W, 2, "0") + ":" + P(H, 2, "0");
|
|
19245
|
+
}, m: function I(L, B) {
|
|
19246
|
+
if (L.date() < B.date()) return -I(B, L);
|
|
19247
|
+
var W = 12 * (B.year() - L.year()) + (B.month() - L.month()), H = L.clone().add(W, f), z = B - H < 0, y = L.clone().add(W + (z ? -1 : 1), f);
|
|
19248
|
+
return +(-(W + (B - H) / (z ? H - y : y - H)) || 0);
|
|
19249
19249
|
}, a: function(I) {
|
|
19250
19250
|
return I < 0 ? Math.ceil(I) || 0 : Math.floor(I);
|
|
19251
19251
|
}, p: function(I) {
|
|
19252
19252
|
return { M: f, y: h, w: d, d: c, D: b, h: l, m: s, s: u, ms: i, Q: p }[I] || String(I || "").toLowerCase().replace(/s$/, "");
|
|
19253
19253
|
}, u: function(I) {
|
|
19254
19254
|
return I === void 0;
|
|
19255
|
-
} },
|
|
19256
|
-
x[
|
|
19257
|
-
var
|
|
19258
|
-
return I instanceof $ || !(!I || !I[
|
|
19259
|
-
}, q = function I(
|
|
19260
|
-
var
|
|
19261
|
-
if (!
|
|
19262
|
-
if (typeof
|
|
19263
|
-
var z =
|
|
19264
|
-
x[z] && (
|
|
19265
|
-
var y =
|
|
19266
|
-
if (!
|
|
19255
|
+
} }, F = "en", x = {};
|
|
19256
|
+
x[F] = D;
|
|
19257
|
+
var w = "$isDayjsObject", V = function(I) {
|
|
19258
|
+
return I instanceof $ || !(!I || !I[w]);
|
|
19259
|
+
}, q = function I(L, B, W) {
|
|
19260
|
+
var H;
|
|
19261
|
+
if (!L) return F;
|
|
19262
|
+
if (typeof L == "string") {
|
|
19263
|
+
var z = L.toLowerCase();
|
|
19264
|
+
x[z] && (H = z), B && (x[z] = B, H = z);
|
|
19265
|
+
var y = L.split("-");
|
|
19266
|
+
if (!H && y.length > 1) return I(y[0]);
|
|
19267
19267
|
} else {
|
|
19268
|
-
var ne =
|
|
19269
|
-
x[ne] =
|
|
19268
|
+
var ne = L.name;
|
|
19269
|
+
x[ne] = L, H = ne;
|
|
19270
19270
|
}
|
|
19271
|
-
return !
|
|
19272
|
-
}, te = function(I,
|
|
19273
|
-
if (
|
|
19274
|
-
var
|
|
19275
|
-
return
|
|
19276
|
-
}, Y =
|
|
19277
|
-
Y.l = q, Y.i =
|
|
19278
|
-
return te(I, { locale:
|
|
19271
|
+
return !W && H && (F = H), H || !W && F;
|
|
19272
|
+
}, te = function(I, L) {
|
|
19273
|
+
if (V(I)) return I.clone();
|
|
19274
|
+
var B = typeof L == "object" ? L : {};
|
|
19275
|
+
return B.date = I, B.args = arguments, new $(B);
|
|
19276
|
+
}, Y = X;
|
|
19277
|
+
Y.l = q, Y.i = V, Y.w = function(I, L) {
|
|
19278
|
+
return te(I, { locale: L.$L, utc: L.$u, x: L.$x, $offset: L.$offset });
|
|
19279
19279
|
};
|
|
19280
19280
|
var $ = (function() {
|
|
19281
|
-
function I(
|
|
19282
|
-
this.$L = q(
|
|
19281
|
+
function I(B) {
|
|
19282
|
+
this.$L = q(B.locale, null, !0), this.parse(B), this.$x = this.$x || B.x || {}, this[w] = !0;
|
|
19283
19283
|
}
|
|
19284
|
-
var
|
|
19285
|
-
return
|
|
19286
|
-
this.$d = (function(
|
|
19287
|
-
var
|
|
19288
|
-
if (
|
|
19289
|
-
if (Y.u(
|
|
19290
|
-
if (
|
|
19291
|
-
if (typeof
|
|
19292
|
-
var y =
|
|
19284
|
+
var L = I.prototype;
|
|
19285
|
+
return L.parse = function(B) {
|
|
19286
|
+
this.$d = (function(W) {
|
|
19287
|
+
var H = W.date, z = W.utc;
|
|
19288
|
+
if (H === null) return /* @__PURE__ */ new Date(NaN);
|
|
19289
|
+
if (Y.u(H)) return /* @__PURE__ */ new Date();
|
|
19290
|
+
if (H instanceof Date) return new Date(H);
|
|
19291
|
+
if (typeof H == "string" && !/Z$/i.test(H)) {
|
|
19292
|
+
var y = H.match(T);
|
|
19293
19293
|
if (y) {
|
|
19294
19294
|
var ne = y[2] - 1 || 0, ae = (y[7] || "0").substring(0, 3);
|
|
19295
19295
|
return z ? new Date(Date.UTC(y[1], ne, y[3] || 1, y[4] || 0, y[5] || 0, y[6] || 0, ae)) : new Date(y[1], ne, y[3] || 1, y[4] || 0, y[5] || 0, y[6] || 0, ae);
|
|
19296
19296
|
}
|
|
19297
19297
|
}
|
|
19298
|
-
return new Date(
|
|
19299
|
-
})(
|
|
19300
|
-
},
|
|
19301
|
-
var
|
|
19302
|
-
this.$y =
|
|
19303
|
-
},
|
|
19298
|
+
return new Date(H);
|
|
19299
|
+
})(B), this.init();
|
|
19300
|
+
}, L.init = function() {
|
|
19301
|
+
var B = this.$d;
|
|
19302
|
+
this.$y = B.getFullYear(), this.$M = B.getMonth(), this.$D = B.getDate(), this.$W = B.getDay(), this.$H = B.getHours(), this.$m = B.getMinutes(), this.$s = B.getSeconds(), this.$ms = B.getMilliseconds();
|
|
19303
|
+
}, L.$utils = function() {
|
|
19304
19304
|
return Y;
|
|
19305
|
-
},
|
|
19305
|
+
}, L.isValid = function() {
|
|
19306
19306
|
return this.$d.toString() !== m;
|
|
19307
|
-
},
|
|
19308
|
-
var
|
|
19309
|
-
return this.startOf(
|
|
19310
|
-
},
|
|
19311
|
-
return te(
|
|
19312
|
-
},
|
|
19313
|
-
return this.endOf(
|
|
19314
|
-
},
|
|
19315
|
-
return Y.u(
|
|
19316
|
-
},
|
|
19307
|
+
}, L.isSame = function(B, W) {
|
|
19308
|
+
var H = te(B);
|
|
19309
|
+
return this.startOf(W) <= H && H <= this.endOf(W);
|
|
19310
|
+
}, L.isAfter = function(B, W) {
|
|
19311
|
+
return te(B) < this.startOf(W);
|
|
19312
|
+
}, L.isBefore = function(B, W) {
|
|
19313
|
+
return this.endOf(W) < te(B);
|
|
19314
|
+
}, L.$g = function(B, W, H) {
|
|
19315
|
+
return Y.u(B) ? this[W] : this.set(H, B);
|
|
19316
|
+
}, L.unix = function() {
|
|
19317
19317
|
return Math.floor(this.valueOf() / 1e3);
|
|
19318
|
-
},
|
|
19318
|
+
}, L.valueOf = function() {
|
|
19319
19319
|
return this.$d.getTime();
|
|
19320
|
-
},
|
|
19321
|
-
var
|
|
19322
|
-
var nt = Y.w(
|
|
19320
|
+
}, L.startOf = function(B, W) {
|
|
19321
|
+
var H = this, z = !!Y.u(W) || W, y = Y.p(B), ne = function(ze, Ie) {
|
|
19322
|
+
var nt = Y.w(H.$u ? Date.UTC(H.$y, Ie, ze) : new Date(H.$y, Ie, ze), H);
|
|
19323
19323
|
return z ? nt : nt.endOf(c);
|
|
19324
19324
|
}, ae = function(ze, Ie) {
|
|
19325
|
-
return Y.w(
|
|
19325
|
+
return Y.w(H.toDate()[ze].apply(H.toDate("s"), (z ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(Ie)), H);
|
|
19326
19326
|
}, v = this.$W, se = this.$M, _e = this.$D, pe = "set" + (this.$u ? "UTC" : "");
|
|
19327
19327
|
switch (y) {
|
|
19328
19328
|
case h:
|
|
@@ -19344,39 +19344,39 @@ function DT() {
|
|
|
19344
19344
|
default:
|
|
19345
19345
|
return this.clone();
|
|
19346
19346
|
}
|
|
19347
|
-
},
|
|
19348
|
-
return this.startOf(
|
|
19349
|
-
},
|
|
19350
|
-
var
|
|
19347
|
+
}, L.endOf = function(B) {
|
|
19348
|
+
return this.startOf(B, !1);
|
|
19349
|
+
}, L.$set = function(B, W) {
|
|
19350
|
+
var H, z = Y.p(B), y = "set" + (this.$u ? "UTC" : ""), ne = (H = {}, H[c] = y + "Date", H[b] = y + "Date", H[f] = y + "Month", H[h] = y + "FullYear", H[l] = y + "Hours", H[s] = y + "Minutes", H[u] = y + "Seconds", H[i] = y + "Milliseconds", H)[z], ae = z === c ? this.$D + (W - this.$W) : W;
|
|
19351
19351
|
if (z === f || z === h) {
|
|
19352
19352
|
var v = this.clone().set(b, 1);
|
|
19353
19353
|
v.$d[ne](ae), v.init(), this.$d = v.set(b, Math.min(this.$D, v.daysInMonth())).$d;
|
|
19354
19354
|
} else ne && this.$d[ne](ae);
|
|
19355
19355
|
return this.init(), this;
|
|
19356
|
-
},
|
|
19357
|
-
return this.clone().$set(
|
|
19358
|
-
},
|
|
19359
|
-
return this[Y.p(
|
|
19360
|
-
},
|
|
19361
|
-
var
|
|
19362
|
-
|
|
19363
|
-
var y = Y.p(
|
|
19356
|
+
}, L.set = function(B, W) {
|
|
19357
|
+
return this.clone().$set(B, W);
|
|
19358
|
+
}, L.get = function(B) {
|
|
19359
|
+
return this[Y.p(B)]();
|
|
19360
|
+
}, L.add = function(B, W) {
|
|
19361
|
+
var H, z = this;
|
|
19362
|
+
B = Number(B);
|
|
19363
|
+
var y = Y.p(W), ne = function(se) {
|
|
19364
19364
|
var _e = te(z);
|
|
19365
|
-
return Y.w(_e.date(_e.date() + Math.round(se *
|
|
19365
|
+
return Y.w(_e.date(_e.date() + Math.round(se * B)), z);
|
|
19366
19366
|
};
|
|
19367
|
-
if (y === f) return this.set(f, this.$M +
|
|
19368
|
-
if (y === h) return this.set(h, this.$y +
|
|
19367
|
+
if (y === f) return this.set(f, this.$M + B);
|
|
19368
|
+
if (y === h) return this.set(h, this.$y + B);
|
|
19369
19369
|
if (y === c) return ne(1);
|
|
19370
19370
|
if (y === d) return ne(7);
|
|
19371
|
-
var ae = (
|
|
19371
|
+
var ae = (H = {}, H[s] = r, H[l] = a, H[u] = n, H)[y] || 1, v = this.$d.getTime() + B * ae;
|
|
19372
19372
|
return Y.w(v, this);
|
|
19373
|
-
},
|
|
19374
|
-
return this.add(-1 *
|
|
19375
|
-
},
|
|
19376
|
-
var
|
|
19377
|
-
if (!this.isValid()) return
|
|
19378
|
-
var z =
|
|
19379
|
-
return Ie && (Ie[nt] || Ie(
|
|
19373
|
+
}, L.subtract = function(B, W) {
|
|
19374
|
+
return this.add(-1 * B, W);
|
|
19375
|
+
}, L.format = function(B) {
|
|
19376
|
+
var W = this, H = this.$locale();
|
|
19377
|
+
if (!this.isValid()) return H.invalidDate || m;
|
|
19378
|
+
var z = B || "YYYY-MM-DDTHH:mm:ssZ", y = Y.z(this), ne = this.$H, ae = this.$m, v = this.$M, se = H.weekdays, _e = H.months, pe = H.meridiem, Se = function(Ie, nt, st, wt) {
|
|
19379
|
+
return Ie && (Ie[nt] || Ie(W, z)) || st[nt].slice(0, wt);
|
|
19380
19380
|
}, Oe = function(Ie) {
|
|
19381
19381
|
return Y.s(ne % 12 || 12, Ie, "0");
|
|
19382
19382
|
}, ze = pe || function(Ie, nt, st) {
|
|
@@ -19387,29 +19387,29 @@ function DT() {
|
|
|
19387
19387
|
return nt || (function(st) {
|
|
19388
19388
|
switch (st) {
|
|
19389
19389
|
case "YY":
|
|
19390
|
-
return String(
|
|
19390
|
+
return String(W.$y).slice(-2);
|
|
19391
19391
|
case "YYYY":
|
|
19392
|
-
return Y.s(
|
|
19392
|
+
return Y.s(W.$y, 4, "0");
|
|
19393
19393
|
case "M":
|
|
19394
19394
|
return v + 1;
|
|
19395
19395
|
case "MM":
|
|
19396
19396
|
return Y.s(v + 1, 2, "0");
|
|
19397
19397
|
case "MMM":
|
|
19398
|
-
return Se(
|
|
19398
|
+
return Se(H.monthsShort, v, _e, 3);
|
|
19399
19399
|
case "MMMM":
|
|
19400
19400
|
return Se(_e, v);
|
|
19401
19401
|
case "D":
|
|
19402
|
-
return
|
|
19402
|
+
return W.$D;
|
|
19403
19403
|
case "DD":
|
|
19404
|
-
return Y.s(
|
|
19404
|
+
return Y.s(W.$D, 2, "0");
|
|
19405
19405
|
case "d":
|
|
19406
|
-
return String(
|
|
19406
|
+
return String(W.$W);
|
|
19407
19407
|
case "dd":
|
|
19408
|
-
return Se(
|
|
19408
|
+
return Se(H.weekdaysMin, W.$W, se, 2);
|
|
19409
19409
|
case "ddd":
|
|
19410
|
-
return Se(
|
|
19410
|
+
return Se(H.weekdaysShort, W.$W, se, 3);
|
|
19411
19411
|
case "dddd":
|
|
19412
|
-
return se[
|
|
19412
|
+
return se[W.$W];
|
|
19413
19413
|
case "H":
|
|
19414
19414
|
return String(ne);
|
|
19415
19415
|
case "HH":
|
|
@@ -19427,21 +19427,21 @@ function DT() {
|
|
|
19427
19427
|
case "mm":
|
|
19428
19428
|
return Y.s(ae, 2, "0");
|
|
19429
19429
|
case "s":
|
|
19430
|
-
return String(
|
|
19430
|
+
return String(W.$s);
|
|
19431
19431
|
case "ss":
|
|
19432
|
-
return Y.s(
|
|
19432
|
+
return Y.s(W.$s, 2, "0");
|
|
19433
19433
|
case "SSS":
|
|
19434
|
-
return Y.s(
|
|
19434
|
+
return Y.s(W.$ms, 3, "0");
|
|
19435
19435
|
case "Z":
|
|
19436
19436
|
return y;
|
|
19437
19437
|
}
|
|
19438
19438
|
return null;
|
|
19439
19439
|
})(Ie) || y.replace(":", "");
|
|
19440
19440
|
}));
|
|
19441
|
-
},
|
|
19441
|
+
}, L.utcOffset = function() {
|
|
19442
19442
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
19443
|
-
},
|
|
19444
|
-
var z, y = this, ne = Y.p(
|
|
19443
|
+
}, L.diff = function(B, W, H) {
|
|
19444
|
+
var z, y = this, ne = Y.p(W), ae = te(B), v = (ae.utcOffset() - this.utcOffset()) * r, se = this - ae, _e = function() {
|
|
19445
19445
|
return Y.m(y, ae);
|
|
19446
19446
|
};
|
|
19447
19447
|
switch (ne) {
|
|
@@ -19472,36 +19472,36 @@ function DT() {
|
|
|
19472
19472
|
default:
|
|
19473
19473
|
z = se;
|
|
19474
19474
|
}
|
|
19475
|
-
return
|
|
19476
|
-
},
|
|
19475
|
+
return H ? z : Y.a(z);
|
|
19476
|
+
}, L.daysInMonth = function() {
|
|
19477
19477
|
return this.endOf(f).$D;
|
|
19478
|
-
},
|
|
19478
|
+
}, L.$locale = function() {
|
|
19479
19479
|
return x[this.$L];
|
|
19480
|
-
},
|
|
19481
|
-
if (!
|
|
19482
|
-
var
|
|
19483
|
-
return z && (
|
|
19484
|
-
},
|
|
19480
|
+
}, L.locale = function(B, W) {
|
|
19481
|
+
if (!B) return this.$L;
|
|
19482
|
+
var H = this.clone(), z = q(B, W, !0);
|
|
19483
|
+
return z && (H.$L = z), H;
|
|
19484
|
+
}, L.clone = function() {
|
|
19485
19485
|
return Y.w(this.$d, this);
|
|
19486
|
-
},
|
|
19486
|
+
}, L.toDate = function() {
|
|
19487
19487
|
return new Date(this.valueOf());
|
|
19488
|
-
},
|
|
19488
|
+
}, L.toJSON = function() {
|
|
19489
19489
|
return this.isValid() ? this.toISOString() : null;
|
|
19490
|
-
},
|
|
19490
|
+
}, L.toISOString = function() {
|
|
19491
19491
|
return this.$d.toISOString();
|
|
19492
|
-
},
|
|
19492
|
+
}, L.toString = function() {
|
|
19493
19493
|
return this.$d.toUTCString();
|
|
19494
19494
|
}, I;
|
|
19495
|
-
})(),
|
|
19496
|
-
return te.prototype =
|
|
19497
|
-
|
|
19498
|
-
return this.$g(
|
|
19495
|
+
})(), k = $.prototype;
|
|
19496
|
+
return te.prototype = k, [["$ms", i], ["$s", u], ["$m", s], ["$H", l], ["$W", c], ["$M", f], ["$y", h], ["$D", b]].forEach((function(I) {
|
|
19497
|
+
k[I[1]] = function(L) {
|
|
19498
|
+
return this.$g(L, I[0], I[1]);
|
|
19499
19499
|
};
|
|
19500
|
-
})), te.extend = function(I,
|
|
19501
|
-
return I.$i || (I(
|
|
19502
|
-
}, te.locale = q, te.isDayjs =
|
|
19500
|
+
})), te.extend = function(I, L) {
|
|
19501
|
+
return I.$i || (I(L, $, te), I.$i = !0), te;
|
|
19502
|
+
}, te.locale = q, te.isDayjs = V, te.unix = function(I) {
|
|
19503
19503
|
return te(1e3 * I);
|
|
19504
|
-
}, te.en = x[
|
|
19504
|
+
}, te.en = x[F], te.Ls = x, te.p = {}, te;
|
|
19505
19505
|
}));
|
|
19506
19506
|
})(Br)), Br.exports;
|
|
19507
19507
|
}
|
|
@@ -19965,14 +19965,14 @@ const GT = (e) => ({
|
|
|
19965
19965
|
d?.userMessageBubble?.style
|
|
19966
19966
|
),
|
|
19967
19967
|
[c, d?.userMessageBubble?.style]
|
|
19968
|
-
),
|
|
19968
|
+
), X = un(
|
|
19969
19969
|
() => GT(l)(f),
|
|
19970
19970
|
[f, l]
|
|
19971
|
-
),
|
|
19971
|
+
), F = un(() => {
|
|
19972
19972
|
if (!D) return null;
|
|
19973
19973
|
if (T === ve.USER)
|
|
19974
|
-
return
|
|
19975
|
-
const x = XT(
|
|
19974
|
+
return X;
|
|
19975
|
+
const x = XT(X);
|
|
19976
19976
|
return /* @__PURE__ */ _.jsx(
|
|
19977
19977
|
Ui,
|
|
19978
19978
|
{
|
|
@@ -19988,7 +19988,7 @@ const GT = (e) => ({
|
|
|
19988
19988
|
);
|
|
19989
19989
|
}, [
|
|
19990
19990
|
D,
|
|
19991
|
-
|
|
19991
|
+
X,
|
|
19992
19992
|
i,
|
|
19993
19993
|
P,
|
|
19994
19994
|
T
|
|
@@ -20021,7 +20021,7 @@ const GT = (e) => ({
|
|
|
20021
20021
|
className: P[T].bubbleClassName,
|
|
20022
20022
|
style: P[T].bubbleStyle,
|
|
20023
20023
|
children: [
|
|
20024
|
-
|
|
20024
|
+
F,
|
|
20025
20025
|
g && /* @__PURE__ */ _.jsxs(_.Fragment, { children: [
|
|
20026
20026
|
/* @__PURE__ */ _.jsx("div", { children: KT }),
|
|
20027
20027
|
/* @__PURE__ */ _.jsx(
|
|
@@ -20668,9 +20668,9 @@ function JT() {
|
|
|
20668
20668
|
return m && window.clearTimeout(m);
|
|
20669
20669
|
};
|
|
20670
20670
|
}, c = function(d, f, p, h, b, m, T) {
|
|
20671
|
-
var g = f.setLastMessage, D = f.setReadyState, P,
|
|
20672
|
-
return p.current.fromSocketIO && (P = (0, t.setUpSocketIOPing)(T)), i(d, p, g, m), u(d, p, D, b, m),
|
|
20673
|
-
D(r.ReadyState.CLOSING),
|
|
20671
|
+
var g = f.setLastMessage, D = f.setReadyState, P, X, F;
|
|
20672
|
+
return p.current.fromSocketIO && (P = (0, t.setUpSocketIOPing)(T)), i(d, p, g, m), u(d, p, D, b, m), X = s(d, p, D, h, b), F = l(d, p, D, h, b), function() {
|
|
20673
|
+
D(r.ReadyState.CLOSING), X(), F(), d.close(), P && clearInterval(P);
|
|
20674
20674
|
};
|
|
20675
20675
|
};
|
|
20676
20676
|
return en.attachListeners = c, en;
|
|
@@ -20882,22 +20882,22 @@ function n3() {
|
|
|
20882
20882
|
for (var d = [], f = 2; f < arguments.length; f++)
|
|
20883
20883
|
d[f - 2] = arguments[f];
|
|
20884
20884
|
return t(void 0, r([l, c], d, !0), void 0, function(p, h, b) {
|
|
20885
|
-
var m, T, g, D, P,
|
|
20886
|
-
return b === void 0 && (b = 0), n(this, function(
|
|
20887
|
-
switch (
|
|
20885
|
+
var m, T, g, D, P, X, F, x;
|
|
20886
|
+
return b === void 0 && (b = 0), n(this, function(w) {
|
|
20887
|
+
switch (w.label) {
|
|
20888
20888
|
case 0:
|
|
20889
20889
|
if (typeof p != "function") return [3, 10];
|
|
20890
|
-
|
|
20890
|
+
w.label = 1;
|
|
20891
20891
|
case 1:
|
|
20892
|
-
return
|
|
20892
|
+
return w.trys.push([1, 3, , 9]), [4, p()];
|
|
20893
20893
|
case 2:
|
|
20894
|
-
return m =
|
|
20894
|
+
return m = w.sent(), [3, 9];
|
|
20895
20895
|
case 3:
|
|
20896
|
-
return
|
|
20896
|
+
return w.sent(), h.current.retryOnError ? (T = (X = h.current.reconnectAttempts) !== null && X !== void 0 ? X : i.DEFAULT_RECONNECT_LIMIT, b < T ? (g = typeof h.current.reconnectInterval == "function" ? h.current.reconnectInterval(b) : h.current.reconnectInterval, [4, u(g ?? i.DEFAULT_RECONNECT_INTERVAL_MS)]) : [3, 5]) : [3, 7];
|
|
20897
20897
|
case 4:
|
|
20898
|
-
return
|
|
20898
|
+
return w.sent(), [2, (0, e.getUrl)(p, h, b + 1)];
|
|
20899
20899
|
case 5:
|
|
20900
|
-
return (x = (
|
|
20900
|
+
return (x = (F = h.current).onReconnectStop) === null || x === void 0 || x.call(F, b), [2, null];
|
|
20901
20901
|
case 6:
|
|
20902
20902
|
return [3, 8];
|
|
20903
20903
|
case 7:
|
|
@@ -20907,7 +20907,7 @@ function n3() {
|
|
|
20907
20907
|
case 9:
|
|
20908
20908
|
return [3, 11];
|
|
20909
20909
|
case 10:
|
|
20910
|
-
m = p,
|
|
20910
|
+
m = p, w.label = 11;
|
|
20911
20911
|
case 11:
|
|
20912
20912
|
return D = h.current.fromSocketIO ? (0, a.parseSocketIOUrl)(m) : m, P = h.current.queryParams ? (0, a.appendQueryParams)(D, h.current.queryParams) : D, [2, P];
|
|
20913
20913
|
}
|
|
@@ -20957,22 +20957,22 @@ function su() {
|
|
|
20957
20957
|
return new (b || (b = Promise))(function(g, D) {
|
|
20958
20958
|
function P(x) {
|
|
20959
20959
|
try {
|
|
20960
|
-
|
|
20961
|
-
} catch (
|
|
20962
|
-
D(
|
|
20960
|
+
F(m.next(x));
|
|
20961
|
+
} catch (w) {
|
|
20962
|
+
D(w);
|
|
20963
20963
|
}
|
|
20964
20964
|
}
|
|
20965
|
-
function
|
|
20965
|
+
function X(x) {
|
|
20966
20966
|
try {
|
|
20967
|
-
|
|
20968
|
-
} catch (
|
|
20969
|
-
D(
|
|
20967
|
+
F(m.throw(x));
|
|
20968
|
+
} catch (w) {
|
|
20969
|
+
D(w);
|
|
20970
20970
|
}
|
|
20971
20971
|
}
|
|
20972
|
-
function
|
|
20973
|
-
x.done ? g(x.value) : T(x.value).then(P,
|
|
20972
|
+
function F(x) {
|
|
20973
|
+
x.done ? g(x.value) : T(x.value).then(P, X);
|
|
20974
20974
|
}
|
|
20975
|
-
|
|
20975
|
+
F((m = m.apply(p, h || [])).next());
|
|
20976
20976
|
});
|
|
20977
20977
|
}, n = gt && gt.__generator || function(p, h) {
|
|
20978
20978
|
var b = { label: 0, sent: function() {
|
|
@@ -20982,56 +20982,56 @@ function su() {
|
|
|
20982
20982
|
return D.next = P(0), D.throw = P(1), D.return = P(2), typeof Symbol == "function" && (D[Symbol.iterator] = function() {
|
|
20983
20983
|
return this;
|
|
20984
20984
|
}), D;
|
|
20985
|
-
function P(
|
|
20985
|
+
function P(F) {
|
|
20986
20986
|
return function(x) {
|
|
20987
|
-
return
|
|
20987
|
+
return X([F, x]);
|
|
20988
20988
|
};
|
|
20989
20989
|
}
|
|
20990
|
-
function
|
|
20990
|
+
function X(F) {
|
|
20991
20991
|
if (m) throw new TypeError("Generator is already executing.");
|
|
20992
|
-
for (; D && (D = 0,
|
|
20993
|
-
if (m = 1, T && (g =
|
|
20994
|
-
switch (T = 0, g && (
|
|
20992
|
+
for (; D && (D = 0, F[0] && (b = 0)), b; ) try {
|
|
20993
|
+
if (m = 1, T && (g = F[0] & 2 ? T.return : F[0] ? T.throw || ((g = T.return) && g.call(T), 0) : T.next) && !(g = g.call(T, F[1])).done) return g;
|
|
20994
|
+
switch (T = 0, g && (F = [F[0] & 2, g.value]), F[0]) {
|
|
20995
20995
|
case 0:
|
|
20996
20996
|
case 1:
|
|
20997
|
-
g =
|
|
20997
|
+
g = F;
|
|
20998
20998
|
break;
|
|
20999
20999
|
case 4:
|
|
21000
|
-
return b.label++, { value:
|
|
21000
|
+
return b.label++, { value: F[1], done: !1 };
|
|
21001
21001
|
case 5:
|
|
21002
|
-
b.label++, T =
|
|
21002
|
+
b.label++, T = F[1], F = [0];
|
|
21003
21003
|
continue;
|
|
21004
21004
|
case 7:
|
|
21005
|
-
|
|
21005
|
+
F = b.ops.pop(), b.trys.pop();
|
|
21006
21006
|
continue;
|
|
21007
21007
|
default:
|
|
21008
|
-
if (g = b.trys, !(g = g.length > 0 && g[g.length - 1]) && (
|
|
21008
|
+
if (g = b.trys, !(g = g.length > 0 && g[g.length - 1]) && (F[0] === 6 || F[0] === 2)) {
|
|
21009
21009
|
b = 0;
|
|
21010
21010
|
continue;
|
|
21011
21011
|
}
|
|
21012
|
-
if (
|
|
21013
|
-
b.label =
|
|
21012
|
+
if (F[0] === 3 && (!g || F[1] > g[0] && F[1] < g[3])) {
|
|
21013
|
+
b.label = F[1];
|
|
21014
21014
|
break;
|
|
21015
21015
|
}
|
|
21016
|
-
if (
|
|
21017
|
-
b.label = g[1], g =
|
|
21016
|
+
if (F[0] === 6 && b.label < g[1]) {
|
|
21017
|
+
b.label = g[1], g = F;
|
|
21018
21018
|
break;
|
|
21019
21019
|
}
|
|
21020
21020
|
if (g && b.label < g[2]) {
|
|
21021
|
-
b.label = g[2], b.ops.push(
|
|
21021
|
+
b.label = g[2], b.ops.push(F);
|
|
21022
21022
|
break;
|
|
21023
21023
|
}
|
|
21024
21024
|
g[2] && b.ops.pop(), b.trys.pop();
|
|
21025
21025
|
continue;
|
|
21026
21026
|
}
|
|
21027
|
-
|
|
21027
|
+
F = h.call(p, b);
|
|
21028
21028
|
} catch (x) {
|
|
21029
|
-
|
|
21029
|
+
F = [6, x], T = 0;
|
|
21030
21030
|
} finally {
|
|
21031
21031
|
m = g = 0;
|
|
21032
21032
|
}
|
|
21033
|
-
if (
|
|
21034
|
-
return { value:
|
|
21033
|
+
if (F[0] & 5) throw F[1];
|
|
21034
|
+
return { value: F[0] ? F[1] : void 0, done: !0 };
|
|
21035
21035
|
}
|
|
21036
21036
|
}, r = gt && gt.__importDefault || function(p) {
|
|
21037
21037
|
return p && p.__esModule ? p : { default: p };
|
|
@@ -21039,7 +21039,7 @@ function su() {
|
|
|
21039
21039
|
Object.defineProperty(gt, "__esModule", { value: !0 }), gt.useWebSocket = void 0;
|
|
21040
21040
|
var a = Ct, i = w0, u = Bt(), s = t3(), l = n3(), c = r(r3()), d = ou(), f = function(p, h, b) {
|
|
21041
21041
|
h === void 0 && (h = u.DEFAULT_OPTIONS), b === void 0 && (b = !0);
|
|
21042
|
-
var m = (0, a.useState)(null), T = m[0], g = m[1], D = (0, a.useState)({}), P = D[0],
|
|
21042
|
+
var m = (0, a.useState)(null), T = m[0], g = m[1], D = (0, a.useState)({}), P = D[0], X = D[1], F = (0, a.useMemo)(function() {
|
|
21043
21043
|
if (!h.disableJson && T)
|
|
21044
21044
|
try {
|
|
21045
21045
|
return JSON.parse(T.data);
|
|
@@ -21047,20 +21047,20 @@ function su() {
|
|
|
21047
21047
|
return u.UNPARSABLE_JSON_OBJECT;
|
|
21048
21048
|
}
|
|
21049
21049
|
return null;
|
|
21050
|
-
}, [T, h.disableJson]), x = (0, a.useRef)(null),
|
|
21051
|
-
}), q = (0, a.useRef)(0), te = (0, a.useRef)(Date.now()), Y = (0, a.useRef)([]), $ = (0, a.useRef)(null),
|
|
21052
|
-
|
|
21053
|
-
var I = x.current && P[x.current] !== void 0 ? P[x.current] : p !== null && b === !0 ? u.ReadyState.CONNECTING : u.ReadyState.UNINSTANTIATED,
|
|
21050
|
+
}, [T, h.disableJson]), x = (0, a.useRef)(null), w = (0, a.useRef)(null), V = (0, a.useRef)(function() {
|
|
21051
|
+
}), q = (0, a.useRef)(0), te = (0, a.useRef)(Date.now()), Y = (0, a.useRef)([]), $ = (0, a.useRef)(null), k = (0, a.useRef)(h);
|
|
21052
|
+
k.current = h;
|
|
21053
|
+
var I = x.current && P[x.current] !== void 0 ? P[x.current] : p !== null && b === !0 ? u.ReadyState.CONNECTING : u.ReadyState.UNINSTANTIATED, L = h.queryParams ? JSON.stringify(h.queryParams) : null, B = (0, a.useCallback)(function(z, y) {
|
|
21054
21054
|
var ne;
|
|
21055
|
-
if (y === void 0 && (y = !0), u.isEventSourceSupported &&
|
|
21055
|
+
if (y === void 0 && (y = !0), u.isEventSourceSupported && w.current instanceof EventSource) {
|
|
21056
21056
|
console.warn("Unable to send a message from an eventSource");
|
|
21057
21057
|
return;
|
|
21058
21058
|
}
|
|
21059
|
-
((ne =
|
|
21060
|
-
}, []),
|
|
21061
|
-
y === void 0 && (y = !0),
|
|
21062
|
-
}, [
|
|
21063
|
-
return
|
|
21059
|
+
((ne = w.current) === null || ne === void 0 ? void 0 : ne.readyState) === u.ReadyState.OPEN ? ((0, d.assertIsWebSocket)(w.current, k.current.skipAssert), w.current.send(z)) : y && Y.current.push(z);
|
|
21060
|
+
}, []), W = (0, a.useCallback)(function(z, y) {
|
|
21061
|
+
y === void 0 && (y = !0), B(JSON.stringify(z), y);
|
|
21062
|
+
}, [B]), H = (0, a.useCallback)(function() {
|
|
21063
|
+
return k.current.share !== !0 || u.isEventSourceSupported && w.current instanceof EventSource ? w.current : ($.current === null && w.current && ((0, d.assertIsWebSocket)(w.current, k.current.skipAssert), $.current = (0, c.default)(w.current, V)), $.current);
|
|
21064
21064
|
}, []);
|
|
21065
21065
|
return (0, a.useEffect)(function() {
|
|
21066
21066
|
if (p !== null && b === !0) {
|
|
@@ -21070,10 +21070,10 @@ function su() {
|
|
|
21070
21070
|
return n(this, function(pe) {
|
|
21071
21071
|
switch (pe.label) {
|
|
21072
21072
|
case 0:
|
|
21073
|
-
return v = x, [4, (0, l.getUrl)(p,
|
|
21073
|
+
return v = x, [4, (0, l.getUrl)(p, k)];
|
|
21074
21074
|
case 1:
|
|
21075
21075
|
return v.current = pe.sent(), x.current === null ? (console.error("Failed to get a valid URL. WebSocket connection aborted."), x.current = "ABORTED", (0, i.flushSync)(function() {
|
|
21076
|
-
return
|
|
21076
|
+
return X(function(Se) {
|
|
21077
21077
|
return e(e({}, Se), { ABORTED: u.ReadyState.CLOSED });
|
|
21078
21078
|
});
|
|
21079
21079
|
}), [
|
|
@@ -21085,12 +21085,12 @@ function su() {
|
|
|
21085
21085
|
});
|
|
21086
21086
|
}, _e = function(Se) {
|
|
21087
21087
|
y || (0, i.flushSync)(function() {
|
|
21088
|
-
return
|
|
21088
|
+
return X(function(Oe) {
|
|
21089
21089
|
var ze;
|
|
21090
21090
|
return e(e({}, Oe), x.current && (ze = {}, ze[x.current] = Se, ze));
|
|
21091
21091
|
});
|
|
21092
21092
|
});
|
|
21093
|
-
}, ne && (z = (0, s.createOrJoinSocket)(
|
|
21093
|
+
}, ne && (z = (0, s.createOrJoinSocket)(w, x.current, _e, k, se, V, q, te, B)), [
|
|
21094
21094
|
2
|
|
21095
21095
|
/*return*/
|
|
21096
21096
|
]);
|
|
@@ -21098,26 +21098,26 @@ function su() {
|
|
|
21098
21098
|
});
|
|
21099
21099
|
});
|
|
21100
21100
|
};
|
|
21101
|
-
return
|
|
21101
|
+
return V.current = function() {
|
|
21102
21102
|
y || ($.current && ($.current = null), z?.(), ae());
|
|
21103
21103
|
}, ae(), function() {
|
|
21104
21104
|
y = !0, ne = !1, $.current && ($.current = null), z?.(), g(null);
|
|
21105
21105
|
};
|
|
21106
|
-
} else (p === null || b === !1) && (q.current = 0,
|
|
21106
|
+
} else (p === null || b === !1) && (q.current = 0, X(function(v) {
|
|
21107
21107
|
var se;
|
|
21108
21108
|
return e(e({}, v), x.current && (se = {}, se[x.current] = u.ReadyState.CLOSED, se));
|
|
21109
21109
|
}));
|
|
21110
|
-
}, [p, b,
|
|
21110
|
+
}, [p, b, L, B]), (0, a.useEffect)(function() {
|
|
21111
21111
|
I === u.ReadyState.OPEN && Y.current.splice(0).forEach(function(z) {
|
|
21112
|
-
|
|
21112
|
+
B(z);
|
|
21113
21113
|
});
|
|
21114
21114
|
}, [I]), {
|
|
21115
|
-
sendMessage:
|
|
21116
|
-
sendJsonMessage:
|
|
21115
|
+
sendMessage: B,
|
|
21116
|
+
sendJsonMessage: W,
|
|
21117
21117
|
lastMessage: T,
|
|
21118
|
-
lastJsonMessage:
|
|
21118
|
+
lastJsonMessage: F,
|
|
21119
21119
|
readyState: I,
|
|
21120
|
-
getWebSocket:
|
|
21120
|
+
getWebSocket: H
|
|
21121
21121
|
};
|
|
21122
21122
|
};
|
|
21123
21123
|
return gt.useWebSocket = f, gt;
|
|
@@ -21200,8 +21200,8 @@ function i3() {
|
|
|
21200
21200
|
var b = (0, r.useWebSocket)(u, p, l), m = b.lastMessage, T = b.readyState, g = b.getWebSocket;
|
|
21201
21201
|
return (0, n.useEffect)(function() {
|
|
21202
21202
|
m?.type && Object.entries(h.current).forEach(function(D) {
|
|
21203
|
-
var P = D[0],
|
|
21204
|
-
P === m.type &&
|
|
21203
|
+
var P = D[0], X = D[1];
|
|
21204
|
+
P === m.type && X(m);
|
|
21205
21205
|
});
|
|
21206
21206
|
}, [m]), {
|
|
21207
21207
|
lastEvent: m,
|
|
@@ -21258,8 +21258,8 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21258
21258
|
CONVERSATION: "CONVERSATION",
|
|
21259
21259
|
FORM: "FORM"
|
|
21260
21260
|
}, pn = Xr({}), hd = ({ children: e, liveChatPayload: t }) => {
|
|
21261
|
-
const { conversationScreen: n } = oe($e), { pushXpertMessage: r } = oe($t), { setHasError: a, setMode: i } = oe(tt), [u, s] = le(""), [l, c] = le(!1), [, d] = le(""), [f, p] = le([]), [h, b] = le(null), [m, T] = le(Yt.FORM), [g, D] = le(null), P = (
|
|
21262
|
-
const z = await l3(
|
|
21261
|
+
const { conversationScreen: n } = oe($e), { pushXpertMessage: r } = oe($t), { setHasError: a, setMode: i } = oe(tt), [u, s] = le(""), [l, c] = le(!1), [, d] = le(""), [f, p] = le([]), [h, b] = le(null), [m, T] = le(Yt.FORM), [g, D] = le(null), P = (H) => p((z) => [...z, H]), X = async (H) => {
|
|
21262
|
+
const z = await l3(H.data), { conversation_id: y, event_type: ne, body: ae } = z;
|
|
21263
21263
|
switch (ne) {
|
|
21264
21264
|
case "AGENT_TYPING":
|
|
21265
21265
|
return te();
|
|
@@ -21270,7 +21270,7 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21270
21270
|
case "CONVERSATION_ERROR":
|
|
21271
21271
|
return;
|
|
21272
21272
|
case "CONVERSATION_TERMINATED":
|
|
21273
|
-
return
|
|
21273
|
+
return V();
|
|
21274
21274
|
case "CONVERSATION_TRANSFERRED_TO_GROUP":
|
|
21275
21275
|
return;
|
|
21276
21276
|
case "CONVERSATION_TRANSFERRED_TO_AGENT":
|
|
@@ -21284,18 +21284,18 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21284
21284
|
default:
|
|
21285
21285
|
return;
|
|
21286
21286
|
}
|
|
21287
|
-
}, { sendJsonMessage:
|
|
21288
|
-
onMessage:
|
|
21287
|
+
}, { sendJsonMessage: F } = s3(h, {
|
|
21288
|
+
onMessage: X
|
|
21289
21289
|
}), x = () => {
|
|
21290
21290
|
T(Yt.FORM);
|
|
21291
|
-
const
|
|
21292
|
-
(!
|
|
21293
|
-
},
|
|
21294
|
-
|
|
21291
|
+
const H = n?.liveChat?.form;
|
|
21292
|
+
(!H || H.length === 0) && i(Nt.XPERT);
|
|
21293
|
+
}, w = () => {
|
|
21294
|
+
F({
|
|
21295
21295
|
action: "sendmessage",
|
|
21296
21296
|
event: "TERMINATE_CONVERSATION"
|
|
21297
21297
|
});
|
|
21298
|
-
},
|
|
21298
|
+
}, V = () => {
|
|
21299
21299
|
r({
|
|
21300
21300
|
content: c3,
|
|
21301
21301
|
role: ve.INFO
|
|
@@ -21304,21 +21304,21 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21304
21304
|
d(""), b(null), T(Yt.FORM), i(Nt.XPERT);
|
|
21305
21305
|
}, te = () => {
|
|
21306
21306
|
g && clearTimeout(g), c(!0);
|
|
21307
|
-
const
|
|
21307
|
+
const H = setTimeout(() => {
|
|
21308
21308
|
c(!1);
|
|
21309
21309
|
}, 5e3);
|
|
21310
|
-
D(
|
|
21311
|
-
}, Y = (
|
|
21312
|
-
const { displayName: z } =
|
|
21310
|
+
D(H);
|
|
21311
|
+
}, Y = (H) => {
|
|
21312
|
+
const { displayName: z } = H;
|
|
21313
21313
|
p([]), s(z ?? "An agent"), T(Yt.CONVERSATION);
|
|
21314
|
-
}, $ = (
|
|
21315
|
-
const { messageId: z, text: y, timestamp: ne } =
|
|
21314
|
+
}, $ = (H) => {
|
|
21315
|
+
const { messageId: z, text: y, timestamp: ne } = H;
|
|
21316
21316
|
P({
|
|
21317
21317
|
content: y ?? "",
|
|
21318
21318
|
id: z ?? "",
|
|
21319
21319
|
role: ve.AGENT,
|
|
21320
21320
|
timestamp: ne ? new Date(ne) : void 0
|
|
21321
|
-
}),
|
|
21321
|
+
}), F({
|
|
21322
21322
|
action: "sendmessage",
|
|
21323
21323
|
messages: [
|
|
21324
21324
|
{
|
|
@@ -21328,27 +21328,27 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21328
21328
|
],
|
|
21329
21329
|
event: "ACKNOWLEDGE_MESSAGE"
|
|
21330
21330
|
}), c(!1);
|
|
21331
|
-
},
|
|
21331
|
+
}, W = {
|
|
21332
21332
|
agentName: u,
|
|
21333
21333
|
agentTyping: l,
|
|
21334
21334
|
cancelLiveChatConnection: x,
|
|
21335
|
-
endLiveChat:
|
|
21335
|
+
endLiveChat: V,
|
|
21336
21336
|
liveChatMessages: f,
|
|
21337
21337
|
pushLiveChatMessage: P,
|
|
21338
|
-
sendMessage: (
|
|
21338
|
+
sendMessage: (H) => {
|
|
21339
21339
|
P({
|
|
21340
|
-
content:
|
|
21340
|
+
content: H,
|
|
21341
21341
|
id: "",
|
|
21342
21342
|
role: ve.USER,
|
|
21343
21343
|
timestamp: /* @__PURE__ */ new Date()
|
|
21344
|
-
}),
|
|
21344
|
+
}), F({
|
|
21345
21345
|
action: "sendmessage",
|
|
21346
21346
|
event: "OUTGOING_MESSAGE",
|
|
21347
|
-
message:
|
|
21347
|
+
message: H
|
|
21348
21348
|
});
|
|
21349
21349
|
},
|
|
21350
21350
|
sendTypingEvent: async () => {
|
|
21351
|
-
|
|
21351
|
+
F({
|
|
21352
21352
|
action: "sendmessage",
|
|
21353
21353
|
event: "TYPING"
|
|
21354
21354
|
});
|
|
@@ -21356,10 +21356,10 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21356
21356
|
setLiveChatMessages: p,
|
|
21357
21357
|
step: m,
|
|
21358
21358
|
setStep: T,
|
|
21359
|
-
startLiveChat: (
|
|
21359
|
+
startLiveChat: (H) => {
|
|
21360
21360
|
try {
|
|
21361
21361
|
T(Yt.CONNECTING);
|
|
21362
|
-
const z = new URLSearchParams({ ...t, ...
|
|
21362
|
+
const z = new URLSearchParams({ ...t, ...H });
|
|
21363
21363
|
z.append("url", window.location.href), b(
|
|
21364
21364
|
`${n?.liveChat?.socketUrl}?${z.toString()}`
|
|
21365
21365
|
);
|
|
@@ -21373,11 +21373,11 @@ const c3 = "This conversation with a live agent has ended. Please note that a tr
|
|
|
21373
21373
|
icon: "check",
|
|
21374
21374
|
iconColor: "#30A171",
|
|
21375
21375
|
role: ve.NOTIFICATION
|
|
21376
|
-
}),
|
|
21376
|
+
}), V();
|
|
21377
21377
|
},
|
|
21378
|
-
terminateConversation:
|
|
21378
|
+
terminateConversation: w
|
|
21379
21379
|
};
|
|
21380
|
-
return /* @__PURE__ */ _.jsx(pn.Provider, { value:
|
|
21380
|
+
return /* @__PURE__ */ _.jsx(pn.Provider, { value: W, children: e });
|
|
21381
21381
|
};
|
|
21382
21382
|
hd.propTypes = {
|
|
21383
21383
|
children: A.element.isRequired,
|
|
@@ -21899,47 +21899,47 @@ function _d() {
|
|
|
21899
21899
|
), T = () => {
|
|
21900
21900
|
r(Nt.XPERT);
|
|
21901
21901
|
}, g = () => {
|
|
21902
|
-
p("privacyCheck"), f((
|
|
21903
|
-
}, D = (
|
|
21904
|
-
const
|
|
21905
|
-
p(x), c(x,
|
|
21902
|
+
p("privacyCheck"), f((F) => !F);
|
|
21903
|
+
}, D = (F, x) => {
|
|
21904
|
+
const w = F.target.value;
|
|
21905
|
+
p(x), c(x, w);
|
|
21906
21906
|
}, P = () => {
|
|
21907
|
-
|
|
21907
|
+
X() && n(l);
|
|
21908
21908
|
};
|
|
21909
21909
|
Le(() => {
|
|
21910
21910
|
(!a || a.length === 0) && n();
|
|
21911
21911
|
}, [a, n]);
|
|
21912
|
-
const
|
|
21913
|
-
const
|
|
21914
|
-
const { key:
|
|
21915
|
-
if (!te) return { ...x, [
|
|
21912
|
+
const X = () => {
|
|
21913
|
+
const F = a.reduce((x, w) => {
|
|
21914
|
+
const { key: V, validations: q = [] } = w, te = l[V];
|
|
21915
|
+
if (!te) return { ...x, [V]: "Required" };
|
|
21916
21916
|
if (q?.length > 0)
|
|
21917
21917
|
for (const Y of q)
|
|
21918
21918
|
switch (Y) {
|
|
21919
21919
|
case "email": {
|
|
21920
21920
|
if (!E3(te))
|
|
21921
|
-
return { ...x, [
|
|
21921
|
+
return { ...x, [V]: "Should be email" };
|
|
21922
21922
|
break;
|
|
21923
21923
|
}
|
|
21924
21924
|
}
|
|
21925
21925
|
return x;
|
|
21926
21926
|
}, {});
|
|
21927
|
-
return !d && s && (
|
|
21927
|
+
return !d && s && (F.privacyCheck = "Required"), b(F), Object.keys(F).length === 0;
|
|
21928
21928
|
};
|
|
21929
21929
|
return /* @__PURE__ */ _.jsxs("div", { className: "live-chat-form", children: [
|
|
21930
21930
|
i && /* @__PURE__ */ _.jsx("p", { children: i }),
|
|
21931
|
-
(a ?? []).map(({ key:
|
|
21931
|
+
(a ?? []).map(({ key: F, name: x }) => /* @__PURE__ */ _.jsxs(k0, { children: [
|
|
21932
21932
|
/* @__PURE__ */ _.jsx(
|
|
21933
21933
|
"input",
|
|
21934
21934
|
{
|
|
21935
|
-
className: `live-chat-form-input ${h[
|
|
21935
|
+
className: `live-chat-form-input ${h[F] ? "error" : ""}`,
|
|
21936
21936
|
name: x,
|
|
21937
21937
|
placeholder: x,
|
|
21938
|
-
onChange: (
|
|
21938
|
+
onChange: (w) => D(w, F)
|
|
21939
21939
|
}
|
|
21940
21940
|
),
|
|
21941
|
-
h[
|
|
21942
|
-
] },
|
|
21941
|
+
h[F] && /* @__PURE__ */ _.jsx("p", { className: "live-chat-form-error", children: h[F] })
|
|
21942
|
+
] }, F)),
|
|
21943
21943
|
s && /* @__PURE__ */ _.jsxs(_.Fragment, { children: [
|
|
21944
21944
|
/* @__PURE__ */ _.jsx(
|
|
21945
21945
|
"div",
|
|
@@ -21984,7 +21984,7 @@ function _d() {
|
|
|
21984
21984
|
},
|
|
21985
21985
|
type: "checkbox",
|
|
21986
21986
|
onChange: g,
|
|
21987
|
-
onKeyDown: (
|
|
21987
|
+
onKeyDown: (F) => F.key === "Enter" && g()
|
|
21988
21988
|
}
|
|
21989
21989
|
),
|
|
21990
21990
|
/* @__PURE__ */ _.jsx("label", { htmlFor: "privacy-check", children: "Yes, I accept" })
|
|
@@ -22212,19 +22212,19 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22212
22212
|
isMobile: g,
|
|
22213
22213
|
mode: D,
|
|
22214
22214
|
setDisableScroll: P,
|
|
22215
|
-
setHasError:
|
|
22216
|
-
setHasNewMessage:
|
|
22215
|
+
setHasError: X,
|
|
22216
|
+
setHasNewMessage: F,
|
|
22217
22217
|
setIsNormalSize: x,
|
|
22218
|
-
setLoading:
|
|
22219
|
-
setLoadingHistory:
|
|
22218
|
+
setLoading: w,
|
|
22219
|
+
setLoadingHistory: V,
|
|
22220
22220
|
setStreaming: q
|
|
22221
|
-
} = oe(tt), [, te] = le(!1), [, Y] = le(!1), [$,
|
|
22221
|
+
} = oe(tt), [, te] = le(!1), [, Y] = le(!1), [$, k] = le(!1), [I, L] = le(!1), [B, W] = le(!1), H = $ || !c, z = et(null), y = et(null), ne = ft.get(`${a}-test`) === "1";
|
|
22222
22222
|
Le(() => {
|
|
22223
|
-
D === Nt.XPERT &&
|
|
22224
|
-
}, [D,
|
|
22223
|
+
D === Nt.XPERT && H && z.current && z.current.focus();
|
|
22224
|
+
}, [D, H]), C3(
|
|
22225
22225
|
r?.liveChat?.enabled,
|
|
22226
22226
|
I,
|
|
22227
|
-
|
|
22227
|
+
L
|
|
22228
22228
|
);
|
|
22229
22229
|
const ae = dt(
|
|
22230
22230
|
({ name: ue, payload: be }) => {
|
|
@@ -22250,13 +22250,13 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22250
22250
|
for (; !ye(); ) {
|
|
22251
22251
|
if (Ce >= Ye)
|
|
22252
22252
|
return !1;
|
|
22253
|
-
await new Promise((
|
|
22253
|
+
await new Promise((U) => setTimeout(U, Fe)), Ce += Fe;
|
|
22254
22254
|
}
|
|
22255
22255
|
return !0;
|
|
22256
22256
|
})(
|
|
22257
22257
|
() => window?.OnetrustActiveGroups && window.OnetrustActiveGroups.split(",").includes("C0003")
|
|
22258
22258
|
))) {
|
|
22259
|
-
|
|
22259
|
+
V(!0);
|
|
22260
22260
|
try {
|
|
22261
22261
|
let ye = Ns(a);
|
|
22262
22262
|
const Ye = t?.baseUrl?.includes("xpert-api-services") ? "/v1/history" : "/xpert/v2/history", Fe = `conversation_id=${ye}&client_id=${t?.payloadParams?.client_id}`, Ce = await fetch(
|
|
@@ -22270,22 +22270,22 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22270
22270
|
);
|
|
22271
22271
|
if (!Ce.ok)
|
|
22272
22272
|
throw new Error(`HTTPError: ${Ce.status} ${Ce.statusText}`);
|
|
22273
|
-
const
|
|
22273
|
+
const U = await Ce.json();
|
|
22274
22274
|
m(
|
|
22275
|
-
|
|
22275
|
+
U.map((K) => ({
|
|
22276
22276
|
...K,
|
|
22277
22277
|
disableFeedback: !0,
|
|
22278
22278
|
toolCalls: K.tool_calls,
|
|
22279
22279
|
toolCallId: K.tool_call_id
|
|
22280
22280
|
}))
|
|
22281
|
-
), P(!0),
|
|
22281
|
+
), P(!0), F(!0);
|
|
22282
22282
|
} catch (ye) {
|
|
22283
22283
|
console.error(ye);
|
|
22284
22284
|
} finally {
|
|
22285
|
-
|
|
22285
|
+
V(!1);
|
|
22286
22286
|
}
|
|
22287
22287
|
}
|
|
22288
|
-
}, se = r?.conversationHistory?.enabled &&
|
|
22288
|
+
}, se = r?.conversationHistory?.enabled && H && !I;
|
|
22289
22289
|
S3(
|
|
22290
22290
|
() => se && v()
|
|
22291
22291
|
), Le(() => {
|
|
@@ -22386,12 +22386,12 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22386
22386
|
});
|
|
22387
22387
|
}
|
|
22388
22388
|
);
|
|
22389
|
-
const
|
|
22389
|
+
const U = Ce.filter(({ content: he }) => !!he), K = U.map((he) => he.content ?? "").join("");
|
|
22390
22390
|
pe(K, be);
|
|
22391
22391
|
const ie = /* @__PURE__ */ new Date(), Ee = ks(JSON.stringify(ye));
|
|
22392
22392
|
return Se({
|
|
22393
22393
|
conversationByteSize: Ee,
|
|
22394
|
-
conversationSize:
|
|
22394
|
+
conversationSize: U.length + T.filter(({ content: he }) => !!he).length + 1,
|
|
22395
22395
|
userInputMessage: Me,
|
|
22396
22396
|
apiResponseMessage: K,
|
|
22397
22397
|
elapsedSeconds: Is(Ye, ie),
|
|
@@ -22399,7 +22399,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22399
22399
|
}), Ce;
|
|
22400
22400
|
}, ze = async (ue, be, Me, ye, Ye) => {
|
|
22401
22401
|
const Fe = new TextDecoder("utf-8");
|
|
22402
|
-
let Ce = [],
|
|
22402
|
+
let Ce = [], U = 0;
|
|
22403
22403
|
const K = /* @__PURE__ */ new Date();
|
|
22404
22404
|
for (; ; ) {
|
|
22405
22405
|
const { value: Ee, done: he } = await ue.read();
|
|
@@ -22416,12 +22416,12 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22416
22416
|
toolCallId: Be.tool_call_id
|
|
22417
22417
|
})
|
|
22418
22418
|
);
|
|
22419
|
-
if (Ve.length >
|
|
22420
|
-
for (let ot =
|
|
22419
|
+
if (Ve.length > U) {
|
|
22420
|
+
for (let ot = U; ot < Ve.length; ot++)
|
|
22421
22421
|
b({
|
|
22422
22422
|
content: "",
|
|
22423
22423
|
disableFeedback: !0
|
|
22424
|
-
}),
|
|
22424
|
+
}), U++;
|
|
22425
22425
|
const Be = /* @__PURE__ */ new Date(), rt = ks(
|
|
22426
22426
|
JSON.stringify(ye)
|
|
22427
22427
|
), He = Ve.filter(({ content: ot }) => !!ot);
|
|
@@ -22462,7 +22462,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22462
22462
|
if (ue.trim().length === 0)
|
|
22463
22463
|
return;
|
|
22464
22464
|
const be = /* @__PURE__ */ new Date();
|
|
22465
|
-
|
|
22465
|
+
F(!1), X(!1);
|
|
22466
22466
|
const Me = T.filter((Ce) => Ce.role === ve.USER).length + 1;
|
|
22467
22467
|
if (ae({
|
|
22468
22468
|
name: `${s.prefix}.bi.xpert.chatbot.popup.chat.message.sent`,
|
|
@@ -22473,8 +22473,8 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22473
22473
|
userInputMessage: ue,
|
|
22474
22474
|
isTestUser: ne
|
|
22475
22475
|
}
|
|
22476
|
-
}),
|
|
22477
|
-
await h(ue),
|
|
22476
|
+
}), w(!0), h) {
|
|
22477
|
+
await h(ue), w(!1);
|
|
22478
22478
|
return;
|
|
22479
22479
|
}
|
|
22480
22480
|
let ye = null;
|
|
@@ -22512,7 +22512,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22512
22512
|
});
|
|
22513
22513
|
if (!Fe.ok)
|
|
22514
22514
|
throw new Error(`HTTPError: ${Fe.status} ${Fe.statusText}`);
|
|
22515
|
-
|
|
22515
|
+
w(!1), t.payloadParams?.stream ? await Ie(
|
|
22516
22516
|
Fe,
|
|
22517
22517
|
ye,
|
|
22518
22518
|
ue,
|
|
@@ -22524,14 +22524,14 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22524
22524
|
ue,
|
|
22525
22525
|
Ye,
|
|
22526
22526
|
be
|
|
22527
|
-
), P(!1),
|
|
22527
|
+
), P(!1), F(!0);
|
|
22528
22528
|
} catch (be) {
|
|
22529
22529
|
if (be.name === "AbortError")
|
|
22530
22530
|
return;
|
|
22531
|
-
|
|
22531
|
+
w(!1), X(!0), console.error(be);
|
|
22532
22532
|
}
|
|
22533
22533
|
}, st = () => {
|
|
22534
|
-
|
|
22534
|
+
L(!1), k(!0), x(!0), v(), ae({
|
|
22535
22535
|
name: `${s.prefix}.bi.xpert.chatbot.action.button.clicked`,
|
|
22536
22536
|
payload: {
|
|
22537
22537
|
category: "2u",
|
|
@@ -22549,7 +22549,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22549
22549
|
}
|
|
22550
22550
|
}), x(ue);
|
|
22551
22551
|
}, Mn = () => {
|
|
22552
|
-
|
|
22552
|
+
k(!0), x(!0), v(), ae({
|
|
22553
22553
|
name: `${s.prefix}.bi.xpert.chatbot.proactive.message.clicked`,
|
|
22554
22554
|
payload: {
|
|
22555
22555
|
category: "2u",
|
|
@@ -22567,7 +22567,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22567
22567
|
}
|
|
22568
22568
|
});
|
|
22569
22569
|
}, mn = () => {
|
|
22570
|
-
|
|
22570
|
+
k(!1), W(!1), ae({
|
|
22571
22571
|
name: `${s.prefix}.bi.xpert.chatbot.popup.chat.minimized`,
|
|
22572
22572
|
payload: {
|
|
22573
22573
|
category: "2u",
|
|
@@ -22602,7 +22602,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22602
22602
|
u?.enabled && /* @__PURE__ */ _.jsx(
|
|
22603
22603
|
Ad,
|
|
22604
22604
|
{
|
|
22605
|
-
showMessage: !
|
|
22605
|
+
showMessage: !H,
|
|
22606
22606
|
style: Bn,
|
|
22607
22607
|
onClose: Fn,
|
|
22608
22608
|
onClick: Mn,
|
|
@@ -22646,7 +22646,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22646
22646
|
}
|
|
22647
22647
|
),
|
|
22648
22648
|
c && /* @__PURE__ */ _.jsx(p3, {}),
|
|
22649
|
-
|
|
22649
|
+
H && !I && /* @__PURE__ */ _.jsx(Js, { isMounted: B, children: /* @__PURE__ */ _.jsx(
|
|
22650
22650
|
"div",
|
|
22651
22651
|
{
|
|
22652
22652
|
ref: d,
|
|
@@ -22657,8 +22657,8 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22657
22657
|
{
|
|
22658
22658
|
onClose: mn,
|
|
22659
22659
|
handleResizeButtonClick: wt,
|
|
22660
|
-
isMounted:
|
|
22661
|
-
setIsMounted:
|
|
22660
|
+
isMounted: B,
|
|
22661
|
+
setIsMounted: W
|
|
22662
22662
|
}
|
|
22663
22663
|
),
|
|
22664
22664
|
/* @__PURE__ */ _.jsx(h3, {}),
|
|
@@ -22670,7 +22670,7 @@ function Sd({ submitEventExternal: e = null }) {
|
|
|
22670
22670
|
handleSend: nt,
|
|
22671
22671
|
inputRef: z,
|
|
22672
22672
|
isTestUser: ne,
|
|
22673
|
-
setLiveChatOpen:
|
|
22673
|
+
setLiveChatOpen: L,
|
|
22674
22674
|
submitEvent: ae
|
|
22675
22675
|
}
|
|
22676
22676
|
),
|