@templatical/editor 0.8.5 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AiChatSidebar-uhkhnXQd.js → AiChatSidebar-BUKj9n02.js} +4 -4
- package/dist/{AiFeatureMenu-DXNKvXP5.js → AiFeatureMenu-Co14YVJt.js} +3 -3
- package/dist/{BlockIssueBadge-DM-vXeD6.js → BlockIssueBadge-DThKKeub.js} +2 -2
- package/dist/{CloudEditor-BSkPQjwo.js → CloudEditor-CAtw_sFC.js} +217 -216
- package/dist/{CollaboratorBar-CP76Sh6c.js → CollaboratorBar-Bc6q0gB9.js} +2 -2
- package/dist/{CommentsSidebar-_llWQ4VT.js → CommentsSidebar-DiH4R4F0.js} +3 -3
- package/dist/{CountdownBlock-I99sC0C5.js → CountdownBlock-BTPefclD.js} +2 -2
- package/dist/{CountdownToolbar-BUhOUiQ9.js → CountdownToolbar-Dvr2icg-.js} +2 -2
- package/dist/{DesignReferenceSidebar-CfJqJ7l6.js → DesignReferenceSidebar-BP32MgpS.js} +2 -2
- package/dist/{IssuesPanel-4MKZe8yP.js → IssuesPanel-B1LT91IX.js} +2 -2
- package/dist/{ModuleBrowserModal-BFQTm6uY.js → ModuleBrowserModal-CWegFoOA.js} +77 -85
- package/dist/{ModulePreviewCanvas-DeqMpo73.js → ModulePreviewCanvas-D9WUSSRT.js} +2 -2
- package/dist/{NumberWithSuffix-CxMFy_j3.js → NumberWithSuffix-CxUBW_V2.js} +2 -2
- package/dist/{ParagraphEditor-DqomSbW3.js → ParagraphEditor-DrAz2yot.js} +115 -115
- package/dist/{RichTextEditorContent-B_KCY6T1.js → RichTextEditorContent-gR169m1-.js} +4 -4
- package/dist/{SaveModuleDialog-DKcpPeWd.js → SaveModuleDialog-DWidA0c9.js} +6 -6
- package/dist/{SnapshotHistory-Z9RQj53S.js → SnapshotHistory-CIo2Jaw-.js} +4 -4
- package/dist/{TemplateScoringPanel-BIwEwFxD.js → TemplateScoringPanel-seBvvn8O.js} +2 -2
- package/dist/{TestEmailModal-C8DhylO1.js → TestEmailModal-BuCuWp3N.js} +3 -3
- package/dist/{TitleEditor-CgLrn6R3.js → TitleEditor-BmW0uMl7.js} +64 -64
- package/dist/{TplModal-CbwRwmR3.js → TplModal-YFpBaiLj.js} +4 -4
- package/dist/{blockTypeIcons-CccKujXP.js → blockTypeIcons-DCkHXPhx.js} +19 -11
- package/dist/bundle-stats.json +8 -8
- package/dist/cdn/chunks/{AiFeatureMenu-ChNv7XXj.js → AiFeatureMenu-Dayzk2H7.js} +2 -2
- package/dist/cdn/chunks/{AiFeatureMenu-ChNv7XXj.js.map → AiFeatureMenu-Dayzk2H7.js.map} +1 -1
- package/dist/cdn/chunks/{BlockIssueBadge-BovmWgok.js → BlockIssueBadge-D_US2wqo.js} +4 -4
- package/dist/cdn/chunks/{BlockIssueBadge-BovmWgok.js.map → BlockIssueBadge-D_US2wqo.js.map} +1 -1
- package/dist/cdn/chunks/{CloudEditor-CHF_P5OL.js → CloudEditor-CyJItWsK.js} +186 -185
- package/dist/cdn/chunks/{CloudEditor-CHF_P5OL.js.map → CloudEditor-CyJItWsK.js.map} +1 -1
- package/dist/cdn/chunks/{CollaboratorBar-Bjr5YSh0.js → CollaboratorBar-C4CFs5EJ.js} +3 -3
- package/dist/cdn/chunks/{CollaboratorBar-Bjr5YSh0.js.map → CollaboratorBar-C4CFs5EJ.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownBlock-KyzvhjMF.js → CountdownBlock-D6lCXhZA.js} +2 -2
- package/dist/cdn/chunks/{CountdownBlock-KyzvhjMF.js.map → CountdownBlock-D6lCXhZA.js.map} +1 -1
- package/dist/cdn/chunks/{CountdownToolbar-bJtMHGYz.js → CountdownToolbar-BsGUxoRv.js} +3 -3
- package/dist/cdn/chunks/{CountdownToolbar-bJtMHGYz.js.map → CountdownToolbar-BsGUxoRv.js.map} +1 -1
- package/dist/cdn/chunks/{IssuesPanel-DFSYTQXy.js → IssuesPanel-DeHTmRDz.js} +5 -5
- package/dist/cdn/chunks/{IssuesPanel-DFSYTQXy.js.map → IssuesPanel-DeHTmRDz.js.map} +1 -1
- package/dist/cdn/chunks/{ModuleBrowserModal-DS0BGRhZ.js → ModuleBrowserModal-Cgjz4xAz.js} +8 -8
- package/dist/cdn/chunks/ModuleBrowserModal-Cgjz4xAz.js.map +1 -0
- package/dist/cdn/chunks/{ModulePreviewCanvas-Dwn2cA5a.js → ModulePreviewCanvas-CeS9PsAA.js} +2 -2
- package/dist/cdn/chunks/{ModulePreviewCanvas-Dwn2cA5a.js.map → ModulePreviewCanvas-CeS9PsAA.js.map} +1 -1
- package/dist/cdn/chunks/{NumberWithSuffix-BNBeHv0P.js → NumberWithSuffix-Bp-idLCc.js} +2 -2
- package/dist/cdn/chunks/{NumberWithSuffix-BNBeHv0P.js.map → NumberWithSuffix-Bp-idLCc.js.map} +1 -1
- package/dist/cdn/chunks/{ParagraphEditor-C4TrTIOm.js → ParagraphEditor-fM9aFu8T.js} +105 -105
- package/dist/cdn/chunks/ParagraphEditor-fM9aFu8T.js.map +1 -0
- package/dist/cdn/chunks/{RichTextEditorContent-HNFFL4aK.js → RichTextEditorContent-DwNPE5H5.js} +4 -4
- package/dist/cdn/chunks/{RichTextEditorContent-HNFFL4aK.js.map → RichTextEditorContent-DwNPE5H5.js.map} +1 -1
- package/dist/cdn/chunks/{SaveModuleDialog-CbHqqeID.js → SaveModuleDialog-BrtDXzIz.js} +4 -4
- package/dist/cdn/chunks/SaveModuleDialog-BrtDXzIz.js.map +1 -0
- package/dist/cdn/chunks/TitleEditor-D0rSnye0.js +175 -0
- package/dist/cdn/chunks/TitleEditor-D0rSnye0.js.map +1 -0
- package/dist/cdn/chunks/{blockTypeIcons-BUlgu9JL.js → blockTypeIcons-YOEe5mDE.js} +3 -3
- package/dist/cdn/chunks/{blockTypeIcons-BUlgu9JL.js.map → blockTypeIcons-YOEe5mDE.js.map} +1 -1
- package/dist/{de-ED7c5RpG.js → cdn/chunks/de-CATfXDKV.js} +14 -1
- package/dist/cdn/chunks/{de-ED7c5RpG.js.map → de-CATfXDKV.js.map} +1 -1
- package/dist/cdn/chunks/{en-ivilDUn0.js → en-CwCAgYL5.js} +13 -2
- package/dist/cdn/chunks/{en-ivilDUn0.js.map → en-CwCAgYL5.js.map} +1 -1
- package/dist/cdn/chunks/{extensions-DK_lVs7A.js → extensions-GYsbQFPr.js} +25 -22
- package/dist/cdn/chunks/extensions-GYsbQFPr.js.map +1 -0
- package/dist/cdn/chunks/{features-LiilsBqW.js → features-D-2kVhHY.js} +1232 -1189
- package/dist/cdn/chunks/features-D-2kVhHY.js.map +1 -0
- package/dist/cdn/chunks/{icons-Bn2SIR30.js → icons-fZoyKV_s.js} +2 -2
- package/dist/cdn/chunks/{icons-Bn2SIR30.js.map → icons-fZoyKV_s.js.map} +1 -1
- package/dist/cdn/chunks/{media-library-Bb2PavAd.js → media-library-CO2WOETY.js} +240 -240
- package/dist/cdn/chunks/{media-library-Bb2PavAd.js.map → media-library-CO2WOETY.js.map} +1 -1
- package/dist/{pt-BR-B5tm2iBl.js → cdn/chunks/pt-BR-D3Mg7AKe.js} +14 -1
- package/dist/cdn/chunks/{pt-BR-B5tm2iBl.js.map → pt-BR-D3Mg7AKe.js.map} +1 -1
- package/dist/cdn/chunks/{quality-Bpj6kNxR.js → quality-BxPiS-wv.js} +464 -464
- package/dist/cdn/chunks/{quality-Bpj6kNxR.js.map → quality-BxPiS-wv.js.map} +1 -1
- package/dist/cdn/chunks/{renderer-CYYyu-Di.js → renderer-7z2t_bYQ.js} +68 -68
- package/dist/cdn/chunks/{renderer-CYYyu-Di.js.map → renderer-7z2t_bYQ.js.map} +1 -1
- package/dist/cdn/chunks/{src-CQjZnxvw.js → src-ftxPuuQh.js} +4 -4
- package/dist/cdn/chunks/{src-CQjZnxvw.js.map → src-ftxPuuQh.js.map} +1 -1
- package/dist/cdn/chunks/{styles-5g8XOS68.js → styles-o0HIrw9F.js} +877 -622
- package/dist/cdn/chunks/styles-o0HIrw9F.js.map +1 -0
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +102 -101
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{cdn/chunks/de-ED7c5RpG.js → de-CATfXDKV.js} +12 -3
- package/dist/{dist-HO0vjY5Z.js → dist-CNLAS2v2.js} +130 -124
- package/dist/{en-ivilDUn0.js → en-CwCAgYL5.js} +12 -1
- package/dist/{extensions-DeNHyWwh.js → extensions-Mj2-D8uK.js} +6 -3
- package/dist/{keys-B8K7Z7Ef.js → keys-BiQlvx51.js} +3 -3
- package/dist/{cdn/chunks/pt-BR-B5tm2iBl.js → pt-BR-D3Mg7AKe.js} +12 -3
- package/dist/style.css +1 -1
- package/dist/{styles-Bgqv7rLA.js → styles-CJtcKmsx.js} +857 -601
- package/dist/templatical-editor.js +104 -103
- package/dist/{useCloudI18n-DFzVgYhJ.js → useCloudI18n-DKWJg6rJ.js} +1 -1
- package/dist/{useEditorCore-CaOVDL_m.js → useEditorCore-CEkf_VWX.js} +662 -632
- package/dist/{useI18n-CBbStVlD.js → useI18n-Besvmtxy.js} +1 -1
- package/dist/useMergeTag-WNzaCpXR.js +44 -0
- package/dist/{usePopoverRoot-62PlZQQ3.js → usePopoverRoot-CKt956u-.js} +1 -1
- package/package.json +7 -7
- package/dist/cdn/chunks/ModuleBrowserModal-DS0BGRhZ.js.map +0 -1
- package/dist/cdn/chunks/ParagraphEditor-C4TrTIOm.js.map +0 -1
- package/dist/cdn/chunks/SaveModuleDialog-CbHqqeID.js.map +0 -1
- package/dist/cdn/chunks/TitleEditor-gr-eBUq_.js +0 -175
- package/dist/cdn/chunks/TitleEditor-gr-eBUq_.js.map +0 -1
- package/dist/cdn/chunks/extensions-DK_lVs7A.js.map +0 -1
- package/dist/cdn/chunks/features-LiilsBqW.js.map +0 -1
- package/dist/cdn/chunks/styles-5g8XOS68.js.map +0 -1
- package/dist/useMergeTag-RWsgUcSh.js +0 -34
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as e, M as t, b as n, d as r, f as i, h as a, l as o, m as s, ot as c, p as l, rt as u, st as d } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import "./useEditorCore-
|
|
2
|
+
import "./useEditorCore-CEkf_VWX.js";
|
|
3
3
|
import { t as f } from "./createLucideIcon-XgXOJ05E.js";
|
|
4
|
-
import { n as p } from "./useCloudI18n-
|
|
4
|
+
import { n as p } from "./useCloudI18n-DKWJg6rJ.js";
|
|
5
5
|
import { t as m } from "./readableTextColor-f8Kykfnh.js";
|
|
6
6
|
var h = f("wifi-off", [
|
|
7
7
|
["path", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { A as e, B as t, E as n, L as r, M as i, X as a, _ as ee, a as o, at as s, b as c, d as l, f as u, h as d, l as f, m as p, ot as te, p as m, rt as h, st as g, t as _, v, z as y } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import {
|
|
3
|
-
import { t as ae } from "./useI18n-
|
|
2
|
+
import { j as b, l as ne, p as re, r as ie } from "./keys-BiQlvx51.js";
|
|
3
|
+
import { t as ae } from "./useI18n-Besvmtxy.js";
|
|
4
4
|
import { t as x } from "./createLucideIcon-XgXOJ05E.js";
|
|
5
5
|
import { t as oe } from "./check-ChQyfxJ3.js";
|
|
6
6
|
import { t as se } from "./chevron-down-DJjo0jSV.js";
|
|
@@ -10,7 +10,7 @@ import { t as w } from "./send-BhbhbIFT.js";
|
|
|
10
10
|
import { t as T } from "./trash-2-BpY5BCLT.js";
|
|
11
11
|
import { t as E } from "./x-rcnxRG8Y.js";
|
|
12
12
|
import { t as D } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
13
|
-
import { n as ce } from "./useCloudI18n-
|
|
13
|
+
import { n as ce } from "./useCloudI18n-DKWJg6rJ.js";
|
|
14
14
|
import { t as le } from "./formatRelativeTime-CyDg5cDD.js";
|
|
15
15
|
var ue = x("chevron-up", [["path", {
|
|
16
16
|
d: "m18 15-6-6-6 6",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as e } from "./rolldown-runtime-Dy4uBu1J.js";
|
|
2
2
|
import { A as t, M as n, X as r, b as i, d as a, f as o, h as s, l as c, m as l, ot as u, rt as d, st as f } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
3
|
-
import {
|
|
4
|
-
import { t as m } from "./useI18n-
|
|
3
|
+
import { s as p } from "./dist-CNLAS2v2.js";
|
|
4
|
+
import { t as m } from "./useI18n-Besvmtxy.js";
|
|
5
5
|
//#region src/components/blocks/CountdownBlock.vue?vue&type=script&setup=true&lang.ts
|
|
6
6
|
var h = {
|
|
7
7
|
key: 0,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { A as e, M as t, _ as n, at as r, b as i, d as a, f as o, h as s, l as c, p as l, rt as u, st as d, v as f, z as p } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import { t as m } from "./useI18n-
|
|
2
|
+
import { t as m } from "./useI18n-Besvmtxy.js";
|
|
3
3
|
import { f as h } from "./styleConstants-lGobwiLH.js";
|
|
4
|
-
import { i as g, n as _, r as v, t as y } from "./NumberWithSuffix-
|
|
4
|
+
import { i as g, n as _, r as v, t as y } from "./NumberWithSuffix-CxUBW_V2.js";
|
|
5
5
|
//#region src/components/toolbar/CheckboxItem.vue?vue&type=script&setup=true&lang.ts
|
|
6
6
|
var b = { class: "tpl:flex tpl:cursor-pointer tpl:items-center tpl:gap-2 tpl:text-[12px] tpl:text-[var(--tpl-text)]" }, x = ["checked"], S = /* @__PURE__ */ i({
|
|
7
7
|
__name: "CheckboxItem",
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { A as e, B as t, D as n, L as r, X as i, _ as a, a as ee, at as te, b as o, d as ne, f as s, h as c, m as l, ot as u, p as re, rt as d, st as f, t as ie, v as p, z as ae } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
2
|
import "./timeouts-Bmi_yePw.js";
|
|
3
|
-
import {
|
|
3
|
+
import { j as m, p as oe, r as h } from "./keys-BiQlvx51.js";
|
|
4
4
|
import { t as g } from "./createLucideIcon-XgXOJ05E.js";
|
|
5
5
|
import { t as se } from "./circle-alert-CPH6l3Lc.js";
|
|
6
6
|
import { t as _ } from "./image-up-CPBCOMit.js";
|
|
7
7
|
import { t as v } from "./x-rcnxRG8Y.js";
|
|
8
8
|
import { t as ce } from "./LoadingTrack-xCOLUR3o.js";
|
|
9
9
|
import { t as y } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
10
|
-
import { n as le } from "./useCloudI18n-
|
|
10
|
+
import { n as le } from "./useCloudI18n-DKWJg6rJ.js";
|
|
11
11
|
import { u as ue } from "./cloud-VxYMtfXC.js";
|
|
12
12
|
var de = g("file-image", [
|
|
13
13
|
["path", {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { A as e, F as t, M as n, _ as r, at as i, b as a, d as o, f as s, h as c, l, m as u, p as d, rt as f, st as p, v as m, w as h } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import {
|
|
3
|
-
import { t as v } from "./useI18n-
|
|
2
|
+
import { D as g, p as _ } from "./keys-BiQlvx51.js";
|
|
3
|
+
import { t as v } from "./useI18n-Besvmtxy.js";
|
|
4
4
|
import { t as y } from "./createLucideIcon-XgXOJ05E.js";
|
|
5
5
|
import { t as b } from "./circle-alert-CPH6l3Lc.js";
|
|
6
6
|
import { t as x } from "./info-DIY9mguM.js";
|
|
@@ -1,22 +1,14 @@
|
|
|
1
1
|
import { A as e, B as t, F as n, L as r, M as i, X as a, a as ee, b as o, c as s, d as c, f as l, h as u, i as te, l as d, m as ne, ot as re, p as f, rt as p, st as m, v as h, y as ie, z as ae } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import "./useEditorCore-
|
|
3
|
-
import {
|
|
4
|
-
import { t as
|
|
5
|
-
import { t as v } from "./
|
|
6
|
-
import {
|
|
7
|
-
import { t as
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
|
|
11
|
-
var
|
|
12
|
-
d: "m21 21-4.34-4.34",
|
|
13
|
-
key: "14j7rj"
|
|
14
|
-
}], ["circle", {
|
|
15
|
-
cx: "11",
|
|
16
|
-
cy: "11",
|
|
17
|
-
r: "8",
|
|
18
|
-
key: "4ej97u"
|
|
19
|
-
}]]), pe = {
|
|
2
|
+
import "./useEditorCore-CEkf_VWX.js";
|
|
3
|
+
import { T as oe, j as g, p as se } from "./keys-BiQlvx51.js";
|
|
4
|
+
import { t as ce } from "./useI18n-Besvmtxy.js";
|
|
5
|
+
import { n as le, r as _, t as v } from "./blockTypeIcons-DCkHXPhx.js";
|
|
6
|
+
import { t as ue } from "./trash-2-BpY5BCLT.js";
|
|
7
|
+
import { t as de } from "./x-rcnxRG8Y.js";
|
|
8
|
+
import { n as fe } from "./useCloudI18n-DKWJg6rJ.js";
|
|
9
|
+
import { t as pe } from "./TplModal-YFpBaiLj.js";
|
|
10
|
+
//#region src/cloud/components/ModuleBrowserModal.vue?vue&type=script&setup=true&lang.ts
|
|
11
|
+
var me = {
|
|
20
12
|
role: "dialog",
|
|
21
13
|
"aria-modal": "true",
|
|
22
14
|
"aria-labelledby": "tpl-module-browser-title",
|
|
@@ -26,72 +18,72 @@ var fe = v("search", [["path", {
|
|
|
26
18
|
"box-shadow": "var(--tpl-shadow-xl)",
|
|
27
19
|
"max-height": "90vh"
|
|
28
20
|
}
|
|
29
|
-
},
|
|
21
|
+
}, he = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-b tpl:px-5 tpl:py-4 tpl:border-[var(--tpl-border)]" }, y = {
|
|
30
22
|
id: "tpl-module-browser-title",
|
|
31
23
|
class: "tpl:text-sm tpl:font-semibold tpl:text-[var(--tpl-text)]"
|
|
32
|
-
},
|
|
24
|
+
}, b = ["aria-label"], x = { class: "tpl:flex tpl:min-h-0 tpl:flex-1 tpl:overflow-hidden" }, S = { class: "tpl:flex tpl:w-[300px] tpl:shrink-0 tpl:flex-col tpl:overflow-hidden" }, C = { class: "tpl:px-4 tpl:pt-4 tpl:pb-3" }, w = { class: "tpl:relative" }, T = ["placeholder"], E = { class: "tpl:flex-1 tpl:overflow-y-auto tpl:px-4 tpl:pb-4" }, D = {
|
|
33
25
|
key: 0,
|
|
34
26
|
class: "tpl:flex tpl:flex-col tpl:gap-1"
|
|
35
|
-
},
|
|
27
|
+
}, O = ["aria-pressed", "onClick"], k = { class: "tpl:flex tpl:items-center tpl:gap-2" }, A = { class: "tpl:flex-1 tpl:truncate tpl:text-xs tpl:font-semibold tpl:text-[var(--tpl-text)]" }, j = { 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)]" }, M = { class: "tpl:mt-1 tpl:flex tpl:items-center tpl:gap-1" }, N = {
|
|
36
28
|
key: 0,
|
|
37
29
|
class: "tpl:text-[10px] tpl:text-[var(--tpl-text-dim)]"
|
|
38
|
-
},
|
|
30
|
+
}, P = ["aria-label", "onClick"], F = [
|
|
39
31
|
"aria-label",
|
|
40
32
|
"title",
|
|
41
33
|
"onClick"
|
|
42
|
-
],
|
|
34
|
+
], I = {
|
|
43
35
|
key: 1,
|
|
44
36
|
class: "tpl:flex tpl:flex-col tpl:items-center tpl:justify-center tpl:py-12"
|
|
45
|
-
},
|
|
37
|
+
}, L = { class: "tpl:mt-2 tpl:text-xs tpl:text-[var(--tpl-text-dim)]" }, R = { class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-hidden tpl:border-l tpl:border-[var(--tpl-border)]" }, ge = {
|
|
46
38
|
key: 0,
|
|
47
39
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:overflow-hidden"
|
|
48
40
|
}, _e = { class: "tpl:flex-1 tpl:overflow-y-auto tpl:p-4" }, ve = {
|
|
49
41
|
key: 1,
|
|
50
42
|
class: "tpl:flex tpl:flex-1 tpl:flex-col tpl:items-center tpl:justify-center tpl:px-4"
|
|
51
|
-
}, ye = { class: "tpl:mt-2 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]" }, be = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-t tpl:px-5 tpl:py-3 tpl:border-[var(--tpl-border)]" }, xe = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Se = { class: "tpl:shrink-0 tpl:text-xs tpl:text-[var(--tpl-text-dim)]" }, Ce = ["value"], we = { class: "tpl:flex tpl:gap-2" }, Te = ["disabled"],
|
|
43
|
+
}, ye = { class: "tpl:mt-2 tpl:text-center tpl:text-xs tpl:text-[var(--tpl-text-dim)]" }, be = { class: "tpl:flex tpl:items-center tpl:justify-between tpl:border-t tpl:px-5 tpl:py-3 tpl:border-[var(--tpl-border)]" }, xe = { class: "tpl:flex tpl:items-center tpl:gap-2" }, Se = { class: "tpl:shrink-0 tpl:text-xs tpl:text-[var(--tpl-text-dim)]" }, Ce = ["value"], we = { class: "tpl:flex tpl:gap-2" }, Te = ["disabled"], z = /* @__PURE__ */ o({
|
|
52
44
|
__name: "ModuleBrowserModal",
|
|
53
45
|
props: { visible: { type: Boolean } },
|
|
54
46
|
emits: ["close", "insert"],
|
|
55
|
-
setup(o, { emit:
|
|
56
|
-
let
|
|
57
|
-
let e =
|
|
58
|
-
if (!
|
|
59
|
-
let t =
|
|
47
|
+
setup(o, { emit: z }) {
|
|
48
|
+
let Ee = o, B = z, De = ie(() => import("./ModulePreviewCanvas-D9WUSSRT.js")), { t: Oe } = ce(), { t: V } = fe(), H = g(oe, "ModuleBrowserModal"), U = g(se, "ModuleBrowserModal"), W = a(""), G = a(null), K = a(null), q = a("end"), J = c(() => {
|
|
49
|
+
let e = H.modules.value;
|
|
50
|
+
if (!W.value) return e;
|
|
51
|
+
let t = W.value.toLowerCase();
|
|
60
52
|
return e.filter((e) => e.name.toLowerCase().includes(t));
|
|
61
|
-
}),
|
|
53
|
+
}), Y = c(() => G.value ? H.modules.value.find((e) => e.id === G.value) ?? null : null), X = c(() => {
|
|
62
54
|
let e = [{
|
|
63
55
|
value: "beginning",
|
|
64
|
-
label:
|
|
65
|
-
}], t =
|
|
56
|
+
label: V.modules.insertAtBeginning
|
|
57
|
+
}], t = U.content.value.blocks;
|
|
66
58
|
for (let n = 0; n < t.length; n++) {
|
|
67
|
-
let r = t[n], i = r.type, a =
|
|
59
|
+
let r = t[n], i = r.type, a = Oe.blocks[i] ?? r.type;
|
|
68
60
|
e.push({
|
|
69
61
|
value: r.id,
|
|
70
|
-
label:
|
|
62
|
+
label: V.modules.insertAfterBlock.replace("{block}", `${a} ${n + 1}`)
|
|
71
63
|
});
|
|
72
64
|
}
|
|
73
65
|
return e.push({
|
|
74
66
|
value: "end",
|
|
75
|
-
label:
|
|
67
|
+
label: V.modules.insertAtEnd
|
|
76
68
|
}), e;
|
|
77
69
|
}), ke = c(() => {
|
|
78
|
-
if (
|
|
79
|
-
if (
|
|
80
|
-
let e =
|
|
70
|
+
if (q.value === "end") return;
|
|
71
|
+
if (q.value === "beginning") return 0;
|
|
72
|
+
let e = U.content.value.blocks.findIndex((e) => e.id === q.value);
|
|
81
73
|
if (e !== -1) return e + 1;
|
|
82
74
|
});
|
|
83
|
-
r(() =>
|
|
75
|
+
r(() => Ee.visible, (e) => {
|
|
84
76
|
if (e) {
|
|
85
|
-
|
|
86
|
-
let e =
|
|
87
|
-
e ?
|
|
77
|
+
W.value = "", G.value = null, K.value = null;
|
|
78
|
+
let e = U.state.selectedBlockId;
|
|
79
|
+
e ? q.value = U.content.value.blocks.findIndex((t) => t.id === e) === -1 ? "end" : e : q.value = "end";
|
|
88
80
|
}
|
|
89
81
|
});
|
|
90
82
|
function Ae(e) {
|
|
91
83
|
let t = [], n = /* @__PURE__ */ new Set();
|
|
92
|
-
for (let r of e.content) if (!n.has(r.type) &&
|
|
84
|
+
for (let r of e.content) if (!n.has(r.type) && v[r.type] && (n.add(r.type), t.push({
|
|
93
85
|
type: r.type,
|
|
94
|
-
icon:
|
|
86
|
+
icon: v[r.type]
|
|
95
87
|
})), t.length >= 5) break;
|
|
96
88
|
return t;
|
|
97
89
|
}
|
|
@@ -101,106 +93,106 @@ var fe = v("search", [["path", {
|
|
|
101
93
|
}
|
|
102
94
|
async function je(e) {
|
|
103
95
|
try {
|
|
104
|
-
await
|
|
96
|
+
await H.deleteModule(e), G.value === e && (G.value = null);
|
|
105
97
|
} finally {
|
|
106
|
-
|
|
98
|
+
K.value = null;
|
|
107
99
|
}
|
|
108
100
|
}
|
|
109
101
|
function Q() {
|
|
110
|
-
|
|
102
|
+
Y.value && B("insert", Y.value, ke.value);
|
|
111
103
|
}
|
|
112
104
|
function $() {
|
|
113
|
-
|
|
105
|
+
B("close");
|
|
114
106
|
}
|
|
115
107
|
function Me(e) {
|
|
116
|
-
e.key === "Escape" && $(), e.key === "Enter" &&
|
|
108
|
+
e.key === "Escape" && $(), e.key === "Enter" && Y.value && (e.preventDefault(), Q());
|
|
117
109
|
}
|
|
118
|
-
return (r, a) => (e(), f(
|
|
110
|
+
return (r, a) => (e(), f(pe, {
|
|
119
111
|
visible: o.visible,
|
|
120
112
|
onClose: $,
|
|
121
113
|
onKeydown: Me
|
|
122
114
|
}, {
|
|
123
|
-
default: ae(() => [l("div",
|
|
124
|
-
l("div",
|
|
125
|
-
"aria-label": p(
|
|
115
|
+
default: ae(() => [l("div", me, [
|
|
116
|
+
l("div", he, [l("h3", y, m(p(V).modules.browse), 1), l("button", {
|
|
117
|
+
"aria-label": p(V).modules.close,
|
|
126
118
|
class: "tpl:cursor-pointer tpl:rounded-md tpl:border-none tpl:bg-transparent tpl:p-1 tpl:transition-colors tpl:duration-100 tpl:text-[var(--tpl-text-dim)]",
|
|
127
119
|
onClick: $
|
|
128
|
-
}, [h(p(
|
|
120
|
+
}, [h(p(de), {
|
|
129
121
|
size: 16,
|
|
130
122
|
"stroke-width": 2
|
|
131
|
-
})], 8,
|
|
132
|
-
l("div",
|
|
123
|
+
})], 8, b)]),
|
|
124
|
+
l("div", x, [l("div", S, [l("div", C, [l("div", w, [h(p(le), {
|
|
133
125
|
size: 14,
|
|
134
126
|
"stroke-width": 2,
|
|
135
127
|
class: "tpl:pointer-events-none tpl:absolute tpl:left-3 tpl:top-1/2 tpl:-translate-y-1/2 tpl:text-[var(--tpl-text-dim)]"
|
|
136
128
|
}), t(l("input", {
|
|
137
|
-
"onUpdate:modelValue": a[0] ||= (e) =>
|
|
129
|
+
"onUpdate:modelValue": a[0] ||= (e) => W.value = e,
|
|
138
130
|
type: "text",
|
|
139
|
-
placeholder: p(
|
|
131
|
+
placeholder: p(V).modules.search,
|
|
140
132
|
class: "tpl:h-9 tpl:w-full tpl:rounded-md tpl:border tpl:pl-9 tpl:pr-3 tpl:text-sm tpl:outline-none tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]"
|
|
141
|
-
}, null, 8,
|
|
133
|
+
}, null, 8, T), [[ee, W.value]])])]), l("div", E, [J.value.length > 0 ? (e(), u("div", D, [(e(!0), u(d, null, i(J.value, (t) => (e(), u("button", {
|
|
142
134
|
key: t.id,
|
|
143
135
|
type: "button",
|
|
144
|
-
"aria-pressed":
|
|
136
|
+
"aria-pressed": G.value === t.id,
|
|
145
137
|
class: "tpl:group/card tpl:w-full tpl:cursor-pointer tpl:rounded-[var(--tpl-radius-md)] tpl:border tpl:bg-transparent tpl:px-3 tpl:py-2 tpl:text-left tpl:transition-all tpl:duration-[120ms]",
|
|
146
138
|
style: re({
|
|
147
|
-
borderColor:
|
|
148
|
-
backgroundColor:
|
|
139
|
+
borderColor: G.value === t.id ? "var(--tpl-primary)" : "var(--tpl-border)",
|
|
140
|
+
backgroundColor: G.value === t.id ? "var(--tpl-primary-light)" : "transparent"
|
|
149
141
|
}),
|
|
150
|
-
onClick: (e) =>
|
|
151
|
-
}, [l("div",
|
|
142
|
+
onClick: (e) => G.value = t.id
|
|
143
|
+
}, [l("div", k, [l("span", A, m(t.name), 1), l("span", j, m(p(V).modules.blockCount.replace("{count}", String(t.content.length))), 1)]), l("div", M, [
|
|
152
144
|
(e(!0), u(d, null, i(Ae(t), (t) => (e(), f(n(t.icon), {
|
|
153
145
|
key: t.type,
|
|
154
146
|
size: 14,
|
|
155
147
|
"stroke-width": 1.5,
|
|
156
148
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
157
149
|
}))), 128)),
|
|
158
|
-
Z(t) > 0 ? (e(), u("span",
|
|
159
|
-
|
|
150
|
+
Z(t) > 0 ? (e(), u("span", N, " +" + m(Z(t)), 1)) : ne("", !0),
|
|
151
|
+
K.value === t.id ? (e(), u("button", {
|
|
160
152
|
key: 1,
|
|
161
|
-
"aria-label": p(
|
|
153
|
+
"aria-label": p(V).modules.deleteConfirm,
|
|
162
154
|
class: "tpl:ml-auto tpl:cursor-pointer tpl:rounded-md tpl:border tpl:px-2 tpl:py-0.5 tpl:text-[10px] tpl:font-medium tpl:transition-colors tpl:duration-100 tpl:border-[var(--tpl-danger)] tpl:text-[var(--tpl-danger)]",
|
|
163
155
|
style: { "background-color": "transparent" },
|
|
164
156
|
onClick: s((e) => je(t.id), ["stop"])
|
|
165
|
-
}, m(p(
|
|
157
|
+
}, m(p(V).modules.deleteConfirm), 9, P)) : (e(), u("button", {
|
|
166
158
|
key: 2,
|
|
167
159
|
class: "tpl-module-delete-btn tpl:ml-auto tpl:cursor-pointer tpl:rounded-md tpl:border-none tpl:bg-transparent tpl:p-0.5 tpl:transition-colors tpl:duration-100 tpl:text-[var(--tpl-text-dim)]",
|
|
168
|
-
"aria-label": p(
|
|
169
|
-
title: p(
|
|
170
|
-
onClick: s((e) =>
|
|
171
|
-
}, [h(p(
|
|
160
|
+
"aria-label": p(V).modules.delete,
|
|
161
|
+
title: p(V).modules.delete,
|
|
162
|
+
onClick: s((e) => K.value = t.id, ["stop"])
|
|
163
|
+
}, [h(p(ue), {
|
|
172
164
|
size: 12,
|
|
173
165
|
"stroke-width": 1.5
|
|
174
|
-
})], 8,
|
|
175
|
-
])], 12,
|
|
166
|
+
})], 8, F))
|
|
167
|
+
])], 12, O))), 128))])) : (e(), u("div", I, [h(p(_), {
|
|
176
168
|
size: 32,
|
|
177
169
|
"stroke-width": 1,
|
|
178
170
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
179
|
-
}), l("p",
|
|
171
|
+
}), l("p", L, m(W.value ? p(V).modules.noModules : p(V).modules.noModulesHint), 1)]))])]), l("div", R, [Y.value ? (e(), u("div", ge, [l("div", _e, [h(p(De), { blocks: Y.value.content }, null, 8, ["blocks"])])])) : (e(), u("div", ve, [h(p(_), {
|
|
180
172
|
size: 32,
|
|
181
173
|
"stroke-width": 1,
|
|
182
174
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
183
|
-
}), l("p", ye, m(p(
|
|
184
|
-
l("div", be, [l("div", xe, [l("label", Se, m(p(
|
|
185
|
-
"onUpdate:modelValue": a[1] ||= (e) =>
|
|
175
|
+
}), l("p", ye, m(p(V).modules.selectToPreview), 1)]))])]),
|
|
176
|
+
l("div", be, [l("div", xe, [l("label", Se, m(p(V).modules.insertPosition), 1), t(l("select", {
|
|
177
|
+
"onUpdate:modelValue": a[1] ||= (e) => q.value = e,
|
|
186
178
|
class: "tpl:h-7 tpl:max-w-[220px] tpl:rounded-md tpl:border tpl:px-2 tpl:text-xs tpl:outline-none tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]"
|
|
187
|
-
}, [(e(!0), u(d, null, i(
|
|
179
|
+
}, [(e(!0), u(d, null, i(X.value, (t) => (e(), u("option", {
|
|
188
180
|
key: t.value,
|
|
189
181
|
value: t.value
|
|
190
|
-
}, m(t.label), 9, Ce))), 128))], 512), [[te,
|
|
182
|
+
}, m(t.label), 9, Ce))), 128))], 512), [[te, q.value]])]), l("div", we, [l("button", {
|
|
191
183
|
type: "button",
|
|
192
184
|
class: "tpl:cursor-pointer tpl:rounded-md tpl:border tpl:px-3 tpl:py-1.5 tpl:text-sm tpl:font-medium tpl:shadow-xs tpl:transition-all tpl:duration-150 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text)] tpl:bg-[var(--tpl-bg)]",
|
|
193
185
|
onClick: $
|
|
194
|
-
}, m(p(
|
|
186
|
+
}, m(p(V).modules.close), 1), l("button", {
|
|
195
187
|
type: "button",
|
|
196
188
|
class: "tpl:cursor-pointer tpl:rounded-md tpl:px-3 tpl:py-1.5 tpl:text-sm tpl:font-medium tpl:shadow-xs tpl:transition-all tpl:duration-150 tpl:hover:opacity-90 tpl:disabled:cursor-not-allowed tpl:disabled:opacity-50 tpl:bg-[var(--tpl-primary)] tpl:text-[var(--tpl-bg)]",
|
|
197
|
-
disabled: !
|
|
189
|
+
disabled: !Y.value,
|
|
198
190
|
onClick: Q
|
|
199
|
-
}, m(p(
|
|
191
|
+
}, m(p(V).modules.insert), 9, Te)])])
|
|
200
192
|
])]),
|
|
201
193
|
_: 1
|
|
202
194
|
}, 8, ["visible"]));
|
|
203
195
|
}
|
|
204
196
|
});
|
|
205
197
|
//#endregion
|
|
206
|
-
export {
|
|
198
|
+
export { z as default };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { A as e, F as t, M as n, P as r, b as i, d as a, f as o, h as s, l as c, ot as l, p as u, rt as d, w as f } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import { N as p, _ as m, a as h, f as g, g as _, h as v, i as y, m as b, n as x, p as S, r as C, u as w, v as T, y as E } from "./useEditorCore-
|
|
3
|
-
import { o as D } from "./keys-
|
|
2
|
+
import { N as p, _ as m, a as h, f as g, g as _, h as v, i as y, m as b, n as x, p as S, r as C, u as w, v as T, y as E } from "./useEditorCore-CEkf_VWX.js";
|
|
3
|
+
import { o as D } from "./keys-BiQlvx51.js";
|
|
4
4
|
//#region src/components/blocks/PreviewSectionBlock.vue?vue&type=script&setup=true&lang.ts
|
|
5
5
|
var O = { class: "tpl:w-full" }, k = { class: "tpl:flex tpl:gap-0" }, A = /* @__PURE__ */ i({
|
|
6
6
|
name: "PreviewSectionBlock",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { A as e, F as t, M as n, N as r, X as i, at as a, b as o, d as s, f as c, h as l, l as u, m as d, ot as f, p, rt as m, s as h, st as g, t as ee, v as _, z as te } from "./vue.runtime.esm-bundler-BDSGA5hA.js";
|
|
2
|
-
import { t as v } from "./dist-
|
|
3
|
-
import { t as ne } from "./useI18n-
|
|
2
|
+
import { t as v } from "./dist-CNLAS2v2.js";
|
|
3
|
+
import { t as ne } from "./useI18n-Besvmtxy.js";
|
|
4
4
|
import { h as y, i as b, m as x, p as S, u as C } from "./styleConstants-lGobwiLH.js";
|
|
5
5
|
//#region ../../node_modules/.pnpm/vanilla-colorful@0.7.2/node_modules/vanilla-colorful/lib/utils/math.js
|
|
6
6
|
var w = (e, t = 0, n = 1) => e > n ? n : e < t ? t : e, T = (e, t = 0, n = 10 ** t) => Math.round(n * e) / n;
|