@templatical/editor 0.10.0 → 0.10.2

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 (138) hide show
  1. package/dist/{AiChatSidebar-D30WPhbv.js → AiChatSidebar-BMwpZx-6.js} +14 -14
  2. package/dist/{AiFeatureMenu-B5CJX5zr.js → AiFeatureMenu-xgaIGUCo.js} +8 -8
  3. package/dist/{BlockIssueBadge-CkB4Yyz2.js → BlockIssueBadge-3kNs6WoD.js} +5 -5
  4. package/dist/{CloudEditor-nT-R769W.js → CloudEditor-Dm9hiaui.js} +159 -156
  5. package/dist/{CollaboratorBar-CwhlXODK.js → CollaboratorBar-Cz_evoU4.js} +4 -4
  6. package/dist/{CommentsSidebar-gpZMMI5w.js → CommentsSidebar-jFZj_CTo.js} +13 -13
  7. package/dist/{CountdownBlock-BNvuXucv.js → CountdownBlock-S-SCyVye.js} +4 -4
  8. package/dist/{CountdownToolbar-Dl82DAmI.js → CountdownToolbar-Ckdo-3P-.js} +3 -3
  9. package/dist/{DesignReferenceSidebar-Bs5AMxVd.js → DesignReferenceSidebar-B9QNPZNV.js} +10 -10
  10. package/dist/{IssuesPanel-CqQa2BtU.js → IssuesPanel-_E_fbSM8.js} +8 -8
  11. package/dist/{LoadingTrack-xCOLUR3o.js → LoadingTrack-BZ5KJyZ_.js} +2 -2
  12. package/dist/{ModuleBrowserModal-BWWgF0LC.js → ModuleBrowserModal-BB22urqi.js} +10 -10
  13. package/dist/{ModulePreviewCanvas-D7Tk5HOt.js → ModulePreviewCanvas-CH5OdXv8.js} +3 -3
  14. package/dist/{NumberWithSuffix-DVy5HxMi.js → NumberWithSuffix-BHDXHMpo.js} +3 -3
  15. package/dist/{ParagraphEditor-DVSGdMOo.js → ParagraphEditor-BmY7LLgN.js} +26 -26
  16. package/dist/{RichTextEditorContent-DN-fRjMa.js → RichTextEditorContent-COijbaWp.js} +8 -8
  17. package/dist/{SaveModuleDialog-CkEYkyVD.js → SaveModuleDialog-D5WN-je_.js} +7 -7
  18. package/dist/{SnapshotHistory-Nx9wrlbF.js → SnapshotHistory-BQ55Rhri.js} +9 -9
  19. package/dist/{TemplateScoringPanel-BG9M-29t.js → TemplateScoringPanel-Dhf_Qgr7.js} +15 -15
  20. package/dist/{TestEmailModal-CRjtEs6S.js → TestEmailModal-DH_Viz_m.js} +5 -5
  21. package/dist/{TitleEditor-CvtV4pCA.js → TitleEditor-Dn613K8o.js} +12 -12
  22. package/dist/{TplModal-BudEYVcJ.js → TplModal-Dxa3rhHI.js} +4 -4
  23. package/dist/{blockTypeIcons-Dd-UvfnC.js → blockTypeIcons-CrcSCTD6.js} +2 -2
  24. package/dist/bundle-stats.json +6 -6
  25. package/dist/cdn/chunks/{AiFeatureMenu-DKOv8VnB.js → AiFeatureMenu-CCsgxyN9.js} +4 -4
  26. package/dist/cdn/chunks/{AiFeatureMenu-DKOv8VnB.js.map → AiFeatureMenu-CCsgxyN9.js.map} +1 -1
  27. package/dist/cdn/chunks/{BlockIssueBadge-DpiSTwM7.js → BlockIssueBadge-Lc3NWFV8.js} +3 -3
  28. package/dist/cdn/chunks/{BlockIssueBadge-DpiSTwM7.js.map → BlockIssueBadge-Lc3NWFV8.js.map} +1 -1
  29. package/dist/cdn/chunks/{CloudEditor-xc_uOEgn.js → CloudEditor-KkwvBhyt.js} +131 -128
  30. package/dist/cdn/chunks/CloudEditor-KkwvBhyt.js.map +1 -0
  31. package/dist/cdn/chunks/{CollaboratorBar-VWfPri_h.js → CollaboratorBar-BGIGiFSm.js} +4 -4
  32. package/dist/cdn/chunks/{CollaboratorBar-VWfPri_h.js.map → CollaboratorBar-BGIGiFSm.js.map} +1 -1
  33. package/dist/cdn/chunks/{CountdownBlock-BKsCWboK.js → CountdownBlock-gqnpxKp_.js} +4 -4
  34. package/dist/cdn/chunks/{CountdownBlock-BKsCWboK.js.map → CountdownBlock-gqnpxKp_.js.map} +1 -1
  35. package/dist/cdn/chunks/{CountdownToolbar-BLtECDNb.js → CountdownToolbar-xHpaWQE2.js} +4 -4
  36. package/dist/cdn/chunks/{CountdownToolbar-BLtECDNb.js.map → CountdownToolbar-xHpaWQE2.js.map} +1 -1
  37. package/dist/cdn/chunks/{IssuesPanel-BW2piyvs.js → IssuesPanel-DHTTHu65.js} +4 -4
  38. package/dist/cdn/chunks/{IssuesPanel-BW2piyvs.js.map → IssuesPanel-DHTTHu65.js.map} +1 -1
  39. package/dist/cdn/chunks/{ModuleBrowserModal-TLlKpvjX.js → ModuleBrowserModal-DDTjrKph.js} +6 -6
  40. package/dist/cdn/chunks/{ModuleBrowserModal-TLlKpvjX.js.map → ModuleBrowserModal-DDTjrKph.js.map} +1 -1
  41. package/dist/cdn/chunks/{ModulePreviewCanvas-wu7y-vrh.js → ModulePreviewCanvas-DeFq0hVi.js} +3 -3
  42. package/dist/cdn/chunks/{ModulePreviewCanvas-wu7y-vrh.js.map → ModulePreviewCanvas-DeFq0hVi.js.map} +1 -1
  43. package/dist/cdn/chunks/{NumberWithSuffix-DxoUtTMr.js → NumberWithSuffix-D4wtmU9O.js} +3 -3
  44. package/dist/cdn/chunks/{NumberWithSuffix-DxoUtTMr.js.map → NumberWithSuffix-D4wtmU9O.js.map} +1 -1
  45. package/dist/cdn/chunks/{ParagraphEditor-DvxIO2LN.js → ParagraphEditor-CwY8GeWa.js} +20 -20
  46. package/dist/cdn/chunks/{ParagraphEditor-DvxIO2LN.js.map → ParagraphEditor-CwY8GeWa.js.map} +1 -1
  47. package/dist/cdn/chunks/{RichTextEditorContent-Dm9GXJmo.js → RichTextEditorContent-C_bMURGF.js} +5 -5
  48. package/dist/cdn/chunks/{RichTextEditorContent-Dm9GXJmo.js.map → RichTextEditorContent-C_bMURGF.js.map} +1 -1
  49. package/dist/cdn/chunks/{SaveModuleDialog-BRAdVcYM.js → SaveModuleDialog-DEi8PSP6.js} +3 -3
  50. package/dist/cdn/chunks/{SaveModuleDialog-BRAdVcYM.js.map → SaveModuleDialog-DEi8PSP6.js.map} +1 -1
  51. package/dist/cdn/chunks/{TitleEditor-D3gPRd0x.js → TitleEditor-Betpo8AZ.js} +9 -9
  52. package/dist/cdn/chunks/{TitleEditor-D3gPRd0x.js.map → TitleEditor-Betpo8AZ.js.map} +1 -1
  53. package/dist/cdn/chunks/{blockTypeIcons-C2cm4RjU.js → blockTypeIcons-Xz6OBq3U.js} +3 -3
  54. package/dist/cdn/chunks/{blockTypeIcons-C2cm4RjU.js.map → blockTypeIcons-Xz6OBq3U.js.map} +1 -1
  55. package/dist/cdn/chunks/{draggable-BwWMFq33.js → draggable-BTGr7_-X.js} +1271 -1270
  56. package/dist/cdn/chunks/draggable-BTGr7_-X.js.map +1 -0
  57. package/dist/cdn/chunks/{extensions-SS1ywPUR.js → extensions-D_j4UWxi.js} +108 -105
  58. package/dist/cdn/chunks/{extensions-SS1ywPUR.js.map → extensions-D_j4UWxi.js.map} +1 -1
  59. package/dist/cdn/chunks/{features-CwZTdcbt.js → features-A28DQtjE.js} +831 -820
  60. package/dist/cdn/chunks/features-A28DQtjE.js.map +1 -0
  61. package/dist/cdn/chunks/{icons-CbNEr1kc.js → icons-C9D3N0-J.js} +12 -12
  62. package/dist/cdn/chunks/{icons-CbNEr1kc.js.map → icons-C9D3N0-J.js.map} +1 -1
  63. package/dist/cdn/chunks/{liquid.browser-rMoPo2t_.js → liquid.browser-DUDc3U21.js} +10 -10
  64. package/dist/cdn/chunks/{liquid.browser-rMoPo2t_.js.map → liquid.browser-DUDc3U21.js.map} +1 -1
  65. package/dist/cdn/chunks/{media-library-BRpHZOl7.js → media-library-CH1Wx5wP.js} +13 -9
  66. package/dist/cdn/chunks/media-library-CH1Wx5wP.js.map +1 -0
  67. package/dist/cdn/chunks/pusher-CHo5Cua0.js.map +1 -1
  68. package/dist/cdn/chunks/{quality-BqJqIPRU.js → quality-D4NeyFej.js} +530 -530
  69. package/dist/cdn/chunks/{quality-BqJqIPRU.js.map → quality-D4NeyFej.js.map} +1 -1
  70. package/dist/cdn/chunks/{renderer-CGVYkdUi.js → renderer-BQnGfLhL.js} +62 -61
  71. package/dist/cdn/chunks/renderer-BQnGfLhL.js.map +1 -0
  72. package/dist/cdn/chunks/{src-CvzfrFlT.js → src-BkKEyLw1.js} +6 -6
  73. package/dist/cdn/chunks/{src-CvzfrFlT.js.map → src-BkKEyLw1.js.map} +1 -1
  74. package/dist/cdn/chunks/{styles-2P5yvfsS.js → styles-BDVaiw3K.js} +150 -150
  75. package/dist/cdn/chunks/{styles-2P5yvfsS.js.map → styles-BDVaiw3K.js.map} +1 -1
  76. package/dist/cdn/chunks/{tiptap-BBbH3IT9.js → tiptap-P5abGB13.js} +4437 -2580
  77. package/dist/cdn/chunks/tiptap-P5abGB13.js.map +1 -0
  78. package/dist/cdn/editor.css +1 -1
  79. package/dist/cdn/editor.js +100 -100
  80. package/dist/cdn/editor.js.map +1 -1
  81. package/dist/{check-ChQyfxJ3.js → check-KooI2jyS.js} +1 -1
  82. package/dist/{chevron-down-DJjo0jSV.js → chevron-down-mnlFgueW.js} +1 -1
  83. package/dist/{circle-alert-CPH6l3Lc.js → circle-alert-D89_hB8j.js} +1 -1
  84. package/dist/{clock-DHl_BIkU.js → clock-BaadyUrg.js} +1 -1
  85. package/dist/{cloud-BBC7bv8q.js → cloud-D-FScaHx.js} +80 -74
  86. package/dist/{createLucideIcon-XgXOJ05E.js → createLucideIcon-D-6fpD2L.js} +3 -3
  87. package/dist/{dist-DXaxGLsw.js → dist-BttO3Zdx.js} +44 -44
  88. package/dist/{dist-C8wMh_gi.js → dist-C1WcikEF.js} +5 -5
  89. package/dist/dist-CjULgTep.js +4072 -0
  90. package/dist/{dist-GAmhYvUK.js → dist-D6L_WdRL.js} +96 -86
  91. package/dist/{dist-DYO-w_Jf.js → dist-DaajG7Fo.js} +5 -5
  92. package/dist/dist-Df4eV6Zi.js +5 -0
  93. package/dist/{dist-D8C6jIXM.js → dist-Dnqx5UF3.js} +171 -158
  94. package/dist/{dist-CUpJmrjt.js → dist-Drp5bNAu.js} +5 -5
  95. package/dist/dist-WJ1fVd5b.js +5 -0
  96. package/dist/{dist-BxP6TB0l.js → dist-XA2i70J5.js} +8 -8
  97. package/dist/{dist-UK-lbEBc.js → dist-b52vYHb5.js} +2 -2
  98. package/dist/{dist-CNLAS2v2.js → dist-cl33Ip6W.js} +3 -3
  99. package/dist/{dist-C0jo8wtG.js → dist-sqf7pq5q.js} +16 -16
  100. package/dist/{dist-BzuC8o3y.js → dist-zInT3Lf6.js} +78 -60
  101. package/dist/{extensions-C87ZSllQ.js → extensions-DA-w1gVg.js} +128 -125
  102. package/dist/{image-up-CPBCOMit.js → image-up-DjwfAom6.js} +1 -1
  103. package/dist/{info-DIY9mguM.js → info-Db3HlTr8.js} +1 -1
  104. package/dist/{keys-Vt3XipJl.js → keys-BjmL5YCT.js} +1 -1
  105. package/dist/{liquid.browser-IgQrXHPQ.js → liquid.browser--qtl1Fqy.js} +9 -9
  106. package/dist/{list-checks-CSCyu3fH.js → list-checks-BlAB0X8a.js} +1 -1
  107. package/dist/{loader-circle-Rz_4vJLH.js → loader-circle-EVqyIxjU.js} +1 -1
  108. package/dist/{message-circle-D-umK_MU.js → message-circle-BuI5pBVG.js} +1 -1
  109. package/dist/{refresh-cw-CvWF4jfR.js → refresh-cw-C2vM_6zQ.js} +1 -1
  110. package/dist/{scan-line-wanvAFDr.js → scan-line-AUIh_SHI.js} +1 -1
  111. package/dist/{send-BhbhbIFT.js → send-nrbwF7xg.js} +1 -1
  112. package/dist/{shield-check-CXPPMWth.js → shield-check-B55Ozmva.js} +1 -1
  113. package/dist/{sparkles-CrUN0KWY.js → sparkles-oh1NUSFq.js} +1 -1
  114. package/dist/style.css +1 -1
  115. package/dist/{styles-DOjWbqA9.js → styles-Byhh107n.js} +41 -41
  116. package/dist/templatical-editor.js +81 -80
  117. package/dist/{text-align-end-Bkq8oBrD.js → text-align-start-B2MqzZwU.js} +11 -11
  118. package/dist/{trash-2-BpY5BCLT.js → trash-2-DH8RBwAx.js} +1 -1
  119. package/dist/{triangle-alert-MwJBKR2e.js → triangle-alert-BQHjCt3B.js} +1 -1
  120. package/dist/{useAliveFlag-BLyG8L4d.js → useAliveFlag-B_b9ubwD.js} +1 -1
  121. package/dist/{useCloudI18n-sRfoQCZY.js → useCloudI18n-BHCrmQgj.js} +2 -2
  122. package/dist/{useEditorCore-DxApq2hZ.js → useEditorCore-BEgc3KFu.js} +370 -377
  123. package/dist/{useI18n-lF6hYgZu.js → useI18n-Bb9-ha9X.js} +2 -2
  124. package/dist/{useMergeTag-CZVI7Xe5.js → useMergeTag-HykzEtBn.js} +3 -3
  125. package/dist/usePopoverRoot-BZDkRRry.js +8 -0
  126. package/dist/{vue.runtime.esm-bundler-BDSGA5hA.js → vue.runtime.esm-bundler-MzYCkFSH.js} +1306 -1305
  127. package/dist/{x-rcnxRG8Y.js → x-DgCCENgP.js} +1 -1
  128. package/package.json +27 -27
  129. package/dist/cdn/chunks/CloudEditor-xc_uOEgn.js.map +0 -1
  130. package/dist/cdn/chunks/draggable-BwWMFq33.js.map +0 -1
  131. package/dist/cdn/chunks/features-CwZTdcbt.js.map +0 -1
  132. package/dist/cdn/chunks/media-library-BRpHZOl7.js.map +0 -1
  133. package/dist/cdn/chunks/renderer-CGVYkdUi.js.map +0 -1
  134. package/dist/cdn/chunks/tiptap-BBbH3IT9.js.map +0 -1
  135. package/dist/dist-BDgf2G-V.js +0 -2243
  136. package/dist/dist-D5lmdi1F.js +0 -5
  137. package/dist/dist-DILjuzSv.js +0 -5
  138. package/dist/usePopoverRoot-p2BanBI7.js +0 -8
