@templatical/editor 0.16.4 → 0.16.5
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/{AiFeatureMenu-BPCkrHAS.js → AiFeatureMenu-B1oEJebq.js} +1 -1
- package/dist/{CloudEditor-v8ARYaFW.js → CloudEditor-D6KNL6VU.js} +6 -6
- package/dist/{CollaboratorBar-BQzKZ2zo.js → CollaboratorBar-C_EhXQ5R.js} +1 -1
- package/dist/{ColorPicker-Cab6U2sH.js → ColorPicker-CppJgX_T.js} +57 -58
- package/dist/{CountdownToolbar-q3umZ7TZ.js → CountdownToolbar-D5GaA_lt.js} +2 -2
- package/dist/{MergeTagSuggestion-DrT3LiZ4.js → MergeTagSuggestion-jIpT_jmz.js} +7 -5
- package/dist/{ModuleBrowserModal-CzzChPmN.js → ModuleBrowserModal-CXy8Bbv9.js} +4 -4
- package/dist/{ModulePreviewCanvas-C0Q2n3FL.js → ModulePreviewCanvas-CJC9kyZN.js} +1 -1
- package/dist/{NumberWithSuffix-Bhm2ByHs.js → NumberWithSuffix-DNi-v4l1.js} +1 -1
- package/dist/{ParagraphEditor-BhsBi8p8.js → ParagraphEditor-nk5Vvr7M.js} +38 -39
- package/dist/{RichTextEditorContent-ef0fdj6e.js → RichTextEditorContent-DBaCrvH0.js} +13 -13
- package/dist/{SaveModuleDialog-BNN3dcxD.js → SaveModuleDialog-CYu5PhBz.js} +2 -2
- package/dist/{SnapshotHistory-tWvgMCe6.js → SnapshotHistory-B38ImqMO.js} +2 -2
- package/dist/{TestEmailModal-EdwEcsrD.js → TestEmailModal-DbstIzEf.js} +2 -2
- package/dist/{TitleEditor-DdvRepBq.js → TitleEditor-CmfkOHJT.js} +18 -18
- package/dist/{TplModal-Niu4Y96-.js → TplModal-BXnx3sLr.js} +4 -4
- package/dist/{blockTypeIcons-DHcYPMB8.js → blockTypeIcons-BVIEw0XJ.js} +1 -1
- package/dist/bundle-stats.json +7 -7
- package/dist/cdn/chunks/{AiFeatureMenu-AoUwsqor.js → AiFeatureMenu-CuIg4yrB.js} +6 -6
- package/dist/cdn/chunks/{AiFeatureMenu-AoUwsqor.js.map → AiFeatureMenu-CuIg4yrB.js.map} +1 -1
- package/dist/cdn/chunks/{BlockIssueBadge-DZU3CfEN.js → BlockIssueBadge-BHEl_Hs7.js} +4 -4
- package/dist/cdn/chunks/{BlockIssueBadge-DZU3CfEN.js.map → BlockIssueBadge-BHEl_Hs7.js.map} +1 -1
- package/dist/cdn/chunks/{CloudEditor-BrZLF_m1.js → CloudEditor-1Ms0w691.js} +130 -130
- package/dist/cdn/chunks/{CloudEditor-BrZLF_m1.js.map → CloudEditor-1Ms0w691.js.map} +1 -1
- package/dist/cdn/chunks/{CollaboratorBar-BAC56ez6.js → CollaboratorBar-C0a5P64z.js} +3 -3
- package/dist/cdn/chunks/{CollaboratorBar-BAC56ez6.js.map → CollaboratorBar-C0a5P64z.js.map} +1 -1
- package/dist/cdn/chunks/{ColorPicker-DLEoT419.js → ColorPicker-bsMmT-_B.js} +144 -144
- package/dist/cdn/chunks/ColorPicker-bsMmT-_B.js.map +1 -0
- package/dist/cdn/chunks/{CountdownBlock-BOF9aTXF.js → CountdownBlock-8053oz4k.js} +4 -4
- package/dist/cdn/chunks/{CountdownBlock-BOF9aTXF.js.map → CountdownBlock-8053oz4k.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownToolbar-C9bQ5k4E.js → CountdownToolbar-DQ_zrorh.js} +4 -4
- package/dist/cdn/chunks/{CountdownToolbar-C9bQ5k4E.js.map → CountdownToolbar-DQ_zrorh.js.map} +1 -1
- package/dist/cdn/chunks/{IssuesPanel-CHwYahKK.js → IssuesPanel-CwQ376nf.js} +7 -7
- package/dist/cdn/chunks/{IssuesPanel-CHwYahKK.js.map → IssuesPanel-CwQ376nf.js.map} +1 -1
- package/dist/cdn/chunks/{MergeTagSuggestion-jesxS7An.js → MergeTagSuggestion-rpZ6Ol-i.js} +8 -6
- package/dist/cdn/chunks/MergeTagSuggestion-rpZ6Ol-i.js.map +1 -0
- package/dist/cdn/chunks/{ModuleBrowserModal-iSXXpAUk.js → ModuleBrowserModal-DUegB2Jk.js} +8 -8
- package/dist/cdn/chunks/{ModuleBrowserModal-iSXXpAUk.js.map → ModuleBrowserModal-DUegB2Jk.js.map} +1 -1
- package/dist/cdn/chunks/{ModulePreviewCanvas-DIy0MZj2.js → ModulePreviewCanvas-f4h8r9Lh.js} +32 -32
- package/dist/cdn/chunks/{ModulePreviewCanvas-DIy0MZj2.js.map → ModulePreviewCanvas-f4h8r9Lh.js.map} +1 -1
- package/dist/cdn/chunks/{NumberWithSuffix-vPdOG2lO.js → NumberWithSuffix-Bu_nHJuD.js} +2 -2
- package/dist/cdn/chunks/{NumberWithSuffix-vPdOG2lO.js.map → NumberWithSuffix-Bu_nHJuD.js.map} +1 -1
- package/dist/cdn/chunks/{ParagraphEditor-D7znI_X1.js → ParagraphEditor-IpZsg8qo.js} +75 -75
- package/dist/cdn/chunks/ParagraphEditor-IpZsg8qo.js.map +1 -0
- package/dist/cdn/chunks/{RichTextEditorContent-DVwGHbO6.js → RichTextEditorContent-DDnqZ9cB.js} +6 -6
- package/dist/cdn/chunks/{RichTextEditorContent-DVwGHbO6.js.map → RichTextEditorContent-DDnqZ9cB.js.map} +1 -1
- package/dist/cdn/chunks/{SaveModuleDialog-D2_qPtE9.js → SaveModuleDialog-CVA5HPCi.js} +20 -20
- package/dist/cdn/chunks/{SaveModuleDialog-D2_qPtE9.js.map → SaveModuleDialog-CVA5HPCi.js.map} +1 -1
- package/dist/cdn/chunks/{TitleEditor-CKjZ6Cgp.js → TitleEditor-DU8wm0Rh.js} +9 -9
- package/dist/cdn/chunks/TitleEditor-DU8wm0Rh.js.map +1 -0
- package/dist/cdn/chunks/{blockTypeIcons-BKecgdgr.js → blockTypeIcons-Dm5Oosjp.js} +7 -7
- package/dist/cdn/chunks/{blockTypeIcons-BKecgdgr.js.map → blockTypeIcons-Dm5Oosjp.js.map} +1 -1
- package/dist/cdn/chunks/{extensions-OZTN_skA.js → extensions-BGUoo2a5.js} +29 -29
- package/dist/cdn/chunks/{extensions-OZTN_skA.js.map → extensions-BGUoo2a5.js.map} +1 -1
- package/dist/cdn/chunks/{features-Bo7H8WNI.js → features-BSpDuFFR.js} +423 -404
- package/dist/cdn/chunks/features-BSpDuFFR.js.map +1 -0
- package/dist/cdn/chunks/{icons-BrNSrnyT.js → icons-k3XVoRvc.js} +2 -2
- package/dist/cdn/chunks/{icons-BrNSrnyT.js.map → icons-k3XVoRvc.js.map} +1 -1
- package/dist/cdn/chunks/{media-library-Cec5DMR3.js → media-library-iDq3otm6.js} +451 -451
- package/dist/cdn/chunks/{media-library-Cec5DMR3.js.map → media-library-iDq3otm6.js.map} +1 -1
- package/dist/cdn/chunks/{quality-Dd2iYgRf.js → quality-Bb7vN32U.js} +512 -512
- package/dist/cdn/chunks/{quality-Dd2iYgRf.js.map → quality-Bb7vN32U.js.map} +1 -1
- package/dist/cdn/chunks/{renderer-Br-qXdnQ.js → renderer-cOvtk8HM.js} +16 -16
- package/dist/cdn/chunks/{renderer-Br-qXdnQ.js.map → renderer-cOvtk8HM.js.map} +1 -1
- package/dist/cdn/chunks/{src-BH8PABpF.js → src-Ddp969zE.js} +6 -6
- package/dist/cdn/chunks/{src-BH8PABpF.js.map → src-Ddp969zE.js.map} +1 -1
- package/dist/cdn/chunks/{styles-nqo5BynI.js → styles-CW_gRVVR.js} +219 -219
- package/dist/cdn/chunks/styles-CW_gRVVR.js.map +1 -0
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +46 -46
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{extensions-B2poxDIo.js → extensions-Cjd-VAII.js} +1 -1
- package/dist/index.d.ts +12 -0
- package/dist/style.css +1 -1
- package/dist/{styles-DN4J7w-C.js → styles-DJfTblY7.js} +97 -97
- package/dist/templatical-editor.js +4 -4
- package/dist/{useEditorCore-DBq2689h.js → useEditorCore-DnOG2a_b.js} +681 -681
- package/dist/usePopoverPosition-B3Byo68F.js +281 -0
- package/package.json +7 -7
- package/dist/cdn/chunks/ColorPicker-DLEoT419.js.map +0 -1
- package/dist/cdn/chunks/MergeTagSuggestion-jesxS7An.js.map +0 -1
- package/dist/cdn/chunks/ParagraphEditor-D7znI_X1.js.map +0 -1
- package/dist/cdn/chunks/TitleEditor-CKjZ6Cgp.js.map +0 -1
- package/dist/cdn/chunks/features-Bo7H8WNI.js.map +0 -1
- package/dist/cdn/chunks/styles-nqo5BynI.js.map +0 -1
- package/dist/color-DhoxCSMv.js +0 -259
- package/dist/usePopoverRoot-C1j0D7cc.js +0 -8
|
@@ -1,18 +1,17 @@
|
|
|
1
1
|
import { A as e, Dt as t, Et as n, N as r, O as i, Ot as a, W as o, Y as s, _ as c, c as l, d as u, h as d, i as f, l as p, m, nt as h, r as g, s as _, u as v, x as y } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { c as b, s as x } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import { D as S, E as C, S as w, x as T } from "./useEditorCore-
|
|
4
|
-
import {
|
|
5
|
-
import { I as
|
|
6
|
-
import { t as
|
|
7
|
-
import { t as
|
|
8
|
-
import { a as ie, i as ae, n as
|
|
3
|
+
import { D as S, E as C, S as w, x as T } from "./useEditorCore-DnOG2a_b.js";
|
|
4
|
+
import { i as E, n as D } from "./usePopoverPosition-B3Byo68F.js";
|
|
5
|
+
import { I as O, L as k, P as A, g as ee, m as te, w as ne, x as re } from "./keys-BbDgCU6K.js";
|
|
6
|
+
import { t as j } from "./useI18n-eR1yVW0v.js";
|
|
7
|
+
import { t as M } from "./createLucideIcon-FSF4peHQ.js";
|
|
8
|
+
import { a as ie, i as ae, n as N, r as oe, t as P } from "./RichTextEditorContent-DBaCrvH0.js";
|
|
9
9
|
import { n as se, t as ce } from "./scan-line-IAMjPtRw.js";
|
|
10
10
|
import { t as le } from "./loader-circle-BT38qSm3.js";
|
|
11
11
|
import { n as ue, r as de, t as fe } from "./text-align-start-BwsA6QzC.js";
|
|
12
|
-
import { t as
|
|
13
|
-
import { t as
|
|
14
|
-
|
|
15
|
-
var L = j("list-ordered", [
|
|
12
|
+
import { t as F } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
13
|
+
import { c as pe, o as me, r as he, s as ge, t as I } from "./ColorPicker-CppJgX_T.js";
|
|
14
|
+
var L = M("list-ordered", [
|
|
16
15
|
["path", {
|
|
17
16
|
d: "M11 5h10",
|
|
18
17
|
key: "1cz7ny"
|
|
@@ -37,7 +36,7 @@ var L = j("list-ordered", [
|
|
|
37
36
|
d: "M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02",
|
|
38
37
|
key: "xtkcd5"
|
|
39
38
|
}]
|
|
40
|
-
]), _e =
|
|
39
|
+
]), _e = M("list", [
|
|
41
40
|
["path", {
|
|
42
41
|
d: "M3 5h.01",
|
|
43
42
|
key: "18ugdj"
|
|
@@ -62,7 +61,7 @@ var L = j("list-ordered", [
|
|
|
62
61
|
d: "M8 19h13",
|
|
63
62
|
key: "m83p4d"
|
|
64
63
|
}]
|
|
65
|
-
]), ve =
|
|
64
|
+
]), ve = M("remove-formatting", [
|
|
66
65
|
["path", {
|
|
67
66
|
d: "M4 7V4h16v3",
|
|
68
67
|
key: "9msm58"
|
|
@@ -83,7 +82,7 @@ var L = j("list-ordered", [
|
|
|
83
82
|
d: "m20 15-5 5",
|
|
84
83
|
key: "11p7ol"
|
|
85
84
|
}]
|
|
86
|
-
]), R =
|
|
85
|
+
]), R = M("smile", [
|
|
87
86
|
["circle", {
|
|
88
87
|
cx: "12",
|
|
89
88
|
cy: "12",
|
|
@@ -108,7 +107,7 @@ var L = j("list-ordered", [
|
|
|
108
107
|
y2: "9",
|
|
109
108
|
key: "1p4y9e"
|
|
110
109
|
}]
|
|
111
|
-
]), ye =
|
|
110
|
+
]), ye = M("strikethrough", [
|
|
112
111
|
["path", {
|
|
113
112
|
d: "M16 4H9a3 3 0 0 0-2.83 4",
|
|
114
113
|
key: "43sutm"
|
|
@@ -124,7 +123,7 @@ var L = j("list-ordered", [
|
|
|
124
123
|
y2: "12",
|
|
125
124
|
key: "1e0a9i"
|
|
126
125
|
}]
|
|
127
|
-
]), be =
|
|
126
|
+
]), be = M("subscript", [
|
|
128
127
|
["path", {
|
|
129
128
|
d: "m4 5 8 8",
|
|
130
129
|
key: "1eunvl"
|
|
@@ -137,7 +136,7 @@ var L = j("list-ordered", [
|
|
|
137
136
|
d: "M20 19h-4c0-1.5.44-2 1.5-2.5S20 15.33 20 14c0-.47-.17-.93-.48-1.29a2.11 2.11 0 0 0-2.62-.44c-.42.24-.74.62-.9 1.07",
|
|
138
137
|
key: "e8ta8j"
|
|
139
138
|
}]
|
|
140
|
-
]), xe =
|
|
139
|
+
]), xe = M("superscript", [
|
|
141
140
|
["path", {
|
|
142
141
|
d: "m4 19 8-8",
|
|
143
142
|
key: "hr47gm"
|
|
@@ -150,7 +149,7 @@ var L = j("list-ordered", [
|
|
|
150
149
|
d: "M20 12h-4c0-1.5.442-2 1.5-2.5S20 8.334 20 7.002c0-.472-.17-.93-.484-1.29a2.105 2.105 0 0 0-2.617-.436c-.42.239-.738.614-.899 1.06",
|
|
151
150
|
key: "1dfcux"
|
|
152
151
|
}]
|
|
153
|
-
]), Se =
|
|
152
|
+
]), Se = M("underline", [["path", {
|
|
154
153
|
d: "M6 4v6a6 6 0 0 0 12 0V4",
|
|
155
154
|
key: "9kb039"
|
|
156
155
|
}], ["line", {
|
|
@@ -167,7 +166,7 @@ var L = j("list-ordered", [
|
|
|
167
166
|
__name: "EmojiPickerDropdown",
|
|
168
167
|
emits: ["insert"],
|
|
169
168
|
setup(t, { emit: r }) {
|
|
170
|
-
let o = r, { categories: c, isOpen: f, toggle: p, close: m } = C(), { t: y, format: w } =
|
|
169
|
+
let o = r, { categories: c, isOpen: f, toggle: p, close: m } = C(), { t: y, format: w } = j(), T = s(null), D = s(null);
|
|
171
170
|
S(T, _(() => f.value)), E(D, () => {
|
|
172
171
|
f.value && m();
|
|
173
172
|
});
|
|
@@ -244,7 +243,7 @@ var L = j("list-ordered", [
|
|
|
244
243
|
function J(e, t) {
|
|
245
244
|
return i(), u("span", q);
|
|
246
245
|
}
|
|
247
|
-
var Y = /*#__PURE__*/
|
|
246
|
+
var Y = /*#__PURE__*/ F(K, [["render", J]]), X = [
|
|
248
247
|
"value",
|
|
249
248
|
"aria-label",
|
|
250
249
|
"title"
|
|
@@ -306,14 +305,14 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
306
305
|
"add-logic-tag"
|
|
307
306
|
],
|
|
308
307
|
setup(e, { emit: n }) {
|
|
309
|
-
let r = e, o = n, s = y(
|
|
310
|
-
function
|
|
308
|
+
let r = e, o = n, s = y(A, null), c = y(O, null), b = k(ee, "ParagraphToolbar"), x = D(), S = y(ne, null), C = y(re, null), w = y(te, null), T = _(() => (S?.isOpen.value ?? !1) || (C?.isOpen.value ?? !1)), { t: E } = j(), M = b.fonts;
|
|
309
|
+
function N(e) {
|
|
311
310
|
r.editor?.chain().focus().insertContent(e).run();
|
|
312
311
|
}
|
|
313
|
-
function
|
|
312
|
+
function P(e) {
|
|
314
313
|
return r.editor?.getAttributes("textStyle")[e] || "";
|
|
315
314
|
}
|
|
316
|
-
function
|
|
315
|
+
function F(e) {
|
|
317
316
|
let t = r.editor?.chain().focus();
|
|
318
317
|
e ? t?.setFontFamily(e).run() : t?.unsetFontFamily().run();
|
|
319
318
|
}
|
|
@@ -333,10 +332,10 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
333
332
|
}
|
|
334
333
|
function H() {
|
|
335
334
|
let e = w?.content.value.settings;
|
|
336
|
-
return z() ? Q(B(), e?.linkColor || e?.textColor) : Q(
|
|
335
|
+
return z() ? Q(B(), e?.linkColor || e?.textColor) : Q(P("color"), e?.textColor);
|
|
337
336
|
}
|
|
338
337
|
function U() {
|
|
339
|
-
return z() ? B() :
|
|
338
|
+
return z() ? B() : P("color");
|
|
340
339
|
}
|
|
341
340
|
function W() {
|
|
342
341
|
return r.editor?.getAttributes("paragraph").lineHeight || "";
|
|
@@ -363,7 +362,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
363
362
|
"data-tpl-theme": h(c),
|
|
364
363
|
role: "toolbar",
|
|
365
364
|
"aria-label": h(E).paragraphEditor.toolbar,
|
|
366
|
-
class: "tpl tpl-text-toolbar tpl:
|
|
365
|
+
class: "tpl tpl-text-toolbar tpl:absolute tpl:z-popover tpl:flex tpl:gap-1 tpl:rounded-lg tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-2 tpl:shadow-lg",
|
|
367
366
|
style: t({
|
|
368
367
|
...h(s),
|
|
369
368
|
top: `${e.toolbarPosition.top}px`,
|
|
@@ -373,12 +372,12 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
373
372
|
})
|
|
374
373
|
}, [!e.isLoading && e.editor ? (i(), u(g, { key: 0 }, [l("div", De, [
|
|
375
374
|
d(Z, {
|
|
376
|
-
"model-value":
|
|
377
|
-
options: h(
|
|
375
|
+
"model-value": P("fontFamily"),
|
|
376
|
+
options: h(M),
|
|
378
377
|
label: h(E).paragraphEditor.fontFamily,
|
|
379
378
|
placeholder: h(E).paragraphEditor.defaultFont,
|
|
380
379
|
"width-class": "tpl:w-32",
|
|
381
|
-
"onUpdate:modelValue":
|
|
380
|
+
"onUpdate:modelValue": F
|
|
382
381
|
}, null, 8, [
|
|
383
382
|
"model-value",
|
|
384
383
|
"options",
|
|
@@ -386,7 +385,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
386
385
|
"placeholder"
|
|
387
386
|
]),
|
|
388
387
|
d(Z, {
|
|
389
|
-
"model-value":
|
|
388
|
+
"model-value": P("fontSize"),
|
|
390
389
|
options: h(me),
|
|
391
390
|
label: h(E).paragraphEditor.fontSize,
|
|
392
391
|
placeholder: h(E).paragraphEditor.defaultSize,
|
|
@@ -565,7 +564,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
565
564
|
"label"
|
|
566
565
|
]),
|
|
567
566
|
d(Z, {
|
|
568
|
-
"model-value":
|
|
567
|
+
"model-value": P("letterSpacing"),
|
|
569
568
|
options: h(ge),
|
|
570
569
|
label: h(E).paragraphEditor.letterSpacing,
|
|
571
570
|
placeholder: "LS",
|
|
@@ -583,7 +582,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
583
582
|
onClick: r[12] ||= (t) => e.editor.chain().focus().clearNodes().unsetAllMarks().run()
|
|
584
583
|
}, null, 8, ["icon", "label"]),
|
|
585
584
|
d(Y),
|
|
586
|
-
d(Ce, { onInsert:
|
|
585
|
+
d(Ce, { onInsert: N }),
|
|
587
586
|
e.canRequestMergeTag ? (i(), u(g, { key: 0 }, [d(Y), l("button", {
|
|
588
587
|
type: "button",
|
|
589
588
|
class: "tpl:flex tpl:h-8 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:gap-1.5 tpl:rounded tpl:border-none tpl:bg-transparent tpl:px-2.5 tpl:text-xs tpl:font-medium tpl:text-[var(--tpl-text)] tpl:transition-all tpl:duration-150 tpl:hover:bg-[var(--tpl-bg-active)]",
|
|
@@ -619,7 +618,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
619
618
|
},
|
|
620
619
|
emits: ["done"],
|
|
621
620
|
setup(e, { emit: t }) {
|
|
622
|
-
let n = e, r = t, a =
|
|
621
|
+
let n = e, r = t, a = D(), { editor: s, EditorContent: c, isLoading: l, initError: f, retry: p, showLinkDialog: m, linkUrl: g, linkColor: _, linkDialogRef: v, canRequestMergeTag: y, canInsertLogicTag: b, openLinkDialog: x, insertLink: S, removeLink: C, closeLinkDialog: E, handleLinkKeydown: O, handleAddMergeTag: k, handleAddLogicTag: A } = T({
|
|
623
622
|
blockId: () => n.block.id,
|
|
624
623
|
blockContent: () => n.block.content,
|
|
625
624
|
onDone: () => r("done"),
|
|
@@ -637,7 +636,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
637
636
|
import("./dist-BXR1aBJV.js"),
|
|
638
637
|
import("./dist-BE9m_i60.js"),
|
|
639
638
|
import("./dist-BPPeDw62.js"),
|
|
640
|
-
import("./extensions-
|
|
639
|
+
import("./extensions-Cjd-VAII.js")
|
|
641
640
|
]);
|
|
642
641
|
return {
|
|
643
642
|
TiptapEditor: o,
|
|
@@ -692,8 +691,8 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
692
691
|
"can-request-merge-tag": h(y),
|
|
693
692
|
"can-insert-logic-tag": h(b),
|
|
694
693
|
onOpenLinkDialog: h(x),
|
|
695
|
-
onAddMergeTag: h(
|
|
696
|
-
onAddLogicTag: h(
|
|
694
|
+
onAddMergeTag: h(k),
|
|
695
|
+
onAddLogicTag: h(A)
|
|
697
696
|
}, null, 8, [
|
|
698
697
|
"editor",
|
|
699
698
|
"toolbar-position",
|
|
@@ -704,7 +703,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
704
703
|
"onAddMergeTag",
|
|
705
704
|
"onAddLogicTag"
|
|
706
705
|
]),
|
|
707
|
-
d(
|
|
706
|
+
d(P, {
|
|
708
707
|
editor: h(s),
|
|
709
708
|
"editor-content": h(c),
|
|
710
709
|
"is-loading": h(l),
|
|
@@ -717,7 +716,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
717
716
|
"init-error",
|
|
718
717
|
"onRetry"
|
|
719
718
|
]),
|
|
720
|
-
d(
|
|
719
|
+
d(N, {
|
|
721
720
|
visible: h(m),
|
|
722
721
|
"is-editing-link": h(s)?.isActive("link") ?? !1,
|
|
723
722
|
"dialog-ref": h(v),
|
|
@@ -729,7 +728,7 @@ var Ee = ["data-tpl-theme", "aria-label"], De = { class: "tpl:flex tpl:items-cen
|
|
|
729
728
|
onClose: h(E),
|
|
730
729
|
onInsert: h(S),
|
|
731
730
|
onRemove: h(C),
|
|
732
|
-
onKeydown: h(
|
|
731
|
+
onKeydown: h(O)
|
|
733
732
|
}, null, 8, [
|
|
734
733
|
"visible",
|
|
735
734
|
"is-editing-link",
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { C as e, Dt as t, N as n, O as r, Ot as i, P as a, _ as o, c as s, d as c, h as l, i as u, l as d, m as f, nt as p, s as m, u as h, x as g, z as _ } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { a as v, c as y } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { t as w } from "./
|
|
6
|
-
import { t as T } from "./
|
|
7
|
-
import { t as E } from "./
|
|
8
|
-
import { t as D } from "./ColorPicker-
|
|
9
|
-
var O =
|
|
3
|
+
import { n as b } from "./usePopoverPosition-B3Byo68F.js";
|
|
4
|
+
import { I as x, P as S, m as C } from "./keys-BbDgCU6K.js";
|
|
5
|
+
import { t as w } from "./useI18n-eR1yVW0v.js";
|
|
6
|
+
import { t as T } from "./createLucideIcon-FSF4peHQ.js";
|
|
7
|
+
import { t as E } from "./x-Ctg_250T.js";
|
|
8
|
+
import { t as D } from "./ColorPicker-CppJgX_T.js";
|
|
9
|
+
var O = T("bold", [["path", {
|
|
10
10
|
d: "M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8",
|
|
11
11
|
key: "mg9rjx"
|
|
12
|
-
}]]), k =
|
|
12
|
+
}]]), k = T("italic", [
|
|
13
13
|
["line", {
|
|
14
14
|
x1: "19",
|
|
15
15
|
x2: "10",
|
|
@@ -31,7 +31,7 @@ var O = w("bold", [["path", {
|
|
|
31
31
|
y2: "20",
|
|
32
32
|
key: "uljnxc"
|
|
33
33
|
}]
|
|
34
|
-
]), A =
|
|
34
|
+
]), A = T("link", [["path", {
|
|
35
35
|
d: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",
|
|
36
36
|
key: "1cjeqo"
|
|
37
37
|
}], ["path", {
|
|
@@ -67,7 +67,7 @@ var O = w("bold", [["path", {
|
|
|
67
67
|
"update:dialogRef"
|
|
68
68
|
]),
|
|
69
69
|
setup(e, { emit: n }) {
|
|
70
|
-
let o = a(e, "linkUrl"), f = a(e, "linkColor"),
|
|
70
|
+
let o = a(e, "linkUrl"), f = a(e, "linkColor"), T = a(e, "dialogRef"), O = n, k = g(S, null), A = g(x, null), U = b(), W = g(C, null), G = m(() => W?.content.value.settings.linkColor || "#2c85de"), { t: K } = w();
|
|
71
71
|
return (n, a) => p(U) ? (r(), d(u, {
|
|
72
72
|
key: 0,
|
|
73
73
|
to: p(U)
|
|
@@ -78,7 +78,7 @@ var O = w("bold", [["path", {
|
|
|
78
78
|
style: t(p(k)),
|
|
79
79
|
onClick: a[7] ||= y((e) => O("close"), ["self"])
|
|
80
80
|
}, [s("div", {
|
|
81
|
-
ref: (e) =>
|
|
81
|
+
ref: (e) => T.value = e,
|
|
82
82
|
role: "dialog",
|
|
83
83
|
"aria-modal": "true",
|
|
84
84
|
"aria-labelledby": "tpl-link-dialog-title",
|
|
@@ -89,7 +89,7 @@ var O = w("bold", [["path", {
|
|
|
89
89
|
"aria-label": p(K).linkDialog.cancel,
|
|
90
90
|
class: "tpl:flex tpl:size-7 tpl:cursor-pointer tpl:items-center tpl:justify-center tpl:rounded tpl:border-none tpl:bg-transparent tpl:p-0 tpl:text-[var(--tpl-text-muted)] tpl:hover:bg-[var(--tpl-bg-hover)] tpl:hover:text-[var(--tpl-text)]",
|
|
91
91
|
onClick: a[0] ||= (e) => O("close")
|
|
92
|
-
}, [l(p(
|
|
92
|
+
}, [l(p(E), {
|
|
93
93
|
size: 16,
|
|
94
94
|
"stroke-width": 2
|
|
95
95
|
})], 8, P)]),
|
|
@@ -138,7 +138,7 @@ var O = w("bold", [["path", {
|
|
|
138
138
|
},
|
|
139
139
|
emits: ["retry"],
|
|
140
140
|
setup(e, { emit: t }) {
|
|
141
|
-
let a = t, { t: o } =
|
|
141
|
+
let a = t, { t: o } = w();
|
|
142
142
|
return (t, l) => e.isLoading ? (r(), c("div", W, [s("div", G, i(p(o).errors.editorLoading), 1)])) : e.initError ? (r(), c("div", K, [f(i(p(o).errors.editorLoadFailed) + " ", 1), s("button", {
|
|
143
143
|
class: "tpl:ml-1 tpl:cursor-pointer tpl:border-none tpl:bg-transparent tpl:p-0 tpl:underline tpl:text-[var(--tpl-primary)]",
|
|
144
144
|
onClick: l[0] ||= (e) => a("retry")
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { A as e, Dt as t, Et as n, I as r, O as i, Ot as a, R as o, Y as s, _ as c, c as l, d as u, h as d, l as f, m as p, nt as m, r as h, s as g, u as ee, z as _ } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { a as v } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import "./useEditorCore-
|
|
3
|
+
import "./useEditorCore-DnOG2a_b.js";
|
|
4
4
|
import { L as y, j as b, m as x } from "./keys-BbDgCU6K.js";
|
|
5
5
|
import { t as S } from "./useI18n-eR1yVW0v.js";
|
|
6
6
|
import { t as te } from "./loader-circle-BT38qSm3.js";
|
|
7
7
|
import { n as ne } from "./useCloudI18n-WbfVWq5k.js";
|
|
8
8
|
import { t as re } from "./ToggleSwitch-DUNuUPsZ.js";
|
|
9
|
-
import { t as C } from "./TplModal-
|
|
9
|
+
import { t as C } from "./TplModal-BXnx3sLr.js";
|
|
10
10
|
//#region src/cloud/components/SaveModuleDialog.vue?vue&type=script&setup=true&lang.ts
|
|
11
11
|
var w = ["aria-busy"], T = {
|
|
12
12
|
id: "tpl-save-module-title",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as e, Et as t, I as n, O as r, Ot as i, R as a, Y as o, _ as s, c, d as l, h as u, nt as d, r as f, s as p, u as m } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { c as h, t as g } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import "./useEditorCore-
|
|
4
|
-
import {
|
|
3
|
+
import "./useEditorCore-DnOG2a_b.js";
|
|
4
|
+
import { i as _ } from "./usePopoverPosition-B3Byo68F.js";
|
|
5
5
|
import { t as v } from "./useI18n-eR1yVW0v.js";
|
|
6
6
|
import { t as y } from "./createLucideIcon-FSF4peHQ.js";
|
|
7
7
|
import { t as b } from "./chevron-down-dClfxKrJ.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { A as e, Et as t, I as n, O as r, Ot as i, R as a, Y as o, _ as s, c, d as l, h as u, l as d, m as f, nt as p, r as m, u as h, z as g } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { i as _ } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import "./useEditorCore-
|
|
3
|
+
import "./useEditorCore-DnOG2a_b.js";
|
|
4
4
|
import { t as v } from "./loader-circle-BT38qSm3.js";
|
|
5
5
|
import { n as y } from "./useCloudI18n-WbfVWq5k.js";
|
|
6
|
-
import { t as b } from "./TplModal-
|
|
6
|
+
import { t as b } from "./TplModal-BXnx3sLr.js";
|
|
7
7
|
//#region src/cloud/components/TestEmailModal.vue?vue&type=script&setup=true&lang.ts
|
|
8
8
|
var x = ["aria-busy"], S = {
|
|
9
9
|
id: "tpl-test-email-title",
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Dt as e, Et as t, O as n, Ot as r, W as i, _ as a, c as o, d as s, h as c, i as l, l as u, m as d, nt as f, r as p, s as m, u as h, x as g } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
|
-
import { S as ee, x as te } from "./useEditorCore-
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { n as
|
|
7
|
-
import { t as S } from "./
|
|
8
|
-
import { t as C } from "./
|
|
2
|
+
import { S as ee, x as te } from "./useEditorCore-DnOG2a_b.js";
|
|
3
|
+
import { n as ne } from "./usePopoverPosition-B3Byo68F.js";
|
|
4
|
+
import { I as _, P as v, w as y, x as b } from "./keys-BbDgCU6K.js";
|
|
5
|
+
import { t as re } from "./useI18n-eR1yVW0v.js";
|
|
6
|
+
import { a as ie, i as ae, n as oe, r as se, t as ce } from "./RichTextEditorContent-DBaCrvH0.js";
|
|
7
|
+
import { n as x, t as S } from "./scan-line-IAMjPtRw.js";
|
|
8
|
+
import { t as C } from "./loader-circle-BT38qSm3.js";
|
|
9
9
|
//#region src/components/blocks/TitleEditor.vue?vue&type=script&setup=true&lang.ts
|
|
10
10
|
var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme", "aria-label"], E = ["aria-label", "title"], D = ["aria-label", "title"], O = ["aria-label", "title"], k = {
|
|
11
11
|
key: 0,
|
|
@@ -24,7 +24,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
24
24
|
},
|
|
25
25
|
emits: ["done"],
|
|
26
26
|
setup(a, { emit: P }) {
|
|
27
|
-
let F = a, I = P, L = g(
|
|
27
|
+
let F = a, I = P, L = g(v, null), R = g(_, null), z = ne(), B = g(y, null), le = g(b, null), V = m(() => (B?.isOpen.value ?? !1) || (le?.isOpen.value ?? !1)), { t: H } = re(), { editor: U, EditorContent: W, isLoading: G, initError: ue, retry: de, showLinkDialog: fe, linkUrl: K, linkColor: q, linkDialogRef: J, canRequestMergeTag: Y, canInsertLogicTag: X, openLinkDialog: Z, insertLink: pe, removeLink: me, closeLinkDialog: he, handleLinkKeydown: ge, handleAddMergeTag: Q, handleAddLogicTag: $ } = te({
|
|
28
28
|
blockId: () => F.block.id,
|
|
29
29
|
blockContent: () => F.block.content,
|
|
30
30
|
onDone: () => I("done"),
|
|
@@ -34,7 +34,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
34
34
|
import("./dist-BReUTadj.js").then((e) => e.r),
|
|
35
35
|
import("./dist-i_Z7t67A.js"),
|
|
36
36
|
import("./dist-CHLoeloJ.js"),
|
|
37
|
-
import("./extensions-
|
|
37
|
+
import("./extensions-Cjd-VAII.js")
|
|
38
38
|
]);
|
|
39
39
|
return {
|
|
40
40
|
TiptapEditor: a,
|
|
@@ -81,7 +81,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
81
81
|
"data-tpl-theme": f(R),
|
|
82
82
|
role: "toolbar",
|
|
83
83
|
"aria-label": f(H).titleEditor.toolbar,
|
|
84
|
-
class: "tpl tpl-text-toolbar tpl:
|
|
84
|
+
class: "tpl tpl-text-toolbar tpl:absolute tpl:z-popover tpl:flex tpl:items-center tpl:gap-1 tpl:rounded-lg tpl:border tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:px-3 tpl:py-2 tpl:shadow-lg",
|
|
85
85
|
style: e({
|
|
86
86
|
...f(L),
|
|
87
87
|
top: `${a.toolbarPosition.top}px`,
|
|
@@ -95,7 +95,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
95
95
|
"aria-label": f(H).titleEditor.bold,
|
|
96
96
|
title: f(H).titleEditor.bold,
|
|
97
97
|
onClick: g[0] ||= (e) => f(U)?.chain().focus().toggleBold().run()
|
|
98
|
-
}, [c(f(
|
|
98
|
+
}, [c(f(ie), {
|
|
99
99
|
size: 16,
|
|
100
100
|
"stroke-width": 2.5
|
|
101
101
|
})], 10, E),
|
|
@@ -105,7 +105,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
105
105
|
"aria-label": f(H).titleEditor.italic,
|
|
106
106
|
title: f(H).titleEditor.italic,
|
|
107
107
|
onClick: g[1] ||= (e) => f(U)?.chain().focus().toggleItalic().run()
|
|
108
|
-
}, [c(f(
|
|
108
|
+
}, [c(f(ae), {
|
|
109
109
|
size: 16,
|
|
110
110
|
"stroke-width": 2
|
|
111
111
|
})], 10, D),
|
|
@@ -119,7 +119,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
119
119
|
"aria-label": f(H).titleEditor.addLink,
|
|
120
120
|
title: f(H).titleEditor.addLink,
|
|
121
121
|
onClick: g[2] ||= (...e) => f(Z) && f(Z)(...e)
|
|
122
|
-
}, [c(f(
|
|
122
|
+
}, [c(f(se), {
|
|
123
123
|
size: 16,
|
|
124
124
|
"stroke-width": 2
|
|
125
125
|
})], 10, O),
|
|
@@ -131,7 +131,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
131
131
|
"aria-label": f(H).mergeTag.insert,
|
|
132
132
|
title: f(H).mergeTag.insert,
|
|
133
133
|
onClick: g[3] ||= (...e) => f(Q) && f(Q)(...e)
|
|
134
|
-
}, [c(f(
|
|
134
|
+
}, [c(f(S), {
|
|
135
135
|
size: 16,
|
|
136
136
|
"stroke-width": 2
|
|
137
137
|
}), d(" " + r(f(H).mergeTag.insertShort), 1)], 8, A)) : h("", !0),
|
|
@@ -144,16 +144,16 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
144
144
|
title: f(H).logicTag.insert,
|
|
145
145
|
"data-testid": "insert-logic-button",
|
|
146
146
|
onClick: g[4] ||= (...e) => f($) && f($)(...e)
|
|
147
|
-
}, [c(f(
|
|
147
|
+
}, [c(f(x), {
|
|
148
148
|
size: 16,
|
|
149
149
|
"stroke-width": 2
|
|
150
150
|
}), d(" " + r(f(H).logicTag.insertShort), 1)], 8, M)) : h("", !0)
|
|
151
|
-
], 64)) : (n(), s("div", N, [c(f(
|
|
151
|
+
], 64)) : (n(), s("div", N, [c(f(C), {
|
|
152
152
|
class: "tpl-spinner",
|
|
153
153
|
size: 14,
|
|
154
154
|
"stroke-width": 2
|
|
155
155
|
}), d(" " + r(f(H).errors.editorLoading), 1)]))], 12, T)], 8, ["to"])) : h("", !0),
|
|
156
|
-
c(
|
|
156
|
+
c(ce, {
|
|
157
157
|
editor: f(U),
|
|
158
158
|
"editor-content": f(W),
|
|
159
159
|
"is-loading": f(G),
|
|
@@ -166,7 +166,7 @@ var w = { class: "tpl-text-editor-wrapper tpl:relative" }, T = ["data-tpl-theme"
|
|
|
166
166
|
"init-error",
|
|
167
167
|
"onRetry"
|
|
168
168
|
]),
|
|
169
|
-
c(
|
|
169
|
+
c(oe, {
|
|
170
170
|
visible: f(fe),
|
|
171
171
|
"is-editing-link": f(U)?.isActive("link") ?? !1,
|
|
172
172
|
"dialog-ref": f(J),
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { O as e, R as t, Y as n, _ as r, c as i, d as a, h as o, i as s, j as c, l, nt as u, s as d, u as f, x as p } from "./vue.runtime.esm-bundler-B0xoGkDv.js";
|
|
2
2
|
import { c as m, t as h } from "./runtime-dom.esm-bundler-GdMI8WqG.js";
|
|
3
|
-
import { D as g } from "./useEditorCore-
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { D as g } from "./useEditorCore-DnOG2a_b.js";
|
|
4
|
+
import { n as _ } from "./usePopoverPosition-B3Byo68F.js";
|
|
5
|
+
import { I as v } from "./keys-BbDgCU6K.js";
|
|
6
6
|
//#region src/components/TplModal.vue?vue&type=script&setup=true&lang.ts
|
|
7
7
|
var y = ["data-tpl-theme"], b = /* @__PURE__ */ r({
|
|
8
8
|
__name: "TplModal",
|
|
@@ -11,7 +11,7 @@ var y = ["data-tpl-theme"], b = /* @__PURE__ */ r({
|
|
|
11
11
|
setup(r, { emit: b }) {
|
|
12
12
|
let x = r, S = b, C = n(null);
|
|
13
13
|
g(C, d(() => x.visible));
|
|
14
|
-
let w = p(
|
|
14
|
+
let w = p(v), T = _();
|
|
15
15
|
function E(e) {
|
|
16
16
|
e.key === "Escape" && S("close"), S("keydown", e);
|
|
17
17
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as e, F as t, M as n, j as r, k as i } from "./useEditorCore-
|
|
1
|
+
import { A as e, F as t, M as n, j as r, k as i } from "./useEditorCore-DnOG2a_b.js";
|
|
2
2
|
import { t as a } from "./createLucideIcon-FSF4peHQ.js";
|
|
3
3
|
var o = a("columns-3", [
|
|
4
4
|
["rect", {
|
package/dist/bundle-stats.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.16.
|
|
3
|
-
"initialGzipBytes":
|
|
4
|
-
"initialRawBytes":
|
|
5
|
-
"initialFileCount":
|
|
6
|
-
"lazyGzipBytes":
|
|
7
|
-
"lazyRawBytes":
|
|
2
|
+
"version": "0.16.5",
|
|
3
|
+
"initialGzipBytes": 282785,
|
|
4
|
+
"initialRawBytes": 1015111,
|
|
5
|
+
"initialFileCount": 42,
|
|
6
|
+
"lazyGzipBytes": 181398,
|
|
7
|
+
"lazyRawBytes": 595924,
|
|
8
8
|
"lazyFileCount": 46,
|
|
9
|
-
"generatedAt": "2026-07-
|
|
9
|
+
"generatedAt": "2026-07-20T20:11:17.315Z"
|
|
10
10
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { L as e, M as t, P as n, ct as r, f as i, g as a, m as o, p as s, st as c, u as l, x as u } from "./draggable-D840DIZB.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Et as d, Vt as f, ct as p, fn as m, gt as h, ht as g, ot as _ } from "./features-BSpDuFFR.js";
|
|
3
3
|
//#region src/cloud/components/AiFeatureMenu.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
var v = {
|
|
5
5
|
class: "tpl-ai-feature-menu tpl:w-[280px] tpl:overflow-hidden tpl:rounded-[var(--tpl-radius)] tpl:py-1 tpl:bg-[var(--tpl-bg-elevated)] tpl:border tpl:border-[var(--tpl-border)] tpl:shadow-[var(--tpl-shadow-lg)]",
|
|
@@ -7,12 +7,12 @@ var v = {
|
|
|
7
7
|
"backdrop-filter": "blur(8px)",
|
|
8
8
|
"-webkit-backdrop-filter": "blur(8px)"
|
|
9
9
|
}
|
|
10
|
-
}, y = ["onClick"], b = { class: "tpl:flex tpl:min-w-0 tpl:flex-col tpl:gap-0.5" }, x = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text)]" }, S = { class: "tpl:text-xs tpl:leading-snug tpl:text-[var(--tpl-text-muted)]" }, C = /*#__PURE__*/
|
|
10
|
+
}, y = ["onClick"], b = { class: "tpl:flex tpl:min-w-0 tpl:flex-col tpl:gap-0.5" }, x = { class: "tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text)]" }, S = { class: "tpl:text-xs tpl:leading-snug tpl:text-[var(--tpl-text-muted)]" }, C = /*#__PURE__*/ p(/* @__PURE__ */ u({
|
|
11
11
|
__name: "AiFeatureMenu",
|
|
12
12
|
props: { activeFeature: {} },
|
|
13
13
|
emits: ["select"],
|
|
14
|
-
setup(u, { emit:
|
|
15
|
-
let C =
|
|
14
|
+
setup(u, { emit: p }) {
|
|
15
|
+
let C = p, { t: w } = _(), T = m(f, "AiFeatureMenu"), E = {
|
|
16
16
|
"ai-chat": "chat",
|
|
17
17
|
"design-reference": "designToTemplate",
|
|
18
18
|
scoring: "scoring"
|
|
@@ -23,7 +23,7 @@ var v = {
|
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
25
|
key: "design-reference",
|
|
26
|
-
icon:
|
|
26
|
+
icon: d
|
|
27
27
|
},
|
|
28
28
|
{
|
|
29
29
|
key: "scoring",
|
|
@@ -56,4 +56,4 @@ var v = {
|
|
|
56
56
|
//#endregion
|
|
57
57
|
export { C as default };
|
|
58
58
|
|
|
59
|
-
//# sourceMappingURL=AiFeatureMenu-
|
|
59
|
+
//# sourceMappingURL=AiFeatureMenu-CuIg4yrB.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AiFeatureMenu-
|
|
1
|
+
{"version":3,"file":"AiFeatureMenu-CuIg4yrB.js","names":[],"sources":["../../../src/cloud/components/AiFeatureMenu.vue","../../../src/cloud/components/AiFeatureMenu.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useCloudI18nStrict } from \"../../composables\";\nimport { AI_CONFIG_KEY, requireInject } from \"../../keys\";\nimport type { AiConfig } from \"@templatical/types\";\nimport { ImageUp, ShieldCheck, Sparkles } from \"@lucide/vue\";\nimport { computed } from \"vue\";\n\nexport type AiFeature = \"ai-chat\" | \"design-reference\" | \"scoring\";\n\ndefineProps<{\n activeFeature: AiFeature | null;\n}>();\n\nconst emit = defineEmits<{\n (e: \"select\", feature: AiFeature): void;\n}>();\n\nconst { t: cloudT } = useCloudI18nStrict();\n\nconst aiConfig = requireInject(AI_CONFIG_KEY, \"AiFeatureMenu\");\n\nconst configKeyMap: Record<AiFeature, keyof AiConfig> = {\n \"ai-chat\": \"chat\",\n \"design-reference\": \"designToTemplate\",\n scoring: \"scoring\",\n};\n\nconst allFeatures: { key: AiFeature; icon: typeof Sparkles }[] = [\n { key: \"ai-chat\", icon: Sparkles },\n { key: \"design-reference\", icon: ImageUp },\n { key: \"scoring\", icon: ShieldCheck },\n];\n\nconst features = computed(() =>\n allFeatures.filter((f) => aiConfig.isFeatureEnabled(configKeyMap[f.key])),\n);\n\nfunction getTitle(key: AiFeature): string {\n if (key === \"ai-chat\") return cloudT.aiMenu.aiAssistant;\n if (key === \"design-reference\") return cloudT.aiMenu.designToTemplate;\n return cloudT.aiMenu.templateScore;\n}\n\nfunction getDescription(key: AiFeature): string {\n if (key === \"ai-chat\") return cloudT.aiMenu.aiAssistantDesc;\n if (key === \"design-reference\") return cloudT.aiMenu.designToTemplateDesc;\n return cloudT.aiMenu.templateScoreDesc;\n}\n</script>\n\n<template>\n <div\n class=\"tpl-ai-feature-menu tpl:w-[280px] tpl:overflow-hidden tpl:rounded-[var(--tpl-radius)] tpl:py-1 tpl:bg-[var(--tpl-bg-elevated)] tpl:border tpl:border-[var(--tpl-border)] tpl:shadow-[var(--tpl-shadow-lg)]\"\n style=\"backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px)\"\n >\n <button\n v-for=\"feature in features\"\n :key=\"feature.key\"\n class=\"tpl-ai-feature-menu-item tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-start tpl:gap-3 tpl:border-none tpl:px-3 tpl:py-2.5 tpl:text-left tpl:transition-colors tpl:duration-100\"\n :style=\"{\n backgroundColor:\n activeFeature === feature.key\n ? 'var(--tpl-primary-light)'\n : 'transparent',\n }\"\n @click=\"emit('select', feature.key)\"\n >\n <div\n class=\"tpl:mt-0.5 tpl:flex tpl:size-7 tpl:shrink-0 tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)]\"\n :style=\"{\n backgroundColor:\n activeFeature === feature.key\n ? 'var(--tpl-primary)'\n : 'var(--tpl-bg-active)',\n color:\n activeFeature === feature.key\n ? 'var(--tpl-bg)'\n : 'var(--tpl-text-muted)',\n }\"\n >\n <component :is=\"feature.icon\" :size=\"15\" :stroke-width=\"2\" />\n </div>\n <div class=\"tpl:flex tpl:min-w-0 tpl:flex-col tpl:gap-0.5\">\n <span class=\"tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text)]\">\n {{ getTitle(feature.key) }}\n </span>\n <span\n class=\"tpl:text-xs tpl:leading-snug tpl:text-[var(--tpl-text-muted)]\"\n >\n {{ getDescription(feature.key) }}\n </span>\n </div>\n </button>\n </div>\n</template>\n\n<style scoped>\n.tpl-ai-feature-menu-item:hover {\n background-color: var(--tpl-bg-hover) !important;\n}\n</style>\n","<script setup lang=\"ts\">\nimport { useCloudI18nStrict } from \"../../composables\";\nimport { AI_CONFIG_KEY, requireInject } from \"../../keys\";\nimport type { AiConfig } from \"@templatical/types\";\nimport { ImageUp, ShieldCheck, Sparkles } from \"@lucide/vue\";\nimport { computed } from \"vue\";\n\nexport type AiFeature = \"ai-chat\" | \"design-reference\" | \"scoring\";\n\ndefineProps<{\n activeFeature: AiFeature | null;\n}>();\n\nconst emit = defineEmits<{\n (e: \"select\", feature: AiFeature): void;\n}>();\n\nconst { t: cloudT } = useCloudI18nStrict();\n\nconst aiConfig = requireInject(AI_CONFIG_KEY, \"AiFeatureMenu\");\n\nconst configKeyMap: Record<AiFeature, keyof AiConfig> = {\n \"ai-chat\": \"chat\",\n \"design-reference\": \"designToTemplate\",\n scoring: \"scoring\",\n};\n\nconst allFeatures: { key: AiFeature; icon: typeof Sparkles }[] = [\n { key: \"ai-chat\", icon: Sparkles },\n { key: \"design-reference\", icon: ImageUp },\n { key: \"scoring\", icon: ShieldCheck },\n];\n\nconst features = computed(() =>\n allFeatures.filter((f) => aiConfig.isFeatureEnabled(configKeyMap[f.key])),\n);\n\nfunction getTitle(key: AiFeature): string {\n if (key === \"ai-chat\") return cloudT.aiMenu.aiAssistant;\n if (key === \"design-reference\") return cloudT.aiMenu.designToTemplate;\n return cloudT.aiMenu.templateScore;\n}\n\nfunction getDescription(key: AiFeature): string {\n if (key === \"ai-chat\") return cloudT.aiMenu.aiAssistantDesc;\n if (key === \"design-reference\") return cloudT.aiMenu.designToTemplateDesc;\n return cloudT.aiMenu.templateScoreDesc;\n}\n</script>\n\n<template>\n <div\n class=\"tpl-ai-feature-menu tpl:w-[280px] tpl:overflow-hidden tpl:rounded-[var(--tpl-radius)] tpl:py-1 tpl:bg-[var(--tpl-bg-elevated)] tpl:border tpl:border-[var(--tpl-border)] tpl:shadow-[var(--tpl-shadow-lg)]\"\n style=\"backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px)\"\n >\n <button\n v-for=\"feature in features\"\n :key=\"feature.key\"\n class=\"tpl-ai-feature-menu-item tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-start tpl:gap-3 tpl:border-none tpl:px-3 tpl:py-2.5 tpl:text-left tpl:transition-colors tpl:duration-100\"\n :style=\"{\n backgroundColor:\n activeFeature === feature.key\n ? 'var(--tpl-primary-light)'\n : 'transparent',\n }\"\n @click=\"emit('select', feature.key)\"\n >\n <div\n class=\"tpl:mt-0.5 tpl:flex tpl:size-7 tpl:shrink-0 tpl:items-center tpl:justify-center tpl:rounded-[var(--tpl-radius-sm)]\"\n :style=\"{\n backgroundColor:\n activeFeature === feature.key\n ? 'var(--tpl-primary)'\n : 'var(--tpl-bg-active)',\n color:\n activeFeature === feature.key\n ? 'var(--tpl-bg)'\n : 'var(--tpl-text-muted)',\n }\"\n >\n <component :is=\"feature.icon\" :size=\"15\" :stroke-width=\"2\" />\n </div>\n <div class=\"tpl:flex tpl:min-w-0 tpl:flex-col tpl:gap-0.5\">\n <span class=\"tpl:text-sm tpl:font-medium tpl:text-[var(--tpl-text)]\">\n {{ getTitle(feature.key) }}\n </span>\n <span\n class=\"tpl:text-xs tpl:leading-snug tpl:text-[var(--tpl-text-muted)]\"\n >\n {{ getDescription(feature.key) }}\n </span>\n </div>\n </button>\n </div>\n</template>\n\n<style scoped>\n.tpl-ai-feature-menu-item:hover {\n background-color: var(--tpl-bg-hover) !important;\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;EAaA,IAAM,IAAO,GAIP,EAAE,GAAG,MAAW,EAAmB,GAEnC,IAAW,EAAc,GAAe,eAAe,GAEvD,IAAkD;GACtD,WAAW;GACX,oBAAoB;GACpB,SAAS;EACX,GAEM,IAA2D;GAC/D;IAAE,KAAK;IAAW,MAAM;GAAS;GACjC;IAAE,KAAK;IAAoB,MAAM;GAAQ;GACzC;IAAE,KAAK;IAAW,MAAM;GAAY;EACtC,GAEM,IAAW,QACf,EAAY,QAAQ,MAAM,EAAS,iBAAiB,EAAa,EAAE,IAAI,CAAC,CAC1E;EAEA,SAAS,EAAS,GAAwB;GAGxC,OAFI,MAAQ,YAAkB,EAAO,OAAO,cACxC,MAAQ,qBAA2B,EAAO,OAAO,mBAC9C,EAAO,OAAO;EACvB;EAEA,SAAS,EAAe,GAAwB;GAG9C,OAFI,MAAQ,YAAkB,EAAO,OAAO,kBACxC,MAAQ,qBAA2B,EAAO,OAAO,uBAC9C,EAAO,OAAO;EACvB;yBAIE,EA0CM,OA1CN,GA0CM,EAAA,EAAA,EAAA,GAtCJ,EAqCS,GAAA,MAAA,EApCW,EAAA,QAAX,YADT,EAqCS,UAAA;GAnCN,KAAK,EAAQ;GACd,OAAM;GACL,OAAK,EAAA,EAAA,iBAAuC,EAAA,kBAAkB,EAAQ,MAAA,6BAAA,cAAA,CAAA;GAMtE,UAAK,MAAE,EAAI,UAAW,EAAQ,GAAG;MAElC,EAcM,OAAA;GAbJ,OAAM;GACL,OAAK,EAAA;qBAA2C,EAAA,kBAAkB,EAAQ,MAAA,uBAAA;WAA8G,EAAA,kBAAkB,EAAQ,MAAA,kBAAA;;YAWnN,EAA6D,EAA7C,EAAQ,IAAI,GAAA;GAAG,MAAM;GAAK,gBAAc;YAE1D,EASM,OATN,GASM,CARJ,EAEO,QAFP,GAEO,EADF,EAAS,EAAQ,GAAG,CAAA,GAAA,CAAA,GAEzB,EAIO,QAJP,GAIO,EADF,EAAe,EAAQ,GAAG,CAAA,GAAA,CAAA,CAAA,CAAA,CAAA,GAAA,IAAA,CAAA"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { M as e, T as t, f as n, g as r, h as i, it as a, m as o, ot as s, x as c } from "./draggable-D840DIZB.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Bt as l, Mt as u, cn as d, ft as f } from "./features-BSpDuFFR.js";
|
|
3
3
|
//#region src/components/canvas/BlockIssueBadge.vue?vue&type=script&setup=true&lang.ts
|
|
4
4
|
var p = ["title", "aria-label"], m = /* @__PURE__ */ c({
|
|
5
5
|
__name: "BlockIssueBadge",
|
|
6
6
|
props: { blockId: {} },
|
|
7
7
|
setup(c) {
|
|
8
|
-
let m = c, { t: h } =
|
|
8
|
+
let m = c, { t: h } = l(), g = t(d, null), _ = n(() => (g?.issues.value ?? []).filter((e) => e.blockId === m.blockId)), v = n(() => _.value.some((e) => e.severity === "error") ? "error" : _.value.some((e) => e.severity === "warning") ? "warning" : null), y = n(() => v.value === "error" ? h.issues.badgeError : h.issues.badgeWarning);
|
|
9
9
|
return (t, n) => v.value ? (e(), r("span", {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: s(["tpl:absolute tpl:top-1 tpl:right-1 tpl:z-10 tpl:flex tpl:size-5 tpl:items-center tpl:justify-center tpl:rounded-full tpl:bg-[var(--tpl-bg)] tpl:shadow-[var(--tpl-shadow-sm)] tpl:ring-1 tpl:ring-[var(--tpl-border)]", v.value === "error" ? "tpl:text-[var(--tpl-danger)]" : "tpl:text-[var(--tpl-warning)]"]),
|
|
@@ -18,7 +18,7 @@ var p = ["title", "aria-label"], m = /* @__PURE__ */ c({
|
|
|
18
18
|
"stroke-width": 2.25,
|
|
19
19
|
fill: "currentColor",
|
|
20
20
|
stroke: "var(--tpl-bg)"
|
|
21
|
-
})) : (e(), o(a(
|
|
21
|
+
})) : (e(), o(a(f), {
|
|
22
22
|
key: 1,
|
|
23
23
|
size: 14,
|
|
24
24
|
"stroke-width": 2.25,
|
|
@@ -30,4 +30,4 @@ var p = ["title", "aria-label"], m = /* @__PURE__ */ c({
|
|
|
30
30
|
//#endregion
|
|
31
31
|
export { m as default };
|
|
32
32
|
|
|
33
|
-
//# sourceMappingURL=BlockIssueBadge-
|
|
33
|
+
//# sourceMappingURL=BlockIssueBadge-BHEl_Hs7.js.map
|