erl-mathtextx-editor 0.1.2 → 0.1.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/dist/{CellPropertiesDialogImpl-CgWcr4bD.js → CellPropertiesDialogImpl-D2iy6DEr.js} +1 -1
- package/dist/{ContentViewer-DcvxXP9t.js → ContentViewer-COGXSiwX.js} +1 -1
- package/dist/{ImageInsertDialog-Di0MXcC2.js → ImageInsertDialog-Cn-IrnHN.js} +50 -55
- package/dist/{InsertTableDialogImpl-CKirXRqE.js → InsertTableDialogImpl-Dpo1pByJ.js} +1 -1
- package/dist/{LinkDialogImpl-BSz0F-xG.js → LinkDialogImpl-C1YeHJFJ.js} +27 -27
- package/dist/{TableTemplatesDialogImpl-DrdqLQLH.js → TableTemplatesDialogImpl-CMzxe328.js} +1 -1
- package/dist/assets/erl-mathtextx-editor.css +1 -1
- package/dist/assets/viewer.css +1 -1
- package/dist/erl-mathtextx-editor.js +2 -2
- package/dist/{index-DYxMVo98.js → index-jQUBaVKf.js} +857 -885
- package/dist/{mathlive-BwNIIOwE.js → mathlive-Bi6rleK6.js} +113 -113
- package/dist/{tiptap-BhJ7Fu9S.js → tiptap-Bc1mIOtx.js} +26 -26
- package/dist/{viewer-deps-xNPNdmbe.js → viewer-deps-CjbAqdti.js} +1 -1
- package/dist/viewer.js +1 -1
- package/package.json +4 -3
|
@@ -72,7 +72,7 @@ var $ = { strings: op, _locale: "", _dirty: !1, _subscribers: [], _numberFormatt
|
|
|
72
72
|
return $._dirty;
|
|
73
73
|
}, set dirty(e) {
|
|
74
74
|
$._dirty || $._dirty === e || ($._dirty = !0, setTimeout(() => {
|
|
75
|
-
$._dirty = !1, this._subscribers.forEach((t) => t
|
|
75
|
+
$._dirty = !1, this._subscribers.forEach((t) => t?.());
|
|
76
76
|
}, 0));
|
|
77
77
|
}, subscribe(e) {
|
|
78
78
|
return $._subscribers.push(e), $._subscribers.length - 1;
|
|
@@ -119,7 +119,7 @@ function qo(e) {
|
|
|
119
119
|
b && (l[0] = l[0].slice(1));
|
|
120
120
|
for (let x = 0; x < l.length; x++) {
|
|
121
121
|
s = d, u = h, c = p;
|
|
122
|
-
let y = (t = l[x].trim().match(/^([A-Za-z\d-]+)/)) == null ? void 0 : t[1], _ = y
|
|
122
|
+
let y = (t = l[x].trim().match(/^([A-Za-z\d-]+)/)) == null ? void 0 : t[1], _ = y?.toLowerCase(), S = y && (n = (o = (a = (r = (i = yi[_]) != null ? i : yi[Q0[y]]) != null ? r : up[y]) != null ? a : cp[y]) != null ? o : sp[y]) != null ? n : l[x].trim(), C = S.match(/^#([\da-f]{2})([\da-f]{2})([\da-f]{2})$/i);
|
|
123
123
|
if (C != null && C[1] && C[2] && C[3]) d = Math.max(0, Math.min(255, Number.parseInt(C[1], 16))), h = Math.max(0, Math.min(255, Number.parseInt(C[2], 16))), p = Math.max(0, Math.min(255, Number.parseInt(C[3], 16)));
|
|
124
124
|
else if (C = S.match(/^#([\da-f]{3})$/i), C != null && C[1]) {
|
|
125
125
|
let F = Number.parseInt(C[1][0], 16), A = Number.parseInt(C[1][1], 16), D = Number.parseInt(C[1][2], 16);
|
|
@@ -316,9 +316,9 @@ function ms(e, t) {
|
|
|
316
316
|
var i, r, a, o;
|
|
317
317
|
if (typeof e == "string") {
|
|
318
318
|
let n = 0, l = e;
|
|
319
|
-
return /(^|[^\\])#1/.test(l) && (n = 1), /(^|[^\\])#2/.test(l) && (n = 2), /(^|[^\\])#3/.test(l) && (n = 3), /(^|[^\\])#4/.test(l) && (n = 4), /(^|[^\\])#5/.test(l) && (n = 5), /(^|[^\\])#6/.test(l) && (n = 6), /(^|[^\\])#7/.test(l) && (n = 7), /(^|[^\\])#8/.test(l) && (n = 8), /(^|[^\\])#9/.test(l) && (n = 9), { expand: (i = t
|
|
319
|
+
return /(^|[^\\])#1/.test(l) && (n = 1), /(^|[^\\])#2/.test(l) && (n = 2), /(^|[^\\])#3/.test(l) && (n = 3), /(^|[^\\])#4/.test(l) && (n = 4), /(^|[^\\])#5/.test(l) && (n = 5), /(^|[^\\])#6/.test(l) && (n = 6), /(^|[^\\])#7/.test(l) && (n = 7), /(^|[^\\])#8/.test(l) && (n = 8), /(^|[^\\])#9/.test(l) && (n = 9), { expand: (i = t?.expand) != null ? i : !0, captureSelection: (r = t?.captureSelection) != null ? r : !0, args: n, def: l };
|
|
320
320
|
}
|
|
321
|
-
return f({ expand: (a = t
|
|
321
|
+
return f({ expand: (a = t?.expand) != null ? a : !0, captureSelection: (o = t?.captureSelection) != null ? o : !0, args: 0 }, e);
|
|
322
322
|
}
|
|
323
323
|
function Rl(e) {
|
|
324
324
|
if (!e) return {};
|
|
@@ -679,14 +679,14 @@ function zp(e, t) {
|
|
|
679
679
|
do {
|
|
680
680
|
if (c.length === 0) if (/^#[\d?@]$/.test(e.peek())) {
|
|
681
681
|
let d = e.get().slice(1);
|
|
682
|
-
c = Rr((r = (i = t
|
|
682
|
+
c = Rr((r = (i = t?.(d)) != null ? i : t?.("?")) != null ? r : "\\placeholder{}", t), l = c[0];
|
|
683
683
|
} else l = e.next(), c = l ? [l] : [];
|
|
684
684
|
u = c.length === 0, !u && l === "\\endcsname" && (u = !0, c.shift()), u || (u = l === "<$>" || l === "<$$>" || l === "<{>" || l === "<}>" || typeof l == "string" && l.length > 1 && l.startsWith("\\")), u || (s += c.shift());
|
|
685
685
|
} while (!u);
|
|
686
686
|
s && n.push("\\" + s), n.push(...c);
|
|
687
687
|
} else if (l !== "\\endcsname") if (l.length > 1 && l.startsWith("#")) {
|
|
688
688
|
let s = l.slice(1);
|
|
689
|
-
n.push(...Rr((o = (a = t
|
|
689
|
+
n.push(...Rr((o = (a = t?.(s)) != null ? a : t?.("?")) != null ? o : "\\placeholder{}", t));
|
|
690
690
|
} else n.push(l);
|
|
691
691
|
}
|
|
692
692
|
return n;
|
|
@@ -773,7 +773,7 @@ function kt(e, t) {
|
|
|
773
773
|
}
|
|
774
774
|
function u0(e, t) {
|
|
775
775
|
var i;
|
|
776
|
-
let { parent: r } = e[0], a = r
|
|
776
|
+
let { parent: r } = e[0], a = r?.style.color, o = [];
|
|
777
777
|
for (let n of sd(e)) {
|
|
778
778
|
let l = t.defaultMode;
|
|
779
779
|
for (let s of kt(n, "color")) {
|
|
@@ -784,7 +784,7 @@ function u0(e, t) {
|
|
|
784
784
|
return o;
|
|
785
785
|
}
|
|
786
786
|
function Kp(e, t) {
|
|
787
|
-
let { parent: i } = e[0], r = i
|
|
787
|
+
let { parent: i } = e[0], r = i?.style.backgroundColor;
|
|
788
788
|
return kt(e, "backgroundColor").map((a) => {
|
|
789
789
|
var o;
|
|
790
790
|
if (a.length > 0 || a[0].type !== "box") {
|
|
@@ -796,7 +796,7 @@ function Kp(e, t) {
|
|
|
796
796
|
}
|
|
797
797
|
function $p(e, t) {
|
|
798
798
|
if (e.length === 0) return [];
|
|
799
|
-
let { parent: i } = e[0], r = i
|
|
799
|
+
let { parent: i } = e[0], r = i?.style.fontSize, a = [];
|
|
800
800
|
for (let o of kt(e, "fontSize")) {
|
|
801
801
|
let n = o[0].style.fontSize, l = Kp(o, t);
|
|
802
802
|
l && (n && n !== "auto" && (!i || r !== n) ? a.push(["", "\\tiny", "\\scriptsize", "\\footnotesize", "\\small", "\\normalsize", "\\large", "\\Large", "\\LARGE", "\\huge", "\\Huge"][n], ...l) : a.push(...l));
|
|
@@ -823,9 +823,9 @@ var L = class ud {
|
|
|
823
823
|
constructor(t, i) {
|
|
824
824
|
var r, a, o, n, l;
|
|
825
825
|
if (typeof t == "number" ? this.value = String.fromCodePoint(t) : typeof t == "string" ? this.value = t : de(t) ? this.children = t.filter((u) => u !== null) : t && t instanceof ud && (this.children = [t]), this.children) for (let u of this.children) u.parent = this;
|
|
826
|
-
this.type = (r = i
|
|
827
|
-
let s = i
|
|
828
|
-
i != null && i.style && this.value && (s = (l = Te.getFont((n = i.mode) != null ? n : "math", this, g(f({ variant: "normal" }, i.style), { letterShapeStyle: i.letterShapeStyle }))) != null ? l : void 0), s || (s = "Main-Regular"), this._height = 0, this._depth = 0, this._width = 0, this.hasExplicitWidth = !1, this.skew = 0, this.italic = 0, this.maxFontSize = 0, this.scale = 1,
|
|
826
|
+
this.type = (r = i?.type) != null ? r : "ignore", this.isSelected = i?.isSelected === !0, i != null && i.caret && (this.caret = i.caret), this.classes = (a = i?.classes) != null ? a : "", this.isTight = (o = i?.isTight) != null ? o : !1, i != null && i.attributes && (this.attributes = i.attributes);
|
|
827
|
+
let s = i?.fontFamily;
|
|
828
|
+
i != null && i.style && this.value && (s = (l = Te.getFont((n = i.mode) != null ? n : "math", this, g(f({ variant: "normal" }, i.style), { letterShapeStyle: i.letterShapeStyle }))) != null ? l : void 0), s || (s = "Main-Regular"), this._height = 0, this._depth = 0, this._width = 0, this.hasExplicitWidth = !1, this.skew = 0, this.italic = 0, this.maxFontSize = 0, this.scale = 1, i?.maxFontSize !== void 0 && (this.maxFontSize = i.maxFontSize), Pp(this, s);
|
|
829
829
|
}
|
|
830
830
|
set atomID(t) {
|
|
831
831
|
t === void 0 || t.length === 0 || (this.id = t);
|
|
@@ -1056,7 +1056,7 @@ var ae = class extends L {
|
|
|
1056
1056
|
constructor(e, t) {
|
|
1057
1057
|
var i;
|
|
1058
1058
|
let [r, a, o] = Ip(e);
|
|
1059
|
-
super(r.length === 1 ? r[0] : r, { type: t
|
|
1059
|
+
super(r.length === 1 ? r[0] : r, { type: t?.type, classes: ((i = t?.classes) != null ? i : "") + " ML__vlist-t" + (r.length === 2 ? " ML__vlist-t2" : "") }), this.height = a, this.depth = o, this.softWidth = r.reduce((n, l) => Math.max(n, l.width), 0);
|
|
1060
1060
|
}
|
|
1061
1061
|
};
|
|
1062
1062
|
function Np(e, t) {
|
|
@@ -1158,9 +1158,9 @@ var O = class pd {
|
|
|
1158
1158
|
constructor(t, i) {
|
|
1159
1159
|
var r, a, o, n, l, s, u, c, d, h, p, m, b, x, y;
|
|
1160
1160
|
let _;
|
|
1161
|
-
t != null && t.parent ? (this.parent = t.parent, _ = t.parent, this.registers = {}) : (_ = f(f({}, Wl()), (r = t
|
|
1161
|
+
t != null && t.parent ? (this.parent = t.parent, _ = t.parent, this.registers = {}) : (_ = f(f({}, Wl()), (r = t?.from) != null ? r : {}), this.registers = _.registers), _.atomIdsSettings && (this.atomIdsSettings = f({}, _.atomIdsSettings)), this.renderPlaceholder = _.renderPlaceholder, this.isPhantom = (n = (o = t?.isPhantom) != null ? o : (a = this.parent) == null ? void 0 : a.isPhantom) != null ? n : !1, this.letterShapeStyle = _.letterShapeStyle, this.minFontScale = _.minFontScale, this.maxMatrixCols = _.maxMatrixCols, i != null && i.color && i.color !== "none" ? this.color = i.color : this.color = (s = (l = this.parent) == null ? void 0 : l.color) != null ? s : "", i != null && i.backgroundColor && i.backgroundColor !== "none" ? this.backgroundColor = i.backgroundColor : this.backgroundColor = (c = (u = this.parent) == null ? void 0 : u.backgroundColor) != null ? c : "", i != null && i.fontSize && i.fontSize !== "auto" && i.fontSize !== ((d = this.parent) == null ? void 0 : d.size) ? this.size = i.fontSize : this.size = (p = (h = this.parent) == null ? void 0 : h.size) != null ? p : Hl;
|
|
1162
1162
|
let S = (b = (m = this.parent) == null ? void 0 : m.mathstyle) != null ? b : lt.displaystyle;
|
|
1163
|
-
if (typeof
|
|
1163
|
+
if (typeof t?.mathstyle == "string") {
|
|
1164
1164
|
if (_ instanceof pd) switch (t.mathstyle) {
|
|
1165
1165
|
case "cramp":
|
|
1166
1166
|
S = S.cramp;
|
|
@@ -1319,8 +1319,8 @@ var v = class ft {
|
|
|
1319
1319
|
c && n.push(c);
|
|
1320
1320
|
}
|
|
1321
1321
|
if (n.length === 0) return null;
|
|
1322
|
-
let l = ((a = r
|
|
1323
|
-
return n.length === 1 && !l && !(r != null && r.type) ? n[0].wrap(t) : new L(n, { classes: l, type: r
|
|
1322
|
+
let l = ((a = r?.classes) != null ? a : "").trim();
|
|
1323
|
+
return n.length === 1 && !l && !(r != null && r.type) ? n[0].wrap(t) : new L(n, { classes: l, type: r?.type }).wrap(t);
|
|
1324
1324
|
}
|
|
1325
1325
|
static serialize(t, i) {
|
|
1326
1326
|
return Te.serialize(t, i);
|
|
@@ -1615,7 +1615,7 @@ var v = class ft {
|
|
|
1615
1615
|
}
|
|
1616
1616
|
createBox(t, i) {
|
|
1617
1617
|
var r, a, o, n;
|
|
1618
|
-
let l = (r = this.value) != null ? r : this.body, s = (a = i
|
|
1618
|
+
let l = (r = this.value) != null ? r : this.body, s = (a = i?.boxType) != null ? a : ml(this.type), u = (o = i?.classes) != null ? o : "";
|
|
1619
1619
|
this.mode === "text" && (u += " ML__text");
|
|
1620
1620
|
let c = typeof l == "string" || l === void 0 ? new L(l ?? null, { type: s, isSelected: this.isSelected, mode: this.mode, maxFontSize: t.scalingFactor, style: g(f({ variant: "normal" }, this.style), { fontSize: Math.max(1, t.size + t.mathstyle.sizeDelta) }), letterShapeStyle: t.letterShapeStyle, classes: u }) : (n = ft.createBox(t, l, { type: s, classes: u })) != null ? n : new L(null);
|
|
1621
1621
|
return t.isTight && (c.isTight = !0), (this.mode !== "math" || this.style.variant === "main") && (c.italic = 0), c.right = c.italic, this.bind(t, c), this.caret && !this.superscript && !this.subscript && (c.caret = this.caret), c;
|
|
@@ -1730,8 +1730,8 @@ function Ul(e, t, i) {
|
|
|
1730
1730
|
var fd = { "&": "\\&", "%": "\\%", $: "\\$", "''": "^{\\doubleprime}", "'''": "^{\\prime\\prime\\prime}", "''''": "^{\\prime\\prime\\prime\\prime}", alpha: "\\alpha", delta: "\\delta", Delta: "\\Delta", pi: "\\pi", Pi: "\\Pi", theta: "\\theta", Theta: "\\Theta", ii: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\imaginaryI" }, jj: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\imaginaryJ" }, ee: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\exponentialE" }, nabla: "\\nabla", grad: "\\nabla", del: "\\partial", deg: { after: "digit+space", value: "\\degree" }, infty: "\\infty", "∞": "\\infty", oo: { after: "nothing+digit+frac+surd+binop+relop+punct+array+openfence+closefence+space", value: "\\infty" }, "∑": "\\sum", sum: "\\sum_{#?}^{#?}", int: "\\int_{#?}^{#?}", prod: "\\prod_{#?}^{#?}", sqrt: "\\sqrt{#?}", "∆": "\\differentialD", "∂": "\\differentialD", arcsin: "\\arcsin", arccos: "\\arccos", arctan: "\\arctan", arcsec: "\\arcsec", arccsc: "\\arccsc", arsinh: "\\arsinh", arcosh: "\\arcosh", artanh: "\\artanh", arcsech: "\\arcsech", arccsch: "\\arccsch", arg: "\\arg", ch: "\\ch", cosec: "\\cosec", cosh: "\\cosh", cot: "\\cot", cotg: "\\cotg", coth: "\\coth", csc: "\\csc", ctg: "\\ctg", cth: "\\cth", sec: "\\sec", sinh: "\\sinh", sh: "\\sh", tanh: "\\tanh", tg: "\\tg", th: "\\th", sin: "\\sin", cos: "\\cos", tan: "\\tan", lg: "\\lg", lb: "\\lb", log: "\\log", ln: "\\ln", exp: "\\exp", lim: "\\lim_{#?}", dx: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\differentialD x" }, dy: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\differentialD y" }, dt: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\differentialD t" }, AA: "\\forall", EE: "\\exists", "!EE": "\\nexists", "&&": "\\land", xin: { after: "nothing+text+relop+punct+openfence+space", value: "x \\in" }, sint: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\sin t" }, in: { after: "nothing+letter+closefence", value: "\\in" }, "!in": "\\notin", NN: "\\mathbb{N}", ZZ: "\\Z", QQ: "\\Q", RR: "\\R", CC: "\\C", xx: "\\times", "+-": "\\pm", "≠": "\\ne", "!=": "\\ne", "≥": "\\ge", ">=": "\\ge", "≤": "\\le", "<=": "\\le", "<<": "\\ll", ">>": "\\gg", "~~": "\\approx", "≈": "\\approx", "?=": "\\questeq", "÷": "\\div", "¬": "\\neg", ":=": "\\coloneq", "::": "\\Colon", "(:": "\\langle", ":)": "\\rangle", beta: "\\beta", chi: "\\chi", epsilon: "\\epsilon", varepsilon: "\\varepsilon", eta: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\eta" }, gamma: "\\gamma", Gamma: "\\Gamma", iota: "\\iota", kappa: "\\kappa", lambda: "\\lambda", Lambda: "\\Lambda", mu: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\mu" }, nu: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\nu" }, µ: "\\mu", phi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\phi" }, Phi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\Phi" }, varphi: "\\varphi", psi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\psi" }, Psi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\Psi" }, rho: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\rho" }, sigma: "\\sigma", Sigma: "\\Sigma", tau: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\tau" }, vartheta: "\\vartheta", upsilon: "\\upsilon", xi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space", value: "\\xi" }, Xi: { after: "nothing+digit+function+frac+surd+binop+relop+punct+array+openfence+closefence+space+text", value: "\\Xi" }, zeta: "\\zeta", omega: "\\omega", Omega: "\\Omega", Ω: "\\omega", forall: "\\forall", exists: "\\exists", "!exists": "\\nexists", ":.": "\\therefore", liminf: "\\liminf_{#?}", limsup: "\\limsup_{#?}", argmin: "\\operatorname*{arg~min}_{#?}", argmax: "\\operatorname*{arg~max}_{#?}", det: "\\det", mod: "\\bmod{#?}", "(mod": "\\pmod{#?}", max: "\\max", min: "\\min", erf: "\\operatorname{erf}", erfc: "\\operatorname{erfc}", bessel: "\\operatorname{bessel}", mean: "\\operatorname{mean}", median: "\\operatorname{median}", fft: "\\operatorname{fft}", lcm: "\\operatorname{lcm}", gcd: "\\operatorname{gcd}", randomReal: "\\operatorname{randomReal}", randomInteger: "\\operatorname{randomInteger}", Re: "\\operatorname{Re}", Im: "\\operatorname{Im}", mm: { after: "nothing+digit+operator", value: "\\operatorname{mm}" }, cm: { after: "nothing+digit+operator", value: "\\operatorname{cm}" }, km: { after: "nothing+digit+operator", value: "\\operatorname{km}" }, kg: { after: "nothing+digit+operator", value: "\\operatorname{kg}" }, "...": "\\ldots", "+...": "+\\cdots", "-...": "-\\cdots", "->...": "\\to\\cdots", "-->...": "\\longrightarrow\\cdots", "->": "\\to", "|->": "\\mapsto", "-->": "\\longrightarrow", "<--": "\\longleftarrow", "=>": "\\Rightarrow", "==>": "\\Longrightarrow", "<=>": "\\Leftrightarrow", "<->": "\\leftrightarrow", "(.)": "\\odot", "(+)": "\\oplus", "(/)": "\\oslash", "(*)": "\\otimes", "(-)": "\\ominus", "||": "\\Vert", "*": "\\cdot", "**": "\\star", "***": "\\ast", "//": "\\slash", "\\\\": "\\backslash", setminus: "\\backslash", "|><": "\\ltimes", "><|": "\\rtimes", "|><|": "\\bowtie", "-:": "\\div", divide: "\\div", "@": "\\circ", "^^": "\\wedge", "^^^": "\\bigwedge", vv: "\\vee", vvv: "\\bigvee", nn: "\\cap", nnn: "\\bigcap", uu: "\\cup", uuu: "\\bigcup", "-=": "\\equiv", "~=": "\\cong", lt: "<", "lt=": "\\leq", gt: ">", "gt=": "\\geq", "-<": "\\prec", "-lt": "\\prec", "-<=": "\\preceq", ">-=": "\\succeq", prop: "\\propto", diamond: "\\diamond", square: "\\square", iff: "\\iff", sub: "\\subset", sup: "\\supset", sube: "\\subseteq", supe: "\\supseteq", uarr: "\\uparrow", darr: "\\downarrow", rarr: "\\rightarrow", rArr: "\\Rightarrow", larr: "\\leftarrow", lArr: "\\Leftarrow", harr: "\\leftrightarrow", hArr: "\\Leftrightarrow", aleph: "\\aleph", and: "\\land", or: "\\lor", not: "\\neg", "_|_": "\\bot", TT: "\\top", "|--": "\\vdash", "|==": "\\models", "|__": "\\lfloor", "__|": "\\rfloor", "|~": "\\lceil", "~|": "\\rceil", ">->": "\\rightarrowtail", "->>": "\\twoheadrightarrow", ">->>": "\\twoheadrightarrowtail", frac: "\\frac{#?}{#?}", cbrt: "\\sqrt[3]{#?}", nthroot: "\\sqrt[#?]{#?}" };
|
|
1731
1731
|
function Vr(e, t) {
|
|
1732
1732
|
var i;
|
|
1733
|
-
let r = (i = t
|
|
1734
|
-
return r === "auto" && ([r, e] = Gp(e)), r === "ascii-math" ? (e = e.replace(/\u2061/gu, ""), e = e.replace(/\u3016/gu, "{"), e = e.replace(/\u3017/gu, "}"), e = e.replace(/([^\\])sinx/g, "$1\\sin x"), e = e.replace(/([^\\])cosx/g, "$1\\cos x "), e = e.replace(/\u2013/g, "-"), ["ascii-math", Se(e, { inlineShortcuts: t
|
|
1733
|
+
let r = (i = t?.format) != null ? i : "auto";
|
|
1734
|
+
return r === "auto" && ([r, e] = Gp(e)), r === "ascii-math" ? (e = e.replace(/\u2061/gu, ""), e = e.replace(/\u3016/gu, "{"), e = e.replace(/\u3017/gu, "}"), e = e.replace(/([^\\])sinx/g, "$1\\sin x"), e = e.replace(/([^\\])cosx/g, "$1\\cos x "), e = e.replace(/\u2013/g, "-"), ["ascii-math", Se(e, { inlineShortcuts: t?.inlineShortcuts })]) : ["latex", e];
|
|
1735
1735
|
}
|
|
1736
1736
|
function Se(e, t) {
|
|
1737
1737
|
var i;
|
|
@@ -4720,7 +4720,7 @@ function Wt(e) {
|
|
|
4720
4720
|
var jo = class kd extends v {
|
|
4721
4721
|
constructor(t) {
|
|
4722
4722
|
var i;
|
|
4723
|
-
super(g(f({}, t), { type: "accent", body: (i = t.body) != null ? i : void 0 })), t.accentChar ? this.accent = t.accentChar : this.svgAccent = t
|
|
4723
|
+
super(g(f({}, t), { type: "accent", body: (i = t.body) != null ? i : void 0 })), t.accentChar ? this.accent = t.accentChar : this.svgAccent = t?.svgAccent, this.skipBoundary = !0, this.captureSelection = !0;
|
|
4724
4724
|
}
|
|
4725
4725
|
static fromJson(t) {
|
|
4726
4726
|
return new kd(t);
|
|
@@ -4756,7 +4756,7 @@ function mm(e, t, i, r) {
|
|
|
4756
4756
|
}
|
|
4757
4757
|
function Md(e, t, i, r, a) {
|
|
4758
4758
|
var o, n;
|
|
4759
|
-
let l = new O({ parent: r, mathstyle: "textstyle" }, a
|
|
4759
|
+
let l = new O({ parent: r, mathstyle: "textstyle" }, a?.style), s = new L(Uo(e), { fontFamily: `Size${t}-Regular`, isSelected: a.isSelected, classes: ((o = a.classes) != null ? o : "") + ` ML__delim-size${t}`, type: (n = a.type) != null ? n : "ignore" }).wrap(l);
|
|
4760
4760
|
return i && s.setTop((1 - l.scalingFactor) * Ue), s;
|
|
4761
4761
|
}
|
|
4762
4762
|
function Sd(e, t, i, r, a) {
|
|
@@ -4785,7 +4785,7 @@ function Sd(e, t, i, r, a) {
|
|
|
4785
4785
|
let M = "";
|
|
4786
4786
|
c === "Size1-Regular" ? M = " delim-size1" : c === "Size4-Regular" && (M = " delim-size4");
|
|
4787
4787
|
let ke = new ae({ bottom: D, children: E }, { classes: M });
|
|
4788
|
-
return new L(ke, g(f({}, a ?? {}), { classes: ((o = a
|
|
4788
|
+
return new L(ke, g(f({}, a ?? {}), { classes: ((o = a?.classes) != null ? o : "") + " ML__delim-mult" }));
|
|
4789
4789
|
}
|
|
4790
4790
|
var Cd = /* @__PURE__ */ new Set(["(", ")", "\\lparen", "\\rparen", "[", "]", "\\lbrack", "\\rbrack", "\\{", "\\}", "\\lbrace", "\\rbrace", "\\lfloor", "\\rfloor", "\\lceil", "\\rceil", "\\surd", "⌊", "⌋", "⌈", "⌉"]), fm = /* @__PURE__ */ new Set(["\\uparrow", "\\downarrow", "\\updownarrow", "\\Uparrow", "\\Downarrow", "\\Updownarrow", "|", "\\|", "\\vert", "\\Vert", "\\lvert", "\\rvert", "\\lVert", "\\rVert", "\\mvert", "\\mid", "\\lgroup", "\\rgroup", "\\lmoustache", "\\rmoustache", "⟮", "⟯", "⎰", "⎱"]), Ld = /* @__PURE__ */ new Set(["<", ">", "\\langle", "\\rangle", "/", "\\backslash", "\\lt", "\\gt"]), gm = [0, 1.2, 1.8, 2.4, 3];
|
|
4791
4791
|
function bm(e, t, i, r) {
|
|
@@ -4810,11 +4810,11 @@ function Do(e, t, i, r, a, o) {
|
|
|
4810
4810
|
t === "<" || t === "\\lt" ? t = "\\langle" : (t === ">" || t === "\\gt") && (t = "\\rangle");
|
|
4811
4811
|
let n;
|
|
4812
4812
|
Ld.has(t) ? n = ym : Cd.has(t) ? n = xm : n = vm;
|
|
4813
|
-
let l = _m(Uo(t), i, n, a), s = new O({ parent: a, mathstyle: l.mathstyle }, o
|
|
4813
|
+
let l = _m(Uo(t), i, n, a), s = new O({ parent: a, mathstyle: l.mathstyle }, o?.style);
|
|
4814
4814
|
return l.type === "small" ? mm(t, s, r, g(f({}, o), { type: e })) : l.type === "large" ? Md(t, l.size, r, s, g(f({}, o), { type: e })) : (l.type, Sd(t, i, r, s, g(f({}, o), { type: e })));
|
|
4815
4815
|
}
|
|
4816
4816
|
function Hr(e, t, i, r, a, o) {
|
|
4817
|
-
if (t === ".") return _i(a, o
|
|
4817
|
+
if (t === ".") return _i(a, o?.classes);
|
|
4818
4818
|
let n = Ue * a.scalingFactor, l = 901, s = 5 / ir, u = Math.max(i - n, r + n), c = Math.max(u / 500 * l, 2 * u - s);
|
|
4819
4819
|
return Do(e, t, c, !0, a, o);
|
|
4820
4820
|
}
|
|
@@ -4825,7 +4825,7 @@ function _i(e, t) {
|
|
|
4825
4825
|
var Je = class Dd extends v {
|
|
4826
4826
|
constructor(t) {
|
|
4827
4827
|
var i;
|
|
4828
|
-
super({ type: "placeholder", command: "\\placeholder", mode: (i = t
|
|
4828
|
+
super({ type: "placeholder", command: "\\placeholder", mode: (i = t?.mode) != null ? i : "math", style: t?.style }), this.captureSelection = !0;
|
|
4829
4829
|
}
|
|
4830
4830
|
static fromJson(t) {
|
|
4831
4831
|
return new Dd(t);
|
|
@@ -5125,7 +5125,7 @@ var Ut = class zd extends v {
|
|
|
5125
5125
|
}, Kd = class $d extends v {
|
|
5126
5126
|
constructor(t, i) {
|
|
5127
5127
|
var r;
|
|
5128
|
-
super({ type: "composition", mode: (r = i
|
|
5128
|
+
super({ type: "composition", mode: (r = i?.mode) != null ? r : "math", value: t });
|
|
5129
5129
|
}
|
|
5130
5130
|
static fromJson(t) {
|
|
5131
5131
|
return new $d(t.value, t);
|
|
@@ -5257,7 +5257,7 @@ var Rd = class Vd extends v {
|
|
|
5257
5257
|
}, jd = class Wd extends v {
|
|
5258
5258
|
constructor(t, i, r = !1, a, o) {
|
|
5259
5259
|
var n;
|
|
5260
|
-
super({ type: "prompt", mode: (n = o
|
|
5260
|
+
super({ type: "prompt", mode: (n = o?.mode) != null ? n : "math", style: o?.style, command: "\\placeholder" }), this.body = a, this.correctness = i, this.placeholderId = t, this.locked = r, this.captureSelection = this.locked;
|
|
5261
5261
|
}
|
|
5262
5262
|
static fromJson(t) {
|
|
5263
5263
|
return new Wd(t.placeholderId, t.correctness, t.locked, t.body, t);
|
|
@@ -5290,7 +5290,7 @@ var Rd = class Vd extends v {
|
|
|
5290
5290
|
}
|
|
5291
5291
|
}, Jo = class Ud extends v {
|
|
5292
5292
|
constructor(t) {
|
|
5293
|
-
super({ type: "subsup", style: t
|
|
5293
|
+
super({ type: "subsup", style: t?.style }), this.subsupPlacement = "auto";
|
|
5294
5294
|
}
|
|
5295
5295
|
get children() {
|
|
5296
5296
|
if (!this._children) {
|
|
@@ -5327,7 +5327,7 @@ var Jd = class {
|
|
|
5327
5327
|
}
|
|
5328
5328
|
beginContext(e) {
|
|
5329
5329
|
var t, i, r;
|
|
5330
|
-
let a = this.parsingContext, o = { parent: a, mathlist: [], style: f({}, a.style), parseMode: (t = e
|
|
5330
|
+
let a = this.parsingContext, o = { parent: a, mathlist: [], style: f({}, a.style), parseMode: (t = e?.mode) != null ? t : a.parseMode, mathstyle: (i = e?.mathstyle) != null ? i : a.mathstyle, tabular: (r = e?.tabular) != null ? r : !1 };
|
|
5331
5331
|
this.parsingContext = o;
|
|
5332
5332
|
}
|
|
5333
5333
|
endContext() {
|
|
@@ -5495,7 +5495,7 @@ var Jd = class {
|
|
|
5495
5495
|
return o.startsWith("\\") ? i ? { register: o, global: !0, factor: (r ? -1 : 1) * i.number } : r ? { register: o, global: !0, factor: -1 } : { register: o, global: !0 } : (this.index = t, null);
|
|
5496
5496
|
}
|
|
5497
5497
|
let a = this.get();
|
|
5498
|
-
return a != null && a.startsWith("\\") ? (a = a.substring(1), this.context.registers[a] ? !r || i !== null ? { register: a, factor: (r ? -1 : 1) * ((e = i
|
|
5498
|
+
return a != null && a.startsWith("\\") ? (a = a.substring(1), this.context.registers[a] ? !r || i !== null ? { register: a, factor: (r ? -1 : 1) * ((e = i?.number) != null ? e : 1) } : { register: a } : (this.index = t, null)) : (this.index = t, null);
|
|
5499
5499
|
}
|
|
5500
5500
|
scanValue() {
|
|
5501
5501
|
let e = this.scanRegister();
|
|
@@ -5852,13 +5852,13 @@ var Jd = class {
|
|
|
5852
5852
|
};
|
|
5853
5853
|
function we(e, t) {
|
|
5854
5854
|
var i, r, a, o;
|
|
5855
|
-
let n = (i = t
|
|
5855
|
+
let n = (i = t?.args) != null ? i : void 0, l = new Jd(Rr(e, n), t?.context, { args: n, mathstyle: (r = t?.mathstyle) != null ? r : "displaystyle", parseMode: (a = t?.parseMode) != null ? a : "math", style: (o = t?.style) != null ? o : {} }), s = [];
|
|
5856
5856
|
for (; !l.end(); ) s.push(...l.scan(() => !1));
|
|
5857
5857
|
return s;
|
|
5858
5858
|
}
|
|
5859
5859
|
function Xd(e, t) {
|
|
5860
5860
|
var i;
|
|
5861
|
-
let r = new Jd(Rr(e, null), t
|
|
5861
|
+
let r = new Jd(Rr(e, null), t?.context, { mathstyle: "displaystyle", parseMode: (i = t?.parseMode) != null ? i : "math" });
|
|
5862
5862
|
for (; !r.end(); ) r.scan();
|
|
5863
5863
|
return r.errors;
|
|
5864
5864
|
}
|
|
@@ -6607,7 +6607,7 @@ function h0(e) {
|
|
|
6607
6607
|
var po = { fractionNavigationOrder: "numerator-denominator" }, Mi = class rh extends v {
|
|
6608
6608
|
constructor(t, i, r) {
|
|
6609
6609
|
var a, o, n;
|
|
6610
|
-
super(g(f({}, r), { type: "genfrac", displayContainsHighlight: !0 })), this.above = t, this.below = i, this.hasBarLine = (a = r
|
|
6610
|
+
super(g(f({}, r), { type: "genfrac", displayContainsHighlight: !0 })), this.above = t, this.below = i, this.hasBarLine = (a = r?.hasBarLine) != null ? a : !0, this.continuousFraction = (o = r?.continuousFraction) != null ? o : !1, this.align = (n = r?.align) != null ? n : "center", this.numerPrefix = r?.numerPrefix, this.denomPrefix = r?.denomPrefix, this.mathstyleName = r?.mathstyleName, this.leftDelim = r?.leftDelim, this.rightDelim = r?.rightDelim;
|
|
6611
6611
|
}
|
|
6612
6612
|
static fromJson(t) {
|
|
6613
6613
|
return new rh(t.above, t.below, t);
|
|
@@ -6659,7 +6659,7 @@ function Wa(e) {
|
|
|
6659
6659
|
var se = class ah extends v {
|
|
6660
6660
|
constructor(t, i) {
|
|
6661
6661
|
var r;
|
|
6662
|
-
super({ type: "latex", value: t, mode: "latex" }), this.isSuggestion = (r = i
|
|
6662
|
+
super({ type: "latex", value: t, mode: "latex" }), this.isSuggestion = (r = i?.isSuggestion) != null ? r : !1, this.isError = !1;
|
|
6663
6663
|
}
|
|
6664
6664
|
static fromJson(t) {
|
|
6665
6665
|
let i = new ah(t.value);
|
|
@@ -6693,7 +6693,7 @@ var se = class ah extends v {
|
|
|
6693
6693
|
}
|
|
6694
6694
|
}, Gl = class nh extends v {
|
|
6695
6695
|
constructor(t, i) {
|
|
6696
|
-
super(g(f({}, i), { type: "extensible-symbol", isFunction: i
|
|
6696
|
+
super(g(f({}, i), { type: "extensible-symbol", isFunction: i?.isFunction })), this.value = t, this.variant = i?.variant, this.subsupPlacement = i?.limits;
|
|
6697
6697
|
}
|
|
6698
6698
|
static fromJson(t) {
|
|
6699
6699
|
return new nh(t.symbol, t);
|
|
@@ -6726,7 +6726,7 @@ var se = class ah extends v {
|
|
|
6726
6726
|
}, Si = class lh extends v {
|
|
6727
6727
|
constructor(t) {
|
|
6728
6728
|
let i = t.body;
|
|
6729
|
-
super(g(f({}, t), { type: "overlap", body: typeof i == "string" ? [new v({ value: i })] : i, style: t
|
|
6729
|
+
super(g(f({}, t), { type: "overlap", body: typeof i == "string" ? [new v({ value: i })] : i, style: t?.style })), this.skipBoundary = !0, this.align = t?.align, this.boxType = t?.boxType;
|
|
6730
6730
|
}
|
|
6731
6731
|
static fromJson(t) {
|
|
6732
6732
|
return new lh(t);
|
|
@@ -6803,7 +6803,7 @@ var Zr = class uh extends v {
|
|
|
6803
6803
|
}, Yr = class ch extends v {
|
|
6804
6804
|
constructor(t) {
|
|
6805
6805
|
var i;
|
|
6806
|
-
super(f({ type: "spacing" }, t)), this.width = t
|
|
6806
|
+
super(f({ type: "spacing" }, t)), this.width = t?.width, this._braced = (i = t?.braced) != null ? i : !1;
|
|
6807
6807
|
}
|
|
6808
6808
|
static fromJson(t) {
|
|
6809
6809
|
return new ch(t);
|
|
@@ -6890,7 +6890,7 @@ function mo(e, t) {
|
|
|
6890
6890
|
var zm = { ord: { op: 3, bin: 4, rel: 5, inner: 3 }, op: { ord: 3, op: 3, rel: 5, inner: 3 }, bin: { ord: 4, op: 4, open: 4, inner: 4 }, rel: { ord: 5, op: 5, open: 5, inner: 5 }, close: { op: 3, bin: 4, rel: 5, inner: 3 }, punct: { ord: 3, op: 3, rel: 3, open: 3, punct: 3, inner: 3 }, inner: { ord: 3, op: 3, bin: 4, rel: 5, open: 3, punct: 3, inner: 3 } }, Km = { ord: { op: 3 }, op: { ord: 3, op: 3 }, close: { op: 3 }, inner: { op: 3 } };
|
|
6891
6891
|
function $m(e) {
|
|
6892
6892
|
zr(e, (t, i) => {
|
|
6893
|
-
i.type === "bin" && (!t || /^(middle|bin|op|rel|open|punct)$/.test(t.type)) && (i.type = "ord"),
|
|
6893
|
+
i.type === "bin" && (!t || /^(middle|bin|op|rel|open|punct)$/.test(t.type)) && (i.type = "ord"), t?.type === "bin" && /^(rel|close|punct)$/.test(i.type) && (t.type = "ord"), i.type !== "ignore" && (t = i);
|
|
6894
6894
|
});
|
|
6895
6895
|
}
|
|
6896
6896
|
function Qr(e, t) {
|
|
@@ -6901,7 +6901,7 @@ function Qr(e, t) {
|
|
|
6901
6901
|
return zr(i, (n, l) => {
|
|
6902
6902
|
var s, u, c;
|
|
6903
6903
|
if (!n) return;
|
|
6904
|
-
let d = n.type, h = l.isTight ? (s = Km[d]) != null ? s : null : (u = zm[d]) != null ? u : null, p = (c = h
|
|
6904
|
+
let d = n.type, h = l.isTight ? (s = Km[d]) != null ? s : null : (u = zm[d]) != null ? u : null, p = (c = h?.[l.type]) != null ? c : null;
|
|
6905
6905
|
p === 3 && mo(l, r), p === 4 && mo(l, a), p === 5 && mo(l, o);
|
|
6906
6906
|
}), e;
|
|
6907
6907
|
}
|
|
@@ -6931,7 +6931,7 @@ var Zl = class ph extends v {
|
|
|
6931
6931
|
}
|
|
6932
6932
|
}, Ci = class mh extends v {
|
|
6933
6933
|
constructor(t, i) {
|
|
6934
|
-
super(g(f({}, i), { type: "operator", isFunction: i
|
|
6934
|
+
super(g(f({}, i), { type: "operator", isFunction: i?.isFunction })), this.value = t, this.variant = i?.variant, this.variantStyle = i?.variantStyle, this.subsupPlacement = i?.limits;
|
|
6935
6935
|
}
|
|
6936
6936
|
static fromJson(t) {
|
|
6937
6937
|
return new mh(t.symbol, t);
|
|
@@ -7231,7 +7231,7 @@ function Go(e) {
|
|
|
7231
7231
|
function Eo() {
|
|
7232
7232
|
var e;
|
|
7233
7233
|
let t = document.activeElement;
|
|
7234
|
-
for (; (e = t
|
|
7234
|
+
for (; (e = t?.shadowRoot) != null && e.activeElement; ) t = t.shadowRoot.activeElement;
|
|
7235
7235
|
return t;
|
|
7236
7236
|
}
|
|
7237
7237
|
var We = class gt {
|
|
@@ -7252,7 +7252,7 @@ var We = class gt {
|
|
|
7252
7252
|
}
|
|
7253
7253
|
constructor(t) {
|
|
7254
7254
|
var i, r;
|
|
7255
|
-
this.lightDismiss = (i = t
|
|
7255
|
+
this.lightDismiss = (i = t?.lightDismiss) != null ? i : !0, this.translucent = (r = t?.translucent) != null ? r : !1, this.state = "closed";
|
|
7256
7256
|
}
|
|
7257
7257
|
get element() {
|
|
7258
7258
|
if (this._element) return this._element;
|
|
@@ -7262,9 +7262,9 @@ var We = class gt {
|
|
|
7262
7262
|
open(t) {
|
|
7263
7263
|
var i;
|
|
7264
7264
|
if (this.state !== "closed") return;
|
|
7265
|
-
this.state = "opening", this.onDismiss = t
|
|
7265
|
+
this.state = "opening", this.onDismiss = t?.onDismiss, this.savedActiveElement = Eo();
|
|
7266
7266
|
let { element: r } = this;
|
|
7267
|
-
((i = t
|
|
7267
|
+
((i = t?.root) != null ? i : document.body).appendChild(r), r.addEventListener("click", this), document.addEventListener("touchmove", this, !1), document.addEventListener("scroll", this, !1);
|
|
7268
7268
|
let a = window.innerWidth - document.documentElement.clientWidth;
|
|
7269
7269
|
this.savedMarginRight = document.body.style.marginRight, this.savedOverflow = document.body.style.overflow, document.body.style.overflow = "hidden";
|
|
7270
7270
|
let o = Number.parseFloat(getComputedStyle(document.body).marginRight);
|
|
@@ -7469,11 +7469,11 @@ function ts(e) {
|
|
|
7469
7469
|
function To(e) {
|
|
7470
7470
|
var t, i;
|
|
7471
7471
|
let r = ts(e);
|
|
7472
|
-
return (i = (t = r
|
|
7472
|
+
return (i = (t = r?.body) == null ? void 0 : t.filter((a) => a.type === "latex")) != null ? i : [];
|
|
7473
7473
|
}
|
|
7474
7474
|
function xh(e, t) {
|
|
7475
7475
|
var i;
|
|
7476
|
-
let r = 0, a = !1, o = Number.isFinite(t
|
|
7476
|
+
let r = 0, a = !1, o = Number.isFinite(t?.before) ? (i = t?.before) != null ? i : 0 : e.lastOffset;
|
|
7477
7477
|
for (; r <= o && !a; ) {
|
|
7478
7478
|
let s = e.at(r);
|
|
7479
7479
|
a = s instanceof se && s.isSuggestion, a || r++;
|
|
@@ -7559,7 +7559,7 @@ function ea(e, t) {
|
|
|
7559
7559
|
nr(e);
|
|
7560
7560
|
return;
|
|
7561
7561
|
}
|
|
7562
|
-
let s = (i = t
|
|
7562
|
+
let s = (i = t?.atIndex) != null ? i : 0;
|
|
7563
7563
|
e.suggestionIndex = s < 0 ? l.length - 1 : s % l.length;
|
|
7564
7564
|
let u = l[e.suggestionIndex];
|
|
7565
7565
|
if (u !== n) {
|
|
@@ -7590,9 +7590,9 @@ function or(e, t = "accept", i) {
|
|
|
7590
7590
|
if (t === "accept-suggestion") return u.length !== 0;
|
|
7591
7591
|
}
|
|
7592
7592
|
let n = To(e.model).filter((u) => !u.isSuggestion).map((u) => u.value).join(""), l = o.leftSibling;
|
|
7593
|
-
if (o.parent.removeChild(o), e.model.position = e.model.offsetOf(l), e.switchMode((r = i
|
|
7593
|
+
if (o.parent.removeChild(o), e.model.position = e.model.offsetOf(l), e.switchMode((r = i?.mode) != null ? r : "math"), t === "reject") return !0;
|
|
7594
7594
|
let s = f({}, ar(e));
|
|
7595
|
-
return !/^[a-zA-Z0-9]$/.test(n) && e.styleBias !== "none" && (s.variant = "normal", s.variantStyle = void 0), U.insert(e.model, n, { selectionMode: (a = i
|
|
7595
|
+
return !/^[a-zA-Z0-9]$/.test(n) && e.styleBias !== "none" && (s.variant = "normal", s.variantStyle = void 0), U.insert(e.model, n, { selectionMode: (a = i?.selectItem) != null && a ? "item" : "placeholder", format: "latex", mode: "math", style: s }), e.snapshot(), e.model.announce("replacement"), e.switchMode("math"), !0;
|
|
7596
7596
|
}
|
|
7597
7597
|
function Yo(e) {
|
|
7598
7598
|
var t;
|
|
@@ -7672,7 +7672,7 @@ function Lf() {
|
|
|
7672
7672
|
let t = e[1], i = t.match(/http.*\.ts[\?:]/);
|
|
7673
7673
|
return i && (t = e[2]), i = t.match(/(https?:.*):[0-9]+:[0-9]+/), i || (i = t.match(/at (.*(\.ts))[\?:]/), i || (i = t.match(/at (.*(\.mjs|\.js))[\?:]/))), i ? i[1] : (console.error(e), console.error(`Can't use relative paths to specify assets location because the source file location could not be determined (unexpected location "${t}").`), "");
|
|
7674
7674
|
}
|
|
7675
|
-
var Ja = null, y0, v0, Hn = ((v0 = (y0 = globalThis
|
|
7675
|
+
var Ja = null, y0, v0, Hn = ((v0 = (y0 = globalThis?.document) == null ? void 0 : y0.currentScript) == null ? void 0 : v0.src) || Lf();
|
|
7676
7676
|
async function wh(e) {
|
|
7677
7677
|
if (/^(?:[a-z+]+:)?\/\//i.test(e)) {
|
|
7678
7678
|
try {
|
|
@@ -7878,7 +7878,7 @@ function Ff(e, t) {
|
|
|
7878
7878
|
if (t = Wr(t), !t) return !1;
|
|
7879
7879
|
let a, o = [], n = !1, l = !1;
|
|
7880
7880
|
de(t) ? (a = t[0], o = t.slice(1)) : a = t;
|
|
7881
|
-
let s = st[a], u = s
|
|
7881
|
+
let s = st[a], u = s?.target;
|
|
7882
7882
|
if (u === "model") {
|
|
7883
7883
|
if (!e.isSelectionEditable && s != null && s.changeContent) return e.model.announce("plonk"), !1;
|
|
7884
7884
|
/^(delete|add)/.test(a) && (a !== "deleteBackward" && e.flushInlineShortcutBuffer(), e.snapshot(a)), /^complete/.test(a) || Zo(e), st[a].fn(e.model, ...o), ea(e), l = !0, n = !0;
|
|
@@ -7894,7 +7894,7 @@ function zf(e, t) {
|
|
|
7894
7894
|
if (!e) return !1;
|
|
7895
7895
|
e.focus(), us.keypressVibration && Y0() && navigator.vibrate(Mh);
|
|
7896
7896
|
let r = as(t);
|
|
7897
|
-
globalThis.MathfieldElement.playSound((i = r
|
|
7897
|
+
globalThis.MathfieldElement.playSound((i = r?.audioFeedback) != null ? i : "keypress");
|
|
7898
7898
|
let a = e.executeCommand(t);
|
|
7899
7899
|
return e.scrollIntoView(), a;
|
|
7900
7900
|
}
|
|
@@ -8009,7 +8009,7 @@ var Pf = class Sh {
|
|
|
8009
8009
|
}
|
|
8010
8010
|
dispatchEvent(t) {
|
|
8011
8011
|
return !this.listeners[t.type] || this.listeners[t.type].size === 0 ? !0 : (this.listeners[t.type].forEach((i) => {
|
|
8012
|
-
typeof i == "function" ? i(t) : i
|
|
8012
|
+
typeof i == "function" ? i(t) : i?.handleEvent(t);
|
|
8013
8013
|
}), !t.defaultPrevented);
|
|
8014
8014
|
}
|
|
8015
8015
|
removeEventListener(t, i, r) {
|
|
@@ -8064,11 +8064,11 @@ function Ch(e, t) {
|
|
|
8064
8064
|
if (!l) return;
|
|
8065
8065
|
let s = Wi(e), u = "";
|
|
8066
8066
|
if (window.mathVirtualKeyboard.isShifted) {
|
|
8067
|
-
let y = (i = l.getKeycap(s
|
|
8067
|
+
let y = (i = l.getKeycap(s?.id)) == null ? void 0 : i.shift;
|
|
8068
8068
|
typeof y == "object" && "variants" in y && (u = (r = y.variants) != null ? r : "");
|
|
8069
|
-
} else u = (o = (a = l.getKeycap(s
|
|
8069
|
+
} else u = (o = (a = l.getKeycap(s?.id)) == null ? void 0 : a.variants) != null ? o : "";
|
|
8070
8070
|
if (typeof u == "string" && !_l(u) || Array.isArray(u) && u.length === 0) {
|
|
8071
|
-
t
|
|
8071
|
+
t?.();
|
|
8072
8072
|
return;
|
|
8073
8073
|
}
|
|
8074
8074
|
let c = {}, d = "";
|
|
@@ -8081,15 +8081,15 @@ function Ch(e, t) {
|
|
|
8081
8081
|
let h = document.createElement("div");
|
|
8082
8082
|
h.setAttribute("aria-hidden", "true"), h.className = "MLK__variant-panel", h.style.height = "auto";
|
|
8083
8083
|
let p = Object.keys(c).length, m = 5;
|
|
8084
|
-
p === 1 ? m = 1 : p === 2 || p === 4 ? m = 2 : p === 3 || p === 5 || p === 6 ? m = 3 : p >= 7 && p < 14 && (m = 4), h.style.width = `calc(var(--variant-keycap-length) * ${m} + 12px)`, h.innerHTML = us.createHTML(d), We.open({ root: (n = l
|
|
8085
|
-
let { signal: b } = Kr, x = e
|
|
8084
|
+
p === 1 ? m = 1 : p === 2 || p === 4 ? m = 2 : p === 3 || p === 5 || p === 6 ? m = 3 : p >= 7 && p < 14 && (m = 4), h.style.width = `calc(var(--variant-keycap-length) * ${m} + 12px)`, h.innerHTML = us.createHTML(d), We.open({ root: (n = l?.container) == null ? void 0 : n.querySelector(".ML__keyboard"), child: h }), Kr = new AbortController();
|
|
8085
|
+
let { signal: b } = Kr, x = e?.getBoundingClientRect();
|
|
8086
8086
|
if (x) {
|
|
8087
8087
|
x.top - h.clientHeight < 0 && (h.style.width = "auto", p <= 6 ? h.style.height = "56px" : p <= 12 ? h.style.height = "108px" : p <= 18 ? h.style.height = "205px" : h.classList.add("compact"));
|
|
8088
8088
|
let y = Math.max(0, Math.min(window.innerWidth - h.offsetWidth, (x.left + x.right - h.offsetWidth) / 2)), _ = x.top - h.clientHeight + 5;
|
|
8089
8089
|
h.style.left = `${y}px`, h.style.top = `${_}px`, h.classList.add("is-visible"), requestAnimationFrame(() => {
|
|
8090
8090
|
h.addEventListener("pointerup", (S) => {
|
|
8091
8091
|
let C = Wi(S.target);
|
|
8092
|
-
!(C != null && C.id) || !c[C.id] || (kl(c[C.id]), $r(), t
|
|
8092
|
+
!(C != null && C.id) || !c[C.id] || (kl(c[C.id]), $r(), t?.(), S.preventDefault());
|
|
8093
8093
|
}, { capture: !0, passive: !1, signal: b }), h.addEventListener("pointerenter", (S) => {
|
|
8094
8094
|
let C = Wi(S.target);
|
|
8095
8095
|
S.target, !(!(C != null && C.id) || !c[C.id]) && C.classList.add("is-active");
|
|
@@ -8097,15 +8097,15 @@ function Ch(e, t) {
|
|
|
8097
8097
|
let C = Wi(S.target);
|
|
8098
8098
|
S.target && "tagName" in S.target && typeof S.target.tagName == "string" && S.target.tagName.toUpperCase() === "ASIDE" || !(C != null && C.id) || !c[C.id] || C.classList.remove("is-active");
|
|
8099
8099
|
}, { capture: !0, signal: b }), window.addEventListener("pointercancel", () => {
|
|
8100
|
-
$r(), t
|
|
8100
|
+
$r(), t?.();
|
|
8101
8101
|
}, { signal: b }), window.addEventListener("pointerup", () => {
|
|
8102
|
-
$r(), t
|
|
8102
|
+
$r(), t?.();
|
|
8103
8103
|
}, { signal: b });
|
|
8104
8104
|
});
|
|
8105
8105
|
}
|
|
8106
8106
|
}
|
|
8107
8107
|
function $r() {
|
|
8108
|
-
Kr
|
|
8108
|
+
Kr?.abort(), Kr = null, We.state === "open" && We.close();
|
|
8109
8109
|
}
|
|
8110
8110
|
function If(e) {
|
|
8111
8111
|
if (e === "foreground-color") {
|
|
@@ -8305,7 +8305,7 @@ function Zf(e) {
|
|
|
8305
8305
|
if (a) for (let n of a) n.addEventListener("click", (l) => {
|
|
8306
8306
|
var s, u;
|
|
8307
8307
|
let c = l.target, d = "";
|
|
8308
|
-
for (; c && !d; ) d = (s = c
|
|
8308
|
+
for (; c && !d; ) d = (s = c?.getAttribute("data-command")) != null ? s : "", c = (u = c?.parentElement) != null ? u : null;
|
|
8309
8309
|
d && e.executeCommand(JSON.parse(d));
|
|
8310
8310
|
});
|
|
8311
8311
|
Wf(t.querySelectorAll(".MLK__keycap, .action, .fnbutton, .bigfnbutton"));
|
|
@@ -8380,7 +8380,7 @@ function e1(e) {
|
|
|
8380
8380
|
let n = new AbortController(), l = n.signal;
|
|
8381
8381
|
a.classList.add("is-pressed"), a.addEventListener("pointerenter", Xa(n), { capture: !0, signal: l }), a.addEventListener("pointerleave", Xa(n), { capture: !0, signal: l }), a.addEventListener("pointercancel", Xa(n), { signal: l }), a.addEventListener("pointerup", Xa(n), { signal: l }), Qi(o) && (a.classList.add("is-active"), i.shiftPressCount++), o.variants && (Or && clearTimeout(Or), Or = setTimeout(() => {
|
|
8382
8382
|
a.classList.contains("is-pressed") && (a.classList.remove("is-pressed"), a.classList.add("is-active"), e.target && "releasePointerCapture" in e.target && e.target.releasePointerCapture(e.pointerId), Ch(a, () => {
|
|
8383
|
-
n.abort(), a
|
|
8383
|
+
n.abort(), a?.classList.remove("is-active");
|
|
8384
8384
|
}));
|
|
8385
8385
|
}, 300)), e.preventDefault();
|
|
8386
8386
|
}
|
|
@@ -8538,7 +8538,7 @@ var Jt = class Dh {
|
|
|
8538
8538
|
}
|
|
8539
8539
|
dispatchEvent(t) {
|
|
8540
8540
|
return !this.listeners[t.type] || this.listeners[t.type].size === 0 ? !0 : (this.listeners[t.type].forEach((i) => {
|
|
8541
|
-
typeof i == "function" ? i(t) : i
|
|
8541
|
+
typeof i == "function" ? i(t) : i?.handleEvent(t);
|
|
8542
8542
|
}), !t.defaultPrevented);
|
|
8543
8543
|
}
|
|
8544
8544
|
removeEventListener(t, i, r) {
|
|
@@ -8802,7 +8802,7 @@ function mi(e, t) {
|
|
|
8802
8802
|
return typeof t == "string" ? r[t] : r;
|
|
8803
8803
|
}
|
|
8804
8804
|
function go() {
|
|
8805
|
-
return { readOnly: !1, defaultMode: "math", macros: {}, registers: {}, colorMap: qo, backgroundColorMap: Il, letterShapeStyle: $.locale.startsWith("fr") ? "french" : "tex", minFontScale: 0, maxMatrixCols: 10, smartMode: !1, smartFence: !0, smartSuperscript: !0, scriptDepth: [1 / 0, 1 / 0], removeExtraneousParentheses: !0, isImplicitFunction: (e) => ["\\sin", "\\cos", "\\tan", "\\arcsin", "\\arccos", "\\arctan", "\\arcsec", "\\arccsc", "\\arsinh", "\\arcosh", "\\artanh", "\\arcsech", "\\arccsch", "\\arg", "\\ch", "\\cosec", "\\cosh", "\\cot", "\\cotg", "\\coth", "\\csc", "\\ctg", "\\cth", "\\sec", "\\sinh", "\\sh", "\\tanh", "\\tg", "\\th", "\\lg", "\\lb", "\\log", "\\ln"].includes(e), mathModeSpace: "", placeholderSymbol: "▢", contentPlaceholder: "", popoverPolicy: "auto", environmentPopoverPolicy: "off", keybindings: em, inlineShortcuts: fd, inlineShortcutTimeout: 0, mathVirtualKeyboardPolicy: "auto", virtualKeyboardTargetOrigin: window
|
|
8805
|
+
return { readOnly: !1, defaultMode: "math", macros: {}, registers: {}, colorMap: qo, backgroundColorMap: Il, letterShapeStyle: $.locale.startsWith("fr") ? "french" : "tex", minFontScale: 0, maxMatrixCols: 10, smartMode: !1, smartFence: !0, smartSuperscript: !0, scriptDepth: [1 / 0, 1 / 0], removeExtraneousParentheses: !0, isImplicitFunction: (e) => ["\\sin", "\\cos", "\\tan", "\\arcsin", "\\arccos", "\\arctan", "\\arcsec", "\\arccsc", "\\arsinh", "\\arcosh", "\\artanh", "\\arcsech", "\\arccsch", "\\arg", "\\ch", "\\cosec", "\\cosh", "\\cot", "\\cotg", "\\coth", "\\csc", "\\ctg", "\\cth", "\\sec", "\\sinh", "\\sh", "\\tanh", "\\tg", "\\th", "\\lg", "\\lb", "\\log", "\\ln"].includes(e), mathModeSpace: "", placeholderSymbol: "▢", contentPlaceholder: "", popoverPolicy: "auto", environmentPopoverPolicy: "off", keybindings: em, inlineShortcuts: fd, inlineShortcutTimeout: 0, mathVirtualKeyboardPolicy: "auto", virtualKeyboardTargetOrigin: window?.origin, originValidator: "none", onInsertStyle: is, onInlineShortcut: () => "", onScrollIntoView: null, onExport: Qp, value: "" };
|
|
8806
8806
|
}
|
|
8807
8807
|
function _0(e) {
|
|
8808
8808
|
return e.defaultMode === "inline-math" ? "math" : e.defaultMode;
|
|
@@ -8881,10 +8881,10 @@ function Oe(e, t = [[[]]], i = [], r = [], a) {
|
|
|
8881
8881
|
return new V(e, t, i, { mathstyleName: "textstyle", leftDelim: "\\Vert", rightDelim: "\\Vert", columns: ri(r[0], a) });
|
|
8882
8882
|
case "matrix":
|
|
8883
8883
|
case "matrix*":
|
|
8884
|
-
return new V(e, t, i, { mathstyleName: "textstyle", leftDelim: ".", rightDelim: ".", columns: ri(r
|
|
8884
|
+
return new V(e, t, i, { mathstyleName: "textstyle", leftDelim: ".", rightDelim: ".", columns: ri(r?.[0], a) });
|
|
8885
8885
|
case "smallmatrix":
|
|
8886
8886
|
case "smallmatrix*":
|
|
8887
|
-
return new V(e, t, i, { mathstyleName: "scriptstyle", columns: ri(r
|
|
8887
|
+
return new V(e, t, i, { mathstyleName: "scriptstyle", columns: ri(r?.[0], a), colSeparationType: "small", arraystretch: 0.5 });
|
|
8888
8888
|
case "cases":
|
|
8889
8889
|
case "dcases":
|
|
8890
8890
|
return new V(e, t, i, { mathstyleName: e === "dcases" ? "displaystyle" : "textstyle", arraystretch: 1.2, leftDelim: "\\lbrace", rightDelim: ".", columns: [{ align: "l" }, { gap: 1 }, { align: "l" }] });
|
|
@@ -9026,7 +9026,7 @@ function Eh(e, t) {
|
|
|
9026
9026
|
function Th(e, t) {
|
|
9027
9027
|
let i = e.at(e.position);
|
|
9028
9028
|
for (; i && !(Array.isArray(i.parentBranch) && i.parent instanceof V); ) i = i.parent;
|
|
9029
|
-
if (Array.isArray(i
|
|
9029
|
+
if (Array.isArray(i?.parentBranch) && i?.parent instanceof V) {
|
|
9030
9030
|
let r = i.parent, a = i.parentBranch, o;
|
|
9031
9031
|
switch (t) {
|
|
9032
9032
|
case "row":
|
|
@@ -9127,7 +9127,7 @@ function Ml(e, t, i) {
|
|
|
9127
9127
|
function Ui(e, t, i) {
|
|
9128
9128
|
var r, a, o, n, l, s, u;
|
|
9129
9129
|
let c = e.position;
|
|
9130
|
-
(r = i
|
|
9130
|
+
(r = i?.extend) != null && r || e.collapseSelection(t);
|
|
9131
9131
|
let d = e.at(e.position);
|
|
9132
9132
|
if (t === "forward" && (d.type === "subsup" ? (d = d.rightSibling, d || (d = e.at(e.position + 1))) : d = e.at(e.position + 1)), !d) return e.announce("plonk"), !1;
|
|
9133
9133
|
let h = e.offsetOf(d);
|
|
@@ -9167,7 +9167,7 @@ function Ui(e, t, i) {
|
|
|
9167
9167
|
}
|
|
9168
9168
|
h -= 1;
|
|
9169
9169
|
}
|
|
9170
|
-
if ((u = i
|
|
9170
|
+
if ((u = i?.extend) != null && u) {
|
|
9171
9171
|
if (!e.setSelection(e.anchor, h)) return e.announce("plonk"), !1;
|
|
9172
9172
|
} else {
|
|
9173
9173
|
if (h === e.position) return e.announce("plonk"), !1;
|
|
@@ -9231,7 +9231,7 @@ function $o(e, t, i, r, a) {
|
|
|
9231
9231
|
}
|
|
9232
9232
|
function p1(e, t) {
|
|
9233
9233
|
var i, r;
|
|
9234
|
-
let a = (i = t
|
|
9234
|
+
let a = (i = t?.extend) != null ? i : !1;
|
|
9235
9235
|
a || e.collapseSelection("backward");
|
|
9236
9236
|
let o = () => {
|
|
9237
9237
|
var s, u;
|
|
@@ -9239,7 +9239,7 @@ function p1(e, t) {
|
|
|
9239
9239
|
return e.silenceNotifications || (c = (u = (s = e.mathfield.host) == null ? void 0 : s.dispatchEvent(new CustomEvent("move-out", { detail: { direction: "upward" }, cancelable: !0, bubbles: !0, composed: !0 }))) != null ? u : !0), e.announce(c ? "line" : "plonk"), c;
|
|
9240
9240
|
}, n = e.at(e.position), l = n;
|
|
9241
9241
|
for (; l && l.parentBranch !== "below" && !(Array.isArray(l.parentBranch) && l.parent instanceof V); ) l = l.parent;
|
|
9242
|
-
if (Array.isArray(l
|
|
9242
|
+
if (Array.isArray(l?.parentBranch) && l.parent instanceof V) {
|
|
9243
9243
|
let s = l.parent;
|
|
9244
9244
|
if (l.parentBranch[0] < 1) return o();
|
|
9245
9245
|
let u = l.parentBranch[0] - 1, c = s.array[u][l.parentBranch[1]];
|
|
@@ -9254,7 +9254,7 @@ function p1(e, t) {
|
|
|
9254
9254
|
}
|
|
9255
9255
|
function m1(e, t) {
|
|
9256
9256
|
var i, r;
|
|
9257
|
-
let a = (i = t
|
|
9257
|
+
let a = (i = t?.extend) != null ? i : !1;
|
|
9258
9258
|
a || e.collapseSelection("forward");
|
|
9259
9259
|
let o = () => {
|
|
9260
9260
|
var s, u;
|
|
@@ -9262,7 +9262,7 @@ function m1(e, t) {
|
|
|
9262
9262
|
return e.silenceNotifications || (c = (u = (s = e.mathfield.host) == null ? void 0 : s.dispatchEvent(new CustomEvent("move-out", { detail: { direction: "downward" }, cancelable: !0, bubbles: !0, composed: !0 }))) != null ? u : !0), e.announce(c ? "line" : "plonk"), c;
|
|
9263
9263
|
}, n = e.at(e.position), l = n;
|
|
9264
9264
|
for (; l && l.parentBranch !== "above" && !(Array.isArray(l.parentBranch) && l.parent instanceof V); ) l = l.parent;
|
|
9265
|
-
if (Array.isArray(l
|
|
9265
|
+
if (Array.isArray(l?.parentBranch) && l.parent instanceof V) {
|
|
9266
9266
|
let s = l.parent;
|
|
9267
9267
|
if (l.parentBranch[0] + 1 > s.array.length - 1) return o();
|
|
9268
9268
|
let u = l.parentBranch[0] + 1, c = s.array[u][l.parentBranch[1]];
|
|
@@ -9615,7 +9615,7 @@ function Oh(e, t) {
|
|
|
9615
9615
|
if (n === "[Space]") {
|
|
9616
9616
|
if (e.styleBias = "none", e.flushInlineShortcutBuffer(), e.options.mathModeSpace) return U.insert(o, e.options.mathModeSpace, { format: "latex", mode: "math" }), e.snapshot("insert-space"), u = "", e.dirty = !0, e.scrollIntoView(), t.preventDefault && (t.preventDefault(), t.stopPropagation()), !1;
|
|
9617
9617
|
let m = o.at(o.position + 1), b = o.at(o.position - 1);
|
|
9618
|
-
if (
|
|
9618
|
+
if (m?.mode === "text" || b?.mode === "text") return U.insert(o, " ", { mode: "text" }), e.snapshot("insert-space"), e.dirty = !0, e.scrollIntoView(), !1;
|
|
9619
9619
|
}
|
|
9620
9620
|
(a = o.at(o.position)) != null && a.isDigit() && globalThis.MathfieldElement.decimalSeparator === "," && Ri(t) === "," && (u = "insertDecimalSeparator");
|
|
9621
9621
|
}
|
|
@@ -9637,7 +9637,7 @@ function Oh(e, t) {
|
|
|
9637
9637
|
return !0;
|
|
9638
9638
|
}
|
|
9639
9639
|
let h = o.at(Math.max(o.position, o.anchor)), { parent: p } = h;
|
|
9640
|
-
if (u === "moveAfterParent" &&
|
|
9640
|
+
if (u === "moveAfterParent" && p?.type === "leftright" && h.isLastSibling && e.options.smartFence && Ll(o, ".", e.defaultStyle) && (u = "", Y(e)), e.keyboardDelegate.cancelComposition(), u) e.executeCommand(u);
|
|
9641
9641
|
else if (l) {
|
|
9642
9642
|
let m = ar(e);
|
|
9643
9643
|
o.setState(d[c].state);
|
|
@@ -10077,7 +10077,7 @@ var D1 = class extends U {
|
|
|
10077
10077
|
S.removeChild(b), S.setChildren(p, C);
|
|
10078
10078
|
}
|
|
10079
10079
|
let y = e.at(e.position);
|
|
10080
|
-
y.parent.addChildrenAfter(p, y), h === "latex" && typeof t == "string" &&
|
|
10080
|
+
y.parent.addChildrenAfter(p, y), h === "latex" && typeof t == "string" && b?.type === "root" && x && !c && (b.verbatimLatex = t), e.silenceNotifications = l;
|
|
10081
10081
|
let _ = p[p.length - 1];
|
|
10082
10082
|
if (i.selectionMode === "placeholder") {
|
|
10083
10083
|
let S = p.flatMap((C) => [C, ...C.children]).find((C) => C.type === "placeholder");
|
|
@@ -10103,7 +10103,7 @@ function Oo(e) {
|
|
|
10103
10103
|
var t;
|
|
10104
10104
|
if (e instanceof ee && e.leftDelim !== "(" && e.rightDelim === ")") {
|
|
10105
10105
|
let i = (t = e.body) == null ? void 0 : t.filter((r) => r.type !== "first");
|
|
10106
|
-
if (
|
|
10106
|
+
if (i?.length === 1 && i[0].type === "genfrac") return i[0];
|
|
10107
10107
|
}
|
|
10108
10108
|
for (let i of e.branches) e.hasEmptyBranch(i) || e.setChildren(e.branch(i).map((r) => Oo(r)), i);
|
|
10109
10109
|
return e instanceof V && e.forEachCell((i, r, a) => {
|
|
@@ -10354,7 +10354,7 @@ function q1(e) {
|
|
|
10354
10354
|
}
|
|
10355
10355
|
function Al() {
|
|
10356
10356
|
let e = document.getElementById("mathlive-environment-popover");
|
|
10357
|
-
e
|
|
10357
|
+
e?.classList.remove("is-visible");
|
|
10358
10358
|
}
|
|
10359
10359
|
function R1() {
|
|
10360
10360
|
document.getElementById("mathlive-environment-popover") && (rs("mathlive-environment-popover"), Wt("environment-popover"), Wt("core"));
|
|
@@ -10583,7 +10583,7 @@ var z0 = 80, Rh = class {
|
|
|
10583
10583
|
openSubmenu(e) {
|
|
10584
10584
|
var t;
|
|
10585
10585
|
if (this.type !== "submenu" || !this.element) return;
|
|
10586
|
-
if ((t = e
|
|
10586
|
+
if ((t = e?.withDelay) != null && t) {
|
|
10587
10587
|
this.rootMenu.scheduleOperation(() => this.openSubmenu());
|
|
10588
10588
|
return;
|
|
10589
10589
|
}
|
|
@@ -10616,7 +10616,7 @@ var Vh = class Tr {
|
|
|
10616
10616
|
constructor(t, i) {
|
|
10617
10617
|
this._element = null, this._activeMenuItem = null, this._dirty = !0;
|
|
10618
10618
|
var r, a;
|
|
10619
|
-
this.parentMenu = (r = i
|
|
10619
|
+
this.parentMenu = (r = i?.parentMenu) != null ? r : null, this._submenuClass = i?.submenuClass, this.columnCount = (a = i?.columnCount) != null ? a : 1, this.isSubmenuOpen = !1, this.menuItems = t;
|
|
10620
10620
|
}
|
|
10621
10621
|
get children() {
|
|
10622
10622
|
return Object.freeze([...this._menuItems]);
|
|
@@ -10693,7 +10693,7 @@ var Vh = class Tr {
|
|
|
10693
10693
|
let n = this.activeMenuItem;
|
|
10694
10694
|
n.active = !1, (i = n.submenu) == null || i.hide();
|
|
10695
10695
|
}
|
|
10696
|
-
if (!((r = t
|
|
10696
|
+
if (!((r = t?.visible) == null || r)) {
|
|
10697
10697
|
this._activeMenuItem = null;
|
|
10698
10698
|
return;
|
|
10699
10699
|
}
|
|
@@ -10780,7 +10780,7 @@ function $0() {
|
|
|
10780
10780
|
var Hh = class jh extends Vh {
|
|
10781
10781
|
constructor(t, i) {
|
|
10782
10782
|
var r;
|
|
10783
|
-
super(t), this.state = "closed", this.typingBufferResetTimer = 0, this.hysteresisTimer = 0, this._updating = !1, this._host = (r = i
|
|
10783
|
+
super(t), this.state = "closed", this.typingBufferResetTimer = 0, this.hysteresisTimer = 0, this._updating = !1, this._host = (r = i?.host) != null ? r : null, this.isDynamic = t.some(Wh), this._modifiers = { shift: !1, control: !1, alt: !1, meta: !1 }, this.typingBuffer = "", this.state = "closed";
|
|
10784
10784
|
}
|
|
10785
10785
|
get modifiers() {
|
|
10786
10786
|
return this._modifiers;
|
|
@@ -10817,10 +10817,10 @@ var Hh = class jh extends Vh {
|
|
|
10817
10817
|
case "Space":
|
|
10818
10818
|
case "Return":
|
|
10819
10819
|
case "Enter":
|
|
10820
|
-
l
|
|
10820
|
+
l?.select(gi(t));
|
|
10821
10821
|
break;
|
|
10822
10822
|
case "ArrowRight":
|
|
10823
|
-
if (
|
|
10823
|
+
if (l?.type === "submenu") l.select(gi(t)), this.activeSubmenu.activeMenuItem = this.activeSubmenu.firstMenuItem;
|
|
10824
10824
|
else if (!l) n.activeMenuItem = n.firstMenuItem;
|
|
10825
10825
|
else {
|
|
10826
10826
|
let s = (i = n.getMenuItemColumn(l)) != null ? i : -1;
|
|
@@ -10837,7 +10837,7 @@ var Hh = class jh extends Vh {
|
|
|
10837
10837
|
let s = n.parentMenu.activeMenuItem;
|
|
10838
10838
|
if (s) {
|
|
10839
10839
|
let { element: u } = s;
|
|
10840
|
-
u
|
|
10840
|
+
u?.focus(), u?.classList.remove("is-submenu-open");
|
|
10841
10841
|
}
|
|
10842
10842
|
} else {
|
|
10843
10843
|
let s = n.nextMenuItem(-1);
|
|
@@ -10910,7 +10910,7 @@ var Hh = class jh extends Vh {
|
|
|
10910
10910
|
return this;
|
|
10911
10911
|
}
|
|
10912
10912
|
show(t) {
|
|
10913
|
-
return this._onDismiss = t
|
|
10913
|
+
return this._onDismiss = t?.onDismiss, t != null && t.modifiers && (this.modifiers = t.modifiers), this.updateState(), this.connectScrim(t?.target), super.show(g(f({}, t), { container: this.scrim })) ? (this._openTimestamp = Date.now(), this.state = "open", !0) : (this.disconnectScrim(), !1);
|
|
10914
10914
|
}
|
|
10915
10915
|
hide() {
|
|
10916
10916
|
this.cancelDelayedOperation(), this.state !== void 0 && (this.state !== "closed" && (this.activeMenuItem = null, We.element.parentElement.focus(), super.hide(), this.state = "closed", this.disconnectScrim()), this._onDismiss && (this._onDismiss(), this._onDismiss = void 0));
|
|
@@ -10963,7 +10963,7 @@ async function O0(e, t, i) {
|
|
|
10963
10963
|
if (e.type === "keydown") {
|
|
10964
10964
|
let r = e;
|
|
10965
10965
|
if (r.code === "ContextMenu" || r.code === "F10" && r.shiftKey) {
|
|
10966
|
-
let a = t
|
|
10966
|
+
let a = t?.getBoundingClientRect();
|
|
10967
10967
|
if (I0(t) && a && i.show({ target: t, location: { x: Math.ceil(a.left + a.width / 2), y: Math.ceil(a.top + a.height / 2) }, modifiers: gi(r) })) return e.preventDefault(), e.stopPropagation(), !0;
|
|
10968
10968
|
}
|
|
10969
10969
|
}
|
|
@@ -12093,12 +12093,12 @@ function ng(e, t) {
|
|
|
12093
12093
|
function re(e, t) {
|
|
12094
12094
|
var i;
|
|
12095
12095
|
let r = g(f({}, Wl()), { renderPlaceholder: () => new L(160, { maxFontSize: 1 }) });
|
|
12096
|
-
if (t != null && t.letterShapeStyle &&
|
|
12097
|
-
let u = Rl(t
|
|
12096
|
+
if (t != null && t.letterShapeStyle && t?.letterShapeStyle !== "auto" && (r.letterShapeStyle = t.letterShapeStyle), t != null && t.macros) {
|
|
12097
|
+
let u = Rl(t?.macros);
|
|
12098
12098
|
r.getMacro = (c) => Vl(c, u);
|
|
12099
12099
|
}
|
|
12100
12100
|
t != null && t.registers && (r.registers = f(f({}, r.registers), t.registers));
|
|
12101
|
-
let a = (i = t
|
|
12101
|
+
let a = (i = t?.defaultMode) != null ? i : "math", o = "math", n = "displaystyle";
|
|
12102
12102
|
a === "inline-math" ? n = "textstyle" : a === "math" ? n = "displaystyle" : a === "text" && (n = "textstyle", o = "text");
|
|
12103
12103
|
let l = new O({ from: r }), s = new v({ type: "root", mode: o, body: we(e, { context: l, parseMode: o, mathstyle: n }) }).render(l);
|
|
12104
12104
|
return s ? (Ro(Qr(s, l)), Vo(s, { classes: "ML__latex" }).toMarkup()) : "";
|
|
@@ -12124,7 +12124,7 @@ function ug(e) {
|
|
|
12124
12124
|
|
|
12125
12125
|
import "https://unpkg.com/@cortex-js/compute-engine?module"`);
|
|
12126
12126
|
}
|
|
12127
|
-
return (i = ao
|
|
12127
|
+
return (i = ao?.box(e).latex) != null ? i : "";
|
|
12128
12128
|
}
|
|
12129
12129
|
function Zg(e, t = "math") {
|
|
12130
12130
|
return Z(new v({ type: "root", body: we(e, { parseMode: t }) }));
|
|
@@ -12326,7 +12326,7 @@ function kg(e) {
|
|
|
12326
12326
|
return e.isSelectionEditable && globalThis.MathfieldElement.computeEngine !== null && ((t = e.expression) == null ? void 0 : t.unknowns.length) === 1 && e.expression.unknowns[0] !== "Nothing";
|
|
12327
12327
|
}, onMenuSelect: () => {
|
|
12328
12328
|
var t;
|
|
12329
|
-
let i = e.expression, r = i
|
|
12329
|
+
let i = e.expression, r = i?.unknowns[0], a = (t = i.solve(r)) == null ? void 0 : t.map((o) => {
|
|
12330
12330
|
var n;
|
|
12331
12331
|
return (n = o.simplify().latex) != null ? n : "";
|
|
12332
12332
|
});
|
|
@@ -12334,7 +12334,7 @@ function kg(e) {
|
|
|
12334
12334
|
e.model.announce("plonk");
|
|
12335
12335
|
return;
|
|
12336
12336
|
}
|
|
12337
|
-
e.insert(`${r}=${a.length === 1 ? a[0] : "\\left\\lbrace" +
|
|
12337
|
+
e.insert(`${r}=${a.length === 1 ? a[0] : "\\left\\lbrace" + a?.join(", ") + "\\right\\rbrace"}`, { insertionMode: "replaceAll", selectionMode: "item" });
|
|
12338
12338
|
} }, { type: "divider" }, { label: () => z("menu.cut"), id: "cut", onMenuSelect: () => e.executeCommand("cutToClipboard"), visible: () => !e.options.readOnly && e.isSelectionEditable, keyboardShortcut: "meta+X" }, { label: () => z("menu.copy"), id: "copy", submenu: [{ label: () => z("menu.copy-as-latex"), id: "copy-latex", onMenuSelect: () => U.copyToClipboard(e, "latex"), keyboardShortcut: "meta+C" }, { label: () => z("menu.copy-as-ascii-math"), id: "copy-ascii-math", onMenuSelect: () => U.copyToClipboard(e, "ascii-math") }, { label: () => z("menu.copy-as-mathml"), id: "copy-math-ml", onMenuSelect: () => U.copyToClipboard(e, "math-ml") }] }, { label: () => z("menu.paste"), id: "paste", onMenuSelect: () => e.executeCommand("pasteFromClipboard"), visible: () => e.hasEditableContent, keyboardShortcut: "meta+V" }, { label: () => z("menu.select-all"), id: "select-all", keyboardShortcut: "meta+A", onMenuSelect: () => e.executeCommand("selectAll") }];
|
|
12339
12339
|
}
|
|
12340
12340
|
function si(e) {
|
|
@@ -12460,9 +12460,9 @@ var Eg = class {
|
|
|
12460
12460
|
setState(e, t) {
|
|
12461
12461
|
var i;
|
|
12462
12462
|
let r = this.silenceNotifications;
|
|
12463
|
-
this.silenceNotifications = (i = t
|
|
12463
|
+
this.silenceNotifications = (i = t?.silenceNotifications) != null ? i : !0;
|
|
12464
12464
|
let a = {};
|
|
12465
|
-
if (
|
|
12465
|
+
if (t?.type === "undo" && (a = { inputType: "historyUndo" }), t?.type === "redo" && (a = { inputType: "historyRedo" }), this.contentWillChange(a)) {
|
|
12466
12466
|
let o = this.silenceNotifications;
|
|
12467
12467
|
this.silenceNotifications = !0, this.mode = e.mode, this.root = jt(e.content), this.selection = e.selection, this.silenceNotifications = o, this.contentDidChange(a), this.selectionDidChange();
|
|
12468
12468
|
}
|
|
@@ -12502,13 +12502,13 @@ var Eg = class {
|
|
|
12502
12502
|
let n = be(o);
|
|
12503
12503
|
o.direction === "backward" ? [this._position, this._anchor] = n : [this._anchor, this._position] = n;
|
|
12504
12504
|
let l = this.at(n[0] + 1), s = this.at(n[1]), u = v.commonAncestor(l, s);
|
|
12505
|
-
|
|
12505
|
+
u?.type === "array" && l.parent === u && s.parent === u ? this._selection = { ranges: [n], direction: o.direction } : this._selection = { ranges: [n], direction: o.direction }, this._position >= 0 && this._position <= this.lastOffset;
|
|
12506
12506
|
});
|
|
12507
12507
|
}
|
|
12508
12508
|
setPositionHandlingPlaceholder(e) {
|
|
12509
12509
|
var t;
|
|
12510
12510
|
let i = this.at(e);
|
|
12511
|
-
|
|
12511
|
+
i?.type === "placeholder" ? this.setSelection(e - 1, e) : ((t = i?.rightSibling) == null ? void 0 : t.type) === "placeholder" ? this.setSelection(e, e + 1) : this.position = e, i instanceof se && i.isSuggestion && (i.isSuggestion = !1), this.mathfield.stopCoalescingUndo();
|
|
12512
12512
|
}
|
|
12513
12513
|
get position() {
|
|
12514
12514
|
return this._position;
|
|
@@ -12639,7 +12639,7 @@ import "https://unpkg.com/@cortex-js/compute-engine?module"`), '["Error", "compu
|
|
|
12639
12639
|
let i = this.normalizeRange([e, t]), [r, a] = i, { parent: o } = this.at(a);
|
|
12640
12640
|
if (o && (o.type === "genfrac" || o.type === "subsup")) for (; o !== this.root && rl(this, o, [r, a]); ) a = this.offsetOf(o), o = o.parent;
|
|
12641
12641
|
for (o = this.at(r).parent; o !== this.root && rl(this, o, [r, a]); ) r = this.offsetOf(o.leftSibling), o = o.parent;
|
|
12642
|
-
if (o = this.at(a).parent,
|
|
12642
|
+
if (o = this.at(a).parent, o?.type === "genfrac") for (; o !== this.root && rl(this, o, [r, a]); ) a = this.offsetOf(o), o = o.parent;
|
|
12643
12643
|
this._position = this.normalizeOffset(t), this._selection = { ranges: [[r, a]], direction: "none" };
|
|
12644
12644
|
});
|
|
12645
12645
|
}
|
|
@@ -12782,11 +12782,11 @@ function Ir(e, t, i, r) {
|
|
|
12782
12782
|
}
|
|
12783
12783
|
return !0;
|
|
12784
12784
|
}
|
|
12785
|
-
if (
|
|
12785
|
+
if (c?.type === "genfrac" && !r && i.type !== "first") {
|
|
12786
12786
|
let d = e.offsetOf(i.leftSibling);
|
|
12787
12787
|
return c.removeChild(i), c.hasEmptyBranch("above") && c.hasEmptyBranch("below") ? (d = e.offsetOf(c.leftSibling), c.parent.removeChild(c), e.announce("delete", void 0, [c]), e.position = d, !0) : (e.announce("delete", void 0, [i]), e.position = d, !0);
|
|
12788
12788
|
}
|
|
12789
|
-
if (t === "backward" && (
|
|
12789
|
+
if (t === "backward" && (c?.command === "\\ln" || c?.command === "\\log") && i.parentBranch !== "body") {
|
|
12790
12790
|
let d = e.offsetOf(c.leftSibling);
|
|
12791
12791
|
return c.parent.removeChild(c), e.announce("delete", void 0, [c]), e.position = d, !0;
|
|
12792
12792
|
}
|
|
@@ -12825,7 +12825,7 @@ function Fg(e) {
|
|
|
12825
12825
|
}
|
|
12826
12826
|
r.parent.removeChild(r);
|
|
12827
12827
|
let a = (t = e.at(e.position)) == null ? void 0 : t.rightSibling;
|
|
12828
|
-
for (;
|
|
12828
|
+
for (; a?.type === "subsup"; ) a.parent.removeChild(a), a = (i = e.at(e.position)) == null ? void 0 : i.rightSibling;
|
|
12829
12829
|
e.announce("delete", void 0, [r]);
|
|
12830
12830
|
}) : nt(e, be(e.selection), "deleteContentForward");
|
|
12831
12831
|
}
|
|
@@ -12877,7 +12877,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
12877
12877
|
window.mathVirtualKeyboard.visible ? window.mathVirtualKeyboard.hide() : (window.mathVirtualKeyboard.show({ animate: !0 }), window.mathVirtualKeyboard.update(Nt(this)));
|
|
12878
12878
|
}, { signal: o }), this.field.addEventListener("contextmenu", this, { signal: o });
|
|
12879
12879
|
let c = this.element.querySelector("[part=menu-toggle]");
|
|
12880
|
-
c
|
|
12880
|
+
c?.addEventListener("pointerdown", (d) => {
|
|
12881
12881
|
if (d.currentTarget !== c) return;
|
|
12882
12882
|
let h = this.menu;
|
|
12883
12883
|
if (h.state !== "closed") return;
|
|
@@ -12900,7 +12900,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
12900
12900
|
}
|
|
12901
12901
|
showMenu(e) {
|
|
12902
12902
|
var t, i;
|
|
12903
|
-
let r = (i = (t = e
|
|
12903
|
+
let r = (i = (t = e?.location) != null ? t : ho(this.field)) != null ? i : void 0, a = e?.modifiers, o = this.element.querySelector("[part=container]");
|
|
12904
12904
|
return this._menu.show({ target: o, location: r, modifiers: a });
|
|
12905
12905
|
}
|
|
12906
12906
|
get colorMap() {
|
|
@@ -12945,7 +12945,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
12945
12945
|
if (this.disabled || !this.contentEditable) return !1;
|
|
12946
12946
|
if (!this.readOnly) return !0;
|
|
12947
12947
|
let e = this.model.at(this.model.anchor), t = this.model.at(this.model.position), i = v.commonAncestor(e, t);
|
|
12948
|
-
return !!(
|
|
12948
|
+
return !!(i?.type === "prompt" || i != null && i.parentPrompt);
|
|
12949
12949
|
}
|
|
12950
12950
|
get letterShapeStyle() {
|
|
12951
12951
|
var e;
|
|
@@ -13121,7 +13121,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
13121
13121
|
}
|
|
13122
13122
|
}
|
|
13123
13123
|
insert(e, t) {
|
|
13124
|
-
if (typeof e != "string" || e.length === 0 && (
|
|
13124
|
+
if (typeof e != "string" || e.length === 0 && (t?.insertionMode === "insertBefore" || t?.insertionMode === "insertAfter") || e.length === 0 && this.model.selectionIsCollapsed) return !1;
|
|
13125
13125
|
if (this.flushInlineShortcutBuffer(), t = t ?? { mode: "math" }, t.focus && this.focus(), t.feedback && (globalThis.MathfieldElement.keypressVibration && Y0() && navigator.vibrate(Mh), globalThis.MathfieldElement.playSound("keypress")), e === "\\\\") Bh(this.model);
|
|
13126
13126
|
else if (e === "&") Ah(this.model);
|
|
13127
13127
|
else if (this.model.selectionIsCollapsed) {
|
|
@@ -13166,7 +13166,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
13166
13166
|
}
|
|
13167
13167
|
focus(e) {
|
|
13168
13168
|
var t;
|
|
13169
|
-
this.hasFocus() || (this.keyboardDelegate.focus(), this.connectToVirtualKeyboard(), this.onFocus(), this.model.announce("line")), (t = e
|
|
13169
|
+
this.hasFocus() || (this.keyboardDelegate.focus(), this.connectToVirtualKeyboard(), this.onFocus(), this.model.announce("line")), (t = e?.preventScroll) != null && t || this.scrollIntoView();
|
|
13170
13170
|
}
|
|
13171
13171
|
blur() {
|
|
13172
13172
|
this.disconnectFromVirtualKeyboard(), this.hasFocus() && this.keyboardDelegate.blur();
|
|
@@ -13290,7 +13290,7 @@ var zg = `<svg xmlns="http://www.w3.org/2000/svg" style="width: 21px;" viewBox=
|
|
|
13290
13290
|
if (r && (a < i.offsetOf(r.firstChild) - 1 || a > i.offsetOf(r.lastChild) + 1)) or(this, "accept", { mode: n }), i.position = i.offsetOf(o);
|
|
13291
13291
|
else {
|
|
13292
13292
|
let l = i.at(a + 1);
|
|
13293
|
-
|
|
13293
|
+
l?.type === "first" && l.mode === "latex" ? i.position = a + 1 : r && l?.mode !== "latex" ? i.position = a - 1 : this.switchMode(n);
|
|
13294
13294
|
}
|
|
13295
13295
|
}
|
|
13296
13296
|
(t = this.host) == null || t.dispatchEvent(new Event("selection-change", { bubbles: !0, composed: !0 })), window.mathVirtualKeyboard.visible && window.mathVirtualKeyboard.update(Nt(this)), to(this);
|
|
@@ -13922,7 +13922,7 @@ var R = /* @__PURE__ */ new WeakMap(), Ng = 0.5, $t = { letterShapeStyle: "mf.le
|
|
|
13922
13922
|
c.textContent = this._style, o.appendChild(c);
|
|
13923
13923
|
}
|
|
13924
13924
|
let u = "";
|
|
13925
|
-
if (this.hasAttribute("value") ? u = this.getAttribute("value") : u = (t = s
|
|
13925
|
+
if (this.hasAttribute("value") ? u = this.getAttribute("value") : u = (t = s?.assignedNodes().map((c) => c.nodeType === 3 ? c.textContent : "").join("").trim()) != null ? t : "", this._mathfield = new $g(o.querySelector(":host > span"), g(f({}, (r = (i = R.get(this)) == null ? void 0 : i.options) != null ? r : oo(this)), { eventSink: this, value: u })), !R.has(this)) {
|
|
13926
13926
|
this.upgradeProperty("disabled"), this.upgradeProperty("readonly");
|
|
13927
13927
|
for (let c of Object.keys(Pt.optionsAttributes)) this.upgradeProperty(vt(c));
|
|
13928
13928
|
}
|
|
@@ -14248,7 +14248,7 @@ ie.version = "0.101.2", ie.openUrl = (e) => {
|
|
|
14248
14248
|
}, ie._fontsDirectory = "./fonts", ie._soundsDirectory = "./sounds", ie.keypressVibration = !0, ie._keypressSound = { spacebar: "keypress-spacebar.wav", return: "keypress-return.wav", delete: "keypress-delete.wav", default: "keypress-standard.wav" }, ie._plonkSound = "plonk.wav", ie.audioBuffers = {}, ie.createHTML = (e) => e, ie._speechEngineRate = "100%", ie._speechEngineVoice = "Joanna", ie._textToSpeechMarkup = "", ie._textToSpeechRules = "mathlive", ie._textToSpeechRulesOptions = {}, ie.speakHook = Og, ie.readAloudHook = Ig, ie.restoreFocusWhenDocumentFocused = !0, ie._decimalSeparator = ".", ie._isFunction = (e) => {
|
|
14249
14249
|
var t, i;
|
|
14250
14250
|
let r = globalThis.MathfieldElement.computeEngine;
|
|
14251
|
-
return (i = (t = r
|
|
14251
|
+
return (i = (t = r?.parse(e).domain) == null ? void 0 : t.isFunction) != null ? i : !1;
|
|
14252
14252
|
};
|
|
14253
14253
|
var ki = ie;
|
|
14254
14254
|
function vt(e) {
|
|
@@ -14260,7 +14260,7 @@ function oo(e) {
|
|
|
14260
14260
|
var a;
|
|
14261
14261
|
if (e.hasAttribute(r)) {
|
|
14262
14262
|
let o = e.getAttribute(r);
|
|
14263
|
-
r === "placeholder" ? t.contentPlaceholder = o ?? "" : i[r] === "boolean" ? t[vt(r)] = !0 : i[r] === "on/off" ? (o = (a = o
|
|
14263
|
+
r === "placeholder" ? t.contentPlaceholder = o ?? "" : i[r] === "boolean" ? t[vt(r)] = !0 : i[r] === "on/off" ? (o = (a = o?.toLowerCase()) != null ? a : "", o === "on" || o === "true" ? t[vt(r)] = !0 : o === "off" || o === "false" ? t[vt(r)] = !1 : t[vt(r)] = void 0) : i[r] === "number" ? t[vt(r)] = Number.parseFloat(o ?? "0") : t[vt(r)] = o;
|
|
14264
14264
|
}
|
|
14265
14265
|
}), t;
|
|
14266
14266
|
}
|