@digipair/skill-web-chatbot 0.3.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 (100) hide show
  1. package/SAP-icons.cjs.js +2489 -0
  2. package/SAP-icons.cjs2.js +2489 -0
  3. package/SAP-icons.esm.js +2482 -0
  4. package/SAP-icons.esm2.js +2482 -0
  5. package/arc-da8fd8d8.cjs.js +88 -0
  6. package/arc-da8fd8d8.esm.js +86 -0
  7. package/array-2ff2c7a6.cjs.js +7 -0
  8. package/array-2ff2c7a6.esm.js +5 -0
  9. package/c4Diagram-1bdb45a8.cjs.js +4613 -0
  10. package/c4Diagram-1bdb45a8.esm.js +4611 -0
  11. package/classDiagram-185c1a10.cjs.js +96 -0
  12. package/classDiagram-185c1a10.esm.js +94 -0
  13. package/classDiagram-v2-6dc3b9c3.cjs.js +403 -0
  14. package/classDiagram-v2-6dc3b9c3.esm.js +401 -0
  15. package/constant-2fe7eae5.cjs.js +58 -0
  16. package/constant-2fe7eae5.esm.js +55 -0
  17. package/createText-94e3ebbf.cjs.js +2775 -0
  18. package/createText-94e3ebbf.esm.js +2773 -0
  19. package/debug.html +18 -0
  20. package/edges-558884ee.cjs.js +1450 -0
  21. package/edges-558884ee.esm.js +1436 -0
  22. package/erDiagram-97139f44.cjs.js +1949 -0
  23. package/erDiagram-97139f44.esm.js +1947 -0
  24. package/flowDb-a4faf166.cjs.js +6918 -0
  25. package/flowDb-a4faf166.esm.js +6914 -0
  26. package/flowDiagram-ccbbb58d.cjs.js +999 -0
  27. package/flowDiagram-ccbbb58d.esm.js +997 -0
  28. package/flowDiagram-v2-79ccd6da.cjs.js +29 -0
  29. package/flowDiagram-v2-79ccd6da.esm.js +27 -0
  30. package/flowchart-elk-definition-7863a61f.cjs.js +48577 -0
  31. package/flowchart-elk-definition-7863a61f.esm.js +48575 -0
  32. package/ganttDiagram-3eff0dd8.cjs.js +3855 -0
  33. package/ganttDiagram-3eff0dd8.esm.js +3853 -0
  34. package/gitGraphDiagram-c3fe571f.cjs.js +3863 -0
  35. package/gitGraphDiagram-c3fe571f.esm.js +3861 -0
  36. package/index-d0b453e2.cjs.js +609 -0
  37. package/index-d0b453e2.esm.js +607 -0
  38. package/index.cjs.d.ts +1 -0
  39. package/index.cjs.js +17 -0
  40. package/index.cjs2.js +43619 -0
  41. package/index.d.ts +1 -0
  42. package/index.esm.js +1 -0
  43. package/index.esm2.js +43493 -0
  44. package/infoDiagram-9c10eab1.cjs.js +467 -0
  45. package/infoDiagram-9c10eab1.esm.js +465 -0
  46. package/init-f9637058.cjs.js +17 -0
  47. package/init-f9637058.esm.js +15 -0
  48. package/journeyDiagram-b6904cec.cjs.js +1292 -0
  49. package/journeyDiagram-b6904cec.esm.js +1290 -0
  50. package/layout-c5a37d74.cjs.js +2808 -0
  51. package/layout-c5a37d74.esm.js +2795 -0
  52. package/libs/engine/src/index.d.ts +2 -0
  53. package/libs/engine/src/lib/engine.d.ts +27 -0
  54. package/libs/engine/src/lib/pins-settings.interface.d.ts +20 -0
  55. package/libs/skill-web-chatbot/src/index.d.ts +3 -0
  56. package/libs/skill-web-chatbot/src/lib/chat.element.d.ts +23 -0
  57. package/libs/skill-web-chatbot/src/lib/common.data.d.ts +1 -0
  58. package/libs/skill-web-chatbot/src/lib/config.d.ts +9 -0
  59. package/libs/skill-web-chatbot/src/lib/digipair-full.data.d.ts +1 -0
  60. package/libs/skill-web-chatbot/src/lib/digipair-full.element.d.ts +32 -0
  61. package/libs/skill-web-chatbot/src/lib/digipair.data.d.ts +1 -0
  62. package/libs/skill-web-chatbot/src/lib/digipair.element.d.ts +39 -0
  63. package/libs/skill-web-chatbot/src/lib/inputs.element.d.ts +9 -0
  64. package/libs/skill-web-chatbot/src/lib/pins/chatbot.actions.d.ts +5 -0
  65. package/libs/skill-web-chatbot/src/lib/tools/css-selector.d.ts +1 -0
  66. package/line-ce5d1152.cjs.js +34 -0
  67. package/line-ce5d1152.esm.js +32 -0
  68. package/linear-db016d0c.cjs.js +485 -0
  69. package/linear-db016d0c.esm.js +479 -0
  70. package/mindmap-definition-a9d0f378.cjs.js +20225 -0
  71. package/mindmap-definition-a9d0f378.esm.js +20223 -0
  72. package/ordinal-5695958c.cjs.js +331 -0
  73. package/ordinal-5695958c.esm.js +329 -0
  74. package/package.json +8 -0
  75. package/pieDiagram-fd367f1f.cjs.js +1157 -0
  76. package/pieDiagram-fd367f1f.esm.js +1155 -0
  77. package/quadrantDiagram-1763608a.cjs.js +2633 -0
  78. package/quadrantDiagram-1763608a.esm.js +2631 -0
  79. package/requirementDiagram-779d93b3.cjs.js +2451 -0
  80. package/requirementDiagram-779d93b3.esm.js +2449 -0
  81. package/sankeyDiagram-86a66bae.cjs.js +1850 -0
  82. package/sankeyDiagram-86a66bae.esm.js +1848 -0
  83. package/sequenceDiagram-169f11ec.cjs.js +4805 -0
  84. package/sequenceDiagram-169f11ec.esm.js +4803 -0
  85. package/stateDiagram-6f4bb19d.cjs.js +282 -0
  86. package/stateDiagram-6f4bb19d.esm.js +280 -0
  87. package/stateDiagram-v2-d72c79bd.cjs.js +377 -0
  88. package/stateDiagram-v2-d72c79bd.esm.js +375 -0
  89. package/styles-3814544c.cjs.js +534 -0
  90. package/styles-3814544c.esm.js +524 -0
  91. package/styles-3fb7b9cf.cjs.js +2377 -0
  92. package/styles-3fb7b9cf.esm.js +2368 -0
  93. package/styles-659d7242.cjs.js +3919 -0
  94. package/styles-659d7242.esm.js +3915 -0
  95. package/svgDraw-af99a425.cjs.js +144 -0
  96. package/svgDraw-af99a425.esm.js +141 -0
  97. package/svgDrawCommon-ebe6c236.cjs.js +70 -0
  98. package/svgDrawCommon-ebe6c236.esm.js +62 -0
  99. package/timeline-definition-65183566.cjs.js +1394 -0
  100. package/timeline-definition-65183566.esm.js +1392 -0
