@templatical/editor 0.19.0 → 0.20.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 (103) hide show
  1. package/dist/{AiChatSidebar-DAQTFuvi.js → AiChatSidebar-ChrE6pUq.js} +7 -7
  2. package/dist/{AiFeatureMenu-aFSO20PR.js → AiFeatureMenu-DkQ9HhQ6.js} +4 -4
  3. package/dist/{BlockIssueBadge-BQmq1bxn.js → BlockIssueBadge-B4QjePax.js} +2 -2
  4. package/dist/{CloudEditor-D0K-m1GA.js → CloudEditor-CfX-aMiV.js} +15 -15
  5. package/dist/{CollaboratorBar-CJO3l6Dt.js → CollaboratorBar-DTibhQ1j.js} +2 -2
  6. package/dist/{ColorPicker-BsgpTJqK.js → ColorPicker-4vDYhdGe.js} +1 -1
  7. package/dist/{CommentsSidebar-BYMVucZh.js → CommentsSidebar-D-o5Stlg.js} +8 -8
  8. package/dist/{CountdownToolbar-PJI3ffi1.js → CountdownToolbar-D7yQqnA2.js} +2 -2
  9. package/dist/{DesignReferenceSidebar-QfAV8XT9.js → DesignReferenceSidebar-DnO6ZdwS.js} +5 -5
  10. package/dist/{IssuesPanel-CTjRgz8w.js → IssuesPanel-X_vkNGrs.js} +5 -5
  11. package/dist/{ModuleBrowserModal-BNalLx0k.js → ModuleBrowserModal-AJt--JPh.js} +6 -6
  12. package/dist/{ModulePreviewCanvas-BwObwisa.js → ModulePreviewCanvas-BKYOcVCh.js} +1 -1
  13. package/dist/{NumberWithSuffix-D3BKz66W.js → NumberWithSuffix-Bf3rNxza.js} +1 -1
  14. package/dist/{ParagraphEditor-Cf75UfSo.js → ParagraphEditor-C5ixOIYb.js} +7 -7
  15. package/dist/{RichTextEditorContent-MdaLz6Q3.js → RichTextEditorContent-DwhDnMsG.js} +3 -3
  16. package/dist/{SaveModuleDialog-MTjwiF9D.js → SaveModuleDialog-B4QX9eiv.js} +3 -3
  17. package/dist/{SnapshotHistory-C_Y1LzAY.js → SnapshotHistory-DaVueFv6.js} +5 -5
  18. package/dist/{TemplateScoringPanel-DikuKc6i.js → TemplateScoringPanel-B0UHoTLx.js} +10 -10
  19. package/dist/{TestEmailModal-BW8aTtzf.js → TestEmailModal-BkauxF7j.js} +3 -3
  20. package/dist/{TitleEditor-CCUkbRN0.js → TitleEditor-n6WDVDjW.js} +4 -4
  21. package/dist/{TplModal-DoOwUKlT.js → TplModal-BDDyvT-C.js} +1 -1
  22. package/dist/{blockTypeIcons-BlPKjD7M.js → blockTypeIcons-4D0aFXNg.js} +2 -2
  23. package/dist/bundle-stats.json +5 -5
  24. package/dist/cdn/chunks/{AiFeatureMenu-RwJiaPXZ.js → AiFeatureMenu-CIBHAGSz.js} +2 -2
  25. package/dist/cdn/chunks/{AiFeatureMenu-RwJiaPXZ.js.map → AiFeatureMenu-CIBHAGSz.js.map} +1 -1
  26. package/dist/cdn/chunks/{BlockIssueBadge-DM-TDKbr.js → BlockIssueBadge-CxMiLo3p.js} +4 -4
  27. package/dist/cdn/chunks/{BlockIssueBadge-DM-TDKbr.js.map → BlockIssueBadge-CxMiLo3p.js.map} +1 -1
  28. package/dist/cdn/chunks/{CloudEditor-Dufl354p.js → CloudEditor-CEa3Xgqh.js} +131 -131
  29. package/dist/cdn/chunks/{CloudEditor-Dufl354p.js.map → CloudEditor-CEa3Xgqh.js.map} +1 -1
  30. package/dist/cdn/chunks/{CollaboratorBar-xsU20iPl.js → CollaboratorBar-Bk1gD02G.js} +3 -3
  31. package/dist/cdn/chunks/{CollaboratorBar-xsU20iPl.js.map → CollaboratorBar-Bk1gD02G.js.map} +1 -1
  32. package/dist/cdn/chunks/{ColorPicker-y_obnw4o.js → ColorPicker-ll8pynws.js} +179 -179
  33. package/dist/cdn/chunks/ColorPicker-ll8pynws.js.map +1 -0
  34. package/dist/cdn/chunks/{CountdownBlock-sHsRMe1q.js → CountdownBlock-eGUE7hhw.js} +4 -4
  35. package/dist/cdn/chunks/{CountdownBlock-sHsRMe1q.js.map → CountdownBlock-eGUE7hhw.js.map} +1 -1
  36. package/dist/cdn/chunks/{CountdownToolbar-Ckc_jEi-.js → CountdownToolbar-C1bkSjUR.js} +4 -4
  37. package/dist/cdn/chunks/{CountdownToolbar-Ckc_jEi-.js.map → CountdownToolbar-C1bkSjUR.js.map} +1 -1
  38. package/dist/cdn/chunks/{IssuesPanel-DF5Ajuna.js → IssuesPanel-Csasylf_.js} +5 -5
  39. package/dist/cdn/chunks/{IssuesPanel-DF5Ajuna.js.map → IssuesPanel-Csasylf_.js.map} +1 -1
  40. package/dist/cdn/chunks/{ModuleBrowserModal-DG4AVFjH.js → ModuleBrowserModal-DznWWtBI.js} +7 -7
  41. package/dist/cdn/chunks/{ModuleBrowserModal-DG4AVFjH.js.map → ModuleBrowserModal-DznWWtBI.js.map} +1 -1
  42. package/dist/cdn/chunks/{ModulePreviewCanvas-Bc_PcJuc.js → ModulePreviewCanvas-D-h7fr87.js} +20 -20
  43. package/dist/cdn/chunks/{ModulePreviewCanvas-Bc_PcJuc.js.map → ModulePreviewCanvas-D-h7fr87.js.map} +1 -1
  44. package/dist/cdn/chunks/{NumberWithSuffix-8fOO-LC_.js → NumberWithSuffix-Dt-0odUN.js} +2 -2
  45. package/dist/cdn/chunks/{NumberWithSuffix-8fOO-LC_.js.map → NumberWithSuffix-Dt-0odUN.js.map} +1 -1
  46. package/dist/cdn/chunks/{ParagraphEditor-BkafKSju.js → ParagraphEditor-v0_XEL-v.js} +18 -18
  47. package/dist/cdn/chunks/{ParagraphEditor-BkafKSju.js.map → ParagraphEditor-v0_XEL-v.js.map} +1 -1
  48. package/dist/cdn/chunks/{RichTextEditorContent-BthhzOZS.js → RichTextEditorContent-NQExNsaV.js} +4 -4
  49. package/dist/cdn/chunks/{RichTextEditorContent-BthhzOZS.js.map → RichTextEditorContent-NQExNsaV.js.map} +1 -1
  50. package/dist/cdn/chunks/{SaveModuleDialog-DhsfYf2n.js → SaveModuleDialog-BpFhTi-k.js} +5 -5
  51. package/dist/cdn/chunks/{SaveModuleDialog-DhsfYf2n.js.map → SaveModuleDialog-BpFhTi-k.js.map} +1 -1
  52. package/dist/cdn/chunks/{TitleEditor-DLv9cXba.js → TitleEditor-CS-_MzYs.js} +8 -8
  53. package/dist/cdn/chunks/{TitleEditor-DLv9cXba.js.map → TitleEditor-CS-_MzYs.js.map} +1 -1
  54. package/dist/cdn/chunks/{blockTypeIcons-B0uibGX7.js → blockTypeIcons-B0Hjh42a.js} +3 -3
  55. package/dist/cdn/chunks/{blockTypeIcons-B0uibGX7.js.map → blockTypeIcons-B0Hjh42a.js.map} +1 -1
  56. package/dist/cdn/chunks/{extensions-DLHvZ0UH.js → extensions-Di3hdIRT.js} +22 -22
  57. package/dist/cdn/chunks/{extensions-DLHvZ0UH.js.map → extensions-Di3hdIRT.js.map} +1 -1
  58. package/dist/cdn/chunks/{features-Cnfv4QAY.js → features-CLIZ7Q-Y.js} +1490 -1447
  59. package/dist/cdn/chunks/features-CLIZ7Q-Y.js.map +1 -0
  60. package/dist/cdn/chunks/{icons-DbcM69bb.js → icons-GX40Qm2W.js} +2 -2
  61. package/dist/cdn/chunks/{icons-DbcM69bb.js.map → icons-GX40Qm2W.js.map} +1 -1
  62. package/dist/cdn/chunks/{media-library-DpSMwHd4.js → media-library-yYAkAagU.js} +80 -80
  63. package/dist/cdn/chunks/{media-library-DpSMwHd4.js.map → media-library-yYAkAagU.js.map} +1 -1
  64. package/dist/cdn/chunks/{pusher-CIwiKF8H.js → pusher-R0v5p99W.js} +27 -22
  65. package/dist/cdn/chunks/pusher-R0v5p99W.js.map +1 -0
  66. package/dist/cdn/chunks/quality-DffYv9j5.js +2180 -0
  67. package/dist/cdn/chunks/{quality-D9QqkRcU.js.map → quality-DffYv9j5.js.map} +1 -1
  68. package/dist/cdn/chunks/{renderer-BsLQZNXU.js → renderer-DpBGiXOg.js} +13 -13
  69. package/dist/cdn/chunks/{renderer-BsLQZNXU.js.map → renderer-DpBGiXOg.js.map} +1 -1
  70. package/dist/cdn/chunks/{src-zu1ehVNN.js → src-9K6uFiuK.js} +4 -4
  71. package/dist/cdn/chunks/{src-zu1ehVNN.js.map → src-9K6uFiuK.js.map} +1 -1
  72. package/dist/cdn/chunks/{styles-Dx-jXeCd.js → styles-DHSmjlpX.js} +837 -833
  73. package/dist/cdn/chunks/styles-DHSmjlpX.js.map +1 -0
  74. package/dist/cdn/editor.js +11 -11
  75. package/dist/{check-Cg6Mc2pP.js → check-Bl4J_tYV.js} +1 -1
  76. package/dist/{chevron-down-dClfxKrJ.js → chevron-down-COEcl2iP.js} +1 -1
  77. package/dist/{circle-alert-Bhzm-fNA.js → circle-alert-CvHi5etc.js} +1 -1
  78. package/dist/{clock-m7TwQw4b.js → clock-CZZw62e8.js} +1 -1
  79. package/dist/{createLucideIcon-FSF4peHQ.js → createLucideIcon-_peTZQtY.js} +2 -2
  80. package/dist/{image-up-CDEgJqwA.js → image-up-D26rNdfX.js} +1 -1
  81. package/dist/{info-BNP8yGsK.js → info-CE3JSTqk.js} +1 -1
  82. package/dist/{list-checks-jepi4iYr.js → list-checks-BQsLrtBB.js} +1 -1
  83. package/dist/{loader-circle-BT38qSm3.js → loader-circle-s9Rh5lLd.js} +1 -1
  84. package/dist/{message-circle-BAHcL9S-.js → message-circle-CI62d690.js} +1 -1
  85. package/dist/{refresh-cw-as5Bmg4X.js → refresh-cw-DlYfl65Y.js} +1 -1
  86. package/dist/{scan-line-IAMjPtRw.js → scan-line-CHadrYVb.js} +1 -1
  87. package/dist/{send-DvMay6bt.js → send-CbP40otC.js} +1 -1
  88. package/dist/{shield-check-YYDhGroE.js → shield-check-Bnj9aRoJ.js} +1 -1
  89. package/dist/{sparkles-CCwQMMMZ.js → sparkles-CncWT57a.js} +1 -1
  90. package/dist/{styles-64uLkPJV.js → styles-DkF_-uX8.js} +658 -654
  91. package/dist/templatical-editor.js +4 -4
  92. package/dist/{text-align-start-BwsA6QzC.js → text-align-start-B458vzYw.js} +1 -1
  93. package/dist/{trash-2-CRBDolnR.js → trash-2-DO0yjSU1.js} +1 -1
  94. package/dist/{triangle-alert-B2g0ALvq.js → triangle-alert-C18_ima6.js} +1 -1
  95. package/dist/{upload-y4gxiFp5.js → upload-DsCd2zTR.js} +1 -1
  96. package/dist/{useEditorCore-ea9OrrH3.js → useEditorCore-kKUemYY6.js} +910 -867
  97. package/dist/{x-Ctg_250T.js → x-BCFQuE_q.js} +1 -1
  98. package/package.json +10 -10
  99. package/dist/cdn/chunks/ColorPicker-y_obnw4o.js.map +0 -1
  100. package/dist/cdn/chunks/features-Cnfv4QAY.js.map +0 -1
  101. package/dist/cdn/chunks/pusher-CIwiKF8H.js.map +0 -1
  102. package/dist/cdn/chunks/quality-D9QqkRcU.js +0 -2180
  103. package/dist/cdn/chunks/styles-Dx-jXeCd.js.map +0 -1
@@ -1,16 +1,16 @@
1
- import { $ as e, A as t, B as n, D as r, Dt as i, E as a, Et as o, H as s, I as c, J as l, K as u, N as d, O as f, Ot as p, R as m, T as h, W as g, Y as _, Z as v, _ as y, c as b, d as x, et as S, g as C, h as w, j as T, k as E, l as D, m as O, nt as k, q as ee, r as A, rt as te, s as j, tt as ne, u as M, v as re, w as ie, x as N, y as ae, z as oe } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
2
- import { c as P, o as se, s as ce } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
3
- import { t as le } from "./upload-y4gxiFp5.js";
4
- import { A as ue, C as de, D as fe, E as pe, F as me, I as he, M as ge, N as _e, P as ve, S as ye, T as be, _ as xe, a as Se, b as Ce, c as we, d as Te, f as Ee, g as De, h as Oe, i as ke, j as Ae, k as je, l as Me, m as Ne, n as Pe, p as Fe, r as Ie, t as Le, u as Re, v as ze, w as Be, x as Ve, y as He } from "./dist-BJbqgyPn.js";
5
- import { f as Ue, g as We, h as Ge, m as Ke } from "./dist-DYv_Pttj.js";
6
- import { c as qe, d as Je, i as Ye, l as Xe, o as Ze, r as Qe, t as $e, u as et } from "./usePopoverPosition-F9STHRIr.js";
1
+ import { $ as e, A as t, B as n, D as r, Dt as i, E as a, Et as o, H as s, I as c, J as l, K as u, N as d, O as f, Ot as p, R as m, T as h, W as g, Y as _, Z as v, _ as y, c as b, d as x, et as S, g as C, h as w, j as T, k as E, l as D, m as O, nt as k, q as A, r as j, rt as ee, s as M, tt as te, u as N, v as ne, w as re, x as P, y as ie, z as ae } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
2
+ import { c as F, o as oe, s as se } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
3
+ import { t as ce } from "./upload-DsCd2zTR.js";
4
+ import { A as le, C as ue, D as de, E as fe, F as pe, I as me, M as he, N as ge, P as _e, S as ve, T as ye, _ as be, a as xe, b as Se, c as Ce, d as we, f as Te, g as Ee, h as De, i as Oe, j as ke, k as Ae, l as je, m as Me, n as Ne, p as Pe, r as Fe, t as Ie, u as Le, v as Re, w as ze, x as Be, y as Ve } from "./dist-BJbqgyPn.js";
5
+ import { f as He, g as Ue, h as We, m as Ge } from "./dist-DYv_Pttj.js";
6
+ import { a as Ke, c as qe, d as Je, i as Ye, l as Xe, o as Ze, r as Qe, t as $e, u as et } from "./usePopoverPosition-F9STHRIr.js";
7
7
  import { A as tt, B as nt, C as rt, D as it, E as at, I as ot, L as st, M as ct, N as lt, O as ut, R as dt, S as ft, T as pt, _ as mt, a as ht, b as gt, d as _t, f as vt, g as yt, h as bt, i as xt, j as St, k as Ct, l as wt, m as Tt, n as Et, o as Dt, p as Ot, s as kt, v as At, w as jt, x as Mt, y as Nt, z as Pt } from "./keys-DFaIbGR8.js";
8
8
  import { t as Ft } from "./useI18n-BNMzZTM5.js";
9
- import { t as F } from "./createLucideIcon-FSF4peHQ.js";
10
- import { t as It } from "./loader-circle-BT38qSm3.js";
11
- import { t as Lt } from "./message-circle-BAHcL9S-.js";
12
- import { t as Rt } from "./trash-2-CRBDolnR.js";
13
- import { t as zt } from "./triangle-alert-B2g0ALvq.js";
9
+ import { t as I } from "./createLucideIcon-_peTZQtY.js";
10
+ import { t as It } from "./loader-circle-s9Rh5lLd.js";
11
+ import { t as Lt } from "./message-circle-CI62d690.js";
12
+ import { t as Rt } from "./trash-2-DO0yjSU1.js";
13
+ import { t as zt } from "./triangle-alert-C18_ima6.js";
14
14
  import { t as Bt } from "./LoadingTrack-KIcREPlS.js";
15
15
  import { t as Vt } from "./_plugin-vue_export-helper-B3ysoDQm.js";
16
16
  import "./useCloudI18n-PCDOC2kz.js";
@@ -21,8 +21,8 @@ function Wt(e) {
21
21
  return e === "1" ? 1 : e === "3" ? 3 : 2;
22
22
  }
