x-prop-tree 0.7.4 → 0.7.6
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/index.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { provide as ce, inject as de, defineComponent as R, ref as O, computed as K, resolveComponent as
|
|
1
|
+
import { provide as ce, inject as de, defineComponent as R, ref as O, computed as K, resolveComponent as $, createBlock as B, openBlock as C, unref as L, isRef as ve, withCtx as J, createVNode as D, createElementBlock as E, Fragment as Ve, renderList as Be, createTextVNode as Ce, toDisplayString as W, resolveDirective as le, withDirectives as ee, withModifiers as X, normalizeStyle as I, createElementVNode as F, createCommentVNode as G, renderSlot as ft, h, mergeModels as Y, useModel as z, useId as we, onUnmounted as De, withKeys as Ke, mergeProps as be, watchEffect as Ne, watch as re, useTemplateRef as Je, reactive as mt, onMounted as vt, onBeforeUnmount as pt } from "vue";
|
|
2
2
|
import { useI18n as te } from "vue-i18n";
|
|
3
|
-
import { useViewStack as
|
|
4
|
-
import { c as
|
|
5
|
-
import { getPropDefault as q, pkgs as
|
|
6
|
-
import { globalState as
|
|
7
|
-
import { useDisplay as
|
|
8
|
-
import { XBlockly as
|
|
9
|
-
const
|
|
10
|
-
let t = { key: "", name: "", children:
|
|
3
|
+
import { useViewStack as Se, useColor as ie, eventBus as ue, useSystem as pe, openPromptDlg as yt, openNumberDlg as Re, injectDark as gt, injectLocale as ht } from "x-essential-lib";
|
|
4
|
+
import { c as Ee, i as Ue, r as He, v as _t, d as kt } from "./vendor.n68iqk3a.js";
|
|
5
|
+
import { getPropDefault as q, pkgs as Fe, parsePixelStr as Vt, parsePercentStr as Ct } from "x-runtime-lib";
|
|
6
|
+
import { globalState as St } from "x-state-lib";
|
|
7
|
+
import { useDisplay as Ut } from "vuetify";
|
|
8
|
+
import { XBlockly as $t } from "x-block-lib";
|
|
9
|
+
const _e = (l, s) => {
|
|
10
|
+
let t = { key: "", name: "", children: l };
|
|
11
11
|
return s.forEach((e) => {
|
|
12
12
|
if (typeof e != "number") {
|
|
13
13
|
if (!t) {
|
|
@@ -21,8 +21,8 @@ const he = (o, s) => {
|
|
|
21
21
|
t = t.children.find((n) => n.key === e);
|
|
22
22
|
}
|
|
23
23
|
}), t;
|
|
24
|
-
}, me = (
|
|
25
|
-
let t =
|
|
24
|
+
}, me = (l, s) => {
|
|
25
|
+
let t = l;
|
|
26
26
|
return s.forEach((e) => {
|
|
27
27
|
if (!t) {
|
|
28
28
|
console.assert(!1, `unpkgObject object must be valid keys=${s}`);
|
|
@@ -30,7 +30,7 @@ const he = (o, s) => {
|
|
|
30
30
|
}
|
|
31
31
|
t = t[e];
|
|
32
32
|
}), t;
|
|
33
|
-
},
|
|
33
|
+
}, Oe = (l) => !(l instanceof Array), Me = (l) => l instanceof Array, xt = (l, s) => {
|
|
34
34
|
const t = (e, n) => {
|
|
35
35
|
if (e.ui !== n.ui || e.array !== n.array)
|
|
36
36
|
return !1;
|
|
@@ -38,277 +38,277 @@ const he = (o, s) => {
|
|
|
38
38
|
return !0;
|
|
39
39
|
if (e.children.length !== n.children.length)
|
|
40
40
|
return !1;
|
|
41
|
-
for (let
|
|
42
|
-
if (!t(e.children[
|
|
41
|
+
for (let o = 0; o < e.children.length; o++)
|
|
42
|
+
if (!t(e.children[o], n.children[o]))
|
|
43
43
|
return !1;
|
|
44
44
|
return !0;
|
|
45
45
|
};
|
|
46
|
-
return t(
|
|
47
|
-
}, Ae = (
|
|
46
|
+
return t(l, s);
|
|
47
|
+
}, Ae = (l) => !(l instanceof Array), $e = (l) => l instanceof Array, Pt = [
|
|
48
48
|
["basic", "id"],
|
|
49
49
|
["basic", "name"]
|
|
50
|
-
],
|
|
51
|
-
|
|
50
|
+
], Mt = (l) => Pt.find((s) => Ue(l, s)), xe = (l, s, t, e, n, o, i) => (l = Ee(l), o !== void 0 ? (l.push(o), i && l.push(s.key)) : l.push(s.key), Mt(l) ? (e.change = !1, e.change) : s.ui ? s.array && e.children && $e(e.children) ? bt(
|
|
51
|
+
l,
|
|
52
52
|
s,
|
|
53
53
|
t,
|
|
54
54
|
e,
|
|
55
55
|
n,
|
|
56
|
-
l,
|
|
57
|
-
i
|
|
58
|
-
) : Dt(s, t, e, l, i) : s.array ? Pt(
|
|
59
56
|
o,
|
|
57
|
+
i
|
|
58
|
+
) : At(s, t, e, o, i) : s.array ? wt(
|
|
59
|
+
l,
|
|
60
60
|
s,
|
|
61
61
|
t,
|
|
62
62
|
e,
|
|
63
63
|
n,
|
|
64
|
-
l,
|
|
65
|
-
i
|
|
66
|
-
) : Mt(
|
|
67
64
|
o,
|
|
65
|
+
i
|
|
66
|
+
) : Dt(
|
|
67
|
+
l,
|
|
68
68
|
s,
|
|
69
69
|
t,
|
|
70
70
|
e,
|
|
71
71
|
n,
|
|
72
|
-
|
|
72
|
+
o,
|
|
73
73
|
i
|
|
74
|
-
)),
|
|
74
|
+
)), wt = (l, s, t, e, n, o, i) => {
|
|
75
75
|
if (s.ui)
|
|
76
76
|
return console.assert(!1, "execPropBranchArray prop ui must be invalid"), !1;
|
|
77
77
|
if (!s.array)
|
|
78
78
|
return console.assert(!1, "execPropBranchArray prop array must be valid"), !1;
|
|
79
|
-
if (!e.children ||
|
|
79
|
+
if (!e.children || !$e(e.children))
|
|
80
80
|
return console.assert(!1, "execPropBranchArray state children must be array"), !1;
|
|
81
|
-
let
|
|
82
|
-
|
|
83
|
-
for (let u = 0; u <
|
|
81
|
+
let r;
|
|
82
|
+
o !== void 0 && !i ? (t[o] instanceof Array || (t[o] = q(s), n?.(l, t[o])), r = t[o]) : (t[s.key] instanceof Array || (t[s.key] = q(s), n?.(l, t[s.key])), r = t[s.key]), e.change = !1;
|
|
83
|
+
for (let u = 0; u < r.length; u++) {
|
|
84
84
|
e.children.push({
|
|
85
85
|
change: !1,
|
|
86
86
|
children: {}
|
|
87
87
|
});
|
|
88
|
-
const
|
|
89
|
-
s.children.forEach((
|
|
90
|
-
if (!
|
|
88
|
+
const a = e.children[u];
|
|
89
|
+
s.children.forEach((f) => {
|
|
90
|
+
if (!a.children || !Ae(a.children)) {
|
|
91
91
|
console.assert(!1);
|
|
92
92
|
return;
|
|
93
93
|
}
|
|
94
|
-
|
|
94
|
+
a.children[f.key] = {
|
|
95
95
|
change: !1,
|
|
96
|
-
children:
|
|
97
|
-
},
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
96
|
+
children: f.array ? [] : {}
|
|
97
|
+
}, xe(
|
|
98
|
+
l,
|
|
99
|
+
f,
|
|
100
|
+
r[u],
|
|
101
|
+
a.children[f.key],
|
|
102
102
|
n,
|
|
103
103
|
u,
|
|
104
104
|
!0
|
|
105
|
-
) && (
|
|
105
|
+
) && (a.change = !0), a.change && (e.change = !0);
|
|
106
106
|
});
|
|
107
107
|
}
|
|
108
|
-
return e.change || (e.change = !
|
|
109
|
-
},
|
|
108
|
+
return e.change || (e.change = !Ue(r, q(s))), e.change;
|
|
109
|
+
}, Dt = (l, s, t, e, n, o, i) => {
|
|
110
110
|
if (s.ui)
|
|
111
111
|
return console.assert(!1, "execPropBranchScalar prop ui must be invalid"), !1;
|
|
112
112
|
if (s.array)
|
|
113
113
|
return console.assert(!1, "execPropBranchScalar prop array must be invalid"), !1;
|
|
114
114
|
if (!e.children || !Ae(e.children))
|
|
115
115
|
return console.assert(!1, "execPropBranchScalar state children must be map"), !1;
|
|
116
|
-
let
|
|
117
|
-
|
|
116
|
+
let r;
|
|
117
|
+
o !== void 0 && !i ? (t[o] || (t[o] = {}), r = t[o]) : (t[s.key] || (t[s.key] = {}), r = t[s.key]), e.change = !1;
|
|
118
118
|
for (let u = 0; u < s.children.length; u++) {
|
|
119
|
-
const
|
|
120
|
-
e.children[
|
|
119
|
+
const a = s.children[u];
|
|
120
|
+
e.children[a.key] = {
|
|
121
121
|
change: !1,
|
|
122
|
-
children:
|
|
123
|
-
},
|
|
122
|
+
children: a.array ? [] : {}
|
|
123
|
+
}, xe(l, a, r, e.children[a.key], n) && (e.change = !0);
|
|
124
124
|
}
|
|
125
125
|
return e.change;
|
|
126
|
-
},
|
|
126
|
+
}, bt = (l, s, t, e, n, o, i) => {
|
|
127
127
|
if (!s.ui)
|
|
128
128
|
return console.assert(!1, "execPropLeafArray prop ui must be valid"), !1;
|
|
129
129
|
if (!s.array)
|
|
130
130
|
return console.assert(!1, "execPropLeafArray prop aray must be valid"), !1;
|
|
131
|
-
if (!e.children ||
|
|
131
|
+
if (!e.children || !$e(e.children))
|
|
132
132
|
return console.assert(!1, "execPropLeafArray state children must be array"), !1;
|
|
133
|
-
let
|
|
134
|
-
|
|
135
|
-
for (let u = 0; u <
|
|
133
|
+
let r;
|
|
134
|
+
o !== void 0 && !i ? (t[o] instanceof Array || (t[o] = q(s), n?.(l, t[o])), r = t[o]) : (t[s.key] instanceof Array || (t[s.key] = q(s), n?.(l, t[s.key])), r = t[s.key]), e.change = !1;
|
|
135
|
+
for (let u = 0; u < r.length; u++)
|
|
136
136
|
e.children[u] = {
|
|
137
137
|
change: !1,
|
|
138
138
|
children: {}
|
|
139
|
-
},
|
|
140
|
-
return e.change || (e.change = !
|
|
141
|
-
},
|
|
142
|
-
if (!
|
|
139
|
+
}, xe(l, s, r, e.children[u], n, u, !1) && (e.change = !0);
|
|
140
|
+
return e.change || (e.change = !Ue(r, q(s))), e.change;
|
|
141
|
+
}, At = (l, s, t, e, n) => {
|
|
142
|
+
if (!l.ui)
|
|
143
143
|
return console.assert(!1, "execPropLeafScalar prop ui must be valid"), !1;
|
|
144
|
-
let
|
|
145
|
-
return e !== void 0 && !n ?
|
|
146
|
-
},
|
|
144
|
+
let o;
|
|
145
|
+
return e !== void 0 && !n ? o = s[e] : o = s[l.key], t.change = !Ue(o, q(l, !0)), t.change;
|
|
146
|
+
}, qe = (l, s, t, e) => {
|
|
147
147
|
if (s.length <= 0 || !t) {
|
|
148
|
-
|
|
148
|
+
l.value = {};
|
|
149
149
|
return;
|
|
150
150
|
}
|
|
151
151
|
const n = {};
|
|
152
|
-
s.forEach((
|
|
153
|
-
n[
|
|
152
|
+
s.forEach((o) => {
|
|
153
|
+
n[o.key] = {
|
|
154
154
|
change: !1,
|
|
155
|
-
children:
|
|
156
|
-
},
|
|
157
|
-
}),
|
|
158
|
-
}, ae = (
|
|
159
|
-
let t = { change: !1, children:
|
|
155
|
+
children: o.array ? [] : {}
|
|
156
|
+
}, xe([], o, t, n[o.key], e);
|
|
157
|
+
}), l.value = n;
|
|
158
|
+
}, ae = (l, s) => {
|
|
159
|
+
let t = { change: !1, children: l };
|
|
160
160
|
return s.forEach((e) => {
|
|
161
161
|
if (!t)
|
|
162
162
|
return console.assert(!1, `isPropChanged state must be valid keys=${s}`), !1;
|
|
163
163
|
if (!t.children)
|
|
164
164
|
return console.assert(!1, `isPropChanged state must be valid keys=${s}`), !1;
|
|
165
|
-
typeof e == "string" ? Ae(t.children) && (t = t.children[e]) :
|
|
165
|
+
typeof e == "string" ? Ae(t.children) && (t = t.children[e]) : $e(t.children) && (t = t.children[e]);
|
|
166
166
|
}), t?.change ?? !1;
|
|
167
|
-
}, Xe = Symbol(),
|
|
168
|
-
function
|
|
169
|
-
ce(Xe,
|
|
167
|
+
}, Xe = Symbol(), ze = Symbol(), Ge = Symbol(), Ye = Symbol(), We = Symbol(), Qe = Symbol();
|
|
168
|
+
function Tt(l) {
|
|
169
|
+
ce(Xe, l);
|
|
170
170
|
}
|
|
171
|
-
function
|
|
171
|
+
function Te() {
|
|
172
172
|
return de(Xe);
|
|
173
173
|
}
|
|
174
|
-
function
|
|
175
|
-
ce(
|
|
176
|
-
}
|
|
177
|
-
function Tt() {
|
|
178
|
-
return de(Fe);
|
|
179
|
-
}
|
|
180
|
-
function Lt(o) {
|
|
181
|
-
ce(ze, o);
|
|
174
|
+
function Lt(l) {
|
|
175
|
+
ce(ze, l);
|
|
182
176
|
}
|
|
183
177
|
function Nt() {
|
|
184
178
|
return de(ze);
|
|
185
179
|
}
|
|
186
|
-
function Ot(
|
|
187
|
-
ce(Ge,
|
|
180
|
+
function Ot(l) {
|
|
181
|
+
ce(Ge, l);
|
|
188
182
|
}
|
|
189
183
|
function qt() {
|
|
190
184
|
return de(Ge);
|
|
191
185
|
}
|
|
192
|
-
function Bt(
|
|
193
|
-
ce(Ye,
|
|
186
|
+
function Bt(l) {
|
|
187
|
+
ce(Ye, l);
|
|
194
188
|
}
|
|
195
189
|
function Kt() {
|
|
196
190
|
return de(Ye);
|
|
197
191
|
}
|
|
198
|
-
function Jt(
|
|
199
|
-
ce(We,
|
|
192
|
+
function Jt(l) {
|
|
193
|
+
ce(We, l);
|
|
200
194
|
}
|
|
201
|
-
function
|
|
195
|
+
function Rt() {
|
|
202
196
|
return de(We);
|
|
203
197
|
}
|
|
204
|
-
|
|
198
|
+
function Et(l) {
|
|
199
|
+
ce(Qe, l);
|
|
200
|
+
}
|
|
201
|
+
function Ze() {
|
|
202
|
+
return de(Qe);
|
|
203
|
+
}
|
|
204
|
+
const Ht = /* @__PURE__ */ R({
|
|
205
205
|
__name: "menu",
|
|
206
|
-
setup(
|
|
207
|
-
const { t: s } = te(), t =
|
|
208
|
-
const
|
|
209
|
-
const
|
|
210
|
-
if (
|
|
211
|
-
if (
|
|
212
|
-
const
|
|
213
|
-
if (!
|
|
206
|
+
setup(l) {
|
|
207
|
+
const { t: s } = te(), t = Nt(), e = qt(), n = Kt(), o = Rt(), i = O(0), r = O(0), u = O([]), a = K(() => [i.value, r.value]), f = (P) => {
|
|
208
|
+
const T = () => !(u.value.length <= 0 || !ae(n.value, u.value)), w = () => {
|
|
209
|
+
const _ = _e(t.value, u.value);
|
|
210
|
+
if (_)
|
|
211
|
+
if (_.ui) {
|
|
212
|
+
const M = me(e.value, u.value.slice(0, -1));
|
|
213
|
+
if (!M)
|
|
214
214
|
return;
|
|
215
|
-
|
|
216
|
-
} else if (
|
|
217
|
-
const
|
|
218
|
-
if (
|
|
215
|
+
M[u.value[u.value.length - 1]] = q(_), o(u.value, M[u.value[u.value.length - 1]]);
|
|
216
|
+
} else if (_.array) {
|
|
217
|
+
const M = u.value[u.value.length - 1];
|
|
218
|
+
if (M === void 0) {
|
|
219
219
|
console.assert(!1, "invalid last key");
|
|
220
220
|
return;
|
|
221
221
|
}
|
|
222
|
-
if (typeof
|
|
222
|
+
if (typeof M == "string") {
|
|
223
223
|
const N = me(e.value, u.value.slice(0, -1));
|
|
224
224
|
if (!N)
|
|
225
225
|
return;
|
|
226
|
-
N[u.value[u.value.length - 1]] = q(
|
|
226
|
+
N[u.value[u.value.length - 1]] = q(_), o(u.value, N[u.value[u.value.length - 1]]);
|
|
227
227
|
} else {
|
|
228
228
|
const N = me(e.value, u.value);
|
|
229
229
|
if (!N)
|
|
230
230
|
return;
|
|
231
|
-
|
|
232
|
-
N[Q.key] = q(
|
|
231
|
+
_.children.forEach((Q) => {
|
|
232
|
+
N[Q.key] = q(_), o([...u.value, Q.key], N[Q.key]);
|
|
233
233
|
});
|
|
234
234
|
}
|
|
235
235
|
} else {
|
|
236
|
-
const
|
|
237
|
-
if (!
|
|
236
|
+
const M = me(e.value, u.value);
|
|
237
|
+
if (!M)
|
|
238
238
|
return;
|
|
239
|
-
|
|
240
|
-
|
|
239
|
+
_.children.forEach((N) => {
|
|
240
|
+
M[N.key] = q(_), o([...u.value, N.key], M[N.key]);
|
|
241
241
|
});
|
|
242
242
|
}
|
|
243
243
|
};
|
|
244
|
-
|
|
244
|
+
T() && P.push({
|
|
245
245
|
title: s("x-prop-tree.reset"),
|
|
246
|
-
func:
|
|
246
|
+
func: w
|
|
247
247
|
});
|
|
248
248
|
}, d = (P) => {
|
|
249
|
-
const
|
|
250
|
-
const
|
|
251
|
-
localStorage.setItem("propTreeCopy", JSON.stringify({ prop:
|
|
249
|
+
const T = () => {
|
|
250
|
+
const w = _e(t.value, u.value), _ = me(e.value, u.value);
|
|
251
|
+
localStorage.setItem("propTreeCopy", JSON.stringify({ prop: w, object: _ }));
|
|
252
252
|
};
|
|
253
253
|
P.push({
|
|
254
254
|
title: s("x-prop-tree.copy"),
|
|
255
|
-
func:
|
|
255
|
+
func: T
|
|
256
256
|
});
|
|
257
|
-
},
|
|
258
|
-
const
|
|
259
|
-
const
|
|
260
|
-
if (!
|
|
257
|
+
}, y = (P) => {
|
|
258
|
+
const T = () => {
|
|
259
|
+
const _ = localStorage.getItem("propTreeCopy");
|
|
260
|
+
if (!_)
|
|
261
261
|
return !1;
|
|
262
262
|
try {
|
|
263
|
-
const { prop:
|
|
264
|
-
return
|
|
265
|
-
} catch (
|
|
266
|
-
console.error(
|
|
263
|
+
const { prop: M } = JSON.parse(_), N = _e(t.value, u.value);
|
|
264
|
+
return xt(M, N);
|
|
265
|
+
} catch (M) {
|
|
266
|
+
console.error(M);
|
|
267
267
|
}
|
|
268
268
|
return !1;
|
|
269
|
-
},
|
|
270
|
-
if (!
|
|
269
|
+
}, w = () => {
|
|
270
|
+
if (!T())
|
|
271
271
|
return;
|
|
272
|
-
const
|
|
273
|
-
if (
|
|
272
|
+
const _ = localStorage.getItem("propTreeCopy");
|
|
273
|
+
if (_)
|
|
274
274
|
try {
|
|
275
|
-
const { object:
|
|
276
|
-
console.log(
|
|
277
|
-
} catch (
|
|
278
|
-
console.error(
|
|
275
|
+
const { object: M } = JSON.parse(_), N = _e(t.value, u.value);
|
|
276
|
+
console.log(M, N);
|
|
277
|
+
} catch (M) {
|
|
278
|
+
console.error(M);
|
|
279
279
|
}
|
|
280
280
|
};
|
|
281
|
-
|
|
281
|
+
T() && P.push({
|
|
282
282
|
title: s("x-prop-tree.paste"),
|
|
283
|
-
func:
|
|
283
|
+
func: w
|
|
284
284
|
});
|
|
285
|
-
},
|
|
285
|
+
}, g = K(() => {
|
|
286
286
|
const P = [];
|
|
287
|
-
return
|
|
288
|
-
}),
|
|
289
|
-
i.value = P.x,
|
|
290
|
-
}, { open:
|
|
291
|
-
return (P,
|
|
292
|
-
const
|
|
293
|
-
return
|
|
294
|
-
modelValue:
|
|
295
|
-
"onUpdate:modelValue":
|
|
287
|
+
return f(P), d(P), y(P), P;
|
|
288
|
+
}), k = (P) => {
|
|
289
|
+
i.value = P.x, r.value = P.y, u.value = P.keys;
|
|
290
|
+
}, { open: S } = Se("propTreeMenu", k);
|
|
291
|
+
return (P, T) => {
|
|
292
|
+
const w = $("v-list-item-title"), _ = $("v-list-item"), M = $("v-list"), N = $("v-menu");
|
|
293
|
+
return C(), B(N, {
|
|
294
|
+
modelValue: L(S),
|
|
295
|
+
"onUpdate:modelValue": T[0] || (T[0] = (Q) => ve(S) ? S.value = Q : null),
|
|
296
296
|
"location-strategy": "connected",
|
|
297
|
-
target:
|
|
297
|
+
target: a.value,
|
|
298
298
|
scrim: "transparent"
|
|
299
299
|
}, {
|
|
300
300
|
default: J(() => [
|
|
301
|
-
M
|
|
301
|
+
D(M, null, {
|
|
302
302
|
default: J(() => [
|
|
303
|
-
(
|
|
304
|
-
key:
|
|
303
|
+
(C(!0), E(Ve, null, Be(g.value, (Q, Pe) => (C(), B(_, {
|
|
304
|
+
key: Pe,
|
|
305
305
|
link: "",
|
|
306
306
|
onClick: Q.func
|
|
307
307
|
}, {
|
|
308
308
|
default: J(() => [
|
|
309
|
-
|
|
309
|
+
D(w, null, {
|
|
310
310
|
default: J(() => [
|
|
311
|
-
|
|
311
|
+
Ce(W(Q.title), 1)
|
|
312
312
|
]),
|
|
313
313
|
_: 2
|
|
314
314
|
}, 1024)
|
|
@@ -323,7 +323,7 @@ const Rt = /* @__PURE__ */ R({
|
|
|
323
323
|
}, 8, ["modelValue", "target"]);
|
|
324
324
|
};
|
|
325
325
|
}
|
|
326
|
-
}),
|
|
326
|
+
}), Ft = { style: { pointerEvents: "none" } }, ke = /* @__PURE__ */ R({
|
|
327
327
|
__name: "title",
|
|
328
328
|
props: {
|
|
329
329
|
title: {},
|
|
@@ -333,149 +333,149 @@ const Rt = /* @__PURE__ */ R({
|
|
|
333
333
|
index: { default: 0 }
|
|
334
334
|
},
|
|
335
335
|
emits: ["collapse", "menu", "create", "delete"],
|
|
336
|
-
setup(
|
|
337
|
-
const { backgroundColor2: t, highlightColor: e } = ie(), n = s,
|
|
338
|
-
background:
|
|
336
|
+
setup(l, { emit: s }) {
|
|
337
|
+
const { backgroundColor2: t, highlightColor: e } = ie(), n = s, o = O(!1), i = K(() => ({
|
|
338
|
+
background: o.value ? e.value : t.value,
|
|
339
339
|
height: "36px",
|
|
340
340
|
marginBottom: "1px",
|
|
341
341
|
userSelect: "none"
|
|
342
|
-
})),
|
|
343
|
-
n("collapse", !
|
|
344
|
-
}, u = (
|
|
345
|
-
n("menu",
|
|
342
|
+
})), r = () => {
|
|
343
|
+
n("collapse", !l.collapse);
|
|
344
|
+
}, u = (a) => {
|
|
345
|
+
n("menu", a.clientX, a.clientY);
|
|
346
346
|
};
|
|
347
|
-
return (
|
|
348
|
-
const d =
|
|
349
|
-
return ee((
|
|
347
|
+
return (a, f) => {
|
|
348
|
+
const d = $("v-icon"), y = $("v-spacer"), g = $("v-btn"), k = le("ripple");
|
|
349
|
+
return ee((C(), E("div", {
|
|
350
350
|
class: "d-flex align-center cursor-pointer",
|
|
351
351
|
style: I(i.value),
|
|
352
|
-
onClick:
|
|
353
|
-
onContextmenu:
|
|
354
|
-
onMouseover:
|
|
355
|
-
onMouseout:
|
|
352
|
+
onClick: r,
|
|
353
|
+
onContextmenu: X(u, ["self", "prevent"]),
|
|
354
|
+
onMouseover: f[2] || (f[2] = (S) => o.value = !0),
|
|
355
|
+
onMouseout: f[3] || (f[3] = (S) => o.value = !1)
|
|
356
356
|
}, [
|
|
357
|
-
|
|
357
|
+
D(d, {
|
|
358
358
|
class: "mr-1",
|
|
359
|
-
icon:
|
|
359
|
+
icon: a.collapse ? "mdi-chevron-right" : "mdi-chevron-down"
|
|
360
360
|
}, null, 8, ["icon"]),
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
361
|
+
F("span", Ft, W(a.title), 1),
|
|
362
|
+
D(y),
|
|
363
|
+
a.hasCreate ? (C(), B(g, {
|
|
364
364
|
key: 0,
|
|
365
365
|
class: "mx-3",
|
|
366
366
|
variant: "text",
|
|
367
367
|
density: "compact",
|
|
368
368
|
icon: "mdi-plus",
|
|
369
|
-
onClick:
|
|
369
|
+
onClick: f[0] || (f[0] = X((S) => n("create"), ["stop"]))
|
|
370
370
|
})) : G("", !0),
|
|
371
|
-
|
|
371
|
+
a.hasDelete ? (C(), B(g, {
|
|
372
372
|
key: 1,
|
|
373
373
|
class: "mx-3",
|
|
374
374
|
variant: "text",
|
|
375
375
|
density: "compact",
|
|
376
376
|
icon: "mdi-minus",
|
|
377
|
-
onClick:
|
|
377
|
+
onClick: f[1] || (f[1] = X((S) => n("delete", a.index), ["stop"]))
|
|
378
378
|
})) : G("", !0)
|
|
379
379
|
], 36)), [
|
|
380
|
-
[
|
|
380
|
+
[k]
|
|
381
381
|
]);
|
|
382
382
|
};
|
|
383
383
|
}
|
|
384
|
-
}),
|
|
384
|
+
}), Xt = /* @__PURE__ */ R({
|
|
385
385
|
__name: "entry",
|
|
386
386
|
props: {
|
|
387
387
|
minHeight: {}
|
|
388
388
|
},
|
|
389
389
|
emits: ["menu"],
|
|
390
|
-
setup(
|
|
391
|
-
const { backgroundColor2: t, highlightColor: e } = ie(), n = s,
|
|
392
|
-
background:
|
|
393
|
-
minHeight:
|
|
390
|
+
setup(l, { emit: s }) {
|
|
391
|
+
const { backgroundColor2: t, highlightColor: e } = ie(), n = s, o = O(!1), i = K(() => ({
|
|
392
|
+
background: o.value ? e.value : t.value,
|
|
393
|
+
minHeight: l.minHeight,
|
|
394
394
|
paddingRight: "4px",
|
|
395
395
|
marginBottom: "1px",
|
|
396
396
|
userSelect: "none"
|
|
397
|
-
})),
|
|
397
|
+
})), r = (u) => {
|
|
398
398
|
n("menu", u.clientX, u.clientY);
|
|
399
399
|
};
|
|
400
|
-
return (u,
|
|
401
|
-
const
|
|
402
|
-
return ee((
|
|
400
|
+
return (u, a) => {
|
|
401
|
+
const f = le("ripple");
|
|
402
|
+
return ee((C(), E("div", {
|
|
403
403
|
class: "d-flex justify-space-between align-center cursor-pointer",
|
|
404
404
|
style: I(i.value),
|
|
405
|
-
onContextmenu:
|
|
406
|
-
onMouseover:
|
|
407
|
-
onMouseout:
|
|
405
|
+
onContextmenu: X(r, ["self", "prevent"]),
|
|
406
|
+
onMouseover: a[0] || (a[0] = (d) => o.value = !0),
|
|
407
|
+
onMouseout: a[1] || (a[1] = (d) => o.value = !1)
|
|
408
408
|
}, [
|
|
409
|
-
|
|
409
|
+
ft(u.$slots, "default")
|
|
410
410
|
], 36)), [
|
|
411
|
-
[
|
|
411
|
+
[f]
|
|
412
412
|
]);
|
|
413
413
|
};
|
|
414
414
|
}
|
|
415
415
|
});
|
|
416
|
-
function
|
|
416
|
+
function zt(l, s, t) {
|
|
417
417
|
const { t: e } = te();
|
|
418
|
-
return { renderProp: (
|
|
419
|
-
const u =
|
|
420
|
-
let
|
|
421
|
-
return ae(
|
|
422
|
-
|
|
418
|
+
return { renderProp: (o, i, r) => {
|
|
419
|
+
const u = o[o.length - 1];
|
|
420
|
+
let f = typeof u == "number" ? `[${u + 1}]` : e(i.name);
|
|
421
|
+
return ae(l.value, o) && (f += " *"), h(
|
|
422
|
+
Xt,
|
|
423
423
|
{
|
|
424
424
|
minHeight: s.value,
|
|
425
|
-
onMenu: (d,
|
|
426
|
-
ue.emit("propTreeMenu", { x: d, y
|
|
425
|
+
onMenu: (d, y) => {
|
|
426
|
+
ue.emit("propTreeMenu", { x: d, y, keys: o });
|
|
427
427
|
}
|
|
428
428
|
},
|
|
429
429
|
() => [
|
|
430
430
|
h("span", {
|
|
431
431
|
style: { marginLeft: "4px", pointerEvents: "none" },
|
|
432
|
-
innerHTML:
|
|
432
|
+
innerHTML: f
|
|
433
433
|
}),
|
|
434
|
-
h("div", { style: { width: t.value } },
|
|
434
|
+
h("div", { style: { width: t.value } }, r)
|
|
435
435
|
]
|
|
436
436
|
);
|
|
437
437
|
} };
|
|
438
438
|
}
|
|
439
|
-
const ne = (
|
|
439
|
+
const ne = (l, s, t, e, n, o) => {
|
|
440
440
|
if (n !== void 0)
|
|
441
|
-
if (
|
|
441
|
+
if (o) {
|
|
442
442
|
if (t[s.key] === void 0) {
|
|
443
443
|
const i = q(s);
|
|
444
|
-
i !== void 0 && (t[s.key] = i, e(
|
|
444
|
+
i !== void 0 && (t[s.key] = i, e(l, t[s.key]));
|
|
445
445
|
}
|
|
446
446
|
return t[s.key];
|
|
447
447
|
} else {
|
|
448
448
|
if (t[n] === void 0) {
|
|
449
449
|
const i = q(s, !0);
|
|
450
|
-
i !== void 0 && (t[n] = i, e(
|
|
450
|
+
i !== void 0 && (t[n] = i, e(l, t[n]));
|
|
451
451
|
}
|
|
452
452
|
return t[n];
|
|
453
453
|
}
|
|
454
454
|
else {
|
|
455
455
|
if (t[s.key] === void 0) {
|
|
456
456
|
const i = q(s);
|
|
457
|
-
i !== void 0 && (t[s.key] = i, e(
|
|
457
|
+
i !== void 0 && (t[s.key] = i, e(l, t[s.key]));
|
|
458
458
|
}
|
|
459
459
|
return t[s.key];
|
|
460
460
|
}
|
|
461
|
-
}, oe = (
|
|
462
|
-
if (
|
|
463
|
-
i ? e !== t[s.key] && (t[s.key] = e, n(
|
|
461
|
+
}, oe = (l, s, t, e, n, o, i) => {
|
|
462
|
+
if (o !== void 0)
|
|
463
|
+
i ? e !== t[s.key] && (t[s.key] = e, n(l, t[s.key])) : e !== t[o] && (t[o] = e, n(l, t[o]));
|
|
464
464
|
else {
|
|
465
|
-
let
|
|
466
|
-
(s.ui === "switch" || s.ui === "select" || s.ui === "colorPicker" || s.ui === "multiTypes" || s.ui === "compSelect") && (e || (
|
|
465
|
+
let r = e;
|
|
466
|
+
(s.ui === "switch" || s.ui === "select" || s.ui === "colorPicker" || s.ui === "multiTypes" || s.ui === "compSelect") && (e || (r = void 0)), r !== t[s.key] && (t[s.key] = r, n(l, t[s.key]));
|
|
467
467
|
}
|
|
468
468
|
};
|
|
469
|
-
function
|
|
470
|
-
return { renderUiDummy: (t, e, n,
|
|
469
|
+
function Gt(l) {
|
|
470
|
+
return { renderUiDummy: (t, e, n, o, i) => {
|
|
471
471
|
if (e.ui !== "dummy") {
|
|
472
472
|
console.assert(!1, "renderUiDummy prop ui must be dummy");
|
|
473
473
|
return;
|
|
474
474
|
}
|
|
475
|
-
ne(t, e, n,
|
|
475
|
+
ne(t, e, n, l, o, i);
|
|
476
476
|
} };
|
|
477
477
|
}
|
|
478
|
-
const
|
|
478
|
+
const Yt = { class: "d-flex justify-space-between align-center" }, Wt = /* @__PURE__ */ R({
|
|
479
479
|
__name: "strInput",
|
|
480
480
|
props: /* @__PURE__ */ Y({
|
|
481
481
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -485,67 +485,76 @@ const zt = { class: "d-flex justify-space-between align-center" }, Gt = /* @__PU
|
|
|
485
485
|
modelModifiers: {}
|
|
486
486
|
}),
|
|
487
487
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
488
|
-
setup(
|
|
489
|
-
const t = z(
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
488
|
+
setup(l, { emit: s }) {
|
|
489
|
+
const { isMobile: t } = pe(), e = z(l, "modelValue"), n = s, o = async (i) => {
|
|
490
|
+
if (!i || l.readonly || !t())
|
|
491
|
+
return;
|
|
492
|
+
const r = await yt({
|
|
493
|
+
title: "",
|
|
494
|
+
value: e.value
|
|
495
|
+
});
|
|
496
|
+
r !== void 0 && (e.value = r);
|
|
497
|
+
};
|
|
498
|
+
return (i, r) => {
|
|
499
|
+
const u = $("v-text-field"), a = $("v-btn"), f = le("ripple");
|
|
500
|
+
return C(), E("div", Yt, [
|
|
501
|
+
ee(D(u, {
|
|
502
|
+
modelValue: e.value,
|
|
503
|
+
"onUpdate:modelValue": r[0] || (r[0] = (d) => e.value = d),
|
|
496
504
|
density: "compact",
|
|
497
505
|
"hide-details": "",
|
|
498
506
|
"single-line": "",
|
|
499
|
-
readonly:
|
|
507
|
+
readonly: i.readonly,
|
|
508
|
+
"onUpdate:focused": o
|
|
500
509
|
}, null, 8, ["modelValue", "readonly"]), [
|
|
501
510
|
[
|
|
502
|
-
|
|
511
|
+
f,
|
|
503
512
|
void 0,
|
|
504
513
|
void 0,
|
|
505
514
|
{ stop: !0 }
|
|
506
515
|
]
|
|
507
516
|
]),
|
|
508
|
-
|
|
517
|
+
i.hasDelete ? (C(), B(a, {
|
|
509
518
|
key: 0,
|
|
510
519
|
class: "mx-2",
|
|
511
520
|
variant: "text",
|
|
512
521
|
density: "compact",
|
|
513
522
|
icon: "mdi-minus",
|
|
514
|
-
onClick:
|
|
523
|
+
onClick: r[1] || (r[1] = X((d) => n("delete"), ["stop"]))
|
|
515
524
|
})) : G("", !0)
|
|
516
525
|
]);
|
|
517
526
|
};
|
|
518
527
|
}
|
|
519
528
|
});
|
|
520
|
-
function
|
|
521
|
-
return { renderUiStrInput: (t, e, n,
|
|
529
|
+
function Qt(l) {
|
|
530
|
+
return { renderUiStrInput: (t, e, n, o, i) => e.ui !== "strInput" ? (console.assert(!1), h("div", "renderUiStrInput prop ui must be strInput")) : h(Wt, {
|
|
522
531
|
modelValue: e.static ? e.value : ne(
|
|
523
532
|
t,
|
|
524
533
|
e,
|
|
525
534
|
n,
|
|
526
|
-
o,
|
|
527
535
|
l,
|
|
536
|
+
o,
|
|
528
537
|
i
|
|
529
538
|
),
|
|
530
|
-
"onUpdate:modelValue": (
|
|
539
|
+
"onUpdate:modelValue": (r) => {
|
|
531
540
|
e.static || oe(
|
|
532
541
|
t,
|
|
533
542
|
e,
|
|
534
543
|
n,
|
|
535
|
-
|
|
536
|
-
o,
|
|
544
|
+
r,
|
|
537
545
|
l,
|
|
546
|
+
o,
|
|
538
547
|
i
|
|
539
548
|
);
|
|
540
549
|
},
|
|
541
|
-
hasDelete:
|
|
550
|
+
hasDelete: o !== void 0 && !i,
|
|
542
551
|
onDelete: () => {
|
|
543
|
-
|
|
552
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, -1), n));
|
|
544
553
|
},
|
|
545
554
|
readonly: e.static || e.readonly
|
|
546
555
|
}) };
|
|
547
556
|
}
|
|
548
|
-
const
|
|
557
|
+
const Zt = { class: "d-flex justify-space-between align-center" }, jt = /* @__PURE__ */ R({
|
|
549
558
|
__name: "numInput",
|
|
550
559
|
props: /* @__PURE__ */ Y({
|
|
551
560
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -560,67 +569,79 @@ const Wt = { class: "d-flex justify-space-between align-center" }, Qt = /* @__PU
|
|
|
560
569
|
modelModifiers: {}
|
|
561
570
|
}),
|
|
562
571
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
563
|
-
setup(
|
|
564
|
-
const t = z(
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
572
|
+
setup(l, { emit: s }) {
|
|
573
|
+
const { isMobile: t } = pe(), e = z(l, "modelValue"), n = s, o = async (i) => {
|
|
574
|
+
if (!i || l.readonly || !t())
|
|
575
|
+
return;
|
|
576
|
+
const r = await Re({
|
|
577
|
+
value: e.value,
|
|
578
|
+
precision: l.precision,
|
|
579
|
+
min: l.min,
|
|
580
|
+
max: l.max,
|
|
581
|
+
step: l.step
|
|
582
|
+
});
|
|
583
|
+
r !== void 0 && (e.value = r);
|
|
584
|
+
};
|
|
585
|
+
return (i, r) => {
|
|
586
|
+
const u = $("v-number-input"), a = $("v-btn"), f = le("ripple");
|
|
587
|
+
return C(), E("div", Zt, [
|
|
588
|
+
ee(D(u, {
|
|
589
|
+
modelValue: e.value,
|
|
590
|
+
"onUpdate:modelValue": r[0] || (r[0] = (d) => e.value = d),
|
|
571
591
|
density: "compact",
|
|
572
592
|
"control-variant": "stacked",
|
|
573
|
-
precision:
|
|
574
|
-
min:
|
|
575
|
-
max:
|
|
576
|
-
step:
|
|
593
|
+
precision: i.precision,
|
|
594
|
+
min: i.min,
|
|
595
|
+
max: i.max,
|
|
596
|
+
step: i.step,
|
|
577
597
|
"hide-details": "",
|
|
578
598
|
"single-line": "",
|
|
579
|
-
readonly:
|
|
599
|
+
readonly: i.readonly,
|
|
600
|
+
"onUpdate:focused": o
|
|
580
601
|
}, null, 8, ["modelValue", "precision", "min", "max", "step", "readonly"]), [
|
|
581
602
|
[
|
|
582
|
-
|
|
603
|
+
f,
|
|
583
604
|
void 0,
|
|
584
605
|
void 0,
|
|
585
606
|
{ stop: !0 }
|
|
586
607
|
]
|
|
587
608
|
]),
|
|
588
|
-
|
|
609
|
+
i.hasDelete ? (C(), B(a, {
|
|
589
610
|
key: 0,
|
|
590
611
|
class: "mx-2",
|
|
591
612
|
variant: "text",
|
|
592
613
|
density: "compact",
|
|
593
614
|
icon: "mdi-minus",
|
|
594
|
-
onClick:
|
|
615
|
+
onClick: r[1] || (r[1] = X((d) => n("delete"), ["stop"]))
|
|
595
616
|
})) : G("", !0)
|
|
596
617
|
]);
|
|
597
618
|
};
|
|
598
619
|
}
|
|
599
620
|
});
|
|
600
|
-
function
|
|
601
|
-
return { renderUiNumInput: (t, e, n,
|
|
621
|
+
function It(l) {
|
|
622
|
+
return { renderUiNumInput: (t, e, n, o, i) => e.ui !== "numInput" ? (console.assert(!1), h("div", "renderUiNumInput prop ui must be numInput")) : h(jt, {
|
|
602
623
|
modelValue: ne(
|
|
603
624
|
t,
|
|
604
625
|
e,
|
|
605
626
|
n,
|
|
606
|
-
o,
|
|
607
627
|
l,
|
|
628
|
+
o,
|
|
608
629
|
i
|
|
609
630
|
),
|
|
610
|
-
"onUpdate:modelValue": (
|
|
631
|
+
"onUpdate:modelValue": (r) => {
|
|
611
632
|
oe(
|
|
612
633
|
t,
|
|
613
634
|
e,
|
|
614
635
|
n,
|
|
615
|
-
|
|
616
|
-
o,
|
|
636
|
+
r,
|
|
617
637
|
l,
|
|
638
|
+
o,
|
|
618
639
|
i
|
|
619
640
|
);
|
|
620
641
|
},
|
|
621
|
-
hasDelete:
|
|
642
|
+
hasDelete: o !== void 0 && !i,
|
|
622
643
|
onDelete: () => {
|
|
623
|
-
|
|
644
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, -1), n));
|
|
624
645
|
},
|
|
625
646
|
precision: e.precision,
|
|
626
647
|
min: e.min,
|
|
@@ -629,7 +650,7 @@ function Zt(o) {
|
|
|
629
650
|
readonly: e.readonly
|
|
630
651
|
}) };
|
|
631
652
|
}
|
|
632
|
-
const
|
|
653
|
+
const en = { class: "d-flex justify-space-between align-center" }, tn = /* @__PURE__ */ R({
|
|
633
654
|
__name: "switch",
|
|
634
655
|
props: /* @__PURE__ */ Y({
|
|
635
656
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -639,61 +660,61 @@ const jt = { class: "d-flex justify-space-between align-center" }, It = /* @__PU
|
|
|
639
660
|
modelModifiers: {}
|
|
640
661
|
}),
|
|
641
662
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
642
|
-
setup(
|
|
643
|
-
const t = z(
|
|
644
|
-
return (n,
|
|
645
|
-
const i =
|
|
646
|
-
return
|
|
647
|
-
|
|
663
|
+
setup(l, { emit: s }) {
|
|
664
|
+
const t = z(l, "modelValue"), e = s;
|
|
665
|
+
return (n, o) => {
|
|
666
|
+
const i = $("v-switch"), r = $("v-btn");
|
|
667
|
+
return C(), E("div", en, [
|
|
668
|
+
D(i, {
|
|
648
669
|
modelValue: t.value,
|
|
649
|
-
"onUpdate:modelValue":
|
|
670
|
+
"onUpdate:modelValue": o[0] || (o[0] = (u) => t.value = u),
|
|
650
671
|
class: "ml-1",
|
|
651
672
|
density: "compact",
|
|
652
673
|
color: "primary",
|
|
653
674
|
"hide-details": "",
|
|
654
675
|
readonly: n.readonly
|
|
655
676
|
}, null, 8, ["modelValue", "readonly"]),
|
|
656
|
-
n.hasDelete ? (
|
|
677
|
+
n.hasDelete ? (C(), B(r, {
|
|
657
678
|
key: 0,
|
|
658
679
|
class: "mx-2",
|
|
659
680
|
variant: "text",
|
|
660
681
|
density: "compact",
|
|
661
682
|
icon: "mdi-minus",
|
|
662
|
-
onClick:
|
|
683
|
+
onClick: o[1] || (o[1] = X((u) => e("delete"), ["stop"]))
|
|
663
684
|
})) : G("", !0)
|
|
664
685
|
]);
|
|
665
686
|
};
|
|
666
687
|
}
|
|
667
688
|
});
|
|
668
|
-
function
|
|
669
|
-
return { renderUiSwitch: (t, e, n,
|
|
689
|
+
function nn(l) {
|
|
690
|
+
return { renderUiSwitch: (t, e, n, o, i) => e.ui !== "switch" ? (console.assert(!1), h("div", "renderUiSwitch prop ui must be switch")) : h(tn, {
|
|
670
691
|
modelValue: ne(
|
|
671
692
|
t,
|
|
672
693
|
e,
|
|
673
694
|
n,
|
|
674
|
-
o,
|
|
675
695
|
l,
|
|
696
|
+
o,
|
|
676
697
|
i
|
|
677
698
|
) ?? !1,
|
|
678
|
-
"onUpdate:modelValue": (
|
|
699
|
+
"onUpdate:modelValue": (r) => {
|
|
679
700
|
oe(
|
|
680
701
|
t,
|
|
681
702
|
e,
|
|
682
703
|
n,
|
|
683
|
-
|
|
684
|
-
o,
|
|
704
|
+
r,
|
|
685
705
|
l,
|
|
706
|
+
o,
|
|
686
707
|
i
|
|
687
708
|
);
|
|
688
709
|
},
|
|
689
|
-
hasDelete:
|
|
710
|
+
hasDelete: o !== void 0 && !i,
|
|
690
711
|
onDelete: () => {
|
|
691
|
-
|
|
712
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, 1), n));
|
|
692
713
|
},
|
|
693
714
|
readonly: e.readonly
|
|
694
715
|
}) };
|
|
695
716
|
}
|
|
696
|
-
const
|
|
717
|
+
const ln = { class: "d-flex justify-space-between align-center" }, on = /* @__PURE__ */ R({
|
|
697
718
|
__name: "select",
|
|
698
719
|
props: /* @__PURE__ */ Y({
|
|
699
720
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -704,24 +725,24 @@ const tn = { class: "d-flex justify-space-between align-center" }, nn = /* @__PU
|
|
|
704
725
|
modelModifiers: {}
|
|
705
726
|
}),
|
|
706
727
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
707
|
-
setup(
|
|
708
|
-
const { t } = te(), e = z(
|
|
709
|
-
const
|
|
710
|
-
return
|
|
711
|
-
|
|
712
|
-
}),
|
|
728
|
+
setup(l, { emit: s }) {
|
|
729
|
+
const { t } = te(), e = z(l, "modelValue"), n = s, o = Te(), i = K(() => {
|
|
730
|
+
const r = [];
|
|
731
|
+
return Fe[o.value]?.items[l.items].forEach(({ title: u, value: a }) => {
|
|
732
|
+
r.push({ title: t(u), value: a });
|
|
733
|
+
}), r;
|
|
713
734
|
});
|
|
714
|
-
return (
|
|
715
|
-
const
|
|
716
|
-
return
|
|
717
|
-
ee(
|
|
735
|
+
return (r, u) => {
|
|
736
|
+
const a = $("v-select"), f = $("v-btn"), d = le("ripple");
|
|
737
|
+
return C(), E("div", ln, [
|
|
738
|
+
ee(D(a, {
|
|
718
739
|
modelValue: e.value,
|
|
719
|
-
"onUpdate:modelValue": u[0] || (u[0] = (
|
|
740
|
+
"onUpdate:modelValue": u[0] || (u[0] = (y) => e.value = y),
|
|
720
741
|
density: "compact",
|
|
721
742
|
items: i.value,
|
|
722
743
|
"hide-details": "",
|
|
723
744
|
"single-line": "",
|
|
724
|
-
readonly:
|
|
745
|
+
readonly: r.readonly
|
|
725
746
|
}, null, 8, ["modelValue", "items", "readonly"]), [
|
|
726
747
|
[
|
|
727
748
|
d,
|
|
@@ -730,48 +751,48 @@ const tn = { class: "d-flex justify-space-between align-center" }, nn = /* @__PU
|
|
|
730
751
|
{ stop: !0 }
|
|
731
752
|
]
|
|
732
753
|
]),
|
|
733
|
-
|
|
754
|
+
r.hasDelete ? (C(), B(f, {
|
|
734
755
|
key: 0,
|
|
735
756
|
class: "mx-2",
|
|
736
757
|
variant: "text",
|
|
737
758
|
density: "compact",
|
|
738
759
|
icon: "mdi-minus",
|
|
739
|
-
onClick: u[1] || (u[1] =
|
|
760
|
+
onClick: u[1] || (u[1] = X((y) => n("delete"), ["stop"]))
|
|
740
761
|
})) : G("", !0)
|
|
741
762
|
]);
|
|
742
763
|
};
|
|
743
764
|
}
|
|
744
765
|
});
|
|
745
|
-
function
|
|
746
|
-
return { renderUiSelect: (t, e, n,
|
|
766
|
+
function sn(l) {
|
|
767
|
+
return { renderUiSelect: (t, e, n, o, i) => e.ui !== "select" ? (console.assert(!1), h("div", "renderUiSelect prop ui must be select")) : h(on, {
|
|
747
768
|
modelValue: ne(
|
|
748
769
|
t,
|
|
749
770
|
e,
|
|
750
771
|
n,
|
|
751
|
-
o,
|
|
752
772
|
l,
|
|
773
|
+
o,
|
|
753
774
|
i
|
|
754
775
|
) ?? "",
|
|
755
|
-
"onUpdate:modelValue": (
|
|
776
|
+
"onUpdate:modelValue": (r) => {
|
|
756
777
|
oe(
|
|
757
778
|
t,
|
|
758
779
|
e,
|
|
759
780
|
n,
|
|
760
|
-
|
|
761
|
-
o,
|
|
781
|
+
r,
|
|
762
782
|
l,
|
|
783
|
+
o,
|
|
763
784
|
i
|
|
764
785
|
);
|
|
765
786
|
},
|
|
766
|
-
hasDelete:
|
|
787
|
+
hasDelete: o !== void 0 && !i,
|
|
767
788
|
onDelete: () => {
|
|
768
|
-
|
|
789
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, -1), n));
|
|
769
790
|
},
|
|
770
791
|
items: e.items,
|
|
771
792
|
readonly: e.readonly
|
|
772
793
|
}) };
|
|
773
794
|
}
|
|
774
|
-
const
|
|
795
|
+
const rn = { class: "text-subtitle-2 ml-1" }, un = { class: "text-caption text-grey ml-1" }, an = /* @__PURE__ */ R({
|
|
775
796
|
__name: "group",
|
|
776
797
|
props: {
|
|
777
798
|
id: {},
|
|
@@ -780,66 +801,66 @@ const on = { class: "text-subtitle-2 ml-1" }, sn = { class: "text-caption text-g
|
|
|
780
801
|
count: {}
|
|
781
802
|
},
|
|
782
803
|
emits: ["x-click"],
|
|
783
|
-
setup(
|
|
784
|
-
const { backgroundColor2: t, highlightColor: e } = ie(), n =
|
|
804
|
+
setup(l, { emit: s }) {
|
|
805
|
+
const { backgroundColor2: t, highlightColor: e } = ie(), n = l, o = s, i = O(!1), r = K(() => ({
|
|
785
806
|
background: i.value ? e.value : t.value,
|
|
786
807
|
height: "30px",
|
|
787
808
|
marginBottom: "1px",
|
|
788
809
|
userSelect: "none"
|
|
789
810
|
}));
|
|
790
|
-
return (u,
|
|
791
|
-
const
|
|
792
|
-
return ee((
|
|
811
|
+
return (u, a) => {
|
|
812
|
+
const f = $("v-icon"), d = le("ripple");
|
|
813
|
+
return ee((C(), E("div", {
|
|
793
814
|
class: "d-flex align-center cursor-pointer",
|
|
794
|
-
style: I(
|
|
795
|
-
onClick:
|
|
796
|
-
onMouseover:
|
|
797
|
-
onMouseout:
|
|
815
|
+
style: I(r.value),
|
|
816
|
+
onClick: a[0] || (a[0] = (y) => o("x-click", n.id)),
|
|
817
|
+
onMouseover: a[1] || (a[1] = (y) => i.value = !0),
|
|
818
|
+
onMouseout: a[2] || (a[2] = (y) => i.value = !1)
|
|
798
819
|
}, [
|
|
799
|
-
|
|
820
|
+
D(f, {
|
|
800
821
|
icon: n.collapse ? "mdi-chevron-right" : "mdi-chevron-down",
|
|
801
822
|
size: "small"
|
|
802
823
|
}, null, 8, ["icon"]),
|
|
803
|
-
|
|
804
|
-
|
|
824
|
+
F("span", rn, W(n.title), 1),
|
|
825
|
+
F("span", un, W(n.count), 1)
|
|
805
826
|
], 36)), [
|
|
806
827
|
[d]
|
|
807
828
|
]);
|
|
808
829
|
};
|
|
809
830
|
}
|
|
810
|
-
}),
|
|
831
|
+
}), cn = { class: "text-subtitle-1 ml-6" }, dn = /* @__PURE__ */ R({
|
|
811
832
|
__name: "item",
|
|
812
833
|
props: {
|
|
813
834
|
id: {},
|
|
814
835
|
title: {}
|
|
815
836
|
},
|
|
816
837
|
emits: ["x-click"],
|
|
817
|
-
setup(
|
|
818
|
-
const { backgroundColor2: t, highlightColor: e } = ie(), n =
|
|
838
|
+
setup(l, { emit: s }) {
|
|
839
|
+
const { backgroundColor2: t, highlightColor: e } = ie(), n = l, o = s, i = O(!1), r = K(() => ({
|
|
819
840
|
background: i.value ? e.value : t.value,
|
|
820
841
|
height: "48px",
|
|
821
842
|
marginBottom: "1px",
|
|
822
843
|
userSelect: "none"
|
|
823
844
|
}));
|
|
824
|
-
return (u,
|
|
825
|
-
const
|
|
826
|
-
return ee((
|
|
845
|
+
return (u, a) => {
|
|
846
|
+
const f = le("ripple");
|
|
847
|
+
return ee((C(), E("div", {
|
|
827
848
|
class: "d-flex align-center cursor-pointer",
|
|
828
|
-
style: I(
|
|
829
|
-
onClick:
|
|
830
|
-
onMouseover:
|
|
831
|
-
onMouseout:
|
|
849
|
+
style: I(r.value),
|
|
850
|
+
onClick: a[0] || (a[0] = (d) => o("x-click", n.id)),
|
|
851
|
+
onMouseover: a[1] || (a[1] = (d) => i.value = !0),
|
|
852
|
+
onMouseout: a[2] || (a[2] = (d) => i.value = !1)
|
|
832
853
|
}, [
|
|
833
|
-
|
|
854
|
+
F("span", cn, W(n.title), 1)
|
|
834
855
|
], 36)), [
|
|
835
|
-
[
|
|
856
|
+
[f]
|
|
836
857
|
]);
|
|
837
858
|
};
|
|
838
859
|
}
|
|
839
|
-
}),
|
|
860
|
+
}), fn = { key: 0 }, mn = {
|
|
840
861
|
key: 1,
|
|
841
862
|
class: "text-body-2 text-grey ml-3"
|
|
842
|
-
},
|
|
863
|
+
}, vn = /* @__PURE__ */ R({
|
|
843
864
|
__name: "index",
|
|
844
865
|
props: {
|
|
845
866
|
modelValue: {},
|
|
@@ -848,128 +869,128 @@ const on = { class: "text-subtitle-2 ml-1" }, sn = { class: "text-caption text-g
|
|
|
848
869
|
openModifiers: {}
|
|
849
870
|
},
|
|
850
871
|
emits: ["update:modelValue", "update:open"],
|
|
851
|
-
setup(
|
|
852
|
-
const { t: s } = te(), t = z(
|
|
853
|
-
const u =
|
|
854
|
-
u &&
|
|
855
|
-
}, i = (
|
|
856
|
-
t.value =
|
|
872
|
+
setup(l) {
|
|
873
|
+
const { t: s } = te(), t = z(l, "modelValue"), e = z(l, "open"), n = Ze(), o = (r) => {
|
|
874
|
+
const u = He(n, r);
|
|
875
|
+
u && _t(n, r, !u.collapse);
|
|
876
|
+
}, i = (r) => {
|
|
877
|
+
t.value = r, e.value = !1, ue.emit("refreshDepends");
|
|
857
878
|
};
|
|
858
|
-
return (
|
|
859
|
-
(
|
|
860
|
-
key:
|
|
879
|
+
return (r, u) => L(n).length > 0 ? (C(), E("div", fn, [
|
|
880
|
+
(C(!0), E(Ve, null, Be(L(n), (a) => (C(), E(Ve, {
|
|
881
|
+
key: a.id
|
|
861
882
|
}, [
|
|
862
|
-
|
|
883
|
+
a.type === 0 ? (C(), B(an, {
|
|
863
884
|
key: 0,
|
|
864
|
-
id:
|
|
865
|
-
title:
|
|
866
|
-
collapse:
|
|
867
|
-
count:
|
|
868
|
-
onXClick:
|
|
885
|
+
id: a.id,
|
|
886
|
+
title: a.name,
|
|
887
|
+
collapse: a.collapse,
|
|
888
|
+
count: a.count ?? 0,
|
|
889
|
+
onXClick: o
|
|
869
890
|
}, null, 8, ["id", "title", "collapse", "count"])) : G("", !0),
|
|
870
|
-
|
|
891
|
+
a.type === 1 && a.show ? (C(), B(dn, {
|
|
871
892
|
key: 1,
|
|
872
|
-
id:
|
|
873
|
-
title:
|
|
893
|
+
id: a.id,
|
|
894
|
+
title: a.name,
|
|
874
895
|
onXClick: i
|
|
875
896
|
}, null, 8, ["id", "title"])) : G("", !0)
|
|
876
897
|
], 64))), 128))
|
|
877
|
-
])) : (
|
|
898
|
+
])) : (C(), E("div", mn, W(L(s)("x-prop-tree.noComp")), 1));
|
|
878
899
|
}
|
|
879
|
-
}),
|
|
900
|
+
}), pn = { class: "text-subtitle-1 ml-3" }, yn = /* @__PURE__ */ R({
|
|
880
901
|
__name: "index",
|
|
881
902
|
props: {
|
|
882
903
|
modelValue: {},
|
|
883
904
|
modelModifiers: {}
|
|
884
905
|
},
|
|
885
906
|
emits: ["update:modelValue"],
|
|
886
|
-
setup(
|
|
887
|
-
const { t: s } = te(), t =
|
|
888
|
-
let
|
|
889
|
-
return t.mdAndUp.value && (
|
|
907
|
+
setup(l) {
|
|
908
|
+
const { t: s } = te(), t = Ut(), { sysBarAvail: e } = pe(), { backgroundColor1: n } = ie(), o = z(l, "modelValue"), i = Ze(), r = K(() => {
|
|
909
|
+
let y = "100%";
|
|
910
|
+
return t.mdAndUp.value && (y = "400px"), {
|
|
890
911
|
background: n.value,
|
|
891
|
-
width:
|
|
912
|
+
width: y,
|
|
892
913
|
height: "100%"
|
|
893
914
|
};
|
|
894
915
|
}), u = K(() => {
|
|
895
|
-
let
|
|
896
|
-
return e.value && (
|
|
916
|
+
let y = 48;
|
|
917
|
+
return e.value && (y += 24), {
|
|
897
918
|
position: "relative",
|
|
898
|
-
height: `calc(100% - ${
|
|
919
|
+
height: `calc(100% - ${y}px)`
|
|
899
920
|
};
|
|
900
|
-
}),
|
|
921
|
+
}), a = K(() => ({
|
|
901
922
|
height: "60px"
|
|
902
|
-
})),
|
|
903
|
-
if (!
|
|
923
|
+
})), f = K(() => {
|
|
924
|
+
if (!o.value)
|
|
904
925
|
return s("x-runtime-lib.notSet");
|
|
905
|
-
const
|
|
906
|
-
return
|
|
907
|
-
}), { open: d } =
|
|
908
|
-
return
|
|
926
|
+
const y = He(i, o.value);
|
|
927
|
+
return y ? y.name : s("x-runtime-lib.compNotAvail");
|
|
928
|
+
}), { open: d } = Se(`propTreeCompSelectDlg${we()}`);
|
|
929
|
+
return De(() => {
|
|
909
930
|
d.value = !1;
|
|
910
|
-
}), (
|
|
911
|
-
const
|
|
912
|
-
return
|
|
913
|
-
modelValue:
|
|
914
|
-
"onUpdate:modelValue":
|
|
931
|
+
}), (y, g) => {
|
|
932
|
+
const k = $("v-btn"), S = $("v-sheet"), P = $("v-icon"), T = $("v-dialog");
|
|
933
|
+
return C(), B(T, {
|
|
934
|
+
modelValue: L(d),
|
|
935
|
+
"onUpdate:modelValue": g[5] || (g[5] = (w) => ve(d) ? d.value = w : null),
|
|
915
936
|
transition: "scroll-x-reverse-transition",
|
|
916
937
|
persistent: "",
|
|
917
938
|
"no-click-animation": "",
|
|
918
939
|
fullscreen: "",
|
|
919
|
-
onKeydown:
|
|
940
|
+
onKeydown: g[6] || (g[6] = Ke(X((w) => d.value = !1, ["stop", "prevent"]), ["esc"]))
|
|
920
941
|
}, {
|
|
921
|
-
activator: J(({ props:
|
|
922
|
-
|
|
942
|
+
activator: J(({ props: w }) => [
|
|
943
|
+
D(k, be(w, {
|
|
923
944
|
density: "comfortable",
|
|
924
945
|
block: ""
|
|
925
946
|
}), {
|
|
926
947
|
default: J(() => [
|
|
927
|
-
|
|
948
|
+
Ce(W(f.value), 1)
|
|
928
949
|
]),
|
|
929
950
|
_: 2
|
|
930
951
|
}, 1040)
|
|
931
952
|
]),
|
|
932
953
|
default: J(() => [
|
|
933
|
-
|
|
954
|
+
F("div", {
|
|
934
955
|
class: "w-100 h-100 d-flex flex-row-reverse",
|
|
935
|
-
onClick:
|
|
936
|
-
onContextmenu:
|
|
956
|
+
onClick: g[3] || (g[3] = X((w) => d.value = !1, ["self"])),
|
|
957
|
+
onContextmenu: g[4] || (g[4] = X((w) => d.value = !1, ["self", "prevent"]))
|
|
937
958
|
}, [
|
|
938
|
-
|
|
959
|
+
F("div", {
|
|
939
960
|
class: "elevation-2",
|
|
940
|
-
style: I(
|
|
961
|
+
style: I(r.value)
|
|
941
962
|
}, [
|
|
942
|
-
|
|
963
|
+
L(e) ? (C(), B(S, {
|
|
943
964
|
key: 0,
|
|
944
965
|
color: "transparent",
|
|
945
966
|
height: 24
|
|
946
967
|
})) : G("", !0),
|
|
947
|
-
|
|
968
|
+
D(S, {
|
|
948
969
|
class: "d-flex align-center px-3",
|
|
949
970
|
color: "transparent",
|
|
950
971
|
height: 48
|
|
951
972
|
}, {
|
|
952
973
|
default: J(() => [
|
|
953
|
-
|
|
974
|
+
D(P, {
|
|
954
975
|
icon: "mdi-close",
|
|
955
|
-
onClick:
|
|
976
|
+
onClick: g[0] || (g[0] = (w) => d.value = !1)
|
|
956
977
|
}),
|
|
957
|
-
|
|
978
|
+
F("span", pn, W(L(s)("x-prop-tree.dlg.compSelect.title")), 1)
|
|
958
979
|
]),
|
|
959
980
|
_: 1
|
|
960
981
|
}),
|
|
961
|
-
|
|
982
|
+
F("div", {
|
|
962
983
|
class: "overflow-y-auto",
|
|
963
984
|
style: I(u.value)
|
|
964
985
|
}, [
|
|
965
|
-
|
|
966
|
-
modelValue:
|
|
967
|
-
"onUpdate:modelValue":
|
|
968
|
-
open:
|
|
969
|
-
"onUpdate:open":
|
|
986
|
+
D(vn, {
|
|
987
|
+
modelValue: o.value,
|
|
988
|
+
"onUpdate:modelValue": g[1] || (g[1] = (w) => o.value = w),
|
|
989
|
+
open: L(d),
|
|
990
|
+
"onUpdate:open": g[2] || (g[2] = (w) => ve(d) ? d.value = w : null)
|
|
970
991
|
}, null, 8, ["modelValue", "open"]),
|
|
971
|
-
|
|
972
|
-
style: I(
|
|
992
|
+
F("div", {
|
|
993
|
+
style: I(a.value)
|
|
973
994
|
}, null, 4)
|
|
974
995
|
], 4)
|
|
975
996
|
], 4)
|
|
@@ -980,30 +1001,30 @@ const on = { class: "text-subtitle-2 ml-1" }, sn = { class: "text-caption text-g
|
|
|
980
1001
|
};
|
|
981
1002
|
}
|
|
982
1003
|
});
|
|
983
|
-
function
|
|
984
|
-
return { renderUiCompSelect: (t, e, n,
|
|
1004
|
+
function gn(l) {
|
|
1005
|
+
return { renderUiCompSelect: (t, e, n, o, i) => e.ui !== "compSelect" ? (console.assert(!1), h("div", "renderUiCompSelect prop ui must be compSelect")) : h(yn, {
|
|
985
1006
|
modelValue: ne(
|
|
986
1007
|
t,
|
|
987
1008
|
e,
|
|
988
1009
|
n,
|
|
989
|
-
o,
|
|
990
1010
|
l,
|
|
1011
|
+
o,
|
|
991
1012
|
i
|
|
992
1013
|
),
|
|
993
|
-
"onUpdate:modelValue": (
|
|
1014
|
+
"onUpdate:modelValue": (r) => {
|
|
994
1015
|
oe(
|
|
995
1016
|
t,
|
|
996
1017
|
e,
|
|
997
1018
|
n,
|
|
998
|
-
|
|
999
|
-
o,
|
|
1019
|
+
r,
|
|
1000
1020
|
l,
|
|
1021
|
+
o,
|
|
1001
1022
|
i
|
|
1002
1023
|
);
|
|
1003
1024
|
}
|
|
1004
1025
|
}) };
|
|
1005
1026
|
}
|
|
1006
|
-
const
|
|
1027
|
+
const hn = { class: "d-flex justify-space-between align-center" }, _n = /* @__PURE__ */ R({
|
|
1007
1028
|
__name: "colorPicker",
|
|
1008
1029
|
props: /* @__PURE__ */ Y({
|
|
1009
1030
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -1013,55 +1034,55 @@ const yn = { class: "d-flex justify-space-between align-center" }, gn = /* @__PU
|
|
|
1013
1034
|
modelModifiers: {}
|
|
1014
1035
|
}),
|
|
1015
1036
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
1016
|
-
setup(
|
|
1017
|
-
const { t } = te(), e = z(
|
|
1037
|
+
setup(l, { emit: s }) {
|
|
1038
|
+
const { t } = te(), e = z(l, "modelValue"), n = s, o = K(() => {
|
|
1018
1039
|
let u = "100%";
|
|
1019
|
-
return
|
|
1040
|
+
return l.hasDelete && (u = "calc(100% - 37px)"), {
|
|
1020
1041
|
width: u
|
|
1021
1042
|
};
|
|
1022
|
-
}), i = K(() =>
|
|
1023
|
-
return
|
|
1024
|
-
|
|
1025
|
-
}), (u,
|
|
1026
|
-
const
|
|
1027
|
-
return
|
|
1028
|
-
modelValue:
|
|
1029
|
-
"onUpdate:modelValue":
|
|
1043
|
+
}), i = K(() => l.readonly), { open: r } = Se(`propTreeColorPickerMenu${we()}`);
|
|
1044
|
+
return De(() => {
|
|
1045
|
+
r.value = !1;
|
|
1046
|
+
}), (u, a) => {
|
|
1047
|
+
const f = $("v-btn"), d = $("v-color-picker"), y = $("v-menu");
|
|
1048
|
+
return C(), B(y, {
|
|
1049
|
+
modelValue: L(r),
|
|
1050
|
+
"onUpdate:modelValue": a[2] || (a[2] = (g) => ve(r) ? r.value = g : null),
|
|
1030
1051
|
"close-on-content-click": !1,
|
|
1031
1052
|
scrim: "transparent"
|
|
1032
1053
|
}, {
|
|
1033
|
-
activator: J(({ props:
|
|
1034
|
-
|
|
1035
|
-
|
|
1054
|
+
activator: J(({ props: g }) => [
|
|
1055
|
+
F("div", hn, [
|
|
1056
|
+
F("div", {
|
|
1036
1057
|
class: "flex-grow-1",
|
|
1037
|
-
style: I(
|
|
1058
|
+
style: I(o.value)
|
|
1038
1059
|
}, [
|
|
1039
|
-
|
|
1060
|
+
D(f, be(g, {
|
|
1040
1061
|
density: "comfortable",
|
|
1041
1062
|
color: e.value,
|
|
1042
1063
|
block: "",
|
|
1043
1064
|
disabled: i.value
|
|
1044
1065
|
}), {
|
|
1045
1066
|
default: J(() => [
|
|
1046
|
-
|
|
1067
|
+
Ce(W(e.value ? e.value : L(t)("x-runtime-lib.notSet")), 1)
|
|
1047
1068
|
]),
|
|
1048
1069
|
_: 2
|
|
1049
1070
|
}, 1040, ["color", "disabled"])
|
|
1050
1071
|
], 4),
|
|
1051
|
-
u.hasDelete ? (
|
|
1072
|
+
u.hasDelete ? (C(), B(f, {
|
|
1052
1073
|
key: 0,
|
|
1053
1074
|
class: "mx-2",
|
|
1054
1075
|
variant: "text",
|
|
1055
1076
|
density: "compact",
|
|
1056
1077
|
icon: "mdi-minus",
|
|
1057
|
-
onClick:
|
|
1078
|
+
onClick: a[0] || (a[0] = X((k) => n("delete"), ["stop"]))
|
|
1058
1079
|
})) : G("", !0)
|
|
1059
1080
|
])
|
|
1060
1081
|
]),
|
|
1061
1082
|
default: J(() => [
|
|
1062
|
-
|
|
1083
|
+
D(d, {
|
|
1063
1084
|
modelValue: e.value,
|
|
1064
|
-
"onUpdate:modelValue":
|
|
1085
|
+
"onUpdate:modelValue": a[1] || (a[1] = (g) => e.value = g),
|
|
1065
1086
|
mode: "hexa",
|
|
1066
1087
|
"show-swatches": "",
|
|
1067
1088
|
"swatches-max-height": "150px"
|
|
@@ -1072,35 +1093,35 @@ const yn = { class: "d-flex justify-space-between align-center" }, gn = /* @__PU
|
|
|
1072
1093
|
};
|
|
1073
1094
|
}
|
|
1074
1095
|
});
|
|
1075
|
-
function
|
|
1076
|
-
return { renderUiColorPicker: (t, e, n,
|
|
1096
|
+
function kn(l) {
|
|
1097
|
+
return { renderUiColorPicker: (t, e, n, o, i) => e.ui !== "colorPicker" ? (console.assert(!1), h("div", "renderUiColorPicker prop ui must be colorPicker")) : h(_n, {
|
|
1077
1098
|
modelValue: ne(
|
|
1078
1099
|
t,
|
|
1079
1100
|
e,
|
|
1080
1101
|
n,
|
|
1081
|
-
o,
|
|
1082
1102
|
l,
|
|
1103
|
+
o,
|
|
1083
1104
|
i
|
|
1084
1105
|
),
|
|
1085
|
-
"onUpdate:modelValue": (
|
|
1106
|
+
"onUpdate:modelValue": (r) => {
|
|
1086
1107
|
oe(
|
|
1087
1108
|
t,
|
|
1088
1109
|
e,
|
|
1089
1110
|
n,
|
|
1090
|
-
|
|
1091
|
-
o,
|
|
1111
|
+
r,
|
|
1092
1112
|
l,
|
|
1113
|
+
o,
|
|
1093
1114
|
i
|
|
1094
1115
|
);
|
|
1095
1116
|
},
|
|
1096
|
-
hasDelete:
|
|
1117
|
+
hasDelete: o !== void 0 && !i,
|
|
1097
1118
|
onDelete: () => {
|
|
1098
|
-
|
|
1119
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, -1), n));
|
|
1099
1120
|
},
|
|
1100
1121
|
readonly: e.readonly
|
|
1101
1122
|
}) };
|
|
1102
1123
|
}
|
|
1103
|
-
const
|
|
1124
|
+
const Vn = { class: "d-flex justify-space-between align-center my-2" }, Cn = { class: "flex-grow-1" }, Sn = /* @__PURE__ */ R({
|
|
1104
1125
|
__name: "multiTypes",
|
|
1105
1126
|
props: /* @__PURE__ */ Y({
|
|
1106
1127
|
hasDelete: { type: Boolean, default: !1 },
|
|
@@ -1110,110 +1131,118 @@ const _n = { class: "d-flex justify-space-between align-center my-2" }, kn = { c
|
|
|
1110
1131
|
modelModifiers: {}
|
|
1111
1132
|
}),
|
|
1112
1133
|
emits: /* @__PURE__ */ Y(["delete"], ["update:modelValue"]),
|
|
1113
|
-
setup(
|
|
1114
|
-
const { t } = te(), e = z(
|
|
1115
|
-
const
|
|
1116
|
-
return
|
|
1117
|
-
|
|
1118
|
-
title: t(
|
|
1119
|
-
value:
|
|
1134
|
+
setup(l, { emit: s }) {
|
|
1135
|
+
const { t } = te(), { isMobile: e } = pe(), n = z(l, "modelValue"), o = s, i = Te(), r = K(() => Fe[i.value]?.types[l.types]), u = O(0), a = K(() => {
|
|
1136
|
+
const k = [];
|
|
1137
|
+
return r.value?.forEach(({ title: S }, P) => {
|
|
1138
|
+
k.push({
|
|
1139
|
+
title: t(S),
|
|
1140
|
+
value: P
|
|
1120
1141
|
});
|
|
1121
|
-
}),
|
|
1142
|
+
}), k;
|
|
1122
1143
|
});
|
|
1123
|
-
|
|
1124
|
-
|
|
1144
|
+
Ne(() => {
|
|
1145
|
+
r.value?.some((k, S) => k.validator(n.value) ? (u.value = S, !0) : !1);
|
|
1125
1146
|
});
|
|
1126
|
-
const
|
|
1127
|
-
|
|
1128
|
-
},
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1147
|
+
const f = K(() => r.value?.[u.value]), d = () => {
|
|
1148
|
+
n.value = f.value?.default;
|
|
1149
|
+
}, y = O(0), g = async (k) => {
|
|
1150
|
+
if (!k || !e())
|
|
1151
|
+
return;
|
|
1152
|
+
const S = await Re({
|
|
1153
|
+
value: y.value
|
|
1154
|
+
});
|
|
1155
|
+
S !== void 0 && (y.value = S);
|
|
1156
|
+
};
|
|
1157
|
+
return Ne(() => {
|
|
1158
|
+
f.value?.ui === "pixelInput" ? y.value = Vt(n.value) : f.value?.ui === "percentInput" && (y.value = Ct(n.value));
|
|
1159
|
+
}), re(y, (k) => {
|
|
1160
|
+
f.value?.ui === "pixelInput" ? n.value = k + "px" : f.value?.ui === "percentInput" && (n.value = k + "%");
|
|
1161
|
+
}), (k, S) => {
|
|
1162
|
+
const P = $("v-select"), T = $("v-number-input"), w = $("v-btn"), _ = le("ripple");
|
|
1163
|
+
return C(), E("div", Vn, [
|
|
1164
|
+
F("div", Cn, [
|
|
1165
|
+
ee(D(P, {
|
|
1166
|
+
modelValue: u.value,
|
|
1139
1167
|
"onUpdate:modelValue": [
|
|
1140
|
-
|
|
1141
|
-
|
|
1168
|
+
S[0] || (S[0] = (M) => u.value = M),
|
|
1169
|
+
d
|
|
1142
1170
|
],
|
|
1143
1171
|
density: "compact",
|
|
1144
|
-
items:
|
|
1172
|
+
items: a.value,
|
|
1145
1173
|
"hide-details": "",
|
|
1146
1174
|
"single-line": ""
|
|
1147
1175
|
}, null, 8, ["modelValue", "items"]), [
|
|
1148
1176
|
[
|
|
1149
|
-
|
|
1177
|
+
_,
|
|
1150
1178
|
void 0,
|
|
1151
1179
|
void 0,
|
|
1152
1180
|
{ stop: !0 }
|
|
1153
1181
|
]
|
|
1154
1182
|
]),
|
|
1155
|
-
|
|
1183
|
+
f.value?.ui === "pixelInput" || f.value?.ui === "percentInput" ? ee((C(), B(T, {
|
|
1156
1184
|
key: 0,
|
|
1157
|
-
modelValue:
|
|
1158
|
-
"onUpdate:modelValue":
|
|
1185
|
+
modelValue: y.value,
|
|
1186
|
+
"onUpdate:modelValue": S[1] || (S[1] = (M) => y.value = M),
|
|
1159
1187
|
density: "compact",
|
|
1160
1188
|
"control-variant": "stacked",
|
|
1161
|
-
precision:
|
|
1162
|
-
min:
|
|
1163
|
-
max:
|
|
1164
|
-
step:
|
|
1189
|
+
precision: f.value.precision,
|
|
1190
|
+
min: f.value.min,
|
|
1191
|
+
max: f.value.max,
|
|
1192
|
+
step: f.value.step,
|
|
1165
1193
|
"hide-details": "",
|
|
1166
|
-
"single-line": ""
|
|
1194
|
+
"single-line": "",
|
|
1195
|
+
"onUpdate:focused": g
|
|
1167
1196
|
}, null, 8, ["modelValue", "precision", "min", "max", "step"])), [
|
|
1168
1197
|
[
|
|
1169
|
-
|
|
1198
|
+
_,
|
|
1170
1199
|
void 0,
|
|
1171
1200
|
void 0,
|
|
1172
1201
|
{ stop: !0 }
|
|
1173
1202
|
]
|
|
1174
1203
|
]) : G("", !0)
|
|
1175
1204
|
]),
|
|
1176
|
-
|
|
1205
|
+
k.hasDelete ? (C(), B(w, {
|
|
1177
1206
|
key: 0,
|
|
1178
1207
|
class: "mx-2",
|
|
1179
1208
|
variant: "text",
|
|
1180
1209
|
density: "compact",
|
|
1181
1210
|
icon: "mdi-minus",
|
|
1182
|
-
onClick:
|
|
1211
|
+
onClick: S[2] || (S[2] = X((M) => o("delete"), ["stop"]))
|
|
1183
1212
|
})) : G("", !0)
|
|
1184
1213
|
]);
|
|
1185
1214
|
};
|
|
1186
1215
|
}
|
|
1187
1216
|
});
|
|
1188
|
-
function
|
|
1189
|
-
return { renderUiMultiTypes: (t, e, n,
|
|
1217
|
+
function Un(l) {
|
|
1218
|
+
return { renderUiMultiTypes: (t, e, n, o, i) => e.ui !== "multiTypes" ? (console.assert(!1), h("div", "renderUiMultiTypes prop ui must be multiTypes")) : h(Sn, {
|
|
1190
1219
|
modelValue: ne(
|
|
1191
1220
|
t,
|
|
1192
1221
|
e,
|
|
1193
1222
|
n,
|
|
1194
|
-
o,
|
|
1195
1223
|
l,
|
|
1224
|
+
o,
|
|
1196
1225
|
i
|
|
1197
1226
|
) ?? "",
|
|
1198
|
-
"onUpdate:modelValue": (
|
|
1227
|
+
"onUpdate:modelValue": (r) => {
|
|
1199
1228
|
oe(
|
|
1200
1229
|
t,
|
|
1201
1230
|
e,
|
|
1202
1231
|
n,
|
|
1203
|
-
|
|
1204
|
-
o,
|
|
1232
|
+
r,
|
|
1205
1233
|
l,
|
|
1234
|
+
o,
|
|
1206
1235
|
i
|
|
1207
1236
|
);
|
|
1208
1237
|
},
|
|
1209
|
-
hasDelete:
|
|
1238
|
+
hasDelete: o !== void 0 && !i,
|
|
1210
1239
|
onDelete: () => {
|
|
1211
|
-
|
|
1240
|
+
o === void 0 || i || (n.splice(o, 1), l(t.slice(0, -1), n));
|
|
1212
1241
|
},
|
|
1213
1242
|
types: e.types
|
|
1214
1243
|
}) };
|
|
1215
1244
|
}
|
|
1216
|
-
const
|
|
1245
|
+
const $n = /* @__PURE__ */ R({
|
|
1217
1246
|
__name: "editor",
|
|
1218
1247
|
props: {
|
|
1219
1248
|
modelValue: { required: !0 },
|
|
@@ -1224,114 +1253,114 @@ const Sn = /* @__PURE__ */ R({
|
|
|
1224
1253
|
scaleModifiers: {}
|
|
1225
1254
|
},
|
|
1226
1255
|
emits: ["update:modelValue", "update:lock", "update:scale"],
|
|
1227
|
-
setup(
|
|
1228
|
-
const t = z(
|
|
1256
|
+
setup(l, { expose: s }) {
|
|
1257
|
+
const t = z(l, "modelValue"), e = z(l, "lock"), n = z(l, "scale"), o = gt(), i = ht(), r = Te(), u = Je("target"), a = () => {
|
|
1229
1258
|
const d = JSON.parse(t.value);
|
|
1230
1259
|
u.value?.load(d);
|
|
1231
1260
|
};
|
|
1232
1261
|
return s({ save: () => {
|
|
1233
1262
|
const d = u.value.save();
|
|
1234
1263
|
t.value = JSON.stringify(d, null, 2);
|
|
1235
|
-
} }), (d,
|
|
1264
|
+
} }), (d, y) => (C(), B(L($t), {
|
|
1236
1265
|
ref_key: "target",
|
|
1237
1266
|
ref: u,
|
|
1238
1267
|
lock: e.value,
|
|
1239
|
-
"onUpdate:lock":
|
|
1268
|
+
"onUpdate:lock": y[0] || (y[0] = (g) => e.value = g),
|
|
1240
1269
|
scale: n.value,
|
|
1241
|
-
"onUpdate:scale":
|
|
1270
|
+
"onUpdate:scale": y[1] || (y[1] = (g) => n.value = g),
|
|
1242
1271
|
type: "json",
|
|
1243
|
-
version:
|
|
1244
|
-
locale:
|
|
1245
|
-
dark:
|
|
1246
|
-
onReady:
|
|
1272
|
+
version: L(r),
|
|
1273
|
+
locale: L(i),
|
|
1274
|
+
dark: L(o),
|
|
1275
|
+
onReady: a
|
|
1247
1276
|
}, null, 8, ["lock", "scale", "version", "locale", "dark"]));
|
|
1248
1277
|
}
|
|
1249
|
-
}),
|
|
1278
|
+
}), xn = { class: "text-subtitle-1" }, Pn = /* @__PURE__ */ R({
|
|
1250
1279
|
__name: "index",
|
|
1251
1280
|
props: {
|
|
1252
1281
|
modelValue: { required: !0 },
|
|
1253
1282
|
modelModifiers: {}
|
|
1254
1283
|
},
|
|
1255
1284
|
emits: ["update:modelValue"],
|
|
1256
|
-
setup(
|
|
1257
|
-
const { t: s } = te(), { sysBarAvail: t } =
|
|
1258
|
-
let
|
|
1259
|
-
return t.value && (
|
|
1285
|
+
setup(l) {
|
|
1286
|
+
const { t: s } = te(), { sysBarAvail: t } = pe(), { backgroundColor0: e, backgroundColor1: n, backgroundColor2: o } = ie(), i = z(l, "modelValue"), r = O(!1), u = O(1), a = K(() => {
|
|
1287
|
+
let g = 48;
|
|
1288
|
+
return t.value && (g += 24), {
|
|
1260
1289
|
position: "relative",
|
|
1261
1290
|
background: n.value,
|
|
1262
|
-
height: `calc(100% - ${
|
|
1291
|
+
height: `calc(100% - ${g}px)`
|
|
1263
1292
|
};
|
|
1264
|
-
}),
|
|
1265
|
-
|
|
1293
|
+
}), f = K(() => s("x-prop-tree.dlg.jsonObject.title")), { open: d } = Se(`propTreeJsonObjectDlg${we()}`);
|
|
1294
|
+
De(() => {
|
|
1266
1295
|
d.value = !1;
|
|
1267
1296
|
});
|
|
1268
|
-
const
|
|
1269
|
-
return re(d, (
|
|
1270
|
-
|
|
1271
|
-
}), (
|
|
1272
|
-
const
|
|
1273
|
-
return
|
|
1274
|
-
modelValue:
|
|
1275
|
-
"onUpdate:modelValue":
|
|
1297
|
+
const y = Je("editor");
|
|
1298
|
+
return re(d, (g) => {
|
|
1299
|
+
g || y.value?.save();
|
|
1300
|
+
}), (g, k) => {
|
|
1301
|
+
const S = $("v-btn"), P = $("v-sheet"), T = $("v-spacer"), w = $("v-dialog");
|
|
1302
|
+
return C(), B(w, {
|
|
1303
|
+
modelValue: L(d),
|
|
1304
|
+
"onUpdate:modelValue": k[4] || (k[4] = (_) => ve(d) ? d.value = _ : null),
|
|
1276
1305
|
transition: "dialog-bottom-transition",
|
|
1277
1306
|
persistent: "",
|
|
1278
1307
|
"no-click-animation": "",
|
|
1279
1308
|
fullscreen: "",
|
|
1280
1309
|
attach: "",
|
|
1281
|
-
onKeydown:
|
|
1310
|
+
onKeydown: k[5] || (k[5] = Ke(X((_) => d.value = !1, ["stop", "prevent"]), ["esc"]))
|
|
1282
1311
|
}, {
|
|
1283
|
-
activator: J(({ props:
|
|
1284
|
-
|
|
1312
|
+
activator: J(({ props: _ }) => [
|
|
1313
|
+
D(S, be(_, {
|
|
1285
1314
|
density: "comfortable",
|
|
1286
1315
|
block: ""
|
|
1287
1316
|
}), {
|
|
1288
1317
|
default: J(() => [
|
|
1289
|
-
|
|
1318
|
+
Ce(W(f.value), 1)
|
|
1290
1319
|
]),
|
|
1291
1320
|
_: 2
|
|
1292
1321
|
}, 1040)
|
|
1293
1322
|
]),
|
|
1294
1323
|
default: J(() => [
|
|
1295
|
-
|
|
1296
|
-
color:
|
|
1324
|
+
D(P, {
|
|
1325
|
+
color: L(e),
|
|
1297
1326
|
width: "100%",
|
|
1298
1327
|
height: "100%"
|
|
1299
1328
|
}, {
|
|
1300
1329
|
default: J(() => [
|
|
1301
|
-
|
|
1330
|
+
L(t) ? (C(), B(P, {
|
|
1302
1331
|
key: 0,
|
|
1303
|
-
color:
|
|
1332
|
+
color: L(o),
|
|
1304
1333
|
height: 24
|
|
1305
1334
|
}, null, 8, ["color"])) : G("", !0),
|
|
1306
|
-
|
|
1335
|
+
D(P, {
|
|
1307
1336
|
class: "d-flex align-center px-2",
|
|
1308
|
-
color:
|
|
1337
|
+
color: L(o),
|
|
1309
1338
|
height: 48
|
|
1310
1339
|
}, {
|
|
1311
1340
|
default: J(() => [
|
|
1312
|
-
|
|
1341
|
+
D(S, {
|
|
1313
1342
|
variant: "text",
|
|
1314
1343
|
density: "comfortable",
|
|
1315
1344
|
icon: "mdi-close",
|
|
1316
|
-
onClick:
|
|
1345
|
+
onClick: k[0] || (k[0] = (_) => d.value = !1)
|
|
1317
1346
|
}),
|
|
1318
|
-
|
|
1319
|
-
|
|
1347
|
+
F("span", xn, W(L(s)("x-prop-tree.dlg.jsonObject.title")), 1),
|
|
1348
|
+
D(T)
|
|
1320
1349
|
]),
|
|
1321
1350
|
_: 1
|
|
1322
1351
|
}, 8, ["color"]),
|
|
1323
|
-
|
|
1324
|
-
style: I(
|
|
1352
|
+
F("div", {
|
|
1353
|
+
style: I(a.value)
|
|
1325
1354
|
}, [
|
|
1326
|
-
|
|
1355
|
+
D($n, {
|
|
1327
1356
|
ref_key: "editor",
|
|
1328
|
-
ref:
|
|
1357
|
+
ref: y,
|
|
1329
1358
|
modelValue: i.value,
|
|
1330
|
-
"onUpdate:modelValue":
|
|
1331
|
-
lock:
|
|
1332
|
-
"onUpdate:lock":
|
|
1359
|
+
"onUpdate:modelValue": k[1] || (k[1] = (_) => i.value = _),
|
|
1360
|
+
lock: r.value,
|
|
1361
|
+
"onUpdate:lock": k[2] || (k[2] = (_) => r.value = _),
|
|
1333
1362
|
scale: u.value,
|
|
1334
|
-
"onUpdate:scale":
|
|
1363
|
+
"onUpdate:scale": k[3] || (k[3] = (_) => u.value = _)
|
|
1335
1364
|
}, null, 8, ["modelValue", "lock", "scale"])
|
|
1336
1365
|
], 4)
|
|
1337
1366
|
]),
|
|
@@ -1343,30 +1372,30 @@ const Sn = /* @__PURE__ */ R({
|
|
|
1343
1372
|
};
|
|
1344
1373
|
}
|
|
1345
1374
|
});
|
|
1346
|
-
function
|
|
1347
|
-
return { renderUiJsonEditor: (t, e, n,
|
|
1375
|
+
function Mn(l) {
|
|
1376
|
+
return { renderUiJsonEditor: (t, e, n, o, i) => e.ui !== "jsonEditor" ? h("div", "renderUiJsonObject prop ui must be jsonEditor") : h(Pn, {
|
|
1348
1377
|
modelValue: ne(
|
|
1349
1378
|
t,
|
|
1350
1379
|
e,
|
|
1351
1380
|
n,
|
|
1352
|
-
o,
|
|
1353
1381
|
l,
|
|
1382
|
+
o,
|
|
1354
1383
|
i
|
|
1355
1384
|
) ?? "{}",
|
|
1356
|
-
"onUpdate:modelValue": (
|
|
1385
|
+
"onUpdate:modelValue": (r) => {
|
|
1357
1386
|
oe(
|
|
1358
1387
|
t,
|
|
1359
1388
|
e,
|
|
1360
1389
|
n,
|
|
1361
|
-
|
|
1362
|
-
o,
|
|
1390
|
+
r,
|
|
1363
1391
|
l,
|
|
1392
|
+
o,
|
|
1364
1393
|
i
|
|
1365
1394
|
);
|
|
1366
1395
|
}
|
|
1367
1396
|
}) };
|
|
1368
1397
|
}
|
|
1369
|
-
const
|
|
1398
|
+
const wn = /* @__PURE__ */ R({
|
|
1370
1399
|
__name: "index",
|
|
1371
1400
|
props: {
|
|
1372
1401
|
unique: {},
|
|
@@ -1375,100 +1404,100 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1375
1404
|
version: {}
|
|
1376
1405
|
},
|
|
1377
1406
|
emits: ["change"],
|
|
1378
|
-
setup(
|
|
1379
|
-
const { t } = te(), { backgroundColor1: e } = ie(), n =
|
|
1380
|
-
|
|
1407
|
+
setup(l, { emit: s }) {
|
|
1408
|
+
const { t } = te(), { backgroundColor1: e } = ie(), n = l, o = s, i = O("20px"), r = O("56px"), u = O("200px"), a = mt({}), f = O({}), d = (v, c) => {
|
|
1409
|
+
qe(f, n.config, n.object), o("change", v, c);
|
|
1381
1410
|
};
|
|
1382
1411
|
re(
|
|
1383
1412
|
[() => n.config, () => n.object],
|
|
1384
1413
|
() => {
|
|
1385
|
-
|
|
1386
|
-
|
|
1414
|
+
qe(f, n.config, n.object, (v, c) => {
|
|
1415
|
+
o("change", v, c);
|
|
1387
1416
|
});
|
|
1388
1417
|
},
|
|
1389
1418
|
{ immediate: !0 }
|
|
1390
1419
|
);
|
|
1391
|
-
const
|
|
1392
|
-
|
|
1420
|
+
const y = O(n.version);
|
|
1421
|
+
Tt(y), re(
|
|
1393
1422
|
() => n.version,
|
|
1394
1423
|
() => {
|
|
1395
|
-
|
|
1424
|
+
y.value = n.version;
|
|
1396
1425
|
}
|
|
1397
1426
|
);
|
|
1398
|
-
const
|
|
1399
|
-
|
|
1427
|
+
const g = O(n.config);
|
|
1428
|
+
Lt(g), re(
|
|
1400
1429
|
() => n.config,
|
|
1401
1430
|
() => {
|
|
1402
|
-
|
|
1431
|
+
g.value = n.config;
|
|
1403
1432
|
}
|
|
1404
1433
|
);
|
|
1405
|
-
const
|
|
1406
|
-
|
|
1434
|
+
const k = O(n.object);
|
|
1435
|
+
Ot(k), re(
|
|
1407
1436
|
() => n.object,
|
|
1408
1437
|
() => {
|
|
1409
|
-
|
|
1438
|
+
k.value = n.object;
|
|
1410
1439
|
}
|
|
1411
|
-
),
|
|
1412
|
-
const
|
|
1413
|
-
|
|
1440
|
+
), Bt(f), Jt(d);
|
|
1441
|
+
const S = O([]);
|
|
1442
|
+
Et(S);
|
|
1414
1443
|
const P = () => {
|
|
1415
|
-
const { compGroups:
|
|
1416
|
-
|
|
1417
|
-
const
|
|
1444
|
+
const { compGroups: v, comps: c } = St.app.activeApp, p = [];
|
|
1445
|
+
v.forEach(({ id: m, name: V, position: x }) => {
|
|
1446
|
+
const A = S.value.find((Z) => Z.id === m);
|
|
1418
1447
|
p.push({
|
|
1419
|
-
id:
|
|
1448
|
+
id: m,
|
|
1420
1449
|
type: 0,
|
|
1421
|
-
name:
|
|
1422
|
-
position:
|
|
1423
|
-
collapse:
|
|
1450
|
+
name: V,
|
|
1451
|
+
position: x,
|
|
1452
|
+
collapse: A?.collapse ?? !0
|
|
1424
1453
|
});
|
|
1425
|
-
}), c.forEach(({ id:
|
|
1426
|
-
p.push({ id:
|
|
1427
|
-
}),
|
|
1454
|
+
}), c.forEach(({ id: m, groupid: V, name: x, position: A }) => {
|
|
1455
|
+
p.push({ id: m, type: 1, name: x, position: A, group: V });
|
|
1456
|
+
}), kt(p, !0), S.value = p;
|
|
1428
1457
|
};
|
|
1429
|
-
let
|
|
1430
|
-
const
|
|
1431
|
-
clearTimeout(
|
|
1432
|
-
P(),
|
|
1458
|
+
let T;
|
|
1459
|
+
const w = () => {
|
|
1460
|
+
clearTimeout(T), T = window.setTimeout(() => {
|
|
1461
|
+
P(), T && w();
|
|
1433
1462
|
}, 1e3);
|
|
1434
|
-
},
|
|
1435
|
-
clearTimeout(
|
|
1463
|
+
}, _ = () => {
|
|
1464
|
+
clearTimeout(T), T = void 0;
|
|
1436
1465
|
};
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
}),
|
|
1440
|
-
|
|
1466
|
+
vt(() => {
|
|
1467
|
+
w();
|
|
1468
|
+
}), pt(() => {
|
|
1469
|
+
_();
|
|
1441
1470
|
});
|
|
1442
|
-
const { renderProp:
|
|
1443
|
-
|
|
1471
|
+
const { renderProp: M } = zt(f, r, u), { renderUiDummy: N } = Gt(d), { renderUiStrInput: Q } = Qt(d), { renderUiNumInput: Pe } = It(d), { renderUiSwitch: je } = nn(d), { renderUiSelect: Ie } = sn(d), { renderUiColorPicker: et } = kn(d), { renderUiJsonEditor: tt } = Mn(d), { renderUiMultiTypes: nt } = Un(d), { renderUiCompSelect: lt } = gn(d), ye = (v, c, p, m, V, x) => (v = Ee(v), V !== void 0 ? (v.push(V), x && v.push(c.key)) : v.push(c.key), c.ui ? c.array && m ? it(v, c, p, m, V, x) : rt(v, c, p, V, x) : c.array ? ot(v, c, p, m, V, x) : st(
|
|
1472
|
+
v,
|
|
1444
1473
|
c,
|
|
1445
1474
|
p,
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
)),
|
|
1475
|
+
m,
|
|
1476
|
+
V,
|
|
1477
|
+
x
|
|
1478
|
+
)), ot = (v, c, p, m, V, x) => {
|
|
1450
1479
|
if (c.ui)
|
|
1451
1480
|
return console.assert(!1), h("div", "renderBranchArray prop ui must be invalid");
|
|
1452
1481
|
if (!c.array)
|
|
1453
1482
|
return console.assert(!1), h("div", "renderBranchArray prop array must be valid");
|
|
1454
|
-
if (!
|
|
1483
|
+
if (!m)
|
|
1455
1484
|
return console.assert(!1), h("div", "renderBranchArray branch must be valid");
|
|
1456
|
-
let
|
|
1457
|
-
|
|
1485
|
+
let A;
|
|
1486
|
+
V !== void 0 && !x ? (p[V] instanceof Array || (p[V] = q(c), d(v, p[c.key])), A = p[V]) : (p[c.key] instanceof Array || (p[c.key] = q(c), d(v, p[c.key])), A = p[c.key]);
|
|
1458
1487
|
let Z = t(c.name);
|
|
1459
|
-
|
|
1460
|
-
const fe = h(
|
|
1488
|
+
m.collapse && ae(f.value, v) && (Z += " *");
|
|
1489
|
+
const fe = h(ke, {
|
|
1461
1490
|
title: Z,
|
|
1462
|
-
collapse:
|
|
1491
|
+
collapse: m.collapse,
|
|
1463
1492
|
hasCreate: !0,
|
|
1464
|
-
onCollapse: (
|
|
1465
|
-
|
|
1493
|
+
onCollapse: (U) => {
|
|
1494
|
+
m.collapse = U;
|
|
1466
1495
|
},
|
|
1467
|
-
onMenu: (
|
|
1468
|
-
ue.emit("propTreeMenu", { x:
|
|
1496
|
+
onMenu: (U, b) => {
|
|
1497
|
+
ue.emit("propTreeMenu", { x: U, y: b, keys: v });
|
|
1469
1498
|
},
|
|
1470
1499
|
onCreate: () => {
|
|
1471
|
-
|
|
1500
|
+
A.push({}), d(v, A);
|
|
1472
1501
|
}
|
|
1473
1502
|
}), H = h(
|
|
1474
1503
|
"div",
|
|
@@ -1478,44 +1507,44 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1478
1507
|
}
|
|
1479
1508
|
},
|
|
1480
1509
|
(() => {
|
|
1481
|
-
const
|
|
1482
|
-
for (let
|
|
1483
|
-
if (!
|
|
1510
|
+
const U = [];
|
|
1511
|
+
for (let b = 0; b < A.length; b++) {
|
|
1512
|
+
if (!Me(m.children)) {
|
|
1484
1513
|
console.assert(!1);
|
|
1485
1514
|
break;
|
|
1486
1515
|
}
|
|
1487
|
-
|
|
1516
|
+
m.children[b] || m.children.push({
|
|
1488
1517
|
collapse: !0,
|
|
1489
1518
|
children: {}
|
|
1490
1519
|
});
|
|
1491
|
-
const
|
|
1492
|
-
let
|
|
1493
|
-
|
|
1494
|
-
const
|
|
1495
|
-
title:
|
|
1496
|
-
collapse:
|
|
1520
|
+
const ge = [...v, b], he = m.children[b];
|
|
1521
|
+
let Le = `[${b + 1}]`;
|
|
1522
|
+
m.children[b].collapse && ae(f.value, ge) && (Le += " *");
|
|
1523
|
+
const at = h(ke, {
|
|
1524
|
+
title: Le,
|
|
1525
|
+
collapse: m.children[b].collapse,
|
|
1497
1526
|
hasDelete: !0,
|
|
1498
|
-
index:
|
|
1527
|
+
index: b,
|
|
1499
1528
|
onCollapse: (j) => {
|
|
1500
|
-
if (!
|
|
1529
|
+
if (!Me(m.children)) {
|
|
1501
1530
|
console.assert(!1);
|
|
1502
1531
|
return;
|
|
1503
1532
|
}
|
|
1504
|
-
|
|
1533
|
+
m.children[b].collapse = j;
|
|
1505
1534
|
},
|
|
1506
1535
|
onMenu: (j, se) => {
|
|
1507
|
-
ue.emit("propTreeMenu", { x: j, y: se, keys:
|
|
1536
|
+
ue.emit("propTreeMenu", { x: j, y: se, keys: ge });
|
|
1508
1537
|
},
|
|
1509
1538
|
onDelete: (j) => {
|
|
1510
|
-
if (!
|
|
1539
|
+
if (!Me(m.children)) {
|
|
1511
1540
|
console.assert(!1);
|
|
1512
1541
|
return;
|
|
1513
1542
|
}
|
|
1514
|
-
|
|
1543
|
+
m.children.splice(j, 1), A.splice(j, 1), d(v, A);
|
|
1515
1544
|
}
|
|
1516
1545
|
});
|
|
1517
|
-
|
|
1518
|
-
const
|
|
1546
|
+
U.push(at);
|
|
1547
|
+
const ct = h(
|
|
1519
1548
|
"div",
|
|
1520
1549
|
{
|
|
1521
1550
|
style: {
|
|
@@ -1525,29 +1554,29 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1525
1554
|
(() => {
|
|
1526
1555
|
const j = [];
|
|
1527
1556
|
return c.children.forEach((se) => {
|
|
1528
|
-
if (!
|
|
1557
|
+
if (!Oe(he.children)) {
|
|
1529
1558
|
console.assert(!1);
|
|
1530
1559
|
return;
|
|
1531
1560
|
}
|
|
1532
|
-
|
|
1561
|
+
he.children[se.key] || (he.children[se.key] = {
|
|
1533
1562
|
collapse: !0,
|
|
1534
1563
|
children: se.array ? [] : {}
|
|
1535
1564
|
});
|
|
1536
|
-
const
|
|
1537
|
-
|
|
1565
|
+
const dt = ye(
|
|
1566
|
+
v,
|
|
1538
1567
|
se,
|
|
1539
|
-
b
|
|
1540
|
-
|
|
1541
|
-
|
|
1568
|
+
A[b],
|
|
1569
|
+
he.children[se.key],
|
|
1570
|
+
b,
|
|
1542
1571
|
!0
|
|
1543
1572
|
);
|
|
1544
|
-
j.push(
|
|
1573
|
+
j.push(dt);
|
|
1545
1574
|
}), j;
|
|
1546
1575
|
})()
|
|
1547
1576
|
);
|
|
1548
|
-
|
|
1577
|
+
m.children[b].collapse || U.push(ct);
|
|
1549
1578
|
}
|
|
1550
|
-
return
|
|
1579
|
+
return U;
|
|
1551
1580
|
})()
|
|
1552
1581
|
);
|
|
1553
1582
|
return h(
|
|
@@ -1558,31 +1587,31 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1558
1587
|
}
|
|
1559
1588
|
},
|
|
1560
1589
|
(() => {
|
|
1561
|
-
const
|
|
1562
|
-
return
|
|
1590
|
+
const U = [];
|
|
1591
|
+
return U.push(fe), m.collapse || U.push(H), U;
|
|
1563
1592
|
})()
|
|
1564
1593
|
);
|
|
1565
|
-
},
|
|
1594
|
+
}, st = (v, c, p, m, V, x) => {
|
|
1566
1595
|
if (c.ui)
|
|
1567
1596
|
return console.assert(!1), h("div", "renderBranchScalar prop ui must be invalid");
|
|
1568
1597
|
if (c.array)
|
|
1569
1598
|
return console.assert(!1), h("div", "renderBranchScalar prop array must be invalid");
|
|
1570
|
-
if (!
|
|
1599
|
+
if (!m)
|
|
1571
1600
|
return console.assert(!1), h("div", "renderBranchScalar branch must be valid");
|
|
1572
|
-
let
|
|
1573
|
-
|
|
1574
|
-
const Z = h(
|
|
1575
|
-
title:
|
|
1576
|
-
collapse:
|
|
1577
|
-
hasDelete:
|
|
1601
|
+
let A = t(c.name);
|
|
1602
|
+
m.collapse && ae(f.value, v) && (A += " *");
|
|
1603
|
+
const Z = h(ke, {
|
|
1604
|
+
title: A,
|
|
1605
|
+
collapse: m.collapse,
|
|
1606
|
+
hasDelete: V !== void 0 && !x,
|
|
1578
1607
|
onCollapse: (H) => {
|
|
1579
|
-
|
|
1608
|
+
m.collapse = H;
|
|
1580
1609
|
},
|
|
1581
|
-
onMenu: (H,
|
|
1582
|
-
ue.emit("propTreeMenu", { x: H, y:
|
|
1610
|
+
onMenu: (H, U) => {
|
|
1611
|
+
ue.emit("propTreeMenu", { x: H, y: U, keys: v });
|
|
1583
1612
|
},
|
|
1584
1613
|
onDelete: () => {
|
|
1585
|
-
|
|
1614
|
+
V === void 0 || x || (p.splice(V, 1), d(v.slice(0, -1), p));
|
|
1586
1615
|
}
|
|
1587
1616
|
}), fe = h(
|
|
1588
1617
|
"div",
|
|
@@ -1593,22 +1622,22 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1593
1622
|
},
|
|
1594
1623
|
(() => {
|
|
1595
1624
|
const H = [];
|
|
1596
|
-
return c.children.forEach((
|
|
1597
|
-
if (!
|
|
1625
|
+
return c.children.forEach((U) => {
|
|
1626
|
+
if (!Oe(m.children)) {
|
|
1598
1627
|
console.assert(!1);
|
|
1599
1628
|
return;
|
|
1600
1629
|
}
|
|
1601
|
-
|
|
1630
|
+
m.children[U.key] || (m.children[U.key] = {
|
|
1602
1631
|
collapse: !0,
|
|
1603
|
-
children: !
|
|
1632
|
+
children: !U.ui && U.array ? [] : {}
|
|
1604
1633
|
});
|
|
1605
|
-
const
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
(typeof p[c.key] != "object" && (p[c.key] = {}, d(
|
|
1609
|
-
|
|
1634
|
+
const b = ye(
|
|
1635
|
+
v,
|
|
1636
|
+
U,
|
|
1637
|
+
(typeof p[c.key] != "object" && (p[c.key] = {}, d(v, p[c.key])), p[c.key]),
|
|
1638
|
+
m.children[U.key]
|
|
1610
1639
|
);
|
|
1611
|
-
H.push(
|
|
1640
|
+
H.push(b);
|
|
1612
1641
|
}), H;
|
|
1613
1642
|
})()
|
|
1614
1643
|
);
|
|
@@ -1621,32 +1650,32 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1621
1650
|
},
|
|
1622
1651
|
(() => {
|
|
1623
1652
|
const H = [];
|
|
1624
|
-
return H.push(Z),
|
|
1653
|
+
return H.push(Z), m.collapse || H.push(fe), H;
|
|
1625
1654
|
})()
|
|
1626
1655
|
);
|
|
1627
|
-
},
|
|
1656
|
+
}, it = (v, c, p, m, V, x) => {
|
|
1628
1657
|
if (!c.ui)
|
|
1629
1658
|
return console.assert(!1), h("div", "renderLeafArray prop ui must be valid");
|
|
1630
1659
|
if (!c.array)
|
|
1631
1660
|
return console.assert(!1), h("div", "renderLeafArray prop array must be valid");
|
|
1632
|
-
if (!
|
|
1661
|
+
if (!m)
|
|
1633
1662
|
return console.assert(!1), h("div", "renderLeafArray branch must be valid");
|
|
1634
|
-
let
|
|
1635
|
-
|
|
1663
|
+
let A;
|
|
1664
|
+
V !== void 0 && !x ? (p[V] instanceof Array || (p[V] = q(c), d(v, p[V])), A = p[V]) : (p[c.key] instanceof Array || (p[c.key] = q(c), d(v, p[c.key])), A = p[c.key]);
|
|
1636
1665
|
let Z = t(c.name);
|
|
1637
|
-
|
|
1638
|
-
const fe = h(
|
|
1666
|
+
m.collapse && ae(f.value, v) && (Z += " *");
|
|
1667
|
+
const fe = h(ke, {
|
|
1639
1668
|
title: Z,
|
|
1640
|
-
collapse:
|
|
1669
|
+
collapse: m.collapse,
|
|
1641
1670
|
hasCreate: !0,
|
|
1642
|
-
onCollapse: (
|
|
1643
|
-
|
|
1671
|
+
onCollapse: (U) => {
|
|
1672
|
+
m.collapse = U;
|
|
1644
1673
|
},
|
|
1645
|
-
onMenu: (
|
|
1646
|
-
ue.emit("propTreeMenu", { x:
|
|
1674
|
+
onMenu: (U, b) => {
|
|
1675
|
+
ue.emit("propTreeMenu", { x: U, y: b, keys: v });
|
|
1647
1676
|
},
|
|
1648
1677
|
onCreate: () => {
|
|
1649
|
-
|
|
1678
|
+
A.push(q(c, !0)), d(v, A);
|
|
1650
1679
|
}
|
|
1651
1680
|
}), H = h(
|
|
1652
1681
|
"div",
|
|
@@ -1656,12 +1685,12 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1656
1685
|
}
|
|
1657
1686
|
},
|
|
1658
1687
|
(() => {
|
|
1659
|
-
const
|
|
1660
|
-
for (let
|
|
1661
|
-
const
|
|
1662
|
-
|
|
1688
|
+
const U = [];
|
|
1689
|
+
for (let b = 0; b < A.length; b++) {
|
|
1690
|
+
const ge = ye(v, c, A, void 0, b, !1);
|
|
1691
|
+
U.push(ge);
|
|
1663
1692
|
}
|
|
1664
|
-
return
|
|
1693
|
+
return U;
|
|
1665
1694
|
})()
|
|
1666
1695
|
);
|
|
1667
1696
|
return h(
|
|
@@ -1672,16 +1701,16 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1672
1701
|
}
|
|
1673
1702
|
},
|
|
1674
1703
|
(() => {
|
|
1675
|
-
const
|
|
1676
|
-
return
|
|
1704
|
+
const U = [];
|
|
1705
|
+
return U.push(fe), m.collapse || U.push(H), U;
|
|
1677
1706
|
})()
|
|
1678
1707
|
);
|
|
1679
|
-
},
|
|
1708
|
+
}, rt = (v, c, p, m, V) => {
|
|
1680
1709
|
if (!c.ui)
|
|
1681
1710
|
return console.assert(!1), h("div", "renderLeafScalar prop ui must be valid");
|
|
1682
|
-
let
|
|
1683
|
-
return c.ui === "dummy" ?
|
|
1684
|
-
},
|
|
1711
|
+
let x;
|
|
1712
|
+
return c.ui === "dummy" ? x = N(v, c, p, m, V) : c.ui === "strInput" ? x = Q(v, c, p, m, V) : c.ui === "numInput" ? x = Pe(v, c, p, m, V) : c.ui === "switch" ? x = je(v, c, p, m, V) : c.ui === "select" ? x = Ie(v, c, p, m, V) : c.ui === "colorPicker" ? x = et(v, c, p, m, V) : c.ui === "jsonEditor" ? x = tt(v, c, p, m, V) : c.ui === "multiTypes" ? x = nt(v, c, p, m, V) : c.ui === "compSelect" ? x = lt(v, c, p, m, V) : console.assert(!1, "renderLeafScalar not implemented"), x ? M(v, c, x) : h("div");
|
|
1713
|
+
}, ut = () => h(
|
|
1685
1714
|
"div",
|
|
1686
1715
|
{
|
|
1687
1716
|
class: "text-body-2",
|
|
@@ -1690,44 +1719,44 @@ const Pn = /* @__PURE__ */ R({
|
|
|
1690
1719
|
}
|
|
1691
1720
|
},
|
|
1692
1721
|
(() => {
|
|
1693
|
-
const
|
|
1722
|
+
const v = [];
|
|
1694
1723
|
if (n.unique && n.config.length > 0 && n.object) {
|
|
1695
|
-
|
|
1696
|
-
const c =
|
|
1724
|
+
a[n.unique] || (a[n.unique] = {});
|
|
1725
|
+
const c = a[n.unique];
|
|
1697
1726
|
n.config.forEach((p) => {
|
|
1698
1727
|
c[p.key] || (c[p.key] = {
|
|
1699
1728
|
collapse: !0,
|
|
1700
1729
|
children: !p.ui && p.array ? [] : {}
|
|
1701
1730
|
});
|
|
1702
|
-
const
|
|
1703
|
-
|
|
1731
|
+
const m = ye([], p, n.object, c[p.key]);
|
|
1732
|
+
v.push(m);
|
|
1704
1733
|
});
|
|
1705
1734
|
}
|
|
1706
|
-
return
|
|
1735
|
+
return v;
|
|
1707
1736
|
})()
|
|
1708
1737
|
);
|
|
1709
|
-
return (
|
|
1710
|
-
|
|
1711
|
-
|
|
1738
|
+
return (v, c) => (C(), E(Ve, null, [
|
|
1739
|
+
D(ut),
|
|
1740
|
+
D(Ht, {
|
|
1712
1741
|
config: n.config,
|
|
1713
1742
|
object: n.object,
|
|
1714
|
-
"prop-states":
|
|
1743
|
+
"prop-states": f.value
|
|
1715
1744
|
}, null, 8, ["config", "object", "prop-states"])
|
|
1716
1745
|
], 64));
|
|
1717
1746
|
}
|
|
1718
|
-
}),
|
|
1719
|
-
|
|
1720
|
-
},
|
|
1721
|
-
const e =
|
|
1722
|
-
return e ? typeof e == "function" ? e() : Promise.resolve(e) : new Promise((n,
|
|
1723
|
-
(typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
|
|
1747
|
+
}), Dn = (l) => {
|
|
1748
|
+
l.component("XPropTree", wn);
|
|
1749
|
+
}, bn = (l, s, t) => {
|
|
1750
|
+
const e = l[s];
|
|
1751
|
+
return e ? typeof e == "function" ? e() : Promise.resolve(e) : new Promise((n, o) => {
|
|
1752
|
+
(typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(o.bind(null, /* @__PURE__ */ new Error("Unknown variable dynamic import: " + s + (s.split("/").length !== t ? ". Note that variables only represent file names one level deep." : ""))));
|
|
1724
1753
|
});
|
|
1725
1754
|
};
|
|
1726
|
-
async function
|
|
1727
|
-
return (await
|
|
1755
|
+
async function Jn(l) {
|
|
1756
|
+
return (await bn(/* @__PURE__ */ Object.assign({ "./locales/en/index.ts": () => import("./i18n-en.n11iysmh.js"), "./locales/zhHans/index.ts": () => import("./i18n-zhHans.hr18mfah.js") }), `./locales/${l}/index.ts`, 4)).default;
|
|
1728
1757
|
}
|
|
1729
|
-
const
|
|
1758
|
+
const Rn = { install: Dn };
|
|
1730
1759
|
export {
|
|
1731
|
-
|
|
1732
|
-
|
|
1760
|
+
Rn as default,
|
|
1761
|
+
Jn as loadLocaleMessagePropTree
|
|
1733
1762
|
};
|