@@ -0,0 +1,2775 @@
1
+ 'use strict';
2
+
3
+ var index = require('./index.cjs2.js');
4
+
5
+ function _array_like_to_array(arr, len) {
6
+ if (len == null || len > arr.length) len = arr.length;
7
+ for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
8
+ return arr2;
9
+ }
10
+ function _array_with_holes(arr) {
11
+ if (Array.isArray(arr)) return arr;
12
+ }
13
+ function _array_without_holes(arr) {
14
+ if (Array.isArray(arr)) return _array_like_to_array(arr);
15
+ }
16
+ function _define_property(obj, key, value) {
17
+ if (key in obj) {
18
+ Object.defineProperty(obj, key, {
19
+ value: value,
20
+ enumerable: true,
21
+ configurable: true,
22
+ writable: true
23
+ });
24
+ } else {
25
+ obj[key] = value;
26
+ }
27
+ return obj;
28
+ }
29
+ function _iterable_to_array(iter) {
30
+ if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
31
+ }
32
+ function _iterable_to_array_limit(arr, i) {
33
+ var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
34
+ if (_i == null) return;
35
+ var _arr = [];
36
+ var _n = true;
37
+ var _d = false;
38
+ var _s, _e;
39
+ try {
40
+ for(_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true){
41
+ _arr.push(_s.value);
42
+ if (i && _arr.length === i) break;
43
+ }
44
+ } catch (err) {
45
+ _d = true;
46
+ _e = err;
47
+ } finally{
48
+ try {
49
+ if (!_n && _i["return"] != null) _i["return"]();
50
+ } finally{
51
+ if (_d) throw _e;
52
+ }
53
+ }
54
+ return _arr;
55
+ }
56
+ function _non_iterable_rest() {
57
+ throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
58
+ }
59
+ function _non_iterable_spread() {
60
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
61
+ }
62
+ function _sliced_to_array(arr, i) {
63
+ return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
64
+ }
65
+ function _to_array(arr) {
66
+ return _array_with_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_rest();
67
+ }
68
+ function _to_consumable_array(arr) {
69
+ return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
70
+ }
71
+ function _unsupported_iterable_to_array(o, minLen) {
72
+ if (!o) return;
73
+ if (typeof o === "string") return _array_like_to_array(o, minLen);
74
+ var n = Object.prototype.toString.call(o).slice(8, -1);
75
+ if (n === "Object" && o.constructor) n = o.constructor.name;
76
+ if (n === "Map" || n === "Set") return Array.from(n);
77
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
78
+ }
79
+ function Tt(n, r) {
80
+ var _ref = r || {}, tmp = _ref.includeImageAlt, t = tmp === void 0 ? !0 : tmp;
81
+ return nt(n, t);
82
+ }
83
+ function nt(n, r) {
84
+ return n && typeof n == "object" && // @ts-ignore looks like a literal.
85
+ (n.value || // @ts-ignore looks like an image.
86
+ (r ? n.alt : "") || // @ts-ignore looks like a parent.
87
+ "children" in n && Hn(n.children, r) || Array.isArray(n) && Hn(n, r)) || "";
88
+ }
89
+ function Hn(n, r) {
90
+ for(var t = [], e = -1; ++e < n.length;)t[e] = nt(n[e], r);
91
+ return t.join("");
92
+ }
93
+ function en(n, r, t, e) {
94
+ var u = n.length;
95
+ var l = 0, i;
96
+ if (r < 0 ? r = -r > u ? 0 : u + r : r = r > u ? u : r, t = t > 0 ? t : 0, e.length < 1e4) i = Array.from(e), i.unshift(r, t), [].splice.apply(n, i);
97
+ else for(t && [].splice.apply(n, [
98
+ r,
99
+ t
100
+ ]); l < e.length;)i = e.slice(l, l + 1e4), i.unshift(r, 0), [].splice.apply(n, i), l += 1e4, r += 1e4;
101
+ }
102
+ function Z(n, r) {
103
+ return n.length > 0 ? (en(n, n.length, 0, r), n) : r;
104
+ }
105
+ var Nn = {}.hasOwnProperty;
106
+ function Bt(n) {
107
+ var r = {};
108
+ var t = -1;
109
+ for(; ++t < n.length;)Lt(r, n[t]);
110
+ return r;
111
+ }
112
+ function Lt(n, r) {
113
+ var t;
114
+ for(t in r){
115
+ var u = (Nn.call(n, t) ? n[t] : void 0) || (n[t] = {}), l = r[t];
116
+ var i = void 0;
117
+ for(i in l){
118
+ Nn.call(u, i) || (u[i] = []);
119
+ var a = l[i];
120
+ Ot(// @ts-expect-error Looks like a list.
121
+ u[i], Array.isArray(a) ? a : a ? [
122
+ a
123
+ ] : []);
124
+ }
125
+ }
126
+ }
127
+ function Ot(n, r) {
128
+ var t = -1;
129
+ var e = [];
130
+ for(; ++t < r.length;)(r[t].add === "after" ? n : e).push(r[t]);
131
+ en(n, 0, 0, e);
132
+ }
133
+ var Dt = /[!-/:-@[-`{-~\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/, tn = sn(/[A-Za-z]/), An = sn(/\d/), Pt = sn(/[\dA-Fa-f]/), v = sn(/[\dA-Za-z]/), _t = sn(/[!-/:-@[-`{-~]/), Vn = sn(/[#-'*+\--9=?A-Z^-~]/);
134
+ function zn(n) {
135
+ return(// Special whitespace codes (which have negative values), C0 and Control
136
+ // character DEL
137
+ n !== null && (n < 32 || n === 127));
138
+ }
139
+ function Y(n) {
140
+ return n !== null && (n < 0 || n === 32);
141
+ }
142
+ function C(n) {
143
+ return n !== null && n < -2;
144
+ }
145
+ function q(n) {
146
+ return n === -2 || n === -1 || n === 32;
147
+ }
148
+ var Mt = sn(/\s/), jt = sn(Dt);
149
+ function sn(n) {
150
+ return r;
151
+ function r(t) {
152
+ return t !== null && n.test(String.fromCharCode(t));
153
+ }
154
+ }
155
+ function T(n, r, t, e) {
156
+ var u = e ? e - 1 : Number.POSITIVE_INFINITY;
157
+ var l = 0;
158
+ return i;
159
+ function i(c) {
160
+ return q(c) ? (n.enter(t), a(c)) : r(c);
161
+ }
162
+ function a(c) {
163
+ return q(c) && l++ < u ? (n.consume(c), a) : (n.exit(t), r(c));
164
+ }
165
+ }
166
+ var Rt = {
167
+ tokenize: qt
168
+ };
169
+ function qt(n) {
170
+ var r = n.attempt(this.parser.constructs.contentInitial, e, u);
171
+ var t;
172
+ return r;
173
+ function e(a) {
174
+ if (a === null) {
175
+ n.consume(a);
176
+ return;
177
+ }
178
+ return n.enter("lineEnding"), n.consume(a), n.exit("lineEnding"), T(n, r, "linePrefix");
179
+ }
180
+ function u(a) {
181
+ return n.enter("paragraph"), l(a);
182
+ }
183
+ function l(a) {
184
+ var c = n.enter("chunkText", {
185
+ contentType: "text",
186
+ previous: t
187
+ });
188
+ return t && (t.next = c), t = c, i(a);
189
+ }
190
+ function i(a) {
191
+ if (a === null) {
192
+ n.exit("chunkText"), n.exit("paragraph"), n.consume(a);
193
+ return;
194
+ }
195
+ return C(a) ? (n.consume(a), n.exit("chunkText"), l) : (n.consume(a), i);
196
+ }
197
+ }
198
+ var Ht = {
199
+ tokenize: Nt
200
+ }, Wn = {
201
+ tokenize: Vt
202
+ };
203
+ function Nt(n) {
204
+ var r = this, t = [];
205
+ var e = 0, u, l, i;
206
+ return a;
207
+ function a(F) {
208
+ if (e < t.length) {
209
+ var L = t[e];
210
+ return r.containerState = L[1], n.attempt(L[0].continuation, c, p)(F);
211
+ }
212
+ return p(F);
213
+ }
214
+ function c(F) {
215
+ if (e++, r.containerState._closeFlow) {
216
+ r.containerState._closeFlow = void 0, u && _();
217
+ var L = r.events.length;
218
+ var O = L, d;
219
+ for(; O--;)if (r.events[O][0] === "exit" && r.events[O][1].type === "chunkFlow") {
220
+ d = r.events[O][1].end;
221
+ break;
222
+ }
223
+ y(e);
224
+ var P = L;
225
+ for(; P < r.events.length;)r.events[P][1].end = Object.assign({}, d), P++;
226
+ return en(r.events, O + 1, 0, r.events.slice(L)), r.events.length = P, p(F);
227
+ }
228
+ return a(F);
229
+ }
230
+ function p(F) {
231
+ if (e === t.length) {
232
+ if (!u) return g(F);
233
+ if (u.currentConstruct && u.currentConstruct.concrete) return k(F);
234
+ r.interrupt = !!(u.currentConstruct && !u._gfmTableDynamicInterruptHack);
235
+ }
236
+ return r.containerState = {}, n.check(Wn, h, x)(F);
237
+ }
238
+ function h(F) {
239
+ return u && _(), y(e), g(F);
240
+ }
241
+ function x(F) {
242
+ return r.parser.lazy[r.now().line] = e !== t.length, i = r.now().offset, k(F);
243
+ }
244
+ function g(F) {
245
+ return r.containerState = {}, n.attempt(Wn, f, k)(F);
246
+ }
247
+ function f(F) {
248
+ return e++, t.push([
249
+ r.currentConstruct,
250
+ r.containerState
251
+ ]), g(F);
252
+ }
253
+ function k(F) {
254
+ if (F === null) {
255
+ u && _(), y(0), n.consume(F);
256
+ return;
257
+ }
258
+ return u = u || r.parser.flow(r.now()), n.enter("chunkFlow", {
259
+ contentType: "flow",
260
+ previous: l,
261
+ _tokenizer: u
262
+ }), B(F);
263
+ }
264
+ function B(F) {
265
+ if (F === null) {
266
+ D(n.exit("chunkFlow"), !0), y(0), n.consume(F);
267
+ return;
268
+ }
269
+ return C(F) ? (n.consume(F), D(n.exit("chunkFlow")), e = 0, r.interrupt = void 0, a) : (n.consume(F), B);
270
+ }
271
+ function D(F, L) {
272
+ var O = r.sliceStream(F);
273
+ if (L && O.push(null), F.previous = l, l && (l.next = F), l = F, u.defineSkip(F.start), u.write(O), r.parser.lazy[F.start.line]) {
274
+ var d = u.events.length;
275
+ for(; d--;)if (// The token starts before the line ending…
276
+ u.events[d][1].start.offset < i && // …and either is not ended yet…
277
+ (!u.events[d][1].end || // …or ends after it.
278
+ u.events[d][1].end.offset > i)) return;
279
+ var P = r.events.length;
280
+ var j = P, R, V;
281
+ for(; j--;)if (r.events[j][0] === "exit" && r.events[j][1].type === "chunkFlow") {
282
+ if (R) {
283
+ V = r.events[j][1].end;
284
+ break;
285
+ }
286
+ R = !0;
287
+ }
288
+ for(y(e), d = P; d < r.events.length;)r.events[d][1].end = Object.assign({}, V), d++;
289
+ en(r.events, j + 1, 0, r.events.slice(P)), r.events.length = d;
290
+ }
291
+ }
292
+ function y(F) {
293
+ var L = t.length;
294
+ for(; L-- > F;){
295
+ var O = t[L];
296
+ r.containerState = O[1], O[0].exit.call(r, n);
297
+ }
298
+ t.length = F;
299
+ }
300
+ function _() {
301
+ u.write([
302
+ null
303
+ ]), l = void 0, u = void 0, r.containerState._closeFlow = void 0;
304
+ }
305
+ }
306
+ function Vt(n, r, t) {
307
+ return T(n, n.attempt(this.parser.constructs.document, r, t), "linePrefix", this.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
308
+ }
309
+ function Qn(n) {
310
+ if (n === null || Y(n) || Mt(n)) return 1;
311
+ if (jt(n)) return 2;
312
+ }
313
+ function Ln(n, r, t) {
314
+ var e = [];
315
+ var u = -1;
316
+ for(; ++u < n.length;){
317
+ var l = n[u].resolveAll;
318
+ l && !e.includes(l) && (r = l(r, t), e.push(l));
319
+ }
320
+ return r;
321
+ }
322
+ var In = {
323
+ name: "attention",
324
+ tokenize: Qt,
325
+ resolveAll: Wt
326
+ };
327
+ function Wt(n, r) {
328
+ var t = -1, e, u, l, i, a, c, p, h;
329
+ for(; ++t < n.length;)if (n[t][0] === "enter" && n[t][1].type === "attentionSequence" && n[t][1]._close) {
330
+ for(e = t; e--;)if (n[e][0] === "exit" && n[e][1].type === "attentionSequence" && n[e][1]._open && // If the markers are the same:
331
+ r.sliceSerialize(n[e][1]).charCodeAt(0) === r.sliceSerialize(n[t][1]).charCodeAt(0)) {
332
+ if ((n[e][1]._close || n[t][1]._open) && (n[t][1].end.offset - n[t][1].start.offset) % 3 && !((n[e][1].end.offset - n[e][1].start.offset + n[t][1].end.offset - n[t][1].start.offset) % 3)) continue;
333
+ c = n[e][1].end.offset - n[e][1].start.offset > 1 && n[t][1].end.offset - n[t][1].start.offset > 1 ? 2 : 1;
334
+ var x = Object.assign({}, n[e][1].end), g = Object.assign({}, n[t][1].start);
335
+ Un(x, -c), Un(g, c), i = {
336
+ type: c > 1 ? "strongSequence" : "emphasisSequence",
337
+ start: x,
338
+ end: Object.assign({}, n[e][1].end)
339
+ }, a = {
340
+ type: c > 1 ? "strongSequence" : "emphasisSequence",
341
+ start: Object.assign({}, n[t][1].start),
342
+ end: g
343
+ }, l = {
344
+ type: c > 1 ? "strongText" : "emphasisText",
345
+ start: Object.assign({}, n[e][1].end),
346
+ end: Object.assign({}, n[t][1].start)
347
+ }, u = {
348
+ type: c > 1 ? "strong" : "emphasis",
349
+ start: Object.assign({}, i.start),
350
+ end: Object.assign({}, a.end)
351
+ }, n[e][1].end = Object.assign({}, i.start), n[t][1].start = Object.assign({}, a.end), p = [], n[e][1].end.offset - n[e][1].start.offset && (p = Z(p, [
352
+ [
353
+ "enter",
354
+ n[e][1],
355
+ r
356
+ ],
357
+ [
358
+ "exit",
359
+ n[e][1],
360
+ r
361
+ ]
362
+ ])), p = Z(p, [
363
+ [
364
+ "enter",
365
+ u,
366
+ r
367
+ ],
368
+ [
369
+ "enter",
370
+ i,
371
+ r
372
+ ],
373
+ [
374
+ "exit",
375
+ i,
376
+ r
377
+ ],
378
+ [
379
+ "enter",
380
+ l,
381
+ r
382
+ ]
383
+ ]), p = Z(p, Ln(r.parser.constructs.insideSpan.null, n.slice(e + 1, t), r)), p = Z(p, [
384
+ [
385
+ "exit",
386
+ l,
387
+ r
388
+ ],
389
+ [
390
+ "enter",
391
+ a,
392
+ r
393
+ ],
394
+ [
395
+ "exit",
396
+ a,
397
+ r
398
+ ],
399
+ [
400
+ "exit",
401
+ u,
402
+ r
403
+ ]
404
+ ]), n[t][1].end.offset - n[t][1].start.offset ? (h = 2, p = Z(p, [
405
+ [
406
+ "enter",
407
+ n[t][1],
408
+ r
409
+ ],
410
+ [
411
+ "exit",
412
+ n[t][1],
413
+ r
414
+ ]
415
+ ])) : h = 0, en(n, e - 1, t - e + 3, p), t = e + p.length - h - 2;
416
+ break;
417
+ }
418
+ }
419
+ for(t = -1; ++t < n.length;)n[t][1].type === "attentionSequence" && (n[t][1].type = "data");
420
+ return n;
421
+ }
422
+ function Qt(n, r) {
423
+ var t = this.parser.constructs.attentionMarkers.null, e = this.previous, u = Qn(e);
424
+ var l;
425
+ return i;
426
+ function i(c) {
427
+ return n.enter("attentionSequence"), l = c, a(c);
428
+ }
429
+ function a(c) {
430
+ if (c === l) return n.consume(c), a;
431
+ var p = n.exit("attentionSequence"), h = Qn(c), x = !h || h === 2 && u || t.includes(c), g = !u || u === 2 && h || t.includes(e);
432
+ return p._open = !!(l === 42 ? x : x && (u || !g)), p._close = !!(l === 42 ? g : g && (h || !x)), r(c);
433
+ }
434
+ }
435
+ function Un(n, r) {
436
+ n.column += r, n.offset += r, n._bufferIndex += r;
437
+ }
438
+ var Ut = {
439
+ name: "autolink",
440
+ tokenize: $t
441
+ };
442
+ function $t(n, r, t) {
443
+ var e = 1;
444
+ return u;
445
+ function u(k) {
446
+ return n.enter("autolink"), n.enter("autolinkMarker"), n.consume(k), n.exit("autolinkMarker"), n.enter("autolinkProtocol"), l;
447
+ }
448
+ function l(k) {
449
+ return tn(k) ? (n.consume(k), i) : Vn(k) ? p(k) : t(k);
450
+ }
451
+ function i(k) {
452
+ return k === 43 || k === 45 || k === 46 || v(k) ? a(k) : p(k);
453
+ }
454
+ function a(k) {
455
+ return k === 58 ? (n.consume(k), c) : (k === 43 || k === 45 || k === 46 || v(k)) && e++ < 32 ? (n.consume(k), a) : p(k);
456
+ }
457
+ function c(k) {
458
+ return k === 62 ? (n.exit("autolinkProtocol"), f(k)) : k === null || k === 32 || k === 60 || zn(k) ? t(k) : (n.consume(k), c);
459
+ }
460
+ function p(k) {
461
+ return k === 64 ? (n.consume(k), e = 0, h) : Vn(k) ? (n.consume(k), p) : t(k);
462
+ }
463
+ function h(k) {
464
+ return v(k) ? x(k) : t(k);
465
+ }
466
+ function x(k) {
467
+ return k === 46 ? (n.consume(k), e = 0, h) : k === 62 ? (n.exit("autolinkProtocol").type = "autolinkEmail", f(k)) : g(k);
468
+ }
469
+ function g(k) {
470
+ return (k === 45 || v(k)) && e++ < 63 ? (n.consume(k), k === 45 ? g : x) : t(k);
471
+ }
472
+ function f(k) {
473
+ return n.enter("autolinkMarker"), n.consume(k), n.exit("autolinkMarker"), n.exit("autolink"), r;
474
+ }
475
+ }
476
+ var Sn = {
477
+ tokenize: Zt,
478
+ partial: !0
479
+ };
480
+ function Zt(n, r, t) {
481
+ return T(n, e, "linePrefix");
482
+ function e(u) {
483
+ return u === null || C(u) ? r(u) : t(u);
484
+ }
485
+ }
486
+ var tt = {
487
+ name: "blockQuote",
488
+ tokenize: Yt,
489
+ continuation: {
490
+ tokenize: Gt
491
+ },
492
+ exit: Jt
493
+ };
494
+ function Yt(n, r, t) {
495
+ var e = this;
496
+ return u;
497
+ function u(i) {
498
+ if (i === 62) {
499
+ var a = e.containerState;
500
+ return a.open || (n.enter("blockQuote", {
501
+ _container: !0
502
+ }), a.open = !0), n.enter("blockQuotePrefix"), n.enter("blockQuoteMarker"), n.consume(i), n.exit("blockQuoteMarker"), l;
503
+ }
504
+ return t(i);
505
+ }
506
+ function l(i) {
507
+ return q(i) ? (n.enter("blockQuotePrefixWhitespace"), n.consume(i), n.exit("blockQuotePrefixWhitespace"), n.exit("blockQuotePrefix"), r) : (n.exit("blockQuotePrefix"), r(i));
508
+ }
509
+ }
510
+ function Gt(n, r, t) {
511
+ return T(n, n.attempt(tt, r, t), "linePrefix", this.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
512
+ }
513
+ function Jt(n) {
514
+ n.exit("blockQuote");
515
+ }
516
+ var et = {
517
+ name: "characterEscape",
518
+ tokenize: Kt
519
+ };
520
+ function Kt(n, r, t) {
521
+ return e;
522
+ function e(l) {
523
+ return n.enter("characterEscape"), n.enter("escapeMarker"), n.consume(l), n.exit("escapeMarker"), u;
524
+ }
525
+ function u(l) {
526
+ return _t(l) ? (n.enter("characterEscapeValue"), n.consume(l), n.exit("characterEscapeValue"), n.exit("characterEscape"), r) : t(l);
527
+ }
528
+ }
529
+ var $n = document.createElement("i");
530
+ function On(n) {
531
+ var r = "&" + n + ";";
532
+ $n.innerHTML = r;
533
+ var t = $n.textContent;
534
+ return t.charCodeAt(t.length - 1) === 59 && n !== "semi" || t === r ? !1 : t;
535
+ }
536
+ var rt = {
537
+ name: "characterReference",
538
+ tokenize: Xt
539
+ };
540
+ function Xt(n, r, t) {
541
+ var e = this;
542
+ var u = 0, l, i;
543
+ return a;
544
+ function a(x) {
545
+ return n.enter("characterReference"), n.enter("characterReferenceMarker"), n.consume(x), n.exit("characterReferenceMarker"), c;
546
+ }
547
+ function c(x) {
548
+ return x === 35 ? (n.enter("characterReferenceMarkerNumeric"), n.consume(x), n.exit("characterReferenceMarkerNumeric"), p) : (n.enter("characterReferenceValue"), l = 31, i = v, h(x));
549
+ }
550
+ function p(x) {
551
+ return x === 88 || x === 120 ? (n.enter("characterReferenceMarkerHexadecimal"), n.consume(x), n.exit("characterReferenceMarkerHexadecimal"), n.enter("characterReferenceValue"), l = 6, i = Pt, h) : (n.enter("characterReferenceValue"), l = 7, i = An, h(x));
552
+ }
553
+ function h(x) {
554
+ var g;
555
+ return x === 59 && u ? (g = n.exit("characterReferenceValue"), i === v && !On(e.sliceSerialize(g)) ? t(x) : (n.enter("characterReferenceMarker"), n.consume(x), n.exit("characterReferenceMarker"), n.exit("characterReference"), r)) : i(x) && u++ < l ? (n.consume(x), h) : t(x);
556
+ }
557
+ }
558
+ var Zn = {
559
+ name: "codeFenced",
560
+ tokenize: vt,
561
+ concrete: !0
562
+ };
563
+ function vt(n, r, t) {
564
+ var e = this, u = {
565
+ tokenize: O,
566
+ partial: !0
567
+ }, l = {
568
+ tokenize: L,
569
+ partial: !0
570
+ }, i = this.events[this.events.length - 1], a = i && i[1].type === "linePrefix" ? i[2].sliceSerialize(i[1], !0).length : 0;
571
+ var c = 0, p;
572
+ return h;
573
+ function h(d) {
574
+ return n.enter("codeFenced"), n.enter("codeFencedFence"), n.enter("codeFencedFenceSequence"), p = d, x(d);
575
+ }
576
+ function x(d) {
577
+ return d === p ? (n.consume(d), c++, x) : (n.exit("codeFencedFenceSequence"), c < 3 ? t(d) : T(n, g, "whitespace")(d));
578
+ }
579
+ function g(d) {
580
+ return d === null || C(d) ? D(d) : (n.enter("codeFencedFenceInfo"), n.enter("chunkString", {
581
+ contentType: "string"
582
+ }), f(d));
583
+ }
584
+ function f(d) {
585
+ return d === null || Y(d) ? (n.exit("chunkString"), n.exit("codeFencedFenceInfo"), T(n, k, "whitespace")(d)) : d === 96 && d === p ? t(d) : (n.consume(d), f);
586
+ }
587
+ function k(d) {
588
+ return d === null || C(d) ? D(d) : (n.enter("codeFencedFenceMeta"), n.enter("chunkString", {
589
+ contentType: "string"
590
+ }), B(d));
591
+ }
592
+ function B(d) {
593
+ return d === null || C(d) ? (n.exit("chunkString"), n.exit("codeFencedFenceMeta"), D(d)) : d === 96 && d === p ? t(d) : (n.consume(d), B);
594
+ }
595
+ function D(d) {
596
+ return n.exit("codeFencedFence"), e.interrupt ? r(d) : y(d);
597
+ }
598
+ function y(d) {
599
+ return d === null ? F(d) : C(d) ? n.attempt(l, n.attempt(u, F, a ? T(n, y, "linePrefix", a + 1) : y), F)(d) : (n.enter("codeFlowValue"), _(d));
600
+ }
601
+ function _(d) {
602
+ return d === null || C(d) ? (n.exit("codeFlowValue"), y(d)) : (n.consume(d), _);
603
+ }
604
+ function F(d) {
605
+ return n.exit("codeFenced"), r(d);
606
+ }
607
+ function L(d, P, j) {
608
+ var R = this;
609
+ return V;
610
+ function V(E) {
611
+ return d.enter("lineEnding"), d.consume(E), d.exit("lineEnding"), S;
612
+ }
613
+ function S(E) {
614
+ return R.parser.lazy[R.now().line] ? j(E) : P(E);
615
+ }
616
+ }
617
+ function O(d, P, j) {
618
+ var R = 0;
619
+ return T(d, V, "linePrefix", this.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
620
+ function V(A) {
621
+ return d.enter("codeFencedFence"), d.enter("codeFencedFenceSequence"), S(A);
622
+ }
623
+ function S(A) {
624
+ return A === p ? (d.consume(A), R++, S) : R < c ? j(A) : (d.exit("codeFencedFenceSequence"), T(d, E, "whitespace")(A));
625
+ }
626
+ function E(A) {
627
+ return A === null || C(A) ? (d.exit("codeFencedFence"), P(A)) : j(A);
628
+ }
629
+ }
630
+ }
631
+ var wn = {
632
+ name: "codeIndented",
633
+ tokenize: te
634
+ }, ne = {
635
+ tokenize: ee,
636
+ partial: !0
637
+ };
638
+ function te(n, r, t) {
639
+ var e = this;
640
+ return u;
641
+ function u(p) {
642
+ return n.enter("codeIndented"), T(n, l, "linePrefix", 4 + 1)(p);
643
+ }
644
+ function l(p) {
645
+ var h = e.events[e.events.length - 1];
646
+ return h && h[1].type === "linePrefix" && h[2].sliceSerialize(h[1], !0).length >= 4 ? i(p) : t(p);
647
+ }
648
+ function i(p) {
649
+ return p === null ? c(p) : C(p) ? n.attempt(ne, i, c)(p) : (n.enter("codeFlowValue"), a(p));
650
+ }
651
+ function a(p) {
652
+ return p === null || C(p) ? (n.exit("codeFlowValue"), i(p)) : (n.consume(p), a);
653
+ }
654
+ function c(p) {
655
+ return n.exit("codeIndented"), r(p);
656
+ }
657
+ }
658
+ function ee(n, r, t) {
659
+ var e = this;
660
+ return u;
661
+ function u(i) {
662
+ return e.parser.lazy[e.now().line] ? t(i) : C(i) ? (n.enter("lineEnding"), n.consume(i), n.exit("lineEnding"), u) : T(n, l, "linePrefix", 4 + 1)(i);
663
+ }
664
+ function l(i) {
665
+ var a = e.events[e.events.length - 1];
666
+ return a && a[1].type === "linePrefix" && a[2].sliceSerialize(a[1], !0).length >= 4 ? r(i) : C(i) ? u(i) : t(i);
667
+ }
668
+ }
669
+ var re = {
670
+ name: "codeText",
671
+ tokenize: le,
672
+ resolve: ie,
673
+ previous: ue
674
+ };
675
+ function ie(n) {
676
+ var r = n.length - 4, t = 3, e, u;
677
+ if ((n[t][1].type === "lineEnding" || n[t][1].type === "space") && (n[r][1].type === "lineEnding" || n[r][1].type === "space")) {
678
+ for(e = t; ++e < r;)if (n[e][1].type === "codeTextData") {
679
+ n[t][1].type = "codeTextPadding", n[r][1].type = "codeTextPadding", t += 2, r -= 2;
680
+ break;
681
+ }
682
+ }
683
+ for(e = t - 1, r++; ++e <= r;)u === void 0 ? e !== r && n[e][1].type !== "lineEnding" && (u = e) : (e === r || n[e][1].type === "lineEnding") && (n[u][1].type = "codeTextData", e !== u + 2 && (n[u][1].end = n[e - 1][1].end, n.splice(u + 2, e - u - 2), r -= e - u - 2, e = u + 2), u = void 0);
684
+ return n;
685
+ }
686
+ function ue(n) {
687
+ return n !== 96 || this.events[this.events.length - 1][1].type === "characterEscape";
688
+ }
689
+ function le(n, r, t) {
690
+ var e = 0, u, l;
691
+ return i;
692
+ function i(x) {
693
+ return n.enter("codeText"), n.enter("codeTextSequence"), a(x);
694
+ }
695
+ function a(x) {
696
+ return x === 96 ? (n.consume(x), e++, a) : (n.exit("codeTextSequence"), c(x));
697
+ }
698
+ function c(x) {
699
+ return x === null ? t(x) : x === 96 ? (l = n.enter("codeTextSequence"), u = 0, h(x)) : x === 32 ? (n.enter("space"), n.consume(x), n.exit("space"), c) : C(x) ? (n.enter("lineEnding"), n.consume(x), n.exit("lineEnding"), c) : (n.enter("codeTextData"), p(x));
700
+ }
701
+ function p(x) {
702
+ return x === null || x === 32 || x === 96 || C(x) ? (n.exit("codeTextData"), c(x)) : (n.consume(x), p);
703
+ }
704
+ function h(x) {
705
+ return x === 96 ? (n.consume(x), u++, h) : u === e ? (n.exit("codeTextSequence"), n.exit("codeText"), r(x)) : (l.type = "codeTextData", p(x));
706
+ }
707
+ }
708
+ function it(n) {
709
+ var r = {};
710
+ var t = -1, e, u, l, i, a, c, p;
711
+ for(; ++t < n.length;){
712
+ for(; (t in r);)t = r[t];
713
+ if (e = n[t], t && e[1].type === "chunkFlow" && n[t - 1][1].type === "listItemPrefix" && (c = e[1]._tokenizer.events, l = 0, l < c.length && c[l][1].type === "lineEndingBlank" && (l += 2), l < c.length && c[l][1].type === "content")) for(; ++l < c.length && c[l][1].type !== "content";)c[l][1].type === "chunkText" && (c[l][1]._isInFirstContentOfListItem = !0, l++);
714
+ if (e[0] === "enter") e[1].contentType && (Object.assign(r, ae(n, t)), t = r[t], p = !0);
715
+ else if (e[1]._container) {
716
+ for(l = t, u = void 0; l-- && (i = n[l], i[1].type === "lineEnding" || i[1].type === "lineEndingBlank");)i[0] === "enter" && (u && (n[u][1].type = "lineEndingBlank"), i[1].type = "lineEnding", u = l);
717
+ u && (e[1].end = Object.assign({}, n[u][1].start), a = n.slice(u, t), a.unshift(e), en(n, u, t - u + 1, a));
718
+ }
719
+ }
720
+ return !p;
721
+ }
722
+ function ae(n, r) {
723
+ var t = n[r][1], e = n[r][2];
724
+ var u = r - 1;
725
+ var l = [], i = t._tokenizer || e.parser[t.contentType](t.start), a = i.events, c = [], p = {};
726
+ var h, x, g = -1, f = t, k = 0, B = 0;
727
+ var D = [
728
+ B
729
+ ];
730
+ for(; f;){
731
+ for(; n[++u][1] !== f;);
732
+ l.push(u), f._tokenizer || (h = e.sliceStream(f), f.next || h.push(null), x && i.defineSkip(f.start), f._isInFirstContentOfListItem && (i._gfmTasklistFirstContentOfListItem = !0), i.write(h), f._isInFirstContentOfListItem && (i._gfmTasklistFirstContentOfListItem = void 0)), x = f, f = f.next;
733
+ }
734
+ for(f = t; ++g < a.length;)// Find a void token that includes a break.
735
+ a[g][0] === "exit" && a[g - 1][0] === "enter" && a[g][1].type === a[g - 1][1].type && a[g][1].start.line !== a[g][1].end.line && (B = g + 1, D.push(B), f._tokenizer = void 0, f.previous = void 0, f = f.next);
736
+ for(i.events = [], f ? (f._tokenizer = void 0, f.previous = void 0) : D.pop(), g = D.length; g--;){
737
+ var y = a.slice(D[g], D[g + 1]), _ = l.pop();
738
+ c.unshift([
739
+ _,
740
+ _ + y.length - 1
741
+ ]), en(n, _, 2, y);
742
+ }
743
+ for(g = -1; ++g < c.length;)p[k + c[g][0]] = k + c[g][1], k += c[g][1] - c[g][0] - 1;
744
+ return p;
745
+ }
746
+ var oe = {
747
+ tokenize: he,
748
+ resolve: ce
749
+ }, se = {
750
+ tokenize: pe,
751
+ partial: !0
752
+ };
753
+ function ce(n) {
754
+ return it(n), n;
755
+ }
756
+ function he(n, r) {
757
+ var t;
758
+ return e;
759
+ function e(a) {
760
+ return n.enter("content"), t = n.enter("chunkContent", {
761
+ contentType: "content"
762
+ }), u(a);
763
+ }
764
+ function u(a) {
765
+ return a === null ? l(a) : C(a) ? n.check(se, i, l)(a) : (n.consume(a), u);
766
+ }
767
+ function l(a) {
768
+ return n.exit("chunkContent"), n.exit("content"), r(a);
769
+ }
770
+ function i(a) {
771
+ return n.consume(a), n.exit("chunkContent"), t.next = n.enter("chunkContent", {
772
+ contentType: "content",
773
+ previous: t
774
+ }), t = t.next, u;
775
+ }
776
+ }
777
+ function pe(n, r, t) {
778
+ var e = this;
779
+ return u;
780
+ function u(i) {
781
+ return n.exit("chunkContent"), n.enter("lineEnding"), n.consume(i), n.exit("lineEnding"), T(n, l, "linePrefix");
782
+ }
783
+ function l(i) {
784
+ if (i === null || C(i)) return t(i);
785
+ var a = e.events[e.events.length - 1];
786
+ return !e.parser.constructs.disable.null.includes("codeIndented") && a && a[1].type === "linePrefix" && a[2].sliceSerialize(a[1], !0).length >= 4 ? r(i) : n.interrupt(e.parser.constructs.flow, t, r)(i);
787
+ }
788
+ }
789
+ function ut(n, r, t, e, u, l, i, a, c) {
790
+ var p = c || Number.POSITIVE_INFINITY;
791
+ var h = 0;
792
+ return x;
793
+ function x(y) {
794
+ return y === 60 ? (n.enter(e), n.enter(u), n.enter(l), n.consume(y), n.exit(l), g) : y === null || y === 41 || zn(y) ? t(y) : (n.enter(e), n.enter(i), n.enter(a), n.enter("chunkString", {
795
+ contentType: "string"
796
+ }), B(y));
797
+ }
798
+ function g(y) {
799
+ return y === 62 ? (n.enter(l), n.consume(y), n.exit(l), n.exit(u), n.exit(e), r) : (n.enter(a), n.enter("chunkString", {
800
+ contentType: "string"
801
+ }), f(y));
802
+ }
803
+ function f(y) {
804
+ return y === 62 ? (n.exit("chunkString"), n.exit(a), g(y)) : y === null || y === 60 || C(y) ? t(y) : (n.consume(y), y === 92 ? k : f);
805
+ }
806
+ function k(y) {
807
+ return y === 60 || y === 62 || y === 92 ? (n.consume(y), f) : f(y);
808
+ }
809
+ function B(y) {
810
+ return y === 40 ? ++h > p ? t(y) : (n.consume(y), B) : y === 41 ? h-- ? (n.consume(y), B) : (n.exit("chunkString"), n.exit(a), n.exit(i), n.exit(e), r(y)) : y === null || Y(y) ? h ? t(y) : (n.exit("chunkString"), n.exit(a), n.exit(i), n.exit(e), r(y)) : zn(y) ? t(y) : (n.consume(y), y === 92 ? D : B);
811
+ }
812
+ function D(y) {
813
+ return y === 40 || y === 41 || y === 92 ? (n.consume(y), B) : B(y);
814
+ }
815
+ }
816
+ function lt(n, r, t, e, u, l) {
817
+ var i = this;
818
+ var a = 0, c;
819
+ return p;
820
+ function p(f) {
821
+ return n.enter(e), n.enter(u), n.consume(f), n.exit(u), n.enter(l), h;
822
+ }
823
+ function h(f) {
824
+ return f === null || f === 91 || f === 93 && !c || /* To do: remove in the future once we’ve switched from
825
+ * `micromark-extension-footnote` to `micromark-extension-gfm-footnote`,
826
+ * which doesn’t need this */ /* Hidden footnotes hook */ /* c8 ignore next 3 */ f === 94 && !a && "_hiddenFootnoteSupport" in i.parser.constructs || a > 999 ? t(f) : f === 93 ? (n.exit(l), n.enter(u), n.consume(f), n.exit(u), n.exit(e), r) : C(f) ? (n.enter("lineEnding"), n.consume(f), n.exit("lineEnding"), h) : (n.enter("chunkString", {
827
+ contentType: "string"
828
+ }), x(f));
829
+ }
830
+ function x(f) {
831
+ return f === null || f === 91 || f === 93 || C(f) || a++ > 999 ? (n.exit("chunkString"), h(f)) : (n.consume(f), c = c || !q(f), f === 92 ? g : x);
832
+ }
833
+ function g(f) {
834
+ return f === 91 || f === 92 || f === 93 ? (n.consume(f), a++, x) : x(f);
835
+ }
836
+ }
837
+ function at(n, r, t, e, u, l) {
838
+ var i;
839
+ return a;
840
+ function a(g) {
841
+ return n.enter(e), n.enter(u), n.consume(g), n.exit(u), i = g === 40 ? 41 : g, c;
842
+ }
843
+ function c(g) {
844
+ return g === i ? (n.enter(u), n.consume(g), n.exit(u), n.exit(e), r) : (n.enter(l), p(g));
845
+ }
846
+ function p(g) {
847
+ return g === i ? (n.exit(l), c(i)) : g === null ? t(g) : C(g) ? (n.enter("lineEnding"), n.consume(g), n.exit("lineEnding"), T(n, p, "linePrefix")) : (n.enter("chunkString", {
848
+ contentType: "string"
849
+ }), h(g));
850
+ }
851
+ function h(g) {
852
+ return g === i || g === null || C(g) ? (n.exit("chunkString"), p(g)) : (n.consume(g), g === 92 ? x : h);
853
+ }
854
+ function x(g) {
855
+ return g === i || g === 92 ? (n.consume(g), h) : h(g);
856
+ }
857
+ }
858
+ function dn(n, r) {
859
+ var t;
860
+ return e;
861
+ function e(u) {
862
+ return C(u) ? (n.enter("lineEnding"), n.consume(u), n.exit("lineEnding"), t = !0, e) : q(u) ? T(n, e, t ? "linePrefix" : "lineSuffix")(u) : r(u);
863
+ }
864
+ }
865
+ function fn(n) {
866
+ return n.replace(/[\t\n\r ]+/g, " ").replace(/^ | $/g, "").toLowerCase().toUpperCase();
867
+ }
868
+ var me = {
869
+ name: "definition",
870
+ tokenize: xe
871
+ }, fe = {
872
+ tokenize: ge,
873
+ partial: !0
874
+ };
875
+ function xe(n, r, t) {
876
+ var e = this;
877
+ var u;
878
+ return l;
879
+ function l(c) {
880
+ return n.enter("definition"), lt.call(e, n, i, t, "definitionLabel", "definitionLabelMarker", "definitionLabelString")(c);
881
+ }
882
+ function i(c) {
883
+ return u = fn(e.sliceSerialize(e.events[e.events.length - 1][1]).slice(1, -1)), c === 58 ? (n.enter("definitionMarker"), n.consume(c), n.exit("definitionMarker"), dn(n, ut(n, n.attempt(fe, T(n, a, "whitespace"), T(n, a, "whitespace")), t, "definitionDestination", "definitionDestinationLiteral", "definitionDestinationLiteralMarker", "definitionDestinationRaw", "definitionDestinationString"))) : t(c);
884
+ }
885
+ function a(c) {
886
+ return c === null || C(c) ? (n.exit("definition"), e.parser.defined.includes(u) || e.parser.defined.push(u), r(c)) : t(c);
887
+ }
888
+ }
889
+ function ge(n, r, t) {
890
+ return e;
891
+ function e(i) {
892
+ return Y(i) ? dn(n, u)(i) : t(i);
893
+ }
894
+ function u(i) {
895
+ return i === 34 || i === 39 || i === 40 ? at(n, T(n, l, "whitespace"), t, "definitionTitle", "definitionTitleMarker", "definitionTitleString")(i) : t(i);
896
+ }
897
+ function l(i) {
898
+ return i === null || C(i) ? r(i) : t(i);
899
+ }
900
+ }
901
+ var ke = {
902
+ name: "hardBreakEscape",
903
+ tokenize: de
904
+ };
905
+ function de(n, r, t) {
906
+ return e;
907
+ function e(l) {
908
+ return n.enter("hardBreakEscape"), n.enter("escapeMarker"), n.consume(l), u;
909
+ }
910
+ function u(l) {
911
+ return C(l) ? (n.exit("escapeMarker"), n.exit("hardBreakEscape"), r(l)) : t(l);
912
+ }
913
+ }
914
+ var be = {
915
+ name: "headingAtx",
916
+ tokenize: Se,
917
+ resolve: ye
918
+ };
919
+ function ye(n, r) {
920
+ var t = n.length - 2, e = 3, u, l;
921
+ return n[e][1].type === "whitespace" && (e += 2), t - 2 > e && n[t][1].type === "whitespace" && (t -= 2), n[t][1].type === "atxHeadingSequence" && (e === t - 1 || t - 4 > e && n[t - 2][1].type === "whitespace") && (t -= e + 1 === t ? 2 : 4), t > e && (u = {
922
+ type: "atxHeadingText",
923
+ start: n[e][1].start,
924
+ end: n[t][1].end
925
+ }, l = {
926
+ type: "chunkText",
927
+ start: n[e][1].start,
928
+ end: n[t][1].end,
929
+ // @ts-expect-error Constants are fine to assign.
930
+ contentType: "text"
931
+ }, en(n, e, t - e + 1, [
932
+ [
933
+ "enter",
934
+ u,
935
+ r
936
+ ],
937
+ [
938
+ "enter",
939
+ l,
940
+ r
941
+ ],
942
+ [
943
+ "exit",
944
+ l,
945
+ r
946
+ ],
947
+ [
948
+ "exit",
949
+ u,
950
+ r
951
+ ]
952
+ ])), n;
953
+ }
954
+ function Se(n, r, t) {
955
+ var e = this;
956
+ var u = 0;
957
+ return l;
958
+ function l(h) {
959
+ return n.enter("atxHeading"), n.enter("atxHeadingSequence"), i(h);
960
+ }
961
+ function i(h) {
962
+ return h === 35 && u++ < 6 ? (n.consume(h), i) : h === null || Y(h) ? (n.exit("atxHeadingSequence"), e.interrupt ? r(h) : a(h)) : t(h);
963
+ }
964
+ function a(h) {
965
+ return h === 35 ? (n.enter("atxHeadingSequence"), c(h)) : h === null || C(h) ? (n.exit("atxHeading"), r(h)) : q(h) ? T(n, a, "whitespace")(h) : (n.enter("atxHeadingText"), p(h));
966
+ }
967
+ function c(h) {
968
+ return h === 35 ? (n.consume(h), c) : (n.exit("atxHeadingSequence"), a(h));
969
+ }
970
+ function p(h) {
971
+ return h === null || h === 35 || Y(h) ? (n.exit("atxHeadingText"), a(h)) : (n.consume(h), p);
972
+ }
973
+ }
974
+ var Fe = [
975
+ "address",
976
+ "article",
977
+ "aside",
978
+ "base",
979
+ "basefont",
980
+ "blockquote",
981
+ "body",
982
+ "caption",
983
+ "center",
984
+ "col",
985
+ "colgroup",
986
+ "dd",
987
+ "details",
988
+ "dialog",
989
+ "dir",
990
+ "div",
991
+ "dl",
992
+ "dt",
993
+ "fieldset",
994
+ "figcaption",
995
+ "figure",
996
+ "footer",
997
+ "form",
998
+ "frame",
999
+ "frameset",
1000
+ "h1",
1001
+ "h2",
1002
+ "h3",
1003
+ "h4",
1004
+ "h5",
1005
+ "h6",
1006
+ "head",
1007
+ "header",
1008
+ "hr",
1009
+ "html",
1010
+ "iframe",
1011
+ "legend",
1012
+ "li",
1013
+ "link",
1014
+ "main",
1015
+ "menu",
1016
+ "menuitem",
1017
+ "nav",
1018
+ "noframes",
1019
+ "ol",
1020
+ "optgroup",
1021
+ "option",
1022
+ "p",
1023
+ "param",
1024
+ "section",
1025
+ "summary",
1026
+ "table",
1027
+ "tbody",
1028
+ "td",
1029
+ "tfoot",
1030
+ "th",
1031
+ "thead",
1032
+ "title",
1033
+ "tr",
1034
+ "track",
1035
+ "ul"
1036
+ ], Yn = [
1037
+ "pre",
1038
+ "script",
1039
+ "style",
1040
+ "textarea"
1041
+ ], Ee = {
1042
+ name: "htmlFlow",
1043
+ tokenize: Ae,
1044
+ resolveTo: Ce,
1045
+ concrete: !0
1046
+ }, we = {
1047
+ tokenize: ze,
1048
+ partial: !0
1049
+ };
1050
+ function Ce(n) {
1051
+ var r = n.length;
1052
+ for(; r-- && !(n[r][0] === "enter" && n[r][1].type === "htmlFlow"););
1053
+ return r > 1 && n[r - 2][1].type === "linePrefix" && (n[r][1].start = n[r - 2][1].start, n[r + 1][1].start = n[r - 2][1].start, n.splice(r - 2, 2)), n;
1054
+ }
1055
+ function Ae(n, r, t) {
1056
+ var e = this;
1057
+ var u, l, i, a, c;
1058
+ return p;
1059
+ function p(o) {
1060
+ return n.enter("htmlFlow"), n.enter("htmlFlowData"), n.consume(o), h;
1061
+ }
1062
+ function h(o) {
1063
+ return o === 33 ? (n.consume(o), x) : o === 47 ? (n.consume(o), k) : o === 63 ? (n.consume(o), u = 3, e.interrupt ? r : U) : tn(o) ? (n.consume(o), i = String.fromCharCode(o), l = !0, B) : t(o);
1064
+ }
1065
+ function x(o) {
1066
+ return o === 45 ? (n.consume(o), u = 2, g) : o === 91 ? (n.consume(o), u = 5, i = "CDATA[", a = 0, f) : tn(o) ? (n.consume(o), u = 4, e.interrupt ? r : U) : t(o);
1067
+ }
1068
+ function g(o) {
1069
+ return o === 45 ? (n.consume(o), e.interrupt ? r : U) : t(o);
1070
+ }
1071
+ function f(o) {
1072
+ return o === i.charCodeAt(a++) ? (n.consume(o), a === i.length ? e.interrupt ? r : S : f) : t(o);
1073
+ }
1074
+ function k(o) {
1075
+ return tn(o) ? (n.consume(o), i = String.fromCharCode(o), B) : t(o);
1076
+ }
1077
+ function B(o) {
1078
+ return o === null || o === 47 || o === 62 || Y(o) ? o !== 47 && l && Yn.includes(i.toLowerCase()) ? (u = 1, e.interrupt ? r(o) : S(o)) : Fe.includes(i.toLowerCase()) ? (u = 6, o === 47 ? (n.consume(o), D) : e.interrupt ? r(o) : S(o)) : (u = 7, e.interrupt && !e.parser.lazy[e.now().line] ? t(o) : l ? _(o) : y(o)) : o === 45 || v(o) ? (n.consume(o), i += String.fromCharCode(o), B) : t(o);
1079
+ }
1080
+ function D(o) {
1081
+ return o === 62 ? (n.consume(o), e.interrupt ? r : S) : t(o);
1082
+ }
1083
+ function y(o) {
1084
+ return q(o) ? (n.consume(o), y) : R(o);
1085
+ }
1086
+ function _(o) {
1087
+ return o === 47 ? (n.consume(o), R) : o === 58 || o === 95 || tn(o) ? (n.consume(o), F) : q(o) ? (n.consume(o), _) : R(o);
1088
+ }
1089
+ function F(o) {
1090
+ return o === 45 || o === 46 || o === 58 || o === 95 || v(o) ? (n.consume(o), F) : L(o);
1091
+ }
1092
+ function L(o) {
1093
+ return o === 61 ? (n.consume(o), O) : q(o) ? (n.consume(o), L) : _(o);
1094
+ }
1095
+ function O(o) {
1096
+ return o === null || o === 60 || o === 61 || o === 62 || o === 96 ? t(o) : o === 34 || o === 39 ? (n.consume(o), c = o, d) : q(o) ? (n.consume(o), O) : (c = null, P(o));
1097
+ }
1098
+ function d(o) {
1099
+ return o === null || C(o) ? t(o) : o === c ? (n.consume(o), j) : (n.consume(o), d);
1100
+ }
1101
+ function P(o) {
1102
+ return o === null || o === 34 || o === 39 || o === 60 || o === 61 || o === 62 || o === 96 || Y(o) ? L(o) : (n.consume(o), P);
1103
+ }
1104
+ function j(o) {
1105
+ return o === 47 || o === 62 || q(o) ? _(o) : t(o);
1106
+ }
1107
+ function R(o) {
1108
+ return o === 62 ? (n.consume(o), V) : t(o);
1109
+ }
1110
+ function V(o) {
1111
+ return q(o) ? (n.consume(o), V) : o === null || C(o) ? S(o) : t(o);
1112
+ }
1113
+ function S(o) {
1114
+ return o === 45 && u === 2 ? (n.consume(o), G) : o === 60 && u === 1 ? (n.consume(o), nn) : o === 62 && u === 4 ? (n.consume(o), H) : o === 63 && u === 3 ? (n.consume(o), U) : o === 93 && u === 5 ? (n.consume(o), W) : C(o) && (u === 6 || u === 7) ? n.check(we, H, E)(o) : o === null || C(o) ? E(o) : (n.consume(o), S);
1115
+ }
1116
+ function E(o) {
1117
+ return n.exit("htmlFlowData"), A(o);
1118
+ }
1119
+ function A(o) {
1120
+ return o === null ? s(o) : C(o) ? n.attempt({
1121
+ tokenize: Q,
1122
+ partial: !0
1123
+ }, A, s)(o) : (n.enter("htmlFlowData"), S(o));
1124
+ }
1125
+ function Q(o, cn, xn) {
1126
+ return hn;
1127
+ function hn(K) {
1128
+ return o.enter("lineEnding"), o.consume(K), o.exit("lineEnding"), N;
1129
+ }
1130
+ function N(K) {
1131
+ return e.parser.lazy[e.now().line] ? xn(K) : cn(K);
1132
+ }
1133
+ }
1134
+ function G(o) {
1135
+ return o === 45 ? (n.consume(o), U) : S(o);
1136
+ }
1137
+ function nn(o) {
1138
+ return o === 47 ? (n.consume(o), i = "", J) : S(o);
1139
+ }
1140
+ function J(o) {
1141
+ return o === 62 && Yn.includes(i.toLowerCase()) ? (n.consume(o), H) : tn(o) && i.length < 8 ? (n.consume(o), i += String.fromCharCode(o), J) : S(o);
1142
+ }
1143
+ function W(o) {
1144
+ return o === 93 ? (n.consume(o), U) : S(o);
1145
+ }
1146
+ function U(o) {
1147
+ return o === 62 ? (n.consume(o), H) : o === 45 && u === 2 ? (n.consume(o), U) : S(o);
1148
+ }
1149
+ function H(o) {
1150
+ return o === null || C(o) ? (n.exit("htmlFlowData"), s(o)) : (n.consume(o), H);
1151
+ }
1152
+ function s(o) {
1153
+ return n.exit("htmlFlow"), r(o);
1154
+ }
1155
+ }
1156
+ function ze(n, r, t) {
1157
+ return e;
1158
+ function e(u) {
1159
+ return n.exit("htmlFlowData"), n.enter("lineEndingBlank"), n.consume(u), n.exit("lineEndingBlank"), n.attempt(Sn, r, t);
1160
+ }
1161
+ }
1162
+ var Ie = {
1163
+ name: "htmlText",
1164
+ tokenize: Te
1165
+ };
1166
+ function Te(n, r, t) {
1167
+ var e = this;
1168
+ var u, l, i, a;
1169
+ return c;
1170
+ function c(s) {
1171
+ return n.enter("htmlText"), n.enter("htmlTextData"), n.consume(s), p;
1172
+ }
1173
+ function p(s) {
1174
+ return s === 33 ? (n.consume(s), h) : s === 47 ? (n.consume(s), P) : s === 63 ? (n.consume(s), O) : tn(s) ? (n.consume(s), V) : t(s);
1175
+ }
1176
+ function h(s) {
1177
+ return s === 45 ? (n.consume(s), x) : s === 91 ? (n.consume(s), l = "CDATA[", i = 0, D) : tn(s) ? (n.consume(s), L) : t(s);
1178
+ }
1179
+ function x(s) {
1180
+ return s === 45 ? (n.consume(s), g) : t(s);
1181
+ }
1182
+ function g(s) {
1183
+ return s === null || s === 62 ? t(s) : s === 45 ? (n.consume(s), f) : k(s);
1184
+ }
1185
+ function f(s) {
1186
+ return s === null || s === 62 ? t(s) : k(s);
1187
+ }
1188
+ function k(s) {
1189
+ return s === null ? t(s) : s === 45 ? (n.consume(s), B) : C(s) ? (a = k, W(s)) : (n.consume(s), k);
1190
+ }
1191
+ function B(s) {
1192
+ return s === 45 ? (n.consume(s), H) : k(s);
1193
+ }
1194
+ function D(s) {
1195
+ return s === l.charCodeAt(i++) ? (n.consume(s), i === l.length ? y : D) : t(s);
1196
+ }
1197
+ function y(s) {
1198
+ return s === null ? t(s) : s === 93 ? (n.consume(s), _) : C(s) ? (a = y, W(s)) : (n.consume(s), y);
1199
+ }
1200
+ function _(s) {
1201
+ return s === 93 ? (n.consume(s), F) : y(s);
1202
+ }
1203
+ function F(s) {
1204
+ return s === 62 ? H(s) : s === 93 ? (n.consume(s), F) : y(s);
1205
+ }
1206
+ function L(s) {
1207
+ return s === null || s === 62 ? H(s) : C(s) ? (a = L, W(s)) : (n.consume(s), L);
1208
+ }
1209
+ function O(s) {
1210
+ return s === null ? t(s) : s === 63 ? (n.consume(s), d) : C(s) ? (a = O, W(s)) : (n.consume(s), O);
1211
+ }
1212
+ function d(s) {
1213
+ return s === 62 ? H(s) : O(s);
1214
+ }
1215
+ function P(s) {
1216
+ return tn(s) ? (n.consume(s), j) : t(s);
1217
+ }
1218
+ function j(s) {
1219
+ return s === 45 || v(s) ? (n.consume(s), j) : R(s);
1220
+ }
1221
+ function R(s) {
1222
+ return C(s) ? (a = R, W(s)) : q(s) ? (n.consume(s), R) : H(s);
1223
+ }
1224
+ function V(s) {
1225
+ return s === 45 || v(s) ? (n.consume(s), V) : s === 47 || s === 62 || Y(s) ? S(s) : t(s);
1226
+ }
1227
+ function S(s) {
1228
+ return s === 47 ? (n.consume(s), H) : s === 58 || s === 95 || tn(s) ? (n.consume(s), E) : C(s) ? (a = S, W(s)) : q(s) ? (n.consume(s), S) : H(s);
1229
+ }
1230
+ function E(s) {
1231
+ return s === 45 || s === 46 || s === 58 || s === 95 || v(s) ? (n.consume(s), E) : A(s);
1232
+ }
1233
+ function A(s) {
1234
+ return s === 61 ? (n.consume(s), Q) : C(s) ? (a = A, W(s)) : q(s) ? (n.consume(s), A) : S(s);
1235
+ }
1236
+ function Q(s) {
1237
+ return s === null || s === 60 || s === 61 || s === 62 || s === 96 ? t(s) : s === 34 || s === 39 ? (n.consume(s), u = s, G) : C(s) ? (a = Q, W(s)) : q(s) ? (n.consume(s), Q) : (n.consume(s), u = void 0, J);
1238
+ }
1239
+ function G(s) {
1240
+ return s === u ? (n.consume(s), nn) : s === null ? t(s) : C(s) ? (a = G, W(s)) : (n.consume(s), G);
1241
+ }
1242
+ function nn(s) {
1243
+ return s === 62 || s === 47 || Y(s) ? S(s) : t(s);
1244
+ }
1245
+ function J(s) {
1246
+ return s === null || s === 34 || s === 39 || s === 60 || s === 61 || s === 96 ? t(s) : s === 62 || Y(s) ? S(s) : (n.consume(s), J);
1247
+ }
1248
+ function W(s) {
1249
+ return n.exit("htmlTextData"), n.enter("lineEnding"), n.consume(s), n.exit("lineEnding"), T(n, U, "linePrefix", e.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
1250
+ }
1251
+ function U(s) {
1252
+ return n.enter("htmlTextData"), a(s);
1253
+ }
1254
+ function H(s) {
1255
+ return s === 62 ? (n.consume(s), n.exit("htmlTextData"), n.exit("htmlText"), r) : t(s);
1256
+ }
1257
+ }
1258
+ var Dn = {
1259
+ name: "labelEnd",
1260
+ tokenize: _e,
1261
+ resolveTo: Pe,
1262
+ resolveAll: De
1263
+ }, Be = {
1264
+ tokenize: Me
1265
+ }, Le = {
1266
+ tokenize: je
1267
+ }, Oe = {
1268
+ tokenize: Re
1269
+ };
1270
+ function De(n) {
1271
+ var r = -1, t;
1272
+ for(; ++r < n.length;)t = n[r][1], (t.type === "labelImage" || t.type === "labelLink" || t.type === "labelEnd") && (n.splice(r + 1, t.type === "labelImage" ? 4 : 2), t.type = "data", r++);
1273
+ return n;
1274
+ }
1275
+ function Pe(n, r) {
1276
+ var t = n.length, e = 0, u, l, i, a;
1277
+ for(; t--;)if (u = n[t][1], l) {
1278
+ if (u.type === "link" || u.type === "labelLink" && u._inactive) break;
1279
+ n[t][0] === "enter" && u.type === "labelLink" && (u._inactive = !0);
1280
+ } else if (i) {
1281
+ if (n[t][0] === "enter" && (u.type === "labelImage" || u.type === "labelLink") && !u._balanced && (l = t, u.type !== "labelLink")) {
1282
+ e = 2;
1283
+ break;
1284
+ }
1285
+ } else u.type === "labelEnd" && (i = t);
1286
+ var c = {
1287
+ type: n[l][1].type === "labelLink" ? "link" : "image",
1288
+ start: Object.assign({}, n[l][1].start),
1289
+ end: Object.assign({}, n[n.length - 1][1].end)
1290
+ }, p = {
1291
+ type: "label",
1292
+ start: Object.assign({}, n[l][1].start),
1293
+ end: Object.assign({}, n[i][1].end)
1294
+ }, h = {
1295
+ type: "labelText",
1296
+ start: Object.assign({}, n[l + e + 2][1].end),
1297
+ end: Object.assign({}, n[i - 2][1].start)
1298
+ };
1299
+ return a = [
1300
+ [
1301
+ "enter",
1302
+ c,
1303
+ r
1304
+ ],
1305
+ [
1306
+ "enter",
1307
+ p,
1308
+ r
1309
+ ]
1310
+ ], a = Z(a, n.slice(l + 1, l + e + 3)), a = Z(a, [
1311
+ [
1312
+ "enter",
1313
+ h,
1314
+ r
1315
+ ]
1316
+ ]), a = Z(a, Ln(r.parser.constructs.insideSpan.null, n.slice(l + e + 4, i - 3), r)), a = Z(a, [
1317
+ [
1318
+ "exit",
1319
+ h,
1320
+ r
1321
+ ],
1322
+ n[i - 2],
1323
+ n[i - 1],
1324
+ [
1325
+ "exit",
1326
+ p,
1327
+ r
1328
+ ]
1329
+ ]), a = Z(a, n.slice(i + 1)), a = Z(a, [
1330
+ [
1331
+ "exit",
1332
+ c,
1333
+ r
1334
+ ]
1335
+ ]), en(n, l, n.length, a), n;
1336
+ }
1337
+ function _e(n, r, t) {
1338
+ var e = this;
1339
+ var u = e.events.length, l, i;
1340
+ for(; u--;)if ((e.events[u][1].type === "labelImage" || e.events[u][1].type === "labelLink") && !e.events[u][1]._balanced) {
1341
+ l = e.events[u][1];
1342
+ break;
1343
+ }
1344
+ return a;
1345
+ function a(h) {
1346
+ return l ? l._inactive ? p(h) : (i = e.parser.defined.includes(fn(e.sliceSerialize({
1347
+ start: l.end,
1348
+ end: e.now()
1349
+ }))), n.enter("labelEnd"), n.enter("labelMarker"), n.consume(h), n.exit("labelMarker"), n.exit("labelEnd"), c) : t(h);
1350
+ }
1351
+ function c(h) {
1352
+ return h === 40 ? n.attempt(Be, r, i ? r : p)(h) : h === 91 ? n.attempt(Le, r, i ? n.attempt(Oe, r, p) : p)(h) : i ? r(h) : p(h);
1353
+ }
1354
+ function p(h) {
1355
+ return l._balanced = !0, t(h);
1356
+ }
1357
+ }
1358
+ function Me(n, r, t) {
1359
+ return e;
1360
+ function e(c) {
1361
+ return n.enter("resource"), n.enter("resourceMarker"), n.consume(c), n.exit("resourceMarker"), dn(n, u);
1362
+ }
1363
+ function u(c) {
1364
+ return c === 41 ? a(c) : ut(n, l, t, "resourceDestination", "resourceDestinationLiteral", "resourceDestinationLiteralMarker", "resourceDestinationRaw", "resourceDestinationString", 32)(c);
1365
+ }
1366
+ function l(c) {
1367
+ return Y(c) ? dn(n, i)(c) : a(c);
1368
+ }
1369
+ function i(c) {
1370
+ return c === 34 || c === 39 || c === 40 ? at(n, dn(n, a), t, "resourceTitle", "resourceTitleMarker", "resourceTitleString")(c) : a(c);
1371
+ }
1372
+ function a(c) {
1373
+ return c === 41 ? (n.enter("resourceMarker"), n.consume(c), n.exit("resourceMarker"), n.exit("resource"), r) : t(c);
1374
+ }
1375
+ }
1376
+ function je(n, r, t) {
1377
+ var e = this;
1378
+ return u;
1379
+ function u(i) {
1380
+ return lt.call(e, n, l, t, "reference", "referenceMarker", "referenceString")(i);
1381
+ }
1382
+ function l(i) {
1383
+ return e.parser.defined.includes(fn(e.sliceSerialize(e.events[e.events.length - 1][1]).slice(1, -1))) ? r(i) : t(i);
1384
+ }
1385
+ }
1386
+ function Re(n, r, t) {
1387
+ return e;
1388
+ function e(l) {
1389
+ return n.enter("reference"), n.enter("referenceMarker"), n.consume(l), n.exit("referenceMarker"), u;
1390
+ }
1391
+ function u(l) {
1392
+ return l === 93 ? (n.enter("referenceMarker"), n.consume(l), n.exit("referenceMarker"), n.exit("reference"), r) : t(l);
1393
+ }
1394
+ }
1395
+ var qe = {
1396
+ name: "labelStartImage",
1397
+ tokenize: He,
1398
+ resolveAll: Dn.resolveAll
1399
+ };
1400
+ function He(n, r, t) {
1401
+ var e = this;
1402
+ return u;
1403
+ function u(a) {
1404
+ return n.enter("labelImage"), n.enter("labelImageMarker"), n.consume(a), n.exit("labelImageMarker"), l;
1405
+ }
1406
+ function l(a) {
1407
+ return a === 91 ? (n.enter("labelMarker"), n.consume(a), n.exit("labelMarker"), n.exit("labelImage"), i) : t(a);
1408
+ }
1409
+ function i(a) {
1410
+ return a === 94 && "_hiddenFootnoteSupport" in e.parser.constructs ? t(a) : r(a);
1411
+ }
1412
+ }
1413
+ var Ne = {
1414
+ name: "labelStartLink",
1415
+ tokenize: Ve,
1416
+ resolveAll: Dn.resolveAll
1417
+ };
1418
+ function Ve(n, r, t) {
1419
+ var e = this;
1420
+ return u;
1421
+ function u(i) {
1422
+ return n.enter("labelLink"), n.enter("labelMarker"), n.consume(i), n.exit("labelMarker"), n.exit("labelLink"), l;
1423
+ }
1424
+ function l(i) {
1425
+ return i === 94 && "_hiddenFootnoteSupport" in e.parser.constructs ? t(i) : r(i);
1426
+ }
1427
+ }
1428
+ var Cn = {
1429
+ name: "lineEnding",
1430
+ tokenize: We
1431
+ };
1432
+ function We(n, r) {
1433
+ return t;
1434
+ function t(e) {
1435
+ return n.enter("lineEnding"), n.consume(e), n.exit("lineEnding"), T(n, r, "linePrefix");
1436
+ }
1437
+ }
1438
+ var bn = {
1439
+ name: "thematicBreak",
1440
+ tokenize: Qe
1441
+ };
1442
+ function Qe(n, r, t) {
1443
+ var e = 0, u;
1444
+ return l;
1445
+ function l(c) {
1446
+ return n.enter("thematicBreak"), u = c, i(c);
1447
+ }
1448
+ function i(c) {
1449
+ return c === u ? (n.enter("thematicBreakSequence"), a(c)) : q(c) ? T(n, i, "whitespace")(c) : e < 3 || c !== null && !C(c) ? t(c) : (n.exit("thematicBreak"), r(c));
1450
+ }
1451
+ function a(c) {
1452
+ return c === u ? (n.consume(c), e++, a) : (n.exit("thematicBreakSequence"), i(c));
1453
+ }
1454
+ }
1455
+ var $ = {
1456
+ name: "list",
1457
+ tokenize: Ze,
1458
+ continuation: {
1459
+ tokenize: Ye
1460
+ },
1461
+ exit: Je
1462
+ }, Ue = {
1463
+ tokenize: Ke,
1464
+ partial: !0
1465
+ }, $e = {
1466
+ tokenize: Ge,
1467
+ partial: !0
1468
+ };
1469
+ function Ze(n, r, t) {
1470
+ var e = this, u = e.events[e.events.length - 1];
1471
+ var l = u && u[1].type === "linePrefix" ? u[2].sliceSerialize(u[1], !0).length : 0, i = 0;
1472
+ return a;
1473
+ function a(f) {
1474
+ var k = e.containerState.type || (f === 42 || f === 43 || f === 45 ? "listUnordered" : "listOrdered");
1475
+ if (k === "listUnordered" ? !e.containerState.marker || f === e.containerState.marker : An(f)) {
1476
+ if (e.containerState.type || (e.containerState.type = k, n.enter(k, {
1477
+ _container: !0
1478
+ })), k === "listUnordered") return n.enter("listItemPrefix"), f === 42 || f === 45 ? n.check(bn, t, p)(f) : p(f);
1479
+ if (!e.interrupt || f === 49) return n.enter("listItemPrefix"), n.enter("listItemValue"), c(f);
1480
+ }
1481
+ return t(f);
1482
+ }
1483
+ function c(f) {
1484
+ return An(f) && ++i < 10 ? (n.consume(f), c) : (!e.interrupt || i < 2) && (e.containerState.marker ? f === e.containerState.marker : f === 41 || f === 46) ? (n.exit("listItemValue"), p(f)) : t(f);
1485
+ }
1486
+ function p(f) {
1487
+ return n.enter("listItemMarker"), n.consume(f), n.exit("listItemMarker"), e.containerState.marker = e.containerState.marker || f, n.check(Sn, // Can’t be empty when interrupting.
1488
+ e.interrupt ? t : h, n.attempt(Ue, g, x));
1489
+ }
1490
+ function h(f) {
1491
+ return e.containerState.initialBlankLine = !0, l++, g(f);
1492
+ }
1493
+ function x(f) {
1494
+ return q(f) ? (n.enter("listItemPrefixWhitespace"), n.consume(f), n.exit("listItemPrefixWhitespace"), g) : t(f);
1495
+ }
1496
+ function g(f) {
1497
+ return e.containerState.size = l + e.sliceSerialize(n.exit("listItemPrefix"), !0).length, r(f);
1498
+ }
1499
+ }
1500
+ function Ye(n, r, t) {
1501
+ var e = this;
1502
+ return e.containerState._closeFlow = void 0, n.check(Sn, u, l);
1503
+ function u(a) {
1504
+ return e.containerState.furtherBlankLines = e.containerState.furtherBlankLines || e.containerState.initialBlankLine, T(n, r, "listItemIndent", e.containerState.size + 1)(a);
1505
+ }
1506
+ function l(a) {
1507
+ return e.containerState.furtherBlankLines || !q(a) ? (e.containerState.furtherBlankLines = void 0, e.containerState.initialBlankLine = void 0, i(a)) : (e.containerState.furtherBlankLines = void 0, e.containerState.initialBlankLine = void 0, n.attempt($e, r, i)(a));
1508
+ }
1509
+ function i(a) {
1510
+ return e.containerState._closeFlow = !0, e.interrupt = void 0, T(n, n.attempt($, r, t), "linePrefix", e.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4)(a);
1511
+ }
1512
+ }
1513
+ function Ge(n, r, t) {
1514
+ var e = this;
1515
+ return T(n, u, "listItemIndent", e.containerState.size + 1);
1516
+ function u(l) {
1517
+ var i = e.events[e.events.length - 1];
1518
+ return i && i[1].type === "listItemIndent" && i[2].sliceSerialize(i[1], !0).length === e.containerState.size ? r(l) : t(l);
1519
+ }
1520
+ }
1521
+ function Je(n) {
1522
+ n.exit(this.containerState.type);
1523
+ }
1524
+ function Ke(n, r, t) {
1525
+ var e = this;
1526
+ return T(n, u, "listItemPrefixWhitespace", e.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4 + 1);
1527
+ function u(l) {
1528
+ var i = e.events[e.events.length - 1];
1529
+ return !q(l) && i && i[1].type === "listItemPrefixWhitespace" ? r(l) : t(l);
1530
+ }
1531
+ }
1532
+ var Gn = {
1533
+ name: "setextUnderline",
1534
+ tokenize: ve,
1535
+ resolveTo: Xe
1536
+ };
1537
+ function Xe(n, r) {
1538
+ var t = n.length, e, u, l;
1539
+ for(; t--;)if (n[t][0] === "enter") {
1540
+ if (n[t][1].type === "content") {
1541
+ e = t;
1542
+ break;
1543
+ }
1544
+ n[t][1].type === "paragraph" && (u = t);
1545
+ } else n[t][1].type === "content" && n.splice(t, 1), !l && n[t][1].type === "definition" && (l = t);
1546
+ var i = {
1547
+ type: "setextHeading",
1548
+ start: Object.assign({}, n[u][1].start),
1549
+ end: Object.assign({}, n[n.length - 1][1].end)
1550
+ };
1551
+ return n[u][1].type = "setextHeadingText", l ? (n.splice(u, 0, [
1552
+ "enter",
1553
+ i,
1554
+ r
1555
+ ]), n.splice(l + 1, 0, [
1556
+ "exit",
1557
+ n[e][1],
1558
+ r
1559
+ ]), n[e][1].end = Object.assign({}, n[l][1].end)) : n[e][1] = i, n.push([
1560
+ "exit",
1561
+ i,
1562
+ r
1563
+ ]), n;
1564
+ }
1565
+ function ve(n, r, t) {
1566
+ var e = this;
1567
+ var u = e.events.length, l, i;
1568
+ for(; u--;)if (e.events[u][1].type !== "lineEnding" && e.events[u][1].type !== "linePrefix" && e.events[u][1].type !== "content") {
1569
+ i = e.events[u][1].type === "paragraph";
1570
+ break;
1571
+ }
1572
+ return a;
1573
+ function a(h) {
1574
+ return !e.parser.lazy[e.now().line] && (e.interrupt || i) ? (n.enter("setextHeadingLine"), n.enter("setextHeadingLineSequence"), l = h, c(h)) : t(h);
1575
+ }
1576
+ function c(h) {
1577
+ return h === l ? (n.consume(h), c) : (n.exit("setextHeadingLineSequence"), T(n, p, "lineSuffix")(h));
1578
+ }
1579
+ function p(h) {
1580
+ return h === null || C(h) ? (n.exit("setextHeadingLine"), r(h)) : t(h);
1581
+ }
1582
+ }
1583
+ var nr = {
1584
+ tokenize: tr
1585
+ };
1586
+ function tr(n) {
1587
+ var r = this, t = n.attempt(// Try to parse a blank line.
1588
+ Sn, e, // Try to parse initial flow (essentially, only code).
1589
+ n.attempt(this.parser.constructs.flowInitial, u, T(n, n.attempt(this.parser.constructs.flow, u, n.attempt(oe, u)), "linePrefix")));
1590
+ return t;
1591
+ function e(l) {
1592
+ if (l === null) {
1593
+ n.consume(l);
1594
+ return;
1595
+ }
1596
+ return n.enter("lineEndingBlank"), n.consume(l), n.exit("lineEndingBlank"), r.currentConstruct = void 0, t;
1597
+ }
1598
+ function u(l) {
1599
+ if (l === null) {
1600
+ n.consume(l);
1601
+ return;
1602
+ }
1603
+ return n.enter("lineEnding"), n.consume(l), n.exit("lineEnding"), r.currentConstruct = void 0, t;
1604
+ }
1605
+ }
1606
+ var er = {
1607
+ resolveAll: st()
1608
+ }, rr = ot("string"), ir = ot("text");
1609
+ function ot(n) {
1610
+ return {
1611
+ tokenize: r,
1612
+ resolveAll: st(n === "text" ? ur : void 0)
1613
+ };
1614
+ function r(t) {
1615
+ var e = this, u = this.parser.constructs[n], l = t.attempt(u, i, a);
1616
+ return i;
1617
+ function i(h) {
1618
+ return p(h) ? l(h) : a(h);
1619
+ }
1620
+ function a(h) {
1621
+ if (h === null) {
1622
+ t.consume(h);
1623
+ return;
1624
+ }
1625
+ return t.enter("data"), t.consume(h), c;
1626
+ }
1627
+ function c(h) {
1628
+ return p(h) ? (t.exit("data"), l(h)) : (t.consume(h), c);
1629
+ }
1630
+ function p(h) {
1631
+ if (h === null) return !0;
1632
+ var x = u[h];
1633
+ var g = -1;
1634
+ if (x) for(; ++g < x.length;){
1635
+ var f = x[g];
1636
+ if (!f.previous || f.previous.call(e, e.previous)) return !0;
1637
+ }
1638
+ return !1;
1639
+ }
1640
+ }
1641
+ }
1642
+ function st(n) {
1643
+ return r;
1644
+ function r(t, e) {
1645
+ var u = -1, l;
1646
+ for(; ++u <= t.length;)l === void 0 ? t[u] && t[u][1].type === "data" && (l = u, u++) : (!t[u] || t[u][1].type !== "data") && (u !== l + 2 && (t[l][1].end = t[u - 1][1].end, t.splice(l + 2, u - l - 2), u = l + 2), l = void 0);
1647
+ return n ? n(t, e) : t;
1648
+ }
1649
+ }
1650
+ function ur(n, r) {
1651
+ var t = 0;
1652
+ for(; ++t <= n.length;)if ((t === n.length || n[t][1].type === "lineEnding") && n[t - 1][1].type === "data") {
1653
+ var e = n[t - 1][1], u = r.sliceStream(e);
1654
+ var l = u.length, i = -1, a = 0, c = void 0;
1655
+ for(; l--;){
1656
+ var p = u[l];
1657
+ if (typeof p == "string") {
1658
+ for(i = p.length; p.charCodeAt(i - 1) === 32;)a++, i--;
1659
+ if (i) break;
1660
+ i = -1;
1661
+ } else if (p === -2) c = !0, a++;
1662
+ else if (p !== -1) {
1663
+ l++;
1664
+ break;
1665
+ }
1666
+ }
1667
+ if (a) {
1668
+ var p1 = {
1669
+ type: t === n.length || c || a < 2 ? "lineSuffix" : "hardBreakTrailing",
1670
+ start: {
1671
+ line: e.end.line,
1672
+ column: e.end.column - a,
1673
+ offset: e.end.offset - a,
1674
+ _index: e.start._index + l,
1675
+ _bufferIndex: l ? i : e.start._bufferIndex + i
1676
+ },
1677
+ end: Object.assign({}, e.end)
1678
+ };
1679
+ e.end = Object.assign({}, p1.start), e.start.offset === e.end.offset ? Object.assign(e, p1) : (n.splice(t, 0, [
1680
+ "enter",
1681
+ p1,
1682
+ r
1683
+ ], [
1684
+ "exit",
1685
+ p1,
1686
+ r
1687
+ ]), t += 2);
1688
+ }
1689
+ t++;
1690
+ }
1691
+ return n;
1692
+ }
1693
+ function lr(n, r, t) {
1694
+ var e = Object.assign(t ? Object.assign({}, t) : {
1695
+ line: 1,
1696
+ column: 1,
1697
+ offset: 0
1698
+ }, {
1699
+ _index: 0,
1700
+ _bufferIndex: -1
1701
+ });
1702
+ var u = {}, l = [];
1703
+ var i = [], a = [];
1704
+ var c = {
1705
+ consume: _,
1706
+ enter: F,
1707
+ exit: L,
1708
+ attempt: P(O),
1709
+ check: P(d),
1710
+ interrupt: P(d, {
1711
+ interrupt: !0
1712
+ })
1713
+ }, p = {
1714
+ previous: null,
1715
+ code: null,
1716
+ containerState: {},
1717
+ events: [],
1718
+ parser: n,
1719
+ sliceStream: f,
1720
+ sliceSerialize: g,
1721
+ now: k,
1722
+ defineSkip: B,
1723
+ write: x
1724
+ };
1725
+ var h = r.tokenize.call(p, c);
1726
+ return r.resolveAll && l.push(r), p;
1727
+ function x(S) {
1728
+ return i = Z(i, S), D(), i[i.length - 1] !== null ? [] : (j(r, 0), p.events = Ln(l, p.events, p), p.events);
1729
+ }
1730
+ function g(S, E) {
1731
+ return or(f(S), E);
1732
+ }
1733
+ function f(S) {
1734
+ return ar(i, S);
1735
+ }
1736
+ function k() {
1737
+ return Object.assign({}, e);
1738
+ }
1739
+ function B(S) {
1740
+ u[S.line] = S.column, V();
1741
+ }
1742
+ function D() {
1743
+ var S;
1744
+ for(; e._index < i.length;){
1745
+ var E = i[e._index];
1746
+ if (typeof E == "string") for(S = e._index, e._bufferIndex < 0 && (e._bufferIndex = 0); e._index === S && e._bufferIndex < E.length;)y(E.charCodeAt(e._bufferIndex));
1747
+ else y(E);
1748
+ }
1749
+ }
1750
+ function y(S) {
1751
+ h = h(S);
1752
+ }
1753
+ function _(S) {
1754
+ C(S) ? (e.line++, e.column = 1, e.offset += S === -3 ? 2 : 1, V()) : S !== -1 && (e.column++, e.offset++), e._bufferIndex < 0 ? e._index++ : (e._bufferIndex++, e._bufferIndex === i[e._index].length && (e._bufferIndex = -1, e._index++)), p.previous = S;
1755
+ }
1756
+ function F(S, E) {
1757
+ var A = E || {};
1758
+ return A.type = S, A.start = k(), p.events.push([
1759
+ "enter",
1760
+ A,
1761
+ p
1762
+ ]), a.push(A), A;
1763
+ }
1764
+ function L(S) {
1765
+ var E = a.pop();
1766
+ return E.end = k(), p.events.push([
1767
+ "exit",
1768
+ E,
1769
+ p
1770
+ ]), E;
1771
+ }
1772
+ function O(S, E) {
1773
+ j(S, E.from);
1774
+ }
1775
+ function d(S, E) {
1776
+ E.restore();
1777
+ }
1778
+ function P(S, E) {
1779
+ return A;
1780
+ function A(Q, G, nn) {
1781
+ var J, W, U, H;
1782
+ return Array.isArray(Q) ? /* c8 ignore next 1 */ o(Q) : "tokenize" in Q ? o([
1783
+ Q
1784
+ ]) : s(Q);
1785
+ function s(N) {
1786
+ return K;
1787
+ function K(ln) {
1788
+ var pn = ln !== null && N[ln], mn = ln !== null && N.null, Fn = // To do: add more extension tests.
1789
+ /* c8 ignore next 2 */ _to_consumable_array(Array.isArray(pn) ? pn : pn ? [
1790
+ pn
1791
+ ] : []).concat(_to_consumable_array(Array.isArray(mn) ? mn : mn ? [
1792
+ mn
1793
+ ] : []));
1794
+ return o(Fn)(ln);
1795
+ }
1796
+ }
1797
+ function o(N) {
1798
+ return J = N, W = 0, N.length === 0 ? nn : cn(N[W]);
1799
+ }
1800
+ function cn(N) {
1801
+ return K;
1802
+ function K(ln) {
1803
+ return H = R(), U = N, N.partial || (p.currentConstruct = N), N.name && p.parser.constructs.disable.null.includes(N.name) ? hn() : N.tokenize.call(// If we do have fields, create an object w/ `context` as its
1804
+ // prototype.
1805
+ // This allows a “live binding”, which is needed for `interrupt`.
1806
+ E ? Object.assign(Object.create(p), E) : p, c, xn, hn)(ln);
1807
+ }
1808
+ }
1809
+ function xn(N) {
1810
+ return S(U, H), G;
1811
+ }
1812
+ function hn(N) {
1813
+ return H.restore(), ++W < J.length ? cn(J[W]) : nn;
1814
+ }
1815
+ }
1816
+ }
1817
+ function j(S, E) {
1818
+ S.resolveAll && !l.includes(S) && l.push(S), S.resolve && en(p.events, E, p.events.length - E, S.resolve(p.events.slice(E), p)), S.resolveTo && (p.events = S.resolveTo(p.events, p));
1819
+ }
1820
+ function R() {
1821
+ var S = k(), E = p.previous, A = p.currentConstruct, Q = p.events.length, G = Array.from(a);
1822
+ return {
1823
+ restore: nn,
1824
+ from: Q
1825
+ };
1826
+ function nn() {
1827
+ e = S, p.previous = E, p.currentConstruct = A, p.events.length = Q, a = G, V();
1828
+ }
1829
+ }
1830
+ function V() {
1831
+ e.line in u && e.column < 2 && (e.column = u[e.line], e.offset += u[e.line] - 1);
1832
+ }
1833
+ }
1834
+ function ar(n, r) {
1835
+ var t = r.start._index, e = r.start._bufferIndex, u = r.end._index, l = r.end._bufferIndex;
1836
+ var i;
1837
+ return t === u ? i = [
1838
+ n[t].slice(e, l)
1839
+ ] : (i = n.slice(t, u), e > -1 && (i[0] = i[0].slice(e)), l > 0 && i.push(n[u].slice(0, l))), i;
1840
+ }
1841
+ function or(n, r) {
1842
+ var t = -1;
1843
+ var e = [];
1844
+ var u;
1845
+ for(; ++t < n.length;){
1846
+ var l = n[t];
1847
+ var i = void 0;
1848
+ if (typeof l == "string") i = l;
1849
+ else switch(l){
1850
+ case -5:
1851
+ {
1852
+ i = "\r";
1853
+ break;
1854
+ }
1855
+ case -4:
1856
+ {
1857
+ i = "\n";
1858
+ break;
1859
+ }
1860
+ case -3:
1861
+ {
1862
+ i = "\r\n";
1863
+ break;
1864
+ }
1865
+ case -2:
1866
+ {
1867
+ i = r ? " " : " ";
1868
+ break;
1869
+ }
1870
+ case -1:
1871
+ {
1872
+ if (!r && u) continue;
1873
+ i = " ";
1874
+ break;
1875
+ }
1876
+ default:
1877
+ i = String.fromCharCode(l);
1878
+ }
1879
+ u = l === -2, e.push(i);
1880
+ }
1881
+ return e.join("");
1882
+ }
1883
+ var _obj, _obj1, _obj2, _obj3, _obj4;
1884
+ var sr = (_obj = {}, _define_property(_obj, 42, $), _define_property(_obj, 43, $), _define_property(_obj, 45, $), _define_property(_obj, 48, $), _define_property(_obj, 49, $), _define_property(_obj, 50, $), _define_property(_obj, 51, $), _define_property(_obj, 52, $), _define_property(_obj, 53, $), _define_property(_obj, 54, $), _define_property(_obj, 55, $), _define_property(_obj, 56, $), _define_property(_obj, 57, $), _define_property(_obj, 62, tt), _obj), cr = _define_property({}, 91, me), hr = (_obj1 = {}, _define_property(_obj1, -2, wn), _define_property(_obj1, -1, wn), _define_property(_obj1, 32, wn), _obj1), pr = (_obj2 = {}, _define_property(_obj2, 35, be), _define_property(_obj2, 42, bn), _define_property(_obj2, 45, [
1885
+ Gn,
1886
+ bn
1887
+ ]), _define_property(_obj2, 60, Ee), _define_property(_obj2, 61, Gn), _define_property(_obj2, 95, bn), _define_property(_obj2, 96, Zn), _define_property(_obj2, 126, Zn), _obj2), mr = (_obj3 = {}, _define_property(_obj3, 38, rt), _define_property(_obj3, 92, et), _obj3), fr = (_obj4 = {}, _define_property(_obj4, -5, Cn), _define_property(_obj4, -4, Cn), _define_property(_obj4, -3, Cn), _define_property(_obj4, 33, qe), _define_property(_obj4, 38, rt), _define_property(_obj4, 42, In), _define_property(_obj4, 60, [
1888
+ Ut,
1889
+ Ie
1890
+ ]), _define_property(_obj4, 91, Ne), _define_property(_obj4, 92, [
1891
+ ke,
1892
+ et
1893
+ ]), _define_property(_obj4, 93, Dn), _define_property(_obj4, 95, In), _define_property(_obj4, 96, re), _obj4), xr = {
1894
+ null: [
1895
+ In,
1896
+ er
1897
+ ]
1898
+ }, gr = {
1899
+ null: [
1900
+ 42,
1901
+ 95
1902
+ ]
1903
+ }, kr = {
1904
+ null: []
1905
+ }, dr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1906
+ __proto__: null,
1907
+ attentionMarkers: gr,
1908
+ contentInitial: cr,
1909
+ disable: kr,
1910
+ document: sr,
1911
+ flow: pr,
1912
+ flowInitial: hr,
1913
+ insideSpan: xr,
1914
+ string: mr,
1915
+ text: fr
1916
+ }, Symbol.toStringTag, {
1917
+ value: "Module"
1918
+ }));
1919
+ function br() {
1920
+ var n = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
1921
+ var r = Bt(// @ts-expect-error Same as above.
1922
+ [
1923
+ dr
1924
+ ].concat(n.extensions || [])), t = {
1925
+ defined: [],
1926
+ lazy: {},
1927
+ constructs: r,
1928
+ content: e(Rt),
1929
+ document: e(Ht),
1930
+ flow: e(nr),
1931
+ string: e(rr),
1932
+ text: e(ir)
1933
+ };
1934
+ return t;
1935
+ function e(u) {
1936
+ return l;
1937
+ function l(i) {
1938
+ return lr(t, u, i);
1939
+ }
1940
+ }
1941
+ }
1942
+ var Jn = /[\0\t\n\r]/g;
1943
+ function yr() {
1944
+ var n = 1, r = "", t = !0, e;
1945
+ return u;
1946
+ function u(l, i, a) {
1947
+ var c = [];
1948
+ var p, h, x, g, f;
1949
+ for(l = r + l.toString(i), x = 0, r = "", t && (l.charCodeAt(0) === 65279 && x++, t = void 0); x < l.length;){
1950
+ if (Jn.lastIndex = x, p = Jn.exec(l), g = p && p.index !== void 0 ? p.index : l.length, f = l.charCodeAt(g), !p) {
1951
+ r = l.slice(x);
1952
+ break;
1953
+ }
1954
+ if (f === 10 && x === g && e) c.push(-3), e = void 0;
1955
+ else switch(e && (c.push(-5), e = void 0), x < g && (c.push(l.slice(x, g)), n += g - x), f){
1956
+ case 0:
1957
+ {
1958
+ c.push(65533), n++;
1959
+ break;
1960
+ }
1961
+ case 9:
1962
+ {
1963
+ for(h = Math.ceil(n / 4) * 4, c.push(-2); n++ < h;)c.push(-1);
1964
+ break;
1965
+ }
1966
+ case 10:
1967
+ {
1968
+ c.push(-4), n = 1;
1969
+ break;
1970
+ }
1971
+ default:
1972
+ e = !0, n = 1;
1973
+ }
1974
+ x = g + 1;
1975
+ }
1976
+ return a && (e && c.push(-5), r && c.push(r), c.push(null)), c;
1977
+ }
1978
+ }
1979
+ function Sr(n) {
1980
+ for(; !it(n););
1981
+ return n;
1982
+ }
1983
+ function ct(n, r) {
1984
+ var t = Number.parseInt(n, r);
1985
+ return(// C0 except for HT, LF, FF, CR, space
1986
+ t < 9 || t === 11 || t > 13 && t < 32 || // Control character (DEL) of the basic block and C1 controls.
1987
+ t > 126 && t < 160 || // Lone high surrogates and low surrogates.
1988
+ t > 55295 && t < 57344 || // Noncharacters.
1989
+ t > 64975 && t < 65008 || (t & 65535) === 65535 || (t & 65535) === 65534 || // Out of range
1990
+ t > 1114111 ? "�" : String.fromCharCode(t));
1991
+ }
1992
+ var Fr = /\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;
1993
+ function Er(n) {
1994
+ return n.replace(Fr, wr);
1995
+ }
1996
+ function wr(n, r, t) {
1997
+ if (r) return r;
1998
+ if (t.charCodeAt(0) === 35) {
1999
+ var u = t.charCodeAt(1), l = u === 120 || u === 88;
2000
+ return ct(t.slice(l ? 2 : 1), l ? 16 : 10);
2001
+ }
2002
+ return On(t) || n;
2003
+ }
2004
+ function yn(n) {
2005
+ return !n || typeof n != "object" ? "" : "position" in n || "type" in n ? Kn(n.position) : "start" in n || "end" in n ? Kn(n) : "line" in n || "column" in n ? Tn(n) : "";
2006
+ }
2007
+ function Tn(n) {
2008
+ return Xn(n && n.line) + ":" + Xn(n && n.column);
2009
+ }
2010
+ function Kn(n) {
2011
+ return Tn(n && n.start) + "-" + Tn(n && n.end);
2012
+ }
2013
+ function Xn(n) {
2014
+ return n && typeof n == "number" ? n : 1;
2015
+ }
2016
+ var ht = {}.hasOwnProperty, pt = /**
2017
+ * @type {(
2018
+ * ((value: Value, encoding: Encoding, options?: Options | null | undefined) => Root) &
2019
+ * ((value: Value, options?: Options | null | undefined) => Root)
2020
+ * )}
2021
+ */ /**
2022
+ * @param {Value} value
2023
+ * @param {Encoding | Options | null | undefined} [encoding]
2024
+ * @param {Options | null | undefined} [options]
2025
+ * @returns {Root}
2026
+ */ function pt(n, r, t) {
2027
+ return typeof r != "string" && (t = r, r = void 0), Cr(t)(Sr(// @ts-expect-error: micromark types need to accept `null`.
2028
+ br(t).document().write(yr()(n, r, !0))));
2029
+ };
2030
+ function Cr(n) {
2031
+ var r = {
2032
+ transforms: [],
2033
+ canContainEols: [
2034
+ "emphasis",
2035
+ "fragment",
2036
+ "heading",
2037
+ "paragraph",
2038
+ "strong"
2039
+ ],
2040
+ enter: {
2041
+ autolink: a(Rn),
2042
+ autolinkProtocol: S,
2043
+ autolinkEmail: S,
2044
+ atxHeading: a(_n),
2045
+ blockQuote: a(Fn),
2046
+ characterEscape: S,
2047
+ characterReference: S,
2048
+ codeFenced: a(Pn),
2049
+ codeFencedFenceInfo: c,
2050
+ codeFencedFenceMeta: c,
2051
+ codeIndented: a(Pn, c),
2052
+ codeText: a(kt, c),
2053
+ codeTextData: S,
2054
+ data: S,
2055
+ codeFlowValue: S,
2056
+ definition: a(dt),
2057
+ definitionDestinationString: c,
2058
+ definitionLabelString: c,
2059
+ definitionTitleString: c,
2060
+ emphasis: a(bt),
2061
+ hardBreakEscape: a(Mn),
2062
+ hardBreakTrailing: a(Mn),
2063
+ htmlFlow: a(jn, c),
2064
+ htmlFlowData: S,
2065
+ htmlText: a(jn, c),
2066
+ htmlTextData: S,
2067
+ image: a(yt),
2068
+ label: c,
2069
+ link: a(Rn),
2070
+ listItem: a(St),
2071
+ listItemValue: k,
2072
+ listOrdered: a(qn, f),
2073
+ listUnordered: a(qn),
2074
+ paragraph: a(Ft),
2075
+ reference: hn,
2076
+ referenceString: c,
2077
+ resourceDestinationString: c,
2078
+ resourceTitleString: c,
2079
+ setextHeading: a(_n),
2080
+ strong: a(Et),
2081
+ thematicBreak: a(Ct)
2082
+ },
2083
+ exit: {
2084
+ atxHeading: h(),
2085
+ atxHeadingSequence: P,
2086
+ autolink: h(),
2087
+ autolinkEmail: mn,
2088
+ autolinkProtocol: pn,
2089
+ blockQuote: h(),
2090
+ characterEscapeValue: E,
2091
+ characterReferenceMarkerHexadecimal: K,
2092
+ characterReferenceMarkerNumeric: K,
2093
+ characterReferenceValue: ln,
2094
+ codeFenced: h(_),
2095
+ codeFencedFence: y,
2096
+ codeFencedFenceInfo: B,
2097
+ codeFencedFenceMeta: D,
2098
+ codeFlowValue: E,
2099
+ codeIndented: h(F),
2100
+ codeText: h(J),
2101
+ codeTextData: E,
2102
+ data: E,
2103
+ definition: h(),
2104
+ definitionDestinationString: d,
2105
+ definitionLabelString: L,
2106
+ definitionTitleString: O,
2107
+ emphasis: h(),
2108
+ hardBreakEscape: h(Q),
2109
+ hardBreakTrailing: h(Q),
2110
+ htmlFlow: h(G),
2111
+ htmlFlowData: E,
2112
+ htmlText: h(nn),
2113
+ htmlTextData: E,
2114
+ image: h(U),
2115
+ label: s,
2116
+ labelText: H,
2117
+ lineEnding: A,
2118
+ link: h(W),
2119
+ listItem: h(),
2120
+ listOrdered: h(),
2121
+ listUnordered: h(),
2122
+ paragraph: h(),
2123
+ referenceString: N,
2124
+ resourceDestinationString: o,
2125
+ resourceTitleString: cn,
2126
+ resource: xn,
2127
+ setextHeading: h(V),
2128
+ setextHeadingLineSequence: R,
2129
+ setextHeadingText: j,
2130
+ strong: h(),
2131
+ thematicBreak: h()
2132
+ }
2133
+ };
2134
+ mt(r, (n || {}).mdastExtensions || []);
2135
+ var t = {};
2136
+ return e;
2137
+ function e(m) {
2138
+ var b = {
2139
+ type: "root",
2140
+ children: []
2141
+ };
2142
+ var w = {
2143
+ stack: [
2144
+ b
2145
+ ],
2146
+ tokenStack: [],
2147
+ config: r,
2148
+ enter: p,
2149
+ exit: x,
2150
+ buffer: c,
2151
+ resume: g,
2152
+ setData: l,
2153
+ getData: i
2154
+ }, z = [];
2155
+ var I = -1;
2156
+ for(; ++I < m.length;)if (m[I][1].type === "listOrdered" || m[I][1].type === "listUnordered") if (m[I][0] === "enter") z.push(I);
2157
+ else {
2158
+ var X = z.pop();
2159
+ I = u(m, X, I);
2160
+ }
2161
+ for(I = -1; ++I < m.length;){
2162
+ var X1 = r[m[I][0]];
2163
+ ht.call(X1, m[I][1].type) && X1[m[I][1].type].call(Object.assign({
2164
+ sliceSerialize: m[I][2].sliceSerialize
2165
+ }, w), m[I][1]);
2166
+ }
2167
+ if (w.tokenStack.length > 0) {
2168
+ var X2 = w.tokenStack[w.tokenStack.length - 1];
2169
+ (X2[1] || vn).call(w, void 0, X2[0]);
2170
+ }
2171
+ for(b.position = {
2172
+ start: on(m.length > 0 ? m[0][1].start : {
2173
+ line: 1,
2174
+ column: 1,
2175
+ offset: 0
2176
+ }),
2177
+ end: on(m.length > 0 ? m[m.length - 2][1].end : {
2178
+ line: 1,
2179
+ column: 1,
2180
+ offset: 0
2181
+ })
2182
+ }, I = -1; ++I < r.transforms.length;)b = r.transforms[I](b) || b;
2183
+ return b;
2184
+ }
2185
+ function u(m, b, w) {
2186
+ var z = b - 1, I = -1, X = !1, an, rn, gn, kn;
2187
+ for(; ++z <= w;){
2188
+ var M = m[z];
2189
+ if (M[1].type === "listUnordered" || M[1].type === "listOrdered" || M[1].type === "blockQuote" ? (M[0] === "enter" ? I++ : I--, kn = void 0) : M[1].type === "lineEndingBlank" ? M[0] === "enter" && (an && !kn && !I && !gn && (gn = z), kn = void 0) : M[1].type === "linePrefix" || M[1].type === "listItemValue" || M[1].type === "listItemMarker" || M[1].type === "listItemPrefix" || M[1].type === "listItemPrefixWhitespace" || (kn = void 0), !I && M[0] === "enter" && M[1].type === "listItemPrefix" || I === -1 && M[0] === "exit" && (M[1].type === "listUnordered" || M[1].type === "listOrdered")) {
2190
+ if (an) {
2191
+ var En = z;
2192
+ for(rn = void 0; En--;){
2193
+ var un = m[En];
2194
+ if (un[1].type === "lineEnding" || un[1].type === "lineEndingBlank") {
2195
+ if (un[0] === "exit") continue;
2196
+ rn && (m[rn][1].type = "lineEndingBlank", X = !0), un[1].type = "lineEnding", rn = En;
2197
+ } else if (!(un[1].type === "linePrefix" || un[1].type === "blockQuotePrefix" || un[1].type === "blockQuotePrefixWhitespace" || un[1].type === "blockQuoteMarker" || un[1].type === "listItemIndent")) break;
2198
+ }
2199
+ gn && (!rn || gn < rn) && (an._spread = !0), an.end = Object.assign({}, rn ? m[rn][1].start : M[1].end), m.splice(rn || z, 0, [
2200
+ "exit",
2201
+ an,
2202
+ M[2]
2203
+ ]), z++, w++;
2204
+ }
2205
+ M[1].type === "listItemPrefix" && (an = {
2206
+ type: "listItem",
2207
+ // @ts-expect-error Patched
2208
+ _spread: !1,
2209
+ start: Object.assign({}, M[1].start)
2210
+ }, m.splice(z, 0, [
2211
+ "enter",
2212
+ an,
2213
+ M[2]
2214
+ ]), z++, w++, gn = void 0, kn = !0);
2215
+ }
2216
+ }
2217
+ return m[b][1]._spread = X, w;
2218
+ }
2219
+ function l(m, b) {
2220
+ t[m] = b;
2221
+ }
2222
+ function i(m) {
2223
+ return t[m];
2224
+ }
2225
+ function a(m, b) {
2226
+ return w;
2227
+ function w(z) {
2228
+ p.call(this, m(z), z), b && b.call(this, z);
2229
+ }
2230
+ }
2231
+ function c() {
2232
+ this.stack.push({
2233
+ type: "fragment",
2234
+ children: []
2235
+ });
2236
+ }
2237
+ function p(m, b, w) {
2238
+ return this.stack[this.stack.length - 1].children.push(m), this.stack.push(m), this.tokenStack.push([
2239
+ b,
2240
+ w
2241
+ ]), m.position = {
2242
+ start: on(b.start)
2243
+ }, m;
2244
+ }
2245
+ function h(m) {
2246
+ return b;
2247
+ function b(w) {
2248
+ m && m.call(this, w), x.call(this, w);
2249
+ }
2250
+ }
2251
+ function x(m, b) {
2252
+ var w = this.stack.pop(), z = this.tokenStack.pop();
2253
+ if (z) z[0].type !== m.type && (b ? b.call(this, m, z[0]) : (z[1] || vn).call(this, m, z[0]));
2254
+ else throw new Error("Cannot close `" + m.type + "` (" + yn({
2255
+ start: m.start,
2256
+ end: m.end
2257
+ }) + "): it’s not open");
2258
+ return w.position.end = on(m.end), w;
2259
+ }
2260
+ function g() {
2261
+ return Tt(this.stack.pop());
2262
+ }
2263
+ function f() {
2264
+ l("expectingFirstListItemValue", !0);
2265
+ }
2266
+ function k(m) {
2267
+ if (i("expectingFirstListItemValue")) {
2268
+ var b = this.stack[this.stack.length - 2];
2269
+ b.start = Number.parseInt(this.sliceSerialize(m), 10), l("expectingFirstListItemValue");
2270
+ }
2271
+ }
2272
+ function B() {
2273
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2274
+ b.lang = m;
2275
+ }
2276
+ function D() {
2277
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2278
+ b.meta = m;
2279
+ }
2280
+ function y() {
2281
+ i("flowCodeInside") || (this.buffer(), l("flowCodeInside", !0));
2282
+ }
2283
+ function _() {
2284
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2285
+ b.value = m.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g, ""), l("flowCodeInside");
2286
+ }
2287
+ function F() {
2288
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2289
+ b.value = m.replace(/(\r?\n|\r)$/g, "");
2290
+ }
2291
+ function L(m) {
2292
+ var b = this.resume(), w = this.stack[this.stack.length - 1];
2293
+ w.label = b, w.identifier = fn(this.sliceSerialize(m)).toLowerCase();
2294
+ }
2295
+ function O() {
2296
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2297
+ b.title = m;
2298
+ }
2299
+ function d() {
2300
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2301
+ b.url = m;
2302
+ }
2303
+ function P(m) {
2304
+ var b = this.stack[this.stack.length - 1];
2305
+ if (!b.depth) {
2306
+ var w = this.sliceSerialize(m).length;
2307
+ b.depth = w;
2308
+ }
2309
+ }
2310
+ function j() {
2311
+ l("setextHeadingSlurpLineEnding", !0);
2312
+ }
2313
+ function R(m) {
2314
+ var b = this.stack[this.stack.length - 1];
2315
+ b.depth = this.sliceSerialize(m).charCodeAt(0) === 61 ? 1 : 2;
2316
+ }
2317
+ function V() {
2318
+ l("setextHeadingSlurpLineEnding");
2319
+ }
2320
+ function S(m) {
2321
+ var b = this.stack[this.stack.length - 1];
2322
+ var w = b.children[b.children.length - 1];
2323
+ (!w || w.type !== "text") && (w = wt(), w.position = {
2324
+ start: on(m.start)
2325
+ }, b.children.push(w)), this.stack.push(w);
2326
+ }
2327
+ function E(m) {
2328
+ var b = this.stack.pop();
2329
+ b.value += this.sliceSerialize(m), b.position.end = on(m.end);
2330
+ }
2331
+ function A(m) {
2332
+ var b = this.stack[this.stack.length - 1];
2333
+ if (i("atHardBreak")) {
2334
+ var w = b.children[b.children.length - 1];
2335
+ w.position.end = on(m.end), l("atHardBreak");
2336
+ return;
2337
+ }
2338
+ !i("setextHeadingSlurpLineEnding") && r.canContainEols.includes(b.type) && (S.call(this, m), E.call(this, m));
2339
+ }
2340
+ function Q() {
2341
+ l("atHardBreak", !0);
2342
+ }
2343
+ function G() {
2344
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2345
+ b.value = m;
2346
+ }
2347
+ function nn() {
2348
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2349
+ b.value = m;
2350
+ }
2351
+ function J() {
2352
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2353
+ b.value = m;
2354
+ }
2355
+ function W() {
2356
+ var m = this.stack[this.stack.length - 1];
2357
+ if (i("inReference")) {
2358
+ var b = i("referenceType") || "shortcut";
2359
+ m.type += "Reference", m.referenceType = b, delete m.url, delete m.title;
2360
+ } else delete m.identifier, delete m.label;
2361
+ l("referenceType");
2362
+ }
2363
+ function U() {
2364
+ var m = this.stack[this.stack.length - 1];
2365
+ if (i("inReference")) {
2366
+ var b = i("referenceType") || "shortcut";
2367
+ m.type += "Reference", m.referenceType = b, delete m.url, delete m.title;
2368
+ } else delete m.identifier, delete m.label;
2369
+ l("referenceType");
2370
+ }
2371
+ function H(m) {
2372
+ var b = this.sliceSerialize(m), w = this.stack[this.stack.length - 2];
2373
+ w.label = Er(b), w.identifier = fn(b).toLowerCase();
2374
+ }
2375
+ function s() {
2376
+ var m = this.stack[this.stack.length - 1], b = this.resume(), w = this.stack[this.stack.length - 1];
2377
+ if (l("inReference", !0), w.type === "link") {
2378
+ var z = m.children;
2379
+ w.children = z;
2380
+ } else w.alt = b;
2381
+ }
2382
+ function o() {
2383
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2384
+ b.url = m;
2385
+ }
2386
+ function cn() {
2387
+ var m = this.resume(), b = this.stack[this.stack.length - 1];
2388
+ b.title = m;
2389
+ }
2390
+ function xn() {
2391
+ l("inReference");
2392
+ }
2393
+ function hn() {
2394
+ l("referenceType", "collapsed");
2395
+ }
2396
+ function N(m) {
2397
+ var b = this.resume(), w = this.stack[this.stack.length - 1];
2398
+ w.label = b, w.identifier = fn(this.sliceSerialize(m)).toLowerCase(), l("referenceType", "full");
2399
+ }
2400
+ function K(m) {
2401
+ l("characterReferenceType", m.type);
2402
+ }
2403
+ function ln(m) {
2404
+ var b = this.sliceSerialize(m), w = i("characterReferenceType");
2405
+ var z;
2406
+ w ? (z = ct(b, w === "characterReferenceMarkerNumeric" ? 10 : 16), l("characterReferenceType")) : z = On(b);
2407
+ var I = this.stack.pop();
2408
+ I.value += z, I.position.end = on(m.end);
2409
+ }
2410
+ function pn(m) {
2411
+ E.call(this, m);
2412
+ var b = this.stack[this.stack.length - 1];
2413
+ b.url = this.sliceSerialize(m);
2414
+ }
2415
+ function mn(m) {
2416
+ E.call(this, m);
2417
+ var b = this.stack[this.stack.length - 1];
2418
+ b.url = "mailto:" + this.sliceSerialize(m);
2419
+ }
2420
+ function Fn() {
2421
+ return {
2422
+ type: "blockquote",
2423
+ children: []
2424
+ };
2425
+ }
2426
+ function Pn() {
2427
+ return {
2428
+ type: "code",
2429
+ lang: null,
2430
+ meta: null,
2431
+ value: ""
2432
+ };
2433
+ }
2434
+ function kt() {
2435
+ return {
2436
+ type: "inlineCode",
2437
+ value: ""
2438
+ };
2439
+ }
2440
+ function dt() {
2441
+ return {
2442
+ type: "definition",
2443
+ identifier: "",
2444
+ label: null,
2445
+ title: null,
2446
+ url: ""
2447
+ };
2448
+ }
2449
+ function bt() {
2450
+ return {
2451
+ type: "emphasis",
2452
+ children: []
2453
+ };
2454
+ }
2455
+ function _n() {
2456
+ return {
2457
+ type: "heading",
2458
+ depth: void 0,
2459
+ children: []
2460
+ };
2461
+ }
2462
+ function Mn() {
2463
+ return {
2464
+ type: "break"
2465
+ };
2466
+ }
2467
+ function jn() {
2468
+ return {
2469
+ type: "html",
2470
+ value: ""
2471
+ };
2472
+ }
2473
+ function yt() {
2474
+ return {
2475
+ type: "image",
2476
+ title: null,
2477
+ url: "",
2478
+ alt: null
2479
+ };
2480
+ }
2481
+ function Rn() {
2482
+ return {
2483
+ type: "link",
2484
+ title: null,
2485
+ url: "",
2486
+ children: []
2487
+ };
2488
+ }
2489
+ function qn(m) {
2490
+ return {
2491
+ type: "list",
2492
+ ordered: m.type === "listOrdered",
2493
+ start: null,
2494
+ // @ts-expect-error Patched.
2495
+ spread: m._spread,
2496
+ children: []
2497
+ };
2498
+ }
2499
+ function St(m) {
2500
+ return {
2501
+ type: "listItem",
2502
+ // @ts-expect-error Patched.
2503
+ spread: m._spread,
2504
+ checked: null,
2505
+ children: []
2506
+ };
2507
+ }
2508
+ function Ft() {
2509
+ return {
2510
+ type: "paragraph",
2511
+ children: []
2512
+ };
2513
+ }
2514
+ function Et() {
2515
+ return {
2516
+ type: "strong",
2517
+ children: []
2518
+ };
2519
+ }
2520
+ function wt() {
2521
+ return {
2522
+ type: "text",
2523
+ value: ""
2524
+ };
2525
+ }
2526
+ function Ct() {
2527
+ return {
2528
+ type: "thematicBreak"
2529
+ };
2530
+ }
2531
+ }
2532
+ function on(n) {
2533
+ return {
2534
+ line: n.line,
2535
+ column: n.column,
2536
+ offset: n.offset
2537
+ };
2538
+ }
2539
+ function mt(n, r) {
2540
+ var t = -1;
2541
+ for(; ++t < r.length;){
2542
+ var e = r[t];
2543
+ Array.isArray(e) ? mt(n, e) : Ar(n, e);
2544
+ }
2545
+ }
2546
+ function Ar(n, r) {
2547
+ var t;
2548
+ for(t in r)if (ht.call(r, t)) {
2549
+ if (t === "canContainEols") {
2550
+ var _n_t;
2551
+ var e = r[t];
2552
+ e && (_n_t = n[t]).push.apply(_n_t, _to_consumable_array(e));
2553
+ } else if (t === "transforms") {
2554
+ var _n_t1;
2555
+ var e1 = r[t];
2556
+ e1 && (_n_t1 = n[t]).push.apply(_n_t1, _to_consumable_array(e1));
2557
+ } else if (t === "enter" || t === "exit") {
2558
+ var e2 = r[t];
2559
+ e2 && Object.assign(n[t], e2);
2560
+ }
2561
+ }
2562
+ }
2563
+ function vn(n, r) {
2564
+ throw n ? new Error("Cannot close `" + n.type + "` (" + yn({
2565
+ start: n.start,
2566
+ end: n.end
2567
+ }) + "): a different token (`" + r.type + "`, " + yn({
2568
+ start: r.start,
2569
+ end: r.end
2570
+ }) + ") is open") : new Error("Cannot close document, a token (`" + r.type + "`, " + yn({
2571
+ start: r.start,
2572
+ end: r.end
2573
+ }) + ") is still open");
2574
+ }
2575
+ function zr(n) {
2576
+ var r = n.replace(/\n{2,}/g, "\n");
2577
+ return index.Pl(r);
2578
+ }
2579
+ function Ir(n) {
2580
+ var r = zr(n), _pt = pt(r), t = _pt.children, e = [
2581
+ []
2582
+ ];
2583
+ var u = 0;
2584
+ function l(i) {
2585
+ var a = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "normal";
2586
+ i.type === "text" ? i.value.split("\n").forEach(function(p, h) {
2587
+ h !== 0 && (u++, e.push([])), p.split(" ").forEach(function(x) {
2588
+ x && e[u].push({
2589
+ content: x,
2590
+ type: a
2591
+ });
2592
+ });
2593
+ }) : (i.type === "strong" || i.type === "emphasis") && i.children.forEach(function(c) {
2594
+ l(c, i.type);
2595
+ });
2596
+ }
2597
+ return t.forEach(function(i) {
2598
+ i.type === "paragraph" && i.children.forEach(function(a) {
2599
+ l(a);
2600
+ });
2601
+ }), e;
2602
+ }
2603
+ function Tr(n) {
2604
+ var _pt = pt(n), r = _pt.children;
2605
+ function t(e) {
2606
+ return e.type === "text" ? e.value.replace(/\n/g, "<br/>") : e.type === "strong" ? "<strong>".concat(e.children.map(t).join(""), "</strong>") : e.type === "emphasis" ? "<em>".concat(e.children.map(t).join(""), "</em>") : e.type === "paragraph" ? "<p>".concat(e.children.map(t).join(""), "</p>") : "Unsupported markdown: ".concat(e.type);
2607
+ }
2608
+ return r.map(t).join("");
2609
+ }
2610
+ function Br(n) {
2611
+ return Intl.Segmenter ? _to_consumable_array(new Intl.Segmenter().segment(n)).map(function(r) {
2612
+ return r.segment;
2613
+ }) : _to_consumable_array(n);
2614
+ }
2615
+ function Lr(n, r) {
2616
+ var t = Br(r.content);
2617
+ return ft(n, [], t, r.type);
2618
+ }
2619
+ function ft(n, r, t, e) {
2620
+ if (t.length === 0) return [
2621
+ {
2622
+ content: r.join(""),
2623
+ type: e
2624
+ },
2625
+ {
2626
+ content: "",
2627
+ type: e
2628
+ }
2629
+ ];
2630
+ var _t = _to_array(t), u = _t[0], l = _t.slice(1), i = _to_consumable_array(r).concat([
2631
+ u
2632
+ ]);
2633
+ return n([
2634
+ {
2635
+ content: i.join(""),
2636
+ type: e
2637
+ }
2638
+ ]) ? ft(n, i, l, e) : (r.length === 0 && u && (r.push(u), t.shift()), [
2639
+ {
2640
+ content: r.join(""),
2641
+ type: e
2642
+ },
2643
+ {
2644
+ content: t.join(""),
2645
+ type: e
2646
+ }
2647
+ ]);
2648
+ }
2649
+ function Or(n, r) {
2650
+ if (n.some(function(param) {
2651
+ var t = param.content;
2652
+ return t.includes("\n");
2653
+ })) throw new Error("splitLineToFitWidth does not support newlines in the line");
2654
+ return Bn(n, r);
2655
+ }
2656
+ function Bn(n, r) {
2657
+ var t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : [], e = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : [];
2658
+ if (n.length === 0) return e.length > 0 && t.push(e), t.length > 0 ? t : [];
2659
+ var u = "";
2660
+ n[0].content === " " && (u = " ", n.shift());
2661
+ var _n_shift;
2662
+ var l = (_n_shift = n.shift()) !== null && _n_shift !== void 0 ? _n_shift : {
2663
+ content: " ",
2664
+ type: "normal"
2665
+ }, i = _to_consumable_array(e);
2666
+ if (u !== "" && i.push({
2667
+ content: u,
2668
+ type: "normal"
2669
+ }), i.push(l), r(i)) return Bn(n, r, t, i);
2670
+ if (e.length > 0) t.push(e), n.unshift(l);
2671
+ else if (l.content) {
2672
+ var _Lr = _sliced_to_array(Lr(r, l), 2), a = _Lr[0], c = _Lr[1];
2673
+ t.push([
2674
+ a
2675
+ ]), c.content && n.unshift(c);
2676
+ }
2677
+ return Bn(n, r, t);
2678
+ }
2679
+ function Dr(n, r) {
2680
+ r && n.attr("style", r);
2681
+ }
2682
+ function Pr(n, r, t, e) {
2683
+ var u = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : !1;
2684
+ var l = n.append("foreignObject"), i = l.append("xhtml:div"), a = r.label, c = r.isNode ? "nodeLabel" : "edgeLabel";
2685
+ i.html('\n <span class="'.concat(c, " ").concat(e, '" ') + (r.labelStyle ? 'style="' + r.labelStyle + '"' : "") + ">" + a + "</span>"), Dr(i, r.labelStyle), i.style("display", "table-cell"), i.style("white-space", "nowrap"), i.style("max-width", t + "px"), i.attr("xmlns", "http://www.w3.org/1999/xhtml"), u && i.attr("class", "labelBkg");
2686
+ var p = i.node().getBoundingClientRect();
2687
+ return p.width === t && (i.style("display", "table"), i.style("white-space", "break-spaces"), i.style("width", t + "px"), p = i.node().getBoundingClientRect()), l.style("width", p.width), l.style("height", p.height), l.node();
2688
+ }
2689
+ function xt(n, r, t) {
2690
+ return n.append("tspan").attr("class", "text-outer-tspan").attr("x", 0).attr("y", r * t - 0.1 + "em").attr("dy", t + "em");
2691
+ }
2692
+ function _r(n, r, t) {
2693
+ var e = n.append("text"), u = xt(e, 1, r);
2694
+ gt(u, t);
2695
+ var l = u.node().getComputedTextLength();
2696
+ return e.remove(), l;
2697
+ }
2698
+ function Mr(n, r, t) {
2699
+ var e = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : !1;
2700
+ var l = r.append("g"), i = l.insert("rect").attr("class", "background"), a = l.append("text").attr("y", "-10.1");
2701
+ var c = 0;
2702
+ var _iteratorNormalCompletion = true, _didIteratorError = false, _iteratorError = undefined;
2703
+ try {
2704
+ for(var _iterator = t[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
2705
+ var p = _step.value;
2706
+ var h = function(g) {
2707
+ return _r(l, 1.1, g) <= n;
2708
+ }, x = h(p) ? [
2709
+ p
2710
+ ] : Or(p, h);
2711
+ var _iteratorNormalCompletion1 = true, _didIteratorError1 = false, _iteratorError1 = undefined;
2712
+ try {
2713
+ for(var _iterator1 = x[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true){
2714
+ var g = _step1.value;
2715
+ var f = xt(a, c, 1.1);
2716
+ gt(f, g), c++;
2717
+ }
2718
+ } catch (err) {
2719
+ _didIteratorError1 = true;
2720
+ _iteratorError1 = err;
2721
+ } finally{
2722
+ try {
2723
+ if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
2724
+ _iterator1.return();
2725
+ }
2726
+ } finally{
2727
+ if (_didIteratorError1) {
2728
+ throw _iteratorError1;
2729
+ }
2730
+ }
2731
+ }
2732
+ }
2733
+ } catch (err) {
2734
+ _didIteratorError = true;
2735
+ _iteratorError = err;
2736
+ } finally{
2737
+ try {
2738
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
2739
+ _iterator.return();
2740
+ }
2741
+ } finally{
2742
+ if (_didIteratorError) {
2743
+ throw _iteratorError;
2744
+ }
2745
+ }
2746
+ }
2747
+ if (e) {
2748
+ var p1 = a.node().getBBox(), h1 = 2;
2749
+ return i.attr("x", -h1).attr("y", -h1).attr("width", p1.width + 2 * h1).attr("height", p1.height + 2 * h1), l.node();
2750
+ } else return a.node();
2751
+ }
2752
+ function gt(n, r) {
2753
+ n.text(""), r.forEach(function(t, e) {
2754
+ var u = n.append("tspan").attr("font-style", t.type === "emphasis" ? "italic" : "normal").attr("class", "text-inner-tspan").attr("font-weight", t.type === "strong" ? "bold" : "normal");
2755
+ e === 0 ? u.text(t.content) : u.text(" " + t.content);
2756
+ });
2757
+ }
2758
+ var Rr = function(n) {
2759
+ var r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "", _ref = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, tmp = _ref.style, t = tmp === void 0 ? "" : tmp, tmp1 = _ref.isTitle, e = tmp1 === void 0 ? !1 : tmp1, tmp2 = _ref.classes, u = tmp2 === void 0 ? "" : tmp2, tmp3 = _ref.useHtmlLabels, l = tmp3 === void 0 ? !0 : tmp3, tmp4 = _ref.isNode, i = tmp4 === void 0 ? !0 : tmp4, tmp5 = _ref.width, a = tmp5 === void 0 ? 200 : tmp5, tmp6 = _ref.addSvgBackground, c = tmp6 === void 0 ? !1 : tmp6;
2760
+ if (index.S.info("createText", r, t, e, u, l, i, c), l) {
2761
+ var p = Tr(r), h = {
2762
+ isNode: i,
2763
+ label: index.cx(p).replace(/fa[blrs]?:fa-[\w-]+/g, function(g) {
2764
+ return "<i class='".concat(g.replace(":", " "), "'></i>");
2765
+ }),
2766
+ labelStyle: t.replace("fill:", "color:")
2767
+ };
2768
+ return Pr(n, h, a, u, c);
2769
+ } else {
2770
+ var p1 = Ir(r);
2771
+ return Mr(a, n, p1, c);
2772
+ }
2773
+ };
2774
+
2775
+ exports.Rr = Rr;