@airalogy/aimd-recorder 1.24.4 → 1.25.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 (86) hide show
  1. package/README.md +13 -1
  2. package/README.zh-CN.md +13 -1
  3. package/dist/{AimdDnaSequenceField-Opgy07Gt.js → AimdDnaSequenceField-BHV1_c2o.js} +1 -1
  4. package/dist/{AimdEditor.vue_vue_type_style_index_0_lang-DHckC0bq.js → AimdEditor.vue_vue_type_style_index_0_lang-phvUVTHV.js} +643 -605
  5. package/dist/AimdEntityRefField-COzwbHwr.js +4 -0
  6. package/dist/{AimdEntityRefField-GA6-mhGU.js → AimdEntityRefField.vue_vue_type_script_setup_true_lang-BIvUuZFV.js} +2 -2
  7. package/dist/{AimdMarkdownField-jagZIbKc.js → AimdMarkdownField-t8hqazDv.js} +3 -3
  8. package/dist/{AimdMarkdownNoteField-BUq4fRcZ.js → AimdMarkdownNoteField-BGjkSXEY.js} +2 -2
  9. package/dist/AimdResourceRefField-BBaRSLcL.js +264 -0
  10. package/dist/aimd-recorder.css +1 -1
  11. package/dist/{arc-CR1cpc2k.js → arc-CsBMJYPv.js} +1 -1
  12. package/dist/{architectureDiagram-3BPJPVTR-B8OoiHF6.js → architectureDiagram-3BPJPVTR-BeKUSqHO.js} +2 -2
  13. package/dist/{blockDiagram-GPEHLZMM-Ddq40SrW.js → blockDiagram-GPEHLZMM-CJeAC_1p.js} +4 -4
  14. package/dist/{c4Diagram-AAUBKEIU-Cf3cjJMq.js → c4Diagram-AAUBKEIU-LoQMp4kW.js} +2 -2
  15. package/dist/{channel-C8Vd7nOK.js → channel-BoLQO6Dk.js} +1 -1
  16. package/dist/{chunk-2J33WTMH-Ck31ftjD.js → chunk-2J33WTMH-D1vw38h5.js} +1 -1
  17. package/dist/{chunk-4BX2VUAB-BJOkbq4i.js → chunk-4BX2VUAB-BFSVnsyi.js} +1 -1
  18. package/dist/{chunk-55IACEB6-lNZxrJyO.js → chunk-55IACEB6-D13UaCP1.js} +1 -1
  19. package/dist/{chunk-727SXJPM-mEDRtdd4.js → chunk-727SXJPM-BCcz4POX.js} +5 -5
  20. package/dist/{chunk-AQP2D5EJ-C1MU-m_K.js → chunk-AQP2D5EJ-DTOfpg2m.js} +3 -3
  21. package/dist/{chunk-FMBD7UC4-Pmfg_1nq.js → chunk-FMBD7UC4-XGRN-sFg.js} +1 -1
  22. package/dist/{chunk-ND2GUHAM-CipPchY0.js → chunk-ND2GUHAM-DSgp1I9F.js} +1 -1
  23. package/dist/{chunk-QZHKN3VN-BvE9EC7r.js → chunk-QZHKN3VN-DQl3-kKo.js} +1 -1
  24. package/dist/{classDiagram-v2-Q7XG4LA2-BM5OaktU.js → classDiagram-4FO5ZUOK-CI-4bhme.js} +2 -2
  25. package/dist/{classDiagram-4FO5ZUOK-BM5OaktU.js → classDiagram-v2-Q7XG4LA2-CI-4bhme.js} +2 -2
  26. package/dist/components.js +2222 -2110
  27. package/dist/composables.js +2 -2
  28. package/dist/{cose-bilkent-S5V4N54A-nmO7LFhz.js → cose-bilkent-S5V4N54A-CU1K-fx3.js} +1 -1
  29. package/dist/{dagre-BM42HDAG-D3xhjRxX.js → dagre-BM42HDAG-HIHsvvPF.js} +3 -3
  30. package/dist/{diagram-2AECGRRQ-kCJcuZOT.js → diagram-2AECGRRQ-XlYRVMia.js} +2 -2
  31. package/dist/{diagram-5GNKFQAL-Bdr1oGkv.js → diagram-5GNKFQAL-BeA9dVE2.js} +3 -3
  32. package/dist/{diagram-KO2AKTUF-CeBpcrbw.js → diagram-KO2AKTUF-D501LuyG.js} +2 -2
  33. package/dist/{diagram-LMA3HP47-C5oYYzCp.js → diagram-LMA3HP47-ClkmdOf_.js} +2 -2
  34. package/dist/{diagram-OG6HWLK6-CNzZuxZL.js → diagram-OG6HWLK6-30O5epks.js} +3 -3
  35. package/dist/{erDiagram-TEJ5UH35-MWNh4yWB.js → erDiagram-TEJ5UH35-Dk5azNFu.js} +4 -4
  36. package/dist/{flowDiagram-I6XJVG4X-DcREbXha.js → flowDiagram-I6XJVG4X-C4K9bB2d.js} +6 -6
  37. package/dist/{ganttDiagram-6RSMTGT7-DGZUsfa4.js → ganttDiagram-6RSMTGT7-sFuSkRH3.js} +2 -2
  38. package/dist/{gitGraphDiagram-PVQCEYII-DhpcTOAS.js → gitGraphDiagram-PVQCEYII-CC4Kf_0S.js} +3 -3
  39. package/dist/{graph-CXU7Rv38.js → graph-BBr12s4M.js} +1 -1
  40. package/dist/index.js +124 -122
  41. package/dist/{infoDiagram-5YYISTIA-CVZBlZ8R.js → infoDiagram-5YYISTIA-PObcwLKW.js} +1 -1
  42. package/dist/{ishikawaDiagram-YF4QCWOH-Bjyc47Lv.js → ishikawaDiagram-YF4QCWOH-B93dpm60.js} +1 -1
  43. package/dist/{journeyDiagram-JHISSGLW-e2G_PVGF.js → journeyDiagram-JHISSGLW-Z0_jIQ5z.js} +4 -4
  44. package/dist/{kanban-definition-UN3LZRKU-CKOBjcK9.js → kanban-definition-UN3LZRKU-BicW7pfZ.js} +2 -2
  45. package/dist/{layout-CBS27QDo.js → layout-jm5q2dTB.js} +2 -2
  46. package/dist/{linear-UyXZcrYY.js → linear-Bv4EbUf4.js} +1 -1
  47. package/dist/{mermaid.core-BeKK51C9.js → mermaid.core-BN0BM26i.js} +34 -34
  48. package/dist/{mindmap-definition-RKZ34NQL-T6_bnhal.js → mindmap-definition-RKZ34NQL-Ba85mo62.js} +3 -3
  49. package/dist/{pieDiagram-4H26LBE5-GGANuPvf.js → pieDiagram-4H26LBE5-CfU3ahlI.js} +3 -3
  50. package/dist/{quadrantDiagram-W4KKPZXB-BAtVKEgW.js → quadrantDiagram-W4KKPZXB-BPTjR1PA.js} +2 -2
  51. package/dist/record.js +2 -2
  52. package/dist/{requirementDiagram-4Y6WPE33-C2oozBsJ.js → requirementDiagram-4Y6WPE33-DVfyUAUL.js} +3 -3
  53. package/dist/{sankeyDiagram-5OEKKPKP-Bfc4Y-JM.js → sankeyDiagram-5OEKKPKP-B_9c0VJt.js} +1 -1
  54. package/dist/{sequenceDiagram-3UESZ5HK-e9yMBU3K.js → sequenceDiagram-3UESZ5HK-BFSDCMig.js} +3 -3
  55. package/dist/{stateDiagram-AJRCARHV-D1vciiPs.js → stateDiagram-AJRCARHV-DNCya3UT.js} +4 -4
  56. package/dist/{stateDiagram-v2-BHNVJYJU-DMXm3rUm.js → stateDiagram-v2-BHNVJYJU-BlmsFnk2.js} +2 -2
  57. package/dist/{timeline-definition-PNZ67QCA-Cg7TL_0Q.js → timeline-definition-PNZ67QCA-B297WQKg.js} +2 -2
  58. package/dist/{useFieldRendering-JFnqNEWH.js → useFieldRendering-DQN_MbSg.js} +1 -1
  59. package/dist/{useVarHelpers-CQQ-zhL0.js → useVarHelpers-D00Za8e6.js} +978 -932
  60. package/dist/validation-Dn_j1py1.js +5712 -0
  61. package/dist/{vennDiagram-CIIHVFJN-BEJdgPK5.js → vennDiagram-CIIHVFJN-gDmDgx6K.js} +1 -1
  62. package/dist/{wardleyDiagram-YWT4CUSO-DLxpx6Lm.js → wardleyDiagram-YWT4CUSO-ek5B-FUl.js} +2 -2
  63. package/dist/{xychartDiagram-2RQKCTM6-CG-K6knD.js → xychartDiagram-2RQKCTM6-DRtlxacH.js} +2 -2
  64. package/package.json +4 -4
  65. package/src/__tests__/record-validation.test.ts +121 -0
  66. package/src/__tests__/required-marker.test.ts +14 -0
  67. package/src/__tests__/resource-form.test.ts +20 -0
  68. package/src/__tests__/resource-ref-field.test.ts +125 -0
  69. package/src/__tests__/var-field-render.test.ts +87 -1
  70. package/src/components/AimdRecorder.vue +11 -1
  71. package/src/components/AimdRecorderEditor.vue +5 -0
  72. package/src/components/AimdRecorderWysiwygFieldHost.vue +1 -0
  73. package/src/components/AimdRecorderWysiwygSurface.vue +5 -0
  74. package/src/components/AimdResourceForm.vue +129 -0
  75. package/src/components/AimdResourceRefField.vue +393 -0
  76. package/src/components/AimdVarField.vue +41 -3
  77. package/src/components/index.ts +4 -0
  78. package/src/components/recorderMilkdownPlugin.ts +2 -0
  79. package/src/composables/__tests__/useVarHelpers.test.ts +96 -0
  80. package/src/composables/useVarHelpers.ts +91 -4
  81. package/src/index.ts +12 -1
  82. package/src/locales.ts +57 -0
  83. package/src/record/validation.ts +145 -11
  84. package/src/styles/recorder.css +8 -0
  85. package/src/types.ts +30 -1
  86. package/dist/validation-DSn_Ttx_.js +0 -5629
@@ -1,6 +1,6 @@
1
- import { getAimdRendererQuizTypeLabel as Ab, parseAndExtract as Eb } from "@airalogy/aimd-renderer";
2
- import { defineComponent as qn, computed as Xe, ref as ye, watch as Pe, openBlock as Z, createBlock as Wc, Teleport as Jp, createElementBlock as ie, withModifiers as ys, createElementVNode as _, normalizeStyle as jr, createTextVNode as fn, toDisplayString as K, Fragment as We, renderList as zn, normalizeClass as ao, withDirectives as Ae, vModelText as qe, createCommentVNode as De, vModelSelect as jl, vModelRadio as Ib, vModelCheckbox as Nb, onMounted as ul, onBeforeUnmount as Gp, inject as jc, createVNode as Lr, provide as Ob, onUnmounted as Yp, h as Se, shallowRef as pi, createApp as Rb, toRef as Db, nextTick as hi, unref as mn, withCtx as _b, vShow as yf } from "vue";
3
- import { bg as Lb } from "./useVarHelpers-CQQ-zhL0.js";
1
+ import { getAimdRendererQuizTypeLabel as Ab, parseAndExtract as Ib } from "@airalogy/aimd-renderer";
2
+ import { defineComponent as qn, computed as Xe, ref as ye, watch as Pe, openBlock as Z, createBlock as Wc, Teleport as Jp, createElementBlock as ie, withModifiers as ys, createElementVNode as _, normalizeStyle as jr, createTextVNode as fn, toDisplayString as K, Fragment as We, renderList as zn, normalizeClass as ao, withDirectives as Ae, vModelText as qe, createCommentVNode as De, vModelSelect as jl, vModelRadio as Eb, vModelCheckbox as Nb, onMounted as ul, onBeforeUnmount as Gp, inject as jc, createVNode as Lr, provide as Ob, onUnmounted as Yp, h as Se, shallowRef as pi, createApp as Rb, toRef as Db, nextTick as hi, unref as mn, withCtx as _b, vShow as yf } from "vue";
3
+ import { bi as Lb } from "./useVarHelpers-D00Za8e6.js";
4
4
  import "./useCodeBlockRendering-D2viVPtA.js";
5
5
  import { restoreAimdInlineTemplates as Uc, protectAimdInlineTemplates as Qp } from "@airalogy/aimd-core";
6
6
  import { g as Pb } from "./_commonjsHelpers-ByX85dGu.js";
@@ -122,6 +122,21 @@ const Fb = {
122
122
  noMatches: "No matching entities",
123
123
  searchFailed: "Entity search failed."
124
124
  },
