diff --git "a/src/backend/gradio_gptchatbot/templates/component/index.js" "b/src/backend/gradio_gptchatbot/templates/component/index.js" new file mode 100644--- /dev/null +++ "b/src/backend/gradio_gptchatbot/templates/component/index.js" @@ -0,0 +1,18219 @@ +var mu = Object.defineProperty; +var du = (s, r, a) => r in s ? mu(s, r, { enumerable: !0, configurable: !0, writable: !0, value: a }) : s[r] = a; +var Fe = (s, r, a) => (du(s, typeof r != "symbol" ? r + "" : r, a), a), pu = (s, r, a) => { + if (!r.has(s)) + throw TypeError("Cannot " + a); +}; +var Ca = (s, r, a) => { + if (r.has(s)) + throw TypeError("Cannot add the same private member more than once"); + r instanceof WeakSet ? r.add(s) : r.set(s, a); +}; +var bn = (s, r, a) => (pu(s, r, "access private method"), a); +const gu = [ + { color: "red", primary: 600, secondary: 100 }, + { color: "green", primary: 600, secondary: 100 }, + { color: "blue", primary: 600, secondary: 100 }, + { color: "yellow", primary: 500, secondary: 100 }, + { color: "purple", primary: 600, secondary: 100 }, + { color: "teal", primary: 600, secondary: 100 }, + { color: "orange", primary: 600, secondary: 100 }, + { color: "cyan", primary: 600, secondary: 100 }, + { color: "lime", primary: 500, secondary: 100 }, + { color: "pink", primary: 600, secondary: 100 } +], Cl = { + inherit: "inherit", + current: "currentColor", + transparent: "transparent", + black: "#000", + white: "#fff", + slate: { + 50: "#f8fafc", + 100: "#f1f5f9", + 200: "#e2e8f0", + 300: "#cbd5e1", + 400: "#94a3b8", + 500: "#64748b", + 600: "#475569", + 700: "#334155", + 800: "#1e293b", + 900: "#0f172a", + 950: "#020617" + }, + gray: { + 50: "#f9fafb", + 100: "#f3f4f6", + 200: "#e5e7eb", + 300: "#d1d5db", + 400: "#9ca3af", + 500: "#6b7280", + 600: "#4b5563", + 700: "#374151", + 800: "#1f2937", + 900: "#111827", + 950: "#030712" + }, + zinc: { + 50: "#fafafa", + 100: "#f4f4f5", + 200: "#e4e4e7", + 300: "#d4d4d8", + 400: "#a1a1aa", + 500: "#71717a", + 600: "#52525b", + 700: "#3f3f46", + 800: "#27272a", + 900: "#18181b", + 950: "#09090b" + }, + neutral: { + 50: "#fafafa", + 100: "#f5f5f5", + 200: "#e5e5e5", + 300: "#d4d4d4", + 400: "#a3a3a3", + 500: "#737373", + 600: "#525252", + 700: "#404040", + 800: "#262626", + 900: "#171717", + 950: "#0a0a0a" + }, + stone: { + 50: "#fafaf9", + 100: "#f5f5f4", + 200: "#e7e5e4", + 300: "#d6d3d1", + 400: "#a8a29e", + 500: "#78716c", + 600: "#57534e", + 700: "#44403c", + 800: "#292524", + 900: "#1c1917", + 950: "#0c0a09" + }, + red: { + 50: "#fef2f2", + 100: "#fee2e2", + 200: "#fecaca", + 300: "#fca5a5", + 400: "#f87171", + 500: "#ef4444", + 600: "#dc2626", + 700: "#b91c1c", + 800: "#991b1b", + 900: "#7f1d1d", + 950: "#450a0a" + }, + orange: { + 50: "#fff7ed", + 100: "#ffedd5", + 200: "#fed7aa", + 300: "#fdba74", + 400: "#fb923c", + 500: "#f97316", + 600: "#ea580c", + 700: "#c2410c", + 800: "#9a3412", + 900: "#7c2d12", + 950: "#431407" + }, + amber: { + 50: "#fffbeb", + 100: "#fef3c7", + 200: "#fde68a", + 300: "#fcd34d", + 400: "#fbbf24", + 500: "#f59e0b", + 600: "#d97706", + 700: "#b45309", + 800: "#92400e", + 900: "#78350f", + 950: "#451a03" + }, + yellow: { + 50: "#fefce8", + 100: "#fef9c3", + 200: "#fef08a", + 300: "#fde047", + 400: "#facc15", + 500: "#eab308", + 600: "#ca8a04", + 700: "#a16207", + 800: "#854d0e", + 900: "#713f12", + 950: "#422006" + }, + lime: { + 50: "#f7fee7", + 100: "#ecfccb", + 200: "#d9f99d", + 300: "#bef264", + 400: "#a3e635", + 500: "#84cc16", + 600: "#65a30d", + 700: "#4d7c0f", + 800: "#3f6212", + 900: "#365314", + 950: "#1a2e05" + }, + green: { + 50: "#f0fdf4", + 100: "#dcfce7", + 200: "#bbf7d0", + 300: "#86efac", + 400: "#4ade80", + 500: "#22c55e", + 600: "#16a34a", + 700: "#15803d", + 800: "#166534", + 900: "#14532d", + 950: "#052e16" + }, + emerald: { + 50: "#ecfdf5", + 100: "#d1fae5", + 200: "#a7f3d0", + 300: "#6ee7b7", + 400: "#34d399", + 500: "#10b981", + 600: "#059669", + 700: "#047857", + 800: "#065f46", + 900: "#064e3b", + 950: "#022c22" + }, + teal: { + 50: "#f0fdfa", + 100: "#ccfbf1", + 200: "#99f6e4", + 300: "#5eead4", + 400: "#2dd4bf", + 500: "#14b8a6", + 600: "#0d9488", + 700: "#0f766e", + 800: "#115e59", + 900: "#134e4a", + 950: "#042f2e" + }, + cyan: { + 50: "#ecfeff", + 100: "#cffafe", + 200: "#a5f3fc", + 300: "#67e8f9", + 400: "#22d3ee", + 500: "#06b6d4", + 600: "#0891b2", + 700: "#0e7490", + 800: "#155e75", + 900: "#164e63", + 950: "#083344" + }, + sky: { + 50: "#f0f9ff", + 100: "#e0f2fe", + 200: "#bae6fd", + 300: "#7dd3fc", + 400: "#38bdf8", + 500: "#0ea5e9", + 600: "#0284c7", + 700: "#0369a1", + 800: "#075985", + 900: "#0c4a6e", + 950: "#082f49" + }, + blue: { + 50: "#eff6ff", + 100: "#dbeafe", + 200: "#bfdbfe", + 300: "#93c5fd", + 400: "#60a5fa", + 500: "#3b82f6", + 600: "#2563eb", + 700: "#1d4ed8", + 800: "#1e40af", + 900: "#1e3a8a", + 950: "#172554" + }, + indigo: { + 50: "#eef2ff", + 100: "#e0e7ff", + 200: "#c7d2fe", + 300: "#a5b4fc", + 400: "#818cf8", + 500: "#6366f1", + 600: "#4f46e5", + 700: "#4338ca", + 800: "#3730a3", + 900: "#312e81", + 950: "#1e1b4b" + }, + violet: { + 50: "#f5f3ff", + 100: "#ede9fe", + 200: "#ddd6fe", + 300: "#c4b5fd", + 400: "#a78bfa", + 500: "#8b5cf6", + 600: "#7c3aed", + 700: "#6d28d9", + 800: "#5b21b6", + 900: "#4c1d95", + 950: "#2e1065" + }, + purple: { + 50: "#faf5ff", + 100: "#f3e8ff", + 200: "#e9d5ff", + 300: "#d8b4fe", + 400: "#c084fc", + 500: "#a855f7", + 600: "#9333ea", + 700: "#7e22ce", + 800: "#6b21a8", + 900: "#581c87", + 950: "#3b0764" + }, + fuchsia: { + 50: "#fdf4ff", + 100: "#fae8ff", + 200: "#f5d0fe", + 300: "#f0abfc", + 400: "#e879f9", + 500: "#d946ef", + 600: "#c026d3", + 700: "#a21caf", + 800: "#86198f", + 900: "#701a75", + 950: "#4a044e" + }, + pink: { + 50: "#fdf2f8", + 100: "#fce7f3", + 200: "#fbcfe8", + 300: "#f9a8d4", + 400: "#f472b6", + 500: "#ec4899", + 600: "#db2777", + 700: "#be185d", + 800: "#9d174d", + 900: "#831843", + 950: "#500724" + }, + rose: { + 50: "#fff1f2", + 100: "#ffe4e6", + 200: "#fecdd3", + 300: "#fda4af", + 400: "#fb7185", + 500: "#f43f5e", + 600: "#e11d48", + 700: "#be123c", + 800: "#9f1239", + 900: "#881337", + 950: "#4c0519" + } +}; +gu.reduce( + (s, { color: r, primary: a, secondary: i }) => ({ + ...s, + [r]: { + primary: Cl[r][a], + secondary: Cl[r][i] + } + }), + {} +); +function so(s) { + let r, a = s[0], i = 1; + for (; i < s.length; ) { + const o = s[i], u = s[i + 1]; + if (i += 2, (o === "optionalAccess" || o === "optionalCall") && a == null) + return; + o === "access" || o === "optionalAccess" ? (r = a, a = u(a)) : (o === "call" || o === "optionalCall") && (a = u((...g) => a.call(r, ...g)), r = void 0); + } + return a; +} +class Cn extends Error { + constructor(r) { + super(r), this.name = "ShareError"; + } +} +async function El(s, r) { + if (window.__gradio_space__ == null) + throw new Cn("Must be on Spaces to share."); + let a, i, o; + if (r === "url") { + const v = await fetch(s); + a = await v.blob(), i = v.headers.get("content-type") || "", o = v.headers.get("content-disposition") || ""; + } else + a = vu(s), i = s.split(";")[0].split(":")[1], o = "file" + i.split("/")[1]; + const u = new File([a], o, { type: i }), g = await fetch("https://huggingface.co/uploads", { + method: "POST", + body: u, + headers: { + "Content-Type": u.type, + "X-Requested-With": "XMLHttpRequest" + } + }); + if (!g.ok) { + if (so([g, "access", (v) => v.headers, "access", (v) => v.get, "call", (v) => v("content-type"), "optionalAccess", (v) => v.includes, "call", (v) => v("application/json")])) { + const v = await g.json(); + throw new Cn(`Upload failed: ${v.error}`); + } + throw new Cn("Upload failed."); + } + return await g.text(); +} +function vu(s) { + for (var r = s.split(","), a = r[0].match(/:(.*?);/)[1], i = atob(r[1]), o = i.length, u = new Uint8Array(o); o--; ) + u[o] = i.charCodeAt(o); + return new Blob([u], { type: a }); +} +function oo(s) { + s.addEventListener("click", r); + async function r(a) { + const i = a.composedPath(), [o] = i.filter( + (u) => so([u, "optionalAccess", (g) => g.tagName]) === "BUTTON" && u.classList.contains("copy_code_button") + ); + if (o) { + let u = function(w) { + w.style.opacity = "1", setTimeout(() => { + w.style.opacity = "0"; + }, 2e3); + }; + a.stopImmediatePropagation(); + const g = o.parentElement.innerText.trim(), p = Array.from( + o.children + )[1]; + await bu(g) && u(p); + } + } + return { + destroy() { + s.removeEventListener("click", r); + } + }; +} +async function bu(s) { + let r = !1; + if ("clipboard" in navigator) + await navigator.clipboard.writeText(s), r = !0; + else { + const a = document.createElement("textarea"); + a.value = s, a.style.position = "absolute", a.style.left = "-999999px", document.body.prepend(a), a.select(); + try { + document.execCommand("copy"), r = !0; + } catch (i) { + console.error(i), r = !1; + } finally { + a.remove(); + } + } + return r; +} +function yn(s) { + let r, a = s[0], i = 1; + for (; i < s.length; ) { + const o = s[i], u = s[i + 1]; + if (i += 2, (o === "optionalAccess" || o === "optionalCall") && a == null) + return; + o === "access" || o === "optionalAccess" ? (r = a, a = u(a)) : (o === "call" || o === "optionalCall") && (a = u((...g) => a.call(r, ...g)), r = void 0); + } + return a; +} +const yu = async (s) => (await Promise.all( + s.map(async (a) => await Promise.all( + a.map(async (i, o) => { + if (i === null) + return ""; + let u = o === 0 ? "😃" : "🤖", g = ""; + if (typeof i == "string") { + const p = { + audio: /|!\[.*?\]\((\/file=.*?)\)/g + }; + g = i; + for (let [v, w] of Object.entries(p)) { + let S; + for (; (S = w.exec(i)) !== null; ) { + const L = S[1] || S[2], O = await El(L, "url"); + g = g.replace(L, O); + } + } + } else { + if (!yn([i, "optionalAccess", (v) => v.url])) + return ""; + const p = await El(i.url, "url"); + yn([i, "access", (v) => v.mime_type, "optionalAccess", (v) => v.includes, "call", (v) => v("audio")]) ? g = `` : yn([i, "access", (v) => v.mime_type, "optionalAccess", (v) => v.includes, "call", (v) => v("video")]) ? g = p : yn([i, "access", (v) => v.mime_type, "optionalAccess", (v) => v.includes, "call", (v) => v("image")]) && (g = ``); + } + return `${u}: ${g}`; + }) + )) +)).map( + (a) => a.join( + a[0] !== "" && a[1] !== "" ? ` +` : "" + ) +).join(` +`); +var Bl = Object.prototype.hasOwnProperty; +function Za(s, r) { + var a, i; + if (s === r) + return !0; + if (s && r && (a = s.constructor) === r.constructor) { + if (a === Date) + return s.getTime() === r.getTime(); + if (a === RegExp) + return s.toString() === r.toString(); + if (a === Array) { + if ((i = s.length) === r.length) + for (; i-- && Za(s[i], r[i]); ) + ; + return i === -1; + } + if (!a || typeof s == "object") { + i = 0; + for (a in s) + if (Bl.call(s, a) && ++i && !Bl.call(r, a) || !(a in r) || !Za(s[a], r[a])) + return !1; + return Object.keys(r).length === i; + } + } + return s !== s && r !== r; +} +const { + SvelteComponent: wu, + assign: ku, + create_slot: _u, + detach: xu, + element: Su, + get_all_dirty_from_scope: Au, + get_slot_changes: Tu, + get_spread_update: Mu, + init: zu, + insert: Cu, + safe_not_equal: Eu, + set_dynamic_element_data: Dl, + set_style: zt, + toggle_class: R0, + transition_in: uo, + transition_out: co, + update_slot_base: Bu +} = window.__gradio__svelte__internal; +function Du(s) { + let r, a, i; + const o = ( + /*#slots*/ + s[17].default + ), u = _u( + o, + s, + /*$$scope*/ + s[16], + null + ); + let g = [ + { "data-testid": ( + /*test_id*/ + s[7] + ) }, + { id: ( + /*elem_id*/ + s[2] + ) }, + { + class: a = "block " + /*elem_classes*/ + s[3].join(" ") + " svelte-1t38q2d" + } + ], p = {}; + for (let v = 0; v < g.length; v += 1) + p = ku(p, g[v]); + return { + c() { + r = Su( + /*tag*/ + s[14] + ), u && u.c(), Dl( + /*tag*/ + s[14] + )(r, p), R0( + r, + "hidden", + /*visible*/ + s[10] === !1 + ), R0( + r, + "padded", + /*padding*/ + s[6] + ), R0( + r, + "border_focus", + /*border_mode*/ + s[5] === "focus" + ), R0(r, "hide-container", !/*explicit_call*/ + s[8] && !/*container*/ + s[9]), zt(r, "height", typeof /*height*/ + s[0] == "number" ? ( + /*height*/ + s[0] + "px" + ) : void 0), zt(r, "width", typeof /*width*/ + s[1] == "number" ? `calc(min(${/*width*/ + s[1]}px, 100%))` : void 0), zt( + r, + "border-style", + /*variant*/ + s[4] + ), zt( + r, + "overflow", + /*allow_overflow*/ + s[11] ? "visible" : "hidden" + ), zt( + r, + "flex-grow", + /*scale*/ + s[12] + ), zt(r, "min-width", `calc(min(${/*min_width*/ + s[13]}px, 100%))`), zt(r, "border-width", "var(--block-border-width)"); + }, + m(v, w) { + Cu(v, r, w), u && u.m(r, null), i = !0; + }, + p(v, w) { + u && u.p && (!i || w & /*$$scope*/ + 65536) && Bu( + u, + o, + v, + /*$$scope*/ + v[16], + i ? Tu( + o, + /*$$scope*/ + v[16], + w, + null + ) : Au( + /*$$scope*/ + v[16] + ), + null + ), Dl( + /*tag*/ + v[14] + )(r, p = Mu(g, [ + (!i || w & /*test_id*/ + 128) && { "data-testid": ( + /*test_id*/ + v[7] + ) }, + (!i || w & /*elem_id*/ + 4) && { id: ( + /*elem_id*/ + v[2] + ) }, + (!i || w & /*elem_classes*/ + 8 && a !== (a = "block " + /*elem_classes*/ + v[3].join(" ") + " svelte-1t38q2d")) && { class: a } + ])), R0( + r, + "hidden", + /*visible*/ + v[10] === !1 + ), R0( + r, + "padded", + /*padding*/ + v[6] + ), R0( + r, + "border_focus", + /*border_mode*/ + v[5] === "focus" + ), R0(r, "hide-container", !/*explicit_call*/ + v[8] && !/*container*/ + v[9]), w & /*height*/ + 1 && zt(r, "height", typeof /*height*/ + v[0] == "number" ? ( + /*height*/ + v[0] + "px" + ) : void 0), w & /*width*/ + 2 && zt(r, "width", typeof /*width*/ + v[1] == "number" ? `calc(min(${/*width*/ + v[1]}px, 100%))` : void 0), w & /*variant*/ + 16 && zt( + r, + "border-style", + /*variant*/ + v[4] + ), w & /*allow_overflow*/ + 2048 && zt( + r, + "overflow", + /*allow_overflow*/ + v[11] ? "visible" : "hidden" + ), w & /*scale*/ + 4096 && zt( + r, + "flex-grow", + /*scale*/ + v[12] + ), w & /*min_width*/ + 8192 && zt(r, "min-width", `calc(min(${/*min_width*/ + v[13]}px, 100%))`); + }, + i(v) { + i || (uo(u, v), i = !0); + }, + o(v) { + co(u, v), i = !1; + }, + d(v) { + v && xu(r), u && u.d(v); + } + }; +} +function Nu(s) { + let r, a = ( + /*tag*/ + s[14] && Du(s) + ); + return { + c() { + a && a.c(); + }, + m(i, o) { + a && a.m(i, o), r = !0; + }, + p(i, [o]) { + /*tag*/ + i[14] && a.p(i, o); + }, + i(i) { + r || (uo(a, i), r = !0); + }, + o(i) { + co(a, i), r = !1; + }, + d(i) { + a && a.d(i); + } + }; +} +function Ru(s, r, a) { + let { $$slots: i = {}, $$scope: o } = r, { height: u = void 0 } = r, { width: g = void 0 } = r, { elem_id: p = "" } = r, { elem_classes: v = [] } = r, { variant: w = "solid" } = r, { border_mode: S = "base" } = r, { padding: L = !0 } = r, { type: O = "normal" } = r, { test_id: X = void 0 } = r, { explicit_call: I = !1 } = r, { container: ne = !0 } = r, { visible: re = !0 } = r, { allow_overflow: V = !0 } = r, { scale: F = null } = r, { min_width: M = 0 } = r, R = O === "fieldset" ? "fieldset" : "div"; + return s.$$set = (B) => { + "height" in B && a(0, u = B.height), "width" in B && a(1, g = B.width), "elem_id" in B && a(2, p = B.elem_id), "elem_classes" in B && a(3, v = B.elem_classes), "variant" in B && a(4, w = B.variant), "border_mode" in B && a(5, S = B.border_mode), "padding" in B && a(6, L = B.padding), "type" in B && a(15, O = B.type), "test_id" in B && a(7, X = B.test_id), "explicit_call" in B && a(8, I = B.explicit_call), "container" in B && a(9, ne = B.container), "visible" in B && a(10, re = B.visible), "allow_overflow" in B && a(11, V = B.allow_overflow), "scale" in B && a(12, F = B.scale), "min_width" in B && a(13, M = B.min_width), "$$scope" in B && a(16, o = B.$$scope); + }, [ + u, + g, + p, + v, + w, + S, + L, + X, + I, + ne, + re, + V, + F, + M, + R, + O, + o, + i + ]; +} +class Fu extends wu { + constructor(r) { + super(), zu(this, r, Ru, Nu, Eu, { + height: 0, + width: 1, + elem_id: 2, + elem_classes: 3, + variant: 4, + border_mode: 5, + padding: 6, + type: 15, + test_id: 7, + explicit_call: 8, + container: 9, + visible: 10, + allow_overflow: 11, + scale: 12, + min_width: 13 + }); + } +} +const { + SvelteComponent: Lu, + append: Ea, + attr: wn, + create_component: Iu, + destroy_component: Ou, + detach: qu, + element: Nl, + init: Pu, + insert: Hu, + mount_component: Uu, + safe_not_equal: Gu, + set_data: Vu, + space: ju, + text: Wu, + toggle_class: F0, + transition_in: Yu, + transition_out: Xu +} = window.__gradio__svelte__internal; +function Zu(s) { + let r, a, i, o, u, g; + return i = new /*Icon*/ + s[1]({}), { + c() { + r = Nl("label"), a = Nl("span"), Iu(i.$$.fragment), o = ju(), u = Wu( + /*label*/ + s[0] + ), wn(a, "class", "svelte-9gxdi0"), wn(r, "for", ""), wn(r, "data-testid", "block-label"), wn(r, "class", "svelte-9gxdi0"), F0(r, "hide", !/*show_label*/ + s[2]), F0(r, "sr-only", !/*show_label*/ + s[2]), F0( + r, + "float", + /*float*/ + s[4] + ), F0( + r, + "hide-label", + /*disable*/ + s[3] + ); + }, + m(p, v) { + Hu(p, r, v), Ea(r, a), Uu(i, a, null), Ea(r, o), Ea(r, u), g = !0; + }, + p(p, [v]) { + (!g || v & /*label*/ + 1) && Vu( + u, + /*label*/ + p[0] + ), (!g || v & /*show_label*/ + 4) && F0(r, "hide", !/*show_label*/ + p[2]), (!g || v & /*show_label*/ + 4) && F0(r, "sr-only", !/*show_label*/ + p[2]), (!g || v & /*float*/ + 16) && F0( + r, + "float", + /*float*/ + p[4] + ), (!g || v & /*disable*/ + 8) && F0( + r, + "hide-label", + /*disable*/ + p[3] + ); + }, + i(p) { + g || (Yu(i.$$.fragment, p), g = !0); + }, + o(p) { + Xu(i.$$.fragment, p), g = !1; + }, + d(p) { + p && qu(r), Ou(i); + } + }; +} +function Ku(s, r, a) { + let { label: i = null } = r, { Icon: o } = r, { show_label: u = !0 } = r, { disable: g = !1 } = r, { float: p = !0 } = r; + return s.$$set = (v) => { + "label" in v && a(0, i = v.label), "Icon" in v && a(1, o = v.Icon), "show_label" in v && a(2, u = v.show_label), "disable" in v && a(3, g = v.disable), "float" in v && a(4, p = v.float); + }, [i, o, u, g, p]; +} +class Qu extends Lu { + constructor(r) { + super(), Pu(this, r, Ku, Zu, Gu, { + label: 0, + Icon: 1, + show_label: 2, + disable: 3, + float: 4 + }); + } +} +const { + SvelteComponent: Ju, + append: Ka, + attr: J0, + bubble: $u, + create_component: ec, + destroy_component: tc, + detach: ho, + element: Qa, + init: rc, + insert: fo, + listen: nc, + mount_component: ac, + safe_not_equal: ic, + set_data: lc, + space: sc, + text: oc, + toggle_class: L0, + transition_in: uc, + transition_out: cc +} = window.__gradio__svelte__internal; +function Rl(s) { + let r, a; + return { + c() { + r = Qa("span"), a = oc( + /*label*/ + s[1] + ), J0(r, "class", "svelte-xtz2g8"); + }, + m(i, o) { + fo(i, r, o), Ka(r, a); + }, + p(i, o) { + o & /*label*/ + 2 && lc( + a, + /*label*/ + i[1] + ); + }, + d(i) { + i && ho(r); + } + }; +} +function hc(s) { + let r, a, i, o, u, g, p, v = ( + /*show_label*/ + s[2] && Rl(s) + ); + return o = new /*Icon*/ + s[0]({}), { + c() { + r = Qa("button"), v && v.c(), a = sc(), i = Qa("div"), ec(o.$$.fragment), J0(i, "class", "svelte-xtz2g8"), L0( + i, + "small", + /*size*/ + s[4] === "small" + ), L0( + i, + "large", + /*size*/ + s[4] === "large" + ), J0( + r, + "aria-label", + /*label*/ + s[1] + ), J0( + r, + "title", + /*label*/ + s[1] + ), J0(r, "class", "svelte-xtz2g8"), L0( + r, + "pending", + /*pending*/ + s[3] + ), L0( + r, + "padded", + /*padded*/ + s[5] + ); + }, + m(w, S) { + fo(w, r, S), v && v.m(r, null), Ka(r, a), Ka(r, i), ac(o, i, null), u = !0, g || (p = nc( + r, + "click", + /*click_handler*/ + s[6] + ), g = !0); + }, + p(w, [S]) { + /*show_label*/ + w[2] ? v ? v.p(w, S) : (v = Rl(w), v.c(), v.m(r, a)) : v && (v.d(1), v = null), (!u || S & /*size*/ + 16) && L0( + i, + "small", + /*size*/ + w[4] === "small" + ), (!u || S & /*size*/ + 16) && L0( + i, + "large", + /*size*/ + w[4] === "large" + ), (!u || S & /*label*/ + 2) && J0( + r, + "aria-label", + /*label*/ + w[1] + ), (!u || S & /*label*/ + 2) && J0( + r, + "title", + /*label*/ + w[1] + ), (!u || S & /*pending*/ + 8) && L0( + r, + "pending", + /*pending*/ + w[3] + ), (!u || S & /*padded*/ + 32) && L0( + r, + "padded", + /*padded*/ + w[5] + ); + }, + i(w) { + u || (uc(o.$$.fragment, w), u = !0); + }, + o(w) { + cc(o.$$.fragment, w), u = !1; + }, + d(w) { + w && ho(r), v && v.d(), tc(o), g = !1, p(); + } + }; +} +function fc(s, r, a) { + let { Icon: i } = r, { label: o = "" } = r, { show_label: u = !1 } = r, { pending: g = !1 } = r, { size: p = "small" } = r, { padded: v = !0 } = r; + function w(S) { + $u.call(this, s, S); + } + return s.$$set = (S) => { + "Icon" in S && a(0, i = S.Icon), "label" in S && a(1, o = S.label), "show_label" in S && a(2, u = S.show_label), "pending" in S && a(3, g = S.pending), "size" in S && a(4, p = S.size), "padded" in S && a(5, v = S.padded); + }, [i, o, u, g, p, v, w]; +} +class mc extends Ju { + constructor(r) { + super(), rc(this, r, fc, hc, ic, { + Icon: 0, + label: 1, + show_label: 2, + pending: 3, + size: 4, + padded: 5 + }); + } +} +const { + SvelteComponent: dc, + append: Fl, + attr: Ct, + detach: pc, + init: gc, + insert: vc, + noop: Ba, + safe_not_equal: bc, + svg_element: Da +} = window.__gradio__svelte__internal; +function yc(s) { + let r, a, i; + return { + c() { + r = Da("svg"), a = Da("path"), i = Da("path"), Ct(a, "fill", "currentColor"), Ct(a, "d", "M17.74 30L16 29l4-7h6a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2H6a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h9v2H6a4 4 0 0 1-4-4V8a4 4 0 0 1 4-4h20a4 4 0 0 1 4 4v12a4 4 0 0 1-4 4h-4.84Z"), Ct(i, "fill", "currentColor"), Ct(i, "d", "M8 10h16v2H8zm0 6h10v2H8z"), Ct(r, "xmlns", "http://www.w3.org/2000/svg"), Ct(r, "xmlns:xlink", "http://www.w3.org/1999/xlink"), Ct(r, "aria-hidden", "true"), Ct(r, "role", "img"), Ct(r, "class", "iconify iconify--carbon"), Ct(r, "width", "100%"), Ct(r, "height", "100%"), Ct(r, "preserveAspectRatio", "xMidYMid meet"), Ct(r, "viewBox", "0 0 32 32"); + }, + m(o, u) { + vc(o, r, u), Fl(r, a), Fl(r, i); + }, + p: Ba, + i: Ba, + o: Ba, + d(o) { + o && pc(r); + } + }; +} +class wc extends dc { + constructor(r) { + super(), gc(this, r, null, yc, bc, {}); + } +} +const { + SvelteComponent: kc, + append: _c, + attr: e0, + detach: xc, + init: Sc, + insert: Ac, + noop: Na, + safe_not_equal: Tc, + svg_element: Ll +} = window.__gradio__svelte__internal; +function Mc(s) { + let r, a; + return { + c() { + r = Ll("svg"), a = Ll("polyline"), e0(a, "points", "20 6 9 17 4 12"), e0(r, "xmlns", "http://www.w3.org/2000/svg"), e0(r, "width", "15px"), e0(r, "height", "14px"), e0(r, "viewBox", "2 0 20 20"), e0(r, "fill", "none"), e0(r, "stroke", "currentColor"), e0(r, "stroke-width", "3"), e0(r, "stroke-linecap", "round"), e0(r, "stroke-linejoin", "round"); + }, + m(i, o) { + Ac(i, r, o), _c(r, a); + }, + p: Na, + i: Na, + o: Na, + d(i) { + i && xc(r); + } + }; +} +class zc extends kc { + constructor(r) { + super(), Sc(this, r, null, Mc, Tc, {}); + } +} +const { + SvelteComponent: Cc, + append: Ec, + attr: Ir, + detach: Bc, + init: Dc, + insert: Nc, + noop: Ra, + safe_not_equal: Rc, + svg_element: Il +} = window.__gradio__svelte__internal; +function Fc(s) { + let r, a; + return { + c() { + r = Il("svg"), a = Il("path"), Ir(a, "d", "M23,20a5,5,0,0,0-3.89,1.89L11.8,17.32a4.46,4.46,0,0,0,0-2.64l7.31-4.57A5,5,0,1,0,18,7a4.79,4.79,0,0,0,.2,1.32l-7.31,4.57a5,5,0,1,0,0,6.22l7.31,4.57A4.79,4.79,0,0,0,18,25a5,5,0,1,0,5-5ZM23,4a3,3,0,1,1-3,3A3,3,0,0,1,23,4ZM7,19a3,3,0,1,1,3-3A3,3,0,0,1,7,19Zm16,9a3,3,0,1,1,3-3A3,3,0,0,1,23,28Z"), Ir(a, "fill", "currentColor"), Ir(r, "id", "icon"), Ir(r, "xmlns", "http://www.w3.org/2000/svg"), Ir(r, "viewBox", "0 0 32 32"); + }, + m(i, o) { + Nc(i, r, o), Ec(r, a); + }, + p: Ra, + i: Ra, + o: Ra, + d(i) { + i && Bc(r); + } + }; +} +class Lc extends Cc { + constructor(r) { + super(), Dc(this, r, null, Fc, Rc, {}); + } +} +const { + SvelteComponent: Ic, + append: Ol, + attr: p0, + detach: Oc, + init: qc, + insert: Pc, + noop: Fa, + safe_not_equal: Hc, + svg_element: La +} = window.__gradio__svelte__internal; +function Uc(s) { + let r, a, i; + return { + c() { + r = La("svg"), a = La("path"), i = La("path"), p0(a, "fill", "currentColor"), p0(a, "d", "M28 10v18H10V10h18m0-2H10a2 2 0 0 0-2 2v18a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2V10a2 2 0 0 0-2-2Z"), p0(i, "fill", "currentColor"), p0(i, "d", "M4 18H2V4a2 2 0 0 1 2-2h14v2H4Z"), p0(r, "xmlns", "http://www.w3.org/2000/svg"), p0(r, "width", "15px"), p0(r, "height", "14px"), p0(r, "viewBox", "0 0 33 33"), p0(r, "color", "currentColor"); + }, + m(o, u) { + Pc(o, r, u), Ol(r, a), Ol(r, i); + }, + p: Fa, + i: Fa, + o: Fa, + d(o) { + o && Oc(r); + } + }; +} +class Gc extends Ic { + constructor(r) { + super(), qc(this, r, null, Uc, Hc, {}); + } +} +const { + SvelteComponent: Vc, + append: ql, + attr: ct, + detach: jc, + init: Wc, + insert: Yc, + noop: Pl, + safe_not_equal: Xc, + svg_element: Ia +} = window.__gradio__svelte__internal; +function Zc(s) { + let r, a, i, o; + return { + c() { + r = Ia("svg"), a = Ia("path"), i = Ia("path"), ct(a, "stroke", "currentColor"), ct(a, "stroke-width", "1.5"), ct(a, "stroke-linecap", "round"), ct(a, "d", "M16.472 3.5H4.1a.6.6 0 0 0-.6.6v9.8a.6.6 0 0 0 .6.6h2.768a2 2 0 0 1 1.715.971l2.71 4.517a1.631 1.631 0 0 0 2.961-1.308l-1.022-3.408a.6.6 0 0 1 .574-.772h4.575a2 2 0 0 0 1.93-2.526l-1.91-7A2 2 0 0 0 16.473 3.5Z"), ct(i, "stroke", "currentColor"), ct(i, "stroke-width", "1.5"), ct(i, "stroke-linecap", "round"), ct(i, "stroke-linejoin", "round"), ct(i, "d", "M7 14.5v-11"), ct(r, "xmlns", "http://www.w3.org/2000/svg"), ct(r, "width", "15px"), ct(r, "height", "15px"), ct(r, "viewBox", "0 0 24 24"), ct(r, "fill", o = /*actioned*/ + s[0] ? "currentColor" : "none"), ct(r, "stroke-width", "1.5"), ct(r, "color", "currentColor"); + }, + m(u, g) { + Yc(u, r, g), ql(r, a), ql(r, i); + }, + p(u, [g]) { + g & /*actioned*/ + 1 && o !== (o = /*actioned*/ + u[0] ? "currentColor" : "none") && ct(r, "fill", o); + }, + i: Pl, + o: Pl, + d(u) { + u && jc(r); + } + }; +} +function Kc(s, r, a) { + let { actioned: i } = r; + return s.$$set = (o) => { + "actioned" in o && a(0, i = o.actioned); + }, [i]; +} +class Qc extends Vc { + constructor(r) { + super(), Wc(this, r, Kc, Zc, Xc, { actioned: 0 }); + } +} +const { + SvelteComponent: Jc, + append: Hl, + attr: ht, + detach: $c, + init: e4, + insert: t4, + noop: Ul, + safe_not_equal: r4, + svg_element: Oa +} = window.__gradio__svelte__internal; +function n4(s) { + let r, a, i, o; + return { + c() { + r = Oa("svg"), a = Oa("path"), i = Oa("path"), ht(a, "stroke", "currentColor"), ht(a, "stroke-width", "1.5"), ht(a, "stroke-linecap", "round"), ht(a, "d", "M16.472 20H4.1a.6.6 0 0 1-.6-.6V9.6a.6.6 0 0 1 .6-.6h2.768a2 2 0 0 0 1.715-.971l2.71-4.517a1.631 1.631 0 0 1 2.961 1.308l-1.022 3.408a.6.6 0 0 0 .574.772h4.575a2 2 0 0 1 1.93 2.526l-1.91 7A2 2 0 0 1 16.473 20Z"), ht(i, "stroke", "currentColor"), ht(i, "stroke-width", "1.5"), ht(i, "stroke-linecap", "round"), ht(i, "stroke-linejoin", "round"), ht(i, "d", "M7 20V9"), ht(r, "xmlns", "http://www.w3.org/2000/svg"), ht(r, "width", "15px"), ht(r, "height", "15px"), ht(r, "viewBox", "0 0 24 24"), ht(r, "fill", o = /*actioned*/ + s[0] ? "currentColor" : "none"), ht(r, "stroke-width", "1.5"), ht(r, "color", "currentColor"); + }, + m(u, g) { + t4(u, r, g), Hl(r, a), Hl(r, i); + }, + p(u, [g]) { + g & /*actioned*/ + 1 && o !== (o = /*actioned*/ + u[0] ? "currentColor" : "none") && ht(r, "fill", o); + }, + i: Ul, + o: Ul, + d(u) { + u && $c(r); + } + }; +} +function a4(s, r, a) { + let { actioned: i } = r; + return s.$$set = (o) => { + "actioned" in o && a(0, i = o.actioned); + }, [i]; +} +class i4 extends Jc { + constructor(r) { + super(), e4(this, r, a4, n4, r4, { actioned: 0 }); + } +} +const { + SvelteComponent: l4, + create_component: s4, + destroy_component: o4, + init: u4, + mount_component: c4, + safe_not_equal: h4, + transition_in: f4, + transition_out: m4 +} = window.__gradio__svelte__internal, { createEventDispatcher: d4 } = window.__gradio__svelte__internal; +function p4(s) { + let r, a; + return r = new mc({ + props: { + Icon: Lc, + label: ( + /*i18n*/ + s[2]("common.share") + ), + pending: ( + /*pending*/ + s[3] + ) + } + }), r.$on( + "click", + /*click_handler*/ + s[5] + ), { + c() { + s4(r.$$.fragment); + }, + m(i, o) { + c4(r, i, o), a = !0; + }, + p(i, [o]) { + const u = {}; + o & /*i18n*/ + 4 && (u.label = /*i18n*/ + i[2]("common.share")), o & /*pending*/ + 8 && (u.pending = /*pending*/ + i[3]), r.$set(u); + }, + i(i) { + a || (f4(r.$$.fragment, i), a = !0); + }, + o(i) { + m4(r.$$.fragment, i), a = !1; + }, + d(i) { + o4(r, i); + } + }; +} +function g4(s, r, a) { + const i = d4(); + let { formatter: o } = r, { value: u } = r, { i18n: g } = r, p = !1; + const v = async () => { + try { + a(3, p = !0); + const w = await o(u); + i("share", { description: w }); + } catch (w) { + console.error(w); + let S = w instanceof Cn ? w.message : "Share failed."; + i("error", S); + } finally { + a(3, p = !1); + } + }; + return s.$$set = (w) => { + "formatter" in w && a(0, o = w.formatter), "value" in w && a(1, u = w.value), "i18n" in w && a(2, g = w.i18n); + }, [o, u, g, p, i, v]; +} +class v4 extends l4 { + constructor(r) { + super(), u4(this, r, g4, p4, h4, { formatter: 0, value: 1, i18n: 2 }); + } +} +/*! @license DOMPurify 3.0.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.0.6/LICENSE */ +const { + entries: mo, + setPrototypeOf: Gl, + isFrozen: b4, + getPrototypeOf: y4, + getOwnPropertyDescriptor: po +} = Object; +let { + freeze: kt, + seal: Yt, + create: go +} = Object, { + apply: Ja, + construct: $a +} = typeof Reflect < "u" && Reflect; +kt || (kt = function(r) { + return r; +}); +Yt || (Yt = function(r) { + return r; +}); +Ja || (Ja = function(r, a, i) { + return r.apply(a, i); +}); +$a || ($a = function(r, a) { + return new r(...a); +}); +const kn = Ht(Array.prototype.forEach), Vl = Ht(Array.prototype.pop), Or = Ht(Array.prototype.push), En = Ht(String.prototype.toLowerCase), qa = Ht(String.prototype.toString), w4 = Ht(String.prototype.match), qr = Ht(String.prototype.replace), k4 = Ht(String.prototype.indexOf), _4 = Ht(String.prototype.trim), Et = Ht(RegExp.prototype.test), Pr = x4(TypeError); +function Ht(s) { + return function(r) { + for (var a = arguments.length, i = new Array(a > 1 ? a - 1 : 0), o = 1; o < a; o++) + i[o - 1] = arguments[o]; + return Ja(s, r, i); + }; +} +function x4(s) { + return function() { + for (var r = arguments.length, a = new Array(r), i = 0; i < r; i++) + a[i] = arguments[i]; + return $a(s, a); + }; +} +function Se(s, r) { + let a = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : En; + Gl && Gl(s, null); + let i = r.length; + for (; i--; ) { + let o = r[i]; + if (typeof o == "string") { + const u = a(o); + u !== o && (b4(r) || (r[i] = u), o = u); + } + s[o] = !0; + } + return s; +} +function dr(s) { + const r = go(null); + for (const [a, i] of mo(s)) + po(s, a) !== void 0 && (r[a] = i); + return r; +} +function _n(s, r) { + for (; s !== null; ) { + const i = po(s, r); + if (i) { + if (i.get) + return Ht(i.get); + if (typeof i.value == "function") + return Ht(i.value); + } + s = y4(s); + } + function a(i) { + return console.warn("fallback value for", i), null; + } + return a; +} +const jl = kt(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "section", "select", "shadow", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]), Pa = kt(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), Ha = kt(["feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence"]), S4 = kt(["animate", "color-profile", "cursor", "discard", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "foreignobject", "hatch", "hatchpath", "mesh", "meshgradient", "meshpatch", "meshrow", "missing-glyph", "script", "set", "solidcolor", "unknown", "use"]), Ua = kt(["math", "menclose", "merror", "mfenced", "mfrac", "mglyph", "mi", "mlabeledtr", "mmultiscripts", "mn", "mo", "mover", "mpadded", "mphantom", "mroot", "mrow", "ms", "mspace", "msqrt", "mstyle", "msub", "msup", "msubsup", "mtable", "mtd", "mtext", "mtr", "munder", "munderover", "mprescripts"]), A4 = kt(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), Wl = kt(["#text"]), Yl = kt(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "pattern", "placeholder", "playsinline", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "xmlns", "slot"]), Ga = kt(["accent-height", "accumulate", "additive", "alignment-baseline", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]), Xl = kt(["accent", "accentunder", "align", "bevelled", "close", "columnsalign", "columnlines", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lspace", "lquote", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]), xn = kt(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), T4 = Yt(/\{\{[\w\W]*|[\w\W]*\}\}/gm), M4 = Yt(/<%[\w\W]*|[\w\W]*%>/gm), z4 = Yt(/\${[\w\W]*}/gm), C4 = Yt(/^data-[\-\w.\u00B7-\uFFFF]/), E4 = Yt(/^aria-[\-\w]+$/), vo = Yt( + /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i + // eslint-disable-line no-useless-escape +), B4 = Yt(/^(?:\w+script|data):/i), D4 = Yt( + /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g + // eslint-disable-line no-control-regex +), bo = Yt(/^html$/i); +var Zl = /* @__PURE__ */ Object.freeze({ + __proto__: null, + MUSTACHE_EXPR: T4, + ERB_EXPR: M4, + TMPLIT_EXPR: z4, + DATA_ATTR: C4, + ARIA_ATTR: E4, + IS_ALLOWED_URI: vo, + IS_SCRIPT_OR_DATA: B4, + ATTR_WHITESPACE: D4, + DOCTYPE_NAME: bo +}); +const N4 = function() { + return typeof window > "u" ? null : window; +}, R4 = function(r, a) { + if (typeof r != "object" || typeof r.createPolicy != "function") + return null; + let i = null; + const o = "data-tt-policy-suffix"; + a && a.hasAttribute(o) && (i = a.getAttribute(o)); + const u = "dompurify" + (i ? "#" + i : ""); + try { + return r.createPolicy(u, { + createHTML(g) { + return g; + }, + createScriptURL(g) { + return g; + } + }); + } catch { + return console.warn("TrustedTypes policy " + u + " could not be created."), null; + } +}; +function yo() { + let s = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : N4(); + const r = (fe) => yo(fe); + if (r.version = "3.0.6", r.removed = [], !s || !s.document || s.document.nodeType !== 9) + return r.isSupported = !1, r; + let { + document: a + } = s; + const i = a, o = i.currentScript, { + DocumentFragment: u, + HTMLTemplateElement: g, + Node: p, + Element: v, + NodeFilter: w, + NamedNodeMap: S = s.NamedNodeMap || s.MozNamedAttrMap, + HTMLFormElement: L, + DOMParser: O, + trustedTypes: X + } = s, I = v.prototype, ne = _n(I, "cloneNode"), re = _n(I, "nextSibling"), V = _n(I, "childNodes"), F = _n(I, "parentNode"); + if (typeof g == "function") { + const fe = a.createElement("template"); + fe.content && fe.content.ownerDocument && (a = fe.content.ownerDocument); + } + let M, R = ""; + const { + implementation: B, + createNodeIterator: H, + createDocumentFragment: W, + getElementsByTagName: Z + } = a, { + importNode: G + } = i; + let ce = {}; + r.isSupported = typeof mo == "function" && typeof F == "function" && B && B.createHTMLDocument !== void 0; + const { + MUSTACHE_EXPR: ve, + ERB_EXPR: Ee, + TMPLIT_EXPR: xe, + DATA_ATTR: Ne, + ARIA_ATTR: rt, + IS_SCRIPT_OR_DATA: vt, + ATTR_WHITESPACE: At + } = Zl; + let { + IS_ALLOWED_URI: Oe + } = Zl, Ae = null; + const J = Se({}, [...jl, ...Pa, ...Ha, ...Ua, ...Wl]); + let Q = null; + const Qe = Se({}, [...Yl, ...Ga, ...Xl, ...xn]); + let ae = Object.seal(go(null, { + tagNameCheck: { + writable: !0, + configurable: !1, + enumerable: !0, + value: null + }, + attributeNameCheck: { + writable: !0, + configurable: !1, + enumerable: !0, + value: null + }, + allowCustomizedBuiltInElements: { + writable: !0, + configurable: !1, + enumerable: !0, + value: !1 + } + })), Je = null, te = null, Ge = !0, $e = !0, Bt = !1, G0 = !0, Dt = !1, _t = !1, V0 = !1, u0 = !1, b0 = !1, rr = !1, j0 = !1, Vr = !0, y0 = !1; + const Nt = "user-content-"; + let w0 = !0, k0 = !1, _0 = {}, Xt = null; + const nr = Se({}, ["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"]); + let jr = null; + const Wr = Se({}, ["audio", "video", "img", "source", "image", "track"]); + let ar = null; + const Ar = Se({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), W0 = "http://www.w3.org/1998/Math/MathML", ir = "http://www.w3.org/2000/svg", Tt = "http://www.w3.org/1999/xhtml"; + let x0 = Tt, lr = !1, Pe = null; + const ee = Se({}, [W0, ir, Tt], qa); + let ft = null; + const Yr = ["application/xhtml+xml", "text/html"], Xr = "text/html"; + let nt = null, Rt = null; + const Tr = a.createElement("form"), Zr = function(z) { + return z instanceof RegExp || z instanceof Function; + }, Mr = function() { + let z = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + if (!(Rt && Rt === z)) { + if ((!z || typeof z != "object") && (z = {}), z = dr(z), ft = // eslint-disable-next-line unicorn/prefer-includes + Yr.indexOf(z.PARSER_MEDIA_TYPE) === -1 ? ft = Xr : ft = z.PARSER_MEDIA_TYPE, nt = ft === "application/xhtml+xml" ? qa : En, Ae = "ALLOWED_TAGS" in z ? Se({}, z.ALLOWED_TAGS, nt) : J, Q = "ALLOWED_ATTR" in z ? Se({}, z.ALLOWED_ATTR, nt) : Qe, Pe = "ALLOWED_NAMESPACES" in z ? Se({}, z.ALLOWED_NAMESPACES, qa) : ee, ar = "ADD_URI_SAFE_ATTR" in z ? Se( + dr(Ar), + // eslint-disable-line indent + z.ADD_URI_SAFE_ATTR, + // eslint-disable-line indent + nt + // eslint-disable-line indent + ) : Ar, jr = "ADD_DATA_URI_TAGS" in z ? Se( + dr(Wr), + // eslint-disable-line indent + z.ADD_DATA_URI_TAGS, + // eslint-disable-line indent + nt + // eslint-disable-line indent + ) : Wr, Xt = "FORBID_CONTENTS" in z ? Se({}, z.FORBID_CONTENTS, nt) : nr, Je = "FORBID_TAGS" in z ? Se({}, z.FORBID_TAGS, nt) : {}, te = "FORBID_ATTR" in z ? Se({}, z.FORBID_ATTR, nt) : {}, _0 = "USE_PROFILES" in z ? z.USE_PROFILES : !1, Ge = z.ALLOW_ARIA_ATTR !== !1, $e = z.ALLOW_DATA_ATTR !== !1, Bt = z.ALLOW_UNKNOWN_PROTOCOLS || !1, G0 = z.ALLOW_SELF_CLOSE_IN_ATTR !== !1, Dt = z.SAFE_FOR_TEMPLATES || !1, _t = z.WHOLE_DOCUMENT || !1, b0 = z.RETURN_DOM || !1, rr = z.RETURN_DOM_FRAGMENT || !1, j0 = z.RETURN_TRUSTED_TYPE || !1, u0 = z.FORCE_BODY || !1, Vr = z.SANITIZE_DOM !== !1, y0 = z.SANITIZE_NAMED_PROPS || !1, w0 = z.KEEP_CONTENT !== !1, k0 = z.IN_PLACE || !1, Oe = z.ALLOWED_URI_REGEXP || vo, x0 = z.NAMESPACE || Tt, ae = z.CUSTOM_ELEMENT_HANDLING || {}, z.CUSTOM_ELEMENT_HANDLING && Zr(z.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (ae.tagNameCheck = z.CUSTOM_ELEMENT_HANDLING.tagNameCheck), z.CUSTOM_ELEMENT_HANDLING && Zr(z.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (ae.attributeNameCheck = z.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), z.CUSTOM_ELEMENT_HANDLING && typeof z.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (ae.allowCustomizedBuiltInElements = z.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), Dt && ($e = !1), rr && (b0 = !0), _0 && (Ae = Se({}, [...Wl]), Q = [], _0.html === !0 && (Se(Ae, jl), Se(Q, Yl)), _0.svg === !0 && (Se(Ae, Pa), Se(Q, Ga), Se(Q, xn)), _0.svgFilters === !0 && (Se(Ae, Ha), Se(Q, Ga), Se(Q, xn)), _0.mathMl === !0 && (Se(Ae, Ua), Se(Q, Xl), Se(Q, xn))), z.ADD_TAGS && (Ae === J && (Ae = dr(Ae)), Se(Ae, z.ADD_TAGS, nt)), z.ADD_ATTR && (Q === Qe && (Q = dr(Q)), Se(Q, z.ADD_ATTR, nt)), z.ADD_URI_SAFE_ATTR && Se(ar, z.ADD_URI_SAFE_ATTR, nt), z.FORBID_CONTENTS && (Xt === nr && (Xt = dr(Xt)), Se(Xt, z.FORBID_CONTENTS, nt)), w0 && (Ae["#text"] = !0), _t && Se(Ae, ["html", "head", "body"]), Ae.table && (Se(Ae, ["tbody"]), delete Je.tbody), z.TRUSTED_TYPES_POLICY) { + if (typeof z.TRUSTED_TYPES_POLICY.createHTML != "function") + throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.'); + if (typeof z.TRUSTED_TYPES_POLICY.createScriptURL != "function") + throw Pr('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.'); + M = z.TRUSTED_TYPES_POLICY, R = M.createHTML(""); + } else + M === void 0 && (M = R4(X, o)), M !== null && typeof R == "string" && (R = M.createHTML("")); + kt && kt(z), Rt = z; + } + }, bt = Se({}, ["mi", "mo", "mn", "ms", "mtext"]), Ft = Se({}, ["foreignobject", "desc", "title", "annotation-xml"]), Zt = Se({}, ["title", "style", "font", "a", "script"]), S0 = Se({}, Pa); + Se(S0, Ha), Se(S0, S4); + const sr = Se({}, Ua); + Se(sr, A4); + const Vn = function(z) { + let Y = F(z); + (!Y || !Y.tagName) && (Y = { + namespaceURI: x0, + tagName: "template" + }); + const le = En(z.tagName), Re = En(Y.tagName); + return Pe[z.namespaceURI] ? z.namespaceURI === ir ? Y.namespaceURI === Tt ? le === "svg" : Y.namespaceURI === W0 ? le === "svg" && (Re === "annotation-xml" || bt[Re]) : !!S0[le] : z.namespaceURI === W0 ? Y.namespaceURI === Tt ? le === "math" : Y.namespaceURI === ir ? le === "math" && Ft[Re] : !!sr[le] : z.namespaceURI === Tt ? Y.namespaceURI === ir && !Ft[Re] || Y.namespaceURI === W0 && !bt[Re] ? !1 : !sr[le] && (Zt[le] || !S0[le]) : !!(ft === "application/xhtml+xml" && Pe[z.namespaceURI]) : !1; + }, c0 = function(z) { + Or(r.removed, { + element: z + }); + try { + z.parentNode.removeChild(z); + } catch { + z.remove(); + } + }, zr = function(z, Y) { + try { + Or(r.removed, { + attribute: Y.getAttributeNode(z), + from: Y + }); + } catch { + Or(r.removed, { + attribute: null, + from: Y + }); + } + if (Y.removeAttribute(z), z === "is" && !Q[z]) + if (b0 || rr) + try { + c0(Y); + } catch { + } + else + try { + Y.setAttribute(z, ""); + } catch { + } + }, Y0 = function(z) { + let Y = null, le = null; + if (u0) + z = "" + z; + else { + const je = w4(z, /^[\r\n\t ]+/); + le = je && je[0]; + } + ft === "application/xhtml+xml" && x0 === Tt && (z = '' + z + ""); + const Re = M ? M.createHTML(z) : z; + if (x0 === Tt) + try { + Y = new O().parseFromString(Re, ft); + } catch { + } + if (!Y || !Y.documentElement) { + Y = B.createDocument(x0, "template", null); + try { + Y.documentElement.innerHTML = lr ? R : Re; + } catch { + } + } + const A = Y.body || Y.documentElement; + return z && le && A.insertBefore(a.createTextNode(le), A.childNodes[0] || null), x0 === Tt ? Z.call(Y, _t ? "html" : "body")[0] : _t ? Y.documentElement : A; + }, Ve = function(z) { + return H.call( + z.ownerDocument || z, + z, + // eslint-disable-next-line no-bitwise + w.SHOW_ELEMENT | w.SHOW_COMMENT | w.SHOW_TEXT, + null + ); + }, h = function(z) { + return z instanceof L && (typeof z.nodeName != "string" || typeof z.textContent != "string" || typeof z.removeChild != "function" || !(z.attributes instanceof S) || typeof z.removeAttribute != "function" || typeof z.setAttribute != "function" || typeof z.namespaceURI != "string" || typeof z.insertBefore != "function" || typeof z.hasChildNodes != "function"); + }, d = function(z) { + return typeof p == "function" && z instanceof p; + }, j = function(z, Y, le) { + ce[z] && kn(ce[z], (Re) => { + Re.call(r, Y, le, Rt); + }); + }, y = function(z) { + let Y = null; + if (j("beforeSanitizeElements", z, null), h(z)) + return c0(z), !0; + const le = nt(z.nodeName); + if (j("uponSanitizeElement", z, { + tagName: le, + allowedTags: Ae + }), z.hasChildNodes() && !d(z.firstElementChild) && Et(/<[/\w]/g, z.innerHTML) && Et(/<[/\w]/g, z.textContent)) + return c0(z), !0; + if (!Ae[le] || Je[le]) { + if (!Je[le] && He(le) && (ae.tagNameCheck instanceof RegExp && Et(ae.tagNameCheck, le) || ae.tagNameCheck instanceof Function && ae.tagNameCheck(le))) + return !1; + if (w0 && !Xt[le]) { + const Re = F(z) || z.parentNode, A = V(z) || z.childNodes; + if (A && Re) { + const je = A.length; + for (let E = je - 1; E >= 0; --E) + Re.insertBefore(ne(A[E], !0), re(z)); + } + } + return c0(z), !0; + } + return z instanceof v && !Vn(z) || (le === "noscript" || le === "noembed" || le === "noframes") && Et(/<\/no(script|embed|frames)/i, z.innerHTML) ? (c0(z), !0) : (Dt && z.nodeType === 3 && (Y = z.textContent, kn([ve, Ee, xe], (Re) => { + Y = qr(Y, Re, " "); + }), z.textContent !== Y && (Or(r.removed, { + element: z.cloneNode() + }), z.textContent = Y)), j("afterSanitizeElements", z, null), !1); + }, T = function(z, Y, le) { + if (Vr && (Y === "id" || Y === "name") && (le in a || le in Tr)) + return !1; + if (!($e && !te[Y] && Et(Ne, Y))) { + if (!(Ge && Et(rt, Y))) { + if (!Q[Y] || te[Y]) { + if ( + // First condition does a very basic check if a) it's basically a valid custom element tagname AND + // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck + // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck + !(He(z) && (ae.tagNameCheck instanceof RegExp && Et(ae.tagNameCheck, z) || ae.tagNameCheck instanceof Function && ae.tagNameCheck(z)) && (ae.attributeNameCheck instanceof RegExp && Et(ae.attributeNameCheck, Y) || ae.attributeNameCheck instanceof Function && ae.attributeNameCheck(Y)) || // Alternative, second condition checks if it's an `is`-attribute, AND + // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck + Y === "is" && ae.allowCustomizedBuiltInElements && (ae.tagNameCheck instanceof RegExp && Et(ae.tagNameCheck, le) || ae.tagNameCheck instanceof Function && ae.tagNameCheck(le))) + ) + return !1; + } else if (!ar[Y]) { + if (!Et(Oe, qr(le, At, ""))) { + if (!((Y === "src" || Y === "xlink:href" || Y === "href") && z !== "script" && k4(le, "data:") === 0 && jr[z])) { + if (!(Bt && !Et(vt, qr(le, At, "")))) { + if (le) + return !1; + } + } + } + } + } + } + return !0; + }, He = function(z) { + return z.indexOf("-") > 0; + }, oe = function(z) { + j("beforeSanitizeAttributes", z, null); + const { + attributes: Y + } = z; + if (!Y) + return; + const le = { + attrName: "", + attrValue: "", + keepAttr: !0, + allowedAttributes: Q + }; + let Re = Y.length; + for (; Re--; ) { + const A = Y[Re], { + name: je, + namespaceURI: E, + value: Kt + } = A, A0 = nt(je); + let st = je === "value" ? Kt : _4(Kt); + if (le.attrName = A0, le.attrValue = st, le.keepAttr = !0, le.forceKeepAttr = void 0, j("uponSanitizeAttribute", z, le), st = le.attrValue, le.forceKeepAttr || (zr(je, z), !le.keepAttr)) + continue; + if (!G0 && Et(/\/>/i, st)) { + zr(je, z); + continue; + } + Dt && kn([ve, Ee, xe], (Er) => { + st = qr(st, Er, " "); + }); + const Cr = nt(z.nodeName); + if (T(Cr, A0, st)) { + if (y0 && (A0 === "id" || A0 === "name") && (zr(je, z), st = Nt + st), M && typeof X == "object" && typeof X.getAttributeType == "function" && !E) + switch (X.getAttributeType(Cr, A0)) { + case "TrustedHTML": { + st = M.createHTML(st); + break; + } + case "TrustedScriptURL": { + st = M.createScriptURL(st); + break; + } + } + try { + E ? z.setAttributeNS(E, je, st) : z.setAttribute(je, st), Vl(r.removed); + } catch { + } + } + } + j("afterSanitizeAttributes", z, null); + }, ot = function fe(z) { + let Y = null; + const le = Ve(z); + for (j("beforeSanitizeShadowDOM", z, null); Y = le.nextNode(); ) + j("uponSanitizeShadowNode", Y, null), !y(Y) && (Y.content instanceof u && fe(Y.content), oe(Y)); + j("afterSanitizeShadowDOM", z, null); + }; + return r.sanitize = function(fe) { + let z = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, Y = null, le = null, Re = null, A = null; + if (lr = !fe, lr && (fe = ""), typeof fe != "string" && !d(fe)) + if (typeof fe.toString == "function") { + if (fe = fe.toString(), typeof fe != "string") + throw Pr("dirty is not a string, aborting"); + } else + throw Pr("toString is not a function"); + if (!r.isSupported) + return fe; + if (V0 || Mr(z), r.removed = [], typeof fe == "string" && (k0 = !1), k0) { + if (fe.nodeName) { + const Kt = nt(fe.nodeName); + if (!Ae[Kt] || Je[Kt]) + throw Pr("root node is forbidden and cannot be sanitized in-place"); + } + } else if (fe instanceof p) + Y = Y0(""), le = Y.ownerDocument.importNode(fe, !0), le.nodeType === 1 && le.nodeName === "BODY" || le.nodeName === "HTML" ? Y = le : Y.appendChild(le); + else { + if (!b0 && !Dt && !_t && // eslint-disable-next-line unicorn/prefer-includes + fe.indexOf("<") === -1) + return M && j0 ? M.createHTML(fe) : fe; + if (Y = Y0(fe), !Y) + return b0 ? null : j0 ? R : ""; + } + Y && u0 && c0(Y.firstChild); + const je = Ve(k0 ? fe : Y); + for (; Re = je.nextNode(); ) + y(Re) || (Re.content instanceof u && ot(Re.content), oe(Re)); + if (k0) + return fe; + if (b0) { + if (rr) + for (A = W.call(Y.ownerDocument); Y.firstChild; ) + A.appendChild(Y.firstChild); + else + A = Y; + return (Q.shadowroot || Q.shadowrootmode) && (A = G.call(i, A, !0)), A; + } + let E = _t ? Y.outerHTML : Y.innerHTML; + return _t && Ae["!doctype"] && Y.ownerDocument && Y.ownerDocument.doctype && Y.ownerDocument.doctype.name && Et(bo, Y.ownerDocument.doctype.name) && (E = " +` + E), Dt && kn([ve, Ee, xe], (Kt) => { + E = qr(E, Kt, " "); + }), M && j0 ? M.createHTML(E) : E; + }, r.setConfig = function() { + let fe = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}; + Mr(fe), V0 = !0; + }, r.clearConfig = function() { + Rt = null, V0 = !1; + }, r.isValidAttribute = function(fe, z, Y) { + Rt || Mr({}); + const le = nt(fe), Re = nt(z); + return T(le, Re, Y); + }, r.addHook = function(fe, z) { + typeof z == "function" && (ce[fe] = ce[fe] || [], Or(ce[fe], z)); + }, r.removeHook = function(fe) { + if (ce[fe]) + return Vl(ce[fe]); + }, r.removeHooks = function(fe) { + ce[fe] && (ce[fe] = []); + }, r.removeAllHooks = function() { + ce = {}; + }, r; +} +var Kl = yo(), Nn = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}; +function wo(s) { + return s && s.__esModule && Object.prototype.hasOwnProperty.call(s, "default") ? s.default : s; +} +var ko = { exports: {} }, Va = { exports: {} }, Ql; +function F4() { + return Ql || (Ql = 1, function(s, r) { + (function(i, o) { + s.exports = o(); + })(typeof self < "u" ? self : Nn, function() { + return ( + /******/ + function() { + var a = {}; + (function() { + a.d = function(f, e) { + for (var t in e) + a.o(e, t) && !a.o(f, t) && Object.defineProperty(f, t, { enumerable: !0, get: e[t] }); + }; + })(), function() { + a.o = function(f, e) { + return Object.prototype.hasOwnProperty.call(f, e); + }; + }(); + var i = {}; + a.d(i, { + default: function() { + return ( + /* binding */ + uu + ); + } + }); + var o = ( + // Error start position based on passed-in Token or ParseNode. + // Length of affected text based on passed-in Token or ParseNode. + // The underlying error message without any context added. + function f(e, t) { + this.name = void 0, this.position = void 0, this.length = void 0, this.rawMessage = void 0; + var n = "KaTeX parse error: " + e, l, c, m = t && t.loc; + if (m && m.start <= m.end) { + var b = m.lexer.input; + l = m.start, c = m.end, l === b.length ? n += " at end of input: " : n += " at position " + (l + 1) + ": "; + var k = b.slice(l, c).replace(/[^]/g, "$&̲"), x; + l > 15 ? x = "…" + b.slice(l - 15, l) : x = b.slice(0, l); + var C; + c + 15 < b.length ? C = b.slice(c, c + 15) + "…" : C = b.slice(c), n += x + k + C; + } + var D = new Error(n); + return D.name = "ParseError", D.__proto__ = f.prototype, D.position = l, l != null && c != null && (D.length = c - l), D.rawMessage = e, D; + } + ); + o.prototype.__proto__ = Error.prototype; + var u = o, g = function(e, t) { + return e.indexOf(t) !== -1; + }, p = function(e, t) { + return e === void 0 ? t : e; + }, v = /([A-Z])/g, w = function(e) { + return e.replace(v, "-$1").toLowerCase(); + }, S = { + "&": "&", + ">": ">", + "<": "<", + '"': """, + "'": "'" + }, L = /[&><"']/g; + function O(f) { + return String(f).replace(L, function(e) { + return S[e]; + }); + } + var X = function f(e) { + return e.type === "ordgroup" || e.type === "color" ? e.body.length === 1 ? f(e.body[0]) : e : e.type === "font" ? f(e.body) : e; + }, I = function(e) { + var t = X(e); + return t.type === "mathord" || t.type === "textord" || t.type === "atom"; + }, ne = function(e) { + if (!e) + throw new Error("Expected non-null, but got " + String(e)); + return e; + }, re = function(e) { + var t = /^\s*([^\\/#]*?)(?::|�*58|�*3a)/i.exec(e); + return t != null ? t[1] : "_relative"; + }, V = { + contains: g, + deflt: p, + escape: O, + hyphenate: w, + getBaseElem: X, + isCharacterBox: I, + protocolFromUrl: re + }, F = { + displayMode: { + type: "boolean", + description: "Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.", + cli: "-d, --display-mode" + }, + output: { + type: { + enum: ["htmlAndMathml", "html", "mathml"] + }, + description: "Determines the markup language of the output.", + cli: "-F, --format " + }, + leqno: { + type: "boolean", + description: "Render display math in leqno style (left-justified tags)." + }, + fleqn: { + type: "boolean", + description: "Render display math flush left." + }, + throwOnError: { + type: "boolean", + default: !0, + cli: "-t, --no-throw-on-error", + cliDescription: "Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error." + }, + errorColor: { + type: "string", + default: "#cc0000", + cli: "-c, --error-color ", + cliDescription: "A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.", + cliProcessor: function(e) { + return "#" + e; + } + }, + macros: { + type: "object", + cli: "-m, --macro ", + cliDescription: "Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).", + cliDefault: [], + cliProcessor: function(e, t) { + return t.push(e), t; + } + }, + minRuleThickness: { + type: "number", + description: "Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.", + processor: function(e) { + return Math.max(0, e); + }, + cli: "--min-rule-thickness ", + cliProcessor: parseFloat + }, + colorIsTextColor: { + type: "boolean", + description: "Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.", + cli: "-b, --color-is-text-color" + }, + strict: { + type: [{ + enum: ["warn", "ignore", "error"] + }, "boolean", "function"], + description: "Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.", + cli: "-S, --strict", + cliDefault: !1 + }, + trust: { + type: ["boolean", "function"], + description: "Trust the input, enabling all HTML features such as \\url.", + cli: "-T, --trust" + }, + maxSize: { + type: "number", + default: 1 / 0, + description: "If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large", + processor: function(e) { + return Math.max(0, e); + }, + cli: "-s, --max-size ", + cliProcessor: parseInt + }, + maxExpand: { + type: "number", + default: 1e3, + description: "Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.", + processor: function(e) { + return Math.max(0, e); + }, + cli: "-e, --max-expand ", + cliProcessor: function(e) { + return e === "Infinity" ? 1 / 0 : parseInt(e); + } + }, + globalGroup: { + type: "boolean", + cli: !1 + } + }; + function M(f) { + if (f.default) + return f.default; + var e = f.type, t = Array.isArray(e) ? e[0] : e; + if (typeof t != "string") + return t.enum[0]; + switch (t) { + case "boolean": + return !1; + case "string": + return ""; + case "number": + return 0; + case "object": + return {}; + } + } + var R = /* @__PURE__ */ function() { + function f(t) { + this.displayMode = void 0, this.output = void 0, this.leqno = void 0, this.fleqn = void 0, this.throwOnError = void 0, this.errorColor = void 0, this.macros = void 0, this.minRuleThickness = void 0, this.colorIsTextColor = void 0, this.strict = void 0, this.trust = void 0, this.maxSize = void 0, this.maxExpand = void 0, this.globalGroup = void 0, t = t || {}; + for (var n in F) + if (F.hasOwnProperty(n)) { + var l = F[n]; + this[n] = t[n] !== void 0 ? l.processor ? l.processor(t[n]) : t[n] : M(l); + } + } + var e = f.prototype; + return e.reportNonstrict = function(n, l, c) { + var m = this.strict; + if (typeof m == "function" && (m = m(n, l, c)), !(!m || m === "ignore")) { + if (m === !0 || m === "error") + throw new u("LaTeX-incompatible input and strict mode is set to 'error': " + (l + " [" + n + "]"), c); + m === "warn" ? typeof console < "u" && console.warn("LaTeX-incompatible input and strict mode is set to 'warn': " + (l + " [" + n + "]")) : typeof console < "u" && console.warn("LaTeX-incompatible input and strict mode is set to " + ("unrecognized '" + m + "': " + l + " [" + n + "]")); + } + }, e.useStrictBehavior = function(n, l, c) { + var m = this.strict; + if (typeof m == "function") + try { + m = m(n, l, c); + } catch { + m = "error"; + } + return !m || m === "ignore" ? !1 : m === !0 || m === "error" ? !0 : m === "warn" ? (typeof console < "u" && console.warn("LaTeX-incompatible input and strict mode is set to 'warn': " + (l + " [" + n + "]")), !1) : (typeof console < "u" && console.warn("LaTeX-incompatible input and strict mode is set to " + ("unrecognized '" + m + "': " + l + " [" + n + "]")), !1); + }, e.isTrusted = function(n) { + n.url && !n.protocol && (n.protocol = V.protocolFromUrl(n.url)); + var l = typeof this.trust == "function" ? this.trust(n) : this.trust; + return !!l; + }, f; + }(), B = /* @__PURE__ */ function() { + function f(t, n, l) { + this.id = void 0, this.size = void 0, this.cramped = void 0, this.id = t, this.size = n, this.cramped = l; + } + var e = f.prototype; + return e.sup = function() { + return Ne[rt[this.id]]; + }, e.sub = function() { + return Ne[vt[this.id]]; + }, e.fracNum = function() { + return Ne[At[this.id]]; + }, e.fracDen = function() { + return Ne[Oe[this.id]]; + }, e.cramp = function() { + return Ne[Ae[this.id]]; + }, e.text = function() { + return Ne[J[this.id]]; + }, e.isTight = function() { + return this.size >= 2; + }, f; + }(), H = 0, W = 1, Z = 2, G = 3, ce = 4, ve = 5, Ee = 6, xe = 7, Ne = [new B(H, 0, !1), new B(W, 0, !0), new B(Z, 1, !1), new B(G, 1, !0), new B(ce, 2, !1), new B(ve, 2, !0), new B(Ee, 3, !1), new B(xe, 3, !0)], rt = [ce, ve, ce, ve, Ee, xe, Ee, xe], vt = [ve, ve, ve, ve, xe, xe, xe, xe], At = [Z, G, ce, ve, Ee, xe, Ee, xe], Oe = [G, G, ve, ve, xe, xe, xe, xe], Ae = [W, W, G, G, ve, ve, xe, xe], J = [H, W, Z, G, Z, G, Z, G], Q = { + DISPLAY: Ne[H], + TEXT: Ne[Z], + SCRIPT: Ne[ce], + SCRIPTSCRIPT: Ne[Ee] + }, Qe = [{ + // Latin characters beyond the Latin-1 characters we have metrics for. + // Needed for Czech, Hungarian and Turkish text, for example. + name: "latin", + blocks: [ + [256, 591], + // Latin Extended-A and Latin Extended-B + [768, 879] + // Combining Diacritical marks + ] + }, { + // The Cyrillic script used by Russian and related languages. + // A Cyrillic subset used to be supported as explicitly defined + // symbols in symbols.js + name: "cyrillic", + blocks: [[1024, 1279]] + }, { + // Armenian + name: "armenian", + blocks: [[1328, 1423]] + }, { + // The Brahmic scripts of South and Southeast Asia + // Devanagari (0900–097F) + // Bengali (0980–09FF) + // Gurmukhi (0A00–0A7F) + // Gujarati (0A80–0AFF) + // Oriya (0B00–0B7F) + // Tamil (0B80–0BFF) + // Telugu (0C00–0C7F) + // Kannada (0C80–0CFF) + // Malayalam (0D00–0D7F) + // Sinhala (0D80–0DFF) + // Thai (0E00–0E7F) + // Lao (0E80–0EFF) + // Tibetan (0F00–0FFF) + // Myanmar (1000–109F) + name: "brahmic", + blocks: [[2304, 4255]] + }, { + name: "georgian", + blocks: [[4256, 4351]] + }, { + // Chinese and Japanese. + // The "k" in cjk is for Korean, but we've separated Korean out + name: "cjk", + blocks: [ + [12288, 12543], + // CJK symbols and punctuation, Hiragana, Katakana + [19968, 40879], + // CJK ideograms + [65280, 65376] + // Fullwidth punctuation + // TODO: add halfwidth Katakana and Romanji glyphs + ] + }, { + // Korean + name: "hangul", + blocks: [[44032, 55215]] + }]; + function ae(f) { + for (var e = 0; e < Qe.length; e++) + for (var t = Qe[e], n = 0; n < t.blocks.length; n++) { + var l = t.blocks[n]; + if (f >= l[0] && f <= l[1]) + return t.name; + } + return null; + } + var Je = []; + Qe.forEach(function(f) { + return f.blocks.forEach(function(e) { + return Je.push.apply(Je, e); + }); + }); + function te(f) { + for (var e = 0; e < Je.length; e += 2) + if (f >= Je[e] && f <= Je[e + 1]) + return !0; + return !1; + } + var Ge = 80, $e = function(e, t) { + return "M95," + (622 + e + t) + ` +c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14 +c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54 +c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10 +s173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429 +c69,-144,104.5,-217.7,106.5,-221 +l` + e / 2.075 + " -" + e + ` +c5.3,-9.3,12,-14,20,-14 +H400000v` + (40 + e) + `H845.2724 +s-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7 +c-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z +M` + (834 + e) + " " + t + "h400000v" + (40 + e) + "h-400000z"; + }, Bt = function(e, t) { + return "M263," + (601 + e + t) + `c0.7,0,18,39.7,52,119 +c34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120 +c340,-704.7,510.7,-1060.3,512,-1067 +l` + e / 2.084 + " -" + e + ` +c4.7,-7.3,11,-11,19,-11 +H40000v` + (40 + e) + `H1012.3 +s-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232 +c-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1 +s-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26 +c-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z +M` + (1001 + e) + " " + t + "h400000v" + (40 + e) + "h-400000z"; + }, G0 = function(e, t) { + return "M983 " + (10 + e + t) + ` +l` + e / 3.13 + " -" + e + ` +c4,-6.7,10,-10,18,-10 H400000v` + (40 + e) + ` +H1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7 +s-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744 +c-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30 +c26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722 +c56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5 +c53.7,-170.3,84.5,-266.8,92.5,-289.5z +M` + (1001 + e) + " " + t + "h400000v" + (40 + e) + "h-400000z"; + }, Dt = function(e, t) { + return "M424," + (2398 + e + t) + ` +c-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514 +c0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20 +s-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121 +s209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081 +l` + e / 4.223 + " -" + e + `c4,-6.7,10,-10,18,-10 H400000 +v` + (40 + e) + `H1014.6 +s-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185 +c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2z M` + (1001 + e) + " " + t + ` +h400000v` + (40 + e) + "h-400000z"; + }, _t = function(e, t) { + return "M473," + (2713 + e + t) + ` +c339.3,-1799.3,509.3,-2700,510,-2702 l` + e / 5.298 + " -" + e + ` +c3.3,-7.3,9.3,-11,18,-11 H400000v` + (40 + e) + `H1017.7 +s-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9 +c-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200 +c0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26 +s76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104, +606zM` + (1001 + e) + " " + t + "h400000v" + (40 + e) + "H1017.7z"; + }, V0 = function(e) { + var t = e / 2; + return "M400000 " + e + " H0 L" + t + " 0 l65 45 L145 " + (e - 80) + " H400000z"; + }, u0 = function(e, t, n) { + var l = n - 54 - t - e; + return "M702 " + (e + t) + "H400000" + (40 + e) + ` +H742v` + l + `l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1 +h-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170 +c-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667 +219 661 l218 661zM702 ` + t + "H400000v" + (40 + e) + "H742z"; + }, b0 = function(e, t, n) { + t = 1e3 * t; + var l = ""; + switch (e) { + case "sqrtMain": + l = $e(t, Ge); + break; + case "sqrtSize1": + l = Bt(t, Ge); + break; + case "sqrtSize2": + l = G0(t, Ge); + break; + case "sqrtSize3": + l = Dt(t, Ge); + break; + case "sqrtSize4": + l = _t(t, Ge); + break; + case "sqrtTall": + l = u0(t, Ge, n); + } + return l; + }, rr = function(e, t) { + switch (e) { + case "⎜": + return "M291 0 H417 V" + t + " H291z M291 0 H417 V" + t + " H291z"; + case "∣": + return "M145 0 H188 V" + t + " H145z M145 0 H188 V" + t + " H145z"; + case "∥": + return "M145 0 H188 V" + t + " H145z M145 0 H188 V" + t + " H145z" + ("M367 0 H410 V" + t + " H367z M367 0 H410 V" + t + " H367z"); + case "⎟": + return "M457 0 H583 V" + t + " H457z M457 0 H583 V" + t + " H457z"; + case "⎢": + return "M319 0 H403 V" + t + " H319z M319 0 H403 V" + t + " H319z"; + case "⎥": + return "M263 0 H347 V" + t + " H263z M263 0 H347 V" + t + " H263z"; + case "⎪": + return "M384 0 H504 V" + t + " H384z M384 0 H504 V" + t + " H384z"; + case "⏐": + return "M312 0 H355 V" + t + " H312z M312 0 H355 V" + t + " H312z"; + case "‖": + return "M257 0 H300 V" + t + " H257z M257 0 H300 V" + t + " H257z" + ("M478 0 H521 V" + t + " H478z M478 0 H521 V" + t + " H478z"); + default: + return ""; + } + }, j0 = { + // The doubleleftarrow geometry is from glyph U+21D0 in the font KaTeX Main + doubleleftarrow: `M262 157 +l10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3 + 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28 + 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5 +c2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5 + 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87 +-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7 +-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z +m8 0v40h399730v-40zm0 194v40h399730v-40z`, + // doublerightarrow is from glyph U+21D2 in font KaTeX Main + doublerightarrow: `M399738 392l +-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5 + 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88 +-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68 +-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18 +-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782 +c-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3 +-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z`, + // leftarrow is from glyph U+2190 in font KaTeX Main + leftarrow: `M400000 241H110l3-3c68.7-52.7 113.7-120 + 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8 +-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247 +c-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208 + 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3 + 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202 + l-3-3h399890zM100 241v40h399900v-40z`, + // overbrace is from glyphs U+23A9/23A8/23A7 in font KaTeX_Size4-Regular + leftbrace: `M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117 +-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7 + 5-6 9-10 13-.7 1-7.3 1-20 1H6z`, + leftbraceunder: `M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13 + 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688 + 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7 +-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z`, + // overgroup is from the MnSymbol package (public domain) + leftgroup: `M400000 80 +H435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0 + 435 0h399565z`, + leftgroupunder: `M400000 262 +H435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219 + 435 219h399565z`, + // Harpoons are from glyph U+21BD in font KaTeX Main + leftharpoon: `M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3 +-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5 +-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7 +-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z`, + leftharpoonplus: `M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5 + 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3 +-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7 +-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z +m0 0v40h400000v-40z`, + leftharpoondown: `M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333 + 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5 + 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667 +-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z`, + leftharpoondownplus: `M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12 + 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7 +-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0 +v40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z`, + // hook is from glyph U+21A9 in font KaTeX Main + lefthook: `M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5 +-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3 +-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21 + 71.5 23h399859zM103 281v-40h399897v40z`, + leftlinesegment: `M40 281 V428 H0 V94 H40 V241 H400000 v40z +M40 281 V428 H0 V94 H40 V241 H400000 v40z`, + leftmapsto: `M40 281 V448H0V74H40V241H400000v40z +M40 281 V448H0V74H40V241H400000v40z`, + // tofrom is from glyph U+21C4 in font KaTeX AMS Regular + leftToFrom: `M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23 +-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8 +c28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3 + 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z`, + longequal: `M0 50 h400000 v40H0z m0 194h40000v40H0z +M0 50 h400000 v40H0z m0 194h40000v40H0z`, + midbrace: `M200428 334 +c-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14 +-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7 + 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11 + 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z`, + midbraceunder: `M199572 214 +c100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14 + 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3 + 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0 +-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z`, + oiintSize1: `M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6 +-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z +m368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8 +60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z`, + oiintSize2: `M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8 +-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z +m502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2 +c0 110 84 276 504 276s502.4-166 502.4-276z`, + oiiintSize1: `M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6 +-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z +m525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0 +85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z`, + oiiintSize2: `M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8 +-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z +m770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1 +c0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z`, + rightarrow: `M0 241v40h399891c-47.3 35.3-84 78-110 128 +-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 + 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 + 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85 +-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 + 151.7 139 205zm0 0v40h399900v-40z`, + rightbrace: `M400000 542l +-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5 +s-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1 +c124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z`, + rightbraceunder: `M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3 + 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237 +-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z`, + rightgroup: `M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0 + 3-1 3-3v-38c-76-158-257-219-435-219H0z`, + rightgroupunder: `M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18 + 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z`, + rightharpoon: `M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3 +-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2 +-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 + 69.2 92 94.5zm0 0v40h399900v-40z`, + rightharpoonplus: `M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11 +-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7 + 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z +m0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z`, + rightharpoondown: `M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8 + 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5 +-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95 +-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z`, + rightharpoondownplus: `M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8 + 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 + 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3 +-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z +m0-194v40h400000v-40zm0 0v40h400000v-40z`, + righthook: `M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3 + 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0 +-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21 + 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z`, + rightlinesegment: `M399960 241 V94 h40 V428 h-40 V281 H0 v-40z +M399960 241 V94 h40 V428 h-40 V281 H0 v-40z`, + rightToFrom: `M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23 + 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32 +-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142 +-167z M100 147v40h399900v-40zM0 341v40h399900v-40z`, + // twoheadleftarrow is from glyph U+219E in font KaTeX AMS Regular + twoheadleftarrow: `M0 167c68 40 + 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69 +-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3 +-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19 +-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101 + 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z`, + twoheadrightarrow: `M400000 167 +c-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3 + 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42 + 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333 +-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70 + 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z`, + // tilde1 is a modified version of a glyph from the MnSymbol package + tilde1: `M200 55.538c-77 0-168 73.953-177 73.953-3 0-7 +-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0 + 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0 + 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128 +-68.267.847-113-73.952-191-73.952z`, + // ditto tilde2, tilde3, & tilde4 + tilde2: `M344 55.266c-142 0-300.638 81.316-311.5 86.418 +-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9 + 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114 +c1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751 + 181.476 676 181.476c-149 0-189-126.21-332-126.21z`, + tilde3: `M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457 +-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0 + 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697 + 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696 + -338 0-409-156.573-744-156.573z`, + tilde4: `M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345 +-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409 + 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9 + 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409 + -175.236-744-175.236z`, + // vec is from glyph U+20D7 in font KaTeX Main + vec: `M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5 +3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11 +10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63 +-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1 +-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59 +H213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359 +c-16-25.333-24-45-24-59z`, + // widehat1 is a modified version of a glyph from the MnSymbol package + widehat1: `M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22 +c-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z`, + // ditto widehat2, widehat3, & widehat4 + widehat2: `M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`, + widehat3: `M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`, + widehat4: `M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10 +-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z`, + // widecheck paths are all inverted versions of widehat + widecheck1: `M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1, +-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z`, + widecheck2: `M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`, + widecheck3: `M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`, + widecheck4: `M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10, +-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z`, + // The next ten paths support reaction arrows from the mhchem package. + // Arrows for \ce{<-->} are offset from xAxis by 0.22ex, per mhchem in LaTeX + // baraboveleftarrow is mostly from glyph U+2190 in font KaTeX Main + baraboveleftarrow: `M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202 +c4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5 +c-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130 +s-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47 +121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6 +s2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11 +c0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z +M100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z`, + // rightarrowabovebar is mostly from glyph U+2192, KaTeX Main + rightarrowabovebar: `M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32 +-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0 +13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39 +-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5 +-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5 +-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67 +151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z`, + // The short left harpoon has 0.5em (i.e. 500 units) kern on the left end. + // Ref from mhchem.sty: \rlap{\raisebox{-.22ex}{$\kern0.5em + baraboveshortleftharpoon: `M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17 +c2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21 +c-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40 +c-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z +M0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z`, + rightharpoonaboveshortbar: `M0,241 l0,40c399126,0,399993,0,399993,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z`, + shortbaraboveleftharpoon: `M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11 +c1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9, +1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7, +-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z +M93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z`, + shortrightharpoonabovebar: `M53,241l0,40c398570,0,399437,0,399437,0 +c4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199, +-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6 +c-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z +M500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z` + }, Vr = function(e, t) { + switch (e) { + case "lbrack": + return "M403 1759 V84 H666 V0 H319 V1759 v" + t + ` v1759 h347 v-84 +H403z M403 1759 V0 H319 V1759 v` + t + " v1759 h84z"; + case "rbrack": + return "M347 1759 V0 H0 V84 H263 V1759 v" + t + ` v1759 H0 v84 H347z +M347 1759 V0 H263 V1759 v` + t + " v1759 h84z"; + case "vert": + return "M145 15 v585 v" + t + ` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v` + -t + ` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v` + t + " v585 h43z"; + case "doublevert": + return "M145 15 v585 v" + t + ` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v` + -t + ` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M188 15 H145 v585 v` + t + ` v585 h43z +M367 15 v585 v` + t + ` v585 c2.667,10,9.667,15,21,15 +c10,0,16.667,-5,20,-15 v-585 v` + -t + ` v-585 c-2.667,-10,-9.667,-15,-21,-15 +c-10,0,-16.667,5,-20,15z M410 15 H367 v585 v` + t + " v585 h43z"; + case "lfloor": + return "M319 602 V0 H403 V602 v" + t + ` v1715 h263 v84 H319z +MM319 602 V0 H403 V602 v` + t + " v1715 H319z"; + case "rfloor": + return "M319 602 V0 H403 V602 v" + t + ` v1799 H0 v-84 H319z +MM319 602 V0 H403 V602 v` + t + " v1715 H319z"; + case "lceil": + return "M403 1759 V84 H666 V0 H319 V1759 v" + t + ` v602 h84z +M403 1759 V0 H319 V1759 v` + t + " v602 h84z"; + case "rceil": + return "M347 1759 V0 H0 V84 H263 V1759 v" + t + ` v602 h84z +M347 1759 V0 h-84 V1759 v` + t + " v602 h84z"; + case "lparen": + return `M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1 +c-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349, +-36,557 l0,` + (t + 84) + `c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210, +949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9 +c0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5, +-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189 +l0,-` + (t + 92) + `c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3, +-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z`; + case "rparen": + return `M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3, +63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5 +c11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,` + (t + 9) + ` +c-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664 +c-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11 +c0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17 +c242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558 +l0,-` + (t + 144) + `c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7, +-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z`; + default: + throw new Error("Unknown stretchy delimiter."); + } + }, y0 = /* @__PURE__ */ function() { + function f(t) { + this.children = void 0, this.classes = void 0, this.height = void 0, this.depth = void 0, this.maxFontSize = void 0, this.style = void 0, this.children = t, this.classes = [], this.height = 0, this.depth = 0, this.maxFontSize = 0, this.style = {}; + } + var e = f.prototype; + return e.hasClass = function(n) { + return V.contains(this.classes, n); + }, e.toNode = function() { + for (var n = document.createDocumentFragment(), l = 0; l < this.children.length; l++) + n.appendChild(this.children[l].toNode()); + return n; + }, e.toMarkup = function() { + for (var n = "", l = 0; l < this.children.length; l++) + n += this.children[l].toMarkup(); + return n; + }, e.toText = function() { + var n = function(c) { + return c.toText(); + }; + return this.children.map(n).join(""); + }, f; + }(), Nt = { + "AMS-Regular": { + 32: [0, 0, 0, 0, 0.25], + 65: [0, 0.68889, 0, 0, 0.72222], + 66: [0, 0.68889, 0, 0, 0.66667], + 67: [0, 0.68889, 0, 0, 0.72222], + 68: [0, 0.68889, 0, 0, 0.72222], + 69: [0, 0.68889, 0, 0, 0.66667], + 70: [0, 0.68889, 0, 0, 0.61111], + 71: [0, 0.68889, 0, 0, 0.77778], + 72: [0, 0.68889, 0, 0, 0.77778], + 73: [0, 0.68889, 0, 0, 0.38889], + 74: [0.16667, 0.68889, 0, 0, 0.5], + 75: [0, 0.68889, 0, 0, 0.77778], + 76: [0, 0.68889, 0, 0, 0.66667], + 77: [0, 0.68889, 0, 0, 0.94445], + 78: [0, 0.68889, 0, 0, 0.72222], + 79: [0.16667, 0.68889, 0, 0, 0.77778], + 80: [0, 0.68889, 0, 0, 0.61111], + 81: [0.16667, 0.68889, 0, 0, 0.77778], + 82: [0, 0.68889, 0, 0, 0.72222], + 83: [0, 0.68889, 0, 0, 0.55556], + 84: [0, 0.68889, 0, 0, 0.66667], + 85: [0, 0.68889, 0, 0, 0.72222], + 86: [0, 0.68889, 0, 0, 0.72222], + 87: [0, 0.68889, 0, 0, 1], + 88: [0, 0.68889, 0, 0, 0.72222], + 89: [0, 0.68889, 0, 0, 0.72222], + 90: [0, 0.68889, 0, 0, 0.66667], + 107: [0, 0.68889, 0, 0, 0.55556], + 160: [0, 0, 0, 0, 0.25], + 165: [0, 0.675, 0.025, 0, 0.75], + 174: [0.15559, 0.69224, 0, 0, 0.94666], + 240: [0, 0.68889, 0, 0, 0.55556], + 295: [0, 0.68889, 0, 0, 0.54028], + 710: [0, 0.825, 0, 0, 2.33334], + 732: [0, 0.9, 0, 0, 2.33334], + 770: [0, 0.825, 0, 0, 2.33334], + 771: [0, 0.9, 0, 0, 2.33334], + 989: [0.08167, 0.58167, 0, 0, 0.77778], + 1008: [0, 0.43056, 0.04028, 0, 0.66667], + 8245: [0, 0.54986, 0, 0, 0.275], + 8463: [0, 0.68889, 0, 0, 0.54028], + 8487: [0, 0.68889, 0, 0, 0.72222], + 8498: [0, 0.68889, 0, 0, 0.55556], + 8502: [0, 0.68889, 0, 0, 0.66667], + 8503: [0, 0.68889, 0, 0, 0.44445], + 8504: [0, 0.68889, 0, 0, 0.66667], + 8513: [0, 0.68889, 0, 0, 0.63889], + 8592: [-0.03598, 0.46402, 0, 0, 0.5], + 8594: [-0.03598, 0.46402, 0, 0, 0.5], + 8602: [-0.13313, 0.36687, 0, 0, 1], + 8603: [-0.13313, 0.36687, 0, 0, 1], + 8606: [0.01354, 0.52239, 0, 0, 1], + 8608: [0.01354, 0.52239, 0, 0, 1], + 8610: [0.01354, 0.52239, 0, 0, 1.11111], + 8611: [0.01354, 0.52239, 0, 0, 1.11111], + 8619: [0, 0.54986, 0, 0, 1], + 8620: [0, 0.54986, 0, 0, 1], + 8621: [-0.13313, 0.37788, 0, 0, 1.38889], + 8622: [-0.13313, 0.36687, 0, 0, 1], + 8624: [0, 0.69224, 0, 0, 0.5], + 8625: [0, 0.69224, 0, 0, 0.5], + 8630: [0, 0.43056, 0, 0, 1], + 8631: [0, 0.43056, 0, 0, 1], + 8634: [0.08198, 0.58198, 0, 0, 0.77778], + 8635: [0.08198, 0.58198, 0, 0, 0.77778], + 8638: [0.19444, 0.69224, 0, 0, 0.41667], + 8639: [0.19444, 0.69224, 0, 0, 0.41667], + 8642: [0.19444, 0.69224, 0, 0, 0.41667], + 8643: [0.19444, 0.69224, 0, 0, 0.41667], + 8644: [0.1808, 0.675, 0, 0, 1], + 8646: [0.1808, 0.675, 0, 0, 1], + 8647: [0.1808, 0.675, 0, 0, 1], + 8648: [0.19444, 0.69224, 0, 0, 0.83334], + 8649: [0.1808, 0.675, 0, 0, 1], + 8650: [0.19444, 0.69224, 0, 0, 0.83334], + 8651: [0.01354, 0.52239, 0, 0, 1], + 8652: [0.01354, 0.52239, 0, 0, 1], + 8653: [-0.13313, 0.36687, 0, 0, 1], + 8654: [-0.13313, 0.36687, 0, 0, 1], + 8655: [-0.13313, 0.36687, 0, 0, 1], + 8666: [0.13667, 0.63667, 0, 0, 1], + 8667: [0.13667, 0.63667, 0, 0, 1], + 8669: [-0.13313, 0.37788, 0, 0, 1], + 8672: [-0.064, 0.437, 0, 0, 1.334], + 8674: [-0.064, 0.437, 0, 0, 1.334], + 8705: [0, 0.825, 0, 0, 0.5], + 8708: [0, 0.68889, 0, 0, 0.55556], + 8709: [0.08167, 0.58167, 0, 0, 0.77778], + 8717: [0, 0.43056, 0, 0, 0.42917], + 8722: [-0.03598, 0.46402, 0, 0, 0.5], + 8724: [0.08198, 0.69224, 0, 0, 0.77778], + 8726: [0.08167, 0.58167, 0, 0, 0.77778], + 8733: [0, 0.69224, 0, 0, 0.77778], + 8736: [0, 0.69224, 0, 0, 0.72222], + 8737: [0, 0.69224, 0, 0, 0.72222], + 8738: [0.03517, 0.52239, 0, 0, 0.72222], + 8739: [0.08167, 0.58167, 0, 0, 0.22222], + 8740: [0.25142, 0.74111, 0, 0, 0.27778], + 8741: [0.08167, 0.58167, 0, 0, 0.38889], + 8742: [0.25142, 0.74111, 0, 0, 0.5], + 8756: [0, 0.69224, 0, 0, 0.66667], + 8757: [0, 0.69224, 0, 0, 0.66667], + 8764: [-0.13313, 0.36687, 0, 0, 0.77778], + 8765: [-0.13313, 0.37788, 0, 0, 0.77778], + 8769: [-0.13313, 0.36687, 0, 0, 0.77778], + 8770: [-0.03625, 0.46375, 0, 0, 0.77778], + 8774: [0.30274, 0.79383, 0, 0, 0.77778], + 8776: [-0.01688, 0.48312, 0, 0, 0.77778], + 8778: [0.08167, 0.58167, 0, 0, 0.77778], + 8782: [0.06062, 0.54986, 0, 0, 0.77778], + 8783: [0.06062, 0.54986, 0, 0, 0.77778], + 8785: [0.08198, 0.58198, 0, 0, 0.77778], + 8786: [0.08198, 0.58198, 0, 0, 0.77778], + 8787: [0.08198, 0.58198, 0, 0, 0.77778], + 8790: [0, 0.69224, 0, 0, 0.77778], + 8791: [0.22958, 0.72958, 0, 0, 0.77778], + 8796: [0.08198, 0.91667, 0, 0, 0.77778], + 8806: [0.25583, 0.75583, 0, 0, 0.77778], + 8807: [0.25583, 0.75583, 0, 0, 0.77778], + 8808: [0.25142, 0.75726, 0, 0, 0.77778], + 8809: [0.25142, 0.75726, 0, 0, 0.77778], + 8812: [0.25583, 0.75583, 0, 0, 0.5], + 8814: [0.20576, 0.70576, 0, 0, 0.77778], + 8815: [0.20576, 0.70576, 0, 0, 0.77778], + 8816: [0.30274, 0.79383, 0, 0, 0.77778], + 8817: [0.30274, 0.79383, 0, 0, 0.77778], + 8818: [0.22958, 0.72958, 0, 0, 0.77778], + 8819: [0.22958, 0.72958, 0, 0, 0.77778], + 8822: [0.1808, 0.675, 0, 0, 0.77778], + 8823: [0.1808, 0.675, 0, 0, 0.77778], + 8828: [0.13667, 0.63667, 0, 0, 0.77778], + 8829: [0.13667, 0.63667, 0, 0, 0.77778], + 8830: [0.22958, 0.72958, 0, 0, 0.77778], + 8831: [0.22958, 0.72958, 0, 0, 0.77778], + 8832: [0.20576, 0.70576, 0, 0, 0.77778], + 8833: [0.20576, 0.70576, 0, 0, 0.77778], + 8840: [0.30274, 0.79383, 0, 0, 0.77778], + 8841: [0.30274, 0.79383, 0, 0, 0.77778], + 8842: [0.13597, 0.63597, 0, 0, 0.77778], + 8843: [0.13597, 0.63597, 0, 0, 0.77778], + 8847: [0.03517, 0.54986, 0, 0, 0.77778], + 8848: [0.03517, 0.54986, 0, 0, 0.77778], + 8858: [0.08198, 0.58198, 0, 0, 0.77778], + 8859: [0.08198, 0.58198, 0, 0, 0.77778], + 8861: [0.08198, 0.58198, 0, 0, 0.77778], + 8862: [0, 0.675, 0, 0, 0.77778], + 8863: [0, 0.675, 0, 0, 0.77778], + 8864: [0, 0.675, 0, 0, 0.77778], + 8865: [0, 0.675, 0, 0, 0.77778], + 8872: [0, 0.69224, 0, 0, 0.61111], + 8873: [0, 0.69224, 0, 0, 0.72222], + 8874: [0, 0.69224, 0, 0, 0.88889], + 8876: [0, 0.68889, 0, 0, 0.61111], + 8877: [0, 0.68889, 0, 0, 0.61111], + 8878: [0, 0.68889, 0, 0, 0.72222], + 8879: [0, 0.68889, 0, 0, 0.72222], + 8882: [0.03517, 0.54986, 0, 0, 0.77778], + 8883: [0.03517, 0.54986, 0, 0, 0.77778], + 8884: [0.13667, 0.63667, 0, 0, 0.77778], + 8885: [0.13667, 0.63667, 0, 0, 0.77778], + 8888: [0, 0.54986, 0, 0, 1.11111], + 8890: [0.19444, 0.43056, 0, 0, 0.55556], + 8891: [0.19444, 0.69224, 0, 0, 0.61111], + 8892: [0.19444, 0.69224, 0, 0, 0.61111], + 8901: [0, 0.54986, 0, 0, 0.27778], + 8903: [0.08167, 0.58167, 0, 0, 0.77778], + 8905: [0.08167, 0.58167, 0, 0, 0.77778], + 8906: [0.08167, 0.58167, 0, 0, 0.77778], + 8907: [0, 0.69224, 0, 0, 0.77778], + 8908: [0, 0.69224, 0, 0, 0.77778], + 8909: [-0.03598, 0.46402, 0, 0, 0.77778], + 8910: [0, 0.54986, 0, 0, 0.76042], + 8911: [0, 0.54986, 0, 0, 0.76042], + 8912: [0.03517, 0.54986, 0, 0, 0.77778], + 8913: [0.03517, 0.54986, 0, 0, 0.77778], + 8914: [0, 0.54986, 0, 0, 0.66667], + 8915: [0, 0.54986, 0, 0, 0.66667], + 8916: [0, 0.69224, 0, 0, 0.66667], + 8918: [0.0391, 0.5391, 0, 0, 0.77778], + 8919: [0.0391, 0.5391, 0, 0, 0.77778], + 8920: [0.03517, 0.54986, 0, 0, 1.33334], + 8921: [0.03517, 0.54986, 0, 0, 1.33334], + 8922: [0.38569, 0.88569, 0, 0, 0.77778], + 8923: [0.38569, 0.88569, 0, 0, 0.77778], + 8926: [0.13667, 0.63667, 0, 0, 0.77778], + 8927: [0.13667, 0.63667, 0, 0, 0.77778], + 8928: [0.30274, 0.79383, 0, 0, 0.77778], + 8929: [0.30274, 0.79383, 0, 0, 0.77778], + 8934: [0.23222, 0.74111, 0, 0, 0.77778], + 8935: [0.23222, 0.74111, 0, 0, 0.77778], + 8936: [0.23222, 0.74111, 0, 0, 0.77778], + 8937: [0.23222, 0.74111, 0, 0, 0.77778], + 8938: [0.20576, 0.70576, 0, 0, 0.77778], + 8939: [0.20576, 0.70576, 0, 0, 0.77778], + 8940: [0.30274, 0.79383, 0, 0, 0.77778], + 8941: [0.30274, 0.79383, 0, 0, 0.77778], + 8994: [0.19444, 0.69224, 0, 0, 0.77778], + 8995: [0.19444, 0.69224, 0, 0, 0.77778], + 9416: [0.15559, 0.69224, 0, 0, 0.90222], + 9484: [0, 0.69224, 0, 0, 0.5], + 9488: [0, 0.69224, 0, 0, 0.5], + 9492: [0, 0.37788, 0, 0, 0.5], + 9496: [0, 0.37788, 0, 0, 0.5], + 9585: [0.19444, 0.68889, 0, 0, 0.88889], + 9586: [0.19444, 0.74111, 0, 0, 0.88889], + 9632: [0, 0.675, 0, 0, 0.77778], + 9633: [0, 0.675, 0, 0, 0.77778], + 9650: [0, 0.54986, 0, 0, 0.72222], + 9651: [0, 0.54986, 0, 0, 0.72222], + 9654: [0.03517, 0.54986, 0, 0, 0.77778], + 9660: [0, 0.54986, 0, 0, 0.72222], + 9661: [0, 0.54986, 0, 0, 0.72222], + 9664: [0.03517, 0.54986, 0, 0, 0.77778], + 9674: [0.11111, 0.69224, 0, 0, 0.66667], + 9733: [0.19444, 0.69224, 0, 0, 0.94445], + 10003: [0, 0.69224, 0, 0, 0.83334], + 10016: [0, 0.69224, 0, 0, 0.83334], + 10731: [0.11111, 0.69224, 0, 0, 0.66667], + 10846: [0.19444, 0.75583, 0, 0, 0.61111], + 10877: [0.13667, 0.63667, 0, 0, 0.77778], + 10878: [0.13667, 0.63667, 0, 0, 0.77778], + 10885: [0.25583, 0.75583, 0, 0, 0.77778], + 10886: [0.25583, 0.75583, 0, 0, 0.77778], + 10887: [0.13597, 0.63597, 0, 0, 0.77778], + 10888: [0.13597, 0.63597, 0, 0, 0.77778], + 10889: [0.26167, 0.75726, 0, 0, 0.77778], + 10890: [0.26167, 0.75726, 0, 0, 0.77778], + 10891: [0.48256, 0.98256, 0, 0, 0.77778], + 10892: [0.48256, 0.98256, 0, 0, 0.77778], + 10901: [0.13667, 0.63667, 0, 0, 0.77778], + 10902: [0.13667, 0.63667, 0, 0, 0.77778], + 10933: [0.25142, 0.75726, 0, 0, 0.77778], + 10934: [0.25142, 0.75726, 0, 0, 0.77778], + 10935: [0.26167, 0.75726, 0, 0, 0.77778], + 10936: [0.26167, 0.75726, 0, 0, 0.77778], + 10937: [0.26167, 0.75726, 0, 0, 0.77778], + 10938: [0.26167, 0.75726, 0, 0, 0.77778], + 10949: [0.25583, 0.75583, 0, 0, 0.77778], + 10950: [0.25583, 0.75583, 0, 0, 0.77778], + 10955: [0.28481, 0.79383, 0, 0, 0.77778], + 10956: [0.28481, 0.79383, 0, 0, 0.77778], + 57350: [0.08167, 0.58167, 0, 0, 0.22222], + 57351: [0.08167, 0.58167, 0, 0, 0.38889], + 57352: [0.08167, 0.58167, 0, 0, 0.77778], + 57353: [0, 0.43056, 0.04028, 0, 0.66667], + 57356: [0.25142, 0.75726, 0, 0, 0.77778], + 57357: [0.25142, 0.75726, 0, 0, 0.77778], + 57358: [0.41951, 0.91951, 0, 0, 0.77778], + 57359: [0.30274, 0.79383, 0, 0, 0.77778], + 57360: [0.30274, 0.79383, 0, 0, 0.77778], + 57361: [0.41951, 0.91951, 0, 0, 0.77778], + 57366: [0.25142, 0.75726, 0, 0, 0.77778], + 57367: [0.25142, 0.75726, 0, 0, 0.77778], + 57368: [0.25142, 0.75726, 0, 0, 0.77778], + 57369: [0.25142, 0.75726, 0, 0, 0.77778], + 57370: [0.13597, 0.63597, 0, 0, 0.77778], + 57371: [0.13597, 0.63597, 0, 0, 0.77778] + }, + "Caligraphic-Regular": { + 32: [0, 0, 0, 0, 0.25], + 65: [0, 0.68333, 0, 0.19445, 0.79847], + 66: [0, 0.68333, 0.03041, 0.13889, 0.65681], + 67: [0, 0.68333, 0.05834, 0.13889, 0.52653], + 68: [0, 0.68333, 0.02778, 0.08334, 0.77139], + 69: [0, 0.68333, 0.08944, 0.11111, 0.52778], + 70: [0, 0.68333, 0.09931, 0.11111, 0.71875], + 71: [0.09722, 0.68333, 0.0593, 0.11111, 0.59487], + 72: [0, 0.68333, 965e-5, 0.11111, 0.84452], + 73: [0, 0.68333, 0.07382, 0, 0.54452], + 74: [0.09722, 0.68333, 0.18472, 0.16667, 0.67778], + 75: [0, 0.68333, 0.01445, 0.05556, 0.76195], + 76: [0, 0.68333, 0, 0.13889, 0.68972], + 77: [0, 0.68333, 0, 0.13889, 1.2009], + 78: [0, 0.68333, 0.14736, 0.08334, 0.82049], + 79: [0, 0.68333, 0.02778, 0.11111, 0.79611], + 80: [0, 0.68333, 0.08222, 0.08334, 0.69556], + 81: [0.09722, 0.68333, 0, 0.11111, 0.81667], + 82: [0, 0.68333, 0, 0.08334, 0.8475], + 83: [0, 0.68333, 0.075, 0.13889, 0.60556], + 84: [0, 0.68333, 0.25417, 0, 0.54464], + 85: [0, 0.68333, 0.09931, 0.08334, 0.62583], + 86: [0, 0.68333, 0.08222, 0, 0.61278], + 87: [0, 0.68333, 0.08222, 0.08334, 0.98778], + 88: [0, 0.68333, 0.14643, 0.13889, 0.7133], + 89: [0.09722, 0.68333, 0.08222, 0.08334, 0.66834], + 90: [0, 0.68333, 0.07944, 0.13889, 0.72473], + 160: [0, 0, 0, 0, 0.25] + }, + "Fraktur-Regular": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69141, 0, 0, 0.29574], + 34: [0, 0.69141, 0, 0, 0.21471], + 38: [0, 0.69141, 0, 0, 0.73786], + 39: [0, 0.69141, 0, 0, 0.21201], + 40: [0.24982, 0.74947, 0, 0, 0.38865], + 41: [0.24982, 0.74947, 0, 0, 0.38865], + 42: [0, 0.62119, 0, 0, 0.27764], + 43: [0.08319, 0.58283, 0, 0, 0.75623], + 44: [0, 0.10803, 0, 0, 0.27764], + 45: [0.08319, 0.58283, 0, 0, 0.75623], + 46: [0, 0.10803, 0, 0, 0.27764], + 47: [0.24982, 0.74947, 0, 0, 0.50181], + 48: [0, 0.47534, 0, 0, 0.50181], + 49: [0, 0.47534, 0, 0, 0.50181], + 50: [0, 0.47534, 0, 0, 0.50181], + 51: [0.18906, 0.47534, 0, 0, 0.50181], + 52: [0.18906, 0.47534, 0, 0, 0.50181], + 53: [0.18906, 0.47534, 0, 0, 0.50181], + 54: [0, 0.69141, 0, 0, 0.50181], + 55: [0.18906, 0.47534, 0, 0, 0.50181], + 56: [0, 0.69141, 0, 0, 0.50181], + 57: [0.18906, 0.47534, 0, 0, 0.50181], + 58: [0, 0.47534, 0, 0, 0.21606], + 59: [0.12604, 0.47534, 0, 0, 0.21606], + 61: [-0.13099, 0.36866, 0, 0, 0.75623], + 63: [0, 0.69141, 0, 0, 0.36245], + 65: [0, 0.69141, 0, 0, 0.7176], + 66: [0, 0.69141, 0, 0, 0.88397], + 67: [0, 0.69141, 0, 0, 0.61254], + 68: [0, 0.69141, 0, 0, 0.83158], + 69: [0, 0.69141, 0, 0, 0.66278], + 70: [0.12604, 0.69141, 0, 0, 0.61119], + 71: [0, 0.69141, 0, 0, 0.78539], + 72: [0.06302, 0.69141, 0, 0, 0.7203], + 73: [0, 0.69141, 0, 0, 0.55448], + 74: [0.12604, 0.69141, 0, 0, 0.55231], + 75: [0, 0.69141, 0, 0, 0.66845], + 76: [0, 0.69141, 0, 0, 0.66602], + 77: [0, 0.69141, 0, 0, 1.04953], + 78: [0, 0.69141, 0, 0, 0.83212], + 79: [0, 0.69141, 0, 0, 0.82699], + 80: [0.18906, 0.69141, 0, 0, 0.82753], + 81: [0.03781, 0.69141, 0, 0, 0.82699], + 82: [0, 0.69141, 0, 0, 0.82807], + 83: [0, 0.69141, 0, 0, 0.82861], + 84: [0, 0.69141, 0, 0, 0.66899], + 85: [0, 0.69141, 0, 0, 0.64576], + 86: [0, 0.69141, 0, 0, 0.83131], + 87: [0, 0.69141, 0, 0, 1.04602], + 88: [0, 0.69141, 0, 0, 0.71922], + 89: [0.18906, 0.69141, 0, 0, 0.83293], + 90: [0.12604, 0.69141, 0, 0, 0.60201], + 91: [0.24982, 0.74947, 0, 0, 0.27764], + 93: [0.24982, 0.74947, 0, 0, 0.27764], + 94: [0, 0.69141, 0, 0, 0.49965], + 97: [0, 0.47534, 0, 0, 0.50046], + 98: [0, 0.69141, 0, 0, 0.51315], + 99: [0, 0.47534, 0, 0, 0.38946], + 100: [0, 0.62119, 0, 0, 0.49857], + 101: [0, 0.47534, 0, 0, 0.40053], + 102: [0.18906, 0.69141, 0, 0, 0.32626], + 103: [0.18906, 0.47534, 0, 0, 0.5037], + 104: [0.18906, 0.69141, 0, 0, 0.52126], + 105: [0, 0.69141, 0, 0, 0.27899], + 106: [0, 0.69141, 0, 0, 0.28088], + 107: [0, 0.69141, 0, 0, 0.38946], + 108: [0, 0.69141, 0, 0, 0.27953], + 109: [0, 0.47534, 0, 0, 0.76676], + 110: [0, 0.47534, 0, 0, 0.52666], + 111: [0, 0.47534, 0, 0, 0.48885], + 112: [0.18906, 0.52396, 0, 0, 0.50046], + 113: [0.18906, 0.47534, 0, 0, 0.48912], + 114: [0, 0.47534, 0, 0, 0.38919], + 115: [0, 0.47534, 0, 0, 0.44266], + 116: [0, 0.62119, 0, 0, 0.33301], + 117: [0, 0.47534, 0, 0, 0.5172], + 118: [0, 0.52396, 0, 0, 0.5118], + 119: [0, 0.52396, 0, 0, 0.77351], + 120: [0.18906, 0.47534, 0, 0, 0.38865], + 121: [0.18906, 0.47534, 0, 0, 0.49884], + 122: [0.18906, 0.47534, 0, 0, 0.39054], + 160: [0, 0, 0, 0, 0.25], + 8216: [0, 0.69141, 0, 0, 0.21471], + 8217: [0, 0.69141, 0, 0, 0.21471], + 58112: [0, 0.62119, 0, 0, 0.49749], + 58113: [0, 0.62119, 0, 0, 0.4983], + 58114: [0.18906, 0.69141, 0, 0, 0.33328], + 58115: [0.18906, 0.69141, 0, 0, 0.32923], + 58116: [0.18906, 0.47534, 0, 0, 0.50343], + 58117: [0, 0.69141, 0, 0, 0.33301], + 58118: [0, 0.62119, 0, 0, 0.33409], + 58119: [0, 0.47534, 0, 0, 0.50073] + }, + "Main-Bold": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0, 0, 0.35], + 34: [0, 0.69444, 0, 0, 0.60278], + 35: [0.19444, 0.69444, 0, 0, 0.95833], + 36: [0.05556, 0.75, 0, 0, 0.575], + 37: [0.05556, 0.75, 0, 0, 0.95833], + 38: [0, 0.69444, 0, 0, 0.89444], + 39: [0, 0.69444, 0, 0, 0.31944], + 40: [0.25, 0.75, 0, 0, 0.44722], + 41: [0.25, 0.75, 0, 0, 0.44722], + 42: [0, 0.75, 0, 0, 0.575], + 43: [0.13333, 0.63333, 0, 0, 0.89444], + 44: [0.19444, 0.15556, 0, 0, 0.31944], + 45: [0, 0.44444, 0, 0, 0.38333], + 46: [0, 0.15556, 0, 0, 0.31944], + 47: [0.25, 0.75, 0, 0, 0.575], + 48: [0, 0.64444, 0, 0, 0.575], + 49: [0, 0.64444, 0, 0, 0.575], + 50: [0, 0.64444, 0, 0, 0.575], + 51: [0, 0.64444, 0, 0, 0.575], + 52: [0, 0.64444, 0, 0, 0.575], + 53: [0, 0.64444, 0, 0, 0.575], + 54: [0, 0.64444, 0, 0, 0.575], + 55: [0, 0.64444, 0, 0, 0.575], + 56: [0, 0.64444, 0, 0, 0.575], + 57: [0, 0.64444, 0, 0, 0.575], + 58: [0, 0.44444, 0, 0, 0.31944], + 59: [0.19444, 0.44444, 0, 0, 0.31944], + 60: [0.08556, 0.58556, 0, 0, 0.89444], + 61: [-0.10889, 0.39111, 0, 0, 0.89444], + 62: [0.08556, 0.58556, 0, 0, 0.89444], + 63: [0, 0.69444, 0, 0, 0.54305], + 64: [0, 0.69444, 0, 0, 0.89444], + 65: [0, 0.68611, 0, 0, 0.86944], + 66: [0, 0.68611, 0, 0, 0.81805], + 67: [0, 0.68611, 0, 0, 0.83055], + 68: [0, 0.68611, 0, 0, 0.88194], + 69: [0, 0.68611, 0, 0, 0.75555], + 70: [0, 0.68611, 0, 0, 0.72361], + 71: [0, 0.68611, 0, 0, 0.90416], + 72: [0, 0.68611, 0, 0, 0.9], + 73: [0, 0.68611, 0, 0, 0.43611], + 74: [0, 0.68611, 0, 0, 0.59444], + 75: [0, 0.68611, 0, 0, 0.90138], + 76: [0, 0.68611, 0, 0, 0.69166], + 77: [0, 0.68611, 0, 0, 1.09166], + 78: [0, 0.68611, 0, 0, 0.9], + 79: [0, 0.68611, 0, 0, 0.86388], + 80: [0, 0.68611, 0, 0, 0.78611], + 81: [0.19444, 0.68611, 0, 0, 0.86388], + 82: [0, 0.68611, 0, 0, 0.8625], + 83: [0, 0.68611, 0, 0, 0.63889], + 84: [0, 0.68611, 0, 0, 0.8], + 85: [0, 0.68611, 0, 0, 0.88472], + 86: [0, 0.68611, 0.01597, 0, 0.86944], + 87: [0, 0.68611, 0.01597, 0, 1.18888], + 88: [0, 0.68611, 0, 0, 0.86944], + 89: [0, 0.68611, 0.02875, 0, 0.86944], + 90: [0, 0.68611, 0, 0, 0.70277], + 91: [0.25, 0.75, 0, 0, 0.31944], + 92: [0.25, 0.75, 0, 0, 0.575], + 93: [0.25, 0.75, 0, 0, 0.31944], + 94: [0, 0.69444, 0, 0, 0.575], + 95: [0.31, 0.13444, 0.03194, 0, 0.575], + 97: [0, 0.44444, 0, 0, 0.55902], + 98: [0, 0.69444, 0, 0, 0.63889], + 99: [0, 0.44444, 0, 0, 0.51111], + 100: [0, 0.69444, 0, 0, 0.63889], + 101: [0, 0.44444, 0, 0, 0.52708], + 102: [0, 0.69444, 0.10903, 0, 0.35139], + 103: [0.19444, 0.44444, 0.01597, 0, 0.575], + 104: [0, 0.69444, 0, 0, 0.63889], + 105: [0, 0.69444, 0, 0, 0.31944], + 106: [0.19444, 0.69444, 0, 0, 0.35139], + 107: [0, 0.69444, 0, 0, 0.60694], + 108: [0, 0.69444, 0, 0, 0.31944], + 109: [0, 0.44444, 0, 0, 0.95833], + 110: [0, 0.44444, 0, 0, 0.63889], + 111: [0, 0.44444, 0, 0, 0.575], + 112: [0.19444, 0.44444, 0, 0, 0.63889], + 113: [0.19444, 0.44444, 0, 0, 0.60694], + 114: [0, 0.44444, 0, 0, 0.47361], + 115: [0, 0.44444, 0, 0, 0.45361], + 116: [0, 0.63492, 0, 0, 0.44722], + 117: [0, 0.44444, 0, 0, 0.63889], + 118: [0, 0.44444, 0.01597, 0, 0.60694], + 119: [0, 0.44444, 0.01597, 0, 0.83055], + 120: [0, 0.44444, 0, 0, 0.60694], + 121: [0.19444, 0.44444, 0.01597, 0, 0.60694], + 122: [0, 0.44444, 0, 0, 0.51111], + 123: [0.25, 0.75, 0, 0, 0.575], + 124: [0.25, 0.75, 0, 0, 0.31944], + 125: [0.25, 0.75, 0, 0, 0.575], + 126: [0.35, 0.34444, 0, 0, 0.575], + 160: [0, 0, 0, 0, 0.25], + 163: [0, 0.69444, 0, 0, 0.86853], + 168: [0, 0.69444, 0, 0, 0.575], + 172: [0, 0.44444, 0, 0, 0.76666], + 176: [0, 0.69444, 0, 0, 0.86944], + 177: [0.13333, 0.63333, 0, 0, 0.89444], + 184: [0.17014, 0, 0, 0, 0.51111], + 198: [0, 0.68611, 0, 0, 1.04166], + 215: [0.13333, 0.63333, 0, 0, 0.89444], + 216: [0.04861, 0.73472, 0, 0, 0.89444], + 223: [0, 0.69444, 0, 0, 0.59722], + 230: [0, 0.44444, 0, 0, 0.83055], + 247: [0.13333, 0.63333, 0, 0, 0.89444], + 248: [0.09722, 0.54167, 0, 0, 0.575], + 305: [0, 0.44444, 0, 0, 0.31944], + 338: [0, 0.68611, 0, 0, 1.16944], + 339: [0, 0.44444, 0, 0, 0.89444], + 567: [0.19444, 0.44444, 0, 0, 0.35139], + 710: [0, 0.69444, 0, 0, 0.575], + 711: [0, 0.63194, 0, 0, 0.575], + 713: [0, 0.59611, 0, 0, 0.575], + 714: [0, 0.69444, 0, 0, 0.575], + 715: [0, 0.69444, 0, 0, 0.575], + 728: [0, 0.69444, 0, 0, 0.575], + 729: [0, 0.69444, 0, 0, 0.31944], + 730: [0, 0.69444, 0, 0, 0.86944], + 732: [0, 0.69444, 0, 0, 0.575], + 733: [0, 0.69444, 0, 0, 0.575], + 915: [0, 0.68611, 0, 0, 0.69166], + 916: [0, 0.68611, 0, 0, 0.95833], + 920: [0, 0.68611, 0, 0, 0.89444], + 923: [0, 0.68611, 0, 0, 0.80555], + 926: [0, 0.68611, 0, 0, 0.76666], + 928: [0, 0.68611, 0, 0, 0.9], + 931: [0, 0.68611, 0, 0, 0.83055], + 933: [0, 0.68611, 0, 0, 0.89444], + 934: [0, 0.68611, 0, 0, 0.83055], + 936: [0, 0.68611, 0, 0, 0.89444], + 937: [0, 0.68611, 0, 0, 0.83055], + 8211: [0, 0.44444, 0.03194, 0, 0.575], + 8212: [0, 0.44444, 0.03194, 0, 1.14999], + 8216: [0, 0.69444, 0, 0, 0.31944], + 8217: [0, 0.69444, 0, 0, 0.31944], + 8220: [0, 0.69444, 0, 0, 0.60278], + 8221: [0, 0.69444, 0, 0, 0.60278], + 8224: [0.19444, 0.69444, 0, 0, 0.51111], + 8225: [0.19444, 0.69444, 0, 0, 0.51111], + 8242: [0, 0.55556, 0, 0, 0.34444], + 8407: [0, 0.72444, 0.15486, 0, 0.575], + 8463: [0, 0.69444, 0, 0, 0.66759], + 8465: [0, 0.69444, 0, 0, 0.83055], + 8467: [0, 0.69444, 0, 0, 0.47361], + 8472: [0.19444, 0.44444, 0, 0, 0.74027], + 8476: [0, 0.69444, 0, 0, 0.83055], + 8501: [0, 0.69444, 0, 0, 0.70277], + 8592: [-0.10889, 0.39111, 0, 0, 1.14999], + 8593: [0.19444, 0.69444, 0, 0, 0.575], + 8594: [-0.10889, 0.39111, 0, 0, 1.14999], + 8595: [0.19444, 0.69444, 0, 0, 0.575], + 8596: [-0.10889, 0.39111, 0, 0, 1.14999], + 8597: [0.25, 0.75, 0, 0, 0.575], + 8598: [0.19444, 0.69444, 0, 0, 1.14999], + 8599: [0.19444, 0.69444, 0, 0, 1.14999], + 8600: [0.19444, 0.69444, 0, 0, 1.14999], + 8601: [0.19444, 0.69444, 0, 0, 1.14999], + 8636: [-0.10889, 0.39111, 0, 0, 1.14999], + 8637: [-0.10889, 0.39111, 0, 0, 1.14999], + 8640: [-0.10889, 0.39111, 0, 0, 1.14999], + 8641: [-0.10889, 0.39111, 0, 0, 1.14999], + 8656: [-0.10889, 0.39111, 0, 0, 1.14999], + 8657: [0.19444, 0.69444, 0, 0, 0.70277], + 8658: [-0.10889, 0.39111, 0, 0, 1.14999], + 8659: [0.19444, 0.69444, 0, 0, 0.70277], + 8660: [-0.10889, 0.39111, 0, 0, 1.14999], + 8661: [0.25, 0.75, 0, 0, 0.70277], + 8704: [0, 0.69444, 0, 0, 0.63889], + 8706: [0, 0.69444, 0.06389, 0, 0.62847], + 8707: [0, 0.69444, 0, 0, 0.63889], + 8709: [0.05556, 0.75, 0, 0, 0.575], + 8711: [0, 0.68611, 0, 0, 0.95833], + 8712: [0.08556, 0.58556, 0, 0, 0.76666], + 8715: [0.08556, 0.58556, 0, 0, 0.76666], + 8722: [0.13333, 0.63333, 0, 0, 0.89444], + 8723: [0.13333, 0.63333, 0, 0, 0.89444], + 8725: [0.25, 0.75, 0, 0, 0.575], + 8726: [0.25, 0.75, 0, 0, 0.575], + 8727: [-0.02778, 0.47222, 0, 0, 0.575], + 8728: [-0.02639, 0.47361, 0, 0, 0.575], + 8729: [-0.02639, 0.47361, 0, 0, 0.575], + 8730: [0.18, 0.82, 0, 0, 0.95833], + 8733: [0, 0.44444, 0, 0, 0.89444], + 8734: [0, 0.44444, 0, 0, 1.14999], + 8736: [0, 0.69224, 0, 0, 0.72222], + 8739: [0.25, 0.75, 0, 0, 0.31944], + 8741: [0.25, 0.75, 0, 0, 0.575], + 8743: [0, 0.55556, 0, 0, 0.76666], + 8744: [0, 0.55556, 0, 0, 0.76666], + 8745: [0, 0.55556, 0, 0, 0.76666], + 8746: [0, 0.55556, 0, 0, 0.76666], + 8747: [0.19444, 0.69444, 0.12778, 0, 0.56875], + 8764: [-0.10889, 0.39111, 0, 0, 0.89444], + 8768: [0.19444, 0.69444, 0, 0, 0.31944], + 8771: [222e-5, 0.50222, 0, 0, 0.89444], + 8773: [0.027, 0.638, 0, 0, 0.894], + 8776: [0.02444, 0.52444, 0, 0, 0.89444], + 8781: [222e-5, 0.50222, 0, 0, 0.89444], + 8801: [222e-5, 0.50222, 0, 0, 0.89444], + 8804: [0.19667, 0.69667, 0, 0, 0.89444], + 8805: [0.19667, 0.69667, 0, 0, 0.89444], + 8810: [0.08556, 0.58556, 0, 0, 1.14999], + 8811: [0.08556, 0.58556, 0, 0, 1.14999], + 8826: [0.08556, 0.58556, 0, 0, 0.89444], + 8827: [0.08556, 0.58556, 0, 0, 0.89444], + 8834: [0.08556, 0.58556, 0, 0, 0.89444], + 8835: [0.08556, 0.58556, 0, 0, 0.89444], + 8838: [0.19667, 0.69667, 0, 0, 0.89444], + 8839: [0.19667, 0.69667, 0, 0, 0.89444], + 8846: [0, 0.55556, 0, 0, 0.76666], + 8849: [0.19667, 0.69667, 0, 0, 0.89444], + 8850: [0.19667, 0.69667, 0, 0, 0.89444], + 8851: [0, 0.55556, 0, 0, 0.76666], + 8852: [0, 0.55556, 0, 0, 0.76666], + 8853: [0.13333, 0.63333, 0, 0, 0.89444], + 8854: [0.13333, 0.63333, 0, 0, 0.89444], + 8855: [0.13333, 0.63333, 0, 0, 0.89444], + 8856: [0.13333, 0.63333, 0, 0, 0.89444], + 8857: [0.13333, 0.63333, 0, 0, 0.89444], + 8866: [0, 0.69444, 0, 0, 0.70277], + 8867: [0, 0.69444, 0, 0, 0.70277], + 8868: [0, 0.69444, 0, 0, 0.89444], + 8869: [0, 0.69444, 0, 0, 0.89444], + 8900: [-0.02639, 0.47361, 0, 0, 0.575], + 8901: [-0.02639, 0.47361, 0, 0, 0.31944], + 8902: [-0.02778, 0.47222, 0, 0, 0.575], + 8968: [0.25, 0.75, 0, 0, 0.51111], + 8969: [0.25, 0.75, 0, 0, 0.51111], + 8970: [0.25, 0.75, 0, 0, 0.51111], + 8971: [0.25, 0.75, 0, 0, 0.51111], + 8994: [-0.13889, 0.36111, 0, 0, 1.14999], + 8995: [-0.13889, 0.36111, 0, 0, 1.14999], + 9651: [0.19444, 0.69444, 0, 0, 1.02222], + 9657: [-0.02778, 0.47222, 0, 0, 0.575], + 9661: [0.19444, 0.69444, 0, 0, 1.02222], + 9667: [-0.02778, 0.47222, 0, 0, 0.575], + 9711: [0.19444, 0.69444, 0, 0, 1.14999], + 9824: [0.12963, 0.69444, 0, 0, 0.89444], + 9825: [0.12963, 0.69444, 0, 0, 0.89444], + 9826: [0.12963, 0.69444, 0, 0, 0.89444], + 9827: [0.12963, 0.69444, 0, 0, 0.89444], + 9837: [0, 0.75, 0, 0, 0.44722], + 9838: [0.19444, 0.69444, 0, 0, 0.44722], + 9839: [0.19444, 0.69444, 0, 0, 0.44722], + 10216: [0.25, 0.75, 0, 0, 0.44722], + 10217: [0.25, 0.75, 0, 0, 0.44722], + 10815: [0, 0.68611, 0, 0, 0.9], + 10927: [0.19667, 0.69667, 0, 0, 0.89444], + 10928: [0.19667, 0.69667, 0, 0, 0.89444], + 57376: [0.19444, 0.69444, 0, 0, 0] + }, + "Main-BoldItalic": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0.11417, 0, 0.38611], + 34: [0, 0.69444, 0.07939, 0, 0.62055], + 35: [0.19444, 0.69444, 0.06833, 0, 0.94444], + 37: [0.05556, 0.75, 0.12861, 0, 0.94444], + 38: [0, 0.69444, 0.08528, 0, 0.88555], + 39: [0, 0.69444, 0.12945, 0, 0.35555], + 40: [0.25, 0.75, 0.15806, 0, 0.47333], + 41: [0.25, 0.75, 0.03306, 0, 0.47333], + 42: [0, 0.75, 0.14333, 0, 0.59111], + 43: [0.10333, 0.60333, 0.03306, 0, 0.88555], + 44: [0.19444, 0.14722, 0, 0, 0.35555], + 45: [0, 0.44444, 0.02611, 0, 0.41444], + 46: [0, 0.14722, 0, 0, 0.35555], + 47: [0.25, 0.75, 0.15806, 0, 0.59111], + 48: [0, 0.64444, 0.13167, 0, 0.59111], + 49: [0, 0.64444, 0.13167, 0, 0.59111], + 50: [0, 0.64444, 0.13167, 0, 0.59111], + 51: [0, 0.64444, 0.13167, 0, 0.59111], + 52: [0.19444, 0.64444, 0.13167, 0, 0.59111], + 53: [0, 0.64444, 0.13167, 0, 0.59111], + 54: [0, 0.64444, 0.13167, 0, 0.59111], + 55: [0.19444, 0.64444, 0.13167, 0, 0.59111], + 56: [0, 0.64444, 0.13167, 0, 0.59111], + 57: [0, 0.64444, 0.13167, 0, 0.59111], + 58: [0, 0.44444, 0.06695, 0, 0.35555], + 59: [0.19444, 0.44444, 0.06695, 0, 0.35555], + 61: [-0.10889, 0.39111, 0.06833, 0, 0.88555], + 63: [0, 0.69444, 0.11472, 0, 0.59111], + 64: [0, 0.69444, 0.09208, 0, 0.88555], + 65: [0, 0.68611, 0, 0, 0.86555], + 66: [0, 0.68611, 0.0992, 0, 0.81666], + 67: [0, 0.68611, 0.14208, 0, 0.82666], + 68: [0, 0.68611, 0.09062, 0, 0.87555], + 69: [0, 0.68611, 0.11431, 0, 0.75666], + 70: [0, 0.68611, 0.12903, 0, 0.72722], + 71: [0, 0.68611, 0.07347, 0, 0.89527], + 72: [0, 0.68611, 0.17208, 0, 0.8961], + 73: [0, 0.68611, 0.15681, 0, 0.47166], + 74: [0, 0.68611, 0.145, 0, 0.61055], + 75: [0, 0.68611, 0.14208, 0, 0.89499], + 76: [0, 0.68611, 0, 0, 0.69777], + 77: [0, 0.68611, 0.17208, 0, 1.07277], + 78: [0, 0.68611, 0.17208, 0, 0.8961], + 79: [0, 0.68611, 0.09062, 0, 0.85499], + 80: [0, 0.68611, 0.0992, 0, 0.78721], + 81: [0.19444, 0.68611, 0.09062, 0, 0.85499], + 82: [0, 0.68611, 0.02559, 0, 0.85944], + 83: [0, 0.68611, 0.11264, 0, 0.64999], + 84: [0, 0.68611, 0.12903, 0, 0.7961], + 85: [0, 0.68611, 0.17208, 0, 0.88083], + 86: [0, 0.68611, 0.18625, 0, 0.86555], + 87: [0, 0.68611, 0.18625, 0, 1.15999], + 88: [0, 0.68611, 0.15681, 0, 0.86555], + 89: [0, 0.68611, 0.19803, 0, 0.86555], + 90: [0, 0.68611, 0.14208, 0, 0.70888], + 91: [0.25, 0.75, 0.1875, 0, 0.35611], + 93: [0.25, 0.75, 0.09972, 0, 0.35611], + 94: [0, 0.69444, 0.06709, 0, 0.59111], + 95: [0.31, 0.13444, 0.09811, 0, 0.59111], + 97: [0, 0.44444, 0.09426, 0, 0.59111], + 98: [0, 0.69444, 0.07861, 0, 0.53222], + 99: [0, 0.44444, 0.05222, 0, 0.53222], + 100: [0, 0.69444, 0.10861, 0, 0.59111], + 101: [0, 0.44444, 0.085, 0, 0.53222], + 102: [0.19444, 0.69444, 0.21778, 0, 0.4], + 103: [0.19444, 0.44444, 0.105, 0, 0.53222], + 104: [0, 0.69444, 0.09426, 0, 0.59111], + 105: [0, 0.69326, 0.11387, 0, 0.35555], + 106: [0.19444, 0.69326, 0.1672, 0, 0.35555], + 107: [0, 0.69444, 0.11111, 0, 0.53222], + 108: [0, 0.69444, 0.10861, 0, 0.29666], + 109: [0, 0.44444, 0.09426, 0, 0.94444], + 110: [0, 0.44444, 0.09426, 0, 0.64999], + 111: [0, 0.44444, 0.07861, 0, 0.59111], + 112: [0.19444, 0.44444, 0.07861, 0, 0.59111], + 113: [0.19444, 0.44444, 0.105, 0, 0.53222], + 114: [0, 0.44444, 0.11111, 0, 0.50167], + 115: [0, 0.44444, 0.08167, 0, 0.48694], + 116: [0, 0.63492, 0.09639, 0, 0.385], + 117: [0, 0.44444, 0.09426, 0, 0.62055], + 118: [0, 0.44444, 0.11111, 0, 0.53222], + 119: [0, 0.44444, 0.11111, 0, 0.76777], + 120: [0, 0.44444, 0.12583, 0, 0.56055], + 121: [0.19444, 0.44444, 0.105, 0, 0.56166], + 122: [0, 0.44444, 0.13889, 0, 0.49055], + 126: [0.35, 0.34444, 0.11472, 0, 0.59111], + 160: [0, 0, 0, 0, 0.25], + 168: [0, 0.69444, 0.11473, 0, 0.59111], + 176: [0, 0.69444, 0, 0, 0.94888], + 184: [0.17014, 0, 0, 0, 0.53222], + 198: [0, 0.68611, 0.11431, 0, 1.02277], + 216: [0.04861, 0.73472, 0.09062, 0, 0.88555], + 223: [0.19444, 0.69444, 0.09736, 0, 0.665], + 230: [0, 0.44444, 0.085, 0, 0.82666], + 248: [0.09722, 0.54167, 0.09458, 0, 0.59111], + 305: [0, 0.44444, 0.09426, 0, 0.35555], + 338: [0, 0.68611, 0.11431, 0, 1.14054], + 339: [0, 0.44444, 0.085, 0, 0.82666], + 567: [0.19444, 0.44444, 0.04611, 0, 0.385], + 710: [0, 0.69444, 0.06709, 0, 0.59111], + 711: [0, 0.63194, 0.08271, 0, 0.59111], + 713: [0, 0.59444, 0.10444, 0, 0.59111], + 714: [0, 0.69444, 0.08528, 0, 0.59111], + 715: [0, 0.69444, 0, 0, 0.59111], + 728: [0, 0.69444, 0.10333, 0, 0.59111], + 729: [0, 0.69444, 0.12945, 0, 0.35555], + 730: [0, 0.69444, 0, 0, 0.94888], + 732: [0, 0.69444, 0.11472, 0, 0.59111], + 733: [0, 0.69444, 0.11472, 0, 0.59111], + 915: [0, 0.68611, 0.12903, 0, 0.69777], + 916: [0, 0.68611, 0, 0, 0.94444], + 920: [0, 0.68611, 0.09062, 0, 0.88555], + 923: [0, 0.68611, 0, 0, 0.80666], + 926: [0, 0.68611, 0.15092, 0, 0.76777], + 928: [0, 0.68611, 0.17208, 0, 0.8961], + 931: [0, 0.68611, 0.11431, 0, 0.82666], + 933: [0, 0.68611, 0.10778, 0, 0.88555], + 934: [0, 0.68611, 0.05632, 0, 0.82666], + 936: [0, 0.68611, 0.10778, 0, 0.88555], + 937: [0, 0.68611, 0.0992, 0, 0.82666], + 8211: [0, 0.44444, 0.09811, 0, 0.59111], + 8212: [0, 0.44444, 0.09811, 0, 1.18221], + 8216: [0, 0.69444, 0.12945, 0, 0.35555], + 8217: [0, 0.69444, 0.12945, 0, 0.35555], + 8220: [0, 0.69444, 0.16772, 0, 0.62055], + 8221: [0, 0.69444, 0.07939, 0, 0.62055] + }, + "Main-Italic": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0.12417, 0, 0.30667], + 34: [0, 0.69444, 0.06961, 0, 0.51444], + 35: [0.19444, 0.69444, 0.06616, 0, 0.81777], + 37: [0.05556, 0.75, 0.13639, 0, 0.81777], + 38: [0, 0.69444, 0.09694, 0, 0.76666], + 39: [0, 0.69444, 0.12417, 0, 0.30667], + 40: [0.25, 0.75, 0.16194, 0, 0.40889], + 41: [0.25, 0.75, 0.03694, 0, 0.40889], + 42: [0, 0.75, 0.14917, 0, 0.51111], + 43: [0.05667, 0.56167, 0.03694, 0, 0.76666], + 44: [0.19444, 0.10556, 0, 0, 0.30667], + 45: [0, 0.43056, 0.02826, 0, 0.35778], + 46: [0, 0.10556, 0, 0, 0.30667], + 47: [0.25, 0.75, 0.16194, 0, 0.51111], + 48: [0, 0.64444, 0.13556, 0, 0.51111], + 49: [0, 0.64444, 0.13556, 0, 0.51111], + 50: [0, 0.64444, 0.13556, 0, 0.51111], + 51: [0, 0.64444, 0.13556, 0, 0.51111], + 52: [0.19444, 0.64444, 0.13556, 0, 0.51111], + 53: [0, 0.64444, 0.13556, 0, 0.51111], + 54: [0, 0.64444, 0.13556, 0, 0.51111], + 55: [0.19444, 0.64444, 0.13556, 0, 0.51111], + 56: [0, 0.64444, 0.13556, 0, 0.51111], + 57: [0, 0.64444, 0.13556, 0, 0.51111], + 58: [0, 0.43056, 0.0582, 0, 0.30667], + 59: [0.19444, 0.43056, 0.0582, 0, 0.30667], + 61: [-0.13313, 0.36687, 0.06616, 0, 0.76666], + 63: [0, 0.69444, 0.1225, 0, 0.51111], + 64: [0, 0.69444, 0.09597, 0, 0.76666], + 65: [0, 0.68333, 0, 0, 0.74333], + 66: [0, 0.68333, 0.10257, 0, 0.70389], + 67: [0, 0.68333, 0.14528, 0, 0.71555], + 68: [0, 0.68333, 0.09403, 0, 0.755], + 69: [0, 0.68333, 0.12028, 0, 0.67833], + 70: [0, 0.68333, 0.13305, 0, 0.65277], + 71: [0, 0.68333, 0.08722, 0, 0.77361], + 72: [0, 0.68333, 0.16389, 0, 0.74333], + 73: [0, 0.68333, 0.15806, 0, 0.38555], + 74: [0, 0.68333, 0.14028, 0, 0.525], + 75: [0, 0.68333, 0.14528, 0, 0.76888], + 76: [0, 0.68333, 0, 0, 0.62722], + 77: [0, 0.68333, 0.16389, 0, 0.89666], + 78: [0, 0.68333, 0.16389, 0, 0.74333], + 79: [0, 0.68333, 0.09403, 0, 0.76666], + 80: [0, 0.68333, 0.10257, 0, 0.67833], + 81: [0.19444, 0.68333, 0.09403, 0, 0.76666], + 82: [0, 0.68333, 0.03868, 0, 0.72944], + 83: [0, 0.68333, 0.11972, 0, 0.56222], + 84: [0, 0.68333, 0.13305, 0, 0.71555], + 85: [0, 0.68333, 0.16389, 0, 0.74333], + 86: [0, 0.68333, 0.18361, 0, 0.74333], + 87: [0, 0.68333, 0.18361, 0, 0.99888], + 88: [0, 0.68333, 0.15806, 0, 0.74333], + 89: [0, 0.68333, 0.19383, 0, 0.74333], + 90: [0, 0.68333, 0.14528, 0, 0.61333], + 91: [0.25, 0.75, 0.1875, 0, 0.30667], + 93: [0.25, 0.75, 0.10528, 0, 0.30667], + 94: [0, 0.69444, 0.06646, 0, 0.51111], + 95: [0.31, 0.12056, 0.09208, 0, 0.51111], + 97: [0, 0.43056, 0.07671, 0, 0.51111], + 98: [0, 0.69444, 0.06312, 0, 0.46], + 99: [0, 0.43056, 0.05653, 0, 0.46], + 100: [0, 0.69444, 0.10333, 0, 0.51111], + 101: [0, 0.43056, 0.07514, 0, 0.46], + 102: [0.19444, 0.69444, 0.21194, 0, 0.30667], + 103: [0.19444, 0.43056, 0.08847, 0, 0.46], + 104: [0, 0.69444, 0.07671, 0, 0.51111], + 105: [0, 0.65536, 0.1019, 0, 0.30667], + 106: [0.19444, 0.65536, 0.14467, 0, 0.30667], + 107: [0, 0.69444, 0.10764, 0, 0.46], + 108: [0, 0.69444, 0.10333, 0, 0.25555], + 109: [0, 0.43056, 0.07671, 0, 0.81777], + 110: [0, 0.43056, 0.07671, 0, 0.56222], + 111: [0, 0.43056, 0.06312, 0, 0.51111], + 112: [0.19444, 0.43056, 0.06312, 0, 0.51111], + 113: [0.19444, 0.43056, 0.08847, 0, 0.46], + 114: [0, 0.43056, 0.10764, 0, 0.42166], + 115: [0, 0.43056, 0.08208, 0, 0.40889], + 116: [0, 0.61508, 0.09486, 0, 0.33222], + 117: [0, 0.43056, 0.07671, 0, 0.53666], + 118: [0, 0.43056, 0.10764, 0, 0.46], + 119: [0, 0.43056, 0.10764, 0, 0.66444], + 120: [0, 0.43056, 0.12042, 0, 0.46389], + 121: [0.19444, 0.43056, 0.08847, 0, 0.48555], + 122: [0, 0.43056, 0.12292, 0, 0.40889], + 126: [0.35, 0.31786, 0.11585, 0, 0.51111], + 160: [0, 0, 0, 0, 0.25], + 168: [0, 0.66786, 0.10474, 0, 0.51111], + 176: [0, 0.69444, 0, 0, 0.83129], + 184: [0.17014, 0, 0, 0, 0.46], + 198: [0, 0.68333, 0.12028, 0, 0.88277], + 216: [0.04861, 0.73194, 0.09403, 0, 0.76666], + 223: [0.19444, 0.69444, 0.10514, 0, 0.53666], + 230: [0, 0.43056, 0.07514, 0, 0.71555], + 248: [0.09722, 0.52778, 0.09194, 0, 0.51111], + 338: [0, 0.68333, 0.12028, 0, 0.98499], + 339: [0, 0.43056, 0.07514, 0, 0.71555], + 710: [0, 0.69444, 0.06646, 0, 0.51111], + 711: [0, 0.62847, 0.08295, 0, 0.51111], + 713: [0, 0.56167, 0.10333, 0, 0.51111], + 714: [0, 0.69444, 0.09694, 0, 0.51111], + 715: [0, 0.69444, 0, 0, 0.51111], + 728: [0, 0.69444, 0.10806, 0, 0.51111], + 729: [0, 0.66786, 0.11752, 0, 0.30667], + 730: [0, 0.69444, 0, 0, 0.83129], + 732: [0, 0.66786, 0.11585, 0, 0.51111], + 733: [0, 0.69444, 0.1225, 0, 0.51111], + 915: [0, 0.68333, 0.13305, 0, 0.62722], + 916: [0, 0.68333, 0, 0, 0.81777], + 920: [0, 0.68333, 0.09403, 0, 0.76666], + 923: [0, 0.68333, 0, 0, 0.69222], + 926: [0, 0.68333, 0.15294, 0, 0.66444], + 928: [0, 0.68333, 0.16389, 0, 0.74333], + 931: [0, 0.68333, 0.12028, 0, 0.71555], + 933: [0, 0.68333, 0.11111, 0, 0.76666], + 934: [0, 0.68333, 0.05986, 0, 0.71555], + 936: [0, 0.68333, 0.11111, 0, 0.76666], + 937: [0, 0.68333, 0.10257, 0, 0.71555], + 8211: [0, 0.43056, 0.09208, 0, 0.51111], + 8212: [0, 0.43056, 0.09208, 0, 1.02222], + 8216: [0, 0.69444, 0.12417, 0, 0.30667], + 8217: [0, 0.69444, 0.12417, 0, 0.30667], + 8220: [0, 0.69444, 0.1685, 0, 0.51444], + 8221: [0, 0.69444, 0.06961, 0, 0.51444], + 8463: [0, 0.68889, 0, 0, 0.54028] + }, + "Main-Regular": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0, 0, 0.27778], + 34: [0, 0.69444, 0, 0, 0.5], + 35: [0.19444, 0.69444, 0, 0, 0.83334], + 36: [0.05556, 0.75, 0, 0, 0.5], + 37: [0.05556, 0.75, 0, 0, 0.83334], + 38: [0, 0.69444, 0, 0, 0.77778], + 39: [0, 0.69444, 0, 0, 0.27778], + 40: [0.25, 0.75, 0, 0, 0.38889], + 41: [0.25, 0.75, 0, 0, 0.38889], + 42: [0, 0.75, 0, 0, 0.5], + 43: [0.08333, 0.58333, 0, 0, 0.77778], + 44: [0.19444, 0.10556, 0, 0, 0.27778], + 45: [0, 0.43056, 0, 0, 0.33333], + 46: [0, 0.10556, 0, 0, 0.27778], + 47: [0.25, 0.75, 0, 0, 0.5], + 48: [0, 0.64444, 0, 0, 0.5], + 49: [0, 0.64444, 0, 0, 0.5], + 50: [0, 0.64444, 0, 0, 0.5], + 51: [0, 0.64444, 0, 0, 0.5], + 52: [0, 0.64444, 0, 0, 0.5], + 53: [0, 0.64444, 0, 0, 0.5], + 54: [0, 0.64444, 0, 0, 0.5], + 55: [0, 0.64444, 0, 0, 0.5], + 56: [0, 0.64444, 0, 0, 0.5], + 57: [0, 0.64444, 0, 0, 0.5], + 58: [0, 0.43056, 0, 0, 0.27778], + 59: [0.19444, 0.43056, 0, 0, 0.27778], + 60: [0.0391, 0.5391, 0, 0, 0.77778], + 61: [-0.13313, 0.36687, 0, 0, 0.77778], + 62: [0.0391, 0.5391, 0, 0, 0.77778], + 63: [0, 0.69444, 0, 0, 0.47222], + 64: [0, 0.69444, 0, 0, 0.77778], + 65: [0, 0.68333, 0, 0, 0.75], + 66: [0, 0.68333, 0, 0, 0.70834], + 67: [0, 0.68333, 0, 0, 0.72222], + 68: [0, 0.68333, 0, 0, 0.76389], + 69: [0, 0.68333, 0, 0, 0.68056], + 70: [0, 0.68333, 0, 0, 0.65278], + 71: [0, 0.68333, 0, 0, 0.78472], + 72: [0, 0.68333, 0, 0, 0.75], + 73: [0, 0.68333, 0, 0, 0.36111], + 74: [0, 0.68333, 0, 0, 0.51389], + 75: [0, 0.68333, 0, 0, 0.77778], + 76: [0, 0.68333, 0, 0, 0.625], + 77: [0, 0.68333, 0, 0, 0.91667], + 78: [0, 0.68333, 0, 0, 0.75], + 79: [0, 0.68333, 0, 0, 0.77778], + 80: [0, 0.68333, 0, 0, 0.68056], + 81: [0.19444, 0.68333, 0, 0, 0.77778], + 82: [0, 0.68333, 0, 0, 0.73611], + 83: [0, 0.68333, 0, 0, 0.55556], + 84: [0, 0.68333, 0, 0, 0.72222], + 85: [0, 0.68333, 0, 0, 0.75], + 86: [0, 0.68333, 0.01389, 0, 0.75], + 87: [0, 0.68333, 0.01389, 0, 1.02778], + 88: [0, 0.68333, 0, 0, 0.75], + 89: [0, 0.68333, 0.025, 0, 0.75], + 90: [0, 0.68333, 0, 0, 0.61111], + 91: [0.25, 0.75, 0, 0, 0.27778], + 92: [0.25, 0.75, 0, 0, 0.5], + 93: [0.25, 0.75, 0, 0, 0.27778], + 94: [0, 0.69444, 0, 0, 0.5], + 95: [0.31, 0.12056, 0.02778, 0, 0.5], + 97: [0, 0.43056, 0, 0, 0.5], + 98: [0, 0.69444, 0, 0, 0.55556], + 99: [0, 0.43056, 0, 0, 0.44445], + 100: [0, 0.69444, 0, 0, 0.55556], + 101: [0, 0.43056, 0, 0, 0.44445], + 102: [0, 0.69444, 0.07778, 0, 0.30556], + 103: [0.19444, 0.43056, 0.01389, 0, 0.5], + 104: [0, 0.69444, 0, 0, 0.55556], + 105: [0, 0.66786, 0, 0, 0.27778], + 106: [0.19444, 0.66786, 0, 0, 0.30556], + 107: [0, 0.69444, 0, 0, 0.52778], + 108: [0, 0.69444, 0, 0, 0.27778], + 109: [0, 0.43056, 0, 0, 0.83334], + 110: [0, 0.43056, 0, 0, 0.55556], + 111: [0, 0.43056, 0, 0, 0.5], + 112: [0.19444, 0.43056, 0, 0, 0.55556], + 113: [0.19444, 0.43056, 0, 0, 0.52778], + 114: [0, 0.43056, 0, 0, 0.39167], + 115: [0, 0.43056, 0, 0, 0.39445], + 116: [0, 0.61508, 0, 0, 0.38889], + 117: [0, 0.43056, 0, 0, 0.55556], + 118: [0, 0.43056, 0.01389, 0, 0.52778], + 119: [0, 0.43056, 0.01389, 0, 0.72222], + 120: [0, 0.43056, 0, 0, 0.52778], + 121: [0.19444, 0.43056, 0.01389, 0, 0.52778], + 122: [0, 0.43056, 0, 0, 0.44445], + 123: [0.25, 0.75, 0, 0, 0.5], + 124: [0.25, 0.75, 0, 0, 0.27778], + 125: [0.25, 0.75, 0, 0, 0.5], + 126: [0.35, 0.31786, 0, 0, 0.5], + 160: [0, 0, 0, 0, 0.25], + 163: [0, 0.69444, 0, 0, 0.76909], + 167: [0.19444, 0.69444, 0, 0, 0.44445], + 168: [0, 0.66786, 0, 0, 0.5], + 172: [0, 0.43056, 0, 0, 0.66667], + 176: [0, 0.69444, 0, 0, 0.75], + 177: [0.08333, 0.58333, 0, 0, 0.77778], + 182: [0.19444, 0.69444, 0, 0, 0.61111], + 184: [0.17014, 0, 0, 0, 0.44445], + 198: [0, 0.68333, 0, 0, 0.90278], + 215: [0.08333, 0.58333, 0, 0, 0.77778], + 216: [0.04861, 0.73194, 0, 0, 0.77778], + 223: [0, 0.69444, 0, 0, 0.5], + 230: [0, 0.43056, 0, 0, 0.72222], + 247: [0.08333, 0.58333, 0, 0, 0.77778], + 248: [0.09722, 0.52778, 0, 0, 0.5], + 305: [0, 0.43056, 0, 0, 0.27778], + 338: [0, 0.68333, 0, 0, 1.01389], + 339: [0, 0.43056, 0, 0, 0.77778], + 567: [0.19444, 0.43056, 0, 0, 0.30556], + 710: [0, 0.69444, 0, 0, 0.5], + 711: [0, 0.62847, 0, 0, 0.5], + 713: [0, 0.56778, 0, 0, 0.5], + 714: [0, 0.69444, 0, 0, 0.5], + 715: [0, 0.69444, 0, 0, 0.5], + 728: [0, 0.69444, 0, 0, 0.5], + 729: [0, 0.66786, 0, 0, 0.27778], + 730: [0, 0.69444, 0, 0, 0.75], + 732: [0, 0.66786, 0, 0, 0.5], + 733: [0, 0.69444, 0, 0, 0.5], + 915: [0, 0.68333, 0, 0, 0.625], + 916: [0, 0.68333, 0, 0, 0.83334], + 920: [0, 0.68333, 0, 0, 0.77778], + 923: [0, 0.68333, 0, 0, 0.69445], + 926: [0, 0.68333, 0, 0, 0.66667], + 928: [0, 0.68333, 0, 0, 0.75], + 931: [0, 0.68333, 0, 0, 0.72222], + 933: [0, 0.68333, 0, 0, 0.77778], + 934: [0, 0.68333, 0, 0, 0.72222], + 936: [0, 0.68333, 0, 0, 0.77778], + 937: [0, 0.68333, 0, 0, 0.72222], + 8211: [0, 0.43056, 0.02778, 0, 0.5], + 8212: [0, 0.43056, 0.02778, 0, 1], + 8216: [0, 0.69444, 0, 0, 0.27778], + 8217: [0, 0.69444, 0, 0, 0.27778], + 8220: [0, 0.69444, 0, 0, 0.5], + 8221: [0, 0.69444, 0, 0, 0.5], + 8224: [0.19444, 0.69444, 0, 0, 0.44445], + 8225: [0.19444, 0.69444, 0, 0, 0.44445], + 8230: [0, 0.123, 0, 0, 1.172], + 8242: [0, 0.55556, 0, 0, 0.275], + 8407: [0, 0.71444, 0.15382, 0, 0.5], + 8463: [0, 0.68889, 0, 0, 0.54028], + 8465: [0, 0.69444, 0, 0, 0.72222], + 8467: [0, 0.69444, 0, 0.11111, 0.41667], + 8472: [0.19444, 0.43056, 0, 0.11111, 0.63646], + 8476: [0, 0.69444, 0, 0, 0.72222], + 8501: [0, 0.69444, 0, 0, 0.61111], + 8592: [-0.13313, 0.36687, 0, 0, 1], + 8593: [0.19444, 0.69444, 0, 0, 0.5], + 8594: [-0.13313, 0.36687, 0, 0, 1], + 8595: [0.19444, 0.69444, 0, 0, 0.5], + 8596: [-0.13313, 0.36687, 0, 0, 1], + 8597: [0.25, 0.75, 0, 0, 0.5], + 8598: [0.19444, 0.69444, 0, 0, 1], + 8599: [0.19444, 0.69444, 0, 0, 1], + 8600: [0.19444, 0.69444, 0, 0, 1], + 8601: [0.19444, 0.69444, 0, 0, 1], + 8614: [0.011, 0.511, 0, 0, 1], + 8617: [0.011, 0.511, 0, 0, 1.126], + 8618: [0.011, 0.511, 0, 0, 1.126], + 8636: [-0.13313, 0.36687, 0, 0, 1], + 8637: [-0.13313, 0.36687, 0, 0, 1], + 8640: [-0.13313, 0.36687, 0, 0, 1], + 8641: [-0.13313, 0.36687, 0, 0, 1], + 8652: [0.011, 0.671, 0, 0, 1], + 8656: [-0.13313, 0.36687, 0, 0, 1], + 8657: [0.19444, 0.69444, 0, 0, 0.61111], + 8658: [-0.13313, 0.36687, 0, 0, 1], + 8659: [0.19444, 0.69444, 0, 0, 0.61111], + 8660: [-0.13313, 0.36687, 0, 0, 1], + 8661: [0.25, 0.75, 0, 0, 0.61111], + 8704: [0, 0.69444, 0, 0, 0.55556], + 8706: [0, 0.69444, 0.05556, 0.08334, 0.5309], + 8707: [0, 0.69444, 0, 0, 0.55556], + 8709: [0.05556, 0.75, 0, 0, 0.5], + 8711: [0, 0.68333, 0, 0, 0.83334], + 8712: [0.0391, 0.5391, 0, 0, 0.66667], + 8715: [0.0391, 0.5391, 0, 0, 0.66667], + 8722: [0.08333, 0.58333, 0, 0, 0.77778], + 8723: [0.08333, 0.58333, 0, 0, 0.77778], + 8725: [0.25, 0.75, 0, 0, 0.5], + 8726: [0.25, 0.75, 0, 0, 0.5], + 8727: [-0.03472, 0.46528, 0, 0, 0.5], + 8728: [-0.05555, 0.44445, 0, 0, 0.5], + 8729: [-0.05555, 0.44445, 0, 0, 0.5], + 8730: [0.2, 0.8, 0, 0, 0.83334], + 8733: [0, 0.43056, 0, 0, 0.77778], + 8734: [0, 0.43056, 0, 0, 1], + 8736: [0, 0.69224, 0, 0, 0.72222], + 8739: [0.25, 0.75, 0, 0, 0.27778], + 8741: [0.25, 0.75, 0, 0, 0.5], + 8743: [0, 0.55556, 0, 0, 0.66667], + 8744: [0, 0.55556, 0, 0, 0.66667], + 8745: [0, 0.55556, 0, 0, 0.66667], + 8746: [0, 0.55556, 0, 0, 0.66667], + 8747: [0.19444, 0.69444, 0.11111, 0, 0.41667], + 8764: [-0.13313, 0.36687, 0, 0, 0.77778], + 8768: [0.19444, 0.69444, 0, 0, 0.27778], + 8771: [-0.03625, 0.46375, 0, 0, 0.77778], + 8773: [-0.022, 0.589, 0, 0, 0.778], + 8776: [-0.01688, 0.48312, 0, 0, 0.77778], + 8781: [-0.03625, 0.46375, 0, 0, 0.77778], + 8784: [-0.133, 0.673, 0, 0, 0.778], + 8801: [-0.03625, 0.46375, 0, 0, 0.77778], + 8804: [0.13597, 0.63597, 0, 0, 0.77778], + 8805: [0.13597, 0.63597, 0, 0, 0.77778], + 8810: [0.0391, 0.5391, 0, 0, 1], + 8811: [0.0391, 0.5391, 0, 0, 1], + 8826: [0.0391, 0.5391, 0, 0, 0.77778], + 8827: [0.0391, 0.5391, 0, 0, 0.77778], + 8834: [0.0391, 0.5391, 0, 0, 0.77778], + 8835: [0.0391, 0.5391, 0, 0, 0.77778], + 8838: [0.13597, 0.63597, 0, 0, 0.77778], + 8839: [0.13597, 0.63597, 0, 0, 0.77778], + 8846: [0, 0.55556, 0, 0, 0.66667], + 8849: [0.13597, 0.63597, 0, 0, 0.77778], + 8850: [0.13597, 0.63597, 0, 0, 0.77778], + 8851: [0, 0.55556, 0, 0, 0.66667], + 8852: [0, 0.55556, 0, 0, 0.66667], + 8853: [0.08333, 0.58333, 0, 0, 0.77778], + 8854: [0.08333, 0.58333, 0, 0, 0.77778], + 8855: [0.08333, 0.58333, 0, 0, 0.77778], + 8856: [0.08333, 0.58333, 0, 0, 0.77778], + 8857: [0.08333, 0.58333, 0, 0, 0.77778], + 8866: [0, 0.69444, 0, 0, 0.61111], + 8867: [0, 0.69444, 0, 0, 0.61111], + 8868: [0, 0.69444, 0, 0, 0.77778], + 8869: [0, 0.69444, 0, 0, 0.77778], + 8872: [0.249, 0.75, 0, 0, 0.867], + 8900: [-0.05555, 0.44445, 0, 0, 0.5], + 8901: [-0.05555, 0.44445, 0, 0, 0.27778], + 8902: [-0.03472, 0.46528, 0, 0, 0.5], + 8904: [5e-3, 0.505, 0, 0, 0.9], + 8942: [0.03, 0.903, 0, 0, 0.278], + 8943: [-0.19, 0.313, 0, 0, 1.172], + 8945: [-0.1, 0.823, 0, 0, 1.282], + 8968: [0.25, 0.75, 0, 0, 0.44445], + 8969: [0.25, 0.75, 0, 0, 0.44445], + 8970: [0.25, 0.75, 0, 0, 0.44445], + 8971: [0.25, 0.75, 0, 0, 0.44445], + 8994: [-0.14236, 0.35764, 0, 0, 1], + 8995: [-0.14236, 0.35764, 0, 0, 1], + 9136: [0.244, 0.744, 0, 0, 0.412], + 9137: [0.244, 0.745, 0, 0, 0.412], + 9651: [0.19444, 0.69444, 0, 0, 0.88889], + 9657: [-0.03472, 0.46528, 0, 0, 0.5], + 9661: [0.19444, 0.69444, 0, 0, 0.88889], + 9667: [-0.03472, 0.46528, 0, 0, 0.5], + 9711: [0.19444, 0.69444, 0, 0, 1], + 9824: [0.12963, 0.69444, 0, 0, 0.77778], + 9825: [0.12963, 0.69444, 0, 0, 0.77778], + 9826: [0.12963, 0.69444, 0, 0, 0.77778], + 9827: [0.12963, 0.69444, 0, 0, 0.77778], + 9837: [0, 0.75, 0, 0, 0.38889], + 9838: [0.19444, 0.69444, 0, 0, 0.38889], + 9839: [0.19444, 0.69444, 0, 0, 0.38889], + 10216: [0.25, 0.75, 0, 0, 0.38889], + 10217: [0.25, 0.75, 0, 0, 0.38889], + 10222: [0.244, 0.744, 0, 0, 0.412], + 10223: [0.244, 0.745, 0, 0, 0.412], + 10229: [0.011, 0.511, 0, 0, 1.609], + 10230: [0.011, 0.511, 0, 0, 1.638], + 10231: [0.011, 0.511, 0, 0, 1.859], + 10232: [0.024, 0.525, 0, 0, 1.609], + 10233: [0.024, 0.525, 0, 0, 1.638], + 10234: [0.024, 0.525, 0, 0, 1.858], + 10236: [0.011, 0.511, 0, 0, 1.638], + 10815: [0, 0.68333, 0, 0, 0.75], + 10927: [0.13597, 0.63597, 0, 0, 0.77778], + 10928: [0.13597, 0.63597, 0, 0, 0.77778], + 57376: [0.19444, 0.69444, 0, 0, 0] + }, + "Math-BoldItalic": { + 32: [0, 0, 0, 0, 0.25], + 48: [0, 0.44444, 0, 0, 0.575], + 49: [0, 0.44444, 0, 0, 0.575], + 50: [0, 0.44444, 0, 0, 0.575], + 51: [0.19444, 0.44444, 0, 0, 0.575], + 52: [0.19444, 0.44444, 0, 0, 0.575], + 53: [0.19444, 0.44444, 0, 0, 0.575], + 54: [0, 0.64444, 0, 0, 0.575], + 55: [0.19444, 0.44444, 0, 0, 0.575], + 56: [0, 0.64444, 0, 0, 0.575], + 57: [0.19444, 0.44444, 0, 0, 0.575], + 65: [0, 0.68611, 0, 0, 0.86944], + 66: [0, 0.68611, 0.04835, 0, 0.8664], + 67: [0, 0.68611, 0.06979, 0, 0.81694], + 68: [0, 0.68611, 0.03194, 0, 0.93812], + 69: [0, 0.68611, 0.05451, 0, 0.81007], + 70: [0, 0.68611, 0.15972, 0, 0.68889], + 71: [0, 0.68611, 0, 0, 0.88673], + 72: [0, 0.68611, 0.08229, 0, 0.98229], + 73: [0, 0.68611, 0.07778, 0, 0.51111], + 74: [0, 0.68611, 0.10069, 0, 0.63125], + 75: [0, 0.68611, 0.06979, 0, 0.97118], + 76: [0, 0.68611, 0, 0, 0.75555], + 77: [0, 0.68611, 0.11424, 0, 1.14201], + 78: [0, 0.68611, 0.11424, 0, 0.95034], + 79: [0, 0.68611, 0.03194, 0, 0.83666], + 80: [0, 0.68611, 0.15972, 0, 0.72309], + 81: [0.19444, 0.68611, 0, 0, 0.86861], + 82: [0, 0.68611, 421e-5, 0, 0.87235], + 83: [0, 0.68611, 0.05382, 0, 0.69271], + 84: [0, 0.68611, 0.15972, 0, 0.63663], + 85: [0, 0.68611, 0.11424, 0, 0.80027], + 86: [0, 0.68611, 0.25555, 0, 0.67778], + 87: [0, 0.68611, 0.15972, 0, 1.09305], + 88: [0, 0.68611, 0.07778, 0, 0.94722], + 89: [0, 0.68611, 0.25555, 0, 0.67458], + 90: [0, 0.68611, 0.06979, 0, 0.77257], + 97: [0, 0.44444, 0, 0, 0.63287], + 98: [0, 0.69444, 0, 0, 0.52083], + 99: [0, 0.44444, 0, 0, 0.51342], + 100: [0, 0.69444, 0, 0, 0.60972], + 101: [0, 0.44444, 0, 0, 0.55361], + 102: [0.19444, 0.69444, 0.11042, 0, 0.56806], + 103: [0.19444, 0.44444, 0.03704, 0, 0.5449], + 104: [0, 0.69444, 0, 0, 0.66759], + 105: [0, 0.69326, 0, 0, 0.4048], + 106: [0.19444, 0.69326, 0.0622, 0, 0.47083], + 107: [0, 0.69444, 0.01852, 0, 0.6037], + 108: [0, 0.69444, 88e-4, 0, 0.34815], + 109: [0, 0.44444, 0, 0, 1.0324], + 110: [0, 0.44444, 0, 0, 0.71296], + 111: [0, 0.44444, 0, 0, 0.58472], + 112: [0.19444, 0.44444, 0, 0, 0.60092], + 113: [0.19444, 0.44444, 0.03704, 0, 0.54213], + 114: [0, 0.44444, 0.03194, 0, 0.5287], + 115: [0, 0.44444, 0, 0, 0.53125], + 116: [0, 0.63492, 0, 0, 0.41528], + 117: [0, 0.44444, 0, 0, 0.68102], + 118: [0, 0.44444, 0.03704, 0, 0.56666], + 119: [0, 0.44444, 0.02778, 0, 0.83148], + 120: [0, 0.44444, 0, 0, 0.65903], + 121: [0.19444, 0.44444, 0.03704, 0, 0.59028], + 122: [0, 0.44444, 0.04213, 0, 0.55509], + 160: [0, 0, 0, 0, 0.25], + 915: [0, 0.68611, 0.15972, 0, 0.65694], + 916: [0, 0.68611, 0, 0, 0.95833], + 920: [0, 0.68611, 0.03194, 0, 0.86722], + 923: [0, 0.68611, 0, 0, 0.80555], + 926: [0, 0.68611, 0.07458, 0, 0.84125], + 928: [0, 0.68611, 0.08229, 0, 0.98229], + 931: [0, 0.68611, 0.05451, 0, 0.88507], + 933: [0, 0.68611, 0.15972, 0, 0.67083], + 934: [0, 0.68611, 0, 0, 0.76666], + 936: [0, 0.68611, 0.11653, 0, 0.71402], + 937: [0, 0.68611, 0.04835, 0, 0.8789], + 945: [0, 0.44444, 0, 0, 0.76064], + 946: [0.19444, 0.69444, 0.03403, 0, 0.65972], + 947: [0.19444, 0.44444, 0.06389, 0, 0.59003], + 948: [0, 0.69444, 0.03819, 0, 0.52222], + 949: [0, 0.44444, 0, 0, 0.52882], + 950: [0.19444, 0.69444, 0.06215, 0, 0.50833], + 951: [0.19444, 0.44444, 0.03704, 0, 0.6], + 952: [0, 0.69444, 0.03194, 0, 0.5618], + 953: [0, 0.44444, 0, 0, 0.41204], + 954: [0, 0.44444, 0, 0, 0.66759], + 955: [0, 0.69444, 0, 0, 0.67083], + 956: [0.19444, 0.44444, 0, 0, 0.70787], + 957: [0, 0.44444, 0.06898, 0, 0.57685], + 958: [0.19444, 0.69444, 0.03021, 0, 0.50833], + 959: [0, 0.44444, 0, 0, 0.58472], + 960: [0, 0.44444, 0.03704, 0, 0.68241], + 961: [0.19444, 0.44444, 0, 0, 0.6118], + 962: [0.09722, 0.44444, 0.07917, 0, 0.42361], + 963: [0, 0.44444, 0.03704, 0, 0.68588], + 964: [0, 0.44444, 0.13472, 0, 0.52083], + 965: [0, 0.44444, 0.03704, 0, 0.63055], + 966: [0.19444, 0.44444, 0, 0, 0.74722], + 967: [0.19444, 0.44444, 0, 0, 0.71805], + 968: [0.19444, 0.69444, 0.03704, 0, 0.75833], + 969: [0, 0.44444, 0.03704, 0, 0.71782], + 977: [0, 0.69444, 0, 0, 0.69155], + 981: [0.19444, 0.69444, 0, 0, 0.7125], + 982: [0, 0.44444, 0.03194, 0, 0.975], + 1009: [0.19444, 0.44444, 0, 0, 0.6118], + 1013: [0, 0.44444, 0, 0, 0.48333], + 57649: [0, 0.44444, 0, 0, 0.39352], + 57911: [0.19444, 0.44444, 0, 0, 0.43889] + }, + "Math-Italic": { + 32: [0, 0, 0, 0, 0.25], + 48: [0, 0.43056, 0, 0, 0.5], + 49: [0, 0.43056, 0, 0, 0.5], + 50: [0, 0.43056, 0, 0, 0.5], + 51: [0.19444, 0.43056, 0, 0, 0.5], + 52: [0.19444, 0.43056, 0, 0, 0.5], + 53: [0.19444, 0.43056, 0, 0, 0.5], + 54: [0, 0.64444, 0, 0, 0.5], + 55: [0.19444, 0.43056, 0, 0, 0.5], + 56: [0, 0.64444, 0, 0, 0.5], + 57: [0.19444, 0.43056, 0, 0, 0.5], + 65: [0, 0.68333, 0, 0.13889, 0.75], + 66: [0, 0.68333, 0.05017, 0.08334, 0.75851], + 67: [0, 0.68333, 0.07153, 0.08334, 0.71472], + 68: [0, 0.68333, 0.02778, 0.05556, 0.82792], + 69: [0, 0.68333, 0.05764, 0.08334, 0.7382], + 70: [0, 0.68333, 0.13889, 0.08334, 0.64306], + 71: [0, 0.68333, 0, 0.08334, 0.78625], + 72: [0, 0.68333, 0.08125, 0.05556, 0.83125], + 73: [0, 0.68333, 0.07847, 0.11111, 0.43958], + 74: [0, 0.68333, 0.09618, 0.16667, 0.55451], + 75: [0, 0.68333, 0.07153, 0.05556, 0.84931], + 76: [0, 0.68333, 0, 0.02778, 0.68056], + 77: [0, 0.68333, 0.10903, 0.08334, 0.97014], + 78: [0, 0.68333, 0.10903, 0.08334, 0.80347], + 79: [0, 0.68333, 0.02778, 0.08334, 0.76278], + 80: [0, 0.68333, 0.13889, 0.08334, 0.64201], + 81: [0.19444, 0.68333, 0, 0.08334, 0.79056], + 82: [0, 0.68333, 773e-5, 0.08334, 0.75929], + 83: [0, 0.68333, 0.05764, 0.08334, 0.6132], + 84: [0, 0.68333, 0.13889, 0.08334, 0.58438], + 85: [0, 0.68333, 0.10903, 0.02778, 0.68278], + 86: [0, 0.68333, 0.22222, 0, 0.58333], + 87: [0, 0.68333, 0.13889, 0, 0.94445], + 88: [0, 0.68333, 0.07847, 0.08334, 0.82847], + 89: [0, 0.68333, 0.22222, 0, 0.58056], + 90: [0, 0.68333, 0.07153, 0.08334, 0.68264], + 97: [0, 0.43056, 0, 0, 0.52859], + 98: [0, 0.69444, 0, 0, 0.42917], + 99: [0, 0.43056, 0, 0.05556, 0.43276], + 100: [0, 0.69444, 0, 0.16667, 0.52049], + 101: [0, 0.43056, 0, 0.05556, 0.46563], + 102: [0.19444, 0.69444, 0.10764, 0.16667, 0.48959], + 103: [0.19444, 0.43056, 0.03588, 0.02778, 0.47697], + 104: [0, 0.69444, 0, 0, 0.57616], + 105: [0, 0.65952, 0, 0, 0.34451], + 106: [0.19444, 0.65952, 0.05724, 0, 0.41181], + 107: [0, 0.69444, 0.03148, 0, 0.5206], + 108: [0, 0.69444, 0.01968, 0.08334, 0.29838], + 109: [0, 0.43056, 0, 0, 0.87801], + 110: [0, 0.43056, 0, 0, 0.60023], + 111: [0, 0.43056, 0, 0.05556, 0.48472], + 112: [0.19444, 0.43056, 0, 0.08334, 0.50313], + 113: [0.19444, 0.43056, 0.03588, 0.08334, 0.44641], + 114: [0, 0.43056, 0.02778, 0.05556, 0.45116], + 115: [0, 0.43056, 0, 0.05556, 0.46875], + 116: [0, 0.61508, 0, 0.08334, 0.36111], + 117: [0, 0.43056, 0, 0.02778, 0.57246], + 118: [0, 0.43056, 0.03588, 0.02778, 0.48472], + 119: [0, 0.43056, 0.02691, 0.08334, 0.71592], + 120: [0, 0.43056, 0, 0.02778, 0.57153], + 121: [0.19444, 0.43056, 0.03588, 0.05556, 0.49028], + 122: [0, 0.43056, 0.04398, 0.05556, 0.46505], + 160: [0, 0, 0, 0, 0.25], + 915: [0, 0.68333, 0.13889, 0.08334, 0.61528], + 916: [0, 0.68333, 0, 0.16667, 0.83334], + 920: [0, 0.68333, 0.02778, 0.08334, 0.76278], + 923: [0, 0.68333, 0, 0.16667, 0.69445], + 926: [0, 0.68333, 0.07569, 0.08334, 0.74236], + 928: [0, 0.68333, 0.08125, 0.05556, 0.83125], + 931: [0, 0.68333, 0.05764, 0.08334, 0.77986], + 933: [0, 0.68333, 0.13889, 0.05556, 0.58333], + 934: [0, 0.68333, 0, 0.08334, 0.66667], + 936: [0, 0.68333, 0.11, 0.05556, 0.61222], + 937: [0, 0.68333, 0.05017, 0.08334, 0.7724], + 945: [0, 0.43056, 37e-4, 0.02778, 0.6397], + 946: [0.19444, 0.69444, 0.05278, 0.08334, 0.56563], + 947: [0.19444, 0.43056, 0.05556, 0, 0.51773], + 948: [0, 0.69444, 0.03785, 0.05556, 0.44444], + 949: [0, 0.43056, 0, 0.08334, 0.46632], + 950: [0.19444, 0.69444, 0.07378, 0.08334, 0.4375], + 951: [0.19444, 0.43056, 0.03588, 0.05556, 0.49653], + 952: [0, 0.69444, 0.02778, 0.08334, 0.46944], + 953: [0, 0.43056, 0, 0.05556, 0.35394], + 954: [0, 0.43056, 0, 0, 0.57616], + 955: [0, 0.69444, 0, 0, 0.58334], + 956: [0.19444, 0.43056, 0, 0.02778, 0.60255], + 957: [0, 0.43056, 0.06366, 0.02778, 0.49398], + 958: [0.19444, 0.69444, 0.04601, 0.11111, 0.4375], + 959: [0, 0.43056, 0, 0.05556, 0.48472], + 960: [0, 0.43056, 0.03588, 0, 0.57003], + 961: [0.19444, 0.43056, 0, 0.08334, 0.51702], + 962: [0.09722, 0.43056, 0.07986, 0.08334, 0.36285], + 963: [0, 0.43056, 0.03588, 0, 0.57141], + 964: [0, 0.43056, 0.1132, 0.02778, 0.43715], + 965: [0, 0.43056, 0.03588, 0.02778, 0.54028], + 966: [0.19444, 0.43056, 0, 0.08334, 0.65417], + 967: [0.19444, 0.43056, 0, 0.05556, 0.62569], + 968: [0.19444, 0.69444, 0.03588, 0.11111, 0.65139], + 969: [0, 0.43056, 0.03588, 0, 0.62245], + 977: [0, 0.69444, 0, 0.08334, 0.59144], + 981: [0.19444, 0.69444, 0, 0.08334, 0.59583], + 982: [0, 0.43056, 0.02778, 0, 0.82813], + 1009: [0.19444, 0.43056, 0, 0.08334, 0.51702], + 1013: [0, 0.43056, 0, 0.05556, 0.4059], + 57649: [0, 0.43056, 0, 0.02778, 0.32246], + 57911: [0.19444, 0.43056, 0, 0.08334, 0.38403] + }, + "SansSerif-Bold": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0, 0, 0.36667], + 34: [0, 0.69444, 0, 0, 0.55834], + 35: [0.19444, 0.69444, 0, 0, 0.91667], + 36: [0.05556, 0.75, 0, 0, 0.55], + 37: [0.05556, 0.75, 0, 0, 1.02912], + 38: [0, 0.69444, 0, 0, 0.83056], + 39: [0, 0.69444, 0, 0, 0.30556], + 40: [0.25, 0.75, 0, 0, 0.42778], + 41: [0.25, 0.75, 0, 0, 0.42778], + 42: [0, 0.75, 0, 0, 0.55], + 43: [0.11667, 0.61667, 0, 0, 0.85556], + 44: [0.10556, 0.13056, 0, 0, 0.30556], + 45: [0, 0.45833, 0, 0, 0.36667], + 46: [0, 0.13056, 0, 0, 0.30556], + 47: [0.25, 0.75, 0, 0, 0.55], + 48: [0, 0.69444, 0, 0, 0.55], + 49: [0, 0.69444, 0, 0, 0.55], + 50: [0, 0.69444, 0, 0, 0.55], + 51: [0, 0.69444, 0, 0, 0.55], + 52: [0, 0.69444, 0, 0, 0.55], + 53: [0, 0.69444, 0, 0, 0.55], + 54: [0, 0.69444, 0, 0, 0.55], + 55: [0, 0.69444, 0, 0, 0.55], + 56: [0, 0.69444, 0, 0, 0.55], + 57: [0, 0.69444, 0, 0, 0.55], + 58: [0, 0.45833, 0, 0, 0.30556], + 59: [0.10556, 0.45833, 0, 0, 0.30556], + 61: [-0.09375, 0.40625, 0, 0, 0.85556], + 63: [0, 0.69444, 0, 0, 0.51945], + 64: [0, 0.69444, 0, 0, 0.73334], + 65: [0, 0.69444, 0, 0, 0.73334], + 66: [0, 0.69444, 0, 0, 0.73334], + 67: [0, 0.69444, 0, 0, 0.70278], + 68: [0, 0.69444, 0, 0, 0.79445], + 69: [0, 0.69444, 0, 0, 0.64167], + 70: [0, 0.69444, 0, 0, 0.61111], + 71: [0, 0.69444, 0, 0, 0.73334], + 72: [0, 0.69444, 0, 0, 0.79445], + 73: [0, 0.69444, 0, 0, 0.33056], + 74: [0, 0.69444, 0, 0, 0.51945], + 75: [0, 0.69444, 0, 0, 0.76389], + 76: [0, 0.69444, 0, 0, 0.58056], + 77: [0, 0.69444, 0, 0, 0.97778], + 78: [0, 0.69444, 0, 0, 0.79445], + 79: [0, 0.69444, 0, 0, 0.79445], + 80: [0, 0.69444, 0, 0, 0.70278], + 81: [0.10556, 0.69444, 0, 0, 0.79445], + 82: [0, 0.69444, 0, 0, 0.70278], + 83: [0, 0.69444, 0, 0, 0.61111], + 84: [0, 0.69444, 0, 0, 0.73334], + 85: [0, 0.69444, 0, 0, 0.76389], + 86: [0, 0.69444, 0.01528, 0, 0.73334], + 87: [0, 0.69444, 0.01528, 0, 1.03889], + 88: [0, 0.69444, 0, 0, 0.73334], + 89: [0, 0.69444, 0.0275, 0, 0.73334], + 90: [0, 0.69444, 0, 0, 0.67223], + 91: [0.25, 0.75, 0, 0, 0.34306], + 93: [0.25, 0.75, 0, 0, 0.34306], + 94: [0, 0.69444, 0, 0, 0.55], + 95: [0.35, 0.10833, 0.03056, 0, 0.55], + 97: [0, 0.45833, 0, 0, 0.525], + 98: [0, 0.69444, 0, 0, 0.56111], + 99: [0, 0.45833, 0, 0, 0.48889], + 100: [0, 0.69444, 0, 0, 0.56111], + 101: [0, 0.45833, 0, 0, 0.51111], + 102: [0, 0.69444, 0.07639, 0, 0.33611], + 103: [0.19444, 0.45833, 0.01528, 0, 0.55], + 104: [0, 0.69444, 0, 0, 0.56111], + 105: [0, 0.69444, 0, 0, 0.25556], + 106: [0.19444, 0.69444, 0, 0, 0.28611], + 107: [0, 0.69444, 0, 0, 0.53056], + 108: [0, 0.69444, 0, 0, 0.25556], + 109: [0, 0.45833, 0, 0, 0.86667], + 110: [0, 0.45833, 0, 0, 0.56111], + 111: [0, 0.45833, 0, 0, 0.55], + 112: [0.19444, 0.45833, 0, 0, 0.56111], + 113: [0.19444, 0.45833, 0, 0, 0.56111], + 114: [0, 0.45833, 0.01528, 0, 0.37222], + 115: [0, 0.45833, 0, 0, 0.42167], + 116: [0, 0.58929, 0, 0, 0.40417], + 117: [0, 0.45833, 0, 0, 0.56111], + 118: [0, 0.45833, 0.01528, 0, 0.5], + 119: [0, 0.45833, 0.01528, 0, 0.74445], + 120: [0, 0.45833, 0, 0, 0.5], + 121: [0.19444, 0.45833, 0.01528, 0, 0.5], + 122: [0, 0.45833, 0, 0, 0.47639], + 126: [0.35, 0.34444, 0, 0, 0.55], + 160: [0, 0, 0, 0, 0.25], + 168: [0, 0.69444, 0, 0, 0.55], + 176: [0, 0.69444, 0, 0, 0.73334], + 180: [0, 0.69444, 0, 0, 0.55], + 184: [0.17014, 0, 0, 0, 0.48889], + 305: [0, 0.45833, 0, 0, 0.25556], + 567: [0.19444, 0.45833, 0, 0, 0.28611], + 710: [0, 0.69444, 0, 0, 0.55], + 711: [0, 0.63542, 0, 0, 0.55], + 713: [0, 0.63778, 0, 0, 0.55], + 728: [0, 0.69444, 0, 0, 0.55], + 729: [0, 0.69444, 0, 0, 0.30556], + 730: [0, 0.69444, 0, 0, 0.73334], + 732: [0, 0.69444, 0, 0, 0.55], + 733: [0, 0.69444, 0, 0, 0.55], + 915: [0, 0.69444, 0, 0, 0.58056], + 916: [0, 0.69444, 0, 0, 0.91667], + 920: [0, 0.69444, 0, 0, 0.85556], + 923: [0, 0.69444, 0, 0, 0.67223], + 926: [0, 0.69444, 0, 0, 0.73334], + 928: [0, 0.69444, 0, 0, 0.79445], + 931: [0, 0.69444, 0, 0, 0.79445], + 933: [0, 0.69444, 0, 0, 0.85556], + 934: [0, 0.69444, 0, 0, 0.79445], + 936: [0, 0.69444, 0, 0, 0.85556], + 937: [0, 0.69444, 0, 0, 0.79445], + 8211: [0, 0.45833, 0.03056, 0, 0.55], + 8212: [0, 0.45833, 0.03056, 0, 1.10001], + 8216: [0, 0.69444, 0, 0, 0.30556], + 8217: [0, 0.69444, 0, 0, 0.30556], + 8220: [0, 0.69444, 0, 0, 0.55834], + 8221: [0, 0.69444, 0, 0, 0.55834] + }, + "SansSerif-Italic": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0.05733, 0, 0.31945], + 34: [0, 0.69444, 316e-5, 0, 0.5], + 35: [0.19444, 0.69444, 0.05087, 0, 0.83334], + 36: [0.05556, 0.75, 0.11156, 0, 0.5], + 37: [0.05556, 0.75, 0.03126, 0, 0.83334], + 38: [0, 0.69444, 0.03058, 0, 0.75834], + 39: [0, 0.69444, 0.07816, 0, 0.27778], + 40: [0.25, 0.75, 0.13164, 0, 0.38889], + 41: [0.25, 0.75, 0.02536, 0, 0.38889], + 42: [0, 0.75, 0.11775, 0, 0.5], + 43: [0.08333, 0.58333, 0.02536, 0, 0.77778], + 44: [0.125, 0.08333, 0, 0, 0.27778], + 45: [0, 0.44444, 0.01946, 0, 0.33333], + 46: [0, 0.08333, 0, 0, 0.27778], + 47: [0.25, 0.75, 0.13164, 0, 0.5], + 48: [0, 0.65556, 0.11156, 0, 0.5], + 49: [0, 0.65556, 0.11156, 0, 0.5], + 50: [0, 0.65556, 0.11156, 0, 0.5], + 51: [0, 0.65556, 0.11156, 0, 0.5], + 52: [0, 0.65556, 0.11156, 0, 0.5], + 53: [0, 0.65556, 0.11156, 0, 0.5], + 54: [0, 0.65556, 0.11156, 0, 0.5], + 55: [0, 0.65556, 0.11156, 0, 0.5], + 56: [0, 0.65556, 0.11156, 0, 0.5], + 57: [0, 0.65556, 0.11156, 0, 0.5], + 58: [0, 0.44444, 0.02502, 0, 0.27778], + 59: [0.125, 0.44444, 0.02502, 0, 0.27778], + 61: [-0.13, 0.37, 0.05087, 0, 0.77778], + 63: [0, 0.69444, 0.11809, 0, 0.47222], + 64: [0, 0.69444, 0.07555, 0, 0.66667], + 65: [0, 0.69444, 0, 0, 0.66667], + 66: [0, 0.69444, 0.08293, 0, 0.66667], + 67: [0, 0.69444, 0.11983, 0, 0.63889], + 68: [0, 0.69444, 0.07555, 0, 0.72223], + 69: [0, 0.69444, 0.11983, 0, 0.59722], + 70: [0, 0.69444, 0.13372, 0, 0.56945], + 71: [0, 0.69444, 0.11983, 0, 0.66667], + 72: [0, 0.69444, 0.08094, 0, 0.70834], + 73: [0, 0.69444, 0.13372, 0, 0.27778], + 74: [0, 0.69444, 0.08094, 0, 0.47222], + 75: [0, 0.69444, 0.11983, 0, 0.69445], + 76: [0, 0.69444, 0, 0, 0.54167], + 77: [0, 0.69444, 0.08094, 0, 0.875], + 78: [0, 0.69444, 0.08094, 0, 0.70834], + 79: [0, 0.69444, 0.07555, 0, 0.73611], + 80: [0, 0.69444, 0.08293, 0, 0.63889], + 81: [0.125, 0.69444, 0.07555, 0, 0.73611], + 82: [0, 0.69444, 0.08293, 0, 0.64584], + 83: [0, 0.69444, 0.09205, 0, 0.55556], + 84: [0, 0.69444, 0.13372, 0, 0.68056], + 85: [0, 0.69444, 0.08094, 0, 0.6875], + 86: [0, 0.69444, 0.1615, 0, 0.66667], + 87: [0, 0.69444, 0.1615, 0, 0.94445], + 88: [0, 0.69444, 0.13372, 0, 0.66667], + 89: [0, 0.69444, 0.17261, 0, 0.66667], + 90: [0, 0.69444, 0.11983, 0, 0.61111], + 91: [0.25, 0.75, 0.15942, 0, 0.28889], + 93: [0.25, 0.75, 0.08719, 0, 0.28889], + 94: [0, 0.69444, 0.0799, 0, 0.5], + 95: [0.35, 0.09444, 0.08616, 0, 0.5], + 97: [0, 0.44444, 981e-5, 0, 0.48056], + 98: [0, 0.69444, 0.03057, 0, 0.51667], + 99: [0, 0.44444, 0.08336, 0, 0.44445], + 100: [0, 0.69444, 0.09483, 0, 0.51667], + 101: [0, 0.44444, 0.06778, 0, 0.44445], + 102: [0, 0.69444, 0.21705, 0, 0.30556], + 103: [0.19444, 0.44444, 0.10836, 0, 0.5], + 104: [0, 0.69444, 0.01778, 0, 0.51667], + 105: [0, 0.67937, 0.09718, 0, 0.23889], + 106: [0.19444, 0.67937, 0.09162, 0, 0.26667], + 107: [0, 0.69444, 0.08336, 0, 0.48889], + 108: [0, 0.69444, 0.09483, 0, 0.23889], + 109: [0, 0.44444, 0.01778, 0, 0.79445], + 110: [0, 0.44444, 0.01778, 0, 0.51667], + 111: [0, 0.44444, 0.06613, 0, 0.5], + 112: [0.19444, 0.44444, 0.0389, 0, 0.51667], + 113: [0.19444, 0.44444, 0.04169, 0, 0.51667], + 114: [0, 0.44444, 0.10836, 0, 0.34167], + 115: [0, 0.44444, 0.0778, 0, 0.38333], + 116: [0, 0.57143, 0.07225, 0, 0.36111], + 117: [0, 0.44444, 0.04169, 0, 0.51667], + 118: [0, 0.44444, 0.10836, 0, 0.46111], + 119: [0, 0.44444, 0.10836, 0, 0.68334], + 120: [0, 0.44444, 0.09169, 0, 0.46111], + 121: [0.19444, 0.44444, 0.10836, 0, 0.46111], + 122: [0, 0.44444, 0.08752, 0, 0.43472], + 126: [0.35, 0.32659, 0.08826, 0, 0.5], + 160: [0, 0, 0, 0, 0.25], + 168: [0, 0.67937, 0.06385, 0, 0.5], + 176: [0, 0.69444, 0, 0, 0.73752], + 184: [0.17014, 0, 0, 0, 0.44445], + 305: [0, 0.44444, 0.04169, 0, 0.23889], + 567: [0.19444, 0.44444, 0.04169, 0, 0.26667], + 710: [0, 0.69444, 0.0799, 0, 0.5], + 711: [0, 0.63194, 0.08432, 0, 0.5], + 713: [0, 0.60889, 0.08776, 0, 0.5], + 714: [0, 0.69444, 0.09205, 0, 0.5], + 715: [0, 0.69444, 0, 0, 0.5], + 728: [0, 0.69444, 0.09483, 0, 0.5], + 729: [0, 0.67937, 0.07774, 0, 0.27778], + 730: [0, 0.69444, 0, 0, 0.73752], + 732: [0, 0.67659, 0.08826, 0, 0.5], + 733: [0, 0.69444, 0.09205, 0, 0.5], + 915: [0, 0.69444, 0.13372, 0, 0.54167], + 916: [0, 0.69444, 0, 0, 0.83334], + 920: [0, 0.69444, 0.07555, 0, 0.77778], + 923: [0, 0.69444, 0, 0, 0.61111], + 926: [0, 0.69444, 0.12816, 0, 0.66667], + 928: [0, 0.69444, 0.08094, 0, 0.70834], + 931: [0, 0.69444, 0.11983, 0, 0.72222], + 933: [0, 0.69444, 0.09031, 0, 0.77778], + 934: [0, 0.69444, 0.04603, 0, 0.72222], + 936: [0, 0.69444, 0.09031, 0, 0.77778], + 937: [0, 0.69444, 0.08293, 0, 0.72222], + 8211: [0, 0.44444, 0.08616, 0, 0.5], + 8212: [0, 0.44444, 0.08616, 0, 1], + 8216: [0, 0.69444, 0.07816, 0, 0.27778], + 8217: [0, 0.69444, 0.07816, 0, 0.27778], + 8220: [0, 0.69444, 0.14205, 0, 0.5], + 8221: [0, 0.69444, 316e-5, 0, 0.5] + }, + "SansSerif-Regular": { + 32: [0, 0, 0, 0, 0.25], + 33: [0, 0.69444, 0, 0, 0.31945], + 34: [0, 0.69444, 0, 0, 0.5], + 35: [0.19444, 0.69444, 0, 0, 0.83334], + 36: [0.05556, 0.75, 0, 0, 0.5], + 37: [0.05556, 0.75, 0, 0, 0.83334], + 38: [0, 0.69444, 0, 0, 0.75834], + 39: [0, 0.69444, 0, 0, 0.27778], + 40: [0.25, 0.75, 0, 0, 0.38889], + 41: [0.25, 0.75, 0, 0, 0.38889], + 42: [0, 0.75, 0, 0, 0.5], + 43: [0.08333, 0.58333, 0, 0, 0.77778], + 44: [0.125, 0.08333, 0, 0, 0.27778], + 45: [0, 0.44444, 0, 0, 0.33333], + 46: [0, 0.08333, 0, 0, 0.27778], + 47: [0.25, 0.75, 0, 0, 0.5], + 48: [0, 0.65556, 0, 0, 0.5], + 49: [0, 0.65556, 0, 0, 0.5], + 50: [0, 0.65556, 0, 0, 0.5], + 51: [0, 0.65556, 0, 0, 0.5], + 52: [0, 0.65556, 0, 0, 0.5], + 53: [0, 0.65556, 0, 0, 0.5], + 54: [0, 0.65556, 0, 0, 0.5], + 55: [0, 0.65556, 0, 0, 0.5], + 56: [0, 0.65556, 0, 0, 0.5], + 57: [0, 0.65556, 0, 0, 0.5], + 58: [0, 0.44444, 0, 0, 0.27778], + 59: [0.125, 0.44444, 0, 0, 0.27778], + 61: [-0.13, 0.37, 0, 0, 0.77778], + 63: [0, 0.69444, 0, 0, 0.47222], + 64: [0, 0.69444, 0, 0, 0.66667], + 65: [0, 0.69444, 0, 0, 0.66667], + 66: [0, 0.69444, 0, 0, 0.66667], + 67: [0, 0.69444, 0, 0, 0.63889], + 68: [0, 0.69444, 0, 0, 0.72223], + 69: [0, 0.69444, 0, 0, 0.59722], + 70: [0, 0.69444, 0, 0, 0.56945], + 71: [0, 0.69444, 0, 0, 0.66667], + 72: [0, 0.69444, 0, 0, 0.70834], + 73: [0, 0.69444, 0, 0, 0.27778], + 74: [0, 0.69444, 0, 0, 0.47222], + 75: [0, 0.69444, 0, 0, 0.69445], + 76: [0, 0.69444, 0, 0, 0.54167], + 77: [0, 0.69444, 0, 0, 0.875], + 78: [0, 0.69444, 0, 0, 0.70834], + 79: [0, 0.69444, 0, 0, 0.73611], + 80: [0, 0.69444, 0, 0, 0.63889], + 81: [0.125, 0.69444, 0, 0, 0.73611], + 82: [0, 0.69444, 0, 0, 0.64584], + 83: [0, 0.69444, 0, 0, 0.55556], + 84: [0, 0.69444, 0, 0, 0.68056], + 85: [0, 0.69444, 0, 0, 0.6875], + 86: [0, 0.69444, 0.01389, 0, 0.66667], + 87: [0, 0.69444, 0.01389, 0, 0.94445], + 88: [0, 0.69444, 0, 0, 0.66667], + 89: [0, 0.69444, 0.025, 0, 0.66667], + 90: [0, 0.69444, 0, 0, 0.61111], + 91: [0.25, 0.75, 0, 0, 0.28889], + 93: [0.25, 0.75, 0, 0, 0.28889], + 94: [0, 0.69444, 0, 0, 0.5], + 95: [0.35, 0.09444, 0.02778, 0, 0.5], + 97: [0, 0.44444, 0, 0, 0.48056], + 98: [0, 0.69444, 0, 0, 0.51667], + 99: [0, 0.44444, 0, 0, 0.44445], + 100: [0, 0.69444, 0, 0, 0.51667], + 101: [0, 0.44444, 0, 0, 0.44445], + 102: [0, 0.69444, 0.06944, 0, 0.30556], + 103: [0.19444, 0.44444, 0.01389, 0, 0.5], + 104: [0, 0.69444, 0, 0, 0.51667], + 105: [0, 0.67937, 0, 0, 0.23889], + 106: [0.19444, 0.67937, 0, 0, 0.26667], + 107: [0, 0.69444, 0, 0, 0.48889], + 108: [0, 0.69444, 0, 0, 0.23889], + 109: [0, 0.44444, 0, 0, 0.79445], + 110: [0, 0.44444, 0, 0, 0.51667], + 111: [0, 0.44444, 0, 0, 0.5], + 112: [0.19444, 0.44444, 0, 0, 0.51667], + 113: [0.19444, 0.44444, 0, 0, 0.51667], + 114: [0, 0.44444, 0.01389, 0, 0.34167], + 115: [0, 0.44444, 0, 0, 0.38333], + 116: [0, 0.57143, 0, 0, 0.36111], + 117: [0, 0.44444, 0, 0, 0.51667], + 118: [0, 0.44444, 0.01389, 0, 0.46111], + 119: [0, 0.44444, 0.01389, 0, 0.68334], + 120: [0, 0.44444, 0, 0, 0.46111], + 121: [0.19444, 0.44444, 0.01389, 0, 0.46111], + 122: [0, 0.44444, 0, 0, 0.43472], + 126: [0.35, 0.32659, 0, 0, 0.5], + 160: [0, 0, 0, 0, 0.25], + 168: [0, 0.67937, 0, 0, 0.5], + 176: [0, 0.69444, 0, 0, 0.66667], + 184: [0.17014, 0, 0, 0, 0.44445], + 305: [0, 0.44444, 0, 0, 0.23889], + 567: [0.19444, 0.44444, 0, 0, 0.26667], + 710: [0, 0.69444, 0, 0, 0.5], + 711: [0, 0.63194, 0, 0, 0.5], + 713: [0, 0.60889, 0, 0, 0.5], + 714: [0, 0.69444, 0, 0, 0.5], + 715: [0, 0.69444, 0, 0, 0.5], + 728: [0, 0.69444, 0, 0, 0.5], + 729: [0, 0.67937, 0, 0, 0.27778], + 730: [0, 0.69444, 0, 0, 0.66667], + 732: [0, 0.67659, 0, 0, 0.5], + 733: [0, 0.69444, 0, 0, 0.5], + 915: [0, 0.69444, 0, 0, 0.54167], + 916: [0, 0.69444, 0, 0, 0.83334], + 920: [0, 0.69444, 0, 0, 0.77778], + 923: [0, 0.69444, 0, 0, 0.61111], + 926: [0, 0.69444, 0, 0, 0.66667], + 928: [0, 0.69444, 0, 0, 0.70834], + 931: [0, 0.69444, 0, 0, 0.72222], + 933: [0, 0.69444, 0, 0, 0.77778], + 934: [0, 0.69444, 0, 0, 0.72222], + 936: [0, 0.69444, 0, 0, 0.77778], + 937: [0, 0.69444, 0, 0, 0.72222], + 8211: [0, 0.44444, 0.02778, 0, 0.5], + 8212: [0, 0.44444, 0.02778, 0, 1], + 8216: [0, 0.69444, 0, 0, 0.27778], + 8217: [0, 0.69444, 0, 0, 0.27778], + 8220: [0, 0.69444, 0, 0, 0.5], + 8221: [0, 0.69444, 0, 0, 0.5] + }, + "Script-Regular": { + 32: [0, 0, 0, 0, 0.25], + 65: [0, 0.7, 0.22925, 0, 0.80253], + 66: [0, 0.7, 0.04087, 0, 0.90757], + 67: [0, 0.7, 0.1689, 0, 0.66619], + 68: [0, 0.7, 0.09371, 0, 0.77443], + 69: [0, 0.7, 0.18583, 0, 0.56162], + 70: [0, 0.7, 0.13634, 0, 0.89544], + 71: [0, 0.7, 0.17322, 0, 0.60961], + 72: [0, 0.7, 0.29694, 0, 0.96919], + 73: [0, 0.7, 0.19189, 0, 0.80907], + 74: [0.27778, 0.7, 0.19189, 0, 1.05159], + 75: [0, 0.7, 0.31259, 0, 0.91364], + 76: [0, 0.7, 0.19189, 0, 0.87373], + 77: [0, 0.7, 0.15981, 0, 1.08031], + 78: [0, 0.7, 0.3525, 0, 0.9015], + 79: [0, 0.7, 0.08078, 0, 0.73787], + 80: [0, 0.7, 0.08078, 0, 1.01262], + 81: [0, 0.7, 0.03305, 0, 0.88282], + 82: [0, 0.7, 0.06259, 0, 0.85], + 83: [0, 0.7, 0.19189, 0, 0.86767], + 84: [0, 0.7, 0.29087, 0, 0.74697], + 85: [0, 0.7, 0.25815, 0, 0.79996], + 86: [0, 0.7, 0.27523, 0, 0.62204], + 87: [0, 0.7, 0.27523, 0, 0.80532], + 88: [0, 0.7, 0.26006, 0, 0.94445], + 89: [0, 0.7, 0.2939, 0, 0.70961], + 90: [0, 0.7, 0.24037, 0, 0.8212], + 160: [0, 0, 0, 0, 0.25] + }, + "Size1-Regular": { + 32: [0, 0, 0, 0, 0.25], + 40: [0.35001, 0.85, 0, 0, 0.45834], + 41: [0.35001, 0.85, 0, 0, 0.45834], + 47: [0.35001, 0.85, 0, 0, 0.57778], + 91: [0.35001, 0.85, 0, 0, 0.41667], + 92: [0.35001, 0.85, 0, 0, 0.57778], + 93: [0.35001, 0.85, 0, 0, 0.41667], + 123: [0.35001, 0.85, 0, 0, 0.58334], + 125: [0.35001, 0.85, 0, 0, 0.58334], + 160: [0, 0, 0, 0, 0.25], + 710: [0, 0.72222, 0, 0, 0.55556], + 732: [0, 0.72222, 0, 0, 0.55556], + 770: [0, 0.72222, 0, 0, 0.55556], + 771: [0, 0.72222, 0, 0, 0.55556], + 8214: [-99e-5, 0.601, 0, 0, 0.77778], + 8593: [1e-5, 0.6, 0, 0, 0.66667], + 8595: [1e-5, 0.6, 0, 0, 0.66667], + 8657: [1e-5, 0.6, 0, 0, 0.77778], + 8659: [1e-5, 0.6, 0, 0, 0.77778], + 8719: [0.25001, 0.75, 0, 0, 0.94445], + 8720: [0.25001, 0.75, 0, 0, 0.94445], + 8721: [0.25001, 0.75, 0, 0, 1.05556], + 8730: [0.35001, 0.85, 0, 0, 1], + 8739: [-599e-5, 0.606, 0, 0, 0.33333], + 8741: [-599e-5, 0.606, 0, 0, 0.55556], + 8747: [0.30612, 0.805, 0.19445, 0, 0.47222], + 8748: [0.306, 0.805, 0.19445, 0, 0.47222], + 8749: [0.306, 0.805, 0.19445, 0, 0.47222], + 8750: [0.30612, 0.805, 0.19445, 0, 0.47222], + 8896: [0.25001, 0.75, 0, 0, 0.83334], + 8897: [0.25001, 0.75, 0, 0, 0.83334], + 8898: [0.25001, 0.75, 0, 0, 0.83334], + 8899: [0.25001, 0.75, 0, 0, 0.83334], + 8968: [0.35001, 0.85, 0, 0, 0.47222], + 8969: [0.35001, 0.85, 0, 0, 0.47222], + 8970: [0.35001, 0.85, 0, 0, 0.47222], + 8971: [0.35001, 0.85, 0, 0, 0.47222], + 9168: [-99e-5, 0.601, 0, 0, 0.66667], + 10216: [0.35001, 0.85, 0, 0, 0.47222], + 10217: [0.35001, 0.85, 0, 0, 0.47222], + 10752: [0.25001, 0.75, 0, 0, 1.11111], + 10753: [0.25001, 0.75, 0, 0, 1.11111], + 10754: [0.25001, 0.75, 0, 0, 1.11111], + 10756: [0.25001, 0.75, 0, 0, 0.83334], + 10758: [0.25001, 0.75, 0, 0, 0.83334] + }, + "Size2-Regular": { + 32: [0, 0, 0, 0, 0.25], + 40: [0.65002, 1.15, 0, 0, 0.59722], + 41: [0.65002, 1.15, 0, 0, 0.59722], + 47: [0.65002, 1.15, 0, 0, 0.81111], + 91: [0.65002, 1.15, 0, 0, 0.47222], + 92: [0.65002, 1.15, 0, 0, 0.81111], + 93: [0.65002, 1.15, 0, 0, 0.47222], + 123: [0.65002, 1.15, 0, 0, 0.66667], + 125: [0.65002, 1.15, 0, 0, 0.66667], + 160: [0, 0, 0, 0, 0.25], + 710: [0, 0.75, 0, 0, 1], + 732: [0, 0.75, 0, 0, 1], + 770: [0, 0.75, 0, 0, 1], + 771: [0, 0.75, 0, 0, 1], + 8719: [0.55001, 1.05, 0, 0, 1.27778], + 8720: [0.55001, 1.05, 0, 0, 1.27778], + 8721: [0.55001, 1.05, 0, 0, 1.44445], + 8730: [0.65002, 1.15, 0, 0, 1], + 8747: [0.86225, 1.36, 0.44445, 0, 0.55556], + 8748: [0.862, 1.36, 0.44445, 0, 0.55556], + 8749: [0.862, 1.36, 0.44445, 0, 0.55556], + 8750: [0.86225, 1.36, 0.44445, 0, 0.55556], + 8896: [0.55001, 1.05, 0, 0, 1.11111], + 8897: [0.55001, 1.05, 0, 0, 1.11111], + 8898: [0.55001, 1.05, 0, 0, 1.11111], + 8899: [0.55001, 1.05, 0, 0, 1.11111], + 8968: [0.65002, 1.15, 0, 0, 0.52778], + 8969: [0.65002, 1.15, 0, 0, 0.52778], + 8970: [0.65002, 1.15, 0, 0, 0.52778], + 8971: [0.65002, 1.15, 0, 0, 0.52778], + 10216: [0.65002, 1.15, 0, 0, 0.61111], + 10217: [0.65002, 1.15, 0, 0, 0.61111], + 10752: [0.55001, 1.05, 0, 0, 1.51112], + 10753: [0.55001, 1.05, 0, 0, 1.51112], + 10754: [0.55001, 1.05, 0, 0, 1.51112], + 10756: [0.55001, 1.05, 0, 0, 1.11111], + 10758: [0.55001, 1.05, 0, 0, 1.11111] + }, + "Size3-Regular": { + 32: [0, 0, 0, 0, 0.25], + 40: [0.95003, 1.45, 0, 0, 0.73611], + 41: [0.95003, 1.45, 0, 0, 0.73611], + 47: [0.95003, 1.45, 0, 0, 1.04445], + 91: [0.95003, 1.45, 0, 0, 0.52778], + 92: [0.95003, 1.45, 0, 0, 1.04445], + 93: [0.95003, 1.45, 0, 0, 0.52778], + 123: [0.95003, 1.45, 0, 0, 0.75], + 125: [0.95003, 1.45, 0, 0, 0.75], + 160: [0, 0, 0, 0, 0.25], + 710: [0, 0.75, 0, 0, 1.44445], + 732: [0, 0.75, 0, 0, 1.44445], + 770: [0, 0.75, 0, 0, 1.44445], + 771: [0, 0.75, 0, 0, 1.44445], + 8730: [0.95003, 1.45, 0, 0, 1], + 8968: [0.95003, 1.45, 0, 0, 0.58334], + 8969: [0.95003, 1.45, 0, 0, 0.58334], + 8970: [0.95003, 1.45, 0, 0, 0.58334], + 8971: [0.95003, 1.45, 0, 0, 0.58334], + 10216: [0.95003, 1.45, 0, 0, 0.75], + 10217: [0.95003, 1.45, 0, 0, 0.75] + }, + "Size4-Regular": { + 32: [0, 0, 0, 0, 0.25], + 40: [1.25003, 1.75, 0, 0, 0.79167], + 41: [1.25003, 1.75, 0, 0, 0.79167], + 47: [1.25003, 1.75, 0, 0, 1.27778], + 91: [1.25003, 1.75, 0, 0, 0.58334], + 92: [1.25003, 1.75, 0, 0, 1.27778], + 93: [1.25003, 1.75, 0, 0, 0.58334], + 123: [1.25003, 1.75, 0, 0, 0.80556], + 125: [1.25003, 1.75, 0, 0, 0.80556], + 160: [0, 0, 0, 0, 0.25], + 710: [0, 0.825, 0, 0, 1.8889], + 732: [0, 0.825, 0, 0, 1.8889], + 770: [0, 0.825, 0, 0, 1.8889], + 771: [0, 0.825, 0, 0, 1.8889], + 8730: [1.25003, 1.75, 0, 0, 1], + 8968: [1.25003, 1.75, 0, 0, 0.63889], + 8969: [1.25003, 1.75, 0, 0, 0.63889], + 8970: [1.25003, 1.75, 0, 0, 0.63889], + 8971: [1.25003, 1.75, 0, 0, 0.63889], + 9115: [0.64502, 1.155, 0, 0, 0.875], + 9116: [1e-5, 0.6, 0, 0, 0.875], + 9117: [0.64502, 1.155, 0, 0, 0.875], + 9118: [0.64502, 1.155, 0, 0, 0.875], + 9119: [1e-5, 0.6, 0, 0, 0.875], + 9120: [0.64502, 1.155, 0, 0, 0.875], + 9121: [0.64502, 1.155, 0, 0, 0.66667], + 9122: [-99e-5, 0.601, 0, 0, 0.66667], + 9123: [0.64502, 1.155, 0, 0, 0.66667], + 9124: [0.64502, 1.155, 0, 0, 0.66667], + 9125: [-99e-5, 0.601, 0, 0, 0.66667], + 9126: [0.64502, 1.155, 0, 0, 0.66667], + 9127: [1e-5, 0.9, 0, 0, 0.88889], + 9128: [0.65002, 1.15, 0, 0, 0.88889], + 9129: [0.90001, 0, 0, 0, 0.88889], + 9130: [0, 0.3, 0, 0, 0.88889], + 9131: [1e-5, 0.9, 0, 0, 0.88889], + 9132: [0.65002, 1.15, 0, 0, 0.88889], + 9133: [0.90001, 0, 0, 0, 0.88889], + 9143: [0.88502, 0.915, 0, 0, 1.05556], + 10216: [1.25003, 1.75, 0, 0, 0.80556], + 10217: [1.25003, 1.75, 0, 0, 0.80556], + 57344: [-499e-5, 0.605, 0, 0, 1.05556], + 57345: [-499e-5, 0.605, 0, 0, 1.05556], + 57680: [0, 0.12, 0, 0, 0.45], + 57681: [0, 0.12, 0, 0, 0.45], + 57682: [0, 0.12, 0, 0, 0.45], + 57683: [0, 0.12, 0, 0, 0.45] + }, + "Typewriter-Regular": { + 32: [0, 0, 0, 0, 0.525], + 33: [0, 0.61111, 0, 0, 0.525], + 34: [0, 0.61111, 0, 0, 0.525], + 35: [0, 0.61111, 0, 0, 0.525], + 36: [0.08333, 0.69444, 0, 0, 0.525], + 37: [0.08333, 0.69444, 0, 0, 0.525], + 38: [0, 0.61111, 0, 0, 0.525], + 39: [0, 0.61111, 0, 0, 0.525], + 40: [0.08333, 0.69444, 0, 0, 0.525], + 41: [0.08333, 0.69444, 0, 0, 0.525], + 42: [0, 0.52083, 0, 0, 0.525], + 43: [-0.08056, 0.53055, 0, 0, 0.525], + 44: [0.13889, 0.125, 0, 0, 0.525], + 45: [-0.08056, 0.53055, 0, 0, 0.525], + 46: [0, 0.125, 0, 0, 0.525], + 47: [0.08333, 0.69444, 0, 0, 0.525], + 48: [0, 0.61111, 0, 0, 0.525], + 49: [0, 0.61111, 0, 0, 0.525], + 50: [0, 0.61111, 0, 0, 0.525], + 51: [0, 0.61111, 0, 0, 0.525], + 52: [0, 0.61111, 0, 0, 0.525], + 53: [0, 0.61111, 0, 0, 0.525], + 54: [0, 0.61111, 0, 0, 0.525], + 55: [0, 0.61111, 0, 0, 0.525], + 56: [0, 0.61111, 0, 0, 0.525], + 57: [0, 0.61111, 0, 0, 0.525], + 58: [0, 0.43056, 0, 0, 0.525], + 59: [0.13889, 0.43056, 0, 0, 0.525], + 60: [-0.05556, 0.55556, 0, 0, 0.525], + 61: [-0.19549, 0.41562, 0, 0, 0.525], + 62: [-0.05556, 0.55556, 0, 0, 0.525], + 63: [0, 0.61111, 0, 0, 0.525], + 64: [0, 0.61111, 0, 0, 0.525], + 65: [0, 0.61111, 0, 0, 0.525], + 66: [0, 0.61111, 0, 0, 0.525], + 67: [0, 0.61111, 0, 0, 0.525], + 68: [0, 0.61111, 0, 0, 0.525], + 69: [0, 0.61111, 0, 0, 0.525], + 70: [0, 0.61111, 0, 0, 0.525], + 71: [0, 0.61111, 0, 0, 0.525], + 72: [0, 0.61111, 0, 0, 0.525], + 73: [0, 0.61111, 0, 0, 0.525], + 74: [0, 0.61111, 0, 0, 0.525], + 75: [0, 0.61111, 0, 0, 0.525], + 76: [0, 0.61111, 0, 0, 0.525], + 77: [0, 0.61111, 0, 0, 0.525], + 78: [0, 0.61111, 0, 0, 0.525], + 79: [0, 0.61111, 0, 0, 0.525], + 80: [0, 0.61111, 0, 0, 0.525], + 81: [0.13889, 0.61111, 0, 0, 0.525], + 82: [0, 0.61111, 0, 0, 0.525], + 83: [0, 0.61111, 0, 0, 0.525], + 84: [0, 0.61111, 0, 0, 0.525], + 85: [0, 0.61111, 0, 0, 0.525], + 86: [0, 0.61111, 0, 0, 0.525], + 87: [0, 0.61111, 0, 0, 0.525], + 88: [0, 0.61111, 0, 0, 0.525], + 89: [0, 0.61111, 0, 0, 0.525], + 90: [0, 0.61111, 0, 0, 0.525], + 91: [0.08333, 0.69444, 0, 0, 0.525], + 92: [0.08333, 0.69444, 0, 0, 0.525], + 93: [0.08333, 0.69444, 0, 0, 0.525], + 94: [0, 0.61111, 0, 0, 0.525], + 95: [0.09514, 0, 0, 0, 0.525], + 96: [0, 0.61111, 0, 0, 0.525], + 97: [0, 0.43056, 0, 0, 0.525], + 98: [0, 0.61111, 0, 0, 0.525], + 99: [0, 0.43056, 0, 0, 0.525], + 100: [0, 0.61111, 0, 0, 0.525], + 101: [0, 0.43056, 0, 0, 0.525], + 102: [0, 0.61111, 0, 0, 0.525], + 103: [0.22222, 0.43056, 0, 0, 0.525], + 104: [0, 0.61111, 0, 0, 0.525], + 105: [0, 0.61111, 0, 0, 0.525], + 106: [0.22222, 0.61111, 0, 0, 0.525], + 107: [0, 0.61111, 0, 0, 0.525], + 108: [0, 0.61111, 0, 0, 0.525], + 109: [0, 0.43056, 0, 0, 0.525], + 110: [0, 0.43056, 0, 0, 0.525], + 111: [0, 0.43056, 0, 0, 0.525], + 112: [0.22222, 0.43056, 0, 0, 0.525], + 113: [0.22222, 0.43056, 0, 0, 0.525], + 114: [0, 0.43056, 0, 0, 0.525], + 115: [0, 0.43056, 0, 0, 0.525], + 116: [0, 0.55358, 0, 0, 0.525], + 117: [0, 0.43056, 0, 0, 0.525], + 118: [0, 0.43056, 0, 0, 0.525], + 119: [0, 0.43056, 0, 0, 0.525], + 120: [0, 0.43056, 0, 0, 0.525], + 121: [0.22222, 0.43056, 0, 0, 0.525], + 122: [0, 0.43056, 0, 0, 0.525], + 123: [0.08333, 0.69444, 0, 0, 0.525], + 124: [0.08333, 0.69444, 0, 0, 0.525], + 125: [0.08333, 0.69444, 0, 0, 0.525], + 126: [0, 0.61111, 0, 0, 0.525], + 127: [0, 0.61111, 0, 0, 0.525], + 160: [0, 0, 0, 0, 0.525], + 176: [0, 0.61111, 0, 0, 0.525], + 184: [0.19445, 0, 0, 0, 0.525], + 305: [0, 0.43056, 0, 0, 0.525], + 567: [0.22222, 0.43056, 0, 0, 0.525], + 711: [0, 0.56597, 0, 0, 0.525], + 713: [0, 0.56555, 0, 0, 0.525], + 714: [0, 0.61111, 0, 0, 0.525], + 715: [0, 0.61111, 0, 0, 0.525], + 728: [0, 0.61111, 0, 0, 0.525], + 730: [0, 0.61111, 0, 0, 0.525], + 770: [0, 0.61111, 0, 0, 0.525], + 771: [0, 0.61111, 0, 0, 0.525], + 776: [0, 0.61111, 0, 0, 0.525], + 915: [0, 0.61111, 0, 0, 0.525], + 916: [0, 0.61111, 0, 0, 0.525], + 920: [0, 0.61111, 0, 0, 0.525], + 923: [0, 0.61111, 0, 0, 0.525], + 926: [0, 0.61111, 0, 0, 0.525], + 928: [0, 0.61111, 0, 0, 0.525], + 931: [0, 0.61111, 0, 0, 0.525], + 933: [0, 0.61111, 0, 0, 0.525], + 934: [0, 0.61111, 0, 0, 0.525], + 936: [0, 0.61111, 0, 0, 0.525], + 937: [0, 0.61111, 0, 0, 0.525], + 8216: [0, 0.61111, 0, 0, 0.525], + 8217: [0, 0.61111, 0, 0, 0.525], + 8242: [0, 0.61111, 0, 0, 0.525], + 9251: [0.11111, 0.21944, 0, 0, 0.525] + } + }, w0 = { + slant: [0.25, 0.25, 0.25], + // sigma1 + space: [0, 0, 0], + // sigma2 + stretch: [0, 0, 0], + // sigma3 + shrink: [0, 0, 0], + // sigma4 + xHeight: [0.431, 0.431, 0.431], + // sigma5 + quad: [1, 1.171, 1.472], + // sigma6 + extraSpace: [0, 0, 0], + // sigma7 + num1: [0.677, 0.732, 0.925], + // sigma8 + num2: [0.394, 0.384, 0.387], + // sigma9 + num3: [0.444, 0.471, 0.504], + // sigma10 + denom1: [0.686, 0.752, 1.025], + // sigma11 + denom2: [0.345, 0.344, 0.532], + // sigma12 + sup1: [0.413, 0.503, 0.504], + // sigma13 + sup2: [0.363, 0.431, 0.404], + // sigma14 + sup3: [0.289, 0.286, 0.294], + // sigma15 + sub1: [0.15, 0.143, 0.2], + // sigma16 + sub2: [0.247, 0.286, 0.4], + // sigma17 + supDrop: [0.386, 0.353, 0.494], + // sigma18 + subDrop: [0.05, 0.071, 0.1], + // sigma19 + delim1: [2.39, 1.7, 1.98], + // sigma20 + delim2: [1.01, 1.157, 1.42], + // sigma21 + axisHeight: [0.25, 0.25, 0.25], + // sigma22 + // These font metrics are extracted from TeX by using tftopl on cmex10.tfm; + // they correspond to the font parameters of the extension fonts (family 3). + // See the TeXbook, page 441. In AMSTeX, the extension fonts scale; to + // match cmex7, we'd use cmex7.tfm values for script and scriptscript + // values. + defaultRuleThickness: [0.04, 0.049, 0.049], + // xi8; cmex7: 0.049 + bigOpSpacing1: [0.111, 0.111, 0.111], + // xi9 + bigOpSpacing2: [0.166, 0.166, 0.166], + // xi10 + bigOpSpacing3: [0.2, 0.2, 0.2], + // xi11 + bigOpSpacing4: [0.6, 0.611, 0.611], + // xi12; cmex7: 0.611 + bigOpSpacing5: [0.1, 0.143, 0.143], + // xi13; cmex7: 0.143 + // The \sqrt rule width is taken from the height of the surd character. + // Since we use the same font at all sizes, this thickness doesn't scale. + sqrtRuleThickness: [0.04, 0.04, 0.04], + // This value determines how large a pt is, for metrics which are defined + // in terms of pts. + // This value is also used in katex.less; if you change it make sure the + // values match. + ptPerEm: [10, 10, 10], + // The space between adjacent `|` columns in an array definition. From + // `\showthe\doublerulesep` in LaTeX. Equals 2.0 / ptPerEm. + doubleRuleSep: [0.2, 0.2, 0.2], + // The width of separator lines in {array} environments. From + // `\showthe\arrayrulewidth` in LaTeX. Equals 0.4 / ptPerEm. + arrayRuleWidth: [0.04, 0.04, 0.04], + // Two values from LaTeX source2e: + fboxsep: [0.3, 0.3, 0.3], + // 3 pt / ptPerEm + fboxrule: [0.04, 0.04, 0.04] + // 0.4 pt / ptPerEm + }, k0 = { + // Latin-1 + Å: "A", + Ð: "D", + Þ: "o", + å: "a", + ð: "d", + þ: "o", + // Cyrillic + А: "A", + Б: "B", + В: "B", + Г: "F", + Д: "A", + Е: "E", + Ж: "K", + З: "3", + И: "N", + Й: "N", + К: "K", + Л: "N", + М: "M", + Н: "H", + О: "O", + П: "N", + Р: "P", + С: "C", + Т: "T", + У: "y", + Ф: "O", + Х: "X", + Ц: "U", + Ч: "h", + Ш: "W", + Щ: "W", + Ъ: "B", + Ы: "X", + Ь: "B", + Э: "3", + Ю: "X", + Я: "R", + а: "a", + б: "b", + в: "a", + г: "r", + д: "y", + е: "e", + ж: "m", + з: "e", + и: "n", + й: "n", + к: "n", + л: "n", + м: "m", + н: "n", + о: "o", + п: "n", + р: "p", + с: "c", + т: "o", + у: "y", + ф: "b", + х: "x", + ц: "n", + ч: "n", + ш: "w", + щ: "w", + ъ: "a", + ы: "m", + ь: "a", + э: "e", + ю: "m", + я: "r" + }; + function _0(f, e) { + Nt[f] = e; + } + function Xt(f, e, t) { + if (!Nt[e]) + throw new Error("Font metrics not found for font: " + e + "."); + var n = f.charCodeAt(0), l = Nt[e][n]; + if (!l && f[0] in k0 && (n = k0[f[0]].charCodeAt(0), l = Nt[e][n]), !l && t === "text" && te(n) && (l = Nt[e][77]), l) + return { + depth: l[0], + height: l[1], + italic: l[2], + skew: l[3], + width: l[4] + }; + } + var nr = {}; + function jr(f) { + var e; + if (f >= 5 ? e = 0 : f >= 3 ? e = 1 : e = 2, !nr[e]) { + var t = nr[e] = { + cssEmPerMu: w0.quad[e] / 18 + }; + for (var n in w0) + w0.hasOwnProperty(n) && (t[n] = w0[n][e]); + } + return nr[e]; + } + var Wr = [ + // Each element contains [textsize, scriptsize, scriptscriptsize]. + // The size mappings are taken from TeX with \normalsize=10pt. + [1, 1, 1], + // size1: [5, 5, 5] \tiny + [2, 1, 1], + // size2: [6, 5, 5] + [3, 1, 1], + // size3: [7, 5, 5] \scriptsize + [4, 2, 1], + // size4: [8, 6, 5] \footnotesize + [5, 2, 1], + // size5: [9, 6, 5] \small + [6, 3, 1], + // size6: [10, 7, 5] \normalsize + [7, 4, 2], + // size7: [12, 8, 6] \large + [8, 6, 3], + // size8: [14.4, 10, 7] \Large + [9, 7, 6], + // size9: [17.28, 12, 10] \LARGE + [10, 8, 7], + // size10: [20.74, 14.4, 12] \huge + [11, 10, 9] + // size11: [24.88, 20.74, 17.28] \HUGE + ], ar = [ + // fontMetrics.js:getGlobalMetrics also uses size indexes, so if + // you change size indexes, change that function. + 0.5, + 0.6, + 0.7, + 0.8, + 0.9, + 1, + 1.2, + 1.44, + 1.728, + 2.074, + 2.488 + ], Ar = function(e, t) { + return t.size < 2 ? e : Wr[e - 1][t.size - 1]; + }, W0 = /* @__PURE__ */ function() { + function f(t) { + this.style = void 0, this.color = void 0, this.size = void 0, this.textSize = void 0, this.phantom = void 0, this.font = void 0, this.fontFamily = void 0, this.fontWeight = void 0, this.fontShape = void 0, this.sizeMultiplier = void 0, this.maxSize = void 0, this.minRuleThickness = void 0, this._fontMetrics = void 0, this.style = t.style, this.color = t.color, this.size = t.size || f.BASESIZE, this.textSize = t.textSize || this.size, this.phantom = !!t.phantom, this.font = t.font || "", this.fontFamily = t.fontFamily || "", this.fontWeight = t.fontWeight || "", this.fontShape = t.fontShape || "", this.sizeMultiplier = ar[this.size - 1], this.maxSize = t.maxSize, this.minRuleThickness = t.minRuleThickness, this._fontMetrics = void 0; + } + var e = f.prototype; + return e.extend = function(n) { + var l = { + style: this.style, + size: this.size, + textSize: this.textSize, + color: this.color, + phantom: this.phantom, + font: this.font, + fontFamily: this.fontFamily, + fontWeight: this.fontWeight, + fontShape: this.fontShape, + maxSize: this.maxSize, + minRuleThickness: this.minRuleThickness + }; + for (var c in n) + n.hasOwnProperty(c) && (l[c] = n[c]); + return new f(l); + }, e.havingStyle = function(n) { + return this.style === n ? this : this.extend({ + style: n, + size: Ar(this.textSize, n) + }); + }, e.havingCrampedStyle = function() { + return this.havingStyle(this.style.cramp()); + }, e.havingSize = function(n) { + return this.size === n && this.textSize === n ? this : this.extend({ + style: this.style.text(), + size: n, + textSize: n, + sizeMultiplier: ar[n - 1] + }); + }, e.havingBaseStyle = function(n) { + n = n || this.style.text(); + var l = Ar(f.BASESIZE, n); + return this.size === l && this.textSize === f.BASESIZE && this.style === n ? this : this.extend({ + style: n, + size: l + }); + }, e.havingBaseSizing = function() { + var n; + switch (this.style.id) { + case 4: + case 5: + n = 3; + break; + case 6: + case 7: + n = 1; + break; + default: + n = 6; + } + return this.extend({ + style: this.style.text(), + size: n + }); + }, e.withColor = function(n) { + return this.extend({ + color: n + }); + }, e.withPhantom = function() { + return this.extend({ + phantom: !0 + }); + }, e.withFont = function(n) { + return this.extend({ + font: n + }); + }, e.withTextFontFamily = function(n) { + return this.extend({ + fontFamily: n, + font: "" + }); + }, e.withTextFontWeight = function(n) { + return this.extend({ + fontWeight: n, + font: "" + }); + }, e.withTextFontShape = function(n) { + return this.extend({ + fontShape: n, + font: "" + }); + }, e.sizingClasses = function(n) { + return n.size !== this.size ? ["sizing", "reset-size" + n.size, "size" + this.size] : []; + }, e.baseSizingClasses = function() { + return this.size !== f.BASESIZE ? ["sizing", "reset-size" + this.size, "size" + f.BASESIZE] : []; + }, e.fontMetrics = function() { + return this._fontMetrics || (this._fontMetrics = jr(this.size)), this._fontMetrics; + }, e.getColor = function() { + return this.phantom ? "transparent" : this.color; + }, f; + }(); + W0.BASESIZE = 6; + var ir = W0, Tt = { + // https://en.wikibooks.org/wiki/LaTeX/Lengths and + // https://tex.stackexchange.com/a/8263 + pt: 1, + // TeX point + mm: 7227 / 2540, + // millimeter + cm: 7227 / 254, + // centimeter + in: 72.27, + // inch + bp: 803 / 800, + // big (PostScript) points + pc: 12, + // pica + dd: 1238 / 1157, + // didot + cc: 14856 / 1157, + // cicero (12 didot) + nd: 685 / 642, + // new didot + nc: 1370 / 107, + // new cicero (12 new didot) + sp: 1 / 65536, + // scaled point (TeX's internal smallest unit) + // https://tex.stackexchange.com/a/41371 + px: 803 / 800 + // \pdfpxdimen defaults to 1 bp in pdfTeX and LuaTeX + }, x0 = { + ex: !0, + em: !0, + mu: !0 + }, lr = function(e) { + return typeof e != "string" && (e = e.unit), e in Tt || e in x0 || e === "ex"; + }, Pe = function(e, t) { + var n; + if (e.unit in Tt) + n = Tt[e.unit] / t.fontMetrics().ptPerEm / t.sizeMultiplier; + else if (e.unit === "mu") + n = t.fontMetrics().cssEmPerMu; + else { + var l; + if (t.style.isTight() ? l = t.havingStyle(t.style.text()) : l = t, e.unit === "ex") + n = l.fontMetrics().xHeight; + else if (e.unit === "em") + n = l.fontMetrics().quad; + else + throw new u("Invalid unit: '" + e.unit + "'"); + l !== t && (n *= l.sizeMultiplier / t.sizeMultiplier); + } + return Math.min(e.number * n, t.maxSize); + }, ee = function(e) { + return +e.toFixed(4) + "em"; + }, ft = function(e) { + return e.filter(function(t) { + return t; + }).join(" "); + }, Yr = function(e, t, n) { + if (this.classes = e || [], this.attributes = {}, this.height = 0, this.depth = 0, this.maxFontSize = 0, this.style = n || {}, t) { + t.style.isTight() && this.classes.push("mtight"); + var l = t.getColor(); + l && (this.style.color = l); + } + }, Xr = function(e) { + var t = document.createElement(e); + t.className = ft(this.classes); + for (var n in this.style) + this.style.hasOwnProperty(n) && (t.style[n] = this.style[n]); + for (var l in this.attributes) + this.attributes.hasOwnProperty(l) && t.setAttribute(l, this.attributes[l]); + for (var c = 0; c < this.children.length; c++) + t.appendChild(this.children[c].toNode()); + return t; + }, nt = function(e) { + var t = "<" + e; + this.classes.length && (t += ' class="' + V.escape(ft(this.classes)) + '"'); + var n = ""; + for (var l in this.style) + this.style.hasOwnProperty(l) && (n += V.hyphenate(l) + ":" + this.style[l] + ";"); + n && (t += ' style="' + V.escape(n) + '"'); + for (var c in this.attributes) + this.attributes.hasOwnProperty(c) && (t += " " + c + '="' + V.escape(this.attributes[c]) + '"'); + t += ">"; + for (var m = 0; m < this.children.length; m++) + t += this.children[m].toMarkup(); + return t += "", t; + }, Rt = /* @__PURE__ */ function() { + function f(t, n, l, c) { + this.children = void 0, this.attributes = void 0, this.classes = void 0, this.height = void 0, this.depth = void 0, this.width = void 0, this.maxFontSize = void 0, this.style = void 0, Yr.call(this, t, l, c), this.children = n || []; + } + var e = f.prototype; + return e.setAttribute = function(n, l) { + this.attributes[n] = l; + }, e.hasClass = function(n) { + return V.contains(this.classes, n); + }, e.toNode = function() { + return Xr.call(this, "span"); + }, e.toMarkup = function() { + return nt.call(this, "span"); + }, f; + }(), Tr = /* @__PURE__ */ function() { + function f(t, n, l, c) { + this.children = void 0, this.attributes = void 0, this.classes = void 0, this.height = void 0, this.depth = void 0, this.maxFontSize = void 0, this.style = void 0, Yr.call(this, n, c), this.children = l || [], this.setAttribute("href", t); + } + var e = f.prototype; + return e.setAttribute = function(n, l) { + this.attributes[n] = l; + }, e.hasClass = function(n) { + return V.contains(this.classes, n); + }, e.toNode = function() { + return Xr.call(this, "a"); + }, e.toMarkup = function() { + return nt.call(this, "a"); + }, f; + }(), Zr = /* @__PURE__ */ function() { + function f(t, n, l) { + this.src = void 0, this.alt = void 0, this.classes = void 0, this.height = void 0, this.depth = void 0, this.maxFontSize = void 0, this.style = void 0, this.alt = n, this.src = t, this.classes = ["mord"], this.style = l; + } + var e = f.prototype; + return e.hasClass = function(n) { + return V.contains(this.classes, n); + }, e.toNode = function() { + var n = document.createElement("img"); + n.src = this.src, n.alt = this.alt, n.className = "mord"; + for (var l in this.style) + this.style.hasOwnProperty(l) && (n.style[l] = this.style[l]); + return n; + }, e.toMarkup = function() { + var n = "" + this.alt + " 0 && (l = document.createElement("span"), l.style.marginRight = ee(this.italic)), this.classes.length > 0 && (l = l || document.createElement("span"), l.className = ft(this.classes)); + for (var c in this.style) + this.style.hasOwnProperty(c) && (l = l || document.createElement("span"), l.style[c] = this.style[c]); + return l ? (l.appendChild(n), l) : n; + }, e.toMarkup = function() { + var n = !1, l = " 0 && (c += "margin-right:" + this.italic + "em;"); + for (var m in this.style) + this.style.hasOwnProperty(m) && (c += V.hyphenate(m) + ":" + this.style[m] + ";"); + c && (n = !0, l += ' style="' + V.escape(c) + '"'); + var b = V.escape(this.text); + return n ? (l += ">", l += b, l += "", l) : b; + }, f; + }(), Ft = /* @__PURE__ */ function() { + function f(t, n) { + this.children = void 0, this.attributes = void 0, this.children = t || [], this.attributes = n || {}; + } + var e = f.prototype; + return e.toNode = function() { + var n = "http://www.w3.org/2000/svg", l = document.createElementNS(n, "svg"); + for (var c in this.attributes) + Object.prototype.hasOwnProperty.call(this.attributes, c) && l.setAttribute(c, this.attributes[c]); + for (var m = 0; m < this.children.length; m++) + l.appendChild(this.children[m].toNode()); + return l; + }, e.toMarkup = function() { + var n = '" : ""; + }, f; + }(), S0 = /* @__PURE__ */ function() { + function f(t) { + this.attributes = void 0, this.attributes = t || {}; + } + var e = f.prototype; + return e.toNode = function() { + var n = "http://www.w3.org/2000/svg", l = document.createElementNS(n, "line"); + for (var c in this.attributes) + Object.prototype.hasOwnProperty.call(this.attributes, c) && l.setAttribute(c, this.attributes[c]); + return l; + }, e.toMarkup = function() { + var n = " but got " + String(f) + "."); + } + var c0 = { + bin: 1, + close: 1, + inner: 1, + open: 1, + punct: 1, + rel: 1 + }, zr = { + "accent-token": 1, + mathord: 1, + "op-token": 1, + spacing: 1, + textord: 1 + }, Y0 = { + math: {}, + text: {} + }, Ve = Y0; + function h(f, e, t, n, l, c) { + Y0[f][l] = { + font: e, + group: t, + replace: n + }, c && n && (Y0[f][n] = Y0[f][l]); + } + var d = "math", j = "text", y = "main", T = "ams", He = "accent-token", oe = "bin", ot = "close", fe = "inner", z = "mathord", Y = "op-token", le = "open", Re = "punct", A = "rel", je = "spacing", E = "textord"; + h(d, y, A, "≡", "\\equiv", !0), h(d, y, A, "≺", "\\prec", !0), h(d, y, A, "≻", "\\succ", !0), h(d, y, A, "∼", "\\sim", !0), h(d, y, A, "⊥", "\\perp"), h(d, y, A, "⪯", "\\preceq", !0), h(d, y, A, "⪰", "\\succeq", !0), h(d, y, A, "≃", "\\simeq", !0), h(d, y, A, "∣", "\\mid", !0), h(d, y, A, "≪", "\\ll", !0), h(d, y, A, "≫", "\\gg", !0), h(d, y, A, "≍", "\\asymp", !0), h(d, y, A, "∥", "\\parallel"), h(d, y, A, "⋈", "\\bowtie", !0), h(d, y, A, "⌣", "\\smile", !0), h(d, y, A, "⊑", "\\sqsubseteq", !0), h(d, y, A, "⊒", "\\sqsupseteq", !0), h(d, y, A, "≐", "\\doteq", !0), h(d, y, A, "⌢", "\\frown", !0), h(d, y, A, "∋", "\\ni", !0), h(d, y, A, "∝", "\\propto", !0), h(d, y, A, "⊢", "\\vdash", !0), h(d, y, A, "⊣", "\\dashv", !0), h(d, y, A, "∋", "\\owns"), h(d, y, Re, ".", "\\ldotp"), h(d, y, Re, "⋅", "\\cdotp"), h(d, y, E, "#", "\\#"), h(j, y, E, "#", "\\#"), h(d, y, E, "&", "\\&"), h(j, y, E, "&", "\\&"), h(d, y, E, "ℵ", "\\aleph", !0), h(d, y, E, "∀", "\\forall", !0), h(d, y, E, "ℏ", "\\hbar", !0), h(d, y, E, "∃", "\\exists", !0), h(d, y, E, "∇", "\\nabla", !0), h(d, y, E, "♭", "\\flat", !0), h(d, y, E, "ℓ", "\\ell", !0), h(d, y, E, "♮", "\\natural", !0), h(d, y, E, "♣", "\\clubsuit", !0), h(d, y, E, "℘", "\\wp", !0), h(d, y, E, "♯", "\\sharp", !0), h(d, y, E, "♢", "\\diamondsuit", !0), h(d, y, E, "ℜ", "\\Re", !0), h(d, y, E, "♡", "\\heartsuit", !0), h(d, y, E, "ℑ", "\\Im", !0), h(d, y, E, "♠", "\\spadesuit", !0), h(d, y, E, "§", "\\S", !0), h(j, y, E, "§", "\\S"), h(d, y, E, "¶", "\\P", !0), h(j, y, E, "¶", "\\P"), h(d, y, E, "†", "\\dag"), h(j, y, E, "†", "\\dag"), h(j, y, E, "†", "\\textdagger"), h(d, y, E, "‡", "\\ddag"), h(j, y, E, "‡", "\\ddag"), h(j, y, E, "‡", "\\textdaggerdbl"), h(d, y, ot, "⎱", "\\rmoustache", !0), h(d, y, le, "⎰", "\\lmoustache", !0), h(d, y, ot, "⟯", "\\rgroup", !0), h(d, y, le, "⟮", "\\lgroup", !0), h(d, y, oe, "∓", "\\mp", !0), h(d, y, oe, "⊖", "\\ominus", !0), h(d, y, oe, "⊎", "\\uplus", !0), h(d, y, oe, "⊓", "\\sqcap", !0), h(d, y, oe, "∗", "\\ast"), h(d, y, oe, "⊔", "\\sqcup", !0), h(d, y, oe, "◯", "\\bigcirc", !0), h(d, y, oe, "∙", "\\bullet", !0), h(d, y, oe, "‡", "\\ddagger"), h(d, y, oe, "≀", "\\wr", !0), h(d, y, oe, "⨿", "\\amalg"), h(d, y, oe, "&", "\\And"), h(d, y, A, "⟵", "\\longleftarrow", !0), h(d, y, A, "⇐", "\\Leftarrow", !0), h(d, y, A, "⟸", "\\Longleftarrow", !0), h(d, y, A, "⟶", "\\longrightarrow", !0), h(d, y, A, "⇒", "\\Rightarrow", !0), h(d, y, A, "⟹", "\\Longrightarrow", !0), h(d, y, A, "↔", "\\leftrightarrow", !0), h(d, y, A, "⟷", "\\longleftrightarrow", !0), h(d, y, A, "⇔", "\\Leftrightarrow", !0), h(d, y, A, "⟺", "\\Longleftrightarrow", !0), h(d, y, A, "↦", "\\mapsto", !0), h(d, y, A, "⟼", "\\longmapsto", !0), h(d, y, A, "↗", "\\nearrow", !0), h(d, y, A, "↩", "\\hookleftarrow", !0), h(d, y, A, "↪", "\\hookrightarrow", !0), h(d, y, A, "↘", "\\searrow", !0), h(d, y, A, "↼", "\\leftharpoonup", !0), h(d, y, A, "⇀", "\\rightharpoonup", !0), h(d, y, A, "↙", "\\swarrow", !0), h(d, y, A, "↽", "\\leftharpoondown", !0), h(d, y, A, "⇁", "\\rightharpoondown", !0), h(d, y, A, "↖", "\\nwarrow", !0), h(d, y, A, "⇌", "\\rightleftharpoons", !0), h(d, T, A, "≮", "\\nless", !0), h(d, T, A, "", "\\@nleqslant"), h(d, T, A, "", "\\@nleqq"), h(d, T, A, "⪇", "\\lneq", !0), h(d, T, A, "≨", "\\lneqq", !0), h(d, T, A, "", "\\@lvertneqq"), h(d, T, A, "⋦", "\\lnsim", !0), h(d, T, A, "⪉", "\\lnapprox", !0), h(d, T, A, "⊀", "\\nprec", !0), h(d, T, A, "⋠", "\\npreceq", !0), h(d, T, A, "⋨", "\\precnsim", !0), h(d, T, A, "⪹", "\\precnapprox", !0), h(d, T, A, "≁", "\\nsim", !0), h(d, T, A, "", "\\@nshortmid"), h(d, T, A, "∤", "\\nmid", !0), h(d, T, A, "⊬", "\\nvdash", !0), h(d, T, A, "⊭", "\\nvDash", !0), h(d, T, A, "⋪", "\\ntriangleleft"), h(d, T, A, "⋬", "\\ntrianglelefteq", !0), h(d, T, A, "⊊", "\\subsetneq", !0), h(d, T, A, "", "\\@varsubsetneq"), h(d, T, A, "⫋", "\\subsetneqq", !0), h(d, T, A, "", "\\@varsubsetneqq"), h(d, T, A, "≯", "\\ngtr", !0), h(d, T, A, "", "\\@ngeqslant"), h(d, T, A, "", "\\@ngeqq"), h(d, T, A, "⪈", "\\gneq", !0), h(d, T, A, "≩", "\\gneqq", !0), h(d, T, A, "", "\\@gvertneqq"), h(d, T, A, "⋧", "\\gnsim", !0), h(d, T, A, "⪊", "\\gnapprox", !0), h(d, T, A, "⊁", "\\nsucc", !0), h(d, T, A, "⋡", "\\nsucceq", !0), h(d, T, A, "⋩", "\\succnsim", !0), h(d, T, A, "⪺", "\\succnapprox", !0), h(d, T, A, "≆", "\\ncong", !0), h(d, T, A, "", "\\@nshortparallel"), h(d, T, A, "∦", "\\nparallel", !0), h(d, T, A, "⊯", "\\nVDash", !0), h(d, T, A, "⋫", "\\ntriangleright"), h(d, T, A, "⋭", "\\ntrianglerighteq", !0), h(d, T, A, "", "\\@nsupseteqq"), h(d, T, A, "⊋", "\\supsetneq", !0), h(d, T, A, "", "\\@varsupsetneq"), h(d, T, A, "⫌", "\\supsetneqq", !0), h(d, T, A, "", "\\@varsupsetneqq"), h(d, T, A, "⊮", "\\nVdash", !0), h(d, T, A, "⪵", "\\precneqq", !0), h(d, T, A, "⪶", "\\succneqq", !0), h(d, T, A, "", "\\@nsubseteqq"), h(d, T, oe, "⊴", "\\unlhd"), h(d, T, oe, "⊵", "\\unrhd"), h(d, T, A, "↚", "\\nleftarrow", !0), h(d, T, A, "↛", "\\nrightarrow", !0), h(d, T, A, "⇍", "\\nLeftarrow", !0), h(d, T, A, "⇏", "\\nRightarrow", !0), h(d, T, A, "↮", "\\nleftrightarrow", !0), h(d, T, A, "⇎", "\\nLeftrightarrow", !0), h(d, T, A, "△", "\\vartriangle"), h(d, T, E, "ℏ", "\\hslash"), h(d, T, E, "▽", "\\triangledown"), h(d, T, E, "◊", "\\lozenge"), h(d, T, E, "Ⓢ", "\\circledS"), h(d, T, E, "®", "\\circledR"), h(j, T, E, "®", "\\circledR"), h(d, T, E, "∡", "\\measuredangle", !0), h(d, T, E, "∄", "\\nexists"), h(d, T, E, "℧", "\\mho"), h(d, T, E, "Ⅎ", "\\Finv", !0), h(d, T, E, "⅁", "\\Game", !0), h(d, T, E, "‵", "\\backprime"), h(d, T, E, "▲", "\\blacktriangle"), h(d, T, E, "▼", "\\blacktriangledown"), h(d, T, E, "■", "\\blacksquare"), h(d, T, E, "⧫", "\\blacklozenge"), h(d, T, E, "★", "\\bigstar"), h(d, T, E, "∢", "\\sphericalangle", !0), h(d, T, E, "∁", "\\complement", !0), h(d, T, E, "ð", "\\eth", !0), h(j, y, E, "ð", "ð"), h(d, T, E, "╱", "\\diagup"), h(d, T, E, "╲", "\\diagdown"), h(d, T, E, "□", "\\square"), h(d, T, E, "□", "\\Box"), h(d, T, E, "◊", "\\Diamond"), h(d, T, E, "¥", "\\yen", !0), h(j, T, E, "¥", "\\yen", !0), h(d, T, E, "✓", "\\checkmark", !0), h(j, T, E, "✓", "\\checkmark"), h(d, T, E, "ℶ", "\\beth", !0), h(d, T, E, "ℸ", "\\daleth", !0), h(d, T, E, "ℷ", "\\gimel", !0), h(d, T, E, "ϝ", "\\digamma", !0), h(d, T, E, "ϰ", "\\varkappa"), h(d, T, le, "┌", "\\@ulcorner", !0), h(d, T, ot, "┐", "\\@urcorner", !0), h(d, T, le, "└", "\\@llcorner", !0), h(d, T, ot, "┘", "\\@lrcorner", !0), h(d, T, A, "≦", "\\leqq", !0), h(d, T, A, "⩽", "\\leqslant", !0), h(d, T, A, "⪕", "\\eqslantless", !0), h(d, T, A, "≲", "\\lesssim", !0), h(d, T, A, "⪅", "\\lessapprox", !0), h(d, T, A, "≊", "\\approxeq", !0), h(d, T, oe, "⋖", "\\lessdot"), h(d, T, A, "⋘", "\\lll", !0), h(d, T, A, "≶", "\\lessgtr", !0), h(d, T, A, "⋚", "\\lesseqgtr", !0), h(d, T, A, "⪋", "\\lesseqqgtr", !0), h(d, T, A, "≑", "\\doteqdot"), h(d, T, A, "≓", "\\risingdotseq", !0), h(d, T, A, "≒", "\\fallingdotseq", !0), h(d, T, A, "∽", "\\backsim", !0), h(d, T, A, "⋍", "\\backsimeq", !0), h(d, T, A, "⫅", "\\subseteqq", !0), h(d, T, A, "⋐", "\\Subset", !0), h(d, T, A, "⊏", "\\sqsubset", !0), h(d, T, A, "≼", "\\preccurlyeq", !0), h(d, T, A, "⋞", "\\curlyeqprec", !0), h(d, T, A, "≾", "\\precsim", !0), h(d, T, A, "⪷", "\\precapprox", !0), h(d, T, A, "⊲", "\\vartriangleleft"), h(d, T, A, "⊴", "\\trianglelefteq"), h(d, T, A, "⊨", "\\vDash", !0), h(d, T, A, "⊪", "\\Vvdash", !0), h(d, T, A, "⌣", "\\smallsmile"), h(d, T, A, "⌢", "\\smallfrown"), h(d, T, A, "≏", "\\bumpeq", !0), h(d, T, A, "≎", "\\Bumpeq", !0), h(d, T, A, "≧", "\\geqq", !0), h(d, T, A, "⩾", "\\geqslant", !0), h(d, T, A, "⪖", "\\eqslantgtr", !0), h(d, T, A, "≳", "\\gtrsim", !0), h(d, T, A, "⪆", "\\gtrapprox", !0), h(d, T, oe, "⋗", "\\gtrdot"), h(d, T, A, "⋙", "\\ggg", !0), h(d, T, A, "≷", "\\gtrless", !0), h(d, T, A, "⋛", "\\gtreqless", !0), h(d, T, A, "⪌", "\\gtreqqless", !0), h(d, T, A, "≖", "\\eqcirc", !0), h(d, T, A, "≗", "\\circeq", !0), h(d, T, A, "≜", "\\triangleq", !0), h(d, T, A, "∼", "\\thicksim"), h(d, T, A, "≈", "\\thickapprox"), h(d, T, A, "⫆", "\\supseteqq", !0), h(d, T, A, "⋑", "\\Supset", !0), h(d, T, A, "⊐", "\\sqsupset", !0), h(d, T, A, "≽", "\\succcurlyeq", !0), h(d, T, A, "⋟", "\\curlyeqsucc", !0), h(d, T, A, "≿", "\\succsim", !0), h(d, T, A, "⪸", "\\succapprox", !0), h(d, T, A, "⊳", "\\vartriangleright"), h(d, T, A, "⊵", "\\trianglerighteq"), h(d, T, A, "⊩", "\\Vdash", !0), h(d, T, A, "∣", "\\shortmid"), h(d, T, A, "∥", "\\shortparallel"), h(d, T, A, "≬", "\\between", !0), h(d, T, A, "⋔", "\\pitchfork", !0), h(d, T, A, "∝", "\\varpropto"), h(d, T, A, "◀", "\\blacktriangleleft"), h(d, T, A, "∴", "\\therefore", !0), h(d, T, A, "∍", "\\backepsilon"), h(d, T, A, "▶", "\\blacktriangleright"), h(d, T, A, "∵", "\\because", !0), h(d, T, A, "⋘", "\\llless"), h(d, T, A, "⋙", "\\gggtr"), h(d, T, oe, "⊲", "\\lhd"), h(d, T, oe, "⊳", "\\rhd"), h(d, T, A, "≂", "\\eqsim", !0), h(d, y, A, "⋈", "\\Join"), h(d, T, A, "≑", "\\Doteq", !0), h(d, T, oe, "∔", "\\dotplus", !0), h(d, T, oe, "∖", "\\smallsetminus"), h(d, T, oe, "⋒", "\\Cap", !0), h(d, T, oe, "⋓", "\\Cup", !0), h(d, T, oe, "⩞", "\\doublebarwedge", !0), h(d, T, oe, "⊟", "\\boxminus", !0), h(d, T, oe, "⊞", "\\boxplus", !0), h(d, T, oe, "⋇", "\\divideontimes", !0), h(d, T, oe, "⋉", "\\ltimes", !0), h(d, T, oe, "⋊", "\\rtimes", !0), h(d, T, oe, "⋋", "\\leftthreetimes", !0), h(d, T, oe, "⋌", "\\rightthreetimes", !0), h(d, T, oe, "⋏", "\\curlywedge", !0), h(d, T, oe, "⋎", "\\curlyvee", !0), h(d, T, oe, "⊝", "\\circleddash", !0), h(d, T, oe, "⊛", "\\circledast", !0), h(d, T, oe, "⋅", "\\centerdot"), h(d, T, oe, "⊺", "\\intercal", !0), h(d, T, oe, "⋒", "\\doublecap"), h(d, T, oe, "⋓", "\\doublecup"), h(d, T, oe, "⊠", "\\boxtimes", !0), h(d, T, A, "⇢", "\\dashrightarrow", !0), h(d, T, A, "⇠", "\\dashleftarrow", !0), h(d, T, A, "⇇", "\\leftleftarrows", !0), h(d, T, A, "⇆", "\\leftrightarrows", !0), h(d, T, A, "⇚", "\\Lleftarrow", !0), h(d, T, A, "↞", "\\twoheadleftarrow", !0), h(d, T, A, "↢", "\\leftarrowtail", !0), h(d, T, A, "↫", "\\looparrowleft", !0), h(d, T, A, "⇋", "\\leftrightharpoons", !0), h(d, T, A, "↶", "\\curvearrowleft", !0), h(d, T, A, "↺", "\\circlearrowleft", !0), h(d, T, A, "↰", "\\Lsh", !0), h(d, T, A, "⇈", "\\upuparrows", !0), h(d, T, A, "↿", "\\upharpoonleft", !0), h(d, T, A, "⇃", "\\downharpoonleft", !0), h(d, y, A, "⊶", "\\origof", !0), h(d, y, A, "⊷", "\\imageof", !0), h(d, T, A, "⊸", "\\multimap", !0), h(d, T, A, "↭", "\\leftrightsquigarrow", !0), h(d, T, A, "⇉", "\\rightrightarrows", !0), h(d, T, A, "⇄", "\\rightleftarrows", !0), h(d, T, A, "↠", "\\twoheadrightarrow", !0), h(d, T, A, "↣", "\\rightarrowtail", !0), h(d, T, A, "↬", "\\looparrowright", !0), h(d, T, A, "↷", "\\curvearrowright", !0), h(d, T, A, "↻", "\\circlearrowright", !0), h(d, T, A, "↱", "\\Rsh", !0), h(d, T, A, "⇊", "\\downdownarrows", !0), h(d, T, A, "↾", "\\upharpoonright", !0), h(d, T, A, "⇂", "\\downharpoonright", !0), h(d, T, A, "⇝", "\\rightsquigarrow", !0), h(d, T, A, "⇝", "\\leadsto"), h(d, T, A, "⇛", "\\Rrightarrow", !0), h(d, T, A, "↾", "\\restriction"), h(d, y, E, "‘", "`"), h(d, y, E, "$", "\\$"), h(j, y, E, "$", "\\$"), h(j, y, E, "$", "\\textdollar"), h(d, y, E, "%", "\\%"), h(j, y, E, "%", "\\%"), h(d, y, E, "_", "\\_"), h(j, y, E, "_", "\\_"), h(j, y, E, "_", "\\textunderscore"), h(d, y, E, "∠", "\\angle", !0), h(d, y, E, "∞", "\\infty", !0), h(d, y, E, "′", "\\prime"), h(d, y, E, "△", "\\triangle"), h(d, y, E, "Γ", "\\Gamma", !0), h(d, y, E, "Δ", "\\Delta", !0), h(d, y, E, "Θ", "\\Theta", !0), h(d, y, E, "Λ", "\\Lambda", !0), h(d, y, E, "Ξ", "\\Xi", !0), h(d, y, E, "Π", "\\Pi", !0), h(d, y, E, "Σ", "\\Sigma", !0), h(d, y, E, "Υ", "\\Upsilon", !0), h(d, y, E, "Φ", "\\Phi", !0), h(d, y, E, "Ψ", "\\Psi", !0), h(d, y, E, "Ω", "\\Omega", !0), h(d, y, E, "A", "Α"), h(d, y, E, "B", "Β"), h(d, y, E, "E", "Ε"), h(d, y, E, "Z", "Ζ"), h(d, y, E, "H", "Η"), h(d, y, E, "I", "Ι"), h(d, y, E, "K", "Κ"), h(d, y, E, "M", "Μ"), h(d, y, E, "N", "Ν"), h(d, y, E, "O", "Ο"), h(d, y, E, "P", "Ρ"), h(d, y, E, "T", "Τ"), h(d, y, E, "X", "Χ"), h(d, y, E, "¬", "\\neg", !0), h(d, y, E, "¬", "\\lnot"), h(d, y, E, "⊤", "\\top"), h(d, y, E, "⊥", "\\bot"), h(d, y, E, "∅", "\\emptyset"), h(d, T, E, "∅", "\\varnothing"), h(d, y, z, "α", "\\alpha", !0), h(d, y, z, "β", "\\beta", !0), h(d, y, z, "γ", "\\gamma", !0), h(d, y, z, "δ", "\\delta", !0), h(d, y, z, "ϵ", "\\epsilon", !0), h(d, y, z, "ζ", "\\zeta", !0), h(d, y, z, "η", "\\eta", !0), h(d, y, z, "θ", "\\theta", !0), h(d, y, z, "ι", "\\iota", !0), h(d, y, z, "κ", "\\kappa", !0), h(d, y, z, "λ", "\\lambda", !0), h(d, y, z, "μ", "\\mu", !0), h(d, y, z, "ν", "\\nu", !0), h(d, y, z, "ξ", "\\xi", !0), h(d, y, z, "ο", "\\omicron", !0), h(d, y, z, "π", "\\pi", !0), h(d, y, z, "ρ", "\\rho", !0), h(d, y, z, "σ", "\\sigma", !0), h(d, y, z, "τ", "\\tau", !0), h(d, y, z, "υ", "\\upsilon", !0), h(d, y, z, "ϕ", "\\phi", !0), h(d, y, z, "χ", "\\chi", !0), h(d, y, z, "ψ", "\\psi", !0), h(d, y, z, "ω", "\\omega", !0), h(d, y, z, "ε", "\\varepsilon", !0), h(d, y, z, "ϑ", "\\vartheta", !0), h(d, y, z, "ϖ", "\\varpi", !0), h(d, y, z, "ϱ", "\\varrho", !0), h(d, y, z, "ς", "\\varsigma", !0), h(d, y, z, "φ", "\\varphi", !0), h(d, y, oe, "∗", "*", !0), h(d, y, oe, "+", "+"), h(d, y, oe, "−", "-", !0), h(d, y, oe, "⋅", "\\cdot", !0), h(d, y, oe, "∘", "\\circ", !0), h(d, y, oe, "÷", "\\div", !0), h(d, y, oe, "±", "\\pm", !0), h(d, y, oe, "×", "\\times", !0), h(d, y, oe, "∩", "\\cap", !0), h(d, y, oe, "∪", "\\cup", !0), h(d, y, oe, "∖", "\\setminus", !0), h(d, y, oe, "∧", "\\land"), h(d, y, oe, "∨", "\\lor"), h(d, y, oe, "∧", "\\wedge", !0), h(d, y, oe, "∨", "\\vee", !0), h(d, y, E, "√", "\\surd"), h(d, y, le, "⟨", "\\langle", !0), h(d, y, le, "∣", "\\lvert"), h(d, y, le, "∥", "\\lVert"), h(d, y, ot, "?", "?"), h(d, y, ot, "!", "!"), h(d, y, ot, "⟩", "\\rangle", !0), h(d, y, ot, "∣", "\\rvert"), h(d, y, ot, "∥", "\\rVert"), h(d, y, A, "=", "="), h(d, y, A, ":", ":"), h(d, y, A, "≈", "\\approx", !0), h(d, y, A, "≅", "\\cong", !0), h(d, y, A, "≥", "\\ge"), h(d, y, A, "≥", "\\geq", !0), h(d, y, A, "←", "\\gets"), h(d, y, A, ">", "\\gt", !0), h(d, y, A, "∈", "\\in", !0), h(d, y, A, "", "\\@not"), h(d, y, A, "⊂", "\\subset", !0), h(d, y, A, "⊃", "\\supset", !0), h(d, y, A, "⊆", "\\subseteq", !0), h(d, y, A, "⊇", "\\supseteq", !0), h(d, T, A, "⊈", "\\nsubseteq", !0), h(d, T, A, "⊉", "\\nsupseteq", !0), h(d, y, A, "⊨", "\\models"), h(d, y, A, "←", "\\leftarrow", !0), h(d, y, A, "≤", "\\le"), h(d, y, A, "≤", "\\leq", !0), h(d, y, A, "<", "\\lt", !0), h(d, y, A, "→", "\\rightarrow", !0), h(d, y, A, "→", "\\to"), h(d, T, A, "≱", "\\ngeq", !0), h(d, T, A, "≰", "\\nleq", !0), h(d, y, je, " ", "\\ "), h(d, y, je, " ", "\\space"), h(d, y, je, " ", "\\nobreakspace"), h(j, y, je, " ", "\\ "), h(j, y, je, " ", " "), h(j, y, je, " ", "\\space"), h(j, y, je, " ", "\\nobreakspace"), h(d, y, je, null, "\\nobreak"), h(d, y, je, null, "\\allowbreak"), h(d, y, Re, ",", ","), h(d, y, Re, ";", ";"), h(d, T, oe, "⊼", "\\barwedge", !0), h(d, T, oe, "⊻", "\\veebar", !0), h(d, y, oe, "⊙", "\\odot", !0), h(d, y, oe, "⊕", "\\oplus", !0), h(d, y, oe, "⊗", "\\otimes", !0), h(d, y, E, "∂", "\\partial", !0), h(d, y, oe, "⊘", "\\oslash", !0), h(d, T, oe, "⊚", "\\circledcirc", !0), h(d, T, oe, "⊡", "\\boxdot", !0), h(d, y, oe, "△", "\\bigtriangleup"), h(d, y, oe, "▽", "\\bigtriangledown"), h(d, y, oe, "†", "\\dagger"), h(d, y, oe, "⋄", "\\diamond"), h(d, y, oe, "⋆", "\\star"), h(d, y, oe, "◃", "\\triangleleft"), h(d, y, oe, "▹", "\\triangleright"), h(d, y, le, "{", "\\{"), h(j, y, E, "{", "\\{"), h(j, y, E, "{", "\\textbraceleft"), h(d, y, ot, "}", "\\}"), h(j, y, E, "}", "\\}"), h(j, y, E, "}", "\\textbraceright"), h(d, y, le, "{", "\\lbrace"), h(d, y, ot, "}", "\\rbrace"), h(d, y, le, "[", "\\lbrack", !0), h(j, y, E, "[", "\\lbrack", !0), h(d, y, ot, "]", "\\rbrack", !0), h(j, y, E, "]", "\\rbrack", !0), h(d, y, le, "(", "\\lparen", !0), h(d, y, ot, ")", "\\rparen", !0), h(j, y, E, "<", "\\textless", !0), h(j, y, E, ">", "\\textgreater", !0), h(d, y, le, "⌊", "\\lfloor", !0), h(d, y, ot, "⌋", "\\rfloor", !0), h(d, y, le, "⌈", "\\lceil", !0), h(d, y, ot, "⌉", "\\rceil", !0), h(d, y, E, "\\", "\\backslash"), h(d, y, E, "∣", "|"), h(d, y, E, "∣", "\\vert"), h(j, y, E, "|", "\\textbar", !0), h(d, y, E, "∥", "\\|"), h(d, y, E, "∥", "\\Vert"), h(j, y, E, "∥", "\\textbardbl"), h(j, y, E, "~", "\\textasciitilde"), h(j, y, E, "\\", "\\textbackslash"), h(j, y, E, "^", "\\textasciicircum"), h(d, y, A, "↑", "\\uparrow", !0), h(d, y, A, "⇑", "\\Uparrow", !0), h(d, y, A, "↓", "\\downarrow", !0), h(d, y, A, "⇓", "\\Downarrow", !0), h(d, y, A, "↕", "\\updownarrow", !0), h(d, y, A, "⇕", "\\Updownarrow", !0), h(d, y, Y, "∐", "\\coprod"), h(d, y, Y, "⋁", "\\bigvee"), h(d, y, Y, "⋀", "\\bigwedge"), h(d, y, Y, "⨄", "\\biguplus"), h(d, y, Y, "⋂", "\\bigcap"), h(d, y, Y, "⋃", "\\bigcup"), h(d, y, Y, "∫", "\\int"), h(d, y, Y, "∫", "\\intop"), h(d, y, Y, "∬", "\\iint"), h(d, y, Y, "∭", "\\iiint"), h(d, y, Y, "∏", "\\prod"), h(d, y, Y, "∑", "\\sum"), h(d, y, Y, "⨂", "\\bigotimes"), h(d, y, Y, "⨁", "\\bigoplus"), h(d, y, Y, "⨀", "\\bigodot"), h(d, y, Y, "∮", "\\oint"), h(d, y, Y, "∯", "\\oiint"), h(d, y, Y, "∰", "\\oiiint"), h(d, y, Y, "⨆", "\\bigsqcup"), h(d, y, Y, "∫", "\\smallint"), h(j, y, fe, "…", "\\textellipsis"), h(d, y, fe, "…", "\\mathellipsis"), h(j, y, fe, "…", "\\ldots", !0), h(d, y, fe, "…", "\\ldots", !0), h(d, y, fe, "⋯", "\\@cdots", !0), h(d, y, fe, "⋱", "\\ddots", !0), h(d, y, E, "⋮", "\\varvdots"), h(d, y, He, "ˊ", "\\acute"), h(d, y, He, "ˋ", "\\grave"), h(d, y, He, "¨", "\\ddot"), h(d, y, He, "~", "\\tilde"), h(d, y, He, "ˉ", "\\bar"), h(d, y, He, "˘", "\\breve"), h(d, y, He, "ˇ", "\\check"), h(d, y, He, "^", "\\hat"), h(d, y, He, "⃗", "\\vec"), h(d, y, He, "˙", "\\dot"), h(d, y, He, "˚", "\\mathring"), h(d, y, z, "", "\\@imath"), h(d, y, z, "", "\\@jmath"), h(d, y, E, "ı", "ı"), h(d, y, E, "ȷ", "ȷ"), h(j, y, E, "ı", "\\i", !0), h(j, y, E, "ȷ", "\\j", !0), h(j, y, E, "ß", "\\ss", !0), h(j, y, E, "æ", "\\ae", !0), h(j, y, E, "œ", "\\oe", !0), h(j, y, E, "ø", "\\o", !0), h(j, y, E, "Æ", "\\AE", !0), h(j, y, E, "Œ", "\\OE", !0), h(j, y, E, "Ø", "\\O", !0), h(j, y, He, "ˊ", "\\'"), h(j, y, He, "ˋ", "\\`"), h(j, y, He, "ˆ", "\\^"), h(j, y, He, "˜", "\\~"), h(j, y, He, "ˉ", "\\="), h(j, y, He, "˘", "\\u"), h(j, y, He, "˙", "\\."), h(j, y, He, "¸", "\\c"), h(j, y, He, "˚", "\\r"), h(j, y, He, "ˇ", "\\v"), h(j, y, He, "¨", '\\"'), h(j, y, He, "˝", "\\H"), h(j, y, He, "◯", "\\textcircled"); + var Kt = { + "--": !0, + "---": !0, + "``": !0, + "''": !0 + }; + h(j, y, E, "–", "--", !0), h(j, y, E, "–", "\\textendash"), h(j, y, E, "—", "---", !0), h(j, y, E, "—", "\\textemdash"), h(j, y, E, "‘", "`", !0), h(j, y, E, "‘", "\\textquoteleft"), h(j, y, E, "’", "'", !0), h(j, y, E, "’", "\\textquoteright"), h(j, y, E, "“", "``", !0), h(j, y, E, "“", "\\textquotedblleft"), h(j, y, E, "”", "''", !0), h(j, y, E, "”", "\\textquotedblright"), h(d, y, E, "°", "\\degree", !0), h(j, y, E, "°", "\\degree"), h(j, y, E, "°", "\\textdegree", !0), h(d, y, E, "£", "\\pounds"), h(d, y, E, "£", "\\mathsterling", !0), h(j, y, E, "£", "\\pounds"), h(j, y, E, "£", "\\textsterling", !0), h(d, T, E, "✠", "\\maltese"), h(j, T, E, "✠", "\\maltese"); + for (var A0 = '0123456789/@."', st = 0; st < A0.length; st++) { + var Cr = A0.charAt(st); + h(d, y, E, Cr, Cr); + } + for (var Er = '0123456789!@*()-=+";:?/.,', jn = 0; jn < Er.length; jn++) { + var hi = Er.charAt(jn); + h(j, y, E, hi, hi); + } + for (var Kr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", Wn = 0; Wn < Kr.length; Wn++) { + var Qr = Kr.charAt(Wn); + h(d, y, z, Qr, Qr), h(j, y, E, Qr, Qr); + } + h(d, T, E, "C", "ℂ"), h(j, T, E, "C", "ℂ"), h(d, T, E, "H", "ℍ"), h(j, T, E, "H", "ℍ"), h(d, T, E, "N", "ℕ"), h(j, T, E, "N", "ℕ"), h(d, T, E, "P", "ℙ"), h(j, T, E, "P", "ℙ"), h(d, T, E, "Q", "ℚ"), h(j, T, E, "Q", "ℚ"), h(d, T, E, "R", "ℝ"), h(j, T, E, "R", "ℝ"), h(d, T, E, "Z", "ℤ"), h(j, T, E, "Z", "ℤ"), h(d, y, z, "h", "ℎ"), h(j, y, z, "h", "ℎ"); + for (var be = "", yt = 0; yt < Kr.length; yt++) { + var et = Kr.charAt(yt); + be = String.fromCharCode(55349, 56320 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56372 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56424 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56580 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56684 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56736 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56788 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56840 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56944 + yt), h(d, y, z, et, be), h(j, y, E, et, be), yt < 26 && (be = String.fromCharCode(55349, 56632 + yt), h(d, y, z, et, be), h(j, y, E, et, be), be = String.fromCharCode(55349, 56476 + yt), h(d, y, z, et, be), h(j, y, E, et, be)); + } + be = String.fromCharCode(55349, 56668), h(d, y, z, "k", be), h(j, y, E, "k", be); + for (var X0 = 0; X0 < 10; X0++) { + var T0 = X0.toString(); + be = String.fromCharCode(55349, 57294 + X0), h(d, y, z, T0, be), h(j, y, E, T0, be), be = String.fromCharCode(55349, 57314 + X0), h(d, y, z, T0, be), h(j, y, E, T0, be), be = String.fromCharCode(55349, 57324 + X0), h(d, y, z, T0, be), h(j, y, E, T0, be), be = String.fromCharCode(55349, 57334 + X0), h(d, y, z, T0, be), h(j, y, E, T0, be); + } + for (var Yn = "ÐÞþ", Xn = 0; Xn < Yn.length; Xn++) { + var Jr = Yn.charAt(Xn); + h(d, y, z, Jr, Jr), h(j, y, E, Jr, Jr); + } + var $r = [ + ["mathbf", "textbf", "Main-Bold"], + // A-Z bold upright + ["mathbf", "textbf", "Main-Bold"], + // a-z bold upright + ["mathnormal", "textit", "Math-Italic"], + // A-Z italic + ["mathnormal", "textit", "Math-Italic"], + // a-z italic + ["boldsymbol", "boldsymbol", "Main-BoldItalic"], + // A-Z bold italic + ["boldsymbol", "boldsymbol", "Main-BoldItalic"], + // a-z bold italic + // Map fancy A-Z letters to script, not calligraphic. + // This aligns with unicode-math and math fonts (except Cambria Math). + ["mathscr", "textscr", "Script-Regular"], + // A-Z script + ["", "", ""], + // a-z script. No font + ["", "", ""], + // A-Z bold script. No font + ["", "", ""], + // a-z bold script. No font + ["mathfrak", "textfrak", "Fraktur-Regular"], + // A-Z Fraktur + ["mathfrak", "textfrak", "Fraktur-Regular"], + // a-z Fraktur + ["mathbb", "textbb", "AMS-Regular"], + // A-Z double-struck + ["mathbb", "textbb", "AMS-Regular"], + // k double-struck + // Note that we are using a bold font, but font metrics for regular Fraktur. + ["mathboldfrak", "textboldfrak", "Fraktur-Regular"], + // A-Z bold Fraktur + ["mathboldfrak", "textboldfrak", "Fraktur-Regular"], + // a-z bold Fraktur + ["mathsf", "textsf", "SansSerif-Regular"], + // A-Z sans-serif + ["mathsf", "textsf", "SansSerif-Regular"], + // a-z sans-serif + ["mathboldsf", "textboldsf", "SansSerif-Bold"], + // A-Z bold sans-serif + ["mathboldsf", "textboldsf", "SansSerif-Bold"], + // a-z bold sans-serif + ["mathitsf", "textitsf", "SansSerif-Italic"], + // A-Z italic sans-serif + ["mathitsf", "textitsf", "SansSerif-Italic"], + // a-z italic sans-serif + ["", "", ""], + // A-Z bold italic sans. No font + ["", "", ""], + // a-z bold italic sans. No font + ["mathtt", "texttt", "Typewriter-Regular"], + // A-Z monospace + ["mathtt", "texttt", "Typewriter-Regular"] + // a-z monospace + ], fi = [ + ["mathbf", "textbf", "Main-Bold"], + // 0-9 bold + ["", "", ""], + // 0-9 double-struck. No KaTeX font. + ["mathsf", "textsf", "SansSerif-Regular"], + // 0-9 sans-serif + ["mathboldsf", "textboldsf", "SansSerif-Bold"], + // 0-9 bold sans-serif + ["mathtt", "texttt", "Typewriter-Regular"] + // 0-9 monospace + ], Vo = function(e, t) { + var n = e.charCodeAt(0), l = e.charCodeAt(1), c = (n - 55296) * 1024 + (l - 56320) + 65536, m = t === "math" ? 0 : 1; + if (119808 <= c && c < 120484) { + var b = Math.floor((c - 119808) / 26); + return [$r[b][2], $r[b][m]]; + } else if (120782 <= c && c <= 120831) { + var k = Math.floor((c - 120782) / 10); + return [fi[k][2], fi[k][m]]; + } else { + if (c === 120485 || c === 120486) + return [$r[0][2], $r[0][m]]; + if (120486 < c && c < 120782) + return ["", ""]; + throw new u("Unsupported character: " + e); + } + }, en = function(e, t, n) { + return Ve[n][e] && Ve[n][e].replace && (e = Ve[n][e].replace), { + value: e, + metrics: Xt(e, t, n) + }; + }, Gt = function(e, t, n, l, c) { + var m = en(e, t, n), b = m.metrics; + e = m.value; + var k; + if (b) { + var x = b.italic; + (n === "text" || l && l.font === "mathit") && (x = 0), k = new bt(e, b.height, b.depth, x, b.skew, b.width, c); + } else + typeof console < "u" && console.warn("No character metrics " + ("for '" + e + "' in style '" + t + "' and mode '" + n + "'")), k = new bt(e, 0, 0, 0, 0, 0, c); + if (l) { + k.maxFontSize = l.sizeMultiplier, l.style.isTight() && k.classes.push("mtight"); + var C = l.getColor(); + C && (k.style.color = C); + } + return k; + }, jo = function(e, t, n, l) { + return l === void 0 && (l = []), n.font === "boldsymbol" && en(e, "Main-Bold", t).metrics ? Gt(e, "Main-Bold", t, n, l.concat(["mathbf"])) : e === "\\" || Ve[t][e].font === "main" ? Gt(e, "Main-Regular", t, n, l) : Gt(e, "AMS-Regular", t, n, l.concat(["amsrm"])); + }, Wo = function(e, t, n, l, c) { + return c !== "textord" && en(e, "Math-BoldItalic", t).metrics ? { + fontName: "Math-BoldItalic", + fontClass: "boldsymbol" + } : { + fontName: "Main-Bold", + fontClass: "mathbf" + }; + }, Yo = function(e, t, n) { + var l = e.mode, c = e.text, m = ["mord"], b = l === "math" || l === "text" && t.font, k = b ? t.font : t.fontFamily, x = "", C = ""; + if (c.charCodeAt(0) === 55349) { + var D = Vo(c, l); + x = D[0], C = D[1]; + } + if (x.length > 0) + return Gt(c, x, l, t, m.concat(C)); + if (k) { + var P, q; + if (k === "boldsymbol") { + var U = Wo(c, l, t, m, n); + P = U.fontName, q = [U.fontClass]; + } else + b ? (P = pi[k].fontName, q = [k]) : (P = tn(k, t.fontWeight, t.fontShape), q = [k, t.fontWeight, t.fontShape]); + if (en(c, P, l).metrics) + return Gt(c, P, l, t, m.concat(q)); + if (Kt.hasOwnProperty(c) && P.slice(0, 10) === "Typewriter") { + for (var $ = [], ie = 0; ie < c.length; ie++) + $.push(Gt(c[ie], P, l, t, m.concat(q))); + return di($); + } + } + if (n === "mathord") + return Gt(c, "Math-Italic", l, t, m.concat(["mathnormal"])); + if (n === "textord") { + var he = Ve[l][c] && Ve[l][c].font; + if (he === "ams") { + var de = tn("amsrm", t.fontWeight, t.fontShape); + return Gt(c, de, l, t, m.concat("amsrm", t.fontWeight, t.fontShape)); + } else if (he === "main" || !he) { + var ge = tn("textrm", t.fontWeight, t.fontShape); + return Gt(c, ge, l, t, m.concat(t.fontWeight, t.fontShape)); + } else { + var Be = tn(he, t.fontWeight, t.fontShape); + return Gt(c, Be, l, t, m.concat(Be, t.fontWeight, t.fontShape)); + } + } else + throw new Error("unexpected type: " + n + " in makeOrd"); + }, Xo = function(e, t) { + if (ft(e.classes) !== ft(t.classes) || e.skew !== t.skew || e.maxFontSize !== t.maxFontSize) + return !1; + if (e.classes.length === 1) { + var n = e.classes[0]; + if (n === "mbin" || n === "mord") + return !1; + } + for (var l in e.style) + if (e.style.hasOwnProperty(l) && e.style[l] !== t.style[l]) + return !1; + for (var c in t.style) + if (t.style.hasOwnProperty(c) && e.style[c] !== t.style[c]) + return !1; + return !0; + }, Zo = function(e) { + for (var t = 0; t < e.length - 1; t++) { + var n = e[t], l = e[t + 1]; + n instanceof bt && l instanceof bt && Xo(n, l) && (n.text += l.text, n.height = Math.max(n.height, l.height), n.depth = Math.max(n.depth, l.depth), n.italic = l.italic, e.splice(t + 1, 1), t--); + } + return e; + }, Zn = function(e) { + for (var t = 0, n = 0, l = 0, c = 0; c < e.children.length; c++) { + var m = e.children[c]; + m.height > t && (t = m.height), m.depth > n && (n = m.depth), m.maxFontSize > l && (l = m.maxFontSize); + } + e.height = t, e.depth = n, e.maxFontSize = l; + }, xt = function(e, t, n, l) { + var c = new Rt(e, t, n, l); + return Zn(c), c; + }, mi = function(e, t, n, l) { + return new Rt(e, t, n, l); + }, Ko = function(e, t, n) { + var l = xt([e], [], t); + return l.height = Math.max(n || t.fontMetrics().defaultRuleThickness, t.minRuleThickness), l.style.borderBottomWidth = ee(l.height), l.maxFontSize = 1, l; + }, Qo = function(e, t, n, l) { + var c = new Tr(e, t, n, l); + return Zn(c), c; + }, di = function(e) { + var t = new y0(e); + return Zn(t), t; + }, Jo = function(e, t) { + return e instanceof y0 ? xt([], [e], t) : e; + }, $o = function(e) { + if (e.positionType === "individualShift") { + for (var t = e.children, n = [t[0]], l = -t[0].shift - t[0].elem.depth, c = l, m = 1; m < t.length; m++) { + var b = -t[m].shift - c - t[m].elem.depth, k = b - (t[m - 1].elem.height + t[m - 1].elem.depth); + c = c + b, n.push({ + type: "kern", + size: k + }), n.push(t[m]); + } + return { + children: n, + depth: l + }; + } + var x; + if (e.positionType === "top") { + for (var C = e.positionData, D = 0; D < e.children.length; D++) { + var P = e.children[D]; + C -= P.type === "kern" ? P.size : P.elem.height + P.elem.depth; + } + x = C; + } else if (e.positionType === "bottom") + x = -e.positionData; + else { + var q = e.children[0]; + if (q.type !== "elem") + throw new Error('First child must have type "elem".'); + if (e.positionType === "shift") + x = -q.elem.depth - e.positionData; + else if (e.positionType === "firstBaseline") + x = -q.elem.depth; + else + throw new Error("Invalid positionType " + e.positionType + "."); + } + return { + children: e.children, + depth: x + }; + }, e1 = function(e, t) { + for (var n = $o(e), l = n.children, c = n.depth, m = 0, b = 0; b < l.length; b++) { + var k = l[b]; + if (k.type === "elem") { + var x = k.elem; + m = Math.max(m, x.maxFontSize, x.height); + } + } + m += 2; + var C = xt(["pstrut"], []); + C.style.height = ee(m); + for (var D = [], P = c, q = c, U = c, $ = 0; $ < l.length; $++) { + var ie = l[$]; + if (ie.type === "kern") + U += ie.size; + else { + var he = ie.elem, de = ie.wrapperClasses || [], ge = ie.wrapperStyle || {}, Be = xt(de, [C, he], void 0, ge); + Be.style.top = ee(-m - U - he.depth), ie.marginLeft && (Be.style.marginLeft = ie.marginLeft), ie.marginRight && (Be.style.marginRight = ie.marginRight), D.push(Be), U += he.height + he.depth; + } + P = Math.min(P, U), q = Math.max(q, U); + } + var we = xt(["vlist"], D); + we.style.height = ee(q); + var Ie; + if (P < 0) { + var ze = xt([], []), qe = xt(["vlist"], [ze]); + qe.style.height = ee(-P); + var Ye = xt(["vlist-s"], [new bt("​")]); + Ie = [xt(["vlist-r"], [we, Ye]), xt(["vlist-r"], [qe])]; + } else + Ie = [xt(["vlist-r"], [we])]; + var ut = xt(["vlist-t"], Ie); + return Ie.length === 2 && ut.classes.push("vlist-t2"), ut.height = q, ut.depth = -P, ut; + }, t1 = function(e, t) { + var n = xt(["mspace"], [], t), l = Pe(e, t); + return n.style.marginRight = ee(l), n; + }, tn = function(e, t, n) { + var l = ""; + switch (e) { + case "amsrm": + l = "AMS"; + break; + case "textrm": + l = "Main"; + break; + case "textsf": + l = "SansSerif"; + break; + case "texttt": + l = "Typewriter"; + break; + default: + l = e; + } + var c; + return t === "textbf" && n === "textit" ? c = "BoldItalic" : t === "textbf" ? c = "Bold" : t === "textit" ? c = "Italic" : c = "Regular", l + "-" + c; + }, pi = { + // styles + mathbf: { + variant: "bold", + fontName: "Main-Bold" + }, + mathrm: { + variant: "normal", + fontName: "Main-Regular" + }, + textit: { + variant: "italic", + fontName: "Main-Italic" + }, + mathit: { + variant: "italic", + fontName: "Main-Italic" + }, + mathnormal: { + variant: "italic", + fontName: "Math-Italic" + }, + // "boldsymbol" is missing because they require the use of multiple fonts: + // Math-BoldItalic and Main-Bold. This is handled by a special case in + // makeOrd which ends up calling boldsymbol. + // families + mathbb: { + variant: "double-struck", + fontName: "AMS-Regular" + }, + mathcal: { + variant: "script", + fontName: "Caligraphic-Regular" + }, + mathfrak: { + variant: "fraktur", + fontName: "Fraktur-Regular" + }, + mathscr: { + variant: "script", + fontName: "Script-Regular" + }, + mathsf: { + variant: "sans-serif", + fontName: "SansSerif-Regular" + }, + mathtt: { + variant: "monospace", + fontName: "Typewriter-Regular" + } + }, gi = { + // path, width, height + vec: ["vec", 0.471, 0.714], + // values from the font glyph + oiintSize1: ["oiintSize1", 0.957, 0.499], + // oval to overlay the integrand + oiintSize2: ["oiintSize2", 1.472, 0.659], + oiiintSize1: ["oiiintSize1", 1.304, 0.499], + oiiintSize2: ["oiiintSize2", 1.98, 0.659] + }, r1 = function(e, t) { + var n = gi[e], l = n[0], c = n[1], m = n[2], b = new Zt(l), k = new Ft([b], { + width: ee(c), + height: ee(m), + // Override CSS rule `.katex svg { width: 100% }` + style: "width:" + ee(c), + viewBox: "0 0 " + 1e3 * c + " " + 1e3 * m, + preserveAspectRatio: "xMinYMin" + }), x = mi(["overlay"], [k], t); + return x.height = m, x.style.height = ee(m), x.style.width = ee(c), x; + }, N = { + fontMap: pi, + makeSymbol: Gt, + mathsym: jo, + makeSpan: xt, + makeSvgSpan: mi, + makeLineSpan: Ko, + makeAnchor: Qo, + makeFragment: di, + wrapFragment: Jo, + makeVList: e1, + makeOrd: Yo, + makeGlue: t1, + staticSvg: r1, + svgData: gi, + tryCombineChars: Zo + }, Xe = { + number: 3, + unit: "mu" + }, Z0 = { + number: 4, + unit: "mu" + }, h0 = { + number: 5, + unit: "mu" + }, n1 = { + mord: { + mop: Xe, + mbin: Z0, + mrel: h0, + minner: Xe + }, + mop: { + mord: Xe, + mop: Xe, + mrel: h0, + minner: Xe + }, + mbin: { + mord: Z0, + mop: Z0, + mopen: Z0, + minner: Z0 + }, + mrel: { + mord: h0, + mop: h0, + mopen: h0, + minner: h0 + }, + mopen: {}, + mclose: { + mop: Xe, + mbin: Z0, + mrel: h0, + minner: Xe + }, + mpunct: { + mord: Xe, + mop: Xe, + mrel: h0, + mopen: Xe, + mclose: Xe, + mpunct: Xe, + minner: Xe + }, + minner: { + mord: Xe, + mop: Xe, + mbin: Z0, + mrel: h0, + mopen: Xe, + mpunct: Xe, + minner: Xe + } + }, a1 = { + mord: { + mop: Xe + }, + mop: { + mord: Xe, + mop: Xe + }, + mbin: {}, + mrel: {}, + mopen: {}, + mclose: { + mop: Xe + }, + mpunct: {}, + minner: { + mop: Xe + } + }, vi = {}, rn = {}, nn = {}; + function se(f) { + for (var e = f.type, t = f.names, n = f.props, l = f.handler, c = f.htmlBuilder, m = f.mathmlBuilder, b = { + type: e, + numArgs: n.numArgs, + argTypes: n.argTypes, + allowedInArgument: !!n.allowedInArgument, + allowedInText: !!n.allowedInText, + allowedInMath: n.allowedInMath === void 0 ? !0 : n.allowedInMath, + numOptionalArgs: n.numOptionalArgs || 0, + infix: !!n.infix, + primitive: !!n.primitive, + handler: l + }, k = 0; k < t.length; ++k) + vi[t[k]] = b; + e && (c && (rn[e] = c), m && (nn[e] = m)); + } + function K0(f) { + var e = f.type, t = f.htmlBuilder, n = f.mathmlBuilder; + se({ + type: e, + names: [], + props: { + numArgs: 0 + }, + handler: function() { + throw new Error("Should never be called."); + }, + htmlBuilder: t, + mathmlBuilder: n + }); + } + var an = function(e) { + return e.type === "ordgroup" && e.body.length === 1 ? e.body[0] : e; + }, at = function(e) { + return e.type === "ordgroup" ? e.body : [e]; + }, f0 = N.makeSpan, i1 = ["leftmost", "mbin", "mopen", "mrel", "mop", "mpunct"], l1 = ["rightmost", "mrel", "mclose", "mpunct"], s1 = { + display: Q.DISPLAY, + text: Q.TEXT, + script: Q.SCRIPT, + scriptscript: Q.SCRIPTSCRIPT + }, o1 = { + mord: "mord", + mop: "mop", + mbin: "mbin", + mrel: "mrel", + mopen: "mopen", + mclose: "mclose", + mpunct: "mpunct", + minner: "minner" + }, it = function(e, t, n, l) { + l === void 0 && (l = [null, null]); + for (var c = [], m = 0; m < e.length; m++) { + var b = Me(e[m], t); + if (b instanceof y0) { + var k = b.children; + c.push.apply(c, k); + } else + c.push(b); + } + if (N.tryCombineChars(c), !n) + return c; + var x = t; + if (e.length === 1) { + var C = e[0]; + C.type === "sizing" ? x = t.havingSize(C.size) : C.type === "styling" && (x = t.havingStyle(s1[C.style])); + } + var D = f0([l[0] || "leftmost"], [], t), P = f0([l[1] || "rightmost"], [], t), q = n === "root"; + return bi(c, function(U, $) { + var ie = $.classes[0], he = U.classes[0]; + ie === "mbin" && V.contains(l1, he) ? $.classes[0] = "mord" : he === "mbin" && V.contains(i1, ie) && (U.classes[0] = "mord"); + }, { + node: D + }, P, q), bi(c, function(U, $) { + var ie = Kn($), he = Kn(U), de = ie && he ? U.hasClass("mtight") ? a1[ie][he] : n1[ie][he] : null; + if (de) + return N.makeGlue(de, x); + }, { + node: D + }, P, q), c; + }, bi = function f(e, t, n, l, c) { + l && e.push(l); + for (var m = 0; m < e.length; m++) { + var b = e[m], k = yi(b); + if (k) { + f(k.children, t, n, null, c); + continue; + } + var x = !b.hasClass("mspace"); + if (x) { + var C = t(b, n.node); + C && (n.insertAfter ? n.insertAfter(C) : (e.unshift(C), m++)); + } + x ? n.node = b : c && b.hasClass("newline") && (n.node = f0(["leftmost"])), n.insertAfter = function(D) { + return function(P) { + e.splice(D + 1, 0, P), m++; + }; + }(m); + } + l && e.pop(); + }, yi = function(e) { + return e instanceof y0 || e instanceof Tr || e instanceof Rt && e.hasClass("enclosing") ? e : null; + }, u1 = function f(e, t) { + var n = yi(e); + if (n) { + var l = n.children; + if (l.length) { + if (t === "right") + return f(l[l.length - 1], "right"); + if (t === "left") + return f(l[0], "left"); + } + } + return e; + }, Kn = function(e, t) { + return e ? (t && (e = u1(e, t)), o1[e.classes[0]] || null) : null; + }, Br = function(e, t) { + var n = ["nulldelimiter"].concat(e.baseSizingClasses()); + return f0(t.concat(n)); + }, Me = function(e, t, n) { + if (!e) + return f0(); + if (rn[e.type]) { + var l = rn[e.type](e, t); + if (n && t.size !== n.size) { + l = f0(t.sizingClasses(n), [l], t); + var c = t.sizeMultiplier / n.sizeMultiplier; + l.height *= c, l.depth *= c; + } + return l; + } else + throw new u("Got group of unknown type: '" + e.type + "'"); + }; + function ln(f, e) { + var t = f0(["base"], f, e), n = f0(["strut"]); + return n.style.height = ee(t.height + t.depth), t.depth && (n.style.verticalAlign = ee(-t.depth)), t.children.unshift(n), t; + } + function Qn(f, e) { + var t = null; + f.length === 1 && f[0].type === "tag" && (t = f[0].tag, f = f[0].body); + var n = it(f, e, "root"), l; + n.length === 2 && n[1].hasClass("tag") && (l = n.pop()); + for (var c = [], m = [], b = 0; b < n.length; b++) + if (m.push(n[b]), n[b].hasClass("mbin") || n[b].hasClass("mrel") || n[b].hasClass("allowbreak")) { + for (var k = !1; b < n.length - 1 && n[b + 1].hasClass("mspace") && !n[b + 1].hasClass("newline"); ) + b++, m.push(n[b]), n[b].hasClass("nobreak") && (k = !0); + k || (c.push(ln(m, e)), m = []); + } else + n[b].hasClass("newline") && (m.pop(), m.length > 0 && (c.push(ln(m, e)), m = []), c.push(n[b])); + m.length > 0 && c.push(ln(m, e)); + var x; + t ? (x = ln(it(t, e, !0)), x.classes = ["tag"], c.push(x)) : l && c.push(l); + var C = f0(["katex-html"], c); + if (C.setAttribute("aria-hidden", "true"), x) { + var D = x.children[0]; + D.style.height = ee(C.height + C.depth), C.depth && (D.style.verticalAlign = ee(-C.depth)); + } + return C; + } + function wi(f) { + return new y0(f); + } + var Lt = /* @__PURE__ */ function() { + function f(t, n, l) { + this.type = void 0, this.attributes = void 0, this.children = void 0, this.classes = void 0, this.type = t, this.attributes = {}, this.children = n || [], this.classes = l || []; + } + var e = f.prototype; + return e.setAttribute = function(n, l) { + this.attributes[n] = l; + }, e.getAttribute = function(n) { + return this.attributes[n]; + }, e.toNode = function() { + var n = document.createElementNS("http://www.w3.org/1998/Math/MathML", this.type); + for (var l in this.attributes) + Object.prototype.hasOwnProperty.call(this.attributes, l) && n.setAttribute(l, this.attributes[l]); + this.classes.length > 0 && (n.className = ft(this.classes)); + for (var c = 0; c < this.children.length; c++) + n.appendChild(this.children[c].toNode()); + return n; + }, e.toMarkup = function() { + var n = "<" + this.type; + for (var l in this.attributes) + Object.prototype.hasOwnProperty.call(this.attributes, l) && (n += " " + l + '="', n += V.escape(this.attributes[l]), n += '"'); + this.classes.length > 0 && (n += ' class ="' + V.escape(ft(this.classes)) + '"'), n += ">"; + for (var c = 0; c < this.children.length; c++) + n += this.children[c].toMarkup(); + return n += "", n; + }, e.toText = function() { + return this.children.map(function(n) { + return n.toText(); + }).join(""); + }, f; + }(), Dr = /* @__PURE__ */ function() { + function f(t) { + this.text = void 0, this.text = t; + } + var e = f.prototype; + return e.toNode = function() { + return document.createTextNode(this.text); + }, e.toMarkup = function() { + return V.escape(this.toText()); + }, e.toText = function() { + return this.text; + }, f; + }(), c1 = /* @__PURE__ */ function() { + function f(t) { + this.width = void 0, this.character = void 0, this.width = t, t >= 0.05555 && t <= 0.05556 ? this.character = " " : t >= 0.1666 && t <= 0.1667 ? this.character = " " : t >= 0.2222 && t <= 0.2223 ? this.character = " " : t >= 0.2777 && t <= 0.2778 ? this.character = "  " : t >= -0.05556 && t <= -0.05555 ? this.character = " ⁣" : t >= -0.1667 && t <= -0.1666 ? this.character = " ⁣" : t >= -0.2223 && t <= -0.2222 ? this.character = " ⁣" : t >= -0.2778 && t <= -0.2777 ? this.character = " ⁣" : this.character = null; + } + var e = f.prototype; + return e.toNode = function() { + if (this.character) + return document.createTextNode(this.character); + var n = document.createElementNS("http://www.w3.org/1998/Math/MathML", "mspace"); + return n.setAttribute("width", ee(this.width)), n; + }, e.toMarkup = function() { + return this.character ? "" + this.character + "" : ''; + }, e.toText = function() { + return this.character ? this.character : " "; + }, f; + }(), K = { + MathNode: Lt, + TextNode: Dr, + SpaceNode: c1, + newDocumentFragment: wi + }, It = function(e, t, n) { + return Ve[t][e] && Ve[t][e].replace && e.charCodeAt(0) !== 55349 && !(Kt.hasOwnProperty(e) && n && (n.fontFamily && n.fontFamily.slice(4, 6) === "tt" || n.font && n.font.slice(4, 6) === "tt")) && (e = Ve[t][e].replace), new K.TextNode(e); + }, Jn = function(e) { + return e.length === 1 ? e[0] : new K.MathNode("mrow", e); + }, $n = function(e, t) { + if (t.fontFamily === "texttt") + return "monospace"; + if (t.fontFamily === "textsf") + return t.fontShape === "textit" && t.fontWeight === "textbf" ? "sans-serif-bold-italic" : t.fontShape === "textit" ? "sans-serif-italic" : t.fontWeight === "textbf" ? "bold-sans-serif" : "sans-serif"; + if (t.fontShape === "textit" && t.fontWeight === "textbf") + return "bold-italic"; + if (t.fontShape === "textit") + return "italic"; + if (t.fontWeight === "textbf") + return "bold"; + var n = t.font; + if (!n || n === "mathnormal") + return null; + var l = e.mode; + if (n === "mathit") + return "italic"; + if (n === "boldsymbol") + return e.type === "textord" ? "bold" : "bold-italic"; + if (n === "mathbf") + return "bold"; + if (n === "mathbb") + return "double-struck"; + if (n === "mathfrak") + return "fraktur"; + if (n === "mathscr" || n === "mathcal") + return "script"; + if (n === "mathsf") + return "sans-serif"; + if (n === "mathtt") + return "monospace"; + var c = e.text; + if (V.contains(["\\imath", "\\jmath"], c)) + return null; + Ve[l][c] && Ve[l][c].replace && (c = Ve[l][c].replace); + var m = N.fontMap[n].fontName; + return Xt(c, m, l) ? N.fontMap[n].variant : null; + }, St = function(e, t, n) { + if (e.length === 1) { + var l = Ue(e[0], t); + return n && l instanceof Lt && l.type === "mo" && (l.setAttribute("lspace", "0em"), l.setAttribute("rspace", "0em")), [l]; + } + for (var c = [], m, b = 0; b < e.length; b++) { + var k = Ue(e[b], t); + if (k instanceof Lt && m instanceof Lt) { + if (k.type === "mtext" && m.type === "mtext" && k.getAttribute("mathvariant") === m.getAttribute("mathvariant")) { + var x; + (x = m.children).push.apply(x, k.children); + continue; + } else if (k.type === "mn" && m.type === "mn") { + var C; + (C = m.children).push.apply(C, k.children); + continue; + } else if (k.type === "mi" && k.children.length === 1 && m.type === "mn") { + var D = k.children[0]; + if (D instanceof Dr && D.text === ".") { + var P; + (P = m.children).push.apply(P, k.children); + continue; + } + } else if (m.type === "mi" && m.children.length === 1) { + var q = m.children[0]; + if (q instanceof Dr && q.text === "̸" && (k.type === "mo" || k.type === "mi" || k.type === "mn")) { + var U = k.children[0]; + U instanceof Dr && U.text.length > 0 && (U.text = U.text.slice(0, 1) + "̸" + U.text.slice(1), c.pop()); + } + } + } + c.push(k), m = k; + } + return c; + }, M0 = function(e, t, n) { + return Jn(St(e, t, n)); + }, Ue = function(e, t) { + if (!e) + return new K.MathNode("mrow"); + if (nn[e.type]) { + var n = nn[e.type](e, t); + return n; + } else + throw new u("Got group of unknown type: '" + e.type + "'"); + }; + function ki(f, e, t, n, l) { + var c = St(f, t), m; + c.length === 1 && c[0] instanceof Lt && V.contains(["mrow", "mtable"], c[0].type) ? m = c[0] : m = new K.MathNode("mrow", c); + var b = new K.MathNode("annotation", [new K.TextNode(e)]); + b.setAttribute("encoding", "application/x-tex"); + var k = new K.MathNode("semantics", [m, b]), x = new K.MathNode("math", [k]); + x.setAttribute("xmlns", "http://www.w3.org/1998/Math/MathML"), n && x.setAttribute("display", "block"); + var C = l ? "katex" : "katex-mathml"; + return N.makeSpan([C], [x]); + } + var _i = function(e) { + return new ir({ + style: e.displayMode ? Q.DISPLAY : Q.TEXT, + maxSize: e.maxSize, + minRuleThickness: e.minRuleThickness + }); + }, xi = function(e, t) { + if (t.displayMode) { + var n = ["katex-display"]; + t.leqno && n.push("leqno"), t.fleqn && n.push("fleqn"), e = N.makeSpan(n, [e]); + } + return e; + }, h1 = function(e, t, n) { + var l = _i(n), c; + if (n.output === "mathml") + return ki(e, t, l, n.displayMode, !0); + if (n.output === "html") { + var m = Qn(e, l); + c = N.makeSpan(["katex"], [m]); + } else { + var b = ki(e, t, l, n.displayMode, !1), k = Qn(e, l); + c = N.makeSpan(["katex"], [b, k]); + } + return xi(c, n); + }, f1 = function(e, t, n) { + var l = _i(n), c = Qn(e, l), m = N.makeSpan(["katex"], [c]); + return xi(m, n); + }, m1 = { + widehat: "^", + widecheck: "ˇ", + widetilde: "~", + utilde: "~", + overleftarrow: "←", + underleftarrow: "←", + xleftarrow: "←", + overrightarrow: "→", + underrightarrow: "→", + xrightarrow: "→", + underbrace: "⏟", + overbrace: "⏞", + overgroup: "⏠", + undergroup: "⏡", + overleftrightarrow: "↔", + underleftrightarrow: "↔", + xleftrightarrow: "↔", + Overrightarrow: "⇒", + xRightarrow: "⇒", + overleftharpoon: "↼", + xleftharpoonup: "↼", + overrightharpoon: "⇀", + xrightharpoonup: "⇀", + xLeftarrow: "⇐", + xLeftrightarrow: "⇔", + xhookleftarrow: "↩", + xhookrightarrow: "↪", + xmapsto: "↦", + xrightharpoondown: "⇁", + xleftharpoondown: "↽", + xrightleftharpoons: "⇌", + xleftrightharpoons: "⇋", + xtwoheadleftarrow: "↞", + xtwoheadrightarrow: "↠", + xlongequal: "=", + xtofrom: "⇄", + xrightleftarrows: "⇄", + xrightequilibrium: "⇌", + // Not a perfect match. + xleftequilibrium: "⇋", + // None better available. + "\\cdrightarrow": "→", + "\\cdleftarrow": "←", + "\\cdlongequal": "=" + }, d1 = function(e) { + var t = new K.MathNode("mo", [new K.TextNode(m1[e.replace(/^\\/, "")])]); + return t.setAttribute("stretchy", "true"), t; + }, p1 = { + // path(s), minWidth, height, align + overrightarrow: [["rightarrow"], 0.888, 522, "xMaxYMin"], + overleftarrow: [["leftarrow"], 0.888, 522, "xMinYMin"], + underrightarrow: [["rightarrow"], 0.888, 522, "xMaxYMin"], + underleftarrow: [["leftarrow"], 0.888, 522, "xMinYMin"], + xrightarrow: [["rightarrow"], 1.469, 522, "xMaxYMin"], + "\\cdrightarrow": [["rightarrow"], 3, 522, "xMaxYMin"], + // CD minwwidth2.5pc + xleftarrow: [["leftarrow"], 1.469, 522, "xMinYMin"], + "\\cdleftarrow": [["leftarrow"], 3, 522, "xMinYMin"], + Overrightarrow: [["doublerightarrow"], 0.888, 560, "xMaxYMin"], + xRightarrow: [["doublerightarrow"], 1.526, 560, "xMaxYMin"], + xLeftarrow: [["doubleleftarrow"], 1.526, 560, "xMinYMin"], + overleftharpoon: [["leftharpoon"], 0.888, 522, "xMinYMin"], + xleftharpoonup: [["leftharpoon"], 0.888, 522, "xMinYMin"], + xleftharpoondown: [["leftharpoondown"], 0.888, 522, "xMinYMin"], + overrightharpoon: [["rightharpoon"], 0.888, 522, "xMaxYMin"], + xrightharpoonup: [["rightharpoon"], 0.888, 522, "xMaxYMin"], + xrightharpoondown: [["rightharpoondown"], 0.888, 522, "xMaxYMin"], + xlongequal: [["longequal"], 0.888, 334, "xMinYMin"], + "\\cdlongequal": [["longequal"], 3, 334, "xMinYMin"], + xtwoheadleftarrow: [["twoheadleftarrow"], 0.888, 334, "xMinYMin"], + xtwoheadrightarrow: [["twoheadrightarrow"], 0.888, 334, "xMaxYMin"], + overleftrightarrow: [["leftarrow", "rightarrow"], 0.888, 522], + overbrace: [["leftbrace", "midbrace", "rightbrace"], 1.6, 548], + underbrace: [["leftbraceunder", "midbraceunder", "rightbraceunder"], 1.6, 548], + underleftrightarrow: [["leftarrow", "rightarrow"], 0.888, 522], + xleftrightarrow: [["leftarrow", "rightarrow"], 1.75, 522], + xLeftrightarrow: [["doubleleftarrow", "doublerightarrow"], 1.75, 560], + xrightleftharpoons: [["leftharpoondownplus", "rightharpoonplus"], 1.75, 716], + xleftrightharpoons: [["leftharpoonplus", "rightharpoondownplus"], 1.75, 716], + xhookleftarrow: [["leftarrow", "righthook"], 1.08, 522], + xhookrightarrow: [["lefthook", "rightarrow"], 1.08, 522], + overlinesegment: [["leftlinesegment", "rightlinesegment"], 0.888, 522], + underlinesegment: [["leftlinesegment", "rightlinesegment"], 0.888, 522], + overgroup: [["leftgroup", "rightgroup"], 0.888, 342], + undergroup: [["leftgroupunder", "rightgroupunder"], 0.888, 342], + xmapsto: [["leftmapsto", "rightarrow"], 1.5, 522], + xtofrom: [["leftToFrom", "rightToFrom"], 1.75, 528], + // The next three arrows are from the mhchem package. + // In mhchem.sty, min-length is 2.0em. But these arrows might appear in the + // document as \xrightarrow or \xrightleftharpoons. Those have + // min-length = 1.75em, so we set min-length on these next three to match. + xrightleftarrows: [["baraboveleftarrow", "rightarrowabovebar"], 1.75, 901], + xrightequilibrium: [["baraboveshortleftharpoon", "rightharpoonaboveshortbar"], 1.75, 716], + xleftequilibrium: [["shortbaraboveleftharpoon", "shortrightharpoonabovebar"], 1.75, 716] + }, g1 = function(e) { + return e.type === "ordgroup" ? e.body.length : 1; + }, v1 = function(e, t) { + function n() { + var k = 4e5, x = e.label.slice(1); + if (V.contains(["widehat", "widecheck", "widetilde", "utilde"], x)) { + var C = e, D = g1(C.base), P, q, U; + if (D > 5) + x === "widehat" || x === "widecheck" ? (P = 420, k = 2364, U = 0.42, q = x + "4") : (P = 312, k = 2340, U = 0.34, q = "tilde4"); + else { + var $ = [1, 1, 2, 2, 3, 3][D]; + x === "widehat" || x === "widecheck" ? (k = [0, 1062, 2364, 2364, 2364][$], P = [0, 239, 300, 360, 420][$], U = [0, 0.24, 0.3, 0.3, 0.36, 0.42][$], q = x + $) : (k = [0, 600, 1033, 2339, 2340][$], P = [0, 260, 286, 306, 312][$], U = [0, 0.26, 0.286, 0.3, 0.306, 0.34][$], q = "tilde" + $); + } + var ie = new Zt(q), he = new Ft([ie], { + width: "100%", + height: ee(U), + viewBox: "0 0 " + k + " " + P, + preserveAspectRatio: "none" + }); + return { + span: N.makeSvgSpan([], [he], t), + minWidth: 0, + height: U + }; + } else { + var de = [], ge = p1[x], Be = ge[0], we = ge[1], Ie = ge[2], ze = Ie / 1e3, qe = Be.length, Ye, ut; + if (qe === 1) { + var Mt = ge[3]; + Ye = ["hide-tail"], ut = [Mt]; + } else if (qe === 2) + Ye = ["halfarrow-left", "halfarrow-right"], ut = ["xMinYMin", "xMaxYMin"]; + else if (qe === 3) + Ye = ["brace-left", "brace-center", "brace-right"], ut = ["xMinYMin", "xMidYMin", "xMaxYMin"]; + else + throw new Error(`Correct katexImagesData or update code here to support + ` + qe + " children."); + for (var Ze = 0; Ze < qe; Ze++) { + var Q0 = new Zt(Be[Ze]), Ot = new Ft([Q0], { + width: "400em", + height: ee(ze), + viewBox: "0 0 " + k + " " + Ie, + preserveAspectRatio: ut[Ze] + " slice" + }), wt = N.makeSvgSpan([Ye[Ze]], [Ot], t); + if (qe === 1) + return { + span: wt, + minWidth: we, + height: ze + }; + wt.style.height = ee(ze), de.push(wt); + } + return { + span: N.makeSpan(["stretchy"], de, t), + minWidth: we, + height: ze + }; + } + } + var l = n(), c = l.span, m = l.minWidth, b = l.height; + return c.height = b, c.style.height = ee(b), m > 0 && (c.style.minWidth = ee(m)), c; + }, b1 = function(e, t, n, l, c) { + var m, b = e.height + e.depth + n + l; + if (/fbox|color|angl/.test(t)) { + if (m = N.makeSpan(["stretchy", t], [], c), t === "fbox") { + var k = c.color && c.getColor(); + k && (m.style.borderColor = k); + } + } else { + var x = []; + /^[bx]cancel$/.test(t) && x.push(new S0({ + x1: "0", + y1: "0", + x2: "100%", + y2: "100%", + "stroke-width": "0.046em" + })), /^x?cancel$/.test(t) && x.push(new S0({ + x1: "0", + y1: "100%", + x2: "100%", + y2: "0", + "stroke-width": "0.046em" + })); + var C = new Ft(x, { + width: "100%", + height: ee(b) + }); + m = N.makeSvgSpan([], [C], c); + } + return m.height = b, m.style.height = ee(b), m; + }, m0 = { + encloseSpan: b1, + mathMLnode: d1, + svgSpan: v1 + }; + function ye(f, e) { + if (!f || f.type !== e) + throw new Error("Expected node of type " + e + ", but got " + (f ? "node of type " + f.type : String(f))); + return f; + } + function ea(f) { + var e = sn(f); + if (!e) + throw new Error("Expected node of symbol group type, but got " + (f ? "node of type " + f.type : String(f))); + return e; + } + function sn(f) { + return f && (f.type === "atom" || zr.hasOwnProperty(f.type)) ? f : null; + } + var ta = function(e, t) { + var n, l, c; + e && e.type === "supsub" ? (l = ye(e.base, "accent"), n = l.base, e.base = n, c = Vn(Me(e, t)), e.base = l) : (l = ye(e, "accent"), n = l.base); + var m = Me(n, t.havingCrampedStyle()), b = l.isShifty && V.isCharacterBox(n), k = 0; + if (b) { + var x = V.getBaseElem(n), C = Me(x, t.havingCrampedStyle()); + k = sr(C).skew; + } + var D = l.label === "\\c", P = D ? m.height + m.depth : Math.min(m.height, t.fontMetrics().xHeight), q; + if (l.isStretchy) + q = m0.svgSpan(l, t), q = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: m + }, { + type: "elem", + elem: q, + wrapperClasses: ["svg-align"], + wrapperStyle: k > 0 ? { + width: "calc(100% - " + ee(2 * k) + ")", + marginLeft: ee(2 * k) + } : void 0 + }] + }, t); + else { + var U, $; + l.label === "\\vec" ? (U = N.staticSvg("vec", t), $ = N.svgData.vec[1]) : (U = N.makeOrd({ + mode: l.mode, + text: l.label + }, t, "textord"), U = sr(U), U.italic = 0, $ = U.width, D && (P += U.depth)), q = N.makeSpan(["accent-body"], [U]); + var ie = l.label === "\\textcircled"; + ie && (q.classes.push("accent-full"), P = m.height); + var he = k; + ie || (he -= $ / 2), q.style.left = ee(he), l.label === "\\textcircled" && (q.style.top = ".2em"), q = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: m + }, { + type: "kern", + size: -P + }, { + type: "elem", + elem: q + }] + }, t); + } + var de = N.makeSpan(["mord", "accent"], [q], t); + return c ? (c.children[0] = de, c.height = Math.max(de.height, c.height), c.classes[0] = "mord", c) : de; + }, Si = function(e, t) { + var n = e.isStretchy ? m0.mathMLnode(e.label) : new K.MathNode("mo", [It(e.label, e.mode)]), l = new K.MathNode("mover", [Ue(e.base, t), n]); + return l.setAttribute("accent", "true"), l; + }, y1 = new RegExp(["\\acute", "\\grave", "\\ddot", "\\tilde", "\\bar", "\\breve", "\\check", "\\hat", "\\vec", "\\dot", "\\mathring"].map(function(f) { + return "\\" + f; + }).join("|")); + se({ + type: "accent", + names: ["\\acute", "\\grave", "\\ddot", "\\tilde", "\\bar", "\\breve", "\\check", "\\hat", "\\vec", "\\dot", "\\mathring", "\\widecheck", "\\widehat", "\\widetilde", "\\overrightarrow", "\\overleftarrow", "\\Overrightarrow", "\\overleftrightarrow", "\\overgroup", "\\overlinesegment", "\\overleftharpoon", "\\overrightharpoon"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = an(t[0]), l = !y1.test(e.funcName), c = !l || e.funcName === "\\widehat" || e.funcName === "\\widetilde" || e.funcName === "\\widecheck"; + return { + type: "accent", + mode: e.parser.mode, + label: e.funcName, + isStretchy: l, + isShifty: c, + base: n + }; + }, + htmlBuilder: ta, + mathmlBuilder: Si + }), se({ + type: "accent", + names: ["\\'", "\\`", "\\^", "\\~", "\\=", "\\u", "\\.", '\\"', "\\c", "\\r", "\\H", "\\v", "\\textcircled"], + props: { + numArgs: 1, + allowedInText: !0, + allowedInMath: !0, + // unless in strict mode + argTypes: ["primitive"] + }, + handler: function(e, t) { + var n = t[0], l = e.parser.mode; + return l === "math" && (e.parser.settings.reportNonstrict("mathVsTextAccents", "LaTeX's accent " + e.funcName + " works only in text mode"), l = "text"), { + type: "accent", + mode: l, + label: e.funcName, + isStretchy: !1, + isShifty: !0, + base: n + }; + }, + htmlBuilder: ta, + mathmlBuilder: Si + }), se({ + type: "accentUnder", + names: ["\\underleftarrow", "\\underrightarrow", "\\underleftrightarrow", "\\undergroup", "\\underlinesegment", "\\utilde"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "accentUnder", + mode: n.mode, + label: l, + base: c + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.base, t), l = m0.svgSpan(e, t), c = e.label === "\\utilde" ? 0.12 : 0, m = N.makeVList({ + positionType: "top", + positionData: n.height, + children: [{ + type: "elem", + elem: l, + wrapperClasses: ["svg-align"] + }, { + type: "kern", + size: c + }, { + type: "elem", + elem: n + }] + }, t); + return N.makeSpan(["mord", "accentunder"], [m], t); + }, + mathmlBuilder: function(e, t) { + var n = m0.mathMLnode(e.label), l = new K.MathNode("munder", [Ue(e.base, t), n]); + return l.setAttribute("accentunder", "true"), l; + } + }); + var on = function(e) { + var t = new K.MathNode("mpadded", e ? [e] : []); + return t.setAttribute("width", "+0.6em"), t.setAttribute("lspace", "0.3em"), t; + }; + se({ + type: "xArrow", + names: [ + "\\xleftarrow", + "\\xrightarrow", + "\\xLeftarrow", + "\\xRightarrow", + "\\xleftrightarrow", + "\\xLeftrightarrow", + "\\xhookleftarrow", + "\\xhookrightarrow", + "\\xmapsto", + "\\xrightharpoondown", + "\\xrightharpoonup", + "\\xleftharpoondown", + "\\xleftharpoonup", + "\\xrightleftharpoons", + "\\xleftrightharpoons", + "\\xlongequal", + "\\xtwoheadrightarrow", + "\\xtwoheadleftarrow", + "\\xtofrom", + // The next 3 functions are here to support the mhchem extension. + // Direct use of these functions is discouraged and may break someday. + "\\xrightleftarrows", + "\\xrightequilibrium", + "\\xleftequilibrium", + // The next 3 functions are here only to support the {CD} environment. + "\\\\cdrightarrow", + "\\\\cdleftarrow", + "\\\\cdlongequal" + ], + props: { + numArgs: 1, + numOptionalArgs: 1 + }, + handler: function(e, t, n) { + var l = e.parser, c = e.funcName; + return { + type: "xArrow", + mode: l.mode, + label: c, + body: t[0], + below: n[0] + }; + }, + // Flow is unable to correctly infer the type of `group`, even though it's + // unambiguously determined from the passed-in `type` above. + htmlBuilder: function(e, t) { + var n = t.style, l = t.havingStyle(n.sup()), c = N.wrapFragment(Me(e.body, l, t), t), m = e.label.slice(0, 2) === "\\x" ? "x" : "cd"; + c.classes.push(m + "-arrow-pad"); + var b; + e.below && (l = t.havingStyle(n.sub()), b = N.wrapFragment(Me(e.below, l, t), t), b.classes.push(m + "-arrow-pad")); + var k = m0.svgSpan(e, t), x = -t.fontMetrics().axisHeight + 0.5 * k.height, C = -t.fontMetrics().axisHeight - 0.5 * k.height - 0.111; + (c.depth > 0.25 || e.label === "\\xleftequilibrium") && (C -= c.depth); + var D; + if (b) { + var P = -t.fontMetrics().axisHeight + b.height + 0.5 * k.height + 0.111; + D = N.makeVList({ + positionType: "individualShift", + children: [{ + type: "elem", + elem: c, + shift: C + }, { + type: "elem", + elem: k, + shift: x + }, { + type: "elem", + elem: b, + shift: P + }] + }, t); + } else + D = N.makeVList({ + positionType: "individualShift", + children: [{ + type: "elem", + elem: c, + shift: C + }, { + type: "elem", + elem: k, + shift: x + }] + }, t); + return D.children[0].children[0].children[1].classes.push("svg-align"), N.makeSpan(["mrel", "x-arrow"], [D], t); + }, + mathmlBuilder: function(e, t) { + var n = m0.mathMLnode(e.label); + n.setAttribute("minsize", e.label.charAt(0) === "x" ? "1.75em" : "3.0em"); + var l; + if (e.body) { + var c = on(Ue(e.body, t)); + if (e.below) { + var m = on(Ue(e.below, t)); + l = new K.MathNode("munderover", [n, m, c]); + } else + l = new K.MathNode("mover", [n, c]); + } else if (e.below) { + var b = on(Ue(e.below, t)); + l = new K.MathNode("munder", [n, b]); + } else + l = on(), l = new K.MathNode("mover", [n, l]); + return l; + } + }); + var w1 = N.makeSpan; + function Ai(f, e) { + var t = it(f.body, e, !0); + return w1([f.mclass], t, e); + } + function Ti(f, e) { + var t, n = St(f.body, e); + return f.mclass === "minner" ? t = new K.MathNode("mpadded", n) : f.mclass === "mord" ? f.isCharacterBox ? (t = n[0], t.type = "mi") : t = new K.MathNode("mi", n) : (f.isCharacterBox ? (t = n[0], t.type = "mo") : t = new K.MathNode("mo", n), f.mclass === "mbin" ? (t.attributes.lspace = "0.22em", t.attributes.rspace = "0.22em") : f.mclass === "mpunct" ? (t.attributes.lspace = "0em", t.attributes.rspace = "0.17em") : f.mclass === "mopen" || f.mclass === "mclose" ? (t.attributes.lspace = "0em", t.attributes.rspace = "0em") : f.mclass === "minner" && (t.attributes.lspace = "0.0556em", t.attributes.width = "+0.1111em")), t; + } + se({ + type: "mclass", + names: ["\\mathord", "\\mathbin", "\\mathrel", "\\mathopen", "\\mathclose", "\\mathpunct", "\\mathinner"], + props: { + numArgs: 1, + primitive: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "mclass", + mode: n.mode, + mclass: "m" + l.slice(5), + // TODO(kevinb): don't prefix with 'm' + body: at(c), + isCharacterBox: V.isCharacterBox(c) + }; + }, + htmlBuilder: Ai, + mathmlBuilder: Ti + }); + var un = function(e) { + var t = e.type === "ordgroup" && e.body.length ? e.body[0] : e; + return t.type === "atom" && (t.family === "bin" || t.family === "rel") ? "m" + t.family : "mord"; + }; + se({ + type: "mclass", + names: ["\\@binrel"], + props: { + numArgs: 2 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "mclass", + mode: n.mode, + mclass: un(t[0]), + body: at(t[1]), + isCharacterBox: V.isCharacterBox(t[1]) + }; + } + }), se({ + type: "mclass", + names: ["\\stackrel", "\\overset", "\\underset"], + props: { + numArgs: 2 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[1], m = t[0], b; + l !== "\\stackrel" ? b = un(c) : b = "mrel"; + var k = { + type: "op", + mode: c.mode, + limits: !0, + alwaysHandleSupSub: !0, + parentIsSupSub: !1, + symbol: !1, + suppressBaseShift: l !== "\\stackrel", + body: at(c) + }, x = { + type: "supsub", + mode: m.mode, + base: k, + sup: l === "\\underset" ? null : m, + sub: l === "\\underset" ? m : null + }; + return { + type: "mclass", + mode: n.mode, + mclass: b, + body: [x], + isCharacterBox: V.isCharacterBox(x) + }; + }, + htmlBuilder: Ai, + mathmlBuilder: Ti + }), se({ + type: "pmb", + names: ["\\pmb"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "pmb", + mode: n.mode, + mclass: un(t[0]), + body: at(t[0]) + }; + }, + htmlBuilder: function(e, t) { + var n = it(e.body, t, !0), l = N.makeSpan([e.mclass], n, t); + return l.style.textShadow = "0.02em 0.01em 0.04px", l; + }, + mathmlBuilder: function(e, t) { + var n = St(e.body, t), l = new K.MathNode("mstyle", n); + return l.setAttribute("style", "text-shadow: 0.02em 0.01em 0.04px"), l; + } + }); + var k1 = { + ">": "\\\\cdrightarrow", + "<": "\\\\cdleftarrow", + "=": "\\\\cdlongequal", + A: "\\uparrow", + V: "\\downarrow", + "|": "\\Vert", + ".": "no arrow" + }, Mi = function() { + return { + type: "styling", + body: [], + mode: "math", + style: "display" + }; + }, zi = function(e) { + return e.type === "textord" && e.text === "@"; + }, _1 = function(e, t) { + return (e.type === "mathord" || e.type === "atom") && e.text === t; + }; + function x1(f, e, t) { + var n = k1[f]; + switch (n) { + case "\\\\cdrightarrow": + case "\\\\cdleftarrow": + return t.callFunction(n, [e[0]], [e[1]]); + case "\\uparrow": + case "\\downarrow": { + var l = t.callFunction("\\\\cdleft", [e[0]], []), c = { + type: "atom", + text: n, + mode: "math", + family: "rel" + }, m = t.callFunction("\\Big", [c], []), b = t.callFunction("\\\\cdright", [e[1]], []), k = { + type: "ordgroup", + mode: "math", + body: [l, m, b] + }; + return t.callFunction("\\\\cdparent", [k], []); + } + case "\\\\cdlongequal": + return t.callFunction("\\\\cdlongequal", [], []); + case "\\Vert": { + var x = { + type: "textord", + text: "\\Vert", + mode: "math" + }; + return t.callFunction("\\Big", [x], []); + } + default: + return { + type: "textord", + text: " ", + mode: "math" + }; + } + } + function S1(f) { + var e = []; + for (f.gullet.beginGroup(), f.gullet.macros.set("\\cr", "\\\\\\relax"), f.gullet.beginGroup(); ; ) { + e.push(f.parseExpression(!1, "\\\\")), f.gullet.endGroup(), f.gullet.beginGroup(); + var t = f.fetch().text; + if (t === "&" || t === "\\\\") + f.consume(); + else if (t === "\\end") { + e[e.length - 1].length === 0 && e.pop(); + break; + } else + throw new u("Expected \\\\ or \\cr or \\end", f.nextToken); + } + for (var n = [], l = [n], c = 0; c < e.length; c++) { + for (var m = e[c], b = Mi(), k = 0; k < m.length; k++) + if (!zi(m[k])) + b.body.push(m[k]); + else { + n.push(b), k += 1; + var x = ea(m[k]).text, C = new Array(2); + if (C[0] = { + type: "ordgroup", + mode: "math", + body: [] + }, C[1] = { + type: "ordgroup", + mode: "math", + body: [] + }, !("=|.".indexOf(x) > -1)) + if ("<>AV".indexOf(x) > -1) + for (var D = 0; D < 2; D++) { + for (var P = !0, q = k + 1; q < m.length; q++) { + if (_1(m[q], x)) { + P = !1, k = q; + break; + } + if (zi(m[q])) + throw new u("Missing a " + x + " character to complete a CD arrow.", m[q]); + C[D].body.push(m[q]); + } + if (P) + throw new u("Missing a " + x + " character to complete a CD arrow.", m[k]); + } + else + throw new u('Expected one of "<>AV=|." after @', m[k]); + var U = x1(x, C, f), $ = { + type: "styling", + body: [U], + mode: "math", + style: "display" + // CD is always displaystyle. + }; + n.push($), b = Mi(); + } + c % 2 === 0 ? n.push(b) : n.shift(), n = [], l.push(n); + } + f.gullet.endGroup(), f.gullet.endGroup(); + var ie = new Array(l[0].length).fill({ + type: "align", + align: "c", + pregap: 0.25, + // CD package sets \enskip between columns. + postgap: 0.25 + // So pre and post each get half an \enskip, i.e. 0.25em. + }); + return { + type: "array", + mode: "math", + body: l, + arraystretch: 1, + addJot: !0, + rowGaps: [null], + cols: ie, + colSeparationType: "CD", + hLinesBeforeRow: new Array(l.length + 1).fill([]) + }; + } + se({ + type: "cdlabel", + names: ["\\\\cdleft", "\\\\cdright"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName; + return { + type: "cdlabel", + mode: n.mode, + side: l.slice(4), + label: t[0] + }; + }, + htmlBuilder: function(e, t) { + var n = t.havingStyle(t.style.sup()), l = N.wrapFragment(Me(e.label, n, t), t); + return l.classes.push("cd-label-" + e.side), l.style.bottom = ee(0.8 - l.depth), l.height = 0, l.depth = 0, l; + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mrow", [Ue(e.label, t)]); + return n = new K.MathNode("mpadded", [n]), n.setAttribute("width", "0"), e.side === "left" && n.setAttribute("lspace", "-1width"), n.setAttribute("voffset", "0.7em"), n = new K.MathNode("mstyle", [n]), n.setAttribute("displaystyle", "false"), n.setAttribute("scriptlevel", "1"), n; + } + }), se({ + type: "cdlabelparent", + names: ["\\\\cdparent"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "cdlabelparent", + mode: n.mode, + fragment: t[0] + }; + }, + htmlBuilder: function(e, t) { + var n = N.wrapFragment(Me(e.fragment, t), t); + return n.classes.push("cd-vert-arrow"), n; + }, + mathmlBuilder: function(e, t) { + return new K.MathNode("mrow", [Ue(e.fragment, t)]); + } + }), se({ + type: "textord", + names: ["\\@char"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + for (var n = e.parser, l = ye(t[0], "ordgroup"), c = l.body, m = "", b = 0; b < c.length; b++) { + var k = ye(c[b], "textord"); + m += k.text; + } + var x = parseInt(m), C; + if (isNaN(x)) + throw new u("\\@char has non-numeric argument " + m); + if (x < 0 || x >= 1114111) + throw new u("\\@char with invalid code point " + m); + return x <= 65535 ? C = String.fromCharCode(x) : (x -= 65536, C = String.fromCharCode((x >> 10) + 55296, (x & 1023) + 56320)), { + type: "textord", + mode: n.mode, + text: C + }; + } + }); + var Ci = function(e, t) { + var n = it(e.body, t.withColor(e.color), !1); + return N.makeFragment(n); + }, Ei = function(e, t) { + var n = St(e.body, t.withColor(e.color)), l = new K.MathNode("mstyle", n); + return l.setAttribute("mathcolor", e.color), l; + }; + se({ + type: "color", + names: ["\\textcolor"], + props: { + numArgs: 2, + allowedInText: !0, + argTypes: ["color", "original"] + }, + handler: function(e, t) { + var n = e.parser, l = ye(t[0], "color-token").color, c = t[1]; + return { + type: "color", + mode: n.mode, + color: l, + body: at(c) + }; + }, + htmlBuilder: Ci, + mathmlBuilder: Ei + }), se({ + type: "color", + names: ["\\color"], + props: { + numArgs: 1, + allowedInText: !0, + argTypes: ["color"] + }, + handler: function(e, t) { + var n = e.parser, l = e.breakOnTokenText, c = ye(t[0], "color-token").color; + n.gullet.macros.set("\\current@color", c); + var m = n.parseExpression(!0, l); + return { + type: "color", + mode: n.mode, + color: c, + body: m + }; + }, + htmlBuilder: Ci, + mathmlBuilder: Ei + }), se({ + type: "cr", + names: ["\\\\"], + props: { + numArgs: 0, + numOptionalArgs: 0, + allowedInText: !0 + }, + handler: function(e, t, n) { + var l = e.parser, c = l.gullet.future().text === "[" ? l.parseSizeGroup(!0) : null, m = !l.settings.displayMode || !l.settings.useStrictBehavior("newLineInDisplayMode", "In LaTeX, \\\\ or \\newline does nothing in display mode"); + return { + type: "cr", + mode: l.mode, + newLine: m, + size: c && ye(c, "size").value + }; + }, + // The following builders are called only at the top level, + // not within tabular/array environments. + htmlBuilder: function(e, t) { + var n = N.makeSpan(["mspace"], [], t); + return e.newLine && (n.classes.push("newline"), e.size && (n.style.marginTop = ee(Pe(e.size, t)))), n; + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mspace"); + return e.newLine && (n.setAttribute("linebreak", "newline"), e.size && n.setAttribute("height", ee(Pe(e.size, t)))), n; + } + }); + var ra = { + "\\global": "\\global", + "\\long": "\\\\globallong", + "\\\\globallong": "\\\\globallong", + "\\def": "\\gdef", + "\\gdef": "\\gdef", + "\\edef": "\\xdef", + "\\xdef": "\\xdef", + "\\let": "\\\\globallet", + "\\futurelet": "\\\\globalfuture" + }, Bi = function(e) { + var t = e.text; + if (/^(?:[\\{}$&#^_]|EOF)$/.test(t)) + throw new u("Expected a control sequence", e); + return t; + }, A1 = function(e) { + var t = e.gullet.popToken(); + return t.text === "=" && (t = e.gullet.popToken(), t.text === " " && (t = e.gullet.popToken())), t; + }, Di = function(e, t, n, l) { + var c = e.gullet.macros.get(n.text); + c == null && (n.noexpand = !0, c = { + tokens: [n], + numArgs: 0, + // reproduce the same behavior in expansion + unexpandable: !e.gullet.isExpandable(n.text) + }), e.gullet.macros.set(t, c, l); + }; + se({ + type: "internal", + names: [ + "\\global", + "\\long", + "\\\\globallong" + // can’t be entered directly + ], + props: { + numArgs: 0, + allowedInText: !0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName; + t.consumeSpaces(); + var l = t.fetch(); + if (ra[l.text]) + return (n === "\\global" || n === "\\\\globallong") && (l.text = ra[l.text]), ye(t.parseFunction(), "internal"); + throw new u("Invalid token after macro prefix", l); + } + }), se({ + type: "internal", + names: ["\\def", "\\gdef", "\\edef", "\\xdef"], + props: { + numArgs: 0, + allowedInText: !0, + primitive: !0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName, l = t.gullet.popToken(), c = l.text; + if (/^(?:[\\{}$&#^_]|EOF)$/.test(c)) + throw new u("Expected a control sequence", l); + for (var m = 0, b, k = [[]]; t.gullet.future().text !== "{"; ) + if (l = t.gullet.popToken(), l.text === "#") { + if (t.gullet.future().text === "{") { + b = t.gullet.future(), k[m].push("{"); + break; + } + if (l = t.gullet.popToken(), !/^[1-9]$/.test(l.text)) + throw new u('Invalid argument number "' + l.text + '"'); + if (parseInt(l.text) !== m + 1) + throw new u('Argument number "' + l.text + '" out of order'); + m++, k.push([]); + } else { + if (l.text === "EOF") + throw new u("Expected a macro definition"); + k[m].push(l.text); + } + var x = t.gullet.consumeArg(), C = x.tokens; + return b && C.unshift(b), (n === "\\edef" || n === "\\xdef") && (C = t.gullet.expandTokens(C), C.reverse()), t.gullet.macros.set(c, { + tokens: C, + numArgs: m, + delimiters: k + }, n === ra[n]), { + type: "internal", + mode: t.mode + }; + } + }), se({ + type: "internal", + names: [ + "\\let", + "\\\\globallet" + // can’t be entered directly + ], + props: { + numArgs: 0, + allowedInText: !0, + primitive: !0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName, l = Bi(t.gullet.popToken()); + t.gullet.consumeSpaces(); + var c = A1(t); + return Di(t, l, c, n === "\\\\globallet"), { + type: "internal", + mode: t.mode + }; + } + }), se({ + type: "internal", + names: [ + "\\futurelet", + "\\\\globalfuture" + // can’t be entered directly + ], + props: { + numArgs: 0, + allowedInText: !0, + primitive: !0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName, l = Bi(t.gullet.popToken()), c = t.gullet.popToken(), m = t.gullet.popToken(); + return Di(t, l, m, n === "\\\\globalfuture"), t.gullet.pushToken(m), t.gullet.pushToken(c), { + type: "internal", + mode: t.mode + }; + } + }); + var Nr = function(e, t, n) { + var l = Ve.math[e] && Ve.math[e].replace, c = Xt(l || e, t, n); + if (!c) + throw new Error("Unsupported symbol " + e + " and font size " + t + "."); + return c; + }, na = function(e, t, n, l) { + var c = n.havingBaseStyle(t), m = N.makeSpan(l.concat(c.sizingClasses(n)), [e], n), b = c.sizeMultiplier / n.sizeMultiplier; + return m.height *= b, m.depth *= b, m.maxFontSize = c.sizeMultiplier, m; + }, Ni = function(e, t, n) { + var l = t.havingBaseStyle(n), c = (1 - t.sizeMultiplier / l.sizeMultiplier) * t.fontMetrics().axisHeight; + e.classes.push("delimcenter"), e.style.top = ee(c), e.height -= c, e.depth += c; + }, T1 = function(e, t, n, l, c, m) { + var b = N.makeSymbol(e, "Main-Regular", c, l), k = na(b, t, l, m); + return n && Ni(k, l, t), k; + }, M1 = function(e, t, n, l) { + return N.makeSymbol(e, "Size" + t + "-Regular", n, l); + }, Ri = function(e, t, n, l, c, m) { + var b = M1(e, t, c, l), k = na(N.makeSpan(["delimsizing", "size" + t], [b], l), Q.TEXT, l, m); + return n && Ni(k, l, Q.TEXT), k; + }, aa = function(e, t, n) { + var l; + t === "Size1-Regular" ? l = "delim-size1" : l = "delim-size4"; + var c = N.makeSpan(["delimsizinginner", l], [N.makeSpan([], [N.makeSymbol(e, t, n)])]); + return { + type: "elem", + elem: c + }; + }, ia = function(e, t, n) { + var l = Nt["Size4-Regular"][e.charCodeAt(0)] ? Nt["Size4-Regular"][e.charCodeAt(0)][4] : Nt["Size1-Regular"][e.charCodeAt(0)][4], c = new Zt("inner", rr(e, Math.round(1e3 * t))), m = new Ft([c], { + width: ee(l), + height: ee(t), + // Override CSS rule `.katex svg { width: 100% }` + style: "width:" + ee(l), + viewBox: "0 0 " + 1e3 * l + " " + Math.round(1e3 * t), + preserveAspectRatio: "xMinYMin" + }), b = N.makeSvgSpan([], [m], n); + return b.height = t, b.style.height = ee(t), b.style.width = ee(l), { + type: "elem", + elem: b + }; + }, la = 8e-3, cn = { + type: "kern", + size: -1 * la + }, z1 = ["|", "\\lvert", "\\rvert", "\\vert"], C1 = ["\\|", "\\lVert", "\\rVert", "\\Vert"], Fi = function(e, t, n, l, c, m) { + var b, k, x, C, D = "", P = 0; + b = x = C = e, k = null; + var q = "Size1-Regular"; + e === "\\uparrow" ? x = C = "⏐" : e === "\\Uparrow" ? x = C = "‖" : e === "\\downarrow" ? b = x = "⏐" : e === "\\Downarrow" ? b = x = "‖" : e === "\\updownarrow" ? (b = "\\uparrow", x = "⏐", C = "\\downarrow") : e === "\\Updownarrow" ? (b = "\\Uparrow", x = "‖", C = "\\Downarrow") : V.contains(z1, e) ? (x = "∣", D = "vert", P = 333) : V.contains(C1, e) ? (x = "∥", D = "doublevert", P = 556) : e === "[" || e === "\\lbrack" ? (b = "⎡", x = "⎢", C = "⎣", q = "Size4-Regular", D = "lbrack", P = 667) : e === "]" || e === "\\rbrack" ? (b = "⎤", x = "⎥", C = "⎦", q = "Size4-Regular", D = "rbrack", P = 667) : e === "\\lfloor" || e === "⌊" ? (x = b = "⎢", C = "⎣", q = "Size4-Regular", D = "lfloor", P = 667) : e === "\\lceil" || e === "⌈" ? (b = "⎡", x = C = "⎢", q = "Size4-Regular", D = "lceil", P = 667) : e === "\\rfloor" || e === "⌋" ? (x = b = "⎥", C = "⎦", q = "Size4-Regular", D = "rfloor", P = 667) : e === "\\rceil" || e === "⌉" ? (b = "⎤", x = C = "⎥", q = "Size4-Regular", D = "rceil", P = 667) : e === "(" || e === "\\lparen" ? (b = "⎛", x = "⎜", C = "⎝", q = "Size4-Regular", D = "lparen", P = 875) : e === ")" || e === "\\rparen" ? (b = "⎞", x = "⎟", C = "⎠", q = "Size4-Regular", D = "rparen", P = 875) : e === "\\{" || e === "\\lbrace" ? (b = "⎧", k = "⎨", C = "⎩", x = "⎪", q = "Size4-Regular") : e === "\\}" || e === "\\rbrace" ? (b = "⎫", k = "⎬", C = "⎭", x = "⎪", q = "Size4-Regular") : e === "\\lgroup" || e === "⟮" ? (b = "⎧", C = "⎩", x = "⎪", q = "Size4-Regular") : e === "\\rgroup" || e === "⟯" ? (b = "⎫", C = "⎭", x = "⎪", q = "Size4-Regular") : e === "\\lmoustache" || e === "⎰" ? (b = "⎧", C = "⎭", x = "⎪", q = "Size4-Regular") : (e === "\\rmoustache" || e === "⎱") && (b = "⎫", C = "⎩", x = "⎪", q = "Size4-Regular"); + var U = Nr(b, q, c), $ = U.height + U.depth, ie = Nr(x, q, c), he = ie.height + ie.depth, de = Nr(C, q, c), ge = de.height + de.depth, Be = 0, we = 1; + if (k !== null) { + var Ie = Nr(k, q, c); + Be = Ie.height + Ie.depth, we = 2; + } + var ze = $ + ge + Be, qe = Math.max(0, Math.ceil((t - ze) / (we * he))), Ye = ze + qe * we * he, ut = l.fontMetrics().axisHeight; + n && (ut *= l.sizeMultiplier); + var Mt = Ye / 2 - ut, Ze = []; + if (D.length > 0) { + var Q0 = Ye - $ - ge, Ot = Math.round(Ye * 1e3), wt = Vr(D, Math.round(Q0 * 1e3)), B0 = new Zt(D, wt), ur = (P / 1e3).toFixed(3) + "em", cr = (Ot / 1e3).toFixed(3) + "em", Aa = new Ft([B0], { + width: ur, + height: cr, + viewBox: "0 0 " + P + " " + Ot + }), D0 = N.makeSvgSpan([], [Aa], l); + D0.height = Ot / 1e3, D0.style.width = ur, D0.style.height = cr, Ze.push({ + type: "elem", + elem: D0 + }); + } else { + if (Ze.push(aa(C, q, c)), Ze.push(cn), k === null) { + var N0 = Ye - $ - ge + 2 * la; + Ze.push(ia(x, N0, l)); + } else { + var qt = (Ye - $ - ge - Be) / 2 + 2 * la; + Ze.push(ia(x, qt, l)), Ze.push(cn), Ze.push(aa(k, q, c)), Ze.push(cn), Ze.push(ia(x, qt, l)); + } + Ze.push(cn), Ze.push(aa(b, q, c)); + } + var Lr = l.havingBaseStyle(Q.TEXT), Ta = N.makeVList({ + positionType: "bottom", + positionData: Mt, + children: Ze + }, Lr); + return na(N.makeSpan(["delimsizing", "mult"], [Ta], Lr), Q.TEXT, l, m); + }, sa = 80, oa = 0.08, ua = function(e, t, n, l, c) { + var m = b0(e, l, n), b = new Zt(e, m), k = new Ft([b], { + // Note: 1000:1 ratio of viewBox to document em width. + width: "400em", + height: ee(t), + viewBox: "0 0 400000 " + n, + preserveAspectRatio: "xMinYMin slice" + }); + return N.makeSvgSpan(["hide-tail"], [k], c); + }, E1 = function(e, t) { + var n = t.havingBaseSizing(), l = qi("\\surd", e * n.sizeMultiplier, Oi, n), c = n.sizeMultiplier, m = Math.max(0, t.minRuleThickness - t.fontMetrics().sqrtRuleThickness), b, k = 0, x = 0, C = 0, D; + return l.type === "small" ? (C = 1e3 + 1e3 * m + sa, e < 1 ? c = 1 : e < 1.4 && (c = 0.7), k = (1 + m + oa) / c, x = (1 + m) / c, b = ua("sqrtMain", k, C, m, t), b.style.minWidth = "0.853em", D = 0.833 / c) : l.type === "large" ? (C = (1e3 + sa) * Rr[l.size], x = (Rr[l.size] + m) / c, k = (Rr[l.size] + m + oa) / c, b = ua("sqrtSize" + l.size, k, C, m, t), b.style.minWidth = "1.02em", D = 1 / c) : (k = e + m + oa, x = e + m, C = Math.floor(1e3 * e + m) + sa, b = ua("sqrtTall", k, C, m, t), b.style.minWidth = "0.742em", D = 1.056), b.height = x, b.style.height = ee(k), { + span: b, + advanceWidth: D, + // Calculate the actual line width. + // This actually should depend on the chosen font -- e.g. \boldmath + // should use the thicker surd symbols from e.g. KaTeX_Main-Bold, and + // have thicker rules. + ruleWidth: (t.fontMetrics().sqrtRuleThickness + m) * c + }; + }, Li = ["(", "\\lparen", ")", "\\rparen", "[", "\\lbrack", "]", "\\rbrack", "\\{", "\\lbrace", "\\}", "\\rbrace", "\\lfloor", "\\rfloor", "⌊", "⌋", "\\lceil", "\\rceil", "⌈", "⌉", "\\surd"], B1 = ["\\uparrow", "\\downarrow", "\\updownarrow", "\\Uparrow", "\\Downarrow", "\\Updownarrow", "|", "\\|", "\\vert", "\\Vert", "\\lvert", "\\rvert", "\\lVert", "\\rVert", "\\lgroup", "\\rgroup", "⟮", "⟯", "\\lmoustache", "\\rmoustache", "⎰", "⎱"], Ii = ["<", ">", "\\langle", "\\rangle", "/", "\\backslash", "\\lt", "\\gt"], Rr = [0, 1.2, 1.8, 2.4, 3], D1 = function(e, t, n, l, c) { + if (e === "<" || e === "\\lt" || e === "⟨" ? e = "\\langle" : (e === ">" || e === "\\gt" || e === "⟩") && (e = "\\rangle"), V.contains(Li, e) || V.contains(Ii, e)) + return Ri(e, t, !1, n, l, c); + if (V.contains(B1, e)) + return Fi(e, Rr[t], !1, n, l, c); + throw new u("Illegal delimiter: '" + e + "'"); + }, N1 = [{ + type: "small", + style: Q.SCRIPTSCRIPT + }, { + type: "small", + style: Q.SCRIPT + }, { + type: "small", + style: Q.TEXT + }, { + type: "large", + size: 1 + }, { + type: "large", + size: 2 + }, { + type: "large", + size: 3 + }, { + type: "large", + size: 4 + }], R1 = [{ + type: "small", + style: Q.SCRIPTSCRIPT + }, { + type: "small", + style: Q.SCRIPT + }, { + type: "small", + style: Q.TEXT + }, { + type: "stack" + }], Oi = [{ + type: "small", + style: Q.SCRIPTSCRIPT + }, { + type: "small", + style: Q.SCRIPT + }, { + type: "small", + style: Q.TEXT + }, { + type: "large", + size: 1 + }, { + type: "large", + size: 2 + }, { + type: "large", + size: 3 + }, { + type: "large", + size: 4 + }, { + type: "stack" + }], F1 = function(e) { + if (e.type === "small") + return "Main-Regular"; + if (e.type === "large") + return "Size" + e.size + "-Regular"; + if (e.type === "stack") + return "Size4-Regular"; + throw new Error("Add support for delim type '" + e.type + "' here."); + }, qi = function(e, t, n, l) { + for (var c = Math.min(2, 3 - l.style.size), m = c; m < n.length && n[m].type !== "stack"; m++) { + var b = Nr(e, F1(n[m]), "math"), k = b.height + b.depth; + if (n[m].type === "small") { + var x = l.havingBaseStyle(n[m].style); + k *= x.sizeMultiplier; + } + if (k > t) + return n[m]; + } + return n[n.length - 1]; + }, Pi = function(e, t, n, l, c, m) { + e === "<" || e === "\\lt" || e === "⟨" ? e = "\\langle" : (e === ">" || e === "\\gt" || e === "⟩") && (e = "\\rangle"); + var b; + V.contains(Ii, e) ? b = N1 : V.contains(Li, e) ? b = Oi : b = R1; + var k = qi(e, t, b, l); + return k.type === "small" ? T1(e, k.style, n, l, c, m) : k.type === "large" ? Ri(e, k.size, n, l, c, m) : Fi(e, t, n, l, c, m); + }, L1 = function(e, t, n, l, c, m) { + var b = l.fontMetrics().axisHeight * l.sizeMultiplier, k = 901, x = 5 / l.fontMetrics().ptPerEm, C = Math.max(t - b, n + b), D = Math.max( + // In real TeX, calculations are done using integral values which are + // 65536 per pt, or 655360 per em. So, the division here truncates in + // TeX but doesn't here, producing different results. If we wanted to + // exactly match TeX's calculation, we could do + // Math.floor(655360 * maxDistFromAxis / 500) * + // delimiterFactor / 655360 + // (To see the difference, compare + // x^{x^{\left(\rule{0.1em}{0.68em}\right)}} + // in TeX and KaTeX) + C / 500 * k, + 2 * C - x + ); + return Pi(e, D, !0, l, c, m); + }, d0 = { + sqrtImage: E1, + sizedDelim: D1, + sizeToMaxHeight: Rr, + customSizedDelim: Pi, + leftRightDelim: L1 + }, Hi = { + "\\bigl": { + mclass: "mopen", + size: 1 + }, + "\\Bigl": { + mclass: "mopen", + size: 2 + }, + "\\biggl": { + mclass: "mopen", + size: 3 + }, + "\\Biggl": { + mclass: "mopen", + size: 4 + }, + "\\bigr": { + mclass: "mclose", + size: 1 + }, + "\\Bigr": { + mclass: "mclose", + size: 2 + }, + "\\biggr": { + mclass: "mclose", + size: 3 + }, + "\\Biggr": { + mclass: "mclose", + size: 4 + }, + "\\bigm": { + mclass: "mrel", + size: 1 + }, + "\\Bigm": { + mclass: "mrel", + size: 2 + }, + "\\biggm": { + mclass: "mrel", + size: 3 + }, + "\\Biggm": { + mclass: "mrel", + size: 4 + }, + "\\big": { + mclass: "mord", + size: 1 + }, + "\\Big": { + mclass: "mord", + size: 2 + }, + "\\bigg": { + mclass: "mord", + size: 3 + }, + "\\Bigg": { + mclass: "mord", + size: 4 + } + }, I1 = ["(", "\\lparen", ")", "\\rparen", "[", "\\lbrack", "]", "\\rbrack", "\\{", "\\lbrace", "\\}", "\\rbrace", "\\lfloor", "\\rfloor", "⌊", "⌋", "\\lceil", "\\rceil", "⌈", "⌉", "<", ">", "\\langle", "⟨", "\\rangle", "⟩", "\\lt", "\\gt", "\\lvert", "\\rvert", "\\lVert", "\\rVert", "\\lgroup", "\\rgroup", "⟮", "⟯", "\\lmoustache", "\\rmoustache", "⎰", "⎱", "/", "\\backslash", "|", "\\vert", "\\|", "\\Vert", "\\uparrow", "\\Uparrow", "\\downarrow", "\\Downarrow", "\\updownarrow", "\\Updownarrow", "."]; + function hn(f, e) { + var t = sn(f); + if (t && V.contains(I1, t.text)) + return t; + throw t ? new u("Invalid delimiter '" + t.text + "' after '" + e.funcName + "'", f) : new u("Invalid delimiter type '" + f.type + "'", f); + } + se({ + type: "delimsizing", + names: ["\\bigl", "\\Bigl", "\\biggl", "\\Biggl", "\\bigr", "\\Bigr", "\\biggr", "\\Biggr", "\\bigm", "\\Bigm", "\\biggm", "\\Biggm", "\\big", "\\Big", "\\bigg", "\\Bigg"], + props: { + numArgs: 1, + argTypes: ["primitive"] + }, + handler: function(e, t) { + var n = hn(t[0], e); + return { + type: "delimsizing", + mode: e.parser.mode, + size: Hi[e.funcName].size, + mclass: Hi[e.funcName].mclass, + delim: n.text + }; + }, + htmlBuilder: function(e, t) { + return e.delim === "." ? N.makeSpan([e.mclass]) : d0.sizedDelim(e.delim, e.size, t, e.mode, [e.mclass]); + }, + mathmlBuilder: function(e) { + var t = []; + e.delim !== "." && t.push(It(e.delim, e.mode)); + var n = new K.MathNode("mo", t); + e.mclass === "mopen" || e.mclass === "mclose" ? n.setAttribute("fence", "true") : n.setAttribute("fence", "false"), n.setAttribute("stretchy", "true"); + var l = ee(d0.sizeToMaxHeight[e.size]); + return n.setAttribute("minsize", l), n.setAttribute("maxsize", l), n; + } + }); + function Ui(f) { + if (!f.body) + throw new Error("Bug: The leftright ParseNode wasn't fully parsed."); + } + se({ + type: "leftright-right", + names: ["\\right"], + props: { + numArgs: 1, + primitive: !0 + }, + handler: function(e, t) { + var n = e.parser.gullet.macros.get("\\current@color"); + if (n && typeof n != "string") + throw new u("\\current@color set to non-string in \\right"); + return { + type: "leftright-right", + mode: e.parser.mode, + delim: hn(t[0], e).text, + color: n + // undefined if not set via \color + }; + } + }), se({ + type: "leftright", + names: ["\\left"], + props: { + numArgs: 1, + primitive: !0 + }, + handler: function(e, t) { + var n = hn(t[0], e), l = e.parser; + ++l.leftrightDepth; + var c = l.parseExpression(!1); + --l.leftrightDepth, l.expect("\\right", !1); + var m = ye(l.parseFunction(), "leftright-right"); + return { + type: "leftright", + mode: l.mode, + body: c, + left: n.text, + right: m.delim, + rightColor: m.color + }; + }, + htmlBuilder: function(e, t) { + Ui(e); + for (var n = it(e.body, t, !0, ["mopen", "mclose"]), l = 0, c = 0, m = !1, b = 0; b < n.length; b++) + n[b].isMiddle ? m = !0 : (l = Math.max(n[b].height, l), c = Math.max(n[b].depth, c)); + l *= t.sizeMultiplier, c *= t.sizeMultiplier; + var k; + if (e.left === "." ? k = Br(t, ["mopen"]) : k = d0.leftRightDelim(e.left, l, c, t, e.mode, ["mopen"]), n.unshift(k), m) + for (var x = 1; x < n.length; x++) { + var C = n[x], D = C.isMiddle; + D && (n[x] = d0.leftRightDelim(D.delim, l, c, D.options, e.mode, [])); + } + var P; + if (e.right === ".") + P = Br(t, ["mclose"]); + else { + var q = e.rightColor ? t.withColor(e.rightColor) : t; + P = d0.leftRightDelim(e.right, l, c, q, e.mode, ["mclose"]); + } + return n.push(P), N.makeSpan(["minner"], n, t); + }, + mathmlBuilder: function(e, t) { + Ui(e); + var n = St(e.body, t); + if (e.left !== ".") { + var l = new K.MathNode("mo", [It(e.left, e.mode)]); + l.setAttribute("fence", "true"), n.unshift(l); + } + if (e.right !== ".") { + var c = new K.MathNode("mo", [It(e.right, e.mode)]); + c.setAttribute("fence", "true"), e.rightColor && c.setAttribute("mathcolor", e.rightColor), n.push(c); + } + return Jn(n); + } + }), se({ + type: "middle", + names: ["\\middle"], + props: { + numArgs: 1, + primitive: !0 + }, + handler: function(e, t) { + var n = hn(t[0], e); + if (!e.parser.leftrightDepth) + throw new u("\\middle without preceding \\left", n); + return { + type: "middle", + mode: e.parser.mode, + delim: n.text + }; + }, + htmlBuilder: function(e, t) { + var n; + if (e.delim === ".") + n = Br(t, []); + else { + n = d0.sizedDelim(e.delim, 1, t, e.mode, []); + var l = { + delim: e.delim, + options: t + }; + n.isMiddle = l; + } + return n; + }, + mathmlBuilder: function(e, t) { + var n = e.delim === "\\vert" || e.delim === "|" ? It("|", "text") : It(e.delim, e.mode), l = new K.MathNode("mo", [n]); + return l.setAttribute("fence", "true"), l.setAttribute("lspace", "0.05em"), l.setAttribute("rspace", "0.05em"), l; + } + }); + var ca = function(e, t) { + var n = N.wrapFragment(Me(e.body, t), t), l = e.label.slice(1), c = t.sizeMultiplier, m, b = 0, k = V.isCharacterBox(e.body); + if (l === "sout") + m = N.makeSpan(["stretchy", "sout"]), m.height = t.fontMetrics().defaultRuleThickness / c, b = -0.5 * t.fontMetrics().xHeight; + else if (l === "phase") { + var x = Pe({ + number: 0.6, + unit: "pt" + }, t), C = Pe({ + number: 0.35, + unit: "ex" + }, t), D = t.havingBaseSizing(); + c = c / D.sizeMultiplier; + var P = n.height + n.depth + x + C; + n.style.paddingLeft = ee(P / 2 + x); + var q = Math.floor(1e3 * P * c), U = V0(q), $ = new Ft([new Zt("phase", U)], { + width: "400em", + height: ee(q / 1e3), + viewBox: "0 0 400000 " + q, + preserveAspectRatio: "xMinYMin slice" + }); + m = N.makeSvgSpan(["hide-tail"], [$], t), m.style.height = ee(P), b = n.depth + x + C; + } else { + /cancel/.test(l) ? k || n.classes.push("cancel-pad") : l === "angl" ? n.classes.push("anglpad") : n.classes.push("boxpad"); + var ie = 0, he = 0, de = 0; + /box/.test(l) ? (de = Math.max( + t.fontMetrics().fboxrule, + // default + t.minRuleThickness + // User override. + ), ie = t.fontMetrics().fboxsep + (l === "colorbox" ? 0 : de), he = ie) : l === "angl" ? (de = Math.max(t.fontMetrics().defaultRuleThickness, t.minRuleThickness), ie = 4 * de, he = Math.max(0, 0.25 - n.depth)) : (ie = k ? 0.2 : 0, he = ie), m = m0.encloseSpan(n, l, ie, he, t), /fbox|boxed|fcolorbox/.test(l) ? (m.style.borderStyle = "solid", m.style.borderWidth = ee(de)) : l === "angl" && de !== 0.049 && (m.style.borderTopWidth = ee(de), m.style.borderRightWidth = ee(de)), b = n.depth + he, e.backgroundColor && (m.style.backgroundColor = e.backgroundColor, e.borderColor && (m.style.borderColor = e.borderColor)); + } + var ge; + if (e.backgroundColor) + ge = N.makeVList({ + positionType: "individualShift", + children: [ + // Put the color background behind inner; + { + type: "elem", + elem: m, + shift: b + }, + { + type: "elem", + elem: n, + shift: 0 + } + ] + }, t); + else { + var Be = /cancel|phase/.test(l) ? ["svg-align"] : []; + ge = N.makeVList({ + positionType: "individualShift", + children: [ + // Write the \cancel stroke on top of inner. + { + type: "elem", + elem: n, + shift: 0 + }, + { + type: "elem", + elem: m, + shift: b, + wrapperClasses: Be + } + ] + }, t); + } + return /cancel/.test(l) && (ge.height = n.height, ge.depth = n.depth), /cancel/.test(l) && !k ? N.makeSpan(["mord", "cancel-lap"], [ge], t) : N.makeSpan(["mord"], [ge], t); + }, ha = function(e, t) { + var n = 0, l = new K.MathNode(e.label.indexOf("colorbox") > -1 ? "mpadded" : "menclose", [Ue(e.body, t)]); + switch (e.label) { + case "\\cancel": + l.setAttribute("notation", "updiagonalstrike"); + break; + case "\\bcancel": + l.setAttribute("notation", "downdiagonalstrike"); + break; + case "\\phase": + l.setAttribute("notation", "phasorangle"); + break; + case "\\sout": + l.setAttribute("notation", "horizontalstrike"); + break; + case "\\fbox": + l.setAttribute("notation", "box"); + break; + case "\\angl": + l.setAttribute("notation", "actuarial"); + break; + case "\\fcolorbox": + case "\\colorbox": + if (n = t.fontMetrics().fboxsep * t.fontMetrics().ptPerEm, l.setAttribute("width", "+" + 2 * n + "pt"), l.setAttribute("height", "+" + 2 * n + "pt"), l.setAttribute("lspace", n + "pt"), l.setAttribute("voffset", n + "pt"), e.label === "\\fcolorbox") { + var c = Math.max( + t.fontMetrics().fboxrule, + // default + t.minRuleThickness + // user override + ); + l.setAttribute("style", "border: " + c + "em solid " + String(e.borderColor)); + } + break; + case "\\xcancel": + l.setAttribute("notation", "updiagonalstrike downdiagonalstrike"); + break; + } + return e.backgroundColor && l.setAttribute("mathbackground", e.backgroundColor), l; + }; + se({ + type: "enclose", + names: ["\\colorbox"], + props: { + numArgs: 2, + allowedInText: !0, + argTypes: ["color", "text"] + }, + handler: function(e, t, n) { + var l = e.parser, c = e.funcName, m = ye(t[0], "color-token").color, b = t[1]; + return { + type: "enclose", + mode: l.mode, + label: c, + backgroundColor: m, + body: b + }; + }, + htmlBuilder: ca, + mathmlBuilder: ha + }), se({ + type: "enclose", + names: ["\\fcolorbox"], + props: { + numArgs: 3, + allowedInText: !0, + argTypes: ["color", "color", "text"] + }, + handler: function(e, t, n) { + var l = e.parser, c = e.funcName, m = ye(t[0], "color-token").color, b = ye(t[1], "color-token").color, k = t[2]; + return { + type: "enclose", + mode: l.mode, + label: c, + backgroundColor: b, + borderColor: m, + body: k + }; + }, + htmlBuilder: ca, + mathmlBuilder: ha + }), se({ + type: "enclose", + names: ["\\fbox"], + props: { + numArgs: 1, + argTypes: ["hbox"], + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "enclose", + mode: n.mode, + label: "\\fbox", + body: t[0] + }; + } + }), se({ + type: "enclose", + names: ["\\cancel", "\\bcancel", "\\xcancel", "\\sout", "\\phase"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "enclose", + mode: n.mode, + label: l, + body: c + }; + }, + htmlBuilder: ca, + mathmlBuilder: ha + }), se({ + type: "enclose", + names: ["\\angl"], + props: { + numArgs: 1, + argTypes: ["hbox"], + allowedInText: !1 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "enclose", + mode: n.mode, + label: "\\angl", + body: t[0] + }; + } + }); + var Gi = {}; + function Qt(f) { + for (var e = f.type, t = f.names, n = f.props, l = f.handler, c = f.htmlBuilder, m = f.mathmlBuilder, b = { + type: e, + numArgs: n.numArgs || 0, + allowedInText: !1, + numOptionalArgs: 0, + handler: l + }, k = 0; k < t.length; ++k) + Gi[t[k]] = b; + c && (rn[e] = c), m && (nn[e] = m); + } + var Vi = {}; + function _(f, e) { + Vi[f] = e; + } + var Vt = /* @__PURE__ */ function() { + function f(e, t, n) { + this.lexer = void 0, this.start = void 0, this.end = void 0, this.lexer = e, this.start = t, this.end = n; + } + return f.range = function(t, n) { + return n ? !t || !t.loc || !n.loc || t.loc.lexer !== n.loc.lexer ? null : new f(t.loc.lexer, t.loc.start, n.loc.end) : t && t.loc; + }, f; + }(), z0 = /* @__PURE__ */ function() { + function f(t, n) { + this.text = void 0, this.loc = void 0, this.noexpand = void 0, this.treatAsRelax = void 0, this.text = t, this.loc = n; + } + var e = f.prototype; + return e.range = function(n, l) { + return new f(l, Vt.range(this, n)); + }, f; + }(); + function ji(f) { + var e = []; + f.consumeSpaces(); + var t = f.fetch().text; + for (t === "\\relax" && (f.consume(), f.consumeSpaces(), t = f.fetch().text); t === "\\hline" || t === "\\hdashline"; ) + f.consume(), e.push(t === "\\hdashline"), f.consumeSpaces(), t = f.fetch().text; + return e; + } + var fn = function(e) { + var t = e.parser.settings; + if (!t.displayMode) + throw new u("{" + e.envName + "} can be used only in display mode."); + }; + function fa(f) { + if (f.indexOf("ed") === -1) + return f.indexOf("*") === -1; + } + function C0(f, e, t) { + var n = e.hskipBeforeAndAfter, l = e.addJot, c = e.cols, m = e.arraystretch, b = e.colSeparationType, k = e.autoTag, x = e.singleRow, C = e.emptySingleRow, D = e.maxNumCols, P = e.leqno; + if (f.gullet.beginGroup(), x || f.gullet.macros.set("\\cr", "\\\\\\relax"), !m) { + var q = f.gullet.expandMacroAsText("\\arraystretch"); + if (q == null) + m = 1; + else if (m = parseFloat(q), !m || m < 0) + throw new u("Invalid \\arraystretch: " + q); + } + f.gullet.beginGroup(); + var U = [], $ = [U], ie = [], he = [], de = k != null ? [] : void 0; + function ge() { + k && f.gullet.macros.set("\\@eqnsw", "1", !0); + } + function Be() { + de && (f.gullet.macros.get("\\df@tag") ? (de.push(f.subparse([new z0("\\df@tag")])), f.gullet.macros.set("\\df@tag", void 0, !0)) : de.push(!!k && f.gullet.macros.get("\\@eqnsw") === "1")); + } + for (ge(), he.push(ji(f)); ; ) { + var we = f.parseExpression(!1, x ? "\\end" : "\\\\"); + f.gullet.endGroup(), f.gullet.beginGroup(), we = { + type: "ordgroup", + mode: f.mode, + body: we + }, t && (we = { + type: "styling", + mode: f.mode, + style: t, + body: [we] + }), U.push(we); + var Ie = f.fetch().text; + if (Ie === "&") { + if (D && U.length === D) { + if (x || b) + throw new u("Too many tab characters: &", f.nextToken); + f.settings.reportNonstrict("textEnv", "Too few columns specified in the {array} column argument."); + } + f.consume(); + } else if (Ie === "\\end") { + Be(), U.length === 1 && we.type === "styling" && we.body[0].body.length === 0 && ($.length > 1 || !C) && $.pop(), he.length < $.length + 1 && he.push([]); + break; + } else if (Ie === "\\\\") { + f.consume(); + var ze = void 0; + f.gullet.future().text !== " " && (ze = f.parseSizeGroup(!0)), ie.push(ze ? ze.value : null), Be(), he.push(ji(f)), U = [], $.push(U), ge(); + } else + throw new u("Expected & or \\\\ or \\cr or \\end", f.nextToken); + } + return f.gullet.endGroup(), f.gullet.endGroup(), { + type: "array", + mode: f.mode, + addJot: l, + arraystretch: m, + body: $, + cols: c, + rowGaps: ie, + hskipBeforeAndAfter: n, + hLinesBeforeRow: he, + colSeparationType: b, + tags: de, + leqno: P + }; + } + function ma(f) { + return f.slice(0, 1) === "d" ? "display" : "text"; + } + var Jt = function(e, t) { + var n, l, c = e.body.length, m = e.hLinesBeforeRow, b = 0, k = new Array(c), x = [], C = Math.max( + // From LaTeX \showthe\arrayrulewidth. Equals 0.04 em. + t.fontMetrics().arrayRuleWidth, + t.minRuleThickness + // User override. + ), D = 1 / t.fontMetrics().ptPerEm, P = 5 * D; + if (e.colSeparationType && e.colSeparationType === "small") { + var q = t.havingStyle(Q.SCRIPT).sizeMultiplier; + P = 0.2778 * (q / t.sizeMultiplier); + } + var U = e.colSeparationType === "CD" ? Pe({ + number: 3, + unit: "ex" + }, t) : 12 * D, $ = 3 * D, ie = e.arraystretch * U, he = 0.7 * ie, de = 0.3 * ie, ge = 0; + function Be(gn) { + for (var vn = 0; vn < gn.length; ++vn) + vn > 0 && (ge += 0.25), x.push({ + pos: ge, + isDashed: gn[vn] + }); + } + for (Be(m[0]), n = 0; n < e.body.length; ++n) { + var we = e.body[n], Ie = he, ze = de; + b < we.length && (b = we.length); + var qe = new Array(we.length); + for (l = 0; l < we.length; ++l) { + var Ye = Me(we[l], t); + ze < Ye.depth && (ze = Ye.depth), Ie < Ye.height && (Ie = Ye.height), qe[l] = Ye; + } + var ut = e.rowGaps[n], Mt = 0; + ut && (Mt = Pe(ut, t), Mt > 0 && (Mt += de, ze < Mt && (ze = Mt), Mt = 0)), e.addJot && (ze += $), qe.height = Ie, qe.depth = ze, ge += Ie, qe.pos = ge, ge += ze + Mt, k[n] = qe, Be(m[n + 1]); + } + var Ze = ge / 2 + t.fontMetrics().axisHeight, Q0 = e.cols || [], Ot = [], wt, B0, ur = []; + if (e.tags && e.tags.some(function(gn) { + return gn; + })) + for (n = 0; n < c; ++n) { + var cr = k[n], Aa = cr.pos - Ze, D0 = e.tags[n], N0 = void 0; + D0 === !0 ? N0 = N.makeSpan(["eqn-num"], [], t) : D0 === !1 ? N0 = N.makeSpan([], [], t) : N0 = N.makeSpan([], it(D0, t, !0), t), N0.depth = cr.depth, N0.height = cr.height, ur.push({ + type: "elem", + elem: N0, + shift: Aa + }); + } + for ( + l = 0, B0 = 0; + // Continue while either there are more columns or more column + // descriptions, so trailing separators don't get lost. + l < b || B0 < Q0.length; + ++l, ++B0 + ) { + for (var qt = Q0[B0] || {}, Lr = !0; qt.type === "separator"; ) { + if (Lr || (wt = N.makeSpan(["arraycolsep"], []), wt.style.width = ee(t.fontMetrics().doubleRuleSep), Ot.push(wt)), qt.separator === "|" || qt.separator === ":") { + var Ta = qt.separator === "|" ? "solid" : "dashed", hr = N.makeSpan(["vertical-separator"], [], t); + hr.style.height = ee(ge), hr.style.borderRightWidth = ee(C), hr.style.borderRightStyle = Ta, hr.style.margin = "0 " + ee(-C / 2); + var Tl = ge - Ze; + Tl && (hr.style.verticalAlign = ee(-Tl)), Ot.push(hr); + } else + throw new u("Invalid separator type: " + qt.separator); + B0++, qt = Q0[B0] || {}, Lr = !1; + } + if (!(l >= b)) { + var fr = void 0; + (l > 0 || e.hskipBeforeAndAfter) && (fr = V.deflt(qt.pregap, P), fr !== 0 && (wt = N.makeSpan(["arraycolsep"], []), wt.style.width = ee(fr), Ot.push(wt))); + var mr = []; + for (n = 0; n < c; ++n) { + var dn = k[n], pn = dn[l]; + if (pn) { + var cu = dn.pos - Ze; + pn.depth = dn.depth, pn.height = dn.height, mr.push({ + type: "elem", + elem: pn, + shift: cu + }); + } + } + mr = N.makeVList({ + positionType: "individualShift", + children: mr + }, t), mr = N.makeSpan(["col-align-" + (qt.align || "c")], [mr]), Ot.push(mr), (l < b - 1 || e.hskipBeforeAndAfter) && (fr = V.deflt(qt.postgap, P), fr !== 0 && (wt = N.makeSpan(["arraycolsep"], []), wt.style.width = ee(fr), Ot.push(wt))); + } + } + if (k = N.makeSpan(["mtable"], Ot), x.length > 0) { + for (var hu = N.makeLineSpan("hline", t, C), fu = N.makeLineSpan("hdashline", t, C), Ma = [{ + type: "elem", + elem: k, + shift: 0 + }]; x.length > 0; ) { + var Ml = x.pop(), zl = Ml.pos - Ze; + Ml.isDashed ? Ma.push({ + type: "elem", + elem: fu, + shift: zl + }) : Ma.push({ + type: "elem", + elem: hu, + shift: zl + }); + } + k = N.makeVList({ + positionType: "individualShift", + children: Ma + }, t); + } + if (ur.length === 0) + return N.makeSpan(["mord"], [k], t); + var za = N.makeVList({ + positionType: "individualShift", + children: ur + }, t); + return za = N.makeSpan(["tag"], [za], t), N.makeFragment([k, za]); + }, O1 = { + c: "center ", + l: "left ", + r: "right " + }, $t = function(e, t) { + for (var n = [], l = new K.MathNode("mtd", [], ["mtr-glue"]), c = new K.MathNode("mtd", [], ["mml-eqn-num"]), m = 0; m < e.body.length; m++) { + for (var b = e.body[m], k = [], x = 0; x < b.length; x++) + k.push(new K.MathNode("mtd", [Ue(b[x], t)])); + e.tags && e.tags[m] && (k.unshift(l), k.push(l), e.leqno ? k.unshift(c) : k.push(c)), n.push(new K.MathNode("mtr", k)); + } + var C = new K.MathNode("mtable", n), D = e.arraystretch === 0.5 ? 0.1 : 0.16 + e.arraystretch - 1 + (e.addJot ? 0.09 : 0); + C.setAttribute("rowspacing", ee(D)); + var P = "", q = ""; + if (e.cols && e.cols.length > 0) { + var U = e.cols, $ = "", ie = !1, he = 0, de = U.length; + U[0].type === "separator" && (P += "top ", he = 1), U[U.length - 1].type === "separator" && (P += "bottom ", de -= 1); + for (var ge = he; ge < de; ge++) + U[ge].type === "align" ? (q += O1[U[ge].align], ie && ($ += "none "), ie = !0) : U[ge].type === "separator" && ie && ($ += U[ge].separator === "|" ? "solid " : "dashed ", ie = !1); + C.setAttribute("columnalign", q.trim()), /[sd]/.test($) && C.setAttribute("columnlines", $.trim()); + } + if (e.colSeparationType === "align") { + for (var Be = e.cols || [], we = "", Ie = 1; Ie < Be.length; Ie++) + we += Ie % 2 ? "0em " : "1em "; + C.setAttribute("columnspacing", we.trim()); + } else + e.colSeparationType === "alignat" || e.colSeparationType === "gather" ? C.setAttribute("columnspacing", "0em") : e.colSeparationType === "small" ? C.setAttribute("columnspacing", "0.2778em") : e.colSeparationType === "CD" ? C.setAttribute("columnspacing", "0.5em") : C.setAttribute("columnspacing", "1em"); + var ze = "", qe = e.hLinesBeforeRow; + P += qe[0].length > 0 ? "left " : "", P += qe[qe.length - 1].length > 0 ? "right " : ""; + for (var Ye = 1; Ye < qe.length - 1; Ye++) + ze += qe[Ye].length === 0 ? "none " : qe[Ye][0] ? "dashed " : "solid "; + return /[sd]/.test(ze) && C.setAttribute("rowlines", ze.trim()), P !== "" && (C = new K.MathNode("menclose", [C]), C.setAttribute("notation", P.trim())), e.arraystretch && e.arraystretch < 1 && (C = new K.MathNode("mstyle", [C]), C.setAttribute("scriptlevel", "1")), C; + }, Wi = function(e, t) { + e.envName.indexOf("ed") === -1 && fn(e); + var n = [], l = e.envName.indexOf("at") > -1 ? "alignat" : "align", c = e.envName === "split", m = C0(e.parser, { + cols: n, + addJot: !0, + autoTag: c ? void 0 : fa(e.envName), + emptySingleRow: !0, + colSeparationType: l, + maxNumCols: c ? 2 : void 0, + leqno: e.parser.settings.leqno + }, "display"), b, k = 0, x = { + type: "ordgroup", + mode: e.mode, + body: [] + }; + if (t[0] && t[0].type === "ordgroup") { + for (var C = "", D = 0; D < t[0].body.length; D++) { + var P = ye(t[0].body[D], "textord"); + C += P.text; + } + b = Number(C), k = b * 2; + } + var q = !k; + m.body.forEach(function(he) { + for (var de = 1; de < he.length; de += 2) { + var ge = ye(he[de], "styling"), Be = ye(ge.body[0], "ordgroup"); + Be.body.unshift(x); + } + if (q) + k < he.length && (k = he.length); + else { + var we = he.length / 2; + if (b < we) + throw new u("Too many math in a row: " + ("expected " + b + ", but got " + we), he[0]); + } + }); + for (var U = 0; U < k; ++U) { + var $ = "r", ie = 0; + U % 2 === 1 ? $ = "l" : U > 0 && q && (ie = 1), n[U] = { + type: "align", + align: $, + pregap: ie, + postgap: 0 + }; + } + return m.colSeparationType = q ? "align" : "alignat", m; + }; + Qt({ + type: "array", + names: ["array", "darray"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = sn(t[0]), l = n ? [t[0]] : ye(t[0], "ordgroup").body, c = l.map(function(b) { + var k = ea(b), x = k.text; + if ("lcr".indexOf(x) !== -1) + return { + type: "align", + align: x + }; + if (x === "|") + return { + type: "separator", + separator: "|" + }; + if (x === ":") + return { + type: "separator", + separator: ":" + }; + throw new u("Unknown column alignment: " + x, b); + }), m = { + cols: c, + hskipBeforeAndAfter: !0, + // \@preamble in lttab.dtx + maxNumCols: c.length + }; + return C0(e.parser, m, ma(e.envName)); + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["matrix", "pmatrix", "bmatrix", "Bmatrix", "vmatrix", "Vmatrix", "matrix*", "pmatrix*", "bmatrix*", "Bmatrix*", "vmatrix*", "Vmatrix*"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = { + matrix: null, + pmatrix: ["(", ")"], + bmatrix: ["[", "]"], + Bmatrix: ["\\{", "\\}"], + vmatrix: ["|", "|"], + Vmatrix: ["\\Vert", "\\Vert"] + }[e.envName.replace("*", "")], n = "c", l = { + hskipBeforeAndAfter: !1, + cols: [{ + type: "align", + align: n + }] + }; + if (e.envName.charAt(e.envName.length - 1) === "*") { + var c = e.parser; + if (c.consumeSpaces(), c.fetch().text === "[") { + if (c.consume(), c.consumeSpaces(), n = c.fetch().text, "lcr".indexOf(n) === -1) + throw new u("Expected l or c or r", c.nextToken); + c.consume(), c.consumeSpaces(), c.expect("]"), c.consume(), l.cols = [{ + type: "align", + align: n + }]; + } + } + var m = C0(e.parser, l, ma(e.envName)), b = Math.max.apply(Math, [0].concat(m.body.map(function(k) { + return k.length; + }))); + return m.cols = new Array(b).fill({ + type: "align", + align: n + }), t ? { + type: "leftright", + mode: e.mode, + body: [m], + left: t[0], + right: t[1], + rightColor: void 0 + // \right uninfluenced by \color in array + } : m; + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["smallmatrix"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = { + arraystretch: 0.5 + }, n = C0(e.parser, t, "script"); + return n.colSeparationType = "small", n; + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["subarray"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = sn(t[0]), l = n ? [t[0]] : ye(t[0], "ordgroup").body, c = l.map(function(b) { + var k = ea(b), x = k.text; + if ("lc".indexOf(x) !== -1) + return { + type: "align", + align: x + }; + throw new u("Unknown column alignment: " + x, b); + }); + if (c.length > 1) + throw new u("{subarray} can contain only one column"); + var m = { + cols: c, + hskipBeforeAndAfter: !1, + arraystretch: 0.5 + }; + if (m = C0(e.parser, m, "script"), m.body.length > 0 && m.body[0].length > 1) + throw new u("{subarray} can contain only one column"); + return m; + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["cases", "dcases", "rcases", "drcases"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = { + arraystretch: 1.2, + cols: [{ + type: "align", + align: "l", + pregap: 0, + // TODO(kevinb) get the current style. + // For now we use the metrics for TEXT style which is what we were + // doing before. Before attempting to get the current style we + // should look at TeX's behavior especially for \over and matrices. + postgap: 1 + /* 1em quad */ + }, { + type: "align", + align: "l", + pregap: 0, + postgap: 0 + }] + }, n = C0(e.parser, t, ma(e.envName)); + return { + type: "leftright", + mode: e.mode, + body: [n], + left: e.envName.indexOf("r") > -1 ? "." : "\\{", + right: e.envName.indexOf("r") > -1 ? "\\}" : ".", + rightColor: void 0 + }; + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["align", "align*", "aligned", "split"], + props: { + numArgs: 0 + }, + handler: Wi, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["gathered", "gather", "gather*"], + props: { + numArgs: 0 + }, + handler: function(e) { + V.contains(["gather", "gather*"], e.envName) && fn(e); + var t = { + cols: [{ + type: "align", + align: "c" + }], + addJot: !0, + colSeparationType: "gather", + autoTag: fa(e.envName), + emptySingleRow: !0, + leqno: e.parser.settings.leqno + }; + return C0(e.parser, t, "display"); + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["alignat", "alignat*", "alignedat"], + props: { + numArgs: 1 + }, + handler: Wi, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["equation", "equation*"], + props: { + numArgs: 0 + }, + handler: function(e) { + fn(e); + var t = { + autoTag: fa(e.envName), + emptySingleRow: !0, + singleRow: !0, + maxNumCols: 1, + leqno: e.parser.settings.leqno + }; + return C0(e.parser, t, "display"); + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), Qt({ + type: "array", + names: ["CD"], + props: { + numArgs: 0 + }, + handler: function(e) { + return fn(e), S1(e.parser); + }, + htmlBuilder: Jt, + mathmlBuilder: $t + }), _("\\nonumber", "\\gdef\\@eqnsw{0}"), _("\\notag", "\\nonumber"), se({ + type: "text", + // Doesn't matter what this is. + names: ["\\hline", "\\hdashline"], + props: { + numArgs: 0, + allowedInText: !0, + allowedInMath: !0 + }, + handler: function(e, t) { + throw new u(e.funcName + " valid only within array environment"); + } + }); + var q1 = Gi, Yi = q1; + se({ + type: "environment", + names: ["\\begin", "\\end"], + props: { + numArgs: 1, + argTypes: ["text"] + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + if (c.type !== "ordgroup") + throw new u("Invalid environment name", c); + for (var m = "", b = 0; b < c.body.length; ++b) + m += ye(c.body[b], "textord").text; + if (l === "\\begin") { + if (!Yi.hasOwnProperty(m)) + throw new u("No such environment: " + m, c); + var k = Yi[m], x = n.parseArguments("\\begin{" + m + "}", k), C = x.args, D = x.optArgs, P = { + mode: n.mode, + envName: m, + parser: n + }, q = k.handler(P, C, D); + n.expect("\\end", !1); + var U = n.nextToken, $ = ye(n.parseFunction(), "environment"); + if ($.name !== m) + throw new u("Mismatch: \\begin{" + m + "} matched by \\end{" + $.name + "}", U); + return q; + } + return { + type: "environment", + mode: n.mode, + name: m, + nameGroup: c + }; + } + }); + var Xi = function(e, t) { + var n = e.font, l = t.withFont(n); + return Me(e.body, l); + }, Zi = function(e, t) { + var n = e.font, l = t.withFont(n); + return Ue(e.body, l); + }, Ki = { + "\\Bbb": "\\mathbb", + "\\bold": "\\mathbf", + "\\frak": "\\mathfrak", + "\\bm": "\\boldsymbol" + }; + se({ + type: "font", + names: [ + // styles, except \boldsymbol defined below + "\\mathrm", + "\\mathit", + "\\mathbf", + "\\mathnormal", + // families + "\\mathbb", + "\\mathcal", + "\\mathfrak", + "\\mathscr", + "\\mathsf", + "\\mathtt", + // aliases, except \bm defined below + "\\Bbb", + "\\bold", + "\\frak" + ], + props: { + numArgs: 1, + allowedInArgument: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = an(t[0]), m = l; + return m in Ki && (m = Ki[m]), { + type: "font", + mode: n.mode, + font: m.slice(1), + body: c + }; + }, + htmlBuilder: Xi, + mathmlBuilder: Zi + }), se({ + type: "mclass", + names: ["\\boldsymbol", "\\bm"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = t[0], c = V.isCharacterBox(l); + return { + type: "mclass", + mode: n.mode, + mclass: un(l), + body: [{ + type: "font", + mode: n.mode, + font: "boldsymbol", + body: l + }], + isCharacterBox: c + }; + } + }), se({ + type: "font", + names: ["\\rm", "\\sf", "\\tt", "\\bf", "\\it", "\\cal"], + props: { + numArgs: 0, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = e.breakOnTokenText, m = n.mode, b = n.parseExpression(!0, c), k = "math" + l.slice(1); + return { + type: "font", + mode: m, + font: k, + body: { + type: "ordgroup", + mode: n.mode, + body: b + } + }; + }, + htmlBuilder: Xi, + mathmlBuilder: Zi + }); + var Qi = function(e, t) { + var n = t; + return e === "display" ? n = n.id >= Q.SCRIPT.id ? n.text() : Q.DISPLAY : e === "text" && n.size === Q.DISPLAY.size ? n = Q.TEXT : e === "script" ? n = Q.SCRIPT : e === "scriptscript" && (n = Q.SCRIPTSCRIPT), n; + }, da = function(e, t) { + var n = Qi(e.size, t.style), l = n.fracNum(), c = n.fracDen(), m; + m = t.havingStyle(l); + var b = Me(e.numer, m, t); + if (e.continued) { + var k = 8.5 / t.fontMetrics().ptPerEm, x = 3.5 / t.fontMetrics().ptPerEm; + b.height = b.height < k ? k : b.height, b.depth = b.depth < x ? x : b.depth; + } + m = t.havingStyle(c); + var C = Me(e.denom, m, t), D, P, q; + e.hasBarLine ? (e.barSize ? (P = Pe(e.barSize, t), D = N.makeLineSpan("frac-line", t, P)) : D = N.makeLineSpan("frac-line", t), P = D.height, q = D.height) : (D = null, P = 0, q = t.fontMetrics().defaultRuleThickness); + var U, $, ie; + n.size === Q.DISPLAY.size || e.size === "display" ? (U = t.fontMetrics().num1, P > 0 ? $ = 3 * q : $ = 7 * q, ie = t.fontMetrics().denom1) : (P > 0 ? (U = t.fontMetrics().num2, $ = q) : (U = t.fontMetrics().num3, $ = 3 * q), ie = t.fontMetrics().denom2); + var he; + if (D) { + var ge = t.fontMetrics().axisHeight; + U - b.depth - (ge + 0.5 * P) < $ && (U += $ - (U - b.depth - (ge + 0.5 * P))), ge - 0.5 * P - (C.height - ie) < $ && (ie += $ - (ge - 0.5 * P - (C.height - ie))); + var Be = -(ge - 0.5 * P); + he = N.makeVList({ + positionType: "individualShift", + children: [{ + type: "elem", + elem: C, + shift: ie + }, { + type: "elem", + elem: D, + shift: Be + }, { + type: "elem", + elem: b, + shift: -U + }] + }, t); + } else { + var de = U - b.depth - (C.height - ie); + de < $ && (U += 0.5 * ($ - de), ie += 0.5 * ($ - de)), he = N.makeVList({ + positionType: "individualShift", + children: [{ + type: "elem", + elem: C, + shift: ie + }, { + type: "elem", + elem: b, + shift: -U + }] + }, t); + } + m = t.havingStyle(n), he.height *= m.sizeMultiplier / t.sizeMultiplier, he.depth *= m.sizeMultiplier / t.sizeMultiplier; + var we; + n.size === Q.DISPLAY.size ? we = t.fontMetrics().delim1 : n.size === Q.SCRIPTSCRIPT.size ? we = t.havingStyle(Q.SCRIPT).fontMetrics().delim2 : we = t.fontMetrics().delim2; + var Ie, ze; + return e.leftDelim == null ? Ie = Br(t, ["mopen"]) : Ie = d0.customSizedDelim(e.leftDelim, we, !0, t.havingStyle(n), e.mode, ["mopen"]), e.continued ? ze = N.makeSpan([]) : e.rightDelim == null ? ze = Br(t, ["mclose"]) : ze = d0.customSizedDelim(e.rightDelim, we, !0, t.havingStyle(n), e.mode, ["mclose"]), N.makeSpan(["mord"].concat(m.sizingClasses(t)), [Ie, N.makeSpan(["mfrac"], [he]), ze], t); + }, pa = function(e, t) { + var n = new K.MathNode("mfrac", [Ue(e.numer, t), Ue(e.denom, t)]); + if (!e.hasBarLine) + n.setAttribute("linethickness", "0px"); + else if (e.barSize) { + var l = Pe(e.barSize, t); + n.setAttribute("linethickness", ee(l)); + } + var c = Qi(e.size, t.style); + if (c.size !== t.style.size) { + n = new K.MathNode("mstyle", [n]); + var m = c.size === Q.DISPLAY.size ? "true" : "false"; + n.setAttribute("displaystyle", m), n.setAttribute("scriptlevel", "0"); + } + if (e.leftDelim != null || e.rightDelim != null) { + var b = []; + if (e.leftDelim != null) { + var k = new K.MathNode("mo", [new K.TextNode(e.leftDelim.replace("\\", ""))]); + k.setAttribute("fence", "true"), b.push(k); + } + if (b.push(n), e.rightDelim != null) { + var x = new K.MathNode("mo", [new K.TextNode(e.rightDelim.replace("\\", ""))]); + x.setAttribute("fence", "true"), b.push(x); + } + return Jn(b); + } + return n; + }; + se({ + type: "genfrac", + names: [ + "\\dfrac", + "\\frac", + "\\tfrac", + "\\dbinom", + "\\binom", + "\\tbinom", + "\\\\atopfrac", + // can’t be entered directly + "\\\\bracefrac", + "\\\\brackfrac" + // ditto + ], + props: { + numArgs: 2, + allowedInArgument: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0], m = t[1], b, k = null, x = null, C = "auto"; + switch (l) { + case "\\dfrac": + case "\\frac": + case "\\tfrac": + b = !0; + break; + case "\\\\atopfrac": + b = !1; + break; + case "\\dbinom": + case "\\binom": + case "\\tbinom": + b = !1, k = "(", x = ")"; + break; + case "\\\\bracefrac": + b = !1, k = "\\{", x = "\\}"; + break; + case "\\\\brackfrac": + b = !1, k = "[", x = "]"; + break; + default: + throw new Error("Unrecognized genfrac command"); + } + switch (l) { + case "\\dfrac": + case "\\dbinom": + C = "display"; + break; + case "\\tfrac": + case "\\tbinom": + C = "text"; + break; + } + return { + type: "genfrac", + mode: n.mode, + continued: !1, + numer: c, + denom: m, + hasBarLine: b, + leftDelim: k, + rightDelim: x, + size: C, + barSize: null + }; + }, + htmlBuilder: da, + mathmlBuilder: pa + }), se({ + type: "genfrac", + names: ["\\cfrac"], + props: { + numArgs: 2 + }, + handler: function(e, t) { + var n = e.parser; + e.funcName; + var l = t[0], c = t[1]; + return { + type: "genfrac", + mode: n.mode, + continued: !0, + numer: l, + denom: c, + hasBarLine: !0, + leftDelim: null, + rightDelim: null, + size: "display", + barSize: null + }; + } + }), se({ + type: "infix", + names: ["\\over", "\\choose", "\\atop", "\\brace", "\\brack"], + props: { + numArgs: 0, + infix: !0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName, l = e.token, c; + switch (n) { + case "\\over": + c = "\\frac"; + break; + case "\\choose": + c = "\\binom"; + break; + case "\\atop": + c = "\\\\atopfrac"; + break; + case "\\brace": + c = "\\\\bracefrac"; + break; + case "\\brack": + c = "\\\\brackfrac"; + break; + default: + throw new Error("Unrecognized infix genfrac command"); + } + return { + type: "infix", + mode: t.mode, + replaceWith: c, + token: l + }; + } + }); + var Ji = ["display", "text", "script", "scriptscript"], $i = function(e) { + var t = null; + return e.length > 0 && (t = e, t = t === "." ? null : t), t; + }; + se({ + type: "genfrac", + names: ["\\genfrac"], + props: { + numArgs: 6, + allowedInArgument: !0, + argTypes: ["math", "math", "size", "text", "math", "math"] + }, + handler: function(e, t) { + var n = e.parser, l = t[4], c = t[5], m = an(t[0]), b = m.type === "atom" && m.family === "open" ? $i(m.text) : null, k = an(t[1]), x = k.type === "atom" && k.family === "close" ? $i(k.text) : null, C = ye(t[2], "size"), D, P = null; + C.isBlank ? D = !0 : (P = C.value, D = P.number > 0); + var q = "auto", U = t[3]; + if (U.type === "ordgroup") { + if (U.body.length > 0) { + var $ = ye(U.body[0], "textord"); + q = Ji[Number($.text)]; + } + } else + U = ye(U, "textord"), q = Ji[Number(U.text)]; + return { + type: "genfrac", + mode: n.mode, + numer: l, + denom: c, + continued: !1, + hasBarLine: D, + barSize: P, + leftDelim: b, + rightDelim: x, + size: q + }; + }, + htmlBuilder: da, + mathmlBuilder: pa + }), se({ + type: "infix", + names: ["\\above"], + props: { + numArgs: 1, + argTypes: ["size"], + infix: !0 + }, + handler: function(e, t) { + var n = e.parser; + e.funcName; + var l = e.token; + return { + type: "infix", + mode: n.mode, + replaceWith: "\\\\abovefrac", + size: ye(t[0], "size").value, + token: l + }; + } + }), se({ + type: "genfrac", + names: ["\\\\abovefrac"], + props: { + numArgs: 3, + argTypes: ["math", "size", "math"] + }, + handler: function(e, t) { + var n = e.parser; + e.funcName; + var l = t[0], c = ne(ye(t[1], "infix").size), m = t[2], b = c.number > 0; + return { + type: "genfrac", + mode: n.mode, + numer: l, + denom: m, + continued: !1, + hasBarLine: b, + barSize: c, + leftDelim: null, + rightDelim: null, + size: "auto" + }; + }, + htmlBuilder: da, + mathmlBuilder: pa + }); + var el = function(e, t) { + var n = t.style, l, c; + e.type === "supsub" ? (l = e.sup ? Me(e.sup, t.havingStyle(n.sup()), t) : Me(e.sub, t.havingStyle(n.sub()), t), c = ye(e.base, "horizBrace")) : c = ye(e, "horizBrace"); + var m = Me(c.base, t.havingBaseStyle(Q.DISPLAY)), b = m0.svgSpan(c, t), k; + if (c.isOver ? (k = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: m + }, { + type: "kern", + size: 0.1 + }, { + type: "elem", + elem: b + }] + }, t), k.children[0].children[0].children[1].classes.push("svg-align")) : (k = N.makeVList({ + positionType: "bottom", + positionData: m.depth + 0.1 + b.height, + children: [{ + type: "elem", + elem: b + }, { + type: "kern", + size: 0.1 + }, { + type: "elem", + elem: m + }] + }, t), k.children[0].children[0].children[0].classes.push("svg-align")), l) { + var x = N.makeSpan(["mord", c.isOver ? "mover" : "munder"], [k], t); + c.isOver ? k = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: x + }, { + type: "kern", + size: 0.2 + }, { + type: "elem", + elem: l + }] + }, t) : k = N.makeVList({ + positionType: "bottom", + positionData: x.depth + 0.2 + l.height + l.depth, + children: [{ + type: "elem", + elem: l + }, { + type: "kern", + size: 0.2 + }, { + type: "elem", + elem: x + }] + }, t); + } + return N.makeSpan(["mord", c.isOver ? "mover" : "munder"], [k], t); + }, P1 = function(e, t) { + var n = m0.mathMLnode(e.label); + return new K.MathNode(e.isOver ? "mover" : "munder", [Ue(e.base, t), n]); + }; + se({ + type: "horizBrace", + names: ["\\overbrace", "\\underbrace"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName; + return { + type: "horizBrace", + mode: n.mode, + label: l, + isOver: /^\\over/.test(l), + base: t[0] + }; + }, + htmlBuilder: el, + mathmlBuilder: P1 + }), se({ + type: "href", + names: ["\\href"], + props: { + numArgs: 2, + argTypes: ["url", "original"], + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = t[1], c = ye(t[0], "url").url; + return n.settings.isTrusted({ + command: "\\href", + url: c + }) ? { + type: "href", + mode: n.mode, + href: c, + body: at(l) + } : n.formatUnsupportedCmd("\\href"); + }, + htmlBuilder: function(e, t) { + var n = it(e.body, t, !1); + return N.makeAnchor(e.href, [], n, t); + }, + mathmlBuilder: function(e, t) { + var n = M0(e.body, t); + return n instanceof Lt || (n = new Lt("mrow", [n])), n.setAttribute("href", e.href), n; + } + }), se({ + type: "href", + names: ["\\url"], + props: { + numArgs: 1, + argTypes: ["url"], + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = ye(t[0], "url").url; + if (!n.settings.isTrusted({ + command: "\\url", + url: l + })) + return n.formatUnsupportedCmd("\\url"); + for (var c = [], m = 0; m < l.length; m++) { + var b = l[m]; + b === "~" && (b = "\\textasciitilde"), c.push({ + type: "textord", + mode: "text", + text: b + }); + } + var k = { + type: "text", + mode: n.mode, + font: "\\texttt", + body: c + }; + return { + type: "href", + mode: n.mode, + href: l, + body: at(k) + }; + } + }), se({ + type: "hbox", + names: ["\\hbox"], + props: { + numArgs: 1, + argTypes: ["text"], + allowedInText: !0, + primitive: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "hbox", + mode: n.mode, + body: at(t[0]) + }; + }, + htmlBuilder: function(e, t) { + var n = it(e.body, t, !1); + return N.makeFragment(n); + }, + mathmlBuilder: function(e, t) { + return new K.MathNode("mrow", St(e.body, t)); + } + }), se({ + type: "html", + names: ["\\htmlClass", "\\htmlId", "\\htmlStyle", "\\htmlData"], + props: { + numArgs: 2, + argTypes: ["raw", "original"], + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName; + e.token; + var c = ye(t[0], "raw").string, m = t[1]; + n.settings.strict && n.settings.reportNonstrict("htmlExtension", "HTML extension is disabled on strict mode"); + var b, k = {}; + switch (l) { + case "\\htmlClass": + k.class = c, b = { + command: "\\htmlClass", + class: c + }; + break; + case "\\htmlId": + k.id = c, b = { + command: "\\htmlId", + id: c + }; + break; + case "\\htmlStyle": + k.style = c, b = { + command: "\\htmlStyle", + style: c + }; + break; + case "\\htmlData": { + for (var x = c.split(","), C = 0; C < x.length; C++) { + var D = x[C].split("="); + if (D.length !== 2) + throw new u("Error parsing key-value for \\htmlData"); + k["data-" + D[0].trim()] = D[1].trim(); + } + b = { + command: "\\htmlData", + attributes: k + }; + break; + } + default: + throw new Error("Unrecognized html command"); + } + return n.settings.isTrusted(b) ? { + type: "html", + mode: n.mode, + attributes: k, + body: at(m) + } : n.formatUnsupportedCmd(l); + }, + htmlBuilder: function(e, t) { + var n = it(e.body, t, !1), l = ["enclosing"]; + e.attributes.class && l.push.apply(l, e.attributes.class.trim().split(/\s+/)); + var c = N.makeSpan(l, n, t); + for (var m in e.attributes) + m !== "class" && e.attributes.hasOwnProperty(m) && c.setAttribute(m, e.attributes[m]); + return c; + }, + mathmlBuilder: function(e, t) { + return M0(e.body, t); + } + }), se({ + type: "htmlmathml", + names: ["\\html@mathml"], + props: { + numArgs: 2, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "htmlmathml", + mode: n.mode, + html: at(t[0]), + mathml: at(t[1]) + }; + }, + htmlBuilder: function(e, t) { + var n = it(e.html, t, !1); + return N.makeFragment(n); + }, + mathmlBuilder: function(e, t) { + return M0(e.mathml, t); + } + }); + var ga = function(e) { + if (/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(e)) + return { + number: +e, + unit: "bp" + }; + var t = /([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(e); + if (!t) + throw new u("Invalid size: '" + e + "' in \\includegraphics"); + var n = { + number: +(t[1] + t[2]), + // sign + magnitude, cast to number + unit: t[3] + }; + if (!lr(n)) + throw new u("Invalid unit: '" + n.unit + "' in \\includegraphics."); + return n; + }; + se({ + type: "includegraphics", + names: ["\\includegraphics"], + props: { + numArgs: 1, + numOptionalArgs: 1, + argTypes: ["raw", "url"], + allowedInText: !1 + }, + handler: function(e, t, n) { + var l = e.parser, c = { + number: 0, + unit: "em" + }, m = { + number: 0.9, + unit: "em" + }, b = { + number: 0, + unit: "em" + }, k = ""; + if (n[0]) + for (var x = ye(n[0], "raw").string, C = x.split(","), D = 0; D < C.length; D++) { + var P = C[D].split("="); + if (P.length === 2) { + var q = P[1].trim(); + switch (P[0].trim()) { + case "alt": + k = q; + break; + case "width": + c = ga(q); + break; + case "height": + m = ga(q); + break; + case "totalheight": + b = ga(q); + break; + default: + throw new u("Invalid key: '" + P[0] + "' in \\includegraphics."); + } + } + } + var U = ye(t[0], "url").url; + return k === "" && (k = U, k = k.replace(/^.*[\\/]/, ""), k = k.substring(0, k.lastIndexOf("."))), l.settings.isTrusted({ + command: "\\includegraphics", + url: U + }) ? { + type: "includegraphics", + mode: l.mode, + alt: k, + width: c, + height: m, + totalheight: b, + src: U + } : l.formatUnsupportedCmd("\\includegraphics"); + }, + htmlBuilder: function(e, t) { + var n = Pe(e.height, t), l = 0; + e.totalheight.number > 0 && (l = Pe(e.totalheight, t) - n); + var c = 0; + e.width.number > 0 && (c = Pe(e.width, t)); + var m = { + height: ee(n + l) + }; + c > 0 && (m.width = ee(c)), l > 0 && (m.verticalAlign = ee(-l)); + var b = new Zr(e.src, e.alt, m); + return b.height = n, b.depth = l, b; + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mglyph", []); + n.setAttribute("alt", e.alt); + var l = Pe(e.height, t), c = 0; + if (e.totalheight.number > 0 && (c = Pe(e.totalheight, t) - l, n.setAttribute("valign", ee(-c))), n.setAttribute("height", ee(l + c)), e.width.number > 0) { + var m = Pe(e.width, t); + n.setAttribute("width", ee(m)); + } + return n.setAttribute("src", e.src), n; + } + }), se({ + type: "kern", + names: ["\\kern", "\\mkern", "\\hskip", "\\mskip"], + props: { + numArgs: 1, + argTypes: ["size"], + primitive: !0, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = ye(t[0], "size"); + if (n.settings.strict) { + var m = l[1] === "m", b = c.value.unit === "mu"; + m ? (b || n.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + l + " supports only mu units, " + ("not " + c.value.unit + " units")), n.mode !== "math" && n.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + l + " works only in math mode")) : b && n.settings.reportNonstrict("mathVsTextUnits", "LaTeX's " + l + " doesn't support mu units"); + } + return { + type: "kern", + mode: n.mode, + dimension: c.value + }; + }, + htmlBuilder: function(e, t) { + return N.makeGlue(e.dimension, t); + }, + mathmlBuilder: function(e, t) { + var n = Pe(e.dimension, t); + return new K.SpaceNode(n); + } + }), se({ + type: "lap", + names: ["\\mathllap", "\\mathrlap", "\\mathclap"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "lap", + mode: n.mode, + alignment: l.slice(5), + body: c + }; + }, + htmlBuilder: function(e, t) { + var n; + e.alignment === "clap" ? (n = N.makeSpan([], [Me(e.body, t)]), n = N.makeSpan(["inner"], [n], t)) : n = N.makeSpan(["inner"], [Me(e.body, t)]); + var l = N.makeSpan(["fix"], []), c = N.makeSpan([e.alignment], [n, l], t), m = N.makeSpan(["strut"]); + return m.style.height = ee(c.height + c.depth), c.depth && (m.style.verticalAlign = ee(-c.depth)), c.children.unshift(m), c = N.makeSpan(["thinbox"], [c], t), N.makeSpan(["mord", "vbox"], [c], t); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mpadded", [Ue(e.body, t)]); + if (e.alignment !== "rlap") { + var l = e.alignment === "llap" ? "-1" : "-0.5"; + n.setAttribute("lspace", l + "width"); + } + return n.setAttribute("width", "0px"), n; + } + }), se({ + type: "styling", + names: ["\\(", "$"], + props: { + numArgs: 0, + allowedInText: !0, + allowedInMath: !1 + }, + handler: function(e, t) { + var n = e.funcName, l = e.parser, c = l.mode; + l.switchMode("math"); + var m = n === "\\(" ? "\\)" : "$", b = l.parseExpression(!1, m); + return l.expect(m), l.switchMode(c), { + type: "styling", + mode: l.mode, + style: "text", + body: b + }; + } + }), se({ + type: "text", + // Doesn't matter what this is. + names: ["\\)", "\\]"], + props: { + numArgs: 0, + allowedInText: !0, + allowedInMath: !1 + }, + handler: function(e, t) { + throw new u("Mismatched " + e.funcName); + } + }); + var tl = function(e, t) { + switch (t.style.size) { + case Q.DISPLAY.size: + return e.display; + case Q.TEXT.size: + return e.text; + case Q.SCRIPT.size: + return e.script; + case Q.SCRIPTSCRIPT.size: + return e.scriptscript; + default: + return e.text; + } + }; + se({ + type: "mathchoice", + names: ["\\mathchoice"], + props: { + numArgs: 4, + primitive: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "mathchoice", + mode: n.mode, + display: at(t[0]), + text: at(t[1]), + script: at(t[2]), + scriptscript: at(t[3]) + }; + }, + htmlBuilder: function(e, t) { + var n = tl(e, t), l = it(n, t, !1); + return N.makeFragment(l); + }, + mathmlBuilder: function(e, t) { + var n = tl(e, t); + return M0(n, t); + } + }); + var rl = function(e, t, n, l, c, m, b) { + e = N.makeSpan([], [e]); + var k = n && V.isCharacterBox(n), x, C; + if (t) { + var D = Me(t, l.havingStyle(c.sup()), l); + C = { + elem: D, + kern: Math.max(l.fontMetrics().bigOpSpacing1, l.fontMetrics().bigOpSpacing3 - D.depth) + }; + } + if (n) { + var P = Me(n, l.havingStyle(c.sub()), l); + x = { + elem: P, + kern: Math.max(l.fontMetrics().bigOpSpacing2, l.fontMetrics().bigOpSpacing4 - P.height) + }; + } + var q; + if (C && x) { + var U = l.fontMetrics().bigOpSpacing5 + x.elem.height + x.elem.depth + x.kern + e.depth + b; + q = N.makeVList({ + positionType: "bottom", + positionData: U, + children: [{ + type: "kern", + size: l.fontMetrics().bigOpSpacing5 + }, { + type: "elem", + elem: x.elem, + marginLeft: ee(-m) + }, { + type: "kern", + size: x.kern + }, { + type: "elem", + elem: e + }, { + type: "kern", + size: C.kern + }, { + type: "elem", + elem: C.elem, + marginLeft: ee(m) + }, { + type: "kern", + size: l.fontMetrics().bigOpSpacing5 + }] + }, l); + } else if (x) { + var $ = e.height - b; + q = N.makeVList({ + positionType: "top", + positionData: $, + children: [{ + type: "kern", + size: l.fontMetrics().bigOpSpacing5 + }, { + type: "elem", + elem: x.elem, + marginLeft: ee(-m) + }, { + type: "kern", + size: x.kern + }, { + type: "elem", + elem: e + }] + }, l); + } else if (C) { + var ie = e.depth + b; + q = N.makeVList({ + positionType: "bottom", + positionData: ie, + children: [{ + type: "elem", + elem: e + }, { + type: "kern", + size: C.kern + }, { + type: "elem", + elem: C.elem, + marginLeft: ee(m) + }, { + type: "kern", + size: l.fontMetrics().bigOpSpacing5 + }] + }, l); + } else + return e; + var he = [q]; + if (x && m !== 0 && !k) { + var de = N.makeSpan(["mspace"], [], l); + de.style.marginRight = ee(m), he.unshift(de); + } + return N.makeSpan(["mop", "op-limits"], he, l); + }, nl = ["\\smallint"], or = function(e, t) { + var n, l, c = !1, m; + e.type === "supsub" ? (n = e.sup, l = e.sub, m = ye(e.base, "op"), c = !0) : m = ye(e, "op"); + var b = t.style, k = !1; + b.size === Q.DISPLAY.size && m.symbol && !V.contains(nl, m.name) && (k = !0); + var x; + if (m.symbol) { + var C = k ? "Size2-Regular" : "Size1-Regular", D = ""; + if ((m.name === "\\oiint" || m.name === "\\oiiint") && (D = m.name.slice(1), m.name = D === "oiint" ? "\\iint" : "\\iiint"), x = N.makeSymbol(m.name, C, "math", t, ["mop", "op-symbol", k ? "large-op" : "small-op"]), D.length > 0) { + var P = x.italic, q = N.staticSvg(D + "Size" + (k ? "2" : "1"), t); + x = N.makeVList({ + positionType: "individualShift", + children: [{ + type: "elem", + elem: x, + shift: 0 + }, { + type: "elem", + elem: q, + shift: k ? 0.08 : 0 + }] + }, t), m.name = "\\" + D, x.classes.unshift("mop"), x.italic = P; + } + } else if (m.body) { + var U = it(m.body, t, !0); + U.length === 1 && U[0] instanceof bt ? (x = U[0], x.classes[0] = "mop") : x = N.makeSpan(["mop"], U, t); + } else { + for (var $ = [], ie = 1; ie < m.name.length; ie++) + $.push(N.mathsym(m.name[ie], m.mode, t)); + x = N.makeSpan(["mop"], $, t); + } + var he = 0, de = 0; + return (x instanceof bt || m.name === "\\oiint" || m.name === "\\oiiint") && !m.suppressBaseShift && (he = (x.height - x.depth) / 2 - t.fontMetrics().axisHeight, de = x.italic), c ? rl(x, n, l, t, b, de, he) : (he && (x.style.position = "relative", x.style.top = ee(he)), x); + }, Fr = function(e, t) { + var n; + if (e.symbol) + n = new Lt("mo", [It(e.name, e.mode)]), V.contains(nl, e.name) && n.setAttribute("largeop", "false"); + else if (e.body) + n = new Lt("mo", St(e.body, t)); + else { + n = new Lt("mi", [new Dr(e.name.slice(1))]); + var l = new Lt("mo", [It("⁡", "text")]); + e.parentIsSupSub ? n = new Lt("mrow", [n, l]) : n = wi([n, l]); + } + return n; + }, H1 = { + "∏": "\\prod", + "∐": "\\coprod", + "∑": "\\sum", + "⋀": "\\bigwedge", + "⋁": "\\bigvee", + "⋂": "\\bigcap", + "⋃": "\\bigcup", + "⨀": "\\bigodot", + "⨁": "\\bigoplus", + "⨂": "\\bigotimes", + "⨄": "\\biguplus", + "⨆": "\\bigsqcup" + }; + se({ + type: "op", + names: ["\\coprod", "\\bigvee", "\\bigwedge", "\\biguplus", "\\bigcap", "\\bigcup", "\\intop", "\\prod", "\\sum", "\\bigotimes", "\\bigoplus", "\\bigodot", "\\bigsqcup", "\\smallint", "∏", "∐", "∑", "⋀", "⋁", "⋂", "⋃", "⨀", "⨁", "⨂", "⨄", "⨆"], + props: { + numArgs: 0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = l; + return c.length === 1 && (c = H1[c]), { + type: "op", + mode: n.mode, + limits: !0, + parentIsSupSub: !1, + symbol: !0, + name: c + }; + }, + htmlBuilder: or, + mathmlBuilder: Fr + }), se({ + type: "op", + names: ["\\mathop"], + props: { + numArgs: 1, + primitive: !0 + }, + handler: function(e, t) { + var n = e.parser, l = t[0]; + return { + type: "op", + mode: n.mode, + limits: !1, + parentIsSupSub: !1, + symbol: !1, + body: at(l) + }; + }, + htmlBuilder: or, + mathmlBuilder: Fr + }); + var U1 = { + "∫": "\\int", + "∬": "\\iint", + "∭": "\\iiint", + "∮": "\\oint", + "∯": "\\oiint", + "∰": "\\oiiint" + }; + se({ + type: "op", + names: ["\\arcsin", "\\arccos", "\\arctan", "\\arctg", "\\arcctg", "\\arg", "\\ch", "\\cos", "\\cosec", "\\cosh", "\\cot", "\\cotg", "\\coth", "\\csc", "\\ctg", "\\cth", "\\deg", "\\dim", "\\exp", "\\hom", "\\ker", "\\lg", "\\ln", "\\log", "\\sec", "\\sin", "\\sinh", "\\sh", "\\tan", "\\tanh", "\\tg", "\\th"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName; + return { + type: "op", + mode: t.mode, + limits: !1, + parentIsSupSub: !1, + symbol: !1, + name: n + }; + }, + htmlBuilder: or, + mathmlBuilder: Fr + }), se({ + type: "op", + names: ["\\det", "\\gcd", "\\inf", "\\lim", "\\max", "\\min", "\\Pr", "\\sup"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName; + return { + type: "op", + mode: t.mode, + limits: !0, + parentIsSupSub: !1, + symbol: !1, + name: n + }; + }, + htmlBuilder: or, + mathmlBuilder: Fr + }), se({ + type: "op", + names: ["\\int", "\\iint", "\\iiint", "\\oint", "\\oiint", "\\oiiint", "∫", "∬", "∭", "∮", "∯", "∰"], + props: { + numArgs: 0 + }, + handler: function(e) { + var t = e.parser, n = e.funcName, l = n; + return l.length === 1 && (l = U1[l]), { + type: "op", + mode: t.mode, + limits: !1, + parentIsSupSub: !1, + symbol: !0, + name: l + }; + }, + htmlBuilder: or, + mathmlBuilder: Fr + }); + var al = function(e, t) { + var n, l, c = !1, m; + e.type === "supsub" ? (n = e.sup, l = e.sub, m = ye(e.base, "operatorname"), c = !0) : m = ye(e, "operatorname"); + var b; + if (m.body.length > 0) { + for (var k = m.body.map(function(P) { + var q = P.text; + return typeof q == "string" ? { + type: "textord", + mode: P.mode, + text: q + } : P; + }), x = it(k, t.withFont("mathrm"), !0), C = 0; C < x.length; C++) { + var D = x[C]; + D instanceof bt && (D.text = D.text.replace(/\u2212/, "-").replace(/\u2217/, "*")); + } + b = N.makeSpan(["mop"], x, t); + } else + b = N.makeSpan(["mop"], [], t); + return c ? rl(b, n, l, t, t.style, 0, 0) : b; + }, G1 = function(e, t) { + for (var n = St(e.body, t.withFont("mathrm")), l = !0, c = 0; c < n.length; c++) { + var m = n[c]; + if (!(m instanceof K.SpaceNode)) + if (m instanceof K.MathNode) + switch (m.type) { + case "mi": + case "mn": + case "ms": + case "mspace": + case "mtext": + break; + case "mo": { + var b = m.children[0]; + m.children.length === 1 && b instanceof K.TextNode ? b.text = b.text.replace(/\u2212/, "-").replace(/\u2217/, "*") : l = !1; + break; + } + default: + l = !1; + } + else + l = !1; + } + if (l) { + var k = n.map(function(D) { + return D.toText(); + }).join(""); + n = [new K.TextNode(k)]; + } + var x = new K.MathNode("mi", n); + x.setAttribute("mathvariant", "normal"); + var C = new K.MathNode("mo", [It("⁡", "text")]); + return e.parentIsSupSub ? new K.MathNode("mrow", [x, C]) : K.newDocumentFragment([x, C]); + }; + se({ + type: "operatorname", + names: ["\\operatorname@", "\\operatornamewithlimits"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "operatorname", + mode: n.mode, + body: at(c), + alwaysHandleSupSub: l === "\\operatornamewithlimits", + limits: !1, + parentIsSupSub: !1 + }; + }, + htmlBuilder: al, + mathmlBuilder: G1 + }), _("\\operatorname", "\\@ifstar\\operatornamewithlimits\\operatorname@"), K0({ + type: "ordgroup", + htmlBuilder: function(e, t) { + return e.semisimple ? N.makeFragment(it(e.body, t, !1)) : N.makeSpan(["mord"], it(e.body, t, !0), t); + }, + mathmlBuilder: function(e, t) { + return M0(e.body, t, !0); + } + }), se({ + type: "overline", + names: ["\\overline"], + props: { + numArgs: 1 + }, + handler: function(e, t) { + var n = e.parser, l = t[0]; + return { + type: "overline", + mode: n.mode, + body: l + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.body, t.havingCrampedStyle()), l = N.makeLineSpan("overline-line", t), c = t.fontMetrics().defaultRuleThickness, m = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: n + }, { + type: "kern", + size: 3 * c + }, { + type: "elem", + elem: l + }, { + type: "kern", + size: c + }] + }, t); + return N.makeSpan(["mord", "overline"], [m], t); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mo", [new K.TextNode("‾")]); + n.setAttribute("stretchy", "true"); + var l = new K.MathNode("mover", [Ue(e.body, t), n]); + return l.setAttribute("accent", "true"), l; + } + }), se({ + type: "phantom", + names: ["\\phantom"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = t[0]; + return { + type: "phantom", + mode: n.mode, + body: at(l) + }; + }, + htmlBuilder: function(e, t) { + var n = it(e.body, t.withPhantom(), !1); + return N.makeFragment(n); + }, + mathmlBuilder: function(e, t) { + var n = St(e.body, t); + return new K.MathNode("mphantom", n); + } + }), se({ + type: "hphantom", + names: ["\\hphantom"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = t[0]; + return { + type: "hphantom", + mode: n.mode, + body: l + }; + }, + htmlBuilder: function(e, t) { + var n = N.makeSpan([], [Me(e.body, t.withPhantom())]); + if (n.height = 0, n.depth = 0, n.children) + for (var l = 0; l < n.children.length; l++) + n.children[l].height = 0, n.children[l].depth = 0; + return n = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: n + }] + }, t), N.makeSpan(["mord"], [n], t); + }, + mathmlBuilder: function(e, t) { + var n = St(at(e.body), t), l = new K.MathNode("mphantom", n), c = new K.MathNode("mpadded", [l]); + return c.setAttribute("height", "0px"), c.setAttribute("depth", "0px"), c; + } + }), se({ + type: "vphantom", + names: ["\\vphantom"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = t[0]; + return { + type: "vphantom", + mode: n.mode, + body: l + }; + }, + htmlBuilder: function(e, t) { + var n = N.makeSpan(["inner"], [Me(e.body, t.withPhantom())]), l = N.makeSpan(["fix"], []); + return N.makeSpan(["mord", "rlap"], [n, l], t); + }, + mathmlBuilder: function(e, t) { + var n = St(at(e.body), t), l = new K.MathNode("mphantom", n), c = new K.MathNode("mpadded", [l]); + return c.setAttribute("width", "0px"), c; + } + }), se({ + type: "raisebox", + names: ["\\raisebox"], + props: { + numArgs: 2, + argTypes: ["size", "hbox"], + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = ye(t[0], "size").value, c = t[1]; + return { + type: "raisebox", + mode: n.mode, + dy: l, + body: c + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.body, t), l = Pe(e.dy, t); + return N.makeVList({ + positionType: "shift", + positionData: -l, + children: [{ + type: "elem", + elem: n + }] + }, t); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mpadded", [Ue(e.body, t)]), l = e.dy.number + e.dy.unit; + return n.setAttribute("voffset", l), n; + } + }), se({ + type: "internal", + names: ["\\relax"], + props: { + numArgs: 0, + allowedInText: !0 + }, + handler: function(e) { + var t = e.parser; + return { + type: "internal", + mode: t.mode + }; + } + }), se({ + type: "rule", + names: ["\\rule"], + props: { + numArgs: 2, + numOptionalArgs: 1, + argTypes: ["size", "size", "size"] + }, + handler: function(e, t, n) { + var l = e.parser, c = n[0], m = ye(t[0], "size"), b = ye(t[1], "size"); + return { + type: "rule", + mode: l.mode, + shift: c && ye(c, "size").value, + width: m.value, + height: b.value + }; + }, + htmlBuilder: function(e, t) { + var n = N.makeSpan(["mord", "rule"], [], t), l = Pe(e.width, t), c = Pe(e.height, t), m = e.shift ? Pe(e.shift, t) : 0; + return n.style.borderRightWidth = ee(l), n.style.borderTopWidth = ee(c), n.style.bottom = ee(m), n.width = l, n.height = c + m, n.depth = -m, n.maxFontSize = c * 1.125 * t.sizeMultiplier, n; + }, + mathmlBuilder: function(e, t) { + var n = Pe(e.width, t), l = Pe(e.height, t), c = e.shift ? Pe(e.shift, t) : 0, m = t.color && t.getColor() || "black", b = new K.MathNode("mspace"); + b.setAttribute("mathbackground", m), b.setAttribute("width", ee(n)), b.setAttribute("height", ee(l)); + var k = new K.MathNode("mpadded", [b]); + return c >= 0 ? k.setAttribute("height", ee(c)) : (k.setAttribute("height", ee(c)), k.setAttribute("depth", ee(-c))), k.setAttribute("voffset", ee(c)), k; + } + }); + function il(f, e, t) { + for (var n = it(f, e, !1), l = e.sizeMultiplier / t.sizeMultiplier, c = 0; c < n.length; c++) { + var m = n[c].classes.indexOf("sizing"); + m < 0 ? Array.prototype.push.apply(n[c].classes, e.sizingClasses(t)) : n[c].classes[m + 1] === "reset-size" + e.size && (n[c].classes[m + 1] = "reset-size" + t.size), n[c].height *= l, n[c].depth *= l; + } + return N.makeFragment(n); + } + var ll = ["\\tiny", "\\sixptsize", "\\scriptsize", "\\footnotesize", "\\small", "\\normalsize", "\\large", "\\Large", "\\LARGE", "\\huge", "\\Huge"], V1 = function(e, t) { + var n = t.havingSize(e.size); + return il(e.body, n, t); + }; + se({ + type: "sizing", + names: ll, + props: { + numArgs: 0, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.breakOnTokenText, l = e.funcName, c = e.parser, m = c.parseExpression(!1, n); + return { + type: "sizing", + mode: c.mode, + // Figure out what size to use based on the list of functions above + size: ll.indexOf(l) + 1, + body: m + }; + }, + htmlBuilder: V1, + mathmlBuilder: function(e, t) { + var n = t.havingSize(e.size), l = St(e.body, n), c = new K.MathNode("mstyle", l); + return c.setAttribute("mathsize", ee(n.sizeMultiplier)), c; + } + }), se({ + type: "smash", + names: ["\\smash"], + props: { + numArgs: 1, + numOptionalArgs: 1, + allowedInText: !0 + }, + handler: function(e, t, n) { + var l = e.parser, c = !1, m = !1, b = n[0] && ye(n[0], "ordgroup"); + if (b) + for (var k = "", x = 0; x < b.body.length; ++x) { + var C = b.body[x]; + if (k = C.text, k === "t") + c = !0; + else if (k === "b") + m = !0; + else { + c = !1, m = !1; + break; + } + } + else + c = !0, m = !0; + var D = t[0]; + return { + type: "smash", + mode: l.mode, + body: D, + smashHeight: c, + smashDepth: m + }; + }, + htmlBuilder: function(e, t) { + var n = N.makeSpan([], [Me(e.body, t)]); + if (!e.smashHeight && !e.smashDepth) + return n; + if (e.smashHeight && (n.height = 0, n.children)) + for (var l = 0; l < n.children.length; l++) + n.children[l].height = 0; + if (e.smashDepth && (n.depth = 0, n.children)) + for (var c = 0; c < n.children.length; c++) + n.children[c].depth = 0; + var m = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: n + }] + }, t); + return N.makeSpan(["mord"], [m], t); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mpadded", [Ue(e.body, t)]); + return e.smashHeight && n.setAttribute("height", "0px"), e.smashDepth && n.setAttribute("depth", "0px"), n; + } + }), se({ + type: "sqrt", + names: ["\\sqrt"], + props: { + numArgs: 1, + numOptionalArgs: 1 + }, + handler: function(e, t, n) { + var l = e.parser, c = n[0], m = t[0]; + return { + type: "sqrt", + mode: l.mode, + body: m, + index: c + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.body, t.havingCrampedStyle()); + n.height === 0 && (n.height = t.fontMetrics().xHeight), n = N.wrapFragment(n, t); + var l = t.fontMetrics(), c = l.defaultRuleThickness, m = c; + t.style.id < Q.TEXT.id && (m = t.fontMetrics().xHeight); + var b = c + m / 4, k = n.height + n.depth + b + c, x = d0.sqrtImage(k, t), C = x.span, D = x.ruleWidth, P = x.advanceWidth, q = C.height - D; + q > n.height + n.depth + b && (b = (b + q - n.height - n.depth) / 2); + var U = C.height - n.height - b - D; + n.style.paddingLeft = ee(P); + var $ = N.makeVList({ + positionType: "firstBaseline", + children: [{ + type: "elem", + elem: n, + wrapperClasses: ["svg-align"] + }, { + type: "kern", + size: -(n.height + U) + }, { + type: "elem", + elem: C + }, { + type: "kern", + size: D + }] + }, t); + if (e.index) { + var ie = t.havingStyle(Q.SCRIPTSCRIPT), he = Me(e.index, ie, t), de = 0.6 * ($.height - $.depth), ge = N.makeVList({ + positionType: "shift", + positionData: -de, + children: [{ + type: "elem", + elem: he + }] + }, t), Be = N.makeSpan(["root"], [ge]); + return N.makeSpan(["mord", "sqrt"], [Be, $], t); + } else + return N.makeSpan(["mord", "sqrt"], [$], t); + }, + mathmlBuilder: function(e, t) { + var n = e.body, l = e.index; + return l ? new K.MathNode("mroot", [Ue(n, t), Ue(l, t)]) : new K.MathNode("msqrt", [Ue(n, t)]); + } + }); + var sl = { + display: Q.DISPLAY, + text: Q.TEXT, + script: Q.SCRIPT, + scriptscript: Q.SCRIPTSCRIPT + }; + se({ + type: "styling", + names: ["\\displaystyle", "\\textstyle", "\\scriptstyle", "\\scriptscriptstyle"], + props: { + numArgs: 0, + allowedInText: !0, + primitive: !0 + }, + handler: function(e, t) { + var n = e.breakOnTokenText, l = e.funcName, c = e.parser, m = c.parseExpression(!0, n), b = l.slice(1, l.length - 5); + return { + type: "styling", + mode: c.mode, + // Figure out what style to use by pulling out the style from + // the function name + style: b, + body: m + }; + }, + htmlBuilder: function(e, t) { + var n = sl[e.style], l = t.havingStyle(n).withFont(""); + return il(e.body, l, t); + }, + mathmlBuilder: function(e, t) { + var n = sl[e.style], l = t.havingStyle(n), c = St(e.body, l), m = new K.MathNode("mstyle", c), b = { + display: ["0", "true"], + text: ["0", "false"], + script: ["1", "false"], + scriptscript: ["2", "false"] + }, k = b[e.style]; + return m.setAttribute("scriptlevel", k[0]), m.setAttribute("displaystyle", k[1]), m; + } + }); + var j1 = function(e, t) { + var n = e.base; + if (n) + if (n.type === "op") { + var l = n.limits && (t.style.size === Q.DISPLAY.size || n.alwaysHandleSupSub); + return l ? or : null; + } else if (n.type === "operatorname") { + var c = n.alwaysHandleSupSub && (t.style.size === Q.DISPLAY.size || n.limits); + return c ? al : null; + } else { + if (n.type === "accent") + return V.isCharacterBox(n.base) ? ta : null; + if (n.type === "horizBrace") { + var m = !e.sub; + return m === n.isOver ? el : null; + } else + return null; + } + else + return null; + }; + K0({ + type: "supsub", + htmlBuilder: function(e, t) { + var n = j1(e, t); + if (n) + return n(e, t); + var l = e.base, c = e.sup, m = e.sub, b = Me(l, t), k, x, C = t.fontMetrics(), D = 0, P = 0, q = l && V.isCharacterBox(l); + if (c) { + var U = t.havingStyle(t.style.sup()); + k = Me(c, U, t), q || (D = b.height - U.fontMetrics().supDrop * U.sizeMultiplier / t.sizeMultiplier); + } + if (m) { + var $ = t.havingStyle(t.style.sub()); + x = Me(m, $, t), q || (P = b.depth + $.fontMetrics().subDrop * $.sizeMultiplier / t.sizeMultiplier); + } + var ie; + t.style === Q.DISPLAY ? ie = C.sup1 : t.style.cramped ? ie = C.sup3 : ie = C.sup2; + var he = t.sizeMultiplier, de = ee(0.5 / C.ptPerEm / he), ge = null; + if (x) { + var Be = e.base && e.base.type === "op" && e.base.name && (e.base.name === "\\oiint" || e.base.name === "\\oiiint"); + (b instanceof bt || Be) && (ge = ee(-b.italic)); + } + var we; + if (k && x) { + D = Math.max(D, ie, k.depth + 0.25 * C.xHeight), P = Math.max(P, C.sub2); + var Ie = C.defaultRuleThickness, ze = 4 * Ie; + if (D - k.depth - (x.height - P) < ze) { + P = ze - (D - k.depth) + x.height; + var qe = 0.8 * C.xHeight - (D - k.depth); + qe > 0 && (D += qe, P -= qe); + } + var Ye = [{ + type: "elem", + elem: x, + shift: P, + marginRight: de, + marginLeft: ge + }, { + type: "elem", + elem: k, + shift: -D, + marginRight: de + }]; + we = N.makeVList({ + positionType: "individualShift", + children: Ye + }, t); + } else if (x) { + P = Math.max(P, C.sub1, x.height - 0.8 * C.xHeight); + var ut = [{ + type: "elem", + elem: x, + marginLeft: ge, + marginRight: de + }]; + we = N.makeVList({ + positionType: "shift", + positionData: P, + children: ut + }, t); + } else if (k) + D = Math.max(D, ie, k.depth + 0.25 * C.xHeight), we = N.makeVList({ + positionType: "shift", + positionData: -D, + children: [{ + type: "elem", + elem: k, + marginRight: de + }] + }, t); + else + throw new Error("supsub must have either sup or sub."); + var Mt = Kn(b, "right") || "mord"; + return N.makeSpan([Mt], [b, N.makeSpan(["msupsub"], [we])], t); + }, + mathmlBuilder: function(e, t) { + var n = !1, l, c; + e.base && e.base.type === "horizBrace" && (c = !!e.sup, c === e.base.isOver && (n = !0, l = e.base.isOver)), e.base && (e.base.type === "op" || e.base.type === "operatorname") && (e.base.parentIsSupSub = !0); + var m = [Ue(e.base, t)]; + e.sub && m.push(Ue(e.sub, t)), e.sup && m.push(Ue(e.sup, t)); + var b; + if (n) + b = l ? "mover" : "munder"; + else if (e.sub) + if (e.sup) { + var C = e.base; + C && C.type === "op" && C.limits && t.style === Q.DISPLAY || C && C.type === "operatorname" && C.alwaysHandleSupSub && (t.style === Q.DISPLAY || C.limits) ? b = "munderover" : b = "msubsup"; + } else { + var x = e.base; + x && x.type === "op" && x.limits && (t.style === Q.DISPLAY || x.alwaysHandleSupSub) || x && x.type === "operatorname" && x.alwaysHandleSupSub && (x.limits || t.style === Q.DISPLAY) ? b = "munder" : b = "msub"; + } + else { + var k = e.base; + k && k.type === "op" && k.limits && (t.style === Q.DISPLAY || k.alwaysHandleSupSub) || k && k.type === "operatorname" && k.alwaysHandleSupSub && (k.limits || t.style === Q.DISPLAY) ? b = "mover" : b = "msup"; + } + return new K.MathNode(b, m); + } + }), K0({ + type: "atom", + htmlBuilder: function(e, t) { + return N.mathsym(e.text, e.mode, t, ["m" + e.family]); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mo", [It(e.text, e.mode)]); + if (e.family === "bin") { + var l = $n(e, t); + l === "bold-italic" && n.setAttribute("mathvariant", l); + } else + e.family === "punct" ? n.setAttribute("separator", "true") : (e.family === "open" || e.family === "close") && n.setAttribute("stretchy", "false"); + return n; + } + }); + var ol = { + mi: "italic", + mn: "normal", + mtext: "normal" + }; + K0({ + type: "mathord", + htmlBuilder: function(e, t) { + return N.makeOrd(e, t, "mathord"); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mi", [It(e.text, e.mode, t)]), l = $n(e, t) || "italic"; + return l !== ol[n.type] && n.setAttribute("mathvariant", l), n; + } + }), K0({ + type: "textord", + htmlBuilder: function(e, t) { + return N.makeOrd(e, t, "textord"); + }, + mathmlBuilder: function(e, t) { + var n = It(e.text, e.mode, t), l = $n(e, t) || "normal", c; + return e.mode === "text" ? c = new K.MathNode("mtext", [n]) : /[0-9]/.test(e.text) ? c = new K.MathNode("mn", [n]) : e.text === "\\prime" ? c = new K.MathNode("mo", [n]) : c = new K.MathNode("mi", [n]), l !== ol[c.type] && c.setAttribute("mathvariant", l), c; + } + }); + var va = { + "\\nobreak": "nobreak", + "\\allowbreak": "allowbreak" + }, ba = { + " ": {}, + "\\ ": {}, + "~": { + className: "nobreak" + }, + "\\space": {}, + "\\nobreakspace": { + className: "nobreak" + } + }; + K0({ + type: "spacing", + htmlBuilder: function(e, t) { + if (ba.hasOwnProperty(e.text)) { + var n = ba[e.text].className || ""; + if (e.mode === "text") { + var l = N.makeOrd(e, t, "textord"); + return l.classes.push(n), l; + } else + return N.makeSpan(["mspace", n], [N.mathsym(e.text, e.mode, t)], t); + } else { + if (va.hasOwnProperty(e.text)) + return N.makeSpan(["mspace", va[e.text]], [], t); + throw new u('Unknown type of space "' + e.text + '"'); + } + }, + mathmlBuilder: function(e, t) { + var n; + if (ba.hasOwnProperty(e.text)) + n = new K.MathNode("mtext", [new K.TextNode(" ")]); + else { + if (va.hasOwnProperty(e.text)) + return new K.MathNode("mspace"); + throw new u('Unknown type of space "' + e.text + '"'); + } + return n; + } + }); + var ul = function() { + var e = new K.MathNode("mtd", []); + return e.setAttribute("width", "50%"), e; + }; + K0({ + type: "tag", + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mtable", [new K.MathNode("mtr", [ul(), new K.MathNode("mtd", [M0(e.body, t)]), ul(), new K.MathNode("mtd", [M0(e.tag, t)])])]); + return n.setAttribute("width", "100%"), n; + } + }); + var cl = { + "\\text": void 0, + "\\textrm": "textrm", + "\\textsf": "textsf", + "\\texttt": "texttt", + "\\textnormal": "textrm" + }, hl = { + "\\textbf": "textbf", + "\\textmd": "textmd" + }, W1 = { + "\\textit": "textit", + "\\textup": "textup" + }, fl = function(e, t) { + var n = e.font; + return n ? cl[n] ? t.withTextFontFamily(cl[n]) : hl[n] ? t.withTextFontWeight(hl[n]) : t.withTextFontShape(W1[n]) : t; + }; + se({ + type: "text", + names: [ + // Font families + "\\text", + "\\textrm", + "\\textsf", + "\\texttt", + "\\textnormal", + // Font weights + "\\textbf", + "\\textmd", + // Font Shapes + "\\textit", + "\\textup" + ], + props: { + numArgs: 1, + argTypes: ["text"], + allowedInArgument: !0, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser, l = e.funcName, c = t[0]; + return { + type: "text", + mode: n.mode, + body: at(c), + font: l + }; + }, + htmlBuilder: function(e, t) { + var n = fl(e, t), l = it(e.body, n, !0); + return N.makeSpan(["mord", "text"], l, n); + }, + mathmlBuilder: function(e, t) { + var n = fl(e, t); + return M0(e.body, n); + } + }), se({ + type: "underline", + names: ["\\underline"], + props: { + numArgs: 1, + allowedInText: !0 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "underline", + mode: n.mode, + body: t[0] + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.body, t), l = N.makeLineSpan("underline-line", t), c = t.fontMetrics().defaultRuleThickness, m = N.makeVList({ + positionType: "top", + positionData: n.height, + children: [{ + type: "kern", + size: c + }, { + type: "elem", + elem: l + }, { + type: "kern", + size: 3 * c + }, { + type: "elem", + elem: n + }] + }, t); + return N.makeSpan(["mord", "underline"], [m], t); + }, + mathmlBuilder: function(e, t) { + var n = new K.MathNode("mo", [new K.TextNode("‾")]); + n.setAttribute("stretchy", "true"); + var l = new K.MathNode("munder", [Ue(e.body, t), n]); + return l.setAttribute("accentunder", "true"), l; + } + }), se({ + type: "vcenter", + names: ["\\vcenter"], + props: { + numArgs: 1, + argTypes: ["original"], + // In LaTeX, \vcenter can act only on a box. + allowedInText: !1 + }, + handler: function(e, t) { + var n = e.parser; + return { + type: "vcenter", + mode: n.mode, + body: t[0] + }; + }, + htmlBuilder: function(e, t) { + var n = Me(e.body, t), l = t.fontMetrics().axisHeight, c = 0.5 * (n.height - l - (n.depth + l)); + return N.makeVList({ + positionType: "shift", + positionData: c, + children: [{ + type: "elem", + elem: n + }] + }, t); + }, + mathmlBuilder: function(e, t) { + return new K.MathNode("mpadded", [Ue(e.body, t)], ["vcenter"]); + } + }), se({ + type: "verb", + names: ["\\verb"], + props: { + numArgs: 0, + allowedInText: !0 + }, + handler: function(e, t, n) { + throw new u("\\verb ended by end of line instead of matching delimiter"); + }, + htmlBuilder: function(e, t) { + for (var n = ml(e), l = [], c = t.havingStyle(t.style.text()), m = 0; m < n.length; m++) { + var b = n[m]; + b === "~" && (b = "\\textasciitilde"), l.push(N.makeSymbol(b, "Typewriter-Regular", e.mode, c, ["mord", "texttt"])); + } + return N.makeSpan(["mord", "text"].concat(c.sizingClasses(t)), N.tryCombineChars(l), c); + }, + mathmlBuilder: function(e, t) { + var n = new K.TextNode(ml(e)), l = new K.MathNode("mtext", [n]); + return l.setAttribute("mathvariant", "monospace"), l; + } + }); + var ml = function(e) { + return e.body.replace(/ /g, e.star ? "␣" : " "); + }, Y1 = vi, E0 = Y1, dl = `[ \r + ]`, X1 = "\\\\[a-zA-Z@]+", Z1 = "\\\\[^\uD800-\uDFFF]", K1 = "(" + X1 + ")" + dl + "*", Q1 = `\\\\( +|[ \r ]+ +?)[ \r ]*`, ya = "[̀-ͯ]", J1 = new RegExp(ya + "+$"), $1 = "(" + dl + "+)|" + // whitespace + (Q1 + "|") + // \whitespace + "([!-\\[\\]-‧‪-퟿豈-￿]" + // single codepoint + (ya + "*") + // ...plus accents + "|[\uD800-\uDBFF][\uDC00-\uDFFF]" + // surrogate pair + (ya + "*") + // ...plus accents + "|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5" + // \verb unstarred + ("|" + K1) + // \macroName + spaces + ("|" + Z1 + ")"), pl = /* @__PURE__ */ function() { + function f(t, n) { + this.input = void 0, this.settings = void 0, this.tokenRegex = void 0, this.catcodes = void 0, this.input = t, this.settings = n, this.tokenRegex = new RegExp($1, "g"), this.catcodes = { + "%": 14, + // comment character + "~": 13 + // active character + }; + } + var e = f.prototype; + return e.setCatcode = function(n, l) { + this.catcodes[n] = l; + }, e.lex = function() { + var n = this.input, l = this.tokenRegex.lastIndex; + if (l === n.length) + return new z0("EOF", new Vt(this, l, l)); + var c = this.tokenRegex.exec(n); + if (c === null || c.index !== l) + throw new u("Unexpected character: '" + n[l] + "'", new z0(n[l], new Vt(this, l, l + 1))); + var m = c[6] || c[3] || (c[2] ? "\\ " : " "); + if (this.catcodes[m] === 14) { + var b = n.indexOf(` +`, this.tokenRegex.lastIndex); + return b === -1 ? (this.tokenRegex.lastIndex = n.length, this.settings.reportNonstrict("commentAtEnd", "% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)")) : this.tokenRegex.lastIndex = b + 1, this.lex(); + } + return new z0(m, new Vt(this, l, this.tokenRegex.lastIndex)); + }, f; + }(), eu = /* @__PURE__ */ function() { + function f(t, n) { + t === void 0 && (t = {}), n === void 0 && (n = {}), this.current = void 0, this.builtins = void 0, this.undefStack = void 0, this.current = n, this.builtins = t, this.undefStack = []; + } + var e = f.prototype; + return e.beginGroup = function() { + this.undefStack.push({}); + }, e.endGroup = function() { + if (this.undefStack.length === 0) + throw new u("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug"); + var n = this.undefStack.pop(); + for (var l in n) + n.hasOwnProperty(l) && (n[l] == null ? delete this.current[l] : this.current[l] = n[l]); + }, e.endGroups = function() { + for (; this.undefStack.length > 0; ) + this.endGroup(); + }, e.has = function(n) { + return this.current.hasOwnProperty(n) || this.builtins.hasOwnProperty(n); + }, e.get = function(n) { + return this.current.hasOwnProperty(n) ? this.current[n] : this.builtins[n]; + }, e.set = function(n, l, c) { + if (c === void 0 && (c = !1), c) { + for (var m = 0; m < this.undefStack.length; m++) + delete this.undefStack[m][n]; + this.undefStack.length > 0 && (this.undefStack[this.undefStack.length - 1][n] = l); + } else { + var b = this.undefStack[this.undefStack.length - 1]; + b && !b.hasOwnProperty(n) && (b[n] = this.current[n]); + } + l == null ? delete this.current[n] : this.current[n] = l; + }, f; + }(), tu = Vi, ru = tu; + _("\\noexpand", function(f) { + var e = f.popToken(); + return f.isExpandable(e.text) && (e.noexpand = !0, e.treatAsRelax = !0), { + tokens: [e], + numArgs: 0 + }; + }), _("\\expandafter", function(f) { + var e = f.popToken(); + return f.expandOnce(!0), { + tokens: [e], + numArgs: 0 + }; + }), _("\\@firstoftwo", function(f) { + var e = f.consumeArgs(2); + return { + tokens: e[0], + numArgs: 0 + }; + }), _("\\@secondoftwo", function(f) { + var e = f.consumeArgs(2); + return { + tokens: e[1], + numArgs: 0 + }; + }), _("\\@ifnextchar", function(f) { + var e = f.consumeArgs(3); + f.consumeSpaces(); + var t = f.future(); + return e[0].length === 1 && e[0][0].text === t.text ? { + tokens: e[1], + numArgs: 0 + } : { + tokens: e[2], + numArgs: 0 + }; + }), _("\\@ifstar", "\\@ifnextchar *{\\@firstoftwo{#1}}"), _("\\TextOrMath", function(f) { + var e = f.consumeArgs(2); + return f.mode === "text" ? { + tokens: e[0], + numArgs: 0 + } : { + tokens: e[1], + numArgs: 0 + }; + }); + var gl = { + 0: 0, + 1: 1, + 2: 2, + 3: 3, + 4: 4, + 5: 5, + 6: 6, + 7: 7, + 8: 8, + 9: 9, + a: 10, + A: 10, + b: 11, + B: 11, + c: 12, + C: 12, + d: 13, + D: 13, + e: 14, + E: 14, + f: 15, + F: 15 + }; + _("\\char", function(f) { + var e = f.popToken(), t, n = ""; + if (e.text === "'") + t = 8, e = f.popToken(); + else if (e.text === '"') + t = 16, e = f.popToken(); + else if (e.text === "`") + if (e = f.popToken(), e.text[0] === "\\") + n = e.text.charCodeAt(1); + else { + if (e.text === "EOF") + throw new u("\\char` missing argument"); + n = e.text.charCodeAt(0); + } + else + t = 10; + if (t) { + if (n = gl[e.text], n == null || n >= t) + throw new u("Invalid base-" + t + " digit " + e.text); + for (var l; (l = gl[f.future().text]) != null && l < t; ) + n *= t, n += l, f.popToken(); + } + return "\\@char{" + n + "}"; + }); + var wa = function(e, t, n) { + var l = e.consumeArg().tokens; + if (l.length !== 1) + throw new u("\\newcommand's first argument must be a macro name"); + var c = l[0].text, m = e.isDefined(c); + if (m && !t) + throw new u("\\newcommand{" + c + "} attempting to redefine " + (c + "; use \\renewcommand")); + if (!m && !n) + throw new u("\\renewcommand{" + c + "} when command " + c + " does not yet exist; use \\newcommand"); + var b = 0; + if (l = e.consumeArg().tokens, l.length === 1 && l[0].text === "[") { + for (var k = "", x = e.expandNextToken(); x.text !== "]" && x.text !== "EOF"; ) + k += x.text, x = e.expandNextToken(); + if (!k.match(/^\s*[0-9]+\s*$/)) + throw new u("Invalid number of arguments: " + k); + b = parseInt(k), l = e.consumeArg().tokens; + } + return e.macros.set(c, { + tokens: l, + numArgs: b + }), ""; + }; + _("\\newcommand", function(f) { + return wa(f, !1, !0); + }), _("\\renewcommand", function(f) { + return wa(f, !0, !1); + }), _("\\providecommand", function(f) { + return wa(f, !0, !0); + }), _("\\message", function(f) { + var e = f.consumeArgs(1)[0]; + return console.log(e.reverse().map(function(t) { + return t.text; + }).join("")), ""; + }), _("\\errmessage", function(f) { + var e = f.consumeArgs(1)[0]; + return console.error(e.reverse().map(function(t) { + return t.text; + }).join("")), ""; + }), _("\\show", function(f) { + var e = f.popToken(), t = e.text; + return console.log(e, f.macros.get(t), E0[t], Ve.math[t], Ve.text[t]), ""; + }), _("\\bgroup", "{"), _("\\egroup", "}"), _("~", "\\nobreakspace"), _("\\lq", "`"), _("\\rq", "'"), _("\\aa", "\\r a"), _("\\AA", "\\r A"), _("\\textcopyright", "\\html@mathml{\\textcircled{c}}{\\char`©}"), _("\\copyright", "\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}"), _("\\textregistered", "\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}"), _("ℬ", "\\mathscr{B}"), _("ℰ", "\\mathscr{E}"), _("ℱ", "\\mathscr{F}"), _("ℋ", "\\mathscr{H}"), _("ℐ", "\\mathscr{I}"), _("ℒ", "\\mathscr{L}"), _("ℳ", "\\mathscr{M}"), _("ℛ", "\\mathscr{R}"), _("ℭ", "\\mathfrak{C}"), _("ℌ", "\\mathfrak{H}"), _("ℨ", "\\mathfrak{Z}"), _("\\Bbbk", "\\Bbb{k}"), _("·", "\\cdotp"), _("\\llap", "\\mathllap{\\textrm{#1}}"), _("\\rlap", "\\mathrlap{\\textrm{#1}}"), _("\\clap", "\\mathclap{\\textrm{#1}}"), _("\\mathstrut", "\\vphantom{(}"), _("\\underbar", "\\underline{\\text{#1}}"), _("\\not", '\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}'), _("\\neq", "\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}"), _("\\ne", "\\neq"), _("≠", "\\neq"), _("\\notin", "\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}"), _("∉", "\\notin"), _("≘", "\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}"), _("≙", "\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}"), _("≚", "\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}"), _("≛", "\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}"), _("≝", "\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}"), _("≞", "\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}"), _("≟", "\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}"), _("⟂", "\\perp"), _("‼", "\\mathclose{!\\mkern-0.8mu!}"), _("∌", "\\notni"), _("⌜", "\\ulcorner"), _("⌝", "\\urcorner"), _("⌞", "\\llcorner"), _("⌟", "\\lrcorner"), _("©", "\\copyright"), _("®", "\\textregistered"), _("️", "\\textregistered"), _("\\ulcorner", '\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}'), _("\\urcorner", '\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}'), _("\\llcorner", '\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}'), _("\\lrcorner", '\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}'), _("\\vdots", "\\mathord{\\varvdots\\rule{0pt}{15pt}}"), _("⋮", "\\vdots"), _("\\varGamma", "\\mathit{\\Gamma}"), _("\\varDelta", "\\mathit{\\Delta}"), _("\\varTheta", "\\mathit{\\Theta}"), _("\\varLambda", "\\mathit{\\Lambda}"), _("\\varXi", "\\mathit{\\Xi}"), _("\\varPi", "\\mathit{\\Pi}"), _("\\varSigma", "\\mathit{\\Sigma}"), _("\\varUpsilon", "\\mathit{\\Upsilon}"), _("\\varPhi", "\\mathit{\\Phi}"), _("\\varPsi", "\\mathit{\\Psi}"), _("\\varOmega", "\\mathit{\\Omega}"), _("\\substack", "\\begin{subarray}{c}#1\\end{subarray}"), _("\\colon", "\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax"), _("\\boxed", "\\fbox{$\\displaystyle{#1}$}"), _("\\iff", "\\DOTSB\\;\\Longleftrightarrow\\;"), _("\\implies", "\\DOTSB\\;\\Longrightarrow\\;"), _("\\impliedby", "\\DOTSB\\;\\Longleftarrow\\;"); + var vl = { + ",": "\\dotsc", + "\\not": "\\dotsb", + // \keybin@ checks for the following: + "+": "\\dotsb", + "=": "\\dotsb", + "<": "\\dotsb", + ">": "\\dotsb", + "-": "\\dotsb", + "*": "\\dotsb", + ":": "\\dotsb", + // Symbols whose definition starts with \DOTSB: + "\\DOTSB": "\\dotsb", + "\\coprod": "\\dotsb", + "\\bigvee": "\\dotsb", + "\\bigwedge": "\\dotsb", + "\\biguplus": "\\dotsb", + "\\bigcap": "\\dotsb", + "\\bigcup": "\\dotsb", + "\\prod": "\\dotsb", + "\\sum": "\\dotsb", + "\\bigotimes": "\\dotsb", + "\\bigoplus": "\\dotsb", + "\\bigodot": "\\dotsb", + "\\bigsqcup": "\\dotsb", + "\\And": "\\dotsb", + "\\longrightarrow": "\\dotsb", + "\\Longrightarrow": "\\dotsb", + "\\longleftarrow": "\\dotsb", + "\\Longleftarrow": "\\dotsb", + "\\longleftrightarrow": "\\dotsb", + "\\Longleftrightarrow": "\\dotsb", + "\\mapsto": "\\dotsb", + "\\longmapsto": "\\dotsb", + "\\hookrightarrow": "\\dotsb", + "\\doteq": "\\dotsb", + // Symbols whose definition starts with \mathbin: + "\\mathbin": "\\dotsb", + // Symbols whose definition starts with \mathrel: + "\\mathrel": "\\dotsb", + "\\relbar": "\\dotsb", + "\\Relbar": "\\dotsb", + "\\xrightarrow": "\\dotsb", + "\\xleftarrow": "\\dotsb", + // Symbols whose definition starts with \DOTSI: + "\\DOTSI": "\\dotsi", + "\\int": "\\dotsi", + "\\oint": "\\dotsi", + "\\iint": "\\dotsi", + "\\iiint": "\\dotsi", + "\\iiiint": "\\dotsi", + "\\idotsint": "\\dotsi", + // Symbols whose definition starts with \DOTSX: + "\\DOTSX": "\\dotsx" + }; + _("\\dots", function(f) { + var e = "\\dotso", t = f.expandAfterFuture().text; + return t in vl ? e = vl[t] : (t.slice(0, 4) === "\\not" || t in Ve.math && V.contains(["bin", "rel"], Ve.math[t].group)) && (e = "\\dotsb"), e; + }); + var ka = { + // \rightdelim@ checks for the following: + ")": !0, + "]": !0, + "\\rbrack": !0, + "\\}": !0, + "\\rbrace": !0, + "\\rangle": !0, + "\\rceil": !0, + "\\rfloor": !0, + "\\rgroup": !0, + "\\rmoustache": !0, + "\\right": !0, + "\\bigr": !0, + "\\biggr": !0, + "\\Bigr": !0, + "\\Biggr": !0, + // \extra@ also tests for the following: + $: !0, + // \extrap@ checks for the following: + ";": !0, + ".": !0, + ",": !0 + }; + _("\\dotso", function(f) { + var e = f.future().text; + return e in ka ? "\\ldots\\," : "\\ldots"; + }), _("\\dotsc", function(f) { + var e = f.future().text; + return e in ka && e !== "," ? "\\ldots\\," : "\\ldots"; + }), _("\\cdots", function(f) { + var e = f.future().text; + return e in ka ? "\\@cdots\\," : "\\@cdots"; + }), _("\\dotsb", "\\cdots"), _("\\dotsm", "\\cdots"), _("\\dotsi", "\\!\\cdots"), _("\\dotsx", "\\ldots\\,"), _("\\DOTSI", "\\relax"), _("\\DOTSB", "\\relax"), _("\\DOTSX", "\\relax"), _("\\tmspace", "\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax"), _("\\,", "\\tmspace+{3mu}{.1667em}"), _("\\thinspace", "\\,"), _("\\>", "\\mskip{4mu}"), _("\\:", "\\tmspace+{4mu}{.2222em}"), _("\\medspace", "\\:"), _("\\;", "\\tmspace+{5mu}{.2777em}"), _("\\thickspace", "\\;"), _("\\!", "\\tmspace-{3mu}{.1667em}"), _("\\negthinspace", "\\!"), _("\\negmedspace", "\\tmspace-{4mu}{.2222em}"), _("\\negthickspace", "\\tmspace-{5mu}{.277em}"), _("\\enspace", "\\kern.5em "), _("\\enskip", "\\hskip.5em\\relax"), _("\\quad", "\\hskip1em\\relax"), _("\\qquad", "\\hskip2em\\relax"), _("\\tag", "\\@ifstar\\tag@literal\\tag@paren"), _("\\tag@paren", "\\tag@literal{({#1})}"), _("\\tag@literal", function(f) { + if (f.macros.get("\\df@tag")) + throw new u("Multiple \\tag"); + return "\\gdef\\df@tag{\\text{#1}}"; + }), _("\\bmod", "\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}"), _("\\pod", "\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)"), _("\\pmod", "\\pod{{\\rm mod}\\mkern6mu#1}"), _("\\mod", "\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1"), _("\\newline", "\\\\\\relax"), _("\\TeX", "\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}"); + var bl = ee(Nt["Main-Regular"]["T".charCodeAt(0)][1] - 0.7 * Nt["Main-Regular"]["A".charCodeAt(0)][1]); + _("\\LaTeX", "\\textrm{\\html@mathml{" + ("L\\kern-.36em\\raisebox{" + bl + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{LaTeX}}"), _("\\KaTeX", "\\textrm{\\html@mathml{" + ("K\\kern-.17em\\raisebox{" + bl + "}{\\scriptstyle A}") + "\\kern-.15em\\TeX}{KaTeX}}"), _("\\hspace", "\\@ifstar\\@hspacer\\@hspace"), _("\\@hspace", "\\hskip #1\\relax"), _("\\@hspacer", "\\rule{0pt}{0pt}\\hskip #1\\relax"), _("\\ordinarycolon", ":"), _("\\vcentcolon", "\\mathrel{\\mathop\\ordinarycolon}"), _("\\dblcolon", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}'), _("\\coloneqq", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}'), _("\\Coloneqq", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}'), _("\\coloneq", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}'), _("\\Coloneq", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}'), _("\\eqqcolon", '\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}'), _("\\Eqqcolon", '\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}'), _("\\eqcolon", '\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}'), _("\\Eqcolon", '\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}'), _("\\colonapprox", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}'), _("\\Colonapprox", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}'), _("\\colonsim", '\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}'), _("\\Colonsim", '\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}'), _("∷", "\\dblcolon"), _("∹", "\\eqcolon"), _("≔", "\\coloneqq"), _("≕", "\\eqqcolon"), _("⩴", "\\Coloneqq"), _("\\ratio", "\\vcentcolon"), _("\\coloncolon", "\\dblcolon"), _("\\colonequals", "\\coloneqq"), _("\\coloncolonequals", "\\Coloneqq"), _("\\equalscolon", "\\eqqcolon"), _("\\equalscoloncolon", "\\Eqqcolon"), _("\\colonminus", "\\coloneq"), _("\\coloncolonminus", "\\Coloneq"), _("\\minuscolon", "\\eqcolon"), _("\\minuscoloncolon", "\\Eqcolon"), _("\\coloncolonapprox", "\\Colonapprox"), _("\\coloncolonsim", "\\Colonsim"), _("\\simcolon", "\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}"), _("\\simcoloncolon", "\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}"), _("\\approxcolon", "\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}"), _("\\approxcoloncolon", "\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}"), _("\\notni", "\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}"), _("\\limsup", "\\DOTSB\\operatorname*{lim\\,sup}"), _("\\liminf", "\\DOTSB\\operatorname*{lim\\,inf}"), _("\\injlim", "\\DOTSB\\operatorname*{inj\\,lim}"), _("\\projlim", "\\DOTSB\\operatorname*{proj\\,lim}"), _("\\varlimsup", "\\DOTSB\\operatorname*{\\overline{lim}}"), _("\\varliminf", "\\DOTSB\\operatorname*{\\underline{lim}}"), _("\\varinjlim", "\\DOTSB\\operatorname*{\\underrightarrow{lim}}"), _("\\varprojlim", "\\DOTSB\\operatorname*{\\underleftarrow{lim}}"), _("\\gvertneqq", "\\html@mathml{\\@gvertneqq}{≩}"), _("\\lvertneqq", "\\html@mathml{\\@lvertneqq}{≨}"), _("\\ngeqq", "\\html@mathml{\\@ngeqq}{≱}"), _("\\ngeqslant", "\\html@mathml{\\@ngeqslant}{≱}"), _("\\nleqq", "\\html@mathml{\\@nleqq}{≰}"), _("\\nleqslant", "\\html@mathml{\\@nleqslant}{≰}"), _("\\nshortmid", "\\html@mathml{\\@nshortmid}{∤}"), _("\\nshortparallel", "\\html@mathml{\\@nshortparallel}{∦}"), _("\\nsubseteqq", "\\html@mathml{\\@nsubseteqq}{⊈}"), _("\\nsupseteqq", "\\html@mathml{\\@nsupseteqq}{⊉}"), _("\\varsubsetneq", "\\html@mathml{\\@varsubsetneq}{⊊}"), _("\\varsubsetneqq", "\\html@mathml{\\@varsubsetneqq}{⫋}"), _("\\varsupsetneq", "\\html@mathml{\\@varsupsetneq}{⊋}"), _("\\varsupsetneqq", "\\html@mathml{\\@varsupsetneqq}{⫌}"), _("\\imath", "\\html@mathml{\\@imath}{ı}"), _("\\jmath", "\\html@mathml{\\@jmath}{ȷ}"), _("\\llbracket", "\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}"), _("\\rrbracket", "\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}"), _("⟦", "\\llbracket"), _("⟧", "\\rrbracket"), _("\\lBrace", "\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}"), _("\\rBrace", "\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}"), _("⦃", "\\lBrace"), _("⦄", "\\rBrace"), _("\\minuso", "\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}"), _("⦵", "\\minuso"), _("\\darr", "\\downarrow"), _("\\dArr", "\\Downarrow"), _("\\Darr", "\\Downarrow"), _("\\lang", "\\langle"), _("\\rang", "\\rangle"), _("\\uarr", "\\uparrow"), _("\\uArr", "\\Uparrow"), _("\\Uarr", "\\Uparrow"), _("\\N", "\\mathbb{N}"), _("\\R", "\\mathbb{R}"), _("\\Z", "\\mathbb{Z}"), _("\\alef", "\\aleph"), _("\\alefsym", "\\aleph"), _("\\Alpha", "\\mathrm{A}"), _("\\Beta", "\\mathrm{B}"), _("\\bull", "\\bullet"), _("\\Chi", "\\mathrm{X}"), _("\\clubs", "\\clubsuit"), _("\\cnums", "\\mathbb{C}"), _("\\Complex", "\\mathbb{C}"), _("\\Dagger", "\\ddagger"), _("\\diamonds", "\\diamondsuit"), _("\\empty", "\\emptyset"), _("\\Epsilon", "\\mathrm{E}"), _("\\Eta", "\\mathrm{H}"), _("\\exist", "\\exists"), _("\\harr", "\\leftrightarrow"), _("\\hArr", "\\Leftrightarrow"), _("\\Harr", "\\Leftrightarrow"), _("\\hearts", "\\heartsuit"), _("\\image", "\\Im"), _("\\infin", "\\infty"), _("\\Iota", "\\mathrm{I}"), _("\\isin", "\\in"), _("\\Kappa", "\\mathrm{K}"), _("\\larr", "\\leftarrow"), _("\\lArr", "\\Leftarrow"), _("\\Larr", "\\Leftarrow"), _("\\lrarr", "\\leftrightarrow"), _("\\lrArr", "\\Leftrightarrow"), _("\\Lrarr", "\\Leftrightarrow"), _("\\Mu", "\\mathrm{M}"), _("\\natnums", "\\mathbb{N}"), _("\\Nu", "\\mathrm{N}"), _("\\Omicron", "\\mathrm{O}"), _("\\plusmn", "\\pm"), _("\\rarr", "\\rightarrow"), _("\\rArr", "\\Rightarrow"), _("\\Rarr", "\\Rightarrow"), _("\\real", "\\Re"), _("\\reals", "\\mathbb{R}"), _("\\Reals", "\\mathbb{R}"), _("\\Rho", "\\mathrm{P}"), _("\\sdot", "\\cdot"), _("\\sect", "\\S"), _("\\spades", "\\spadesuit"), _("\\sub", "\\subset"), _("\\sube", "\\subseteq"), _("\\supe", "\\supseteq"), _("\\Tau", "\\mathrm{T}"), _("\\thetasym", "\\vartheta"), _("\\weierp", "\\wp"), _("\\Zeta", "\\mathrm{Z}"), _("\\argmin", "\\DOTSB\\operatorname*{arg\\,min}"), _("\\argmax", "\\DOTSB\\operatorname*{arg\\,max}"), _("\\plim", "\\DOTSB\\mathop{\\operatorname{plim}}\\limits"), _("\\bra", "\\mathinner{\\langle{#1}|}"), _("\\ket", "\\mathinner{|{#1}\\rangle}"), _("\\braket", "\\mathinner{\\langle{#1}\\rangle}"), _("\\Bra", "\\left\\langle#1\\right|"), _("\\Ket", "\\left|#1\\right\\rangle"); + var yl = function(e) { + return function(t) { + var n = t.consumeArg().tokens, l = t.consumeArg().tokens, c = t.consumeArg().tokens, m = t.consumeArg().tokens, b = t.macros.get("|"), k = t.macros.get("\\|"); + t.macros.beginGroup(); + var x = function(q) { + return function(U) { + e && (U.macros.set("|", b), c.length && U.macros.set("\\|", k)); + var $ = q; + if (!q && c.length) { + var ie = U.future(); + ie.text === "|" && (U.popToken(), $ = !0); + } + return { + tokens: $ ? c : l, + numArgs: 0 + }; + }; + }; + t.macros.set("|", x(!1)), c.length && t.macros.set("\\|", x(!0)); + var C = t.consumeArg().tokens, D = t.expandTokens([].concat(m, C, n)); + return t.macros.endGroup(), { + tokens: D.reverse(), + numArgs: 0 + }; + }; + }; + _("\\bra@ket", yl(!1)), _("\\bra@set", yl(!0)), _("\\Braket", "\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}"), _("\\Set", "\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}"), _("\\set", "\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}"), _("\\angln", "{\\angl n}"), _("\\blue", "\\textcolor{##6495ed}{#1}"), _("\\orange", "\\textcolor{##ffa500}{#1}"), _("\\pink", "\\textcolor{##ff00af}{#1}"), _("\\red", "\\textcolor{##df0030}{#1}"), _("\\green", "\\textcolor{##28ae7b}{#1}"), _("\\gray", "\\textcolor{gray}{#1}"), _("\\purple", "\\textcolor{##9d38bd}{#1}"), _("\\blueA", "\\textcolor{##ccfaff}{#1}"), _("\\blueB", "\\textcolor{##80f6ff}{#1}"), _("\\blueC", "\\textcolor{##63d9ea}{#1}"), _("\\blueD", "\\textcolor{##11accd}{#1}"), _("\\blueE", "\\textcolor{##0c7f99}{#1}"), _("\\tealA", "\\textcolor{##94fff5}{#1}"), _("\\tealB", "\\textcolor{##26edd5}{#1}"), _("\\tealC", "\\textcolor{##01d1c1}{#1}"), _("\\tealD", "\\textcolor{##01a995}{#1}"), _("\\tealE", "\\textcolor{##208170}{#1}"), _("\\greenA", "\\textcolor{##b6ffb0}{#1}"), _("\\greenB", "\\textcolor{##8af281}{#1}"), _("\\greenC", "\\textcolor{##74cf70}{#1}"), _("\\greenD", "\\textcolor{##1fab54}{#1}"), _("\\greenE", "\\textcolor{##0d923f}{#1}"), _("\\goldA", "\\textcolor{##ffd0a9}{#1}"), _("\\goldB", "\\textcolor{##ffbb71}{#1}"), _("\\goldC", "\\textcolor{##ff9c39}{#1}"), _("\\goldD", "\\textcolor{##e07d10}{#1}"), _("\\goldE", "\\textcolor{##a75a05}{#1}"), _("\\redA", "\\textcolor{##fca9a9}{#1}"), _("\\redB", "\\textcolor{##ff8482}{#1}"), _("\\redC", "\\textcolor{##f9685d}{#1}"), _("\\redD", "\\textcolor{##e84d39}{#1}"), _("\\redE", "\\textcolor{##bc2612}{#1}"), _("\\maroonA", "\\textcolor{##ffbde0}{#1}"), _("\\maroonB", "\\textcolor{##ff92c6}{#1}"), _("\\maroonC", "\\textcolor{##ed5fa6}{#1}"), _("\\maroonD", "\\textcolor{##ca337c}{#1}"), _("\\maroonE", "\\textcolor{##9e034e}{#1}"), _("\\purpleA", "\\textcolor{##ddd7ff}{#1}"), _("\\purpleB", "\\textcolor{##c6b9fc}{#1}"), _("\\purpleC", "\\textcolor{##aa87ff}{#1}"), _("\\purpleD", "\\textcolor{##7854ab}{#1}"), _("\\purpleE", "\\textcolor{##543b78}{#1}"), _("\\mintA", "\\textcolor{##f5f9e8}{#1}"), _("\\mintB", "\\textcolor{##edf2df}{#1}"), _("\\mintC", "\\textcolor{##e0e5cc}{#1}"), _("\\grayA", "\\textcolor{##f6f7f7}{#1}"), _("\\grayB", "\\textcolor{##f0f1f2}{#1}"), _("\\grayC", "\\textcolor{##e3e5e6}{#1}"), _("\\grayD", "\\textcolor{##d6d8da}{#1}"), _("\\grayE", "\\textcolor{##babec2}{#1}"), _("\\grayF", "\\textcolor{##888d93}{#1}"), _("\\grayG", "\\textcolor{##626569}{#1}"), _("\\grayH", "\\textcolor{##3b3e40}{#1}"), _("\\grayI", "\\textcolor{##21242c}{#1}"), _("\\kaBlue", "\\textcolor{##314453}{#1}"), _("\\kaGreen", "\\textcolor{##71B307}{#1}"); + var wl = { + "^": !0, + // Parser.js + _: !0, + // Parser.js + "\\limits": !0, + // Parser.js + "\\nolimits": !0 + // Parser.js + }, nu = /* @__PURE__ */ function() { + function f(t, n, l) { + this.settings = void 0, this.expansionCount = void 0, this.lexer = void 0, this.macros = void 0, this.stack = void 0, this.mode = void 0, this.settings = n, this.expansionCount = 0, this.feed(t), this.macros = new eu(ru, n.macros), this.mode = l, this.stack = []; + } + var e = f.prototype; + return e.feed = function(n) { + this.lexer = new pl(n, this.settings); + }, e.switchMode = function(n) { + this.mode = n; + }, e.beginGroup = function() { + this.macros.beginGroup(); + }, e.endGroup = function() { + this.macros.endGroup(); + }, e.endGroups = function() { + this.macros.endGroups(); + }, e.future = function() { + return this.stack.length === 0 && this.pushToken(this.lexer.lex()), this.stack[this.stack.length - 1]; + }, e.popToken = function() { + return this.future(), this.stack.pop(); + }, e.pushToken = function(n) { + this.stack.push(n); + }, e.pushTokens = function(n) { + var l; + (l = this.stack).push.apply(l, n); + }, e.scanArgument = function(n) { + var l, c, m; + if (n) { + if (this.consumeSpaces(), this.future().text !== "[") + return null; + l = this.popToken(); + var b = this.consumeArg(["]"]); + m = b.tokens, c = b.end; + } else { + var k = this.consumeArg(); + m = k.tokens, l = k.start, c = k.end; + } + return this.pushToken(new z0("EOF", c.loc)), this.pushTokens(m), l.range(c, ""); + }, e.consumeSpaces = function() { + for (; ; ) { + var n = this.future(); + if (n.text === " ") + this.stack.pop(); + else + break; + } + }, e.consumeArg = function(n) { + var l = [], c = n && n.length > 0; + c || this.consumeSpaces(); + var m = this.future(), b, k = 0, x = 0; + do { + if (b = this.popToken(), l.push(b), b.text === "{") + ++k; + else if (b.text === "}") { + if (--k, k === -1) + throw new u("Extra }", b); + } else if (b.text === "EOF") + throw new u("Unexpected end of input in a macro argument, expected '" + (n && c ? n[x] : "}") + "'", b); + if (n && c) + if ((k === 0 || k === 1 && n[x] === "{") && b.text === n[x]) { + if (++x, x === n.length) { + l.splice(-x, x); + break; + } + } else + x = 0; + } while (k !== 0 || c); + return m.text === "{" && l[l.length - 1].text === "}" && (l.pop(), l.shift()), l.reverse(), { + tokens: l, + start: m, + end: b + }; + }, e.consumeArgs = function(n, l) { + if (l) { + if (l.length !== n + 1) + throw new u("The length of delimiters doesn't match the number of args!"); + for (var c = l[0], m = 0; m < c.length; m++) { + var b = this.popToken(); + if (c[m] !== b.text) + throw new u("Use of the macro doesn't match its definition", b); + } + } + for (var k = [], x = 0; x < n; x++) + k.push(this.consumeArg(l && l[x + 1]).tokens); + return k; + }, e.expandOnce = function(n) { + var l = this.popToken(), c = l.text, m = l.noexpand ? null : this._getExpansion(c); + if (m == null || n && m.unexpandable) { + if (n && m == null && c[0] === "\\" && !this.isDefined(c)) + throw new u("Undefined control sequence: " + c); + return this.pushToken(l), !1; + } + if (this.expansionCount++, this.expansionCount > this.settings.maxExpand) + throw new u("Too many expansions: infinite loop or need to increase maxExpand setting"); + var b = m.tokens, k = this.consumeArgs(m.numArgs, m.delimiters); + if (m.numArgs) { + b = b.slice(); + for (var x = b.length - 1; x >= 0; --x) { + var C = b[x]; + if (C.text === "#") { + if (x === 0) + throw new u("Incomplete placeholder at end of macro body", C); + if (C = b[--x], C.text === "#") + b.splice(x + 1, 1); + else if (/^[1-9]$/.test(C.text)) { + var D; + (D = b).splice.apply(D, [x, 2].concat(k[+C.text - 1])); + } else + throw new u("Not a valid argument number", C); + } + } + } + return this.pushTokens(b), b.length; + }, e.expandAfterFuture = function() { + return this.expandOnce(), this.future(); + }, e.expandNextToken = function() { + for (; ; ) + if (this.expandOnce() === !1) { + var n = this.stack.pop(); + return n.treatAsRelax && (n.text = "\\relax"), n; + } + throw new Error(); + }, e.expandMacro = function(n) { + return this.macros.has(n) ? this.expandTokens([new z0(n)]) : void 0; + }, e.expandTokens = function(n) { + var l = [], c = this.stack.length; + for (this.pushTokens(n); this.stack.length > c; ) + if (this.expandOnce(!0) === !1) { + var m = this.stack.pop(); + m.treatAsRelax && (m.noexpand = !1, m.treatAsRelax = !1), l.push(m); + } + return l; + }, e.expandMacroAsText = function(n) { + var l = this.expandMacro(n); + return l && l.map(function(c) { + return c.text; + }).join(""); + }, e._getExpansion = function(n) { + var l = this.macros.get(n); + if (l == null) + return l; + if (n.length === 1) { + var c = this.lexer.catcodes[n]; + if (c != null && c !== 13) + return; + } + var m = typeof l == "function" ? l(this) : l; + if (typeof m == "string") { + var b = 0; + if (m.indexOf("#") !== -1) + for (var k = m.replace(/##/g, ""); k.indexOf("#" + (b + 1)) !== -1; ) + ++b; + for (var x = new pl(m, this.settings), C = [], D = x.lex(); D.text !== "EOF"; ) + C.push(D), D = x.lex(); + C.reverse(); + var P = { + tokens: C, + numArgs: b + }; + return P; + } + return m; + }, e.isDefined = function(n) { + return this.macros.has(n) || E0.hasOwnProperty(n) || Ve.math.hasOwnProperty(n) || Ve.text.hasOwnProperty(n) || wl.hasOwnProperty(n); + }, e.isExpandable = function(n) { + var l = this.macros.get(n); + return l != null ? typeof l == "string" || typeof l == "function" || !l.unexpandable : E0.hasOwnProperty(n) && !E0[n].primitive; + }, f; + }(), kl = /^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/, mn = Object.freeze({ + "₊": "+", + "₋": "-", + "₌": "=", + "₍": "(", + "₎": ")", + "₀": "0", + "₁": "1", + "₂": "2", + "₃": "3", + "₄": "4", + "₅": "5", + "₆": "6", + "₇": "7", + "₈": "8", + "₉": "9", + "ₐ": "a", + "ₑ": "e", + "ₕ": "h", + "ᵢ": "i", + "ⱼ": "j", + "ₖ": "k", + "ₗ": "l", + "ₘ": "m", + "ₙ": "n", + "ₒ": "o", + "ₚ": "p", + "ᵣ": "r", + "ₛ": "s", + "ₜ": "t", + "ᵤ": "u", + "ᵥ": "v", + "ₓ": "x", + "ᵦ": "β", + "ᵧ": "γ", + "ᵨ": "ρ", + "ᵩ": "ϕ", + "ᵪ": "χ", + "⁺": "+", + "⁻": "-", + "⁼": "=", + "⁽": "(", + "⁾": ")", + "⁰": "0", + "¹": "1", + "²": "2", + "³": "3", + "⁴": "4", + "⁵": "5", + "⁶": "6", + "⁷": "7", + "⁸": "8", + "⁹": "9", + "ᴬ": "A", + "ᴮ": "B", + "ᴰ": "D", + "ᴱ": "E", + "ᴳ": "G", + "ᴴ": "H", + "ᴵ": "I", + "ᴶ": "J", + "ᴷ": "K", + "ᴸ": "L", + "ᴹ": "M", + "ᴺ": "N", + "ᴼ": "O", + "ᴾ": "P", + "ᴿ": "R", + "ᵀ": "T", + "ᵁ": "U", + "ⱽ": "V", + "ᵂ": "W", + "ᵃ": "a", + "ᵇ": "b", + "ᶜ": "c", + "ᵈ": "d", + "ᵉ": "e", + "ᶠ": "f", + "ᵍ": "g", + ʰ: "h", + "ⁱ": "i", + ʲ: "j", + "ᵏ": "k", + ˡ: "l", + "ᵐ": "m", + ⁿ: "n", + "ᵒ": "o", + "ᵖ": "p", + ʳ: "r", + ˢ: "s", + "ᵗ": "t", + "ᵘ": "u", + "ᵛ": "v", + ʷ: "w", + ˣ: "x", + ʸ: "y", + "ᶻ": "z", + "ᵝ": "β", + "ᵞ": "γ", + "ᵟ": "δ", + "ᵠ": "ϕ", + "ᵡ": "χ", + "ᶿ": "θ" + }), _a = { + "́": { + text: "\\'", + math: "\\acute" + }, + "̀": { + text: "\\`", + math: "\\grave" + }, + "̈": { + text: '\\"', + math: "\\ddot" + }, + "̃": { + text: "\\~", + math: "\\tilde" + }, + "̄": { + text: "\\=", + math: "\\bar" + }, + "̆": { + text: "\\u", + math: "\\breve" + }, + "̌": { + text: "\\v", + math: "\\check" + }, + "̂": { + text: "\\^", + math: "\\hat" + }, + "̇": { + text: "\\.", + math: "\\dot" + }, + "̊": { + text: "\\r", + math: "\\mathring" + }, + "̋": { + text: "\\H" + }, + "̧": { + text: "\\c" + } + }, _l = { + á: "á", + à: "à", + ä: "ä", + ǟ: "ǟ", + ã: "ã", + ā: "ā", + ă: "ă", + ắ: "ắ", + ằ: "ằ", + ẵ: "ẵ", + ǎ: "ǎ", + â: "â", + ấ: "ấ", + ầ: "ầ", + ẫ: "ẫ", + ȧ: "ȧ", + ǡ: "ǡ", + å: "å", + ǻ: "ǻ", + ḃ: "ḃ", + ć: "ć", + ḉ: "ḉ", + č: "č", + ĉ: "ĉ", + ċ: "ċ", + ç: "ç", + ď: "ď", + ḋ: "ḋ", + ḑ: "ḑ", + é: "é", + è: "è", + ë: "ë", + ẽ: "ẽ", + ē: "ē", + ḗ: "ḗ", + ḕ: "ḕ", + ĕ: "ĕ", + ḝ: "ḝ", + ě: "ě", + ê: "ê", + ế: "ế", + ề: "ề", + ễ: "ễ", + ė: "ė", + ȩ: "ȩ", + ḟ: "ḟ", + ǵ: "ǵ", + ḡ: "ḡ", + ğ: "ğ", + ǧ: "ǧ", + ĝ: "ĝ", + ġ: "ġ", + ģ: "ģ", + ḧ: "ḧ", + ȟ: "ȟ", + ĥ: "ĥ", + ḣ: "ḣ", + ḩ: "ḩ", + í: "í", + ì: "ì", + ï: "ï", + ḯ: "ḯ", + ĩ: "ĩ", + ī: "ī", + ĭ: "ĭ", + ǐ: "ǐ", + î: "î", + ǰ: "ǰ", + ĵ: "ĵ", + ḱ: "ḱ", + ǩ: "ǩ", + ķ: "ķ", + ĺ: "ĺ", + ľ: "ľ", + ļ: "ļ", + ḿ: "ḿ", + ṁ: "ṁ", + ń: "ń", + ǹ: "ǹ", + ñ: "ñ", + ň: "ň", + ṅ: "ṅ", + ņ: "ņ", + ó: "ó", + ò: "ò", + ö: "ö", + ȫ: "ȫ", + õ: "õ", + ṍ: "ṍ", + ṏ: "ṏ", + ȭ: "ȭ", + ō: "ō", + ṓ: "ṓ", + ṑ: "ṑ", + ŏ: "ŏ", + ǒ: "ǒ", + ô: "ô", + ố: "ố", + ồ: "ồ", + ỗ: "ỗ", + ȯ: "ȯ", + ȱ: "ȱ", + ő: "ő", + ṕ: "ṕ", + ṗ: "ṗ", + ŕ: "ŕ", + ř: "ř", + ṙ: "ṙ", + ŗ: "ŗ", + ś: "ś", + ṥ: "ṥ", + š: "š", + ṧ: "ṧ", + ŝ: "ŝ", + ṡ: "ṡ", + ş: "ş", + ẗ: "ẗ", + ť: "ť", + ṫ: "ṫ", + ţ: "ţ", + ú: "ú", + ù: "ù", + ü: "ü", + ǘ: "ǘ", + ǜ: "ǜ", + ǖ: "ǖ", + ǚ: "ǚ", + ũ: "ũ", + ṹ: "ṹ", + ū: "ū", + ṻ: "ṻ", + ŭ: "ŭ", + ǔ: "ǔ", + û: "û", + ů: "ů", + ű: "ű", + ṽ: "ṽ", + ẃ: "ẃ", + ẁ: "ẁ", + ẅ: "ẅ", + ŵ: "ŵ", + ẇ: "ẇ", + ẘ: "ẘ", + ẍ: "ẍ", + ẋ: "ẋ", + ý: "ý", + ỳ: "ỳ", + ÿ: "ÿ", + ỹ: "ỹ", + ȳ: "ȳ", + ŷ: "ŷ", + ẏ: "ẏ", + ẙ: "ẙ", + ź: "ź", + ž: "ž", + ẑ: "ẑ", + ż: "ż", + Á: "Á", + À: "À", + Ä: "Ä", + Ǟ: "Ǟ", + Ã: "Ã", + Ā: "Ā", + Ă: "Ă", + Ắ: "Ắ", + Ằ: "Ằ", + Ẵ: "Ẵ", + Ǎ: "Ǎ", + Â: "Â", + Ấ: "Ấ", + Ầ: "Ầ", + Ẫ: "Ẫ", + Ȧ: "Ȧ", + Ǡ: "Ǡ", + Å: "Å", + Ǻ: "Ǻ", + Ḃ: "Ḃ", + Ć: "Ć", + Ḉ: "Ḉ", + Č: "Č", + Ĉ: "Ĉ", + Ċ: "Ċ", + Ç: "Ç", + Ď: "Ď", + Ḋ: "Ḋ", + Ḑ: "Ḑ", + É: "É", + È: "È", + Ë: "Ë", + Ẽ: "Ẽ", + Ē: "Ē", + Ḗ: "Ḗ", + Ḕ: "Ḕ", + Ĕ: "Ĕ", + Ḝ: "Ḝ", + Ě: "Ě", + Ê: "Ê", + Ế: "Ế", + Ề: "Ề", + Ễ: "Ễ", + Ė: "Ė", + Ȩ: "Ȩ", + Ḟ: "Ḟ", + Ǵ: "Ǵ", + Ḡ: "Ḡ", + Ğ: "Ğ", + Ǧ: "Ǧ", + Ĝ: "Ĝ", + Ġ: "Ġ", + Ģ: "Ģ", + Ḧ: "Ḧ", + Ȟ: "Ȟ", + Ĥ: "Ĥ", + Ḣ: "Ḣ", + Ḩ: "Ḩ", + Í: "Í", + Ì: "Ì", + Ï: "Ï", + Ḯ: "Ḯ", + Ĩ: "Ĩ", + Ī: "Ī", + Ĭ: "Ĭ", + Ǐ: "Ǐ", + Î: "Î", + İ: "İ", + Ĵ: "Ĵ", + Ḱ: "Ḱ", + Ǩ: "Ǩ", + Ķ: "Ķ", + Ĺ: "Ĺ", + Ľ: "Ľ", + Ļ: "Ļ", + Ḿ: "Ḿ", + Ṁ: "Ṁ", + Ń: "Ń", + Ǹ: "Ǹ", + Ñ: "Ñ", + Ň: "Ň", + Ṅ: "Ṅ", + Ņ: "Ņ", + Ó: "Ó", + Ò: "Ò", + Ö: "Ö", + Ȫ: "Ȫ", + Õ: "Õ", + Ṍ: "Ṍ", + Ṏ: "Ṏ", + Ȭ: "Ȭ", + Ō: "Ō", + Ṓ: "Ṓ", + Ṑ: "Ṑ", + Ŏ: "Ŏ", + Ǒ: "Ǒ", + Ô: "Ô", + Ố: "Ố", + Ồ: "Ồ", + Ỗ: "Ỗ", + Ȯ: "Ȯ", + Ȱ: "Ȱ", + Ő: "Ő", + Ṕ: "Ṕ", + Ṗ: "Ṗ", + Ŕ: "Ŕ", + Ř: "Ř", + Ṙ: "Ṙ", + Ŗ: "Ŗ", + Ś: "Ś", + Ṥ: "Ṥ", + Š: "Š", + Ṧ: "Ṧ", + Ŝ: "Ŝ", + Ṡ: "Ṡ", + Ş: "Ş", + Ť: "Ť", + Ṫ: "Ṫ", + Ţ: "Ţ", + Ú: "Ú", + Ù: "Ù", + Ü: "Ü", + Ǘ: "Ǘ", + Ǜ: "Ǜ", + Ǖ: "Ǖ", + Ǚ: "Ǚ", + Ũ: "Ũ", + Ṹ: "Ṹ", + Ū: "Ū", + Ṻ: "Ṻ", + Ŭ: "Ŭ", + Ǔ: "Ǔ", + Û: "Û", + Ů: "Ů", + Ű: "Ű", + Ṽ: "Ṽ", + Ẃ: "Ẃ", + Ẁ: "Ẁ", + Ẅ: "Ẅ", + Ŵ: "Ŵ", + Ẇ: "Ẇ", + Ẍ: "Ẍ", + Ẋ: "Ẋ", + Ý: "Ý", + Ỳ: "Ỳ", + Ÿ: "Ÿ", + Ỹ: "Ỹ", + Ȳ: "Ȳ", + Ŷ: "Ŷ", + Ẏ: "Ẏ", + Ź: "Ź", + Ž: "Ž", + Ẑ: "Ẑ", + Ż: "Ż", + ά: "ά", + ὰ: "ὰ", + ᾱ: "ᾱ", + ᾰ: "ᾰ", + έ: "έ", + ὲ: "ὲ", + ή: "ή", + ὴ: "ὴ", + ί: "ί", + ὶ: "ὶ", + ϊ: "ϊ", + ΐ: "ΐ", + ῒ: "ῒ", + ῑ: "ῑ", + ῐ: "ῐ", + ό: "ό", + ὸ: "ὸ", + ύ: "ύ", + ὺ: "ὺ", + ϋ: "ϋ", + ΰ: "ΰ", + ῢ: "ῢ", + ῡ: "ῡ", + ῠ: "ῠ", + ώ: "ώ", + ὼ: "ὼ", + Ύ: "Ύ", + Ὺ: "Ὺ", + Ϋ: "Ϋ", + Ῡ: "Ῡ", + Ῠ: "Ῠ", + Ώ: "Ώ", + Ὼ: "Ὼ" + }, xl = /* @__PURE__ */ function() { + function f(t, n) { + this.mode = void 0, this.gullet = void 0, this.settings = void 0, this.leftrightDepth = void 0, this.nextToken = void 0, this.mode = "math", this.gullet = new nu(t, n, this.mode), this.settings = n, this.leftrightDepth = 0; + } + var e = f.prototype; + return e.expect = function(n, l) { + if (l === void 0 && (l = !0), this.fetch().text !== n) + throw new u("Expected '" + n + "', got '" + this.fetch().text + "'", this.fetch()); + l && this.consume(); + }, e.consume = function() { + this.nextToken = null; + }, e.fetch = function() { + return this.nextToken == null && (this.nextToken = this.gullet.expandNextToken()), this.nextToken; + }, e.switchMode = function(n) { + this.mode = n, this.gullet.switchMode(n); + }, e.parse = function() { + this.settings.globalGroup || this.gullet.beginGroup(), this.settings.colorIsTextColor && this.gullet.macros.set("\\color", "\\textcolor"); + try { + var n = this.parseExpression(!1); + return this.expect("EOF"), this.settings.globalGroup || this.gullet.endGroup(), n; + } finally { + this.gullet.endGroups(); + } + }, e.subparse = function(n) { + var l = this.nextToken; + this.consume(), this.gullet.pushToken(new z0("}")), this.gullet.pushTokens(n); + var c = this.parseExpression(!1); + return this.expect("}"), this.nextToken = l, c; + }, e.parseExpression = function(n, l) { + for (var c = []; ; ) { + this.mode === "math" && this.consumeSpaces(); + var m = this.fetch(); + if (f.endOfExpression.indexOf(m.text) !== -1 || l && m.text === l || n && E0[m.text] && E0[m.text].infix) + break; + var b = this.parseAtom(l); + if (b) { + if (b.type === "internal") + continue; + } else + break; + c.push(b); + } + return this.mode === "text" && this.formLigatures(c), this.handleInfixNodes(c); + }, e.handleInfixNodes = function(n) { + for (var l = -1, c, m = 0; m < n.length; m++) + if (n[m].type === "infix") { + if (l !== -1) + throw new u("only one infix operator per group", n[m].token); + l = m, c = n[m].replaceWith; + } + if (l !== -1 && c) { + var b, k, x = n.slice(0, l), C = n.slice(l + 1); + x.length === 1 && x[0].type === "ordgroup" ? b = x[0] : b = { + type: "ordgroup", + mode: this.mode, + body: x + }, C.length === 1 && C[0].type === "ordgroup" ? k = C[0] : k = { + type: "ordgroup", + mode: this.mode, + body: C + }; + var D; + return c === "\\\\abovefrac" ? D = this.callFunction(c, [b, n[l], k], []) : D = this.callFunction(c, [b, k], []), [D]; + } else + return n; + }, e.handleSupSubscript = function(n) { + var l = this.fetch(), c = l.text; + this.consume(), this.consumeSpaces(); + var m = this.parseGroup(n); + if (!m) + throw new u("Expected group after '" + c + "'", l); + return m; + }, e.formatUnsupportedCmd = function(n) { + for (var l = [], c = 0; c < n.length; c++) + l.push({ + type: "textord", + mode: "text", + text: n[c] + }); + var m = { + type: "text", + mode: this.mode, + body: l + }, b = { + type: "color", + mode: this.mode, + color: this.settings.errorColor, + body: [m] + }; + return b; + }, e.parseAtom = function(n) { + var l = this.parseGroup("atom", n); + if (this.mode === "text") + return l; + for (var c, m; ; ) { + this.consumeSpaces(); + var b = this.fetch(); + if (b.text === "\\limits" || b.text === "\\nolimits") { + if (l && l.type === "op") { + var k = b.text === "\\limits"; + l.limits = k, l.alwaysHandleSupSub = !0; + } else if (l && l.type === "operatorname") + l.alwaysHandleSupSub && (l.limits = b.text === "\\limits"); + else + throw new u("Limit controls must follow a math operator", b); + this.consume(); + } else if (b.text === "^") { + if (c) + throw new u("Double superscript", b); + c = this.handleSupSubscript("superscript"); + } else if (b.text === "_") { + if (m) + throw new u("Double subscript", b); + m = this.handleSupSubscript("subscript"); + } else if (b.text === "'") { + if (c) + throw new u("Double superscript", b); + var x = { + type: "textord", + mode: this.mode, + text: "\\prime" + }, C = [x]; + for (this.consume(); this.fetch().text === "'"; ) + C.push(x), this.consume(); + this.fetch().text === "^" && C.push(this.handleSupSubscript("superscript")), c = { + type: "ordgroup", + mode: this.mode, + body: C + }; + } else if (mn[b.text]) { + var D = mn[b.text], P = kl.test(b.text); + for (this.consume(); ; ) { + var q = this.fetch().text; + if (!mn[q] || kl.test(q) !== P) + break; + this.consume(), D += mn[q]; + } + var U = new f(D, this.settings).parse(); + P ? m = { + type: "ordgroup", + mode: "math", + body: U + } : c = { + type: "ordgroup", + mode: "math", + body: U + }; + } else + break; + } + return c || m ? { + type: "supsub", + mode: this.mode, + base: l, + sup: c, + sub: m + } : l; + }, e.parseFunction = function(n, l) { + var c = this.fetch(), m = c.text, b = E0[m]; + if (!b) + return null; + if (this.consume(), l && l !== "atom" && !b.allowedInArgument) + throw new u("Got function '" + m + "' with no arguments" + (l ? " as " + l : ""), c); + if (this.mode === "text" && !b.allowedInText) + throw new u("Can't use function '" + m + "' in text mode", c); + if (this.mode === "math" && b.allowedInMath === !1) + throw new u("Can't use function '" + m + "' in math mode", c); + var k = this.parseArguments(m, b), x = k.args, C = k.optArgs; + return this.callFunction(m, x, C, c, n); + }, e.callFunction = function(n, l, c, m, b) { + var k = { + funcName: n, + parser: this, + token: m, + breakOnTokenText: b + }, x = E0[n]; + if (x && x.handler) + return x.handler(k, l, c); + throw new u("No function handler for " + n); + }, e.parseArguments = function(n, l) { + var c = l.numArgs + l.numOptionalArgs; + if (c === 0) + return { + args: [], + optArgs: [] + }; + for (var m = [], b = [], k = 0; k < c; k++) { + var x = l.argTypes && l.argTypes[k], C = k < l.numOptionalArgs; + (l.primitive && x == null || // \sqrt expands into primitive if optional argument doesn't exist + l.type === "sqrt" && k === 1 && b[0] == null) && (x = "primitive"); + var D = this.parseGroupOfType("argument to '" + n + "'", x, C); + if (C) + b.push(D); + else if (D != null) + m.push(D); + else + throw new u("Null argument, please report this as a bug"); + } + return { + args: m, + optArgs: b + }; + }, e.parseGroupOfType = function(n, l, c) { + switch (l) { + case "color": + return this.parseColorGroup(c); + case "size": + return this.parseSizeGroup(c); + case "url": + return this.parseUrlGroup(c); + case "math": + case "text": + return this.parseArgumentGroup(c, l); + case "hbox": { + var m = this.parseArgumentGroup(c, "text"); + return m != null ? { + type: "styling", + mode: m.mode, + body: [m], + style: "text" + // simulate \textstyle + } : null; + } + case "raw": { + var b = this.parseStringGroup("raw", c); + return b != null ? { + type: "raw", + mode: "text", + string: b.text + } : null; + } + case "primitive": { + if (c) + throw new u("A primitive argument cannot be optional"); + var k = this.parseGroup(n); + if (k == null) + throw new u("Expected group as " + n, this.fetch()); + return k; + } + case "original": + case null: + case void 0: + return this.parseArgumentGroup(c); + default: + throw new u("Unknown group type as " + n, this.fetch()); + } + }, e.consumeSpaces = function() { + for (; this.fetch().text === " "; ) + this.consume(); + }, e.parseStringGroup = function(n, l) { + var c = this.gullet.scanArgument(l); + if (c == null) + return null; + for (var m = "", b; (b = this.fetch()).text !== "EOF"; ) + m += b.text, this.consume(); + return this.consume(), c.text = m, c; + }, e.parseRegexGroup = function(n, l) { + for (var c = this.fetch(), m = c, b = "", k; (k = this.fetch()).text !== "EOF" && n.test(b + k.text); ) + m = k, b += m.text, this.consume(); + if (b === "") + throw new u("Invalid " + l + ": '" + c.text + "'", c); + return c.range(m, b); + }, e.parseColorGroup = function(n) { + var l = this.parseStringGroup("color", n); + if (l == null) + return null; + var c = /^(#[a-f0-9]{3}|#?[a-f0-9]{6}|[a-z]+)$/i.exec(l.text); + if (!c) + throw new u("Invalid color: '" + l.text + "'", l); + var m = c[0]; + return /^[0-9a-f]{6}$/i.test(m) && (m = "#" + m), { + type: "color-token", + mode: this.mode, + color: m + }; + }, e.parseSizeGroup = function(n) { + var l, c = !1; + if (this.gullet.consumeSpaces(), !n && this.gullet.future().text !== "{" ? l = this.parseRegexGroup(/^[-+]? *(?:$|\d+|\d+\.\d*|\.\d*) *[a-z]{0,2} *$/, "size") : l = this.parseStringGroup("size", n), !l) + return null; + !n && l.text.length === 0 && (l.text = "0pt", c = !0); + var m = /([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(l.text); + if (!m) + throw new u("Invalid size: '" + l.text + "'", l); + var b = { + number: +(m[1] + m[2]), + // sign + magnitude, cast to number + unit: m[3] + }; + if (!lr(b)) + throw new u("Invalid unit: '" + b.unit + "'", l); + return { + type: "size", + mode: this.mode, + value: b, + isBlank: c + }; + }, e.parseUrlGroup = function(n) { + this.gullet.lexer.setCatcode("%", 13), this.gullet.lexer.setCatcode("~", 12); + var l = this.parseStringGroup("url", n); + if (this.gullet.lexer.setCatcode("%", 14), this.gullet.lexer.setCatcode("~", 13), l == null) + return null; + var c = l.text.replace(/\\([#$%&~_^{}])/g, "$1"); + return { + type: "url", + mode: this.mode, + url: c + }; + }, e.parseArgumentGroup = function(n, l) { + var c = this.gullet.scanArgument(n); + if (c == null) + return null; + var m = this.mode; + l && this.switchMode(l), this.gullet.beginGroup(); + var b = this.parseExpression(!1, "EOF"); + this.expect("EOF"), this.gullet.endGroup(); + var k = { + type: "ordgroup", + mode: this.mode, + loc: c.loc, + body: b + }; + return l && this.switchMode(m), k; + }, e.parseGroup = function(n, l) { + var c = this.fetch(), m = c.text, b; + if (m === "{" || m === "\\begingroup") { + this.consume(); + var k = m === "{" ? "}" : "\\endgroup"; + this.gullet.beginGroup(); + var x = this.parseExpression(!1, k), C = this.fetch(); + this.expect(k), this.gullet.endGroup(), b = { + type: "ordgroup", + mode: this.mode, + loc: Vt.range(c, C), + body: x, + // A group formed by \begingroup...\endgroup is a semi-simple group + // which doesn't affect spacing in math mode, i.e., is transparent. + // https://tex.stackexchange.com/questions/1930/when-should-one- + // use-begingroup-instead-of-bgroup + semisimple: m === "\\begingroup" || void 0 + }; + } else if (b = this.parseFunction(l, n) || this.parseSymbol(), b == null && m[0] === "\\" && !wl.hasOwnProperty(m)) { + if (this.settings.throwOnError) + throw new u("Undefined control sequence: " + m, c); + b = this.formatUnsupportedCmd(m), this.consume(); + } + return b; + }, e.formLigatures = function(n) { + for (var l = n.length - 1, c = 0; c < l; ++c) { + var m = n[c], b = m.text; + b === "-" && n[c + 1].text === "-" && (c + 1 < l && n[c + 2].text === "-" ? (n.splice(c, 3, { + type: "textord", + mode: "text", + loc: Vt.range(m, n[c + 2]), + text: "---" + }), l -= 2) : (n.splice(c, 2, { + type: "textord", + mode: "text", + loc: Vt.range(m, n[c + 1]), + text: "--" + }), l -= 1)), (b === "'" || b === "`") && n[c + 1].text === b && (n.splice(c, 2, { + type: "textord", + mode: "text", + loc: Vt.range(m, n[c + 1]), + text: b + b + }), l -= 1); + } + }, e.parseSymbol = function() { + var n = this.fetch(), l = n.text; + if (/^\\verb[^a-zA-Z]/.test(l)) { + this.consume(); + var c = l.slice(5), m = c.charAt(0) === "*"; + if (m && (c = c.slice(1)), c.length < 2 || c.charAt(0) !== c.slice(-1)) + throw new u(`\\verb assertion failed -- + please report what input caused this bug`); + return c = c.slice(1, -1), { + type: "verb", + mode: "text", + body: c, + star: m + }; + } + _l.hasOwnProperty(l[0]) && !Ve[this.mode][l[0]] && (this.settings.strict && this.mode === "math" && this.settings.reportNonstrict("unicodeTextInMathMode", 'Accented Unicode text character "' + l[0] + '" used in math mode', n), l = _l[l[0]] + l.slice(1)); + var b = J1.exec(l); + b && (l = l.substring(0, b.index), l === "i" ? l = "ı" : l === "j" && (l = "ȷ")); + var k; + if (Ve[this.mode][l]) { + this.settings.strict && this.mode === "math" && Yn.indexOf(l) >= 0 && this.settings.reportNonstrict("unicodeTextInMathMode", 'Latin-1/Unicode text character "' + l[0] + '" used in math mode', n); + var x = Ve[this.mode][l].group, C = Vt.range(n), D; + if (c0.hasOwnProperty(x)) { + var P = x; + D = { + type: "atom", + mode: this.mode, + family: P, + loc: C, + text: l + }; + } else + D = { + type: x, + mode: this.mode, + loc: C, + text: l + }; + k = D; + } else if (l.charCodeAt(0) >= 128) + this.settings.strict && (te(l.charCodeAt(0)) ? this.mode === "math" && this.settings.reportNonstrict("unicodeTextInMathMode", 'Unicode text character "' + l[0] + '" used in math mode', n) : this.settings.reportNonstrict("unknownSymbol", 'Unrecognized Unicode character "' + l[0] + '"' + (" (" + l.charCodeAt(0) + ")"), n)), k = { + type: "textord", + mode: "text", + loc: Vt.range(n), + text: l + }; + else + return null; + if (this.consume(), b) + for (var q = 0; q < b[0].length; q++) { + var U = b[0][q]; + if (!_a[U]) + throw new u("Unknown accent ' " + U + "'", n); + var $ = _a[U][this.mode] || _a[U].text; + if (!$) + throw new u("Accent " + U + " unsupported in " + this.mode + " mode", n); + k = { + type: "accent", + mode: this.mode, + loc: Vt.range(n), + label: $, + isStretchy: !1, + isShifty: !0, + // $FlowFixMe + base: k + }; + } + return k; + }, f; + }(); + xl.endOfExpression = ["}", "\\endgroup", "\\end", "\\right", "&"]; + var au = function(e, t) { + if (!(typeof e == "string" || e instanceof String)) + throw new TypeError("KaTeX can only parse string typed expression"); + var n = new xl(e, t); + delete n.gullet.macros.current["\\df@tag"]; + var l = n.parse(); + if (delete n.gullet.macros.current["\\current@color"], delete n.gullet.macros.current["\\color"], n.gullet.macros.get("\\df@tag")) { + if (!t.displayMode) + throw new u("\\tag works only in display equations"); + l = [{ + type: "tag", + mode: "text", + body: l, + tag: n.subparse([new z0("\\df@tag")]) + }]; + } + return l; + }, xa = au, Sl = function(e, t, n) { + t.textContent = ""; + var l = Sa(e, n).toNode(); + t.appendChild(l); + }; + typeof document < "u" && document.compatMode !== "CSS1Compat" && (typeof console < "u" && console.warn("Warning: KaTeX doesn't work in quirks mode. Make sure your website has a suitable doctype."), Sl = function() { + throw new u("KaTeX doesn't work in quirks mode."); + }); + var iu = function(e, t) { + var n = Sa(e, t).toMarkup(); + return n; + }, lu = function(e, t) { + var n = new R(t); + return xa(e, n); + }, Al = function(e, t, n) { + if (n.throwOnError || !(e instanceof u)) + throw e; + var l = N.makeSpan(["katex-error"], [new bt(t)]); + return l.setAttribute("title", e.toString()), l.setAttribute("style", "color:" + n.errorColor), l; + }, Sa = function(e, t) { + var n = new R(t); + try { + var l = xa(e, n); + return h1(l, e, n); + } catch (c) { + return Al(c, e, n); + } + }, su = function(e, t) { + var n = new R(t); + try { + var l = xa(e, n); + return f1(l, e, n); + } catch (c) { + return Al(c, e, n); + } + }, ou = { + /** + * Current KaTeX version + */ + version: "0.16.9", + /** + * Renders the given LaTeX into an HTML+MathML combination, and adds + * it as a child to the specified DOM node. + */ + render: Sl, + /** + * Renders the given LaTeX into an HTML+MathML combination string, + * for sending to the client. + */ + renderToString: iu, + /** + * KaTeX error, usually during parsing. + */ + ParseError: u, + /** + * The shema of Settings + */ + SETTINGS_SCHEMA: F, + /** + * Parses the given LaTeX into KaTeX's internal parse tree structure, + * without rendering to HTML or MathML. + * + * NOTE: This method is not currently recommended for public use. + * The internal tree representation is unstable and is very likely + * to change. Use at your own risk. + */ + __parse: lu, + /** + * Renders the given LaTeX into an HTML+MathML internal DOM tree + * representation, without flattening that representation to a string. + * + * NOTE: This method is not currently recommended for public use. + * The internal tree representation is unstable and is very likely + * to change. Use at your own risk. + */ + __renderToDomTree: Sa, + /** + * Renders the given LaTeX into an HTML internal DOM tree representation, + * without MathML and without flattening that representation to a string. + * + * NOTE: This method is not currently recommended for public use. + * The internal tree representation is unstable and is very likely + * to change. Use at your own risk. + */ + __renderToHTMLTree: su, + /** + * extends internal font metrics object with a new object + * each key in the new object represents a font name + */ + __setFontMetrics: _0, + /** + * adds a new symbol to builtin symbols table + */ + __defineSymbol: h, + /** + * adds a new function to builtin function list, + * which directly produce parse tree elements + * and have their own html/mathml builders + */ + __defineFunction: se, + /** + * adds a new macro to builtin macro list + */ + __defineMacro: _, + /** + * Expose the dom tree node types, which can be useful for type checking nodes. + * + * NOTE: This method is not currently recommended for public use. + * The internal tree representation is unstable and is very likely + * to change. Use at your own risk. + */ + __domTree: { + Span: Rt, + Anchor: Tr, + SymbolNode: bt, + SvgNode: Ft, + PathNode: Zt, + LineNode: S0 + } + }, uu = ou; + return i = i.default, i; + }() + ); + }); + }(Va)), Va.exports; +} +(function(s, r) { + (function(i, o) { + s.exports = o(F4()); + })(typeof self < "u" ? self : Nn, function(a) { + return ( + /******/ + function() { + var i = { + /***/ + 771: ( + /***/ + function(p) { + p.exports = a; + } + ) + /******/ + }, o = {}; + function u(p) { + var v = o[p]; + if (v !== void 0) + return v.exports; + var w = o[p] = { + /******/ + // no module.id needed + /******/ + // no module.loaded needed + /******/ + exports: {} + /******/ + }; + return i[p](w, w.exports, u), w.exports; + } + (function() { + u.n = function(p) { + var v = p && p.__esModule ? ( + /******/ + function() { + return p.default; + } + ) : ( + /******/ + function() { + return p; + } + ); + return u.d(v, { a: v }), v; + }; + })(), function() { + u.d = function(p, v) { + for (var w in v) + u.o(v, w) && !u.o(p, w) && Object.defineProperty(p, w, { enumerable: !0, get: v[w] }); + }; + }(), function() { + u.o = function(p, v) { + return Object.prototype.hasOwnProperty.call(p, v); + }; + }(); + var g = {}; + return function() { + u.d(g, { + default: function() { + return ( + /* binding */ + V + ); + } + }); + var p = u(771), v = /* @__PURE__ */ u.n(p), w = function(M, R, B) { + for (var H = B, W = 0, Z = M.length; H < R.length; ) { + var G = R[H]; + if (W <= 0 && R.slice(H, H + Z) === M) + return H; + G === "\\" ? H++ : G === "{" ? W++ : G === "}" && W--, H++; + } + return -1; + }, S = function(M) { + return M.replace(/[-/\\^$*+?.()|[\]{}]/g, "\\$&"); + }, L = /^\\begin{/, O = function(M, R) { + for (var B, H = [], W = new RegExp("(" + R.map(function(ve) { + return S(ve.left); + }).join("|") + ")"); B = M.search(W), B !== -1; ) { + B > 0 && (H.push({ + type: "text", + data: M.slice(0, B) + }), M = M.slice(B)); + var Z = R.findIndex(function(ve) { + return M.startsWith(ve.left); + }); + if (B = w(R[Z].right, M, R[Z].left.length), B === -1) + break; + var G = M.slice(0, B + R[Z].right.length), ce = L.test(G) ? G : M.slice(R[Z].left.length, B); + H.push({ + type: "math", + data: ce, + rawData: G, + display: R[Z].display + }), M = M.slice(B + R[Z].right.length); + } + return M !== "" && H.push({ + type: "text", + data: M + }), H; + }, X = O, I = function(M, R) { + var B = X(M, R.delimiters); + if (B.length === 1 && B[0].type === "text") + return null; + for (var H = document.createDocumentFragment(), W = 0; W < B.length; W++) + if (B[W].type === "text") + H.appendChild(document.createTextNode(B[W].data)); + else { + var Z = document.createElement("span"), G = B[W].data; + R.displayMode = B[W].display; + try { + R.preProcess && (G = R.preProcess(G)), v().render(G, Z, R); + } catch (ce) { + if (!(ce instanceof v().ParseError)) + throw ce; + R.errorCallback("KaTeX auto-render: Failed to parse `" + B[W].data + "` with ", ce), H.appendChild(document.createTextNode(B[W].rawData)); + continue; + } + H.appendChild(Z); + } + return H; + }, ne = function F(M, R) { + for (var B = 0; B < M.childNodes.length; B++) { + var H = M.childNodes[B]; + if (H.nodeType === 3) { + for (var W = H.textContent, Z = H.nextSibling, G = 0; Z && Z.nodeType === Node.TEXT_NODE; ) + W += Z.textContent, Z = Z.nextSibling, G++; + var ce = I(W, R); + if (ce) { + for (var ve = 0; ve < G; ve++) + H.nextSibling.remove(); + B += ce.childNodes.length - 1, M.replaceChild(ce, H); + } else + B += G; + } else + H.nodeType === 1 && function() { + var Ee = " " + H.className + " ", xe = R.ignoredTags.indexOf(H.nodeName.toLowerCase()) === -1 && R.ignoredClasses.every(function(Ne) { + return Ee.indexOf(" " + Ne + " ") === -1; + }); + xe && F(H, R); + }(); + } + }, re = function(M, R) { + if (!M) + throw new Error("No element provided to render"); + var B = {}; + for (var H in R) + R.hasOwnProperty(H) && (B[H] = R[H]); + B.delimiters = B.delimiters || [ + { + left: "$$", + right: "$$", + display: !0 + }, + { + left: "\\(", + right: "\\)", + display: !1 + }, + // LaTeX uses $…$, but it ruins the display of normal `$` in text: + // {left: "$", right: "$", display: false}, + // $ must come after $$ + // Render AMS environments even if outside $$…$$ delimiters. + { + left: "\\begin{equation}", + right: "\\end{equation}", + display: !0 + }, + { + left: "\\begin{align}", + right: "\\end{align}", + display: !0 + }, + { + left: "\\begin{alignat}", + right: "\\end{alignat}", + display: !0 + }, + { + left: "\\begin{gather}", + right: "\\end{gather}", + display: !0 + }, + { + left: "\\begin{CD}", + right: "\\end{CD}", + display: !0 + }, + { + left: "\\[", + right: "\\]", + display: !0 + } + ], B.ignoredTags = B.ignoredTags || ["script", "noscript", "style", "textarea", "pre", "code", "option"], B.ignoredClasses = B.ignoredClasses || [], B.errorCallback = B.errorCallback || console.error, B.macros = B.macros || {}, ne(M, B); + }, V = re; + }(), g = g.default, g; + }() + ); + }); +})(ko); +var L4 = ko.exports; +const I4 = /* @__PURE__ */ wo(L4); +function ai() { + return { + async: !1, + baseUrl: null, + breaks: !1, + extensions: null, + gfm: !0, + headerIds: !1, + headerPrefix: "", + highlight: null, + hooks: null, + langPrefix: "language-", + mangle: !1, + pedantic: !1, + renderer: null, + sanitize: !1, + sanitizer: null, + silent: !1, + smartypants: !1, + tokenizer: null, + walkTokens: null, + xhtml: !1 + }; +} +let tr = ai(); +function _o(s) { + tr = s; +} +const xo = /[&<>"']/, O4 = new RegExp(xo.source, "g"), So = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, q4 = new RegExp(So.source, "g"), P4 = { + "&": "&", + "<": "<", + ">": ">", + '"': """, + "'": "'" +}, Jl = (s) => P4[s]; +function mt(s, r) { + if (r) { + if (xo.test(s)) + return s.replace(O4, Jl); + } else if (So.test(s)) + return s.replace(q4, Jl); + return s; +} +const H4 = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig; +function Ao(s) { + return s.replace(H4, (r, a) => (a = a.toLowerCase(), a === "colon" ? ":" : a.charAt(0) === "#" ? a.charAt(1) === "x" ? String.fromCharCode(parseInt(a.substring(2), 16)) : String.fromCharCode(+a.substring(1)) : "")); +} +const U4 = /(^|[^\[])\^/g; +function Le(s, r) { + s = typeof s == "string" ? s : s.source, r = r || ""; + const a = { + replace: (i, o) => (o = typeof o == "object" && "source" in o ? o.source : o, o = o.replace(U4, "$1"), s = s.replace(i, o), a), + getRegex: () => new RegExp(s, r) + }; + return a; +} +const G4 = /[^\w:]/g, V4 = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i; +function $l(s, r, a) { + if (s) { + let i; + try { + i = decodeURIComponent(Ao(a)).replace(G4, "").toLowerCase(); + } catch { + return null; + } + if (i.indexOf("javascript:") === 0 || i.indexOf("vbscript:") === 0 || i.indexOf("data:") === 0) + return null; + } + r && !V4.test(a) && (a = X4(r, a)); + try { + a = encodeURI(a).replace(/%25/g, "%"); + } catch { + return null; + } + return a; +} +const Sn = {}, j4 = /^[^:]+:\/*[^/]*$/, W4 = /^([^:]+:)[\s\S]*$/, Y4 = /^([^:]+:\/*[^/]*)[\s\S]*$/; +function X4(s, r) { + Sn[" " + s] || (j4.test(s) ? Sn[" " + s] = s + "/" : Sn[" " + s] = Bn(s, "/", !0)), s = Sn[" " + s]; + const a = s.indexOf(":") === -1; + return r.substring(0, 2) === "//" ? a ? r : s.replace(W4, "$1") + r : r.charAt(0) === "/" ? a ? r : s.replace(Y4, "$1") + r : s + r; +} +const Rn = { exec: () => null }; +function es(s, r) { + const a = s.replace(/\|/g, (u, g, p) => { + let v = !1, w = g; + for (; --w >= 0 && p[w] === "\\"; ) + v = !v; + return v ? "|" : " |"; + }), i = a.split(/ \|/); + let o = 0; + if (i[0].trim() || i.shift(), i.length > 0 && !i[i.length - 1].trim() && i.pop(), r) + if (i.length > r) + i.splice(r); + else + for (; i.length < r; ) + i.push(""); + for (; o < i.length; o++) + i[o] = i[o].trim().replace(/\\\|/g, "|"); + return i; +} +function Bn(s, r, a) { + const i = s.length; + if (i === 0) + return ""; + let o = 0; + for (; o < i; ) { + const u = s.charAt(i - o - 1); + if (u === r && !a) + o++; + else if (u !== r && a) + o++; + else + break; + } + return s.slice(0, i - o); +} +function Z4(s, r) { + if (s.indexOf(r[1]) === -1) + return -1; + let a = 0; + for (let i = 0; i < s.length; i++) + if (s[i] === "\\") + i++; + else if (s[i] === r[0]) + a++; + else if (s[i] === r[1] && (a--, a < 0)) + return i; + return -1; +} +function K4(s, r) { + !s || s.silent || (r && console.warn("marked(): callback is deprecated since version 5.0.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/using_pro#async"), (s.sanitize || s.sanitizer) && console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options"), (s.highlight || s.langPrefix !== "language-") && console.warn("marked(): highlight and langPrefix parameters are deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-highlight."), s.mangle && console.warn("marked(): mangle parameter is enabled by default, but is deprecated since version 5.0.0, and will be removed in the future. To clear this warning, install https://www.npmjs.com/package/marked-mangle, or disable by setting `{mangle: false}`."), s.baseUrl && console.warn("marked(): baseUrl parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-base-url."), s.smartypants && console.warn("marked(): smartypants parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-smartypants."), s.xhtml && console.warn("marked(): xhtml parameter is deprecated since version 5.0.0, should not be used and will be removed in the future. Instead use https://www.npmjs.com/package/marked-xhtml."), (s.headerIds || s.headerPrefix) && console.warn("marked(): headerIds and headerPrefix parameters enabled by default, but are deprecated since version 5.0.0, and will be removed in the future. To clear this warning, install https://www.npmjs.com/package/marked-gfm-heading-id, or disable by setting `{headerIds: false}`.")); +} +function ts(s, r, a, i) { + const o = r.href, u = r.title ? mt(r.title) : null, g = s[1].replace(/\\([\[\]])/g, "$1"); + if (s[0].charAt(0) !== "!") { + i.state.inLink = !0; + const p = { + type: "link", + raw: a, + href: o, + title: u, + text: g, + tokens: i.inlineTokens(g) + }; + return i.state.inLink = !1, p; + } + return { + type: "image", + raw: a, + href: o, + title: u, + text: mt(g) + }; +} +function Q4(s, r) { + const a = s.match(/^(\s+)(?:```)/); + if (a === null) + return r; + const i = a[1]; + return r.split(` +`).map((o) => { + const u = o.match(/^\s+/); + if (u === null) + return o; + const [g] = u; + return g.length >= i.length ? o.slice(i.length) : o; + }).join(` +`); +} +class Fn { + constructor(r) { + Fe(this, "options"); + // TODO: Fix this rules type + Fe(this, "rules"); + Fe(this, "lexer"); + this.options = r || tr; + } + space(r) { + const a = this.rules.block.newline.exec(r); + if (a && a[0].length > 0) + return { + type: "space", + raw: a[0] + }; + } + code(r) { + const a = this.rules.block.code.exec(r); + if (a) { + const i = a[0].replace(/^ {1,4}/gm, ""); + return { + type: "code", + raw: a[0], + codeBlockStyle: "indented", + text: this.options.pedantic ? i : Bn(i, ` +`) + }; + } + } + fences(r) { + const a = this.rules.block.fences.exec(r); + if (a) { + const i = a[0], o = Q4(i, a[3] || ""); + return { + type: "code", + raw: i, + lang: a[2] ? a[2].trim().replace(this.rules.inline._escapes, "$1") : a[2], + text: o + }; + } + } + heading(r) { + const a = this.rules.block.heading.exec(r); + if (a) { + let i = a[2].trim(); + if (/#$/.test(i)) { + const o = Bn(i, "#"); + (this.options.pedantic || !o || / $/.test(o)) && (i = o.trim()); + } + return { + type: "heading", + raw: a[0], + depth: a[1].length, + text: i, + tokens: this.lexer.inline(i) + }; + } + } + hr(r) { + const a = this.rules.block.hr.exec(r); + if (a) + return { + type: "hr", + raw: a[0] + }; + } + blockquote(r) { + const a = this.rules.block.blockquote.exec(r); + if (a) { + const i = a[0].replace(/^ *>[ \t]?/gm, ""), o = this.lexer.state.top; + this.lexer.state.top = !0; + const u = this.lexer.blockTokens(i); + return this.lexer.state.top = o, { + type: "blockquote", + raw: a[0], + tokens: u, + text: i + }; + } + } + list(r) { + let a = this.rules.block.list.exec(r); + if (a) { + let i = a[1].trim(); + const o = i.length > 1, u = { + type: "list", + raw: "", + ordered: o, + start: o ? +i.slice(0, -1) : "", + loose: !1, + items: [] + }; + i = o ? `\\d{1,9}\\${i.slice(-1)}` : `\\${i}`, this.options.pedantic && (i = o ? i : "[*+-]"); + const g = new RegExp(`^( {0,3}${i})((?:[ ][^\\n]*)?(?:\\n|$))`); + let p = "", v = "", w = !1; + for (; r; ) { + let S = !1; + if (!(a = g.exec(r)) || this.rules.block.hr.test(r)) + break; + p = a[0], r = r.substring(p.length); + let L = a[2].split(` +`, 1)[0].replace(/^\t+/, (V) => " ".repeat(3 * V.length)), O = r.split(` +`, 1)[0], X = 0; + this.options.pedantic ? (X = 2, v = L.trimLeft()) : (X = a[2].search(/[^ ]/), X = X > 4 ? 1 : X, v = L.slice(X), X += a[1].length); + let I = !1; + if (!L && /^ *$/.test(O) && (p += O + ` +`, r = r.substring(O.length + 1), S = !0), !S) { + const V = new RegExp(`^ {0,${Math.min(3, X - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), F = new RegExp(`^ {0,${Math.min(3, X - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), M = new RegExp(`^ {0,${Math.min(3, X - 1)}}(?:\`\`\`|~~~)`), R = new RegExp(`^ {0,${Math.min(3, X - 1)}}#`); + for (; r; ) { + const B = r.split(` +`, 1)[0]; + if (O = B, this.options.pedantic && (O = O.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ")), M.test(O) || R.test(O) || V.test(O) || F.test(r)) + break; + if (O.search(/[^ ]/) >= X || !O.trim()) + v += ` +` + O.slice(X); + else { + if (I || L.search(/[^ ]/) >= 4 || M.test(L) || R.test(L) || F.test(L)) + break; + v += ` +` + O; + } + !I && !O.trim() && (I = !0), p += B + ` +`, r = r.substring(B.length + 1), L = O.slice(X); + } + } + u.loose || (w ? u.loose = !0 : /\n *\n *$/.test(p) && (w = !0)); + let ne = null, re; + this.options.gfm && (ne = /^\[[ xX]\] /.exec(v), ne && (re = ne[0] !== "[ ] ", v = v.replace(/^\[[ xX]\] +/, ""))), u.items.push({ + type: "list_item", + raw: p, + task: !!ne, + checked: re, + loose: !1, + text: v, + tokens: [] + }), u.raw += p; + } + u.items[u.items.length - 1].raw = p.trimRight(), u.items[u.items.length - 1].text = v.trimRight(), u.raw = u.raw.trimRight(); + for (let S = 0; S < u.items.length; S++) + if (this.lexer.state.top = !1, u.items[S].tokens = this.lexer.blockTokens(u.items[S].text, []), !u.loose) { + const L = u.items[S].tokens.filter((X) => X.type === "space"), O = L.length > 0 && L.some((X) => /\n.*\n/.test(X.raw)); + u.loose = O; + } + if (u.loose) + for (let S = 0; S < u.items.length; S++) + u.items[S].loose = !0; + return u; + } + } + html(r) { + const a = this.rules.block.html.exec(r); + if (a) { + const i = { + type: "html", + block: !0, + raw: a[0], + pre: !this.options.sanitizer && (a[1] === "pre" || a[1] === "script" || a[1] === "style"), + text: a[0] + }; + if (this.options.sanitize) { + const o = this.options.sanitizer ? this.options.sanitizer(a[0]) : mt(a[0]), u = i; + u.type = "paragraph", u.text = o, u.tokens = this.lexer.inline(o); + } + return i; + } + } + def(r) { + const a = this.rules.block.def.exec(r); + if (a) { + const i = a[1].toLowerCase().replace(/\s+/g, " "), o = a[2] ? a[2].replace(/^<(.*)>$/, "$1").replace(this.rules.inline._escapes, "$1") : "", u = a[3] ? a[3].substring(1, a[3].length - 1).replace(this.rules.inline._escapes, "$1") : a[3]; + return { + type: "def", + tag: i, + raw: a[0], + href: o, + title: u + }; + } + } + table(r) { + const a = this.rules.block.table.exec(r); + if (a) { + const i = { + type: "table", + raw: a[0], + header: es(a[1]).map((o) => ({ text: o, tokens: [] })), + align: a[2].replace(/^ *|\| *$/g, "").split(/ *\| */), + rows: a[3] && a[3].trim() ? a[3].replace(/\n[ \t]*$/, "").split(` +`) : [] + }; + if (i.header.length === i.align.length) { + let o = i.align.length, u, g, p, v; + for (u = 0; u < o; u++) { + const w = i.align[u]; + w && (/^ *-+: *$/.test(w) ? i.align[u] = "right" : /^ *:-+: *$/.test(w) ? i.align[u] = "center" : /^ *:-+ *$/.test(w) ? i.align[u] = "left" : i.align[u] = null); + } + for (o = i.rows.length, u = 0; u < o; u++) + i.rows[u] = es(i.rows[u], i.header.length).map((w) => ({ text: w, tokens: [] })); + for (o = i.header.length, g = 0; g < o; g++) + i.header[g].tokens = this.lexer.inline(i.header[g].text); + for (o = i.rows.length, g = 0; g < o; g++) + for (v = i.rows[g], p = 0; p < v.length; p++) + v[p].tokens = this.lexer.inline(v[p].text); + return i; + } + } + } + lheading(r) { + const a = this.rules.block.lheading.exec(r); + if (a) + return { + type: "heading", + raw: a[0], + depth: a[2].charAt(0) === "=" ? 1 : 2, + text: a[1], + tokens: this.lexer.inline(a[1]) + }; + } + paragraph(r) { + const a = this.rules.block.paragraph.exec(r); + if (a) { + const i = a[1].charAt(a[1].length - 1) === ` +` ? a[1].slice(0, -1) : a[1]; + return { + type: "paragraph", + raw: a[0], + text: i, + tokens: this.lexer.inline(i) + }; + } + } + text(r) { + const a = this.rules.block.text.exec(r); + if (a) + return { + type: "text", + raw: a[0], + text: a[0], + tokens: this.lexer.inline(a[0]) + }; + } + escape(r) { + const a = this.rules.inline.escape.exec(r); + if (a) + return { + type: "escape", + raw: a[0], + text: mt(a[1]) + }; + } + tag(r) { + const a = this.rules.inline.tag.exec(r); + if (a) + return !this.lexer.state.inLink && /^/i.test(a[0]) && (this.lexer.state.inLink = !1), !this.lexer.state.inRawBlock && /^<(pre|code|kbd|script)(\s|>)/i.test(a[0]) ? this.lexer.state.inRawBlock = !0 : this.lexer.state.inRawBlock && /^<\/(pre|code|kbd|script)(\s|>)/i.test(a[0]) && (this.lexer.state.inRawBlock = !1), { + type: this.options.sanitize ? "text" : "html", + raw: a[0], + inLink: this.lexer.state.inLink, + inRawBlock: this.lexer.state.inRawBlock, + block: !1, + text: this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(a[0]) : mt(a[0]) : a[0] + }; + } + link(r) { + const a = this.rules.inline.link.exec(r); + if (a) { + const i = a[2].trim(); + if (!this.options.pedantic && /^$/.test(i)) + return; + const g = Bn(i.slice(0, -1), "\\"); + if ((i.length - g.length) % 2 === 0) + return; + } else { + const g = Z4(a[2], "()"); + if (g > -1) { + const v = (a[0].indexOf("!") === 0 ? 5 : 4) + a[1].length + g; + a[2] = a[2].substring(0, g), a[0] = a[0].substring(0, v).trim(), a[3] = ""; + } + } + let o = a[2], u = ""; + if (this.options.pedantic) { + const g = /^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(o); + g && (o = g[1], u = g[3]); + } else + u = a[3] ? a[3].slice(1, -1) : ""; + return o = o.trim(), /^$/.test(i) ? o = o.slice(1) : o = o.slice(1, -1)), ts(a, { + href: o && o.replace(this.rules.inline._escapes, "$1"), + title: u && u.replace(this.rules.inline._escapes, "$1") + }, a[0], this.lexer); + } + } + reflink(r, a) { + let i; + if ((i = this.rules.inline.reflink.exec(r)) || (i = this.rules.inline.nolink.exec(r))) { + let o = (i[2] || i[1]).replace(/\s+/g, " "); + if (o = a[o.toLowerCase()], !o) { + const u = i[0].charAt(0); + return { + type: "text", + raw: u, + text: u + }; + } + return ts(i, o, i[0], this.lexer); + } + } + emStrong(r, a, i = "") { + let o = this.rules.inline.emStrong.lDelim.exec(r); + if (!o || o[3] && i.match(/[\p{L}\p{N}]/u)) + return; + if (!(o[1] || o[2] || "") || !i || this.rules.inline.punctuation.exec(i)) { + const g = [...o[0]].length - 1; + let p, v, w = g, S = 0; + const L = o[0][0] === "*" ? this.rules.inline.emStrong.rDelimAst : this.rules.inline.emStrong.rDelimUnd; + for (L.lastIndex = 0, a = a.slice(-1 * r.length + g); (o = L.exec(a)) != null; ) { + if (p = o[1] || o[2] || o[3] || o[4] || o[5] || o[6], !p) + continue; + if (v = [...p].length, o[3] || o[4]) { + w += v; + continue; + } else if ((o[5] || o[6]) && g % 3 && !((g + v) % 3)) { + S += v; + continue; + } + if (w -= v, w > 0) + continue; + v = Math.min(v, v + w + S); + const O = [...r].slice(0, g + o.index + v + 1).join(""); + if (Math.min(g, v) % 2) { + const I = O.slice(1, -1); + return { + type: "em", + raw: O, + text: I, + tokens: this.lexer.inlineTokens(I) + }; + } + const X = O.slice(2, -2); + return { + type: "strong", + raw: O, + text: X, + tokens: this.lexer.inlineTokens(X) + }; + } + } + } + codespan(r) { + const a = this.rules.inline.code.exec(r); + if (a) { + let i = a[2].replace(/\n/g, " "); + const o = /[^ ]/.test(i), u = /^ /.test(i) && / $/.test(i); + return o && u && (i = i.substring(1, i.length - 1)), i = mt(i, !0), { + type: "codespan", + raw: a[0], + text: i + }; + } + } + br(r) { + const a = this.rules.inline.br.exec(r); + if (a) + return { + type: "br", + raw: a[0] + }; + } + del(r) { + const a = this.rules.inline.del.exec(r); + if (a) + return { + type: "del", + raw: a[0], + text: a[2], + tokens: this.lexer.inlineTokens(a[2]) + }; + } + autolink(r, a) { + const i = this.rules.inline.autolink.exec(r); + if (i) { + let o, u; + return i[2] === "@" ? (o = mt(this.options.mangle ? a(i[1]) : i[1]), u = "mailto:" + o) : (o = mt(i[1]), u = o), { + type: "link", + raw: i[0], + text: o, + href: u, + tokens: [ + { + type: "text", + raw: o, + text: o + } + ] + }; + } + } + url(r, a) { + let i; + if (i = this.rules.inline.url.exec(r)) { + let o, u; + if (i[2] === "@") + o = mt(this.options.mangle ? a(i[0]) : i[0]), u = "mailto:" + o; + else { + let g; + do + g = i[0], i[0] = this.rules.inline._backpedal.exec(i[0])[0]; + while (g !== i[0]); + o = mt(i[0]), i[1] === "www." ? u = "http://" + i[0] : u = i[0]; + } + return { + type: "link", + raw: i[0], + text: o, + href: u, + tokens: [ + { + type: "text", + raw: o, + text: o + } + ] + }; + } + } + inlineText(r, a) { + const i = this.rules.inline.text.exec(r); + if (i) { + let o; + return this.lexer.state.inRawBlock ? o = this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(i[0]) : mt(i[0]) : i[0] : o = mt(this.options.smartypants ? a(i[0]) : i[0]), { + type: "text", + raw: i[0], + text: o + }; + } + } +} +const pe = { + newline: /^(?: *(?:\n|$))+/, + code: /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, + fences: /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, + hr: /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, + heading: /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, + blockquote: /^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/, + list: /^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/, + html: "^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))", + def: /^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/, + table: Rn, + lheading: /^((?:(?!^bull ).|\n(?!\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, + // regex template, placeholders will be replaced according to different paragraph + // interruption rules of commonmark and the original markdown spec: + _paragraph: /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, + text: /^[^\n]+/ +}; +pe._label = /(?!\s*\])(?:\\.|[^\[\]\\])+/; +pe._title = /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/; +pe.def = Le(pe.def).replace("label", pe._label).replace("title", pe._title).getRegex(); +pe.bullet = /(?:[*+-]|\d{1,9}[.)])/; +pe.listItemStart = Le(/^( *)(bull) */).replace("bull", pe.bullet).getRegex(); +pe.list = Le(pe.list).replace(/bull/g, pe.bullet).replace("hr", "\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def", "\\n+(?=" + pe.def.source + ")").getRegex(); +pe._tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul"; +pe._comment = /|$)/; +pe.html = Le(pe.html, "i").replace("comment", pe._comment).replace("tag", pe._tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(); +pe.lheading = Le(pe.lheading).replace(/bull/g, pe.bullet).getRegex(); +pe.paragraph = Le(pe._paragraph).replace("hr", pe.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", ")|<(?:script|pre|style|textarea|!--)").replace("tag", pe._tag).getRegex(); +pe.blockquote = Le(pe.blockquote).replace("paragraph", pe.paragraph).getRegex(); +pe.normal = { ...pe }; +pe.gfm = { + ...pe.normal, + table: "^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)" + // Cells +}; +pe.gfm.table = Le(pe.gfm.table).replace("hr", pe.hr).replace("heading", " {0,3}#{1,6} ").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", ")|<(?:script|pre|style|textarea|!--)").replace("tag", pe._tag).getRegex(); +pe.gfm.paragraph = Le(pe._paragraph).replace("hr", pe.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("table", pe.gfm.table).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", ")|<(?:script|pre|style|textarea|!--)").replace("tag", pe._tag).getRegex(); +pe.pedantic = { + ...pe.normal, + html: Le(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", pe._comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(), + def: /^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/, + heading: /^(#{1,6})(.*)(?:\n+|$)/, + fences: Rn, + lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/, + paragraph: Le(pe.normal._paragraph).replace("hr", pe.hr).replace("heading", ` *#{1,6} *[^ +]`).replace("lheading", pe.lheading).replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").getRegex() +}; +const ue = { + escape: /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, + autolink: /^<(scheme:[^\s\x00-\x1f<>]*|email)>/, + url: Rn, + tag: "^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^", + link: /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/, + reflink: /^!?\[(label)\]\[(ref)\]/, + nolink: /^!?\[(ref)\](?:\[\])?/, + reflinkSearch: "reflink|nolink(?!\\()", + emStrong: { + lDelim: /^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/, + // (1) and (2) can only be a Right Delimiter. (3) and (4) can only be Left. (5) and (6) can be either Left or Right. + // | Skip orphan inside strong | Consume to delim | (1) #*** | (2) a***#, a*** | (3) #***a, ***a | (4) ***# | (5) #***# | (6) a***a + rDelimAst: /^[^_*]*?__[^_*]*?\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\*)[punct](\*+)(?=[\s]|$)|[^punct\s](\*+)(?!\*)(?=[punct\s]|$)|(?!\*)[punct\s](\*+)(?=[^punct\s])|[\s](\*+)(?!\*)(?=[punct])|(?!\*)[punct](\*+)(?!\*)(?=[punct])|[^punct\s](\*+)(?=[^punct\s])/, + rDelimUnd: /^[^_*]*?\*\*[^_*]*?_[^_*]*?(?=\*\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\s]|$)|[^punct\s](_+)(?!_)(?=[punct\s]|$)|(?!_)[punct\s](_+)(?=[^punct\s])|[\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])/ + // ^- Not allowed for _ + }, + code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, + br: /^( {2,}|\\)\n(?!\s*$)/, + del: Rn, + text: /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`^|~"; +ue.punctuation = Le(ue.punctuation, "u").replace(/punctuation/g, ue._punctuation).getRegex(); +ue.blockSkip = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g; +ue.anyPunctuation = /\\[punct]/g; +ue._escapes = /\\([punct])/g; +ue._comment = Le(pe._comment).replace("(?:-->|$)", "-->").getRegex(); +ue.emStrong.lDelim = Le(ue.emStrong.lDelim, "u").replace(/punct/g, ue._punctuation).getRegex(); +ue.emStrong.rDelimAst = Le(ue.emStrong.rDelimAst, "gu").replace(/punct/g, ue._punctuation).getRegex(); +ue.emStrong.rDelimUnd = Le(ue.emStrong.rDelimUnd, "gu").replace(/punct/g, ue._punctuation).getRegex(); +ue.anyPunctuation = Le(ue.anyPunctuation, "gu").replace(/punct/g, ue._punctuation).getRegex(); +ue._escapes = Le(ue._escapes, "gu").replace(/punct/g, ue._punctuation).getRegex(); +ue._scheme = /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/; +ue._email = /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/; +ue.autolink = Le(ue.autolink).replace("scheme", ue._scheme).replace("email", ue._email).getRegex(); +ue._attribute = /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/; +ue.tag = Le(ue.tag).replace("comment", ue._comment).replace("attribute", ue._attribute).getRegex(); +ue._label = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/; +ue._href = /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/; +ue._title = /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/; +ue.link = Le(ue.link).replace("label", ue._label).replace("href", ue._href).replace("title", ue._title).getRegex(); +ue.reflink = Le(ue.reflink).replace("label", ue._label).replace("ref", pe._label).getRegex(); +ue.nolink = Le(ue.nolink).replace("ref", pe._label).getRegex(); +ue.reflinkSearch = Le(ue.reflinkSearch, "g").replace("reflink", ue.reflink).replace("nolink", ue.nolink).getRegex(); +ue.normal = { ...ue }; +ue.pedantic = { + ...ue.normal, + strong: { + start: /^__|\*\*/, + middle: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/, + endAst: /\*\*(?!\*)/g, + endUnd: /__(?!_)/g + }, + em: { + start: /^_|\*/, + middle: /^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/, + endAst: /\*(?!\*)/g, + endUnd: /_(?!_)/g + }, + link: Le(/^!?\[(label)\]\((.*?)\)/).replace("label", ue._label).getRegex(), + reflink: Le(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", ue._label).getRegex() +}; +ue.gfm = { + ...ue.normal, + escape: Le(ue.escape).replace("])", "~|])").getRegex(), + _extended_email: /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/, + url: /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, + _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/, + del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/, + text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\ 0.5 ? "x" + s.charCodeAt(a).toString(16) : s.charCodeAt(a).toString(); + r += "&#" + i + ";"; + } + return r; +} +class r0 { + constructor(r) { + Fe(this, "tokens"); + Fe(this, "options"); + Fe(this, "state"); + Fe(this, "tokenizer"); + Fe(this, "inlineQueue"); + this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = r || tr, this.options.tokenizer = this.options.tokenizer || new Fn(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = { + inLink: !1, + inRawBlock: !1, + top: !0 + }; + const a = { + block: pe.normal, + inline: ue.normal + }; + this.options.pedantic ? (a.block = pe.pedantic, a.inline = ue.pedantic) : this.options.gfm && (a.block = pe.gfm, this.options.breaks ? a.inline = ue.breaks : a.inline = ue.gfm), this.tokenizer.rules = a; + } + /** + * Expose Rules + */ + static get rules() { + return { + block: pe, + inline: ue + }; + } + /** + * Static Lex Method + */ + static lex(r, a) { + return new r0(a).lex(r); + } + /** + * Static Lex Inline Method + */ + static lexInline(r, a) { + return new r0(a).inlineTokens(r); + } + /** + * Preprocessing + */ + lex(r) { + r = r.replace(/\r\n|\r/g, ` +`), this.blockTokens(r, this.tokens); + let a; + for (; a = this.inlineQueue.shift(); ) + this.inlineTokens(a.src, a.tokens); + return this.tokens; + } + blockTokens(r, a = []) { + this.options.pedantic ? r = r.replace(/\t/g, " ").replace(/^ +$/gm, "") : r = r.replace(/^( *)(\t+)/gm, (p, v, w) => v + " ".repeat(w.length)); + let i, o, u, g; + for (; r; ) + if (!(this.options.extensions && this.options.extensions.block && this.options.extensions.block.some((p) => (i = p.call({ lexer: this }, r, a)) ? (r = r.substring(i.raw.length), a.push(i), !0) : !1))) { + if (i = this.tokenizer.space(r)) { + r = r.substring(i.raw.length), i.raw.length === 1 && a.length > 0 ? a[a.length - 1].raw += ` +` : a.push(i); + continue; + } + if (i = this.tokenizer.code(r)) { + r = r.substring(i.raw.length), o = a[a.length - 1], o && (o.type === "paragraph" || o.type === "text") ? (o.raw += ` +` + i.raw, o.text += ` +` + i.text, this.inlineQueue[this.inlineQueue.length - 1].src = o.text) : a.push(i); + continue; + } + if (i = this.tokenizer.fences(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.heading(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.hr(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.blockquote(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.list(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.html(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.def(r)) { + r = r.substring(i.raw.length), o = a[a.length - 1], o && (o.type === "paragraph" || o.type === "text") ? (o.raw += ` +` + i.raw, o.text += ` +` + i.raw, this.inlineQueue[this.inlineQueue.length - 1].src = o.text) : this.tokens.links[i.tag] || (this.tokens.links[i.tag] = { + href: i.href, + title: i.title + }); + continue; + } + if (i = this.tokenizer.table(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.lheading(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (u = r, this.options.extensions && this.options.extensions.startBlock) { + let p = 1 / 0; + const v = r.slice(1); + let w; + this.options.extensions.startBlock.forEach((S) => { + w = S.call({ lexer: this }, v), typeof w == "number" && w >= 0 && (p = Math.min(p, w)); + }), p < 1 / 0 && p >= 0 && (u = r.substring(0, p + 1)); + } + if (this.state.top && (i = this.tokenizer.paragraph(u))) { + o = a[a.length - 1], g && o.type === "paragraph" ? (o.raw += ` +` + i.raw, o.text += ` +` + i.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = o.text) : a.push(i), g = u.length !== r.length, r = r.substring(i.raw.length); + continue; + } + if (i = this.tokenizer.text(r)) { + r = r.substring(i.raw.length), o = a[a.length - 1], o && o.type === "text" ? (o.raw += ` +` + i.raw, o.text += ` +` + i.text, this.inlineQueue.pop(), this.inlineQueue[this.inlineQueue.length - 1].src = o.text) : a.push(i); + continue; + } + if (r) { + const p = "Infinite loop on byte: " + r.charCodeAt(0); + if (this.options.silent) { + console.error(p); + break; + } else + throw new Error(p); + } + } + return this.state.top = !0, a; + } + inline(r, a = []) { + return this.inlineQueue.push({ src: r, tokens: a }), a; + } + /** + * Lexing/Compiling + */ + inlineTokens(r, a = []) { + let i, o, u, g = r, p, v, w; + if (this.tokens.links) { + const S = Object.keys(this.tokens.links); + if (S.length > 0) + for (; (p = this.tokenizer.rules.inline.reflinkSearch.exec(g)) != null; ) + S.includes(p[0].slice(p[0].lastIndexOf("[") + 1, -1)) && (g = g.slice(0, p.index) + "[" + "a".repeat(p[0].length - 2) + "]" + g.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex)); + } + for (; (p = this.tokenizer.rules.inline.blockSkip.exec(g)) != null; ) + g = g.slice(0, p.index) + "[" + "a".repeat(p[0].length - 2) + "]" + g.slice(this.tokenizer.rules.inline.blockSkip.lastIndex); + for (; (p = this.tokenizer.rules.inline.anyPunctuation.exec(g)) != null; ) + g = g.slice(0, p.index) + "++" + g.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex); + for (; r; ) + if (v || (w = ""), v = !1, !(this.options.extensions && this.options.extensions.inline && this.options.extensions.inline.some((S) => (i = S.call({ lexer: this }, r, a)) ? (r = r.substring(i.raw.length), a.push(i), !0) : !1))) { + if (i = this.tokenizer.escape(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.tag(r)) { + r = r.substring(i.raw.length), o = a[a.length - 1], o && i.type === "text" && o.type === "text" ? (o.raw += i.raw, o.text += i.text) : a.push(i); + continue; + } + if (i = this.tokenizer.link(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.reflink(r, this.tokens.links)) { + r = r.substring(i.raw.length), o = a[a.length - 1], o && i.type === "text" && o.type === "text" ? (o.raw += i.raw, o.text += i.text) : a.push(i); + continue; + } + if (i = this.tokenizer.emStrong(r, g, w)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.codespan(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.br(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.del(r)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (i = this.tokenizer.autolink(r, rs)) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (!this.state.inLink && (i = this.tokenizer.url(r, rs))) { + r = r.substring(i.raw.length), a.push(i); + continue; + } + if (u = r, this.options.extensions && this.options.extensions.startInline) { + let S = 1 / 0; + const L = r.slice(1); + let O; + this.options.extensions.startInline.forEach((X) => { + O = X.call({ lexer: this }, L), typeof O == "number" && O >= 0 && (S = Math.min(S, O)); + }), S < 1 / 0 && S >= 0 && (u = r.substring(0, S + 1)); + } + if (i = this.tokenizer.inlineText(u, J4)) { + r = r.substring(i.raw.length), i.raw.slice(-1) !== "_" && (w = i.raw.slice(-1)), v = !0, o = a[a.length - 1], o && o.type === "text" ? (o.raw += i.raw, o.text += i.text) : a.push(i); + continue; + } + if (r) { + const S = "Infinite loop on byte: " + r.charCodeAt(0); + if (this.options.silent) { + console.error(S); + break; + } else + throw new Error(S); + } + } + return a; + } +} +class Ln { + constructor(r) { + Fe(this, "options"); + this.options = r || tr; + } + code(r, a, i) { + var u; + const o = (u = (a || "").match(/^\S*/)) == null ? void 0 : u[0]; + if (this.options.highlight) { + const g = this.options.highlight(r, o); + g != null && g !== r && (i = !0, r = g); + } + return r = r.replace(/\n$/, "") + ` +`, o ? '
' + (i ? r : mt(r, !0)) + `
+` : "
" + (i ? r : mt(r, !0)) + `
+`; + } + blockquote(r) { + return `
+${r}
+`; + } + html(r, a) { + return r; + } + heading(r, a, i, o) { + if (this.options.headerIds) { + const u = this.options.headerPrefix + o.slug(i); + return `${r} +`; + } + return `${r} +`; + } + hr() { + return this.options.xhtml ? `
+` : `
+`; + } + list(r, a, i) { + const o = a ? "ol" : "ul", u = a && i !== 1 ? ' start="' + i + '"' : ""; + return "<" + o + u + `> +` + r + " +`; + } + listitem(r, a, i) { + return `
  • ${r}
  • +`; + } + checkbox(r) { + return " "; + } + paragraph(r) { + return `

    ${r}

    +`; + } + table(r, a) { + return a && (a = `${a}`), ` + +` + r + ` +` + a + `
    +`; + } + tablerow(r) { + return ` +${r} +`; + } + tablecell(r, a) { + const i = a.header ? "th" : "td"; + return (a.align ? `<${i} align="${a.align}">` : `<${i}>`) + r + ` +`; + } + /** + * span level renderer + */ + strong(r) { + return `${r}`; + } + em(r) { + return `${r}`; + } + codespan(r) { + return `${r}`; + } + br() { + return this.options.xhtml ? "
    " : "
    "; + } + del(r) { + return `${r}`; + } + link(r, a, i) { + const o = $l(this.options.sanitize, this.options.baseUrl, r); + if (o === null) + return i; + r = o; + let u = '
    ", u; + } + image(r, a, i) { + const o = $l(this.options.sanitize, this.options.baseUrl, r); + if (o === null) + return i; + r = o; + let u = `${i}" : ">", u; + } + text(r) { + return r; + } +} +class ii { + // no need for block level renderers + strong(r) { + return r; + } + em(r) { + return r; + } + codespan(r) { + return r; + } + del(r) { + return r; + } + html(r) { + return r; + } + text(r) { + return r; + } + link(r, a, i) { + return "" + i; + } + image(r, a, i) { + return "" + i; + } + br() { + return ""; + } +} +class li { + constructor() { + Fe(this, "seen"); + this.seen = {}; + } + serialize(r) { + return r.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig, "").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g, "").replace(/\s/g, "-"); + } + /** + * Finds the next safe (unique) slug to use + */ + getNextSafeSlug(r, a) { + let i = r, o = 0; + if (this.seen.hasOwnProperty(i)) { + o = this.seen[r]; + do + o++, i = r + "-" + o; + while (this.seen.hasOwnProperty(i)); + } + return a || (this.seen[r] = o, this.seen[i] = 0), i; + } + /** + * Convert string to unique id + */ + slug(r, a = {}) { + const i = this.serialize(r); + return this.getNextSafeSlug(i, a.dryrun); + } +} +class n0 { + constructor(r) { + Fe(this, "options"); + Fe(this, "renderer"); + Fe(this, "textRenderer"); + Fe(this, "slugger"); + this.options = r || tr, this.options.renderer = this.options.renderer || new Ln(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.textRenderer = new ii(), this.slugger = new li(); + } + /** + * Static Parse Method + */ + static parse(r, a) { + return new n0(a).parse(r); + } + /** + * Static Parse Inline Method + */ + static parseInline(r, a) { + return new n0(a).parseInline(r); + } + /** + * Parse Loop + */ + parse(r, a = !0) { + let i = ""; + for (let o = 0; o < r.length; o++) { + const u = r[o]; + if (this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[u.type]) { + const g = u, p = this.options.extensions.renderers[g.type].call({ parser: this }, g); + if (p !== !1 || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(g.type)) { + i += p || ""; + continue; + } + } + switch (u.type) { + case "space": + continue; + case "hr": { + i += this.renderer.hr(); + continue; + } + case "heading": { + const g = u; + i += this.renderer.heading(this.parseInline(g.tokens), g.depth, Ao(this.parseInline(g.tokens, this.textRenderer)), this.slugger); + continue; + } + case "code": { + const g = u; + i += this.renderer.code(g.text, g.lang, !!g.escaped); + continue; + } + case "table": { + const g = u; + let p = "", v = ""; + for (let S = 0; S < g.header.length; S++) + v += this.renderer.tablecell(this.parseInline(g.header[S].tokens), { header: !0, align: g.align[S] }); + p += this.renderer.tablerow(v); + let w = ""; + for (let S = 0; S < g.rows.length; S++) { + const L = g.rows[S]; + v = ""; + for (let O = 0; O < L.length; O++) + v += this.renderer.tablecell(this.parseInline(L[O].tokens), { header: !1, align: g.align[O] }); + w += this.renderer.tablerow(v); + } + i += this.renderer.table(p, w); + continue; + } + case "blockquote": { + const g = u, p = this.parse(g.tokens); + i += this.renderer.blockquote(p); + continue; + } + case "list": { + const g = u, p = g.ordered, v = g.start, w = g.loose; + let S = ""; + for (let L = 0; L < g.items.length; L++) { + const O = g.items[L], X = O.checked, I = O.task; + let ne = ""; + if (O.task) { + const re = this.renderer.checkbox(!!X); + w ? O.tokens.length > 0 && O.tokens[0].type === "paragraph" ? (O.tokens[0].text = re + " " + O.tokens[0].text, O.tokens[0].tokens && O.tokens[0].tokens.length > 0 && O.tokens[0].tokens[0].type === "text" && (O.tokens[0].tokens[0].text = re + " " + O.tokens[0].tokens[0].text)) : O.tokens.unshift({ + type: "text", + text: re + }) : ne += re; + } + ne += this.parse(O.tokens, w), S += this.renderer.listitem(ne, I, !!X); + } + i += this.renderer.list(S, p, v); + continue; + } + case "html": { + const g = u; + i += this.renderer.html(g.text, g.block); + continue; + } + case "paragraph": { + const g = u; + i += this.renderer.paragraph(this.parseInline(g.tokens)); + continue; + } + case "text": { + let g = u, p = g.tokens ? this.parseInline(g.tokens) : g.text; + for (; o + 1 < r.length && r[o + 1].type === "text"; ) + g = r[++o], p += ` +` + (g.tokens ? this.parseInline(g.tokens) : g.text); + i += a ? this.renderer.paragraph(p) : p; + continue; + } + default: { + const g = 'Token with "' + u.type + '" type was not found.'; + if (this.options.silent) + return console.error(g), ""; + throw new Error(g); + } + } + } + return i; + } + /** + * Parse Inline Tokens + */ + parseInline(r, a) { + a = a || this.renderer; + let i = ""; + for (let o = 0; o < r.length; o++) { + const u = r[o]; + if (this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[u.type]) { + const g = this.options.extensions.renderers[u.type].call({ parser: this }, u); + if (g !== !1 || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(u.type)) { + i += g || ""; + continue; + } + } + switch (u.type) { + case "escape": { + const g = u; + i += a.text(g.text); + break; + } + case "html": { + const g = u; + i += a.html(g.text); + break; + } + case "link": { + const g = u; + i += a.link(g.href, g.title, this.parseInline(g.tokens, a)); + break; + } + case "image": { + const g = u; + i += a.image(g.href, g.title, g.text); + break; + } + case "strong": { + const g = u; + i += a.strong(this.parseInline(g.tokens, a)); + break; + } + case "em": { + const g = u; + i += a.em(this.parseInline(g.tokens, a)); + break; + } + case "codespan": { + const g = u; + i += a.codespan(g.text); + break; + } + case "br": { + i += a.br(); + break; + } + case "del": { + const g = u; + i += a.del(this.parseInline(g.tokens, a)); + break; + } + case "text": { + const g = u; + i += a.text(g.text); + break; + } + default: { + const g = 'Token with "' + u.type + '" type was not found.'; + if (this.options.silent) + return console.error(g), ""; + throw new Error(g); + } + } + } + return i; + } +} +class Ur { + constructor(r) { + Fe(this, "options"); + this.options = r || tr; + } + /** + * Process markdown before marked + */ + preprocess(r) { + return r; + } + /** + * Process HTML after marked is finished + */ + postprocess(r) { + return r; + } +} +Fe(Ur, "passThroughHooks", /* @__PURE__ */ new Set([ + "preprocess", + "postprocess" +])); +var Gr, ei, Pn, To; +class $4 { + constructor(...r) { + Ca(this, Gr); + Ca(this, Pn); + Fe(this, "defaults", ai()); + Fe(this, "options", this.setOptions); + Fe(this, "parse", bn(this, Gr, ei).call(this, r0.lex, n0.parse)); + Fe(this, "parseInline", bn(this, Gr, ei).call(this, r0.lexInline, n0.parseInline)); + Fe(this, "Parser", n0); + Fe(this, "parser", n0.parse); + Fe(this, "Renderer", Ln); + Fe(this, "TextRenderer", ii); + Fe(this, "Lexer", r0); + Fe(this, "lexer", r0.lex); + Fe(this, "Tokenizer", Fn); + Fe(this, "Slugger", li); + Fe(this, "Hooks", Ur); + this.use(...r); + } + /** + * Run callback for every token + */ + walkTokens(r, a) { + var o, u; + let i = []; + for (const g of r) + switch (i = i.concat(a.call(this, g)), g.type) { + case "table": { + const p = g; + for (const v of p.header) + i = i.concat(this.walkTokens(v.tokens, a)); + for (const v of p.rows) + for (const w of v) + i = i.concat(this.walkTokens(w.tokens, a)); + break; + } + case "list": { + const p = g; + i = i.concat(this.walkTokens(p.items, a)); + break; + } + default: { + const p = g; + (u = (o = this.defaults.extensions) == null ? void 0 : o.childTokens) != null && u[p.type] ? this.defaults.extensions.childTokens[p.type].forEach((v) => { + i = i.concat(this.walkTokens(p[v], a)); + }) : p.tokens && (i = i.concat(this.walkTokens(p.tokens, a))); + } + } + return i; + } + use(...r) { + const a = this.defaults.extensions || { renderers: {}, childTokens: {} }; + return r.forEach((i) => { + const o = { ...i }; + if (o.async = this.defaults.async || o.async || !1, i.extensions && (i.extensions.forEach((u) => { + if (!u.name) + throw new Error("extension name required"); + if ("renderer" in u) { + const g = a.renderers[u.name]; + g ? a.renderers[u.name] = function(...p) { + let v = u.renderer.apply(this, p); + return v === !1 && (v = g.apply(this, p)), v; + } : a.renderers[u.name] = u.renderer; + } + if ("tokenizer" in u) { + if (!u.level || u.level !== "block" && u.level !== "inline") + throw new Error("extension level must be 'block' or 'inline'"); + const g = a[u.level]; + g ? g.unshift(u.tokenizer) : a[u.level] = [u.tokenizer], u.start && (u.level === "block" ? a.startBlock ? a.startBlock.push(u.start) : a.startBlock = [u.start] : u.level === "inline" && (a.startInline ? a.startInline.push(u.start) : a.startInline = [u.start])); + } + "childTokens" in u && u.childTokens && (a.childTokens[u.name] = u.childTokens); + }), o.extensions = a), i.renderer) { + const u = this.defaults.renderer || new Ln(this.defaults); + for (const g in i.renderer) { + const p = i.renderer[g], v = g, w = u[v]; + u[v] = (...S) => { + let L = p.apply(u, S); + return L === !1 && (L = w.apply(u, S)), L || ""; + }; + } + o.renderer = u; + } + if (i.tokenizer) { + const u = this.defaults.tokenizer || new Fn(this.defaults); + for (const g in i.tokenizer) { + const p = i.tokenizer[g], v = g, w = u[v]; + u[v] = (...S) => { + let L = p.apply(u, S); + return L === !1 && (L = w.apply(u, S)), L; + }; + } + o.tokenizer = u; + } + if (i.hooks) { + const u = this.defaults.hooks || new Ur(); + for (const g in i.hooks) { + const p = i.hooks[g], v = g, w = u[v]; + Ur.passThroughHooks.has(g) ? u[v] = (S) => { + if (this.defaults.async) + return Promise.resolve(p.call(u, S)).then((O) => w.call(u, O)); + const L = p.call(u, S); + return w.call(u, L); + } : u[v] = (...S) => { + let L = p.apply(u, S); + return L === !1 && (L = w.apply(u, S)), L; + }; + } + o.hooks = u; + } + if (i.walkTokens) { + const u = this.defaults.walkTokens, g = i.walkTokens; + o.walkTokens = function(p) { + let v = []; + return v.push(g.call(this, p)), u && (v = v.concat(u.call(this, p))), v; + }; + } + this.defaults = { ...this.defaults, ...o }; + }), this; + } + setOptions(r) { + return this.defaults = { ...this.defaults, ...r }, this; + } +} +Gr = new WeakSet(), ei = function(r, a) { + return (i, o, u) => { + typeof o == "function" && (u = o, o = null); + const g = { ...o }, p = { ...this.defaults, ...g }; + this.defaults.async === !0 && g.async === !1 && (p.silent || console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."), p.async = !0); + const v = bn(this, Pn, To).call(this, !!p.silent, !!p.async, u); + if (typeof i > "u" || i === null) + return v(new Error("marked(): input parameter is undefined or null")); + if (typeof i != "string") + return v(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(i) + ", string expected")); + if (K4(p, u), p.hooks && (p.hooks.options = p), u) { + const w = u, S = p.highlight; + let L; + try { + p.hooks && (i = p.hooks.preprocess(i)), L = r(i, p); + } catch (I) { + return v(I); + } + const O = (I) => { + let ne; + if (!I) + try { + p.walkTokens && this.walkTokens(L, p.walkTokens), ne = a(L, p), p.hooks && (ne = p.hooks.postprocess(ne)); + } catch (re) { + I = re; + } + return p.highlight = S, I ? v(I) : w(null, ne); + }; + if (!S || S.length < 3 || (delete p.highlight, !L.length)) + return O(); + let X = 0; + this.walkTokens(L, (I) => { + I.type === "code" && (X++, setTimeout(() => { + S(I.text, I.lang, (ne, re) => { + if (ne) + return O(ne); + re != null && re !== I.text && (I.text = re, I.escaped = !0), X--, X === 0 && O(); + }); + }, 0)); + }), X === 0 && O(); + return; + } + if (p.async) + return Promise.resolve(p.hooks ? p.hooks.preprocess(i) : i).then((w) => r(w, p)).then((w) => p.walkTokens ? Promise.all(this.walkTokens(w, p.walkTokens)).then(() => w) : w).then((w) => a(w, p)).then((w) => p.hooks ? p.hooks.postprocess(w) : w).catch(v); + try { + p.hooks && (i = p.hooks.preprocess(i)); + const w = r(i, p); + p.walkTokens && this.walkTokens(w, p.walkTokens); + let S = a(w, p); + return p.hooks && (S = p.hooks.postprocess(S)), S; + } catch (w) { + return v(w); + } + }; +}, Pn = new WeakSet(), To = function(r, a, i) { + return (o) => { + if (o.message += ` +Please report this to https://github.com/markedjs/marked.`, r) { + const u = "

    An error occurred:

    " + mt(o.message + "", !0) + "
    "; + if (a) + return Promise.resolve(u); + if (i) { + i(null, u); + return; + } + return u; + } + if (a) + return Promise.reject(o); + if (i) { + i(o); + return; + } + throw o; + }; +}; +const er = new $4(); +function De(s, r, a) { + return er.parse(s, r, a); +} +De.options = De.setOptions = function(s) { + return er.setOptions(s), De.defaults = er.defaults, _o(De.defaults), De; +}; +De.getDefaults = ai; +De.defaults = tr; +De.use = function(...s) { + return er.use(...s), De.defaults = er.defaults, _o(De.defaults), De; +}; +De.walkTokens = function(s, r) { + return er.walkTokens(s, r); +}; +De.parseInline = er.parseInline; +De.Parser = n0; +De.parser = n0.parse; +De.Renderer = Ln; +De.TextRenderer = ii; +De.Lexer = r0; +De.lexer = r0.lex; +De.Tokenizer = Fn; +De.Slugger = li; +De.Hooks = Ur; +De.parse = De; +De.options; +De.setOptions; +De.use; +De.walkTokens; +De.parseInline; +n0.parse; +r0.lex; +function eh(s) { + if (typeof s == "function" && (s = { + highlight: s + }), !s || typeof s.highlight != "function") + throw new Error("Must provide highlight function"); + return typeof s.langPrefix != "string" && (s.langPrefix = "language-"), { + async: !!s.async, + walkTokens(r) { + if (r.type !== "code") + return; + const a = th(r); + if (s.async) + return Promise.resolve(s.highlight(r.text, a)).then(ns(r)); + const i = s.highlight(r.text, a); + if (i instanceof Promise) + throw new Error("markedHighlight is not set to async but the highlight function is async. Set the async option to true on markedHighlight to await the async highlight function."); + ns(r)(i); + }, + renderer: { + code(r, a, i) { + const o = (a || "").match(/\S*/)[0], u = o ? ` class="${s.langPrefix}${is(o)}"` : ""; + return r = r.replace(/\n$/, ""), `
    ${i ? r : is(r, !0)}
    +
    `; + } + } + }; +} +function th(s) { + return (s.lang || "").match(/\S*/)[0]; +} +function ns(s) { + return (r) => { + typeof r == "string" && r !== s.text && (s.escaped = !0, s.text = r); + }; +} +const Mo = /[&<>"']/, rh = new RegExp(Mo.source, "g"), zo = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, nh = new RegExp(zo.source, "g"), ah = { + "&": "&", + "<": "<", + ">": ">", + '"': """, + "'": "'" +}, as = (s) => ah[s]; +function is(s, r) { + if (r) { + if (Mo.test(s)) + return s.replace(rh, as); + } else if (zo.test(s)) + return s.replace(nh, as); + return s; +} +var Co = { exports: {} }; +(function(s) { + var r = typeof window < "u" ? window : typeof WorkerGlobalScope < "u" && self instanceof WorkerGlobalScope ? self : {}; + /** + * Prism: Lightweight, robust, elegant syntax highlighting + * + * @license MIT + * @author Lea Verou + * @namespace + * @public + */ + var a = function(i) { + var o = /(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i, u = 0, g = {}, p = { + /** + * By default, Prism will attempt to highlight all code elements (by calling {@link Prism.highlightAll}) on the + * current page after the page finished loading. This might be a problem if e.g. you wanted to asynchronously load + * additional languages or plugins yourself. + * + * By setting this value to `true`, Prism will not automatically highlight all code elements on the page. + * + * You obviously have to change this value before the automatic highlighting started. To do this, you can add an + * empty Prism object into the global scope before loading the Prism script like this: + * + * ```js + * window.Prism = window.Prism || {}; + * Prism.manual = true; + * // add a new