@templatical/editor 0.6.7 → 0.7.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/README.md +26 -1
- package/dist/{AccessibilityPanel-B2MT0M58.js → AccessibilityPanel-D-PqmHdH.js} +2 -2
- package/dist/{AiChatSidebar-w5ek3Z76.js → AiChatSidebar-BwLECwsO.js} +1 -1
- package/dist/{AiFeatureMenu-ChlAWywJ.js → AiFeatureMenu-CVHKharv.js} +3 -3
- package/dist/{BlockA11yBadge-C0S6kPC4.js → BlockA11yBadge-BFIw0h1m.js} +2 -2
- package/dist/{CloudEditor-DYYaScFe.js → CloudEditor-S7AzuNwC.js} +30 -21
- package/dist/{CollaboratorBar-Bo8vtPId.js → CollaboratorBar-VZKOv_Zn.js} +2 -2
- package/dist/{CommentsSidebar-BQROg36f.js → CommentsSidebar-BiRtaXYD.js} +3 -3
- package/dist/{CountdownBlock-Bxqe7zwL.js → CountdownBlock-Cq8A8WrM.js} +1 -1
- package/dist/{CountdownToolbar-CpFAnjSo.js → CountdownToolbar-CojjlZet.js} +2 -2
- package/dist/{DesignReferenceSidebar-CfqpcWX6.js → DesignReferenceSidebar-Ci9HIGbf.js} +2 -2
- package/dist/ModuleBrowserModal-D7IYx1Nh.js +206 -0
- package/dist/{ModulePreviewCanvas-Cw9GeGus.js → ModulePreviewCanvas-I-uMcK5G.js} +2 -2
- package/dist/{NumberWithSuffix-Dw8dN1Pt.js → NumberWithSuffix-CLTBb2Rj.js} +1 -1
- package/dist/{ParagraphEditor-DjDiUzmv.js → ParagraphEditor-BRQTNDFO.js} +156 -151
- package/dist/{RichTextEditorContent-CK3Om7ES.js → RichTextEditorContent-C3QSg7gd.js} +32 -28
- package/dist/{SaveModuleDialog-CSUPmfRP.js → SaveModuleDialog-DGGGNZfm.js} +6 -6
- package/dist/{SnapshotHistory-DwX2fj6N.js → SnapshotHistory-C97Iw6xw.js} +3 -3
- package/dist/{TemplateScoringPanel-BIAeCAEP.js → TemplateScoringPanel-V79yrEPC.js} +3 -3
- package/dist/{TestEmailModal-CIlBvWWn.js → TestEmailModal-B7S8H-VG.js} +3 -3
- package/dist/{TitleEditor-BCV5k6wj.js → TitleEditor-DhFTYzrw.js} +65 -60
- package/dist/{TplModal-C3Hq9b58.js → TplModal-BgABm6ju.js} +21 -17
- package/dist/{blockTypeIcons-iUurP50H.js → blockTypeIcons-BSf-3RJ-.js} +1 -1
- package/dist/bundle-stats.json +7 -7
- package/dist/cdn/chunks/{AccessibilityPanel-DnNB30b0.js → AccessibilityPanel-kgNBRaZV.js} +28 -28
- package/dist/cdn/chunks/{AccessibilityPanel-DnNB30b0.js.map → AccessibilityPanel-kgNBRaZV.js.map} +1 -1
- package/dist/cdn/chunks/{AiFeatureMenu-BKBh_ueF.js → AiFeatureMenu-CRkzwdMg.js} +15 -15
- package/dist/cdn/chunks/{AiFeatureMenu-BKBh_ueF.js.map → AiFeatureMenu-CRkzwdMg.js.map} +1 -1
- package/dist/cdn/chunks/{BlockA11yBadge-CnBu14Fj.js → BlockA11yBadge-BfuH2Hrg.js} +9 -9
- package/dist/cdn/chunks/{BlockA11yBadge-CnBu14Fj.js.map → BlockA11yBadge-BfuH2Hrg.js.map} +1 -1
- package/dist/cdn/chunks/{CloudEditor-CmR17piA.js → CloudEditor-BGiN3M_f.js} +252 -243
- package/dist/cdn/chunks/CloudEditor-BGiN3M_f.js.map +1 -0
- package/dist/cdn/chunks/{CollaboratorBar-BejZaFtY.js → CollaboratorBar-CMl3lAZU.js} +15 -15
- package/dist/cdn/chunks/{CollaboratorBar-BejZaFtY.js.map → CollaboratorBar-CMl3lAZU.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownBlock-CjvUEHhE.js → CountdownBlock-D1RoaOgF.js} +18 -18
- package/dist/cdn/chunks/{CountdownBlock-CjvUEHhE.js.map → CountdownBlock-D1RoaOgF.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownToolbar-Caokkqsg.js → CountdownToolbar-DltwuOer.js} +42 -42
- package/dist/cdn/chunks/{CountdownToolbar-Caokkqsg.js.map → CountdownToolbar-DltwuOer.js.map} +1 -1
- package/dist/cdn/chunks/{ModuleBrowserModal-Tb9a7L-K.js → ModuleBrowserModal-3uu2mXR9.js} +36 -36
- package/dist/cdn/chunks/{ModuleBrowserModal-Tb9a7L-K.js.map → ModuleBrowserModal-3uu2mXR9.js.map} +1 -1
- package/dist/cdn/chunks/{ModulePreviewCanvas-JWIEv5oS.js → ModulePreviewCanvas-K9CQFr7p.js} +37 -37
- package/dist/cdn/chunks/{ModulePreviewCanvas-JWIEv5oS.js.map → ModulePreviewCanvas-K9CQFr7p.js.map} +1 -1
- package/dist/cdn/chunks/{NumberWithSuffix-DrV8eumz.js → NumberWithSuffix-BIFgtqGs.js} +74 -74
- package/dist/cdn/chunks/{NumberWithSuffix-DrV8eumz.js.map → NumberWithSuffix-BIFgtqGs.js.map} +1 -1
- package/dist/cdn/chunks/{ParagraphEditor-CSfShBAO.js → ParagraphEditor-DlpZX_x4.js} +180 -176
- package/dist/cdn/chunks/ParagraphEditor-DlpZX_x4.js.map +1 -0
- package/dist/cdn/chunks/{RichTextEditorContent-DgqZzl8n.js → RichTextEditorContent-CPGT8h-O.js} +40 -37
- package/dist/cdn/chunks/RichTextEditorContent-CPGT8h-O.js.map +1 -0
- package/dist/cdn/chunks/{SaveModuleDialog-CxTwrIgx.js → SaveModuleDialog-_uaJscj1.js} +24 -24
- package/dist/cdn/chunks/{SaveModuleDialog-CxTwrIgx.js.map → SaveModuleDialog-_uaJscj1.js.map} +1 -1
- package/dist/cdn/chunks/TitleEditor-Kerz6US8.js +175 -0
- package/dist/cdn/chunks/TitleEditor-Kerz6US8.js.map +1 -0
- package/dist/cdn/chunks/{blockTypeIcons-DMt-2qR6.js → blockTypeIcons-BeOhGtoo.js} +7 -7
- package/dist/cdn/chunks/{blockTypeIcons-DMt-2qR6.js.map → blockTypeIcons-BeOhGtoo.js.map} +1 -1
- package/dist/cdn/chunks/{draggable-CNhyCGIO.js → draggable-P6QWzy4g.js} +1182 -1171
- package/dist/cdn/chunks/{draggable-CNhyCGIO.js.map → draggable-P6QWzy4g.js.map} +1 -1
- package/dist/cdn/chunks/{extensions-CUvwrffu.js → extensions-BZYkPlKr.js} +107 -108
- package/dist/cdn/chunks/extensions-BZYkPlKr.js.map +1 -0
- package/dist/cdn/chunks/{features-U3nzKc-R.js → features-DzIN-Nua.js} +925 -896
- package/dist/cdn/chunks/features-DzIN-Nua.js.map +1 -0
- package/dist/cdn/chunks/{icons-QcjADKIW.js → icons-Nvr6w13E.js} +2 -2
- package/dist/cdn/chunks/{icons-QcjADKIW.js.map → icons-Nvr6w13E.js.map} +1 -1
- package/dist/cdn/chunks/{media-library-Zcd_GInj.js → media-library-BzT7BoGU.js} +1189 -1183
- package/dist/cdn/chunks/media-library-BzT7BoGU.js.map +1 -0
- package/dist/cdn/chunks/{quality-8eo6DM3p.js → quality-C328caFm.js} +45 -45
- package/dist/cdn/chunks/{quality-8eo6DM3p.js.map → quality-C328caFm.js.map} +1 -1
- package/dist/cdn/chunks/renderer-eDlxzlJI.js +501 -0
- package/dist/cdn/chunks/renderer-eDlxzlJI.js.map +1 -0
- package/dist/cdn/chunks/{src-CthVYW_o.js → src-DKNTQJVO.js} +144 -144
- package/dist/cdn/chunks/{src-CthVYW_o.js.map → src-DKNTQJVO.js.map} +1 -1
- package/dist/cdn/chunks/{styles-CV5w3kjq.js → styles-lcwmaOou.js} +969 -958
- package/dist/cdn/chunks/styles-lcwmaOou.js.map +1 -0
- package/dist/cdn/chunks/{tiptap-IyIsncxY.js → tiptap-BwTCLVWl.js} +7 -7
- package/dist/cdn/chunks/{tiptap-IyIsncxY.js.map → tiptap-BwTCLVWl.js.map} +1 -1
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +197 -146
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{extensions-BF39Siqk.js → extensions-D-J02CiP.js} +50 -51
- package/dist/index.d.ts +51 -6
- package/dist/{keys-Bqs_0du9.js → keys-B5SJtPWf.js} +3 -3
- package/dist/style.css +1 -1
- package/dist/{styles-BgmKdc2x.js → styles-DeNciUTX.js} +586 -575
- package/dist/templatical-editor.js +182 -131
- package/dist/{useCloudI18n-CL_AwWwi.js → useCloudI18n-ByEMykjO.js} +1 -1
- package/dist/{useEditorCore-CnXrv71D.js → useEditorCore-uCU9Ny0M.js} +637 -619
- package/dist/{useI18n-CgmQftNf.js → useI18n-PEB8ioi_.js} +1 -1
- package/dist/{useMergeTag-vpwrZ9eQ.js → useMergeTag-C47xwU7X.js} +2 -2
- package/dist/usePopoverRoot-BxJrqnMD.js +8 -0
- package/package.json +7 -7
- package/dist/ModuleBrowserModal-CKhsaPnA.js +0 -206
- package/dist/cdn/chunks/CloudEditor-CmR17piA.js.map +0 -1
- package/dist/cdn/chunks/ParagraphEditor-CSfShBAO.js.map +0 -1
- package/dist/cdn/chunks/RichTextEditorContent-DgqZzl8n.js.map +0 -1
- package/dist/cdn/chunks/TitleEditor-DlqV7ODD.js +0 -171
- package/dist/cdn/chunks/TitleEditor-DlqV7ODD.js.map +0 -1
- package/dist/cdn/chunks/extensions-CUvwrffu.js.map +0 -1
- package/dist/cdn/chunks/features-U3nzKc-R.js.map +0 -1
- package/dist/cdn/chunks/media-library-Zcd_GInj.js.map +0 -1
- package/dist/cdn/chunks/renderer-eHJyPiJH.js +0 -548
- package/dist/cdn/chunks/renderer-eHJyPiJH.js.map +0 -1
- package/dist/cdn/chunks/styles-CV5w3kjq.js.map +0 -1
- /package/dist/{de-DcVOh9Fp.js → de-BhIWu_bO.js} +0 -0
- /package/dist/{de-DCaaCE5s.js → de-Di4MEjjx.js} +0 -0
- /package/dist/{emojiData-PQyVa4bU.js → emojiData-DX3E0XT-.js} +0 -0
- /package/dist/{en-DXCyK4-X.js → en-BSuzi-Pd.js} +0 -0
- /package/dist/{en-TZVJ_f6v.js → en-D7HRbYah.js} +0 -0
- /package/dist/{pt-BR-Vq7D7c11.js → pt-BR-CCVBRais.js} +0 -0
- /package/dist/{pt-BR-BMGasLBa.js → pt-BR-K32lt6YP.js} +0 -0
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
import { A as e, B as t, E as n, F as r, J as i, L as a, M as o, N as s, X as c, _ as l, a as u, at as d, b as f, c as p, d as m, f as h, h as g, l as _, m as v, o as y, ot as b, p as x, rt as S, s as C, st as w, t as T, v as E, w as D, y as O, z as k } from "./vue.runtime.esm-bundler-Bxqkjqhc.js";
|
|
2
|
-
import { C as A, D as j, E as
|
|
3
|
-
import { A as ne, F as I, I as L, M as re, N as ie, T as ae, _ as oe, a as se, c as ce, d as le, g as ue, h as de, i as fe, j as pe, k as
|
|
4
|
-
import { s as
|
|
5
|
-
import {
|
|
6
|
-
import { t as
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { t as
|
|
10
|
-
import { t as
|
|
11
|
-
import { n as
|
|
12
|
-
import { n as
|
|
13
|
-
import { t as
|
|
14
|
-
import { t as
|
|
15
|
-
import { t as
|
|
16
|
-
import { t as
|
|
17
|
-
import { n as
|
|
18
|
-
import { t as
|
|
19
|
-
import { t as
|
|
20
|
-
import { t as
|
|
21
|
-
import { t as
|
|
22
|
-
import { t as
|
|
23
|
-
import { t as
|
|
24
|
-
import { t as
|
|
25
|
-
import { _ as
|
|
26
|
-
import { i as
|
|
27
|
-
var
|
|
2
|
+
import { C as A, D as j, E as ee, S as M, a as te, l as N, n as P, o as F } from "./dist-DJmnUmW9.js";
|
|
3
|
+
import { A as ne, F as I, I as L, M as re, N as ie, T as ae, _ as oe, a as se, c as ce, d as le, g as ue, h as de, i as fe, j as pe, k as R, l as me, m as he, n as ge, o as _e, p as ve, r as ye, s as be, u as xe, v as Se, y as Ce } from "./useEditorCore-uCU9Ny0M.js";
|
|
4
|
+
import { s as we } from "./dist-BzRLLpfq.js";
|
|
5
|
+
import { A as Te, S as Ee, c as De, d as Oe, f as ke, g as Ae, m as je, o as Me, p as Ne, r as Pe, s as Fe, t as Ie, x as Le } from "./keys-B5SJtPWf.js";
|
|
6
|
+
import { t as z } from "./useI18n-PEB8ioi_.js";
|
|
7
|
+
import { t as B } from "./createLucideIcon-Di4mqmGn.js";
|
|
8
|
+
import { t as Re } from "./accessibility-BgUEA-Ai.js";
|
|
9
|
+
import { t as ze } from "./chevron-down-tee-ghFi.js";
|
|
10
|
+
import { t as Be } from "./circle-alert-C0L9pUQ4.js";
|
|
11
|
+
import { n as Ve, r as V, t as He } from "./blockTypeIcons-BSf-3RJ-.js";
|
|
12
|
+
import { n as Ue, t as We } from "./refresh-cw-BNAhAmtL.js";
|
|
13
|
+
import { t as Ge } from "./image-up-1D_3XDdO.js";
|
|
14
|
+
import { t as Ke } from "./info-DTGrc0Bx.js";
|
|
15
|
+
import { t as qe } from "./scan-line-DUEg6DoT.js";
|
|
16
|
+
import { t as Je } from "./sparkles-D1IGi_cC.js";
|
|
17
|
+
import { n as Ye, r as Xe, t as Ze } from "./text-align-start-DG3aAH7Y.js";
|
|
18
|
+
import { t as Qe } from "./trash-2-424iqbpN.js";
|
|
19
|
+
import { t as $e } from "./x-Dlaenqta.js";
|
|
20
|
+
import { t as H } from "./_plugin-vue_export-helper-B0hnzhyu.js";
|
|
21
|
+
import { t as et } from "./useCloudI18n-ByEMykjO.js";
|
|
22
|
+
import { t as tt } from "./useMergeTag-C47xwU7X.js";
|
|
23
|
+
import { t as nt } from "./readableTextColor-CY3SiRnt.js";
|
|
24
|
+
import { t as rt } from "./CountdownBlock-Cq8A8WrM.js";
|
|
25
|
+
import { _ as it, c as at, f as U, g as ot, h as W, l as st, m as G, p as K, t as ct } from "./styleConstants-fWzlIIwN.js";
|
|
26
|
+
import { i as q, n as J, r as Y, t as lt } from "./NumberWithSuffix-CLTBb2Rj.js";
|
|
27
|
+
var ut = B("circle", [["circle", {
|
|
28
28
|
cx: "12",
|
|
29
29
|
cy: "12",
|
|
30
30
|
r: "10",
|
|
31
31
|
key: "1mglay"
|
|
32
|
-
}]]),
|
|
32
|
+
}]]), dt = B("globe", [
|
|
33
33
|
["circle", {
|
|
34
34
|
cx: "12",
|
|
35
35
|
cy: "12",
|
|
@@ -44,7 +44,7 @@ var dt = z("circle", [["circle", {
|
|
|
44
44
|
d: "M2 12h20",
|
|
45
45
|
key: "9i4pu4"
|
|
46
46
|
}]
|
|
47
|
-
]),
|
|
47
|
+
]), ft = B("layout-template", [
|
|
48
48
|
["rect", {
|
|
49
49
|
width: "18",
|
|
50
50
|
height: "7",
|
|
@@ -69,7 +69,7 @@ var dt = z("circle", [["circle", {
|
|
|
69
69
|
rx: "1",
|
|
70
70
|
key: "q5h2i8"
|
|
71
71
|
}]
|
|
72
|
-
]),
|
|
72
|
+
]), pt = B("lock-open", [["rect", {
|
|
73
73
|
width: "18",
|
|
74
74
|
height: "11",
|
|
75
75
|
x: "3",
|
|
@@ -80,7 +80,7 @@ var dt = z("circle", [["circle", {
|
|
|
80
80
|
}], ["path", {
|
|
81
81
|
d: "M7 11V7a5 5 0 0 1 9.9-1",
|
|
82
82
|
key: "1mm8w8"
|
|
83
|
-
}]]),
|
|
83
|
+
}]]), mt = B("lock", [["rect", {
|
|
84
84
|
width: "18",
|
|
85
85
|
height: "11",
|
|
86
86
|
x: "3",
|
|
@@ -91,7 +91,7 @@ var dt = z("circle", [["circle", {
|
|
|
91
91
|
}], ["path", {
|
|
92
92
|
d: "M7 11V7a5 5 0 0 1 10 0v4",
|
|
93
93
|
key: "fwvmzm"
|
|
94
|
-
}]]),
|
|
94
|
+
}]]), ht = B("monitor", [
|
|
95
95
|
["rect", {
|
|
96
96
|
width: "20",
|
|
97
97
|
height: "14",
|
|
@@ -114,10 +114,10 @@ var dt = z("circle", [["circle", {
|
|
|
114
114
|
y2: "21",
|
|
115
115
|
key: "vw1qmm"
|
|
116
116
|
}]
|
|
117
|
-
]),
|
|
117
|
+
]), gt = B("moon", [["path", {
|
|
118
118
|
d: "M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",
|
|
119
119
|
key: "kfwtm"
|
|
120
|
-
}]]),
|
|
120
|
+
}]]), _t = B("panel-top", [["rect", {
|
|
121
121
|
width: "18",
|
|
122
122
|
height: "18",
|
|
123
123
|
x: "3",
|
|
@@ -127,19 +127,19 @@ var dt = z("circle", [["circle", {
|
|
|
127
127
|
}], ["path", {
|
|
128
128
|
d: "M3 9h18",
|
|
129
129
|
key: "1pudct"
|
|
130
|
-
}]]),
|
|
130
|
+
}]]), X = B("plus", [["path", {
|
|
131
131
|
d: "M5 12h14",
|
|
132
132
|
key: "1ays0h"
|
|
133
133
|
}], ["path", {
|
|
134
134
|
d: "M12 5v14",
|
|
135
135
|
key: "s699le"
|
|
136
|
-
}]]),
|
|
136
|
+
}]]), vt = B("rotate-ccw", [["path", {
|
|
137
137
|
d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",
|
|
138
138
|
key: "1357e3"
|
|
139
139
|
}], ["path", {
|
|
140
140
|
d: "M3 3v5h5",
|
|
141
141
|
key: "1xhq8a"
|
|
142
|
-
}]]),
|
|
142
|
+
}]]), yt = B("settings", [["path", {
|
|
143
143
|
d: "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",
|
|
144
144
|
key: "1i5ecw"
|
|
145
145
|
}], ["circle", {
|
|
@@ -147,7 +147,7 @@ var dt = z("circle", [["circle", {
|
|
|
147
147
|
cy: "12",
|
|
148
148
|
r: "3",
|
|
149
149
|
key: "1v7zrd"
|
|
150
|
-
}]]),
|
|
150
|
+
}]]), bt = B("smartphone", [["rect", {
|
|
151
151
|
width: "14",
|
|
152
152
|
height: "20",
|
|
153
153
|
x: "5",
|
|
@@ -158,7 +158,7 @@ var dt = z("circle", [["circle", {
|
|
|
158
158
|
}], ["path", {
|
|
159
159
|
d: "M12 18h.01",
|
|
160
160
|
key: "mhygvu"
|
|
161
|
-
}]]),
|
|
161
|
+
}]]), xt = B("square-plus", [
|
|
162
162
|
["rect", {
|
|
163
163
|
width: "18",
|
|
164
164
|
height: "18",
|
|
@@ -175,14 +175,14 @@ var dt = z("circle", [["circle", {
|
|
|
175
175
|
d: "M12 8v8",
|
|
176
176
|
key: "napkw2"
|
|
177
177
|
}]
|
|
178
|
-
]),
|
|
178
|
+
]), St = B("square", [["rect", {
|
|
179
179
|
width: "18",
|
|
180
180
|
height: "18",
|
|
181
181
|
x: "3",
|
|
182
182
|
y: "3",
|
|
183
183
|
rx: "2",
|
|
184
184
|
key: "afitv7"
|
|
185
|
-
}]]),
|
|
185
|
+
}]]), Ct = B("sun", [
|
|
186
186
|
["circle", {
|
|
187
187
|
cx: "12",
|
|
188
188
|
cy: "12",
|
|
@@ -221,7 +221,7 @@ var dt = z("circle", [["circle", {
|
|
|
221
221
|
d: "m19.07 4.93-1.41 1.41",
|
|
222
222
|
key: "1shlcs"
|
|
223
223
|
}]
|
|
224
|
-
]),
|
|
224
|
+
]), wt = B("tablet", [["rect", {
|
|
225
225
|
width: "16",
|
|
226
226
|
height: "20",
|
|
227
227
|
x: "4",
|
|
@@ -238,7 +238,7 @@ var dt = z("circle", [["circle", {
|
|
|
238
238
|
}]]);
|
|
239
239
|
//#endregion
|
|
240
240
|
//#region src/utils/resolveAccessibilityOptions.ts
|
|
241
|
-
function
|
|
241
|
+
function Tt(e) {
|
|
242
242
|
return {
|
|
243
243
|
...e.accessibility,
|
|
244
244
|
locale: e.locale
|
|
@@ -246,19 +246,19 @@ function Et(e) {
|
|
|
246
246
|
}
|
|
247
247
|
//#endregion
|
|
248
248
|
//#region src/components/Canvas.vue?vue&type=script&setup=true&lang.ts
|
|
249
|
-
var
|
|
250
|
-
class: "tpl:inline-flex tpl:size-3 tpl:items-center tpl:justify-center tpl:rounded-full tpl:text-[8px] tpl:font-bold",
|
|
251
|
-
style: { "background-color": "color-mix(\n in srgb,\n var(--tpl-bg) 30%,\n transparent\n )" }
|
|
252
|
-
}, At = {
|
|
249
|
+
var Et = ["aria-label"], Dt = {
|
|
253
250
|
key: 0,
|
|
254
|
-
class: "tpl-canvas-empty
|
|
255
|
-
},
|
|
251
|
+
class: "tpl-canvas-empty-content tpl:flex tpl:flex-col tpl:items-center"
|
|
252
|
+
}, Ot = { class: "tpl-canvas-empty-icon tpl:mb-4 tpl:text-[var(--tpl-primary)]" }, kt = { class: "tpl-canvas-empty-title tpl:m-0 tpl:mb-2 tpl:text-base tpl:font-semibold tpl:text-[var(--tpl-primary)]" }, At = { class: "tpl-canvas-empty-text tpl:m-0 tpl:text-sm tpl:text-[var(--tpl-text-dim)]" }, jt = {
|
|
256
253
|
key: 0,
|
|
257
254
|
class: "tpl:m-0 tpl:mt-2 tpl:flex tpl:flex-wrap tpl:items-center tpl:justify-center tpl:gap-x-1 tpl:gap-y-0.5 tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
|
|
258
|
-
},
|
|
255
|
+
}, Mt = {
|
|
259
256
|
key: 1,
|
|
260
257
|
class: "tpl:m-0 tpl:mt-4 tpl:flex tpl:flex-wrap tpl:items-center tpl:justify-center tpl:gap-x-1 tpl:gap-y-0.5 tpl:text-sm tpl:text-[var(--tpl-text-dim)]"
|
|
261
|
-
},
|
|
258
|
+
}, Nt = { class: "tpl:relative" }, Pt = {
|
|
259
|
+
class: "tpl:inline-flex tpl:size-3 tpl:items-center tpl:justify-center tpl:rounded-full tpl:text-[8px] tpl:font-bold",
|
|
260
|
+
style: { "background-color": "color-mix(\n in srgb,\n var(--tpl-bg) 30%,\n transparent\n )" }
|
|
261
|
+
}, Ft = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
262
262
|
__name: "Canvas",
|
|
263
263
|
props: {
|
|
264
264
|
viewport: {},
|
|
@@ -276,48 +276,57 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
276
276
|
setup(n, { emit: i }) {
|
|
277
277
|
let a = {
|
|
278
278
|
section: ce,
|
|
279
|
-
title:
|
|
280
|
-
paragraph:
|
|
279
|
+
title: xe,
|
|
280
|
+
paragraph: he,
|
|
281
281
|
image: ue,
|
|
282
282
|
button: ie,
|
|
283
|
-
divider:
|
|
283
|
+
divider: Se,
|
|
284
284
|
spacer: fe,
|
|
285
285
|
html: oe,
|
|
286
286
|
social: se,
|
|
287
287
|
menu: de,
|
|
288
|
-
table:
|
|
289
|
-
video:
|
|
290
|
-
countdown:
|
|
291
|
-
custom:
|
|
292
|
-
}, s = n,
|
|
288
|
+
table: ye,
|
|
289
|
+
video: ge,
|
|
290
|
+
countdown: rt,
|
|
291
|
+
custom: Ce
|
|
292
|
+
}, s = n, u = i, { t: f } = z(), { t: p } = et(), C = Te(je, "Canvas"), T = D(Oe, null), O = D(Fe, null), A = D(De, {}), j = m(() => (A.plan?.hasFeature("ai_generation") ?? !1) && (A.ai?.isFeatureEnabled("chat") ?? !1)), ee = m(() => (A.plan?.hasFeature("ai_generation") ?? !1) && (A.ai?.isFeatureEnabled("designToTemplate") ?? !1)), M = m({
|
|
293
293
|
get: () => s.content.blocks,
|
|
294
294
|
set: (e) => {
|
|
295
|
-
|
|
295
|
+
C.setContent({
|
|
296
296
|
...s.content,
|
|
297
297
|
blocks: e
|
|
298
298
|
});
|
|
299
299
|
}
|
|
300
|
-
}),
|
|
300
|
+
}), te = m(() => {
|
|
301
301
|
switch (s.viewport) {
|
|
302
302
|
case "mobile": return 375;
|
|
303
303
|
case "tablet": return 768;
|
|
304
304
|
default: return s.content.settings.width;
|
|
305
305
|
}
|
|
306
|
-
}),
|
|
306
|
+
}), N = m(() => ({
|
|
307
307
|
backgroundColor: s.content.settings.backgroundColor,
|
|
308
308
|
fontFamily: s.content.settings.fontFamily
|
|
309
|
-
}));
|
|
310
|
-
function
|
|
311
|
-
|
|
309
|
+
})), P = m(() => M.value.length === 0 && !s.previewMode), F = c(0), ne = m(() => P.value && F.value > 0);
|
|
310
|
+
function I() {
|
|
311
|
+
P.value && (F.value += 1);
|
|
312
|
+
}
|
|
313
|
+
function L() {
|
|
314
|
+
P.value && (F.value = Math.max(0, F.value - 1));
|
|
312
315
|
}
|
|
313
|
-
function
|
|
314
|
-
|
|
316
|
+
function re() {
|
|
317
|
+
F.value = 0;
|
|
315
318
|
}
|
|
316
|
-
function
|
|
319
|
+
function ae(e) {
|
|
320
|
+
s.previewMode || e.target === e.currentTarget && u("select-block", null);
|
|
321
|
+
}
|
|
322
|
+
function pe(e) {
|
|
323
|
+
return ve(e, O, a);
|
|
324
|
+
}
|
|
325
|
+
function R(e) {
|
|
317
326
|
return s.lockedBlocks?.get(e) ?? null;
|
|
318
327
|
}
|
|
319
|
-
function
|
|
320
|
-
e.type === "custom" &&
|
|
328
|
+
function _e(e, t) {
|
|
329
|
+
e.type === "custom" && C.updateBlock(e.id, {
|
|
321
330
|
fieldValues: t.fieldValues,
|
|
322
331
|
dataSourceFetched: t.dataSourceFetched
|
|
323
332
|
});
|
|
@@ -325,10 +334,10 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
325
334
|
return (i, a) => (e(), g("div", {
|
|
326
335
|
"data-testid": "canvas-wrapper",
|
|
327
336
|
role: "region",
|
|
328
|
-
"aria-label": S(
|
|
337
|
+
"aria-label": S(f).landmarks.canvas,
|
|
329
338
|
class: "tpl-canvas-wrapper tpl:rounded-lg",
|
|
330
339
|
style: b({
|
|
331
|
-
width: `${
|
|
340
|
+
width: `${te.value}px`,
|
|
332
341
|
backgroundColor: n.content.settings.backgroundColor,
|
|
333
342
|
boxShadow: n.darkMode ? "none" : "var(--tpl-shadow-xl)",
|
|
334
343
|
filter: n.darkMode ? "invert(1) hue-rotate(180deg)" : "none",
|
|
@@ -339,11 +348,11 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
339
348
|
"tpl-canvas--dark-mode": n.darkMode,
|
|
340
349
|
"tpl-preview-mode": n.previewMode
|
|
341
350
|
}]),
|
|
342
|
-
style: b(
|
|
343
|
-
onClick:
|
|
344
|
-
}, [E(S(
|
|
351
|
+
style: b(N.value),
|
|
352
|
+
onClick: ae
|
|
353
|
+
}, [E(S(me), {
|
|
345
354
|
modelValue: M.value,
|
|
346
|
-
"onUpdate:modelValue": a[
|
|
355
|
+
"onUpdate:modelValue": a[2] ||= (e) => M.value = e,
|
|
347
356
|
group: "blocks",
|
|
348
357
|
animation: 150,
|
|
349
358
|
"ghost-class": "tpl-ghost",
|
|
@@ -352,33 +361,74 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
352
361
|
"invert-swap": !0,
|
|
353
362
|
"inverted-swap-threshold": .65,
|
|
354
363
|
disabled: n.previewMode,
|
|
355
|
-
|
|
364
|
+
draggable: ".tpl-block-item",
|
|
365
|
+
class: d([
|
|
366
|
+
"tpl-canvas-blocks",
|
|
367
|
+
P.value ? "tpl-canvas-empty tpl:m-6 tpl:flex tpl:min-h-[400px] tpl:flex-col tpl:items-center tpl:justify-center tpl:rounded-xl tpl:border-2 tpl:border-dashed tpl:px-10 tpl:py-12 tpl:text-center tpl:bg-[var(--tpl-bg-elevated)] tpl:font-[var(--tpl-font-family)] tpl:transition-colors tpl:duration-150" : "",
|
|
368
|
+
P.value && ne.value ? "tpl-canvas-empty--drag-over tpl:border-[var(--tpl-primary-hover)] tpl:bg-[var(--tpl-primary-light)]" : "",
|
|
369
|
+
P.value && !ne.value ? "tpl:border-[var(--tpl-primary)]" : ""
|
|
370
|
+
]),
|
|
371
|
+
onDragenter: I,
|
|
372
|
+
onDragleave: L,
|
|
373
|
+
onDrop: re
|
|
356
374
|
}, {
|
|
357
|
-
default: k(() => [
|
|
375
|
+
default: k(() => [P.value ? (e(), g("div", Dt, [
|
|
376
|
+
h("div", Ot, [E(S(xt), {
|
|
377
|
+
size: 48,
|
|
378
|
+
"stroke-width": 1
|
|
379
|
+
})]),
|
|
380
|
+
h("p", kt, w(S(f).canvas.noBlocks), 1),
|
|
381
|
+
h("p", At, w(S(f).canvas.dragHint), 1),
|
|
382
|
+
j.value && S(p) ? (e(), g("p", jt, [
|
|
383
|
+
l(w(S(f).canvas.aiHintChat) + " ", 1),
|
|
384
|
+
h("button", {
|
|
385
|
+
class: "tpl:inline-flex tpl:shrink-0 tpl:cursor-pointer tpl:items-center tpl:gap-1 tpl:whitespace-nowrap tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-sm tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
386
|
+
onClick: a[0] ||= (e) => u("open-ai-chat")
|
|
387
|
+
}, [E(S(Je), {
|
|
388
|
+
size: 14,
|
|
389
|
+
"stroke-width": 2
|
|
390
|
+
}), l(" " + w(S(p).aiMenu.aiAssistant), 1)]),
|
|
391
|
+
l(" " + w(S(f).canvas.aiHintChatSuffix), 1)
|
|
392
|
+
])) : v("", !0),
|
|
393
|
+
ee.value && S(p) ? (e(), g("p", Mt, [
|
|
394
|
+
l(w(S(f).canvas.aiHintDesign) + " ", 1),
|
|
395
|
+
h("button", {
|
|
396
|
+
class: "tpl:inline-flex tpl:shrink-0 tpl:cursor-pointer tpl:items-center tpl:gap-1 tpl:whitespace-nowrap tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-sm tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
397
|
+
onClick: a[1] ||= (e) => u("open-design-reference")
|
|
398
|
+
}, [E(S(Ge), {
|
|
399
|
+
size: 14,
|
|
400
|
+
"stroke-width": 2
|
|
401
|
+
}), l(" " + w(S(p).aiMenu.designToTemplate), 1)]),
|
|
402
|
+
l(" " + w(S(f).canvas.aiHintDesignSuffix), 1)
|
|
403
|
+
])) : v("", !0)
|
|
404
|
+
])) : v("", !0), (e(!0), g(_, null, o(M.value, (i) => t((e(), g("div", {
|
|
405
|
+
key: i.id,
|
|
406
|
+
class: "tpl-block-item"
|
|
407
|
+
}, [h("div", Nt, [R(i.id) ? (e(), g("div", {
|
|
358
408
|
key: 0,
|
|
359
409
|
class: "tpl-collab-lock tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-[4] tpl:rounded-sm",
|
|
360
410
|
style: b({
|
|
361
|
-
outline: `2px solid ${
|
|
411
|
+
outline: `2px solid ${R(i.id).color}`,
|
|
362
412
|
outlineOffset: "-1px"
|
|
363
413
|
})
|
|
364
414
|
}, [h("span", {
|
|
365
415
|
class: "tpl:absolute tpl:-top-0.5 tpl:left-1/2 tpl:z-[5] tpl:flex tpl:-translate-x-1/2 tpl:-translate-y-full tpl:items-center tpl:gap-1 tpl:rounded-full tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-medium tpl:whitespace-nowrap",
|
|
366
416
|
style: b({
|
|
367
|
-
backgroundColor:
|
|
368
|
-
color: S(
|
|
417
|
+
backgroundColor: R(i.id).color,
|
|
418
|
+
color: S(nt)(R(i.id).color)
|
|
369
419
|
})
|
|
370
|
-
}, [h("span",
|
|
420
|
+
}, [h("span", Pt, w(R(i.id).name.charAt(0)), 1), l(" " + w(R(i.id).name), 1)], 4)], 4)) : v("", !0), E(le, {
|
|
371
421
|
block: i,
|
|
372
|
-
"is-selected": !n.previewMode && n.selectedBlockId === i.id && !
|
|
422
|
+
"is-selected": !n.previewMode && n.selectedBlockId === i.id && !R(i.id),
|
|
373
423
|
viewport: n.viewport,
|
|
374
424
|
"preview-mode": n.previewMode,
|
|
375
|
-
onSelect: (e) => n.previewMode ||
|
|
425
|
+
onSelect: (e) => n.previewMode || R(i.id) ? void 0 : u("select-block", i.id)
|
|
376
426
|
}, {
|
|
377
|
-
default: k(() => [(e(), x(r(
|
|
427
|
+
default: k(() => [(e(), x(r(pe(i)), {
|
|
378
428
|
block: i,
|
|
379
429
|
viewport: n.viewport,
|
|
380
|
-
onFetchData: (e) =>
|
|
381
|
-
onUpdate: (e) => S(
|
|
430
|
+
onFetchData: (e) => _e(i, e),
|
|
431
|
+
onUpdate: (e) => S(C).updateBlock(i.id, e)
|
|
382
432
|
}, null, 40, [
|
|
383
433
|
"block",
|
|
384
434
|
"viewport",
|
|
@@ -392,60 +442,35 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
392
442
|
"viewport",
|
|
393
443
|
"preview-mode",
|
|
394
444
|
"onSelect"
|
|
395
|
-
])])])), [[y, !S(
|
|
445
|
+
])])])), [[y, !S(T)?.isHidden(i.id)]])), 128))]),
|
|
396
446
|
_: 1
|
|
397
|
-
}, 8, [
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
h("p", Mt, w(S(u).canvas.noBlocks), 1),
|
|
403
|
-
h("p", Nt, w(S(u).canvas.dragHint), 1),
|
|
404
|
-
A.value && S(f) ? (e(), g("p", Pt, [
|
|
405
|
-
l(w(S(u).canvas.aiHintChat) + " ", 1),
|
|
406
|
-
h("button", {
|
|
407
|
-
class: "tpl:inline-flex tpl:shrink-0 tpl:cursor-pointer tpl:items-center tpl:gap-1 tpl:whitespace-nowrap tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-sm tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
408
|
-
onClick: a[1] ||= (e) => c("open-ai-chat")
|
|
409
|
-
}, [E(S(Ye), {
|
|
410
|
-
size: 14,
|
|
411
|
-
"stroke-width": 2
|
|
412
|
-
}), l(" " + w(S(f).aiMenu.aiAssistant), 1)]),
|
|
413
|
-
l(" " + w(S(u).canvas.aiHintChatSuffix), 1)
|
|
414
|
-
])) : v("", !0),
|
|
415
|
-
j.value && S(f) ? (e(), g("p", Ft, [
|
|
416
|
-
l(w(S(u).canvas.aiHintDesign) + " ", 1),
|
|
417
|
-
h("button", {
|
|
418
|
-
class: "tpl:inline-flex tpl:shrink-0 tpl:cursor-pointer tpl:items-center tpl:gap-1 tpl:whitespace-nowrap tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-2 tpl:py-0.5 tpl:text-sm tpl:font-semibold tpl:transition-colors tpl:duration-150 tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary-hover)]",
|
|
419
|
-
onClick: a[2] ||= (e) => c("open-design-reference")
|
|
420
|
-
}, [E(S(Ke), {
|
|
421
|
-
size: 14,
|
|
422
|
-
"stroke-width": 2
|
|
423
|
-
}), l(" " + w(S(f).aiMenu.designToTemplate), 1)]),
|
|
424
|
-
l(" " + w(S(u).canvas.aiHintDesignSuffix), 1)
|
|
425
|
-
])) : v("", !0)
|
|
426
|
-
])) : v("", !0)], 6)], 12, Dt));
|
|
447
|
+
}, 8, [
|
|
448
|
+
"modelValue",
|
|
449
|
+
"disabled",
|
|
450
|
+
"class"
|
|
451
|
+
])], 6)], 12, Et));
|
|
427
452
|
}
|
|
428
|
-
}), [["__scopeId", "data-v-
|
|
453
|
+
}), [["__scopeId", "data-v-14168e8c"]]), It = ["aria-label"], Lt = {
|
|
429
454
|
key: 0,
|
|
430
455
|
class: "tpl:border-b tpl:px-1 tpl:pb-1 tpl:border-[var(--tpl-border)]"
|
|
431
|
-
},
|
|
456
|
+
}, Rt = ["aria-label"], zt = {
|
|
432
457
|
key: 0,
|
|
433
458
|
class: "tpl:flex-1 tpl:truncate tpl:text-sm tpl:font-medium"
|
|
434
|
-
},
|
|
459
|
+
}, Bt = {
|
|
435
460
|
key: 1,
|
|
436
461
|
class: "tpl:shrink-0 tpl:rounded-full tpl:px-1.5 tpl:py-0.5 tpl:text-[10px] tpl:font-medium tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-muted)]"
|
|
437
|
-
},
|
|
462
|
+
}, Vt = [
|
|
438
463
|
"data-palette-type",
|
|
439
464
|
"aria-label",
|
|
440
465
|
"onClick",
|
|
441
466
|
"onKeydown"
|
|
442
|
-
],
|
|
467
|
+
], Ht = { class: "tpl:flex tpl:shrink-0 tpl:items-center tpl:justify-center tpl:transition-transform tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)] hover:tpl:scale-105" }, Ut = {
|
|
443
468
|
key: 0,
|
|
444
469
|
class: "tpl:truncate tpl:text-sm tpl:font-medium"
|
|
445
|
-
},
|
|
470
|
+
}, Wt = /* @__PURE__ */ f({
|
|
446
471
|
__name: "Sidebar",
|
|
447
472
|
setup(t) {
|
|
448
|
-
let { t: n, format: i } =
|
|
473
|
+
let { t: n, format: i } = z(), { t: a } = et(), s = D(ke, []), l = D(Me, void 0), u = D(je, null), d = D(De, {}), f = m(() => (d.savedModules?.moduleCount.value ?? 0) > 0), p = c(!1), y = [
|
|
449
474
|
"section",
|
|
450
475
|
"image",
|
|
451
476
|
"title",
|
|
@@ -476,7 +501,7 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
476
501
|
function A(e) {
|
|
477
502
|
if (e.isCustom) {
|
|
478
503
|
let t = e.type.replace("custom:", ""), n = s.find((e) => e.type === t);
|
|
479
|
-
if (n) return
|
|
504
|
+
if (n) return N(n);
|
|
480
505
|
}
|
|
481
506
|
return F(e.type, l);
|
|
482
507
|
}
|
|
@@ -485,7 +510,7 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
485
510
|
let t = A(e);
|
|
486
511
|
u.addBlock(t), u.selectBlock(t.id);
|
|
487
512
|
}
|
|
488
|
-
function
|
|
513
|
+
function ee(e, t) {
|
|
489
514
|
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), j(t));
|
|
490
515
|
}
|
|
491
516
|
return (t, s) => (e(), g("aside", {
|
|
@@ -502,21 +527,21 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
502
527
|
onMouseleave: s[2] ||= (e) => p.value = !1,
|
|
503
528
|
onFocusin: s[3] ||= (e) => p.value = !0,
|
|
504
529
|
onFocusout: s[4] ||= (e) => p.value = !1
|
|
505
|
-
}, [f.value && S(a) ? (e(), g("div",
|
|
530
|
+
}, [f.value && S(a) ? (e(), g("div", Lt, [h("button", {
|
|
506
531
|
type: "button",
|
|
507
532
|
"aria-label": S(n).sidebarNav.browseModules,
|
|
508
533
|
class: "tpl:flex tpl:h-10 tpl:w-full tpl:cursor-pointer tpl:items-center tpl:gap-3 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:bg-transparent tpl:px-3 tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-[120ms] hover:tpl:bg-[var(--tpl-primary-light)] hover:tpl:text-[var(--tpl-primary)]",
|
|
509
534
|
style: b({ justifyContent: p.value ? "flex-start" : "center" }),
|
|
510
535
|
onClick: s[0] ||= (e) => S(d).savedModules?.openBrowser()
|
|
511
536
|
}, [
|
|
512
|
-
E(S(
|
|
537
|
+
E(S(Ve), {
|
|
513
538
|
size: 20,
|
|
514
539
|
"stroke-width": 1.5,
|
|
515
540
|
class: "tpl:shrink-0"
|
|
516
541
|
}),
|
|
517
|
-
p.value ? (e(), g("span",
|
|
518
|
-
p.value ? (e(), g("span",
|
|
519
|
-
], 12,
|
|
542
|
+
p.value ? (e(), g("span", zt, w(S(a).modules.title), 1)) : v("", !0),
|
|
543
|
+
p.value ? (e(), g("span", Bt, w(S(d).savedModules?.moduleCount.value ?? 0), 1)) : v("", !0)
|
|
544
|
+
], 12, Rt)])) : v("", !0), E(S(me), {
|
|
520
545
|
"model-value": O.value,
|
|
521
546
|
group: {
|
|
522
547
|
name: "blocks",
|
|
@@ -537,8 +562,8 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
537
562
|
class: "tpl:flex tpl:h-10 tpl:w-full tpl:cursor-grab tpl:items-center tpl:gap-3 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:bg-transparent tpl:px-3 tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)] hover:tpl:bg-[var(--tpl-primary-light)] hover:tpl:text-[var(--tpl-primary)] active:tpl:cursor-grabbing",
|
|
538
563
|
style: b({ justifyContent: p.value ? "flex-start" : "center" }),
|
|
539
564
|
onClick: (e) => j(t),
|
|
540
|
-
onKeydown: (e) =>
|
|
541
|
-
}, [h("div",
|
|
565
|
+
onKeydown: (e) => ee(e, t)
|
|
566
|
+
}, [h("div", Ht, [S(He)[t.type] ? (e(), x(r(S(He)[t.type]), {
|
|
542
567
|
key: 0,
|
|
543
568
|
size: 20,
|
|
544
569
|
"stroke-width": 1.5
|
|
@@ -546,15 +571,15 @@ var Dt = ["aria-label"], Ot = { class: "tpl:relative" }, kt = {
|
|
|
546
571
|
key: 1,
|
|
547
572
|
icon: t.icon,
|
|
548
573
|
size: 20
|
|
549
|
-
}, null, 8, ["icon"])) : v("", !0)]), p.value ? (e(), g("span",
|
|
574
|
+
}, null, 8, ["icon"])) : v("", !0)]), p.value ? (e(), g("span", Ut, w(t.label), 1)) : v("", !0)], 44, Vt))), 128))]),
|
|
550
575
|
_: 1
|
|
551
|
-
}, 8, ["model-value"])], 44,
|
|
576
|
+
}, 8, ["model-value"])], 44, It));
|
|
552
577
|
}
|
|
553
578
|
});
|
|
554
579
|
//#endregion
|
|
555
580
|
//#region src/composables/useMergeTagField.ts
|
|
556
|
-
function
|
|
557
|
-
let { modelValue: t, emit: r, elementRef: i } = e, { canRequestMergeTag: a, isRequesting: o, isMergeTagValue: s, getMergeTagLabel: l, requestMergeTag: u, syntax: d } =
|
|
581
|
+
function Gt(e) {
|
|
582
|
+
let { modelValue: t, emit: r, elementRef: i } = e, { canRequestMergeTag: a, isRequesting: o, isMergeTagValue: s, getMergeTagLabel: l, requestMergeTag: u, syntax: d } = tt(), f = c(!1), p = !1, h = m(() => {
|
|
558
583
|
let e = t();
|
|
559
584
|
if (!e) return [];
|
|
560
585
|
let n = [], r = `(${d.value.source}|${d.logic.source})`, i = new RegExp(r, "g"), a = 0, o;
|
|
@@ -630,10 +655,10 @@ function Kt(e) {
|
|
|
630
655
|
}
|
|
631
656
|
//#endregion
|
|
632
657
|
//#region src/components/MergeTagSegments.vue?vue&type=script&setup=true&lang.ts
|
|
633
|
-
var
|
|
658
|
+
var Kt = ["aria-label", "onKeydown"], qt = ["data-tooltip"], Jt = ["data-tooltip"], Yt = {
|
|
634
659
|
key: 2,
|
|
635
660
|
class: "tpl:text-sm tpl:text-[var(--tpl-text)]"
|
|
636
|
-
},
|
|
661
|
+
}, Xt = ["aria-label", "title"], Zt = /* @__PURE__ */ f({
|
|
637
662
|
__name: "MergeTagSegments",
|
|
638
663
|
props: {
|
|
639
664
|
segments: {},
|
|
@@ -642,7 +667,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
642
667
|
},
|
|
643
668
|
emits: ["edit", "clear"],
|
|
644
669
|
setup(t, { emit: n }) {
|
|
645
|
-
let r = n, { t: i } =
|
|
670
|
+
let r = n, { t: i } = z();
|
|
646
671
|
function a() {
|
|
647
672
|
r("edit");
|
|
648
673
|
}
|
|
@@ -661,7 +686,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
661
686
|
"background-color": "color-mix(\n in srgb,\n var(--tpl-primary) 20%,\n transparent\n )",
|
|
662
687
|
color: "var(--tpl-primary)"
|
|
663
688
|
}
|
|
664
|
-
}, w(t.label), 9,
|
|
689
|
+
}, w(t.label), 9, qt)) : t.type === "logicMergeTag" ? (e(), g("span", {
|
|
665
690
|
key: 1,
|
|
666
691
|
class: "tpl-tooltip tpl:inline-flex tpl:items-center tpl:rounded tpl:px-1.5 tpl:py-0.5 tpl:text-[0.8em] tpl:font-bold tpl:tracking-wide tpl:uppercase",
|
|
667
692
|
"data-tooltip": t.value,
|
|
@@ -670,44 +695,44 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
670
695
|
border: "1.5px solid\n color-mix(in srgb, var(--tpl-primary) 50%, transparent)",
|
|
671
696
|
color: "var(--tpl-primary)"
|
|
672
697
|
}
|
|
673
|
-
}, w(t.keyword), 9,
|
|
698
|
+
}, w(t.keyword), 9, Jt)) : (e(), g("span", Yt, w(t.value), 1))], 64))), 128)), h("button", {
|
|
674
699
|
type: "button",
|
|
675
700
|
class: "tpl:ml-auto tpl:flex tpl:size-6 tpl:shrink-0 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-full tpl:border-none tpl:bg-transparent tpl:p-0 tpl:text-[var(--tpl-text-dim)] tpl:opacity-60 tpl:transition-all hover:tpl:text-[var(--tpl-danger)] hover:tpl:opacity-100",
|
|
676
701
|
"aria-label": S(i).mergeTag.remove,
|
|
677
702
|
title: S(i).mergeTag.remove,
|
|
678
703
|
onClick: s[0] ||= p((e) => r("clear"), ["stop"])
|
|
679
|
-
}, [E(S(
|
|
704
|
+
}, [E(S($e), {
|
|
680
705
|
size: 12,
|
|
681
706
|
"stroke-width": 2.5
|
|
682
|
-
})], 8,
|
|
707
|
+
})], 8, Xt)], 42, Kt));
|
|
683
708
|
}
|
|
684
|
-
}),
|
|
709
|
+
}), Qt = [
|
|
685
710
|
"aria-label",
|
|
686
711
|
"title",
|
|
687
712
|
"disabled"
|
|
688
|
-
],
|
|
713
|
+
], $t = "tpl:flex tpl:items-center tpl:justify-center tpl:gap-1 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:px-2 tpl:py-1 tpl:text-xs tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-[120ms] hover:tpl:bg-[var(--tpl-primary-light)] hover:tpl:text-[var(--tpl-primary)] hover:tpl:border-[var(--tpl-primary)]", en = /* @__PURE__ */ f({
|
|
689
714
|
__name: "MergeTagInsertButton",
|
|
690
715
|
props: { disabled: { type: Boolean } },
|
|
691
716
|
emits: ["insert"],
|
|
692
717
|
setup(t) {
|
|
693
|
-
let { t: n } =
|
|
718
|
+
let { t: n } = z();
|
|
694
719
|
return (r, i) => (e(), g("button", {
|
|
695
720
|
type: "button",
|
|
696
|
-
class: d([
|
|
721
|
+
class: d([$t, "tpl:mt-1.5"]),
|
|
697
722
|
"aria-label": S(n).mergeTag.insert,
|
|
698
723
|
title: S(n).mergeTag.insert,
|
|
699
724
|
disabled: t.disabled,
|
|
700
725
|
onClick: i[0] ||= (e) => r.$emit("insert")
|
|
701
|
-
}, [E(S(
|
|
726
|
+
}, [E(S(qe), {
|
|
702
727
|
size: 12,
|
|
703
728
|
"stroke-width": 2
|
|
704
|
-
}), l(" " + w(S(n).mergeTag.insert), 1)], 10,
|
|
729
|
+
}), l(" " + w(S(n).mergeTag.insert), 1)], 10, Qt));
|
|
705
730
|
}
|
|
706
|
-
}),
|
|
731
|
+
}), tn = { key: 0 }, nn = { key: 1 }, rn = [
|
|
707
732
|
"value",
|
|
708
733
|
"placeholder",
|
|
709
734
|
"rows"
|
|
710
|
-
],
|
|
735
|
+
], an = "tpl:w-full tpl:resize-y tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:shadow-xs tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-2 tpl:text-sm tpl:text-[var(--tpl-text)] tpl:outline-none tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)] tpl:placeholder:text-[var(--tpl-text-dim)] tpl:focus:border-[var(--tpl-primary)] tpl:focus:shadow-[var(--tpl-ring)]", on = "tpl:flex tpl:w-full tpl:min-h-[5rem] tpl:cursor-pointer tpl:items-start tpl:flex-wrap tpl:gap-1 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:shadow-xs tpl:bg-[var(--tpl-bg)] tpl:border-[var(--tpl-border)] tpl:px-3 tpl:py-2 tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", sn = /* @__PURE__ */ f({
|
|
711
736
|
__name: "MergeTagTextarea",
|
|
712
737
|
props: {
|
|
713
738
|
modelValue: {},
|
|
@@ -716,46 +741,46 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
716
741
|
},
|
|
717
742
|
emits: ["update:modelValue"],
|
|
718
743
|
setup(t, { emit: n }) {
|
|
719
|
-
let r = t, i = n, a = c(null), { segments: o, hasMergeTags: s, canRequestMergeTag: l, isRequestingMergeTag: u, isEditing: f, startEditing: p, stopEditing: m, handleInput: _, clearValue: y, insertMergeTag: b } =
|
|
744
|
+
let r = t, i = n, a = c(null), { segments: o, hasMergeTags: s, canRequestMergeTag: l, isRequestingMergeTag: u, isEditing: f, startEditing: p, stopEditing: m, handleInput: _, clearValue: y, insertMergeTag: b } = Gt({
|
|
720
745
|
modelValue: () => r.modelValue,
|
|
721
746
|
emit: (e) => i("update:modelValue", e),
|
|
722
747
|
elementRef: a
|
|
723
748
|
});
|
|
724
|
-
return (n, r) => S(s) && !S(f) ? (e(), g("div",
|
|
749
|
+
return (n, r) => S(s) && !S(f) ? (e(), g("div", tn, [E(Zt, {
|
|
725
750
|
segments: S(o),
|
|
726
|
-
"display-class":
|
|
751
|
+
"display-class": on,
|
|
727
752
|
onEdit: S(p),
|
|
728
753
|
onClear: S(y)
|
|
729
754
|
}, null, 8, [
|
|
730
755
|
"segments",
|
|
731
756
|
"onEdit",
|
|
732
757
|
"onClear"
|
|
733
|
-
]), S(l) ? (e(), x(
|
|
758
|
+
]), S(l) ? (e(), x(en, {
|
|
734
759
|
key: 0,
|
|
735
760
|
disabled: S(u),
|
|
736
761
|
onInsert: S(b)
|
|
737
|
-
}, null, 8, ["disabled", "onInsert"])) : v("", !0)])) : (e(), g("div",
|
|
762
|
+
}, null, 8, ["disabled", "onInsert"])) : v("", !0)])) : (e(), g("div", nn, [h("textarea", {
|
|
738
763
|
ref_key: "textareaRef",
|
|
739
764
|
ref: a,
|
|
740
|
-
class: d(
|
|
765
|
+
class: d(an),
|
|
741
766
|
value: t.modelValue,
|
|
742
767
|
placeholder: t.placeholder,
|
|
743
768
|
rows: t.rows,
|
|
744
769
|
onInput: r[0] ||= (...e) => S(_) && S(_)(...e),
|
|
745
770
|
onBlur: r[1] ||= (...e) => S(m) && S(m)(...e),
|
|
746
771
|
onKeydown: r[2] ||= C((...e) => S(m) && S(m)(...e), ["escape"])
|
|
747
|
-
}, null, 40,
|
|
772
|
+
}, null, 40, rn), S(l) ? (e(), x(en, {
|
|
748
773
|
key: 0,
|
|
749
774
|
disabled: S(u),
|
|
750
775
|
onInsert: S(b)
|
|
751
776
|
}, null, 8, ["disabled", "onInsert"])) : v("", !0)]));
|
|
752
777
|
}
|
|
753
|
-
}),
|
|
778
|
+
}), cn = { class: "tpl:flex tpl:w-full tpl:flex-1 tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)]" }, ln = { class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:gap-3 tpl:overflow-y-auto tpl:p-4" }, un = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, dn = { class: "tpl:mb-3.5" }, fn = { class: "tpl:grid tpl:grid-cols-4 tpl:gap-1 tpl:rounded-[var(--tpl-radius-sm)] tpl:p-1 tpl:bg-[var(--tpl-bg-hover)]" }, pn = ["onClick"], mn = { class: "tpl:flex tpl:items-stretch" }, hn = ["value"], gn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, _n = { class: "tpl:mb-3.5" }, vn = ["value"], yn = ["value"], bn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, xn = ["value"], Sn = { class: "tpl:mt-1 tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, Cn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, wn = { class: "tpl:mt-1 tpl:flex tpl:items-start tpl:justify-between tpl:gap-2" }, Tn = { class: "tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, En = { class: "tpl:shrink-0 tpl:text-xs tpl:tabular-nums tpl:text-[var(--tpl-text-dim)]" }, Dn = { class: "tpl:rounded-[var(--tpl-radius)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:p-3" }, On = { class: "tpl:mb-2.5 tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text-muted)]" }, kn = { class: "tpl:m-0 tpl:pl-[18px] tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, An = { class: "tpl:mb-1 tpl:last:mb-0" }, jn = { class: "tpl:mb-1 tpl:last:mb-0" }, Mn = { class: "tpl:mb-1 tpl:last:mb-0" }, Nn = 150, Pn = /* @__PURE__ */ f({
|
|
754
779
|
__name: "TemplateSettings",
|
|
755
780
|
props: { settings: {} },
|
|
756
781
|
emits: ["update"],
|
|
757
782
|
setup(t, { emit: n }) {
|
|
758
|
-
let r = t, i = n, { t: a } =
|
|
783
|
+
let r = t, i = n, { t: a } = z(), s = Te(Ae, "TemplateSettings"), c = m(() => s.fonts.value), l = m(() => c.value.some((e) => e.value === r.settings.fontFamily) ? r.settings.fontFamily : s.defaultFont.value), u = [
|
|
759
784
|
{
|
|
760
785
|
value: 480,
|
|
761
786
|
label: "480px"
|
|
@@ -773,14 +798,14 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
773
798
|
label: "800px"
|
|
774
799
|
}
|
|
775
800
|
];
|
|
776
|
-
return (n, r) => (e(), g("aside",
|
|
777
|
-
h("div", { class: d(S(
|
|
778
|
-
h("div",
|
|
801
|
+
return (n, r) => (e(), g("aside", cn, [h("div", ln, [
|
|
802
|
+
h("div", { class: d(S(st)) }, [
|
|
803
|
+
h("div", un, [E(S(St), {
|
|
779
804
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
780
805
|
size: 14,
|
|
781
806
|
"stroke-width": 2
|
|
782
807
|
}), h("span", null, w(S(a).templateSettings.layout), 1)]),
|
|
783
|
-
h("div",
|
|
808
|
+
h("div", dn, [h("label", { class: d(S(W)) }, w(S(a).templateSettings.widthPreset), 3), h("div", fn, [(e(), g(_, null, o(u, (e) => h("button", {
|
|
784
809
|
key: e.value,
|
|
785
810
|
class: "tpl:cursor-pointer tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-2 tpl:py-1.5 tpl:text-sm tpl:font-medium tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]",
|
|
786
811
|
style: b({
|
|
@@ -789,79 +814,79 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
789
814
|
boxShadow: t.settings.width === e.value ? "var(--tpl-shadow)" : "none"
|
|
790
815
|
}),
|
|
791
816
|
onClick: (t) => i("update", { width: e.value })
|
|
792
|
-
}, w(e.label), 13,
|
|
793
|
-
h("div", null, [h("label", { class: d(S(
|
|
817
|
+
}, w(e.label), 13, pn)), 64))])]),
|
|
818
|
+
h("div", null, [h("label", { class: d(S(W)) }, w(S(a).templateSettings.customWidth), 3), h("div", mn, [h("input", {
|
|
794
819
|
type: "number",
|
|
795
|
-
class: d(S(
|
|
820
|
+
class: d(S(K)),
|
|
796
821
|
value: t.settings.width,
|
|
797
822
|
min: "300",
|
|
798
823
|
max: "900",
|
|
799
824
|
onInput: r[0] ||= (e) => i("update", { width: Number(e.target.value) })
|
|
800
|
-
}, null, 42,
|
|
825
|
+
}, null, 42, hn), h("span", { class: d(S(G)) }, "px", 2)])])
|
|
801
826
|
], 2),
|
|
802
|
-
h("div", { class: d(S(
|
|
803
|
-
h("div",
|
|
827
|
+
h("div", { class: d(S(st)) }, [
|
|
828
|
+
h("div", gn, [E(S(ut), {
|
|
804
829
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
805
830
|
size: 14,
|
|
806
831
|
"stroke-width": 2
|
|
807
832
|
}), h("span", null, w(S(a).templateSettings.appearance), 1)]),
|
|
808
|
-
h("div",
|
|
833
|
+
h("div", _n, [h("label", { class: d(S(W)) }, w(S(a).templateSettings.backgroundColor), 3), E(q, {
|
|
809
834
|
"model-value": t.settings.backgroundColor,
|
|
810
|
-
placeholder: S(
|
|
835
|
+
placeholder: S(ct),
|
|
811
836
|
"onUpdate:modelValue": r[1] ||= (e) => i("update", { backgroundColor: e })
|
|
812
837
|
}, null, 8, ["model-value", "placeholder"])]),
|
|
813
|
-
h("div", null, [h("label", { class: d(S(
|
|
814
|
-
class: d(S(
|
|
838
|
+
h("div", null, [h("label", { class: d(S(W)) }, w(S(a).templateSettings.fontFamily), 3), h("select", {
|
|
839
|
+
class: d(S(U)),
|
|
815
840
|
value: l.value,
|
|
816
841
|
onChange: r[2] ||= (e) => i("update", { fontFamily: e.target.value })
|
|
817
842
|
}, [(e(!0), g(_, null, o(c.value, (t) => (e(), g("option", {
|
|
818
843
|
key: t.value,
|
|
819
844
|
value: t.value
|
|
820
|
-
}, w(t.label), 9,
|
|
845
|
+
}, w(t.label), 9, yn))), 128))], 42, vn)])
|
|
821
846
|
], 2),
|
|
822
|
-
h("div", { class: d(S(
|
|
847
|
+
h("div", { class: d(S(st)) }, [h("div", bn, [E(S(dt), {
|
|
823
848
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
824
849
|
size: 14,
|
|
825
850
|
"stroke-width": 2
|
|
826
851
|
}), h("span", null, w(S(a).templateSettings.language), 1)]), h("div", null, [
|
|
827
|
-
h("label", { class: d(S(
|
|
852
|
+
h("label", { class: d(S(W)) }, w(S(a).templateSettings.contentLocale), 3),
|
|
828
853
|
h("input", {
|
|
829
854
|
type: "text",
|
|
830
|
-
class: d(S(
|
|
855
|
+
class: d(S(U)),
|
|
831
856
|
value: t.settings.locale ?? "",
|
|
832
857
|
placeholder: "en",
|
|
833
858
|
spellcheck: "false",
|
|
834
859
|
autocapitalize: "off",
|
|
835
860
|
autocomplete: "off",
|
|
836
861
|
onInput: r[3] ||= (e) => i("update", { locale: e.target.value.trim() || void 0 })
|
|
837
|
-
}, null, 42,
|
|
838
|
-
h("p",
|
|
862
|
+
}, null, 42, xn),
|
|
863
|
+
h("p", Sn, w(S(a).templateSettings.contentLocaleHint), 1)
|
|
839
864
|
])], 2),
|
|
840
|
-
h("div", { class: d(S(
|
|
865
|
+
h("div", { class: d(S(st)) }, [h("div", Cn, [E(S(Ue), {
|
|
841
866
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
842
867
|
size: 14,
|
|
843
868
|
"stroke-width": 2
|
|
844
|
-
}), h("span", null, w(S(a).templateSettings.preheaderText), 1)]), h("div", null, [E(
|
|
869
|
+
}), h("span", null, w(S(a).templateSettings.preheaderText), 1)]), h("div", null, [E(sn, {
|
|
845
870
|
"model-value": t.settings.preheaderText ?? "",
|
|
846
871
|
placeholder: S(a).templateSettings.preheaderTextPlaceholder,
|
|
847
872
|
rows: 2,
|
|
848
873
|
"onUpdate:modelValue": r[4] ||= (e) => i("update", { preheaderText: e.replace(/[\r\n]/g, " ") || void 0 })
|
|
849
|
-
}, null, 8, ["model-value", "placeholder"]), h("div",
|
|
850
|
-
h("div",
|
|
874
|
+
}, null, 8, ["model-value", "placeholder"]), h("div", wn, [h("span", Tn, w(S(a).templateSettings.preheaderTextHint), 1), h("span", En, w((t.settings.preheaderText ?? "").length) + "/" + w(Nn), 1)])])], 2),
|
|
875
|
+
h("div", Dn, [h("div", On, [E(S(Ke), {
|
|
851
876
|
size: 14,
|
|
852
877
|
"stroke-width": 2
|
|
853
|
-
}), h("span", null, w(S(a).templateSettings.tips), 1)]), h("ul",
|
|
854
|
-
h("li",
|
|
855
|
-
h("li",
|
|
856
|
-
h("li",
|
|
878
|
+
}), h("span", null, w(S(a).templateSettings.tips), 1)]), h("ul", kn, [
|
|
879
|
+
h("li", An, w(S(a).templateSettings.tip1), 1),
|
|
880
|
+
h("li", jn, w(S(a).templateSettings.tip2), 1),
|
|
881
|
+
h("li", Mn, w(S(a).templateSettings.tip3), 1)
|
|
857
882
|
])])
|
|
858
883
|
])]));
|
|
859
884
|
}
|
|
860
|
-
}),
|
|
885
|
+
}), Fn = { key: 0 }, In = { key: 1 }, Ln = [
|
|
861
886
|
"type",
|
|
862
887
|
"value",
|
|
863
888
|
"placeholder"
|
|
864
|
-
],
|
|
889
|
+
], Rn = "tpl:flex tpl:w-full tpl:min-h-10 tpl:cursor-pointer tpl:items-center tpl:flex-wrap tpl:gap-1 tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:shadow-xs tpl:bg-[var(--tpl-bg)] tpl:border-[var(--tpl-border)] tpl:px-3.5 tpl:py-1.5 tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", Z = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
865
890
|
__name: "MergeTagInput",
|
|
866
891
|
props: {
|
|
867
892
|
modelValue: {},
|
|
@@ -874,14 +899,14 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
874
899
|
},
|
|
875
900
|
emits: ["update:modelValue"],
|
|
876
901
|
setup(t, { emit: n }) {
|
|
877
|
-
let r = t, i = n, a = c(null), { segments: o, hasMergeTags: s, canRequestMergeTag: l, isRequestingMergeTag: u, isEditing: f, startEditing: p, stopEditing: m, handleInput: _, clearValue: y, insertMergeTag: b } =
|
|
902
|
+
let r = t, i = n, a = c(null), { segments: o, hasMergeTags: s, canRequestMergeTag: l, isRequestingMergeTag: u, isEditing: f, startEditing: p, stopEditing: m, handleInput: _, clearValue: y, insertMergeTag: b } = Gt({
|
|
878
903
|
modelValue: () => r.modelValue,
|
|
879
904
|
emit: (e) => i("update:modelValue", e),
|
|
880
905
|
elementRef: a
|
|
881
906
|
});
|
|
882
|
-
return (n, r) => S(s) && !S(f) ? (e(), g("div",
|
|
907
|
+
return (n, r) => S(s) && !S(f) ? (e(), g("div", Fn, [E(Zt, {
|
|
883
908
|
segments: S(o),
|
|
884
|
-
"display-class":
|
|
909
|
+
"display-class": Rn,
|
|
885
910
|
pulse: t.pulse,
|
|
886
911
|
onEdit: S(p),
|
|
887
912
|
onClear: S(y)
|
|
@@ -890,30 +915,30 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
890
915
|
"pulse",
|
|
891
916
|
"onEdit",
|
|
892
917
|
"onClear"
|
|
893
|
-
]), S(l) ? (e(), x(
|
|
918
|
+
]), S(l) ? (e(), x(en, {
|
|
894
919
|
key: 0,
|
|
895
920
|
disabled: S(u),
|
|
896
921
|
onInsert: S(b)
|
|
897
|
-
}, null, 8, ["disabled", "onInsert"])) : v("", !0)])) : (e(), g("div",
|
|
922
|
+
}, null, 8, ["disabled", "onInsert"])) : v("", !0)])) : (e(), g("div", In, [h("input", {
|
|
898
923
|
ref_key: "inputRef",
|
|
899
924
|
ref: a,
|
|
900
925
|
type: t.type,
|
|
901
|
-
class: d([S(
|
|
926
|
+
class: d([S(U), { "tpl-pulse-fill": t.pulse }]),
|
|
902
927
|
value: t.modelValue,
|
|
903
928
|
placeholder: t.placeholder,
|
|
904
929
|
onInput: r[0] ||= (...e) => S(_) && S(_)(...e),
|
|
905
930
|
onBlur: r[1] ||= (...e) => S(m) && S(m)(...e),
|
|
906
931
|
onKeydown: r[2] ||= C((...e) => S(m) && S(m)(...e), ["escape"])
|
|
907
|
-
}, null, 42,
|
|
932
|
+
}, null, 42, Ln), S(l) ? (e(), x(en, {
|
|
908
933
|
key: 0,
|
|
909
934
|
disabled: S(u),
|
|
910
935
|
onInsert: S(b)
|
|
911
936
|
}, null, 8, ["disabled", "onInsert"])) : v("", !0)]));
|
|
912
937
|
}
|
|
913
|
-
}), [["__scopeId", "data-v-358207dd"]]),
|
|
938
|
+
}), [["__scopeId", "data-v-358207dd"]]), zn = { class: "tpl:mb-3.5" }, Bn = ["value"], Vn = { value: "" }, Hn = ["value"], Un = { class: "tpl:mb-3.5" }, Wn = { class: "tpl:mb-3.5" }, Gn = {
|
|
914
939
|
key: 0,
|
|
915
940
|
class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]"
|
|
916
|
-
},
|
|
941
|
+
}, Kn = ["checked"], qn = { class: "tpl:grid tpl:grid-cols-2 tpl:gap-3" }, Jn = { class: "tpl:mb-3.5" }, Yn = { class: "tpl:mb-3.5" }, Xn = { class: "tpl:grid tpl:grid-cols-2 tpl:gap-3" }, Zn = { class: "tpl:mb-3.5" }, Qn = { class: "tpl:flex tpl:items-stretch" }, $n = ["value"], er = { class: "tpl:mb-3.5" }, tr = { class: "tpl:flex tpl:items-stretch" }, nr = ["value"], rr = /* @__PURE__ */ f({
|
|
917
942
|
__name: "ButtonToolbar",
|
|
918
943
|
props: {
|
|
919
944
|
block: {},
|
|
@@ -921,64 +946,64 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
921
946
|
},
|
|
922
947
|
emits: ["update"],
|
|
923
948
|
setup(t, { emit: n }) {
|
|
924
|
-
let r = n, { t: i } =
|
|
949
|
+
let r = n, { t: i } = z();
|
|
925
950
|
function a(e, t) {
|
|
926
951
|
r("update", { [e]: t });
|
|
927
952
|
}
|
|
928
953
|
return (n, r) => (e(), g(_, null, [
|
|
929
|
-
h("div",
|
|
930
|
-
class: d(S(
|
|
954
|
+
h("div", zn, [h("label", { class: d(S(W)) }, w(S(i).button.fontFamily), 3), h("select", {
|
|
955
|
+
class: d(S(U)),
|
|
931
956
|
value: t.block.fontFamily || "",
|
|
932
957
|
onChange: r[0] ||= (e) => a("fontFamily", e.target.value || void 0)
|
|
933
|
-
}, [h("option",
|
|
958
|
+
}, [h("option", Vn, w(S(i).button.inheritFont), 1), (e(!0), g(_, null, o(t.fontFamilies, (t) => (e(), g("option", {
|
|
934
959
|
key: t.value,
|
|
935
960
|
value: t.value
|
|
936
|
-
}, w(t.label), 9,
|
|
937
|
-
h("div",
|
|
961
|
+
}, w(t.label), 9, Hn))), 128))], 42, Bn)]),
|
|
962
|
+
h("div", Un, [h("label", { class: d(S(W)) }, w(S(i).button.text), 3), E(Z, {
|
|
938
963
|
"model-value": t.block.text,
|
|
939
964
|
type: "text",
|
|
940
965
|
"onUpdate:modelValue": r[1] ||= (e) => a("text", e)
|
|
941
966
|
}, null, 8, ["model-value"])]),
|
|
942
|
-
h("div",
|
|
943
|
-
h("label", { class: d(S(
|
|
944
|
-
E(
|
|
967
|
+
h("div", Wn, [
|
|
968
|
+
h("label", { class: d(S(W)) }, w(S(i).button.url), 3),
|
|
969
|
+
E(Z, {
|
|
945
970
|
"model-value": t.block.url,
|
|
946
971
|
type: "url",
|
|
947
972
|
placeholder: S(i).button.urlPlaceholder,
|
|
948
973
|
"onUpdate:modelValue": r[2] ||= (e) => a("url", e)
|
|
949
974
|
}, null, 8, ["model-value", "placeholder"]),
|
|
950
|
-
t.block.url ? (e(), g("label",
|
|
975
|
+
t.block.url ? (e(), g("label", Gn, [h("input", {
|
|
951
976
|
type: "checkbox",
|
|
952
977
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
953
978
|
checked: t.block.openInNewTab ?? !1,
|
|
954
979
|
onChange: r[3] ||= (e) => a("openInNewTab", e.target.checked)
|
|
955
|
-
}, null, 40,
|
|
980
|
+
}, null, 40, Kn), l(" " + w(S(i).button.openInNewTab), 1)])) : v("", !0)
|
|
956
981
|
]),
|
|
957
|
-
h("div",
|
|
982
|
+
h("div", qn, [h("div", Jn, [h("label", { class: d(S(W)) }, w(S(i).button.background), 3), E(q, {
|
|
958
983
|
"model-value": t.block.backgroundColor,
|
|
959
984
|
"onUpdate:modelValue": r[4] ||= (e) => a("backgroundColor", e)
|
|
960
|
-
}, null, 8, ["model-value"])]), h("div",
|
|
985
|
+
}, null, 8, ["model-value"])]), h("div", Yn, [h("label", { class: d(S(W)) }, w(S(i).button.textColor), 3), E(q, {
|
|
961
986
|
"model-value": t.block.textColor,
|
|
962
987
|
"onUpdate:modelValue": r[5] ||= (e) => a("textColor", e)
|
|
963
988
|
}, null, 8, ["model-value"])])]),
|
|
964
|
-
h("div",
|
|
989
|
+
h("div", Xn, [h("div", Zn, [h("label", { class: d(S(W)) }, w(S(i).button.borderRadius), 3), h("div", Qn, [h("input", {
|
|
965
990
|
type: "number",
|
|
966
|
-
class: d(S(
|
|
991
|
+
class: d(S(K)),
|
|
967
992
|
value: t.block.borderRadius,
|
|
968
993
|
min: "0",
|
|
969
994
|
max: "50",
|
|
970
995
|
onInput: r[6] ||= (e) => a("borderRadius", Number(e.target.value))
|
|
971
|
-
}, null, 42,
|
|
996
|
+
}, null, 42, $n), h("span", { class: d(S(G)) }, "px", 2)])]), h("div", er, [h("label", { class: d(S(W)) }, w(S(i).button.fontSize), 3), h("div", tr, [h("input", {
|
|
972
997
|
type: "number",
|
|
973
|
-
class: d(S(
|
|
998
|
+
class: d(S(K)),
|
|
974
999
|
value: t.block.fontSize,
|
|
975
1000
|
min: "10",
|
|
976
1001
|
max: "36",
|
|
977
1002
|
onInput: r[7] ||= (e) => a("fontSize", Number(e.target.value))
|
|
978
|
-
}, null, 42,
|
|
1003
|
+
}, null, 42, nr), h("span", { class: d(S(G)) }, "px", 2)])])])
|
|
979
1004
|
], 64));
|
|
980
1005
|
}
|
|
981
|
-
}),
|
|
1006
|
+
}), ir = { class: "spacing-control" }, ar = { class: "tpl:mb-2 tpl:block tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, or = { class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-1.5" }, sr = { class: "tpl:flex tpl:items-center" }, cr = ["aria-label"], lr = ["value", "aria-label"], ur = ["aria-label"], dr = { class: "tpl:flex tpl:items-center tpl:gap-2" }, fr = { class: "tpl:flex tpl:items-center" }, pr = ["aria-label"], mr = ["value", "aria-label"], hr = ["aria-label"], gr = ["aria-label", "title"], _r = { class: "tpl:flex tpl:items-center" }, vr = ["aria-label"], yr = ["value", "aria-label"], br = ["aria-label"], xr = { class: "tpl:flex tpl:items-center" }, Sr = ["aria-label"], Cr = ["value", "aria-label"], wr = ["aria-label"], Q = "tpl:flex tpl:items-center tpl:justify-center tpl:w-8 tpl:h-8 tpl:text-[var(--tpl-text-muted)] tpl:bg-[var(--tpl-bg)] tpl:border tpl:border-[var(--tpl-border)] tpl:cursor-pointer tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)] hover:tpl:bg-[var(--tpl-bg-hover)] hover:tpl:text-[var(--tpl-text)] active:tpl:bg-[var(--tpl-bg-active)]", Tr = "tpl:w-10 tpl:h-8 tpl:text-center tpl:text-xs tpl:font-medium tpl:border-y tpl:border-x-0 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text)] tpl:bg-[var(--tpl-bg)] tpl:outline-none tpl:transition-all tpl:duration-[120ms] focus:tpl:border-[var(--tpl-primary)] focus:tpl:shadow-[var(--tpl-ring)]", Er = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
982
1007
|
__name: "SpacingControl",
|
|
983
1008
|
props: {
|
|
984
1009
|
modelValue: {},
|
|
@@ -986,7 +1011,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
986
1011
|
},
|
|
987
1012
|
emits: ["update:modelValue"],
|
|
988
1013
|
setup(t, { emit: n }) {
|
|
989
|
-
let r = t, i = n, { t: o } =
|
|
1014
|
+
let r = t, i = n, { t: o } = z(), s = m(() => r.modelValue.top === r.modelValue.right && r.modelValue.right === r.modelValue.bottom && r.modelValue.bottom === r.modelValue.left), l = c(s.value);
|
|
990
1015
|
a(s, (e) => {
|
|
991
1016
|
!e && l.value && (l.value = !1);
|
|
992
1017
|
});
|
|
@@ -1025,130 +1050,130 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1025
1050
|
});
|
|
1026
1051
|
}
|
|
1027
1052
|
}
|
|
1028
|
-
return (n, r) => (e(), g("div",
|
|
1029
|
-
h("div",
|
|
1053
|
+
return (n, r) => (e(), g("div", ir, [h("label", ar, w(t.label), 1), h("div", or, [
|
|
1054
|
+
h("div", sr, [
|
|
1030
1055
|
h("button", {
|
|
1031
1056
|
"aria-label": S(o).spacingControl.decreaseTop,
|
|
1032
|
-
class: d([
|
|
1057
|
+
class: d([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1033
1058
|
onClick: r[0] ||= (e) => u("top", -1)
|
|
1034
|
-
}, [E(S(
|
|
1059
|
+
}, [E(S(V), {
|
|
1035
1060
|
size: 12,
|
|
1036
1061
|
"stroke-width": 2
|
|
1037
|
-
})], 10,
|
|
1062
|
+
})], 10, cr),
|
|
1038
1063
|
h("input", {
|
|
1039
1064
|
type: "number",
|
|
1040
|
-
class: d(
|
|
1065
|
+
class: d(Tr),
|
|
1041
1066
|
value: t.modelValue.top,
|
|
1042
1067
|
"aria-label": S(o).spacingControl.top,
|
|
1043
1068
|
min: "0",
|
|
1044
1069
|
onInput: r[1] ||= (e) => f("top", Number(e.target.value))
|
|
1045
|
-
}, null, 40,
|
|
1070
|
+
}, null, 40, lr),
|
|
1046
1071
|
h("button", {
|
|
1047
1072
|
"aria-label": S(o).spacingControl.increaseTop,
|
|
1048
|
-
class: d([
|
|
1073
|
+
class: d([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
1049
1074
|
onClick: r[2] ||= (e) => u("top", 1)
|
|
1050
|
-
}, [E(S(
|
|
1075
|
+
}, [E(S(X), {
|
|
1051
1076
|
size: 12,
|
|
1052
1077
|
"stroke-width": 2
|
|
1053
|
-
})], 10,
|
|
1078
|
+
})], 10, ur)
|
|
1054
1079
|
]),
|
|
1055
|
-
h("div",
|
|
1056
|
-
h("div",
|
|
1080
|
+
h("div", dr, [
|
|
1081
|
+
h("div", fr, [
|
|
1057
1082
|
h("button", {
|
|
1058
1083
|
"aria-label": S(o).spacingControl.decreaseLeft,
|
|
1059
|
-
class: d([
|
|
1084
|
+
class: d([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1060
1085
|
onClick: r[3] ||= (e) => u("left", -1)
|
|
1061
|
-
}, [E(S(
|
|
1086
|
+
}, [E(S(V), {
|
|
1062
1087
|
size: 12,
|
|
1063
1088
|
"stroke-width": 2
|
|
1064
|
-
})], 10,
|
|
1089
|
+
})], 10, pr),
|
|
1065
1090
|
h("input", {
|
|
1066
1091
|
type: "number",
|
|
1067
|
-
class: d(
|
|
1092
|
+
class: d(Tr),
|
|
1068
1093
|
value: t.modelValue.left,
|
|
1069
1094
|
"aria-label": S(o).spacingControl.left,
|
|
1070
1095
|
min: "0",
|
|
1071
1096
|
onInput: r[4] ||= (e) => f("left", Number(e.target.value))
|
|
1072
|
-
}, null, 40,
|
|
1097
|
+
}, null, 40, mr),
|
|
1073
1098
|
h("button", {
|
|
1074
1099
|
"aria-label": S(o).spacingControl.increaseLeft,
|
|
1075
|
-
class: d([
|
|
1100
|
+
class: d([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
1076
1101
|
onClick: r[5] ||= (e) => u("left", 1)
|
|
1077
|
-
}, [E(S(
|
|
1102
|
+
}, [E(S(X), {
|
|
1078
1103
|
size: 12,
|
|
1079
1104
|
"stroke-width": 2
|
|
1080
|
-
})], 10,
|
|
1105
|
+
})], 10, hr)
|
|
1081
1106
|
]),
|
|
1082
1107
|
h("button", {
|
|
1083
1108
|
class: d(["tpl:flex tpl:h-8 tpl:w-8 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", l.value ? "tpl:border-[var(--tpl-primary)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]" : "tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text-muted)] hover:tpl:bg-[var(--tpl-bg-hover)]"]),
|
|
1084
1109
|
"aria-label": l.value ? S(o).spacingControl.unlock : S(o).spacingControl.lockAll,
|
|
1085
1110
|
title: l.value ? S(o).spacingControl.unlock : S(o).spacingControl.lockAll,
|
|
1086
1111
|
onClick: p
|
|
1087
|
-
}, [l.value ? (e(), x(S(
|
|
1112
|
+
}, [l.value ? (e(), x(S(mt), {
|
|
1088
1113
|
key: 0,
|
|
1089
1114
|
size: 14,
|
|
1090
1115
|
"stroke-width": 2
|
|
1091
|
-
})) : (e(), x(S(
|
|
1116
|
+
})) : (e(), x(S(pt), {
|
|
1092
1117
|
key: 1,
|
|
1093
1118
|
size: 14,
|
|
1094
1119
|
"stroke-width": 2
|
|
1095
|
-
}))], 10,
|
|
1096
|
-
h("div",
|
|
1120
|
+
}))], 10, gr),
|
|
1121
|
+
h("div", _r, [
|
|
1097
1122
|
h("button", {
|
|
1098
1123
|
"aria-label": S(o).spacingControl.decreaseRight,
|
|
1099
|
-
class: d([
|
|
1124
|
+
class: d([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1100
1125
|
onClick: r[6] ||= (e) => u("right", -1)
|
|
1101
|
-
}, [E(S(
|
|
1126
|
+
}, [E(S(V), {
|
|
1102
1127
|
size: 12,
|
|
1103
1128
|
"stroke-width": 2
|
|
1104
|
-
})], 10,
|
|
1129
|
+
})], 10, vr),
|
|
1105
1130
|
h("input", {
|
|
1106
1131
|
type: "number",
|
|
1107
|
-
class: d(
|
|
1132
|
+
class: d(Tr),
|
|
1108
1133
|
value: t.modelValue.right,
|
|
1109
1134
|
"aria-label": S(o).spacingControl.right,
|
|
1110
1135
|
min: "0",
|
|
1111
1136
|
onInput: r[7] ||= (e) => f("right", Number(e.target.value))
|
|
1112
|
-
}, null, 40,
|
|
1137
|
+
}, null, 40, yr),
|
|
1113
1138
|
h("button", {
|
|
1114
1139
|
"aria-label": S(o).spacingControl.increaseRight,
|
|
1115
|
-
class: d([
|
|
1140
|
+
class: d([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
1116
1141
|
onClick: r[8] ||= (e) => u("right", 1)
|
|
1117
|
-
}, [E(S(
|
|
1142
|
+
}, [E(S(X), {
|
|
1118
1143
|
size: 12,
|
|
1119
1144
|
"stroke-width": 2
|
|
1120
|
-
})], 10,
|
|
1145
|
+
})], 10, br)
|
|
1121
1146
|
])
|
|
1122
1147
|
]),
|
|
1123
|
-
h("div",
|
|
1148
|
+
h("div", xr, [
|
|
1124
1149
|
h("button", {
|
|
1125
1150
|
"aria-label": S(o).spacingControl.decreaseBottom,
|
|
1126
|
-
class: d([
|
|
1151
|
+
class: d([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1127
1152
|
onClick: r[9] ||= (e) => u("bottom", -1)
|
|
1128
|
-
}, [E(S(
|
|
1153
|
+
}, [E(S(V), {
|
|
1129
1154
|
size: 12,
|
|
1130
1155
|
"stroke-width": 2
|
|
1131
|
-
})], 10,
|
|
1156
|
+
})], 10, Sr),
|
|
1132
1157
|
h("input", {
|
|
1133
1158
|
type: "number",
|
|
1134
|
-
class: d(
|
|
1159
|
+
class: d(Tr),
|
|
1135
1160
|
value: t.modelValue.bottom,
|
|
1136
1161
|
"aria-label": S(o).spacingControl.bottom,
|
|
1137
1162
|
min: "0",
|
|
1138
1163
|
onInput: r[10] ||= (e) => f("bottom", Number(e.target.value))
|
|
1139
|
-
}, null, 40,
|
|
1164
|
+
}, null, 40, Cr),
|
|
1140
1165
|
h("button", {
|
|
1141
1166
|
"aria-label": S(o).spacingControl.increaseBottom,
|
|
1142
|
-
class: d([
|
|
1167
|
+
class: d([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
1143
1168
|
onClick: r[11] ||= (e) => u("bottom", 1)
|
|
1144
|
-
}, [E(S(
|
|
1169
|
+
}, [E(S(X), {
|
|
1145
1170
|
size: 12,
|
|
1146
1171
|
"stroke-width": 2
|
|
1147
|
-
})], 10,
|
|
1172
|
+
})], 10, wr)
|
|
1148
1173
|
])
|
|
1149
1174
|
])]));
|
|
1150
1175
|
}
|
|
1151
|
-
}), [["__scopeId", "data-v-9a9c8a07"]]),
|
|
1176
|
+
}), [["__scopeId", "data-v-9a9c8a07"]]), Dr = { class: "tpl:mt-3" }, Or = /* @__PURE__ */ f({
|
|
1152
1177
|
__name: "CollapsibleSection",
|
|
1153
1178
|
props: {
|
|
1154
1179
|
title: {},
|
|
@@ -1161,11 +1186,11 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1161
1186
|
type: "button",
|
|
1162
1187
|
class: "tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-center tpl:gap-1.5 tpl:border-none tpl:bg-transparent tpl:p-0 tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]",
|
|
1163
1188
|
onClick: i[0] ||= (e) => r.$emit("toggle")
|
|
1164
|
-
}, [E(S(
|
|
1189
|
+
}, [E(S(ze), {
|
|
1165
1190
|
class: d(["tpl:transition-transform tpl:duration-200", n.open ? "tpl:rotate-0" : "tpl:-rotate-90"]),
|
|
1166
1191
|
size: 12,
|
|
1167
1192
|
"stroke-width": 2
|
|
1168
|
-
}, null, 8, ["class"]), h("span", null, w(n.title), 1)]), t(h("div",
|
|
1193
|
+
}, null, 8, ["class"]), h("span", null, w(n.title), 1)]), t(h("div", Dr, [s(r.$slots, "default")], 512), [[y, n.open]])], 2));
|
|
1169
1194
|
}
|
|
1170
1195
|
}), kr = { class: "tpl:mt-4" }, Ar = { class: "tpl:space-y-2" }, jr = ["checked", "onChange"], Mr = ["value", "placeholder"], Nr = { class: "tpl:space-y-2" }, Pr = ["value"], Fr = { value: "" }, Ir = ["label"], Lr = ["value"], Rr = ["value"], zr = {
|
|
1171
1196
|
key: 0,
|
|
@@ -1187,29 +1212,29 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1187
1212
|
},
|
|
1188
1213
|
emits: ["update"],
|
|
1189
1214
|
setup(n, { emit: s }) {
|
|
1190
|
-
let f = n, p = s, { t: y } =
|
|
1215
|
+
let f = n, p = s, { t: y } = z(), b = D(Ne, []), C = D(Pe, !1), T = i(/* @__PURE__ */ new Set()), O = c(!1), A = c(""), j = c(""), ee = [
|
|
1191
1216
|
{
|
|
1192
1217
|
key: "desktop",
|
|
1193
|
-
icon:
|
|
1218
|
+
icon: ht,
|
|
1194
1219
|
labelKey: "showOnDesktop"
|
|
1195
1220
|
},
|
|
1196
1221
|
{
|
|
1197
1222
|
key: "tablet",
|
|
1198
|
-
icon:
|
|
1223
|
+
icon: wt,
|
|
1199
1224
|
labelKey: "showOnTablet"
|
|
1200
1225
|
},
|
|
1201
1226
|
{
|
|
1202
1227
|
key: "mobile",
|
|
1203
|
-
icon:
|
|
1228
|
+
icon: bt,
|
|
1204
1229
|
labelKey: "showOnMobile"
|
|
1205
1230
|
}
|
|
1206
1231
|
];
|
|
1207
|
-
function
|
|
1232
|
+
function M(e) {
|
|
1208
1233
|
T.has(e) ? T.delete(e) : T.add(e);
|
|
1209
1234
|
}
|
|
1210
|
-
let
|
|
1211
|
-
function
|
|
1212
|
-
O.value = !0,
|
|
1235
|
+
let te = m(() => b.length > 0 || C), N = m(() => f.block.displayCondition ? !b.some((e) => e.label === f.block.displayCondition?.label) : !1);
|
|
1236
|
+
function P() {
|
|
1237
|
+
O.value = !0, N.value && f.block.displayCondition ? (A.value = f.block.displayCondition.before, j.value = f.block.displayCondition.after ?? "") : (A.value = "", j.value = "");
|
|
1213
1238
|
}
|
|
1214
1239
|
function F() {
|
|
1215
1240
|
A.value.trim() && (p("update", { displayCondition: {
|
|
@@ -1223,7 +1248,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1223
1248
|
O.value = !1, A.value = "", j.value = "";
|
|
1224
1249
|
return;
|
|
1225
1250
|
}
|
|
1226
|
-
|
|
1251
|
+
N.value && (A.value = e.before, j.value = e.after ?? "");
|
|
1227
1252
|
}, { immediate: !0 });
|
|
1228
1253
|
let ne = m(() => {
|
|
1229
1254
|
let e = {};
|
|
@@ -1251,17 +1276,17 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1251
1276
|
t[e] = !t[e], p("update", { visibility: t });
|
|
1252
1277
|
}
|
|
1253
1278
|
return (i, a) => (e(), g("div", { class: d(["tpl:flex tpl:flex-col", n.isFirstSection ? "" : "tpl:mt-4"]) }, [
|
|
1254
|
-
E(
|
|
1279
|
+
E(Or, {
|
|
1255
1280
|
title: S(y).blockSettings.spacing,
|
|
1256
1281
|
open: T.has("spacing"),
|
|
1257
1282
|
"no-border": n.isFirstSection,
|
|
1258
|
-
onToggle: a[2] ||= (e) =>
|
|
1283
|
+
onToggle: a[2] ||= (e) => M("spacing")
|
|
1259
1284
|
}, {
|
|
1260
|
-
default: k(() => [E(
|
|
1285
|
+
default: k(() => [E(Er, {
|
|
1261
1286
|
label: S(y).blockSettings.padding,
|
|
1262
1287
|
"model-value": n.block.styles.padding,
|
|
1263
1288
|
"onUpdate:modelValue": a[0] ||= (e) => I("padding", e)
|
|
1264
|
-
}, null, 8, ["label", "model-value"]), h("div", kr, [E(
|
|
1289
|
+
}, null, 8, ["label", "model-value"]), h("div", kr, [E(Er, {
|
|
1265
1290
|
label: S(y).blockSettings.margin,
|
|
1266
1291
|
"model-value": n.block.styles.margin,
|
|
1267
1292
|
"onUpdate:modelValue": a[1] ||= (e) => I("margin", e)
|
|
@@ -1272,24 +1297,24 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1272
1297
|
"open",
|
|
1273
1298
|
"no-border"
|
|
1274
1299
|
]),
|
|
1275
|
-
E(
|
|
1300
|
+
E(Or, {
|
|
1276
1301
|
title: S(y).blockSettings.background,
|
|
1277
1302
|
open: T.has("bg"),
|
|
1278
|
-
onToggle: a[4] ||= (e) =>
|
|
1303
|
+
onToggle: a[4] ||= (e) => M("bg")
|
|
1279
1304
|
}, {
|
|
1280
|
-
default: k(() => [h("label", { class: d(S(
|
|
1305
|
+
default: k(() => [h("label", { class: d(S(W)) }, w(S(y).blockSettings.color), 3), E(q, {
|
|
1281
1306
|
size: "large",
|
|
1282
1307
|
"model-value": n.block.styles.backgroundColor || S("#ffffff"),
|
|
1283
1308
|
"onUpdate:modelValue": a[3] ||= (e) => I("backgroundColor", e)
|
|
1284
1309
|
}, null, 8, ["model-value"])]),
|
|
1285
1310
|
_: 1
|
|
1286
1311
|
}, 8, ["title", "open"]),
|
|
1287
|
-
E(
|
|
1312
|
+
E(Or, {
|
|
1288
1313
|
title: S(y).blockSettings.display,
|
|
1289
1314
|
open: T.has("display"),
|
|
1290
|
-
onToggle: a[5] ||= (e) =>
|
|
1315
|
+
onToggle: a[5] ||= (e) => M("display")
|
|
1291
1316
|
}, {
|
|
1292
|
-
default: k(() => [h("div", Ar, [(e(), g(_, null, o(
|
|
1317
|
+
default: k(() => [h("div", Ar, [(e(), g(_, null, o(ee, (t) => h("label", {
|
|
1293
1318
|
key: t.key,
|
|
1294
1319
|
class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-xs tpl:text-[var(--tpl-text)]"
|
|
1295
1320
|
}, [
|
|
@@ -1307,33 +1332,33 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1307
1332
|
])), 64))])]),
|
|
1308
1333
|
_: 1
|
|
1309
1334
|
}, 8, ["title", "open"]),
|
|
1310
|
-
E(
|
|
1335
|
+
E(Or, {
|
|
1311
1336
|
title: S(y).blockSettings.customCss,
|
|
1312
1337
|
open: T.has("css"),
|
|
1313
|
-
onToggle: a[7] ||= (e) =>
|
|
1338
|
+
onToggle: a[7] ||= (e) => M("css")
|
|
1314
1339
|
}, {
|
|
1315
|
-
default: k(() => [h("label", { class: d(S(
|
|
1340
|
+
default: k(() => [h("label", { class: d(S(W)) }, w(S(y).blockSettings.css), 3), h("textarea", {
|
|
1316
1341
|
value: n.block.customCss || "",
|
|
1317
1342
|
placeholder: S(y).blockSettings.cssPlaceholder,
|
|
1318
1343
|
rows: "3",
|
|
1319
|
-
class: d(S(
|
|
1344
|
+
class: d(S(ot)),
|
|
1320
1345
|
onInput: a[6] ||= (e) => p("update", { customCss: e.target.value })
|
|
1321
1346
|
}, null, 42, Mr)]),
|
|
1322
1347
|
_: 1
|
|
1323
1348
|
}, 8, ["title", "open"]),
|
|
1324
|
-
|
|
1349
|
+
te.value ? (e(), x(Or, {
|
|
1325
1350
|
key: 0,
|
|
1326
1351
|
title: S(y).blockSettings.displayCondition,
|
|
1327
1352
|
open: T.has("condition"),
|
|
1328
|
-
onToggle: a[11] ||= (e) =>
|
|
1353
|
+
onToggle: a[11] ||= (e) => M("condition")
|
|
1329
1354
|
}, {
|
|
1330
1355
|
default: k(() => [h("div", Nr, [h("select", {
|
|
1331
1356
|
class: d(["tpl:w-full tpl:rounded-md tpl:border tpl:px-2.5 tpl:py-2 tpl:text-xs tpl:outline-none tpl:transition-all tpl:duration-150 tpl:focus:border-[var(--tpl-primary)] tpl:focus:shadow-[0_0_0_3px_var(--tpl-primary-light)]", n.block.displayCondition ? "tpl:border-[var(--tpl-primary)] tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-text)]" : "tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]"]),
|
|
1332
|
-
value: O.value ||
|
|
1357
|
+
value: O.value || N.value ? "__custom__" : n.block.displayCondition?.label ?? "",
|
|
1333
1358
|
onChange: a[8] ||= (e) => {
|
|
1334
1359
|
let t = e.target.value;
|
|
1335
1360
|
if (t === "__custom__") {
|
|
1336
|
-
|
|
1361
|
+
P();
|
|
1337
1362
|
return;
|
|
1338
1363
|
}
|
|
1339
1364
|
if (O.value = !1, !t) {
|
|
@@ -1356,16 +1381,16 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1356
1381
|
value: t.label
|
|
1357
1382
|
}, w(t.label), 9, Rr))), 128))], 64))), 128)),
|
|
1358
1383
|
S(C) ? (e(), g("option", zr, w(S(y).blockSettings.customCondition), 1)) : v("", !0)
|
|
1359
|
-
], 42, Pr), O.value ||
|
|
1384
|
+
], 42, Pr), O.value || N.value ? (e(), g("div", Br, [
|
|
1360
1385
|
h("div", null, [h("label", Vr, w(S(y).blockSettings.customConditionBefore), 1), t(h("textarea", {
|
|
1361
1386
|
"onUpdate:modelValue": a[9] ||= (e) => A.value = e,
|
|
1362
1387
|
rows: "2",
|
|
1363
|
-
class: d(S(
|
|
1388
|
+
class: d(S(ot))
|
|
1364
1389
|
}, null, 2), [[u, A.value]])]),
|
|
1365
1390
|
h("div", null, [h("label", Hr, w(S(y).blockSettings.customConditionAfter), 1), t(h("textarea", {
|
|
1366
1391
|
"onUpdate:modelValue": a[10] ||= (e) => j.value = e,
|
|
1367
1392
|
rows: "2",
|
|
1368
|
-
class: d(S(
|
|
1393
|
+
class: d(S(ot))
|
|
1369
1394
|
}, null, 2), [[u, j.value]])]),
|
|
1370
1395
|
h("div", Ur, [h("button", {
|
|
1371
1396
|
type: "button",
|
|
@@ -1373,7 +1398,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1373
1398
|
disabled: !A.value.trim(),
|
|
1374
1399
|
onClick: F
|
|
1375
1400
|
}, w(S(y).blockSettings.applyCondition), 9, Wr)])
|
|
1376
|
-
])) : n.block.displayCondition && !
|
|
1401
|
+
])) : n.block.displayCondition && !N.value ? (e(), g(_, { key: 1 }, [n.block.displayCondition.description ? (e(), g("p", Gr, w(n.block.displayCondition.description), 1)) : v("", !0), h("div", Kr, [h("pre", qr, w(n.block.displayCondition.before), 1), n.block.displayCondition.after ? (e(), g("pre", Jr, w(n.block.displayCondition.after), 1)) : v("", !0)])], 64)) : v("", !0)])]),
|
|
1377
1402
|
_: 1
|
|
1378
1403
|
}, 8, ["title", "open"])) : v("", !0)
|
|
1379
1404
|
], 2));
|
|
@@ -1394,13 +1419,13 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1394
1419
|
},
|
|
1395
1420
|
emits: ["update:modelValue"],
|
|
1396
1421
|
setup(t, { emit: n }) {
|
|
1397
|
-
let r = n, { t: i } =
|
|
1422
|
+
let r = n, { t: i } = z();
|
|
1398
1423
|
return (n, a) => (e(), g("div", {
|
|
1399
1424
|
class: "tpl:mb-3.5",
|
|
1400
1425
|
title: t.readOnly ? S(i).customBlocks.dataSource.readOnlyTooltip : void 0
|
|
1401
1426
|
}, [h("label", { class: d(["tpl:flex tpl:items-center tpl:justify-between tpl:gap-2", t.readOnly ? "tpl:cursor-not-allowed" : "tpl:cursor-pointer"]) }, [h("span", Zr, [
|
|
1402
1427
|
l(w(t.field.label) + " ", 1),
|
|
1403
|
-
t.readOnly ? (e(), x(S(
|
|
1428
|
+
t.readOnly ? (e(), x(S(mt), {
|
|
1404
1429
|
key: 0,
|
|
1405
1430
|
size: 12,
|
|
1406
1431
|
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]"
|
|
@@ -1431,9 +1456,9 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1431
1456
|
readOnly: { type: Boolean }
|
|
1432
1457
|
},
|
|
1433
1458
|
setup(t) {
|
|
1434
|
-
return (n, r) => (e(), g("div", ti, [h("label", { class: d(S(
|
|
1459
|
+
return (n, r) => (e(), g("div", ti, [h("label", { class: d(S(W)) }, [
|
|
1435
1460
|
l(w(t.label) + " ", 1),
|
|
1436
|
-
t.readOnly ? (e(), x(S(
|
|
1461
|
+
t.readOnly ? (e(), x(S(mt), {
|
|
1437
1462
|
key: 0,
|
|
1438
1463
|
size: 12,
|
|
1439
1464
|
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]"
|
|
@@ -1450,13 +1475,13 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1450
1475
|
},
|
|
1451
1476
|
emits: ["update:modelValue"],
|
|
1452
1477
|
setup(t, { emit: n }) {
|
|
1453
|
-
let r = n, { t: i } =
|
|
1478
|
+
let r = n, { t: i } = z();
|
|
1454
1479
|
return (n, a) => (e(), x($, {
|
|
1455
1480
|
label: t.field.label,
|
|
1456
1481
|
required: t.field.required,
|
|
1457
1482
|
"read-only": t.readOnly
|
|
1458
1483
|
}, {
|
|
1459
|
-
default: k(() => [E(
|
|
1484
|
+
default: k(() => [E(q, {
|
|
1460
1485
|
"model-value": t.modelValue || S("#000000"),
|
|
1461
1486
|
placeholder: t.field.placeholder || S("#000000"),
|
|
1462
1487
|
disabled: t.readOnly,
|
|
@@ -1488,7 +1513,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1488
1513
|
},
|
|
1489
1514
|
emits: ["update:modelValue"],
|
|
1490
1515
|
setup(t, { emit: n }) {
|
|
1491
|
-
let r = n, { t: i } =
|
|
1516
|
+
let r = n, { t: i } = z(), a = D(Ee, null), o = m(() => !!a);
|
|
1492
1517
|
async function s() {
|
|
1493
1518
|
let e = await a?.({ accept: ["images"] });
|
|
1494
1519
|
e && r("update:modelValue", e.url);
|
|
@@ -1501,7 +1526,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1501
1526
|
default: k(() => [t.readOnly ? (e(), g("input", {
|
|
1502
1527
|
key: 0,
|
|
1503
1528
|
type: "url",
|
|
1504
|
-
class: d([S(
|
|
1529
|
+
class: d([S(U), "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1505
1530
|
value: t.modelValue,
|
|
1506
1531
|
placeholder: t.field.placeholder || "https://...",
|
|
1507
1532
|
disabled: "",
|
|
@@ -1509,7 +1534,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1509
1534
|
}, null, 10, ii)) : (e(), g("input", {
|
|
1510
1535
|
key: 1,
|
|
1511
1536
|
type: "url",
|
|
1512
|
-
class: d(S(
|
|
1537
|
+
class: d(S(U)),
|
|
1513
1538
|
value: t.modelValue,
|
|
1514
1539
|
placeholder: t.field.placeholder || "https://...",
|
|
1515
1540
|
onInput: a[0] ||= (e) => r("update:modelValue", e.target.value)
|
|
@@ -1517,7 +1542,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1517
1542
|
key: 2,
|
|
1518
1543
|
class: "tpl:mt-2 tpl:flex tpl:w-full tpl:items-center tpl:justify-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-150 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)] tpl:bg-[var(--tpl-bg)]",
|
|
1519
1544
|
onClick: a[1] ||= (e) => s()
|
|
1520
|
-
}, [E(S(
|
|
1545
|
+
}, [E(S(R), {
|
|
1521
1546
|
size: 14,
|
|
1522
1547
|
"stroke-width": 1.5
|
|
1523
1548
|
}), l(" " + w(S(i).image.browseMedia), 1)])) : v("", !0)]),
|
|
@@ -1545,7 +1570,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1545
1570
|
},
|
|
1546
1571
|
emits: ["update:modelValue"],
|
|
1547
1572
|
setup(t, { emit: n }) {
|
|
1548
|
-
let r = n, { t: i } =
|
|
1573
|
+
let r = n, { t: i } = z();
|
|
1549
1574
|
return (n, a) => (e(), x($, {
|
|
1550
1575
|
label: t.field.label,
|
|
1551
1576
|
required: t.field.required,
|
|
@@ -1553,7 +1578,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1553
1578
|
}, {
|
|
1554
1579
|
default: k(() => [h("input", {
|
|
1555
1580
|
type: "number",
|
|
1556
|
-
class: d([S(
|
|
1581
|
+
class: d([S(U), t.readOnly && "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1557
1582
|
value: t.modelValue,
|
|
1558
1583
|
placeholder: t.field.placeholder,
|
|
1559
1584
|
min: t.field.min,
|
|
@@ -1582,7 +1607,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1582
1607
|
},
|
|
1583
1608
|
emits: ["update:modelValue"],
|
|
1584
1609
|
setup(t, { emit: n }) {
|
|
1585
|
-
let i = t, a = n, { t: s } =
|
|
1610
|
+
let i = t, a = n, { t: s } = z(), c = m(() => i.modelValue || []), u = m(() => !i.field.maxItems || c.value.length < i.field.maxItems), f = m(() => !i.field.minItems || c.value.length > i.field.minItems);
|
|
1586
1611
|
function p() {
|
|
1587
1612
|
if (!u.value || i.readOnly) return;
|
|
1588
1613
|
let e = {};
|
|
@@ -1615,7 +1640,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1615
1640
|
class: "tpl:flex tpl:size-6 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-150 tpl:hover:border-[var(--tpl-danger)] tpl:hover:bg-[var(--tpl-danger-light)] tpl:hover:text-[var(--tpl-danger)]",
|
|
1616
1641
|
title: S(s).customBlocks.fields.removeItem,
|
|
1617
1642
|
onClick: (e) => y(i)
|
|
1618
|
-
}, [E(S(
|
|
1643
|
+
}, [E(S(Qe), {
|
|
1619
1644
|
size: 12,
|
|
1620
1645
|
"stroke-width": 2
|
|
1621
1646
|
})], 8, fi)) : v("", !0)]), (e(!0), g(_, null, o(t.field.fields, (a) => (e(), x(r(S(Ci)(a.type)), {
|
|
@@ -1633,9 +1658,9 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1633
1658
|
u.value && !t.readOnly ? (e(), g("button", {
|
|
1634
1659
|
key: 0,
|
|
1635
1660
|
type: "button",
|
|
1636
|
-
class: d(S(
|
|
1661
|
+
class: d(S(at)),
|
|
1637
1662
|
onClick: p
|
|
1638
|
-
}, [E(S(
|
|
1663
|
+
}, [E(S(X), {
|
|
1639
1664
|
size: 14,
|
|
1640
1665
|
"stroke-width": 2
|
|
1641
1666
|
}), l(" " + w(S(s).customBlocks.fields.addItem), 1)], 2)) : v("", !0),
|
|
@@ -1661,14 +1686,14 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1661
1686
|
},
|
|
1662
1687
|
emits: ["update:modelValue"],
|
|
1663
1688
|
setup(t, { emit: n }) {
|
|
1664
|
-
let r = n, { t: i } =
|
|
1689
|
+
let r = n, { t: i } = z();
|
|
1665
1690
|
return (n, a) => (e(), x($, {
|
|
1666
1691
|
label: t.field.label,
|
|
1667
1692
|
required: t.field.required,
|
|
1668
1693
|
"read-only": t.readOnly
|
|
1669
1694
|
}, {
|
|
1670
1695
|
default: k(() => [h("select", {
|
|
1671
|
-
class: d([S(
|
|
1696
|
+
class: d([S(U), t.readOnly && "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1672
1697
|
value: t.modelValue,
|
|
1673
1698
|
disabled: t.readOnly,
|
|
1674
1699
|
title: t.readOnly ? S(i).customBlocks.dataSource.readOnlyTooltip : void 0,
|
|
@@ -1697,7 +1722,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1697
1722
|
},
|
|
1698
1723
|
emits: ["update:modelValue"],
|
|
1699
1724
|
setup(t, { emit: n }) {
|
|
1700
|
-
let r = n, { t: i } =
|
|
1725
|
+
let r = n, { t: i } = z();
|
|
1701
1726
|
return (n, a) => (e(), x($, {
|
|
1702
1727
|
label: t.field.label,
|
|
1703
1728
|
required: t.field.required,
|
|
@@ -1706,12 +1731,12 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1706
1731
|
default: k(() => [t.readOnly ? (e(), g("input", {
|
|
1707
1732
|
key: 0,
|
|
1708
1733
|
type: "text",
|
|
1709
|
-
class: d([S(
|
|
1734
|
+
class: d([S(U), "tpl:opacity-60 tpl:cursor-not-allowed"]),
|
|
1710
1735
|
value: t.modelValue,
|
|
1711
1736
|
placeholder: t.field.placeholder,
|
|
1712
1737
|
disabled: "",
|
|
1713
1738
|
title: S(i).customBlocks.dataSource.readOnlyTooltip
|
|
1714
|
-
}, null, 10, vi)) : (e(), x(
|
|
1739
|
+
}, null, 10, vi)) : (e(), x(Z, {
|
|
1715
1740
|
key: 1,
|
|
1716
1741
|
"model-value": t.modelValue,
|
|
1717
1742
|
placeholder: t.field.placeholder,
|
|
@@ -1739,7 +1764,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1739
1764
|
},
|
|
1740
1765
|
emits: ["update:modelValue"],
|
|
1741
1766
|
setup(t, { emit: n }) {
|
|
1742
|
-
let r = n, { t: i } =
|
|
1767
|
+
let r = n, { t: i } = z();
|
|
1743
1768
|
return (n, a) => (e(), x($, {
|
|
1744
1769
|
label: t.field.label,
|
|
1745
1770
|
required: t.field.required,
|
|
@@ -1753,7 +1778,7 @@ var qt = ["aria-label", "onKeydown"], Jt = ["data-tooltip"], Yt = ["data-tooltip
|
|
|
1753
1778
|
disabled: "",
|
|
1754
1779
|
title: S(i).customBlocks.dataSource.readOnlyTooltip,
|
|
1755
1780
|
class: d(xi)
|
|
1756
|
-
}, null, 8, bi)) : (e(), x(
|
|
1781
|
+
}, null, 8, bi)) : (e(), x(sn, {
|
|
1757
1782
|
key: 1,
|
|
1758
1783
|
"model-value": t.modelValue,
|
|
1759
1784
|
placeholder: t.field.placeholder,
|
|
@@ -1802,7 +1827,7 @@ var wi = {
|
|
|
1802
1827
|
props: { block: {} },
|
|
1803
1828
|
emits: ["updateFieldValues", "updateDataSourceFetched"],
|
|
1804
1829
|
setup(t, { emit: n }) {
|
|
1805
|
-
let i = t, a = n, { t: s } =
|
|
1830
|
+
let i = t, a = n, { t: s } = z(), c = D(ke, []), u = m(() => c.find((e) => e.type === i.block.customType)), { isFetching: d, fetchError: f, fetch: p, hasDataSource: y, needsFetch: b } = L({
|
|
1806
1831
|
definition: u,
|
|
1807
1832
|
block: m(() => i.block),
|
|
1808
1833
|
onUpdate: (e, t) => {
|
|
@@ -1830,7 +1855,7 @@ var wi = {
|
|
|
1830
1855
|
type: "button",
|
|
1831
1856
|
class: "tpl:flex tpl:w-full tpl:items-center tpl:justify-center tpl:gap-1.5 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-muted)] tpl:transition-all tpl:duration-150 tpl:hover:border-[var(--tpl-primary)] tpl:hover:text-[var(--tpl-primary)]",
|
|
1832
1857
|
onClick: i[1] ||= (...e) => S(p) && S(p)(...e)
|
|
1833
|
-
}, [E(S(
|
|
1858
|
+
}, [E(S(We), { size: 12 }), l(" " + w(S(s).customBlocks.dataSource.changeButton), 1)]))])), S(f) ? (e(), g("p", ji, [E(S(Be), {
|
|
1834
1859
|
size: 14,
|
|
1835
1860
|
class: "tpl:shrink-0"
|
|
1836
1861
|
}), l(" " + w(S(s).customBlocks.dataSource.fetchError), 1)])) : v("", !0)])) : v("", !0),
|
|
@@ -1853,12 +1878,12 @@ var wi = {
|
|
|
1853
1878
|
props: { block: {} },
|
|
1854
1879
|
emits: ["update"],
|
|
1855
1880
|
setup(t, { emit: n }) {
|
|
1856
|
-
let r = n, { t: i } =
|
|
1881
|
+
let r = n, { t: i } = z();
|
|
1857
1882
|
function a(e, t) {
|
|
1858
1883
|
r("update", { [e]: t });
|
|
1859
1884
|
}
|
|
1860
1885
|
return (n, r) => (e(), g(_, null, [
|
|
1861
|
-
h("div", Ni, [h("label", { class: d(S(
|
|
1886
|
+
h("div", Ni, [h("label", { class: d(S(W)) }, w(S(i).divider.style), 3), E(Y, {
|
|
1862
1887
|
options: [
|
|
1863
1888
|
{
|
|
1864
1889
|
value: "solid",
|
|
@@ -1876,18 +1901,18 @@ var wi = {
|
|
|
1876
1901
|
"model-value": t.block.lineStyle,
|
|
1877
1902
|
"onUpdate:modelValue": r[0] ||= (e) => a("lineStyle", e)
|
|
1878
1903
|
}, null, 8, ["options", "model-value"])]),
|
|
1879
|
-
h("div", Pi, [h("label", { class: d(S(
|
|
1904
|
+
h("div", Pi, [h("label", { class: d(S(W)) }, w(S(i).divider.color), 3), E(q, {
|
|
1880
1905
|
"model-value": t.block.color,
|
|
1881
1906
|
"onUpdate:modelValue": r[1] ||= (e) => a("color", e)
|
|
1882
1907
|
}, null, 8, ["model-value"])]),
|
|
1883
|
-
h("div", Fi, [h("label", { class: d(S(
|
|
1908
|
+
h("div", Fi, [h("label", { class: d(S(W)) }, w(S(i).divider.thickness), 3), h("div", Ii, [h("input", {
|
|
1884
1909
|
type: "number",
|
|
1885
|
-
class: d(S(
|
|
1910
|
+
class: d(S(K)),
|
|
1886
1911
|
value: t.block.thickness,
|
|
1887
1912
|
min: "1",
|
|
1888
1913
|
max: "10",
|
|
1889
1914
|
onInput: r[2] ||= (e) => a("thickness", Number(e.target.value))
|
|
1890
|
-
}, null, 42, Li), h("span", { class: d(S(
|
|
1915
|
+
}, null, 42, Li), h("span", { class: d(S(G)) }, "px", 2)])])
|
|
1891
1916
|
], 64));
|
|
1892
1917
|
}
|
|
1893
1918
|
}), zi = { class: "tpl:mb-3.5" }, Bi = ["value"], Vi = { class: "tpl:mt-1.5 tpl:flex tpl:items-start tpl:gap-1.5 tpl:text-[11px] tpl:text-[var(--tpl-text-dim)]" }, Hi = /* @__PURE__ */ f({
|
|
@@ -1895,17 +1920,17 @@ var wi = {
|
|
|
1895
1920
|
props: { block: {} },
|
|
1896
1921
|
emits: ["update"],
|
|
1897
1922
|
setup(t, { emit: n }) {
|
|
1898
|
-
let r = n, { t: i } =
|
|
1923
|
+
let r = n, { t: i } = z();
|
|
1899
1924
|
return (n, a) => (e(), g("div", zi, [
|
|
1900
|
-
h("label", { class: d(S(
|
|
1925
|
+
h("label", { class: d(S(W)) }, w(S(i).html.content), 3),
|
|
1901
1926
|
h("textarea", {
|
|
1902
1927
|
value: t.block.content,
|
|
1903
1928
|
placeholder: "<div>...</div>",
|
|
1904
1929
|
rows: "10",
|
|
1905
|
-
class: d(S(
|
|
1930
|
+
class: d(S(ot)),
|
|
1906
1931
|
onInput: a[0] ||= (e) => r("update", { content: e.target.value })
|
|
1907
1932
|
}, null, 42, Bi),
|
|
1908
|
-
h("p", Vi, [E(S(
|
|
1933
|
+
h("p", Vi, [E(S(Ke), {
|
|
1909
1934
|
size: 12,
|
|
1910
1935
|
class: "tpl:mt-0.5 tpl:shrink-0"
|
|
1911
1936
|
}), l(" " + w(S(i).html.sanitizationHint), 1)])
|
|
@@ -1922,7 +1947,7 @@ var wi = {
|
|
|
1922
1947
|
props: { block: {} },
|
|
1923
1948
|
emits: ["update"],
|
|
1924
1949
|
setup(t, { emit: n }) {
|
|
1925
|
-
let r = n, { t: i } =
|
|
1950
|
+
let r = n, { t: i } = z(), a = D(Ee, null), o = D(Le, P.liquid), s = m(() => !!a), u = c(!1), f = c(!1), { start: p } = we(() => {
|
|
1926
1951
|
u.value = !1;
|
|
1927
1952
|
}, 1e3, { immediate: !1 });
|
|
1928
1953
|
function y(e, t) {
|
|
@@ -1934,8 +1959,8 @@ var wi = {
|
|
|
1934
1959
|
}
|
|
1935
1960
|
return (n, r) => (e(), g(_, null, [
|
|
1936
1961
|
h("div", Ui, [
|
|
1937
|
-
h("label", { class: d(S(
|
|
1938
|
-
E(
|
|
1962
|
+
h("label", { class: d(S(W)) }, w(S(i).image.imageUrl), 3),
|
|
1963
|
+
E(Z, {
|
|
1939
1964
|
"model-value": t.block.src,
|
|
1940
1965
|
type: "url",
|
|
1941
1966
|
placeholder: S(i).image.imageUrlPlaceholder,
|
|
@@ -1955,21 +1980,21 @@ var wi = {
|
|
|
1955
1980
|
"background-color": "var(--tpl-bg)"
|
|
1956
1981
|
},
|
|
1957
1982
|
onClick: b
|
|
1958
|
-
}, [E(S(
|
|
1983
|
+
}, [E(S(R), {
|
|
1959
1984
|
size: 14,
|
|
1960
1985
|
"stroke-width": 1.5
|
|
1961
1986
|
}), l(" " + w(S(i).image.browseMedia), 1)])) : v("", !0)
|
|
1962
1987
|
]),
|
|
1963
|
-
S(
|
|
1988
|
+
S(te)(t.block.src, S(o)) ? (e(), g("div", Wi, [h("label", { class: d(S(W)) }, [l(w(S(i).image.placeholderUrl) + " ", 1), r[8] ||= h("span", { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, w("(optional)"), -1)], 2), h("input", {
|
|
1964
1989
|
type: "url",
|
|
1965
|
-
class: d(S(
|
|
1990
|
+
class: d(S(U)),
|
|
1966
1991
|
value: t.block.placeholderUrl || "",
|
|
1967
1992
|
placeholder: S(i).image.placeholderUrlPlaceholder,
|
|
1968
1993
|
onInput: r[1] ||= (e) => y("placeholderUrl", e.target.value)
|
|
1969
1994
|
}, null, 42, Gi)])) : v("", !0),
|
|
1970
1995
|
h("div", Ki, [
|
|
1971
|
-
h("label", { class: d(S(
|
|
1972
|
-
E(
|
|
1996
|
+
h("label", { class: d(S(W)) }, w(S(i).image.altText), 3),
|
|
1997
|
+
E(Z, {
|
|
1973
1998
|
"model-value": t.block.alt,
|
|
1974
1999
|
type: "text",
|
|
1975
2000
|
placeholder: S(i).image.altTextPlaceholder,
|
|
@@ -1989,8 +2014,8 @@ var wi = {
|
|
|
1989
2014
|
onChange: r[3] ||= (e) => y("decorative", e.target.checked)
|
|
1990
2015
|
}, null, 40, Ji), h("span", null, [l(w(S(i).image.decorative) + " ", 1), h("span", Yi, w(S(i).image.decorativeHint), 1)])])
|
|
1991
2016
|
]),
|
|
1992
|
-
h("div", Xi, [h("label", { class: d(S(
|
|
1993
|
-
class: d(S(
|
|
2017
|
+
h("div", Xi, [h("label", { class: d(S(W)) }, w(S(i).image.width), 3), h("select", {
|
|
2018
|
+
class: d(S(U)),
|
|
1994
2019
|
value: t.block.width,
|
|
1995
2020
|
onChange: r[4] ||= (e) => y("width", e.target.value === "full" ? "full" : Number(e.target.value))
|
|
1996
2021
|
}, [
|
|
@@ -1999,7 +2024,7 @@ var wi = {
|
|
|
1999
2024
|
r[10] ||= h("option", { value: "400" }, "400px", -1),
|
|
2000
2025
|
r[11] ||= h("option", { value: "500" }, "500px", -1)
|
|
2001
2026
|
], 42, Zi)]),
|
|
2002
|
-
h("div", $i, [h("label", { class: d(S(
|
|
2027
|
+
h("div", $i, [h("label", { class: d(S(W)) }, w(S(i).title.align), 3), E(Y, {
|
|
2003
2028
|
options: [
|
|
2004
2029
|
{
|
|
2005
2030
|
value: "left",
|
|
@@ -2018,8 +2043,8 @@ var wi = {
|
|
|
2018
2043
|
"onUpdate:modelValue": r[5] ||= (e) => y("align", e)
|
|
2019
2044
|
}, null, 8, ["options", "model-value"])]),
|
|
2020
2045
|
h("div", ea, [
|
|
2021
|
-
h("label", { class: d(S(
|
|
2022
|
-
E(
|
|
2046
|
+
h("label", { class: d(S(W)) }, w(S(i).image.linkUrl), 3),
|
|
2047
|
+
E(Z, {
|
|
2023
2048
|
"model-value": t.block.linkUrl || "",
|
|
2024
2049
|
type: "url",
|
|
2025
2050
|
placeholder: S(i).image.imageUrlPlaceholder,
|
|
@@ -2046,7 +2071,7 @@ var wi = {
|
|
|
2046
2071
|
},
|
|
2047
2072
|
emits: ["update"],
|
|
2048
2073
|
setup(t, { emit: n }) {
|
|
2049
|
-
let r = t, i = n, { t: a } =
|
|
2074
|
+
let r = t, i = n, { t: a } = z(), s = m(() => [
|
|
2050
2075
|
{
|
|
2051
2076
|
key: "openInNewTab",
|
|
2052
2077
|
label: a.menu.openInNewTab
|
|
@@ -2063,17 +2088,17 @@ var wi = {
|
|
|
2063
2088
|
{
|
|
2064
2089
|
value: "left",
|
|
2065
2090
|
label: a.title.alignLeft,
|
|
2066
|
-
icon:
|
|
2091
|
+
icon: Ze
|
|
2067
2092
|
},
|
|
2068
2093
|
{
|
|
2069
2094
|
value: "center",
|
|
2070
2095
|
label: a.title.alignCenter,
|
|
2071
|
-
icon:
|
|
2096
|
+
icon: Xe
|
|
2072
2097
|
},
|
|
2073
2098
|
{
|
|
2074
2099
|
value: "right",
|
|
2075
2100
|
label: a.title.alignRight,
|
|
2076
|
-
icon:
|
|
2101
|
+
icon: Ye
|
|
2077
2102
|
}
|
|
2078
2103
|
]);
|
|
2079
2104
|
function u(e, t) {
|
|
@@ -2081,7 +2106,7 @@ var wi = {
|
|
|
2081
2106
|
}
|
|
2082
2107
|
function f() {
|
|
2083
2108
|
let e = {
|
|
2084
|
-
id:
|
|
2109
|
+
id: M(),
|
|
2085
2110
|
text: "",
|
|
2086
2111
|
url: "",
|
|
2087
2112
|
openInNewTab: !1,
|
|
@@ -2100,26 +2125,26 @@ var wi = {
|
|
|
2100
2125
|
i("update", { items: r.block.items.filter((t) => t.id !== e) });
|
|
2101
2126
|
}
|
|
2102
2127
|
return (n, r) => (e(), g(_, null, [
|
|
2103
|
-
E(
|
|
2128
|
+
E(J, { label: S(a).menu.items }, {
|
|
2104
2129
|
default: k(() => [h("div", ia, [(e(!0), g(_, null, o(t.block.items, (n) => (e(), g("div", {
|
|
2105
2130
|
key: n.id,
|
|
2106
2131
|
class: "tpl:flex tpl:flex-col tpl:gap-1.5 tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-2"
|
|
2107
2132
|
}, [
|
|
2108
2133
|
h("div", aa, [h("input", {
|
|
2109
2134
|
type: "text",
|
|
2110
|
-
class: d([S(
|
|
2135
|
+
class: d([S(U), "tpl:flex-1"]),
|
|
2111
2136
|
value: n.text,
|
|
2112
2137
|
placeholder: S(a).menu.text,
|
|
2113
2138
|
onInput: (e) => p(n.id, "text", e.target.value)
|
|
2114
2139
|
}, null, 42, oa), h("button", {
|
|
2115
|
-
class: d(S(
|
|
2140
|
+
class: d(S(it)),
|
|
2116
2141
|
title: S(a).menu.removeItem,
|
|
2117
2142
|
onClick: (e) => v(n.id)
|
|
2118
|
-
}, [E(S(
|
|
2143
|
+
}, [E(S($e), {
|
|
2119
2144
|
size: 14,
|
|
2120
2145
|
"stroke-width": 2
|
|
2121
2146
|
})], 10, sa)]),
|
|
2122
|
-
E(
|
|
2147
|
+
E(Z, {
|
|
2123
2148
|
"model-value": n.url,
|
|
2124
2149
|
type: "url",
|
|
2125
2150
|
placeholder: S(a).menu.urlPlaceholder,
|
|
@@ -2138,23 +2163,23 @@ var wi = {
|
|
|
2138
2163
|
class: "tpl:accent-[var(--tpl-primary)]",
|
|
2139
2164
|
onChange: (e) => p(n.id, t.key, e.target.checked)
|
|
2140
2165
|
}, null, 40, la), l(" " + w(t.label), 1)]))), 128))]),
|
|
2141
|
-
h("div", ua, [h("label", { class: d([S(
|
|
2166
|
+
h("div", ua, [h("label", { class: d([S(W), "tpl:!mb-0"]) }, w(S(a).menu.color), 3), E(q, {
|
|
2142
2167
|
"swatch-only": "",
|
|
2143
2168
|
"model-value": n.color || t.block.linkColor || t.block.color,
|
|
2144
2169
|
"onUpdate:modelValue": (e) => p(n.id, "color", e)
|
|
2145
2170
|
}, null, 8, ["model-value", "onUpdate:modelValue"])])
|
|
2146
2171
|
]))), 128)), h("button", {
|
|
2147
|
-
class: d(S(
|
|
2172
|
+
class: d(S(at)),
|
|
2148
2173
|
onClick: f
|
|
2149
|
-
}, [E(S(
|
|
2174
|
+
}, [E(S(X), {
|
|
2150
2175
|
size: 14,
|
|
2151
2176
|
"stroke-width": 2
|
|
2152
2177
|
}), l(" " + w(S(a).menu.addItem), 1)], 2)])]),
|
|
2153
2178
|
_: 1
|
|
2154
2179
|
}, 8, ["label"]),
|
|
2155
|
-
E(
|
|
2180
|
+
E(J, { label: S(a).menu.fontFamily }, {
|
|
2156
2181
|
default: k(() => [h("select", {
|
|
2157
|
-
class: d(S(
|
|
2182
|
+
class: d(S(U)),
|
|
2158
2183
|
value: t.block.fontFamily || "",
|
|
2159
2184
|
onChange: r[0] ||= (e) => u("fontFamily", e.target.value || void 0)
|
|
2160
2185
|
}, [h("option", fa, w(S(a).title.inheritFont), 1), (e(!0), g(_, null, o(t.fontFamilies, (t) => (e(), g("option", {
|
|
@@ -2163,8 +2188,8 @@ var wi = {
|
|
|
2163
2188
|
}, w(t.label), 9, pa))), 128))], 42, da)]),
|
|
2164
2189
|
_: 1
|
|
2165
2190
|
}, 8, ["label"]),
|
|
2166
|
-
E(
|
|
2167
|
-
default: k(() => [E(
|
|
2191
|
+
E(J, { label: S(a).menu.fontSize }, {
|
|
2192
|
+
default: k(() => [E(lt, {
|
|
2168
2193
|
"model-value": t.block.fontSize,
|
|
2169
2194
|
min: 8,
|
|
2170
2195
|
max: 48,
|
|
@@ -2173,46 +2198,46 @@ var wi = {
|
|
|
2173
2198
|
}, null, 8, ["model-value"])]),
|
|
2174
2199
|
_: 1
|
|
2175
2200
|
}, 8, ["label"]),
|
|
2176
|
-
E(
|
|
2177
|
-
default: k(() => [E(
|
|
2201
|
+
E(J, { label: S(a).menu.color }, {
|
|
2202
|
+
default: k(() => [E(q, {
|
|
2178
2203
|
"model-value": t.block.color,
|
|
2179
2204
|
"onUpdate:modelValue": r[2] ||= (e) => u("color", e)
|
|
2180
2205
|
}, null, 8, ["model-value"])]),
|
|
2181
2206
|
_: 1
|
|
2182
2207
|
}, 8, ["label"]),
|
|
2183
|
-
E(
|
|
2184
|
-
default: k(() => [E(
|
|
2208
|
+
E(J, { label: S(a).menu.linkColor }, {
|
|
2209
|
+
default: k(() => [E(q, {
|
|
2185
2210
|
"model-value": t.block.linkColor || t.block.color,
|
|
2186
2211
|
"onUpdate:modelValue": r[3] ||= (e) => u("linkColor", e || void 0)
|
|
2187
2212
|
}, null, 8, ["model-value"])]),
|
|
2188
2213
|
_: 1
|
|
2189
2214
|
}, 8, ["label"]),
|
|
2190
|
-
E(
|
|
2191
|
-
default: k(() => [E(
|
|
2215
|
+
E(J, { label: S(a).menu.textAlign }, {
|
|
2216
|
+
default: k(() => [E(Y, {
|
|
2192
2217
|
options: c.value,
|
|
2193
2218
|
"model-value": t.block.textAlign,
|
|
2194
2219
|
"onUpdate:modelValue": r[4] ||= (e) => u("textAlign", e)
|
|
2195
2220
|
}, null, 8, ["options", "model-value"])]),
|
|
2196
2221
|
_: 1
|
|
2197
2222
|
}, 8, ["label"]),
|
|
2198
|
-
E(
|
|
2223
|
+
E(J, { label: S(a).menu.separator }, {
|
|
2199
2224
|
default: k(() => [h("input", {
|
|
2200
2225
|
type: "text",
|
|
2201
|
-
class: d(S(
|
|
2226
|
+
class: d(S(U)),
|
|
2202
2227
|
value: t.block.separator,
|
|
2203
2228
|
onInput: r[5] ||= (e) => u("separator", e.target.value)
|
|
2204
2229
|
}, null, 42, ma)]),
|
|
2205
2230
|
_: 1
|
|
2206
2231
|
}, 8, ["label"]),
|
|
2207
|
-
E(
|
|
2208
|
-
default: k(() => [E(
|
|
2232
|
+
E(J, { label: S(a).menu.separatorColor }, {
|
|
2233
|
+
default: k(() => [E(q, {
|
|
2209
2234
|
"model-value": t.block.separatorColor,
|
|
2210
2235
|
"onUpdate:modelValue": r[6] ||= (e) => u("separatorColor", e)
|
|
2211
2236
|
}, null, 8, ["model-value"])]),
|
|
2212
2237
|
_: 1
|
|
2213
2238
|
}, 8, ["label"]),
|
|
2214
|
-
E(
|
|
2215
|
-
default: k(() => [E(
|
|
2239
|
+
E(J, { label: S(a).menu.spacing }, {
|
|
2240
|
+
default: k(() => [E(lt, {
|
|
2216
2241
|
"model-value": t.block.spacing,
|
|
2217
2242
|
min: 0,
|
|
2218
2243
|
max: 50,
|
|
@@ -2228,7 +2253,7 @@ var wi = {
|
|
|
2228
2253
|
props: { block: {} },
|
|
2229
2254
|
emits: ["update"],
|
|
2230
2255
|
setup(t, { emit: n }) {
|
|
2231
|
-
let r = n, { t: i } =
|
|
2256
|
+
let r = n, { t: i } = z(), a = m(() => [
|
|
2232
2257
|
{
|
|
2233
2258
|
value: "1",
|
|
2234
2259
|
label: i.section.column1
|
|
@@ -2250,8 +2275,8 @@ var wi = {
|
|
|
2250
2275
|
label: i.section.ratio21
|
|
2251
2276
|
}
|
|
2252
2277
|
]);
|
|
2253
|
-
return (n, s) => (e(), g("div", ga, [h("label", { class: d(S(
|
|
2254
|
-
class: d(S(
|
|
2278
|
+
return (n, s) => (e(), g("div", ga, [h("label", { class: d(S(W)) }, w(S(i).section.columns), 3), h("select", {
|
|
2279
|
+
class: d(S(U)),
|
|
2255
2280
|
value: t.block.columns,
|
|
2256
2281
|
onChange: s[0] ||= (e) => r("update", { columns: e.target.value })
|
|
2257
2282
|
}, [(e(!0), g(_, null, o(a.value, (t) => (e(), g("option", {
|
|
@@ -2259,18 +2284,18 @@ var wi = {
|
|
|
2259
2284
|
value: t.value
|
|
2260
2285
|
}, w(t.label), 9, va))), 128))], 42, _a)]));
|
|
2261
2286
|
}
|
|
2262
|
-
}), ba = { class: "tpl:mb-3.5" }, xa = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, Sa = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ca = ["value", "onChange"], wa = ["value"], Ta = ["title", "onClick"], Ea = { class: "tpl:mb-3.5" }, Da = { class: "tpl:mb-3.5" },
|
|
2287
|
+
}), ba = { class: "tpl:mb-3.5" }, xa = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, Sa = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Ca = ["value", "onChange"], wa = ["value"], Ta = ["title", "onClick"], Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = { value: "solid" }, ka = { value: "outlined" }, Aa = { value: "rounded" }, ja = { value: "square" }, Ma = { value: "circle" }, Na = { class: "tpl:mb-3.5" }, Pa = { class: "tpl:mb-3.5" }, Fa = { class: "tpl:flex tpl:items-stretch" }, Ia = ["value"], La = { class: "tpl:mb-3.5" }, Ra = /* @__PURE__ */ f({
|
|
2263
2288
|
__name: "SocialToolbar",
|
|
2264
2289
|
props: { block: {} },
|
|
2265
2290
|
emits: ["update"],
|
|
2266
2291
|
setup(t, { emit: n }) {
|
|
2267
|
-
let r = t, i = n, { t: a } =
|
|
2292
|
+
let r = t, i = n, { t: a } = z();
|
|
2268
2293
|
function s(e, t) {
|
|
2269
2294
|
i("update", { [e]: t });
|
|
2270
2295
|
}
|
|
2271
2296
|
function c() {
|
|
2272
2297
|
let e = {
|
|
2273
|
-
id:
|
|
2298
|
+
id: M(),
|
|
2274
2299
|
platform: "facebook",
|
|
2275
2300
|
url: ""
|
|
2276
2301
|
};
|
|
@@ -2286,24 +2311,25 @@ var wi = {
|
|
|
2286
2311
|
i("update", { icons: r.block.icons.filter((t) => t.id !== e) });
|
|
2287
2312
|
}
|
|
2288
2313
|
return (n, r) => (e(), g(_, null, [
|
|
2289
|
-
h("div", ba, [h("label", { class: d(S(
|
|
2314
|
+
h("div", ba, [h("label", { class: d(S(W)) }, w(S(a).social.icons), 3), h("div", xa, [(e(!0), g(_, null, o(t.block.icons, (t) => (e(), g("div", {
|
|
2290
2315
|
key: t.id,
|
|
2291
2316
|
class: "tpl:flex tpl:flex-col tpl:gap-1.5 tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-2"
|
|
2292
2317
|
}, [h("div", Sa, [h("select", {
|
|
2293
|
-
|
|
2318
|
+
"data-testid": "social-platform-select",
|
|
2319
|
+
class: d([S(U), "tpl:flex-1"]),
|
|
2294
2320
|
value: t.platform,
|
|
2295
2321
|
onChange: (e) => u(t.id, "platform", e.target.value)
|
|
2296
|
-
}, [(e(!0), g(_, null, o(S(
|
|
2322
|
+
}, [(e(!0), g(_, null, o(S(be), (t) => (e(), g("option", {
|
|
2297
2323
|
key: t,
|
|
2298
2324
|
value: t
|
|
2299
|
-
}, w(S(
|
|
2300
|
-
class: d(S(
|
|
2325
|
+
}, w(S(_e)[t].name), 9, wa))), 128))], 42, Ca), h("button", {
|
|
2326
|
+
class: d(S(it)),
|
|
2301
2327
|
title: S(a).social.removeIcon,
|
|
2302
2328
|
onClick: (e) => f(t.id)
|
|
2303
|
-
}, [E(S(
|
|
2329
|
+
}, [E(S($e), {
|
|
2304
2330
|
size: 14,
|
|
2305
2331
|
"stroke-width": 2
|
|
2306
|
-
})], 10, Ta)]), E(
|
|
2332
|
+
})], 10, Ta)]), E(Z, {
|
|
2307
2333
|
"model-value": t.url,
|
|
2308
2334
|
type: "url",
|
|
2309
2335
|
placeholder: S(a).social.urlPlaceholder,
|
|
@@ -2313,39 +2339,24 @@ var wi = {
|
|
|
2313
2339
|
"placeholder",
|
|
2314
2340
|
"onUpdate:modelValue"
|
|
2315
2341
|
])]))), 128)), h("button", {
|
|
2316
|
-
class: d(S(
|
|
2342
|
+
class: d(S(at)),
|
|
2317
2343
|
onClick: c
|
|
2318
|
-
}, [E(S(
|
|
2344
|
+
}, [E(S(X), {
|
|
2319
2345
|
size: 14,
|
|
2320
2346
|
"stroke-width": 2
|
|
2321
2347
|
}), l(" " + w(S(a).social.addIcon), 1)], 2)])]),
|
|
2322
|
-
h("div", Ea, [h("label", { class: d(S(
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
label: S(a).social.styleRounded
|
|
2335
|
-
},
|
|
2336
|
-
{
|
|
2337
|
-
value: "square",
|
|
2338
|
-
label: S(a).social.styleSquare
|
|
2339
|
-
},
|
|
2340
|
-
{
|
|
2341
|
-
value: "circle",
|
|
2342
|
-
label: S(a).social.styleCircle
|
|
2343
|
-
}
|
|
2344
|
-
],
|
|
2345
|
-
"model-value": t.block.iconStyle,
|
|
2346
|
-
"onUpdate:modelValue": r[0] ||= (e) => s("iconStyle", e)
|
|
2347
|
-
}, null, 8, ["options", "model-value"])]),
|
|
2348
|
-
h("div", Da, [h("label", { class: d(S(U)) }, w(S(a).social.size), 3), E(J, {
|
|
2348
|
+
h("div", Ea, [h("label", { class: d(S(W)) }, w(S(a).social.style), 3), h("select", {
|
|
2349
|
+
class: d(S(U)),
|
|
2350
|
+
value: t.block.iconStyle,
|
|
2351
|
+
onChange: r[0] ||= (e) => s("iconStyle", e.target.value)
|
|
2352
|
+
}, [
|
|
2353
|
+
h("option", Oa, w(S(a).social.styleSolid), 1),
|
|
2354
|
+
h("option", ka, w(S(a).social.styleOutlined), 1),
|
|
2355
|
+
h("option", Aa, w(S(a).social.styleRounded), 1),
|
|
2356
|
+
h("option", ja, w(S(a).social.styleSquare), 1),
|
|
2357
|
+
h("option", Ma, w(S(a).social.styleCircle), 1)
|
|
2358
|
+
], 42, Da)]),
|
|
2359
|
+
h("div", Na, [h("label", { class: d(S(W)) }, w(S(a).social.size), 3), E(Y, {
|
|
2349
2360
|
options: [
|
|
2350
2361
|
{
|
|
2351
2362
|
value: "small",
|
|
@@ -2363,30 +2374,30 @@ var wi = {
|
|
|
2363
2374
|
"model-value": t.block.iconSize,
|
|
2364
2375
|
"onUpdate:modelValue": r[1] ||= (e) => s("iconSize", e)
|
|
2365
2376
|
}, null, 8, ["options", "model-value"])]),
|
|
2366
|
-
h("div",
|
|
2377
|
+
h("div", Pa, [h("label", { class: d(S(W)) }, w(S(a).social.spacing), 3), h("div", Fa, [h("input", {
|
|
2367
2378
|
type: "number",
|
|
2368
|
-
class: d(S(
|
|
2379
|
+
class: d(S(K)),
|
|
2369
2380
|
value: t.block.spacing,
|
|
2370
2381
|
min: "0",
|
|
2371
2382
|
max: "50",
|
|
2372
2383
|
onInput: r[2] ||= (e) => s("spacing", Number(e.target.value))
|
|
2373
|
-
}, null, 42,
|
|
2374
|
-
h("div",
|
|
2384
|
+
}, null, 42, Ia), h("span", { class: d(S(G)) }, "px", 2)])]),
|
|
2385
|
+
h("div", La, [h("label", { class: d(S(W)) }, w(S(a).social.align), 3), E(Y, {
|
|
2375
2386
|
options: [
|
|
2376
2387
|
{
|
|
2377
2388
|
value: "left",
|
|
2378
2389
|
label: S(a).title.alignLeft,
|
|
2379
|
-
icon: S(
|
|
2390
|
+
icon: S(Ze)
|
|
2380
2391
|
},
|
|
2381
2392
|
{
|
|
2382
2393
|
value: "center",
|
|
2383
2394
|
label: S(a).title.alignCenter,
|
|
2384
|
-
icon: S(
|
|
2395
|
+
icon: S(Xe)
|
|
2385
2396
|
},
|
|
2386
2397
|
{
|
|
2387
2398
|
value: "right",
|
|
2388
2399
|
label: S(a).title.alignRight,
|
|
2389
|
-
icon: S(
|
|
2400
|
+
icon: S(Ye)
|
|
2390
2401
|
}
|
|
2391
2402
|
],
|
|
2392
2403
|
"model-value": t.block.align,
|
|
@@ -2394,22 +2405,22 @@ var wi = {
|
|
|
2394
2405
|
}, null, 8, ["options", "model-value"])])
|
|
2395
2406
|
], 64));
|
|
2396
2407
|
}
|
|
2397
|
-
}),
|
|
2408
|
+
}), za = { class: "tpl:mb-3.5" }, Ba = { class: "tpl:flex tpl:items-stretch" }, Va = ["value"], Ha = ["value"], Ua = /* @__PURE__ */ f({
|
|
2398
2409
|
__name: "SpacerToolbar",
|
|
2399
2410
|
props: { block: {} },
|
|
2400
2411
|
emits: ["update"],
|
|
2401
2412
|
setup(t, { emit: n }) {
|
|
2402
|
-
let r = n, { t: i } =
|
|
2403
|
-
return (n, a) => (e(), g("div",
|
|
2404
|
-
h("label", { class: d(S(
|
|
2405
|
-
h("div",
|
|
2413
|
+
let r = n, { t: i } = z();
|
|
2414
|
+
return (n, a) => (e(), g("div", za, [
|
|
2415
|
+
h("label", { class: d(S(W)) }, w(S(i).spacer.height), 3),
|
|
2416
|
+
h("div", Ba, [h("input", {
|
|
2406
2417
|
type: "number",
|
|
2407
|
-
class: d(S(
|
|
2418
|
+
class: d(S(K)),
|
|
2408
2419
|
value: t.block.height,
|
|
2409
2420
|
min: "10",
|
|
2410
2421
|
max: "100",
|
|
2411
2422
|
onInput: a[0] ||= (e) => r("update", { height: Number(e.target.value) })
|
|
2412
|
-
}, null, 42,
|
|
2423
|
+
}, null, 42, Va), h("span", { class: d(S(G)) }, "px", 2)]),
|
|
2413
2424
|
h("input", {
|
|
2414
2425
|
type: "range",
|
|
2415
2426
|
class: "tpl:mt-2 tpl:w-full tpl:accent-[var(--tpl-primary)]",
|
|
@@ -2417,13 +2428,13 @@ var wi = {
|
|
|
2417
2428
|
min: "10",
|
|
2418
2429
|
max: "100",
|
|
2419
2430
|
onInput: a[1] ||= (e) => r("update", { height: Number(e.target.value) })
|
|
2420
|
-
}, null, 40,
|
|
2431
|
+
}, null, 40, Ha)
|
|
2421
2432
|
]));
|
|
2422
2433
|
}
|
|
2423
|
-
}),
|
|
2434
|
+
}), Wa = { class: "tpl:mb-3.5" }, Ga = { class: "tpl:flex tpl:items-center tpl:gap-3" }, Ka = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, qa = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, Ja = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, Ya = ["disabled"], Xa = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, Za = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, Qa = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, $a = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, eo = ["disabled"], to = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, no = { class: "tpl:mb-3.5" }, ro = { class: "tpl:mb-1.5 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, io = ["checked"], ao = {
|
|
2424
2435
|
key: 0,
|
|
2425
2436
|
class: "tpl:mb-3.5"
|
|
2426
|
-
},
|
|
2437
|
+
}, oo = { class: "tpl:mb-3.5" }, so = { class: "tpl:mb-3.5" }, co = { class: "tpl:flex tpl:items-stretch" }, lo = ["value"], uo = { class: "tpl:mb-3.5" }, fo = { class: "tpl:flex tpl:items-stretch" }, po = ["value"], mo = { class: "tpl:mb-3.5" }, ho = ["value"], go = { value: "" }, _o = ["value"], vo = { class: "tpl:mb-3.5" }, yo = { class: "tpl:flex tpl:items-stretch" }, bo = ["value"], xo = { class: "tpl:mb-3.5" }, So = { class: "tpl:mb-3.5" }, Co = /* @__PURE__ */ f({
|
|
2427
2438
|
__name: "TableToolbar",
|
|
2428
2439
|
props: {
|
|
2429
2440
|
block: {},
|
|
@@ -2431,15 +2442,15 @@ var wi = {
|
|
|
2431
2442
|
},
|
|
2432
2443
|
emits: ["update"],
|
|
2433
2444
|
setup(t, { emit: n }) {
|
|
2434
|
-
let r = t, i = n, { t: a } =
|
|
2445
|
+
let r = t, i = n, { t: a } = z(), s = m(() => r.block.rows.length > 0 ? r.block.rows[0].cells.length : 0);
|
|
2435
2446
|
function c(e, t) {
|
|
2436
2447
|
i("update", { [e]: t });
|
|
2437
2448
|
}
|
|
2438
2449
|
function u() {
|
|
2439
2450
|
let e = r.block.rows.length > 0 ? r.block.rows[0].cells.length : 3, t = {
|
|
2440
|
-
id:
|
|
2451
|
+
id: M(),
|
|
2441
2452
|
cells: Array.from({ length: e }, () => ({
|
|
2442
|
-
id:
|
|
2453
|
+
id: M(),
|
|
2443
2454
|
content: ""
|
|
2444
2455
|
}))
|
|
2445
2456
|
};
|
|
@@ -2452,7 +2463,7 @@ var wi = {
|
|
|
2452
2463
|
i("update", { rows: r.block.rows.map((e) => ({
|
|
2453
2464
|
...e,
|
|
2454
2465
|
cells: [...e.cells, {
|
|
2455
|
-
id:
|
|
2466
|
+
id: M(),
|
|
2456
2467
|
content: ""
|
|
2457
2468
|
}]
|
|
2458
2469
|
})) });
|
|
@@ -2464,108 +2475,108 @@ var wi = {
|
|
|
2464
2475
|
})) });
|
|
2465
2476
|
}
|
|
2466
2477
|
return (n, r) => (e(), g(_, null, [
|
|
2467
|
-
h("div",
|
|
2478
|
+
h("div", Wa, [h("label", { class: d(S(W)) }, w(S(a).table.dimensions), 3), h("div", Ga, [h("div", Ka, [h("span", qa, w(S(a).table.rows), 1), h("div", Ja, [
|
|
2468
2479
|
h("button", {
|
|
2469
2480
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:duration-150 tpl:hover:text-[var(--tpl-primary)] tpl:disabled:opacity-30",
|
|
2470
2481
|
disabled: t.block.rows.length <= 1,
|
|
2471
2482
|
onClick: r[0] ||= (e) => f(t.block.rows[t.block.rows.length - 1].id)
|
|
2472
|
-
}, [E(S(
|
|
2483
|
+
}, [E(S(V), {
|
|
2473
2484
|
size: 12,
|
|
2474
2485
|
"stroke-width": 2
|
|
2475
|
-
})], 8,
|
|
2476
|
-
h("span",
|
|
2486
|
+
})], 8, Ya),
|
|
2487
|
+
h("span", Xa, w(t.block.rows.length), 1),
|
|
2477
2488
|
h("button", {
|
|
2478
2489
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:duration-150 tpl:hover:text-[var(--tpl-primary)]",
|
|
2479
2490
|
onClick: u
|
|
2480
|
-
}, [E(S(
|
|
2491
|
+
}, [E(S(X), {
|
|
2481
2492
|
size: 12,
|
|
2482
2493
|
"stroke-width": 2
|
|
2483
2494
|
})])
|
|
2484
|
-
])]), h("div",
|
|
2495
|
+
])]), h("div", Za, [h("span", Qa, w(S(a).table.columns), 1), h("div", $a, [
|
|
2485
2496
|
h("button", {
|
|
2486
2497
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:duration-150 tpl:hover:text-[var(--tpl-primary)] tpl:disabled:opacity-30",
|
|
2487
2498
|
disabled: s.value <= 1,
|
|
2488
2499
|
onClick: r[1] ||= (e) => y(s.value - 1)
|
|
2489
|
-
}, [E(S(
|
|
2500
|
+
}, [E(S(V), {
|
|
2490
2501
|
size: 12,
|
|
2491
2502
|
"stroke-width": 2
|
|
2492
|
-
})], 8,
|
|
2493
|
-
h("span",
|
|
2503
|
+
})], 8, eo),
|
|
2504
|
+
h("span", to, w(s.value), 1),
|
|
2494
2505
|
h("button", {
|
|
2495
2506
|
class: "tpl:flex tpl:items-center tpl:justify-center tpl:px-1.5 tpl:py-1 tpl:text-[var(--tpl-text-muted)] tpl:transition-colors tpl:duration-150 tpl:hover:text-[var(--tpl-primary)]",
|
|
2496
2507
|
onClick: p
|
|
2497
|
-
}, [E(S(
|
|
2508
|
+
}, [E(S(X), {
|
|
2498
2509
|
size: 12,
|
|
2499
2510
|
"stroke-width": 2
|
|
2500
2511
|
})])
|
|
2501
2512
|
])])])]),
|
|
2502
|
-
h("div",
|
|
2513
|
+
h("div", no, [h("label", ro, [h("input", {
|
|
2503
2514
|
type: "checkbox",
|
|
2504
2515
|
checked: t.block.hasHeaderRow,
|
|
2505
2516
|
class: "tpl:accent-[var(--tpl-primary)]",
|
|
2506
2517
|
onChange: r[2] ||= (e) => c("hasHeaderRow", e.target.checked)
|
|
2507
|
-
}, null, 40,
|
|
2508
|
-
t.block.hasHeaderRow ? (e(), g("div",
|
|
2518
|
+
}, null, 40, io), l(" " + w(S(a).table.hasHeaderRow), 1)])]),
|
|
2519
|
+
t.block.hasHeaderRow ? (e(), g("div", ao, [h("label", { class: d(S(W)) }, w(S(a).table.headerBackgroundColor), 3), E(q, {
|
|
2509
2520
|
"model-value": t.block.headerBackgroundColor || S("#f2f2f2"),
|
|
2510
2521
|
placeholder: S(a).table.noHeaderBg,
|
|
2511
2522
|
"onUpdate:modelValue": r[3] ||= (e) => c("headerBackgroundColor", e || null)
|
|
2512
2523
|
}, null, 8, ["model-value", "placeholder"])])) : v("", !0),
|
|
2513
|
-
h("div",
|
|
2524
|
+
h("div", oo, [h("label", { class: d(S(W)) }, w(S(a).table.borderColor), 3), E(q, {
|
|
2514
2525
|
"model-value": t.block.borderColor,
|
|
2515
2526
|
"onUpdate:modelValue": r[4] ||= (e) => c("borderColor", e)
|
|
2516
2527
|
}, null, 8, ["model-value"])]),
|
|
2517
|
-
h("div",
|
|
2528
|
+
h("div", so, [h("label", { class: d(S(W)) }, w(S(a).table.borderWidth), 3), h("div", co, [h("input", {
|
|
2518
2529
|
type: "number",
|
|
2519
|
-
class: d(S(
|
|
2530
|
+
class: d(S(K)),
|
|
2520
2531
|
value: t.block.borderWidth,
|
|
2521
2532
|
min: "0",
|
|
2522
2533
|
max: "10",
|
|
2523
2534
|
onInput: r[5] ||= (e) => c("borderWidth", Number(e.target.value))
|
|
2524
|
-
}, null, 42,
|
|
2525
|
-
h("div",
|
|
2535
|
+
}, null, 42, lo), h("span", { class: d(S(G)) }, "px", 2)])]),
|
|
2536
|
+
h("div", uo, [h("label", { class: d(S(W)) }, w(S(a).table.cellPadding), 3), h("div", fo, [h("input", {
|
|
2526
2537
|
type: "number",
|
|
2527
|
-
class: d(S(
|
|
2538
|
+
class: d(S(K)),
|
|
2528
2539
|
value: t.block.cellPadding,
|
|
2529
2540
|
min: "0",
|
|
2530
2541
|
max: "30",
|
|
2531
2542
|
onInput: r[6] ||= (e) => c("cellPadding", Number(e.target.value))
|
|
2532
|
-
}, null, 42,
|
|
2533
|
-
h("div",
|
|
2534
|
-
class: d(S(
|
|
2543
|
+
}, null, 42, po), h("span", { class: d(S(G)) }, "px", 2)])]),
|
|
2544
|
+
h("div", mo, [h("label", { class: d(S(W)) }, w(S(a).table.fontFamily), 3), h("select", {
|
|
2545
|
+
class: d(S(U)),
|
|
2535
2546
|
value: t.block.fontFamily || "",
|
|
2536
2547
|
onChange: r[7] ||= (e) => c("fontFamily", e.target.value || void 0)
|
|
2537
|
-
}, [h("option",
|
|
2548
|
+
}, [h("option", go, w(S(a).title.inheritFont), 1), (e(!0), g(_, null, o(t.fontFamilies, (t) => (e(), g("option", {
|
|
2538
2549
|
key: t.value,
|
|
2539
2550
|
value: t.value
|
|
2540
|
-
}, w(t.label), 9,
|
|
2541
|
-
h("div",
|
|
2551
|
+
}, w(t.label), 9, _o))), 128))], 42, ho)]),
|
|
2552
|
+
h("div", vo, [h("label", { class: d(S(W)) }, w(S(a).table.fontSize), 3), h("div", yo, [h("input", {
|
|
2542
2553
|
type: "number",
|
|
2543
|
-
class: d(S(
|
|
2554
|
+
class: d(S(K)),
|
|
2544
2555
|
value: t.block.fontSize,
|
|
2545
2556
|
min: "10",
|
|
2546
2557
|
max: "32",
|
|
2547
2558
|
onInput: r[8] ||= (e) => c("fontSize", Number(e.target.value))
|
|
2548
|
-
}, null, 42,
|
|
2549
|
-
h("div",
|
|
2559
|
+
}, null, 42, bo), h("span", { class: d(S(G)) }, "px", 2)])]),
|
|
2560
|
+
h("div", xo, [h("label", { class: d(S(W)) }, w(S(a).table.color), 3), E(q, {
|
|
2550
2561
|
"model-value": t.block.color,
|
|
2551
2562
|
"onUpdate:modelValue": r[9] ||= (e) => c("color", e)
|
|
2552
2563
|
}, null, 8, ["model-value"])]),
|
|
2553
|
-
h("div",
|
|
2564
|
+
h("div", So, [h("label", { class: d(S(W)) }, w(S(a).table.textAlign), 3), E(Y, {
|
|
2554
2565
|
options: [
|
|
2555
2566
|
{
|
|
2556
2567
|
value: "left",
|
|
2557
2568
|
label: S(a).title.alignLeft,
|
|
2558
|
-
icon: S(
|
|
2569
|
+
icon: S(Ze)
|
|
2559
2570
|
},
|
|
2560
2571
|
{
|
|
2561
2572
|
value: "center",
|
|
2562
2573
|
label: S(a).title.alignCenter,
|
|
2563
|
-
icon: S(
|
|
2574
|
+
icon: S(Xe)
|
|
2564
2575
|
},
|
|
2565
2576
|
{
|
|
2566
2577
|
value: "right",
|
|
2567
2578
|
label: S(a).title.alignRight,
|
|
2568
|
-
icon: S(
|
|
2579
|
+
icon: S(Ye)
|
|
2569
2580
|
}
|
|
2570
2581
|
],
|
|
2571
2582
|
"model-value": t.block.textAlign,
|
|
@@ -2573,7 +2584,7 @@ var wi = {
|
|
|
2573
2584
|
}, null, 8, ["options", "model-value"])])
|
|
2574
2585
|
], 64));
|
|
2575
2586
|
}
|
|
2576
|
-
}),
|
|
2587
|
+
}), wo = { class: "tpl:mb-3.5" }, To = ["value"], Eo = { value: 1 }, Do = { value: 2 }, Oo = { value: 3 }, ko = { value: 4 }, Ao = { class: "tpl:mb-3.5" }, jo = ["value"], Mo = { value: "" }, No = ["value"], Po = { class: "tpl:mb-3.5" }, Fo = { class: "tpl:mb-3.5" }, Io = /* @__PURE__ */ f({
|
|
2577
2588
|
__name: "TitleToolbar",
|
|
2578
2589
|
props: {
|
|
2579
2590
|
block: {},
|
|
@@ -2581,49 +2592,49 @@ var wi = {
|
|
|
2581
2592
|
},
|
|
2582
2593
|
emits: ["update"],
|
|
2583
2594
|
setup(t, { emit: n }) {
|
|
2584
|
-
let r = n, { t: i } =
|
|
2595
|
+
let r = n, { t: i } = z();
|
|
2585
2596
|
function a(e, t) {
|
|
2586
2597
|
r("update", { [e]: t });
|
|
2587
2598
|
}
|
|
2588
2599
|
return (n, r) => (e(), g(_, null, [
|
|
2589
|
-
h("div",
|
|
2590
|
-
class: d(S(
|
|
2600
|
+
h("div", wo, [h("label", { class: d(S(W)) }, w(S(i).title.level), 3), h("select", {
|
|
2601
|
+
class: d(S(U)),
|
|
2591
2602
|
value: t.block.level,
|
|
2592
2603
|
onChange: r[0] ||= (e) => a("level", Number(e.target.value))
|
|
2593
2604
|
}, [
|
|
2594
|
-
h("option",
|
|
2595
|
-
h("option",
|
|
2596
|
-
h("option",
|
|
2597
|
-
h("option",
|
|
2598
|
-
], 42,
|
|
2599
|
-
h("div",
|
|
2600
|
-
class: d(S(
|
|
2605
|
+
h("option", Eo, w(S(i).title.heading1), 1),
|
|
2606
|
+
h("option", Do, w(S(i).title.heading2), 1),
|
|
2607
|
+
h("option", Oo, w(S(i).title.heading3), 1),
|
|
2608
|
+
h("option", ko, w(S(i).title.heading4), 1)
|
|
2609
|
+
], 42, To)]),
|
|
2610
|
+
h("div", Ao, [h("label", { class: d(S(W)) }, w(S(i).title.fontFamily), 3), h("select", {
|
|
2611
|
+
class: d(S(U)),
|
|
2601
2612
|
value: t.block.fontFamily || "",
|
|
2602
2613
|
onChange: r[1] ||= (e) => a("fontFamily", e.target.value || void 0)
|
|
2603
|
-
}, [h("option",
|
|
2614
|
+
}, [h("option", Mo, w(S(i).title.inheritFont), 1), (e(!0), g(_, null, o(t.fontFamilies, (t) => (e(), g("option", {
|
|
2604
2615
|
key: t.value,
|
|
2605
2616
|
value: t.value
|
|
2606
|
-
}, w(t.label), 9,
|
|
2607
|
-
h("div",
|
|
2617
|
+
}, w(t.label), 9, No))), 128))], 42, jo)]),
|
|
2618
|
+
h("div", Po, [h("label", { class: d(S(W)) }, w(S(i).title.color), 3), E(q, {
|
|
2608
2619
|
"model-value": t.block.color,
|
|
2609
2620
|
"onUpdate:modelValue": r[2] ||= (e) => a("color", e)
|
|
2610
2621
|
}, null, 8, ["model-value"])]),
|
|
2611
|
-
h("div",
|
|
2622
|
+
h("div", Fo, [h("label", { class: d(S(W)) }, w(S(i).title.align), 3), E(Y, {
|
|
2612
2623
|
options: [
|
|
2613
2624
|
{
|
|
2614
2625
|
value: "left",
|
|
2615
2626
|
label: S(i).title.alignLeft,
|
|
2616
|
-
icon: S(
|
|
2627
|
+
icon: S(Ze)
|
|
2617
2628
|
},
|
|
2618
2629
|
{
|
|
2619
2630
|
value: "center",
|
|
2620
2631
|
label: S(i).title.alignCenter,
|
|
2621
|
-
icon: S(
|
|
2632
|
+
icon: S(Xe)
|
|
2622
2633
|
},
|
|
2623
2634
|
{
|
|
2624
2635
|
value: "right",
|
|
2625
2636
|
label: S(i).title.alignRight,
|
|
2626
|
-
icon: S(
|
|
2637
|
+
icon: S(Ye)
|
|
2627
2638
|
}
|
|
2628
2639
|
],
|
|
2629
2640
|
"model-value": t.block.textAlign,
|
|
@@ -2631,22 +2642,22 @@ var wi = {
|
|
|
2631
2642
|
}, null, 8, ["options", "model-value"])])
|
|
2632
2643
|
], 64));
|
|
2633
2644
|
}
|
|
2634
|
-
}),
|
|
2645
|
+
}), Lo = { class: "tpl:mb-3.5" }, Ro = {
|
|
2635
2646
|
key: 0,
|
|
2636
2647
|
class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]"
|
|
2637
|
-
},
|
|
2648
|
+
}, zo = ["checked"], Bo = {
|
|
2638
2649
|
key: 0,
|
|
2639
2650
|
class: "tpl:mb-3.5"
|
|
2640
|
-
},
|
|
2651
|
+
}, Vo = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, Ho = [
|
|
2641
2652
|
"value",
|
|
2642
2653
|
"placeholder",
|
|
2643
2654
|
"title"
|
|
2644
|
-
],
|
|
2655
|
+
], Uo = { class: "tpl:mb-3.5" }, Wo = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, Go = { class: "tpl:mb-3.5" }, Ko = { class: "tpl:mb-3.5" }, qo = ["value"], Jo = { value: "full" }, Yo = { class: "tpl:mb-3.5" }, Xo = /* @__PURE__ */ f({
|
|
2645
2656
|
__name: "VideoToolbar",
|
|
2646
2657
|
props: { block: {} },
|
|
2647
2658
|
emits: ["update"],
|
|
2648
2659
|
setup(t, { emit: n }) {
|
|
2649
|
-
let r = t, i = n, { t: a } =
|
|
2660
|
+
let r = t, i = n, { t: a } = z(), o = D(Ee, null), s = D(Le, P.liquid), u = m(() => !!o), f = m(() => te(r.block.url, s)), p = c(!1), { start: y } = we(() => {
|
|
2650
2661
|
p.value = !1;
|
|
2651
2662
|
}, 1e3, { immediate: !1 });
|
|
2652
2663
|
function b(e, t) {
|
|
@@ -2657,32 +2668,32 @@ var wi = {
|
|
|
2657
2668
|
e && (b("thumbnailUrl", e.url), p.value = !0, y());
|
|
2658
2669
|
}
|
|
2659
2670
|
return (n, r) => (e(), g(_, null, [
|
|
2660
|
-
h("div",
|
|
2661
|
-
h("label", { class: d(S(
|
|
2662
|
-
E(
|
|
2671
|
+
h("div", Lo, [
|
|
2672
|
+
h("label", { class: d(S(W)) }, w(S(a).video.videoUrl), 3),
|
|
2673
|
+
E(Z, {
|
|
2663
2674
|
"model-value": t.block.url,
|
|
2664
2675
|
type: "url",
|
|
2665
2676
|
placeholder: S(a).video.videoUrlPlaceholder,
|
|
2666
2677
|
"onUpdate:modelValue": r[0] ||= (e) => b("url", e)
|
|
2667
2678
|
}, null, 8, ["model-value", "placeholder"]),
|
|
2668
|
-
t.block.url ? (e(), g("label",
|
|
2679
|
+
t.block.url ? (e(), g("label", Ro, [h("input", {
|
|
2669
2680
|
type: "checkbox",
|
|
2670
2681
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
2671
2682
|
checked: t.block.openInNewTab ?? !1,
|
|
2672
2683
|
onChange: r[1] ||= (e) => b("openInNewTab", e.target.checked)
|
|
2673
|
-
}, null, 40,
|
|
2684
|
+
}, null, 40, zo), l(" " + w(S(a).video.openInNewTab), 1)])) : v("", !0)
|
|
2674
2685
|
]),
|
|
2675
|
-
f.value ? (e(), g("div",
|
|
2686
|
+
f.value ? (e(), g("div", Bo, [h("label", { class: d(S(W)) }, [l(w(S(a).video.placeholderUrl) + " ", 1), h("span", Vo, w(S(a).video.optional), 1)], 2), h("input", {
|
|
2676
2687
|
type: "url",
|
|
2677
|
-
class: d(S(
|
|
2688
|
+
class: d(S(U)),
|
|
2678
2689
|
value: t.block.placeholderUrl || "",
|
|
2679
2690
|
placeholder: S(a).video.placeholderUrlPlaceholder,
|
|
2680
2691
|
title: S(a).video.placeholderUrlTooltip,
|
|
2681
2692
|
onInput: r[2] ||= (e) => b("placeholderUrl", e.target.value)
|
|
2682
|
-
}, null, 42,
|
|
2683
|
-
h("div",
|
|
2684
|
-
h("label", { class: d(S(
|
|
2685
|
-
E(
|
|
2693
|
+
}, null, 42, Ho)])) : v("", !0),
|
|
2694
|
+
h("div", Uo, [
|
|
2695
|
+
h("label", { class: d(S(W)) }, [l(w(S(a).video.customThumbnail) + " ", 1), h("span", Wo, w(S(a).video.optional), 1)], 2),
|
|
2696
|
+
E(Z, {
|
|
2686
2697
|
"model-value": t.block.thumbnailUrl,
|
|
2687
2698
|
type: "url",
|
|
2688
2699
|
placeholder: S(a).video.thumbnailPlaceholder,
|
|
@@ -2702,28 +2713,28 @@ var wi = {
|
|
|
2702
2713
|
"background-color": "var(--tpl-bg)"
|
|
2703
2714
|
},
|
|
2704
2715
|
onClick: x
|
|
2705
|
-
}, [E(S(
|
|
2716
|
+
}, [E(S(R), {
|
|
2706
2717
|
size: 14,
|
|
2707
2718
|
"stroke-width": 1.5
|
|
2708
2719
|
}), l(" " + w(S(a).image.browseMedia), 1)])) : v("", !0)
|
|
2709
2720
|
]),
|
|
2710
|
-
h("div",
|
|
2721
|
+
h("div", Go, [h("label", { class: d(S(W)) }, w(S(a).video.altText), 3), E(Z, {
|
|
2711
2722
|
"model-value": t.block.alt,
|
|
2712
2723
|
type: "text",
|
|
2713
2724
|
placeholder: S(a).video.altTextPlaceholder,
|
|
2714
2725
|
"onUpdate:modelValue": r[4] ||= (e) => b("alt", e)
|
|
2715
2726
|
}, null, 8, ["model-value", "placeholder"])]),
|
|
2716
|
-
h("div",
|
|
2717
|
-
class: d(S(
|
|
2727
|
+
h("div", Ko, [h("label", { class: d(S(W)) }, w(S(a).video.width), 3), h("select", {
|
|
2728
|
+
class: d(S(U)),
|
|
2718
2729
|
value: t.block.width,
|
|
2719
2730
|
onChange: r[5] ||= (e) => b("width", e.target.value === "full" ? "full" : Number(e.target.value))
|
|
2720
2731
|
}, [
|
|
2721
|
-
h("option",
|
|
2732
|
+
h("option", Jo, w(S(a).video.fullWidth), 1),
|
|
2722
2733
|
r[7] ||= h("option", { value: "300" }, "300px", -1),
|
|
2723
2734
|
r[8] ||= h("option", { value: "400" }, "400px", -1),
|
|
2724
2735
|
r[9] ||= h("option", { value: "500" }, "500px", -1)
|
|
2725
|
-
], 42,
|
|
2726
|
-
h("div",
|
|
2736
|
+
], 42, qo)]),
|
|
2737
|
+
h("div", Yo, [h("label", { class: d(S(W)) }, w(S(a).title.align), 3), E(Y, {
|
|
2727
2738
|
options: [
|
|
2728
2739
|
{
|
|
2729
2740
|
value: "left",
|
|
@@ -2743,7 +2754,7 @@ var wi = {
|
|
|
2743
2754
|
}, null, 8, ["options", "model-value"])])
|
|
2744
2755
|
], 64));
|
|
2745
2756
|
}
|
|
2746
|
-
}),
|
|
2757
|
+
}), Zo = ["aria-label"], Qo = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-3.5" }, $o = { class: "tpl:flex tpl:items-center tpl:gap-2 tpl:text-[var(--tpl-primary)]" }, es = { class: "tpl:m-0 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, ts = { class: "tpl:flex tpl:gap-1" }, ns = ["title"], rs = ["title"], is = { class: "tpl:flex-1 tpl:overflow-y-auto tpl:p-4" }, as = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
2747
2758
|
__name: "Toolbar",
|
|
2748
2759
|
props: { block: {} },
|
|
2749
2760
|
emits: [
|
|
@@ -2752,7 +2763,7 @@ var wi = {
|
|
|
2752
2763
|
"duplicate"
|
|
2753
2764
|
],
|
|
2754
2765
|
setup(t, { emit: n }) {
|
|
2755
|
-
let i = O(() => import("./CountdownToolbar-
|
|
2766
|
+
let i = O(() => import("./CountdownToolbar-CojjlZet.js")), a = t, o = n, { t: s } = z(), c = Te(Ae, "Toolbar"), l = D(ke, []), u = m(() => a.block.type), d = m(() => ee(a.block)), f = m(() => {
|
|
2756
2767
|
if (d.value) return l.find((e) => e.type === a.block.customType);
|
|
2757
2768
|
}), p = m(() => d.value ? f.value?.name ?? a.block.customType : I(u.value, s)), y = c.fonts;
|
|
2758
2769
|
function b(e) {
|
|
@@ -2761,7 +2772,7 @@ var wi = {
|
|
|
2761
2772
|
return (n, a) => (e(), g("aside", {
|
|
2762
2773
|
"aria-label": S(s).landmarks.blockToolbar,
|
|
2763
2774
|
class: "tpl:flex tpl:w-full tpl:flex-1 tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)]"
|
|
2764
|
-
}, [h("div",
|
|
2775
|
+
}, [h("div", Qo, [h("div", $o, [S(He)[u.value] ? (e(), x(r(S(He)[u.value]), {
|
|
2765
2776
|
key: 0,
|
|
2766
2777
|
size: 16,
|
|
2767
2778
|
"stroke-width": 1.5
|
|
@@ -2769,21 +2780,21 @@ var wi = {
|
|
|
2769
2780
|
key: 1,
|
|
2770
2781
|
size: 16,
|
|
2771
2782
|
"stroke-width": 1.5
|
|
2772
|
-
})) : v("", !0), h("h3",
|
|
2783
|
+
})) : v("", !0), h("h3", es, w(p.value), 1)]), h("div", ts, [h("button", {
|
|
2773
2784
|
class: "tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-150 tpl:hover:bg-[var(--tpl-bg-active)] tpl:hover:text-[var(--tpl-text)]",
|
|
2774
2785
|
title: S(s).toolbar.duplicate,
|
|
2775
2786
|
onClick: a[0] ||= (e) => o("duplicate")
|
|
2776
2787
|
}, [E(S(pe), {
|
|
2777
2788
|
size: 14,
|
|
2778
2789
|
"stroke-width": 2
|
|
2779
|
-
})], 8,
|
|
2790
|
+
})], 8, ns), h("button", {
|
|
2780
2791
|
class: "tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:text-[var(--tpl-text-muted)] tpl:transition-all tpl:duration-150 tpl:hover:border-[var(--tpl-danger)] tpl:hover:bg-[var(--tpl-danger-light)] tpl:hover:text-[var(--tpl-danger)]",
|
|
2781
2792
|
title: S(s).toolbar.delete,
|
|
2782
2793
|
onClick: a[1] ||= (e) => o("delete")
|
|
2783
|
-
}, [E(S(
|
|
2794
|
+
}, [E(S(Qe), {
|
|
2784
2795
|
size: 14,
|
|
2785
2796
|
"stroke-width": 2
|
|
2786
|
-
})], 8,
|
|
2797
|
+
})], 8, rs)])]), h("div", is, [d.value ? (e(), x(Mi, {
|
|
2787
2798
|
key: 0,
|
|
2788
2799
|
block: t.block,
|
|
2789
2800
|
onUpdateFieldValues: a[2] ||= (e) => o("update", { fieldValues: e }),
|
|
@@ -2792,7 +2803,7 @@ var wi = {
|
|
|
2792
2803
|
key: 1,
|
|
2793
2804
|
block: t.block,
|
|
2794
2805
|
onUpdate: b
|
|
2795
|
-
}, null, 8, ["block"])) : u.value === "title" ? (e(), x(
|
|
2806
|
+
}, null, 8, ["block"])) : u.value === "title" ? (e(), x(Io, {
|
|
2796
2807
|
key: 2,
|
|
2797
2808
|
block: t.block,
|
|
2798
2809
|
"font-families": S(y),
|
|
@@ -2801,11 +2812,11 @@ var wi = {
|
|
|
2801
2812
|
key: 4,
|
|
2802
2813
|
block: t.block,
|
|
2803
2814
|
onUpdate: b
|
|
2804
|
-
}, null, 8, ["block"])) : u.value === "video" ? (e(), x(
|
|
2815
|
+
}, null, 8, ["block"])) : u.value === "video" ? (e(), x(Xo, {
|
|
2805
2816
|
key: 5,
|
|
2806
2817
|
block: t.block,
|
|
2807
2818
|
onUpdate: b
|
|
2808
|
-
}, null, 8, ["block"])) : u.value === "button" ? (e(), x(
|
|
2819
|
+
}, null, 8, ["block"])) : u.value === "button" ? (e(), x(rr, {
|
|
2809
2820
|
key: 6,
|
|
2810
2821
|
block: t.block,
|
|
2811
2822
|
"font-families": S(y),
|
|
@@ -2814,7 +2825,7 @@ var wi = {
|
|
|
2814
2825
|
key: 7,
|
|
2815
2826
|
block: t.block,
|
|
2816
2827
|
onUpdate: b
|
|
2817
|
-
}, null, 8, ["block"])) : u.value === "social" ? (e(), x(
|
|
2828
|
+
}, null, 8, ["block"])) : u.value === "social" ? (e(), x(Ra, {
|
|
2818
2829
|
key: 8,
|
|
2819
2830
|
block: t.block,
|
|
2820
2831
|
onUpdate: b
|
|
@@ -2823,12 +2834,12 @@ var wi = {
|
|
|
2823
2834
|
block: t.block,
|
|
2824
2835
|
"font-families": S(y),
|
|
2825
2836
|
onUpdate: b
|
|
2826
|
-
}, null, 8, ["block", "font-families"])) : u.value === "table" ? (e(), x(
|
|
2837
|
+
}, null, 8, ["block", "font-families"])) : u.value === "table" ? (e(), x(Co, {
|
|
2827
2838
|
key: 10,
|
|
2828
2839
|
block: t.block,
|
|
2829
2840
|
"font-families": S(y),
|
|
2830
2841
|
onUpdate: b
|
|
2831
|
-
}, null, 8, ["block", "font-families"])) : u.value === "spacer" ? (e(), x(
|
|
2842
|
+
}, null, 8, ["block", "font-families"])) : u.value === "spacer" ? (e(), x(Ua, {
|
|
2832
2843
|
key: 11,
|
|
2833
2844
|
block: t.block,
|
|
2834
2845
|
onUpdate: b
|
|
@@ -2845,48 +2856,48 @@ var wi = {
|
|
|
2845
2856
|
block: t.block,
|
|
2846
2857
|
"is-first-section": u.value === "paragraph",
|
|
2847
2858
|
onUpdate: b
|
|
2848
|
-
}, null, 8, ["block", "is-first-section"])])], 8,
|
|
2859
|
+
}, null, 8, ["block", "is-first-section"])])], 8, Zo));
|
|
2849
2860
|
}
|
|
2850
|
-
}), [["__scopeId", "data-v-2ac88283"]]),
|
|
2861
|
+
}), [["__scopeId", "data-v-2ac88283"]]), os = ["aria-label"], ss = {
|
|
2851
2862
|
role: "tablist",
|
|
2852
2863
|
class: "tpl:relative tpl:flex tpl:gap-1 tpl:border-b tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-active)] tpl:p-1.5"
|
|
2853
|
-
},
|
|
2864
|
+
}, cs = [
|
|
2854
2865
|
"aria-selected",
|
|
2855
2866
|
"aria-label",
|
|
2856
2867
|
"title"
|
|
2857
|
-
],
|
|
2868
|
+
], ls = { key: 0 }, us = [
|
|
2858
2869
|
"aria-selected",
|
|
2859
2870
|
"aria-label",
|
|
2860
2871
|
"title"
|
|
2861
|
-
],
|
|
2872
|
+
], ds = { key: 0 }, fs = [
|
|
2862
2873
|
"aria-selected",
|
|
2863
2874
|
"aria-label",
|
|
2864
2875
|
"title"
|
|
2865
|
-
],
|
|
2876
|
+
], ps = { key: 0 }, ms = {
|
|
2866
2877
|
key: 1,
|
|
2867
2878
|
class: "tpl:ml-1 tpl:rounded-full tpl:bg-[var(--tpl-bg-hover)] tpl:px-1.5 tpl:text-[10px]"
|
|
2868
|
-
},
|
|
2879
|
+
}, hs = {
|
|
2869
2880
|
key: 0,
|
|
2870
2881
|
id: "tpl-tabpanel-content",
|
|
2871
2882
|
role: "tabpanel",
|
|
2872
2883
|
"aria-labelledby": "tpl-tab-content",
|
|
2873
2884
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2874
|
-
},
|
|
2885
|
+
}, gs = {
|
|
2875
2886
|
key: 1,
|
|
2876
2887
|
class: "tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:px-6 tpl:py-10 tpl:text-center tpl:text-[var(--tpl-text-muted)]"
|
|
2877
|
-
},
|
|
2888
|
+
}, _s = { class: "tpl:mb-4 tpl:text-[var(--tpl-text-dim)]" }, vs = { class: "tpl:m-0 tpl:mb-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, ys = { class: "tpl:m-0 tpl:text-sm tpl:leading-normal" }, bs = {
|
|
2878
2889
|
key: 1,
|
|
2879
2890
|
id: "tpl-tabpanel-settings",
|
|
2880
2891
|
role: "tabpanel",
|
|
2881
2892
|
"aria-labelledby": "tpl-tab-settings",
|
|
2882
2893
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2883
|
-
},
|
|
2894
|
+
}, xs = {
|
|
2884
2895
|
key: 2,
|
|
2885
2896
|
id: "tpl-tabpanel-accessibility",
|
|
2886
2897
|
role: "tabpanel",
|
|
2887
2898
|
"aria-labelledby": "tpl-tab-accessibility",
|
|
2888
2899
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2889
|
-
},
|
|
2900
|
+
}, Ss = /* @__PURE__ */ f({
|
|
2890
2901
|
__name: "RightSidebar",
|
|
2891
2902
|
props: {
|
|
2892
2903
|
selectedBlock: {},
|
|
@@ -2900,7 +2911,7 @@ var wi = {
|
|
|
2900
2911
|
"update-settings"
|
|
2901
2912
|
],
|
|
2902
2913
|
setup(t, { emit: n }) {
|
|
2903
|
-
let r = O(() => import("./AccessibilityPanel-
|
|
2914
|
+
let r = O(() => import("./AccessibilityPanel-D-PqmHdH.js")), i = t, o = n, { t: s } = z(), l = c("content"), u = D(Ie, null), f = m(() => u !== null), p = m(() => u?.issues.value.length ?? 0);
|
|
2904
2915
|
function _(e) {
|
|
2905
2916
|
return l.value === e ? "tpl:flex-1 tpl:text-[var(--tpl-primary)]" : "tpl:shrink-0 tpl:text-[var(--tpl-text-muted)] hover:tpl:text-[var(--tpl-text)]";
|
|
2906
2917
|
}
|
|
@@ -2916,7 +2927,7 @@ var wi = {
|
|
|
2916
2927
|
"aria-label": S(s).landmarks.rightSidebar,
|
|
2917
2928
|
class: d(["tpl-right-sidebar tpl:absolute tpl:top-14 tpl:bottom-0 tpl:z-40 tpl:flex tpl:w-[320px] tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)] tpl:transition-all tpl:duration-200 tpl:border-l tpl:border-[var(--tpl-border)]", t.shiftedLeft ? "tpl:right-[360px]" : "tpl:right-0"])
|
|
2918
2929
|
}, [
|
|
2919
|
-
h("div",
|
|
2930
|
+
h("div", ss, [
|
|
2920
2931
|
h("button", {
|
|
2921
2932
|
id: "tpl-tab-content",
|
|
2922
2933
|
role: "tab",
|
|
@@ -2927,10 +2938,10 @@ var wi = {
|
|
|
2927
2938
|
class: d(["tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:gap-1.5 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", _("content")]),
|
|
2928
2939
|
style: b(y("content")),
|
|
2929
2940
|
onClick: i[0] ||= (e) => l.value = "content"
|
|
2930
|
-
}, [E(S(
|
|
2941
|
+
}, [E(S(_t), {
|
|
2931
2942
|
size: 14,
|
|
2932
2943
|
"stroke-width": 2
|
|
2933
|
-
}), l.value === "content" ? (e(), g("span",
|
|
2944
|
+
}), l.value === "content" ? (e(), g("span", ls, w(S(s).sidebar.content), 1)) : v("", !0)], 14, cs),
|
|
2934
2945
|
h("button", {
|
|
2935
2946
|
id: "tpl-tab-settings",
|
|
2936
2947
|
role: "tab",
|
|
@@ -2941,10 +2952,10 @@ var wi = {
|
|
|
2941
2952
|
class: d(["tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:gap-1.5 tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:px-3 tpl:py-2 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-[120ms] tpl:ease-[cubic-bezier(0.16,1,0.3,1)]", _("settings")]),
|
|
2942
2953
|
style: b(y("settings")),
|
|
2943
2954
|
onClick: i[1] ||= (e) => l.value = "settings"
|
|
2944
|
-
}, [E(S(
|
|
2955
|
+
}, [E(S(yt), {
|
|
2945
2956
|
size: 14,
|
|
2946
2957
|
"stroke-width": 1.5
|
|
2947
|
-
}), l.value === "settings" ? (e(), g("span",
|
|
2958
|
+
}), l.value === "settings" ? (e(), g("span", ds, w(S(s).sidebar.settings), 1)) : v("", !0)], 14, us),
|
|
2948
2959
|
f.value ? (e(), g("button", {
|
|
2949
2960
|
key: 0,
|
|
2950
2961
|
id: "tpl-tab-accessibility",
|
|
@@ -2957,46 +2968,46 @@ var wi = {
|
|
|
2957
2968
|
style: b(y("accessibility")),
|
|
2958
2969
|
onClick: i[2] ||= (e) => l.value = "accessibility"
|
|
2959
2970
|
}, [
|
|
2960
|
-
E(S(
|
|
2971
|
+
E(S(Re), {
|
|
2961
2972
|
size: 14,
|
|
2962
2973
|
"stroke-width": 1.5
|
|
2963
2974
|
}),
|
|
2964
|
-
l.value === "accessibility" ? (e(), g("span",
|
|
2965
|
-
p.value > 0 ? (e(), g("span",
|
|
2966
|
-
], 14,
|
|
2975
|
+
l.value === "accessibility" ? (e(), g("span", ps, w(S(s).accessibility.panelTabLabel), 1)) : v("", !0),
|
|
2976
|
+
p.value > 0 ? (e(), g("span", ms, w(p.value), 1)) : v("", !0)
|
|
2977
|
+
], 14, fs)) : v("", !0)
|
|
2967
2978
|
]),
|
|
2968
|
-
l.value === "content" ? (e(), g("div",
|
|
2979
|
+
l.value === "content" ? (e(), g("div", hs, [t.selectedBlock ? (e(), x(as, {
|
|
2969
2980
|
key: 0,
|
|
2970
2981
|
block: t.selectedBlock,
|
|
2971
2982
|
onUpdate: i[3] ||= (e) => o("update-block", e),
|
|
2972
2983
|
onDelete: i[4] ||= (e) => o("delete-block"),
|
|
2973
2984
|
onDuplicate: i[5] ||= (e) => o("duplicate-block")
|
|
2974
|
-
}, null, 8, ["block"])) : (e(), g("div",
|
|
2975
|
-
h("div",
|
|
2985
|
+
}, null, 8, ["block"])) : (e(), g("div", gs, [
|
|
2986
|
+
h("div", _s, [E(S(ft), {
|
|
2976
2987
|
size: 40,
|
|
2977
2988
|
"stroke-width": 1.5
|
|
2978
2989
|
})]),
|
|
2979
|
-
h("h3",
|
|
2980
|
-
h("p",
|
|
2990
|
+
h("h3", vs, w(S(s).sidebar.noSelection), 1),
|
|
2991
|
+
h("p", ys, w(S(s).sidebar.noSelectionHint), 1)
|
|
2981
2992
|
]))])) : v("", !0),
|
|
2982
|
-
l.value === "settings" ? (e(), g("div",
|
|
2993
|
+
l.value === "settings" ? (e(), g("div", bs, [E(Pn, {
|
|
2983
2994
|
settings: t.settings,
|
|
2984
2995
|
onUpdate: i[6] ||= (e) => o("update-settings", e)
|
|
2985
2996
|
}, null, 8, ["settings"])])) : v("", !0),
|
|
2986
|
-
l.value === "accessibility" && f.value ? (e(), g("div",
|
|
2987
|
-
], 10,
|
|
2997
|
+
l.value === "accessibility" && f.value ? (e(), g("div", xs, [E(S(r))])) : v("", !0)
|
|
2998
|
+
], 10, os));
|
|
2988
2999
|
}
|
|
2989
|
-
}),
|
|
3000
|
+
}), Cs = ["aria-label"], ws = [
|
|
2990
3001
|
"aria-checked",
|
|
2991
3002
|
"aria-label",
|
|
2992
3003
|
"title",
|
|
2993
3004
|
"onClick"
|
|
2994
|
-
],
|
|
3005
|
+
], Ts = /* @__PURE__ */ f({
|
|
2995
3006
|
__name: "ViewportToggle",
|
|
2996
3007
|
props: { viewport: {} },
|
|
2997
3008
|
emits: ["change"],
|
|
2998
3009
|
setup(t, { emit: n }) {
|
|
2999
|
-
let r = t, i = n, { t: a } =
|
|
3010
|
+
let r = t, i = n, { t: a } = z(), s = m(() => [
|
|
3000
3011
|
{
|
|
3001
3012
|
value: "desktop",
|
|
3002
3013
|
label: a.viewport.desktop
|
|
@@ -3040,30 +3051,30 @@ var wi = {
|
|
|
3040
3051
|
}),
|
|
3041
3052
|
title: n.label,
|
|
3042
3053
|
onClick: (e) => i("change", n.value)
|
|
3043
|
-
}, [n.value === "desktop" ? (e(), x(S(
|
|
3054
|
+
}, [n.value === "desktop" ? (e(), x(S(ht), {
|
|
3044
3055
|
key: 0,
|
|
3045
3056
|
size: 18,
|
|
3046
3057
|
"stroke-width": 1.5
|
|
3047
|
-
})) : n.value === "tablet" ? (e(), x(S(
|
|
3058
|
+
})) : n.value === "tablet" ? (e(), x(S(wt), {
|
|
3048
3059
|
key: 1,
|
|
3049
3060
|
size: 18,
|
|
3050
3061
|
"stroke-width": 1.5
|
|
3051
|
-
})) : (e(), x(S(
|
|
3062
|
+
})) : (e(), x(S(bt), {
|
|
3052
3063
|
key: 2,
|
|
3053
3064
|
size: 18,
|
|
3054
3065
|
"stroke-width": 1.5
|
|
3055
|
-
})), h("span", null, w(n.label), 1)], 12,
|
|
3066
|
+
})), h("span", null, w(n.label), 1)], 12, ws))), 128))], 12, Cs));
|
|
3056
3067
|
}
|
|
3057
|
-
}),
|
|
3068
|
+
}), Es = [
|
|
3058
3069
|
"aria-label",
|
|
3059
3070
|
"title",
|
|
3060
3071
|
"aria-pressed"
|
|
3061
|
-
],
|
|
3072
|
+
], Ds = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
3062
3073
|
__name: "PreviewToggle",
|
|
3063
3074
|
props: { previewMode: { type: Boolean } },
|
|
3064
3075
|
emits: ["change"],
|
|
3065
3076
|
setup(t, { emit: n }) {
|
|
3066
|
-
let r = n, { t: i } =
|
|
3077
|
+
let r = n, { t: i } = z();
|
|
3067
3078
|
return (n, a) => (e(), g("button", {
|
|
3068
3079
|
class: "tpl-preview-toggle tpl:relative tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:p-2 tpl:transition-all tpl:duration-150",
|
|
3069
3080
|
style: b({
|
|
@@ -3081,7 +3092,7 @@ var wi = {
|
|
|
3081
3092
|
"leave-to-class": "tpl-icon-leave-to",
|
|
3082
3093
|
mode: "out-in"
|
|
3083
3094
|
}, {
|
|
3084
|
-
default: k(() => [t.previewMode ? (e(), x(S(
|
|
3095
|
+
default: k(() => [t.previewMode ? (e(), x(S(Ue), {
|
|
3085
3096
|
key: "eye",
|
|
3086
3097
|
size: 18,
|
|
3087
3098
|
"stroke-width": 1.5
|
|
@@ -3091,18 +3102,18 @@ var wi = {
|
|
|
3091
3102
|
"stroke-width": 1.5
|
|
3092
3103
|
}))]),
|
|
3093
3104
|
_: 1
|
|
3094
|
-
})], 12,
|
|
3105
|
+
})], 12, Es));
|
|
3095
3106
|
}
|
|
3096
|
-
}), [["__scopeId", "data-v-af87d02a"]]),
|
|
3107
|
+
}), [["__scopeId", "data-v-af87d02a"]]), Os = [
|
|
3097
3108
|
"aria-label",
|
|
3098
3109
|
"title",
|
|
3099
3110
|
"aria-pressed"
|
|
3100
|
-
],
|
|
3111
|
+
], ks = /* @__PURE__ */ H(/* @__PURE__ */ f({
|
|
3101
3112
|
__name: "DarkModeToggle",
|
|
3102
3113
|
props: { darkMode: { type: Boolean } },
|
|
3103
3114
|
emits: ["change"],
|
|
3104
3115
|
setup(t, { emit: n }) {
|
|
3105
|
-
let r = n, { t: i } =
|
|
3116
|
+
let r = n, { t: i } = z();
|
|
3106
3117
|
return (n, a) => (e(), g("button", {
|
|
3107
3118
|
class: "tpl-dark-mode-toggle tpl:relative tpl:flex tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:p-2 tpl:transition-all tpl:duration-150",
|
|
3108
3119
|
style: b({
|
|
@@ -3120,37 +3131,37 @@ var wi = {
|
|
|
3120
3131
|
"leave-to-class": "tpl-icon-leave-to",
|
|
3121
3132
|
mode: "out-in"
|
|
3122
3133
|
}, {
|
|
3123
|
-
default: k(() => [t.darkMode ? (e(), x(S(
|
|
3134
|
+
default: k(() => [t.darkMode ? (e(), x(S(gt), {
|
|
3124
3135
|
key: "moon",
|
|
3125
3136
|
size: 18,
|
|
3126
3137
|
"stroke-width": 1.5
|
|
3127
|
-
})) : (e(), x(S(
|
|
3138
|
+
})) : (e(), x(S(Ct), {
|
|
3128
3139
|
key: "sun",
|
|
3129
3140
|
size: 18,
|
|
3130
3141
|
"stroke-width": 1.5
|
|
3131
3142
|
}))]),
|
|
3132
3143
|
_: 1
|
|
3133
|
-
})], 12,
|
|
3144
|
+
})], 12, Os));
|
|
3134
3145
|
}
|
|
3135
|
-
}), [["__scopeId", "data-v-f8694f76"]]),
|
|
3146
|
+
}), [["__scopeId", "data-v-f8694f76"]]), As = {
|
|
3136
3147
|
class: "tpl:pointer-events-auto tpl:flex tpl:items-center tpl:gap-1.5 tpl:rounded-tl-lg tpl:p-1",
|
|
3137
3148
|
style: {
|
|
3138
3149
|
"background-color": "color-mix(\n in srgb,\n var(--tpl-canvas-bg) 85%,\n transparent\n )",
|
|
3139
3150
|
"backdrop-filter": "blur(8px)",
|
|
3140
3151
|
"-webkit-backdrop-filter": "blur(8px)"
|
|
3141
3152
|
}
|
|
3142
|
-
},
|
|
3153
|
+
}, js = {
|
|
3143
3154
|
href: "https://github.com/templatical/sdk",
|
|
3144
3155
|
target: "_blank",
|
|
3145
3156
|
rel: "noopener noreferrer",
|
|
3146
3157
|
class: "tpl:transition-colors tpl:duration-150 hover:tpl:opacity-80 tpl:text-[var(--tpl-text-dim)]",
|
|
3147
3158
|
style: { "text-decoration": "none" }
|
|
3148
|
-
},
|
|
3159
|
+
}, Ms = /* @__PURE__ */ f({
|
|
3149
3160
|
__name: "EditorFooter",
|
|
3150
3161
|
props: { positionClass: {} },
|
|
3151
3162
|
setup(t) {
|
|
3152
|
-
let { t: n } =
|
|
3153
|
-
return (r, i) => (e(), g("footer", { class: d(["tpl:pointer-events-none tpl:absolute tpl:bottom-0 tpl:z-50 tpl:flex tpl:h-8 tpl:items-center tpl:justify-end tpl:pr-4 tpl:text-[9px] tpl:opacity-90 tpl:transition-all tpl:duration-300 tpl:text-[var(--tpl-text-dim)]", t.positionClass]) }, [h("div",
|
|
3163
|
+
let { t: n } = z();
|
|
3164
|
+
return (r, i) => (e(), g("footer", { class: d(["tpl:pointer-events-none tpl:absolute tpl:bottom-0 tpl:z-50 tpl:flex tpl:h-8 tpl:items-center tpl:justify-end tpl:pr-4 tpl:text-[9px] tpl:opacity-90 tpl:transition-all tpl:duration-300 tpl:text-[var(--tpl-text-dim)]", t.positionClass]) }, [h("div", As, [
|
|
3154
3165
|
h("span", null, w(S(n).footer.poweredBy), 1),
|
|
3155
3166
|
i[0] ||= h("a", {
|
|
3156
3167
|
href: "https://templatical.com",
|
|
@@ -3165,9 +3176,9 @@ var wi = {
|
|
|
3165
3176
|
alt: ""
|
|
3166
3177
|
}), l(" Templatical ")], -1),
|
|
3167
3178
|
i[1] ||= h("span", { class: "tpl:text-[var(--tpl-border)]" }, "·", -1),
|
|
3168
|
-
h("a",
|
|
3179
|
+
h("a", js, w(S(n).footer.openSource), 1)
|
|
3169
3180
|
])], 2));
|
|
3170
3181
|
}
|
|
3171
3182
|
});
|
|
3172
3183
|
//#endregion
|
|
3173
|
-
export {
|
|
3184
|
+
export { Ss as a, Tt as c, Ts as i, vt as l, ks as n, Wt as o, Ds as r, Ft as s, Ms as t };
|