@farris/ui-vue 1.2.6 → 1.2.8
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 +150 -142
- package/components/avatar/index.esm.js +393 -457
- package/components/border-editor/index.esm.js +4 -4
- package/components/button/index.esm.js +1 -1
- package/components/button-edit/index.esm.js +353 -444
- package/components/button-group/index.esm.js +5 -5
- package/components/calendar/index.esm.js +176 -176
- package/components/capsule/index.esm.js +93 -93
- package/components/checkbox/index.esm.js +491 -554
- package/components/color-picker/index.esm.js +1 -1
- package/components/combo-list/index.esm.js +479 -513
- package/components/combo-tree/index.esm.js +8 -8
- package/components/component/index.esm.js +89 -89
- package/components/condition/index.esm.js +857 -743
- package/components/content-container/index.esm.js +61 -61
- package/components/data-grid/index.esm.js +4883 -5182
- package/components/data-view/index.esm.js +3072 -2949
- package/components/date-picker/index.esm.js +2626 -2689
- package/components/dependent-base/style.js +1 -0
- package/components/dependent-fluid/style.js +1 -0
- package/components/dependent-icon/style.js +1 -0
- package/components/dependent-input/style.js +1 -0
- package/components/dependent-table/style.js +1 -0
- package/components/designer-canvas/index.esm.js +478 -475
- package/components/designer-outline/index.esm.js +173 -131
- package/components/discussion-editor/index.esm.js +1 -1
- package/components/dropdown/index.esm.js +73 -73
- package/components/dynamic-form/index.esm.js +940 -998
- package/components/dynamic-resolver/index.esm.js +67 -35
- package/components/dynamic-view/index.esm.js +307 -293
- package/components/enum-editor/index.esm.js +3 -3
- package/components/events-editor/index.esm.js +178 -178
- package/components/expression-editor/index.esm.js +105 -105
- package/components/external-container/index.esm.js +1747 -1627
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5877 -6176
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1454 -1524
- package/components/flow-canvas/index.esm.js +678 -675
- package/components/image-cropper/index.esm.js +266 -266
- package/components/input-group/index.esm.js +659 -722
- package/components/layout/index.esm.js +148 -148
- package/components/list-nav/index.esm.js +109 -109
- package/components/list-view/index.esm.js +1643 -1524
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +6502 -6770
- package/components/mapping-editor/index.esm.js +5639 -5939
- package/components/message-box/index.esm.js +1 -1
- package/components/modal/index.esm.js +1 -1
- package/components/nav/index.esm.js +86 -86
- package/components/number-range/index.esm.js +1120 -0
- package/components/number-range/package.json +8 -0
- package/components/number-range/style.js +6 -0
- package/components/number-spinner/index.esm.js +1146 -0
- package/components/number-spinner/package.json +8 -0
- package/components/number-spinner/style.js +4 -0
- package/components/order/index.esm.js +1098 -1130
- package/components/page-footer/index.esm.js +106 -106
- package/components/page-header/index.esm.js +1088 -1317
- package/components/pagination/index.esm.js +252 -252
- package/components/progress/index.esm.js +37 -37
- package/components/property-editor/index.esm.js +1479 -1513
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +706 -778
- package/components/query-solution/index.css +1 -0
- package/components/query-solution/index.esm.js +6935 -0
- package/components/query-solution/package.json +8 -0
- package/components/query-solution/style.js +2 -0
- package/components/radio-button/index.esm.js +64 -64
- package/components/radio-group/index.esm.js +453 -516
- package/components/rate/index.esm.js +92 -92
- package/components/response-layout/index.esm.js +33 -33
- package/components/response-layout-editor/index.esm.js +555 -526
- package/components/response-toolbar/index.esm.js +1009 -1247
- package/components/schema-selector/index.esm.js +3261 -3373
- package/components/search-box/index.esm.js +143 -143
- package/components/section/index.esm.js +209 -209
- package/components/smoke-detector/index.esm.js +22 -22
- package/components/spacing-editor/index.esm.js +2 -2
- package/components/splitter/index.esm.js +1097 -394
- package/components/step/index.esm.js +153 -153
- package/components/switch/index.esm.js +441 -504
- package/components/tabs/index.esm.js +1849 -2039
- package/components/tags/index.esm.js +215 -215
- package/components/text/index.esm.js +53 -53
- package/components/textarea/index.esm.js +445 -493
- package/components/time-picker/index.esm.js +1350 -1414
- package/components/transfer/index.esm.js +146 -144
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5948 -6237
- package/components/tree-view/index.esm.js +2381 -2255
- package/components/uploader/index.esm.js +1 -1
- package/components/verify-detail/index.esm.js +232 -232
- package/components/video/index.esm.js +136 -136
- package/components/weather/index.esm.js +2 -2
- package/farris.all.esm.js +27221 -26804
- package/farris.all.umd.cjs +9 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/checkbox/index.d.ts +1 -0
- package/types/combo-list/src/components/list-container.component.d.ts +6 -0
- package/types/combo-list/src/components/list-container.props.d.ts +9 -1
- package/types/data-grid/src/data-grid.props.d.ts +1 -0
- package/types/data-grid/src/designer/column-header.design.component.d.ts +1 -1
- package/types/data-grid/src/designer/data-grid-column.props.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +1 -1
- package/types/designer-canvas/src/composition/dg-control.d.ts +16 -350
- package/types/designer-canvas/src/types.d.ts +1 -1
- package/types/dynamic-form/index.d.ts +1 -0
- package/types/dynamic-form/src/types.d.ts +1 -1
- package/types/dynamic-resolver/index.d.ts +1 -0
- package/types/dynamic-resolver/src/binding-resolver.d.ts +1 -0
- package/types/dynamic-view/src/dynamic-view.component.d.ts +1 -1
- package/types/lookup/src/property-config/converters/lookup-property.converter.d.ts +0 -4
- package/types/lookup/src/property-config/lookup.property-config.d.ts +4 -3
- package/types/modal/src/modal.props.d.ts +1 -4
- package/types/property-panel/src/composition/entity/base-property.d.ts +0 -28
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +11 -5
- package/types/property-panel/src/composition/entity/schema-dom-mapping.d.ts +10 -8
- package/types/tabs/src/designer/tab-toolbar-item.props.d.ts +19 -0
- package/types/tabs/src/property-config/tabs.property-config.d.ts +6 -6
- package/types/tree-grid/src/designer/use-designer-rules.d.ts +3 -0
- package/types/tree-grid/src/property-config/tree-grid.property-config.d.ts +11 -0
- package/types/tree-grid/src/schema/column-resolver.d.ts +1 -1
- package/types/tree-grid/src/tree-grid.props.d.ts +8 -0
- package/components/accordion/index.umd.cjs +0 -1
- package/components/avatar/index.umd.cjs +0 -1
- package/components/border-editor/index.umd.cjs +0 -1
- package/components/button/index.umd.cjs +0 -1
- package/components/button-edit/index.umd.cjs +0 -1
- package/components/button-group/index.umd.cjs +0 -1
- package/components/calculator/index.umd.cjs +0 -1
- package/components/calendar/index.umd.cjs +0 -1
- package/components/capsule/index.umd.cjs +0 -1
- package/components/checkbox/index.umd.cjs +0 -1
- package/components/color-picker/index.umd.cjs +0 -3
- package/components/combo-list/index.umd.cjs +0 -1
- package/components/combo-tree/index.umd.cjs +0 -1
- package/components/common/index.umd.cjs +0 -1
- package/components/component/index.umd.cjs +0 -1
- package/components/condition/index.umd.cjs +0 -1
- package/components/content-container/index.umd.cjs +0 -1
- package/components/data-grid/index.umd.cjs +0 -1
- package/components/data-view/index.umd.cjs +0 -1
- package/components/date-picker/index.umd.cjs +0 -1
- package/components/designer-canvas/index.umd.cjs +0 -1
- package/components/designer-outline/index.umd.cjs +0 -1
- package/components/designer-toolbox/index.umd.cjs +0 -1
- package/components/discussion-editor/index.umd.cjs +0 -3
- package/components/discussion-list/index.umd.cjs +0 -1
- package/components/drawer/index.umd.cjs +0 -1
- package/components/dropdown/index.umd.cjs +0 -2
- package/components/dynamic-form/index.umd.cjs +0 -1
- package/components/dynamic-resolver/index.umd.cjs +0 -1
- package/components/dynamic-view/index.umd.cjs +0 -1
- package/components/enum-editor/index.umd.cjs +0 -1
- package/components/events-editor/index.umd.cjs +0 -1
- package/components/expression-editor/index.umd.cjs +0 -1
- package/components/external-container/index.umd.cjs +0 -1
- package/components/field-selector/index.umd.cjs +0 -1
- package/components/filter-bar/index.umd.cjs +0 -1
- package/components/flow-canvas/index.umd.cjs +0 -1
- package/components/image-cropper/index.umd.cjs +0 -1
- package/components/input-group/index.umd.cjs +0 -1
- package/components/layout/index.umd.cjs +0 -1
- package/components/list-nav/index.umd.cjs +0 -1
- package/components/list-view/index.umd.cjs +0 -1
- package/components/loading/index.umd.cjs +0 -8
- package/components/locale/index.umd.cjs +0 -1
- package/components/lookup/index.umd.cjs +0 -1
- package/components/mapping-editor/index.umd.cjs +0 -1
- package/components/message-box/index.umd.cjs +0 -1
- package/components/modal/index.umd.cjs +0 -1
- package/components/nav/index.umd.cjs +0 -3
- package/components/notify/index.umd.cjs +0 -1
- package/components/order/index.umd.cjs +0 -1
- package/components/page-footer/index.umd.cjs +0 -1
- package/components/page-header/index.umd.cjs +0 -1
- package/components/pagination/index.umd.cjs +0 -1
- package/components/popover/index.umd.cjs +0 -1
- package/components/progress/index.umd.cjs +0 -3
- package/components/property-editor/index.umd.cjs +0 -3
- package/components/property-panel/index.umd.cjs +0 -1
- package/components/radio-button/index.umd.cjs +0 -1
- package/components/radio-group/index.umd.cjs +0 -1
- package/components/rate/index.umd.cjs +0 -1
- package/components/response-layout/index.umd.cjs +0 -1
- package/components/response-layout-editor/index.umd.cjs +0 -1
- package/components/response-toolbar/index.umd.cjs +0 -1
- package/components/schema-selector/index.umd.cjs +0 -8
- package/components/search-box/index.umd.cjs +0 -1
- package/components/section/index.umd.cjs +0 -1
- package/components/smoke-detector/index.umd.cjs +0 -1
- package/components/spacing-editor/index.umd.cjs +0 -1
- package/components/splitter/index.umd.cjs +0 -1
- package/components/step/index.umd.cjs +0 -1
- package/components/switch/index.umd.cjs +0 -1
- package/components/tabs/index.umd.cjs +0 -1
- package/components/tags/index.umd.cjs +0 -1
- package/components/text/index.umd.cjs +0 -1
- package/components/textarea/index.umd.cjs +0 -1
- package/components/time-picker/index.umd.cjs +0 -1
- package/components/tooltip/index.umd.cjs +0 -1
- package/components/transfer/index.umd.cjs +0 -1
- package/components/tree-grid/index.umd.cjs +0 -1
- package/components/tree-view/index.umd.cjs +0 -1
- package/components/uploader/index.umd.cjs +0 -2
- package/components/verify-detail/index.umd.cjs +0 -1
- package/components/video/index.umd.cjs +0 -1
- package/components/weather/index.umd.cjs +0 -16
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var C = (n, e, t) =>
|
|
4
|
-
import { defineComponent as
|
|
5
|
-
import { useCheck as
|
|
6
|
-
import { cloneDeep as
|
|
7
|
-
|
|
1
|
+
var R = Object.defineProperty;
|
|
2
|
+
var H = (n, e, t) => e in n ? R(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
|
|
3
|
+
var C = (n, e, t) => H(n, typeof e != "symbol" ? e + "" : e, t);
|
|
4
|
+
import { defineComponent as O, inject as A, onMounted as W, createVNode as h, Fragment as I, computed as S, ref as k, provide as K } from "vue";
|
|
5
|
+
import { useCheck as ee } from "../common/index.esm.js";
|
|
6
|
+
import { cloneDeep as te } from "lodash-es";
|
|
7
|
+
import { getSchemaByType as q } from "../dynamic-resolver/index.esm.js";
|
|
8
|
+
const ne = {
|
|
8
9
|
value: { type: String, default: "" },
|
|
9
10
|
/** 值 */
|
|
10
11
|
modelValue: { type: String, default: "" },
|
|
@@ -14,39 +15,39 @@ const ee = {
|
|
|
14
15
|
label: { type: String, default: "" },
|
|
15
16
|
/** 标识 */
|
|
16
17
|
id: { type: String, default: "" }
|
|
17
|
-
},
|
|
18
|
+
}, x = Symbol("radioGroupContext"), L = /* @__PURE__ */ O({
|
|
18
19
|
name: "FRadio",
|
|
19
|
-
props:
|
|
20
|
+
props: ne,
|
|
20
21
|
emits: ["update:value"],
|
|
21
22
|
setup(n, e) {
|
|
22
|
-
const t =
|
|
23
|
+
const t = A(x, null), {
|
|
23
24
|
buttonClass: o,
|
|
24
|
-
checked:
|
|
25
|
-
disabled:
|
|
25
|
+
checked: i,
|
|
26
|
+
disabled: s,
|
|
26
27
|
name: m,
|
|
27
|
-
tagClass:
|
|
28
|
-
shouldRenderButton:
|
|
29
|
-
shouldRenderNative:
|
|
28
|
+
tagClass: u,
|
|
29
|
+
shouldRenderButton: p,
|
|
30
|
+
shouldRenderNative: r,
|
|
30
31
|
shouldRenderTag: l,
|
|
31
32
|
onClickRadio: c
|
|
32
|
-
} =
|
|
33
|
-
return
|
|
33
|
+
} = ee(n, e, t == null ? void 0 : t.parentProps, t == null ? void 0 : t.parentContext);
|
|
34
|
+
return W(() => {
|
|
34
35
|
}), () => {
|
|
35
|
-
var
|
|
36
|
-
return h(
|
|
36
|
+
var d, f, g, M, T, w;
|
|
37
|
+
return h(I, null, [p.value && h("div", {
|
|
37
38
|
class: o.value,
|
|
38
39
|
style: "border-radius:0;border: 1px solid #E8EBF2;",
|
|
39
40
|
onClick: c
|
|
40
|
-
}, [(
|
|
41
|
-
class:
|
|
41
|
+
}, [(f = (d = e.slots).default) == null ? void 0 : f.call(d)]), l.value && h("div", {
|
|
42
|
+
class: u.value,
|
|
42
43
|
onClick: c
|
|
43
44
|
}, [h("div", {
|
|
44
45
|
class: "title"
|
|
45
|
-
}, [(
|
|
46
|
+
}, [(M = (g = e.slots).default) == null ? void 0 : M.call(g)]), h("div", {
|
|
46
47
|
class: "tip"
|
|
47
48
|
}, null), h("span", {
|
|
48
49
|
class: "f-icon f-icon-check f-radio-icon"
|
|
49
|
-
}, null)]),
|
|
50
|
+
}, null)]), r.value && h("div", {
|
|
50
51
|
class: "custom-control custom-radio",
|
|
51
52
|
onClick: c
|
|
52
53
|
}, [h("input", {
|
|
@@ -55,115 +56,113 @@ const ee = {
|
|
|
55
56
|
name: m.value,
|
|
56
57
|
id: n.id,
|
|
57
58
|
value: n.value,
|
|
58
|
-
checked:
|
|
59
|
-
disabled:
|
|
59
|
+
checked: i.value,
|
|
60
|
+
disabled: s.value
|
|
60
61
|
}, null), h("div", {
|
|
61
62
|
class: "custom-control-label"
|
|
62
|
-
}, [(
|
|
63
|
+
}, [(w = (T = e.slots).default) == null ? void 0 : w.call(T)])])]);
|
|
63
64
|
};
|
|
64
65
|
}
|
|
65
66
|
});
|
|
66
|
-
function
|
|
67
|
+
function oe(n, e, t) {
|
|
67
68
|
return e;
|
|
68
69
|
}
|
|
69
|
-
const
|
|
70
|
-
function
|
|
71
|
-
const { properties: e, title: t } = n, o = Object.keys(e).reduce((
|
|
70
|
+
const _ = {}, J = {};
|
|
71
|
+
function $(n) {
|
|
72
|
+
const { properties: e, title: t } = n, o = Object.keys(e).reduce((i, s) => (i[s] = e[s].type === "object" && e[s].properties ? $(e[s]) : te(e[s].default), i), {});
|
|
72
73
|
return o.id = `${t}-${Date.now()}`, o;
|
|
73
74
|
}
|
|
74
|
-
function
|
|
75
|
-
const t =
|
|
75
|
+
function N(n, e = {}) {
|
|
76
|
+
const t = _[n];
|
|
76
77
|
if (t) {
|
|
77
|
-
let o =
|
|
78
|
-
const
|
|
79
|
-
return o =
|
|
78
|
+
let o = $(t);
|
|
79
|
+
const i = J[n];
|
|
80
|
+
return o = i ? i({ getSchemaByType: N }, o, e) : o, o;
|
|
80
81
|
}
|
|
81
82
|
return null;
|
|
82
83
|
}
|
|
83
|
-
function
|
|
84
|
-
const t =
|
|
85
|
-
return Object.keys(n).reduce((o,
|
|
84
|
+
function re(n, e) {
|
|
85
|
+
const t = $(e);
|
|
86
|
+
return Object.keys(n).reduce((o, i) => (o[i] && typeof o[i] == "object" ? Object.assign(o[i], n[i]) : o[i] = n[i], o), t), t;
|
|
86
87
|
}
|
|
87
|
-
function
|
|
88
|
-
return Object.keys(n).filter((o) => n[o] != null).reduce((o,
|
|
89
|
-
if (e.has(
|
|
90
|
-
const
|
|
91
|
-
if (typeof
|
|
92
|
-
o[
|
|
88
|
+
function ie(n, e) {
|
|
89
|
+
return Object.keys(n).filter((o) => n[o] != null).reduce((o, i) => {
|
|
90
|
+
if (e.has(i)) {
|
|
91
|
+
const s = e.get(i);
|
|
92
|
+
if (typeof s == "string")
|
|
93
|
+
o[s] = n[i];
|
|
93
94
|
else {
|
|
94
|
-
const m =
|
|
95
|
+
const m = s(i, n[i], n);
|
|
95
96
|
Object.assign(o, m);
|
|
96
97
|
}
|
|
97
98
|
} else
|
|
98
|
-
o[
|
|
99
|
+
o[i] = n[i];
|
|
99
100
|
return o;
|
|
100
101
|
}, {});
|
|
101
102
|
}
|
|
102
103
|
function ae(n, e, t = /* @__PURE__ */ new Map()) {
|
|
103
|
-
const o =
|
|
104
|
-
return
|
|
104
|
+
const o = re(n, e);
|
|
105
|
+
return ie(o, t);
|
|
105
106
|
}
|
|
106
|
-
function
|
|
107
|
-
function e(
|
|
107
|
+
function le(n = {}) {
|
|
108
|
+
function e(r, l, c, d) {
|
|
108
109
|
if (typeof c == "number")
|
|
109
|
-
return
|
|
110
|
+
return d[r].length === c;
|
|
110
111
|
if (typeof c == "object") {
|
|
111
|
-
const
|
|
112
|
-
if (
|
|
113
|
-
return Number(
|
|
114
|
-
if (
|
|
115
|
-
return Number(
|
|
116
|
-
if (
|
|
117
|
-
return Number(
|
|
112
|
+
const f = Object.keys(c)[0], g = c[f];
|
|
113
|
+
if (f === "not")
|
|
114
|
+
return Number(d[r].length) !== Number(g);
|
|
115
|
+
if (f === "moreThan")
|
|
116
|
+
return Number(d[r].length) >= Number(g);
|
|
117
|
+
if (f === "lessThan")
|
|
118
|
+
return Number(d[r].length) <= Number(g);
|
|
118
119
|
}
|
|
119
120
|
return !1;
|
|
120
121
|
}
|
|
121
|
-
function t(
|
|
122
|
-
return
|
|
122
|
+
function t(r, l, c, d) {
|
|
123
|
+
return d[r] && d[r].propertyValue && String(d[r].propertyValue.value) === String(c);
|
|
123
124
|
}
|
|
124
125
|
const o = /* @__PURE__ */ new Map([
|
|
125
126
|
["length", e],
|
|
126
127
|
["getProperty", t]
|
|
127
128
|
]);
|
|
128
|
-
Object.keys(n).reduce((
|
|
129
|
-
function r
|
|
130
|
-
const c =
|
|
131
|
-
return typeof l == "number" ? [{ target: c, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: c, operator: "getProperty", param:
|
|
132
|
-
if (
|
|
133
|
-
return { target: c, operator: "length", param: null, value: l[
|
|
134
|
-
const
|
|
135
|
-
return { target: c, operator: "getProperty", param:
|
|
129
|
+
Object.keys(n).reduce((r, l) => (r.set(l, n[l]), r), o);
|
|
130
|
+
function i(r, l) {
|
|
131
|
+
const c = r;
|
|
132
|
+
return typeof l == "number" ? [{ target: c, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: c, operator: "getProperty", param: r, value: !!l }] : typeof l == "object" ? Object.keys(l).map((d) => {
|
|
133
|
+
if (d === "length")
|
|
134
|
+
return { target: c, operator: "length", param: null, value: l[d] };
|
|
135
|
+
const f = d, g = l[d];
|
|
136
|
+
return { target: c, operator: "getProperty", param: f, value: g };
|
|
136
137
|
}) : [];
|
|
137
138
|
}
|
|
138
|
-
function
|
|
139
|
-
return Object.keys(
|
|
140
|
-
const
|
|
141
|
-
return c.push(...
|
|
139
|
+
function s(r) {
|
|
140
|
+
return Object.keys(r).reduce((c, d) => {
|
|
141
|
+
const f = i(d, r[d]);
|
|
142
|
+
return c.push(...f), c;
|
|
142
143
|
}, []);
|
|
143
144
|
}
|
|
144
|
-
function m(
|
|
145
|
-
if (o.has(
|
|
146
|
-
const c = o.get(
|
|
147
|
-
return c && c(
|
|
145
|
+
function m(r, l) {
|
|
146
|
+
if (o.has(r.operator)) {
|
|
147
|
+
const c = o.get(r.operator);
|
|
148
|
+
return c && c(r.target, r.param, r.value, l) || !1;
|
|
148
149
|
}
|
|
149
150
|
return !1;
|
|
150
151
|
}
|
|
151
|
-
function
|
|
152
|
-
return
|
|
152
|
+
function u(r, l) {
|
|
153
|
+
return s(r).reduce((f, g) => f && m(g, l), !0);
|
|
153
154
|
}
|
|
154
|
-
function
|
|
155
|
-
const c = Object.keys(
|
|
156
|
-
return
|
|
155
|
+
function p(r, l) {
|
|
156
|
+
const c = Object.keys(r), d = c.includes("allOf"), f = c.includes("anyOf"), g = d || f, w = (g ? r[g ? d ? "allOf" : "anyOf" : "allOf"] : [r]).map((E) => u(E, l));
|
|
157
|
+
return d ? !w.includes(!1) : w.includes(!0);
|
|
157
158
|
}
|
|
158
|
-
return { parseValueSchema:
|
|
159
|
+
return { parseValueSchema: p };
|
|
159
160
|
}
|
|
160
|
-
const
|
|
161
|
-
|
|
162
|
-
ButtonGroup: { type: "ButtonGroup", name: "按钮组", icon: "ButtonGroup" },
|
|
161
|
+
const a = {
|
|
162
|
+
button: { type: "button", name: "按钮", icon: "Button" },
|
|
163
163
|
"response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
|
|
164
|
-
"response-toolbar-item": { type: "response-toolbar-item", name: "
|
|
164
|
+
"response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
|
|
165
165
|
"content-container": { type: "content-container", name: "容器", icon: "ContentContainer" },
|
|
166
|
-
DisplayField: { type: "DisplayField", name: "标签", icon: "DisplayField" },
|
|
167
166
|
"input-group": { type: "input-group", name: "文本", icon: "TextBox" },
|
|
168
167
|
textarea: { type: "textarea", name: "多行文本", icon: "MultiTextBox" },
|
|
169
168
|
lookup: { type: "lookup", name: "帮助", icon: "LookupEdit" },
|
|
@@ -174,114 +173,43 @@ const i = {
|
|
|
174
173
|
"check-box": { type: "check-box", name: "复选框", icon: "CheckBox" },
|
|
175
174
|
"check-group": { type: "check-group", name: "复选框组", icon: "CheckGroup" },
|
|
176
175
|
"combo-list": { type: "combo-list", name: "下拉列表", icon: "EnumField" },
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
FlowLayout: { type: "FlowLayout", name: "流布局" },
|
|
181
|
-
ResponseLayout: { type: "ResponseLayout", name: "布局容器", icon: "ResponseLayout3" },
|
|
182
|
-
ResponseLayoutItem: { type: "ResponseLayoutItem", name: "布局", icon: "ResponseLayout1" },
|
|
176
|
+
"response-form": { type: "response-form", name: "卡片面板", icon: "Form" },
|
|
177
|
+
"response-layout": { type: "response-layout", name: "布局容器", icon: "ResponseLayout3" },
|
|
178
|
+
"response-layout-item": { type: "response-layout-item", name: "布局", icon: "ResponseLayout1" },
|
|
183
179
|
"tree-grid": { type: "tree-grid", name: "树表格", icon: "TreeGrid" },
|
|
184
|
-
|
|
185
|
-
FieldSet: { type: "FieldSet", name: "分组", icon: "FieldSet" },
|
|
186
|
-
Form: { type: "Form", name: "卡片面板", icon: "Form" },
|
|
187
|
-
QueryForm: { type: "QueryForm", name: "查询面板", icon: "Form" },
|
|
180
|
+
"tree-grid-column": { type: "tree-grid-column", name: "树表格列" },
|
|
188
181
|
"data-grid": { type: "data-grid", name: "表格", icon: "DataGrid" },
|
|
189
182
|
"data-grid-column": { type: "data-grid-column", name: "表格列" },
|
|
190
|
-
|
|
191
|
-
Module: { type: "Module", name: "模块", icon: "Module" },
|
|
183
|
+
module: { type: "Module", name: "模块", icon: "Module" },
|
|
192
184
|
component: { type: "component", name: "组件", icon: "Component" },
|
|
193
|
-
ExternalContainer: { type: "ExternalContainer", name: "外部容器", icon: "ContentContainer" },
|
|
194
|
-
Image: { type: "Image", name: "图像", icon: "Image" },
|
|
195
|
-
ImageUpload: { type: "ImageUpload", name: "图片上传", icon: "imageupload" },
|
|
196
|
-
HiddenContainer: { type: "HiddenContainer", name: "隐藏区域", icon: "ContentContainer" },
|
|
197
|
-
ModalContainer: { type: "ModalContainer", name: "弹窗容器", icon: "ContentContainer" },
|
|
198
|
-
RouteContainer: { type: "RouteContainer", name: "路由区域", icon: "ContentContainer" },
|
|
199
185
|
tabs: { type: "tabs", name: "标签页", icon: "Tab" },
|
|
200
186
|
"tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" },
|
|
201
187
|
"tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮", icon: "Button" },
|
|
202
|
-
|
|
203
|
-
Sidebar: { type: "Sidebar", name: "侧边栏", icon: "Sidebar" },
|
|
204
|
-
HtmlTemplate: { type: "HtmlTemplate", name: "模版容器", icon: "HtmlTemplate" },
|
|
205
|
-
ListView: { type: "ListView", name: "列表", icon: "ListView" },
|
|
206
|
-
RichTextBox: { type: "RichTextBox", name: "富文本", icon: "RichTextBox" },
|
|
207
|
-
TimeSpinner: { type: "TimeSpinner", name: "时间调节器", icon: "TimePicker" },
|
|
208
|
-
TimePicker: { type: "TimePicker", name: "时间选择", icon: "TimePicker" },
|
|
188
|
+
"time-picker": { type: "time-picker", name: "时间选择", icon: "TimePicker" },
|
|
209
189
|
section: { type: "section", name: "分组面板", icon: "Section" },
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
WizardDetail: { type: "WizardDetail", name: "向导详情页" },
|
|
217
|
-
WizardDetailContainer: { type: "WizardDetailContainer", name: "向导详情容器" },
|
|
218
|
-
Wizard: { type: "Wizard", name: "向导", icon: "Wizard" },
|
|
219
|
-
MultiSelect: { type: "MultiSelect", name: "数据分配", icon: "MultiSelect" },
|
|
220
|
-
Steps: { type: "Steps", name: "步骤条", icon: "Steps" },
|
|
221
|
-
avatar: { type: "avatar", name: "头像", icon: "Avatar" },
|
|
222
|
-
ListFilter: { type: "ListFilter", name: "筛选条", icon: "ListFilter" },
|
|
223
|
-
ListNav: { type: "ListNav", name: "列表导航", icon: "ListNav" },
|
|
224
|
-
NumberRange: { type: "NumberRange", name: "数字区间选择", icon: "NumericBox" },
|
|
225
|
-
Scrollspy: { type: "Scrollspy", name: "滚动监听", icon: "Scrollspy" },
|
|
226
|
-
LanguageTextBox: { type: "LanguageTextBox", name: "多语言输入框", icon: "LanguageTextBox" },
|
|
227
|
-
ComponentRef: { type: "ComponentRef", name: "组件引用节点" },
|
|
228
|
-
FileUpload: { type: "FileUpload", name: "附件上传", icon: "FileUpload" },
|
|
229
|
-
FilePreview: { type: "FilePreview", name: "附件预览", icon: "FilePreview" },
|
|
230
|
-
ViewChange: { type: "ViewChange", name: "多视图切换", icon: "Button" },
|
|
231
|
-
MultiViewContainer: { type: "MultiViewContainer", name: "多视图", icon: "MultiViewContainer" },
|
|
232
|
-
MultiViewItem: { type: "MultiViewItem", name: "多视图项", dependentParentControl: "MultiViewContainer" },
|
|
233
|
-
Footer: { type: "Footer", name: "页脚" },
|
|
234
|
-
DiscussionEditor: { type: "DiscussionEditor", name: "评论编辑区", icon: "DiscussionEditor" },
|
|
235
|
-
DiscussionList: { type: "DiscussionList", name: "评论列表", icon: "DiscussionList" },
|
|
236
|
-
NavTab: { type: "NavTab", name: "标签类导航", icon: "NavTab" },
|
|
237
|
-
Tags: { type: "Tags", name: "标记组", icon: "Tags" },
|
|
238
|
-
Portlet: { type: "Portlet", name: "小部件", icon: "dingzhi" },
|
|
190
|
+
"section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" },
|
|
191
|
+
"section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" },
|
|
192
|
+
splitter: { type: "splitter", name: "分栏面板", icon: "Splitter" },
|
|
193
|
+
"splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" },
|
|
194
|
+
"component-ref": { type: "component-ref", name: "组件引用节点" },
|
|
195
|
+
uploader: { type: "uploader", name: "附件上传", icon: "FileUpload" },
|
|
239
196
|
"page-header": { type: "page-header", name: "页头", icon: "Header" },
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
TabToolbar: { type: "TabToolbar", name: "标签页工具栏", icon: "TabToolbar" },
|
|
249
|
-
HeaderToolBar: { type: "HeaderToolBar", name: "头部组件工具栏", icon: "HeaderToolBar" },
|
|
250
|
-
ModalFooterToolBar: { type: "ModalFooterToolBar", name: "底部组件工具栏", icon: "ModalFooterToolBar" },
|
|
251
|
-
HeaderToolBarItem: { type: "HeaderToolBarItem", name: "头部组件工具栏按钮", icon: "HeaderToolBarItem" },
|
|
252
|
-
ModalFooterToolBarItem: { type: "ModalFooterToolBarItem", name: "底部组件工具栏按钮", icon: "ModalFooterToolBarItem" },
|
|
253
|
-
OrganizationSelector: { type: "OrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
254
|
-
AdminOrganizationSelector: { type: "AdminOrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
255
|
-
EmployeeSelector: { type: "EmployeeSelector", name: "人员选择", icon: "PersonnelSelector" },
|
|
256
|
-
OaRelation: { type: "OaRelation", name: "关联行政审批", icon: "TextBox" },
|
|
257
|
-
CitySelector: { type: "CitySelector", name: "城市选择", icon: "CitySelector" },
|
|
258
|
-
ExtIntergration: { type: "ExtIntergration", name: "外部服务集成", icon: "ViewModel" },
|
|
259
|
-
AppointmentCalendar: { type: "AppointmentCalendar", name: "预约日历", icon: "DateBox" },
|
|
260
|
-
/** 查询类 start */
|
|
261
|
-
Charts: { type: "Charts", name: "图表", icon: "Charts" },
|
|
262
|
-
QdpFramework: { type: "QdpFramework", name: "查询结果工具栏", icon: "QdpFramework" },
|
|
263
|
-
SpreadSheet: { type: "SpreadSheet", name: "查询表格控件", icon: "Charts" },
|
|
264
|
-
QdpConditionDialog: { type: "QdpConditionDialog", name: "查询筛选对话框", icon: "ContentContainer" },
|
|
265
|
-
QdpConditionDialogTab: { type: "QdpConditionDialogTab", name: "查询筛选标签页", icon: "Tab" },
|
|
266
|
-
/** 查询类 end */
|
|
267
|
-
/** 审批类 start */
|
|
268
|
-
ApprovalLogs: { type: "ApprovalLogs", name: "审批记录", icon: "ApprovalLogs" },
|
|
269
|
-
ApprovalComments: { type: "ApprovalComments", name: "审批意见", icon: "shenpiyijian" }
|
|
270
|
-
/** 审批类 end */
|
|
271
|
-
}, re = {}, le = {};
|
|
272
|
-
ie();
|
|
273
|
-
function ce(n, e, t = /* @__PURE__ */ new Map(), o = (m, d, u) => d, r = {}, p = (m) => m) {
|
|
274
|
-
return $[e.title] = e, j[e.title] = o, re[e.title] = r, le[e.title] = p, (m = {}) => {
|
|
275
|
-
const d = ae(m, e, t), u = Object.keys(n).reduce((a, l) => (a[l] = n[l].default, a), {});
|
|
276
|
-
return Object.assign(u, d);
|
|
197
|
+
"page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
|
|
198
|
+
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
|
|
199
|
+
}, ce = {}, se = {};
|
|
200
|
+
le();
|
|
201
|
+
function pe(n, e, t = /* @__PURE__ */ new Map(), o = (m, u, p) => u, i = {}, s = (m) => m) {
|
|
202
|
+
return _[e.title] = e, J[e.title] = o, ce[e.title] = i, se[e.title] = s, (m = {}) => {
|
|
203
|
+
const u = ae(m, e, t), p = Object.keys(n).reduce((r, l) => (r[l] = n[l].default, r), {});
|
|
204
|
+
return Object.assign(p, u);
|
|
277
205
|
};
|
|
278
206
|
}
|
|
279
|
-
function
|
|
207
|
+
function ue(n, e) {
|
|
280
208
|
return { customClass: e.class, customStyle: e.style };
|
|
281
209
|
}
|
|
282
|
-
const
|
|
283
|
-
["appearance",
|
|
284
|
-
]),
|
|
210
|
+
const de = /* @__PURE__ */ new Map([
|
|
211
|
+
["appearance", ue]
|
|
212
|
+
]), me = "https://json-schema.org/draft/2020-12/schema", fe = "https://farris-design.gitee.io/radio-group.schema.json", ye = "radio-group", ge = "A Farris Input Component", he = "object", ve = {
|
|
285
213
|
id: {
|
|
286
214
|
description: "The unique identifier for a radio-group",
|
|
287
215
|
type: "string"
|
|
@@ -362,18 +290,18 @@ const se = /* @__PURE__ */ new Map([
|
|
|
362
290
|
description: "",
|
|
363
291
|
type: "array"
|
|
364
292
|
}
|
|
365
|
-
},
|
|
293
|
+
}, be = [
|
|
366
294
|
"id",
|
|
367
295
|
"type"
|
|
368
|
-
],
|
|
369
|
-
$schema:
|
|
370
|
-
$id:
|
|
371
|
-
title:
|
|
372
|
-
description:
|
|
373
|
-
type:
|
|
374
|
-
properties:
|
|
375
|
-
required:
|
|
376
|
-
},
|
|
296
|
+
], Ce = {
|
|
297
|
+
$schema: me,
|
|
298
|
+
$id: fe,
|
|
299
|
+
title: ye,
|
|
300
|
+
description: ge,
|
|
301
|
+
type: he,
|
|
302
|
+
properties: ve,
|
|
303
|
+
required: be
|
|
304
|
+
}, ke = {
|
|
377
305
|
/**
|
|
378
306
|
* 是否被选中
|
|
379
307
|
*/
|
|
@@ -390,8 +318,8 @@ const se = /* @__PURE__ */ new Map([
|
|
|
390
318
|
* type为button或者tag时的尺寸
|
|
391
319
|
*/
|
|
392
320
|
size: { type: String, default: "middle" }
|
|
393
|
-
},
|
|
394
|
-
...
|
|
321
|
+
}, U = {
|
|
322
|
+
...ke,
|
|
395
323
|
/**
|
|
396
324
|
* 组件标识
|
|
397
325
|
*/
|
|
@@ -430,50 +358,50 @@ const se = /* @__PURE__ */ new Map([
|
|
|
430
358
|
* 枚举数组中枚举值的key值。
|
|
431
359
|
*/
|
|
432
360
|
valueField: { type: String, default: "value" }
|
|
433
|
-
},
|
|
434
|
-
function
|
|
435
|
-
const o =
|
|
436
|
-
function p
|
|
437
|
-
return
|
|
361
|
+
}, X = pe(U, Ce, de, oe);
|
|
362
|
+
function Q(n, e, t) {
|
|
363
|
+
const o = S(() => !n.disabled), i = S(() => n.enumData || []);
|
|
364
|
+
function s(p) {
|
|
365
|
+
return p[n.valueField];
|
|
438
366
|
}
|
|
439
|
-
function m(
|
|
440
|
-
return
|
|
367
|
+
function m(p) {
|
|
368
|
+
return p[n.textField];
|
|
441
369
|
}
|
|
442
|
-
function
|
|
370
|
+
function u(p, r) {
|
|
443
371
|
if (o.value) {
|
|
444
|
-
const l = p
|
|
372
|
+
const l = s(p);
|
|
445
373
|
t.value !== l && (t.value = l, e.emit("changeValue", l), e.emit("update:modelValue", l));
|
|
446
374
|
}
|
|
447
|
-
|
|
375
|
+
r.stopPropagation();
|
|
448
376
|
}
|
|
449
377
|
return {
|
|
450
|
-
enumData:
|
|
451
|
-
getValue:
|
|
378
|
+
enumData: i,
|
|
379
|
+
getValue: s,
|
|
452
380
|
getText: m,
|
|
453
|
-
onClickRadio:
|
|
381
|
+
onClickRadio: u
|
|
454
382
|
};
|
|
455
383
|
}
|
|
456
|
-
const
|
|
384
|
+
const P = /* @__PURE__ */ O({
|
|
457
385
|
name: "FRadioGroup",
|
|
458
|
-
props:
|
|
386
|
+
props: U,
|
|
459
387
|
emits: ["changeValue", "update:modelValue"],
|
|
460
388
|
setup(n, e) {
|
|
461
|
-
const t =
|
|
389
|
+
const t = k(n.modelValue), {
|
|
462
390
|
enumData: o,
|
|
463
|
-
onClickRadio:
|
|
464
|
-
getValue:
|
|
391
|
+
onClickRadio: i,
|
|
392
|
+
getValue: s,
|
|
465
393
|
getText: m
|
|
466
|
-
} =
|
|
394
|
+
} = Q(n, e, t), u = S(() => ({
|
|
467
395
|
"farris-checkradio-hor": n.direction === "horizontal"
|
|
468
|
-
})),
|
|
469
|
-
return
|
|
470
|
-
radios:
|
|
396
|
+
})), p = k([]);
|
|
397
|
+
return K(x, {
|
|
398
|
+
radios: p,
|
|
471
399
|
parentProps: n,
|
|
472
400
|
parentContext: e
|
|
473
401
|
}), () => h("div", {
|
|
474
|
-
class: ["farris-input-wrap",
|
|
475
|
-
}, [e.slots.default ? e.slots.default() : o.value.map((
|
|
476
|
-
const c = "radio_" + n.id + n.name +
|
|
402
|
+
class: ["farris-input-wrap", u.value]
|
|
403
|
+
}, [e.slots.default ? e.slots.default() : o.value.map((r, l) => {
|
|
404
|
+
const c = "radio_" + n.id + n.name + r[n.valueField];
|
|
477
405
|
return h("div", {
|
|
478
406
|
class: "custom-control custom-radio"
|
|
479
407
|
}, [h("input", {
|
|
@@ -481,171 +409,107 @@ const w = /* @__PURE__ */ E({
|
|
|
481
409
|
class: "custom-control-input",
|
|
482
410
|
name: c,
|
|
483
411
|
id: c,
|
|
484
|
-
value:
|
|
485
|
-
checked:
|
|
412
|
+
value: s(r),
|
|
413
|
+
checked: s(r) === t.value,
|
|
486
414
|
disabled: n.disabled,
|
|
487
415
|
tabindex: n.tabIndex,
|
|
488
|
-
onClick: (
|
|
416
|
+
onClick: (d) => i(r, d)
|
|
489
417
|
}, null), h("label", {
|
|
490
418
|
class: "custom-control-label",
|
|
491
419
|
for: c
|
|
492
|
-
}, [m(
|
|
420
|
+
}, [m(r)])]);
|
|
493
421
|
})]);
|
|
494
422
|
}
|
|
495
423
|
});
|
|
496
|
-
function
|
|
497
|
-
var
|
|
424
|
+
function Me(n, e, t) {
|
|
425
|
+
var G;
|
|
498
426
|
function o() {
|
|
499
427
|
t != null && t.resolveComponentContext && t.resolveComponentContext();
|
|
500
428
|
}
|
|
501
429
|
o();
|
|
502
|
-
const
|
|
503
|
-
function
|
|
430
|
+
const i = t && t.getStyles && t.getStyles() || "", s = t && t.getDesignerClass && t.getDesignerClass() || "", m = k();
|
|
431
|
+
function u() {
|
|
504
432
|
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : t && t.checkCanMoveComponent ? t.checkCanMoveComponent() : !0;
|
|
505
433
|
}
|
|
506
|
-
function
|
|
434
|
+
function p() {
|
|
507
435
|
return !1;
|
|
508
436
|
}
|
|
509
|
-
function
|
|
437
|
+
function r() {
|
|
510
438
|
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : t && t.checkCanDeleteComponent ? t.checkCanDeleteComponent() : !0;
|
|
511
439
|
}
|
|
512
440
|
function l() {
|
|
513
441
|
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !0 : t && t.hideNestedPaddingInDesginerView ? t.hideNestedPaddingInDesginerView() : !1;
|
|
514
442
|
}
|
|
515
|
-
function c(
|
|
516
|
-
if (!
|
|
443
|
+
function c(y) {
|
|
444
|
+
if (!y || !y.value)
|
|
517
445
|
return null;
|
|
518
|
-
if (
|
|
519
|
-
return
|
|
520
|
-
const b =
|
|
446
|
+
if (y.value.schema && y.value.schema.type === "component")
|
|
447
|
+
return y.value;
|
|
448
|
+
const b = k(y == null ? void 0 : y.value.parent), v = c(b);
|
|
521
449
|
return v || null;
|
|
522
450
|
}
|
|
523
|
-
function
|
|
524
|
-
const { componentInstance: b, designerItemElementRef: v } =
|
|
525
|
-
return !b || !b.value ? null : b.value.canMove ? v :
|
|
451
|
+
function d(y = e) {
|
|
452
|
+
const { componentInstance: b, designerItemElementRef: v } = y;
|
|
453
|
+
return !b || !b.value ? null : b.value.canMove ? v : d(y.parent);
|
|
526
454
|
}
|
|
527
|
-
function y
|
|
528
|
-
return !!t && t.canAccepts(
|
|
455
|
+
function f(y) {
|
|
456
|
+
return !!t && t.canAccepts(y);
|
|
529
457
|
}
|
|
530
458
|
function g() {
|
|
531
459
|
return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
|
|
532
460
|
}
|
|
533
|
-
function
|
|
461
|
+
function M() {
|
|
534
462
|
}
|
|
535
|
-
function
|
|
463
|
+
function T(y, b) {
|
|
536
464
|
b && t != null && t.onAcceptMovedChildElement && t.onAcceptMovedChildElement(b);
|
|
537
465
|
}
|
|
538
|
-
function
|
|
539
|
-
const { componentType: b } =
|
|
540
|
-
let v =
|
|
541
|
-
t && t.onResolveNewComponentSchema && (v = t.onResolveNewComponentSchema(
|
|
542
|
-
const
|
|
543
|
-
return v && !v.id && v.type === b && (v.id = `${
|
|
466
|
+
function w(y) {
|
|
467
|
+
const { componentType: b } = y;
|
|
468
|
+
let v = N(b, y);
|
|
469
|
+
t && t.onResolveNewComponentSchema && (v = t.onResolveNewComponentSchema(y, v));
|
|
470
|
+
const F = b.toLowerCase().replace("-", "_");
|
|
471
|
+
return v && !v.id && v.type === b && (v.id = `${F}_${Math.random().toString().slice(2, 6)}`), v;
|
|
544
472
|
}
|
|
545
|
-
function
|
|
546
|
-
const v = String(
|
|
547
|
-
|
|
548
|
-
let
|
|
549
|
-
t && t.onAcceptNewChildElement && (
|
|
550
|
-
const
|
|
551
|
-
return
|
|
473
|
+
function j(y, b) {
|
|
474
|
+
const v = String(y.getAttribute("data-controltype")), F = y.getAttribute("data-feature"), z = F ? JSON.parse(F) : {};
|
|
475
|
+
z.parentComponentInstance = m.value;
|
|
476
|
+
let V = N(v, z);
|
|
477
|
+
t && t.onAcceptNewChildElement && (V = t.onAcceptNewChildElement(y, b, V));
|
|
478
|
+
const Z = v.toLowerCase().replace("-", "_");
|
|
479
|
+
return V && !V.id && V.type === v && (V.id = `${Z}_${Math.random().toString().slice(2, 6)}`), V;
|
|
552
480
|
}
|
|
553
|
-
function
|
|
481
|
+
function E(y) {
|
|
554
482
|
}
|
|
555
|
-
function
|
|
483
|
+
function Y(...y) {
|
|
556
484
|
if (t && t.getPropsConfig)
|
|
557
|
-
return t.getPropsConfig(...
|
|
485
|
+
return t.getPropsConfig(...y);
|
|
558
486
|
}
|
|
559
487
|
return m.value = {
|
|
560
|
-
canMove:
|
|
561
|
-
canSelectParent:
|
|
562
|
-
canDelete:
|
|
488
|
+
canMove: u(),
|
|
489
|
+
canSelectParent: p(),
|
|
490
|
+
canDelete: r(),
|
|
563
491
|
canNested: !l(),
|
|
564
492
|
contents: e == null ? void 0 : e.schema.contents,
|
|
565
493
|
elementRef: n,
|
|
566
|
-
parent: (
|
|
494
|
+
parent: (G = e == null ? void 0 : e.parent) == null ? void 0 : G.componentInstance,
|
|
567
495
|
schema: e == null ? void 0 : e.schema,
|
|
568
|
-
styles:
|
|
569
|
-
designerClass:
|
|
570
|
-
canAccepts:
|
|
496
|
+
styles: i,
|
|
497
|
+
designerClass: s,
|
|
498
|
+
canAccepts: f,
|
|
571
499
|
getBelongedComponentInstance: c,
|
|
572
|
-
getDraggableDesignItemElement:
|
|
500
|
+
getDraggableDesignItemElement: d,
|
|
573
501
|
getDraggingDisplayText: g,
|
|
574
|
-
getPropConfig:
|
|
575
|
-
getDragScopeElement:
|
|
576
|
-
onAcceptMovedChildElement:
|
|
577
|
-
onAcceptNewChildElement:
|
|
578
|
-
onChildElementMovedOut:
|
|
579
|
-
addNewChildComponentSchema:
|
|
502
|
+
getPropConfig: Y,
|
|
503
|
+
getDragScopeElement: M,
|
|
504
|
+
onAcceptMovedChildElement: T,
|
|
505
|
+
onAcceptNewChildElement: j,
|
|
506
|
+
onChildElementMovedOut: E,
|
|
507
|
+
addNewChildComponentSchema: w,
|
|
580
508
|
updateDragAndDropRules: o,
|
|
581
|
-
triggerBelongedComponentToMoveWhenMoved: !!t && t.triggerBelongedComponentToMoveWhenMoved ||
|
|
582
|
-
triggerBelongedComponentToDeleteWhenDeleted: !!t && t.triggerBelongedComponentToDeleteWhenDeleted ||
|
|
509
|
+
triggerBelongedComponentToMoveWhenMoved: !!t && t.triggerBelongedComponentToMoveWhenMoved || k(!1),
|
|
510
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!t && t.triggerBelongedComponentToDeleteWhenDeleted || k(!1)
|
|
583
511
|
}, m;
|
|
584
512
|
}
|
|
585
|
-
class H {
|
|
586
|
-
static getEditorTypesByMDataType(e) {
|
|
587
|
-
const t = this.fieldControlTypeMapping[e];
|
|
588
|
-
return t || [{ key: "", value: "" }];
|
|
589
|
-
}
|
|
590
|
-
}
|
|
591
|
-
/**
|
|
592
|
-
* <字段类型,可配置的控件类型列表>的映射
|
|
593
|
-
*/
|
|
594
|
-
C(H, "fieldControlTypeMapping", {
|
|
595
|
-
String: [
|
|
596
|
-
{ key: i["input-group"].type, value: i["input-group"].name },
|
|
597
|
-
{ key: i.lookup.type, value: i.lookup.name },
|
|
598
|
-
{ key: i.Image.type, value: i.Image.name },
|
|
599
|
-
{ key: i["date-picker"].type, value: i["date-picker"].name },
|
|
600
|
-
{ key: i["check-box"].type, value: i["check-box"].name },
|
|
601
|
-
{ key: i["radio-group"].type, value: i["radio-group"].name },
|
|
602
|
-
{ key: i["combo-list"].type, value: i["combo-list"].name },
|
|
603
|
-
{ key: i.textarea.type, value: i.textarea.name }
|
|
604
|
-
// { key: DgControl.Tags.type, value: DgControl.Tags.name },
|
|
605
|
-
],
|
|
606
|
-
Text: [
|
|
607
|
-
{ key: i.textarea.type, value: i.textarea.name },
|
|
608
|
-
{ key: i.avatar.type, value: i.avatar.name },
|
|
609
|
-
{ key: i.lookup.type, value: i.lookup.name }
|
|
610
|
-
],
|
|
611
|
-
Decimal: [
|
|
612
|
-
{ key: i["number-spinner"].type, value: i["number-spinner"].name }
|
|
613
|
-
],
|
|
614
|
-
Integer: [
|
|
615
|
-
{ key: i["number-spinner"].type, value: i["number-spinner"].name }
|
|
616
|
-
],
|
|
617
|
-
Number: [
|
|
618
|
-
{ key: i["number-spinner"].type, value: i["number-spinner"].name }
|
|
619
|
-
],
|
|
620
|
-
BigNumber: [
|
|
621
|
-
{ key: i["number-spinner"].type, value: i["number-spinner"].name }
|
|
622
|
-
],
|
|
623
|
-
Date: [
|
|
624
|
-
{ key: i["date-picker"].type, value: i["date-picker"].name }
|
|
625
|
-
],
|
|
626
|
-
DateTime: [
|
|
627
|
-
{ key: i["date-picker"].type, value: i["date-picker"].name }
|
|
628
|
-
],
|
|
629
|
-
Boolean: [
|
|
630
|
-
{ key: i.switch.type, value: i.switch.name },
|
|
631
|
-
{ key: i["check-box"].type, value: i["check-box"].name }
|
|
632
|
-
],
|
|
633
|
-
Enum: [
|
|
634
|
-
{ key: i["combo-list"].type, value: i["combo-list"].name },
|
|
635
|
-
{ key: i["radio-group"].type, value: i["radio-group"].name }
|
|
636
|
-
],
|
|
637
|
-
Object: [
|
|
638
|
-
{ key: i.lookup.type, value: i.lookup.name },
|
|
639
|
-
{ key: i["combo-list"].type, value: i["combo-list"].name },
|
|
640
|
-
{ key: i["radio-group"].type, value: i["radio-group"].name }
|
|
641
|
-
],
|
|
642
|
-
EmployeeSelector: [
|
|
643
|
-
{ key: i.EmployeeSelector.type, value: i.EmployeeSelector.name }
|
|
644
|
-
],
|
|
645
|
-
AdminOrganizationSelector: [
|
|
646
|
-
{ key: i.AdminOrganizationSelector.type, value: i.AdminOrganizationSelector.name }
|
|
647
|
-
]
|
|
648
|
-
});
|
|
649
513
|
class Te {
|
|
650
514
|
constructor(e, t) {
|
|
651
515
|
C(this, "componentId");
|
|
@@ -675,7 +539,7 @@ class Te {
|
|
|
675
539
|
if (t) {
|
|
676
540
|
if (!this.designViewModelField) {
|
|
677
541
|
const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
678
|
-
this.designViewModelField = o.fields.find((
|
|
542
|
+
this.designViewModelField = o.fields.find((i) => i.id === t);
|
|
679
543
|
}
|
|
680
544
|
e.updateOn = this.designViewModelField.updateOn;
|
|
681
545
|
}
|
|
@@ -683,9 +547,135 @@ class Te {
|
|
|
683
547
|
changeFieldEditorType(e, t) {
|
|
684
548
|
}
|
|
685
549
|
getBasicPropConfig(e) {
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
550
|
+
return {
|
|
551
|
+
description: "Basic Information",
|
|
552
|
+
title: "基本信息",
|
|
553
|
+
properties: {
|
|
554
|
+
id: {
|
|
555
|
+
description: "组件标识",
|
|
556
|
+
title: "标识",
|
|
557
|
+
type: "string",
|
|
558
|
+
readonly: !0
|
|
559
|
+
},
|
|
560
|
+
type: {
|
|
561
|
+
description: "组件类型",
|
|
562
|
+
title: "控件类型",
|
|
563
|
+
type: "select",
|
|
564
|
+
editor: {
|
|
565
|
+
type: "combo-list",
|
|
566
|
+
textField: "name",
|
|
567
|
+
valueField: "value",
|
|
568
|
+
data: [{ value: e.type, name: a[e.type].name }]
|
|
569
|
+
}
|
|
570
|
+
}
|
|
571
|
+
}
|
|
572
|
+
};
|
|
573
|
+
}
|
|
574
|
+
getAppearanceConfig(e = null) {
|
|
575
|
+
return {
|
|
576
|
+
title: "样式",
|
|
577
|
+
description: "Appearance",
|
|
578
|
+
properties: {
|
|
579
|
+
class: {
|
|
580
|
+
title: "class样式",
|
|
581
|
+
type: "string",
|
|
582
|
+
description: "组件的CSS样式",
|
|
583
|
+
$converter: "/converter/appearance.converter"
|
|
584
|
+
},
|
|
585
|
+
style: {
|
|
586
|
+
title: "style样式",
|
|
587
|
+
type: "string",
|
|
588
|
+
description: "组件的样式",
|
|
589
|
+
$converter: "/converter/appearance.converter"
|
|
590
|
+
}
|
|
591
|
+
}
|
|
592
|
+
};
|
|
593
|
+
}
|
|
594
|
+
}
|
|
595
|
+
const D = class D {
|
|
596
|
+
/**
|
|
597
|
+
* 根据绑定字段类型获取可用的输入类控件
|
|
598
|
+
*/
|
|
599
|
+
static getEditorTypesByMDataType(e) {
|
|
600
|
+
const t = D.fieldControlTypeMapping[e];
|
|
601
|
+
return t || [{ key: "", value: "" }];
|
|
602
|
+
}
|
|
603
|
+
/**
|
|
604
|
+
* 获取所有输入类控件
|
|
605
|
+
*/
|
|
606
|
+
static getAllInputTypes() {
|
|
607
|
+
const e = [];
|
|
608
|
+
for (let t in D.fieldControlTypeMapping)
|
|
609
|
+
D.fieldControlTypeMapping[t].forEach((o) => {
|
|
610
|
+
e.find((i) => i.key === o.key && i.value === o.value) || e.push({ key: o.key, value: o.value });
|
|
611
|
+
});
|
|
612
|
+
return e;
|
|
613
|
+
}
|
|
614
|
+
};
|
|
615
|
+
/**
|
|
616
|
+
* <字段类型,可配置的控件类型列表>的映射
|
|
617
|
+
*/
|
|
618
|
+
C(D, "fieldControlTypeMapping", {
|
|
619
|
+
String: [
|
|
620
|
+
{ key: a["input-group"].type, value: a["input-group"].name },
|
|
621
|
+
{ key: a.lookup.type, value: a.lookup.name },
|
|
622
|
+
{ key: a["date-picker"].type, value: a["date-picker"].name },
|
|
623
|
+
{ key: a["check-box"].type, value: a["check-box"].name },
|
|
624
|
+
{ key: a["radio-group"].type, value: a["radio-group"].name },
|
|
625
|
+
{ key: a["combo-list"].type, value: a["combo-list"].name },
|
|
626
|
+
{ key: a.textarea.type, value: a.textarea.name }
|
|
627
|
+
],
|
|
628
|
+
Text: [
|
|
629
|
+
{ key: a.textarea.type, value: a.textarea.name },
|
|
630
|
+
{ key: a.lookup.type, value: a.lookup.name }
|
|
631
|
+
],
|
|
632
|
+
Decimal: [
|
|
633
|
+
{ key: a["number-spinner"].type, value: a["number-spinner"].name }
|
|
634
|
+
],
|
|
635
|
+
Integer: [
|
|
636
|
+
{ key: a["number-spinner"].type, value: a["number-spinner"].name }
|
|
637
|
+
],
|
|
638
|
+
Number: [
|
|
639
|
+
{ key: a["number-spinner"].type, value: a["number-spinner"].name }
|
|
640
|
+
],
|
|
641
|
+
BigNumber: [
|
|
642
|
+
{ key: a["number-spinner"].type, value: a["number-spinner"].name }
|
|
643
|
+
],
|
|
644
|
+
Date: [
|
|
645
|
+
{ key: a["date-picker"].type, value: a["date-picker"].name }
|
|
646
|
+
],
|
|
647
|
+
DateTime: [
|
|
648
|
+
{ key: a["date-picker"].type, value: a["date-picker"].name }
|
|
649
|
+
],
|
|
650
|
+
Boolean: [
|
|
651
|
+
{ key: a.switch.type, value: a.switch.name },
|
|
652
|
+
{ key: a["check-box"].type, value: a["check-box"].name }
|
|
653
|
+
],
|
|
654
|
+
Enum: [
|
|
655
|
+
{ key: a["combo-list"].type, value: a["combo-list"].name },
|
|
656
|
+
{ key: a["radio-group"].type, value: a["radio-group"].name }
|
|
657
|
+
],
|
|
658
|
+
Object: [
|
|
659
|
+
{ key: a.lookup.type, value: a.lookup.name },
|
|
660
|
+
{ key: a["combo-list"].type, value: a["combo-list"].name },
|
|
661
|
+
{ key: a["radio-group"].type, value: a["radio-group"].name }
|
|
662
|
+
]
|
|
663
|
+
});
|
|
664
|
+
let B = D;
|
|
665
|
+
const we = k(0);
|
|
666
|
+
class Ve extends Te {
|
|
667
|
+
constructor(e, t) {
|
|
668
|
+
super(e, t);
|
|
669
|
+
}
|
|
670
|
+
getPropertyConfig(e, t) {
|
|
671
|
+
return this.propertyConfig.categories.basic = this.getBasicProperties(e, t), this.propertyConfig.categories.appearance = this.getAppearanceProperties(e), this.propertyConfig.categories.editor = this.getEditorProperties(e), this.propertyConfig;
|
|
672
|
+
}
|
|
673
|
+
getBasicProperties(e, t) {
|
|
674
|
+
var m;
|
|
675
|
+
var o = this;
|
|
676
|
+
this.setDesignViewModelField(e);
|
|
677
|
+
const i = this.formSchemaUtils.getFormMetadataBasicInfo(), s = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
678
|
+
return {
|
|
689
679
|
description: "Basic Information",
|
|
690
680
|
title: "基本信息",
|
|
691
681
|
properties: {
|
|
@@ -705,63 +695,48 @@ class Te {
|
|
|
705
695
|
type: "combo-list",
|
|
706
696
|
textField: "value",
|
|
707
697
|
valueField: "key",
|
|
708
|
-
|
|
709
|
-
|
|
698
|
+
editable: !1,
|
|
699
|
+
data: o.designViewModelField ? B.getEditorTypesByMDataType((m = o.designViewModelField.type) == null ? void 0 : m.name) : B.getAllInputTypes()
|
|
710
700
|
}
|
|
711
701
|
},
|
|
712
702
|
label: {
|
|
713
703
|
title: "标签",
|
|
714
704
|
type: "string",
|
|
715
705
|
$converter: "/converter/form-group-label.converter"
|
|
706
|
+
},
|
|
707
|
+
binding: {
|
|
708
|
+
description: "绑定的表单字段",
|
|
709
|
+
title: "绑定",
|
|
710
|
+
$converter: "/converter/field-selector.converter",
|
|
711
|
+
editor: {
|
|
712
|
+
type: "field-selector",
|
|
713
|
+
bindingType: { enable: !1 },
|
|
714
|
+
editorParams: {
|
|
715
|
+
propertyData: e,
|
|
716
|
+
formBasicInfo: i
|
|
717
|
+
},
|
|
718
|
+
columns: [
|
|
719
|
+
{ field: "name", title: "字段名称" },
|
|
720
|
+
{ field: "bindingField", title: "绑定字段" },
|
|
721
|
+
{ field: "fieldType", title: "字段类型" }
|
|
722
|
+
],
|
|
723
|
+
textField: "bindingField",
|
|
724
|
+
data: s
|
|
725
|
+
}
|
|
716
726
|
}
|
|
717
727
|
},
|
|
718
|
-
setPropertyRelates(
|
|
719
|
-
if (
|
|
720
|
-
switch (
|
|
728
|
+
setPropertyRelates(u, p) {
|
|
729
|
+
if (u)
|
|
730
|
+
switch (u && u.propertyID) {
|
|
721
731
|
case "type": {
|
|
722
|
-
|
|
732
|
+
o.changeControlType(e, u, t);
|
|
723
733
|
break;
|
|
724
734
|
}
|
|
725
735
|
}
|
|
726
736
|
}
|
|
727
737
|
};
|
|
728
738
|
}
|
|
729
|
-
|
|
730
|
-
* 卡片控件:切换控件类型后事件
|
|
731
|
-
* @param propertyData 控件DOM属性
|
|
732
|
-
* @param newControlType 新控件类型
|
|
733
|
-
*/
|
|
734
|
-
changeControlType(e, t) {
|
|
735
|
-
var a, l, c, s, y;
|
|
736
|
-
const o = t.propertyValue, r = this.formSchemaUtils.getComponentById(this.componentId);
|
|
737
|
-
let p = this.getControlParentContainer(e.id, r);
|
|
738
|
-
if (!p)
|
|
739
|
-
return;
|
|
740
|
-
const m = p.contents.findIndex((g) => g.id === e.id), d = p.contents[m];
|
|
741
|
-
let u;
|
|
742
|
-
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
743
|
-
editor: {
|
|
744
|
-
$type: o
|
|
745
|
-
},
|
|
746
|
-
name: this.designViewModelField.name,
|
|
747
|
-
require: this.designViewModelField.require,
|
|
748
|
-
readonly: this.designViewModelField.readonly
|
|
749
|
-
}, !1), u = this.controlCreatorUtils.setFormFieldProperty("Form", this.designViewModelField, null, o)), Object.assign(u, {
|
|
750
|
-
id: d.id,
|
|
751
|
-
appearance: d.appearance,
|
|
752
|
-
size: d.size,
|
|
753
|
-
label: d.label
|
|
754
|
-
}), Object.assign(u.editor, {
|
|
755
|
-
isTextArea: u.isTextArea && d.isTextArea,
|
|
756
|
-
type: o || "",
|
|
757
|
-
placeHolder: (a = d.editor) == null ? void 0 : a.placeHolder,
|
|
758
|
-
holdPlace: (l = d.editor) == null ? void 0 : l.holdPlace,
|
|
759
|
-
readonly: (c = d.editor) == null ? void 0 : c.readonly,
|
|
760
|
-
require: (s = d.editor) == null ? void 0 : s.require,
|
|
761
|
-
visible: (y = d.editor) == null ? void 0 : y.visible
|
|
762
|
-
}), p.contents.splice(m, 1, u);
|
|
763
|
-
}
|
|
764
|
-
getAppearanceConfig(e = null) {
|
|
739
|
+
getAppearanceProperties(e) {
|
|
765
740
|
return {
|
|
766
741
|
title: "样式",
|
|
767
742
|
description: "Appearance",
|
|
@@ -791,90 +766,52 @@ class Te {
|
|
|
791
766
|
}
|
|
792
767
|
};
|
|
793
768
|
}
|
|
794
|
-
/**
|
|
795
|
-
* 获取控件:以contents为节点进行定位
|
|
796
|
-
* @param controlId 控件ID
|
|
797
|
-
* @param domJson 容器
|
|
798
|
-
*/
|
|
799
|
-
getControlParentContainer(e, t) {
|
|
800
|
-
let o;
|
|
801
|
-
if (!t || !t.contents || t.contents.length === 0)
|
|
802
|
-
return null;
|
|
803
|
-
for (const r of t.contents) {
|
|
804
|
-
if (r.id === e)
|
|
805
|
-
return o = t, t;
|
|
806
|
-
if (o = this.getControlParentContainer(e, r), o)
|
|
807
|
-
return o;
|
|
808
|
-
}
|
|
809
|
-
}
|
|
810
|
-
getBindingFieldEditorOptions(e) {
|
|
811
|
-
const t = this.formSchemaUtils.getFormMetadataBasicInfo();
|
|
812
|
-
return {
|
|
813
|
-
type: "field-selector",
|
|
814
|
-
bindingType: { enable: !1 },
|
|
815
|
-
editorParams: {
|
|
816
|
-
propertyData: e,
|
|
817
|
-
formBasicInfo: t
|
|
818
|
-
},
|
|
819
|
-
columns: [
|
|
820
|
-
{ field: "name", title: "字段名称" },
|
|
821
|
-
{ field: "bindingField", title: "绑定字段" },
|
|
822
|
-
{ field: "fieldType", title: "字段类型" }
|
|
823
|
-
],
|
|
824
|
-
beforeOpenDialog: (o) => {
|
|
825
|
-
const r = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
826
|
-
o.instance.loadData(r);
|
|
827
|
-
},
|
|
828
|
-
textField: "bindingField"
|
|
829
|
-
};
|
|
830
|
-
}
|
|
831
|
-
}
|
|
832
|
-
class Se extends Te {
|
|
833
|
-
constructor(e, t) {
|
|
834
|
-
super(e, t);
|
|
835
|
-
}
|
|
836
|
-
getBasicProperties(e) {
|
|
837
|
-
let t = this.getBasicPropConfig(e);
|
|
838
|
-
return t.properties.binding = this.getFieldSelectorOptions(e), t;
|
|
839
|
-
}
|
|
840
|
-
getAppearanceProperties(e) {
|
|
841
|
-
return this.getAppearanceConfig(e);
|
|
842
|
-
}
|
|
843
769
|
getEditorProperties(e) {
|
|
844
770
|
return this.getComponentConfig(e);
|
|
845
771
|
}
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
772
|
+
/**
|
|
773
|
+
* 卡片控件:切换控件类型后事件
|
|
774
|
+
* @param propertyData 控件DOM属性
|
|
775
|
+
* @param newControlType 新控件类型
|
|
776
|
+
*/
|
|
777
|
+
changeControlType(e, t, o) {
|
|
778
|
+
var r, l, c, d;
|
|
779
|
+
const i = t.propertyValue, s = o && o.parent && o.parent.schema;
|
|
780
|
+
if (!s)
|
|
781
|
+
return;
|
|
782
|
+
const m = s.contents.findIndex((f) => f.id === e.id), u = s.contents[m];
|
|
783
|
+
let p;
|
|
784
|
+
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
855
785
|
editor: {
|
|
856
|
-
type:
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
786
|
+
$type: i
|
|
787
|
+
},
|
|
788
|
+
name: this.designViewModelField.name,
|
|
789
|
+
require: this.designViewModelField.require,
|
|
790
|
+
readonly: this.designViewModelField.readonly
|
|
791
|
+
}, !1), p = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, i)), p || (p = q("form-group") || {}, p.editor = q(i) || {}, delete p.editor.id, delete p.editor.binding, delete p.editor.appearance), Object.assign(p, {
|
|
792
|
+
id: u.id,
|
|
793
|
+
appearance: u.appearance,
|
|
794
|
+
size: u.size,
|
|
795
|
+
label: u.label,
|
|
796
|
+
binding: u.binding,
|
|
797
|
+
visible: u.visible
|
|
798
|
+
}), Object.assign(p.editor, {
|
|
799
|
+
isTextArea: p.isTextArea && u.isTextArea,
|
|
800
|
+
placeholder: (r = u.editor) == null ? void 0 : r.placeholder,
|
|
801
|
+
holdPlace: (l = u.editor) == null ? void 0 : l.holdPlace,
|
|
802
|
+
readonly: (c = u.editor) == null ? void 0 : c.readonly,
|
|
803
|
+
require: (d = u.editor) == null ? void 0 : d.require
|
|
804
|
+
}), s.contents.splice(m, 1), s.contents.splice(m, 0, p), o.schema = Object.assign(u, p), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
805
|
+
(f) => f.classList.remove("dgComponentSelected")
|
|
806
|
+
), we.value++;
|
|
870
807
|
}
|
|
871
808
|
getComponentConfig(e, t = {}, o = {}) {
|
|
872
|
-
const
|
|
809
|
+
const i = Object.assign({
|
|
873
810
|
description: "组件信息",
|
|
874
811
|
title: "组件信息",
|
|
875
812
|
type: "input-group",
|
|
876
813
|
$converter: "/converter/property-editor.converter"
|
|
877
|
-
}, t),
|
|
814
|
+
}, t), s = Object.assign({
|
|
878
815
|
readonly: {
|
|
879
816
|
description: "",
|
|
880
817
|
title: "只读",
|
|
@@ -896,10 +833,10 @@ class Se extends Te {
|
|
|
896
833
|
type: "string"
|
|
897
834
|
}
|
|
898
835
|
}, o);
|
|
899
|
-
return { ...
|
|
836
|
+
return { ...i, properties: { ...s } };
|
|
900
837
|
}
|
|
901
838
|
}
|
|
902
|
-
class
|
|
839
|
+
class De extends Ve {
|
|
903
840
|
constructor(e, t) {
|
|
904
841
|
super(e, t);
|
|
905
842
|
}
|
|
@@ -935,118 +872,118 @@ class Me extends Se {
|
|
|
935
872
|
});
|
|
936
873
|
}
|
|
937
874
|
}
|
|
938
|
-
function
|
|
875
|
+
function Pe(n, e) {
|
|
939
876
|
n.schema;
|
|
940
|
-
const t =
|
|
941
|
-
function
|
|
877
|
+
const t = k(!0), o = k(!0);
|
|
878
|
+
function i(c) {
|
|
942
879
|
return !1;
|
|
943
880
|
}
|
|
944
|
-
function
|
|
881
|
+
function s() {
|
|
945
882
|
return !1;
|
|
946
883
|
}
|
|
947
884
|
function m() {
|
|
948
885
|
return !1;
|
|
949
886
|
}
|
|
950
|
-
function
|
|
887
|
+
function u() {
|
|
951
888
|
return !0;
|
|
952
889
|
}
|
|
953
|
-
function
|
|
890
|
+
function p(c) {
|
|
954
891
|
}
|
|
955
|
-
function
|
|
892
|
+
function r() {
|
|
956
893
|
}
|
|
957
894
|
function l(c) {
|
|
958
895
|
return null;
|
|
959
896
|
}
|
|
960
897
|
return {
|
|
961
|
-
canAccepts:
|
|
962
|
-
checkCanDeleteComponent:
|
|
898
|
+
canAccepts: i,
|
|
899
|
+
checkCanDeleteComponent: s,
|
|
963
900
|
checkCanMoveComponent: m,
|
|
964
|
-
hideNestedPaddingInDesginerView:
|
|
965
|
-
onAcceptMovedChildElement:
|
|
966
|
-
resolveComponentContext:
|
|
901
|
+
hideNestedPaddingInDesginerView: u,
|
|
902
|
+
onAcceptMovedChildElement: p,
|
|
903
|
+
resolveComponentContext: r,
|
|
967
904
|
triggerBelongedComponentToMoveWhenMoved: t,
|
|
968
905
|
triggerBelongedComponentToDeleteWhenDeleted: o,
|
|
969
906
|
getPropsConfig: l
|
|
970
907
|
};
|
|
971
908
|
}
|
|
972
|
-
function
|
|
909
|
+
function Fe(n, e) {
|
|
973
910
|
const {
|
|
974
911
|
canAccepts: t,
|
|
975
912
|
checkCanDeleteComponent: o,
|
|
976
|
-
checkCanMoveComponent:
|
|
977
|
-
hideNestedPaddingInDesginerView:
|
|
913
|
+
checkCanMoveComponent: i,
|
|
914
|
+
hideNestedPaddingInDesginerView: s,
|
|
978
915
|
onAcceptMovedChildElement: m,
|
|
979
|
-
resolveComponentContext:
|
|
980
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
981
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
982
|
-
} =
|
|
983
|
-
function c(
|
|
984
|
-
return new
|
|
916
|
+
resolveComponentContext: u,
|
|
917
|
+
triggerBelongedComponentToMoveWhenMoved: p,
|
|
918
|
+
triggerBelongedComponentToDeleteWhenDeleted: r
|
|
919
|
+
} = Pe(n), l = n.schema;
|
|
920
|
+
function c(d, f) {
|
|
921
|
+
return new De(d, e).getPropertyConfig(l, f);
|
|
985
922
|
}
|
|
986
923
|
return {
|
|
987
924
|
canAccepts: t,
|
|
988
925
|
checkCanDeleteComponent: o,
|
|
989
|
-
checkCanMoveComponent:
|
|
990
|
-
hideNestedPaddingInDesginerView:
|
|
926
|
+
checkCanMoveComponent: i,
|
|
927
|
+
hideNestedPaddingInDesginerView: s,
|
|
991
928
|
onAcceptMovedChildElement: m,
|
|
992
|
-
resolveComponentContext:
|
|
993
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
994
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
929
|
+
resolveComponentContext: u,
|
|
930
|
+
triggerBelongedComponentToMoveWhenMoved: p,
|
|
931
|
+
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
995
932
|
getPropsConfig: c
|
|
996
933
|
};
|
|
997
934
|
}
|
|
998
|
-
const
|
|
935
|
+
const Se = /* @__PURE__ */ O({
|
|
999
936
|
name: "FRadioGroupDesign",
|
|
1000
|
-
props:
|
|
937
|
+
props: U,
|
|
1001
938
|
emits: ["changeValue", "update:modelValue"],
|
|
1002
939
|
setup(n, e) {
|
|
1003
|
-
const t =
|
|
940
|
+
const t = k(n.modelValue), {
|
|
1004
941
|
enumData: o,
|
|
1005
|
-
onClickRadio:
|
|
1006
|
-
getValue:
|
|
942
|
+
onClickRadio: i,
|
|
943
|
+
getValue: s,
|
|
1007
944
|
getText: m
|
|
1008
|
-
} =
|
|
945
|
+
} = Q(n, e, t), u = S(() => ({
|
|
1009
946
|
"farris-checkradio-hor": n.horizontal
|
|
1010
|
-
})),
|
|
1011
|
-
return
|
|
1012
|
-
|
|
1013
|
-
}), e.expose(
|
|
1014
|
-
class: ["farris-input-wrap",
|
|
1015
|
-
ref:
|
|
1016
|
-
}, [o.value.map((
|
|
1017
|
-
const
|
|
947
|
+
})), p = k(), r = A("designer-host-service"), l = A("design-item-context"), c = Fe(l, r), d = Me(p, l, c);
|
|
948
|
+
return W(() => {
|
|
949
|
+
p.value.componentInstance = d;
|
|
950
|
+
}), e.expose(d.value), () => h("div", {
|
|
951
|
+
class: ["farris-input-wrap", u.value],
|
|
952
|
+
ref: p
|
|
953
|
+
}, [o.value.map((f, g) => {
|
|
954
|
+
const M = "radio_" + n.name + g;
|
|
1018
955
|
return h("div", {
|
|
1019
956
|
class: "custom-control custom-radio"
|
|
1020
957
|
}, [h("input", {
|
|
1021
958
|
type: "radio",
|
|
1022
959
|
class: "custom-control-input",
|
|
1023
960
|
name: n.name,
|
|
1024
|
-
id:
|
|
1025
|
-
value:
|
|
1026
|
-
checked:
|
|
961
|
+
id: M,
|
|
962
|
+
value: s(f),
|
|
963
|
+
checked: s(f) === t.value,
|
|
1027
964
|
disabled: n.disabled,
|
|
1028
965
|
tabindex: n.tabIndex,
|
|
1029
|
-
onClick: (
|
|
966
|
+
onClick: (T) => i(f, T)
|
|
1030
967
|
}, null), h("label", {
|
|
1031
968
|
class: "custom-control-label",
|
|
1032
|
-
for:
|
|
1033
|
-
}, [m(
|
|
969
|
+
for: M
|
|
970
|
+
}, [m(f)])]);
|
|
1034
971
|
})]);
|
|
1035
972
|
}
|
|
1036
973
|
});
|
|
1037
|
-
|
|
1038
|
-
n.component(
|
|
974
|
+
P.install = (n) => {
|
|
975
|
+
n.component(P.name, P), n.component(L.name, L);
|
|
1039
976
|
};
|
|
1040
|
-
|
|
1041
|
-
n["radio-group"] =
|
|
977
|
+
P.register = (n, e, t, o) => {
|
|
978
|
+
n["radio-group"] = P, e["radio-group"] = X;
|
|
1042
979
|
};
|
|
1043
|
-
|
|
1044
|
-
n["radio-group"] =
|
|
980
|
+
P.registerDesigner = (n, e, t) => {
|
|
981
|
+
n["radio-group"] = Se, e["radio-group"] = X;
|
|
1045
982
|
};
|
|
1046
983
|
export {
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
984
|
+
P as RadioGroup,
|
|
985
|
+
P as default,
|
|
986
|
+
X as propsResolver,
|
|
987
|
+
U as radioGroupProps,
|
|
988
|
+
ne as radioProps
|
|
1052
989
|
};
|