epic-designer-gold 1.0.29 → 1.0.31
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/{attributeView-BqtDAlQn.js → attributeView-CSiGWdPc.js} +1 -1
- package/dist/{attributeView-BXAZCzjN.cjs → attributeView-UzP3tU2D.cjs} +1 -1
- package/dist/{index-BLP-aOxR.js → index-B2RMcVgD.js} +1 -1
- package/dist/{index-CfNqnQwZ.cjs → index-B8exdhvc.cjs} +1 -1
- package/dist/{index-Bca_A9gK.cjs → index-BENF2JDS.cjs} +1 -1
- package/dist/{index-gdly69qM.js → index-BbTWJKHb.js} +140 -140
- package/dist/{index-kTMEQOpq.js → index-BhICtIH5.js} +360 -368
- package/dist/index-BhMVNODR.js +43 -0
- package/dist/index-BwLkOBWy.cjs +10 -0
- package/dist/index-C9PHR_YC.js +4 -0
- package/dist/index-CU1ZFiwn.cjs +1 -0
- package/dist/{index-B4_XV0sh.cjs → index-CZFPJ6vM.cjs} +1 -1
- package/dist/{index-D-EiABAK.js → index-Cmfhlo_3.js} +1 -1
- package/dist/{index-CURN8hNC.cjs → index-D2GF87Tg.cjs} +1 -1
- package/dist/{index-UFxVHTZ9.cjs → index-DEBQD_h0.cjs} +1 -1
- package/dist/{index-DNEhlg9r.cjs → index-Dk0fyxAJ.cjs} +1 -1
- package/dist/{index-CvD6bD_0.js → index-DymbM-qI.js} +1 -1
- package/dist/{index-arLwKBPE.js → index-RL7vrExY.js} +1 -1
- package/dist/{index-UJyLHIXT.js → index-lCYWKDlK.js} +1 -1
- package/dist/{index-B9A0eWKG.cjs → index-n6H8b6fT.cjs} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{selectPage-vm_pZlz-.js → selectPage-Bm45M31g.js} +47 -47
- package/dist/selectPage-CrdVWKGk.cjs +1 -0
- package/dist/style.css +1 -1
- package/dist/{styleView-pnZNe-no.cjs → styleView-CrBDikDV.cjs} +1 -1
- package/dist/{styleView-DWhRTeHv.js → styleView-DONajUQ-.js} +1 -1
- package/dist/ui/elementPlus/index.cjs +1 -1
- package/dist/ui/elementPlus/index.js +3 -3
- package/dist/uploadFile-CTDuT_4r.cjs +1 -0
- package/dist/uploadFile-D1Wv0mlk.js +90 -0
- package/dist/uploadImage-0mGONFA8.cjs +1 -0
- package/dist/{uploadImage-DQmVV0jl.js → uploadImage-lNqQKWH3.js} +23 -22
- package/package.json +2 -2
- package/dist/index-CfqqBphl.cjs +0 -1
- package/dist/index-DOWqiyzN.cjs +0 -10
- package/dist/index-DSujK9zM.js +0 -4
- package/dist/index-DjPTgDpJ.js +0 -43
- package/dist/selectPage-DufSfwTA.cjs +0 -1
- package/dist/uploadFile-pgvj4Lm9.cjs +0 -1
- package/dist/uploadFile-qCbXuHfd.js +0 -81
- package/dist/uploadImage-B3sOX-5F.cjs +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as re, inject as A, ref as M, computed as q, watch as fe, openBlock as H, createElementBlock as F, Fragment as he, withDirectives as Ce, createElementVNode as V, normalizeClass as pe, toDisplayString as Qe, unref as u, createVNode as B, createCommentVNode as ie, withCtx as Z, createTextVNode as de, vShow as Te, createBlock as ve, mergeProps as Ke, useAttrs as Xe, provide as Ye, onUnmounted as qe, resolveComponent as Ge, createSlots as je, renderList as Ne, shallowRef as et, watchEffect as tt, nextTick as
|
|
2
|
-
import { p as
|
|
3
|
-
import { u as $e, a as at, b as _e, _ as it, c as rt, d as ct, e as dt, w as ut, f as ht } from "./index-
|
|
1
|
+
import { defineComponent as re, inject as A, ref as M, computed as q, watch as fe, openBlock as H, createElementBlock as F, Fragment as he, withDirectives as Ce, createElementVNode as V, normalizeClass as pe, toDisplayString as Qe, unref as u, createVNode as B, createCommentVNode as ie, withCtx as Z, createTextVNode as de, vShow as Te, createBlock as ve, mergeProps as Ke, useAttrs as Xe, provide as Ye, onUnmounted as qe, resolveComponent as Ge, createSlots as je, renderList as Ne, shallowRef as et, watchEffect as tt, nextTick as We, normalizeStyle as ye, renderSlot as nt, onMounted as ot } from "vue";
|
|
2
|
+
import { p as ne, o as D, g as te, a as Se, h as st, d as ke, q as lt } from "./pluginManager-BCnrHPYv.js";
|
|
3
|
+
import { u as $e, a as at, b as _e, _ as it, c as rt, d as ct, e as dt, w as ut, f as ht } from "./index-BhICtIH5.js";
|
|
4
4
|
import { ElDropdown as ft, ElDropdownMenu as pt, ElDropdownItem as ue } from "element-plus";
|
|
5
5
|
import { _ as me } from "./icon.vue_vue_type_script_setup_true_lang-D3QdcReY.js";
|
|
6
6
|
import { d as vt } from "./vuedraggable.umd-D2S7Eo7p.js";
|
|
@@ -13,12 +13,12 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
13
13
|
class: "epic-widget-action-item pointer-events-auto"
|
|
14
14
|
}, yt = /* @__PURE__ */ re({
|
|
15
15
|
__name: "previewWidgets",
|
|
16
|
-
setup(
|
|
17
|
-
const v = A("pageManager", {}),
|
|
16
|
+
setup(oe, { expose: U }) {
|
|
17
|
+
const v = A("pageManager", {}), n = A("pageSchema"), t = A("designer"), w = A("designerProps"), a = A("revoke"), m = M(null), I = M(null), S = M(null), P = M(!1), i = M(!1), r = M(!0), h = M("top"), { canvasScale: c, disabledZoom: $ } = $e();
|
|
18
18
|
let s = null;
|
|
19
19
|
const Y = q(() => {
|
|
20
20
|
const e = t.state.checkedNode;
|
|
21
|
-
return !(!(e != null && e.id) ||
|
|
21
|
+
return !(!(e != null && e.id) || w.value.lockDefaultSchemaEdit && v.defaultComponentIds.value.includes(e == null ? void 0 : e.id) || e.type === "table-cell");
|
|
22
22
|
}), Q = q(() => {
|
|
23
23
|
const e = t.state.checkedNode;
|
|
24
24
|
return (e == null ? void 0 : e.type) === "eTd";
|
|
@@ -28,26 +28,26 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
28
28
|
return (e == null ? void 0 : e.type) === "table";
|
|
29
29
|
});
|
|
30
30
|
const O = q(() => {
|
|
31
|
-
var
|
|
32
|
-
const e = v.componentInstances.value, l = (
|
|
31
|
+
var b, C, R, f, J, X;
|
|
32
|
+
const e = v.componentInstances.value, l = (b = t.state.checkedNode) == null ? void 0 : b.id;
|
|
33
33
|
if ((R = (C = t.state.checkedNode) == null ? void 0 : C.componentProps) != null && R.hidden)
|
|
34
34
|
return null;
|
|
35
|
-
const x =
|
|
35
|
+
const x = ne.getComponentConfingByType((f = t.state.checkedNode) == null ? void 0 : f.type) ?? null;
|
|
36
36
|
if (!l || !(e != null && e[l]))
|
|
37
37
|
return null;
|
|
38
38
|
if (x != null && x.defaultSchema.input && ((J = t.state.checkedNode) == null ? void 0 : J.noFormItem) !== !0)
|
|
39
39
|
return (X = e[l + "formItem"]) == null ? void 0 : X.$el;
|
|
40
|
-
const
|
|
41
|
-
return !(
|
|
40
|
+
const o = e[l];
|
|
41
|
+
return !(o != null && o.$el) || (o == null ? void 0 : o.$el.nodeName) === "#text" || !(o != null && o.$el.getBoundingClientRect) ? null : o == null ? void 0 : o.$el;
|
|
42
42
|
}), g = q(() => {
|
|
43
|
-
var
|
|
44
|
-
const e = v.componentInstances.value, l = (
|
|
43
|
+
var b, C, R, f;
|
|
44
|
+
const e = v.componentInstances.value, l = (b = t.state.hoverNode) == null ? void 0 : b.id, x = ne.getComponentConfingByType((C = t.state.hoverNode) == null ? void 0 : C.type) ?? null;
|
|
45
45
|
if (!l || !(e != null && e[l]))
|
|
46
46
|
return null;
|
|
47
47
|
if (x != null && x.defaultSchema.input && ((R = t.state.hoverNode) == null ? void 0 : R.noFormItem) !== !0)
|
|
48
48
|
return (f = e[l + "formItem"]) == null ? void 0 : f.$el;
|
|
49
|
-
const
|
|
50
|
-
return (
|
|
49
|
+
const o = e[l];
|
|
50
|
+
return (o == null ? void 0 : o.$el.nodeName) === "#text" ? null : o == null ? void 0 : o.$el;
|
|
51
51
|
}), { mutationObserver: k, observerConfig: y } = Re(K), { startTimedQuery: j, stopTimedQuery: ce } = at(K);
|
|
52
52
|
fe(
|
|
53
53
|
() => O.value,
|
|
@@ -64,14 +64,14 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
64
64
|
P.value = !1;
|
|
65
65
|
}
|
|
66
66
|
);
|
|
67
|
-
const { mutationObserver:
|
|
67
|
+
const { mutationObserver: W, observerConfig: L } = Re(be);
|
|
68
68
|
fe(
|
|
69
69
|
() => g.value,
|
|
70
70
|
(e) => {
|
|
71
|
-
e && (
|
|
71
|
+
e && (W.observe(e, L), be());
|
|
72
72
|
}
|
|
73
73
|
);
|
|
74
|
-
let
|
|
74
|
+
let z = 0;
|
|
75
75
|
fe(
|
|
76
76
|
() => {
|
|
77
77
|
var e;
|
|
@@ -79,10 +79,10 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
79
79
|
},
|
|
80
80
|
(e) => {
|
|
81
81
|
if (e) {
|
|
82
|
-
i.value = !0, clearTimeout(
|
|
82
|
+
i.value = !0, clearTimeout(z);
|
|
83
83
|
return;
|
|
84
84
|
}
|
|
85
|
-
|
|
85
|
+
z = setTimeout(() => {
|
|
86
86
|
i.value = !1;
|
|
87
87
|
}, 300);
|
|
88
88
|
}
|
|
@@ -91,23 +91,23 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
91
91
|
function K() {
|
|
92
92
|
const e = O.value;
|
|
93
93
|
if (!e || !s) return;
|
|
94
|
-
const { top: l, left: x } = s == null ? void 0 : s.getBoundingClientRect(), { top:
|
|
95
|
-
m.value && (m.value.style.width = `${C / f}px`, m.value.style.height = `${G}px`, m.value.style.top = `${J / f}px`, m.value.style.left = `${X / f}px`, Ae(J, X)),
|
|
94
|
+
const { top: l, left: x } = s == null ? void 0 : s.getBoundingClientRect(), { top: o, left: b, width: C, height: R } = e.getBoundingClientRect(), f = $.value ? 1 : c.value, J = o - l + ((s == null ? void 0 : s.scrollTop) ?? 0) * f, X = b - x + ((s == null ? void 0 : s.scrollLeft) ?? 0) * f, G = R / f;
|
|
95
|
+
m.value && (m.value.style.width = `${C / f}px`, m.value.style.height = `${G}px`, m.value.style.top = `${J / f}px`, m.value.style.left = `${X / f}px`, Ae(J, X)), S.value && (J < 45 && G < 100 ? (S.value.style.top = "", S.value.style.bottom = "-30px", S.value.style["border-radius"] = "0px 0px 4px 4px", h.value = "bottom") : J < 45 ? (S.value.style.top = "0px", S.value.style["border-radius"] = "0px 0px 4px 0", h.value = "center") : (S.value.style.top = "-30px", S.value.style["border-radius"] = "4px 4px 0px 0px", h.value = "top"));
|
|
96
96
|
}
|
|
97
97
|
function Ae(e, l) {
|
|
98
98
|
const x = O.value;
|
|
99
99
|
if (!s || !x) return;
|
|
100
|
-
const
|
|
101
|
-
let f = l / C -
|
|
102
|
-
f <
|
|
103
|
-
const J = s.scrollTop -
|
|
100
|
+
const o = s.getBoundingClientRect(), { width: b } = x.getBoundingClientRect(), C = $.value ? 1 : c.value, R = e / C - o.top;
|
|
101
|
+
let f = l / C - o.left + b / C;
|
|
102
|
+
f < o.width && (f = 0);
|
|
103
|
+
const J = s.scrollTop - o.height / 3 + 60, X = s.scrollTop + o.height / 3 * 2, G = s.scrollLeft - o.width + 200, le = s.scrollLeft + o.width - 200;
|
|
104
104
|
Math.abs(R - ee) < 10 && Math.abs(f - se) < 10 || (ee = R, se = f, !(R > J && R < X && f > G && f < le) && (s.scrollTop = R, s.scrollLeft = f));
|
|
105
105
|
}
|
|
106
106
|
function be() {
|
|
107
107
|
var G, le;
|
|
108
108
|
const e = g.value;
|
|
109
109
|
if (!e) return;
|
|
110
|
-
const { top: l, left: x } = (s == null ? void 0 : s.getBoundingClientRect()) ?? { top: 0, left: 0 }, { top:
|
|
110
|
+
const { top: l, left: x } = (s == null ? void 0 : s.getBoundingClientRect()) ?? { top: 0, left: 0 }, { top: o, left: b, width: C, height: R } = ((G = e.getBoundingClientRect) == null ? void 0 : G.call(e)) ?? ((le = e.nextElementSibling) == null ? void 0 : le.getBoundingClientRect()), f = $.value ? 1 : c.value, J = o - l + ((s == null ? void 0 : s.scrollTop) ?? 0) * f, X = b - x + ((s == null ? void 0 : s.scrollLeft) ?? 0) * f;
|
|
111
111
|
I.value && (I.value.style.width = `${C / f}px`, I.value.style.height = `${R / f}px`, I.value.style.top = `${J / f}px`, I.value.style.left = `${X / f}px`);
|
|
112
112
|
}
|
|
113
113
|
function Re(e) {
|
|
@@ -122,19 +122,19 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
122
122
|
};
|
|
123
123
|
}
|
|
124
124
|
function Ue(e) {
|
|
125
|
-
var l, x,
|
|
125
|
+
var l, x, o, b, C, R, f, J, X, G, le, De, Be, Me, Le, Ee, He, Ie;
|
|
126
126
|
if (e === "right") {
|
|
127
|
-
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(
|
|
128
|
-
(
|
|
127
|
+
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), T = (x = D(n.schemas, ((l = t.state.checkedNode) == null ? void 0 : l.id) ?? "root")) == null ? void 0 : x.index;
|
|
128
|
+
(o = _.list) == null || o[0].children.forEach((N) => {
|
|
129
129
|
var E;
|
|
130
130
|
(E = N.children) == null || E.splice(T + 1, 0, {
|
|
131
131
|
type: "eTd",
|
|
132
132
|
id: "eTd_" + te(),
|
|
133
133
|
children: []
|
|
134
134
|
});
|
|
135
|
-
}), a.push(
|
|
135
|
+
}), a.push(n.schemas, "添加右列");
|
|
136
136
|
} else if (e === "left") {
|
|
137
|
-
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(
|
|
137
|
+
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), T = (C = D(n.schemas, ((b = t.state.checkedNode) == null ? void 0 : b.id) ?? "root")) == null ? void 0 : C.index;
|
|
138
138
|
(R = _.list) == null || R[0].children.forEach((N) => {
|
|
139
139
|
var E;
|
|
140
140
|
T === 0 ? N.children.unshift({
|
|
@@ -146,75 +146,75 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
146
146
|
id: "eTd_" + te(),
|
|
147
147
|
children: []
|
|
148
148
|
});
|
|
149
|
-
}), a.push(
|
|
149
|
+
}), a.push(n.schemas, "添加左列");
|
|
150
150
|
} else if (e === "top") {
|
|
151
|
-
const d = t.state.matched.find((p) => p.type === "eTable"), _ = t.state.matched.find((p) => p.type === "eTr"), T = D(
|
|
151
|
+
const d = t.state.matched.find((p) => p.type === "eTable"), _ = t.state.matched.find((p) => p.type === "eTr"), T = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), N = D(n.schemas, (_ == null ? void 0 : _.id) ?? "root"), E = D(n.schemas, ((f = t.state.checkedNode) == null ? void 0 : f.id) ?? "root");
|
|
152
152
|
N.index === 0 ? (J = T.list) == null || J[0].children.unshift({
|
|
153
153
|
type: "eTr",
|
|
154
154
|
id: "eTr_" + te(),
|
|
155
|
-
children:
|
|
155
|
+
children: Se(E.list).map((p) => (p.id = "eTd_" + te(), p.children = [], p))
|
|
156
156
|
}) : (X = T.list) == null || X[0].children.splice(N.index - 1, 0, {
|
|
157
157
|
type: "eTr",
|
|
158
158
|
id: "eTr_" + te(),
|
|
159
|
-
children:
|
|
160
|
-
}), a.push(
|
|
159
|
+
children: Se(E.list).map((p) => (p.id = "eTd_" + te(), p.children = [], p))
|
|
160
|
+
}), a.push(n.schemas, "添加上列");
|
|
161
161
|
} else if (e === "bottom") {
|
|
162
|
-
const d = t.state.matched.find((p) => p.type === "eTable"), _ = t.state.matched.find((p) => p.type === "eTr"), T = D(
|
|
162
|
+
const d = t.state.matched.find((p) => p.type === "eTable"), _ = t.state.matched.find((p) => p.type === "eTr"), T = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), N = D(n.schemas, (_ == null ? void 0 : _.id) ?? "root"), E = D(n.schemas, ((G = t.state.checkedNode) == null ? void 0 : G.id) ?? "root");
|
|
163
163
|
(le = T.list) == null || le[0].children.splice(N.index + 1, 0, {
|
|
164
164
|
type: "eTr",
|
|
165
165
|
id: "eTr_" + te(),
|
|
166
|
-
children:
|
|
167
|
-
}), a.push(
|
|
166
|
+
children: Se(E.list).map((p) => (p.id = "eTd_" + te(), p.children = [], p))
|
|
167
|
+
}), a.push(n.schemas, "添加下列");
|
|
168
168
|
} else if (e === "merge-right") {
|
|
169
169
|
t.state.matched.find((N) => N.type === "eTr");
|
|
170
|
-
const d = D(
|
|
170
|
+
const d = D(n.schemas, ((De = t.state.checkedNode) == null ? void 0 : De.id) ?? "root");
|
|
171
171
|
if (d.index === d.list.length - 1)
|
|
172
172
|
return;
|
|
173
173
|
const _ = d.list[d.index], T = d.list[d.index + 1];
|
|
174
|
-
_.colspan = (_.colspan || 1) + (T.colspan || 1), d.list.splice(d.index + 1, 1), a.push(
|
|
174
|
+
_.colspan = (_.colspan || 1) + (T.colspan || 1), d.list.splice(d.index + 1, 1), a.push(n.schemas, "向右合并");
|
|
175
175
|
} else if (e === "merge-bottom") {
|
|
176
176
|
const d = t.state.matched.find((p) => p.type === "eTable"), _ = t.state.matched.find((p) => p.type === "eTr");
|
|
177
|
-
D(
|
|
178
|
-
const T = D(
|
|
177
|
+
D(n.schemas, (d == null ? void 0 : d.id) ?? "root");
|
|
178
|
+
const T = D(n.schemas, (_ == null ? void 0 : _.id) ?? "root"), E = D(n.schemas, ((Be = t.state.checkedNode) == null ? void 0 : Be.id) ?? "root").index;
|
|
179
179
|
if (T.index !== T.list.length - 1) {
|
|
180
180
|
const p = T.list[T.index];
|
|
181
181
|
let ge = 0, xe = 0;
|
|
182
|
-
p.children.forEach((ae,
|
|
183
|
-
ae.colSpan || (ae.colSpan = 1), xe = xe + ae.colSpan, xe === E + 1 && (ge =
|
|
182
|
+
p.children.forEach((ae, we) => {
|
|
183
|
+
ae.colSpan || (ae.colSpan = 1), xe = xe + ae.colSpan, xe === E + 1 && (ge = we);
|
|
184
184
|
}), p.children[ge].rowSpan = (p.children[ge].rowSpan || 1) + 1;
|
|
185
185
|
const Ze = T.list[T.index + p.children[ge].rowSpan - 1];
|
|
186
186
|
let Oe = 0, Ve = 0;
|
|
187
|
-
p.children.forEach((ae,
|
|
188
|
-
ae.colSpan || (ae.colSpan = 1), Ve = Ve + ae.colSpan, xe === E + 1 && (Oe =
|
|
187
|
+
p.children.forEach((ae, we) => {
|
|
188
|
+
ae.colSpan || (ae.colSpan = 1), Ve = Ve + ae.colSpan, xe === E + 1 && (Oe = we);
|
|
189
189
|
}), Ze.children.splice(Oe, 1);
|
|
190
190
|
}
|
|
191
|
-
a.push(
|
|
191
|
+
a.push(n.schemas, "向下合并");
|
|
192
192
|
} else if (e === "delete-col") {
|
|
193
|
-
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(
|
|
193
|
+
const d = t.state.matched.find((N) => N.type === "eTable"), _ = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), T = (Le = D(n.schemas, ((Me = t.state.checkedNode) == null ? void 0 : Me.id) ?? "root")) == null ? void 0 : Le.index;
|
|
194
194
|
(Ee = _.list) == null || Ee[0].children.forEach((N) => {
|
|
195
195
|
var E;
|
|
196
196
|
(E = N.children) == null || E.splice(T, 1);
|
|
197
|
-
}), a.push(
|
|
197
|
+
}), a.push(n.schemas, "删除当前列");
|
|
198
198
|
} else if (e === "delete-row") {
|
|
199
|
-
const d = t.state.matched.find((E) => E.type === "eTable"), _ = t.state.matched.find((E) => E.type === "eTr"), T = D(
|
|
200
|
-
D(
|
|
199
|
+
const d = t.state.matched.find((E) => E.type === "eTable"), _ = t.state.matched.find((E) => E.type === "eTr"), T = D(n.schemas, (d == null ? void 0 : d.id) ?? "root"), N = D(n.schemas, (_ == null ? void 0 : _.id) ?? "root");
|
|
200
|
+
D(n.schemas, ((He = t.state.checkedNode) == null ? void 0 : He.id) ?? "root"), (Ie = T.list) == null || Ie[0].children.splice(N.index, 1), a.push(n.schemas, "删除当前行");
|
|
201
201
|
}
|
|
202
202
|
}
|
|
203
203
|
function Pe() {
|
|
204
204
|
var C;
|
|
205
|
-
const e = D(
|
|
205
|
+
const e = D(n.schemas, ((C = t.state.checkedNode) == null ? void 0 : C.id) ?? "root");
|
|
206
206
|
if (!e)
|
|
207
207
|
return !1;
|
|
208
|
-
const { list: l, schema: x, index:
|
|
209
|
-
l.splice(
|
|
208
|
+
const { list: l, schema: x, index: o } = e, b = st(x);
|
|
209
|
+
l.splice(o + 1, 0, b), t.setCheckedNode(b), a.push(n.schemas, "复制组件");
|
|
210
210
|
}
|
|
211
211
|
function Fe() {
|
|
212
|
-
var
|
|
213
|
-
const e = D(
|
|
212
|
+
var b;
|
|
213
|
+
const e = D(n.schemas, ((b = t.state.checkedNode) == null ? void 0 : b.id) ?? "root");
|
|
214
214
|
if (!e)
|
|
215
215
|
return !1;
|
|
216
|
-
let { list: l, schema: x, index:
|
|
217
|
-
l.splice(
|
|
216
|
+
let { list: l, schema: x, index: o } = e;
|
|
217
|
+
l.splice(o, 1), o === l.length && o--, t.setCheckedNode(l[o]), a.push(n.schemas, "删除组件");
|
|
218
218
|
}
|
|
219
219
|
function Je(e) {
|
|
220
220
|
s = e, s == null || s.addEventListener("scroll", () => {
|
|
@@ -224,7 +224,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
224
224
|
return U({
|
|
225
225
|
handleInit: Je
|
|
226
226
|
}), (e, l) => {
|
|
227
|
-
var x,
|
|
227
|
+
var x, o, b, C, R;
|
|
228
228
|
return H(), F(he, null, [
|
|
229
229
|
Ce(V("div", {
|
|
230
230
|
ref_key: "selectorRef",
|
|
@@ -234,9 +234,9 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
234
234
|
V("div", {
|
|
235
235
|
class: "epic-widget-action-box",
|
|
236
236
|
ref_key: "actionBoxRef",
|
|
237
|
-
ref:
|
|
237
|
+
ref: S
|
|
238
238
|
}, [
|
|
239
|
-
V("div", mt, Qe((
|
|
239
|
+
V("div", mt, Qe((o = u(ne).getComponentConfingByType(((x = u(t).state.checkedNode) == null ? void 0 : x.type) ?? "")) == null ? void 0 : o.defaultSchema.label), 1),
|
|
240
240
|
Y.value ? (H(), F("div", gt, [
|
|
241
241
|
Y.value && !Q.value ? (H(), F("div", {
|
|
242
242
|
key: 0,
|
|
@@ -314,7 +314,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
314
314
|
])) : ie("", !0)
|
|
315
315
|
], 512)
|
|
316
316
|
], 2), [
|
|
317
|
-
[Te, P.value && ((
|
|
317
|
+
[Te, P.value && ((b = u(t).state.checkedNode) == null ? void 0 : b.id) !== "root"]
|
|
318
318
|
]),
|
|
319
319
|
Ce(V("div", {
|
|
320
320
|
ref_key: "hoverWidgetRef",
|
|
@@ -333,10 +333,10 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
333
333
|
schemas: {}
|
|
334
334
|
},
|
|
335
335
|
emits: ["update:schemas"],
|
|
336
|
-
setup(
|
|
337
|
-
const v = A("designer"),
|
|
336
|
+
setup(oe, { emit: U }) {
|
|
337
|
+
const v = A("designer"), n = A("pageSchema"), t = A("revoke"), w = oe, a = U, m = q({
|
|
338
338
|
get() {
|
|
339
|
-
return
|
|
339
|
+
return w.schemas;
|
|
340
340
|
},
|
|
341
341
|
set(r) {
|
|
342
342
|
a("update:schemas", r);
|
|
@@ -345,15 +345,15 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
345
345
|
function I(r) {
|
|
346
346
|
v.setCheckedNode(m.value[r]), v.setDisableHover(!0);
|
|
347
347
|
}
|
|
348
|
-
function
|
|
349
|
-
v.setDisableHover(), t.push(
|
|
348
|
+
function S() {
|
|
349
|
+
v.setDisableHover(), t.push(n.schemas, "拖拽组件");
|
|
350
350
|
}
|
|
351
351
|
function P() {
|
|
352
|
-
t.push(
|
|
352
|
+
t.push(n.schemas, "插入组件");
|
|
353
353
|
}
|
|
354
354
|
function i(r) {
|
|
355
355
|
var h, c, $;
|
|
356
|
-
return r.id === ((h =
|
|
356
|
+
return r.id === ((h = n.schemas[0]) == null ? void 0 : h.id) || ($ = (c = ne.getComponentConfingByType(r.type)) == null ? void 0 : c.editConstraints) != null && $.immovable ? "unmover-item" : "draggable-item";
|
|
357
357
|
}
|
|
358
358
|
return (r, h) => (H(), ve(u(vt), Ke({
|
|
359
359
|
modelValue: m.value,
|
|
@@ -370,7 +370,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
370
370
|
ghostClass: "moveing"
|
|
371
371
|
}, {
|
|
372
372
|
onStart: h[1] || (h[1] = (c) => I(c.oldIndex)),
|
|
373
|
-
onEnd: h[2] || (h[2] = (c) =>
|
|
373
|
+
onEnd: h[2] || (h[2] = (c) => S()),
|
|
374
374
|
onAdd: h[3] || (h[3] = (c) => {
|
|
375
375
|
I(c.newIndex), P();
|
|
376
376
|
})
|
|
@@ -380,25 +380,25 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
380
380
|
class: pe(["widget-box", i(c)]),
|
|
381
381
|
key: $
|
|
382
382
|
}, [
|
|
383
|
-
B(
|
|
383
|
+
B(ze, { schema: c }, null, 8, ["schema"])
|
|
384
384
|
], 2))
|
|
385
385
|
]),
|
|
386
386
|
_: 1
|
|
387
387
|
}, 16, ["modelValue"]));
|
|
388
388
|
}
|
|
389
|
-
}),
|
|
389
|
+
}), ze = /* @__PURE__ */ re({
|
|
390
390
|
name: "ENodeItem",
|
|
391
391
|
__name: "nodeItem",
|
|
392
392
|
props: {
|
|
393
393
|
schema: {},
|
|
394
394
|
name: {}
|
|
395
395
|
},
|
|
396
|
-
setup(
|
|
397
|
-
const U = Xe(), v = A("designer"),
|
|
396
|
+
setup(oe) {
|
|
397
|
+
const U = Xe(), v = A("designer"), n = A("pageManager", {}), t = A("pageSchema", {}), w = M(null);
|
|
398
398
|
Ye("nodeAttrs", U);
|
|
399
|
-
const a =
|
|
399
|
+
const a = oe, m = q(() => {
|
|
400
400
|
var $, s, Y, Q, O;
|
|
401
|
-
const i =
|
|
401
|
+
const i = n.componentInstances.value, r = ($ = a.schema) == null ? void 0 : $.id, h = ne.getComponentConfingByType((s = a.schema) == null ? void 0 : s.type) ?? null;
|
|
402
402
|
if (!r || !(i != null && i[r]))
|
|
403
403
|
return null;
|
|
404
404
|
if (h != null && h.defaultSchema.input && ((Y = a.schema) == null ? void 0 : Y.noFormItem) !== !0)
|
|
@@ -409,16 +409,16 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
409
409
|
fe(
|
|
410
410
|
() => m.value,
|
|
411
411
|
(i) => {
|
|
412
|
-
i == null || i.addEventListener("click", I, !1), i == null || i.addEventListener("mouseover",
|
|
412
|
+
i == null || i.addEventListener("click", I, !1), i == null || i.addEventListener("mouseover", S, !1), i == null || i.addEventListener("mouseout", P, !1);
|
|
413
413
|
}
|
|
414
414
|
), qe(() => {
|
|
415
415
|
var i, r, h;
|
|
416
|
-
(i = m.value) == null || i.removeEventListener("click", I, !1), (r = m.value) == null || r.removeEventListener("mouseover",
|
|
416
|
+
(i = m.value) == null || i.removeEventListener("click", I, !1), (r = m.value) == null || r.removeEventListener("mouseover", S, !1), (h = m.value) == null || h.removeEventListener("mouseout", P, !1);
|
|
417
417
|
});
|
|
418
418
|
function I(i) {
|
|
419
419
|
i.stopPropagation(), v.setCheckedNode(a.schema);
|
|
420
420
|
}
|
|
421
|
-
function
|
|
421
|
+
function S(i) {
|
|
422
422
|
var r;
|
|
423
423
|
a.schema.id !== ((r = t.schemas[0]) == null ? void 0 : r.id) && (i.stopPropagation(), v.setHoverNode(a.schema));
|
|
424
424
|
}
|
|
@@ -430,10 +430,10 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
430
430
|
const h = Ge("ENodeItem");
|
|
431
431
|
return H(), ve(u(it), {
|
|
432
432
|
ref_key: "nodeRef",
|
|
433
|
-
ref:
|
|
433
|
+
ref: w,
|
|
434
434
|
componentSchema: a.schema
|
|
435
435
|
}, je({ _: 2 }, [
|
|
436
|
-
($ = (c = u(
|
|
436
|
+
($ = (c = u(ne).getComponentConfingByType(a.schema.type)) == null ? void 0 : c.editConstraints) != null && $.childImmovable ? {
|
|
437
437
|
name: "edit-node",
|
|
438
438
|
fn: Z(() => [
|
|
439
439
|
(H(!0), F(he, null, Ne(a.schema.children, (s) => (H(), ve(h, {
|
|
@@ -456,23 +456,23 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
456
456
|
]), 1032, ["componentSchema"]);
|
|
457
457
|
};
|
|
458
458
|
}
|
|
459
|
-
}), bt = { class: "min-w-750px rounded h-full" },
|
|
459
|
+
}), bt = { class: "min-w-750px rounded h-full" }, wt = /* @__PURE__ */ re({
|
|
460
460
|
__name: "previewJson",
|
|
461
|
-
setup(
|
|
462
|
-
const v =
|
|
461
|
+
setup(oe, { expose: U }) {
|
|
462
|
+
const v = ne.getComponent("modal"), n = ne.getComponent("monacoEditor"), t = {
|
|
463
463
|
theme: "vs-light",
|
|
464
464
|
selectOnLineNumbers: !0,
|
|
465
465
|
minimap: {
|
|
466
466
|
enabled: !1
|
|
467
467
|
},
|
|
468
468
|
readOnly: !0
|
|
469
|
-
},
|
|
469
|
+
}, w = M(null), a = M(!1), m = A("pageSchema");
|
|
470
470
|
function I() {
|
|
471
471
|
a.value = !1;
|
|
472
472
|
}
|
|
473
|
-
function
|
|
474
|
-
a.value = !0,
|
|
475
|
-
|
|
473
|
+
function S() {
|
|
474
|
+
a.value = !0, w.value ? w.value.setValue(JSON.stringify(m, null, 2)) : setTimeout(() => {
|
|
475
|
+
S();
|
|
476
476
|
}, 300);
|
|
477
477
|
}
|
|
478
478
|
function P(i = "epic-data.json") {
|
|
@@ -481,7 +481,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
481
481
|
c.setAttribute("href", h), c.setAttribute("download", i), c.click();
|
|
482
482
|
}
|
|
483
483
|
return U({
|
|
484
|
-
handleOpen:
|
|
484
|
+
handleOpen: S
|
|
485
485
|
}), (i, r) => (H(), ve(u(v), {
|
|
486
486
|
modelValue: a.value,
|
|
487
487
|
"onUpdate:modelValue": r[0] || (r[0] = (h) => a.value = h),
|
|
@@ -494,9 +494,9 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
494
494
|
}, {
|
|
495
495
|
default: Z(() => [
|
|
496
496
|
V("div", bt, [
|
|
497
|
-
B(u(
|
|
497
|
+
B(u(n), {
|
|
498
498
|
ref_key: "monacoEditorRef",
|
|
499
|
-
ref:
|
|
499
|
+
ref: w,
|
|
500
500
|
class: "editor h-full",
|
|
501
501
|
autoToggleTheme: "",
|
|
502
502
|
readOnly: "",
|
|
@@ -508,7 +508,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
508
508
|
_: 1
|
|
509
509
|
}, 8, ["modelValue"]));
|
|
510
510
|
}
|
|
511
|
-
}),
|
|
511
|
+
}), St = { class: "epic-edit-toolbar flex items-center justify-between px-2" }, kt = { class: "flex-1 h-full flex items-center" }, Ct = {
|
|
512
512
|
key: 0,
|
|
513
513
|
class: "epic-divider"
|
|
514
514
|
}, Tt = ["title", "onClick"], Nt = { class: "flex-1 h-full flex items-center justify-end" }, $t = {
|
|
@@ -516,8 +516,8 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
516
516
|
class: "flex items-center ml-12px"
|
|
517
517
|
}, Rt = { class: "pr-8px w-82px cursor-pointer" }, Dt = { class: "epic-device h-28px items-center gap-1 rounded-md border p-2px flex" }, Bt = ["title", "onClick"], Mt = /* @__PURE__ */ re({
|
|
518
518
|
__name: "toolbar",
|
|
519
|
-
setup(
|
|
520
|
-
const U =
|
|
519
|
+
setup(oe) {
|
|
520
|
+
const U = ne.getComponent("select"), { canvasScale: v, disabledZoom: n } = $e(), t = M("pc"), w = A("pageSchema"), a = A("designer"), m = A("revoke"), I = M(null), S = [
|
|
521
521
|
{
|
|
522
522
|
icon: "icon--epic--computer-outline-rounded",
|
|
523
523
|
title: "pc",
|
|
@@ -594,11 +594,11 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
594
594
|
];
|
|
595
595
|
function c() {
|
|
596
596
|
const g = m.undo();
|
|
597
|
-
g && (ke(
|
|
597
|
+
g && (ke(w.schemas, g), a.setCheckedNode(w.schemas[0]));
|
|
598
598
|
}
|
|
599
599
|
function $() {
|
|
600
600
|
const g = m.redo();
|
|
601
|
-
g && (ke(
|
|
601
|
+
g && (ke(w.schemas, g), a.setCheckedNode(w.schemas[0]));
|
|
602
602
|
}
|
|
603
603
|
function s() {
|
|
604
604
|
a.reset();
|
|
@@ -610,14 +610,14 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
610
610
|
g.target.value = null;
|
|
611
611
|
const y = new FileReader();
|
|
612
612
|
y.readAsText(k), y.onload = (ce) => {
|
|
613
|
-
var
|
|
614
|
-
Q((
|
|
613
|
+
var W;
|
|
614
|
+
Q((W = ce.target) == null ? void 0 : W.result);
|
|
615
615
|
};
|
|
616
616
|
}
|
|
617
617
|
function Q(g) {
|
|
618
618
|
try {
|
|
619
619
|
let k = JSON.parse(g ?? "");
|
|
620
|
-
k.schemas || (k = lt(k)), ke(
|
|
620
|
+
k.schemas || (k = lt(k)), ke(w, k);
|
|
621
621
|
} catch (k) {
|
|
622
622
|
console.error(k);
|
|
623
623
|
}
|
|
@@ -636,10 +636,10 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
636
636
|
mode: g
|
|
637
637
|
}
|
|
638
638
|
};
|
|
639
|
-
|
|
639
|
+
w.canvas = k[g];
|
|
640
640
|
}
|
|
641
641
|
return (g, k) => (H(), F(he, null, [
|
|
642
|
-
V("div",
|
|
642
|
+
V("div", St, [
|
|
643
643
|
V("div", kt, [
|
|
644
644
|
(H(!0), F(he, null, Ne(P.value, (y, j) => (H(), F(he, { key: j }, [
|
|
645
645
|
y.divider ? (H(), F("div", Ct)) : ie("", !0),
|
|
@@ -664,7 +664,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
664
664
|
[Te, !1]
|
|
665
665
|
]),
|
|
666
666
|
V("div", Nt, [
|
|
667
|
-
u(
|
|
667
|
+
u(n) ? ie("", !0) : (H(), F("div", $t, [
|
|
668
668
|
V("div", Rt, [
|
|
669
669
|
B(u(U), {
|
|
670
670
|
value: r.value,
|
|
@@ -677,7 +677,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
677
677
|
])
|
|
678
678
|
])),
|
|
679
679
|
V("div", Dt, [
|
|
680
|
-
(H(), F(he, null, Ne(
|
|
680
|
+
(H(), F(he, null, Ne(S, (y) => V("div", {
|
|
681
681
|
key: y.key,
|
|
682
682
|
title: y.title,
|
|
683
683
|
class: pe(["epic-device-item h-full px-1 flex items-center cursor-pointer text-base transition-colors rounded-sm", { checked: y.key === t.value }]),
|
|
@@ -690,7 +690,7 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
690
690
|
])
|
|
691
691
|
])
|
|
692
692
|
]),
|
|
693
|
-
B(
|
|
693
|
+
B(wt, {
|
|
694
694
|
ref_key: "previewJson",
|
|
695
695
|
ref: I
|
|
696
696
|
}, null, 512)
|
|
@@ -698,16 +698,16 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
698
698
|
}
|
|
699
699
|
}), Lt = { class: "h-full flex flex-col relative" }, Et = ["draggable"], Ht = /* @__PURE__ */ re({
|
|
700
700
|
__name: "editScreenContainer",
|
|
701
|
-
setup(
|
|
702
|
-
const U = A("pageSchema"), v = M(null),
|
|
701
|
+
setup(oe) {
|
|
702
|
+
const U = A("pageSchema"), v = M(null), n = M(null), t = M(null), { pressSpace: w, disabledZoom: a } = $e(), {
|
|
703
703
|
handleElementDragStart: m,
|
|
704
704
|
handleElementDrag: I,
|
|
705
|
-
handleElementDragEnd:
|
|
706
|
-
} = rt(v), { width: P, height: i } = ct(v), { canvasScale: r, handleZoom: h } = dt(
|
|
705
|
+
handleElementDragEnd: S
|
|
706
|
+
} = rt(v), { width: P, height: i } = ct(v), { canvasScale: r, handleZoom: h } = dt(n);
|
|
707
707
|
let c = 0, $ = 0;
|
|
708
708
|
const s = M({}), Y = M({}), Q = M({}), O = et({ width: 0, height: 0 });
|
|
709
709
|
tt(k), fe(Q, () => {
|
|
710
|
-
|
|
710
|
+
We(g);
|
|
711
711
|
});
|
|
712
712
|
function g() {
|
|
713
713
|
t.value && (O.value = {
|
|
@@ -716,65 +716,65 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
716
716
|
});
|
|
717
717
|
}
|
|
718
718
|
function k() {
|
|
719
|
-
var
|
|
719
|
+
var W, L;
|
|
720
720
|
Q.value = {
|
|
721
|
-
width: ((
|
|
721
|
+
width: ((W = U.canvas) == null ? void 0 : W.width) ?? "0",
|
|
722
722
|
height: ((L = U.canvas) == null ? void 0 : L.height) ?? "0"
|
|
723
723
|
};
|
|
724
724
|
}
|
|
725
725
|
ut(P, y), fe(O, y);
|
|
726
726
|
function y() {
|
|
727
|
-
let
|
|
727
|
+
let W = O.value.width || c, L = O.value.height || $;
|
|
728
728
|
s.value = {
|
|
729
|
-
width: P.value +
|
|
729
|
+
width: P.value + W + "px",
|
|
730
730
|
// 滚动框宽度,包含额外的宽度
|
|
731
731
|
height: i.value + L + "px"
|
|
732
732
|
// 滚动框高度,包含额外的高度
|
|
733
733
|
}, Y.value = {
|
|
734
|
-
width:
|
|
734
|
+
width: W + "px",
|
|
735
735
|
// 画布宽度
|
|
736
736
|
height: L + "px"
|
|
737
737
|
// 画布高度
|
|
738
738
|
}, j();
|
|
739
739
|
}
|
|
740
740
|
function j() {
|
|
741
|
-
|
|
741
|
+
We(() => {
|
|
742
742
|
var se;
|
|
743
|
-
let
|
|
744
|
-
const
|
|
745
|
-
(se = v.value) == null || se.scrollTo(ee,
|
|
743
|
+
let W = O.value.width || c;
|
|
744
|
+
const z = (O.value.height || $) / 2, ee = W / 2;
|
|
745
|
+
(se = v.value) == null || se.scrollTo(ee, z);
|
|
746
746
|
});
|
|
747
747
|
}
|
|
748
|
-
_e(v, ce), _e(
|
|
748
|
+
_e(v, ce), _e(n, ce);
|
|
749
749
|
function ce() {
|
|
750
750
|
var L;
|
|
751
751
|
if (!v.value) return;
|
|
752
|
-
const
|
|
753
|
-
if (c =
|
|
752
|
+
const W = v.value.getBoundingClientRect();
|
|
753
|
+
if (c = W.width - 60, $ = W.height - 80, !a.value)
|
|
754
754
|
if (O.value.width === 0)
|
|
755
755
|
r.value = 1;
|
|
756
756
|
else {
|
|
757
|
-
const
|
|
757
|
+
const z = (c - 20) / O.value.width, ee = $ / (O.value.height || ((L = n.value) == null ? void 0 : L.clientHeight) || 1), se = Math.abs(z - 1) < Math.abs(ee - 1);
|
|
758
758
|
let K = 1;
|
|
759
|
-
se ? K =
|
|
759
|
+
se ? K = z : K = ee, (z < 1 || ee < 1) && (K = Math.min(z, ee)), K < 1.4 && K > 0.5 && (r.value = K);
|
|
760
760
|
}
|
|
761
761
|
ht(y, 50)();
|
|
762
762
|
}
|
|
763
|
-
return (
|
|
763
|
+
return (W, L) => (H(), F("div", Lt, [
|
|
764
764
|
B(Mt),
|
|
765
765
|
V("div", {
|
|
766
766
|
ref_key: "editScreenContainerRef",
|
|
767
767
|
ref: v,
|
|
768
|
-
class: pe(["flex-1 overflow-auto overflow-y-hidden epic-edit-screen-container", { "cursor-grab": u(
|
|
769
|
-
draggable: u(
|
|
768
|
+
class: pe(["flex-1 overflow-auto overflow-y-hidden epic-edit-screen-container", { "cursor-grab": u(w) }]),
|
|
769
|
+
draggable: u(w),
|
|
770
770
|
onWheel: L[0] || (L[0] = //@ts-ignore
|
|
771
|
-
(...
|
|
771
|
+
(...z) => u(h) && u(h)(...z)),
|
|
772
772
|
onDragstart: L[1] || (L[1] = //@ts-ignore
|
|
773
|
-
(...
|
|
773
|
+
(...z) => u(m) && u(m)(...z)),
|
|
774
774
|
onDragend: L[2] || (L[2] = //@ts-ignore
|
|
775
|
-
(...
|
|
775
|
+
(...z) => u(S) && u(S)(...z)),
|
|
776
776
|
onDrag: L[3] || (L[3] = //@ts-ignore
|
|
777
|
-
(...
|
|
777
|
+
(...z) => u(I) && u(I)(...z))
|
|
778
778
|
}, [
|
|
779
779
|
V("div", {
|
|
780
780
|
id: "canvasContainer",
|
|
@@ -783,14 +783,14 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
783
783
|
}, [
|
|
784
784
|
V("div", {
|
|
785
785
|
ref_key: "draggableElRef",
|
|
786
|
-
ref:
|
|
786
|
+
ref: n,
|
|
787
787
|
class: "transition-all"
|
|
788
788
|
}, [
|
|
789
789
|
V("div", {
|
|
790
|
-
class: pe({ "pointer-events-none": u(
|
|
790
|
+
class: pe({ "pointer-events-none": u(w) }),
|
|
791
791
|
style: ye(Y.value)
|
|
792
792
|
}, [
|
|
793
|
-
|
|
793
|
+
nt(W.$slots, "default")
|
|
794
794
|
], 6)
|
|
795
795
|
], 512)
|
|
796
796
|
], 4)
|
|
@@ -805,12 +805,12 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
805
805
|
}
|
|
806
806
|
}), It = { class: "epic-edit-canvas" }, Pt = /* @__PURE__ */ re({
|
|
807
807
|
__name: "index",
|
|
808
|
-
setup(
|
|
809
|
-
const U = M(null), v = M(null),
|
|
808
|
+
setup(oe) {
|
|
809
|
+
const U = M(null), v = M(null), n = A("pageSchema"), t = q(() => n.schemas[0]), w = q(() => ({
|
|
810
810
|
width: "100%",
|
|
811
811
|
height: "100%"
|
|
812
812
|
}));
|
|
813
|
-
return
|
|
813
|
+
return ot(() => {
|
|
814
814
|
var a;
|
|
815
815
|
(a = v.value) == null || a.handleInit(U.value);
|
|
816
816
|
}), (a, m) => (H(), F("section", It, [
|
|
@@ -820,9 +820,9 @@ const mt = { class: "epic-widget-action-item whitespace-nowrap" }, gt = {
|
|
|
820
820
|
ref_key: "epicEditRangeRef",
|
|
821
821
|
ref: U,
|
|
822
822
|
class: "epic-edit-range rounded-md overflow-auto relative",
|
|
823
|
-
style: ye(
|
|
823
|
+
style: ye(w.value)
|
|
824
824
|
}, [
|
|
825
|
-
B(
|
|
825
|
+
B(ze, { schema: t.value }, null, 8, ["schema"]),
|
|
826
826
|
B(yt, {
|
|
827
827
|
ref_key: "ePreviewWidgetsRef",
|
|
828
828
|
ref: v
|