@aswin.dev/editor 0.7.1 → 0.7.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +56 -0
- package/dist/{AccessibilityPanel-COL6Wm7p.js → AccessibilityPanel-EmQ19wiS.js} +1 -1
- package/dist/{AiChatSidebar-DWGPVtvC.js → AiChatSidebar-DeB0w_32.js} +38 -52
- package/dist/{AiFeatureMenu-duUFSfDf.js → AiFeatureMenu-DoLD5Cde.js} +5 -5
- package/dist/{BlockA11yBadge-Qs6HtXid.js → BlockA11yBadge-DkNbDvJA.js} +1 -1
- package/dist/{CloudEditor-CFldoCOb.js → CloudEditor-zo9PjjvY.js} +255 -248
- package/dist/{CollaboratorBar-Bw-lbt61.js → CollaboratorBar-BsXMY-8e.js} +3 -3
- package/dist/{CommentsSidebar-BaD5F53-.js → CommentsSidebar-DIWIa4rS.js} +6 -6
- package/dist/{CountdownToolbar-Dg4F8MTk.js → CountdownToolbar-BuS8p5ju.js} +2 -2
- package/dist/{DesignReferenceSidebar-BSH7uNP_.js → DesignReferenceSidebar-RDlnhL-6.js} +5 -5
- package/dist/{LoadingTrack-Ba2pfF57.js → LoadingTrack-BJ59h9ok.js} +1 -1
- package/dist/{ModuleBrowserModal-6phxZSKI.js → ModuleBrowserModal-b7HbpByz.js} +7 -7
- package/dist/{ModulePreviewCanvas-BW8L3eQX.js → ModulePreviewCanvas-D__YlOLS.js} +1 -1
- package/dist/{NumberWithSuffix-BpUzQOJt.js → NumberWithSuffix-Ca3vNY84.js} +1 -1
- package/dist/{ParagraphEditor-DNSzAB-I.js → ParagraphEditor-B1aYPO-6.js} +18 -18
- package/dist/{RichTextEditorContent-CrqPQdnk.js → RichTextEditorContent-BmEVMrkJ.js} +1 -1
- package/dist/{SaveModuleDialog-zMQTpez7.js → SaveModuleDialog-ClovqI6h.js} +3 -3
- package/dist/{SnapshotHistory-Do-A5rYU.js → SnapshotHistory-DoqtH0cw.js} +3 -3
- package/dist/{TemplateScoringPanel-CS7o62zS.js → TemplateScoringPanel-DQv2ZAiL.js} +7 -7
- package/dist/{TestEmailModal-DGj_9V1u.js → TestEmailModal-iIeYJYsj.js} +3 -3
- package/dist/{TitleEditor-C7IDnAoS.js → TitleEditor-CTDIwRF_.js} +7 -7
- package/dist/{TplModal-BAsVzcTb.js → TplModal-CBq1J1pG.js} +1 -1
- package/dist/{blockTypeIcons-C6LDKvmd.js → blockTypeIcons-QkC6f5UE.js} +1 -1
- package/dist/bundle-stats.json +7 -7
- package/dist/cdn/chunks/AccessibilityPanel-BeU8nz7A.js +97 -0
- package/dist/cdn/chunks/AccessibilityPanel-BeU8nz7A.js.map +1 -0
- package/dist/cdn/chunks/AiFeatureMenu-B2mhscyP.js +59 -0
- package/dist/cdn/chunks/AiFeatureMenu-B2mhscyP.js.map +1 -0
- package/dist/cdn/chunks/BlockA11yBadge-C4g77gF0.js +33 -0
- package/dist/cdn/chunks/BlockA11yBadge-C4g77gF0.js.map +1 -0
- package/dist/cdn/chunks/CloudEditor-Btyr0b0_.js +1183 -0
- package/dist/cdn/chunks/CloudEditor-Btyr0b0_.js.map +1 -0
- package/dist/cdn/chunks/CollaboratorBar-YBiIjiRh.js +51 -0
- package/dist/cdn/chunks/CollaboratorBar-YBiIjiRh.js.map +1 -0
- package/dist/cdn/chunks/CountdownBlock-B06UZoWe.js +93 -0
- package/dist/cdn/chunks/CountdownBlock-B06UZoWe.js.map +1 -0
- package/dist/cdn/chunks/CountdownToolbar-C9XZr33O.js +212 -0
- package/dist/cdn/chunks/CountdownToolbar-C9XZr33O.js.map +1 -0
- package/dist/cdn/chunks/ModuleBrowserModal-C2CDWKW6.js +195 -0
- package/dist/cdn/chunks/ModuleBrowserModal-C2CDWKW6.js.map +1 -0
- package/dist/cdn/chunks/ModulePreviewCanvas-Drt8Evai.js +109 -0
- package/dist/cdn/chunks/ModulePreviewCanvas-Drt8Evai.js.map +1 -0
- package/dist/cdn/chunks/NumberWithSuffix-Ty1bp9vB.js +423 -0
- package/dist/cdn/chunks/NumberWithSuffix-Ty1bp9vB.js.map +1 -0
- package/dist/cdn/chunks/ParagraphEditor-BA1WbHI7.js +544 -0
- package/dist/cdn/chunks/ParagraphEditor-BA1WbHI7.js.map +1 -0
- package/dist/cdn/chunks/RichTextEditorContent-BtWCA_Oc.js +106 -0
- package/dist/cdn/chunks/RichTextEditorContent-BtWCA_Oc.js.map +1 -0
- package/dist/cdn/chunks/SaveModuleDialog-AwL0tkCV.js +119 -0
- package/dist/cdn/chunks/SaveModuleDialog-AwL0tkCV.js.map +1 -0
- package/dist/cdn/chunks/TitleEditor-DbSyeixS.js +171 -0
- package/dist/cdn/chunks/TitleEditor-DbSyeixS.js.map +1 -0
- package/dist/cdn/chunks/blockTypeIcons-pQIkxJzc.js +23 -0
- package/dist/cdn/chunks/blockTypeIcons-pQIkxJzc.js.map +1 -0
- package/dist/cdn/chunks/de-Ce-LbJ2J.js +89 -0
- package/dist/cdn/chunks/de-Ce-LbJ2J.js.map +1 -0
- package/dist/cdn/chunks/de-RQrZR56a.js +209 -0
- package/dist/cdn/chunks/de-RQrZR56a.js.map +1 -0
- package/dist/cdn/chunks/de-_tooy3Q8.js +771 -0
- package/dist/cdn/chunks/de-_tooy3Q8.js.map +1 -0
- package/dist/cdn/chunks/draggable-C-1_gch3.js +11572 -0
- package/dist/cdn/chunks/draggable-C-1_gch3.js.map +1 -0
- package/dist/cdn/chunks/emojiData-EMFlj6FJ.js +19 -0
- package/dist/cdn/chunks/emojiData-EMFlj6FJ.js.map +1 -0
- package/dist/cdn/chunks/en-Bl1ecfRF.js +209 -0
- package/dist/cdn/chunks/en-Bl1ecfRF.js.map +1 -0
- package/dist/cdn/chunks/en-CNqLoIm9.js +771 -0
- package/dist/cdn/chunks/en-CNqLoIm9.js.map +1 -0
- package/dist/cdn/chunks/en-DiCWK5fG.js +89 -0
- package/dist/cdn/chunks/en-DiCWK5fG.js.map +1 -0
- package/dist/cdn/chunks/extensions-BVKQw_sp.js +598 -0
- package/dist/cdn/chunks/extensions-BVKQw_sp.js.map +1 -0
- package/dist/cdn/chunks/features-DIBEo4xl.js +7913 -0
- package/dist/cdn/chunks/features-DIBEo4xl.js.map +1 -0
- package/dist/cdn/chunks/icons-C1Gg-ov-.js +992 -0
- package/dist/cdn/chunks/icons-C1Gg-ov-.js.map +1 -0
- package/dist/cdn/chunks/liquid.browser-lQbkge2E.js +3279 -0
- package/dist/cdn/chunks/liquid.browser-lQbkge2E.js.map +1 -0
- package/dist/cdn/chunks/media-library-BTF_Ko70.js +6014 -0
- package/dist/cdn/chunks/media-library-BTF_Ko70.js.map +1 -0
- package/dist/cdn/chunks/pusher-CDbNlZBE.js +2508 -0
- package/dist/cdn/chunks/pusher-CDbNlZBE.js.map +1 -0
- package/dist/cdn/chunks/quality-C5AmotmP.js +1456 -0
- package/dist/cdn/chunks/quality-C5AmotmP.js.map +1 -0
- package/dist/cdn/chunks/readableTextColor-DhoK4XiZ.js +32 -0
- package/dist/cdn/chunks/readableTextColor-DhoK4XiZ.js.map +1 -0
- package/dist/cdn/chunks/renderer-D0L44Vlp.js +642 -0
- package/dist/cdn/chunks/renderer-D0L44Vlp.js.map +1 -0
- package/dist/cdn/chunks/rolldown-runtime-BNuo_Jkg.js +20 -0
- package/dist/cdn/chunks/src-RKexlYjA.js +497 -0
- package/dist/cdn/chunks/src-RKexlYjA.js.map +1 -0
- package/dist/cdn/chunks/styleConstants-PgmvNBzQ.js +57 -0
- package/dist/cdn/chunks/styleConstants-PgmvNBzQ.js.map +1 -0
- package/dist/cdn/chunks/styles-CQR6ed13.js +4976 -0
- package/dist/cdn/chunks/styles-CQR6ed13.js.map +1 -0
- package/dist/cdn/chunks/tiptap-CDzAbF2j.js +14654 -0
- package/dist/cdn/chunks/tiptap-CDzAbF2j.js.map +1 -0
- package/dist/cdn/editor.css +2 -0
- package/dist/cdn/editor.js +338 -0
- package/dist/cdn/editor.js.map +1 -0
- package/dist/{cloud-6ZmAvF0j.js → cloud-DJG4tb4_.js} +1 -1
- package/dist/{de-DWcgp-7T.js → de-2LEvILeZ.js} +40 -0
- package/dist/{dist-DtiDUrX-.js → dist-BHAeXaUY.js} +1 -1
- package/dist/{dist-BUzw1buG.js → dist-BSJvAvH3.js} +1 -1
- package/dist/{dist-COSzWQUs.js → dist-BeFnymxK.js} +1 -1
- package/dist/dist-Bmir0gYb.js +1167 -0
- package/dist/{dist-C3T2AKtB.js → dist-BvPgo-UK.js} +1 -1
- package/dist/{dist-C9ckKEZL.js → dist-CPVBKMmd.js} +1 -1
- package/dist/{dist-BadNx4qo.js → dist-Df4ie7vZ.js} +1 -1
- package/dist/{dist-CBItRG-Z.js → dist-DxOoemkW.js} +1 -1
- package/dist/{dist-Dzt5foyL.js → dist-HEQ52gTJ.js} +1 -1
- package/dist/{dist-BZyY-SS4.js → dist-b-XUqAoF.js} +1 -1
- package/dist/{dist-Bz3M4RXG.js → dist-kZfaVUpW.js} +3 -3
- package/dist/{dist-BesOh2mk.js → dist-wfAedlzi.js} +1 -1
- package/dist/{en-Cxd4fhNm.js → en-D2RU2Poj.js} +40 -0
- package/dist/{extensions-D__hOlV1.js → extensions-BQ1xXx3d.js} +21 -21
- package/dist/index.d.ts +17 -6
- package/dist/style.css +1 -1
- package/dist/{styles-B4tjX5SP.js → styles-CavWjvol.js} +1573 -1310
- package/dist/templatical-editor.js +161 -132
- package/dist/undo-2-Cg8I7obC.js +16 -0
- package/dist/{useEditorCore-wslttMH-.js → useEditorCore-BGnzcT7p.js} +37 -37
- package/dist/{useMergeTag-DX0XG5V9.js → useMergeTag-CfuZq2fF.js} +3 -3
- package/package.json +12 -12
- package/dist/dist-C04s_fLA.js +0 -563
- /package/dist/{CountdownBlock-DaYGxKqo.js → CountdownBlock-BCi7-DAM.js} +0 -0
- /package/dist/{_plugin-vue_export-helper-BVAJ4lgT.js → _plugin-vue_export-helper-Bwh4ceeO.js} +0 -0
- /package/dist/{de-GOtR9DwW.js → de-D2npYjrZ.js} +0 -0
- /package/dist/{dist-DXa1uAMh.js → dist-DvHLtWVP.js} +0 -0
- /package/dist/{emojiData-DrBuvEoP.js → emojiData-DvQBBzmO.js} +0 -0
- /package/dist/{en-dFFQVzNn.js → en-ib-4h3_o.js} +0 -0
- /package/dist/{formatRelativeTime-BhhO8yCl.js → formatRelativeTime-CFDZnEIs.js} +0 -0
- /package/dist/{liquid.browser-BvCyLQII.js → liquid.browser-7Rv0QDiO.js} +0 -0
- /package/dist/{readableTextColor-DVuzNX1y.js → readableTextColor-C_9OpzBw.js} +0 -0
- /package/dist/{scan-line-CzfFJO1o.js → scan-line-DlghmhNf.js} +0 -0
- /package/dist/{send-D2eSo4GH.js → send-DDdhIRj8.js} +0 -0
- /package/dist/{shield-check-jkpgcC0-.js → shield-check-OSQ-JVTX.js} +0 -0
- /package/dist/{sparkles-Chm5CZfb.js → sparkles-BN4a-CoF.js} +0 -0
- /package/dist/{styleConstants-34eUKPOZ.js → styleConstants-wWRbcuEK.js} +0 -0
- /package/dist/{text-align-start-CzBnJsW8.js → text-align-start-D1weisjS.js} +0 -0
- /package/dist/{trash-2-CtK2apEH.js → trash-2-CMWvQ5KX.js} +0 -0
- /package/dist/{triangle-alert-KpDVNbpn.js → triangle-alert-DyidRNX_.js} +0 -0
- /package/dist/{useCloudI18n-DOKSZql1.js → useCloudI18n-BTTNBk5i.js} +0 -0
- /package/dist/{x-BkaOMosX.js → x-CgIhNcT9.js} +0 -0
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { At as e, C as t, F as n, Ft as r, M as i, N as a, P as o, S as s, U as c, V as l, W as u, Z as d, _ as f, b as p, d as m, et as h, f as g, g as _, h as v, j as y, jt as b, l as x, m as S, nt as C, st as w, t as T, v as E, x as D, y as O } from "./vue.runtime.esm-bundler-CjauPXjj.js";
|
|
2
2
|
import { t as k } from "./timeouts-BSGxjuUF.js";
|
|
3
|
-
import {
|
|
4
|
-
import { C as
|
|
5
|
-
import { l as
|
|
6
|
-
import { E as
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { a as
|
|
10
|
-
import { t as
|
|
11
|
-
import { t as
|
|
12
|
-
import { t as
|
|
13
|
-
import { t as
|
|
14
|
-
import { t as
|
|
15
|
-
import { t as
|
|
16
|
-
import { t as
|
|
17
|
-
import { t as
|
|
18
|
-
import { t as
|
|
19
|
-
import { n as X } from "./useCloudI18n-
|
|
20
|
-
import { d as Z } from "./styleConstants-
|
|
21
|
-
import { _ as
|
|
22
|
-
var
|
|
3
|
+
import { f as A, j, o as ee, r as M } from "./dist-Bmir0gYb.js";
|
|
4
|
+
import { C as N, F as te, L as P, t as F } from "./useEditorCore-BGnzcT7p.js";
|
|
5
|
+
import { l as I, t as L } from "./dist-CivF9P8b.js";
|
|
6
|
+
import { E as ne, S as R, T as z, c as B, i as re, l as ie, n as ae, u as V, w as oe } from "./keys-CvX8D-8C.js";
|
|
7
|
+
import { t as H } from "./useI18n-C2xQZ6K9.js";
|
|
8
|
+
import { t as se } from "./createLucideIcon-ClREiSx3.js";
|
|
9
|
+
import { a as ce, c as U, d as W, f as le, g as ue, h as G, i as de, l as fe, m as pe, n as me, p as he, r as ge, s as _e, t as ve, u as K } from "./styles-CavWjvol.js";
|
|
10
|
+
import { t as ye } from "./check-DJrpDKO_.js";
|
|
11
|
+
import { t as be } from "./circle-alert-ZQQc98HC.js";
|
|
12
|
+
import { t as xe } from "./clock-ik2pRJKG.js";
|
|
13
|
+
import { t as q } from "./loader-circle-Balo8p3d.js";
|
|
14
|
+
import { t as J } from "./message-circle-B39qAHxs.js";
|
|
15
|
+
import { t as Se } from "./send-DDdhIRj8.js";
|
|
16
|
+
import { t as Y } from "./sparkles-BN4a-CoF.js";
|
|
17
|
+
import { t as Ce } from "./triangle-alert-DyidRNX_.js";
|
|
18
|
+
import { t as we } from "./_plugin-vue_export-helper-Bwh4ceeO.js";
|
|
19
|
+
import { n as X } from "./useCloudI18n-BTTNBk5i.js";
|
|
20
|
+
import { d as Z } from "./styleConstants-wWRbcuEK.js";
|
|
21
|
+
import { _ as Te, a as Q, c as Ee, d as $, f as De, g as Oe, h as ke, l as Ae, m as je, n as Me, o as Ne, p as Pe, r as Fe, s as Ie, t as Le, v as Re, y as ze } from "./cloud-DJG4tb4_.js";
|
|
22
|
+
var Be = se("save", [
|
|
23
23
|
["path", {
|
|
24
24
|
d: "M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",
|
|
25
25
|
key: "1c8476"
|
|
@@ -35,14 +35,14 @@ var ze = ce("save", [
|
|
|
35
35
|
]);
|
|
36
36
|
//#endregion
|
|
37
37
|
//#region src/cloud/composables/useSnapshotPreview.ts
|
|
38
|
-
function
|
|
38
|
+
function Ve(e) {
|
|
39
39
|
let { authManager: t, editor: n, history: r, conditionPreview: i, autoSave: a, onError: o } = e, s = C(null), c = h(null), l = h(null), u = !1;
|
|
40
40
|
d(() => {
|
|
41
41
|
u = !0;
|
|
42
42
|
});
|
|
43
43
|
let f = S(() => c.value !== null), p = S(() => s.value?.snapshots.value ?? []), m = S(() => s.value?.isLoading.value ?? !1), g = S(() => s.value?.isRestoring.value ?? !1);
|
|
44
44
|
function _() {
|
|
45
|
-
n.state.template?.id && !s.value && (s.value =
|
|
45
|
+
n.state.template?.id && !s.value && (s.value = Oe({
|
|
46
46
|
authManager: t,
|
|
47
47
|
templateId: n.state.template.id,
|
|
48
48
|
onRestore: v,
|
|
@@ -92,7 +92,7 @@ function Be(e) {
|
|
|
92
92
|
}
|
|
93
93
|
//#endregion
|
|
94
94
|
//#region src/cloud/composables/useCloudPanelState.ts
|
|
95
|
-
function
|
|
95
|
+
function He() {
|
|
96
96
|
let e = h(null), t = S({
|
|
97
97
|
get: () => e.value === "ai-chat",
|
|
98
98
|
set: (t) => e.value = t ? "ai-chat" : null
|
|
@@ -115,7 +115,7 @@ function Ve() {
|
|
|
115
115
|
function m(t) {
|
|
116
116
|
c.value = !1, e.value = e.value === t ? null : t;
|
|
117
117
|
}
|
|
118
|
-
return
|
|
118
|
+
return L(l, () => {
|
|
119
119
|
c.value = !1;
|
|
120
120
|
}), {
|
|
121
121
|
activePanel: e,
|
|
@@ -137,8 +137,8 @@ function Ve() {
|
|
|
137
137
|
}
|
|
138
138
|
//#endregion
|
|
139
139
|
//#region src/cloud/composables/useCollabUndoWarning.ts
|
|
140
|
-
function
|
|
141
|
-
let { isCollaborationEnabled: t, getCollaboratorCount: n, canUndo: r } = e, i = h(!1), a = h(!1), { start: o } =
|
|
140
|
+
function Ue(e) {
|
|
141
|
+
let { isCollaborationEnabled: t, getCollaboratorCount: n, canUndo: r } = e, i = h(!1), a = h(!1), { start: o } = I(() => {
|
|
142
142
|
a.value = !1;
|
|
143
143
|
}, k, { immediate: !1 });
|
|
144
144
|
function s() {
|
|
@@ -151,8 +151,8 @@ function He(e) {
|
|
|
151
151
|
}
|
|
152
152
|
//#endregion
|
|
153
153
|
//#region src/cloud/composables/useCloudFeatureFlags.ts
|
|
154
|
-
function
|
|
155
|
-
let { planConfigInstance: t, aiConfig: n, editor: r } = e, i = S(() => t.hasFeature("ai_generation") && n.hasAnyMenuFeature.value), a = S(() => t.hasFeature("test_email")), o = S(() => !!r.state.template?.id), s = S(() => t.hasFeature("white_label")), c = S(() => t.config.value?.limits.max_templates ?? null), l = S(() => t.config.value?.template_count ?? 0), u = h(!1), d = h("idle"), f = h(""), { start: p } =
|
|
154
|
+
function We(e) {
|
|
155
|
+
let { planConfigInstance: t, aiConfig: n, editor: r } = e, i = S(() => t.hasFeature("ai_generation") && n.hasAnyMenuFeature.value), a = S(() => t.hasFeature("test_email")), o = S(() => !!r.state.template?.id), s = S(() => t.hasFeature("white_label")), c = S(() => t.config.value?.limits.max_templates ?? null), l = S(() => t.config.value?.template_count ?? 0), u = h(!1), d = h("idle"), f = h(""), { start: p } = I(() => {
|
|
156
156
|
d.value = "idle";
|
|
157
157
|
}, 3e3, { immediate: !1 });
|
|
158
158
|
return {
|
|
@@ -170,7 +170,7 @@ function Ue(e) {
|
|
|
170
170
|
}
|
|
171
171
|
//#endregion
|
|
172
172
|
//#region src/cloud/composables/useCloudMediaLibrary.ts
|
|
173
|
-
function
|
|
173
|
+
function Ge(e) {
|
|
174
174
|
let { onRequestMedia: t, mediaLibraryOpen: n, mediaLibraryAccept: r } = e, i = null;
|
|
175
175
|
async function a() {
|
|
176
176
|
if (t) {
|
|
@@ -205,30 +205,30 @@ function We(e) {
|
|
|
205
205
|
}
|
|
206
206
|
//#endregion
|
|
207
207
|
//#region src/cloud/composables/useCloudInitialization.ts
|
|
208
|
-
function
|
|
209
|
-
let { config: t, translations: n, fontsManager: r, emit: i, getCommentsSidebar: a } = e, s = h(!0), c = h(!1), u = h(null), d = !1, f = { value: null }, p = null, m = null, g = new
|
|
208
|
+
function Ke(e) {
|
|
209
|
+
let { config: t, translations: n, fontsManager: r, emit: i, getCommentsSidebar: a } = e, s = h(!0), c = h(!1), u = h(null), d = !1, f = { value: null }, p = null, m = null, g = new Le({
|
|
210
210
|
...t.auth,
|
|
211
211
|
onError: t.onError
|
|
212
|
-
}), _ =
|
|
212
|
+
}), _ = je({
|
|
213
213
|
authManager: g,
|
|
214
214
|
onError: t.onError
|
|
215
|
-
}), v = h(/* @__PURE__ */ new Map()), y =
|
|
215
|
+
}), v = h(/* @__PURE__ */ new Map()), y = $({
|
|
216
216
|
authManager: g,
|
|
217
217
|
defaultFontFamily: t.fonts?.defaultFont,
|
|
218
218
|
templateDefaults: t.templateDefaults,
|
|
219
219
|
onError: t.onError,
|
|
220
220
|
lockedBlocks: v
|
|
221
|
-
}), b =
|
|
221
|
+
}), b = ze({
|
|
222
222
|
authManager: g,
|
|
223
223
|
onError: t.onError
|
|
224
224
|
});
|
|
225
|
-
t.mcp?.enabled &&
|
|
225
|
+
t.mcp?.enabled && Pe({
|
|
226
226
|
editor: y,
|
|
227
227
|
channel: b.channel,
|
|
228
228
|
onOperation: t.mcp.onOperation
|
|
229
229
|
});
|
|
230
230
|
let x = null;
|
|
231
|
-
t.collaboration?.enabled && (x =
|
|
231
|
+
t.collaboration?.enabled && (x = Ne({
|
|
232
232
|
authManager: g,
|
|
233
233
|
editor: y,
|
|
234
234
|
channel: b.channel,
|
|
@@ -239,8 +239,8 @@ function Ge(e) {
|
|
|
239
239
|
onBlockUnlocked: t.collaboration.onBlockUnlocked
|
|
240
240
|
}), l(() => x.lockedBlocks.value, (e) => {
|
|
241
241
|
v.value = e;
|
|
242
|
-
}, { immediate: !0 }),
|
|
243
|
-
let C = S(() => !!t.collaboration?.enabled && _.hasFeature("collaboration")), w =
|
|
242
|
+
}, { immediate: !0 }), Ie(y, x));
|
|
243
|
+
let C = S(() => !!t.collaboration?.enabled && _.hasFeature("collaboration")), w = F({
|
|
244
244
|
editor: y,
|
|
245
245
|
config: {
|
|
246
246
|
uiTheme: t.uiTheme,
|
|
@@ -251,7 +251,7 @@ function Ge(e) {
|
|
|
251
251
|
displayConditions: t.displayConditions,
|
|
252
252
|
onRequestMedia: null,
|
|
253
253
|
editorType: t.editorType,
|
|
254
|
-
accessibility:
|
|
254
|
+
accessibility: G(t),
|
|
255
255
|
onSave: () => {
|
|
256
256
|
f.value?.().catch((e) => {
|
|
257
257
|
t.onError?.(e);
|
|
@@ -270,13 +270,13 @@ function Ge(e) {
|
|
|
270
270
|
},
|
|
271
271
|
themeExtraStyles: () => ({ "--tpl-drop-text": `"${n.canvas.dropHere}"` }),
|
|
272
272
|
keyboardOptions: { onBeforeUndo: () => m?.showCollabUndoWarning() }
|
|
273
|
-
}), T =
|
|
273
|
+
}), T = Ue({
|
|
274
274
|
isCollaborationEnabled: C,
|
|
275
275
|
getCollaboratorCount: () => x?.collaborators.value.length ?? 0,
|
|
276
276
|
canUndo: w.history.canUndo
|
|
277
277
|
});
|
|
278
278
|
m = T;
|
|
279
|
-
let E =
|
|
279
|
+
let E = Ve({
|
|
280
280
|
authManager: g,
|
|
281
281
|
editor: y,
|
|
282
282
|
history: w.history,
|
|
@@ -285,24 +285,24 @@ function Ge(e) {
|
|
|
285
285
|
onError: t.onError
|
|
286
286
|
});
|
|
287
287
|
p = E;
|
|
288
|
-
let D =
|
|
288
|
+
let D = He(), O = Q(t.ai), k = We({
|
|
289
289
|
planConfigInstance: _,
|
|
290
290
|
aiConfig: O,
|
|
291
291
|
editor: y
|
|
292
|
-
}), A =
|
|
292
|
+
}), A = Ge({
|
|
293
293
|
onRequestMedia: t.onRequestMedia,
|
|
294
294
|
mediaLibraryOpen: D.mediaLibraryOpen,
|
|
295
295
|
mediaLibraryAccept: D.mediaLibraryAccept
|
|
296
296
|
});
|
|
297
|
-
|
|
297
|
+
N({
|
|
298
298
|
onBlockMove: y.moveBlock,
|
|
299
299
|
onBlockAdd: y.addBlock
|
|
300
300
|
});
|
|
301
|
-
let j =
|
|
301
|
+
let j = De({
|
|
302
302
|
authManager: g,
|
|
303
303
|
getFontsConfig: () => t.fonts,
|
|
304
304
|
canUseCustomFonts: () => _.hasFeature("custom_fonts")
|
|
305
|
-
}), ee =
|
|
305
|
+
}), ee = Re({
|
|
306
306
|
authManager: g,
|
|
307
307
|
getTemplateId: () => y.state.template?.id ?? null,
|
|
308
308
|
save: () => y.save(),
|
|
@@ -310,7 +310,7 @@ function Ge(e) {
|
|
|
310
310
|
onError: t.onError,
|
|
311
311
|
isAuthReady: c,
|
|
312
312
|
onBeforeTestEmail: t.onBeforeTestEmail
|
|
313
|
-
}), M =
|
|
313
|
+
}), M = Ae({
|
|
314
314
|
authManager: g,
|
|
315
315
|
getTemplateId: () => y.state.template?.id ?? null,
|
|
316
316
|
getSocketId: () => b.getSocketId(),
|
|
@@ -319,56 +319,56 @@ function Ge(e) {
|
|
|
319
319
|
isAuthReady: c,
|
|
320
320
|
hasCommentingFeature: () => t.commenting !== !1 && _.hasFeature("commenting")
|
|
321
321
|
});
|
|
322
|
-
|
|
322
|
+
Ee({
|
|
323
323
|
comments: M,
|
|
324
324
|
channel: b.channel
|
|
325
325
|
});
|
|
326
|
-
let
|
|
326
|
+
let P = ke({
|
|
327
327
|
authManager: g,
|
|
328
328
|
onError: t.onError
|
|
329
|
-
}),
|
|
329
|
+
}), I = h(!1), L = h(null), ie = h(!1), oe = Te({
|
|
330
330
|
authManager: g,
|
|
331
331
|
getTemplateId: () => y.state.template?.id ?? null
|
|
332
332
|
});
|
|
333
|
-
function
|
|
333
|
+
function H(e) {
|
|
334
334
|
D.commentsOpen.value = !0, queueMicrotask(() => {
|
|
335
335
|
a()?.filterByBlock(e);
|
|
336
336
|
});
|
|
337
337
|
}
|
|
338
|
-
o(
|
|
338
|
+
o(R, A.handleRequestMedia), o(re, g), o(ae, O), o(V, M), o(z, P), o(ne, oe), o(B, {
|
|
339
339
|
plan: _,
|
|
340
340
|
ai: O,
|
|
341
341
|
comments: {
|
|
342
342
|
getBlockCount: (e) => M.commentCountByBlock.value.get(e) ?? 0,
|
|
343
|
-
openForBlock:
|
|
343
|
+
openForBlock: H
|
|
344
344
|
},
|
|
345
345
|
savedModules: {
|
|
346
346
|
openSaveDialog: (e) => {
|
|
347
|
-
|
|
347
|
+
L.value = e ?? null, I.value = !0;
|
|
348
348
|
},
|
|
349
349
|
openBrowser: () => {
|
|
350
|
-
|
|
350
|
+
ie.value = !0;
|
|
351
351
|
},
|
|
352
|
-
moduleCount: S(() =>
|
|
352
|
+
moduleCount: S(() => P.modules.value.length)
|
|
353
353
|
}
|
|
354
354
|
});
|
|
355
|
-
function
|
|
355
|
+
function se(e) {
|
|
356
356
|
_.hasFeature("theme_customization") && (w.themeOverrides.value = e);
|
|
357
357
|
}
|
|
358
|
-
function
|
|
358
|
+
function ce(e) {
|
|
359
359
|
y.setUiTheme(e);
|
|
360
360
|
}
|
|
361
|
-
async function
|
|
361
|
+
async function U() {
|
|
362
362
|
s.value = !0, u.value = null;
|
|
363
363
|
try {
|
|
364
364
|
if (await g.initialize(), d) return;
|
|
365
365
|
c.value = !0;
|
|
366
|
-
let e = await
|
|
366
|
+
let e = await Me({ authManager: g });
|
|
367
367
|
if (d) return;
|
|
368
368
|
if (!e.api.ok) throw Error("Health check failed: API is not reachable");
|
|
369
369
|
if (!e.auth.ok) throw Error(`Health check failed: authentication error${e.auth.error ? ` - ${e.auth.error}` : ""}`);
|
|
370
|
-
if (e.websocket.ok ||
|
|
371
|
-
r.setCustomFontsEnabled(_.hasFeature("custom_fonts")), t.customBlocks?.length && _.hasFeature("custom_blocks") && w.registerCustomBlocks(t.customBlocks), t.theme && _.hasFeature("theme_customization") && (w.themeOverrides.value = t.theme), t.modules !== !1 && _.hasFeature("saved_modules") &&
|
|
370
|
+
if (e.websocket.ok || te.warn("WebSocket health check failed:", e.websocket.error ?? "unknown error", "-- real-time features will be disabled."), await _.fetchConfig(), d) return;
|
|
371
|
+
r.setCustomFontsEnabled(_.hasFeature("custom_fonts")), t.customBlocks?.length && _.hasFeature("custom_blocks") && w.registerCustomBlocks(t.customBlocks), t.theme && _.hasFeature("theme_customization") && (w.themeOverrides.value = t.theme), t.modules !== !1 && _.hasFeature("saved_modules") && P.loadModules(), i("ready");
|
|
372
372
|
} catch (e) {
|
|
373
373
|
if (d) return;
|
|
374
374
|
let n = e instanceof Error ? e : Error("Initialization failed", { cause: e });
|
|
@@ -377,7 +377,7 @@ function Ge(e) {
|
|
|
377
377
|
d || (s.value = !1);
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
|
-
function
|
|
380
|
+
function W() {
|
|
381
381
|
d = !0, r.cleanupFontLinks(), b.disconnect(), w.destroy(), t.onUnmount?.();
|
|
382
382
|
}
|
|
383
383
|
return {
|
|
@@ -398,27 +398,27 @@ function Ge(e) {
|
|
|
398
398
|
exporter: j,
|
|
399
399
|
testEmail: ee,
|
|
400
400
|
commentsInstance: M,
|
|
401
|
-
savedModulesHeadless:
|
|
402
|
-
scoringInstance:
|
|
401
|
+
savedModulesHeadless: P,
|
|
402
|
+
scoringInstance: oe,
|
|
403
403
|
panelState: D,
|
|
404
404
|
snapshotPreview: E,
|
|
405
405
|
collabWarning: T,
|
|
406
|
-
showSaveModuleDialog:
|
|
407
|
-
showModuleBrowserModal:
|
|
408
|
-
saveModulePreSelectedBlockId:
|
|
406
|
+
showSaveModuleDialog: I,
|
|
407
|
+
showModuleBrowserModal: ie,
|
|
408
|
+
saveModulePreSelectedBlockId: L,
|
|
409
409
|
onSaveHook: f,
|
|
410
|
-
initialize:
|
|
411
|
-
destroy:
|
|
412
|
-
setThemeOverrides:
|
|
413
|
-
setUiTheme:
|
|
414
|
-
openCommentsForBlock:
|
|
410
|
+
initialize: U,
|
|
411
|
+
destroy: W,
|
|
412
|
+
setThemeOverrides: se,
|
|
413
|
+
setUiTheme: ce,
|
|
414
|
+
openCommentsForBlock: H
|
|
415
415
|
};
|
|
416
416
|
}
|
|
417
417
|
//#endregion
|
|
418
418
|
//#region src/utils/preRenderCustomBlocks.ts
|
|
419
|
-
async function
|
|
419
|
+
async function qe(e, t) {
|
|
420
420
|
let n = async (e) => {
|
|
421
|
-
if (
|
|
421
|
+
if (j(e)) {
|
|
422
422
|
let n = e;
|
|
423
423
|
try {
|
|
424
424
|
n.renderedHtml = await t.renderCustomBlock(n);
|
|
@@ -435,10 +435,10 @@ async function Ke(e, t) {
|
|
|
435
435
|
}
|
|
436
436
|
//#endregion
|
|
437
437
|
//#region src/cloud/composables/useCloudLifecycle.ts
|
|
438
|
-
function
|
|
438
|
+
function Je(e) {
|
|
439
439
|
let { config: t, editor: n, websocket: r, planConfigInstance: i, snapshotPreview: a, core: o, exporter: s, featureFlags: c, isDestroyed: l } = e;
|
|
440
440
|
function u() {
|
|
441
|
-
return
|
|
441
|
+
return Fe(i.config.value.websocket);
|
|
442
442
|
}
|
|
443
443
|
async function d(e) {
|
|
444
444
|
let i = await n.create(e);
|
|
@@ -451,7 +451,7 @@ function qe(e) {
|
|
|
451
451
|
async function p() {
|
|
452
452
|
c.isSaveExporting.value = !0, c.saveStatus.value = "idle";
|
|
453
453
|
try {
|
|
454
|
-
if (await
|
|
454
|
+
if (await qe(n.content.value, o.registry), l()) throw Error("Component unmounted during save");
|
|
455
455
|
let e = await n.save();
|
|
456
456
|
if (l()) throw Error("Component unmounted during save");
|
|
457
457
|
a.initSnapshotHistory(), a.snapshotHistoryInstance.value?.loadSnapshots();
|
|
@@ -478,7 +478,7 @@ function qe(e) {
|
|
|
478
478
|
}
|
|
479
479
|
//#endregion
|
|
480
480
|
//#region src/cloud/composables/useCloudSaveGate.ts
|
|
481
|
-
function
|
|
481
|
+
function Ye(e) {
|
|
482
482
|
let t = h(!1), n = null, r = S(() => e.planConfig.value?.accessibility?.blockOnError === !0), i = S(() => r.value ? e.issues.value.filter((e) => e.severity === "error") : []), a = S(() => i.value.length > 0);
|
|
483
483
|
async function o(e) {
|
|
484
484
|
return a.value ? (n = e, t.value = !0, !1) : (await e(), !0);
|
|
@@ -501,7 +501,7 @@ function Je(e) {
|
|
|
501
501
|
}
|
|
502
502
|
//#endregion
|
|
503
503
|
//#region src/cloud/components/CloudSaveGateModal.vue?vue&type=script&setup=true&lang.ts
|
|
504
|
-
var
|
|
504
|
+
var Xe = ["aria-label"], Ze = { 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)]" }, Qe = { class: "tpl:flex tpl:items-center tpl:gap-2" }, $e = { class: "tpl:m-0 tpl:text-base tpl:font-semibold tpl:text-[var(--tpl-text)]" }, et = { class: "tpl:m-0 tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, tt = { 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" }, nt = { class: "tpl:text-xs tpl:text-[var(--tpl-text)]" }, rt = { class: "tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-dim)]" }, it = { class: "tpl:flex tpl:justify-end tpl:gap-2" }, at = /* @__PURE__ */ t({
|
|
505
505
|
__name: "CloudSaveGateModal",
|
|
506
506
|
props: {
|
|
507
507
|
open: { type: Boolean },
|
|
@@ -523,18 +523,18 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
523
523
|
"aria-label": w(o).saveGate.title,
|
|
524
524
|
class: "tpl:fixed tpl:inset-0 tpl:z-50 tpl:flex tpl:items-center tpl:justify-center tpl:bg-black/40 tpl:p-6",
|
|
525
525
|
onClick: s[2] ||= m((e) => i("cancel"), ["self"])
|
|
526
|
-
}, [v("div",
|
|
527
|
-
v("header",
|
|
526
|
+
}, [v("div", Ze, [
|
|
527
|
+
v("header", Qe, [D(w(Ce), {
|
|
528
528
|
size: 18,
|
|
529
529
|
"stroke-width": 2,
|
|
530
530
|
class: "tpl:text-[var(--tpl-warning)]"
|
|
531
|
-
}), v("h2",
|
|
532
|
-
v("p",
|
|
533
|
-
v("ul",
|
|
531
|
+
}), v("h2", $e, r(w(o).saveGate.title), 1)]),
|
|
532
|
+
v("p", et, r(w(o).saveGate.body), 1),
|
|
533
|
+
v("ul", tt, [(a(!0), E(g, null, n(e.issues, (e) => (a(), E("li", {
|
|
534
534
|
key: `${e.ruleId}-${e.blockId ?? "template"}`,
|
|
535
535
|
class: "tpl:flex tpl:flex-col tpl:gap-0.5 tpl:rounded tpl:px-2 tpl:py-1.5"
|
|
536
|
-
}, [v("span",
|
|
537
|
-
v("footer",
|
|
536
|
+
}, [v("span", nt, r(e.message), 1), v("span", rt, r(e.ruleId), 1)]))), 128))]),
|
|
537
|
+
v("footer", it, [v("button", {
|
|
538
538
|
type: "button",
|
|
539
539
|
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)]",
|
|
540
540
|
onClick: s[0] ||= (e) => i("cancel")
|
|
@@ -543,11 +543,11 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
543
543
|
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",
|
|
544
544
|
onClick: s[1] ||= (e) => i("confirm")
|
|
545
545
|
}, r(w(o).saveGate.confirm), 1)])
|
|
546
|
-
])], 8,
|
|
546
|
+
])], 8, Xe)) : f("", !0)]),
|
|
547
547
|
_: 1
|
|
548
548
|
}));
|
|
549
549
|
}
|
|
550
|
-
}),
|
|
550
|
+
}), ot = {
|
|
551
551
|
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",
|
|
552
552
|
style: {
|
|
553
553
|
"background-color": "color-mix(in srgb, var(--tpl-bg) 80%, transparent)",
|
|
@@ -556,28 +556,28 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
556
556
|
"box-shadow": "var(--tpl-shadow-md)",
|
|
557
557
|
"border-bottom": "1px solid var(--tpl-border)"
|
|
558
558
|
}
|
|
559
|
-
},
|
|
559
|
+
}, st = { class: "tpl-header-left tpl:flex tpl:min-w-[200px] tpl:items-center tpl:gap-3" }, ct = {
|
|
560
560
|
key: 0,
|
|
561
561
|
class: "tpl:text-xs tpl:opacity-60 tpl:text-[var(--tpl-text-muted)]"
|
|
562
|
-
},
|
|
562
|
+
}, lt = { class: "tpl-header-center tpl:flex tpl:items-center tpl:justify-center tpl:gap-10" }, ut = { class: "tpl-header-right tpl:flex tpl:min-w-[200px] tpl:items-center tpl:justify-end tpl:gap-3" }, dt = ["data-tooltip"], ft = {
|
|
563
563
|
key: 1,
|
|
564
564
|
"aria-live": "polite",
|
|
565
565
|
class: "tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-success)]"
|
|
566
|
-
},
|
|
566
|
+
}, pt = {
|
|
567
567
|
key: 2,
|
|
568
568
|
"aria-live": "polite",
|
|
569
569
|
class: "tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
570
|
-
},
|
|
570
|
+
}, mt = ["aria-label", "aria-expanded"], ht = {
|
|
571
571
|
key: 0,
|
|
572
572
|
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)]"
|
|
573
|
-
},
|
|
573
|
+
}, gt = ["aria-expanded"], _t = {
|
|
574
574
|
key: 0,
|
|
575
575
|
class: "tpl:absolute tpl:right-0 tpl:top-full tpl:z-50 tpl:mt-1 tpl:origin-top-right"
|
|
576
|
-
},
|
|
576
|
+
}, vt = ["disabled"], yt = ["disabled"], bt = /* @__PURE__ */ t({
|
|
577
577
|
__name: "CloudHeader",
|
|
578
578
|
props: {
|
|
579
579
|
editor: {},
|
|
580
|
-
|
|
580
|
+
onBeforeHistoryUndo: { type: Function },
|
|
581
581
|
featureFlags: {},
|
|
582
582
|
panelState: {},
|
|
583
583
|
snapshotPreview: {},
|
|
@@ -591,22 +591,23 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
591
591
|
},
|
|
592
592
|
emits: ["save"],
|
|
593
593
|
setup(t) {
|
|
594
|
-
let n = s(() => import("./CollaboratorBar-
|
|
595
|
-
return (s, d) => (a(), E("header",
|
|
596
|
-
v("div",
|
|
594
|
+
let n = s(() => import("./CollaboratorBar-BsXMY-8e.js")), i = s(() => import("./SnapshotHistory-DoqtH0cw.js")), o = s(() => import("./AiFeatureMenu-DoLD5Cde.js")), { t: l, format: u } = X();
|
|
595
|
+
return (s, d) => (a(), E("header", ot, [
|
|
596
|
+
v("div", st, [t.featureFlags.templateLimit.value === null ? f("", !0) : (a(), E("span", ct, r(w(u)(w(l).header.templatesUsed, {
|
|
597
597
|
used: t.featureFlags.templateCount.value,
|
|
598
598
|
max: t.featureFlags.templateLimit.value
|
|
599
599
|
})), 1))]),
|
|
600
|
-
v("div",
|
|
601
|
-
D(W, {
|
|
600
|
+
v("div", lt, [
|
|
601
|
+
D(W, { "on-before-undo": t.onBeforeHistoryUndo }, null, 8, ["on-before-undo"]),
|
|
602
|
+
D(K, {
|
|
602
603
|
viewport: t.editor.state.viewport,
|
|
603
604
|
onChange: t.editor.setViewport
|
|
604
605
|
}, null, 8, ["viewport", "onChange"]),
|
|
605
|
-
D(
|
|
606
|
+
D(U, {
|
|
606
607
|
"dark-mode": t.editor.state.darkMode,
|
|
607
608
|
onChange: t.editor.setDarkMode
|
|
608
609
|
}, null, 8, ["dark-mode", "onChange"]),
|
|
609
|
-
D(
|
|
610
|
+
D(fe, {
|
|
610
611
|
"preview-mode": t.editor.state.previewMode,
|
|
611
612
|
onChange: t.editor.setPreviewMode
|
|
612
613
|
}, null, 8, ["preview-mode", "onChange"]),
|
|
@@ -630,19 +631,19 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
630
631
|
"onNavigate"
|
|
631
632
|
])) : f("", !0)
|
|
632
633
|
]),
|
|
633
|
-
v("div",
|
|
634
|
+
v("div", ut, [
|
|
634
635
|
t.featureFlags.saveStatus.value === "error" ? (a(), E("div", {
|
|
635
636
|
key: 0,
|
|
636
637
|
"aria-live": "assertive",
|
|
637
638
|
class: "tpl-tooltip tpl-status tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-danger)]",
|
|
638
639
|
"data-tooltip": t.featureFlags.saveErrorMessage.value
|
|
639
|
-
}, [D(w(
|
|
640
|
+
}, [D(w(be), {
|
|
640
641
|
size: 12,
|
|
641
642
|
"stroke-width": 2.5
|
|
642
|
-
}), p(" " + r(w(l).header.saveFailed), 1)], 8,
|
|
643
|
+
}), p(" " + r(w(l).header.saveFailed), 1)], 8, dt)) : t.featureFlags.saveStatus.value === "saved" ? (a(), E("div", ft, [D(w(ye), {
|
|
643
644
|
size: 12,
|
|
644
645
|
"stroke-width": 2.5
|
|
645
|
-
}), p(" " + r(w(l).header.saved), 1)])) : t.editor.state.isDirty ? (a(), E("div",
|
|
646
|
+
}), p(" " + r(w(l).header.saved), 1)])) : t.editor.state.isDirty ? (a(), E("div", pt, [d[4] ||= v("span", { class: "tpl-pulse tpl:size-1.5 tpl:rounded-full tpl:bg-[var(--tpl-primary)]" }, null, -1), p(" " + r(w(l).header.unsaved), 1)])) : f("", !0),
|
|
646
647
|
t.commentsInstance.isEnabled.value && t.featureFlags.hasTemplateSaved.value ? (a(), E("button", {
|
|
647
648
|
key: 3,
|
|
648
649
|
"aria-label": t.commentsInstance.unresolvedCount.value > 0 ? `${w(l).comments.button} (${t.commentsInstance.unresolvedCount.value})` : w(l).comments.button,
|
|
@@ -655,13 +656,13 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
655
656
|
}),
|
|
656
657
|
onClick: d[0] ||= (e) => t.panelState.commentsOpen.value = !t.panelState.commentsOpen.value
|
|
657
658
|
}, [
|
|
658
|
-
D(w(
|
|
659
|
+
D(w(J), {
|
|
659
660
|
size: 16,
|
|
660
661
|
"stroke-width": 2
|
|
661
662
|
}),
|
|
662
663
|
p(" " + r(w(l).comments.button) + " ", 1),
|
|
663
|
-
t.commentsInstance.unresolvedCount.value > 0 && !t.panelState.commentsOpen.value ? (a(), E("span",
|
|
664
|
-
], 14,
|
|
664
|
+
t.commentsInstance.unresolvedCount.value > 0 && !t.panelState.commentsOpen.value ? (a(), E("span", ht, r(t.commentsInstance.unresolvedCount.value), 1)) : f("", !0)
|
|
665
|
+
], 14, mt)) : f("", !0),
|
|
665
666
|
t.featureFlags.canUseAiGeneration.value && t.featureFlags.hasTemplateSaved.value ? (a(), E("div", {
|
|
666
667
|
key: 4,
|
|
667
668
|
ref: (e) => t.panelState.aiMenuRef.value = e,
|
|
@@ -670,11 +671,11 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
670
671
|
"aria-expanded": t.panelState.aiMenuOpen.value,
|
|
671
672
|
class: e(["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", t.panelState.aiButtonActive.value ? "tpl-ai-btn--active" : "tpl-ai-btn--idle"]),
|
|
672
673
|
onClick: d[1] ||= m((...e) => t.panelState.toggleAiMenu && t.panelState.toggleAiMenu(...e), ["stop"])
|
|
673
|
-
}, [D(w(
|
|
674
|
+
}, [D(w(Y), {
|
|
674
675
|
size: 16,
|
|
675
676
|
"stroke-width": 2,
|
|
676
677
|
class: "tpl-ai-btn-icon"
|
|
677
|
-
}), p(" " + r(w(l).aiChat.button), 1)], 10,
|
|
678
|
+
}), p(" " + r(w(l).aiChat.button), 1)], 10, gt), D(T, {
|
|
678
679
|
"enter-active-class": "tpl:transition-all tpl:duration-150 tpl:ease-out",
|
|
679
680
|
"enter-from-class": "tpl:scale-95 tpl:opacity-0",
|
|
680
681
|
"enter-to-class": "tpl:scale-100 tpl:opacity-100",
|
|
@@ -682,7 +683,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
682
683
|
"leave-from-class": "tpl:scale-100 tpl:opacity-100",
|
|
683
684
|
"leave-to-class": "tpl:scale-95 tpl:opacity-0"
|
|
684
685
|
}, {
|
|
685
|
-
default: c(() => [t.panelState.aiMenuOpen.value ? (a(), E("div",
|
|
686
|
+
default: c(() => [t.panelState.aiMenuOpen.value ? (a(), E("div", _t, [D(w(o), {
|
|
686
687
|
"active-feature": t.panelState.activeAiFeature.value,
|
|
687
688
|
onSelect: t.panelState.handleAiFeatureSelect
|
|
688
689
|
}, null, 8, ["active-feature", "onSelect"])])) : f("", !0)]),
|
|
@@ -698,16 +699,16 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
698
699
|
},
|
|
699
700
|
disabled: t.testEmail.isSending.value || !t.featureFlags.hasTemplateSaved.value,
|
|
700
701
|
onClick: d[2] ||= (e) => t.panelState.testEmailModalOpen.value = !0
|
|
701
|
-
}, [t.testEmail.isSending.value ? (a(), _(w(
|
|
702
|
+
}, [t.testEmail.isSending.value ? (a(), _(w(q), {
|
|
702
703
|
key: 1,
|
|
703
704
|
class: "tpl-spinner",
|
|
704
705
|
size: 16,
|
|
705
706
|
"stroke-width": 2
|
|
706
|
-
})) : (a(), _(w(
|
|
707
|
+
})) : (a(), _(w(Se), {
|
|
707
708
|
key: 0,
|
|
708
709
|
size: 16,
|
|
709
710
|
"stroke-width": 2
|
|
710
|
-
})), p(" " + r(w(l).testEmail.button), 1)], 10,
|
|
711
|
+
})), p(" " + r(w(l).testEmail.button), 1)], 10, vt)) : f("", !0),
|
|
711
712
|
v("button", {
|
|
712
713
|
class: e(w(Z)),
|
|
713
714
|
style: {
|
|
@@ -717,20 +718,20 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
717
718
|
},
|
|
718
719
|
disabled: t.isSaveDisabled,
|
|
719
720
|
onClick: d[3] ||= (e) => s.$emit("save")
|
|
720
|
-
}, [t.isSaving ? (a(), _(w(
|
|
721
|
+
}, [t.isSaving ? (a(), _(w(q), {
|
|
721
722
|
key: 1,
|
|
722
723
|
class: "tpl-spinner",
|
|
723
724
|
size: 16,
|
|
724
725
|
"stroke-width": 2
|
|
725
|
-
})) : (a(), _(w(
|
|
726
|
+
})) : (a(), _(w(Be), {
|
|
726
727
|
key: 0,
|
|
727
728
|
size: 16,
|
|
728
729
|
"stroke-width": 2
|
|
729
|
-
})), p(" " + r(t.isSaving ? w(l).header.saving : w(l).header.save), 1)], 10,
|
|
730
|
+
})), p(" " + r(t.isSaving ? w(l).header.saving : w(l).header.save), 1)], 10, yt)
|
|
730
731
|
])
|
|
731
732
|
]));
|
|
732
733
|
}
|
|
733
|
-
}),
|
|
734
|
+
}), xt = /* @__PURE__ */ t({
|
|
734
735
|
__name: "CloudPanels",
|
|
735
736
|
props: {
|
|
736
737
|
config: {},
|
|
@@ -753,7 +754,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
753
754
|
"module-insert"
|
|
754
755
|
],
|
|
755
756
|
setup(e, { expose: t, emit: n }) {
|
|
756
|
-
let r = s(() => import("./AiChatSidebar-
|
|
757
|
+
let r = s(() => import("./AiChatSidebar-DeB0w_32.js")), i = s(() => import("./CommentsSidebar-DIWIa4rS.js")), o = s(() => import("./DesignReferenceSidebar-RDlnhL-6.js")), c = s(() => import("./TemplateScoringPanel-DQv2ZAiL.js")), l = s(() => import("./TestEmailModal-iIeYJYsj.js")), u = s(() => import("./SaveModuleDialog-ClovqI6h.js")), d = s(() => import("./ModuleBrowserModal-b7HbpByz.js")), p = s(async () => (await import("@aswin.dev/media-library")).MediaLibraryModal), m = n;
|
|
757
758
|
function v(e, t, n) {
|
|
758
759
|
t.history.record(), n.setContent(e), t.conditionPreview.reset();
|
|
759
760
|
}
|
|
@@ -827,23 +828,23 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
827
828
|
])
|
|
828
829
|
], 64));
|
|
829
830
|
}
|
|
830
|
-
}),
|
|
831
|
+
}), St = {
|
|
831
832
|
key: 0,
|
|
832
833
|
class: "tpl-loading tpl:absolute tpl:inset-0 tpl:z-overlay tpl:flex tpl:flex-col tpl:bg-[var(--tpl-bg)]"
|
|
833
|
-
},
|
|
834
|
+
}, Ct = { class: "tpl:flex tpl:flex-1 tpl:overflow-hidden" }, wt = { 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)]" }, Tt = /* @__PURE__ */ t({
|
|
834
835
|
__name: "CloudLoadingOverlay",
|
|
835
836
|
props: { visible: { type: Boolean } },
|
|
836
837
|
setup(e) {
|
|
837
|
-
return (t, r) => e.visible ? (a(), E("div",
|
|
838
|
+
return (t, r) => e.visible ? (a(), E("div", St, [r[1] ||= O("<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), v("div", Ct, [v("div", wt, [(a(), E(g, null, n(5, (e) => v("div", {
|
|
838
839
|
key: e,
|
|
839
840
|
class: "tpl-shimmer tpl:size-7 tpl:rounded-[var(--tpl-radius-sm)]"
|
|
840
841
|
})), 64))]), r[0] ||= O("<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)])])) : f("", !0);
|
|
841
842
|
}
|
|
842
|
-
}),
|
|
843
|
+
}), Et = {
|
|
843
844
|
key: 0,
|
|
844
845
|
role: "alert",
|
|
845
846
|
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)]"
|
|
846
|
-
},
|
|
847
|
+
}, Dt = { class: "tpl:flex tpl:size-16 tpl:items-center tpl:justify-center tpl:rounded-full tpl:bg-[var(--tpl-danger-light)]" }, Ot = { class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-2 tpl:text-center" }, kt = { class: "tpl:text-lg tpl:font-semibold tpl:text-[var(--tpl-text)]" }, At = { class: "tpl:max-w-md tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, jt = /* @__PURE__ */ t({
|
|
847
848
|
__name: "CloudErrorOverlay",
|
|
848
849
|
props: {
|
|
849
850
|
error: {},
|
|
@@ -858,13 +859,13 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
858
859
|
function s(e) {
|
|
859
860
|
return "isNotFound" in e && !!e.isNotFound;
|
|
860
861
|
}
|
|
861
|
-
return (t, c) => e.visible && e.error ? (a(), E("div",
|
|
862
|
-
v("div",
|
|
862
|
+
return (t, c) => e.visible && e.error ? (a(), E("div", Et, [
|
|
863
|
+
v("div", Dt, [D(w(be), {
|
|
863
864
|
size: 32,
|
|
864
865
|
"stroke-width": 1.5,
|
|
865
866
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
866
867
|
})]),
|
|
867
|
-
v("div",
|
|
868
|
+
v("div", Ot, [v("h2", kt, r(w(i).error.title), 1), v("p", At, r(o(e.error)), 1)]),
|
|
868
869
|
s(e.error) ? f("", !0) : (a(), E("button", {
|
|
869
870
|
key: 0,
|
|
870
871
|
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)]",
|
|
@@ -872,20 +873,20 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
872
873
|
}, r(w(i).error.retry), 1))
|
|
873
874
|
])) : f("", !0);
|
|
874
875
|
}
|
|
875
|
-
}),
|
|
876
|
+
}), Mt = {
|
|
876
877
|
key: 0,
|
|
877
878
|
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)]"
|
|
878
|
-
},
|
|
879
|
+
}, Nt = { class: "tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:text-[var(--tpl-text)]" }, Pt = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ft = /* @__PURE__ */ t({
|
|
879
880
|
__name: "SnapshotPreviewBanner",
|
|
880
881
|
props: { visible: { type: Boolean } },
|
|
881
882
|
emits: ["cancel", "confirm"],
|
|
882
883
|
setup(e, { emit: t }) {
|
|
883
884
|
let n = t, { t: i } = X();
|
|
884
|
-
return (t, o) => e.visible ? (a(), E("div",
|
|
885
|
+
return (t, o) => e.visible ? (a(), E("div", Mt, [v("div", Nt, [D(w(xe), {
|
|
885
886
|
size: 18,
|
|
886
887
|
"stroke-width": 2,
|
|
887
888
|
class: "tpl:text-[var(--tpl-primary)]"
|
|
888
|
-
}), v("span", null, r(w(i).snapshotPreview.message), 1)]), v("div",
|
|
889
|
+
}), v("span", null, r(w(i).snapshotPreview.message), 1)]), v("div", Pt, [v("button", {
|
|
889
890
|
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)]",
|
|
890
891
|
style: { "background-color": "transparent" },
|
|
891
892
|
onClick: o[0] ||= (e) => n("cancel")
|
|
@@ -894,7 +895,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
894
895
|
onClick: o[1] ||= (e) => n("confirm")
|
|
895
896
|
}, r(w(i).snapshotPreview.restore), 1)])])) : f("", !0);
|
|
896
897
|
}
|
|
897
|
-
}),
|
|
898
|
+
}), It = {
|
|
898
899
|
key: 0,
|
|
899
900
|
role: "status",
|
|
900
901
|
"aria-live": "polite",
|
|
@@ -904,14 +905,14 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
904
905
|
color: "var(--tpl-text)",
|
|
905
906
|
border: "1px solid var(--tpl-warning)"
|
|
906
907
|
}
|
|
907
|
-
},
|
|
908
|
+
}, Lt = /* @__PURE__ */ t({
|
|
908
909
|
__name: "CollabUndoToast",
|
|
909
910
|
props: { visible: { type: Boolean } },
|
|
910
911
|
setup(e) {
|
|
911
|
-
let { t } =
|
|
912
|
-
return (n, i) => e.visible ? (a(), E("div",
|
|
912
|
+
let { t } = H();
|
|
913
|
+
return (n, i) => e.visible ? (a(), E("div", It, r(w(t).history.collabWarning), 1)) : f("", !0);
|
|
913
914
|
}
|
|
914
|
-
}),
|
|
915
|
+
}), Rt = ["data-tpl-theme"], zt = { class: "tpl:sticky tpl:top-0 tpl:z-40 tpl:h-0" }, Bt = { class: "tpl-main tpl:flex tpl:justify-center tpl:p-8" }, Vt = ["aria-label"], Ht = /* @__PURE__ */ we(/* @__PURE__ */ t({
|
|
915
916
|
__name: "CloudEditor",
|
|
916
917
|
props: {
|
|
917
918
|
config: {},
|
|
@@ -922,57 +923,57 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
922
923
|
emits: ["ready"],
|
|
923
924
|
setup(t, { expose: n, emit: s }) {
|
|
924
925
|
let d = t;
|
|
925
|
-
o(
|
|
926
|
-
let m = s, C = h(null), O = h(null), k =
|
|
926
|
+
o(ie, d.cloudTranslations);
|
|
927
|
+
let m = s, C = h(null), O = h(null), k = Ke({
|
|
927
928
|
config: d.config,
|
|
928
929
|
translations: d.translations,
|
|
929
930
|
fontsManager: d.fontsManager,
|
|
930
931
|
emit: m,
|
|
931
932
|
getCommentsSidebar: () => C.value ? { filterByBlock: C.value.filterCommentsByBlock } : null
|
|
932
|
-
}), { isInitializing:
|
|
933
|
-
o(
|
|
934
|
-
let J = S(() =>
|
|
935
|
-
l(() => [
|
|
936
|
-
if (!e || !J.value ||
|
|
937
|
-
let t =
|
|
938
|
-
|
|
933
|
+
}), { isInitializing: j, isAuthReady: N, initError: te, planConfigInstance: F, websocket: I, collaboration: L, isCollaborationEnabled: ne, editor: R, core: z, featureFlags: B, mediaLib: re, exporter: ae, testEmail: V, commentsInstance: H, savedModulesHeadless: se, panelState: U, snapshotPreview: W, collabWarning: G, showSaveModuleDialog: fe, showModuleBrowserModal: K, saveModulePreSelectedBlockId: ye, setThemeOverrides: be, setUiTheme: xe } = k, q = h("blocks");
|
|
934
|
+
o(oe, q);
|
|
935
|
+
let J = S(() => P(d.config.editorType) === "popup"), Se = S(() => J.value && q.value === "displayRules"), Y = S(() => J.value && q.value === "schedule"), Ce = S(() => q.value === "design"), we = S(() => J.value && (Se.value || Y.value || Ce.value)), X = S(() => Se.value || Y.value);
|
|
936
|
+
l(() => [N.value, R.content.value.settings.popup], ([e]) => {
|
|
937
|
+
if (!e || !J.value || R.content.value.settings.popup) return;
|
|
938
|
+
let t = A();
|
|
939
|
+
R.updateSettings({
|
|
939
940
|
popup: t,
|
|
940
941
|
width: M[t.design.sizePreset]
|
|
941
942
|
});
|
|
942
943
|
}, { immediate: !0 });
|
|
943
|
-
async function
|
|
944
|
+
async function Z(e) {
|
|
944
945
|
try {
|
|
945
|
-
await
|
|
946
|
+
await V.sendTestEmail(e), U.testEmailModalOpen.value = !1;
|
|
946
947
|
} catch {}
|
|
947
948
|
}
|
|
948
949
|
function Te(e, t) {
|
|
949
950
|
for (let n = 0; n < e.content.length; n++) {
|
|
950
951
|
let r = ee(e.content[n]), i = t === void 0 ? void 0 : t + n;
|
|
951
|
-
|
|
952
|
+
R.addBlock(r, void 0, void 0, i);
|
|
952
953
|
}
|
|
953
|
-
|
|
954
|
+
K.value = !1;
|
|
954
955
|
}
|
|
955
|
-
let Q =
|
|
956
|
+
let Q = Je({
|
|
956
957
|
config: d.config,
|
|
957
|
-
editor:
|
|
958
|
-
websocket:
|
|
959
|
-
planConfigInstance:
|
|
960
|
-
snapshotPreview:
|
|
961
|
-
core:
|
|
962
|
-
exporter:
|
|
963
|
-
featureFlags:
|
|
958
|
+
editor: R,
|
|
959
|
+
websocket: I,
|
|
960
|
+
planConfigInstance: F,
|
|
961
|
+
snapshotPreview: W,
|
|
962
|
+
core: z,
|
|
963
|
+
exporter: ae,
|
|
964
|
+
featureFlags: B,
|
|
964
965
|
isDestroyed: k.isDestroyed
|
|
965
966
|
}), Ee = S(() => {
|
|
966
|
-
if (
|
|
967
|
-
let e =
|
|
967
|
+
if (R.state.previewMode) return ["tpl:left-0", "tpl:right-0"];
|
|
968
|
+
let e = U.rightPanelOpen.value ? "tpl:right-[680px]" : "tpl:right-[320px]";
|
|
968
969
|
if (!J.value) return ["tpl:left-12", e];
|
|
969
970
|
let t;
|
|
970
971
|
t = q.value === "blocks" ? "tpl:left-[272px]" : Ce.value ? "tpl:left-[392px]" : "tpl:left-[72px]";
|
|
971
|
-
let n =
|
|
972
|
+
let n = we.value ? "tpl:right-0" : e;
|
|
972
973
|
return [t, n];
|
|
973
|
-
}), $ =
|
|
974
|
-
issues:
|
|
975
|
-
planConfig:
|
|
974
|
+
}), $ = Ye({
|
|
975
|
+
issues: z.accessibilityLint ? z.accessibilityLint.issues : h([]),
|
|
976
|
+
planConfig: F.config
|
|
976
977
|
});
|
|
977
978
|
async function De() {
|
|
978
979
|
await $.tryRunSave(() => Q.saveTemplate().catch((e) => d.config.onError?.(e)));
|
|
@@ -982,22 +983,28 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
982
983
|
}), i(() => {
|
|
983
984
|
k.destroy();
|
|
984
985
|
}), n({
|
|
985
|
-
getContent: () =>
|
|
986
|
-
setContent: (e) =>
|
|
986
|
+
getContent: () => R.content.value,
|
|
987
|
+
setContent: (e) => R.setContent(e),
|
|
987
988
|
setTheme: xe,
|
|
988
989
|
setThemeOverrides: be,
|
|
990
|
+
undo: () => {
|
|
991
|
+
G.showCollabUndoWarning(), z.history.undo();
|
|
992
|
+
},
|
|
993
|
+
redo: () => z.history.redo(),
|
|
994
|
+
canUndo: () => z.history.canUndo.value,
|
|
995
|
+
canRedo: () => z.history.canRedo.value,
|
|
989
996
|
create: Q.createTemplate,
|
|
990
997
|
load: Q.loadTemplate,
|
|
991
998
|
save: Q.saveTemplate,
|
|
992
|
-
sendTestEmail:
|
|
999
|
+
sendTestEmail: V.sendTestEmail,
|
|
993
1000
|
startTour: (e) => O.value?.start(e),
|
|
994
1001
|
dismissTour: () => O.value?.dismiss(),
|
|
995
|
-
resetTourDismissed: () =>
|
|
996
|
-
isTourDismissed: () => d.config.tour ?
|
|
1002
|
+
resetTourDismissed: () => de(d.config.tour),
|
|
1003
|
+
isTourDismissed: () => d.config.tour ? ce(d.config.tour) : !0
|
|
997
1004
|
}), (n, i) => (a(), E("div", {
|
|
998
|
-
class: e(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": w(
|
|
999
|
-
"data-tpl-theme": w(
|
|
1000
|
-
style: b(w(
|
|
1005
|
+
class: e(["tpl tpl:relative tpl:h-full tpl:overflow-hidden", { "tpl:dark": w(R).state.darkMode }]),
|
|
1006
|
+
"data-tpl-theme": w(z).resolvedTheme.value,
|
|
1007
|
+
style: b(w(z).themeStyles.value)
|
|
1001
1008
|
}, [
|
|
1002
1009
|
D(T, {
|
|
1003
1010
|
"enter-active-class": "tpl:transition-opacity tpl:duration-200",
|
|
@@ -1007,7 +1014,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1007
1014
|
"leave-from-class": "tpl:opacity-100",
|
|
1008
1015
|
"leave-to-class": "tpl:opacity-0"
|
|
1009
1016
|
}, {
|
|
1010
|
-
default: c(() => [D(
|
|
1017
|
+
default: c(() => [D(Tt, { visible: w(j) || w(R).state.isLoading }, null, 8, ["visible"])]),
|
|
1011
1018
|
_: 1
|
|
1012
1019
|
}),
|
|
1013
1020
|
D(T, {
|
|
@@ -1018,9 +1025,9 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1018
1025
|
"leave-from-class": "tpl:opacity-100",
|
|
1019
1026
|
"leave-to-class": "tpl:opacity-0"
|
|
1020
1027
|
}, {
|
|
1021
|
-
default: c(() => [D(
|
|
1022
|
-
error: w(
|
|
1023
|
-
visible: !!w(
|
|
1028
|
+
default: c(() => [D(jt, {
|
|
1029
|
+
error: w(te),
|
|
1030
|
+
visible: !!w(te) && !w(j),
|
|
1024
1031
|
onRetry: w(k).initialize
|
|
1025
1032
|
}, null, 8, [
|
|
1026
1033
|
"error",
|
|
@@ -1029,23 +1036,23 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1029
1036
|
])]),
|
|
1030
1037
|
_: 1
|
|
1031
1038
|
}),
|
|
1032
|
-
D(
|
|
1033
|
-
editor: w(
|
|
1034
|
-
|
|
1035
|
-
"feature-flags": w(
|
|
1036
|
-
"panel-state": w(
|
|
1037
|
-
"snapshot-preview": w(
|
|
1038
|
-
"comments-instance": w(
|
|
1039
|
-
"test-email": w(
|
|
1040
|
-
websocket: w(
|
|
1041
|
-
collaboration: w(
|
|
1042
|
-
"is-collaboration-enabled": w(
|
|
1043
|
-
"is-saving": w(
|
|
1044
|
-
"is-save-disabled": w(
|
|
1039
|
+
D(bt, {
|
|
1040
|
+
editor: w(R),
|
|
1041
|
+
"on-before-history-undo": w(G).showCollabUndoWarning,
|
|
1042
|
+
"feature-flags": w(B),
|
|
1043
|
+
"panel-state": w(U),
|
|
1044
|
+
"snapshot-preview": w(W),
|
|
1045
|
+
"comments-instance": w(H),
|
|
1046
|
+
"test-email": w(V),
|
|
1047
|
+
websocket: w(I),
|
|
1048
|
+
collaboration: w(L),
|
|
1049
|
+
"is-collaboration-enabled": w(ne),
|
|
1050
|
+
"is-saving": w(R).state.isSaving || w(B).isSaveExporting.value,
|
|
1051
|
+
"is-save-disabled": w(R).state.isSaving || w(B).isSaveExporting.value || !w(R).state.isDirty,
|
|
1045
1052
|
onSave: De
|
|
1046
1053
|
}, null, 8, [
|
|
1047
1054
|
"editor",
|
|
1048
|
-
"
|
|
1055
|
+
"on-before-history-undo",
|
|
1049
1056
|
"feature-flags",
|
|
1050
1057
|
"panel-state",
|
|
1051
1058
|
"snapshot-preview",
|
|
@@ -1057,7 +1064,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1057
1064
|
"is-saving",
|
|
1058
1065
|
"is-save-disabled"
|
|
1059
1066
|
]),
|
|
1060
|
-
D(
|
|
1067
|
+
D(at, {
|
|
1061
1068
|
open: w($).modalOpen.value,
|
|
1062
1069
|
issues: w($).blockingIssues.value,
|
|
1063
1070
|
onCancel: w($).cancel,
|
|
@@ -1068,10 +1075,10 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1068
1075
|
"onCancel",
|
|
1069
1076
|
"onConfirm"
|
|
1070
1077
|
]),
|
|
1071
|
-
D(
|
|
1072
|
-
visible: w(
|
|
1073
|
-
onCancel: w(
|
|
1074
|
-
onConfirm: w(
|
|
1078
|
+
D(Ft, {
|
|
1079
|
+
visible: w(W).isPreviewingSnapshot.value,
|
|
1080
|
+
onCancel: w(W).cancelPreview,
|
|
1081
|
+
onConfirm: w(W).confirmRestoreSnapshot
|
|
1075
1082
|
}, null, 8, [
|
|
1076
1083
|
"visible",
|
|
1077
1084
|
"onCancel",
|
|
@@ -1085,21 +1092,21 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1085
1092
|
"leave-from-class": "tpl:translate-y-0 tpl:opacity-100",
|
|
1086
1093
|
"leave-to-class": "tpl:translate-y-[-8px] tpl:opacity-0"
|
|
1087
1094
|
}, {
|
|
1088
|
-
default: c(() => [D(
|
|
1095
|
+
default: c(() => [D(Lt, { visible: w(G).collabUndoWarningVisible.value }, null, 8, ["visible"])]),
|
|
1089
1096
|
_: 1
|
|
1090
1097
|
}),
|
|
1091
|
-
u(D(
|
|
1098
|
+
u(D(he, null, null, 512), [[x, !w(R).state.previewMode]]),
|
|
1092
1099
|
v("div", {
|
|
1093
|
-
class: e(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [...Ee.value, w(
|
|
1100
|
+
class: e(["tpl-body tpl:absolute tpl:bottom-0 tpl:overflow-auto", [...Ee.value, w(W).isPreviewingSnapshot.value ? "tpl:top-[104px]" : "tpl:top-14"]]),
|
|
1094
1101
|
style: b({
|
|
1095
1102
|
transition: "all 300ms cubic-bezier(0.34, 1.56, 0.64, 1)",
|
|
1096
|
-
backgroundColor:
|
|
1103
|
+
backgroundColor: X.value ? "var(--tpl-bg)" : "var(--tpl-canvas-bg)"
|
|
1097
1104
|
})
|
|
1098
|
-
}, [J.value && q.value === "displayRules" ? (a(), _(
|
|
1105
|
+
}, [J.value && q.value === "displayRules" ? (a(), _(me, { key: 0 })) : J.value && q.value === "schedule" ? (a(), _(ve, {
|
|
1099
1106
|
key: 1,
|
|
1100
1107
|
layout: "standalone"
|
|
1101
|
-
})) : (a(), E(g, { key: 2 }, [v("div",
|
|
1102
|
-
default: c(() => [w(
|
|
1108
|
+
})) : (a(), E(g, { key: 2 }, [v("div", zt, [D(T, { name: "tpl-restore-btn" }, {
|
|
1109
|
+
default: c(() => [w(z).conditionPreview.hasHiddenBlocks.value ? (a(), E("button", {
|
|
1103
1110
|
key: 0,
|
|
1104
1111
|
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",
|
|
1105
1112
|
style: {
|
|
@@ -1108,23 +1115,23 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1108
1115
|
"border-color": "var(--tpl-warning)",
|
|
1109
1116
|
"backdrop-filter": "blur(8px)"
|
|
1110
1117
|
},
|
|
1111
|
-
onClick: i[0] ||= (e) => w(
|
|
1112
|
-
}, [D(w(
|
|
1118
|
+
onClick: i[0] ||= (e) => w(z).conditionPreview.reset()
|
|
1119
|
+
}, [D(w(ue), {
|
|
1113
1120
|
size: 13,
|
|
1114
1121
|
"stroke-width": 2
|
|
1115
|
-
}), p(" " + r(w(
|
|
1122
|
+
}), p(" " + r(w(z).t.blockSettings.restoreHiddenBlocks), 1)])) : f("", !0)]),
|
|
1116
1123
|
_: 1
|
|
1117
|
-
})]), v("main",
|
|
1118
|
-
viewport: w(
|
|
1119
|
-
content: w(
|
|
1120
|
-
"selected-block-id": w(
|
|
1121
|
-
"dark-mode": w(
|
|
1122
|
-
"preview-mode": w(
|
|
1124
|
+
})]), v("main", Bt, [D(pe, {
|
|
1125
|
+
viewport: w(R).state.viewport,
|
|
1126
|
+
content: w(R).content.value,
|
|
1127
|
+
"selected-block-id": w(R).state.selectedBlockId,
|
|
1128
|
+
"dark-mode": w(R).state.darkMode,
|
|
1129
|
+
"preview-mode": w(R).state.previewMode,
|
|
1123
1130
|
"multi-page-canvas": t.config.multiPageCanvas ?? !1,
|
|
1124
|
-
"locked-blocks": w(
|
|
1125
|
-
onSelectBlock: w(
|
|
1126
|
-
onOpenAiChat: i[1] ||= (e) => w(
|
|
1127
|
-
onOpenDesignReference: i[2] ||= (e) => w(
|
|
1131
|
+
"locked-blocks": w(L)?.lockedBlocks.value ?? void 0,
|
|
1132
|
+
onSelectBlock: w(R).selectBlock,
|
|
1133
|
+
onOpenAiChat: i[1] ||= (e) => w(U).aiChatOpen.value = !0,
|
|
1134
|
+
onOpenDesignReference: i[2] ||= (e) => w(U).designReferenceOpen.value = !0
|
|
1128
1135
|
}, null, 8, [
|
|
1129
1136
|
"viewport",
|
|
1130
1137
|
"content",
|
|
@@ -1135,7 +1142,7 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1135
1142
|
"locked-blocks",
|
|
1136
1143
|
"onSelectBlock"
|
|
1137
1144
|
])])], 64))], 6),
|
|
1138
|
-
t.config.branding !== !1 && !w(
|
|
1145
|
+
t.config.branding !== !1 && !w(B).isWhiteLabeled.value ? (a(), _(_e, {
|
|
1139
1146
|
key: 0,
|
|
1140
1147
|
"position-class": Ee.value
|
|
1141
1148
|
}, null, 8, ["position-class"])) : f("", !0),
|
|
@@ -1144,41 +1151,41 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1144
1151
|
role: "status",
|
|
1145
1152
|
"aria-live": "polite",
|
|
1146
1153
|
"aria-atomic": "true",
|
|
1147
|
-
"aria-label": w(
|
|
1148
|
-
}, r(w(
|
|
1149
|
-
u(D(
|
|
1150
|
-
"selected-block": w(
|
|
1151
|
-
settings: w(
|
|
1152
|
-
"shifted-left": w(
|
|
1153
|
-
onUpdateBlock: i[3] ||= (e) => w(
|
|
1154
|
-
onDeleteBlock: i[4] ||= (e) => w(
|
|
1155
|
-
onDuplicateBlock: i[5] ||= (e) => w(
|
|
1156
|
-
onUpdateSettings: w(
|
|
1154
|
+
"aria-label": w(z).t.landmarks.reorderAnnouncements
|
|
1155
|
+
}, r(w(z).keyboardReorder.announcement.value), 9, Vt),
|
|
1156
|
+
u(D(le, {
|
|
1157
|
+
"selected-block": w(R).selectedBlock.value,
|
|
1158
|
+
settings: w(R).content.value.settings,
|
|
1159
|
+
"shifted-left": w(U).rightPanelOpen.value,
|
|
1160
|
+
onUpdateBlock: i[3] ||= (e) => w(R).updateBlock(w(R).selectedBlock.value.id, e),
|
|
1161
|
+
onDeleteBlock: i[4] ||= (e) => w(z).blockActions.deleteBlock(w(R).selectedBlock.value.id),
|
|
1162
|
+
onDuplicateBlock: i[5] ||= (e) => w(z).blockActions.duplicateBlock(w(R).selectedBlock.value),
|
|
1163
|
+
onUpdateSettings: w(R).updateSettings
|
|
1157
1164
|
}, null, 8, [
|
|
1158
1165
|
"selected-block",
|
|
1159
1166
|
"settings",
|
|
1160
1167
|
"shifted-left",
|
|
1161
1168
|
"onUpdateSettings"
|
|
1162
|
-
]), [[x, !w(
|
|
1163
|
-
!w(
|
|
1169
|
+
]), [[x, !w(R).state.previewMode && !we.value]]),
|
|
1170
|
+
!w(j) && w(N) ? (a(), _(xt, {
|
|
1164
1171
|
key: 1,
|
|
1165
1172
|
ref_key: "cloudPanelsRef",
|
|
1166
1173
|
ref: C,
|
|
1167
1174
|
config: d.config,
|
|
1168
|
-
editor: w(
|
|
1169
|
-
core: w(
|
|
1170
|
-
"panel-state": w(
|
|
1171
|
-
"plan-config-instance": w(
|
|
1172
|
-
"test-email": w(
|
|
1173
|
-
"media-lib": w(
|
|
1174
|
-
"saved-modules-headless": w(
|
|
1175
|
-
"show-save-module-dialog": w(
|
|
1176
|
-
"save-module-pre-selected-block-id": w(
|
|
1177
|
-
"show-module-browser-modal": w(
|
|
1178
|
-
"onUpdate:showSaveModuleDialog": i[6] ||= (e) =>
|
|
1179
|
-
"onUpdate:saveModulePreSelectedBlockId": i[7] ||= (e) =>
|
|
1180
|
-
"onUpdate:showModuleBrowserModal": i[8] ||= (e) =>
|
|
1181
|
-
onSendTestEmail:
|
|
1175
|
+
editor: w(R),
|
|
1176
|
+
core: w(z),
|
|
1177
|
+
"panel-state": w(U),
|
|
1178
|
+
"plan-config-instance": w(F),
|
|
1179
|
+
"test-email": w(V),
|
|
1180
|
+
"media-lib": w(re),
|
|
1181
|
+
"saved-modules-headless": w(se),
|
|
1182
|
+
"show-save-module-dialog": w(fe),
|
|
1183
|
+
"save-module-pre-selected-block-id": w(ye),
|
|
1184
|
+
"show-module-browser-modal": w(K),
|
|
1185
|
+
"onUpdate:showSaveModuleDialog": i[6] ||= (e) => fe.value = e,
|
|
1186
|
+
"onUpdate:saveModulePreSelectedBlockId": i[7] ||= (e) => ye.value = e,
|
|
1187
|
+
"onUpdate:showModuleBrowserModal": i[8] ||= (e) => K.value = e,
|
|
1188
|
+
onSendTestEmail: Z,
|
|
1182
1189
|
onModuleInsert: Te
|
|
1183
1190
|
}, null, 8, [
|
|
1184
1191
|
"config",
|
|
@@ -1193,15 +1200,15 @@ var Ye = ["aria-label"], Xe = { class: "tpl:flex tpl:max-h-[80vh] tpl:w-full tpl
|
|
|
1193
1200
|
"save-module-pre-selected-block-id",
|
|
1194
1201
|
"show-module-browser-modal"
|
|
1195
1202
|
])) : f("", !0),
|
|
1196
|
-
t.config.tour ? (a(), _(
|
|
1203
|
+
t.config.tour ? (a(), _(ge, {
|
|
1197
1204
|
key: 2,
|
|
1198
1205
|
ref_key: "editorTourRef",
|
|
1199
1206
|
ref: O,
|
|
1200
1207
|
"tour-config": t.config.tour,
|
|
1201
|
-
"dark-mode": w(
|
|
1208
|
+
"dark-mode": w(R).state.darkMode
|
|
1202
1209
|
}, null, 8, ["tour-config", "dark-mode"])) : f("", !0)
|
|
1203
|
-
], 14,
|
|
1210
|
+
], 14, Rt));
|
|
1204
1211
|
}
|
|
1205
|
-
}), [["__scopeId", "data-v-
|
|
1212
|
+
}), [["__scopeId", "data-v-6985a9ad"]]);
|
|
1206
1213
|
//#endregion
|
|
1207
|
-
export {
|
|
1214
|
+
export { Ht as default };
|