@telia-ace/widget-conversational-hub 1.1.123-rc.1 → 1.1.123-rc.3
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/index.js +19 -19
- package/index.mjs +99 -98
- package/package.json +3 -3
package/index.mjs
CHANGED
|
@@ -339,9 +339,9 @@ function Wr(n) {
|
|
|
339
339
|
function Di(n) {
|
|
340
340
|
E(n) ? n() : n.unsubscribe();
|
|
341
341
|
}
|
|
342
|
-
var
|
|
342
|
+
var Ra = {
|
|
343
343
|
Promise: void 0
|
|
344
|
-
},
|
|
344
|
+
}, La = {
|
|
345
345
|
setTimeout: function(n, e) {
|
|
346
346
|
for (var t = [], s = 2; s < arguments.length; s++)
|
|
347
347
|
t[s - 2] = arguments[s];
|
|
@@ -353,7 +353,7 @@ var La = {
|
|
|
353
353
|
delegate: void 0
|
|
354
354
|
};
|
|
355
355
|
function Gr(n) {
|
|
356
|
-
|
|
356
|
+
La.setTimeout(function() {
|
|
357
357
|
throw n;
|
|
358
358
|
});
|
|
359
359
|
}
|
|
@@ -522,7 +522,7 @@ var X = (function() {
|
|
|
522
522
|
})();
|
|
523
523
|
function Ui(n) {
|
|
524
524
|
var e;
|
|
525
|
-
return (e = n ??
|
|
525
|
+
return (e = n ?? Ra.Promise) !== null && e !== void 0 ? e : Promise;
|
|
526
526
|
}
|
|
527
527
|
function Na(n) {
|
|
528
528
|
return n && E(n.next) && E(n.error) && E(n.complete);
|
|
@@ -1109,8 +1109,8 @@ function pl(n, e, t, s, i, r, o, a) {
|
|
|
1109
1109
|
})), function() {
|
|
1110
1110
|
};
|
|
1111
1111
|
}
|
|
1112
|
-
function
|
|
1113
|
-
return t === void 0 && (t = 1 / 0), E(e) ?
|
|
1112
|
+
function Rs(n, e, t) {
|
|
1113
|
+
return t === void 0 && (t = 1 / 0), E(e) ? Rs(function(s, i) {
|
|
1114
1114
|
return nn(function(r, o) {
|
|
1115
1115
|
return e(s, r, i, o);
|
|
1116
1116
|
})(ce(n(s, i)));
|
|
@@ -1119,7 +1119,7 @@ function Ls(n, e, t) {
|
|
|
1119
1119
|
}));
|
|
1120
1120
|
}
|
|
1121
1121
|
function fl(n) {
|
|
1122
|
-
return n === void 0 && (n = 1 / 0),
|
|
1122
|
+
return n === void 0 && (n = 1 / 0), Rs(Ot, n);
|
|
1123
1123
|
}
|
|
1124
1124
|
var gl = ["addListener", "removeListener"], ml = ["addEventListener", "removeEventListener"], vl = ["on", "off"];
|
|
1125
1125
|
function sn(n, e, t, s) {
|
|
@@ -1131,7 +1131,7 @@ function sn(n, e, t, s) {
|
|
|
1131
1131
|
};
|
|
1132
1132
|
}) : bl(n) ? gl.map(Hi(n, e)) : yl(n) ? vl.map(Hi(n, e)) : [], 2), r = i[0], o = i[1];
|
|
1133
1133
|
if (!r && Ts(n))
|
|
1134
|
-
return
|
|
1134
|
+
return Rs(function(a) {
|
|
1135
1135
|
return sn(a, e, t);
|
|
1136
1136
|
})(ce(n));
|
|
1137
1137
|
if (!r)
|
|
@@ -1464,7 +1464,7 @@ class Cl {
|
|
|
1464
1464
|
* Copyright 2019 Google LLC
|
|
1465
1465
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1466
1466
|
*/
|
|
1467
|
-
const Qt = globalThis,
|
|
1467
|
+
const Qt = globalThis, Ls = Qt.ShadowRoot && (Qt.ShadyCSS === void 0 || Qt.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, Os = Symbol(), ji = /* @__PURE__ */ new WeakMap();
|
|
1468
1468
|
let co = class {
|
|
1469
1469
|
constructor(e, t, s) {
|
|
1470
1470
|
if (this._$cssResult$ = !0, s !== Os) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
@@ -1473,7 +1473,7 @@ let co = class {
|
|
|
1473
1473
|
get styleSheet() {
|
|
1474
1474
|
let e = this.o;
|
|
1475
1475
|
const t = this.t;
|
|
1476
|
-
if (
|
|
1476
|
+
if (Ls && e === void 0) {
|
|
1477
1477
|
const s = t !== void 0 && t.length === 1;
|
|
1478
1478
|
s && (e = ji.get(t)), e === void 0 && ((this.o = e = new CSSStyleSheet()).replaceSync(this.cssText), s && ji.set(t, e));
|
|
1479
1479
|
}
|
|
@@ -1490,13 +1490,13 @@ const Tl = (n) => new co(typeof n == "string" ? n : n + "", void 0, Os), Z = (n,
|
|
|
1490
1490
|
throw Error("Value passed to 'css' function must be a 'css' function result: " + o + ". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.");
|
|
1491
1491
|
})(i) + n[r + 1]), n[0]);
|
|
1492
1492
|
return new co(t, n, Os);
|
|
1493
|
-
},
|
|
1494
|
-
if (
|
|
1493
|
+
}, Rl = (n, e) => {
|
|
1494
|
+
if (Ls) n.adoptedStyleSheets = e.map(((t) => t instanceof CSSStyleSheet ? t : t.styleSheet));
|
|
1495
1495
|
else for (const t of e) {
|
|
1496
1496
|
const s = document.createElement("style"), i = Qt.litNonce;
|
|
1497
1497
|
i !== void 0 && s.setAttribute("nonce", i), s.textContent = t.cssText, n.appendChild(s);
|
|
1498
1498
|
}
|
|
1499
|
-
}, qi =
|
|
1499
|
+
}, qi = Ls ? (n) => n : (n) => n instanceof CSSStyleSheet ? ((e) => {
|
|
1500
1500
|
let t = "";
|
|
1501
1501
|
for (const s of e.cssRules) t += s.cssText;
|
|
1502
1502
|
return Tl(t);
|
|
@@ -1506,7 +1506,7 @@ const Tl = (n) => new co(typeof n == "string" ? n : n + "", void 0, Os), Z = (n,
|
|
|
1506
1506
|
* Copyright 2017 Google LLC
|
|
1507
1507
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1508
1508
|
*/
|
|
1509
|
-
const { is:
|
|
1509
|
+
const { is: Ll, defineProperty: Ol, getOwnPropertyDescriptor: Pl, getOwnPropertyNames: Il, getOwnPropertySymbols: Ml, getPrototypeOf: Nl } = Object, Se = globalThis, Wi = Se.trustedTypes, Dl = Wi ? Wi.emptyScript : "", qn = Se.reactiveElementPolyfillSupport, $t = (n, e) => n, rn = { toAttribute(n, e) {
|
|
1510
1510
|
switch (e) {
|
|
1511
1511
|
case Boolean:
|
|
1512
1512
|
n = n ? Dl : null;
|
|
@@ -1534,7 +1534,7 @@ const { is: Rl, defineProperty: Ol, getOwnPropertyDescriptor: Pl, getOwnProperty
|
|
|
1534
1534
|
}
|
|
1535
1535
|
}
|
|
1536
1536
|
return t;
|
|
1537
|
-
} }, Ps = (n, e) => !
|
|
1537
|
+
} }, Ps = (n, e) => !Ll(n, e), Gi = { attribute: !0, type: String, converter: rn, reflect: !1, useDefault: !1, hasChanged: Ps };
|
|
1538
1538
|
Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), Se.litPropertyMetadata ?? (Se.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
|
|
1539
1539
|
let Ye = class extends HTMLElement {
|
|
1540
1540
|
static addInitializer(e) {
|
|
@@ -1620,7 +1620,7 @@ let Ye = class extends HTMLElement {
|
|
|
1620
1620
|
}
|
|
1621
1621
|
createRenderRoot() {
|
|
1622
1622
|
const e = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
1623
|
-
return
|
|
1623
|
+
return Rl(e, this.constructor.elementStyles), e;
|
|
1624
1624
|
}
|
|
1625
1625
|
connectedCallback() {
|
|
1626
1626
|
var e;
|
|
@@ -1746,7 +1746,7 @@ Ye.elementStyles = [], Ye.shadowRootOptions = { mode: "open" }, Ye[$t("elementPr
|
|
|
1746
1746
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
1747
1747
|
*/
|
|
1748
1748
|
const xt = globalThis, on = xt.trustedTypes, Zi = on ? on.createPolicy("lit-html", { createHTML: (n) => n }) : void 0, uo = "$lit$", we = `lit$${Math.random().toFixed(9).slice(2)}$`, ho = "?" + we, Ul = `<${ho}>`, De = document, St = () => De.createComment(""), _t = (n) => n === null || typeof n != "object" && typeof n != "function", Is = Array.isArray, zl = (n) => Is(n) || typeof (n == null ? void 0 : n[Symbol.iterator]) == "function", Wn = `[
|
|
1749
|
-
\f\r]`, dt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Yi = /-->/g, Xi = />/g,
|
|
1749
|
+
\f\r]`, dt = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Yi = /-->/g, Xi = />/g, Le = RegExp(`>|${Wn}(?:([^\\s"'>=/]+)(${Wn}*=${Wn}*(?:[^
|
|
1750
1750
|
\f\r"'\`<>=]|("|')|))|$)`, "g"), Ki = /'/g, Vi = /"/g, po = /^(?:script|style|textarea|title)$/i, Bl = (n) => (e, ...t) => ({ _$litType$: n, strings: e, values: t }), w = Bl(1), _e = Symbol.for("lit-noChange"), $ = Symbol.for("lit-nothing"), Qi = /* @__PURE__ */ new WeakMap(), Pe = De.createTreeWalker(De, 129);
|
|
1751
1751
|
function fo(n, e) {
|
|
1752
1752
|
if (!Is(n) || !n.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
@@ -1758,8 +1758,8 @@ const Hl = (n, e) => {
|
|
|
1758
1758
|
for (let a = 0; a < t; a++) {
|
|
1759
1759
|
const l = n[a];
|
|
1760
1760
|
let c, u, p = -1, d = 0;
|
|
1761
|
-
for (; d < l.length && (o.lastIndex = d, u = o.exec(l), u !== null); ) d = o.lastIndex, o === dt ? u[1] === "!--" ? o = Yi : u[1] !== void 0 ? o = Xi : u[2] !== void 0 ? (po.test(u[2]) && (i = RegExp("</" + u[2], "g")), o =
|
|
1762
|
-
const g = o ===
|
|
1761
|
+
for (; d < l.length && (o.lastIndex = d, u = o.exec(l), u !== null); ) d = o.lastIndex, o === dt ? u[1] === "!--" ? o = Yi : u[1] !== void 0 ? o = Xi : u[2] !== void 0 ? (po.test(u[2]) && (i = RegExp("</" + u[2], "g")), o = Le) : u[3] !== void 0 && (o = Le) : o === Le ? u[0] === ">" ? (o = i ?? dt, p = -1) : u[1] === void 0 ? p = -2 : (p = o.lastIndex - u[2].length, c = u[1], o = u[3] === void 0 ? Le : u[3] === '"' ? Vi : Ki) : o === Vi || o === Ki ? o = Le : o === Yi || o === Xi ? o = dt : (o = Le, i = void 0);
|
|
1762
|
+
const g = o === Le && n[a + 1].startsWith("/>") ? " " : "";
|
|
1763
1763
|
r += o === dt ? l + Ul : p >= 0 ? (s.push(c), l.slice(0, p) + uo + l.slice(p) + we + g) : l + we + (p === -2 ? a : g);
|
|
1764
1764
|
}
|
|
1765
1765
|
return [fo(n, r + (n[t] || "<?>") + (e === 2 ? "</svg>" : e === 3 ? "</math>" : "")), s];
|
|
@@ -2421,7 +2421,7 @@ const kn = typeof window < "u" ? window : {}, le = kn.document || { head: {} },
|
|
|
2421
2421
|
}
|
|
2422
2422
|
}
|
|
2423
2423
|
}
|
|
2424
|
-
},
|
|
2424
|
+
}, Rc = (n, e, t) => {
|
|
2425
2425
|
if (e.$members$) {
|
|
2426
2426
|
n.watchers && (e.$watchers$ = n.watchers);
|
|
2427
2427
|
const s = Object.entries(e.$members$), i = n.prototype;
|
|
@@ -2458,7 +2458,7 @@ const kn = typeof window < "u" ? window : {}, le = kn.document || { head: {} },
|
|
|
2458
2458
|
}
|
|
2459
2459
|
}
|
|
2460
2460
|
return n;
|
|
2461
|
-
},
|
|
2461
|
+
}, Lc = async (n, e, t, s, i) => {
|
|
2462
2462
|
if ((e.$flags$ & 32) === 0 && (i = n.constructor, e.$flags$ |= 32, customElements.whenDefined(t.$tagName$).then(() => e.$flags$ |= 128), i.style)) {
|
|
2463
2463
|
let o = i.style;
|
|
2464
2464
|
typeof o != "string" && (o = o[e.$modeName$ = cc(n)]);
|
|
@@ -2478,7 +2478,7 @@ const kn = typeof window < "u" ? window : {}, le = kn.document || { head: {} },
|
|
|
2478
2478
|
const o = n[i];
|
|
2479
2479
|
delete n[i], n[i] = o;
|
|
2480
2480
|
}
|
|
2481
|
-
}),
|
|
2481
|
+
}), Lc(n, e, t)), s();
|
|
2482
2482
|
}
|
|
2483
2483
|
}, Ic = (n) => {
|
|
2484
2484
|
const e = n["s-cr"] = le.createComment("");
|
|
@@ -2488,7 +2488,7 @@ const kn = typeof window < "u" ? window : {}, le = kn.document || { head: {} },
|
|
|
2488
2488
|
const e = Sn(n);
|
|
2489
2489
|
e.$rmListeners$ && (e.$rmListeners$.map((t) => t()), e.$rmListeners$ = void 0);
|
|
2490
2490
|
}
|
|
2491
|
-
},
|
|
2491
|
+
}, Ro = (n, e) => {
|
|
2492
2492
|
const t = {
|
|
2493
2493
|
$flags$: e[0],
|
|
2494
2494
|
$tagName$: e[1]
|
|
@@ -2511,15 +2511,15 @@ const kn = typeof window < "u" ? window : {}, le = kn.document || { head: {} },
|
|
|
2511
2511
|
delegatesFocus: !!(t.$flags$ & 16)
|
|
2512
2512
|
});
|
|
2513
2513
|
}
|
|
2514
|
-
}), n.is = t.$tagName$,
|
|
2515
|
-
},
|
|
2514
|
+
}), n.is = t.$tagName$, Rc(n, t);
|
|
2515
|
+
}, Lo = /* @__PURE__ */ new WeakMap(), Sn = (n) => Lo.get(n), Nc = (n, e) => {
|
|
2516
2516
|
const t = {
|
|
2517
2517
|
$flags$: 0,
|
|
2518
2518
|
$hostElement$: n,
|
|
2519
2519
|
$cmpMeta$: e,
|
|
2520
2520
|
$instanceValues$: /* @__PURE__ */ new Map()
|
|
2521
2521
|
};
|
|
2522
|
-
return $o(n, t, e.$listeners$),
|
|
2522
|
+
return $o(n, t, e.$listeners$), Lo.set(n, t);
|
|
2523
2523
|
}, ur = (n, e) => e in n, Nt = (n, e) => (0, console.error)(n, e), un = /* @__PURE__ */ new Map(), Dc = [], hr = [], Oo = [], Uc = (n, e) => (t) => {
|
|
2524
2524
|
n.push(t), ds || (ds = !0, e && q.$flags$ & 4 ? zc(ps) : q.raf(ps));
|
|
2525
2525
|
}, dr = (n) => {
|
|
@@ -2549,7 +2549,7 @@ class qc {
|
|
|
2549
2549
|
this.voca_component = e, this.voca_added = jc(/* @__PURE__ */ new Date());
|
|
2550
2550
|
}
|
|
2551
2551
|
}
|
|
2552
|
-
const Wc = "telia-vst{display:none}", Gc = /* @__PURE__ */
|
|
2552
|
+
const Wc = "telia-vst{display:none}", Gc = /* @__PURE__ */ Ro(class extends yo {
|
|
2553
2553
|
constructor() {
|
|
2554
2554
|
super(), this.__registerHost(), this.vocaInternalUStats = $c(this, "vocaInternalUStats");
|
|
2555
2555
|
}
|
|
@@ -2587,7 +2587,7 @@ function Zc() {
|
|
|
2587
2587
|
function Yc() {
|
|
2588
2588
|
return fs().vocadsIconsRegistered;
|
|
2589
2589
|
}
|
|
2590
|
-
const Xc = ".telia-icon{display:inline-block}.telia-icon__container{display:block;height:inherit}.telia-icon svg{display:block}.telia-icon--sm{height:calc(1.6rem * var(--voca-rem-multiplier));min-width:calc(1.6rem * var(--voca-rem-multiplier));width:calc(1.6rem * var(--voca-rem-multiplier))}.telia-icon--md{height:calc(2.4rem * var(--voca-rem-multiplier));min-width:calc(2.4rem * var(--voca-rem-multiplier));width:calc(2.4rem * var(--voca-rem-multiplier))}.telia-icon--lg{height:calc(3.2rem * var(--voca-rem-multiplier));min-width:calc(3.2rem * var(--voca-rem-multiplier));width:calc(3.2rem * var(--voca-rem-multiplier))}", Kc = /* @__PURE__ */
|
|
2590
|
+
const Xc = ".telia-icon{display:inline-block}.telia-icon__container{display:block;height:inherit}.telia-icon svg{display:block}.telia-icon--sm{height:calc(1.6rem * var(--voca-rem-multiplier));min-width:calc(1.6rem * var(--voca-rem-multiplier));width:calc(1.6rem * var(--voca-rem-multiplier))}.telia-icon--md{height:calc(2.4rem * var(--voca-rem-multiplier));min-width:calc(2.4rem * var(--voca-rem-multiplier));width:calc(2.4rem * var(--voca-rem-multiplier))}.telia-icon--lg{height:calc(3.2rem * var(--voca-rem-multiplier));min-width:calc(3.2rem * var(--voca-rem-multiplier));width:calc(3.2rem * var(--voca-rem-multiplier))}", Kc = /* @__PURE__ */ Ro(class extends yo {
|
|
2591
2591
|
constructor() {
|
|
2592
2592
|
super(), this.__registerHost(), this.size = "md", this.allyTitle = null, this.dataTrackingId = "telia-icon";
|
|
2593
2593
|
}
|
|
@@ -4616,12 +4616,12 @@ class bs extends zs {
|
|
|
4616
4616
|
}
|
|
4617
4617
|
}
|
|
4618
4618
|
bs.directiveName = "unsafeHTML", bs.resultType = 1;
|
|
4619
|
-
const
|
|
4619
|
+
const Ru = En(bs);
|
|
4620
4620
|
/*! @license DOMPurify 3.2.6 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.6/LICENSE */
|
|
4621
4621
|
const {
|
|
4622
4622
|
entries: qo,
|
|
4623
4623
|
setPrototypeOf: kr,
|
|
4624
|
-
isFrozen:
|
|
4624
|
+
isFrozen: Lu,
|
|
4625
4625
|
getPrototypeOf: Ou,
|
|
4626
4626
|
getOwnPropertyDescriptor: Pu
|
|
4627
4627
|
} = Object;
|
|
@@ -4669,7 +4669,7 @@ function x(n, e) {
|
|
|
4669
4669
|
let i = e[s];
|
|
4670
4670
|
if (typeof i == "string") {
|
|
4671
4671
|
const r = t(i);
|
|
4672
|
-
r !== i && (
|
|
4672
|
+
r !== i && (Lu(e) || (e[s] = r), i = r);
|
|
4673
4673
|
}
|
|
4674
4674
|
n[i] = !0;
|
|
4675
4675
|
}
|
|
@@ -4709,7 +4709,7 @@ const Er = W(["a", "abbr", "acronym", "address", "area", "article", "aside", "au
|
|
|
4709
4709
|
/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
|
|
4710
4710
|
// eslint-disable-line no-control-regex
|
|
4711
4711
|
), Zo = J(/^html$/i), Xu = J(/^[a-z][.\w]*(-[.\w]+)+$/i);
|
|
4712
|
-
var
|
|
4712
|
+
var Rr = /* @__PURE__ */ Object.freeze({
|
|
4713
4713
|
__proto__: null,
|
|
4714
4714
|
ARIA_ATTR: Gu,
|
|
4715
4715
|
ATTR_WHITESPACE: Yu,
|
|
@@ -4750,7 +4750,7 @@ const vt = {
|
|
|
4750
4750
|
} catch {
|
|
4751
4751
|
return console.warn("TrustedTypes policy " + r + " could not be created."), null;
|
|
4752
4752
|
}
|
|
4753
|
-
},
|
|
4753
|
+
}, Lr = function() {
|
|
4754
4754
|
return {
|
|
4755
4755
|
afterSanitizeAttributes: [],
|
|
4756
4756
|
afterSanitizeElements: [],
|
|
@@ -4786,7 +4786,7 @@ function Yo() {
|
|
|
4786
4786
|
const b = t.createElement("template");
|
|
4787
4787
|
b.content && b.content.ownerDocument && (t = b.content.ownerDocument);
|
|
4788
4788
|
}
|
|
4789
|
-
let
|
|
4789
|
+
let L, Ae = "";
|
|
4790
4790
|
const {
|
|
4791
4791
|
implementation: Ce,
|
|
4792
4792
|
createNodeIterator: Te,
|
|
@@ -4795,21 +4795,21 @@ function Yo() {
|
|
|
4795
4795
|
} = t, {
|
|
4796
4796
|
importNode: da
|
|
4797
4797
|
} = s;
|
|
4798
|
-
let B =
|
|
4798
|
+
let B = Lr();
|
|
4799
4799
|
e.isSupported = typeof qo == "function" && typeof Ee == "function" && Ce && Ce.createHTMLDocument !== void 0;
|
|
4800
4800
|
const {
|
|
4801
4801
|
MUSTACHE_EXPR: Tn,
|
|
4802
|
-
ERB_EXPR:
|
|
4803
|
-
TMPLIT_EXPR:
|
|
4802
|
+
ERB_EXPR: Rn,
|
|
4803
|
+
TMPLIT_EXPR: Ln,
|
|
4804
4804
|
DATA_ATTR: pa,
|
|
4805
4805
|
ARIA_ATTR: fa,
|
|
4806
4806
|
IS_SCRIPT_OR_DATA: ga,
|
|
4807
4807
|
ATTR_WHITESPACE: di,
|
|
4808
4808
|
CUSTOM_ELEMENT: ma
|
|
4809
|
-
} =
|
|
4809
|
+
} = Rr;
|
|
4810
4810
|
let {
|
|
4811
4811
|
IS_ALLOWED_URI: pi
|
|
4812
|
-
} =
|
|
4812
|
+
} = Rr, O = null;
|
|
4813
4813
|
const fi = x({}, [...Er, ...Qn, ...Jn, ...es, ...Ar]);
|
|
4814
4814
|
let D = null;
|
|
4815
4815
|
const gi = x({}, [...Cr, ...ts, ...Tr, ...Xt]);
|
|
@@ -4832,7 +4832,7 @@ function Yo() {
|
|
|
4832
4832
|
enumerable: !0,
|
|
4833
4833
|
value: !1
|
|
4834
4834
|
}
|
|
4835
|
-
})), lt = null, On = null, mi = !0, Pn = !0, vi = !1, bi = !0, He = !1, zt = !0,
|
|
4835
|
+
})), lt = null, On = null, mi = !0, Pn = !0, vi = !1, bi = !0, He = !1, zt = !0, Re = !1, In = !1, Mn = !1, Fe = !1, Bt = !1, Ht = !1, yi = !0, $i = !1;
|
|
4836
4836
|
const va = "user-content-";
|
|
4837
4837
|
let Nn = !0, ct = !1, je = {}, qe = null;
|
|
4838
4838
|
const xi = x({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
|
|
@@ -4853,14 +4853,14 @@ function Yo() {
|
|
|
4853
4853
|
let h = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
4854
4854
|
if (!(Ge && Ge === h)) {
|
|
4855
4855
|
if ((!h || typeof h != "object") && (h = {}), h = ge(h), ut = // eslint-disable-next-line unicorn/prefer-includes
|
|
4856
|
-
$a.indexOf(h.PARSER_MEDIA_TYPE) === -1 ? xa : h.PARSER_MEDIA_TYPE, P = ut === "application/xhtml+xml" ? Vn : Jt, O = te(h, "ALLOWED_TAGS") ? x({}, h.ALLOWED_TAGS, P) : fi, D = te(h, "ALLOWED_ATTR") ? x({}, h.ALLOWED_ATTR, P) : gi, zn = te(h, "ALLOWED_NAMESPACES") ? x({}, h.ALLOWED_NAMESPACES, Vn) : ba, Dn = te(h, "ADD_URI_SAFE_ATTR") ? x(ge(Si), h.ADD_URI_SAFE_ATTR, P) : Si, wi = te(h, "ADD_DATA_URI_TAGS") ? x(ge(ki), h.ADD_DATA_URI_TAGS, P) : ki, qe = te(h, "FORBID_CONTENTS") ? x({}, h.FORBID_CONTENTS, P) : xi, lt = te(h, "FORBID_TAGS") ? x({}, h.FORBID_TAGS, P) : ge({}), On = te(h, "FORBID_ATTR") ? x({}, h.FORBID_ATTR, P) : ge({}), je = te(h, "USE_PROFILES") ? h.USE_PROFILES : !1, mi = h.ALLOW_ARIA_ATTR !== !1, Pn = h.ALLOW_DATA_ATTR !== !1, vi = h.ALLOW_UNKNOWN_PROTOCOLS || !1, bi = h.ALLOW_SELF_CLOSE_IN_ATTR !== !1, He = h.SAFE_FOR_TEMPLATES || !1, zt = h.SAFE_FOR_XML !== !1,
|
|
4856
|
+
$a.indexOf(h.PARSER_MEDIA_TYPE) === -1 ? xa : h.PARSER_MEDIA_TYPE, P = ut === "application/xhtml+xml" ? Vn : Jt, O = te(h, "ALLOWED_TAGS") ? x({}, h.ALLOWED_TAGS, P) : fi, D = te(h, "ALLOWED_ATTR") ? x({}, h.ALLOWED_ATTR, P) : gi, zn = te(h, "ALLOWED_NAMESPACES") ? x({}, h.ALLOWED_NAMESPACES, Vn) : ba, Dn = te(h, "ADD_URI_SAFE_ATTR") ? x(ge(Si), h.ADD_URI_SAFE_ATTR, P) : Si, wi = te(h, "ADD_DATA_URI_TAGS") ? x(ge(ki), h.ADD_DATA_URI_TAGS, P) : ki, qe = te(h, "FORBID_CONTENTS") ? x({}, h.FORBID_CONTENTS, P) : xi, lt = te(h, "FORBID_TAGS") ? x({}, h.FORBID_TAGS, P) : ge({}), On = te(h, "FORBID_ATTR") ? x({}, h.FORBID_ATTR, P) : ge({}), je = te(h, "USE_PROFILES") ? h.USE_PROFILES : !1, mi = h.ALLOW_ARIA_ATTR !== !1, Pn = h.ALLOW_DATA_ATTR !== !1, vi = h.ALLOW_UNKNOWN_PROTOCOLS || !1, bi = h.ALLOW_SELF_CLOSE_IN_ATTR !== !1, He = h.SAFE_FOR_TEMPLATES || !1, zt = h.SAFE_FOR_XML !== !1, Re = h.WHOLE_DOCUMENT || !1, Fe = h.RETURN_DOM || !1, Bt = h.RETURN_DOM_FRAGMENT || !1, Ht = h.RETURN_TRUSTED_TYPE || !1, Mn = h.FORCE_BODY || !1, yi = h.SANITIZE_DOM !== !1, $i = h.SANITIZE_NAMED_PROPS || !1, Nn = h.KEEP_CONTENT !== !1, ct = h.IN_PLACE || !1, pi = h.ALLOWED_URI_REGEXP || Go, We = h.NAMESPACE || he, qt = h.MATHML_TEXT_INTEGRATION_POINTS || qt, Wt = h.HTML_INTEGRATION_POINTS || Wt, T = h.CUSTOM_ELEMENT_HANDLING || {}, h.CUSTOM_ELEMENT_HANDLING && _i(h.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (T.tagNameCheck = h.CUSTOM_ELEMENT_HANDLING.tagNameCheck), h.CUSTOM_ELEMENT_HANDLING && _i(h.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (T.attributeNameCheck = h.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), h.CUSTOM_ELEMENT_HANDLING && typeof h.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (T.allowCustomizedBuiltInElements = h.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), He && (Pn = !1), Bt && (Fe = !0), je && (O = x({}, Ar), D = [], je.html === !0 && (x(O, Er), x(D, Cr)), je.svg === !0 && (x(O, Qn), x(D, ts), x(D, Xt)), je.svgFilters === !0 && (x(O, Jn), x(D, ts), x(D, Xt)), je.mathMl === !0 && (x(O, es), x(D, Tr), x(D, Xt))), h.ADD_TAGS && (O === fi && (O = ge(O)), x(O, h.ADD_TAGS, P)), h.ADD_ATTR && (D === gi && (D = ge(D)), x(D, h.ADD_ATTR, P)), h.ADD_URI_SAFE_ATTR && x(Dn, h.ADD_URI_SAFE_ATTR, P), h.FORBID_CONTENTS && (qe === xi && (qe = ge(qe)), x(qe, h.FORBID_CONTENTS, P)), Nn && (O["#text"] = !0), Re && x(O, ["html", "head", "body"]), O.table && (x(O, ["tbody"]), delete lt.tbody), h.TRUSTED_TYPES_POLICY) {
|
|
4857
4857
|
if (typeof h.TRUSTED_TYPES_POLICY.createHTML != "function")
|
|
4858
4858
|
throw gt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
|
|
4859
4859
|
if (typeof h.TRUSTED_TYPES_POLICY.createScriptURL != "function")
|
|
4860
4860
|
throw gt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
|
|
4861
|
-
|
|
4861
|
+
L = h.TRUSTED_TYPES_POLICY, Ae = L.createHTML("");
|
|
4862
4862
|
} else
|
|
4863
|
-
|
|
4863
|
+
L === void 0 && (L = Vu(g, i)), L !== null && typeof Ae == "string" && (Ae = L.createHTML(""));
|
|
4864
4864
|
W && W(h), Ge = h;
|
|
4865
4865
|
}
|
|
4866
4866
|
}, Ei = x({}, [...Qn, ...Jn, ...Bu]), Ai = x({}, [...es, ...Hu]), ka = function(h) {
|
|
@@ -4908,11 +4908,11 @@ function Yo() {
|
|
|
4908
4908
|
if (Mn)
|
|
4909
4909
|
h = "<remove></remove>" + h;
|
|
4910
4910
|
else {
|
|
4911
|
-
const
|
|
4912
|
-
v =
|
|
4911
|
+
const R = _r(h, /^[\r\n\t ]+/);
|
|
4912
|
+
v = R && R[0];
|
|
4913
4913
|
}
|
|
4914
4914
|
ut === "application/xhtml+xml" && We === he && (h = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + h + "</body></html>");
|
|
4915
|
-
const A =
|
|
4915
|
+
const A = L ? L.createHTML(h) : h;
|
|
4916
4916
|
if (We === he)
|
|
4917
4917
|
try {
|
|
4918
4918
|
f = new d().parseFromString(A, ut);
|
|
@@ -4926,7 +4926,7 @@ function Yo() {
|
|
|
4926
4926
|
}
|
|
4927
4927
|
}
|
|
4928
4928
|
const U = f.body || f.documentElement;
|
|
4929
|
-
return h && v && U.insertBefore(t.createTextNode(v), U.childNodes[0] || null), We === he ? ha.call(f,
|
|
4929
|
+
return h && v && U.insertBefore(t.createTextNode(v), U.childNodes[0] || null), We === he ? ha.call(f, Re ? "html" : "body")[0] : Re ? f.documentElement : U;
|
|
4930
4930
|
}, Ti = function(h) {
|
|
4931
4931
|
return Te.call(
|
|
4932
4932
|
h.ownerDocument || h,
|
|
@@ -4937,7 +4937,7 @@ function Yo() {
|
|
|
4937
4937
|
);
|
|
4938
4938
|
}, Hn = function(h) {
|
|
4939
4939
|
return h instanceof p && (typeof h.nodeName != "string" || typeof h.textContent != "string" || typeof h.removeChild != "function" || !(h.attributes instanceof u) || typeof h.removeAttribute != "function" || typeof h.setAttribute != "function" || typeof h.namespaceURI != "string" || typeof h.insertBefore != "function" || typeof h.hasChildNodes != "function");
|
|
4940
|
-
},
|
|
4940
|
+
}, Ri = function(h) {
|
|
4941
4941
|
return typeof a == "function" && h instanceof a;
|
|
4942
4942
|
};
|
|
4943
4943
|
function de(b, h, f) {
|
|
@@ -4945,7 +4945,7 @@ function Yo() {
|
|
|
4945
4945
|
v.call(e, h, f, Ge);
|
|
4946
4946
|
});
|
|
4947
4947
|
}
|
|
4948
|
-
const
|
|
4948
|
+
const Li = function(h) {
|
|
4949
4949
|
let f = null;
|
|
4950
4950
|
if (de(B.beforeSanitizeElements, h, null), Hn(h))
|
|
4951
4951
|
return ie(h), !0;
|
|
@@ -4953,7 +4953,7 @@ function Yo() {
|
|
|
4953
4953
|
if (de(B.uponSanitizeElement, h, {
|
|
4954
4954
|
tagName: v,
|
|
4955
4955
|
allowedTags: O
|
|
4956
|
-
}), zt && h.hasChildNodes() && !
|
|
4956
|
+
}), zt && h.hasChildNodes() && !Ri(h.firstElementChild) && H(/<[/\w!]/g, h.innerHTML) && H(/<[/\w!]/g, h.textContent) || h.nodeType === vt.progressingInstruction || zt && h.nodeType === vt.comment && H(/<[/\w]/g, h.data))
|
|
4957
4957
|
return ie(h), !0;
|
|
4958
4958
|
if (!O[v] || lt[v]) {
|
|
4959
4959
|
if (!lt[v] && Pi(v) && (T.tagNameCheck instanceof RegExp && H(T.tagNameCheck, v) || T.tagNameCheck instanceof Function && T.tagNameCheck(v)))
|
|
@@ -4961,8 +4961,8 @@ function Yo() {
|
|
|
4961
4961
|
if (Nn && !qe[v]) {
|
|
4962
4962
|
const A = Ee(h) || h.parentNode, U = xe(h) || h.childNodes;
|
|
4963
4963
|
if (U && A) {
|
|
4964
|
-
const
|
|
4965
|
-
for (let Y =
|
|
4964
|
+
const R = U.length;
|
|
4965
|
+
for (let Y = R - 1; Y >= 0; --Y) {
|
|
4966
4966
|
const pe = y(U[Y], !0);
|
|
4967
4967
|
pe.__removalCount = (h.__removalCount || 0) + 1, A.insertBefore(pe, ee(h));
|
|
4968
4968
|
}
|
|
@@ -4970,7 +4970,7 @@ function Yo() {
|
|
|
4970
4970
|
}
|
|
4971
4971
|
return ie(h), !0;
|
|
4972
4972
|
}
|
|
4973
|
-
return h instanceof l && !ka(h) || (v === "noscript" || v === "noembed" || v === "noframes") && H(/<\/no(script|embed|frames)/i, h.innerHTML) ? (ie(h), !0) : (He && h.nodeType === vt.text && (f = h.textContent, Yt([Tn,
|
|
4973
|
+
return h instanceof l && !ka(h) || (v === "noscript" || v === "noembed" || v === "noframes") && H(/<\/no(script|embed|frames)/i, h.innerHTML) ? (ie(h), !0) : (He && h.nodeType === vt.text && (f = h.textContent, Yt([Tn, Rn, Ln], (A) => {
|
|
4974
4974
|
f = ft(f, A, " ");
|
|
4975
4975
|
}), h.textContent !== f && (pt(e.removed, {
|
|
4976
4976
|
element: h.cloneNode()
|
|
@@ -5021,49 +5021,49 @@ function Yo() {
|
|
|
5021
5021
|
let A = f.length;
|
|
5022
5022
|
for (; A--; ) {
|
|
5023
5023
|
const U = f[A], {
|
|
5024
|
-
name:
|
|
5024
|
+
name: R,
|
|
5025
5025
|
namespaceURI: Y,
|
|
5026
5026
|
value: pe
|
|
5027
|
-
} = U, ht = P(
|
|
5028
|
-
let z =
|
|
5029
|
-
if (v.attrName = ht, v.attrValue = z, v.keepAttr = !0, v.forceKeepAttr = void 0, de(B.uponSanitizeAttribute, h, v), z = v.attrValue, $i && (ht === "id" || ht === "name") && (Ze(
|
|
5030
|
-
Ze(
|
|
5027
|
+
} = U, ht = P(R), Fn = pe;
|
|
5028
|
+
let z = R === "value" ? Fn : Du(Fn);
|
|
5029
|
+
if (v.attrName = ht, v.attrValue = z, v.keepAttr = !0, v.forceKeepAttr = void 0, de(B.uponSanitizeAttribute, h, v), z = v.attrValue, $i && (ht === "id" || ht === "name") && (Ze(R, h), z = va + z), zt && H(/((--!?|])>)|<\/(style|title)/i, z)) {
|
|
5030
|
+
Ze(R, h);
|
|
5031
5031
|
continue;
|
|
5032
5032
|
}
|
|
5033
5033
|
if (v.forceKeepAttr)
|
|
5034
5034
|
continue;
|
|
5035
5035
|
if (!v.keepAttr) {
|
|
5036
|
-
Ze(
|
|
5036
|
+
Ze(R, h);
|
|
5037
5037
|
continue;
|
|
5038
5038
|
}
|
|
5039
5039
|
if (!bi && H(/\/>/i, z)) {
|
|
5040
|
-
Ze(
|
|
5040
|
+
Ze(R, h);
|
|
5041
5041
|
continue;
|
|
5042
5042
|
}
|
|
5043
|
-
He && Yt([Tn,
|
|
5043
|
+
He && Yt([Tn, Rn, Ln], (Ni) => {
|
|
5044
5044
|
z = ft(z, Ni, " ");
|
|
5045
5045
|
});
|
|
5046
5046
|
const Mi = P(h.nodeName);
|
|
5047
5047
|
if (!Oi(Mi, ht, z)) {
|
|
5048
|
-
Ze(
|
|
5048
|
+
Ze(R, h);
|
|
5049
5049
|
continue;
|
|
5050
5050
|
}
|
|
5051
|
-
if (
|
|
5051
|
+
if (L && typeof g == "object" && typeof g.getAttributeType == "function" && !Y)
|
|
5052
5052
|
switch (g.getAttributeType(Mi, ht)) {
|
|
5053
5053
|
case "TrustedHTML": {
|
|
5054
|
-
z =
|
|
5054
|
+
z = L.createHTML(z);
|
|
5055
5055
|
break;
|
|
5056
5056
|
}
|
|
5057
5057
|
case "TrustedScriptURL": {
|
|
5058
|
-
z =
|
|
5058
|
+
z = L.createScriptURL(z);
|
|
5059
5059
|
break;
|
|
5060
5060
|
}
|
|
5061
5061
|
}
|
|
5062
5062
|
if (z !== Fn)
|
|
5063
5063
|
try {
|
|
5064
|
-
Y ? h.setAttributeNS(Y,
|
|
5064
|
+
Y ? h.setAttributeNS(Y, R, z) : h.setAttribute(R, z), Hn(h) ? ie(h) : Sr(e.removed);
|
|
5065
5065
|
} catch {
|
|
5066
|
-
Ze(
|
|
5066
|
+
Ze(R, h);
|
|
5067
5067
|
}
|
|
5068
5068
|
}
|
|
5069
5069
|
de(B.afterSanitizeAttributes, h, null);
|
|
@@ -5071,12 +5071,12 @@ function Yo() {
|
|
|
5071
5071
|
let f = null;
|
|
5072
5072
|
const v = Ti(h);
|
|
5073
5073
|
for (de(B.beforeSanitizeShadowDOM, h, null); f = v.nextNode(); )
|
|
5074
|
-
de(B.uponSanitizeShadowNode, f, null),
|
|
5074
|
+
de(B.uponSanitizeShadowNode, f, null), Li(f), Ii(f), f.content instanceof r && b(f.content);
|
|
5075
5075
|
de(B.afterSanitizeShadowDOM, h, null);
|
|
5076
5076
|
};
|
|
5077
5077
|
return e.sanitize = function(b) {
|
|
5078
5078
|
let h = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, f = null, v = null, A = null, U = null;
|
|
5079
|
-
if (Un = !b, Un && (b = "<!-->"), typeof b != "string" && !
|
|
5079
|
+
if (Un = !b, Un && (b = "<!-->"), typeof b != "string" && !Ri(b))
|
|
5080
5080
|
if (typeof b.toString == "function") {
|
|
5081
5081
|
if (b = b.toString(), typeof b != "string")
|
|
5082
5082
|
throw gt("dirty is not a string, aborting");
|
|
@@ -5093,16 +5093,16 @@ function Yo() {
|
|
|
5093
5093
|
} else if (b instanceof a)
|
|
5094
5094
|
f = Ci("<!---->"), v = f.ownerDocument.importNode(b, !0), v.nodeType === vt.element && v.nodeName === "BODY" || v.nodeName === "HTML" ? f = v : f.appendChild(v);
|
|
5095
5095
|
else {
|
|
5096
|
-
if (!Fe && !He && !
|
|
5096
|
+
if (!Fe && !He && !Re && // eslint-disable-next-line unicorn/prefer-includes
|
|
5097
5097
|
b.indexOf("<") === -1)
|
|
5098
|
-
return
|
|
5098
|
+
return L && Ht ? L.createHTML(b) : b;
|
|
5099
5099
|
if (f = Ci(b), !f)
|
|
5100
5100
|
return Fe ? null : Ht ? Ae : "";
|
|
5101
5101
|
}
|
|
5102
5102
|
f && Mn && ie(f.firstChild);
|
|
5103
|
-
const
|
|
5104
|
-
for (; A =
|
|
5105
|
-
|
|
5103
|
+
const R = Ti(ct ? b : f);
|
|
5104
|
+
for (; A = R.nextNode(); )
|
|
5105
|
+
Li(A), Ii(A), A.content instanceof r && Sa(A.content);
|
|
5106
5106
|
if (ct)
|
|
5107
5107
|
return b;
|
|
5108
5108
|
if (Fe) {
|
|
@@ -5113,11 +5113,11 @@ function Yo() {
|
|
|
5113
5113
|
U = f;
|
|
5114
5114
|
return (D.shadowroot || D.shadowrootmode) && (U = da.call(s, U, !0)), U;
|
|
5115
5115
|
}
|
|
5116
|
-
let Y =
|
|
5117
|
-
return
|
|
5118
|
-
` + Y), He && Yt([Tn,
|
|
5116
|
+
let Y = Re ? f.outerHTML : f.innerHTML;
|
|
5117
|
+
return Re && O["!doctype"] && f.ownerDocument && f.ownerDocument.doctype && f.ownerDocument.doctype.name && H(Zo, f.ownerDocument.doctype.name) && (Y = "<!DOCTYPE " + f.ownerDocument.doctype.name + `>
|
|
5118
|
+
` + Y), He && Yt([Tn, Rn, Ln], (pe) => {
|
|
5119
5119
|
Y = ft(Y, pe, " ");
|
|
5120
|
-
}),
|
|
5120
|
+
}), L && Ht ? L.createHTML(Y) : Y;
|
|
5121
5121
|
}, e.setConfig = function() {
|
|
5122
5122
|
let b = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
|
|
5123
5123
|
Bn(b), In = !0;
|
|
@@ -5138,7 +5138,7 @@ function Yo() {
|
|
|
5138
5138
|
}, e.removeHooks = function(b) {
|
|
5139
5139
|
B[b] = [];
|
|
5140
5140
|
}, e.removeAllHooks = function() {
|
|
5141
|
-
B =
|
|
5141
|
+
B = Lr();
|
|
5142
5142
|
}, e;
|
|
5143
5143
|
}
|
|
5144
5144
|
var Xo = Yo(), Qu = Object.defineProperty, Ju = (n, e, t, s) => {
|
|
@@ -5149,7 +5149,7 @@ var Xo = Yo(), Qu = Object.defineProperty, Ju = (n, e, t, s) => {
|
|
|
5149
5149
|
const li = class li extends M {
|
|
5150
5150
|
render() {
|
|
5151
5151
|
return w`<div class="message-type-html">
|
|
5152
|
-
${
|
|
5152
|
+
${Ru(Xo.sanitize(this.message.content))}
|
|
5153
5153
|
</div>`;
|
|
5154
5154
|
}
|
|
5155
5155
|
};
|
|
@@ -5343,7 +5343,7 @@ var j = {
|
|
|
5343
5343
|
tag: Ah,
|
|
5344
5344
|
text: fh,
|
|
5345
5345
|
url: kt
|
|
5346
|
-
},
|
|
5346
|
+
}, Rh = {
|
|
5347
5347
|
...Ks,
|
|
5348
5348
|
link: S(/^!?\[(label)\]\((.*?)\)/).replace("label", gn).getRegex(),
|
|
5349
5349
|
reflink: S(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", gn).getRegex()
|
|
@@ -5355,7 +5355,7 @@ var j = {
|
|
|
5355
5355
|
_backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
|
|
5356
5356
|
del: /^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,
|
|
5357
5357
|
text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
|
|
5358
|
-
},
|
|
5358
|
+
}, Lh = {
|
|
5359
5359
|
...xs,
|
|
5360
5360
|
br: S(ea).replace("{2,}", "*").getRegex(),
|
|
5361
5361
|
text: S(xs.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
|
|
@@ -5366,8 +5366,8 @@ var j = {
|
|
|
5366
5366
|
}, bt = {
|
|
5367
5367
|
normal: Ks,
|
|
5368
5368
|
gfm: xs,
|
|
5369
|
-
breaks:
|
|
5370
|
-
pedantic:
|
|
5369
|
+
breaks: Lh,
|
|
5370
|
+
pedantic: Rh
|
|
5371
5371
|
}, Oh = {
|
|
5372
5372
|
"&": "&",
|
|
5373
5373
|
"<": "<",
|
|
@@ -5605,18 +5605,18 @@ ${u}` : u;
|
|
|
5605
5605
|
`, 1)[0], g = !p.trim(), m = 0;
|
|
5606
5606
|
if (this.options.pedantic ? (m = 2, u = p.trimStart()) : g ? m = e[1].length + 1 : (m = e[2].search(this.rules.other.nonSpaceChar), m = m > 4 ? 1 : m, u = p.slice(m), m += e[1].length), g && this.rules.other.blankLine.test(d) && (c += d + `
|
|
5607
5607
|
`, n = n.substring(d.length + 1), l = !0), !l) {
|
|
5608
|
-
const ee = this.rules.other.nextBulletRegex(m), xe = this.rules.other.hrRegex(m), Ee = this.rules.other.fencesBeginRegex(m),
|
|
5608
|
+
const ee = this.rules.other.nextBulletRegex(m), xe = this.rules.other.hrRegex(m), Ee = this.rules.other.fencesBeginRegex(m), L = this.rules.other.headingBeginRegex(m), Ae = this.rules.other.htmlBeginRegex(m);
|
|
5609
5609
|
for (; n; ) {
|
|
5610
5610
|
const Ce = n.split(`
|
|
5611
5611
|
`, 1)[0];
|
|
5612
5612
|
let Te;
|
|
5613
|
-
if (d = Ce, this.options.pedantic ? (d = d.replace(this.rules.other.listReplaceNesting, " "), Te = d) : Te = d.replace(this.rules.other.tabCharGlobal, " "), Ee.test(d) ||
|
|
5613
|
+
if (d = Ce, this.options.pedantic ? (d = d.replace(this.rules.other.listReplaceNesting, " "), Te = d) : Te = d.replace(this.rules.other.tabCharGlobal, " "), Ee.test(d) || L.test(d) || Ae.test(d) || ee.test(d) || xe.test(d))
|
|
5614
5614
|
break;
|
|
5615
5615
|
if (Te.search(this.rules.other.nonSpaceChar) >= m || !d.trim())
|
|
5616
5616
|
u += `
|
|
5617
5617
|
` + Te.slice(m);
|
|
5618
5618
|
else {
|
|
5619
|
-
if (g || p.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || Ee.test(p) ||
|
|
5619
|
+
if (g || p.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || Ee.test(p) || L.test(p) || xe.test(p))
|
|
5620
5620
|
break;
|
|
5621
5621
|
u += `
|
|
5622
5622
|
` + d;
|
|
@@ -6184,7 +6184,7 @@ ${u}` : u;
|
|
|
6184
6184
|
}
|
|
6185
6185
|
return t;
|
|
6186
6186
|
}
|
|
6187
|
-
},
|
|
6187
|
+
}, Rt = class {
|
|
6188
6188
|
// set by the parser
|
|
6189
6189
|
constructor(n) {
|
|
6190
6190
|
_(this, "options");
|
|
@@ -6353,7 +6353,7 @@ ${n}</tr>
|
|
|
6353
6353
|
_(this, "options");
|
|
6354
6354
|
_(this, "renderer");
|
|
6355
6355
|
_(this, "textRenderer");
|
|
6356
|
-
this.options = e || Be, this.options.renderer = this.options.renderer || new
|
|
6356
|
+
this.options = e || Be, this.options.renderer = this.options.renderer || new Rt(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new Vs();
|
|
6357
6357
|
}
|
|
6358
6358
|
/**
|
|
6359
6359
|
* Static Parse Method
|
|
@@ -6557,7 +6557,7 @@ ${n}</tr>
|
|
|
6557
6557
|
_(this, "parse", this.parseMarkdown(!0));
|
|
6558
6558
|
_(this, "parseInline", this.parseMarkdown(!1));
|
|
6559
6559
|
_(this, "Parser", ve);
|
|
6560
|
-
_(this, "Renderer",
|
|
6560
|
+
_(this, "Renderer", Rt);
|
|
6561
6561
|
_(this, "TextRenderer", Vs);
|
|
6562
6562
|
_(this, "Lexer", me);
|
|
6563
6563
|
_(this, "Tokenizer", mn);
|
|
@@ -6618,7 +6618,7 @@ ${n}</tr>
|
|
|
6618
6618
|
}
|
|
6619
6619
|
"childTokens" in i && i.childTokens && (e.childTokens[i.name] = i.childTokens);
|
|
6620
6620
|
}), s.extensions = e), t.renderer) {
|
|
6621
|
-
const i = this.defaults.renderer || new
|
|
6621
|
+
const i = this.defaults.renderer || new Rt(this.defaults);
|
|
6622
6622
|
for (const r in t.renderer) {
|
|
6623
6623
|
if (!(r in i))
|
|
6624
6624
|
throw new Error(`renderer '${r}' does not exist`);
|
|
@@ -6740,7 +6740,7 @@ k.walkTokens = function(n, e) {
|
|
|
6740
6740
|
k.parseInline = ze.parseInline;
|
|
6741
6741
|
k.Parser = ve;
|
|
6742
6742
|
k.parser = ve.parse;
|
|
6743
|
-
k.Renderer =
|
|
6743
|
+
k.Renderer = Rt;
|
|
6744
6744
|
k.TextRenderer = Vs;
|
|
6745
6745
|
k.Lexer = me;
|
|
6746
6746
|
k.lexer = me.lex;
|
|
@@ -6759,7 +6759,7 @@ var Nh = Object.defineProperty, aa = (n, e, t, s) => {
|
|
|
6759
6759
|
(o = n[r]) && (i = o(e, t, i) || i);
|
|
6760
6760
|
return i && Nh(e, t, i), i;
|
|
6761
6761
|
};
|
|
6762
|
-
const la = new
|
|
6762
|
+
const la = new Rt();
|
|
6763
6763
|
la.link = function({ href: n, title: e, text: t }) {
|
|
6764
6764
|
return e ?? (e = t), `<a target="_blank" href="${n}" title="${e}">${t}</a>`;
|
|
6765
6765
|
};
|
|
@@ -6812,7 +6812,8 @@ const ci = class ci extends M {
|
|
|
6812
6812
|
if (!e) return;
|
|
6813
6813
|
this.buffer += e;
|
|
6814
6814
|
const t = Xo.sanitize(
|
|
6815
|
-
k.parse(this.buffer)
|
|
6815
|
+
k.parse(this.buffer),
|
|
6816
|
+
{ ADD_ATTR: ["target"] }
|
|
6816
6817
|
);
|
|
6817
6818
|
if (this.includesImage(this.buffer))
|
|
6818
6819
|
(i = this.contentRef.value) == null || i.appendChild(document.createElement("div")), this.buffer = "";
|
|
@@ -6883,13 +6884,13 @@ ci.styles = [
|
|
|
6883
6884
|
}
|
|
6884
6885
|
`
|
|
6885
6886
|
];
|
|
6886
|
-
let
|
|
6887
|
+
let Lt = ci;
|
|
6887
6888
|
aa([
|
|
6888
6889
|
C({ attribute: !1 })
|
|
6889
|
-
],
|
|
6890
|
+
], Lt.prototype, "message");
|
|
6890
6891
|
aa([
|
|
6891
6892
|
N()
|
|
6892
|
-
],
|
|
6893
|
+
], Lt.prototype, "showLightbox");
|
|
6893
6894
|
var Dh = Object.defineProperty, Uh = (n, e, t, s) => {
|
|
6894
6895
|
for (var i = void 0, r = n.length - 1, o; r >= 0; r--)
|
|
6895
6896
|
(o = n[r]) && (i = o(e, t, i) || i);
|
|
@@ -6993,7 +6994,7 @@ customElements.get("ace-conversation-feed") || customElements.define("ace-conver
|
|
|
6993
6994
|
customElements.get("conversation-group") || customElements.define("conversation-group", pn);
|
|
6994
6995
|
customElements.get("ace-typing-state") || customElements.define("ace-typing-state", vs);
|
|
6995
6996
|
customElements.get("message-type-html") || customElements.define("message-type-html", fn);
|
|
6996
|
-
customElements.get("message-type-markdown") || customElements.define("message-type-markdown",
|
|
6997
|
+
customElements.get("message-type-markdown") || customElements.define("message-type-markdown", Lt);
|
|
6997
6998
|
customElements.get("ace-lightbox") || customElements.define("ace-lightbox", vn);
|
|
6998
6999
|
const Dr = Do(M), hi = class hi extends Dr {
|
|
6999
7000
|
constructor() {
|