@farris/ui-vue 1.2.8 → 1.2.9
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/components/accordion/index.esm.js +129 -129
- package/components/accordion/index.umd.cjs +1 -0
- package/components/avatar/index.esm.js +166 -157
- package/components/avatar/index.umd.cjs +1 -0
- package/components/border-editor/index.umd.cjs +1 -0
- package/components/button/index.umd.cjs +1 -0
- package/components/button-edit/index.esm.js +343 -325
- package/components/button-edit/index.umd.cjs +1 -0
- package/components/button-group/index.umd.cjs +1 -0
- package/components/calculator/index.umd.cjs +1 -0
- package/components/calendar/index.esm.js +338 -338
- package/components/calendar/index.umd.cjs +1 -0
- package/components/capsule/index.esm.js +182 -182
- package/components/capsule/index.umd.cjs +1 -0
- package/components/checkbox/index.esm.js +326 -317
- package/components/checkbox/index.umd.cjs +1 -0
- package/components/color-picker/index.esm.js +118 -118
- package/components/color-picker/index.umd.cjs +3 -0
- package/components/combo-list/index.esm.js +338 -325
- package/components/combo-list/index.umd.cjs +1 -0
- package/components/combo-tree/index.esm.js +62 -62
- package/components/combo-tree/index.umd.cjs +1 -0
- package/components/common/index.umd.cjs +1 -0
- package/components/component/index.esm.js +382 -270
- package/components/component/index.umd.cjs +1 -0
- package/components/condition/index.esm.js +1018 -895
- package/components/condition/index.umd.cjs +1 -0
- package/components/content-container/index.esm.js +285 -212
- package/components/content-container/index.umd.cjs +1 -0
- package/components/data-grid/index.css +1 -1
- package/components/data-grid/index.esm.js +4761 -4319
- package/components/data-grid/index.umd.cjs +1 -0
- package/components/data-view/index.esm.js +2901 -2664
- package/components/data-view/index.umd.cjs +1 -0
- package/components/date-picker/index.esm.js +1502 -1488
- package/components/date-picker/index.umd.cjs +1 -0
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +938 -928
- package/components/designer-canvas/index.umd.cjs +1 -0
- package/components/designer-outline/index.css +1 -1
- package/components/designer-outline/index.esm.js +27 -27
- package/components/designer-outline/index.umd.cjs +1 -0
- package/components/designer-toolbox/index.esm.js +36 -12
- package/components/designer-toolbox/index.umd.cjs +1 -0
- package/components/discussion-editor/index.umd.cjs +3 -0
- package/components/discussion-list/index.umd.cjs +1 -0
- package/components/drawer/index.umd.cjs +1 -0
- package/components/dropdown/index.esm.js +241 -241
- package/components/dropdown/index.umd.cjs +2 -0
- package/components/dynamic-form/index.esm.js +1074 -885
- package/components/dynamic-form/index.umd.cjs +1 -0
- package/components/dynamic-resolver/index.esm.js +99 -94
- package/components/dynamic-resolver/index.umd.cjs +1 -0
- package/components/dynamic-view/index.umd.cjs +1 -0
- package/components/enum-editor/index.umd.cjs +1 -0
- package/components/events-editor/index.esm.js +577 -522
- package/components/events-editor/index.umd.cjs +1 -0
- package/components/expression-editor/index.esm.js +70 -70
- package/components/expression-editor/index.umd.cjs +1 -0
- package/components/external-container/index.css +1 -1
- package/components/external-container/index.esm.js +2938 -2619
- package/components/external-container/index.umd.cjs +1 -0
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +4766 -4325
- package/components/field-selector/index.umd.cjs +1 -0
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1231 -1215
- package/components/filter-bar/index.umd.cjs +1 -0
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +1062 -1052
- package/components/flow-canvas/index.umd.cjs +1 -0
- package/components/image-cropper/index.esm.js +373 -373
- package/components/image-cropper/index.umd.cjs +1 -0
- package/components/input-group/index.esm.js +398 -394
- package/components/input-group/index.umd.cjs +1 -0
- package/components/layout/index.esm.js +268 -268
- package/components/layout/index.umd.cjs +1 -0
- package/components/list-nav/index.esm.js +234 -161
- package/components/list-nav/index.umd.cjs +1 -0
- package/components/list-view/index.css +1 -1
- package/components/list-view/index.esm.js +2288 -2048
- package/components/list-view/index.umd.cjs +1 -0
- package/components/loading/index.umd.cjs +8 -0
- package/components/locale/index.umd.cjs +1 -0
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +5776 -5305
- package/components/lookup/index.umd.cjs +1 -0
- package/components/mapping-editor/index.css +1 -1
- package/components/mapping-editor/index.esm.js +5496 -5036
- package/components/mapping-editor/index.umd.cjs +1 -0
- package/components/message-box/index.umd.cjs +1 -0
- package/components/modal/index.umd.cjs +1 -0
- package/components/nav/index.esm.js +383 -322
- package/components/nav/index.umd.cjs +3 -0
- package/components/notify/index.umd.cjs +1 -0
- package/components/number-range/index.esm.js +273 -269
- package/components/number-range/index.umd.cjs +1 -0
- package/components/number-spinner/index.esm.js +292 -283
- package/components/number-spinner/index.umd.cjs +1 -0
- package/components/order/index.css +1 -1
- package/components/order/index.esm.js +1008 -925
- package/components/order/index.umd.cjs +1 -0
- package/components/page-footer/index.esm.js +98 -98
- package/components/page-footer/index.umd.cjs +1 -0
- package/components/page-header/index.esm.js +949 -847
- package/components/page-header/index.umd.cjs +1 -0
- package/components/pagination/index.esm.js +464 -403
- package/components/pagination/index.umd.cjs +1 -0
- package/components/popover/index.umd.cjs +1 -0
- package/components/progress/index.esm.js +226 -226
- package/components/progress/index.umd.cjs +3 -0
- package/components/property-editor/index.esm.js +1110 -1092
- package/components/property-editor/index.umd.cjs +3 -0
- package/components/property-panel/index.esm.js +520 -513
- package/components/property-panel/index.umd.cjs +1 -0
- package/components/query-solution/index.css +1 -1
- package/components/query-solution/index.esm.js +1714 -1575
- package/components/query-solution/index.umd.cjs +1 -0
- package/components/radio-button/index.esm.js +67 -67
- package/components/radio-button/index.umd.cjs +1 -0
- package/components/radio-group/index.esm.js +298 -289
- package/components/radio-group/index.umd.cjs +1 -0
- package/components/rate/index.esm.js +195 -190
- package/components/rate/index.umd.cjs +1 -0
- package/components/response-layout/index.esm.js +112 -112
- package/components/response-layout/index.umd.cjs +1 -0
- package/components/response-layout-editor/index.esm.js +902 -877
- package/components/response-layout-editor/index.umd.cjs +1 -0
- package/components/response-toolbar/index.esm.js +874 -778
- package/components/response-toolbar/index.umd.cjs +1 -0
- package/components/schema-selector/index.css +1 -1
- package/components/schema-selector/index.esm.js +4594 -4289
- package/components/schema-selector/index.umd.cjs +8 -0
- package/components/search-box/index.esm.js +126 -126
- package/components/search-box/index.umd.cjs +1 -0
- package/components/section/index.esm.js +645 -503
- package/components/section/index.umd.cjs +1 -0
- package/components/smoke-detector/index.esm.js +120 -120
- package/components/smoke-detector/index.umd.cjs +1 -0
- package/components/spacing-editor/index.umd.cjs +1 -0
- package/components/splitter/index.esm.js +421 -348
- package/components/splitter/index.umd.cjs +1 -0
- package/components/step/index.esm.js +219 -219
- package/components/step/index.umd.cjs +1 -0
- package/components/switch/index.esm.js +232 -222
- package/components/switch/index.umd.cjs +1 -0
- package/components/tabs/index.esm.js +1823 -1744
- package/components/tabs/index.umd.cjs +1 -0
- package/components/tags/index.esm.js +399 -401
- package/components/tags/index.umd.cjs +1 -0
- package/components/text/index.esm.js +164 -164
- package/components/text/index.umd.cjs +1 -0
- package/components/textarea/index.esm.js +220 -215
- package/components/textarea/index.umd.cjs +1 -0
- package/components/time-picker/index.esm.js +693 -666
- package/components/time-picker/index.umd.cjs +1 -0
- package/components/tooltip/index.umd.cjs +1 -0
- package/components/transfer/index.css +1 -1
- package/components/transfer/index.esm.js +422 -413
- package/components/transfer/index.umd.cjs +1 -0
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +4799 -4358
- package/components/tree-grid/index.umd.cjs +1 -0
- package/components/tree-view/index.esm.js +2448 -2215
- package/components/tree-view/index.umd.cjs +1 -0
- package/components/uploader/index.esm.js +164 -164
- package/components/uploader/index.umd.cjs +2 -0
- package/components/verify-detail/index.esm.js +143 -143
- package/components/verify-detail/index.umd.cjs +1 -0
- package/components/video/index.esm.js +410 -331
- package/components/video/index.umd.cjs +1 -0
- package/components/weather/index.esm.js +901 -901
- package/components/weather/index.umd.cjs +16 -0
- package/farris.all.esm.js +12305 -11403
- package/farris.all.umd.cjs +8 -8
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/button-edit/src/designer/button-group.design.component.d.ts +7 -0
- package/types/combo-list/src/components/list-container.component.d.ts +3 -0
- package/types/combo-list/src/components/list-container.props.d.ts +5 -1
- package/types/common/entity/entity-schema.d.ts +258 -0
- package/types/component/src/component-ref.props.d.ts +4 -0
- package/types/component/src/composition/inner-component-build-info.d.ts +27 -0
- package/types/component/src/designer/use-designer-rules.d.ts +2 -2
- package/types/data-grid/index.d.ts +5 -2
- package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +33 -0
- package/types/data-grid/src/data-grid.component.d.ts +2 -1
- package/types/data-grid/src/data-grid.props.d.ts +2 -2
- package/types/data-grid/src/designer/use-group-column.d.ts +20 -0
- package/types/data-grid/src/property-config/data-grid.property-config.d.ts +4 -0
- package/types/data-grid/src/schema/schema-resolver.d.ts +2 -1
- package/types/data-view/components/column-format/boolean.component.d.ts +4 -0
- package/types/data-view/components/column-format/column-format.component.d.ts +4 -0
- package/types/data-view/components/column-format/date.component.d.ts +4 -0
- package/types/data-view/components/column-format/enum.component.d.ts +4 -0
- package/types/data-view/components/column-format/number.component.d.ts +4 -0
- package/types/data-view/composition/pagination/use-pagination.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +18 -6
- package/types/data-view/composition/use-edit.d.ts +2 -1
- package/types/designer-canvas/src/composition/function/use-dragula.d.ts +2 -2
- package/types/designer-canvas/src/types.d.ts +2 -2
- package/types/dynamic-form/index.d.ts +2 -1
- package/types/dynamic-form/src/composition/response-form-component-creator.service.d.ts +31 -0
- package/types/dynamic-form/src/schema/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/types.d.ts +3 -2
- package/types/response-toolbar/src/response-toolbar.props.d.ts +2 -2
- package/types/response-toolbar/src/schema/schema-mapper.d.ts +4 -0
- package/types/section/src/property-config/section.property-config.d.ts +93 -0
- package/types/section/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/composition/types.d.ts +2 -2
- package/types/tabs/src/designer/tab-header-item.design.component.d.ts +3 -1
- package/types/tabs/src/property-config/tab-page.property-config.d.ts +60 -0
- package/types/tabs/src/schema/schema-resolver.d.ts +2 -1
- package/types/tags/index.d.ts +36 -5
|
@@ -6,10 +6,10 @@ import { cloneDeep as N } from "lodash-es";
|
|
|
6
6
|
import { resolveAppearance as j, getSchemaByType as M } from "../dynamic-resolver/index.esm.js";
|
|
7
7
|
import { useDesignerComponent as Q } from "../designer-canvas/index.esm.js";
|
|
8
8
|
import { withInstall as q } from "../common/index.esm.js";
|
|
9
|
-
const
|
|
9
|
+
const U = {}, O = {};
|
|
10
10
|
function V(t) {
|
|
11
|
-
const { properties: e, title: n } = t, r = Object.keys(e).reduce((
|
|
12
|
-
return r.id = `${n}-${Date.now()}
|
|
11
|
+
const { properties: e, title: n, ignore: r } = t, o = r && Array.isArray(r), d = Object.keys(e).reduce((u, s) => ((!o || !r.find((A) => A == s)) && (u[s] = e[s].type === "object" && e[s].properties ? V(e[s]) : N(e[s].default)), u), {});
|
|
12
|
+
return (!o || !r.find((u) => u == "id")) && (d.id = `${n}-${Date.now()}`), d;
|
|
13
13
|
}
|
|
14
14
|
function W(t, e) {
|
|
15
15
|
const n = V(e);
|
|
@@ -18,12 +18,12 @@ function W(t, e) {
|
|
|
18
18
|
function G(t, e) {
|
|
19
19
|
return Object.keys(t).filter((r) => t[r] != null).reduce((r, o) => {
|
|
20
20
|
if (e.has(o)) {
|
|
21
|
-
const
|
|
22
|
-
if (typeof
|
|
23
|
-
r[
|
|
21
|
+
const d = e.get(o);
|
|
22
|
+
if (typeof d == "string")
|
|
23
|
+
r[d] = t[o];
|
|
24
24
|
else {
|
|
25
|
-
const
|
|
26
|
-
Object.assign(r,
|
|
25
|
+
const u = d(o, t[o], t);
|
|
26
|
+
Object.assign(r, u);
|
|
27
27
|
}
|
|
28
28
|
} else
|
|
29
29
|
r[o] = t[o];
|
|
@@ -35,56 +35,56 @@ function L(t, e, n = /* @__PURE__ */ new Map()) {
|
|
|
35
35
|
return G(r, n);
|
|
36
36
|
}
|
|
37
37
|
function Z(t = {}) {
|
|
38
|
-
function e(i,
|
|
39
|
-
if (typeof
|
|
40
|
-
return
|
|
41
|
-
if (typeof
|
|
42
|
-
const
|
|
43
|
-
if (
|
|
44
|
-
return Number(
|
|
45
|
-
if (
|
|
46
|
-
return Number(
|
|
47
|
-
if (
|
|
48
|
-
return Number(
|
|
38
|
+
function e(i, c, p, g) {
|
|
39
|
+
if (typeof p == "number")
|
|
40
|
+
return g[i].length === p;
|
|
41
|
+
if (typeof p == "object") {
|
|
42
|
+
const l = Object.keys(p)[0], y = p[l];
|
|
43
|
+
if (l === "not")
|
|
44
|
+
return Number(g[i].length) !== Number(y);
|
|
45
|
+
if (l === "moreThan")
|
|
46
|
+
return Number(g[i].length) >= Number(y);
|
|
47
|
+
if (l === "lessThan")
|
|
48
|
+
return Number(g[i].length) <= Number(y);
|
|
49
49
|
}
|
|
50
50
|
return !1;
|
|
51
51
|
}
|
|
52
|
-
function n(i,
|
|
53
|
-
return
|
|
52
|
+
function n(i, c, p, g) {
|
|
53
|
+
return g[i] && g[i].propertyValue && String(g[i].propertyValue.value) === String(p);
|
|
54
54
|
}
|
|
55
55
|
const r = /* @__PURE__ */ new Map([
|
|
56
56
|
["length", e],
|
|
57
57
|
["getProperty", n]
|
|
58
58
|
]);
|
|
59
|
-
Object.keys(t).reduce((i,
|
|
60
|
-
function o(i,
|
|
61
|
-
const
|
|
62
|
-
return typeof
|
|
63
|
-
if (
|
|
64
|
-
return { target:
|
|
65
|
-
const
|
|
66
|
-
return { target:
|
|
59
|
+
Object.keys(t).reduce((i, c) => (i.set(c, t[c]), i), r);
|
|
60
|
+
function o(i, c) {
|
|
61
|
+
const p = i;
|
|
62
|
+
return typeof c == "number" ? [{ target: p, operator: "length", param: null, value: Number(c) }] : typeof c == "boolean" ? [{ target: p, operator: "getProperty", param: i, value: !!c }] : typeof c == "object" ? Object.keys(c).map((g) => {
|
|
63
|
+
if (g === "length")
|
|
64
|
+
return { target: p, operator: "length", param: null, value: c[g] };
|
|
65
|
+
const l = g, y = c[g];
|
|
66
|
+
return { target: p, operator: "getProperty", param: l, value: y };
|
|
67
67
|
}) : [];
|
|
68
68
|
}
|
|
69
|
-
function
|
|
70
|
-
return Object.keys(i).reduce((
|
|
71
|
-
const
|
|
72
|
-
return
|
|
69
|
+
function d(i) {
|
|
70
|
+
return Object.keys(i).reduce((p, g) => {
|
|
71
|
+
const l = o(g, i[g]);
|
|
72
|
+
return p.push(...l), p;
|
|
73
73
|
}, []);
|
|
74
74
|
}
|
|
75
|
-
function
|
|
75
|
+
function u(i, c) {
|
|
76
76
|
if (r.has(i.operator)) {
|
|
77
|
-
const
|
|
78
|
-
return
|
|
77
|
+
const p = r.get(i.operator);
|
|
78
|
+
return p && p(i.target, i.param, i.value, c) || !1;
|
|
79
79
|
}
|
|
80
80
|
return !1;
|
|
81
81
|
}
|
|
82
|
-
function
|
|
83
|
-
return
|
|
82
|
+
function s(i, c) {
|
|
83
|
+
return d(i).reduce((l, y) => l && u(y, c), !0);
|
|
84
84
|
}
|
|
85
|
-
function A(i,
|
|
86
|
-
const
|
|
87
|
-
return
|
|
85
|
+
function A(i, c) {
|
|
86
|
+
const p = Object.keys(i), g = p.includes("allOf"), l = p.includes("anyOf"), y = g || l, x = (y ? i[y ? g ? "allOf" : "anyOf" : "allOf"] : [i]).map((R) => s(R, c));
|
|
87
|
+
return g ? !x.includes(!1) : x.includes(!0);
|
|
88
88
|
}
|
|
89
89
|
return { parseValueSchema: A };
|
|
90
90
|
}
|
|
@@ -128,10 +128,10 @@ const a = {
|
|
|
128
128
|
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
|
|
129
129
|
}, z = {}, K = {};
|
|
130
130
|
Z();
|
|
131
|
-
function J(t, e, n = /* @__PURE__ */ new Map(), r = (
|
|
132
|
-
return
|
|
133
|
-
const
|
|
134
|
-
return Object.assign(A,
|
|
131
|
+
function J(t, e, n = /* @__PURE__ */ new Map(), r = (u, s, A) => s, o = {}, d = (u) => u) {
|
|
132
|
+
return U[e.title] = e, O[e.title] = r, z[e.title] = o, K[e.title] = d, (u = {}) => {
|
|
133
|
+
const s = L(u, e, n), A = Object.keys(t).reduce((i, c) => (i[c] = t[c].default, i), {});
|
|
134
|
+
return Object.assign(A, s);
|
|
135
135
|
};
|
|
136
136
|
}
|
|
137
137
|
function Y(t, e, n) {
|
|
@@ -204,15 +204,20 @@ const X = /* @__PURE__ */ new Map([
|
|
|
204
204
|
}, oe = [
|
|
205
205
|
"id",
|
|
206
206
|
"type"
|
|
207
|
-
], ie =
|
|
207
|
+
], ie = [
|
|
208
|
+
"id",
|
|
209
|
+
"appearance",
|
|
210
|
+
"binding"
|
|
211
|
+
], ae = {
|
|
208
212
|
$schema: $,
|
|
209
213
|
$id: _,
|
|
210
214
|
title: ee,
|
|
211
215
|
description: te,
|
|
212
216
|
type: ne,
|
|
213
217
|
properties: re,
|
|
214
|
-
required: oe
|
|
215
|
-
|
|
218
|
+
required: oe,
|
|
219
|
+
ignore: ie
|
|
220
|
+
}, k = {
|
|
216
221
|
/**
|
|
217
222
|
* 头像宽度
|
|
218
223
|
*/
|
|
@@ -249,36 +254,36 @@ const X = /* @__PURE__ */ new Map([
|
|
|
249
254
|
* 支持的头像类型
|
|
250
255
|
*/
|
|
251
256
|
imageType: { type: Array, default: ["jpeg"] }
|
|
252
|
-
}, E = J(
|
|
257
|
+
}, E = J(k, ae, X, Y);
|
|
253
258
|
function I(t, e, n, r) {
|
|
254
|
-
const o = "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAZABkAAD/2wBDAAwICQoJBwwKCQoNDAwOER0TERAQESMZGxUdKiUsKyklKCguNEI4LjE/MigoOk46P0RHSktKLTdRV1FIVkJJSkf/2wBDAQwNDREPESITEyJHMCgwR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0f/wAARCAEsASwDASIAAhEBAxEB/8QA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AAOux212d0ttwvGdnjHr3ceMfPevo2XxbLTu3T0B1TmHJAZVOYF4p98xPviBFScQGlRZxBdS3TG3slvsibS/8WX+t/YHhx/TPGaqk4TyVQAAAAAAAAAAAAAAAAAAAAAAd+iX82c7ZL9/Nwdui/5b/rfoD00vARAQqAhfvcVNfL3A1WMqDSxmVQVNr/iz4/pv7LDOXLDLGcbNPDeDxTh6DtOjZaafFju816tlf+2Puo4Dv1bPvY+51bLvY+5RwHfq2Xex9zquXex9yjgO/Vcu9j7nVc+9j7lHAd+q597H3Oq597H3BwHfqufex9zqufex9yjgO/Vc+9j7nVc+9j7lHAd+q597H3Oq597H3KOA79Vz72PudVz72PuUcB36rl3sfc6rn3sfco4DvejZd7H3OrZd7H3KOA79Wy72PudWz72PuDg7dG/y3/W/Q6tl3sfdvY7K7PO25S6yzSdoOqWlEBmhaBamt+6J6AnmqaqDQy0CxYyoNCKC6m/VAGhPJdQBOSgKi6+QGu41QBRAF1LUABbUABNdAVOYUC0tE13gIWloCcTXeloFQLQTmffMtT74gixOa6gqysrzBVSVQVdWdQGpRNV1BV10SUlBYIvIF1E1Ne0F5iAKIAohaCmqWgBaapqC2ohqC6pqWoC2paa70tAqCACACa+F+RanyAWJ/a8vkAuqT6fVf7AVOz0X+AXVYh2egNSifx9T+wVWefyX+PqCyrqn807PQFEn0+p/YKH9H37gAc/kC6onL0P5BRP6OV8vqC2of2l/gAOSAuqan9J/AKmon9AUtL9PqnP1oCWl5ehfv5gh635nP1qWg//Z",
|
|
255
|
-
function
|
|
256
|
-
return
|
|
259
|
+
const o = "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAZABkAAD/2wBDAAwICQoJBwwKCQoNDAwOER0TERAQESMZGxUdKiUsKyklKCguNEI4LjE/MigoOk46P0RHSktKLTdRV1FIVkJJSkf/2wBDAQwNDREPESITEyJHMCgwR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0dHR0f/wAARCA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AAAAAAAAAAAAAAAAAAAAAAOux212d0ttwvGdnjHr3ceMfPevo2XxbLTu3T0B1TmHJAZVOYF4p98xPviBFScQGlRZxBdS3TG3slvsibS/8WX+t/YHhx/TPGaqk4TyVQAAAAAAAAAAAAAAAAAAAAAAd+iX82c7ZL9/Nwdui/5b/rfoD00vARAQqAhfvcVNfL3A1WMqDSxmVQVNr/iz4/pv7LDOXLDLGcbNPDeDxTh6DtOjZaafFju816tlf+2Puo4Dv1bPvY+51bLvY+5RwHfq2Xex9zquXex9yjgO/Vcu9j7nVc+9j7lHAd+q597H3Oq597H3BwHfqufex9zqufex9yjgO/Vc+9j7nVc+9j7lHAd+q597H3Oq597H3KOA79Vz72PudVz72PuUcB36rl3sfc6rn3sfco4DvejZd7H3OrZd7H3KOA79Wy72PudWz72PuDg7dG/y3/W/Q6tl3sfdvY7K7PO25S6yzSdoOqWlEBmhaBamt+6J6AnmqaqDQy0CxYyoNCKC6m/VAGhPJdQBOSgKi6+QGu41QBRAF1LUABbUABNdAVOYUC0tE13gIWloCcTXeloFQLQTmffMtT74gixOa6gqysrzBVSVQVdWdQGpRNV1BV10SUlBYIvIF1E1Ne0F5iAKIAohaCmqWgBaapqC2ohqC6pqWoC2paa70tAqCACACa+F+RanyAWJ/a8vkAuqT6fVf7AVOz0X+AXVYh2egNSifx9T+wVWefyX+PqCyrqn807PQFEn0+p/YKH9H37gAc/kC6onL0P5BRP6OV8vqC2of2l/gAOSAuqan9J/AKmon9AUtL9PqnP1oCWl5ehfv5gh635nP1qWg//Z", d = v(t.readonly);
|
|
260
|
+
function u(l) {
|
|
261
|
+
return l.match(/\.(jpeg|jpg|gif|png|svg|bmp|webp)$/) != null;
|
|
257
262
|
}
|
|
258
|
-
function
|
|
259
|
-
return
|
|
263
|
+
function s(l) {
|
|
264
|
+
return l.indexOf("data:image/") > -1;
|
|
260
265
|
}
|
|
261
|
-
function A(
|
|
262
|
-
return
|
|
266
|
+
function A(l) {
|
|
267
|
+
return l ? "data:image/jpeg;base64," + l : "";
|
|
263
268
|
}
|
|
264
269
|
const i = b(() => {
|
|
265
270
|
var y;
|
|
266
271
|
if (!t.imageType || !t.imageType.length)
|
|
267
272
|
return "";
|
|
268
|
-
const
|
|
269
|
-
return !
|
|
270
|
-
}),
|
|
271
|
-
const
|
|
272
|
-
return
|
|
273
|
-
}),
|
|
274
|
-
function
|
|
275
|
-
|
|
273
|
+
const l = (y = t.imageType) == null ? void 0 : y.map((h) => (h === "jpg" && (h = "jpeg"), `image/${h}`));
|
|
274
|
+
return !l || !l.length ? "image/*" : l.join(",");
|
|
275
|
+
}), c = b(() => {
|
|
276
|
+
const l = r.value || t.cover || o;
|
|
277
|
+
return u(l) || s(l) ? l : A(l);
|
|
278
|
+
}), p = b(() => d.value ? "" : t.title);
|
|
279
|
+
function g() {
|
|
280
|
+
d.value || n && n.value && n.value.click();
|
|
276
281
|
}
|
|
277
|
-
return { acceptTypes: i, imageSource:
|
|
282
|
+
return { acceptTypes: i, imageSource: c, imageTitle: p, onClickImage: g };
|
|
278
283
|
}
|
|
279
284
|
const B = /* @__PURE__ */ F({
|
|
280
285
|
name: "FAvatar",
|
|
281
|
-
props:
|
|
286
|
+
props: k,
|
|
282
287
|
emits: ["change", "update:modelValue"],
|
|
283
288
|
setup(t, e) {
|
|
284
289
|
const n = b(() => ({
|
|
@@ -289,26 +294,26 @@ const B = /* @__PURE__ */ F({
|
|
|
289
294
|
})), r = v(t.modelValue), o = b(() => ({
|
|
290
295
|
width: t.avatarWidth + "px",
|
|
291
296
|
height: t.avatarHeight + "px"
|
|
292
|
-
})),
|
|
293
|
-
function
|
|
297
|
+
})), d = !1;
|
|
298
|
+
function u() {
|
|
294
299
|
return "";
|
|
295
300
|
}
|
|
296
|
-
function
|
|
301
|
+
function s() {
|
|
297
302
|
}
|
|
298
303
|
const A = v(null), {
|
|
299
304
|
acceptTypes: i,
|
|
300
|
-
imageSource:
|
|
301
|
-
onClickImage:
|
|
305
|
+
imageSource: c,
|
|
306
|
+
onClickImage: p
|
|
302
307
|
} = I(t, e, A, r);
|
|
303
308
|
return () => f("div", {
|
|
304
309
|
class: n.value,
|
|
305
310
|
style: o.value,
|
|
306
|
-
onClick:
|
|
307
|
-
}, [
|
|
311
|
+
onClick: p
|
|
312
|
+
}, [d, f("img", {
|
|
308
313
|
title: t.title,
|
|
309
314
|
class: "f-avatar-image",
|
|
310
|
-
src:
|
|
311
|
-
onError:
|
|
315
|
+
src: c.value,
|
|
316
|
+
onError: u
|
|
312
317
|
}, null), !t.readonly && f("div", {
|
|
313
318
|
class: "f-avatar-icon"
|
|
314
319
|
}, [f("span", {
|
|
@@ -319,46 +324,46 @@ const B = /* @__PURE__ */ F({
|
|
|
319
324
|
type: "file",
|
|
320
325
|
class: "f-avatar-upload",
|
|
321
326
|
accept: i.value,
|
|
322
|
-
onChange:
|
|
327
|
+
onChange: s,
|
|
323
328
|
style: "display: none;"
|
|
324
329
|
}, null)]);
|
|
325
330
|
}
|
|
326
331
|
});
|
|
327
|
-
function
|
|
332
|
+
function se(t, e) {
|
|
328
333
|
t.schema;
|
|
329
334
|
const n = v(!0), r = v(!0);
|
|
330
|
-
function o(
|
|
335
|
+
function o(p) {
|
|
331
336
|
return !1;
|
|
332
337
|
}
|
|
333
|
-
function
|
|
338
|
+
function d() {
|
|
334
339
|
return !1;
|
|
335
340
|
}
|
|
336
|
-
function
|
|
341
|
+
function u() {
|
|
337
342
|
return !1;
|
|
338
343
|
}
|
|
339
|
-
function
|
|
344
|
+
function s() {
|
|
340
345
|
return !0;
|
|
341
346
|
}
|
|
342
|
-
function A(
|
|
347
|
+
function A(p) {
|
|
343
348
|
}
|
|
344
349
|
function i() {
|
|
345
350
|
}
|
|
346
|
-
function
|
|
351
|
+
function c(p) {
|
|
347
352
|
return null;
|
|
348
353
|
}
|
|
349
354
|
return {
|
|
350
355
|
canAccepts: o,
|
|
351
|
-
checkCanDeleteComponent:
|
|
352
|
-
checkCanMoveComponent:
|
|
353
|
-
hideNestedPaddingInDesginerView:
|
|
356
|
+
checkCanDeleteComponent: d,
|
|
357
|
+
checkCanMoveComponent: u,
|
|
358
|
+
hideNestedPaddingInDesginerView: s,
|
|
354
359
|
onAcceptMovedChildElement: A,
|
|
355
360
|
resolveComponentContext: i,
|
|
356
361
|
triggerBelongedComponentToMoveWhenMoved: n,
|
|
357
362
|
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
358
|
-
getPropsConfig:
|
|
363
|
+
getPropsConfig: c
|
|
359
364
|
};
|
|
360
365
|
}
|
|
361
|
-
class
|
|
366
|
+
class le {
|
|
362
367
|
constructor(e, n) {
|
|
363
368
|
m(this, "componentId");
|
|
364
369
|
m(this, "viewModelId");
|
|
@@ -510,8 +515,8 @@ m(C, "fieldControlTypeMapping", {
|
|
|
510
515
|
]
|
|
511
516
|
});
|
|
512
517
|
let T = C;
|
|
513
|
-
const
|
|
514
|
-
class
|
|
518
|
+
const ce = v(0);
|
|
519
|
+
class pe extends le {
|
|
515
520
|
constructor(e, n) {
|
|
516
521
|
super(e, n);
|
|
517
522
|
}
|
|
@@ -519,10 +524,10 @@ class ce extends se {
|
|
|
519
524
|
return this.propertyConfig.categories.basic = this.getBasicProperties(e, n), this.propertyConfig.categories.appearance = this.getAppearanceProperties(e), this.propertyConfig.categories.editor = this.getEditorProperties(e), this.propertyConfig;
|
|
520
525
|
}
|
|
521
526
|
getBasicProperties(e, n) {
|
|
522
|
-
var
|
|
527
|
+
var u;
|
|
523
528
|
var r = this;
|
|
524
529
|
this.setDesignViewModelField(e);
|
|
525
|
-
const o = this.formSchemaUtils.getFormMetadataBasicInfo(),
|
|
530
|
+
const o = this.formSchemaUtils.getFormMetadataBasicInfo(), d = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
526
531
|
return {
|
|
527
532
|
description: "Basic Information",
|
|
528
533
|
title: "基本信息",
|
|
@@ -534,8 +539,8 @@ class ce extends se {
|
|
|
534
539
|
readonly: !0
|
|
535
540
|
},
|
|
536
541
|
type: {
|
|
537
|
-
description: "
|
|
538
|
-
title: "
|
|
542
|
+
description: "编辑器类型",
|
|
543
|
+
title: "编辑器类型",
|
|
539
544
|
type: "string",
|
|
540
545
|
refreshPanelAfterChanged: !0,
|
|
541
546
|
$converter: "/converter/change-editor.converter",
|
|
@@ -544,7 +549,7 @@ class ce extends se {
|
|
|
544
549
|
textField: "value",
|
|
545
550
|
valueField: "key",
|
|
546
551
|
editable: !1,
|
|
547
|
-
data: r.designViewModelField ? T.getEditorTypesByMDataType((
|
|
552
|
+
data: r.designViewModelField ? T.getEditorTypesByMDataType((u = r.designViewModelField.type) == null ? void 0 : u.name) : T.getAllInputTypes()
|
|
548
553
|
}
|
|
549
554
|
},
|
|
550
555
|
label: {
|
|
@@ -569,15 +574,19 @@ class ce extends se {
|
|
|
569
574
|
{ field: "fieldType", title: "字段类型" }
|
|
570
575
|
],
|
|
571
576
|
textField: "bindingField",
|
|
572
|
-
data:
|
|
577
|
+
data: d
|
|
573
578
|
}
|
|
574
579
|
}
|
|
575
580
|
},
|
|
576
|
-
setPropertyRelates(
|
|
577
|
-
if (
|
|
578
|
-
switch (
|
|
581
|
+
setPropertyRelates(s, A) {
|
|
582
|
+
if (s)
|
|
583
|
+
switch (s && s.propertyID) {
|
|
579
584
|
case "type": {
|
|
580
|
-
r.changeControlType(e,
|
|
585
|
+
r.changeControlType(e, s, n);
|
|
586
|
+
break;
|
|
587
|
+
}
|
|
588
|
+
case "label": {
|
|
589
|
+
s.needRefreshControlTree = !0;
|
|
581
590
|
break;
|
|
582
591
|
}
|
|
583
592
|
}
|
|
@@ -623,11 +632,11 @@ class ce extends se {
|
|
|
623
632
|
* @param newControlType 新控件类型
|
|
624
633
|
*/
|
|
625
634
|
changeControlType(e, n, r) {
|
|
626
|
-
var i,
|
|
627
|
-
const o = n.propertyValue,
|
|
628
|
-
if (!
|
|
635
|
+
var i, c, p, g;
|
|
636
|
+
const o = n.propertyValue, d = r && r.parent && r.parent.schema;
|
|
637
|
+
if (!d)
|
|
629
638
|
return;
|
|
630
|
-
const
|
|
639
|
+
const u = d.contents.findIndex((l) => l.id === e.id), s = d.contents[u];
|
|
631
640
|
let A;
|
|
632
641
|
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
633
642
|
editor: {
|
|
@@ -637,29 +646,29 @@ class ce extends se {
|
|
|
637
646
|
require: this.designViewModelField.require,
|
|
638
647
|
readonly: this.designViewModelField.readonly
|
|
639
648
|
}, !1), A = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, o)), A || (A = M("form-group") || {}, A.editor = M(o) || {}, delete A.editor.id, delete A.editor.binding, delete A.editor.appearance), Object.assign(A, {
|
|
640
|
-
id:
|
|
641
|
-
appearance:
|
|
642
|
-
size:
|
|
643
|
-
label:
|
|
644
|
-
binding:
|
|
645
|
-
visible:
|
|
649
|
+
id: s.id,
|
|
650
|
+
appearance: s.appearance,
|
|
651
|
+
size: s.size,
|
|
652
|
+
label: s.label,
|
|
653
|
+
binding: s.binding,
|
|
654
|
+
visible: s.visible
|
|
646
655
|
}), Object.assign(A.editor, {
|
|
647
|
-
isTextArea: A.isTextArea &&
|
|
648
|
-
placeholder: (i =
|
|
649
|
-
holdPlace: (
|
|
650
|
-
readonly: (
|
|
651
|
-
require: (
|
|
652
|
-
}),
|
|
653
|
-
(
|
|
654
|
-
),
|
|
656
|
+
isTextArea: A.isTextArea && s.isTextArea,
|
|
657
|
+
placeholder: (i = s.editor) == null ? void 0 : i.placeholder,
|
|
658
|
+
holdPlace: (c = s.editor) == null ? void 0 : c.holdPlace,
|
|
659
|
+
readonly: (p = s.editor) == null ? void 0 : p.readonly,
|
|
660
|
+
require: (g = s.editor) == null ? void 0 : g.require
|
|
661
|
+
}), d.contents.splice(u, 1), d.contents.splice(u, 0, A), r.schema = Object.assign(s, A), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
662
|
+
(l) => l.classList.remove("dgComponentSelected")
|
|
663
|
+
), ce.value++;
|
|
655
664
|
}
|
|
656
665
|
getComponentConfig(e, n = {}, r = {}) {
|
|
657
666
|
const o = Object.assign({
|
|
658
|
-
description: "
|
|
659
|
-
title: "
|
|
667
|
+
description: "编辑器",
|
|
668
|
+
title: "编辑器",
|
|
660
669
|
type: "input-group",
|
|
661
670
|
$converter: "/converter/property-editor.converter"
|
|
662
|
-
}, n),
|
|
671
|
+
}, n), d = Object.assign({
|
|
663
672
|
readonly: {
|
|
664
673
|
description: "",
|
|
665
674
|
title: "只读",
|
|
@@ -681,17 +690,17 @@ class ce extends se {
|
|
|
681
690
|
type: "string"
|
|
682
691
|
}
|
|
683
692
|
}, r);
|
|
684
|
-
return { ...o, properties: { ...
|
|
693
|
+
return { ...o, properties: { ...d } };
|
|
685
694
|
}
|
|
686
695
|
}
|
|
687
|
-
class
|
|
696
|
+
class de extends pe {
|
|
688
697
|
constructor(e, n) {
|
|
689
698
|
super(e, n);
|
|
690
699
|
}
|
|
691
700
|
getEditorProperties(e) {
|
|
692
701
|
return {
|
|
693
|
-
description: "
|
|
694
|
-
title: "
|
|
702
|
+
description: "编辑器",
|
|
703
|
+
title: "编辑器",
|
|
695
704
|
type: "avatar",
|
|
696
705
|
$converter: "/converter/property-editor.converter",
|
|
697
706
|
properties: {
|
|
@@ -719,42 +728,42 @@ class pe extends ce {
|
|
|
719
728
|
};
|
|
720
729
|
}
|
|
721
730
|
}
|
|
722
|
-
function
|
|
731
|
+
function ue(t, e) {
|
|
723
732
|
const {
|
|
724
733
|
canAccepts: n,
|
|
725
734
|
checkCanDeleteComponent: r,
|
|
726
735
|
checkCanMoveComponent: o,
|
|
727
|
-
hideNestedPaddingInDesginerView:
|
|
728
|
-
onAcceptMovedChildElement:
|
|
729
|
-
resolveComponentContext:
|
|
736
|
+
hideNestedPaddingInDesginerView: d,
|
|
737
|
+
onAcceptMovedChildElement: u,
|
|
738
|
+
resolveComponentContext: s,
|
|
730
739
|
triggerBelongedComponentToMoveWhenMoved: A,
|
|
731
740
|
triggerBelongedComponentToDeleteWhenDeleted: i
|
|
732
|
-
} =
|
|
733
|
-
function
|
|
734
|
-
return new
|
|
741
|
+
} = se(t), c = t.schema;
|
|
742
|
+
function p(g, l) {
|
|
743
|
+
return new de(g, e).getPropertyConfig(c, l);
|
|
735
744
|
}
|
|
736
745
|
return {
|
|
737
746
|
canAccepts: n,
|
|
738
747
|
checkCanDeleteComponent: r,
|
|
739
748
|
checkCanMoveComponent: o,
|
|
740
|
-
hideNestedPaddingInDesginerView:
|
|
741
|
-
onAcceptMovedChildElement:
|
|
742
|
-
resolveComponentContext:
|
|
749
|
+
hideNestedPaddingInDesginerView: d,
|
|
750
|
+
onAcceptMovedChildElement: u,
|
|
751
|
+
resolveComponentContext: s,
|
|
743
752
|
triggerBelongedComponentToMoveWhenMoved: A,
|
|
744
753
|
triggerBelongedComponentToDeleteWhenDeleted: i,
|
|
745
|
-
getPropsConfig:
|
|
754
|
+
getPropsConfig: p
|
|
746
755
|
};
|
|
747
756
|
}
|
|
748
|
-
const
|
|
757
|
+
const Ae = /* @__PURE__ */ F({
|
|
749
758
|
name: "FAvatarDesign",
|
|
750
|
-
props:
|
|
759
|
+
props: k,
|
|
751
760
|
emits: ["change", "update:modelValue"],
|
|
752
761
|
setup(t, e) {
|
|
753
|
-
const n = v(), r = P("designer-host-service"), o = P("design-item-context"),
|
|
762
|
+
const n = v(), r = P("designer-host-service"), o = P("design-item-context"), d = ue(o, r), u = Q(n, o, d);
|
|
754
763
|
H(() => {
|
|
755
|
-
n.value.componentInstance =
|
|
756
|
-
}), e.expose(
|
|
757
|
-
const
|
|
764
|
+
n.value.componentInstance = u;
|
|
765
|
+
}), e.expose(u.value);
|
|
766
|
+
const s = b(() => ({
|
|
758
767
|
"f-avatar": !0,
|
|
759
768
|
"f-avatar-readonly": t.readonly,
|
|
760
769
|
"f-avatar-circle": t.shape === "circle",
|
|
@@ -762,27 +771,27 @@ const ue = /* @__PURE__ */ F({
|
|
|
762
771
|
})), A = v(t.modelValue), i = b(() => ({
|
|
763
772
|
width: t.avatarWidth + "px",
|
|
764
773
|
height: t.avatarHeight + "px"
|
|
765
|
-
})),
|
|
766
|
-
function
|
|
774
|
+
})), c = !1;
|
|
775
|
+
function p() {
|
|
767
776
|
return "";
|
|
768
777
|
}
|
|
769
|
-
function
|
|
778
|
+
function g() {
|
|
770
779
|
}
|
|
771
|
-
const
|
|
780
|
+
const l = v(null), {
|
|
772
781
|
acceptTypes: y,
|
|
773
782
|
imageSource: h,
|
|
774
|
-
onClickImage:
|
|
775
|
-
} = I(t, e,
|
|
783
|
+
onClickImage: w
|
|
784
|
+
} = I(t, e, l, A);
|
|
776
785
|
return () => f("div", {
|
|
777
786
|
ref: n,
|
|
778
|
-
class:
|
|
787
|
+
class: s.value,
|
|
779
788
|
style: i.value,
|
|
780
|
-
onClick:
|
|
781
|
-
}, [
|
|
789
|
+
onClick: w
|
|
790
|
+
}, [c, f("img", {
|
|
782
791
|
title: t.title,
|
|
783
792
|
class: "f-avatar-image",
|
|
784
793
|
src: h.value,
|
|
785
|
-
onError:
|
|
794
|
+
onError: p
|
|
786
795
|
}, null), !t.readonly && f("div", {
|
|
787
796
|
class: "f-avatar-icon"
|
|
788
797
|
}, [f("span", {
|
|
@@ -793,7 +802,7 @@ const ue = /* @__PURE__ */ F({
|
|
|
793
802
|
type: "file",
|
|
794
803
|
class: "f-avatar-upload",
|
|
795
804
|
accept: y.value,
|
|
796
|
-
onChange:
|
|
805
|
+
onChange: g,
|
|
797
806
|
style: "display: none;"
|
|
798
807
|
}, null)]);
|
|
799
808
|
}
|
|
@@ -802,12 +811,12 @@ B.register = (t, e, n, r) => {
|
|
|
802
811
|
t.avatar = B, e.avatar = E;
|
|
803
812
|
};
|
|
804
813
|
B.registerDesigner = (t, e, n) => {
|
|
805
|
-
t.avatar =
|
|
814
|
+
t.avatar = Ae, e.avatar = E;
|
|
806
815
|
};
|
|
807
|
-
const
|
|
816
|
+
const Ce = q(B);
|
|
808
817
|
export {
|
|
809
818
|
B as FAvatar,
|
|
810
|
-
|
|
811
|
-
|
|
819
|
+
k as avatarProps,
|
|
820
|
+
Ce as default,
|
|
812
821
|
E as propsResolver
|
|
813
822
|
};
|