23
23
  function Gt(e) {
24
- let t = ee({
25
- content: e.content ?? Fe(e.defaultFontFamily, e.templateDefaults),
24
+ let t = A({
25
+ content: e.content ?? Pe(e.defaultFontFamily, e.templateDefaults),
26
26
  selectedBlockId: null,
27
27
  viewport: "desktop",
28
28
  darkMode: !1,
@@ -177,7 +177,7 @@ var Kt = 50, qt = 300, Jt = 1500;
177
177
  function Yt(e) {
178
178
  let { content: t, setContent: r, isRemoteOperation: i, maxSize: a = Kt } = e, o = _([]), s = _([]), c = _(!1), l = null, u = null, d = n(() => o.value.length > 0), f = n(() => s.value.length > 0);
179
179
  function p() {
180
- return he(t.value);
180
+ return me(t.value);
181
181
  }
182
182
  function m(e) {
183
183
  o.value.push(e), o.value.length > a && o.value.splice(0, o.value.length - a);
@@ -242,30 +242,30 @@ function Yt(e) {
242
242
  function Xt(e) {
243
243
  e.type === "table" ? e.rows = e.rows.map((e) => ({
244
244
  ...e,
245
- id: be(),
245
+ id: ye(),
246
246
  cells: e.cells.map((e) => ({
247
247
  ...e,
248
- id: be()
248
+ id: ye()
249
249
  }))
250
250
  })) : e.type === "social" ? e.icons = e.icons.map((e) => ({
251
251
  ...e,
252
- id: be()
252
+ id: ye()
253
253
  })) : e.type === "menu" && (e.items = e.items.map((e) => ({
254
254
  ...e,
255
- id: be()
255
+ id: ye()
256
256
  })));
257
257
  }
258
258
  function Zt(e) {
259
259
  let { addBlock: t, removeBlock: n, updateBlock: r, selectBlock: i, findBlockLocation: a } = e;
260
260
  function o(n, r, a) {
261
- let o = Me(n, e.blockDefaults);
261
+ let o = je(n, e.blockDefaults);
262
262
  return t(o, r, a), i(o.id), o;
263
263
  }
264
264
  function s(e, n, r) {
265
265
  let o = JSON.parse(JSON.stringify(e));
266
- if (o.id = be(), Xt(o), o.type === "section" && (o.children = o.children.map((e) => e.map((e) => {
266
+ if (o.id = ye(), Xt(o), o.type === "section" && (o.children = o.children.map((e) => e.map((e) => {
267
267
  let t = JSON.parse(JSON.stringify(e));
268
- return t.id = be(), Xt(t), t;
268
+ return t.id = ye(), Xt(t), t;
269
269
  }))), n !== void 0 || r !== void 0) t(o, n, r);
270
270
  else {
271
271
  let i = a?.(e.id) ?? null;
@@ -308,7 +308,7 @@ function Qt(e) {
308
308
  o = null, c() && !s && n() && r(JSON.parse(JSON.stringify(t.value)));
309
309
  }, i));
310
310
  }
311
- let m = te(t, () => {
311
+ let m = ee(t, () => {
312
312
  c() && !s && n() && p();
313
313
  }, { deep: !0 });
314
314
  function h() {
@@ -323,7 +323,7 @@ function Qt(e) {
323
323
  };
324
324
  }
325
325
  function $t(e) {
326
- let t = ee(/* @__PURE__ */ new Set()), r = n(() => t.size > 0);
326
+ let t = A(/* @__PURE__ */ new Set()), r = n(() => t.size > 0);
327
327
  function i(e) {
328
328
  return t.has(e);
329
329
  }
@@ -406,7 +406,7 @@ function on() {
406
406
  //#endregion
407
407
  //#region src/composables/useImageUrlResolver.ts
408
408
  function sn(e) {
409
- let t = ee(/* @__PURE__ */ new Map()), n = /* @__PURE__ */ new Set();
409
+ let t = A(/* @__PURE__ */ new Map()), n = /* @__PURE__ */ new Set();
410
410
  function r(e) {
411
411
  return t.get(e);
412
412
  }
@@ -439,7 +439,7 @@ function sn(e) {
439
439
  };
440
440
  }
441
441
  function cn(e) {
442
- let t = N(gt, null), n = j(e);
442
+ let t = P(gt, null), n = M(e);
443
443
  if (!t) return n;
444
444
  let r;
445
445
  function i() {
@@ -459,7 +459,7 @@ function cn(e) {
459
459
  r = void 0, t.lookup(e);
460
460
  }, 300);
461
461
  }
462
- }, { immediate: !0 }), j(() => {
462
+ }, { immediate: !0 }), M(() => {
463
463
  let e = n.value;
464
464
  if (!e) return e;
465
465
  let r = t.get(e);
@@ -539,7 +539,7 @@ function fn(e) {
539
539
  try {
540
540
  let t = await import("@templatical/quality");
541
541
  if (s) return;
542
- i.value = { lintTemplate: t.lintTemplate }, n.value = !0, u(), o = We(e.content, u, {
542
+ i.value = { lintTemplate: t.lintTemplate }, n.value = !0, u(), o = Ue(e.content, u, {
543
543
  debounce: e.debounce ?? 500,
544
544
  deep: !0
545
545
  });
@@ -677,7 +677,7 @@ function mn(e, t) {
677
677
  //#region src/composables/useUiTheme.ts
678
678
  function hn(e) {
679
679
  let t = Je("(prefers-color-scheme: dark)");
680
- return { resolvedTheme: j(() => e.value === "auto" ? t.value ? "dark" : "light" : e.value) };
680
+ return { resolvedTheme: M(() => e.value === "auto" ? t.value ? "dark" : "light" : e.value) };
681
681
  }
682
682
  //#endregion
683
683
  //#region src/composables/useThemeStyles.ts
@@ -706,7 +706,7 @@ var gn = {
706
706
  canvasBg: "--tpl-canvas-bg"
707
707
  };
708
708
  function _n({ themeOverrides: e, resolvedTheme: t, extraStyles: n }) {
709
- return { themeStyles: j(() => {
709
+ return { themeStyles: M(() => {
710
710
  let r = {}, i = e.value, a = t.value === "dark" ? i.dark : i;
711
711
  if (a) for (let [e, t] of Object.entries(gn)) {
712
712
  let n = a[e];
@@ -740,15 +740,15 @@ var bn = {
740
740
  function xn() {
741
741
  let e = v(/* @__PURE__ */ new Map());
742
742
  function t(t, n) {
743
- e.value.set(t, n), ne(e);
743
+ e.value.set(t, n), te(e);
744
744
  }
745
745
  function n(t, n) {
746
746
  let r = `custom:${t.type}`, i = {
747
747
  component: n,
748
- createBlock: () => Ee(t),
748
+ createBlock: () => Te(t),
749
749
  definition: t
750
750
  };
751
- e.value.set(r, i), ne(e);
751
+ e.value.set(r, i), te(e);
752
752
  }
753
753
  function r(t) {
754
754
  if (t.type === "custom") {
@@ -796,7 +796,7 @@ function xn() {
796
796
  //#endregion
797
797
  //#region src/composables/useCustomBlockStylesheets.ts
798
798
  function Sn(e, t) {
799
- return j(() => {
799
+ return M(() => {
800
800
  let n = Cn(e.value.blocks);
801
801
  if (n.size === 0) return [];
802
802
  let r = /* @__PURE__ */ new Set(), i = [];
@@ -815,7 +815,7 @@ function Cn(e) {
815
815
  }
816
816
  function wn(e, t) {
817
817
  for (let n of e) {
818
- if (ue(n)) {
818
+ if (le(n)) {
819
819
  t.add(n.customType);
820
820
  continue;
821
821
  }
@@ -831,55 +831,55 @@ function wn(e, t) {
831
831
  var Tn = [
832
832
  {
833
833
  type: "section",
834
- createBlock: He
834
+ createBlock: Ve
835
835
  },
836
836
  {
837
837
  type: "title",
838
- createBlock: de
838
+ createBlock: ue
839
839
  },
840
840
  {
841
841
  type: "paragraph",
842
- createBlock: ze
842
+ createBlock: Re
843
843
  },
844
844
  {
845
845
  type: "image",
846
- createBlock: De
846
+ createBlock: Ee
847
847
  },
848
848
  {
849
849
  type: "button",
850
- createBlock: Re
850
+ createBlock: Le
851
851
  },
852
852
  {
853
853
  type: "divider",
854
- createBlock: Ne
854
+ createBlock: Me
855
855
  },
856
856
  {
857
857
  type: "video",
858
- createBlock: Be
858
+ createBlock: ze
859
859
  },
860
860
  {
861
861
  type: "social",
862
- createBlock: Ce
862
+ createBlock: Se
863
863
  },
864
864
  {
865
865
  type: "menu",
866
- createBlock: xe
866
+ createBlock: be
867
867
  },
868
868
  {
869
869
  type: "table",
870
- createBlock: ye
870
+ createBlock: ve
871
871
  },
872
872
  {
873
873
  type: "spacer",
874
- createBlock: Ve
874
+ createBlock: Be
875
875
  },
876
876
  {
877
877
  type: "html",
878
- createBlock: Oe
878
+ createBlock: De
879
879
  },
880
880
  {
881
881
  type: "countdown",
882
- createBlock: Te
882
+ createBlock: we
883
883
  }
884
884
  ];
885
885
  function En(e, t) {
@@ -905,7 +905,7 @@ function kn(e, t, n) {
905
905
  let r = new Set(e.map((e) => Qe(e))), i = [], a = (e, t) => {
906
906
  for (let [n, o] of Object.entries(e)) typeof o == "string" ? o !== "" && /color$/i.test(n) && !r.has(Qe(o)) && i.push(`${t}.${n}: ${o}`) : On(o) && a(o, `${t}.${n}`);
907
907
  }, o = t;
908
- for (let [e, t] of Object.entries(Le)) {
908
+ for (let [e, t] of Object.entries(Ie)) {
909
909
  let n = o?.[e];
910
910
  a({
911
911
  ...t,
@@ -913,13 +913,52 @@ function kn(e, t, n) {
913
913
  }, e);
914
914
  }
915
915
  return a({
916
- ...Pe,
916
+ ...Ne,
917
917
  ...n ?? {}
918
918
  }, "template"), i;
919
919
  }
920
920
  //#endregion
921
+ //#region src/utils/resolveFieldColors.ts
922
+ function An(e, t) {
923
+ let n = Ze({ presets: e.presets }, Ke), r = n.presets.length === 0, i = e.allowCustom ?? t.allowCustom;
924
+ return {
925
+ presets: r ? t.presets : n.presets,
926
+ allowCustom: t.allowCustom !== !1 && i,
927
+ invalidPresets: n.invalidPresets,
928
+ emptyPresets: e.presets !== void 0 && e.presets.length === 0,
929
+ presetsInherited: r,
930
+ allowCustomIgnored: e.allowCustom === !0 && t.allowCustom === !1
931
+ };
932
+ }
933
+ //#endregion
934
+ //#region src/utils/collectColorFieldIssues.ts
935
+ function jn(e, t) {
936
+ let n = [], r = (r, i) => {
937
+ let a = An(r, t), o = `custom block "${e.type}" field "${i}"`, s = (t) => `${e.type}:${i}:${t}`;
938
+ if (a.invalidPresets.length > 0 && n.push({
939
+ id: s("invalid-presets"),
940
+ message: `${o}: presets skipped invalid entries: ${a.invalidPresets.join(", ")} — presets must be hex colors (#rgb or #rrggbb).` + (a.presetsInherited ? " No valid entries are left, so the field inherits colors.presets." : "")
941
+ }), a.emptyPresets && n.push({
942
+ id: s("empty-presets"),
943
+ message: `${o}: presets is empty — a field palette can only narrow the editor's, so an empty list is ignored and the field inherits colors.presets.`
944
+ }), a.allowCustomIgnored && n.push({
945
+ id: s("allow-custom-ignored"),
946
+ message: `${o}: allowCustom: true is ignored because colors.allowCustom is false — a field can narrow the editor-wide palette, never unlock it.`
947
+ }), !a.allowCustom && a.presets.length > 0) {
948
+ let e = r.default ?? "", t = new Set(a.presets.map((e) => Qe(e)));
949
+ e !== "" && !t.has(Qe(e)) && n.push({
950
+ id: s("off-palette-default"),
951
+ message: `${o} locks custom colours, but its default ${e} falls outside the field's presets: ${a.presets.join(", ")}. New blocks start on a colour the picker can't reselect — set the default from the same palette.`
952
+ });
953
+ }
954
+ };
955
+ for (let t of e.fields) if (t.type === "color") r(t, t.key);
956
+ else if (t.type === "repeatable") for (let e of t.fields) e.type === "color" && r(e, `${t.key}[].${e.key}`);
957
+ return n;
958
+ }
959
+ //#endregion
921
960
  //#region src/utils/keyboardShortcuts.ts
922
- function An(e) {
961
+ function Mn(e) {
923
962
  for (let t of e.composedPath()) {
924
963
  if (!(t instanceof HTMLElement)) continue;
925
964
  if (t.isContentEditable) return !0;
@@ -928,14 +967,14 @@ function An(e) {
928
967
  }
929
968
  return !1;
930
969
  }
931
- function jn(e, t) {
970
+ function Nn(e, t) {
932
971
  let n = e.metaKey || e.ctrlKey;
933
972
  if (n && e.key.toLowerCase() === "s") {
934
973
  e.preventDefault(), t.onSave?.();
935
974
  return;
936
975
  }
937
976
  if (n && e.key.toLowerCase() === "z") {
938
- if (An(e)) return;
977
+ if (Mn(e)) return;
939
978
  e.preventDefault(), e.shiftKey ? t.history.redo() : (t.onBeforeUndo?.(), t.history.undo());
940
979
  return;
941
980
  }
@@ -943,11 +982,11 @@ function jn(e, t) {
943
982
  t.selectBlock(null);
944
983
  return;
945
984
  }
946
- (e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !An(e) && (e.preventDefault(), t.history.record(), t.removeBlock(t.getSelectedBlockId()));
985
+ (e.key === "Delete" || e.key === "Backspace") && t.getSelectedBlockId() && !Mn(e) && (e.preventDefault(), t.history.record(), t.removeBlock(t.getSelectedBlockId()));
947
986
  }
948
987
  //#endregion
949
988
  //#region src/utils/mergeTagLabelSegments.ts
950
- function Mn(e, t, n) {
989
+ function Pn(e, t, n) {
951
990
  if (!e) return [];
952
991
  let r = RegExp(`(${n.value.source}|${n.logic.source})`, "g"), i = [], a = 0, o;
953
992
  for (; (o = r.exec(e)) !== null;) {
@@ -956,12 +995,12 @@ function Mn(e, t, n) {
956
995
  value: e.slice(a, o.index)
957
996
  });
958
997
  let r = o[0];
959
- ge(r, n) ? i.push({
998
+ he(r, n) ? i.push({
960
999
  type: "tag",
961
- value: fe(r, t)
962
- }) : Ae(r, n) ? i.push({
1000
+ value: de(r, t)
1001
+ }) : ke(r, n) ? i.push({
963
1002
  type: "tag",
964
- value: pe(r, n)
1003
+ value: fe(r, n)
965
1004
  }) : i.push({
966
1005
  type: "text",
967
1006
  value: r
@@ -974,27 +1013,27 @@ function Mn(e, t, n) {
974
1013
  }
975
1014
  //#endregion
976
1015
  //#region src/components/MergeTagPreviewText.vue
977
- var Nn = y({
1016
+ var Fn = y({
978
1017
  name: "MergeTagPreviewText",
979
1018
  props: { text: {
980
1019
  type: String,
981
1020
  required: !0
982
1021
  } },
983
1022
  setup(e) {
984
- let t = N(pt, []), n = N(ut, Se.liquid), r = j(() => Mn(e.text, t, n));
985
- return () => r.value.map((e, t) => e.type === "tag" ? ae("span", {
1023
+ let t = P(pt, []), n = P(ut, xe.liquid), r = M(() => Pn(e.text, t, n));
1024
+ return () => r.value.map((e, t) => e.type === "tag" ? ie("span", {
986
1025
  key: t,
987
1026
  class: "tpl-merge-tag-label"
988
1027
  }, e.value) : e.value);
989
1028
  }
990
- }), Pn = { class: "tpl:text-center" }, Fn = ["href"], In = /* @__PURE__ */ y({
1029
+ }), In = { class: "tpl:text-center" }, Ln = ["href"], Rn = /* @__PURE__ */ y({
991
1030
  __name: "ButtonBlock",
992
1031
  props: {
993
1032
  block: {},
994
1033
  viewport: {}
995
1034
  },
996
1035
  setup(e) {
997
- let t = e, n = j(() => {
1036
+ let t = e, n = M(() => {
998
1037
  let e = {
999
1038
  display: "inline-block",
1000
1039
  padding: `${t.block.buttonPadding.top}px ${t.block.buttonPadding.right}px ${t.block.buttonPadding.bottom}px ${t.block.buttonPadding.left}px`,
@@ -1008,17 +1047,17 @@ var Nn = y({
1008
1047
  };
1009
1048
  return t.block.fontFamily && (e.fontFamily = t.block.fontFamily), t.block.width === "full" ? (e.display = "block", e.width = "100%", e.boxSizing = "border-box") : typeof t.block.width == "number" && (e.width = `${t.block.width}px`, e.boxSizing = "border-box"), e;
1010
1049
  });
1011
- return (t, r) => (f(), x("div", Pn, [b("a", {
1050
+ return (t, r) => (f(), x("div", In, [b("a", {
1012
1051
  href: e.block.url || "#",
1013
1052
  style: i(n.value),
1014
1053
  class: "tpl:cursor-default",
1015
- onClick: r[0] ||= P(() => {}, ["prevent"])
1016
- }, [w(Nn, { text: e.block.text }, null, 8, ["text"])], 12, Fn)]));
1054
+ onClick: r[0] ||= F(() => {}, ["prevent"])
1055
+ }, [w(Fn, { text: e.block.text }, null, 8, ["text"])], 12, Ln)]));
1017
1056
  }
1018
- }), Ln = F("bookmark", [["path", {
1057
+ }), zn = I("bookmark", [["path", {
1019
1058
  d: "M17 3a2 2 0 0 1 2 2v15a1 1 0 0 1-1.496.868l-4.512-2.578a2 2 0 0 0-1.984 0l-4.512 2.578A1 1 0 0 1 5 20V5a2 2 0 0 1 2-2z",
1020
1059
  key: "oz39mx"
1021
- }]]), Rn = F("box", [
1060
+ }]]), Bn = I("box", [
1022
1061
  ["path", {
1023
1062
  d: "M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",
1024
1063
  key: "hh9hay"
@@ -1031,13 +1070,13 @@ var Nn = y({
1031
1070
  d: "M12 22V12",
1032
1071
  key: "d0xqtd"
1033
1072
  }]
1034
- ]), zn = F("code", [["path", {
1073
+ ]), Vn = I("code", [["path", {
1035
1074
  d: "m16 18 6-6-6-6",
1036
1075
  key: "eg8j8"
1037
1076
  }], ["path", {
1038
1077
  d: "m8 6-6 6 6 6",
1039
1078
  key: "ppft3o"
1040
- }]]), Bn = F("copy", [["rect", {
1079
+ }]]), Hn = I("copy", [["rect", {
1041
1080
  width: "14",
1042
1081
  height: "14",
1043
1082
  x: "8",
@@ -1048,7 +1087,7 @@ var Nn = y({
1048
1087
  }], ["path", {
1049
1088
  d: "M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",
1050
1089
  key: "zix9uf"
1051
- }]]), Vn = F("eye-off", [
1090
+ }]]), Un = I("eye-off", [
1052
1091
  ["path", {
1053
1092
  d: "M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",
1054
1093
  key: "ct8e1f"
@@ -1065,10 +1104,10 @@ var Nn = y({
1065
1104
  d: "m2 2 20 20",
1066
1105
  key: "1ooewy"
1067
1106
  }]
1068
- ]), Hn = F("funnel", [["path", {
1107
+ ]), Wn = I("funnel", [["path", {
1069
1108
  d: "M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",
1070
1109
  key: "sc7q7i"
1071
- }]]), Un = F("grip-vertical", [
1110
+ }]]), Gn = I("grip-vertical", [
1072
1111
  ["circle", {
1073
1112
  cx: "9",
1074
1113
  cy: "12",
@@ -1105,7 +1144,7 @@ var Nn = y({
1105
1144
  r: "1",
1106
1145
  key: "f4zoj3"
1107
1146
  }]
1108
- ]), Wn = F("image", [
1147
+ ]), Kn = I("image", [
1109
1148
  ["rect", {
1110
1149
  width: "18",
1111
1150
  height: "18",
@@ -1125,13 +1164,13 @@ var Nn = y({
1125
1164
  d: "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",
1126
1165
  key: "1xmnt7"
1127
1166
  }]
1128
- ]), Gn = F("navigation", [["polygon", {
1167
+ ]), qn = I("navigation", [["polygon", {
1129
1168
  points: "3 11 22 2 13 21 11 13 3 11",
1130
1169
  key: "1ltx0t"
1131
- }]]), Kn = F("puzzle", [["path", {
1170
+ }]]), Jn = I("puzzle", [["path", {
1132
1171
  d: "M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",
1133
1172
  key: "w46dr5"
1134
- }]]), qn = F("share-2", [
1173
+ }]]), Yn = I("share-2", [
1135
1174
  ["circle", {
1136
1175
  cx: "18",
1137
1176
  cy: "5",
@@ -1164,7 +1203,7 @@ var Nn = y({
1164
1203
  y2: "10.49",
1165
1204
  key: "1n3mei"
1166
1205
  }]
1167
- ]), Jn = F("table", [
1206
+ ]), Xn = I("table", [
1168
1207
  ["path", {
1169
1208
  d: "M12 3v18",
1170
1209
  key: "108xh3"
@@ -1185,7 +1224,7 @@ var Nn = y({
1185
1224
  d: "M3 15h18",
1186
1225
  key: "5xshup"
1187
1226
  }]
1188
- ]), Yn = F("video", [["path", {
1227
+ ]), Zn = I("video", [["path", {
1189
1228
  d: "m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",
1190
1229
  key: "ftymec"
1191
1230
  }], ["rect", {
@@ -1195,18 +1234,18 @@ var Nn = y({
1195
1234
  height: "12",
1196
1235
  rx: "2",
1197
1236
  key: "158x01"
1198
- }]]), Xn = ["innerHTML"], Zn = [
1237
+ }]]), Qn = ["innerHTML"], $n = [
1199
1238
  "src",
1200
1239
  "width",
1201
1240
  "height"
1202
- ], Qn = /* @__PURE__ */ y({
1241
+ ], er = /* @__PURE__ */ y({
1203
1242
  __name: "CustomBlockIcon",
1204
1243
  props: {
1205
1244
  icon: {},
1206
1245
  size: {}
1207
1246
  },
1208
1247
  setup(e) {
1209
- let t = e, n = j(() => t.size ?? 20), r = j(() => t.icon && (t.icon.trimStart().startsWith("<svg") || t.icon.trimStart().startsWith("<SVG"))), a = j(() => t.icon && !r.value && (t.icon.startsWith("http") || t.icon.startsWith("/")));
1248
+ let t = e, n = M(() => t.size ?? 20), r = M(() => t.icon && (t.icon.trimStart().startsWith("<svg") || t.icon.trimStart().startsWith("<SVG"))), a = M(() => t.icon && !r.value && (t.icon.startsWith("http") || t.icon.startsWith("/")));
1210
1249
  return (t, o) => r.value ? (f(), x("span", {
1211
1250
  key: 0,
1212
1251
  class: "tpl:inline-flex tpl:items-center tpl:justify-center",
@@ -1215,14 +1254,14 @@ var Nn = y({
1215
1254
  height: `${n.value}px`
1216
1255
  }),
1217
1256
  innerHTML: e.icon
1218
- }, null, 12, Xn)) : a.value ? (f(), x("img", {
1257
+ }, null, 12, Qn)) : a.value ? (f(), x("img", {
1219
1258
  key: 1,
1220
1259
  src: e.icon,
1221
1260
  width: n.value,
1222
1261
  height: n.value,
1223
1262
  class: "tpl:inline-block",
1224
1263
  alt: ""
1225
- }, null, 8, Zn)) : (f(), D(k(Rn), {
1264
+ }, null, 8, $n)) : (f(), D(k(Bn), {
1226
1265
  key: 2,
1227
1266
  size: n.value,
1228
1267
  "stroke-width": 1.5
@@ -1231,16 +1270,16 @@ var Nn = y({
1231
1270
  });
1232
1271
  //#endregion
1233
1272
  //#region src/composables/useEditorRoot.ts
1234
- function $n() {
1235
- return N(yt, document) ?? document;
1273
+ function tr() {
1274
+ return P(yt, document) ?? document;
1236
1275
  }
1237
1276
  //#endregion
1238
1277
  //#region src/composables/useFocusTrap.ts
1239
- var er = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
1240
- function tr(e, t) {
1241
- let n = $n(), r = null, i = null, a = null;
1278
+ var nr = "a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex=\"-1\"])";
1279
+ function rr(e, t) {
1280
+ let n = tr(), r = null, i = null, a = null;
1242
1281
  function o() {
1243
- return e.value ? Array.from(e.value.querySelectorAll(er)).filter((e) => e.offsetParent !== null) : [];
1282
+ return e.value ? Array.from(e.value.querySelectorAll(nr)).filter((e) => e.offsetParent !== null) : [];
1244
1283
  }
1245
1284
  function s(e) {
1246
1285
  if (e.key !== "Tab") return;
@@ -1270,8 +1309,8 @@ function tr(e, t) {
1270
1309
  }
1271
1310
  //#endregion
1272
1311
  //#region src/composables/useEmoji.ts
1273
- function nr() {
1274
- let [e, t] = Ge(!1), n = v([]), r = !1;
1312
+ function ir() {
1313
+ let [e, t] = We(!1), n = v([]), r = !1;
1275
1314
  u(() => {
1276
1315
  r = !0;
1277
1316
  }), c(e, async (e) => {
@@ -1296,7 +1335,7 @@ function nr() {
1296
1335
  }
1297
1336
  //#endregion
1298
1337
  //#region src/composables/useDragDrop.ts
1299
- function rr(e) {
1338
+ function ar(e) {
1300
1339
  let { onBlockMove: t, onBlockAdd: n } = e, r = _(!1), i = _(null), a = _(null);
1301
1340
  function o(e) {
1302
1341
  r.value = !0, i.value = e;
@@ -1346,7 +1385,7 @@ function rr(e) {
1346
1385
  }
1347
1386
  //#endregion
1348
1387
  //#region src/composables/useFonts.ts
1349
- var ir = [
1388
+ var or = [
1350
1389
  {
1351
1390
  value: "Arial",
1352
1391
  label: "Arial"
@@ -1375,7 +1414,7 @@ var ir = [
1375
1414
  value: "Courier New",
1376
1415
  label: "Courier New"
1377
1416
  }
1378
- ], ar = {
1417
+ ], sr = {
1379
1418
  arial: "Arial, sans-serif",
1380
1419
  helvetica: "Helvetica, sans-serif",
1381
1420
  georgia: "Georgia, serif",
@@ -1383,27 +1422,27 @@ var ir = [
1383
1422
  verdana: "Verdana, sans-serif",
1384
1423
  "trebuchet ms": "'Trebuchet MS', sans-serif",
1385
1424
  "courier new": "'Courier New', monospace"
1386
- }, or = "Arial, sans-serif";
1387
- function sr(e) {
1388
- if (e === void 0 || e === !0) return [...ir];
1425
+ }, cr = "Arial, sans-serif";
1426
+ function lr(e) {
1427
+ if (e === void 0 || e === !0) return [...or];
1389
1428
  if (e === !1) return [];
1390
1429
  let t = [], n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set();
1391
1430
  for (let i of e) {
1392
- let e = i.toLowerCase(), a = ir.find((t) => t.value.toLowerCase() === e);
1431
+ let e = i.toLowerCase(), a = or.find((t) => t.value.toLowerCase() === e);
1393
1432
  if (!a) {
1394
- r.has(e) || (r.add(e), bn.warn(`config.fonts.builtIns: "${i}" is not a built-in font — skipping it. Built-in fonts are: ${ir.map((e) => e.value).join(", ")}.`));
1433
+ r.has(e) || (r.add(e), bn.warn(`config.fonts.builtIns: "${i}" is not a built-in font — skipping it. Built-in fonts are: ${or.map((e) => e.value).join(", ")}.`));
1395
1434
  continue;
1396
1435
  }
1397
1436
  n.has(a.value) || (n.add(a.value), t.push(a));
1398
1437
  }
1399
1438
  return t;
1400
1439
  }
1401
- function cr(e) {
1402
- let t = _(e?.customFonts ?? []), n = _(!0), r = _(!1), i = sr(e?.builtIns), a = j(() => e?.defaultFallback ?? or);
1440
+ function ur(e) {
1441
+ let t = _(e?.customFonts ?? []), n = _(!0), r = _(!1), i = lr(e?.builtIns), a = M(() => e?.defaultFallback ?? cr);
1403
1442
  function o(e) {
1404
1443
  n.value = e;
1405
1444
  }
1406
- let c = j(() => {
1445
+ let c = M(() => {
1407
1446
  let e = [...i];
1408
1447
  if (!n.value) return e.sort((e, t) => e.label.localeCompare(t.label));
1409
1448
  let r = t.value.map((e) => ({
@@ -1416,22 +1455,22 @@ function cr(e) {
1416
1455
  function l(e) {
1417
1456
  return c.value.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
1418
1457
  }
1419
- let d = e?.defaultFont ?? or.split(",")[0].trim();
1458
+ let d = e?.defaultFont ?? cr.split(",")[0].trim();
1420
1459
  l(d) || bn.warn(`config.fonts: new templates seed "${d}", which the font picker doesn't offer — authors can't reselect it. Either add it to fonts.builtIns, or set fonts.defaultFont to an offered font.`);
1421
1460
  function f(e) {
1422
- return ir.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
1461
+ return or.some((t) => t.label.toLowerCase() === e.toLowerCase() || t.value.toLowerCase().startsWith(e.toLowerCase()));
1423
1462
  }
1424
1463
  function p() {
1425
1464
  if (e?.defaultFont) {
1426
- if (!n.value && !f(e.defaultFont)) return or;
1465
+ if (!n.value && !f(e.defaultFont)) return cr;
1427
1466
  if (l(e.defaultFont)) {
1428
1467
  let t = c.value.find((t) => t.label.toLowerCase() === e.defaultFont.toLowerCase() || t.value.toLowerCase().startsWith(e.defaultFont.toLowerCase()));
1429
1468
  if (t) return t.value;
1430
1469
  }
1431
1470
  }
1432
- return or;
1471
+ return cr;
1433
1472
  }
1434
- let m = j(() => p());
1473
+ let m = M(() => p());
1435
1474
  function h(e) {
1436
1475
  if (!e) return a.value;
1437
1476
  let n = t.value.find((t) => t.name.toLowerCase() === e.toLowerCase());
@@ -1439,7 +1478,7 @@ function cr(e) {
1439
1478
  let e = n.fallback ?? a.value;
1440
1479
  return `'${n.name}', ${e}`;
1441
1480
  }
1442
- return ar[e.toLowerCase()] || (e.includes(",") ? e : `${e}, ${a.value}`);
1481
+ return sr[e.toLowerCase()] || (e.includes(",") ? e : `${e}, ${a.value}`);
1443
1482
  }
1444
1483
  let g = [], v = !1;
1445
1484
  async function y() {
@@ -1482,8 +1521,8 @@ function cr(e) {
1482
1521
  }
1483
1522
  //#endregion
1484
1523
  //#region src/composables/useLogicTag.ts
1485
- function lr() {
1486
- let e = N(rt, []), t = N(ft, []), n = N(ut, Se.liquid), r = N(Ct, null), i = N(jt, null), a = _(!1), o = !!r || e.length > 0 || t.length > 0, s = e.length > 0 || t.length > 0;
1524
+ function dr() {
1525
+ let e = P(rt, []), t = P(ft, []), n = P(ut, xe.liquid), r = P(Ct, null), i = P(jt, null), a = _(!1), o = !!r || e.length > 0 || t.length > 0, s = e.length > 0 || t.length > 0;
1487
1526
  async function c() {
1488
1527
  if (r) {
1489
1528
  a.value = !0;
@@ -1514,12 +1553,12 @@ function lr() {
1514
1553
  }
1515
1554
  //#endregion
1516
1555
  //#region src/utils/mergeTagNodeSpec.ts
1517
- function ur(e, t, n) {
1518
- return Ae(e, n) ? {
1556
+ function fr(e, t, n) {
1557
+ return ke(e, n) ? {
1519
1558
  type: "logicMergeTagNode",
1520
1559
  attrs: {
1521
1560
  value: e,
1522
- keyword: pe(e, n)
1561
+ keyword: fe(e, n)
1523
1562
  }
1524
1563
  } : {
1525
1564
  type: "mergeTagNode",
@@ -1531,15 +1570,15 @@ function ur(e, t, n) {
1531
1570
  }
1532
1571
  //#endregion
1533
1572
  //#region src/utils/insertLogicTag.ts
1534
- function dr(e) {
1573
+ function pr(e) {
1535
1574
  return "before" in e && "after" in e;
1536
1575
  }
1537
- function fr(e, t, n) {
1538
- if (!dr(t)) {
1539
- e.chain().focus().insertContent(ur(t.value, t.label, n)).run();
1576
+ function mr(e, t, n) {
1577
+ if (!pr(t)) {
1578
+ e.chain().focus().insertContent(fr(t.value, t.label, n)).run();
1540
1579
  return;
1541
1580
  }
1542
- let r = ur(t.before, t.label, n), i = ur(t.after, t.label, n), { from: a, to: o } = e.state.selection;
1581
+ let r = fr(t.before, t.label, n), i = fr(t.after, t.label, n), { from: a, to: o } = e.state.selection;
1543
1582
  if (a !== o) {
1544
1583
  e.chain().focus().insertContentAt(o, i).insertContentAt(a, r).run();
1545
1584
  return;
@@ -1548,20 +1587,20 @@ function fr(e, t, n) {
1548
1587
  }
1549
1588
  //#endregion
1550
1589
  //#region src/utils/linkColorExtension.ts
1551
- function pr(e) {
1590
+ function hr(e) {
1552
1591
  if (!e) return null;
1553
1592
  let t = e.trim();
1554
1593
  return /^#[0-9a-f]{3,8}$/i.test(t) || /^(rgb|rgba|hsl|hsla)\(\s*[0-9.,%/\s]+\)$/i.test(t) || /^[a-z]+$/i.test(t) ? t : null;
1555
1594
  }
1556
- function mr(e) {
1595
+ function gr(e) {
1557
1596
  return e.extend({ addAttributes() {
1558
1597
  return {
1559
1598
  ...this.parent?.(),
1560
1599
  color: {
1561
1600
  default: null,
1562
- parseHTML: (e) => pr(Ye(e.style.color)),
1601
+ parseHTML: (e) => hr(Ye(e.style.color)),
1563
1602
  renderHTML: (e) => {
1564
- let t = pr(e.color);
1603
+ let t = hr(e.color);
1565
1604
  return t ? { style: `color: ${t}` } : {};
1566
1605
  }
1567
1606
  }
@@ -1570,9 +1609,9 @@ function mr(e) {
1570
1609
  }
1571
1610
  //#endregion
1572
1611
  //#region src/composables/useRichTextLinkDialog.ts
1573
- function hr(e) {
1612
+ function _r(e) {
1574
1613
  let t = _(!1), n = _(""), r = _(""), i = _(null);
1575
- tr(i, t);
1614
+ rr(i, t);
1576
1615
  function a() {
1577
1616
  let i = e.value?.getAttributes("link") ?? {};
1578
1617
  n.value = i.href || "", r.value = i.color || "", t.value = !0;
@@ -1581,7 +1620,7 @@ function hr(e) {
1581
1620
  if (n.value) {
1582
1621
  let t = c(n.value);
1583
1622
  if (t !== null) {
1584
- let n = pr(r.value), i = e.value?.chain().focus().extendMarkRange("link").setLink({ href: t }).updateAttributes("link", { color: n });
1623
+ let n = hr(r.value), i = e.value?.chain().focus().extendMarkRange("link").setLink({ href: t }).updateAttributes("link", { color: n });
1585
1624
  n && typeof e.value?.commands.unsetColor == "function" && i?.unsetColor(), i?.run();
1586
1625
  }
1587
1626
  }
@@ -1628,10 +1667,10 @@ function hr(e) {
1628
1667
  }
1629
1668
  //#endregion
1630
1669
  //#region src/composables/useRichTextEditor.ts
1631
- function gr(e) {
1632
- let t = N(bt, null), { mergeTags: n, canRequestMergeTag: r, isRequesting: i, requestMergeTag: a, syntax: o, autocomplete: s } = Ht(), { canInsertLogicTag: l, isRequesting: u, requestLogicTag: d } = lr(), f = N(dt, null), p = (g(f) ? f.value : f)?.mergeTag?.suggestionEmpty ?? "No matching merge tags", m = je(o), y = v(null), { showLinkDialog: b, linkUrl: x, linkColor: S, linkDialogRef: C, openLinkDialog: w, insertLink: T, removeLink: E, closeLinkDialog: D, handleLinkKeydown: O } = hr(y), { start: k, stop: ee } = Ke(() => y.value?.commands.focus("end"), 0, { immediate: !1 }), A = v(null), te = _(!0), j = _(null), ne = !1;
1633
- async function M() {
1634
- j.value = null, te.value = !0;
1670
+ function vr(e) {
1671
+ let t = P(bt, null), { mergeTags: n, canRequestMergeTag: r, isRequesting: i, requestMergeTag: a, syntax: o, autocomplete: s } = Ht(), { canInsertLogicTag: l, isRequesting: u, requestLogicTag: d } = dr(), f = P(dt, null), p = (g(f) ? f.value : f)?.mergeTag?.suggestionEmpty ?? "No matching merge tags", m = Ae(o), y = v(null), { showLinkDialog: b, linkUrl: x, linkColor: S, linkDialogRef: C, openLinkDialog: w, insertLink: T, removeLink: E, closeLinkDialog: D, handleLinkKeydown: O } = _r(y), { start: k, stop: A } = Ge(() => y.value?.commands.focus("end"), 0, { immediate: !1 }), j = v(null), ee = _(!0), M = _(null), te = !1;
1672
+ async function N() {
1673
+ M.value = null, ee.value = !0;
1635
1674
  try {
1636
1675
  let { TiptapEditor: r, EC: i, extensions: a } = await e.loadExtensions({
1637
1676
  mergeTags: n,
@@ -1640,8 +1679,8 @@ function gr(e) {
1640
1679
  autocompleteEnabled: s,
1641
1680
  suggestionEmptyText: p
1642
1681
  });
1643
- if (ne) return;
1644
- A.value = i;
1682
+ if (te) return;
1683
+ j.value = i;
1645
1684
  let c = /* @__PURE__ */ new Map();
1646
1685
  a.forEach((e, t) => c.set(e.name, t));
1647
1686
  let l = new r({
@@ -1649,27 +1688,27 @@ function gr(e) {
1649
1688
  content: e.blockContent(),
1650
1689
  editable: !0,
1651
1690
  onUpdate: ({ editor: n }) => {
1652
- ne || t && t.updateBlock(e.blockId(), { content: n.getHTML() });
1691
+ te || t && t.updateBlock(e.blockId(), { content: n.getHTML() });
1653
1692
  }
1654
1693
  });
1655
- if (ne) {
1694
+ if (te) {
1656
1695
  l.destroy();
1657
1696
  return;
1658
1697
  }
1659
- y.value = l, te.value = !1, k();
1698
+ y.value = l, ee.value = !1, k();
1660
1699
  } catch (t) {
1661
- if (ne) return;
1662
- bn.error(`[${e.editorName ?? "RichTextEditor"}] Failed to initialize TipTap editor:`, t), j.value = t instanceof Error ? t.message : "Failed to load editor", te.value = !1;
1700
+ if (te) return;
1701
+ bn.error(`[${e.editorName ?? "RichTextEditor"}] Failed to initialize TipTap editor:`, t), M.value = t instanceof Error ? t.message : "Failed to load editor", ee.value = !1;
1663
1702
  }
1664
1703
  }
1665
- function re() {
1666
- y.value?.destroy(), y.value = null, M();
1704
+ function ne() {
1705
+ y.value?.destroy(), y.value = null, N();
1667
1706
  }
1668
- M();
1669
- let ie = c(() => e.blockContent(), (e) => {
1707
+ N();
1708
+ let re = c(() => e.blockContent(), (e) => {
1670
1709
  y.value && y.value.getHTML() !== e && y.value.commands.setContent(e, { emitUpdate: !1 });
1671
1710
  });
1672
- function ae(t) {
1711
+ function ie(t) {
1673
1712
  if (i.value || u.value) return;
1674
1713
  let n = t.composedPath(), r = n.find((e) => e instanceof HTMLElement);
1675
1714
  if (!r) return;
@@ -1677,26 +1716,26 @@ function gr(e) {
1677
1716
  let a = n.some((e) => e instanceof HTMLElement && e.classList.contains("tpl-color-popover"));
1678
1717
  r.closest(".tpl-text-editor-wrapper") || r.closest(".tpl-text-toolbar") || r.closest(".tpl-link-dialog") || a || e.onDone();
1679
1718
  }
1680
- et(document, "mousedown", ae), h(() => {
1681
- ne = !0, ie(), ee(), y.value?.destroy();
1719
+ et(document, "mousedown", ie), h(() => {
1720
+ te = !0, re(), A(), y.value?.destroy();
1682
1721
  });
1683
- async function oe() {
1722
+ async function ae() {
1684
1723
  let e = await a();
1685
- ne || (e && y.value ? y.value.chain().focus().insertMergeTag({
1724
+ te || (e && y.value ? y.value.chain().focus().insertMergeTag({
1686
1725
  label: e.label,
1687
1726
  value: e.value
1688
1727
  }).run() : y.value?.commands.focus());
1689
1728
  }
1690
- async function P() {
1729
+ async function F() {
1691
1730
  let e = await d();
1692
- ne || (e && y.value ? fr(y.value, e, o) : y.value?.commands.focus());
1731
+ te || (e && y.value ? mr(y.value, e, o) : y.value?.commands.focus());
1693
1732
  }
1694
1733
  return {
1695
1734
  editor: y,
1696
- EditorContent: A,
1697
- isLoading: te,
1698
- initError: j,
1699
- retry: re,
1735
+ EditorContent: j,
1736
+ isLoading: ee,
1737
+ initError: M,
1738
+ retry: ne,
1700
1739
  showLinkDialog: b,
1701
1740
  linkUrl: x,
1702
1741
  linkColor: S,
@@ -1712,36 +1751,36 @@ function gr(e) {
1712
1751
  removeLink: E,
1713
1752
  closeLinkDialog: D,
1714
1753
  handleLinkKeydown: O,
1715
- handleAddMergeTag: oe,
1716
- handleAddLogicTag: P
1754
+ handleAddMergeTag: ae,
1755
+ handleAddLogicTag: F
1717
1756
  };
1718
1757
  }
1719
1758
  //#endregion
1720
1759
  //#region src/composables/useSmallScreenNotice.ts
1721
- var _r = "(max-width: 767px)";
1722
- function vr(e) {
1723
- let t = Je(_r);
1760
+ var yr = "(max-width: 767px)";
1761
+ function br(e) {
1762
+ let t = Je(yr);
1724
1763
  return {
1725
1764
  isSmallScreen: t,
1726
- showNotice: j(() => (S(e) ?? !0) && t.value)
1765
+ showNotice: M(() => (S(e) ?? !0) && t.value)
1727
1766
  };
1728
1767
  }
1729
1768
  //#endregion
1730
1769
  //#region src/components/blocks/CustomBlock.vue?vue&type=script&setup=true&lang.ts
1731
- var yr = { class: "tpl:w-full" }, br = {
1770
+ var xr = { class: "tpl:w-full" }, Sr = {
1732
1771
  key: 0,
1733
1772
  class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-warning)] tpl:bg-[var(--tpl-warning-light)]"
1734
- }, xr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Sr = {
1773
+ }, Cr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, wr = {
1735
1774
  key: 1,
1736
1775
  class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-danger)] tpl:bg-[var(--tpl-danger-light)]"
1737
- }, Cr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, wr = {
1776
+ }, Tr = { class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Er = {
1738
1777
  key: 2,
1739
1778
  class: "tpl:relative"
1740
- }, Tr = ["innerHTML"], Er = {
1779
+ }, Dr = ["innerHTML"], Or = {
1741
1780
  key: 0,
1742
1781
  class: "tpl:absolute tpl:inset-0 tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-3 tpl:rounded tpl:backdrop-blur-[2px]",
1743
1782
  style: { "background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)" }
1744
- }, Dr = /* @__PURE__ */ y({
1783
+ }, kr = /* @__PURE__ */ y({
1745
1784
  __name: "CustomBlock",
1746
1785
  props: {
1747
1786
  block: {},
@@ -1749,9 +1788,9 @@ var yr = { class: "tpl:w-full" }, br = {
1749
1788
  },
1750
1789
  emits: ["fetchData"],
1751
1790
  setup(e, { emit: t }) {
1752
- let n = e, r = t, { t: i } = Ft(), o = N(Dt, null), s = _(""), l = _(!1), u = j(() => o?.getDefinition(n.block.customType)), d = j(() => !!u.value), { isFetching: m, fetch: h, needsFetch: g, hasDataSource: v } = en({
1791
+ let n = e, r = t, { t: i } = Ft(), o = P(Dt, null), s = _(""), l = _(!1), u = M(() => o?.getDefinition(n.block.customType)), d = M(() => !!u.value), { isFetching: m, fetch: h, needsFetch: g, hasDataSource: v } = en({
1753
1792
  definition: u,
1754
- block: j(() => n.block),
1793
+ block: M(() => n.block),
1755
1794
  onUpdate: (e, t) => {
1756
1795
  r("fetchData", {
1757
1796
  fieldValues: e,
@@ -1770,65 +1809,65 @@ var yr = { class: "tpl:w-full" }, br = {
1770
1809
  }
1771
1810
  }
1772
1811
  }
1773
- let S = Ue(y, 150);
1812
+ let S = He(y, 150);
1774
1813
  return a(() => {
1775
1814
  y();
1776
1815
  }), c(() => n.block.fieldValues, () => {
1777
1816
  S();
1778
- }, { deep: !0 }), (e, t) => (f(), x("div", yr, [d.value ? l.value ? (f(), x("div", Sr, [w(k(zt), {
1817
+ }, { deep: !0 }), (e, t) => (f(), x("div", xr, [d.value ? l.value ? (f(), x("div", wr, [w(k(zt), {
1779
1818
  size: 24,
1780
1819
  class: "tpl:text-[var(--tpl-danger)]"
1781
- }), b("span", Cr, p(k(i).customBlocks.renderError), 1)])) : (f(), x("div", wr, [b("div", { innerHTML: s.value }, null, 8, Tr), k(v) && k(g) ? (f(), x("div", Er, [k(m) ? (f(), D(Bt, {
1820
+ }), b("span", Tr, p(k(i).customBlocks.renderError), 1)])) : (f(), x("div", Er, [b("div", { innerHTML: s.value }, null, 8, Dr), k(v) && k(g) ? (f(), x("div", Or, [k(m) ? (f(), D(Bt, {
1782
1821
  key: 1,
1783
1822
  class: "tpl:w-48"
1784
1823
  })) : (f(), x("button", {
1785
1824
  key: 0,
1786
1825
  type: "button",
1787
1826
  class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-2 tpl:text-sm tpl:font-semibold tpl:shadow-sm tpl:transition-all tpl:duration-150 hover:tpl:border-[var(--tpl-primary)] hover:tpl:shadow-md tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
1788
- onClick: t[0] ||= P((...e) => k(h) && k(h)(...e), ["stop"])
1789
- }, [u.value?.icon ? (f(), D(Qn, {
1827
+ onClick: t[0] ||= F((...e) => k(h) && k(h)(...e), ["stop"])
1828
+ }, [u.value?.icon ? (f(), D(er, {
1790
1829
  key: 0,
1791
1830
  icon: u.value.icon,
1792
1831
  size: 16
1793
- }, null, 8, ["icon"])) : M("", !0), O(" " + p(u.value?.dataSource?.label || k(i).customBlocks.dataSource.fetchButton), 1)]))])) : M("", !0)])) : (f(), x("div", br, [w(k(Kn), {
1832
+ }, null, 8, ["icon"])) : N("", !0), O(" " + p(u.value?.dataSource?.label || k(i).customBlocks.dataSource.fetchButton), 1)]))])) : N("", !0)])) : (f(), x("div", Sr, [w(k(Jn), {
1794
1833
  size: 24,
1795
1834
  class: "tpl:text-[var(--tpl-warning)]"
1796
- }), b("span", xr, p(k(i).customBlocks.definitionNotFound), 1)]))]));
1835
+ }), b("span", Cr, p(k(i).customBlocks.definitionNotFound), 1)]))]));
1797
1836
  }
1798
- }), Or = { class: "tpl:w-full" }, kr = /* @__PURE__ */ y({
1837
+ }), Ar = { class: "tpl:w-full" }, jr = /* @__PURE__ */ y({
1799
1838
  __name: "DividerBlock",
1800
1839
  props: {
1801
1840
  block: {},
1802
1841
  viewport: {}
1803
1842
  },
1804
1843
  setup(e) {
1805
- let t = e, n = j(() => ({
1844
+ let t = e, n = M(() => ({
1806
1845
  borderTop: `${t.block.thickness}px ${t.block.lineStyle} ${t.block.color}`,
1807
1846
  width: t.block.width === "full" ? "100%" : `${t.block.width}px`,
1808
1847
  margin: t.block.width === "full" ? "0" : "0 auto"
1809
1848
  }));
1810
- return (e, t) => (f(), x("div", Or, [b("hr", {
1849
+ return (e, t) => (f(), x("div", Ar, [b("hr", {
1811
1850
  class: "tpl:m-0 tpl:border-none",
1812
1851
  style: i(n.value)
1813
1852
  }, null, 4)]));
1814
1853
  }
1815
- }), Ar = { class: "tpl:w-full" }, jr = ["srcdoc", "title"], Mr = {
1854
+ }), Mr = { class: "tpl:w-full" }, Nr = ["srcdoc", "title"], Pr = {
1816
1855
  key: 1,
1817
1856
  class: "tpl:flex tpl:min-h-[80px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)]"
1818
- }, Nr = {
1857
+ }, Fr = {
1819
1858
  key: 0,
1820
1859
  class: "tpl:text-sm tpl:text-[var(--tpl-text-muted)]"
1821
- }, Pr = {
1860
+ }, Ir = {
1822
1861
  key: 1,
1823
1862
  class: "tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
1824
- }, Fr = /* @__PURE__ */ y({
1863
+ }, Lr = /* @__PURE__ */ y({
1825
1864
  __name: "HtmlBlock",
1826
1865
  props: {
1827
1866
  block: {},
1828
1867
  viewport: {}
1829
1868
  },
1830
1869
  setup(e) {
1831
- let t = e, { t: n } = Ft(), r = N(Nt, !1), a = j(() => t.block.content.trim().length > 0), o = j(() => r && a.value), s = _(null), l = _(60), u = null;
1870
+ let t = e, { t: n } = Ft(), r = P(Nt, !1), a = M(() => t.block.content.trim().length > 0), o = M(() => r && a.value), s = _(null), l = _(60), u = null;
1832
1871
  function d() {
1833
1872
  let e = s.value?.contentDocument;
1834
1873
  e && (l.value = Math.max(e.body?.scrollHeight ?? 0, e.documentElement?.scrollHeight ?? 0));
@@ -1842,7 +1881,7 @@ var yr = { class: "tpl:w-full" }, br = {
1842
1881
  e || (u?.disconnect(), u = null);
1843
1882
  }), h(() => {
1844
1883
  u?.disconnect(), u = null;
1845
- }), (t, r) => (f(), x("div", Ar, [o.value ? (f(), x("iframe", {
1884
+ }), (t, r) => (f(), x("div", Mr, [o.value ? (f(), x("iframe", {
1846
1885
  key: 0,
1847
1886
  ref_key: "iframeRef",
1848
1887
  ref: s,
@@ -1852,36 +1891,36 @@ var yr = { class: "tpl:w-full" }, br = {
1852
1891
  class: "tpl:block tpl:w-full tpl:border-0",
1853
1892
  style: i({ height: `${l.value}px` }),
1854
1893
  onLoad: m
1855
- }, null, 44, jr)) : (f(), x("div", Mr, [w(k(zn), {
1894
+ }, null, 44, Nr)) : (f(), x("div", Pr, [w(k(Vn), {
1856
1895
  size: 24,
1857
1896
  class: "tpl:text-[var(--tpl-text-dim)]"
1858
- }), a.value ? (f(), x("span", Nr, p(k(n).html.preview), 1)) : (f(), x("span", Pr, p(k(n).html.empty), 1))]))]));
1897
+ }), a.value ? (f(), x("span", Fr, p(k(n).html.preview), 1)) : (f(), x("span", Ir, p(k(n).html.empty), 1))]))]));
1859
1898
  }
1860
- }), Ir = "image/";
1861
- function Lr(e) {
1899
+ }), Rr = "image/";
1900
+ function zr(e) {
1862
1901
  let { target: t, onFiles: n, enabled: r } = e, i = () => r === void 0 || S(r), { isOverDropZone: a } = qe(t, {
1863
1902
  preventDefaultForUnhandled: !0,
1864
1903
  onDrop: (e) => {
1865
1904
  if (!i()) return;
1866
- let t = (e ?? []).filter((e) => e.type.startsWith(Ir));
1905
+ let t = (e ?? []).filter((e) => e.type.startsWith(Rr));
1867
1906
  t.length > 0 && n([t[0]]);
1868
1907
  }
1869
1908
  });
1870
- return { isOver: j(() => i() && a.value) };
1909
+ return { isOver: M(() => i() && a.value) };
1871
1910
  }
1872
1911
  //#endregion
1873
1912
  //#region src/components/blocks/ImageBlock.vue?vue&type=script&setup=true&lang.ts
1874
- var Rr = {
1913
+ var Br = {
1875
1914
  key: 0,
1876
1915
  class: "tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-10 tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-xs tpl:font-medium tpl:border-[var(--tpl-primary)] tpl:text-[var(--tpl-primary)]",
1877
1916
  style: { "background-color": "color-mix(in srgb, var(--tpl-bg) 85%, transparent)" }
1878
- }, zr = ["href"], Br = ["src", "alt"], Vr = ["src", "alt"], Hr = {
1917
+ }, Vr = ["href"], Hr = ["src", "alt"], Ur = ["src", "alt"], Wr = {
1879
1918
  class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
1880
1919
  style: { opacity: "0.7" }
1881
- }, Ur = ["href"], Wr = ["src", "alt"], Gr = ["src", "alt"], Kr = {
1920
+ }, Gr = ["href"], Kr = ["src", "alt"], qr = ["src", "alt"], Jr = {
1882
1921
  key: 4,
1883
1922
  class: "tpl:flex tpl:min-h-[100px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
1884
- }, qr = ["aria-label"], Jr = { key: 1 }, Yr = /* @__PURE__ */ y({
1923
+ }, Yr = ["aria-label"], Xr = { key: 1 }, Zr = /* @__PURE__ */ y({
1885
1924
  __name: "ImageBlock",
1886
1925
  props: {
1887
1926
  block: {},
@@ -1889,7 +1928,7 @@ var Rr = {
1889
1928
  },
1890
1929
  emits: ["update"],
1891
1930
  setup(e, { emit: t }) {
1892
- let n = e, r = t, { t: a } = Ft(), { syntax: o } = Ht(), s = N(tt, null), c = j(() => !!s), l = Ut();
1931
+ let n = e, r = t, { t: a } = Ft(), { syntax: o } = Ht(), s = P(tt, null), c = M(() => !!s), l = Ut();
1893
1932
  async function u() {
1894
1933
  let e = await s?.({ accept: ["images"] });
1895
1934
  if (l.alive && e) {
@@ -1897,7 +1936,7 @@ var Rr = {
1897
1936
  e.alt && (t.alt = e.alt), r("update", t);
1898
1937
  }
1899
1938
  }
1900
- let d = _(), m = _(!1), h = j(() => c.value && !m.value && !C.value);
1939
+ let d = _(), m = _(!1), h = M(() => c.value && !m.value && !C.value);
1901
1940
  async function g(e) {
1902
1941
  if (s) {
1903
1942
  m.value = !0;
@@ -1916,11 +1955,11 @@ var Rr = {
1916
1955
  }
1917
1956
  }
1918
1957
  }
1919
- let { isOver: v } = Lr({
1958
+ let { isOver: v } = zr({
1920
1959
  target: d,
1921
1960
  enabled: h,
1922
1961
  onFiles: g
1923
- }), y = j(() => ({ textAlign: n.block.align })), S = j(() => {
1962
+ }), y = M(() => ({ textAlign: n.block.align })), S = M(() => {
1924
1963
  let e = n.block.align;
1925
1964
  return {
1926
1965
  maxWidth: "100%",
@@ -1929,86 +1968,86 @@ var Rr = {
1929
1968
  marginLeft: e === "center" || e === "right" ? "auto" : void 0,
1930
1969
  marginRight: e === "center" ? "auto" : void 0
1931
1970
  };
1932
- }), C = j(() => we(n.block.src, o)), T = cn(() => C.value ? void 0 : n.block.src), E = cn(() => C.value ? n.block.placeholderUrl : void 0);
1971
+ }), C = M(() => Ce(n.block.src, o)), T = cn(() => C.value ? void 0 : n.block.src), E = cn(() => C.value ? n.block.placeholderUrl : void 0);
1933
1972
  return (t, n) => (f(), x("div", {
1934
1973
  ref_key: "dropZoneRef",
1935
1974
  ref: d,
1936
1975
  "data-testid": "image-drop-zone",
1937
1976
  class: "tpl:relative tpl:w-full",
1938
1977
  style: i(y.value)
1939
- }, [h.value && (k(v) || m.value) ? (f(), x("div", Rr, [m.value ? (f(), x(A, { key: 0 }, [w(k(It), {
1978
+ }, [h.value && (k(v) || m.value) ? (f(), x("div", Br, [m.value ? (f(), x(j, { key: 0 }, [w(k(It), {
1940
1979
  class: "tpl-spinner",
1941
1980
  size: 20,
1942
1981
  "stroke-width": 2
1943
- }), O(" " + p(k(a).image.uploading), 1)], 64)) : (f(), x(A, { key: 1 }, [w(k(le), {
1982
+ }), O(" " + p(k(a).image.uploading), 1)], 64)) : (f(), x(j, { key: 1 }, [w(k(ce), {
1944
1983
  size: 20,
1945
1984
  "stroke-width": 1.5
1946
- }), O(" " + p(k(a).image.dropToUpload), 1)], 64))])) : M("", !0), e.block.src && C.value && e.block.placeholderUrl ? (f(), x(A, { key: 1 }, [e.block.linkUrl ? (f(), x("a", {
1985
+ }), O(" " + p(k(a).image.dropToUpload), 1)], 64))])) : N("", !0), e.block.src && C.value && e.block.placeholderUrl ? (f(), x(j, { key: 1 }, [e.block.linkUrl ? (f(), x("a", {
1947
1986
  key: 0,
1948
1987
  href: e.block.linkUrl,
1949
1988
  target: "_blank",
1950
1989
  rel: "noopener noreferrer",
1951
- onClick: n[0] ||= P(() => {}, ["prevent"])
1990
+ onClick: n[0] ||= F(() => {}, ["prevent"])
1952
1991
  }, [b("img", {
1953
1992
  class: "tpl:border-0",
1954
1993
  loading: "lazy",
1955
1994
  src: k(E),
1956
1995
  alt: e.block.alt || k(a).image.altTextPlaceholder,
1957
1996
  style: i(S.value)
1958
- }, null, 12, Br)], 8, zr)) : (f(), x("img", {
1997
+ }, null, 12, Hr)], 8, Vr)) : (f(), x("img", {
1959
1998
  key: 1,
1960
1999
  class: "tpl:border-0",
1961
2000
  src: k(E),
1962
2001
  alt: e.block.alt,
1963
2002
  style: i(S.value)
1964
- }, null, 12, Vr))], 64)) : e.block.src && C.value ? (f(), x("div", {
2003
+ }, null, 12, Ur))], 64)) : e.block.src && C.value ? (f(), x("div", {
1965
2004
  key: 2,
1966
2005
  class: "tpl:!flex tpl:min-h-[120px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
1967
2006
  style: i([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, S.value])
1968
- }, [w(k(Wn), {
2007
+ }, [w(k(Kn), {
1969
2008
  size: 32,
1970
2009
  "stroke-width": 1.5,
1971
2010
  class: "tpl:text-[var(--tpl-primary)]",
1972
2011
  style: { opacity: "0.5" }
1973
- }), b("span", Hr, [w(Nn, { text: e.block.src }, null, 8, ["text"])])], 4)) : e.block.src ? (f(), x(A, { key: 3 }, [e.block.linkUrl ? (f(), x("a", {
2012
+ }), b("span", Wr, [w(Fn, { text: e.block.src }, null, 8, ["text"])])], 4)) : e.block.src ? (f(), x(j, { key: 3 }, [e.block.linkUrl ? (f(), x("a", {
1974
2013
  key: 0,
1975
2014
  href: e.block.linkUrl,
1976
2015
  target: "_blank",
1977
2016
  rel: "noopener noreferrer",
1978
- onClick: n[1] ||= P(() => {}, ["prevent"])
2017
+ onClick: n[1] ||= F(() => {}, ["prevent"])
1979
2018
  }, [b("img", {
1980
2019
  class: "tpl:border-0",
1981
2020
  loading: "lazy",
1982
2021
  src: k(T),
1983
2022
  alt: e.block.alt || k(a).image.altTextPlaceholder,
1984
2023
  style: i(S.value)
1985
- }, null, 12, Wr)], 8, Ur)) : (f(), x("img", {
2024
+ }, null, 12, Kr)], 8, Gr)) : (f(), x("img", {
1986
2025
  key: 1,
1987
2026
  class: "tpl:border-0",
1988
2027
  src: k(T),
1989
2028
  alt: e.block.alt,
1990
2029
  style: i(S.value)
1991
- }, null, 12, Gr))], 64)) : (f(), x("div", Kr, [c.value ? (f(), x("button", {
2030
+ }, null, 12, qr))], 64)) : (f(), x("div", Jr, [c.value ? (f(), x("button", {
1992
2031
  key: 0,
1993
2032
  "aria-label": k(a).image.browseMedia,
1994
2033
  class: "tpl:flex tpl:items-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-150 tpl:cursor-pointer tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)] tpl:bg-[var(--tpl-bg)]",
1995
- onClick: P(u, ["stop"])
1996
- }, [w(k(Wn), {
2034
+ onClick: F(u, ["stop"])
2035
+ }, [w(k(Kn), {
1997
2036
  size: 14,
1998
2037
  "stroke-width": 1.5
1999
- }), O(" " + p(k(a).image.browseMedia), 1)], 8, qr)) : (f(), x("span", Jr, p(k(a).image.clickToAdd), 1))]))], 4));
2038
+ }), O(" " + p(k(a).image.browseMedia), 1)], 8, Yr)) : (f(), x("span", Xr, p(k(a).image.clickToAdd), 1))]))], 4));
2000
2039
  }
2001
- }), Xr = { class: "tpl:w-full" }, Zr = ["href"], Qr = {
2040
+ }), Qr = { class: "tpl:w-full" }, $r = ["href"], ei = {
2002
2041
  key: 1,
2003
2042
  class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
2004
- }, $r = /* @__PURE__ */ y({
2043
+ }, ti = /* @__PURE__ */ y({
2005
2044
  __name: "MenuBlock",
2006
2045
  props: {
2007
2046
  block: {},
2008
2047
  viewport: {}
2009
2048
  },
2010
2049
  setup(e) {
2011
- let n = e, { t: r } = Ft(), a = j(() => ({
2050
+ let n = e, { t: r } = Ft(), a = M(() => ({
2012
2051
  display: "flex",
2013
2052
  flexWrap: "wrap",
2014
2053
  gap: `0 ${n.block.spacing}px`,
@@ -2016,14 +2055,14 @@ var Rr = {
2016
2055
  fontSize: `${n.block.fontSize}px`,
2017
2056
  fontFamily: n.block.fontFamily || "inherit",
2018
2057
  alignItems: "center"
2019
- })), o = j(() => n.block.items.length > 0);
2058
+ })), o = M(() => n.block.items.length > 0);
2020
2059
  function s(e) {
2021
2060
  return e || n.block.linkColor || n.block.color;
2022
2061
  }
2023
- return (n, c) => (f(), x("div", Xr, [o.value ? (f(), x("div", {
2062
+ return (n, c) => (f(), x("div", Qr, [o.value ? (f(), x("div", {
2024
2063
  key: 0,
2025
2064
  style: i(a.value)
2026
- }, [(f(!0), x(A, null, t(e.block.items, (t, n) => (f(), x(A, { key: t.id }, [b("a", {
2065
+ }, [(f(!0), x(j, null, t(e.block.items, (t, n) => (f(), x(j, { key: t.id }, [b("a", {
2027
2066
  href: t.url || "#",
2028
2067
  class: "tpl:cursor-default tpl:no-underline",
2029
2068
  style: i({
@@ -2031,16 +2070,16 @@ var Rr = {
2031
2070
  fontWeight: t.bold ? "bold" : "normal",
2032
2071
  textDecoration: t.underline ? "underline" : "none"
2033
2072
  }),
2034
- onClick: c[0] ||= P(() => {}, ["prevent"])
2035
- }, [w(Nn, { text: t.text || "..." }, null, 8, ["text"])], 12, Zr), n < e.block.items.length - 1 ? (f(), x("span", {
2073
+ onClick: c[0] ||= F(() => {}, ["prevent"])
2074
+ }, [w(Fn, { text: t.text || "..." }, null, 8, ["text"])], 12, $r), n < e.block.items.length - 1 ? (f(), x("span", {
2036
2075
  key: 0,
2037
2076
  style: i({
2038
2077
  color: e.block.separatorColor,
2039
2078
  padding: `0 ${e.block.spacing}px`
2040
2079
  })
2041
- }, p(e.block.separator), 5)) : M("", !0)], 64))), 128))], 4)) : (f(), x("div", Qr, [w(k(Gn), { size: 16 }), b("span", null, p(k(r).menu.addLinks), 1)]))]));
2080
+ }, p(e.block.separator), 5)) : N("", !0)], 64))), 128))], 4)) : (f(), x("div", ei, [w(k(qn), { size: 16 }), b("span", null, p(k(r).menu.addLinks), 1)]))]));
2042
2081
  }
2043
- }), ei = /* @__PURE__ */ new Set([
2082
+ }), ni = /* @__PURE__ */ new Set([
2044
2083
  "http",
2045
2084
  "https",
2046
2085
  "mailto",
@@ -2050,7 +2089,7 @@ var Rr = {
2050
2089
  "sms",
2051
2090
  "xmpp",
2052
2091
  "cid"
2053
- ]), ti = /* @__PURE__ */ new Set([
2092
+ ]), ri = /* @__PURE__ */ new Set([
2054
2093
  "SCRIPT",
2055
2094
  "STYLE",
2056
2095
  "IFRAME",
@@ -2060,7 +2099,7 @@ var Rr = {
2060
2099
  "META",
2061
2100
  "BASE",
2062
2101
  "FORM"
2063
- ]), ni = /* @__PURE__ */ new Set([
2102
+ ]), ii = /* @__PURE__ */ new Set([
2064
2103
  "href",
2065
2104
  "xlink:href",
2066
2105
  "formaction",
@@ -2069,16 +2108,16 @@ var Rr = {
2069
2108
  "background",
2070
2109
  "poster"
2071
2110
  ]);
2072
- function ri(e, t) {
2111
+ function ai(e, t) {
2073
2112
  let n = e.replace(/[\t\n\r]/g, "").replace(/^[\u0000-\u0020]+/, "").trimEnd();
2074
2113
  if (!n || n.startsWith("#")) return !0;
2075
2114
  let r = /^([a-z][a-z0-9+.-]*):/i.exec(n);
2076
2115
  if (!r) return !0;
2077
2116
  let i = r[1].toLowerCase();
2078
- return ei.has(i) ? !0 : t && i === "data" ? /^data:image\/(png|jpe?g|gif|webp|svg\+xml);/i.test(n) : !1;
2117
+ return ni.has(i) ? !0 : t && i === "data" ? /^data:image\/(png|jpe?g|gif|webp|svg\+xml);/i.test(n) : !1;
2079
2118
  }
2080
- function ii(e) {
2081
- if (ti.has(e.tagName)) {
2119
+ function oi(e) {
2120
+ if (ri.has(e.tagName)) {
2082
2121
  e.remove();
2083
2122
  return;
2084
2123
  }
@@ -2090,29 +2129,29 @@ function ii(e) {
2090
2129
  e.removeAttribute(n);
2091
2130
  continue;
2092
2131
  }
2093
- if (ni.has(t)) {
2094
- ri(e.getAttribute(n) ?? "", !1) || e.removeAttribute(n);
2132
+ if (ii.has(t)) {
2133
+ ai(e.getAttribute(n) ?? "", !1) || e.removeAttribute(n);
2095
2134
  continue;
2096
2135
  }
2097
2136
  if (t === "src") {
2098
- ri(e.getAttribute(n) ?? "", !0) || e.removeAttribute(n);
2137
+ ai(e.getAttribute(n) ?? "", !0) || e.removeAttribute(n);
2099
2138
  continue;
2100
2139
  }
2101
2140
  t === "srcdoc" && e.removeAttribute(n);
2102
2141
  }
2103
2142
  let n = Array.from(e.children);
2104
- for (let e of n) ii(e);
2143
+ for (let e of n) oi(e);
2105
2144
  }
2106
- function ai(e) {
2145
+ function si(e) {
2107
2146
  if (typeof DOMParser > "u") return e;
2108
2147
  let t = new DOMParser().parseFromString(`<!doctype html><body>${e}</body>`, "text/html").body, n = Array.from(t.children);
2109
- for (let e of n) ii(e);
2148
+ for (let e of n) oi(e);
2110
2149
  return t.innerHTML;
2111
2150
  }
2112
2151
  //#endregion
2113
2152
  //#region src/composables/useEditableTextBlock.ts
2114
- function oi(e) {
2115
- let t = N(pt, []), { syntax: n } = Ht(), r = j(() => ai(_e(ve(e(), t), n))), i = _(!1), a = _(null), { top: o, left: s } = Xe(a), { toLocal: c } = $e(), l = j(() => c({
2153
+ function ci(e) {
2154
+ let t = P(pt, []), { syntax: n } = Ht(), r = M(() => si(ge(_e(e(), t), n))), i = _(!1), a = _(null), { top: o, left: s } = Xe(a), { toLocal: c } = $e(), l = M(() => c({
2116
2155
  top: o.value - 8,
2117
2156
  left: s.value
2118
2157
  }));
@@ -2133,14 +2172,14 @@ function oi(e) {
2133
2172
  }
2134
2173
  //#endregion
2135
2174
  //#region src/components/blocks/ParagraphBlock.vue?vue&type=script&setup=true&lang.ts
2136
- var si = ["innerHTML"], ci = /* @__PURE__ */ y({
2175
+ var li = ["innerHTML"], ui = /* @__PURE__ */ y({
2137
2176
  __name: "ParagraphBlock",
2138
2177
  props: {
2139
2178
  block: {},
2140
2179
  viewport: {}
2141
2180
  },
2142
2181
  setup(e) {
2143
- let t = e, n = C(() => import("./ParagraphEditor-Cf75UfSo.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: s, handleEditorDone: c } = oi(() => t.block.content);
2182
+ let t = e, n = C(() => import("./ParagraphEditor-C5ixOIYb.js")), { isEditing: r, blockRef: i, toolbarPosition: a, resolvedContent: o, handleDoubleClick: s, handleEditorDone: c } = ci(() => t.block.content);
2144
2183
  return (t, l) => (f(), x("div", {
2145
2184
  ref_key: "blockRef",
2146
2185
  ref: i,
@@ -2159,46 +2198,46 @@ var si = ["innerHTML"], ci = /* @__PURE__ */ y({
2159
2198
  key: 1,
2160
2199
  class: "tpl-text-content tpl:outline-none [&_a]:tpl:underline [&_li]:tpl:my-1 [&_ol]:tpl:my-2 [&_ol]:tpl:pl-6 [&_p]:tpl:m-0 [&_p]:tpl:mb-2 [&_p:last-child]:tpl:mb-0 [&_s]:tpl:line-through [&_sub]:tpl:align-sub [&_sub]:tpl:text-[0.75em] [&_sup]:tpl:align-super [&_sup]:tpl:text-[0.75em] [&_ul]:tpl:my-2 [&_ul]:tpl:pl-6",
2161
2200
  innerHTML: k(o)
2162
- }, null, 8, si))], 544));
2201
+ }, null, 8, li))], 544));
2163
2202
  }
2164
2203
  });
2165
2204
  //#endregion
2166
2205
  //#region src/utils/blockComponentResolver.ts
2167
- function li(e, t, n) {
2206
+ function di(e, t, n) {
2168
2207
  if (t) {
2169
2208
  let n = t.getComponent(e);
2170
2209
  if (n) return n;
2171
2210
  }
2172
2211
  return n[e.type] ?? null;
2173
2212
  }
2174
- function ui(e) {
2213
+ function fi(e) {
2175
2214
  let { padding: t, backgroundColor: n } = e.styles, r = {
2176
2215
  padding: `${t.top}px ${t.right}px ${t.bottom}px ${t.left}px`,
2177
2216
  backgroundColor: n || "transparent"
2178
2217
  };
2179
2218
  return e.type === "section" && e.borderRadius && e.borderRadius > 0 && (r.borderRadius = `${e.borderRadius}px`), r;
2180
2219
  }
2181
- function di(e) {
2220
+ function pi(e) {
2182
2221
  if (e.type !== "section" || !e.wrapper) return null;
2183
2222
  let t = e.wrapper, n = {};
2184
2223
  return t.backgroundColor && (n.backgroundColor = t.backgroundColor), t.padding && (n.padding = `${t.padding.top}px ${t.padding.right}px ${t.padding.bottom}px ${t.padding.left}px`), t.borderRadius && t.borderRadius > 0 && (n.borderRadius = `${t.borderRadius}px`), n;
2185
2224
  }
2186
2225
  //#endregion
2187
2226
  //#region src/components/blocks/BlockWrapper.vue?vue&type=script&setup=true&lang.ts
2188
- var fi = ["data-block-id", "data-block-type"], pi = ["aria-label"], mi = [
2227
+ var mi = ["data-block-id", "data-block-type"], hi = ["aria-label"], gi = [
2189
2228
  "aria-label",
2190
2229
  "aria-pressed",
2191
2230
  "title"
2192
- ], hi = ["aria-label", "title"], gi = ["aria-label", "title"], _i = ["aria-label", "title"], vi = {
2231
+ ], _i = ["aria-label", "title"], vi = ["aria-label", "title"], yi = ["aria-label", "title"], bi = {
2193
2232
  key: 1,
2194
2233
  class: "tpl-block-hidden-overlay tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-[5] tpl:flex tpl:items-center tpl:justify-center tpl:rounded-sm"
2195
- }, yi = { class: "tpl:flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-2 tpl:py-1 tpl:text-[10px] tpl:font-medium tpl:bg-[var(--tpl-bg-elevated)] tpl:text-[var(--tpl-text-muted)] tpl:shadow-[var(--tpl-shadow-sm)]" }, bi = {
2234
+ }, xi = { class: "tpl:flex tpl:items-center tpl:gap-1 tpl:rounded tpl:px-2 tpl:py-1 tpl:text-[10px] tpl:font-medium tpl:bg-[var(--tpl-bg-elevated)] tpl:text-[var(--tpl-text-muted)] tpl:shadow-[var(--tpl-shadow-sm)]" }, Si = {
2196
2235
  key: 2,
2197
2236
  class: "tpl:absolute tpl:-left-1 tpl:top-1/2 tpl:z-[5] tpl:-translate-x-full tpl:-translate-y-1/2"
2198
- }, xi = ["aria-label", "title"], Si = {
2237
+ }, Ci = ["aria-label", "title"], wi = {
2199
2238
  key: 3,
2200
2239
  class: "tpl:absolute tpl:-right-1 tpl:-top-1 tpl:z-[5] tpl:translate-x-full"
2201
- }, Ci = ["aria-label"], wi = /*#__PURE__*/ Vt(/* @__PURE__ */ y({
2240
+ }, Ti = ["aria-label"], Ei = /*#__PURE__*/ Vt(/* @__PURE__ */ y({
2202
2241
  __name: "BlockWrapper",
2203
2242
  props: {
2204
2243
  block: {},
@@ -2208,9 +2247,9 @@ var fi = ["data-block-id", "data-block-type"], pi = ["aria-label"], mi = [
2208
2247
  },
2209
2248
  emits: ["select"],
2210
2249
  setup(e, { emit: t }) {
2211
- let n = C(() => import("./BlockIssueBadge-BQmq1bxn.js")), r = e, a = t, { t: s, format: c } = Ft(), l = N(Mt, null), u = _(null), d = j(() => l?.liftedBlockId.value === r.block.id), m = j(() => d.value ? c(s.blockActions.dragLifted, { block: r.block.type }) : s.blockActions.drag);
2250
+ let n = C(() => import("./BlockIssueBadge-B4QjePax.js")), r = e, a = t, { t: s, format: c } = Ft(), l = P(Mt, null), u = _(null), d = M(() => l?.liftedBlockId.value === r.block.id), m = M(() => d.value ? c(s.blockActions.dragLifted, { block: r.block.type }) : s.blockActions.drag);
2212
2251
  async function h() {
2213
- await ie(), u.value?.focus();
2252
+ await re(), u.value?.focus();
2214
2253
  }
2215
2254
  function g(e) {
2216
2255
  if (l) {
@@ -2231,32 +2270,32 @@ var fi = ["data-block-id", "data-block-type"], pi = ["aria-label"], mi = [
2231
2270
  }
2232
2271
  }
2233
2272
  }
2234
- let v = j(() => !r.viewport || !r.block.visibility ? !1 : r.block.visibility[r.viewport] === !1), y = j(() => r.previewMode === !0 && v.value), S = j(() => r.viewport ? {
2273
+ let v = M(() => !r.viewport || !r.block.visibility ? !1 : r.block.visibility[r.viewport] === !1), y = M(() => r.previewMode === !0 && v.value), S = M(() => r.viewport ? {
2235
2274
  desktop: s.viewport.desktop,
2236
2275
  mobile: s.viewport.mobile
2237
- }[r.viewport] ?? r.viewport : ""), E = j(() => !!r.block.displayCondition), D = N(xt, null), ee = N(_t, null), A = N(kt, {}), te = j(() => !!A.savedModules), ne = j(() => A.comments?.getBlockCount(r.block.id) ?? 0), re = j(() => {
2238
- let e = ui(r.block), t = {
2276
+ }[r.viewport] ?? r.viewport : ""), E = M(() => !!r.block.displayCondition), D = P(xt, null), A = P(_t, null), j = P(kt, {}), ee = M(() => !!j.savedModules), te = M(() => j.comments?.getBlockCount(r.block.id) ?? 0), ne = M(() => {
2277
+ let e = fi(r.block), t = {
2239
2278
  padding: e.padding,
2240
2279
  backgroundColor: e.backgroundColor
2241
2280
  };
2242
2281
  return e.borderRadius && (t.borderRadius = e.borderRadius), t;
2243
- }), ae = j(() => di(r.block));
2244
- function oe(e) {
2282
+ }), ie = M(() => pi(r.block));
2283
+ function ae(e) {
2245
2284
  r.previewMode || (e.target?.closest("a") && e.preventDefault(), e.stopPropagation(), a("select"));
2246
2285
  }
2247
- function se() {
2286
+ function oe() {
2248
2287
  D?.deleteBlock(r.block.id);
2249
2288
  }
2250
- function ce() {
2289
+ function se() {
2251
2290
  D?.duplicateBlock(r.block);
2252
2291
  }
2253
- function le() {
2254
- A.savedModules?.openSaveDialog(r.block.id);
2292
+ function ce() {
2293
+ j.savedModules?.openSaveDialog(r.block.id);
2255
2294
  }
2256
- function ue() {
2257
- ee?.toggleBlock(r.block.id);
2295
+ function le() {
2296
+ A?.toggleBlock(r.block.id);
2258
2297
  }
2259
- return (t, r) => y.value ? M("", !0) : (f(), x("div", {
2298
+ return (t, r) => y.value ? N("", !0) : (f(), x("div", {
2260
2299
  key: 0,
2261
2300
  class: o(["tpl-block tpl:group tpl:relative tpl:cursor-pointer tpl:rounded-sm tpl:transition-shadow tpl:duration-150", {
2262
2301
  "tpl-block--selected": e.isSelected,
@@ -2265,7 +2304,7 @@ var fi = ["data-block-id", "data-block-type"], pi = ["aria-label"], mi = [
2265
2304
  }]),
2266
2305
  "data-block-id": e.block.id,
2267
2306
  "data-block-type": e.block.type,
2268
- onClick: oe
2307
+ onClick: ae
2269
2308
  }, [
2270
2309
  w(k(n), { "block-id": e.block.id }, null, 8, ["block-id"]),
2271
2310
  e.isSelected ? (f(), x("div", {
@@ -2283,97 +2322,97 @@ var fi = ["data-block-id", "data-block-type"], pi = ["aria-label"], mi = [
2283
2322
  "aria-keyshortcuts": "Space Enter ArrowUp ArrowDown Escape",
2284
2323
  title: k(s).blockActions.drag,
2285
2324
  onKeydown: g
2286
- }, [w(k(Un), {
2325
+ }, [w(k(Gn), {
2287
2326
  size: 14,
2288
2327
  "stroke-width": 1.5
2289
- })], 40, mi),
2328
+ })], 40, gi),
2290
2329
  b("button", {
2291
2330
  class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
2292
2331
  "aria-label": k(s).blockActions.duplicate,
2293
2332
  title: k(s).blockActions.duplicate,
2294
- onClick: P(ce, ["stop"])
2295
- }, [w(k(Bn), {
2333
+ onClick: F(se, ["stop"])
2334
+ }, [w(k(Hn), {
2296
2335
  size: 14,
2297
2336
  "stroke-width": 1.5
2298
- })], 8, hi),
2299
- te.value ? (f(), x("button", {
2337
+ })], 8, _i),
2338
+ ee.value ? (f(), x("button", {
2300
2339
  key: 0,
2301
2340
  class: "tpl-block-action-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
2302
2341
  "aria-label": k(s).blockActions.saveAsModule,
2303
2342
  title: k(s).blockActions.saveAsModule,
2304
- onClick: P(le, ["stop"])
2305
- }, [w(k(Ln), {
2343
+ onClick: F(ce, ["stop"])
2344
+ }, [w(k(zn), {
2306
2345
  size: 14,
2307
2346
  "stroke-width": 1.5
2308
- })], 8, gi)) : M("", !0),
2347
+ })], 8, vi)) : N("", !0),
2309
2348
  b("button", {
2310
2349
  class: "tpl-block-action-btn tpl-block-delete-btn tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-sm tpl:border-none tpl:transition-colors tpl:duration-150",
2311
2350
  "aria-label": k(s).blockActions.delete,
2312
2351
  title: k(s).blockActions.delete,
2313
- onClick: P(se, ["stop"])
2352
+ onClick: F(oe, ["stop"])
2314
2353
  }, [w(k(Rt), {
2315
2354
  size: 14,
2316
2355
  "stroke-width": 1.5
2317
- })], 8, _i)
2318
- ], 8, pi)) : M("", !0),
2319
- v.value ? (f(), x("div", vi, [b("span", yi, [w(k(Vn), {
2356
+ })], 8, yi)
2357
+ ], 8, hi)) : N("", !0),
2358
+ v.value ? (f(), x("div", bi, [b("span", xi, [w(k(Un), {
2320
2359
  size: 12,
2321
2360
  "stroke-width": 1.5
2322
- }), O(" " + p(k(c)(k(s).blockActions.hiddenOnViewport, { viewport: S.value })), 1)])])) : M("", !0),
2323
- E.value && !v.value ? (f(), x("div", bi, [b("button", {
2361
+ }), O(" " + p(k(c)(k(s).blockActions.hiddenOnViewport, { viewport: S.value })), 1)])])) : N("", !0),
2362
+ E.value && !v.value ? (f(), x("div", Si, [b("button", {
2324
2363
  class: "tpl-condition-toggle tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:p-1 tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-bg-elevated)] tpl:text-[var(--tpl-primary)] tpl:border tpl:border-[var(--tpl-border)]",
2325
2364
  "aria-label": k(s).blockActions.conditionToggle,
2326
2365
  title: e.block.displayCondition?.label,
2327
- onClick: P(ue, ["stop"])
2328
- }, [w(k(Hn), {
2366
+ onClick: F(le, ["stop"])
2367
+ }, [w(k(Wn), {
2329
2368
  size: 12,
2330
2369
  "stroke-width": 2
2331
- })], 8, xi)])) : M("", !0),
2332
- ne.value > 0 && !v.value ? (f(), x("div", Si, [b("button", {
2370
+ })], 8, Ci)])) : N("", !0),
2371
+ te.value > 0 && !v.value ? (f(), x("div", wi, [b("button", {
2333
2372
  class: "tpl-comment-indicator tpl:flex tpl:min-h-6 tpl:min-w-6 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:gap-0.5 tpl:rounded-full tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]",
2334
- "aria-label": k(c)(k(s).blockActions.comments, { count: String(ne.value) }),
2335
- onClick: r[0] ||= P((t) => k(A).comments?.openForBlock(e.block.id), ["stop"])
2373
+ "aria-label": k(c)(k(s).blockActions.comments, { count: String(te.value) }),
2374
+ onClick: r[0] ||= F((t) => k(j).comments?.openForBlock(e.block.id), ["stop"])
2336
2375
  }, [w(k(Lt), {
2337
2376
  size: 12,
2338
2377
  "stroke-width": 2.5
2339
- }), O(" " + p(ne.value), 1)], 8, Ci)])) : M("", !0),
2340
- ae.value ? (f(), x("div", {
2378
+ }), O(" " + p(te.value), 1)], 8, Ti)])) : N("", !0),
2379
+ ie.value ? (f(), x("div", {
2341
2380
  key: 4,
2342
2381
  class: "tpl-section-wrapper",
2343
- style: i(ae.value)
2382
+ style: i(ie.value)
2344
2383
  }, [b("div", {
2345
2384
  class: "tpl-block-content",
2346
- style: i(re.value)
2385
+ style: i(ne.value)
2347
2386
  }, [T(t.$slots, "default", {}, void 0, !0)], 4)], 4)) : (f(), x("div", {
2348
2387
  key: 5,
2349
2388
  class: "tpl-block-content",
2350
- style: i(re.value)
2389
+ style: i(ne.value)
2351
2390
  }, [T(t.$slots, "default", {}, void 0, !0)], 4))
2352
- ], 10, fi));
2391
+ ], 10, mi));
2353
2392
  }
2354
2393
  }), [["__scopeId", "data-v-7d9e7893"]]);
2355
2394
  //#endregion
2356
2395
  //#region src/utils/unwrapParagraph.ts
2357
- function Ti(e) {
2396
+ function Di(e) {
2358
2397
  let t = e.match(/^\s*<p\b[^>]*>([\s\S]*)<\/p>\s*$/);
2359
2398
  return !t || /<\/p>\s*<p\b/i.test(t[1]) ? e : t[1];
2360
2399
  }
2361
2400
  //#endregion
2362
2401
  //#region src/components/blocks/TitleBlock.vue
2363
- var Ei = /* @__PURE__ */ y({
2402
+ var Oi = /* @__PURE__ */ y({
2364
2403
  __name: "TitleBlock",
2365
2404
  props: {
2366
2405
  block: {},
2367
2406
  viewport: {}
2368
2407
  },
2369
2408
  setup(e) {
2370
- let t = e, n = C(() => import("./TitleEditor-CCUkbRN0.js")), { isEditing: r, blockRef: a, toolbarPosition: o, resolvedContent: s, handleDoubleClick: c, handleEditorDone: l } = oi(() => t.block.content), u = j(() => {
2409
+ let t = e, n = C(() => import("./TitleEditor-n6WDVDjW.js")), { isEditing: r, blockRef: a, toolbarPosition: o, resolvedContent: s, handleDoubleClick: c, handleEditorDone: l } = ci(() => t.block.content), u = M(() => {
2371
2410
  let e = {
2372
- fontSize: `${Ie[t.block.level]}px`,
2411
+ fontSize: `${Fe[t.block.level]}px`,
2373
2412
  textAlign: t.block.textAlign
2374
2413
  };
2375
2414
  return t.block.color && (e.color = t.block.color), t.block.fontFamily && (e.fontFamily = t.block.fontFamily), e;
2376
- }), p = j(() => `h${t.block.level}`), m = j(() => Ti(s.value));
2415
+ }), p = M(() => `h${t.block.level}`), m = M(() => Di(s.value));
2377
2416
  return (t, s) => (f(), x("div", {
2378
2417
  ref_key: "blockRef",
2379
2418
  ref: a,
@@ -2399,88 +2438,88 @@ var Ei = /* @__PURE__ */ y({
2399
2438
  });
2400
2439
  //#endregion
2401
2440
  //#region src/utils/sectionColumnDrop.ts
2402
- function Di(e) {
2441
+ function ki(e) {
2403
2442
  return e.dataset.blockType !== "section" && e.dataset.paletteType !== "section";
2404
2443
  }
2405
2444
  //#endregion
2406
2445
  //#region ../../node_modules/.pnpm/vue-draggable-plus@0.6.1_@types+sortablejs@1.15.9/node_modules/vue-draggable-plus/dist/vue-draggable-plus.js
2407
- var Oi = Object.defineProperty, ki = Object.getOwnPropertySymbols, Ai = Object.prototype.hasOwnProperty, ji = Object.prototype.propertyIsEnumerable, Mi = (e, t, n) => t in e ? Oi(e, t, {
2446
+ var Ai = Object.defineProperty, ji = Object.getOwnPropertySymbols, Mi = Object.prototype.hasOwnProperty, Ni = Object.prototype.propertyIsEnumerable, Pi = (e, t, n) => t in e ? Ai(e, t, {
2408
2447
  enumerable: !0,
2409
2448
  configurable: !0,
2410
2449
  writable: !0,
2411
2450
  value: n
2412
- }) : e[t] = n, Ni = (e, t) => {
2413
- for (var n in t ||= {}) Ai.call(t, n) && Mi(e, n, t[n]);
2414
- if (ki) for (var n of ki(t)) ji.call(t, n) && Mi(e, n, t[n]);
2451
+ }) : e[t] = n, Fi = (e, t) => {
2452
+ for (var n in t ||= {}) Mi.call(t, n) && Pi(e, n, t[n]);
2453
+ if (ji) for (var n of ji(t)) Ni.call(t, n) && Pi(e, n, t[n]);
2415
2454
  return e;
2416
- }, Pi = (e, t) => {
2455
+ }, Ii = (e, t) => {
2417
2456
  var n = {};
2418
- for (var r in e) Ai.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
2419
- if (e != null && ki) for (var r of ki(e)) t.indexOf(r) < 0 && ji.call(e, r) && (n[r] = e[r]);
2457
+ for (var r in e) Mi.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
2458
+ if (e != null && ji) for (var r of ji(e)) t.indexOf(r) < 0 && Ni.call(e, r) && (n[r] = e[r]);
2420
2459
  return n;
2421
- }, Fi = "[vue-draggable-plus]: ";
2422
- function Ii(e) {
2423
- console.warn(Fi + e);
2460
+ }, Li = "[vue-draggable-plus]: ";
2461
+ function Ri(e) {
2462
+ console.warn(Li + e);
2424
2463
  }
2425
- function Li(e) {
2426
- console.error(Fi + e);
2464
+ function zi(e) {
2465
+ console.error(Li + e);
2427
2466
  }
2428
- function Ri(e, t, n) {
2467
+ function Bi(e, t, n) {
2429
2468
  return n >= 0 && n < e.length && e.splice(n, 0, e.splice(t, 1)[0]), e;
2430
2469
  }
2431
- function zi(e) {
2470
+ function Vi(e) {
2432
2471
  return e.replace(/-(\w)/g, (e, t) => t ? t.toUpperCase() : "");
2433
2472
  }
2434
- function Bi(e) {
2435
- return Object.keys(e).reduce((t, n) => (e[n] !== void 0 && (t[zi(n)] = e[n]), t), {});
2473
+ function Hi(e) {
2474
+ return Object.keys(e).reduce((t, n) => (e[n] !== void 0 && (t[Vi(n)] = e[n]), t), {});
2436
2475
  }
2437
- function Vi(e, t) {
2476
+ function Ui(e, t) {
2438
2477
  return Array.isArray(e) && e.splice(t, 1), e;
2439
2478
  }
2440
- function Hi(e, t, n) {
2479
+ function Wi(e, t, n) {
2441
2480
  return Array.isArray(e) && e.splice(t, 0, n), e;
2442
2481
  }
2443
- function Ui(e) {
2482
+ function Gi(e) {
2444
2483
  return e === void 0;
2445
2484
  }
2446
- function Wi(e) {
2485
+ function Ki(e) {
2447
2486
  return typeof e == "string";
2448
2487
  }
2449
- function Gi(e, t, n) {
2488
+ function qi(e, t, n) {
2450
2489
  let r = e.children[n];
2451
2490
  e.insertBefore(t, r);
2452
2491
  }
2453
- function Ki(e) {
2492
+ function Ji(e) {
2454
2493
  e.parentNode && e.parentNode.removeChild(e);
2455
2494
  }
2456
- function qi(e, t = document) {
2495
+ function Yi(e, t = document) {
2457
2496
  let n = null;
2458
- return n = typeof t?.querySelector == "function" ? (t?.querySelector)?.call(t, e) : document.querySelector(e), n || Ii(`Element not found: ${e}`), n;
2497
+ return n = typeof t?.querySelector == "function" ? (t?.querySelector)?.call(t, e) : document.querySelector(e), n || Ri(`Element not found: ${e}`), n;
2459
2498
  }
2460
- function Ji(e, t, n = null) {
2499
+ function Xi(e, t, n = null) {
2461
2500
  return function(...r) {
2462
2501
  return e.apply(n, r), t.apply(n, r);
2463
2502
  };
2464
2503
  }
2465
- function Yi(e, t) {
2466
- let n = Ni({}, e);
2504
+ function Zi(e, t) {
2505
+ let n = Fi({}, e);
2467
2506
  return Object.keys(t).forEach((r) => {
2468
- n[r] ? n[r] = Ji(e[r], t[r]) : n[r] = t[r];
2507
+ n[r] ? n[r] = Xi(e[r], t[r]) : n[r] = t[r];
2469
2508
  }), n;
2470
2509
  }
2471
- function Xi(e) {
2510
+ function Qi(e) {
2472
2511
  return e instanceof HTMLElement;
2473
2512
  }
2474
- function Zi(e, t) {
2513
+ function $i(e, t) {
2475
2514
  Object.keys(e).forEach((n) => {
2476
2515
  t(n, e[n]);
2477
2516
  });
2478
2517
  }
2479
- function Qi(e) {
2518
+ function ea(e) {
2480
2519
  return e.charCodeAt(0) === 111 && e.charCodeAt(1) === 110 && (e.charCodeAt(2) > 122 || e.charCodeAt(2) < 97);
2481
2520
  }
2482
- var $i = Object.assign;
2483
- function ea(e, t) {
2521
+ var ta = Object.assign;
2522
+ function na(e, t) {
2484
2523
  var n = Object.keys(e);
2485
2524
  if (Object.getOwnPropertySymbols) {
2486
2525
  var r = Object.getOwnPropertySymbols(e);
@@ -2490,26 +2529,26 @@ function ea(e, t) {
2490
2529
  }
2491
2530
  return n;
2492
2531
  }
2493
- function ta(e) {
2532
+ function ra(e) {
2494
2533
  for (var t = 1; t < arguments.length; t++) {
2495
2534
  var n = arguments[t] == null ? {} : arguments[t];
2496
- t % 2 ? ea(Object(n), !0).forEach(function(t) {
2497
- ra(e, t, n[t]);
2498
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : ea(Object(n)).forEach(function(t) {
2535
+ t % 2 ? na(Object(n), !0).forEach(function(t) {
2536
+ aa(e, t, n[t]);
2537
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : na(Object(n)).forEach(function(t) {
2499
2538
  Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(n, t));
2500
2539
  });
2501
2540
  }
2502
2541
  return e;
2503
2542
  }
2504
- function na(e) {
2543
+ function ia(e) {
2505
2544
  "@babel/helpers - typeof";
2506
- return na = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
2545
+ return ia = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
2507
2546
  return typeof e;
2508
2547
  } : function(e) {
2509
2548
  return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
2510
- }, na(e);
2549
+ }, ia(e);
2511
2550
  }
2512
- function ra(e, t, n) {
2551
+ function aa(e, t, n) {
2513
2552
  return t in e ? Object.defineProperty(e, t, {
2514
2553
  value: n,
2515
2554
  enumerable: !0,
@@ -2517,45 +2556,45 @@ function ra(e, t, n) {
2517
2556
  writable: !0
2518
2557
  }) : e[t] = n, e;
2519
2558
  }
2520
- function ia() {
2521
- return ia = Object.assign || function(e) {
2559
+ function oa() {
2560
+ return oa = Object.assign || function(e) {
2522
2561
  for (var t = 1; t < arguments.length; t++) {
2523
2562
  var n = arguments[t];
2524
2563
  for (var r in n) Object.prototype.hasOwnProperty.call(n, r) && (e[r] = n[r]);
2525
2564
  }
2526
2565
  return e;
2527
- }, ia.apply(this, arguments);
2566
+ }, oa.apply(this, arguments);
2528
2567
  }
2529
- function aa(e, t) {
2568
+ function sa(e, t) {
2530
2569
  if (e == null) return {};
2531
2570
  var n = {}, r = Object.keys(e), i, a;
2532
2571
  for (a = 0; a < r.length; a++) i = r[a], !(t.indexOf(i) >= 0) && (n[i] = e[i]);
2533
2572
  return n;
2534
2573
  }
2535
- function oa(e, t) {
2574
+ function ca(e, t) {
2536
2575
  if (e == null) return {};
2537
- var n = aa(e, t), r, i;
2576
+ var n = sa(e, t), r, i;
2538
2577
  if (Object.getOwnPropertySymbols) {
2539
2578
  var a = Object.getOwnPropertySymbols(e);
2540
2579
  for (i = 0; i < a.length; i++) r = a[i], !(t.indexOf(r) >= 0) && Object.prototype.propertyIsEnumerable.call(e, r) && (n[r] = e[r]);
2541
2580
  }
2542
2581
  return n;
2543
2582
  }
2544
- var sa = "1.15.2";
2545
- function ca(e) {
2583
+ var la = "1.15.2";
2584
+ function ua(e) {
2546
2585
  if (typeof window < "u" && window.navigator) return !!/* @__PURE__ */ navigator.userAgent.match(e);
2547
2586
  }
2548
- var la = ca(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), ua = ca(/Edge/i), da = ca(/firefox/i), fa = ca(/safari/i) && !ca(/chrome/i) && !ca(/android/i), pa = ca(/iP(ad|od|hone)/i), ma = ca(/chrome/i) && ca(/android/i), ha = {
2587
+ var da = ua(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), fa = ua(/Edge/i), pa = ua(/firefox/i), ma = ua(/safari/i) && !ua(/chrome/i) && !ua(/android/i), ha = ua(/iP(ad|od|hone)/i), ga = ua(/chrome/i) && ua(/android/i), _a = {
2549
2588
  capture: !1,
2550
2589
  passive: !1
2551
2590
  };
2552
- function I(e, t, n) {
2553
- e.addEventListener(t, n, !la && ha);
2554
- }
2555
2591
  function L(e, t, n) {
2556
- e.removeEventListener(t, n, !la && ha);
2592
+ e.addEventListener(t, n, !da && _a);
2557
2593
  }
2558
- function ga(e, t) {
2594
+ function R(e, t, n) {
2595
+ e.removeEventListener(t, n, !da && _a);
2596
+ }
2597
+ function va(e, t) {
2559
2598
  if (t) {
2560
2599
  if (t[0] === ">" && (t = t.substring(1)), e) try {
2561
2600
  if (e.matches) return e.matches(t);
@@ -2567,41 +2606,41 @@ function ga(e, t) {
2567
2606
  return !1;
2568
2607
  }
2569
2608
  }
2570
- function _a(e) {
2609
+ function ya(e) {
2571
2610
  return e.host && e !== document && e.host.nodeType ? e.host : e.parentNode;
2572
2611
  }
2573
- function va(e, t, n, r) {
2612
+ function ba(e, t, n, r) {
2574
2613
  if (e) {
2575
2614
  n ||= document;
2576
2615
  do {
2577
- if (t != null && (t[0] === ">" ? e.parentNode === n && ga(e, t) : ga(e, t)) || r && e === n) return e;
2616
+ if (t != null && (t[0] === ">" ? e.parentNode === n && va(e, t) : va(e, t)) || r && e === n) return e;
2578
2617
  if (e === n) break;
2579
- } while (e = _a(e));
2618
+ } while (e = ya(e));
2580
2619
  }
2581
2620
  return null;
2582
2621
  }
2583
- var ya = /\s+/g;
2584
- function R(e, t, n) {
2585
- e && t && (e.classList ? e.classList[n ? "add" : "remove"](t) : e.className = ((" " + e.className + " ").replace(ya, " ").replace(" " + t + " ", " ") + (n ? " " + t : "")).replace(ya, " "));
2586
- }
2622
+ var xa = /\s+/g;
2587
2623
  function z(e, t, n) {
2624
+ e && t && (e.classList ? e.classList[n ? "add" : "remove"](t) : e.className = ((" " + e.className + " ").replace(xa, " ").replace(" " + t + " ", " ") + (n ? " " + t : "")).replace(xa, " "));
2625
+ }
2626
+ function B(e, t, n) {
2588
2627
  var r = e && e.style;
2589
2628
  if (r) {
2590
2629
  if (n === void 0) return document.defaultView && document.defaultView.getComputedStyle ? n = document.defaultView.getComputedStyle(e, "") : e.currentStyle && (n = e.currentStyle), t === void 0 ? n : n[t];
2591
2630
  !(t in r) && t.indexOf("webkit") === -1 && (t = "-webkit-" + t), r[t] = n + (typeof n == "string" ? "" : "px");
2592
2631
  }
2593
2632
  }
2594
- function ba(e, t) {
2633
+ function Sa(e, t) {
2595
2634
  var n = "";
2596
2635
  if (typeof e == "string") n = e;
2597
2636
  else do {
2598
- var r = z(e, "transform");
2637
+ var r = B(e, "transform");
2599
2638
  r && r !== "none" && (n = r + " " + n);
2600
2639
  } while (!t && (e = e.parentNode));
2601
2640
  var i = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;
2602
2641
  return i && new i(n);
2603
2642
  }
2604
- function xa(e, t, n) {
2643
+ function Ca(e, t, n) {
2605
2644
  if (e) {
2606
2645
  var r = e.getElementsByTagName(t), i = 0, a = r.length;
2607
2646
  if (n) for (; i < a; i++) n(r[i], i);
@@ -2609,21 +2648,21 @@ function xa(e, t, n) {
2609
2648
  }
2610
2649
  return [];
2611
2650
  }
2612
- function Sa() {
2651
+ function wa() {
2613
2652
  return document.scrollingElement || document.documentElement;
2614
2653
  }
2615
- function B(e, t, n, r, i) {
2654
+ function V(e, t, n, r, i) {
2616
2655
  if (!(!e.getBoundingClientRect && e !== window)) {
2617
2656
  var a, o, s, c, l, u, d;
2618
- if (e !== window && e.parentNode && e !== Sa() ? (a = e.getBoundingClientRect(), o = a.top, s = a.left, c = a.bottom, l = a.right, u = a.height, d = a.width) : (o = 0, s = 0, c = window.innerHeight, l = window.innerWidth, u = window.innerHeight, d = window.innerWidth), (t || n) && e !== window && (i ||= e.parentNode, !la)) do
2619
- if (i && i.getBoundingClientRect && (z(i, "transform") !== "none" || n && z(i, "position") !== "static")) {
2657
+ if (e !== window && e.parentNode && e !== wa() ? (a = e.getBoundingClientRect(), o = a.top, s = a.left, c = a.bottom, l = a.right, u = a.height, d = a.width) : (o = 0, s = 0, c = window.innerHeight, l = window.innerWidth, u = window.innerHeight, d = window.innerWidth), (t || n) && e !== window && (i ||= e.parentNode, !da)) do
2658
+ if (i && i.getBoundingClientRect && (B(i, "transform") !== "none" || n && B(i, "position") !== "static")) {
2620
2659
  var f = i.getBoundingClientRect();
2621
- o -= f.top + parseInt(z(i, "border-top-width")), s -= f.left + parseInt(z(i, "border-left-width")), c = o + a.height, l = s + a.width;
2660
+ o -= f.top + parseInt(B(i, "border-top-width")), s -= f.left + parseInt(B(i, "border-left-width")), c = o + a.height, l = s + a.width;
2622
2661
  break;
2623
2662
  }
2624
2663
  while (i = i.parentNode);
2625
2664
  if (r && e !== window) {
2626
- var p = ba(i || e), m = p && p.a, h = p && p.d;
2665
+ var p = Sa(i || e), m = p && p.a, h = p && p.d;
2627
2666
  p && (o /= h, s /= m, d /= m, u /= h, c = o + u, l = s + d);
2628
2667
  }
2629
2668
  return {
@@ -2636,18 +2675,18 @@ function B(e, t, n, r, i) {
2636
2675
  };
2637
2676
  }
2638
2677
  }
2639
- function Ca(e, t, n) {
2640
- for (var r = ka(e, !0), i = B(e)[t]; r;) {
2641
- var a = B(r)[n], o = void 0;
2678
+ function Ta(e, t, n) {
2679
+ for (var r = ja(e, !0), i = V(e)[t]; r;) {
2680
+ var a = V(r)[n], o = void 0;
2642
2681
  if (o = i >= a, !o) return r;
2643
- if (r === Sa()) break;
2644
- r = ka(r, !1);
2682
+ if (r === wa()) break;
2683
+ r = ja(r, !1);
2645
2684
  }
2646
2685
  return !1;
2647
2686
  }
2648
- function wa(e, t, n, r) {
2687
+ function Ea(e, t, n, r) {
2649
2688
  for (var i = 0, a = 0, o = e.children; a < o.length;) {
2650
- if (o[a].style.display !== "none" && o[a] !== Q.ghost && (r || o[a] !== Q.dragged) && va(o[a], n.draggable, e, !1)) {
2689
+ if (o[a].style.display !== "none" && o[a] !== Q.ghost && (r || o[a] !== Q.dragged) && ba(o[a], n.draggable, e, !1)) {
2651
2690
  if (i === t) return o[a];
2652
2691
  i++;
2653
2692
  }
@@ -2655,96 +2694,96 @@ function wa(e, t, n, r) {
2655
2694
  }
2656
2695
  return null;
2657
2696
  }
2658
- function Ta(e, t) {
2659
- for (var n = e.lastElementChild; n && (n === Q.ghost || z(n, "display") === "none" || t && !ga(n, t));) n = n.previousElementSibling;
2697
+ function Da(e, t) {
2698
+ for (var n = e.lastElementChild; n && (n === Q.ghost || B(n, "display") === "none" || t && !va(n, t));) n = n.previousElementSibling;
2660
2699
  return n || null;
2661
2700
  }
2662
- function Ea(e, t) {
2701
+ function Oa(e, t) {
2663
2702
  var n = 0;
2664
2703
  if (!e || !e.parentNode) return -1;
2665
- for (; e = e.previousElementSibling;) e.nodeName.toUpperCase() !== "TEMPLATE" && e !== Q.clone && (!t || ga(e, t)) && n++;
2704
+ for (; e = e.previousElementSibling;) e.nodeName.toUpperCase() !== "TEMPLATE" && e !== Q.clone && (!t || va(e, t)) && n++;
2666
2705
  return n;
2667
2706
  }
2668
- function Da(e) {
2669
- var t = 0, n = 0, r = Sa();
2707
+ function ka(e) {
2708
+ var t = 0, n = 0, r = wa();
2670
2709
  if (e) do {
2671
- var i = ba(e), a = i.a, o = i.d;
2710
+ var i = Sa(e), a = i.a, o = i.d;
2672
2711
  t += e.scrollLeft * a, n += e.scrollTop * o;
2673
2712
  } while (e !== r && (e = e.parentNode));
2674
2713
  return [t, n];
2675
2714
  }
2676
- function Oa(e, t) {
2715
+ function Aa(e, t) {
2677
2716
  for (var n in e) if (e.hasOwnProperty(n)) {
2678
2717
  for (var r in t) if (t.hasOwnProperty(r) && t[r] === e[n][r]) return Number(n);
2679
2718
  }
2680
2719
  return -1;
2681
2720
  }
2682
- function ka(e, t) {
2683
- if (!e || !e.getBoundingClientRect) return Sa();
2721
+ function ja(e, t) {
2722
+ if (!e || !e.getBoundingClientRect) return wa();
2684
2723
  var n = e, r = !1;
2685
2724
  do
2686
2725
  if (n.clientWidth < n.scrollWidth || n.clientHeight < n.scrollHeight) {
2687
- var i = z(n);
2726
+ var i = B(n);
2688
2727
  if (n.clientWidth < n.scrollWidth && (i.overflowX == "auto" || i.overflowX == "scroll") || n.clientHeight < n.scrollHeight && (i.overflowY == "auto" || i.overflowY == "scroll")) {
2689
- if (!n.getBoundingClientRect || n === document.body) return Sa();
2728
+ if (!n.getBoundingClientRect || n === document.body) return wa();
2690
2729
  if (r || t) return n;
2691
2730
  r = !0;
2692
2731
  }
2693
2732
  }
2694
2733
  while (n = n.parentNode);
2695
- return Sa();
2734
+ return wa();
2696
2735
  }
2697
- function Aa(e, t) {
2736
+ function Ma(e, t) {
2698
2737
  if (e && t) for (var n in t) t.hasOwnProperty(n) && (e[n] = t[n]);
2699
2738
  return e;
2700
2739
  }
2701
- function ja(e, t) {
2740
+ function Na(e, t) {
2702
2741
  return Math.round(e.top) === Math.round(t.top) && Math.round(e.left) === Math.round(t.left) && Math.round(e.height) === Math.round(t.height) && Math.round(e.width) === Math.round(t.width);
2703
2742
  }
2704
- var Ma;
2705
- function Na(e, t) {
2743
+ var Pa;
2744
+ function Fa(e, t) {
2706
2745
  return function() {
2707
- if (!Ma) {
2746
+ if (!Pa) {
2708
2747
  var n = arguments, r = this;
2709
- n.length === 1 ? e.call(r, n[0]) : e.apply(r, n), Ma = setTimeout(function() {
2710
- Ma = void 0;
2748
+ n.length === 1 ? e.call(r, n[0]) : e.apply(r, n), Pa = setTimeout(function() {
2749
+ Pa = void 0;
2711
2750
  }, t);
2712
2751
  }
2713
2752
  };
2714
2753
  }
2715
- function Pa() {
2716
- clearTimeout(Ma), Ma = void 0;
2754
+ function Ia() {
2755
+ clearTimeout(Pa), Pa = void 0;
2717
2756
  }
2718
- function Fa(e, t, n) {
2757
+ function La(e, t, n) {
2719
2758
  e.scrollLeft += t, e.scrollTop += n;
2720
2759
  }
2721
- function Ia(e) {
2760
+ function Ra(e) {
2722
2761
  var t = window.Polymer, n = window.jQuery || window.Zepto;
2723
2762
  return t && t.dom ? t.dom(e).cloneNode(!0) : n ? n(e).clone(!0)[0] : e.cloneNode(!0);
2724
2763
  }
2725
- function La(e, t, n) {
2764
+ function za(e, t, n) {
2726
2765
  var r = {};
2727
2766
  return Array.from(e.children).forEach(function(i) {
2728
- if (!(!va(i, t.draggable, e, !1) || i.animated || i === n)) {
2729
- var a = B(i);
2767
+ if (!(!ba(i, t.draggable, e, !1) || i.animated || i === n)) {
2768
+ var a = V(i);
2730
2769
  r.left = Math.min(r.left ?? Infinity, a.left), r.top = Math.min(r.top ?? Infinity, a.top), r.right = Math.max(r.right ?? -Infinity, a.right), r.bottom = Math.max(r.bottom ?? -Infinity, a.bottom);
2731
2770
  }
2732
2771
  }), r.width = r.right - r.left, r.height = r.bottom - r.top, r.x = r.left, r.y = r.top, r;
2733
2772
  }
2734
- var V = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
2735
- function Ra() {
2773
+ var H = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
2774
+ function Ba() {
2736
2775
  var e = [], t;
2737
2776
  return {
2738
2777
  captureAnimationState: function() {
2739
2778
  e = [], this.options.animation && [].slice.call(this.el.children).forEach(function(t) {
2740
- if (!(z(t, "display") === "none" || t === Q.ghost)) {
2779
+ if (!(B(t, "display") === "none" || t === Q.ghost)) {
2741
2780
  e.push({
2742
2781
  target: t,
2743
- rect: B(t)
2782
+ rect: V(t)
2744
2783
  });
2745
- var n = ta({}, e[e.length - 1].rect);
2784
+ var n = ra({}, e[e.length - 1].rect);
2746
2785
  if (t.thisAnimationDuration) {
2747
- var r = ba(t, !0);
2786
+ var r = Sa(t, !0);
2748
2787
  r && (n.top -= r.f, n.left -= r.e);
2749
2788
  }
2750
2789
  t.fromRect = n;
@@ -2755,7 +2794,7 @@ function Ra() {
2755
2794
  e.push(t);
2756
2795
  },
2757
2796
  removeAnimationState: function(t) {
2758
- e.splice(Oa(e, { target: t }), 1);
2797
+ e.splice(Aa(e, { target: t }), 1);
2759
2798
  },
2760
2799
  animateAll: function(n) {
2761
2800
  var r = this;
@@ -2765,8 +2804,8 @@ function Ra() {
2765
2804
  }
2766
2805
  var i = !1, a = 0;
2767
2806
  e.forEach(function(e) {
2768
- var t = 0, n = e.target, o = n.fromRect, s = B(n), c = n.prevFromRect, l = n.prevToRect, u = e.rect, d = ba(n, !0);
2769
- d && (s.top -= d.f, s.left -= d.e), n.toRect = s, n.thisAnimationDuration && ja(c, s) && !ja(o, s) && (u.top - s.top) / (u.left - s.left) === (o.top - s.top) / (o.left - s.left) && (t = Ba(u, c, l, r.options)), ja(s, o) || (n.prevFromRect = o, n.prevToRect = s, t ||= r.options.animation, r.animate(n, u, s, t)), t && (i = !0, a = Math.max(a, t), clearTimeout(n.animationResetTimer), n.animationResetTimer = setTimeout(function() {
2807
+ var t = 0, n = e.target, o = n.fromRect, s = V(n), c = n.prevFromRect, l = n.prevToRect, u = e.rect, d = Sa(n, !0);
2808
+ d && (s.top -= d.f, s.left -= d.e), n.toRect = s, n.thisAnimationDuration && Na(c, s) && !Na(o, s) && (u.top - s.top) / (u.left - s.left) === (o.top - s.top) / (o.left - s.left) && (t = Ha(u, c, l, r.options)), Na(s, o) || (n.prevFromRect = o, n.prevToRect = s, t ||= r.options.animation, r.animate(n, u, s, t)), t && (i = !0, a = Math.max(a, t), clearTimeout(n.animationResetTimer), n.animationResetTimer = setTimeout(function() {
2770
2809
  n.animationTime = 0, n.prevFromRect = null, n.fromRect = null, n.prevToRect = null, n.thisAnimationDuration = null;
2771
2810
  }, t), n.thisAnimationDuration = t);
2772
2811
  }), clearTimeout(t), i ? t = setTimeout(function() {
@@ -2775,27 +2814,27 @@ function Ra() {
2775
2814
  },
2776
2815
  animate: function(e, t, n, r) {
2777
2816
  if (r) {
2778
- z(e, "transition", ""), z(e, "transform", "");
2779
- var i = ba(this.el), a = i && i.a, o = i && i.d, s = (t.left - n.left) / (a || 1), c = (t.top - n.top) / (o || 1);
2780
- e.animatingX = !!s, e.animatingY = !!c, z(e, "transform", "translate3d(" + s + "px," + c + "px,0)"), this.forRepaintDummy = za(e), z(e, "transition", "transform " + r + "ms" + (this.options.easing ? " " + this.options.easing : "")), z(e, "transform", "translate3d(0,0,0)"), typeof e.animated == "number" && clearTimeout(e.animated), e.animated = setTimeout(function() {
2781
- z(e, "transition", ""), z(e, "transform", ""), e.animated = !1, e.animatingX = !1, e.animatingY = !1;
2817
+ B(e, "transition", ""), B(e, "transform", "");
2818
+ var i = Sa(this.el), a = i && i.a, o = i && i.d, s = (t.left - n.left) / (a || 1), c = (t.top - n.top) / (o || 1);
2819
+ e.animatingX = !!s, e.animatingY = !!c, B(e, "transform", "translate3d(" + s + "px," + c + "px,0)"), this.forRepaintDummy = Va(e), B(e, "transition", "transform " + r + "ms" + (this.options.easing ? " " + this.options.easing : "")), B(e, "transform", "translate3d(0,0,0)"), typeof e.animated == "number" && clearTimeout(e.animated), e.animated = setTimeout(function() {
2820
+ B(e, "transition", ""), B(e, "transform", ""), e.animated = !1, e.animatingX = !1, e.animatingY = !1;
2782
2821
  }, r);
2783
2822
  }
2784
2823
  }
2785
2824
  };
2786
2825
  }
2787
- function za(e) {
2826
+ function Va(e) {
2788
2827
  return e.offsetWidth;
2789
2828
  }
2790
- function Ba(e, t, n, r) {
2829
+ function Ha(e, t, n, r) {
2791
2830
  return Math.sqrt((t.top - e.top) ** 2 + (t.left - e.left) ** 2) / Math.sqrt((t.top - n.top) ** 2 + (t.left - n.left) ** 2) * r.animation;
2792
2831
  }
2793
- var Va = [], Ha = { initializeByDefault: !0 }, Ua = {
2832
+ var Ua = [], Wa = { initializeByDefault: !0 }, Ga = {
2794
2833
  mount: function(e) {
2795
- for (var t in Ha) Ha.hasOwnProperty(t) && !(t in e) && (e[t] = Ha[t]);
2796
- Va.forEach(function(t) {
2834
+ for (var t in Wa) Wa.hasOwnProperty(t) && !(t in e) && (e[t] = Wa[t]);
2835
+ Ua.forEach(function(t) {
2797
2836
  if (t.pluginName === e.pluginName) throw `Sortable: Cannot mount plugin ${e.pluginName} more than once`;
2798
- }), Va.push(e);
2837
+ }), Ua.push(e);
2799
2838
  },
2800
2839
  pluginEvent: function(e, t, n) {
2801
2840
  var r = this;
@@ -2803,16 +2842,16 @@ var Va = [], Ha = { initializeByDefault: !0 }, Ua = {
2803
2842
  r.eventCanceled = !0;
2804
2843
  };
2805
2844
  var i = e + "Global";
2806
- Va.forEach(function(r) {
2807
- t[r.pluginName] && (t[r.pluginName][i] && t[r.pluginName][i](ta({ sortable: t }, n)), t.options[r.pluginName] && t[r.pluginName][e] && t[r.pluginName][e](ta({ sortable: t }, n)));
2845
+ Ua.forEach(function(r) {
2846
+ t[r.pluginName] && (t[r.pluginName][i] && t[r.pluginName][i](ra({ sortable: t }, n)), t.options[r.pluginName] && t[r.pluginName][e] && t[r.pluginName][e](ra({ sortable: t }, n)));
2808
2847
  });
2809
2848
  },
2810
2849
  initializePlugins: function(e, t, n, r) {
2811
- for (var i in Va.forEach(function(r) {
2850
+ for (var i in Ua.forEach(function(r) {
2812
2851
  var i = r.pluginName;
2813
2852
  if (!(!e.options[i] && !r.initializeByDefault)) {
2814
2853
  var a = new r(e, t, e.options);
2815
- a.sortable = e, a.options = e.options, e[i] = a, ia(n, a.defaults);
2854
+ a.sortable = e, a.options = e.options, e[i] = a, oa(n, a.defaults);
2816
2855
  }
2817
2856
  }), e.options) if (e.options.hasOwnProperty(i)) {
2818
2857
  var a = this.modifyOption(e, i, e.options[i]);
@@ -2821,59 +2860,59 @@ var Va = [], Ha = { initializeByDefault: !0 }, Ua = {
2821
2860
  },
2822
2861
  getEventProperties: function(e, t) {
2823
2862
  var n = {};
2824
- return Va.forEach(function(r) {
2825
- typeof r.eventProperties == "function" && ia(n, r.eventProperties.call(t[r.pluginName], e));
2863
+ return Ua.forEach(function(r) {
2864
+ typeof r.eventProperties == "function" && oa(n, r.eventProperties.call(t[r.pluginName], e));
2826
2865
  }), n;
2827
2866
  },
2828
2867
  modifyOption: function(e, t, n) {
2829
2868
  var r;
2830
- return Va.forEach(function(i) {
2869
+ return Ua.forEach(function(i) {
2831
2870
  e[i.pluginName] && i.optionListeners && typeof i.optionListeners[t] == "function" && (r = i.optionListeners[t].call(e[i.pluginName], n));
2832
2871
  }), r;
2833
2872
  }
2834
2873
  };
2835
- function Wa(e) {
2874
+ function Ka(e) {
2836
2875
  var t = e.sortable, n = e.rootEl, r = e.name, i = e.targetEl, a = e.cloneEl, o = e.toEl, s = e.fromEl, c = e.oldIndex, l = e.newIndex, u = e.oldDraggableIndex, d = e.newDraggableIndex, f = e.originalEvent, p = e.putSortable, m = e.extraEventProperties;
2837
- if (t ||= n && n[V], t) {
2876
+ if (t ||= n && n[H], t) {
2838
2877
  var h, g = t.options, _ = "on" + r.charAt(0).toUpperCase() + r.substr(1);
2839
- window.CustomEvent && !la && !ua ? h = new CustomEvent(r, {
2878
+ window.CustomEvent && !da && !fa ? h = new CustomEvent(r, {
2840
2879
  bubbles: !0,
2841
2880
  cancelable: !0
2842
2881
  }) : (h = document.createEvent("Event"), h.initEvent(r, !0, !0)), h.to = o || n, h.from = s || n, h.item = i || n, h.clone = a, h.oldIndex = c, h.newIndex = l, h.oldDraggableIndex = u, h.newDraggableIndex = d, h.originalEvent = f, h.pullMode = p ? p.lastPutMode : void 0;
2843
- var v = ta(ta({}, m), Ua.getEventProperties(r, t));
2882
+ var v = ra(ra({}, m), Ga.getEventProperties(r, t));
2844
2883
  for (var y in v) h[y] = v[y];
2845
2884
  n && n.dispatchEvent(h), g[_] && g[_].call(t, h);
2846
2885
  }
2847
2886
  }
2848
- var Ga = ["evt"], H = function(e, t) {
2849
- var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, r = n.evt, i = oa(n, Ga);
2850
- Ua.pluginEvent.bind(Q)(e, t, ta({
2851
- dragEl: W,
2852
- parentEl: G,
2853
- ghostEl: K,
2854
- rootEl: q,
2855
- nextEl: Ka,
2856
- lastDownEl: qa,
2857
- cloneEl: J,
2858
- cloneHidden: Ja,
2859
- dragStarted: co,
2887
+ var qa = ["evt"], U = function(e, t) {
2888
+ var n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, r = n.evt, i = ca(n, qa);
2889
+ Ga.pluginEvent.bind(Q)(e, t, ra({
2890
+ dragEl: G,
2891
+ parentEl: K,
2892
+ ghostEl: q,
2893
+ rootEl: J,
2894
+ nextEl: Ja,
2895
+ lastDownEl: Ya,
2896
+ cloneEl: Y,
2897
+ cloneHidden: Xa,
2898
+ dragStarted: fo,
2860
2899
  putSortable: X,
2861
2900
  activeSortable: Q.active,
2862
2901
  originalEvent: r,
2863
- oldIndex: Ya,
2864
- oldDraggableIndex: Xa,
2865
- newIndex: Y,
2866
- newDraggableIndex: Za,
2867
- hideGhostForTarget: Do,
2868
- unhideGhostForTarget: Oo,
2902
+ oldIndex: Za,
2903
+ oldDraggableIndex: $a,
2904
+ newIndex: Qa,
2905
+ newDraggableIndex: eo,
2906
+ hideGhostForTarget: Ao,
2907
+ unhideGhostForTarget: jo,
2869
2908
  cloneNowHidden: function() {
2870
- Ja = !0;
2909
+ Xa = !0;
2871
2910
  },
2872
2911
  cloneNowShown: function() {
2873
- Ja = !1;
2912
+ Xa = !1;
2874
2913
  },
2875
2914
  dispatchSortableEvent: function(e) {
2876
- U({
2915
+ W({
2877
2916
  sortable: t,
2878
2917
  name: e,
2879
2918
  originalEvent: r
@@ -2881,46 +2920,46 @@ var Ga = ["evt"], H = function(e, t) {
2881
2920
  }
2882
2921
  }, i));
2883
2922
  };
2884
- function U(e) {
2885
- Wa(ta({
2923
+ function W(e) {
2924
+ Ka(ra({
2886
2925
  putSortable: X,
2887
- cloneEl: J,
2888
- targetEl: W,
2889
- rootEl: q,
2890
- oldIndex: Ya,
2891
- oldDraggableIndex: Xa,
2892
- newIndex: Y,
2893
- newDraggableIndex: Za
2926
+ cloneEl: Y,
2927
+ targetEl: G,
2928
+ rootEl: J,
2929
+ oldIndex: Za,
2930
+ oldDraggableIndex: $a,
2931
+ newIndex: Qa,
2932
+ newDraggableIndex: eo
2894
2933
  }, e));
2895
2934
  }
2896
- var W, G, K, q, Ka, qa, J, Ja, Ya, Y, Xa, Za, Qa, X, $a = !1, eo = !1, to = [], no, ro, io, ao, oo, so, co, lo, uo, fo = !1, po = !1, mo, Z, ho = [], go = !1, _o = [], vo = typeof document < "u", yo = pa, bo = ua || la ? "cssFloat" : "float", xo = vo && !ma && !pa && "draggable" in document.createElement("div"), So = function() {
2897
- if (vo) {
2898
- if (la) return !1;
2935
+ var G, K, q, J, Ja, Ya, Y, Xa, Za, Qa, $a, eo, to, X, no = !1, ro = !1, io = [], ao, oo, so, co, lo, uo, fo, po, mo, ho = !1, go = !1, _o, Z, vo = [], yo = !1, bo = [], xo = typeof document < "u", So = ha, Co = fa || da ? "cssFloat" : "float", wo = xo && !ga && !ha && "draggable" in document.createElement("div"), To = function() {
2936
+ if (xo) {
2937
+ if (da) return !1;
2899
2938
  var e = document.createElement("x");
2900
2939
  return e.style.cssText = "pointer-events:auto", e.style.pointerEvents === "auto";
2901
2940
  }
2902
- }(), Co = function(e, t) {
2903
- var n = z(e), r = parseInt(n.width) - parseInt(n.paddingLeft) - parseInt(n.paddingRight) - parseInt(n.borderLeftWidth) - parseInt(n.borderRightWidth), i = wa(e, 0, t), a = wa(e, 1, t), o = i && z(i), s = a && z(a), c = o && parseInt(o.marginLeft) + parseInt(o.marginRight) + B(i).width, l = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + B(a).width;
2941
+ }(), Eo = function(e, t) {
2942
+ var n = B(e), r = parseInt(n.width) - parseInt(n.paddingLeft) - parseInt(n.paddingRight) - parseInt(n.borderLeftWidth) - parseInt(n.borderRightWidth), i = Ea(e, 0, t), a = Ea(e, 1, t), o = i && B(i), s = a && B(a), c = o && parseInt(o.marginLeft) + parseInt(o.marginRight) + V(i).width, l = s && parseInt(s.marginLeft) + parseInt(s.marginRight) + V(a).width;
2904
2943
  if (n.display === "flex") return n.flexDirection === "column" || n.flexDirection === "column-reverse" ? "vertical" : "horizontal";
2905
2944
  if (n.display === "grid") return n.gridTemplateColumns.split(" ").length <= 1 ? "vertical" : "horizontal";
2906
2945
  if (i && o.float && o.float !== "none") {
2907
2946
  var u = o.float === "left" ? "left" : "right";
2908
2947
  return a && (s.clear === "both" || s.clear === u) ? "vertical" : "horizontal";
2909
2948
  }
2910
- return i && (o.display === "block" || o.display === "flex" || o.display === "table" || o.display === "grid" || c >= r && n[bo] === "none" || a && n[bo] === "none" && c + l > r) ? "vertical" : "horizontal";
2911
- }, wo = function(e, t, n) {
2949
+ return i && (o.display === "block" || o.display === "flex" || o.display === "table" || o.display === "grid" || c >= r && n[Co] === "none" || a && n[Co] === "none" && c + l > r) ? "vertical" : "horizontal";
2950
+ }, Do = function(e, t, n) {
2912
2951
  var r = n ? e.left : e.top, i = n ? e.right : e.bottom, a = n ? e.width : e.height, o = n ? t.left : t.top, s = n ? t.right : t.bottom, c = n ? t.width : t.height;
2913
2952
  return r === o || i === s || r + a / 2 === o + c / 2;
2914
- }, To = function(e, t) {
2953
+ }, Oo = function(e, t) {
2915
2954
  var n;
2916
- return to.some(function(r) {
2917
- var i = r[V].options.emptyInsertThreshold;
2918
- if (!(!i || Ta(r))) {
2919
- var a = B(r), o = e >= a.left - i && e <= a.right + i, s = t >= a.top - i && t <= a.bottom + i;
2955
+ return io.some(function(r) {
2956
+ var i = r[H].options.emptyInsertThreshold;
2957
+ if (!(!i || Da(r))) {
2958
+ var a = V(r), o = e >= a.left - i && e <= a.right + i, s = t >= a.top - i && t <= a.bottom + i;
2920
2959
  if (o && s) return n = r;
2921
2960
  }
2922
2961
  }), n;
2923
- }, Eo = function(e) {
2962
+ }, ko = function(e) {
2924
2963
  function t(e, n) {
2925
2964
  return function(r, i, a, o) {
2926
2965
  var s = r.options.group.name && i.options.group.name && r.options.group.name === i.options.group.name;
@@ -2933,31 +2972,31 @@ var W, G, K, q, Ka, qa, J, Ja, Ya, Y, Xa, Za, Qa, X, $a = !1, eo = !1, to = [],
2933
2972
  };
2934
2973
  }
2935
2974
  var n = {}, r = e.group;
2936
- (!r || na(r) != "object") && (r = { name: r }), n.name = r.name, n.checkPull = t(r.pull, !0), n.checkPut = t(r.put), n.revertClone = r.revertClone, e.group = n;
2937
- }, Do = function() {
2938
- !So && K && z(K, "display", "none");
2939
- }, Oo = function() {
2940
- !So && K && z(K, "display", "");
2975
+ (!r || ia(r) != "object") && (r = { name: r }), n.name = r.name, n.checkPull = t(r.pull, !0), n.checkPut = t(r.put), n.revertClone = r.revertClone, e.group = n;
2976
+ }, Ao = function() {
2977
+ !To && q && B(q, "display", "none");
2978
+ }, jo = function() {
2979
+ !To && q && B(q, "display", "");
2941
2980
  };
2942
- vo && !ma && document.addEventListener("click", function(e) {
2943
- if (eo) return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(), eo = !1, !1;
2981
+ xo && !ga && document.addEventListener("click", function(e) {
2982
+ if (ro) return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(), ro = !1, !1;
2944
2983
  }, !0);
2945
- var ko = function(e) {
2946
- if (W) {
2984
+ var Mo = function(e) {
2985
+ if (G) {
2947
2986
  e = e.touches ? e.touches[0] : e;
2948
- var t = To(e.clientX, e.clientY);
2987
+ var t = Oo(e.clientX, e.clientY);
2949
2988
  if (t) {
2950
2989
  var n = {};
2951
2990
  for (var r in e) e.hasOwnProperty(r) && (n[r] = e[r]);
2952
- n.target = n.rootEl = t, n.preventDefault = void 0, n.stopPropagation = void 0, t[V]._onDragOver(n);
2991
+ n.target = n.rootEl = t, n.preventDefault = void 0, n.stopPropagation = void 0, t[H]._onDragOver(n);
2953
2992
  }
2954
2993
  }
2955
- }, Ao = function(e) {
2956
- W && W.parentNode[V]._isOutsideThisEl(e.target);
2994
+ }, No = function(e) {
2995
+ G && G.parentNode[H]._isOutsideThisEl(e.target);
2957
2996
  };
2958
2997
  function Q(e, t) {
2959
2998
  if (!(e && e.nodeType && e.nodeType === 1)) throw `Sortable: \`el\` must be an HTMLElement, not ${{}.toString.call(e)}`;
2960
- this.el = e, this.options = t = ia({}, t), e[V] = this;
2999
+ this.el = e, this.options = t = oa({}, t), e[H] = this;
2961
3000
  var n = {
2962
3001
  group: null,
2963
3002
  sort: !0,
@@ -2970,7 +3009,7 @@ function Q(e, t) {
2970
3009
  invertedSwapThreshold: null,
2971
3010
  removeCloneOnHide: !0,
2972
3011
  direction: function() {
2973
- return Co(e, this.options);
3012
+ return Eo(e, this.options);
2974
3013
  },
2975
3014
  ghostClass: "sortable-ghost",
2976
3015
  chosenClass: "sortable-chosen",
@@ -2997,80 +3036,80 @@ function Q(e, t) {
2997
3036
  x: 0,
2998
3037
  y: 0
2999
3038
  },
3000
- supportPointer: Q.supportPointer !== !1 && "PointerEvent" in window && !fa,
3039
+ supportPointer: Q.supportPointer !== !1 && "PointerEvent" in window && !ma,
3001
3040
  emptyInsertThreshold: 5
3002
3041
  };
3003
- for (var r in Ua.initializePlugins(this, e, n), n) !(r in t) && (t[r] = n[r]);
3004
- for (var i in Eo(t), this) i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
3005
- this.nativeDraggable = !t.forceFallback && xo, this.nativeDraggable && (this.options.touchStartThreshold = 1), t.supportPointer ? I(e, "pointerdown", this._onTapStart) : (I(e, "mousedown", this._onTapStart), I(e, "touchstart", this._onTapStart)), this.nativeDraggable && (I(e, "dragover", this), I(e, "dragenter", this)), to.push(this.el), t.store && t.store.get && this.sort(t.store.get(this) || []), ia(this, Ra());
3042
+ for (var r in Ga.initializePlugins(this, e, n), n) !(r in t) && (t[r] = n[r]);
3043
+ for (var i in ko(t), this) i.charAt(0) === "_" && typeof this[i] == "function" && (this[i] = this[i].bind(this));
3044
+ this.nativeDraggable = !t.forceFallback && wo, this.nativeDraggable && (this.options.touchStartThreshold = 1), t.supportPointer ? L(e, "pointerdown", this._onTapStart) : (L(e, "mousedown", this._onTapStart), L(e, "touchstart", this._onTapStart)), this.nativeDraggable && (L(e, "dragover", this), L(e, "dragenter", this)), io.push(this.el), t.store && t.store.get && this.sort(t.store.get(this) || []), oa(this, Ba());
3006
3045
  }
3007
3046
  Q.prototype = {
3008
3047
  constructor: Q,
3009
3048
  _isOutsideThisEl: function(e) {
3010
- !this.el.contains(e) && e !== this.el && (lo = null);
3049
+ !this.el.contains(e) && e !== this.el && (po = null);
3011
3050
  },
3012
3051
  _getDirection: function(e, t) {
3013
- return typeof this.options.direction == "function" ? this.options.direction.call(this, e, t, W) : this.options.direction;
3052
+ return typeof this.options.direction == "function" ? this.options.direction.call(this, e, t, G) : this.options.direction;
3014
3053
  },
3015
3054
  _onTapStart: function(e) {
3016
3055
  if (e.cancelable) {
3017
3056
  var t = this, n = this.el, r = this.options, i = r.preventOnFilter, a = e.type, o = e.touches && e.touches[0] || e.pointerType && e.pointerType === "touch" && e, s = (o || e).target, c = e.target.shadowRoot && (e.path && e.path[0] || e.composedPath && e.composedPath()[0]) || s, l = r.filter;
3018
- if (Bo(n), !W && !(/mousedown|pointerdown/.test(a) && e.button !== 0 || r.disabled) && !c.isContentEditable && !(!this.nativeDraggable && fa && s && s.tagName.toUpperCase() === "SELECT") && (s = va(s, r.draggable, n, !1), !(s && s.animated) && qa !== s)) {
3019
- if (Ya = Ea(s), Xa = Ea(s, r.draggable), typeof l == "function") {
3057
+ if (Uo(n), !G && !(/mousedown|pointerdown/.test(a) && e.button !== 0 || r.disabled) && !c.isContentEditable && !(!this.nativeDraggable && ma && s && s.tagName.toUpperCase() === "SELECT") && (s = ba(s, r.draggable, n, !1), !(s && s.animated) && Ya !== s)) {
3058
+ if (Za = Oa(s), $a = Oa(s, r.draggable), typeof l == "function") {
3020
3059
  if (l.call(this, e, s, this)) {
3021
- U({
3060
+ W({
3022
3061
  sortable: t,
3023
3062
  rootEl: c,
3024
3063
  name: "filter",
3025
3064
  targetEl: s,
3026
3065
  toEl: n,
3027
3066
  fromEl: n
3028
- }), H("filter", t, { evt: e }), i && e.cancelable && e.preventDefault();
3067
+ }), U("filter", t, { evt: e }), i && e.cancelable && e.preventDefault();
3029
3068
  return;
3030
3069
  }
3031
3070
  } else if (l && (l = l.split(",").some(function(r) {
3032
- if (r = va(c, r.trim(), n, !1), r) return U({
3071
+ if (r = ba(c, r.trim(), n, !1), r) return W({
3033
3072
  sortable: t,
3034
3073
  rootEl: r,
3035
3074
  name: "filter",
3036
3075
  targetEl: s,
3037
3076
  fromEl: n,
3038
3077
  toEl: n
3039
- }), H("filter", t, { evt: e }), !0;
3078
+ }), U("filter", t, { evt: e }), !0;
3040
3079
  }), l)) {
3041
3080
  i && e.cancelable && e.preventDefault();
3042
3081
  return;
3043
3082
  }
3044
- r.handle && !va(c, r.handle, n, !1) || this._prepareDragStart(e, o, s);
3083
+ r.handle && !ba(c, r.handle, n, !1) || this._prepareDragStart(e, o, s);
3045
3084
  }
3046
3085
  }
3047
3086
  },
3048
3087
  _prepareDragStart: function(e, t, n) {
3049
3088
  var r = this, i = r.el, a = r.options, o = i.ownerDocument, s;
3050
- if (n && !W && n.parentNode === i) {
3051
- var c = B(n);
3052
- if (q = i, W = n, G = W.parentNode, Ka = W.nextSibling, qa = n, Qa = a.group, Q.dragged = W, no = {
3053
- target: W,
3089
+ if (n && !G && n.parentNode === i) {
3090
+ var c = V(n);
3091
+ if (J = i, G = n, K = G.parentNode, Ja = G.nextSibling, Ya = n, to = a.group, Q.dragged = G, ao = {
3092
+ target: G,
3054
3093
  clientX: (t || e).clientX,
3055
3094
  clientY: (t || e).clientY
3056
- }, oo = no.clientX - c.left, so = no.clientY - c.top, this._lastX = (t || e).clientX, this._lastY = (t || e).clientY, W.style["will-change"] = "all", s = function() {
3057
- if (H("delayEnded", r, { evt: e }), Q.eventCanceled) {
3095
+ }, lo = ao.clientX - c.left, uo = ao.clientY - c.top, this._lastX = (t || e).clientX, this._lastY = (t || e).clientY, G.style["will-change"] = "all", s = function() {
3096
+ if (U("delayEnded", r, { evt: e }), Q.eventCanceled) {
3058
3097
  r._onDrop();
3059
3098
  return;
3060
3099
  }
3061
- r._disableDelayedDragEvents(), !da && r.nativeDraggable && (W.draggable = !0), r._triggerDragStart(e, t), U({
3100
+ r._disableDelayedDragEvents(), !pa && r.nativeDraggable && (G.draggable = !0), r._triggerDragStart(e, t), W({
3062
3101
  sortable: r,
3063
3102
  name: "choose",
3064
3103
  originalEvent: e
3065
- }), R(W, a.chosenClass, !0);
3104
+ }), z(G, a.chosenClass, !0);
3066
3105
  }, a.ignore.split(",").forEach(function(e) {
3067
- xa(W, e.trim(), No);
3068
- }), I(o, "dragover", ko), I(o, "mousemove", ko), I(o, "touchmove", ko), I(o, "mouseup", r._onDrop), I(o, "touchend", r._onDrop), I(o, "touchcancel", r._onDrop), da && this.nativeDraggable && (this.options.touchStartThreshold = 4, W.draggable = !0), H("delayStart", this, { evt: e }), a.delay && (!a.delayOnTouchOnly || t) && (!this.nativeDraggable || !(ua || la))) {
3106
+ Ca(G, e.trim(), Io);
3107
+ }), L(o, "dragover", Mo), L(o, "mousemove", Mo), L(o, "touchmove", Mo), L(o, "mouseup", r._onDrop), L(o, "touchend", r._onDrop), L(o, "touchcancel", r._onDrop), pa && this.nativeDraggable && (this.options.touchStartThreshold = 4, G.draggable = !0), U("delayStart", this, { evt: e }), a.delay && (!a.delayOnTouchOnly || t) && (!this.nativeDraggable || !(fa || da))) {
3069
3108
  if (Q.eventCanceled) {
3070
3109
  this._onDrop();
3071
3110
  return;
3072
3111
  }
3073
- I(o, "mouseup", r._disableDelayedDrag), I(o, "touchend", r._disableDelayedDrag), I(o, "touchcancel", r._disableDelayedDrag), I(o, "mousemove", r._delayedDragTouchMoveHandler), I(o, "touchmove", r._delayedDragTouchMoveHandler), a.supportPointer && I(o, "pointermove", r._delayedDragTouchMoveHandler), r._dragStartTimer = setTimeout(s, a.delay);
3112
+ L(o, "mouseup", r._disableDelayedDrag), L(o, "touchend", r._disableDelayedDrag), L(o, "touchcancel", r._disableDelayedDrag), L(o, "mousemove", r._delayedDragTouchMoveHandler), L(o, "touchmove", r._delayedDragTouchMoveHandler), a.supportPointer && L(o, "pointermove", r._delayedDragTouchMoveHandler), r._dragStartTimer = setTimeout(s, a.delay);
3074
3113
  } else s();
3075
3114
  }
3076
3115
  },
@@ -3079,25 +3118,25 @@ Q.prototype = {
3079
3118
  Math.max(Math.abs(t.clientX - this._lastX), Math.abs(t.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1)) && this._disableDelayedDrag();
3080
3119
  },
3081
3120
  _disableDelayedDrag: function() {
3082
- W && No(W), clearTimeout(this._dragStartTimer), this._disableDelayedDragEvents();
3121
+ G && Io(G), clearTimeout(this._dragStartTimer), this._disableDelayedDragEvents();
3083
3122
  },
3084
3123
  _disableDelayedDragEvents: function() {
3085
3124
  var e = this.el.ownerDocument;
3086
- L(e, "mouseup", this._disableDelayedDrag), L(e, "touchend", this._disableDelayedDrag), L(e, "touchcancel", this._disableDelayedDrag), L(e, "mousemove", this._delayedDragTouchMoveHandler), L(e, "touchmove", this._delayedDragTouchMoveHandler), L(e, "pointermove", this._delayedDragTouchMoveHandler);
3125
+ R(e, "mouseup", this._disableDelayedDrag), R(e, "touchend", this._disableDelayedDrag), R(e, "touchcancel", this._disableDelayedDrag), R(e, "mousemove", this._delayedDragTouchMoveHandler), R(e, "touchmove", this._delayedDragTouchMoveHandler), R(e, "pointermove", this._delayedDragTouchMoveHandler);
3087
3126
  },
3088
3127
  _triggerDragStart: function(e, t) {
3089
- t ||= e.pointerType == "touch" && e, !this.nativeDraggable || t ? this.options.supportPointer ? I(document, "pointermove", this._onTouchMove) : t ? I(document, "touchmove", this._onTouchMove) : I(document, "mousemove", this._onTouchMove) : (I(W, "dragend", this), I(q, "dragstart", this._onDragStart));
3128
+ t ||= e.pointerType == "touch" && e, !this.nativeDraggable || t ? this.options.supportPointer ? L(document, "pointermove", this._onTouchMove) : t ? L(document, "touchmove", this._onTouchMove) : L(document, "mousemove", this._onTouchMove) : (L(G, "dragend", this), L(J, "dragstart", this._onDragStart));
3090
3129
  try {
3091
- document.selection ? Vo(function() {
3130
+ document.selection ? Wo(function() {
3092
3131
  document.selection.empty();
3093
3132
  }) : window.getSelection().removeAllRanges();
3094
3133
  } catch {}
3095
3134
  },
3096
3135
  _dragStarted: function(e, t) {
3097
- if ($a = !1, q && W) {
3098
- H("dragStarted", this, { evt: t }), this.nativeDraggable && I(document, "dragover", Ao);
3136
+ if (no = !1, J && G) {
3137
+ U("dragStarted", this, { evt: t }), this.nativeDraggable && L(document, "dragover", No);
3099
3138
  var n = this.options;
3100
- !e && R(W, n.dragClass, !1), R(W, n.ghostClass, !0), Q.active = this, e && this._appendGhost(), U({
3139
+ !e && z(G, n.dragClass, !1), z(G, n.ghostClass, !0), Q.active = this, e && this._appendGhost(), W({
3101
3140
  sortable: this,
3102
3141
  name: "start",
3103
3142
  originalEvent: t
@@ -3105,33 +3144,33 @@ Q.prototype = {
3105
3144
  } else this._nulling();
3106
3145
  },
3107
3146
  _emulateDragOver: function() {
3108
- if (ro) {
3109
- this._lastX = ro.clientX, this._lastY = ro.clientY, Do();
3110
- for (var e = document.elementFromPoint(ro.clientX, ro.clientY), t = e; e && e.shadowRoot && (e = e.shadowRoot.elementFromPoint(ro.clientX, ro.clientY), e !== t);) t = e;
3111
- if (W.parentNode[V]._isOutsideThisEl(e), t) do {
3112
- if (t[V]) {
3147
+ if (oo) {
3148
+ this._lastX = oo.clientX, this._lastY = oo.clientY, Ao();
3149
+ for (var e = document.elementFromPoint(oo.clientX, oo.clientY), t = e; e && e.shadowRoot && (e = e.shadowRoot.elementFromPoint(oo.clientX, oo.clientY), e !== t);) t = e;
3150
+ if (G.parentNode[H]._isOutsideThisEl(e), t) do {
3151
+ if (t[H]) {
3113
3152
  var n = void 0;
3114
- if (n = t[V]._onDragOver({
3115
- clientX: ro.clientX,
3116
- clientY: ro.clientY,
3153
+ if (n = t[H]._onDragOver({
3154
+ clientX: oo.clientX,
3155
+ clientY: oo.clientY,
3117
3156
  target: e,
3118
3157
  rootEl: t
3119
3158
  }), n && !this.options.dragoverBubble) break;
3120
3159
  }
3121
3160
  e = t;
3122
3161
  } while (t = t.parentNode);
3123
- Oo();
3162
+ jo();
3124
3163
  }
3125
3164
  },
3126
3165
  _onTouchMove: function(e) {
3127
- if (no) {
3128
- var t = this.options, n = t.fallbackTolerance, r = t.fallbackOffset, i = e.touches ? e.touches[0] : e, a = K && ba(K, !0), o = K && a && a.a, s = K && a && a.d, c = yo && Z && Da(Z), l = (i.clientX - no.clientX + r.x) / (o || 1) + (c ? c[0] - ho[0] : 0) / (o || 1), u = (i.clientY - no.clientY + r.y) / (s || 1) + (c ? c[1] - ho[1] : 0) / (s || 1);
3129
- if (!Q.active && !$a) {
3166
+ if (ao) {
3167
+ var t = this.options, n = t.fallbackTolerance, r = t.fallbackOffset, i = e.touches ? e.touches[0] : e, a = q && Sa(q, !0), o = q && a && a.a, s = q && a && a.d, c = So && Z && ka(Z), l = (i.clientX - ao.clientX + r.x) / (o || 1) + (c ? c[0] - vo[0] : 0) / (o || 1), u = (i.clientY - ao.clientY + r.y) / (s || 1) + (c ? c[1] - vo[1] : 0) / (s || 1);
3168
+ if (!Q.active && !no) {
3130
3169
  if (n && Math.max(Math.abs(i.clientX - this._lastX), Math.abs(i.clientY - this._lastY)) < n) return;
3131
3170
  this._onDragStart(e, !0);
3132
3171
  }
3133
- if (K) {
3134
- a ? (a.e += l - (io || 0), a.f += u - (ao || 0)) : a = {
3172
+ if (q) {
3173
+ a ? (a.e += l - (so || 0), a.f += u - (co || 0)) : a = {
3135
3174
  a: 1,
3136
3175
  b: 0,
3137
3176
  c: 0,
@@ -3140,39 +3179,39 @@ Q.prototype = {
3140
3179
  f: u
3141
3180
  };
3142
3181
  var d = `matrix(${a.a},${a.b},${a.c},${a.d},${a.e},${a.f})`;
3143
- z(K, "webkitTransform", d), z(K, "mozTransform", d), z(K, "msTransform", d), z(K, "transform", d), io = l, ao = u, ro = i;
3182
+ B(q, "webkitTransform", d), B(q, "mozTransform", d), B(q, "msTransform", d), B(q, "transform", d), so = l, co = u, oo = i;
3144
3183
  }
3145
3184
  e.cancelable && e.preventDefault();
3146
3185
  }
3147
3186
  },
3148
3187
  _appendGhost: function() {
3149
- if (!K) {
3150
- var e = this.options.fallbackOnBody ? document.body : q, t = B(W, !0, yo, !0, e), n = this.options;
3151
- if (yo) {
3152
- for (Z = e; z(Z, "position") === "static" && z(Z, "transform") === "none" && Z !== document;) Z = Z.parentNode;
3153
- Z !== document.body && Z !== document.documentElement ? (Z === document && (Z = Sa()), t.top += Z.scrollTop, t.left += Z.scrollLeft) : Z = Sa(), ho = Da(Z);
3188
+ if (!q) {
3189
+ var e = this.options.fallbackOnBody ? document.body : J, t = V(G, !0, So, !0, e), n = this.options;
3190
+ if (So) {
3191
+ for (Z = e; B(Z, "position") === "static" && B(Z, "transform") === "none" && Z !== document;) Z = Z.parentNode;
3192
+ Z !== document.body && Z !== document.documentElement ? (Z === document && (Z = wa()), t.top += Z.scrollTop, t.left += Z.scrollLeft) : Z = wa(), vo = ka(Z);
3154
3193
  }
3155
- K = W.cloneNode(!0), R(K, n.ghostClass, !1), R(K, n.fallbackClass, !0), R(K, n.dragClass, !0), z(K, "transition", ""), z(K, "transform", ""), z(K, "box-sizing", "border-box"), z(K, "margin", 0), z(K, "top", t.top), z(K, "left", t.left), z(K, "width", t.width), z(K, "height", t.height), z(K, "opacity", "0.8"), z(K, "position", yo ? "absolute" : "fixed"), z(K, "zIndex", "100000"), z(K, "pointerEvents", "none"), Q.ghost = K, e.appendChild(K), z(K, "transform-origin", oo / parseInt(K.style.width) * 100 + "% " + so / parseInt(K.style.height) * 100 + "%");
3194
+ q = G.cloneNode(!0), z(q, n.ghostClass, !1), z(q, n.fallbackClass, !0), z(q, n.dragClass, !0), B(q, "transition", ""), B(q, "transform", ""), B(q, "box-sizing", "border-box"), B(q, "margin", 0), B(q, "top", t.top), B(q, "left", t.left), B(q, "width", t.width), B(q, "height", t.height), B(q, "opacity", "0.8"), B(q, "position", So ? "absolute" : "fixed"), B(q, "zIndex", "100000"), B(q, "pointerEvents", "none"), Q.ghost = q, e.appendChild(q), B(q, "transform-origin", lo / parseInt(q.style.width) * 100 + "% " + uo / parseInt(q.style.height) * 100 + "%");
3156
3195
  }
3157
3196
  },
3158
3197
  _onDragStart: function(e, t) {
3159
3198
  var n = this, r = e.dataTransfer, i = n.options;
3160
- if (H("dragStart", this, { evt: e }), Q.eventCanceled) {
3199
+ if (U("dragStart", this, { evt: e }), Q.eventCanceled) {
3161
3200
  this._onDrop();
3162
3201
  return;
3163
3202
  }
3164
- H("setupClone", this), Q.eventCanceled || (J = Ia(W), J.removeAttribute("id"), J.draggable = !1, J.style["will-change"] = "", this._hideClone(), R(J, this.options.chosenClass, !1), Q.clone = J), n.cloneId = Vo(function() {
3165
- H("clone", n), !Q.eventCanceled && (n.options.removeCloneOnHide || q.insertBefore(J, W), n._hideClone(), U({
3203
+ U("setupClone", this), Q.eventCanceled || (Y = Ra(G), Y.removeAttribute("id"), Y.draggable = !1, Y.style["will-change"] = "", this._hideClone(), z(Y, this.options.chosenClass, !1), Q.clone = Y), n.cloneId = Wo(function() {
3204
+ U("clone", n), !Q.eventCanceled && (n.options.removeCloneOnHide || J.insertBefore(Y, G), n._hideClone(), W({
3166
3205
  sortable: n,
3167
3206
  name: "clone"
3168
3207
  }));
3169
- }), !t && R(W, i.dragClass, !0), t ? (eo = !0, n._loopId = setInterval(n._emulateDragOver, 50)) : (L(document, "mouseup", n._onDrop), L(document, "touchend", n._onDrop), L(document, "touchcancel", n._onDrop), r && (r.effectAllowed = "move", i.setData && i.setData.call(n, r, W)), I(document, "drop", n), z(W, "transform", "translateZ(0)")), $a = !0, n._dragStartId = Vo(n._dragStarted.bind(n, t, e)), I(document, "selectstart", n), co = !0, fa && z(document.body, "user-select", "none");
3208
+ }), !t && z(G, i.dragClass, !0), t ? (ro = !0, n._loopId = setInterval(n._emulateDragOver, 50)) : (R(document, "mouseup", n._onDrop), R(document, "touchend", n._onDrop), R(document, "touchcancel", n._onDrop), r && (r.effectAllowed = "move", i.setData && i.setData.call(n, r, G)), L(document, "drop", n), B(G, "transform", "translateZ(0)")), no = !0, n._dragStartId = Wo(n._dragStarted.bind(n, t, e)), L(document, "selectstart", n), fo = !0, ma && B(document.body, "user-select", "none");
3170
3209
  },
3171
3210
  _onDragOver: function(e) {
3172
- var t = this.el, n = e.target, r, i, a, o = this.options, s = o.group, c = Q.active, l = Qa === s, u = o.sort, d = X || c, f, p = this, m = !1;
3173
- if (go) return;
3211
+ var t = this.el, n = e.target, r, i, a, o = this.options, s = o.group, c = Q.active, l = to === s, u = o.sort, d = X || c, f, p = this, m = !1;
3212
+ if (yo) return;
3174
3213
  function h(o, s) {
3175
- H(o, p, ta({
3214
+ U(o, p, ra({
3176
3215
  evt: e,
3177
3216
  isOwner: l,
3178
3217
  axis: f ? "vertical" : "horizontal",
@@ -3184,7 +3223,7 @@ Q.prototype = {
3184
3223
  target: n,
3185
3224
  completed: _,
3186
3225
  onMove: function(n, i) {
3187
- return Mo(q, t, W, r, n, B(n), e, i);
3226
+ return Fo(J, t, G, r, n, V(n), e, i);
3188
3227
  },
3189
3228
  changed: v
3190
3229
  }, s));
@@ -3193,119 +3232,119 @@ Q.prototype = {
3193
3232
  h("dragOverAnimationCapture"), p.captureAnimationState(), p !== d && d.captureAnimationState();
3194
3233
  }
3195
3234
  function _(r) {
3196
- return h("dragOverCompleted", { insertion: r }), r && (l ? c._hideClone() : c._showClone(p), p !== d && (R(W, X ? X.options.ghostClass : c.options.ghostClass, !1), R(W, o.ghostClass, !0)), X !== p && p !== Q.active ? X = p : p === Q.active && X && (X = null), d === p && (p._ignoreWhileAnimating = n), p.animateAll(function() {
3235
+ return h("dragOverCompleted", { insertion: r }), r && (l ? c._hideClone() : c._showClone(p), p !== d && (z(G, X ? X.options.ghostClass : c.options.ghostClass, !1), z(G, o.ghostClass, !0)), X !== p && p !== Q.active ? X = p : p === Q.active && X && (X = null), d === p && (p._ignoreWhileAnimating = n), p.animateAll(function() {
3197
3236
  h("dragOverAnimationComplete"), p._ignoreWhileAnimating = null;
3198
- }), p !== d && (d.animateAll(), d._ignoreWhileAnimating = null)), (n === W && !W.animated || n === t && !n.animated) && (lo = null), !o.dragoverBubble && !e.rootEl && n !== document && (W.parentNode[V]._isOutsideThisEl(e.target), !r && ko(e)), !o.dragoverBubble && e.stopPropagation && e.stopPropagation(), m = !0;
3237
+ }), p !== d && (d.animateAll(), d._ignoreWhileAnimating = null)), (n === G && !G.animated || n === t && !n.animated) && (po = null), !o.dragoverBubble && !e.rootEl && n !== document && (G.parentNode[H]._isOutsideThisEl(e.target), !r && Mo(e)), !o.dragoverBubble && e.stopPropagation && e.stopPropagation(), m = !0;
3199
3238
  }
3200
3239
  function v() {
3201
- Y = Ea(W), Za = Ea(W, o.draggable), U({
3240
+ Qa = Oa(G), eo = Oa(G, o.draggable), W({
3202
3241
  sortable: p,
3203
3242
  name: "change",
3204
3243
  toEl: t,
3205
- newIndex: Y,
3206
- newDraggableIndex: Za,
3244
+ newIndex: Qa,
3245
+ newDraggableIndex: eo,
3207
3246
  originalEvent: e
3208
3247
  });
3209
3248
  }
3210
- if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), n = va(n, o.draggable, t, !0), h("dragOver"), Q.eventCanceled) return m;
3211
- if (W.contains(e.target) || n.animated && n.animatingX && n.animatingY || p._ignoreWhileAnimating === n) return _(!1);
3212
- if (eo = !1, c && !o.disabled && (l ? u || (a = G !== q) : X === this || (this.lastPutMode = Qa.checkPull(this, c, W, e)) && s.checkPut(this, c, W, e))) {
3213
- if (f = this._getDirection(e, n) === "vertical", r = B(W), h("dragOverValid"), Q.eventCanceled) return m;
3214
- if (a) return G = q, g(), this._hideClone(), h("revert"), Q.eventCanceled || (Ka ? q.insertBefore(W, Ka) : q.appendChild(W)), _(!0);
3215
- var y = Ta(t, o.draggable);
3216
- if (!y || Io(e, f, this) && !y.animated) {
3217
- if (y === W) return _(!1);
3218
- if (y && t === e.target && (n = y), n && (i = B(n)), Mo(q, t, W, r, n, i, e, !!n) !== !1) return g(), y && y.nextSibling ? t.insertBefore(W, y.nextSibling) : t.appendChild(W), G = t, v(), _(!0);
3219
- } else if (y && Fo(e, f, this)) {
3220
- var b = wa(t, 0, o, !0);
3221
- if (b === W) return _(!1);
3222
- if (n = b, i = B(n), Mo(q, t, W, r, n, i, e, !1) !== !1) return g(), t.insertBefore(W, b), G = t, v(), _(!0);
3249
+ if (e.preventDefault !== void 0 && e.cancelable && e.preventDefault(), n = ba(n, o.draggable, t, !0), h("dragOver"), Q.eventCanceled) return m;
3250
+ if (G.contains(e.target) || n.animated && n.animatingX && n.animatingY || p._ignoreWhileAnimating === n) return _(!1);
3251
+ if (ro = !1, c && !o.disabled && (l ? u || (a = K !== J) : X === this || (this.lastPutMode = to.checkPull(this, c, G, e)) && s.checkPut(this, c, G, e))) {
3252
+ if (f = this._getDirection(e, n) === "vertical", r = V(G), h("dragOverValid"), Q.eventCanceled) return m;
3253
+ if (a) return K = J, g(), this._hideClone(), h("revert"), Q.eventCanceled || (Ja ? J.insertBefore(G, Ja) : J.appendChild(G)), _(!0);
3254
+ var y = Da(t, o.draggable);
3255
+ if (!y || zo(e, f, this) && !y.animated) {
3256
+ if (y === G) return _(!1);
3257
+ if (y && t === e.target && (n = y), n && (i = V(n)), Fo(J, t, G, r, n, i, e, !!n) !== !1) return g(), y && y.nextSibling ? t.insertBefore(G, y.nextSibling) : t.appendChild(G), K = t, v(), _(!0);
3258
+ } else if (y && Ro(e, f, this)) {
3259
+ var b = Ea(t, 0, o, !0);
3260
+ if (b === G) return _(!1);
3261
+ if (n = b, i = V(n), Fo(J, t, G, r, n, i, e, !1) !== !1) return g(), t.insertBefore(G, b), K = t, v(), _(!0);
3223
3262
  } else if (n.parentNode === t) {
3224
- i = B(n);
3225
- var x = 0, S, C = W.parentNode !== t, w = !wo(W.animated && W.toRect || r, n.animated && n.toRect || i, f), T = f ? "top" : "left", E = Ca(n, "top", "top") || Ca(W, "top", "top"), D = E ? E.scrollTop : void 0;
3226
- lo !== n && (S = i[T], fo = !1, po = !w && o.invertSwap || C), x = Lo(e, n, i, f, w ? 1 : o.swapThreshold, o.invertedSwapThreshold == null ? o.swapThreshold : o.invertedSwapThreshold, po, lo === n);
3263
+ i = V(n);
3264
+ var x = 0, S, C = G.parentNode !== t, w = !Do(G.animated && G.toRect || r, n.animated && n.toRect || i, f), T = f ? "top" : "left", E = Ta(n, "top", "top") || Ta(G, "top", "top"), D = E ? E.scrollTop : void 0;
3265
+ po !== n && (S = i[T], ho = !1, go = !w && o.invertSwap || C), x = Bo(e, n, i, f, w ? 1 : o.swapThreshold, o.invertedSwapThreshold == null ? o.swapThreshold : o.invertedSwapThreshold, go, po === n);
3227
3266
  var O;
3228
3267
  if (x !== 0) {
3229
- var k = Ea(W);
3268
+ var k = Oa(G);
3230
3269
  do
3231
- k -= x, O = G.children[k];
3232
- while (O && (z(O, "display") === "none" || O === K));
3270
+ k -= x, O = K.children[k];
3271
+ while (O && (B(O, "display") === "none" || O === q));
3233
3272
  }
3234
3273
  if (x === 0 || O === n) return _(!1);
3235
- lo = n, uo = x;
3236
- var ee = n.nextElementSibling, A = !1;
3237
- A = x === 1;
3238
- var te = Mo(q, t, W, r, n, i, e, A);
3239
- if (te !== !1) return (te === 1 || te === -1) && (A = te === 1), go = !0, setTimeout(Po, 30), g(), A && !ee ? t.appendChild(W) : n.parentNode.insertBefore(W, A ? ee : n), E && Fa(E, 0, D - E.scrollTop), G = W.parentNode, S !== void 0 && !po && (mo = Math.abs(S - B(n)[T])), v(), _(!0);
3274
+ po = n, mo = x;
3275
+ var A = n.nextElementSibling, j = !1;
3276
+ j = x === 1;
3277
+ var ee = Fo(J, t, G, r, n, i, e, j);
3278
+ if (ee !== !1) return (ee === 1 || ee === -1) && (j = ee === 1), yo = !0, setTimeout(Lo, 30), g(), j && !A ? t.appendChild(G) : n.parentNode.insertBefore(G, j ? A : n), E && La(E, 0, D - E.scrollTop), K = G.parentNode, S !== void 0 && !go && (_o = Math.abs(S - V(n)[T])), v(), _(!0);
3240
3279
  }
3241
- if (t.contains(W)) return _(!1);
3280
+ if (t.contains(G)) return _(!1);
3242
3281
  }
3243
3282
  return !1;
3244
3283
  },
3245
3284
  _ignoreWhileAnimating: null,
3246
3285
  _offMoveEvents: function() {
3247
- L(document, "mousemove", this._onTouchMove), L(document, "touchmove", this._onTouchMove), L(document, "pointermove", this._onTouchMove), L(document, "dragover", ko), L(document, "mousemove", ko), L(document, "touchmove", ko);
3286
+ R(document, "mousemove", this._onTouchMove), R(document, "touchmove", this._onTouchMove), R(document, "pointermove", this._onTouchMove), R(document, "dragover", Mo), R(document, "mousemove", Mo), R(document, "touchmove", Mo);
3248
3287
  },
3249
3288
  _offUpEvents: function() {
3250
3289
  var e = this.el.ownerDocument;
3251
- L(e, "mouseup", this._onDrop), L(e, "touchend", this._onDrop), L(e, "pointerup", this._onDrop), L(e, "touchcancel", this._onDrop), L(document, "selectstart", this);
3290
+ R(e, "mouseup", this._onDrop), R(e, "touchend", this._onDrop), R(e, "pointerup", this._onDrop), R(e, "touchcancel", this._onDrop), R(document, "selectstart", this);
3252
3291
  },
3253
3292
  _onDrop: function(e) {
3254
3293
  var t = this.el, n = this.options;
3255
- if (Y = Ea(W), Za = Ea(W, n.draggable), H("drop", this, { evt: e }), G = W && W.parentNode, Y = Ea(W), Za = Ea(W, n.draggable), Q.eventCanceled) {
3294
+ if (Qa = Oa(G), eo = Oa(G, n.draggable), U("drop", this, { evt: e }), K = G && G.parentNode, Qa = Oa(G), eo = Oa(G, n.draggable), Q.eventCanceled) {
3256
3295
  this._nulling();
3257
3296
  return;
3258
3297
  }
3259
- $a = !1, po = !1, fo = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), Ho(this.cloneId), Ho(this._dragStartId), this.nativeDraggable && (L(document, "drop", this), L(t, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), fa && z(document.body, "user-select", ""), z(W, "transform", ""), e && (co && (e.cancelable && e.preventDefault(), !n.dropBubble && e.stopPropagation()), K && K.parentNode && K.parentNode.removeChild(K), (q === G || X && X.lastPutMode !== "clone") && J && J.parentNode && J.parentNode.removeChild(J), W && (this.nativeDraggable && L(W, "dragend", this), No(W), W.style["will-change"] = "", co && !$a && R(W, X ? X.options.ghostClass : this.options.ghostClass, !1), R(W, this.options.chosenClass, !1), U({
3298
+ no = !1, go = !1, ho = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), Go(this.cloneId), Go(this._dragStartId), this.nativeDraggable && (R(document, "drop", this), R(t, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), ma && B(document.body, "user-select", ""), B(G, "transform", ""), e && (fo && (e.cancelable && e.preventDefault(), !n.dropBubble && e.stopPropagation()), q && q.parentNode && q.parentNode.removeChild(q), (J === K || X && X.lastPutMode !== "clone") && Y && Y.parentNode && Y.parentNode.removeChild(Y), G && (this.nativeDraggable && R(G, "dragend", this), Io(G), G.style["will-change"] = "", fo && !no && z(G, X ? X.options.ghostClass : this.options.ghostClass, !1), z(G, this.options.chosenClass, !1), W({
3260
3299
  sortable: this,
3261
3300
  name: "unchoose",
3262
- toEl: G,
3301
+ toEl: K,
3263
3302
  newIndex: null,
3264
3303
  newDraggableIndex: null,
3265
3304
  originalEvent: e
3266
- }), q === G ? Y !== Ya && Y >= 0 && (U({
3305
+ }), J === K ? Qa !== Za && Qa >= 0 && (W({
3267
3306
  sortable: this,
3268
3307
  name: "update",
3269
- toEl: G,
3308
+ toEl: K,
3270
3309
  originalEvent: e
3271
- }), U({
3310
+ }), W({
3272
3311
  sortable: this,
3273
3312
  name: "sort",
3274
- toEl: G,
3313
+ toEl: K,
3275
3314
  originalEvent: e
3276
- })) : (Y >= 0 && (U({
3277
- rootEl: G,
3315
+ })) : (Qa >= 0 && (W({
3316
+ rootEl: K,
3278
3317
  name: "add",
3279
- toEl: G,
3280
- fromEl: q,
3318
+ toEl: K,
3319
+ fromEl: J,
3281
3320
  originalEvent: e
3282
- }), U({
3321
+ }), W({
3283
3322
  sortable: this,
3284
3323
  name: "remove",
3285
- toEl: G,
3324
+ toEl: K,
3286
3325
  originalEvent: e
3287
- }), U({
3288
- rootEl: G,
3326
+ }), W({
3327
+ rootEl: K,
3289
3328
  name: "sort",
3290
- toEl: G,
3291
- fromEl: q,
3329
+ toEl: K,
3330
+ fromEl: J,
3292
3331
  originalEvent: e
3293
- }), U({
3332
+ }), W({
3294
3333
  sortable: this,
3295
3334
  name: "sort",
3296
- toEl: G,
3335
+ toEl: K,
3297
3336
  originalEvent: e
3298
- })), X && X.save()), Q.active && ((Y == null || Y === -1) && (Y = Ya, Za = Xa), U({
3337
+ })), X && X.save()), Q.active && ((Qa == null || Qa === -1) && (Qa = Za, eo = $a), W({
3299
3338
  sortable: this,
3300
3339
  name: "end",
3301
- toEl: G,
3340
+ toEl: K,
3302
3341
  originalEvent: e
3303
3342
  }), this.save()))), this._nulling();
3304
3343
  },
3305
3344
  _nulling: function() {
3306
- H("nulling", this), q = W = G = K = Ka = J = qa = Ja = no = ro = co = Y = Za = Ya = Xa = lo = uo = X = Qa = Q.dragged = Q.ghost = Q.clone = Q.active = null, _o.forEach(function(e) {
3345
+ U("nulling", this), J = G = K = q = Ja = Y = Ya = Xa = ao = oo = fo = Qa = eo = Za = $a = po = mo = X = to = Q.dragged = Q.ghost = Q.clone = Q.active = null, bo.forEach(function(e) {
3307
3346
  e.checked = !0;
3308
- }), _o.length = io = ao = 0;
3347
+ }), bo.length = so = co = 0;
3309
3348
  },
3310
3349
  handleEvent: function(e) {
3311
3350
  switch (e.type) {
@@ -3315,7 +3354,7 @@ Q.prototype = {
3315
3354
  break;
3316
3355
  case "dragenter":
3317
3356
  case "dragover":
3318
- W && (this._onDragOver(e), jo(e));
3357
+ G && (this._onDragOver(e), Po(e));
3319
3358
  break;
3320
3359
  case "selectstart":
3321
3360
  e.preventDefault();
@@ -3323,14 +3362,14 @@ Q.prototype = {
3323
3362
  }
3324
3363
  },
3325
3364
  toArray: function() {
3326
- for (var e = [], t, n = this.el.children, r = 0, i = n.length, a = this.options; r < i; r++) t = n[r], va(t, a.draggable, this.el, !1) && e.push(t.getAttribute(a.dataIdAttr) || zo(t));
3365
+ for (var e = [], t, n = this.el.children, r = 0, i = n.length, a = this.options; r < i; r++) t = n[r], ba(t, a.draggable, this.el, !1) && e.push(t.getAttribute(a.dataIdAttr) || Ho(t));
3327
3366
  return e;
3328
3367
  },
3329
3368
  sort: function(e, t) {
3330
3369
  var n = {}, r = this.el;
3331
3370
  this.toArray().forEach(function(e, t) {
3332
3371
  var i = r.children[t];
3333
- va(i, this.options.draggable, r, !1) && (n[e] = i);
3372
+ ba(i, this.options.draggable, r, !1) && (n[e] = i);
3334
3373
  }, this), t && this.captureAnimationState(), e.forEach(function(e) {
3335
3374
  n[e] && (r.removeChild(n[e]), r.appendChild(n[e]));
3336
3375
  }), t && this.animateAll();
@@ -3340,25 +3379,25 @@ Q.prototype = {
3340
3379
  e && e.set && e.set(this);
3341
3380
  },
3342
3381
  closest: function(e, t) {
3343
- return va(e, t || this.options.draggable, this.el, !1);
3382
+ return ba(e, t || this.options.draggable, this.el, !1);
3344
3383
  },
3345
3384
  option: function(e, t) {
3346
3385
  var n = this.options;
3347
3386
  if (t === void 0) return n[e];
3348
- var r = Ua.modifyOption(this, e, t);
3349
- r === void 0 ? n[e] = t : n[e] = r, e === "group" && Eo(n);
3387
+ var r = Ga.modifyOption(this, e, t);
3388
+ r === void 0 ? n[e] = t : n[e] = r, e === "group" && ko(n);
3350
3389
  },
3351
3390
  destroy: function() {
3352
- H("destroy", this);
3391
+ U("destroy", this);
3353
3392
  var e = this.el;
3354
- e[V] = null, L(e, "mousedown", this._onTapStart), L(e, "touchstart", this._onTapStart), L(e, "pointerdown", this._onTapStart), this.nativeDraggable && (L(e, "dragover", this), L(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(e) {
3393
+ e[H] = null, R(e, "mousedown", this._onTapStart), R(e, "touchstart", this._onTapStart), R(e, "pointerdown", this._onTapStart), this.nativeDraggable && (R(e, "dragover", this), R(e, "dragenter", this)), Array.prototype.forEach.call(e.querySelectorAll("[draggable]"), function(e) {
3355
3394
  e.removeAttribute("draggable");
3356
- }), this._onDrop(), this._disableDelayedDragEvents(), to.splice(to.indexOf(this.el), 1), this.el = e = null;
3395
+ }), this._onDrop(), this._disableDelayedDragEvents(), io.splice(io.indexOf(this.el), 1), this.el = e = null;
3357
3396
  },
3358
3397
  _hideClone: function() {
3359
- if (!Ja) {
3360
- if (H("hideClone", this), Q.eventCanceled) return;
3361
- z(J, "display", "none"), this.options.removeCloneOnHide && J.parentNode && J.parentNode.removeChild(J), Ja = !0;
3398
+ if (!Xa) {
3399
+ if (U("hideClone", this), Q.eventCanceled) return;
3400
+ B(Y, "display", "none"), this.options.removeCloneOnHide && Y.parentNode && Y.parentNode.removeChild(Y), Xa = !0;
3362
3401
  }
3363
3402
  },
3364
3403
  _showClone: function(e) {
@@ -3366,99 +3405,99 @@ Q.prototype = {
3366
3405
  this._hideClone();
3367
3406
  return;
3368
3407
  }
3369
- if (Ja) {
3370
- if (H("showClone", this), Q.eventCanceled) return;
3371
- W.parentNode == q && !this.options.group.revertClone ? q.insertBefore(J, W) : Ka ? q.insertBefore(J, Ka) : q.appendChild(J), this.options.group.revertClone && this.animate(W, J), z(J, "display", ""), Ja = !1;
3408
+ if (Xa) {
3409
+ if (U("showClone", this), Q.eventCanceled) return;
3410
+ G.parentNode == J && !this.options.group.revertClone ? J.insertBefore(Y, G) : Ja ? J.insertBefore(Y, Ja) : J.appendChild(Y), this.options.group.revertClone && this.animate(G, Y), B(Y, "display", ""), Xa = !1;
3372
3411
  }
3373
3412
  }
3374
3413
  };
3375
- function jo(e) {
3414
+ function Po(e) {
3376
3415
  e.dataTransfer && (e.dataTransfer.dropEffect = "move"), e.cancelable && e.preventDefault();
3377
3416
  }
3378
- function Mo(e, t, n, r, i, a, o, s) {
3379
- var c, l = e[V], u = l.options.onMove, d;
3380
- return window.CustomEvent && !la && !ua ? c = new CustomEvent("move", {
3417
+ function Fo(e, t, n, r, i, a, o, s) {
3418
+ var c, l = e[H], u = l.options.onMove, d;
3419
+ return window.CustomEvent && !da && !fa ? c = new CustomEvent("move", {
3381
3420
  bubbles: !0,
3382
3421
  cancelable: !0
3383
- }) : (c = document.createEvent("Event"), c.initEvent("move", !0, !0)), c.to = t, c.from = e, c.dragged = n, c.draggedRect = r, c.related = i || t, c.relatedRect = a || B(t), c.willInsertAfter = s, c.originalEvent = o, e.dispatchEvent(c), u && (d = u.call(l, c, o)), d;
3422
+ }) : (c = document.createEvent("Event"), c.initEvent("move", !0, !0)), c.to = t, c.from = e, c.dragged = n, c.draggedRect = r, c.related = i || t, c.relatedRect = a || V(t), c.willInsertAfter = s, c.originalEvent = o, e.dispatchEvent(c), u && (d = u.call(l, c, o)), d;
3384
3423
  }
3385
- function No(e) {
3424
+ function Io(e) {
3386
3425
  e.draggable = !1;
3387
3426
  }
3388
- function Po() {
3389
- go = !1;
3427
+ function Lo() {
3428
+ yo = !1;
3390
3429
  }
3391
- function Fo(e, t, n) {
3392
- var r = B(wa(n.el, 0, n.options, !0)), i = La(n.el, n.options, K), a = 10;
3430
+ function Ro(e, t, n) {
3431
+ var r = V(Ea(n.el, 0, n.options, !0)), i = za(n.el, n.options, q), a = 10;
3393
3432
  return t ? e.clientX < i.left - a || e.clientY < r.top && e.clientX < r.right : e.clientY < i.top - a || e.clientY < r.bottom && e.clientX < r.left;
3394
3433
  }
3395
- function Io(e, t, n) {
3396
- var r = B(Ta(n.el, n.options.draggable)), i = La(n.el, n.options, K), a = 10;
3434
+ function zo(e, t, n) {
3435
+ var r = V(Da(n.el, n.options.draggable)), i = za(n.el, n.options, q), a = 10;
3397
3436
  return t ? e.clientX > i.right + a || e.clientY > r.bottom && e.clientX > r.left : e.clientY > i.bottom + a || e.clientX > r.right && e.clientY > r.top;
3398
3437
  }
3399
- function Lo(e, t, n, r, i, a, o, s) {
3438
+ function Bo(e, t, n, r, i, a, o, s) {
3400
3439
  var c = r ? e.clientY : e.clientX, l = r ? n.height : n.width, u = r ? n.top : n.left, d = r ? n.bottom : n.right, f = !1;
3401
3440
  if (!o) {
3402
- if (s && mo < l * i) {
3403
- if (!fo && (uo === 1 ? c > u + l * a / 2 : c < d - l * a / 2) && (fo = !0), fo) f = !0;
3404
- else if (uo === 1 ? c < u + mo : c > d - mo) return -uo;
3405
- } else if (c > u + l * (1 - i) / 2 && c < d - l * (1 - i) / 2) return Ro(t);
3441
+ if (s && _o < l * i) {
3442
+ if (!ho && (mo === 1 ? c > u + l * a / 2 : c < d - l * a / 2) && (ho = !0), ho) f = !0;
3443
+ else if (mo === 1 ? c < u + _o : c > d - _o) return -mo;
3444
+ } else if (c > u + l * (1 - i) / 2 && c < d - l * (1 - i) / 2) return Vo(t);
3406
3445
  }
3407
3446
  return f ||= o, f && (c < u + l * a / 2 || c > d - l * a / 2) ? c > u + l / 2 ? 1 : -1 : 0;
3408
3447
  }
3409
- function Ro(e) {
3410
- return Ea(W) < Ea(e) ? 1 : -1;
3448
+ function Vo(e) {
3449
+ return Oa(G) < Oa(e) ? 1 : -1;
3411
3450
  }
3412
- function zo(e) {
3451
+ function Ho(e) {
3413
3452
  for (var t = e.tagName + e.className + e.src + e.href + e.textContent, n = t.length, r = 0; n--;) r += t.charCodeAt(n);
3414
3453
  return r.toString(36);
3415
3454
  }
3416
- function Bo(e) {
3417
- _o.length = 0;
3455
+ function Uo(e) {
3456
+ bo.length = 0;
3418
3457
  for (var t = e.getElementsByTagName("input"), n = t.length; n--;) {
3419
3458
  var r = t[n];
3420
- r.checked && _o.push(r);
3459
+ r.checked && bo.push(r);
3421
3460
  }
3422
3461
  }
3423
- function Vo(e) {
3462
+ function Wo(e) {
3424
3463
  return setTimeout(e, 0);
3425
3464
  }
3426
- function Ho(e) {
3465
+ function Go(e) {
3427
3466
  return clearTimeout(e);
3428
3467
  }
3429
- vo && I(document, "touchmove", function(e) {
3430
- (Q.active || $a) && e.cancelable && e.preventDefault();
3468
+ xo && L(document, "touchmove", function(e) {
3469
+ (Q.active || no) && e.cancelable && e.preventDefault();
3431
3470
  }), Q.utils = {
3432
- on: I,
3433
- off: L,
3434
- css: z,
3435
- find: xa,
3471
+ on: L,
3472
+ off: R,
3473
+ css: B,
3474
+ find: Ca,
3436
3475
  is: function(e, t) {
3437
- return !!va(e, t, e, !1);
3476
+ return !!ba(e, t, e, !1);
3438
3477
  },
3439
- extend: Aa,
3440
- throttle: Na,
3441
- closest: va,
3442
- toggleClass: R,
3443
- clone: Ia,
3444
- index: Ea,
3445
- nextTick: Vo,
3446
- cancelNextTick: Ho,
3447
- detectDirection: Co,
3448
- getChild: wa
3478
+ extend: Ma,
3479
+ throttle: Fa,
3480
+ closest: ba,
3481
+ toggleClass: z,
3482
+ clone: Ra,
3483
+ index: Oa,
3484
+ nextTick: Wo,
3485
+ cancelNextTick: Go,
3486
+ detectDirection: Eo,
3487
+ getChild: Ea
3449
3488
  }, Q.get = function(e) {
3450
- return e[V];
3489
+ return e[H];
3451
3490
  }, Q.mount = function() {
3452
3491
  var e = [...arguments];
3453
3492
  e[0].constructor === Array && (e = e[0]), e.forEach(function(e) {
3454
3493
  if (!e.prototype || !e.prototype.constructor) throw `Sortable: Mounted plugin must be a constructor function, not ${{}.toString.call(e)}`;
3455
- e.utils && (Q.utils = ta(ta({}, Q.utils), e.utils)), Ua.mount(e);
3494
+ e.utils && (Q.utils = ra(ra({}, Q.utils), e.utils)), Ga.mount(e);
3456
3495
  });
3457
3496
  }, Q.create = function(e, t) {
3458
3497
  return new Q(e, t);
3459
- }, Q.version = sa;
3460
- var $ = [], Uo, Wo, Go = !1, Ko, qo, Jo, Yo;
3461
- function Xo() {
3498
+ }, Q.version = la;
3499
+ var $ = [], Ko, qo, Jo = !1, Yo, Xo, Zo, Qo;
3500
+ function $o() {
3462
3501
  function e() {
3463
3502
  for (var e in this.defaults = {
3464
3503
  scroll: !0,
@@ -3471,70 +3510,70 @@ function Xo() {
3471
3510
  return e.prototype = {
3472
3511
  dragStarted: function(e) {
3473
3512
  var t = e.originalEvent;
3474
- this.sortable.nativeDraggable ? I(document, "dragover", this._handleAutoScroll) : this.options.supportPointer ? I(document, "pointermove", this._handleFallbackAutoScroll) : t.touches ? I(document, "touchmove", this._handleFallbackAutoScroll) : I(document, "mousemove", this._handleFallbackAutoScroll);
3513
+ this.sortable.nativeDraggable ? L(document, "dragover", this._handleAutoScroll) : this.options.supportPointer ? L(document, "pointermove", this._handleFallbackAutoScroll) : t.touches ? L(document, "touchmove", this._handleFallbackAutoScroll) : L(document, "mousemove", this._handleFallbackAutoScroll);
3475
3514
  },
3476
3515
  dragOverCompleted: function(e) {
3477
3516
  var t = e.originalEvent;
3478
3517
  !this.options.dragOverBubble && !t.rootEl && this._handleAutoScroll(t);
3479
3518
  },
3480
3519
  drop: function() {
3481
- this.sortable.nativeDraggable ? L(document, "dragover", this._handleAutoScroll) : (L(document, "pointermove", this._handleFallbackAutoScroll), L(document, "touchmove", this._handleFallbackAutoScroll), L(document, "mousemove", this._handleFallbackAutoScroll)), Qo(), Zo(), Pa();
3520
+ this.sortable.nativeDraggable ? R(document, "dragover", this._handleAutoScroll) : (R(document, "pointermove", this._handleFallbackAutoScroll), R(document, "touchmove", this._handleFallbackAutoScroll), R(document, "mousemove", this._handleFallbackAutoScroll)), ts(), es(), Ia();
3482
3521
  },
3483
3522
  nulling: function() {
3484
- Jo = Wo = Uo = Go = Yo = Ko = qo = null, $.length = 0;
3523
+ Zo = qo = Ko = Jo = Qo = Yo = Xo = null, $.length = 0;
3485
3524
  },
3486
3525
  _handleFallbackAutoScroll: function(e) {
3487
3526
  this._handleAutoScroll(e, !0);
3488
3527
  },
3489
3528
  _handleAutoScroll: function(e, t) {
3490
3529
  var n = this, r = (e.touches ? e.touches[0] : e).clientX, i = (e.touches ? e.touches[0] : e).clientY, a = document.elementFromPoint(r, i);
3491
- if (Jo = e, t || this.options.forceAutoScrollFallback || ua || la || fa) {
3492
- $o(e, this.options, a, t);
3493
- var o = ka(a, !0);
3494
- Go && (!Yo || r !== Ko || i !== qo) && (Yo && Qo(), Yo = setInterval(function() {
3495
- var a = ka(document.elementFromPoint(r, i), !0);
3496
- a !== o && (o = a, Zo()), $o(e, n.options, a, t);
3497
- }, 10), Ko = r, qo = i);
3530
+ if (Zo = e, t || this.options.forceAutoScrollFallback || fa || da || ma) {
3531
+ ns(e, this.options, a, t);
3532
+ var o = ja(a, !0);
3533
+ Jo && (!Qo || r !== Yo || i !== Xo) && (Qo && ts(), Qo = setInterval(function() {
3534
+ var a = ja(document.elementFromPoint(r, i), !0);
3535
+ a !== o && (o = a, es()), ns(e, n.options, a, t);
3536
+ }, 10), Yo = r, Xo = i);
3498
3537
  } else {
3499
- if (!this.options.bubbleScroll || ka(a, !0) === Sa()) {
3500
- Zo();
3538
+ if (!this.options.bubbleScroll || ja(a, !0) === wa()) {
3539
+ es();
3501
3540
  return;
3502
3541
  }
3503
- $o(e, this.options, ka(a, !1), !1);
3542
+ ns(e, this.options, ja(a, !1), !1);
3504
3543
  }
3505
3544
  }
3506
- }, ia(e, {
3545
+ }, oa(e, {
3507
3546
  pluginName: "scroll",
3508
3547
  initializeByDefault: !0
3509
3548
  });
3510
3549
  }
3511
- function Zo() {
3550
+ function es() {
3512
3551
  $.forEach(function(e) {
3513
3552
  clearInterval(e.pid);
3514
3553
  }), $ = [];
3515
3554
  }
3516
- function Qo() {
3517
- clearInterval(Yo);
3555
+ function ts() {
3556
+ clearInterval(Qo);
3518
3557
  }
3519
- var $o = Na(function(e, t, n, r) {
3558
+ var ns = Fa(function(e, t, n, r) {
3520
3559
  if (t.scroll) {
3521
- var i = (e.touches ? e.touches[0] : e).clientX, a = (e.touches ? e.touches[0] : e).clientY, o = t.scrollSensitivity, s = t.scrollSpeed, c = Sa(), l = !1, u;
3522
- Wo !== n && (Wo = n, Zo(), Uo = t.scroll, u = t.scrollFn, Uo === !0 && (Uo = ka(n, !0)));
3523
- var d = 0, f = Uo;
3560
+ var i = (e.touches ? e.touches[0] : e).clientX, a = (e.touches ? e.touches[0] : e).clientY, o = t.scrollSensitivity, s = t.scrollSpeed, c = wa(), l = !1, u;
3561
+ qo !== n && (qo = n, es(), Ko = t.scroll, u = t.scrollFn, Ko === !0 && (Ko = ja(n, !0)));
3562
+ var d = 0, f = Ko;
3524
3563
  do {
3525
- var p = f, m = B(p), h = m.top, g = m.bottom, _ = m.left, v = m.right, y = m.width, b = m.height, x = void 0, S = void 0, C = p.scrollWidth, w = p.scrollHeight, T = z(p), E = p.scrollLeft, D = p.scrollTop;
3564
+ var p = f, m = V(p), h = m.top, g = m.bottom, _ = m.left, v = m.right, y = m.width, b = m.height, x = void 0, S = void 0, C = p.scrollWidth, w = p.scrollHeight, T = B(p), E = p.scrollLeft, D = p.scrollTop;
3526
3565
  p === c ? (x = y < C && (T.overflowX === "auto" || T.overflowX === "scroll" || T.overflowX === "visible"), S = b < w && (T.overflowY === "auto" || T.overflowY === "scroll" || T.overflowY === "visible")) : (x = y < C && (T.overflowX === "auto" || T.overflowX === "scroll"), S = b < w && (T.overflowY === "auto" || T.overflowY === "scroll"));
3527
3566
  var O = x && (Math.abs(v - i) <= o && E + y < C) - (Math.abs(_ - i) <= o && !!E), k = S && (Math.abs(g - a) <= o && D + b < w) - (Math.abs(h - a) <= o && !!D);
3528
- if (!$[d]) for (var ee = 0; ee <= d; ee++) $[ee] || ($[ee] = {});
3567
+ if (!$[d]) for (var A = 0; A <= d; A++) $[A] || ($[A] = {});
3529
3568
  ($[d].vx != O || $[d].vy != k || $[d].el !== p) && ($[d].el = p, $[d].vx = O, $[d].vy = k, clearInterval($[d].pid), (O != 0 || k != 0) && (l = !0, $[d].pid = setInterval(function() {
3530
- r && this.layer === 0 && Q.active._onTouchMove(Jo);
3569
+ r && this.layer === 0 && Q.active._onTouchMove(Zo);
3531
3570
  var t = $[this.layer].vy ? $[this.layer].vy * s : 0, n = $[this.layer].vx ? $[this.layer].vx * s : 0;
3532
- typeof u == "function" && u.call(Q.dragged.parentNode[V], n, t, e, Jo, $[this.layer].el) !== "continue" || Fa($[this.layer].el, n, t);
3571
+ typeof u == "function" && u.call(Q.dragged.parentNode[H], n, t, e, Zo, $[this.layer].el) !== "continue" || La($[this.layer].el, n, t);
3533
3572
  }.bind({ layer: d }), 24))), d++;
3534
- } while (t.bubbleScroll && f !== c && (f = ka(f, !1)));
3535
- Go = l;
3573
+ } while (t.bubbleScroll && f !== c && (f = ja(f, !1)));
3574
+ Jo = l;
3536
3575
  }
3537
- }, 30), es = function(e) {
3576
+ }, 30), rs = function(e) {
3538
3577
  var t = e.originalEvent, n = e.putSortable, r = e.dragEl, i = e.activeSortable, a = e.dispatchSortableEvent, o = e.hideGhostForTarget, s = e.unhideGhostForTarget;
3539
3578
  if (t) {
3540
3579
  var c = n || i;
@@ -3546,8 +3585,8 @@ var $o = Na(function(e, t, n, r) {
3546
3585
  }));
3547
3586
  }
3548
3587
  };
3549
- function ts() {}
3550
- ts.prototype = {
3588
+ function is() {}
3589
+ is.prototype = {
3551
3590
  startIndex: null,
3552
3591
  dragStart: function(e) {
3553
3592
  var t = e.oldDraggableIndex;
@@ -3556,72 +3595,72 @@ ts.prototype = {
3556
3595
  onSpill: function(e) {
3557
3596
  var t = e.dragEl, n = e.putSortable;
3558
3597
  this.sortable.captureAnimationState(), n && n.captureAnimationState();
3559
- var r = wa(this.sortable.el, this.startIndex, this.options);
3598
+ var r = Ea(this.sortable.el, this.startIndex, this.options);
3560
3599
  r ? this.sortable.el.insertBefore(t, r) : this.sortable.el.appendChild(t), this.sortable.animateAll(), n && n.animateAll();
3561
3600
  },
3562
- drop: es
3563
- }, ia(ts, { pluginName: "revertOnSpill" });
3564
- function ns() {}
3565
- ns.prototype = {
3601
+ drop: rs
3602
+ }, oa(is, { pluginName: "revertOnSpill" });
3603
+ function as() {}
3604
+ as.prototype = {
3566
3605
  onSpill: function(e) {
3567
3606
  var t = e.dragEl, n = e.putSortable || this.sortable;
3568
3607
  n.captureAnimationState(), t.parentNode && t.parentNode.removeChild(t), n.animateAll();
3569
3608
  },
3570
- drop: es
3571
- }, ia(ns, { pluginName: "removeOnSpill" }), Q.mount(new Xo()), Q.mount(ns, ts);
3572
- function rs(e) {
3609
+ drop: rs
3610
+ }, oa(as, { pluginName: "removeOnSpill" }), Q.mount(new $o()), Q.mount(as, is);
3611
+ function os(e) {
3573
3612
  return e == null ? e : JSON.parse(JSON.stringify(e));
3574
3613
  }
3575
- function is(e) {
3576
- re() && r(e);
3614
+ function ss(e) {
3615
+ ne() && r(e);
3577
3616
  }
3578
- function as(e) {
3579
- re() ? a(e) : ie(e);
3617
+ function cs(e) {
3618
+ ne() ? a(e) : re(e);
3580
3619
  }
3581
- var os = null, ss = null;
3582
- function cs(e = null, t = null) {
3583
- os = e, ss = t;
3620
+ var ls = null, us = null;
3621
+ function ds(e = null, t = null) {
3622
+ ls = e, us = t;
3584
3623
  }
3585
- function ls() {
3624
+ function fs() {
3586
3625
  return {
3587
- data: os,
3588
- clonedData: ss
3626
+ data: ls,
3627
+ clonedData: us
3589
3628
  };
3590
3629
  }
3591
- var us = Symbol("cloneElement");
3592
- function ds(...e) {
3593
- let t = re()?.proxy, n = null, r = e[0], [, i, a] = e;
3630
+ var ps = Symbol("cloneElement");
3631
+ function ms(...e) {
3632
+ let t = ne()?.proxy, n = null, r = e[0], [, i, a] = e;
3594
3633
  Array.isArray(k(i)) || (a = i, i = null);
3595
- let o = null, { immediate: s = !0, clone: l = rs, forceFallback: u, fallbackOnBody: d, customUpdate: f } = k(a) ?? {};
3634
+ let o = null, { immediate: s = !0, clone: l = os, forceFallback: u, fallbackOnBody: d, customUpdate: f } = k(a) ?? {};
3596
3635
  function p(e) {
3597
3636
  let { from: t, oldIndex: r, item: a } = e, o = Array.from(t.childNodes);
3598
3637
  n = u && !d ? o.slice(0, -1) : o;
3599
3638
  let s = k(k(i)?.[r]), c = l(s);
3600
- cs(s, c), a[us] = c;
3639
+ ds(s, c), a[ps] = c;
3601
3640
  }
3602
3641
  function m(e) {
3603
- let t = e.item[us];
3604
- if (!Ui(t)) {
3605
- if (Ki(e.item), g(i)) {
3642
+ let t = e.item[ps];
3643
+ if (!Gi(t)) {
3644
+ if (Ji(e.item), g(i)) {
3606
3645
  let n = [...k(i)];
3607
- i.value = Hi(n, e.newDraggableIndex, t);
3646
+ i.value = Wi(n, e.newDraggableIndex, t);
3608
3647
  return;
3609
3648
  }
3610
- Hi(k(i), e.newDraggableIndex, t);
3649
+ Wi(k(i), e.newDraggableIndex, t);
3611
3650
  }
3612
3651
  }
3613
3652
  function h(e) {
3614
3653
  let { from: t, item: n, oldIndex: r, oldDraggableIndex: a, pullMode: o, clone: s } = e;
3615
- if (Gi(t, n, r), o === "clone") {
3616
- Ki(s);
3654
+ if (qi(t, n, r), o === "clone") {
3655
+ Ji(s);
3617
3656
  return;
3618
3657
  }
3619
3658
  if (g(i)) {
3620
3659
  let e = [...k(i)];
3621
- i.value = Vi(e, a);
3660
+ i.value = Ui(e, a);
3622
3661
  return;
3623
3662
  }
3624
- Vi(k(i), a);
3663
+ Ui(k(i), a);
3625
3664
  }
3626
3665
  function _(e) {
3627
3666
  if (f) {
@@ -3629,12 +3668,12 @@ function ds(...e) {
3629
3668
  return;
3630
3669
  }
3631
3670
  let { from: t, item: n, oldIndex: r, oldDraggableIndex: a, newDraggableIndex: o } = e;
3632
- if (Ki(n), Gi(t, n, r), g(i)) {
3671
+ if (Ji(n), qi(t, n, r), g(i)) {
3633
3672
  let e = [...k(i)];
3634
- i.value = Ri(e, a, o);
3673
+ i.value = Bi(e, a, o);
3635
3674
  return;
3636
3675
  }
3637
- Ri(k(i), a, o);
3676
+ Bi(k(i), a, o);
3638
3677
  }
3639
3678
  function v(e) {
3640
3679
  let { newIndex: t, oldIndex: r, from: i, to: a } = e, o = null, s = t === r && i === a;
@@ -3652,8 +3691,8 @@ function ds(...e) {
3652
3691
  } finally {
3653
3692
  n = null;
3654
3693
  }
3655
- ie(() => {
3656
- if (cs(), o) throw o;
3694
+ re(() => {
3695
+ if (ds(), o) throw o;
3657
3696
  });
3658
3697
  }
3659
3698
  let y = {
@@ -3665,19 +3704,19 @@ function ds(...e) {
3665
3704
  };
3666
3705
  function b(e) {
3667
3706
  let n = k(r);
3668
- return e ||= Wi(n) ? qi(n, t?.$el) : n, e && !Xi(e) && (e = e.$el), e || Li("Root element not found"), e;
3707
+ return e ||= Ki(n) ? Yi(n, t?.$el) : n, e && !Qi(e) && (e = e.$el), e || zi("Root element not found"), e;
3669
3708
  }
3670
3709
  function x() {
3671
- let e = k(a) ?? {}, { immediate: t, clone: n } = e, r = Pi(e, ["immediate", "clone"]);
3672
- return Zi(r, (e, t) => {
3673
- Qi(e) && (r[e] = (e, ...n) => ($i(e, ls()), t(e, ...n)));
3674
- }), Yi(i === null ? {} : y, r);
3710
+ let e = k(a) ?? {}, { immediate: t, clone: n } = e, r = Ii(e, ["immediate", "clone"]);
3711
+ return $i(r, (e, t) => {
3712
+ ea(e) && (r[e] = (e, ...n) => (ta(e, fs()), t(e, ...n)));
3713
+ }), Zi(i === null ? {} : y, r);
3675
3714
  }
3676
3715
  let S = (e) => {
3677
3716
  e = b(e), o && C.destroy(), o = new Q(e, x());
3678
3717
  };
3679
3718
  c(() => a, () => {
3680
- o && Zi(x(), (e, t) => {
3719
+ o && $i(x(), (e, t) => {
3681
3720
  o?.option(e, t);
3682
3721
  });
3683
3722
  }, { deep: !0 });
@@ -3690,15 +3729,15 @@ function ds(...e) {
3690
3729
  toArray: () => o?.toArray(),
3691
3730
  closest: (...e) => o?.closest(...e)
3692
3731
  };
3693
- return as(() => {
3732
+ return cs(() => {
3694
3733
  s && S();
3695
- }), is(C.destroy), Ni({
3734
+ }), ss(C.destroy), Fi({
3696
3735
  start: S,
3697
3736
  pause: () => C?.option("disabled", !0),
3698
3737
  resume: () => C?.option("disabled", !1)
3699
3738
  }, C);
3700
3739
  }
3701
- var fs = [
3740
+ var hs = [
3702
3741
  "update",
3703
3742
  "start",
3704
3743
  "add",
@@ -3711,7 +3750,7 @@ var fs = [
3711
3750
  "clone",
3712
3751
  "move",
3713
3752
  "change"
3714
- ], ps = y({
3753
+ ], gs = y({
3715
3754
  name: "VueDraggable",
3716
3755
  model: {
3717
3756
  prop: "modelValue",
@@ -3761,37 +3800,37 @@ var fs = [
3761
3800
  "tag",
3762
3801
  "target",
3763
3802
  "customUpdate",
3764
- ...fs.map((e) => `on${e.replace(/^\S/, (e) => e.toUpperCase())}`)
3803
+ ...hs.map((e) => `on${e.replace(/^\S/, (e) => e.toUpperCase())}`)
3765
3804
  ],
3766
- emits: ["update:modelValue", ...fs],
3805
+ emits: ["update:modelValue", ...hs],
3767
3806
  setup(t, { slots: n, emit: r, expose: i, attrs: a }) {
3768
- let o = fs.reduce((e, t) => {
3807
+ let o = hs.reduce((e, t) => {
3769
3808
  let n = `on${t.replace(/^\S/, (e) => e.toUpperCase())}`;
3770
3809
  return e[n] = (...e) => r(t, ...e), e;
3771
- }, {}), s = j(() => {
3772
- let n = e(t), { modelValue: r } = n, i = Pi(n, ["modelValue"]), s = Object.entries(i).reduce((e, [t, n]) => {
3810
+ }, {}), s = M(() => {
3811
+ let n = e(t), { modelValue: r } = n, i = Ii(n, ["modelValue"]), s = Object.entries(i).reduce((e, [t, n]) => {
3773
3812
  let r = k(n);
3774
3813
  return r !== void 0 && (e[t] = r), e;
3775
3814
  }, {});
3776
- return Ni(Ni({}, o), Bi(Ni(Ni({}, a), s)));
3777
- }), c = j({
3815
+ return Fi(Fi({}, o), Hi(Fi(Fi({}, a), s)));
3816
+ }), c = M({
3778
3817
  get: () => t.modelValue,
3779
3818
  set: (e) => r("update:modelValue", e)
3780
- }), l = _(), u = ee(ds(t.target || l, c, s));
3781
- return i(u), () => ae(t.tag || "div", { ref: l }, (n?.default)?.call(n, u));
3819
+ }), l = _(), u = A(ms(t.target || l, c, s));
3820
+ return i(u), () => ie(t.tag || "div", { ref: l }, (n?.default)?.call(n, u));
3782
3821
  }
3783
- }), ms = {
3822
+ }), _s = {
3784
3823
  mounted: "mounted",
3785
3824
  unmounted: "unmounted"
3786
3825
  };
3787
- ms.mounted, ms.unmounted;
3826
+ _s.mounted, _s.unmounted;
3788
3827
  //#endregion
3789
3828
  //#region src/components/blocks/SectionBlock.vue?vue&type=script&setup=true&lang.ts
3790
- var hs = { class: "tpl:w-full" }, gs = {
3829
+ var vs = { class: "tpl:w-full" }, ys = {
3791
3830
  key: 0,
3792
3831
  "data-testid": "section-drop-hint",
3793
3832
  class: "tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:flex tpl:items-center tpl:justify-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
3794
- }, _s = /* @__PURE__ */ y({
3833
+ }, bs = /* @__PURE__ */ y({
3795
3834
  __name: "SectionBlock",
3796
3835
  props: {
3797
3836
  block: {},
@@ -3799,13 +3838,13 @@ var hs = { class: "tpl:w-full" }, gs = {
3799
3838
  },
3800
3839
  setup(e) {
3801
3840
  let n = {
3802
- title: Ei,
3803
- paragraph: ci,
3804
- image: Yr,
3805
- button: In,
3806
- divider: kr,
3807
- custom: Dr
3808
- }, r = e, { t: a } = Ft(), s = nt(bt, "SectionBlock"), c = N(_t, null), l = N(Dt, null), u = j(() => {
3841
+ title: Oi,
3842
+ paragraph: ui,
3843
+ image: Zr,
3844
+ button: Rn,
3845
+ divider: jr,
3846
+ custom: kr
3847
+ }, r = e, { t: a } = Ft(), s = nt(bt, "SectionBlock"), c = P(_t, null), l = P(Dt, null), u = M(() => {
3809
3848
  switch (r.block.columns) {
3810
3849
  case "2": return ["50%", "50%"];
3811
3850
  case "3": return [
@@ -3817,11 +3856,11 @@ var hs = { class: "tpl:w-full" }, gs = {
3817
3856
  case "2-1": return ["66.67%", "33.33%"];
3818
3857
  default: return ["100%"];
3819
3858
  }
3820
- }), h = j(() => {
3859
+ }), h = M(() => {
3821
3860
  let e = u.value.length, t = [...r.block.children];
3822
3861
  for (; t.length < e;) t.push([]);
3823
3862
  return t.slice(0, e);
3824
- }), g = j(() => r.viewport === "mobile" && r.block.stackOnMobile !== !1);
3863
+ }), g = M(() => r.viewport === "mobile" && r.block.stackOnMobile !== !1);
3825
3864
  function _(e) {
3826
3865
  return h.value[e] || [];
3827
3866
  }
@@ -3831,7 +3870,7 @@ var hs = { class: "tpl:w-full" }, gs = {
3831
3870
  i[e] = n, s.updateBlock(r.block.id, { children: i });
3832
3871
  }
3833
3872
  function y(e) {
3834
- return li(e, l, n);
3873
+ return di(e, l, n);
3835
3874
  }
3836
3875
  function S(e, t) {
3837
3876
  e.type === "custom" && s.updateBlock(e.id, {
@@ -3839,16 +3878,16 @@ var hs = { class: "tpl:w-full" }, gs = {
3839
3878
  dataSourceFetched: t.dataSourceFetched
3840
3879
  });
3841
3880
  }
3842
- return (n, r) => (f(), x("div", hs, [b("div", { class: o(["tpl:flex tpl:gap-0", { "tpl:flex-col": g.value }]) }, [(f(!0), x(A, null, t(h.value, (n, r) => (f(), x("div", {
3881
+ return (n, r) => (f(), x("div", vs, [b("div", { class: o(["tpl:flex tpl:gap-0", { "tpl:flex-col": g.value }]) }, [(f(!0), x(j, null, t(h.value, (n, r) => (f(), x("div", {
3843
3882
  key: r,
3844
3883
  class: o(["tpl:relative tpl:min-h-[60px] tpl:rounded", _(r).length === 0 ? "tpl:border tpl:border-dashed tpl:border-[var(--tpl-border)]" : ""]),
3845
3884
  style: i({ width: g.value ? "100%" : u.value[r] })
3846
- }, [w(k(ps), {
3885
+ }, [w(k(gs), {
3847
3886
  "model-value": _(r),
3848
3887
  group: {
3849
3888
  name: "blocks",
3850
3889
  pull: !0,
3851
- put: (e, t, n) => k(Di)(n)
3890
+ put: (e, t, n) => k(ki)(n)
3852
3891
  },
3853
3892
  animation: 150,
3854
3893
  "ghost-class": "tpl-ghost",
@@ -3861,7 +3900,7 @@ var hs = { class: "tpl:w-full" }, gs = {
3861
3900
  class: "tpl:min-h-[60px]",
3862
3901
  "onUpdate:modelValue": (e) => v(r, e)
3863
3902
  }, {
3864
- default: m(() => [(f(!0), x(A, null, t(_(r), (t) => oe((f(), x("div", { key: t.id }, [w(wi, {
3903
+ default: m(() => [(f(!0), x(j, null, t(_(r), (t) => ae((f(), x("div", { key: t.id }, [w(Ei, {
3865
3904
  block: t,
3866
3905
  "is-selected": k(s).state.selectedBlockId === t.id,
3867
3906
  viewport: e.viewport,
@@ -3886,19 +3925,19 @@ var hs = { class: "tpl:w-full" }, gs = {
3886
3925
  "viewport",
3887
3926
  "preview-mode",
3888
3927
  "onSelect"
3889
- ])])), [[se, !k(c)?.isHidden(t.id)]])), 128))]),
3928
+ ])])), [[oe, !k(c)?.isHidden(t.id)]])), 128))]),
3890
3929
  _: 2
3891
3930
  }, 1032, [
3892
3931
  "model-value",
3893
3932
  "group",
3894
3933
  "onUpdate:modelValue"
3895
- ]), _(r).length === 0 ? (f(), x("div", gs, [b("span", null, p(k(a).section.dropHere), 1)])) : M("", !0)], 6))), 128))], 2)]));
3934
+ ]), _(r).length === 0 ? (f(), x("div", ys, [b("span", null, p(k(a).section.dropHere), 1)])) : N("", !0)], 6))), 128))], 2)]));
3896
3935
  }
3897
- }), vs = ke, ys = {
3936
+ }), xs = Oe, Ss = {
3898
3937
  small: 24,
3899
3938
  medium: 32,
3900
3939
  large: 48
3901
- }, bs = [
3940
+ }, Cs = [
3902
3941
  "facebook",
3903
3942
  "twitter",
3904
3943
  "instagram",
@@ -3916,11 +3955,11 @@ var hs = { class: "tpl:w-full" }, gs = {
3916
3955
  "github",
3917
3956
  "dribbble",
3918
3957
  "behance"
3919
- ], xs = [
3958
+ ], ws = [
3920
3959
  "width",
3921
3960
  "height",
3922
3961
  "fill"
3923
- ], Ss = ["d"], Cs = /* @__PURE__ */ y({
3962
+ ], Ts = ["d"], Es = /* @__PURE__ */ y({
3924
3963
  __name: "SocialIconSvg",
3925
3964
  props: {
3926
3965
  platform: {},
@@ -3928,7 +3967,7 @@ var hs = { class: "tpl:w-full" }, gs = {
3928
3967
  iconSize: {}
3929
3968
  },
3930
3969
  setup(e) {
3931
- let t = e, n = j(() => vs[t.platform]), r = j(() => ys[t.iconSize]), a = j(() => {
3970
+ let t = e, n = M(() => xs[t.platform]), r = M(() => Ss[t.iconSize]), a = M(() => {
3932
3971
  let e = {
3933
3972
  display: "inline-flex",
3934
3973
  alignItems: "center",
@@ -3965,40 +4004,40 @@ var hs = { class: "tpl:w-full" }, gs = {
3965
4004
  };
3966
4005
  default: return e;
3967
4006
  }
3968
- }), o = j(() => Math.floor(r.value * .6)), s = j(() => t.iconStyle === "outlined" ? n.value.color : "#ffffff");
4007
+ }), o = M(() => Math.floor(r.value * .6)), s = M(() => t.iconStyle === "outlined" ? n.value.color : "#ffffff");
3969
4008
  return (e, t) => (f(), x("span", { style: i(a.value) }, [(f(), x("svg", {
3970
4009
  width: o.value,
3971
4010
  height: o.value,
3972
4011
  viewBox: "0 0 24 24",
3973
4012
  fill: s.value,
3974
4013
  xmlns: "http://www.w3.org/2000/svg"
3975
- }, [b("path", { d: n.value.path }, null, 8, Ss)], 8, xs))], 4));
4014
+ }, [b("path", { d: n.value.path }, null, 8, Ts)], 8, ws))], 4));
3976
4015
  }
3977
- }), ws = { class: "tpl:w-full" }, Ts = ["href"], Es = {
4016
+ }), Ds = { class: "tpl:w-full" }, Os = ["href"], ks = {
3978
4017
  key: 1,
3979
4018
  class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
3980
- }, Ds = /* @__PURE__ */ y({
4019
+ }, As = /* @__PURE__ */ y({
3981
4020
  __name: "SocialIconsBlock",
3982
4021
  props: {
3983
4022
  block: {},
3984
4023
  viewport: {}
3985
4024
  },
3986
4025
  setup(e) {
3987
- let n = e, { t: r } = Ft(), a = j(() => ({
4026
+ let n = e, { t: r } = Ft(), a = M(() => ({
3988
4027
  display: "flex",
3989
4028
  flexWrap: "wrap",
3990
4029
  gap: `${n.block.spacing}px`,
3991
4030
  justifyContent: n.block.align === "left" ? "flex-start" : n.block.align === "right" ? "flex-end" : "center"
3992
- })), o = j(() => n.block.icons.length > 0);
3993
- return (n, s) => (f(), x("div", ws, [o.value ? (f(), x("div", {
4031
+ })), o = M(() => n.block.icons.length > 0);
4032
+ return (n, s) => (f(), x("div", Ds, [o.value ? (f(), x("div", {
3994
4033
  key: 0,
3995
4034
  style: i(a.value)
3996
- }, [(f(!0), x(A, null, t(e.block.icons, (t) => (f(), x("a", {
4035
+ }, [(f(!0), x(j, null, t(e.block.icons, (t) => (f(), x("a", {
3997
4036
  key: t.id,
3998
4037
  href: t.url || "#",
3999
4038
  class: "tpl:cursor-default",
4000
- onClick: s[0] ||= P(() => {}, ["prevent"])
4001
- }, [w(Cs, {
4039
+ onClick: s[0] ||= F(() => {}, ["prevent"])
4040
+ }, [w(Es, {
4002
4041
  platform: t.platform,
4003
4042
  "icon-style": e.block.iconStyle,
4004
4043
  "icon-size": e.block.iconSize
@@ -4006,44 +4045,44 @@ var hs = { class: "tpl:w-full" }, gs = {
4006
4045
  "platform",
4007
4046
  "icon-style",
4008
4047
  "icon-size"
4009
- ])], 8, Ts))), 128))], 4)) : (f(), x("div", Es, [w(k(qn), { size: 16 }), b("span", null, p(k(r).social.addIcons), 1)]))]));
4048
+ ])], 8, Os))), 128))], 4)) : (f(), x("div", ks, [w(k(Yn), { size: 16 }), b("span", null, p(k(r).social.addIcons), 1)]))]));
4010
4049
  }
4011
- }), Os = { class: "tpl:w-full" }, ks = {
4050
+ }), js = { class: "tpl:w-full" }, Ms = {
4012
4051
  key: 0,
4013
4052
  class: "tpl:absolute tpl:rounded tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-medium",
4014
4053
  style: {
4015
4054
  "background-color": "var(--tpl-bg-hover)",
4016
4055
  color: "var(--tpl-text-dim)"
4017
4056
  }
4018
- }, As = /* @__PURE__ */ y({
4057
+ }, Ns = /* @__PURE__ */ y({
4019
4058
  __name: "SpacerBlock",
4020
4059
  props: {
4021
4060
  block: {},
4022
4061
  viewport: {}
4023
4062
  },
4024
4063
  setup(e) {
4025
- let t = e, n = nt(bt, "SpacerBlock"), r = j(() => ({
4064
+ let t = e, n = nt(bt, "SpacerBlock"), r = M(() => ({
4026
4065
  height: `${t.block.height}px`,
4027
4066
  minHeight: `${t.block.height}px`,
4028
4067
  ...n.state.previewMode ? {} : { borderColor: "var(--tpl-border)" }
4029
4068
  }));
4030
- return (t, a) => (f(), x("div", Os, [b("div", {
4069
+ return (t, a) => (f(), x("div", js, [b("div", {
4031
4070
  style: i(r.value),
4032
4071
  class: o(["tpl:relative tpl:flex tpl:items-center tpl:justify-center", { "tpl:border-y tpl:border-dashed": !k(n).state.previewMode }])
4033
- }, [k(n).state.previewMode ? M("", !0) : (f(), x("span", ks, p(e.block.height) + "px ", 1))], 6)]));
4072
+ }, [k(n).state.previewMode ? N("", !0) : (f(), x("span", Ms, p(e.block.height) + "px ", 1))], 6)]));
4034
4073
  }
4035
- }), js = { class: "tpl:w-full" }, Ms = { key: 0 }, Ns = [
4074
+ }), Ps = { class: "tpl:w-full" }, Fs = { key: 0 }, Is = [
4036
4075
  "aria-label",
4037
4076
  "data-placeholder",
4038
4077
  "onBlur"
4039
- ], Ps = [
4078
+ ], Ls = [
4040
4079
  "aria-label",
4041
4080
  "data-placeholder",
4042
4081
  "onBlur"
4043
- ], Fs = {
4082
+ ], Rs = {
4044
4083
  key: 1,
4045
4084
  class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border tpl:border-dashed tpl:py-4 tpl:text-sm tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-dim)]"
4046
- }, Is = /*#__PURE__*/ Vt(/* @__PURE__ */ y({
4085
+ }, zs = /*#__PURE__*/ Vt(/* @__PURE__ */ y({
4047
4086
  __name: "TableBlock",
4048
4087
  props: {
4049
4088
  block: {},
@@ -4057,7 +4096,7 @@ var hs = { class: "tpl:w-full" }, gs = {
4057
4096
  updated(e, t) {
4058
4097
  t.value !== t.oldValue && e.getRootNode().activeElement !== e && (e.textContent = t.value ?? "");
4059
4098
  }
4060
- }, r = e, { t: a } = Ft(), o = nt(bt, "TableBlock"), s = j(() => r.block.rows.length > 0), c = j(() => {
4099
+ }, r = e, { t: a } = Ft(), o = nt(bt, "TableBlock"), s = M(() => r.block.rows.length > 0), c = M(() => {
4061
4100
  let e = {
4062
4101
  width: "100%",
4063
4102
  borderCollapse: "collapse",
@@ -4066,15 +4105,15 @@ var hs = { class: "tpl:w-full" }, gs = {
4066
4105
  fontFamily: r.block.fontFamily || "inherit"
4067
4106
  };
4068
4107
  return r.block.color && (e.color = r.block.color), e;
4069
- }), l = j(() => ({
4108
+ }), l = M(() => ({
4070
4109
  border: `${r.block.borderWidth}px solid ${r.block.borderColor}`,
4071
4110
  padding: `${r.block.cellPadding}px`,
4072
4111
  textAlign: r.block.textAlign
4073
- })), u = j(() => ({
4112
+ })), u = M(() => ({
4074
4113
  ...l.value,
4075
4114
  fontWeight: "bold",
4076
4115
  backgroundColor: r.block.headerBackgroundColor || "transparent"
4077
- })), d = j(() => r.block.hasHeaderRow && r.block.rows.length > 0 ? r.block.rows[0] : null), m = j(() => r.block.hasHeaderRow ? r.block.rows.slice(1) : r.block.rows);
4116
+ })), d = M(() => r.block.hasHeaderRow && r.block.rows.length > 0 ? r.block.rows[0] : null), m = M(() => r.block.hasHeaderRow ? r.block.rows.slice(1) : r.block.rows);
4078
4117
  function h() {
4079
4118
  o.selectBlock(r.block.id);
4080
4119
  }
@@ -4088,31 +4127,31 @@ var hs = { class: "tpl:w-full" }, gs = {
4088
4127
  } : n);
4089
4128
  o.updateBlock(r.block.id, { rows: a });
4090
4129
  }
4091
- return (e, r) => (f(), x("div", js, [s.value ? (f(), x("table", {
4130
+ return (e, r) => (f(), x("div", Ps, [s.value ? (f(), x("table", {
4092
4131
  key: 0,
4093
4132
  style: i(c.value),
4094
4133
  class: "tpl-table-editable"
4095
- }, [d.value ? (f(), x("thead", Ms, [b("tr", null, [(f(!0), x(A, null, t(d.value.cells, (e) => oe((f(), x("th", {
4134
+ }, [d.value ? (f(), x("thead", Fs, [b("tr", null, [(f(!0), x(j, null, t(d.value.cells, (e) => ae((f(), x("th", {
4096
4135
  key: e.id,
4097
4136
  style: i(u.value),
4098
4137
  "aria-label": k(a).table.cellPlaceholder,
4099
4138
  contenteditable: "true",
4100
4139
  "data-placeholder": k(a).table.cellPlaceholder,
4101
4140
  onBlur: (t) => g(d.value.id, e.id, t),
4102
- onKeydown: r[0] ||= ce(P((e) => e.target.blur(), ["prevent"]), ["enter"]),
4103
- onClick: P(h, ["stop"])
4104
- }, null, 44, Ns)), [[n, e.content]])), 128))])])) : M("", !0), b("tbody", null, [(f(!0), x(A, null, t(m.value, (e) => (f(), x("tr", { key: e.id }, [(f(!0), x(A, null, t(e.cells, (t) => oe((f(), x("td", {
4141
+ onKeydown: r[0] ||= se(F((e) => e.target.blur(), ["prevent"]), ["enter"]),
4142
+ onClick: F(h, ["stop"])
4143
+ }, null, 44, Is)), [[n, e.content]])), 128))])])) : N("", !0), b("tbody", null, [(f(!0), x(j, null, t(m.value, (e) => (f(), x("tr", { key: e.id }, [(f(!0), x(j, null, t(e.cells, (t) => ae((f(), x("td", {
4105
4144
  key: t.id,
4106
4145
  style: i(l.value),
4107
4146
  "aria-label": k(a).table.cellPlaceholder,
4108
4147
  contenteditable: "true",
4109
4148
  "data-placeholder": k(a).table.cellPlaceholder,
4110
4149
  onBlur: (n) => g(e.id, t.id, n),
4111
- onKeydown: r[1] ||= ce(P((e) => e.target.blur(), ["prevent"]), ["enter"]),
4112
- onClick: P(h, ["stop"])
4113
- }, null, 44, Ps)), [[n, t.content]])), 128))]))), 128))])], 4)) : (f(), x("div", Fs, [w(k(Jn), { size: 16 }), b("span", null, p(k(a).table.empty), 1)]))]));
4150
+ onKeydown: r[1] ||= se(F((e) => e.target.blur(), ["prevent"]), ["enter"]),
4151
+ onClick: F(h, ["stop"])
4152
+ }, null, 44, Ls)), [[n, t.content]])), 128))]))), 128))])], 4)) : (f(), x("div", Rs, [w(k(Xn), { size: 16 }), b("span", null, p(k(a).table.empty), 1)]))]));
4114
4153
  }
4115
- }), [["__scopeId", "data-v-963ac422"]]), Ls = /* @__PURE__ */ y({
4154
+ }), [["__scopeId", "data-v-963ac422"]]), Bs = /* @__PURE__ */ y({
4116
4155
  __name: "VideoPlayButton",
4117
4156
  props: { hoverEffect: {
4118
4157
  type: Boolean,
@@ -4130,7 +4169,7 @@ var hs = { class: "tpl:w-full" }, gs = {
4130
4169
  });
4131
4170
  //#endregion
4132
4171
  //#region src/utils/videoThumbnail.ts
4133
- function Rs(e) {
4172
+ function Vs(e) {
4134
4173
  if (!e) return {
4135
4174
  platform: "unknown",
4136
4175
  videoId: null,
@@ -4162,25 +4201,25 @@ function Rs(e) {
4162
4201
  thumbnailUrl: null
4163
4202
  };
4164
4203
  }
4165
- function zs(e, t) {
4166
- return t || Rs(e).thumbnailUrl;
4204
+ function Hs(e, t) {
4205
+ return t || Vs(e).thumbnailUrl;
4167
4206
  }
4168
4207
  //#endregion
4169
4208
  //#region src/components/blocks/VideoBlock.vue?vue&type=script&setup=true&lang.ts
4170
- var Bs = ["src", "alt"], Vs = {
4209
+ var Us = ["src", "alt"], Ws = {
4171
4210
  class: "tpl:max-w-full tpl:truncate tpl:px-3 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-primary)]",
4172
4211
  style: { opacity: "0.7" }
4173
- }, Hs = ["href"], Us = ["src", "alt"], Ws = ["src", "alt"], Gs = {
4212
+ }, Gs = ["href"], Ks = ["src", "alt"], qs = ["src", "alt"], Js = {
4174
4213
  key: 3,
4175
4214
  class: "tpl:flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-sm tpl:border-[var(--tpl-border-light)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-dim)]"
4176
- }, Ks = /* @__PURE__ */ y({
4215
+ }, Ys = /* @__PURE__ */ y({
4177
4216
  __name: "VideoBlock",
4178
4217
  props: {
4179
4218
  block: {},
4180
4219
  viewport: {}
4181
4220
  },
4182
4221
  setup(e) {
4183
- let t = e, { t: n } = Ft(), { syntax: r } = Ht(), a = j(() => we(t.block.url, r) || we(t.block.thumbnailUrl, r)), o = cn(() => a.value ? void 0 : t.block.thumbnailUrl || void 0), s = cn(() => a.value ? t.block.placeholderUrl : void 0), c = j(() => a.value ? null : t.block.thumbnailUrl ? o.value ?? null : zs(t.block.url)), l = j(() => ({ textAlign: t.block.align })), u = j(() => {
4222
+ let t = e, { t: n } = Ft(), { syntax: r } = Ht(), a = M(() => Ce(t.block.url, r) || Ce(t.block.thumbnailUrl, r)), o = cn(() => a.value ? void 0 : t.block.thumbnailUrl || void 0), s = cn(() => a.value ? t.block.placeholderUrl : void 0), c = M(() => a.value ? null : t.block.thumbnailUrl ? o.value ?? null : Hs(t.block.url)), l = M(() => ({ textAlign: t.block.align })), u = M(() => {
4184
4223
  let e = t.block.align;
4185
4224
  return {
4186
4225
  maxWidth: "100%",
@@ -4189,7 +4228,7 @@ var Bs = ["src", "alt"], Vs = {
4189
4228
  marginLeft: e === "center" || e === "right" ? "auto" : void 0,
4190
4229
  marginRight: e === "center" ? "auto" : void 0
4191
4230
  };
4192
- }), d = j(() => we(t.block.url, r) ? t.block.url : t.block.thumbnailUrl);
4231
+ }), d = M(() => Ce(t.block.url, r) ? t.block.url : t.block.thumbnailUrl);
4193
4232
  return (t, r) => (f(), x("div", {
4194
4233
  class: "tpl:w-full",
4195
4234
  style: i(l.value)
@@ -4201,28 +4240,28 @@ var Bs = ["src", "alt"], Vs = {
4201
4240
  class: "tpl:w-full tpl:border-0",
4202
4241
  src: k(s),
4203
4242
  alt: e.block.alt
4204
- }, null, 8, Bs), w(Ls)], 4)) : a.value ? (f(), x("div", {
4243
+ }, null, 8, Us), w(Bs)], 4)) : a.value ? (f(), x("div", {
4205
4244
  key: 1,
4206
4245
  class: "tpl:relative tpl:!flex tpl:min-h-[150px] tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded tpl:border-2 tpl:border-dashed tpl:text-center tpl:bg-[var(--tpl-bg-elevated)]",
4207
4246
  style: i([{ "border-color": "color-mix(in srgb, var(--tpl-primary) 40%, transparent)" }, u.value])
4208
- }, [w(k(Yn), {
4247
+ }, [w(k(Zn), {
4209
4248
  size: 36,
4210
4249
  "stroke-width": 1.5,
4211
4250
  class: "tpl:text-[var(--tpl-primary)]",
4212
4251
  style: { opacity: "0.5" }
4213
- }), b("span", Vs, [w(Nn, { text: d.value }, null, 8, ["text"])])], 4)) : c.value ? (f(), x(A, { key: 2 }, [e.block.url ? (f(), x("a", {
4252
+ }), b("span", Ws, [w(Fn, { text: d.value }, null, 8, ["text"])])], 4)) : c.value ? (f(), x(j, { key: 2 }, [e.block.url ? (f(), x("a", {
4214
4253
  key: 0,
4215
4254
  href: e.block.url,
4216
4255
  target: "_blank",
4217
4256
  rel: "noopener noreferrer",
4218
4257
  class: "tpl:group tpl:relative tpl:inline-block",
4219
4258
  style: i(u.value),
4220
- onClick: r[0] ||= P(() => {}, ["prevent"])
4259
+ onClick: r[0] ||= F(() => {}, ["prevent"])
4221
4260
  }, [b("img", {
4222
4261
  class: "tpl:w-full tpl:border-0",
4223
4262
  src: c.value,
4224
4263
  alt: e.block.alt
4225
- }, null, 8, Us), w(Ls, { "hover-effect": "" })], 12, Hs)) : (f(), x("div", {
4264
+ }, null, 8, Ks), w(Bs, { "hover-effect": "" })], 12, Gs)) : (f(), x("div", {
4226
4265
  key: 1,
4227
4266
  class: "tpl:relative tpl:inline-block",
4228
4267
  style: i(u.value)
@@ -4230,31 +4269,31 @@ var Bs = ["src", "alt"], Vs = {
4230
4269
  class: "tpl:w-full tpl:border-0",
4231
4270
  src: c.value,
4232
4271
  alt: e.block.alt
4233
- }, null, 8, Ws), w(Ls)], 4))], 64)) : (f(), x("div", Gs, [w(k(Yn), {
4272
+ }, null, 8, qs), w(Bs)], 4))], 64)) : (f(), x("div", Js, [w(k(Zn), {
4234
4273
  size: 40,
4235
4274
  "stroke-width": 1.5,
4236
4275
  class: "tpl:text-[var(--tpl-border-light)]"
4237
4276
  }), b("span", null, p(k(n).video.addVideo), 1)]))], 4));
4238
4277
  }
4239
- }), qs = {
4240
- section: _s,
4241
- title: Ei,
4242
- paragraph: ci,
4243
- image: Yr,
4244
- button: In,
4245
- divider: kr,
4246
- video: Ks,
4247
- social: Ds,
4248
- menu: $r,
4249
- table: Is,
4250
- spacer: As,
4251
- html: Fr,
4278
+ }), Xs = {
4279
+ section: bs,
4280
+ title: Oi,
4281
+ paragraph: ui,
4282
+ image: Zr,
4283
+ button: Rn,
4284
+ divider: jr,
4285
+ video: Ys,
4286
+ social: As,
4287
+ menu: ti,
4288
+ table: zs,
4289
+ spacer: Ns,
4290
+ html: Lr,
4252
4291
  countdown: C(() => import("./CountdownBlock-Bn5w7C-p.js").then((e) => e.n))
4253
4292
  };
4254
- function Js(e) {
4293
+ function Zs(e) {
4255
4294
  let { editor: t, config: n, translations: r, fontsManager: i } = e, { t: a, format: o } = Ft(r);
4256
4295
  t.setUiTheme(n.uiTheme ?? "auto");
4257
- let { resolvedTheme: l } = hn(j(() => t.state.uiTheme)), d = _(n.theme ?? {}), { themeStyles: f } = _n({
4296
+ let { resolvedTheme: l } = hn(M(() => t.state.uiTheme)), d = _(n.theme ?? {}), { themeStyles: f } = _n({
4258
4297
  themeOverrides: d,
4259
4298
  resolvedTheme: l,
4260
4299
  extraStyles: e.themeExtraStyles
@@ -4282,21 +4321,31 @@ function Js(e) {
4282
4321
  let y = mn(t, {
4283
4322
  t: a,
4284
4323
  format: o
4285
- }), b = xn();
4286
- if (En(b, qs), n.customBlocks?.length) for (let e of n.customBlocks) b.registerCustom(e, Dr);
4287
- function x(e) {
4288
- for (let t of e) b.registerCustom(t, Dr);
4324
+ }), b = Ze(n.colors);
4325
+ if (b.allowCustomIgnored && bn.warn("config.colors.allowCustom: false is ignored without presets — keeping the color wheel and hex input so a color can still be chosen."), b.invalidPresets.length > 0 && bn.warn(`config.colors.presets skipped invalid entries: ${b.invalidPresets.join(", ")} — presets must be hex colors (#rgb or #rrggbb).`), b.allowCustom === !1) {
4326
+ let e = kn(b.presets, n.blockDefaults, n.templateDefaults);
4327
+ e.length > 0 && bn.warn(`config.colors locks custom colours, but these block/template default colours fall outside colors.presets: ${e.join(", ")}. New blocks start on a colour the palette can't reselect — set blockDefaults / templateDefaults from the same palette.`);
4328
+ }
4329
+ let x = xn();
4330
+ En(x, Xs);
4331
+ let S = /* @__PURE__ */ new Set();
4332
+ function C(e) {
4333
+ for (let t of e) {
4334
+ x.registerCustom(t, kr);
4335
+ for (let e of jn(t, b)) S.has(e.id) || (S.add(e.id), bn.warn(e.message));
4336
+ }
4289
4337
  }
4290
- let S = on();
4291
- if (s() && u(S.dispose), e.containerEl) {
4338
+ n.customBlocks?.length && C(n.customBlocks);
4339
+ let w = on();
4340
+ if (s() && u(w.dispose), e.containerEl) {
4292
4341
  let t = e.containerEl;
4293
4342
  et(document, "pointerdown", (e) => {
4294
4343
  let n = t.value;
4295
- n && (e.composedPath?.() ?? []).includes(n) && S.claim();
4344
+ n && (e.composedPath?.() ?? []).includes(n) && w.claim();
4296
4345
  }, { capture: !0 });
4297
4346
  }
4298
- function C(r) {
4299
- S.isActive() && jn(r, {
4347
+ function T(r) {
4348
+ w.isActive() && Nn(r, {
4300
4349
  history: p,
4301
4350
  selectBlock: (e) => t.selectBlock(e),
4302
4351
  getSelectedBlockId: () => t.state.selectedBlockId,
@@ -4305,27 +4354,21 @@ function Js(e) {
4305
4354
  onBeforeUndo: e.keyboardOptions?.onBeforeUndo
4306
4355
  });
4307
4356
  }
4308
- et(document, "keydown", C);
4309
- let w = _(null);
4310
- E(yt, e.editorRoot ?? document), E(lt, w), E(dt, r), E(bt, t), E(At, p), E(xt, m), E(_t, h), E(mt, i), E(st, f), E(Pt, l), E(ht, n.blockDefaults), E(Dt, b), E(vt, n.customBlocks ?? []), E(ct, n.paletteBlocks), E(Nt, Dn(n.htmlBlockPreview));
4311
- let T = Ze(n.colors);
4312
- if (T.allowCustomIgnored && bn.warn("config.colors.allowCustom: false is ignored without presets keeping the color wheel and hex input so a color can still be chosen."), T.invalidPresets.length > 0 && bn.warn(`config.colors.presets skipped invalid entries: ${T.invalidPresets.join(", ")} presets must be hex colors (#rgb or #rrggbb).`), T.allowCustom === !1) {
4313
- let e = kn(T.presets, n.blockDefaults, n.templateDefaults);
4314
- e.length > 0 && bn.warn(`config.colors locks custom colours, but these block/template default colours fall outside colors.presets: ${e.join(", ")}. New blocks start on a colour the palette can't reselect — set blockDefaults / templateDefaults from the same palette.`);
4315
- }
4316
- E(wt, T), E(Ot, Sn(t.content, b));
4317
- let D = me(n.mergeTags?.syntax);
4318
- E(pt, n.mergeTags?.tags ?? []), E(ut, D), E(St, n.mergeTags?.onRequest ?? null), E(at, n.mergeTags?.autocomplete !== !1), E(it, ln()), E(rt, n.logicTags?.tags ?? []), E(ft, n.logicTags?.pairs ?? []), E(Ct, n.logicTags?.onRequest ?? null), E(jt, un()), E(tt, n.onRequestMedia ?? null), E(gt, n.resolveImageUrl ? sn(n.resolveImageUrl) : null), E(Tt, n.displayConditions?.conditions ?? []), E(Et, n.displayConditions?.allowCustom ?? !1), E(kt, e.capabilities ?? {}), E(Mt, y);
4319
- let O = dn(n.lint) ? null : fn({
4357
+ et(document, "keydown", T);
4358
+ let D = _(null);
4359
+ E(yt, e.editorRoot ?? document), E(lt, D), E(dt, r), E(bt, t), E(At, p), E(xt, m), E(_t, h), E(mt, i), E(st, f), E(Pt, l), E(ht, n.blockDefaults), E(Dt, x), E(vt, n.customBlocks ?? []), E(ct, n.paletteBlocks), E(Nt, Dn(n.htmlBlockPreview)), E(wt, b), E(Ot, Sn(t.content, x));
4360
+ let O = pe(n.mergeTags?.syntax);
4361
+ E(pt, n.mergeTags?.tags ?? []), E(ut, O), E(St, n.mergeTags?.onRequest ?? null), E(at, n.mergeTags?.autocomplete !== !1), E(it, ln()), E(rt, n.logicTags?.tags ?? []), E(ft, n.logicTags?.pairs ?? []), E(Ct, n.logicTags?.onRequest ?? null), E(jt, un()), E(tt, n.onRequestMedia ?? null), E(gt, n.resolveImageUrl ? sn(n.resolveImageUrl) : null), E(Tt, n.displayConditions?.conditions ?? []), E(Et, n.displayConditions?.allowCustom ?? !1), E(kt, e.capabilities ?? {}), E(Mt, y);
4362
+ let k = dn(n.lint) ? null : fn({
4320
4363
  content: t.content,
4321
4364
  options: n.lint ?? {},
4322
4365
  updateBlock: t.updateBlock,
4323
4366
  updateSettings: t.updateSettings,
4324
4367
  removeBlock: t.removeBlock
4325
4368
  });
4326
- E(ot, O);
4327
- function k() {
4328
- v?.(), O?.destroy(), g?.destroy(), p.destroy();
4369
+ E(ot, k);
4370
+ function A() {
4371
+ v?.(), k?.destroy(), g?.destroy(), p.destroy();
4329
4372
  }
4330
4373
  return {
4331
4374
  t: a,
@@ -4337,13 +4380,13 @@ function Js(e) {
4337
4380
  resolvedTheme: l,
4338
4381
  themeStyles: f,
4339
4382
  themeOverrides: d,
4340
- registry: b,
4383
+ registry: x,
4341
4384
  keyboardReorder: y,
4342
- templateLint: O,
4343
- popoverRoot: w,
4344
- registerCustomBlocks: x,
4345
- destroy: k
4385
+ templateLint: k,
4386
+ popoverRoot: D,
4387
+ registerCustomBlocks: C,
4388
+ destroy: A
4346
4389
  };
4347
4390
  }
4348
4391
  //#endregion
4349
- export { qn as A, Gt as B, lr as C, tr as D, nr as E, zn as F, In as I, bn as L, Wn as M, Vn as N, Qn as O, Bn as P, pn as R, mr as S, rr as T, Fr as _, Ds as a, vr as b, ps as c, ui as d, li as f, Lr as g, Yr as h, As as i, Gn as j, Jn as k, Ei as l, $r as m, Ks as n, bs as o, ci as p, Is as r, _s as s, Js as t, wi as u, kr as v, cr as w, gr as x, Dr as y, en as z };
4392
+ export { Yn as A, en as B, dr as C, rr as D, ir as E, Vn as F, Rn as I, An as L, Kn as M, Un as N, er as O, Hn as P, bn as R, gr as S, ar as T, Gt as V, Lr as _, As as a, br as b, gs as c, fi as d, di as f, zr as g, Zr as h, Ns as i, qn as j, Xn as k, Oi as l, ti as m, Ys as n, Cs as o, ui as p, zs as r, bs as s, Zs as t, Ei as u, jr as v, ur as w, vr as x, kr as y, pn as z };