md-editor-v3 6.5.6 → 7.0.0-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.
@@ -1,16 +1,23 @@
1
- import { useId as Me, provide as T, computed as A, reactive as ie, watch as x, onMounted as M, ref as z, inject as $, nextTick as W, shallowRef as te, onBeforeUnmount as ne, toRef as Pe, defineComponent as de, createVNode as j, Fragment as Le, h as _e } from "vue";
2
- import { deepMerge as Oe, deepClone as Ne, randomId as se, debounce as Be } from "@vavt/util";
3
- import { p as h, g as L, f as me, s as fe, a as je, b as De } from "./config.mjs";
4
- import { b, R as Ve, U as Ge, C as Te, B as Y, O as Se, E as ee, g as he, F as pe, h as ge, i as ve, H as ye, j as be, e as Ue, k as ue, d as ze, f as re, P as We, T as qe } from "./event-bus.mjs";
5
- import { a as O, u as Ke, S as Ze, c as Je, z as Xe } from "./dom.mjs";
6
- import Ye from "@vavt/copy2clipboard";
7
- import Qe from "markdown-it";
8
- import et from "markdown-it-image-figures";
9
- import tt from "markdown-it-sub";
10
- import nt from "markdown-it-sup";
11
- import { a as ot } from "./index5.mjs";
12
- import at from "medium-zoom";
13
- const P = {
1
+ import { useId as je, provide as I, computed as F, reactive as me, watch as x, onMounted as L, ref as U, inject as $, nextTick as W, shallowRef as se, onBeforeUnmount as le, toRef as De, defineComponent as pe, createVNode as j, Fragment as Ve, h as ze } from "vue";
2
+ import { b, g as ge, R as Ge, U as Ue, C as Fe, B as ne, O as Re, E as re, h as ye, F as be, i as Ce, j as we, H as $e, k as Ee, e as We, d as qe, f as de, P as Ke, T as Ze } from "./event-bus.mjs";
3
+ import { deepMerge as Je, deepClone as Xe, randomId as fe, debounce as Ye } from "@vavt/util";
4
+ import { p as h, g as P, f as xe, s as Ie, a as Qe, b as et } from "./config.mjs";
5
+ import { a as O, u as tt, S as nt, c as ot, z as at } from "./dom.mjs";
6
+ import rt from "@vavt/copy2clipboard";
7
+ import st from "markdown-it";
8
+ import lt from "markdown-it-image-figures";
9
+ import it from "markdown-it-sub";
10
+ import ct from "markdown-it-sup";
11
+ import { p as dt, a as ut } from "./index5.mjs";
12
+ import mt from "medium-zoom";
13
+ const ft = (e, t, a) => {
14
+ const { editorId: o } = a, n = {
15
+ rerender() {
16
+ b.emit(o, ge);
17
+ }
18
+ };
19
+ t.expose(n);
20
+ }, M = {
14
21
  hljs: `${h}-hljs`,
15
22
  hlcss: `${h}-hlCss`,
16
23
  prettier: `${h}-prettier`,
@@ -23,10 +30,10 @@ const P = {
23
30
  katexjs: `${h}-katex`,
24
31
  katexcss: `${h}-katexCss`,
25
32
  echarts: `${h}-echarts`
26
- }, ce = (e, t) => {
27
- b.emit(e, Ve, t);
28
- }, tn = (e, t, a) => {
29
- const { editorId: o } = a, n = ie({
33
+ }, he = (e, t) => {
34
+ b.emit(e, Ge, t);
35
+ }, mn = (e, t, a) => {
36
+ const { editorId: o } = a, n = me({
30
37
  // 是否已编译成html
31
38
  buildFinished: !1,
32
39
  // 存储当前最新的html
@@ -37,55 +44,55 @@ const P = {
37
44
  () => {
38
45
  n.buildFinished = !1;
39
46
  }
40
- ), M(() => {
47
+ ), L(() => {
41
48
  b.on(o, {
42
- name: Y,
43
- callback(d) {
44
- n.buildFinished = !0, n.html = d;
49
+ name: ne,
50
+ callback(c) {
51
+ n.buildFinished = !0, n.html = c;
45
52
  }
46
53
  }), b.on(o, {
47
- name: Se,
54
+ name: Re,
48
55
  callback() {
49
- const d = new Promise((s) => {
56
+ const c = new Promise((i) => {
50
57
  if (n.buildFinished)
51
- s(n.html);
58
+ i(n.html);
52
59
  else {
53
- const c = (u) => {
54
- s(u), b.remove(o, Y, c);
60
+ const d = (u) => {
61
+ i(u), b.remove(o, ne, d);
55
62
  };
56
63
  b.on(o, {
57
- name: Y,
58
- callback: c
64
+ name: ne,
65
+ callback: d
59
66
  });
60
67
  }
61
68
  });
62
- e.onSave ? e.onSave(e.modelValue, d) : t.emit("onSave", e.modelValue, d);
69
+ e.onSave ? e.onSave(e.modelValue, c) : t.emit("onSave", e.modelValue, c);
63
70
  }
64
71
  });
65
72
  });
66
- }, Ie = (e, {
73
+ }, Le = (e, {
67
74
  editorId: t,
68
75
  rootRef: a,
69
76
  setting: o
70
77
  }) => {
71
- const n = L.editorExtensions.highlight, d = L.editorExtensionsAttrs.highlight;
72
- T("editorId", t), T("rootRef", a), T(
78
+ const n = P.editorExtensions.highlight, c = P.editorExtensionsAttrs.highlight;
79
+ I("editorId", t), I("rootRef", a), I(
73
80
  "theme",
74
- A(() => e.theme)
75
- ), T(
81
+ F(() => e.theme)
82
+ ), I(
76
83
  "language",
77
- A(() => e.language)
78
- ), T(
84
+ F(() => e.language)
85
+ ), I(
79
86
  "highlight",
80
- A(() => {
81
- const { js: c } = n, u = {
82
- ...me,
87
+ F(() => {
88
+ const { js: d } = n, u = {
89
+ ...xe,
83
90
  ...n.css
84
- }, { js: l, css: i = {} } = d || {}, r = e.codeStyleReverse && e.codeStyleReverseList.includes(e.previewTheme) ? "dark" : e.theme, m = u[e.codeTheme] ? u[e.codeTheme][r] : me.atom[r], f = u[e.codeTheme] && i[e.codeTheme] ? i[e.codeTheme][r] : i.atom ? i.atom[r] : {};
91
+ }, { js: r, css: l = {} } = c || {}, s = e.codeStyleReverse && e.codeStyleReverseList.includes(e.previewTheme) ? "dark" : e.theme, m = u[e.codeTheme] ? u[e.codeTheme][s] : xe.atom[s], f = u[e.codeTheme] && l[e.codeTheme] ? l[e.codeTheme][s] : l.atom ? l.atom[s] : {};
85
92
  return {
86
93
  js: {
87
- src: c,
88
- ...l
94
+ src: d,
95
+ ...r
89
96
  },
90
97
  css: {
91
98
  href: m,
@@ -93,26 +100,26 @@ const P = {
93
100
  }
94
101
  };
95
102
  })
96
- ), T("showCodeRowNumber", e.showCodeRowNumber);
97
- const s = A(() => {
98
- const c = {
99
- ...fe,
100
- ...L.editorConfig.languageUserDefined
103
+ ), I("showCodeRowNumber", e.showCodeRowNumber);
104
+ const i = F(() => {
105
+ const d = {
106
+ ...Ie,
107
+ ...P.editorConfig.languageUserDefined
101
108
  };
102
- return Oe(
103
- Ne(fe["en-US"]),
104
- c[e.language] || {}
109
+ return Je(
110
+ Xe(Ie["en-US"]),
111
+ d[e.language] || {}
105
112
  );
106
113
  });
107
- return T("usedLanguageText", s), T(
114
+ return I("usedLanguageText", i), I(
108
115
  "previewTheme",
109
- A(() => e.previewTheme)
110
- ), T(
116
+ F(() => e.previewTheme)
117
+ ), I(
111
118
  "customIcon",
112
- A(() => e.customIcon)
113
- ), T(
119
+ F(() => e.customIcon)
120
+ ), I(
114
121
  "setting",
115
- A(() => o ? {
122
+ F(() => o ? {
116
123
  // setting是reactive,不转化是可以直接赋值的
117
124
  ...o
118
125
  } : {
@@ -123,80 +130,80 @@ const P = {
123
130
  fullscreen: !1
124
131
  })
125
132
  ), { editorId: t };
126
- }, nn = (e, t) => (T("tabWidth", e.tabWidth), T(
133
+ }, fn = (e, t) => (I("tabWidth", e.tabWidth), I(
127
134
  "disabled",
128
- A(() => e.disabled)
129
- ), T(
135
+ F(() => e.disabled)
136
+ ), I(
130
137
  "contentDisabled",
131
- A(() => e.disabled || e.readOnly)
132
- ), T(
138
+ F(() => e.disabled || e.readOnly)
139
+ ), I(
133
140
  "showToolbarName",
134
- A(() => e.showToolbarName)
135
- ), T("noUploadImg", e.noUploadImg), T(
141
+ F(() => e.showToolbarName)
142
+ ), I("noUploadImg", e.noUploadImg), I(
136
143
  "tableShape",
137
- A(() => e.tableShape)
138
- ), T("noPrettier", e.noPrettier), T(
144
+ F(() => e.tableShape)
145
+ ), I("noPrettier", e.noPrettier), I(
139
146
  "codeTheme",
140
- A(() => e.codeTheme)
141
- ), T("updateSetting", t.updateSetting), T(
147
+ F(() => e.codeTheme)
148
+ ), I("updateSetting", t.updateSetting), I(
142
149
  "catalogVisible",
143
- A(() => t.catalogVisible.value)
144
- ), T("defToolbars", t.defToolbars), T(
150
+ F(() => t.catalogVisible.value)
151
+ ), I("defToolbars", t.defToolbars), I(
145
152
  "floatingToolbars",
146
- A(() => e.floatingToolbars)
147
- ), Ie(e, t)), on = (e) => {
148
- const { noPrettier: t, noUploadImg: a } = e, { editorExtensions: o, editorExtensionsAttrs: n } = L, d = t || o.prettier.prettierInstance, s = t || o.prettier.parserMarkdownInstance, c = a || o.cropper.instance;
149
- M(() => {
150
- if (!c) {
151
- const { js: u = {}, css: l = {} } = n.cropper || {};
153
+ F(() => e.floatingToolbars)
154
+ ), Le(e, t)), hn = (e) => {
155
+ const { noPrettier: t, noUploadImg: a } = e, { editorExtensions: o, editorExtensionsAttrs: n } = P, c = t || o.prettier.prettierInstance, i = t || o.prettier.parserMarkdownInstance, d = a || o.cropper.instance;
156
+ L(() => {
157
+ if (!d) {
158
+ const { js: u = {}, css: r = {} } = n.cropper || {};
152
159
  O("link", {
153
- ...l,
160
+ ...r,
154
161
  rel: "stylesheet",
155
162
  href: o.cropper.css,
156
- id: P.croppercss
163
+ id: M.croppercss
157
164
  }), O("script", {
158
165
  ...u,
159
166
  src: o.cropper.js,
160
- id: P.cropperjs
167
+ id: M.cropperjs
161
168
  });
162
169
  }
163
- if (!d) {
170
+ if (!c) {
164
171
  const { standaloneJs: u = {} } = n.prettier || {};
165
172
  O("script", {
166
173
  ...u,
167
174
  src: o.prettier.standaloneJs,
168
- id: P.prettier
175
+ id: M.prettier
169
176
  });
170
177
  }
171
- if (!s) {
178
+ if (!i) {
172
179
  const { parserMarkdownJs: u = {} } = n.prettier || {};
173
180
  O("script", {
174
181
  ...u,
175
182
  src: o.prettier.parserMarkdownJs,
176
- id: P.prettierMD
183
+ id: M.prettierMD
177
184
  });
178
185
  }
179
186
  });
180
- }, an = (e, t, a) => {
187
+ }, pn = (e, t, a) => {
181
188
  const { editorId: o } = a;
182
- M(() => {
189
+ L(() => {
183
190
  b.on(o, {
184
- name: ee,
191
+ name: re,
185
192
  callback: (n) => {
186
193
  e.onError?.(n), t.emit("onError", n);
187
194
  }
188
195
  });
189
196
  });
190
- }, rn = (e, t, a) => {
191
- const { editorId: o } = a, n = ie({
197
+ }, gn = (e, t, a) => {
198
+ const { editorId: o } = a, n = me({
192
199
  pageFullscreen: e.pageFullscreen,
193
200
  fullscreen: !1,
194
201
  preview: e.preview,
195
202
  htmlPreview: e.preview ? !1 : e.htmlPreview,
196
203
  previewOnly: !1
197
- }), d = ie({ ...n }), s = (l, i) => {
198
- const r = i === void 0 ? !n[l] : i;
199
- switch (l) {
204
+ }), c = me({ ...n }), i = (r, l) => {
205
+ const s = l === void 0 ? !n[r] : l;
206
+ switch (r) {
200
207
  case "preview": {
201
208
  n.htmlPreview = !1, n.previewOnly = !1;
202
209
  break;
@@ -206,261 +213,261 @@ const P = {
206
213
  break;
207
214
  }
208
215
  case "previewOnly": {
209
- r ? !n.preview && !n.htmlPreview && (n.preview = !0) : (d.preview || (n.preview = !1), d.htmlPreview || (n.htmlPreview = !1));
216
+ s ? !n.preview && !n.htmlPreview && (n.preview = !0) : (c.preview || (n.preview = !1), c.htmlPreview || (n.htmlPreview = !1));
210
217
  break;
211
218
  }
212
219
  }
213
- d[l] = r, n[l] = r;
220
+ c[r] = s, n[r] = s;
214
221
  };
215
- let c = "";
222
+ let d = "";
216
223
  const u = () => {
217
- n.pageFullscreen || n.fullscreen ? document.body.style.overflow = "hidden" : document.body.style.overflow = c;
224
+ n.pageFullscreen || n.fullscreen ? document.body.style.overflow = "hidden" : document.body.style.overflow = d;
218
225
  };
219
- return x(() => [n.pageFullscreen, n.fullscreen], u), M(() => {
226
+ return x(() => [n.pageFullscreen, n.fullscreen], u), L(() => {
220
227
  b.on(o, {
221
- name: Ge,
222
- callback(l, i) {
223
- const r = (m) => {
224
- ce(o, {
228
+ name: Ue,
229
+ callback(r, l) {
230
+ const s = (m) => {
231
+ he(o, {
225
232
  direct: "image",
226
233
  params: {
227
234
  desc: "",
228
235
  urls: m
229
236
  }
230
- }), i?.();
237
+ }), l?.();
231
238
  };
232
- e.onUploadImg ? e.onUploadImg(l, r) : t.emit("onUploadImg", l, r);
239
+ e.onUploadImg ? e.onUploadImg(r, s) : t.emit("onUploadImg", r, s);
233
240
  }
234
- }), c = document.body.style.overflow, u();
235
- }), [n, s];
236
- }, ln = (e, t) => {
237
- const { editorId: a } = t, o = z(!1);
238
- return M(() => {
241
+ }), d = document.body.style.overflow, u();
242
+ }), [n, i];
243
+ }, vn = (e, t) => {
244
+ const { editorId: a } = t, o = U(!1);
245
+ return L(() => {
239
246
  b.on(a, {
240
- name: Te,
247
+ name: Fe,
241
248
  callback: (n) => {
242
249
  n === void 0 ? o.value = !o.value : o.value = n;
243
250
  }
244
251
  });
245
252
  }), o;
246
- }, sn = (e, t, a) => {
247
- const { editorId: o, catalogVisible: n, setting: d, updateSetting: s, codeRef: c } = a;
253
+ }, yn = (e, t, a) => {
254
+ const { editorId: o, catalogVisible: n, setting: c, updateSetting: i, codeRef: d } = a;
248
255
  x(
249
- () => d.pageFullscreen,
250
- (l) => {
251
- b.emit(o, he, l);
256
+ () => c.pageFullscreen,
257
+ (r) => {
258
+ b.emit(o, ye, r);
252
259
  }
253
260
  ), x(
254
- () => d.fullscreen,
255
- (l) => {
256
- b.emit(o, pe, l);
261
+ () => c.fullscreen,
262
+ (r) => {
263
+ b.emit(o, be, r);
257
264
  }
258
265
  ), x(
259
- () => d.preview,
260
- (l) => {
261
- b.emit(o, ge, l);
266
+ () => c.preview,
267
+ (r) => {
268
+ b.emit(o, Ce, r);
262
269
  }
263
270
  ), x(
264
- () => d.previewOnly,
265
- (l) => {
266
- b.emit(o, ve, l);
271
+ () => c.previewOnly,
272
+ (r) => {
273
+ b.emit(o, we, r);
267
274
  }
268
275
  ), x(
269
- () => d.htmlPreview,
270
- (l) => {
271
- b.emit(o, ye, l);
276
+ () => c.htmlPreview,
277
+ (r) => {
278
+ b.emit(o, $e, r);
272
279
  }
273
- ), x(n, (l) => {
274
- b.emit(o, be, l);
280
+ ), x(n, (r) => {
281
+ b.emit(o, Ee, r);
275
282
  });
276
283
  const u = {
277
- on(l, i) {
278
- switch (l) {
284
+ on(r, l) {
285
+ switch (r) {
279
286
  case "pageFullscreen": {
280
287
  b.on(o, {
281
- name: he,
282
- callback(r) {
283
- i(r);
288
+ name: ye,
289
+ callback(s) {
290
+ l(s);
284
291
  }
285
292
  });
286
293
  break;
287
294
  }
288
295
  case "fullscreen": {
289
296
  b.on(o, {
290
- name: pe,
291
- callback(r) {
292
- i(r);
297
+ name: be,
298
+ callback(s) {
299
+ l(s);
293
300
  }
294
301
  });
295
302
  break;
296
303
  }
297
304
  case "preview": {
298
305
  b.on(o, {
299
- name: ge,
300
- callback(r) {
301
- i(r);
306
+ name: Ce,
307
+ callback(s) {
308
+ l(s);
302
309
  }
303
310
  });
304
311
  break;
305
312
  }
306
313
  case "previewOnly": {
307
314
  b.on(o, {
308
- name: ve,
309
- callback(r) {
310
- i(r);
315
+ name: we,
316
+ callback(s) {
317
+ l(s);
311
318
  }
312
319
  });
313
320
  break;
314
321
  }
315
322
  case "htmlPreview": {
316
323
  b.on(o, {
317
- name: ye,
318
- callback(r) {
319
- i(r);
324
+ name: $e,
325
+ callback(s) {
326
+ l(s);
320
327
  }
321
328
  });
322
329
  break;
323
330
  }
324
331
  case "catalog": {
325
332
  b.on(o, {
326
- name: be,
327
- callback(r) {
328
- i(r);
333
+ name: Ee,
334
+ callback(s) {
335
+ l(s);
329
336
  }
330
337
  });
331
338
  break;
332
339
  }
333
340
  }
334
341
  },
335
- togglePageFullscreen(l) {
336
- s("pageFullscreen", l);
342
+ togglePageFullscreen(r) {
343
+ i("pageFullscreen", r);
337
344
  },
338
- toggleFullscreen(l) {
339
- b.emit(o, ze, l);
345
+ toggleFullscreen(r) {
346
+ b.emit(o, qe, r);
340
347
  },
341
- togglePreview(l) {
342
- s("preview", l);
348
+ togglePreview(r) {
349
+ i("preview", r);
343
350
  },
344
- togglePreviewOnly(l) {
345
- s("previewOnly", l);
351
+ togglePreviewOnly(r) {
352
+ i("previewOnly", r);
346
353
  },
347
- toggleHtmlPreview(l) {
348
- s("htmlPreview", l);
354
+ toggleHtmlPreview(r) {
355
+ i("htmlPreview", r);
349
356
  },
350
- toggleCatalog(l) {
351
- b.emit(o, Te, l);
357
+ toggleCatalog(r) {
358
+ b.emit(o, Fe, r);
352
359
  },
353
360
  triggerSave() {
354
- b.emit(o, Se);
361
+ b.emit(o, Re);
355
362
  },
356
- insert(l) {
357
- ce(o, {
363
+ insert(r) {
364
+ he(o, {
358
365
  direct: "universal",
359
- params: { generate: l },
366
+ params: { generate: r },
360
367
  source: "programmatic"
361
368
  });
362
369
  },
363
- focus(l) {
364
- c.value?.focus(l);
370
+ focus(r) {
371
+ d.value?.focus(r);
365
372
  },
366
373
  rerender() {
367
- b.emit(o, ue);
374
+ b.emit(o, ge);
368
375
  },
369
376
  getSelectedText() {
370
- return c.value?.getSelectedText();
377
+ return d.value?.getSelectedText();
371
378
  },
372
379
  resetHistory() {
373
- c.value?.resetHistory();
380
+ d.value?.resetHistory();
374
381
  },
375
- domEventHandlers(l) {
376
- b.emit(o, Ue, l);
382
+ domEventHandlers(r) {
383
+ b.emit(o, We, r);
377
384
  },
378
- execCommand(l) {
379
- ce(o, { direct: l, source: "programmatic" });
385
+ execCommand(r) {
386
+ he(o, { direct: r, source: "programmatic" });
380
387
  },
381
388
  getEditorView() {
382
- return c.value?.getEditorView();
389
+ return d.value?.getEditorView();
383
390
  }
384
391
  };
385
392
  t.expose(u);
386
- }, rt = (e) => {
387
- const t = Me();
393
+ }, ht = (e) => {
394
+ const t = je();
388
395
  return e.id || e.editorId || `${h}-${t}`;
389
- }, lt = (e, t, a) => {
390
- const o = $("editorId"), n = $("rootRef"), d = $("usedLanguageText"), s = $("setting"), c = () => {
391
- n.value.querySelectorAll(`#${o} .${h}-preview .${h}-code`).forEach((i) => {
392
- let r = -1;
393
- const m = i.querySelector(
396
+ }, pt = (e, t, a) => {
397
+ const o = $("editorId"), n = $("rootRef"), c = $("usedLanguageText"), i = $("setting"), d = () => {
398
+ n.value.querySelectorAll(`#${o} .${h}-preview .${h}-code`).forEach((l) => {
399
+ let s = -1;
400
+ const m = l.querySelector(
394
401
  `.${h}-copy-button:not([data-processed])`
395
402
  );
396
403
  m && (m.onclick = (f) => {
397
- f.preventDefault(), clearTimeout(r);
398
- const g = (i.querySelector("input:checked + pre code") || i.querySelector("pre code")).textContent, { text: v, successTips: E, failTips: y } = d.value.copyCode;
399
- let w = E;
400
- Ye(e.formatCopiedText(g || "")).catch(() => {
401
- w = y;
404
+ f.preventDefault(), clearTimeout(s);
405
+ const g = (l.querySelector("input:checked + pre code") || l.querySelector("pre code")).textContent, { text: v, successTips: E, failTips: y } = c.value.copyCode;
406
+ let C = E;
407
+ rt(e.formatCopiedText(g || "")).catch(() => {
408
+ C = y;
402
409
  }).finally(() => {
403
- m.dataset.isIcon ? m.dataset.tips = w : m.textContent = w, r = window.setTimeout(() => {
410
+ m.dataset.isIcon ? m.dataset.tips = C : m.textContent = C, s = window.setTimeout(() => {
404
411
  m.dataset.isIcon ? m.dataset.tips = v : m.textContent = v;
405
412
  }, 1500);
406
413
  });
407
414
  }, m.setAttribute("data-processed", "true"));
408
415
  });
409
416
  }, u = () => {
410
- W(c);
411
- }, l = (i) => {
412
- i && W(c);
417
+ W(d);
418
+ }, r = (l) => {
419
+ l && W(d);
413
420
  };
414
- x([t, a], u), x(() => s.value.preview, l), x(() => s.value.htmlPreview, l), M(c);
415
- }, it = (e) => {
416
- const t = $("editorId"), a = $("theme"), o = $("rootRef"), { editorExtensions: n, editorExtensionsAttrs: d, echartsConfig: s } = L;
417
- let c = n.echarts.instance;
418
- const u = te(-1), l = () => {
419
- !e.noEcharts && c && (u.value = u.value + 1);
421
+ x([t, a], u), x(() => i.value.preview, r), x(() => i.value.htmlPreview, r), L(d);
422
+ }, gt = (e) => {
423
+ const t = $("editorId"), a = $("theme"), o = $("rootRef"), { editorExtensions: n, editorExtensionsAttrs: c, echartsConfig: i } = P;
424
+ let d = n.echarts.instance;
425
+ const u = se(-1), r = () => {
426
+ !e.noEcharts && d && (u.value = u.value + 1);
420
427
  };
421
428
  x(
422
429
  () => a.value,
423
430
  () => {
424
- l();
431
+ r();
425
432
  }
426
- ), M(() => {
427
- if (e.noEcharts || c)
433
+ ), L(() => {
434
+ if (e.noEcharts || d)
428
435
  return;
429
436
  const g = n.echarts.js;
430
437
  O(
431
438
  "script",
432
439
  {
433
- ...d.echarts?.js,
440
+ ...c.echarts?.js,
434
441
  src: g,
435
- id: P.echarts,
442
+ id: M.echarts,
436
443
  onload() {
437
- c = window.echarts, l();
444
+ d = window.echarts, r();
438
445
  }
439
446
  },
440
447
  "echarts"
441
448
  );
442
449
  });
443
- let i = [], r = [], m = [];
450
+ let l = [], s = [], m = [];
444
451
  const f = (g = !1) => {
445
- if (!i.length) {
446
- g && (r.forEach((w) => {
447
- w.dispose?.();
448
- }), m.forEach((w) => {
449
- w.disconnect?.();
450
- }), r = [], m = []);
452
+ if (!l.length) {
453
+ g && (s.forEach((C) => {
454
+ C.dispose?.();
455
+ }), m.forEach((C) => {
456
+ C.disconnect?.();
457
+ }), s = [], m = []);
451
458
  return;
452
459
  }
453
460
  const v = [], E = [], y = [];
454
- i.forEach((w, S) => {
455
- const C = r[S], k = m[S];
456
- if (g || !w || !w.isConnected || (o?.value ? !o.value.contains(w) : !1)) {
457
- C?.dispose?.(), k?.disconnect?.();
461
+ l.forEach((C, T) => {
462
+ const w = s[T], k = m[T];
463
+ if (g || !C || !C.isConnected || (o?.value ? !o.value.contains(C) : !1)) {
464
+ w?.dispose?.(), k?.disconnect?.();
458
465
  return;
459
466
  }
460
- v.push(w), C && E.push(C), k && y.push(k);
461
- }), i = v, r = E, m = y;
467
+ v.push(C), w && E.push(w), k && y.push(k);
468
+ }), l = v, s = E, m = y;
462
469
  }, p = () => {
463
- if (f(), !e.noEcharts && c) {
470
+ if (f(), !e.noEcharts && d) {
464
471
  const g = o.value;
465
472
  if (!g) return;
466
473
  Array.from(
@@ -474,14 +481,14 @@ const P = {
474
481
  const y = n.echarts.parseOption(E.innerText, {
475
482
  editorId: t,
476
483
  element: E
477
- }), w = s(y), S = c.init(E, a.value);
478
- S.setOption(w), E.setAttribute("data-processed", ""), i.push(E), r.push(S);
479
- const C = new ResizeObserver(() => {
480
- S.resize();
484
+ }), C = i(y), T = d.init(E, a.value);
485
+ T.setOption(C), E.setAttribute("data-processed", ""), l.push(E), s.push(T);
486
+ const w = new ResizeObserver(() => {
487
+ T.resize();
481
488
  });
482
- C.observe(E), m.push(C);
489
+ w.observe(E), m.push(w);
483
490
  } catch (y) {
484
- b.emit(t, ee, {
491
+ b.emit(t, re, {
485
492
  name: "echarts",
486
493
  message: y?.message,
487
494
  error: y
@@ -490,21 +497,21 @@ const P = {
490
497
  });
491
498
  }
492
499
  };
493
- return ne(() => {
500
+ return le(() => {
494
501
  f(!0);
495
502
  }), { reRenderEcharts: u, replaceEcharts: p };
496
- }, st = (e) => {
497
- const t = $("highlight"), a = te(L.editorExtensions.highlight.instance);
498
- return M(() => {
503
+ }, vt = (e) => {
504
+ const t = $("highlight"), a = se(P.editorExtensions.highlight.instance);
505
+ return L(() => {
499
506
  e.noHighlight || a.value || (O("link", {
500
507
  ...t.value.css,
501
508
  rel: "stylesheet",
502
- id: P.hlcss
509
+ id: M.hlcss
503
510
  }), O(
504
511
  "script",
505
512
  {
506
513
  ...t.value.js,
507
- id: P.hljs,
514
+ id: M.hljs,
508
515
  onload() {
509
516
  a.value = window.hljs;
510
517
  }
@@ -514,25 +521,25 @@ const P = {
514
521
  }), x(
515
522
  () => t.value.css,
516
523
  () => {
517
- e.noHighlight || L.editorExtensions.highlight.instance || Ke("link", {
524
+ e.noHighlight || P.editorExtensions.highlight.instance || tt("link", {
518
525
  ...t.value.css,
519
526
  rel: "stylesheet",
520
- id: P.hlcss
527
+ id: M.hlcss
521
528
  });
522
529
  }
523
530
  ), a;
524
- }, ct = (e) => {
525
- const t = te(L.editorExtensions.katex.instance);
526
- return M(() => {
531
+ }, yt = (e) => {
532
+ const t = se(P.editorExtensions.katex.instance);
533
+ return L(() => {
527
534
  if (e.noKatex || t.value)
528
535
  return;
529
- const { editorExtensions: a, editorExtensionsAttrs: o } = L;
536
+ const { editorExtensions: a, editorExtensionsAttrs: o } = P;
530
537
  O(
531
538
  "script",
532
539
  {
533
540
  ...o.katex?.js,
534
541
  src: a.katex.js,
535
- id: P.katexjs,
542
+ id: M.katexjs,
536
543
  onload() {
537
544
  t.value = window.katex;
538
545
  }
@@ -542,11 +549,11 @@ const P = {
542
549
  ...o.katex?.css,
543
550
  rel: "stylesheet",
544
551
  href: a.katex.css,
545
- id: P.katexcss
552
+ id: M.katexcss
546
553
  });
547
554
  }), t;
548
555
  };
549
- class dt {
556
+ class bt {
550
557
  constructor(t) {
551
558
  this.options = t;
552
559
  }
@@ -585,16 +592,16 @@ class dt {
585
592
  this.cache.clear();
586
593
  }
587
594
  }
588
- const Q = new dt({
595
+ const oe = new bt({
589
596
  max: 1e3,
590
597
  // 缓存10分钟
591
598
  ttl: 6e5
592
- }), ut = (e) => {
593
- const t = $("editorId"), a = $("theme"), o = $("rootRef"), { editorExtensions: n, editorExtensionsAttrs: d, mermaidConfig: s } = L;
594
- let c = n.mermaid.instance;
595
- const u = te(-1), l = () => {
596
- if (!e.noMermaid && c) {
597
- const r = a.value === "dark" ? {
599
+ }), Ct = (e) => {
600
+ const t = $("editorId"), a = $("theme"), o = $("rootRef"), { editorExtensions: n, editorExtensionsAttrs: c, mermaidConfig: i } = P;
601
+ let d = n.mermaid.instance;
602
+ const u = se(-1), r = () => {
603
+ if (!e.noMermaid && d) {
604
+ const s = a.value === "dark" ? {
598
605
  startOnLoad: !1,
599
606
  theme: "dark"
600
607
  } : {
@@ -613,31 +620,31 @@ const Q = new dt({
613
620
  clusterBorder: "#b7c0cc"
614
621
  }
615
622
  };
616
- c.initialize(s(r)), u.value = u.value + 1;
623
+ d.initialize(i(s)), u.value = u.value + 1;
617
624
  }
618
625
  };
619
626
  return x(
620
627
  () => a.value,
621
628
  () => {
622
- Q.clear(), l();
629
+ oe.clear(), r();
623
630
  }
624
- ), M(() => {
625
- if (e.noMermaid || c)
631
+ ), L(() => {
632
+ if (e.noMermaid || d)
626
633
  return;
627
- const r = n.mermaid.js;
628
- /\.mjs/.test(r) ? (O("link", {
629
- ...d.mermaid?.js,
634
+ const s = n.mermaid.js;
635
+ /\.mjs/.test(s) ? (O("link", {
636
+ ...c.mermaid?.js,
630
637
  rel: "modulepreload",
631
- href: r,
632
- id: P.mermaidM
638
+ href: s,
639
+ id: M.mermaidM
633
640
  }), import(
634
641
  /* @vite-ignore */
635
642
  /* webpackIgnore: true */
636
- r
643
+ s
637
644
  ).then((m) => {
638
- c = m.default, l();
645
+ d = m.default, r();
639
646
  }).catch((m) => {
640
- b.emit(t, ee, {
647
+ b.emit(t, re, {
641
648
  name: "mermaid",
642
649
  message: `Failed to load mermaid module: ${m.message}`,
643
650
  error: m
@@ -645,20 +652,20 @@ const Q = new dt({
645
652
  })) : O(
646
653
  "script",
647
654
  {
648
- ...d.mermaid?.js,
649
- src: r,
650
- id: P.mermaid,
655
+ ...c.mermaid?.js,
656
+ src: s,
657
+ id: M.mermaid,
651
658
  onload() {
652
- c = window.mermaid, l();
659
+ d = window.mermaid, r();
653
660
  }
654
661
  },
655
662
  "mermaid"
656
663
  );
657
664
  }), { reRenderRef: u, replaceMermaid: async () => {
658
- if (!e.noMermaid && c) {
659
- const r = o.value;
660
- if (!r) return;
661
- const m = r.querySelectorAll(
665
+ if (!e.noMermaid && d) {
666
+ const s = o.value;
667
+ if (!s) return;
668
+ const m = s.querySelectorAll(
662
669
  `div.${h}-mermaid`
663
670
  );
664
671
  if (m.length === 0) return;
@@ -669,20 +676,20 @@ const Q = new dt({
669
676
  Array.from(m).map((v) => (async (y) => {
670
677
  if (y.dataset.closed === "false")
671
678
  return !1;
672
- const w = y.innerText;
673
- let S = Q.get(w);
674
- if (!S) {
675
- const C = se();
679
+ const C = y.innerText;
680
+ let T = oe.get(C);
681
+ if (!T) {
682
+ const w = fe();
676
683
  let k = { svg: "" };
677
684
  try {
678
- k = await c.render(C, w, f), S = await e.sanitizeMermaid(k.svg);
679
- const I = document.createElement("p");
680
- I.className = `${h}-mermaid`, I.setAttribute("data-processed", ""), I.setAttribute("data-content", w), I.innerHTML = S, I.children[0]?.removeAttribute("height"), Q.set(w, I.innerHTML), y.dataset.line !== void 0 && (I.dataset.line = y.dataset.line), y.replaceWith(I);
681
- } catch (I) {
682
- b.emit(t, ee, {
685
+ k = await d.render(w, C, f), T = await e.sanitizeMermaid(k.svg);
686
+ const S = document.createElement("p");
687
+ S.className = `${h}-mermaid`, S.setAttribute("data-processed", ""), S.setAttribute("data-content", C), S.innerHTML = T, S.children[0]?.removeAttribute("height"), oe.set(C, S.innerHTML), y.dataset.line !== void 0 && (S.dataset.line = y.dataset.line), y.replaceWith(S);
688
+ } catch (S) {
689
+ b.emit(t, re, {
683
690
  name: "mermaid",
684
- message: I.message,
685
- error: I
691
+ message: S.message,
692
+ error: S
686
693
  });
687
694
  }
688
695
  }
@@ -693,193 +700,243 @@ const Q = new dt({
693
700
  }
694
701
  }
695
702
  } };
696
- }, mt = (e, t) => {
703
+ }, wt = (e, t) => {
697
704
  t = t || {};
698
- const a = 3, o = t.marker || "!", n = o.charCodeAt(0), d = o.length;
699
- let s = "", c = "";
700
- const u = (i, r, m, f, p) => {
701
- const g = i[r];
702
- return g.type === "admonition_open" ? i[r].attrPush([
705
+ const a = 3, o = t.marker || "!", n = o.charCodeAt(0), c = o.length;
706
+ let i = "", d = "";
707
+ const u = (l, s, m, f, p) => {
708
+ const g = l[s];
709
+ return g.type === "admonition_open" ? l[s].attrPush([
703
710
  "class",
704
711
  `${h}-admonition ${h}-admonition-${g.info}`
705
- ]) : g.type === "admonition_title_open" && i[r].attrPush(["class", `${h}-admonition-title`]), p.renderToken(i, r, m);
706
- }, l = (i) => {
707
- const r = i.trim().split(" ", 2);
708
- c = "", s = r[0], r.length > 1 && (c = i.substring(s.length + 2));
712
+ ]) : g.type === "admonition_title_open" && l[s].attrPush(["class", `${h}-admonition-title`]), p.renderToken(l, s, m);
713
+ }, r = (l) => {
714
+ const s = l.trim().split(" ", 2);
715
+ d = "", i = s[0], s.length > 1 && (d = l.substring(i.length + 2));
709
716
  };
710
717
  e.block.ruler.before(
711
718
  "code",
712
719
  "admonition",
713
- (i, r, m, f) => {
714
- let p, g, v, E = !1, y = i.bMarks[r] + i.tShift[r], w = i.eMarks[r];
715
- if (n !== i.src.charCodeAt(y))
720
+ (l, s, m, f) => {
721
+ let p, g, v, E = !1, y = l.bMarks[s] + l.tShift[s], C = l.eMarks[s];
722
+ if (n !== l.src.charCodeAt(y))
716
723
  return !1;
717
- for (p = y + 1; p <= w && o[(p - y) % d] === i.src[p]; p++)
724
+ for (p = y + 1; p <= C && o[(p - y) % c] === l.src[p]; p++)
718
725
  ;
719
- const S = Math.floor((p - y) / d);
720
- if (S !== a)
726
+ const T = Math.floor((p - y) / c);
727
+ if (T !== a)
721
728
  return !1;
722
- p -= (p - y) % d;
723
- const C = i.src.slice(y, p), k = i.src.slice(p, w);
724
- if (l(k), f)
729
+ p -= (p - y) % c;
730
+ const w = l.src.slice(y, p), k = l.src.slice(p, C);
731
+ if (r(k), f)
725
732
  return !0;
726
- for (g = r; g++, !(g >= m || (y = i.bMarks[g] + i.tShift[g], w = i.eMarks[g], y < w && i.sCount[g] < i.blkIndent)); )
727
- if (n === i.src.charCodeAt(y) && !(i.sCount[g] - i.blkIndent >= 4)) {
728
- for (p = y + 1; p <= w && o[(p - y) % d] === i.src[p]; p++)
733
+ for (g = s; g++, !(g >= m || (y = l.bMarks[g] + l.tShift[g], C = l.eMarks[g], y < C && l.sCount[g] < l.blkIndent)); )
734
+ if (n === l.src.charCodeAt(y) && !(l.sCount[g] - l.blkIndent >= 4)) {
735
+ for (p = y + 1; p <= C && o[(p - y) % c] === l.src[p]; p++)
729
736
  ;
730
- if (!(Math.floor((p - y) / d) < S) && (p -= (p - y) % d, p = i.skipSpaces(p), !(p < w))) {
737
+ if (!(Math.floor((p - y) / c) < T) && (p -= (p - y) % c, p = l.skipSpaces(p), !(p < C))) {
731
738
  E = !0;
732
739
  break;
733
740
  }
734
741
  }
735
- const I = i.parentType, R = i.lineMax;
736
- return i.parentType = "root", i.lineMax = g, v = i.push("admonition_open", "div", 1), v.markup = C, v.block = !0, v.info = s, v.map = [r, g], c && (v = i.push("admonition_title_open", "p", 1), v.markup = C + " " + s, v.map = [r, g], v = i.push("inline", "", 0), v.content = c, v.map = [r, i.line - 1], v.children = [], v = i.push("admonition_title_close", "p", -1), v.markup = C + " " + s), i.md.block.tokenize(i, r + 1, g), v = i.push("admonition_close", "div", -1), v.markup = i.src.slice(y, p), v.block = !0, i.parentType = I, i.lineMax = R, i.line = g + (E ? 1 : 0), !0;
742
+ const S = l.parentType, R = l.lineMax;
743
+ return l.parentType = "root", l.lineMax = g, v = l.push("admonition_open", "div", 1), v.markup = w, v.block = !0, v.info = i, v.map = [s, g], d && (v = l.push("admonition_title_open", "p", 1), v.markup = w + " " + i, v.map = [s, g], v = l.push("inline", "", 0), v.content = d, v.map = [s, l.line - 1], v.children = [], v = l.push("admonition_title_close", "p", -1), v.markup = w + " " + i), l.md.block.tokenize(l, s + 1, g), v = l.push("admonition_close", "div", -1), v.markup = l.src.slice(y, p), v.block = !0, l.parentType = S, l.lineMax = R, l.line = g + (E ? 1 : 0), !0;
737
744
  },
738
745
  {
739
746
  alt: ["paragraph", "reference", "blockquote", "list"]
740
747
  }
741
748
  ), e.renderer.rules.admonition_open = u, e.renderer.rules.admonition_title_open = u, e.renderer.rules.admonition_title_close = u, e.renderer.rules.admonition_close = u;
742
- }, J = (e, t, a) => `<${e.tag}${a.renderAttrs(e)}>${t}</${e.tag}>`, we = (e, t) => {
749
+ }, $t = /^\s*\d+(?:\s*-\s*\d+)?(?:\s*,\s*\d+(?:\s*-\s*\d+)?)*\s*$/, Et = (e) => {
750
+ const t = e.search(/\s/);
751
+ let a = "", o = !1;
752
+ for (let n = 0; n < e.length; n += 1) {
753
+ const c = e[n];
754
+ if (a) {
755
+ if (o) {
756
+ o = !1;
757
+ continue;
758
+ }
759
+ if (c === "\\") {
760
+ o = !0;
761
+ continue;
762
+ }
763
+ c === a && (a = "");
764
+ continue;
765
+ }
766
+ if (c === '"' || c === "'" || c === "`") {
767
+ a = c;
768
+ continue;
769
+ }
770
+ if (c !== "{")
771
+ continue;
772
+ const i = e.indexOf("}", n + 1);
773
+ if (i === -1)
774
+ break;
775
+ const d = e.slice(n + 1, i);
776
+ if (!$t.test(d))
777
+ continue;
778
+ const u = e[n - 1] || "", r = e[i + 1] || "", l = !r || /\s/.test(r), s = (t === -1 || n < t) && (!u || !/[\s="'`]/.test(u)) && l, m = (!u || /\s/.test(u)) && l;
779
+ if (s || m)
780
+ return {
781
+ endIndex: i + 1,
782
+ startIndex: n,
783
+ value: d
784
+ };
785
+ }
786
+ return null;
787
+ }, ae = (e, t = "") => {
788
+ const a = `${e}${t ? ` ${t}` : ""}`.trim(), o = Et(a), n = o ? `${a.slice(0, o.startIndex)} ${a.slice(o.endIndex)}`.trim() : a, c = n.search(/\s/), i = c === -1 ? n : n.slice(0, c), d = c === -1 ? "" : n.slice(c).trim(), u = o ? o.value.split(",").reduce((r, l) => {
789
+ const [s, m] = l.split("-").map((p) => Number.parseInt(p.trim(), 10)), f = m ?? s;
790
+ return s > 0 && f >= s && r.push({ start: s, end: f }), r;
791
+ }, []) : [];
792
+ return {
793
+ attrs: d,
794
+ language: i,
795
+ lineHighlightRanges: u
796
+ };
797
+ }, te = (e, t, a) => `<${e.tag}${a.renderAttrs(e)}>${t}</${e.tag}>`, Te = (e, t) => {
743
798
  const a = e.attrs ? e.attrs.slice() : [];
744
799
  return t.forEach((o) => {
745
800
  const n = e.attrIndex(o[0]);
746
801
  n < 0 ? a.push(o) : (a[n] = a[n].slice(), a[n][1] += ` ${o[1]}`);
747
802
  }), a;
748
- }, ft = (e) => Array.from(e).map(
803
+ }, xt = (e) => Array.from(e).map(
749
804
  (t) => /[A-Za-z0-9_-]/.test(t) ? t : `_${t.codePointAt(0).toString(16)}_`
750
- ).join(""), ht = (e, t) => {
751
- const a = e.renderer.rules.fence, o = e.utils.unescapeAll, n = /\[(\w*)(?::([\w ]*))?\]/, d = /::(open|close)/, s = ft(t.editorId), c = (m) => m.info ? o(m.info).trim() : "", u = (m) => {
752
- const f = c(m), [p = null, g = ""] = (n.exec(f) || []).slice(1);
805
+ ).join(""), It = (e, t) => {
806
+ const a = e.renderer.rules.fence, o = e.utils.unescapeAll, n = /\[(\w*)(?::([\w ]*))?\]/, c = /::(open|close)/, i = xt(t.editorId), d = (m) => m.info ? o(m.info).trim() : "", u = (m) => {
807
+ const f = d(m), [p = null, g = ""] = (n.exec(f) || []).slice(1);
753
808
  return [p, g];
754
- }, l = (m) => {
755
- const f = c(m);
756
- return f ? f.split(/(\s+)/g)[0] : "";
757
- }, i = (m) => {
758
- const f = m.info.match(d) || [], p = f[1] === "open" || f[1] !== "close" && t.codeFoldable && m.content.trim().split(`
809
+ }, r = (m) => ae(d(m)).language, l = (m) => {
810
+ const f = m.info.match(c) || [], p = f[1] === "open" || f[1] !== "close" && t.codeFoldable && m.content.trim().split(`
759
811
  `).length < t.autoFoldThreshold, g = f[1] || t.codeFoldable ? "details" : "div", v = f[1] || t.codeFoldable ? "summary" : "div";
760
812
  return { open: p, tagContainer: g, tagHeader: v };
761
- }, r = (m, f, p, g, v) => {
813
+ }, s = (m, f, p, g, v) => {
762
814
  if (m[f].hidden)
763
815
  return "";
764
- const E = t.usedLanguageTextRef.value?.copyCode.text || "", y = t.customIconRef.value.copy, w = e.utils.escapeHtml(E), S = y || w, C = !!y, k = `<span class="${h}-collapse-tips">${Ze("collapse-tips", t.customIconRef.value)}</span>`, [I] = u(m[f]);
765
- if (I === null) {
766
- const { open: F, tagContainer: _, tagHeader: X } = i(m[f]), U = [["class", `${h}-code`]];
767
- F && U.push(["open", ""]);
768
- const Re = {
769
- attrs: we(m[f], U)
816
+ const E = t.usedLanguageTextRef.value?.copyCode.text || "", y = t.customIconRef.value.copy, C = e.utils.escapeHtml(E), T = y || C, w = !!y, k = `<span class="${h}-collapse-tips">${nt("collapse-tips", t.customIconRef.value)}</span>`, [S] = u(m[f]);
817
+ if (S === null) {
818
+ const { open: A, tagContainer: _, tagHeader: Q } = l(m[f]), G = [["class", `${h}-code`]];
819
+ A && G.push(["open", ""]);
820
+ const ee = {
821
+ attrs: Te(m[f], G)
770
822
  };
771
- m[f].info = m[f].info.replace(d, "");
772
- const He = a(m, f, p, g, v);
823
+ m[f].info = m[f].info.replace(c, "");
824
+ const { attrs: Oe, language: Ne } = ae(
825
+ d(m[f])
826
+ ), ve = [Ne, Oe].filter(Boolean).join(" "), Be = a(m, f, p, g, v);
773
827
  return `
774
- <${_} ${v.renderAttrs(Re)}>
775
- <${X} class="${h}-code-head">
828
+ <${_} ${v.renderAttrs(ee)}>
829
+ <${Q} class="${h}-code-head">
776
830
  <div class="${h}-code-flag"><span></span><span></span><span></span></div>
777
831
  <div class="${h}-code-action">
778
- <span class="${h}-code-lang">${e.utils.escapeHtml(m[f].info.trim())}</span>
779
- <span class="${h}-copy-button" data-tips="${w}"${C ? " data-is-icon=true" : ""}>${S}</span>
780
- ${t.extraTools instanceof Function ? t.extraTools({ lang: m[f].info.trim() }) : t.extraTools || ""}
832
+ <span class="${h}-code-lang">${e.utils.escapeHtml(ve)}</span>
833
+ <span class="${h}-copy-button" data-tips="${C}"${w ? " data-is-icon=true" : ""}>${T}</span>
834
+ ${t.extraTools instanceof Function ? t.extraTools({ lang: ve }) : t.extraTools || ""}
781
835
  ${_ === "details" ? k : ""}
782
836
  </div>
783
- </${X}>
784
- ${He}
837
+ </${Q}>
838
+ ${Be}
785
839
  </${_}>
786
840
  `;
787
841
  }
788
- let R, N, V, B, q = "", K = "", Z = "";
789
- const { open: oe, tagContainer: G, tagHeader: H } = i(m[f]), D = [["class", `${h}-code`]];
790
- oe && D.push(["open", ""]);
791
- const ae = {
792
- attrs: we(m[f], D)
842
+ let R, N, D, B, q = "", K = "", Z = "";
843
+ const { open: ie, tagContainer: H, tagHeader: J } = l(m[f]), V = [["class", `${h}-code`]];
844
+ ie && V.push(["open", ""]);
845
+ const X = {
846
+ attrs: Te(m[f], V)
793
847
  };
794
- for (let F = f; F < m.length && (R = m[F], [N, V] = u(R), N === I); F++) {
795
- R.info = R.info.replace(n, "").replace(d, ""), R.hidden = !0;
796
- const _ = `${h}-codetab-${s}-${f}-${F - f}`;
797
- B = F - f > 0 ? "" : "checked", q += `
848
+ for (let A = f; A < m.length && (R = m[A], [N, D] = u(R), N === S); A++) {
849
+ R.info = R.info.replace(n, "").replace(c, ""), R.hidden = !0;
850
+ const _ = `${h}-codetab-${i}-${f}-${A - f}`;
851
+ B = A - f > 0 ? "" : "checked", q += `
798
852
  <li>
799
853
  <input
800
854
  type="radio"
801
- id="label-${h}-codetab-label-1-${s}-${f}-${F - f}"
802
- name="${h}-codetab-label-${s}-${f}"
855
+ id="label-${h}-codetab-label-1-${i}-${f}-${A - f}"
856
+ name="${h}-codetab-label-${i}-${f}"
803
857
  class="${_}"
804
858
  ${B}
805
859
  >
806
860
  <label
807
- for="label-${h}-codetab-label-1-${s}-${f}-${F - f}"
861
+ for="label-${h}-codetab-label-1-${i}-${f}-${A - f}"
808
862
  onclick="this.getRootNode().querySelectorAll('.${_}').forEach(e => e.click())"
809
863
  >
810
- ${e.utils.escapeHtml(V || l(R))}
864
+ ${e.utils.escapeHtml(D || r(R))}
811
865
  </label>
812
866
  </li>`, K += `
813
867
  <div role="tabpanel">
814
868
  <input
815
869
  type="radio"
816
- name="${h}-codetab-pre-${s}-${f}"
870
+ name="${h}-codetab-pre-${i}-${f}"
817
871
  class="${_}"
818
872
  ${B}
819
873
  role="presentation">
820
- ${a(m, F, p, g, v)}
874
+ ${a(m, A, p, g, v)}
821
875
  </div>`, Z += `
822
876
  <input
823
877
  type="radio"
824
- name="${h}-codetab-lang-${s}-${f}"
878
+ name="${h}-codetab-lang-${i}-${f}"
825
879
  class="${_}"
826
880
  ${B}
827
881
  role="presentation">
828
- <span class=${h}-code-lang role="note">${e.utils.escapeHtml(l(R))}</span>`;
882
+ <span class=${h}-code-lang role="note">${e.utils.escapeHtml(r(R))}</span>`;
829
883
  }
884
+ const { attrs: ce, language: z } = ae(
885
+ d(m[f])
886
+ ), Y = [z, ce].filter(Boolean).join(" ");
830
887
  return `
831
- <${G} ${v.renderAttrs(ae)}>
832
- <${H} class="${h}-code-head">
888
+ <${H} ${v.renderAttrs(X)}>
889
+ <${J} class="${h}-code-head">
833
890
  <div class="${h}-code-flag">
834
891
  <ul class="${h}-codetab-label" role="tablist">${q}</ul>
835
892
  </div>
836
893
  <div class="${h}-code-action">
837
894
  <span class="${h}-codetab-lang">${Z}</span>
838
- <span class="${h}-copy-button" data-tips="${w}"${C ? " data-is-icon=true" : ""}>${S}</span>
839
- ${t.extraTools instanceof Function ? t.extraTools({ lang: m[f].info.trim() }) : t.extraTools || ""}
840
- ${G === "details" ? k : ""}
895
+ <span class="${h}-copy-button" data-tips="${C}"${w ? " data-is-icon=true" : ""}>${T}</span>
896
+ ${t.extraTools instanceof Function ? t.extraTools({ lang: Y }) : t.extraTools || ""}
897
+ ${H === "details" ? k : ""}
841
898
  </div>
842
- </${H}>
899
+ </${J}>
843
900
  ${K}
844
- </${G}>
901
+ </${H}>
845
902
  `;
846
903
  };
847
- e.renderer.rules.fence = r, e.renderer.rules.code_block = r;
848
- }, pt = (e, t) => {
904
+ e.renderer.rules.fence = s, e.renderer.rules.code_block = s;
905
+ }, Tt = (e, t) => {
849
906
  e.core.ruler.after("block", "echarts-token-attrs", (o) => {
850
907
  o.tokens.forEach((n) => {
851
908
  if (!(n.type !== "fence" || n.info !== "echarts") && (n.tag = "div", n.attrJoin("class", `${h}-echarts`), n.attrSet("data-echarts-theme", t.themeRef.value), n.attrSet("style", "width: 100%; aspect-ratio: 4 / 3;"), n.map && n.level === 0)) {
852
- const d = n.map[1] - 1, c = !!o.env.srcLines?.[d]?.trim()?.startsWith("```");
853
- n.attrSet("data-closed", `${c}`), n.attrSet("data-line", String(n.map[0]));
909
+ const c = n.map[1] - 1, d = !!o.env.srcLines?.[c]?.trim()?.startsWith("```");
910
+ n.attrSet("data-closed", `${d}`), n.attrSet("data-line", String(n.map[0]));
854
911
  }
855
912
  });
856
913
  });
857
914
  const a = e.renderer.rules.fence.bind(e.renderer.rules);
858
- e.renderer.rules.fence = (o, n, d, s, c) => {
859
- const u = o[n], l = u.content.trim();
860
- return u.info === "echarts" ? J(u, e.utils.escapeHtml(l), c) : a(o, n, d, s, c);
915
+ e.renderer.rules.fence = (o, n, c, i, d) => {
916
+ const u = o[n], r = u.content.trim();
917
+ return u.info === "echarts" ? te(u, e.utils.escapeHtml(r), d) : a(o, n, c, i, d);
861
918
  };
862
- }, gt = (e, t) => {
919
+ }, St = (e, t) => {
863
920
  e.renderer.rules.heading_open = (a, o) => {
864
- const n = a[o], d = a[o + 1].children?.reduce((c, u) => c + (["text", "code_inline", "math_inline"].includes(u.type) && u.content || ""), "") || "", s = n.markup.length;
921
+ const n = a[o], c = a[o + 1].children?.reduce((d, u) => d + (["text", "code_inline", "math_inline"].includes(u.type) && u.content || ""), "") || "", i = n.markup.length;
865
922
  return t.headsRef.value.push({
866
- text: d,
867
- level: s,
923
+ text: c,
924
+ level: i,
868
925
  line: n.map[0],
869
926
  currentToken: n,
870
927
  nextToken: a[o + 1]
871
928
  }), n.map && n.level === 0 && n.attrSet(
872
929
  "id",
873
930
  t.mdHeadingId({
874
- text: d,
875
- level: s,
931
+ text: c,
932
+ level: i,
876
933
  index: t.headsRef.value.length,
877
934
  currentToken: n,
878
935
  nextToken: a[o + 1]
879
936
  })
880
937
  ), e.renderer.renderToken(a, o, t);
881
- }, e.renderer.rules.heading_close = (a, o, n, d, s) => s.renderToken(a, o, n);
882
- }, Ce = {
938
+ }, e.renderer.rules.heading_close = (a, o, n, c, i) => i.renderToken(a, o, n);
939
+ }, Se = {
883
940
  block: [
884
941
  { open: "$$", close: "$$" },
885
942
  { open: "\\[", close: "\\]" }
@@ -890,335 +947,350 @@ const Q = new dt({
890
947
  { open: "\\[", close: "\\]" },
891
948
  { open: "\\(", close: "\\)" }
892
949
  ]
893
- }, vt = (e) => (t, a) => {
950
+ }, kt = (e) => (t, a) => {
894
951
  const o = e.delimiters;
895
952
  for (const n of o) {
896
953
  if (!t.src.startsWith(n.open, t.pos))
897
954
  continue;
898
- const d = t.pos + n.open.length;
899
- let s = d;
900
- for (; (s = t.src.indexOf(n.close, s)) !== -1; ) {
901
- let c = 0, u = s - 1;
955
+ const c = t.pos + n.open.length;
956
+ let i = c;
957
+ for (; (i = t.src.indexOf(n.close, i)) !== -1; ) {
958
+ let d = 0, u = i - 1;
902
959
  for (; u >= 0 && t.src[u] === "\\"; )
903
- c++, u--;
904
- if (c % 2 === 0)
960
+ d++, u--;
961
+ if (d % 2 === 0)
905
962
  break;
906
- s += n.close.length;
963
+ i += n.close.length;
907
964
  }
908
- if (s !== -1) {
909
- if (s - d === 0)
910
- return a || (t.pending += n.open + n.close), t.pos = s + n.close.length, !0;
965
+ if (i !== -1) {
966
+ if (i - c === 0)
967
+ return a || (t.pending += n.open + n.close), t.pos = i + n.close.length, !0;
911
968
  if (!a) {
912
- const c = t.push("math_inline", e.tag, 0);
913
- c.attrSet("class", e.className), c.markup = n.open, c.content = t.src.slice(d, s);
969
+ const d = t.push("math_inline", e.tag, 0);
970
+ d.attrSet("class", e.className), d.markup = n.open, d.content = t.src.slice(c, i);
914
971
  }
915
- return t.pos = s + n.close.length, !0;
972
+ return t.pos = i + n.close.length, !0;
916
973
  }
917
974
  }
918
975
  return !1;
919
- }, yt = (e) => (t, a, o, n) => {
920
- const d = e.delimiters, s = t.bMarks[a] + t.tShift[a], c = t.eMarks[a], u = (l, i, r) => {
921
- t.line = i;
976
+ }, At = (e) => (t, a, o, n) => {
977
+ const c = e.delimiters, i = t.bMarks[a] + t.tShift[a], d = t.eMarks[a], u = (r, l, s) => {
978
+ t.line = l;
922
979
  const m = t.push("math_block", e.tag, 0);
923
- return m.attrSet("class", e.className), m.block = !0, m.content = l, m.map = [a, t.line], m.markup = r, !0;
980
+ return m.attrSet("class", e.className), m.block = !0, m.content = r, m.map = [a, t.line], m.markup = s, !0;
924
981
  };
925
- for (const l of d) {
926
- const i = s;
927
- if (t.src.slice(i, i + l.open.length) !== l.open)
982
+ for (const r of c) {
983
+ const l = i;
984
+ if (t.src.slice(l, l + r.open.length) !== r.open)
928
985
  continue;
929
- const r = i + l.open.length, m = t.src.slice(r, c).trim(), f = m === "", p = m === l.close, g = m.endsWith(l.close);
986
+ const s = l + r.open.length, m = t.src.slice(s, d).trim(), f = m === "", p = m === r.close, g = m.endsWith(r.close);
930
987
  if (!f && !p && !g)
931
988
  continue;
932
989
  if (n)
933
990
  return !0;
934
991
  if (p)
935
- return u("", a + 1, l.open);
992
+ return u("", a + 1, r.open);
936
993
  if (!f && g) {
937
- const C = m.slice(0, -l.close.length);
938
- return u(C, a + 1, l.open);
994
+ const w = m.slice(0, -r.close.length);
995
+ return u(w, a + 1, r.open);
939
996
  }
940
997
  let v = a + 1, E = !1, y = "";
941
998
  for (; v < o; v++) {
942
- const C = t.bMarks[v] + t.tShift[v], k = t.eMarks[v];
943
- if (C < k && t.tShift[v] < t.blkIndent)
999
+ const w = t.bMarks[v] + t.tShift[v], k = t.eMarks[v];
1000
+ if (w < k && t.tShift[v] < t.blkIndent)
944
1001
  break;
945
- if (t.src.slice(C, k).trim().endsWith(l.close)) {
946
- const R = t.src.slice(0, k).lastIndexOf(l.close);
947
- y = t.src.slice(C, R), E = !0;
1002
+ if (t.src.slice(w, k).trim().endsWith(r.close)) {
1003
+ const R = t.src.slice(0, k).lastIndexOf(r.close);
1004
+ y = t.src.slice(w, R), E = !0;
948
1005
  break;
949
1006
  }
950
1007
  }
951
1008
  if (!E)
952
1009
  continue;
953
- const S = t.getLines(a + 1, v, t.tShift[a], !0) + (y.trim() ? y : "");
954
- return u(S, v + 1, l.open);
1010
+ const T = t.getLines(a + 1, v, t.tShift[a], !0) + (y.trim() ? y : "");
1011
+ return u(T, v + 1, r.open);
955
1012
  }
956
1013
  return !1;
957
- }, bt = (e, { katexRef: t, inlineDelimiters: a, blockDelimiters: o }) => {
958
- const n = (c, u, l = !1) => {
1014
+ }, Ht = (e, { katexRef: t, inlineDelimiters: a, blockDelimiters: o }) => {
1015
+ const n = (d, u, r = !1) => {
959
1016
  if (!t.value)
960
- return J(c, e.utils.escapeHtml(c.content), u);
961
- const i = t.value.renderToString(
962
- c.content,
963
- L.katexConfig({
1017
+ return te(d, e.utils.escapeHtml(d.content), u);
1018
+ const l = t.value.renderToString(
1019
+ d.content,
1020
+ P.katexConfig({
964
1021
  throwOnError: !1,
965
- displayMode: l
1022
+ displayMode: r
966
1023
  })
967
1024
  );
968
- return c.attrSet("data-processed", ""), J(c, String(i), u);
969
- }, d = (c, u, l, i, r) => n(c[u], r), s = (c, u, l, i, r) => n(c[u], r, !0);
1025
+ return d.attrSet("data-processed", ""), te(d, String(l), u);
1026
+ }, c = (d, u, r, l, s) => n(d[u], s), i = (d, u, r, l, s) => n(d[u], s, !0);
970
1027
  e.inline.ruler.before(
971
1028
  "escape",
972
1029
  "math_inline",
973
- vt({
974
- delimiters: a || Ce.inline,
1030
+ kt({
1031
+ delimiters: a || Se.inline,
975
1032
  className: `${h}-katex-inline`,
976
1033
  tag: "span"
977
1034
  })
978
1035
  ), e.block.ruler.after(
979
1036
  "blockquote",
980
1037
  "math_block",
981
- yt({
982
- delimiters: o || Ce.block,
1038
+ At({
1039
+ delimiters: o || Se.block,
983
1040
  className: `${h}-katex-block`,
984
1041
  tag: "p"
985
1042
  }),
986
1043
  {
987
1044
  alt: ["paragraph", "reference", "blockquote", "list"]
988
1045
  }
989
- ), e.renderer.rules.math_inline = d, e.renderer.rules.math_block = s;
990
- }, wt = (e, t) => {
1046
+ ), e.renderer.rules.math_inline = c, e.renderer.rules.math_block = i;
1047
+ }, Ft = (e, t) => {
991
1048
  e.core.ruler.after("block", "mermaid-token-attrs", (o) => {
992
1049
  o.tokens.forEach((n) => {
993
1050
  if (!(n.type !== "fence" || n.info !== "mermaid") && (n.tag = "div", n.attrJoin("class", `${h}-mermaid`), n.attrSet("data-mermaid-theme", t.themeRef.value), n.map && n.level === 0)) {
994
- const d = n.map[1] - 1, c = !!o.env.srcLines?.[d]?.trim()?.startsWith("```");
995
- n.attrSet("data-closed", `${c}`), n.attrSet("data-line", String(n.map[0]));
1051
+ const c = n.map[1] - 1, d = !!o.env.srcLines?.[c]?.trim()?.startsWith("```");
1052
+ n.attrSet("data-closed", `${d}`), n.attrSet("data-line", String(n.map[0]));
996
1053
  }
997
1054
  });
998
1055
  });
999
1056
  const a = e.renderer.rules.fence.bind(e.renderer.rules);
1000
- e.renderer.rules.fence = (o, n, d, s, c) => {
1001
- const u = o[n], l = u.content.trim();
1057
+ e.renderer.rules.fence = (o, n, c, i, d) => {
1058
+ const u = o[n], r = u.content.trim();
1002
1059
  if (u.info === "mermaid") {
1003
- const i = Q.get(l);
1004
- return i ? (u.tag = "p", u.attrSet("data-processed", ""), u.attrSet("data-content", l), J(u, i, c)) : J(u, e.utils.escapeHtml(l), c);
1060
+ const l = oe.get(r);
1061
+ return l ? (u.tag = "p", u.attrSet("data-processed", ""), u.attrSet("data-content", r), te(u, l, d)) : te(u, e.utils.escapeHtml(r), d);
1005
1062
  }
1006
- return a(o, n, d, s, c);
1063
+ return a(o, n, c, i, d);
1007
1064
  };
1008
- }, $e = (e, t, a) => {
1065
+ }, ke = (e, t, a) => {
1009
1066
  const o = e.attrIndex(t), n = [t, a];
1010
1067
  o < 0 ? e.attrPush(n) : (e.attrs = e.attrs || [], e.attrs[o] = n);
1011
- }, Ct = (e) => e.type === "inline", $t = (e) => e.type === "paragraph_open", Et = (e) => e.type === "list_item_open", xt = (e) => e.content.indexOf("[ ] ") === 0 || e.content.indexOf("[x] ") === 0 || e.content.indexOf("[X] ") === 0, Tt = (e, t) => Ct(e[t]) && $t(e[t - 1]) && Et(e[t - 2]) && xt(e[t]), St = (e, t) => {
1068
+ }, Rt = (e) => e.type === "inline", Lt = (e) => e.type === "paragraph_open", Mt = (e) => e.type === "list_item_open", Pt = (e) => e.content.indexOf("[ ] ") === 0 || e.content.indexOf("[x] ") === 0 || e.content.indexOf("[X] ") === 0, _t = (e, t) => Rt(e[t]) && Lt(e[t - 1]) && Mt(e[t - 2]) && Pt(e[t]), Ot = (e, t) => {
1012
1069
  const a = e[t].level - 1;
1013
1070
  for (let o = t - 1; o >= 0; o--)
1014
1071
  if (e[o].level === a)
1015
1072
  return o;
1016
1073
  return -1;
1017
- }, It = (e) => {
1074
+ }, Nt = (e) => {
1018
1075
  const t = new e("html_inline", "", 0);
1019
1076
  return t.content = "<label>", t;
1020
- }, kt = (e) => {
1077
+ }, Bt = (e) => {
1021
1078
  const t = new e("html_inline", "", 0);
1022
1079
  return t.content = "</label>", t;
1023
- }, Ft = (e, t, a) => {
1080
+ }, jt = (e, t, a) => {
1024
1081
  const o = new a("html_inline", "", 0);
1025
1082
  return o.content = '<label class="task-list-item-label" for="' + t + '">' + e + "</label>", o.attrs = [["for", t]], o;
1026
- }, At = (e, t, a) => {
1083
+ }, Dt = (e, t, a) => {
1027
1084
  const o = new t("html_inline", "", 0), n = a.enabled ? " " : ' disabled="" ';
1028
1085
  return e.content.indexOf("[ ] ") === 0 ? o.content = '<input class="task-list-item-checkbox"' + n + 'type="checkbox">' : (e.content.indexOf("[x] ") === 0 || e.content.indexOf("[X] ") === 0) && (o.content = '<input class="task-list-item-checkbox" checked=""' + n + 'type="checkbox">'), o;
1029
- }, Rt = (e, t, a) => {
1030
- if (e.children = e.children || [], e.children.unshift(At(e, t, a)), e.children[1].content = e.children[1].content.slice(3), e.content = e.content.slice(3), a.label)
1086
+ }, Vt = (e, t, a) => {
1087
+ if (e.children = e.children || [], e.children.unshift(Dt(e, t, a)), e.children[1].content = e.children[1].content.slice(3), e.content = e.content.slice(3), a.label)
1031
1088
  if (a.labelAfter) {
1032
1089
  e.children.pop();
1033
1090
  const o = "task-item-" + Math.ceil(Math.random() * (1e4 * 1e3) - 1e3);
1034
- e.children[0].content = e.children[0].content.slice(0, -1) + ' id="' + o + '">', e.children.push(Ft(e.content, o, t));
1091
+ e.children[0].content = e.children[0].content.slice(0, -1) + ' id="' + o + '">', e.children.push(jt(e.content, o, t));
1035
1092
  } else
1036
- e.children.unshift(It(t)), e.children.push(kt(t));
1037
- }, Ht = (e, t = {}) => {
1093
+ e.children.unshift(Nt(t)), e.children.push(Bt(t));
1094
+ }, zt = (e, t = {}) => {
1038
1095
  e.core.ruler.after("inline", "github-task-lists", (a) => {
1039
1096
  const o = a.tokens;
1040
1097
  for (let n = 2; n < o.length; n++)
1041
- Tt(o, n) && (Rt(o[n], a.Token, t), $e(
1098
+ _t(o, n) && (Vt(o[n], a.Token, t), ke(
1042
1099
  o[n - 2],
1043
1100
  "class",
1044
1101
  "task-list-item" + (t.enabled ? " enabled" : " ")
1045
- ), $e(o[St(o, n - 2)], "class", "contains-task-list"));
1102
+ ), ke(o[Ot(o, n - 2)], "class", "contains-task-list"));
1046
1103
  });
1047
- }, Mt = (e) => {
1104
+ }, Gt = (e) => {
1048
1105
  e.core.ruler.push("init-line-number", (t) => (t.tokens.forEach((a) => {
1049
1106
  a.map && a.attrSet("data-line", a.map[0].toString());
1050
1107
  }), !0));
1051
- }, Pt = (e, t) => {
1052
- const { editorConfig: a, markdownItConfig: o, markdownItPlugins: n, editorExtensions: d } = L, s = $("editorId"), c = $("language"), u = $(
1108
+ }, Ut = (e, t) => {
1109
+ const { editorConfig: a, markdownItConfig: o, markdownItPlugins: n, editorExtensions: c } = P, i = $("editorId"), d = $("language"), u = $(
1053
1110
  "usedLanguageText"
1054
- ), l = $("showCodeRowNumber"), i = $("theme"), r = $("customIcon"), m = $("rootRef"), f = $("setting"), p = z([]), g = st(e), v = ct(e), { reRenderRef: E, replaceMermaid: y } = ut(e), { reRenderEcharts: w, replaceEcharts: S } = it(e), C = Qe({
1055
- html: !0,
1111
+ ), r = $("showCodeRowNumber"), l = $("theme"), s = $("customIcon"), m = $("rootRef"), f = $("setting"), p = U([]), g = vt(e), v = yt(e), { reRenderRef: E, replaceMermaid: y } = Ct(e), { reRenderEcharts: C, replaceEcharts: T } = gt(e), w = st({
1112
+ // 关闭源文本中的原生 HTML 解析,插件生成的 HTML 不受影响。
1113
+ html: !1,
1056
1114
  breaks: !0,
1057
1115
  linkify: !0
1058
1116
  });
1059
- o(C, {
1060
- editorId: s
1117
+ o(w, {
1118
+ editorId: i
1061
1119
  });
1062
1120
  const k = [
1063
1121
  {
1064
1122
  type: "image",
1065
- plugin: et,
1123
+ plugin: lt,
1066
1124
  options: { figcaption: !0, classes: "md-zoom" }
1067
1125
  },
1068
1126
  {
1069
1127
  type: "admonition",
1070
- plugin: mt,
1128
+ plugin: wt,
1071
1129
  options: {}
1072
1130
  },
1073
1131
  {
1074
1132
  type: "taskList",
1075
- plugin: Ht,
1133
+ plugin: zt,
1076
1134
  options: {}
1077
1135
  },
1078
1136
  {
1079
1137
  type: "heading",
1080
- plugin: gt,
1138
+ plugin: St,
1081
1139
  options: { mdHeadingId: e.mdHeadingId, headsRef: p }
1082
1140
  },
1083
1141
  {
1084
1142
  type: "code",
1085
- plugin: ht,
1143
+ plugin: It,
1086
1144
  options: {
1087
- editorId: s,
1145
+ editorId: i,
1088
1146
  usedLanguageTextRef: u,
1089
1147
  // showCodeRowNumber,
1090
1148
  codeFoldable: e.codeFoldable,
1091
1149
  autoFoldThreshold: e.autoFoldThreshold,
1092
- customIconRef: r
1150
+ customIconRef: s
1093
1151
  }
1094
1152
  },
1095
1153
  {
1096
1154
  type: "sub",
1097
- plugin: tt,
1155
+ plugin: it,
1098
1156
  options: {}
1099
1157
  },
1100
1158
  {
1101
1159
  type: "sup",
1102
- plugin: nt,
1160
+ plugin: ct,
1103
1161
  options: {}
1104
1162
  }
1105
1163
  ];
1106
1164
  e.noKatex || k.push({
1107
1165
  type: "katex",
1108
- plugin: bt,
1166
+ plugin: Ht,
1109
1167
  options: { katexRef: v }
1110
1168
  }), e.noMermaid || k.push({
1111
1169
  type: "mermaid",
1112
- plugin: wt,
1113
- options: { themeRef: i }
1170
+ plugin: Ft,
1171
+ options: { themeRef: l }
1114
1172
  }), e.noEcharts || k.push({
1115
1173
  type: "echarts",
1116
- plugin: pt,
1117
- options: { themeRef: i }
1174
+ plugin: Tt,
1175
+ options: { themeRef: l }
1118
1176
  }), n(k, {
1119
- editorId: s
1177
+ editorId: i
1120
1178
  }).forEach((H) => {
1121
- C.use(H.plugin, H.options);
1179
+ w.use(H.plugin, H.options);
1122
1180
  });
1123
- const I = C.options.highlight;
1124
- C.set({
1125
- highlight: (H, D, ae) => {
1126
- if (I) {
1127
- const U = I(H, D, ae);
1128
- if (U)
1129
- return U;
1181
+ const S = w.options.highlight;
1182
+ w.set({
1183
+ highlight: (H, J, V) => {
1184
+ const X = ae(J, V), { attrs: ce, language: z, lineHighlightRanges: Y } = X;
1185
+ let A = "";
1186
+ if (S) {
1187
+ const G = S(H, z, ce);
1188
+ if (G) {
1189
+ const ee = dt(G, H, {
1190
+ lineHighlightRanges: Y,
1191
+ showLineNumber: r
1192
+ });
1193
+ if (ee.shouldReturnDirectly)
1194
+ return ee.html;
1195
+ A = ee.html;
1196
+ }
1130
1197
  }
1131
- let F;
1132
- !e.noHighlight && g.value ? g.value.getLanguage(D) ? F = g.value.highlight(H, {
1133
- language: D,
1198
+ A || (!e.noHighlight && g.value ? g.value.getLanguage(z) ? A = g.value.highlight(H, {
1199
+ language: z,
1134
1200
  ignoreIllegals: !0
1135
- }).value : F = g.value.highlightAuto(H).value : F = C.utils.escapeHtml(H);
1136
- const _ = C.utils.escapeHtml(D), X = l ? ot(
1137
- F.replace(/^\n+|\n+$/g, ""),
1138
- H.replace(/^\n+|\n+$/g, "")
1139
- ) : `<span class="${h}-code-block">${F.replace(/^\n+|\n+$/g, "")}</span>`;
1140
- return `<pre><code class="language-${_}" language="${_}">${X}</code></pre>`;
1201
+ }).value : A = g.value.highlightAuto(H).value : A = w.utils.escapeHtml(H));
1202
+ const _ = w.utils.escapeHtml(z);
1203
+ let Q = `<span class="${h}-code-block">${A.replace(/^\n+|\n+$/g, "")}</span>`;
1204
+ return (r || Y.length) && (Q = ut(A, H, {
1205
+ lineHighlightRanges: Y,
1206
+ showLineNumber: r
1207
+ })), `<pre><code class="language-${_}" language="${_}">${Q}</code></pre>`;
1141
1208
  }
1142
- }), Mt(C);
1143
- const R = z(`_article-key_${se()}`), N = z(
1209
+ }), Gt(w);
1210
+ const R = U(`_article-key_${fe()}`), N = U(
1144
1211
  e.sanitize(
1145
- C.render(e.modelValue, {
1212
+ w.render(e.modelValue, {
1146
1213
  srcLines: e.modelValue.split(`
1147
1214
  `)
1148
1215
  })
1149
1216
  )
1150
1217
  );
1151
- let V = () => {
1218
+ let D = () => {
1152
1219
  }, B = () => {
1153
1220
  };
1154
1221
  const q = () => {
1155
1222
  const H = m.value?.querySelectorAll(
1156
- `#${s} p.${h}-mermaid:not([data-closed=false])`
1223
+ `#${i} p.${h}-mermaid:not([data-closed=false])`
1157
1224
  );
1158
- B(), B = Je(H, {
1159
- customIcon: r.value
1160
- }), d.mermaid?.enableZoom && (V(), V = Xe(H, {
1161
- customIcon: r.value
1225
+ B(), B = ot(H, {
1226
+ customIcon: s.value
1227
+ }), c.mermaid?.enableZoom && (D(), D = at(H, {
1228
+ customIcon: s.value
1162
1229
  }));
1163
1230
  }, K = () => {
1164
- b.emit(s, Y, N.value), e.onHtmlChanged(N.value), e.onGetCatalog(p.value), b.emit(s, re, p.value), W(() => {
1165
- y().then(q), S();
1231
+ b.emit(i, ne, N.value), e.onHtmlChanged(N.value), e.onGetCatalog(p.value), b.emit(i, de, p.value), W(() => {
1232
+ y().then(q), T();
1166
1233
  });
1167
1234
  }, Z = () => {
1168
1235
  p.value = [], N.value = e.sanitize(
1169
- C.render(e.modelValue, {
1236
+ w.render(e.modelValue, {
1170
1237
  srcLines: e.modelValue.split(`
1171
1238
  `)
1172
1239
  })
1173
1240
  );
1174
- }, oe = A(() => (e.noKatex || !!v.value) && (e.noHighlight || !!g.value));
1175
- let G = -1;
1176
- return x([Pe(e, "modelValue"), oe, E, c], () => {
1177
- G = window.setTimeout(
1178
- () => {
1179
- Z();
1180
- },
1181
- t ? 0 : a.renderDelay
1182
- );
1183
- }), x(
1241
+ }, ie = F(() => (e.noKatex || !!v.value) && (e.noHighlight || !!g.value));
1242
+ return x(
1243
+ [De(e, "modelValue"), ie, E, d],
1244
+ (H, J, V) => {
1245
+ const X = window.setTimeout(
1246
+ () => {
1247
+ Z();
1248
+ },
1249
+ t ? 0 : a.renderDelay
1250
+ );
1251
+ V(() => {
1252
+ clearTimeout(X);
1253
+ });
1254
+ }
1255
+ ), x(
1184
1256
  () => f.value.preview,
1185
1257
  () => {
1186
1258
  f.value.preview && W(() => {
1187
- y().then(q), S(), b.emit(s, re, p.value);
1259
+ y().then(q), T(), b.emit(i, de, p.value);
1188
1260
  });
1189
1261
  }
1190
- ), x([N, w], () => {
1262
+ ), x([N, C], () => {
1191
1263
  K();
1192
- }), M(K), M(() => {
1193
- b.on(s, {
1194
- name: We,
1264
+ }), L(K), L(() => {
1265
+ b.on(i, {
1266
+ name: Ke,
1195
1267
  callback() {
1196
- b.emit(s, re, p.value);
1268
+ b.emit(i, de, p.value);
1197
1269
  }
1198
- }), b.on(s, {
1199
- name: ue,
1270
+ }), b.on(i, {
1271
+ name: ge,
1200
1272
  callback: () => {
1201
- R.value = `_article-key_${se()}`, Z();
1273
+ R.value = `_article-key_${fe()}`, Z();
1202
1274
  }
1203
1275
  });
1204
- }), ne(() => {
1205
- V(), B(), clearTimeout(G);
1276
+ }), le(() => {
1277
+ D(), B();
1206
1278
  }), { html: N, key: R };
1207
- }, Lt = (e, t) => {
1208
- const a = $("editorId"), o = $("setting"), { noImgZoomIn: n } = e, d = Be(() => {
1209
- const s = document.querySelectorAll(
1279
+ }, Wt = (e, t) => {
1280
+ const a = $("editorId"), o = $("setting"), { noImgZoomIn: n } = e, c = Ye(() => {
1281
+ const i = document.querySelectorAll(
1210
1282
  `#${a}-preview img:not(.not-zoom):not(.medium-zoom-image)`
1211
1283
  );
1212
- s.length !== 0 && at(s, {
1284
+ i.length !== 0 && mt(i, {
1213
1285
  background: "#00000073"
1214
1286
  });
1215
1287
  });
1216
- M(async () => {
1217
- !n && o.value.preview && await d();
1288
+ L(async () => {
1289
+ !n && o.value.preview && await c();
1218
1290
  }), x([t, () => o.value.preview], async () => {
1219
- !n && o.value.preview && await d();
1291
+ !n && o.value.preview && await c();
1220
1292
  });
1221
- }, Ee = {
1293
+ }, Ae = {
1222
1294
  checked: {
1223
1295
  regexp: /- \[x\]/,
1224
1296
  value: "- [ ]"
@@ -1227,55 +1299,55 @@ const Q = new dt({
1227
1299
  regexp: /- \[\s\]/,
1228
1300
  value: "- [x]"
1229
1301
  }
1230
- }, _t = (e, t) => {
1302
+ }, qt = (e, t) => {
1231
1303
  const a = $("editorId"), o = $("rootRef");
1232
1304
  let n = () => {
1233
1305
  };
1234
- const d = () => {
1306
+ const c = () => {
1235
1307
  if (!o.value)
1236
1308
  return !1;
1237
- const s = o.value.querySelectorAll(".task-list-item.enabled"), c = (u) => {
1309
+ const i = o.value.querySelectorAll(".task-list-item.enabled"), d = (u) => {
1238
1310
  u.preventDefault();
1239
- const l = u.target.checked ? "unChecked" : "checked", i = u.target.parentElement?.dataset.line;
1240
- if (!i)
1311
+ const r = u.target.checked ? "unChecked" : "checked", l = u.target.parentElement?.dataset.line;
1312
+ if (!l)
1241
1313
  return;
1242
- const r = Number(i), m = e.modelValue.split(`
1243
- `), f = m[Number(r)].replace(
1244
- Ee[l].regexp,
1245
- Ee[l].value
1314
+ const s = Number(l), m = e.modelValue.split(`
1315
+ `), f = m[Number(s)].replace(
1316
+ Ae[r].regexp,
1317
+ Ae[r].value
1246
1318
  );
1247
- e.previewOnly ? (m[Number(r)] = f, e.onChange(m.join(`
1248
- `))) : b.emit(a, qe, r + 1, f);
1319
+ e.previewOnly ? (m[Number(s)] = f, e.onChange(m.join(`
1320
+ `))) : b.emit(a, Ze, s + 1, f);
1249
1321
  };
1250
- s.forEach((u) => {
1251
- u.addEventListener("click", c);
1322
+ i.forEach((u) => {
1323
+ u.addEventListener("click", d);
1252
1324
  }), n = () => {
1253
- s.forEach((u) => {
1254
- u.removeEventListener("click", c);
1325
+ i.forEach((u) => {
1326
+ u.removeEventListener("click", d);
1255
1327
  });
1256
1328
  };
1257
1329
  };
1258
- ne(() => {
1330
+ le(() => {
1259
1331
  n();
1260
1332
  }), x(
1261
1333
  [t],
1262
1334
  () => {
1263
- n(), W(d);
1335
+ n(), W(c);
1264
1336
  },
1265
1337
  {
1266
1338
  immediate: !0
1267
1339
  }
1268
1340
  );
1269
- }, Ot = (e, t, a) => {
1341
+ }, Kt = (e, t, a) => {
1270
1342
  const o = $("setting"), n = () => {
1271
1343
  W(() => {
1272
1344
  e.onRemount?.();
1273
1345
  });
1274
- }, d = (s) => {
1275
- s && n();
1346
+ }, c = (i) => {
1347
+ i && n();
1276
1348
  };
1277
- x([t, a], n), x(() => o.value.preview, d), x(() => o.value.htmlPreview, d), M(n);
1278
- }, ke = {
1349
+ x([t, a], n), x(() => o.value.preview, c), x(() => o.value.htmlPreview, c), L(n);
1350
+ }, Me = {
1279
1351
  modelValue: {
1280
1352
  type: String,
1281
1353
  default: ""
@@ -1346,8 +1418,8 @@ const Q = new dt({
1346
1418
  type: [Object, Function],
1347
1419
  default: void 0
1348
1420
  }
1349
- }, cn = {
1350
- ...ke,
1421
+ }, bn = {
1422
+ ...Me,
1351
1423
  updateModelValue: {
1352
1424
  type: Function,
1353
1425
  default: () => {
@@ -1402,7 +1474,7 @@ const Q = new dt({
1402
1474
  inputBoxWidth: {
1403
1475
  type: String
1404
1476
  },
1405
- oninputBoxWidthChange: {
1477
+ onInputBoxWidthChange: {
1406
1478
  type: Function
1407
1479
  },
1408
1480
  transformImgUrl: {
@@ -1415,10 +1487,10 @@ const Q = new dt({
1415
1487
  catalogMaxDepth: {
1416
1488
  type: Number
1417
1489
  }
1418
- }, xe = (e) => {
1490
+ }, He = (e) => {
1419
1491
  const a = new DOMParser().parseFromString(e, "text/html");
1420
1492
  return Array.from(a.body.childNodes);
1421
- }, Nt = (e, t) => e.nodeType !== t.nodeType ? !1 : e.nodeType === Node.TEXT_NODE || e.nodeType === Node.COMMENT_NODE ? e.textContent === t.textContent : e.nodeType === Node.ELEMENT_NODE ? e.outerHTML === t.outerHTML : e.isEqualNode ? e.isEqualNode(t) : !1, Bt = /* @__PURE__ */ de({
1493
+ }, Zt = (e, t) => e.nodeType !== t.nodeType ? !1 : e.nodeType === Node.TEXT_NODE || e.nodeType === Node.COMMENT_NODE ? e.textContent === t.textContent : e.nodeType === Node.ELEMENT_NODE ? e.outerHTML === t.outerHTML : e.isEqualNode ? e.isEqualNode(t) : !1, Jt = /* @__PURE__ */ pe({
1422
1494
  name: "UpdateOnDemand",
1423
1495
  props: {
1424
1496
  id: {
@@ -1435,31 +1507,31 @@ const Q = new dt({
1435
1507
  }
1436
1508
  },
1437
1509
  setup(e) {
1438
- const t = z(), a = e.html, o = (n, d) => {
1510
+ const t = U(), a = e.html, o = (n, c) => {
1439
1511
  if (!t.value) return;
1440
- const s = t.value, c = Array.from(s.childNodes), u = Math.min(n.length, d.length);
1441
- let l = -1;
1442
- for (let r = 0; r < u; r++)
1443
- if (!Nt(n[r], d[r])) {
1444
- l = r;
1512
+ const i = t.value, d = Array.from(i.childNodes), u = Math.min(n.length, c.length);
1513
+ let r = -1;
1514
+ for (let s = 0; s < u; s++)
1515
+ if (!Zt(n[s], c[s])) {
1516
+ r = s;
1445
1517
  break;
1446
1518
  }
1447
- if (l === -1)
1448
- if (d.length > n.length)
1449
- l = n.length;
1450
- else if (n.length > d.length)
1451
- l = d.length;
1519
+ if (r === -1)
1520
+ if (c.length > n.length)
1521
+ r = n.length;
1522
+ else if (n.length > c.length)
1523
+ r = c.length;
1452
1524
  else
1453
1525
  return;
1454
- const i = Math.min(l, c.length);
1455
- for (let r = c.length - 1; r >= i; r--)
1456
- c[r].remove();
1457
- for (let r = l; r < n.length; r++)
1458
- s.appendChild(n[r].cloneNode(!0));
1526
+ const l = Math.min(r, d.length);
1527
+ for (let s = d.length - 1; s >= l; s--)
1528
+ d[s].remove();
1529
+ for (let s = r; s < n.length; s++)
1530
+ i.appendChild(n[s].cloneNode(!0));
1459
1531
  };
1460
- return x(() => e.html, (n, d) => {
1461
- const s = xe(n), c = xe(d || "");
1462
- o(s, c);
1532
+ return x(() => e.html, (n, c) => {
1533
+ const i = He(n), d = He(c || "");
1534
+ o(i, d);
1463
1535
  }), () => j("div", {
1464
1536
  id: e.id,
1465
1537
  class: e.class,
@@ -1467,30 +1539,30 @@ const Q = new dt({
1467
1539
  ref: t
1468
1540
  }, null);
1469
1541
  }
1470
- }), jt = /* @__PURE__ */ de({
1542
+ }), Xt = /* @__PURE__ */ pe({
1471
1543
  name: "ContentPreview",
1472
- props: ke,
1544
+ props: Me,
1473
1545
  setup(e) {
1474
1546
  const t = $("editorId"), a = $("setting"), o = $("previewTheme"), n = $("showCodeRowNumber"), {
1475
- html: d,
1476
- key: s
1477
- } = Pt(e, e.previewOnly);
1478
- lt(e, d, s), Lt(e, d), _t(e, d), Ot(e, d, s);
1479
- const c = A(() => [`${h}-preview`, `${o?.value}-theme`, n && `${h}-scrn`].filter(Boolean)), u = () => {
1480
- const l = `${t}-preview`;
1481
- return e.previewComponent ? _e(e.previewComponent, {
1482
- key: s.value,
1483
- html: d.value,
1484
- id: l,
1485
- class: c.value
1486
- }) : j(Bt, {
1487
- key: s.value,
1488
- html: d.value,
1489
- id: l,
1490
- class: c.value
1547
+ html: c,
1548
+ key: i
1549
+ } = Ut(e, e.previewOnly);
1550
+ pt(e, c, i), Wt(e, c), qt(e, c), Kt(e, c, i);
1551
+ const d = F(() => [`${h}-preview`, `${o?.value}-theme`, n && `${h}-scrn`].filter(Boolean)), u = () => {
1552
+ const r = `${t}-preview`;
1553
+ return e.previewComponent ? ze(e.previewComponent, {
1554
+ key: i.value,
1555
+ html: c.value,
1556
+ id: r,
1557
+ class: d.value
1558
+ }) : j(Jt, {
1559
+ key: i.value,
1560
+ html: c.value,
1561
+ id: r,
1562
+ class: d.value
1491
1563
  }, null);
1492
1564
  };
1493
- return () => j(Le, null, [a.value.preview && (e.previewOnly ? u() : j("div", {
1565
+ return () => j(Ve, null, [a.value.preview && (e.previewOnly ? u() : j("div", {
1494
1566
  id: `${t}-preview-wrapper`,
1495
1567
  class: `${h}-preview-wrapper`,
1496
1568
  key: "content-preview-wrapper"
@@ -1500,9 +1572,9 @@ const Q = new dt({
1500
1572
  key: "html-preview-wrapper"
1501
1573
  }, [j("div", {
1502
1574
  class: `${h}-html`
1503
- }, [d.value])])]);
1575
+ }, [c.value])])]);
1504
1576
  }
1505
- }), Dt = ({ text: e }) => e, Fe = {
1577
+ }), Yt = ({ text: e }) => e, Pe = {
1506
1578
  /**
1507
1579
  * markdown content.
1508
1580
  *
@@ -1611,7 +1683,7 @@ const Q = new dt({
1611
1683
  */
1612
1684
  mdHeadingId: {
1613
1685
  type: Function,
1614
- default: Dt
1686
+ default: Yt
1615
1687
  },
1616
1688
  /**
1617
1689
  *
@@ -1740,8 +1812,8 @@ const Q = new dt({
1740
1812
  type: [Object, Function],
1741
1813
  default: void 0
1742
1814
  }
1743
- }, dn = {
1744
- ...Fe,
1815
+ }, Cn = {
1816
+ ...Pe,
1745
1817
  /**
1746
1818
  * input回调事件
1747
1819
  */
@@ -1801,7 +1873,7 @@ const Q = new dt({
1801
1873
  */
1802
1874
  toolbars: {
1803
1875
  type: Array,
1804
- default: De
1876
+ default: et
1805
1877
  },
1806
1878
  /**
1807
1879
  * 浮动工具栏
@@ -1879,7 +1951,7 @@ const Q = new dt({
1879
1951
  */
1880
1952
  footers: {
1881
1953
  type: Array,
1882
- default: je
1954
+ default: Qe
1883
1955
  },
1884
1956
  /**
1885
1957
  * 是否默认激活输入框和预览框同步滚动
@@ -2011,7 +2083,7 @@ const Q = new dt({
2011
2083
  /**
2012
2084
  * 输入框宽度变化事件
2013
2085
  */
2014
- oninputBoxWidthChange: {
2086
+ onInputBoxWidthChange: {
2015
2087
  type: Function,
2016
2088
  default: void 0
2017
2089
  },
@@ -2046,14 +2118,14 @@ const Q = new dt({
2046
2118
  type: Number,
2047
2119
  default: void 0
2048
2120
  }
2049
- }, Ae = [
2121
+ }, _e = [
2050
2122
  "onHtmlChanged",
2051
2123
  "onGetCatalog",
2052
2124
  "onChange",
2053
2125
  "onRemount",
2054
2126
  "update:modelValue"
2055
- ], un = [
2056
- ...Ae,
2127
+ ], wn = [
2128
+ ..._e,
2057
2129
  "onSave",
2058
2130
  "onUploadImg",
2059
2131
  "onError",
@@ -2061,51 +2133,45 @@ const Q = new dt({
2061
2133
  "onFocus",
2062
2134
  "onInput",
2063
2135
  "onDrop",
2064
- "oninputBoxWidthChange"
2065
- ], Vt = (e, t, a) => {
2066
- const { editorId: o } = a, n = {
2067
- rerender() {
2068
- b.emit(o, ue);
2069
- }
2070
- };
2071
- t.expose(n);
2072
- }, le = /* @__PURE__ */ de({
2136
+ "onInputBoxWidthChange"
2137
+ ], ue = /* @__PURE__ */ pe({
2073
2138
  name: "MdPreview",
2074
- props: Fe,
2075
- emits: Ae,
2139
+ props: Pe,
2140
+ emits: _e,
2076
2141
  setup(e, t) {
2077
2142
  const {
2078
2143
  noKatex: a,
2079
2144
  noMermaid: o,
2080
2145
  noHighlight: n
2081
- } = e, d = z(), s = rt(e);
2082
- Ie(e, {
2083
- rootRef: d,
2084
- editorId: s
2085
- }), Vt(e, t, {
2086
- editorId: s
2087
- }), ne(() => {
2088
- b.clear(s);
2146
+ } = e, c = U(), i = ht(e);
2147
+ Le(e, {
2148
+ rootRef: c,
2149
+ editorId: i
2150
+ }), ft(e, t, {
2151
+ editorId: i
2152
+ }), le(() => {
2153
+ b.clear(i);
2089
2154
  });
2090
- const c = (r) => {
2091
- e.onChange?.(r), t.emit("onChange", r), t.emit("update:modelValue", r);
2092
- }, u = (r) => {
2093
- e.onHtmlChanged?.(r), t.emit("onHtmlChanged", r);
2094
- }, l = (r) => {
2095
- e.onGetCatalog?.(r), t.emit("onGetCatalog", r);
2096
- }, i = () => {
2155
+ const d = (s) => {
2156
+ e.onChange?.(s), t.emit("onChange", s), t.emit("update:modelValue", s);
2157
+ }, u = (s) => {
2158
+ e.onHtmlChanged?.(s), t.emit("onHtmlChanged", s);
2159
+ }, r = (s) => {
2160
+ e.onGetCatalog?.(s), t.emit("onGetCatalog", s);
2161
+ }, l = () => {
2097
2162
  e.onRemount?.(), t.emit("onRemount");
2098
2163
  };
2099
2164
  return () => j("div", {
2100
- id: s,
2101
- class: [h, e.class, e.theme === "dark" && `${h}-dark`, `${h}-previewOnly`],
2165
+ id: i,
2166
+ class: [h, e.class, `${h}-previewOnly`],
2167
+ "data-theme": e.theme,
2102
2168
  style: e.style,
2103
- ref: d
2104
- }, [j(jt, {
2169
+ ref: c
2170
+ }, [j(Xt, {
2105
2171
  modelValue: e.modelValue,
2106
- onChange: c,
2172
+ onChange: d,
2107
2173
  onHtmlChanged: u,
2108
- onGetCatalog: l,
2174
+ onGetCatalog: r,
2109
2175
  mdHeadingId: e.mdHeadingId,
2110
2176
  noMermaid: o,
2111
2177
  sanitize: e.sanitize,
@@ -2117,27 +2183,27 @@ const Q = new dt({
2117
2183
  sanitizeMermaid: e.sanitizeMermaid,
2118
2184
  codeFoldable: e.codeFoldable,
2119
2185
  autoFoldThreshold: e.autoFoldThreshold,
2120
- onRemount: i,
2186
+ onRemount: l,
2121
2187
  noEcharts: e.noEcharts,
2122
2188
  previewComponent: e.previewComponent
2123
2189
  }, null)]);
2124
2190
  }
2125
2191
  });
2126
- le.install = (e) => (e.component(le.name, le), e);
2192
+ ue.install = (e) => (e.component(ue.name, ue), e);
2127
2193
  export {
2128
- P as C,
2129
- le as M,
2130
- jt as a,
2131
- un as b,
2132
- cn as c,
2133
- dn as d,
2134
- ce as e,
2135
- rn as f,
2136
- ln as g,
2137
- tn as h,
2138
- on as i,
2139
- an as j,
2140
- sn as k,
2141
- nn as l,
2142
- rt as u
2194
+ M as C,
2195
+ ue as M,
2196
+ Xt as a,
2197
+ wn as b,
2198
+ bn as c,
2199
+ Cn as d,
2200
+ he as e,
2201
+ gn as f,
2202
+ vn as g,
2203
+ mn as h,
2204
+ hn as i,
2205
+ pn as j,
2206
+ yn as k,
2207
+ fn as l,
2208
+ ht as u
2143
2209
  };