@opentiny/tiny-robot 0.3.0-alpha.37 → 0.3.0-alpha.38

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,15 +1,15 @@
1
- var pn = Object.defineProperty;
2
- var bn = (u, e, t) => e in u ? pn(u, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : u[e] = t;
3
- var Ou = (u, e, t) => bn(u, typeof e != "symbol" ? e + "" : e, t);
4
- import { defineComponent as yu, ref as s0, createElementBlock as H, openBlock as S, createElementVNode as Z, createVNode as Dt, toDisplayString as Cu, unref as l0, normalizeClass as Au, withDirectives as mn, vShow as _n, computed as X, useCssModule as xn, createCommentVNode as Bu, createBlock as eu, resolveDynamicComponent as _u, createTextVNode as gn, inject as W0, normalizeProps as Ce, mergeProps as Ku, h as Z0, useSlots as kn, useAttrs as En, normalizeStyle as An, renderSlot as Qu, Fragment as De, renderList as Ee, watch as Cn, nextTick as Dn, createSlots as V0, withCtx as Y0, guardReactiveProps as yn, provide as X0 } from "vue";
1
+ var bn = Object.defineProperty;
2
+ var pn = (u, e, t) => e in u ? bn(u, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : u[e] = t;
3
+ var Ou = (u, e, t) => pn(u, typeof e != "symbol" ? e + "" : e, t);
4
+ import { defineComponent as Fu, ref as s0, createElementBlock as W, openBlock as v, createElementVNode as Y, createVNode as Ct, toDisplayString as Du, unref as l0, normalizeClass as Cu, withDirectives as _n, vShow as mn, computed as X, useCssModule as xn, createCommentVNode as Qu, createBlock as hu, resolveDynamicComponent as Pu, createTextVNode as gn, inject as G0, h as xu, useSlots as kn, useAttrs as En, normalizeStyle as An, renderSlot as ke, Fragment as Dt, renderList as Ee, watch as Cn, nextTick as Dn, mergeProps as $e, createSlots as W0, withCtx as Z0, normalizeProps as V0, guardReactiveProps as yn, provide as Y0 } from "vue";
5
5
  import { _ as Fn } from "../loading.js";
6
6
  import { t as Tn } from "../utils.js";
7
- import { IconArrowUp as Sn, IconPlugin as J0, IconArrowDown as wn, IconLoading as vn, IconError as Rn, IconCancelled as In } from "@opentiny/tiny-robot-svgs";
7
+ import { IconArrowUp as Sn, IconPlugin as X0, IconArrowDown as wn, IconLoading as vn, IconError as Rn, IconCancelled as In } from "@opentiny/tiny-robot-svgs";
8
8
  import { _ as ce } from "../_plugin-vue_export-helper.js";
9
9
  import { u as Mn } from "../index3.js";
10
10
  class f0 {
11
11
  }
12
- const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-text-title" }, Nn = { class: "tr-bubble__step-text-content-wrapper" }, Bn = /* @__PURE__ */ yu({
12
+ const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-text-title" }, Nn = { class: "tr-bubble__step-text-content-wrapper" }, Bn = /* @__PURE__ */ Fu({
13
13
  __name: "collapsible-text",
14
14
  props: {
15
15
  title: {},
@@ -18,34 +18,34 @@ const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-tex
18
18
  },
19
19
  setup(u) {
20
20
  const e = u, t = s0(e.defaultOpen ?? !1);
21
- return (n, r) => (S(), H("div", Ln, [
22
- Z("div", On, [
23
- Z("span", null, Cu(e.title), 1),
24
- Dt(l0(Sn), {
25
- class: Au(["expand-icon", { "rotate-180": !t.value }]),
26
- onClick: r[0] || (r[0] = (o) => t.value = !t.value)
21
+ return (n, r) => (v(), W("div", Ln, [
22
+ Y("div", On, [
23
+ Y("span", null, Du(e.title), 1),
24
+ Ct(l0(Sn), {
25
+ class: Cu(["expand-icon", { "rotate-180": !t.value }]),
26
+ onClick: r[0] || (r[0] = (c) => t.value = !t.value)
27
27
  }, null, 8, ["class"])
28
28
  ]),
29
- Z("div", Nn, [
30
- mn(Z("div", { class: "tr-bubble__step-text-content" }, Cu(e.content), 513), [
31
- [_n, t.value]
29
+ Y("div", Nn, [
30
+ _n(Y("div", { class: "tr-bubble__step-text-content" }, Du(e.content), 513), [
31
+ [mn, t.value]
32
32
  ])
33
33
  ])
34
34
  ]));
35
35
  }
36
- }), Pn = /* @__PURE__ */ ce(Bn, [["__scopeId", "data-v-c614ffd3"]]), zn = Pn, qn = { class: "tr-bubble__text" }, Un = /* @__PURE__ */ yu({
36
+ }), Pn = /* @__PURE__ */ ce(Bn, [["__scopeId", "data-v-c614ffd3"]]), zn = Pn, qn = { class: "tr-bubble__text" }, Un = /* @__PURE__ */ Fu({
37
37
  __name: "text",
38
38
  props: {
39
39
  content: {}
40
40
  },
41
41
  setup(u) {
42
42
  const e = u;
43
- return (t, n) => (S(), H("span", qn, Cu(e.content), 1));
43
+ return (t, n) => (v(), W("span", qn, Du(e.content), 1));
44
44
  }
45
45
  }), Hn = /* @__PURE__ */ ce(Un, [["__scopeId", "data-v-ddb66b72"]]), d0 = Hn, $n = { class: "tr-bubble__step-tool" }, jn = { class: "tr-bubble__step-tool-header" }, Gn = { class: "tr-bubble__step-tool-left" }, Wn = { class: "tr-bubble__step-tool-title" }, Zn = { class: "tr-bubble__step-tool-name" }, Vn = { class: "tr-bubble__step-tool-expand" }, Yn = {
46
46
  key: 0,
47
47
  class: "tr-bubble__step-tool-params"
48
- }, Xn = ["innerHTML"], Jn = /* @__PURE__ */ yu({
48
+ }, Xn = ["innerHTML"], Jn = /* @__PURE__ */ Fu({
49
49
  __name: "tool",
50
50
  props: {
51
51
  name: {},
@@ -57,16 +57,16 @@ const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-tex
57
57
  setup(u) {
58
58
  const e = u, t = s0(e.defaultOpen ?? !1), n = /* @__PURE__ */ new Map([
59
59
  ["running", { text: "正在调用", icon: vn }],
60
- ["success", { text: "已调用", icon: J0 }],
60
+ ["success", { text: "已调用", icon: X0 }],
61
61
  ["failed", { text: "调用失败", icon: Rn }],
62
62
  ["cancelled", { text: "已取消", icon: In }]
63
- ]), r = X(() => n.get(e.status) || { text: "", icon: J0 }), o = xn(), i = (c) => {
64
- if (!c)
63
+ ]), r = X(() => n.get(e.status) || { text: "", icon: X0 }), c = xn(), i = (o) => {
64
+ if (!o)
65
65
  return "";
66
66
  let a = "";
67
67
  const s = e.formatPretty ? 2 : 0;
68
68
  try {
69
- typeof c == "string" ? a = JSON.stringify(JSON.parse(c), null, s) : a = JSON.stringify(c, null, s);
69
+ typeof o == "string" ? a = JSON.stringify(JSON.parse(o), null, s) : a = JSON.stringify(o, null, s);
70
70
  } catch (f) {
71
71
  console.warn(f);
72
72
  }
@@ -74,35 +74,35 @@ const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-tex
74
74
  /("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)/g,
75
75
  (f) => {
76
76
  let d = "number";
77
- return /^"/.test(f) ? d = /:$/.test(f) ? "key" : "string" : /true|false/.test(f) ? d = "boolean" : /null/.test(f) && (d = "null"), `<span class="${o[d]}">${f}</span>`;
77
+ return /^"/.test(f) ? d = /:$/.test(f) ? "key" : "string" : /true|false/.test(f) ? d = "boolean" : /null/.test(f) && (d = "null"), `<span class="${c[d]}">${f}</span>`;
78
78
  }
79
79
  ), a;
80
80
  };
81
- return (c, a) => (S(), H("div", $n, [
82
- Z("div", jn, [
83
- Z("div", Gn, [
84
- (S(), eu(_u(r.value.icon), {
85
- class: Au(["tr-bubble__step-tool-icon", `icon-${e.status}`])
81
+ return (o, a) => (v(), W("div", $n, [
82
+ Y("div", jn, [
83
+ Y("div", Gn, [
84
+ (v(), hu(Pu(r.value.icon), {
85
+ class: Cu(["tr-bubble__step-tool-icon", `icon-${e.status}`])
86
86
  }, null, 8, ["class"])),
87
- Z("span", Wn, [
88
- gn(Cu(r.value.text) + " ", 1),
89
- Z("span", Zn, Cu(e.name), 1)
87
+ Y("span", Wn, [
88
+ gn(Du(r.value.text) + " ", 1),
89
+ Y("span", Zn, Du(e.name), 1)
90
90
  ])
91
91
  ]),
92
- Z("div", Vn, [
93
- Dt(l0(wn), {
94
- class: Au(["expand-icon", { "-rotate-90": !t.value }]),
92
+ Y("div", Vn, [
93
+ Ct(l0(wn), {
94
+ class: Cu(["expand-icon", { "-rotate-90": !t.value }]),
95
95
  onClick: a[0] || (a[0] = (s) => t.value = !t.value)
96
96
  }, null, 8, ["class"])
97
97
  ])
98
98
  ]),
99
- t.value ? (S(), H("div", Yn, [
100
- a[1] || (a[1] = Z("hr", { class: "tr-bubble__step-tool-hr" }, null, -1)),
101
- Z("div", {
99
+ t.value ? (v(), W("div", Yn, [
100
+ a[1] || (a[1] = Y("hr", { class: "tr-bubble__step-tool-hr" }, null, -1)),
101
+ Y("div", {
102
102
  class: "tr-bubble__step-tool-params-content",
103
103
  innerHTML: i(e.content)
104
104
  }, null, 8, Xn)
105
- ])) : Bu("", !0)
105
+ ])) : Qu("", !0)
106
106
  ]));
107
107
  }
108
108
  }), Qn = "_key_1b448_2", Kn = "_number_1b448_6", ur = "_string_1b448_10", er = "_boolean_1b448_14", tr = {
@@ -113,57 +113,61 @@ const Ln = { class: "tr-bubble__step-text" }, On = { class: "tr-bubble__step-tex
113
113
  null: "_null_1b448_18"
114
114
  }, nr = {
115
115
  $style: tr
116
- }, rr = /* @__PURE__ */ ce(Jn, [["__cssModules", nr], ["__scopeId", "data-v-1c37a4c4"]]), or = rr, yt = /* @__PURE__ */ new Map([
116
+ }, rr = /* @__PURE__ */ ce(Jn, [["__cssModules", nr], ["__scopeId", "data-v-1c37a4c4"]]), cr = rr, yt = /* @__PURE__ */ new Map([
117
117
  ["text", d0],
118
- ["tool", or],
118
+ ["tool", cr],
119
119
  ["collapsible-text", zn]
120
- ]), Ft = Symbol("bubbleContentRendererMap"), Tt = Symbol("bubbleContentFallbackRenderer"), cr = /* @__PURE__ */ yu({
120
+ ]), Ft = Symbol("bubbleContentRendererMap"), Tt = Symbol("bubbleContentFallbackRenderer"), or = /* @__PURE__ */ Fu({
121
121
  __name: "ContentItem",
122
122
  props: {
123
123
  item: {}
124
124
  },
125
125
  setup(u) {
126
- const e = W0(Ft, yt), t = W0(Tt, d0), n = u, r = (i) => {
127
- const c = e.get(i) || t;
128
- return typeof c == "function" ? { isComponent: !1, vNodeOrComponent: c(n.item) } : c instanceof f0 ? { isComponent: !1, vNodeOrComponent: c.render(n.item) } : { isComponent: !0, vNodeOrComponent: c };
129
- }, o = X(() => r(n.item.type));
130
- return (i, c) => o.value.isComponent ? (S(), eu(_u(o.value.vNodeOrComponent), Ce(Ku({ key: 0 }, n.item)), null, 16)) : (S(), eu(_u(o.value.vNodeOrComponent), { key: 1 }));
126
+ const e = G0(Ft, yt), t = G0(Tt, d0), n = u, r = (i) => {
127
+ const o = e.get(i) || t;
128
+ if (typeof o == "function") {
129
+ const a = o;
130
+ return xu(() => a(n.item));
131
+ }
132
+ return o instanceof f0 ? xu(() => o.render(n.item)) : xu(o, n.item);
133
+ }, c = X(() => r(n.item.type));
134
+ return (i, o) => (v(), hu(Pu(c.value)));
131
135
  }
132
136
  });
133
- /*! @license DOMPurify 3.3.0 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.0/LICENSE */
137
+ /*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */
134
138
  const {
135
139
  entries: St,
136
- setPrototypeOf: Q0,
140
+ setPrototypeOf: J0,
137
141
  isFrozen: ir,
138
142
  getPrototypeOf: ar,
139
143
  getOwnPropertyDescriptor: sr
140
144
  } = Object;
141
145
  let {
142
- freeze: j,
146
+ freeze: $,
143
147
  seal: Q,
144
148
  create: n0
145
149
  } = Object, {
146
150
  apply: r0,
147
- construct: o0
151
+ construct: c0
148
152
  } = typeof Reflect < "u" && Reflect;
149
- j || (j = function(e) {
153
+ $ || ($ = function(e) {
150
154
  return e;
151
155
  });
152
156
  Q || (Q = function(e) {
153
157
  return e;
154
158
  });
155
159
  r0 || (r0 = function(e, t) {
156
- for (var n = arguments.length, r = new Array(n > 2 ? n - 2 : 0), o = 2; o < n; o++)
157
- r[o - 2] = arguments[o];
160
+ for (var n = arguments.length, r = new Array(n > 2 ? n - 2 : 0), c = 2; c < n; c++)
161
+ r[c - 2] = arguments[c];
158
162
  return e.apply(t, r);
159
163
  });
160
- o0 || (o0 = function(e) {
164
+ c0 || (c0 = function(e) {
161
165
  for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), r = 1; r < t; r++)
162
166
  n[r - 1] = arguments[r];
163
167
  return new e(...n);
164
168
  });
165
- const _e = G(Array.prototype.forEach), lr = G(Array.prototype.lastIndexOf), K0 = G(Array.prototype.pop), Zu = G(Array.prototype.push), fr = G(Array.prototype.splice), Ae = G(String.prototype.toLowerCase), je = G(String.prototype.toString), Ge = G(String.prototype.match), Vu = G(String.prototype.replace), dr = G(String.prototype.indexOf), hr = G(String.prototype.trim), uu = G(Object.prototype.hasOwnProperty), $ = G(RegExp.prototype.test), Yu = pr(TypeError);
166
- function G(u) {
169
+ const _e = j(Array.prototype.forEach), lr = j(Array.prototype.lastIndexOf), Q0 = j(Array.prototype.pop), Zu = j(Array.prototype.push), fr = j(Array.prototype.splice), Ae = j(String.prototype.toLowerCase), je = j(String.prototype.toString), Ge = j(String.prototype.match), Vu = j(String.prototype.replace), dr = j(String.prototype.indexOf), hr = j(String.prototype.trim), uu = j(Object.prototype.hasOwnProperty), H = j(RegExp.prototype.test), Yu = br(TypeError);
170
+ function j(u) {
167
171
  return function(e) {
168
172
  e instanceof RegExp && (e.lastIndex = 0);
169
173
  for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), r = 1; r < t; r++)
@@ -171,36 +175,36 @@ function G(u) {
171
175
  return r0(u, e, n);
172
176
  };
173
177
  }
174
- function pr(u) {
178
+ function br(u) {
175
179
  return function() {
176
180
  for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++)
177
181
  t[n] = arguments[n];
178
- return o0(u, t);
182
+ return c0(u, t);
179
183
  };
180
184
  }
181
- function F(u, e) {
185
+ function D(u, e) {
182
186
  let t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Ae;
183
- Q0 && Q0(u, null);
187
+ J0 && J0(u, null);
184
188
  let n = e.length;
185
189
  for (; n--; ) {
186
190
  let r = e[n];
187
191
  if (typeof r == "string") {
188
- const o = t(r);
189
- o !== r && (ir(e) || (e[n] = o), r = o);
192
+ const c = t(r);
193
+ c !== r && (ir(e) || (e[n] = c), r = c);
190
194
  }
191
195
  u[r] = !0;
192
196
  }
193
197
  return u;
194
198
  }
195
- function br(u) {
199
+ function pr(u) {
196
200
  for (let e = 0; e < u.length; e++)
197
201
  uu(u, e) || (u[e] = null);
198
202
  return u;
199
203
  }
200
- function du(u) {
204
+ function cu(u) {
201
205
  const e = n0(null);
202
206
  for (const [t, n] of St(u))
203
- uu(u, t) && (Array.isArray(n) ? e[t] = br(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = du(n) : e[t] = n);
207
+ uu(u, t) && (Array.isArray(n) ? e[t] = pr(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = cu(n) : e[t] = n);
204
208
  return e;
205
209
  }
206
210
  function Xu(u, e) {
@@ -208,9 +212,9 @@ function Xu(u, e) {
208
212
  const n = sr(u, e);
209
213
  if (n) {
210
214
  if (n.get)
211
- return G(n.get);
215
+ return j(n.get);
212
216
  if (typeof n.value == "function")
213
- return G(n.value);
217
+ return j(n.value);
214
218
  }
215
219
  u = ar(u);
216
220
  }
@@ -219,14 +223,14 @@ function Xu(u, e) {
219
223
  }
220
224
  return t;
221
225
  }
222
- const ut = j(["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", "search", "section", "select", "shadow", "slot", "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"]), We = j(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "enterkeyhint", "exportparts", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "inputmode", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "part", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), Ze = j(["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"]), mr = j(["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"]), Ve = j(["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"]), _r = j(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), et = j(["#text"]), tt = j(["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", "exportparts", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inert", "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", "part", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "slot", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns", "slot"]), Ye = j(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "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", "exponent", "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", "intercept", "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", "mask-type", "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", "slope", "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", "tablevalues", "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"]), nt = j(["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"]), xe = j(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), xr = Q(/\{\{[\w\W]*|[\w\W]*\}\}/gm), gr = Q(/<%[\w\W]*|[\w\W]*%>/gm), kr = Q(/\$\{[\w\W]*/gm), Er = Q(/^data-[\-\w.\u00B7-\uFFFF]+$/), Ar = Q(/^aria-[\-\w]+$/), wt = Q(
226
+ const K0 = $(["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", "search", "section", "select", "shadow", "slot", "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"]), We = $(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "enterkeyhint", "exportparts", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "inputmode", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "part", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), Ze = $(["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"]), _r = $(["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"]), Ve = $(["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"]), mr = $(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), ut = $(["#text"]), et = $(["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", "exportparts", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inert", "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", "part", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "slot", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns", "slot"]), Ye = $(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "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", "exponent", "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", "intercept", "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", "mask-type", "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", "slope", "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", "tablevalues", "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"]), tt = $(["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"]), me = $(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), xr = Q(/\{\{[\w\W]*|[\w\W]*\}\}/gm), gr = Q(/<%[\w\W]*|[\w\W]*%>/gm), kr = Q(/\$\{[\w\W]*/gm), Er = Q(/^data-[\-\w.\u00B7-\uFFFF]+$/), Ar = Q(/^aria-[\-\w]+$/), wt = Q(
223
227
  /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
224
228
  // eslint-disable-line no-useless-escape
225
229
  ), Cr = Q(/^(?:\w+script|data):/i), Dr = Q(
226
230
  /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
227
231
  // eslint-disable-line no-control-regex
228
232
  ), vt = Q(/^html$/i), yr = Q(/^[a-z][.\w]*(-[.\w]+)+$/i);
229
- var rt = /* @__PURE__ */ Object.freeze({
233
+ var nt = /* @__PURE__ */ Object.freeze({
230
234
  __proto__: null,
231
235
  ARIA_ATTR: Ar,
232
236
  ATTR_WHITESPACE: Dr,
@@ -254,9 +258,9 @@ const Ju = {
254
258
  let n = null;
255
259
  const r = "data-tt-policy-suffix";
256
260
  t && t.hasAttribute(r) && (n = t.getAttribute(r));
257
- const o = "dompurify" + (n ? "#" + n : "");
261
+ const c = "dompurify" + (n ? "#" + n : "");
258
262
  try {
259
- return e.createPolicy(o, {
263
+ return e.createPolicy(c, {
260
264
  createHTML(i) {
261
265
  return i;
262
266
  },
@@ -265,9 +269,9 @@ const Ju = {
265
269
  }
266
270
  });
267
271
  } catch {
268
- return console.warn("TrustedTypes policy " + o + " could not be created."), null;
272
+ return console.warn("TrustedTypes policy " + c + " could not be created."), null;
269
273
  }
270
- }, ot = function() {
274
+ }, rt = function() {
271
275
  return {
272
276
  afterSanitizeAttributes: [],
273
277
  afterSanitizeElements: [],
@@ -283,53 +287,53 @@ const Ju = {
283
287
  function Rt() {
284
288
  let u = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : Fr();
285
289
  const e = (g) => Rt(g);
286
- if (e.version = "3.3.0", e.removed = [], !u || !u.document || u.document.nodeType !== Ju.document || !u.Element)
290
+ if (e.version = "3.3.1", e.removed = [], !u || !u.document || u.document.nodeType !== Ju.document || !u.Element)
287
291
  return e.isSupported = !1, e;
288
292
  let {
289
293
  document: t
290
294
  } = u;
291
295
  const n = t, r = n.currentScript, {
292
- DocumentFragment: o,
296
+ DocumentFragment: c,
293
297
  HTMLTemplateElement: i,
294
- Node: c,
298
+ Node: o,
295
299
  Element: a,
296
300
  NodeFilter: s,
297
301
  NamedNodeMap: f = u.NamedNodeMap || u.MozNamedAttrMap,
298
302
  HTMLFormElement: d,
299
- DOMParser: m,
300
- trustedTypes: p
301
- } = u, h = a.prototype, C = Xu(h, "cloneNode"), D = Xu(h, "remove"), T = Xu(h, "nextSibling"), E = Xu(h, "childNodes"), k = Xu(h, "parentNode");
303
+ DOMParser: _,
304
+ trustedTypes: b
305
+ } = u, h = a.prototype, C = Xu(h, "cloneNode"), y = Xu(h, "remove"), T = Xu(h, "nextSibling"), E = Xu(h, "childNodes"), k = Xu(h, "parentNode");
302
306
  if (typeof i == "function") {
303
307
  const g = t.createElement("template");
304
308
  g.content && g.content.ownerDocument && (t = g.content.ownerDocument);
305
309
  }
306
- let _, A = "";
310
+ let m, A = "";
307
311
  const {
308
- implementation: y,
312
+ implementation: F,
309
313
  createNodeIterator: M,
310
- createDocumentFragment: Y,
311
- getElementsByTagName: nu
314
+ createDocumentFragment: V,
315
+ getElementsByTagName: tu
312
316
  } = t, {
313
- importNode: gu
317
+ importNode: ku
314
318
  } = n;
315
- let L = ot();
316
- e.isSupported = typeof St == "function" && typeof k == "function" && y && y.createHTMLDocument !== void 0;
319
+ let L = rt();
320
+ e.isSupported = typeof St == "function" && typeof k == "function" && F && F.createHTMLDocument !== void 0;
317
321
  const {
318
322
  MUSTACHE_EXPR: Hu,
319
323
  ERB_EXPR: $u,
320
- TMPLIT_EXPR: Fu,
321
- DATA_ATTR: hu,
322
- ARIA_ATTR: Ie,
324
+ TMPLIT_EXPR: Tu,
325
+ DATA_ATTR: bu,
326
+ ARIA_ATTR: ve,
323
327
  IS_SCRIPT_OR_DATA: nn,
324
328
  ATTR_WHITESPACE: E0,
325
329
  CUSTOM_ELEMENT: rn
326
- } = rt;
330
+ } = nt;
327
331
  let {
328
332
  IS_ALLOWED_URI: A0
329
- } = rt, O = null;
330
- const C0 = F({}, [...ut, ...We, ...Ze, ...Ve, ...et]);
333
+ } = nt, N = null;
334
+ const C0 = D({}, [...K0, ...We, ...Ze, ...Ve, ...ut]);
331
335
  let z = null;
332
- const D0 = F({}, [...tt, ...Ye, ...nt, ...xe]);
336
+ const D0 = D({}, [...et, ...Ye, ...tt, ...me]);
333
337
  let R = Object.seal(n0(null, {
334
338
  tagNameCheck: {
335
339
  writable: !0,
@@ -349,8 +353,8 @@ function Rt() {
349
353
  enumerable: !0,
350
354
  value: !1
351
355
  }
352
- })), ju = null, Me = null;
353
- const Tu = Object.seal(n0(null, {
356
+ })), ju = null, Re = null;
357
+ const Su = Object.seal(n0(null, {
354
358
  tagCheck: {
355
359
  writable: !0,
356
360
  configurable: !1,
@@ -364,45 +368,45 @@ function Rt() {
364
368
  value: null
365
369
  }
366
370
  }));
367
- let y0 = !0, Le = !0, F0 = !1, T0 = !0, Su = !1, le = !0, ku = !1, Oe = !1, Ne = !1, wu = !1, fe = !1, de = !1, S0 = !0, w0 = !1;
368
- const on = "user-content-";
369
- let Be = !0, Gu = !1, vu = {}, Ru = null;
370
- const v0 = F({}, ["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"]);
371
- let R0 = null;
372
- const I0 = F({}, ["audio", "video", "img", "source", "image", "track"]);
373
- let Pe = null;
374
- const M0 = F({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), he = "http://www.w3.org/1998/Math/MathML", pe = "http://www.w3.org/2000/svg", su = "http://www.w3.org/1999/xhtml";
375
- let Iu = su, ze = !1, qe = null;
376
- const cn = F({}, [he, pe, su], je);
377
- let be = F({}, ["mi", "mo", "mn", "ms", "mtext"]), me = F({}, ["annotation-xml"]);
378
- const an = F({}, ["title", "style", "font", "a", "script"]);
371
+ let y0 = !0, Ie = !0, F0 = !1, T0 = !0, wu = !1, se = !0, Eu = !1, Me = !1, Le = !1, vu = !1, le = !1, fe = !1, S0 = !0, w0 = !1;
372
+ const cn = "user-content-";
373
+ let Oe = !0, Gu = !1, Ru = {}, nu = null;
374
+ const Ne = D({}, ["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"]);
375
+ let v0 = null;
376
+ const R0 = D({}, ["audio", "video", "img", "source", "image", "track"]);
377
+ let Be = null;
378
+ const I0 = D({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), de = "http://www.w3.org/1998/Math/MathML", he = "http://www.w3.org/2000/svg", lu = "http://www.w3.org/1999/xhtml";
379
+ let Iu = lu, Pe = !1, ze = null;
380
+ const on = D({}, [de, he, lu], je);
381
+ let be = D({}, ["mi", "mo", "mn", "ms", "mtext"]), pe = D({}, ["annotation-xml"]);
382
+ const an = D({}, ["title", "style", "font", "a", "script"]);
379
383
  let Wu = null;
380
384
  const sn = ["application/xhtml+xml", "text/html"], ln = "text/html";
381
- let N = null, Mu = null;
382
- const fn = t.createElement("form"), L0 = function(l) {
385
+ let O = null, Mu = null;
386
+ const fn = t.createElement("form"), M0 = function(l) {
383
387
  return l instanceof RegExp || l instanceof Function;
384
- }, Ue = function() {
388
+ }, qe = function() {
385
389
  let l = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
386
390
  if (!(Mu && Mu === l)) {
387
- if ((!l || typeof l != "object") && (l = {}), l = du(l), Wu = // eslint-disable-next-line unicorn/prefer-includes
388
- sn.indexOf(l.PARSER_MEDIA_TYPE) === -1 ? ln : l.PARSER_MEDIA_TYPE, N = Wu === "application/xhtml+xml" ? je : Ae, O = uu(l, "ALLOWED_TAGS") ? F({}, l.ALLOWED_TAGS, N) : C0, z = uu(l, "ALLOWED_ATTR") ? F({}, l.ALLOWED_ATTR, N) : D0, qe = uu(l, "ALLOWED_NAMESPACES") ? F({}, l.ALLOWED_NAMESPACES, je) : cn, Pe = uu(l, "ADD_URI_SAFE_ATTR") ? F(du(M0), l.ADD_URI_SAFE_ATTR, N) : M0, R0 = uu(l, "ADD_DATA_URI_TAGS") ? F(du(I0), l.ADD_DATA_URI_TAGS, N) : I0, Ru = uu(l, "FORBID_CONTENTS") ? F({}, l.FORBID_CONTENTS, N) : v0, ju = uu(l, "FORBID_TAGS") ? F({}, l.FORBID_TAGS, N) : du({}), Me = uu(l, "FORBID_ATTR") ? F({}, l.FORBID_ATTR, N) : du({}), vu = uu(l, "USE_PROFILES") ? l.USE_PROFILES : !1, y0 = l.ALLOW_ARIA_ATTR !== !1, Le = l.ALLOW_DATA_ATTR !== !1, F0 = l.ALLOW_UNKNOWN_PROTOCOLS || !1, T0 = l.ALLOW_SELF_CLOSE_IN_ATTR !== !1, Su = l.SAFE_FOR_TEMPLATES || !1, le = l.SAFE_FOR_XML !== !1, ku = l.WHOLE_DOCUMENT || !1, wu = l.RETURN_DOM || !1, fe = l.RETURN_DOM_FRAGMENT || !1, de = l.RETURN_TRUSTED_TYPE || !1, Ne = l.FORCE_BODY || !1, S0 = l.SANITIZE_DOM !== !1, w0 = l.SANITIZE_NAMED_PROPS || !1, Be = l.KEEP_CONTENT !== !1, Gu = l.IN_PLACE || !1, A0 = l.ALLOWED_URI_REGEXP || wt, Iu = l.NAMESPACE || su, be = l.MATHML_TEXT_INTEGRATION_POINTS || be, me = l.HTML_INTEGRATION_POINTS || me, R = l.CUSTOM_ELEMENT_HANDLING || {}, l.CUSTOM_ELEMENT_HANDLING && L0(l.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (R.tagNameCheck = l.CUSTOM_ELEMENT_HANDLING.tagNameCheck), l.CUSTOM_ELEMENT_HANDLING && L0(l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (R.attributeNameCheck = l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), l.CUSTOM_ELEMENT_HANDLING && typeof l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (R.allowCustomizedBuiltInElements = l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), Su && (Le = !1), fe && (wu = !0), vu && (O = F({}, et), z = [], vu.html === !0 && (F(O, ut), F(z, tt)), vu.svg === !0 && (F(O, We), F(z, Ye), F(z, xe)), vu.svgFilters === !0 && (F(O, Ze), F(z, Ye), F(z, xe)), vu.mathMl === !0 && (F(O, Ve), F(z, nt), F(z, xe))), l.ADD_TAGS && (typeof l.ADD_TAGS == "function" ? Tu.tagCheck = l.ADD_TAGS : (O === C0 && (O = du(O)), F(O, l.ADD_TAGS, N))), l.ADD_ATTR && (typeof l.ADD_ATTR == "function" ? Tu.attributeCheck = l.ADD_ATTR : (z === D0 && (z = du(z)), F(z, l.ADD_ATTR, N))), l.ADD_URI_SAFE_ATTR && F(Pe, l.ADD_URI_SAFE_ATTR, N), l.FORBID_CONTENTS && (Ru === v0 && (Ru = du(Ru)), F(Ru, l.FORBID_CONTENTS, N)), Be && (O["#text"] = !0), ku && F(O, ["html", "head", "body"]), O.table && (F(O, ["tbody"]), delete ju.tbody), l.TRUSTED_TYPES_POLICY) {
391
+ if ((!l || typeof l != "object") && (l = {}), l = cu(l), Wu = // eslint-disable-next-line unicorn/prefer-includes
392
+ sn.indexOf(l.PARSER_MEDIA_TYPE) === -1 ? ln : l.PARSER_MEDIA_TYPE, O = Wu === "application/xhtml+xml" ? je : Ae, N = uu(l, "ALLOWED_TAGS") ? D({}, l.ALLOWED_TAGS, O) : C0, z = uu(l, "ALLOWED_ATTR") ? D({}, l.ALLOWED_ATTR, O) : D0, ze = uu(l, "ALLOWED_NAMESPACES") ? D({}, l.ALLOWED_NAMESPACES, je) : on, Be = uu(l, "ADD_URI_SAFE_ATTR") ? D(cu(I0), l.ADD_URI_SAFE_ATTR, O) : I0, v0 = uu(l, "ADD_DATA_URI_TAGS") ? D(cu(R0), l.ADD_DATA_URI_TAGS, O) : R0, nu = uu(l, "FORBID_CONTENTS") ? D({}, l.FORBID_CONTENTS, O) : Ne, ju = uu(l, "FORBID_TAGS") ? D({}, l.FORBID_TAGS, O) : cu({}), Re = uu(l, "FORBID_ATTR") ? D({}, l.FORBID_ATTR, O) : cu({}), Ru = uu(l, "USE_PROFILES") ? l.USE_PROFILES : !1, y0 = l.ALLOW_ARIA_ATTR !== !1, Ie = l.ALLOW_DATA_ATTR !== !1, F0 = l.ALLOW_UNKNOWN_PROTOCOLS || !1, T0 = l.ALLOW_SELF_CLOSE_IN_ATTR !== !1, wu = l.SAFE_FOR_TEMPLATES || !1, se = l.SAFE_FOR_XML !== !1, Eu = l.WHOLE_DOCUMENT || !1, vu = l.RETURN_DOM || !1, le = l.RETURN_DOM_FRAGMENT || !1, fe = l.RETURN_TRUSTED_TYPE || !1, Le = l.FORCE_BODY || !1, S0 = l.SANITIZE_DOM !== !1, w0 = l.SANITIZE_NAMED_PROPS || !1, Oe = l.KEEP_CONTENT !== !1, Gu = l.IN_PLACE || !1, A0 = l.ALLOWED_URI_REGEXP || wt, Iu = l.NAMESPACE || lu, be = l.MATHML_TEXT_INTEGRATION_POINTS || be, pe = l.HTML_INTEGRATION_POINTS || pe, R = l.CUSTOM_ELEMENT_HANDLING || {}, l.CUSTOM_ELEMENT_HANDLING && M0(l.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (R.tagNameCheck = l.CUSTOM_ELEMENT_HANDLING.tagNameCheck), l.CUSTOM_ELEMENT_HANDLING && M0(l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (R.attributeNameCheck = l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), l.CUSTOM_ELEMENT_HANDLING && typeof l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (R.allowCustomizedBuiltInElements = l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), wu && (Ie = !1), le && (vu = !0), Ru && (N = D({}, ut), z = [], Ru.html === !0 && (D(N, K0), D(z, et)), Ru.svg === !0 && (D(N, We), D(z, Ye), D(z, me)), Ru.svgFilters === !0 && (D(N, Ze), D(z, Ye), D(z, me)), Ru.mathMl === !0 && (D(N, Ve), D(z, tt), D(z, me))), l.ADD_TAGS && (typeof l.ADD_TAGS == "function" ? Su.tagCheck = l.ADD_TAGS : (N === C0 && (N = cu(N)), D(N, l.ADD_TAGS, O))), l.ADD_ATTR && (typeof l.ADD_ATTR == "function" ? Su.attributeCheck = l.ADD_ATTR : (z === D0 && (z = cu(z)), D(z, l.ADD_ATTR, O))), l.ADD_URI_SAFE_ATTR && D(Be, l.ADD_URI_SAFE_ATTR, O), l.FORBID_CONTENTS && (nu === Ne && (nu = cu(nu)), D(nu, l.FORBID_CONTENTS, O)), l.ADD_FORBID_CONTENTS && (nu === Ne && (nu = cu(nu)), D(nu, l.ADD_FORBID_CONTENTS, O)), Oe && (N["#text"] = !0), Eu && D(N, ["html", "head", "body"]), N.table && (D(N, ["tbody"]), delete ju.tbody), l.TRUSTED_TYPES_POLICY) {
389
393
  if (typeof l.TRUSTED_TYPES_POLICY.createHTML != "function")
390
394
  throw Yu('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
391
395
  if (typeof l.TRUSTED_TYPES_POLICY.createScriptURL != "function")
392
396
  throw Yu('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
393
- _ = l.TRUSTED_TYPES_POLICY, A = _.createHTML("");
397
+ m = l.TRUSTED_TYPES_POLICY, A = m.createHTML("");
394
398
  } else
395
- _ === void 0 && (_ = Tr(p, r)), _ !== null && typeof A == "string" && (A = _.createHTML(""));
396
- j && j(l), Mu = l;
399
+ m === void 0 && (m = Tr(b, r)), m !== null && typeof A == "string" && (A = m.createHTML(""));
400
+ $ && $(l), Mu = l;
397
401
  }
398
- }, O0 = F({}, [...We, ...Ze, ...mr]), N0 = F({}, [...Ve, ..._r]), dn = function(l) {
399
- let b = k(l);
400
- (!b || !b.tagName) && (b = {
402
+ }, L0 = D({}, [...We, ...Ze, ..._r]), O0 = D({}, [...Ve, ...mr]), dn = function(l) {
403
+ let p = k(l);
404
+ (!p || !p.tagName) && (p = {
401
405
  namespaceURI: Iu,
402
406
  tagName: "template"
403
407
  });
404
- const x = Ae(l.tagName), v = Ae(b.tagName);
405
- return qe[l.namespaceURI] ? l.namespaceURI === pe ? b.namespaceURI === su ? x === "svg" : b.namespaceURI === he ? x === "svg" && (v === "annotation-xml" || be[v]) : !!O0[x] : l.namespaceURI === he ? b.namespaceURI === su ? x === "math" : b.namespaceURI === pe ? x === "math" && me[v] : !!N0[x] : l.namespaceURI === su ? b.namespaceURI === pe && !me[v] || b.namespaceURI === he && !be[v] ? !1 : !N0[x] && (an[x] || !O0[x]) : !!(Wu === "application/xhtml+xml" && qe[l.namespaceURI]) : !1;
408
+ const x = Ae(l.tagName), w = Ae(p.tagName);
409
+ return ze[l.namespaceURI] ? l.namespaceURI === he ? p.namespaceURI === lu ? x === "svg" : p.namespaceURI === de ? x === "svg" && (w === "annotation-xml" || be[w]) : !!L0[x] : l.namespaceURI === de ? p.namespaceURI === lu ? x === "math" : p.namespaceURI === he ? x === "math" && pe[w] : !!O0[x] : l.namespaceURI === lu ? p.namespaceURI === he && !pe[w] || p.namespaceURI === de && !be[w] ? !1 : !O0[x] && (an[x] || !L0[x]) : !!(Wu === "application/xhtml+xml" && ze[l.namespaceURI]) : !1;
406
410
  }, ru = function(l) {
407
411
  Zu(e.removed, {
408
412
  element: l
@@ -410,56 +414,56 @@ function Rt() {
410
414
  try {
411
415
  k(l).removeChild(l);
412
416
  } catch {
413
- D(l);
417
+ y(l);
414
418
  }
415
- }, Eu = function(l, b) {
419
+ }, Au = function(l, p) {
416
420
  try {
417
421
  Zu(e.removed, {
418
- attribute: b.getAttributeNode(l),
419
- from: b
422
+ attribute: p.getAttributeNode(l),
423
+ from: p
420
424
  });
421
425
  } catch {
422
426
  Zu(e.removed, {
423
427
  attribute: null,
424
- from: b
428
+ from: p
425
429
  });
426
430
  }
427
- if (b.removeAttribute(l), l === "is")
428
- if (wu || fe)
431
+ if (p.removeAttribute(l), l === "is")
432
+ if (vu || le)
429
433
  try {
430
- ru(b);
434
+ ru(p);
431
435
  } catch {
432
436
  }
433
437
  else
434
438
  try {
435
- b.setAttribute(l, "");
439
+ p.setAttribute(l, "");
436
440
  } catch {
437
441
  }
438
- }, B0 = function(l) {
439
- let b = null, x = null;
440
- if (Ne)
442
+ }, N0 = function(l) {
443
+ let p = null, x = null;
444
+ if (Le)
441
445
  l = "<remove></remove>" + l;
442
446
  else {
443
447
  const I = Ge(l, /^[\r\n\t ]+/);
444
448
  x = I && I[0];
445
449
  }
446
- Wu === "application/xhtml+xml" && Iu === su && (l = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + l + "</body></html>");
447
- const v = _ ? _.createHTML(l) : l;
448
- if (Iu === su)
450
+ Wu === "application/xhtml+xml" && Iu === lu && (l = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + l + "</body></html>");
451
+ const w = m ? m.createHTML(l) : l;
452
+ if (Iu === lu)
449
453
  try {
450
- b = new m().parseFromString(v, Wu);
454
+ p = new _().parseFromString(w, Wu);
451
455
  } catch {
452
456
  }
453
- if (!b || !b.documentElement) {
454
- b = y.createDocument(Iu, "template", null);
457
+ if (!p || !p.documentElement) {
458
+ p = F.createDocument(Iu, "template", null);
455
459
  try {
456
- b.documentElement.innerHTML = ze ? A : v;
460
+ p.documentElement.innerHTML = Pe ? A : w;
457
461
  } catch {
458
462
  }
459
463
  }
460
- const U = b.body || b.documentElement;
461
- return l && x && U.insertBefore(t.createTextNode(x), U.childNodes[0] || null), Iu === su ? nu.call(b, ku ? "html" : "body")[0] : ku ? b.documentElement : U;
462
- }, P0 = function(l) {
464
+ const U = p.body || p.documentElement;
465
+ return l && x && U.insertBefore(t.createTextNode(x), U.childNodes[0] || null), Iu === lu ? tu.call(p, Eu ? "html" : "body")[0] : Eu ? p.documentElement : U;
466
+ }, B0 = function(l) {
463
467
  return M.call(
464
468
  l.ownerDocument || l,
465
469
  l,
@@ -467,65 +471,65 @@ function Rt() {
467
471
  s.SHOW_ELEMENT | s.SHOW_COMMENT | s.SHOW_TEXT | s.SHOW_PROCESSING_INSTRUCTION | s.SHOW_CDATA_SECTION,
468
472
  null
469
473
  );
470
- }, He = function(l) {
474
+ }, Ue = function(l) {
471
475
  return l instanceof d && (typeof l.nodeName != "string" || typeof l.textContent != "string" || typeof l.removeChild != "function" || !(l.attributes instanceof f) || typeof l.removeAttribute != "function" || typeof l.setAttribute != "function" || typeof l.namespaceURI != "string" || typeof l.insertBefore != "function" || typeof l.hasChildNodes != "function");
472
- }, z0 = function(l) {
473
- return typeof c == "function" && l instanceof c;
476
+ }, P0 = function(l) {
477
+ return typeof o == "function" && l instanceof o;
474
478
  };
475
- function lu(g, l, b) {
479
+ function fu(g, l, p) {
476
480
  _e(g, (x) => {
477
- x.call(e, l, b, Mu);
481
+ x.call(e, l, p, Mu);
478
482
  });
479
483
  }
480
- const q0 = function(l) {
481
- let b = null;
482
- if (lu(L.beforeSanitizeElements, l, null), He(l))
484
+ const z0 = function(l) {
485
+ let p = null;
486
+ if (fu(L.beforeSanitizeElements, l, null), Ue(l))
483
487
  return ru(l), !0;
484
- const x = N(l.nodeName);
485
- if (lu(L.uponSanitizeElement, l, {
488
+ const x = O(l.nodeName);
489
+ if (fu(L.uponSanitizeElement, l, {
486
490
  tagName: x,
487
- allowedTags: O
488
- }), le && l.hasChildNodes() && !z0(l.firstElementChild) && $(/<[/\w!]/g, l.innerHTML) && $(/<[/\w!]/g, l.textContent) || l.nodeType === Ju.progressingInstruction || le && l.nodeType === Ju.comment && $(/<[/\w]/g, l.data))
491
+ allowedTags: N
492
+ }), se && l.hasChildNodes() && !P0(l.firstElementChild) && H(/<[/\w!]/g, l.innerHTML) && H(/<[/\w!]/g, l.textContent) || l.nodeType === Ju.progressingInstruction || se && l.nodeType === Ju.comment && H(/<[/\w]/g, l.data))
489
493
  return ru(l), !0;
490
- if (!(Tu.tagCheck instanceof Function && Tu.tagCheck(x)) && (!O[x] || ju[x])) {
491
- if (!ju[x] && H0(x) && (R.tagNameCheck instanceof RegExp && $(R.tagNameCheck, x) || R.tagNameCheck instanceof Function && R.tagNameCheck(x)))
494
+ if (!(Su.tagCheck instanceof Function && Su.tagCheck(x)) && (!N[x] || ju[x])) {
495
+ if (!ju[x] && U0(x) && (R.tagNameCheck instanceof RegExp && H(R.tagNameCheck, x) || R.tagNameCheck instanceof Function && R.tagNameCheck(x)))
492
496
  return !1;
493
- if (Be && !Ru[x]) {
494
- const v = k(l) || l.parentNode, U = E(l) || l.childNodes;
495
- if (U && v) {
497
+ if (Oe && !nu[x]) {
498
+ const w = k(l) || l.parentNode, U = E(l) || l.childNodes;
499
+ if (U && w) {
496
500
  const I = U.length;
497
- for (let W = I - 1; W >= 0; --W) {
498
- const fu = C(U[W], !0);
499
- fu.__removalCount = (l.__removalCount || 0) + 1, v.insertBefore(fu, T(l));
501
+ for (let G = I - 1; G >= 0; --G) {
502
+ const du = C(U[G], !0);
503
+ du.__removalCount = (l.__removalCount || 0) + 1, w.insertBefore(du, T(l));
500
504
  }
501
505
  }
502
506
  }
503
507
  return ru(l), !0;
504
508
  }
505
- return l instanceof a && !dn(l) || (x === "noscript" || x === "noembed" || x === "noframes") && $(/<\/no(script|embed|frames)/i, l.innerHTML) ? (ru(l), !0) : (Su && l.nodeType === Ju.text && (b = l.textContent, _e([Hu, $u, Fu], (v) => {
506
- b = Vu(b, v, " ");
507
- }), l.textContent !== b && (Zu(e.removed, {
509
+ return l instanceof a && !dn(l) || (x === "noscript" || x === "noembed" || x === "noframes") && H(/<\/no(script|embed|frames)/i, l.innerHTML) ? (ru(l), !0) : (wu && l.nodeType === Ju.text && (p = l.textContent, _e([Hu, $u, Tu], (w) => {
510
+ p = Vu(p, w, " ");
511
+ }), l.textContent !== p && (Zu(e.removed, {
508
512
  element: l.cloneNode()
509
- }), l.textContent = b)), lu(L.afterSanitizeElements, l, null), !1);
510
- }, U0 = function(l, b, x) {
511
- if (S0 && (b === "id" || b === "name") && (x in t || x in fn))
513
+ }), l.textContent = p)), fu(L.afterSanitizeElements, l, null), !1);
514
+ }, q0 = function(l, p, x) {
515
+ if (S0 && (p === "id" || p === "name") && (x in t || x in fn))
512
516
  return !1;
513
- if (!(Le && !Me[b] && $(hu, b))) {
514
- if (!(y0 && $(Ie, b))) {
515
- if (!(Tu.attributeCheck instanceof Function && Tu.attributeCheck(b, l))) {
516
- if (!z[b] || Me[b]) {
517
+ if (!(Ie && !Re[p] && H(bu, p))) {
518
+ if (!(y0 && H(ve, p))) {
519
+ if (!(Su.attributeCheck instanceof Function && Su.attributeCheck(p, l))) {
520
+ if (!z[p] || Re[p]) {
517
521
  if (
518
522
  // First condition does a very basic check if a) it's basically a valid custom element tagname AND
519
523
  // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
520
524
  // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
521
- !(H0(l) && (R.tagNameCheck instanceof RegExp && $(R.tagNameCheck, l) || R.tagNameCheck instanceof Function && R.tagNameCheck(l)) && (R.attributeNameCheck instanceof RegExp && $(R.attributeNameCheck, b) || R.attributeNameCheck instanceof Function && R.attributeNameCheck(b, l)) || // Alternative, second condition checks if it's an `is`-attribute, AND
525
+ !(U0(l) && (R.tagNameCheck instanceof RegExp && H(R.tagNameCheck, l) || R.tagNameCheck instanceof Function && R.tagNameCheck(l)) && (R.attributeNameCheck instanceof RegExp && H(R.attributeNameCheck, p) || R.attributeNameCheck instanceof Function && R.attributeNameCheck(p, l)) || // Alternative, second condition checks if it's an `is`-attribute, AND
522
526
  // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
523
- b === "is" && R.allowCustomizedBuiltInElements && (R.tagNameCheck instanceof RegExp && $(R.tagNameCheck, x) || R.tagNameCheck instanceof Function && R.tagNameCheck(x)))
527
+ p === "is" && R.allowCustomizedBuiltInElements && (R.tagNameCheck instanceof RegExp && H(R.tagNameCheck, x) || R.tagNameCheck instanceof Function && R.tagNameCheck(x)))
524
528
  ) return !1;
525
- } else if (!Pe[b]) {
526
- if (!$(A0, Vu(x, E0, ""))) {
527
- if (!((b === "src" || b === "xlink:href" || b === "href") && l !== "script" && dr(x, "data:") === 0 && R0[l])) {
528
- if (!(F0 && !$(nn, Vu(x, E0, "")))) {
529
+ } else if (!Be[p]) {
530
+ if (!H(A0, Vu(x, E0, ""))) {
531
+ if (!((p === "src" || p === "xlink:href" || p === "href") && l !== "script" && dr(x, "data:") === 0 && v0[l])) {
532
+ if (!(F0 && !H(nn, Vu(x, E0, "")))) {
529
533
  if (x)
530
534
  return !1;
531
535
  }
@@ -536,14 +540,14 @@ function Rt() {
536
540
  }
537
541
  }
538
542
  return !0;
539
- }, H0 = function(l) {
543
+ }, U0 = function(l) {
540
544
  return l !== "annotation-xml" && Ge(l, rn);
541
- }, $0 = function(l) {
542
- lu(L.beforeSanitizeAttributes, l, null);
545
+ }, H0 = function(l) {
546
+ fu(L.beforeSanitizeAttributes, l, null);
543
547
  const {
544
- attributes: b
548
+ attributes: p
545
549
  } = l;
546
- if (!b || He(l))
550
+ if (!p || Ue(l))
547
551
  return;
548
552
  const x = {
549
553
  attrName: "",
@@ -552,69 +556,69 @@ function Rt() {
552
556
  allowedAttributes: z,
553
557
  forceKeepAttr: void 0
554
558
  };
555
- let v = b.length;
556
- for (; v--; ) {
557
- const U = b[v], {
559
+ let w = p.length;
560
+ for (; w--; ) {
561
+ const U = p[w], {
558
562
  name: I,
559
- namespaceURI: W,
560
- value: fu
561
- } = U, Lu = N(I), $e = fu;
562
- let q = I === "value" ? $e : hr($e);
563
- if (x.attrName = Lu, x.attrValue = q, x.keepAttr = !0, x.forceKeepAttr = void 0, lu(L.uponSanitizeAttribute, l, x), q = x.attrValue, w0 && (Lu === "id" || Lu === "name") && (Eu(I, l), q = on + q), le && $(/((--!?|])>)|<\/(style|title|textarea)/i, q)) {
564
- Eu(I, l);
563
+ namespaceURI: G,
564
+ value: du
565
+ } = U, Lu = O(I), He = du;
566
+ let q = I === "value" ? He : hr(He);
567
+ if (x.attrName = Lu, x.attrValue = q, x.keepAttr = !0, x.forceKeepAttr = void 0, fu(L.uponSanitizeAttribute, l, x), q = x.attrValue, w0 && (Lu === "id" || Lu === "name") && (Au(I, l), q = cn + q), se && H(/((--!?|])>)|<\/(style|title|textarea)/i, q)) {
568
+ Au(I, l);
565
569
  continue;
566
570
  }
567
571
  if (Lu === "attributename" && Ge(q, "href")) {
568
- Eu(I, l);
572
+ Au(I, l);
569
573
  continue;
570
574
  }
571
575
  if (x.forceKeepAttr)
572
576
  continue;
573
577
  if (!x.keepAttr) {
574
- Eu(I, l);
578
+ Au(I, l);
575
579
  continue;
576
580
  }
577
- if (!T0 && $(/\/>/i, q)) {
578
- Eu(I, l);
581
+ if (!T0 && H(/\/>/i, q)) {
582
+ Au(I, l);
579
583
  continue;
580
584
  }
581
- Su && _e([Hu, $u, Fu], (G0) => {
582
- q = Vu(q, G0, " ");
585
+ wu && _e([Hu, $u, Tu], (j0) => {
586
+ q = Vu(q, j0, " ");
583
587
  });
584
- const j0 = N(l.nodeName);
585
- if (!U0(j0, Lu, q)) {
586
- Eu(I, l);
588
+ const $0 = O(l.nodeName);
589
+ if (!q0($0, Lu, q)) {
590
+ Au(I, l);
587
591
  continue;
588
592
  }
589
- if (_ && typeof p == "object" && typeof p.getAttributeType == "function" && !W)
590
- switch (p.getAttributeType(j0, Lu)) {
593
+ if (m && typeof b == "object" && typeof b.getAttributeType == "function" && !G)
594
+ switch (b.getAttributeType($0, Lu)) {
591
595
  case "TrustedHTML": {
592
- q = _.createHTML(q);
596
+ q = m.createHTML(q);
593
597
  break;
594
598
  }
595
599
  case "TrustedScriptURL": {
596
- q = _.createScriptURL(q);
600
+ q = m.createScriptURL(q);
597
601
  break;
598
602
  }
599
603
  }
600
- if (q !== $e)
604
+ if (q !== He)
601
605
  try {
602
- W ? l.setAttributeNS(W, I, q) : l.setAttribute(I, q), He(l) ? ru(l) : K0(e.removed);
606
+ G ? l.setAttributeNS(G, I, q) : l.setAttribute(I, q), Ue(l) ? ru(l) : Q0(e.removed);
603
607
  } catch {
604
- Eu(I, l);
608
+ Au(I, l);
605
609
  }
606
610
  }
607
- lu(L.afterSanitizeAttributes, l, null);
611
+ fu(L.afterSanitizeAttributes, l, null);
608
612
  }, hn = function g(l) {
609
- let b = null;
610
- const x = P0(l);
611
- for (lu(L.beforeSanitizeShadowDOM, l, null); b = x.nextNode(); )
612
- lu(L.uponSanitizeShadowNode, b, null), q0(b), $0(b), b.content instanceof o && g(b.content);
613
- lu(L.afterSanitizeShadowDOM, l, null);
613
+ let p = null;
614
+ const x = B0(l);
615
+ for (fu(L.beforeSanitizeShadowDOM, l, null); p = x.nextNode(); )
616
+ fu(L.uponSanitizeShadowNode, p, null), z0(p), H0(p), p.content instanceof c && g(p.content);
617
+ fu(L.afterSanitizeShadowDOM, l, null);
614
618
  };
615
619
  return e.sanitize = function(g) {
616
- let l = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, b = null, x = null, v = null, U = null;
617
- if (ze = !g, ze && (g = "<!-->"), typeof g != "string" && !z0(g))
620
+ let l = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, p = null, x = null, w = null, U = null;
621
+ if (Pe = !g, Pe && (g = "<!-->"), typeof g != "string" && !P0(g))
618
622
  if (typeof g.toString == "function") {
619
623
  if (g = g.toString(), typeof g != "string")
620
624
  throw Yu("dirty is not a string, aborting");
@@ -622,61 +626,61 @@ function Rt() {
622
626
  throw Yu("toString is not a function");
623
627
  if (!e.isSupported)
624
628
  return g;
625
- if (Oe || Ue(l), e.removed = [], typeof g == "string" && (Gu = !1), Gu) {
629
+ if (Me || qe(l), e.removed = [], typeof g == "string" && (Gu = !1), Gu) {
626
630
  if (g.nodeName) {
627
- const fu = N(g.nodeName);
628
- if (!O[fu] || ju[fu])
631
+ const du = O(g.nodeName);
632
+ if (!N[du] || ju[du])
629
633
  throw Yu("root node is forbidden and cannot be sanitized in-place");
630
634
  }
631
- } else if (g instanceof c)
632
- b = B0("<!---->"), x = b.ownerDocument.importNode(g, !0), x.nodeType === Ju.element && x.nodeName === "BODY" || x.nodeName === "HTML" ? b = x : b.appendChild(x);
635
+ } else if (g instanceof o)
636
+ p = N0("<!---->"), x = p.ownerDocument.importNode(g, !0), x.nodeType === Ju.element && x.nodeName === "BODY" || x.nodeName === "HTML" ? p = x : p.appendChild(x);
633
637
  else {
634
- if (!wu && !Su && !ku && // eslint-disable-next-line unicorn/prefer-includes
638
+ if (!vu && !wu && !Eu && // eslint-disable-next-line unicorn/prefer-includes
635
639
  g.indexOf("<") === -1)
636
- return _ && de ? _.createHTML(g) : g;
637
- if (b = B0(g), !b)
638
- return wu ? null : de ? A : "";
639
- }
640
- b && Ne && ru(b.firstChild);
641
- const I = P0(Gu ? g : b);
642
- for (; v = I.nextNode(); )
643
- q0(v), $0(v), v.content instanceof o && hn(v.content);
640
+ return m && fe ? m.createHTML(g) : g;
641
+ if (p = N0(g), !p)
642
+ return vu ? null : fe ? A : "";
643
+ }
644
+ p && Le && ru(p.firstChild);
645
+ const I = B0(Gu ? g : p);
646
+ for (; w = I.nextNode(); )
647
+ z0(w), H0(w), w.content instanceof c && hn(w.content);
644
648
  if (Gu)
645
649
  return g;
646
- if (wu) {
647
- if (fe)
648
- for (U = Y.call(b.ownerDocument); b.firstChild; )
649
- U.appendChild(b.firstChild);
650
+ if (vu) {
651
+ if (le)
652
+ for (U = V.call(p.ownerDocument); p.firstChild; )
653
+ U.appendChild(p.firstChild);
650
654
  else
651
- U = b;
652
- return (z.shadowroot || z.shadowrootmode) && (U = gu.call(n, U, !0)), U;
653
- }
654
- let W = ku ? b.outerHTML : b.innerHTML;
655
- return ku && O["!doctype"] && b.ownerDocument && b.ownerDocument.doctype && b.ownerDocument.doctype.name && $(vt, b.ownerDocument.doctype.name) && (W = "<!DOCTYPE " + b.ownerDocument.doctype.name + `>
656
- ` + W), Su && _e([Hu, $u, Fu], (fu) => {
657
- W = Vu(W, fu, " ");
658
- }), _ && de ? _.createHTML(W) : W;
655
+ U = p;
656
+ return (z.shadowroot || z.shadowrootmode) && (U = ku.call(n, U, !0)), U;
657
+ }
658
+ let G = Eu ? p.outerHTML : p.innerHTML;
659
+ return Eu && N["!doctype"] && p.ownerDocument && p.ownerDocument.doctype && p.ownerDocument.doctype.name && H(vt, p.ownerDocument.doctype.name) && (G = "<!DOCTYPE " + p.ownerDocument.doctype.name + `>
660
+ ` + G), wu && _e([Hu, $u, Tu], (du) => {
661
+ G = Vu(G, du, " ");
662
+ }), m && fe ? m.createHTML(G) : G;
659
663
  }, e.setConfig = function() {
660
664
  let g = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
661
- Ue(g), Oe = !0;
665
+ qe(g), Me = !0;
662
666
  }, e.clearConfig = function() {
663
- Mu = null, Oe = !1;
664
- }, e.isValidAttribute = function(g, l, b) {
665
- Mu || Ue({});
666
- const x = N(g), v = N(l);
667
- return U0(x, v, b);
667
+ Mu = null, Me = !1;
668
+ }, e.isValidAttribute = function(g, l, p) {
669
+ Mu || qe({});
670
+ const x = O(g), w = O(l);
671
+ return q0(x, w, p);
668
672
  }, e.addHook = function(g, l) {
669
673
  typeof l == "function" && Zu(L[g], l);
670
674
  }, e.removeHook = function(g, l) {
671
675
  if (l !== void 0) {
672
- const b = lr(L[g], l);
673
- return b === -1 ? void 0 : fr(L[g], b, 1)[0];
676
+ const p = lr(L[g], l);
677
+ return p === -1 ? void 0 : fr(L[g], p, 1)[0];
674
678
  }
675
- return K0(L[g]);
679
+ return Q0(L[g]);
676
680
  }, e.removeHooks = function(g) {
677
681
  L[g] = [];
678
682
  }, e.removeAllHooks = function() {
679
- L = ot();
683
+ L = rt();
680
684
  }, e;
681
685
  }
682
686
  var Sr = Rt();
@@ -701,33 +705,33 @@ function zu(u, e) {
701
705
  const t = wr(e);
702
706
  return u.replace(/(%[a-f0-9]{2})+/gi, function(n) {
703
707
  let r = "";
704
- for (let o = 0, i = n.length; o < i; o += 3) {
705
- const c = parseInt(n.slice(o + 1, o + 3), 16);
706
- if (c < 128) {
707
- r += t[c];
708
+ for (let c = 0, i = n.length; c < i; c += 3) {
709
+ const o = parseInt(n.slice(c + 1, c + 3), 16);
710
+ if (o < 128) {
711
+ r += t[o];
708
712
  continue;
709
713
  }
710
- if ((c & 224) === 192 && o + 3 < i) {
711
- const a = parseInt(n.slice(o + 4, o + 6), 16);
714
+ if ((o & 224) === 192 && c + 3 < i) {
715
+ const a = parseInt(n.slice(c + 4, c + 6), 16);
712
716
  if ((a & 192) === 128) {
713
- const s = c << 6 & 1984 | a & 63;
714
- s < 128 ? r += "��" : r += String.fromCharCode(s), o += 3;
717
+ const s = o << 6 & 1984 | a & 63;
718
+ s < 128 ? r += "��" : r += String.fromCharCode(s), c += 3;
715
719
  continue;
716
720
  }
717
721
  }
718
- if ((c & 240) === 224 && o + 6 < i) {
719
- const a = parseInt(n.slice(o + 4, o + 6), 16), s = parseInt(n.slice(o + 7, o + 9), 16);
722
+ if ((o & 240) === 224 && c + 6 < i) {
723
+ const a = parseInt(n.slice(c + 4, c + 6), 16), s = parseInt(n.slice(c + 7, c + 9), 16);
720
724
  if ((a & 192) === 128 && (s & 192) === 128) {
721
- const f = c << 12 & 61440 | a << 6 & 4032 | s & 63;
722
- f < 2048 || f >= 55296 && f <= 57343 ? r += "���" : r += String.fromCharCode(f), o += 6;
725
+ const f = o << 12 & 61440 | a << 6 & 4032 | s & 63;
726
+ f < 2048 || f >= 55296 && f <= 57343 ? r += "���" : r += String.fromCharCode(f), c += 6;
723
727
  continue;
724
728
  }
725
729
  }
726
- if ((c & 248) === 240 && o + 9 < i) {
727
- const a = parseInt(n.slice(o + 4, o + 6), 16), s = parseInt(n.slice(o + 7, o + 9), 16), f = parseInt(n.slice(o + 10, o + 12), 16);
730
+ if ((o & 248) === 240 && c + 9 < i) {
731
+ const a = parseInt(n.slice(c + 4, c + 6), 16), s = parseInt(n.slice(c + 7, c + 9), 16), f = parseInt(n.slice(c + 10, c + 12), 16);
728
732
  if ((a & 192) === 128 && (s & 192) === 128 && (f & 192) === 128) {
729
- let d = c << 18 & 1835008 | a << 12 & 258048 | s << 6 & 4032 | f & 63;
730
- d < 65536 || d > 1114111 ? r += "����" : (d -= 65536, r += String.fromCharCode(55296 + (d >> 10), 56320 + (d & 1023))), o += 9;
733
+ let d = o << 18 & 1835008 | a << 12 & 258048 | s << 6 & 4032 | f & 63;
734
+ d < 65536 || d > 1114111 ? r += "����" : (d -= 65536, r += String.fromCharCode(55296 + (d >> 10), 56320 + (d & 1023))), c += 9;
731
735
  continue;
732
736
  }
733
737
  }
@@ -738,12 +742,12 @@ function zu(u, e) {
738
742
  }
739
743
  zu.defaultChars = ";/?:@&=+$,#";
740
744
  zu.componentChars = "";
741
- const it = {};
745
+ const ot = {};
742
746
  function vr(u) {
743
- let e = it[u];
747
+ let e = ot[u];
744
748
  if (e)
745
749
  return e;
746
- e = it[u] = [];
750
+ e = ot[u] = [];
747
751
  for (let t = 0; t < 128; t++) {
748
752
  const n = String.fromCharCode(t);
749
753
  /^[0-9a-z]$/i.test(n) ? e.push(n) : e.push("%" + ("0" + t.toString(16).toUpperCase()).slice(-2));
@@ -752,49 +756,49 @@ function vr(u) {
752
756
  e[u.charCodeAt(t)] = u[t];
753
757
  return e;
754
758
  }
755
- function ie(u, e, t) {
756
- typeof e != "string" && (t = e, e = ie.defaultChars), typeof t > "u" && (t = !0);
759
+ function oe(u, e, t) {
760
+ typeof e != "string" && (t = e, e = oe.defaultChars), typeof t > "u" && (t = !0);
757
761
  const n = vr(e);
758
762
  let r = "";
759
- for (let o = 0, i = u.length; o < i; o++) {
760
- const c = u.charCodeAt(o);
761
- if (t && c === 37 && o + 2 < i && /^[0-9a-f]{2}$/i.test(u.slice(o + 1, o + 3))) {
762
- r += u.slice(o, o + 3), o += 2;
763
+ for (let c = 0, i = u.length; c < i; c++) {
764
+ const o = u.charCodeAt(c);
765
+ if (t && o === 37 && c + 2 < i && /^[0-9a-f]{2}$/i.test(u.slice(c + 1, c + 3))) {
766
+ r += u.slice(c, c + 3), c += 2;
763
767
  continue;
764
768
  }
765
- if (c < 128) {
766
- r += n[c];
769
+ if (o < 128) {
770
+ r += n[o];
767
771
  continue;
768
772
  }
769
- if (c >= 55296 && c <= 57343) {
770
- if (c >= 55296 && c <= 56319 && o + 1 < i) {
771
- const a = u.charCodeAt(o + 1);
773
+ if (o >= 55296 && o <= 57343) {
774
+ if (o >= 55296 && o <= 56319 && c + 1 < i) {
775
+ const a = u.charCodeAt(c + 1);
772
776
  if (a >= 56320 && a <= 57343) {
773
- r += encodeURIComponent(u[o] + u[o + 1]), o++;
777
+ r += encodeURIComponent(u[c] + u[c + 1]), c++;
774
778
  continue;
775
779
  }
776
780
  }
777
781
  r += "%EF%BF%BD";
778
782
  continue;
779
783
  }
780
- r += encodeURIComponent(u[o]);
784
+ r += encodeURIComponent(u[c]);
781
785
  }
782
786
  return r;
783
787
  }
784
- ie.defaultChars = ";/?:@&=+$,-_.!~*'()#";
785
- ie.componentChars = "-_.!~*'()";
788
+ oe.defaultChars = ";/?:@&=+$,-_.!~*'()#";
789
+ oe.componentChars = "-_.!~*'()";
786
790
  function h0(u) {
787
791
  let e = "";
788
792
  return e += u.protocol || "", e += u.slashes ? "//" : "", e += u.auth ? u.auth + "@" : "", u.hostname && u.hostname.indexOf(":") !== -1 ? e += "[" + u.hostname + "]" : e += u.hostname || "", e += u.port ? ":" + u.port : "", e += u.pathname || "", e += u.search || "", e += u.hash || "", e;
789
793
  }
790
- function ye() {
794
+ function Ce() {
791
795
  this.protocol = null, this.slashes = null, this.auth = null, this.port = null, this.hostname = null, this.hash = null, this.search = null, this.pathname = null;
792
796
  }
793
797
  const Rr = /^([a-z0-9.+-]+:)/i, Ir = /:[0-9]*$/, Mr = /^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/, Lr = ["<", ">", '"', "`", " ", "\r", `
794
- `, " "], Or = ["{", "}", "|", "\\", "^", "`"].concat(Lr), Nr = ["'"].concat(Or), at = ["%", "/", "?", ";", "#"].concat(Nr), st = ["/", "?", "#"], Br = 255, lt = /^[+a-z0-9A-Z_-]{0,63}$/, Pr = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, ft = {
798
+ `, " "], Or = ["{", "}", "|", "\\", "^", "`"].concat(Lr), Nr = ["'"].concat(Or), it = ["%", "/", "?", ";", "#"].concat(Nr), at = ["/", "?", "#"], Br = 255, st = /^[+a-z0-9A-Z_-]{0,63}$/, Pr = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, lt = {
795
799
  javascript: !0,
796
800
  "javascript:": !0
797
- }, dt = {
801
+ }, ft = {
798
802
  http: !0,
799
803
  https: !0,
800
804
  ftp: !0,
@@ -806,70 +810,70 @@ const Rr = /^([a-z0-9.+-]+:)/i, Ir = /:[0-9]*$/, Mr = /^(\/\/?(?!\/)[^\?\s]*)(\?
806
810
  "gopher:": !0,
807
811
  "file:": !0
808
812
  };
809
- function p0(u, e) {
810
- if (u && u instanceof ye) return u;
811
- const t = new ye();
813
+ function b0(u, e) {
814
+ if (u && u instanceof Ce) return u;
815
+ const t = new Ce();
812
816
  return t.parse(u, e), t;
813
817
  }
814
- ye.prototype.parse = function(u, e) {
815
- let t, n, r, o = u;
816
- if (o = o.trim(), !e && u.split("#").length === 1) {
817
- const s = Mr.exec(o);
818
+ Ce.prototype.parse = function(u, e) {
819
+ let t, n, r, c = u;
820
+ if (c = c.trim(), !e && u.split("#").length === 1) {
821
+ const s = Mr.exec(c);
818
822
  if (s)
819
823
  return this.pathname = s[1], s[2] && (this.search = s[2]), this;
820
824
  }
821
- let i = Rr.exec(o);
822
- if (i && (i = i[0], t = i.toLowerCase(), this.protocol = i, o = o.substr(i.length)), (e || i || o.match(/^\/\/[^@\/]+@[^@\/]+/)) && (r = o.substr(0, 2) === "//", r && !(i && ft[i]) && (o = o.substr(2), this.slashes = !0)), !ft[i] && (r || i && !dt[i])) {
825
+ let i = Rr.exec(c);
826
+ if (i && (i = i[0], t = i.toLowerCase(), this.protocol = i, c = c.substr(i.length)), (e || i || c.match(/^\/\/[^@\/]+@[^@\/]+/)) && (r = c.substr(0, 2) === "//", r && !(i && lt[i]) && (c = c.substr(2), this.slashes = !0)), !lt[i] && (r || i && !ft[i])) {
823
827
  let s = -1;
824
- for (let h = 0; h < st.length; h++)
825
- n = o.indexOf(st[h]), n !== -1 && (s === -1 || n < s) && (s = n);
826
- let f, d;
827
- s === -1 ? d = o.lastIndexOf("@") : d = o.lastIndexOf("@", s), d !== -1 && (f = o.slice(0, d), o = o.slice(d + 1), this.auth = f), s = -1;
828
828
  for (let h = 0; h < at.length; h++)
829
- n = o.indexOf(at[h]), n !== -1 && (s === -1 || n < s) && (s = n);
830
- s === -1 && (s = o.length), o[s - 1] === ":" && s--;
831
- const m = o.slice(0, s);
832
- o = o.slice(s), this.parseHost(m), this.hostname = this.hostname || "";
833
- const p = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]";
834
- if (!p) {
829
+ n = c.indexOf(at[h]), n !== -1 && (s === -1 || n < s) && (s = n);
830
+ let f, d;
831
+ s === -1 ? d = c.lastIndexOf("@") : d = c.lastIndexOf("@", s), d !== -1 && (f = c.slice(0, d), c = c.slice(d + 1), this.auth = f), s = -1;
832
+ for (let h = 0; h < it.length; h++)
833
+ n = c.indexOf(it[h]), n !== -1 && (s === -1 || n < s) && (s = n);
834
+ s === -1 && (s = c.length), c[s - 1] === ":" && s--;
835
+ const _ = c.slice(0, s);
836
+ c = c.slice(s), this.parseHost(_), this.hostname = this.hostname || "";
837
+ const b = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]";
838
+ if (!b) {
835
839
  const h = this.hostname.split(/\./);
836
- for (let C = 0, D = h.length; C < D; C++) {
840
+ for (let C = 0, y = h.length; C < y; C++) {
837
841
  const T = h[C];
838
- if (T && !T.match(lt)) {
842
+ if (T && !T.match(st)) {
839
843
  let E = "";
840
- for (let k = 0, _ = T.length; k < _; k++)
844
+ for (let k = 0, m = T.length; k < m; k++)
841
845
  T.charCodeAt(k) > 127 ? E += "x" : E += T[k];
842
- if (!E.match(lt)) {
843
- const k = h.slice(0, C), _ = h.slice(C + 1), A = T.match(Pr);
844
- A && (k.push(A[1]), _.unshift(A[2])), _.length && (o = _.join(".") + o), this.hostname = k.join(".");
846
+ if (!E.match(st)) {
847
+ const k = h.slice(0, C), m = h.slice(C + 1), A = T.match(Pr);
848
+ A && (k.push(A[1]), m.unshift(A[2])), m.length && (c = m.join(".") + c), this.hostname = k.join(".");
845
849
  break;
846
850
  }
847
851
  }
848
852
  }
849
853
  }
850
- this.hostname.length > Br && (this.hostname = ""), p && (this.hostname = this.hostname.substr(1, this.hostname.length - 2));
854
+ this.hostname.length > Br && (this.hostname = ""), b && (this.hostname = this.hostname.substr(1, this.hostname.length - 2));
851
855
  }
852
- const c = o.indexOf("#");
853
- c !== -1 && (this.hash = o.substr(c), o = o.slice(0, c));
854
- const a = o.indexOf("?");
855
- return a !== -1 && (this.search = o.substr(a), o = o.slice(0, a)), o && (this.pathname = o), dt[t] && this.hostname && !this.pathname && (this.pathname = ""), this;
856
+ const o = c.indexOf("#");
857
+ o !== -1 && (this.hash = c.substr(o), c = c.slice(0, o));
858
+ const a = c.indexOf("?");
859
+ return a !== -1 && (this.search = c.substr(a), c = c.slice(0, a)), c && (this.pathname = c), ft[t] && this.hostname && !this.pathname && (this.pathname = ""), this;
856
860
  };
857
- ye.prototype.parseHost = function(u) {
861
+ Ce.prototype.parseHost = function(u) {
858
862
  let e = Ir.exec(u);
859
863
  e && (e = e[0], e !== ":" && (this.port = e.substr(1)), u = u.substr(0, u.length - e.length)), u && (this.hostname = u);
860
864
  };
861
865
  const zr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
862
866
  __proto__: null,
863
867
  decode: zu,
864
- encode: ie,
868
+ encode: oe,
865
869
  format: h0,
866
- parse: p0
867
- }, Symbol.toStringTag, { value: "Module" })), It = /[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Mt = /[\0-\x1F\x7F-\x9F]/, qr = /[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/, b0 = /[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/, Lt = /[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/, Ot = /[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/, Ur = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
870
+ parse: b0
871
+ }, Symbol.toStringTag, { value: "Module" })), It = /[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, Mt = /[\0-\x1F\x7F-\x9F]/, qr = /[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/, p0 = /[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDEAD\uDF55-\uDF59\uDF86-\uDF89]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5A\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDEB9\uDF3C-\uDF3E]|\uD806[\uDC3B\uDD44-\uDD46\uDDE2\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2\uDF00-\uDF09]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8\uDF43-\uDF4F\uDFFF]|\uD809[\uDC70-\uDC74]|\uD80B[\uDFF1\uDFF2]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A\uDFE2]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/, Lt = /[\$\+<->\^`\|~\xA2-\xA6\xA8\xA9\xAC\xAE-\xB1\xB4\xB8\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0384\u0385\u03F6\u0482\u058D-\u058F\u0606-\u0608\u060B\u060E\u060F\u06DE\u06E9\u06FD\u06FE\u07F6\u07FE\u07FF\u0888\u09F2\u09F3\u09FA\u09FB\u0AF1\u0B70\u0BF3-\u0BFA\u0C7F\u0D4F\u0D79\u0E3F\u0F01-\u0F03\u0F13\u0F15-\u0F17\u0F1A-\u0F1F\u0F34\u0F36\u0F38\u0FBE-\u0FC5\u0FC7-\u0FCC\u0FCE\u0FCF\u0FD5-\u0FD8\u109E\u109F\u1390-\u1399\u166D\u17DB\u1940\u19DE-\u19FF\u1B61-\u1B6A\u1B74-\u1B7C\u1FBD\u1FBF-\u1FC1\u1FCD-\u1FCF\u1FDD-\u1FDF\u1FED-\u1FEF\u1FFD\u1FFE\u2044\u2052\u207A-\u207C\u208A-\u208C\u20A0-\u20C0\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F\u218A\u218B\u2190-\u2307\u230C-\u2328\u232B-\u2426\u2440-\u244A\u249C-\u24E9\u2500-\u2767\u2794-\u27C4\u27C7-\u27E5\u27F0-\u2982\u2999-\u29D7\u29DC-\u29FB\u29FE-\u2B73\u2B76-\u2B95\u2B97-\u2BFF\u2CE5-\u2CEA\u2E50\u2E51\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFF\u3004\u3012\u3013\u3020\u3036\u3037\u303E\u303F\u309B\u309C\u3190\u3191\u3196-\u319F\u31C0-\u31E3\u31EF\u3200-\u321E\u322A-\u3247\u3250\u3260-\u327F\u328A-\u32B0\u32C0-\u33FF\u4DC0-\u4DFF\uA490-\uA4C6\uA700-\uA716\uA720\uA721\uA789\uA78A\uA828-\uA82B\uA836-\uA839\uAA77-\uAA79\uAB5B\uAB6A\uAB6B\uFB29\uFBB2-\uFBC2\uFD40-\uFD4F\uFDCF\uFDFC-\uFDFF\uFE62\uFE64-\uFE66\uFE69\uFF04\uFF0B\uFF1C-\uFF1E\uFF3E\uFF40\uFF5C\uFF5E\uFFE0-\uFFE6\uFFE8-\uFFEE\uFFFC\uFFFD]|\uD800[\uDD37-\uDD3F\uDD79-\uDD89\uDD8C-\uDD8E\uDD90-\uDD9C\uDDA0\uDDD0-\uDDFC]|\uD802[\uDC77\uDC78\uDEC8]|\uD805\uDF3F|\uD807[\uDFD5-\uDFF1]|\uD81A[\uDF3C-\uDF3F\uDF45]|\uD82F\uDC9C|\uD833[\uDF50-\uDFC3]|\uD834[\uDC00-\uDCF5\uDD00-\uDD26\uDD29-\uDD64\uDD6A-\uDD6C\uDD83\uDD84\uDD8C-\uDDA9\uDDAE-\uDDEA\uDE00-\uDE41\uDE45\uDF00-\uDF56]|\uD835[\uDEC1\uDEDB\uDEFB\uDF15\uDF35\uDF4F\uDF6F\uDF89\uDFA9\uDFC3]|\uD836[\uDC00-\uDDFF\uDE37-\uDE3A\uDE6D-\uDE74\uDE76-\uDE83\uDE85\uDE86]|\uD838[\uDD4F\uDEFF]|\uD83B[\uDCAC\uDCB0\uDD2E\uDEF0\uDEF1]|\uD83C[\uDC00-\uDC2B\uDC30-\uDC93\uDCA0-\uDCAE\uDCB1-\uDCBF\uDCC1-\uDCCF\uDCD1-\uDCF5\uDD0D-\uDDAD\uDDE6-\uDE02\uDE10-\uDE3B\uDE40-\uDE48\uDE50\uDE51\uDE60-\uDE65\uDF00-\uDFFF]|\uD83D[\uDC00-\uDED7\uDEDC-\uDEEC\uDEF0-\uDEFC\uDF00-\uDF76\uDF7B-\uDFD9\uDFE0-\uDFEB\uDFF0]|\uD83E[\uDC00-\uDC0B\uDC10-\uDC47\uDC50-\uDC59\uDC60-\uDC87\uDC90-\uDCAD\uDCB0\uDCB1\uDD00-\uDE53\uDE60-\uDE6D\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC5\uDECE-\uDEDB\uDEE0-\uDEE8\uDEF0-\uDEF8\uDF00-\uDF92\uDF94-\uDFCA]/, Ot = /[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/, Ur = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
868
872
  __proto__: null,
869
873
  Any: It,
870
874
  Cc: Mt,
871
875
  Cf: qr,
872
- P: b0,
876
+ P: p0,
873
877
  S: Lt,
874
878
  Z: Ot
875
879
  }, Symbol.toStringTag, { value: "Module" })), Hr = new Uint16Array(
@@ -930,14 +934,14 @@ var mu;
930
934
  (function(u) {
931
935
  u[u.VALUE_LENGTH = 49152] = "VALUE_LENGTH", u[u.BRANCH_LENGTH = 16256] = "BRANCH_LENGTH", u[u.JUMP_TABLE = 127] = "JUMP_TABLE";
932
936
  })(mu || (mu = {}));
933
- function c0(u) {
937
+ function o0(u) {
934
938
  return u >= P.ZERO && u <= P.NINE;
935
939
  }
936
940
  function Vr(u) {
937
941
  return u >= P.UPPER_A && u <= P.UPPER_F || u >= P.LOWER_A && u <= P.LOWER_F;
938
942
  }
939
943
  function Yr(u) {
940
- return u >= P.UPPER_A && u <= P.UPPER_Z || u >= P.LOWER_A && u <= P.LOWER_Z || c0(u);
944
+ return u >= P.UPPER_A && u <= P.UPPER_Z || u >= P.LOWER_A && u <= P.LOWER_Z || o0(u);
941
945
  }
942
946
  function Xr(u) {
943
947
  return u === P.EQUALS || Yr(u);
@@ -946,13 +950,13 @@ var B;
946
950
  (function(u) {
947
951
  u[u.EntityStart = 0] = "EntityStart", u[u.NumericStart = 1] = "NumericStart", u[u.NumericDecimal = 2] = "NumericDecimal", u[u.NumericHex = 3] = "NumericHex", u[u.NamedEntity = 4] = "NamedEntity";
948
952
  })(B || (B = {}));
949
- var bu;
953
+ var _u;
950
954
  (function(u) {
951
955
  u[u.Legacy = 0] = "Legacy", u[u.Strict = 1] = "Strict", u[u.Attribute = 2] = "Attribute";
952
- })(bu || (bu = {}));
956
+ })(_u || (_u = {}));
953
957
  class Jr {
954
958
  constructor(e, t, n) {
955
- this.decodeTree = e, this.emitCodePoint = t, this.errors = n, this.state = B.EntityStart, this.consumed = 1, this.result = 0, this.treeIndex = 0, this.excess = 1, this.decodeMode = bu.Strict;
959
+ this.decodeTree = e, this.emitCodePoint = t, this.errors = n, this.state = B.EntityStart, this.consumed = 1, this.result = 0, this.treeIndex = 0, this.excess = 1, this.decodeMode = _u.Strict;
956
960
  }
957
961
  /** Resets the instance to make it reusable. */
958
962
  startEntity(e) {
@@ -997,8 +1001,8 @@ class Jr {
997
1001
  }
998
1002
  addToNumericResult(e, t, n, r) {
999
1003
  if (t !== n) {
1000
- const o = n - t;
1001
- this.result = this.result * Math.pow(r, o) + parseInt(e.substr(t, o), r), this.consumed += o;
1004
+ const c = n - t;
1005
+ this.result = this.result * Math.pow(r, c) + parseInt(e.substr(t, c), r), this.consumed += c;
1002
1006
  }
1003
1007
  }
1004
1008
  /**
@@ -1014,7 +1018,7 @@ class Jr {
1014
1018
  const n = t;
1015
1019
  for (; t < e.length; ) {
1016
1020
  const r = e.charCodeAt(t);
1017
- if (c0(r) || Vr(r))
1021
+ if (o0(r) || Vr(r))
1018
1022
  t += 1;
1019
1023
  else
1020
1024
  return this.addToNumericResult(e, n, t, 16), this.emitNumericEntity(r, 3);
@@ -1034,7 +1038,7 @@ class Jr {
1034
1038
  const n = t;
1035
1039
  for (; t < e.length; ) {
1036
1040
  const r = e.charCodeAt(t);
1037
- if (c0(r))
1041
+ if (o0(r))
1038
1042
  t += 1;
1039
1043
  else
1040
1044
  return this.addToNumericResult(e, n, t, 10), this.emitNumericEntity(r, 2);
@@ -1060,7 +1064,7 @@ class Jr {
1060
1064
  return (n = this.errors) === null || n === void 0 || n.absenceOfDigitsInNumericCharacterReference(this.consumed), 0;
1061
1065
  if (e === P.SEMI)
1062
1066
  this.consumed += 1;
1063
- else if (this.decodeMode === bu.Strict)
1067
+ else if (this.decodeMode === _u.Strict)
1064
1068
  return 0;
1065
1069
  return this.emitCodePoint(Wr(this.result), this.consumed), this.errors && (e !== P.SEMI && this.errors.missingSemicolonAfterCharacterReference(), this.errors.validateNumericCharacterReference(this.result)), this.consumed;
1066
1070
  }
@@ -1075,18 +1079,18 @@ class Jr {
1075
1079
  */
1076
1080
  stateNamedEntity(e, t) {
1077
1081
  const { decodeTree: n } = this;
1078
- let r = n[this.treeIndex], o = (r & mu.VALUE_LENGTH) >> 14;
1082
+ let r = n[this.treeIndex], c = (r & mu.VALUE_LENGTH) >> 14;
1079
1083
  for (; t < e.length; t++, this.excess++) {
1080
1084
  const i = e.charCodeAt(t);
1081
- if (this.treeIndex = Qr(n, r, this.treeIndex + Math.max(1, o), i), this.treeIndex < 0)
1085
+ if (this.treeIndex = Qr(n, r, this.treeIndex + Math.max(1, c), i), this.treeIndex < 0)
1082
1086
  return this.result === 0 || // If we are parsing an attribute
1083
- this.decodeMode === bu.Attribute && // We shouldn't have consumed any characters after the entity,
1084
- (o === 0 || // And there should be no invalid characters.
1087
+ this.decodeMode === _u.Attribute && // We shouldn't have consumed any characters after the entity,
1088
+ (c === 0 || // And there should be no invalid characters.
1085
1089
  Xr(i)) ? 0 : this.emitNotTerminatedNamedEntity();
1086
- if (r = n[this.treeIndex], o = (r & mu.VALUE_LENGTH) >> 14, o !== 0) {
1090
+ if (r = n[this.treeIndex], c = (r & mu.VALUE_LENGTH) >> 14, c !== 0) {
1087
1091
  if (i === P.SEMI)
1088
- return this.emitNamedEntityData(this.treeIndex, o, this.consumed + this.excess);
1089
- this.decodeMode !== bu.Strict && (this.result = this.treeIndex, this.consumed += this.excess, this.excess = 0);
1092
+ return this.emitNamedEntityData(this.treeIndex, c, this.consumed + this.excess);
1093
+ this.decodeMode !== _u.Strict && (this.result = this.treeIndex, this.consumed += this.excess, this.excess = 0);
1090
1094
  }
1091
1095
  }
1092
1096
  return -1;
@@ -1125,7 +1129,7 @@ class Jr {
1125
1129
  var e;
1126
1130
  switch (this.state) {
1127
1131
  case B.NamedEntity:
1128
- return this.result !== 0 && (this.decodeMode !== bu.Attribute || this.result === this.treeIndex) ? this.emitNotTerminatedNamedEntity() : 0;
1132
+ return this.result !== 0 && (this.decodeMode !== _u.Attribute || this.result === this.treeIndex) ? this.emitNotTerminatedNamedEntity() : 0;
1129
1133
  case B.NumericDecimal:
1130
1134
  return this.emitNumericEntity(0, 2);
1131
1135
  case B.NumericHex:
@@ -1140,40 +1144,40 @@ class Jr {
1140
1144
  function Nt(u) {
1141
1145
  let e = "";
1142
1146
  const t = new Jr(u, (n) => e += Gr(n));
1143
- return function(r, o) {
1144
- let i = 0, c = 0;
1145
- for (; (c = r.indexOf("&", c)) >= 0; ) {
1146
- e += r.slice(i, c), t.startEntity(o);
1147
+ return function(r, c) {
1148
+ let i = 0, o = 0;
1149
+ for (; (o = r.indexOf("&", o)) >= 0; ) {
1150
+ e += r.slice(i, o), t.startEntity(c);
1147
1151
  const s = t.write(
1148
1152
  r,
1149
1153
  // Skip the "&"
1150
- c + 1
1154
+ o + 1
1151
1155
  );
1152
1156
  if (s < 0) {
1153
- i = c + t.end();
1157
+ i = o + t.end();
1154
1158
  break;
1155
1159
  }
1156
- i = c + s, c = s === 0 ? i + 1 : i;
1160
+ i = o + s, o = s === 0 ? i + 1 : i;
1157
1161
  }
1158
1162
  const a = e + r.slice(i);
1159
1163
  return e = "", a;
1160
1164
  };
1161
1165
  }
1162
1166
  function Qr(u, e, t, n) {
1163
- const r = (e & mu.BRANCH_LENGTH) >> 7, o = e & mu.JUMP_TABLE;
1167
+ const r = (e & mu.BRANCH_LENGTH) >> 7, c = e & mu.JUMP_TABLE;
1164
1168
  if (r === 0)
1165
- return o !== 0 && n === o ? t : -1;
1166
- if (o) {
1167
- const a = n - o;
1169
+ return c !== 0 && n === c ? t : -1;
1170
+ if (c) {
1171
+ const a = n - c;
1168
1172
  return a < 0 || a >= r ? -1 : u[t + a] - 1;
1169
1173
  }
1170
- let i = t, c = i + r - 1;
1171
- for (; i <= c; ) {
1172
- const a = i + c >>> 1, s = u[a];
1174
+ let i = t, o = i + r - 1;
1175
+ for (; i <= o; ) {
1176
+ const a = i + o >>> 1, s = u[a];
1173
1177
  if (s < n)
1174
1178
  i = a + 1;
1175
1179
  else if (s > n)
1176
- c = a - 1;
1180
+ o = a - 1;
1177
1181
  else
1178
1182
  return u[a + r];
1179
1183
  }
@@ -1181,20 +1185,20 @@ function Qr(u, e, t, n) {
1181
1185
  }
1182
1186
  const Kr = Nt(Hr);
1183
1187
  Nt($r);
1184
- function Bt(u, e = bu.Legacy) {
1188
+ function Bt(u, e = _u.Legacy) {
1185
1189
  return Kr(u, e);
1186
1190
  }
1187
- function uo(u) {
1191
+ function uc(u) {
1188
1192
  return Object.prototype.toString.call(u);
1189
1193
  }
1190
- function m0(u) {
1191
- return uo(u) === "[object String]";
1194
+ function _0(u) {
1195
+ return uc(u) === "[object String]";
1192
1196
  }
1193
- const eo = Object.prototype.hasOwnProperty;
1194
- function to(u, e) {
1195
- return eo.call(u, e);
1197
+ const ec = Object.prototype.hasOwnProperty;
1198
+ function tc(u, e) {
1199
+ return ec.call(u, e);
1196
1200
  }
1197
- function Se(u) {
1201
+ function Fe(u) {
1198
1202
  return Array.prototype.slice.call(arguments, 1).forEach(function(t) {
1199
1203
  if (t) {
1200
1204
  if (typeof t != "object")
@@ -1208,10 +1212,10 @@ function Se(u) {
1208
1212
  function Pt(u, e, t) {
1209
1213
  return [].concat(u.slice(0, e), t, u.slice(e + 1));
1210
1214
  }
1211
- function _0(u) {
1215
+ function m0(u) {
1212
1216
  return !(u >= 55296 && u <= 57343 || u >= 64976 && u <= 65007 || (u & 65535) === 65535 || (u & 65535) === 65534 || u >= 0 && u <= 8 || u === 11 || u >= 14 && u <= 31 || u >= 127 && u <= 159 || u > 1114111);
1213
1217
  }
1214
- function Fe(u) {
1218
+ function De(u) {
1215
1219
  if (u > 65535) {
1216
1220
  u -= 65536;
1217
1221
  const e = 55296 + (u >> 10), t = 56320 + (u & 1023);
@@ -1219,40 +1223,40 @@ function Fe(u) {
1219
1223
  }
1220
1224
  return String.fromCharCode(u);
1221
1225
  }
1222
- const zt = /\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g, no = /&([a-z#][a-z0-9]{1,31});/gi, ro = new RegExp(zt.source + "|" + no.source, "gi"), oo = /^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;
1223
- function co(u, e) {
1224
- if (e.charCodeAt(0) === 35 && oo.test(e)) {
1226
+ const zt = /\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g, nc = /&([a-z#][a-z0-9]{1,31});/gi, rc = new RegExp(zt.source + "|" + nc.source, "gi"), cc = /^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))$/i;
1227
+ function oc(u, e) {
1228
+ if (e.charCodeAt(0) === 35 && cc.test(e)) {
1225
1229
  const n = e[1].toLowerCase() === "x" ? parseInt(e.slice(2), 16) : parseInt(e.slice(1), 10);
1226
- return _0(n) ? Fe(n) : u;
1230
+ return m0(n) ? De(n) : u;
1227
1231
  }
1228
1232
  const t = Bt(u);
1229
1233
  return t !== u ? t : u;
1230
1234
  }
1231
- function io(u) {
1235
+ function ic(u) {
1232
1236
  return u.indexOf("\\") < 0 ? u : u.replace(zt, "$1");
1233
1237
  }
1234
1238
  function qu(u) {
1235
- return u.indexOf("\\") < 0 && u.indexOf("&") < 0 ? u : u.replace(ro, function(e, t, n) {
1236
- return t || co(e, n);
1239
+ return u.indexOf("\\") < 0 && u.indexOf("&") < 0 ? u : u.replace(rc, function(e, t, n) {
1240
+ return t || oc(e, n);
1237
1241
  });
1238
1242
  }
1239
- const ao = /[&<>"]/, so = /[&<>"]/g, lo = {
1243
+ const ac = /[&<>"]/, sc = /[&<>"]/g, lc = {
1240
1244
  "&": "&amp;",
1241
1245
  "<": "&lt;",
1242
1246
  ">": "&gt;",
1243
1247
  '"': "&quot;"
1244
1248
  };
1245
- function fo(u) {
1246
- return lo[u];
1249
+ function fc(u) {
1250
+ return lc[u];
1247
1251
  }
1248
- function xu(u) {
1249
- return ao.test(u) ? u.replace(so, fo) : u;
1252
+ function gu(u) {
1253
+ return ac.test(u) ? u.replace(sc, fc) : u;
1250
1254
  }
1251
- const ho = /[.?*+^$[\]\\(){}|-]/g;
1252
- function po(u) {
1253
- return u.replace(ho, "\\$&");
1255
+ const dc = /[.?*+^$[\]\\(){}|-]/g;
1256
+ function hc(u) {
1257
+ return u.replace(dc, "\\$&");
1254
1258
  }
1255
- function w(u) {
1259
+ function S(u) {
1256
1260
  switch (u) {
1257
1261
  case 9:
1258
1262
  case 32:
@@ -1260,7 +1264,7 @@ function w(u) {
1260
1264
  }
1261
1265
  return !1;
1262
1266
  }
1263
- function ue(u) {
1267
+ function Ku(u) {
1264
1268
  if (u >= 8192 && u <= 8202)
1265
1269
  return !0;
1266
1270
  switch (u) {
@@ -1279,10 +1283,10 @@ function ue(u) {
1279
1283
  }
1280
1284
  return !1;
1281
1285
  }
1282
- function ee(u) {
1283
- return b0.test(u) || Lt.test(u);
1286
+ function ue(u) {
1287
+ return p0.test(u) || Lt.test(u);
1284
1288
  }
1285
- function te(u) {
1289
+ function ee(u) {
1286
1290
  switch (u) {
1287
1291
  case 33:
1288
1292
  case 34:
@@ -1321,37 +1325,37 @@ function te(u) {
1321
1325
  return !1;
1322
1326
  }
1323
1327
  }
1324
- function we(u) {
1328
+ function Te(u) {
1325
1329
  return u = u.trim().replace(/\s+/g, " "), "ẞ".toLowerCase() === "Ṿ" && (u = u.replace(/ẞ/g, "ß")), u.toLowerCase().toUpperCase();
1326
1330
  }
1327
- const bo = { mdurl: zr, ucmicro: Ur }, mo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1331
+ const bc = { mdurl: zr, ucmicro: Ur }, pc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1328
1332
  __proto__: null,
1329
1333
  arrayReplaceAt: Pt,
1330
- assign: Se,
1331
- escapeHtml: xu,
1332
- escapeRE: po,
1333
- fromCodePoint: Fe,
1334
- has: to,
1335
- isMdAsciiPunct: te,
1336
- isPunctChar: ee,
1337
- isSpace: w,
1338
- isString: m0,
1339
- isValidEntityCode: _0,
1340
- isWhiteSpace: ue,
1341
- lib: bo,
1342
- normalizeReference: we,
1334
+ assign: Fe,
1335
+ escapeHtml: gu,
1336
+ escapeRE: hc,
1337
+ fromCodePoint: De,
1338
+ has: tc,
1339
+ isMdAsciiPunct: ee,
1340
+ isPunctChar: ue,
1341
+ isSpace: S,
1342
+ isString: _0,
1343
+ isValidEntityCode: m0,
1344
+ isWhiteSpace: Ku,
1345
+ lib: bc,
1346
+ normalizeReference: Te,
1343
1347
  unescapeAll: qu,
1344
- unescapeMd: io
1348
+ unescapeMd: ic
1345
1349
  }, Symbol.toStringTag, { value: "Module" }));
1346
- function _o(u, e, t) {
1347
- let n, r, o, i;
1348
- const c = u.posMax, a = u.pos;
1349
- for (u.pos = e + 1, n = 1; u.pos < c; ) {
1350
- if (o = u.src.charCodeAt(u.pos), o === 93 && (n--, n === 0)) {
1350
+ function _c(u, e, t) {
1351
+ let n, r, c, i;
1352
+ const o = u.posMax, a = u.pos;
1353
+ for (u.pos = e + 1, n = 1; u.pos < o; ) {
1354
+ if (c = u.src.charCodeAt(u.pos), c === 93 && (n--, n === 0)) {
1351
1355
  r = !0;
1352
1356
  break;
1353
1357
  }
1354
- if (i = u.pos, u.md.inline.skipToken(u), o === 91) {
1358
+ if (i = u.pos, u.md.inline.skipToken(u), c === 91) {
1355
1359
  if (i === u.pos - 1)
1356
1360
  n++;
1357
1361
  else if (t)
@@ -1361,9 +1365,9 @@ function _o(u, e, t) {
1361
1365
  let s = -1;
1362
1366
  return r && (s = u.pos), u.pos = a, s;
1363
1367
  }
1364
- function xo(u, e, t) {
1368
+ function mc(u, e, t) {
1365
1369
  let n, r = e;
1366
- const o = {
1370
+ const c = {
1367
1371
  ok: !1,
1368
1372
  pos: 0,
1369
1373
  str: ""
@@ -1371,16 +1375,16 @@ function xo(u, e, t) {
1371
1375
  if (u.charCodeAt(r) === 60) {
1372
1376
  for (r++; r < t; ) {
1373
1377
  if (n = u.charCodeAt(r), n === 10 || n === 60)
1374
- return o;
1378
+ return c;
1375
1379
  if (n === 62)
1376
- return o.pos = r + 1, o.str = qu(u.slice(e + 1, r)), o.ok = !0, o;
1380
+ return c.pos = r + 1, c.str = qu(u.slice(e + 1, r)), c.ok = !0, c;
1377
1381
  if (n === 92 && r + 1 < t) {
1378
1382
  r += 2;
1379
1383
  continue;
1380
1384
  }
1381
1385
  r++;
1382
1386
  }
1383
- return o;
1387
+ return c;
1384
1388
  }
1385
1389
  let i = 0;
1386
1390
  for (; r < t && (n = u.charCodeAt(r), !(n === 32 || n < 32 || n === 127)); ) {
@@ -1391,7 +1395,7 @@ function xo(u, e, t) {
1391
1395
  continue;
1392
1396
  }
1393
1397
  if (n === 40 && (i++, i > 32))
1394
- return o;
1398
+ return c;
1395
1399
  if (n === 41) {
1396
1400
  if (i === 0)
1397
1401
  break;
@@ -1399,10 +1403,10 @@ function xo(u, e, t) {
1399
1403
  }
1400
1404
  r++;
1401
1405
  }
1402
- return e === r || i !== 0 || (o.str = qu(u.slice(e, r)), o.pos = r, o.ok = !0), o;
1406
+ return e === r || i !== 0 || (c.str = qu(u.slice(e, r)), c.pos = r, c.ok = !0), c;
1403
1407
  }
1404
- function go(u, e, t, n) {
1405
- let r, o = e;
1408
+ function xc(u, e, t, n) {
1409
+ let r, c = e;
1406
1410
  const i = {
1407
1411
  // if `true`, this is a valid link title
1408
1412
  ok: !1,
@@ -1418,122 +1422,122 @@ function go(u, e, t, n) {
1418
1422
  if (n)
1419
1423
  i.str = n.str, i.marker = n.marker;
1420
1424
  else {
1421
- if (o >= t)
1425
+ if (c >= t)
1422
1426
  return i;
1423
- let c = u.charCodeAt(o);
1424
- if (c !== 34 && c !== 39 && c !== 40)
1427
+ let o = u.charCodeAt(c);
1428
+ if (o !== 34 && o !== 39 && o !== 40)
1425
1429
  return i;
1426
- e++, o++, c === 40 && (c = 41), i.marker = c;
1430
+ e++, c++, o === 40 && (o = 41), i.marker = o;
1427
1431
  }
1428
- for (; o < t; ) {
1429
- if (r = u.charCodeAt(o), r === i.marker)
1430
- return i.pos = o + 1, i.str += qu(u.slice(e, o)), i.ok = !0, i;
1432
+ for (; c < t; ) {
1433
+ if (r = u.charCodeAt(c), r === i.marker)
1434
+ return i.pos = c + 1, i.str += qu(u.slice(e, c)), i.ok = !0, i;
1431
1435
  if (r === 40 && i.marker === 41)
1432
1436
  return i;
1433
- r === 92 && o + 1 < t && o++, o++;
1437
+ r === 92 && c + 1 < t && c++, c++;
1434
1438
  }
1435
- return i.can_continue = !0, i.str += qu(u.slice(e, o)), i;
1439
+ return i.can_continue = !0, i.str += qu(u.slice(e, c)), i;
1436
1440
  }
1437
- const ko = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1441
+ const gc = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1438
1442
  __proto__: null,
1439
- parseLinkDestination: xo,
1440
- parseLinkLabel: _o,
1441
- parseLinkTitle: go
1442
- }, Symbol.toStringTag, { value: "Module" })), iu = {};
1443
- iu.code_inline = function(u, e, t, n, r) {
1444
- const o = u[e];
1445
- return "<code" + r.renderAttrs(o) + ">" + xu(o.content) + "</code>";
1446
- };
1447
- iu.code_block = function(u, e, t, n, r) {
1448
- const o = u[e];
1449
- return "<pre" + r.renderAttrs(o) + "><code>" + xu(u[e].content) + `</code></pre>
1443
+ parseLinkDestination: mc,
1444
+ parseLinkLabel: _c,
1445
+ parseLinkTitle: xc
1446
+ }, Symbol.toStringTag, { value: "Module" })), au = {};
1447
+ au.code_inline = function(u, e, t, n, r) {
1448
+ const c = u[e];
1449
+ return "<code" + r.renderAttrs(c) + ">" + gu(c.content) + "</code>";
1450
+ };
1451
+ au.code_block = function(u, e, t, n, r) {
1452
+ const c = u[e];
1453
+ return "<pre" + r.renderAttrs(c) + "><code>" + gu(u[e].content) + `</code></pre>
1450
1454
  `;
1451
1455
  };
1452
- iu.fence = function(u, e, t, n, r) {
1453
- const o = u[e], i = o.info ? qu(o.info).trim() : "";
1454
- let c = "", a = "";
1456
+ au.fence = function(u, e, t, n, r) {
1457
+ const c = u[e], i = c.info ? qu(c.info).trim() : "";
1458
+ let o = "", a = "";
1455
1459
  if (i) {
1456
1460
  const f = i.split(/(\s+)/g);
1457
- c = f[0], a = f.slice(2).join("");
1461
+ o = f[0], a = f.slice(2).join("");
1458
1462
  }
1459
1463
  let s;
1460
- if (t.highlight ? s = t.highlight(o.content, c, a) || xu(o.content) : s = xu(o.content), s.indexOf("<pre") === 0)
1464
+ if (t.highlight ? s = t.highlight(c.content, o, a) || gu(c.content) : s = gu(c.content), s.indexOf("<pre") === 0)
1461
1465
  return s + `
1462
1466
  `;
1463
1467
  if (i) {
1464
- const f = o.attrIndex("class"), d = o.attrs ? o.attrs.slice() : [];
1465
- f < 0 ? d.push(["class", t.langPrefix + c]) : (d[f] = d[f].slice(), d[f][1] += " " + t.langPrefix + c);
1466
- const m = {
1468
+ const f = c.attrIndex("class"), d = c.attrs ? c.attrs.slice() : [];
1469
+ f < 0 ? d.push(["class", t.langPrefix + o]) : (d[f] = d[f].slice(), d[f][1] += " " + t.langPrefix + o);
1470
+ const _ = {
1467
1471
  attrs: d
1468
1472
  };
1469
- return `<pre><code${r.renderAttrs(m)}>${s}</code></pre>
1473
+ return `<pre><code${r.renderAttrs(_)}>${s}</code></pre>
1470
1474
  `;
1471
1475
  }
1472
- return `<pre><code${r.renderAttrs(o)}>${s}</code></pre>
1476
+ return `<pre><code${r.renderAttrs(c)}>${s}</code></pre>
1473
1477
  `;
1474
1478
  };
1475
- iu.image = function(u, e, t, n, r) {
1476
- const o = u[e];
1477
- return o.attrs[o.attrIndex("alt")][1] = r.renderInlineAsText(o.children, t, n), r.renderToken(u, e, t);
1479
+ au.image = function(u, e, t, n, r) {
1480
+ const c = u[e];
1481
+ return c.attrs[c.attrIndex("alt")][1] = r.renderInlineAsText(c.children, t, n), r.renderToken(u, e, t);
1478
1482
  };
1479
- iu.hardbreak = function(u, e, t) {
1483
+ au.hardbreak = function(u, e, t) {
1480
1484
  return t.xhtmlOut ? `<br />
1481
1485
  ` : `<br>
1482
1486
  `;
1483
1487
  };
1484
- iu.softbreak = function(u, e, t) {
1488
+ au.softbreak = function(u, e, t) {
1485
1489
  return t.breaks ? t.xhtmlOut ? `<br />
1486
1490
  ` : `<br>
1487
1491
  ` : `
1488
1492
  `;
1489
1493
  };
1490
- iu.text = function(u, e) {
1491
- return xu(u[e].content);
1494
+ au.text = function(u, e) {
1495
+ return gu(u[e].content);
1492
1496
  };
1493
- iu.html_block = function(u, e) {
1497
+ au.html_block = function(u, e) {
1494
1498
  return u[e].content;
1495
1499
  };
1496
- iu.html_inline = function(u, e) {
1500
+ au.html_inline = function(u, e) {
1497
1501
  return u[e].content;
1498
1502
  };
1499
1503
  function Uu() {
1500
- this.rules = Se({}, iu);
1504
+ this.rules = Fe({}, au);
1501
1505
  }
1502
1506
  Uu.prototype.renderAttrs = function(e) {
1503
1507
  let t, n, r;
1504
1508
  if (!e.attrs)
1505
1509
  return "";
1506
1510
  for (r = "", t = 0, n = e.attrs.length; t < n; t++)
1507
- r += " " + xu(e.attrs[t][0]) + '="' + xu(e.attrs[t][1]) + '"';
1511
+ r += " " + gu(e.attrs[t][0]) + '="' + gu(e.attrs[t][1]) + '"';
1508
1512
  return r;
1509
1513
  };
1510
1514
  Uu.prototype.renderToken = function(e, t, n) {
1511
1515
  const r = e[t];
1512
- let o = "";
1516
+ let c = "";
1513
1517
  if (r.hidden)
1514
1518
  return "";
1515
- r.block && r.nesting !== -1 && t && e[t - 1].hidden && (o += `
1516
- `), o += (r.nesting === -1 ? "</" : "<") + r.tag, o += this.renderAttrs(r), r.nesting === 0 && n.xhtmlOut && (o += " /");
1519
+ r.block && r.nesting !== -1 && t && e[t - 1].hidden && (c += `
1520
+ `), c += (r.nesting === -1 ? "</" : "<") + r.tag, c += this.renderAttrs(r), r.nesting === 0 && n.xhtmlOut && (c += " /");
1517
1521
  let i = !1;
1518
1522
  if (r.block && (i = !0, r.nesting === 1 && t + 1 < e.length)) {
1519
- const c = e[t + 1];
1520
- (c.type === "inline" || c.hidden || c.nesting === -1 && c.tag === r.tag) && (i = !1);
1523
+ const o = e[t + 1];
1524
+ (o.type === "inline" || o.hidden || o.nesting === -1 && o.tag === r.tag) && (i = !1);
1521
1525
  }
1522
- return o += i ? `>
1523
- ` : ">", o;
1526
+ return c += i ? `>
1527
+ ` : ">", c;
1524
1528
  };
1525
1529
  Uu.prototype.renderInline = function(u, e, t) {
1526
1530
  let n = "";
1527
1531
  const r = this.rules;
1528
- for (let o = 0, i = u.length; o < i; o++) {
1529
- const c = u[o].type;
1530
- typeof r[c] < "u" ? n += r[c](u, o, e, t, this) : n += this.renderToken(u, o, e);
1532
+ for (let c = 0, i = u.length; c < i; c++) {
1533
+ const o = u[c].type;
1534
+ typeof r[o] < "u" ? n += r[o](u, c, e, t, this) : n += this.renderToken(u, c, e);
1531
1535
  }
1532
1536
  return n;
1533
1537
  };
1534
1538
  Uu.prototype.renderInlineAsText = function(u, e, t) {
1535
1539
  let n = "";
1536
- for (let r = 0, o = u.length; r < o; r++)
1540
+ for (let r = 0, c = u.length; r < c; r++)
1537
1541
  switch (u[r].type) {
1538
1542
  case "text":
1539
1543
  n += u[r].content;
@@ -1556,22 +1560,22 @@ Uu.prototype.renderInlineAsText = function(u, e, t) {
1556
1560
  Uu.prototype.render = function(u, e, t) {
1557
1561
  let n = "";
1558
1562
  const r = this.rules;
1559
- for (let o = 0, i = u.length; o < i; o++) {
1560
- const c = u[o].type;
1561
- c === "inline" ? n += this.renderInline(u[o].children, e, t) : typeof r[c] < "u" ? n += r[c](u, o, e, t, this) : n += this.renderToken(u, o, e, t);
1563
+ for (let c = 0, i = u.length; c < i; c++) {
1564
+ const o = u[c].type;
1565
+ o === "inline" ? n += this.renderInline(u[c].children, e, t) : typeof r[o] < "u" ? n += r[o](u, c, e, t, this) : n += this.renderToken(u, c, e, t);
1562
1566
  }
1563
1567
  return n;
1564
1568
  };
1565
- function V() {
1569
+ function Z() {
1566
1570
  this.__rules__ = [], this.__cache__ = null;
1567
1571
  }
1568
- V.prototype.__find__ = function(u) {
1572
+ Z.prototype.__find__ = function(u) {
1569
1573
  for (let e = 0; e < this.__rules__.length; e++)
1570
1574
  if (this.__rules__[e].name === u)
1571
1575
  return e;
1572
1576
  return -1;
1573
1577
  };
1574
- V.prototype.__compile__ = function() {
1578
+ Z.prototype.__compile__ = function() {
1575
1579
  const u = this, e = [""];
1576
1580
  u.__rules__.forEach(function(t) {
1577
1581
  t.enabled && t.alt.forEach(function(n) {
@@ -1583,35 +1587,35 @@ V.prototype.__compile__ = function() {
1583
1587
  });
1584
1588
  });
1585
1589
  };
1586
- V.prototype.at = function(u, e, t) {
1590
+ Z.prototype.at = function(u, e, t) {
1587
1591
  const n = this.__find__(u), r = t || {};
1588
1592
  if (n === -1)
1589
1593
  throw new Error("Parser rule not found: " + u);
1590
1594
  this.__rules__[n].fn = e, this.__rules__[n].alt = r.alt || [], this.__cache__ = null;
1591
1595
  };
1592
- V.prototype.before = function(u, e, t, n) {
1593
- const r = this.__find__(u), o = n || {};
1596
+ Z.prototype.before = function(u, e, t, n) {
1597
+ const r = this.__find__(u), c = n || {};
1594
1598
  if (r === -1)
1595
1599
  throw new Error("Parser rule not found: " + u);
1596
1600
  this.__rules__.splice(r, 0, {
1597
1601
  name: e,
1598
1602
  enabled: !0,
1599
1603
  fn: t,
1600
- alt: o.alt || []
1604
+ alt: c.alt || []
1601
1605
  }), this.__cache__ = null;
1602
1606
  };
1603
- V.prototype.after = function(u, e, t, n) {
1604
- const r = this.__find__(u), o = n || {};
1607
+ Z.prototype.after = function(u, e, t, n) {
1608
+ const r = this.__find__(u), c = n || {};
1605
1609
  if (r === -1)
1606
1610
  throw new Error("Parser rule not found: " + u);
1607
1611
  this.__rules__.splice(r + 1, 0, {
1608
1612
  name: e,
1609
1613
  enabled: !0,
1610
1614
  fn: t,
1611
- alt: o.alt || []
1615
+ alt: c.alt || []
1612
1616
  }), this.__cache__ = null;
1613
1617
  };
1614
- V.prototype.push = function(u, e, t) {
1618
+ Z.prototype.push = function(u, e, t) {
1615
1619
  const n = t || {};
1616
1620
  this.__rules__.push({
1617
1621
  name: u,
@@ -1620,7 +1624,7 @@ V.prototype.push = function(u, e, t) {
1620
1624
  alt: n.alt || []
1621
1625
  }), this.__cache__ = null;
1622
1626
  };
1623
- V.prototype.enable = function(u, e) {
1627
+ Z.prototype.enable = function(u, e) {
1624
1628
  Array.isArray(u) || (u = [u]);
1625
1629
  const t = [];
1626
1630
  return u.forEach(function(n) {
@@ -1633,12 +1637,12 @@ V.prototype.enable = function(u, e) {
1633
1637
  this.__rules__[r].enabled = !0, t.push(n);
1634
1638
  }, this), this.__cache__ = null, t;
1635
1639
  };
1636
- V.prototype.enableOnly = function(u, e) {
1640
+ Z.prototype.enableOnly = function(u, e) {
1637
1641
  Array.isArray(u) || (u = [u]), this.__rules__.forEach(function(t) {
1638
1642
  t.enabled = !1;
1639
1643
  }), this.enable(u, e);
1640
1644
  };
1641
- V.prototype.disable = function(u, e) {
1645
+ Z.prototype.disable = function(u, e) {
1642
1646
  Array.isArray(u) || (u = [u]);
1643
1647
  const t = [];
1644
1648
  return u.forEach(function(n) {
@@ -1651,13 +1655,13 @@ V.prototype.disable = function(u, e) {
1651
1655
  this.__rules__[r].enabled = !1, t.push(n);
1652
1656
  }, this), this.__cache__ = null, t;
1653
1657
  };
1654
- V.prototype.getRules = function(u) {
1658
+ Z.prototype.getRules = function(u) {
1655
1659
  return this.__cache__ === null && this.__compile__(), this.__cache__[u] || [];
1656
1660
  };
1657
- function tu(u, e, t) {
1661
+ function eu(u, e, t) {
1658
1662
  this.type = u, this.tag = e, this.attrs = null, this.map = null, this.nesting = t, this.level = 0, this.children = null, this.content = "", this.markup = "", this.info = "", this.meta = null, this.block = !1, this.hidden = !1;
1659
1663
  }
1660
- tu.prototype.attrIndex = function(e) {
1664
+ eu.prototype.attrIndex = function(e) {
1661
1665
  if (!this.attrs)
1662
1666
  return -1;
1663
1667
  const t = this.attrs;
@@ -1666,150 +1670,150 @@ tu.prototype.attrIndex = function(e) {
1666
1670
  return n;
1667
1671
  return -1;
1668
1672
  };
1669
- tu.prototype.attrPush = function(e) {
1673
+ eu.prototype.attrPush = function(e) {
1670
1674
  this.attrs ? this.attrs.push(e) : this.attrs = [e];
1671
1675
  };
1672
- tu.prototype.attrSet = function(e, t) {
1676
+ eu.prototype.attrSet = function(e, t) {
1673
1677
  const n = this.attrIndex(e), r = [e, t];
1674
1678
  n < 0 ? this.attrPush(r) : this.attrs[n] = r;
1675
1679
  };
1676
- tu.prototype.attrGet = function(e) {
1680
+ eu.prototype.attrGet = function(e) {
1677
1681
  const t = this.attrIndex(e);
1678
1682
  let n = null;
1679
1683
  return t >= 0 && (n = this.attrs[t][1]), n;
1680
1684
  };
1681
- tu.prototype.attrJoin = function(e, t) {
1685
+ eu.prototype.attrJoin = function(e, t) {
1682
1686
  const n = this.attrIndex(e);
1683
1687
  n < 0 ? this.attrPush([e, t]) : this.attrs[n][1] = this.attrs[n][1] + " " + t;
1684
1688
  };
1685
1689
  function qt(u, e, t) {
1686
1690
  this.src = u, this.env = t, this.tokens = [], this.inlineMode = !1, this.md = e;
1687
1691
  }
1688
- qt.prototype.Token = tu;
1689
- const Eo = /\r\n?|\n/g, Ao = /\0/g;
1690
- function Co(u) {
1692
+ qt.prototype.Token = eu;
1693
+ const kc = /\r\n?|\n/g, Ec = /\0/g;
1694
+ function Ac(u) {
1691
1695
  let e;
1692
- e = u.src.replace(Eo, `
1693
- `), e = e.replace(Ao, "�"), u.src = e;
1696
+ e = u.src.replace(kc, `
1697
+ `), e = e.replace(Ec, "�"), u.src = e;
1694
1698
  }
1695
- function Do(u) {
1699
+ function Cc(u) {
1696
1700
  let e;
1697
1701
  u.inlineMode ? (e = new u.Token("inline", "", 0), e.content = u.src, e.map = [0, 1], e.children = [], u.tokens.push(e)) : u.md.block.parse(u.src, u.md, u.env, u.tokens);
1698
1702
  }
1699
- function yo(u) {
1703
+ function Dc(u) {
1700
1704
  const e = u.tokens;
1701
1705
  for (let t = 0, n = e.length; t < n; t++) {
1702
1706
  const r = e[t];
1703
1707
  r.type === "inline" && u.md.inline.parse(r.content, u.md, u.env, r.children);
1704
1708
  }
1705
1709
  }
1706
- function Fo(u) {
1710
+ function yc(u) {
1707
1711
  return /^<a[>\s]/i.test(u);
1708
1712
  }
1709
- function To(u) {
1713
+ function Fc(u) {
1710
1714
  return /^<\/a\s*>/i.test(u);
1711
1715
  }
1712
- function So(u) {
1716
+ function Tc(u) {
1713
1717
  const e = u.tokens;
1714
1718
  if (u.md.options.linkify)
1715
1719
  for (let t = 0, n = e.length; t < n; t++) {
1716
1720
  if (e[t].type !== "inline" || !u.md.linkify.pretest(e[t].content))
1717
1721
  continue;
1718
- let r = e[t].children, o = 0;
1722
+ let r = e[t].children, c = 0;
1719
1723
  for (let i = r.length - 1; i >= 0; i--) {
1720
- const c = r[i];
1721
- if (c.type === "link_close") {
1722
- for (i--; r[i].level !== c.level && r[i].type !== "link_open"; )
1724
+ const o = r[i];
1725
+ if (o.type === "link_close") {
1726
+ for (i--; r[i].level !== o.level && r[i].type !== "link_open"; )
1723
1727
  i--;
1724
1728
  continue;
1725
1729
  }
1726
- if (c.type === "html_inline" && (Fo(c.content) && o > 0 && o--, To(c.content) && o++), !(o > 0) && c.type === "text" && u.md.linkify.test(c.content)) {
1727
- const a = c.content;
1730
+ if (o.type === "html_inline" && (yc(o.content) && c > 0 && c--, Fc(o.content) && c++), !(c > 0) && o.type === "text" && u.md.linkify.test(o.content)) {
1731
+ const a = o.content;
1728
1732
  let s = u.md.linkify.match(a);
1729
1733
  const f = [];
1730
- let d = c.level, m = 0;
1734
+ let d = o.level, _ = 0;
1731
1735
  s.length > 0 && s[0].index === 0 && i > 0 && r[i - 1].type === "text_special" && (s = s.slice(1));
1732
- for (let p = 0; p < s.length; p++) {
1733
- const h = s[p].url, C = u.md.normalizeLink(h);
1736
+ for (let b = 0; b < s.length; b++) {
1737
+ const h = s[b].url, C = u.md.normalizeLink(h);
1734
1738
  if (!u.md.validateLink(C))
1735
1739
  continue;
1736
- let D = s[p].text;
1737
- s[p].schema ? s[p].schema === "mailto:" && !/^mailto:/i.test(D) ? D = u.md.normalizeLinkText("mailto:" + D).replace(/^mailto:/, "") : D = u.md.normalizeLinkText(D) : D = u.md.normalizeLinkText("http://" + D).replace(/^http:\/\//, "");
1738
- const T = s[p].index;
1739
- if (T > m) {
1740
+ let y = s[b].text;
1741
+ s[b].schema ? s[b].schema === "mailto:" && !/^mailto:/i.test(y) ? y = u.md.normalizeLinkText("mailto:" + y).replace(/^mailto:/, "") : y = u.md.normalizeLinkText(y) : y = u.md.normalizeLinkText("http://" + y).replace(/^http:\/\//, "");
1742
+ const T = s[b].index;
1743
+ if (T > _) {
1740
1744
  const A = new u.Token("text", "", 0);
1741
- A.content = a.slice(m, T), A.level = d, f.push(A);
1745
+ A.content = a.slice(_, T), A.level = d, f.push(A);
1742
1746
  }
1743
1747
  const E = new u.Token("link_open", "a", 1);
1744
1748
  E.attrs = [["href", C]], E.level = d++, E.markup = "linkify", E.info = "auto", f.push(E);
1745
1749
  const k = new u.Token("text", "", 0);
1746
- k.content = D, k.level = d, f.push(k);
1747
- const _ = new u.Token("link_close", "a", -1);
1748
- _.level = --d, _.markup = "linkify", _.info = "auto", f.push(_), m = s[p].lastIndex;
1750
+ k.content = y, k.level = d, f.push(k);
1751
+ const m = new u.Token("link_close", "a", -1);
1752
+ m.level = --d, m.markup = "linkify", m.info = "auto", f.push(m), _ = s[b].lastIndex;
1749
1753
  }
1750
- if (m < a.length) {
1751
- const p = new u.Token("text", "", 0);
1752
- p.content = a.slice(m), p.level = d, f.push(p);
1754
+ if (_ < a.length) {
1755
+ const b = new u.Token("text", "", 0);
1756
+ b.content = a.slice(_), b.level = d, f.push(b);
1753
1757
  }
1754
1758
  e[t].children = r = Pt(r, i, f);
1755
1759
  }
1756
1760
  }
1757
1761
  }
1758
1762
  }
1759
- const Ut = /\+-|\.\.|\?\?\?\?|!!!!|,,|--/, wo = /\((c|tm|r)\)/i, vo = /\((c|tm|r)\)/ig, Ro = {
1763
+ const Ut = /\+-|\.\.|\?\?\?\?|!!!!|,,|--/, Sc = /\((c|tm|r)\)/i, wc = /\((c|tm|r)\)/ig, vc = {
1760
1764
  c: "©",
1761
1765
  r: "®",
1762
1766
  tm: "™"
1763
1767
  };
1764
- function Io(u, e) {
1765
- return Ro[e.toLowerCase()];
1768
+ function Rc(u, e) {
1769
+ return vc[e.toLowerCase()];
1766
1770
  }
1767
- function Mo(u) {
1771
+ function Ic(u) {
1768
1772
  let e = 0;
1769
1773
  for (let t = u.length - 1; t >= 0; t--) {
1770
1774
  const n = u[t];
1771
- n.type === "text" && !e && (n.content = n.content.replace(vo, Io)), n.type === "link_open" && n.info === "auto" && e--, n.type === "link_close" && n.info === "auto" && e++;
1775
+ n.type === "text" && !e && (n.content = n.content.replace(wc, Rc)), n.type === "link_open" && n.info === "auto" && e--, n.type === "link_close" && n.info === "auto" && e++;
1772
1776
  }
1773
1777
  }
1774
- function Lo(u) {
1778
+ function Mc(u) {
1775
1779
  let e = 0;
1776
1780
  for (let t = u.length - 1; t >= 0; t--) {
1777
1781
  const n = u[t];
1778
1782
  n.type === "text" && !e && Ut.test(n.content) && (n.content = n.content.replace(/\+-/g, "±").replace(/\.{2,}/g, "…").replace(/([?!])…/g, "$1..").replace(/([?!]){4,}/g, "$1$1$1").replace(/,{2,}/g, ",").replace(/(^|[^-])---(?=[^-]|$)/mg, "$1—").replace(/(^|\s)--(?=\s|$)/mg, "$1–").replace(/(^|[^-\s])--(?=[^-\s]|$)/mg, "$1–")), n.type === "link_open" && n.info === "auto" && e--, n.type === "link_close" && n.info === "auto" && e++;
1779
1783
  }
1780
1784
  }
1781
- function Oo(u) {
1785
+ function Lc(u) {
1782
1786
  let e;
1783
1787
  if (u.md.options.typographer)
1784
1788
  for (e = u.tokens.length - 1; e >= 0; e--)
1785
- u.tokens[e].type === "inline" && (wo.test(u.tokens[e].content) && Mo(u.tokens[e].children), Ut.test(u.tokens[e].content) && Lo(u.tokens[e].children));
1789
+ u.tokens[e].type === "inline" && (Sc.test(u.tokens[e].content) && Ic(u.tokens[e].children), Ut.test(u.tokens[e].content) && Mc(u.tokens[e].children));
1786
1790
  }
1787
- const No = /['"]/, ht = /['"]/g, pt = "’";
1788
- function ge(u, e, t) {
1791
+ const Oc = /['"]/, dt = /['"]/g, ht = "’";
1792
+ function xe(u, e, t) {
1789
1793
  return u.slice(0, e) + t + u.slice(e + 1);
1790
1794
  }
1791
- function Bo(u, e) {
1795
+ function Nc(u, e) {
1792
1796
  let t;
1793
1797
  const n = [];
1794
1798
  for (let r = 0; r < u.length; r++) {
1795
- const o = u[r], i = u[r].level;
1799
+ const c = u[r], i = u[r].level;
1796
1800
  for (t = n.length - 1; t >= 0 && !(n[t].level <= i); t--)
1797
1801
  ;
1798
- if (n.length = t + 1, o.type !== "text")
1802
+ if (n.length = t + 1, c.type !== "text")
1799
1803
  continue;
1800
- let c = o.content, a = 0, s = c.length;
1804
+ let o = c.content, a = 0, s = o.length;
1801
1805
  u:
1802
1806
  for (; a < s; ) {
1803
- ht.lastIndex = a;
1804
- const f = ht.exec(c);
1807
+ dt.lastIndex = a;
1808
+ const f = dt.exec(o);
1805
1809
  if (!f)
1806
1810
  break;
1807
- let d = !0, m = !0;
1811
+ let d = !0, _ = !0;
1808
1812
  a = f.index + 1;
1809
- const p = f[0] === "'";
1813
+ const b = f[0] === "'";
1810
1814
  let h = 32;
1811
1815
  if (f.index - 1 >= 0)
1812
- h = c.charCodeAt(f.index - 1);
1816
+ h = o.charCodeAt(f.index - 1);
1813
1817
  else
1814
1818
  for (t = r - 1; t >= 0 && !(u[t].type === "softbreak" || u[t].type === "hardbreak"); t--)
1815
1819
  if (u[t].content) {
@@ -1818,74 +1822,74 @@ function Bo(u, e) {
1818
1822
  }
1819
1823
  let C = 32;
1820
1824
  if (a < s)
1821
- C = c.charCodeAt(a);
1825
+ C = o.charCodeAt(a);
1822
1826
  else
1823
1827
  for (t = r + 1; t < u.length && !(u[t].type === "softbreak" || u[t].type === "hardbreak"); t++)
1824
1828
  if (u[t].content) {
1825
1829
  C = u[t].content.charCodeAt(0);
1826
1830
  break;
1827
1831
  }
1828
- const D = te(h) || ee(String.fromCharCode(h)), T = te(C) || ee(String.fromCharCode(C)), E = ue(h), k = ue(C);
1829
- if (k ? d = !1 : T && (E || D || (d = !1)), E ? m = !1 : D && (k || T || (m = !1)), C === 34 && f[0] === '"' && h >= 48 && h <= 57 && (m = d = !1), d && m && (d = D, m = T), !d && !m) {
1830
- p && (o.content = ge(o.content, f.index, pt));
1832
+ const y = ee(h) || ue(String.fromCharCode(h)), T = ee(C) || ue(String.fromCharCode(C)), E = Ku(h), k = Ku(C);
1833
+ if (k ? d = !1 : T && (E || y || (d = !1)), E ? _ = !1 : y && (k || T || (_ = !1)), C === 34 && f[0] === '"' && h >= 48 && h <= 57 && (_ = d = !1), d && _ && (d = y, _ = T), !d && !_) {
1834
+ b && (c.content = xe(c.content, f.index, ht));
1831
1835
  continue;
1832
1836
  }
1833
- if (m)
1837
+ if (_)
1834
1838
  for (t = n.length - 1; t >= 0; t--) {
1835
- let _ = n[t];
1839
+ let m = n[t];
1836
1840
  if (n[t].level < i)
1837
1841
  break;
1838
- if (_.single === p && n[t].level === i) {
1839
- _ = n[t];
1840
- let A, y;
1841
- p ? (A = e.md.options.quotes[2], y = e.md.options.quotes[3]) : (A = e.md.options.quotes[0], y = e.md.options.quotes[1]), o.content = ge(o.content, f.index, y), u[_.token].content = ge(
1842
- u[_.token].content,
1843
- _.pos,
1842
+ if (m.single === b && n[t].level === i) {
1843
+ m = n[t];
1844
+ let A, F;
1845
+ b ? (A = e.md.options.quotes[2], F = e.md.options.quotes[3]) : (A = e.md.options.quotes[0], F = e.md.options.quotes[1]), c.content = xe(c.content, f.index, F), u[m.token].content = xe(
1846
+ u[m.token].content,
1847
+ m.pos,
1844
1848
  A
1845
- ), a += y.length - 1, _.token === r && (a += A.length - 1), c = o.content, s = c.length, n.length = t;
1849
+ ), a += F.length - 1, m.token === r && (a += A.length - 1), o = c.content, s = o.length, n.length = t;
1846
1850
  continue u;
1847
1851
  }
1848
1852
  }
1849
1853
  d ? n.push({
1850
1854
  token: r,
1851
1855
  pos: f.index,
1852
- single: p,
1856
+ single: b,
1853
1857
  level: i
1854
- }) : m && p && (o.content = ge(o.content, f.index, pt));
1858
+ }) : _ && b && (c.content = xe(c.content, f.index, ht));
1855
1859
  }
1856
1860
  }
1857
1861
  }
1858
- function Po(u) {
1862
+ function Bc(u) {
1859
1863
  if (u.md.options.typographer)
1860
1864
  for (let e = u.tokens.length - 1; e >= 0; e--)
1861
- u.tokens[e].type !== "inline" || !No.test(u.tokens[e].content) || Bo(u.tokens[e].children, u);
1865
+ u.tokens[e].type !== "inline" || !Oc.test(u.tokens[e].content) || Nc(u.tokens[e].children, u);
1862
1866
  }
1863
- function zo(u) {
1867
+ function Pc(u) {
1864
1868
  let e, t;
1865
1869
  const n = u.tokens, r = n.length;
1866
- for (let o = 0; o < r; o++) {
1867
- if (n[o].type !== "inline") continue;
1868
- const i = n[o].children, c = i.length;
1869
- for (e = 0; e < c; e++)
1870
+ for (let c = 0; c < r; c++) {
1871
+ if (n[c].type !== "inline") continue;
1872
+ const i = n[c].children, o = i.length;
1873
+ for (e = 0; e < o; e++)
1870
1874
  i[e].type === "text_special" && (i[e].type = "text");
1871
- for (e = t = 0; e < c; e++)
1872
- i[e].type === "text" && e + 1 < c && i[e + 1].type === "text" ? i[e + 1].content = i[e].content + i[e + 1].content : (e !== t && (i[t] = i[e]), t++);
1875
+ for (e = t = 0; e < o; e++)
1876
+ i[e].type === "text" && e + 1 < o && i[e + 1].type === "text" ? i[e + 1].content = i[e].content + i[e + 1].content : (e !== t && (i[t] = i[e]), t++);
1873
1877
  e !== t && (i.length = t);
1874
1878
  }
1875
1879
  }
1876
1880
  const Je = [
1877
- ["normalize", Co],
1878
- ["block", Do],
1879
- ["inline", yo],
1880
- ["linkify", So],
1881
- ["replacements", Oo],
1882
- ["smartquotes", Po],
1881
+ ["normalize", Ac],
1882
+ ["block", Cc],
1883
+ ["inline", Dc],
1884
+ ["linkify", Tc],
1885
+ ["replacements", Lc],
1886
+ ["smartquotes", Bc],
1883
1887
  // `text_join` finds `text_special` tokens (for escape sequences)
1884
1888
  // and joins them with the rest of the text
1885
- ["text_join", zo]
1889
+ ["text_join", Pc]
1886
1890
  ];
1887
1891
  function x0() {
1888
- this.ruler = new V();
1892
+ this.ruler = new Z();
1889
1893
  for (let u = 0; u < Je.length; u++)
1890
1894
  this.ruler.push(Je[u][0], Je[u][1]);
1891
1895
  }
@@ -1895,55 +1899,55 @@ x0.prototype.process = function(u) {
1895
1899
  e[t](u);
1896
1900
  };
1897
1901
  x0.prototype.State = qt;
1898
- function au(u, e, t, n) {
1902
+ function su(u, e, t, n) {
1899
1903
  this.src = u, this.md = e, this.env = t, this.tokens = n, this.bMarks = [], this.eMarks = [], this.tShift = [], this.sCount = [], this.bsCount = [], this.blkIndent = 0, this.line = 0, this.lineMax = 0, this.tight = !1, this.ddIndent = -1, this.listIndent = -1, this.parentType = "root", this.level = 0;
1900
1904
  const r = this.src;
1901
- for (let o = 0, i = 0, c = 0, a = 0, s = r.length, f = !1; i < s; i++) {
1905
+ for (let c = 0, i = 0, o = 0, a = 0, s = r.length, f = !1; i < s; i++) {
1902
1906
  const d = r.charCodeAt(i);
1903
1907
  if (!f)
1904
- if (w(d)) {
1905
- c++, d === 9 ? a += 4 - a % 4 : a++;
1908
+ if (S(d)) {
1909
+ o++, d === 9 ? a += 4 - a % 4 : a++;
1906
1910
  continue;
1907
1911
  } else
1908
1912
  f = !0;
1909
- (d === 10 || i === s - 1) && (d !== 10 && i++, this.bMarks.push(o), this.eMarks.push(i), this.tShift.push(c), this.sCount.push(a), this.bsCount.push(0), f = !1, c = 0, a = 0, o = i + 1);
1913
+ (d === 10 || i === s - 1) && (d !== 10 && i++, this.bMarks.push(c), this.eMarks.push(i), this.tShift.push(o), this.sCount.push(a), this.bsCount.push(0), f = !1, o = 0, a = 0, c = i + 1);
1910
1914
  }
1911
1915
  this.bMarks.push(r.length), this.eMarks.push(r.length), this.tShift.push(0), this.sCount.push(0), this.bsCount.push(0), this.lineMax = this.bMarks.length - 1;
1912
1916
  }
1913
- au.prototype.push = function(u, e, t) {
1914
- const n = new tu(u, e, t);
1917
+ su.prototype.push = function(u, e, t) {
1918
+ const n = new eu(u, e, t);
1915
1919
  return n.block = !0, t < 0 && this.level--, n.level = this.level, t > 0 && this.level++, this.tokens.push(n), n;
1916
1920
  };
1917
- au.prototype.isEmpty = function(e) {
1921
+ su.prototype.isEmpty = function(e) {
1918
1922
  return this.bMarks[e] + this.tShift[e] >= this.eMarks[e];
1919
1923
  };
1920
- au.prototype.skipEmptyLines = function(e) {
1924
+ su.prototype.skipEmptyLines = function(e) {
1921
1925
  for (let t = this.lineMax; e < t && !(this.bMarks[e] + this.tShift[e] < this.eMarks[e]); e++)
1922
1926
  ;
1923
1927
  return e;
1924
1928
  };
1925
- au.prototype.skipSpaces = function(e) {
1929
+ su.prototype.skipSpaces = function(e) {
1926
1930
  for (let t = this.src.length; e < t; e++) {
1927
1931
  const n = this.src.charCodeAt(e);
1928
- if (!w(n))
1932
+ if (!S(n))
1929
1933
  break;
1930
1934
  }
1931
1935
  return e;
1932
1936
  };
1933
- au.prototype.skipSpacesBack = function(e, t) {
1937
+ su.prototype.skipSpacesBack = function(e, t) {
1934
1938
  if (e <= t)
1935
1939
  return e;
1936
1940
  for (; e > t; )
1937
- if (!w(this.src.charCodeAt(--e)))
1941
+ if (!S(this.src.charCodeAt(--e)))
1938
1942
  return e + 1;
1939
1943
  return e;
1940
1944
  };
1941
- au.prototype.skipChars = function(e, t) {
1945
+ su.prototype.skipChars = function(e, t) {
1942
1946
  for (let n = this.src.length; e < n && this.src.charCodeAt(e) === t; e++)
1943
1947
  ;
1944
1948
  return e;
1945
1949
  };
1946
- au.prototype.skipCharsBack = function(e, t, n) {
1950
+ su.prototype.skipCharsBack = function(e, t, n) {
1947
1951
  if (e <= n)
1948
1952
  return e;
1949
1953
  for (; e > n; )
@@ -1951,68 +1955,68 @@ au.prototype.skipCharsBack = function(e, t, n) {
1951
1955
  return e + 1;
1952
1956
  return e;
1953
1957
  };
1954
- au.prototype.getLines = function(e, t, n, r) {
1958
+ su.prototype.getLines = function(e, t, n, r) {
1955
1959
  if (e >= t)
1956
1960
  return "";
1957
- const o = new Array(t - e);
1958
- for (let i = 0, c = e; c < t; c++, i++) {
1961
+ const c = new Array(t - e);
1962
+ for (let i = 0, o = e; o < t; o++, i++) {
1959
1963
  let a = 0;
1960
- const s = this.bMarks[c];
1964
+ const s = this.bMarks[o];
1961
1965
  let f = s, d;
1962
- for (c + 1 < t || r ? d = this.eMarks[c] + 1 : d = this.eMarks[c]; f < d && a < n; ) {
1963
- const m = this.src.charCodeAt(f);
1964
- if (w(m))
1965
- m === 9 ? a += 4 - (a + this.bsCount[c]) % 4 : a++;
1966
- else if (f - s < this.tShift[c])
1966
+ for (o + 1 < t || r ? d = this.eMarks[o] + 1 : d = this.eMarks[o]; f < d && a < n; ) {
1967
+ const _ = this.src.charCodeAt(f);
1968
+ if (S(_))
1969
+ _ === 9 ? a += 4 - (a + this.bsCount[o]) % 4 : a++;
1970
+ else if (f - s < this.tShift[o])
1967
1971
  a++;
1968
1972
  else
1969
1973
  break;
1970
1974
  f++;
1971
1975
  }
1972
- a > n ? o[i] = new Array(a - n + 1).join(" ") + this.src.slice(f, d) : o[i] = this.src.slice(f, d);
1976
+ a > n ? c[i] = new Array(a - n + 1).join(" ") + this.src.slice(f, d) : c[i] = this.src.slice(f, d);
1973
1977
  }
1974
- return o.join("");
1978
+ return c.join("");
1975
1979
  };
1976
- au.prototype.Token = tu;
1977
- const qo = 65536;
1980
+ su.prototype.Token = eu;
1981
+ const zc = 65536;
1978
1982
  function Qe(u, e) {
1979
1983
  const t = u.bMarks[e] + u.tShift[e], n = u.eMarks[e];
1980
1984
  return u.src.slice(t, n);
1981
1985
  }
1982
1986
  function bt(u) {
1983
1987
  const e = [], t = u.length;
1984
- let n = 0, r = u.charCodeAt(n), o = !1, i = 0, c = "";
1988
+ let n = 0, r = u.charCodeAt(n), c = !1, i = 0, o = "";
1985
1989
  for (; n < t; )
1986
- r === 124 && (o ? (c += u.substring(i, n - 1), i = n) : (e.push(c + u.substring(i, n)), c = "", i = n + 1)), o = r === 92, n++, r = u.charCodeAt(n);
1987
- return e.push(c + u.substring(i)), e;
1990
+ r === 124 && (c ? (o += u.substring(i, n - 1), i = n) : (e.push(o + u.substring(i, n)), o = "", i = n + 1)), c = r === 92, n++, r = u.charCodeAt(n);
1991
+ return e.push(o + u.substring(i)), e;
1988
1992
  }
1989
- function Uo(u, e, t, n) {
1993
+ function qc(u, e, t, n) {
1990
1994
  if (e + 2 > t)
1991
1995
  return !1;
1992
1996
  let r = e + 1;
1993
1997
  if (u.sCount[r] < u.blkIndent || u.sCount[r] - u.blkIndent >= 4)
1994
1998
  return !1;
1995
- let o = u.bMarks[r] + u.tShift[r];
1996
- if (o >= u.eMarks[r])
1999
+ let c = u.bMarks[r] + u.tShift[r];
2000
+ if (c >= u.eMarks[r])
1997
2001
  return !1;
1998
- const i = u.src.charCodeAt(o++);
1999
- if (i !== 124 && i !== 45 && i !== 58 || o >= u.eMarks[r])
2002
+ const i = u.src.charCodeAt(c++);
2003
+ if (i !== 124 && i !== 45 && i !== 58 || c >= u.eMarks[r])
2000
2004
  return !1;
2001
- const c = u.src.charCodeAt(o++);
2002
- if (c !== 124 && c !== 45 && c !== 58 && !w(c) || i === 45 && w(c))
2005
+ const o = u.src.charCodeAt(c++);
2006
+ if (o !== 124 && o !== 45 && o !== 58 && !S(o) || i === 45 && S(o))
2003
2007
  return !1;
2004
- for (; o < u.eMarks[r]; ) {
2005
- const _ = u.src.charCodeAt(o);
2006
- if (_ !== 124 && _ !== 45 && _ !== 58 && !w(_))
2008
+ for (; c < u.eMarks[r]; ) {
2009
+ const m = u.src.charCodeAt(c);
2010
+ if (m !== 124 && m !== 45 && m !== 58 && !S(m))
2007
2011
  return !1;
2008
- o++;
2012
+ c++;
2009
2013
  }
2010
2014
  let a = Qe(u, e + 1), s = a.split("|");
2011
2015
  const f = [];
2012
- for (let _ = 0; _ < s.length; _++) {
2013
- const A = s[_].trim();
2016
+ for (let m = 0; m < s.length; m++) {
2017
+ const A = s[m].trim();
2014
2018
  if (!A) {
2015
- if (_ === 0 || _ === s.length - 1)
2019
+ if (m === 0 || m === s.length - 1)
2016
2020
  continue;
2017
2021
  return !1;
2018
2022
  }
@@ -2028,48 +2032,48 @@ function Uo(u, e, t, n) {
2028
2032
  return !1;
2029
2033
  if (n)
2030
2034
  return !0;
2031
- const m = u.parentType;
2035
+ const _ = u.parentType;
2032
2036
  u.parentType = "table";
2033
- const p = u.md.block.ruler.getRules("blockquote"), h = u.push("table_open", "table", 1), C = [e, 0];
2037
+ const b = u.md.block.ruler.getRules("blockquote"), h = u.push("table_open", "table", 1), C = [e, 0];
2034
2038
  h.map = C;
2035
- const D = u.push("thead_open", "thead", 1);
2036
- D.map = [e, e + 1];
2039
+ const y = u.push("thead_open", "thead", 1);
2040
+ y.map = [e, e + 1];
2037
2041
  const T = u.push("tr_open", "tr", 1);
2038
2042
  T.map = [e, e + 1];
2039
- for (let _ = 0; _ < s.length; _++) {
2043
+ for (let m = 0; m < s.length; m++) {
2040
2044
  const A = u.push("th_open", "th", 1);
2041
- f[_] && (A.attrs = [["style", "text-align:" + f[_]]]);
2042
- const y = u.push("inline", "", 0);
2043
- y.content = s[_].trim(), y.children = [], u.push("th_close", "th", -1);
2045
+ f[m] && (A.attrs = [["style", "text-align:" + f[m]]]);
2046
+ const F = u.push("inline", "", 0);
2047
+ F.content = s[m].trim(), F.children = [], u.push("th_close", "th", -1);
2044
2048
  }
2045
2049
  u.push("tr_close", "tr", -1), u.push("thead_close", "thead", -1);
2046
2050
  let E, k = 0;
2047
2051
  for (r = e + 2; r < t && !(u.sCount[r] < u.blkIndent); r++) {
2048
- let _ = !1;
2049
- for (let y = 0, M = p.length; y < M; y++)
2050
- if (p[y](u, r, t, !0)) {
2051
- _ = !0;
2052
+ let m = !1;
2053
+ for (let F = 0, M = b.length; F < M; F++)
2054
+ if (b[F](u, r, t, !0)) {
2055
+ m = !0;
2052
2056
  break;
2053
2057
  }
2054
- if (_ || (a = Qe(u, r).trim(), !a) || u.sCount[r] - u.blkIndent >= 4 || (s = bt(a), s.length && s[0] === "" && s.shift(), s.length && s[s.length - 1] === "" && s.pop(), k += d - s.length, k > qo))
2058
+ if (m || (a = Qe(u, r).trim(), !a) || u.sCount[r] - u.blkIndent >= 4 || (s = bt(a), s.length && s[0] === "" && s.shift(), s.length && s[s.length - 1] === "" && s.pop(), k += d - s.length, k > zc))
2055
2059
  break;
2056
2060
  if (r === e + 2) {
2057
- const y = u.push("tbody_open", "tbody", 1);
2058
- y.map = E = [e + 2, 0];
2061
+ const F = u.push("tbody_open", "tbody", 1);
2062
+ F.map = E = [e + 2, 0];
2059
2063
  }
2060
2064
  const A = u.push("tr_open", "tr", 1);
2061
2065
  A.map = [r, r + 1];
2062
- for (let y = 0; y < d; y++) {
2066
+ for (let F = 0; F < d; F++) {
2063
2067
  const M = u.push("td_open", "td", 1);
2064
- f[y] && (M.attrs = [["style", "text-align:" + f[y]]]);
2065
- const Y = u.push("inline", "", 0);
2066
- Y.content = s[y] ? s[y].trim() : "", Y.children = [], u.push("td_close", "td", -1);
2068
+ f[F] && (M.attrs = [["style", "text-align:" + f[F]]]);
2069
+ const V = u.push("inline", "", 0);
2070
+ V.content = s[F] ? s[F].trim() : "", V.children = [], u.push("td_close", "td", -1);
2067
2071
  }
2068
2072
  u.push("tr_close", "tr", -1);
2069
2073
  }
2070
- return E && (u.push("tbody_close", "tbody", -1), E[1] = r), u.push("table_close", "table", -1), C[1] = r, u.parentType = m, u.line = r, !0;
2074
+ return E && (u.push("tbody_close", "tbody", -1), E[1] = r), u.push("table_close", "table", -1), C[1] = r, u.parentType = _, u.line = r, !0;
2071
2075
  }
2072
- function Ho(u, e, t) {
2076
+ function Uc(u, e, t) {
2073
2077
  if (u.sCount[e] - u.blkIndent < 4)
2074
2078
  return !1;
2075
2079
  let n = e + 1, r = n;
@@ -2085,124 +2089,124 @@ function Ho(u, e, t) {
2085
2089
  break;
2086
2090
  }
2087
2091
  u.line = r;
2088
- const o = u.push("code_block", "code", 0);
2089
- return o.content = u.getLines(e, r, 4 + u.blkIndent, !1) + `
2090
- `, o.map = [e, u.line], !0;
2092
+ const c = u.push("code_block", "code", 0);
2093
+ return c.content = u.getLines(e, r, 4 + u.blkIndent, !1) + `
2094
+ `, c.map = [e, u.line], !0;
2091
2095
  }
2092
- function $o(u, e, t, n) {
2093
- let r = u.bMarks[e] + u.tShift[e], o = u.eMarks[e];
2094
- if (u.sCount[e] - u.blkIndent >= 4 || r + 3 > o)
2096
+ function Hc(u, e, t, n) {
2097
+ let r = u.bMarks[e] + u.tShift[e], c = u.eMarks[e];
2098
+ if (u.sCount[e] - u.blkIndent >= 4 || r + 3 > c)
2095
2099
  return !1;
2096
2100
  const i = u.src.charCodeAt(r);
2097
2101
  if (i !== 126 && i !== 96)
2098
2102
  return !1;
2099
- let c = r;
2103
+ let o = r;
2100
2104
  r = u.skipChars(r, i);
2101
- let a = r - c;
2105
+ let a = r - o;
2102
2106
  if (a < 3)
2103
2107
  return !1;
2104
- const s = u.src.slice(c, r), f = u.src.slice(r, o);
2108
+ const s = u.src.slice(o, r), f = u.src.slice(r, c);
2105
2109
  if (i === 96 && f.indexOf(String.fromCharCode(i)) >= 0)
2106
2110
  return !1;
2107
2111
  if (n)
2108
2112
  return !0;
2109
- let d = e, m = !1;
2110
- for (; d++, !(d >= t || (r = c = u.bMarks[d] + u.tShift[d], o = u.eMarks[d], r < o && u.sCount[d] < u.blkIndent)); )
2111
- if (u.src.charCodeAt(r) === i && !(u.sCount[d] - u.blkIndent >= 4) && (r = u.skipChars(r, i), !(r - c < a) && (r = u.skipSpaces(r), !(r < o)))) {
2112
- m = !0;
2113
+ let d = e, _ = !1;
2114
+ for (; d++, !(d >= t || (r = o = u.bMarks[d] + u.tShift[d], c = u.eMarks[d], r < c && u.sCount[d] < u.blkIndent)); )
2115
+ if (u.src.charCodeAt(r) === i && !(u.sCount[d] - u.blkIndent >= 4) && (r = u.skipChars(r, i), !(r - o < a) && (r = u.skipSpaces(r), !(r < c)))) {
2116
+ _ = !0;
2113
2117
  break;
2114
2118
  }
2115
- a = u.sCount[e], u.line = d + (m ? 1 : 0);
2116
- const p = u.push("fence", "code", 0);
2117
- return p.info = f, p.content = u.getLines(e + 1, d, a, !0), p.markup = s, p.map = [e, u.line], !0;
2119
+ a = u.sCount[e], u.line = d + (_ ? 1 : 0);
2120
+ const b = u.push("fence", "code", 0);
2121
+ return b.info = f, b.content = u.getLines(e + 1, d, a, !0), b.markup = s, b.map = [e, u.line], !0;
2118
2122
  }
2119
- function jo(u, e, t, n) {
2120
- let r = u.bMarks[e] + u.tShift[e], o = u.eMarks[e];
2123
+ function $c(u, e, t, n) {
2124
+ let r = u.bMarks[e] + u.tShift[e], c = u.eMarks[e];
2121
2125
  const i = u.lineMax;
2122
2126
  if (u.sCount[e] - u.blkIndent >= 4 || u.src.charCodeAt(r) !== 62)
2123
2127
  return !1;
2124
2128
  if (n)
2125
2129
  return !0;
2126
- const c = [], a = [], s = [], f = [], d = u.md.block.ruler.getRules("blockquote"), m = u.parentType;
2130
+ const o = [], a = [], s = [], f = [], d = u.md.block.ruler.getRules("blockquote"), _ = u.parentType;
2127
2131
  u.parentType = "blockquote";
2128
- let p = !1, h;
2132
+ let b = !1, h;
2129
2133
  for (h = e; h < t; h++) {
2130
2134
  const k = u.sCount[h] < u.blkIndent;
2131
- if (r = u.bMarks[h] + u.tShift[h], o = u.eMarks[h], r >= o)
2135
+ if (r = u.bMarks[h] + u.tShift[h], c = u.eMarks[h], r >= c)
2132
2136
  break;
2133
2137
  if (u.src.charCodeAt(r++) === 62 && !k) {
2134
- let A = u.sCount[h] + 1, y, M;
2135
- u.src.charCodeAt(r) === 32 ? (r++, A++, M = !1, y = !0) : u.src.charCodeAt(r) === 9 ? (y = !0, (u.bsCount[h] + A) % 4 === 3 ? (r++, A++, M = !1) : M = !0) : y = !1;
2136
- let Y = A;
2137
- for (c.push(u.bMarks[h]), u.bMarks[h] = r; r < o; ) {
2138
- const nu = u.src.charCodeAt(r);
2139
- if (w(nu))
2140
- nu === 9 ? Y += 4 - (Y + u.bsCount[h] + (M ? 1 : 0)) % 4 : Y++;
2138
+ let A = u.sCount[h] + 1, F, M;
2139
+ u.src.charCodeAt(r) === 32 ? (r++, A++, M = !1, F = !0) : u.src.charCodeAt(r) === 9 ? (F = !0, (u.bsCount[h] + A) % 4 === 3 ? (r++, A++, M = !1) : M = !0) : F = !1;
2140
+ let V = A;
2141
+ for (o.push(u.bMarks[h]), u.bMarks[h] = r; r < c; ) {
2142
+ const tu = u.src.charCodeAt(r);
2143
+ if (S(tu))
2144
+ tu === 9 ? V += 4 - (V + u.bsCount[h] + (M ? 1 : 0)) % 4 : V++;
2141
2145
  else
2142
2146
  break;
2143
2147
  r++;
2144
2148
  }
2145
- p = r >= o, a.push(u.bsCount[h]), u.bsCount[h] = u.sCount[h] + 1 + (y ? 1 : 0), s.push(u.sCount[h]), u.sCount[h] = Y - A, f.push(u.tShift[h]), u.tShift[h] = r - u.bMarks[h];
2149
+ b = r >= c, a.push(u.bsCount[h]), u.bsCount[h] = u.sCount[h] + 1 + (F ? 1 : 0), s.push(u.sCount[h]), u.sCount[h] = V - A, f.push(u.tShift[h]), u.tShift[h] = r - u.bMarks[h];
2146
2150
  continue;
2147
2151
  }
2148
- if (p)
2152
+ if (b)
2149
2153
  break;
2150
- let _ = !1;
2151
- for (let A = 0, y = d.length; A < y; A++)
2154
+ let m = !1;
2155
+ for (let A = 0, F = d.length; A < F; A++)
2152
2156
  if (d[A](u, h, t, !0)) {
2153
- _ = !0;
2157
+ m = !0;
2154
2158
  break;
2155
2159
  }
2156
- if (_) {
2157
- u.lineMax = h, u.blkIndent !== 0 && (c.push(u.bMarks[h]), a.push(u.bsCount[h]), f.push(u.tShift[h]), s.push(u.sCount[h]), u.sCount[h] -= u.blkIndent);
2160
+ if (m) {
2161
+ u.lineMax = h, u.blkIndent !== 0 && (o.push(u.bMarks[h]), a.push(u.bsCount[h]), f.push(u.tShift[h]), s.push(u.sCount[h]), u.sCount[h] -= u.blkIndent);
2158
2162
  break;
2159
2163
  }
2160
- c.push(u.bMarks[h]), a.push(u.bsCount[h]), f.push(u.tShift[h]), s.push(u.sCount[h]), u.sCount[h] = -1;
2164
+ o.push(u.bMarks[h]), a.push(u.bsCount[h]), f.push(u.tShift[h]), s.push(u.sCount[h]), u.sCount[h] = -1;
2161
2165
  }
2162
2166
  const C = u.blkIndent;
2163
2167
  u.blkIndent = 0;
2164
- const D = u.push("blockquote_open", "blockquote", 1);
2165
- D.markup = ">";
2168
+ const y = u.push("blockquote_open", "blockquote", 1);
2169
+ y.markup = ">";
2166
2170
  const T = [e, 0];
2167
- D.map = T, u.md.block.tokenize(u, e, h);
2171
+ y.map = T, u.md.block.tokenize(u, e, h);
2168
2172
  const E = u.push("blockquote_close", "blockquote", -1);
2169
- E.markup = ">", u.lineMax = i, u.parentType = m, T[1] = u.line;
2173
+ E.markup = ">", u.lineMax = i, u.parentType = _, T[1] = u.line;
2170
2174
  for (let k = 0; k < f.length; k++)
2171
- u.bMarks[k + e] = c[k], u.tShift[k + e] = f[k], u.sCount[k + e] = s[k], u.bsCount[k + e] = a[k];
2175
+ u.bMarks[k + e] = o[k], u.tShift[k + e] = f[k], u.sCount[k + e] = s[k], u.bsCount[k + e] = a[k];
2172
2176
  return u.blkIndent = C, !0;
2173
2177
  }
2174
- function Go(u, e, t, n) {
2178
+ function jc(u, e, t, n) {
2175
2179
  const r = u.eMarks[e];
2176
2180
  if (u.sCount[e] - u.blkIndent >= 4)
2177
2181
  return !1;
2178
- let o = u.bMarks[e] + u.tShift[e];
2179
- const i = u.src.charCodeAt(o++);
2182
+ let c = u.bMarks[e] + u.tShift[e];
2183
+ const i = u.src.charCodeAt(c++);
2180
2184
  if (i !== 42 && i !== 45 && i !== 95)
2181
2185
  return !1;
2182
- let c = 1;
2183
- for (; o < r; ) {
2184
- const s = u.src.charCodeAt(o++);
2185
- if (s !== i && !w(s))
2186
+ let o = 1;
2187
+ for (; c < r; ) {
2188
+ const s = u.src.charCodeAt(c++);
2189
+ if (s !== i && !S(s))
2186
2190
  return !1;
2187
- s === i && c++;
2191
+ s === i && o++;
2188
2192
  }
2189
- if (c < 3)
2193
+ if (o < 3)
2190
2194
  return !1;
2191
2195
  if (n)
2192
2196
  return !0;
2193
2197
  u.line = e + 1;
2194
2198
  const a = u.push("hr", "hr", 0);
2195
- return a.map = [e, u.line], a.markup = Array(c + 1).join(String.fromCharCode(i)), !0;
2199
+ return a.map = [e, u.line], a.markup = Array(o + 1).join(String.fromCharCode(i)), !0;
2196
2200
  }
2197
- function mt(u, e) {
2201
+ function pt(u, e) {
2198
2202
  const t = u.eMarks[e];
2199
2203
  let n = u.bMarks[e] + u.tShift[e];
2200
2204
  const r = u.src.charCodeAt(n++);
2201
2205
  if (r !== 42 && r !== 45 && r !== 43)
2202
2206
  return -1;
2203
2207
  if (n < t) {
2204
- const o = u.src.charCodeAt(n);
2205
- if (!w(o))
2208
+ const c = u.src.charCodeAt(n);
2209
+ if (!S(c))
2206
2210
  return -1;
2207
2211
  }
2208
2212
  return n;
@@ -2212,122 +2216,122 @@ function _t(u, e) {
2212
2216
  let r = t;
2213
2217
  if (r + 1 >= n)
2214
2218
  return -1;
2215
- let o = u.src.charCodeAt(r++);
2216
- if (o < 48 || o > 57)
2219
+ let c = u.src.charCodeAt(r++);
2220
+ if (c < 48 || c > 57)
2217
2221
  return -1;
2218
2222
  for (; ; ) {
2219
2223
  if (r >= n)
2220
2224
  return -1;
2221
- if (o = u.src.charCodeAt(r++), o >= 48 && o <= 57) {
2225
+ if (c = u.src.charCodeAt(r++), c >= 48 && c <= 57) {
2222
2226
  if (r - t >= 10)
2223
2227
  return -1;
2224
2228
  continue;
2225
2229
  }
2226
- if (o === 41 || o === 46)
2230
+ if (c === 41 || c === 46)
2227
2231
  break;
2228
2232
  return -1;
2229
2233
  }
2230
- return r < n && (o = u.src.charCodeAt(r), !w(o)) ? -1 : r;
2234
+ return r < n && (c = u.src.charCodeAt(r), !S(c)) ? -1 : r;
2231
2235
  }
2232
- function Wo(u, e) {
2236
+ function Gc(u, e) {
2233
2237
  const t = u.level + 2;
2234
2238
  for (let n = e + 2, r = u.tokens.length - 2; n < r; n++)
2235
2239
  u.tokens[n].level === t && u.tokens[n].type === "paragraph_open" && (u.tokens[n + 2].hidden = !0, u.tokens[n].hidden = !0, n += 2);
2236
2240
  }
2237
- function Zo(u, e, t, n) {
2238
- let r, o, i, c, a = e, s = !0;
2241
+ function Wc(u, e, t, n) {
2242
+ let r, c, i, o, a = e, s = !0;
2239
2243
  if (u.sCount[a] - u.blkIndent >= 4 || u.listIndent >= 0 && u.sCount[a] - u.listIndent >= 4 && u.sCount[a] < u.blkIndent)
2240
2244
  return !1;
2241
2245
  let f = !1;
2242
2246
  n && u.parentType === "paragraph" && u.sCount[a] >= u.blkIndent && (f = !0);
2243
- let d, m, p;
2244
- if ((p = _t(u, a)) >= 0) {
2245
- if (d = !0, i = u.bMarks[a] + u.tShift[a], m = Number(u.src.slice(i, p - 1)), f && m !== 1) return !1;
2246
- } else if ((p = mt(u, a)) >= 0)
2247
+ let d, _, b;
2248
+ if ((b = _t(u, a)) >= 0) {
2249
+ if (d = !0, i = u.bMarks[a] + u.tShift[a], _ = Number(u.src.slice(i, b - 1)), f && _ !== 1) return !1;
2250
+ } else if ((b = pt(u, a)) >= 0)
2247
2251
  d = !1;
2248
2252
  else
2249
2253
  return !1;
2250
- if (f && u.skipSpaces(p) >= u.eMarks[a])
2254
+ if (f && u.skipSpaces(b) >= u.eMarks[a])
2251
2255
  return !1;
2252
2256
  if (n)
2253
2257
  return !0;
2254
- const h = u.src.charCodeAt(p - 1), C = u.tokens.length;
2255
- d ? (c = u.push("ordered_list_open", "ol", 1), m !== 1 && (c.attrs = [["start", m]])) : c = u.push("bullet_list_open", "ul", 1);
2256
- const D = [a, 0];
2257
- c.map = D, c.markup = String.fromCharCode(h);
2258
+ const h = u.src.charCodeAt(b - 1), C = u.tokens.length;
2259
+ d ? (o = u.push("ordered_list_open", "ol", 1), _ !== 1 && (o.attrs = [["start", _]])) : o = u.push("bullet_list_open", "ul", 1);
2260
+ const y = [a, 0];
2261
+ o.map = y, o.markup = String.fromCharCode(h);
2258
2262
  let T = !1;
2259
2263
  const E = u.md.block.ruler.getRules("list"), k = u.parentType;
2260
2264
  for (u.parentType = "list"; a < t; ) {
2261
- o = p, r = u.eMarks[a];
2262
- const _ = u.sCount[a] + p - (u.bMarks[a] + u.tShift[a]);
2263
- let A = _;
2264
- for (; o < r; ) {
2265
- const hu = u.src.charCodeAt(o);
2266
- if (hu === 9)
2265
+ c = b, r = u.eMarks[a];
2266
+ const m = u.sCount[a] + b - (u.bMarks[a] + u.tShift[a]);
2267
+ let A = m;
2268
+ for (; c < r; ) {
2269
+ const bu = u.src.charCodeAt(c);
2270
+ if (bu === 9)
2267
2271
  A += 4 - (A + u.bsCount[a]) % 4;
2268
- else if (hu === 32)
2272
+ else if (bu === 32)
2269
2273
  A++;
2270
2274
  else
2271
2275
  break;
2272
- o++;
2276
+ c++;
2273
2277
  }
2274
- const y = o;
2278
+ const F = c;
2275
2279
  let M;
2276
- y >= r ? M = 1 : M = A - _, M > 4 && (M = 1);
2277
- const Y = _ + M;
2278
- c = u.push("list_item_open", "li", 1), c.markup = String.fromCharCode(h);
2279
- const nu = [a, 0];
2280
- c.map = nu, d && (c.info = u.src.slice(i, p - 1));
2281
- const gu = u.tight, L = u.tShift[a], Hu = u.sCount[a], $u = u.listIndent;
2282
- if (u.listIndent = u.blkIndent, u.blkIndent = Y, u.tight = !0, u.tShift[a] = y - u.bMarks[a], u.sCount[a] = A, y >= r && u.isEmpty(a + 1) ? u.line = Math.min(u.line + 2, t) : u.md.block.tokenize(u, a, t, !0), (!u.tight || T) && (s = !1), T = u.line - a > 1 && u.isEmpty(u.line - 1), u.blkIndent = u.listIndent, u.listIndent = $u, u.tShift[a] = L, u.sCount[a] = Hu, u.tight = gu, c = u.push("list_item_close", "li", -1), c.markup = String.fromCharCode(h), a = u.line, nu[1] = a, a >= t || u.sCount[a] < u.blkIndent || u.sCount[a] - u.blkIndent >= 4)
2280
+ F >= r ? M = 1 : M = A - m, M > 4 && (M = 1);
2281
+ const V = m + M;
2282
+ o = u.push("list_item_open", "li", 1), o.markup = String.fromCharCode(h);
2283
+ const tu = [a, 0];
2284
+ o.map = tu, d && (o.info = u.src.slice(i, b - 1));
2285
+ const ku = u.tight, L = u.tShift[a], Hu = u.sCount[a], $u = u.listIndent;
2286
+ if (u.listIndent = u.blkIndent, u.blkIndent = V, u.tight = !0, u.tShift[a] = F - u.bMarks[a], u.sCount[a] = A, F >= r && u.isEmpty(a + 1) ? u.line = Math.min(u.line + 2, t) : u.md.block.tokenize(u, a, t, !0), (!u.tight || T) && (s = !1), T = u.line - a > 1 && u.isEmpty(u.line - 1), u.blkIndent = u.listIndent, u.listIndent = $u, u.tShift[a] = L, u.sCount[a] = Hu, u.tight = ku, o = u.push("list_item_close", "li", -1), o.markup = String.fromCharCode(h), a = u.line, tu[1] = a, a >= t || u.sCount[a] < u.blkIndent || u.sCount[a] - u.blkIndent >= 4)
2283
2287
  break;
2284
- let Fu = !1;
2285
- for (let hu = 0, Ie = E.length; hu < Ie; hu++)
2286
- if (E[hu](u, a, t, !0)) {
2287
- Fu = !0;
2288
+ let Tu = !1;
2289
+ for (let bu = 0, ve = E.length; bu < ve; bu++)
2290
+ if (E[bu](u, a, t, !0)) {
2291
+ Tu = !0;
2288
2292
  break;
2289
2293
  }
2290
- if (Fu)
2294
+ if (Tu)
2291
2295
  break;
2292
2296
  if (d) {
2293
- if (p = _t(u, a), p < 0)
2297
+ if (b = _t(u, a), b < 0)
2294
2298
  break;
2295
2299
  i = u.bMarks[a] + u.tShift[a];
2296
- } else if (p = mt(u, a), p < 0)
2300
+ } else if (b = pt(u, a), b < 0)
2297
2301
  break;
2298
- if (h !== u.src.charCodeAt(p - 1))
2302
+ if (h !== u.src.charCodeAt(b - 1))
2299
2303
  break;
2300
2304
  }
2301
- return d ? c = u.push("ordered_list_close", "ol", -1) : c = u.push("bullet_list_close", "ul", -1), c.markup = String.fromCharCode(h), D[1] = a, u.line = a, u.parentType = k, s && Wo(u, C), !0;
2305
+ return d ? o = u.push("ordered_list_close", "ol", -1) : o = u.push("bullet_list_close", "ul", -1), o.markup = String.fromCharCode(h), y[1] = a, u.line = a, u.parentType = k, s && Gc(u, C), !0;
2302
2306
  }
2303
- function Vo(u, e, t, n) {
2304
- let r = u.bMarks[e] + u.tShift[e], o = u.eMarks[e], i = e + 1;
2307
+ function Zc(u, e, t, n) {
2308
+ let r = u.bMarks[e] + u.tShift[e], c = u.eMarks[e], i = e + 1;
2305
2309
  if (u.sCount[e] - u.blkIndent >= 4 || u.src.charCodeAt(r) !== 91)
2306
2310
  return !1;
2307
- function c(E) {
2311
+ function o(E) {
2308
2312
  const k = u.lineMax;
2309
2313
  if (E >= k || u.isEmpty(E))
2310
2314
  return null;
2311
- let _ = !1;
2312
- if (u.sCount[E] - u.blkIndent > 3 && (_ = !0), u.sCount[E] < 0 && (_ = !0), !_) {
2313
- const M = u.md.block.ruler.getRules("reference"), Y = u.parentType;
2315
+ let m = !1;
2316
+ if (u.sCount[E] - u.blkIndent > 3 && (m = !0), u.sCount[E] < 0 && (m = !0), !m) {
2317
+ const M = u.md.block.ruler.getRules("reference"), V = u.parentType;
2314
2318
  u.parentType = "reference";
2315
- let nu = !1;
2316
- for (let gu = 0, L = M.length; gu < L; gu++)
2317
- if (M[gu](u, E, k, !0)) {
2318
- nu = !0;
2319
+ let tu = !1;
2320
+ for (let ku = 0, L = M.length; ku < L; ku++)
2321
+ if (M[ku](u, E, k, !0)) {
2322
+ tu = !0;
2319
2323
  break;
2320
2324
  }
2321
- if (u.parentType = Y, nu)
2325
+ if (u.parentType = V, tu)
2322
2326
  return null;
2323
2327
  }
2324
- const A = u.bMarks[E] + u.tShift[E], y = u.eMarks[E];
2325
- return u.src.slice(A, y + 1);
2328
+ const A = u.bMarks[E] + u.tShift[E], F = u.eMarks[E];
2329
+ return u.src.slice(A, F + 1);
2326
2330
  }
2327
- let a = u.src.slice(r, o + 1);
2328
- o = a.length;
2331
+ let a = u.src.slice(r, c + 1);
2332
+ c = a.length;
2329
2333
  let s = -1;
2330
- for (r = 1; r < o; r++) {
2334
+ for (r = 1; r < c; r++) {
2331
2335
  const E = a.charCodeAt(r);
2332
2336
  if (E === 91)
2333
2337
  return !1;
@@ -2335,63 +2339,63 @@ function Vo(u, e, t, n) {
2335
2339
  s = r;
2336
2340
  break;
2337
2341
  } else if (E === 10) {
2338
- const k = c(i);
2339
- k !== null && (a += k, o = a.length, i++);
2340
- } else if (E === 92 && (r++, r < o && a.charCodeAt(r) === 10)) {
2341
- const k = c(i);
2342
- k !== null && (a += k, o = a.length, i++);
2342
+ const k = o(i);
2343
+ k !== null && (a += k, c = a.length, i++);
2344
+ } else if (E === 92 && (r++, r < c && a.charCodeAt(r) === 10)) {
2345
+ const k = o(i);
2346
+ k !== null && (a += k, c = a.length, i++);
2343
2347
  }
2344
2348
  }
2345
2349
  if (s < 0 || a.charCodeAt(s + 1) !== 58)
2346
2350
  return !1;
2347
- for (r = s + 2; r < o; r++) {
2351
+ for (r = s + 2; r < c; r++) {
2348
2352
  const E = a.charCodeAt(r);
2349
2353
  if (E === 10) {
2350
- const k = c(i);
2351
- k !== null && (a += k, o = a.length, i++);
2352
- } else if (!w(E)) break;
2354
+ const k = o(i);
2355
+ k !== null && (a += k, c = a.length, i++);
2356
+ } else if (!S(E)) break;
2353
2357
  }
2354
- const f = u.md.helpers.parseLinkDestination(a, r, o);
2358
+ const f = u.md.helpers.parseLinkDestination(a, r, c);
2355
2359
  if (!f.ok)
2356
2360
  return !1;
2357
2361
  const d = u.md.normalizeLink(f.str);
2358
2362
  if (!u.md.validateLink(d))
2359
2363
  return !1;
2360
2364
  r = f.pos;
2361
- const m = r, p = i, h = r;
2362
- for (; r < o; r++) {
2365
+ const _ = r, b = i, h = r;
2366
+ for (; r < c; r++) {
2363
2367
  const E = a.charCodeAt(r);
2364
2368
  if (E === 10) {
2365
- const k = c(i);
2366
- k !== null && (a += k, o = a.length, i++);
2367
- } else if (!w(E)) break;
2369
+ const k = o(i);
2370
+ k !== null && (a += k, c = a.length, i++);
2371
+ } else if (!S(E)) break;
2368
2372
  }
2369
- let C = u.md.helpers.parseLinkTitle(a, r, o);
2373
+ let C = u.md.helpers.parseLinkTitle(a, r, c);
2370
2374
  for (; C.can_continue; ) {
2371
- const E = c(i);
2375
+ const E = o(i);
2372
2376
  if (E === null) break;
2373
- a += E, r = o, o = a.length, i++, C = u.md.helpers.parseLinkTitle(a, r, o, C);
2377
+ a += E, r = c, c = a.length, i++, C = u.md.helpers.parseLinkTitle(a, r, c, C);
2374
2378
  }
2375
- let D;
2376
- for (r < o && h !== r && C.ok ? (D = C.str, r = C.pos) : (D = "", r = m, i = p); r < o; ) {
2379
+ let y;
2380
+ for (r < c && h !== r && C.ok ? (y = C.str, r = C.pos) : (y = "", r = _, i = b); r < c; ) {
2377
2381
  const E = a.charCodeAt(r);
2378
- if (!w(E))
2382
+ if (!S(E))
2379
2383
  break;
2380
2384
  r++;
2381
2385
  }
2382
- if (r < o && a.charCodeAt(r) !== 10 && D)
2383
- for (D = "", r = m, i = p; r < o; ) {
2386
+ if (r < c && a.charCodeAt(r) !== 10 && y)
2387
+ for (y = "", r = _, i = b; r < c; ) {
2384
2388
  const E = a.charCodeAt(r);
2385
- if (!w(E))
2389
+ if (!S(E))
2386
2390
  break;
2387
2391
  r++;
2388
2392
  }
2389
- if (r < o && a.charCodeAt(r) !== 10)
2393
+ if (r < c && a.charCodeAt(r) !== 10)
2390
2394
  return !1;
2391
- const T = we(a.slice(1, s));
2392
- return T ? (n || (typeof u.env.references > "u" && (u.env.references = {}), typeof u.env.references[T] > "u" && (u.env.references[T] = { title: D, href: d }), u.line = i), !0) : !1;
2395
+ const T = Te(a.slice(1, s));
2396
+ return T ? (n || (typeof u.env.references > "u" && (u.env.references = {}), typeof u.env.references[T] > "u" && (u.env.references[T] = { title: y, href: d }), u.line = i), !0) : !1;
2393
2397
  }
2394
- const Yo = [
2398
+ const Vc = [
2395
2399
  "address",
2396
2400
  "article",
2397
2401
  "aside",
@@ -2454,30 +2458,30 @@ const Yo = [
2454
2458
  "tr",
2455
2459
  "track",
2456
2460
  "ul"
2457
- ], Xo = "[a-zA-Z_:][a-zA-Z0-9:._-]*", Jo = "[^\"'=<>`\\x00-\\x20]+", Qo = "'[^']*'", Ko = '"[^"]*"', uc = "(?:" + Jo + "|" + Qo + "|" + Ko + ")", ec = "(?:\\s+" + Xo + "(?:\\s*=\\s*" + uc + ")?)", Ht = "<[A-Za-z][A-Za-z0-9\\-]*" + ec + "*\\s*\\/?>", $t = "<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>", tc = "<!---?>|<!--(?:[^-]|-[^-]|--[^>])*-->", nc = "<[?][\\s\\S]*?[?]>", rc = "<![A-Za-z][^>]*>", oc = "<!\\[CDATA\\[[\\s\\S]*?\\]\\]>", cc = new RegExp("^(?:" + Ht + "|" + $t + "|" + tc + "|" + nc + "|" + rc + "|" + oc + ")"), ic = new RegExp("^(?:" + Ht + "|" + $t + ")"), Nu = [
2461
+ ], Yc = "[a-zA-Z_:][a-zA-Z0-9:._-]*", Xc = "[^\"'=<>`\\x00-\\x20]+", Jc = "'[^']*'", Qc = '"[^"]*"', Kc = "(?:" + Xc + "|" + Jc + "|" + Qc + ")", uo = "(?:\\s+" + Yc + "(?:\\s*=\\s*" + Kc + ")?)", Ht = "<[A-Za-z][A-Za-z0-9\\-]*" + uo + "*\\s*\\/?>", $t = "<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>", eo = "<!---?>|<!--(?:[^-]|-[^-]|--[^>])*-->", to = "<[?][\\s\\S]*?[?]>", no = "<![A-Za-z][^>]*>", ro = "<!\\[CDATA\\[[\\s\\S]*?\\]\\]>", co = new RegExp("^(?:" + Ht + "|" + $t + "|" + eo + "|" + to + "|" + no + "|" + ro + ")"), oo = new RegExp("^(?:" + Ht + "|" + $t + ")"), Nu = [
2458
2462
  [/^<(script|pre|style|textarea)(?=(\s|>|$))/i, /<\/(script|pre|style|textarea)>/i, !0],
2459
2463
  [/^<!--/, /-->/, !0],
2460
2464
  [/^<\?/, /\?>/, !0],
2461
2465
  [/^<![A-Z]/, />/, !0],
2462
2466
  [/^<!\[CDATA\[/, /\]\]>/, !0],
2463
- [new RegExp("^</?(" + Yo.join("|") + ")(?=(\\s|/?>|$))", "i"), /^$/, !0],
2464
- [new RegExp(ic.source + "\\s*$"), /^$/, !1]
2467
+ [new RegExp("^</?(" + Vc.join("|") + ")(?=(\\s|/?>|$))", "i"), /^$/, !0],
2468
+ [new RegExp(oo.source + "\\s*$"), /^$/, !1]
2465
2469
  ];
2466
- function ac(u, e, t, n) {
2467
- let r = u.bMarks[e] + u.tShift[e], o = u.eMarks[e];
2470
+ function io(u, e, t, n) {
2471
+ let r = u.bMarks[e] + u.tShift[e], c = u.eMarks[e];
2468
2472
  if (u.sCount[e] - u.blkIndent >= 4 || !u.md.options.html || u.src.charCodeAt(r) !== 60)
2469
2473
  return !1;
2470
- let i = u.src.slice(r, o), c = 0;
2471
- for (; c < Nu.length && !Nu[c][0].test(i); c++)
2474
+ let i = u.src.slice(r, c), o = 0;
2475
+ for (; o < Nu.length && !Nu[o][0].test(i); o++)
2472
2476
  ;
2473
- if (c === Nu.length)
2477
+ if (o === Nu.length)
2474
2478
  return !1;
2475
2479
  if (n)
2476
- return Nu[c][2];
2480
+ return Nu[o][2];
2477
2481
  let a = e + 1;
2478
- if (!Nu[c][1].test(i)) {
2482
+ if (!Nu[o][1].test(i)) {
2479
2483
  for (; a < t && !(u.sCount[a] < u.blkIndent); a++)
2480
- if (r = u.bMarks[a] + u.tShift[a], o = u.eMarks[a], i = u.src.slice(r, o), Nu[c][1].test(i)) {
2484
+ if (r = u.bMarks[a] + u.tShift[a], c = u.eMarks[a], i = u.src.slice(r, c), Nu[o][1].test(i)) {
2481
2485
  i.length !== 0 && a++;
2482
2486
  break;
2483
2487
  }
@@ -2486,117 +2490,117 @@ function ac(u, e, t, n) {
2486
2490
  const s = u.push("html_block", "", 0);
2487
2491
  return s.map = [e, a], s.content = u.getLines(e, a, u.blkIndent, !0), !0;
2488
2492
  }
2489
- function sc(u, e, t, n) {
2490
- let r = u.bMarks[e] + u.tShift[e], o = u.eMarks[e];
2493
+ function ao(u, e, t, n) {
2494
+ let r = u.bMarks[e] + u.tShift[e], c = u.eMarks[e];
2491
2495
  if (u.sCount[e] - u.blkIndent >= 4)
2492
2496
  return !1;
2493
2497
  let i = u.src.charCodeAt(r);
2494
- if (i !== 35 || r >= o)
2498
+ if (i !== 35 || r >= c)
2495
2499
  return !1;
2496
- let c = 1;
2497
- for (i = u.src.charCodeAt(++r); i === 35 && r < o && c <= 6; )
2498
- c++, i = u.src.charCodeAt(++r);
2499
- if (c > 6 || r < o && !w(i))
2500
+ let o = 1;
2501
+ for (i = u.src.charCodeAt(++r); i === 35 && r < c && o <= 6; )
2502
+ o++, i = u.src.charCodeAt(++r);
2503
+ if (o > 6 || r < c && !S(i))
2500
2504
  return !1;
2501
2505
  if (n)
2502
2506
  return !0;
2503
- o = u.skipSpacesBack(o, r);
2504
- const a = u.skipCharsBack(o, 35, r);
2505
- a > r && w(u.src.charCodeAt(a - 1)) && (o = a), u.line = e + 1;
2506
- const s = u.push("heading_open", "h" + String(c), 1);
2507
- s.markup = "########".slice(0, c), s.map = [e, u.line];
2507
+ c = u.skipSpacesBack(c, r);
2508
+ const a = u.skipCharsBack(c, 35, r);
2509
+ a > r && S(u.src.charCodeAt(a - 1)) && (c = a), u.line = e + 1;
2510
+ const s = u.push("heading_open", "h" + String(o), 1);
2511
+ s.markup = "########".slice(0, o), s.map = [e, u.line];
2508
2512
  const f = u.push("inline", "", 0);
2509
- f.content = u.src.slice(r, o).trim(), f.map = [e, u.line], f.children = [];
2510
- const d = u.push("heading_close", "h" + String(c), -1);
2511
- return d.markup = "########".slice(0, c), !0;
2513
+ f.content = u.src.slice(r, c).trim(), f.map = [e, u.line], f.children = [];
2514
+ const d = u.push("heading_close", "h" + String(o), -1);
2515
+ return d.markup = "########".slice(0, o), !0;
2512
2516
  }
2513
- function lc(u, e, t) {
2517
+ function so(u, e, t) {
2514
2518
  const n = u.md.block.ruler.getRules("paragraph");
2515
2519
  if (u.sCount[e] - u.blkIndent >= 4)
2516
2520
  return !1;
2517
2521
  const r = u.parentType;
2518
2522
  u.parentType = "paragraph";
2519
- let o = 0, i, c = e + 1;
2520
- for (; c < t && !u.isEmpty(c); c++) {
2521
- if (u.sCount[c] - u.blkIndent > 3)
2523
+ let c = 0, i, o = e + 1;
2524
+ for (; o < t && !u.isEmpty(o); o++) {
2525
+ if (u.sCount[o] - u.blkIndent > 3)
2522
2526
  continue;
2523
- if (u.sCount[c] >= u.blkIndent) {
2524
- let p = u.bMarks[c] + u.tShift[c];
2525
- const h = u.eMarks[c];
2526
- if (p < h && (i = u.src.charCodeAt(p), (i === 45 || i === 61) && (p = u.skipChars(p, i), p = u.skipSpaces(p), p >= h))) {
2527
- o = i === 61 ? 1 : 2;
2527
+ if (u.sCount[o] >= u.blkIndent) {
2528
+ let b = u.bMarks[o] + u.tShift[o];
2529
+ const h = u.eMarks[o];
2530
+ if (b < h && (i = u.src.charCodeAt(b), (i === 45 || i === 61) && (b = u.skipChars(b, i), b = u.skipSpaces(b), b >= h))) {
2531
+ c = i === 61 ? 1 : 2;
2528
2532
  break;
2529
2533
  }
2530
2534
  }
2531
- if (u.sCount[c] < 0)
2535
+ if (u.sCount[o] < 0)
2532
2536
  continue;
2533
- let m = !1;
2534
- for (let p = 0, h = n.length; p < h; p++)
2535
- if (n[p](u, c, t, !0)) {
2536
- m = !0;
2537
+ let _ = !1;
2538
+ for (let b = 0, h = n.length; b < h; b++)
2539
+ if (n[b](u, o, t, !0)) {
2540
+ _ = !0;
2537
2541
  break;
2538
2542
  }
2539
- if (m)
2543
+ if (_)
2540
2544
  break;
2541
2545
  }
2542
- if (!o)
2546
+ if (!c)
2543
2547
  return !1;
2544
- const a = u.getLines(e, c, u.blkIndent, !1).trim();
2545
- u.line = c + 1;
2546
- const s = u.push("heading_open", "h" + String(o), 1);
2548
+ const a = u.getLines(e, o, u.blkIndent, !1).trim();
2549
+ u.line = o + 1;
2550
+ const s = u.push("heading_open", "h" + String(c), 1);
2547
2551
  s.markup = String.fromCharCode(i), s.map = [e, u.line];
2548
2552
  const f = u.push("inline", "", 0);
2549
2553
  f.content = a, f.map = [e, u.line - 1], f.children = [];
2550
- const d = u.push("heading_close", "h" + String(o), -1);
2554
+ const d = u.push("heading_close", "h" + String(c), -1);
2551
2555
  return d.markup = String.fromCharCode(i), u.parentType = r, !0;
2552
2556
  }
2553
- function fc(u, e, t) {
2557
+ function lo(u, e, t) {
2554
2558
  const n = u.md.block.ruler.getRules("paragraph"), r = u.parentType;
2555
- let o = e + 1;
2556
- for (u.parentType = "paragraph"; o < t && !u.isEmpty(o); o++) {
2557
- if (u.sCount[o] - u.blkIndent > 3 || u.sCount[o] < 0)
2559
+ let c = e + 1;
2560
+ for (u.parentType = "paragraph"; c < t && !u.isEmpty(c); c++) {
2561
+ if (u.sCount[c] - u.blkIndent > 3 || u.sCount[c] < 0)
2558
2562
  continue;
2559
2563
  let s = !1;
2560
2564
  for (let f = 0, d = n.length; f < d; f++)
2561
- if (n[f](u, o, t, !0)) {
2565
+ if (n[f](u, c, t, !0)) {
2562
2566
  s = !0;
2563
2567
  break;
2564
2568
  }
2565
2569
  if (s)
2566
2570
  break;
2567
2571
  }
2568
- const i = u.getLines(e, o, u.blkIndent, !1).trim();
2569
- u.line = o;
2570
- const c = u.push("paragraph_open", "p", 1);
2571
- c.map = [e, u.line];
2572
+ const i = u.getLines(e, c, u.blkIndent, !1).trim();
2573
+ u.line = c;
2574
+ const o = u.push("paragraph_open", "p", 1);
2575
+ o.map = [e, u.line];
2572
2576
  const a = u.push("inline", "", 0);
2573
2577
  return a.content = i, a.map = [e, u.line], a.children = [], u.push("paragraph_close", "p", -1), u.parentType = r, !0;
2574
2578
  }
2575
- const ke = [
2579
+ const ge = [
2576
2580
  // First 2 params - rule name & source. Secondary array - list of rules,
2577
2581
  // which can be terminated by this one.
2578
- ["table", Uo, ["paragraph", "reference"]],
2579
- ["code", Ho],
2580
- ["fence", $o, ["paragraph", "reference", "blockquote", "list"]],
2581
- ["blockquote", jo, ["paragraph", "reference", "blockquote", "list"]],
2582
- ["hr", Go, ["paragraph", "reference", "blockquote", "list"]],
2583
- ["list", Zo, ["paragraph", "reference", "blockquote"]],
2584
- ["reference", Vo],
2585
- ["html_block", ac, ["paragraph", "reference", "blockquote"]],
2586
- ["heading", sc, ["paragraph", "reference", "blockquote"]],
2587
- ["lheading", lc],
2588
- ["paragraph", fc]
2582
+ ["table", qc, ["paragraph", "reference"]],
2583
+ ["code", Uc],
2584
+ ["fence", Hc, ["paragraph", "reference", "blockquote", "list"]],
2585
+ ["blockquote", $c, ["paragraph", "reference", "blockquote", "list"]],
2586
+ ["hr", jc, ["paragraph", "reference", "blockquote", "list"]],
2587
+ ["list", Wc, ["paragraph", "reference", "blockquote"]],
2588
+ ["reference", Zc],
2589
+ ["html_block", io, ["paragraph", "reference", "blockquote"]],
2590
+ ["heading", ao, ["paragraph", "reference", "blockquote"]],
2591
+ ["lheading", so],
2592
+ ["paragraph", lo]
2589
2593
  ];
2590
- function ve() {
2591
- this.ruler = new V();
2592
- for (let u = 0; u < ke.length; u++)
2593
- this.ruler.push(ke[u][0], ke[u][1], { alt: (ke[u][2] || []).slice() });
2594
- }
2595
- ve.prototype.tokenize = function(u, e, t) {
2596
- const n = this.ruler.getRules(""), r = n.length, o = u.md.options.maxNesting;
2597
- let i = e, c = !1;
2594
+ function Se() {
2595
+ this.ruler = new Z();
2596
+ for (let u = 0; u < ge.length; u++)
2597
+ this.ruler.push(ge[u][0], ge[u][1], { alt: (ge[u][2] || []).slice() });
2598
+ }
2599
+ Se.prototype.tokenize = function(u, e, t) {
2600
+ const n = this.ruler.getRules(""), r = n.length, c = u.md.options.maxNesting;
2601
+ let i = e, o = !1;
2598
2602
  for (; i < t && (u.line = i = u.skipEmptyLines(i), !(i >= t || u.sCount[i] < u.blkIndent)); ) {
2599
- if (u.level >= o) {
2603
+ if (u.level >= c) {
2600
2604
  u.line = t;
2601
2605
  break;
2602
2606
  }
@@ -2609,39 +2613,39 @@ ve.prototype.tokenize = function(u, e, t) {
2609
2613
  break;
2610
2614
  }
2611
2615
  if (!s) throw new Error("none of the block rules matched");
2612
- u.tight = !c, u.isEmpty(u.line - 1) && (c = !0), i = u.line, i < t && u.isEmpty(i) && (c = !0, i++, u.line = i);
2616
+ u.tight = !o, u.isEmpty(u.line - 1) && (o = !0), i = u.line, i < t && u.isEmpty(i) && (o = !0, i++, u.line = i);
2613
2617
  }
2614
2618
  };
2615
- ve.prototype.parse = function(u, e, t, n) {
2619
+ Se.prototype.parse = function(u, e, t, n) {
2616
2620
  if (!u)
2617
2621
  return;
2618
2622
  const r = new this.State(u, e, t, n);
2619
2623
  this.tokenize(r, r.line, r.lineMax);
2620
2624
  };
2621
- ve.prototype.State = au;
2622
- function ae(u, e, t, n) {
2625
+ Se.prototype.State = su;
2626
+ function ie(u, e, t, n) {
2623
2627
  this.src = u, this.env = t, this.md = e, this.tokens = n, this.tokens_meta = Array(n.length), this.pos = 0, this.posMax = this.src.length, this.level = 0, this.pending = "", this.pendingLevel = 0, this.cache = {}, this.delimiters = [], this._prev_delimiters = [], this.backticks = {}, this.backticksScanned = !1, this.linkLevel = 0;
2624
2628
  }
2625
- ae.prototype.pushPending = function() {
2626
- const u = new tu("text", "", 0);
2629
+ ie.prototype.pushPending = function() {
2630
+ const u = new eu("text", "", 0);
2627
2631
  return u.content = this.pending, u.level = this.pendingLevel, this.tokens.push(u), this.pending = "", u;
2628
2632
  };
2629
- ae.prototype.push = function(u, e, t) {
2633
+ ie.prototype.push = function(u, e, t) {
2630
2634
  this.pending && this.pushPending();
2631
- const n = new tu(u, e, t);
2635
+ const n = new eu(u, e, t);
2632
2636
  let r = null;
2633
2637
  return t < 0 && (this.level--, this.delimiters = this._prev_delimiters.pop()), n.level = this.level, t > 0 && (this.level++, this._prev_delimiters.push(this.delimiters), this.delimiters = [], r = { delimiters: this.delimiters }), this.pendingLevel = this.level, this.tokens.push(n), this.tokens_meta.push(r), n;
2634
2638
  };
2635
- ae.prototype.scanDelims = function(u, e) {
2639
+ ie.prototype.scanDelims = function(u, e) {
2636
2640
  const t = this.posMax, n = this.src.charCodeAt(u), r = u > 0 ? this.src.charCodeAt(u - 1) : 32;
2637
- let o = u;
2638
- for (; o < t && this.src.charCodeAt(o) === n; )
2639
- o++;
2640
- const i = o - u, c = o < t ? this.src.charCodeAt(o) : 32, a = te(r) || ee(String.fromCharCode(r)), s = te(c) || ee(String.fromCharCode(c)), f = ue(r), d = ue(c), m = !d && (!s || f || a), p = !f && (!a || d || s);
2641
- return { can_open: m && (e || !p || a), can_close: p && (e || !m || s), length: i };
2642
- };
2643
- ae.prototype.Token = tu;
2644
- function dc(u) {
2641
+ let c = u;
2642
+ for (; c < t && this.src.charCodeAt(c) === n; )
2643
+ c++;
2644
+ const i = c - u, o = c < t ? this.src.charCodeAt(c) : 32, a = ee(r) || ue(String.fromCharCode(r)), s = ee(o) || ue(String.fromCharCode(o)), f = Ku(r), d = Ku(o), _ = !d && (!s || f || a), b = !f && (!a || d || s);
2645
+ return { can_open: _ && (e || !b || a), can_close: b && (e || !_ || s), length: i };
2646
+ };
2647
+ ie.prototype.Token = eu;
2648
+ function fo(u) {
2645
2649
  switch (u) {
2646
2650
  case 10:
2647
2651
  case 33:
@@ -2671,38 +2675,38 @@ function dc(u) {
2671
2675
  return !1;
2672
2676
  }
2673
2677
  }
2674
- function hc(u, e) {
2678
+ function ho(u, e) {
2675
2679
  let t = u.pos;
2676
- for (; t < u.posMax && !dc(u.src.charCodeAt(t)); )
2680
+ for (; t < u.posMax && !fo(u.src.charCodeAt(t)); )
2677
2681
  t++;
2678
2682
  return t === u.pos ? !1 : (e || (u.pending += u.src.slice(u.pos, t)), u.pos = t, !0);
2679
2683
  }
2680
- const pc = /(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;
2681
- function bc(u, e) {
2684
+ const bo = /(?:^|[^a-z0-9.+-])([a-z][a-z0-9.+-]*)$/i;
2685
+ function po(u, e) {
2682
2686
  if (!u.md.options.linkify || u.linkLevel > 0) return !1;
2683
2687
  const t = u.pos, n = u.posMax;
2684
2688
  if (t + 3 > n || u.src.charCodeAt(t) !== 58 || u.src.charCodeAt(t + 1) !== 47 || u.src.charCodeAt(t + 2) !== 47) return !1;
2685
- const r = u.pending.match(pc);
2689
+ const r = u.pending.match(bo);
2686
2690
  if (!r) return !1;
2687
- const o = r[1], i = u.md.linkify.matchAtStart(u.src.slice(t - o.length));
2691
+ const c = r[1], i = u.md.linkify.matchAtStart(u.src.slice(t - c.length));
2688
2692
  if (!i) return !1;
2689
- let c = i.url;
2690
- if (c.length <= o.length) return !1;
2691
- c = c.replace(/\*+$/, "");
2692
- const a = u.md.normalizeLink(c);
2693
+ let o = i.url;
2694
+ if (o.length <= c.length) return !1;
2695
+ o = o.replace(/\*+$/, "");
2696
+ const a = u.md.normalizeLink(o);
2693
2697
  if (!u.md.validateLink(a)) return !1;
2694
2698
  if (!e) {
2695
- u.pending = u.pending.slice(0, -o.length);
2699
+ u.pending = u.pending.slice(0, -c.length);
2696
2700
  const s = u.push("link_open", "a", 1);
2697
2701
  s.attrs = [["href", a]], s.markup = "linkify", s.info = "auto";
2698
2702
  const f = u.push("text", "", 0);
2699
- f.content = u.md.normalizeLinkText(c);
2703
+ f.content = u.md.normalizeLinkText(o);
2700
2704
  const d = u.push("link_close", "a", -1);
2701
2705
  d.markup = "linkify", d.info = "auto";
2702
2706
  }
2703
- return u.pos += c.length - o.length, !0;
2707
+ return u.pos += o.length - c.length, !0;
2704
2708
  }
2705
- function mc(u, e) {
2709
+ function _o(u, e) {
2706
2710
  let t = u.pos;
2707
2711
  if (u.src.charCodeAt(t) !== 10)
2708
2712
  return !1;
@@ -2710,14 +2714,14 @@ function mc(u, e) {
2710
2714
  if (!e)
2711
2715
  if (n >= 0 && u.pending.charCodeAt(n) === 32)
2712
2716
  if (n >= 1 && u.pending.charCodeAt(n - 1) === 32) {
2713
- let o = n - 1;
2714
- for (; o >= 1 && u.pending.charCodeAt(o - 1) === 32; ) o--;
2715
- u.pending = u.pending.slice(0, o), u.push("hardbreak", "br", 0);
2717
+ let c = n - 1;
2718
+ for (; c >= 1 && u.pending.charCodeAt(c - 1) === 32; ) c--;
2719
+ u.pending = u.pending.slice(0, c), u.push("hardbreak", "br", 0);
2716
2720
  } else
2717
2721
  u.pending = u.pending.slice(0, -1), u.push("softbreak", "br", 0);
2718
2722
  else
2719
2723
  u.push("softbreak", "br", 0);
2720
- for (t++; t < r && w(u.src.charCodeAt(t)); )
2724
+ for (t++; t < r && S(u.src.charCodeAt(t)); )
2721
2725
  t++;
2722
2726
  return u.pos = t, !0;
2723
2727
  }
@@ -2727,46 +2731,46 @@ for (let u = 0; u < 256; u++)
2727
2731
  "\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach(function(u) {
2728
2732
  g0[u.charCodeAt(0)] = 1;
2729
2733
  });
2730
- function _c(u, e) {
2734
+ function mo(u, e) {
2731
2735
  let t = u.pos;
2732
2736
  const n = u.posMax;
2733
2737
  if (u.src.charCodeAt(t) !== 92 || (t++, t >= n)) return !1;
2734
2738
  let r = u.src.charCodeAt(t);
2735
2739
  if (r === 10) {
2736
- for (e || u.push("hardbreak", "br", 0), t++; t < n && (r = u.src.charCodeAt(t), !!w(r)); )
2740
+ for (e || u.push("hardbreak", "br", 0), t++; t < n && (r = u.src.charCodeAt(t), !!S(r)); )
2737
2741
  t++;
2738
2742
  return u.pos = t, !0;
2739
2743
  }
2740
- let o = u.src[t];
2744
+ let c = u.src[t];
2741
2745
  if (r >= 55296 && r <= 56319 && t + 1 < n) {
2742
- const c = u.src.charCodeAt(t + 1);
2743
- c >= 56320 && c <= 57343 && (o += u.src[t + 1], t++);
2746
+ const o = u.src.charCodeAt(t + 1);
2747
+ o >= 56320 && o <= 57343 && (c += u.src[t + 1], t++);
2744
2748
  }
2745
- const i = "\\" + o;
2749
+ const i = "\\" + c;
2746
2750
  if (!e) {
2747
- const c = u.push("text_special", "", 0);
2748
- r < 256 && g0[r] !== 0 ? c.content = o : c.content = i, c.markup = i, c.info = "escape";
2751
+ const o = u.push("text_special", "", 0);
2752
+ r < 256 && g0[r] !== 0 ? o.content = c : o.content = i, o.markup = i, o.info = "escape";
2749
2753
  }
2750
2754
  return u.pos = t + 1, !0;
2751
2755
  }
2752
- function xc(u, e) {
2756
+ function xo(u, e) {
2753
2757
  let t = u.pos;
2754
2758
  if (u.src.charCodeAt(t) !== 96)
2755
2759
  return !1;
2756
2760
  const r = t;
2757
2761
  t++;
2758
- const o = u.posMax;
2759
- for (; t < o && u.src.charCodeAt(t) === 96; )
2762
+ const c = u.posMax;
2763
+ for (; t < c && u.src.charCodeAt(t) === 96; )
2760
2764
  t++;
2761
- const i = u.src.slice(r, t), c = i.length;
2762
- if (u.backticksScanned && (u.backticks[c] || 0) <= r)
2763
- return e || (u.pending += i), u.pos += c, !0;
2765
+ const i = u.src.slice(r, t), o = i.length;
2766
+ if (u.backticksScanned && (u.backticks[o] || 0) <= r)
2767
+ return e || (u.pending += i), u.pos += o, !0;
2764
2768
  let a = t, s;
2765
2769
  for (; (s = u.src.indexOf("`", a)) !== -1; ) {
2766
- for (a = s + 1; a < o && u.src.charCodeAt(a) === 96; )
2770
+ for (a = s + 1; a < c && u.src.charCodeAt(a) === 96; )
2767
2771
  a++;
2768
2772
  const f = a - s;
2769
- if (f === c) {
2773
+ if (f === o) {
2770
2774
  if (!e) {
2771
2775
  const d = u.push("code_inline", "code", 0);
2772
2776
  d.markup = i, d.content = u.src.slice(t, s).replace(/\n/g, " ").replace(/^ (.+) $/, "$1");
@@ -2775,21 +2779,21 @@ function xc(u, e) {
2775
2779
  }
2776
2780
  u.backticks[f] = s;
2777
2781
  }
2778
- return u.backticksScanned = !0, e || (u.pending += i), u.pos += c, !0;
2782
+ return u.backticksScanned = !0, e || (u.pending += i), u.pos += o, !0;
2779
2783
  }
2780
- function gc(u, e) {
2784
+ function go(u, e) {
2781
2785
  const t = u.pos, n = u.src.charCodeAt(t);
2782
2786
  if (e || n !== 126)
2783
2787
  return !1;
2784
2788
  const r = u.scanDelims(u.pos, !0);
2785
- let o = r.length;
2789
+ let c = r.length;
2786
2790
  const i = String.fromCharCode(n);
2787
- if (o < 2)
2791
+ if (c < 2)
2788
2792
  return !1;
2789
- let c;
2790
- o % 2 && (c = u.push("text", "", 0), c.content = i, o--);
2791
- for (let a = 0; a < o; a += 2)
2792
- c = u.push("text", "", 0), c.content = i + i, u.delimiters.push({
2793
+ let o;
2794
+ c % 2 && (o = u.push("text", "", 0), o.content = i, c--);
2795
+ for (let a = 0; a < c; a += 2)
2796
+ o = u.push("text", "", 0), o.content = i + i, u.delimiters.push({
2793
2797
  marker: n,
2794
2798
  length: 0,
2795
2799
  // disable "rule of 3" length checks meant for emphasis
@@ -2800,40 +2804,40 @@ function gc(u, e) {
2800
2804
  });
2801
2805
  return u.pos += r.length, !0;
2802
2806
  }
2803
- function xt(u, e) {
2807
+ function mt(u, e) {
2804
2808
  let t;
2805
2809
  const n = [], r = e.length;
2806
- for (let o = 0; o < r; o++) {
2807
- const i = e[o];
2810
+ for (let c = 0; c < r; c++) {
2811
+ const i = e[c];
2808
2812
  if (i.marker !== 126 || i.end === -1)
2809
2813
  continue;
2810
- const c = e[i.end];
2811
- t = u.tokens[i.token], t.type = "s_open", t.tag = "s", t.nesting = 1, t.markup = "~~", t.content = "", t = u.tokens[c.token], t.type = "s_close", t.tag = "s", t.nesting = -1, t.markup = "~~", t.content = "", u.tokens[c.token - 1].type === "text" && u.tokens[c.token - 1].content === "~" && n.push(c.token - 1);
2814
+ const o = e[i.end];
2815
+ t = u.tokens[i.token], t.type = "s_open", t.tag = "s", t.nesting = 1, t.markup = "~~", t.content = "", t = u.tokens[o.token], t.type = "s_close", t.tag = "s", t.nesting = -1, t.markup = "~~", t.content = "", u.tokens[o.token - 1].type === "text" && u.tokens[o.token - 1].content === "~" && n.push(o.token - 1);
2812
2816
  }
2813
2817
  for (; n.length; ) {
2814
- const o = n.pop();
2815
- let i = o + 1;
2818
+ const c = n.pop();
2819
+ let i = c + 1;
2816
2820
  for (; i < u.tokens.length && u.tokens[i].type === "s_close"; )
2817
2821
  i++;
2818
- i--, o !== i && (t = u.tokens[i], u.tokens[i] = u.tokens[o], u.tokens[o] = t);
2822
+ i--, c !== i && (t = u.tokens[i], u.tokens[i] = u.tokens[c], u.tokens[c] = t);
2819
2823
  }
2820
2824
  }
2821
- function kc(u) {
2825
+ function ko(u) {
2822
2826
  const e = u.tokens_meta, t = u.tokens_meta.length;
2823
- xt(u, u.delimiters);
2827
+ mt(u, u.delimiters);
2824
2828
  for (let n = 0; n < t; n++)
2825
- e[n] && e[n].delimiters && xt(u, e[n].delimiters);
2829
+ e[n] && e[n].delimiters && mt(u, e[n].delimiters);
2826
2830
  }
2827
2831
  const jt = {
2828
- tokenize: gc,
2829
- postProcess: kc
2832
+ tokenize: go,
2833
+ postProcess: ko
2830
2834
  };
2831
- function Ec(u, e) {
2835
+ function Eo(u, e) {
2832
2836
  const t = u.pos, n = u.src.charCodeAt(t);
2833
2837
  if (e || n !== 95 && n !== 42)
2834
2838
  return !1;
2835
2839
  const r = u.scanDelims(u.pos, n === 42);
2836
- for (let o = 0; o < r.length; o++) {
2840
+ for (let c = 0; c < r.length; c++) {
2837
2841
  const i = u.push("text", "", 0);
2838
2842
  i.content = String.fromCharCode(n), u.delimiters.push({
2839
2843
  // Char code of the starting marker (number).
@@ -2858,48 +2862,48 @@ function Ec(u, e) {
2858
2862
  }
2859
2863
  return u.pos += r.length, !0;
2860
2864
  }
2861
- function gt(u, e) {
2865
+ function xt(u, e) {
2862
2866
  const t = e.length;
2863
2867
  for (let n = t - 1; n >= 0; n--) {
2864
2868
  const r = e[n];
2865
2869
  if (r.marker !== 95 && r.marker !== 42 || r.end === -1)
2866
2870
  continue;
2867
- const o = e[r.end], i = n > 0 && e[n - 1].end === r.end + 1 && // check that first two markers match and adjacent
2871
+ const c = e[r.end], i = n > 0 && e[n - 1].end === r.end + 1 && // check that first two markers match and adjacent
2868
2872
  e[n - 1].marker === r.marker && e[n - 1].token === r.token - 1 && // check that last two markers are adjacent (we can safely assume they match)
2869
- e[r.end + 1].token === o.token + 1, c = String.fromCharCode(r.marker), a = u.tokens[r.token];
2870
- a.type = i ? "strong_open" : "em_open", a.tag = i ? "strong" : "em", a.nesting = 1, a.markup = i ? c + c : c, a.content = "";
2871
- const s = u.tokens[o.token];
2872
- s.type = i ? "strong_close" : "em_close", s.tag = i ? "strong" : "em", s.nesting = -1, s.markup = i ? c + c : c, s.content = "", i && (u.tokens[e[n - 1].token].content = "", u.tokens[e[r.end + 1].token].content = "", n--);
2873
+ e[r.end + 1].token === c.token + 1, o = String.fromCharCode(r.marker), a = u.tokens[r.token];
2874
+ a.type = i ? "strong_open" : "em_open", a.tag = i ? "strong" : "em", a.nesting = 1, a.markup = i ? o + o : o, a.content = "";
2875
+ const s = u.tokens[c.token];
2876
+ s.type = i ? "strong_close" : "em_close", s.tag = i ? "strong" : "em", s.nesting = -1, s.markup = i ? o + o : o, s.content = "", i && (u.tokens[e[n - 1].token].content = "", u.tokens[e[r.end + 1].token].content = "", n--);
2873
2877
  }
2874
2878
  }
2875
- function Ac(u) {
2879
+ function Ao(u) {
2876
2880
  const e = u.tokens_meta, t = u.tokens_meta.length;
2877
- gt(u, u.delimiters);
2881
+ xt(u, u.delimiters);
2878
2882
  for (let n = 0; n < t; n++)
2879
- e[n] && e[n].delimiters && gt(u, e[n].delimiters);
2883
+ e[n] && e[n].delimiters && xt(u, e[n].delimiters);
2880
2884
  }
2881
2885
  const Gt = {
2882
- tokenize: Ec,
2883
- postProcess: Ac
2886
+ tokenize: Eo,
2887
+ postProcess: Ao
2884
2888
  };
2885
- function Cc(u, e) {
2886
- let t, n, r, o, i = "", c = "", a = u.pos, s = !0;
2889
+ function Co(u, e) {
2890
+ let t, n, r, c, i = "", o = "", a = u.pos, s = !0;
2887
2891
  if (u.src.charCodeAt(u.pos) !== 91)
2888
2892
  return !1;
2889
- const f = u.pos, d = u.posMax, m = u.pos + 1, p = u.md.helpers.parseLinkLabel(u, u.pos, !0);
2890
- if (p < 0)
2893
+ const f = u.pos, d = u.posMax, _ = u.pos + 1, b = u.md.helpers.parseLinkLabel(u, u.pos, !0);
2894
+ if (b < 0)
2891
2895
  return !1;
2892
- let h = p + 1;
2896
+ let h = b + 1;
2893
2897
  if (h < d && u.src.charCodeAt(h) === 40) {
2894
- for (s = !1, h++; h < d && (t = u.src.charCodeAt(h), !(!w(t) && t !== 10)); h++)
2898
+ for (s = !1, h++; h < d && (t = u.src.charCodeAt(h), !(!S(t) && t !== 10)); h++)
2895
2899
  ;
2896
2900
  if (h >= d)
2897
2901
  return !1;
2898
2902
  if (a = h, r = u.md.helpers.parseLinkDestination(u.src, h, u.posMax), r.ok) {
2899
- for (i = u.md.normalizeLink(r.str), u.md.validateLink(i) ? h = r.pos : i = "", a = h; h < d && (t = u.src.charCodeAt(h), !(!w(t) && t !== 10)); h++)
2903
+ for (i = u.md.normalizeLink(r.str), u.md.validateLink(i) ? h = r.pos : i = "", a = h; h < d && (t = u.src.charCodeAt(h), !(!S(t) && t !== 10)); h++)
2900
2904
  ;
2901
2905
  if (r = u.md.helpers.parseLinkTitle(u.src, h, u.posMax), h < d && a !== h && r.ok)
2902
- for (c = r.str, h = r.pos; h < d && (t = u.src.charCodeAt(h), !(!w(t) && t !== 10)); h++)
2906
+ for (o = r.str, h = r.pos; h < d && (t = u.src.charCodeAt(h), !(!S(t) && t !== 10)); h++)
2903
2907
  ;
2904
2908
  }
2905
2909
  (h >= d || u.src.charCodeAt(h) !== 41) && (s = !0), h++;
@@ -2907,49 +2911,49 @@ function Cc(u, e) {
2907
2911
  if (s) {
2908
2912
  if (typeof u.env.references > "u")
2909
2913
  return !1;
2910
- if (h < d && u.src.charCodeAt(h) === 91 ? (a = h + 1, h = u.md.helpers.parseLinkLabel(u, h), h >= 0 ? n = u.src.slice(a, h++) : h = p + 1) : h = p + 1, n || (n = u.src.slice(m, p)), o = u.env.references[we(n)], !o)
2914
+ if (h < d && u.src.charCodeAt(h) === 91 ? (a = h + 1, h = u.md.helpers.parseLinkLabel(u, h), h >= 0 ? n = u.src.slice(a, h++) : h = b + 1) : h = b + 1, n || (n = u.src.slice(_, b)), c = u.env.references[Te(n)], !c)
2911
2915
  return u.pos = f, !1;
2912
- i = o.href, c = o.title;
2916
+ i = c.href, o = c.title;
2913
2917
  }
2914
2918
  if (!e) {
2915
- u.pos = m, u.posMax = p;
2916
- const C = u.push("link_open", "a", 1), D = [["href", i]];
2917
- C.attrs = D, c && D.push(["title", c]), u.linkLevel++, u.md.inline.tokenize(u), u.linkLevel--, u.push("link_close", "a", -1);
2919
+ u.pos = _, u.posMax = b;
2920
+ const C = u.push("link_open", "a", 1), y = [["href", i]];
2921
+ C.attrs = y, o && y.push(["title", o]), u.linkLevel++, u.md.inline.tokenize(u), u.linkLevel--, u.push("link_close", "a", -1);
2918
2922
  }
2919
2923
  return u.pos = h, u.posMax = d, !0;
2920
2924
  }
2921
- function Dc(u, e) {
2922
- let t, n, r, o, i, c, a, s, f = "";
2923
- const d = u.pos, m = u.posMax;
2925
+ function Do(u, e) {
2926
+ let t, n, r, c, i, o, a, s, f = "";
2927
+ const d = u.pos, _ = u.posMax;
2924
2928
  if (u.src.charCodeAt(u.pos) !== 33 || u.src.charCodeAt(u.pos + 1) !== 91)
2925
2929
  return !1;
2926
- const p = u.pos + 2, h = u.md.helpers.parseLinkLabel(u, u.pos + 1, !1);
2930
+ const b = u.pos + 2, h = u.md.helpers.parseLinkLabel(u, u.pos + 1, !1);
2927
2931
  if (h < 0)
2928
2932
  return !1;
2929
- if (o = h + 1, o < m && u.src.charCodeAt(o) === 40) {
2930
- for (o++; o < m && (t = u.src.charCodeAt(o), !(!w(t) && t !== 10)); o++)
2933
+ if (c = h + 1, c < _ && u.src.charCodeAt(c) === 40) {
2934
+ for (c++; c < _ && (t = u.src.charCodeAt(c), !(!S(t) && t !== 10)); c++)
2931
2935
  ;
2932
- if (o >= m)
2936
+ if (c >= _)
2933
2937
  return !1;
2934
- for (s = o, c = u.md.helpers.parseLinkDestination(u.src, o, u.posMax), c.ok && (f = u.md.normalizeLink(c.str), u.md.validateLink(f) ? o = c.pos : f = ""), s = o; o < m && (t = u.src.charCodeAt(o), !(!w(t) && t !== 10)); o++)
2938
+ for (s = c, o = u.md.helpers.parseLinkDestination(u.src, c, u.posMax), o.ok && (f = u.md.normalizeLink(o.str), u.md.validateLink(f) ? c = o.pos : f = ""), s = c; c < _ && (t = u.src.charCodeAt(c), !(!S(t) && t !== 10)); c++)
2935
2939
  ;
2936
- if (c = u.md.helpers.parseLinkTitle(u.src, o, u.posMax), o < m && s !== o && c.ok)
2937
- for (a = c.str, o = c.pos; o < m && (t = u.src.charCodeAt(o), !(!w(t) && t !== 10)); o++)
2940
+ if (o = u.md.helpers.parseLinkTitle(u.src, c, u.posMax), c < _ && s !== c && o.ok)
2941
+ for (a = o.str, c = o.pos; c < _ && (t = u.src.charCodeAt(c), !(!S(t) && t !== 10)); c++)
2938
2942
  ;
2939
2943
  else
2940
2944
  a = "";
2941
- if (o >= m || u.src.charCodeAt(o) !== 41)
2945
+ if (c >= _ || u.src.charCodeAt(c) !== 41)
2942
2946
  return u.pos = d, !1;
2943
- o++;
2947
+ c++;
2944
2948
  } else {
2945
2949
  if (typeof u.env.references > "u")
2946
2950
  return !1;
2947
- if (o < m && u.src.charCodeAt(o) === 91 ? (s = o + 1, o = u.md.helpers.parseLinkLabel(u, o), o >= 0 ? r = u.src.slice(s, o++) : o = h + 1) : o = h + 1, r || (r = u.src.slice(p, h)), i = u.env.references[we(r)], !i)
2951
+ if (c < _ && u.src.charCodeAt(c) === 91 ? (s = c + 1, c = u.md.helpers.parseLinkLabel(u, c), c >= 0 ? r = u.src.slice(s, c++) : c = h + 1) : c = h + 1, r || (r = u.src.slice(b, h)), i = u.env.references[Te(r)], !i)
2948
2952
  return u.pos = d, !1;
2949
2953
  f = i.href, a = i.title;
2950
2954
  }
2951
2955
  if (!e) {
2952
- n = u.src.slice(p, h);
2956
+ n = u.src.slice(b, h);
2953
2957
  const C = [];
2954
2958
  u.md.inline.parse(
2955
2959
  n,
@@ -2957,13 +2961,13 @@ function Dc(u, e) {
2957
2961
  u.env,
2958
2962
  C
2959
2963
  );
2960
- const D = u.push("image", "img", 0), T = [["src", f], ["alt", ""]];
2961
- D.attrs = T, D.children = C, D.content = n, a && T.push(["title", a]);
2964
+ const y = u.push("image", "img", 0), T = [["src", f], ["alt", ""]];
2965
+ y.attrs = T, y.children = C, y.content = n, a && T.push(["title", a]);
2962
2966
  }
2963
- return u.pos = o, u.posMax = m, !0;
2967
+ return u.pos = c, u.posMax = _, !0;
2964
2968
  }
2965
- const yc = /^([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])?)*)$/, Fc = /^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;
2966
- function Tc(u, e) {
2969
+ const yo = /^([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])?)*)$/, Fo = /^([a-zA-Z][a-zA-Z0-9+.-]{1,31}):([^<>\x00-\x20]*)$/;
2970
+ function To(u, e) {
2967
2971
  let t = u.pos;
2968
2972
  if (u.src.charCodeAt(t) !== 60)
2969
2973
  return !1;
@@ -2974,187 +2978,187 @@ function Tc(u, e) {
2974
2978
  if (i === 60) return !1;
2975
2979
  if (i === 62) break;
2976
2980
  }
2977
- const o = u.src.slice(n + 1, t);
2978
- if (Fc.test(o)) {
2979
- const i = u.md.normalizeLink(o);
2981
+ const c = u.src.slice(n + 1, t);
2982
+ if (Fo.test(c)) {
2983
+ const i = u.md.normalizeLink(c);
2980
2984
  if (!u.md.validateLink(i))
2981
2985
  return !1;
2982
2986
  if (!e) {
2983
- const c = u.push("link_open", "a", 1);
2984
- c.attrs = [["href", i]], c.markup = "autolink", c.info = "auto";
2987
+ const o = u.push("link_open", "a", 1);
2988
+ o.attrs = [["href", i]], o.markup = "autolink", o.info = "auto";
2985
2989
  const a = u.push("text", "", 0);
2986
- a.content = u.md.normalizeLinkText(o);
2990
+ a.content = u.md.normalizeLinkText(c);
2987
2991
  const s = u.push("link_close", "a", -1);
2988
2992
  s.markup = "autolink", s.info = "auto";
2989
2993
  }
2990
- return u.pos += o.length + 2, !0;
2994
+ return u.pos += c.length + 2, !0;
2991
2995
  }
2992
- if (yc.test(o)) {
2993
- const i = u.md.normalizeLink("mailto:" + o);
2996
+ if (yo.test(c)) {
2997
+ const i = u.md.normalizeLink("mailto:" + c);
2994
2998
  if (!u.md.validateLink(i))
2995
2999
  return !1;
2996
3000
  if (!e) {
2997
- const c = u.push("link_open", "a", 1);
2998
- c.attrs = [["href", i]], c.markup = "autolink", c.info = "auto";
3001
+ const o = u.push("link_open", "a", 1);
3002
+ o.attrs = [["href", i]], o.markup = "autolink", o.info = "auto";
2999
3003
  const a = u.push("text", "", 0);
3000
- a.content = u.md.normalizeLinkText(o);
3004
+ a.content = u.md.normalizeLinkText(c);
3001
3005
  const s = u.push("link_close", "a", -1);
3002
3006
  s.markup = "autolink", s.info = "auto";
3003
3007
  }
3004
- return u.pos += o.length + 2, !0;
3008
+ return u.pos += c.length + 2, !0;
3005
3009
  }
3006
3010
  return !1;
3007
3011
  }
3008
- function Sc(u) {
3012
+ function So(u) {
3009
3013
  return /^<a[>\s]/i.test(u);
3010
3014
  }
3011
- function wc(u) {
3015
+ function wo(u) {
3012
3016
  return /^<\/a\s*>/i.test(u);
3013
3017
  }
3014
- function vc(u) {
3018
+ function vo(u) {
3015
3019
  const e = u | 32;
3016
3020
  return e >= 97 && e <= 122;
3017
3021
  }
3018
- function Rc(u, e) {
3022
+ function Ro(u, e) {
3019
3023
  if (!u.md.options.html)
3020
3024
  return !1;
3021
3025
  const t = u.posMax, n = u.pos;
3022
3026
  if (u.src.charCodeAt(n) !== 60 || n + 2 >= t)
3023
3027
  return !1;
3024
3028
  const r = u.src.charCodeAt(n + 1);
3025
- if (r !== 33 && r !== 63 && r !== 47 && !vc(r))
3029
+ if (r !== 33 && r !== 63 && r !== 47 && !vo(r))
3026
3030
  return !1;
3027
- const o = u.src.slice(n).match(cc);
3028
- if (!o)
3031
+ const c = u.src.slice(n).match(co);
3032
+ if (!c)
3029
3033
  return !1;
3030
3034
  if (!e) {
3031
3035
  const i = u.push("html_inline", "", 0);
3032
- i.content = o[0], Sc(i.content) && u.linkLevel++, wc(i.content) && u.linkLevel--;
3036
+ i.content = c[0], So(i.content) && u.linkLevel++, wo(i.content) && u.linkLevel--;
3033
3037
  }
3034
- return u.pos += o[0].length, !0;
3038
+ return u.pos += c[0].length, !0;
3035
3039
  }
3036
- const Ic = /^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i, Mc = /^&([a-z][a-z0-9]{1,31});/i;
3037
- function Lc(u, e) {
3040
+ const Io = /^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i, Mo = /^&([a-z][a-z0-9]{1,31});/i;
3041
+ function Lo(u, e) {
3038
3042
  const t = u.pos, n = u.posMax;
3039
3043
  if (u.src.charCodeAt(t) !== 38 || t + 1 >= n) return !1;
3040
3044
  if (u.src.charCodeAt(t + 1) === 35) {
3041
- const o = u.src.slice(t).match(Ic);
3042
- if (o) {
3045
+ const c = u.src.slice(t).match(Io);
3046
+ if (c) {
3043
3047
  if (!e) {
3044
- const i = o[1][0].toLowerCase() === "x" ? parseInt(o[1].slice(1), 16) : parseInt(o[1], 10), c = u.push("text_special", "", 0);
3045
- c.content = _0(i) ? Fe(i) : Fe(65533), c.markup = o[0], c.info = "entity";
3048
+ const i = c[1][0].toLowerCase() === "x" ? parseInt(c[1].slice(1), 16) : parseInt(c[1], 10), o = u.push("text_special", "", 0);
3049
+ o.content = m0(i) ? De(i) : De(65533), o.markup = c[0], o.info = "entity";
3046
3050
  }
3047
- return u.pos += o[0].length, !0;
3051
+ return u.pos += c[0].length, !0;
3048
3052
  }
3049
3053
  } else {
3050
- const o = u.src.slice(t).match(Mc);
3051
- if (o) {
3052
- const i = Bt(o[0]);
3053
- if (i !== o[0]) {
3054
+ const c = u.src.slice(t).match(Mo);
3055
+ if (c) {
3056
+ const i = Bt(c[0]);
3057
+ if (i !== c[0]) {
3054
3058
  if (!e) {
3055
- const c = u.push("text_special", "", 0);
3056
- c.content = i, c.markup = o[0], c.info = "entity";
3059
+ const o = u.push("text_special", "", 0);
3060
+ o.content = i, o.markup = c[0], o.info = "entity";
3057
3061
  }
3058
- return u.pos += o[0].length, !0;
3062
+ return u.pos += c[0].length, !0;
3059
3063
  }
3060
3064
  }
3061
3065
  }
3062
3066
  return !1;
3063
3067
  }
3064
- function kt(u) {
3068
+ function gt(u) {
3065
3069
  const e = {}, t = u.length;
3066
3070
  if (!t) return;
3067
3071
  let n = 0, r = -2;
3068
- const o = [];
3072
+ const c = [];
3069
3073
  for (let i = 0; i < t; i++) {
3070
- const c = u[i];
3071
- if (o.push(0), (u[n].marker !== c.marker || r !== c.token - 1) && (n = i), r = c.token, c.length = c.length || 0, !c.close) continue;
3072
- e.hasOwnProperty(c.marker) || (e[c.marker] = [-1, -1, -1, -1, -1, -1]);
3073
- const a = e[c.marker][(c.open ? 3 : 0) + c.length % 3];
3074
- let s = n - o[n] - 1, f = s;
3075
- for (; s > a; s -= o[s] + 1) {
3074
+ const o = u[i];
3075
+ if (c.push(0), (u[n].marker !== o.marker || r !== o.token - 1) && (n = i), r = o.token, o.length = o.length || 0, !o.close) continue;
3076
+ e.hasOwnProperty(o.marker) || (e[o.marker] = [-1, -1, -1, -1, -1, -1]);
3077
+ const a = e[o.marker][(o.open ? 3 : 0) + o.length % 3];
3078
+ let s = n - c[n] - 1, f = s;
3079
+ for (; s > a; s -= c[s] + 1) {
3076
3080
  const d = u[s];
3077
- if (d.marker === c.marker && d.open && d.end < 0) {
3078
- let m = !1;
3079
- if ((d.close || c.open) && (d.length + c.length) % 3 === 0 && (d.length % 3 !== 0 || c.length % 3 !== 0) && (m = !0), !m) {
3080
- const p = s > 0 && !u[s - 1].open ? o[s - 1] + 1 : 0;
3081
- o[i] = i - s + p, o[s] = p, c.open = !1, d.end = i, d.close = !1, f = -1, r = -2;
3081
+ if (d.marker === o.marker && d.open && d.end < 0) {
3082
+ let _ = !1;
3083
+ if ((d.close || o.open) && (d.length + o.length) % 3 === 0 && (d.length % 3 !== 0 || o.length % 3 !== 0) && (_ = !0), !_) {
3084
+ const b = s > 0 && !u[s - 1].open ? c[s - 1] + 1 : 0;
3085
+ c[i] = i - s + b, c[s] = b, o.open = !1, d.end = i, d.close = !1, f = -1, r = -2;
3082
3086
  break;
3083
3087
  }
3084
3088
  }
3085
3089
  }
3086
- f !== -1 && (e[c.marker][(c.open ? 3 : 0) + (c.length || 0) % 3] = f);
3090
+ f !== -1 && (e[o.marker][(o.open ? 3 : 0) + (o.length || 0) % 3] = f);
3087
3091
  }
3088
3092
  }
3089
- function Oc(u) {
3093
+ function Oo(u) {
3090
3094
  const e = u.tokens_meta, t = u.tokens_meta.length;
3091
- kt(u.delimiters);
3095
+ gt(u.delimiters);
3092
3096
  for (let n = 0; n < t; n++)
3093
- e[n] && e[n].delimiters && kt(e[n].delimiters);
3097
+ e[n] && e[n].delimiters && gt(e[n].delimiters);
3094
3098
  }
3095
- function Nc(u) {
3099
+ function No(u) {
3096
3100
  let e, t, n = 0;
3097
- const r = u.tokens, o = u.tokens.length;
3098
- for (e = t = 0; e < o; e++)
3099
- r[e].nesting < 0 && n--, r[e].level = n, r[e].nesting > 0 && n++, r[e].type === "text" && e + 1 < o && r[e + 1].type === "text" ? r[e + 1].content = r[e].content + r[e + 1].content : (e !== t && (r[t] = r[e]), t++);
3101
+ const r = u.tokens, c = u.tokens.length;
3102
+ for (e = t = 0; e < c; e++)
3103
+ r[e].nesting < 0 && n--, r[e].level = n, r[e].nesting > 0 && n++, r[e].type === "text" && e + 1 < c && r[e + 1].type === "text" ? r[e + 1].content = r[e].content + r[e + 1].content : (e !== t && (r[t] = r[e]), t++);
3100
3104
  e !== t && (r.length = t);
3101
3105
  }
3102
3106
  const Ke = [
3103
- ["text", hc],
3104
- ["linkify", bc],
3105
- ["newline", mc],
3106
- ["escape", _c],
3107
- ["backticks", xc],
3107
+ ["text", ho],
3108
+ ["linkify", po],
3109
+ ["newline", _o],
3110
+ ["escape", mo],
3111
+ ["backticks", xo],
3108
3112
  ["strikethrough", jt.tokenize],
3109
3113
  ["emphasis", Gt.tokenize],
3110
- ["link", Cc],
3111
- ["image", Dc],
3112
- ["autolink", Tc],
3113
- ["html_inline", Rc],
3114
- ["entity", Lc]
3114
+ ["link", Co],
3115
+ ["image", Do],
3116
+ ["autolink", To],
3117
+ ["html_inline", Ro],
3118
+ ["entity", Lo]
3115
3119
  ], u0 = [
3116
- ["balance_pairs", Oc],
3120
+ ["balance_pairs", Oo],
3117
3121
  ["strikethrough", jt.postProcess],
3118
3122
  ["emphasis", Gt.postProcess],
3119
3123
  // rules for pairs separate '**' into its own text tokens, which may be left unused,
3120
3124
  // rule below merges unused segments back with the rest of the text
3121
- ["fragments_join", Nc]
3125
+ ["fragments_join", No]
3122
3126
  ];
3123
- function se() {
3124
- this.ruler = new V();
3127
+ function ae() {
3128
+ this.ruler = new Z();
3125
3129
  for (let u = 0; u < Ke.length; u++)
3126
3130
  this.ruler.push(Ke[u][0], Ke[u][1]);
3127
- this.ruler2 = new V();
3131
+ this.ruler2 = new Z();
3128
3132
  for (let u = 0; u < u0.length; u++)
3129
3133
  this.ruler2.push(u0[u][0], u0[u][1]);
3130
3134
  }
3131
- se.prototype.skipToken = function(u) {
3132
- const e = u.pos, t = this.ruler.getRules(""), n = t.length, r = u.md.options.maxNesting, o = u.cache;
3133
- if (typeof o[e] < "u") {
3134
- u.pos = o[e];
3135
+ ae.prototype.skipToken = function(u) {
3136
+ const e = u.pos, t = this.ruler.getRules(""), n = t.length, r = u.md.options.maxNesting, c = u.cache;
3137
+ if (typeof c[e] < "u") {
3138
+ u.pos = c[e];
3135
3139
  return;
3136
3140
  }
3137
3141
  let i = !1;
3138
3142
  if (u.level < r) {
3139
- for (let c = 0; c < n; c++)
3140
- if (u.level++, i = t[c](u, !0), u.level--, i) {
3143
+ for (let o = 0; o < n; o++)
3144
+ if (u.level++, i = t[o](u, !0), u.level--, i) {
3141
3145
  if (e >= u.pos)
3142
3146
  throw new Error("inline rule didn't increment state.pos");
3143
3147
  break;
3144
3148
  }
3145
3149
  } else
3146
3150
  u.pos = u.posMax;
3147
- i || u.pos++, o[e] = u.pos;
3151
+ i || u.pos++, c[e] = u.pos;
3148
3152
  };
3149
- se.prototype.tokenize = function(u) {
3153
+ ae.prototype.tokenize = function(u) {
3150
3154
  const e = this.ruler.getRules(""), t = e.length, n = u.posMax, r = u.md.options.maxNesting;
3151
3155
  for (; u.pos < n; ) {
3152
- const o = u.pos;
3156
+ const c = u.pos;
3153
3157
  let i = !1;
3154
3158
  if (u.level < r) {
3155
- for (let c = 0; c < t; c++)
3156
- if (i = e[c](u, !1), i) {
3157
- if (o >= u.pos)
3159
+ for (let o = 0; o < t; o++)
3160
+ if (i = e[o](u, !1), i) {
3161
+ if (c >= u.pos)
3158
3162
  throw new Error("inline rule didn't increment state.pos");
3159
3163
  break;
3160
3164
  }
@@ -3168,17 +3172,17 @@ se.prototype.tokenize = function(u) {
3168
3172
  }
3169
3173
  u.pending && u.pushPending();
3170
3174
  };
3171
- se.prototype.parse = function(u, e, t, n) {
3175
+ ae.prototype.parse = function(u, e, t, n) {
3172
3176
  const r = new this.State(u, e, t, n);
3173
3177
  this.tokenize(r);
3174
- const o = this.ruler2.getRules(""), i = o.length;
3175
- for (let c = 0; c < i; c++)
3176
- o[c](r);
3178
+ const c = this.ruler2.getRules(""), i = c.length;
3179
+ for (let o = 0; o < i; o++)
3180
+ c[o](r);
3177
3181
  };
3178
- se.prototype.State = ae;
3179
- function Bc(u) {
3182
+ ae.prototype.State = ie;
3183
+ function Bo(u) {
3180
3184
  const e = {};
3181
- u = u || {}, e.src_Any = It.source, e.src_Cc = Mt.source, e.src_Z = Ot.source, e.src_P = b0.source, e.src_ZPCc = [e.src_Z, e.src_P, e.src_Cc].join("|"), e.src_ZCc = [e.src_Z, e.src_Cc].join("|");
3185
+ u = u || {}, e.src_Any = It.source, e.src_Cc = Mt.source, e.src_Z = Ot.source, e.src_P = p0.source, e.src_ZPCc = [e.src_Z, e.src_P, e.src_Cc].join("|"), e.src_ZCc = [e.src_Z, e.src_Cc].join("|");
3182
3186
  const t = "[><|]";
3183
3187
  return e.src_pseudo_letter = "(?:(?!" + t + "|" + e.src_ZPCc + ")" + e.src_Any + ")", e.src_ip4 = "(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)", e.src_auth = "(?:(?:(?!" + e.src_ZCc + "|[@/\\[\\]()]).)+@)?", e.src_port = "(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?", e.src_host_terminator = "(?=$|" + t + "|" + e.src_ZPCc + ")(?!" + (u["---"] ? "-(?!--)|" : "-|") + "_|:\\d|\\.-|\\.(?!$|" + e.src_ZPCc + "))", e.src_path = "(?:[/?#](?:(?!" + e.src_ZCc + "|" + t + `|[()[\\]{}.,"'?!\\-;]).|\\[(?:(?!` + e.src_ZCc + "|\\]).)*\\]|\\((?:(?!" + e.src_ZCc + "|[)]).)*\\)|\\{(?:(?!" + e.src_ZCc + '|[}]).)*\\}|\\"(?:(?!' + e.src_ZCc + `|["]).)+\\"|\\'(?:(?!` + e.src_ZCc + "|[']).)+\\'|\\'(?=" + e.src_pseudo_letter + "|[-])|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!" + e.src_ZCc + "|[.]|$)|" + (u["---"] ? "\\-(?!--(?:[^-]|$))(?:-*)|" : "\\-+|") + // allow `,,,` in paths
3184
3188
  ",(?!" + e.src_ZCc + "|$)|;(?!" + e.src_ZCc + "|$)|\\!+(?!" + e.src_ZCc + "|[!]|$)|\\?(?!" + e.src_ZCc + "|[?]|$))+|\\/)?", e.src_email_name = '[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*', e.src_xn = "xn--[a-z0-9\\-]{1,59}", e.src_domain_root = // Allow letters & digits (http://test1)
@@ -3195,22 +3199,22 @@ function i0(u) {
3195
3199
  });
3196
3200
  }), u;
3197
3201
  }
3198
- function Re(u) {
3202
+ function we(u) {
3199
3203
  return Object.prototype.toString.call(u);
3200
3204
  }
3201
- function Pc(u) {
3202
- return Re(u) === "[object String]";
3205
+ function Po(u) {
3206
+ return we(u) === "[object String]";
3203
3207
  }
3204
- function zc(u) {
3205
- return Re(u) === "[object Object]";
3208
+ function zo(u) {
3209
+ return we(u) === "[object Object]";
3206
3210
  }
3207
- function qc(u) {
3208
- return Re(u) === "[object RegExp]";
3211
+ function qo(u) {
3212
+ return we(u) === "[object RegExp]";
3209
3213
  }
3210
- function Et(u) {
3211
- return Re(u) === "[object Function]";
3214
+ function kt(u) {
3215
+ return we(u) === "[object Function]";
3212
3216
  }
3213
- function Uc(u) {
3217
+ function Uo(u) {
3214
3218
  return u.replace(/[.?*+^$[\]\\(){}|-]/g, "\\$&");
3215
3219
  }
3216
3220
  const Wt = {
@@ -3218,12 +3222,12 @@ const Wt = {
3218
3222
  fuzzyEmail: !0,
3219
3223
  fuzzyIP: !1
3220
3224
  };
3221
- function Hc(u) {
3225
+ function Ho(u) {
3222
3226
  return Object.keys(u || {}).reduce(function(e, t) {
3223
3227
  return e || Wt.hasOwnProperty(t);
3224
3228
  }, !1);
3225
3229
  }
3226
- const $c = {
3230
+ const $o = {
3227
3231
  "http:": {
3228
3232
  validate: function(u, e, t) {
3229
3233
  const n = u.slice(e);
@@ -3255,73 +3259,73 @@ const $c = {
3255
3259
  )), t.re.mailto.test(n) ? n.match(t.re.mailto)[0].length : 0;
3256
3260
  }
3257
3261
  }
3258
- }, jc = "a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]", Gc = "biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");
3259
- function Wc(u) {
3262
+ }, jo = "a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]", Go = "biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");
3263
+ function Wo(u) {
3260
3264
  u.__index__ = -1, u.__text_cache__ = "";
3261
3265
  }
3262
- function Zc(u) {
3266
+ function Zo(u) {
3263
3267
  return function(e, t) {
3264
3268
  const n = e.slice(t);
3265
3269
  return u.test(n) ? n.match(u)[0].length : 0;
3266
3270
  };
3267
3271
  }
3268
- function At() {
3272
+ function Et() {
3269
3273
  return function(u, e) {
3270
3274
  e.normalize(u);
3271
3275
  };
3272
3276
  }
3273
- function Te(u) {
3274
- const e = u.re = Bc(u.__opts__), t = u.__tlds__.slice();
3275
- u.onCompile(), u.__tlds_replaced__ || t.push(jc), t.push(e.src_xn), e.src_tlds = t.join("|");
3276
- function n(c) {
3277
- return c.replace("%TLDS%", e.src_tlds);
3277
+ function ye(u) {
3278
+ const e = u.re = Bo(u.__opts__), t = u.__tlds__.slice();
3279
+ u.onCompile(), u.__tlds_replaced__ || t.push(jo), t.push(e.src_xn), e.src_tlds = t.join("|");
3280
+ function n(o) {
3281
+ return o.replace("%TLDS%", e.src_tlds);
3278
3282
  }
3279
3283
  e.email_fuzzy = RegExp(n(e.tpl_email_fuzzy), "i"), e.link_fuzzy = RegExp(n(e.tpl_link_fuzzy), "i"), e.link_no_ip_fuzzy = RegExp(n(e.tpl_link_no_ip_fuzzy), "i"), e.host_fuzzy_test = RegExp(n(e.tpl_host_fuzzy_test), "i");
3280
3284
  const r = [];
3281
3285
  u.__compiled__ = {};
3282
- function o(c, a) {
3283
- throw new Error('(LinkifyIt) Invalid schema "' + c + '": ' + a);
3286
+ function c(o, a) {
3287
+ throw new Error('(LinkifyIt) Invalid schema "' + o + '": ' + a);
3284
3288
  }
3285
- Object.keys(u.__schemas__).forEach(function(c) {
3286
- const a = u.__schemas__[c];
3289
+ Object.keys(u.__schemas__).forEach(function(o) {
3290
+ const a = u.__schemas__[o];
3287
3291
  if (a === null)
3288
3292
  return;
3289
3293
  const s = { validate: null, link: null };
3290
- if (u.__compiled__[c] = s, zc(a)) {
3291
- qc(a.validate) ? s.validate = Zc(a.validate) : Et(a.validate) ? s.validate = a.validate : o(c, a), Et(a.normalize) ? s.normalize = a.normalize : a.normalize ? o(c, a) : s.normalize = At();
3294
+ if (u.__compiled__[o] = s, zo(a)) {
3295
+ qo(a.validate) ? s.validate = Zo(a.validate) : kt(a.validate) ? s.validate = a.validate : c(o, a), kt(a.normalize) ? s.normalize = a.normalize : a.normalize ? c(o, a) : s.normalize = Et();
3292
3296
  return;
3293
3297
  }
3294
- if (Pc(a)) {
3295
- r.push(c);
3298
+ if (Po(a)) {
3299
+ r.push(o);
3296
3300
  return;
3297
3301
  }
3298
- o(c, a);
3299
- }), r.forEach(function(c) {
3300
- u.__compiled__[u.__schemas__[c]] && (u.__compiled__[c].validate = u.__compiled__[u.__schemas__[c]].validate, u.__compiled__[c].normalize = u.__compiled__[u.__schemas__[c]].normalize);
3301
- }), u.__compiled__[""] = { validate: null, normalize: At() };
3302
- const i = Object.keys(u.__compiled__).filter(function(c) {
3303
- return c.length > 0 && u.__compiled__[c];
3304
- }).map(Uc).join("|");
3302
+ c(o, a);
3303
+ }), r.forEach(function(o) {
3304
+ u.__compiled__[u.__schemas__[o]] && (u.__compiled__[o].validate = u.__compiled__[u.__schemas__[o]].validate, u.__compiled__[o].normalize = u.__compiled__[u.__schemas__[o]].normalize);
3305
+ }), u.__compiled__[""] = { validate: null, normalize: Et() };
3306
+ const i = Object.keys(u.__compiled__).filter(function(o) {
3307
+ return o.length > 0 && u.__compiled__[o];
3308
+ }).map(Uo).join("|");
3305
3309
  u.re.schema_test = RegExp("(^|(?!_)(?:[><|]|" + e.src_ZPCc + "))(" + i + ")", "i"), u.re.schema_search = RegExp("(^|(?!_)(?:[><|]|" + e.src_ZPCc + "))(" + i + ")", "ig"), u.re.schema_at_start = RegExp("^" + u.re.schema_search.source, "i"), u.re.pretest = RegExp(
3306
3310
  "(" + u.re.schema_test.source + ")|(" + u.re.host_fuzzy_test.source + ")|@",
3307
3311
  "i"
3308
- ), Wc(u);
3312
+ ), Wo(u);
3309
3313
  }
3310
- function Vc(u, e) {
3314
+ function Vo(u, e) {
3311
3315
  const t = u.__index__, n = u.__last_index__, r = u.__text_cache__.slice(t, n);
3312
3316
  this.schema = u.__schema__.toLowerCase(), this.index = t + e, this.lastIndex = n + e, this.raw = r, this.text = r, this.url = r;
3313
3317
  }
3314
3318
  function a0(u, e) {
3315
- const t = new Vc(u, e);
3319
+ const t = new Vo(u, e);
3316
3320
  return u.__compiled__[t.schema].normalize(t, u), t;
3317
3321
  }
3318
3322
  function J(u, e) {
3319
3323
  if (!(this instanceof J))
3320
3324
  return new J(u, e);
3321
- e || Hc(u) && (e = u, u = {}), this.__opts__ = i0({}, Wt, e), this.__index__ = -1, this.__last_index__ = -1, this.__schema__ = "", this.__text_cache__ = "", this.__schemas__ = i0({}, $c, u), this.__compiled__ = {}, this.__tlds__ = Gc, this.__tlds_replaced__ = !1, this.re = {}, Te(this);
3325
+ e || Ho(u) && (e = u, u = {}), this.__opts__ = i0({}, Wt, e), this.__index__ = -1, this.__last_index__ = -1, this.__schema__ = "", this.__text_cache__ = "", this.__schemas__ = i0({}, $o, u), this.__compiled__ = {}, this.__tlds__ = Go, this.__tlds_replaced__ = !1, this.re = {}, ye(this);
3322
3326
  }
3323
3327
  J.prototype.add = function(e, t) {
3324
- return this.__schemas__[e] = t, Te(this), this;
3328
+ return this.__schemas__[e] = t, ye(this), this;
3325
3329
  };
3326
3330
  J.prototype.set = function(e) {
3327
3331
  return this.__opts__ = i0(this.__opts__, e), this;
@@ -3329,15 +3333,15 @@ J.prototype.set = function(e) {
3329
3333
  J.prototype.test = function(e) {
3330
3334
  if (this.__text_cache__ = e, this.__index__ = -1, !e.length)
3331
3335
  return !1;
3332
- let t, n, r, o, i, c, a, s, f;
3336
+ let t, n, r, c, i, o, a, s, f;
3333
3337
  if (this.re.schema_test.test(e)) {
3334
3338
  for (a = this.re.schema_search, a.lastIndex = 0; (t = a.exec(e)) !== null; )
3335
- if (o = this.testSchemaAt(e, t[2], a.lastIndex), o) {
3336
- this.__schema__ = t[2], this.__index__ = t.index + t[1].length, this.__last_index__ = t.index + t[0].length + o;
3339
+ if (c = this.testSchemaAt(e, t[2], a.lastIndex), c) {
3340
+ this.__schema__ = t[2], this.__index__ = t.index + t[1].length, this.__last_index__ = t.index + t[0].length + c;
3337
3341
  break;
3338
3342
  }
3339
3343
  }
3340
- return this.__opts__.fuzzyLink && this.__compiled__["http:"] && (s = e.search(this.re.host_fuzzy_test), s >= 0 && (this.__index__ < 0 || s < this.__index__) && (n = e.match(this.__opts__.fuzzyIP ? this.re.link_fuzzy : this.re.link_no_ip_fuzzy)) !== null && (i = n.index + n[1].length, (this.__index__ < 0 || i < this.__index__) && (this.__schema__ = "", this.__index__ = i, this.__last_index__ = n.index + n[0].length))), this.__opts__.fuzzyEmail && this.__compiled__["mailto:"] && (f = e.indexOf("@"), f >= 0 && (r = e.match(this.re.email_fuzzy)) !== null && (i = r.index + r[1].length, c = r.index + r[0].length, (this.__index__ < 0 || i < this.__index__ || i === this.__index__ && c > this.__last_index__) && (this.__schema__ = "mailto:", this.__index__ = i, this.__last_index__ = c))), this.__index__ >= 0;
3344
+ return this.__opts__.fuzzyLink && this.__compiled__["http:"] && (s = e.search(this.re.host_fuzzy_test), s >= 0 && (this.__index__ < 0 || s < this.__index__) && (n = e.match(this.__opts__.fuzzyIP ? this.re.link_fuzzy : this.re.link_no_ip_fuzzy)) !== null && (i = n.index + n[1].length, (this.__index__ < 0 || i < this.__index__) && (this.__schema__ = "", this.__index__ = i, this.__last_index__ = n.index + n[0].length))), this.__opts__.fuzzyEmail && this.__compiled__["mailto:"] && (f = e.indexOf("@"), f >= 0 && (r = e.match(this.re.email_fuzzy)) !== null && (i = r.index + r[1].length, o = r.index + r[0].length, (this.__index__ < 0 || i < this.__index__ || i === this.__index__ && o > this.__last_index__) && (this.__schema__ = "mailto:", this.__index__ = i, this.__last_index__ = o))), this.__index__ >= 0;
3341
3345
  };
3342
3346
  J.prototype.pretest = function(e) {
3343
3347
  return this.re.pretest.test(e);
@@ -3362,20 +3366,20 @@ J.prototype.matchAtStart = function(e) {
3362
3366
  return n ? (this.__schema__ = t[2], this.__index__ = t.index + t[1].length, this.__last_index__ = t.index + t[0].length + n, a0(this, 0)) : null;
3363
3367
  };
3364
3368
  J.prototype.tlds = function(e, t) {
3365
- return e = Array.isArray(e) ? e : [e], t ? (this.__tlds__ = this.__tlds__.concat(e).sort().filter(function(n, r, o) {
3366
- return n !== o[r - 1];
3367
- }).reverse(), Te(this), this) : (this.__tlds__ = e.slice(), this.__tlds_replaced__ = !0, Te(this), this);
3369
+ return e = Array.isArray(e) ? e : [e], t ? (this.__tlds__ = this.__tlds__.concat(e).sort().filter(function(n, r, c) {
3370
+ return n !== c[r - 1];
3371
+ }).reverse(), ye(this), this) : (this.__tlds__ = e.slice(), this.__tlds_replaced__ = !0, ye(this), this);
3368
3372
  };
3369
3373
  J.prototype.normalize = function(e) {
3370
3374
  e.schema || (e.url = "http://" + e.url), e.schema === "mailto:" && !/^mailto:/i.test(e.url) && (e.url = "mailto:" + e.url);
3371
3375
  };
3372
3376
  J.prototype.onCompile = function() {
3373
3377
  };
3374
- const Pu = 2147483647, ou = 36, k0 = 1, ne = 26, Yc = 38, Xc = 700, Zt = 72, Vt = 128, Yt = "-", Jc = /^xn--/, Qc = /[^\0-\x7F]/, Kc = /[\x2E\u3002\uFF0E\uFF61]/g, ui = {
3378
+ const Bu = 2147483647, ou = 36, k0 = 1, te = 26, Yo = 38, Xo = 700, Zt = 72, Vt = 128, Yt = "-", Jo = /^xn--/, Qo = /[^\0-\x7F]/, Ko = /[\x2E\u3002\uFF0E\uFF61]/g, ui = {
3375
3379
  overflow: "Overflow: input needs wider integers to process",
3376
3380
  "not-basic": "Illegal input >= 0x80 (not a basic code point)",
3377
3381
  "invalid-input": "Invalid input"
3378
- }, e0 = ou - k0, cu = Math.floor, t0 = String.fromCharCode;
3382
+ }, e0 = ou - k0, iu = Math.floor, t0 = String.fromCharCode;
3379
3383
  function pu(u) {
3380
3384
  throw new RangeError(ui[u]);
3381
3385
  }
@@ -3389,9 +3393,9 @@ function ei(u, e) {
3389
3393
  function Xt(u, e) {
3390
3394
  const t = u.split("@");
3391
3395
  let n = "";
3392
- t.length > 1 && (n = t[0] + "@", u = t[1]), u = u.replace(Kc, ".");
3393
- const r = u.split("."), o = ei(r, e).join(".");
3394
- return n + o;
3396
+ t.length > 1 && (n = t[0] + "@", u = t[1]), u = u.replace(Ko, ".");
3397
+ const r = u.split("."), c = ei(r, e).join(".");
3398
+ return n + c;
3395
3399
  }
3396
3400
  function Jt(u) {
3397
3401
  const e = [];
@@ -3400,8 +3404,8 @@ function Jt(u) {
3400
3404
  for (; t < n; ) {
3401
3405
  const r = u.charCodeAt(t++);
3402
3406
  if (r >= 55296 && r <= 56319 && t < n) {
3403
- const o = u.charCodeAt(t++);
3404
- (o & 64512) == 56320 ? e.push(((r & 1023) << 10) + (o & 1023) + 65536) : (e.push(r), t--);
3407
+ const c = u.charCodeAt(t++);
3408
+ (c & 64512) == 56320 ? e.push(((r & 1023) << 10) + (c & 1023) + 65536) : (e.push(r), t--);
3405
3409
  } else
3406
3410
  e.push(r);
3407
3411
  }
@@ -3409,74 +3413,74 @@ function Jt(u) {
3409
3413
  }
3410
3414
  const ti = (u) => String.fromCodePoint(...u), ni = function(u) {
3411
3415
  return u >= 48 && u < 58 ? 26 + (u - 48) : u >= 65 && u < 91 ? u - 65 : u >= 97 && u < 123 ? u - 97 : ou;
3412
- }, Ct = function(u, e) {
3416
+ }, At = function(u, e) {
3413
3417
  return u + 22 + 75 * (u < 26) - ((e != 0) << 5);
3414
3418
  }, Qt = function(u, e, t) {
3415
3419
  let n = 0;
3416
- for (u = t ? cu(u / Xc) : u >> 1, u += cu(u / e); u > e0 * ne >> 1; n += ou)
3417
- u = cu(u / e0);
3418
- return cu(n + (e0 + 1) * u / (u + Yc));
3420
+ for (u = t ? iu(u / Xo) : u >> 1, u += iu(u / e); u > e0 * te >> 1; n += ou)
3421
+ u = iu(u / e0);
3422
+ return iu(n + (e0 + 1) * u / (u + Yo));
3419
3423
  }, Kt = function(u) {
3420
3424
  const e = [], t = u.length;
3421
- let n = 0, r = Vt, o = Zt, i = u.lastIndexOf(Yt);
3425
+ let n = 0, r = Vt, c = Zt, i = u.lastIndexOf(Yt);
3422
3426
  i < 0 && (i = 0);
3423
- for (let c = 0; c < i; ++c)
3424
- u.charCodeAt(c) >= 128 && pu("not-basic"), e.push(u.charCodeAt(c));
3425
- for (let c = i > 0 ? i + 1 : 0; c < t; ) {
3427
+ for (let o = 0; o < i; ++o)
3428
+ u.charCodeAt(o) >= 128 && pu("not-basic"), e.push(u.charCodeAt(o));
3429
+ for (let o = i > 0 ? i + 1 : 0; o < t; ) {
3426
3430
  const a = n;
3427
3431
  for (let f = 1, d = ou; ; d += ou) {
3428
- c >= t && pu("invalid-input");
3429
- const m = ni(u.charCodeAt(c++));
3430
- m >= ou && pu("invalid-input"), m > cu((Pu - n) / f) && pu("overflow"), n += m * f;
3431
- const p = d <= o ? k0 : d >= o + ne ? ne : d - o;
3432
- if (m < p)
3432
+ o >= t && pu("invalid-input");
3433
+ const _ = ni(u.charCodeAt(o++));
3434
+ _ >= ou && pu("invalid-input"), _ > iu((Bu - n) / f) && pu("overflow"), n += _ * f;
3435
+ const b = d <= c ? k0 : d >= c + te ? te : d - c;
3436
+ if (_ < b)
3433
3437
  break;
3434
- const h = ou - p;
3435
- f > cu(Pu / h) && pu("overflow"), f *= h;
3438
+ const h = ou - b;
3439
+ f > iu(Bu / h) && pu("overflow"), f *= h;
3436
3440
  }
3437
3441
  const s = e.length + 1;
3438
- o = Qt(n - a, s, a == 0), cu(n / s) > Pu - r && pu("overflow"), r += cu(n / s), n %= s, e.splice(n++, 0, r);
3442
+ c = Qt(n - a, s, a == 0), iu(n / s) > Bu - r && pu("overflow"), r += iu(n / s), n %= s, e.splice(n++, 0, r);
3439
3443
  }
3440
3444
  return String.fromCodePoint(...e);
3441
3445
  }, un = function(u) {
3442
3446
  const e = [];
3443
3447
  u = Jt(u);
3444
3448
  const t = u.length;
3445
- let n = Vt, r = 0, o = Zt;
3449
+ let n = Vt, r = 0, c = Zt;
3446
3450
  for (const a of u)
3447
3451
  a < 128 && e.push(t0(a));
3448
3452
  const i = e.length;
3449
- let c = i;
3450
- for (i && e.push(Yt); c < t; ) {
3451
- let a = Pu;
3453
+ let o = i;
3454
+ for (i && e.push(Yt); o < t; ) {
3455
+ let a = Bu;
3452
3456
  for (const f of u)
3453
3457
  f >= n && f < a && (a = f);
3454
- const s = c + 1;
3455
- a - n > cu((Pu - r) / s) && pu("overflow"), r += (a - n) * s, n = a;
3458
+ const s = o + 1;
3459
+ a - n > iu((Bu - r) / s) && pu("overflow"), r += (a - n) * s, n = a;
3456
3460
  for (const f of u)
3457
- if (f < n && ++r > Pu && pu("overflow"), f === n) {
3461
+ if (f < n && ++r > Bu && pu("overflow"), f === n) {
3458
3462
  let d = r;
3459
- for (let m = ou; ; m += ou) {
3460
- const p = m <= o ? k0 : m >= o + ne ? ne : m - o;
3461
- if (d < p)
3463
+ for (let _ = ou; ; _ += ou) {
3464
+ const b = _ <= c ? k0 : _ >= c + te ? te : _ - c;
3465
+ if (d < b)
3462
3466
  break;
3463
- const h = d - p, C = ou - p;
3467
+ const h = d - b, C = ou - b;
3464
3468
  e.push(
3465
- t0(Ct(p + h % C, 0))
3466
- ), d = cu(h / C);
3469
+ t0(At(b + h % C, 0))
3470
+ ), d = iu(h / C);
3467
3471
  }
3468
- e.push(t0(Ct(d, 0))), o = Qt(r, s, c === i), r = 0, ++c;
3472
+ e.push(t0(At(d, 0))), c = Qt(r, s, o === i), r = 0, ++o;
3469
3473
  }
3470
3474
  ++r, ++n;
3471
3475
  }
3472
3476
  return e.join("");
3473
3477
  }, ri = function(u) {
3474
3478
  return Xt(u, function(e) {
3475
- return Jc.test(e) ? Kt(e.slice(4).toLowerCase()) : e;
3479
+ return Jo.test(e) ? Kt(e.slice(4).toLowerCase()) : e;
3476
3480
  });
3477
- }, oi = function(u) {
3481
+ }, ci = function(u) {
3478
3482
  return Xt(u, function(e) {
3479
- return Qc.test(e) ? "xn--" + un(e) : e;
3483
+ return Qo.test(e) ? "xn--" + un(e) : e;
3480
3484
  });
3481
3485
  }, en = {
3482
3486
  /**
@@ -3498,9 +3502,9 @@ const ti = (u) => String.fromCodePoint(...u), ni = function(u) {
3498
3502
  },
3499
3503
  decode: Kt,
3500
3504
  encode: un,
3501
- toASCII: oi,
3505
+ toASCII: ci,
3502
3506
  toUnicode: ri
3503
- }, ci = {
3507
+ }, oi = {
3504
3508
  options: {
3505
3509
  // Enable HTML tags in source
3506
3510
  html: !1,
@@ -3666,7 +3670,7 @@ const ti = (u) => String.fromCodePoint(...u), ni = function(u) {
3666
3670
  }
3667
3671
  }
3668
3672
  }, si = {
3669
- default: ci,
3673
+ default: oi,
3670
3674
  zero: ii,
3671
3675
  commonmark: ai
3672
3676
  }, li = /^(vbscript|javascript|file|data):/, fi = /^data:image\/(gif|png|jpeg|webp);/;
@@ -3676,16 +3680,16 @@ function di(u) {
3676
3680
  }
3677
3681
  const tn = ["http:", "https:", "mailto:"];
3678
3682
  function hi(u) {
3679
- const e = p0(u, !0);
3683
+ const e = b0(u, !0);
3680
3684
  if (e.hostname && (!e.protocol || tn.indexOf(e.protocol) >= 0))
3681
3685
  try {
3682
3686
  e.hostname = en.toASCII(e.hostname);
3683
3687
  } catch {
3684
3688
  }
3685
- return ie(h0(e));
3689
+ return oe(h0(e));
3686
3690
  }
3687
- function pi(u) {
3688
- const e = p0(u, !0);
3691
+ function bi(u) {
3692
+ const e = b0(u, !0);
3689
3693
  if (e.hostname && (!e.protocol || tn.indexOf(e.protocol) >= 0))
3690
3694
  try {
3691
3695
  e.hostname = en.toUnicode(e.hostname);
@@ -3696,14 +3700,14 @@ function pi(u) {
3696
3700
  function K(u, e) {
3697
3701
  if (!(this instanceof K))
3698
3702
  return new K(u, e);
3699
- e || m0(u) || (e = u || {}, u = "default"), this.inline = new se(), this.block = new ve(), this.core = new x0(), this.renderer = new Uu(), this.linkify = new J(), this.validateLink = di, this.normalizeLink = hi, this.normalizeLinkText = pi, this.utils = mo, this.helpers = Se({}, ko), this.options = {}, this.configure(u), e && this.set(e);
3703
+ e || _0(u) || (e = u || {}, u = "default"), this.inline = new ae(), this.block = new Se(), this.core = new x0(), this.renderer = new Uu(), this.linkify = new J(), this.validateLink = di, this.normalizeLink = hi, this.normalizeLinkText = bi, this.utils = pc, this.helpers = Fe({}, gc), this.options = {}, this.configure(u), e && this.set(e);
3700
3704
  }
3701
3705
  K.prototype.set = function(u) {
3702
- return Se(this.options, u), this;
3706
+ return Fe(this.options, u), this;
3703
3707
  };
3704
3708
  K.prototype.configure = function(u) {
3705
3709
  const e = this;
3706
- if (m0(u)) {
3710
+ if (_0(u)) {
3707
3711
  const t = u;
3708
3712
  if (u = si[t], !u)
3709
3713
  throw new Error('Wrong `markdown-it` preset "' + t + '", check name');
@@ -3758,7 +3762,7 @@ K.prototype.parseInline = function(u, e) {
3758
3762
  K.prototype.renderInline = function(u, e) {
3759
3763
  return e = e || {}, this.renderer.render(this.parseInline(u, e), this.options, e);
3760
3764
  };
3761
- class Mi extends f0 {
3765
+ class Ii extends f0 {
3762
3766
  constructor(t = {}) {
3763
3767
  super();
3764
3768
  Ou(this, "mdConfig");
@@ -3770,37 +3774,34 @@ class Mi extends f0 {
3770
3774
  }
3771
3775
  render(t) {
3772
3776
  const { content: n, ...r } = t;
3773
- let o = "";
3777
+ let c = "";
3774
3778
  try {
3775
- o = this.md.render(n ?? "");
3776
- } catch (c) {
3777
- console.error("Error rendering markdown:", c), o = n ?? "";
3779
+ c = this.md.render(n ?? "");
3780
+ } catch (o) {
3781
+ console.error("Error rendering markdown:", o), c = n ?? "";
3778
3782
  }
3779
3783
  if (this.sanitizeDisabled)
3780
- return console.warn("HTML sanitization is disabled, potential XSS risk"), Z0("div", { ...this.defaultAttrs, ...r, innerHTML: o });
3781
- const i = Sr.sanitize(o, this.dompurifyConfig);
3782
- return Z0("div", { ...this.defaultAttrs, ...r, innerHTML: i });
3784
+ return console.warn("HTML sanitization is disabled, potential XSS risk"), xu("div", { ...this.defaultAttrs, ...r, innerHTML: c });
3785
+ const i = Sr.sanitize(c, this.dompurifyConfig);
3786
+ return xu("div", { ...this.defaultAttrs, ...r, innerHTML: i });
3783
3787
  }
3784
3788
  }
3785
- const bi = {
3789
+ const pi = {
3786
3790
  key: 0,
3787
- class: /* @__PURE__ */ Au(["tr-bubble__avatar"])
3788
- }, mi = {
3789
- key: 2,
3790
- class: "tr-bubble__content-wrapper"
3791
+ class: /* @__PURE__ */ Cu(["tr-bubble__avatar"])
3791
3792
  }, _i = {
3792
3793
  key: 0,
3793
3794
  class: "tr-bubble__content-items"
3794
- }, xi = {
3795
+ }, mi = {
3795
3796
  key: 1,
3796
3797
  class: "tr-bubble__body-text"
3797
- }, gi = {
3798
+ }, xi = {
3798
3799
  key: 2,
3799
3800
  class: "tr-bubble__aborted"
3800
- }, ki = {
3801
+ }, gi = {
3801
3802
  key: 3,
3802
3803
  class: "tr-bubble__footer"
3803
- }, Ei = /* @__PURE__ */ yu({
3804
+ }, ki = /* @__PURE__ */ Fu({
3804
3805
  __name: "Bubble",
3805
3806
  props: {
3806
3807
  content: { default: "" },
@@ -3819,17 +3820,23 @@ const bi = {
3819
3820
  setup(u) {
3820
3821
  const e = u, t = kn(), n = X(() => {
3821
3822
  const d = e.contentRenderer;
3822
- return d ? typeof d == "function" ? { isComponent: !1, vNodeOrComponent: d(e) } : d instanceof f0 ? { isComponent: !1, vNodeOrComponent: d.render(e) } : { isComponent: !0, vNodeOrComponent: d } : null;
3823
- }), r = En(), o = X(() => {
3823
+ if (!d)
3824
+ return null;
3825
+ if (typeof d == "function") {
3826
+ const _ = d;
3827
+ return xu(() => _(e));
3828
+ }
3829
+ return d instanceof f0 ? xu(() => d.render(e)) : xu(d, e);
3830
+ }), r = En(), c = X(() => {
3824
3831
  if (!e.customContentField)
3825
3832
  return null;
3826
3833
  const d = r[e.customContentField];
3827
3834
  return typeof d == "string" || Array.isArray(d) && d.length > 0 ? d : null;
3828
- }), i = X(() => o.value || e.content), c = X(() => Array.isArray(i.value) ? "" : i.value), a = X(() => Array.isArray(i.value) ? i.value : []), s = X(() => e.placement === "start"), f = X(() => e.maxWidth ? {
3835
+ }), i = X(() => c.value || e.content), o = X(() => Array.isArray(i.value) ? "" : i.value), a = X(() => Array.isArray(i.value) ? i.value : []), s = X(() => e.placement === "start"), f = X(() => e.maxWidth ? {
3829
3836
  "--max-width": Tn(e.maxWidth)
3830
3837
  } : {});
3831
- return (d, m) => (S(), H("div", {
3832
- class: Au([
3838
+ return (d, _) => (v(), W("div", {
3839
+ class: Cu([
3833
3840
  "tr-bubble",
3834
3841
  {
3835
3842
  "placement-start": s.value,
@@ -3838,49 +3845,45 @@ const bi = {
3838
3845
  ]),
3839
3846
  style: An(f.value)
3840
3847
  }, [
3841
- e.avatar ? (S(), H("div", bi, [
3842
- (S(), eu(_u(e.avatar)))
3843
- ])) : Bu("", !0),
3844
- e.loading ? Qu(d.$slots, "loading", {
3848
+ e.avatar ? (v(), W("div", pi, [
3849
+ (v(), hu(Pu(e.avatar)))
3850
+ ])) : Qu("", !0),
3851
+ e.loading ? ke(d.$slots, "loading", {
3845
3852
  key: 1,
3846
3853
  bubbleProps: e
3847
3854
  }, () => [
3848
- Z("div", {
3849
- class: Au(["tr-bubble__content", { "border-corner": e.shape === "corner" }])
3850
- }, [...m[0] || (m[0] = [
3851
- Z("img", {
3855
+ Y("div", {
3856
+ class: Cu(["tr-bubble__content", { "border-corner": e.shape === "corner" }])
3857
+ }, [..._[0] || (_[0] = [
3858
+ Y("img", {
3852
3859
  src: Fn,
3853
3860
  alt: "loading",
3854
3861
  class: "tr-bubble__loading"
3855
3862
  }, null, -1)
3856
3863
  ])], 2)
3857
- ], !0) : (S(), H("div", mi, [
3858
- Z("div", {
3859
- class: Au(["tr-bubble__content", { "border-corner": e.shape === "corner" }])
3860
- }, [
3861
- a.value.length ? (S(), H("div", _i, [
3862
- (S(!0), H(De, null, Ee(a.value, (p, h) => (S(), eu(l0(cr), {
3863
- key: h,
3864
- item: p
3865
- }, null, 8, ["item"]))), 128))
3866
- ])) : Qu(d.$slots, "default", {
3867
- key: 1,
3868
- bubbleProps: e
3869
- }, () => [
3870
- n.value ? (S(), H(De, { key: 0 }, [
3871
- n.value.isComponent ? (S(), eu(_u(n.value.vNodeOrComponent), Ce(Ku({ key: 0 }, e)), null, 16)) : (S(), eu(_u(n.value.vNodeOrComponent), { key: 1 }))
3872
- ], 64)) : (S(), H("span", xi, Cu(c.value), 1))
3873
- ], !0),
3874
- e.aborted ? (S(), H("span", gi, Cu(e.abortedText), 1)) : Bu("", !0),
3875
- t.footer ? (S(), H("div", ki, [
3876
- Qu(d.$slots, "footer", { bubbleProps: e }, void 0, !0)
3877
- ])) : Bu("", !0)
3878
- ], 2),
3879
- Qu(d.$slots, "trailer", { bubbleProps: e }, void 0, !0)
3880
- ]))
3864
+ ], !0) : (v(), W("div", {
3865
+ key: 2,
3866
+ class: Cu(["tr-bubble__content", { "border-corner": e.shape === "corner" }])
3867
+ }, [
3868
+ a.value.length ? (v(), W("div", _i, [
3869
+ (v(!0), W(Dt, null, Ee(a.value, (b, h) => (v(), hu(l0(or), {
3870
+ key: h,
3871
+ item: b
3872
+ }, null, 8, ["item"]))), 128))
3873
+ ])) : ke(d.$slots, "default", {
3874
+ key: 1,
3875
+ bubbleProps: e
3876
+ }, () => [
3877
+ n.value ? (v(), hu(Pu(n.value), { key: 0 })) : (v(), W("span", mi, Du(o.value), 1))
3878
+ ], !0),
3879
+ e.aborted ? (v(), W("span", xi, Du(e.abortedText), 1)) : Qu("", !0),
3880
+ t.footer ? (v(), W("div", gi, [
3881
+ ke(d.$slots, "footer", { bubbleProps: e }, void 0, !0)
3882
+ ])) : Qu("", !0)
3883
+ ], 2))
3881
3884
  ], 6));
3882
3885
  }
3883
- }), Du = /* @__PURE__ */ ce(Ei, [["__scopeId", "data-v-cd2deda0"]]), Ai = /* @__PURE__ */ yu({
3886
+ }), yu = /* @__PURE__ */ ce(ki, [["__scopeId", "data-v-6c781ef4"]]), Ei = /* @__PURE__ */ Fu({
3884
3887
  __name: "BubbleList",
3885
3888
  props: {
3886
3889
  items: {},
@@ -3893,7 +3896,7 @@ const bi = {
3893
3896
  const e = u, t = s0(null), { y: n } = Mn(t, {
3894
3897
  behavior: "smooth",
3895
3898
  throttle: 100
3896
- }), r = X(() => e.items.at(-1)), o = X(() => {
3899
+ }), r = X(() => e.items.at(-1)), c = X(() => {
3897
3900
  var f, d;
3898
3901
  if (!r.value)
3899
3902
  return 0;
@@ -3902,10 +3905,10 @@ const bi = {
3902
3905
  return 0;
3903
3906
  const s = r.value;
3904
3907
  if (Array.isArray(s[a])) {
3905
- const m = s[a].at(-1);
3906
- if (m && typeof m == "object" && "content" in m)
3908
+ const _ = s[a].at(-1);
3909
+ if (_ && typeof _ == "object" && "content" in _)
3907
3910
  try {
3908
- return JSON.stringify(m.content).length;
3911
+ return JSON.stringify(_.content).length;
3909
3912
  } catch {
3910
3913
  }
3911
3914
  return s[a].length;
@@ -3915,7 +3918,7 @@ const bi = {
3915
3918
  Cn(
3916
3919
  () => {
3917
3920
  var a;
3918
- return [e.autoScroll, e.items.length, (a = r.value) == null ? void 0 : a.content, o.value];
3921
+ return [e.autoScroll, e.items.length, (a = r.value) == null ? void 0 : a.content, c.value];
3919
3922
  },
3920
3923
  ([a]) => {
3921
3924
  Dn(() => {
@@ -3924,54 +3927,50 @@ const bi = {
3924
3927
  },
3925
3928
  { deep: !0 }
3926
3929
  );
3927
- const i = X(() => e.items.map((a, s) => {
3928
- var D;
3929
- const f = a.role ? ((D = e.roles) == null ? void 0 : D[a.role]) || {} : {}, { slots: d, hidden: m, ...p } = f, { slots: h, ...C } = a;
3930
+ const i = X(() => e.items.map((a) => {
3931
+ var C;
3932
+ const s = a.role ? ((C = e.roles) == null ? void 0 : C[a.role]) || {} : {};
3933
+ if (s.hidden)
3934
+ return null;
3935
+ const { slots: f, hidden: d, ..._ } = s, { slots: b, ...h } = a;
3930
3936
  return {
3931
3937
  id: a.id,
3932
- index: s,
3933
- hidden: !!m,
3934
- props: { ...p, ...C, "data-role": a.role },
3935
- slots: { ...d, ...h }
3938
+ props: { ..._, ...h, "data-role": a.role },
3939
+ slots: { ...f, ...b }
3936
3940
  };
3937
- })), c = X(() => {
3941
+ }).filter((a) => !!a)), o = X(() => {
3938
3942
  var f;
3939
3943
  if (!(e.loading && e.loadingRole && ((f = e.roles) != null && f[e.loadingRole])))
3940
3944
  return null;
3941
3945
  const { slots: a, ...s } = e.roles[e.loadingRole];
3942
3946
  return { props: { ...s, loading: !0 }, slots: a };
3943
3947
  });
3944
- return (a, s) => (S(), H("div", {
3948
+ return (a, s) => (v(), W("div", {
3945
3949
  class: "tr-bubble-list",
3946
3950
  ref_key: "scrollContainerRef",
3947
3951
  ref: t
3948
3952
  }, [
3949
- (S(!0), H(De, null, Ee(i.value, (f, d) => (S(), H(De, {
3953
+ (v(!0), W(Dt, null, Ee(i.value, (f, d) => (v(), hu(yu, $e({
3950
3954
  key: f.id || d
3951
- }, [
3952
- f.hidden ? Bu("", !0) : (S(), eu(Du, Ku({
3953
- key: 0,
3954
- ref_for: !0
3955
- }, f.props), V0({ _: 2 }, [
3956
- Ee(f.slots, (m, p) => ({
3957
- name: p,
3958
- fn: Y0((h) => [
3959
- (S(), eu(_u(m), Ku({ ref_for: !0 }, { ...h, index: f.index }), null, 16))
3960
- ])
3961
- }))
3962
- ]), 1040))
3963
- ], 64))), 128)),
3964
- c.value ? (S(), eu(Du, Ce(Ku({ key: 0 }, c.value.props)), V0({ _: 2 }, [
3965
- Ee(c.value.slots, (f, d) => ({
3955
+ }, { ref_for: !0 }, f.props), W0({ _: 2 }, [
3956
+ Ee(f.slots, (_, b) => ({
3957
+ name: b,
3958
+ fn: Z0((h) => [
3959
+ (v(), hu(Pu(_), $e({ ref_for: !0 }, h), null, 16))
3960
+ ])
3961
+ }))
3962
+ ]), 1040))), 128)),
3963
+ o.value ? (v(), hu(yu, V0($e({ key: 0 }, o.value.props)), W0({ _: 2 }, [
3964
+ Ee(o.value.slots, (f, d) => ({
3966
3965
  name: d,
3967
- fn: Y0((m) => [
3968
- (S(), eu(_u(f), Ce(yn(m)), null, 16))
3966
+ fn: Z0((_) => [
3967
+ (v(), hu(Pu(f), V0(yn(_)), null, 16))
3969
3968
  ])
3970
3969
  }))
3971
- ]), 1040)) : Bu("", !0)
3970
+ ]), 1040)) : Qu("", !0)
3972
3971
  ], 512));
3973
3972
  }
3974
- }), re = /* @__PURE__ */ ce(Ai, [["__scopeId", "data-v-4cbc6c09"]]), oe = /* @__PURE__ */ yu({
3973
+ }), ne = /* @__PURE__ */ ce(Ei, [["__scopeId", "data-v-a5afaa8b"]]), re = /* @__PURE__ */ Fu({
3975
3974
  __name: "BubbleProvider",
3976
3975
  props: {
3977
3976
  contentRenderers: { default: () => ({}) }
@@ -3982,31 +3981,31 @@ const bi = {
3982
3981
  t.set(n, r);
3983
3982
  for (const [n, r] of Object.entries(e.contentRenderers))
3984
3983
  t.set(n, r);
3985
- return X0(Ft, t), X0(Tt, d0), (n, r) => Qu(n.$slots, "default");
3984
+ return Y0(Ft, t), Y0(Tt, d0), (n, r) => ke(n.$slots, "default");
3986
3985
  }
3987
3986
  });
3988
- Du.name = "TrBubble";
3987
+ yu.name = "TrBubble";
3988
+ const Ai = function(u) {
3989
+ u.component(yu.name, yu);
3990
+ };
3991
+ yu.install = Ai;
3992
+ const Mi = yu;
3993
+ ne.name = "TrBubbleList";
3989
3994
  const Ci = function(u) {
3990
- u.component(Du.name, Du);
3995
+ u.component(ne.name, ne);
3991
3996
  };
3992
- Du.install = Ci;
3993
- const Li = Du;
3994
- re.name = "TrBubbleList";
3997
+ ne.install = Ci;
3998
+ const Li = ne;
3999
+ re.name = "TrBubbleProvider";
3995
4000
  const Di = function(u) {
3996
4001
  u.component(re.name, re);
3997
4002
  };
3998
4003
  re.install = Di;
3999
4004
  const Oi = re;
4000
- oe.name = "TrBubbleProvider";
4001
- const yi = function(u) {
4002
- u.component(oe.name, oe);
4003
- };
4004
- oe.install = yi;
4005
- const Ni = oe;
4006
4005
  export {
4007
- Li as Bubble,
4006
+ Mi as Bubble,
4008
4007
  f0 as BubbleContentClassRenderer,
4009
- Oi as BubbleList,
4010
- Mi as BubbleMarkdownContentRenderer,
4011
- Ni as BubbleProvider
4008
+ Li as BubbleList,
4009
+ Ii as BubbleMarkdownContentRenderer,
4010
+ Oi as BubbleProvider
4012
4011
  };