@emblemvault/hustle-react 1.5.12 → 1.5.13

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,4 +1,3 @@
1
- 'use client';
2
1
  import { createContext, useState, useEffect, useCallback, useRef, useMemo, useContext } from 'react';
3
2
  import { HustleIncognitoClient } from 'hustle-incognito';
4
3
  import { useEmblemAuthOptional } from '@emblemvault/emblem-auth-react';
@@ -32,9 +31,9 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
32
31
  ));
33
32
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
34
33
 
35
- // node_modules/highlight.js/lib/core.js
34
+ // ../../node_modules/highlight.js/lib/core.js
36
35
  var require_core = __commonJS({
37
- "node_modules/highlight.js/lib/core.js"(exports$1, module) {
36
+ "../../node_modules/highlight.js/lib/core.js"(exports$1, module) {
38
37
  function deepFreeze(obj) {
39
38
  if (obj instanceof Map) {
40
39
  obj.clear = obj.delete = obj.set = function() {
@@ -4777,15 +4776,15 @@ var animations = `
4777
4776
  }
4778
4777
  `;
4779
4778
 
4780
- // node_modules/marked/lib/marked.esm.js
4781
- function L() {
4779
+ // ../../node_modules/marked/lib/marked.esm.js
4780
+ function M() {
4782
4781
  return { async: false, breaks: false, extensions: null, gfm: true, hooks: null, pedantic: false, renderer: null, silent: false, tokenizer: null, walkTokens: null };
4783
4782
  }
4784
- var T = L();
4785
- function Z(u3) {
4786
- T = u3;
4783
+ var O = M();
4784
+ function G(u3) {
4785
+ O = u3;
4787
4786
  }
4788
- var C = { exec: () => null };
4787
+ var _ = { exec: () => null };
4789
4788
  function k(u3, e = "") {
4790
4789
  let t = typeof u3 == "string" ? u3 : u3.source, n = { replace: (r, i) => {
4791
4790
  let s = typeof i == "string" ? i : i.source;
@@ -4793,82 +4792,85 @@ function k(u3, e = "") {
4793
4792
  }, getRegex: () => new RegExp(t, e) };
4794
4793
  return n;
4795
4794
  }
4796
- var me = (() => {
4795
+ var be = (() => {
4797
4796
  try {
4798
4797
  return !!new RegExp("(?<=1)(?<!1)");
4799
4798
  } catch {
4800
4799
  return false;
4801
4800
  }
4802
4801
  })();
4803
- var m = { codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm, outputLinkReplace: /\\([\[\]])/g, indentCodeCompensation: /^(\s+)(?:```)/, beginningSpace: /^\s+/, endingHash: /#$/, startingSpaceChar: /^ /, endingSpaceChar: / $/, nonSpaceChar: /[^ ]/, newLineCharGlobal: /\n/g, tabCharGlobal: /\t/g, multipleSpaceGlobal: /\s+/g, blankLine: /^[ \t]*$/, doubleBlankLine: /\n[ \t]*\n[ \t]*$/, blockquoteStart: /^ {0,3}>/, blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g, blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm, listReplaceTabs: /^\t+/, listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g, listIsTask: /^\[[ xX]\] +\S/, listReplaceTask: /^\[[ xX]\] +/, listTaskCheckbox: /\[[ xX]\]/, anyLine: /\n.*\n/, hrefBrackets: /^<(.*)>$/, tableDelimiter: /[:|]/, tableAlignChars: /^\||\| *$/g, tableRowBlankLine: /\n[ \t]*$/, tableAlignRight: /^ *-+: *$/, tableAlignCenter: /^ *:-+: *$/, tableAlignLeft: /^ *:-+ *$/, startATag: /^<a /i, endATag: /^<\/a>/i, startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i, endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i, startAngleBracket: /^</, endAngleBracket: />$/, pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/, unicodeAlphaNumeric: /[\p{L}\p{N}]/u, escapeTest: /[&<>"']/, escapeReplace: /[&<>"']/g, escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g, unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig, caret: /(^|[^\[])\^/g, percentDecode: /%25/g, findPipe: /\|/g, splitPipe: / \|/, slashPipe: /\\\|/g, carriageReturn: /\r\n|\r/g, spaceLine: /^ +$/gm, notSpaceStart: /^\S*/, endingNewline: /\n$/, listItemRegex: (u3) => new RegExp(`^( {0,3}${u3})((?:[ ][^\\n]*)?(?:\\n|$))`), nextBulletRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), hrRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), fencesBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}(?:\`\`\`|~~~)`), headingBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}#`), htmlBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}<(?:[a-z].*>|!--)`, "i") };
4804
- var xe = /^(?:[ \t]*(?:\n|$))+/;
4805
- var be = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/;
4806
- var Re = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/;
4807
- var I = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/;
4808
- var Te = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/;
4809
- var N = /(?:[*+-]|\d{1,9}[.)])/;
4810
- var re = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/;
4811
- var 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();
4812
- var 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();
4813
- var Q = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/;
4814
- var we = /^[^\n]+/;
4802
+ var m = { codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm, outputLinkReplace: /\\([\[\]])/g, indentCodeCompensation: /^(\s+)(?:```)/, beginningSpace: /^\s+/, endingHash: /#$/, startingSpaceChar: /^ /, endingSpaceChar: / $/, nonSpaceChar: /[^ ]/, newLineCharGlobal: /\n/g, tabCharGlobal: /\t/g, multipleSpaceGlobal: /\s+/g, blankLine: /^[ \t]*$/, doubleBlankLine: /\n[ \t]*\n[ \t]*$/, blockquoteStart: /^ {0,3}>/, blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g, blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm, listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g, listIsTask: /^\[[ xX]\] +\S/, listReplaceTask: /^\[[ xX]\] +/, listTaskCheckbox: /\[[ xX]\]/, anyLine: /\n.*\n/, hrefBrackets: /^<(.*)>$/, tableDelimiter: /[:|]/, tableAlignChars: /^\||\| *$/g, tableRowBlankLine: /\n[ \t]*$/, tableAlignRight: /^ *-+: *$/, tableAlignCenter: /^ *:-+: *$/, tableAlignLeft: /^ *:-+ *$/, startATag: /^<a /i, endATag: /^<\/a>/i, startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i, endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i, startAngleBracket: /^</, endAngleBracket: />$/, pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/, unicodeAlphaNumeric: /[\p{L}\p{N}]/u, escapeTest: /[&<>"']/, escapeReplace: /[&<>"']/g, escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g, caret: /(^|[^\[])\^/g, percentDecode: /%25/g, findPipe: /\|/g, splitPipe: / \|/, slashPipe: /\\\|/g, carriageReturn: /\r\n|\r/g, spaceLine: /^ +$/gm, notSpaceStart: /^\S*/, endingNewline: /\n$/, listItemRegex: (u3) => new RegExp(`^( {0,3}${u3})((?:[ ][^\\n]*)?(?:\\n|$))`), nextBulletRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), hrRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), fencesBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}(?:\`\`\`|~~~)`), headingBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}#`), htmlBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}<(?:[a-z].*>|!--)`, "i"), blockquoteBeginRegex: (u3) => new RegExp(`^ {0,${Math.min(3, u3 - 1)}}>`) };
4803
+ var Re = /^(?:[ \t]*(?:\n|$))+/;
4804
+ var Oe = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/;
4805
+ var Te = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/;
4806
+ var C = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/;
4807
+ var we = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/;
4808
+ var Q = / {0,3}(?:[*+-]|\d{1,9}[.)])/;
4809
+ var se = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/;
4810
+ var ie = k(se).replace(/bull/g, Q).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();
4811
+ var ye = k(se).replace(/bull/g, Q).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();
4812
+ var j = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/;
4813
+ var Pe = /^[^\n]+/;
4815
4814
  var F = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/;
4816
- var 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();
4817
- var Pe = k(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, N).getRegex();
4815
+ var Se = k(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", F).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex();
4816
+ var $e = k(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, Q).getRegex();
4818
4817
  var 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";
4819
- var j = /<!--(?:-?>|[\s\S]*?(?:-->|$))/;
4820
- var 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();
4821
- var 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();
4822
- var $e = k(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ie).getRegex();
4823
- var U = { blockquote: $e, code: be, def: ye, fences: Re, heading: Te, hr: I, html: Se, lheading: se, list: Pe, newline: xe, paragraph: ie, table: C, text: we };
4824
- var 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();
4825
- var _e = { ...U, lheading: Oe, table: te, 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() };
4826
- var Le = { ...U, 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(), def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/, heading: /^(#{1,6})(.*)(?:\n+|$)/, fences: C, lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/, paragraph: k(Q).replace("hr", I).replace("heading", ` *#{1,6} *[^
4827
- ]`).replace("lheading", se).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex() };
4828
- var Me = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/;
4829
- var ze = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/;
4830
- var oe = /^( {2,}|\\)\n(?!\s*$)/;
4818
+ var U = /<!--(?:-?>|[\s\S]*?(?:-->|$))/;
4819
+ var _e = 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", U).replace("tag", v).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
4820
+ var oe = k(j).replace("hr", C).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", v).getRegex();
4821
+ var Le = k(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", oe).getRegex();
4822
+ var K = { blockquote: Le, code: Oe, def: Se, fences: Te, heading: we, hr: C, html: _e, lheading: ie, list: $e, newline: Re, paragraph: oe, table: _, text: Pe };
4823
+ var ne = k("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", C).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", v).getRegex();
4824
+ var Me = { ...K, lheading: ye, table: ne, paragraph: k(j).replace("hr", C).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", ne).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", v).getRegex() };
4825
+ var ze = { ...K, html: k(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", U).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(), def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/, heading: /^(#{1,6})(.*)(?:\n+|$)/, fences: _, lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/, paragraph: k(j).replace("hr", C).replace("heading", ` *#{1,6} *[^
4826
+ ]`).replace("lheading", ie).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex() };
4827
+ var Ee = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/;
4828
+ var Ie = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/;
4829
+ var ae = /^( {2,}|\\)\n(?!\s*$)/;
4831
4830
  var Ae = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/;
4832
- var D = /[\p{P}\p{S}]/u;
4833
- var K = /[\s\p{P}\p{S}]/u;
4834
- var ae = /[^\s\p{P}\p{S}]/u;
4835
- var Ce = k(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, K).getRegex();
4831
+ var z = /[\p{P}\p{S}]/u;
4832
+ var H = /[\s\p{P}\p{S}]/u;
4833
+ var W = /[^\s\p{P}\p{S}]/u;
4834
+ var Ce = k(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, H).getRegex();
4836
4835
  var le = /(?!~)[\p{P}\p{S}]/u;
4837
- var Ie = /(?!~)[\s\p{P}\p{S}]/u;
4838
- var Ee = /(?:[^\s\p{P}\p{S}]|~)/u;
4839
- var 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();
4840
- var ue = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/;
4841
- var qe = k(ue, "u").replace(/punct/g, D).getRegex();
4842
- var ve = k(ue, "u").replace(/punct/g, le).getRegex();
4836
+ var Be = /(?!~)[\s\p{P}\p{S}]/u;
4837
+ var De = /(?:[^\s\p{P}\p{S}]|~)/u;
4838
+ var qe = k(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", be ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex();
4839
+ var ue = /^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/;
4840
+ var ve = k(ue, "u").replace(/punct/g, z).getRegex();
4841
+ var He = k(ue, "u").replace(/punct/g, le).getRegex();
4843
4842
  var pe = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)";
4844
- var De = k(pe, "gu").replace(/notPunctSpace/g, ae).replace(/punctSpace/g, K).replace(/punct/g, D).getRegex();
4845
- var He = k(pe, "gu").replace(/notPunctSpace/g, Ee).replace(/punctSpace/g, Ie).replace(/punct/g, le).getRegex();
4846
- var 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();
4847
- var Ge = k(/\\(punct)/, "gu").replace(/punct/g, D).getRegex();
4848
- var 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();
4849
- var Qe = k(j).replace("(?:-->|$)", "-->").getRegex();
4850
- var 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();
4851
- var q = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/;
4852
- var je = k(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", q).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex();
4843
+ var Ze = k(pe, "gu").replace(/notPunctSpace/g, W).replace(/punctSpace/g, H).replace(/punct/g, z).getRegex();
4844
+ var Ge = k(pe, "gu").replace(/notPunctSpace/g, De).replace(/punctSpace/g, Be).replace(/punct/g, le).getRegex();
4845
+ var Ne = k("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, W).replace(/punctSpace/g, H).replace(/punct/g, z).getRegex();
4846
+ var Qe = k(/^~~?(?:((?!~)punct)|[^\s~])/, "u").replace(/punct/g, z).getRegex();
4847
+ var je = "^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)";
4848
+ var Fe = k(je, "gu").replace(/notPunctSpace/g, W).replace(/punctSpace/g, H).replace(/punct/g, z).getRegex();
4849
+ var Ue = k(/\\(punct)/, "gu").replace(/punct/g, z).getRegex();
4850
+ var Ke = 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();
4851
+ var We = k(U).replace("(?:-->|$)", "-->").getRegex();
4852
+ var Xe = 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", We).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex();
4853
+ var q = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/;
4854
+ var Je = k(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label", q).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex();
4853
4855
  var ce = k(/^!?\[(label)\]\[(ref)\]/).replace("label", q).replace("ref", F).getRegex();
4854
4856
  var he = k(/^!?\[(ref)\](?:\[\])?/).replace("ref", F).getRegex();
4855
- var Ue = k("reflink|nolink(?!\\()", "g").replace("reflink", ce).replace("nolink", he).getRegex();
4856
- var ne = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/;
4857
- var W = { _backpedal: C, anyPunctuation: Ge, autolink: Ne, blockSkip: Be, br: oe, code: ze, del: C, emStrongLDelim: qe, emStrongRDelimAst: De, emStrongRDelimUnd: Ze, escape: Me, link: je, nolink: he, punctuation: Ce, reflink: ce, reflinkSearch: Ue, tag: Fe, text: Ae, url: C };
4858
- var Ke = { ...W, link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", q).getRegex(), reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", q).getRegex() };
4859
- var G = { ...W, emStrongRDelimAst: He, emStrongLDelim: ve, 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(), _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/, del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/, 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() };
4860
- var We = { ...G, br: k(oe).replace("{2,}", "*").getRegex(), text: k(G.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex() };
4861
- var E = { normal: U, gfm: _e, pedantic: Le };
4862
- var M = { normal: W, gfm: G, breaks: We, pedantic: Ke };
4863
- var Xe = { "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;", "'": "&#39;" };
4864
- var ke = (u3) => Xe[u3];
4865
- function w(u3, e) {
4857
+ var Ve = k("reflink|nolink(?!\\()", "g").replace("reflink", ce).replace("nolink", he).getRegex();
4858
+ var re = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/;
4859
+ var X = { _backpedal: _, anyPunctuation: Ue, autolink: Ke, blockSkip: qe, br: ae, code: Ie, del: _, delLDelim: _, delRDelim: _, emStrongLDelim: ve, emStrongRDelimAst: Ze, emStrongRDelimUnd: Ne, escape: Ee, link: Je, nolink: he, punctuation: Ce, reflink: ce, reflinkSearch: Ve, tag: Xe, text: Ae, url: _ };
4860
+ var Ye = { ...X, link: k(/^!?\[(label)\]\((.*?)\)/).replace("label", q).getRegex(), reflink: k(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", q).getRegex() };
4861
+ var N = { ...X, emStrongRDelimAst: Ge, emStrongLDelim: He, delLDelim: Qe, delRDelim: Fe, url: k(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", re).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(), _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/, del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/, 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", re).getRegex() };
4862
+ var et = { ...N, br: k(ae).replace("{2,}", "*").getRegex(), text: k(N.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex() };
4863
+ var B = { normal: K, gfm: Me, pedantic: ze };
4864
+ var E = { normal: X, gfm: N, breaks: et, pedantic: Ye };
4865
+ var tt = { "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;", "'": "&#39;" };
4866
+ var ke = (u3) => tt[u3];
4867
+ function T(u3, e) {
4866
4868
  if (e) {
4867
4869
  if (m.escapeTest.test(u3)) return u3.replace(m.escapeReplace, ke);
4868
4870
  } else if (m.escapeTestNoEncode.test(u3)) return u3.replace(m.escapeReplaceNoEncode, ke);
4869
4871
  return u3;
4870
4872
  }
4871
- function X(u3) {
4873
+ function J(u3) {
4872
4874
  try {
4873
4875
  u3 = encodeURI(u3).replace(m.percentDecode, "%");
4874
4876
  } catch {
@@ -4876,7 +4878,7 @@ function X(u3) {
4876
4878
  }
4877
4879
  return u3;
4878
4880
  }
4879
- function J(u3, e) {
4881
+ function V(u3, e) {
4880
4882
  let t = u3.replace(m.findPipe, (i, s, a) => {
4881
4883
  let o = false, l = s;
4882
4884
  for (; --l >= 0 && a[l] === "\\"; ) o = !o;
@@ -4887,7 +4889,7 @@ function J(u3, e) {
4887
4889
  for (; r < n.length; r++) n[r] = n[r].trim().replace(m.slashPipe, "|");
4888
4890
  return n;
4889
4891
  }
4890
- function z(u3, e, t) {
4892
+ function I(u3, e, t) {
4891
4893
  let n = u3.length;
4892
4894
  if (n === 0) return "";
4893
4895
  let r = 0;
@@ -4906,13 +4908,21 @@ function de(u3, e) {
4906
4908
  else if (u3[n] === e[1] && (t--, t < 0)) return n;
4907
4909
  return t > 0 ? -2 : -1;
4908
4910
  }
4909
- function ge(u3, e, t, n, r) {
4911
+ function ge(u3, e = 0) {
4912
+ let t = e, n = "";
4913
+ for (let r of u3) if (r === " ") {
4914
+ let i = 4 - t % 4;
4915
+ n += " ".repeat(i), t += i;
4916
+ } else n += r, t++;
4917
+ return n;
4918
+ }
4919
+ function fe(u3, e, t, n, r) {
4910
4920
  let i = e.href, s = e.title || null, a = u3[1].replace(r.other.outputLinkReplace, "$1");
4911
4921
  n.state.inLink = true;
4912
4922
  let o = { type: u3[0].charAt(0) === "!" ? "image" : "link", raw: t, href: i, title: s, text: a, tokens: n.inlineTokens(a) };
4913
4923
  return n.state.inLink = false, o;
4914
4924
  }
4915
- function Je(u3, e, t) {
4925
+ function nt(u3, e, t) {
4916
4926
  let n = u3.match(t.other.indentCodeCompensation);
4917
4927
  if (n === null) return e;
4918
4928
  let r = n[1];
@@ -4925,12 +4935,12 @@ function Je(u3, e, t) {
4925
4935
  }).join(`
4926
4936
  `);
4927
4937
  }
4928
- var y = class {
4938
+ var w = class {
4929
4939
  constructor(e) {
4930
4940
  __publicField(this, "options");
4931
4941
  __publicField(this, "rules");
4932
4942
  __publicField(this, "lexer");
4933
- this.options = e || T;
4943
+ this.options = e || O;
4934
4944
  }
4935
4945
  space(e) {
4936
4946
  let t = this.rules.block.newline.exec(e);
@@ -4940,14 +4950,14 @@ var y = class {
4940
4950
  let t = this.rules.block.code.exec(e);
4941
4951
  if (t) {
4942
4952
  let n = t[0].replace(this.rules.other.codeRemoveIndent, "");
4943
- return { type: "code", raw: t[0], codeBlockStyle: "indented", text: this.options.pedantic ? n : z(n, `
4953
+ return { type: "code", raw: t[0], codeBlockStyle: "indented", text: this.options.pedantic ? n : I(n, `
4944
4954
  `) };
4945
4955
  }
4946
4956
  }
4947
4957
  fences(e) {
4948
4958
  let t = this.rules.block.fences.exec(e);
4949
4959
  if (t) {
4950
- let n = t[0], r = Je(n, t[3] || "", this.rules);
4960
+ let n = t[0], r = nt(n, t[3] || "", this.rules);
4951
4961
  return { type: "code", raw: n, lang: t[2] ? t[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : t[2], text: r };
4952
4962
  }
4953
4963
  }
@@ -4956,7 +4966,7 @@ var y = class {
4956
4966
  if (t) {
4957
4967
  let n = t[2].trim();
4958
4968
  if (this.rules.other.endingHash.test(n)) {
4959
- let r = z(n, "#");
4969
+ let r = I(n, "#");
4960
4970
  (this.options.pedantic || !r || this.rules.other.endingSpaceChar.test(r)) && (n = r.trim());
4961
4971
  }
4962
4972
  return { type: "heading", raw: t[0], depth: t[1].length, text: n, tokens: this.lexer.inline(n) };
@@ -4964,13 +4974,13 @@ var y = class {
4964
4974
  }
4965
4975
  hr(e) {
4966
4976
  let t = this.rules.block.hr.exec(e);
4967
- if (t) return { type: "hr", raw: z(t[0], `
4977
+ if (t) return { type: "hr", raw: I(t[0], `
4968
4978
  `) };
4969
4979
  }
4970
4980
  blockquote(e) {
4971
4981
  let t = this.rules.block.blockquote.exec(e);
4972
4982
  if (t) {
4973
- let n = z(t[0], `
4983
+ let n = I(t[0], `
4974
4984
  `).split(`
4975
4985
  `), r = "", i = "", s = [];
4976
4986
  for (; n.length > 0; ) {
@@ -4985,21 +4995,21 @@ var y = class {
4985
4995
  r = r ? `${r}
4986
4996
  ${p}` : p, i = i ? `${i}
4987
4997
  ${c}` : c;
4988
- let g = this.lexer.state.top;
4989
- if (this.lexer.state.top = true, this.lexer.blockTokens(c, s, true), this.lexer.state.top = g, n.length === 0) break;
4998
+ let d = this.lexer.state.top;
4999
+ if (this.lexer.state.top = true, this.lexer.blockTokens(c, s, true), this.lexer.state.top = d, n.length === 0) break;
4990
5000
  let h = s.at(-1);
4991
5001
  if (h?.type === "code") break;
4992
5002
  if (h?.type === "blockquote") {
4993
5003
  let R = h, f = R.raw + `
4994
5004
  ` + n.join(`
4995
- `), O = this.blockquote(f);
4996
- 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;
5005
+ `), S = this.blockquote(f);
5006
+ 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;
4997
5007
  break;
4998
5008
  } else if (h?.type === "list") {
4999
5009
  let R = h, f = R.raw + `
5000
5010
  ` + n.join(`
5001
- `), O = this.list(f);
5002
- 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(`
5011
+ `), S = this.list(f);
5012
+ 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(`
5003
5013
  `);
5004
5014
  continue;
5005
5015
  }
@@ -5017,25 +5027,25 @@ ${c}` : c;
5017
5027
  let l = false, p = "", c = "";
5018
5028
  if (!(t = s.exec(e)) || this.rules.block.hr.test(e)) break;
5019
5029
  p = t[0], e = e.substring(p.length);
5020
- let g = t[2].split(`
5021
- `, 1)[0].replace(this.rules.other.listReplaceTabs, (O) => " ".repeat(3 * O.length)), h = e.split(`
5022
- `, 1)[0], R = !g.trim(), f = 0;
5023
- 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 + `
5030
+ let d = ge(t[2].split(`
5031
+ `, 1)[0], t[1].length), h = e.split(`
5032
+ `, 1)[0], R = !d.trim(), f = 0;
5033
+ 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 + `
5024
5034
  `, e = e.substring(h.length + 1), l = true), !l) {
5025
- 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);
5035
+ let S = this.rules.other.nextBulletRegex(f), Y = this.rules.other.hrRegex(f), ee = this.rules.other.fencesBeginRegex(f), te = this.rules.other.headingBeginRegex(f), me = this.rules.other.htmlBeginRegex(f), xe = this.rules.other.blockquoteBeginRegex(f);
5026
5036
  for (; e; ) {
5027
- let H = e.split(`
5037
+ let Z = e.split(`
5028
5038
  `, 1)[0], A;
5029
- 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;
5039
+ if (h = Z, this.options.pedantic ? (h = h.replace(this.rules.other.listReplaceNesting, " "), A = h) : A = h.replace(this.rules.other.tabCharGlobal, " "), ee.test(h) || te.test(h) || me.test(h) || xe.test(h) || S.test(h) || Y.test(h)) break;
5030
5040
  if (A.search(this.rules.other.nonSpaceChar) >= f || !h.trim()) c += `
5031
5041
  ` + A.slice(f);
5032
5042
  else {
5033
- if (R || g.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || Y.test(g) || ee.test(g) || V.test(g)) break;
5043
+ if (R || d.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || ee.test(d) || te.test(d) || Y.test(d)) break;
5034
5044
  c += `
5035
5045
  ` + h;
5036
5046
  }
5037
- !R && !h.trim() && (R = true), p += H + `
5038
- `, e = e.substring(H.length + 1), g = A.slice(f);
5047
+ R = !h.trim(), p += Z + `
5048
+ `, e = e.substring(Z.length + 1), d = A.slice(f);
5039
5049
  }
5040
5050
  }
5041
5051
  i.loose || (a ? i.loose = true : this.rules.other.doubleBlankLine.test(p) && (a = true)), i.items.push({ type: "list_item", raw: p, task: !!this.options.gfm && this.rules.other.listIsTask.test(c), loose: false, text: c, tokens: [] }), i.raw += p;
@@ -5060,7 +5070,7 @@ ${c}` : c;
5060
5070
  }
5061
5071
  }
5062
5072
  if (!i.loose) {
5063
- let p = l.tokens.filter((g) => g.type === "space"), c = p.length > 0 && p.some((g) => this.rules.other.anyLine.test(g.raw));
5073
+ let p = l.tokens.filter((d) => d.type === "space"), c = p.length > 0 && p.some((d) => this.rules.other.anyLine.test(d.raw));
5064
5074
  i.loose = c;
5065
5075
  }
5066
5076
  }
@@ -5085,18 +5095,21 @@ ${c}` : c;
5085
5095
  table(e) {
5086
5096
  let t = this.rules.block.table.exec(e);
5087
5097
  if (!t || !this.rules.other.tableDelimiter.test(t[2])) return;
5088
- let n = J(t[1]), r = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split(`
5098
+ let n = V(t[1]), r = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split(`
5089
5099
  `) : [], s = { type: "table", raw: t[0], header: [], align: [], rows: [] };
5090
5100
  if (n.length === r.length) {
5091
5101
  for (let a of r) this.rules.other.tableAlignRight.test(a) ? s.align.push("right") : this.rules.other.tableAlignCenter.test(a) ? s.align.push("center") : this.rules.other.tableAlignLeft.test(a) ? s.align.push("left") : s.align.push(null);
5092
5102
  for (let a = 0; a < n.length; a++) s.header.push({ text: n[a], tokens: this.lexer.inline(n[a]), header: true, align: s.align[a] });
5093
- for (let a of i) s.rows.push(J(a, s.header.length).map((o, l) => ({ text: o, tokens: this.lexer.inline(o), header: false, align: s.align[l] })));
5103
+ for (let a of i) s.rows.push(V(a, s.header.length).map((o, l) => ({ text: o, tokens: this.lexer.inline(o), header: false, align: s.align[l] })));
5094
5104
  return s;
5095
5105
  }
5096
5106
  }
5097
5107
  lheading(e) {
5098
5108
  let t = this.rules.block.lheading.exec(e);
5099
- if (t) return { type: "heading", raw: t[0], depth: t[2].charAt(0) === "=" ? 1 : 2, text: t[1], tokens: this.lexer.inline(t[1]) };
5109
+ if (t) {
5110
+ let n = t[1].trim();
5111
+ return { type: "heading", raw: t[0], depth: t[2].charAt(0) === "=" ? 1 : 2, text: n, tokens: this.lexer.inline(n) };
5112
+ }
5100
5113
  }
5101
5114
  paragraph(e) {
5102
5115
  let t = this.rules.block.paragraph.exec(e);
@@ -5124,7 +5137,7 @@ ${c}` : c;
5124
5137
  let n = t[2].trim();
5125
5138
  if (!this.options.pedantic && this.rules.other.startAngleBracket.test(n)) {
5126
5139
  if (!this.rules.other.endAngleBracket.test(n)) return;
5127
- let s = z(n.slice(0, -1), "\\");
5140
+ let s = I(n.slice(0, -1), "\\");
5128
5141
  if ((n.length - s.length) % 2 === 0) return;
5129
5142
  } else {
5130
5143
  let s = de(t[2], "()");
@@ -5139,7 +5152,7 @@ ${c}` : c;
5139
5152
  let s = this.rules.other.pedanticHrefTitle.exec(r);
5140
5153
  s && (r = s[1], i = s[3]);
5141
5154
  } else i = t[3] ? t[3].slice(1, -1) : "";
5142
- 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, { href: r && r.replace(this.rules.inline.anyPunctuation, "$1"), title: i && i.replace(this.rules.inline.anyPunctuation, "$1") }, t[0], this.lexer, this.rules);
5155
+ 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)), fe(t, { href: r && r.replace(this.rules.inline.anyPunctuation, "$1"), title: i && i.replace(this.rules.inline.anyPunctuation, "$1") }, t[0], this.lexer, this.rules);
5143
5156
  }
5144
5157
  }
5145
5158
  reflink(e, t) {
@@ -5150,15 +5163,15 @@ ${c}` : c;
5150
5163
  let s = n[0].charAt(0);
5151
5164
  return { type: "text", raw: s, text: s };
5152
5165
  }
5153
- return ge(n, i, n[0], this.lexer, this.rules);
5166
+ return fe(n, i, n[0], this.lexer, this.rules);
5154
5167
  }
5155
5168
  }
5156
5169
  emStrong(e, t, n = "") {
5157
5170
  let r = this.rules.inline.emStrongLDelim.exec(e);
5158
- if (!r || r[3] && n.match(this.rules.other.unicodeAlphaNumeric)) return;
5159
- if (!(r[1] || r[2] || "") || !n || this.rules.inline.punctuation.exec(n)) {
5171
+ if (!r || !r[1] && !r[2] && !r[3] && !r[4] || r[4] && n.match(this.rules.other.unicodeAlphaNumeric)) return;
5172
+ if (!(r[1] || r[3] || "") || !n || this.rules.inline.punctuation.exec(n)) {
5160
5173
  let s = [...r[0]].length - 1, a, o, l = s, p = 0, c = r[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
5161
- for (c.lastIndex = 0, t = t.slice(-1 * e.length + s); (r = c.exec(t)) != null; ) {
5174
+ for (c.lastIndex = 0, t = t.slice(-1 * e.length + s); (r = c.exec(t)) !== null; ) {
5162
5175
  if (a = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !a) continue;
5163
5176
  if (o = [...a].length, r[3] || r[4]) {
5164
5177
  l += o;
@@ -5169,7 +5182,7 @@ ${c}` : c;
5169
5182
  }
5170
5183
  if (l -= o, l > 0) continue;
5171
5184
  o = Math.min(o, o + l + p);
5172
- let g = [...r[0]][0].length, h = e.slice(0, s + r.index + g + o);
5185
+ let d = [...r[0]][0].length, h = e.slice(0, s + r.index + d + o);
5173
5186
  if (Math.min(s, o) % 2) {
5174
5187
  let f = h.slice(1, -1);
5175
5188
  return { type: "em", raw: h, text: f, tokens: this.lexer.inlineTokens(f) };
@@ -5190,9 +5203,23 @@ ${c}` : c;
5190
5203
  let t = this.rules.inline.br.exec(e);
5191
5204
  if (t) return { type: "br", raw: t[0] };
5192
5205
  }
5193
- del(e) {
5194
- let t = this.rules.inline.del.exec(e);
5195
- if (t) return { type: "del", raw: t[0], text: t[2], tokens: this.lexer.inlineTokens(t[2]) };
5206
+ del(e, t, n = "") {
5207
+ let r = this.rules.inline.delLDelim.exec(e);
5208
+ if (!r) return;
5209
+ if (!(r[1] || "") || !n || this.rules.inline.punctuation.exec(n)) {
5210
+ let s = [...r[0]].length - 1, a, o, l = s, p = this.rules.inline.delRDelim;
5211
+ for (p.lastIndex = 0, t = t.slice(-1 * e.length + s); (r = p.exec(t)) !== null; ) {
5212
+ if (a = r[1] || r[2] || r[3] || r[4] || r[5] || r[6], !a || (o = [...a].length, o !== s)) continue;
5213
+ if (r[3] || r[4]) {
5214
+ l += o;
5215
+ continue;
5216
+ }
5217
+ if (l -= o, l > 0) continue;
5218
+ o = Math.min(o, o + l);
5219
+ let c = [...r[0]][0].length, d = e.slice(0, s + r.index + c + o), h = d.slice(s, -s);
5220
+ return { type: "del", raw: d, text: h, tokens: this.lexer.inlineTokens(h) };
5221
+ }
5222
+ }
5196
5223
  }
5197
5224
  autolink(e) {
5198
5225
  let t = this.rules.inline.autolink.exec(e);
@@ -5231,12 +5258,12 @@ var x = class u {
5231
5258
  __publicField(this, "state");
5232
5259
  __publicField(this, "inlineQueue");
5233
5260
  __publicField(this, "tokenizer");
5234
- this.tokens = [], this.tokens.links = /* @__PURE__ */ 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 = { inLink: false, inRawBlock: false, top: true };
5235
- let t = { other: m, block: E.normal, inline: M.normal };
5236
- 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;
5261
+ this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e || O, 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 = { inLink: false, inRawBlock: false, top: true };
5262
+ let t = { other: m, block: B.normal, inline: E.normal };
5263
+ this.options.pedantic ? (t.block = B.pedantic, t.inline = E.pedantic) : this.options.gfm && (t.block = B.gfm, this.options.breaks ? t.inline = E.breaks : t.inline = E.gfm), this.tokenizer.rules = t;
5237
5264
  }
5238
5265
  static get rules() {
5239
- return { block: E, inline: M };
5266
+ return { block: B, inline: E };
5240
5267
  }
5241
5268
  static lex(e, t) {
5242
5269
  return new u(t).lex(e);
@@ -5254,7 +5281,7 @@ var x = class u {
5254
5281
  return this.inlineQueue = [], this.tokens;
5255
5282
  }
5256
5283
  blockTokens(e, t = [], n = false) {
5257
- for (this.options.pedantic && (e = e.replace(m.tabCharGlobal, " ").replace(m.spaceLine, "")); e; ) {
5284
+ for (this.tokenizer.lexer = this, this.options.pedantic && (e = e.replace(m.tabCharGlobal, " ").replace(m.spaceLine, "")); e; ) {
5258
5285
  let r;
5259
5286
  if (this.options.extensions?.block?.some((s) => (r = s.call({ lexer: this }, e, t)) ? (e = e.substring(r.raw.length), t.push(r), true) : false)) continue;
5260
5287
  if (r = this.tokenizer.space(e)) {
@@ -5352,14 +5379,15 @@ var x = class u {
5352
5379
  return this.inlineQueue.push({ src: e, tokens: t }), t;
5353
5380
  }
5354
5381
  inlineTokens(e, t = []) {
5382
+ this.tokenizer.lexer = this;
5355
5383
  let n = e, r = null;
5356
5384
  if (this.tokens.links) {
5357
5385
  let o = Object.keys(this.tokens.links);
5358
- if (o.length > 0) for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(n)) != null; ) o.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
5386
+ if (o.length > 0) for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(n)) !== null; ) o.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
5359
5387
  }
5360
- for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) != null; ) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
5388
+ for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) !== null; ) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
5361
5389
  let i;
5362
- for (; (r = this.tokenizer.rules.inline.blockSkip.exec(n)) != null; ) i = r[2] ? r[2].length : 0, n = n.slice(0, r.index + i) + "[" + "a".repeat(r[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
5390
+ for (; (r = this.tokenizer.rules.inline.blockSkip.exec(n)) !== null; ) i = r[2] ? r[2].length : 0, n = n.slice(0, r.index + i) + "[" + "a".repeat(r[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
5363
5391
  n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
5364
5392
  let s = false, a = "";
5365
5393
  for (; e; ) {
@@ -5396,7 +5424,7 @@ var x = class u {
5396
5424
  e = e.substring(o.raw.length), t.push(o);
5397
5425
  continue;
5398
5426
  }
5399
- if (o = this.tokenizer.del(e)) {
5427
+ if (o = this.tokenizer.del(e, n, a)) {
5400
5428
  e = e.substring(o.raw.length), t.push(o);
5401
5429
  continue;
5402
5430
  }
@@ -5410,9 +5438,9 @@ var x = class u {
5410
5438
  }
5411
5439
  let l = e;
5412
5440
  if (this.options.extensions?.startInline) {
5413
- let p = 1 / 0, c = e.slice(1), g;
5441
+ let p = 1 / 0, c = e.slice(1), d;
5414
5442
  this.options.extensions.startInline.forEach((h) => {
5415
- g = h.call({ lexer: this }, c), typeof g == "number" && g >= 0 && (p = Math.min(p, g));
5443
+ d = h.call({ lexer: this }, c), typeof d == "number" && d >= 0 && (p = Math.min(p, d));
5416
5444
  }), p < 1 / 0 && p >= 0 && (l = e.substring(0, p + 1));
5417
5445
  }
5418
5446
  if (o = this.tokenizer.inlineText(l)) {
@@ -5432,11 +5460,11 @@ var x = class u {
5432
5460
  return t;
5433
5461
  }
5434
5462
  };
5435
- var P = class {
5463
+ var y = class {
5436
5464
  constructor(e) {
5437
5465
  __publicField(this, "options");
5438
5466
  __publicField(this, "parser");
5439
- this.options = e || T;
5467
+ this.options = e || O;
5440
5468
  }
5441
5469
  space(e) {
5442
5470
  return "";
@@ -5444,8 +5472,8 @@ var P = class {
5444
5472
  code({ text: e, lang: t, escaped: n }) {
5445
5473
  let r = (t || "").match(m.notSpaceStart)?.[0], i = e.replace(m.endingNewline, "") + `
5446
5474
  `;
5447
- return r ? '<pre><code class="language-' + w(r) + '">' + (n ? i : w(i, true)) + `</code></pre>
5448
- ` : "<pre><code>" + (n ? i : w(i, true)) + `</code></pre>
5475
+ return r ? '<pre><code class="language-' + T(r) + '">' + (n ? i : T(i, true)) + `</code></pre>
5476
+ ` : "<pre><code>" + (n ? i : T(i, true)) + `</code></pre>
5449
5477
  `;
5450
5478
  }
5451
5479
  blockquote({ tokens: e }) {
@@ -5523,7 +5551,7 @@ ${e}</tr>
5523
5551
  return `<em>${this.parser.parseInline(e)}</em>`;
5524
5552
  }
5525
5553
  codespan({ text: e }) {
5526
- return `<code>${w(e, true)}</code>`;
5554
+ return `<code>${T(e, true)}</code>`;
5527
5555
  }
5528
5556
  br(e) {
5529
5557
  return "<br>";
@@ -5532,22 +5560,22 @@ ${e}</tr>
5532
5560
  return `<del>${this.parser.parseInline(e)}</del>`;
5533
5561
  }
5534
5562
  link({ href: e, title: t, tokens: n }) {
5535
- let r = this.parser.parseInline(n), i = X(e);
5563
+ let r = this.parser.parseInline(n), i = J(e);
5536
5564
  if (i === null) return r;
5537
5565
  e = i;
5538
5566
  let s = '<a href="' + e + '"';
5539
- return t && (s += ' title="' + w(t) + '"'), s += ">" + r + "</a>", s;
5567
+ return t && (s += ' title="' + T(t) + '"'), s += ">" + r + "</a>", s;
5540
5568
  }
5541
5569
  image({ href: e, title: t, text: n, tokens: r }) {
5542
5570
  r && (n = this.parser.parseInline(r, this.parser.textRenderer));
5543
- let i = X(e);
5544
- if (i === null) return w(n);
5571
+ let i = J(e);
5572
+ if (i === null) return T(n);
5545
5573
  e = i;
5546
- let s = `<img src="${e}" alt="${n}"`;
5547
- return t && (s += ` title="${w(t)}"`), s += ">", s;
5574
+ let s = `<img src="${e}" alt="${T(n)}"`;
5575
+ return t && (s += ` title="${T(t)}"`), s += ">", s;
5548
5576
  }
5549
5577
  text(e) {
5550
- return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : w(e.text);
5578
+ return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : T(e.text);
5551
5579
  }
5552
5580
  };
5553
5581
  var $ = class {
@@ -5587,7 +5615,7 @@ var b = class u2 {
5587
5615
  __publicField(this, "options");
5588
5616
  __publicField(this, "renderer");
5589
5617
  __publicField(this, "textRenderer");
5590
- 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 $();
5618
+ this.options = e || O, 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 $();
5591
5619
  }
5592
5620
  static parse(e, t) {
5593
5621
  return new u2(t).parse(e);
@@ -5596,6 +5624,7 @@ var b = class u2 {
5596
5624
  return new u2(t).parseInline(e);
5597
5625
  }
5598
5626
  parse(e) {
5627
+ this.renderer.parser = this;
5599
5628
  let t = "";
5600
5629
  for (let n = 0; n < e.length; n++) {
5601
5630
  let r = e[n];
@@ -5666,6 +5695,7 @@ var b = class u2 {
5666
5695
  return t;
5667
5696
  }
5668
5697
  parseInline(e, t = this.renderer) {
5698
+ this.renderer.parser = this;
5669
5699
  let n = "";
5670
5700
  for (let r = 0; r < e.length; r++) {
5671
5701
  let i = e[r];
@@ -5733,11 +5763,11 @@ var b = class u2 {
5733
5763
  }
5734
5764
  };
5735
5765
  var _a;
5736
- var S = (_a = class {
5766
+ var P = (_a = class {
5737
5767
  constructor(e) {
5738
5768
  __publicField(this, "options");
5739
5769
  __publicField(this, "block");
5740
- this.options = e || T;
5770
+ this.options = e || O;
5741
5771
  }
5742
5772
  preprocess(e) {
5743
5773
  return e;
@@ -5751,25 +5781,25 @@ var S = (_a = class {
5751
5781
  emStrongMask(e) {
5752
5782
  return e;
5753
5783
  }
5754
- provideLexer() {
5755
- return this.block ? x.lex : x.lexInline;
5784
+ provideLexer(e = this.block) {
5785
+ return e ? x.lex : x.lexInline;
5756
5786
  }
5757
- provideParser() {
5758
- return this.block ? b.parse : b.parseInline;
5787
+ provideParser(e = this.block) {
5788
+ return e ? b.parse : b.parseInline;
5759
5789
  }
5760
5790
  }, __publicField(_a, "passThroughHooks", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens", "emStrongMask"])), __publicField(_a, "passThroughHooksRespectAsync", /* @__PURE__ */ new Set(["preprocess", "postprocess", "processAllTokens"])), _a);
5761
- var B = class {
5791
+ var D = class {
5762
5792
  constructor(...e) {
5763
- __publicField(this, "defaults", L());
5793
+ __publicField(this, "defaults", M());
5764
5794
  __publicField(this, "options", this.setOptions);
5765
5795
  __publicField(this, "parse", this.parseMarkdown(true));
5766
5796
  __publicField(this, "parseInline", this.parseMarkdown(false));
5767
5797
  __publicField(this, "Parser", b);
5768
- __publicField(this, "Renderer", P);
5798
+ __publicField(this, "Renderer", y);
5769
5799
  __publicField(this, "TextRenderer", $);
5770
5800
  __publicField(this, "Lexer", x);
5771
- __publicField(this, "Tokenizer", y);
5772
- __publicField(this, "Hooks", S);
5801
+ __publicField(this, "Tokenizer", w);
5802
+ __publicField(this, "Hooks", P);
5773
5803
  this.use(...e);
5774
5804
  }
5775
5805
  walkTokens(e, t) {
@@ -5816,7 +5846,7 @@ var B = class {
5816
5846
  }
5817
5847
  "childTokens" in i && i.childTokens && (t.childTokens[i.name] = i.childTokens);
5818
5848
  }), r.extensions = t), n.renderer) {
5819
- let i = this.defaults.renderer || new P(this.defaults);
5849
+ let i = this.defaults.renderer || new y(this.defaults);
5820
5850
  for (let s in n.renderer) {
5821
5851
  if (!(s in i)) throw new Error(`renderer '${s}' does not exist`);
5822
5852
  if (["options", "parser"].includes(s)) continue;
@@ -5829,7 +5859,7 @@ var B = class {
5829
5859
  r.renderer = i;
5830
5860
  }
5831
5861
  if (n.tokenizer) {
5832
- let i = this.defaults.tokenizer || new y(this.defaults);
5862
+ let i = this.defaults.tokenizer || new w(this.defaults);
5833
5863
  for (let s in n.tokenizer) {
5834
5864
  if (!(s in i)) throw new Error(`tokenizer '${s}' does not exist`);
5835
5865
  if (["options", "rules", "lexer"].includes(s)) continue;
@@ -5842,22 +5872,22 @@ var B = class {
5842
5872
  r.tokenizer = i;
5843
5873
  }
5844
5874
  if (n.hooks) {
5845
- let i = this.defaults.hooks || new S();
5875
+ let i = this.defaults.hooks || new P();
5846
5876
  for (let s in n.hooks) {
5847
5877
  if (!(s in i)) throw new Error(`hook '${s}' does not exist`);
5848
5878
  if (["options", "block"].includes(s)) continue;
5849
5879
  let a = s, o = n.hooks[a], l = i[a];
5850
- S.passThroughHooks.has(s) ? i[a] = (p) => {
5851
- if (this.defaults.async && S.passThroughHooksRespectAsync.has(s)) return (async () => {
5852
- let g = await o.call(i, p);
5853
- return l.call(i, g);
5880
+ P.passThroughHooks.has(s) ? i[a] = (p) => {
5881
+ if (this.defaults.async && P.passThroughHooksRespectAsync.has(s)) return (async () => {
5882
+ let d = await o.call(i, p);
5883
+ return l.call(i, d);
5854
5884
  })();
5855
5885
  let c = o.call(i, p);
5856
5886
  return l.call(i, c);
5857
5887
  } : i[a] = (...p) => {
5858
5888
  if (this.defaults.async) return (async () => {
5859
- let g = await o.apply(i, p);
5860
- return g === false && (g = await l.apply(i, p)), g;
5889
+ let d = await o.apply(i, p);
5890
+ return d === false && (d = await l.apply(i, p)), d;
5861
5891
  })();
5862
5892
  let c = o.apply(i, p);
5863
5893
  return c === false && (c = l.apply(i, p)), c;
@@ -5891,16 +5921,16 @@ var B = class {
5891
5921
  if (typeof n > "u" || n === null) return a(new Error("marked(): input parameter is undefined or null"));
5892
5922
  if (typeof n != "string") return a(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(n) + ", string expected"));
5893
5923
  if (s.hooks && (s.hooks.options = s, s.hooks.block = e), s.async) return (async () => {
5894
- let o = s.hooks ? await s.hooks.preprocess(n) : n, p = await (s.hooks ? await s.hooks.provideLexer() : e ? x.lex : x.lexInline)(o, s), c = s.hooks ? await s.hooks.processAllTokens(p) : p;
5924
+ let o = s.hooks ? await s.hooks.preprocess(n) : n, p = await (s.hooks ? await s.hooks.provideLexer(e) : e ? x.lex : x.lexInline)(o, s), c = s.hooks ? await s.hooks.processAllTokens(p) : p;
5895
5925
  s.walkTokens && await Promise.all(this.walkTokens(c, s.walkTokens));
5896
- let h = await (s.hooks ? await s.hooks.provideParser() : e ? b.parse : b.parseInline)(c, s);
5926
+ let h = await (s.hooks ? await s.hooks.provideParser(e) : e ? b.parse : b.parseInline)(c, s);
5897
5927
  return s.hooks ? await s.hooks.postprocess(h) : h;
5898
5928
  })().catch(a);
5899
5929
  try {
5900
5930
  s.hooks && (n = s.hooks.preprocess(n));
5901
- let l = (s.hooks ? s.hooks.provideLexer() : e ? x.lex : x.lexInline)(n, s);
5931
+ let l = (s.hooks ? s.hooks.provideLexer(e) : e ? x.lex : x.lexInline)(n, s);
5902
5932
  s.hooks && (l = s.hooks.processAllTokens(l)), s.walkTokens && this.walkTokens(l, s.walkTokens);
5903
- let c = (s.hooks ? s.hooks.provideParser() : e ? b.parse : b.parseInline)(l, s);
5933
+ let c = (s.hooks ? s.hooks.provideParser(e) : e ? b.parse : b.parseInline)(l, s);
5904
5934
  return s.hooks && (c = s.hooks.postprocess(c)), c;
5905
5935
  } catch (o) {
5906
5936
  return a(o);
@@ -5911,7 +5941,7 @@ var B = class {
5911
5941
  return (n) => {
5912
5942
  if (n.message += `
5913
5943
  Please report this to https://github.com/markedjs/marked.`, e) {
5914
- let r = "<p>An error occurred:</p><pre>" + w(n.message + "", true) + "</pre>";
5944
+ let r = "<p>An error occurred:</p><pre>" + T(n.message + "", true) + "</pre>";
5915
5945
  return t ? Promise.resolve(r) : r;
5916
5946
  }
5917
5947
  if (t) return Promise.reject(n);
@@ -5919,44 +5949,44 @@ Please report this to https://github.com/markedjs/marked.`, e) {
5919
5949
  };
5920
5950
  }
5921
5951
  };
5922
- var _ = new B();
5923
- function d(u3, e) {
5924
- return _.parse(u3, e);
5952
+ var L = new D();
5953
+ function g(u3, e) {
5954
+ return L.parse(u3, e);
5925
5955
  }
5926
- d.options = d.setOptions = function(u3) {
5927
- return _.setOptions(u3), d.defaults = _.defaults, Z(d.defaults), d;
5956
+ g.options = g.setOptions = function(u3) {
5957
+ return L.setOptions(u3), g.defaults = L.defaults, G(g.defaults), g;
5928
5958
  };
5929
- d.getDefaults = L;
5930
- d.defaults = T;
5931
- d.use = function(...u3) {
5932
- return _.use(...u3), d.defaults = _.defaults, Z(d.defaults), d;
5959
+ g.getDefaults = M;
5960
+ g.defaults = O;
5961
+ g.use = function(...u3) {
5962
+ return L.use(...u3), g.defaults = L.defaults, G(g.defaults), g;
5933
5963
  };
5934
- d.walkTokens = function(u3, e) {
5935
- return _.walkTokens(u3, e);
5964
+ g.walkTokens = function(u3, e) {
5965
+ return L.walkTokens(u3, e);
5936
5966
  };
5937
- d.parseInline = _.parseInline;
5938
- d.Parser = b;
5939
- d.parser = b.parse;
5940
- d.Renderer = P;
5941
- d.TextRenderer = $;
5942
- d.Lexer = x;
5943
- d.lexer = x.lex;
5944
- d.Tokenizer = y;
5945
- d.Hooks = S;
5946
- d.parse = d;
5947
- d.options;
5948
- d.setOptions;
5949
- d.use;
5950
- d.walkTokens;
5951
- d.parseInline;
5967
+ g.parseInline = L.parseInline;
5968
+ g.Parser = b;
5969
+ g.parser = b.parse;
5970
+ g.Renderer = y;
5971
+ g.TextRenderer = $;
5972
+ g.Lexer = x;
5973
+ g.lexer = x.lex;
5974
+ g.Tokenizer = w;
5975
+ g.Hooks = P;
5976
+ g.parse = g;
5977
+ g.options;
5978
+ g.setOptions;
5979
+ g.use;
5980
+ g.walkTokens;
5981
+ g.parseInline;
5952
5982
  b.parse;
5953
5983
  x.lex;
5954
5984
 
5955
- // node_modules/highlight.js/es/core.js
5985
+ // ../../node_modules/highlight.js/es/core.js
5956
5986
  var import_core = __toESM(require_core());
5957
5987
  var core_default = import_core.default;
5958
5988
 
5959
- // node_modules/highlight.js/es/languages/javascript.js
5989
+ // ../../node_modules/highlight.js/es/languages/javascript.js
5960
5990
  var IDENT_RE = "[A-Za-z$_][0-9A-Za-z$_]*";
5961
5991
  var KEYWORDS = [
5962
5992
  "as",
@@ -6657,7 +6687,7 @@ function javascript(hljs) {
6657
6687
  };
6658
6688
  }
6659
6689
 
6660
- // node_modules/highlight.js/es/languages/typescript.js
6690
+ // ../../node_modules/highlight.js/es/languages/typescript.js
6661
6691
  var IDENT_RE2 = "[A-Za-z$_][0-9A-Za-z$_]*";
6662
6692
  var KEYWORDS2 = [
6663
6693
  "as",
@@ -7471,7 +7501,7 @@ function typescript(hljs) {
7471
7501
  return tsLanguage;
7472
7502
  }
7473
7503
 
7474
- // node_modules/highlight.js/es/languages/python.js
7504
+ // ../../node_modules/highlight.js/es/languages/python.js
7475
7505
  function python(hljs) {
7476
7506
  const regex = hljs.regex;
7477
7507
  const IDENT_RE3 = /[\p{XID_Start}_]\p{XID_Continue}*/u;
@@ -7886,7 +7916,7 @@ function python(hljs) {
7886
7916
  };
7887
7917
  }
7888
7918
 
7889
- // node_modules/highlight.js/es/languages/json.js
7919
+ // ../../node_modules/highlight.js/es/languages/json.js
7890
7920
  function json(hljs) {
7891
7921
  const ATTRIBUTE = {
7892
7922
  className: "attr",
@@ -7926,7 +7956,7 @@ function json(hljs) {
7926
7956
  };
7927
7957
  }
7928
7958
 
7929
- // node_modules/highlight.js/es/languages/bash.js
7959
+ // ../../node_modules/highlight.js/es/languages/bash.js
7930
7960
  function bash(hljs) {
7931
7961
  const regex = hljs.regex;
7932
7962
  const VAR = {};
@@ -8320,7 +8350,7 @@ function bash(hljs) {
8320
8350
  };
8321
8351
  }
8322
8352
 
8323
- // node_modules/highlight.js/es/languages/shell.js
8353
+ // ../../node_modules/highlight.js/es/languages/shell.js
8324
8354
  function shell(hljs) {
8325
8355
  return {
8326
8356
  name: "Shell Session",
@@ -8344,7 +8374,7 @@ function shell(hljs) {
8344
8374
  };
8345
8375
  }
8346
8376
 
8347
- // node_modules/highlight.js/es/languages/css.js
8377
+ // ../../node_modules/highlight.js/es/languages/css.js
8348
8378
  var MODES = (hljs) => {
8349
8379
  return {
8350
8380
  IMPORTANT: {
@@ -9281,7 +9311,7 @@ function css(hljs) {
9281
9311
  };
9282
9312
  }
9283
9313
 
9284
- // node_modules/highlight.js/es/languages/xml.js
9314
+ // ../../node_modules/highlight.js/es/languages/xml.js
9285
9315
  function xml(hljs) {
9286
9316
  const regex = hljs.regex;
9287
9317
  const TAG_NAME_RE = regex.concat(/[\p{L}_]/u, regex.optional(/[\p{L}0-9_.-]*:/u), /[\p{L}0-9_.-]*/u);
@@ -9507,7 +9537,7 @@ function xml(hljs) {
9507
9537
  };
9508
9538
  }
9509
9539
 
9510
- // node_modules/highlight.js/es/languages/markdown.js
9540
+ // ../../node_modules/highlight.js/es/languages/markdown.js
9511
9541
  function markdown(hljs) {
9512
9542
  const regex = hljs.regex;
9513
9543
  const INLINE_HTML = {
@@ -9739,7 +9769,7 @@ function markdown(hljs) {
9739
9769
  };
9740
9770
  }
9741
9771
 
9742
- // node_modules/highlight.js/es/languages/sql.js
9772
+ // ../../node_modules/highlight.js/es/languages/sql.js
9743
9773
  function sql(hljs) {
9744
9774
  const regex = hljs.regex;
9745
9775
  const COMMENT_MODE = hljs.COMMENT("--", "$");
@@ -10382,7 +10412,7 @@ function sql(hljs) {
10382
10412
  };
10383
10413
  }
10384
10414
 
10385
- // node_modules/highlight.js/es/languages/yaml.js
10415
+ // ../../node_modules/highlight.js/es/languages/yaml.js
10386
10416
  function yaml(hljs) {
10387
10417
  const LITERALS3 = "true false yes no null";
10388
10418
  const URI_CHARACTERS = "[\\w#;/?:@&=+$,.~*'()[\\]]+";
@@ -10583,7 +10613,7 @@ function yaml(hljs) {
10583
10613
  };
10584
10614
  }
10585
10615
 
10586
- // node_modules/highlight.js/es/languages/rust.js
10616
+ // ../../node_modules/highlight.js/es/languages/rust.js
10587
10617
  function rust(hljs) {
10588
10618
  const regex = hljs.regex;
10589
10619
  const RAW_IDENTIFIER = /(r#)?/;
@@ -10896,7 +10926,7 @@ function rust(hljs) {
10896
10926
  };
10897
10927
  }
10898
10928
 
10899
- // node_modules/highlight.js/es/languages/go.js
10929
+ // ../../node_modules/highlight.js/es/languages/go.js
10900
10930
  function go(hljs) {
10901
10931
  const LITERALS3 = [
10902
10932
  "true",
@@ -11050,7 +11080,7 @@ function go(hljs) {
11050
11080
  };
11051
11081
  }
11052
11082
 
11053
- // node_modules/highlight.js/es/languages/java.js
11083
+ // ../../node_modules/highlight.js/es/languages/java.js
11054
11084
  var decimalDigits = "[0-9](_*[0-9])*";
11055
11085
  var frac = `\\.(${decimalDigits})`;
11056
11086
  var hexDigits = "[0-9a-fA-F](_*[0-9a-fA-F])*";
@@ -11304,7 +11334,7 @@ function java(hljs) {
11304
11334
  };
11305
11335
  }
11306
11336
 
11307
- // node_modules/highlight.js/es/languages/cpp.js
11337
+ // ../../node_modules/highlight.js/es/languages/cpp.js
11308
11338
  function cpp(hljs) {
11309
11339
  const regex = hljs.regex;
11310
11340
  const C_LINE_COMMENT_MODE = hljs.COMMENT("//", "$", { contains: [{ begin: /\\\n/ }] });
@@ -11847,7 +11877,7 @@ function cpp(hljs) {
11847
11877
  };
11848
11878
  }
11849
11879
 
11850
- // node_modules/highlight.js/es/languages/csharp.js
11880
+ // ../../node_modules/highlight.js/es/languages/csharp.js
11851
11881
  function csharp(hljs) {
11852
11882
  const BUILT_IN_KEYWORDS = [
11853
11883
  "bool",
@@ -12247,7 +12277,7 @@ function csharp(hljs) {
12247
12277
  };
12248
12278
  }
12249
12279
 
12250
- // node_modules/highlight.js/es/languages/php.js
12280
+ // ../../node_modules/highlight.js/es/languages/php.js
12251
12281
  function php(hljs) {
12252
12282
  const regex = hljs.regex;
12253
12283
  const NOT_PERL_ETC = /(?![A-Za-z0-9])(?![$])/;
@@ -12848,7 +12878,7 @@ function php(hljs) {
12848
12878
  };
12849
12879
  }
12850
12880
 
12851
- // node_modules/highlight.js/es/languages/ruby.js
12881
+ // ../../node_modules/highlight.js/es/languages/ruby.js
12852
12882
  function ruby(hljs) {
12853
12883
  const regex = hljs.regex;
12854
12884
  const RUBY_METHOD_RE = "([a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?)";
@@ -13261,7 +13291,7 @@ function ruby(hljs) {
13261
13291
  };
13262
13292
  }
13263
13293
 
13264
- // node_modules/highlight.js/es/languages/swift.js
13294
+ // ../../node_modules/highlight.js/es/languages/swift.js
13265
13295
  function source(re2) {
13266
13296
  if (!re2) return null;
13267
13297
  if (typeof re2 === "string") return re2;
@@ -14136,7 +14166,7 @@ function swift(hljs) {
14136
14166
  };
14137
14167
  }
14138
14168
 
14139
- // node_modules/highlight.js/es/languages/kotlin.js
14169
+ // ../../node_modules/highlight.js/es/languages/kotlin.js
14140
14170
  var decimalDigits2 = "[0-9](_*[0-9])*";
14141
14171
  var frac2 = `\\.(${decimalDigits2})`;
14142
14172
  var hexDigits2 = "[0-9a-fA-F](_*[0-9a-fA-F])*";
@@ -14606,7 +14636,7 @@ var scopedStyles = `
14606
14636
  font-style: italic;
14607
14637
  }
14608
14638
  `;
14609
- d.use({
14639
+ g.use({
14610
14640
  gfm: true,
14611
14641
  breaks: false
14612
14642
  });
@@ -14628,7 +14658,7 @@ function generateCodeBlockId() {
14628
14658
  return `code-block-${++codeBlockCounter}`;
14629
14659
  }
14630
14660
  function renderMarkdown(content) {
14631
- const html = d.parse(content, { async: false });
14661
+ const html = g.parse(content, { async: false });
14632
14662
  const codeBlockRegex = /<pre><code class="language-(\w+)">([\s\S]*?)<\/code><\/pre>/g;
14633
14663
  let result = html.replace(codeBlockRegex, (_2, lang, code2) => {
14634
14664
  const decoded = code2.replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&amp;/g, "&").replace(/&quot;/g, '"');