@aswin.dev/editor 0.8.5 → 0.8.7

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 (89) hide show
  1. package/dist/{AccessibilityPanel-COL6Wm7p.js → AccessibilityPanel-B39ct5ON.js} +2 -2
  2. package/dist/{AiChatSidebar-DAJOuHPG.js → AiChatSidebar-CYh7SPHW.js} +2 -2
  3. package/dist/{AiFeatureMenu-CKnEDzme.js → AiFeatureMenu-D9UhqJAa.js} +3 -3
  4. package/dist/{BlockA11yBadge-Qs6HtXid.js → BlockA11yBadge-Dr854uEe.js} +2 -2
  5. package/dist/{CloudEditor-BUlmUuhO.js → CloudEditor-BNEIze18.js} +281 -274
  6. package/dist/{CollaboratorBar-C6TfqpyV.js → CollaboratorBar-DZXuPSfU.js} +2 -2
  7. package/dist/{CommentsSidebar-DE6ZsM4D.js → CommentsSidebar-BVKFtxml.js} +4 -4
  8. package/dist/{CountdownBlock-Ba3T-i2X.js → CountdownBlock-CrpaDWze.js} +1 -1
  9. package/dist/{CountdownToolbar-B9IAZzeV.js → CountdownToolbar-D1tb2T_b.js} +2 -2
  10. package/dist/{DesignReferenceSidebar-C6yDJlD8.js → DesignReferenceSidebar-_QsmFpE_.js} +44 -44
  11. package/dist/{ModuleBrowserModal-DUKuDjS-.js → ModuleBrowserModal-Bth1crh_.js} +7 -7
  12. package/dist/{ModulePreviewCanvas-C9HTjfkN.js → ModulePreviewCanvas-96pndrb9.js} +3 -3
  13. package/dist/{ParagraphEditor-CFuaZKGk.js → ParagraphEditor-C2d9O2P4.js} +123 -123
  14. package/dist/{RichTextEditorContent-CrqPQdnk.js → RichTextEditorContent-Cn0ZU41b.js} +3 -3
  15. package/dist/{SaveModuleDialog-QjgPFEDg.js → SaveModuleDialog-B1EJtMGq.js} +17 -17
  16. package/dist/{SlidingPillSelect-DfcBdJqN.js → SlidingPillSelect-Dt34f5VF.js} +1 -1
  17. package/dist/{SnapshotHistory-Dblt21_W.js → SnapshotHistory-Cd-a_xGv.js} +3 -3
  18. package/dist/{TemplateScoringPanel-CS7o62zS.js → TemplateScoringPanel-C8WixDsv.js} +77 -77
  19. package/dist/{TestEmailModal-D_y3ZksG.js → TestEmailModal-CEj_81cQ.js} +3 -3
  20. package/dist/TitleEditor-C8Qyr_U3.js +172 -0
  21. package/dist/{TplModal-DinL7DhQ.js → TplModal-B_HcUS4S.js} +2 -2
  22. package/dist/{blockTypeIcons-JjmIZ_Vx.js → blockTypeIcons-CeaSm2Xd.js} +1 -1
  23. package/dist/bundle-stats.json +6 -6
  24. package/dist/cdn/chunks/{AccessibilityPanel-BTADkTp2.js → AccessibilityPanel-C8vY7QIF.js} +3 -3
  25. package/dist/cdn/chunks/{AccessibilityPanel-BTADkTp2.js.map → AccessibilityPanel-C8vY7QIF.js.map} +1 -1
  26. package/dist/cdn/chunks/{AiFeatureMenu-D99Pw32q.js → AiFeatureMenu-BaUpnF6T.js} +2 -2
  27. package/dist/cdn/chunks/{AiFeatureMenu-D99Pw32q.js.map → AiFeatureMenu-BaUpnF6T.js.map} +1 -1
  28. package/dist/cdn/chunks/{BlockA11yBadge-dtyeSSvY.js → BlockA11yBadge-BHkh4Otq.js} +2 -2
  29. package/dist/cdn/chunks/{BlockA11yBadge-dtyeSSvY.js.map → BlockA11yBadge-BHkh4Otq.js.map} +1 -1
  30. package/dist/cdn/chunks/{CloudEditor-BBBkTBfW.js → CloudEditor-DUIjZDAS.js} +264 -257
  31. package/dist/cdn/chunks/{CloudEditor-BBBkTBfW.js.map → CloudEditor-DUIjZDAS.js.map} +1 -1
  32. package/dist/cdn/chunks/{CollaboratorBar-Cuy1BusU.js → CollaboratorBar-pyuEO5Bm.js} +3 -3
  33. package/dist/cdn/chunks/{CollaboratorBar-Cuy1BusU.js.map → CollaboratorBar-pyuEO5Bm.js.map} +1 -1
  34. package/dist/cdn/chunks/{CountdownToolbar-CqFM85Xv.js → CountdownToolbar-CCGHm6Gg.js} +3 -3
  35. package/dist/cdn/chunks/{CountdownToolbar-CqFM85Xv.js.map → CountdownToolbar-CCGHm6Gg.js.map} +1 -1
  36. package/dist/cdn/chunks/{ModuleBrowserModal-Dcxtq_dC.js → ModuleBrowserModal-DKsMddYS.js} +6 -6
  37. package/dist/cdn/chunks/{ModuleBrowserModal-Dcxtq_dC.js.map → ModuleBrowserModal-DKsMddYS.js.map} +1 -1
  38. package/dist/cdn/chunks/{ModulePreviewCanvas-Didb4ZCU.js → ModulePreviewCanvas-E0mfCUJi.js} +2 -2
  39. package/dist/cdn/chunks/{ModulePreviewCanvas-Didb4ZCU.js.map → ModulePreviewCanvas-E0mfCUJi.js.map} +1 -1
  40. package/dist/cdn/chunks/{ParagraphEditor-BX2L35YF.js → ParagraphEditor-DwmzHg6F.js} +116 -116
  41. package/dist/cdn/chunks/ParagraphEditor-DwmzHg6F.js.map +1 -0
  42. package/dist/cdn/chunks/{RichTextEditorContent-ywrdsvHY.js → RichTextEditorContent-4-cNqB4H.js} +3 -3
  43. package/dist/cdn/chunks/{RichTextEditorContent-ywrdsvHY.js.map → RichTextEditorContent-4-cNqB4H.js.map} +1 -1
  44. package/dist/cdn/chunks/{SaveModuleDialog-Ddp-HCFB.js → SaveModuleDialog-COm3ptOF.js} +3 -3
  45. package/dist/cdn/chunks/{SaveModuleDialog-Ddp-HCFB.js.map → SaveModuleDialog-COm3ptOF.js.map} +1 -1
  46. package/dist/cdn/chunks/{SlidingPillSelect-CS6N3vGq.js → SlidingPillSelect-DlgRynQN.js} +2 -2
  47. package/dist/cdn/chunks/{SlidingPillSelect-CS6N3vGq.js.map → SlidingPillSelect-DlgRynQN.js.map} +1 -1
  48. package/dist/cdn/chunks/TitleEditor-CE8r8txX.js +171 -0
  49. package/dist/cdn/chunks/TitleEditor-CE8r8txX.js.map +1 -0
  50. package/dist/cdn/chunks/{blockTypeIcons-B2x3gJsz.js → blockTypeIcons-BOf7hTFU.js} +3 -3
  51. package/dist/cdn/chunks/{blockTypeIcons-B2x3gJsz.js.map → blockTypeIcons-BOf7hTFU.js.map} +1 -1
  52. package/dist/cdn/chunks/{extensions-CdYSoz4B.js → extensions-B5e8Ov02.js} +17 -17
  53. package/dist/cdn/chunks/{extensions-CdYSoz4B.js.map → extensions-B5e8Ov02.js.map} +1 -1
  54. package/dist/cdn/chunks/{features-BZeMkHMs.js → features-BHTP4oRU.js} +734 -734
  55. package/dist/cdn/chunks/features-BHTP4oRU.js.map +1 -0
  56. package/dist/cdn/chunks/{icons-nP0Wj6Eq.js → icons-DS4IYWzG.js} +2 -2
  57. package/dist/cdn/chunks/{icons-nP0Wj6Eq.js.map → icons-DS4IYWzG.js.map} +1 -1
  58. package/dist/cdn/chunks/{media-library-54Ezt5wL.js → media-library-BLLJsLwk.js} +508 -508
  59. package/dist/cdn/chunks/{media-library-54Ezt5wL.js.map → media-library-BLLJsLwk.js.map} +1 -1
  60. package/dist/cdn/chunks/{quality-Di1pUcCW.js → quality-DfKLOn8j.js} +290 -290
  61. package/dist/cdn/chunks/{quality-Di1pUcCW.js.map → quality-DfKLOn8j.js.map} +1 -1
  62. package/dist/cdn/chunks/{renderer-C4OuJhDG.js → renderer-fG9yLafB.js} +14 -14
  63. package/dist/cdn/chunks/{renderer-C4OuJhDG.js.map → renderer-fG9yLafB.js.map} +1 -1
  64. package/dist/cdn/chunks/{src-DF5NNH7S.js → src-DsfVhQaK.js} +4 -4
  65. package/dist/cdn/chunks/{src-DF5NNH7S.js.map → src-DsfVhQaK.js.map} +1 -1
  66. package/dist/cdn/chunks/{styles-C9P3yzMF.js → styles-CPUuKOlD.js} +210 -210
  67. package/dist/cdn/chunks/{styles-C9P3yzMF.js.map → styles-CPUuKOlD.js.map} +1 -1
  68. package/dist/cdn/chunks/{tiptap-CZ52Pj8k.js → tiptap-q69oUYhb.js} +2 -2
  69. package/dist/cdn/chunks/{tiptap-CZ52Pj8k.js.map → tiptap-q69oUYhb.js.map} +1 -1
  70. package/dist/cdn/editor.css +1 -1
  71. package/dist/cdn/editor.js +130 -123
  72. package/dist/cdn/editor.js.map +1 -1
  73. package/dist/{extensions-CNPdJw_8.js → extensions-mwqd2u9M.js} +2 -2
  74. package/dist/index.d.ts +6 -6
  75. package/dist/keys-CqdzeWhT.js +10 -0
  76. package/dist/style.css +1 -1
  77. package/dist/{styles-ZIYLQwFf.js → styles-BRNubGRJ.js} +287 -287
  78. package/dist/templatical-editor.js +134 -127
  79. package/dist/{useCloudI18n-DOKSZql1.js → useCloudI18n-CDhjmAgB.js} +1 -1
  80. package/dist/{useEditorCore-BHSyoxSK.js → useEditorCore-DB4A_cje.js} +22 -22
  81. package/dist/{useI18n-C2xQZ6K9.js → useI18n-DLZJ6wNn.js} +1 -1
  82. package/dist/{useMergeTag-BfVcyNSv.js → useMergeTag-D-kqWENN.js} +2 -2
  83. package/package.json +7 -7
  84. package/dist/TitleEditor-CHmL3FFR.js +0 -172
  85. package/dist/cdn/chunks/ParagraphEditor-BX2L35YF.js.map +0 -1
  86. package/dist/cdn/chunks/TitleEditor-BTtgZzci.js +0 -171
  87. package/dist/cdn/chunks/TitleEditor-BTtgZzci.js.map +0 -1
  88. package/dist/cdn/chunks/features-BZeMkHMs.js.map +0 -1
  89. package/dist/keys-CvX8D-8C.js +0 -10
