wecool-chat 0.8.0 → 0.10.0

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.
Files changed (227) hide show
  1. package/CHANGELOG.md +83 -0
  2. package/README.ja.md +234 -20
  3. package/README.md +419 -21
  4. package/dist/CopyIndicator-RR3hSsBA.js +51 -0
  5. package/dist/MarkdownBody-EIz0jnQy.js +14910 -0
  6. package/dist/VoiceControls-A7N4uPTo.js +146 -0
  7. package/dist/VoiceRuntime-DrYjNkZK.js +459 -0
  8. package/dist/abort-BjeyCmGn.js +6 -0
  9. package/dist/blank-line-CUDmZ-mX.js +143 -0
  10. package/dist/{browser-Cgo1GySj.js → browser-M7mS-hAN.js} +5 -5
  11. package/dist/clsx-Cf23UI1w.js +16 -0
  12. package/dist/core/client.d.ts +37 -4
  13. package/dist/core/client.d.ts.map +1 -1
  14. package/dist/core/consume-stream.d.ts.map +1 -1
  15. package/dist/core/error-reporter.d.ts +59 -0
  16. package/dist/core/error-reporter.d.ts.map +1 -0
  17. package/dist/core/global-error-capture.d.ts +10 -0
  18. package/dist/core/global-error-capture.d.ts.map +1 -0
  19. package/dist/core/i18n/messages.d.ts +139 -1
  20. package/dist/core/i18n/messages.d.ts.map +1 -1
  21. package/dist/core/sanitize-user-message.d.ts +11 -0
  22. package/dist/core/sanitize-user-message.d.ts.map +1 -0
  23. package/dist/core/stream-state.d.ts.map +1 -1
  24. package/dist/core/tool-confirmation.d.ts +35 -0
  25. package/dist/core/tool-confirmation.d.ts.map +1 -0
  26. package/dist/core/tool-runner.d.ts +8 -0
  27. package/dist/core/tool-runner.d.ts.map +1 -1
  28. package/dist/core/types.d.ts +123 -0
  29. package/dist/core/types.d.ts.map +1 -1
  30. package/dist/core/widget-origin.d.ts +33 -0
  31. package/dist/core/widget-origin.d.ts.map +1 -0
  32. package/dist/createLucideIcon-C7wGkK-Q.js +43 -0
  33. package/dist/default-sNAxTmdF.js +8 -0
  34. package/dist/index.css +2 -2
  35. package/dist/index.d.ts +3 -1
  36. package/dist/index.d.ts.map +1 -1
  37. package/dist/index.js +7548 -26290
  38. package/dist/jsx-runtime-Cyy0mp0f.js +328 -0
  39. package/dist/lib-DG_DjiCr.js +15 -0
  40. package/dist/loader.d.ts +12 -0
  41. package/dist/loader.d.ts.map +1 -0
  42. package/dist/messages-FvtWi3lI.js +247 -0
  43. package/dist/observe/__tests__/format.test.d.ts +2 -0
  44. package/dist/observe/__tests__/format.test.d.ts.map +1 -0
  45. package/dist/observe/__tests__/http.test.d.ts +2 -0
  46. package/dist/observe/__tests__/http.test.d.ts.map +1 -0
  47. package/dist/observe/__tests__/index.test.d.ts +2 -0
  48. package/dist/observe/__tests__/index.test.d.ts.map +1 -0
  49. package/dist/observe/__tests__/js-error.test.d.ts +2 -0
  50. package/dist/observe/__tests__/js-error.test.d.ts.map +1 -0
  51. package/dist/observe/__tests__/redact.test.d.ts +2 -0
  52. package/dist/observe/__tests__/redact.test.d.ts.map +1 -0
  53. package/dist/observe/__tests__/ring-buffer.test.d.ts +2 -0
  54. package/dist/observe/__tests__/ring-buffer.test.d.ts.map +1 -0
  55. package/dist/observe/format.d.ts +10 -0
  56. package/dist/observe/format.d.ts.map +1 -0
  57. package/dist/observe/index.d.ts +33 -0
  58. package/dist/observe/index.d.ts.map +1 -0
  59. package/dist/observe/observers/http.d.ts +24 -0
  60. package/dist/observe/observers/http.d.ts.map +1 -0
  61. package/dist/observe/observers/js-error.d.ts +22 -0
  62. package/dist/observe/observers/js-error.d.ts.map +1 -0
  63. package/dist/observe/redact.d.ts +27 -0
  64. package/dist/observe/redact.d.ts.map +1 -0
  65. package/dist/observe/ring-buffer.d.ts +20 -0
  66. package/dist/observe/ring-buffer.d.ts.map +1 -0
  67. package/dist/observe/types.d.ts +25 -0
  68. package/dist/observe/types.d.ts.map +1 -0
  69. package/dist/plugin/registry.d.ts.map +1 -1
  70. package/dist/plugin/types.d.ts +19 -1
  71. package/dist/plugin/types.d.ts.map +1 -1
  72. package/dist/plugins/page-reader/__tests__/get-meta.test.d.ts +2 -0
  73. package/dist/plugins/page-reader/__tests__/get-meta.test.d.ts.map +1 -0
  74. package/dist/plugins/page-reader/__tests__/index.test.d.ts +2 -0
  75. package/dist/plugins/page-reader/__tests__/index.test.d.ts.map +1 -0
  76. package/dist/plugins/page-reader/__tests__/read-content.test.d.ts +2 -0
  77. package/dist/plugins/page-reader/__tests__/read-content.test.d.ts.map +1 -0
  78. package/dist/plugins/page-reader/__tests__/scroll.test.d.ts +2 -0
  79. package/dist/plugins/page-reader/__tests__/scroll.test.d.ts.map +1 -0
  80. package/dist/plugins/page-reader/index.d.ts +18 -0
  81. package/dist/plugins/page-reader/index.d.ts.map +1 -0
  82. package/dist/plugins/page-reader/tools/get-meta.d.ts +29 -0
  83. package/dist/plugins/page-reader/tools/get-meta.d.ts.map +1 -0
  84. package/dist/plugins/page-reader/tools/read-content.d.ts +34 -0
  85. package/dist/plugins/page-reader/tools/read-content.d.ts.map +1 -0
  86. package/dist/plugins/page-reader/tools/scroll.d.ts +29 -0
  87. package/dist/plugins/page-reader/tools/scroll.d.ts.map +1 -0
  88. package/dist/plugins/page-reader.d.ts +2 -0
  89. package/dist/plugins/page-reader.js +230 -0
  90. package/dist/plugins/qrcode/tool.d.ts.map +1 -1
  91. package/dist/plugins/qrcode.js +52 -42
  92. package/dist/plugins/shared/abort.d.ts +7 -0
  93. package/dist/plugins/shared/abort.d.ts.map +1 -0
  94. package/dist/remark-gfm-Bzy1u34W.js +1962 -0
  95. package/dist/remark-parse-BnwSmQr-.js +2486 -0
  96. package/dist/stable-prefix-BHsGj4tL.js +21 -0
  97. package/dist/ui/builtin-tools/get-current-page-info.d.ts.map +1 -1
  98. package/dist/ui/builtin-tools/index.d.ts +1 -1
  99. package/dist/ui/builtin-tools/index.d.ts.map +1 -1
  100. package/dist/ui/builtin-tools/merge-builtin-tools.d.ts +9 -0
  101. package/dist/ui/builtin-tools/merge-builtin-tools.d.ts.map +1 -1
  102. package/dist/ui/commands/builtin-commands.d.ts +46 -0
  103. package/dist/ui/commands/builtin-commands.d.ts.map +1 -0
  104. package/dist/ui/components/ChatErrorBoundary.d.ts +30 -0
  105. package/dist/ui/components/ChatErrorBoundary.d.ts.map +1 -0
  106. package/dist/ui/components/ChatFooter.d.ts +32 -2
  107. package/dist/ui/components/ChatFooter.d.ts.map +1 -1
  108. package/dist/ui/components/ChatHeader.d.ts +13 -2
  109. package/dist/ui/components/ChatHeader.d.ts.map +1 -1
  110. package/dist/ui/components/ChatHeaderMenu.d.ts +28 -2
  111. package/dist/ui/components/ChatHeaderMenu.d.ts.map +1 -1
  112. package/dist/ui/components/ChatPanel.d.ts +38 -4
  113. package/dist/ui/components/ChatPanel.d.ts.map +1 -1
  114. package/dist/ui/components/ChatWidget.d.ts +1 -1
  115. package/dist/ui/components/ChatWidget.d.ts.map +1 -1
  116. package/dist/ui/components/CommandConfirmationCard.d.ts +28 -0
  117. package/dist/ui/components/CommandConfirmationCard.d.ts.map +1 -0
  118. package/dist/ui/components/CommandOverlays.d.ts +40 -0
  119. package/dist/ui/components/CommandOverlays.d.ts.map +1 -0
  120. package/dist/ui/components/CommandPalette.d.ts +25 -0
  121. package/dist/ui/components/CommandPalette.d.ts.map +1 -0
  122. package/dist/ui/components/FooterActions.d.ts +18 -0
  123. package/dist/ui/components/FooterActions.d.ts.map +1 -0
  124. package/dist/ui/components/HelpDialogContent.d.ts +7 -0
  125. package/dist/ui/components/HelpDialogContent.d.ts.map +1 -0
  126. package/dist/ui/components/MessageList.d.ts +12 -1
  127. package/dist/ui/components/MessageList.d.ts.map +1 -1
  128. package/dist/ui/components/MessageRow.d.ts +7 -1
  129. package/dist/ui/components/MessageRow.d.ts.map +1 -1
  130. package/dist/ui/components/MessageRowActions.d.ts +9 -3
  131. package/dist/ui/components/MessageRowActions.d.ts.map +1 -1
  132. package/dist/ui/components/MicButton.d.ts +11 -0
  133. package/dist/ui/components/MicButton.d.ts.map +1 -0
  134. package/dist/ui/components/ResizeHandles.d.ts +15 -0
  135. package/dist/ui/components/ResizeHandles.d.ts.map +1 -0
  136. package/dist/ui/components/ToolConfirmationCard.d.ts +22 -0
  137. package/dist/ui/components/ToolConfirmationCard.d.ts.map +1 -0
  138. package/dist/ui/components/ToolConfirmationRecord.d.ts +16 -0
  139. package/dist/ui/components/ToolConfirmationRecord.d.ts.map +1 -0
  140. package/dist/ui/components/ToolsDialogContent.d.ts +20 -0
  141. package/dist/ui/components/ToolsDialogContent.d.ts.map +1 -0
  142. package/dist/ui/components/VoiceControls.d.ts +22 -0
  143. package/dist/ui/components/VoiceControls.d.ts.map +1 -0
  144. package/dist/ui/components/VoiceLoopStatusBar.d.ts +17 -0
  145. package/dist/ui/components/VoiceLoopStatusBar.d.ts.map +1 -0
  146. package/dist/ui/components/VoiceLoopToggle.d.ts +15 -0
  147. package/dist/ui/components/VoiceLoopToggle.d.ts.map +1 -0
  148. package/dist/ui/components/VoiceRuntime.d.ts +16 -0
  149. package/dist/ui/components/VoiceRuntime.d.ts.map +1 -0
  150. package/dist/ui/components/WidgetDialog.d.ts +22 -0
  151. package/dist/ui/components/WidgetDialog.d.ts.map +1 -0
  152. package/dist/ui/components/lazy-voice.d.ts +19 -0
  153. package/dist/ui/components/lazy-voice.d.ts.map +1 -0
  154. package/dist/ui/components/markdown/MarkdownBody.d.ts +28 -0
  155. package/dist/ui/components/markdown/MarkdownBody.d.ts.map +1 -0
  156. package/dist/ui/components/markdown/MarkdownMessage.d.ts +12 -13
  157. package/dist/ui/components/markdown/MarkdownMessage.d.ts.map +1 -1
  158. package/dist/ui/hooks/conversationPersistence.d.ts +21 -0
  159. package/dist/ui/hooks/conversationPersistence.d.ts.map +1 -0
  160. package/dist/ui/hooks/resize-geometry.d.ts +42 -0
  161. package/dist/ui/hooks/resize-geometry.d.ts.map +1 -0
  162. package/dist/ui/hooks/use-command-execution.d.ts +60 -0
  163. package/dist/ui/hooks/use-command-execution.d.ts.map +1 -0
  164. package/dist/ui/hooks/use-command-palette.d.ts +45 -0
  165. package/dist/ui/hooks/use-command-palette.d.ts.map +1 -0
  166. package/dist/ui/hooks/use-fullscreen.d.ts +21 -0
  167. package/dist/ui/hooks/use-fullscreen.d.ts.map +1 -0
  168. package/dist/ui/hooks/use-global-error-capture.d.ts +16 -0
  169. package/dist/ui/hooks/use-global-error-capture.d.ts.map +1 -0
  170. package/dist/ui/hooks/use-locale-preference.d.ts +14 -0
  171. package/dist/ui/hooks/use-locale-preference.d.ts.map +1 -0
  172. package/dist/ui/hooks/use-menu-keyboard.d.ts +7 -1
  173. package/dist/ui/hooks/use-menu-keyboard.d.ts.map +1 -1
  174. package/dist/ui/hooks/use-message-history.d.ts +14 -0
  175. package/dist/ui/hooks/use-message-history.d.ts.map +1 -1
  176. package/dist/ui/hooks/use-mic-button.d.ts +29 -0
  177. package/dist/ui/hooks/use-mic-button.d.ts.map +1 -0
  178. package/dist/ui/hooks/use-send-message.d.ts +6 -0
  179. package/dist/ui/hooks/use-send-message.d.ts.map +1 -1
  180. package/dist/ui/hooks/use-speak-message.d.ts +26 -0
  181. package/dist/ui/hooks/use-speak-message.d.ts.map +1 -0
  182. package/dist/ui/hooks/use-tool-confirmation.d.ts +22 -0
  183. package/dist/ui/hooks/use-tool-confirmation.d.ts.map +1 -0
  184. package/dist/ui/hooks/use-tool-runner.d.ts +17 -2
  185. package/dist/ui/hooks/use-tool-runner.d.ts.map +1 -1
  186. package/dist/ui/hooks/use-visitor-id.d.ts +22 -0
  187. package/dist/ui/hooks/use-visitor-id.d.ts.map +1 -0
  188. package/dist/ui/hooks/use-voice-input.d.ts +38 -0
  189. package/dist/ui/hooks/use-voice-input.d.ts.map +1 -0
  190. package/dist/ui/hooks/use-voice-loop-speech.d.ts +38 -0
  191. package/dist/ui/hooks/use-voice-loop-speech.d.ts.map +1 -0
  192. package/dist/ui/hooks/use-voice-loop.d.ts +12 -0
  193. package/dist/ui/hooks/use-voice-loop.d.ts.map +1 -0
  194. package/dist/ui/hooks/use-voice-runtime-snapshot.d.ts +19 -0
  195. package/dist/ui/hooks/use-voice-runtime-snapshot.d.ts.map +1 -0
  196. package/dist/ui/hooks/use-voice-runtime.d.ts +29 -0
  197. package/dist/ui/hooks/use-voice-runtime.d.ts.map +1 -0
  198. package/dist/ui/hooks/useChatStream.d.ts +19 -0
  199. package/dist/ui/hooks/useChatStream.d.ts.map +1 -1
  200. package/dist/ui/hooks/useConversationList.d.ts +12 -1
  201. package/dist/ui/hooks/useConversationList.d.ts.map +1 -1
  202. package/dist/ui/hooks/useDraggablePanel.d.ts +2 -0
  203. package/dist/ui/hooks/useDraggablePanel.d.ts.map +1 -1
  204. package/dist/ui/hooks/useResizablePanel.d.ts +48 -0
  205. package/dist/ui/hooks/useResizablePanel.d.ts.map +1 -0
  206. package/dist/ui/utils/speech-text.d.ts +29 -0
  207. package/dist/ui/utils/speech-text.d.ts.map +1 -0
  208. package/dist/ui/utils/voice-locale.d.ts +3 -0
  209. package/dist/ui/utils/voice-locale.d.ts.map +1 -0
  210. package/dist/ui/utils/voice-loop-cue.d.ts +23 -0
  211. package/dist/ui/utils/voice-loop-cue.d.ts.map +1 -0
  212. package/dist/ui/utils/voice-loop-status.d.ts +17 -0
  213. package/dist/ui/utils/voice-loop-status.d.ts.map +1 -0
  214. package/dist/ui/utils/voice-loop-types.d.ts +40 -0
  215. package/dist/ui/utils/voice-loop-types.d.ts.map +1 -0
  216. package/dist/ui/utils/voice-runtime.d.ts +38 -0
  217. package/dist/ui/utils/voice-runtime.d.ts.map +1 -0
  218. package/dist/ui/utils/voice-support.d.ts +9 -0
  219. package/dist/ui/utils/voice-support.d.ts.map +1 -0
  220. package/dist/unified-DctkAd9P.js +518 -0
  221. package/dist/use-voice-input-LtJJz-zQ.js +102 -0
  222. package/dist/version.d.ts +17 -0
  223. package/dist/version.d.ts.map +1 -0
  224. package/dist/voice-runtime-F5NxN_0m.js +11 -0
  225. package/dist/voice-support-BeOiOzcn.js +9 -0
  226. package/package.json +41 -23
  227. package/dist/messages-B7Kpa6yx.js +0 -117