125
+ resourceRef: {
126
+ availability: "Availability",
127
+ available: "Available",
128
+ lot: "Lot",
129
+ container: "Container",
130
+ quantity: "Quantity",
131
+ unit: "Unit",
132
+ booking: "Booking",
133
+ selectLot: "Select a lot",
134
+ selectContainer: "Select a container",
135
+ selectBooking: "Select a time slot",
136
+ availabilityFailed: "Resource availability could not be loaded.",
137
+ prepareOutputFailed: "The output resource could not be prepared.",
138
+ quantityFrom: (t) => `Quantity is read from ${t}.`
139
+ },
125
140
  collector: {
126
141
  snapshot: "Read now",
127
142
  start: "Start collecting",
@@ -174,6 +189,10 @@ const Fb = {
174
189
  numeric: (t, e) => `${t}: ${e}`,
175
190
  type: (t, e) => `${t} must be ${e}.`,
176
191
  format: (t, e) => `${t} must use ${e} format.`,
192
+ resource: (t, e) => `${t}: ${e}`,
193
+ resourceInvalid: "Select a valid resource.",
194
+ resourceContainerRequired: "A container must be selected.",
195
+ resourceBookingRequired: "An equipment booking must be selected.",
177
196
  schema: (t, e) => `${t}: ${e}`,
178
197
  tableCell: (t, e) => `Row ${t}, ${e}`
179
198
  },
@@ -357,6 +376,21 @@ const Fb = {
357
376
  noMatches: "没有匹配的实体",
358
377
  searchFailed: "实体搜索失败。"
359
378
  },
379
+ resourceRef: {
380
+ availability: "可用情况",
381
+ available: "可用量",
382
+ lot: "批次",
383
+ container: "容器",
384
+ quantity: "数量",
385
+ unit: "单位",
386
+ booking: "设备预约",
387
+ selectLot: "选择批次",
388
+ selectContainer: "选择容器",
389
+ selectBooking: "选择可用时段",
390
+ availabilityFailed: "无法读取资源可用情况。",
391
+ prepareOutputFailed: "无法准备产出资源。",
392
+ quantityFrom: (t) => `数量读取自 ${t}。`
393
+ },
360
394
  collector: {
361
395
  snapshot: "立即采集",
362
396
  start: "开始采集",
@@ -409,6 +443,10 @@ const Fb = {
409
443
  numeric: (t, e) => `${t}:${e}`,
410
444
  type: (t, e) => `${t}必须是${e}类型。`,
411
445
  format: (t, e) => `${t}必须使用 ${e} 格式。`,
446
+ resource: (t, e) => `${t}:${e}`,
447
+ resourceInvalid: "请选择有效资源。",
448
+ resourceContainerRequired: "必须选择容器。",
449
+ resourceBookingRequired: "必须选择设备预约时段。",
412
450
  schema: (t, e) => `${t}:${e}`,
413
451
  tableCell: (t, e) => `第 ${t} 行,${e}`
414
452
  },
@@ -995,7 +1033,7 @@ function Jc(t, e, n, r) {
995
1033
  function fk(t) {
996
1034
  return Array.isArray(t) ? t : typeof t == "number" ? [dk, t] : t == null ? rm : [t];
997
1035
  }
998
- function Ii(t, e, n, r) {
1036
+ function Ei(t, e, n, r) {
999
1037
  let i, o, s;
1000
1038
  typeof e == "function" && typeof n != "function" ? (o = void 0, s = e, i = n) : (o = e, s = n, i = r), Jc(t, o, l, i);
1001
1039
  function l(a, c) {
@@ -1320,14 +1358,14 @@ class Ak {
1320
1358
  #l;
1321
1359
  #i;
1322
1360
  }
1323
- class Ek {
1361
+ class Ik {
1324
1362
  /// Create a timer type with a name and a timeout.
1325
1363
  /// The name should be unique in the clock.
1326
1364
  constructor(e, n = 3e3) {
1327
1365
  this.create = (r) => new Ak(r, this), this.id = /* @__PURE__ */ Symbol(`Timer-${e}`), this.name = e, this.timeout = n;
1328
1366
  }
1329
1367
  }
1330
- const Tn = (t, e = 3e3) => new Ek(t, e);
1368
+ const Tn = (t, e = 3e3) => new Ik(t, e);
1331
1369
  function Qe(t) {
1332
1370
  this.content = t;
1333
1371
  }
@@ -1965,7 +2003,7 @@ function cm(t, e, n, r) {
1965
2003
  let l = cm(s.content, e - o - 1, n, s);
1966
2004
  return l && t.replaceChild(i, s.copy(l));
1967
2005
  }
1968
- function Ik(t, e, n) {
2006
+ function Ek(t, e, n) {
1969
2007
  if (n.openStart > t.depth)
1970
2008
  throw new Ws("Inserted content deeper than insertion position");
1971
2009
  if (t.depth - n.openStart != e.depth - n.openEnd)
@@ -2485,7 +2523,7 @@ let $n = class Qa {
2485
2523
  [`ReplaceError`](https://prosemirror.net/docs/ref/#model.ReplaceError) is thrown.
2486
2524
  */
2487
2525
  replace(e, n, r) {
2488
- return Ik(this.resolve(e), this.resolve(n), r);
2526
+ return Ek(this.resolve(e), this.resolve(n), r);
2489
2527
  }
2490
2528
  /**
2491
2529
  Find the node directly after the given position.
@@ -3557,13 +3595,13 @@ class dr {
3557
3595
  for (let i in e.marks) {
3558
3596
  let o = e.marks[i].spec.parseDOM;
3559
3597
  o && o.forEach((s) => {
3560
- r(s = Ef(s)), s.mark || s.ignore || s.clearMark || (s.mark = i);
3598
+ r(s = If(s)), s.mark || s.ignore || s.clearMark || (s.mark = i);
3561
3599
  });
3562
3600
  }
3563
3601
  for (let i in e.nodes) {
3564
3602
  let o = e.nodes[i].spec.parseDOM;
3565
3603
  o && o.forEach((s) => {
3566
- r(s = Ef(s)), s.node || s.ignore || s.mark || (s.node = i);
3604
+ r(s = If(s)), s.node || s.ignore || s.mark || (s.node = i);
3567
3605
  });
3568
3606
  }
3569
3607
  return n;
@@ -3823,7 +3861,7 @@ class Af {
3823
3861
  o.match && (o.match = o.match.matchType(e.type));
3824
3862
  let s = ke.none;
3825
3863
  for (let l of i.concat(e.marks))
3826
- (o.type ? o.type.allowsMarkType(l.type) : If(l.type, e.type)) && (s = l.addToSet(s));
3864
+ (o.type ? o.type.allowsMarkType(l.type) : Ef(l.type, e.type)) && (s = l.addToSet(s));
3827
3865
  return o.content.push(e.mark(s)), !0;
3828
3866
  }
3829
3867
  return !1;
@@ -3842,7 +3880,7 @@ class Af {
3842
3880
  let l = Mf(e, o, s.options);
3843
3881
  s.options & uo && s.content.length == 0 && (l |= uo);
3844
3882
  let a = ke.none;
3845
- return r = r.filter((c) => (s.type ? s.type.allowsMarkType(c.type) : If(c.type, e)) ? (a = c.addToSet(a), !1) : !0), this.nodes.push(new ls(e, n, a, i, null, l)), this.open++, r;
3883
+ return r = r.filter((c) => (s.type ? s.type.allowsMarkType(c.type) : Ef(c.type, e)) ? (a = c.addToSet(a), !1) : !0), this.nodes.push(new ls(e, n, a, i, null, l)), this.open++, r;
3846
3884
  }
3847
3885
  // Make sure all nodes above this.open are finished and added to
3848
3886
  // their parents
@@ -3945,13 +3983,13 @@ function Gk(t) {
3945
3983
  function Yk(t, e) {
3946
3984
  return (t.matches || t.msMatchesSelector || t.webkitMatchesSelector || t.mozMatchesSelector).call(t, e);
3947
3985
  }
3948
- function Ef(t) {
3986
+ function If(t) {
3949
3987
  let e = {};
3950
3988
  for (let n in t)
3951
3989
  e[n] = t[n];
3952
3990
  return e;
3953
3991
  }
3954
- function If(t, e) {
3992
+ function Ef(t, e) {
3955
3993
  let n = e.schema.nodes;
3956
3994
  for (let r in n) {
3957
3995
  let i = n[r];
@@ -4607,7 +4645,7 @@ function y0(t, e, n) {
4607
4645
  function b0(t) {
4608
4646
  t.exit("blockQuote");
4609
4647
  }
4610
- const Em = {
4648
+ const Im = {
4611
4649
  name: "characterEscape",
4612
4650
  tokenize: k0
4613
4651
  };
@@ -4620,7 +4658,7 @@ function k0(t, e, n) {
4620
4658
  return o0(o) ? (t.enter("characterEscapeValue"), t.consume(o), t.exit("characterEscapeValue"), t.exit("characterEscape"), e) : n(o);
4621
4659
  }
4622
4660
  }
4623
- const Im = {
4661
+ const Em = {
4624
4662
  name: "characterReference",
4625
4663
  tokenize: w0
4626
4664
  };
@@ -4774,9 +4812,9 @@ function T0(t, e, n) {
4774
4812
  }
4775
4813
  const M0 = {
4776
4814
  name: "codeText",
4777
- previous: E0,
4815
+ previous: I0,
4778
4816
  resolve: A0,
4779
- tokenize: I0
4817
+ tokenize: E0
4780
4818
  };
4781
4819
  function A0(t) {
4782
4820
  let e = t.length - 4, n = 3, r, i;
@@ -4791,10 +4829,10 @@ function A0(t) {
4791
4829
  i === void 0 ? r !== e && t[r][1].type !== "lineEnding" && (i = r) : (r === e || t[r][1].type === "lineEnding") && (t[i][1].type = "codeTextData", r !== i + 2 && (t[i][1].end = t[r - 1][1].end, t.splice(i + 2, r - i - 2), e -= r - i - 2, r = i + 2), i = void 0);
4792
4830
  return t;
4793
4831
  }
4794
- function E0(t) {
4832
+ function I0(t) {
4795
4833
  return t !== 96 || this.events[this.events.length - 1][1].type === "characterEscape";
4796
4834
  }
4797
- function I0(t, e, n) {
4835
+ function E0(t, e, n) {
4798
4836
  let r = 0, i, o;
4799
4837
  return s;
4800
4838
  function s(d) {
@@ -5944,9 +5982,9 @@ function Aw(t) {
5944
5982
  return t.enter("lineEnding"), t.consume(o), t.exit("lineEnding"), e.currentConstruct = void 0, n;
5945
5983
  }
5946
5984
  }
5947
- const Ew = {
5985
+ const Iw = {
5948
5986
  resolveAll: Lm()
5949
- }, Iw = _m("string"), Nw = _m("text");
5987
+ }, Ew = _m("string"), Nw = _m("text");
5950
5988
  function _m(t) {
5951
5989
  return {
5952
5990
  resolveAll: Lm(t === "text" ? Ow : void 0),
@@ -6065,23 +6103,23 @@ const Rw = {
6065
6103
  96: Bf,
6066
6104
  126: Bf
6067
6105
  }, Pw = {
6068
- 38: Im,
6069
- 92: Em
6106
+ 38: Em,
6107
+ 92: Im
6070
6108
  }, zw = {
6071
6109
  [-5]: Ql,
6072
6110
  [-4]: Ql,
6073
6111
  [-3]: Ql,
6074
6112
  33: dw,
6075
- 38: Im,
6113
+ 38: Em,
6076
6114
  42: ec,
6077
6115
  60: [h0, ew],
6078
6116
  91: hw,
6079
- 92: [H0, Em],
6117
+ 92: [H0, Im],
6080
6118
  93: Xc,
6081
6119
  95: ec,
6082
6120
  96: M0
6083
6121
  }, Bw = {
6084
- null: [ec, Ew]
6122
+ null: [ec, Iw]
6085
6123
  }, Fw = {
6086
6124
  null: [42, 95]
6087
6125
  }, $w = {
@@ -6326,7 +6364,7 @@ function jw(t) {
6326
6364
  document: i(a0),
6327
6365
  flow: i(Mw),
6328
6366
  lazy: {},
6329
- string: i(Iw),
6367
+ string: i(Ew),
6330
6368
  text: i(Nw)
6331
6369
  };
6332
6370
  return r;
@@ -6415,7 +6453,7 @@ function Qw(t) {
6415
6453
  autolink: o(Dt),
6416
6454
  autolinkProtocol: V,
6417
6455
  autolinkEmail: V,
6418
- atxHeading: o(I),
6456
+ atxHeading: o(E),
6419
6457
  blockQuote: o(nt),
6420
6458
  characterEscape: V,
6421
6459
  characterReference: V,
@@ -6432,8 +6470,8 @@ function Qw(t) {
6432
6470
  definitionLabelString: s,
6433
6471
  definitionTitleString: s,
6434
6472
  emphasis: o(z),
6435
- hardBreakEscape: o(E),
6436
- hardBreakTrailing: o(E),
6473
+ hardBreakEscape: o(I),
6474
+ hardBreakTrailing: o(I),
6437
6475
  htmlFlow: o(oe, s),
6438
6476
  htmlFlowData: V,
6439
6477
  htmlText: o(oe, s),
@@ -6450,7 +6488,7 @@ function Qw(t) {
6450
6488
  referenceString: s,
6451
6489
  resourceDestinationString: s,
6452
6490
  resourceTitleString: s,
6453
- setextHeading: o(I),
6491
+ setextHeading: o(E),
6454
6492
  strong: o(Zt),
6455
6493
  thematicBreak: o(Yn)
6456
6494
  },
@@ -6847,7 +6885,7 @@ function Qw(t) {
6847
6885
  children: []
6848
6886
  };
6849
6887
  }
6850
- function I() {
6888
+ function E() {
6851
6889
  return {
6852
6890
  type: "heading",
6853
6891
  // @ts-expect-error `depth` will be set later.
@@ -6855,7 +6893,7 @@ function Qw(t) {
6855
6893
  children: []
6856
6894
  };
6857
6895
  }
6858
- function E() {
6896
+ function I() {
6859
6897
  return {
6860
6898
  type: "break"
6861
6899
  };
@@ -7242,7 +7280,7 @@ function ux(t, e, n) {
7242
7280
  }
7243
7281
  function Vm(t, e) {
7244
7282
  let n = !1;
7245
- return Ii(t, function(r) {
7283
+ return Ei(t, function(r) {
7246
7284
  if ("value" in r && /\r?\n|\r/.test(r.value) || r.type === "break")
7247
7285
  return n = !0, Ja;
7248
7286
  }), !!((!t.depth || t.depth < 3) && Yc(t) && (e.options.setext || n));
@@ -7596,10 +7634,10 @@ function Qm(t, e, n, r) {
7596
7634
  function Ax(t, e, n) {
7597
7635
  return n.options.strong || "*";
7598
7636
  }
7599
- function Ex(t, e, n, r) {
7637
+ function Ix(t, e, n, r) {
7600
7638
  return n.safe(t.value, r);
7601
7639
  }
7602
- function Ix(t) {
7640
+ function Ex(t) {
7603
7641
  const e = t.options.ruleRepetition || 3;
7604
7642
  if (e < 3)
7605
7643
  throw new Error(
@@ -7608,7 +7646,7 @@ function Ix(t) {
7608
7646
  return e;
7609
7647
  }
7610
7648
  function Nx(t, e, n) {
7611
- const r = (Ym(n) + (n.options.ruleSpaces ? " " : "")).repeat(Ix(n));
7649
+ const r = (Ym(n) + (n.options.ruleSpaces ? " " : "")).repeat(Ex(n));
7612
7650
  return n.options.ruleSpaces ? r.slice(0, -1) : r;
7613
7651
  }
7614
7652
  const tu = {
@@ -7630,7 +7668,7 @@ const tu = {
7630
7668
  paragraph: Sx,
7631
7669
  root: Tx,
7632
7670
  strong: Qm,
7633
- text: Ex,
7671
+ text: Ix,
7634
7672
  thematicBreak: Nx
7635
7673
  }, Ox = [Rx];
7636
7674
  function Rx(t, e, n, r) {
@@ -9294,7 +9332,7 @@ function yC(t) {
9294
9332
  }
9295
9333
  var Xm = (t) => {
9296
9334
  throw TypeError(t);
9297
- }, Zm = (t, e, n) => e.has(t) || Xm("Cannot " + n), he = (t, e, n) => (Zm(t, e, "read from private field"), n ? n.call(t) : e.get(t)), Le = (t, e, n) => e.has(t) ? Xm("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, n), Ie = (t, e, n, r) => (Zm(t, e, "write to private field"), e.set(t, n), n), hn, Qi, ws, xs, Cs, Xi, Zi, Rn, eo, Ss, vs, to, Ts, no, Ms, As, si, Ar, Es, ro;
9335
+ }, Zm = (t, e, n) => e.has(t) || Xm("Cannot " + n), he = (t, e, n) => (Zm(t, e, "read from private field"), n ? n.call(t) : e.get(t)), Le = (t, e, n) => e.has(t) ? Xm("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, n), Ee = (t, e, n, r) => (Zm(t, e, "write to private field"), e.set(t, n), n), hn, Qi, ws, xs, Cs, Xi, Zi, Rn, eo, Ss, vs, to, Ts, no, Ms, As, si, Ar, Is, ro;
9298
9336
  class eg {
9299
9337
  }
9300
9338
  class tg {
@@ -9327,21 +9365,21 @@ class ru extends eg {
9327
9365
  const ac = class extends tg {
9328
9366
  /// @internal
9329
9367
  constructor(e) {
9330
- super(), Le(this, hn), Le(this, Qi), Le(this, ws), Le(this, xs), Le(this, Cs), Le(this, Xi), Le(this, Zi), Ie(this, hn, ke.none), Ie(this, Qi, (n) => n.isText), Ie(this, ws, (n, r) => {
9368
+ super(), Le(this, hn), Le(this, Qi), Le(this, ws), Le(this, xs), Le(this, Cs), Le(this, Xi), Le(this, Zi), Ee(this, hn, ke.none), Ee(this, Qi, (n) => n.isText), Ee(this, ws, (n, r) => {
9331
9369
  if (he(this, Qi).call(this, n) && he(this, Qi).call(this, r) && ke.sameSet(n.marks, r.marks))
9332
9370
  return this.schema.text(n.text + r.text, n.marks);
9333
- }), Ie(this, xs, (n) => {
9371
+ }), Ee(this, xs, (n) => {
9334
9372
  const r = Object.values({
9335
9373
  ...this.schema.nodes,
9336
9374
  ...this.schema.marks
9337
9375
  }).find((i) => i.spec.parseMarkdown.match(n));
9338
9376
  if (!r) throw bk(n);
9339
9377
  return r;
9340
- }), Ie(this, Cs, (n) => {
9378
+ }), Ee(this, Cs, (n) => {
9341
9379
  const r = he(this, xs).call(this, n);
9342
9380
  r.spec.parseMarkdown.runner(this, n, r);
9343
- }), this.injectRoot = (n, r, i) => (this.openNode(r, i), this.next(n.children), this), this.openNode = (n, r) => (this.open(ru.create(n, [], r)), this), Ie(this, Xi, () => {
9344
- Ie(this, hn, ke.none);
9381
+ }), this.injectRoot = (n, r, i) => (this.openNode(r, i), this.next(n.children), this), this.openNode = (n, r) => (this.open(ru.create(n, [], r)), this), Ee(this, Xi, () => {
9382
+ Ee(this, hn, ke.none);
9345
9383
  const n = this.close();
9346
9384
  return he(this, Zi).call(this, n.type, n.attrs, n.content);
9347
9385
  }), this.closeNode = () => {
@@ -9351,7 +9389,7 @@ const ac = class extends tg {
9351
9389
  console.error(n);
9352
9390
  }
9353
9391
  return this;
9354
- }, Ie(this, Zi, (n, r, i) => {
9392
+ }, Ee(this, Zi, (n, r, i) => {
9355
9393
  const o = n.createAndFill(r, i, he(this, hn));
9356
9394
  if (!o) throw yk(n, r, i);
9357
9395
  return this.push(o), o;
@@ -9364,8 +9402,8 @@ const ac = class extends tg {
9364
9402
  return this;
9365
9403
  }, this.openMark = (n, r) => {
9366
9404
  const i = n.create(r);
9367
- return Ie(this, hn, i.addToSet(he(this, hn))), this;
9368
- }, this.closeMark = (n) => (Ie(this, hn, n.removeFromSet(he(this, hn))), this), this.addText = (n) => {
9405
+ return Ee(this, hn, i.addToSet(he(this, hn))), this;
9406
+ }, this.closeMark = (n) => (Ee(this, hn, n.removeFromSet(he(this, hn))), this), this.addText = (n) => {
9369
9407
  try {
9370
9408
  const r = this.top();
9371
9409
  if (!r) throw im();
@@ -9416,17 +9454,17 @@ let th = cc;
9416
9454
  const kC = (t) => Object.prototype.hasOwnProperty.call(t, "size"), uc = class extends tg {
9417
9455
  /// @internal
9418
9456
  constructor(e) {
9419
- super(), Le(this, Rn), Le(this, eo), Le(this, Ss), Le(this, vs), Le(this, to), Le(this, Ts), Le(this, no), Le(this, Ms), Le(this, As), Le(this, si), Le(this, Ar), Le(this, Es), Le(this, ro), Ie(this, Rn, ke.none), Ie(this, eo, (n) => {
9457
+ super(), Le(this, Rn), Le(this, eo), Le(this, Ss), Le(this, vs), Le(this, to), Le(this, Ts), Le(this, no), Le(this, Ms), Le(this, As), Le(this, si), Le(this, Ar), Le(this, Is), Le(this, ro), Ee(this, Rn, ke.none), Ee(this, eo, (n) => {
9420
9458
  const r = Object.values({
9421
9459
  ...this.schema.nodes,
9422
9460
  ...this.schema.marks
9423
9461
  }).find((i) => i.spec.toMarkdown.match(n));
9424
9462
  if (!r) throw kk(n.type);
9425
9463
  return r;
9426
- }), Ie(this, Ss, (n) => he(this, eo).call(this, n).spec.toMarkdown.runner(this, n)), Ie(this, vs, (n, r) => he(this, eo).call(this, n).spec.toMarkdown.runner(this, n, r)), Ie(this, to, (n) => {
9464
+ }), Ee(this, Ss, (n) => he(this, eo).call(this, n).spec.toMarkdown.runner(this, n)), Ee(this, vs, (n, r) => he(this, eo).call(this, n).spec.toMarkdown.runner(this, n, r)), Ee(this, to, (n) => {
9427
9465
  const { marks: r } = n, i = (l) => l.type.spec.priority ?? 50;
9428
9466
  [...r].sort((l, a) => i(l) - i(a)).every((l) => !he(this, vs).call(this, l, n)) && he(this, Ss).call(this, n), r.forEach((l) => he(this, ro).call(this, l));
9429
- }), Ie(this, Ts, (n, r) => {
9467
+ }), Ee(this, Ts, (n, r) => {
9430
9468
  if (n.type === r || n.children?.length !== 1) return n;
9431
9469
  const i = (a) => {
9432
9470
  if (a.type === r) return a;
@@ -9437,7 +9475,7 @@ const kC = (t) => Object.prototype.hasOwnProperty.call(t, "size"), uc = class ex
9437
9475
  if (!o) return n;
9438
9476
  const s = o.children ? [...o.children] : void 0, l = { ...n, children: s };
9439
9477
  return l.children = s, o.children = [l], o;
9440
- }), Ie(this, no, (n) => {
9478
+ }), Ee(this, no, (n) => {
9441
9479
  const { children: r } = n;
9442
9480
  return r && (n.children = r.reduce((i, o, s) => {
9443
9481
  if (s === 0) return [o];
@@ -9455,13 +9493,13 @@ const kC = (t) => Object.prototype.hasOwnProperty.call(t, "size"), uc = class ex
9455
9493
  }
9456
9494
  return i.concat(o);
9457
9495
  }, [])), n;
9458
- }), Ie(this, Ms, (n) => {
9496
+ }), Ee(this, Ms, (n) => {
9459
9497
  const r = {
9460
9498
  ...n.props,
9461
9499
  type: n.type
9462
9500
  };
9463
9501
  return n.children && (r.children = n.children), n.value && (r.value = n.value), r;
9464
- }), this.openNode = (n, r, i) => (this.open(th.create(n, void 0, r, i)), this), Ie(this, As, (n, r) => {
9502
+ }), this.openNode = (n, r, i) => (this.open(th.create(n, void 0, r, i)), this), Ee(this, As, (n, r) => {
9465
9503
  let i = "", o = "";
9466
9504
  const s = n.children;
9467
9505
  let l = -1, a = -1;
@@ -9485,15 +9523,15 @@ const kC = (t) => Object.prototype.hasOwnProperty.call(t, "size"), uc = class ex
9485
9523
  i.length && he(this, Ar).call(this, "text", void 0, i);
9486
9524
  const u = r();
9487
9525
  return o.length && he(this, Ar).call(this, "text", void 0, o), u;
9488
- }), Ie(this, si, (n = !1) => {
9526
+ }), Ee(this, si, (n = !1) => {
9489
9527
  const r = this.close(), i = () => he(this, Ar).call(this, r.type, r.children, r.value, r.props);
9490
9528
  return n ? he(this, As).call(this, r, i) : i();
9491
- }), this.closeNode = () => (he(this, si).call(this), this), Ie(this, Ar, (n, r, i, o) => {
9529
+ }), this.closeNode = () => (he(this, si).call(this), this), Ee(this, Ar, (n, r, i, o) => {
9492
9530
  const s = th.create(n, r, i, o), l = he(this, no).call(this, he(this, Ms).call(this, s));
9493
9531
  return this.push(l), l;
9494
- }), this.addNode = (n, r, i, o) => (he(this, Ar).call(this, n, r, i, o), this), Ie(this, Es, (n, r, i, o) => n.isInSet(he(this, Rn)) ? this : (Ie(this, Rn, n.addToSet(he(this, Rn))), this.openNode(r, i, { ...o, isMark: !0 }))), Ie(this, ro, (n) => {
9495
- n.isInSet(he(this, Rn)) && (Ie(this, Rn, n.type.removeFromSet(he(this, Rn))), he(this, si).call(this, !0));
9496
- }), this.withMark = (n, r, i, o) => (he(this, Es).call(this, n, r, i, o), this), this.closeMark = (n) => (he(this, ro).call(this, n), this), this.build = () => {
9532
+ }), this.addNode = (n, r, i, o) => (he(this, Ar).call(this, n, r, i, o), this), Ee(this, Is, (n, r, i, o) => n.isInSet(he(this, Rn)) ? this : (Ee(this, Rn, n.addToSet(he(this, Rn))), this.openNode(r, i, { ...o, isMark: !0 }))), Ee(this, ro, (n) => {
9533
+ n.isInSet(he(this, Rn)) && (Ee(this, Rn, n.type.removeFromSet(he(this, Rn))), he(this, si).call(this, !0));
9534
+ }), this.withMark = (n, r, i, o) => (he(this, Is).call(this, n, r, i, o), this), this.closeMark = (n) => (he(this, ro).call(this, n), this), this.build = () => {
9497
9535
  let n = null;
9498
9536
  do
9499
9537
  n = he(this, si).call(this);
@@ -9515,7 +9553,7 @@ Ms = /* @__PURE__ */ new WeakMap();
9515
9553
  As = /* @__PURE__ */ new WeakMap();
9516
9554
  si = /* @__PURE__ */ new WeakMap();
9517
9555
  Ar = /* @__PURE__ */ new WeakMap();
9518
- Es = /* @__PURE__ */ new WeakMap();
9556
+ Is = /* @__PURE__ */ new WeakMap();
9519
9557
  ro = /* @__PURE__ */ new WeakMap();
9520
9558
  uc.create = (t, e) => {
9521
9559
  const n = new uc(t);
@@ -9532,7 +9570,7 @@ function nh(t) {
9532
9570
  function CC(t) {
9533
9571
  return (t - (t & ng)) / rg;
9534
9572
  }
9535
- const ig = 1, og = 2, Is = 4, sg = 8;
9573
+ const ig = 1, og = 2, Es = 4, sg = 8;
9536
9574
  class dc {
9537
9575
  /**
9538
9576
  @internal
@@ -9552,13 +9590,13 @@ class dc {
9552
9590
  Tells you whether the token before the mapped position was deleted.
9553
9591
  */
9554
9592
  get deletedBefore() {
9555
- return (this.delInfo & (ig | Is)) > 0;
9593
+ return (this.delInfo & (ig | Es)) > 0;
9556
9594
  }
9557
9595
  /**
9558
9596
  True when the token after the mapped position was deleted.
9559
9597
  */
9560
9598
  get deletedAfter() {
9561
- return (this.delInfo & (og | Is)) > 0;
9599
+ return (this.delInfo & (og | Es)) > 0;
9562
9600
  }
9563
9601
  /**
9564
9602
  Tells whether any of the steps mapped through deletes across the
@@ -9566,7 +9604,7 @@ class dc {
9566
9604
  position).
9567
9605
  */
9568
9606
  get deletedAcross() {
9569
- return (this.delInfo & Is) > 0;
9607
+ return (this.delInfo & Es) > 0;
9570
9608
  }
9571
9609
  }
9572
9610
  class Lt {
@@ -9609,7 +9647,7 @@ class Lt {
9609
9647
  let f = c ? e == a ? -1 : e == d ? 1 : n : n, h = a + i + (f < 0 ? 0 : u);
9610
9648
  if (r)
9611
9649
  return h;
9612
- let p = e == (n < 0 ? a : d) ? null : xC(l / 3, e - a), m = e == a ? og : e == d ? ig : Is;
9650
+ let p = e == (n < 0 ? a : d) ? null : xC(l / 3, e - a), m = e == a ? og : e == d ? ig : Es;
9613
9651
  return (n < 0 ? e != a : e != d) && (m |= sg), new dc(h, m, p);
9614
9652
  }
9615
9653
  i += u - c;
@@ -9666,7 +9704,7 @@ class Lt {
9666
9704
  }
9667
9705
  }
9668
9706
  Lt.empty = new Lt([]);
9669
- class Eo {
9707
+ class Io {
9670
9708
  /**
9671
9709
  Create a new mapping with the given position maps.
9672
9710
  */
@@ -9683,7 +9721,7 @@ class Eo {
9683
9721
  Create a mapping that maps only through a part of this one.
9684
9722
  */
9685
9723
  slice(e = 0, n = this.maps.length) {
9686
- return new Eo(this._maps, this.mirror, e, n);
9724
+ return new Io(this._maps, this.mirror, e, n);
9687
9725
  }
9688
9726
  /**
9689
9727
  Add a step map to the end of this mapping. If `mirrors` is
@@ -9734,7 +9772,7 @@ class Eo {
9734
9772
  Create an inverted version of this mapping.
9735
9773
  */
9736
9774
  invert() {
9737
- let e = new Eo();
9775
+ let e = new Io();
9738
9776
  return e.appendMappingInverted(this), e;
9739
9777
  }
9740
9778
  /**
@@ -10227,7 +10265,7 @@ function MC(t, e, n) {
10227
10265
  t.step(new st(a, c, s, l, new q(u.append(f), d, h), u.size - d, !0));
10228
10266
  }
10229
10267
  function su(t, e, n = null, r = t) {
10230
- let i = AC(t, e), o = i && EC(r, e);
10268
+ let i = AC(t, e), o = i && IC(r, e);
10231
10269
  return o ? i.map(rh).concat({ type: e, attrs: n }).concat(o.map(rh)) : null;
10232
10270
  }
10233
10271
  function rh(t) {
@@ -10240,7 +10278,7 @@ function AC(t, e) {
10240
10278
  let s = o.length ? o[0] : e;
10241
10279
  return n.canReplaceWith(r, i, s) ? o : null;
10242
10280
  }
10243
- function EC(t, e) {
10281
+ function IC(t, e) {
10244
10282
  let { parent: n, startIndex: r, endIndex: i } = t, o = n.child(r), s = e.contentMatch.findWrapping(o.type);
10245
10283
  if (!s)
10246
10284
  return null;
@@ -10249,7 +10287,7 @@ function EC(t, e) {
10249
10287
  a = a.matchType(n.child(c).type);
10250
10288
  return !a || !a.validEnd ? null : s;
10251
10289
  }
10252
- function IC(t, e, n) {
10290
+ function EC(t, e, n) {
10253
10291
  let r = P.empty;
10254
10292
  for (let s = n.length - 1; s >= 0; s--) {
10255
10293
  if (r.size) {
@@ -10737,7 +10775,7 @@ class mi extends at {
10737
10775
  }
10738
10776
  }
10739
10777
  at.jsonID("attr", mi);
10740
- class Io extends at {
10778
+ class Eo extends at {
10741
10779
  /**
10742
10780
  Construct an attribute step.
10743
10781
  */
@@ -10756,7 +10794,7 @@ class Io extends at {
10756
10794
  return Lt.empty;
10757
10795
  }
10758
10796
  invert(e) {
10759
- return new Io(this.attr, e.attrs[this.attr]);
10797
+ return new Eo(this.attr, e.attrs[this.attr]);
10760
10798
  }
10761
10799
  map(e) {
10762
10800
  return this;
@@ -10767,10 +10805,10 @@ class Io extends at {
10767
10805
  static fromJSON(e, n) {
10768
10806
  if (typeof n.attr != "string")
10769
10807
  throw new RangeError("Invalid input for DocAttrStep.fromJSON");
10770
- return new Io(n.attr, n.value);
10808
+ return new Eo(n.attr, n.value);
10771
10809
  }
10772
10810
  }
10773
- at.jsonID("docAttr", Io);
10811
+ at.jsonID("docAttr", Eo);
10774
10812
  let Ci = class extends Error {
10775
10813
  };
10776
10814
  Ci = function t(e) {
@@ -10785,7 +10823,7 @@ class hg {
10785
10823
  Create a transform that starts with the given document.
10786
10824
  */
10787
10825
  constructor(e) {
10788
- this.doc = e, this.steps = [], this.docs = [], this.mapping = new Eo();
10826
+ this.doc = e, this.steps = [], this.docs = [], this.mapping = new Io();
10789
10827
  }
10790
10828
  /**
10791
10829
  The starting document.
@@ -10931,7 +10969,7 @@ class hg {
10931
10969
  probably be computed with [`findWrapping`](https://prosemirror.net/docs/ref/#transform.findWrapping).
10932
10970
  */
10933
10971
  wrap(e, n) {
10934
- return IC(this, e, n), this;
10972
+ return EC(this, e, n), this;
10935
10973
  }
10936
10974
  /**
10937
10975
  Set the type of all textblocks (partly) between `from` and `to` to
@@ -10959,7 +10997,7 @@ class hg {
10959
10997
  Set a single attribute on the document to a new value.
10960
10998
  */
10961
10999
  setDocAttribute(e, n) {
10962
- return this.step(new Io(e, n)), this;
11000
+ return this.step(new Eo(e, n)), this;
10963
11001
  }
10964
11002
  /**
10965
11003
  Add a mark to the node at position `pos`.
@@ -11619,7 +11657,7 @@ class ua {
11619
11657
  });
11620
11658
  }
11621
11659
  }
11622
- class Ir {
11660
+ class Er {
11623
11661
  /**
11624
11662
  @internal
11625
11663
  */
@@ -11694,7 +11732,7 @@ class Ir {
11694
11732
  applyInner(e) {
11695
11733
  if (!e.before.eq(this.doc))
11696
11734
  throw new RangeError("Applying a mismatched transaction");
11697
- let n = new Ir(this.config), r = this.config.fields;
11735
+ let n = new Er(this.config), r = this.config.fields;
11698
11736
  for (let i = 0; i < r.length; i++) {
11699
11737
  let o = r[i];
11700
11738
  n[o.name] = o.apply(e, this[o.name], this, n);
@@ -11711,7 +11749,7 @@ class Ir {
11711
11749
  Create a new state.
11712
11750
  */
11713
11751
  static create(e) {
11714
- let n = new ua(e.doc ? e.doc.type.schema : e.schema, e.plugins), r = new Ir(n);
11752
+ let n = new ua(e.doc ? e.doc.type.schema : e.schema, e.plugins), r = new Er(n);
11715
11753
  for (let i = 0; i < n.fields.length; i++)
11716
11754
  r[n.fields[i].name] = n.fields[i].init(e, r);
11717
11755
  return r;
@@ -11725,7 +11763,7 @@ class Ir {
11725
11763
  configuration object..
11726
11764
  */
11727
11765
  reconfigure(e) {
11728
- let n = new ua(this.schema, e.plugins), r = n.fields, i = new Ir(n);
11766
+ let n = new ua(this.schema, e.plugins), r = n.fields, i = new Er(n);
11729
11767
  for (let o = 0; o < r.length; o++) {
11730
11768
  let s = r[o].name;
11731
11769
  i[s] = this.hasOwnProperty(s) ? this[s] : r[o].init(e, i);
@@ -11762,7 +11800,7 @@ class Ir {
11762
11800
  throw new RangeError("Invalid input for EditorState.fromJSON");
11763
11801
  if (!e.schema)
11764
11802
  throw new RangeError("Required config field 'schema' missing");
11765
- let i = new ua(e.schema, e.plugins), o = new Ir(i);
11803
+ let i = new ua(e.schema, e.plugins), o = new Er(i);
11766
11804
  return i.fields.forEach((s) => {
11767
11805
  if (s.name == "doc")
11768
11806
  o.doc = $n.fromJSON(e.schema, n.doc);
@@ -12213,7 +12251,7 @@ const Pn = {
12213
12251
  for (let t in Pn)
12214
12252
  Sg[t] = Pn[t];
12215
12253
  const uS = typeof navigator < "u" ? /Mac|iP(hone|[oa]d)/.test(navigator.platform) : typeof os < "u" && os.platform ? os.platform() == "darwin" : !1, dS = uS ? Sg : Pn;
12216
- class Et {
12254
+ class It {
12217
12255
  /**
12218
12256
  Create an input rule. The rule applies when the user typed
12219
12257
  something and the text directly in front of the cursor matches
@@ -12267,14 +12305,14 @@ const hS = (t, e) => {
12267
12305
  }
12268
12306
  return !1;
12269
12307
  };
12270
- new Et(/--$/, "—", { inCodeMark: !1 });
12271
- new Et(/\.\.\.$/, "…", { inCodeMark: !1 });
12272
- new Et(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(")$/, "“", { inCodeMark: !1 });
12273
- new Et(/"$/, "”", { inCodeMark: !1 });
12274
- new Et(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(')$/, "‘", { inCodeMark: !1 });
12275
- new Et(/'$/, "’", { inCodeMark: !1 });
12308
+ new It(/--$/, "—", { inCodeMark: !1 });
12309
+ new It(/\.\.\.$/, "…", { inCodeMark: !1 });
12310
+ new It(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(")$/, "“", { inCodeMark: !1 });
12311
+ new It(/"$/, "”", { inCodeMark: !1 });
12312
+ new It(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(')$/, "‘", { inCodeMark: !1 });
12313
+ new It(/'$/, "’", { inCodeMark: !1 });
12276
12314
  function fu(t, e, n = null, r) {
12277
- return new Et(t, (i, o, s, l) => {
12315
+ return new It(t, (i, o, s, l) => {
12278
12316
  let a = n instanceof Function ? n(o) : n, c = i.tr.delete(s, l), u = c.doc.resolve(s), d = u.blockRange(), f = d && su(d, e, a);
12279
12317
  if (!f)
12280
12318
  return null;
@@ -12284,12 +12322,12 @@ function fu(t, e, n = null, r) {
12284
12322
  });
12285
12323
  }
12286
12324
  function vg(t, e, n = null) {
12287
- return new Et(t, (r, i, o, s) => {
12325
+ return new It(t, (r, i, o, s) => {
12288
12326
  let l = r.doc.resolve(o), a = n instanceof Function ? n(i) : n;
12289
12327
  return l.node(-1).canReplaceWith(l.index(-1), l.indexAfter(-1), e) ? r.tr.delete(o, s).setBlockType(o, o, e, a) : null;
12290
12328
  });
12291
12329
  }
12292
- const hr = typeof navigator < "u" ? navigator : null, dh = typeof document < "u" ? document : null, br = hr && hr.userAgent || "", hc = /Edge\/(\d+)/.exec(br), Tg = /MSIE \d/.exec(br), pc = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(br), Sl = !!(Tg || pc || hc), pS = Tg ? document.documentMode : pc ? +pc[1] : hc ? +hc[1] : 0, Mg = !Sl && /gecko\/(\d+)/i.test(br), mS = Mg && +(/Firefox\/(\d+)/.exec(br) || [0, 0])[1], mc = !Sl && /Chrome\/(\d+)/.exec(br), gS = !!mc, yS = mc ? +mc[1] : 0, Ag = !Sl && !!hr && /Apple Computer/.test(hr.vendor), Eg = Ag && (/Mobile\/\w+/.test(br) || !!hr && hr.maxTouchPoints > 2), bS = Eg || (hr ? /Mac/.test(hr.platform) : !1), kS = /Android \d/.test(br), Ig = !!dh && "webkitFontSmoothing" in dh.documentElement.style, wS = Ig ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
12330
+ const hr = typeof navigator < "u" ? navigator : null, dh = typeof document < "u" ? document : null, br = hr && hr.userAgent || "", hc = /Edge\/(\d+)/.exec(br), Tg = /MSIE \d/.exec(br), pc = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(br), Sl = !!(Tg || pc || hc), pS = Tg ? document.documentMode : pc ? +pc[1] : hc ? +hc[1] : 0, Mg = !Sl && /gecko\/(\d+)/i.test(br), mS = Mg && +(/Firefox\/(\d+)/.exec(br) || [0, 0])[1], mc = !Sl && /Chrome\/(\d+)/.exec(br), gS = !!mc, yS = mc ? +mc[1] : 0, Ag = !Sl && !!hr && /Apple Computer/.test(hr.vendor), Ig = Ag && (/Mobile\/\w+/.test(br) || !!hr && hr.maxTouchPoints > 2), bS = Ig || (hr ? /Mac/.test(hr.platform) : !1), kS = /Android \d/.test(br), Eg = !!dh && "webkitFontSmoothing" in dh.documentElement.style, wS = Eg ? +(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent) || [0, 0])[1] : 0;
12293
12331
  var us = /* @__PURE__ */ Object.freeze({
12294
12332
  __proto__: null,
12295
12333
  android: kS,
@@ -12299,10 +12337,10 @@ var us = /* @__PURE__ */ Object.freeze({
12299
12337
  gecko_version: mS,
12300
12338
  ie: Sl,
12301
12339
  ie_version: pS,
12302
- ios: Eg,
12340
+ ios: Ig,
12303
12341
  mac: bS,
12304
12342
  safari: Ag,
12305
- webkit: Ig,
12343
+ webkit: Eg,
12306
12344
  webkit_version: wS
12307
12345
  });
12308
12346
  function ha(t, e, n, r, i, o) {
@@ -12357,7 +12395,7 @@ function CS({ rules: t }) {
12357
12395
  return e;
12358
12396
  }
12359
12397
  function Wo(t, e, n = {}) {
12360
- return new Et(t, (r, i, o, s) => {
12398
+ return new It(t, (r, i, o, s) => {
12361
12399
  var l, a, c, u;
12362
12400
  const { tr: d } = r, f = i.length;
12363
12401
  let h = i[f - 1], p = i[0], m = [], g = s;
@@ -12442,7 +12480,7 @@ function AS(t, e) {
12442
12480
  depth: r.depth
12443
12481
  };
12444
12482
  }
12445
- const ES = (t, e) => {
12483
+ const IS = (t, e) => {
12446
12484
  const { selection: n, doc: r } = t;
12447
12485
  if (n instanceof ne)
12448
12486
  return {
@@ -12536,14 +12574,14 @@ var pr = {
12536
12574
  220: "|",
12537
12575
  221: "}",
12538
12576
  222: '"'
12539
- }, IS = typeof navigator < "u" && /Mac/.test(navigator.platform), NS = typeof navigator < "u" && /MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);
12577
+ }, ES = typeof navigator < "u" && /Mac/.test(navigator.platform), NS = typeof navigator < "u" && /MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);
12540
12578
  for (var Ze = 0; Ze < 10; Ze++) pr[48 + Ze] = pr[96 + Ze] = String(Ze);
12541
12579
  for (var Ze = 1; Ze <= 24; Ze++) pr[Ze + 111] = "F" + Ze;
12542
12580
  for (var Ze = 65; Ze <= 90; Ze++)
12543
12581
  pr[Ze] = String.fromCharCode(Ze + 32), Ys[Ze] = String.fromCharCode(Ze);
12544
12582
  for (var pa in pr) Ys.hasOwnProperty(pa) || (Ys[pa] = pr[pa]);
12545
12583
  function OS(t) {
12546
- var e = IS && t.metaKey && t.shiftKey && !t.ctrlKey && !t.altKey || NS && t.shiftKey && t.key && t.key.length == 1 || t.key == "Unidentified", n = !e && t.key || (t.shiftKey ? Ys : pr)[t.keyCode] || t.key || "Unidentified";
12584
+ var e = ES && t.metaKey && t.shiftKey && !t.ctrlKey && !t.altKey || NS && t.shiftKey && t.key && t.key.length == 1 || t.key == "Unidentified", n = !e && t.key || (t.shiftKey ? Ys : pr)[t.keyCode] || t.key || "Unidentified";
12547
12585
  return n == "Esc" && (n = "Escape"), n == "Del" && (n = "Delete"), n == "Left" && (n = "ArrowLeft"), n == "Up" && (n = "ArrowUp"), n == "Right" && (n = "ArrowRight"), n == "Down" && (n = "ArrowDown"), n;
12548
12586
  }
12549
12587
  const RS = typeof navigator < "u" && /Mac|iP(hone|[oa]d)/.test(navigator.platform), DS = typeof navigator < "u" && /Win/.test(navigator.platform);
@@ -12691,7 +12729,7 @@ function jo(t) {
12691
12729
  const vl = function(t) {
12692
12730
  return t.focusNode && Gr(t.focusNode, t.focusOffset, t.anchorNode, t.anchorOffset);
12693
12731
  };
12694
- function Er(t, e) {
12732
+ function Ir(t, e) {
12695
12733
  let n = document.createEvent("Event");
12696
12734
  return n.initEvent("keydown", !0, !0), n.keyCode = t, n.key = n.code = e, n;
12697
12735
  }
@@ -14360,7 +14398,7 @@ function Sc(t, e, n) {
14360
14398
  t.state == i && Vn(t);
14361
14399
  }, 50);
14362
14400
  }
14363
- function Eh(t, e) {
14401
+ function Ih(t, e) {
14364
14402
  let n = t.state.doc.resolve(e);
14365
14403
  if (!(tt || Lg) && n.parent.inlineContent) {
14366
14404
  let i = t.coordsAtPos(e);
@@ -14377,7 +14415,7 @@ function Eh(t, e) {
14377
14415
  }
14378
14416
  return getComputedStyle(t.dom).direction == "rtl" ? "rtl" : "ltr";
14379
14417
  }
14380
- function Ih(t, e, n) {
14418
+ function Eh(t, e, n) {
14381
14419
  let r = t.state.selection;
14382
14420
  if (r instanceof ae && !r.empty || n.indexOf("s") > -1 || Wt && n.indexOf("m") > -1)
14383
14421
  return !1;
@@ -14436,16 +14474,16 @@ function vv(t, e) {
14436
14474
  if (n == 13 || n == 27)
14437
14475
  return !0;
14438
14476
  if (n == 37 || Wt && n == 66 && r == "c") {
14439
- let i = n == 37 ? Eh(t, t.state.selection.from) == "ltr" ? -1 : 1 : -1;
14477
+ let i = n == 37 ? Ih(t, t.state.selection.from) == "ltr" ? -1 : 1 : -1;
14440
14478
  return Ah(t, i, r) || oi(t, i);
14441
14479
  } else if (n == 39 || Wt && n == 70 && r == "c") {
14442
- let i = n == 39 ? Eh(t, t.state.selection.from) == "ltr" ? 1 : -1 : 1;
14480
+ let i = n == 39 ? Ih(t, t.state.selection.from) == "ltr" ? 1 : -1 : 1;
14443
14481
  return Ah(t, i, r) || oi(t, i);
14444
14482
  } else {
14445
14483
  if (n == 38 || Wt && n == 80 && r == "c")
14446
- return Ih(t, -1, r) || oi(t, -1);
14484
+ return Eh(t, -1, r) || oi(t, -1);
14447
14485
  if (n == 40 || Wt && n == 78 && r == "c")
14448
- return Cv(t) || Ih(t, 1, r) || oi(t, 1);
14486
+ return Cv(t) || Eh(t, 1, r) || oi(t, 1);
14449
14487
  if (r == (Wt ? "m" : "c") && (n == 66 || n == 73 || n == 89 || n == 90))
14450
14488
  return !0;
14451
14489
  }
@@ -14505,7 +14543,7 @@ function Qg(t, e, n, r, i) {
14505
14543
  } else
14506
14544
  t.someProp("transformPastedHTML", (d) => {
14507
14545
  n = d(n, t);
14508
- }), s = Ev(n), Uo && Iv(s);
14546
+ }), s = Iv(n), Uo && Ev(s);
14509
14547
  let c = s && s.querySelector("[data-pm-slice]"), u = c && /^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(c.getAttribute("data-pm-slice") || "");
14510
14548
  if (u && u[3])
14511
14549
  for (let d = +u[3]; d > 0; d--) {
@@ -14607,7 +14645,7 @@ function Av(t) {
14607
14645
  let e = window.trustedTypes;
14608
14646
  return e ? (ba || (ba = e.defaultPolicy || e.createPolicy("ProseMirrorClipboard", { createHTML: (n) => n })), ba.createHTML(t)) : t;
14609
14647
  }
14610
- function Ev(t) {
14648
+ function Iv(t) {
14611
14649
  let e = /^(\s*<meta [^>]*>)*/.exec(t);
14612
14650
  e && (t = t.slice(e[0].length));
14613
14651
  let n = ny().createElement("div"), r = /<([a-z][^>\s]+)/i.exec(t), i;
@@ -14616,7 +14654,7 @@ function Ev(t) {
14616
14654
  n = n.querySelector(i[o]) || n;
14617
14655
  return n;
14618
14656
  }
14619
- function Iv(t) {
14657
+ function Ev(t) {
14620
14658
  let e = t.querySelectorAll(tt ? "span:not([class]):not([style])" : "span.Apple-converted-space");
14621
14659
  for (let n = 0; n < e.length; n++) {
14622
14660
  let r = e[n];
@@ -14696,7 +14734,7 @@ mt.keydown = (t, e) => {
14696
14734
  if (n.keyCode != 229 && t.domObserver.forceFlush(), Ti && n.keyCode == 13 && !n.ctrlKey && !n.altKey && !n.metaKey) {
14697
14735
  let r = Date.now();
14698
14736
  t.input.lastIOSEnter = r, t.input.lastIOSEnterFallbackTimeout = setTimeout(() => {
14699
- t.input.lastIOSEnter == r && (t.someProp("handleKeyDown", (i) => i(t, Er(13, "Enter"))), t.input.lastIOSEnter = 0);
14737
+ t.input.lastIOSEnter == r && (t.someProp("handleKeyDown", (i) => i(t, Ir(13, "Enter"))), t.input.lastIOSEnter = 0);
14700
14738
  }, 200);
14701
14739
  } else t.someProp("handleKeyDown", (r) => r(t, n)) || vv(t, n) ? n.preventDefault() : or(t, "key");
14702
14740
  };
@@ -15074,7 +15112,7 @@ pt.beforeinput = (t, e) => {
15074
15112
  t.domObserver.flushSoon();
15075
15113
  let { domChangeCount: r } = t.input;
15076
15114
  setTimeout(() => {
15077
- if (t.input.domChangeCount != r || (t.dom.blur(), t.focus(), t.someProp("handleKeyDown", (o) => o(t, Er(8, "Backspace")))))
15115
+ if (t.input.domChangeCount != r || (t.dom.blur(), t.focus(), t.someProp("handleKeyDown", (o) => o(t, Ir(8, "Backspace")))))
15078
15116
  return;
15079
15117
  let { $cursor: i } = t.state.selection;
15080
15118
  i && i.pos > 0 && t.dispatch(t.state.tr.delete(i.pos - 1, i.pos).scrollIntoView());
@@ -15863,7 +15901,7 @@ function hT(t, e, n, r, i) {
15863
15901
  if (t.input.compositionPendingChanges = 0, e < 0) {
15864
15902
  let D = t.input.lastSelectionTime > Date.now() - 50 ? t.input.lastSelectionOrigin : null, B = pu(t, D);
15865
15903
  if (B && !t.state.selection.eq(B)) {
15866
- if (tt && Fn && t.input.lastKeyCode === 13 && Date.now() - 100 < t.input.lastKeyCodeTime && t.someProp("handleKeyDown", (T) => T(t, Er(13, "Enter"))))
15904
+ if (tt && Fn && t.input.lastKeyCode === 13 && Date.now() - 100 < t.input.lastKeyCodeTime && t.someProp("handleKeyDown", (T) => T(t, Ir(13, "Enter"))))
15867
15905
  return;
15868
15906
  let V = t.state.tr.setSelection(B);
15869
15907
  D == "pointer" ? V.setMeta("pointer", !0) : D == "key" && V.scrollIntoView(), o && V.setMeta("composition", o), t.dispatch(V);
@@ -15875,7 +15913,7 @@ function hT(t, e, n, r, i) {
15875
15913
  let a = t.state.selection, c = uT(t, e, n), u = t.state.doc, d = u.slice(c.from, c.to), f, h;
15876
15914
  t.input.lastKeyCode === 8 && Date.now() - 100 < t.input.lastKeyCodeTime ? (f = t.state.selection.to, h = "end") : (f = t.state.selection.from, h = "start"), t.input.lastKeyCode = null;
15877
15915
  let p = gT(d.content, c.doc.content, c.from, f, h);
15878
- if (p && t.input.domChangeCount++, (Ti && t.input.lastIOSEnter > Date.now() - 225 || Fn) && i.some((D) => D.nodeType == 1 && !fT.test(D.nodeName)) && (!p || p.endA >= p.endB) && t.someProp("handleKeyDown", (D) => D(t, Er(13, "Enter")))) {
15916
+ if (p && t.input.domChangeCount++, (Ti && t.input.lastIOSEnter > Date.now() - 225 || Fn) && i.some((D) => D.nodeType == 1 && !fT.test(D.nodeName)) && (!p || p.endA >= p.endB) && t.someProp("handleKeyDown", (D) => D(t, Ir(13, "Enter")))) {
15879
15917
  t.input.lastIOSEnter = 0;
15880
15918
  return;
15881
15919
  }
@@ -15894,17 +15932,17 @@ function hT(t, e, n, r, i) {
15894
15932
  }
15895
15933
  t.state.selection.from < t.state.selection.to && p.start == p.endB && t.state.selection instanceof ae && (p.start > t.state.selection.from && p.start <= t.state.selection.from + 2 && t.state.selection.from >= c.from ? p.start = t.state.selection.from : p.endA < t.state.selection.to && p.endA >= t.state.selection.to - 2 && t.state.selection.to <= c.to && (p.endB += t.state.selection.to - p.endA, p.endA = t.state.selection.to)), Tt && lr <= 11 && p.endB == p.start + 1 && p.endA == p.start && p.start > c.from && c.doc.textBetween(p.start - c.from - 1, p.start - c.from + 1) == "  " && (p.start--, p.endA--, p.endB--);
15896
15934
  let m = c.doc.resolveNoCache(p.start - c.from), g = c.doc.resolveNoCache(p.endB - c.from), y = u.resolve(p.start), M = m.sameParent(g) && m.parent.inlineContent && y.end() >= p.endA;
15897
- if ((Ti && t.input.lastIOSEnter > Date.now() - 225 && (!M || i.some((D) => D.nodeName == "DIV" || D.nodeName == "P")) || !M && m.pos < c.doc.content.size && (!m.sameParent(g) || !m.parent.inlineContent) && m.pos < g.pos && !/\S/.test(c.doc.textBetween(m.pos, g.pos, "", ""))) && t.someProp("handleKeyDown", (D) => D(t, Er(13, "Enter")))) {
15935
+ if ((Ti && t.input.lastIOSEnter > Date.now() - 225 && (!M || i.some((D) => D.nodeName == "DIV" || D.nodeName == "P")) || !M && m.pos < c.doc.content.size && (!m.sameParent(g) || !m.parent.inlineContent) && m.pos < g.pos && !/\S/.test(c.doc.textBetween(m.pos, g.pos, "", ""))) && t.someProp("handleKeyDown", (D) => D(t, Ir(13, "Enter")))) {
15898
15936
  t.input.lastIOSEnter = 0;
15899
15937
  return;
15900
15938
  }
15901
- if (t.state.selection.anchor > p.start && mT(u, p.start, p.endA, m, g) && t.someProp("handleKeyDown", (D) => D(t, Er(8, "Backspace")))) {
15939
+ if (t.state.selection.anchor > p.start && mT(u, p.start, p.endA, m, g) && t.someProp("handleKeyDown", (D) => D(t, Ir(8, "Backspace")))) {
15902
15940
  Fn && tt && t.domObserver.suppressSelectionUpdates();
15903
15941
  return;
15904
15942
  }
15905
15943
  tt && p.endB == p.start && (t.input.lastChromeDelete = Date.now()), Fn && !M && m.start() != g.start() && g.parentOffset == 0 && m.depth == g.depth && c.sel && c.sel.anchor == c.sel.head && c.sel.head == p.endA && (p.endB -= 2, g = c.doc.resolveNoCache(p.endB - c.from), setTimeout(() => {
15906
15944
  t.someProp("handleKeyDown", function(D) {
15907
- return D(t, Er(13, "Enter"));
15945
+ return D(t, Ir(13, "Enter"));
15908
15946
  });
15909
15947
  }, 20));
15910
15948
  let S = p.start, N = p.endA, R = (D) => {
@@ -16687,7 +16725,7 @@ const TT = new Be("MILKDOWN_STATE_TRACKER"), Sy = (t) => (t.inject(Rs, "").injec
16687
16725
  schema: e,
16688
16726
  doc: l,
16689
16727
  plugins: u
16690
- }), f = Ir.create(d);
16728
+ }), f = Er.create(d);
16691
16729
  return t.set(lo, f), t.done(_s), () => {
16692
16730
  c(), t.remove(Rs).remove(lo).remove(Ds).remove(Aa).clearTimer(_s);
16693
16731
  };
@@ -16695,13 +16733,13 @@ const TT = new Be("MILKDOWN_STATE_TRACKER"), Sy = (t) => (t.inject(Rs, "").injec
16695
16733
  jn(Sy, {
16696
16734
  displayName: "EditorState"
16697
16735
  });
16698
- const Bo = ge([], "pasteRule"), Ea = ge([ht], "pasteRuleTimer"), Ls = Tn("PasteRuleReady"), vy = (t) => (t.inject(Bo, []).inject(Ea, [ht]).record(Ls), async () => (await t.waitTimers(Ea), t.done(Ls), () => {
16699
- t.remove(Bo).remove(Ea).clearTimer(Ls);
16736
+ const Bo = ge([], "pasteRule"), Ia = ge([ht], "pasteRuleTimer"), Ls = Tn("PasteRuleReady"), vy = (t) => (t.inject(Bo, []).inject(Ia, [ht]).record(Ls), async () => (await t.waitTimers(Ia), t.done(Ls), () => {
16737
+ t.remove(Bo).remove(Ia).clearTimer(Ls);
16700
16738
  }));
16701
16739
  jn(vy, {
16702
16740
  displayName: "PasteRule"
16703
16741
  });
16704
- const Ps = Tn("EditorViewReady"), Ia = ge(
16742
+ const Ps = Tn("EditorViewReady"), Ea = ge(
16705
16743
  [],
16706
16744
  "editorViewTimer"
16707
16745
  ), So = ge(
@@ -16722,12 +16760,12 @@ function MT(t, e) {
16722
16760
  function AT(t) {
16723
16761
  t.classList.add("editor"), t.setAttribute("role", "textbox");
16724
16762
  }
16725
- const ET = new Be("MILKDOWN_VIEW_CLEAR"), Ty = (t) => (t.inject(zs, document.body).inject(Oe, {}).inject(So, {}).inject(Mc, null).inject(Ac, {}).inject(Ia, [_s, Ls]).record(Ps), async () => {
16763
+ const IT = new Be("MILKDOWN_VIEW_CLEAR"), Ty = (t) => (t.inject(zs, document.body).inject(Oe, {}).inject(So, {}).inject(Mc, null).inject(Ac, {}).inject(Ea, [_s, Ls]).record(Ps), async () => {
16726
16764
  await t.wait(Hr);
16727
16765
  const e = t.get(zs) || document.body, n = typeof e == "string" ? document.querySelector(e) : e;
16728
16766
  t.update(Wn, (a) => [
16729
16767
  new $e({
16730
- key: ET,
16768
+ key: IT,
16731
16769
  view: (c) => {
16732
16770
  const u = n ? MT(n, t) : void 0;
16733
16771
  return (() => {
@@ -16743,7 +16781,7 @@ const ET = new Be("MILKDOWN_VIEW_CLEAR"), Ty = (t) => (t.inject(zs, document.bod
16743
16781
  }
16744
16782
  }),
16745
16783
  ...a
16746
- ]), await t.waitTimers(Ia);
16784
+ ]), await t.waitTimers(Ea);
16747
16785
  const r = t.get(lo), i = t.get(So), o = Object.fromEntries(t.get(Po)), s = Object.fromEntries(t.get(zo)), l = new hy(n, {
16748
16786
  state: r,
16749
16787
  nodeViews: o,
@@ -16754,7 +16792,7 @@ const ET = new Be("MILKDOWN_VIEW_CLEAR"), Ty = (t) => (t.inject(zs, document.bod
16754
16792
  ...i
16755
16793
  });
16756
16794
  return AT(l.dom), t.set(Oe, l), t.done(Ps), () => {
16757
- l?.destroy(), t.remove(zs).remove(Oe).remove(So).remove(Mc).remove(Ac).remove(Ia).clearTimer(Ps);
16795
+ l?.destroy(), t.remove(zs).remove(Oe).remove(So).remove(Mc).remove(Ac).remove(Ea).clearTimer(Ps);
16758
16796
  };
16759
16797
  });
16760
16798
  jn(Ty, {
@@ -16896,7 +16934,7 @@ function bt(t) {
16896
16934
  };
16897
16935
  return e;
16898
16936
  }
16899
- function IT(t) {
16937
+ function ET(t) {
16900
16938
  const e = (n) => async () => {
16901
16939
  await n.wait(ht);
16902
16940
  const r = t(n);
@@ -16938,7 +16976,7 @@ function Al(t, e) {
16938
16976
  return i;
16939
16977
  }, n;
16940
16978
  }
16941
- function It(t) {
16979
+ function Et(t) {
16942
16980
  let e;
16943
16981
  const n = (r) => async () => (await r.wait(ht), e = t(r), r.update(Wn, (i) => [...i, e]), () => {
16944
16982
  r.update(Wn, (i) => i.filter((o) => o !== e));
@@ -17073,7 +17111,7 @@ function vo(t, e = !1) {
17073
17111
  )
17074
17112
  );
17075
17113
  }
17076
- const s = n.get(Gt), l = n.get(Ds), a = n.get(Wn), c = Ir.create({
17114
+ const s = n.get(Gt), l = n.get(Ds), a = n.get(Wn), c = Er.create({
17077
17115
  schema: s,
17078
17116
  doc: o,
17079
17117
  plugins: a,
@@ -17082,7 +17120,7 @@ function vo(t, e = !1) {
17082
17120
  r.updateState(c);
17083
17121
  };
17084
17122
  }
17085
- const Ey = "en-US";
17123
+ const Iy = "en-US";
17086
17124
  function RT() {
17087
17125
  if (typeof document < "u") {
17088
17126
  const t = document.documentElement?.lang?.trim();
@@ -17491,7 +17529,7 @@ const DT = {
17491
17529
  function Jh(t) {
17492
17530
  return typeof t == "object" && t !== null && !Array.isArray(t);
17493
17531
  }
17494
- function Iy(t, e) {
17532
+ function Ey(t, e) {
17495
17533
  if (!e) return t;
17496
17534
  const n = { ...t };
17497
17535
  for (const r of Object.keys(e)) {
@@ -17499,7 +17537,7 @@ function Iy(t, e) {
17499
17537
  if (i === void 0) continue;
17500
17538
  const o = t[r];
17501
17539
  if (Jh(o) && Jh(i)) {
17502
- n[r] = Iy(o, i);
17540
+ n[r] = Ey(o, i);
17503
17541
  continue;
17504
17542
  }
17505
17543
  n[r] = i;
@@ -17507,41 +17545,41 @@ function Iy(t, e) {
17507
17545
  return n;
17508
17546
  }
17509
17547
  function PT(t) {
17510
- return (t || RT())?.toLowerCase().startsWith("zh") ? "zh-CN" : Ey;
17548
+ return (t || RT())?.toLowerCase().startsWith("zh") ? "zh-CN" : Iy;
17511
17549
  }
17512
17550
  function Ny(t, e) {
17513
17551
  const n = PT(t);
17514
- return Iy(LT[n], e);
17515
- }
17516
- const Ee = (t, e = "") => `<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"${e}>${t}</svg>`, Un = Ny(Ey), zT = [
17517
- { type: "var", icon: "x", svgIcon: Ee('<path d="M7 4l10 16M17 4L7 20"/>'), color: "#2563eb" },
17518
- { type: "var_table", icon: "⊞", svgIcon: Ee('<rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M3 15h18M9 3v18M15 3v18"/>'), color: "#059669" },
17519
- { type: "quiz", icon: "?", svgIcon: Ee('<circle cx="12" cy="12" r="9"/><path d="M9.5 9a2.5 2.5 0 0 1 5 0c0 1.5-2 2-2 3.5"/><circle cx="12" cy="17" r="1" fill="currentColor" stroke="none"/>'), color: "#7c3aed" },
17520
- { type: "step", icon: "▶", svgIcon: Ee('<polygon points="5,3 19,12 5,21" fill="currentColor" stroke="none"/>'), color: "#d97706" },
17521
- { type: "check", icon: "✓", svgIcon: Ee('<polyline points="4 12 9 17 20 6"/>'), color: "#dc2626" },
17522
- { type: "ref_step", icon: "↗", svgIcon: Ee('<path d="M7 17L17 7M17 7H8M17 7v9"/>'), color: "#0891b2" },
17523
- { type: "ref_var", icon: "↗", svgIcon: Ee('<circle cx="11" cy="11" r="7"/><path d="M21 21l-4.35-4.35"/>'), color: "#0891b2" },
17524
- { type: "ref_fig", icon: "↗", svgIcon: Ee('<rect x="3" y="3" width="18" height="18" rx="2"/><circle cx="8.5" cy="8.5" r="1.5" fill="currentColor" stroke="none"/><path d="M21 15l-5-5L5 21"/>'), color: "#0891b2" },
17525
- { type: "cite", icon: "📖", svgIcon: Ee('<path d="M4 19.5A2.5 2.5 0 016.5 17H20"/><path d="M6.5 2H20v20H6.5A2.5 2.5 0 014 19.5v-15A2.5 2.5 0 016.5 2z"/>'), color: "#6d28d9" }
17552
+ return Ey(LT[n], e);
17553
+ }
17554
+ const Ie = (t, e = "") => `<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"${e}>${t}</svg>`, Un = Ny(Iy), zT = [
17555
+ { type: "var", icon: "x", svgIcon: Ie('<path d="M7 4l10 16M17 4L7 20"/>'), color: "#2563eb" },
17556
+ { type: "var_table", icon: "⊞", svgIcon: Ie('<rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M3 15h18M9 3v18M15 3v18"/>'), color: "#059669" },
17557
+ { type: "quiz", icon: "?", svgIcon: Ie('<circle cx="12" cy="12" r="9"/><path d="M9.5 9a2.5 2.5 0 0 1 5 0c0 1.5-2 2-2 3.5"/><circle cx="12" cy="17" r="1" fill="currentColor" stroke="none"/>'), color: "#7c3aed" },
17558
+ { type: "step", icon: "▶", svgIcon: Ie('<polygon points="5,3 19,12 5,21" fill="currentColor" stroke="none"/>'), color: "#d97706" },
17559
+ { type: "check", icon: "✓", svgIcon: Ie('<polyline points="4 12 9 17 20 6"/>'), color: "#dc2626" },
17560
+ { type: "ref_step", icon: "↗", svgIcon: Ie('<path d="M7 17L17 7M17 7H8M17 7v9"/>'), color: "#0891b2" },
17561
+ { type: "ref_var", icon: "↗", svgIcon: Ie('<circle cx="11" cy="11" r="7"/><path d="M21 21l-4.35-4.35"/>'), color: "#0891b2" },
17562
+ { type: "ref_fig", icon: "↗", svgIcon: Ie('<rect x="3" y="3" width="18" height="18" rx="2"/><circle cx="8.5" cy="8.5" r="1.5" fill="currentColor" stroke="none"/><path d="M21 15l-5-5L5 21"/>'), color: "#0891b2" },
17563
+ { type: "cite", icon: "📖", svgIcon: Ie('<path d="M4 19.5A2.5 2.5 0 016.5 17H20"/><path d="M6.5 2H20v20H6.5A2.5 2.5 0 014 19.5v-15A2.5 2.5 0 016.5 2z"/>'), color: "#6d28d9" }
17526
17564
  ], BT = [
17527
- { action: "h1", svgIcon: Ee('<path d="M4 12h8M4 4v16M12 4v16"/><text x="16.5" y="14" font-size="10" fill="currentColor" stroke="none" font-weight="600">1</text>') },
17528
- { action: "h2", svgIcon: Ee('<path d="M4 12h8M4 4v16M12 4v16"/><path d="M16.5 8.5a2.5 2.5 0 015 0c0 2-5 4-5 6.5h5" stroke-width="1.8"/>') },
17529
- { action: "h3", svgIcon: Ee('<path d="M4 12h8M4 4v16M12 4v16"/><path d="M16.5 8a2 2 0 014 0 2 2 0 01-2.5 2 2 2 0 012.5 2 2 2 0 01-4 0" stroke-width="1.8"/>') },
17530
- { action: "bold", svgIcon: Ee('<path d="M6 4h8a4 4 0 014 4 4 4 0 01-4 4H6z"/><path d="M6 12h9a4 4 0 014 4 4 4 0 01-4 4H6z"/>') },
17531
- { action: "italic", svgIcon: Ee('<line x1="19" y1="4" x2="10" y2="4"/><line x1="14" y1="20" x2="5" y2="20"/><line x1="15" y1="4" x2="9" y2="20"/>') },
17532
- { action: "strikethrough", svgIcon: Ee('<path d="M16 4c-.5-1.5-2.2-3-5-3-3 0-5 2-5 4.5 0 2 1.5 3.5 5 4.5"/><path d="M3 12h18"/><path d="M8 20c.5 1.5 2.2 3 5 3 3 0 5-2 5-4.5 0-2-1.5-3.5-5-4.5"/>') },
17565
+ { action: "h1", svgIcon: Ie('<path d="M4 12h8M4 4v16M12 4v16"/><text x="16.5" y="14" font-size="10" fill="currentColor" stroke="none" font-weight="600">1</text>') },
17566
+ { action: "h2", svgIcon: Ie('<path d="M4 12h8M4 4v16M12 4v16"/><path d="M16.5 8.5a2.5 2.5 0 015 0c0 2-5 4-5 6.5h5" stroke-width="1.8"/>') },
17567
+ { action: "h3", svgIcon: Ie('<path d="M4 12h8M4 4v16M12 4v16"/><path d="M16.5 8a2 2 0 014 0 2 2 0 01-2.5 2 2 2 0 012.5 2 2 2 0 01-4 0" stroke-width="1.8"/>') },
17568
+ { action: "bold", svgIcon: Ie('<path d="M6 4h8a4 4 0 014 4 4 4 0 01-4 4H6z"/><path d="M6 12h9a4 4 0 014 4 4 4 0 01-4 4H6z"/>') },
17569
+ { action: "italic", svgIcon: Ie('<line x1="19" y1="4" x2="10" y2="4"/><line x1="14" y1="20" x2="5" y2="20"/><line x1="15" y1="4" x2="9" y2="20"/>') },
17570
+ { action: "strikethrough", svgIcon: Ie('<path d="M16 4c-.5-1.5-2.2-3-5-3-3 0-5 2-5 4.5 0 2 1.5 3.5 5 4.5"/><path d="M3 12h18"/><path d="M8 20c.5 1.5 2.2 3 5 3 3 0 5-2 5-4.5 0-2-1.5-3.5-5-4.5"/>') },
17533
17571
  { action: "sep1" },
17534
- { action: "ul", svgIcon: Ee('<line x1="9" y1="6" x2="20" y2="6"/><line x1="9" y1="12" x2="20" y2="12"/><line x1="9" y1="18" x2="20" y2="18"/><circle cx="5" cy="6" r="1" fill="currentColor"/><circle cx="5" cy="12" r="1" fill="currentColor"/><circle cx="5" cy="18" r="1" fill="currentColor"/>') },
17535
- { action: "ol", svgIcon: Ee('<line x1="10" y1="6" x2="21" y2="6"/><line x1="10" y1="12" x2="21" y2="12"/><line x1="10" y1="18" x2="21" y2="18"/><text x="3" y="7.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">1</text><text x="3" y="13.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">2</text><text x="3" y="19.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">3</text>') },
17536
- { action: "blockquote", svgIcon: Ee('<path d="M3 21c3 0 7-1 7-8V5c0-1.25-.756-2.017-2-2H4c-1.25 0-2 .75-2 1.972V11c0 1.25.75 2 2 2 1 0 1 0 1 1v1c0 1-1 2-2 2s-1 .008-1 1.031V20c0 1 0 1 1 1z"/><path d="M15 21c3 0 7-1 7-8V5c0-1.25-.757-2.017-2-2h-4c-1.25 0-2 .75-2 1.972V11c0 1.25.75 2 2 2h.75c0 2.25.25 4-2.75 4v3c0 1 0 1 1 1z"/>') },
17537
- { action: "code", svgIcon: Ee('<polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/>') },
17538
- { action: "codeblock", svgIcon: Ee('<polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/><rect x="1" y="1" width="22" height="22" rx="3" stroke-dasharray="4 2" stroke-width="1"/>') },
17572
+ { action: "ul", svgIcon: Ie('<line x1="9" y1="6" x2="20" y2="6"/><line x1="9" y1="12" x2="20" y2="12"/><line x1="9" y1="18" x2="20" y2="18"/><circle cx="5" cy="6" r="1" fill="currentColor"/><circle cx="5" cy="12" r="1" fill="currentColor"/><circle cx="5" cy="18" r="1" fill="currentColor"/>') },
17573
+ { action: "ol", svgIcon: Ie('<line x1="10" y1="6" x2="21" y2="6"/><line x1="10" y1="12" x2="21" y2="12"/><line x1="10" y1="18" x2="21" y2="18"/><text x="3" y="7.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">1</text><text x="3" y="13.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">2</text><text x="3" y="19.5" font-size="6" fill="currentColor" stroke="none" font-weight="600">3</text>') },
17574
+ { action: "blockquote", svgIcon: Ie('<path d="M3 21c3 0 7-1 7-8V5c0-1.25-.756-2.017-2-2H4c-1.25 0-2 .75-2 1.972V11c0 1.25.75 2 2 2 1 0 1 0 1 1v1c0 1-1 2-2 2s-1 .008-1 1.031V20c0 1 0 1 1 1z"/><path d="M15 21c3 0 7-1 7-8V5c0-1.25-.757-2.017-2-2h-4c-1.25 0-2 .75-2 1.972V11c0 1.25.75 2 2 2h.75c0 2.25.25 4-2.75 4v3c0 1 0 1 1 1z"/>') },
17575
+ { action: "code", svgIcon: Ie('<polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/>') },
17576
+ { action: "codeblock", svgIcon: Ie('<polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/><rect x="1" y="1" width="22" height="22" rx="3" stroke-dasharray="4 2" stroke-width="1"/>') },
17539
17577
  { action: "sep2" },
17540
- { action: "link", svgIcon: Ee('<path d="M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71"/>') },
17541
- { action: "image", svgIcon: Ee('<rect x="3" y="3" width="18" height="18" rx="2"/><circle cx="8.5" cy="8.5" r="1.5" fill="currentColor" stroke="none"/><path d="M21 15l-5-5L5 21"/>') },
17542
- { action: "table", svgIcon: Ee('<rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M3 15h18M9 3v18M15 3v18"/>') },
17543
- { action: "hr", svgIcon: Ee('<line x1="2" y1="12" x2="22" y2="12" stroke-width="2.5"/>') },
17544
- { action: "math", svgIcon: Ee('<path d="M18 4H6l6 8-6 8h12" stroke-width="2"/>') }
17578
+ { action: "link", svgIcon: Ie('<path d="M10 13a5 5 0 007.54.54l3-3a5 5 0 00-7.07-7.07l-1.72 1.71"/><path d="M14 11a5 5 0 00-7.54-.54l-3 3a5 5 0 007.07 7.07l1.71-1.71"/>') },
17579
+ { action: "image", svgIcon: Ie('<rect x="3" y="3" width="18" height="18" rx="2"/><circle cx="8.5" cy="8.5" r="1.5" fill="currentColor" stroke="none"/><path d="M21 15l-5-5L5 21"/>') },
17580
+ { action: "table", svgIcon: Ie('<rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M3 15h18M9 3v18M15 3v18"/>') },
17581
+ { action: "hr", svgIcon: Ie('<line x1="2" y1="12" x2="22" y2="12" stroke-width="2.5"/>') },
17582
+ { action: "math", svgIcon: Ie('<path d="M18 4H6l6 8-6 8h12" stroke-width="2"/>') }
17545
17583
  ];
17546
17584
  function Su(t = Un) {
17547
17585
  return zT.map((e) => {
@@ -17780,7 +17818,7 @@ function jT(t, e) {
17780
17818
  cite: "{{cite|ref1}}"
17781
17819
  }[t] || `{{${t}|id}}`;
17782
17820
  }
17783
- const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT = { class: "aimd-dialog-title" }, GT = ["innerHTML"], YT = { class: "aimd-dialog-type-tabs" }, QT = ["onClick"], XT = ["innerHTML"], ZT = { class: "aimd-dialog-body" }, eM = { class: "aimd-field-row" }, tM = { class: "aimd-field-label" }, nM = ["placeholder"], rM = { class: "aimd-field-row" }, iM = { class: "aimd-field-label" }, oM = { class: "aimd-field-hint" }, sM = { class: "aimd-var-type-grid" }, lM = ["onClick"], aM = { class: "aimd-var-type-card-title" }, cM = { class: "aimd-var-type-card-desc" }, uM = { class: "aimd-field-row" }, dM = { class: "aimd-field-label" }, fM = ["placeholder"], hM = { class: "aimd-field-hint" }, pM = { class: "aimd-field-row" }, mM = { class: "aimd-field-label" }, gM = ["placeholder"], yM = { class: "aimd-field-row" }, bM = { class: "aimd-field-label" }, kM = ["placeholder"], wM = { class: "aimd-field-row" }, xM = { class: "aimd-field-label" }, CM = ["placeholder"], SM = { class: "aimd-field-row" }, vM = { class: "aimd-field-label" }, TM = ["placeholder"], MM = { class: "aimd-field-hint" }, AM = { class: "aimd-field-row" }, EM = { class: "aimd-field-label" }, IM = ["placeholder"], NM = { class: "aimd-field-row" }, OM = { class: "aimd-field-label" }, RM = { value: "1" }, DM = { value: "2" }, _M = { value: "3" }, LM = { class: "aimd-field-row" }, PM = { class: "aimd-field-label" }, zM = ["placeholder"], BM = { class: "aimd-field-row" }, FM = { class: "aimd-field-label" }, $M = { value: "choice" }, HM = { value: "blank" }, VM = { value: "open" }, qM = { class: "aimd-field-row" }, WM = { class: "aimd-field-label" }, jM = ["placeholder"], UM = { class: "aimd-field-row" }, KM = { class: "aimd-field-label" }, JM = ["placeholder"], GM = {
17821
+ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT = { class: "aimd-dialog-title" }, GT = ["innerHTML"], YT = { class: "aimd-dialog-type-tabs" }, QT = ["onClick"], XT = ["innerHTML"], ZT = { class: "aimd-dialog-body" }, eM = { class: "aimd-field-row" }, tM = { class: "aimd-field-label" }, nM = ["placeholder"], rM = { class: "aimd-field-row" }, iM = { class: "aimd-field-label" }, oM = { class: "aimd-field-hint" }, sM = { class: "aimd-var-type-grid" }, lM = ["onClick"], aM = { class: "aimd-var-type-card-title" }, cM = { class: "aimd-var-type-card-desc" }, uM = { class: "aimd-field-row" }, dM = { class: "aimd-field-label" }, fM = ["placeholder"], hM = { class: "aimd-field-hint" }, pM = { class: "aimd-field-row" }, mM = { class: "aimd-field-label" }, gM = ["placeholder"], yM = { class: "aimd-field-row" }, bM = { class: "aimd-field-label" }, kM = ["placeholder"], wM = { class: "aimd-field-row" }, xM = { class: "aimd-field-label" }, CM = ["placeholder"], SM = { class: "aimd-field-row" }, vM = { class: "aimd-field-label" }, TM = ["placeholder"], MM = { class: "aimd-field-hint" }, AM = { class: "aimd-field-row" }, IM = { class: "aimd-field-label" }, EM = ["placeholder"], NM = { class: "aimd-field-row" }, OM = { class: "aimd-field-label" }, RM = { value: "1" }, DM = { value: "2" }, _M = { value: "3" }, LM = { class: "aimd-field-row" }, PM = { class: "aimd-field-label" }, zM = ["placeholder"], BM = { class: "aimd-field-row" }, FM = { class: "aimd-field-label" }, $M = { value: "choice" }, HM = { value: "blank" }, VM = { value: "open" }, qM = { class: "aimd-field-row" }, WM = { class: "aimd-field-label" }, jM = ["placeholder"], UM = { class: "aimd-field-row" }, KM = { class: "aimd-field-label" }, JM = ["placeholder"], GM = {
17784
17822
  key: 0,
17785
17823
  class: "aimd-field-hint"
17786
17824
  }, YM = { class: "aimd-field-row" }, QM = { class: "aimd-field-label" }, XM = { value: "single" }, ZM = { value: "multiple" }, e2 = { class: "aimd-field-row" }, t2 = { class: "aimd-field-label" }, n2 = { class: "aimd-collection-editor" }, r2 = ["onDragover", "onDrop"], i2 = ["title", "onDragstart"], o2 = ["onUpdate:modelValue", "placeholder"], s2 = ["onUpdate:modelValue", "placeholder"], l2 = { class: "aimd-option-answer-toggle" }, a2 = ["value", "disabled"], c2 = ["value", "disabled"], u2 = ["disabled", "onClick"], d2 = { class: "aimd-field-hint" }, f2 = {
@@ -17795,7 +17833,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17795
17833
  }, S2 = { class: "aimd-field-label" }, v2 = ["placeholder"], T2 = {
17796
17834
  key: 5,
17797
17835
  class: "aimd-field-row"
17798
- }, M2 = { class: "aimd-field-label" }, A2 = ["placeholder"], E2 = { id: "aimd-ref-suggestions" }, I2 = ["value"], N2 = {
17836
+ }, M2 = { class: "aimd-field-label" }, A2 = ["placeholder"], I2 = { id: "aimd-ref-suggestions" }, E2 = ["value"], N2 = {
17799
17837
  key: 0,
17800
17838
  class: "aimd-field-hint"
17801
17839
  }, O2 = {
@@ -17821,11 +17859,11 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17821
17859
  const z = Su(n.messages);
17822
17860
  if (!n.allowedTypes || n.allowedTypes.length === 0)
17823
17861
  return z;
17824
- const I = new Set(n.allowedTypes);
17825
- return z.filter((E) => I.has(E.type));
17862
+ const E = new Set(n.allowedTypes);
17863
+ return z.filter((I) => E.has(I.type));
17826
17864
  });
17827
17865
  function o(z) {
17828
- return z && i.value.some((I) => I.type === z) ? z : i.value[0]?.type ?? z ?? "var";
17866
+ return z && i.value.some((E) => E.type === z) ? z : i.value[0]?.type ?? z ?? "var";
17829
17867
  }
17830
17868
  const s = Xe(() => new Set(n.existingQuizIds || [])), l = ye(o(n.initialType)), a = ye(Wi(l.value, n.messages, s.value)), c = ye([]), u = ye([]), d = ye([]), f = ye(null), h = ye(null), p = ye(""), m = Xe(
17831
17869
  () => $T(n.messages, n.varTypePlugins ?? [])
@@ -17839,48 +17877,48 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17839
17877
  function M(z) {
17840
17878
  a.value.type = z;
17841
17879
  }
17842
- function S(z, I) {
17843
- const E = `quiz_${z}`;
17880
+ function S(z, E) {
17881
+ const I = `quiz_${z}`;
17844
17882
  let oe = 1;
17845
- for (; I.has(`${E}_${oe}`); )
17883
+ for (; E.has(`${I}_${oe}`); )
17846
17884
  oe += 1;
17847
- return `${E}_${oe}`;
17885
+ return `${I}_${oe}`;
17848
17886
  }
17849
17887
  function N(z) {
17850
- const I = z.split(",").map((E) => E.trim()).filter(Boolean);
17851
- return I.length === 0 ? [
17888
+ const E = z.split(",").map((I) => I.trim()).filter(Boolean);
17889
+ return E.length === 0 ? [
17852
17890
  { key: "A", text: "" },
17853
17891
  { key: "B", text: "" }
17854
- ] : I.map((E, oe) => {
17855
- const be = E.indexOf(":");
17892
+ ] : E.map((I, oe) => {
17893
+ const be = I.indexOf(":");
17856
17894
  if (be > 0) {
17857
- const _t = E.slice(0, be).trim() || String.fromCharCode(65 + oe), An = E.slice(be + 1).trim() || n.messages.defaults.optionText(_t);
17895
+ const _t = I.slice(0, be).trim() || String.fromCharCode(65 + oe), An = I.slice(be + 1).trim() || n.messages.defaults.optionText(_t);
17858
17896
  return { key: _t, text: An };
17859
17897
  }
17860
- return { key: String.fromCharCode(65 + oe), text: E };
17898
+ return { key: String.fromCharCode(65 + oe), text: I };
17861
17899
  });
17862
17900
  }
17863
17901
  function R(z) {
17864
- const I = z.map((E) => ({ key: E.key.trim(), text: E.text.trim() })).filter((E) => E.key && E.text);
17865
- return I.length === 0 ? "A:, B:" : I.map((E) => `${E.key}:${E.text}`).join(", ");
17902
+ const E = z.map((I) => ({ key: I.key.trim(), text: I.text.trim() })).filter((I) => I.key && I.text);
17903
+ return E.length === 0 ? "A:, B:" : E.map((I) => `${I.key}:${I.text}`).join(", ");
17866
17904
  }
17867
17905
  function C(z) {
17868
- const I = z.split(",").map((E) => E.trim()).filter(Boolean);
17869
- return I.length === 0 ? [{ key: "b1", answer: "" }] : I.map((E, oe) => {
17870
- const be = E.indexOf(":");
17906
+ const E = z.split(",").map((I) => I.trim()).filter(Boolean);
17907
+ return E.length === 0 ? [{ key: "b1", answer: "" }] : E.map((I, oe) => {
17908
+ const be = I.indexOf(":");
17871
17909
  if (be > 0) {
17872
- const Dt = E.slice(0, be).trim() || `b${oe + 1}`, _t = E.slice(be + 1).trim() || "";
17910
+ const Dt = I.slice(0, be).trim() || `b${oe + 1}`, _t = I.slice(be + 1).trim() || "";
17873
17911
  return { key: Dt, answer: _t };
17874
17912
  }
17875
- return { key: `b${oe + 1}`, answer: E };
17913
+ return { key: `b${oe + 1}`, answer: I };
17876
17914
  });
17877
17915
  }
17878
17916
  function D(z) {
17879
- const I = z.map((E) => ({ key: E.key.trim(), answer: E.answer.trim() })).filter((E) => E.key);
17880
- return I.length === 0 ? "b1:" : I.map((E) => `${E.key}:${E.answer}`).join(", ");
17917
+ const E = z.map((I) => ({ key: I.key.trim(), answer: I.answer.trim() })).filter((I) => I.key);
17918
+ return E.length === 0 ? "b1:" : E.map((I) => `${I.key}:${I.answer}`).join(", ");
17881
17919
  }
17882
17920
  function B(z) {
17883
- return z.split(",").map((I) => I.trim()).filter(Boolean);
17921
+ return z.split(",").map((E) => E.trim()).filter(Boolean);
17884
17922
  }
17885
17923
  function V() {
17886
17924
  l.value === "quiz" && (a.value.quizType === "choice" ? (c.value = N(a.value.options || ""), d.value = B(a.value.answer || "")) : a.value.quizType === "blank" && (u.value = C(a.value.blanks || "")));
@@ -17888,23 +17926,23 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17888
17926
  function T() {
17889
17927
  if (l.value !== "quiz" || a.value.quizType !== "choice") return;
17890
17928
  const z = new Set(
17891
- c.value.map((I) => I.key.trim()).filter(Boolean)
17929
+ c.value.map((E) => E.key.trim()).filter(Boolean)
17892
17930
  );
17893
17931
  if (a.value.mode === "multiple") {
17894
- const I = d.value.map((E) => E.trim()).filter((E) => E && z.has(E));
17895
- I.length !== d.value.length && (d.value = I);
17932
+ const E = d.value.map((I) => I.trim()).filter((I) => I && z.has(I));
17933
+ E.length !== d.value.length && (d.value = E);
17896
17934
  } else {
17897
- const I = (a.value.answer || "").trim();
17898
- I && !z.has(I) && (a.value.answer = "");
17935
+ const E = (a.value.answer || "").trim();
17936
+ E && !z.has(E) && (a.value.answer = "");
17899
17937
  }
17900
17938
  }
17901
17939
  function v() {
17902
17940
  const z = new Set(
17903
- c.value.map((I) => I.key.trim().toUpperCase()).filter(Boolean)
17941
+ c.value.map((E) => E.key.trim().toUpperCase()).filter(Boolean)
17904
17942
  );
17905
- for (let I = 0; I < 26; I++) {
17906
- const E = String.fromCharCode(65 + I);
17907
- if (!z.has(E)) return E;
17943
+ for (let E = 0; E < 26; E++) {
17944
+ const I = String.fromCharCode(65 + E);
17945
+ if (!z.has(I)) return I;
17908
17946
  }
17909
17947
  return `K${c.value.length + 1}`;
17910
17948
  }
@@ -17922,25 +17960,25 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17922
17960
  f.value !== null && (h.value = z);
17923
17961
  }
17924
17962
  function Y(z) {
17925
- const I = f.value;
17926
- if (I === null || I === z) {
17963
+ const E = f.value;
17964
+ if (E === null || E === z) {
17927
17965
  f.value = null, h.value = null;
17928
17966
  return;
17929
17967
  }
17930
- const E = c.value.splice(I, 1)[0];
17931
- c.value.splice(z, 0, E), f.value = null, h.value = null;
17968
+ const I = c.value.splice(E, 1)[0];
17969
+ c.value.splice(z, 0, I), f.value = null, h.value = null;
17932
17970
  }
17933
17971
  function Q() {
17934
17972
  f.value = null, h.value = null;
17935
17973
  }
17936
17974
  function ee() {
17937
17975
  const z = new Set(
17938
- u.value.map((E) => E.key.trim().toLowerCase()).filter(Boolean)
17976
+ u.value.map((I) => I.key.trim().toLowerCase()).filter(Boolean)
17939
17977
  );
17940
- let I = 1;
17941
- for (; z.has(`b${I}`); )
17942
- I += 1;
17943
- return `b${I}`;
17978
+ let E = 1;
17979
+ for (; z.has(`b${E}`); )
17980
+ E += 1;
17981
+ return `b${E}`;
17944
17982
  }
17945
17983
  function de() {
17946
17984
  u.value.push({ key: ee(), answer: "" });
@@ -17949,25 +17987,25 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17949
17987
  u.value.length <= 1 || u.value.splice(z, 1);
17950
17988
  }
17951
17989
  function ue(z) {
17952
- const I = /* @__PURE__ */ new Set(), E = [];
17990
+ const E = /* @__PURE__ */ new Set(), I = [];
17953
17991
  for (const oe of z)
17954
- I.has(oe) && !E.includes(oe) && E.push(oe), I.add(oe);
17955
- return E;
17992
+ E.has(oe) && !I.includes(oe) && I.push(oe), E.add(oe);
17993
+ return I;
17956
17994
  }
17957
17995
  function _e(z) {
17958
- const I = [], E = /\[\[([^\[\]\s]+)\]\]/g;
17959
- for (const oe of z.matchAll(E))
17960
- I.push(oe[1]);
17961
- return I;
17996
+ const E = [], I = /\[\[([^\[\]\s]+)\]\]/g;
17997
+ for (const oe of z.matchAll(I))
17998
+ E.push(oe[1]);
17999
+ return E;
17962
18000
  }
17963
18001
  function b() {
17964
18002
  const z = u.value.map((Zt) => Zt.key.trim()).filter(Boolean);
17965
18003
  if (z.length === 0)
17966
18004
  return n.messages.errors.blankQuizRequiresBlankKey;
17967
- const I = ue(z);
17968
- if (I.length > 0)
17969
- return n.messages.errors.blankKeysMustBeUnique(I);
17970
- const E = a.value.stem || "", oe = _e(E);
18005
+ const E = ue(z);
18006
+ if (E.length > 0)
18007
+ return n.messages.errors.blankKeysMustBeUnique(E);
18008
+ const I = a.value.stem || "", oe = _e(I);
17971
18009
  if (oe.length === 0)
17972
18010
  return n.messages.errors.blankStemRequiresPlaceholders;
17973
18011
  const be = ue(oe);
@@ -17983,8 +18021,8 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17983
18021
  return l.value !== "quiz" || a.value.quizType !== "blank" ? null : b();
17984
18022
  }
17985
18023
  Pe(() => n.initialType, (z) => {
17986
- const I = o(z);
17987
- l.value = I, a.value = Wi(I, n.messages, s.value), V(), p.value = "";
18024
+ const E = o(z);
18025
+ l.value = E, a.value = Wi(E, n.messages, s.value), V(), p.value = "";
17988
18026
  }), Pe(i, () => {
17989
18027
  const z = o(l.value);
17990
18028
  z !== l.value && (l.value = z, a.value = Wi(z, n.messages, s.value), V(), p.value = "");
@@ -17992,16 +18030,16 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
17992
18030
  z && (a.value = Wi(l.value, n.messages, s.value), V(), p.value = "");
17993
18031
  });
17994
18032
  function J(z) {
17995
- const I = o(z);
17996
- l.value = I, a.value = Wi(I, n.messages, s.value), V(), p.value = "";
18033
+ const E = o(z);
18034
+ l.value = E, a.value = Wi(E, n.messages, s.value), V(), p.value = "";
17997
18035
  }
17998
18036
  const xe = Xe(() => Yh(l.value, a.value, n.messages));
17999
18037
  function Ot(z) {
18000
- return i.value.find((I) => I.type === z) || { type: z, label: z, icon: "?", svgIcon: "", desc: "", color: "#666" };
18038
+ return i.value.find((E) => E.type === z) || { type: z, label: z, icon: "?", svgIcon: "", desc: "", color: "#666" };
18001
18039
  }
18002
18040
  const Je = Xe(() => Ot(l.value)), Ge = Xe(() => n.refSuggestions ? n.refSuggestions : []), nt = Xe(() => l.value === "ref_step" ? n.messages.dialog.referencedStepId : l.value === "ref_var" ? n.messages.dialog.referencedVariableId : n.messages.dialog.referencedFigureId), $t = Xe(() => l.value === "ref_step" ? "step_id" : l.value === "ref_var" ? "var_id" : "fig_id");
18003
- Pe(() => [l.value, a.value.quizType], ([z, I], [E, oe]) => {
18004
- z === "quiz" && (z !== E || I !== oe) && (I !== oe && oe && (a.value.id = S(I, s.value), I === "choice" ? (a.value.stem = n.messages.defaults.questionStem, a.value.mode = "single", a.value.options = "A:, B:", a.value.answer = "A", a.value.blanks = "", a.value.rubric = "") : I === "blank" ? (a.value.stem = n.messages.defaults.fillQuestionStem, a.value.blanks = "b1:", a.value.options = "", a.value.answer = "", a.value.mode = "", a.value.rubric = "", u.value = [{ key: "b1", answer: "" }]) : I === "open" && (a.value.stem = n.messages.defaults.fillQuestionStem, a.value.rubric = "", a.value.options = "", a.value.answer = "", a.value.blanks = "", a.value.mode = "")), V());
18041
+ Pe(() => [l.value, a.value.quizType], ([z, E], [I, oe]) => {
18042
+ z === "quiz" && (z !== I || E !== oe) && (E !== oe && oe && (a.value.id = S(E, s.value), E === "choice" ? (a.value.stem = n.messages.defaults.questionStem, a.value.mode = "single", a.value.options = "A:, B:", a.value.answer = "A", a.value.blanks = "", a.value.rubric = "") : E === "blank" ? (a.value.stem = n.messages.defaults.fillQuestionStem, a.value.blanks = "b1:", a.value.options = "", a.value.answer = "", a.value.mode = "", a.value.rubric = "", u.value = [{ key: "b1", answer: "" }]) : E === "open" && (a.value.stem = n.messages.defaults.fillQuestionStem, a.value.rubric = "", a.value.options = "", a.value.answer = "", a.value.blanks = "", a.value.mode = "")), V());
18005
18043
  }), Pe(() => a.value.mode, () => {
18006
18044
  T();
18007
18045
  }), Pe(c, (z) => {
@@ -18026,7 +18064,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18026
18064
  function Ht() {
18027
18065
  r("update:visible", !1);
18028
18066
  }
18029
- return (z, I) => (Z(), Wc(Jp, { to: "body" }, [
18067
+ return (z, E) => (Z(), Wc(Jp, { to: "body" }, [
18030
18068
  t.visible ? (Z(), ie("div", {
18031
18069
  key: 0,
18032
18070
  class: "aimd-dialog-overlay",
@@ -18048,17 +18086,17 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18048
18086
  }, "×")
18049
18087
  ]),
18050
18088
  _("div", YT, [
18051
- (Z(!0), ie(We, null, zn(i.value, (E) => (Z(), ie("button", {
18052
- key: E.type,
18053
- class: ao(["aimd-type-tab", { active: l.value === E.type }]),
18054
- style: jr(l.value === E.type ? { borderColor: E.color, color: E.color, background: `${E.color}14` } : {}),
18055
- onClick: (oe) => J(E.type)
18089
+ (Z(!0), ie(We, null, zn(i.value, (I) => (Z(), ie("button", {
18090
+ key: I.type,
18091
+ class: ao(["aimd-type-tab", { active: l.value === I.type }]),
18092
+ style: jr(l.value === I.type ? { borderColor: I.color, color: I.color, background: `${I.color}14` } : {}),
18093
+ onClick: (oe) => J(I.type)
18056
18094
  }, [
18057
18095
  _("span", {
18058
- innerHTML: E.svgIcon,
18096
+ innerHTML: I.svgIcon,
18059
18097
  class: "aimd-type-tab-icon"
18060
18098
  }, null, 8, XT),
18061
- fn(" " + K(E.label), 1)
18099
+ fn(" " + K(I.label), 1)
18062
18100
  ], 14, QT))), 128))
18063
18101
  ]),
18064
18102
  _("div", ZT, [
@@ -18066,10 +18104,10 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18066
18104
  _("label", eM, [
18067
18105
  _("span", tM, [
18068
18106
  fn(K(n.messages.dialog.variableId) + " ", 1),
18069
- I[19] || (I[19] = _("em", null, "*", -1))
18107
+ E[19] || (E[19] = _("em", null, "*", -1))
18070
18108
  ]),
18071
18109
  Ae(_("input", {
18072
- "onUpdate:modelValue": I[0] || (I[0] = (E) => a.value.name = E),
18110
+ "onUpdate:modelValue": E[0] || (E[0] = (I) => a.value.name = I),
18073
18111
  placeholder: n.messages.placeholders.variableId,
18074
18112
  class: "aimd-field-input"
18075
18113
  }, null, 8, nM), [
@@ -18080,21 +18118,21 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18080
18118
  _("span", iM, K(n.messages.dialog.typePresetLabel), 1),
18081
18119
  _("span", oM, K(n.messages.dialog.typeHint), 1),
18082
18120
  _("div", sM, [
18083
- (Z(!0), ie(We, null, zn(m.value, (E) => (Z(), ie("button", {
18084
- key: E.key,
18121
+ (Z(!0), ie(We, null, zn(m.value, (I) => (Z(), ie("button", {
18122
+ key: I.key,
18085
18123
  type: "button",
18086
- class: ao(["aimd-var-type-card", { active: y(E.value) }]),
18087
- onClick: (oe) => M(E.value)
18124
+ class: ao(["aimd-var-type-card", { active: y(I.value) }]),
18125
+ onClick: (oe) => M(I.value)
18088
18126
  }, [
18089
- _("span", aM, K(E.label), 1),
18090
- _("span", cM, K(E.desc), 1)
18127
+ _("span", aM, K(I.label), 1),
18128
+ _("span", cM, K(I.desc), 1)
18091
18129
  ], 10, lM))), 128))
18092
18130
  ])
18093
18131
  ]),
18094
18132
  _("label", uM, [
18095
18133
  _("span", dM, K(n.messages.dialog.customType), 1),
18096
18134
  Ae(_("input", {
18097
- "onUpdate:modelValue": I[1] || (I[1] = (E) => a.value.type = E),
18135
+ "onUpdate:modelValue": E[1] || (E[1] = (I) => a.value.type = I),
18098
18136
  placeholder: n.messages.placeholders.type,
18099
18137
  class: "aimd-field-input"
18100
18138
  }, null, 8, fM), [
@@ -18105,7 +18143,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18105
18143
  _("label", pM, [
18106
18144
  _("span", mM, K(n.messages.dialog.defaultValue), 1),
18107
18145
  Ae(_("input", {
18108
- "onUpdate:modelValue": I[2] || (I[2] = (E) => a.value.default = E),
18146
+ "onUpdate:modelValue": E[2] || (E[2] = (I) => a.value.default = I),
18109
18147
  placeholder: n.messages.placeholders.defaultValue,
18110
18148
  class: "aimd-field-input"
18111
18149
  }, null, 8, gM), [
@@ -18115,7 +18153,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18115
18153
  _("label", yM, [
18116
18154
  _("span", bM, K(n.messages.dialog.titleLabel), 1),
18117
18155
  Ae(_("input", {
18118
- "onUpdate:modelValue": I[3] || (I[3] = (E) => a.value.title = E),
18156
+ "onUpdate:modelValue": E[3] || (E[3] = (I) => a.value.title = I),
18119
18157
  placeholder: n.messages.placeholders.title,
18120
18158
  class: "aimd-field-input"
18121
18159
  }, null, 8, kM), [
@@ -18127,10 +18165,10 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18127
18165
  _("label", wM, [
18128
18166
  _("span", xM, [
18129
18167
  fn(K(n.messages.dialog.tableId) + " ", 1),
18130
- I[20] || (I[20] = _("em", null, "*", -1))
18168
+ E[20] || (E[20] = _("em", null, "*", -1))
18131
18169
  ]),
18132
18170
  Ae(_("input", {
18133
- "onUpdate:modelValue": I[4] || (I[4] = (E) => a.value.name = E),
18171
+ "onUpdate:modelValue": E[4] || (E[4] = (I) => a.value.name = I),
18134
18172
  placeholder: n.messages.placeholders.tableId,
18135
18173
  class: "aimd-field-input"
18136
18174
  }, null, 8, CM), [
@@ -18140,7 +18178,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18140
18178
  _("label", SM, [
18141
18179
  _("span", vM, K(n.messages.dialog.subVariableColumns), 1),
18142
18180
  Ae(_("input", {
18143
- "onUpdate:modelValue": I[5] || (I[5] = (E) => a.value.subvars = E),
18181
+ "onUpdate:modelValue": E[5] || (E[5] = (I) => a.value.subvars = I),
18144
18182
  placeholder: n.messages.placeholders.subVariableColumns,
18145
18183
  class: "aimd-field-input"
18146
18184
  }, null, 8, TM), [
@@ -18151,22 +18189,22 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18151
18189
  ], 64)) : De("", !0),
18152
18190
  l.value === "step" ? (Z(), ie(We, { key: 2 }, [
18153
18191
  _("label", AM, [
18154
- _("span", EM, [
18192
+ _("span", IM, [
18155
18193
  fn(K(n.messages.dialog.stepId) + " ", 1),
18156
- I[21] || (I[21] = _("em", null, "*", -1))
18194
+ E[21] || (E[21] = _("em", null, "*", -1))
18157
18195
  ]),
18158
18196
  Ae(_("input", {
18159
- "onUpdate:modelValue": I[6] || (I[6] = (E) => a.value.name = E),
18197
+ "onUpdate:modelValue": E[6] || (E[6] = (I) => a.value.name = I),
18160
18198
  placeholder: n.messages.placeholders.stepId,
18161
18199
  class: "aimd-field-input"
18162
- }, null, 8, IM), [
18200
+ }, null, 8, EM), [
18163
18201
  [qe, a.value.name]
18164
18202
  ])
18165
18203
  ]),
18166
18204
  _("label", NM, [
18167
18205
  _("span", OM, K(n.messages.dialog.level), 1),
18168
18206
  Ae(_("select", {
18169
- "onUpdate:modelValue": I[7] || (I[7] = (E) => a.value.level = E),
18207
+ "onUpdate:modelValue": E[7] || (E[7] = (I) => a.value.level = I),
18170
18208
  class: "aimd-field-input"
18171
18209
  }, [
18172
18210
  _("option", RM, K(n.messages.dialog.level1), 1),
@@ -18181,10 +18219,10 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18181
18219
  _("label", LM, [
18182
18220
  _("span", PM, [
18183
18221
  fn(K(n.messages.dialog.quizId) + " ", 1),
18184
- I[22] || (I[22] = _("em", null, "*", -1))
18222
+ E[22] || (E[22] = _("em", null, "*", -1))
18185
18223
  ]),
18186
18224
  Ae(_("input", {
18187
- "onUpdate:modelValue": I[8] || (I[8] = (E) => a.value.id = E),
18225
+ "onUpdate:modelValue": E[8] || (E[8] = (I) => a.value.id = I),
18188
18226
  placeholder: n.messages.placeholders.quizId,
18189
18227
  class: "aimd-field-input"
18190
18228
  }, null, 8, zM), [
@@ -18194,7 +18232,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18194
18232
  _("label", BM, [
18195
18233
  _("span", FM, K(n.messages.dialog.questionType), 1),
18196
18234
  Ae(_("select", {
18197
- "onUpdate:modelValue": I[9] || (I[9] = (E) => a.value.quizType = E),
18235
+ "onUpdate:modelValue": E[9] || (E[9] = (I) => a.value.quizType = I),
18198
18236
  class: "aimd-field-input"
18199
18237
  }, [
18200
18238
  _("option", $M, K(n.messages.quiz.types.choice), 1),
@@ -18207,7 +18245,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18207
18245
  _("label", qM, [
18208
18246
  _("span", WM, K(n.messages.dialog.score), 1),
18209
18247
  Ae(_("input", {
18210
- "onUpdate:modelValue": I[10] || (I[10] = (E) => a.value.score = E),
18248
+ "onUpdate:modelValue": E[10] || (E[10] = (I) => a.value.score = I),
18211
18249
  placeholder: n.messages.placeholders.score,
18212
18250
  class: "aimd-field-input"
18213
18251
  }, null, 8, jM), [
@@ -18217,10 +18255,10 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18217
18255
  _("label", UM, [
18218
18256
  _("span", KM, [
18219
18257
  fn(K(n.messages.dialog.stem) + " ", 1),
18220
- I[23] || (I[23] = _("em", null, "*", -1))
18258
+ E[23] || (E[23] = _("em", null, "*", -1))
18221
18259
  ]),
18222
18260
  Ae(_("textarea", {
18223
- "onUpdate:modelValue": I[11] || (I[11] = (E) => a.value.stem = E),
18261
+ "onUpdate:modelValue": E[11] || (E[11] = (I) => a.value.stem = I),
18224
18262
  placeholder: n.messages.placeholders.stem,
18225
18263
  class: "aimd-field-input aimd-field-textarea"
18226
18264
  }, null, 8, JM), [
@@ -18232,7 +18270,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18232
18270
  _("label", YM, [
18233
18271
  _("span", QM, K(n.messages.dialog.mode), 1),
18234
18272
  Ae(_("select", {
18235
- "onUpdate:modelValue": I[12] || (I[12] = (E) => a.value.mode = E),
18273
+ "onUpdate:modelValue": E[12] || (E[12] = (I) => a.value.mode = I),
18236
18274
  class: "aimd-field-input"
18237
18275
  }, [
18238
18276
  _("option", XM, K(n.messages.quiz.modes.single), 1),
@@ -18244,7 +18282,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18244
18282
  _("div", e2, [
18245
18283
  _("span", t2, K(n.messages.dialog.options), 1),
18246
18284
  _("div", n2, [
18247
- (Z(!0), ie(We, null, zn(c.value, (E, oe) => (Z(), ie("div", {
18285
+ (Z(!0), ie(We, null, zn(c.value, (I, oe) => (Z(), ie("div", {
18248
18286
  key: `choice-option-${oe}`,
18249
18287
  class: ao(["aimd-collection-row aimd-option-row", { "aimd-option-row-dragover": h.value === oe && f.value !== null && f.value !== oe }]),
18250
18288
  onDragover: ys((be) => W(oe), ["prevent"]),
@@ -18258,35 +18296,35 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18258
18296
  onDragend: Q
18259
18297
  }, " ⋮⋮ ", 40, i2),
18260
18298
  Ae(_("input", {
18261
- "onUpdate:modelValue": (be) => E.key = be,
18299
+ "onUpdate:modelValue": (be) => I.key = be,
18262
18300
  placeholder: n.messages.placeholders.optionKey,
18263
18301
  class: "aimd-field-input"
18264
18302
  }, null, 8, o2), [
18265
- [qe, E.key]
18303
+ [qe, I.key]
18266
18304
  ]),
18267
18305
  Ae(_("input", {
18268
- "onUpdate:modelValue": (be) => E.text = be,
18306
+ "onUpdate:modelValue": (be) => I.text = be,
18269
18307
  placeholder: n.messages.placeholders.optionText,
18270
18308
  class: "aimd-field-input"
18271
18309
  }, null, 8, s2), [
18272
- [qe, E.text]
18310
+ [qe, I.text]
18273
18311
  ]),
18274
18312
  _("label", l2, [
18275
18313
  a.value.mode === "single" ? Ae((Z(), ie("input", {
18276
18314
  key: 0,
18277
- "onUpdate:modelValue": I[13] || (I[13] = (be) => a.value.answer = be),
18315
+ "onUpdate:modelValue": E[13] || (E[13] = (be) => a.value.answer = be),
18278
18316
  type: "radio",
18279
18317
  name: "aimd-quiz-choice-answer",
18280
- value: E.key.trim(),
18281
- disabled: !E.key.trim()
18318
+ value: I.key.trim(),
18319
+ disabled: !I.key.trim()
18282
18320
  }, null, 8, a2)), [
18283
- [Ib, a.value.answer]
18321
+ [Eb, a.value.answer]
18284
18322
  ]) : Ae((Z(), ie("input", {
18285
18323
  key: 1,
18286
- "onUpdate:modelValue": I[14] || (I[14] = (be) => d.value = be),
18324
+ "onUpdate:modelValue": E[14] || (E[14] = (be) => d.value = be),
18287
18325
  type: "checkbox",
18288
- value: E.key.trim(),
18289
- disabled: !E.key.trim()
18326
+ value: I.key.trim(),
18327
+ disabled: !I.key.trim()
18290
18328
  }, null, 8, c2)), [
18291
18329
  [Nb, d.value]
18292
18330
  ]),
@@ -18310,23 +18348,23 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18310
18348
  ], 64)) : a.value.quizType === "blank" ? (Z(), ie("div", f2, [
18311
18349
  _("span", h2, K(n.messages.dialog.blanks), 1),
18312
18350
  _("div", p2, [
18313
- (Z(!0), ie(We, null, zn(u.value, (E, oe) => (Z(), ie("div", {
18351
+ (Z(!0), ie(We, null, zn(u.value, (I, oe) => (Z(), ie("div", {
18314
18352
  key: `blank-item-${oe}`,
18315
18353
  class: "aimd-collection-row"
18316
18354
  }, [
18317
18355
  Ae(_("input", {
18318
- "onUpdate:modelValue": (be) => E.key = be,
18356
+ "onUpdate:modelValue": (be) => I.key = be,
18319
18357
  placeholder: n.messages.placeholders.blankKey,
18320
18358
  class: "aimd-field-input"
18321
18359
  }, null, 8, m2), [
18322
- [qe, E.key]
18360
+ [qe, I.key]
18323
18361
  ]),
18324
18362
  Ae(_("input", {
18325
- "onUpdate:modelValue": (be) => E.answer = be,
18363
+ "onUpdate:modelValue": (be) => I.answer = be,
18326
18364
  placeholder: n.messages.placeholders.blankAnswer,
18327
18365
  class: "aimd-field-input"
18328
18366
  }, null, 8, g2), [
18329
- [qe, E.answer]
18367
+ [qe, I.answer]
18330
18368
  ]),
18331
18369
  _("button", {
18332
18370
  type: "button",
@@ -18345,7 +18383,7 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18345
18383
  ])) : (Z(), ie("label", k2, [
18346
18384
  _("span", w2, K(n.messages.dialog.rubric), 1),
18347
18385
  Ae(_("textarea", {
18348
- "onUpdate:modelValue": I[15] || (I[15] = (E) => a.value.rubric = E),
18386
+ "onUpdate:modelValue": E[15] || (E[15] = (I) => a.value.rubric = I),
18349
18387
  placeholder: n.messages.placeholders.rubric,
18350
18388
  class: "aimd-field-input aimd-field-textarea"
18351
18389
  }, null, 8, x2), [
@@ -18356,10 +18394,10 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18356
18394
  l.value === "check" ? (Z(), ie("label", C2, [
18357
18395
  _("span", S2, [
18358
18396
  fn(K(n.messages.dialog.checkpointId) + " ", 1),
18359
- I[24] || (I[24] = _("em", null, "*", -1))
18397
+ E[24] || (E[24] = _("em", null, "*", -1))
18360
18398
  ]),
18361
18399
  Ae(_("input", {
18362
- "onUpdate:modelValue": I[16] || (I[16] = (E) => a.value.name = E),
18400
+ "onUpdate:modelValue": E[16] || (E[16] = (I) => a.value.name = I),
18363
18401
  placeholder: n.messages.placeholders.checkpointId,
18364
18402
  class: "aimd-field-input"
18365
18403
  }, null, 8, v2), [
@@ -18369,31 +18407,31 @@ const UT = { class: "aimd-dialog" }, KT = { class: "aimd-dialog-header" }, JT =
18369
18407
  ["ref_step", "ref_var", "ref_fig"].includes(l.value) ? (Z(), ie("label", T2, [
18370
18408
  _("span", M2, [
18371
18409
  fn(K(nt.value) + " ", 1),
18372
- I[25] || (I[25] = _("em", null, "*", -1))
18410
+ E[25] || (E[25] = _("em", null, "*", -1))
18373
18411
  ]),
18374
18412
  Ae(_("input", {
18375
- "onUpdate:modelValue": I[17] || (I[17] = (E) => a.value.name = E),
18413
+ "onUpdate:modelValue": E[17] || (E[17] = (I) => a.value.name = I),
18376
18414
  placeholder: $t.value,
18377
18415
  class: "aimd-field-input",
18378
18416
  list: "aimd-ref-suggestions"
18379
18417
  }, null, 8, A2), [
18380
18418
  [qe, a.value.name]
18381
18419
  ]),
18382
- _("datalist", E2, [
18383
- (Z(!0), ie(We, null, zn(Ge.value, (E) => (Z(), ie("option", {
18384
- key: E,
18385
- value: E
18386
- }, null, 8, I2))), 128))
18420
+ _("datalist", I2, [
18421
+ (Z(!0), ie(We, null, zn(Ge.value, (I) => (Z(), ie("option", {
18422
+ key: I,
18423
+ value: I
18424
+ }, null, 8, E2))), 128))
18387
18425
  ]),
18388
18426
  Ge.value.length ? (Z(), ie("span", N2, K(n.messages.common.available) + ": " + K(Ge.value.join(", ")), 1)) : De("", !0)
18389
18427
  ])) : De("", !0),
18390
18428
  l.value === "cite" ? (Z(), ie("label", O2, [
18391
18429
  _("span", R2, [
18392
18430
  fn(K(n.messages.dialog.citationId) + " ", 1),
18393
- I[26] || (I[26] = _("em", null, "*", -1))
18431
+ E[26] || (E[26] = _("em", null, "*", -1))
18394
18432
  ]),
18395
18433
  Ae(_("input", {
18396
- "onUpdate:modelValue": I[18] || (I[18] = (E) => a.value.refs = E),
18434
+ "onUpdate:modelValue": E[18] || (E[18] = (I) => a.value.refs = I),
18397
18435
  placeholder: n.messages.placeholders.citationIds,
18398
18436
  class: "aimd-field-input"
18399
18437
  }, null, 8, D2), [
@@ -18833,14 +18871,14 @@ const rA = {
18833
18871
  }, null, 512)
18834
18872
  ], 4));
18835
18873
  }
18836
- }), El = /* @__PURE__ */ Symbol("editorInfoCtxKey");
18874
+ }), Il = /* @__PURE__ */ Symbol("editorInfoCtxKey");
18837
18875
  function oA() {
18838
18876
  const {
18839
18877
  dom: t,
18840
18878
  loading: e,
18841
18879
  editor: n,
18842
18880
  editorFactory: r
18843
- } = jc(El, {}), i = ye();
18881
+ } = jc(Il, {}), i = ye();
18844
18882
  return ul(() => {
18845
18883
  if (!t.value) return;
18846
18884
  const o = r.value(t.value);
@@ -18868,7 +18906,7 @@ const sA = /* @__PURE__ */ qn({
18868
18906
  slots: e
18869
18907
  }) => {
18870
18908
  const n = ye(null), r = ye(void 0), i = ye(void 0), o = ye(!0);
18871
- return Ob(El, {
18909
+ return Ob(Il, {
18872
18910
  loading: o,
18873
18911
  dom: n,
18874
18912
  editor: i,
@@ -18877,14 +18915,14 @@ const sA = /* @__PURE__ */ qn({
18877
18915
  }
18878
18916
  });
18879
18917
  function aA(t) {
18880
- const { editorFactory: e, loading: n, editor: r } = jc(El);
18918
+ const { editorFactory: e, loading: n, editor: r } = jc(Il);
18881
18919
  return e.value = t, {
18882
18920
  loading: n,
18883
18921
  get: () => r.value
18884
18922
  };
18885
18923
  }
18886
18924
  function cA() {
18887
- const t = jc(El);
18925
+ const t = jc(Il);
18888
18926
  return [t.loading, () => t.editor.value];
18889
18927
  }
18890
18928
  function uA(t, e) {
@@ -18968,7 +19006,7 @@ function mA(t) {
18968
19006
  const e = /* @__PURE__ */ new Map();
18969
19007
  if (!t || !t.type)
18970
19008
  throw new Error("mdast-util-definitions expected node");
18971
- return Ii(t, "definition", function(r) {
19009
+ return Ei(t, "definition", function(r) {
18972
19010
  const i = Xh(r.identifier);
18973
19011
  i && !e.get(i) && e.set(i, r);
18974
19012
  }), n;
@@ -18983,7 +19021,7 @@ function Xh(t) {
18983
19021
  function gA() {
18984
19022
  return function(t) {
18985
19023
  const e = mA(t);
18986
- Ii(t, function(n, r, i) {
19024
+ Ei(t, function(n, r, i) {
18987
19025
  if (n.type === "definition" && i !== void 0 && typeof r == "number")
18988
19026
  return i.children.splice(r, 1), [Ga, r];
18989
19027
  if (n.type === "imageReference" || n.type === "linkReference") {
@@ -19152,8 +19190,8 @@ L(Go.ctx, {
19152
19190
  displayName: "MarkSchemaCtx<strong>",
19153
19191
  group: "Strong"
19154
19192
  });
19155
- const Eu = le("ToggleStrong", (t) => () => Cl(Go.type(t)));
19156
- L(Eu, {
19193
+ const Iu = le("ToggleStrong", (t) => () => Cl(Go.type(t)));
19194
+ L(Iu, {
19157
19195
  displayName: "Command<toggleStrongCommand>",
19158
19196
  group: "Strong"
19159
19197
  });
@@ -19170,20 +19208,20 @@ L(Ly, {
19170
19208
  displayName: "InputRule<strong>",
19171
19209
  group: "Strong"
19172
19210
  });
19173
- const Iu = Nt("strongKeymap", {
19211
+ const Eu = Nt("strongKeymap", {
19174
19212
  ToggleBold: {
19175
19213
  shortcuts: ["Mod-b"],
19176
19214
  command: (t) => {
19177
19215
  const e = t.get(te);
19178
- return () => e.call(Eu.key);
19216
+ return () => e.call(Iu.key);
19179
19217
  }
19180
19218
  }
19181
19219
  });
19182
- L(Iu.ctx, {
19220
+ L(Eu.ctx, {
19183
19221
  displayName: "KeymapCtx<strong>",
19184
19222
  group: "Strong"
19185
19223
  });
19186
- L(Iu.shortcuts, {
19224
+ L(Eu.shortcuts, {
19187
19225
  displayName: "Keymap<strong>",
19188
19226
  group: "Strong"
19189
19227
  });
@@ -19366,15 +19404,15 @@ function yA(t) {
19366
19404
  !0
19367
19405
  );
19368
19406
  }
19369
- const Il = wr(
19407
+ const El = wr(
19370
19408
  "remark-preserve-empty-line",
19371
19409
  () => () => yA
19372
19410
  );
19373
- L(Il.plugin, {
19411
+ L(El.plugin, {
19374
19412
  displayName: "Remark<remarkPreserveEmptyLine>",
19375
19413
  group: "Remark"
19376
19414
  });
19377
- L(Il.options, {
19415
+ L(El.options, {
19378
19416
  displayName: "RemarkConfig<remarkPreserveEmptyLine>",
19379
19417
  group: "Remark"
19380
19418
  });
@@ -19405,7 +19443,7 @@ const sn = He("paragraph", (t) => ({
19405
19443
  function bA(t) {
19406
19444
  let e = !1;
19407
19445
  try {
19408
- t.get(Il.id), e = !0;
19446
+ t.get(El.id), e = !0;
19409
19447
  } catch {
19410
19448
  e = !1;
19411
19449
  }
@@ -19889,7 +19927,7 @@ L(Wy, {
19889
19927
  group: "Image"
19890
19928
  });
19891
19929
  const CA = bt(
19892
- (t) => new Et(
19930
+ (t) => new It(
19893
19931
  /!\[(?<alt>.*?)]\((?<filename>.*?)\s*(?="|\))"?(?<title>[^"]+)?"?\)/,
19894
19932
  (e, n, r, i) => {
19895
19933
  const [o, s, l = "", a] = n;
@@ -20030,7 +20068,7 @@ L(Pi.ctx, {
20030
20068
  group: "Hr"
20031
20069
  });
20032
20070
  const jy = bt(
20033
- (t) => new Et(/^(?:---|___\s|\*\*\*\s)$/, (e, n, r, i) => {
20071
+ (t) => new It(/^(?:---|___\s|\*\*\*\s)$/, (e, n, r, i) => {
20034
20072
  const { tr: o } = e;
20035
20073
  return n[0] && o.replaceWith(r - 1, i, Pi.type(t).create()), o;
20036
20074
  })
@@ -20517,9 +20555,9 @@ const vA = [
20517
20555
  const { doc: n, selection: r } = e;
20518
20556
  return n.rangeHasMark(r.from, r.to, t);
20519
20557
  }
20520
- ), EA = le(
20558
+ ), IA = le(
20521
20559
  "IsNoteSelected",
20522
- () => (t) => (e) => t ? ES(e, t).hasNode : !1
20560
+ () => (t) => (e) => t ? IS(e, t).hasNode : !1
20523
20561
  ), tn = le(
20524
20562
  "ClearTextInCurrentBlock",
20525
20563
  () => () => (t, e) => {
@@ -20555,7 +20593,7 @@ const vA = [
20555
20593
  }
20556
20594
  return n?.(o), !0;
20557
20595
  }
20558
- ), Ec = le(
20596
+ ), Ic = le(
20559
20597
  "AddBlockType",
20560
20598
  () => (t) => (e, n) => {
20561
20599
  const { nodeType: r, attrs: i = null } = t ?? {};
@@ -20570,7 +20608,7 @@ const vA = [
20570
20608
  }
20571
20609
  return n?.(o), !0;
20572
20610
  }
20573
- ), IA = le(
20611
+ ), EA = le(
20574
20612
  "SelectTextNearPos",
20575
20613
  () => (t) => (e, n) => {
20576
20614
  const { pos: r } = t ?? {};
@@ -20602,16 +20640,16 @@ const vA = [
20602
20640
  sd,
20603
20641
  Tu,
20604
20642
  Ou,
20605
- Eu,
20643
+ Iu,
20606
20644
  zy,
20607
20645
  By,
20608
20646
  AA,
20609
- EA,
20647
+ IA,
20610
20648
  tn,
20611
20649
  ci,
20612
20650
  Bs,
20613
- Ec,
20614
- IA
20651
+ Ic,
20652
+ EA
20615
20653
  ], OA = [
20616
20654
  Vu,
20617
20655
  ju,
@@ -20623,11 +20661,11 @@ const vA = [
20623
20661
  Pu,
20624
20662
  Mu,
20625
20663
  Ru,
20626
- Iu
20664
+ Eu
20627
20665
  ].flat(), ud = wr(
20628
20666
  "remarkAddOrderInList",
20629
20667
  () => () => (t) => {
20630
- Ii(t, "list", (e) => {
20668
+ Ei(t, "list", (e) => {
20631
20669
  if (e.ordered) {
20632
20670
  const n = e.start ?? 1;
20633
20671
  e.children.forEach((r, i) => {
@@ -20649,7 +20687,7 @@ const dd = wr(
20649
20687
  "remarkLineBreak",
20650
20688
  () => () => (t) => {
20651
20689
  const e = /[\t ]*(?:\r?\n|\r)/g;
20652
- Ii(
20690
+ Ei(
20653
20691
  t,
20654
20692
  "text",
20655
20693
  (n, r, i) => {
@@ -20731,7 +20769,7 @@ const pd = wr(
20731
20769
  "remarkMarker",
20732
20770
  () => () => (t, e) => {
20733
20771
  const n = (r) => e.value.charAt(r.position.start.offset);
20734
- Ii(
20772
+ Ei(
20735
20773
  t,
20736
20774
  (r) => ["strong", "emphasis"].includes(r.type),
20737
20775
  (r) => {
@@ -20748,7 +20786,7 @@ L(pd.options, {
20748
20786
  displayName: "RemarkConfig<remarkMarker>",
20749
20787
  group: "Remark"
20750
20788
  });
20751
- const Yy = It(() => {
20789
+ const Yy = Et(() => {
20752
20790
  let t = !1;
20753
20791
  const e = new Be(
20754
20792
  "MILKDOWN_INLINE_NODES_CURSOR"
@@ -20800,7 +20838,7 @@ L(Yy, {
20800
20838
  displayName: "Prose<inlineNodesCursorPlugin>",
20801
20839
  group: "Prose"
20802
20840
  });
20803
- const Qy = It((t) => new $e({
20841
+ const Qy = Et((t) => new $e({
20804
20842
  key: new Be("MILKDOWN_HARDBREAK_MARKS"),
20805
20843
  appendTransaction: (e, n, r) => {
20806
20844
  if (!e.length) return;
@@ -20843,7 +20881,7 @@ L(md, {
20843
20881
  displayName: "Ctx<hardbreakFilterNodes>",
20844
20882
  group: "Prose"
20845
20883
  });
20846
- const Xy = It((t) => {
20884
+ const Xy = Et((t) => {
20847
20885
  const e = t.get(md.key);
20848
20886
  return new $e({
20849
20887
  key: new Be("MILKDOWN_HARDBREAK_FILTER"),
@@ -20864,7 +20902,7 @@ L(Xy, {
20864
20902
  displayName: "Prose<hardbreakFilterPlugin>",
20865
20903
  group: "Prose"
20866
20904
  });
20867
- const Zy = It((t) => {
20905
+ const Zy = Et((t) => {
20868
20906
  const e = new Be("MILKDOWN_HEADING_ID"), n = (r) => {
20869
20907
  if (r.composing) return;
20870
20908
  const i = t.get(Nl.key), o = r.state.tr.setMeta("addToHistory", !1);
@@ -20895,7 +20933,7 @@ L(Zy, {
20895
20933
  displayName: "Prose<syncHeadingIdPlugin>",
20896
20934
  group: "Prose"
20897
20935
  });
20898
- const e1 = It((t) => {
20936
+ const e1 = Et((t) => {
20899
20937
  const e = (n, r, i) => {
20900
20938
  if (!i.selection || n.some(
20901
20939
  (d) => d.getMeta("addToHistory") === !1 || !d.isGeneric
@@ -20947,7 +20985,7 @@ const PA = [
20947
20985
  dd,
20948
20986
  hd,
20949
20987
  pd,
20950
- Il,
20988
+ El,
20951
20989
  Zy,
20952
20990
  e1
20953
20991
  ].flat(), zA = [
@@ -20958,14 +20996,14 @@ const PA = [
20958
20996
  OA,
20959
20997
  PA
20960
20998
  ].flat();
20961
- let Ic, Nc;
20999
+ let Ec, Nc;
20962
21000
  if (typeof WeakMap < "u") {
20963
21001
  let t = /* @__PURE__ */ new WeakMap();
20964
- Ic = (e) => t.get(e), Nc = (e, n) => (t.set(e, n), n);
21002
+ Ec = (e) => t.get(e), Nc = (e, n) => (t.set(e, n), n);
20965
21003
  } else {
20966
21004
  const t = [];
20967
21005
  let n = 0;
20968
- Ic = (r) => {
21006
+ Ec = (r) => {
20969
21007
  for (let i = 0; i < t.length; i += 2) if (t[i] == r) return t[i + 1];
20970
21008
  }, Nc = (r, i) => (n == 10 && (n = 0), t[n++] = r, t[n++] = i);
20971
21009
  }
@@ -21028,7 +21066,7 @@ var ve = class {
21028
21066
  }
21029
21067
  }
21030
21068
  static get(t) {
21031
- return Ic(t) || Nc(t, BA(t));
21069
+ return Ec(t) || Nc(t, BA(t));
21032
21070
  }
21033
21071
  };
21034
21072
  function BA(t) {
@@ -21491,14 +21529,14 @@ function r1(t, e, n, r) {
21491
21529
  r(a, n), l < i && t.child(l).sameMarkup(a) ? r1(t.child(l), a, n + 1, r) : a.nodesBetween(0, a.content.size, r, n + 1), n += a.nodeSize;
21492
21530
  }
21493
21531
  }
21494
- function eE(t, e) {
21532
+ function eI(t, e) {
21495
21533
  let n;
21496
21534
  const r = (i, o) => {
21497
- i.type.spec.tableRole == "table" && (n = tE(t, i, o, n));
21535
+ i.type.spec.tableRole == "table" && (n = tI(t, i, o, n));
21498
21536
  };
21499
21537
  return e ? e.doc != t.doc && r1(e.doc, t.doc, 0, r) : t.doc.descendants(r), n;
21500
21538
  }
21501
- function tE(t, e, n, r) {
21539
+ function tI(t, e, n, r) {
21502
21540
  const i = ve.get(e);
21503
21541
  if (!i.problems) return r;
21504
21542
  r || (r = t.tr);
@@ -21600,9 +21638,9 @@ function s1(t, e, n, r) {
21600
21638
  return l = i === -1 ? n[0] : n[n.length - 1] - s, t.splice(l, 0, ...o), t;
21601
21639
  }
21602
21640
  function zi(t) {
21603
- return nE((e) => e.type.spec.tableRole === "table", t);
21641
+ return nI((e) => e.type.spec.tableRole === "table", t);
21604
21642
  }
21605
- function nE(t, e) {
21643
+ function nI(t, e) {
21606
21644
  for (let n = e.depth; n >= 0; n -= 1) {
21607
21645
  const r = e.node(n);
21608
21646
  if (t(r)) return {
@@ -21743,33 +21781,33 @@ function np(t, e, n = e) {
21743
21781
  function rp(t) {
21744
21782
  return t[0].map((e, n) => t.map((r) => r[n]));
21745
21783
  }
21746
- function rE(t) {
21784
+ function rI(t) {
21747
21785
  var e, n;
21748
21786
  const { tr: r, originIndex: i, targetIndex: o, select: s, pos: l } = t, a = zi(r.doc.resolve(l));
21749
21787
  if (!a) return !1;
21750
21788
  const c = (e = tp(r, i)) === null || e === void 0 ? void 0 : e.indexes, u = (n = tp(r, o)) === null || n === void 0 ? void 0 : n.indexes;
21751
21789
  if (!c || !u || c.includes(o)) return !1;
21752
- const d = iE(a.node, c, u);
21790
+ const d = iI(a.node, c, u);
21753
21791
  if (r.replaceWith(a.pos, a.pos + a.node.nodeSize, d), !s) return !0;
21754
21792
  const f = ve.get(d), h = a.start, p = o, m = f.positionAt(f.height - 1, p, d), g = r.doc.resolve(h + m), y = f.positionAt(0, p, d), M = r.doc.resolve(h + y);
21755
21793
  return r.setSelection(Me.colSelection(g, M)), !0;
21756
21794
  }
21757
- function iE(t, e, n, r) {
21795
+ function iI(t, e, n, r) {
21758
21796
  let i = rp(i1(t));
21759
21797
  return i = s1(i, e, n), i = rp(i), o1(t, i);
21760
21798
  }
21761
- function oE(t) {
21799
+ function oI(t) {
21762
21800
  var e, n;
21763
21801
  const { tr: r, originIndex: i, targetIndex: o, select: s, pos: l } = t, a = zi(r.doc.resolve(l));
21764
21802
  if (!a) return !1;
21765
21803
  const c = (e = np(r, i)) === null || e === void 0 ? void 0 : e.indexes, u = (n = np(r, o)) === null || n === void 0 ? void 0 : n.indexes;
21766
21804
  if (!c || !u || c.includes(o)) return !1;
21767
- const d = sE(a.node, c, u);
21805
+ const d = sI(a.node, c, u);
21768
21806
  if (r.replaceWith(a.pos, a.pos + a.node.nodeSize, d), !s) return !0;
21769
21807
  const f = ve.get(d), h = a.start, p = o, m = f.positionAt(p, f.width - 1, d), g = r.doc.resolve(h + m), y = f.positionAt(p, 0, d), M = r.doc.resolve(h + y);
21770
21808
  return r.setSelection(Me.rowSelection(g, M)), !0;
21771
21809
  }
21772
- function sE(t, e, n, r) {
21810
+ function sI(t, e, n, r) {
21773
21811
  let i = i1(t);
21774
21812
  return i = s1(i, e, n), o1(t, i);
21775
21813
  }
@@ -21797,7 +21835,7 @@ function l1(t, { map: e, tableStart: n, table: r }, i) {
21797
21835
  }
21798
21836
  return t;
21799
21837
  }
21800
- function lE(t, e) {
21838
+ function lI(t, e) {
21801
21839
  if (!Xt(t)) return !1;
21802
21840
  if (e) {
21803
21841
  const n = xr(t);
@@ -21805,7 +21843,7 @@ function lE(t, e) {
21805
21843
  }
21806
21844
  return !0;
21807
21845
  }
21808
- function aE(t, e) {
21846
+ function aI(t, e) {
21809
21847
  if (!Xt(t)) return !1;
21810
21848
  if (e) {
21811
21849
  const n = xr(t);
@@ -21813,7 +21851,7 @@ function aE(t, e) {
21813
21851
  }
21814
21852
  return !0;
21815
21853
  }
21816
- function cE(t, { map: e, table: n, tableStart: r }, i) {
21854
+ function cI(t, { map: e, table: n, tableStart: r }, i) {
21817
21855
  const o = t.mapping.maps.length;
21818
21856
  for (let s = 0; s < e.height; ) {
21819
21857
  const l = s * e.width + i, a = e.map[l], c = n.nodeAt(a), u = c.attrs;
@@ -21825,12 +21863,12 @@ function cE(t, { map: e, table: n, tableStart: r }, i) {
21825
21863
  s += u.rowspan;
21826
21864
  }
21827
21865
  }
21828
- function uE(t, e) {
21866
+ function uI(t, e) {
21829
21867
  if (!Xt(t)) return !1;
21830
21868
  if (e) {
21831
21869
  const n = xr(t), r = t.tr;
21832
21870
  if (n.left == 0 && n.right == n.map.width) return !1;
21833
- for (let i = n.right - 1; cE(r, n, i), i != n.left; i--) {
21871
+ for (let i = n.right - 1; cI(r, n, i), i != n.left; i--) {
21834
21872
  const o = n.tableStart ? r.doc.nodeAt(n.tableStart - 1) : r.doc;
21835
21873
  if (!o) throw new RangeError("No table found");
21836
21874
  n.table = o, n.map = ve.get(o);
@@ -21839,7 +21877,7 @@ function uE(t, e) {
21839
21877
  }
21840
21878
  return !0;
21841
21879
  }
21842
- function dE(t, { map: e, table: n, tableStart: r }, i) {
21880
+ function dI(t, { map: e, table: n, tableStart: r }, i) {
21843
21881
  let o = 0;
21844
21882
  for (let c = 0; c < i; c++) o += n.child(c).nodeSize;
21845
21883
  const s = o + n.child(i).nodeSize, l = t.mapping.maps.length;
@@ -21864,12 +21902,12 @@ function dE(t, { map: e, table: n, tableStart: r }, i) {
21864
21902
  }
21865
21903
  }
21866
21904
  }
21867
- function fE(t, e) {
21905
+ function fI(t, e) {
21868
21906
  if (!Xt(t)) return !1;
21869
21907
  if (e) {
21870
21908
  const n = xr(t), r = t.tr;
21871
21909
  if (n.top == 0 && n.bottom == n.map.height) return !1;
21872
- for (let i = n.bottom - 1; dE(r, n, i), i != n.top; i--) {
21910
+ for (let i = n.bottom - 1; dI(r, n, i), i != n.top; i--) {
21873
21911
  const o = n.tableStart ? r.doc.nodeAt(n.tableStart - 1) : r.doc;
21874
21912
  if (!o) throw new RangeError("No table found");
21875
21913
  n.table = o, n.map = ve.get(n.table);
@@ -21878,7 +21916,7 @@ function fE(t, e) {
21878
21916
  }
21879
21917
  return !0;
21880
21918
  }
21881
- function hE(t, e) {
21919
+ function hI(t, e) {
21882
21920
  return function(n, r) {
21883
21921
  if (!Xt(n)) return !1;
21884
21922
  const i = Ol(n);
@@ -21898,7 +21936,7 @@ function hE(t, e) {
21898
21936
  return !0;
21899
21937
  };
21900
21938
  }
21901
- function pE(t) {
21939
+ function pI(t) {
21902
21940
  return function(e, n) {
21903
21941
  if (!Xt(e)) return !1;
21904
21942
  if (n) {
@@ -21934,7 +21972,7 @@ function ip(t, e, n) {
21934
21972
  return !0;
21935
21973
  }
21936
21974
  function yd(t, e) {
21937
- return e = e || { useDeprecatedLogic: !1 }, e.useDeprecatedLogic ? pE(t) : function(n, r) {
21975
+ return e = e || { useDeprecatedLogic: !1 }, e.useDeprecatedLogic ? pI(t) : function(n, r) {
21938
21976
  if (!Xt(n)) return !1;
21939
21977
  if (r) {
21940
21978
  const i = Yt(n.schema), o = xr(n), s = n.tr, l = ip("row", o, i), a = ip("column", o, i), c = (t === "column" ? l : t === "row" && a) ? 1 : 0, u = t == "column" ? {
@@ -21959,7 +21997,7 @@ function yd(t, e) {
21959
21997
  yd("row", { useDeprecatedLogic: !0 });
21960
21998
  yd("column", { useDeprecatedLogic: !0 });
21961
21999
  yd("cell", { useDeprecatedLogic: !0 });
21962
- function mE(t, e) {
22000
+ function mI(t, e) {
21963
22001
  if (e < 0) {
21964
22002
  const n = t.nodeBefore;
21965
22003
  if (n) return t.pos - n.nodeSize;
@@ -21982,7 +22020,7 @@ function mE(t, e) {
21982
22020
  function a1(t) {
21983
22021
  return function(e, n) {
21984
22022
  if (!Xt(e)) return !1;
21985
- const r = mE(Ol(e), t);
22023
+ const r = mI(Ol(e), t);
21986
22024
  if (r == null) return !1;
21987
22025
  if (n) {
21988
22026
  const i = e.doc.resolve(r);
@@ -21991,7 +22029,7 @@ function a1(t) {
21991
22029
  return !0;
21992
22030
  };
21993
22031
  }
21994
- function gE(t, e) {
22032
+ function gI(t, e) {
21995
22033
  const n = t.selection.$anchor;
21996
22034
  for (let r = n.depth; r > 0; r--) if (n.node(r).type.spec.tableRole == "table")
21997
22035
  return e && e(t.tr.delete(n.before(r), n.after(r)).scrollIntoView()), !0;
@@ -22008,10 +22046,10 @@ function ds(t, e) {
22008
22046
  }
22009
22047
  return !0;
22010
22048
  }
22011
- function yE(t) {
22049
+ function yI(t) {
22012
22050
  return (e, n) => {
22013
22051
  const { from: r, to: i, select: o = !0, pos: s = e.selection.from } = t, l = e.tr;
22014
- return oE({
22052
+ return oI({
22015
22053
  tr: l,
22016
22054
  originIndex: r,
22017
22055
  targetIndex: i,
@@ -22020,10 +22058,10 @@ function yE(t) {
22020
22058
  }) ? (n?.(l), !0) : !1;
22021
22059
  };
22022
22060
  }
22023
- function bE(t) {
22061
+ function bI(t) {
22024
22062
  return (e, n) => {
22025
22063
  const { from: r, to: i, select: o = !0, pos: s = e.selection.from } = t, l = e.tr;
22026
- return rE({
22064
+ return rI({
22027
22065
  tr: l,
22028
22066
  originIndex: r,
22029
22067
  targetIndex: i,
@@ -22032,7 +22070,7 @@ function bE(t) {
22032
22070
  }) ? (n?.(l), !0) : !1;
22033
22071
  };
22034
22072
  }
22035
- function kE(t) {
22073
+ function kI(t) {
22036
22074
  if (t.size === 0) return null;
22037
22075
  let { content: e, openStart: n, openEnd: r } = t;
22038
22076
  for (; e.childCount == 1 && (n > 0 && r > 0 || e.child(0).type.spec.tableRole == "table"); )
@@ -22045,9 +22083,9 @@ function kE(t) {
22045
22083
  }
22046
22084
  else if (o == "cell" || o == "header_cell") l.push(n || r ? Rc(Yt(s).row, new q(e, n, r)).content : e);
22047
22085
  else return null;
22048
- return wE(s, l);
22086
+ return wI(s, l);
22049
22087
  }
22050
- function wE(t, e) {
22088
+ function wI(t, e) {
22051
22089
  const n = [];
22052
22090
  for (let i = 0; i < e.length; i++) {
22053
22091
  const o = e[i];
@@ -22074,7 +22112,7 @@ function Rc(t, e) {
22074
22112
  const n = t.createAndFill();
22075
22113
  return new hg(n).replace(0, n.content.size, e).doc;
22076
22114
  }
22077
- function xE({ width: t, height: e, rows: n }, r, i) {
22115
+ function xI({ width: t, height: e, rows: n }, r, i) {
22078
22116
  if (t != r) {
22079
22117
  const o = [], s = [];
22080
22118
  for (let l = 0; l < n.length; l++) {
@@ -22109,7 +22147,7 @@ function xE({ width: t, height: e, rows: n }, r, i) {
22109
22147
  rows: n
22110
22148
  };
22111
22149
  }
22112
- function CE(t, e, n, r, i, o, s) {
22150
+ function CI(t, e, n, r, i, o, s) {
22113
22151
  const l = t.doc.type.schema, a = Yt(l);
22114
22152
  let c, u;
22115
22153
  if (i > e.width) for (let d = 0, f = 0; d < e.height; d++) {
@@ -22175,14 +22213,14 @@ function lp(t, e, n, r, i) {
22175
22213
  if (o = n ? d.doc.nodeAt(n - 1) : d.doc, !o) throw new Error("No table found");
22176
22214
  s = ve.get(o), f = d.mapping.maps.length;
22177
22215
  }
22178
- CE(d, s, o, n, c, u, f) && h(), op(d, s, o, n, a, c, l, f) && h(), op(d, s, o, n, a, c, u, f) && h(), sp(d, s, o, n, l, u, a, f) && h(), sp(d, s, o, n, l, u, c, f) && h();
22216
+ CI(d, s, o, n, c, u, f) && h(), op(d, s, o, n, a, c, l, f) && h(), op(d, s, o, n, a, c, u, f) && h(), sp(d, s, o, n, l, u, a, f) && h(), sp(d, s, o, n, l, u, c, f) && h();
22179
22217
  for (let p = l; p < u; p++) {
22180
22218
  const m = s.positionAt(p, a, o), g = s.positionAt(p, c, o);
22181
22219
  d.replace(d.mapping.slice(f).map(m + n), d.mapping.slice(f).map(g + n), new q(i.rows[p - l], 0, 0));
22182
22220
  }
22183
22221
  h(), d.setSelection(new Me(d.doc.resolve(n + s.positionAt(l, a, o)), d.doc.resolve(n + s.positionAt(u - 1, c - 1, o)))), e(d);
22184
22222
  }
22185
- const SE = Rg({
22223
+ const SI = Rg({
22186
22224
  ArrowLeft: fs("horiz", -1),
22187
22225
  ArrowRight: fs("horiz", 1),
22188
22226
  ArrowUp: fs("vert", -1),
@@ -22230,13 +22268,13 @@ function hs(t, e) {
22230
22268
  return l ? Fs(n, r, new Me(s.$anchorCell, l)) : !1;
22231
22269
  };
22232
22270
  }
22233
- function vE(t, e) {
22271
+ function vI(t, e) {
22234
22272
  const n = t.state.doc, r = Mi(n.resolve(e));
22235
22273
  return r ? (t.dispatch(t.state.tr.setSelection(new Me(r))), !0) : !1;
22236
22274
  }
22237
- function TE(t, e, n) {
22275
+ function TI(t, e, n) {
22238
22276
  if (!Xt(t.state)) return !1;
22239
- let r = kE(n);
22277
+ let r = kI(n);
22240
22278
  const i = t.state.selection;
22241
22279
  if (i instanceof Me) {
22242
22280
  r || (r = {
@@ -22245,13 +22283,13 @@ function TE(t, e, n) {
22245
22283
  rows: [P.from(Rc(Yt(t.state.schema).cell, n))]
22246
22284
  });
22247
22285
  const o = i.$anchorCell.node(-1), s = i.$anchorCell.start(-1), l = ve.get(o).rectBetween(i.$anchorCell.pos - s, i.$headCell.pos - s);
22248
- return r = xE(r, l.right - l.left, l.bottom - l.top), lp(t.state, t.dispatch, s, l, r), !0;
22286
+ return r = xI(r, l.right - l.left, l.bottom - l.top), lp(t.state, t.dispatch, s, l, r), !0;
22249
22287
  } else if (r) {
22250
22288
  const o = Ol(t.state), s = o.start(-1);
22251
22289
  return lp(t.state, t.dispatch, s, ve.get(o.node(-1)).findCell(o.pos - s), r), !0;
22252
22290
  } else return !1;
22253
22291
  }
22254
- function ME(t, e) {
22292
+ function MI(t, e) {
22255
22293
  var n;
22256
22294
  if (e.button != 0 || e.ctrlKey || e.metaKey) return;
22257
22295
  const r = ap(t, e.target);
@@ -22311,7 +22349,7 @@ function Oa(t, e) {
22311
22349
  let { inside: r, pos: i } = n;
22312
22350
  return r >= 0 && Mi(t.state.doc.resolve(r)) || Mi(t.state.doc.resolve(i));
22313
22351
  }
22314
- var AE = class {
22352
+ var AI = class {
22315
22353
  constructor(t, e) {
22316
22354
  this.node = t, this.defaultCellMinWidth = e, this.dom = document.createElement("div"), this.dom.className = "tableWrapper", this.table = this.dom.appendChild(document.createElement("table")), this.table.style.setProperty("--default-cell-min-width", `${e}px`), this.colgroup = this.table.appendChild(document.createElement("colgroup")), Dc(t, this.colgroup, this.table, e), this.contentDOM = this.table.appendChild(document.createElement("tbody"));
22317
22355
  }
@@ -22347,14 +22385,14 @@ function Dc(t, e, n, r, i, o) {
22347
22385
  }
22348
22386
  }
22349
22387
  const Pt = new Be("tableColumnResizing");
22350
- function EE({ handleWidth: t = 5, cellMinWidth: e = 25, defaultCellMinWidth: n = 100, View: r = AE, lastColumnResizable: i = !0 } = {}) {
22388
+ function II({ handleWidth: t = 5, cellMinWidth: e = 25, defaultCellMinWidth: n = 100, View: r = AI, lastColumnResizable: i = !0 } = {}) {
22351
22389
  const o = new $e({
22352
22390
  key: Pt,
22353
22391
  state: {
22354
22392
  init(s, l) {
22355
22393
  var a;
22356
22394
  const c = (a = o.spec) === null || a === void 0 || (a = a.props) === null || a === void 0 ? void 0 : a.nodeViews, u = Yt(l.schema).table.name;
22357
- return r && c && (c[u] = (d, f) => new r(d, n, f)), new IE(-1, !1);
22395
+ return r && c && (c[u] = (d, f) => new r(d, n, f)), new EI(-1, !1);
22358
22396
  },
22359
22397
  apply(s, l) {
22360
22398
  return l.apply(s);
@@ -22367,25 +22405,25 @@ function EE({ handleWidth: t = 5, cellMinWidth: e = 25, defaultCellMinWidth: n =
22367
22405
  },
22368
22406
  handleDOMEvents: {
22369
22407
  mousemove: (s, l) => {
22370
- NE(s, l, t, i);
22408
+ NI(s, l, t, i);
22371
22409
  },
22372
22410
  mouseleave: (s) => {
22373
- OE(s);
22411
+ OI(s);
22374
22412
  },
22375
22413
  mousedown: (s, l) => {
22376
- RE(s, l, e, n);
22414
+ RI(s, l, e, n);
22377
22415
  }
22378
22416
  },
22379
22417
  decorations: (s) => {
22380
22418
  const l = Pt.getState(s);
22381
- if (l && l.activeHandle > -1) return zE(s, l.activeHandle);
22419
+ if (l && l.activeHandle > -1) return zI(s, l.activeHandle);
22382
22420
  },
22383
22421
  nodeViews: {}
22384
22422
  }
22385
22423
  });
22386
22424
  return o;
22387
22425
  }
22388
- var IE = class $s {
22426
+ var EI = class $s {
22389
22427
  constructor(e, n) {
22390
22428
  this.activeHandle = e, this.dragging = n;
22391
22429
  }
@@ -22400,11 +22438,11 @@ var IE = class $s {
22400
22438
  return n;
22401
22439
  }
22402
22440
  };
22403
- function NE(t, e, n, r) {
22441
+ function NI(t, e, n, r) {
22404
22442
  if (!t.editable) return;
22405
22443
  const i = Pt.getState(t.state);
22406
22444
  if (i && !i.dragging) {
22407
- const o = _E(e.target);
22445
+ const o = _I(e.target);
22408
22446
  let s = -1;
22409
22447
  if (o) {
22410
22448
  const { left: l, right: a } = o.getBoundingClientRect();
@@ -22419,17 +22457,17 @@ function NE(t, e, n, r) {
22419
22457
  }
22420
22458
  }
22421
22459
  }
22422
- function OE(t) {
22460
+ function OI(t) {
22423
22461
  if (!t.editable) return;
22424
22462
  const e = Pt.getState(t.state);
22425
22463
  e && e.activeHandle > -1 && !e.dragging && u1(t, -1);
22426
22464
  }
22427
- function RE(t, e, n, r) {
22465
+ function RI(t, e, n, r) {
22428
22466
  var i;
22429
22467
  if (!t.editable) return !1;
22430
22468
  const o = (i = t.dom.ownerDocument.defaultView) !== null && i !== void 0 ? i : window, s = Pt.getState(t.state);
22431
22469
  if (!s || s.activeHandle == -1 || s.dragging) return !1;
22432
- const l = t.state.doc.nodeAt(s.activeHandle), a = DE(t, s.activeHandle, l.attrs);
22470
+ const l = t.state.doc.nodeAt(s.activeHandle), a = DI(t, s.activeHandle, l.attrs);
22433
22471
  t.dispatch(t.state.tr.setMeta(Pt, { setDragging: {
22434
22472
  startX: e.clientX,
22435
22473
  startWidth: a
@@ -22437,7 +22475,7 @@ function RE(t, e, n, r) {
22437
22475
  function c(d) {
22438
22476
  o.removeEventListener("mouseup", c), o.removeEventListener("mousemove", u);
22439
22477
  const f = Pt.getState(t.state);
22440
- f?.dragging && (LE(t, f.activeHandle, up(f.dragging, d, n)), t.dispatch(t.state.tr.setMeta(Pt, { setDragging: null })));
22478
+ f?.dragging && (LI(t, f.activeHandle, up(f.dragging, d, n)), t.dispatch(t.state.tr.setMeta(Pt, { setDragging: null })));
22441
22479
  }
22442
22480
  function u(d) {
22443
22481
  if (!d.which) return c(d);
@@ -22449,7 +22487,7 @@ function RE(t, e, n, r) {
22449
22487
  }
22450
22488
  return dp(t, s.activeHandle, a, r), o.addEventListener("mouseup", c), o.addEventListener("mousemove", u), e.preventDefault(), !0;
22451
22489
  }
22452
- function DE(t, e, { colspan: n, colwidth: r }) {
22490
+ function DI(t, e, { colspan: n, colwidth: r }) {
22453
22491
  const i = r && r[r.length - 1];
22454
22492
  if (i) return i;
22455
22493
  const o = t.domAtPos(e);
@@ -22458,7 +22496,7 @@ function DE(t, e, { colspan: n, colwidth: r }) {
22458
22496
  for (let a = 0; a < n; a++) r[a] && (s -= r[a], l--);
22459
22497
  return s / l;
22460
22498
  }
22461
- function _E(t) {
22499
+ function _I(t) {
22462
22500
  for (; t && t.nodeName != "TD" && t.nodeName != "TH"; ) t = t.classList && t.classList.contains("ProseMirror") ? null : t.parentNode;
22463
22501
  return t;
22464
22502
  }
@@ -22481,14 +22519,14 @@ function up(t, e, n) {
22481
22519
  function u1(t, e) {
22482
22520
  t.dispatch(t.state.tr.setMeta(Pt, { setHandle: e }));
22483
22521
  }
22484
- function LE(t, e, n) {
22522
+ function LI(t, e, n) {
22485
22523
  const r = t.state.doc.resolve(e), i = r.node(-1), o = ve.get(i), s = r.start(-1), l = o.colCount(r.pos - s) + r.nodeAfter.attrs.colspan - 1, a = t.state.tr;
22486
22524
  for (let c = 0; c < o.height; c++) {
22487
22525
  const u = c * o.width + l;
22488
22526
  if (c && o.map[u] == o.map[u - o.width]) continue;
22489
22527
  const d = o.map[u], f = i.nodeAt(d).attrs, h = f.colspan == 1 ? 0 : l - o.colCount(d);
22490
22528
  if (f.colwidth && f.colwidth[h] == n) continue;
22491
- const p = f.colwidth ? f.colwidth.slice() : PE(f.colspan);
22529
+ const p = f.colwidth ? f.colwidth.slice() : PI(f.colspan);
22492
22530
  p[h] = n, a.setNodeMarkup(s + d, null, {
22493
22531
  ...f,
22494
22532
  colwidth: p
@@ -22502,10 +22540,10 @@ function dp(t, e, n, r) {
22502
22540
  for (; a && a.nodeName != "TABLE"; ) a = a.parentNode;
22503
22541
  a && Dc(o, a.firstChild, a, r, l, n);
22504
22542
  }
22505
- function PE(t) {
22543
+ function PI(t) {
22506
22544
  return Array(t).fill(0);
22507
22545
  }
22508
- function zE(t, e) {
22546
+ function zI(t, e) {
22509
22547
  const n = [], r = t.doc.resolve(e), i = r.node(-1);
22510
22548
  if (!i) return Ne.empty;
22511
22549
  const o = ve.get(i), s = r.start(-1), l = o.colCount(r.pos - s) + r.nodeAfter.attrs.colspan - 1;
@@ -22519,7 +22557,7 @@ function zE(t, e) {
22519
22557
  }
22520
22558
  return Ne.create(t.doc, n);
22521
22559
  }
22522
- function BE({ allowTableNodeSelection: t = !1 } = {}) {
22560
+ function BI({ allowTableNodeSelection: t = !1 } = {}) {
22523
22561
  return new $e({
22524
22562
  key: rr,
22525
22563
  state: {
@@ -22536,23 +22574,23 @@ function BE({ allowTableNodeSelection: t = !1 } = {}) {
22536
22574
  },
22537
22575
  props: {
22538
22576
  decorations: GA,
22539
- handleDOMEvents: { mousedown: ME },
22577
+ handleDOMEvents: { mousedown: MI },
22540
22578
  createSelectionBetween(e) {
22541
22579
  return rr.getState(e.state) != null ? e.state.selection : null;
22542
22580
  },
22543
- handleTripleClick: vE,
22544
- handleKeyDown: SE,
22545
- handlePaste: TE
22581
+ handleTripleClick: vI,
22582
+ handleKeyDown: SI,
22583
+ handlePaste: TI
22546
22584
  },
22547
22585
  appendTransaction(e, n, r) {
22548
- return XA(r, eE(r, n), t);
22586
+ return XA(r, eI(r, n), t);
22549
22587
  }
22550
22588
  });
22551
22589
  }
22552
- var rl = typeof navigator < "u" ? navigator : null, bd = rl && rl.userAgent || "", FE = /Edge\/(\d+)/.exec(bd), $E = /MSIE \d/.exec(bd), HE = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(bd), VE = !!($E || HE || FE), qE = !VE && !!rl && /Apple Computer/.test(rl.vendor), d1 = new Be("safari-ime-span"), _c = !1, WE = {
22590
+ var rl = typeof navigator < "u" ? navigator : null, bd = rl && rl.userAgent || "", FI = /Edge\/(\d+)/.exec(bd), $I = /MSIE \d/.exec(bd), HI = /Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(bd), VI = !!($I || HI || FI), qI = !VI && !!rl && /Apple Computer/.test(rl.vendor), d1 = new Be("safari-ime-span"), _c = !1, WI = {
22553
22591
  key: d1,
22554
22592
  props: {
22555
- decorations: jE,
22593
+ decorations: jI,
22556
22594
  handleDOMEvents: {
22557
22595
  compositionstart: () => {
22558
22596
  _c = !0;
@@ -22563,21 +22601,21 @@ var rl = typeof navigator < "u" ? navigator : null, bd = rl && rl.userAgent || "
22563
22601
  }
22564
22602
  }
22565
22603
  };
22566
- function jE(t) {
22604
+ function jI(t) {
22567
22605
  const { $from: e, $to: n, to: r } = t.selection;
22568
22606
  if (_c && e.sameParent(n)) {
22569
- const i = Ue.widget(r, UE, {
22607
+ const i = Ue.widget(r, UI, {
22570
22608
  ignoreSelection: !0,
22571
22609
  key: "safari-ime-span"
22572
22610
  });
22573
22611
  return Ne.create(t.doc, [i]);
22574
22612
  }
22575
22613
  }
22576
- function UE(t) {
22614
+ function UI(t) {
22577
22615
  const e = t.dom.ownerDocument.createElement("span");
22578
22616
  return e.className = "ProseMirror-safari-ime-span", e;
22579
22617
  }
22580
- var KE = new $e(qE ? WE : { key: d1 });
22618
+ var KI = new $e(qI ? WI : { key: d1 });
22581
22619
  function fp(t, e) {
22582
22620
  const n = String(t);
22583
22621
  if (typeof e != "string")
@@ -22587,13 +22625,13 @@ function fp(t, e) {
22587
22625
  r++, i = n.indexOf(e, i + e.length);
22588
22626
  return r;
22589
22627
  }
22590
- function JE(t) {
22628
+ function JI(t) {
22591
22629
  if (typeof t != "string")
22592
22630
  throw new TypeError("Expected a string");
22593
22631
  return t.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
22594
22632
  }
22595
- function GE(t, e, n) {
22596
- const i = dl((n || {}).ignore || []), o = YE(e);
22633
+ function GI(t, e, n) {
22634
+ const i = dl((n || {}).ignore || []), o = YI(e);
22597
22635
  let s = -1;
22598
22636
  for (; ++s < o.length; )
22599
22637
  Jc(t, "text", l);
@@ -22636,7 +22674,7 @@ function GE(t, e, n) {
22636
22674
  return y ? (p < c.value.length && M.push({ type: "text", value: c.value.slice(p) }), d.children.splice(g, 1, ...M)) : M = [c], g + M.length;
22637
22675
  }
22638
22676
  }
22639
- function YE(t) {
22677
+ function YI(t) {
22640
22678
  const e = [];
22641
22679
  if (!Array.isArray(t))
22642
22680
  throw new TypeError("Expected find and replace tuple or list of tuples");
@@ -22644,37 +22682,37 @@ function YE(t) {
22644
22682
  let r = -1;
22645
22683
  for (; ++r < n.length; ) {
22646
22684
  const i = n[r];
22647
- e.push([QE(i[0]), XE(i[1])]);
22685
+ e.push([QI(i[0]), XI(i[1])]);
22648
22686
  }
22649
22687
  return e;
22650
22688
  }
22651
- function QE(t) {
22652
- return typeof t == "string" ? new RegExp(JE(t), "g") : t;
22689
+ function QI(t) {
22690
+ return typeof t == "string" ? new RegExp(JI(t), "g") : t;
22653
22691
  }
22654
- function XE(t) {
22692
+ function XI(t) {
22655
22693
  return typeof t == "function" ? t : function() {
22656
22694
  return t;
22657
22695
  };
22658
22696
  }
22659
22697
  const Ra = "phrasing", Da = ["autolink", "link", "image", "label"];
22660
- function ZE() {
22698
+ function ZI() {
22661
22699
  return {
22662
- transforms: [sI],
22700
+ transforms: [sE],
22663
22701
  enter: {
22664
- literalAutolink: tI,
22702
+ literalAutolink: tE,
22665
22703
  literalAutolinkEmail: _a,
22666
22704
  literalAutolinkHttp: _a,
22667
22705
  literalAutolinkWww: _a
22668
22706
  },
22669
22707
  exit: {
22670
- literalAutolink: oI,
22671
- literalAutolinkEmail: iI,
22672
- literalAutolinkHttp: nI,
22673
- literalAutolinkWww: rI
22708
+ literalAutolink: oE,
22709
+ literalAutolinkEmail: iE,
22710
+ literalAutolinkHttp: nE,
22711
+ literalAutolinkWww: rE
22674
22712
  }
22675
22713
  };
22676
22714
  }
22677
- function eI() {
22715
+ function eE() {
22678
22716
  return {
22679
22717
  unsafe: [
22680
22718
  {
@@ -22701,41 +22739,41 @@ function eI() {
22701
22739
  ]
22702
22740
  };
22703
22741
  }
22704
- function tI(t) {
22742
+ function tE(t) {
22705
22743
  this.enter({ type: "link", title: null, url: "", children: [] }, t);
22706
22744
  }
22707
22745
  function _a(t) {
22708
22746
  this.config.enter.autolinkProtocol.call(this, t);
22709
22747
  }
22710
- function nI(t) {
22748
+ function nE(t) {
22711
22749
  this.config.exit.autolinkProtocol.call(this, t);
22712
22750
  }
22713
- function rI(t) {
22751
+ function rE(t) {
22714
22752
  this.config.exit.data.call(this, t);
22715
22753
  const e = this.stack[this.stack.length - 1];
22716
22754
  e.type, e.url = "http://" + this.sliceSerialize(t);
22717
22755
  }
22718
- function iI(t) {
22756
+ function iE(t) {
22719
22757
  this.config.exit.autolinkEmail.call(this, t);
22720
22758
  }
22721
- function oI(t) {
22759
+ function oE(t) {
22722
22760
  this.exit(t);
22723
22761
  }
22724
- function sI(t) {
22725
- GE(
22762
+ function sE(t) {
22763
+ GI(
22726
22764
  t,
22727
22765
  [
22728
- [/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi, lI],
22729
- [new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)", "gu"), aI]
22766
+ [/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi, lE],
22767
+ [new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)", "gu"), aE]
22730
22768
  ],
22731
22769
  { ignore: ["link", "linkReference"] }
22732
22770
  );
22733
22771
  }
22734
- function lI(t, e, n, r, i) {
22772
+ function lE(t, e, n, r, i) {
22735
22773
  let o = "";
22736
- if (!f1(i) || (/^w/i.test(e) && (n = e + n, e = "", o = "http://"), !cI(n)))
22774
+ if (!f1(i) || (/^w/i.test(e) && (n = e + n, e = "", o = "http://"), !cE(n)))
22737
22775
  return !1;
22738
- const s = uI(n + r);
22776
+ const s = uE(n + r);
22739
22777
  if (!s[0]) return !1;
22740
22778
  const l = {
22741
22779
  type: "link",
@@ -22745,7 +22783,7 @@ function lI(t, e, n, r, i) {
22745
22783
  };
22746
22784
  return s[1] ? [l, { type: "text", value: s[1] }] : l;
22747
22785
  }
22748
- function aI(t, e, n, r) {
22786
+ function aE(t, e, n, r) {
22749
22787
  return (
22750
22788
  // Not an expected previous character.
22751
22789
  !f1(r, !0) || // Label ends in not allowed character.
@@ -22757,11 +22795,11 @@ function aI(t, e, n, r) {
22757
22795
  }
22758
22796
  );
22759
22797
  }
22760
- function cI(t) {
22798
+ function cE(t) {
22761
22799
  const e = t.split(".");
22762
22800
  return !(e.length < 2 || e[e.length - 1] && (/_/.test(e[e.length - 1]) || !/[a-zA-Z\d]/.test(e[e.length - 1])) || e[e.length - 2] && (/_/.test(e[e.length - 2]) || !/[a-zA-Z\d]/.test(e[e.length - 2])));
22763
22801
  }
22764
- function uI(t) {
22802
+ function uE(t) {
22765
22803
  const e = /[!"&'),.:;<>?\]}]+$/.exec(t);
22766
22804
  if (!e)
22767
22805
  return [t, void 0];
@@ -22778,41 +22816,41 @@ function f1(t, e) {
22778
22816
  return (t.index === 0 || Kr(n) || gl(n)) && // If it’s an email, the previous character should not be a slash.
22779
22817
  (!e || n !== 47);
22780
22818
  }
22781
- h1.peek = kI;
22782
- function dI() {
22819
+ h1.peek = kE;
22820
+ function dE() {
22783
22821
  this.buffer();
22784
22822
  }
22785
- function fI(t) {
22823
+ function fE(t) {
22786
22824
  this.enter({ type: "footnoteReference", identifier: "", label: "" }, t);
22787
22825
  }
22788
- function hI() {
22826
+ function hE() {
22789
22827
  this.buffer();
22790
22828
  }
22791
- function pI(t) {
22829
+ function pE(t) {
22792
22830
  this.enter(
22793
22831
  { type: "footnoteDefinition", identifier: "", label: "", children: [] },
22794
22832
  t
22795
22833
  );
22796
22834
  }
22797
- function mI(t) {
22835
+ function mE(t) {
22798
22836
  const e = this.resume(), n = this.stack[this.stack.length - 1];
22799
22837
  n.type, n.identifier = on(
22800
22838
  this.sliceSerialize(t)
22801
22839
  ).toLowerCase(), n.label = e;
22802
22840
  }
22803
- function gI(t) {
22841
+ function gE(t) {
22804
22842
  this.exit(t);
22805
22843
  }
22806
- function yI(t) {
22844
+ function yE(t) {
22807
22845
  const e = this.resume(), n = this.stack[this.stack.length - 1];
22808
22846
  n.type, n.identifier = on(
22809
22847
  this.sliceSerialize(t)
22810
22848
  ).toLowerCase(), n.label = e;
22811
22849
  }
22812
- function bI(t) {
22850
+ function bE(t) {
22813
22851
  this.exit(t);
22814
22852
  }
22815
- function kI() {
22853
+ function kE() {
22816
22854
  return "[";
22817
22855
  }
22818
22856
  function h1(t, e, n, r) {
@@ -22823,23 +22861,23 @@ function h1(t, e, n, r) {
22823
22861
  n.safe(n.associationId(t), { after: "]", before: o })
22824
22862
  ), l(), s(), o += i.move("]"), o;
22825
22863
  }
22826
- function wI() {
22864
+ function wE() {
22827
22865
  return {
22828
22866
  enter: {
22829
- gfmFootnoteCallString: dI,
22830
- gfmFootnoteCall: fI,
22831
- gfmFootnoteDefinitionLabelString: hI,
22832
- gfmFootnoteDefinition: pI
22867
+ gfmFootnoteCallString: dE,
22868
+ gfmFootnoteCall: fE,
22869
+ gfmFootnoteDefinitionLabelString: hE,
22870
+ gfmFootnoteDefinition: pE
22833
22871
  },
22834
22872
  exit: {
22835
- gfmFootnoteCallString: mI,
22836
- gfmFootnoteCall: gI,
22837
- gfmFootnoteDefinitionLabelString: yI,
22838
- gfmFootnoteDefinition: bI
22873
+ gfmFootnoteCallString: mE,
22874
+ gfmFootnoteCall: gE,
22875
+ gfmFootnoteDefinitionLabelString: yE,
22876
+ gfmFootnoteDefinition: bE
22839
22877
  }
22840
22878
  };
22841
22879
  }
22842
- function xI(t) {
22880
+ function xE(t) {
22843
22881
  let e = !1;
22844
22882
  return t && t.firstLineBlank && (e = !0), {
22845
22883
  handlers: { footnoteDefinition: n, footnoteReference: h1 },
@@ -22856,18 +22894,18 @@ function xI(t) {
22856
22894
  (e ? `
22857
22895
  ` : " ") + o.indentLines(
22858
22896
  o.containerFlow(r, l.current()),
22859
- e ? p1 : CI
22897
+ e ? p1 : CE
22860
22898
  )
22861
22899
  )), c(), a;
22862
22900
  }
22863
22901
  }
22864
- function CI(t, e, n) {
22902
+ function CE(t, e, n) {
22865
22903
  return e === 0 ? t : p1(t, e, n);
22866
22904
  }
22867
22905
  function p1(t, e, n) {
22868
22906
  return (n ? "" : " ") + t;
22869
22907
  }
22870
- const SI = [
22908
+ const SE = [
22871
22909
  "autolink",
22872
22910
  "destinationLiteral",
22873
22911
  "destinationRaw",
@@ -22875,30 +22913,30 @@ const SI = [
22875
22913
  "titleQuote",
22876
22914
  "titleApostrophe"
22877
22915
  ];
22878
- m1.peek = EI;
22879
- function vI() {
22916
+ m1.peek = IE;
22917
+ function vE() {
22880
22918
  return {
22881
22919
  canContainEols: ["delete"],
22882
- enter: { strikethrough: MI },
22883
- exit: { strikethrough: AI }
22920
+ enter: { strikethrough: ME },
22921
+ exit: { strikethrough: AE }
22884
22922
  };
22885
22923
  }
22886
- function TI() {
22924
+ function TE() {
22887
22925
  return {
22888
22926
  unsafe: [
22889
22927
  {
22890
22928
  character: "~",
22891
22929
  inConstruct: "phrasing",
22892
- notInConstruct: SI
22930
+ notInConstruct: SE
22893
22931
  }
22894
22932
  ],
22895
22933
  handlers: { delete: m1 }
22896
22934
  };
22897
22935
  }
22898
- function MI(t) {
22936
+ function ME(t) {
22899
22937
  this.enter({ type: "delete", children: [] }, t);
22900
22938
  }
22901
- function AI(t) {
22939
+ function AE(t) {
22902
22940
  this.exit(t);
22903
22941
  }
22904
22942
  function m1(t, e, n, r) {
@@ -22910,20 +22948,20 @@ function m1(t, e, n, r) {
22910
22948
  after: "~"
22911
22949
  }), s += i.move("~~"), o(), s;
22912
22950
  }
22913
- function EI() {
22951
+ function IE() {
22914
22952
  return "~";
22915
22953
  }
22916
- function II(t) {
22954
+ function EE(t) {
22917
22955
  return t.length;
22918
22956
  }
22919
- function NI(t, e) {
22920
- const n = e || {}, r = (n.align || []).concat(), i = n.stringLength || II, o = [], s = [], l = [], a = [];
22957
+ function NE(t, e) {
22958
+ const n = e || {}, r = (n.align || []).concat(), i = n.stringLength || EE, o = [], s = [], l = [], a = [];
22921
22959
  let c = 0, u = -1;
22922
22960
  for (; ++u < t.length; ) {
22923
22961
  const m = [], g = [];
22924
22962
  let y = -1;
22925
22963
  for (t[u].length > c && (c = t[u].length); ++y < t[u].length; ) {
22926
- const M = OI(t[u][y]);
22964
+ const M = OE(t[u][y]);
22927
22965
  if (n.alignDelimiters !== !1) {
22928
22966
  const S = i(M);
22929
22967
  g[y] = S, (a[y] === void 0 || S > a[y]) && (a[y] = S);
@@ -22978,31 +23016,31 @@ function NI(t, e) {
22978
23016
  return p.join(`
22979
23017
  `);
22980
23018
  }
22981
- function OI(t) {
23019
+ function OE(t) {
22982
23020
  return t == null ? "" : String(t);
22983
23021
  }
22984
23022
  function hp(t) {
22985
23023
  const e = typeof t == "string" ? t.codePointAt(0) : 0;
22986
23024
  return e === 67 || e === 99 ? 99 : e === 76 || e === 108 ? 108 : e === 82 || e === 114 ? 114 : 0;
22987
23025
  }
22988
- function RI() {
23026
+ function RE() {
22989
23027
  return {
22990
23028
  enter: {
22991
- table: DI,
23029
+ table: DE,
22992
23030
  tableData: pp,
22993
23031
  tableHeader: pp,
22994
- tableRow: LI
23032
+ tableRow: LE
22995
23033
  },
22996
23034
  exit: {
22997
- codeText: PI,
22998
- table: _I,
23035
+ codeText: PE,
23036
+ table: _E,
22999
23037
  tableData: La,
23000
23038
  tableHeader: La,
23001
23039
  tableRow: La
23002
23040
  }
23003
23041
  };
23004
23042
  }
23005
- function DI(t) {
23043
+ function DE(t) {
23006
23044
  const e = t._align;
23007
23045
  this.enter(
23008
23046
  {
@@ -23015,10 +23053,10 @@ function DI(t) {
23015
23053
  t
23016
23054
  ), this.data.inTable = !0;
23017
23055
  }
23018
- function _I(t) {
23056
+ function _E(t) {
23019
23057
  this.exit(t), this.data.inTable = void 0;
23020
23058
  }
23021
- function LI(t) {
23059
+ function LE(t) {
23022
23060
  this.enter({ type: "tableRow", children: [] }, t);
23023
23061
  }
23024
23062
  function La(t) {
@@ -23027,16 +23065,16 @@ function La(t) {
23027
23065
  function pp(t) {
23028
23066
  this.enter({ type: "tableCell", children: [] }, t);
23029
23067
  }
23030
- function PI(t) {
23068
+ function PE(t) {
23031
23069
  let e = this.resume();
23032
- this.data.inTable && (e = e.replace(/\\([\\|])/g, zI));
23070
+ this.data.inTable && (e = e.replace(/\\([\\|])/g, zE));
23033
23071
  const n = this.stack[this.stack.length - 1];
23034
23072
  n.type, n.value = e, this.exit(t);
23035
23073
  }
23036
- function zI(t, e) {
23074
+ function zE(t, e) {
23037
23075
  return e === "|" ? e : t;
23038
23076
  }
23039
- function BI(t) {
23077
+ function BE(t) {
23040
23078
  const e = t || {}, n = e.tableCellPadding, r = e.tablePipeAlign, i = e.stringLength, o = n ? " " : "|";
23041
23079
  return {
23042
23080
  unsafe: [
@@ -23082,7 +23120,7 @@ function BI(t) {
23082
23120
  return M(), y(), S;
23083
23121
  }
23084
23122
  function c(h, p) {
23085
- return NI(h, {
23123
+ return NE(h, {
23086
23124
  align: p,
23087
23125
  // @ts-expect-error: `markdown-table` types should support `null`.
23088
23126
  alignDelimiters: r,
@@ -23113,26 +23151,26 @@ function BI(t) {
23113
23151
  return m.stack.includes("tableCell") && (g = g.replace(/\|/g, "\\$&")), g;
23114
23152
  }
23115
23153
  }
23116
- function FI() {
23154
+ function FE() {
23117
23155
  return {
23118
23156
  exit: {
23119
23157
  taskListCheckValueChecked: mp,
23120
23158
  taskListCheckValueUnchecked: mp,
23121
- paragraph: HI
23159
+ paragraph: HE
23122
23160
  }
23123
23161
  };
23124
23162
  }
23125
- function $I() {
23163
+ function $E() {
23126
23164
  return {
23127
23165
  unsafe: [{ atBreak: !0, character: "-", after: "[:|-]" }],
23128
- handlers: { listItem: VI }
23166
+ handlers: { listItem: VE }
23129
23167
  };
23130
23168
  }
23131
23169
  function mp(t) {
23132
23170
  const e = this.stack[this.stack.length - 2];
23133
23171
  e.type, e.checked = t.type === "taskListCheckValueChecked";
23134
23172
  }
23135
- function HI(t) {
23173
+ function HE(t) {
23136
23174
  const e = this.stack[this.stack.length - 2];
23137
23175
  if (e && e.type === "listItem" && typeof e.checked == "boolean") {
23138
23176
  const n = this.stack[this.stack.length - 1];
@@ -23153,7 +23191,7 @@ function HI(t) {
23153
23191
  }
23154
23192
  this.exit(t);
23155
23193
  }
23156
- function VI(t, e, n, r) {
23194
+ function VE(t, e, n, r) {
23157
23195
  const i = t.children[0], o = typeof t.checked == "boolean" && i && i.type === "paragraph", s = "[" + (t.checked ? "x" : " ") + "] ", l = n.createTracker(r);
23158
23196
  o && l.move(s);
23159
23197
  let a = tu.listItem(t, e, n, {
@@ -23165,55 +23203,55 @@ function VI(t, e, n, r) {
23165
23203
  return u + s;
23166
23204
  }
23167
23205
  }
23168
- function qI() {
23206
+ function qE() {
23169
23207
  return [
23170
- ZE(),
23171
- wI(),
23172
- vI(),
23173
- RI(),
23174
- FI()
23208
+ ZI(),
23209
+ wE(),
23210
+ vE(),
23211
+ RE(),
23212
+ FE()
23175
23213
  ];
23176
23214
  }
23177
- function WI(t) {
23215
+ function WE(t) {
23178
23216
  return {
23179
23217
  extensions: [
23180
- eI(),
23181
- xI(t),
23182
- TI(),
23183
- BI(t),
23184
- $I()
23218
+ eE(),
23219
+ xE(t),
23220
+ TE(),
23221
+ BE(t),
23222
+ $E()
23185
23223
  ]
23186
23224
  };
23187
23225
  }
23188
- const jI = {
23189
- tokenize: QI,
23226
+ const jE = {
23227
+ tokenize: QE,
23190
23228
  partial: !0
23191
23229
  }, g1 = {
23192
- tokenize: XI,
23230
+ tokenize: XE,
23193
23231
  partial: !0
23194
23232
  }, y1 = {
23195
- tokenize: ZI,
23233
+ tokenize: ZE,
23196
23234
  partial: !0
23197
23235
  }, b1 = {
23198
23236
  tokenize: eN,
23199
23237
  partial: !0
23200
- }, UI = {
23238
+ }, UE = {
23201
23239
  tokenize: tN,
23202
23240
  partial: !0
23203
23241
  }, k1 = {
23204
23242
  name: "wwwAutolink",
23205
- tokenize: GI,
23243
+ tokenize: GE,
23206
23244
  previous: x1
23207
23245
  }, w1 = {
23208
23246
  name: "protocolAutolink",
23209
- tokenize: YI,
23247
+ tokenize: YE,
23210
23248
  previous: C1
23211
23249
  }, Jn = {
23212
23250
  name: "emailAutolink",
23213
- tokenize: JI,
23251
+ tokenize: JE,
23214
23252
  previous: S1
23215
23253
  }, Mn = {};
23216
- function KI() {
23254
+ function KE() {
23217
23255
  return {
23218
23256
  text: Mn
23219
23257
  };
@@ -23229,7 +23267,7 @@ Mn[72] = [Jn, w1];
23229
23267
  Mn[104] = [Jn, w1];
23230
23268
  Mn[87] = [Jn, k1];
23231
23269
  Mn[119] = [Jn, k1];
23232
- function JI(t, e, n) {
23270
+ function JE(t, e, n) {
23233
23271
  const r = this;
23234
23272
  let i, o;
23235
23273
  return s;
@@ -23240,7 +23278,7 @@ function JI(t, e, n) {
23240
23278
  return Lc(d) ? (t.consume(d), l) : d === 64 ? (t.consume(d), a) : n(d);
23241
23279
  }
23242
23280
  function a(d) {
23243
- return d === 46 ? t.check(UI, u, c)(d) : d === 45 || d === 95 || St(d) ? (o = !0, t.consume(d), a) : u(d);
23281
+ return d === 46 ? t.check(UE, u, c)(d) : d === 45 || d === 95 || St(d) ? (o = !0, t.consume(d), a) : u(d);
23244
23282
  }
23245
23283
  function c(d) {
23246
23284
  return t.consume(d), i = !0, a;
@@ -23249,17 +23287,17 @@ function JI(t, e, n) {
23249
23287
  return o && i && ft(r.previous) ? (t.exit("literalAutolinkEmail"), t.exit("literalAutolink"), e(d)) : n(d);
23250
23288
  }
23251
23289
  }
23252
- function GI(t, e, n) {
23290
+ function GE(t, e, n) {
23253
23291
  const r = this;
23254
23292
  return i;
23255
23293
  function i(s) {
23256
- return s !== 87 && s !== 119 || !x1.call(r, r.previous) || kd(r.events) ? n(s) : (t.enter("literalAutolink"), t.enter("literalAutolinkWww"), t.check(jI, t.attempt(g1, t.attempt(y1, o), n), n)(s));
23294
+ return s !== 87 && s !== 119 || !x1.call(r, r.previous) || kd(r.events) ? n(s) : (t.enter("literalAutolink"), t.enter("literalAutolinkWww"), t.check(jE, t.attempt(g1, t.attempt(y1, o), n), n)(s));
23257
23295
  }
23258
23296
  function o(s) {
23259
23297
  return t.exit("literalAutolinkWww"), t.exit("literalAutolink"), e(s);
23260
23298
  }
23261
23299
  }
23262
- function YI(t, e, n) {
23300
+ function YE(t, e, n) {
23263
23301
  const r = this;
23264
23302
  let i = "", o = !1;
23265
23303
  return s;
@@ -23286,7 +23324,7 @@ function YI(t, e, n) {
23286
23324
  return t.exit("literalAutolinkHttp"), t.exit("literalAutolink"), e(d);
23287
23325
  }
23288
23326
  }
23289
- function QI(t, e, n) {
23327
+ function QE(t, e, n) {
23290
23328
  let r = 0;
23291
23329
  return i;
23292
23330
  function i(s) {
@@ -23296,7 +23334,7 @@ function QI(t, e, n) {
23296
23334
  return s === null ? n(s) : e(s);
23297
23335
  }
23298
23336
  }
23299
- function XI(t, e, n) {
23337
+ function XE(t, e, n) {
23300
23338
  let r, i, o;
23301
23339
  return s;
23302
23340
  function s(c) {
@@ -23309,7 +23347,7 @@ function XI(t, e, n) {
23309
23347
  return i || r || !o ? n(c) : e(c);
23310
23348
  }
23311
23349
  }
23312
- function ZI(t, e) {
23350
+ function ZE(t, e) {
23313
23351
  let n = 0, r = 0;
23314
23352
  return i;
23315
23353
  function i(s) {
@@ -23888,7 +23926,7 @@ function xN(t, e, n) {
23888
23926
  }
23889
23927
  function CN(t) {
23890
23928
  return Tm([
23891
- KI(),
23929
+ KE(),
23892
23930
  rN(),
23893
23931
  dN(t),
23894
23932
  mN(),
@@ -23901,7 +23939,7 @@ function vN(t) {
23901
23939
  /** @type {Processor<Root>} */
23902
23940
  this
23903
23941
  ), n = t || SN, r = e.data(), i = r.micromarkExtensions || (r.micromarkExtensions = []), o = r.fromMarkdownExtensions || (r.fromMarkdownExtensions = []), s = r.toMarkdownExtensions || (r.toMarkdownExtensions = []);
23904
- i.push(CN(n)), o.push(qI()), s.push(WI(n));
23942
+ i.push(CN(n)), o.push(qE()), s.push(WE(n));
23905
23943
  }
23906
23944
  function re(t, e) {
23907
23945
  return Object.assign(t, {
@@ -24204,7 +24242,7 @@ function AN(t) {
24204
24242
  return { pos: s, start: s + 1, node: o };
24205
24243
  });
24206
24244
  }
24207
- function EN(t) {
24245
+ function IN(t) {
24208
24246
  const e = AN(t.selection);
24209
24247
  if (e && e[0]) {
24210
24248
  const n = t.doc.resolve(e[0].pos), r = e[e.length - 1];
@@ -24260,27 +24298,27 @@ re(Ad, {
24260
24298
  displayName: "Command<insertTableCommand>",
24261
24299
  group: "Table"
24262
24300
  });
24263
- const Ed = le(
24301
+ const Id = le(
24264
24302
  "MoveRow",
24265
- () => ({ from: t, to: e, pos: n } = {}) => yE({
24303
+ () => ({ from: t, to: e, pos: n } = {}) => yI({
24266
24304
  from: t ?? 0,
24267
24305
  to: e ?? 0,
24268
24306
  pos: n
24269
24307
  })
24270
24308
  );
24271
- re(Ed, {
24309
+ re(Id, {
24272
24310
  displayName: "Command<moveRowCommand>",
24273
24311
  group: "Table"
24274
24312
  });
24275
- const Id = le(
24313
+ const Ed = le(
24276
24314
  "MoveCol",
24277
- () => ({ from: t, to: e, pos: n } = {}) => bE({
24315
+ () => ({ from: t, to: e, pos: n } = {}) => bI({
24278
24316
  from: t ?? 0,
24279
24317
  to: e ?? 0,
24280
24318
  pos: n
24281
24319
  })
24282
24320
  );
24283
- re(Id, {
24321
+ re(Ed, {
24284
24322
  displayName: "Command<moveColCommand>",
24285
24323
  group: "Table"
24286
24324
  });
@@ -24310,7 +24348,7 @@ const A1 = le(
24310
24348
  "SelectTable",
24311
24349
  () => () => (t, e) => {
24312
24350
  const { tr: n } = t;
24313
- return !!e?.(EN(n));
24351
+ return !!e?.(IN(n));
24314
24352
  }
24315
24353
  );
24316
24354
  re(A1, {
@@ -24323,7 +24361,7 @@ const Nd = le(
24323
24361
  const { selection: n } = t;
24324
24362
  if (!(n instanceof Me)) return !1;
24325
24363
  const r = n.isRowSelection(), i = n.isColSelection();
24326
- return r && i ? gE(t, e) : i ? uE(t, e) : fE(t, e);
24364
+ return r && i ? gI(t, e) : i ? uI(t, e) : fI(t, e);
24327
24365
  }
24328
24366
  );
24329
24367
  re(Nd, {
@@ -24332,7 +24370,7 @@ re(Nd, {
24332
24370
  });
24333
24371
  const Od = le(
24334
24372
  "AddColBefore",
24335
- () => () => lE
24373
+ () => () => lI
24336
24374
  );
24337
24375
  re(Od, {
24338
24376
  displayName: "Command<addColBeforeCommand>",
@@ -24340,7 +24378,7 @@ re(Od, {
24340
24378
  });
24341
24379
  const Rd = le(
24342
24380
  "AddColAfter",
24343
- () => () => aE
24381
+ () => () => aI
24344
24382
  );
24345
24383
  re(Rd, {
24346
24384
  displayName: "Command<addColAfterCommand>",
@@ -24378,14 +24416,14 @@ re(_d, {
24378
24416
  });
24379
24417
  const Ld = le(
24380
24418
  "SetAlign",
24381
- () => (t = "left") => hE("alignment", t)
24419
+ () => (t = "left") => hI("alignment", t)
24382
24420
  );
24383
24421
  re(Ld, {
24384
24422
  displayName: "Command<setAlignCommand>",
24385
24423
  group: "Table"
24386
24424
  });
24387
- const E1 = bt(
24388
- (t) => new Et(
24425
+ const I1 = bt(
24426
+ (t) => new It(
24389
24427
  /^\|(?<col>\d+)[xX](?<row>\d+)\|\s$/,
24390
24428
  (e, n, r, i) => {
24391
24429
  const o = e.doc.resolve(r);
@@ -24400,11 +24438,11 @@ const E1 = bt(
24400
24438
  }
24401
24439
  )
24402
24440
  );
24403
- re(E1, {
24441
+ re(I1, {
24404
24442
  displayName: "InputRule<insertTableInputRule>",
24405
24443
  group: "Table"
24406
24444
  });
24407
- const I1 = IT((t) => ({
24445
+ const E1 = ET((t) => ({
24408
24446
  run: (e, n, r) => {
24409
24447
  if (r)
24410
24448
  return e;
@@ -24432,7 +24470,7 @@ const I1 = IT((t) => ({
24432
24470
  }), new q(P.from(i), e.openStart, e.openEnd);
24433
24471
  }
24434
24472
  }));
24435
- re(I1, {
24473
+ re(E1, {
24436
24474
  displayName: "PasteRule<table>",
24437
24475
  group: "Table"
24438
24476
  });
@@ -24670,7 +24708,7 @@ re(Fd.ctx, {
24670
24708
  displayName: "NodeSchemaCtx<taskListItem>",
24671
24709
  group: "ListItem"
24672
24710
  });
24673
- const N1 = bt(() => new Et(
24711
+ const N1 = bt(() => new It(
24674
24712
  /^\[(?<checked>\s|x)\]\s$/,
24675
24713
  (t, e, n, r) => {
24676
24714
  const i = t.doc.resolve(n);
@@ -24689,24 +24727,24 @@ re(N1, {
24689
24727
  displayName: "InputRule<wrapInTaskListInputRule>",
24690
24728
  group: "ListItem"
24691
24729
  });
24692
- const IN = [
24730
+ const EN = [
24693
24731
  Cd,
24694
24732
  Pd
24695
24733
  ].flat(), NN = [
24696
- E1,
24734
+ I1,
24697
24735
  N1
24698
- ], ON = [v1], RN = [I1], O1 = It(() => KE);
24736
+ ], ON = [v1], RN = [E1], O1 = Et(() => KI);
24699
24737
  re(O1, {
24700
24738
  displayName: "Prose<autoInsertSpanPlugin>",
24701
24739
  group: "Prose"
24702
24740
  });
24703
- const DN = It(() => EE({}));
24741
+ const DN = Et(() => II({}));
24704
24742
  re(DN, {
24705
24743
  displayName: "Prose<columnResizingPlugin>",
24706
24744
  group: "Prose"
24707
24745
  });
24708
- const R1 = It(
24709
- () => BE({ allowTableNodeSelection: !0 })
24746
+ const R1 = Et(
24747
+ () => BI({ allowTableNodeSelection: !0 })
24710
24748
  );
24711
24749
  re(R1, {
24712
24750
  displayName: "Prose<tableEditingPlugin>",
@@ -24728,7 +24766,7 @@ function LN(t, e) {
24728
24766
  r === t && (n = o);
24729
24767
  }), n;
24730
24768
  }
24731
- const D1 = It(() => new $e({
24769
+ const D1 = Et(() => new $e({
24732
24770
  key: _N,
24733
24771
  appendTransaction: (t, e, n) => {
24734
24772
  let r;
@@ -24769,8 +24807,8 @@ const PN = [
24769
24807
  vd,
24770
24808
  Md,
24771
24809
  Ad,
24772
- Ed,
24773
24810
  Id,
24811
+ Ed,
24774
24812
  Rr,
24775
24813
  Dr,
24776
24814
  A1,
@@ -24786,7 +24824,7 @@ const PN = [
24786
24824
  NN,
24787
24825
  RN,
24788
24826
  ON,
24789
- IN,
24827
+ EN,
24790
24828
  BN,
24791
24829
  PN
24792
24830
  ].flat();
@@ -24932,7 +24970,7 @@ class rn {
24932
24970
  return c > qN && (l = VN(l, c), s -= c), new rn(l.append(o), s);
24933
24971
  }
24934
24972
  remapping(e, n) {
24935
- let r = new Eo();
24973
+ let r = new Io();
24936
24974
  return this.items.forEach((i, o) => {
24937
24975
  let s = i.mirrorOffset != null && o - i.mirrorOffset >= e ? r.maps.length - i.mirrorOffset : void 0;
24938
24976
  r.appendMap(i.map, s);
@@ -25147,7 +25185,7 @@ const qd = ct({}, "historyProviderConfig");
25147
25185
  Bi(qd, {
25148
25186
  displayName: "Ctx<historyProviderConfig>"
25149
25187
  });
25150
- const B1 = It(
25188
+ const B1 = Et(
25151
25189
  (t) => JN(t.get(qd.key))
25152
25190
  );
25153
25191
  Bi(B1, {
@@ -25409,7 +25447,7 @@ function SO(t, e) {
25409
25447
  }
25410
25448
  }), t;
25411
25449
  }
25412
- const W1 = It((t) => {
25450
+ const W1 = Et((t) => {
25413
25451
  const e = t.get(Gt);
25414
25452
  t.update(So, (i) => ({
25415
25453
  ...i,
@@ -25511,7 +25549,7 @@ Kd.meta = {
25511
25549
  package: "@milkdown/plugin-trailing",
25512
25550
  displayName: "Ctx<trailingConfig>"
25513
25551
  };
25514
- const U1 = It((t) => {
25552
+ const U1 = Et((t) => {
25515
25553
  const e = new Be("MILKDOWN_TRAILING"), { shouldAppend: n, getNode: r } = t.get(Kd.key), i = new $e({
25516
25554
  key: e,
25517
25555
  state: {
@@ -25545,7 +25583,7 @@ const MO = [Kd, U1], Sp = Math.min, To = Math.max, ll = Math.round, wn = (t) =>
25545
25583
  right: "left",
25546
25584
  bottom: "top",
25547
25585
  top: "bottom"
25548
- }, EO = {
25586
+ }, IO = {
25549
25587
  start: "end",
25550
25588
  end: "start"
25551
25589
  };
@@ -25558,7 +25596,7 @@ function Ai(t) {
25558
25596
  function Dl(t) {
25559
25597
  return t.split("-")[1];
25560
25598
  }
25561
- function IO(t) {
25599
+ function EO(t) {
25562
25600
  return t === "x" ? "y" : "x";
25563
25601
  }
25564
25602
  function K1(t) {
@@ -25569,7 +25607,7 @@ function _r(t) {
25569
25607
  return NO.has(Ai(t)) ? "y" : "x";
25570
25608
  }
25571
25609
  function J1(t) {
25572
- return IO(_r(t));
25610
+ return EO(_r(t));
25573
25611
  }
25574
25612
  function OO(t, e, n) {
25575
25613
  n === void 0 && (n = !1);
@@ -25582,7 +25620,7 @@ function RO(t) {
25582
25620
  return [Bc(t), e, Bc(e)];
25583
25621
  }
25584
25622
  function Bc(t) {
25585
- return t.replace(/start|end/g, (e) => EO[e]);
25623
+ return t.replace(/start|end/g, (e) => IO[e]);
25586
25624
  }
25587
25625
  const vp = ["left", "right"], Tp = ["right", "left"], DO = ["top", "bottom"], _O = ["bottom", "top"];
25588
25626
  function LO(t, e, n) {
@@ -25986,7 +26024,7 @@ function Gd(t) {
25986
26024
  }
25987
26025
  function XO(t) {
25988
26026
  let e = mr(t);
25989
- for (; Sn(e) && !Ei(e); ) {
26027
+ for (; Sn(e) && !Ii(e); ) {
25990
26028
  if (Gd(e))
25991
26029
  return e;
25992
26030
  if (Ll(e))
@@ -25999,7 +26037,7 @@ function Yd() {
25999
26037
  return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
26000
26038
  }
26001
26039
  const ZO = /* @__PURE__ */ new Set(["html", "body", "#document"]);
26002
- function Ei(t) {
26040
+ function Ii(t) {
26003
26041
  return ZO.has(Fi(t));
26004
26042
  }
26005
26043
  function an(t) {
@@ -26028,7 +26066,7 @@ function mr(t) {
26028
26066
  }
26029
26067
  function Y1(t) {
26030
26068
  const e = mr(t);
26031
- return Ei(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : Sn(e) && ts(e) ? e : Y1(e);
26069
+ return Ii(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : Sn(e) && ts(e) ? e : Y1(e);
26032
26070
  }
26033
26071
  function Q1(t, e, n) {
26034
26072
  var r;
@@ -26152,7 +26190,7 @@ function iR(t) {
26152
26190
  y: l
26153
26191
  };
26154
26192
  }
26155
- const Ep = 25;
26193
+ const Ip = 25;
26156
26194
  function oR(t, e) {
26157
26195
  const n = Bt(t), r = Gn(t), i = n.visualViewport;
26158
26196
  let o = r.clientWidth, s = r.clientHeight, l = 0, a = 0;
@@ -26164,8 +26202,8 @@ function oR(t, e) {
26164
26202
  const c = zl(r);
26165
26203
  if (c <= 0) {
26166
26204
  const u = r.ownerDocument, d = u.body, f = getComputedStyle(d), h = u.compatMode === "CSS1Compat" && parseFloat(f.marginLeft) + parseFloat(f.marginRight) || 0, p = Math.abs(r.clientWidth - d.clientWidth - h);
26167
- p <= Ep && (o -= p);
26168
- } else c <= Ep && (o += c);
26205
+ p <= Ip && (o -= p);
26206
+ } else c <= Ip && (o += c);
26169
26207
  return {
26170
26208
  width: o,
26171
26209
  height: s,
@@ -26183,7 +26221,7 @@ function lR(t, e) {
26183
26221
  y: c
26184
26222
  };
26185
26223
  }
26186
- function Ip(t, e, n) {
26224
+ function Ep(t, e, n) {
26187
26225
  let r;
26188
26226
  if (e === "viewport")
26189
26227
  r = oR(t, n);
@@ -26204,7 +26242,7 @@ function Ip(t, e, n) {
26204
26242
  }
26205
26243
  function nb(t, e) {
26206
26244
  const n = mr(t);
26207
- return n === e || !ln(n) || Ei(n) ? !1 : an(n).position === "fixed" || nb(n, e);
26245
+ return n === e || !ln(n) || Ii(n) ? !1 : an(n).position === "fixed" || nb(n, e);
26208
26246
  }
26209
26247
  function aR(t, e) {
26210
26248
  const n = e.get(t);
@@ -26213,7 +26251,7 @@ function aR(t, e) {
26213
26251
  let r = Q1(t, []).filter((l) => ln(l) && Fi(l) !== "body"), i = null;
26214
26252
  const o = an(t).position === "fixed";
26215
26253
  let s = o ? mr(t) : t;
26216
- for (; ln(s) && !Ei(s); ) {
26254
+ for (; ln(s) && !Ii(s); ) {
26217
26255
  const l = an(s), a = Gd(s);
26218
26256
  !a && l.position === "fixed" && (i = null), (o ? !a && !i : !a && l.position === "static" && !!i && sR.has(i.position) || ts(s) && !a && nb(t, s)) ? r = r.filter((u) => u !== s) : i = l, s = mr(s);
26219
26257
  }
@@ -26227,9 +26265,9 @@ function cR(t) {
26227
26265
  strategy: i
26228
26266
  } = t;
26229
26267
  const s = [...n === "clippingAncestors" ? Ll(e) ? [] : aR(e, this._c) : [].concat(n), r], l = s[0], a = s.reduce((c, u) => {
26230
- const d = Ip(e, u, i);
26268
+ const d = Ep(e, u, i);
26231
26269
  return c.top = To(d.top, c.top), c.right = Sp(d.right, c.right), c.bottom = Sp(d.bottom, c.bottom), c.left = To(d.left, c.left), c;
26232
- }, Ip(e, l, i));
26270
+ }, Ep(e, l, i));
26233
26271
  return {
26234
26272
  width: a.right - a.left,
26235
26273
  height: a.bottom - a.top,
@@ -26288,7 +26326,7 @@ function rb(t, e) {
26288
26326
  return n;
26289
26327
  if (!Sn(t)) {
26290
26328
  let i = mr(t);
26291
- for (; i && !Ei(i); ) {
26329
+ for (; i && !Ii(i); ) {
26292
26330
  if (ln(i) && !Ha(i))
26293
26331
  return i;
26294
26332
  i = mr(i);
@@ -26298,7 +26336,7 @@ function rb(t, e) {
26298
26336
  let r = Np(t, e);
26299
26337
  for (; r && KO(r) && Ha(r); )
26300
26338
  r = Np(r, e);
26301
- return r && Ei(r) && Ha(r) && !Gd(r) ? n : r || XO(t) || n;
26339
+ return r && Ii(r) && Ha(r) && !Gd(r) ? n : r || XO(t) || n;
26302
26340
  }
26303
26341
  const fR = async function(t) {
26304
26342
  const e = this.getOffsetParent || rb, n = this.getDimensions, r = await n(t.floating);
@@ -26524,7 +26562,7 @@ const Fl = ct({}, "blockSpec");
26524
26562
  ns(Fl, {
26525
26563
  displayName: "Ctx<blockSpec>"
26526
26564
  });
26527
- const Zd = It((t) => {
26565
+ const Zd = Et((t) => {
26528
26566
  const e = new Be("MILKDOWN_BLOCK"), r = t.get(Xd.key)();
26529
26567
  t.set(Bl.key, r);
26530
26568
  const i = t.get(Fl.key);
@@ -26671,7 +26709,7 @@ $c || ($c = function(e, n, r) {
26671
26709
  Hc || (Hc = function(e, n) {
26672
26710
  return new e(...n);
26673
26711
  });
26674
- const ms = yt(Array.prototype.forEach), vR = yt(Array.prototype.lastIndexOf), _p = yt(Array.prototype.pop), Ui = yt(Array.prototype.push), TR = yt(Array.prototype.splice), Vs = yt(String.prototype.toLowerCase), Va = yt(String.prototype.toString), Lp = yt(String.prototype.match), Ki = yt(String.prototype.replace), MR = yt(String.prototype.indexOf), AR = yt(String.prototype.trim), nn = yt(Object.prototype.hasOwnProperty), dt = yt(RegExp.prototype.test), Ji = ER(TypeError);
26712
+ const ms = yt(Array.prototype.forEach), vR = yt(Array.prototype.lastIndexOf), _p = yt(Array.prototype.pop), Ui = yt(Array.prototype.push), TR = yt(Array.prototype.splice), Vs = yt(String.prototype.toLowerCase), Va = yt(String.prototype.toString), Lp = yt(String.prototype.match), Ki = yt(String.prototype.replace), MR = yt(String.prototype.indexOf), AR = yt(String.prototype.trim), nn = yt(Object.prototype.hasOwnProperty), dt = yt(RegExp.prototype.test), Ji = IR(TypeError);
26675
26713
  function yt(t) {
26676
26714
  return function(e) {
26677
26715
  e instanceof RegExp && (e.lastIndex = 0);
@@ -26680,7 +26718,7 @@ function yt(t) {
26680
26718
  return $c(t, e, r);
26681
26719
  };
26682
26720
  }
26683
- function ER(t) {
26721
+ function IR(t) {
26684
26722
  return function() {
26685
26723
  for (var e = arguments.length, n = new Array(e), r = 0; r < e; r++)
26686
26724
  n[r] = arguments[r];
@@ -26701,7 +26739,7 @@ function pe(t, e) {
26701
26739
  }
26702
26740
  return t;
26703
26741
  }
26704
- function IR(t) {
26742
+ function ER(t) {
26705
26743
  for (let e = 0; e < t.length; e++)
26706
26744
  nn(t, e) || (t[e] = null);
26707
26745
  return t;
@@ -26709,7 +26747,7 @@ function IR(t) {
26709
26747
  function _n(t) {
26710
26748
  const e = sb(null);
26711
26749
  for (const [n, r] of ob(t))
26712
- nn(t, n) && (Array.isArray(r) ? e[n] = IR(r) : r && typeof r == "object" && r.constructor === Object ? e[n] = _n(r) : e[n] = r);
26750
+ nn(t, n) && (Array.isArray(r) ? e[n] = ER(r) : r && typeof r == "object" && r.constructor === Object ? e[n] = _n(r) : e[n] = r);
26713
26751
  return e;
26714
26752
  }
26715
26753
  function Gi(t, e) {
@@ -26858,7 +26896,7 @@ function cb() {
26858
26896
  enumerable: !0,
26859
26897
  value: !1
26860
26898
  }
26861
- })), xe = null, Ot = null, Je = !0, Ge = !0, nt = !1, $t = !0, Rt = !1, Ht = !0, z = !1, I = !1, E = !1, oe = !1, be = !1, Dt = !1, _t = !0, An = !1;
26899
+ })), xe = null, Ot = null, Je = !0, Ge = !0, nt = !1, $t = !0, Rt = !1, Ht = !0, z = !1, E = !1, I = !1, oe = !1, be = !1, Dt = !1, _t = !0, An = !1;
26862
26900
  const ti = "user-content-";
26863
26901
  let Zt = !0, Sr = !1, Yn = {}, O = null;
26864
26902
  const H = pe({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
@@ -26879,7 +26917,7 @@ function cb() {
26879
26917
  let x = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
26880
26918
  if (!(ni && ni === x)) {
26881
26919
  if ((!x || typeof x != "object") && (x = {}), x = _n(x), $i = // eslint-disable-next-line unicorn/prefer-includes
26882
- Cb.indexOf(x.PARSER_MEDIA_TYPE) === -1 ? Sb : x.PARSER_MEDIA_TYPE, Ve = $i === "application/xhtml+xml" ? Va : Vs, ue = nn(x, "ALLOWED_TAGS") ? pe({}, x.ALLOWED_TAGS, Ve) : _e, b = nn(x, "ALLOWED_ATTR") ? pe({}, x.ALLOWED_ATTR, Ve) : j, un = nn(x, "ALLOWED_NAMESPACES") ? pe({}, x.ALLOWED_NAMESPACES, Va) : en, Ce = nn(x, "ADD_URI_SAFE_ATTR") ? pe(_n(kt), x.ADD_URI_SAFE_ATTR, Ve) : kt, se = nn(x, "ADD_DATA_URI_TAGS") ? pe(_n(fe), x.ADD_DATA_URI_TAGS, Ve) : fe, O = nn(x, "FORBID_CONTENTS") ? pe({}, x.FORBID_CONTENTS, Ve) : H, xe = nn(x, "FORBID_TAGS") ? pe({}, x.FORBID_TAGS, Ve) : _n({}), Ot = nn(x, "FORBID_ATTR") ? pe({}, x.FORBID_ATTR, Ve) : _n({}), Yn = nn(x, "USE_PROFILES") ? x.USE_PROFILES : !1, Je = x.ALLOW_ARIA_ATTR !== !1, Ge = x.ALLOW_DATA_ATTR !== !1, nt = x.ALLOW_UNKNOWN_PROTOCOLS || !1, $t = x.ALLOW_SELF_CLOSE_IN_ATTR !== !1, Rt = x.SAFE_FOR_TEMPLATES || !1, Ht = x.SAFE_FOR_XML !== !1, z = x.WHOLE_DOCUMENT || !1, oe = x.RETURN_DOM || !1, be = x.RETURN_DOM_FRAGMENT || !1, Dt = x.RETURN_TRUSTED_TYPE || !1, E = x.FORCE_BODY || !1, _t = x.SANITIZE_DOM !== !1, An = x.SANITIZE_NAMED_PROPS || !1, Zt = x.KEEP_CONTENT !== !1, Sr = x.IN_PLACE || !1, k = x.ALLOWED_URI_REGEXP || lb, qt = x.NAMESPACE || ut, rs = x.MATHML_TEXT_INTEGRATION_POINTS || rs, is = x.HTML_INTEGRATION_POINTS || is, J = x.CUSTOM_ELEMENT_HANDLING || {}, x.CUSTOM_ELEMENT_HANDLING && of(x.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (J.tagNameCheck = x.CUSTOM_ELEMENT_HANDLING.tagNameCheck), x.CUSTOM_ELEMENT_HANDLING && of(x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (J.attributeNameCheck = x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), x.CUSTOM_ELEMENT_HANDLING && typeof x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (J.allowCustomizedBuiltInElements = x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), Rt && (Ge = !1), be && (oe = !0), Yn && (ue = pe({}, zp), b = [], Yn.html === !0 && (pe(ue, Pp), pe(b, Bp)), Yn.svg === !0 && (pe(ue, qa), pe(b, Ua), pe(b, gs)), Yn.svgFilters === !0 && (pe(ue, Wa), pe(b, Ua), pe(b, gs)), Yn.mathMl === !0 && (pe(ue, ja), pe(b, Fp), pe(b, gs))), x.ADD_TAGS && (ue === _e && (ue = _n(ue)), pe(ue, x.ADD_TAGS, Ve)), x.ADD_ATTR && (b === j && (b = _n(b)), pe(b, x.ADD_ATTR, Ve)), x.ADD_URI_SAFE_ATTR && pe(Ce, x.ADD_URI_SAFE_ATTR, Ve), x.FORBID_CONTENTS && (O === H && (O = _n(O)), pe(O, x.FORBID_CONTENTS, Ve)), Zt && (ue["#text"] = !0), z && pe(ue, ["html", "head", "body"]), ue.table && (pe(ue, ["tbody"]), delete xe.tbody), x.TRUSTED_TYPES_POLICY) {
26920
+ Cb.indexOf(x.PARSER_MEDIA_TYPE) === -1 ? Sb : x.PARSER_MEDIA_TYPE, Ve = $i === "application/xhtml+xml" ? Va : Vs, ue = nn(x, "ALLOWED_TAGS") ? pe({}, x.ALLOWED_TAGS, Ve) : _e, b = nn(x, "ALLOWED_ATTR") ? pe({}, x.ALLOWED_ATTR, Ve) : j, un = nn(x, "ALLOWED_NAMESPACES") ? pe({}, x.ALLOWED_NAMESPACES, Va) : en, Ce = nn(x, "ADD_URI_SAFE_ATTR") ? pe(_n(kt), x.ADD_URI_SAFE_ATTR, Ve) : kt, se = nn(x, "ADD_DATA_URI_TAGS") ? pe(_n(fe), x.ADD_DATA_URI_TAGS, Ve) : fe, O = nn(x, "FORBID_CONTENTS") ? pe({}, x.FORBID_CONTENTS, Ve) : H, xe = nn(x, "FORBID_TAGS") ? pe({}, x.FORBID_TAGS, Ve) : _n({}), Ot = nn(x, "FORBID_ATTR") ? pe({}, x.FORBID_ATTR, Ve) : _n({}), Yn = nn(x, "USE_PROFILES") ? x.USE_PROFILES : !1, Je = x.ALLOW_ARIA_ATTR !== !1, Ge = x.ALLOW_DATA_ATTR !== !1, nt = x.ALLOW_UNKNOWN_PROTOCOLS || !1, $t = x.ALLOW_SELF_CLOSE_IN_ATTR !== !1, Rt = x.SAFE_FOR_TEMPLATES || !1, Ht = x.SAFE_FOR_XML !== !1, z = x.WHOLE_DOCUMENT || !1, oe = x.RETURN_DOM || !1, be = x.RETURN_DOM_FRAGMENT || !1, Dt = x.RETURN_TRUSTED_TYPE || !1, I = x.FORCE_BODY || !1, _t = x.SANITIZE_DOM !== !1, An = x.SANITIZE_NAMED_PROPS || !1, Zt = x.KEEP_CONTENT !== !1, Sr = x.IN_PLACE || !1, k = x.ALLOWED_URI_REGEXP || lb, qt = x.NAMESPACE || ut, rs = x.MATHML_TEXT_INTEGRATION_POINTS || rs, is = x.HTML_INTEGRATION_POINTS || is, J = x.CUSTOM_ELEMENT_HANDLING || {}, x.CUSTOM_ELEMENT_HANDLING && of(x.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (J.tagNameCheck = x.CUSTOM_ELEMENT_HANDLING.tagNameCheck), x.CUSTOM_ELEMENT_HANDLING && of(x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (J.attributeNameCheck = x.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), x.CUSTOM_ELEMENT_HANDLING && typeof x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (J.allowCustomizedBuiltInElements = x.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), Rt && (Ge = !1), be && (oe = !0), Yn && (ue = pe({}, zp), b = [], Yn.html === !0 && (pe(ue, Pp), pe(b, Bp)), Yn.svg === !0 && (pe(ue, qa), pe(b, Ua), pe(b, gs)), Yn.svgFilters === !0 && (pe(ue, Wa), pe(b, Ua), pe(b, gs)), Yn.mathMl === !0 && (pe(ue, ja), pe(b, Fp), pe(b, gs))), x.ADD_TAGS && (ue === _e && (ue = _n(ue)), pe(ue, x.ADD_TAGS, Ve)), x.ADD_ATTR && (b === j && (b = _n(b)), pe(b, x.ADD_ATTR, Ve)), x.ADD_URI_SAFE_ATTR && pe(Ce, x.ADD_URI_SAFE_ATTR, Ve), x.FORBID_CONTENTS && (O === H && (O = _n(O)), pe(O, x.FORBID_CONTENTS, Ve)), Zt && (ue["#text"] = !0), z && pe(ue, ["html", "head", "body"]), ue.table && (pe(ue, ["tbody"]), delete xe.tbody), x.TRUSTED_TYPES_POLICY) {
26883
26921
  if (typeof x.TRUSTED_TYPES_POLICY.createHTML != "function")
26884
26922
  throw Ji('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
26885
26923
  if (typeof x.TRUSTED_TYPES_POLICY.createScriptURL != "function")
@@ -26931,7 +26969,7 @@ function cb() {
26931
26969
  }
26932
26970
  }, af = function(x) {
26933
26971
  let F = null, U = null;
26934
- if (E)
26972
+ if (I)
26935
26973
  x = "<remove></remove>" + x;
26936
26974
  else {
26937
26975
  const Fe = Lp(x, /^[\r\n\t ]+/);
@@ -26966,17 +27004,17 @@ function cb() {
26966
27004
  }, uf = function(x) {
26967
27005
  return typeof l == "function" && x instanceof l;
26968
27006
  };
26969
- function En(G, x, F) {
27007
+ function In(G, x, F) {
26970
27008
  ms(G, (U) => {
26971
27009
  U.call(e, x, F, ni);
26972
27010
  });
26973
27011
  }
26974
27012
  const df = function(x) {
26975
27013
  let F = null;
26976
- if (En(v.beforeSanitizeElements, x, null), ql(x))
27014
+ if (In(v.beforeSanitizeElements, x, null), ql(x))
26977
27015
  return dn(x), !0;
26978
27016
  const U = Ve(x.nodeName);
26979
- if (En(v.uponSanitizeElement, x, {
27017
+ if (In(v.uponSanitizeElement, x, {
26980
27018
  tagName: U,
26981
27019
  allowedTags: ue
26982
27020
  }), Ht && x.hasChildNodes() && !uf(x.firstElementChild) && dt(/<[/\w!]/g, x.innerHTML) && dt(/<[/\w!]/g, x.textContent) || x.nodeType === Yi.progressingInstruction || Ht && x.nodeType === Yi.comment && dt(/<[/\w]/g, x.data))
@@ -26989,8 +27027,8 @@ function cb() {
26989
27027
  if (rt && Re) {
26990
27028
  const Fe = rt.length;
26991
27029
  for (let xt = Fe - 1; xt >= 0; --xt) {
26992
- const In = m(rt[xt], !0);
26993
- In.__removalCount = (x.__removalCount || 0) + 1, Re.insertBefore(In, y(x));
27030
+ const En = m(rt[xt], !0);
27031
+ En.__removalCount = (x.__removalCount || 0) + 1, Re.insertBefore(En, y(x));
26994
27032
  }
26995
27033
  }
26996
27034
  }
@@ -27000,7 +27038,7 @@ function cb() {
27000
27038
  F = Ki(F, Re, " ");
27001
27039
  }), x.textContent !== F && (Ui(e.removed, {
27002
27040
  element: x.cloneNode()
27003
- }), x.textContent = F)), En(v.afterSanitizeElements, x, null), !1);
27041
+ }), x.textContent = F)), In(v.afterSanitizeElements, x, null), !1);
27004
27042
  }, ff = function(x, F, U) {
27005
27043
  if (_t && (F === "id" || F === "name") && (U in n || U in vb))
27006
27044
  return !1;
@@ -27031,7 +27069,7 @@ function cb() {
27031
27069
  }, hf = function(x) {
27032
27070
  return x !== "annotation-xml" && Lp(x, de);
27033
27071
  }, pf = function(x) {
27034
- En(v.beforeSanitizeAttributes, x, null);
27072
+ In(v.beforeSanitizeAttributes, x, null);
27035
27073
  const {
27036
27074
  attributes: F
27037
27075
  } = x;
@@ -27049,10 +27087,10 @@ function cb() {
27049
27087
  const rt = F[Re], {
27050
27088
  name: Fe,
27051
27089
  namespaceURI: xt,
27052
- value: In
27053
- } = rt, Hi = Ve(Fe), Wl = In;
27090
+ value: En
27091
+ } = rt, Hi = Ve(Fe), Wl = En;
27054
27092
  let it = Fe === "value" ? Wl : AR(Wl);
27055
- if (U.attrName = Hi, U.attrValue = it, U.keepAttr = !0, U.forceKeepAttr = void 0, En(v.uponSanitizeAttribute, x, U), it = U.attrValue, An && (Hi === "id" || Hi === "name") && (ri(Fe, x), it = ti + it), Ht && dt(/((--!?|])>)|<\/(style|title)/i, it)) {
27093
+ if (U.attrName = Hi, U.attrValue = it, U.keepAttr = !0, U.forceKeepAttr = void 0, In(v.uponSanitizeAttribute, x, U), it = U.attrValue, An && (Hi === "id" || Hi === "name") && (ri(Fe, x), it = ti + it), Ht && dt(/((--!?|])>)|<\/(style|title)/i, it)) {
27056
27094
  ri(Fe, x);
27057
27095
  continue;
27058
27096
  }
@@ -27092,13 +27130,13 @@ function cb() {
27092
27130
  ri(Fe, x);
27093
27131
  }
27094
27132
  }
27095
- En(v.afterSanitizeAttributes, x, null);
27133
+ In(v.afterSanitizeAttributes, x, null);
27096
27134
  }, Mb = function G(x) {
27097
27135
  let F = null;
27098
27136
  const U = cf(x);
27099
- for (En(v.beforeSanitizeShadowDOM, x, null); F = U.nextNode(); )
27100
- En(v.uponSanitizeShadowNode, F, null), df(F), pf(F), F.content instanceof o && G(F.content);
27101
- En(v.afterSanitizeShadowDOM, x, null);
27137
+ for (In(v.beforeSanitizeShadowDOM, x, null); F = U.nextNode(); )
27138
+ In(v.uponSanitizeShadowNode, F, null), df(F), pf(F), F.content instanceof o && G(F.content);
27139
+ In(v.afterSanitizeShadowDOM, x, null);
27102
27140
  };
27103
27141
  return e.sanitize = function(G) {
27104
27142
  let x = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, F = null, U = null, Re = null, rt = null;
@@ -27110,10 +27148,10 @@ function cb() {
27110
27148
  throw Ji("toString is not a function");
27111
27149
  if (!e.isSupported)
27112
27150
  return G;
27113
- if (I || Vl(x), e.removed = [], typeof G == "string" && (Sr = !1), Sr) {
27151
+ if (E || Vl(x), e.removed = [], typeof G == "string" && (Sr = !1), Sr) {
27114
27152
  if (G.nodeName) {
27115
- const In = Ve(G.nodeName);
27116
- if (!ue[In] || xe[In])
27153
+ const En = Ve(G.nodeName);
27154
+ if (!ue[En] || xe[En])
27117
27155
  throw Ji("root node is forbidden and cannot be sanitized in-place");
27118
27156
  }
27119
27157
  } else if (G instanceof l)
@@ -27125,7 +27163,7 @@ function cb() {
27125
27163
  if (F = af(G), !F)
27126
27164
  return oe ? null : Dt ? R : "";
27127
27165
  }
27128
- F && E && dn(F.firstChild);
27166
+ F && I && dn(F.firstChild);
27129
27167
  const Fe = cf(Sr ? G : F);
27130
27168
  for (; Re = Fe.nextNode(); )
27131
27169
  df(Re), pf(Re), Re.content instanceof o && Mb(Re.content);
@@ -27141,14 +27179,14 @@ function cb() {
27141
27179
  }
27142
27180
  let xt = z ? F.outerHTML : F.innerHTML;
27143
27181
  return z && ue["!doctype"] && F.ownerDocument && F.ownerDocument.doctype && F.ownerDocument.doctype.name && dt(ab, F.ownerDocument.doctype.name) && (xt = "<!DOCTYPE " + F.ownerDocument.doctype.name + `>
27144
- ` + xt), Rt && ms([w, A, $], (In) => {
27145
- xt = Ki(xt, In, " ");
27182
+ ` + xt), Rt && ms([w, A, $], (En) => {
27183
+ xt = Ki(xt, En, " ");
27146
27184
  }), N && Dt ? N.createHTML(xt) : xt;
27147
27185
  }, e.setConfig = function() {
27148
27186
  let G = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
27149
- Vl(G), I = !0;
27187
+ Vl(G), E = !0;
27150
27188
  }, e.clearConfig = function() {
27151
- ni = null, I = !1;
27189
+ ni = null, E = !1;
27152
27190
  }, e.isValidAttribute = function(G, x, F) {
27153
27191
  ni || Vl({});
27154
27192
  const U = Ve(G), Re = Ve(x);
@@ -27570,7 +27608,7 @@ function o5(t, e, n) {
27570
27608
  S.call(Dr.key, {
27571
27609
  pos: N.pos,
27572
27610
  index: g.startIndex
27573
- }), S.call(Id.key, N);
27611
+ }), S.call(Ed.key, N);
27574
27612
  const R = [0, g.endIndex];
27575
27613
  tf({
27576
27614
  refs: t,
@@ -27580,7 +27618,7 @@ function o5(t, e, n) {
27580
27618
  S.call(Rr.key, {
27581
27619
  pos: N.pos,
27582
27620
  index: g.startIndex
27583
- }), S.call(Ed.key, N);
27621
+ }), S.call(Id.key, N);
27584
27622
  const R = [g.endIndex, 0];
27585
27623
  nf({
27586
27624
  refs: t,
@@ -28140,7 +28178,7 @@ class k5 {
28140
28178
  const w5 = Ay(rf, () => (t, e, n) => new k5(t, e, n)), x5 = ur.extendSchema((t) => (e) => ({
28141
28179
  ...t(e),
28142
28180
  toDOM: (r) => ["br", e.get(Fo.key)(r)]
28143
- })), C5 = bt((t) => new Et(
28181
+ })), C5 = bt((t) => new It(
28144
28182
  /\{\{(\w+)\|([^}]*)\}\}$/,
28145
28183
  (e, n, r, i) => {
28146
28184
  const [, o, s] = n, a = rf.type(t).create({ fieldType: o, fieldContent: s });
@@ -28182,12 +28220,12 @@ function T5(t = v5) {
28182
28220
  }
28183
28221
  };
28184
28222
  }
28185
- const M5 = String.raw`(?:var(?:\\?_table)?|step|check|ref\\?_(?:step|var|fig)|cite)`, A5 = new RegExp(String.raw`\{\{${M5}\s*\|[^}]+?\}\}`, "g"), E5 = /\\([\\!"#$%&'()*+,./:;<=>?@[\\\]^_`{|}~-])/g;
28186
- function I5(t) {
28187
- return t.replace(E5, "$1");
28223
+ const M5 = String.raw`(?:var(?:\\?_table)?|step|check|ref\\?_(?:step|var|fig)|cite)`, A5 = new RegExp(String.raw`\{\{${M5}\s*\|[^}]+?\}\}`, "g"), I5 = /\\([\\!"#$%&'()*+,./:;<=>?@[\\\]^_`{|}~-])/g;
28224
+ function E5(t) {
28225
+ return t.replace(I5, "$1");
28188
28226
  }
28189
28227
  function wb(t) {
28190
- return t.replace(A5, I5);
28228
+ return t.replace(A5, E5);
28191
28229
  }
28192
28230
  function Mr(t) {
28193
28231
  return wb(Uc(t));
@@ -28271,7 +28309,7 @@ const N5 = {
28271
28309
  icon: u('<line x1="2" y1="12" x2="22" y2="12" stroke-width="2.5"/>'),
28272
28310
  onRun: (v) => {
28273
28311
  const w = v.get(te);
28274
- w.call(tn.key), w.call(Ec.key, { nodeType: Pi.type(v) });
28312
+ w.call(tn.key), w.call(Ic.key, { nodeType: Pi.type(v) });
28275
28313
  }
28276
28314
  }
28277
28315
  ]
@@ -28313,7 +28351,7 @@ const N5 = {
28313
28351
  icon: u('<rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M3 15h18M9 3v18M15 3v18"/>'),
28314
28352
  onRun: (v) => {
28315
28353
  const w = v.get(te);
28316
- w.call(tn.key), w.call(Ec.key, { nodeType: Sd(v, 3, 3) });
28354
+ w.call(tn.key), w.call(Ic.key, { nodeType: Sd(v, 3, 3) });
28317
28355
  }
28318
28356
  }
28319
28357
  ]
@@ -28355,7 +28393,7 @@ const N5 = {
28355
28393
  p = null, document.addEventListener("click", h);
28356
28394
  }, 0) : (p !== null && (clearTimeout(p), p = null), document.removeEventListener("click", h));
28357
28395
  });
28358
- const m = It(() => new $e({
28396
+ const m = Et(() => new $e({
28359
28397
  key: new Be("AIMD_PLACEHOLDER"),
28360
28398
  props: {
28361
28399
  decorations: (v) => {
@@ -28600,7 +28638,7 @@ function P5(t) {
28600
28638
  }
28601
28639
  const S = Xe(() => {
28602
28640
  try {
28603
- return Eb(l.value);
28641
+ return Ib(l.value);
28604
28642
  } catch {
28605
28643
  return null;
28606
28644
  }
@@ -28977,7 +29015,7 @@ export {
28977
29015
  Fo as f,
28978
29016
  K5 as g,
28979
29017
  ur as h,
28980
- It as i,
29018
+ Et as i,
28981
29019
  b5 as j,
28982
29020
  rf as k,
28983
29021
  C5 as l,