@@ -1,22 +1,22 @@
1
- import { C as e, F as t, G as n, M as r, N as i, P as a, T as o, W as s, _ as c, b as l, ct as u, dt as d, f as ee, ft as f, g as p, h as m, l as h, m as g, n as te, r as _, tt as v, ut as y, v as b, x, y as S } from "./chunks/draggable-C-1_gch3.js";
2
- import { $ as C, Bn as ne, Dn as re, fn as w, k as ie, on as ae, ot as T, ur as E, zn as oe } from "./chunks/features-BZeMkHMs.js";
3
- import { D as se } from "./chunks/icons-nP0Wj6Eq.js";
4
- import { a as ce, c as le, d as ue, f as de, g as fe, h as D, i as pe, l as me, m as O, n as he, o as k, p as A, r as j, s as M, t as N, u as P } from "./chunks/styles-C9P3yzMF.js";
1
+ import { C as e, F as t, G as n, M as r, N as i, P as a, T as o, W as s, _ as c, b as l, ct as u, dt as d, f as ee, ft as f, g as p, h as m, l as h, m as g, n as _, r as v, tt as y, ut as b, v as x, x as S, y as te } from "./chunks/draggable-C-1_gch3.js";
2
+ import { $ as C, Bn as ne, On as re, Vn as w, dr as T, en as ie, k as ae, ot as E, pn as D, sn as oe } from "./chunks/features-BHTP4oRU.js";
3
+ import { D as se } from "./chunks/icons-DS4IYWzG.js";
4
+ import { a as ce, c as le, d as ue, f as de, g as fe, h as O, i as pe, l as me, m as k, n as he, o as A, p as j, r as M, s as N, t as P, u as F } from "./chunks/styles-CPUuKOlD.js";
5
5
  //#region src/Editor.vue?vue&type=script&setup=true&lang.ts
