@flytedan/flytebot-design-system 0.70.0 → 0.71.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-CGCQNBCR.js +42 -0
- package/dist/chunk-CGCQNBCR.js.map +1 -0
- package/dist/index.cjs +23 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -7
- package/dist/index.d.ts +12 -7
- package/dist/index.js +5 -7
- package/dist/index.js.map +1 -1
- package/dist/markdown.cjs +30 -2
- package/dist/markdown.cjs.map +1 -1
- package/dist/markdown.d.cts +7 -1
- package/dist/markdown.d.ts +7 -1
- package/dist/markdown.js +5 -3
- package/package.json +9 -1
- package/dist/chunk-OVTWSE43.js +0 -21
- package/dist/chunk-OVTWSE43.js.map +0 -1
package/dist/markdown.cjs
CHANGED
|
@@ -20,19 +20,47 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
20
20
|
// src/markdown.ts
|
|
21
21
|
var markdown_exports = {};
|
|
22
22
|
__export(markdown_exports, {
|
|
23
|
-
escapeMarkdown: () => escapeMarkdown
|
|
23
|
+
escapeMarkdown: () => escapeMarkdown,
|
|
24
|
+
markdownToText: () => markdownToText
|
|
24
25
|
});
|
|
25
26
|
module.exports = __toCommonJS(markdown_exports);
|
|
26
27
|
|
|
27
28
|
// src/components/data/markdownEscape.ts
|
|
29
|
+
var ESCAPABLE = /\\([!-/:-@[-`{-~])/g;
|
|
30
|
+
var STAND_IN_BASE = 57344;
|
|
31
|
+
var STAND_IN = /[-]/g;
|
|
32
|
+
var hideEscapes = (s) => s.replace(STAND_IN, "\uFFFD").replace(ESCAPABLE, (_, c) => String.fromCharCode(STAND_IN_BASE + c.charCodeAt(0)));
|
|
33
|
+
var showEscapes = (s) => s.replace(STAND_IN, (c) => String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));
|
|
34
|
+
var showEscapesRaw = (s) => s.replace(STAND_IN, (c) => "\\" + String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));
|
|
28
35
|
function escapeMarkdown(text) {
|
|
29
36
|
return String(text == null ? "" : text).replace(/\r\n?/g, "\n").replace(/[\\`*_[\]()<>!|~^]/g, "\\$&").replace(/\b(https?|mailto|tel):/gi, "$1\\:").split("\n").map(
|
|
30
37
|
(line) => line.replace(/^(\s*)([#>+-])/, "$1\\$2").replace(/^(\s*\d{1,9})([.)])/, "$1\\$2")
|
|
31
38
|
// task item `[ ]` is already covered by escaping `[`
|
|
32
39
|
).join("\n");
|
|
33
40
|
}
|
|
41
|
+
var TABLE_ROW = /^\s*\|.*\|\s*$/;
|
|
42
|
+
var TABLE_SEPARATOR = /^\s*\|(\s*:?-{3,}:?\s*\|)+\s*$/;
|
|
43
|
+
var LIST_MARKER = /^\s*(?:[-*+]|\d{1,9}[.)])\s+/;
|
|
44
|
+
function stripBlockSyntax(s) {
|
|
45
|
+
let inFence = false;
|
|
46
|
+
return s.split("\n").flatMap((line) => {
|
|
47
|
+
if (/^\s*```/.test(line)) inFence = !inFence;
|
|
48
|
+
if (inFence || /^\s*```/.test(line)) return [line];
|
|
49
|
+
if (TABLE_SEPARATOR.test(line)) return [];
|
|
50
|
+
if (TABLE_ROW.test(line)) {
|
|
51
|
+
return [line.trim().slice(1, -1).split("|").map((c) => c.trim()).filter(Boolean).join(" ")];
|
|
52
|
+
}
|
|
53
|
+
return [line.replace(LIST_MARKER, "")];
|
|
54
|
+
}).join("\n");
|
|
55
|
+
}
|
|
56
|
+
function markdownToText(src) {
|
|
57
|
+
return showEscapes(
|
|
58
|
+
stripBlockSyntax(hideEscapes(String(src == null ? "" : src))).replace(/```[\w+#-]*\n?([\s\S]*?)```/g, (_, c) => showEscapesRaw(c)).replace(/`([^`]+)`/g, (_, c) => showEscapesRaw(c)).replace(/!\[([^\]]*)\]\([^)]*\)/g, "$1").replace(/\[([^\]]+)\]\([^)]*\)/g, "$1").replace(/^\s{0,3}#{1,6}\s+/gm, "").replace(/\*\*\*([^*]+)\*\*\*|\*\*([^*]+)\*\*|__([^_]+)__/g, "$1$2$3").replace(/(^|\W)[*_]([^*_\n]+)[*_](\W|$)/g, "$1$2$3").replace(/~~([^~]+)~~/g, "$1").replace(/^\s*>\s?/gm, "").trim()
|
|
59
|
+
);
|
|
60
|
+
}
|
|
34
61
|
// Annotate the CommonJS export names for ESM import in node:
|
|
35
62
|
0 && (module.exports = {
|
|
36
|
-
escapeMarkdown
|
|
63
|
+
escapeMarkdown,
|
|
64
|
+
markdownToText
|
|
37
65
|
});
|
|
38
66
|
//# sourceMappingURL=markdown.cjs.map
|
package/dist/markdown.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/markdown.ts","../src/components/data/markdownEscape.ts"],"sourcesContent":["// React-free entry (`@flytedan/flytebot-design-system/markdown`): safe to import on a server.\nexport { escapeMarkdown } from \"./components/data/markdownEscape\";\n","/* DS-7: the one definition of the markdown escape rule, shared by the renderer\n (Markdown.tsx) and by `escapeMarkdown` (a React-free entry, so a server can import it). */\n\n/** CommonMark: a backslash before any ASCII punctuation character makes it literal. */\nexport const ESCAPABLE = /\\\\([!-/:-@[-`{-~])/g;\n\n/* An escaped character is swapped for a private-use stand-in (U+E000 + its code) before any\n syntax pattern runs, so no pattern can see it, then swapped back where text is emitted. */\nconst STAND_IN_BASE = 0xe000;\nconst STAND_IN = /[-]/g;\n\n/** Hide every escaped character from the syntax patterns. Stray stand-ins already in the input are neutralised first. */\nexport const hideEscapes = (s: string): string =>\n s.replace(STAND_IN, \"�\").replace(ESCAPABLE, (_, c: string) => String.fromCharCode(STAND_IN_BASE + c.charCodeAt(0)));\n\n/** Put escaped characters back as the literal character. */\nexport const showEscapes = (s: string): string => s.replace(STAND_IN, (c) => String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/** Put escaped characters back with their backslash (a code span keeps its source verbatim). */\nexport const showEscapesRaw = (s: string): string => s.replace(STAND_IN, (c) => \"\\\\\" + String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/**\n * Backslash-escape text so `Markdown` / `MarkdownInline` render it as exactly that text:\n * every character the renderer reads as inline syntax, the `:` that starts a bare-URL or\n * mailto autolink, and any block marker (heading, quote, list, rule, table, fence) at the\n * start of a line.\n */\nexport function escapeMarkdown(text: string): string {\n return String(text == null ? \"\" : text)\n .replace(/\\r\\n?/g, \"\\n\")\n .replace(/[\\\\`*_[\\]()<>!|~^]/g, \"\\\\$&\")\n .replace(/\\b(https?|mailto|tel):/gi, \"$1\\\\:\")\n .split(\"\\n\")\n .map((line) =>\n line\n // heading, quote, bullet, rule, fence-like markers: escape the first marker character\n .replace(/^(\\s*)([#>+-])/, \"$1\\\\$2\")\n // ordered list: escape the dot or paren after the number\n .replace(/^(\\s*\\d{1,9})([.)])/, \"$1\\\\$2\")\n // task item `[ ]` is already covered by escaping `[`\n )\n .join(\"\\n\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;
|
|
1
|
+
{"version":3,"sources":["../src/markdown.ts","../src/components/data/markdownEscape.ts"],"sourcesContent":["// React-free entry (`@flytedan/flytebot-design-system/markdown`): safe to import on a server.\nexport { escapeMarkdown, markdownToText } from \"./components/data/markdownEscape\";\n","/* DS-7: the one definition of the markdown escape rule, shared by the renderer\n (Markdown.tsx) and by `escapeMarkdown` (a React-free entry, so a server can import it). */\n\n/** CommonMark: a backslash before any ASCII punctuation character makes it literal. */\nexport const ESCAPABLE = /\\\\([!-/:-@[-`{-~])/g;\n\n/* An escaped character is swapped for a private-use stand-in (U+E000 + its code) before any\n syntax pattern runs, so no pattern can see it, then swapped back where text is emitted. */\nconst STAND_IN_BASE = 0xe000;\nconst STAND_IN = /[-]/g;\n\n/** Hide every escaped character from the syntax patterns. Stray stand-ins already in the input are neutralised first. */\nexport const hideEscapes = (s: string): string =>\n s.replace(STAND_IN, \"�\").replace(ESCAPABLE, (_, c: string) => String.fromCharCode(STAND_IN_BASE + c.charCodeAt(0)));\n\n/** Put escaped characters back as the literal character. */\nexport const showEscapes = (s: string): string => s.replace(STAND_IN, (c) => String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/** Put escaped characters back with their backslash (a code span keeps its source verbatim). */\nexport const showEscapesRaw = (s: string): string => s.replace(STAND_IN, (c) => \"\\\\\" + String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/**\n * Backslash-escape text so `Markdown` / `MarkdownInline` render it as exactly that text:\n * every character the renderer reads as inline syntax, the `:` that starts a bare-URL or\n * mailto autolink, and any block marker (heading, quote, list, rule, table, fence) at the\n * start of a line.\n */\nexport function escapeMarkdown(text: string): string {\n return String(text == null ? \"\" : text)\n .replace(/\\r\\n?/g, \"\\n\")\n .replace(/[\\\\`*_[\\]()<>!|~^]/g, \"\\\\$&\")\n .replace(/\\b(https?|mailto|tel):/gi, \"$1\\\\:\")\n .split(\"\\n\")\n .map((line) =>\n line\n // heading, quote, bullet, rule, fence-like markers: escape the first marker character\n .replace(/^(\\s*)([#>+-])/, \"$1\\\\$2\")\n // ordered list: escape the dot or paren after the number\n .replace(/^(\\s*\\d{1,9})([.)])/, \"$1\\\\$2\")\n // task item `[ ]` is already covered by escaping `[`\n )\n .join(\"\\n\");\n}\n\nconst TABLE_ROW = /^\\s*\\|.*\\|\\s*$/;\nconst TABLE_SEPARATOR = /^\\s*\\|(\\s*:?-{3,}:?\\s*\\|)+\\s*$/;\nconst LIST_MARKER = /^\\s*(?:[-*+]|\\d{1,9}[.)])\\s+/;\n\n/* DS-12: table pipes, the separator row and list markers are layout, not words. Escaped pipes\n and markers are already hidden, so they stay literal. Fenced code is left untouched. */\nfunction stripBlockSyntax(s: string): string {\n let inFence = false;\n return s\n .split(\"\\n\")\n .flatMap((line) => {\n if (/^\\s*```/.test(line)) inFence = !inFence;\n if (inFence || /^\\s*```/.test(line)) return [line];\n if (TABLE_SEPARATOR.test(line)) return [];\n if (TABLE_ROW.test(line)) {\n return [line.trim().slice(1, -1).split(\"|\").map((c) => c.trim()).filter(Boolean).join(\" \")];\n }\n return [line.replace(LIST_MARKER, \"\")];\n })\n .join(\"\\n\");\n}\n\n/**\n * Strip markdown to the plain text the renderer shows — for search, copy actions, titles and\n * previews. Escaped characters become literal text; only real syntax is removed, so\n * `markdownToText(escapeMarkdown(x)) === x`. A code span keeps its source verbatim.\n */\nexport function markdownToText(src: string): string {\n return showEscapes(\n stripBlockSyntax(hideEscapes(String(src == null ? \"\" : src)))\n .replace(/```[\\w+#-]*\\n?([\\s\\S]*?)```/g, (_, c: string) => showEscapesRaw(c))\n .replace(/`([^`]+)`/g, (_, c: string) => showEscapesRaw(c))\n .replace(/!\\[([^\\]]*)\\]\\([^)]*\\)/g, \"$1\")\n .replace(/\\[([^\\]]+)\\]\\([^)]*\\)/g, \"$1\")\n .replace(/^\\s{0,3}#{1,6}\\s+/gm, \"\")\n .replace(/\\*\\*\\*([^*]+)\\*\\*\\*|\\*\\*([^*]+)\\*\\*|__([^_]+)__/g, \"$1$2$3\")\n .replace(/(^|\\W)[*_]([^*_\\n]+)[*_](\\W|$)/g, \"$1$2$3\")\n .replace(/~~([^~]+)~~/g, \"$1\")\n .replace(/^\\s*>\\s?/gm, \"\")\n .trim(),\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACIO,IAAM,YAAY;AAIzB,IAAM,gBAAgB;AACtB,IAAM,WAAW;AAGV,IAAM,cAAc,CAAC,MAC1B,EAAE,QAAQ,UAAU,QAAG,EAAE,QAAQ,WAAW,CAAC,GAAG,MAAc,OAAO,aAAa,gBAAgB,EAAE,WAAW,CAAC,CAAC,CAAC;AAG7G,IAAM,cAAc,CAAC,MAAsB,EAAE,QAAQ,UAAU,CAAC,MAAM,OAAO,aAAa,EAAE,WAAW,CAAC,IAAI,aAAa,CAAC;AAG1H,IAAM,iBAAiB,CAAC,MAAsB,EAAE,QAAQ,UAAU,CAAC,MAAM,OAAO,OAAO,aAAa,EAAE,WAAW,CAAC,IAAI,aAAa,CAAC;AAQpI,SAAS,eAAe,MAAsB;AACnD,SAAO,OAAO,QAAQ,OAAO,KAAK,IAAI,EACnC,QAAQ,UAAU,IAAI,EACtB,QAAQ,uBAAuB,MAAM,EACrC,QAAQ,4BAA4B,OAAO,EAC3C,MAAM,IAAI,EACV;AAAA,IAAI,CAAC,SACJ,KAEG,QAAQ,kBAAkB,QAAQ,EAElC,QAAQ,uBAAuB,QAAQ;AAAA;AAAA,EAE5C,EACC,KAAK,IAAI;AACd;AAEA,IAAM,YAAY;AAClB,IAAM,kBAAkB;AACxB,IAAM,cAAc;AAIpB,SAAS,iBAAiB,GAAmB;AAC3C,MAAI,UAAU;AACd,SAAO,EACJ,MAAM,IAAI,EACV,QAAQ,CAAC,SAAS;AACjB,QAAI,UAAU,KAAK,IAAI,EAAG,WAAU,CAAC;AACrC,QAAI,WAAW,UAAU,KAAK,IAAI,EAAG,QAAO,CAAC,IAAI;AACjD,QAAI,gBAAgB,KAAK,IAAI,EAAG,QAAO,CAAC;AACxC,QAAI,UAAU,KAAK,IAAI,GAAG;AACxB,aAAO,CAAC,KAAK,KAAK,EAAE,MAAM,GAAG,EAAE,EAAE,MAAM,GAAG,EAAE,IAAI,CAAC,MAAM,EAAE,KAAK,CAAC,EAAE,OAAO,OAAO,EAAE,KAAK,GAAG,CAAC;AAAA,IAC5F;AACA,WAAO,CAAC,KAAK,QAAQ,aAAa,EAAE,CAAC;AAAA,EACvC,CAAC,EACA,KAAK,IAAI;AACd;AAOO,SAAS,eAAe,KAAqB;AAClD,SAAO;AAAA,IACL,iBAAiB,YAAY,OAAO,OAAO,OAAO,KAAK,GAAG,CAAC,CAAC,EACzD,QAAQ,gCAAgC,CAAC,GAAG,MAAc,eAAe,CAAC,CAAC,EAC3E,QAAQ,cAAc,CAAC,GAAG,MAAc,eAAe,CAAC,CAAC,EACzD,QAAQ,2BAA2B,IAAI,EACvC,QAAQ,0BAA0B,IAAI,EACtC,QAAQ,uBAAuB,EAAE,EACjC,QAAQ,oDAAoD,QAAQ,EACpE,QAAQ,mCAAmC,QAAQ,EACnD,QAAQ,gBAAgB,IAAI,EAC5B,QAAQ,cAAc,EAAE,EACxB,KAAK;AAAA,EACV;AACF;","names":[]}
|
package/dist/markdown.d.cts
CHANGED
|
@@ -5,5 +5,11 @@
|
|
|
5
5
|
* start of a line.
|
|
6
6
|
*/
|
|
7
7
|
declare function escapeMarkdown(text: string): string;
|
|
8
|
+
/**
|
|
9
|
+
* Strip markdown to the plain text the renderer shows — for search, copy actions, titles and
|
|
10
|
+
* previews. Escaped characters become literal text; only real syntax is removed, so
|
|
11
|
+
* `markdownToText(escapeMarkdown(x)) === x`. A code span keeps its source verbatim.
|
|
12
|
+
*/
|
|
13
|
+
declare function markdownToText(src: string): string;
|
|
8
14
|
|
|
9
|
-
export { escapeMarkdown };
|
|
15
|
+
export { escapeMarkdown, markdownToText };
|
package/dist/markdown.d.ts
CHANGED
|
@@ -5,5 +5,11 @@
|
|
|
5
5
|
* start of a line.
|
|
6
6
|
*/
|
|
7
7
|
declare function escapeMarkdown(text: string): string;
|
|
8
|
+
/**
|
|
9
|
+
* Strip markdown to the plain text the renderer shows — for search, copy actions, titles and
|
|
10
|
+
* previews. Escaped characters become literal text; only real syntax is removed, so
|
|
11
|
+
* `markdownToText(escapeMarkdown(x)) === x`. A code span keeps its source verbatim.
|
|
12
|
+
*/
|
|
13
|
+
declare function markdownToText(src: string): string;
|
|
8
14
|
|
|
9
|
-
export { escapeMarkdown };
|
|
15
|
+
export { escapeMarkdown, markdownToText };
|
package/dist/markdown.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@flytedan/flytebot-design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.71.1",
|
|
4
4
|
"description": "flytedesk Design System — shared component library, tokens, and business-logic kits for flytedesk apps.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "UNLICENSED",
|
|
@@ -60,6 +60,14 @@
|
|
|
60
60
|
"react": "^18.3.1",
|
|
61
61
|
"react-dom": "^18.3.1"
|
|
62
62
|
},
|
|
63
|
+
"peerDependenciesMeta": {
|
|
64
|
+
"react": {
|
|
65
|
+
"optional": true
|
|
66
|
+
},
|
|
67
|
+
"react-dom": {
|
|
68
|
+
"optional": true
|
|
69
|
+
}
|
|
70
|
+
},
|
|
63
71
|
"dependencies": {
|
|
64
72
|
"@codemirror/commands": "^6.11.1",
|
|
65
73
|
"@codemirror/lang-sql": "^6.10.0",
|
package/dist/chunk-OVTWSE43.js
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
// src/components/data/markdownEscape.ts
|
|
2
|
-
var ESCAPABLE = /\\([!-/:-@[-`{-~])/g;
|
|
3
|
-
var STAND_IN_BASE = 57344;
|
|
4
|
-
var STAND_IN = /[-]/g;
|
|
5
|
-
var hideEscapes = (s) => s.replace(STAND_IN, "\uFFFD").replace(ESCAPABLE, (_, c) => String.fromCharCode(STAND_IN_BASE + c.charCodeAt(0)));
|
|
6
|
-
var showEscapes = (s) => s.replace(STAND_IN, (c) => String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));
|
|
7
|
-
var showEscapesRaw = (s) => s.replace(STAND_IN, (c) => "\\" + String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));
|
|
8
|
-
function escapeMarkdown(text) {
|
|
9
|
-
return String(text == null ? "" : text).replace(/\r\n?/g, "\n").replace(/[\\`*_[\]()<>!|~^]/g, "\\$&").replace(/\b(https?|mailto|tel):/gi, "$1\\:").split("\n").map(
|
|
10
|
-
(line) => line.replace(/^(\s*)([#>+-])/, "$1\\$2").replace(/^(\s*\d{1,9})([.)])/, "$1\\$2")
|
|
11
|
-
// task item `[ ]` is already covered by escaping `[`
|
|
12
|
-
).join("\n");
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export {
|
|
16
|
-
hideEscapes,
|
|
17
|
-
showEscapes,
|
|
18
|
-
showEscapesRaw,
|
|
19
|
-
escapeMarkdown
|
|
20
|
-
};
|
|
21
|
-
//# sourceMappingURL=chunk-OVTWSE43.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/data/markdownEscape.ts"],"sourcesContent":["/* DS-7: the one definition of the markdown escape rule, shared by the renderer\n (Markdown.tsx) and by `escapeMarkdown` (a React-free entry, so a server can import it). */\n\n/** CommonMark: a backslash before any ASCII punctuation character makes it literal. */\nexport const ESCAPABLE = /\\\\([!-/:-@[-`{-~])/g;\n\n/* An escaped character is swapped for a private-use stand-in (U+E000 + its code) before any\n syntax pattern runs, so no pattern can see it, then swapped back where text is emitted. */\nconst STAND_IN_BASE = 0xe000;\nconst STAND_IN = /[-]/g;\n\n/** Hide every escaped character from the syntax patterns. Stray stand-ins already in the input are neutralised first. */\nexport const hideEscapes = (s: string): string =>\n s.replace(STAND_IN, \"�\").replace(ESCAPABLE, (_, c: string) => String.fromCharCode(STAND_IN_BASE + c.charCodeAt(0)));\n\n/** Put escaped characters back as the literal character. */\nexport const showEscapes = (s: string): string => s.replace(STAND_IN, (c) => String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/** Put escaped characters back with their backslash (a code span keeps its source verbatim). */\nexport const showEscapesRaw = (s: string): string => s.replace(STAND_IN, (c) => \"\\\\\" + String.fromCharCode(c.charCodeAt(0) - STAND_IN_BASE));\n\n/**\n * Backslash-escape text so `Markdown` / `MarkdownInline` render it as exactly that text:\n * every character the renderer reads as inline syntax, the `:` that starts a bare-URL or\n * mailto autolink, and any block marker (heading, quote, list, rule, table, fence) at the\n * start of a line.\n */\nexport function escapeMarkdown(text: string): string {\n return String(text == null ? \"\" : text)\n .replace(/\\r\\n?/g, \"\\n\")\n .replace(/[\\\\`*_[\\]()<>!|~^]/g, \"\\\\$&\")\n .replace(/\\b(https?|mailto|tel):/gi, \"$1\\\\:\")\n .split(\"\\n\")\n .map((line) =>\n line\n // heading, quote, bullet, rule, fence-like markers: escape the first marker character\n .replace(/^(\\s*)([#>+-])/, \"$1\\\\$2\")\n // ordered list: escape the dot or paren after the number\n .replace(/^(\\s*\\d{1,9})([.)])/, \"$1\\\\$2\")\n // task item `[ ]` is already covered by escaping `[`\n )\n .join(\"\\n\");\n}\n"],"mappings":";AAIO,IAAM,YAAY;AAIzB,IAAM,gBAAgB;AACtB,IAAM,WAAW;AAGV,IAAM,cAAc,CAAC,MAC1B,EAAE,QAAQ,UAAU,QAAG,EAAE,QAAQ,WAAW,CAAC,GAAG,MAAc,OAAO,aAAa,gBAAgB,EAAE,WAAW,CAAC,CAAC,CAAC;AAG7G,IAAM,cAAc,CAAC,MAAsB,EAAE,QAAQ,UAAU,CAAC,MAAM,OAAO,aAAa,EAAE,WAAW,CAAC,IAAI,aAAa,CAAC;AAG1H,IAAM,iBAAiB,CAAC,MAAsB,EAAE,QAAQ,UAAU,CAAC,MAAM,OAAO,OAAO,aAAa,EAAE,WAAW,CAAC,IAAI,aAAa,CAAC;AAQpI,SAAS,eAAe,MAAsB;AACnD,SAAO,OAAO,QAAQ,OAAO,KAAK,IAAI,EACnC,QAAQ,UAAU,IAAI,EACtB,QAAQ,uBAAuB,MAAM,EACrC,QAAQ,4BAA4B,OAAO,EAC3C,MAAM,IAAI,EACV;AAAA,IAAI,CAAC,SACJ,KAEG,QAAQ,kBAAkB,QAAQ,EAElC,QAAQ,uBAAuB,QAAQ;AAAA;AAAA,EAE5C,EACC,KAAK,IAAI;AACd;","names":[]}
|