@templatical/editor 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{CloudEditor-CAtw_sFC.js → CloudEditor-DHB1FoQD.js} +1 -1
- package/dist/bundle-stats.json +4 -4
- package/dist/cdn/chunks/{CloudEditor-CyJItWsK.js → CloudEditor-CrZk-OwQ.js} +2 -2
- package/dist/cdn/chunks/{CloudEditor-CyJItWsK.js.map → CloudEditor-CrZk-OwQ.js.map} +1 -1
- package/dist/cdn/chunks/{renderer-7z2t_bYQ.js → renderer-CfHPFI5v.js} +2 -2
- package/dist/cdn/chunks/{renderer-7z2t_bYQ.js.map → renderer-CfHPFI5v.js.map} +1 -1
- package/dist/cdn/chunks/{styles-o0HIrw9F.js → styles-CVUvPdKD.js} +619 -617
- package/dist/cdn/chunks/{styles-o0HIrw9F.js.map → styles-CVUvPdKD.js.map} +1 -1
- package/dist/cdn/editor.js +3 -3
- package/dist/{styles-CJtcKmsx.js → styles-CxwIlb7Y.js} +652 -650
- package/dist/templatical-editor.js +2 -2
- package/package.json +7 -7
|
@@ -1,37 +1,37 @@
|
|
|
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, U as c, X as l, _ as u, a as d, at as f, b as p, c as m, d as h, f as g, h as _, l as v, m as y, o as b, ot as x, p as S, q as C, rt as w, s as T, st as E, t as D, v as O, w as k, y as A, z as j } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import { C as
|
|
3
|
-
import { A as
|
|
2
|
+
import { C as M, D as N, E as P, S as F, a as I, l as L, n as ee, o as te } from "./dist-CIV3Brg-.js";
|
|
3
|
+
import { A as R, F as z, I as ne, M as re, N as ie, T as B, _ as ae, a as oe, c as se, d as ce, g as le, h as ue, i as de, j as fe, k as pe, 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-CEkf_VWX.js";
|
|
4
4
|
import { a as we, c as Te } from "./dist-CNLAS2v2.js";
|
|
5
|
-
import {
|
|
5
|
+
import { A as Ee, D as De, O as Oe, S as ke, a as Ae, b as je, d as Me, f as Ne, h as Pe, j as Fe, n as Ie, o as Le, p as Re, s as ze, u as Be, x as Ve } from "./keys-BiQlvx51.js";
|
|
6
6
|
import { t as V } from "./useI18n-Besvmtxy.js";
|
|
7
7
|
import { t as H } from "./createLucideIcon-XgXOJ05E.js";
|
|
8
|
-
import { t as
|
|
9
|
-
import { t as
|
|
10
|
-
import { i as
|
|
11
|
-
import { n as
|
|
12
|
-
import { t 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 { t as
|
|
26
|
-
import { _ as
|
|
27
|
-
import { i as q, n as J, r as Y, t as
|
|
28
|
-
import { t as
|
|
29
|
-
var
|
|
8
|
+
import { t as He } from "./chevron-down-DJjo0jSV.js";
|
|
9
|
+
import { t as Ue } from "./circle-alert-CPH6l3Lc.js";
|
|
10
|
+
import { i as We, n as Ge, r as Ke, t as qe } from "./blockTypeIcons-DCkHXPhx.js";
|
|
11
|
+
import { n as Je, t as Ye } from "./refresh-cw-CvWF4jfR.js";
|
|
12
|
+
import { t as Xe } from "./image-up-CPBCOMit.js";
|
|
13
|
+
import { t as Ze } from "./info-DIY9mguM.js";
|
|
14
|
+
import { t as Qe } from "./list-checks-CSCyu3fH.js";
|
|
15
|
+
import { t as $e } from "./scan-line-wanvAFDr.js";
|
|
16
|
+
import { t as et } from "./sparkles-CrUN0KWY.js";
|
|
17
|
+
import { n as tt, r as nt, t as rt } from "./text-align-end-Bkq8oBrD.js";
|
|
18
|
+
import { t as it } from "./trash-2-BpY5BCLT.js";
|
|
19
|
+
import { t as at } from "./x-rcnxRG8Y.js";
|
|
20
|
+
import { t as ot } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
21
|
+
import { t as st } from "./useCloudI18n-DKWJg6rJ.js";
|
|
22
|
+
import { t as ct } from "./useMergeTag-WNzaCpXR.js";
|
|
23
|
+
import { t as lt } from "./useAliveFlag-BLyG8L4d.js";
|
|
24
|
+
import { t as ut } from "./readableTextColor-f8Kykfnh.js";
|
|
25
|
+
import { t as dt } from "./CountdownBlock-BTPefclD.js";
|
|
26
|
+
import { _ as ft, c as pt, f as U, g as mt, h as W, l as ht, m as G, p as K, t as gt } from "./styleConstants-lGobwiLH.js";
|
|
27
|
+
import { i as q, n as J, r as Y, t as _t } from "./NumberWithSuffix-CxUBW_V2.js";
|
|
28
|
+
import { t as vt } from "./TplModal-YFpBaiLj.js";
|
|
29
|
+
var yt = H("circle", [["circle", {
|
|
30
30
|
cx: "12",
|
|
31
31
|
cy: "12",
|
|
32
32
|
r: "10",
|
|
33
33
|
key: "1mglay"
|
|
34
|
-
}]]),
|
|
34
|
+
}]]), bt = H("globe", [
|
|
35
35
|
["circle", {
|
|
36
36
|
cx: "12",
|
|
37
37
|
cy: "12",
|
|
@@ -46,7 +46,7 @@ var _t = H("circle", [["circle", {
|
|
|
46
46
|
d: "M2 12h20",
|
|
47
47
|
key: "9i4pu4"
|
|
48
48
|
}]
|
|
49
|
-
]),
|
|
49
|
+
]), xt = H("layout-template", [
|
|
50
50
|
["rect", {
|
|
51
51
|
width: "18",
|
|
52
52
|
height: "7",
|
|
@@ -71,7 +71,7 @@ var _t = H("circle", [["circle", {
|
|
|
71
71
|
rx: "1",
|
|
72
72
|
key: "q5h2i8"
|
|
73
73
|
}]
|
|
74
|
-
]),
|
|
74
|
+
]), St = H("lock-open", [["rect", {
|
|
75
75
|
width: "18",
|
|
76
76
|
height: "11",
|
|
77
77
|
x: "3",
|
|
@@ -82,7 +82,7 @@ var _t = H("circle", [["circle", {
|
|
|
82
82
|
}], ["path", {
|
|
83
83
|
d: "M7 11V7a5 5 0 0 1 9.9-1",
|
|
84
84
|
key: "1mm8w8"
|
|
85
|
-
}]]),
|
|
85
|
+
}]]), Ct = H("lock", [["rect", {
|
|
86
86
|
width: "18",
|
|
87
87
|
height: "11",
|
|
88
88
|
x: "3",
|
|
@@ -93,7 +93,7 @@ var _t = H("circle", [["circle", {
|
|
|
93
93
|
}], ["path", {
|
|
94
94
|
d: "M7 11V7a5 5 0 0 1 10 0v4",
|
|
95
95
|
key: "fwvmzm"
|
|
96
|
-
}]]),
|
|
96
|
+
}]]), wt = H("monitor", [
|
|
97
97
|
["rect", {
|
|
98
98
|
width: "20",
|
|
99
99
|
height: "14",
|
|
@@ -116,10 +116,10 @@ var _t = H("circle", [["circle", {
|
|
|
116
116
|
y2: "21",
|
|
117
117
|
key: "vw1qmm"
|
|
118
118
|
}]
|
|
119
|
-
]),
|
|
119
|
+
]), Tt = H("moon", [["path", {
|
|
120
120
|
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",
|
|
121
121
|
key: "kfwtm"
|
|
122
|
-
}]]),
|
|
122
|
+
}]]), Et = H("panel-top", [["rect", {
|
|
123
123
|
width: "18",
|
|
124
124
|
height: "18",
|
|
125
125
|
x: "3",
|
|
@@ -135,13 +135,13 @@ var _t = H("circle", [["circle", {
|
|
|
135
135
|
}], ["path", {
|
|
136
136
|
d: "M12 5v14",
|
|
137
137
|
key: "s699le"
|
|
138
|
-
}]]),
|
|
138
|
+
}]]), Dt = H("rotate-ccw", [["path", {
|
|
139
139
|
d: "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",
|
|
140
140
|
key: "1357e3"
|
|
141
141
|
}], ["path", {
|
|
142
142
|
d: "M3 3v5h5",
|
|
143
143
|
key: "1xhq8a"
|
|
144
|
-
}]]),
|
|
144
|
+
}]]), Ot = H("settings", [["path", {
|
|
145
145
|
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",
|
|
146
146
|
key: "1i5ecw"
|
|
147
147
|
}], ["circle", {
|
|
@@ -149,7 +149,7 @@ var _t = H("circle", [["circle", {
|
|
|
149
149
|
cy: "12",
|
|
150
150
|
r: "3",
|
|
151
151
|
key: "1v7zrd"
|
|
152
|
-
}]]),
|
|
152
|
+
}]]), kt = H("smartphone", [["rect", {
|
|
153
153
|
width: "14",
|
|
154
154
|
height: "20",
|
|
155
155
|
x: "5",
|
|
@@ -160,7 +160,7 @@ var _t = H("circle", [["circle", {
|
|
|
160
160
|
}], ["path", {
|
|
161
161
|
d: "M12 18h.01",
|
|
162
162
|
key: "mhygvu"
|
|
163
|
-
}]]),
|
|
163
|
+
}]]), At = H("square-plus", [
|
|
164
164
|
["rect", {
|
|
165
165
|
width: "18",
|
|
166
166
|
height: "18",
|
|
@@ -177,14 +177,14 @@ var _t = H("circle", [["circle", {
|
|
|
177
177
|
d: "M12 8v8",
|
|
178
178
|
key: "napkw2"
|
|
179
179
|
}]
|
|
180
|
-
]),
|
|
180
|
+
]), jt = H("square", [["rect", {
|
|
181
181
|
width: "18",
|
|
182
182
|
height: "18",
|
|
183
183
|
x: "3",
|
|
184
184
|
y: "3",
|
|
185
185
|
rx: "2",
|
|
186
186
|
key: "afitv7"
|
|
187
|
-
}]]),
|
|
187
|
+
}]]), Mt = H("sun", [
|
|
188
188
|
["circle", {
|
|
189
189
|
cx: "12",
|
|
190
190
|
cy: "12",
|
|
@@ -223,7 +223,7 @@ var _t = H("circle", [["circle", {
|
|
|
223
223
|
d: "m19.07 4.93-1.41 1.41",
|
|
224
224
|
key: "1shlcs"
|
|
225
225
|
}]
|
|
226
|
-
]),
|
|
226
|
+
]), Nt = H("tablet", [["rect", {
|
|
227
227
|
width: "16",
|
|
228
228
|
height: "20",
|
|
229
229
|
x: "4",
|
|
@@ -240,7 +240,7 @@ var _t = H("circle", [["circle", {
|
|
|
240
240
|
}]]);
|
|
241
241
|
//#endregion
|
|
242
242
|
//#region src/utils/resolveLintOptions.ts
|
|
243
|
-
function
|
|
243
|
+
function Pt(e) {
|
|
244
244
|
return {
|
|
245
245
|
...e.lint,
|
|
246
246
|
locale: e.locale
|
|
@@ -248,19 +248,19 @@ function Mt(e) {
|
|
|
248
248
|
}
|
|
249
249
|
//#endregion
|
|
250
250
|
//#region src/components/Canvas.vue?vue&type=script&setup=true&lang.ts
|
|
251
|
-
var
|
|
251
|
+
var Ft = ["aria-label"], It = {
|
|
252
252
|
key: 0,
|
|
253
253
|
class: "tpl-canvas-empty-content tpl:flex tpl:flex-col tpl:items-center"
|
|
254
|
-
},
|
|
254
|
+
}, Lt = { class: "tpl-canvas-empty-icon tpl:mb-4 tpl:text-[var(--tpl-primary)]" }, Rt = { class: "tpl-canvas-empty-title tpl:m-0 tpl:mb-2 tpl:text-base tpl:font-semibold tpl:text-[var(--tpl-primary)]" }, zt = { class: "tpl-canvas-empty-text tpl:m-0 tpl:text-sm tpl:text-[var(--tpl-text-dim)]" }, Bt = {
|
|
255
255
|
key: 0,
|
|
256
256
|
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)]"
|
|
257
|
-
},
|
|
257
|
+
}, Vt = {
|
|
258
258
|
key: 1,
|
|
259
259
|
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)]"
|
|
260
|
-
},
|
|
260
|
+
}, Ht = { class: "tpl:relative" }, Ut = {
|
|
261
261
|
class: "tpl:inline-flex tpl:size-3 tpl:items-center tpl:justify-center tpl:rounded-full tpl:text-[8px] tpl:font-bold",
|
|
262
262
|
style: { "background-color": "color-mix(\n in srgb,\n var(--tpl-bg) 30%,\n transparent\n )" }
|
|
263
|
-
},
|
|
263
|
+
}, Wt = /* @__PURE__ */ ot(/* @__PURE__ */ p({
|
|
264
264
|
__name: "Canvas",
|
|
265
265
|
props: {
|
|
266
266
|
viewport: {},
|
|
@@ -289,9 +289,9 @@ var Nt = ["aria-label"], Pt = {
|
|
|
289
289
|
menu: ue,
|
|
290
290
|
table: ye,
|
|
291
291
|
video: ge,
|
|
292
|
-
countdown:
|
|
292
|
+
countdown: dt,
|
|
293
293
|
custom: Ce
|
|
294
|
-
}, s = n, c = i, { t: d } = V(), { t: p } =
|
|
294
|
+
}, s = n, c = i, { t: d } = V(), { t: p } = st(), m = Fe(Re, "Canvas"), C = k(Be, null), T = k(Le, null), D = k(ze, {}), A = h(() => (D.plan?.hasFeature("ai_generation") ?? !1) && (D.ai?.isFeatureEnabled("chat") ?? !1)), M = h(() => (D.plan?.hasFeature("ai_generation") ?? !1) && (D.ai?.isFeatureEnabled("designToTemplate") ?? !1)), N = h({
|
|
295
295
|
get: () => s.content.blocks,
|
|
296
296
|
set: (e) => {
|
|
297
297
|
m.setContent({
|
|
@@ -299,21 +299,21 @@ var Nt = ["aria-label"], Pt = {
|
|
|
299
299
|
blocks: e
|
|
300
300
|
});
|
|
301
301
|
}
|
|
302
|
-
}),
|
|
302
|
+
}), P = h(() => {
|
|
303
303
|
switch (s.viewport) {
|
|
304
304
|
case "mobile": return 375;
|
|
305
305
|
case "tablet": return 768;
|
|
306
306
|
default: return s.content.settings.width;
|
|
307
307
|
}
|
|
308
|
-
}),
|
|
308
|
+
}), F = h(() => ({ fontFamily: s.content.settings.fontFamily })), I = h(() => N.value.length === 0 && !s.previewMode), L = l(0), ee = h(() => I.value && L.value > 0);
|
|
309
|
+
function te() {
|
|
310
|
+
I.value && (L.value += 1);
|
|
311
|
+
}
|
|
309
312
|
function R() {
|
|
310
|
-
|
|
313
|
+
I.value && (L.value = Math.max(0, L.value - 1));
|
|
311
314
|
}
|
|
312
315
|
function z() {
|
|
313
|
-
|
|
314
|
-
}
|
|
315
|
-
function te() {
|
|
316
|
-
I.value = 0;
|
|
316
|
+
L.value = 0;
|
|
317
317
|
}
|
|
318
318
|
function ne(e) {
|
|
319
319
|
s.previewMode || e.target === e.currentTarget && c("select-block", null);
|
|
@@ -336,7 +336,7 @@ var Nt = ["aria-label"], Pt = {
|
|
|
336
336
|
"aria-label": w(d).landmarks.canvas,
|
|
337
337
|
class: "tpl-canvas-wrapper tpl:relative tpl:rounded-lg",
|
|
338
338
|
style: x({
|
|
339
|
-
width: `${
|
|
339
|
+
width: `${P.value}px`,
|
|
340
340
|
boxShadow: n.darkMode ? "none" : "var(--tpl-shadow-xl)",
|
|
341
341
|
transition: "width 300ms cubic-bezier(0.34, 1.56, 0.64, 1)"
|
|
342
342
|
})
|
|
@@ -352,11 +352,11 @@ var Nt = ["aria-label"], Pt = {
|
|
|
352
352
|
"tpl-canvas--dark-mode": n.darkMode,
|
|
353
353
|
"tpl-preview-mode": n.previewMode
|
|
354
354
|
}]),
|
|
355
|
-
style: x(
|
|
355
|
+
style: x(F.value),
|
|
356
356
|
onClick: ne
|
|
357
357
|
}, [O(w(me), {
|
|
358
|
-
modelValue:
|
|
359
|
-
"onUpdate:modelValue": a[2] ||= (e) =>
|
|
358
|
+
modelValue: N.value,
|
|
359
|
+
"onUpdate:modelValue": a[2] ||= (e) => N.value = e,
|
|
360
360
|
group: "blocks",
|
|
361
361
|
animation: 150,
|
|
362
362
|
"ghost-class": "tpl-ghost",
|
|
@@ -369,47 +369,47 @@ var Nt = ["aria-label"], Pt = {
|
|
|
369
369
|
"force-fallback": !0,
|
|
370
370
|
class: f([
|
|
371
371
|
"tpl-canvas-blocks",
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
372
|
+
I.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" : "",
|
|
373
|
+
I.value && ee.value ? "tpl-canvas-empty--drag-over tpl:border-[var(--tpl-primary-hover)] tpl:bg-[var(--tpl-primary-light)]" : "",
|
|
374
|
+
I.value && !ee.value ? "tpl:border-[var(--tpl-primary)]" : ""
|
|
375
375
|
]),
|
|
376
|
-
onDragenter:
|
|
377
|
-
onDragleave:
|
|
378
|
-
onDrop:
|
|
376
|
+
onDragenter: te,
|
|
377
|
+
onDragleave: R,
|
|
378
|
+
onDrop: z
|
|
379
379
|
}, {
|
|
380
|
-
default: j(() => [
|
|
381
|
-
g("div",
|
|
380
|
+
default: j(() => [I.value ? (e(), _("div", It, [
|
|
381
|
+
g("div", Lt, [O(w(At), {
|
|
382
382
|
size: 48,
|
|
383
383
|
"stroke-width": 1
|
|
384
384
|
})]),
|
|
385
|
-
g("p",
|
|
386
|
-
g("p",
|
|
387
|
-
A.value && w(p) ? (e(), _("p",
|
|
385
|
+
g("p", Rt, E(w(d).canvas.noBlocks), 1),
|
|
386
|
+
g("p", zt, E(w(d).canvas.dragHint), 1),
|
|
387
|
+
A.value && w(p) ? (e(), _("p", Bt, [
|
|
388
388
|
u(E(w(d).canvas.aiHintChat) + " ", 1),
|
|
389
389
|
g("button", {
|
|
390
390
|
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)]",
|
|
391
391
|
onClick: a[0] ||= (e) => c("open-ai-chat")
|
|
392
|
-
}, [O(w(
|
|
392
|
+
}, [O(w(et), {
|
|
393
393
|
size: 14,
|
|
394
394
|
"stroke-width": 2
|
|
395
395
|
}), u(" " + E(w(p).aiMenu.aiAssistant), 1)]),
|
|
396
396
|
u(" " + E(w(d).canvas.aiHintChatSuffix), 1)
|
|
397
397
|
])) : y("", !0),
|
|
398
|
-
|
|
398
|
+
M.value && w(p) ? (e(), _("p", Vt, [
|
|
399
399
|
u(E(w(d).canvas.aiHintDesign) + " ", 1),
|
|
400
400
|
g("button", {
|
|
401
401
|
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)]",
|
|
402
402
|
onClick: a[1] ||= (e) => c("open-design-reference")
|
|
403
|
-
}, [O(w(
|
|
403
|
+
}, [O(w(Xe), {
|
|
404
404
|
size: 14,
|
|
405
405
|
"stroke-width": 2
|
|
406
406
|
}), u(" " + E(w(p).aiMenu.designToTemplate), 1)]),
|
|
407
407
|
u(" " + E(w(d).canvas.aiHintDesignSuffix), 1)
|
|
408
408
|
])) : y("", !0)
|
|
409
|
-
])) : y("", !0), (e(!0), _(v, null, o(
|
|
409
|
+
])) : y("", !0), (e(!0), _(v, null, o(N.value, (i) => t((e(), _("div", {
|
|
410
410
|
key: i.id,
|
|
411
411
|
class: "tpl-block-item"
|
|
412
|
-
}, [g("div",
|
|
412
|
+
}, [g("div", Ht, [B(i.id) ? (e(), _("div", {
|
|
413
413
|
key: 0,
|
|
414
414
|
class: "tpl-collab-lock tpl:pointer-events-none tpl:absolute tpl:inset-0 tpl:z-[4] tpl:rounded-sm",
|
|
415
415
|
style: x({
|
|
@@ -420,9 +420,9 @@ var Nt = ["aria-label"], Pt = {
|
|
|
420
420
|
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",
|
|
421
421
|
style: x({
|
|
422
422
|
backgroundColor: B(i.id).color,
|
|
423
|
-
color: w(
|
|
423
|
+
color: w(ut)(B(i.id).color)
|
|
424
424
|
})
|
|
425
|
-
}, [g("span",
|
|
425
|
+
}, [g("span", Ut, E(B(i.id).name.charAt(0)), 1), u(" " + E(B(i.id).name), 1)], 4)], 4)) : y("", !0), O(ce, {
|
|
426
426
|
block: i,
|
|
427
427
|
"is-selected": !n.previewMode && n.selectedBlockId === i.id && !B(i.id),
|
|
428
428
|
viewport: n.viewport,
|
|
@@ -453,29 +453,29 @@ var Nt = ["aria-label"], Pt = {
|
|
|
453
453
|
"modelValue",
|
|
454
454
|
"disabled",
|
|
455
455
|
"class"
|
|
456
|
-
])], 6)], 12,
|
|
456
|
+
])], 6)], 12, Ft));
|
|
457
457
|
}
|
|
458
|
-
}), [["__scopeId", "data-v-a4d3fa2d"]]),
|
|
458
|
+
}), [["__scopeId", "data-v-a4d3fa2d"]]), Gt = ["aria-label"], Kt = {
|
|
459
459
|
key: 0,
|
|
460
460
|
class: "tpl:border-b tpl:px-1 tpl:pb-1 tpl:border-[var(--tpl-border)]"
|
|
461
|
-
},
|
|
461
|
+
}, qt = ["aria-label"], Jt = {
|
|
462
462
|
key: 0,
|
|
463
463
|
class: "tpl:flex-1 tpl:truncate tpl:text-sm tpl:font-medium"
|
|
464
|
-
},
|
|
464
|
+
}, Yt = {
|
|
465
465
|
key: 1,
|
|
466
466
|
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)]"
|
|
467
|
-
},
|
|
467
|
+
}, Xt = [
|
|
468
468
|
"data-palette-type",
|
|
469
469
|
"aria-label",
|
|
470
470
|
"onClick",
|
|
471
471
|
"onKeydown"
|
|
472
|
-
],
|
|
472
|
+
], Zt = { 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" }, Qt = {
|
|
473
473
|
key: 0,
|
|
474
474
|
class: "tpl:truncate tpl:text-sm tpl:font-medium"
|
|
475
|
-
},
|
|
475
|
+
}, $t = /* @__PURE__ */ p({
|
|
476
476
|
__name: "Sidebar",
|
|
477
477
|
setup(t) {
|
|
478
|
-
let { t: n, format: i } = V(), { t: a } =
|
|
478
|
+
let { t: n, format: i } = V(), { t: a } = st(), s = k(Me, []), c = k(Ae, void 0), u = k(Re, null), d = k(ze, {}), f = h(() => (d.savedModules?.moduleCount.value ?? 0) > 0), p = l(!1), m = l(!1);
|
|
479
479
|
function b() {
|
|
480
480
|
m.value || (p.value = !1);
|
|
481
481
|
}
|
|
@@ -501,32 +501,32 @@ var Nt = ["aria-label"], Pt = {
|
|
|
501
501
|
], A = h(() => {
|
|
502
502
|
let e = D.map((e) => ({
|
|
503
503
|
type: e,
|
|
504
|
-
label:
|
|
504
|
+
label: z(e, n)
|
|
505
505
|
}));
|
|
506
506
|
return d.plan && e.splice(-1, 0, {
|
|
507
507
|
type: "countdown",
|
|
508
|
-
label:
|
|
508
|
+
label: z("countdown", n)
|
|
509
509
|
}), e;
|
|
510
|
-
}),
|
|
510
|
+
}), M = h(() => s.map((e) => ({
|
|
511
511
|
type: `custom:${e.type}`,
|
|
512
512
|
label: e.name,
|
|
513
513
|
isCustom: !0,
|
|
514
514
|
icon: e.icon
|
|
515
|
-
}))),
|
|
516
|
-
function
|
|
515
|
+
}))), N = h(() => [...A.value, ...M.value]);
|
|
516
|
+
function P(e) {
|
|
517
517
|
if (e.isCustom) {
|
|
518
518
|
let t = e.type.replace("custom:", ""), n = s.find((e) => e.type === t);
|
|
519
|
-
if (n) return
|
|
519
|
+
if (n) return L(n);
|
|
520
520
|
}
|
|
521
|
-
return
|
|
521
|
+
return te(e.type, c);
|
|
522
522
|
}
|
|
523
|
-
function
|
|
523
|
+
function F(e) {
|
|
524
524
|
if (!u) return;
|
|
525
|
-
let t =
|
|
525
|
+
let t = P(e);
|
|
526
526
|
u.addBlock(t), u.selectBlock(t.id);
|
|
527
527
|
}
|
|
528
|
-
function
|
|
529
|
-
(e.key === "Enter" || e.key === " ") && (e.preventDefault(),
|
|
528
|
+
function I(e, t) {
|
|
529
|
+
(e.key === "Enter" || e.key === " ") && (e.preventDefault(), F(t));
|
|
530
530
|
}
|
|
531
531
|
return (t, s) => (e(), _("aside", {
|
|
532
532
|
"aria-label": w(n).sidebarNav.palette,
|
|
@@ -542,28 +542,28 @@ var Nt = ["aria-label"], Pt = {
|
|
|
542
542
|
onMouseleave: b,
|
|
543
543
|
onFocusin: s[2] ||= (e) => p.value = !0,
|
|
544
544
|
onFocusout: s[3] ||= (e) => p.value = !1
|
|
545
|
-
}, [f.value && w(a) ? (e(), _("div",
|
|
545
|
+
}, [f.value && w(a) ? (e(), _("div", Kt, [g("button", {
|
|
546
546
|
type: "button",
|
|
547
547
|
"aria-label": w(n).sidebarNav.browseModules,
|
|
548
548
|
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)]",
|
|
549
549
|
style: x({ justifyContent: p.value ? "flex-start" : "center" }),
|
|
550
550
|
onClick: s[0] ||= (e) => w(d).savedModules?.openBrowser()
|
|
551
551
|
}, [
|
|
552
|
-
O(w(
|
|
552
|
+
O(w(Ke), {
|
|
553
553
|
size: 20,
|
|
554
554
|
"stroke-width": 1.5,
|
|
555
555
|
class: "tpl:shrink-0"
|
|
556
556
|
}),
|
|
557
|
-
p.value ? (e(), _("span",
|
|
558
|
-
p.value ? (e(), _("span",
|
|
559
|
-
], 12,
|
|
560
|
-
"model-value":
|
|
557
|
+
p.value ? (e(), _("span", Jt, E(w(a).modules.title), 1)) : y("", !0),
|
|
558
|
+
p.value ? (e(), _("span", Yt, E(w(d).savedModules?.moduleCount.value ?? 0), 1)) : y("", !0)
|
|
559
|
+
], 12, qt)])) : y("", !0), O(w(me), {
|
|
560
|
+
"model-value": N.value,
|
|
561
561
|
group: {
|
|
562
562
|
name: "blocks",
|
|
563
563
|
pull: "clone",
|
|
564
564
|
put: !1
|
|
565
565
|
},
|
|
566
|
-
clone:
|
|
566
|
+
clone: P,
|
|
567
567
|
sort: !1,
|
|
568
568
|
animation: 150,
|
|
569
569
|
"ghost-class": "tpl-ghost",
|
|
@@ -572,16 +572,16 @@ var Nt = ["aria-label"], Pt = {
|
|
|
572
572
|
onChoose: C,
|
|
573
573
|
onEnd: T
|
|
574
574
|
}, {
|
|
575
|
-
default: j(() => [(e(!0), _(v, null, o(
|
|
575
|
+
default: j(() => [(e(!0), _(v, null, o(N.value, (t) => (e(), _("button", {
|
|
576
576
|
key: t.type,
|
|
577
577
|
type: "button",
|
|
578
578
|
"data-palette-type": t.type,
|
|
579
579
|
"aria-label": w(i)(w(n).sidebarNav.insertBlock, { block: t.label }),
|
|
580
580
|
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",
|
|
581
581
|
style: x({ justifyContent: p.value ? "flex-start" : "center" }),
|
|
582
|
-
onClick: (e) =>
|
|
583
|
-
onKeydown: (e) =>
|
|
584
|
-
}, [g("div",
|
|
582
|
+
onClick: (e) => F(t),
|
|
583
|
+
onKeydown: (e) => I(e, t)
|
|
584
|
+
}, [g("div", Zt, [w(qe)[t.type] ? (e(), S(r(w(qe)[t.type]), {
|
|
585
585
|
key: 0,
|
|
586
586
|
size: 20,
|
|
587
587
|
"stroke-width": 1.5
|
|
@@ -589,15 +589,15 @@ var Nt = ["aria-label"], Pt = {
|
|
|
589
589
|
key: 1,
|
|
590
590
|
icon: t.icon,
|
|
591
591
|
size: 20
|
|
592
|
-
}, null, 8, ["icon"])) : y("", !0)]), p.value ? (e(), _("span",
|
|
592
|
+
}, null, 8, ["icon"])) : y("", !0)]), p.value ? (e(), _("span", Qt, E(t.label), 1)) : y("", !0)], 44, Xt))), 128))]),
|
|
593
593
|
_: 1
|
|
594
|
-
}, 8, ["model-value"])], 44,
|
|
594
|
+
}, 8, ["model-value"])], 44, Gt));
|
|
595
595
|
}
|
|
596
596
|
});
|
|
597
597
|
//#endregion
|
|
598
598
|
//#region src/composables/useMergeTagField.ts
|
|
599
|
-
function
|
|
600
|
-
let { modelValue: t, emit: r, elementRef: i } = e, { canRequestMergeTag: a, isRequesting: o, isMergeTagValue: s, getMergeTagLabel: u, requestMergeTag: d, syntax: f } =
|
|
599
|
+
function en(e) {
|
|
600
|
+
let { modelValue: t, emit: r, elementRef: i } = e, { canRequestMergeTag: a, isRequesting: o, isMergeTagValue: s, getMergeTagLabel: u, requestMergeTag: d, syntax: f } = ct(), p = l(!1), m = !1, g = !1;
|
|
601
601
|
c() && C(() => {
|
|
602
602
|
g = !0;
|
|
603
603
|
});
|
|
@@ -615,10 +615,10 @@ function Qt(e) {
|
|
|
615
615
|
type: "mergeTag",
|
|
616
616
|
value: t,
|
|
617
617
|
label: u(t)
|
|
618
|
-
}) :
|
|
618
|
+
}) : N(t, f) ? n.push({
|
|
619
619
|
type: "logicMergeTag",
|
|
620
620
|
value: t,
|
|
621
|
-
keyword:
|
|
621
|
+
keyword: M(t, f)
|
|
622
622
|
}) : n.push({
|
|
623
623
|
type: "text",
|
|
624
624
|
value: t
|
|
@@ -678,10 +678,10 @@ function Qt(e) {
|
|
|
678
678
|
}
|
|
679
679
|
//#endregion
|
|
680
680
|
//#region src/components/MergeTagSegments.vue?vue&type=script&setup=true&lang.ts
|
|
681
|
-
var
|
|
681
|
+
var tn = ["aria-label", "onKeydown"], nn = ["data-tooltip"], rn = ["data-tooltip"], an = {
|
|
682
682
|
key: 2,
|
|
683
683
|
class: "tpl:text-sm tpl:text-[var(--tpl-text)]"
|
|
684
|
-
},
|
|
684
|
+
}, on = ["aria-label", "title"], sn = /* @__PURE__ */ p({
|
|
685
685
|
__name: "MergeTagSegments",
|
|
686
686
|
props: {
|
|
687
687
|
segments: {},
|
|
@@ -709,7 +709,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
709
709
|
"background-color": "color-mix(\n in srgb,\n var(--tpl-primary) 20%,\n transparent\n )",
|
|
710
710
|
color: "var(--tpl-primary)"
|
|
711
711
|
}
|
|
712
|
-
}, E(t.label), 9,
|
|
712
|
+
}, E(t.label), 9, nn)) : t.type === "logicMergeTag" ? (e(), _("span", {
|
|
713
713
|
key: 1,
|
|
714
714
|
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",
|
|
715
715
|
"data-tooltip": t.value,
|
|
@@ -718,22 +718,22 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
718
718
|
border: "1.5px solid\n color-mix(in srgb, var(--tpl-primary) 50%, transparent)",
|
|
719
719
|
color: "var(--tpl-primary)"
|
|
720
720
|
}
|
|
721
|
-
}, E(t.keyword), 9,
|
|
721
|
+
}, E(t.keyword), 9, rn)) : (e(), _("span", an, E(t.value), 1))], 64))), 128)), g("button", {
|
|
722
722
|
type: "button",
|
|
723
723
|
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",
|
|
724
724
|
"aria-label": w(i).mergeTag.remove,
|
|
725
725
|
title: w(i).mergeTag.remove,
|
|
726
726
|
onClick: s[0] ||= m((e) => r("clear"), ["stop"])
|
|
727
|
-
}, [O(w(
|
|
727
|
+
}, [O(w(at), {
|
|
728
728
|
size: 12,
|
|
729
729
|
"stroke-width": 2.5
|
|
730
|
-
})], 8,
|
|
730
|
+
})], 8, on)], 42, tn));
|
|
731
731
|
}
|
|
732
|
-
}),
|
|
732
|
+
}), cn = [
|
|
733
733
|
"aria-label",
|
|
734
734
|
"title",
|
|
735
735
|
"disabled"
|
|
736
|
-
],
|
|
736
|
+
], ln = "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)]", un = /* @__PURE__ */ p({
|
|
737
737
|
__name: "MergeTagInsertButton",
|
|
738
738
|
props: { disabled: { type: Boolean } },
|
|
739
739
|
emits: ["insert"],
|
|
@@ -741,21 +741,21 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
741
741
|
let { t: n } = V();
|
|
742
742
|
return (r, i) => (e(), _("button", {
|
|
743
743
|
type: "button",
|
|
744
|
-
class: f([
|
|
744
|
+
class: f([ln, "tpl:mt-1.5"]),
|
|
745
745
|
"aria-label": w(n).mergeTag.insert,
|
|
746
746
|
title: w(n).mergeTag.insert,
|
|
747
747
|
disabled: t.disabled,
|
|
748
748
|
onClick: i[0] ||= (e) => r.$emit("insert")
|
|
749
|
-
}, [O(w(
|
|
749
|
+
}, [O(w($e), {
|
|
750
750
|
size: 12,
|
|
751
751
|
"stroke-width": 2
|
|
752
|
-
}), u(" " + E(w(n).mergeTag.insert), 1)], 10,
|
|
752
|
+
}), u(" " + E(w(n).mergeTag.insert), 1)], 10, cn));
|
|
753
753
|
}
|
|
754
|
-
}),
|
|
754
|
+
}), dn = { key: 0 }, fn = { key: 1 }, pn = [
|
|
755
755
|
"value",
|
|
756
756
|
"placeholder",
|
|
757
757
|
"rows"
|
|
758
|
-
],
|
|
758
|
+
], mn = "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)]", hn = "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)]", gn = /* @__PURE__ */ p({
|
|
759
759
|
__name: "MergeTagTextarea",
|
|
760
760
|
props: {
|
|
761
761
|
modelValue: {},
|
|
@@ -764,46 +764,46 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
764
764
|
},
|
|
765
765
|
emits: ["update:modelValue"],
|
|
766
766
|
setup(t, { emit: n }) {
|
|
767
|
-
let r = t, i = n, a = l(null), { segments: o, hasMergeTags: s, canRequestMergeTag: c, isRequestingMergeTag: u, isEditing: d, startEditing: p, stopEditing: m, handleInput: h, clearValue: v, insertMergeTag: b } =
|
|
767
|
+
let r = t, i = n, a = l(null), { segments: o, hasMergeTags: s, canRequestMergeTag: c, isRequestingMergeTag: u, isEditing: d, startEditing: p, stopEditing: m, handleInput: h, clearValue: v, insertMergeTag: b } = en({
|
|
768
768
|
modelValue: () => r.modelValue,
|
|
769
769
|
emit: (e) => i("update:modelValue", e),
|
|
770
770
|
elementRef: a
|
|
771
771
|
});
|
|
772
|
-
return (n, r) => w(s) && !w(d) ? (e(), _("div",
|
|
772
|
+
return (n, r) => w(s) && !w(d) ? (e(), _("div", dn, [O(sn, {
|
|
773
773
|
segments: w(o),
|
|
774
|
-
"display-class":
|
|
774
|
+
"display-class": hn,
|
|
775
775
|
onEdit: w(p),
|
|
776
776
|
onClear: w(v)
|
|
777
777
|
}, null, 8, [
|
|
778
778
|
"segments",
|
|
779
779
|
"onEdit",
|
|
780
780
|
"onClear"
|
|
781
|
-
]), w(c) ? (e(), S(
|
|
781
|
+
]), w(c) ? (e(), S(un, {
|
|
782
782
|
key: 0,
|
|
783
783
|
disabled: w(u),
|
|
784
784
|
onInsert: w(b)
|
|
785
|
-
}, null, 8, ["disabled", "onInsert"])) : y("", !0)])) : (e(), _("div",
|
|
785
|
+
}, null, 8, ["disabled", "onInsert"])) : y("", !0)])) : (e(), _("div", fn, [g("textarea", {
|
|
786
786
|
ref_key: "textareaRef",
|
|
787
787
|
ref: a,
|
|
788
|
-
class: f(
|
|
788
|
+
class: f(mn),
|
|
789
789
|
value: t.modelValue,
|
|
790
790
|
placeholder: t.placeholder,
|
|
791
791
|
rows: t.rows,
|
|
792
792
|
onInput: r[0] ||= (...e) => w(h) && w(h)(...e),
|
|
793
793
|
onBlur: r[1] ||= (...e) => w(m) && w(m)(...e),
|
|
794
794
|
onKeydown: r[2] ||= T((...e) => w(m) && w(m)(...e), ["escape"])
|
|
795
|
-
}, null, 40,
|
|
795
|
+
}, null, 40, pn), w(c) ? (e(), S(un, {
|
|
796
796
|
key: 0,
|
|
797
797
|
disabled: w(u),
|
|
798
798
|
onInsert: w(b)
|
|
799
799
|
}, null, 8, ["disabled", "onInsert"])) : y("", !0)]));
|
|
800
800
|
}
|
|
801
|
-
}),
|
|
801
|
+
}), _n = { class: "tpl:flex tpl:w-full tpl:flex-1 tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)]" }, vn = { class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:gap-3 tpl:overflow-y-auto tpl:p-4" }, yn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, bn = { class: "tpl:mb-3.5" }, xn = { 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)]" }, Sn = ["onClick"], Cn = { class: "tpl:flex tpl:items-stretch" }, wn = ["value"], Tn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, En = { class: "tpl:mb-3.5" }, Dn = ["value"], On = ["value"], kn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, An = ["value"], jn = { class: "tpl:mt-1 tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, Mn = { class: "tpl:mb-3.5 tpl:flex tpl:items-center tpl:gap-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, Nn = { class: "tpl:mt-1 tpl:flex tpl:items-start tpl:justify-between tpl:gap-2" }, Pn = { class: "tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, Fn = { class: "tpl:shrink-0 tpl:text-xs tpl:tabular-nums tpl:text-[var(--tpl-text-dim)]" }, In = { class: "tpl:rounded-[var(--tpl-radius)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:p-3" }, Ln = { 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)]" }, Rn = { class: "tpl:m-0 tpl:pl-[18px] tpl:text-xs tpl:leading-relaxed tpl:text-[var(--tpl-text-dim)]" }, zn = { class: "tpl:mb-1 tpl:last:mb-0" }, Bn = { class: "tpl:mb-1 tpl:last:mb-0" }, Vn = { class: "tpl:mb-1 tpl:last:mb-0" }, Hn = 150, Un = /* @__PURE__ */ p({
|
|
802
802
|
__name: "TemplateSettings",
|
|
803
803
|
props: { settings: {} },
|
|
804
804
|
emits: ["update"],
|
|
805
805
|
setup(t, { emit: n }) {
|
|
806
|
-
let r = t, i = n, { t: a } = V(), s =
|
|
806
|
+
let r = t, i = n, { t: a } = V(), s = Fe(Pe, "TemplateSettings"), c = h(() => s.fonts.value), l = h(() => c.value.some((e) => e.value === r.settings.fontFamily) ? r.settings.fontFamily : s.defaultFont.value), u = [
|
|
807
807
|
{
|
|
808
808
|
value: 480,
|
|
809
809
|
label: "480px"
|
|
@@ -821,14 +821,14 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
821
821
|
label: "800px"
|
|
822
822
|
}
|
|
823
823
|
];
|
|
824
|
-
return (n, r) => (e(), _("aside",
|
|
825
|
-
g("div", { class: f(w(
|
|
826
|
-
g("div",
|
|
824
|
+
return (n, r) => (e(), _("aside", _n, [g("div", vn, [
|
|
825
|
+
g("div", { class: f(w(ht)) }, [
|
|
826
|
+
g("div", yn, [O(w(jt), {
|
|
827
827
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
828
828
|
size: 14,
|
|
829
829
|
"stroke-width": 2
|
|
830
830
|
}), g("span", null, E(w(a).templateSettings.layout), 1)]),
|
|
831
|
-
g("div",
|
|
831
|
+
g("div", bn, [g("label", { class: f(w(W)) }, E(w(a).templateSettings.widthPreset), 3), g("div", xn, [(e(), _(v, null, o(u, (e) => g("button", {
|
|
832
832
|
key: e.value,
|
|
833
833
|
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)]",
|
|
834
834
|
style: x({
|
|
@@ -837,25 +837,25 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
837
837
|
boxShadow: t.settings.width === e.value ? "var(--tpl-shadow)" : "none"
|
|
838
838
|
}),
|
|
839
839
|
onClick: (t) => i("update", { width: e.value })
|
|
840
|
-
}, E(e.label), 13,
|
|
841
|
-
g("div", null, [g("label", { class: f(w(W)) }, E(w(a).templateSettings.customWidth), 3), g("div",
|
|
840
|
+
}, E(e.label), 13, Sn)), 64))])]),
|
|
841
|
+
g("div", null, [g("label", { class: f(w(W)) }, E(w(a).templateSettings.customWidth), 3), g("div", Cn, [g("input", {
|
|
842
842
|
type: "number",
|
|
843
843
|
class: f(w(K)),
|
|
844
844
|
value: t.settings.width,
|
|
845
845
|
min: "300",
|
|
846
846
|
max: "900",
|
|
847
847
|
onInput: r[0] ||= (e) => i("update", { width: Number(e.target.value) })
|
|
848
|
-
}, null, 42,
|
|
848
|
+
}, null, 42, wn), g("span", { class: f(w(G)) }, "px", 2)])])
|
|
849
849
|
], 2),
|
|
850
|
-
g("div", { class: f(w(
|
|
851
|
-
g("div",
|
|
850
|
+
g("div", { class: f(w(ht)) }, [
|
|
851
|
+
g("div", Tn, [O(w(yt), {
|
|
852
852
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
853
853
|
size: 14,
|
|
854
854
|
"stroke-width": 2
|
|
855
855
|
}), g("span", null, E(w(a).templateSettings.appearance), 1)]),
|
|
856
|
-
g("div",
|
|
856
|
+
g("div", En, [g("label", { class: f(w(W)) }, E(w(a).templateSettings.backgroundColor), 3), O(q, {
|
|
857
857
|
"model-value": t.settings.backgroundColor,
|
|
858
|
-
placeholder: w(
|
|
858
|
+
placeholder: w(gt),
|
|
859
859
|
"onUpdate:modelValue": r[1] ||= (e) => i("update", { backgroundColor: e })
|
|
860
860
|
}, null, 8, ["model-value", "placeholder"])]),
|
|
861
861
|
g("div", null, [g("label", { class: f(w(W)) }, E(w(a).templateSettings.fontFamily), 3), g("select", {
|
|
@@ -865,9 +865,9 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
865
865
|
}, [(e(!0), _(v, null, o(c.value, (t) => (e(), _("option", {
|
|
866
866
|
key: t.value,
|
|
867
867
|
value: t.value
|
|
868
|
-
}, E(t.label), 9,
|
|
868
|
+
}, E(t.label), 9, On))), 128))], 42, Dn)])
|
|
869
869
|
], 2),
|
|
870
|
-
g("div", { class: f(w(
|
|
870
|
+
g("div", { class: f(w(ht)) }, [g("div", kn, [O(w(bt), {
|
|
871
871
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
872
872
|
size: 14,
|
|
873
873
|
"stroke-width": 2
|
|
@@ -882,34 +882,34 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
882
882
|
autocapitalize: "off",
|
|
883
883
|
autocomplete: "off",
|
|
884
884
|
onInput: r[3] ||= (e) => i("update", { locale: e.target.value.trim() || void 0 })
|
|
885
|
-
}, null, 42,
|
|
886
|
-
g("p",
|
|
885
|
+
}, null, 42, An),
|
|
886
|
+
g("p", jn, E(w(a).templateSettings.contentLocaleHint), 1)
|
|
887
887
|
])], 2),
|
|
888
|
-
g("div", { class: f(w(
|
|
888
|
+
g("div", { class: f(w(ht)) }, [g("div", Mn, [O(w(Je), {
|
|
889
889
|
class: "tpl:text-[var(--tpl-text-muted)]",
|
|
890
890
|
size: 14,
|
|
891
891
|
"stroke-width": 2
|
|
892
|
-
}), g("span", null, E(w(a).templateSettings.preheaderText), 1)]), g("div", null, [O(
|
|
892
|
+
}), g("span", null, E(w(a).templateSettings.preheaderText), 1)]), g("div", null, [O(gn, {
|
|
893
893
|
"model-value": t.settings.preheaderText ?? "",
|
|
894
894
|
placeholder: w(a).templateSettings.preheaderTextPlaceholder,
|
|
895
895
|
rows: 2,
|
|
896
896
|
"onUpdate:modelValue": r[4] ||= (e) => i("update", { preheaderText: e.replace(/[\r\n]/g, " ") || void 0 })
|
|
897
|
-
}, null, 8, ["model-value", "placeholder"]), g("div",
|
|
898
|
-
g("div",
|
|
897
|
+
}, null, 8, ["model-value", "placeholder"]), g("div", Nn, [g("span", Pn, E(w(a).templateSettings.preheaderTextHint), 1), g("span", Fn, E((t.settings.preheaderText ?? "").length) + "/" + E(Hn), 1)])])], 2),
|
|
898
|
+
g("div", In, [g("div", Ln, [O(w(Ze), {
|
|
899
899
|
size: 14,
|
|
900
900
|
"stroke-width": 2
|
|
901
|
-
}), g("span", null, E(w(a).templateSettings.tips), 1)]), g("ul",
|
|
902
|
-
g("li",
|
|
903
|
-
g("li",
|
|
904
|
-
g("li",
|
|
901
|
+
}), g("span", null, E(w(a).templateSettings.tips), 1)]), g("ul", Rn, [
|
|
902
|
+
g("li", zn, E(w(a).templateSettings.tip1), 1),
|
|
903
|
+
g("li", Bn, E(w(a).templateSettings.tip2), 1),
|
|
904
|
+
g("li", Vn, E(w(a).templateSettings.tip3), 1)
|
|
905
905
|
])])
|
|
906
906
|
])]));
|
|
907
907
|
}
|
|
908
|
-
}),
|
|
908
|
+
}), Wn = { key: 0 }, Gn = { key: 1 }, Kn = [
|
|
909
909
|
"type",
|
|
910
910
|
"value",
|
|
911
911
|
"placeholder"
|
|
912
|
-
],
|
|
912
|
+
], qn = "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__ */ ot(/* @__PURE__ */ p({
|
|
913
913
|
__name: "MergeTagInput",
|
|
914
914
|
props: {
|
|
915
915
|
modelValue: {},
|
|
@@ -922,14 +922,14 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
922
922
|
},
|
|
923
923
|
emits: ["update:modelValue"],
|
|
924
924
|
setup(t, { emit: n }) {
|
|
925
|
-
let r = t, i = n, a = l(null), { segments: o, hasMergeTags: s, canRequestMergeTag: c, isRequestingMergeTag: u, isEditing: d, startEditing: p, stopEditing: m, handleInput: h, clearValue: v, insertMergeTag: b } =
|
|
925
|
+
let r = t, i = n, a = l(null), { segments: o, hasMergeTags: s, canRequestMergeTag: c, isRequestingMergeTag: u, isEditing: d, startEditing: p, stopEditing: m, handleInput: h, clearValue: v, insertMergeTag: b } = en({
|
|
926
926
|
modelValue: () => r.modelValue,
|
|
927
927
|
emit: (e) => i("update:modelValue", e),
|
|
928
928
|
elementRef: a
|
|
929
929
|
});
|
|
930
|
-
return (n, r) => w(s) && !w(d) ? (e(), _("div",
|
|
930
|
+
return (n, r) => w(s) && !w(d) ? (e(), _("div", Wn, [O(sn, {
|
|
931
931
|
segments: w(o),
|
|
932
|
-
"display-class":
|
|
932
|
+
"display-class": qn,
|
|
933
933
|
pulse: t.pulse,
|
|
934
934
|
onEdit: w(p),
|
|
935
935
|
onClear: w(v)
|
|
@@ -938,11 +938,11 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
938
938
|
"pulse",
|
|
939
939
|
"onEdit",
|
|
940
940
|
"onClear"
|
|
941
|
-
]), w(c) ? (e(), S(
|
|
941
|
+
]), w(c) ? (e(), S(un, {
|
|
942
942
|
key: 0,
|
|
943
943
|
disabled: w(u),
|
|
944
944
|
onInsert: w(b)
|
|
945
|
-
}, null, 8, ["disabled", "onInsert"])) : y("", !0)])) : (e(), _("div",
|
|
945
|
+
}, null, 8, ["disabled", "onInsert"])) : y("", !0)])) : (e(), _("div", Gn, [g("input", {
|
|
946
946
|
ref_key: "inputRef",
|
|
947
947
|
ref: a,
|
|
948
948
|
type: t.type,
|
|
@@ -952,16 +952,16 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
952
952
|
onInput: r[0] ||= (...e) => w(h) && w(h)(...e),
|
|
953
953
|
onBlur: r[1] ||= (...e) => w(m) && w(m)(...e),
|
|
954
954
|
onKeydown: r[2] ||= T((...e) => w(m) && w(m)(...e), ["escape"])
|
|
955
|
-
}, null, 42,
|
|
955
|
+
}, null, 42, Kn), w(c) ? (e(), S(un, {
|
|
956
956
|
key: 0,
|
|
957
957
|
disabled: w(u),
|
|
958
958
|
onInsert: w(b)
|
|
959
959
|
}, null, 8, ["disabled", "onInsert"])) : y("", !0)]));
|
|
960
960
|
}
|
|
961
|
-
}), [["__scopeId", "data-v-358207dd"]]),
|
|
961
|
+
}), [["__scopeId", "data-v-358207dd"]]), Jn = { class: "tpl:mb-3.5" }, Yn = ["value"], Xn = { value: "" }, Zn = ["value"], Qn = { class: "tpl:mb-3.5" }, $n = { class: "tpl:mb-3.5" }, er = {
|
|
962
962
|
key: 0,
|
|
963
963
|
class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]"
|
|
964
|
-
},
|
|
964
|
+
}, tr = ["checked"], nr = { class: "tpl:grid tpl:grid-cols-2 tpl:gap-3" }, rr = { class: "tpl:mb-3.5" }, ir = { class: "tpl:mb-3.5" }, ar = { class: "tpl:grid tpl:grid-cols-2 tpl:gap-3" }, or = { class: "tpl:mb-3.5" }, sr = { class: "tpl:flex tpl:items-stretch" }, cr = ["value"], lr = { class: "tpl:mb-3.5" }, ur = { class: "tpl:flex tpl:items-stretch" }, dr = ["value"], fr = /* @__PURE__ */ p({
|
|
965
965
|
__name: "ButtonToolbar",
|
|
966
966
|
props: {
|
|
967
967
|
block: {},
|
|
@@ -974,20 +974,20 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
974
974
|
r("update", { [e]: t });
|
|
975
975
|
}
|
|
976
976
|
return (n, r) => (e(), _(v, null, [
|
|
977
|
-
g("div",
|
|
977
|
+
g("div", Jn, [g("label", { class: f(w(W)) }, E(w(i).button.fontFamily), 3), g("select", {
|
|
978
978
|
class: f(w(U)),
|
|
979
979
|
value: t.block.fontFamily || "",
|
|
980
980
|
onChange: r[0] ||= (e) => a("fontFamily", e.target.value || void 0)
|
|
981
|
-
}, [g("option",
|
|
981
|
+
}, [g("option", Xn, E(w(i).button.inheritFont), 1), (e(!0), _(v, null, o(t.fontFamilies, (t) => (e(), _("option", {
|
|
982
982
|
key: t.value,
|
|
983
983
|
value: t.value
|
|
984
|
-
}, E(t.label), 9,
|
|
985
|
-
g("div",
|
|
984
|
+
}, E(t.label), 9, Zn))), 128))], 42, Yn)]),
|
|
985
|
+
g("div", Qn, [g("label", { class: f(w(W)) }, E(w(i).button.text), 3), O(Z, {
|
|
986
986
|
"model-value": t.block.text,
|
|
987
987
|
type: "text",
|
|
988
988
|
"onUpdate:modelValue": r[1] ||= (e) => a("text", e)
|
|
989
989
|
}, null, 8, ["model-value"])]),
|
|
990
|
-
g("div",
|
|
990
|
+
g("div", $n, [
|
|
991
991
|
g("label", { class: f(w(W)) }, E(w(i).button.url), 3),
|
|
992
992
|
O(Z, {
|
|
993
993
|
"model-value": t.block.url,
|
|
@@ -995,38 +995,38 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
995
995
|
placeholder: w(i).button.urlPlaceholder,
|
|
996
996
|
"onUpdate:modelValue": r[2] ||= (e) => a("url", e)
|
|
997
997
|
}, null, 8, ["model-value", "placeholder"]),
|
|
998
|
-
t.block.url ? (e(), _("label",
|
|
998
|
+
t.block.url ? (e(), _("label", er, [g("input", {
|
|
999
999
|
type: "checkbox",
|
|
1000
1000
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
1001
1001
|
checked: t.block.openInNewTab ?? !1,
|
|
1002
1002
|
onChange: r[3] ||= (e) => a("openInNewTab", e.target.checked)
|
|
1003
|
-
}, null, 40,
|
|
1003
|
+
}, null, 40, tr), u(" " + E(w(i).button.openInNewTab), 1)])) : y("", !0)
|
|
1004
1004
|
]),
|
|
1005
|
-
g("div",
|
|
1005
|
+
g("div", nr, [g("div", rr, [g("label", { class: f(w(W)) }, E(w(i).button.background), 3), O(q, {
|
|
1006
1006
|
"model-value": t.block.backgroundColor,
|
|
1007
1007
|
"onUpdate:modelValue": r[4] ||= (e) => a("backgroundColor", e)
|
|
1008
|
-
}, null, 8, ["model-value"])]), g("div",
|
|
1008
|
+
}, null, 8, ["model-value"])]), g("div", ir, [g("label", { class: f(w(W)) }, E(w(i).button.textColor), 3), O(q, {
|
|
1009
1009
|
"model-value": t.block.textColor,
|
|
1010
1010
|
"onUpdate:modelValue": r[5] ||= (e) => a("textColor", e)
|
|
1011
1011
|
}, null, 8, ["model-value"])])]),
|
|
1012
|
-
g("div",
|
|
1012
|
+
g("div", ar, [g("div", or, [g("label", { class: f(w(W)) }, E(w(i).button.borderRadius), 3), g("div", sr, [g("input", {
|
|
1013
1013
|
type: "number",
|
|
1014
1014
|
class: f(w(K)),
|
|
1015
1015
|
value: t.block.borderRadius,
|
|
1016
1016
|
min: "0",
|
|
1017
1017
|
max: "50",
|
|
1018
1018
|
onInput: r[6] ||= (e) => a("borderRadius", Number(e.target.value))
|
|
1019
|
-
}, null, 42,
|
|
1019
|
+
}, null, 42, cr), g("span", { class: f(w(G)) }, "px", 2)])]), g("div", lr, [g("label", { class: f(w(W)) }, E(w(i).button.fontSize), 3), g("div", ur, [g("input", {
|
|
1020
1020
|
type: "number",
|
|
1021
1021
|
class: f(w(K)),
|
|
1022
1022
|
value: t.block.fontSize,
|
|
1023
1023
|
min: "10",
|
|
1024
1024
|
max: "36",
|
|
1025
1025
|
onInput: r[7] ||= (e) => a("fontSize", Number(e.target.value))
|
|
1026
|
-
}, null, 42,
|
|
1026
|
+
}, null, 42, dr), g("span", { class: f(w(G)) }, "px", 2)])])])
|
|
1027
1027
|
], 64));
|
|
1028
1028
|
}
|
|
1029
|
-
}),
|
|
1029
|
+
}), pr = { class: "spacing-control" }, mr = { class: "tpl:mb-2 tpl:block tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, hr = { class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-1.5" }, gr = { class: "tpl:flex tpl:items-center" }, _r = ["aria-label"], vr = ["value", "aria-label"], yr = ["aria-label"], br = { class: "tpl:flex tpl:items-center tpl:gap-2" }, xr = { class: "tpl:flex tpl:items-center" }, Sr = ["aria-label"], Cr = ["value", "aria-label"], wr = ["aria-label"], Tr = ["aria-label", "title"], Er = { class: "tpl:flex tpl:items-center" }, Dr = ["aria-label"], Or = ["value", "aria-label"], kr = ["aria-label"], Ar = { class: "tpl:flex tpl:items-center" }, jr = ["aria-label"], Mr = ["value", "aria-label"], Nr = ["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)]", Pr = "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)]", Fr = /* @__PURE__ */ ot(/* @__PURE__ */ p({
|
|
1030
1030
|
__name: "SpacingControl",
|
|
1031
1031
|
props: {
|
|
1032
1032
|
modelValue: {},
|
|
@@ -1073,24 +1073,24 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1073
1073
|
});
|
|
1074
1074
|
}
|
|
1075
1075
|
}
|
|
1076
|
-
return (n, r) => (e(), _("div",
|
|
1077
|
-
g("div",
|
|
1076
|
+
return (n, r) => (e(), _("div", pr, [g("label", mr, E(t.label), 1), g("div", hr, [
|
|
1077
|
+
g("div", gr, [
|
|
1078
1078
|
g("button", {
|
|
1079
1079
|
"aria-label": w(o).spacingControl.decreaseTop,
|
|
1080
1080
|
class: f([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1081
1081
|
onClick: r[0] ||= (e) => u("top", -1)
|
|
1082
|
-
}, [O(w(
|
|
1082
|
+
}, [O(w(We), {
|
|
1083
1083
|
size: 12,
|
|
1084
1084
|
"stroke-width": 2
|
|
1085
|
-
})], 10,
|
|
1085
|
+
})], 10, _r),
|
|
1086
1086
|
g("input", {
|
|
1087
1087
|
type: "number",
|
|
1088
|
-
class: f(
|
|
1088
|
+
class: f(Pr),
|
|
1089
1089
|
value: t.modelValue.top,
|
|
1090
1090
|
"aria-label": w(o).spacingControl.top,
|
|
1091
1091
|
min: "0",
|
|
1092
1092
|
onInput: r[1] ||= (e) => d("top", Number(e.target.value))
|
|
1093
|
-
}, null, 40,
|
|
1093
|
+
}, null, 40, vr),
|
|
1094
1094
|
g("button", {
|
|
1095
1095
|
"aria-label": w(o).spacingControl.increaseTop,
|
|
1096
1096
|
class: f([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
@@ -1098,26 +1098,26 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1098
1098
|
}, [O(w(X), {
|
|
1099
1099
|
size: 12,
|
|
1100
1100
|
"stroke-width": 2
|
|
1101
|
-
})], 10,
|
|
1101
|
+
})], 10, yr)
|
|
1102
1102
|
]),
|
|
1103
|
-
g("div",
|
|
1104
|
-
g("div",
|
|
1103
|
+
g("div", br, [
|
|
1104
|
+
g("div", xr, [
|
|
1105
1105
|
g("button", {
|
|
1106
1106
|
"aria-label": w(o).spacingControl.decreaseLeft,
|
|
1107
1107
|
class: f([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1108
1108
|
onClick: r[3] ||= (e) => u("left", -1)
|
|
1109
|
-
}, [O(w(
|
|
1109
|
+
}, [O(w(We), {
|
|
1110
1110
|
size: 12,
|
|
1111
1111
|
"stroke-width": 2
|
|
1112
|
-
})], 10,
|
|
1112
|
+
})], 10, Sr),
|
|
1113
1113
|
g("input", {
|
|
1114
1114
|
type: "number",
|
|
1115
|
-
class: f(
|
|
1115
|
+
class: f(Pr),
|
|
1116
1116
|
value: t.modelValue.left,
|
|
1117
1117
|
"aria-label": w(o).spacingControl.left,
|
|
1118
1118
|
min: "0",
|
|
1119
1119
|
onInput: r[4] ||= (e) => d("left", Number(e.target.value))
|
|
1120
|
-
}, null, 40,
|
|
1120
|
+
}, null, 40, Cr),
|
|
1121
1121
|
g("button", {
|
|
1122
1122
|
"aria-label": w(o).spacingControl.increaseLeft,
|
|
1123
1123
|
class: f([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
@@ -1125,39 +1125,39 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1125
1125
|
}, [O(w(X), {
|
|
1126
1126
|
size: 12,
|
|
1127
1127
|
"stroke-width": 2
|
|
1128
|
-
})], 10,
|
|
1128
|
+
})], 10, wr)
|
|
1129
1129
|
]),
|
|
1130
1130
|
g("button", {
|
|
1131
1131
|
class: f(["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)]", c.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)]"]),
|
|
1132
1132
|
"aria-label": c.value ? w(o).spacingControl.unlock : w(o).spacingControl.lockAll,
|
|
1133
1133
|
title: c.value ? w(o).spacingControl.unlock : w(o).spacingControl.lockAll,
|
|
1134
1134
|
onClick: p
|
|
1135
|
-
}, [c.value ? (e(), S(w(
|
|
1135
|
+
}, [c.value ? (e(), S(w(Ct), {
|
|
1136
1136
|
key: 0,
|
|
1137
1137
|
size: 14,
|
|
1138
1138
|
"stroke-width": 2
|
|
1139
|
-
})) : (e(), S(w(
|
|
1139
|
+
})) : (e(), S(w(St), {
|
|
1140
1140
|
key: 1,
|
|
1141
1141
|
size: 14,
|
|
1142
1142
|
"stroke-width": 2
|
|
1143
|
-
}))], 10,
|
|
1144
|
-
g("div",
|
|
1143
|
+
}))], 10, Tr),
|
|
1144
|
+
g("div", Er, [
|
|
1145
1145
|
g("button", {
|
|
1146
1146
|
"aria-label": w(o).spacingControl.decreaseRight,
|
|
1147
1147
|
class: f([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1148
1148
|
onClick: r[6] ||= (e) => u("right", -1)
|
|
1149
|
-
}, [O(w(
|
|
1149
|
+
}, [O(w(We), {
|
|
1150
1150
|
size: 12,
|
|
1151
1151
|
"stroke-width": 2
|
|
1152
|
-
})], 10,
|
|
1152
|
+
})], 10, Dr),
|
|
1153
1153
|
g("input", {
|
|
1154
1154
|
type: "number",
|
|
1155
|
-
class: f(
|
|
1155
|
+
class: f(Pr),
|
|
1156
1156
|
value: t.modelValue.right,
|
|
1157
1157
|
"aria-label": w(o).spacingControl.right,
|
|
1158
1158
|
min: "0",
|
|
1159
1159
|
onInput: r[7] ||= (e) => d("right", Number(e.target.value))
|
|
1160
|
-
}, null, 40,
|
|
1160
|
+
}, null, 40, Or),
|
|
1161
1161
|
g("button", {
|
|
1162
1162
|
"aria-label": w(o).spacingControl.increaseRight,
|
|
1163
1163
|
class: f([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
@@ -1165,26 +1165,26 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1165
1165
|
}, [O(w(X), {
|
|
1166
1166
|
size: 12,
|
|
1167
1167
|
"stroke-width": 2
|
|
1168
|
-
})], 10,
|
|
1168
|
+
})], 10, kr)
|
|
1169
1169
|
])
|
|
1170
1170
|
]),
|
|
1171
|
-
g("div",
|
|
1171
|
+
g("div", Ar, [
|
|
1172
1172
|
g("button", {
|
|
1173
1173
|
"aria-label": w(o).spacingControl.decreaseBottom,
|
|
1174
1174
|
class: f([Q, "tpl:rounded-l-[var(--tpl-radius-sm)]"]),
|
|
1175
1175
|
onClick: r[9] ||= (e) => u("bottom", -1)
|
|
1176
|
-
}, [O(w(
|
|
1176
|
+
}, [O(w(We), {
|
|
1177
1177
|
size: 12,
|
|
1178
1178
|
"stroke-width": 2
|
|
1179
|
-
})], 10,
|
|
1179
|
+
})], 10, jr),
|
|
1180
1180
|
g("input", {
|
|
1181
1181
|
type: "number",
|
|
1182
|
-
class: f(
|
|
1182
|
+
class: f(Pr),
|
|
1183
1183
|
value: t.modelValue.bottom,
|
|
1184
1184
|
"aria-label": w(o).spacingControl.bottom,
|
|
1185
1185
|
min: "0",
|
|
1186
1186
|
onInput: r[10] ||= (e) => d("bottom", Number(e.target.value))
|
|
1187
|
-
}, null, 40,
|
|
1187
|
+
}, null, 40, Mr),
|
|
1188
1188
|
g("button", {
|
|
1189
1189
|
"aria-label": w(o).spacingControl.increaseBottom,
|
|
1190
1190
|
class: f([Q, "tpl:rounded-r-[var(--tpl-radius-sm)]"]),
|
|
@@ -1192,11 +1192,11 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1192
1192
|
}, [O(w(X), {
|
|
1193
1193
|
size: 12,
|
|
1194
1194
|
"stroke-width": 2
|
|
1195
|
-
})], 10,
|
|
1195
|
+
})], 10, Nr)
|
|
1196
1196
|
])
|
|
1197
1197
|
])]));
|
|
1198
1198
|
}
|
|
1199
|
-
}), [["__scopeId", "data-v-9a9c8a07"]]),
|
|
1199
|
+
}), [["__scopeId", "data-v-9a9c8a07"]]), Ir = { class: "tpl:mt-3" }, Lr = /* @__PURE__ */ p({
|
|
1200
1200
|
__name: "CollapsibleSection",
|
|
1201
1201
|
props: {
|
|
1202
1202
|
title: {},
|
|
@@ -1209,25 +1209,25 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1209
1209
|
type: "button",
|
|
1210
1210
|
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)]",
|
|
1211
1211
|
onClick: i[0] ||= (e) => r.$emit("toggle")
|
|
1212
|
-
}, [O(w(
|
|
1212
|
+
}, [O(w(He), {
|
|
1213
1213
|
class: f(["tpl:transition-transform tpl:duration-200", n.open ? "tpl:rotate-0" : "tpl:-rotate-90"]),
|
|
1214
1214
|
size: 12,
|
|
1215
1215
|
"stroke-width": 2
|
|
1216
|
-
}, null, 8, ["class"]), g("span", null, E(n.title), 1)]), t(g("div",
|
|
1216
|
+
}, null, 8, ["class"]), g("span", null, E(n.title), 1)]), t(g("div", Ir, [s(r.$slots, "default")], 512), [[b, n.open]])], 2));
|
|
1217
1217
|
}
|
|
1218
|
-
}),
|
|
1218
|
+
}), Rr = { class: "tpl:mt-4" }, zr = { class: "tpl:space-y-2" }, Br = ["checked", "onChange"], Vr = ["value", "placeholder"], Hr = { class: "tpl:space-y-2" }, Ur = ["value"], Wr = { value: "" }, Gr = ["label"], Kr = ["value"], qr = ["value"], Jr = {
|
|
1219
1219
|
key: 0,
|
|
1220
1220
|
value: "__custom__"
|
|
1221
|
-
},
|
|
1221
|
+
}, Yr = {
|
|
1222
1222
|
key: 0,
|
|
1223
1223
|
class: "tpl:space-y-2"
|
|
1224
|
-
},
|
|
1224
|
+
}, Xr = { class: "tpl:mb-1 tpl:block tpl:text-[11px] tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, Zr = { class: "tpl:mb-1 tpl:block tpl:text-[11px] tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, Qr = { class: "tpl:flex tpl:justify-end" }, $r = ["disabled"], ei = {
|
|
1225
1225
|
key: 0,
|
|
1226
1226
|
class: "tpl:text-[11px] tpl:text-[var(--tpl-text-muted)]"
|
|
1227
|
-
},
|
|
1227
|
+
}, ti = { class: "tpl:space-y-1" }, ni = { class: "tpl:m-0 tpl:overflow-x-auto tpl:rounded tpl:bg-[var(--tpl-bg)] tpl:p-2 tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-muted)]" }, ri = {
|
|
1228
1228
|
key: 0,
|
|
1229
1229
|
class: "tpl:m-0 tpl:overflow-x-auto tpl:rounded tpl:bg-[var(--tpl-bg)] tpl:p-2 tpl:font-mono tpl:text-[10px] tpl:text-[var(--tpl-text-muted)]"
|
|
1230
|
-
},
|
|
1230
|
+
}, ii = /* @__PURE__ */ p({
|
|
1231
1231
|
__name: "CommonBlockSettings",
|
|
1232
1232
|
props: {
|
|
1233
1233
|
block: {},
|
|
@@ -1235,31 +1235,31 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1235
1235
|
},
|
|
1236
1236
|
emits: ["update"],
|
|
1237
1237
|
setup(n, { emit: s }) {
|
|
1238
|
-
let c = n, p = s, { t: m } = V(), b = k(
|
|
1238
|
+
let c = n, p = s, { t: m } = V(), b = k(Ne, []), x = k(Ie, !1), C = i(/* @__PURE__ */ new Set()), T = l(!1), D = l(""), A = l(""), M = [
|
|
1239
1239
|
{
|
|
1240
1240
|
key: "desktop",
|
|
1241
|
-
icon:
|
|
1241
|
+
icon: wt,
|
|
1242
1242
|
labelKey: "showOnDesktop"
|
|
1243
1243
|
},
|
|
1244
1244
|
{
|
|
1245
1245
|
key: "tablet",
|
|
1246
|
-
icon:
|
|
1246
|
+
icon: Nt,
|
|
1247
1247
|
labelKey: "showOnTablet"
|
|
1248
1248
|
},
|
|
1249
1249
|
{
|
|
1250
1250
|
key: "mobile",
|
|
1251
|
-
icon:
|
|
1251
|
+
icon: kt,
|
|
1252
1252
|
labelKey: "showOnMobile"
|
|
1253
1253
|
}
|
|
1254
1254
|
];
|
|
1255
|
-
function
|
|
1255
|
+
function N(e) {
|
|
1256
1256
|
C.has(e) ? C.delete(e) : C.add(e);
|
|
1257
1257
|
}
|
|
1258
|
-
let
|
|
1259
|
-
function F() {
|
|
1260
|
-
T.value = !0, P.value && c.block.displayCondition ? (D.value = c.block.displayCondition.before, A.value = c.block.displayCondition.after ?? "") : (D.value = "", A.value = "");
|
|
1261
|
-
}
|
|
1258
|
+
let P = h(() => b.length > 0 || x), F = h(() => c.block.displayCondition ? !b.some((e) => e.label === c.block.displayCondition?.label) : !1);
|
|
1262
1259
|
function I() {
|
|
1260
|
+
T.value = !0, F.value && c.block.displayCondition ? (D.value = c.block.displayCondition.before, A.value = c.block.displayCondition.after ?? "") : (D.value = "", A.value = "");
|
|
1261
|
+
}
|
|
1262
|
+
function L() {
|
|
1263
1263
|
D.value.trim() && (p("update", { displayCondition: {
|
|
1264
1264
|
label: m.blockSettings.customCondition,
|
|
1265
1265
|
before: D.value.trim(),
|
|
@@ -1271,9 +1271,9 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1271
1271
|
T.value = !1, D.value = "", A.value = "";
|
|
1272
1272
|
return;
|
|
1273
1273
|
}
|
|
1274
|
-
|
|
1274
|
+
F.value && (D.value = e.before, A.value = e.after ?? "");
|
|
1275
1275
|
}, { immediate: !0 });
|
|
1276
|
-
let
|
|
1276
|
+
let ee = h(() => {
|
|
1277
1277
|
let e = {};
|
|
1278
1278
|
for (let t of b) {
|
|
1279
1279
|
let n = t.group ?? "";
|
|
@@ -1281,38 +1281,38 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1281
1281
|
}
|
|
1282
1282
|
return e;
|
|
1283
1283
|
});
|
|
1284
|
-
function
|
|
1284
|
+
function te(e, t) {
|
|
1285
1285
|
p("update", { styles: {
|
|
1286
1286
|
...c.block.styles,
|
|
1287
1287
|
[e]: t
|
|
1288
1288
|
} });
|
|
1289
1289
|
}
|
|
1290
|
-
function
|
|
1290
|
+
function R(e) {
|
|
1291
1291
|
return c.block.visibility?.[e] !== !1;
|
|
1292
1292
|
}
|
|
1293
|
-
function
|
|
1293
|
+
function z(e) {
|
|
1294
1294
|
let t = {
|
|
1295
|
-
desktop:
|
|
1296
|
-
tablet:
|
|
1297
|
-
mobile:
|
|
1295
|
+
desktop: R("desktop"),
|
|
1296
|
+
tablet: R("tablet"),
|
|
1297
|
+
mobile: R("mobile")
|
|
1298
1298
|
};
|
|
1299
1299
|
t[e] = !t[e], p("update", { visibility: t });
|
|
1300
1300
|
}
|
|
1301
1301
|
return (i, a) => (e(), _("div", { class: f(["tpl:flex tpl:flex-col", n.isFirstSection ? "" : "tpl:mt-4"]) }, [
|
|
1302
|
-
O(
|
|
1302
|
+
O(Lr, {
|
|
1303
1303
|
title: w(m).blockSettings.spacing,
|
|
1304
1304
|
open: C.has("spacing"),
|
|
1305
1305
|
"no-border": n.isFirstSection,
|
|
1306
|
-
onToggle: a[2] ||= (e) =>
|
|
1306
|
+
onToggle: a[2] ||= (e) => N("spacing")
|
|
1307
1307
|
}, {
|
|
1308
|
-
default: j(() => [O(
|
|
1308
|
+
default: j(() => [O(Fr, {
|
|
1309
1309
|
label: w(m).blockSettings.padding,
|
|
1310
1310
|
"model-value": n.block.styles.padding,
|
|
1311
|
-
"onUpdate:modelValue": a[0] ||= (e) =>
|
|
1312
|
-
}, null, 8, ["label", "model-value"]), g("div",
|
|
1311
|
+
"onUpdate:modelValue": a[0] ||= (e) => te("padding", e)
|
|
1312
|
+
}, null, 8, ["label", "model-value"]), g("div", Rr, [O(Fr, {
|
|
1313
1313
|
label: w(m).blockSettings.margin,
|
|
1314
1314
|
"model-value": n.block.styles.margin,
|
|
1315
|
-
"onUpdate:modelValue": a[1] ||= (e) =>
|
|
1315
|
+
"onUpdate:modelValue": a[1] ||= (e) => te("margin", e)
|
|
1316
1316
|
}, null, 8, ["label", "model-value"])])]),
|
|
1317
1317
|
_: 1
|
|
1318
1318
|
}, 8, [
|
|
@@ -1320,33 +1320,33 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1320
1320
|
"open",
|
|
1321
1321
|
"no-border"
|
|
1322
1322
|
]),
|
|
1323
|
-
O(
|
|
1323
|
+
O(Lr, {
|
|
1324
1324
|
title: w(m).blockSettings.background,
|
|
1325
1325
|
open: C.has("bg"),
|
|
1326
|
-
onToggle: a[4] ||= (e) =>
|
|
1326
|
+
onToggle: a[4] ||= (e) => N("bg")
|
|
1327
1327
|
}, {
|
|
1328
1328
|
default: j(() => [g("label", { class: f(w(W)) }, E(w(m).blockSettings.color), 3), O(q, {
|
|
1329
1329
|
size: "large",
|
|
1330
1330
|
"model-value": n.block.styles.backgroundColor || w("#ffffff"),
|
|
1331
|
-
"onUpdate:modelValue": a[3] ||= (e) =>
|
|
1331
|
+
"onUpdate:modelValue": a[3] ||= (e) => te("backgroundColor", e)
|
|
1332
1332
|
}, null, 8, ["model-value"])]),
|
|
1333
1333
|
_: 1
|
|
1334
1334
|
}, 8, ["title", "open"]),
|
|
1335
|
-
O(
|
|
1335
|
+
O(Lr, {
|
|
1336
1336
|
title: w(m).blockSettings.display,
|
|
1337
1337
|
open: C.has("display"),
|
|
1338
|
-
onToggle: a[5] ||= (e) =>
|
|
1338
|
+
onToggle: a[5] ||= (e) => N("display")
|
|
1339
1339
|
}, {
|
|
1340
|
-
default: j(() => [g("div",
|
|
1340
|
+
default: j(() => [g("div", zr, [(e(), _(v, null, o(M, (t) => g("label", {
|
|
1341
1341
|
key: t.key,
|
|
1342
1342
|
class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-xs tpl:text-[var(--tpl-text)]"
|
|
1343
1343
|
}, [
|
|
1344
1344
|
g("input", {
|
|
1345
1345
|
type: "checkbox",
|
|
1346
1346
|
class: "tpl:accent-[var(--tpl-primary)]",
|
|
1347
|
-
checked:
|
|
1348
|
-
onChange: (e) =>
|
|
1349
|
-
}, null, 40,
|
|
1347
|
+
checked: R(t.key),
|
|
1348
|
+
onChange: (e) => z(t.key)
|
|
1349
|
+
}, null, 40, Br),
|
|
1350
1350
|
(e(), S(r(t.icon), {
|
|
1351
1351
|
size: 14,
|
|
1352
1352
|
"stroke-width": 1.5
|
|
@@ -1355,33 +1355,33 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1355
1355
|
])), 64))])]),
|
|
1356
1356
|
_: 1
|
|
1357
1357
|
}, 8, ["title", "open"]),
|
|
1358
|
-
O(
|
|
1358
|
+
O(Lr, {
|
|
1359
1359
|
title: w(m).blockSettings.customCss,
|
|
1360
1360
|
open: C.has("css"),
|
|
1361
|
-
onToggle: a[7] ||= (e) =>
|
|
1361
|
+
onToggle: a[7] ||= (e) => N("css")
|
|
1362
1362
|
}, {
|
|
1363
1363
|
default: j(() => [g("label", { class: f(w(W)) }, E(w(m).blockSettings.css), 3), g("textarea", {
|
|
1364
1364
|
value: n.block.customCss || "",
|
|
1365
1365
|
placeholder: w(m).blockSettings.cssPlaceholder,
|
|
1366
1366
|
rows: "3",
|
|
1367
|
-
class: f(w(
|
|
1367
|
+
class: f(w(mt)),
|
|
1368
1368
|
onInput: a[6] ||= (e) => p("update", { customCss: e.target.value })
|
|
1369
|
-
}, null, 42,
|
|
1369
|
+
}, null, 42, Vr)]),
|
|
1370
1370
|
_: 1
|
|
1371
1371
|
}, 8, ["title", "open"]),
|
|
1372
|
-
|
|
1372
|
+
P.value ? (e(), S(Lr, {
|
|
1373
1373
|
key: 0,
|
|
1374
1374
|
title: w(m).blockSettings.displayCondition,
|
|
1375
1375
|
open: C.has("condition"),
|
|
1376
|
-
onToggle: a[11] ||= (e) =>
|
|
1376
|
+
onToggle: a[11] ||= (e) => N("condition")
|
|
1377
1377
|
}, {
|
|
1378
|
-
default: j(() => [g("div",
|
|
1378
|
+
default: j(() => [g("div", Hr, [g("select", {
|
|
1379
1379
|
class: f(["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)]"]),
|
|
1380
|
-
value: T.value ||
|
|
1380
|
+
value: T.value || F.value ? "__custom__" : n.block.displayCondition?.label ?? "",
|
|
1381
1381
|
onChange: a[8] ||= (e) => {
|
|
1382
1382
|
let t = e.target.value;
|
|
1383
1383
|
if (t === "__custom__") {
|
|
1384
|
-
|
|
1384
|
+
I();
|
|
1385
1385
|
return;
|
|
1386
1386
|
}
|
|
1387
1387
|
if (T.value = !1, !t) {
|
|
@@ -1392,48 +1392,48 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1392
1392
|
n && p("update", { displayCondition: n });
|
|
1393
1393
|
}
|
|
1394
1394
|
}, [
|
|
1395
|
-
g("option",
|
|
1396
|
-
(e(!0), _(v, null, o(
|
|
1395
|
+
g("option", Wr, E(w(m).blockSettings.noCondition), 1),
|
|
1396
|
+
(e(!0), _(v, null, o(ee.value, (t, n) => (e(), _(v, { key: n }, [n ? (e(), _("optgroup", {
|
|
1397
1397
|
key: 0,
|
|
1398
1398
|
label: String(n)
|
|
1399
1399
|
}, [(e(!0), _(v, null, o(t, (t) => (e(), _("option", {
|
|
1400
1400
|
key: t.label,
|
|
1401
1401
|
value: t.label
|
|
1402
|
-
}, E(t.label), 9,
|
|
1402
|
+
}, E(t.label), 9, Kr))), 128))], 8, Gr)) : (e(!0), _(v, { key: 1 }, o(t, (t) => (e(), _("option", {
|
|
1403
1403
|
key: t.label,
|
|
1404
1404
|
value: t.label
|
|
1405
|
-
}, E(t.label), 9,
|
|
1406
|
-
w(x) ? (e(), _("option",
|
|
1407
|
-
], 42,
|
|
1408
|
-
g("div", null, [g("label",
|
|
1405
|
+
}, E(t.label), 9, qr))), 128))], 64))), 128)),
|
|
1406
|
+
w(x) ? (e(), _("option", Jr, E(w(m).blockSettings.customCondition), 1)) : y("", !0)
|
|
1407
|
+
], 42, Ur), T.value || F.value ? (e(), _("div", Yr, [
|
|
1408
|
+
g("div", null, [g("label", Xr, E(w(m).blockSettings.customConditionBefore), 1), t(g("textarea", {
|
|
1409
1409
|
"onUpdate:modelValue": a[9] ||= (e) => D.value = e,
|
|
1410
1410
|
rows: "2",
|
|
1411
|
-
class: f(w(
|
|
1411
|
+
class: f(w(mt))
|
|
1412
1412
|
}, null, 2), [[d, D.value]])]),
|
|
1413
|
-
g("div", null, [g("label",
|
|
1413
|
+
g("div", null, [g("label", Zr, E(w(m).blockSettings.customConditionAfter), 1), t(g("textarea", {
|
|
1414
1414
|
"onUpdate:modelValue": a[10] ||= (e) => A.value = e,
|
|
1415
1415
|
rows: "2",
|
|
1416
|
-
class: f(w(
|
|
1416
|
+
class: f(w(mt))
|
|
1417
1417
|
}, null, 2), [[d, A.value]])]),
|
|
1418
|
-
g("div",
|
|
1418
|
+
g("div", Qr, [g("button", {
|
|
1419
1419
|
type: "button",
|
|
1420
1420
|
class: "tpl:cursor-pointer tpl:rounded-md tpl:border-none tpl:bg-[var(--tpl-primary)] tpl:px-3 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-bg)] tpl:transition-all tpl:duration-150 tpl:hover:opacity-90 tpl:disabled:opacity-50",
|
|
1421
1421
|
disabled: !D.value.trim(),
|
|
1422
|
-
onClick:
|
|
1423
|
-
}, E(w(m).blockSettings.applyCondition), 9,
|
|
1424
|
-
])) : n.block.displayCondition && !
|
|
1422
|
+
onClick: L
|
|
1423
|
+
}, E(w(m).blockSettings.applyCondition), 9, $r)])
|
|
1424
|
+
])) : n.block.displayCondition && !F.value ? (e(), _(v, { key: 1 }, [n.block.displayCondition.description ? (e(), _("p", ei, E(n.block.displayCondition.description), 1)) : y("", !0), g("div", ti, [g("pre", ni, E(n.block.displayCondition.before), 1), n.block.displayCondition.after ? (e(), _("pre", ri, E(n.block.displayCondition.after), 1)) : y("", !0)])], 64)) : y("", !0)])]),
|
|
1425
1425
|
_: 1
|
|
1426
1426
|
}, 8, ["title", "open"])) : y("", !0)
|
|
1427
1427
|
], 2));
|
|
1428
1428
|
}
|
|
1429
|
-
}),
|
|
1429
|
+
}), ai = ["title"], oi = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text-muted)]" }, si = {
|
|
1430
1430
|
key: 1,
|
|
1431
1431
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
1432
|
-
},
|
|
1432
|
+
}, ci = [
|
|
1433
1433
|
"aria-checked",
|
|
1434
1434
|
"aria-label",
|
|
1435
1435
|
"disabled"
|
|
1436
|
-
],
|
|
1436
|
+
], li = /* @__PURE__ */ p({
|
|
1437
1437
|
__name: "BooleanField",
|
|
1438
1438
|
props: {
|
|
1439
1439
|
field: {},
|
|
@@ -1446,14 +1446,14 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1446
1446
|
return (n, a) => (e(), _("div", {
|
|
1447
1447
|
class: "tpl:mb-3.5",
|
|
1448
1448
|
title: t.readOnly ? w(i).customBlocks.dataSource.readOnlyTooltip : void 0
|
|
1449
|
-
}, [g("label", { class: f(["tpl:flex tpl:items-center tpl:justify-between tpl:gap-2", t.readOnly ? "tpl:cursor-not-allowed" : "tpl:cursor-pointer"]) }, [g("span",
|
|
1449
|
+
}, [g("label", { class: f(["tpl:flex tpl:items-center tpl:justify-between tpl:gap-2", t.readOnly ? "tpl:cursor-not-allowed" : "tpl:cursor-pointer"]) }, [g("span", oi, [
|
|
1450
1450
|
u(E(t.field.label) + " ", 1),
|
|
1451
|
-
t.readOnly ? (e(), S(w(
|
|
1451
|
+
t.readOnly ? (e(), S(w(Ct), {
|
|
1452
1452
|
key: 0,
|
|
1453
1453
|
size: 12,
|
|
1454
1454
|
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]"
|
|
1455
1455
|
})) : y("", !0),
|
|
1456
|
-
t.field.required ? (e(), _("span",
|
|
1456
|
+
t.field.required ? (e(), _("span", si, " * ")) : y("", !0)
|
|
1457
1457
|
]), g("button", {
|
|
1458
1458
|
type: "button",
|
|
1459
1459
|
role: "switch",
|
|
@@ -1466,12 +1466,12 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1466
1466
|
]),
|
|
1467
1467
|
disabled: t.readOnly,
|
|
1468
1468
|
onClick: a[0] ||= (e) => !t.readOnly && r("update:modelValue", !t.modelValue)
|
|
1469
|
-
}, [g("span", { class: f(["tpl:pointer-events-none tpl:inline-block tpl:size-4 tpl:rounded-full tpl:bg-[var(--tpl-bg)] tpl:shadow tpl:transition-transform tpl:duration-200", t.modelValue ? "tpl:translate-x-4" : "tpl:translate-x-0"]) }, null, 2)], 10,
|
|
1469
|
+
}, [g("span", { class: f(["tpl:pointer-events-none tpl:inline-block tpl:size-4 tpl:rounded-full tpl:bg-[var(--tpl-bg)] tpl:shadow tpl:transition-transform tpl:duration-200", t.modelValue ? "tpl:translate-x-4" : "tpl:translate-x-0"]) }, null, 2)], 10, ci)], 2)], 8, ai));
|
|
1470
1470
|
}
|
|
1471
|
-
}),
|
|
1471
|
+
}), ui = { class: "tpl:mb-3.5" }, di = {
|
|
1472
1472
|
key: 1,
|
|
1473
1473
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
1474
|
-
},
|
|
1474
|
+
}, fi = /* @__PURE__ */ p({
|
|
1475
1475
|
__name: "FieldWrapper",
|
|
1476
1476
|
props: {
|
|
1477
1477
|
label: {},
|
|
@@ -1479,17 +1479,17 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1479
1479
|
readOnly: { type: Boolean }
|
|
1480
1480
|
},
|
|
1481
1481
|
setup(t) {
|
|
1482
|
-
return (n, r) => (e(), _("div",
|
|
1482
|
+
return (n, r) => (e(), _("div", ui, [g("label", { class: f(w(W)) }, [
|
|
1483
1483
|
u(E(t.label) + " ", 1),
|
|
1484
|
-
t.readOnly ? (e(), S(w(
|
|
1484
|
+
t.readOnly ? (e(), S(w(Ct), {
|
|
1485
1485
|
key: 0,
|
|
1486
1486
|
size: 12,
|
|
1487
1487
|
class: "tpl:inline tpl:text-[var(--tpl-text-dim)]"
|
|
1488
1488
|
})) : y("", !0),
|
|
1489
|
-
t.required ? (e(), _("span",
|
|
1489
|
+
t.required ? (e(), _("span", di, "*")) : y("", !0)
|
|
1490
1490
|
], 2), s(n.$slots, "default")]));
|
|
1491
1491
|
}
|
|
1492
|
-
}),
|
|
1492
|
+
}), pi = /* @__PURE__ */ p({
|
|
1493
1493
|
__name: "ColorField",
|
|
1494
1494
|
props: {
|
|
1495
1495
|
field: {},
|
|
@@ -1499,7 +1499,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1499
1499
|
emits: ["update:modelValue"],
|
|
1500
1500
|
setup(t, { emit: n }) {
|
|
1501
1501
|
let r = n, { t: i } = V();
|
|
1502
|
-
return (n, a) => (e(), S(
|
|
1502
|
+
return (n, a) => (e(), S(fi, {
|
|
1503
1503
|
label: t.field.label,
|
|
1504
1504
|
required: t.field.required,
|
|
1505
1505
|
"read-only": t.readOnly
|
|
@@ -1523,11 +1523,11 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1523
1523
|
"read-only"
|
|
1524
1524
|
]));
|
|
1525
1525
|
}
|
|
1526
|
-
}),
|
|
1526
|
+
}), mi = [
|
|
1527
1527
|
"value",
|
|
1528
1528
|
"placeholder",
|
|
1529
1529
|
"title"
|
|
1530
|
-
],
|
|
1530
|
+
], hi = ["value", "placeholder"], gi = /* @__PURE__ */ p({
|
|
1531
1531
|
__name: "ImageField",
|
|
1532
1532
|
props: {
|
|
1533
1533
|
field: {},
|
|
@@ -1536,12 +1536,12 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1536
1536
|
},
|
|
1537
1537
|
emits: ["update:modelValue"],
|
|
1538
1538
|
setup(t, { emit: n }) {
|
|
1539
|
-
let r = n, { t: i } = V(), a = k(
|
|
1539
|
+
let r = n, { t: i } = V(), a = k(ke, null), o = lt(), s = h(() => !!a);
|
|
1540
1540
|
async function c() {
|
|
1541
1541
|
let e = await a?.({ accept: ["images"] });
|
|
1542
1542
|
o.alive && e && r("update:modelValue", e.url);
|
|
1543
1543
|
}
|
|
1544
|
-
return (n, a) => (e(), S(
|
|
1544
|
+
return (n, a) => (e(), S(fi, {
|
|
1545
1545
|
label: t.field.label,
|
|
1546
1546
|
required: t.field.required,
|
|
1547
1547
|
"read-only": t.readOnly
|
|
@@ -1554,14 +1554,14 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1554
1554
|
placeholder: t.field.placeholder || "https://...",
|
|
1555
1555
|
disabled: "",
|
|
1556
1556
|
title: w(i).customBlocks.dataSource.readOnlyTooltip
|
|
1557
|
-
}, null, 10,
|
|
1557
|
+
}, null, 10, mi)) : (e(), _("input", {
|
|
1558
1558
|
key: 1,
|
|
1559
1559
|
type: "url",
|
|
1560
1560
|
class: f(w(U)),
|
|
1561
1561
|
value: t.modelValue,
|
|
1562
1562
|
placeholder: t.field.placeholder || "https://...",
|
|
1563
1563
|
onInput: a[0] ||= (e) => r("update:modelValue", e.target.value)
|
|
1564
|
-
}, null, 42,
|
|
1564
|
+
}, null, 42, hi)), s.value && !t.readOnly ? (e(), _("button", {
|
|
1565
1565
|
key: 2,
|
|
1566
1566
|
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)]",
|
|
1567
1567
|
onClick: a[1] ||= (e) => c()
|
|
@@ -1576,7 +1576,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1576
1576
|
"read-only"
|
|
1577
1577
|
]));
|
|
1578
1578
|
}
|
|
1579
|
-
}),
|
|
1579
|
+
}), _i = [
|
|
1580
1580
|
"value",
|
|
1581
1581
|
"placeholder",
|
|
1582
1582
|
"min",
|
|
@@ -1584,7 +1584,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1584
1584
|
"step",
|
|
1585
1585
|
"disabled",
|
|
1586
1586
|
"title"
|
|
1587
|
-
],
|
|
1587
|
+
], vi = /* @__PURE__ */ p({
|
|
1588
1588
|
__name: "NumberField",
|
|
1589
1589
|
props: {
|
|
1590
1590
|
field: {},
|
|
@@ -1594,7 +1594,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1594
1594
|
emits: ["update:modelValue"],
|
|
1595
1595
|
setup(t, { emit: n }) {
|
|
1596
1596
|
let r = n, { t: i } = V();
|
|
1597
|
-
return (n, a) => (e(), S(
|
|
1597
|
+
return (n, a) => (e(), S(fi, {
|
|
1598
1598
|
label: t.field.label,
|
|
1599
1599
|
required: t.field.required,
|
|
1600
1600
|
"read-only": t.readOnly
|
|
@@ -1610,7 +1610,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1610
1610
|
disabled: t.readOnly,
|
|
1611
1611
|
title: t.readOnly ? w(i).customBlocks.dataSource.readOnlyTooltip : void 0,
|
|
1612
1612
|
onInput: a[0] ||= (e) => !t.readOnly && r("update:modelValue", Number(e.target.value))
|
|
1613
|
-
}, null, 42,
|
|
1613
|
+
}, null, 42, _i)]),
|
|
1614
1614
|
_: 1
|
|
1615
1615
|
}, 8, [
|
|
1616
1616
|
"label",
|
|
@@ -1618,10 +1618,10 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1618
1618
|
"read-only"
|
|
1619
1619
|
]));
|
|
1620
1620
|
}
|
|
1621
|
-
}),
|
|
1621
|
+
}), yi = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, bi = { class: "tpl:mb-2 tpl:flex tpl:items-center tpl:justify-between" }, xi = { class: "tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-dim)]" }, Si = ["title", "onClick"], Ci = {
|
|
1622
1622
|
key: 1,
|
|
1623
1623
|
class: "tpl:m-0 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
1624
|
-
},
|
|
1624
|
+
}, wi = /* @__PURE__ */ p({
|
|
1625
1625
|
__name: "RepeatableField",
|
|
1626
1626
|
props: {
|
|
1627
1627
|
field: {},
|
|
@@ -1648,25 +1648,25 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1648
1648
|
[t]: n
|
|
1649
1649
|
} : r));
|
|
1650
1650
|
}
|
|
1651
|
-
return (n, i) => (e(), S(
|
|
1651
|
+
return (n, i) => (e(), S(fi, {
|
|
1652
1652
|
label: t.field.label,
|
|
1653
1653
|
required: t.field.required,
|
|
1654
1654
|
"read-only": t.readOnly
|
|
1655
1655
|
}, {
|
|
1656
|
-
default: j(() => [g("div",
|
|
1656
|
+
default: j(() => [g("div", yi, [
|
|
1657
1657
|
(e(!0), _(v, null, o(c.value, (n, i) => (e(), _("div", {
|
|
1658
1658
|
key: `${t.field.key}-${i}`,
|
|
1659
1659
|
class: "tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-hover)] tpl:p-3"
|
|
1660
|
-
}, [g("div",
|
|
1660
|
+
}, [g("div", bi, [g("span", xi, " #" + E(i + 1), 1), d.value && !t.readOnly ? (e(), _("button", {
|
|
1661
1661
|
key: 0,
|
|
1662
1662
|
type: "button",
|
|
1663
1663
|
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)]",
|
|
1664
1664
|
title: w(s).customBlocks.fields.removeItem,
|
|
1665
1665
|
onClick: (e) => m(i)
|
|
1666
|
-
}, [O(w(
|
|
1666
|
+
}, [O(w(it), {
|
|
1667
1667
|
size: 12,
|
|
1668
1668
|
"stroke-width": 2
|
|
1669
|
-
})], 8,
|
|
1669
|
+
})], 8, Si)) : y("", !0)]), (e(!0), _(v, null, o(t.field.fields, (a) => (e(), S(r(w(Ni)(a.type)), {
|
|
1670
1670
|
key: a.key,
|
|
1671
1671
|
field: a,
|
|
1672
1672
|
"model-value": n[a.key],
|
|
@@ -1681,13 +1681,13 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1681
1681
|
l.value && !t.readOnly ? (e(), _("button", {
|
|
1682
1682
|
key: 0,
|
|
1683
1683
|
type: "button",
|
|
1684
|
-
class: f(w(
|
|
1684
|
+
class: f(w(pt)),
|
|
1685
1685
|
onClick: p
|
|
1686
1686
|
}, [O(w(X), {
|
|
1687
1687
|
size: 14,
|
|
1688
1688
|
"stroke-width": 2
|
|
1689
1689
|
}), u(" " + E(w(s).customBlocks.fields.addItem), 1)], 2)) : y("", !0),
|
|
1690
|
-
!l.value && !t.readOnly ? (e(), _("p",
|
|
1690
|
+
!l.value && !t.readOnly ? (e(), _("p", Ci, E(w(s).customBlocks.fields.maxItemsReached), 1)) : y("", !0)
|
|
1691
1691
|
])]),
|
|
1692
1692
|
_: 1
|
|
1693
1693
|
}, 8, [
|
|
@@ -1696,11 +1696,11 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1696
1696
|
"read-only"
|
|
1697
1697
|
]));
|
|
1698
1698
|
}
|
|
1699
|
-
}),
|
|
1699
|
+
}), Ti = [
|
|
1700
1700
|
"value",
|
|
1701
1701
|
"disabled",
|
|
1702
1702
|
"title"
|
|
1703
|
-
],
|
|
1703
|
+
], Ei = ["value"], Di = /* @__PURE__ */ p({
|
|
1704
1704
|
__name: "SelectField",
|
|
1705
1705
|
props: {
|
|
1706
1706
|
field: {},
|
|
@@ -1710,7 +1710,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1710
1710
|
emits: ["update:modelValue"],
|
|
1711
1711
|
setup(t, { emit: n }) {
|
|
1712
1712
|
let r = n, { t: i } = V();
|
|
1713
|
-
return (n, a) => (e(), S(
|
|
1713
|
+
return (n, a) => (e(), S(fi, {
|
|
1714
1714
|
label: t.field.label,
|
|
1715
1715
|
required: t.field.required,
|
|
1716
1716
|
"read-only": t.readOnly
|
|
@@ -1724,7 +1724,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1724
1724
|
}, [(e(!0), _(v, null, o(t.field.options, (t) => (e(), _("option", {
|
|
1725
1725
|
key: t.value,
|
|
1726
1726
|
value: t.value
|
|
1727
|
-
}, E(t.label), 9,
|
|
1727
|
+
}, E(t.label), 9, Ei))), 128))], 42, Ti)]),
|
|
1728
1728
|
_: 1
|
|
1729
1729
|
}, 8, [
|
|
1730
1730
|
"label",
|
|
@@ -1732,11 +1732,11 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1732
1732
|
"read-only"
|
|
1733
1733
|
]));
|
|
1734
1734
|
}
|
|
1735
|
-
}),
|
|
1735
|
+
}), Oi = [
|
|
1736
1736
|
"value",
|
|
1737
1737
|
"placeholder",
|
|
1738
1738
|
"title"
|
|
1739
|
-
],
|
|
1739
|
+
], ki = /* @__PURE__ */ p({
|
|
1740
1740
|
__name: "TextField",
|
|
1741
1741
|
props: {
|
|
1742
1742
|
field: {},
|
|
@@ -1746,7 +1746,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1746
1746
|
emits: ["update:modelValue"],
|
|
1747
1747
|
setup(t, { emit: n }) {
|
|
1748
1748
|
let r = n, { t: i } = V();
|
|
1749
|
-
return (n, a) => (e(), S(
|
|
1749
|
+
return (n, a) => (e(), S(fi, {
|
|
1750
1750
|
label: t.field.label,
|
|
1751
1751
|
required: t.field.required,
|
|
1752
1752
|
"read-only": t.readOnly
|
|
@@ -1759,7 +1759,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1759
1759
|
placeholder: t.field.placeholder,
|
|
1760
1760
|
disabled: "",
|
|
1761
1761
|
title: w(i).customBlocks.dataSource.readOnlyTooltip
|
|
1762
|
-
}, null, 10,
|
|
1762
|
+
}, null, 10, Oi)) : (e(), S(Z, {
|
|
1763
1763
|
key: 1,
|
|
1764
1764
|
"model-value": t.modelValue,
|
|
1765
1765
|
placeholder: t.field.placeholder,
|
|
@@ -1772,12 +1772,12 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1772
1772
|
"read-only"
|
|
1773
1773
|
]));
|
|
1774
1774
|
}
|
|
1775
|
-
}),
|
|
1775
|
+
}), Ai = [
|
|
1776
1776
|
"value",
|
|
1777
1777
|
"placeholder",
|
|
1778
1778
|
"title"
|
|
1779
|
-
],
|
|
1780
|
-
text:
|
|
1779
|
+
], ji = "tpl:w-full tpl:resize-y tpl:rounded-md tpl:border 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:opacity-60 tpl:cursor-not-allowed", Mi = {
|
|
1780
|
+
text: ki,
|
|
1781
1781
|
textarea: /* @__PURE__ */ p({
|
|
1782
1782
|
__name: "TextareaField",
|
|
1783
1783
|
props: {
|
|
@@ -1788,7 +1788,7 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1788
1788
|
emits: ["update:modelValue"],
|
|
1789
1789
|
setup(t, { emit: n }) {
|
|
1790
1790
|
let r = n, { t: i } = V();
|
|
1791
|
-
return (n, a) => (e(), S(
|
|
1791
|
+
return (n, a) => (e(), S(fi, {
|
|
1792
1792
|
label: t.field.label,
|
|
1793
1793
|
required: t.field.required,
|
|
1794
1794
|
"read-only": t.readOnly
|
|
@@ -1800,8 +1800,8 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1800
1800
|
rows: "3",
|
|
1801
1801
|
disabled: "",
|
|
1802
1802
|
title: w(i).customBlocks.dataSource.readOnlyTooltip,
|
|
1803
|
-
class: f(
|
|
1804
|
-
}, null, 8,
|
|
1803
|
+
class: f(ji)
|
|
1804
|
+
}, null, 8, Ai)) : (e(), S(gn, {
|
|
1805
1805
|
key: 1,
|
|
1806
1806
|
"model-value": t.modelValue,
|
|
1807
1807
|
placeholder: t.field.placeholder,
|
|
@@ -1815,42 +1815,42 @@ var $t = ["aria-label", "onKeydown"], en = ["data-tooltip"], tn = ["data-tooltip
|
|
|
1815
1815
|
]));
|
|
1816
1816
|
}
|
|
1817
1817
|
}),
|
|
1818
|
-
image:
|
|
1819
|
-
color:
|
|
1820
|
-
number:
|
|
1821
|
-
select:
|
|
1822
|
-
boolean:
|
|
1823
|
-
repeatable:
|
|
1818
|
+
image: gi,
|
|
1819
|
+
color: pi,
|
|
1820
|
+
number: vi,
|
|
1821
|
+
select: Di,
|
|
1822
|
+
boolean: li,
|
|
1823
|
+
repeatable: wi
|
|
1824
1824
|
};
|
|
1825
|
-
function
|
|
1826
|
-
return
|
|
1825
|
+
function Ni(e) {
|
|
1826
|
+
return Mi[e] ?? ki;
|
|
1827
1827
|
}
|
|
1828
1828
|
//#endregion
|
|
1829
1829
|
//#region src/components/toolbar/CustomBlockToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
1830
|
-
var
|
|
1830
|
+
var Pi = {
|
|
1831
1831
|
key: 0,
|
|
1832
1832
|
class: "tpl:p-4"
|
|
1833
|
-
},
|
|
1833
|
+
}, Fi = { class: "tpl:m-0 tpl:text-center tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Ii = { key: 1 }, Li = {
|
|
1834
1834
|
key: 0,
|
|
1835
1835
|
class: "tpl:m-0 tpl:mb-3 tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
1836
|
-
},
|
|
1836
|
+
}, Ri = {
|
|
1837
1837
|
key: 1,
|
|
1838
1838
|
class: "tpl:mb-4"
|
|
1839
|
-
},
|
|
1839
|
+
}, zi = {
|
|
1840
1840
|
key: 1,
|
|
1841
1841
|
class: "tpl:flex tpl:h-[32px] tpl:items-center"
|
|
1842
|
-
},
|
|
1842
|
+
}, Bi = {
|
|
1843
1843
|
key: 0,
|
|
1844
1844
|
class: "tpl:w-full tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-muted)]"
|
|
1845
|
-
},
|
|
1845
|
+
}, Vi = {
|
|
1846
1846
|
key: 2,
|
|
1847
1847
|
class: "tpl:m-0 tpl:mt-2 tpl:flex tpl:items-center tpl:gap-1.5 tpl:text-xs tpl:text-[var(--tpl-danger)]"
|
|
1848
|
-
},
|
|
1848
|
+
}, Hi = /* @__PURE__ */ p({
|
|
1849
1849
|
__name: "CustomBlockToolbar",
|
|
1850
1850
|
props: { block: {} },
|
|
1851
1851
|
emits: ["updateFieldValues", "updateDataSourceFetched"],
|
|
1852
1852
|
setup(t, { emit: n }) {
|
|
1853
|
-
let i = t, a = n, { t: s } = V(), c = k(
|
|
1853
|
+
let i = t, a = n, { t: s } = V(), c = k(Me, []), l = h(() => c.find((e) => e.type === i.block.customType)), { isFetching: d, fetchError: f, fetch: p, hasDataSource: m, needsFetch: b } = ne({
|
|
1854
1854
|
definition: l,
|
|
1855
1855
|
block: h(() => i.block),
|
|
1856
1856
|
onUpdate: (e, t) => {
|
|
@@ -1866,23 +1866,23 @@ var Mi = {
|
|
|
1866
1866
|
[e]: t
|
|
1867
1867
|
});
|
|
1868
1868
|
}
|
|
1869
|
-
return (n, i) => l.value ? (e(), _("div",
|
|
1870
|
-
l.value.description ? (e(), _("p",
|
|
1871
|
-
w(m) ? (e(), _("div",
|
|
1869
|
+
return (n, i) => l.value ? (e(), _("div", Ii, [
|
|
1870
|
+
l.value.description ? (e(), _("p", Li, E(l.value.description), 1)) : y("", !0),
|
|
1871
|
+
w(m) ? (e(), _("div", Ri, [w(b) && !w(d) ? (e(), _("button", {
|
|
1872
1872
|
key: 0,
|
|
1873
1873
|
type: "button",
|
|
1874
1874
|
class: "tpl:flex tpl:w-full tpl:items-center tpl:justify-center tpl:gap-2 tpl:rounded-md tpl:px-3 tpl:py-2.5 tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-bg)] tpl:transition-all tpl:duration-150 tpl:bg-[var(--tpl-primary)]",
|
|
1875
1875
|
onClick: i[0] ||= (...e) => w(p) && w(p)(...e)
|
|
1876
|
-
}, E(l.value?.dataSource?.label || w(s).customBlocks.dataSource.fetchButton), 1)) : (e(), _("div",
|
|
1876
|
+
}, E(l.value?.dataSource?.label || w(s).customBlocks.dataSource.fetchButton), 1)) : (e(), _("div", zi, [w(d) ? (e(), _("div", Bi, E(w(s).customBlocks.dataSource.fetching), 1)) : (e(), _("button", {
|
|
1877
1877
|
key: 1,
|
|
1878
1878
|
type: "button",
|
|
1879
1879
|
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)]",
|
|
1880
1880
|
onClick: i[1] ||= (...e) => w(p) && w(p)(...e)
|
|
1881
|
-
}, [O(w(
|
|
1881
|
+
}, [O(w(Ye), { size: 12 }), u(" " + E(w(s).customBlocks.dataSource.changeButton), 1)]))])), w(f) ? (e(), _("p", Vi, [O(w(Ue), {
|
|
1882
1882
|
size: 14,
|
|
1883
1883
|
class: "tpl:shrink-0"
|
|
1884
1884
|
}), u(" " + E(w(s).customBlocks.dataSource.fetchError), 1)])) : y("", !0)])) : y("", !0),
|
|
1885
|
-
(e(!0), _(v, null, o(l.value.fields, (n) => (e(), S(r(w(
|
|
1885
|
+
(e(!0), _(v, null, o(l.value.fields, (n) => (e(), S(r(w(Ni)(n.type)), {
|
|
1886
1886
|
key: n.key,
|
|
1887
1887
|
field: n,
|
|
1888
1888
|
"model-value": t.block.fieldValues[n.key],
|
|
@@ -1894,9 +1894,9 @@ var Mi = {
|
|
|
1894
1894
|
"read-only",
|
|
1895
1895
|
"onUpdate:modelValue"
|
|
1896
1896
|
]))), 128))
|
|
1897
|
-
])) : (e(), _("div",
|
|
1897
|
+
])) : (e(), _("div", Pi, [g("p", Fi, E(w(s).customBlocks.toolbar.noDefinition), 1)]));
|
|
1898
1898
|
}
|
|
1899
|
-
}),
|
|
1899
|
+
}), Ui = { class: "tpl:mb-3.5" }, Wi = { class: "tpl:mb-3.5" }, Gi = { class: "tpl:mb-3.5" }, Ki = { class: "tpl:flex tpl:items-stretch" }, qi = ["value"], Ji = /* @__PURE__ */ p({
|
|
1900
1900
|
__name: "DividerToolbar",
|
|
1901
1901
|
props: { block: {} },
|
|
1902
1902
|
emits: ["update"],
|
|
@@ -1906,7 +1906,7 @@ var Mi = {
|
|
|
1906
1906
|
r("update", { [e]: t });
|
|
1907
1907
|
}
|
|
1908
1908
|
return (n, r) => (e(), _(v, null, [
|
|
1909
|
-
g("div",
|
|
1909
|
+
g("div", Ui, [g("label", { class: f(w(W)) }, E(w(i).divider.style), 3), O(Y, {
|
|
1910
1910
|
options: [
|
|
1911
1911
|
{
|
|
1912
1912
|
value: "solid",
|
|
@@ -1924,53 +1924,53 @@ var Mi = {
|
|
|
1924
1924
|
"model-value": t.block.lineStyle,
|
|
1925
1925
|
"onUpdate:modelValue": r[0] ||= (e) => a("lineStyle", e)
|
|
1926
1926
|
}, null, 8, ["options", "model-value"])]),
|
|
1927
|
-
g("div",
|
|
1927
|
+
g("div", Wi, [g("label", { class: f(w(W)) }, E(w(i).divider.color), 3), O(q, {
|
|
1928
1928
|
"model-value": t.block.color,
|
|
1929
1929
|
"onUpdate:modelValue": r[1] ||= (e) => a("color", e)
|
|
1930
1930
|
}, null, 8, ["model-value"])]),
|
|
1931
|
-
g("div",
|
|
1931
|
+
g("div", Gi, [g("label", { class: f(w(W)) }, E(w(i).divider.thickness), 3), g("div", Ki, [g("input", {
|
|
1932
1932
|
type: "number",
|
|
1933
1933
|
class: f(w(K)),
|
|
1934
1934
|
value: t.block.thickness,
|
|
1935
1935
|
min: "1",
|
|
1936
1936
|
max: "10",
|
|
1937
1937
|
onInput: r[2] ||= (e) => a("thickness", Number(e.target.value))
|
|
1938
|
-
}, null, 42,
|
|
1938
|
+
}, null, 42, qi), g("span", { class: f(w(G)) }, "px", 2)])])
|
|
1939
1939
|
], 64));
|
|
1940
1940
|
}
|
|
1941
|
-
}),
|
|
1941
|
+
}), Yi = { class: "tpl:mb-3.5" }, Xi = ["value"], Zi = { class: "tpl:mt-1.5 tpl:flex tpl:items-start tpl:gap-1.5 tpl:text-[11px] tpl:text-[var(--tpl-text-dim)]" }, Qi = /* @__PURE__ */ p({
|
|
1942
1942
|
__name: "HtmlToolbar",
|
|
1943
1943
|
props: { block: {} },
|
|
1944
1944
|
emits: ["update"],
|
|
1945
1945
|
setup(t, { emit: n }) {
|
|
1946
1946
|
let r = n, { t: i } = V();
|
|
1947
|
-
return (n, a) => (e(), _("div",
|
|
1947
|
+
return (n, a) => (e(), _("div", Yi, [
|
|
1948
1948
|
g("label", { class: f(w(W)) }, E(w(i).html.content), 3),
|
|
1949
1949
|
g("textarea", {
|
|
1950
1950
|
value: t.block.content,
|
|
1951
1951
|
placeholder: "<div>...</div>",
|
|
1952
1952
|
rows: "10",
|
|
1953
|
-
class: f(w(
|
|
1953
|
+
class: f(w(mt)),
|
|
1954
1954
|
onInput: a[0] ||= (e) => r("update", { content: e.target.value })
|
|
1955
|
-
}, null, 42,
|
|
1956
|
-
g("p",
|
|
1955
|
+
}, null, 42, Xi),
|
|
1956
|
+
g("p", Zi, [O(w(Ze), {
|
|
1957
1957
|
size: 12,
|
|
1958
1958
|
class: "tpl:mt-0.5 tpl:shrink-0"
|
|
1959
1959
|
}), u(" " + E(w(i).html.sanitizationHint), 1)])
|
|
1960
1960
|
]));
|
|
1961
1961
|
}
|
|
1962
|
-
}),
|
|
1962
|
+
}), $i = { class: "tpl:mb-3.5" }, ea = {
|
|
1963
1963
|
key: 0,
|
|
1964
1964
|
class: "tpl:mb-3.5"
|
|
1965
|
-
},
|
|
1965
|
+
}, ta = ["value", "placeholder"], na = { class: "tpl:mb-3.5" }, ra = { class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]" }, ia = ["checked"], aa = { class: "tpl:block tpl:text-[var(--tpl-text-dim)]" }, oa = { class: "tpl:mb-3.5" }, sa = ["value"], ca = { value: "full" }, la = { class: "tpl:mb-3.5" }, ua = { class: "tpl:mb-3.5" }, da = {
|
|
1966
1966
|
key: 0,
|
|
1967
1967
|
class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]"
|
|
1968
|
-
},
|
|
1968
|
+
}, fa = ["checked"], pa = /* @__PURE__ */ p({
|
|
1969
1969
|
__name: "ImageToolbar",
|
|
1970
1970
|
props: { block: {} },
|
|
1971
1971
|
emits: ["update"],
|
|
1972
1972
|
setup(t, { emit: n }) {
|
|
1973
|
-
let r = n, { t: i } = V(), a = k(
|
|
1973
|
+
let r = n, { t: i } = V(), a = k(ke, null), o = k(Ve, ee.liquid), s = lt(), c = h(() => !!a), d = l(!1), p = l(!1), { start: m } = Te(() => {
|
|
1974
1974
|
d.value = !1;
|
|
1975
1975
|
}, 1e3, { immediate: !1 });
|
|
1976
1976
|
function b(e, t) {
|
|
@@ -1981,7 +1981,7 @@ var Mi = {
|
|
|
1981
1981
|
s.alive && e && (b("src", e.url), e.alt && (b("alt", e.alt), p.value = !0), d.value = !0, m());
|
|
1982
1982
|
}
|
|
1983
1983
|
return (n, r) => (e(), _(v, null, [
|
|
1984
|
-
g("div",
|
|
1984
|
+
g("div", $i, [
|
|
1985
1985
|
g("label", { class: f(w(W)) }, E(w(i).image.imageUrl), 3),
|
|
1986
1986
|
O(Z, {
|
|
1987
1987
|
"model-value": t.block.src,
|
|
@@ -2008,14 +2008,14 @@ var Mi = {
|
|
|
2008
2008
|
"stroke-width": 1.5
|
|
2009
2009
|
}), u(" " + E(w(i).image.browseMedia), 1)])) : y("", !0)
|
|
2010
2010
|
]),
|
|
2011
|
-
w(
|
|
2011
|
+
w(I)(t.block.src, w(o)) ? (e(), _("div", ea, [g("label", { class: f(w(W)) }, [u(E(w(i).image.placeholderUrl) + " ", 1), r[8] ||= g("span", { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, E("(optional)"), -1)], 2), g("input", {
|
|
2012
2012
|
type: "url",
|
|
2013
2013
|
class: f(w(U)),
|
|
2014
2014
|
value: t.block.placeholderUrl || "",
|
|
2015
2015
|
placeholder: w(i).image.placeholderUrlPlaceholder,
|
|
2016
2016
|
onInput: r[1] ||= (e) => b("placeholderUrl", e.target.value)
|
|
2017
|
-
}, null, 42,
|
|
2018
|
-
g("div",
|
|
2017
|
+
}, null, 42, ta)])) : y("", !0),
|
|
2018
|
+
g("div", na, [
|
|
2019
2019
|
g("label", { class: f(w(W)) }, E(w(i).image.altText), 3),
|
|
2020
2020
|
O(Z, {
|
|
2021
2021
|
"model-value": t.block.alt,
|
|
@@ -2030,24 +2030,24 @@ var Mi = {
|
|
|
2030
2030
|
"pulse",
|
|
2031
2031
|
"disabled"
|
|
2032
2032
|
]),
|
|
2033
|
-
g("label",
|
|
2033
|
+
g("label", ra, [g("input", {
|
|
2034
2034
|
type: "checkbox",
|
|
2035
2035
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
2036
2036
|
checked: t.block.decorative === !0,
|
|
2037
2037
|
onChange: r[3] ||= (e) => b("decorative", e.target.checked)
|
|
2038
|
-
}, null, 40,
|
|
2038
|
+
}, null, 40, ia), g("span", null, [u(E(w(i).image.decorative) + " ", 1), g("span", aa, E(w(i).image.decorativeHint), 1)])])
|
|
2039
2039
|
]),
|
|
2040
|
-
g("div",
|
|
2040
|
+
g("div", oa, [g("label", { class: f(w(W)) }, E(w(i).image.width), 3), g("select", {
|
|
2041
2041
|
class: f(w(U)),
|
|
2042
2042
|
value: t.block.width,
|
|
2043
2043
|
onChange: r[4] ||= (e) => b("width", e.target.value === "full" ? "full" : Number(e.target.value))
|
|
2044
2044
|
}, [
|
|
2045
|
-
g("option",
|
|
2045
|
+
g("option", ca, E(w(i).image.fullWidth), 1),
|
|
2046
2046
|
r[9] ||= g("option", { value: "300" }, "300px", -1),
|
|
2047
2047
|
r[10] ||= g("option", { value: "400" }, "400px", -1),
|
|
2048
2048
|
r[11] ||= g("option", { value: "500" }, "500px", -1)
|
|
2049
|
-
], 42,
|
|
2050
|
-
g("div",
|
|
2049
|
+
], 42, sa)]),
|
|
2050
|
+
g("div", la, [g("label", { class: f(w(W)) }, E(w(i).title.align), 3), O(Y, {
|
|
2051
2051
|
options: [
|
|
2052
2052
|
{
|
|
2053
2053
|
value: "left",
|
|
@@ -2065,7 +2065,7 @@ var Mi = {
|
|
|
2065
2065
|
"model-value": t.block.align,
|
|
2066
2066
|
"onUpdate:modelValue": r[5] ||= (e) => b("align", e)
|
|
2067
2067
|
}, null, 8, ["options", "model-value"])]),
|
|
2068
|
-
g("div",
|
|
2068
|
+
g("div", ua, [
|
|
2069
2069
|
g("label", { class: f(w(W)) }, E(w(i).image.linkUrl), 3),
|
|
2070
2070
|
O(Z, {
|
|
2071
2071
|
"model-value": t.block.linkUrl || "",
|
|
@@ -2073,20 +2073,20 @@ var Mi = {
|
|
|
2073
2073
|
placeholder: w(i).image.imageUrlPlaceholder,
|
|
2074
2074
|
"onUpdate:modelValue": r[6] ||= (e) => b("linkUrl", e)
|
|
2075
2075
|
}, null, 8, ["model-value", "placeholder"]),
|
|
2076
|
-
t.block.linkUrl ? (e(), _("label",
|
|
2076
|
+
t.block.linkUrl ? (e(), _("label", da, [g("input", {
|
|
2077
2077
|
type: "checkbox",
|
|
2078
2078
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
2079
2079
|
checked: t.block.linkOpenInNewTab ?? !1,
|
|
2080
2080
|
onChange: r[7] ||= (e) => b("linkOpenInNewTab", e.target.checked)
|
|
2081
|
-
}, null, 40,
|
|
2081
|
+
}, null, 40, fa), u(" " + E(w(i).image.openInNewTab), 1)])) : y("", !0)
|
|
2082
2082
|
])
|
|
2083
2083
|
], 64));
|
|
2084
2084
|
}
|
|
2085
|
-
}),
|
|
2085
|
+
}), ma = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, ha = { class: "tpl:flex tpl:items-center tpl:gap-2" }, ga = [
|
|
2086
2086
|
"value",
|
|
2087
2087
|
"placeholder",
|
|
2088
2088
|
"onInput"
|
|
2089
|
-
],
|
|
2089
|
+
], _a = ["title", "onClick"], va = { class: "tpl:flex tpl:items-center tpl:gap-3 tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, ya = ["checked", "onChange"], ba = { class: "tpl:flex tpl:items-center tpl:gap-2" }, xa = ["value"], Sa = { value: "" }, Ca = ["value"], wa = ["value"], Ta = /* @__PURE__ */ p({
|
|
2090
2090
|
__name: "MenuToolbar",
|
|
2091
2091
|
props: {
|
|
2092
2092
|
block: {},
|
|
@@ -2111,17 +2111,17 @@ var Mi = {
|
|
|
2111
2111
|
{
|
|
2112
2112
|
value: "left",
|
|
2113
2113
|
label: a.title.alignLeft,
|
|
2114
|
-
icon:
|
|
2114
|
+
icon: tt
|
|
2115
2115
|
},
|
|
2116
2116
|
{
|
|
2117
2117
|
value: "center",
|
|
2118
2118
|
label: a.title.alignCenter,
|
|
2119
|
-
icon:
|
|
2119
|
+
icon: nt
|
|
2120
2120
|
},
|
|
2121
2121
|
{
|
|
2122
2122
|
value: "right",
|
|
2123
2123
|
label: a.title.alignRight,
|
|
2124
|
-
icon:
|
|
2124
|
+
icon: rt
|
|
2125
2125
|
}
|
|
2126
2126
|
]);
|
|
2127
2127
|
function l(e, t) {
|
|
@@ -2129,7 +2129,7 @@ var Mi = {
|
|
|
2129
2129
|
}
|
|
2130
2130
|
function d() {
|
|
2131
2131
|
let e = {
|
|
2132
|
-
id:
|
|
2132
|
+
id: F(),
|
|
2133
2133
|
text: "",
|
|
2134
2134
|
url: "",
|
|
2135
2135
|
openInNewTab: !1,
|
|
@@ -2149,24 +2149,24 @@ var Mi = {
|
|
|
2149
2149
|
}
|
|
2150
2150
|
return (n, r) => (e(), _(v, null, [
|
|
2151
2151
|
O(J, { label: w(a).menu.items }, {
|
|
2152
|
-
default: j(() => [g("div",
|
|
2152
|
+
default: j(() => [g("div", ma, [(e(!0), _(v, null, o(t.block.items, (n) => (e(), _("div", {
|
|
2153
2153
|
key: n.id,
|
|
2154
2154
|
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"
|
|
2155
2155
|
}, [
|
|
2156
|
-
g("div",
|
|
2156
|
+
g("div", ha, [g("input", {
|
|
2157
2157
|
type: "text",
|
|
2158
2158
|
class: f([w(U), "tpl:flex-1"]),
|
|
2159
2159
|
value: n.text,
|
|
2160
2160
|
placeholder: w(a).menu.text,
|
|
2161
2161
|
onInput: (e) => p(n.id, "text", e.target.value)
|
|
2162
|
-
}, null, 42,
|
|
2163
|
-
class: f(w(
|
|
2162
|
+
}, null, 42, ga), g("button", {
|
|
2163
|
+
class: f(w(ft)),
|
|
2164
2164
|
title: w(a).menu.removeItem,
|
|
2165
2165
|
onClick: (e) => m(n.id)
|
|
2166
|
-
}, [O(w(
|
|
2166
|
+
}, [O(w(at), {
|
|
2167
2167
|
size: 14,
|
|
2168
2168
|
"stroke-width": 2
|
|
2169
|
-
})], 10,
|
|
2169
|
+
})], 10, _a)]),
|
|
2170
2170
|
O(Z, {
|
|
2171
2171
|
"model-value": n.url,
|
|
2172
2172
|
type: "url",
|
|
@@ -2177,7 +2177,7 @@ var Mi = {
|
|
|
2177
2177
|
"placeholder",
|
|
2178
2178
|
"onUpdate:modelValue"
|
|
2179
2179
|
]),
|
|
2180
|
-
g("div",
|
|
2180
|
+
g("div", va, [(e(!0), _(v, null, o(s.value, (t) => (e(), _("label", {
|
|
2181
2181
|
key: t.key,
|
|
2182
2182
|
class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-1"
|
|
2183
2183
|
}, [g("input", {
|
|
@@ -2185,14 +2185,14 @@ var Mi = {
|
|
|
2185
2185
|
checked: n[t.key],
|
|
2186
2186
|
class: "tpl:accent-[var(--tpl-primary)]",
|
|
2187
2187
|
onChange: (e) => p(n.id, t.key, e.target.checked)
|
|
2188
|
-
}, null, 40,
|
|
2189
|
-
g("div",
|
|
2188
|
+
}, null, 40, ya), u(" " + E(t.label), 1)]))), 128))]),
|
|
2189
|
+
g("div", ba, [g("label", { class: f([w(W), "tpl:!mb-0"]) }, E(w(a).menu.color), 3), O(q, {
|
|
2190
2190
|
"swatch-only": "",
|
|
2191
2191
|
"model-value": n.color || t.block.linkColor || t.block.color,
|
|
2192
2192
|
"onUpdate:modelValue": (e) => p(n.id, "color", e)
|
|
2193
2193
|
}, null, 8, ["model-value", "onUpdate:modelValue"])])
|
|
2194
2194
|
]))), 128)), g("button", {
|
|
2195
|
-
class: f(w(
|
|
2195
|
+
class: f(w(pt)),
|
|
2196
2196
|
onClick: d
|
|
2197
2197
|
}, [O(w(X), {
|
|
2198
2198
|
size: 14,
|
|
@@ -2205,14 +2205,14 @@ var Mi = {
|
|
|
2205
2205
|
class: f(w(U)),
|
|
2206
2206
|
value: t.block.fontFamily || "",
|
|
2207
2207
|
onChange: r[0] ||= (e) => l("fontFamily", e.target.value || void 0)
|
|
2208
|
-
}, [g("option",
|
|
2208
|
+
}, [g("option", Sa, E(w(a).title.inheritFont), 1), (e(!0), _(v, null, o(t.fontFamilies, (t) => (e(), _("option", {
|
|
2209
2209
|
key: t.value,
|
|
2210
2210
|
value: t.value
|
|
2211
|
-
}, E(t.label), 9,
|
|
2211
|
+
}, E(t.label), 9, Ca))), 128))], 42, xa)]),
|
|
2212
2212
|
_: 1
|
|
2213
2213
|
}, 8, ["label"]),
|
|
2214
2214
|
O(J, { label: w(a).menu.fontSize }, {
|
|
2215
|
-
default: j(() => [O(
|
|
2215
|
+
default: j(() => [O(_t, {
|
|
2216
2216
|
"model-value": t.block.fontSize,
|
|
2217
2217
|
min: 8,
|
|
2218
2218
|
max: 48,
|
|
@@ -2249,7 +2249,7 @@ var Mi = {
|
|
|
2249
2249
|
class: f(w(U)),
|
|
2250
2250
|
value: t.block.separator,
|
|
2251
2251
|
onInput: r[5] ||= (e) => l("separator", e.target.value)
|
|
2252
|
-
}, null, 42,
|
|
2252
|
+
}, null, 42, wa)]),
|
|
2253
2253
|
_: 1
|
|
2254
2254
|
}, 8, ["label"]),
|
|
2255
2255
|
O(J, { label: w(a).menu.separatorColor }, {
|
|
@@ -2260,7 +2260,7 @@ var Mi = {
|
|
|
2260
2260
|
_: 1
|
|
2261
2261
|
}, 8, ["label"]),
|
|
2262
2262
|
O(J, { label: w(a).menu.spacing }, {
|
|
2263
|
-
default: j(() => [O(
|
|
2263
|
+
default: j(() => [O(_t, {
|
|
2264
2264
|
"model-value": t.block.spacing,
|
|
2265
2265
|
min: 0,
|
|
2266
2266
|
max: 50,
|
|
@@ -2274,11 +2274,11 @@ var Mi = {
|
|
|
2274
2274
|
});
|
|
2275
2275
|
//#endregion
|
|
2276
2276
|
//#region src/utils/rebalanceColumnChildren.ts
|
|
2277
|
-
function
|
|
2277
|
+
function Ea(e) {
|
|
2278
2278
|
return e === "1" ? 1 : e === "3" ? 3 : 2;
|
|
2279
2279
|
}
|
|
2280
|
-
function
|
|
2281
|
-
let n =
|
|
2280
|
+
function Da(e, t) {
|
|
2281
|
+
let n = Ea(t);
|
|
2282
2282
|
if (e.length === n) return e;
|
|
2283
2283
|
if (e.length < n) {
|
|
2284
2284
|
let t = Array.from({ length: n - e.length }, () => []);
|
|
@@ -2289,7 +2289,7 @@ function Ta(e, t) {
|
|
|
2289
2289
|
}
|
|
2290
2290
|
//#endregion
|
|
2291
2291
|
//#region src/components/toolbar/SectionToolbar.vue?vue&type=script&setup=true&lang.ts
|
|
2292
|
-
var
|
|
2292
|
+
var Oa = { class: "tpl:mb-3.5" }, ka = ["value"], Aa = ["value"], ja = /* @__PURE__ */ p({
|
|
2293
2293
|
__name: "SectionToolbar",
|
|
2294
2294
|
props: { block: {} },
|
|
2295
2295
|
emits: ["update"],
|
|
@@ -2320,19 +2320,19 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2320
2320
|
let t = e.target.value;
|
|
2321
2321
|
i("update", {
|
|
2322
2322
|
columns: t,
|
|
2323
|
-
children:
|
|
2323
|
+
children: Da(r.block.children, t)
|
|
2324
2324
|
});
|
|
2325
2325
|
}
|
|
2326
|
-
return (n, r) => (e(), _("div",
|
|
2326
|
+
return (n, r) => (e(), _("div", Oa, [g("label", { class: f(w(W)) }, E(w(a).section.columns), 3), g("select", {
|
|
2327
2327
|
class: f(w(U)),
|
|
2328
2328
|
value: t.block.columns,
|
|
2329
2329
|
onChange: c
|
|
2330
2330
|
}, [(e(!0), _(v, null, o(s.value, (t) => (e(), _("option", {
|
|
2331
2331
|
key: t.value,
|
|
2332
2332
|
value: t.value
|
|
2333
|
-
}, E(t.label), 9,
|
|
2333
|
+
}, E(t.label), 9, Aa))), 128))], 42, ka)]));
|
|
2334
2334
|
}
|
|
2335
|
-
}),
|
|
2335
|
+
}), Ma = { class: "tpl:mb-3.5" }, Na = { class: "tpl:flex tpl:flex-col tpl:gap-2" }, Pa = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Fa = ["value", "onChange"], Ia = ["value"], La = ["title", "onClick"], Ra = { class: "tpl:mb-3.5" }, za = ["value"], Ba = { value: "solid" }, Va = { value: "outlined" }, Ha = { value: "rounded" }, Ua = { value: "square" }, Wa = { value: "circle" }, Ga = { class: "tpl:mb-3.5" }, Ka = { class: "tpl:mb-3.5" }, qa = { class: "tpl:flex tpl:items-stretch" }, Ja = ["value"], Ya = { class: "tpl:mb-3.5" }, Xa = /* @__PURE__ */ p({
|
|
2336
2336
|
__name: "SocialToolbar",
|
|
2337
2337
|
props: { block: {} },
|
|
2338
2338
|
emits: ["update"],
|
|
@@ -2343,7 +2343,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2343
2343
|
}
|
|
2344
2344
|
function c() {
|
|
2345
2345
|
let e = {
|
|
2346
|
-
id:
|
|
2346
|
+
id: F(),
|
|
2347
2347
|
platform: "facebook",
|
|
2348
2348
|
url: ""
|
|
2349
2349
|
};
|
|
@@ -2359,10 +2359,10 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2359
2359
|
i("update", { icons: r.block.icons.filter((t) => t.id !== e) });
|
|
2360
2360
|
}
|
|
2361
2361
|
return (n, r) => (e(), _(v, null, [
|
|
2362
|
-
g("div",
|
|
2362
|
+
g("div", Ma, [g("label", { class: f(w(W)) }, E(w(a).social.icons), 3), g("div", Na, [(e(!0), _(v, null, o(t.block.icons, (t) => (e(), _("div", {
|
|
2363
2363
|
key: t.id,
|
|
2364
2364
|
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"
|
|
2365
|
-
}, [g("div",
|
|
2365
|
+
}, [g("div", Pa, [g("select", {
|
|
2366
2366
|
"data-testid": "social-platform-select",
|
|
2367
2367
|
class: f([w(U), "tpl:flex-1"]),
|
|
2368
2368
|
value: t.platform,
|
|
@@ -2370,14 +2370,14 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2370
2370
|
}, [(e(!0), _(v, null, o(w(be), (t) => (e(), _("option", {
|
|
2371
2371
|
key: t,
|
|
2372
2372
|
value: t
|
|
2373
|
-
}, E(w(_e)[t].name), 9,
|
|
2374
|
-
class: f(w(
|
|
2373
|
+
}, E(w(_e)[t].name), 9, Ia))), 128))], 42, Fa), g("button", {
|
|
2374
|
+
class: f(w(ft)),
|
|
2375
2375
|
title: w(a).social.removeIcon,
|
|
2376
2376
|
onClick: (e) => d(t.id)
|
|
2377
|
-
}, [O(w(
|
|
2377
|
+
}, [O(w(at), {
|
|
2378
2378
|
size: 14,
|
|
2379
2379
|
"stroke-width": 2
|
|
2380
|
-
})], 10,
|
|
2380
|
+
})], 10, La)]), O(Z, {
|
|
2381
2381
|
"model-value": t.url,
|
|
2382
2382
|
type: "url",
|
|
2383
2383
|
placeholder: w(a).social.urlPlaceholder,
|
|
@@ -2387,24 +2387,24 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2387
2387
|
"placeholder",
|
|
2388
2388
|
"onUpdate:modelValue"
|
|
2389
2389
|
])]))), 128)), g("button", {
|
|
2390
|
-
class: f(w(
|
|
2390
|
+
class: f(w(pt)),
|
|
2391
2391
|
onClick: c
|
|
2392
2392
|
}, [O(w(X), {
|
|
2393
2393
|
size: 14,
|
|
2394
2394
|
"stroke-width": 2
|
|
2395
2395
|
}), u(" " + E(w(a).social.addIcon), 1)], 2)])]),
|
|
2396
|
-
g("div",
|
|
2396
|
+
g("div", Ra, [g("label", { class: f(w(W)) }, E(w(a).social.style), 3), g("select", {
|
|
2397
2397
|
class: f(w(U)),
|
|
2398
2398
|
value: t.block.iconStyle,
|
|
2399
2399
|
onChange: r[0] ||= (e) => s("iconStyle", e.target.value)
|
|
2400
2400
|
}, [
|
|
2401
|
-
g("option",
|
|
2402
|
-
g("option",
|
|
2403
|
-
g("option",
|
|
2404
|
-
g("option",
|
|
2405
|
-
g("option",
|
|
2406
|
-
], 42,
|
|
2407
|
-
g("div",
|
|
2401
|
+
g("option", Ba, E(w(a).social.styleSolid), 1),
|
|
2402
|
+
g("option", Va, E(w(a).social.styleOutlined), 1),
|
|
2403
|
+
g("option", Ha, E(w(a).social.styleRounded), 1),
|
|
2404
|
+
g("option", Ua, E(w(a).social.styleSquare), 1),
|
|
2405
|
+
g("option", Wa, E(w(a).social.styleCircle), 1)
|
|
2406
|
+
], 42, za)]),
|
|
2407
|
+
g("div", Ga, [g("label", { class: f(w(W)) }, E(w(a).social.size), 3), O(Y, {
|
|
2408
2408
|
options: [
|
|
2409
2409
|
{
|
|
2410
2410
|
value: "small",
|
|
@@ -2422,30 +2422,30 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2422
2422
|
"model-value": t.block.iconSize,
|
|
2423
2423
|
"onUpdate:modelValue": r[1] ||= (e) => s("iconSize", e)
|
|
2424
2424
|
}, null, 8, ["options", "model-value"])]),
|
|
2425
|
-
g("div",
|
|
2425
|
+
g("div", Ka, [g("label", { class: f(w(W)) }, E(w(a).social.spacing), 3), g("div", qa, [g("input", {
|
|
2426
2426
|
type: "number",
|
|
2427
2427
|
class: f(w(K)),
|
|
2428
2428
|
value: t.block.spacing,
|
|
2429
2429
|
min: "0",
|
|
2430
2430
|
max: "50",
|
|
2431
2431
|
onInput: r[2] ||= (e) => s("spacing", Number(e.target.value))
|
|
2432
|
-
}, null, 42,
|
|
2433
|
-
g("div",
|
|
2432
|
+
}, null, 42, Ja), g("span", { class: f(w(G)) }, "px", 2)])]),
|
|
2433
|
+
g("div", Ya, [g("label", { class: f(w(W)) }, E(w(a).social.align), 3), O(Y, {
|
|
2434
2434
|
options: [
|
|
2435
2435
|
{
|
|
2436
2436
|
value: "left",
|
|
2437
2437
|
label: w(a).title.alignLeft,
|
|
2438
|
-
icon: w(
|
|
2438
|
+
icon: w(tt)
|
|
2439
2439
|
},
|
|
2440
2440
|
{
|
|
2441
2441
|
value: "center",
|
|
2442
2442
|
label: w(a).title.alignCenter,
|
|
2443
|
-
icon: w(
|
|
2443
|
+
icon: w(nt)
|
|
2444
2444
|
},
|
|
2445
2445
|
{
|
|
2446
2446
|
value: "right",
|
|
2447
2447
|
label: w(a).title.alignRight,
|
|
2448
|
-
icon: w(
|
|
2448
|
+
icon: w(rt)
|
|
2449
2449
|
}
|
|
2450
2450
|
],
|
|
2451
2451
|
"model-value": t.block.align,
|
|
@@ -2453,22 +2453,22 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2453
2453
|
}, null, 8, ["options", "model-value"])])
|
|
2454
2454
|
], 64));
|
|
2455
2455
|
}
|
|
2456
|
-
}),
|
|
2456
|
+
}), Za = { class: "tpl:mb-3.5" }, Qa = { class: "tpl:flex tpl:items-stretch" }, $a = ["value"], eo = ["value"], to = /* @__PURE__ */ p({
|
|
2457
2457
|
__name: "SpacerToolbar",
|
|
2458
2458
|
props: { block: {} },
|
|
2459
2459
|
emits: ["update"],
|
|
2460
2460
|
setup(t, { emit: n }) {
|
|
2461
2461
|
let r = n, { t: i } = V();
|
|
2462
|
-
return (n, a) => (e(), _("div",
|
|
2462
|
+
return (n, a) => (e(), _("div", Za, [
|
|
2463
2463
|
g("label", { class: f(w(W)) }, E(w(i).spacer.height), 3),
|
|
2464
|
-
g("div",
|
|
2464
|
+
g("div", Qa, [g("input", {
|
|
2465
2465
|
type: "number",
|
|
2466
2466
|
class: f(w(K)),
|
|
2467
2467
|
value: t.block.height,
|
|
2468
2468
|
min: "10",
|
|
2469
2469
|
max: "100",
|
|
2470
2470
|
onInput: a[0] ||= (e) => r("update", { height: Number(e.target.value) })
|
|
2471
|
-
}, null, 42,
|
|
2471
|
+
}, null, 42, $a), g("span", { class: f(w(G)) }, "px", 2)]),
|
|
2472
2472
|
g("input", {
|
|
2473
2473
|
type: "range",
|
|
2474
2474
|
class: "tpl:mt-2 tpl:w-full tpl:accent-[var(--tpl-primary)]",
|
|
@@ -2476,13 +2476,13 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2476
2476
|
min: "10",
|
|
2477
2477
|
max: "100",
|
|
2478
2478
|
onInput: a[1] ||= (e) => r("update", { height: Number(e.target.value) })
|
|
2479
|
-
}, null, 40,
|
|
2479
|
+
}, null, 40, eo)
|
|
2480
2480
|
]));
|
|
2481
2481
|
}
|
|
2482
|
-
}),
|
|
2482
|
+
}), no = { class: "tpl:mb-3.5" }, ro = { class: "tpl:flex tpl:items-center tpl:gap-3" }, io = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, ao = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, oo = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, so = ["disabled"], co = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, lo = { class: "tpl:flex tpl:flex-1 tpl:items-center tpl:gap-1.5" }, uo = { class: "tpl:text-xs tpl:text-[var(--tpl-text-muted)]" }, fo = { class: "tpl:flex tpl:items-center tpl:rounded-md tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)]" }, po = ["disabled"], mo = { class: "tpl:min-w-[20px] tpl:text-center tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)]" }, ho = { class: "tpl:mb-3.5" }, go = { 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)]" }, _o = ["checked"], vo = {
|
|
2483
2483
|
key: 0,
|
|
2484
2484
|
class: "tpl:mb-3.5"
|
|
2485
|
-
},
|
|
2485
|
+
}, yo = { class: "tpl:mb-3.5" }, bo = { class: "tpl:mb-3.5" }, xo = { class: "tpl:flex tpl:items-stretch" }, So = ["value"], Co = { class: "tpl:mb-3.5" }, wo = { class: "tpl:flex tpl:items-stretch" }, To = ["value"], Eo = { class: "tpl:mb-3.5" }, Do = ["value"], Oo = { value: "" }, ko = ["value"], Ao = { class: "tpl:mb-3.5" }, jo = { class: "tpl:flex tpl:items-stretch" }, Mo = ["value"], No = { class: "tpl:mb-3.5" }, Po = { class: "tpl:mb-3.5" }, Fo = /* @__PURE__ */ p({
|
|
2486
2486
|
__name: "TableToolbar",
|
|
2487
2487
|
props: {
|
|
2488
2488
|
block: {},
|
|
@@ -2496,9 +2496,9 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2496
2496
|
}
|
|
2497
2497
|
function l() {
|
|
2498
2498
|
let e = r.block.rows.length > 0 ? r.block.rows[0].cells.length : 3, t = {
|
|
2499
|
-
id:
|
|
2499
|
+
id: F(),
|
|
2500
2500
|
cells: Array.from({ length: e }, () => ({
|
|
2501
|
-
id:
|
|
2501
|
+
id: F(),
|
|
2502
2502
|
content: ""
|
|
2503
2503
|
}))
|
|
2504
2504
|
};
|
|
@@ -2511,7 +2511,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2511
2511
|
i("update", { rows: r.block.rows.map((e) => ({
|
|
2512
2512
|
...e,
|
|
2513
2513
|
cells: [...e.cells, {
|
|
2514
|
-
id:
|
|
2514
|
+
id: F(),
|
|
2515
2515
|
content: ""
|
|
2516
2516
|
}]
|
|
2517
2517
|
})) });
|
|
@@ -2523,16 +2523,16 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2523
2523
|
})) });
|
|
2524
2524
|
}
|
|
2525
2525
|
return (n, r) => (e(), _(v, null, [
|
|
2526
|
-
g("div",
|
|
2526
|
+
g("div", no, [g("label", { class: f(w(W)) }, E(w(a).table.dimensions), 3), g("div", ro, [g("div", io, [g("span", ao, E(w(a).table.rows), 1), g("div", oo, [
|
|
2527
2527
|
g("button", {
|
|
2528
2528
|
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",
|
|
2529
2529
|
disabled: t.block.rows.length <= 1,
|
|
2530
2530
|
onClick: r[0] ||= (e) => d(t.block.rows[t.block.rows.length - 1].id)
|
|
2531
|
-
}, [O(w(
|
|
2531
|
+
}, [O(w(We), {
|
|
2532
2532
|
size: 12,
|
|
2533
2533
|
"stroke-width": 2
|
|
2534
|
-
})], 8,
|
|
2535
|
-
g("span",
|
|
2534
|
+
})], 8, so),
|
|
2535
|
+
g("span", co, E(t.block.rows.length), 1),
|
|
2536
2536
|
g("button", {
|
|
2537
2537
|
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)]",
|
|
2538
2538
|
onClick: l
|
|
@@ -2540,16 +2540,16 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2540
2540
|
size: 12,
|
|
2541
2541
|
"stroke-width": 2
|
|
2542
2542
|
})])
|
|
2543
|
-
])]), g("div",
|
|
2543
|
+
])]), g("div", lo, [g("span", uo, E(w(a).table.columns), 1), g("div", fo, [
|
|
2544
2544
|
g("button", {
|
|
2545
2545
|
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",
|
|
2546
2546
|
disabled: s.value <= 1,
|
|
2547
2547
|
onClick: r[1] ||= (e) => m(s.value - 1)
|
|
2548
|
-
}, [O(w(
|
|
2548
|
+
}, [O(w(We), {
|
|
2549
2549
|
size: 12,
|
|
2550
2550
|
"stroke-width": 2
|
|
2551
|
-
})], 8,
|
|
2552
|
-
g("span",
|
|
2551
|
+
})], 8, po),
|
|
2552
|
+
g("span", mo, E(s.value), 1),
|
|
2553
2553
|
g("button", {
|
|
2554
2554
|
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)]",
|
|
2555
2555
|
onClick: p
|
|
@@ -2558,73 +2558,73 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2558
2558
|
"stroke-width": 2
|
|
2559
2559
|
})])
|
|
2560
2560
|
])])])]),
|
|
2561
|
-
g("div",
|
|
2561
|
+
g("div", ho, [g("label", go, [g("input", {
|
|
2562
2562
|
type: "checkbox",
|
|
2563
2563
|
checked: t.block.hasHeaderRow,
|
|
2564
2564
|
class: "tpl:accent-[var(--tpl-primary)]",
|
|
2565
2565
|
onChange: r[2] ||= (e) => c("hasHeaderRow", e.target.checked)
|
|
2566
|
-
}, null, 40,
|
|
2567
|
-
t.block.hasHeaderRow ? (e(), _("div",
|
|
2566
|
+
}, null, 40, _o), u(" " + E(w(a).table.hasHeaderRow), 1)])]),
|
|
2567
|
+
t.block.hasHeaderRow ? (e(), _("div", vo, [g("label", { class: f(w(W)) }, E(w(a).table.headerBackgroundColor), 3), O(q, {
|
|
2568
2568
|
"model-value": t.block.headerBackgroundColor || w("#f2f2f2"),
|
|
2569
2569
|
placeholder: w(a).table.noHeaderBg,
|
|
2570
2570
|
"onUpdate:modelValue": r[3] ||= (e) => c("headerBackgroundColor", e || null)
|
|
2571
2571
|
}, null, 8, ["model-value", "placeholder"])])) : y("", !0),
|
|
2572
|
-
g("div",
|
|
2572
|
+
g("div", yo, [g("label", { class: f(w(W)) }, E(w(a).table.borderColor), 3), O(q, {
|
|
2573
2573
|
"model-value": t.block.borderColor,
|
|
2574
2574
|
"onUpdate:modelValue": r[4] ||= (e) => c("borderColor", e)
|
|
2575
2575
|
}, null, 8, ["model-value"])]),
|
|
2576
|
-
g("div",
|
|
2576
|
+
g("div", bo, [g("label", { class: f(w(W)) }, E(w(a).table.borderWidth), 3), g("div", xo, [g("input", {
|
|
2577
2577
|
type: "number",
|
|
2578
2578
|
class: f(w(K)),
|
|
2579
2579
|
value: t.block.borderWidth,
|
|
2580
2580
|
min: "0",
|
|
2581
2581
|
max: "10",
|
|
2582
2582
|
onInput: r[5] ||= (e) => c("borderWidth", Number(e.target.value))
|
|
2583
|
-
}, null, 42,
|
|
2584
|
-
g("div",
|
|
2583
|
+
}, null, 42, So), g("span", { class: f(w(G)) }, "px", 2)])]),
|
|
2584
|
+
g("div", Co, [g("label", { class: f(w(W)) }, E(w(a).table.cellPadding), 3), g("div", wo, [g("input", {
|
|
2585
2585
|
type: "number",
|
|
2586
2586
|
class: f(w(K)),
|
|
2587
2587
|
value: t.block.cellPadding,
|
|
2588
2588
|
min: "0",
|
|
2589
2589
|
max: "30",
|
|
2590
2590
|
onInput: r[6] ||= (e) => c("cellPadding", Number(e.target.value))
|
|
2591
|
-
}, null, 42,
|
|
2592
|
-
g("div",
|
|
2591
|
+
}, null, 42, To), g("span", { class: f(w(G)) }, "px", 2)])]),
|
|
2592
|
+
g("div", Eo, [g("label", { class: f(w(W)) }, E(w(a).table.fontFamily), 3), g("select", {
|
|
2593
2593
|
class: f(w(U)),
|
|
2594
2594
|
value: t.block.fontFamily || "",
|
|
2595
2595
|
onChange: r[7] ||= (e) => c("fontFamily", e.target.value || void 0)
|
|
2596
|
-
}, [g("option",
|
|
2596
|
+
}, [g("option", Oo, E(w(a).title.inheritFont), 1), (e(!0), _(v, null, o(t.fontFamilies, (t) => (e(), _("option", {
|
|
2597
2597
|
key: t.value,
|
|
2598
2598
|
value: t.value
|
|
2599
|
-
}, E(t.label), 9,
|
|
2600
|
-
g("div",
|
|
2599
|
+
}, E(t.label), 9, ko))), 128))], 42, Do)]),
|
|
2600
|
+
g("div", Ao, [g("label", { class: f(w(W)) }, E(w(a).table.fontSize), 3), g("div", jo, [g("input", {
|
|
2601
2601
|
type: "number",
|
|
2602
2602
|
class: f(w(K)),
|
|
2603
2603
|
value: t.block.fontSize,
|
|
2604
2604
|
min: "10",
|
|
2605
2605
|
max: "32",
|
|
2606
2606
|
onInput: r[8] ||= (e) => c("fontSize", Number(e.target.value))
|
|
2607
|
-
}, null, 42,
|
|
2608
|
-
g("div",
|
|
2607
|
+
}, null, 42, Mo), g("span", { class: f(w(G)) }, "px", 2)])]),
|
|
2608
|
+
g("div", No, [g("label", { class: f(w(W)) }, E(w(a).table.color), 3), O(q, {
|
|
2609
2609
|
"model-value": t.block.color,
|
|
2610
2610
|
"onUpdate:modelValue": r[9] ||= (e) => c("color", e)
|
|
2611
2611
|
}, null, 8, ["model-value"])]),
|
|
2612
|
-
g("div",
|
|
2612
|
+
g("div", Po, [g("label", { class: f(w(W)) }, E(w(a).table.textAlign), 3), O(Y, {
|
|
2613
2613
|
options: [
|
|
2614
2614
|
{
|
|
2615
2615
|
value: "left",
|
|
2616
2616
|
label: w(a).title.alignLeft,
|
|
2617
|
-
icon: w(
|
|
2617
|
+
icon: w(tt)
|
|
2618
2618
|
},
|
|
2619
2619
|
{
|
|
2620
2620
|
value: "center",
|
|
2621
2621
|
label: w(a).title.alignCenter,
|
|
2622
|
-
icon: w(
|
|
2622
|
+
icon: w(nt)
|
|
2623
2623
|
},
|
|
2624
2624
|
{
|
|
2625
2625
|
value: "right",
|
|
2626
2626
|
label: w(a).title.alignRight,
|
|
2627
|
-
icon: w(
|
|
2627
|
+
icon: w(rt)
|
|
2628
2628
|
}
|
|
2629
2629
|
],
|
|
2630
2630
|
"model-value": t.block.textAlign,
|
|
@@ -2632,7 +2632,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2632
2632
|
}, null, 8, ["options", "model-value"])])
|
|
2633
2633
|
], 64));
|
|
2634
2634
|
}
|
|
2635
|
-
}),
|
|
2635
|
+
}), Io = { class: "tpl:mb-3.5" }, Lo = ["value"], Ro = { value: 1 }, zo = { value: 2 }, Bo = { value: 3 }, Vo = { value: 4 }, Ho = { class: "tpl:mb-3.5" }, Uo = ["value"], Wo = { value: "" }, Go = ["value"], Ko = { class: "tpl:mb-3.5" }, qo = { class: "tpl:mb-3.5" }, Jo = /* @__PURE__ */ p({
|
|
2636
2636
|
__name: "TitleToolbar",
|
|
2637
2637
|
props: {
|
|
2638
2638
|
block: {},
|
|
@@ -2645,44 +2645,44 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2645
2645
|
r("update", { [e]: t });
|
|
2646
2646
|
}
|
|
2647
2647
|
return (n, r) => (e(), _(v, null, [
|
|
2648
|
-
g("div",
|
|
2648
|
+
g("div", Io, [g("label", { class: f(w(W)) }, E(w(i).title.level), 3), g("select", {
|
|
2649
2649
|
class: f(w(U)),
|
|
2650
2650
|
value: t.block.level,
|
|
2651
2651
|
onChange: r[0] ||= (e) => a("level", Number(e.target.value))
|
|
2652
2652
|
}, [
|
|
2653
|
-
g("option",
|
|
2654
|
-
g("option",
|
|
2655
|
-
g("option",
|
|
2656
|
-
g("option",
|
|
2657
|
-
], 42,
|
|
2658
|
-
g("div",
|
|
2653
|
+
g("option", Ro, E(w(i).title.heading1), 1),
|
|
2654
|
+
g("option", zo, E(w(i).title.heading2), 1),
|
|
2655
|
+
g("option", Bo, E(w(i).title.heading3), 1),
|
|
2656
|
+
g("option", Vo, E(w(i).title.heading4), 1)
|
|
2657
|
+
], 42, Lo)]),
|
|
2658
|
+
g("div", Ho, [g("label", { class: f(w(W)) }, E(w(i).title.fontFamily), 3), g("select", {
|
|
2659
2659
|
class: f(w(U)),
|
|
2660
2660
|
value: t.block.fontFamily || "",
|
|
2661
2661
|
onChange: r[1] ||= (e) => a("fontFamily", e.target.value || void 0)
|
|
2662
|
-
}, [g("option",
|
|
2662
|
+
}, [g("option", Wo, E(w(i).title.inheritFont), 1), (e(!0), _(v, null, o(t.fontFamilies, (t) => (e(), _("option", {
|
|
2663
2663
|
key: t.value,
|
|
2664
2664
|
value: t.value
|
|
2665
|
-
}, E(t.label), 9,
|
|
2666
|
-
g("div",
|
|
2665
|
+
}, E(t.label), 9, Go))), 128))], 42, Uo)]),
|
|
2666
|
+
g("div", Ko, [g("label", { class: f(w(W)) }, E(w(i).title.color), 3), O(q, {
|
|
2667
2667
|
"model-value": t.block.color,
|
|
2668
2668
|
"onUpdate:modelValue": r[2] ||= (e) => a("color", e)
|
|
2669
2669
|
}, null, 8, ["model-value"])]),
|
|
2670
|
-
g("div",
|
|
2670
|
+
g("div", qo, [g("label", { class: f(w(W)) }, E(w(i).title.align), 3), O(Y, {
|
|
2671
2671
|
options: [
|
|
2672
2672
|
{
|
|
2673
2673
|
value: "left",
|
|
2674
2674
|
label: w(i).title.alignLeft,
|
|
2675
|
-
icon: w(
|
|
2675
|
+
icon: w(tt)
|
|
2676
2676
|
},
|
|
2677
2677
|
{
|
|
2678
2678
|
value: "center",
|
|
2679
2679
|
label: w(i).title.alignCenter,
|
|
2680
|
-
icon: w(
|
|
2680
|
+
icon: w(nt)
|
|
2681
2681
|
},
|
|
2682
2682
|
{
|
|
2683
2683
|
value: "right",
|
|
2684
2684
|
label: w(i).title.alignRight,
|
|
2685
|
-
icon: w(
|
|
2685
|
+
icon: w(rt)
|
|
2686
2686
|
}
|
|
2687
2687
|
],
|
|
2688
2688
|
"model-value": t.block.textAlign,
|
|
@@ -2690,22 +2690,22 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2690
2690
|
}, null, 8, ["options", "model-value"])])
|
|
2691
2691
|
], 64));
|
|
2692
2692
|
}
|
|
2693
|
-
}),
|
|
2693
|
+
}), Yo = { class: "tpl:mb-3.5" }, Xo = {
|
|
2694
2694
|
key: 0,
|
|
2695
2695
|
class: "tpl:mt-2 tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text-muted)]"
|
|
2696
|
-
},
|
|
2696
|
+
}, Zo = ["checked"], Qo = {
|
|
2697
2697
|
key: 0,
|
|
2698
2698
|
class: "tpl:mb-3.5"
|
|
2699
|
-
},
|
|
2699
|
+
}, $o = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, es = [
|
|
2700
2700
|
"value",
|
|
2701
2701
|
"placeholder",
|
|
2702
2702
|
"title"
|
|
2703
|
-
],
|
|
2703
|
+
], ts = { class: "tpl:mb-3.5" }, ns = { class: "tpl:font-normal tpl:text-[var(--tpl-text-dim)]" }, rs = { class: "tpl:mb-3.5" }, is = { class: "tpl:mb-3.5" }, as = ["value"], os = { value: "full" }, ss = { class: "tpl:mb-3.5" }, cs = /* @__PURE__ */ p({
|
|
2704
2704
|
__name: "VideoToolbar",
|
|
2705
2705
|
props: { block: {} },
|
|
2706
2706
|
emits: ["update"],
|
|
2707
2707
|
setup(t, { emit: n }) {
|
|
2708
|
-
let r = t, i = n, { t: a } = V(), o = k(
|
|
2708
|
+
let r = t, i = n, { t: a } = V(), o = k(ke, null), s = k(Ve, ee.liquid), c = lt(), d = h(() => !!o), p = h(() => I(r.block.url, s)), m = l(!1), { start: b } = Te(() => {
|
|
2709
2709
|
m.value = !1;
|
|
2710
2710
|
}, 1e3, { immediate: !1 });
|
|
2711
2711
|
function x(e, t) {
|
|
@@ -2716,7 +2716,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2716
2716
|
c.alive && e && (x("thumbnailUrl", e.url), m.value = !0, b());
|
|
2717
2717
|
}
|
|
2718
2718
|
return (n, r) => (e(), _(v, null, [
|
|
2719
|
-
g("div",
|
|
2719
|
+
g("div", Yo, [
|
|
2720
2720
|
g("label", { class: f(w(W)) }, E(w(a).video.videoUrl), 3),
|
|
2721
2721
|
O(Z, {
|
|
2722
2722
|
"model-value": t.block.url,
|
|
@@ -2724,23 +2724,23 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2724
2724
|
placeholder: w(a).video.videoUrlPlaceholder,
|
|
2725
2725
|
"onUpdate:modelValue": r[0] ||= (e) => x("url", e)
|
|
2726
2726
|
}, null, 8, ["model-value", "placeholder"]),
|
|
2727
|
-
t.block.url ? (e(), _("label",
|
|
2727
|
+
t.block.url ? (e(), _("label", Xo, [g("input", {
|
|
2728
2728
|
type: "checkbox",
|
|
2729
2729
|
class: "tpl:size-3.5 tpl:cursor-pointer tpl:accent-[var(--tpl-primary)]",
|
|
2730
2730
|
checked: t.block.openInNewTab ?? !1,
|
|
2731
2731
|
onChange: r[1] ||= (e) => x("openInNewTab", e.target.checked)
|
|
2732
|
-
}, null, 40,
|
|
2732
|
+
}, null, 40, Zo), u(" " + E(w(a).video.openInNewTab), 1)])) : y("", !0)
|
|
2733
2733
|
]),
|
|
2734
|
-
p.value ? (e(), _("div",
|
|
2734
|
+
p.value ? (e(), _("div", Qo, [g("label", { class: f(w(W)) }, [u(E(w(a).video.placeholderUrl) + " ", 1), g("span", $o, E(w(a).video.optional), 1)], 2), g("input", {
|
|
2735
2735
|
type: "url",
|
|
2736
2736
|
class: f(w(U)),
|
|
2737
2737
|
value: t.block.placeholderUrl || "",
|
|
2738
2738
|
placeholder: w(a).video.placeholderUrlPlaceholder,
|
|
2739
2739
|
title: w(a).video.placeholderUrlTooltip,
|
|
2740
2740
|
onInput: r[2] ||= (e) => x("placeholderUrl", e.target.value)
|
|
2741
|
-
}, null, 42,
|
|
2742
|
-
g("div",
|
|
2743
|
-
g("label", { class: f(w(W)) }, [u(E(w(a).video.customThumbnail) + " ", 1), g("span",
|
|
2741
|
+
}, null, 42, es)])) : y("", !0),
|
|
2742
|
+
g("div", ts, [
|
|
2743
|
+
g("label", { class: f(w(W)) }, [u(E(w(a).video.customThumbnail) + " ", 1), g("span", ns, E(w(a).video.optional), 1)], 2),
|
|
2744
2744
|
O(Z, {
|
|
2745
2745
|
"model-value": t.block.thumbnailUrl,
|
|
2746
2746
|
type: "url",
|
|
@@ -2766,23 +2766,23 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2766
2766
|
"stroke-width": 1.5
|
|
2767
2767
|
}), u(" " + E(w(a).image.browseMedia), 1)])) : y("", !0)
|
|
2768
2768
|
]),
|
|
2769
|
-
g("div",
|
|
2769
|
+
g("div", rs, [g("label", { class: f(w(W)) }, E(w(a).video.altText), 3), O(Z, {
|
|
2770
2770
|
"model-value": t.block.alt,
|
|
2771
2771
|
type: "text",
|
|
2772
2772
|
placeholder: w(a).video.altTextPlaceholder,
|
|
2773
2773
|
"onUpdate:modelValue": r[4] ||= (e) => x("alt", e)
|
|
2774
2774
|
}, null, 8, ["model-value", "placeholder"])]),
|
|
2775
|
-
g("div",
|
|
2775
|
+
g("div", is, [g("label", { class: f(w(W)) }, E(w(a).video.width), 3), g("select", {
|
|
2776
2776
|
class: f(w(U)),
|
|
2777
2777
|
value: t.block.width,
|
|
2778
2778
|
onChange: r[5] ||= (e) => x("width", e.target.value === "full" ? "full" : Number(e.target.value))
|
|
2779
2779
|
}, [
|
|
2780
|
-
g("option",
|
|
2780
|
+
g("option", os, E(w(a).video.fullWidth), 1),
|
|
2781
2781
|
r[7] ||= g("option", { value: "300" }, "300px", -1),
|
|
2782
2782
|
r[8] ||= g("option", { value: "400" }, "400px", -1),
|
|
2783
2783
|
r[9] ||= g("option", { value: "500" }, "500px", -1)
|
|
2784
|
-
], 42,
|
|
2785
|
-
g("div",
|
|
2784
|
+
], 42, as)]),
|
|
2785
|
+
g("div", ss, [g("label", { class: f(w(W)) }, E(w(a).title.align), 3), O(Y, {
|
|
2786
2786
|
options: [
|
|
2787
2787
|
{
|
|
2788
2788
|
value: "left",
|
|
@@ -2802,7 +2802,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2802
2802
|
}, null, 8, ["options", "model-value"])])
|
|
2803
2803
|
], 64));
|
|
2804
2804
|
}
|
|
2805
|
-
}),
|
|
2805
|
+
}), ls = ["aria-label"], us = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-4 tpl:py-3.5" }, ds = { class: "tpl:flex tpl:items-center tpl:gap-2 tpl:text-[var(--tpl-primary)]" }, fs = { class: "tpl:m-0 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, ps = { class: "tpl:flex tpl:gap-1" }, ms = ["title"], hs = ["title"], gs = { class: "tpl:flex-1 tpl:overflow-y-auto tpl:p-4" }, _s = /* @__PURE__ */ ot(/* @__PURE__ */ p({
|
|
2806
2806
|
__name: "Toolbar",
|
|
2807
2807
|
props: { block: {} },
|
|
2808
2808
|
emits: [
|
|
@@ -2811,16 +2811,16 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2811
2811
|
"duplicate"
|
|
2812
2812
|
],
|
|
2813
2813
|
setup(t, { emit: n }) {
|
|
2814
|
-
let i = A(() => import("./CountdownToolbar-Dvr2icg-.js")), a = t, o = n, { t: s } = V(), c =
|
|
2814
|
+
let i = A(() => import("./CountdownToolbar-Dvr2icg-.js")), a = t, o = n, { t: s } = V(), c = Fe(Pe, "Toolbar"), l = k(Me, []), u = h(() => a.block.type), d = h(() => P(a.block)), f = h(() => {
|
|
2815
2815
|
if (d.value) return l.find((e) => e.type === a.block.customType);
|
|
2816
|
-
}), p = h(() => d.value ? f.value?.name ?? a.block.customType :
|
|
2816
|
+
}), p = h(() => d.value ? f.value?.name ?? a.block.customType : z(u.value, s)), m = c.fonts;
|
|
2817
2817
|
function b(e) {
|
|
2818
2818
|
o("update", e);
|
|
2819
2819
|
}
|
|
2820
2820
|
return (n, a) => (e(), _("aside", {
|
|
2821
2821
|
"aria-label": w(s).landmarks.blockToolbar,
|
|
2822
2822
|
class: "tpl:flex tpl:w-full tpl:flex-1 tpl:flex-col tpl:bg-[var(--tpl-bg-elevated)]"
|
|
2823
|
-
}, [g("div",
|
|
2823
|
+
}, [g("div", us, [g("div", ds, [w(qe)[u.value] ? (e(), S(r(w(qe)[u.value]), {
|
|
2824
2824
|
key: 0,
|
|
2825
2825
|
size: 16,
|
|
2826
2826
|
"stroke-width": 1.5
|
|
@@ -2828,70 +2828,70 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2828
2828
|
key: 1,
|
|
2829
2829
|
size: 16,
|
|
2830
2830
|
"stroke-width": 1.5
|
|
2831
|
-
})) : y("", !0), g("h3",
|
|
2831
|
+
})) : y("", !0), g("h3", fs, E(p.value), 1)]), g("div", ps, [g("button", {
|
|
2832
2832
|
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)]",
|
|
2833
2833
|
title: w(s).toolbar.duplicate,
|
|
2834
2834
|
onClick: a[0] ||= (e) => o("duplicate")
|
|
2835
2835
|
}, [O(w(fe), {
|
|
2836
2836
|
size: 14,
|
|
2837
2837
|
"stroke-width": 2
|
|
2838
|
-
})], 8,
|
|
2838
|
+
})], 8, ms), g("button", {
|
|
2839
2839
|
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)]",
|
|
2840
2840
|
title: w(s).toolbar.delete,
|
|
2841
2841
|
onClick: a[1] ||= (e) => o("delete")
|
|
2842
|
-
}, [O(w(
|
|
2842
|
+
}, [O(w(it), {
|
|
2843
2843
|
size: 14,
|
|
2844
2844
|
"stroke-width": 2
|
|
2845
|
-
})], 8,
|
|
2845
|
+
})], 8, hs)])]), g("div", gs, [d.value ? (e(), S(Hi, {
|
|
2846
2846
|
key: 0,
|
|
2847
2847
|
block: t.block,
|
|
2848
2848
|
onUpdateFieldValues: a[2] ||= (e) => o("update", { fieldValues: e }),
|
|
2849
2849
|
onUpdateDataSourceFetched: a[3] ||= (e) => o("update", { dataSourceFetched: e })
|
|
2850
|
-
}, null, 8, ["block"])) : u.value === "section" ? (e(), S(
|
|
2850
|
+
}, null, 8, ["block"])) : u.value === "section" ? (e(), S(ja, {
|
|
2851
2851
|
key: 1,
|
|
2852
2852
|
block: t.block,
|
|
2853
2853
|
onUpdate: b
|
|
2854
|
-
}, null, 8, ["block"])) : u.value === "title" ? (e(), S(
|
|
2854
|
+
}, null, 8, ["block"])) : u.value === "title" ? (e(), S(Jo, {
|
|
2855
2855
|
key: 2,
|
|
2856
2856
|
block: t.block,
|
|
2857
2857
|
"font-families": w(m),
|
|
2858
2858
|
onUpdate: b
|
|
2859
|
-
}, null, 8, ["block", "font-families"])) : u.value === "paragraph" ? (e(), _(v, { key: 3 }, [], 64)) : u.value === "image" ? (e(), S(
|
|
2859
|
+
}, null, 8, ["block", "font-families"])) : u.value === "paragraph" ? (e(), _(v, { key: 3 }, [], 64)) : u.value === "image" ? (e(), S(pa, {
|
|
2860
2860
|
key: 4,
|
|
2861
2861
|
block: t.block,
|
|
2862
2862
|
onUpdate: b
|
|
2863
|
-
}, null, 8, ["block"])) : u.value === "video" ? (e(), S(
|
|
2863
|
+
}, null, 8, ["block"])) : u.value === "video" ? (e(), S(cs, {
|
|
2864
2864
|
key: 5,
|
|
2865
2865
|
block: t.block,
|
|
2866
2866
|
onUpdate: b
|
|
2867
|
-
}, null, 8, ["block"])) : u.value === "button" ? (e(), S(
|
|
2867
|
+
}, null, 8, ["block"])) : u.value === "button" ? (e(), S(fr, {
|
|
2868
2868
|
key: 6,
|
|
2869
2869
|
block: t.block,
|
|
2870
2870
|
"font-families": w(m),
|
|
2871
2871
|
onUpdate: b
|
|
2872
|
-
}, null, 8, ["block", "font-families"])) : u.value === "divider" ? (e(), S(
|
|
2872
|
+
}, null, 8, ["block", "font-families"])) : u.value === "divider" ? (e(), S(Ji, {
|
|
2873
2873
|
key: 7,
|
|
2874
2874
|
block: t.block,
|
|
2875
2875
|
onUpdate: b
|
|
2876
|
-
}, null, 8, ["block"])) : u.value === "social" ? (e(), S(
|
|
2876
|
+
}, null, 8, ["block"])) : u.value === "social" ? (e(), S(Xa, {
|
|
2877
2877
|
key: 8,
|
|
2878
2878
|
block: t.block,
|
|
2879
2879
|
onUpdate: b
|
|
2880
|
-
}, null, 8, ["block"])) : u.value === "menu" ? (e(), S(
|
|
2880
|
+
}, null, 8, ["block"])) : u.value === "menu" ? (e(), S(Ta, {
|
|
2881
2881
|
key: 9,
|
|
2882
2882
|
block: t.block,
|
|
2883
2883
|
"font-families": w(m),
|
|
2884
2884
|
onUpdate: b
|
|
2885
|
-
}, null, 8, ["block", "font-families"])) : u.value === "table" ? (e(), S(
|
|
2885
|
+
}, null, 8, ["block", "font-families"])) : u.value === "table" ? (e(), S(Fo, {
|
|
2886
2886
|
key: 10,
|
|
2887
2887
|
block: t.block,
|
|
2888
2888
|
"font-families": w(m),
|
|
2889
2889
|
onUpdate: b
|
|
2890
|
-
}, null, 8, ["block", "font-families"])) : u.value === "spacer" ? (e(), S(
|
|
2890
|
+
}, null, 8, ["block", "font-families"])) : u.value === "spacer" ? (e(), S(to, {
|
|
2891
2891
|
key: 11,
|
|
2892
2892
|
block: t.block,
|
|
2893
2893
|
onUpdate: b
|
|
2894
|
-
}, null, 8, ["block"])) : u.value === "html" ? (e(), S(
|
|
2894
|
+
}, null, 8, ["block"])) : u.value === "html" ? (e(), S(Qi, {
|
|
2895
2895
|
key: 12,
|
|
2896
2896
|
block: t.block,
|
|
2897
2897
|
onUpdate: b
|
|
@@ -2900,52 +2900,52 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2900
2900
|
block: t.block,
|
|
2901
2901
|
"font-families": w(m),
|
|
2902
2902
|
onUpdate: b
|
|
2903
|
-
}, null, 8, ["block", "font-families"])) : y("", !0), O(
|
|
2903
|
+
}, null, 8, ["block", "font-families"])) : y("", !0), O(ii, {
|
|
2904
2904
|
block: t.block,
|
|
2905
2905
|
"is-first-section": u.value === "paragraph",
|
|
2906
2906
|
onUpdate: b
|
|
2907
|
-
}, null, 8, ["block", "is-first-section"])])], 8,
|
|
2907
|
+
}, null, 8, ["block", "is-first-section"])])], 8, ls));
|
|
2908
2908
|
}
|
|
2909
|
-
}), [["__scopeId", "data-v-2ac88283"]]),
|
|
2909
|
+
}), [["__scopeId", "data-v-2ac88283"]]), vs = ["aria-label"], ys = {
|
|
2910
2910
|
role: "tablist",
|
|
2911
2911
|
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"
|
|
2912
|
-
},
|
|
2912
|
+
}, bs = [
|
|
2913
2913
|
"aria-selected",
|
|
2914
2914
|
"aria-label",
|
|
2915
2915
|
"title"
|
|
2916
|
-
],
|
|
2916
|
+
], xs = { key: 0 }, Ss = [
|
|
2917
2917
|
"aria-selected",
|
|
2918
2918
|
"aria-label",
|
|
2919
2919
|
"title"
|
|
2920
|
-
],
|
|
2920
|
+
], Cs = { key: 0 }, ws = [
|
|
2921
2921
|
"aria-selected",
|
|
2922
2922
|
"aria-label",
|
|
2923
2923
|
"title"
|
|
2924
|
-
],
|
|
2924
|
+
], Ts = { key: 0 }, Es = {
|
|
2925
2925
|
key: 1,
|
|
2926
2926
|
class: "tpl:ml-1 tpl:rounded-full tpl:bg-[var(--tpl-bg-hover)] tpl:px-1.5 tpl:text-[10px]"
|
|
2927
|
-
},
|
|
2927
|
+
}, Ds = {
|
|
2928
2928
|
key: 0,
|
|
2929
2929
|
id: "tpl-tabpanel-content",
|
|
2930
2930
|
role: "tabpanel",
|
|
2931
2931
|
"aria-labelledby": "tpl-tab-content",
|
|
2932
2932
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2933
|
-
},
|
|
2933
|
+
}, Os = {
|
|
2934
2934
|
key: 1,
|
|
2935
2935
|
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)]"
|
|
2936
|
-
},
|
|
2936
|
+
}, ks = { class: "tpl:mb-4 tpl:text-[var(--tpl-text-dim)]" }, As = { class: "tpl:m-0 tpl:mb-2 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]" }, js = { class: "tpl:m-0 tpl:text-sm tpl:leading-normal" }, Ms = {
|
|
2937
2937
|
key: 1,
|
|
2938
2938
|
id: "tpl-tabpanel-settings",
|
|
2939
2939
|
role: "tabpanel",
|
|
2940
2940
|
"aria-labelledby": "tpl-tab-settings",
|
|
2941
2941
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2942
|
-
},
|
|
2942
|
+
}, Ns = {
|
|
2943
2943
|
key: 2,
|
|
2944
2944
|
id: "tpl-tabpanel-issues",
|
|
2945
2945
|
role: "tabpanel",
|
|
2946
2946
|
"aria-labelledby": "tpl-tab-issues",
|
|
2947
2947
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-y-auto"
|
|
2948
|
-
},
|
|
2948
|
+
}, Ps = /* @__PURE__ */ p({
|
|
2949
2949
|
__name: "RightSidebar",
|
|
2950
2950
|
props: {
|
|
2951
2951
|
selectedBlock: {},
|
|
@@ -2959,7 +2959,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2959
2959
|
"update-settings"
|
|
2960
2960
|
],
|
|
2961
2961
|
setup(t, { emit: n }) {
|
|
2962
|
-
let r = A(() => import("./IssuesPanel-B1LT91IX.js")), i = t, o = n, { t: s } = V(), c = l("content"), u = k(
|
|
2962
|
+
let r = A(() => import("./IssuesPanel-B1LT91IX.js")), i = t, o = n, { t: s } = V(), c = l("content"), u = k(De, null), d = h(() => u !== null), p = h(() => u?.issues.value.length ?? 0);
|
|
2963
2963
|
function m(e) {
|
|
2964
2964
|
return c.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)]";
|
|
2965
2965
|
}
|
|
@@ -2975,7 +2975,7 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2975
2975
|
"aria-label": w(s).landmarks.rightSidebar,
|
|
2976
2976
|
class: f(["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"])
|
|
2977
2977
|
}, [
|
|
2978
|
-
g("div",
|
|
2978
|
+
g("div", ys, [
|
|
2979
2979
|
g("button", {
|
|
2980
2980
|
id: "tpl-tab-content",
|
|
2981
2981
|
role: "tab",
|
|
@@ -2986,10 +2986,10 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
2986
2986
|
class: f(["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)]", m("content")]),
|
|
2987
2987
|
style: x(v("content")),
|
|
2988
2988
|
onClick: i[0] ||= (e) => c.value = "content"
|
|
2989
|
-
}, [O(w(
|
|
2989
|
+
}, [O(w(Et), {
|
|
2990
2990
|
size: 14,
|
|
2991
2991
|
"stroke-width": 2
|
|
2992
|
-
}), c.value === "content" ? (e(), _("span",
|
|
2992
|
+
}), c.value === "content" ? (e(), _("span", xs, E(w(s).sidebar.content), 1)) : y("", !0)], 14, bs),
|
|
2993
2993
|
g("button", {
|
|
2994
2994
|
id: "tpl-tab-settings",
|
|
2995
2995
|
role: "tab",
|
|
@@ -3000,10 +3000,10 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3000
3000
|
class: f(["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)]", m("settings")]),
|
|
3001
3001
|
style: x(v("settings")),
|
|
3002
3002
|
onClick: i[1] ||= (e) => c.value = "settings"
|
|
3003
|
-
}, [O(w(
|
|
3003
|
+
}, [O(w(Ot), {
|
|
3004
3004
|
size: 14,
|
|
3005
3005
|
"stroke-width": 1.5
|
|
3006
|
-
}), c.value === "settings" ? (e(), _("span",
|
|
3006
|
+
}), c.value === "settings" ? (e(), _("span", Cs, E(w(s).sidebar.settings), 1)) : y("", !0)], 14, Ss),
|
|
3007
3007
|
d.value ? (e(), _("button", {
|
|
3008
3008
|
key: 0,
|
|
3009
3009
|
id: "tpl-tab-issues",
|
|
@@ -3016,41 +3016,41 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3016
3016
|
style: x(v("issues")),
|
|
3017
3017
|
onClick: i[2] ||= (e) => c.value = "issues"
|
|
3018
3018
|
}, [
|
|
3019
|
-
O(w(
|
|
3019
|
+
O(w(Qe), {
|
|
3020
3020
|
size: 14,
|
|
3021
3021
|
"stroke-width": 1.5
|
|
3022
3022
|
}),
|
|
3023
|
-
c.value === "issues" ? (e(), _("span",
|
|
3024
|
-
p.value > 0 ? (e(), _("span",
|
|
3025
|
-
], 14,
|
|
3023
|
+
c.value === "issues" ? (e(), _("span", Ts, E(w(s).issues.panelTabLabel), 1)) : y("", !0),
|
|
3024
|
+
p.value > 0 ? (e(), _("span", Es, E(p.value), 1)) : y("", !0)
|
|
3025
|
+
], 14, ws)) : y("", !0)
|
|
3026
3026
|
]),
|
|
3027
|
-
c.value === "content" ? (e(), _("div",
|
|
3027
|
+
c.value === "content" ? (e(), _("div", Ds, [t.selectedBlock ? (e(), S(_s, {
|
|
3028
3028
|
key: 0,
|
|
3029
3029
|
block: t.selectedBlock,
|
|
3030
3030
|
onUpdate: i[3] ||= (e) => o("update-block", e),
|
|
3031
3031
|
onDelete: i[4] ||= (e) => o("delete-block"),
|
|
3032
3032
|
onDuplicate: i[5] ||= (e) => o("duplicate-block")
|
|
3033
|
-
}, null, 8, ["block"])) : (e(), _("div",
|
|
3034
|
-
g("div",
|
|
3033
|
+
}, null, 8, ["block"])) : (e(), _("div", Os, [
|
|
3034
|
+
g("div", ks, [O(w(xt), {
|
|
3035
3035
|
size: 40,
|
|
3036
3036
|
"stroke-width": 1.5
|
|
3037
3037
|
})]),
|
|
3038
|
-
g("h3",
|
|
3039
|
-
g("p",
|
|
3038
|
+
g("h3", As, E(w(s).sidebar.noSelection), 1),
|
|
3039
|
+
g("p", js, E(w(s).sidebar.noSelectionHint), 1)
|
|
3040
3040
|
]))])) : y("", !0),
|
|
3041
|
-
c.value === "settings" ? (e(), _("div",
|
|
3041
|
+
c.value === "settings" ? (e(), _("div", Ms, [O(Un, {
|
|
3042
3042
|
settings: t.settings,
|
|
3043
3043
|
onUpdate: i[6] ||= (e) => o("update-settings", e)
|
|
3044
3044
|
}, null, 8, ["settings"])])) : y("", !0),
|
|
3045
|
-
c.value === "issues" && d.value ? (e(), _("div",
|
|
3046
|
-
], 10,
|
|
3045
|
+
c.value === "issues" && d.value ? (e(), _("div", Ns, [O(w(r))])) : y("", !0)
|
|
3046
|
+
], 10, vs));
|
|
3047
3047
|
}
|
|
3048
|
-
}),
|
|
3048
|
+
}), Fs = ["aria-label"], Is = [
|
|
3049
3049
|
"aria-checked",
|
|
3050
3050
|
"aria-label",
|
|
3051
3051
|
"title",
|
|
3052
3052
|
"onClick"
|
|
3053
|
-
],
|
|
3053
|
+
], Ls = /* @__PURE__ */ p({
|
|
3054
3054
|
__name: "ViewportToggle",
|
|
3055
3055
|
props: { viewport: {} },
|
|
3056
3056
|
emits: ["change"],
|
|
@@ -3099,25 +3099,25 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3099
3099
|
}),
|
|
3100
3100
|
title: n.label,
|
|
3101
3101
|
onClick: (e) => i("change", n.value)
|
|
3102
|
-
}, [n.value === "desktop" ? (e(), S(w(
|
|
3102
|
+
}, [n.value === "desktop" ? (e(), S(w(wt), {
|
|
3103
3103
|
key: 0,
|
|
3104
3104
|
size: 18,
|
|
3105
3105
|
"stroke-width": 1.5
|
|
3106
|
-
})) : n.value === "tablet" ? (e(), S(w(
|
|
3106
|
+
})) : n.value === "tablet" ? (e(), S(w(Nt), {
|
|
3107
3107
|
key: 1,
|
|
3108
3108
|
size: 18,
|
|
3109
3109
|
"stroke-width": 1.5
|
|
3110
|
-
})) : (e(), S(w(
|
|
3110
|
+
})) : (e(), S(w(kt), {
|
|
3111
3111
|
key: 2,
|
|
3112
3112
|
size: 18,
|
|
3113
3113
|
"stroke-width": 1.5
|
|
3114
|
-
})), g("span", null, E(n.label), 1)], 12,
|
|
3114
|
+
})), g("span", null, E(n.label), 1)], 12, Is))), 128))], 12, Fs));
|
|
3115
3115
|
}
|
|
3116
|
-
}),
|
|
3116
|
+
}), Rs = [
|
|
3117
3117
|
"aria-label",
|
|
3118
3118
|
"title",
|
|
3119
3119
|
"aria-pressed"
|
|
3120
|
-
],
|
|
3120
|
+
], zs = /* @__PURE__ */ ot(/* @__PURE__ */ p({
|
|
3121
3121
|
__name: "PreviewToggle",
|
|
3122
3122
|
props: { previewMode: { type: Boolean } },
|
|
3123
3123
|
emits: ["change"],
|
|
@@ -3140,23 +3140,23 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3140
3140
|
"leave-to-class": "tpl-icon-leave-to",
|
|
3141
3141
|
mode: "out-in"
|
|
3142
3142
|
}, {
|
|
3143
|
-
default: j(() => [t.previewMode ? (e(), S(w(
|
|
3143
|
+
default: j(() => [t.previewMode ? (e(), S(w(Je), {
|
|
3144
3144
|
key: "eye",
|
|
3145
3145
|
size: 18,
|
|
3146
3146
|
"stroke-width": 1.5
|
|
3147
|
-
})) : (e(), S(w(
|
|
3147
|
+
})) : (e(), S(w(R), {
|
|
3148
3148
|
key: "eye-off",
|
|
3149
3149
|
size: 18,
|
|
3150
3150
|
"stroke-width": 1.5
|
|
3151
3151
|
}))]),
|
|
3152
3152
|
_: 1
|
|
3153
|
-
})], 12,
|
|
3153
|
+
})], 12, Rs));
|
|
3154
3154
|
}
|
|
3155
|
-
}), [["__scopeId", "data-v-af87d02a"]]),
|
|
3155
|
+
}), [["__scopeId", "data-v-af87d02a"]]), Bs = [
|
|
3156
3156
|
"aria-label",
|
|
3157
3157
|
"title",
|
|
3158
3158
|
"aria-pressed"
|
|
3159
|
-
],
|
|
3159
|
+
], Vs = /* @__PURE__ */ ot(/* @__PURE__ */ p({
|
|
3160
3160
|
__name: "DarkModeToggle",
|
|
3161
3161
|
props: { darkMode: { type: Boolean } },
|
|
3162
3162
|
emits: ["change"],
|
|
@@ -3179,37 +3179,37 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3179
3179
|
"leave-to-class": "tpl-icon-leave-to",
|
|
3180
3180
|
mode: "out-in"
|
|
3181
3181
|
}, {
|
|
3182
|
-
default: j(() => [t.darkMode ? (e(), S(w(
|
|
3182
|
+
default: j(() => [t.darkMode ? (e(), S(w(Tt), {
|
|
3183
3183
|
key: "moon",
|
|
3184
3184
|
size: 18,
|
|
3185
3185
|
"stroke-width": 1.5
|
|
3186
|
-
})) : (e(), S(w(
|
|
3186
|
+
})) : (e(), S(w(Mt), {
|
|
3187
3187
|
key: "sun",
|
|
3188
3188
|
size: 18,
|
|
3189
3189
|
"stroke-width": 1.5
|
|
3190
3190
|
}))]),
|
|
3191
3191
|
_: 1
|
|
3192
|
-
})], 12,
|
|
3192
|
+
})], 12, Bs));
|
|
3193
3193
|
}
|
|
3194
|
-
}), [["__scopeId", "data-v-f8694f76"]]),
|
|
3194
|
+
}), [["__scopeId", "data-v-f8694f76"]]), Hs = {
|
|
3195
3195
|
class: "tpl:pointer-events-auto tpl:flex tpl:items-center tpl:gap-1.5 tpl:rounded-tl-lg tpl:p-1",
|
|
3196
3196
|
style: {
|
|
3197
3197
|
"background-color": "color-mix(\n in srgb,\n var(--tpl-canvas-bg) 85%,\n transparent\n )",
|
|
3198
3198
|
"backdrop-filter": "blur(8px)",
|
|
3199
3199
|
"-webkit-backdrop-filter": "blur(8px)"
|
|
3200
3200
|
}
|
|
3201
|
-
},
|
|
3201
|
+
}, Us = {
|
|
3202
3202
|
href: "https://github.com/templatical/sdk",
|
|
3203
3203
|
target: "_blank",
|
|
3204
3204
|
rel: "noopener noreferrer",
|
|
3205
3205
|
class: "tpl:transition-colors tpl:duration-150 hover:tpl:opacity-80 tpl:text-[var(--tpl-text-dim)]",
|
|
3206
3206
|
style: { "text-decoration": "none" }
|
|
3207
|
-
},
|
|
3207
|
+
}, Ws = /* @__PURE__ */ p({
|
|
3208
3208
|
__name: "EditorFooter",
|
|
3209
3209
|
props: { positionClass: {} },
|
|
3210
3210
|
setup(t) {
|
|
3211
3211
|
let { t: n } = V();
|
|
3212
|
-
return (r, i) => (e(), _("footer", { class: f(["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]) }, [g("div",
|
|
3212
|
+
return (r, i) => (e(), _("footer", { class: f(["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]) }, [g("div", Hs, [
|
|
3213
3213
|
g("span", null, E(w(n).footer.poweredBy), 1),
|
|
3214
3214
|
i[0] ||= g("a", {
|
|
3215
3215
|
href: "https://templatical.com",
|
|
@@ -3224,32 +3224,32 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3224
3224
|
alt: ""
|
|
3225
3225
|
}), u(" Templatical ")], -1),
|
|
3226
3226
|
i[1] ||= g("span", { class: "tpl:text-[var(--tpl-border)]" }, "·", -1),
|
|
3227
|
-
g("a",
|
|
3227
|
+
g("a", Us, E(w(n).footer.openSource), 1)
|
|
3228
3228
|
])], 2));
|
|
3229
3229
|
}
|
|
3230
|
-
}),
|
|
3230
|
+
}), Gs = ["aria-labelledby", "data-tpl-theme"], Ks = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:gap-3 tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-3 tpl:py-2.5" }, qs = ["id"], Js = ["aria-label"], Ys = { class: "tpl:relative tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-3 tpl:py-2.5" }, Xs = [
|
|
3231
3231
|
"id",
|
|
3232
3232
|
"placeholder",
|
|
3233
3233
|
"aria-label",
|
|
3234
3234
|
"aria-activedescendant"
|
|
3235
|
-
],
|
|
3235
|
+
], Zs = {
|
|
3236
3236
|
key: 0,
|
|
3237
3237
|
class: "tpl:flex tpl:gap-1.5 tpl:overflow-x-auto tpl:border-b tpl:border-[var(--tpl-border)] tpl:px-3 tpl:py-2",
|
|
3238
3238
|
"data-testid": "merge-tag-picker-group-pills"
|
|
3239
|
-
},
|
|
3239
|
+
}, Qs = ["data-group-name", "onClick"], $s = ["aria-label"], ec = {
|
|
3240
3240
|
key: 0,
|
|
3241
3241
|
class: "tpl:px-3 tpl:py-6 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]",
|
|
3242
3242
|
"data-testid": "merge-tag-picker-empty"
|
|
3243
|
-
},
|
|
3243
|
+
}, tc = {
|
|
3244
3244
|
key: 1,
|
|
3245
3245
|
class: "tpl:px-3 tpl:py-6 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]",
|
|
3246
3246
|
"data-testid": "merge-tag-picker-empty"
|
|
3247
|
-
},
|
|
3247
|
+
}, nc = [
|
|
3248
3248
|
"aria-expanded",
|
|
3249
3249
|
"data-group-name",
|
|
3250
3250
|
"data-group-collapsed",
|
|
3251
3251
|
"onClick"
|
|
3252
|
-
],
|
|
3252
|
+
], rc = { class: "tpl:ml-1 tpl:font-normal" }, ic = [
|
|
3253
3253
|
"id",
|
|
3254
3254
|
"aria-selected",
|
|
3255
3255
|
"data-selected",
|
|
@@ -3258,38 +3258,38 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3258
3258
|
"title",
|
|
3259
3259
|
"onMousemove",
|
|
3260
3260
|
"onClick"
|
|
3261
|
-
],
|
|
3261
|
+
], ac = { class: "tpl:text-sm tpl:font-medium" }, oc = { class: "tpl:line-clamp-2 tpl:font-mono tpl:text-xs tpl:text-ellipsis tpl:break-all tpl:text-[var(--tpl-text-dim)]" }, sc = {
|
|
3262
3262
|
key: 0,
|
|
3263
3263
|
class: "tpl:line-clamp-2 tpl:text-xs tpl:text-ellipsis tpl:text-[var(--tpl-text-dim)]"
|
|
3264
|
-
}, $ = "tpl-merge-tag-picker-list",
|
|
3264
|
+
}, $ = "tpl-merge-tag-picker-list", cc = /* @__PURE__ */ p({
|
|
3265
3265
|
__name: "MergeTagPickerModal",
|
|
3266
3266
|
setup(r) {
|
|
3267
|
-
let i =
|
|
3268
|
-
function
|
|
3269
|
-
return
|
|
3267
|
+
let i = Fe(je, "MergeTagPickerModal"), { t: s, format: c } = V(), u = k(Oe, null), p = k(Ee, null), b = l(""), C = we(b, 200), D = l(null), A = h(() => C.value.trim().length > 0), M = l(0), N = h(() => i.tags.value.some((e) => !!e.group)), P = l(/* @__PURE__ */ new Set());
|
|
3268
|
+
function F(e) {
|
|
3269
|
+
return P.value.has(e);
|
|
3270
3270
|
}
|
|
3271
|
-
function
|
|
3272
|
-
let t = new Set(
|
|
3273
|
-
t.has(e) ? t.delete(e) : t.add(e),
|
|
3271
|
+
function I(e) {
|
|
3272
|
+
let t = new Set(P.value);
|
|
3273
|
+
t.has(e) ? t.delete(e) : t.add(e), P.value = t, M.value = 0;
|
|
3274
3274
|
}
|
|
3275
|
-
let
|
|
3276
|
-
let e =
|
|
3275
|
+
let L = h(() => {
|
|
3276
|
+
let e = C.value.trim().toLowerCase();
|
|
3277
3277
|
return e ? i.tags.value.filter((t) => [
|
|
3278
3278
|
t.label,
|
|
3279
3279
|
t.value,
|
|
3280
3280
|
t.description ?? ""
|
|
3281
3281
|
].join(" ").toLowerCase().includes(e)) : i.tags.value;
|
|
3282
|
-
}),
|
|
3283
|
-
if (!
|
|
3282
|
+
}), ee = h(() => {
|
|
3283
|
+
if (!N.value) return [];
|
|
3284
3284
|
let e = s.mergeTag.picker.otherGroup, t = /* @__PURE__ */ new Set(), n = [];
|
|
3285
3285
|
for (let r of i.tags.value) {
|
|
3286
3286
|
let i = r.group ?? e;
|
|
3287
3287
|
t.has(i) || (t.add(i), n.push(i));
|
|
3288
3288
|
}
|
|
3289
3289
|
return n;
|
|
3290
|
-
}),
|
|
3291
|
-
let e =
|
|
3292
|
-
if (!
|
|
3290
|
+
}), te = h(() => {
|
|
3291
|
+
let e = L.value;
|
|
3292
|
+
if (!N.value || A.value) return e.map((e, t) => ({
|
|
3293
3293
|
kind: "tag",
|
|
3294
3294
|
tag: e,
|
|
3295
3295
|
index: t
|
|
@@ -3306,49 +3306,49 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3306
3306
|
kind: "header",
|
|
3307
3307
|
group: e,
|
|
3308
3308
|
count: t.length
|
|
3309
|
-
}), !
|
|
3309
|
+
}), !P.value.has(e)) for (let e of t) i.push({
|
|
3310
3310
|
kind: "tag",
|
|
3311
3311
|
tag: e,
|
|
3312
3312
|
index: a
|
|
3313
3313
|
}), a++;
|
|
3314
3314
|
}
|
|
3315
3315
|
return i;
|
|
3316
|
-
}),
|
|
3316
|
+
}), R = h(() => te.value.flatMap((e) => e.kind === "tag" ? [e.tag] : []));
|
|
3317
3317
|
a(() => i.isOpen.value, (e) => {
|
|
3318
|
-
e && (
|
|
3319
|
-
|
|
3318
|
+
e && (b.value = "", M.value = 0, P.value = /* @__PURE__ */ new Set(), n(() => {
|
|
3319
|
+
D.value?.focus();
|
|
3320
3320
|
}));
|
|
3321
|
-
}), a(
|
|
3322
|
-
|
|
3321
|
+
}), a(R, (e) => {
|
|
3322
|
+
M.value >= e.length && (M.value = Math.max(0, e.length - 1));
|
|
3323
3323
|
});
|
|
3324
|
-
function
|
|
3324
|
+
function z(e) {
|
|
3325
3325
|
i.resolve(e);
|
|
3326
3326
|
}
|
|
3327
|
-
function
|
|
3327
|
+
function ne() {
|
|
3328
3328
|
i.resolve(null);
|
|
3329
3329
|
}
|
|
3330
|
-
function
|
|
3331
|
-
if (
|
|
3332
|
-
let t =
|
|
3333
|
-
|
|
3330
|
+
function re(e) {
|
|
3331
|
+
if (R.value.length === 0) return;
|
|
3332
|
+
let t = M.value + e;
|
|
3333
|
+
M.value = Math.max(0, Math.min(R.value.length - 1, t)), oe();
|
|
3334
3334
|
}
|
|
3335
|
-
let
|
|
3336
|
-
function
|
|
3337
|
-
|
|
3335
|
+
let ie = l(null), B = l({});
|
|
3336
|
+
function ae(e, t) {
|
|
3337
|
+
B.value[e] = t ?? null;
|
|
3338
3338
|
}
|
|
3339
|
-
function
|
|
3339
|
+
function oe() {
|
|
3340
3340
|
n(() => {
|
|
3341
|
-
let e =
|
|
3342
|
-
e && e.querySelector(`[data-merge-tag-index="${
|
|
3341
|
+
let e = ie.value;
|
|
3342
|
+
e && e.querySelector(`[data-merge-tag-index="${M.value}"]`)?.scrollIntoView({ block: "nearest" });
|
|
3343
3343
|
});
|
|
3344
3344
|
}
|
|
3345
|
-
function
|
|
3346
|
-
if (
|
|
3347
|
-
let t = new Set(
|
|
3348
|
-
t.delete(e),
|
|
3345
|
+
function se(e) {
|
|
3346
|
+
if (P.value.has(e)) {
|
|
3347
|
+
let t = new Set(P.value);
|
|
3348
|
+
t.delete(e), P.value = t;
|
|
3349
3349
|
}
|
|
3350
3350
|
n(() => {
|
|
3351
|
-
let t =
|
|
3351
|
+
let t = ie.value;
|
|
3352
3352
|
if (!t) return;
|
|
3353
3353
|
let n = 0, r = !1;
|
|
3354
3354
|
for (let i of Array.from(t.children)) {
|
|
@@ -3364,124 +3364,126 @@ var Ea = { class: "tpl:mb-3.5" }, Da = ["value"], Oa = ["value"], ka = /* @__PUR
|
|
|
3364
3364
|
});
|
|
3365
3365
|
});
|
|
3366
3366
|
}
|
|
3367
|
-
function
|
|
3368
|
-
if (e.key === "ArrowDown") e.preventDefault(),
|
|
3369
|
-
else if (e.key === "ArrowUp") e.preventDefault(),
|
|
3367
|
+
function ce(e) {
|
|
3368
|
+
if (e.key === "ArrowDown") e.preventDefault(), re(1);
|
|
3369
|
+
else if (e.key === "ArrowUp") e.preventDefault(), re(-1);
|
|
3370
3370
|
else if (e.key === "Enter") {
|
|
3371
3371
|
e.preventDefault();
|
|
3372
|
-
let t =
|
|
3373
|
-
t &&
|
|
3372
|
+
let t = R.value[M.value];
|
|
3373
|
+
t && z(t);
|
|
3374
3374
|
}
|
|
3375
3375
|
}
|
|
3376
|
-
function
|
|
3377
|
-
if (
|
|
3376
|
+
function le() {
|
|
3377
|
+
if (R.value.length !== 0) return `${$}-opt-${M.value}`;
|
|
3378
3378
|
}
|
|
3379
|
-
function
|
|
3379
|
+
function ue(e) {
|
|
3380
3380
|
return `${$}-opt-${e}`;
|
|
3381
3381
|
}
|
|
3382
|
-
let
|
|
3383
|
-
return (n, r) => (e(), S(
|
|
3382
|
+
let de = h(() => i.tags.value.length === 0), fe = h(() => !de.value && L.value.length === 0), pe = h(() => N.value && ee.value.length > 1 && !A.value);
|
|
3383
|
+
return (n, r) => (e(), S(vt, {
|
|
3384
3384
|
visible: w(i).isOpen.value,
|
|
3385
|
-
onClose:
|
|
3386
|
-
onKeydown:
|
|
3385
|
+
onClose: ne,
|
|
3386
|
+
onKeydown: ce
|
|
3387
3387
|
}, {
|
|
3388
3388
|
default: j(() => [g("div", {
|
|
3389
3389
|
role: "dialog",
|
|
3390
3390
|
"aria-modal": "true",
|
|
3391
3391
|
"aria-labelledby": `${$}-title`,
|
|
3392
|
+
"data-tpl-theme": w(p),
|
|
3392
3393
|
"data-testid": "merge-tag-picker-modal",
|
|
3393
|
-
class: "tpl tpl:flex tpl:max-h-[80vh] tpl:w-[min(420px,92vw)] tpl:flex-col tpl:rounded-[var(--tpl-radius)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-elevated)] tpl:shadow-[var(--tpl-shadow-lg)]"
|
|
3394
|
+
class: "tpl tpl:flex tpl:max-h-[80vh] tpl:w-[min(420px,92vw)] tpl:flex-col tpl:rounded-[var(--tpl-radius)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg-elevated)] tpl:shadow-[var(--tpl-shadow-lg)]",
|
|
3395
|
+
style: x(w(u))
|
|
3394
3396
|
}, [
|
|
3395
|
-
g("header",
|
|
3397
|
+
g("header", Ks, [g("h2", {
|
|
3396
3398
|
id: `${$}-title`,
|
|
3397
3399
|
class: "tpl:m-0 tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]"
|
|
3398
|
-
}, E(w(s).mergeTag.picker.title), 9,
|
|
3400
|
+
}, E(w(s).mergeTag.picker.title), 9, qs), g("button", {
|
|
3399
3401
|
type: "button",
|
|
3400
3402
|
class: "tpl:flex tpl:h-7 tpl:w-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)] tpl:border-none tpl:bg-transparent tpl:text-[var(--tpl-text-dim)] tpl:transition-colors tpl:hover:bg-[var(--tpl-bg-hover)] tpl:hover:text-[var(--tpl-text)]",
|
|
3401
3403
|
"aria-label": w(s).mergeTag.picker.close,
|
|
3402
3404
|
"data-testid": "merge-tag-picker-close",
|
|
3403
|
-
onClick:
|
|
3404
|
-
}, [O(w(
|
|
3405
|
+
onClick: ne
|
|
3406
|
+
}, [O(w(at), {
|
|
3405
3407
|
size: 16,
|
|
3406
3408
|
"stroke-width": 2
|
|
3407
|
-
})], 8,
|
|
3408
|
-
g("div",
|
|
3409
|
+
})], 8, Js)]),
|
|
3410
|
+
g("div", Ys, [O(w(Ge), {
|
|
3409
3411
|
class: "tpl:pointer-events-none tpl:absolute tpl:top-1/2 tpl:left-5 tpl:-translate-y-1/2 tpl:text-[var(--tpl-text-dim)]",
|
|
3410
3412
|
size: 14,
|
|
3411
3413
|
"stroke-width": 2
|
|
3412
3414
|
}), t(g("input", {
|
|
3413
3415
|
id: `${$}-search`,
|
|
3414
3416
|
ref_key: "searchInputRef",
|
|
3415
|
-
ref:
|
|
3416
|
-
"onUpdate:modelValue": r[0] ||= (e) =>
|
|
3417
|
+
ref: D,
|
|
3418
|
+
"onUpdate:modelValue": r[0] ||= (e) => b.value = e,
|
|
3417
3419
|
type: "text",
|
|
3418
3420
|
class: "tpl:w-full tpl:rounded-[var(--tpl-radius-sm)] tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:py-1.5 tpl:pr-3 tpl:pl-8 tpl:text-sm tpl:text-[var(--tpl-text)] tpl:outline-none tpl:focus:border-[var(--tpl-primary)]",
|
|
3419
3421
|
placeholder: w(s).mergeTag.picker.searchPlaceholder,
|
|
3420
3422
|
"aria-label": w(s).mergeTag.picker.searchAriaLabel,
|
|
3421
3423
|
"aria-controls": $,
|
|
3422
|
-
"aria-activedescendant":
|
|
3424
|
+
"aria-activedescendant": le(),
|
|
3423
3425
|
"data-testid": "merge-tag-picker-search",
|
|
3424
3426
|
onKeydown: r[1] ||= T(m(() => {}, ["prevent"]), ["enter"])
|
|
3425
|
-
}, null, 40,
|
|
3426
|
-
|
|
3427
|
+
}, null, 40, Xs), [[d, b.value]])]),
|
|
3428
|
+
pe.value ? (e(), _("div", Zs, [(e(!0), _(v, null, o(ee.value, (t) => (e(), _("button", {
|
|
3427
3429
|
key: t,
|
|
3428
3430
|
type: "button",
|
|
3429
3431
|
class: "tpl:flex tpl:flex-shrink-0 tpl:cursor-pointer tpl:items-center tpl:rounded-full tpl:border tpl:border-[var(--tpl-border)] tpl:bg-transparent tpl:px-2.5 tpl:py-0.5 tpl:text-[11px] tpl:font-medium tpl:text-[var(--tpl-text-dim)] tpl:transition-colors tpl:hover:bg-[var(--tpl-bg-hover)] tpl:hover:text-[var(--tpl-text)]",
|
|
3430
3432
|
"data-testid": "merge-tag-picker-group-pill",
|
|
3431
3433
|
"data-group-name": t,
|
|
3432
|
-
onClick: (e) =>
|
|
3433
|
-
}, E(t), 9,
|
|
3434
|
+
onClick: (e) => se(t)
|
|
3435
|
+
}, E(t), 9, Qs))), 128))])) : y("", !0),
|
|
3434
3436
|
g("div", {
|
|
3435
3437
|
id: $,
|
|
3436
3438
|
ref_key: "listRef",
|
|
3437
|
-
ref:
|
|
3439
|
+
ref: ie,
|
|
3438
3440
|
class: "tpl:relative tpl:max-h-[60vh] tpl:flex-1 tpl:overflow-y-auto",
|
|
3439
3441
|
role: "listbox",
|
|
3440
3442
|
"aria-label": w(s).mergeTag.picker.title,
|
|
3441
3443
|
"data-testid": "merge-tag-picker-list"
|
|
3442
|
-
}, [
|
|
3444
|
+
}, [de.value ? (e(), _("div", ec, E(w(s).mergeTag.picker.empty), 1)) : fe.value ? (e(), _("div", tc, E(w(s).mergeTag.picker.noResults), 1)) : (e(!0), _(v, { key: 2 }, o(te.value, (t, n) => (e(), _(v, { key: n }, [t.kind === "header" ? (e(), _("button", {
|
|
3443
3445
|
key: 0,
|
|
3444
3446
|
ref_for: !0,
|
|
3445
|
-
ref: (e) =>
|
|
3447
|
+
ref: (e) => ae(t.group, e),
|
|
3446
3448
|
type: "button",
|
|
3447
|
-
"aria-expanded": !
|
|
3449
|
+
"aria-expanded": !F(t.group),
|
|
3448
3450
|
"aria-controls": $,
|
|
3449
3451
|
class: "tpl:sticky tpl:top-0 tpl:z-10 tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-center tpl:gap-1.5 tpl:border-none tpl:bg-[var(--tpl-bg-elevated)] tpl:px-3 tpl:pt-2.5 tpl:pb-1 tpl:text-left tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text-dim)] tpl:transition-colors tpl:hover:bg-[var(--tpl-bg-hover)]",
|
|
3450
3452
|
"data-testid": "merge-tag-picker-group-header",
|
|
3451
3453
|
"data-group-name": t.group,
|
|
3452
|
-
"data-group-collapsed":
|
|
3453
|
-
onClick: (e) =>
|
|
3454
|
+
"data-group-collapsed": F(t.group) ? "true" : "false",
|
|
3455
|
+
onClick: (e) => I(t.group)
|
|
3454
3456
|
}, [
|
|
3455
|
-
O(w(
|
|
3457
|
+
O(w(He), {
|
|
3456
3458
|
size: 12,
|
|
3457
3459
|
"stroke-width": 2,
|
|
3458
|
-
class: f(["tpl:transition-transform",
|
|
3460
|
+
class: f(["tpl:transition-transform", F(t.group) ? "tpl:-rotate-90" : ""])
|
|
3459
3461
|
}, null, 8, ["class"]),
|
|
3460
3462
|
g("span", null, E(t.group), 1),
|
|
3461
|
-
g("span",
|
|
3462
|
-
], 8,
|
|
3463
|
+
g("span", rc, " (" + E(w(c)(w(s).mergeTag.picker.groupCount, { count: t.count })) + ") ", 1)
|
|
3464
|
+
], 8, nc)) : (e(), _("button", {
|
|
3463
3465
|
key: 1,
|
|
3464
|
-
id:
|
|
3466
|
+
id: ue(t.index),
|
|
3465
3467
|
type: "button",
|
|
3466
3468
|
role: "option",
|
|
3467
|
-
"aria-selected": t.index ===
|
|
3468
|
-
"data-selected": t.index ===
|
|
3469
|
+
"aria-selected": t.index === M.value,
|
|
3470
|
+
"data-selected": t.index === M.value ? "true" : "false",
|
|
3469
3471
|
"data-merge-tag-index": t.index,
|
|
3470
3472
|
"data-merge-tag-value": t.tag.value,
|
|
3471
3473
|
title: t.tag.description ? `${t.tag.value} — ${t.tag.description}` : t.tag.value,
|
|
3472
|
-
class: f(["tpl:flex tpl:w-full tpl:cursor-pointer tpl:flex-col tpl:items-start tpl:gap-0.5 tpl:border-none tpl:px-3 tpl:py-1.5 tpl:text-left tpl:transition-colors", t.index ===
|
|
3474
|
+
class: f(["tpl:flex tpl:w-full tpl:cursor-pointer tpl:flex-col tpl:items-start tpl:gap-0.5 tpl:border-none tpl:px-3 tpl:py-1.5 tpl:text-left tpl:transition-colors", t.index === M.value ? "tpl:bg-[var(--tpl-primary-light)] tpl:text-[var(--tpl-primary)]" : "tpl:bg-transparent tpl:text-[var(--tpl-text)] tpl:hover:bg-[var(--tpl-bg-hover)]"]),
|
|
3473
3475
|
"data-testid": "merge-tag-picker-item",
|
|
3474
|
-
onMousemove: (e) =>
|
|
3475
|
-
onClick: (e) =>
|
|
3476
|
+
onMousemove: (e) => M.value = t.index,
|
|
3477
|
+
onClick: (e) => z(t.tag)
|
|
3476
3478
|
}, [
|
|
3477
|
-
g("span",
|
|
3478
|
-
g("span",
|
|
3479
|
-
t.tag.description ? (e(), _("span",
|
|
3480
|
-
], 42,
|
|
3481
|
-
],
|
|
3479
|
+
g("span", ac, E(t.tag.label), 1),
|
|
3480
|
+
g("span", oc, E(t.tag.value), 1),
|
|
3481
|
+
t.tag.description ? (e(), _("span", sc, E(t.tag.description), 1)) : y("", !0)
|
|
3482
|
+
], 42, ic))], 64))), 128))], 8, $s)
|
|
3483
|
+
], 12, Gs)]),
|
|
3482
3484
|
_: 1
|
|
3483
3485
|
}, 8, ["visible"]));
|
|
3484
3486
|
}
|
|
3485
3487
|
});
|
|
3486
3488
|
//#endregion
|
|
3487
|
-
export {
|
|
3489
|
+
export { Ls as a, Wt as c, zs as i, Pt as l, Ws as n, Ps as o, Vs as r, $t as s, cc as t, Dt as u };
|