6
- var F = ["data-tpl-theme"], I = {
6
+ var I = ["data-tpl-theme"], L = {
7
7
  class: "tpl-header tpl:absolute tpl:top-0 tpl:right-0 tpl:left-0 tpl:z-50 tpl:grid tpl:h-14 tpl:grid-cols-[1fr_auto_1fr] tpl:items-center tpl:px-4 tpl:shadow-[var(--tpl-shadow-md)] tpl:border-b tpl:border-[var(--tpl-border)]",
8
8
  style: {
9
9
  "background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)",
10
10
  "backdrop-filter": "blur(12px)",
11
11
  "-webkit-backdrop-filter": "blur(12px)"
12
12
  }
13
- }, L = { class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-10" }, R = { class: "tpl:sticky tpl:top-0 tpl:z-40 tpl:h-0" }, ge = {
13
+ }, R = { class: "tpl:flex tpl:items-center tpl:justify-center tpl:gap-10" }, ge = { class: "tpl:sticky tpl:top-0 tpl:z-40 tpl:h-0" }, _e = {
14
14
  key: 0,
15
15
  class: "tpl:flex tpl:w-full tpl:flex-col tpl:gap-3 tpl:px-4 tpl:pt-4 tpl:pb-6"
16
- }, _e = { class: "tpl-popup-browser-frame tpl:flex tpl:min-h-[calc(100vh-11rem)] tpl:w-full tpl:flex-col tpl:overflow-hidden tpl:rounded-xl tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:shadow-[var(--tpl-shadow-xl)]" }, ve = {
16
+ }, ve = { class: "tpl-popup-browser-frame tpl:flex tpl:min-h-[calc(100vh-11rem)] tpl:w-full tpl:flex-col tpl:overflow-hidden tpl:rounded-xl tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:shadow-[var(--tpl-shadow-xl)]" }, ye = {
17
17
  key: 1,
18
18
  class: "tpl:flex tpl:w-full tpl:flex-col tpl:items-center tpl:gap-3 tpl:p-8"
19
- }, ye = ["aria-label"], z = /* @__PURE__ */ T(/* @__PURE__ */ e({
19
+ }, be = ["aria-label"], z = /* @__PURE__ */ E(/* @__PURE__ */ e({
20
20
  __name: "Editor",
21
21
  props: {
22
22
  config: {},
@@ -24,116 +24,118 @@ var F = ["data-tpl-theme"], I = {
24
24
  fontsManager: {}
25
25
  },
26
26
  setup(e, { expose: o }) {
27
- let _ = v(null), C = e, T = re({
28
- content: C.config.content,
29
- templateDefaults: C.config.templateDefaults
30
- }), E = ie({
31
- editor: T,
27
+ let v = y(null), C = y(null);
28
+ t(ie, C);
29
+ let T = e, E = re({
30
+ content: T.config.content,
31
+ templateDefaults: T.config.templateDefaults
32
+ }), A = ae({
33
+ editor: E,
32
34
  config: {
33
- uiTheme: C.config.uiTheme,
34
- theme: C.config.theme,
35
- blockDefaults: C.config.blockDefaults,
36
- customBlocks: C.config.customBlocks,
37
- mergeTags: C.config.mergeTags,
38
- displayConditions: C.config.displayConditions,
39
- onRequestMedia: C.config.onRequestMedia,
40
- editorType: C.config.editorType,
41
- accessibility: fe(C.config),
42
- onSave: C.config.onSave ? () => C.config.onSave(JSON.parse(JSON.stringify(T.state.content))) : void 0
35
+ uiTheme: T.config.uiTheme,
36
+ theme: T.config.theme,
37
+ blockDefaults: T.config.blockDefaults,
38
+ customBlocks: T.config.customBlocks,
39
+ mergeTags: T.config.mergeTags,
40
+ displayConditions: T.config.displayConditions,
41
+ onRequestMedia: T.config.onRequestMedia,
42
+ editorType: T.config.editorType,
43
+ accessibility: fe(T.config),
44
+ onSave: T.config.onSave ? () => T.config.onSave(JSON.parse(JSON.stringify(E.state.content))) : void 0
43
45
  },
44
- translations: C.translations,
45
- fontsManager: C.fontsManager,
46
- autoSaveOptions: C.config.onChange ? { onChange: () => C.config.onChange(JSON.parse(JSON.stringify(T.state.content))) } : null
46
+ translations: T.translations,
47
+ fontsManager: T.fontsManager,
48
+ autoSaveOptions: T.config.onChange ? { onChange: () => T.config.onChange(JSON.parse(JSON.stringify(E.state.content))) } : null
47
49
  });
48
50
  r(async () => {
49
- if (await C.fontsManager.loadCustomFonts(), w(C.config.editorType) === "popup" && !T.content.value.settings.popup) {
50
- let e = ne();
51
- T.updateSettings({
51
+ if (await T.fontsManager.loadCustomFonts(), D(T.config.editorType) === "popup" && !E.content.value.settings.popup) {
52
+ let e = w();
53
+ E.updateSettings({
52
54
  popup: e,
53
- width: oe[e.design.sizePreset]
55
+ width: ne[e.design.sizePreset]
54
56
  });
55
57
  }
56
58
  }), i(() => {
57
- C.fontsManager.cleanupFontLinks(), E.destroy();
59
+ T.fontsManager.cleanupFontLinks(), A.destroy();
58
60
  });
59
- let k = v("blocks");
60
- t(ae, k);
61
- let z = g(() => w(C.config.editorType) === "popup"), B = g(() => z.value && k.value === "displayRules"), V = g(() => z.value && k.value === "schedule"), H = g(() => k.value === "design"), U = g(() => z.value && (B.value || V.value || H.value)), W = g(() => {
62
- if (T.state.previewMode) return ["tpl:left-0", "tpl:right-0"];
63
- if (!z.value) return ["tpl:left-12", "tpl:right-[320px]"];
61
+ let z = y("blocks");
62
+ t(oe, z);
63
+ let B = g(() => D(T.config.editorType) === "popup"), V = g(() => B.value && z.value === "displayRules"), H = g(() => B.value && z.value === "schedule"), U = g(() => z.value === "design"), W = g(() => B.value && (V.value || H.value || U.value)), G = g(() => {
64
+ if (E.state.previewMode) return ["tpl:left-0", "tpl:right-0"];
65
+ if (!B.value) return ["tpl:left-12", "tpl:right-[320px]"];
64
66
  let e;
65
- return e = k.value === "blocks" ? "tpl:left-[272px]" : H.value ? "tpl:left-[392px]" : "tpl:left-[72px]", [e, U.value ? "tpl:right-0" : "tpl:right-[320px]"];
66
- }), G = g(() => B.value || V.value);
67
+ return e = z.value === "blocks" ? "tpl:left-[272px]" : U.value ? "tpl:left-[392px]" : "tpl:left-[72px]", [e, W.value ? "tpl:right-0" : "tpl:right-[320px]"];
68
+ }), K = g(() => V.value || H.value);
67
69
  return o({
68
- getContent: () => T.content.value,
69
- setContent: (e) => T.setContent(e),
70
- setTheme: (e) => T.setUiTheme(e),
71
- undo: () => E.history.undo(),
72
- redo: () => E.history.redo(),
73
- canUndo: () => E.history.canUndo.value,
74
- canRedo: () => E.history.canRedo.value,
75
- renderCustomBlock: E.registry.renderCustomBlock,
76
- startTour: (e) => _.value?.start(e),
77
- dismissTour: () => _.value?.dismiss(),
78
- resetTourDismissed: () => pe(C.config.tour),
79
- isTourDismissed: () => C.config.tour ? ce(C.config.tour) : !0
80
- }), (t, r) => (a(), b("div", {
81
- class: y(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": u(T).state.darkMode }]),
82
- "data-tpl-theme": u(E).resolvedTheme.value,
83
- style: d(u(E).themeStyles.value)
70
+ getContent: () => E.content.value,
71
+ setContent: (e) => E.setContent(e),
72
+ setTheme: (e) => E.setUiTheme(e),
73
+ undo: () => A.history.undo(),
74
+ redo: () => A.history.redo(),
75
+ canUndo: () => A.history.canUndo.value,
76
+ canRedo: () => A.history.canRedo.value,
77
+ renderCustomBlock: A.registry.renderCustomBlock,
78
+ startTour: (e) => v.value?.start(e),
79
+ dismissTour: () => v.value?.dismiss(),
80
+ resetTourDismissed: () => pe(T.config.tour),
81
+ isTourDismissed: () => T.config.tour ? ce(T.config.tour) : !0
82
+ }), (t, r) => (a(), x("div", {
83
+ class: b(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": u(E).state.darkMode }]),
84
+ "data-tpl-theme": u(A).resolvedTheme.value,
85
+ style: d(u(A).themeStyles.value)
84
86
  }, [
85
- m("header", I, [
87
+ m("header", L, [
86
88
  r[5] ||= m("div", { class: "tpl:flex tpl:items-center tpl:gap-2.5" }, null, -1),
87
- m("div", L, [
88
- x(ue),
89
- x(P, {
90
- viewport: u(T).state.viewport,
91
- onChange: u(T).setViewport
89
+ m("div", R, [
90
+ S(ue),
91
+ S(F, {
92
+ viewport: u(E).state.viewport,
93
+ onChange: u(E).setViewport
92
94
  }, null, 8, ["viewport", "onChange"]),
93
- x(le, {
94
- "dark-mode": u(T).state.darkMode,
95
- onChange: u(T).setDarkMode
95
+ S(le, {
96
+ "dark-mode": u(E).state.darkMode,
97
+ onChange: u(E).setDarkMode
96
98
  }, null, 8, ["dark-mode", "onChange"]),
97
- x(me, {
98
- "preview-mode": u(T).state.previewMode,
99
- onChange: u(T).setPreviewMode
99
+ S(me, {
100
+ "preview-mode": u(E).state.previewMode,
101
+ onChange: u(E).setPreviewMode
100
102
  }, null, 8, ["preview-mode", "onChange"])
101
103
  ]),
102
104
  r[6] ||= m("div", { class: "tpl:flex tpl:min-w-[200px] tpl:items-center tpl:justify-end tpl:gap-3" }, null, -1)
103
105
  ]),
104
- n(x(A, null, null, 512), [[h, !u(T).state.previewMode]]),
106
+ n(S(j, null, null, 512), [[h, !u(E).state.previewMode]]),
105
107
  m("div", {
106
- class: y(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [...W.value, "tpl:top-14"]]),
108
+ class: b(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [...G.value, "tpl:top-14"]]),
107
109
  style: d({
108
110
  transition: "all 300ms cubic-bezier(0.34, 1.56, 0.64, 1)",
109
- backgroundColor: G.value ? "var(--tpl-bg)" : "var(--tpl-canvas-bg)"
111
+ backgroundColor: K.value ? "var(--tpl-bg)" : "var(--tpl-canvas-bg)"
110
112
  })
111
- }, [z.value && k.value === "displayRules" ? (a(), p(he, { key: 0 })) : z.value && k.value === "schedule" ? (a(), p(N, {
113
+ }, [B.value && z.value === "displayRules" ? (a(), p(he, { key: 0 })) : B.value && z.value === "schedule" ? (a(), p(P, {
112
114
  key: 1,
113
115
  layout: "standalone"
114
- })) : (a(), b(ee, { key: 2 }, [m("div", R, [x(te, { name: "tpl-restore-btn" }, {
115
- default: s(() => [u(E).conditionPreview.hasHiddenBlocks.value ? (a(), b("button", {
116
+ })) : (a(), x(ee, { key: 2 }, [m("div", ge, [S(_, { name: "tpl-restore-btn" }, {
117
+ default: s(() => [u(A).conditionPreview.hasHiddenBlocks.value ? (a(), x("button", {
116
118
  key: 0,
117
119
  class: "tpl:absolute tpl:left-1/2 tpl:top-2 tpl:-translate-x-1/2 tpl:inline-flex tpl:items-center tpl:gap-1.5 tpl:rounded-full tpl:border tpl:px-3.5 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:whitespace-nowrap tpl:shadow-md tpl:hover:opacity-80 tpl:bg-[var(--tpl-warning-light)] tpl:text-[var(--tpl-warning)] tpl:border-[var(--tpl-warning)]",
118
120
  style: { "backdrop-filter": "blur(8px)" },
119
- onClick: r[0] ||= (e) => u(E).conditionPreview.reset()
120
- }, [x(u(se), {
121
+ onClick: r[0] ||= (e) => u(A).conditionPreview.reset()
122
+ }, [S(u(se), {
121
123
  size: 13,
122
124
  "stroke-width": 2
123
- }), l(" " + f(u(E).t.blockSettings.restoreHiddenBlocks), 1)])) : c("", !0)]),
125
+ }), l(" " + f(u(A).t.blockSettings.restoreHiddenBlocks), 1)])) : c("", !0)]),
124
126
  _: 1
125
- })]), z.value ? (a(), b("div", ge, [x(O, {
126
- "preview-mode": u(T).state.previewMode,
127
+ })]), B.value ? (a(), x("div", _e, [S(k, {
128
+ "preview-mode": u(E).state.previewMode,
127
129
  "multi-page-canvas": e.config.multiPageCanvas ?? !1
128
- }, null, 8, ["preview-mode", "multi-page-canvas"]), m("div", _e, [r[7] ||= S("<div class=\"tpl-popup-browser-bar tpl:relative tpl:flex tpl:h-9 tpl:items-center tpl:gap-1.5 tpl:border-b tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-elevated)] tpl:px-3\" aria-hidden=\"true\" data-v-186f5453><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#ff5f57;\" data-v-186f5453></span><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#febc2e;\" data-v-186f5453></span><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#28c840;\" data-v-186f5453></span><div class=\"tpl:pointer-events-none tpl:absolute tpl:left-1/2 tpl:top-1/2 tpl:-translate-x-1/2 tpl:-translate-y-1/2 tpl:rounded-md tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-0.5 tpl:text-[11px] tpl:font-medium tpl:text-[var(--tpl-text-muted)] tpl:tracking-tight\" data-v-186f5453> yourstore.com </div></div>", 1), x(D, {
130
+ }, null, 8, ["preview-mode", "multi-page-canvas"]), m("div", ve, [r[7] ||= te("<div class=\"tpl-popup-browser-bar tpl:relative tpl:flex tpl:h-9 tpl:items-center tpl:gap-1.5 tpl:border-b tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-elevated)] tpl:px-3\" aria-hidden=\"true\" data-v-1fdbd0b6><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#ff5f57;\" data-v-1fdbd0b6></span><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#febc2e;\" data-v-1fdbd0b6></span><span class=\"tpl:block tpl:size-3 tpl:rounded-full\" style=\"background-color:#28c840;\" data-v-1fdbd0b6></span><div class=\"tpl:pointer-events-none tpl:absolute tpl:left-1/2 tpl:top-1/2 tpl:-translate-x-1/2 tpl:-translate-y-1/2 tpl:rounded-md tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-0.5 tpl:text-[11px] tpl:font-medium tpl:text-[var(--tpl-text-muted)] tpl:tracking-tight\" data-v-1fdbd0b6> yourstore.com </div></div>", 1), S(O, {
129
131
  class: "tpl:flex tpl:min-h-0 tpl:flex-1 tpl:flex-col",
130
- viewport: u(T).state.viewport,
131
- content: u(T).content.value,
132
- "selected-block-id": u(T).state.selectedBlockId,
133
- "dark-mode": u(T).state.darkMode,
134
- "preview-mode": u(T).state.previewMode,
132
+ viewport: u(E).state.viewport,
133
+ content: u(E).content.value,
134
+ "selected-block-id": u(E).state.selectedBlockId,
135
+ "dark-mode": u(E).state.darkMode,
136
+ "preview-mode": u(E).state.previewMode,
135
137
  "multi-page-canvas": e.config.multiPageCanvas ?? !1,
136
- onSelectBlock: u(T).selectBlock
138
+ onSelectBlock: u(E).selectBlock
137
139
  }, null, 8, [
138
140
  "viewport",
139
141
  "content",
@@ -142,17 +144,17 @@ var F = ["data-tpl-theme"], I = {
142
144
  "preview-mode",
143
145
  "multi-page-canvas",
144
146
  "onSelectBlock"
145
- ])])])) : (a(), b("div", ve, [x(O, {
146
- "preview-mode": u(T).state.previewMode,
147
+ ])])])) : (a(), x("div", ye, [S(k, {
148
+ "preview-mode": u(E).state.previewMode,
147
149
  "multi-page-canvas": e.config.multiPageCanvas ?? !1
148
- }, null, 8, ["preview-mode", "multi-page-canvas"]), x(D, {
149
- viewport: u(T).state.viewport,
150
- content: u(T).content.value,
151
- "selected-block-id": u(T).state.selectedBlockId,
152
- "dark-mode": u(T).state.darkMode,
153
- "preview-mode": u(T).state.previewMode,
150
+ }, null, 8, ["preview-mode", "multi-page-canvas"]), S(O, {
151
+ viewport: u(E).state.viewport,
152
+ content: u(E).content.value,
153
+ "selected-block-id": u(E).state.selectedBlockId,
154
+ "dark-mode": u(E).state.darkMode,
155
+ "preview-mode": u(E).state.previewMode,
154
156
  "multi-page-canvas": e.config.multiPageCanvas ?? !1,
155
- onSelectBlock: u(T).selectBlock
157
+ onSelectBlock: u(E).selectBlock
156
158
  }, null, 8, [
157
159
  "viewport",
158
160
  "content",
@@ -162,39 +164,44 @@ var F = ["data-tpl-theme"], I = {
162
164
  "multi-page-canvas",
163
165
  "onSelectBlock"
164
166
  ])]))], 64))], 6),
165
- e.config.branding === !1 ? c("", !0) : (a(), p(M, {
167
+ e.config.branding === !1 ? c("", !0) : (a(), p(N, {
166
168
  key: 0,
167
- "position-class": W.value
169
+ "position-class": G.value
168
170
  }, null, 8, ["position-class"])),
169
171
  m("div", {
170
172
  class: "tpl-sr-only",
171
173
  role: "status",
172
174
  "aria-live": "polite",
173
175
  "aria-atomic": "true",
174
- "aria-label": u(E).t.landmarks.reorderAnnouncements
175
- }, f(u(E).keyboardReorder.announcement.value), 9, ye),
176
- n(x(de, {
177
- "selected-block": u(T).selectedBlock.value,
178
- settings: u(T).content.value.settings,
179
- onUpdateBlock: r[1] ||= (e) => u(T).updateBlock(u(T).state.selectedBlockId, e),
176
+ "aria-label": u(A).t.landmarks.reorderAnnouncements
177
+ }, f(u(A).keyboardReorder.announcement.value), 9, be),
178
+ n(S(de, {
179
+ "selected-block": u(E).selectedBlock.value,
180
+ settings: u(E).content.value.settings,
181
+ onUpdateBlock: r[1] ||= (e) => u(E).updateBlock(u(E).state.selectedBlockId, e),
180
182
  onDeleteBlock: r[2] ||= () => {
181
- u(T).state.selectedBlockId && u(E).blockActions.deleteBlock(u(T).state.selectedBlockId);
183
+ u(E).state.selectedBlockId && u(A).blockActions.deleteBlock(u(E).state.selectedBlockId);
182
184
  },
183
185
  onDuplicateBlock: r[3] ||= () => {
184
- u(T).selectedBlock.value && u(E).blockActions.duplicateBlock(u(T).selectedBlock.value);
186
+ u(E).selectedBlock.value && u(A).blockActions.duplicateBlock(u(E).selectedBlock.value);
185
187
  },
186
- onUpdateSettings: r[4] ||= (e) => u(T).updateSettings(e)
187
- }, null, 8, ["selected-block", "settings"]), [[h, !u(T).state.previewMode && !U.value]]),
188
- e.config.tour ? (a(), p(j, {
188
+ onUpdateSettings: r[4] ||= (e) => u(E).updateSettings(e)
189
+ }, null, 8, ["selected-block", "settings"]), [[h, !u(E).state.previewMode && !W.value]]),
190
+ m("div", {
191
+ ref_key: "floatingUiTeleportEl",
192
+ ref: C,
193
+ class: "tpl-editor-floating-ui tpl:pointer-events-none tpl:fixed tpl:inset-0 tpl:z-[9999] tpl:overflow-visible"
194
+ }, null, 512),
195
+ e.config.tour ? (a(), p(M, {
189
196
  key: 1,
190
197
  ref_key: "editorTourRef",
191
- ref: _,
198
+ ref: v,
192
199
  "tour-config": e.config.tour,
193
- "dark-mode": u(T).state.darkMode
200
+ "dark-mode": u(E).state.darkMode
194
201
  }, null, 8, ["tour-config", "dark-mode"])) : c("", !0)
195
- ], 14, F));
202
+ ], 14, I));
196
203
  }
197
- }), [["__scopeId", "data-v-186f5453"]]), B = /* @__PURE__ */ Object.assign({
204
+ }), [["__scopeId", "data-v-1fdbd0b6"]]), B = /* @__PURE__ */ Object.assign({
198
205
  "./locales/de.ts": () => import("./chunks/de-Dum1oCPV.js"),
199
206
  "./locales/en.ts": () => import("./chunks/en-ClDdvkbR.js")
200
207
  }), V = /* @__PURE__ */ Object.assign({
@@ -216,16 +223,16 @@ async function q(e) {
216
223
  let t = B[`./locales/${K(e, U)}.ts`];
217
224
  return (await t()).default;
218
225
  }
219
- async function be(e) {
226
+ async function xe(e) {
220
227
  let t = V[`./locales/cloud/${K(e, W)}.ts`];
221
228
  return (await t()).default;
222
229
  }
223
230
  //#endregion
224
231
  //#region src/utils/toMjml.ts
225
- async function xe(e) {
232
+ async function Se(e) {
226
233
  let t;
227
234
  try {
228
- t = await import("./chunks/renderer-C4OuJhDG.js").then((e) => e.t);
235
+ t = await import("./chunks/renderer-fG9yLafB.js").then((e) => e.t);
229
236
  } catch {
230
237
  throw Error("[Templatical] toMjml() requires the @aswin.dev/renderer package. Please install it.");
231
238
  }
@@ -233,12 +240,12 @@ async function xe(e) {
233
240
  }
234
241
  //#endregion
235
242
  //#region src/index.ts
236
- var J = null, Y = v(null);
237
- async function Se(e) {
243
+ var J = null, Y = y(null);
244
+ async function Ce(e) {
238
245
  let t = typeof e.container == "string" ? document.querySelector(e.container) : e.container;
239
246
  if (!t) throw Error(`[Templatical] Container element not found: ${e.container}`);
240
247
  let n = await q(e.locale ?? "en"), r = C(e.fonts);
241
- J && Q(), J = _({ setup() {
248
+ J && Q(), J = v({ setup() {
242
249
  return () => o(z, {
243
250
  config: e,
244
251
  translations: n,
@@ -284,20 +291,20 @@ async function Se(e) {
284
291
  renderCustomBlock(e) {
285
292
  return Y.value ? Y.value.renderCustomBlock(e) : Promise.reject(/* @__PURE__ */ Error("[Templatical] Editor not ready"));
286
293
  },
287
- toMjml: () => xe(i)
294
+ toMjml: () => Se(i)
288
295
  };
289
296
  return i;
290
297
  }
291
- var X = null, Z = v(null);
292
- async function Ce(e) {
298
+ var X = null, Z = y(null);
299
+ async function we(e) {
293
300
  let t = typeof e.container == "string" ? document.querySelector(e.container) : e.container;
294
301
  if (!t) throw Error(`[Templatical] Container element not found: ${e.container}`);
295
- let { default: n } = await import("./chunks/CloudEditor-BBBkTBfW.js"), [r, i] = await Promise.all([q(e.locale ?? "en"), be(e.locale ?? "en")]), a = C(e.fonts);
302
+ let { default: n } = await import("./chunks/CloudEditor-DUIjZDAS.js"), [r, i] = await Promise.all([q(e.locale ?? "en"), xe(e.locale ?? "en")]), a = C(e.fonts);
296
303
  return X && $(), await new Promise((s, c) => {
297
304
  let l = setTimeout(() => {
298
305
  c(/* @__PURE__ */ Error("[Templatical] Cloud editor initialization timed out"));
299
- }, E);
300
- X = _({ setup() {
306
+ }, T);
307
+ X = v({ setup() {
301
308
  return () => o(n, {
302
309
  config: e,
303
310
  translations: r,
@@ -362,6 +369,6 @@ function $() {
362
369
  X && (X.unmount(), X = null, Z.value = null);
363
370
  }
364
371
  //#endregion
365
- export { k as DEFAULT_EDITOR_TOUR_STORAGE_KEY, Se as init, Ce as initCloud, Q as unmount, C as useFonts };
372
+ export { A as DEFAULT_EDITOR_TOUR_STORAGE_KEY, Ce as init, we as initCloud, Q as unmount, C as useFonts };
366
373
 
367
374
  //# sourceMappingURL=editor.js.map