@templatical/editor 0.10.4 → 0.11.1
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.
- package/dist/{AiChatSidebar-Djjqrmoh.js → AiChatSidebar-Cm5RM5Qh.js} +8 -8
- package/dist/{AiFeatureMenu-DR56EYbL.js → AiFeatureMenu-DBWcfcWl.js} +6 -6
- package/dist/{BlockIssueBadge-ySMhwDRR.js → BlockIssueBadge-BF4sdsr4.js} +4 -4
- package/dist/{CloudEditor-BLlRKq5D.js → CloudEditor-C6cSXtcP.js} +162 -160
- package/dist/{CollaboratorBar-BlXmZrIj.js → CollaboratorBar-B8-AQfG2.js} +3 -3
- package/dist/{CommentsSidebar-XcYtqAn8.js → CommentsSidebar-BQJzyCc6.js} +11 -11
- package/dist/{CountdownBlock-sAAv3BHE.js → CountdownBlock-D_AsF4F3.js} +1 -1
- package/dist/{CountdownToolbar-CUvqPILZ.js → CountdownToolbar-BGTkFky9.js} +2 -2
- package/dist/{DesignReferenceSidebar-B0Upq2MY.js → DesignReferenceSidebar-O3epZMXD.js} +6 -6
- package/dist/{IssuesPanel-BvcqQ0ec.js → IssuesPanel-CPBbR8yp.js} +7 -7
- package/dist/{ModuleBrowserModal-BdOB1Lbt.js → ModuleBrowserModal-B_tLzFAk.js} +9 -9
- package/dist/{ModulePreviewCanvas-BeglLfBF.js → ModulePreviewCanvas-B7pNpAHM.js} +2 -2
- package/dist/{NumberWithSuffix-Cb7HI_yW.js → NumberWithSuffix-eI9pPDWT.js} +1 -1
- package/dist/{ParagraphEditor-4Wrd3nnB.js → ParagraphEditor-DmA9K7dx.js} +27 -27
- package/dist/{RichTextEditorContent-D-uKzBDa.js → RichTextEditorContent-Dvn4woIt.js} +6 -6
- package/dist/{SaveModuleDialog-ueFhCVWN.js → SaveModuleDialog-B8ypoxdj.js} +6 -6
- package/dist/{SnapshotHistory-DNuw_gCY.js → SnapshotHistory-BTHd7CVP.js} +7 -7
- package/dist/{TemplateScoringPanel-bkIhEokb.js → TemplateScoringPanel-Bt5Rsgen.js} +12 -12
- package/dist/{TestEmailModal-Tg30-itu.js → TestEmailModal-CBIFMzK6.js} +4 -4
- package/dist/{TitleEditor-CY8QWbEw.js → TitleEditor-C9jDA5lI.js} +12 -12
- package/dist/{TplModal-D338Vv9U.js → TplModal-ND4fiqOS.js} +3 -3
- package/dist/{blockTypeIcons-CYoPwoH9.js → blockTypeIcons-Bn-_Smlm.js} +5 -5
- package/dist/bundle-stats.json +6 -6
- package/dist/cdn/chunks/{AiFeatureMenu-DRWRoPdh.js → AiFeatureMenu-BuSO0dXP.js} +8 -8
- package/dist/cdn/chunks/{AiFeatureMenu-DRWRoPdh.js.map → AiFeatureMenu-BuSO0dXP.js.map} +1 -1
- package/dist/cdn/chunks/{BlockIssueBadge-D2ApLp61.js → BlockIssueBadge-sv3IZ1Pb.js} +4 -4
- package/dist/cdn/chunks/{BlockIssueBadge-D2ApLp61.js.map → BlockIssueBadge-sv3IZ1Pb.js.map} +1 -1
- package/dist/cdn/chunks/{CloudEditor-gvOOuXac.js → CloudEditor-hxoqsTsq.js} +242 -240
- package/dist/cdn/chunks/CloudEditor-hxoqsTsq.js.map +1 -0
- package/dist/cdn/chunks/{CollaboratorBar-BZK3R383.js → CollaboratorBar-DFqsaNX0.js} +3 -3
- package/dist/cdn/chunks/{CollaboratorBar-BZK3R383.js.map → CollaboratorBar-DFqsaNX0.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownBlock-DU5YmjFP.js → CountdownBlock-PpH3fxAX.js} +2 -2
- package/dist/cdn/chunks/{CountdownBlock-DU5YmjFP.js.map → CountdownBlock-PpH3fxAX.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownToolbar-C1nlFm4e.js → CountdownToolbar-CZN92Bhz.js} +3 -3
- package/dist/cdn/chunks/{CountdownToolbar-C1nlFm4e.js.map → CountdownToolbar-CZN92Bhz.js.map} +1 -1
- package/dist/cdn/chunks/{IssuesPanel-R3M60NTk.js → IssuesPanel-wQjrnuyc.js} +7 -7
- package/dist/cdn/chunks/{IssuesPanel-R3M60NTk.js.map → IssuesPanel-wQjrnuyc.js.map} +1 -1
- package/dist/cdn/chunks/{ModuleBrowserModal-DMithQu8.js → ModuleBrowserModal-348wCgft.js} +8 -8
- package/dist/cdn/chunks/{ModuleBrowserModal-DMithQu8.js.map → ModuleBrowserModal-348wCgft.js.map} +1 -1
- package/dist/cdn/chunks/{ModulePreviewCanvas-BNKbV_c2.js → ModulePreviewCanvas-Cf6DUHml.js} +22 -22
- package/dist/cdn/chunks/{ModulePreviewCanvas-BNKbV_c2.js.map → ModulePreviewCanvas-Cf6DUHml.js.map} +1 -1
- package/dist/cdn/chunks/{NumberWithSuffix-C5zNn3Oc.js → NumberWithSuffix-Deo8EOSz.js} +2 -2
- package/dist/cdn/chunks/{NumberWithSuffix-C5zNn3Oc.js.map → NumberWithSuffix-Deo8EOSz.js.map} +1 -1
- package/dist/cdn/chunks/{ParagraphEditor-H136qVNI.js → ParagraphEditor-Cbl_gBYM.js} +53 -53
- package/dist/cdn/chunks/{ParagraphEditor-H136qVNI.js.map → ParagraphEditor-Cbl_gBYM.js.map} +1 -1
- package/dist/cdn/chunks/{RichTextEditorContent-BxW6vSck.js → RichTextEditorContent-TBPzn3RC.js} +4 -4
- package/dist/cdn/chunks/{RichTextEditorContent-BxW6vSck.js.map → RichTextEditorContent-TBPzn3RC.js.map} +1 -1
- package/dist/cdn/chunks/{SaveModuleDialog-BaiynUWb.js → SaveModuleDialog-CxdYMutK.js} +4 -4
- package/dist/cdn/chunks/{SaveModuleDialog-BaiynUWb.js.map → SaveModuleDialog-CxdYMutK.js.map} +1 -1
- package/dist/cdn/chunks/{TitleEditor-BBsR46vE.js → TitleEditor--XulEf7R.js} +9 -9
- package/dist/cdn/chunks/{TitleEditor-BBsR46vE.js.map → TitleEditor--XulEf7R.js.map} +1 -1
- package/dist/cdn/chunks/{blockTypeIcons-CX05RINM.js → blockTypeIcons-BJND4L-A.js} +6 -6
- package/dist/cdn/chunks/{blockTypeIcons-CX05RINM.js.map → blockTypeIcons-BJND4L-A.js.map} +1 -1
- package/dist/{de-DIAGP7yH.js → cdn/chunks/de-BJMLpg_p.js} +6 -0
- package/dist/cdn/chunks/{de-DIAGP7yH.js.map → de-BJMLpg_p.js.map} +1 -1
- package/dist/{en-nqIW8Q9W.js → cdn/chunks/en-DFMMw7SL.js} +6 -0
- package/dist/cdn/chunks/{en-nqIW8Q9W.js.map → en-DFMMw7SL.js.map} +1 -1
- package/dist/cdn/chunks/{extensions-2LuW8PHB.js → extensions-BtWoLy6E.js} +28 -28
- package/dist/cdn/chunks/{extensions-2LuW8PHB.js.map → extensions-BtWoLy6E.js.map} +1 -1
- package/dist/cdn/chunks/{features-CxHQG9xr.js → features-mO5NzwnN.js} +657 -678
- package/dist/cdn/chunks/features-mO5NzwnN.js.map +1 -0
- package/dist/cdn/chunks/{icons-DrsFvnNP.js → icons-CuXm6XAT.js} +2 -2
- package/dist/cdn/chunks/{icons-DrsFvnNP.js.map → icons-CuXm6XAT.js.map} +1 -1
- package/dist/cdn/chunks/{media-library-CDXkfBa7.js → media-library-BtNzYUTi.js} +524 -524
- package/dist/cdn/chunks/{media-library-CDXkfBa7.js.map → media-library-BtNzYUTi.js.map} +1 -1
- package/dist/cdn/chunks/{pt-BR-DCNnLLx9.js → pt-BR-C-9aWLlR.js} +5 -1
- package/dist/cdn/chunks/{pt-BR-DCNnLLx9.js.map → pt-BR-C-9aWLlR.js.map} +1 -1
- package/dist/cdn/chunks/{quality-HR87TCZc.js → quality-YKe19zp8.js} +481 -481
- package/dist/cdn/chunks/{quality-HR87TCZc.js.map → quality-YKe19zp8.js.map} +1 -1
- package/dist/cdn/chunks/{renderer-Dh5WdraW.js → renderer-BcOaxCs6.js} +9 -9
- package/dist/cdn/chunks/{renderer-Dh5WdraW.js.map → renderer-BcOaxCs6.js.map} +1 -1
- package/dist/cdn/chunks/{src-fyYLC_tY.js → src-B_ZRmuit.js} +63 -63
- package/dist/cdn/chunks/{src-fyYLC_tY.js.map → src-B_ZRmuit.js.map} +1 -1
- package/dist/cdn/chunks/{styles-NhU45rEI.js → styles-DDBCCJ-l.js} +675 -626
- package/dist/cdn/chunks/styles-DDBCCJ-l.js.map +1 -0
- package/dist/cdn/chunks/{tiptap-CfnwT9a8.js → tiptap-BAwu9VcJ.js} +4454 -3328
- package/dist/cdn/chunks/tiptap-BAwu9VcJ.js.map +1 -0
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +104 -102
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{check-B4oiQEsJ.js → check-BsNM6BDs.js} +1 -1
- package/dist/{chevron-down-BrL7CDST.js → chevron-down-fcsZ5DU7.js} +1 -1
- package/dist/{circle-alert-Ddf06I0D.js → circle-alert-BZTbwc-B.js} +1 -1
- package/dist/{clock-CbIkIHL5.js → clock-B7iQRubC.js} +1 -1
- package/dist/{createLucideIcon-Bn5l6hkC.js → createLucideIcon-C_fetdGM.js} +2 -2
- package/dist/{cdn/chunks/de-DIAGP7yH.js → de-BJMLpg_p.js} +4 -2
- package/dist/{dist-BRvZBY6r.js → dist-B4NkMBYc.js} +2 -2
- package/dist/{dist-DDB4TfTY.js → dist-BLcYl_de.js} +2 -2
- package/dist/{dist-DS9NXb20.js → dist-BOHAk4zI.js} +2 -2
- package/dist/dist-BsB4nPJD.js +5 -0
- package/dist/{dist-B6B8IO1W.js → dist-ByBVNmRN.js} +2 -2
- package/dist/dist-CD3wbUoR.js +5 -0
- package/dist/{dist-DbGsZrPu.js → dist-Cwl7XXr4.js} +806 -601
- package/dist/{dist-BShwEwPy.js → dist-Dem8ODLh.js} +1512 -1501
- package/dist/{dist-BdIM5Jt8.js → dist-Dhs3W2WW.js} +2 -2
- package/dist/{dist-ZiEahccA.js → dist-XdF11ZkX.js} +2 -2
- package/dist/{dist-BhZo8-eC.js → dist-c2sj5PQ5.js} +2 -2
- package/dist/{dist-Ctv43HTN.js → dist-eVlXvuKI.js} +3 -3
- package/dist/{cdn/chunks/en-nqIW8Q9W.js → en-DFMMw7SL.js} +4 -2
- package/dist/extensions-B2lSGCA8.js +1720 -0
- package/dist/{image-up-D3KvvHLf.js → image-up-1xrPPJYH.js} +1 -1
- package/dist/index.d.ts +61 -0
- package/dist/{info-RwcI2EUD.js → info-ByAFxArD.js} +1 -1
- package/dist/keys-DsRdOmg3.js +10 -0
- package/dist/{list-checks-ruqK9lCo.js → list-checks-CKUP4UZU.js} +1 -1
- package/dist/{loader-circle-D4SXJ8eQ.js → loader-circle-BuxX338d.js} +1 -1
- package/dist/{message-circle-p9UiFyS7.js → message-circle-nLwqegRi.js} +1 -1
- package/dist/{pt-BR-DCNnLLx9.js → pt-BR-C-9aWLlR.js} +4 -0
- package/dist/{refresh-cw-C8HbO4hg.js → refresh-cw-DAkD6iDI.js} +1 -1
- package/dist/{scan-line-CmPIMm63.js → scan-line-DEELRJJ5.js} +1 -1
- package/dist/{send-DacXlri3.js → send-DCMgrNT4.js} +1 -1
- package/dist/{shield-check-BdrHnTnJ.js → shield-check-BFtVr_ov.js} +1 -1
- package/dist/{sparkles-tT7wcus5.js → sparkles-CeYIQ5RJ.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{styles-BmZWc8sc.js → styles-DZcQGzsN.js} +735 -686
- package/dist/templatical-editor.js +118 -116
- package/dist/{text-align-start-DaSSBZVi.js → text-align-start-BsmIoqLS.js} +1 -1
- package/dist/{trash-2-B0uIJOwX.js → trash-2-C2S4-CIH.js} +1 -1
- package/dist/{triangle-alert-FLQWRf-c.js → triangle-alert-DMdedF6W.js} +1 -1
- package/dist/{useCloudI18n-Lh0xWlQ4.js → useCloudI18n-BEuiZdzs.js} +1 -1
- package/dist/{useEditorCore-CMukR8kX.js → useEditorCore-D00QzW07.js} +742 -763
- package/dist/{useI18n-CNEz8RK7.js → useI18n-DNspT6uw.js} +1 -1
- package/dist/{useMergeTag-C54tabTK.js → useMergeTag-abutjUud.js} +1 -1
- package/dist/{usePopoverRoot-dvg2XFmj.js → usePopoverRoot-DG3mlvd1.js} +1 -1
- package/dist/{x-BROzFhGs.js → x-_9jw816B.js} +1 -1
- package/package.json +25 -25
- package/dist/cdn/chunks/CloudEditor-gvOOuXac.js.map +0 -1
- package/dist/cdn/chunks/features-CxHQG9xr.js.map +0 -1
- package/dist/cdn/chunks/styles-NhU45rEI.js.map +0 -1
- package/dist/cdn/chunks/tiptap-CfnwT9a8.js.map +0 -1
- package/dist/dist-BVKpiz3S.js +0 -5
- package/dist/dist-BzeOnbU8.js +0 -5
- package/dist/extensions-CqrSpX_i.js +0 -806
- package/dist/keys-DSm2p8zn.js +0 -10
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { $ as e, A as t, H as n, J as r, M as i, N as a, P as o, V as s, Z as c, _ as l, b as u, ct as d, f, g as p, h as m, it as h, j as g, l as _, m as v, n as y, ot as b, p as x, s as S, st as C, u as w, v as T, x as E, y as D, z as
|
|
2
|
-
import { $t as k, A,
|
|
3
|
-
import { S as
|
|
4
|
-
import { a as
|
|
1
|
+
import { $ as e, A as t, H as n, J as r, M as i, N as a, P as o, V as s, Z as c, _ as l, b as u, ct as d, f, g as p, h as m, it as h, j as g, l as _, m as v, n as y, ot as b, p as x, s as S, st as C, u as w, v as T, x as E, y as D, z as ee } from "./draggable-iAb7QVJo.js";
|
|
2
|
+
import { $t as O, A as k, Dt as A, E as j, Ht as te, It as M, Lt as N, Ot as P, Pt as ne, Q as re, S as F, Tn as I, Ut as L, Wn as R, Wt as ie, Y as z, _ as B, b as V, c as ae, ct as H, d as U, dt as W, f as G, g as oe, gn as K, h as se, it as q, jn as J, jt as Y, l as X, m as Z, mt as ce, nn as le, nt as Q, p as ue, s as de, sn as fe, tn as pe, u as me, v as he, vt as ge, x as _e, y as ve, yt as ye, zt as be } from "./features-mO5NzwnN.js";
|
|
3
|
+
import { S as xe, x as Se } from "./icons-CuXm6XAT.js";
|
|
4
|
+
import { a as Ce, c as we, d as Te, i as Ee, l as De, n as Oe, o as ke, r as Ae, s as je, t as Me, u as Ne } from "./styles-DDBCCJ-l.js";
|
|
5
5
|
import { d as $ } from "./styleConstants-lGobwiLH.js";
|
|
6
6
|
//#region src/cloud/composables/useSnapshotPreview.ts
|
|
7
|
-
function
|
|
7
|
+
function Pe(t) {
|
|
8
8
|
let { authManager: n, editor: i, history: a, conditionPreview: o, autoSave: s, onError: l } = t, u = e(null), d = c(null), p = c(null), m = !1;
|
|
9
9
|
r(() => {
|
|
10
10
|
m = !0;
|
|
11
11
|
});
|
|
12
12
|
let h = f(() => d.value !== null), g = f(() => u.value?.snapshots.value ?? []), _ = f(() => u.value?.isLoading.value ?? !1), v = f(() => u.value?.isRestoring.value ?? !1);
|
|
13
13
|
function y() {
|
|
14
|
-
i.state.template?.id && !u.value && (u.value =
|
|
14
|
+
i.state.template?.id && !u.value && (u.value = G({
|
|
15
15
|
authManager: n,
|
|
16
16
|
templateId: i.state.template.id,
|
|
17
17
|
onRestore: b,
|
|
@@ -63,7 +63,7 @@ function Me(t) {
|
|
|
63
63
|
}
|
|
64
64
|
//#endregion
|
|
65
65
|
//#region src/cloud/composables/useCloudPanelState.ts
|
|
66
|
-
function
|
|
66
|
+
function Fe() {
|
|
67
67
|
let e = c(null), t = f({
|
|
68
68
|
get: () => e.value === "ai-chat",
|
|
69
69
|
set: (t) => e.value = t ? "ai-chat" : null
|
|
@@ -86,7 +86,7 @@ function Ne() {
|
|
|
86
86
|
function g(t) {
|
|
87
87
|
l.value = !1, e.value = e.value === t ? null : t;
|
|
88
88
|
}
|
|
89
|
-
return
|
|
89
|
+
return fe(u, () => {
|
|
90
90
|
l.value = !1;
|
|
91
91
|
}), {
|
|
92
92
|
activePanel: e,
|
|
@@ -108,10 +108,10 @@ function Ne() {
|
|
|
108
108
|
}
|
|
109
109
|
//#endregion
|
|
110
110
|
//#region src/cloud/composables/useCollabUndoWarning.ts
|
|
111
|
-
function
|
|
112
|
-
let { isCollaborationEnabled: t, getCollaboratorCount: n, canUndo: r } = e, i = c(!1), a = c(!1), { start: o } =
|
|
111
|
+
function Ie(e) {
|
|
112
|
+
let { isCollaborationEnabled: t, getCollaboratorCount: n, canUndo: r } = e, i = c(!1), a = c(!1), { start: o } = K(() => {
|
|
113
113
|
a.value = !1;
|
|
114
|
-
},
|
|
114
|
+
}, R, { immediate: !1 });
|
|
115
115
|
function s() {
|
|
116
116
|
i.value || !t.value || n() === 0 || !r.value || (i.value = !0, a.value = !0, o());
|
|
117
117
|
}
|
|
@@ -122,8 +122,8 @@ function Pe(e) {
|
|
|
122
122
|
}
|
|
123
123
|
//#endregion
|
|
124
124
|
//#region src/cloud/composables/useCloudFeatureFlags.ts
|
|
125
|
-
function
|
|
126
|
-
let { planConfigInstance: t, aiConfig: n, editor: r } = e, i = f(() => t.hasFeature("ai_generation") && n.hasAnyMenuFeature.value), a = f(() => t.hasFeature("test_email")), o = f(() => !!r.state.template?.id), s = f(() => t.hasFeature("white_label")), l = f(() => t.config.value?.limits.max_templates ?? null), u = f(() => t.config.value?.template_count ?? 0), d = c(!1), p = c("idle"), m = c(""), { start: h } =
|
|
125
|
+
function Le(e) {
|
|
126
|
+
let { planConfigInstance: t, aiConfig: n, editor: r } = e, i = f(() => t.hasFeature("ai_generation") && n.hasAnyMenuFeature.value), a = f(() => t.hasFeature("test_email")), o = f(() => !!r.state.template?.id), s = f(() => t.hasFeature("white_label")), l = f(() => t.config.value?.limits.max_templates ?? null), u = f(() => t.config.value?.template_count ?? 0), d = c(!1), p = c("idle"), m = c(""), { start: h } = K(() => {
|
|
127
127
|
p.value = "idle";
|
|
128
128
|
}, 3e3, { immediate: !1 });
|
|
129
129
|
return {
|
|
@@ -141,7 +141,7 @@ function Fe(e) {
|
|
|
141
141
|
}
|
|
142
142
|
//#endregion
|
|
143
143
|
//#region src/cloud/composables/useCloudMediaLibrary.ts
|
|
144
|
-
function
|
|
144
|
+
function Re(e) {
|
|
145
145
|
let { onRequestMedia: t, mediaLibraryOpen: n, mediaLibraryAccept: i } = e, a = null;
|
|
146
146
|
async function o() {
|
|
147
147
|
if (t) {
|
|
@@ -176,30 +176,30 @@ function Ie(e) {
|
|
|
176
176
|
}
|
|
177
177
|
//#endregion
|
|
178
178
|
//#region src/cloud/composables/useCloudInitialization.ts
|
|
179
|
-
function
|
|
180
|
-
let { config: t, translations: n, fontsManager: r, emit: i, getCommentsSidebar: o } = e, s = c(!0), l = c(!1), u = c(null), d = !1, p = { value: null }, m = null, h = null, g = new
|
|
179
|
+
function ze(e) {
|
|
180
|
+
let { config: t, translations: n, fontsManager: r, emit: i, getCommentsSidebar: o } = e, s = c(!0), l = c(!1), u = c(null), d = !1, p = { value: null }, m = null, h = null, g = new j({
|
|
181
181
|
...t.auth,
|
|
182
182
|
onError: t.onError
|
|
183
|
-
}), _ =
|
|
183
|
+
}), _ = X({
|
|
184
184
|
authManager: g,
|
|
185
185
|
onError: t.onError
|
|
186
|
-
}), v = c(/* @__PURE__ */ new Map()), y =
|
|
186
|
+
}), v = c(/* @__PURE__ */ new Map()), y = _e({
|
|
187
187
|
authManager: g,
|
|
188
188
|
defaultFontFamily: t.fonts?.defaultFont,
|
|
189
189
|
templateDefaults: t.templateDefaults,
|
|
190
190
|
onError: t.onError,
|
|
191
191
|
lockedBlocks: v
|
|
192
|
-
}), b =
|
|
192
|
+
}), b = Z({
|
|
193
193
|
authManager: g,
|
|
194
194
|
onError: t.onError
|
|
195
195
|
});
|
|
196
|
-
t.mcp?.enabled &&
|
|
196
|
+
t.mcp?.enabled && de({
|
|
197
197
|
editor: y,
|
|
198
198
|
channel: b.channel,
|
|
199
199
|
onOperation: t.mcp.onOperation
|
|
200
200
|
});
|
|
201
201
|
let x = null;
|
|
202
|
-
t.collaboration?.enabled && (x =
|
|
202
|
+
t.collaboration?.enabled && (x = oe({
|
|
203
203
|
authManager: g,
|
|
204
204
|
editor: y,
|
|
205
205
|
channel: b.channel,
|
|
@@ -208,20 +208,21 @@ function Le(e) {
|
|
|
208
208
|
onCollaboratorLeft: t.collaboration.onCollaboratorLeft,
|
|
209
209
|
onBlockLocked: t.collaboration.onBlockLocked,
|
|
210
210
|
onBlockUnlocked: t.collaboration.onBlockUnlocked
|
|
211
|
-
}),
|
|
211
|
+
}), ee(() => x.lockedBlocks.value, (e) => {
|
|
212
212
|
v.value = e;
|
|
213
|
-
}, { immediate: !0 }),
|
|
214
|
-
let S = f(() => !!t.collaboration?.enabled && _.hasFeature("collaboration")), C =
|
|
213
|
+
}, { immediate: !0 }), se(y, x));
|
|
214
|
+
let S = f(() => !!t.collaboration?.enabled && _.hasFeature("collaboration")), C = k({
|
|
215
215
|
editor: y,
|
|
216
216
|
config: {
|
|
217
217
|
uiTheme: t.uiTheme,
|
|
218
218
|
theme: void 0,
|
|
219
219
|
blockDefaults: t.blockDefaults,
|
|
220
220
|
customBlocks: [],
|
|
221
|
+
paletteBlocks: t.paletteBlocks,
|
|
221
222
|
mergeTags: t.mergeTags,
|
|
222
223
|
displayConditions: t.displayConditions,
|
|
223
224
|
onRequestMedia: null,
|
|
224
|
-
lint:
|
|
225
|
+
lint: Te(t),
|
|
225
226
|
onSave: () => {
|
|
226
227
|
p.value?.().catch((e) => {
|
|
227
228
|
t.onError?.(e);
|
|
@@ -242,13 +243,13 @@ function Le(e) {
|
|
|
242
243
|
keyboardOptions: { onBeforeUndo: () => h?.showCollabUndoWarning() },
|
|
243
244
|
editorRoot: e.editorRoot,
|
|
244
245
|
containerEl: e.containerEl
|
|
245
|
-
}), w =
|
|
246
|
+
}), w = Ie({
|
|
246
247
|
isCollaborationEnabled: S,
|
|
247
248
|
getCollaboratorCount: () => x?.collaborators.value.length ?? 0,
|
|
248
249
|
canUndo: C.history.canUndo
|
|
249
250
|
});
|
|
250
251
|
h = w;
|
|
251
|
-
let T =
|
|
252
|
+
let T = Pe({
|
|
252
253
|
authManager: g,
|
|
253
254
|
editor: y,
|
|
254
255
|
history: C.history,
|
|
@@ -257,32 +258,32 @@ function Le(e) {
|
|
|
257
258
|
onError: t.onError
|
|
258
259
|
});
|
|
259
260
|
m = T;
|
|
260
|
-
let E =
|
|
261
|
+
let E = Fe(), D = V(t.ai), A = Le({
|
|
261
262
|
planConfigInstance: _,
|
|
262
263
|
aiConfig: D,
|
|
263
264
|
editor: y
|
|
264
|
-
}), M =
|
|
265
|
+
}), M = Re({
|
|
265
266
|
onRequestMedia: t.onRequestMedia,
|
|
266
267
|
mediaLibraryOpen: E.mediaLibraryOpen,
|
|
267
268
|
mediaLibraryAccept: E.mediaLibraryAccept
|
|
268
269
|
});
|
|
269
|
-
|
|
270
|
+
re({
|
|
270
271
|
onBlockMove: y.moveBlock,
|
|
271
272
|
onBlockAdd: y.addBlock
|
|
272
273
|
});
|
|
273
|
-
let
|
|
274
|
+
let P = me({
|
|
274
275
|
authManager: g,
|
|
275
276
|
getFontsConfig: () => t.fonts,
|
|
276
277
|
canUseCustomFonts: () => _.hasFeature("custom_fonts")
|
|
277
|
-
}), F =
|
|
278
|
+
}), F = U({
|
|
278
279
|
authManager: g,
|
|
279
280
|
getTemplateId: () => y.state.template?.id ?? null,
|
|
280
281
|
save: () => y.save(),
|
|
281
|
-
exportHtml: (e) =>
|
|
282
|
+
exportHtml: (e) => P.exportHtml(e),
|
|
282
283
|
onError: t.onError,
|
|
283
284
|
isAuthReady: l,
|
|
284
285
|
onBeforeTestEmail: t.onBeforeTestEmail
|
|
285
|
-
}), I =
|
|
286
|
+
}), I = he({
|
|
286
287
|
authManager: g,
|
|
287
288
|
getTemplateId: () => y.state.template?.id ?? null,
|
|
288
289
|
getSocketId: () => b.getSocketId(),
|
|
@@ -291,55 +292,55 @@ function Le(e) {
|
|
|
291
292
|
isAuthReady: l,
|
|
292
293
|
hasCommentingFeature: () => t.commenting !== !1 && _.hasFeature("commenting")
|
|
293
294
|
});
|
|
294
|
-
|
|
295
|
+
B({
|
|
295
296
|
comments: I,
|
|
296
297
|
channel: b.channel
|
|
297
298
|
});
|
|
298
|
-
let L =
|
|
299
|
+
let L = ue({
|
|
299
300
|
authManager: g,
|
|
300
301
|
onError: t.onError
|
|
301
|
-
}), R = c(!1),
|
|
302
|
+
}), R = c(!1), z = c(null), H = c(!1), W = ve({
|
|
302
303
|
authManager: g,
|
|
303
304
|
getTemplateId: () => y.state.template?.id ?? null
|
|
304
305
|
});
|
|
305
|
-
function
|
|
306
|
+
function G(e) {
|
|
306
307
|
E.commentsOpen.value = !0, queueMicrotask(() => {
|
|
307
308
|
o()?.filterByBlock(e);
|
|
308
309
|
});
|
|
309
310
|
}
|
|
310
|
-
a(
|
|
311
|
+
a(O, M.handleRequestMedia), a(be, g), a(N, D), a(ie, I), a(pe, L), a(le, W), a(te, {
|
|
311
312
|
plan: _,
|
|
312
313
|
ai: D,
|
|
313
314
|
comments: {
|
|
314
315
|
getBlockCount: (e) => I.commentCountByBlock.value.get(e) ?? 0,
|
|
315
|
-
openForBlock:
|
|
316
|
+
openForBlock: G
|
|
316
317
|
},
|
|
317
318
|
savedModules: {
|
|
318
319
|
openSaveDialog: (e) => {
|
|
319
|
-
|
|
320
|
+
z.value = e ?? null, R.value = !0;
|
|
320
321
|
},
|
|
321
322
|
openBrowser: () => {
|
|
322
|
-
|
|
323
|
+
H.value = !0;
|
|
323
324
|
},
|
|
324
325
|
moduleCount: f(() => L.modules.value.length)
|
|
325
326
|
}
|
|
326
327
|
});
|
|
327
|
-
function
|
|
328
|
+
function K(e) {
|
|
328
329
|
_.hasFeature("theme_customization") && (C.themeOverrides.value = e);
|
|
329
330
|
}
|
|
330
|
-
function
|
|
331
|
+
function q(e) {
|
|
331
332
|
y.setUiTheme(e);
|
|
332
333
|
}
|
|
333
|
-
async function
|
|
334
|
+
async function J() {
|
|
334
335
|
s.value = !0, u.value = null;
|
|
335
336
|
try {
|
|
336
337
|
if (await g.initialize(), d) return;
|
|
337
338
|
l.value = !0;
|
|
338
|
-
let e = await
|
|
339
|
+
let e = await ae({ authManager: g });
|
|
339
340
|
if (d) return;
|
|
340
341
|
if (!e.api.ok) throw Error("Health check failed: API is not reachable");
|
|
341
342
|
if (!e.auth.ok) throw Error(`Health check failed: authentication error${e.auth.error ? ` - ${e.auth.error}` : ""}`);
|
|
342
|
-
if (e.websocket.ok ||
|
|
343
|
+
if (e.websocket.ok || ne.warn("WebSocket health check failed:", e.websocket.error ?? "unknown error", "-- real-time features will be disabled."), await _.fetchConfig(), d) return;
|
|
343
344
|
r.setCustomFontsEnabled(_.hasFeature("custom_fonts")), t.customBlocks?.length && _.hasFeature("custom_blocks") && C.registerCustomBlocks(t.customBlocks), t.theme && _.hasFeature("theme_customization") && (C.themeOverrides.value = t.theme), t.modules !== !1 && _.hasFeature("saved_modules") && L.loadModules(), i("ready");
|
|
344
345
|
} catch (e) {
|
|
345
346
|
if (d) return;
|
|
@@ -349,7 +350,7 @@ function Le(e) {
|
|
|
349
350
|
d || (s.value = !1);
|
|
350
351
|
}
|
|
351
352
|
}
|
|
352
|
-
function
|
|
353
|
+
function Y() {
|
|
353
354
|
d = !0, r.cleanupFontLinks(), b.disconnect(), C.destroy(), t.onUnmount?.();
|
|
354
355
|
}
|
|
355
356
|
return {
|
|
@@ -365,32 +366,32 @@ function Le(e) {
|
|
|
365
366
|
editor: y,
|
|
366
367
|
core: C,
|
|
367
368
|
aiConfig: D,
|
|
368
|
-
featureFlags:
|
|
369
|
+
featureFlags: A,
|
|
369
370
|
mediaLib: M,
|
|
370
|
-
exporter:
|
|
371
|
+
exporter: P,
|
|
371
372
|
testEmail: F,
|
|
372
373
|
commentsInstance: I,
|
|
373
374
|
savedModulesHeadless: L,
|
|
374
|
-
scoringInstance:
|
|
375
|
+
scoringInstance: W,
|
|
375
376
|
panelState: E,
|
|
376
377
|
snapshotPreview: T,
|
|
377
378
|
collabWarning: w,
|
|
378
379
|
showSaveModuleDialog: R,
|
|
379
|
-
showModuleBrowserModal:
|
|
380
|
-
saveModulePreSelectedBlockId:
|
|
380
|
+
showModuleBrowserModal: H,
|
|
381
|
+
saveModulePreSelectedBlockId: z,
|
|
381
382
|
onSaveHook: p,
|
|
382
|
-
initialize:
|
|
383
|
-
destroy:
|
|
384
|
-
setThemeOverrides:
|
|
385
|
-
setUiTheme:
|
|
386
|
-
openCommentsForBlock:
|
|
383
|
+
initialize: J,
|
|
384
|
+
destroy: Y,
|
|
385
|
+
setThemeOverrides: K,
|
|
386
|
+
setUiTheme: q,
|
|
387
|
+
openCommentsForBlock: G
|
|
387
388
|
};
|
|
388
389
|
}
|
|
389
390
|
//#endregion
|
|
390
391
|
//#region src/utils/preRenderCustomBlocks.ts
|
|
391
|
-
async function
|
|
392
|
+
async function Be(e, t) {
|
|
392
393
|
let n = async (e) => {
|
|
393
|
-
if (
|
|
394
|
+
if (J(e)) {
|
|
394
395
|
let n = e;
|
|
395
396
|
try {
|
|
396
397
|
n.renderedHtml = await t.renderCustomBlock(n);
|
|
@@ -407,10 +408,10 @@ async function Re(e, t) {
|
|
|
407
408
|
}
|
|
408
409
|
//#endregion
|
|
409
410
|
//#region src/cloud/composables/useCloudLifecycle.ts
|
|
410
|
-
function
|
|
411
|
+
function Ve(e) {
|
|
411
412
|
let { config: t, editor: n, websocket: r, planConfigInstance: i, snapshotPreview: a, core: o, exporter: s, featureFlags: c, isDestroyed: l } = e;
|
|
412
413
|
function u() {
|
|
413
|
-
return
|
|
414
|
+
return F(i.config.value.websocket);
|
|
414
415
|
}
|
|
415
416
|
async function d(e) {
|
|
416
417
|
let i = await n.create(e);
|
|
@@ -423,7 +424,7 @@ function ze(e) {
|
|
|
423
424
|
async function p() {
|
|
424
425
|
c.isSaveExporting.value = !0, c.saveStatus.value = "idle";
|
|
425
426
|
try {
|
|
426
|
-
if (await
|
|
427
|
+
if (await Be(n.content.value, o.registry), l()) throw Error("Component unmounted during save");
|
|
427
428
|
let e = await n.save();
|
|
428
429
|
if (l()) throw Error("Component unmounted during save");
|
|
429
430
|
a.initSnapshotHistory(), a.snapshotHistoryInstance.value?.loadSnapshots();
|
|
@@ -450,7 +451,7 @@ function ze(e) {
|
|
|
450
451
|
}
|
|
451
452
|
//#endregion
|
|
452
453
|
//#region src/cloud/composables/useCloudSaveGate.ts
|
|
453
|
-
function
|
|
454
|
+
function He(e) {
|
|
454
455
|
let t = c(!1), n = null, r = f(() => e.planConfig.value?.accessibility?.blockOnError === !0), i = f(() => r.value ? e.issues.value.filter((e) => e.severity === "error") : []), a = f(() => i.value.length > 0);
|
|
455
456
|
async function o(e) {
|
|
456
457
|
return a.value ? (n = e, t.value = !0, !1) : (await e(), !0);
|
|
@@ -473,7 +474,7 @@ function Be(e) {
|
|
|
473
474
|
}
|
|
474
475
|
//#endregion
|
|
475
476
|
//#region src/cloud/components/CloudSaveGateModal.vue?vue&type=script&setup=true&lang.ts
|
|
476
|
-
var
|
|
477
|
+
var Ue = ["aria-label"], We = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl:max-w-md tpl:flex-col tpl:gap-4 tpl:rounded-lg tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-elevated)] tpl:p-5 tpl:shadow-[var(--tpl-shadow-md)]" }, Ge = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ke = { class: "tpl:m-0 tpl:text-base tpl:font-semibold tpl:text-[var(--tpl-text)]" }, qe = { class: "tpl:m-0 tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Je = { class: "tpl:m-0 tpl:flex tpl:max-h-64 tpl:list-none tpl:flex-col tpl:gap-1.5 tpl:overflow-y-auto tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:p-2" }, Ye = { class: "tpl:text-xs tpl:text-[var(--tpl-text)]" }, Xe = { class: "tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-dim)]" }, Ze = { class: "tpl:flex tpl:justify-end tpl:gap-2" }, Qe = /* @__PURE__ */ E({
|
|
477
478
|
__name: "CloudSaveGateModal",
|
|
478
479
|
props: {
|
|
479
480
|
open: { type: Boolean },
|
|
@@ -495,18 +496,18 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
495
496
|
"aria-label": h(r).saveGate.title,
|
|
496
497
|
class: "tpl:fixed tpl:inset-0 tpl:z-50 tpl:flex tpl:items-center tpl:justify-center tpl:bg-black/40 tpl:p-6",
|
|
497
498
|
onClick: a[2] ||= _((e) => n("cancel"), ["self"])
|
|
498
|
-
}, [x("div",
|
|
499
|
-
x("header",
|
|
499
|
+
}, [x("div", We, [
|
|
500
|
+
x("header", Ge, [D(h(H), {
|
|
500
501
|
size: 18,
|
|
501
502
|
"stroke-width": 2,
|
|
502
503
|
class: "tpl:text-[var(--tpl-warning)]"
|
|
503
|
-
}), x("h2",
|
|
504
|
-
x("p",
|
|
505
|
-
x("ul",
|
|
504
|
+
}), x("h2", Ke, d(h(r).saveGate.title), 1)]),
|
|
505
|
+
x("p", qe, d(h(r).saveGate.body), 1),
|
|
506
|
+
x("ul", Je, [(i(!0), p(w, null, o(e.issues, (e) => (i(), p("li", {
|
|
506
507
|
key: `${e.ruleId}-${e.blockId ?? "template"}`,
|
|
507
508
|
class: "tpl:flex tpl:flex-col tpl:gap-0.5 tpl:rounded tpl:px-2 tpl:py-1.5"
|
|
508
|
-
}, [x("span",
|
|
509
|
-
x("footer",
|
|
509
|
+
}, [x("span", Ye, d(e.message), 1), x("span", Xe, d(e.ruleId), 1)]))), 128))]),
|
|
510
|
+
x("footer", Ze, [x("button", {
|
|
510
511
|
type: "button",
|
|
511
512
|
class: "tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]",
|
|
512
513
|
onClick: a[0] ||= (e) => n("cancel")
|
|
@@ -515,11 +516,11 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
515
516
|
class: "tpl:rounded-md tpl:bg-[var(--tpl-danger)] tpl:px-3 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:text-white",
|
|
516
517
|
onClick: a[1] ||= (e) => n("confirm")
|
|
517
518
|
}, d(h(r).saveGate.confirm), 1)])
|
|
518
|
-
])], 8,
|
|
519
|
+
])], 8, Ue)) : m("", !0)]),
|
|
519
520
|
_: 1
|
|
520
521
|
}));
|
|
521
522
|
}
|
|
522
|
-
}),
|
|
523
|
+
}), $e = {
|
|
523
524
|
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",
|
|
524
525
|
style: {
|
|
525
526
|
"background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)",
|
|
@@ -528,24 +529,24 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
528
529
|
"box-shadow": "var(--tpl-shadow-md)",
|
|
529
530
|
"border-bottom": "1px solid var(--tpl-border)"
|
|
530
531
|
}
|
|
531
|
-
},
|
|
532
|
+
}, et = { class: "tpl-header-left tpl:flex tpl:min-w-[200px] tpl:items-center tpl:gap-3" }, tt = {
|
|
532
533
|
key: 0,
|
|
533
534
|
class: "tpl:text-xs tpl:opacity-60 tpl:text-[var(--tpl-text-muted)]"
|
|
534
|
-
},
|
|
535
|
+
}, nt = { class: "tpl-header-center tpl:flex tpl:items-center tpl:justify-center tpl:gap-10" }, rt = { class: "tpl-header-right tpl:flex tpl:min-w-[200px] tpl:items-center tpl:justify-end tpl:gap-3" }, it = ["data-tooltip"], at = {
|
|
535
536
|
key: 1,
|
|
536
537
|
"aria-live": "polite",
|
|
537
538
|
class: "tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-success)]"
|
|
538
|
-
},
|
|
539
|
+
}, ot = {
|
|
539
540
|
key: 2,
|
|
540
541
|
"aria-live": "polite",
|
|
541
542
|
class: "tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
542
|
-
},
|
|
543
|
+
}, st = ["aria-label", "aria-expanded"], ct = {
|
|
543
544
|
key: 0,
|
|
544
545
|
class: "tpl:inline-flex tpl:size-4.5 tpl:items-center tpl:justify-center tpl:rounded-full tpl:text-[10px] tpl:font-semibold tpl:bg-[var(--tpl-primary)] tpl:text-[var(--tpl-bg)]"
|
|
545
|
-
},
|
|
546
|
+
}, lt = ["aria-expanded"], ut = {
|
|
546
547
|
key: 0,
|
|
547
548
|
class: "tpl:absolute tpl:right-0 tpl:top-full tpl:z-50 tpl:mt-1 tpl:origin-top-right"
|
|
548
|
-
},
|
|
549
|
+
}, dt = ["disabled"], ft = ["disabled"], pt = /* @__PURE__ */ E({
|
|
549
550
|
__name: "CloudHeader",
|
|
550
551
|
props: {
|
|
551
552
|
editor: {},
|
|
@@ -563,22 +564,22 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
563
564
|
},
|
|
564
565
|
emits: ["save"],
|
|
565
566
|
setup(e) {
|
|
566
|
-
let t = u(() => import("./CollaboratorBar-
|
|
567
|
-
return (c, l) => (i(), p("header",
|
|
568
|
-
x("div",
|
|
567
|
+
let t = u(() => import("./CollaboratorBar-DFqsaNX0.js")), n = u(() => import("./features-mO5NzwnN.js").then((e) => e.r)), r = u(() => import("./AiFeatureMenu-BuSO0dXP.js")), { t: a, format: o } = Q();
|
|
568
|
+
return (c, l) => (i(), p("header", $e, [
|
|
569
|
+
x("div", et, [e.featureFlags.templateLimit.value === null ? m("", !0) : (i(), p("span", tt, d(h(o)(h(a).header.templatesUsed, {
|
|
569
570
|
used: e.featureFlags.templateCount.value,
|
|
570
571
|
max: e.featureFlags.templateLimit.value
|
|
571
572
|
})), 1))]),
|
|
572
|
-
x("div",
|
|
573
|
-
D(
|
|
573
|
+
x("div", nt, [
|
|
574
|
+
D(Ce, {
|
|
574
575
|
viewport: e.editor.state.viewport,
|
|
575
576
|
onChange: e.editor.setViewport
|
|
576
577
|
}, null, 8, ["viewport", "onChange"]),
|
|
577
|
-
D(
|
|
578
|
+
D(Ae, {
|
|
578
579
|
"dark-mode": e.editor.state.darkMode,
|
|
579
580
|
onChange: e.editor.setDarkMode
|
|
580
581
|
}, null, 8, ["dark-mode", "onChange"]),
|
|
581
|
-
D(
|
|
582
|
+
D(Ee, {
|
|
582
583
|
"preview-mode": e.editor.state.previewMode,
|
|
583
584
|
onChange: e.editor.setPreviewMode
|
|
584
585
|
}, null, 8, ["preview-mode", "onChange"]),
|
|
@@ -602,19 +603,19 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
602
603
|
"onNavigate"
|
|
603
604
|
])) : m("", !0)
|
|
604
605
|
]),
|
|
605
|
-
x("div",
|
|
606
|
+
x("div", rt, [
|
|
606
607
|
e.featureFlags.saveStatus.value === "error" ? (i(), p("div", {
|
|
607
608
|
key: 0,
|
|
608
609
|
"aria-live": "assertive",
|
|
609
610
|
class: "tpl-tooltip tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-danger)]",
|
|
610
611
|
"data-tooltip": e.featureFlags.saveErrorMessage.value
|
|
611
|
-
}, [D(h(
|
|
612
|
+
}, [D(h(P), {
|
|
612
613
|
size: 12,
|
|
613
614
|
"stroke-width": 2.5
|
|
614
|
-
}), T(" " + d(h(a).header.saveFailed), 1)], 8,
|
|
615
|
+
}), T(" " + d(h(a).header.saveFailed), 1)], 8, it)) : e.featureFlags.saveStatus.value === "saved" ? (i(), p("div", at, [D(h(Y), {
|
|
615
616
|
size: 12,
|
|
616
617
|
"stroke-width": 2.5
|
|
617
|
-
}), T(" " + d(h(a).header.saved), 1)])) : e.editor.state.isDirty ? (i(), p("div",
|
|
618
|
+
}), T(" " + d(h(a).header.saved), 1)])) : e.editor.state.isDirty ? (i(), p("div", ot, [l[4] ||= x("span", { class: "tpl-pulse tpl:size-1.5 tpl:rounded-full tpl:bg-[var(--tpl-primary)]" }, null, -1), T(" " + d(h(a).header.unsaved), 1)])) : m("", !0),
|
|
618
619
|
e.commentsInstance.isEnabled.value && e.featureFlags.hasTemplateSaved.value ? (i(), p("button", {
|
|
619
620
|
key: 3,
|
|
620
621
|
"aria-label": e.commentsInstance.unresolvedCount.value > 0 ? `${h(a).comments.button} (${e.commentsInstance.unresolvedCount.value})` : h(a).comments.button,
|
|
@@ -627,13 +628,13 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
627
628
|
}),
|
|
628
629
|
onClick: l[0] ||= (t) => e.panelState.commentsOpen.value = !e.panelState.commentsOpen.value
|
|
629
630
|
}, [
|
|
630
|
-
D(h(
|
|
631
|
+
D(h(ge), {
|
|
631
632
|
size: 16,
|
|
632
633
|
"stroke-width": 2
|
|
633
634
|
}),
|
|
634
635
|
T(" " + d(h(a).comments.button) + " ", 1),
|
|
635
|
-
e.commentsInstance.unresolvedCount.value > 0 && !e.panelState.commentsOpen.value ? (i(), p("span",
|
|
636
|
-
], 14,
|
|
636
|
+
e.commentsInstance.unresolvedCount.value > 0 && !e.panelState.commentsOpen.value ? (i(), p("span", ct, d(e.commentsInstance.unresolvedCount.value), 1)) : m("", !0)
|
|
637
|
+
], 14, st)) : m("", !0),
|
|
637
638
|
e.featureFlags.canUseAiGeneration.value && e.featureFlags.hasTemplateSaved.value ? (i(), p("div", {
|
|
638
639
|
key: 4,
|
|
639
640
|
ref: (t) => e.panelState.aiMenuRef.value = t,
|
|
@@ -642,11 +643,11 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
642
643
|
"aria-expanded": e.panelState.aiMenuOpen.value,
|
|
643
644
|
class: b(["tpl-ai-btn tpl:inline-flex tpl:items-center tpl:gap-1.5 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-4 tpl:py-2 tpl:text-sm tpl:font-semibold tpl:whitespace-nowrap tpl:transition-all tpl:duration-200", e.panelState.aiButtonActive.value ? "tpl-ai-btn--active" : "tpl-ai-btn--idle"]),
|
|
644
645
|
onClick: l[1] ||= _((...t) => e.panelState.toggleAiMenu && e.panelState.toggleAiMenu(...t), ["stop"])
|
|
645
|
-
}, [D(h(
|
|
646
|
+
}, [D(h(W), {
|
|
646
647
|
size: 16,
|
|
647
648
|
"stroke-width": 2,
|
|
648
649
|
class: "tpl-ai-btn-icon"
|
|
649
|
-
}), T(" " + d(h(a).aiChat.button), 1)], 10,
|
|
650
|
+
}), T(" " + d(h(a).aiChat.button), 1)], 10, lt), D(y, {
|
|
650
651
|
"enter-active-class": "tpl:transition-all tpl:duration-150 tpl:ease-out",
|
|
651
652
|
"enter-from-class": "tpl:scale-95 tpl:opacity-0",
|
|
652
653
|
"enter-to-class": "tpl:scale-100 tpl:opacity-100",
|
|
@@ -654,7 +655,7 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
654
655
|
"leave-from-class": "tpl:scale-100 tpl:opacity-100",
|
|
655
656
|
"leave-to-class": "tpl:scale-95 tpl:opacity-0"
|
|
656
657
|
}, {
|
|
657
|
-
default: s(() => [e.panelState.aiMenuOpen.value ? (i(), p("div",
|
|
658
|
+
default: s(() => [e.panelState.aiMenuOpen.value ? (i(), p("div", ut, [D(h(r), {
|
|
658
659
|
"active-feature": e.panelState.activeAiFeature.value,
|
|
659
660
|
onSelect: e.panelState.handleAiFeatureSelect
|
|
660
661
|
}, null, 8, ["active-feature", "onSelect"])])) : m("", !0)]),
|
|
@@ -670,16 +671,16 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
670
671
|
},
|
|
671
672
|
disabled: e.testEmail.isSending.value || !e.featureFlags.hasTemplateSaved.value,
|
|
672
673
|
onClick: l[2] ||= (t) => e.panelState.testEmailModalOpen.value = !0
|
|
673
|
-
}, [e.testEmail.isSending.value ? (i(), v(h(
|
|
674
|
+
}, [e.testEmail.isSending.value ? (i(), v(h(ye), {
|
|
674
675
|
key: 1,
|
|
675
676
|
class: "tpl-spinner",
|
|
676
677
|
size: 16,
|
|
677
678
|
"stroke-width": 2
|
|
678
|
-
})) : (i(), v(h(
|
|
679
|
+
})) : (i(), v(h(ce), {
|
|
679
680
|
key: 0,
|
|
680
681
|
size: 16,
|
|
681
682
|
"stroke-width": 2
|
|
682
|
-
})), T(" " + d(h(a).testEmail.button), 1)], 10,
|
|
683
|
+
})), T(" " + d(h(a).testEmail.button), 1)], 10, dt)) : m("", !0),
|
|
683
684
|
x("button", {
|
|
684
685
|
class: b(h($)),
|
|
685
686
|
style: {
|
|
@@ -689,20 +690,20 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
689
690
|
},
|
|
690
691
|
disabled: e.isSaveDisabled,
|
|
691
692
|
onClick: l[3] ||= (e) => c.$emit("save")
|
|
692
|
-
}, [e.isSaving ? (i(), v(h(
|
|
693
|
+
}, [e.isSaving ? (i(), v(h(ye), {
|
|
693
694
|
key: 1,
|
|
694
695
|
class: "tpl-spinner",
|
|
695
696
|
size: 16,
|
|
696
697
|
"stroke-width": 2
|
|
697
|
-
})) : (i(), v(h(
|
|
698
|
+
})) : (i(), v(h(Se), {
|
|
698
699
|
key: 0,
|
|
699
700
|
size: 16,
|
|
700
701
|
"stroke-width": 2
|
|
701
|
-
})), T(" " + d(e.isSaving ? h(a).header.saving : h(a).header.save), 1)], 10,
|
|
702
|
+
})), T(" " + d(e.isSaving ? h(a).header.saving : h(a).header.save), 1)], 10, ft)
|
|
702
703
|
])
|
|
703
704
|
]));
|
|
704
705
|
}
|
|
705
|
-
}),
|
|
706
|
+
}), mt = /* @__PURE__ */ E({
|
|
706
707
|
__name: "CloudPanels",
|
|
707
708
|
props: {
|
|
708
709
|
config: {},
|
|
@@ -725,9 +726,9 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
725
726
|
"module-insert"
|
|
726
727
|
],
|
|
727
728
|
setup(e, { expose: t, emit: n }) {
|
|
728
|
-
let r = u(() => import("./features-
|
|
729
|
+
let r = u(() => import("./features-mO5NzwnN.js").then((e) => e.o)), a = u(() => import("./features-mO5NzwnN.js").then((e) => e.a)), o = u(() => import("./features-mO5NzwnN.js").then((e) => e.i)), s = u(() => import("./features-mO5NzwnN.js").then((e) => e.n)), l = u(() => import("./features-mO5NzwnN.js").then((e) => e.t)), d = u(() => import("./SaveModuleDialog-CxdYMutK.js")), f = u(() => import("./ModuleBrowserModal-348wCgft.js")), g = u(async () => {
|
|
729
730
|
try {
|
|
730
|
-
return (await import("./src-
|
|
731
|
+
return (await import("./src-B_ZRmuit.js")).MediaLibraryModal;
|
|
731
732
|
} catch {
|
|
732
733
|
throw Error("[Templatical] Cloud media library requires the optional peer dependency '@templatical/media-library'. Please install it.");
|
|
733
734
|
}
|
|
@@ -807,23 +808,23 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
807
808
|
])
|
|
808
809
|
], 64));
|
|
809
810
|
}
|
|
810
|
-
}),
|
|
811
|
+
}), ht = {
|
|
811
812
|
key: 0,
|
|
812
813
|
class: "tpl-loading tpl:absolute tpl:inset-0 tpl:z-overlay tpl:flex tpl:flex-col tpl:bg-[var(--tpl-bg)]"
|
|
813
|
-
},
|
|
814
|
+
}, gt = { class: "tpl:flex tpl:flex-1 tpl:overflow-hidden" }, _t = { class: "tpl:flex tpl:w-12 tpl:shrink-0 tpl:flex-col tpl:items-center tpl:gap-4 tpl:py-5 tpl:border-r tpl:border-[var(--tpl-border)]" }, vt = /* @__PURE__ */ E({
|
|
814
815
|
__name: "CloudLoadingOverlay",
|
|
815
816
|
props: { visible: { type: Boolean } },
|
|
816
817
|
setup(e) {
|
|
817
|
-
return (t, n) => e.visible ? (i(), p("div",
|
|
818
|
+
return (t, n) => e.visible ? (i(), p("div", ht, [n[1] ||= l("<div class=\"tpl:flex tpl:h-14 tpl:shrink-0 tpl:items-center tpl:justify-between tpl:px-4 tpl:border-b tpl:border-[var(--tpl-border)]\"><div class=\"tpl-shimmer tpl:h-5 tpl:w-28 tpl:rounded-[var(--tpl-radius-sm)]\"></div><div class=\"tpl:flex tpl:gap-3\"><div class=\"tpl-shimmer tpl:h-8 tpl:w-20 tpl:rounded-[var(--tpl-radius-sm)]\"></div><div class=\"tpl-shimmer tpl:h-8 tpl:w-20 tpl:rounded-[var(--tpl-radius-sm)]\"></div></div></div>", 1), x("div", gt, [x("div", _t, [(i(), p(w, null, o(5, (e) => x("div", {
|
|
818
819
|
key: e,
|
|
819
820
|
class: "tpl-shimmer tpl:size-7 tpl:rounded-[var(--tpl-radius-sm)]"
|
|
820
821
|
})), 64))]), n[0] ||= l("<div class=\"tpl:flex tpl:flex-1 tpl:items-start tpl:justify-center tpl:overflow-auto tpl:p-8 tpl:bg-[var(--tpl-canvas-bg)]\"><div class=\"tpl:w-full tpl:max-w-[600px] tpl:rounded-[var(--tpl-radius)] tpl:p-6 tpl:bg-[var(--tpl-bg)] tpl:shadow-[var(--tpl-shadow-sm)]\"><div class=\"tpl:space-y-2 tpl:py-4\"><div class=\"tpl-shimmer tpl:h-3 tpl:w-3/4 tpl:rounded\"></div><div class=\"tpl-shimmer tpl:h-3 tpl:w-full tpl:rounded\"></div><div class=\"tpl-shimmer tpl:h-3 tpl:w-5/6 tpl:rounded\"></div></div><div class=\"tpl:py-4\"><div class=\"tpl-shimmer tpl:h-44 tpl:w-full tpl:rounded-[var(--tpl-radius-sm)]\"></div></div><div class=\"tpl:space-y-2 tpl:py-4\"><div class=\"tpl-shimmer tpl:h-3 tpl:w-full tpl:rounded\"></div><div class=\"tpl-shimmer tpl:h-3 tpl:w-2/3 tpl:rounded\"></div></div><div class=\"tpl:flex tpl:justify-center tpl:py-4\"><div class=\"tpl-shimmer tpl:h-10 tpl:w-36 tpl:rounded-[var(--tpl-radius-sm)]\"></div></div><div class=\"tpl:space-y-2 tpl:py-4\"><div class=\"tpl-shimmer tpl:mx-auto tpl:h-2.5 tpl:w-1/2 tpl:rounded\"></div><div class=\"tpl-shimmer tpl:mx-auto tpl:h-2.5 tpl:w-1/3 tpl:rounded\"></div></div></div></div><div class=\"tpl:flex tpl:w-[320px] tpl:shrink-0 tpl:flex-col tpl:gap-4 tpl:p-4 tpl:border-l tpl:border-[var(--tpl-border)]\"><div class=\"tpl-shimmer tpl:h-8 tpl:rounded-[var(--tpl-radius-sm)]\"></div><div class=\"tpl-shimmer tpl:h-32 tpl:rounded-[var(--tpl-radius)]\"></div><div class=\"tpl-shimmer tpl:h-32 tpl:rounded-[var(--tpl-radius)]\"></div></div>", 2)])])) : m("", !0);
|
|
821
822
|
}
|
|
822
|
-
}),
|
|
823
|
+
}), yt = {
|
|
823
824
|
key: 0,
|
|
824
825
|
role: "alert",
|
|
825
826
|
class: "tpl-error tpl:absolute tpl:inset-0 tpl:z-overlay tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-6 tpl:px-8 tpl:bg-[var(--tpl-bg)]"
|
|
826
|
-
},
|
|
827
|
+
}, bt = { class: "tpl:flex tpl:size-16 tpl:items-center tpl:justify-center tpl:rounded-full tpl:bg-[var(--tpl-danger-light)]" }, xt = { class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-2 tpl:text-center" }, St = { class: "tpl:text-lg tpl:font-semibold tpl:text-[var(--tpl-text)]" }, Ct = { class: "tpl:max-w-md tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, wt = /* @__PURE__ */ E({
|
|
827
828
|
__name: "CloudErrorOverlay",
|
|
828
829
|
props: {
|
|
829
830
|
error: {},
|
|
@@ -838,13 +839,13 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
838
839
|
function o(e) {
|
|
839
840
|
return "isNotFound" in e && !!e.isNotFound;
|
|
840
841
|
}
|
|
841
|
-
return (t, s) => e.visible && e.error ? (i(), p("div",
|
|
842
|
-
x("div",
|
|
842
|
+
return (t, s) => e.visible && e.error ? (i(), p("div", yt, [
|
|
843
|
+
x("div", bt, [D(h(P), {
|
|
843
844
|
size: 32,
|
|
844
845
|
"stroke-width": 1.5,
|
|
845
846
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
846
847
|
})]),
|
|
847
|
-
x("div",
|
|
848
|
+
x("div", xt, [x("h2", St, d(h(r).error.title), 1), x("p", Ct, d(a(e.error)), 1)]),
|
|
848
849
|
o(e.error) ? m("", !0) : (i(), p("button", {
|
|
849
850
|
key: 0,
|
|
850
851
|
class: "tpl-btn tpl-btn-primary tpl:inline-flex tpl:items-center tpl:gap-2 tpl:rounded-md tpl:px-4 tpl:py-2.5 tpl:text-sm tpl:font-medium tpl:shadow-xs tpl:transition-all tpl:duration-150 tpl:hover:opacity-90 tpl:bg-[var(--tpl-primary)] tpl:text-[var(--tpl-bg)]",
|
|
@@ -852,20 +853,20 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
852
853
|
}, d(h(r).error.retry), 1))
|
|
853
854
|
])) : m("", !0);
|
|
854
855
|
}
|
|
855
|
-
}),
|
|
856
|
+
}), Tt = {
|
|
856
857
|
key: 0,
|
|
857
858
|
class: "tpl-preview-banner tpl:absolute tpl:top-14 tpl:right-0 tpl:left-0 tpl:z-40 tpl:flex tpl:items-center tpl:justify-center tpl:gap-4 tpl:px-4 tpl:py-3 tpl:bg-[var(--tpl-primary-light)] tpl:border-b tpl:border-[var(--tpl-primary)]"
|
|
858
|
-
},
|
|
859
|
+
}, Et = { class: "tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:text-[var(--tpl-text)]" }, Dt = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ot = /* @__PURE__ */ E({
|
|
859
860
|
__name: "SnapshotPreviewBanner",
|
|
860
861
|
props: { visible: { type: Boolean } },
|
|
861
862
|
emits: ["cancel", "confirm"],
|
|
862
863
|
setup(e, { emit: t }) {
|
|
863
864
|
let n = t, { t: r } = Q();
|
|
864
|
-
return (t, a) => e.visible ? (i(), p("div",
|
|
865
|
+
return (t, a) => e.visible ? (i(), p("div", Tt, [x("div", Et, [D(h(A), {
|
|
865
866
|
size: 18,
|
|
866
867
|
"stroke-width": 2,
|
|
867
868
|
class: "tpl:text-[var(--tpl-primary)]"
|
|
868
|
-
}), x("span", null, d(h(r).snapshotPreview.message), 1)]), x("div",
|
|
869
|
+
}), x("span", null, d(h(r).snapshotPreview.message), 1)]), x("div", Dt, [x("button", {
|
|
869
870
|
class: "tpl:rounded-md tpl:px-3 tpl:py-1.5 tpl:text-sm tpl:font-medium tpl:transition-all tpl:duration-150 tpl:text-[var(--tpl-text-muted)] tpl:border tpl:border-[var(--tpl-border)]",
|
|
870
871
|
style: { "background-color": "transparent" },
|
|
871
872
|
onClick: a[0] ||= (e) => n("cancel")
|
|
@@ -874,7 +875,7 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
874
875
|
onClick: a[1] ||= (e) => n("confirm")
|
|
875
876
|
}, d(h(r).snapshotPreview.restore), 1)])])) : m("", !0);
|
|
876
877
|
}
|
|
877
|
-
}),
|
|
878
|
+
}), kt = {
|
|
878
879
|
key: 0,
|
|
879
880
|
role: "status",
|
|
880
881
|
"aria-live": "polite",
|
|
@@ -884,14 +885,14 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
884
885
|
color: "var(--tpl-text)",
|
|
885
886
|
border: "1px solid var(--tpl-warning)"
|
|
886
887
|
}
|
|
887
|
-
},
|
|
888
|
+
}, At = /* @__PURE__ */ E({
|
|
888
889
|
__name: "CollabUndoToast",
|
|
889
890
|
props: { visible: { type: Boolean } },
|
|
890
891
|
setup(e) {
|
|
891
|
-
let { t } =
|
|
892
|
-
return (n, r) => e.visible ? (i(), p("div",
|
|
892
|
+
let { t } = M();
|
|
893
|
+
return (n, r) => e.visible ? (i(), p("div", kt, d(h(t).history.collabWarning), 1)) : m("", !0);
|
|
893
894
|
}
|
|
894
|
-
}),
|
|
895
|
+
}), jt = ["data-tpl-theme"], Mt = { class: "tpl:sticky tpl:top-0 tpl:z-40 tpl:h-0" }, Nt = { class: "tpl-main tpl:flex tpl:justify-center tpl:p-8" }, Pt = ["aria-label"], Ft = /*#__PURE__*/ q(/* @__PURE__ */ E({
|
|
895
896
|
__name: "CloudEditor",
|
|
896
897
|
props: {
|
|
897
898
|
config: {},
|
|
@@ -903,8 +904,8 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
903
904
|
emits: ["ready"],
|
|
904
905
|
setup(e, { expose: r, emit: o }) {
|
|
905
906
|
let l = e;
|
|
906
|
-
a(
|
|
907
|
-
let u = o, f = c(null), _ = c(null), w =
|
|
907
|
+
a(L, l.cloudTranslations);
|
|
908
|
+
let u = o, f = c(null), _ = c(null), w = ze({
|
|
908
909
|
config: l.config,
|
|
909
910
|
translations: l.translations,
|
|
910
911
|
fontsManager: l.fontsManager,
|
|
@@ -912,62 +913,62 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
912
913
|
getCommentsSidebar: () => f.value ? { filterByBlock: f.value.filterCommentsByBlock } : null,
|
|
913
914
|
editorRoot: l.shadowRoot,
|
|
914
915
|
containerEl: _
|
|
915
|
-
}), { isInitializing: E, isAuthReady:
|
|
916
|
-
async function
|
|
916
|
+
}), { isInitializing: E, isAuthReady: ee, initError: O, planConfigInstance: k, websocket: A, collaboration: j, isCollaborationEnabled: te, editor: M, core: N, featureFlags: P, mediaLib: ne, exporter: re, testEmail: F, commentsInstance: R, savedModulesHeadless: ie, panelState: B, snapshotPreview: V, collabWarning: ae, showSaveModuleDialog: H, showModuleBrowserModal: U, saveModulePreSelectedBlockId: W, setThemeOverrides: G, setUiTheme: oe } = w, { showNotice: K } = z(() => l.config.smallScreenNotice);
|
|
917
|
+
async function se(e) {
|
|
917
918
|
try {
|
|
918
|
-
await
|
|
919
|
+
await F.sendTestEmail(e), B.testEmailModalOpen.value = !1;
|
|
919
920
|
} catch {}
|
|
920
921
|
}
|
|
921
|
-
async function
|
|
922
|
+
async function q() {
|
|
922
923
|
try {
|
|
923
|
-
await
|
|
924
|
+
await V.confirmRestoreSnapshot();
|
|
924
925
|
} catch {}
|
|
925
926
|
}
|
|
926
|
-
function
|
|
927
|
+
function J(e, t) {
|
|
927
928
|
for (let n = 0; n < e.content.length; n++) {
|
|
928
|
-
let r =
|
|
929
|
-
|
|
929
|
+
let r = I(e.content[n]), i = t === void 0 ? void 0 : t + n;
|
|
930
|
+
M.addBlock(r, void 0, void 0, i);
|
|
930
931
|
}
|
|
931
|
-
|
|
932
|
+
U.value = !1;
|
|
932
933
|
}
|
|
933
|
-
let
|
|
934
|
+
let Y = Ve({
|
|
934
935
|
config: l.config,
|
|
935
|
-
editor:
|
|
936
|
-
websocket:
|
|
937
|
-
planConfigInstance:
|
|
938
|
-
snapshotPreview:
|
|
939
|
-
core:
|
|
940
|
-
exporter:
|
|
941
|
-
featureFlags:
|
|
936
|
+
editor: M,
|
|
937
|
+
websocket: A,
|
|
938
|
+
planConfigInstance: k,
|
|
939
|
+
snapshotPreview: V,
|
|
940
|
+
core: N,
|
|
941
|
+
exporter: re,
|
|
942
|
+
featureFlags: P,
|
|
942
943
|
isDestroyed: w.isDestroyed
|
|
943
|
-
}),
|
|
944
|
-
issues:
|
|
945
|
-
planConfig:
|
|
944
|
+
}), X = He({
|
|
945
|
+
issues: N.templateLint ? N.templateLint.issues : c([]),
|
|
946
|
+
planConfig: k.config
|
|
946
947
|
});
|
|
947
|
-
async function
|
|
948
|
-
await
|
|
948
|
+
async function Z() {
|
|
949
|
+
await X.tryRunSave(() => Y.saveTemplate().catch((e) => l.config.onError?.(e)));
|
|
949
950
|
}
|
|
950
|
-
return w.onSaveHook.value =
|
|
951
|
+
return w.onSaveHook.value = Z, t(() => {
|
|
951
952
|
w.initialize();
|
|
952
953
|
}), g(() => {
|
|
953
954
|
w.destroy();
|
|
954
955
|
}), r({
|
|
955
|
-
getContent: () =>
|
|
956
|
-
setContent: (e) =>
|
|
957
|
-
setTheme:
|
|
958
|
-
setThemeOverrides:
|
|
959
|
-
create:
|
|
960
|
-
load:
|
|
961
|
-
save:
|
|
962
|
-
sendTestEmail:
|
|
956
|
+
getContent: () => M.content.value,
|
|
957
|
+
setContent: (e) => M.setContent(e),
|
|
958
|
+
setTheme: oe,
|
|
959
|
+
setThemeOverrides: G,
|
|
960
|
+
create: Y.createTemplate,
|
|
961
|
+
load: Y.loadTemplate,
|
|
962
|
+
save: Y.saveTemplate,
|
|
963
|
+
sendTestEmail: F.sendTestEmail
|
|
963
964
|
}), (t, r) => (i(), p("div", {
|
|
964
965
|
ref_key: "rootEl",
|
|
965
966
|
ref: _,
|
|
966
|
-
class: b(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": h(
|
|
967
|
-
"data-tpl-theme": h(
|
|
968
|
-
style: C(h(
|
|
967
|
+
class: b(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": h(M).state.darkMode }]),
|
|
968
|
+
"data-tpl-theme": h(N).resolvedTheme.value,
|
|
969
|
+
style: C(h(N).themeStyles.value)
|
|
969
970
|
}, [
|
|
970
|
-
D(
|
|
971
|
+
D(De),
|
|
971
972
|
D(y, {
|
|
972
973
|
"enter-active-class": "tpl:transition-opacity tpl:duration-200",
|
|
973
974
|
"enter-from-class": "tpl:opacity-100",
|
|
@@ -976,7 +977,7 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
976
977
|
"leave-from-class": "tpl:opacity-100",
|
|
977
978
|
"leave-to-class": "tpl:opacity-0"
|
|
978
979
|
}, {
|
|
979
|
-
default: s(() => [D(
|
|
980
|
+
default: s(() => [D(vt, { visible: h(E) || h(M).state.isLoading }, null, 8, ["visible"])]),
|
|
980
981
|
_: 1
|
|
981
982
|
}),
|
|
982
983
|
D(y, {
|
|
@@ -987,9 +988,9 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
987
988
|
"leave-from-class": "tpl:opacity-100",
|
|
988
989
|
"leave-to-class": "tpl:opacity-0"
|
|
989
990
|
}, {
|
|
990
|
-
default: s(() => [D(
|
|
991
|
-
error: h(
|
|
992
|
-
visible: !!h(
|
|
991
|
+
default: s(() => [D(wt, {
|
|
992
|
+
error: h(O),
|
|
993
|
+
visible: !!h(O) && !h(E),
|
|
993
994
|
onRetry: h(w).initialize
|
|
994
995
|
}, null, 8, [
|
|
995
996
|
"error",
|
|
@@ -998,20 +999,20 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
998
999
|
])]),
|
|
999
1000
|
_: 1
|
|
1000
1001
|
}),
|
|
1001
|
-
D(
|
|
1002
|
-
editor: h(
|
|
1003
|
-
core: h(
|
|
1004
|
-
"feature-flags": h(
|
|
1005
|
-
"panel-state": h(
|
|
1006
|
-
"snapshot-preview": h(
|
|
1007
|
-
"comments-instance": h(
|
|
1008
|
-
"test-email": h(
|
|
1009
|
-
websocket: h(
|
|
1010
|
-
collaboration: h(
|
|
1011
|
-
"is-collaboration-enabled": h(
|
|
1012
|
-
"is-saving": h(
|
|
1013
|
-
"is-save-disabled": h(
|
|
1014
|
-
onSave:
|
|
1002
|
+
D(pt, {
|
|
1003
|
+
editor: h(M),
|
|
1004
|
+
core: h(N),
|
|
1005
|
+
"feature-flags": h(P),
|
|
1006
|
+
"panel-state": h(B),
|
|
1007
|
+
"snapshot-preview": h(V),
|
|
1008
|
+
"comments-instance": h(R),
|
|
1009
|
+
"test-email": h(F),
|
|
1010
|
+
websocket: h(A),
|
|
1011
|
+
collaboration: h(j),
|
|
1012
|
+
"is-collaboration-enabled": h(te),
|
|
1013
|
+
"is-saving": h(M).state.isSaving || h(P).isSaveExporting.value,
|
|
1014
|
+
"is-save-disabled": h(M).state.isSaving || h(P).isSaveExporting.value || !h(M).state.isDirty,
|
|
1015
|
+
onSave: Z
|
|
1015
1016
|
}, null, 8, [
|
|
1016
1017
|
"editor",
|
|
1017
1018
|
"core",
|
|
@@ -1026,21 +1027,21 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1026
1027
|
"is-saving",
|
|
1027
1028
|
"is-save-disabled"
|
|
1028
1029
|
]),
|
|
1029
|
-
D(
|
|
1030
|
-
open: h(
|
|
1031
|
-
issues: h(
|
|
1032
|
-
onCancel: h(
|
|
1033
|
-
onConfirm: h(
|
|
1030
|
+
D(Qe, {
|
|
1031
|
+
open: h(X).modalOpen.value,
|
|
1032
|
+
issues: h(X).blockingIssues.value,
|
|
1033
|
+
onCancel: h(X).cancel,
|
|
1034
|
+
onConfirm: h(X).confirmAndSave
|
|
1034
1035
|
}, null, 8, [
|
|
1035
1036
|
"open",
|
|
1036
1037
|
"issues",
|
|
1037
1038
|
"onCancel",
|
|
1038
1039
|
"onConfirm"
|
|
1039
1040
|
]),
|
|
1040
|
-
D(
|
|
1041
|
-
visible: h(
|
|
1042
|
-
onCancel: h(
|
|
1043
|
-
onConfirm:
|
|
1041
|
+
D(Ot, {
|
|
1042
|
+
visible: h(V).isPreviewingSnapshot.value,
|
|
1043
|
+
onCancel: h(V).cancelPreview,
|
|
1044
|
+
onConfirm: q
|
|
1044
1045
|
}, null, 8, ["visible", "onCancel"]),
|
|
1045
1046
|
D(y, {
|
|
1046
1047
|
"enter-active-class": "tpl:transition-all tpl:duration-200 tpl:ease-out",
|
|
@@ -1050,18 +1051,18 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1050
1051
|
"leave-from-class": "tpl:translate-y-0 tpl:opacity-100",
|
|
1051
1052
|
"leave-to-class": "tpl:translate-y-[-8px] tpl:opacity-0"
|
|
1052
1053
|
}, {
|
|
1053
|
-
default: s(() => [D(
|
|
1054
|
+
default: s(() => [D(At, { visible: h(ae).collabUndoWarningVisible.value }, null, 8, ["visible"])]),
|
|
1054
1055
|
_: 1
|
|
1055
1056
|
}),
|
|
1056
|
-
n(D(
|
|
1057
|
+
n(D(we, null, null, 512), [[S, !h(M).state.previewMode]]),
|
|
1057
1058
|
x("div", {
|
|
1058
|
-
class: b(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [h(
|
|
1059
|
+
class: b(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [h(M).state.previewMode ? "tpl:left-0 tpl:right-0" : h(B).rightPanelOpen.value ? "tpl:left-12 tpl:right-[680px]" : "tpl:left-12 tpl:right-[320px]", h(V).isPreviewingSnapshot.value ? "tpl:top-[104px]" : "tpl:top-14"]]),
|
|
1059
1060
|
style: {
|
|
1060
1061
|
transition: "all 300ms cubic-bezier(0.34, 1.56, 0.64, 1)",
|
|
1061
1062
|
"background-color": "var(--tpl-canvas-bg)"
|
|
1062
1063
|
}
|
|
1063
|
-
}, [x("div",
|
|
1064
|
-
default: s(() => [h(
|
|
1064
|
+
}, [x("div", Mt, [D(y, { name: "tpl-restore-btn" }, {
|
|
1065
|
+
default: s(() => [h(N).conditionPreview.hasHiddenBlocks.value ? (i(), p("button", {
|
|
1065
1066
|
key: 0,
|
|
1066
1067
|
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",
|
|
1067
1068
|
style: {
|
|
@@ -1070,22 +1071,22 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1070
1071
|
"border-color": "var(--tpl-warning)",
|
|
1071
1072
|
"backdrop-filter": "blur(8px)"
|
|
1072
1073
|
},
|
|
1073
|
-
onClick: r[0] ||= (e) => h(
|
|
1074
|
-
}, [D(h(
|
|
1074
|
+
onClick: r[0] ||= (e) => h(N).conditionPreview.reset()
|
|
1075
|
+
}, [D(h(xe), {
|
|
1075
1076
|
size: 13,
|
|
1076
1077
|
"stroke-width": 2
|
|
1077
|
-
}), T(" " + d(h(
|
|
1078
|
+
}), T(" " + d(h(N).t.blockSettings.restoreHiddenBlocks), 1)])) : m("", !0)]),
|
|
1078
1079
|
_: 1
|
|
1079
|
-
})]), x("main",
|
|
1080
|
-
viewport: h(
|
|
1081
|
-
content: h(
|
|
1082
|
-
"selected-block-id": h(
|
|
1083
|
-
"dark-mode": h(
|
|
1084
|
-
"preview-mode": h(
|
|
1085
|
-
"locked-blocks": h(
|
|
1086
|
-
onSelectBlock: h(
|
|
1087
|
-
onOpenAiChat: r[1] ||= (e) => h(
|
|
1088
|
-
onOpenDesignReference: r[2] ||= (e) => h(
|
|
1080
|
+
})]), x("main", Nt, [D(Ne, {
|
|
1081
|
+
viewport: h(M).state.viewport,
|
|
1082
|
+
content: h(M).content.value,
|
|
1083
|
+
"selected-block-id": h(M).state.selectedBlockId,
|
|
1084
|
+
"dark-mode": h(M).state.darkMode,
|
|
1085
|
+
"preview-mode": h(M).state.previewMode,
|
|
1086
|
+
"locked-blocks": h(j)?.lockedBlocks.value ?? void 0,
|
|
1087
|
+
onSelectBlock: h(M).selectBlock,
|
|
1088
|
+
onOpenAiChat: r[1] ||= (e) => h(B).aiChatOpen.value = !0,
|
|
1089
|
+
onOpenDesignReference: r[2] ||= (e) => h(B).designReferenceOpen.value = !0
|
|
1089
1090
|
}, null, 8, [
|
|
1090
1091
|
"viewport",
|
|
1091
1092
|
"content",
|
|
@@ -1095,51 +1096,51 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1095
1096
|
"locked-blocks",
|
|
1096
1097
|
"onSelectBlock"
|
|
1097
1098
|
])])], 2),
|
|
1098
|
-
e.config.branding !== !1 && !h(
|
|
1099
|
+
e.config.branding !== !1 && !h(P).isWhiteLabeled.value ? (i(), v(Oe, {
|
|
1099
1100
|
key: 0,
|
|
1100
|
-
"position-class": [h(
|
|
1101
|
+
"position-class": [h(M).state.previewMode ? "tpl:left-0 tpl:right-0" : h(B).rightPanelOpen.value ? "tpl:left-12 tpl:right-[680px]" : "tpl:left-12 tpl:right-[320px]"]
|
|
1101
1102
|
}, null, 8, ["position-class"])) : m("", !0),
|
|
1102
1103
|
x("div", {
|
|
1103
1104
|
class: "tpl-sr-only",
|
|
1104
1105
|
role: "status",
|
|
1105
1106
|
"aria-live": "polite",
|
|
1106
1107
|
"aria-atomic": "true",
|
|
1107
|
-
"aria-label": h(
|
|
1108
|
-
}, d(h(
|
|
1109
|
-
n(D(
|
|
1110
|
-
"selected-block": h(
|
|
1111
|
-
settings: h(
|
|
1112
|
-
"shifted-left": h(
|
|
1113
|
-
onUpdateBlock: r[3] ||= (e) => h(
|
|
1114
|
-
onDeleteBlock: r[4] ||= (e) => h(
|
|
1115
|
-
onDuplicateBlock: r[5] ||= (e) => h(
|
|
1116
|
-
onUpdateSettings: h(
|
|
1108
|
+
"aria-label": h(N).t.landmarks.reorderAnnouncements
|
|
1109
|
+
}, d(h(N).keyboardReorder.announcement.value), 9, Pt),
|
|
1110
|
+
n(D(je, {
|
|
1111
|
+
"selected-block": h(M).selectedBlock.value,
|
|
1112
|
+
settings: h(M).content.value.settings,
|
|
1113
|
+
"shifted-left": h(B).rightPanelOpen.value,
|
|
1114
|
+
onUpdateBlock: r[3] ||= (e) => h(M).updateBlock(h(M).selectedBlock.value.id, e),
|
|
1115
|
+
onDeleteBlock: r[4] ||= (e) => h(N).blockActions.deleteBlock(h(M).selectedBlock.value.id),
|
|
1116
|
+
onDuplicateBlock: r[5] ||= (e) => h(N).blockActions.duplicateBlock(h(M).selectedBlock.value),
|
|
1117
|
+
onUpdateSettings: h(M).updateSettings
|
|
1117
1118
|
}, null, 8, [
|
|
1118
1119
|
"selected-block",
|
|
1119
1120
|
"settings",
|
|
1120
1121
|
"shifted-left",
|
|
1121
1122
|
"onUpdateSettings"
|
|
1122
|
-
]), [[S, !h(
|
|
1123
|
-
!h(E) && h(
|
|
1123
|
+
]), [[S, !h(M).state.previewMode]]),
|
|
1124
|
+
!h(E) && h(ee) ? (i(), v(mt, {
|
|
1124
1125
|
key: 1,
|
|
1125
1126
|
ref_key: "cloudPanelsRef",
|
|
1126
1127
|
ref: f,
|
|
1127
1128
|
config: l.config,
|
|
1128
|
-
editor: h(
|
|
1129
|
-
core: h(
|
|
1130
|
-
"panel-state": h(
|
|
1131
|
-
"plan-config-instance": h(
|
|
1132
|
-
"test-email": h(
|
|
1133
|
-
"media-lib": h(
|
|
1134
|
-
"saved-modules-headless": h(
|
|
1135
|
-
"show-save-module-dialog": h(
|
|
1136
|
-
"save-module-pre-selected-block-id": h(
|
|
1137
|
-
"show-module-browser-modal": h(
|
|
1138
|
-
"onUpdate:showSaveModuleDialog": r[6] ||= (e) =>
|
|
1139
|
-
"onUpdate:saveModulePreSelectedBlockId": r[7] ||= (e) =>
|
|
1140
|
-
"onUpdate:showModuleBrowserModal": r[8] ||= (e) =>
|
|
1141
|
-
onSendTestEmail:
|
|
1142
|
-
onModuleInsert:
|
|
1129
|
+
editor: h(M),
|
|
1130
|
+
core: h(N),
|
|
1131
|
+
"panel-state": h(B),
|
|
1132
|
+
"plan-config-instance": h(k),
|
|
1133
|
+
"test-email": h(F),
|
|
1134
|
+
"media-lib": h(ne),
|
|
1135
|
+
"saved-modules-headless": h(ie),
|
|
1136
|
+
"show-save-module-dialog": h(H),
|
|
1137
|
+
"save-module-pre-selected-block-id": h(W),
|
|
1138
|
+
"show-module-browser-modal": h(U),
|
|
1139
|
+
"onUpdate:showSaveModuleDialog": r[6] ||= (e) => H.value = e,
|
|
1140
|
+
"onUpdate:saveModulePreSelectedBlockId": r[7] ||= (e) => W.value = e,
|
|
1141
|
+
"onUpdate:showModuleBrowserModal": r[8] ||= (e) => U.value = e,
|
|
1142
|
+
onSendTestEmail: se,
|
|
1143
|
+
onModuleInsert: J
|
|
1143
1144
|
}, null, 8, [
|
|
1144
1145
|
"config",
|
|
1145
1146
|
"editor",
|
|
@@ -1154,14 +1155,15 @@ var Ve = ["aria-label"], He = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1154
1155
|
"show-module-browser-modal"
|
|
1155
1156
|
])) : m("", !0),
|
|
1156
1157
|
x("div", {
|
|
1157
|
-
ref: (e) => h(
|
|
1158
|
+
ref: (e) => h(N).popoverRoot.value = e,
|
|
1158
1159
|
class: "tpl-popover-root"
|
|
1159
1160
|
}, null, 512),
|
|
1160
|
-
D(
|
|
1161
|
-
|
|
1161
|
+
D(Me),
|
|
1162
|
+
h(K) ? (i(), v(ke, { key: 2 })) : m("", !0)
|
|
1163
|
+
], 14, jt));
|
|
1162
1164
|
}
|
|
1163
|
-
}), [["__scopeId", "data-v-
|
|
1165
|
+
}), [["__scopeId", "data-v-df1ba3f4"]]);
|
|
1164
1166
|
//#endregion
|
|
1165
|
-
export {
|
|
1167
|
+
export { Ft as default };
|
|
1166
1168
|
|
|
1167
|
-
//# sourceMappingURL=CloudEditor-
|
|
1169
|
+
//# sourceMappingURL=CloudEditor-hxoqsTsq.js.map
|