@powerlines/plugin-marked 0.1.236 → 0.1.237

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,8 +1,8 @@
1
1
 
2
- //#region ../../node_modules/.pnpm/marked@17.0.1/node_modules/marked/lib/marked.esm.js
2
+ //#region ../../node_modules/.pnpm/marked@17.0.2/node_modules/marked/lib/marked.esm.js
3
3
  /**
4
- * marked v17.0.1 - a markdown parser
5
- * Copyright (c) 2018-2025, MarkedJS. (MIT License)
4
+ * marked v17.0.2 - a markdown parser
5
+ * Copyright (c) 2018-2026, MarkedJS. (MIT License)
6
6
  * Copyright (c) 2011-2018, Christopher Jeffrey. (MIT License)
7
7
  * https://github.com/markedjs/marked
8
8
  */
@@ -10,7 +10,7 @@
10
10
  * DO NOT EDIT THIS FILE
11
11
  * The code in this file is generated from files in ./src/
12
12
  */
13
- function L() {
13
+ function M() {
14
14
  return {
15
15
  async: !1,
16
16
  breaks: !1,
@@ -24,11 +24,11 @@ function L() {
24
24
  walkTokens: null
25
25
  };
26
26
  }
27
- var T = L();
28
- function Z(u) {
27
+ var T = M();
28
+ function H(u) {
29
29
  T = u;
30
30
  }
31
- var C = { exec: () => null };
31
+ var _ = { exec: () => null };
32
32
  function k(u, e = "") {
33
33
  let t = typeof u == "string" ? u : u.source, n = {
34
34
  replace: (r, i) => {
@@ -39,7 +39,7 @@ function k(u, e = "") {
39
39
  };
40
40
  return n;
41
41
  }
42
- var me = (() => {
42
+ var Re = (() => {
43
43
  try {
44
44
  return true;
45
45
  } catch {
@@ -62,7 +62,6 @@ var me = (() => {
62
62
  blockquoteStart: /^ {0,3}>/,
63
63
  blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
64
64
  blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
65
- listReplaceTabs: /^\t+/,
66
65
  listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
67
66
  listIsTask: /^\[[ xX]\] +\S/,
68
67
  listReplaceTask: /^\[[ xX]\] +/,
@@ -102,92 +101,97 @@ var me = (() => {
102
101
  hrRegex: (u) => /* @__PURE__ */ new RegExp(`^ {0,${Math.min(3, u - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),
103
102
  fencesBeginRegex: (u) => /* @__PURE__ */ new RegExp(`^ {0,${Math.min(3, u - 1)}}(?:\`\`\`|~~~)`),
104
103
  headingBeginRegex: (u) => /* @__PURE__ */ new RegExp(`^ {0,${Math.min(3, u - 1)}}#`),
105
- htmlBeginRegex: (u) => new RegExp(`^ {0,${Math.min(3, u - 1)}}<(?:[a-z].*>|!--)`, "i")
106
- }, xe = /^(?:[ \t]*(?:\n|$))+/, be = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, Re = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, I = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, Te = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, N = /(?:[*+-]|\d{1,9}[.)])/, re = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, se = k(re).replace(/bull/g, N).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), Oe = k(re).replace(/bull/g, N).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), Q = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, we = /^[^\n]+/, F = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, ye = k(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", F).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Pe = k(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, N).getRegex(), v = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", j = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, Se = k("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", j).replace("tag", v).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ie = k(Q).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), U = {
104
+ htmlBeginRegex: (u) => new RegExp(`^ {0,${Math.min(3, u - 1)}}<(?:[a-z].*>|!--)`, "i"),
105
+ blockquoteBeginRegex: (u) => /* @__PURE__ */ new RegExp(`^ {0,${Math.min(3, u - 1)}}>`)
106
+ }, Te = /^(?:[ \t]*(?:\n|$))+/, Oe = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, we = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, I = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, ye = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, N = / {0,3}(?:[*+-]|\d{1,9}[.)])/, re = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, se = k(re).replace(/bull/g, N).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), Pe = k(re).replace(/bull/g, N).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), Q = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, Se = /^[^\n]+/, F = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, $e = k(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", F).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), _e = k(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, N).getRegex(), q = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", j = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, Le = k("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", j).replace("tag", q).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ie = k(Q).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", q).getRegex(), U = {
107
107
  blockquote: k(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ie).getRegex(),
108
- code: be,
109
- def: ye,
110
- fences: Re,
111
- heading: Te,
108
+ code: Oe,
109
+ def: $e,
110
+ fences: we,
111
+ heading: ye,
112
112
  hr: I,
113
- html: Se,
113
+ html: Le,
114
114
  lheading: se,
115
- list: Pe,
116
- newline: xe,
115
+ list: _e,
116
+ newline: Te,
117
117
  paragraph: ie,
118
- table: C,
119
- text: we
120
- }, te = k("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), _e = {
118
+ table: _,
119
+ text: Se
120
+ }, te = k("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", q).getRegex(), ze = {
121
121
  ...U,
122
- lheading: Oe,
122
+ lheading: Pe,
123
123
  table: te,
124
- paragraph: k(Q).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", te).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex()
125
- }, Le = {
124
+ paragraph: k(Q).replace("hr", I).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", te).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", q).getRegex()
125
+ }, Ce = {
126
126
  ...U,
127
127
  html: k(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", j).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
128
128
  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
129
129
  heading: /^(#{1,6})(.*)(?:\n+|$)/,
130
- fences: C,
130
+ fences: _,
131
131
  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
132
132
  paragraph: k(Q).replace("hr", I).replace("heading", ` *#{1,6} *[^
133
133
  ]`).replace("lheading", se).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
134
- }, Me = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, ze = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, oe = /^( {2,}|\\)\n(?!\s*$)/, Ae = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, D = /[\p{P}\p{S}]/u, K = /[\s\p{P}\p{S}]/u, ae = /[^\s\p{P}\p{S}]/u, Ce = k(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, K).getRegex(), le = /(?!~)[\p{P}\p{S}]/u, Ie = /(?!~)[\s\p{P}\p{S}]/u, Ee = /(?:[^\s\p{P}\p{S}]|~)/u, Be = k(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", me ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), ue = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, qe = k(ue, "u").replace(/punct/g, D).getRegex(), ve = k(ue, "u").replace(/punct/g, le).getRegex(), pe = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", De = k(pe, "gu").replace(/notPunctSpace/g, ae).replace(/punctSpace/g, K).replace(/punct/g, D).getRegex(), He = k(pe, "gu").replace(/notPunctSpace/g, Ee).replace(/punctSpace/g, Ie).replace(/punct/g, le).getRegex(), Ze = k("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, ae).replace(/punctSpace/g, K).replace(/punct/g, D).getRegex(), Ge = k(/\\(punct)/, "gu").replace(/punct/g, D).getRegex(), Ne = k(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), Qe = k(j).replace("(?:-->|$)", "-->").getRegex(), Fe = k("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", Qe).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), q = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/, je = k(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", q).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), ce = k(/^!?\[(label)\]\[(ref)\]/).replace("label", q).replace("ref", F).getRegex(), he = k(/^!?\[(ref)\](?:\[\])?/).replace("ref", F).getRegex(), Ue = k("reflink|nolink(?!\\()", "g").replace("reflink", ce).replace("nolink", he).getRegex(), ne = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, W = {
135
- _backpedal: C,
136
- anyPunctuation: Ge,
137
- autolink: Ne,
138
- blockSkip: Be,
134
+ }, Ae = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, Ie = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, oe = /^( {2,}|\\)\n(?!\s*$)/, Ee = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, v = /[\p{P}\p{S}]/u, K = /[\s\p{P}\p{S}]/u, ae = /[^\s\p{P}\p{S}]/u, Be = k(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, K).getRegex(), le = /(?!~)[\p{P}\p{S}]/u, De = /(?!~)[\s\p{P}\p{S}]/u, qe = /(?:[^\s\p{P}\p{S}]|~)/u, ue = /(?![*_])[\p{P}\p{S}]/u, ve = /(?![*_])[\s\p{P}\p{S}]/u, Ge = /(?:[^\s\p{P}\p{S}]|[*_])/u, He = k(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", Re ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), pe = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, Ze = k(pe, "u").replace(/punct/g, v).getRegex(), Ne = k(pe, "u").replace(/punct/g, le).getRegex(), ce = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", Qe = k(ce, "gu").replace(/notPunctSpace/g, ae).replace(/punctSpace/g, K).replace(/punct/g, v).getRegex(), Fe = k(ce, "gu").replace(/notPunctSpace/g, qe).replace(/punctSpace/g, De).replace(/punct/g, le).getRegex(), je = k("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, ae).replace(/punctSpace/g, K).replace(/punct/g, v).getRegex(), Ue = k(/^~~?(?:((?!~)punct)|[^\s~])/, "u").replace(/punct/g, ue).getRegex(), We = k("^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)", "gu").replace(/notPunctSpace/g, Ge).replace(/punctSpace/g, ve).replace(/punct/g, ue).getRegex(), Xe = k(/\\(punct)/, "gu").replace(/punct/g, v).getRegex(), Je = k(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), Ve = k(j).replace("(?:-->|$)", "-->").getRegex(), Ye = k("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", Ve).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), D = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/, et = k(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", D).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), he = k(/^!?\[(label)\]\[(ref)\]/).replace("label", D).replace("ref", F).getRegex(), ke = k(/^!?\[(ref)\](?:\[\])?/).replace("ref", F).getRegex(), tt = k("reflink|nolink(?!\\()", "g").replace("reflink", he).replace("nolink", ke).getRegex(), ne = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, W = {
135
+ _backpedal: _,
136
+ anyPunctuation: Xe,
137
+ autolink: Je,
138
+ blockSkip: He,
139
139
  br: oe,
140
- code: ze,
141
- del: C,
142
- emStrongLDelim: qe,
143
- emStrongRDelimAst: De,
144
- emStrongRDelimUnd: Ze,
145
- escape: Me,
146
- link: je,
147
- nolink: he,
148
- punctuation: Ce,
149
- reflink: ce,
150
- reflinkSearch: Ue,
151
- tag: Fe,
152
- text: Ae,
153
- url: C
154
- }, Ke = {
140
+ code: Ie,
141
+ del: _,
142
+ delLDelim: _,
143
+ delRDelim: _,
144
+ emStrongLDelim: Ze,
145
+ emStrongRDelimAst: Qe,
146
+ emStrongRDelimUnd: je,
147
+ escape: Ae,
148
+ link: et,
149
+ nolink: ke,
150
+ punctuation: Be,
151
+ reflink: he,
152
+ reflinkSearch: tt,
153
+ tag: Ye,
154
+ text: Ee,
155
+ url: _
156
+ }, nt = {
155
157
  ...W,
156
- link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", q).getRegex(),
157
- reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", q).getRegex()
158
- }, G = {
158
+ link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", D).getRegex(),
159
+ reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", D).getRegex()
160
+ }, Z = {
159
161
  ...W,
160
- emStrongRDelimAst: He,
161
- emStrongLDelim: ve,
162
+ emStrongRDelimAst: Fe,
163
+ emStrongLDelim: Ne,
164
+ delLDelim: Ue,
165
+ delRDelim: We,
162
166
  url: k(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", ne).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
163
167
  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
164
168
  del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
165
169
  text: k(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", ne).getRegex()
166
- }, We = {
167
- ...G,
170
+ }, rt = {
171
+ ...Z,
168
172
  br: k(oe).replace("{2,}", "*").getRegex(),
169
- text: k(G.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
173
+ text: k(Z.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
170
174
  }, E = {
171
175
  normal: U,
172
- gfm: _e,
173
- pedantic: Le
174
- }, M = {
176
+ gfm: ze,
177
+ pedantic: Ce
178
+ }, z = {
175
179
  normal: W,
176
- gfm: G,
177
- breaks: We,
178
- pedantic: Ke
180
+ gfm: Z,
181
+ breaks: rt,
182
+ pedantic: nt
179
183
  };
180
- var Xe = {
184
+ var st = {
181
185
  "&": "&amp;",
182
186
  "<": "&lt;",
183
187
  ">": "&gt;",
184
188
  "\"": "&quot;",
185
189
  "'": "&#39;"
186
- }, ke = (u) => Xe[u];
187
- function w(u, e) {
190
+ }, de = (u) => st[u];
191
+ function O(u, e) {
188
192
  if (e) {
189
- if (m.escapeTest.test(u)) return u.replace(m.escapeReplace, ke);
190
- } else if (m.escapeTestNoEncode.test(u)) return u.replace(m.escapeReplaceNoEncode, ke);
193
+ if (m.escapeTest.test(u)) return u.replace(m.escapeReplace, de);
194
+ } else if (m.escapeTestNoEncode.test(u)) return u.replace(m.escapeReplaceNoEncode, de);
191
195
  return u;
192
196
  }
193
197
  function X(u) {
@@ -209,7 +213,7 @@ function J(u, e) {
209
213
  for (; r < n.length; r++) n[r] = n[r].trim().replace(m.slashPipe, "|");
210
214
  return n;
211
215
  }
212
- function z(u, e, t) {
216
+ function C(u, e, t) {
213
217
  let n = u.length;
214
218
  if (n === 0) return "";
215
219
  let r = 0;
@@ -221,7 +225,7 @@ function z(u, e, t) {
221
225
  }
222
226
  return u.slice(0, n - r);
223
227
  }
224
- function de(u, e) {
228
+ function ge(u, e) {
225
229
  if (u.indexOf(e[1]) === -1) return -1;
226
230
  let t = 0;
227
231
  for (let n = 0; n < u.length; n++) if (u[n] === "\\") n++;
@@ -229,7 +233,15 @@ function de(u, e) {
229
233
  else if (u[n] === e[1] && (t--, t < 0)) return n;
230
234
  return t > 0 ? -2 : -1;
231
235
  }
232
- function ge(u, e, t, n, r) {
236
+ function fe(u, e = 0) {
237
+ let t = e, n = "";
238
+ for (let r of u) if (r === " ") {
239
+ let i = 4 - t % 4;
240
+ n += " ".repeat(i), t += i;
241
+ } else n += r, t++;
242
+ return n;
243
+ }
244
+ function me(u, e, t, n, r) {
233
245
  let i = e.href, s = e.title || null, a = u[1].replace(r.other.outputLinkReplace, "$1");
234
246
  n.state.inLink = !0;
235
247
  let o = {
@@ -242,7 +254,7 @@ function ge(u, e, t, n, r) {
242
254
  };
243
255
  return n.state.inLink = !1, o;
244
256
  }
245
- function Je(u, e, t) {
257
+ function it(u, e, t) {
246
258
  let n = u.match(t.other.indentCodeCompensation);
247
259
  if (n === null) return e;
248
260
  let r = n[1];
@@ -255,7 +267,7 @@ function Je(u, e, t) {
255
267
  }).join(`
256
268
  `);
257
269
  }
258
- var y = class {
270
+ var w = class {
259
271
  options;
260
272
  rules;
261
273
  lexer;
@@ -277,7 +289,7 @@ var y = class {
277
289
  type: "code",
278
290
  raw: t[0],
279
291
  codeBlockStyle: "indented",
280
- text: this.options.pedantic ? n : z(n, `
292
+ text: this.options.pedantic ? n : C(n, `
281
293
  `)
282
294
  };
283
295
  }
@@ -285,7 +297,7 @@ var y = class {
285
297
  fences(e) {
286
298
  let t = this.rules.block.fences.exec(e);
287
299
  if (t) {
288
- let n = t[0], r = Je(n, t[3] || "", this.rules);
300
+ let n = t[0], r = it(n, t[3] || "", this.rules);
289
301
  return {
290
302
  type: "code",
291
303
  raw: n,
@@ -299,7 +311,7 @@ var y = class {
299
311
  if (t) {
300
312
  let n = t[2].trim();
301
313
  if (this.rules.other.endingHash.test(n)) {
302
- let r = z(n, "#");
314
+ let r = C(n, "#");
303
315
  (this.options.pedantic || !r || this.rules.other.endingSpaceChar.test(r)) && (n = r.trim());
304
316
  }
305
317
  return {
@@ -315,14 +327,14 @@ var y = class {
315
327
  let t = this.rules.block.hr.exec(e);
316
328
  if (t) return {
317
329
  type: "hr",
318
- raw: z(t[0], `
330
+ raw: C(t[0], `
319
331
  `)
320
332
  };
321
333
  }
322
334
  blockquote(e) {
323
335
  let t = this.rules.block.blockquote.exec(e);
324
336
  if (t) {
325
- let n = z(t[0], `
337
+ let n = C(t[0], `
326
338
  `).split(`
327
339
  `), r = "", i = "", s = [];
328
340
  for (; n.length > 0;) {
@@ -337,21 +349,21 @@ var y = class {
337
349
  r = r ? `${r}
338
350
  ${p}` : p, i = i ? `${i}
339
351
  ${c}` : c;
340
- let g = this.lexer.state.top;
341
- if (this.lexer.state.top = !0, this.lexer.blockTokens(c, s, !0), this.lexer.state.top = g, n.length === 0) break;
352
+ let d = this.lexer.state.top;
353
+ if (this.lexer.state.top = !0, this.lexer.blockTokens(c, s, !0), this.lexer.state.top = d, n.length === 0) break;
342
354
  let h = s.at(-1);
343
355
  if (h?.type === "code") break;
344
356
  if (h?.type === "blockquote") {
345
357
  let R = h, f = R.raw + `
346
358
  ` + n.join(`
347
- `), O = this.blockquote(f);
348
- s[s.length - 1] = O, r = r.substring(0, r.length - R.raw.length) + O.raw, i = i.substring(0, i.length - R.text.length) + O.text;
359
+ `), S = this.blockquote(f);
360
+ s[s.length - 1] = S, r = r.substring(0, r.length - R.raw.length) + S.raw, i = i.substring(0, i.length - R.text.length) + S.text;
349
361
  break;
350
362
  } else if (h?.type === "list") {
351
363
  let R = h, f = R.raw + `
352
364
  ` + n.join(`
353
- `), O = this.list(f);
354
- s[s.length - 1] = O, r = r.substring(0, r.length - h.raw.length) + O.raw, i = i.substring(0, i.length - R.raw.length) + O.raw, n = f.substring(s.at(-1).raw.length).split(`
365
+ `), S = this.list(f);
366
+ s[s.length - 1] = S, r = r.substring(0, r.length - h.raw.length) + S.raw, i = i.substring(0, i.length - R.raw.length) + S.raw, n = f.substring(s.at(-1).raw.length).split(`
355
367
  `);
356
368
  continue;
357
369
  }
@@ -381,25 +393,25 @@ ${c}` : c;
381
393
  let l = !1, p = "", c = "";
382
394
  if (!(t = s.exec(e)) || this.rules.block.hr.test(e)) break;
383
395
  p = t[0], e = e.substring(p.length);
384
- let g = t[2].split(`
385
- `, 1)[0].replace(this.rules.other.listReplaceTabs, (O) => " ".repeat(3 * O.length)), h = e.split(`
386
- `, 1)[0], R = !g.trim(), f = 0;
387
- if (this.options.pedantic ? (f = 2, c = g.trimStart()) : R ? f = t[1].length + 1 : (f = t[2].search(this.rules.other.nonSpaceChar), f = f > 4 ? 1 : f, c = g.slice(f), f += t[1].length), R && this.rules.other.blankLine.test(h) && (p += h + `
396
+ let d = fe(t[2].split(`
397
+ `, 1)[0], t[1].length), h = e.split(`
398
+ `, 1)[0], R = !d.trim(), f = 0;
399
+ if (this.options.pedantic ? (f = 2, c = d.trimStart()) : R ? f = t[1].length + 1 : (f = d.search(this.rules.other.nonSpaceChar), f = f > 4 ? 1 : f, c = d.slice(f), f += t[1].length), R && this.rules.other.blankLine.test(h) && (p += h + `
388
400
  `, e = e.substring(h.length + 1), l = !0), !l) {
389
- let O = this.rules.other.nextBulletRegex(f), V = this.rules.other.hrRegex(f), Y = this.rules.other.fencesBeginRegex(f), ee = this.rules.other.headingBeginRegex(f), fe = this.rules.other.htmlBeginRegex(f);
401
+ let S = this.rules.other.nextBulletRegex(f), V = this.rules.other.hrRegex(f), Y = this.rules.other.fencesBeginRegex(f), ee = this.rules.other.headingBeginRegex(f), xe = this.rules.other.htmlBeginRegex(f), be = this.rules.other.blockquoteBeginRegex(f);
390
402
  for (; e;) {
391
- let H = e.split(`
403
+ let G = e.split(`
392
404
  `, 1)[0], A;
393
- if (h = H, this.options.pedantic ? (h = h.replace(this.rules.other.listReplaceNesting, " "), A = h) : A = h.replace(this.rules.other.tabCharGlobal, " "), Y.test(h) || ee.test(h) || fe.test(h) || O.test(h) || V.test(h)) break;
405
+ if (h = G, this.options.pedantic ? (h = h.replace(this.rules.other.listReplaceNesting, " "), A = h) : A = h.replace(this.rules.other.tabCharGlobal, " "), Y.test(h) || ee.test(h) || xe.test(h) || be.test(h) || S.test(h) || V.test(h)) break;
394
406
  if (A.search(this.rules.other.nonSpaceChar) >= f || !h.trim()) c += `
395
407
  ` + A.slice(f);
396
408
  else {
397
- if (R || g.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || Y.test(g) || ee.test(g) || V.test(g)) break;
409
+ if (R || d.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || Y.test(d) || ee.test(d) || V.test(d)) break;
398
410
  c += `
399
411
  ` + h;
400
412
  }
401
- !R && !h.trim() && (R = !0), p += H + `
402
- `, e = e.substring(H.length + 1), g = A.slice(f);
413
+ R = !h.trim(), p += G + `
414
+ `, e = e.substring(G.length + 1), d = A.slice(f);
403
415
  }
404
416
  }
405
417
  i.loose || (a ? i.loose = !0 : this.rules.other.doubleBlankLine.test(p) && (a = !0)), i.items.push({
@@ -440,8 +452,8 @@ ${c}` : c;
440
452
  }
441
453
  }
442
454
  if (!i.loose) {
443
- let p = l.tokens.filter((g) => g.type === "space");
444
- i.loose = p.length > 0 && p.some((g) => this.rules.other.anyLine.test(g.raw));
455
+ let p = l.tokens.filter((d) => d.type === "space");
456
+ i.loose = p.length > 0 && p.some((d) => this.rules.other.anyLine.test(d.raw));
445
457
  }
446
458
  }
447
459
  if (i.loose) for (let l of i.items) {
@@ -559,10 +571,10 @@ ${c}` : c;
559
571
  let n = t[2].trim();
560
572
  if (!this.options.pedantic && this.rules.other.startAngleBracket.test(n)) {
561
573
  if (!this.rules.other.endAngleBracket.test(n)) return;
562
- let s = z(n.slice(0, -1), "\\");
574
+ let s = C(n.slice(0, -1), "\\");
563
575
  if ((n.length - s.length) % 2 === 0) return;
564
576
  } else {
565
- let s = de(t[2], "()");
577
+ let s = ge(t[2], "()");
566
578
  if (s === -2) return;
567
579
  if (s > -1) {
568
580
  let o = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + s;
@@ -574,7 +586,7 @@ ${c}` : c;
574
586
  let s = this.rules.other.pedanticHrefTitle.exec(r);
575
587
  s && (r = s[1], i = s[3]);
576
588
  } else i = t[3] ? t[3].slice(1, -1) : "";
577
- return r = r.trim(), this.rules.other.startAngleBracket.test(r) && (this.options.pedantic && !this.rules.other.endAngleBracket.test(n) ? r = r.slice(1) : r = r.slice(1, -1)), ge(t, {
589
+ return r = r.trim(), this.rules.other.startAngleBracket.test(r) && (this.options.pedantic && !this.rules.other.endAngleBracket.test(n) ? r = r.slice(1) : r = r.slice(1, -1)), me(t, {
578
590
  href: r && r.replace(this.rules.inline.anyPunctuation, "$1"),
579
591
  title: i && i.replace(this.rules.inline.anyPunctuation, "$1")
580
592
  }, t[0], this.lexer, this.rules);
@@ -592,7 +604,7 @@ ${c}` : c;
592
604
  text: s
593
605
  };
594
606
  }
595
- return ge(n, i, n[0], this.lexer, this.rules);
607
+ return me(n, i, n[0], this.lexer, this.rules);
596
608
  }
597
609
  }
598
610
  emStrong(e, t, n = "") {
@@ -611,7 +623,7 @@ ${c}` : c;
611
623
  }
612
624
  if (l -= o, l > 0) continue;
613
625
  o = Math.min(o, o + l + p);
614
- let g = [...r[0]][0].length, h = e.slice(0, s + r.index + g + o);
626
+ let d = [...r[0]][0].length, h = e.slice(0, s + r.index + d + o);
615
627
  if (Math.min(s, o) % 2) {
616
628
  let f = h.slice(1, -1);
617
629
  return {
@@ -649,14 +661,28 @@ ${c}` : c;
649
661
  raw: t[0]
650
662
  };
651
663
  }
652
- del(e) {
653
- let t = this.rules.inline.del.exec(e);
654
- if (t) return {
655
- type: "del",
656
- raw: t[0],
657
- text: t[2],
658
- tokens: this.lexer.inlineTokens(t[2])
659
- };
664
+ del(e, t, n = "") {
665
+ let r = this.rules.inline.delLDelim.exec(e);
666
+ if (!r) return;
667
+ if (!(r[1] || "") || !n || this.rules.inline.punctuation.exec(n)) {
668
+ let s = [...r[0]].length - 1, a, o, l = s, p = this.rules.inline.delRDelim;
669
+ for (p.lastIndex = 0, t = t.slice(-1 * e.length + s); (r = p.exec(t)) != null;) {
670
+ if (a = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !a || (o = [...a].length, o !== s)) continue;
671
+ if (r[3] || r[4]) {
672
+ l += o;
673
+ continue;
674
+ }
675
+ if (l -= o, l > 0) continue;
676
+ o = Math.min(o, o + l);
677
+ let c = [...r[0]][0].length, d = e.slice(0, s + r.index + c + o), h = d.slice(s, -s);
678
+ return {
679
+ type: "del",
680
+ raw: d,
681
+ text: h,
682
+ tokens: this.lexer.inlineTokens(h)
683
+ };
684
+ }
685
+ }
660
686
  }
661
687
  autolink(e) {
662
688
  let t = this.rules.inline.autolink.exec(e);
@@ -720,7 +746,7 @@ var x = class u {
720
746
  inlineQueue;
721
747
  tokenizer;
722
748
  constructor(e) {
723
- this.tokens = [], this.tokens.links = Object.create(null), this.options = e || T, this.options.tokenizer = this.options.tokenizer || new y(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
749
+ this.tokens = [], this.tokens.links = Object.create(null), this.options = e || T, this.options.tokenizer = this.options.tokenizer || new w(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
724
750
  inLink: !1,
725
751
  inRawBlock: !1,
726
752
  top: !0
@@ -728,14 +754,14 @@ var x = class u {
728
754
  let t = {
729
755
  other: m,
730
756
  block: E.normal,
731
- inline: M.normal
757
+ inline: z.normal
732
758
  };
733
- this.options.pedantic ? (t.block = E.pedantic, t.inline = M.pedantic) : this.options.gfm && (t.block = E.gfm, this.options.breaks ? t.inline = M.breaks : t.inline = M.gfm), this.tokenizer.rules = t;
759
+ this.options.pedantic ? (t.block = E.pedantic, t.inline = z.pedantic) : this.options.gfm && (t.block = E.gfm, this.options.breaks ? t.inline = z.breaks : t.inline = z.gfm), this.tokenizer.rules = t;
734
760
  }
735
761
  static get rules() {
736
762
  return {
737
763
  block: E,
738
- inline: M
764
+ inline: z
739
765
  };
740
766
  }
741
767
  static lex(e, t) {
@@ -902,7 +928,7 @@ var x = class u {
902
928
  e = e.substring(o.raw.length), t.push(o);
903
929
  continue;
904
930
  }
905
- if (o = this.tokenizer.del(e)) {
931
+ if (o = this.tokenizer.del(e, n, a)) {
906
932
  e = e.substring(o.raw.length), t.push(o);
907
933
  continue;
908
934
  }
@@ -916,9 +942,9 @@ var x = class u {
916
942
  }
917
943
  let l = e;
918
944
  if (this.options.extensions?.startInline) {
919
- let p = Infinity, c = e.slice(1), g;
945
+ let p = Infinity, c = e.slice(1), d;
920
946
  this.options.extensions.startInline.forEach((h) => {
921
- g = h.call({ lexer: this }, c), typeof g == "number" && g >= 0 && (p = Math.min(p, g));
947
+ d = h.call({ lexer: this }, c), typeof d == "number" && d >= 0 && (p = Math.min(p, d));
922
948
  }), p < Infinity && p >= 0 && (l = e.substring(0, p + 1));
923
949
  }
924
950
  if (o = this.tokenizer.inlineText(l)) {
@@ -938,7 +964,7 @@ var x = class u {
938
964
  return t;
939
965
  }
940
966
  };
941
- var P = class {
967
+ var y = class {
942
968
  options;
943
969
  parser;
944
970
  constructor(e) {
@@ -950,8 +976,8 @@ var P = class {
950
976
  code({ text: e, lang: t, escaped: n }) {
951
977
  let r = (t || "").match(m.notSpaceStart)?.[0], i = e.replace(m.endingNewline, "") + `
952
978
  `;
953
- return r ? "<pre><code class=\"language-" + w(r) + "\">" + (n ? i : w(i, !0)) + `</code></pre>
954
- ` : "<pre><code>" + (n ? i : w(i, !0)) + `</code></pre>
979
+ return r ? "<pre><code class=\"language-" + O(r) + "\">" + (n ? i : O(i, !0)) + `</code></pre>
980
+ ` : "<pre><code>" + (n ? i : O(i, !0)) + `</code></pre>
955
981
  `;
956
982
  }
957
983
  blockquote({ tokens: e }) {
@@ -1029,7 +1055,7 @@ ${e}</tr>
1029
1055
  return `<em>${this.parser.parseInline(e)}</em>`;
1030
1056
  }
1031
1057
  codespan({ text: e }) {
1032
- return `<code>${w(e, !0)}</code>`;
1058
+ return `<code>${O(e, !0)}</code>`;
1033
1059
  }
1034
1060
  br(e) {
1035
1061
  return "<br>";
@@ -1042,18 +1068,18 @@ ${e}</tr>
1042
1068
  if (i === null) return r;
1043
1069
  e = i;
1044
1070
  let s = "<a href=\"" + e + "\"";
1045
- return t && (s += " title=\"" + w(t) + "\""), s += ">" + r + "</a>", s;
1071
+ return t && (s += " title=\"" + O(t) + "\""), s += ">" + r + "</a>", s;
1046
1072
  }
1047
1073
  image({ href: e, title: t, text: n, tokens: r }) {
1048
1074
  r && (n = this.parser.parseInline(r, this.parser.textRenderer));
1049
1075
  let i = X(e);
1050
- if (i === null) return w(n);
1076
+ if (i === null) return O(n);
1051
1077
  e = i;
1052
1078
  let s = `<img src="${e}" alt="${n}"`;
1053
- return t && (s += ` title="${w(t)}"`), s += ">", s;
1079
+ return t && (s += ` title="${O(t)}"`), s += ">", s;
1054
1080
  }
1055
1081
  text(e) {
1056
- return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : w(e.text);
1082
+ return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : O(e.text);
1057
1083
  }
1058
1084
  };
1059
1085
  var $ = class {
@@ -1093,7 +1119,7 @@ var b = class u {
1093
1119
  renderer;
1094
1120
  textRenderer;
1095
1121
  constructor(e) {
1096
- this.options = e || T, this.options.renderer = this.options.renderer || new P(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new $();
1122
+ this.options = e || T, this.options.renderer = this.options.renderer || new y(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new $();
1097
1123
  }
1098
1124
  static parse(e, t) {
1099
1125
  return new u(t).parse(e);
@@ -1238,7 +1264,7 @@ var b = class u {
1238
1264
  return n;
1239
1265
  }
1240
1266
  };
1241
- var S = class {
1267
+ var P = class {
1242
1268
  options;
1243
1269
  block;
1244
1270
  constructor(e) {
@@ -1275,16 +1301,16 @@ var S = class {
1275
1301
  }
1276
1302
  };
1277
1303
  var B = class {
1278
- defaults = L();
1304
+ defaults = M();
1279
1305
  options = this.setOptions;
1280
1306
  parse = this.parseMarkdown(!0);
1281
1307
  parseInline = this.parseMarkdown(!1);
1282
1308
  Parser = b;
1283
- Renderer = P;
1309
+ Renderer = y;
1284
1310
  TextRenderer = $;
1285
1311
  Lexer = x;
1286
- Tokenizer = y;
1287
- Hooks = S;
1312
+ Tokenizer = w;
1313
+ Hooks = P;
1288
1314
  constructor(...e) {
1289
1315
  this.use(...e);
1290
1316
  }
@@ -1335,7 +1361,7 @@ var B = class {
1335
1361
  }
1336
1362
  "childTokens" in i && i.childTokens && (t.childTokens[i.name] = i.childTokens);
1337
1363
  }), r.extensions = t), n.renderer) {
1338
- let i = this.defaults.renderer || new P(this.defaults);
1364
+ let i = this.defaults.renderer || new y(this.defaults);
1339
1365
  for (let s in n.renderer) {
1340
1366
  if (!(s in i)) throw new Error(`renderer '${s}' does not exist`);
1341
1367
  if (["options", "parser"].includes(s)) continue;
@@ -1348,7 +1374,7 @@ var B = class {
1348
1374
  r.renderer = i;
1349
1375
  }
1350
1376
  if (n.tokenizer) {
1351
- let i = this.defaults.tokenizer || new y(this.defaults);
1377
+ let i = this.defaults.tokenizer || new w(this.defaults);
1352
1378
  for (let s in n.tokenizer) {
1353
1379
  if (!(s in i)) throw new Error(`tokenizer '${s}' does not exist`);
1354
1380
  if ([
@@ -1365,22 +1391,22 @@ var B = class {
1365
1391
  r.tokenizer = i;
1366
1392
  }
1367
1393
  if (n.hooks) {
1368
- let i = this.defaults.hooks || new S();
1394
+ let i = this.defaults.hooks || new P();
1369
1395
  for (let s in n.hooks) {
1370
1396
  if (!(s in i)) throw new Error(`hook '${s}' does not exist`);
1371
1397
  if (["options", "block"].includes(s)) continue;
1372
1398
  let a = s, o = n.hooks[a], l = i[a];
1373
- S.passThroughHooks.has(s) ? i[a] = (p) => {
1374
- if (this.defaults.async && S.passThroughHooksRespectAsync.has(s)) return (async () => {
1375
- let g = await o.call(i, p);
1376
- return l.call(i, g);
1399
+ P.passThroughHooks.has(s) ? i[a] = (p) => {
1400
+ if (this.defaults.async && P.passThroughHooksRespectAsync.has(s)) return (async () => {
1401
+ let d = await o.call(i, p);
1402
+ return l.call(i, d);
1377
1403
  })();
1378
1404
  let c = o.call(i, p);
1379
1405
  return l.call(i, c);
1380
1406
  } : i[a] = (...p) => {
1381
1407
  if (this.defaults.async) return (async () => {
1382
- let g = await o.apply(i, p);
1383
- return g === !1 && (g = await l.apply(i, p)), g;
1408
+ let d = await o.apply(i, p);
1409
+ return d === !1 && (d = await l.apply(i, p)), d;
1384
1410
  })();
1385
1411
  let c = o.apply(i, p);
1386
1412
  return c === !1 && (c = l.apply(i, p)), c;
@@ -1443,7 +1469,7 @@ var B = class {
1443
1469
  return (n) => {
1444
1470
  if (n.message += `
1445
1471
  Please report this to https://github.com/markedjs/marked.`, e) {
1446
- let r = "<p>An error occurred:</p><pre>" + w(n.message + "", !0) + "</pre>";
1472
+ let r = "<p>An error occurred:</p><pre>" + O(n.message + "", !0) + "</pre>";
1447
1473
  return t ? Promise.resolve(r) : r;
1448
1474
  }
1449
1475
  if (t) return Promise.reject(n);
@@ -1451,32 +1477,32 @@ Please report this to https://github.com/markedjs/marked.`, e) {
1451
1477
  };
1452
1478
  }
1453
1479
  };
1454
- var _ = new B();
1455
- function d(u, e) {
1456
- return _.parse(u, e);
1480
+ var L = new B();
1481
+ function g(u, e) {
1482
+ return L.parse(u, e);
1457
1483
  }
1458
- d.options = d.setOptions = function(u) {
1459
- return _.setOptions(u), d.defaults = _.defaults, Z(d.defaults), d;
1484
+ g.options = g.setOptions = function(u) {
1485
+ return L.setOptions(u), g.defaults = L.defaults, H(g.defaults), g;
1460
1486
  };
1461
- d.getDefaults = L;
1462
- d.defaults = T;
1463
- d.use = function(...u) {
1464
- return _.use(...u), d.defaults = _.defaults, Z(d.defaults), d;
1487
+ g.getDefaults = M;
1488
+ g.defaults = T;
1489
+ g.use = function(...u) {
1490
+ return L.use(...u), g.defaults = L.defaults, H(g.defaults), g;
1465
1491
  };
1466
- d.walkTokens = function(u, e) {
1467
- return _.walkTokens(u, e);
1492
+ g.walkTokens = function(u, e) {
1493
+ return L.walkTokens(u, e);
1468
1494
  };
1469
- d.parseInline = _.parseInline;
1470
- d.Parser = b;
1471
- d.parser = b.parse;
1472
- d.Renderer = P;
1473
- d.TextRenderer = $;
1474
- d.Lexer = x;
1475
- d.lexer = x.lex;
1476
- d.Tokenizer = y;
1477
- d.Hooks = S;
1478
- d.parse = d;
1479
- var Dt = d.options, Ht = d.setOptions, Zt = d.use, Gt = d.walkTokens, Nt = d.parseInline, Qt = d, Ft = b.parse, jt = x.lex;
1495
+ g.parseInline = L.parseInline;
1496
+ g.Parser = b;
1497
+ g.parser = b.parse;
1498
+ g.Renderer = y;
1499
+ g.TextRenderer = $;
1500
+ g.Lexer = x;
1501
+ g.lexer = x.lex;
1502
+ g.Tokenizer = w;
1503
+ g.Hooks = P;
1504
+ g.parse = g;
1505
+ var Ut = g.options, Kt = g.setOptions, Wt = g.use, Xt = g.walkTokens, Jt = g.parseInline, Vt = g, Yt = b.parse, en = x.lex;
1480
1506
 
1481
1507
  //#endregion
1482
- exports.d = d;
1508
+ exports.g = g;