x-prop-tree 0.4.4 → 0.4.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.
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
@@ -13,9 +13,5 @@ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, imp
|
|
|
13
13
|
onDelete?: ((...args: any[]) => any) | undefined;
|
|
14
14
|
onCollapse?: ((...args: any[]) => any) | undefined;
|
|
15
15
|
onCreate?: ((...args: any[]) => any) | undefined;
|
|
16
|
-
}>, {
|
|
17
|
-
index: number;
|
|
18
|
-
hasDelete: boolean;
|
|
19
|
-
hasCreate: boolean;
|
|
20
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
16
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
21
17
|
export default _default;
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.id="x-prop-tree",e.appendChild(document.createTextNode('.v-icon{--v-icon-size-multiplier: 1;align-items:center;display:inline-flex;font-feature-settings:"liga";height:1em;justify-content:center;letter-spacing:normal;line-height:1;position:relative;text-indent:0;text-align:center;-webkit-user-select:none;user-select:none;vertical-align:middle;width:1em;min-width:1em}.v-icon--clickable{cursor:pointer}.v-icon--disabled{pointer-events:none;opacity:.38}.v-icon--size-x-small{font-size:calc(var(--v-icon-size-multiplier) * 1em)}.v-icon--size-small{font-size:calc(var(--v-icon-size-multiplier) * 1.25em)}.v-icon--size-default{font-size:calc(var(--v-icon-size-multiplier) * 1.5em)}.v-icon--size-large{font-size:calc(var(--v-icon-size-multiplier) * 1.75em)}.v-icon--size-x-large{font-size:calc(var(--v-icon-size-multiplier) * 2em)}.v-icon__svg{fill:currentColor;width:100%;height:100%}.v-icon--start{margin-inline-end:8px}.v-icon--end{margin-inline-start:8px}')),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
|
|
2
|
-
import { Fragment as Ae, reactive as Ve, computed as
|
|
2
|
+
import { Fragment as Ae, reactive as Ve, computed as b, watchEffect as be, toRefs as Me, warn as Pe, getCurrentInstance as Le, inject as j, shallowRef as Te, provide as _e, defineComponent as M, isRef as ze, createVNode as C, mergeProps as xe, unref as q, ref as T, toRef as Oe, Text as Re, resolveComponent as p, openBlock as S, createBlock as B, withCtx as ne, mergeModels as Z, useModel as ee, resolveDirective as Ne, withDirectives as He, createElementBlock as Ee, normalizeStyle as We, createElementVNode as Ue, toDisplayString as Ge, withModifiers as te, createCommentVNode as se, h as k } from "vue";
|
|
3
3
|
import { useI18n as qe } from "vue-i18n";
|
|
4
4
|
import { useColor as Ze } from "x-essential-lib";
|
|
5
|
-
import { getPropDefault as
|
|
5
|
+
import { getPropDefault as L } from "x-runtime-lib";
|
|
6
6
|
var Xe = "M7.41,8.58L12,13.17L16.59,8.58L18,10L12,16L6,10L7.41,8.58Z", Ye = "M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z", Ke = "M19,13H5V11H19V13Z", Je = "M19,13H13V19H11V13H5V11H11V5H13V11H19V13Z";
|
|
7
|
-
function
|
|
7
|
+
function I(e, n) {
|
|
8
8
|
return (t) => Object.keys(e).reduce((s, a) => {
|
|
9
9
|
const u = typeof e[a] == "object" && e[a] != null && !Array.isArray(e[a]) ? e[a] : {
|
|
10
10
|
type: e[a]
|
|
@@ -15,14 +15,14 @@ function p(e, n) {
|
|
|
15
15
|
} : s[a] = u, n && !s[a].source && (s[a].source = n), s;
|
|
16
16
|
}, {});
|
|
17
17
|
}
|
|
18
|
-
const Qe =
|
|
18
|
+
const Qe = I({
|
|
19
19
|
class: [String, Array, Object],
|
|
20
20
|
style: {
|
|
21
21
|
type: [String, Array, Object],
|
|
22
22
|
default: null
|
|
23
23
|
}
|
|
24
24
|
}, "component");
|
|
25
|
-
function
|
|
25
|
+
function O(e) {
|
|
26
26
|
let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "px";
|
|
27
27
|
if (!(e == null || e === ""))
|
|
28
28
|
return isNaN(+e) ? String(e) : isFinite(+e) ? `${Number(e)}${n}` : void 0;
|
|
@@ -31,7 +31,7 @@ function ae(e) {
|
|
|
31
31
|
let n;
|
|
32
32
|
return e !== null && typeof e == "object" && ((n = Object.getPrototypeOf(e)) === Object.prototype || n === null);
|
|
33
33
|
}
|
|
34
|
-
function
|
|
34
|
+
function K(e, n) {
|
|
35
35
|
return n.every((t) => e.hasOwnProperty(t));
|
|
36
36
|
}
|
|
37
37
|
function je(e, n) {
|
|
@@ -52,70 +52,70 @@ function en(e) {
|
|
|
52
52
|
t.push(e.substr(s, n)), s += n;
|
|
53
53
|
return t;
|
|
54
54
|
}
|
|
55
|
-
function
|
|
55
|
+
function pe() {
|
|
56
56
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = arguments.length > 2 ? arguments[2] : void 0;
|
|
57
57
|
const s = {};
|
|
58
58
|
for (const a in e)
|
|
59
59
|
s[a] = e[a];
|
|
60
60
|
for (const a in n) {
|
|
61
|
-
const
|
|
62
|
-
if (ae(
|
|
63
|
-
s[a] =
|
|
61
|
+
const r = e[a], u = n[a];
|
|
62
|
+
if (ae(r) && ae(u)) {
|
|
63
|
+
s[a] = pe(r, u, t);
|
|
64
64
|
continue;
|
|
65
65
|
}
|
|
66
|
-
if (t && Array.isArray(
|
|
67
|
-
s[a] = t(
|
|
66
|
+
if (t && Array.isArray(r) && Array.isArray(u)) {
|
|
67
|
+
s[a] = t(r, u);
|
|
68
68
|
continue;
|
|
69
69
|
}
|
|
70
70
|
s[a] = u;
|
|
71
71
|
}
|
|
72
72
|
return s;
|
|
73
73
|
}
|
|
74
|
-
function
|
|
75
|
-
return e.map((n) => n.type === Ae ?
|
|
74
|
+
function Se(e) {
|
|
75
|
+
return e.map((n) => n.type === Ae ? Se(n.children) : n).flat();
|
|
76
76
|
}
|
|
77
|
-
function
|
|
77
|
+
function A() {
|
|
78
78
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "";
|
|
79
|
-
if (
|
|
79
|
+
if (A.cache.has(e)) return A.cache.get(e);
|
|
80
80
|
const n = e.replace(/[^a-z]/gi, "-").replace(/\B([A-Z])/g, "-$1").toLowerCase();
|
|
81
|
-
return
|
|
81
|
+
return A.cache.set(e, n), n;
|
|
82
82
|
}
|
|
83
|
-
|
|
84
|
-
function
|
|
85
|
-
const n = Ve({}), t =
|
|
86
|
-
return
|
|
83
|
+
A.cache = /* @__PURE__ */ new Map();
|
|
84
|
+
function we(e) {
|
|
85
|
+
const n = Ve({}), t = b(e);
|
|
86
|
+
return be(() => {
|
|
87
87
|
for (const s in t.value)
|
|
88
88
|
n[s] = t.value[s];
|
|
89
89
|
}, {
|
|
90
90
|
flush: "sync"
|
|
91
|
-
}),
|
|
91
|
+
}), Me(n);
|
|
92
92
|
}
|
|
93
93
|
function nn(e, n) {
|
|
94
94
|
return e.includes(n);
|
|
95
95
|
}
|
|
96
|
-
const
|
|
96
|
+
const D = 2.4, re = 0.2126729, ie = 0.7151522, ue = 0.072175, tn = 0.55, sn = 0.58, an = 0.57, ln = 0.62, U = 0.03, oe = 1.45, rn = 5e-4, un = 1.25, on = 1.25, ce = 0.078, fe = 12.82051282051282, G = 0.06, de = 1e-3;
|
|
97
97
|
function me(e, n) {
|
|
98
|
-
const t = (e.r / 255) **
|
|
99
|
-
let o = t *
|
|
100
|
-
if (o <= U && (o += (U - o) ** oe),
|
|
101
|
-
let
|
|
102
|
-
if (
|
|
103
|
-
const g = (
|
|
104
|
-
|
|
98
|
+
const t = (e.r / 255) ** D, s = (e.g / 255) ** D, a = (e.b / 255) ** D, r = (n.r / 255) ** D, u = (n.g / 255) ** D, y = (n.b / 255) ** D;
|
|
99
|
+
let o = t * re + s * ie + a * ue, f = r * re + u * ie + y * ue;
|
|
100
|
+
if (o <= U && (o += (U - o) ** oe), f <= U && (f += (U - f) ** oe), Math.abs(f - o) < rn) return 0;
|
|
101
|
+
let v;
|
|
102
|
+
if (f > o) {
|
|
103
|
+
const g = (f ** tn - o ** sn) * un;
|
|
104
|
+
v = g < de ? 0 : g < ce ? g - g * fe * G : g - G;
|
|
105
105
|
} else {
|
|
106
|
-
const g = (
|
|
107
|
-
|
|
106
|
+
const g = (f ** ln - o ** an) * on;
|
|
107
|
+
v = g > -de ? 0 : g > -ce ? g - g * fe * G : g + G;
|
|
108
108
|
}
|
|
109
|
-
return
|
|
109
|
+
return v * 100;
|
|
110
110
|
}
|
|
111
|
-
function
|
|
112
|
-
|
|
111
|
+
function R(e) {
|
|
112
|
+
Pe(`Vuetify: ${e}`);
|
|
113
113
|
}
|
|
114
|
-
function
|
|
114
|
+
function J(e) {
|
|
115
115
|
return !!e && /^(#|var\(--|(rgb|hsl)a?\()/.test(e);
|
|
116
116
|
}
|
|
117
117
|
function cn(e) {
|
|
118
|
-
return
|
|
118
|
+
return J(e) && !/^((rgb|hsl)a?\()?var\(--/.test(e);
|
|
119
119
|
}
|
|
120
120
|
const ge = /^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/, fn = {
|
|
121
121
|
rgb: (e, n, t, s) => ({
|
|
@@ -142,22 +142,22 @@ const ge = /^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/, fn = {
|
|
|
142
142
|
l: t,
|
|
143
143
|
a: s
|
|
144
144
|
}),
|
|
145
|
-
hsv: (e, n, t, s) =>
|
|
145
|
+
hsv: (e, n, t, s) => N({
|
|
146
146
|
h: e,
|
|
147
147
|
s: n,
|
|
148
148
|
v: t,
|
|
149
149
|
a: s
|
|
150
150
|
}),
|
|
151
|
-
hsva: (e, n, t, s) =>
|
|
151
|
+
hsva: (e, n, t, s) => N({
|
|
152
152
|
h: e,
|
|
153
153
|
s: n,
|
|
154
154
|
v: t,
|
|
155
155
|
a: s
|
|
156
156
|
})
|
|
157
157
|
};
|
|
158
|
-
function
|
|
158
|
+
function z(e) {
|
|
159
159
|
if (typeof e == "number")
|
|
160
|
-
return (isNaN(e) || e < 0 || e > 16777215) &&
|
|
160
|
+
return (isNaN(e) || e < 0 || e > 16777215) && R(`'${e}' is not a valid hex color`), {
|
|
161
161
|
r: (e & 16711680) >> 16,
|
|
162
162
|
g: (e & 65280) >> 8,
|
|
163
163
|
b: e & 255
|
|
@@ -168,34 +168,34 @@ function M(e) {
|
|
|
168
168
|
} = e.match(ge), {
|
|
169
169
|
fn: t,
|
|
170
170
|
values: s
|
|
171
|
-
} = n, a = s.split(/,\s*/).map((
|
|
171
|
+
} = n, a = s.split(/,\s*/).map((r) => r.endsWith("%") && ["hsl", "hsla", "hsv", "hsva"].includes(t) ? parseFloat(r) / 100 : parseFloat(r));
|
|
172
172
|
return fn[t](...a);
|
|
173
173
|
} else if (typeof e == "string") {
|
|
174
174
|
let n = e.startsWith("#") ? e.slice(1) : e;
|
|
175
|
-
[3, 4].includes(n.length) ? n = n.split("").map((s) => s + s).join("") : [6, 8].includes(n.length) ||
|
|
175
|
+
[3, 4].includes(n.length) ? n = n.split("").map((s) => s + s).join("") : [6, 8].includes(n.length) || R(`'${e}' is not a valid hex(a) color`);
|
|
176
176
|
const t = parseInt(n, 16);
|
|
177
|
-
return (isNaN(t) || t < 0 || t > 4294967295) &&
|
|
177
|
+
return (isNaN(t) || t < 0 || t > 4294967295) && R(`'${e}' is not a valid hex(a) color`), dn(n);
|
|
178
178
|
} else if (typeof e == "object") {
|
|
179
|
-
if (
|
|
179
|
+
if (K(e, ["r", "g", "b"]))
|
|
180
180
|
return e;
|
|
181
|
-
if (
|
|
182
|
-
return
|
|
183
|
-
if (
|
|
184
|
-
return
|
|
181
|
+
if (K(e, ["h", "s", "l"]))
|
|
182
|
+
return N(Fe(e));
|
|
183
|
+
if (K(e, ["h", "s", "v"]))
|
|
184
|
+
return N(e);
|
|
185
185
|
}
|
|
186
186
|
throw new TypeError(`Invalid color: ${e == null ? e : String(e) || e.constructor.name}
|
|
187
187
|
Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`);
|
|
188
188
|
}
|
|
189
|
-
function
|
|
189
|
+
function N(e) {
|
|
190
190
|
const {
|
|
191
191
|
h: n,
|
|
192
192
|
s: t,
|
|
193
193
|
v: s,
|
|
194
194
|
a
|
|
195
|
-
} = e,
|
|
196
|
-
const o = (
|
|
195
|
+
} = e, r = (y) => {
|
|
196
|
+
const o = (y + n / 60) % 6;
|
|
197
197
|
return s - s * t * Math.max(Math.min(o, 4 - o, 1), 0);
|
|
198
|
-
}, u = [
|
|
198
|
+
}, u = [r(5), r(3), r(1)].map((y) => Math.round(y * 255));
|
|
199
199
|
return {
|
|
200
200
|
r: u[0],
|
|
201
201
|
g: u[1],
|
|
@@ -204,25 +204,25 @@ function R(e) {
|
|
|
204
204
|
};
|
|
205
205
|
}
|
|
206
206
|
function ye(e) {
|
|
207
|
-
return
|
|
207
|
+
return N(Fe(e));
|
|
208
208
|
}
|
|
209
|
-
function
|
|
209
|
+
function Fe(e) {
|
|
210
210
|
const {
|
|
211
211
|
h: n,
|
|
212
212
|
s: t,
|
|
213
213
|
l: s,
|
|
214
214
|
a
|
|
215
|
-
} = e,
|
|
215
|
+
} = e, r = s + t * Math.min(s, 1 - s), u = r === 0 ? 0 : 2 - 2 * s / r;
|
|
216
216
|
return {
|
|
217
217
|
h: n,
|
|
218
218
|
s: u,
|
|
219
|
-
v:
|
|
219
|
+
v: r,
|
|
220
220
|
a
|
|
221
221
|
};
|
|
222
222
|
}
|
|
223
223
|
function dn(e) {
|
|
224
224
|
e = mn(e);
|
|
225
|
-
let [n, t, s, a] = en(e, 2).map((
|
|
225
|
+
let [n, t, s, a] = en(e, 2).map((r) => parseInt(r, 16));
|
|
226
226
|
return a = a === void 0 ? a : a / 255, {
|
|
227
227
|
r: n,
|
|
228
228
|
g: t,
|
|
@@ -234,128 +234,128 @@ function mn(e) {
|
|
|
234
234
|
return e.startsWith("#") && (e = e.slice(1)), e = e.replace(/([^0-9a-f])/gi, "F"), (e.length === 3 || e.length === 4) && (e = e.split("").map((n) => n + n).join("")), e.length !== 6 && (e = le(le(e, 6), 8, "F")), e;
|
|
235
235
|
}
|
|
236
236
|
function gn(e) {
|
|
237
|
-
const n = Math.abs(me(
|
|
238
|
-
return Math.abs(me(
|
|
237
|
+
const n = Math.abs(me(z(0), z(e)));
|
|
238
|
+
return Math.abs(me(z(16777215), z(e))) > Math.min(n, 50) ? "#fff" : "#000";
|
|
239
239
|
}
|
|
240
|
-
function
|
|
241
|
-
const t =
|
|
240
|
+
function H(e, n) {
|
|
241
|
+
const t = Le();
|
|
242
242
|
if (!t)
|
|
243
243
|
throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);
|
|
244
244
|
return t;
|
|
245
245
|
}
|
|
246
246
|
function yn() {
|
|
247
247
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "composables";
|
|
248
|
-
const n =
|
|
249
|
-
return
|
|
248
|
+
const n = H(e).type;
|
|
249
|
+
return A((n == null ? void 0 : n.aliasName) || (n == null ? void 0 : n.name));
|
|
250
250
|
}
|
|
251
251
|
function hn(e) {
|
|
252
|
-
let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] :
|
|
252
|
+
let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : H("injectSelf");
|
|
253
253
|
const {
|
|
254
254
|
provides: t
|
|
255
255
|
} = n;
|
|
256
256
|
if (t && e in t)
|
|
257
257
|
return t[e];
|
|
258
258
|
}
|
|
259
|
-
const
|
|
260
|
-
function
|
|
261
|
-
const e =
|
|
259
|
+
const Q = Symbol.for("vuetify:defaults");
|
|
260
|
+
function Be() {
|
|
261
|
+
const e = j(Q);
|
|
262
262
|
if (!e) throw new Error("[Vuetify] Could not find defaults instance");
|
|
263
263
|
return e;
|
|
264
264
|
}
|
|
265
265
|
function vn(e, n) {
|
|
266
266
|
var t, s;
|
|
267
|
-
return typeof ((t = e.props) == null ? void 0 : t[n]) < "u" || typeof ((s = e.props) == null ? void 0 : s[
|
|
267
|
+
return typeof ((t = e.props) == null ? void 0 : t[n]) < "u" || typeof ((s = e.props) == null ? void 0 : s[A(n)]) < "u";
|
|
268
268
|
}
|
|
269
269
|
function kn() {
|
|
270
|
-
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = arguments.length > 1 ? arguments[1] : void 0, t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] :
|
|
271
|
-
const s =
|
|
270
|
+
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}, n = arguments.length > 1 ? arguments[1] : void 0, t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Be();
|
|
271
|
+
const s = H("useDefaults");
|
|
272
272
|
if (n = n ?? s.type.name ?? s.type.__name, !n)
|
|
273
273
|
throw new Error("[Vuetify] Could not determine component name");
|
|
274
|
-
const a =
|
|
274
|
+
const a = b(() => {
|
|
275
275
|
var o;
|
|
276
276
|
return (o = t.value) == null ? void 0 : o[e._as ?? n];
|
|
277
|
-
}),
|
|
278
|
-
get(o,
|
|
279
|
-
var g,
|
|
280
|
-
const
|
|
281
|
-
return
|
|
277
|
+
}), r = new Proxy(e, {
|
|
278
|
+
get(o, f) {
|
|
279
|
+
var g, w, F, _, E, P, W;
|
|
280
|
+
const v = Reflect.get(o, f);
|
|
281
|
+
return f === "class" || f === "style" ? [(g = a.value) == null ? void 0 : g[f], v].filter((c) => c != null) : typeof f == "string" && !vn(s.vnode, f) ? ((w = a.value) == null ? void 0 : w[f]) !== void 0 ? (F = a.value) == null ? void 0 : F[f] : ((E = (_ = t.value) == null ? void 0 : _.global) == null ? void 0 : E[f]) !== void 0 ? (W = (P = t.value) == null ? void 0 : P.global) == null ? void 0 : W[f] : v : v;
|
|
282
282
|
}
|
|
283
283
|
}), u = Te();
|
|
284
|
-
|
|
284
|
+
be(() => {
|
|
285
285
|
if (a.value) {
|
|
286
|
-
const o = Object.entries(a.value).filter((
|
|
287
|
-
let [
|
|
288
|
-
return
|
|
286
|
+
const o = Object.entries(a.value).filter((f) => {
|
|
287
|
+
let [v] = f;
|
|
288
|
+
return v.startsWith(v[0].toUpperCase());
|
|
289
289
|
});
|
|
290
290
|
u.value = o.length ? Object.fromEntries(o) : void 0;
|
|
291
291
|
} else
|
|
292
292
|
u.value = void 0;
|
|
293
293
|
});
|
|
294
|
-
function
|
|
295
|
-
const o = hn(
|
|
296
|
-
|
|
294
|
+
function y() {
|
|
295
|
+
const o = hn(Q, s);
|
|
296
|
+
_e(Q, b(() => u.value ? pe((o == null ? void 0 : o.value) ?? {}, u.value) : o == null ? void 0 : o.value));
|
|
297
297
|
}
|
|
298
298
|
return {
|
|
299
|
-
props:
|
|
300
|
-
provideSubDefaults:
|
|
299
|
+
props: r,
|
|
300
|
+
provideSubDefaults: y
|
|
301
301
|
};
|
|
302
302
|
}
|
|
303
303
|
function X(e) {
|
|
304
304
|
if (e._setup = e._setup ?? e.setup, !e.name)
|
|
305
|
-
return
|
|
305
|
+
return R("The component is missing an explicit name, unable to generate default prop value"), e;
|
|
306
306
|
if (e._setup) {
|
|
307
|
-
e.props =
|
|
307
|
+
e.props = I(e.props ?? {}, e.name)();
|
|
308
308
|
const n = Object.keys(e.props).filter((t) => t !== "class" && t !== "style");
|
|
309
309
|
e.filterProps = function(s) {
|
|
310
310
|
return je(s, n);
|
|
311
311
|
}, e.props._as = String, e.setup = function(s, a) {
|
|
312
|
-
const
|
|
313
|
-
if (!
|
|
312
|
+
const r = Be();
|
|
313
|
+
if (!r.value) return e._setup(s, a);
|
|
314
314
|
const {
|
|
315
315
|
props: u,
|
|
316
|
-
provideSubDefaults:
|
|
317
|
-
} = kn(s, s._as ?? e.name,
|
|
318
|
-
return
|
|
316
|
+
provideSubDefaults: y
|
|
317
|
+
} = kn(s, s._as ?? e.name, r), o = e._setup(u, a);
|
|
318
|
+
return y(), o;
|
|
319
319
|
};
|
|
320
320
|
}
|
|
321
321
|
return e;
|
|
322
322
|
}
|
|
323
|
-
function
|
|
323
|
+
function Ie() {
|
|
324
324
|
let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !0;
|
|
325
|
-
return (n) => (e ? X :
|
|
325
|
+
return (n) => (e ? X : M)(n);
|
|
326
326
|
}
|
|
327
327
|
function Cn(e) {
|
|
328
|
-
const n =
|
|
328
|
+
const n = H("useRender");
|
|
329
329
|
n.render = e;
|
|
330
330
|
}
|
|
331
|
-
const he = Symbol.for("vuetify:theme"), Vn =
|
|
331
|
+
const he = Symbol.for("vuetify:theme"), Vn = I({
|
|
332
332
|
theme: String
|
|
333
333
|
}, "theme");
|
|
334
|
-
function
|
|
335
|
-
|
|
336
|
-
const n =
|
|
334
|
+
function bn(e) {
|
|
335
|
+
H("provideTheme");
|
|
336
|
+
const n = j(he, null);
|
|
337
337
|
if (!n) throw new Error("Could not find Vuetify theme injection");
|
|
338
|
-
const t =
|
|
338
|
+
const t = b(() => e.theme ?? n.name.value), s = b(() => n.themes.value[t.value]), a = b(() => n.isDisabled ? void 0 : `v-theme--${t.value}`), r = {
|
|
339
339
|
...n,
|
|
340
340
|
name: t,
|
|
341
341
|
current: s,
|
|
342
342
|
themeClasses: a
|
|
343
343
|
};
|
|
344
|
-
return
|
|
344
|
+
return _e(he, r), r;
|
|
345
345
|
}
|
|
346
|
-
const
|
|
346
|
+
const _n = I({
|
|
347
347
|
tag: {
|
|
348
348
|
type: String,
|
|
349
349
|
default: "div"
|
|
350
350
|
}
|
|
351
351
|
}, "tag");
|
|
352
|
-
function
|
|
353
|
-
return
|
|
352
|
+
function xn(e) {
|
|
353
|
+
return we(() => {
|
|
354
354
|
const n = [], t = {};
|
|
355
355
|
if (e.value.background)
|
|
356
|
-
if (
|
|
356
|
+
if (J(e.value.background)) {
|
|
357
357
|
if (t.backgroundColor = e.value.background, !e.value.text && cn(e.value.background)) {
|
|
358
|
-
const s =
|
|
358
|
+
const s = z(e.value.background);
|
|
359
359
|
if (s.a == null || s.a === 1) {
|
|
360
360
|
const a = gn(s);
|
|
361
361
|
t.color = a, t.caretColor = a;
|
|
@@ -363,34 +363,34 @@ function Sn(e) {
|
|
|
363
363
|
}
|
|
364
364
|
} else
|
|
365
365
|
n.push(`bg-${e.value.background}`);
|
|
366
|
-
return e.value.text && (
|
|
366
|
+
return e.value.text && (J(e.value.text) ? (t.color = e.value.text, t.caretColor = e.value.text) : n.push(`text-${e.value.text}`)), {
|
|
367
367
|
colorClasses: n,
|
|
368
368
|
colorStyles: t
|
|
369
369
|
};
|
|
370
370
|
});
|
|
371
371
|
}
|
|
372
|
-
function
|
|
373
|
-
const t =
|
|
374
|
-
text:
|
|
372
|
+
function pn(e, n) {
|
|
373
|
+
const t = b(() => ({
|
|
374
|
+
text: ze(e) ? e.value : null
|
|
375
375
|
})), {
|
|
376
376
|
colorClasses: s,
|
|
377
377
|
colorStyles: a
|
|
378
|
-
} =
|
|
378
|
+
} = xn(t);
|
|
379
379
|
return {
|
|
380
380
|
textColorClasses: s,
|
|
381
381
|
textColorStyles: a
|
|
382
382
|
};
|
|
383
383
|
}
|
|
384
|
-
const
|
|
384
|
+
const $e = [String, Function, Object, Array], Sn = Symbol.for("vuetify:icons"), Y = I({
|
|
385
385
|
icon: {
|
|
386
|
-
type:
|
|
386
|
+
type: $e
|
|
387
387
|
},
|
|
388
388
|
// Could not remove this and use makeTagProps, types complained because it is not required
|
|
389
389
|
tag: {
|
|
390
390
|
type: String,
|
|
391
391
|
required: !0
|
|
392
392
|
}
|
|
393
|
-
}, "icon"), ve =
|
|
393
|
+
}, "icon"), ve = Ie()({
|
|
394
394
|
name: "VComponentIcon",
|
|
395
395
|
props: Y(),
|
|
396
396
|
setup(e, n) {
|
|
@@ -399,10 +399,10 @@ const Ie = [String, Function, Object, Array], pn = Symbol.for("vuetify:icons"),
|
|
|
399
399
|
} = n;
|
|
400
400
|
return () => {
|
|
401
401
|
const s = e.icon;
|
|
402
|
-
return
|
|
402
|
+
return C(e.tag, null, {
|
|
403
403
|
default: () => {
|
|
404
404
|
var a;
|
|
405
|
-
return [e.icon ?
|
|
405
|
+
return [e.icon ? C(s, null, null) : (a = t.default) == null ? void 0 : a.call(t)];
|
|
406
406
|
}
|
|
407
407
|
});
|
|
408
408
|
};
|
|
@@ -415,21 +415,21 @@ const Ie = [String, Function, Object, Array], pn = Symbol.for("vuetify:icons"),
|
|
|
415
415
|
let {
|
|
416
416
|
attrs: t
|
|
417
417
|
} = n;
|
|
418
|
-
return () =>
|
|
418
|
+
return () => C(e.tag, xe(t, {
|
|
419
419
|
style: null
|
|
420
420
|
}), {
|
|
421
|
-
default: () => [
|
|
421
|
+
default: () => [C("svg", {
|
|
422
422
|
class: "v-icon__svg",
|
|
423
423
|
xmlns: "http://www.w3.org/2000/svg",
|
|
424
424
|
viewBox: "0 0 24 24",
|
|
425
425
|
role: "img",
|
|
426
426
|
"aria-hidden": "true"
|
|
427
|
-
}, [Array.isArray(e.icon) ? e.icon.map((s) => Array.isArray(s) ?
|
|
427
|
+
}, [Array.isArray(e.icon) ? e.icon.map((s) => Array.isArray(s) ? C("path", {
|
|
428
428
|
d: s[0],
|
|
429
429
|
"fill-opacity": s[1]
|
|
430
|
-
}, null) :
|
|
430
|
+
}, null) : C("path", {
|
|
431
431
|
d: s
|
|
432
|
-
}, null)) :
|
|
432
|
+
}, null)) : C("path", {
|
|
433
433
|
d: e.icon
|
|
434
434
|
}, null)])]
|
|
435
435
|
});
|
|
@@ -439,7 +439,7 @@ X({
|
|
|
439
439
|
name: "VLigatureIcon",
|
|
440
440
|
props: Y(),
|
|
441
441
|
setup(e) {
|
|
442
|
-
return () =>
|
|
442
|
+
return () => C(e.tag, null, {
|
|
443
443
|
default: () => [e.icon]
|
|
444
444
|
});
|
|
445
445
|
}
|
|
@@ -448,23 +448,23 @@ X({
|
|
|
448
448
|
name: "VClassIcon",
|
|
449
449
|
props: Y(),
|
|
450
450
|
setup(e) {
|
|
451
|
-
return () =>
|
|
451
|
+
return () => C(e.tag, {
|
|
452
452
|
class: e.icon
|
|
453
453
|
}, null);
|
|
454
454
|
}
|
|
455
455
|
});
|
|
456
456
|
const Fn = (e) => {
|
|
457
|
-
const n =
|
|
457
|
+
const n = j(Sn);
|
|
458
458
|
if (!n) throw new Error("Missing Vuetify Icons provide!");
|
|
459
459
|
return {
|
|
460
|
-
iconData:
|
|
460
|
+
iconData: b(() => {
|
|
461
461
|
var o;
|
|
462
462
|
const s = q(e);
|
|
463
463
|
if (!s) return {
|
|
464
464
|
component: ve
|
|
465
465
|
};
|
|
466
466
|
let a = s;
|
|
467
|
-
if (typeof a == "string" && (a = a.trim(), a.startsWith("$") && (a = (o = n.aliases) == null ? void 0 : o[a.slice(1)])), a ||
|
|
467
|
+
if (typeof a == "string" && (a = a.trim(), a.startsWith("$") && (a = (o = n.aliases) == null ? void 0 : o[a.slice(1)])), a || R(`Could not find aliased icon "${s}"`), Array.isArray(a))
|
|
468
468
|
return {
|
|
469
469
|
component: wn,
|
|
470
470
|
icon: a
|
|
@@ -474,14 +474,14 @@ const Fn = (e) => {
|
|
|
474
474
|
component: ve,
|
|
475
475
|
icon: a
|
|
476
476
|
};
|
|
477
|
-
const
|
|
477
|
+
const r = Object.keys(n.sets).find((f) => typeof a == "string" && a.startsWith(`${f}:`)), u = r ? a.slice(r.length + 1) : a;
|
|
478
478
|
return {
|
|
479
|
-
component: n.sets[
|
|
479
|
+
component: n.sets[r ?? n.defaultSet].component,
|
|
480
480
|
icon: u
|
|
481
481
|
};
|
|
482
482
|
})
|
|
483
483
|
};
|
|
484
|
-
}, Bn = ["x-small", "small", "default", "large", "x-large"], In =
|
|
484
|
+
}, Bn = ["x-small", "small", "default", "large", "x-large"], In = I({
|
|
485
485
|
size: {
|
|
486
486
|
type: [String, Number],
|
|
487
487
|
default: "default"
|
|
@@ -489,75 +489,100 @@ const Fn = (e) => {
|
|
|
489
489
|
}, "size");
|
|
490
490
|
function $n(e) {
|
|
491
491
|
let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : yn();
|
|
492
|
-
return
|
|
492
|
+
return we(() => {
|
|
493
493
|
let t, s;
|
|
494
494
|
return nn(Bn, e.size) ? t = `${n}--size-${e.size}` : e.size && (s = {
|
|
495
|
-
width:
|
|
496
|
-
height:
|
|
495
|
+
width: O(e.size),
|
|
496
|
+
height: O(e.size)
|
|
497
497
|
}), {
|
|
498
498
|
sizeClasses: t,
|
|
499
499
|
sizeStyles: s
|
|
500
500
|
};
|
|
501
501
|
});
|
|
502
502
|
}
|
|
503
|
-
const
|
|
503
|
+
const Dn = I({
|
|
504
504
|
color: String,
|
|
505
505
|
disabled: Boolean,
|
|
506
506
|
start: Boolean,
|
|
507
507
|
end: Boolean,
|
|
508
|
-
icon:
|
|
508
|
+
icon: $e,
|
|
509
509
|
...Qe(),
|
|
510
510
|
...In(),
|
|
511
|
-
...
|
|
511
|
+
..._n({
|
|
512
512
|
tag: "i"
|
|
513
513
|
}),
|
|
514
514
|
...Vn()
|
|
515
|
-
}, "VIcon"),
|
|
515
|
+
}, "VIcon"), An = Ie()({
|
|
516
516
|
name: "VIcon",
|
|
517
|
-
props:
|
|
517
|
+
props: Dn(),
|
|
518
518
|
setup(e, n) {
|
|
519
519
|
let {
|
|
520
520
|
attrs: t,
|
|
521
521
|
slots: s
|
|
522
522
|
} = n;
|
|
523
|
-
const a =
|
|
524
|
-
themeClasses:
|
|
525
|
-
} =
|
|
523
|
+
const a = T(), {
|
|
524
|
+
themeClasses: r
|
|
525
|
+
} = bn(e), {
|
|
526
526
|
iconData: u
|
|
527
|
-
} = Fn(
|
|
528
|
-
sizeClasses:
|
|
527
|
+
} = Fn(b(() => a.value || e.icon)), {
|
|
528
|
+
sizeClasses: y
|
|
529
529
|
} = $n(e), {
|
|
530
530
|
textColorClasses: o,
|
|
531
|
-
textColorStyles:
|
|
532
|
-
} =
|
|
531
|
+
textColorStyles: f
|
|
532
|
+
} = pn(Oe(e, "color"));
|
|
533
533
|
return Cn(() => {
|
|
534
|
-
var
|
|
535
|
-
const
|
|
536
|
-
|
|
534
|
+
var w, F;
|
|
535
|
+
const v = (w = s.default) == null ? void 0 : w.call(s);
|
|
536
|
+
v && (a.value = (F = Se(v).filter((_) => _.type === Re && _.children && typeof _.children == "string")[0]) == null ? void 0 : F.children);
|
|
537
537
|
const g = !!(t.onClick || t.onClickOnce);
|
|
538
|
-
return
|
|
538
|
+
return C(u.value.component, {
|
|
539
539
|
tag: e.tag,
|
|
540
540
|
icon: u.value.icon,
|
|
541
|
-
class: ["v-icon", "notranslate",
|
|
541
|
+
class: ["v-icon", "notranslate", r.value, y.value, o.value, {
|
|
542
542
|
"v-icon--clickable": g,
|
|
543
543
|
"v-icon--disabled": e.disabled,
|
|
544
544
|
"v-icon--start": e.start,
|
|
545
545
|
"v-icon--end": e.end
|
|
546
546
|
}, e.class],
|
|
547
|
-
style: [
|
|
548
|
-
fontSize:
|
|
549
|
-
height:
|
|
550
|
-
width:
|
|
551
|
-
},
|
|
547
|
+
style: [y.value ? void 0 : {
|
|
548
|
+
fontSize: O(e.size),
|
|
549
|
+
height: O(e.size),
|
|
550
|
+
width: O(e.size)
|
|
551
|
+
}, f.value, e.style],
|
|
552
552
|
role: g ? "button" : void 0,
|
|
553
553
|
"aria-hidden": !g,
|
|
554
554
|
tabindex: g ? e.disabled ? -1 : 0 : void 0
|
|
555
555
|
}, {
|
|
556
|
-
default: () => [
|
|
556
|
+
default: () => [v]
|
|
557
557
|
});
|
|
558
558
|
}), {};
|
|
559
559
|
}
|
|
560
|
-
}),
|
|
560
|
+
}), Mn = (e, n) => {
|
|
561
|
+
const t = e.__vccOpts || e;
|
|
562
|
+
for (const [s, a] of n)
|
|
563
|
+
t[s] = a;
|
|
564
|
+
return t;
|
|
565
|
+
}, Pn = {};
|
|
566
|
+
function Ln(e, n) {
|
|
567
|
+
const t = p("v-btn"), s = p("v-color-picker"), a = p("v-menu");
|
|
568
|
+
return S(), B(a, { "close-on-content-click": !1 }, {
|
|
569
|
+
activator: ne(({ props: r }) => [
|
|
570
|
+
C(t, xe(r, {
|
|
571
|
+
density: "comfortable",
|
|
572
|
+
color: "#00000000",
|
|
573
|
+
block: ""
|
|
574
|
+
}), null, 16)
|
|
575
|
+
]),
|
|
576
|
+
default: ne(() => [
|
|
577
|
+
C(s, {
|
|
578
|
+
"show-swatches": "",
|
|
579
|
+
"swatches-max-height": "150px"
|
|
580
|
+
})
|
|
581
|
+
]),
|
|
582
|
+
_: 1
|
|
583
|
+
});
|
|
584
|
+
}
|
|
585
|
+
const Tn = /* @__PURE__ */ Mn(Pn, [["render", Ln]]), zn = /* @__PURE__ */ M({
|
|
561
586
|
__name: "index",
|
|
562
587
|
props: /* @__PURE__ */ Z({
|
|
563
588
|
min: { default: () => -1 / 0 },
|
|
@@ -571,13 +596,14 @@ const An = p({
|
|
|
571
596
|
}),
|
|
572
597
|
emits: ["update:modelValue"],
|
|
573
598
|
setup(e) {
|
|
574
|
-
const n =
|
|
599
|
+
const n = ee(e, "modelValue");
|
|
575
600
|
return (t, s) => {
|
|
576
|
-
const a =
|
|
577
|
-
return
|
|
601
|
+
const a = p("v-number-input");
|
|
602
|
+
return S(), B(a, {
|
|
578
603
|
modelValue: n.value,
|
|
579
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
580
|
-
|
|
604
|
+
"onUpdate:modelValue": s[0] || (s[0] = (r) => n.value = r),
|
|
605
|
+
density: "compact",
|
|
606
|
+
"control-variant": "stacked",
|
|
581
607
|
min: t.min,
|
|
582
608
|
max: t.max,
|
|
583
609
|
precision: t.precision,
|
|
@@ -588,31 +614,32 @@ const An = p({
|
|
|
588
614
|
}, null, 8, ["modelValue", "min", "max", "precision", "step", "readonly"]);
|
|
589
615
|
};
|
|
590
616
|
}
|
|
591
|
-
}),
|
|
617
|
+
}), On = /* @__PURE__ */ M({
|
|
592
618
|
__name: "index",
|
|
593
619
|
props: /* @__PURE__ */ Z({
|
|
594
|
-
readonly: { type: Boolean, default: !1 }
|
|
620
|
+
readonly: { type: Boolean, default: !1 },
|
|
621
|
+
items: {}
|
|
595
622
|
}, {
|
|
596
623
|
modelValue: {},
|
|
597
624
|
modelModifiers: {}
|
|
598
625
|
}),
|
|
599
626
|
emits: ["update:modelValue"],
|
|
600
627
|
setup(e) {
|
|
601
|
-
const n =
|
|
628
|
+
const n = ee(e, "modelValue");
|
|
602
629
|
return (t, s) => {
|
|
603
|
-
const a =
|
|
604
|
-
return
|
|
630
|
+
const a = p("v-select");
|
|
631
|
+
return S(), B(a, {
|
|
605
632
|
modelValue: n.value,
|
|
606
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
607
|
-
variant: "outlined",
|
|
633
|
+
"onUpdate:modelValue": s[0] || (s[0] = (r) => n.value = r),
|
|
608
634
|
density: "compact",
|
|
635
|
+
items: t.items,
|
|
609
636
|
"hide-details": "",
|
|
610
637
|
"single-line": "",
|
|
611
638
|
readonly: t.readonly
|
|
612
|
-
}, null, 8, ["modelValue", "readonly"]);
|
|
639
|
+
}, null, 8, ["modelValue", "items", "readonly"]);
|
|
613
640
|
};
|
|
614
641
|
}
|
|
615
|
-
}), ke = /* @__PURE__ */
|
|
642
|
+
}), ke = /* @__PURE__ */ M({
|
|
616
643
|
__name: "index",
|
|
617
644
|
props: /* @__PURE__ */ Z({
|
|
618
645
|
readonly: { type: Boolean, default: !1 },
|
|
@@ -623,23 +650,22 @@ const An = p({
|
|
|
623
650
|
}),
|
|
624
651
|
emits: /* @__PURE__ */ Z(["delete"], ["update:modelValue"]),
|
|
625
652
|
setup(e, { emit: n }) {
|
|
626
|
-
const t =
|
|
627
|
-
return (a,
|
|
628
|
-
const u =
|
|
629
|
-
return
|
|
653
|
+
const t = ee(e, "modelValue"), s = n;
|
|
654
|
+
return (a, r) => {
|
|
655
|
+
const u = p("v-text-field");
|
|
656
|
+
return S(), B(u, {
|
|
630
657
|
modelValue: t.value,
|
|
631
|
-
"onUpdate:modelValue":
|
|
632
|
-
variant: "outlined",
|
|
658
|
+
"onUpdate:modelValue": r[0] || (r[0] = (y) => t.value = y),
|
|
633
659
|
density: "compact",
|
|
634
660
|
"append-inner-icon": a.hasDelete ? q(Ke) : "",
|
|
635
661
|
"hide-details": "",
|
|
636
662
|
"single-line": "",
|
|
637
663
|
readonly: a.readonly,
|
|
638
|
-
"onClick:appendInner":
|
|
664
|
+
"onClick:appendInner": r[1] || (r[1] = (y) => s("delete"))
|
|
639
665
|
}, null, 8, ["modelValue", "append-inner-icon", "readonly"]);
|
|
640
666
|
};
|
|
641
667
|
}
|
|
642
|
-
}), Ce = /* @__PURE__ */
|
|
668
|
+
}), Ce = /* @__PURE__ */ M({
|
|
643
669
|
__name: "index",
|
|
644
670
|
props: {
|
|
645
671
|
title: {},
|
|
@@ -650,40 +676,40 @@ const An = p({
|
|
|
650
676
|
},
|
|
651
677
|
emits: ["collapse", "create", "delete"],
|
|
652
678
|
setup(e, { emit: n }) {
|
|
653
|
-
const t =
|
|
679
|
+
const t = n, s = b(() => ({
|
|
654
680
|
height: "36px"
|
|
655
681
|
}));
|
|
656
|
-
return (
|
|
657
|
-
const
|
|
658
|
-
return
|
|
682
|
+
return (a, r) => {
|
|
683
|
+
const u = p("v-icon"), y = p("v-spacer"), o = Ne("ripple");
|
|
684
|
+
return He((S(), Ee("div", {
|
|
659
685
|
class: "d-flex align-center",
|
|
660
|
-
style: We(
|
|
661
|
-
onClick:
|
|
686
|
+
style: We(s.value),
|
|
687
|
+
onClick: r[2] || (r[2] = (f) => t("collapse", !a.collapse))
|
|
662
688
|
}, [
|
|
663
|
-
|
|
689
|
+
C(u, {
|
|
664
690
|
class: "mr-1",
|
|
665
|
-
icon:
|
|
691
|
+
icon: a.collapse ? q(Ye) : q(Xe)
|
|
666
692
|
}, null, 8, ["icon"]),
|
|
667
|
-
Ue("span", null, Ge(
|
|
668
|
-
|
|
669
|
-
|
|
693
|
+
Ue("span", null, Ge(a.title), 1),
|
|
694
|
+
C(y),
|
|
695
|
+
a.hasCreate ? (S(), B(u, {
|
|
670
696
|
key: 0,
|
|
671
697
|
class: "ml-3",
|
|
672
698
|
icon: "$plus",
|
|
673
|
-
onClick:
|
|
699
|
+
onClick: r[0] || (r[0] = te((f) => t("create"), ["stop"]))
|
|
674
700
|
})) : se("", !0),
|
|
675
|
-
|
|
701
|
+
a.hasDelete ? (S(), B(u, {
|
|
676
702
|
key: 1,
|
|
677
703
|
class: "ml-3",
|
|
678
704
|
icon: "$sub",
|
|
679
|
-
onClick:
|
|
705
|
+
onClick: r[1] || (r[1] = te((f) => t("delete", a.index), ["stop"]))
|
|
680
706
|
})) : se("", !0)
|
|
681
707
|
], 4)), [
|
|
682
|
-
[
|
|
708
|
+
[o]
|
|
683
709
|
]);
|
|
684
710
|
};
|
|
685
711
|
}
|
|
686
|
-
}),
|
|
712
|
+
}), Rn = /* @__PURE__ */ M({
|
|
687
713
|
__name: "index",
|
|
688
714
|
props: {
|
|
689
715
|
unique: {},
|
|
@@ -692,22 +718,22 @@ const An = p({
|
|
|
692
718
|
},
|
|
693
719
|
emits: ["change"],
|
|
694
720
|
setup(e, { emit: n }) {
|
|
695
|
-
const { t } = qe(), { backgroundColor2: s } = Ze(), a = e,
|
|
696
|
-
function g(
|
|
697
|
-
return l.keyFlag || (
|
|
721
|
+
const { t } = qe(), { backgroundColor2: s } = Ze(), a = e, r = n, u = T("20px"), y = T("56px"), o = T("10px"), f = T("250px"), v = Ve({});
|
|
722
|
+
function g(c, l, i, d) {
|
|
723
|
+
return l.keyFlag || (c !== "" && (c += "."), c += l.key), l.children ? l.array ? w(c, l, i, d) : F(c, l, i, d) : l.array ? _(c, l, i) : E(c, l, i);
|
|
698
724
|
}
|
|
699
|
-
function
|
|
700
|
-
|
|
701
|
-
const
|
|
725
|
+
function w(c, l, i, d) {
|
|
726
|
+
i[l.key] instanceof Array || (i[l.key] = [], r("change", c, i[l.key]));
|
|
727
|
+
const V = k(Ce, {
|
|
702
728
|
title: t(l.name),
|
|
703
|
-
collapse: !!
|
|
704
|
-
onCollapse: (
|
|
705
|
-
|
|
729
|
+
collapse: !!d.collapse,
|
|
730
|
+
onCollapse: (m) => {
|
|
731
|
+
d.collapse = m;
|
|
706
732
|
},
|
|
707
733
|
onCreate: () => {
|
|
708
|
-
|
|
734
|
+
i[l.key].push({}), r("change", c, i[l.key]);
|
|
709
735
|
}
|
|
710
|
-
}),
|
|
736
|
+
}), h = k(
|
|
711
737
|
"div",
|
|
712
738
|
{
|
|
713
739
|
style: {
|
|
@@ -715,15 +741,15 @@ const An = p({
|
|
|
715
741
|
}
|
|
716
742
|
},
|
|
717
743
|
(() => {
|
|
718
|
-
|
|
719
|
-
for (let
|
|
720
|
-
typeof
|
|
744
|
+
d[l.key] instanceof Array || (d[l.key] = []);
|
|
745
|
+
for (let m = 0; m < i[l.key].length; m++)
|
|
746
|
+
typeof d[l.key][m] != "object" && (d[l.key][m] = {
|
|
721
747
|
collapse: !0
|
|
722
748
|
});
|
|
723
749
|
return [];
|
|
724
750
|
})()
|
|
725
751
|
);
|
|
726
|
-
return
|
|
752
|
+
return k(
|
|
727
753
|
"div",
|
|
728
754
|
{
|
|
729
755
|
style: {
|
|
@@ -732,19 +758,19 @@ const An = p({
|
|
|
732
758
|
}
|
|
733
759
|
},
|
|
734
760
|
(() => {
|
|
735
|
-
const
|
|
736
|
-
return
|
|
761
|
+
const m = [];
|
|
762
|
+
return m.push(V), d.collapse || m.push(h), m;
|
|
737
763
|
})()
|
|
738
764
|
);
|
|
739
765
|
}
|
|
740
|
-
function
|
|
741
|
-
const
|
|
766
|
+
function F(c, l, i, d) {
|
|
767
|
+
const V = k(Ce, {
|
|
742
768
|
title: t(l.name),
|
|
743
|
-
collapse: !!
|
|
744
|
-
onCollapse: (
|
|
745
|
-
|
|
769
|
+
collapse: !!d.collapse,
|
|
770
|
+
onCollapse: (m) => {
|
|
771
|
+
d.collapse = m;
|
|
746
772
|
}
|
|
747
|
-
}),
|
|
773
|
+
}), h = k(
|
|
748
774
|
"div",
|
|
749
775
|
{
|
|
750
776
|
style: {
|
|
@@ -752,23 +778,23 @@ const An = p({
|
|
|
752
778
|
}
|
|
753
779
|
},
|
|
754
780
|
(() => {
|
|
755
|
-
var
|
|
756
|
-
const
|
|
757
|
-
return (
|
|
758
|
-
typeof
|
|
781
|
+
var $;
|
|
782
|
+
const m = [];
|
|
783
|
+
return ($ = l.children) == null || $.forEach((x) => {
|
|
784
|
+
typeof d[x.key] != "object" && (d[x.key] = {
|
|
759
785
|
collapse: !0
|
|
760
786
|
});
|
|
761
|
-
const
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
l.keyFlag ?
|
|
765
|
-
|
|
787
|
+
const De = g(
|
|
788
|
+
c,
|
|
789
|
+
x,
|
|
790
|
+
l.keyFlag ? i : (typeof i[l.key] != "object" && (i[l.key] = {}, r("change", c, i[l.key])), i[l.key]),
|
|
791
|
+
d[x.key]
|
|
766
792
|
);
|
|
767
|
-
|
|
768
|
-
}),
|
|
793
|
+
m.push(De);
|
|
794
|
+
}), m;
|
|
769
795
|
})()
|
|
770
796
|
);
|
|
771
|
-
return
|
|
797
|
+
return k(
|
|
772
798
|
"div",
|
|
773
799
|
{
|
|
774
800
|
style: {
|
|
@@ -777,164 +803,133 @@ const An = p({
|
|
|
777
803
|
}
|
|
778
804
|
},
|
|
779
805
|
(() => {
|
|
780
|
-
const
|
|
781
|
-
return
|
|
806
|
+
const m = [];
|
|
807
|
+
return m.push(V), d.collapse || m.push(h), m;
|
|
782
808
|
})()
|
|
783
809
|
);
|
|
784
810
|
}
|
|
785
|
-
function
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
r[l.key][V] = E, i("change", f, r[l.key]);
|
|
805
|
-
},
|
|
806
|
-
hasDelete: !0,
|
|
807
|
-
onDelete: () => {
|
|
808
|
-
r[l.key].splice(V, 1), i("change", f, r[l.key]);
|
|
809
|
-
}
|
|
810
|
-
})
|
|
811
|
-
]
|
|
812
|
-
);
|
|
813
|
-
c.push(h);
|
|
814
|
-
}
|
|
815
|
-
const A = v(
|
|
816
|
-
"div",
|
|
817
|
-
{
|
|
818
|
-
class: "d-flex align-center justify-center",
|
|
819
|
-
style: {
|
|
820
|
-
backgroundColor: "transparent",
|
|
821
|
-
width: "100%",
|
|
822
|
-
height: "40px",
|
|
823
|
-
marginTop: "8px",
|
|
824
|
-
marginBottom: "8px",
|
|
825
|
-
borderRadius: "5px",
|
|
826
|
-
border: "thin dashed #bdbdbd"
|
|
811
|
+
function _(c, l, i) {
|
|
812
|
+
i[l.key] instanceof Array || (i[l.key] = L(l), r("change", c, i[l.key]));
|
|
813
|
+
let d = () => [];
|
|
814
|
+
return l.ui === "strInput" ? d = () => {
|
|
815
|
+
const V = [];
|
|
816
|
+
for (let m = 0; m < i[l.key].length; m++) {
|
|
817
|
+
const $ = k(
|
|
818
|
+
"div",
|
|
819
|
+
{
|
|
820
|
+
class: "d-flex align-center justify-center",
|
|
821
|
+
style: {
|
|
822
|
+
height: y.value
|
|
823
|
+
}
|
|
824
|
+
},
|
|
825
|
+
[
|
|
826
|
+
k(ke, {
|
|
827
|
+
modelValue: i[l.key][m],
|
|
828
|
+
"onUpdate:modelValue": (x) => {
|
|
829
|
+
i[l.key][m] = x, r("change", c, i[l.key]);
|
|
827
830
|
},
|
|
828
|
-
|
|
829
|
-
|
|
831
|
+
hasDelete: !0,
|
|
832
|
+
onDelete: () => {
|
|
833
|
+
i[l.key].splice(m, 1), r("change", c, i[l.key]);
|
|
830
834
|
}
|
|
831
|
-
}
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
835
|
+
})
|
|
836
|
+
]
|
|
837
|
+
);
|
|
838
|
+
V.push($);
|
|
839
|
+
}
|
|
840
|
+
const h = k(
|
|
841
|
+
"div",
|
|
842
|
+
{
|
|
843
|
+
class: "d-flex align-center justify-center",
|
|
844
|
+
style: {
|
|
845
|
+
backgroundColor: "transparent",
|
|
846
|
+
width: "100%",
|
|
847
|
+
height: "40px",
|
|
848
|
+
marginTop: "8px",
|
|
849
|
+
marginBottom: "8px",
|
|
850
|
+
borderRadius: "5px",
|
|
851
|
+
border: "thin dashed #bdbdbd"
|
|
852
|
+
},
|
|
853
|
+
onClick: () => {
|
|
854
|
+
i[l.key].push(""), r("change", c, i[l.key]);
|
|
855
|
+
}
|
|
856
|
+
},
|
|
857
|
+
[k(An, { icon: Je })]
|
|
836
858
|
);
|
|
837
|
-
|
|
859
|
+
return V.push(h), V;
|
|
860
|
+
} : console.assert(!1, "invalid prop ui", l.ui), P(t(l.name), d());
|
|
838
861
|
}
|
|
839
|
-
function
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
marginRight: o.value
|
|
846
|
-
}
|
|
862
|
+
function E(c, l, i) {
|
|
863
|
+
let d = () => [];
|
|
864
|
+
return l.ui === "void" ? i[l.key] === void 0 && (console.assert(l.default !== void 0), i[l.key] = L(l), r("change", c, i[l.key])) : l.ui === "strInput" ? d = () => [k(ke, {
|
|
865
|
+
modelValue: l.static ? l.value : (typeof i[l.key] != "string" && (i[l.key] = L(l), r("change", c, i[l.key])), i[l.key]),
|
|
866
|
+
"onUpdate:modelValue": (h) => {
|
|
867
|
+
l.static || h !== i[l.key] && (i[l.key] = h, r("change", c, h));
|
|
847
868
|
},
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
})
|
|
868
|
-
);
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
v(Ln, {
|
|
873
|
-
modelValue: (typeof r[l.key] != "number" && (r[l.key] = D(l), i("change", f, r[l.key])), r[l.key]),
|
|
874
|
-
"onUpdate:modelValue": (c) => {
|
|
875
|
-
c !== r[l.key] && (r[l.key] = c, i("change", f, c));
|
|
876
|
-
},
|
|
877
|
-
readonly: l.readonly
|
|
878
|
-
})
|
|
879
|
-
);
|
|
880
|
-
if (l.ui === "select")
|
|
881
|
-
return w(
|
|
882
|
-
t(l.name),
|
|
883
|
-
v(Mn, {
|
|
884
|
-
modelValue: (() => {
|
|
885
|
-
if (typeof r[l.key] > "u")
|
|
886
|
-
return r[l.key] = D(l), i("change", f, r[l.key]), r[l.key];
|
|
887
|
-
})(),
|
|
888
|
-
"onUpdate:modelValue": (c) => {
|
|
889
|
-
c !== r[l.key] && (r[l.key] = c, i("change", f, c));
|
|
890
|
-
},
|
|
891
|
-
readonly: l.readonly
|
|
892
|
-
})
|
|
893
|
-
);
|
|
894
|
-
console.assert(!1, "invalid prop ui", l.ui);
|
|
895
|
-
}
|
|
869
|
+
readonly: l.static || l.readonly
|
|
870
|
+
})] : l.ui === "numInput" ? d = () => [k(zn, {
|
|
871
|
+
modelValue: (typeof i[l.key] != "number" && (i[l.key] = L(l), r("change", c, i[l.key])), i[l.key]),
|
|
872
|
+
"onUpdate:modelValue": (h) => {
|
|
873
|
+
h !== i[l.key] && (i[l.key] = h, r("change", c, h));
|
|
874
|
+
},
|
|
875
|
+
readonly: l.readonly
|
|
876
|
+
})] : l.ui === "select" ? d = () => [k(On, {
|
|
877
|
+
modelValue: (typeof i[l.key] != "string" && (i[l.key] = L(l), r("change", c, i[l.key])), i[l.key]),
|
|
878
|
+
"onUpdate:modelValue": (h) => {
|
|
879
|
+
h !== i[l.key] && (i[l.key] = h, r("change", c, h));
|
|
880
|
+
},
|
|
881
|
+
items: (() => {
|
|
882
|
+
var m;
|
|
883
|
+
const h = [];
|
|
884
|
+
return (m = l.items) == null || m.forEach(({ title: $, value: x }) => {
|
|
885
|
+
h.push({
|
|
886
|
+
title: t($),
|
|
887
|
+
value: x
|
|
888
|
+
});
|
|
889
|
+
}), h;
|
|
890
|
+
})(),
|
|
891
|
+
readonly: l.readonly
|
|
892
|
+
})] : l.ui === "colorPicker" ? d = () => [k(Tn)] : console.assert(!1, "invalid prop ui", l.ui), P(t(l.name), d());
|
|
896
893
|
}
|
|
897
|
-
function
|
|
898
|
-
return
|
|
894
|
+
function P(c, l) {
|
|
895
|
+
return k(
|
|
899
896
|
"div",
|
|
900
897
|
{
|
|
901
898
|
class: "d-flex justify-space-between align-center",
|
|
902
899
|
style: {
|
|
903
|
-
|
|
900
|
+
minHeight: y.value,
|
|
904
901
|
marginRight: o.value
|
|
905
902
|
}
|
|
906
903
|
},
|
|
907
904
|
[
|
|
908
|
-
|
|
909
|
-
|
|
905
|
+
k("span", { style: { marginLeft: "4px" }, innerHTML: c }),
|
|
906
|
+
k("div", { style: { width: f.value } }, l)
|
|
910
907
|
]
|
|
911
908
|
);
|
|
912
909
|
}
|
|
913
|
-
const
|
|
910
|
+
const W = () => k(
|
|
914
911
|
"div",
|
|
915
912
|
{
|
|
916
|
-
class:
|
|
917
|
-
"text-body-2": !0
|
|
918
|
-
}
|
|
913
|
+
class: "text-body-2"
|
|
919
914
|
},
|
|
920
915
|
(() => {
|
|
921
|
-
const
|
|
916
|
+
const c = [];
|
|
922
917
|
if (a.unique && a.config && a.object) {
|
|
923
|
-
|
|
924
|
-
const l =
|
|
925
|
-
a.config.forEach((
|
|
926
|
-
const
|
|
927
|
-
|
|
918
|
+
v[a.unique] || (v[a.unique] = {});
|
|
919
|
+
const l = v[a.unique];
|
|
920
|
+
a.config.forEach((i) => {
|
|
921
|
+
const d = g("", i, a.object, l);
|
|
922
|
+
c.push(d);
|
|
928
923
|
});
|
|
929
924
|
}
|
|
930
|
-
return
|
|
925
|
+
return c;
|
|
931
926
|
})()
|
|
932
927
|
);
|
|
933
|
-
return (
|
|
928
|
+
return (c, l) => (S(), B(W));
|
|
934
929
|
}
|
|
935
|
-
}),
|
|
936
|
-
e.component("XPropTree",
|
|
937
|
-
},
|
|
930
|
+
}), Nn = (e) => {
|
|
931
|
+
e.component("XPropTree", Rn);
|
|
932
|
+
}, Gn = { install: Nn };
|
|
938
933
|
export {
|
|
939
|
-
|
|
934
|
+
Gn as default
|
|
940
935
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x-prop-tree",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.4.
|
|
4
|
+
"version": "0.4.6",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"vue-i18n": "^10.0.4",
|
|
27
27
|
"vuetify": "^3.7.3",
|
|
28
28
|
"x-essential-lib": "^0.7.3",
|
|
29
|
-
"x-runtime-lib": "^0.4.
|
|
29
|
+
"x-runtime-lib": "^0.4.7"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@eslint/js": "^10.0.0",
|