@templatical/editor 0.0.6 → 0.1.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/LICENSE +56 -0
- package/README.md +69 -0
- package/dist/{AiChatSidebar-CNhSl_ty.js → AiChatSidebar-DgAjDWO1.js} +68 -68
- package/dist/{AiFeatureMenu-BFVsjUJY.js → AiFeatureMenu-j6oaiRVi.js} +25 -25
- package/dist/{CloudEditor-Bz5Xkxej.js → CloudEditor-yCOkIkZ-.js} +428 -437
- package/dist/{CollaboratorBar-D2Gu5Xj2.js → CollaboratorBar-CWVdp2Y6.js} +23 -23
- package/dist/CommentsSidebar-CSPHhbQH.js +439 -0
- package/dist/CountdownBlock-DK6P_RaQ.js +92 -0
- package/dist/CountdownToolbar-Dv-Sz4ui.js +210 -0
- package/dist/{DesignReferenceSidebar-u2tKSQK0.js → DesignReferenceSidebar-D7zfvux6.js} +58 -58
- package/dist/LoadingTrack-Cdz2SSq9.js +10 -0
- package/dist/ModuleBrowserModal-BLYuCZht.js +205 -0
- package/dist/ModulePreviewCanvas-CHYqP6K3.js +106 -0
- package/dist/NumberWithSuffix-D-5-AZc3.js +424 -0
- package/dist/{ParagraphEditor-CYrzYJO5.js → ParagraphEditor-DivLBNWv.js} +237 -236
- package/dist/{RichTextEditorContent-BeqlWlWB.js → RichTextEditorContent-G1lXgVJR.js} +42 -42
- package/dist/{SaveModuleDialog-Kde6X13X.js → SaveModuleDialog-DGVfiOmE.js} +29 -29
- package/dist/{SnapshotHistory-B3EfIcLW.js → SnapshotHistory-DM__MqSu.js} +38 -38
- package/dist/{TemplateScoringPanel-D2vCRGgx.js → TemplateScoringPanel-CW13Tlol.js} +80 -80
- package/dist/{TestEmailModal-Egk0DFDf.js → TestEmailModal-B8bYqWCY.js} +28 -28
- package/dist/TitleEditor-4Jrp3C4m.js +167 -0
- package/dist/{TplModal-BCruYWks.js → TplModal-BkoIz0oz.js} +14 -14
- package/dist/{_plugin-vue_export-helper-5TQrnOhO.js → _plugin-vue_export-helper-OO6pH1Dh.js} +11 -11
- package/dist/{blockTypeIcons-rW4BUUNC.js → blockTypeIcons-4AS3CvXn.js} +2 -2
- package/dist/cdn/chunks/{AiFeatureMenu-Dcbshcfu.js → AiFeatureMenu-BcHyzTQy.js} +4 -4
- package/dist/cdn/chunks/{AiFeatureMenu-Dcbshcfu.js.map → AiFeatureMenu-BcHyzTQy.js.map} +1 -1
- package/dist/cdn/chunks/{CloudEditor-Bca3RyBW.js → CloudEditor-TaEZq-YW.js} +179 -188
- package/dist/cdn/chunks/CloudEditor-TaEZq-YW.js.map +1 -0
- package/dist/cdn/chunks/{CollaboratorBar-sToKJfHi.js → CollaboratorBar-DbC5-3If.js} +4 -4
- package/dist/cdn/chunks/{CollaboratorBar-sToKJfHi.js.map → CollaboratorBar-DbC5-3If.js.map} +1 -1
- package/dist/cdn/chunks/CountdownBlock-CfPmCQ7j.js +93 -0
- package/dist/cdn/chunks/CountdownBlock-CfPmCQ7j.js.map +1 -0
- package/dist/cdn/chunks/CountdownToolbar-CB0EVxwN.js +212 -0
- package/dist/cdn/chunks/CountdownToolbar-CB0EVxwN.js.map +1 -0
- package/dist/cdn/chunks/{ModuleBrowserModal-BNhwXbWw.js → ModuleBrowserModal-Df2fp9dj.js} +7 -7
- package/dist/cdn/chunks/{ModuleBrowserModal-BNhwXbWw.js.map → ModuleBrowserModal-Df2fp9dj.js.map} +1 -1
- package/dist/cdn/chunks/{ModulePreviewCanvas-DylUylPU.js → ModulePreviewCanvas-Dw1OCpvV.js} +19 -19
- package/dist/cdn/chunks/{ModulePreviewCanvas-DylUylPU.js.map → ModulePreviewCanvas-Dw1OCpvV.js.map} +1 -1
- package/dist/cdn/chunks/NumberWithSuffix-BU6ycXyG.js +425 -0
- package/dist/cdn/chunks/NumberWithSuffix-BU6ycXyG.js.map +1 -0
- package/dist/cdn/chunks/{ParagraphEditor-BBw90y_p.js → ParagraphEditor-BMRNg_BX.js} +37 -37
- package/dist/cdn/chunks/{ParagraphEditor-BBw90y_p.js.map → ParagraphEditor-BMRNg_BX.js.map} +1 -1
- package/dist/cdn/chunks/{RichTextEditorContent-DvyIO3nR.js → RichTextEditorContent-BKYY1YMZ.js} +5 -5
- package/dist/cdn/chunks/{RichTextEditorContent-DvyIO3nR.js.map → RichTextEditorContent-BKYY1YMZ.js.map} +1 -1
- package/dist/cdn/chunks/{SaveModuleDialog-DvbSHvhF.js → SaveModuleDialog-D977Tg7t.js} +5 -5
- package/dist/cdn/chunks/{SaveModuleDialog-DvbSHvhF.js.map → SaveModuleDialog-D977Tg7t.js.map} +1 -1
- package/dist/cdn/chunks/{TitleEditor-tS3mgoVr.js → TitleEditor-q9IzNy38.js} +11 -11
- package/dist/cdn/chunks/{TitleEditor-tS3mgoVr.js.map → TitleEditor-q9IzNy38.js.map} +1 -1
- package/dist/cdn/chunks/{blockTypeIcons-DbnbyEQE.js → blockTypeIcons-L0fRc3qs.js} +3 -3
- package/dist/cdn/chunks/{blockTypeIcons-DbnbyEQE.js.map → blockTypeIcons-L0fRc3qs.js.map} +1 -1
- package/dist/cdn/chunks/{de-CgUR_S5I.js → de-3exf7MYE.js} +1 -1
- package/dist/cdn/chunks/{de-CgUR_S5I.js.map → de-3exf7MYE.js.map} +1 -1
- package/dist/cdn/chunks/{de-D8oDPhBD.js → de-C8LxVUsb.js} +1 -1
- package/dist/cdn/chunks/{de-D8oDPhBD.js.map → de-C8LxVUsb.js.map} +1 -1
- package/dist/cdn/chunks/{dist-BUmN5e4r.js → dist-D5g00M8N.js} +6 -2
- package/dist/cdn/chunks/dist-D5g00M8N.js.map +1 -0
- package/dist/cdn/chunks/{draggable-m78lz0gI.js → draggable-Bcb86AsV.js} +5 -5
- package/dist/cdn/chunks/draggable-Bcb86AsV.js.map +1 -0
- package/dist/cdn/chunks/{emojiData-CNNgvDqx.js → emojiData-DUHzsh4j.js} +1 -1
- package/dist/cdn/chunks/{emojiData-CNNgvDqx.js.map → emojiData-DUHzsh4j.js.map} +1 -1
- package/dist/cdn/chunks/{en-HseRPPeK.js → en-BoEycuqw.js} +1 -1
- package/dist/cdn/chunks/{en-HseRPPeK.js.map → en-BoEycuqw.js.map} +1 -1
- package/dist/cdn/chunks/{en-BBmfBDqY.js → en-KNPUKxYp.js} +1 -1
- package/dist/cdn/chunks/{en-BBmfBDqY.js.map → en-KNPUKxYp.js.map} +1 -1
- package/dist/cdn/chunks/{extensions-ClpY3m0W.js → extensions-BZ1POyiv.js} +11 -11
- package/dist/cdn/chunks/{extensions-ClpY3m0W.js.map → extensions-BZ1POyiv.js.map} +1 -1
- package/dist/cdn/chunks/{features-B5dGxWLi.js → features-Ccqmm6-M.js} +549 -627
- package/dist/cdn/chunks/features-Ccqmm6-M.js.map +1 -0
- package/dist/cdn/chunks/{icons-hflTyPmb.js → icons-x53__2GC.js} +8 -8
- package/dist/cdn/chunks/icons-x53__2GC.js.map +1 -0
- package/dist/cdn/chunks/{liquid.browser-BxyRVCKv.js → liquid.browser-CEMn-ZqL.js} +2 -2
- package/dist/cdn/chunks/liquid.browser-CEMn-ZqL.js.map +1 -0
- package/dist/cdn/chunks/{media-library-Dgy-V-JA.js → media-library-DUoQk-w7.js} +97 -97
- package/dist/cdn/chunks/media-library-DUoQk-w7.js.map +1 -0
- package/dist/cdn/chunks/{pusher-D-m2WSdL.js → pusher-DwSQn6BA.js} +2 -2
- package/dist/cdn/chunks/pusher-DwSQn6BA.js.map +1 -0
- package/dist/cdn/chunks/{src-TDwMmqm0.js → src-DskCIAr8.js} +8 -8
- package/dist/cdn/chunks/{src-TDwMmqm0.js.map → src-DskCIAr8.js.map} +1 -1
- package/dist/cdn/chunks/{styleConstants-DFe3I4Op.js → styleConstants-DP1VOca8.js} +1 -1
- package/dist/cdn/chunks/{styleConstants-DFe3I4Op.js.map → styleConstants-DP1VOca8.js.map} +1 -1
- package/dist/cdn/chunks/{styles-hCOCOR6K.js → styles-BIlpNe52.js} +622 -1238
- package/dist/cdn/chunks/styles-BIlpNe52.js.map +1 -0
- package/dist/cdn/chunks/{tiptap-C28NLMX8.js → tiptap-hPC_BgDO.js} +850 -826
- package/dist/cdn/chunks/tiptap-hPC_BgDO.js.map +1 -0
- package/dist/cdn/editor.css +1 -1
- package/dist/cdn/editor.js +92 -97
- package/dist/cdn/editor.js.map +1 -1
- package/dist/{check-B5S-C0bz.js → check-Bff5NzCh.js} +1 -1
- package/dist/{chevron-down-CjsV1T0W.js → chevron-down-Bbv4SJwx.js} +1 -1
- package/dist/{circle-alert-CVTmJHKW.js → circle-alert-Dpr8MgkR.js} +1 -1
- package/dist/{clock-CAjdSHBy.js → clock-raVPKfl4.js} +1 -1
- package/dist/{dist-DJrDTuRr.js → dist-BHgEdO-M.js} +1001 -983
- package/dist/dist-BibwE8Y0.js +5 -0
- package/dist/{dist-DPM-DFvh.js → dist-BnlZ_HwX.js} +340 -340
- package/dist/{dist-BTtKPcd2.js → dist-C9yhcxsf.js} +2 -2
- package/dist/{dist-COguaIvm.js → dist-CGffNO8z.js} +2 -2
- package/dist/dist-CfGpCUSx.js +5 -0
- package/dist/{dist-COOFiBFV.js → dist-Chd-H2S3.js} +5 -5
- package/dist/{dist-DfqLGwSF.js → dist-Cq0OFLMj.js} +2 -2
- package/dist/{dist-B4LTlrAn.js → dist-D42og5Sc.js} +191 -185
- package/dist/{dist-CBr-qhie.js → dist-Owxo48fF.js} +2 -2
- package/dist/{dist-Crqkuf-w.js → dist-UZ8UzVZ-.js} +15 -15
- package/dist/dist-n0PkFNGl.js +314 -0
- package/dist/{dist-DHYuVJ_7.js → dist-skgH9dyo.js} +2 -2
- package/dist/{extensions-C6xp_B7K.js → extensions-DQKaICBH.js} +81 -81
- package/dist/{image-up-vZa1Txr-.js → image-up-B1AEiHCh.js} +1 -1
- package/dist/index.d.ts +17 -6
- package/dist/{keys-C0MQRs8d.js → keys-CIw9mUI2.js} +1 -1
- package/dist/{liquid.browser-C02owkex.js → liquid.browser-Bm53dnK1.js} +1 -1
- package/dist/{loader-circle-DilFjHSk.js → loader-circle-BYeKJ3to.js} +1 -1
- package/dist/{message-circle-Dpcnc2oa.js → message-circle-PhNlI7e7.js} +1 -1
- package/dist/{refresh-cw-4r7rkHHX.js → refresh-cw-DhDYRBDd.js} +1 -1
- package/dist/{rolldown-runtime-gEudmnaM.js → rolldown-runtime-BZGGJVDF.js} +2 -5
- package/dist/{scan-line-684IxPQ0.js → scan-line-Bw8bauvt.js} +1 -1
- package/dist/{send-ChDw64yL.js → send-CJPSzbLO.js} +1 -1
- package/dist/{shield-check-9dhLdyST.js → shield-check-DdEvVYMH.js} +1 -1
- package/dist/{sparkles-Co9fkDcv.js → sparkles-DT_27AYs.js} +1 -1
- package/dist/style.css +2 -0
- package/dist/{styleConstants-RV3eYwkD.js → styleConstants-Dqz9z3aa.js} +6 -45
- package/dist/styles-tcwlvlEB.js +2942 -0
- package/dist/templatical-editor.js +114 -119
- package/dist/text-align-start-4Hx15GUf.js +43 -0
- package/dist/{trash-2-CZkMtjeC.js → trash-2-BY-xp5hg.js} +1 -1
- package/dist/{triangle-alert-Dvt51agD.js → triangle-alert-DG72vdb2.js} +1 -1
- package/dist/useEditorCore-DMH2QpUL.js +8946 -0
- package/dist/{useI18n-D6m7ZUgY.js → useI18n-B8CN2iWs.js} +4 -4
- package/dist/{useMergeTag-CSXcnFBc.js → useMergeTag-Dz_Dx2Jz.js} +3 -3
- package/dist/vue.runtime.esm-bundler-DryoQb-v.js +5775 -0
- package/dist/{x-CU2XZOkQ.js → x-D-7GkO6Z.js} +1 -1
- package/package.json +31 -15
- package/dist/CommentsSidebar-CTeEAZTj.js +0 -439
- package/dist/LoadingTrack--aUassFH.js +0 -10
- package/dist/ModuleBrowserModal-DNxODPlX.js +0 -205
- package/dist/ModulePreviewCanvas-DnGe1Y-2.js +0 -106
- package/dist/TitleEditor-DwUpo4gF.js +0 -167
- package/dist/cdn/chunks/CloudEditor-Bca3RyBW.js.map +0 -1
- package/dist/cdn/chunks/dist-BUmN5e4r.js.map +0 -1
- package/dist/cdn/chunks/draggable-m78lz0gI.js.map +0 -1
- package/dist/cdn/chunks/features-B5dGxWLi.js.map +0 -1
- package/dist/cdn/chunks/icons-hflTyPmb.js.map +0 -1
- package/dist/cdn/chunks/liquid.browser-BxyRVCKv.js.map +0 -1
- package/dist/cdn/chunks/media-library-Dgy-V-JA.js.map +0 -1
- package/dist/cdn/chunks/pusher-D-m2WSdL.js.map +0 -1
- package/dist/cdn/chunks/styles-hCOCOR6K.js.map +0 -1
- package/dist/cdn/chunks/tiptap-C28NLMX8.js.map +0 -1
- package/dist/dist-Ac4o1O4a.js +0 -314
- package/dist/dist-DEJZ9iAU.js +0 -5
- package/dist/dist-DmVOCJjI.js +0 -5
- package/dist/styles-nvxFh6L6.js +0 -3557
- package/dist/templatical-editor.css +0 -2
- package/dist/templatical-editor.umd.cjs +0 -178
- package/dist/useEditorCore-ColJh1ST.js +0 -5695
- /package/dist/cdn/chunks/{_rolldown_dynamic_import_helper-DMEI4TQ3.js → _rolldown_dynamic_import_helper-BRcA6nWq.js} +0 -0
- /package/dist/{de-Dh8ON-dm.js → de-CN0xu_Tp.js} +0 -0
- /package/dist/{emojiData-Qc8mH_zW.js → emojiData-CwKEDxVf.js} +0 -0
- /package/dist/{en-C7IShRSD.js → en-DXvHkaUF.js} +0 -0
- /package/dist/{formatRelativeTime-D8f6NR7i.js → formatRelativeTime-BSpx5DHC.js} +0 -0
- /package/dist/{readableTextColor-B809bF5J.js → readableTextColor-CYCxm1jQ.js} +0 -0
- /package/dist/{timeouts-CmBrLeZA.js → timeouts-BSGxjuUF.js} +0 -0
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { t as
|
|
5
|
-
import { t as
|
|
6
|
-
import {
|
|
7
|
-
import { t as
|
|
8
|
-
import { t as
|
|
9
|
-
import { t as
|
|
10
|
-
import { t as
|
|
11
|
-
import { t as
|
|
12
|
-
import { t as
|
|
13
|
-
import {
|
|
14
|
-
var O =
|
|
1
|
+
import { Ct as e, E as t, L as n, M as r, Ot as i, P as a, S as o, V as s, Y as c, _ as l, b as u, d, g as f, h as p, m, t as ee, tt as h, wt as g, y as _, z as te } from "./vue.runtime.esm-bundler-DryoQb-v.js";
|
|
2
|
+
import { T as v, f as ne, g as re, x as y } from "./keys-CIw9mUI2.js";
|
|
3
|
+
import { t as ie } from "./useI18n-B8CN2iWs.js";
|
|
4
|
+
import { n as b, t as x } from "./_plugin-vue_export-helper-OO6pH1Dh.js";
|
|
5
|
+
import { t as S } from "./chevron-down-Bbv4SJwx.js";
|
|
6
|
+
import { t as C } from "./circle-alert-Dpr8MgkR.js";
|
|
7
|
+
import { n as ae, r as w, t as T } from "./refresh-cw-DhDYRBDd.js";
|
|
8
|
+
import { t as oe } from "./loader-circle-BYeKJ3to.js";
|
|
9
|
+
import { t as E } from "./shield-check-DdEvVYMH.js";
|
|
10
|
+
import { t as D } from "./sparkles-DT_27AYs.js";
|
|
11
|
+
import { t as se } from "./triangle-alert-DG72vdb2.js";
|
|
12
|
+
import { t as ce } from "./x-D-7GkO6Z.js";
|
|
13
|
+
import { t as le } from "./LoadingTrack-Cdz2SSq9.js";
|
|
14
|
+
var O = b("shield-x", [
|
|
15
15
|
["path", {
|
|
16
16
|
d: "M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",
|
|
17
17
|
key: "oel41y"
|
|
@@ -24,7 +24,7 @@ var O = i("shield-x", [
|
|
|
24
24
|
d: "m9.5 9.5 5 5",
|
|
25
25
|
key: "18nt4w"
|
|
26
26
|
}]
|
|
27
|
-
]), k =
|
|
27
|
+
]), k = b("zap", [["path", {
|
|
28
28
|
d: "M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",
|
|
29
29
|
key: "1xq2db"
|
|
30
30
|
}]]);
|
|
@@ -83,12 +83,12 @@ var P = {
|
|
|
83
83
|
}, Ee = {
|
|
84
84
|
key: 3,
|
|
85
85
|
class: "tpl:flex tpl:h-full tpl:flex-col tpl:items-center tpl:justify-center tpl:gap-3 tpl:text-center"
|
|
86
|
-
}, De = { class: "tpl:max-w-[240px] tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Oe = { class: "tpl:m-0 tpl:px-4 tpl:pb-2 tpl:pt-2 tpl:text-center tpl:text-[11px] tpl:text-[var(--tpl-text-dim)]" }, G = /* @__PURE__ */
|
|
86
|
+
}, De = { class: "tpl:max-w-[240px] tpl:text-sm tpl:text-[var(--tpl-text-muted)]" }, Oe = { class: "tpl:m-0 tpl:px-4 tpl:pb-2 tpl:pt-2 tpl:text-center tpl:text-[11px] tpl:text-[var(--tpl-text-dim)]" }, G = /* @__PURE__ */ x(/* @__PURE__ */ o({
|
|
87
87
|
__name: "TemplateScoringPanel",
|
|
88
88
|
props: { visible: { type: Boolean } },
|
|
89
89
|
emits: ["close"],
|
|
90
|
-
setup(
|
|
91
|
-
let
|
|
90
|
+
setup(o, { emit: b }) {
|
|
91
|
+
let x = o, G = b, { t: K } = ie(), q = v(ne, "TemplateScoringPanel"), J = v(y, "TemplateScoringPanel"), Y = t(re, []), X = c({
|
|
92
92
|
spam: !0,
|
|
93
93
|
readability: !0,
|
|
94
94
|
accessibility: !0,
|
|
@@ -104,14 +104,14 @@ var P = {
|
|
|
104
104
|
"bestPractices"
|
|
105
105
|
], Ae = {
|
|
106
106
|
spam: O,
|
|
107
|
-
readability:
|
|
108
|
-
accessibility:
|
|
107
|
+
readability: w,
|
|
108
|
+
accessibility: D,
|
|
109
109
|
bestPractices: k
|
|
110
110
|
};
|
|
111
111
|
function Q() {
|
|
112
112
|
J.score(q.content.value, Y);
|
|
113
113
|
}
|
|
114
|
-
|
|
114
|
+
te(() => x.visible, (e) => {
|
|
115
115
|
e && !J.scoringResult.value && !J.isScoring.value && Q();
|
|
116
116
|
});
|
|
117
117
|
async function je(e) {
|
|
@@ -126,7 +126,7 @@ var P = {
|
|
|
126
126
|
function $() {
|
|
127
127
|
return J.scoringResult.value ? Z.reduce((e, t) => e + (J.scoringResult.value?.categories[t]?.findings.length ?? 0), 0) : 0;
|
|
128
128
|
}
|
|
129
|
-
return (
|
|
129
|
+
return (t, c) => (r(), p(ee, {
|
|
130
130
|
"enter-active-class": "tpl-scoring-slide-enter-active",
|
|
131
131
|
"enter-from-class": "tpl:translate-x-full",
|
|
132
132
|
"enter-to-class": "tpl:translate-x-0",
|
|
@@ -134,118 +134,118 @@ var P = {
|
|
|
134
134
|
"leave-from-class": "tpl:translate-x-0",
|
|
135
135
|
"leave-to-class": "tpl:translate-x-full"
|
|
136
136
|
}, {
|
|
137
|
-
default:
|
|
137
|
+
default: s(() => [o.visible ? (r(), l("div", P, [m("div", F, [m("div", I, [u(h(E), {
|
|
138
138
|
size: 13,
|
|
139
139
|
"stroke-width": 2
|
|
140
|
-
}),
|
|
140
|
+
}), m("span", null, i(h(K).scoring.title), 1)]), m("div", L, [h(J).scoringResult.value && !h(J).isScoring.value ? (r(), l("button", {
|
|
141
141
|
key: 0,
|
|
142
142
|
class: "tpl:rounded-md tpl:p-0.5 tpl:transition-colors tpl:duration-150 tpl:text-[var(--tpl-text-muted)]",
|
|
143
|
-
title:
|
|
144
|
-
onClick:
|
|
145
|
-
}, [
|
|
143
|
+
title: h(K).scoring.rescore,
|
|
144
|
+
onClick: c[0] ||= (e) => Q()
|
|
145
|
+
}, [u(h(T), {
|
|
146
146
|
size: 14,
|
|
147
147
|
"stroke-width": 2
|
|
148
|
-
})], 8, R)) :
|
|
148
|
+
})], 8, R)) : f("", !0), m("button", {
|
|
149
149
|
class: "tpl:rounded-md tpl:p-0.5 tpl:transition-colors tpl:duration-150 tpl:text-[var(--tpl-text-muted)]",
|
|
150
|
-
onClick:
|
|
151
|
-
}, [
|
|
150
|
+
onClick: c[1] ||= (e) => G("close")
|
|
151
|
+
}, [u(h(ce), {
|
|
152
152
|
size: 14,
|
|
153
153
|
"stroke-width": 2
|
|
154
|
-
})])])]),
|
|
155
|
-
|
|
154
|
+
})])])]), m("div", z, [h(J).isScoring.value ? (r(), l("div", B, [m("p", V, i(h(K).scoring.scoring), 1), u(le, { class: "tpl:w-3/4" })])) : h(J).error.value && !h(J).scoringResult.value ? (r(), l("div", H, [
|
|
155
|
+
u(h(C), {
|
|
156
156
|
size: 32,
|
|
157
157
|
"stroke-width": 1.5,
|
|
158
158
|
class: "tpl:text-[var(--tpl-danger)]"
|
|
159
159
|
}),
|
|
160
|
-
|
|
161
|
-
|
|
160
|
+
m("p", U, i(h(K).scoring.error), 1),
|
|
161
|
+
m("button", {
|
|
162
162
|
class: "tpl:mt-2 tpl:inline-flex tpl:items-center tpl:gap-1.5 tpl:rounded-md tpl:border tpl:px-3 tpl:py-1.5 tpl:text-xs tpl:font-medium tpl:transition-all tpl:duration-150 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-text-muted)]",
|
|
163
|
-
onClick:
|
|
164
|
-
}, [
|
|
163
|
+
onClick: c[2] ||= (e) => Q()
|
|
164
|
+
}, [u(h(T), {
|
|
165
165
|
size: 12,
|
|
166
166
|
"stroke-width": 2
|
|
167
|
-
}),
|
|
168
|
-
])) :
|
|
169
|
-
|
|
167
|
+
}), _(" " + i(h(K).scoring.rescore), 1)])
|
|
168
|
+
])) : h(J).scoringResult.value ? (r(), l("div", W, [
|
|
169
|
+
m("div", {
|
|
170
170
|
class: "tpl:flex tpl:flex-col tpl:items-center tpl:gap-2 tpl:rounded-[var(--tpl-radius)] tpl:p-5",
|
|
171
|
-
style:
|
|
171
|
+
style: g({ backgroundColor: h(j)(h(J).scoringResult.value.score) })
|
|
172
172
|
}, [
|
|
173
|
-
|
|
173
|
+
m("span", {
|
|
174
174
|
class: "tpl:text-4xl tpl:font-bold tpl:tabular-nums",
|
|
175
|
-
style:
|
|
176
|
-
},
|
|
177
|
-
|
|
178
|
-
$() > 0 ? (
|
|
175
|
+
style: g({ color: h(A)(h(J).scoringResult.value.score) })
|
|
176
|
+
}, i(h(J).scoringResult.value.score), 5),
|
|
177
|
+
m("span", ue, i(h(K).scoring.overallScore), 1),
|
|
178
|
+
$() > 0 ? (r(), l("span", de, i($()) + " " + i(h(K).scoring.findings), 1)) : f("", !0)
|
|
179
179
|
], 4),
|
|
180
|
-
|
|
180
|
+
h(J).fixError.value ? (r(), l("div", fe, [u(h(C), {
|
|
181
181
|
size: 14,
|
|
182
182
|
"stroke-width": 2,
|
|
183
183
|
class: "tpl:mt-0.5 tpl:shrink-0"
|
|
184
|
-
}),
|
|
185
|
-
(
|
|
186
|
-
key:
|
|
184
|
+
}), m("span", null, i(h(K).scoring.fixError), 1)])) : f("", !0),
|
|
185
|
+
(r(), l(d, null, a(Z, (t) => m("div", {
|
|
186
|
+
key: t,
|
|
187
187
|
class: "tpl:overflow-hidden tpl:rounded-[var(--tpl-radius)] tpl:border tpl:border-[var(--tpl-border)]"
|
|
188
|
-
}, [
|
|
188
|
+
}, [m("button", {
|
|
189
189
|
class: "tpl:flex tpl:w-full tpl:cursor-pointer tpl:items-center tpl:gap-2.5 tpl:px-3 tpl:py-2.5 tpl:text-left tpl:transition-colors tpl:duration-100 tpl:bg-[var(--tpl-bg)]",
|
|
190
|
-
onClick: (
|
|
190
|
+
onClick: (e) => ke(t)
|
|
191
191
|
}, [
|
|
192
|
-
(
|
|
192
|
+
(r(), p(n(Ae[t]), {
|
|
193
193
|
size: 14,
|
|
194
194
|
"stroke-width": 2,
|
|
195
|
-
style:
|
|
195
|
+
style: g({ color: h(A)(h(J).scoringResult.value.categories[t].score) })
|
|
196
196
|
}, null, 8, ["style"])),
|
|
197
|
-
|
|
198
|
-
|
|
197
|
+
m("span", me, i(h(K).scoring.categories[t]), 1),
|
|
198
|
+
m("span", {
|
|
199
199
|
class: "tpl:rounded-full tpl:px-2 tpl:py-0.5 tpl:text-xs tpl:font-semibold tpl:tabular-nums",
|
|
200
|
-
style:
|
|
201
|
-
color:
|
|
202
|
-
backgroundColor:
|
|
200
|
+
style: g({
|
|
201
|
+
color: h(A)(h(J).scoringResult.value.categories[t].score),
|
|
202
|
+
backgroundColor: h(j)(h(J).scoringResult.value.categories[t].score)
|
|
203
203
|
})
|
|
204
|
-
},
|
|
205
|
-
|
|
206
|
-
|
|
204
|
+
}, i(h(J).scoringResult.value.categories[t].score), 5),
|
|
205
|
+
h(J).scoringResult.value.categories[t].findings.length > 0 ? (r(), l("span", he, i(h(J).scoringResult.value.categories[t].findings.length), 1)) : f("", !0),
|
|
206
|
+
u(h(S), {
|
|
207
207
|
size: 12,
|
|
208
208
|
"stroke-width": 2,
|
|
209
|
-
class:
|
|
209
|
+
class: e(["tpl:transition-transform tpl:duration-200 tpl:text-[var(--tpl-text-dim)]", X.value[t] ? "tpl:rotate-0" : "tpl:-rotate-90"])
|
|
210
210
|
}, null, 8, ["class"])
|
|
211
|
-
], 8, pe), X.value[
|
|
211
|
+
], 8, pe), X.value[t] ? (r(), l("div", ge, [h(J).scoringResult.value.categories[t].findings.length === 0 ? (r(), l("div", _e, i(h(K).scoring.noFindings), 1)) : f("", !0), (r(!0), l(d, null, a(h(J).scoringResult.value.categories[t].findings, (e) => (r(), l("div", {
|
|
212
212
|
key: e.id,
|
|
213
213
|
class: "tpl:border-t tpl:px-3 tpl:py-2.5 first:tpl:border-t-0 tpl:border-[var(--tpl-border-light)]"
|
|
214
|
-
}, [
|
|
214
|
+
}, [m("div", ve, [(r(), p(n(e.severity === "high" ? h(C) : e.severity === "medium" ? h(se) : h(ae)), {
|
|
215
215
|
size: 13,
|
|
216
216
|
"stroke-width": 2,
|
|
217
217
|
class: "tpl:mt-0.5 tpl:shrink-0",
|
|
218
|
-
style:
|
|
219
|
-
}, null, 8, ["style"])),
|
|
220
|
-
|
|
218
|
+
style: g({ color: h(M)(e.severity) })
|
|
219
|
+
}, null, 8, ["style"])), m("div", ye, [
|
|
220
|
+
m("div", be, [m("span", {
|
|
221
221
|
class: "tpl:mt-0.5 tpl:shrink-0 tpl:rounded tpl:px-1 tpl:py-px tpl:text-[10px] tpl:font-medium tpl:leading-tight",
|
|
222
|
-
style:
|
|
223
|
-
color:
|
|
224
|
-
backgroundColor:
|
|
222
|
+
style: g({
|
|
223
|
+
color: h(M)(e.severity),
|
|
224
|
+
backgroundColor: h(N)(e.severity)
|
|
225
225
|
})
|
|
226
|
-
},
|
|
227
|
-
e.suggestion ? (
|
|
228
|
-
e.blockId ? (
|
|
226
|
+
}, i(h(K).scoring.severity[e.severity]), 5), m("span", xe, i(e.message), 1)]),
|
|
227
|
+
e.suggestion ? (r(), l("p", Se, i(e.suggestion), 1)) : f("", !0),
|
|
228
|
+
e.blockId ? (r(), l("div", Ce, [m("button", {
|
|
229
229
|
class: "tpl-scoring-fix-btn tpl:inline-flex tpl:items-center tpl:gap-1.5 tpl:rounded tpl:border tpl:px-3 tpl:py-1.5 tpl:text-[11px] tpl:font-medium tpl:transition-all tpl:duration-150 tpl:disabled:opacity-50 tpl:border-[var(--tpl-border)] tpl:text-[var(--tpl-primary)]",
|
|
230
230
|
style: { "background-color": "transparent" },
|
|
231
|
-
disabled:
|
|
231
|
+
disabled: h(J).fixingFindingId.value !== null,
|
|
232
232
|
onClick: (t) => je(e)
|
|
233
|
-
}, [
|
|
233
|
+
}, [h(J).fixingFindingId.value === e.id ? (r(), p(h(oe), {
|
|
234
234
|
key: 0,
|
|
235
235
|
class: "tpl-spinner",
|
|
236
236
|
size: 11,
|
|
237
237
|
"stroke-width": 2
|
|
238
|
-
})) : (
|
|
238
|
+
})) : (r(), p(h(D), {
|
|
239
239
|
key: 1,
|
|
240
240
|
size: 11,
|
|
241
241
|
"stroke-width": 2
|
|
242
|
-
})),
|
|
243
|
-
])])]))), 128))])) :
|
|
244
|
-
])) : (
|
|
242
|
+
})), _(" " + i(h(J).fixingFindingId.value === e.id ? h(K).scoring.fixing : h(K).scoring.fix), 1)], 8, we), h(J).fixError.value ? (r(), l("p", Te, i(h(J).fixError.value), 1)) : f("", !0)])) : f("", !0)
|
|
243
|
+
])])]))), 128))])) : f("", !0)])), 64))
|
|
244
|
+
])) : (r(), l("div", Ee, [u(h(E), {
|
|
245
245
|
size: 32,
|
|
246
246
|
"stroke-width": 1.5,
|
|
247
247
|
class: "tpl:text-[var(--tpl-text-dim)]"
|
|
248
|
-
}),
|
|
248
|
+
}), m("p", De, i(h(K).scoring.emptyState), 1)])), m("p", Oe, i(h(K).aiMenu.disclaimer), 1)])])) : f("", !0)]),
|
|
249
249
|
_: 1
|
|
250
250
|
}));
|
|
251
251
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "./
|
|
3
|
-
import
|
|
4
|
-
import { t as
|
|
5
|
-
import {
|
|
1
|
+
import { Ct as e, H as t, M as n, Ot as r, P as i, S as a, V as o, Y as s, _ as c, b as l, d as u, g as d, h as f, m as p, o as m, tt as h, y as g, z as _ } from "./vue.runtime.esm-bundler-DryoQb-v.js";
|
|
2
|
+
import { t as v } from "./useI18n-B8CN2iWs.js";
|
|
3
|
+
import "./useEditorCore-DMH2QpUL.js";
|
|
4
|
+
import { t as y } from "./loader-circle-BYeKJ3to.js";
|
|
5
|
+
import { t as b } from "./TplModal-BkoIz0oz.js";
|
|
6
6
|
//#region src/cloud/components/TestEmailModal.vue?vue&type=script&setup=true&lang.ts
|
|
7
7
|
var x = ["aria-busy"], S = {
|
|
8
8
|
id: "tpl-test-email-title",
|
|
@@ -14,7 +14,7 @@ var x = ["aria-busy"], S = {
|
|
|
14
14
|
}, k = { class: "tpl:flex tpl:justify-end tpl:gap-2" }, A = ["disabled"], j = ["disabled"], M = {
|
|
15
15
|
key: 0,
|
|
16
16
|
class: "tpl:flex tpl:items-center tpl:gap-1.5"
|
|
17
|
-
}, N = { key: 1 }, P = /* @__PURE__ */
|
|
17
|
+
}, N = { key: 1 }, P = /* @__PURE__ */ a({
|
|
18
18
|
__name: "TestEmailModal",
|
|
19
19
|
props: {
|
|
20
20
|
visible: { type: Boolean },
|
|
@@ -23,9 +23,9 @@ var x = ["aria-busy"], S = {
|
|
|
23
23
|
error: {}
|
|
24
24
|
},
|
|
25
25
|
emits: ["send", "close"],
|
|
26
|
-
setup(
|
|
27
|
-
let F =
|
|
28
|
-
|
|
26
|
+
setup(a, { emit: P }) {
|
|
27
|
+
let F = a, I = P, { t: L } = v(), R = s("");
|
|
28
|
+
_(() => F.visible, (e) => {
|
|
29
29
|
e && (R.value = F.allowedEmails[0] ?? "");
|
|
30
30
|
});
|
|
31
31
|
function z() {
|
|
@@ -37,15 +37,15 @@ var x = ["aria-busy"], S = {
|
|
|
37
37
|
function V(e) {
|
|
38
38
|
e.key === "Enter" && !e.shiftKey && (e.preventDefault(), z()), e.key === "Escape" && B();
|
|
39
39
|
}
|
|
40
|
-
return (
|
|
41
|
-
visible:
|
|
40
|
+
return (s, _) => (n(), f(b, {
|
|
41
|
+
visible: a.visible,
|
|
42
42
|
onClose: B,
|
|
43
43
|
onKeydown: V
|
|
44
44
|
}, {
|
|
45
|
-
default:
|
|
45
|
+
default: o(() => [p("div", {
|
|
46
46
|
role: "dialog",
|
|
47
47
|
"aria-modal": "true",
|
|
48
|
-
"aria-busy":
|
|
48
|
+
"aria-busy": a.isSending,
|
|
49
49
|
"aria-labelledby": "tpl-test-email-title",
|
|
50
50
|
class: "tpl-scale-in tpl:mx-4 tpl:w-full tpl:max-w-sm tpl:rounded-[var(--tpl-radius-lg)] tpl:p-5",
|
|
51
51
|
style: {
|
|
@@ -53,38 +53,38 @@ var x = ["aria-busy"], S = {
|
|
|
53
53
|
"box-shadow": "var(--tpl-shadow-xl)"
|
|
54
54
|
}
|
|
55
55
|
}, [
|
|
56
|
-
|
|
57
|
-
|
|
56
|
+
p("h3", S, r(h(L).testEmail.title), 1),
|
|
57
|
+
p("div", C, [p("label", w, r(h(L).testEmail.recipientLabel), 1), a.allowedEmails.length === 1 ? (n(), c("input", {
|
|
58
58
|
key: 0,
|
|
59
59
|
type: "text",
|
|
60
60
|
value: R.value,
|
|
61
61
|
disabled: "",
|
|
62
62
|
class: "tpl:h-9 tpl:w-full tpl:rounded-md tpl:border tpl:px-3 tpl:py-1 tpl:text-sm tpl:opacity-70 tpl:shadow-xs tpl:outline-none tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]"
|
|
63
|
-
}, null, 8, T)) :
|
|
63
|
+
}, null, 8, T)) : t((n(), c("select", {
|
|
64
64
|
key: 1,
|
|
65
|
-
"onUpdate:modelValue":
|
|
65
|
+
"onUpdate:modelValue": _[0] ||= (e) => R.value = e,
|
|
66
66
|
class: "tpl:h-9 tpl:w-full tpl:rounded-md tpl:border tpl:px-3 tpl:py-1 tpl:text-sm tpl:shadow-xs tpl:outline-none tpl:border-[var(--tpl-border)] tpl:bg-[var(--tpl-bg)] tpl:text-[var(--tpl-text)]",
|
|
67
|
-
disabled:
|
|
68
|
-
}, [(
|
|
67
|
+
disabled: a.isSending
|
|
68
|
+
}, [(n(!0), c(u, null, i(a.allowedEmails, (e) => (n(), c("option", {
|
|
69
69
|
key: e,
|
|
70
70
|
value: e
|
|
71
|
-
},
|
|
72
|
-
|
|
73
|
-
|
|
71
|
+
}, r(e), 9, D))), 128))], 8, E)), [[m, R.value]])]),
|
|
72
|
+
a.error ? (n(), c("p", O, r(a.error), 1)) : d("", !0),
|
|
73
|
+
p("div", k, [p("button", {
|
|
74
74
|
type: "button",
|
|
75
|
-
class:
|
|
76
|
-
disabled:
|
|
75
|
+
class: e(["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)]", { "tpl:cursor-not-allowed tpl:opacity-50": a.isSending }]),
|
|
76
|
+
disabled: a.isSending,
|
|
77
77
|
onClick: B
|
|
78
|
-
}, h(
|
|
78
|
+
}, r(h(L).testEmail.cancel), 11, A), p("button", {
|
|
79
79
|
type: "button",
|
|
80
80
|
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)]",
|
|
81
|
-
disabled: !R.value ||
|
|
81
|
+
disabled: !R.value || a.isSending,
|
|
82
82
|
onClick: z
|
|
83
|
-
}, [
|
|
83
|
+
}, [a.isSending ? (n(), c("span", M, [l(h(y), {
|
|
84
84
|
class: "tpl:animate-spin",
|
|
85
85
|
size: 12,
|
|
86
86
|
"stroke-width": 2
|
|
87
|
-
}),
|
|
87
|
+
}), g(" " + r(h(L).testEmail.sending), 1)])) : (n(), c("span", N, r(h(L).testEmail.send), 1))], 8, j)])
|
|
88
88
|
], 8, x)]),
|
|
89
89
|
_: 1
|
|
90
90
|
}, 8, ["visible"]));
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
import { Ct as e, E as t, G as n, M as r, Ot as i, S as a, _ as o, b as s, d as c, f as l, g as u, h as d, m as f, tt as p, wt as m, y as h } from "./vue.runtime.esm-bundler-DryoQb-v.js";
|
|
2
|
+
import { S as g, w as _ } from "./keys-CIw9mUI2.js";
|
|
3
|
+
import { t as v } from "./useI18n-B8CN2iWs.js";
|
|
4
|
+
import { b as y } from "./useEditorCore-DMH2QpUL.js";
|
|
5
|
+
import { a as b, i as x, n as S, r as ee, t as C } from "./RichTextEditorContent-G1lXgVJR.js";
|
|
6
|
+
import { t as w } from "./loader-circle-BYeKJ3to.js";
|
|
7
|
+
import { t as T } from "./scan-line-Bw8bauvt.js";
|
|
8
|
+
//#region src/components/blocks/TitleEditor.vue?vue&type=script&setup=true&lang.ts
|
|
9
|
+
var E = { class: "tpl-text-editor-wrapper tpl:relative" }, D = ["data-tpl-theme", "aria-label"], O = ["aria-label", "title"], k = ["aria-label", "title"], A = ["aria-label", "title"], j = {
|
|
10
|
+
key: 0,
|
|
11
|
+
class: "tpl:mx-1.5 tpl:h-6 tpl:w-px tpl:bg-[var(--tpl-border)]"
|
|
12
|
+
}, M = ["aria-label", "title"], N = {
|
|
13
|
+
key: 1,
|
|
14
|
+
class: "tpl:flex tpl:items-center tpl:gap-2 tpl:px-2 tpl:text-xs tpl:text-[var(--tpl-text-dim)]"
|
|
15
|
+
}, P = /* @__PURE__ */ a({
|
|
16
|
+
__name: "TitleEditor",
|
|
17
|
+
props: {
|
|
18
|
+
block: {},
|
|
19
|
+
toolbarPosition: {}
|
|
20
|
+
},
|
|
21
|
+
emits: ["done"],
|
|
22
|
+
setup(a, { emit: P }) {
|
|
23
|
+
let F = a, I = P, L = t(g, null), R = t(_, null), { t: z } = v(), { editor: B, EditorContent: V, isLoading: H, initError: U, retry: W, showLinkDialog: G, linkUrl: K, linkDialogRef: q, mergeTagEnabled: J, openLinkDialog: Y, insertLink: X, removeLink: Z, closeLinkDialog: Q, handleLinkKeydown: te, handleAddMergeTag: $ } = y({
|
|
24
|
+
blockId: () => F.block.id,
|
|
25
|
+
blockContent: () => F.block.content,
|
|
26
|
+
onDone: () => I("done"),
|
|
27
|
+
editorName: "TitleEditor",
|
|
28
|
+
async loadExtensions({ mergeTags: e, syntax: t }) {
|
|
29
|
+
let [{ Editor: n, EditorContent: r }, { default: i }, { default: a }, { MergeTagNode: o, LogicMergeTagNode: s }] = await Promise.all([
|
|
30
|
+
import("./dist-D42og5Sc.js").then((e) => e.r),
|
|
31
|
+
import("./dist-BnlZ_HwX.js"),
|
|
32
|
+
import("./dist-UZ8UzVZ-.js"),
|
|
33
|
+
import("./extensions-DQKaICBH.js")
|
|
34
|
+
]);
|
|
35
|
+
return {
|
|
36
|
+
TiptapEditor: n,
|
|
37
|
+
EC: r,
|
|
38
|
+
extensions: [
|
|
39
|
+
i.configure({
|
|
40
|
+
heading: !1,
|
|
41
|
+
codeBlock: !1,
|
|
42
|
+
blockquote: !1,
|
|
43
|
+
horizontalRule: !1,
|
|
44
|
+
bulletList: !1,
|
|
45
|
+
orderedList: !1,
|
|
46
|
+
listItem: !1,
|
|
47
|
+
strike: !1
|
|
48
|
+
}),
|
|
49
|
+
a.configure({
|
|
50
|
+
openOnClick: !1,
|
|
51
|
+
HTMLAttributes: {
|
|
52
|
+
target: "_blank",
|
|
53
|
+
rel: "noopener noreferrer"
|
|
54
|
+
}
|
|
55
|
+
}),
|
|
56
|
+
o.configure({
|
|
57
|
+
mergeTags: e,
|
|
58
|
+
syntax: t
|
|
59
|
+
}),
|
|
60
|
+
s.configure({ syntax: t })
|
|
61
|
+
]
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
});
|
|
65
|
+
return (t, g) => (r(), o("div", E, [
|
|
66
|
+
(r(), d(l, { to: "body" }, [f("div", {
|
|
67
|
+
"data-tpl-theme": p(R),
|
|
68
|
+
role: "toolbar",
|
|
69
|
+
"aria-label": p(z).titleEditor.toolbar,
|
|
70
|
+
class: "tpl tpl-text-toolbar tpl:fixed 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",
|
|
71
|
+
style: m({
|
|
72
|
+
...p(L),
|
|
73
|
+
top: `${a.toolbarPosition.top}px`,
|
|
74
|
+
left: `${a.toolbarPosition.left}px`,
|
|
75
|
+
transform: "translateY(-100%)"
|
|
76
|
+
})
|
|
77
|
+
}, [!p(H) && p(B) ? (r(), o(c, { key: 0 }, [
|
|
78
|
+
f("button", {
|
|
79
|
+
type: "button",
|
|
80
|
+
class: e(["tpl-text-toolbar-btn", { "tpl-text-toolbar-btn--active": p(B)?.isActive("bold") }]),
|
|
81
|
+
"aria-label": p(z).titleEditor.bold,
|
|
82
|
+
title: p(z).titleEditor.bold,
|
|
83
|
+
onClick: g[0] ||= (e) => p(B)?.chain().focus().toggleBold().run()
|
|
84
|
+
}, [s(p(b), {
|
|
85
|
+
size: 16,
|
|
86
|
+
"stroke-width": 2.5
|
|
87
|
+
})], 10, O),
|
|
88
|
+
f("button", {
|
|
89
|
+
type: "button",
|
|
90
|
+
class: e(["tpl-text-toolbar-btn", { "tpl-text-toolbar-btn--active": p(B)?.isActive("italic") }]),
|
|
91
|
+
"aria-label": p(z).titleEditor.italic,
|
|
92
|
+
title: p(z).titleEditor.italic,
|
|
93
|
+
onClick: g[1] ||= (e) => p(B)?.chain().focus().toggleItalic().run()
|
|
94
|
+
}, [s(p(x), {
|
|
95
|
+
size: 16,
|
|
96
|
+
"stroke-width": 2
|
|
97
|
+
})], 10, k),
|
|
98
|
+
g[6] ||= f("span", {
|
|
99
|
+
class: "tpl:mx-1.5 tpl:h-6 tpl:w-px tpl:bg-[var(--tpl-border)]",
|
|
100
|
+
"aria-hidden": "true"
|
|
101
|
+
}, null, -1),
|
|
102
|
+
f("button", {
|
|
103
|
+
type: "button",
|
|
104
|
+
class: e(["tpl-text-toolbar-btn", { "tpl-text-toolbar-btn--active": p(B)?.isActive("link") }]),
|
|
105
|
+
"aria-label": p(z).titleEditor.addLink,
|
|
106
|
+
title: p(z).titleEditor.addLink,
|
|
107
|
+
onClick: g[2] ||= (...e) => p(Y) && p(Y)(...e)
|
|
108
|
+
}, [s(p(ee), {
|
|
109
|
+
size: 16,
|
|
110
|
+
"stroke-width": 2
|
|
111
|
+
})], 10, A),
|
|
112
|
+
p(J) ? (r(), o("span", j)) : u("", !0),
|
|
113
|
+
p(J) ? (r(), o("button", {
|
|
114
|
+
key: 1,
|
|
115
|
+
type: "button",
|
|
116
|
+
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)]",
|
|
117
|
+
"aria-label": p(z).mergeTag.add,
|
|
118
|
+
title: p(z).mergeTag.add,
|
|
119
|
+
onClick: g[3] ||= (...e) => p($) && p($)(...e)
|
|
120
|
+
}, [s(p(T), {
|
|
121
|
+
size: 16,
|
|
122
|
+
"stroke-width": 2
|
|
123
|
+
}), h(" " + i(p(z).mergeTag.add), 1)], 8, M)) : u("", !0)
|
|
124
|
+
], 64)) : (r(), o("div", N, [s(p(w), {
|
|
125
|
+
class: "tpl-spinner",
|
|
126
|
+
size: 14,
|
|
127
|
+
"stroke-width": 2
|
|
128
|
+
}), h(" " + i(p(z).errors.editorLoading), 1)]))], 12, D)])),
|
|
129
|
+
s(C, {
|
|
130
|
+
editor: p(B),
|
|
131
|
+
"editor-content": p(V),
|
|
132
|
+
"is-loading": p(H),
|
|
133
|
+
"init-error": p(U),
|
|
134
|
+
onRetry: p(W)
|
|
135
|
+
}, null, 8, [
|
|
136
|
+
"editor",
|
|
137
|
+
"editor-content",
|
|
138
|
+
"is-loading",
|
|
139
|
+
"init-error",
|
|
140
|
+
"onRetry"
|
|
141
|
+
]),
|
|
142
|
+
s(S, {
|
|
143
|
+
visible: p(G),
|
|
144
|
+
"is-editing-link": p(B)?.isActive("link") ?? !1,
|
|
145
|
+
"dialog-ref": p(q),
|
|
146
|
+
"onUpdate:dialogRef": g[4] ||= (e) => n(q) ? q.value = e : null,
|
|
147
|
+
"link-url": p(K),
|
|
148
|
+
"onUpdate:linkUrl": g[5] ||= (e) => n(K) ? K.value = e : null,
|
|
149
|
+
onClose: p(Q),
|
|
150
|
+
onInsert: p(X),
|
|
151
|
+
onRemove: p(Z),
|
|
152
|
+
onKeydown: p(te)
|
|
153
|
+
}, null, 8, [
|
|
154
|
+
"visible",
|
|
155
|
+
"is-editing-link",
|
|
156
|
+
"dialog-ref",
|
|
157
|
+
"link-url",
|
|
158
|
+
"onClose",
|
|
159
|
+
"onInsert",
|
|
160
|
+
"onRemove",
|
|
161
|
+
"onKeydown"
|
|
162
|
+
])
|
|
163
|
+
]));
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
//#endregion
|
|
167
|
+
export { P as default };
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { w as
|
|
3
|
-
import {
|
|
1
|
+
import { E as e, F as t, M as n, S as r, V as i, Y as a, _ as o, b as s, f as c, g as l, h as u, m as d, p as f, t as p, tt as m, u as h } from "./vue.runtime.esm-bundler-DryoQb-v.js";
|
|
2
|
+
import { w as g } from "./keys-CIw9mUI2.js";
|
|
3
|
+
import { w as _ } from "./useEditorCore-DMH2QpUL.js";
|
|
4
4
|
//#region src/cloud/components/TplModal.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
-
var v = ["data-tpl-theme"], y = /* @__PURE__ */
|
|
5
|
+
var v = ["data-tpl-theme"], y = /* @__PURE__ */ r({
|
|
6
6
|
__name: "TplModal",
|
|
7
7
|
props: { visible: { type: Boolean } },
|
|
8
8
|
emits: ["close", "keydown"],
|
|
9
|
-
setup(
|
|
10
|
-
let b =
|
|
11
|
-
|
|
12
|
-
let C =
|
|
9
|
+
setup(r, { emit: y }) {
|
|
10
|
+
let b = r, x = y, S = a(null);
|
|
11
|
+
_(S, f(() => b.visible));
|
|
12
|
+
let C = e(g);
|
|
13
13
|
function w(e) {
|
|
14
14
|
e.key === "Escape" && x("close"), x("keydown", e);
|
|
15
15
|
}
|
|
16
|
-
return (e,
|
|
16
|
+
return (e, a) => (n(), u(c, { to: "body" }, [s(p, {
|
|
17
17
|
"enter-active-class": "tpl:transition tpl:duration-150",
|
|
18
18
|
"enter-from-class": "tpl:opacity-0",
|
|
19
19
|
"enter-to-class": "tpl:opacity-100",
|
|
@@ -21,21 +21,21 @@ var v = ["data-tpl-theme"], y = /* @__PURE__ */ u({
|
|
|
21
21
|
"leave-from-class": "tpl:opacity-100",
|
|
22
22
|
"leave-to-class": "tpl:opacity-0"
|
|
23
23
|
}, {
|
|
24
|
-
default:
|
|
24
|
+
default: i(() => [r.visible ? (n(), o("div", {
|
|
25
25
|
key: 0,
|
|
26
|
-
"data-tpl-theme":
|
|
26
|
+
"data-tpl-theme": m(C),
|
|
27
27
|
class: "tpl tpl:fixed tpl:inset-0 tpl:z-modal tpl:flex tpl:items-center tpl:justify-center",
|
|
28
28
|
style: {
|
|
29
29
|
"background-color": "var(--tpl-overlay)",
|
|
30
30
|
"backdrop-filter": "blur(8px)",
|
|
31
31
|
"-webkit-backdrop-filter": "blur(8px)"
|
|
32
32
|
},
|
|
33
|
-
onClick:
|
|
33
|
+
onClick: a[0] ||= h((e) => x("close"), ["self"]),
|
|
34
34
|
onKeydown: w
|
|
35
|
-
}, [
|
|
35
|
+
}, [d("div", {
|
|
36
36
|
ref_key: "dialogRef",
|
|
37
37
|
ref: S
|
|
38
|
-
}, [
|
|
38
|
+
}, [t(e.$slots, "default")], 512)], 40, v)) : l("", !0)]),
|
|
39
39
|
_: 3
|
|
40
40
|
})]));
|
|
41
41
|
}
|