@@ -1,5 +1,5 @@
1
- import { J as e, L as t, X as n, Y as r, d as i, q as a } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
2
- import { r as o, u as s } from "./dist-GAmhYvUK.js";
1
+ import { J as e, L as t, X as n, Y as r, d as i, q as a } from "./vue.runtime.esm-bundler-MzYCkFSH.js";
2
+ import { r as o, u as s } from "./dist-D6L_WdRL.js";
3
3
  //#region ../core/dist/cloud/index.js
4
4
  var c = class e {
5
5
  static DEFAULT_BASE_URL = "https://templatical.com";
@@ -150,10 +150,10 @@ var u = "/api/v1/projects/{project}/tenants/{tenant}", d = `${u}/templates/{temp
150
150
  "savedModules.update": `${h}/{savedModule}`,
151
151
  "savedModules.destroy": `${h}/{savedModule}`
152
152
  }, _ = class {
153
+ authManager;
153
154
  constructor(e) {
154
155
  this.authManager = e;
155
156
  }
156
- authManager;
157
157
  get projectId() {
158
158
  return this.authManager.projectId;
159
159
  }
@@ -431,7 +431,10 @@ function b(e, t) {
431
431
  break;
432
432
  }
433
433
  }
434
- function x(t) {
434
+ function x(e) {
435
+ return e === "1" ? 1 : e === "3" ? 3 : 2;
436
+ }
437
+ function S(t) {
435
438
  let n = new _(t.authManager), a = e({
436
439
  template: null,
437
440
  content: s(t.defaultFontFamily, t.templateDefaults),
@@ -500,18 +503,18 @@ function x(t) {
500
503
  function b(e) {
501
504
  a.previewMode = e, e && (a.selectedBlockId = null);
502
505
  }
503
- function x(e, t) {
506
+ function S(e, t) {
504
507
  if (p(e)) return;
505
508
  let n = d(a.content.blocks, e);
506
509
  n && (Object.assign(n, t), a.isDirty = !0);
507
510
  }
508
- function S(e) {
511
+ function C(e) {
509
512
  a.content.settings = {
510
513
  ...a.content.settings,
511
514
  ...e
512
515
  }, a.isDirty = !0;
513
516
  }
514
- function C(e, t, n = 0, r) {
517
+ function w(e, t, n = 0, r) {
515
518
  if (t) {
516
519
  let i = d(a.content.blocks, t);
517
520
  if (i && i.type === "section") {
@@ -522,7 +525,7 @@ function x(t) {
522
525
  } else r !== void 0 && r < a.content.blocks.length ? a.content.blocks.splice(r, 0, e) : a.content.blocks.push(e);
523
526
  a.isDirty = !0;
524
527
  }
525
- function w(e) {
528
+ function T(e) {
526
529
  if (p(e)) return;
527
530
  let t = f(a.content.blocks, e);
528
531
  if (t) {
@@ -530,19 +533,21 @@ function x(t) {
530
533
  n !== -1 && (t.blocks.splice(n, 1), a.selectedBlockId === e && (a.selectedBlockId = null), a.isDirty = !0);
531
534
  }
532
535
  }
533
- function T(e, t, n, r = 0) {
536
+ function E(e, t, n, r = 0) {
534
537
  let i = f(a.content.blocks, e);
535
538
  if (!i) return;
536
539
  let o = i.blocks.findIndex((t) => t.id === e);
537
540
  if (o === -1) return;
538
- let [s] = i.blocks.splice(o, 1);
541
+ let s;
539
542
  if (n) {
540
543
  let e = d(a.content.blocks, n);
541
- e && e.type === "section" && (e.children[r] = e.children[r] || [], e.children[r].splice(t, 0, s));
542
- } else a.content.blocks.splice(t, 0, s);
543
- a.isDirty = !0;
544
+ if (!e || e.type !== "section" || r < 0 || r >= x(e.columns)) return;
545
+ e.children[r] = e.children[r] || [], s = e.children[r];
546
+ } else s = a.content.blocks;
547
+ let [c] = i.blocks.splice(o, 1);
548
+ s.splice(t, 0, c), a.isDirty = !0;
544
549
  }
545
- async function E(e) {
550
+ async function D(e) {
546
551
  a.isLoading = !0;
547
552
  try {
548
553
  e && (a.content = e);
@@ -554,7 +559,7 @@ function x(t) {
554
559
  a.isLoading = !1;
555
560
  }
556
561
  }
557
- async function D(e) {
562
+ async function O(e) {
558
563
  a.isLoading = !0;
559
564
  try {
560
565
  let t = await n.getTemplate(e);
@@ -565,7 +570,7 @@ function x(t) {
565
570
  a.isLoading = !1;
566
571
  }
567
572
  }
568
- async function O() {
573
+ async function k() {
569
574
  if (!a.template?.id) throw new o("No template loaded. Call create() or load() before saving.");
570
575
  a.isSaving = !0;
571
576
  try {
@@ -577,20 +582,20 @@ function x(t) {
577
582
  a.isSaving = !1;
578
583
  }
579
584
  }
580
- async function k() {
585
+ async function A() {
581
586
  if (a.template?.id) try {
582
587
  await n.createSnapshot(a.template.id, a.content);
583
588
  } catch (e) {
584
589
  throw t.onError?.(e), e;
585
590
  }
586
591
  }
587
- function A() {
592
+ function j() {
588
593
  return a.template?.id !== void 0;
589
594
  }
590
- function j() {
595
+ function M() {
591
596
  a.isDirty = !0;
592
597
  }
593
- function M(e) {
598
+ function N(e) {
594
599
  let t = f(a.content.blocks, e);
595
600
  if (!t) return null;
596
601
  let n = t.blocks.findIndex((t) => t.id === e);
@@ -606,31 +611,31 @@ function x(t) {
606
611
  selectedBlock: l,
607
612
  savedBlockIds: u,
608
613
  isBlockLocked: p,
609
- findBlockLocation: M,
614
+ findBlockLocation: N,
610
615
  setContent: m,
611
616
  selectBlock: h,
612
617
  setViewport: g,
613
618
  setDarkMode: v,
614
619
  setUiTheme: y,
615
620
  setPreviewMode: b,
616
- updateBlock: x,
617
- updateSettings: S,
618
- addBlock: C,
619
- removeBlock: w,
620
- moveBlock: T,
621
- create: E,
622
- load: D,
623
- save: O,
624
- createSnapshot: k,
625
- hasTemplate: A,
626
- markDirty: j
621
+ updateBlock: S,
622
+ updateSettings: C,
623
+ addBlock: w,
624
+ removeBlock: T,
625
+ moveBlock: E,
626
+ create: D,
627
+ load: O,
628
+ save: k,
629
+ createSnapshot: A,
630
+ hasTemplate: j,
631
+ markDirty: M
627
632
  };
628
633
  }
629
- var S = 0;
630
- function C() {
631
- return `msg_${Date.now()}_${++S}`;
634
+ var C = 0;
635
+ function w() {
636
+ return `msg_${Date.now()}_${++C}`;
632
637
  }
633
- function w(e) {
638
+ function T(e) {
634
639
  let { authManager: t, getTemplateId: r, onApply: i, onError: a } = e, o = n([]), s = n(!1), c = n(!1), u = n(null), d = n(null), f = n(null), p = n(null), m = n(null), h = n(null), _ = n(!1), v = n([]), y = n(!1);
635
640
  function b(e, t) {
636
641
  let n = o.value.findIndex((t) => t.id === e);
@@ -720,18 +725,18 @@ function w(e) {
720
725
  }
721
726
  }
722
727
  }
723
- async function w(e, n, c) {
728
+ async function C(e, n, c) {
724
729
  let y = r();
725
730
  if (!y) throw Error("Template must be saved before using AI generation");
726
731
  s.value = !0, u.value = null, d.value = null, v.value = [];
727
- let x = C();
732
+ let x = w();
728
733
  o.value = [...o.value, {
729
734
  id: x,
730
735
  role: "user",
731
736
  content: e,
732
737
  timestamp: Date.now()
733
738
  }];
734
- let S = C();
739
+ let S = w();
735
740
  o.value = [...o.value, {
736
741
  id: S,
737
742
  role: "assistant",
@@ -813,14 +818,14 @@ function w(e) {
813
818
  failedPrompt: d,
814
819
  suggestions: v,
815
820
  isLoadingSuggestions: y,
816
- sendPrompt: w,
821
+ sendPrompt: C,
817
822
  toggleLastRevert: T,
818
823
  loadConversation: x,
819
824
  loadSuggestions: S,
820
825
  clearChat: E
821
826
  };
822
827
  }
823
- function T(e) {
828
+ function E(e) {
824
829
  function t(t) {
825
830
  return e === !1 ? !1 : e?.[t] !== !1;
826
831
  }
@@ -829,7 +834,7 @@ function T(e) {
829
834
  hasAnyMenuFeature: i(() => t("chat") || t("scoring") || t("designToTemplate"))
830
835
  };
831
836
  }
832
- function E(e) {
837
+ function D(e) {
833
838
  let { authManager: t, getTemplateId: r } = e, i = n(!1), a = n(null), o = n(null), s = n(null), c = n(""), u = n(null);
834
839
  async function d(e, n) {
835
840
  let s = r();
@@ -972,7 +977,7 @@ function E(e) {
972
977
  reset: m
973
978
  };
974
979
  }
975
- function D(e) {
980
+ function O(e) {
976
981
  let { authManager: t, getTemplateId: r, onApply: i, onError: a } = e, o = n(!1), s = n(null);
977
982
  async function c(e) {
978
983
  let n = r();
@@ -1033,7 +1038,7 @@ function D(e) {
1033
1038
  reset: u
1034
1039
  };
1035
1040
  }
1036
- function O(e) {
1041
+ function k(e) {
1037
1042
  let { authManager: t, getTemplateId: r, getSocketId: a, onComment: o, onError: s, hasCommentingFeature: c } = e, l = new _(t), u = n([]), d = n(!1), f = n(!1), p = i(() => (c?.() ?? !1) && t.userConfig !== null), m = i(() => {
1038
1043
  let e = 0;
1039
1044
  for (let t of u.value) e += 1 + (t.replies?.length ?? 0);
@@ -1231,17 +1236,17 @@ function O(e) {
1231
1236
  applyRemoteDelete: k
1232
1237
  };
1233
1238
  }
1234
- function k(e) {
1239
+ function A(e) {
1235
1240
  let { comments: n, channel: r } = e;
1236
1241
  t(r, (e, t) => {
1237
1242
  t && t.unbind("comment-broadcast"), e && e.bind("comment-broadcast", (e) => {
1238
- A(n, e);
1243
+ j(n, e);
1239
1244
  });
1240
1245
  }), a(() => {
1241
1246
  r.value?.unbind("comment-broadcast");
1242
1247
  });
1243
1248
  }
1244
- function A(e, t) {
1249
+ function j(e, t) {
1245
1250
  switch (t.action) {
1246
1251
  case "comment_created":
1247
1252
  e.applyRemoteCreate(t.comment);
@@ -1258,7 +1263,7 @@ function A(e, t) {
1258
1263
  break;
1259
1264
  }
1260
1265
  }
1261
- var j = [
1266
+ var M = [
1262
1267
  "pusher:member_added",
1263
1268
  "pusher:member_removed",
1264
1269
  "client-block_locked",
@@ -1266,10 +1271,10 @@ var j = [
1266
1271
  "client-operation",
1267
1272
  "mcp-operation"
1268
1273
  ];
1269
- function M(e) {
1270
- for (let t of j) e.unbind(t);
1274
+ function N(e) {
1275
+ for (let t of M) e.unbind(t);
1271
1276
  }
1272
- var N = [
1277
+ var P = [
1273
1278
  "#3b82f6",
1274
1279
  "#ef4444",
1275
1280
  "#10b981",
@@ -1281,10 +1286,10 @@ var N = [
1281
1286
  "#6366f1",
1282
1287
  "#14b8a6"
1283
1288
  ];
1284
- function P(e) {
1289
+ function F(e) {
1285
1290
  let { authManager: r, editor: o, channel: s } = e, c = n([]), l = n(/* @__PURE__ */ new Map()), u = 0, d = !1, f = i(() => r.userConfig?.id ?? "");
1286
1291
  function p() {
1287
- let e = N[u % N.length];
1292
+ let e = P[u % P.length];
1288
1293
  return u++, e;
1289
1294
  }
1290
1295
  function m(e) {
@@ -1346,7 +1351,7 @@ function P(e) {
1346
1351
  return t(() => o.state.selectedBlockId, (e, t) => {
1347
1352
  d || (t && S(t), e && x(e));
1348
1353
  }), t(s, (t, n) => {
1349
- if (n && M(n), !t) {
1354
+ if (n && N(n), !t) {
1350
1355
  c.value = [], l.value = /* @__PURE__ */ new Map(), u = 0;
1351
1356
  return;
1352
1357
  }
@@ -1378,7 +1383,7 @@ function P(e) {
1378
1383
  v(e);
1379
1384
  });
1380
1385
  }), a(() => {
1381
- s.value && M(s.value);
1386
+ s.value && N(s.value);
1382
1387
  }), {
1383
1388
  collaborators: c,
1384
1389
  lockedBlocks: l,
@@ -1386,15 +1391,16 @@ function P(e) {
1386
1391
  _isProcessingRemoteOperation: () => d
1387
1392
  };
1388
1393
  }
1389
- function F(e, t) {
1394
+ function I(e, t) {
1390
1395
  let n = e.addBlock, r = e.updateBlock, i = e.removeBlock, a = e.moveBlock, o = e.updateSettings, s = e.setContent;
1391
- e.addBlock = (e, r, i) => {
1392
- n(e, r, i), t._broadcastOperation({
1396
+ e.addBlock = (e, r, i, a) => {
1397
+ n(e, r, i, a), t._broadcastOperation({
1393
1398
  operation: "add_block",
1394
1399
  data: {
1395
1400
  block: e,
1396
1401
  section_id: r,
1397
- column_index: i
1402
+ column_index: i,
1403
+ index: a
1398
1404
  },
1399
1405
  timestamp: Date.now()
1400
1406
  });
@@ -1438,7 +1444,7 @@ function F(e, t) {
1438
1444
  });
1439
1445
  };
1440
1446
  }
1441
- function I(e) {
1447
+ function L(e) {
1442
1448
  let { authManager: t, onError: r } = e, i = n(null), a = n(!1), o = null, s = null;
1443
1449
  async function c(e, n) {
1444
1450
  if (o) return;
@@ -1468,7 +1474,7 @@ function I(e) {
1468
1474
  getSocketId: u
1469
1475
  };
1470
1476
  }
1471
- function L(e) {
1477
+ function R(e) {
1472
1478
  let t = new _(e.authManager), r = n([]), i = n(!1);
1473
1479
  async function a(n) {
1474
1480
  i.value = !0;
@@ -1515,7 +1521,7 @@ function L(e) {
1515
1521
  deleteModule: c
1516
1522
  };
1517
1523
  }
1518
- function R(e) {
1524
+ function z(e) {
1519
1525
  let t = new _(e.authManager), r = n([]), i = n(!1), a = n(!1);
1520
1526
  async function o() {
1521
1527
  i.value = !0;
@@ -1546,7 +1552,7 @@ function R(e) {
1546
1552
  restoreSnapshot: s
1547
1553
  };
1548
1554
  }
1549
- function z(e) {
1555
+ function B(e) {
1550
1556
  let { authManager: r, getTemplateId: a, save: o, exportHtml: s, onError: c, isAuthReady: l, onBeforeTestEmail: u } = e, d = new _(r), f = n(!1), p = n(null), m = n(null);
1551
1557
  l && t(l, (e) => {
1552
1558
  e && (m.value = r.testEmailConfig);
@@ -1581,7 +1587,7 @@ function z(e) {
1581
1587
  sendTestEmail: v
1582
1588
  };
1583
1589
  }
1584
- function B(e) {
1590
+ function V(e) {
1585
1591
  let { authManager: t, getFontsConfig: n, canUseCustomFonts: r } = e, i = new _(t);
1586
1592
  function a() {
1587
1593
  let e = n?.();
@@ -1606,7 +1612,7 @@ function B(e) {
1606
1612
  getMjmlSource: s
1607
1613
  };
1608
1614
  }
1609
- function V(e) {
1615
+ function H(e) {
1610
1616
  let { authManager: t, onError: r } = e, a = n(null), o = n(!1), s = new _(t), c = i(() => a.value?.features ?? null);
1611
1617
  function l(e) {
1612
1618
  return a.value?.features[e] ?? !1;
@@ -1631,11 +1637,11 @@ function V(e) {
1631
1637
  fetchConfig: u
1632
1638
  };
1633
1639
  }
1634
- var H = 5e3;
1635
- function U(e) {
1640
+ var U = 5e3;
1641
+ function W(e) {
1636
1642
  return e.authManager ? e.authManager.resolveUrl(g.health) : `${(e.baseUrl ?? "https://templatical.com").replace(/\/$/, "")}${g.health}`;
1637
1643
  }
1638
- async function W(e, t) {
1644
+ async function G(e, t) {
1639
1645
  let n = performance.now();
1640
1646
  try {
1641
1647
  let r = t ? await t.authenticatedFetch(g.health, {
@@ -1687,7 +1693,7 @@ async function W(e, t) {
1687
1693
  };
1688
1694
  }
1689
1695
  }
1690
- async function G(e) {
1696
+ async function K(e) {
1691
1697
  if (!e?.host || !e?.app_key) return {
1692
1698
  ok: !1,
1693
1699
  error: "WebSocket configuration not available"
@@ -1703,7 +1709,7 @@ async function G(e) {
1703
1709
  ok: !1,
1704
1710
  error: "WebSocket connection timed out"
1705
1711
  });
1706
- }, H);
1712
+ }, U);
1707
1713
  try {
1708
1714
  n = new WebSocket(t);
1709
1715
  } catch (t) {
@@ -1723,8 +1729,8 @@ async function G(e) {
1723
1729
  };
1724
1730
  });
1725
1731
  }
1726
- async function K(e = {}) {
1727
- let t = await W(U(e), e.authManager), n = await G(t.wsConfig);
1732
+ async function q(e = {}) {
1733
+ let t = await G(W(e), e.authManager), n = await K(t.wsConfig);
1728
1734
  return {
1729
1735
  api: t.api,
1730
1736
  websocket: n,
@@ -1732,7 +1738,7 @@ async function K(e = {}) {
1732
1738
  overall: t.api.ok && t.auth.ok
1733
1739
  };
1734
1740
  }
1735
- function q(e) {
1741
+ function J(e) {
1736
1742
  let { editor: n, channel: r, onOperation: i } = e;
1737
1743
  t(r, (e, t) => {
1738
1744
  t && t.unbind("mcp-operation"), e && e.bind("mcp-operation", (e) => {
@@ -1741,4 +1747,4 @@ function q(e) {
1741
1747
  });
1742
1748
  }
1743
1749
  //#endregion
1744
- export { E as _, T as a, k as c, x as d, B as f, R as g, L as h, w as i, O as l, V as m, K as n, P as o, q as p, v as r, F as s, c as t, D as u, z as v, I as y };
1750
+ export { D as _, E as a, A as c, S as d, V as f, z as g, R as h, T as i, k as l, H as m, q as n, F as o, J as p, v as r, I as s, c as t, O as u, B as v, L as y };
@@ -1,5 +1,5 @@
1
- import { S as e, d as t, w as n } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
2
- //#region ../../node_modules/.pnpm/@lucide+vue@1.16.0_vue@3.5.34_typescript@6.0.3_/node_modules/@lucide/vue/dist/esm/shared/src/utils/isEmptyString.mjs
1
+ import { S as e, d as t, w as n } from "./vue.runtime.esm-bundler-MzYCkFSH.js";
2
+ //#region ../../node_modules/.pnpm/@lucide+vue@1.17.0_vue@3.5.35_typescript@6.0.3_/node_modules/@lucide/vue/dist/esm/shared/src/utils/isEmptyString.mjs
3
3
  var r = (e) => e === "", i = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e) === t).join(" ").trim(), a = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), o = (e) => e.replace(/^([A-Z])|[\s-_]+(\w)/g, (e, t, n) => n ? n.toUpperCase() : t.toLowerCase()), s = (e) => {
4
4
  let t = o(e);
5
5
  return t.charAt(0).toUpperCase() + t.slice(1);
@@ -18,7 +18,7 @@ function u() {
18
18
  return n(l, {});
19
19
  }
20
20
  //#endregion
21
- //#region ../../node_modules/.pnpm/@lucide+vue@1.16.0_vue@3.5.34_typescript@6.0.3_/node_modules/@lucide/vue/dist/esm/Icon.mjs
21
+ //#region ../../node_modules/.pnpm/@lucide+vue@1.17.0_vue@3.5.35_typescript@6.0.3_/node_modules/@lucide/vue/dist/esm/Icon.mjs
22
22
  var d = ({ name: n, iconNode: o, absoluteStrokeWidth: l, "absolute-stroke-width": d, strokeWidth: f, "stroke-width": p, size: m, color: h, ...g }, { slots: _ }) => {
23
23
  let { size: v, color: y, strokeWidth: b = 2, absoluteStrokeWidth: x = !1, class: S = "" } = u(), C = t(() => {
24
24
  let e = r(l) || r(d) || l === !0 || d === !0 || x === !0, t = f || p || b || c["stroke-width"];
@@ -1,4 +1,4 @@
1
- import { Gt as e, J as t, K as n, L as r, Ut as i, bn as a, c as o, tt as s, y as c, yn as l } from "./dist-BzuC8o3y.js";
1
+ import { R as e, Sn as t, Wt as n, Y as r, b as i, c as a, nt as o, q as s, qt as c, xn as l } from "./dist-zInT3Lf6.js";
2
2
  //#region ../../node_modules/.pnpm/linkifyjs@4.3.3/node_modules/linkifyjs/dist/linkify.mjs
3
3
  var u = "aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4w0s2x0a2z0ure5ba0by2idu3namex4d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dad1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2odyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3nd0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rck0msd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0axi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp3ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2oodside6rk0s2ld3w2s1tc1f3xbox3erox4ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2", d = "ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2", f = "numeric", p = "ascii", m = "alpha", h = "asciinumeric", g = "alphanumeric", _ = "domain", ee = "emoji", te = "scheme", v = "slashscheme", y = "whitespace";
4
4
  function b(e, t) {
@@ -57,7 +57,7 @@ C.groups = {}, C.prototype = {
57
57
  return s ? (o = new C(), Object.assign(o.j, s.j), o.jr.push.apply(o.jr, s.jr), o.jd = s.jd, o.t = s.t) : o = new C(), a && (r && (o.t && typeof o.t == "string" ? x(a, Object.assign(S(o.t, r), n), r) : n && x(a, n, r)), o.t = a), i.j[e] = o, o;
58
58
  }
59
59
  };
60
- var w = (e, t, n, r, i) => e.ta(t, n, r, i), T = (e, t, n, r, i) => e.tr(t, n, r, i), ne = (e, t, n, r, i) => e.ts(t, n, r, i), E = (e, t, n, r, i) => e.tt(t, n, r, i), D = "WORD", re = "UWORD", ie = "ASCIINUMERICAL", ae = "ALPHANUMERICAL", O = "LOCALHOST", oe = "TLD", se = "UTLD", ce = "SCHEME", k = "SLASH_SCHEME", le = "NUM", ue = "WS", de = "NL", A = "OPENBRACE", j = "CLOSEBRACE", M = "OPENBRACKET", fe = "CLOSEBRACKET", pe = "OPENPAREN", me = "CLOSEPAREN", he = "OPENANGLEBRACKET", ge = "CLOSEANGLEBRACKET", _e = "FULLWIDTHLEFTPAREN", N = "FULLWIDTHRIGHTPAREN", P = "LEFTCORNERBRACKET", F = "RIGHTCORNERBRACKET", I = "LEFTWHITECORNERBRACKET", ve = "RIGHTWHITECORNERBRACKET", ye = "FULLWIDTHLESSTHAN", be = "FULLWIDTHGREATERTHAN", xe = "AMPERSAND", Se = "APOSTROPHE", Ce = "ASTERISK", L = "AT", we = "BACKSLASH", Te = "BACKTICK", Ee = "CARET", R = "COLON", De = "COMMA", Oe = "DOLLAR", z = "DOT", ke = "EQUALS", Ae = "EXCLAMATION", B = "HYPHEN", V = "PERCENT", je = "PIPE", Me = "PLUS", Ne = "POUND", H = "QUERY", Pe = "QUOTE", Fe = "FULLWIDTHMIDDLEDOT", Ie = "SEMI", U = "SLASH", W = "TILDE", Le = "UNDERSCORE", Re = "EMOJI", ze = "SYM", Be = /* @__PURE__ */ Object.freeze({
60
+ var w = (e, t, n, r, i) => e.ta(t, n, r, i), T = (e, t, n, r, i) => e.tr(t, n, r, i), ne = (e, t, n, r, i) => e.ts(t, n, r, i), E = (e, t, n, r, i) => e.tt(t, n, r, i), D = "WORD", re = "UWORD", ie = "ASCIINUMERICAL", ae = "ALPHANUMERICAL", O = "LOCALHOST", oe = "TLD", se = "UTLD", ce = "SCHEME", k = "SLASH_SCHEME", le = "NUM", ue = "WS", de = "NL", A = "OPENBRACE", j = "CLOSEBRACE", M = "OPENBRACKET", fe = "CLOSEBRACKET", pe = "OPENPAREN", me = "CLOSEPAREN", he = "OPENANGLEBRACKET", ge = "CLOSEANGLEBRACKET", _e = "FULLWIDTHLEFTPAREN", N = "FULLWIDTHRIGHTPAREN", P = "LEFTCORNERBRACKET", F = "RIGHTCORNERBRACKET", I = "LEFTWHITECORNERBRACKET", ve = "RIGHTWHITECORNERBRACKET", ye = "FULLWIDTHLESSTHAN", be = "FULLWIDTHGREATERTHAN", xe = "AMPERSAND", Se = "APOSTROPHE", Ce = "ASTERISK", L = "AT", we = "BACKSLASH", Te = "BACKTICK", Ee = "CARET", R = "COLON", De = "COMMA", Oe = "DOLLAR", z = "DOT", ke = "EQUALS", Ae = "EXCLAMATION", B = "HYPHEN", V = "PERCENT", je = "PIPE", Me = "PLUS", Ne = "POUND", H = "QUERY", Pe = "QUOTE", Fe = "FULLWIDTHMIDDLEDOT", Ie = "SEMI", U = "SLASH", W = "TILDE", Le = "UNDERSCORE", Re = "EMOJI", ze = "SYM", Be = /*#__PURE__*/ Object.freeze({
61
61
  __proto__: null,
62
62
  ALPHANUMERICAL: ae,
63
63
  AMPERSAND: xe,
@@ -510,39 +510,39 @@ function gt(e, t = null, n = null) {
510
510
  return a;
511
511
  }
512
512
  //#endregion
513
- //#region ../../node_modules/.pnpm/@tiptap+extension-link@3.23.6_@tiptap+core@3.23.6_@tiptap+pm@3.23.6__@tiptap+pm@3.23.6/node_modules/@tiptap/extension-link/dist/index.js
513
+ //#region ../../node_modules/.pnpm/@tiptap+extension-link@3.26.0_@tiptap+core@3.26.0_@tiptap+pm@3.26.0__@tiptap+pm@3.26.0/node_modules/@tiptap/extension-link/dist/index.js
514
514
  var _t = "[\0- \xA0 ᠎ -\u2029  ]", vt = new RegExp(_t), yt = RegExp(`${_t}$`), bt = new RegExp(_t, "g");
515
515
  function xt(e) {
516
516
  return e.length === 1 ? e[0].isLink : e.length === 3 && e[1].isLink ? ["()", "[]"].includes(e[0].value + e[2].value) : !1;
517
517
  }
518
- function St(e) {
518
+ function St(n) {
519
519
  return new l({
520
- key: new a("autolink"),
521
- appendTransaction: (n, i, a) => {
522
- let o = n.some((e) => e.docChanged) && !i.doc.eq(a.doc), l = n.some((e) => e.getMeta("preventAutolink"));
523
- if (!o || l) return;
524
- let { tr: u } = a;
525
- if (t(c(i.doc, [...n])).forEach(({ newRange: t }) => {
526
- let n = r(a.doc, t, (e) => e.isTextblock), i, o;
527
- if (n.length > 1) i = n[0], o = a.doc.textBetween(i.pos, i.pos + i.node.nodeSize, void 0, " ");
528
- else if (n.length) {
529
- let e = a.doc.textBetween(t.from, t.to, " ", " ");
520
+ key: new t("autolink"),
521
+ appendTransaction: (t, a, s) => {
522
+ let c = t.some((e) => e.docChanged) && !a.doc.eq(s.doc), l = t.some((e) => e.getMeta("preventAutolink"));
523
+ if (!c || l) return;
524
+ let { tr: u } = s;
525
+ if (r(i(a.doc, [...t])).forEach(({ newRange: t }) => {
526
+ let r = e(s.doc, t, (e) => e.isTextblock), i, a;
527
+ if (r.length > 1) i = r[0], a = s.doc.textBetween(i.pos, i.pos + i.node.nodeSize, void 0, " ");
528
+ else if (r.length) {
529
+ let e = s.doc.textBetween(t.from, t.to, " ", " ");
530
530
  if (!yt.test(e)) return;
531
- i = n[0], o = a.doc.textBetween(i.pos, t.to, void 0, " ");
531
+ i = r[0], a = s.doc.textBetween(i.pos, t.to, void 0, " ");
532
532
  }
533
- if (i && o) {
534
- let t = o.split(vt).filter(Boolean);
535
- if (t.length <= 0) return !1;
536
- let n = t[t.length - 1], r = i.pos + o.lastIndexOf(n);
537
- if (!n) return !1;
538
- let c = ht(n).map((t) => t.toObject(e.defaultProtocol));
533
+ if (i && a) {
534
+ let e = a.split(vt).filter(Boolean);
535
+ if (e.length <= 0) return !1;
536
+ let t = e[e.length - 1], r = i.pos + a.lastIndexOf(t);
537
+ if (!t) return !1;
538
+ let c = ht(t).map((e) => e.toObject(n.defaultProtocol));
539
539
  if (!xt(c)) return !1;
540
540
  c.filter((e) => e.isLink).map((e) => ({
541
541
  ...e,
542
542
  from: r + e.start + 1,
543
543
  to: r + e.end + 1
544
- })).filter((e) => a.schema.marks.code ? !a.doc.rangeHasMark(e.from, e.to, a.schema.marks.code) : !0).filter((t) => e.validate(t.value)).filter((t) => e.shouldAutoLink(t.value)).forEach((t) => {
545
- s(t.from, t.to, a.doc).some((t) => t.mark.type === e.type) || u.addMark(t.from, t.to, e.type.create({ href: t.href }));
544
+ })).filter((e) => s.schema.marks.code ? !s.doc.rangeHasMark(e.from, e.to, s.schema.marks.code) : !0).filter((e) => n.validate(e.value)).filter((e) => n.shouldAutoLink(e.value)).forEach((e) => {
545
+ o(e.from, e.to, s.doc).some((e) => e.mark.type === n.type) || u.addMark(e.from, e.to, n.type.create({ href: e.href }));
546
546
  });
547
547
  }
548
548
  }), u.steps.length) return u;
@@ -551,30 +551,30 @@ function St(e) {
551
551
  }
552
552
  function Ct(e) {
553
553
  return new l({
554
- key: new a("handleClickLink"),
555
- props: { handleClick: (t, r, i) => {
556
- if (i.button !== 0 || !t.editable) return !1;
557
- let a = null;
558
- if (i.target instanceof HTMLAnchorElement) a = i.target;
554
+ key: new t("handleClickLink"),
555
+ props: { handleClick: (t, n, r) => {
556
+ if (r.button !== 0 || !t.editable) return !1;
557
+ let i = null;
558
+ if (r.target instanceof HTMLAnchorElement) i = r.target;
559
559
  else {
560
- let t = i.target;
560
+ let t = r.target;
561
561
  if (!t) return !1;
562
562
  let n = e.editor.view.dom;
563
- a = t.closest("a"), a && !n.contains(a) && (a = null);
563
+ i = t.closest("a"), i && !n.contains(i) && (i = null);
564
564
  }
565
- if (!a) return !1;
566
- let o = !1;
567
- if (e.enableClickSelection && (o = e.editor.commands.extendMarkRange(e.type.name)), e.openOnClick) {
568
- let r = n(t.state, e.type.name), i = a.href ?? r.href, s = a.target ?? r.target;
569
- i && (window.open(i, s), o = !0);
565
+ if (!i) return !1;
566
+ let a = !1;
567
+ if (e.enableClickSelection && (a = e.editor.commands.extendMarkRange(e.type.name)), e.openOnClick) {
568
+ let n = s(t.state, e.type.name), r = i.href ?? n.href, o = i.target ?? n.target;
569
+ r && (window.open(r, o), a = !0);
570
570
  }
571
- return o;
571
+ return a;
572
572
  } }
573
573
  });
574
574
  }
575
575
  function wt(e) {
576
576
  return new l({
577
- key: new a("handlePasteLink"),
577
+ key: new t("handlePasteLink"),
578
578
  props: { handlePaste: (t, n, r) => {
579
579
  let { shouldAutoLink: i } = e, { state: a } = t, { selection: o } = a, { empty: s } = o;
580
580
  if (s) return !1;
@@ -606,7 +606,7 @@ function $(e, t) {
606
606
  t && n.push(t);
607
607
  }), !e || e.replace(bt, "").match(RegExp(`^(?:(?:${n.join("|")}):|[^a-z]|[a-z0-9+.-]+(?:[^a-z+.-:]|$))`, "i"));
608
608
  }
609
- var Et = o.create({
609
+ var Et = a.create({
610
610
  name: "link",
611
611
  priority: 1e3,
612
612
  keepOnSplit: !1,
@@ -676,19 +676,19 @@ var Et = o.create({
676
676
  }
677
677
  }];
678
678
  },
679
- renderHTML({ HTMLAttributes: t }) {
680
- return this.options.isAllowedUri(t.href, {
679
+ renderHTML({ HTMLAttributes: e }) {
680
+ return this.options.isAllowedUri(e.href, {
681
681
  defaultValidate: (e) => !!$(e, this.options.protocols),
682
682
  protocols: this.options.protocols,
683
683
  defaultProtocol: this.options.defaultProtocol
684
684
  }) ? [
685
685
  "a",
686
- e(this.options.HTMLAttributes, t),
686
+ c(this.options.HTMLAttributes, e),
687
687
  0
688
688
  ] : [
689
689
  "a",
690
- e(this.options.HTMLAttributes, {
691
- ...t,
690
+ c(this.options.HTMLAttributes, {
691
+ ...e,
692
692
  href: ""
693
693
  }),
694
694
  0
@@ -725,7 +725,7 @@ var Et = o.create({
725
725
  };
726
726
  },
727
727
  addPasteRules() {
728
- return [i({
728
+ return [n({
729
729
  find: (e) => {
730
730
  let t = [];
731
731
  if (e) {
@@ -1,6 +1,6 @@
1
- import { Gt as e, c as t } from "./dist-BzuC8o3y.js";
2
- //#region ../../node_modules/.pnpm/@tiptap+extension-subscript@3.23.6_@tiptap+core@3.23.6_@tiptap+pm@3.23.6__@tiptap+pm@3.23.6/node_modules/@tiptap/extension-subscript/dist/index.js
3
- var n = t.create({
1
+ import { c as e, qt as t } from "./dist-zInT3Lf6.js";
2
+ //#region ../../node_modules/.pnpm/@tiptap+extension-subscript@3.26.0_@tiptap+core@3.26.0_@tiptap+pm@3.26.0__@tiptap+pm@3.26.0/node_modules/@tiptap/extension-subscript/dist/index.js
3
+ var n = e.create({
4
4
  name: "subscript",
5
5
  addOptions() {
6
6
  return { HTMLAttributes: {} };
@@ -13,10 +13,10 @@ var n = t.create({
13
13
  }
14
14
  }];
15
15
  },
16
- renderHTML({ HTMLAttributes: t }) {
16
+ renderHTML({ HTMLAttributes: e }) {
17
17
  return [
18
18
  "sub",
19
- e(this.options.HTMLAttributes, t),
19
+ t(this.options.HTMLAttributes, e),
20
20
  0
21
21
  ];
22
22
  },