@@ -0,0 +1,1962 @@
1
+ import { t as L } from "./default-sNAxTmdF.js";
2
+ import { _ as P, b as J, c as W, d as X, i as Be, l as O, n as F, o as N, p as $e, r as We, s as he, t as qe, u as M, v, x as I, y as T } from "./blank-line-CUDmZ-mX.js";
3
+ function le(e, n) {
4
+ const t = String(e);
5
+ if (typeof n != "string") throw new TypeError("Expected character");
6
+ let r = 0, a = t.indexOf(n);
7
+ for (; a !== -1; )
8
+ r++, a = t.indexOf(n, a + n.length);
9
+ return r;
10
+ }
11
+ function He(e) {
12
+ if (typeof e != "string") throw new TypeError("Expected a string");
13
+ return e.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
14
+ }
15
+ var H = (function(e) {
16
+ if (e == null) return Ge;
17
+ if (typeof e == "function") return U(e);
18
+ if (typeof e == "object") return Array.isArray(e) ? Ue(e) : Ne(e);
19
+ if (typeof e == "string") return Ve(e);
20
+ throw new Error("Expected function, string, or object as test");
21
+ });
22
+ function Ue(e) {
23
+ const n = [];
24
+ let t = -1;
25
+ for (; ++t < e.length; ) n[t] = H(e[t]);
26
+ return U(r);
27
+ function r(...a) {
28
+ let l = -1;
29
+ for (; ++l < n.length; ) if (n[l].apply(this, a)) return !0;
30
+ return !1;
31
+ }
32
+ }
33
+ function Ne(e) {
34
+ const n = e;
35
+ return U(t);
36
+ function t(r) {
37
+ const a = r;
38
+ let l;
39
+ for (l in e) if (a[l] !== n[l]) return !1;
40
+ return !0;
41
+ }
42
+ }
43
+ function Ve(e) {
44
+ return U(n);
45
+ function n(t) {
46
+ return t && t.type === e;
47
+ }
48
+ }
49
+ function U(e) {
50
+ return n;
51
+ function n(t, r, a) {
52
+ return !!(Qe(t) && e.call(this, t, typeof r == "number" ? r : void 0, a || void 0));
53
+ }
54
+ }
55
+ function Ge() {
56
+ return !0;
57
+ }
58
+ function Qe(e) {
59
+ return e !== null && typeof e == "object" && "type" in e;
60
+ }
61
+ var me = [];
62
+ function pe(e, n, t, r) {
63
+ let a;
64
+ typeof n == "function" && typeof t != "function" ? (r = t, t = n) : a = n;
65
+ const l = H(a), i = r ? -1 : 1;
66
+ u(e, void 0, [])();
67
+ function u(o, c, h) {
68
+ const s = o && typeof o == "object" ? o : {};
69
+ if (typeof s.type == "string") {
70
+ const p = typeof s.tagName == "string" ? s.tagName : typeof s.name == "string" ? s.name : void 0;
71
+ Object.defineProperty(g, "name", { value: "node (" + (o.type + (p ? "<" + p + ">" : "")) + ")" });
72
+ }
73
+ return g;
74
+ function g() {
75
+ let p = me, m, b, x;
76
+ if ((!n || l(o, c, h[h.length - 1] || void 0)) && (p = Ke(t(o, h)), p[0] === !1))
77
+ return p;
78
+ if ("children" in o && o.children) {
79
+ const k = o;
80
+ if (k.children && p[0] !== "skip")
81
+ for (b = (r ? k.children.length : -1) + i, x = h.concat(k); b > -1 && b < k.children.length; ) {
82
+ const w = k.children[b];
83
+ if (m = u(w, b, x)(), m[0] === !1) return m;
84
+ b = typeof m[1] == "number" ? m[1] : b + i;
85
+ }
86
+ }
87
+ return p;
88
+ }
89
+ }
90
+ }
91
+ function Ke(e) {
92
+ return Array.isArray(e) ? e : typeof e == "number" ? [!0, e] : e == null ? me : [e];
93
+ }
94
+ function Ze(e, n, t) {
95
+ const r = H((t || {}).ignore || []), a = Je(n);
96
+ let l = -1;
97
+ for (; ++l < a.length; ) pe(e, "text", i);
98
+ function i(o, c) {
99
+ let h = -1, s;
100
+ for (; ++h < c.length; ) {
101
+ const g = c[h], p = s ? s.children : void 0;
102
+ if (r(g, p ? p.indexOf(g) : void 0, s)) return;
103
+ s = g;
104
+ }
105
+ if (s) return u(o, c);
106
+ }
107
+ function u(o, c) {
108
+ const h = c[c.length - 1], s = a[l][0], g = a[l][1];
109
+ let p = 0;
110
+ const m = h.children.indexOf(o);
111
+ let b = !1, x = [];
112
+ s.lastIndex = 0;
113
+ let k = s.exec(o.value);
114
+ for (; k; ) {
115
+ const w = k.index, d = {
116
+ index: k.index,
117
+ input: k.input,
118
+ stack: [...c, o]
119
+ };
120
+ let y = g(...k, d);
121
+ if (typeof y == "string" && (y = y.length > 0 ? {
122
+ type: "text",
123
+ value: y
124
+ } : void 0), y === !1 ? s.lastIndex = w + 1 : (p !== w && x.push({
125
+ type: "text",
126
+ value: o.value.slice(p, w)
127
+ }), Array.isArray(y) ? x.push(...y) : y && x.push(y), p = w + k[0].length, b = !0), !s.global) break;
128
+ k = s.exec(o.value);
129
+ }
130
+ return b ? (p < o.value.length && x.push({
131
+ type: "text",
132
+ value: o.value.slice(p)
133
+ }), h.children.splice(m, 1, ...x)) : x = [o], m + x.length;
134
+ }
135
+ }
136
+ function Je(e) {
137
+ const n = [];
138
+ if (!Array.isArray(e)) throw new TypeError("Expected find and replace tuple or list of tuples");
139
+ const t = !e[0] || Array.isArray(e[0]) ? e : [e];
140
+ let r = -1;
141
+ for (; ++r < t.length; ) {
142
+ const a = t[r];
143
+ n.push([Xe(a[0]), Ye(a[1])]);
144
+ }
145
+ return n;
146
+ }
147
+ function Xe(e) {
148
+ return typeof e == "string" ? new RegExp(He(e), "g") : e;
149
+ }
150
+ function Ye(e) {
151
+ return typeof e == "function" ? e : function() {
152
+ return e;
153
+ };
154
+ }
155
+ var V = "phrasing", G = [
156
+ "autolink",
157
+ "link",
158
+ "image",
159
+ "label"
160
+ ];
161
+ function et() {
162
+ return {
163
+ transforms: [at],
164
+ enter: {
165
+ literalAutolink: nt,
166
+ literalAutolinkEmail: Q,
167
+ literalAutolinkHttp: Q,
168
+ literalAutolinkWww: Q
169
+ },
170
+ exit: {
171
+ literalAutolink: ot,
172
+ literalAutolinkEmail: lt,
173
+ literalAutolinkHttp: rt,
174
+ literalAutolinkWww: it
175
+ }
176
+ };
177
+ }
178
+ function tt() {
179
+ return { unsafe: [
180
+ {
181
+ character: "@",
182
+ before: "[+\\-.\\w]",
183
+ after: "[\\-.\\w]",
184
+ inConstruct: V,
185
+ notInConstruct: G
186
+ },
187
+ {
188
+ character: ".",
189
+ before: "[Ww]",
190
+ after: "[\\-.\\w]",
191
+ inConstruct: V,
192
+ notInConstruct: G
193
+ },
194
+ {
195
+ character: ":",
196
+ before: "[ps]",
197
+ after: "\\/",
198
+ inConstruct: V,
199
+ notInConstruct: G
200
+ }
201
+ ] };
202
+ }
203
+ function nt(e) {
204
+ this.enter({
205
+ type: "link",
206
+ title: null,
207
+ url: "",
208
+ children: []
209
+ }, e);
210
+ }
211
+ function Q(e) {
212
+ this.config.enter.autolinkProtocol.call(this, e);
213
+ }
214
+ function rt(e) {
215
+ this.config.exit.autolinkProtocol.call(this, e);
216
+ }
217
+ function it(e) {
218
+ this.config.exit.data.call(this, e);
219
+ const n = this.stack[this.stack.length - 1];
220
+ n.type, n.url = "http://" + this.sliceSerialize(e);
221
+ }
222
+ function lt(e) {
223
+ this.config.exit.autolinkEmail.call(this, e);
224
+ }
225
+ function ot(e) {
226
+ this.exit(e);
227
+ }
228
+ function at(e) {
229
+ Ze(e, [[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi, ut], [new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)", "gu"), st]], { ignore: ["link", "linkReference"] });
230
+ }
231
+ function ut(e, n, t, r, a) {
232
+ let l = "";
233
+ if (!ge(a) || (/^w/i.test(n) && (t = n + t, n = "", l = "http://"), !ct(t))) return !1;
234
+ const i = ft(t + r);
235
+ if (!i[0]) return !1;
236
+ const u = {
237
+ type: "link",
238
+ title: null,
239
+ url: l + n + i[0],
240
+ children: [{
241
+ type: "text",
242
+ value: n + i[0]
243
+ }]
244
+ };
245
+ return i[1] ? [u, {
246
+ type: "text",
247
+ value: i[1]
248
+ }] : u;
249
+ }
250
+ function st(e, n, t, r) {
251
+ return !ge(r, !0) || /[-\d_]$/.test(t) ? !1 : {
252
+ type: "link",
253
+ title: null,
254
+ url: "mailto:" + n + "@" + t,
255
+ children: [{
256
+ type: "text",
257
+ value: n + "@" + t
258
+ }]
259
+ };
260
+ }
261
+ function ct(e) {
262
+ const n = e.split(".");
263
+ return !(n.length < 2 || n[n.length - 1] && (/_/.test(n[n.length - 1]) || !/[a-zA-Z\d]/.test(n[n.length - 1])) || n[n.length - 2] && (/_/.test(n[n.length - 2]) || !/[a-zA-Z\d]/.test(n[n.length - 2])));
264
+ }
265
+ function ft(e) {
266
+ const n = /[!"&'),.:;<>?\]}]+$/.exec(e);
267
+ if (!n) return [e, void 0];
268
+ e = e.slice(0, n.index);
269
+ let t = n[0], r = t.indexOf(")");
270
+ const a = le(e, "(");
271
+ let l = le(e, ")");
272
+ for (; r !== -1 && a > l; )
273
+ e += t.slice(0, r + 1), t = t.slice(r + 1), r = t.indexOf(")"), l++;
274
+ return [e, t];
275
+ }
276
+ function ge(e, n) {
277
+ const t = e.input.charCodeAt(e.index - 1);
278
+ return (e.index === 0 || I(t) || J(t)) && (!n || t !== 47);
279
+ }
280
+ ke.peek = dt;
281
+ function ht() {
282
+ this.buffer();
283
+ }
284
+ function mt(e) {
285
+ this.enter({
286
+ type: "footnoteReference",
287
+ identifier: "",
288
+ label: ""
289
+ }, e);
290
+ }
291
+ function pt() {
292
+ this.buffer();
293
+ }
294
+ function gt(e) {
295
+ this.enter({
296
+ type: "footnoteDefinition",
297
+ identifier: "",
298
+ label: "",
299
+ children: []
300
+ }, e);
301
+ }
302
+ function kt(e) {
303
+ const n = this.resume(), t = this.stack[this.stack.length - 1];
304
+ t.type, t.identifier = O(this.sliceSerialize(e)).toLowerCase(), t.label = n;
305
+ }
306
+ function bt(e) {
307
+ this.exit(e);
308
+ }
309
+ function xt(e) {
310
+ const n = this.resume(), t = this.stack[this.stack.length - 1];
311
+ t.type, t.identifier = O(this.sliceSerialize(e)).toLowerCase(), t.label = n;
312
+ }
313
+ function wt(e) {
314
+ this.exit(e);
315
+ }
316
+ function dt() {
317
+ return "[";
318
+ }
319
+ function ke(e, n, t, r) {
320
+ const a = t.createTracker(r);
321
+ let l = a.move("[^");
322
+ const i = t.enter("footnoteReference"), u = t.enter("reference");
323
+ return l += a.move(t.safe(t.associationId(e), {
324
+ after: "]",
325
+ before: l
326
+ })), u(), i(), l += a.move("]"), l;
327
+ }
328
+ function yt() {
329
+ return {
330
+ enter: {
331
+ gfmFootnoteCallString: ht,
332
+ gfmFootnoteCall: mt,
333
+ gfmFootnoteDefinitionLabelString: pt,
334
+ gfmFootnoteDefinition: gt
335
+ },
336
+ exit: {
337
+ gfmFootnoteCallString: kt,
338
+ gfmFootnoteCall: bt,
339
+ gfmFootnoteDefinitionLabelString: xt,
340
+ gfmFootnoteDefinition: wt
341
+ }
342
+ };
343
+ }
344
+ function vt(e) {
345
+ let n = !1;
346
+ return e && e.firstLineBlank && (n = !0), {
347
+ handlers: {
348
+ footnoteDefinition: t,
349
+ footnoteReference: ke
350
+ },
351
+ unsafe: [{
352
+ character: "[",
353
+ inConstruct: [
354
+ "label",
355
+ "phrasing",
356
+ "reference"
357
+ ]
358
+ }]
359
+ };
360
+ function t(r, a, l, i) {
361
+ const u = l.createTracker(i);
362
+ let o = u.move("[^");
363
+ const c = l.enter("footnoteDefinition"), h = l.enter("label");
364
+ return o += u.move(l.safe(l.associationId(r), {
365
+ before: o,
366
+ after: "]"
367
+ })), h(), o += u.move("]:"), r.children && r.children.length > 0 && (u.shift(4), o += u.move((n ? `
368
+ ` : " ") + l.indentLines(l.containerFlow(r, u.current()), n ? be : Ct))), c(), o;
369
+ }
370
+ }
371
+ function Ct(e, n, t) {
372
+ return n === 0 ? e : be(e, n, t);
373
+ }
374
+ function be(e, n, t) {
375
+ return (t ? "" : " ") + e;
376
+ }
377
+ var At = [
378
+ "autolink",
379
+ "destinationLiteral",
380
+ "destinationRaw",
381
+ "reference",
382
+ "titleQuote",
383
+ "titleApostrophe"
384
+ ];
385
+ xe.peek = Tt;
386
+ function Dt() {
387
+ return {
388
+ canContainEols: ["delete"],
389
+ enter: { strikethrough: St },
390
+ exit: { strikethrough: Lt }
391
+ };
392
+ }
393
+ function Ft() {
394
+ return {
395
+ unsafe: [{
396
+ character: "~",
397
+ inConstruct: "phrasing",
398
+ notInConstruct: At
399
+ }],
400
+ handlers: { delete: xe }
401
+ };
402
+ }
403
+ function St(e) {
404
+ this.enter({
405
+ type: "delete",
406
+ children: []
407
+ }, e);
408
+ }
409
+ function Lt(e) {
410
+ this.exit(e);
411
+ }
412
+ function xe(e, n, t, r) {
413
+ const a = t.createTracker(r), l = t.enter("strikethrough");
414
+ let i = a.move("~~");
415
+ return i += t.containerPhrasing(e, {
416
+ ...a.current(),
417
+ before: i,
418
+ after: "~"
419
+ }), i += a.move("~~"), l(), i;
420
+ }
421
+ function Tt() {
422
+ return "~";
423
+ }
424
+ function zt(e) {
425
+ return e.length;
426
+ }
427
+ function It(e, n) {
428
+ const t = n || {}, r = (t.align || []).concat(), a = t.stringLength || zt, l = [], i = [], u = [], o = [];
429
+ let c = 0, h = -1;
430
+ for (; ++h < e.length; ) {
431
+ const b = [], x = [];
432
+ let k = -1;
433
+ for (e[h].length > c && (c = e[h].length); ++k < e[h].length; ) {
434
+ const w = Et(e[h][k]);
435
+ if (t.alignDelimiters !== !1) {
436
+ const d = a(w);
437
+ x[k] = d, (o[k] === void 0 || d > o[k]) && (o[k] = d);
438
+ }
439
+ b.push(w);
440
+ }
441
+ i[h] = b, u[h] = x;
442
+ }
443
+ let s = -1;
444
+ if (typeof r == "object" && "length" in r) for (; ++s < c; ) l[s] = oe(r[s]);
445
+ else {
446
+ const b = oe(r);
447
+ for (; ++s < c; ) l[s] = b;
448
+ }
449
+ s = -1;
450
+ const g = [], p = [];
451
+ for (; ++s < c; ) {
452
+ const b = l[s];
453
+ let x = "", k = "";
454
+ b === 99 ? (x = ":", k = ":") : b === 108 ? x = ":" : b === 114 && (k = ":");
455
+ let w = t.alignDelimiters === !1 ? 1 : Math.max(1, o[s] - x.length - k.length);
456
+ const d = x + "-".repeat(w) + k;
457
+ t.alignDelimiters !== !1 && (w = x.length + w + k.length, w > o[s] && (o[s] = w), p[s] = w), g[s] = d;
458
+ }
459
+ i.splice(1, 0, g), u.splice(1, 0, p), h = -1;
460
+ const m = [];
461
+ for (; ++h < i.length; ) {
462
+ const b = i[h], x = u[h];
463
+ s = -1;
464
+ const k = [];
465
+ for (; ++s < c; ) {
466
+ const w = b[s] || "";
467
+ let d = "", y = "";
468
+ if (t.alignDelimiters !== !1) {
469
+ const C = o[s] - (x[s] || 0), E = l[s];
470
+ E === 114 ? d = " ".repeat(C) : E === 99 ? C % 2 ? (d = " ".repeat(C / 2 + 0.5), y = " ".repeat(C / 2 - 0.5)) : (d = " ".repeat(C / 2), y = d) : y = " ".repeat(C);
471
+ }
472
+ t.delimiterStart !== !1 && !s && k.push("|"), t.padding !== !1 && !(t.alignDelimiters === !1 && w === "") && (t.delimiterStart !== !1 || s) && k.push(" "), t.alignDelimiters !== !1 && k.push(d), k.push(w), t.alignDelimiters !== !1 && k.push(y), t.padding !== !1 && k.push(" "), (t.delimiterEnd !== !1 || s !== c - 1) && k.push("|");
473
+ }
474
+ m.push(t.delimiterEnd === !1 ? k.join("").replace(/ +$/, "") : k.join(""));
475
+ }
476
+ return m.join(`
477
+ `);
478
+ }
479
+ function Et(e) {
480
+ return e == null ? "" : String(e);
481
+ }
482
+ function oe(e) {
483
+ const n = typeof e == "string" ? e.codePointAt(0) : 0;
484
+ return n === 67 || n === 99 ? 99 : n === 76 || n === 108 ? 108 : n === 82 || n === 114 ? 114 : 0;
485
+ }
486
+ function Rt(e, n, t, r) {
487
+ const a = t.enter("blockquote"), l = t.createTracker(r);
488
+ l.move("> "), l.shift(2);
489
+ const i = t.indentLines(t.containerFlow(e, l.current()), Pt);
490
+ return a(), i;
491
+ }
492
+ function Pt(e, n, t) {
493
+ return ">" + (t ? "" : " ") + e;
494
+ }
495
+ function Mt(e, n) {
496
+ return ae(e, n.inConstruct, !0) && !ae(e, n.notInConstruct, !1);
497
+ }
498
+ function ae(e, n, t) {
499
+ if (typeof n == "string" && (n = [n]), !n || n.length === 0) return t;
500
+ let r = -1;
501
+ for (; ++r < n.length; ) if (e.includes(n[r])) return !0;
502
+ return !1;
503
+ }
504
+ function ue(e, n, t, r) {
505
+ let a = -1;
506
+ for (; ++a < t.unsafe.length; ) if (t.unsafe[a].character === `
507
+ ` && Mt(t.stack, t.unsafe[a])) return /[ \t]/.test(r.before) ? "" : " ";
508
+ return `\\
509
+ `;
510
+ }
511
+ function _t(e, n) {
512
+ const t = String(e);
513
+ let r = t.indexOf(n), a = r, l = 0, i = 0;
514
+ if (typeof n != "string") throw new TypeError("Expected substring");
515
+ for (; r !== -1; )
516
+ r === a ? ++l > i && (i = l) : l = 1, a = r + n.length, r = t.indexOf(n, a);
517
+ return i;
518
+ }
519
+ function Ot(e, n) {
520
+ return !!(n.options.fences === !1 && e.value && !e.lang && /[^ \r\n]/.test(e.value) && !/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value));
521
+ }
522
+ function jt(e) {
523
+ const n = e.options.fence || "`";
524
+ if (n !== "`" && n !== "~") throw new Error("Cannot serialize code with `" + n + "` for `options.fence`, expected `` ` `` or `~`");
525
+ return n;
526
+ }
527
+ function Bt(e, n, t, r) {
528
+ const a = jt(t), l = e.value || "", i = a === "`" ? "GraveAccent" : "Tilde";
529
+ if (Ot(e, t)) {
530
+ const s = t.enter("codeIndented"), g = t.indentLines(l, $t);
531
+ return s(), g;
532
+ }
533
+ const u = t.createTracker(r), o = a.repeat(Math.max(_t(l, a) + 1, 3)), c = t.enter("codeFenced");
534
+ let h = u.move(o);
535
+ if (e.lang) {
536
+ const s = t.enter(`codeFencedLang${i}`);
537
+ h += u.move(t.safe(e.lang, {
538
+ before: h,
539
+ after: " ",
540
+ encode: ["`"],
541
+ ...u.current()
542
+ })), s();
543
+ }
544
+ if (e.lang && e.meta) {
545
+ const s = t.enter(`codeFencedMeta${i}`);
546
+ h += u.move(" "), h += u.move(t.safe(e.meta, {
547
+ before: h,
548
+ after: `
549
+ `,
550
+ encode: ["`"],
551
+ ...u.current()
552
+ })), s();
553
+ }
554
+ return h += u.move(`
555
+ `), l && (h += u.move(l + `
556
+ `)), h += u.move(o), c(), h;
557
+ }
558
+ function $t(e, n, t) {
559
+ return (t ? "" : " ") + e;
560
+ }
561
+ function Y(e) {
562
+ const n = e.options.quote || '"';
563
+ if (n !== '"' && n !== "'") throw new Error("Cannot serialize title with `" + n + "` for `options.quote`, expected `\"`, or `'`");
564
+ return n;
565
+ }
566
+ function Wt(e, n, t, r) {
567
+ const a = Y(t), l = a === '"' ? "Quote" : "Apostrophe", i = t.enter("definition");
568
+ let u = t.enter("label");
569
+ const o = t.createTracker(r);
570
+ let c = o.move("[");
571
+ return c += o.move(t.safe(t.associationId(e), {
572
+ before: c,
573
+ after: "]",
574
+ ...o.current()
575
+ })), c += o.move("]: "), u(), !e.url || /[\0- \u007F]/.test(e.url) ? (u = t.enter("destinationLiteral"), c += o.move("<"), c += o.move(t.safe(e.url, {
576
+ before: c,
577
+ after: ">",
578
+ ...o.current()
579
+ })), c += o.move(">")) : (u = t.enter("destinationRaw"), c += o.move(t.safe(e.url, {
580
+ before: c,
581
+ after: e.title ? " " : `
582
+ `,
583
+ ...o.current()
584
+ }))), u(), e.title && (u = t.enter(`title${l}`), c += o.move(" " + a), c += o.move(t.safe(e.title, {
585
+ before: c,
586
+ after: a,
587
+ ...o.current()
588
+ })), c += o.move(a), u()), i(), c;
589
+ }
590
+ function qt(e) {
591
+ const n = e.options.emphasis || "*";
592
+ if (n !== "*" && n !== "_") throw new Error("Cannot serialize emphasis with `" + n + "` for `options.emphasis`, expected `*`, or `_`");
593
+ return n;
594
+ }
595
+ function _(e) {
596
+ return "&#x" + e.toString(16).toUpperCase() + ";";
597
+ }
598
+ function q(e, n, t) {
599
+ const r = W(e), a = W(n);
600
+ return r === void 0 ? a === void 0 ? t === "_" ? {
601
+ inside: !0,
602
+ outside: !0
603
+ } : {
604
+ inside: !1,
605
+ outside: !1
606
+ } : a === 1 ? {
607
+ inside: !0,
608
+ outside: !0
609
+ } : {
610
+ inside: !1,
611
+ outside: !0
612
+ } : r === 1 ? a === void 0 ? {
613
+ inside: !1,
614
+ outside: !1
615
+ } : a === 1 ? {
616
+ inside: !0,
617
+ outside: !0
618
+ } : {
619
+ inside: !1,
620
+ outside: !1
621
+ } : a === void 0 ? {
622
+ inside: !1,
623
+ outside: !1
624
+ } : a === 1 ? {
625
+ inside: !0,
626
+ outside: !1
627
+ } : {
628
+ inside: !1,
629
+ outside: !1
630
+ };
631
+ }
632
+ we.peek = Ht;
633
+ function we(e, n, t, r) {
634
+ const a = qt(t), l = t.enter("emphasis"), i = t.createTracker(r), u = i.move(a);
635
+ let o = i.move(t.containerPhrasing(e, {
636
+ after: a,
637
+ before: u,
638
+ ...i.current()
639
+ }));
640
+ const c = o.charCodeAt(0), h = q(r.before.charCodeAt(r.before.length - 1), c, a);
641
+ h.inside && (o = _(c) + o.slice(1));
642
+ const s = o.charCodeAt(o.length - 1), g = q(r.after.charCodeAt(0), s, a);
643
+ g.inside && (o = o.slice(0, -1) + _(s));
644
+ const p = i.move(a);
645
+ return l(), t.attentionEncodeSurroundingInfo = {
646
+ after: g.outside,
647
+ before: h.outside
648
+ }, u + o + p;
649
+ }
650
+ function Ht(e, n, t) {
651
+ return t.options.emphasis || "*";
652
+ }
653
+ function Ut(e, n, t, r) {
654
+ let a, l, i;
655
+ typeof n == "function" && typeof t != "function" ? (l = void 0, i = n, a = t) : (l = n, i = t, a = r), pe(e, l, u, a);
656
+ function u(o, c) {
657
+ const h = c[c.length - 1], s = h ? h.children.indexOf(o) : void 0;
658
+ return i(o, s, h);
659
+ }
660
+ }
661
+ function Nt(e, n) {
662
+ let t = !1;
663
+ return Ut(e, function(r) {
664
+ if ("value" in r && /\r?\n|\r/.test(r.value) || r.type === "break")
665
+ return t = !0, !1;
666
+ }), !!((!e.depth || e.depth < 3) && he(e) && (n.options.setext || t));
667
+ }
668
+ function Vt(e, n, t, r) {
669
+ const a = Math.max(Math.min(6, e.depth || 1), 1), l = t.createTracker(r);
670
+ if (Nt(e, t)) {
671
+ const h = t.enter("headingSetext"), s = t.enter("phrasing"), g = t.containerPhrasing(e, {
672
+ ...l.current(),
673
+ before: `
674
+ `,
675
+ after: `
676
+ `
677
+ });
678
+ return s(), h(), g + `
679
+ ` + (a === 1 ? "=" : "-").repeat(g.length - (Math.max(g.lastIndexOf("\r"), g.lastIndexOf(`
680
+ `)) + 1));
681
+ }
682
+ const i = "#".repeat(a), u = t.enter("headingAtx"), o = t.enter("phrasing");
683
+ l.move(i + " ");
684
+ let c = t.containerPhrasing(e, {
685
+ before: "# ",
686
+ after: `
687
+ `,
688
+ ...l.current()
689
+ });
690
+ return /^[\t ]/.test(c) && (c = _(c.charCodeAt(0)) + c.slice(1)), c = c ? i + " " + c : i, t.options.closeAtx && (c += " " + i), o(), u(), c;
691
+ }
692
+ de.peek = Gt;
693
+ function de(e) {
694
+ return e.value || "";
695
+ }
696
+ function Gt() {
697
+ return "<";
698
+ }
699
+ ye.peek = Qt;
700
+ function ye(e, n, t, r) {
701
+ const a = Y(t), l = a === '"' ? "Quote" : "Apostrophe", i = t.enter("image");
702
+ let u = t.enter("label");
703
+ const o = t.createTracker(r);
704
+ let c = o.move("![");
705
+ return c += o.move(t.safe(e.alt, {
706
+ before: c,
707
+ after: "]",
708
+ ...o.current()
709
+ })), c += o.move("]("), u(), !e.url && e.title || /[\0- \u007F]/.test(e.url) ? (u = t.enter("destinationLiteral"), c += o.move("<"), c += o.move(t.safe(e.url, {
710
+ before: c,
711
+ after: ">",
712
+ ...o.current()
713
+ })), c += o.move(">")) : (u = t.enter("destinationRaw"), c += o.move(t.safe(e.url, {
714
+ before: c,
715
+ after: e.title ? " " : ")",
716
+ ...o.current()
717
+ }))), u(), e.title && (u = t.enter(`title${l}`), c += o.move(" " + a), c += o.move(t.safe(e.title, {
718
+ before: c,
719
+ after: a,
720
+ ...o.current()
721
+ })), c += o.move(a), u()), c += o.move(")"), i(), c;
722
+ }
723
+ function Qt() {
724
+ return "!";
725
+ }
726
+ ve.peek = Kt;
727
+ function ve(e, n, t, r) {
728
+ const a = e.referenceType, l = t.enter("imageReference");
729
+ let i = t.enter("label");
730
+ const u = t.createTracker(r);
731
+ let o = u.move("![");
732
+ const c = t.safe(e.alt, {
733
+ before: o,
734
+ after: "]",
735
+ ...u.current()
736
+ });
737
+ o += u.move(c + "]["), i();
738
+ const h = t.stack;
739
+ t.stack = [], i = t.enter("reference");
740
+ const s = t.safe(t.associationId(e), {
741
+ before: o,
742
+ after: "]",
743
+ ...u.current()
744
+ });
745
+ return i(), t.stack = h, l(), a === "full" || !c || c !== s ? o += u.move(s + "]") : a === "shortcut" ? o = o.slice(0, -1) : o += u.move("]"), o;
746
+ }
747
+ function Kt() {
748
+ return "!";
749
+ }
750
+ Ce.peek = Zt;
751
+ function Ce(e, n, t) {
752
+ let r = e.value || "", a = "`", l = -1;
753
+ for (; new RegExp("(^|[^`])" + a + "([^`]|$)").test(r); ) a += "`";
754
+ for (/[^ \r\n]/.test(r) && (/^[ \r\n]/.test(r) && /[ \r\n]$/.test(r) || /^`|`$/.test(r)) && (r = " " + r + " "); ++l < t.unsafe.length; ) {
755
+ const i = t.unsafe[l], u = t.compilePattern(i);
756
+ let o;
757
+ if (i.atBreak)
758
+ for (; o = u.exec(r); ) {
759
+ let c = o.index;
760
+ r.charCodeAt(c) === 10 && r.charCodeAt(c - 1) === 13 && c--, r = r.slice(0, c) + " " + r.slice(o.index + 1);
761
+ }
762
+ }
763
+ return a + r + a;
764
+ }
765
+ function Zt() {
766
+ return "`";
767
+ }
768
+ function Ae(e, n) {
769
+ const t = he(e);
770
+ return !!(!n.options.resourceLink && e.url && !e.title && e.children && e.children.length === 1 && e.children[0].type === "text" && (t === e.url || "mailto:" + t === e.url) && /^[a-z][a-z+.-]+:/i.test(e.url) && !/[\0- <>\u007F]/.test(e.url));
771
+ }
772
+ De.peek = Jt;
773
+ function De(e, n, t, r) {
774
+ const a = Y(t), l = a === '"' ? "Quote" : "Apostrophe", i = t.createTracker(r);
775
+ let u, o;
776
+ if (Ae(e, t)) {
777
+ const h = t.stack;
778
+ t.stack = [], u = t.enter("autolink");
779
+ let s = i.move("<");
780
+ return s += i.move(t.containerPhrasing(e, {
781
+ before: s,
782
+ after: ">",
783
+ ...i.current()
784
+ })), s += i.move(">"), u(), t.stack = h, s;
785
+ }
786
+ u = t.enter("link"), o = t.enter("label");
787
+ let c = i.move("[");
788
+ return c += i.move(t.containerPhrasing(e, {
789
+ before: c,
790
+ after: "](",
791
+ ...i.current()
792
+ })), c += i.move("]("), o(), !e.url && e.title || /[\0- \u007F]/.test(e.url) ? (o = t.enter("destinationLiteral"), c += i.move("<"), c += i.move(t.safe(e.url, {
793
+ before: c,
794
+ after: ">",
795
+ ...i.current()
796
+ })), c += i.move(">")) : (o = t.enter("destinationRaw"), c += i.move(t.safe(e.url, {
797
+ before: c,
798
+ after: e.title ? " " : ")",
799
+ ...i.current()
800
+ }))), o(), e.title && (o = t.enter(`title${l}`), c += i.move(" " + a), c += i.move(t.safe(e.title, {
801
+ before: c,
802
+ after: a,
803
+ ...i.current()
804
+ })), c += i.move(a), o()), c += i.move(")"), u(), c;
805
+ }
806
+ function Jt(e, n, t) {
807
+ return Ae(e, t) ? "<" : "[";
808
+ }
809
+ Fe.peek = Xt;
810
+ function Fe(e, n, t, r) {
811
+ const a = e.referenceType, l = t.enter("linkReference");
812
+ let i = t.enter("label");
813
+ const u = t.createTracker(r);
814
+ let o = u.move("[");
815
+ const c = t.containerPhrasing(e, {
816
+ before: o,
817
+ after: "]",
818
+ ...u.current()
819
+ });
820
+ o += u.move(c + "]["), i();
821
+ const h = t.stack;
822
+ t.stack = [], i = t.enter("reference");
823
+ const s = t.safe(t.associationId(e), {
824
+ before: o,
825
+ after: "]",
826
+ ...u.current()
827
+ });
828
+ return i(), t.stack = h, l(), a === "full" || !c || c !== s ? o += u.move(s + "]") : a === "shortcut" ? o = o.slice(0, -1) : o += u.move("]"), o;
829
+ }
830
+ function Xt() {
831
+ return "[";
832
+ }
833
+ function ee(e) {
834
+ const n = e.options.bullet || "*";
835
+ if (n !== "*" && n !== "+" && n !== "-") throw new Error("Cannot serialize items with `" + n + "` for `options.bullet`, expected `*`, `+`, or `-`");
836
+ return n;
837
+ }
838
+ function Yt(e) {
839
+ const n = ee(e), t = e.options.bulletOther;
840
+ if (!t) return n === "*" ? "-" : "*";
841
+ if (t !== "*" && t !== "+" && t !== "-") throw new Error("Cannot serialize items with `" + t + "` for `options.bulletOther`, expected `*`, `+`, or `-`");
842
+ if (t === n) throw new Error("Expected `bullet` (`" + n + "`) and `bulletOther` (`" + t + "`) to be different");
843
+ return t;
844
+ }
845
+ function en(e) {
846
+ const n = e.options.bulletOrdered || ".";
847
+ if (n !== "." && n !== ")") throw new Error("Cannot serialize items with `" + n + "` for `options.bulletOrdered`, expected `.` or `)`");
848
+ return n;
849
+ }
850
+ function Se(e) {
851
+ const n = e.options.rule || "*";
852
+ if (n !== "*" && n !== "-" && n !== "_") throw new Error("Cannot serialize rules with `" + n + "` for `options.rule`, expected `*`, `-`, or `_`");
853
+ return n;
854
+ }
855
+ function tn(e, n, t, r) {
856
+ const a = t.enter("list"), l = t.bulletCurrent;
857
+ let i = e.ordered ? en(t) : ee(t);
858
+ const u = e.ordered ? i === "." ? ")" : "." : Yt(t);
859
+ let o = n && t.bulletLastUsed ? i === t.bulletLastUsed : !1;
860
+ if (!e.ordered) {
861
+ const h = e.children ? e.children[0] : void 0;
862
+ if ((i === "*" || i === "-") && h && (!h.children || !h.children[0]) && t.stack[t.stack.length - 1] === "list" && t.stack[t.stack.length - 2] === "listItem" && t.stack[t.stack.length - 3] === "list" && t.stack[t.stack.length - 4] === "listItem" && t.indexStack[t.indexStack.length - 1] === 0 && t.indexStack[t.indexStack.length - 2] === 0 && t.indexStack[t.indexStack.length - 3] === 0 && (o = !0), Se(t) === i && h) {
863
+ let s = -1;
864
+ for (; ++s < e.children.length; ) {
865
+ const g = e.children[s];
866
+ if (g && g.type === "listItem" && g.children && g.children[0] && g.children[0].type === "thematicBreak") {
867
+ o = !0;
868
+ break;
869
+ }
870
+ }
871
+ }
872
+ }
873
+ o && (i = u), t.bulletCurrent = i;
874
+ const c = t.containerFlow(e, r);
875
+ return t.bulletLastUsed = i, t.bulletCurrent = l, a(), c;
876
+ }
877
+ function nn(e) {
878
+ const n = e.options.listItemIndent || "one";
879
+ if (n !== "tab" && n !== "one" && n !== "mixed") throw new Error("Cannot serialize items with `" + n + "` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");
880
+ return n;
881
+ }
882
+ function rn(e, n, t, r) {
883
+ const a = nn(t);
884
+ let l = t.bulletCurrent || ee(t);
885
+ n && n.type === "list" && n.ordered && (l = (typeof n.start == "number" && n.start > -1 ? n.start : 1) + (t.options.incrementListMarker === !1 ? 0 : n.children.indexOf(e)) + l);
886
+ let i = l.length + 1;
887
+ (a === "tab" || a === "mixed" && (n && n.type === "list" && n.spread || e.spread)) && (i = Math.ceil(i / 4) * 4);
888
+ const u = t.createTracker(r);
889
+ u.move(l + " ".repeat(i - l.length)), u.shift(i);
890
+ const o = t.enter("listItem"), c = t.indentLines(t.containerFlow(e, u.current()), h);
891
+ return o(), c;
892
+ function h(s, g, p) {
893
+ return g ? (p ? "" : " ".repeat(i)) + s : (p ? l : l + " ".repeat(i - l.length)) + s;
894
+ }
895
+ }
896
+ function ln(e, n, t, r) {
897
+ const a = t.enter("paragraph"), l = t.enter("phrasing"), i = t.containerPhrasing(e, r);
898
+ return l(), a(), i;
899
+ }
900
+ var on = H([
901
+ "break",
902
+ "delete",
903
+ "emphasis",
904
+ "footnote",
905
+ "footnoteReference",
906
+ "image",
907
+ "imageReference",
908
+ "inlineCode",
909
+ "inlineMath",
910
+ "link",
911
+ "linkReference",
912
+ "mdxJsxTextElement",
913
+ "mdxTextExpression",
914
+ "strong",
915
+ "text",
916
+ "textDirective"
917
+ ]);
918
+ function an(e, n, t, r) {
919
+ return (e.children.some(function(a) {
920
+ return on(a);
921
+ }) ? t.containerPhrasing : t.containerFlow).call(t, e, r);
922
+ }
923
+ function un(e) {
924
+ const n = e.options.strong || "*";
925
+ if (n !== "*" && n !== "_") throw new Error("Cannot serialize strong with `" + n + "` for `options.strong`, expected `*`, or `_`");
926
+ return n;
927
+ }
928
+ Le.peek = sn;
929
+ function Le(e, n, t, r) {
930
+ const a = un(t), l = t.enter("strong"), i = t.createTracker(r), u = i.move(a + a);
931
+ let o = i.move(t.containerPhrasing(e, {
932
+ after: a,
933
+ before: u,
934
+ ...i.current()
935
+ }));
936
+ const c = o.charCodeAt(0), h = q(r.before.charCodeAt(r.before.length - 1), c, a);
937
+ h.inside && (o = _(c) + o.slice(1));
938
+ const s = o.charCodeAt(o.length - 1), g = q(r.after.charCodeAt(0), s, a);
939
+ g.inside && (o = o.slice(0, -1) + _(s));
940
+ const p = i.move(a + a);
941
+ return l(), t.attentionEncodeSurroundingInfo = {
942
+ after: g.outside,
943
+ before: h.outside
944
+ }, u + o + p;
945
+ }
946
+ function sn(e, n, t) {
947
+ return t.options.strong || "*";
948
+ }
949
+ function cn(e, n, t, r) {
950
+ return t.safe(e.value, r);
951
+ }
952
+ function fn(e) {
953
+ const n = e.options.ruleRepetition || 3;
954
+ if (n < 3) throw new Error("Cannot serialize rules with repetition `" + n + "` for `options.ruleRepetition`, expected `3` or more");
955
+ return n;
956
+ }
957
+ function hn(e, n, t) {
958
+ const r = (Se(t) + (t.options.ruleSpaces ? " " : "")).repeat(fn(t));
959
+ return t.options.ruleSpaces ? r.slice(0, -1) : r;
960
+ }
961
+ var Te = {
962
+ blockquote: Rt,
963
+ break: ue,
964
+ code: Bt,
965
+ definition: Wt,
966
+ emphasis: we,
967
+ hardBreak: ue,
968
+ heading: Vt,
969
+ html: de,
970
+ image: ye,
971
+ imageReference: ve,
972
+ inlineCode: Ce,
973
+ link: De,
974
+ linkReference: Fe,
975
+ list: tn,
976
+ listItem: rn,
977
+ paragraph: ln,
978
+ root: an,
979
+ strong: Le,
980
+ text: cn,
981
+ thematicBreak: hn
982
+ };
983
+ function mn() {
984
+ return {
985
+ enter: {
986
+ table: pn,
987
+ tableData: se,
988
+ tableHeader: se,
989
+ tableRow: kn
990
+ },
991
+ exit: {
992
+ codeText: bn,
993
+ table: gn,
994
+ tableData: K,
995
+ tableHeader: K,
996
+ tableRow: K
997
+ }
998
+ };
999
+ }
1000
+ function pn(e) {
1001
+ const n = e._align;
1002
+ this.enter({
1003
+ type: "table",
1004
+ align: n.map(function(t) {
1005
+ return t === "none" ? null : t;
1006
+ }),
1007
+ children: []
1008
+ }, e), this.data.inTable = !0;
1009
+ }
1010
+ function gn(e) {
1011
+ this.exit(e), this.data.inTable = void 0;
1012
+ }
1013
+ function kn(e) {
1014
+ this.enter({
1015
+ type: "tableRow",
1016
+ children: []
1017
+ }, e);
1018
+ }
1019
+ function K(e) {
1020
+ this.exit(e);
1021
+ }
1022
+ function se(e) {
1023
+ this.enter({
1024
+ type: "tableCell",
1025
+ children: []
1026
+ }, e);
1027
+ }
1028
+ function bn(e) {
1029
+ let n = this.resume();
1030
+ this.data.inTable && (n = n.replace(/\\([\\|])/g, xn));
1031
+ const t = this.stack[this.stack.length - 1];
1032
+ t.type, t.value = n, this.exit(e);
1033
+ }
1034
+ function xn(e, n) {
1035
+ return n === "|" ? n : e;
1036
+ }
1037
+ function wn(e) {
1038
+ const n = e || {}, t = n.tableCellPadding, r = n.tablePipeAlign, a = n.stringLength, l = t ? " " : "|";
1039
+ return {
1040
+ unsafe: [
1041
+ {
1042
+ character: "\r",
1043
+ inConstruct: "tableCell"
1044
+ },
1045
+ {
1046
+ character: `
1047
+ `,
1048
+ inConstruct: "tableCell"
1049
+ },
1050
+ {
1051
+ atBreak: !0,
1052
+ character: "|",
1053
+ after: "[ :-]"
1054
+ },
1055
+ {
1056
+ character: "|",
1057
+ inConstruct: "tableCell"
1058
+ },
1059
+ {
1060
+ atBreak: !0,
1061
+ character: ":",
1062
+ after: "-"
1063
+ },
1064
+ {
1065
+ atBreak: !0,
1066
+ character: "-",
1067
+ after: "[:|-]"
1068
+ }
1069
+ ],
1070
+ handlers: {
1071
+ inlineCode: g,
1072
+ table: i,
1073
+ tableCell: o,
1074
+ tableRow: u
1075
+ }
1076
+ };
1077
+ function i(p, m, b, x) {
1078
+ return c(h(p, b, x), p.align);
1079
+ }
1080
+ function u(p, m, b, x) {
1081
+ const k = c([s(p, b, x)]);
1082
+ return k.slice(0, k.indexOf(`
1083
+ `));
1084
+ }
1085
+ function o(p, m, b, x) {
1086
+ const k = b.enter("tableCell"), w = b.enter("phrasing"), d = b.containerPhrasing(p, {
1087
+ ...x,
1088
+ before: l,
1089
+ after: l
1090
+ });
1091
+ return w(), k(), d;
1092
+ }
1093
+ function c(p, m) {
1094
+ return It(p, {
1095
+ align: m,
1096
+ alignDelimiters: r,
1097
+ padding: t,
1098
+ stringLength: a
1099
+ });
1100
+ }
1101
+ function h(p, m, b) {
1102
+ const x = p.children;
1103
+ let k = -1;
1104
+ const w = [], d = m.enter("table");
1105
+ for (; ++k < x.length; ) w[k] = s(x[k], m, b);
1106
+ return d(), w;
1107
+ }
1108
+ function s(p, m, b) {
1109
+ const x = p.children;
1110
+ let k = -1;
1111
+ const w = [], d = m.enter("tableRow");
1112
+ for (; ++k < x.length; ) w[k] = o(x[k], p, m, b);
1113
+ return d(), w;
1114
+ }
1115
+ function g(p, m, b) {
1116
+ let x = Te.inlineCode(p, m, b);
1117
+ return b.stack.includes("tableCell") && (x = x.replace(/\|/g, "\\$&")), x;
1118
+ }
1119
+ }
1120
+ function dn() {
1121
+ return { exit: {
1122
+ taskListCheckValueChecked: ce,
1123
+ taskListCheckValueUnchecked: ce,
1124
+ paragraph: vn
1125
+ } };
1126
+ }
1127
+ function yn() {
1128
+ return {
1129
+ unsafe: [{
1130
+ atBreak: !0,
1131
+ character: "-",
1132
+ after: "[:|-]"
1133
+ }],
1134
+ handlers: { listItem: Cn }
1135
+ };
1136
+ }
1137
+ function ce(e) {
1138
+ const n = this.stack[this.stack.length - 2];
1139
+ n.type, n.checked = e.type === "taskListCheckValueChecked";
1140
+ }
1141
+ function vn(e) {
1142
+ const n = this.stack[this.stack.length - 2];
1143
+ if (n && n.type === "listItem" && typeof n.checked == "boolean") {
1144
+ const t = this.stack[this.stack.length - 1];
1145
+ t.type;
1146
+ const r = t.children[0];
1147
+ if (r && r.type === "text") {
1148
+ const a = n.children;
1149
+ let l = -1, i;
1150
+ for (; ++l < a.length; ) {
1151
+ const u = a[l];
1152
+ if (u.type === "paragraph") {
1153
+ i = u;
1154
+ break;
1155
+ }
1156
+ }
1157
+ i === t && (r.value = r.value.slice(1), r.value.length === 0 ? t.children.shift() : t.position && r.position && typeof r.position.start.offset == "number" && (r.position.start.column++, r.position.start.offset++, t.position.start = Object.assign({}, r.position.start)));
1158
+ }
1159
+ }
1160
+ this.exit(e);
1161
+ }
1162
+ function Cn(e, n, t, r) {
1163
+ const a = e.children[0], l = typeof e.checked == "boolean" && a && a.type === "paragraph", i = "[" + (e.checked ? "x" : " ") + "] ", u = t.createTracker(r);
1164
+ l && u.move(i);
1165
+ let o = Te.listItem(e, n, t, {
1166
+ ...r,
1167
+ ...u.current()
1168
+ });
1169
+ return l && (o = o.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/, c)), o;
1170
+ function c(h) {
1171
+ return h + i;
1172
+ }
1173
+ }
1174
+ function An() {
1175
+ return [
1176
+ et(),
1177
+ yt(),
1178
+ Dt(),
1179
+ mn(),
1180
+ dn()
1181
+ ];
1182
+ }
1183
+ function Dn(e) {
1184
+ return { extensions: [
1185
+ tt(),
1186
+ vt(e),
1187
+ Ft(),
1188
+ wn(e),
1189
+ yn()
1190
+ ] };
1191
+ }
1192
+ var Fn = {
1193
+ tokenize: En,
1194
+ partial: !0
1195
+ }, ze = {
1196
+ tokenize: Rn,
1197
+ partial: !0
1198
+ }, Ie = {
1199
+ tokenize: Pn,
1200
+ partial: !0
1201
+ }, Ee = {
1202
+ tokenize: Mn,
1203
+ partial: !0
1204
+ }, Sn = {
1205
+ tokenize: _n,
1206
+ partial: !0
1207
+ }, Re = {
1208
+ name: "wwwAutolink",
1209
+ tokenize: zn,
1210
+ previous: Me
1211
+ }, Pe = {
1212
+ name: "protocolAutolink",
1213
+ tokenize: In,
1214
+ previous: _e
1215
+ }, D = {
1216
+ name: "emailAutolink",
1217
+ tokenize: Tn,
1218
+ previous: Oe
1219
+ }, A = {};
1220
+ function Ln() {
1221
+ return { text: A };
1222
+ }
1223
+ var S = 48;
1224
+ for (; S < 123; )
1225
+ A[S] = D, S++, S === 58 ? S = 65 : S === 91 && (S = 97);
1226
+ A[43] = D;
1227
+ A[45] = D;
1228
+ A[46] = D;
1229
+ A[95] = D;
1230
+ A[72] = [D, Pe];
1231
+ A[104] = [D, Pe];
1232
+ A[87] = [D, Re];
1233
+ A[119] = [D, Re];
1234
+ function Tn(e, n, t) {
1235
+ const r = this;
1236
+ let a, l;
1237
+ return i;
1238
+ function i(s) {
1239
+ return !Z(s) || !Oe.call(r, r.previous) || te(r.events) ? t(s) : (e.enter("literalAutolink"), e.enter("literalAutolinkEmail"), u(s));
1240
+ }
1241
+ function u(s) {
1242
+ return Z(s) ? (e.consume(s), u) : s === 64 ? (e.consume(s), o) : t(s);
1243
+ }
1244
+ function o(s) {
1245
+ return s === 46 ? e.check(Sn, h, c)(s) : s === 45 || s === 95 || X(s) ? (l = !0, e.consume(s), o) : h(s);
1246
+ }
1247
+ function c(s) {
1248
+ return e.consume(s), a = !0, o;
1249
+ }
1250
+ function h(s) {
1251
+ return l && a && M(r.previous) ? (e.exit("literalAutolinkEmail"), e.exit("literalAutolink"), n(s)) : t(s);
1252
+ }
1253
+ }
1254
+ function zn(e, n, t) {
1255
+ const r = this;
1256
+ return a;
1257
+ function a(i) {
1258
+ return i !== 87 && i !== 119 || !Me.call(r, r.previous) || te(r.events) ? t(i) : (e.enter("literalAutolink"), e.enter("literalAutolinkWww"), e.check(Fn, e.attempt(ze, e.attempt(Ie, l), t), t)(i));
1259
+ }
1260
+ function l(i) {
1261
+ return e.exit("literalAutolinkWww"), e.exit("literalAutolink"), n(i);
1262
+ }
1263
+ }
1264
+ function In(e, n, t) {
1265
+ const r = this;
1266
+ let a = "", l = !1;
1267
+ return i;
1268
+ function i(s) {
1269
+ return (s === 72 || s === 104) && _e.call(r, r.previous) && !te(r.events) ? (e.enter("literalAutolink"), e.enter("literalAutolinkHttp"), a += String.fromCodePoint(s), e.consume(s), u) : t(s);
1270
+ }
1271
+ function u(s) {
1272
+ if (M(s) && a.length < 5)
1273
+ return a += String.fromCodePoint(s), e.consume(s), u;
1274
+ if (s === 58) {
1275
+ const g = a.toLowerCase();
1276
+ if (g === "http" || g === "https")
1277
+ return e.consume(s), o;
1278
+ }
1279
+ return t(s);
1280
+ }
1281
+ function o(s) {
1282
+ return s === 47 ? (e.consume(s), l ? c : (l = !0, o)) : t(s);
1283
+ }
1284
+ function c(s) {
1285
+ return s === null || $e(s) || v(s) || I(s) || J(s) ? t(s) : e.attempt(ze, e.attempt(Ie, h), t)(s);
1286
+ }
1287
+ function h(s) {
1288
+ return e.exit("literalAutolinkHttp"), e.exit("literalAutolink"), n(s);
1289
+ }
1290
+ }
1291
+ function En(e, n, t) {
1292
+ let r = 0;
1293
+ return a;
1294
+ function a(i) {
1295
+ return (i === 87 || i === 119) && r < 3 ? (r++, e.consume(i), a) : i === 46 && r === 3 ? (e.consume(i), l) : t(i);
1296
+ }
1297
+ function l(i) {
1298
+ return i === null ? t(i) : n(i);
1299
+ }
1300
+ }
1301
+ function Rn(e, n, t) {
1302
+ let r, a, l;
1303
+ return i;
1304
+ function i(c) {
1305
+ return c === 46 || c === 95 ? e.check(Ee, o, u)(c) : c === null || v(c) || I(c) || c !== 45 && J(c) ? o(c) : (l = !0, e.consume(c), i);
1306
+ }
1307
+ function u(c) {
1308
+ return c === 95 ? r = !0 : (a = r, r = void 0), e.consume(c), i;
1309
+ }
1310
+ function o(c) {
1311
+ return a || r || !l ? t(c) : n(c);
1312
+ }
1313
+ }
1314
+ function Pn(e, n) {
1315
+ let t = 0, r = 0;
1316
+ return a;
1317
+ function a(i) {
1318
+ return i === 40 ? (t++, e.consume(i), a) : i === 41 && r < t ? l(i) : i === 33 || i === 34 || i === 38 || i === 39 || i === 41 || i === 42 || i === 44 || i === 46 || i === 58 || i === 59 || i === 60 || i === 63 || i === 93 || i === 95 || i === 126 ? e.check(Ee, n, l)(i) : i === null || v(i) || I(i) ? n(i) : (e.consume(i), a);
1319
+ }
1320
+ function l(i) {
1321
+ return i === 41 && r++, e.consume(i), a;
1322
+ }
1323
+ }
1324
+ function Mn(e, n, t) {
1325
+ return r;
1326
+ function r(u) {
1327
+ return u === 33 || u === 34 || u === 39 || u === 41 || u === 42 || u === 44 || u === 46 || u === 58 || u === 59 || u === 63 || u === 95 || u === 126 ? (e.consume(u), r) : u === 38 ? (e.consume(u), l) : u === 93 ? (e.consume(u), a) : u === 60 || u === null || v(u) || I(u) ? n(u) : t(u);
1328
+ }
1329
+ function a(u) {
1330
+ return u === null || u === 40 || u === 91 || v(u) || I(u) ? n(u) : r(u);
1331
+ }
1332
+ function l(u) {
1333
+ return M(u) ? i(u) : t(u);
1334
+ }
1335
+ function i(u) {
1336
+ return u === 59 ? (e.consume(u), r) : M(u) ? (e.consume(u), i) : t(u);
1337
+ }
1338
+ }
1339
+ function _n(e, n, t) {
1340
+ return r;
1341
+ function r(l) {
1342
+ return e.consume(l), a;
1343
+ }
1344
+ function a(l) {
1345
+ return X(l) ? t(l) : n(l);
1346
+ }
1347
+ }
1348
+ function Me(e) {
1349
+ return e === null || e === 40 || e === 42 || e === 95 || e === 91 || e === 93 || e === 126 || v(e);
1350
+ }
1351
+ function _e(e) {
1352
+ return !M(e);
1353
+ }
1354
+ function Oe(e) {
1355
+ return !(e === 47 || Z(e));
1356
+ }
1357
+ function Z(e) {
1358
+ return e === 43 || e === 45 || e === 46 || e === 95 || X(e);
1359
+ }
1360
+ function te(e) {
1361
+ let n = e.length, t = !1;
1362
+ for (; n--; ) {
1363
+ const r = e[n][1];
1364
+ if ((r.type === "labelLink" || r.type === "labelImage") && !r._balanced) {
1365
+ t = !0;
1366
+ break;
1367
+ }
1368
+ if (r._gfmAutolinkLiteralWalkedInto) {
1369
+ t = !1;
1370
+ break;
1371
+ }
1372
+ }
1373
+ return e.length > 0 && !t && (e[e.length - 1][1]._gfmAutolinkLiteralWalkedInto = !0), t;
1374
+ }
1375
+ var On = {
1376
+ tokenize: Nn,
1377
+ partial: !0
1378
+ };
1379
+ function jn() {
1380
+ return {
1381
+ document: { 91: {
1382
+ name: "gfmFootnoteDefinition",
1383
+ tokenize: qn,
1384
+ continuation: { tokenize: Hn },
1385
+ exit: Un
1386
+ } },
1387
+ text: {
1388
+ 91: {
1389
+ name: "gfmFootnoteCall",
1390
+ tokenize: Wn
1391
+ },
1392
+ 93: {
1393
+ name: "gfmPotentialFootnoteCall",
1394
+ add: "after",
1395
+ tokenize: Bn,
1396
+ resolveTo: $n
1397
+ }
1398
+ }
1399
+ };
1400
+ }
1401
+ function Bn(e, n, t) {
1402
+ const r = this;
1403
+ let a = r.events.length;
1404
+ const l = r.parser.gfmFootnotes || (r.parser.gfmFootnotes = []);
1405
+ let i;
1406
+ for (; a--; ) {
1407
+ const o = r.events[a][1];
1408
+ if (o.type === "labelImage") {
1409
+ i = o;
1410
+ break;
1411
+ }
1412
+ if (o.type === "gfmFootnoteCall" || o.type === "labelLink" || o.type === "label" || o.type === "image" || o.type === "link") break;
1413
+ }
1414
+ return u;
1415
+ function u(o) {
1416
+ if (!i || !i._balanced) return t(o);
1417
+ const c = O(r.sliceSerialize({
1418
+ start: i.end,
1419
+ end: r.now()
1420
+ }));
1421
+ return c.codePointAt(0) !== 94 || !l.includes(c.slice(1)) ? t(o) : (e.enter("gfmFootnoteCallLabelMarker"), e.consume(o), e.exit("gfmFootnoteCallLabelMarker"), n(o));
1422
+ }
1423
+ }
1424
+ function $n(e, n) {
1425
+ let t = e.length;
1426
+ for (; t--; ) if (e[t][1].type === "labelImage" && e[t][0] === "enter") {
1427
+ e[t][1];
1428
+ break;
1429
+ }
1430
+ e[t + 1][1].type = "data", e[t + 3][1].type = "gfmFootnoteCallLabelMarker";
1431
+ const r = {
1432
+ type: "gfmFootnoteCall",
1433
+ start: Object.assign({}, e[t + 3][1].start),
1434
+ end: Object.assign({}, e[e.length - 1][1].end)
1435
+ }, a = {
1436
+ type: "gfmFootnoteCallMarker",
1437
+ start: Object.assign({}, e[t + 3][1].end),
1438
+ end: Object.assign({}, e[t + 3][1].end)
1439
+ };
1440
+ a.end.column++, a.end.offset++, a.end._bufferIndex++;
1441
+ const l = {
1442
+ type: "gfmFootnoteCallString",
1443
+ start: Object.assign({}, a.end),
1444
+ end: Object.assign({}, e[e.length - 1][1].start)
1445
+ }, i = {
1446
+ type: "chunkString",
1447
+ contentType: "string",
1448
+ start: Object.assign({}, l.start),
1449
+ end: Object.assign({}, l.end)
1450
+ }, u = [
1451
+ e[t + 1],
1452
+ e[t + 2],
1453
+ [
1454
+ "enter",
1455
+ r,
1456
+ n
1457
+ ],
1458
+ e[t + 3],
1459
+ e[t + 4],
1460
+ [
1461
+ "enter",
1462
+ a,
1463
+ n
1464
+ ],
1465
+ [
1466
+ "exit",
1467
+ a,
1468
+ n
1469
+ ],
1470
+ [
1471
+ "enter",
1472
+ l,
1473
+ n
1474
+ ],
1475
+ [
1476
+ "enter",
1477
+ i,
1478
+ n
1479
+ ],
1480
+ [
1481
+ "exit",
1482
+ i,
1483
+ n
1484
+ ],
1485
+ [
1486
+ "exit",
1487
+ l,
1488
+ n
1489
+ ],
1490
+ e[e.length - 2],
1491
+ e[e.length - 1],
1492
+ [
1493
+ "exit",
1494
+ r,
1495
+ n
1496
+ ]
1497
+ ];
1498
+ return e.splice(t, e.length - t + 1, ...u), e;
1499
+ }
1500
+ function Wn(e, n, t) {
1501
+ const r = this, a = r.parser.gfmFootnotes || (r.parser.gfmFootnotes = []);
1502
+ let l = 0, i;
1503
+ return u;
1504
+ function u(s) {
1505
+ return e.enter("gfmFootnoteCall"), e.enter("gfmFootnoteCallLabelMarker"), e.consume(s), e.exit("gfmFootnoteCallLabelMarker"), o;
1506
+ }
1507
+ function o(s) {
1508
+ return s !== 94 ? t(s) : (e.enter("gfmFootnoteCallMarker"), e.consume(s), e.exit("gfmFootnoteCallMarker"), e.enter("gfmFootnoteCallString"), e.enter("chunkString").contentType = "string", c);
1509
+ }
1510
+ function c(s) {
1511
+ if (l > 999 || s === 93 && !i || s === null || s === 91 || v(s)) return t(s);
1512
+ if (s === 93) {
1513
+ e.exit("chunkString");
1514
+ const g = e.exit("gfmFootnoteCallString");
1515
+ return a.includes(O(r.sliceSerialize(g))) ? (e.enter("gfmFootnoteCallLabelMarker"), e.consume(s), e.exit("gfmFootnoteCallLabelMarker"), e.exit("gfmFootnoteCall"), n) : t(s);
1516
+ }
1517
+ return v(s) || (i = !0), l++, e.consume(s), s === 92 ? h : c;
1518
+ }
1519
+ function h(s) {
1520
+ return s === 91 || s === 92 || s === 93 ? (e.consume(s), l++, c) : c(s);
1521
+ }
1522
+ }
1523
+ function qn(e, n, t) {
1524
+ const r = this, a = r.parser.gfmFootnotes || (r.parser.gfmFootnotes = []);
1525
+ let l, i = 0, u;
1526
+ return o;
1527
+ function o(m) {
1528
+ return e.enter("gfmFootnoteDefinition")._container = !0, e.enter("gfmFootnoteDefinitionLabel"), e.enter("gfmFootnoteDefinitionLabelMarker"), e.consume(m), e.exit("gfmFootnoteDefinitionLabelMarker"), c;
1529
+ }
1530
+ function c(m) {
1531
+ return m === 94 ? (e.enter("gfmFootnoteDefinitionMarker"), e.consume(m), e.exit("gfmFootnoteDefinitionMarker"), e.enter("gfmFootnoteDefinitionLabelString"), e.enter("chunkString").contentType = "string", h) : t(m);
1532
+ }
1533
+ function h(m) {
1534
+ if (i > 999 || m === 93 && !u || m === null || m === 91 || v(m)) return t(m);
1535
+ if (m === 93) {
1536
+ e.exit("chunkString");
1537
+ const b = e.exit("gfmFootnoteDefinitionLabelString");
1538
+ return l = O(r.sliceSerialize(b)), e.enter("gfmFootnoteDefinitionLabelMarker"), e.consume(m), e.exit("gfmFootnoteDefinitionLabelMarker"), e.exit("gfmFootnoteDefinitionLabel"), g;
1539
+ }
1540
+ return v(m) || (u = !0), i++, e.consume(m), m === 92 ? s : h;
1541
+ }
1542
+ function s(m) {
1543
+ return m === 91 || m === 92 || m === 93 ? (e.consume(m), i++, h) : h(m);
1544
+ }
1545
+ function g(m) {
1546
+ return m === 58 ? (e.enter("definitionMarker"), e.consume(m), e.exit("definitionMarker"), a.includes(l) || a.push(l), F(e, p, "gfmFootnoteDefinitionWhitespace")) : t(m);
1547
+ }
1548
+ function p(m) {
1549
+ return n(m);
1550
+ }
1551
+ }
1552
+ function Hn(e, n, t) {
1553
+ return e.check(qe, n, e.attempt(On, n, t));
1554
+ }
1555
+ function Un(e) {
1556
+ e.exit("gfmFootnoteDefinition");
1557
+ }
1558
+ function Nn(e, n, t) {
1559
+ const r = this;
1560
+ return F(e, a, "gfmFootnoteDefinitionIndent", 5);
1561
+ function a(l) {
1562
+ const i = r.events[r.events.length - 1];
1563
+ return i && i[1].type === "gfmFootnoteDefinitionIndent" && i[2].sliceSerialize(i[1], !0).length === 4 ? n(l) : t(l);
1564
+ }
1565
+ }
1566
+ function Vn(e) {
1567
+ let n = (e || {}).singleTilde;
1568
+ const t = {
1569
+ name: "strikethrough",
1570
+ tokenize: a,
1571
+ resolveAll: r
1572
+ };
1573
+ return n == null && (n = !0), {
1574
+ text: { 126: t },
1575
+ insideSpan: { null: [t] },
1576
+ attentionMarkers: { null: [126] }
1577
+ };
1578
+ function r(l, i) {
1579
+ let u = -1;
1580
+ for (; ++u < l.length; ) if (l[u][0] === "enter" && l[u][1].type === "strikethroughSequenceTemporary" && l[u][1]._close) {
1581
+ let o = u;
1582
+ for (; o--; ) if (l[o][0] === "exit" && l[o][1].type === "strikethroughSequenceTemporary" && l[o][1]._open && l[u][1].end.offset - l[u][1].start.offset === l[o][1].end.offset - l[o][1].start.offset) {
1583
+ l[u][1].type = "strikethroughSequence", l[o][1].type = "strikethroughSequence";
1584
+ const c = {
1585
+ type: "strikethrough",
1586
+ start: Object.assign({}, l[o][1].start),
1587
+ end: Object.assign({}, l[u][1].end)
1588
+ }, h = {
1589
+ type: "strikethroughText",
1590
+ start: Object.assign({}, l[o][1].end),
1591
+ end: Object.assign({}, l[u][1].start)
1592
+ }, s = [
1593
+ [
1594
+ "enter",
1595
+ c,
1596
+ i
1597
+ ],
1598
+ [
1599
+ "enter",
1600
+ l[o][1],
1601
+ i
1602
+ ],
1603
+ [
1604
+ "exit",
1605
+ l[o][1],
1606
+ i
1607
+ ],
1608
+ [
1609
+ "enter",
1610
+ h,
1611
+ i
1612
+ ]
1613
+ ], g = i.parser.constructs.insideSpan.null;
1614
+ g && N(s, s.length, 0, We(g, l.slice(o + 1, u), i)), N(s, s.length, 0, [
1615
+ [
1616
+ "exit",
1617
+ h,
1618
+ i
1619
+ ],
1620
+ [
1621
+ "enter",
1622
+ l[u][1],
1623
+ i
1624
+ ],
1625
+ [
1626
+ "exit",
1627
+ l[u][1],
1628
+ i
1629
+ ],
1630
+ [
1631
+ "exit",
1632
+ c,
1633
+ i
1634
+ ]
1635
+ ]), N(l, o - 1, u - o + 3, s), u = o + s.length - 2;
1636
+ break;
1637
+ }
1638
+ }
1639
+ for (u = -1; ++u < l.length; ) l[u][1].type === "strikethroughSequenceTemporary" && (l[u][1].type = "data");
1640
+ return l;
1641
+ }
1642
+ function a(l, i, u) {
1643
+ const o = this.previous, c = this.events;
1644
+ let h = 0;
1645
+ return s;
1646
+ function s(p) {
1647
+ return o === 126 && c[c.length - 1][1].type !== "characterEscape" ? u(p) : (l.enter("strikethroughSequenceTemporary"), g(p));
1648
+ }
1649
+ function g(p) {
1650
+ const m = W(o);
1651
+ if (p === 126)
1652
+ return h > 1 ? u(p) : (l.consume(p), h++, g);
1653
+ if (h < 2 && !n) return u(p);
1654
+ const b = l.exit("strikethroughSequenceTemporary"), x = W(p);
1655
+ return b._open = !x || x === 2 && !!m, b._close = !m || m === 2 && !!x, i(p);
1656
+ }
1657
+ }
1658
+ }
1659
+ var Gn = class {
1660
+ constructor() {
1661
+ this.map = [];
1662
+ }
1663
+ add(e, n, t) {
1664
+ Qn(this, e, n, t);
1665
+ }
1666
+ consume(e) {
1667
+ if (this.map.sort(function(a, l) {
1668
+ return a[0] - l[0];
1669
+ }), this.map.length === 0) return;
1670
+ let n = this.map.length;
1671
+ const t = [];
1672
+ for (; n > 0; )
1673
+ n -= 1, t.push(e.slice(this.map[n][0] + this.map[n][1]), this.map[n][2]), e.length = this.map[n][0];
1674
+ t.push(e.slice()), e.length = 0;
1675
+ let r = t.pop();
1676
+ for (; r; ) {
1677
+ for (const a of r) e.push(a);
1678
+ r = t.pop();
1679
+ }
1680
+ this.map.length = 0;
1681
+ }
1682
+ };
1683
+ function Qn(e, n, t, r) {
1684
+ let a = 0;
1685
+ if (!(t === 0 && r.length === 0)) {
1686
+ for (; a < e.map.length; ) {
1687
+ if (e.map[a][0] === n) {
1688
+ e.map[a][1] += t, e.map[a][2].push(...r);
1689
+ return;
1690
+ }
1691
+ a += 1;
1692
+ }
1693
+ e.map.push([
1694
+ n,
1695
+ t,
1696
+ r
1697
+ ]);
1698
+ }
1699
+ }
1700
+ function Kn(e, n) {
1701
+ let t = !1;
1702
+ const r = [];
1703
+ for (; n < e.length; ) {
1704
+ const a = e[n];
1705
+ if (t) {
1706
+ if (a[0] === "enter")
1707
+ a[1].type === "tableContent" && r.push(e[n + 1][1].type === "tableDelimiterMarker" ? "left" : "none");
1708
+ else if (a[1].type === "tableContent") {
1709
+ if (e[n - 1][1].type === "tableDelimiterMarker") {
1710
+ const l = r.length - 1;
1711
+ r[l] = r[l] === "left" ? "center" : "right";
1712
+ }
1713
+ } else if (a[1].type === "tableDelimiterRow") break;
1714
+ } else a[0] === "enter" && a[1].type === "tableDelimiterRow" && (t = !0);
1715
+ n += 1;
1716
+ }
1717
+ return r;
1718
+ }
1719
+ function Zn() {
1720
+ return { flow: { null: {
1721
+ name: "table",
1722
+ tokenize: Jn,
1723
+ resolveAll: Xn
1724
+ } } };
1725
+ }
1726
+ function Jn(e, n, t) {
1727
+ const r = this;
1728
+ let a = 0, l = 0, i;
1729
+ return u;
1730
+ function u(f) {
1731
+ let R = r.events.length - 1;
1732
+ for (; R > -1; ) {
1733
+ const ie = r.events[R][1].type;
1734
+ if (ie === "lineEnding" || ie === "linePrefix") R--;
1735
+ else break;
1736
+ }
1737
+ const ne = R > -1 ? r.events[R][1].type : null, re = ne === "tableHead" || ne === "tableRow" ? E : o;
1738
+ return re === E && r.parser.lazy[r.now().line] ? t(f) : re(f);
1739
+ }
1740
+ function o(f) {
1741
+ return e.enter("tableHead"), e.enter("tableRow"), c(f);
1742
+ }
1743
+ function c(f) {
1744
+ return f === 124 || (i = !0, l += 1), h(f);
1745
+ }
1746
+ function h(f) {
1747
+ return f === null ? t(f) : P(f) ? l > 1 ? (l = 0, r.interrupt = !0, e.exit("tableRow"), e.enter("lineEnding"), e.consume(f), e.exit("lineEnding"), p) : t(f) : T(f) ? F(e, h, "whitespace")(f) : (l += 1, i && (i = !1, a += 1), f === 124 ? (e.enter("tableCellDivider"), e.consume(f), e.exit("tableCellDivider"), i = !0, h) : (e.enter("data"), s(f)));
1748
+ }
1749
+ function s(f) {
1750
+ return f === null || f === 124 || v(f) ? (e.exit("data"), h(f)) : (e.consume(f), f === 92 ? g : s);
1751
+ }
1752
+ function g(f) {
1753
+ return f === 92 || f === 124 ? (e.consume(f), s) : s(f);
1754
+ }
1755
+ function p(f) {
1756
+ return r.interrupt = !1, r.parser.lazy[r.now().line] ? t(f) : (e.enter("tableDelimiterRow"), i = !1, T(f) ? F(e, m, "linePrefix", r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4)(f) : m(f));
1757
+ }
1758
+ function m(f) {
1759
+ return f === 45 || f === 58 ? x(f) : f === 124 ? (i = !0, e.enter("tableCellDivider"), e.consume(f), e.exit("tableCellDivider"), b) : C(f);
1760
+ }
1761
+ function b(f) {
1762
+ return T(f) ? F(e, x, "whitespace")(f) : x(f);
1763
+ }
1764
+ function x(f) {
1765
+ return f === 58 ? (l += 1, i = !0, e.enter("tableDelimiterMarker"), e.consume(f), e.exit("tableDelimiterMarker"), k) : f === 45 ? (l += 1, k(f)) : f === null || P(f) ? y(f) : C(f);
1766
+ }
1767
+ function k(f) {
1768
+ return f === 45 ? (e.enter("tableDelimiterFiller"), w(f)) : C(f);
1769
+ }
1770
+ function w(f) {
1771
+ return f === 45 ? (e.consume(f), w) : f === 58 ? (i = !0, e.exit("tableDelimiterFiller"), e.enter("tableDelimiterMarker"), e.consume(f), e.exit("tableDelimiterMarker"), d) : (e.exit("tableDelimiterFiller"), d(f));
1772
+ }
1773
+ function d(f) {
1774
+ return T(f) ? F(e, y, "whitespace")(f) : y(f);
1775
+ }
1776
+ function y(f) {
1777
+ return f === 124 ? m(f) : f === null || P(f) ? !i || a !== l ? C(f) : (e.exit("tableDelimiterRow"), e.exit("tableHead"), n(f)) : C(f);
1778
+ }
1779
+ function C(f) {
1780
+ return t(f);
1781
+ }
1782
+ function E(f) {
1783
+ return e.enter("tableRow"), j(f);
1784
+ }
1785
+ function j(f) {
1786
+ return f === 124 ? (e.enter("tableCellDivider"), e.consume(f), e.exit("tableCellDivider"), j) : f === null || P(f) ? (e.exit("tableRow"), n(f)) : T(f) ? F(e, j, "whitespace")(f) : (e.enter("data"), B(f));
1787
+ }
1788
+ function B(f) {
1789
+ return f === null || f === 124 || v(f) ? (e.exit("data"), j(f)) : (e.consume(f), f === 92 ? je : B);
1790
+ }
1791
+ function je(f) {
1792
+ return f === 92 || f === 124 ? (e.consume(f), B) : B(f);
1793
+ }
1794
+ }
1795
+ function Xn(e, n) {
1796
+ let t = -1, r = !0, a = 0, l = [
1797
+ 0,
1798
+ 0,
1799
+ 0,
1800
+ 0
1801
+ ], i = [
1802
+ 0,
1803
+ 0,
1804
+ 0,
1805
+ 0
1806
+ ], u = !1, o = 0, c, h, s;
1807
+ const g = new Gn();
1808
+ for (; ++t < e.length; ) {
1809
+ const p = e[t], m = p[1];
1810
+ p[0] === "enter" ? m.type === "tableHead" ? (u = !1, o !== 0 && (fe(g, n, o, c, h), h = void 0, o = 0), c = {
1811
+ type: "table",
1812
+ start: Object.assign({}, m.start),
1813
+ end: Object.assign({}, m.end)
1814
+ }, g.add(t, 0, [[
1815
+ "enter",
1816
+ c,
1817
+ n
1818
+ ]])) : m.type === "tableRow" || m.type === "tableDelimiterRow" ? (r = !0, s = void 0, l = [
1819
+ 0,
1820
+ 0,
1821
+ 0,
1822
+ 0
1823
+ ], i = [
1824
+ 0,
1825
+ t + 1,
1826
+ 0,
1827
+ 0
1828
+ ], u && (u = !1, h = {
1829
+ type: "tableBody",
1830
+ start: Object.assign({}, m.start),
1831
+ end: Object.assign({}, m.end)
1832
+ }, g.add(t, 0, [[
1833
+ "enter",
1834
+ h,
1835
+ n
1836
+ ]])), a = m.type === "tableDelimiterRow" ? 2 : h ? 3 : 1) : a && (m.type === "data" || m.type === "tableDelimiterMarker" || m.type === "tableDelimiterFiller") ? (r = !1, i[2] === 0 && (l[1] !== 0 && (i[0] = i[1], s = $(g, n, l, a, void 0, s), l = [
1837
+ 0,
1838
+ 0,
1839
+ 0,
1840
+ 0
1841
+ ]), i[2] = t)) : m.type === "tableCellDivider" && (r ? r = !1 : (l[1] !== 0 && (i[0] = i[1], s = $(g, n, l, a, void 0, s)), l = i, i = [
1842
+ l[1],
1843
+ t,
1844
+ 0,
1845
+ 0
1846
+ ])) : m.type === "tableHead" ? (u = !0, o = t) : m.type === "tableRow" || m.type === "tableDelimiterRow" ? (o = t, l[1] !== 0 ? (i[0] = i[1], s = $(g, n, l, a, t, s)) : i[1] !== 0 && (s = $(g, n, i, a, t, s)), a = 0) : a && (m.type === "data" || m.type === "tableDelimiterMarker" || m.type === "tableDelimiterFiller") && (i[3] = t);
1847
+ }
1848
+ for (o !== 0 && fe(g, n, o, c, h), g.consume(n.events), t = -1; ++t < n.events.length; ) {
1849
+ const p = n.events[t];
1850
+ p[0] === "enter" && p[1].type === "table" && (p[1]._align = Kn(n.events, t));
1851
+ }
1852
+ return e;
1853
+ }
1854
+ function $(e, n, t, r, a, l) {
1855
+ const i = r === 1 ? "tableHeader" : r === 2 ? "tableDelimiter" : "tableData", u = "tableContent";
1856
+ t[0] !== 0 && (l.end = Object.assign({}, z(n.events, t[0])), e.add(t[0], 0, [[
1857
+ "exit",
1858
+ l,
1859
+ n
1860
+ ]]));
1861
+ const o = z(n.events, t[1]);
1862
+ if (l = {
1863
+ type: i,
1864
+ start: Object.assign({}, o),
1865
+ end: Object.assign({}, o)
1866
+ }, e.add(t[1], 0, [[
1867
+ "enter",
1868
+ l,
1869
+ n
1870
+ ]]), t[2] !== 0) {
1871
+ const c = z(n.events, t[2]), h = z(n.events, t[3]), s = {
1872
+ type: u,
1873
+ start: Object.assign({}, c),
1874
+ end: Object.assign({}, h)
1875
+ };
1876
+ if (e.add(t[2], 0, [[
1877
+ "enter",
1878
+ s,
1879
+ n
1880
+ ]]), r !== 2) {
1881
+ const g = n.events[t[2]], p = n.events[t[3]];
1882
+ if (g[1].end = Object.assign({}, p[1].end), g[1].type = "chunkText", g[1].contentType = "text", t[3] > t[2] + 1) {
1883
+ const m = t[2] + 1, b = t[3] - t[2] - 1;
1884
+ e.add(m, b, []);
1885
+ }
1886
+ }
1887
+ e.add(t[3] + 1, 0, [[
1888
+ "exit",
1889
+ s,
1890
+ n
1891
+ ]]);
1892
+ }
1893
+ return a !== void 0 && (l.end = Object.assign({}, z(n.events, a)), e.add(a, 0, [[
1894
+ "exit",
1895
+ l,
1896
+ n
1897
+ ]]), l = void 0), l;
1898
+ }
1899
+ function fe(e, n, t, r, a) {
1900
+ const l = [], i = z(n.events, t);
1901
+ a && (a.end = Object.assign({}, i), l.push([
1902
+ "exit",
1903
+ a,
1904
+ n
1905
+ ])), r.end = Object.assign({}, i), l.push([
1906
+ "exit",
1907
+ r,
1908
+ n
1909
+ ]), e.add(t + 1, 0, l);
1910
+ }
1911
+ function z(e, n) {
1912
+ const t = e[n], r = t[0] === "enter" ? "start" : "end";
1913
+ return t[1][r];
1914
+ }
1915
+ var Yn = {
1916
+ name: "tasklistCheck",
1917
+ tokenize: tr
1918
+ };
1919
+ function er() {
1920
+ return { text: { 91: Yn } };
1921
+ }
1922
+ function tr(e, n, t) {
1923
+ const r = this;
1924
+ return a;
1925
+ function a(o) {
1926
+ return r.previous !== null || !r._gfmTasklistFirstContentOfListItem ? t(o) : (e.enter("taskListCheck"), e.enter("taskListCheckMarker"), e.consume(o), e.exit("taskListCheckMarker"), l);
1927
+ }
1928
+ function l(o) {
1929
+ return v(o) ? (e.enter("taskListCheckValueUnchecked"), e.consume(o), e.exit("taskListCheckValueUnchecked"), i) : o === 88 || o === 120 ? (e.enter("taskListCheckValueChecked"), e.consume(o), e.exit("taskListCheckValueChecked"), i) : t(o);
1930
+ }
1931
+ function i(o) {
1932
+ return o === 93 ? (e.enter("taskListCheckMarker"), e.consume(o), e.exit("taskListCheckMarker"), e.exit("taskListCheck"), u) : t(o);
1933
+ }
1934
+ function u(o) {
1935
+ return P(o) ? n(o) : T(o) ? e.check({ tokenize: nr }, n, t)(o) : t(o);
1936
+ }
1937
+ }
1938
+ function nr(e, n, t) {
1939
+ return F(e, r, "whitespace");
1940
+ function r(a) {
1941
+ return a === null ? t(a) : n(a);
1942
+ }
1943
+ }
1944
+ function rr(e) {
1945
+ return Be([
1946
+ Ln(),
1947
+ jn(),
1948
+ Vn(e),
1949
+ Zn(),
1950
+ er()
1951
+ ]);
1952
+ }
1953
+ var ir = {};
1954
+ function ar(e) {
1955
+ const n = this, t = e || ir, r = n.data(), a = r.micromarkExtensions || (r.micromarkExtensions = []), l = r.fromMarkdownExtensions || (r.fromMarkdownExtensions = []), i = r.toMarkdownExtensions || (r.toMarkdownExtensions = []);
1956
+ a.push(rr(t)), l.push(An()), i.push(Dn(t));
1957
+ }
1958
+ export {
1959
+ ar as default,
1960
+ H as n,
1961
+ Ut as t
1962
+ };