@farris/ui-vue 1.2.7 → 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 +79 -79
- package/components/avatar/index.esm.js +393 -440
- 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 +496 -542
- package/components/color-picker/index.esm.js +1 -1
- package/components/combo-list/index.esm.js +437 -483
- package/components/combo-tree/index.esm.js +8 -8
- package/components/component/index.esm.js +89 -89
- package/components/condition/index.esm.js +839 -726
- package/components/content-container/index.esm.js +61 -61
- package/components/data-grid/index.esm.js +4702 -4972
- package/components/data-view/index.esm.js +2999 -2875
- package/components/date-picker/index.esm.js +2626 -2672
- 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 +934 -976
- package/components/dynamic-resolver/index.esm.js +67 -35
- package/components/dynamic-view/index.esm.js +258 -249
- 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 +1892 -1775
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5245 -5514
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1483 -1556
- 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 +668 -714
- package/components/layout/index.esm.js +148 -148
- package/components/list-nav/index.esm.js +109 -109
- package/components/list-view/index.esm.js +1679 -1563
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +6596 -6865
- package/components/mapping-editor/index.esm.js +5592 -5862
- 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 +988 -1034
- package/components/page-footer/index.esm.js +106 -106
- package/components/page-header/index.esm.js +1088 -1296
- package/components/pagination/index.esm.js +252 -252
- package/components/progress/index.esm.js +37 -37
- package/components/property-editor/index.esm.js +1416 -1462
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +757 -830
- 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 +452 -498
- 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 +117 -117
- package/components/response-toolbar/index.esm.js +1021 -1238
- package/components/schema-selector/index.esm.js +3215 -3308
- 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 +442 -488
- package/components/tabs/index.esm.js +1835 -2004
- package/components/tags/index.esm.js +215 -215
- package/components/text/index.esm.js +53 -53
- package/components/textarea/index.esm.js +451 -482
- package/components/time-picker/index.esm.js +1345 -1392
- package/components/transfer/index.esm.js +135 -135
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5761 -6020
- package/components/tree-view/index.esm.js +2380 -2253
- 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 +31630 -31224
- 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/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/lookup.property-config.d.ts +2 -1
- package/types/modal/src/modal.props.d.ts +1 -4
- package/types/property-panel/src/composition/entity/base-property.d.ts +0 -12
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +11 -26
- 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,36 +1,37 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { ref as
|
|
5
|
-
import { cloneDeep as
|
|
1
|
+
var ae = Object.defineProperty;
|
|
2
|
+
var re = (e, t, n) => t in e ? ae(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var P = (e, t, n) => re(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { ref as h, computed as y, watch as D, onMounted as j, nextTick as z, createVNode as T, reactive as ie, withDirectives as le, resolveDirective as ue, defineComponent as Q, Fragment as J, inject as Z } from "vue";
|
|
5
|
+
import { cloneDeep as se } from "lodash-es";
|
|
6
6
|
import "bignumber.js";
|
|
7
|
-
import { useNumber as
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
import { useNumber as ce, useFormat as de, useSpinner as pe, useTextBox as fe } from "../number-spinner/index.esm.js";
|
|
8
|
+
import { getSchemaByType as _ } from "../dynamic-resolver/index.esm.js";
|
|
9
|
+
const X = {}, Y = {};
|
|
10
|
+
function q(e) {
|
|
11
|
+
const { properties: t, title: n } = e, o = Object.keys(t).reduce((a, c) => (a[c] = t[c].type === "object" && t[c].properties ? q(t[c]) : se(t[c].default), a), {});
|
|
11
12
|
return o.id = `${n}-${Date.now()}`, o;
|
|
12
13
|
}
|
|
13
|
-
function
|
|
14
|
-
const n =
|
|
14
|
+
function I(e, t = {}) {
|
|
15
|
+
const n = X[e];
|
|
15
16
|
if (n) {
|
|
16
|
-
let o =
|
|
17
|
-
const a =
|
|
18
|
-
return o = a ? a({ getSchemaByType:
|
|
17
|
+
let o = q(n);
|
|
18
|
+
const a = Y[e];
|
|
19
|
+
return o = a ? a({ getSchemaByType: I }, o, t) : o, o;
|
|
19
20
|
}
|
|
20
21
|
return null;
|
|
21
22
|
}
|
|
22
|
-
function de(e, t) {
|
|
23
|
-
const n = U(t);
|
|
24
|
-
return Object.keys(e).reduce((o, a) => (o[a] = e[a], o), n), n;
|
|
25
|
-
}
|
|
26
23
|
function me(e, t) {
|
|
24
|
+
const n = q(t);
|
|
25
|
+
return Object.keys(e).reduce((o, a) => (o[a] && typeof o[a] == "object" ? Object.assign(o[a], e[a]) : o[a] = e[a], o), n), n;
|
|
26
|
+
}
|
|
27
|
+
function ye(e, t) {
|
|
27
28
|
return Object.keys(e).filter((o) => e[o] != null).reduce((o, a) => {
|
|
28
29
|
if (t.has(a)) {
|
|
29
|
-
const
|
|
30
|
-
if (typeof
|
|
31
|
-
o[
|
|
30
|
+
const c = t.get(a);
|
|
31
|
+
if (typeof c == "string")
|
|
32
|
+
o[c] = e[a];
|
|
32
33
|
else {
|
|
33
|
-
const d =
|
|
34
|
+
const d = c(a, e[a], e);
|
|
34
35
|
Object.assign(o, d);
|
|
35
36
|
}
|
|
36
37
|
} else
|
|
@@ -38,71 +39,69 @@ function me(e, t) {
|
|
|
38
39
|
return o;
|
|
39
40
|
}, {});
|
|
40
41
|
}
|
|
41
|
-
function
|
|
42
|
-
const o =
|
|
43
|
-
return
|
|
42
|
+
function ve(e, t, n = /* @__PURE__ */ new Map()) {
|
|
43
|
+
const o = me(e, t);
|
|
44
|
+
return ye(o, n);
|
|
44
45
|
}
|
|
45
|
-
function
|
|
46
|
-
function t(
|
|
47
|
-
if (typeof
|
|
48
|
-
return
|
|
49
|
-
if (typeof
|
|
50
|
-
const
|
|
51
|
-
if (
|
|
52
|
-
return Number(
|
|
53
|
-
if (
|
|
54
|
-
return Number(
|
|
55
|
-
if (
|
|
56
|
-
return Number(
|
|
46
|
+
function ge(e = {}) {
|
|
47
|
+
function t(r, s, i, p) {
|
|
48
|
+
if (typeof i == "number")
|
|
49
|
+
return p[r].length === i;
|
|
50
|
+
if (typeof i == "object") {
|
|
51
|
+
const m = Object.keys(i)[0], v = i[m];
|
|
52
|
+
if (m === "not")
|
|
53
|
+
return Number(p[r].length) !== Number(v);
|
|
54
|
+
if (m === "moreThan")
|
|
55
|
+
return Number(p[r].length) >= Number(v);
|
|
56
|
+
if (m === "lessThan")
|
|
57
|
+
return Number(p[r].length) <= Number(v);
|
|
57
58
|
}
|
|
58
59
|
return !1;
|
|
59
60
|
}
|
|
60
|
-
function n(
|
|
61
|
-
return
|
|
61
|
+
function n(r, s, i, p) {
|
|
62
|
+
return p[r] && p[r].propertyValue && String(p[r].propertyValue.value) === String(i);
|
|
62
63
|
}
|
|
63
64
|
const o = /* @__PURE__ */ new Map([
|
|
64
65
|
["length", t],
|
|
65
66
|
["getProperty", n]
|
|
66
67
|
]);
|
|
67
|
-
Object.keys(e).reduce((
|
|
68
|
-
function a(
|
|
69
|
-
const
|
|
70
|
-
return typeof
|
|
71
|
-
if (
|
|
72
|
-
return { target:
|
|
73
|
-
const
|
|
74
|
-
return { target:
|
|
68
|
+
Object.keys(e).reduce((r, s) => (r.set(s, e[s]), r), o);
|
|
69
|
+
function a(r, s) {
|
|
70
|
+
const i = r;
|
|
71
|
+
return typeof s == "number" ? [{ target: i, operator: "length", param: null, value: Number(s) }] : typeof s == "boolean" ? [{ target: i, operator: "getProperty", param: r, value: !!s }] : typeof s == "object" ? Object.keys(s).map((p) => {
|
|
72
|
+
if (p === "length")
|
|
73
|
+
return { target: i, operator: "length", param: null, value: s[p] };
|
|
74
|
+
const m = p, v = s[p];
|
|
75
|
+
return { target: i, operator: "getProperty", param: m, value: v };
|
|
75
76
|
}) : [];
|
|
76
77
|
}
|
|
77
|
-
function
|
|
78
|
-
return Object.keys(
|
|
79
|
-
const
|
|
80
|
-
return
|
|
78
|
+
function c(r) {
|
|
79
|
+
return Object.keys(r).reduce((i, p) => {
|
|
80
|
+
const m = a(p, r[p]);
|
|
81
|
+
return i.push(...m), i;
|
|
81
82
|
}, []);
|
|
82
83
|
}
|
|
83
|
-
function d(
|
|
84
|
-
if (o.has(
|
|
85
|
-
const
|
|
86
|
-
return
|
|
84
|
+
function d(r, s) {
|
|
85
|
+
if (o.has(r.operator)) {
|
|
86
|
+
const i = o.get(r.operator);
|
|
87
|
+
return i && i(r.target, r.param, r.value, s) || !1;
|
|
87
88
|
}
|
|
88
89
|
return !1;
|
|
89
90
|
}
|
|
90
|
-
function
|
|
91
|
-
return
|
|
91
|
+
function u(r, s) {
|
|
92
|
+
return c(r).reduce((m, v) => m && d(v, s), !0);
|
|
92
93
|
}
|
|
93
|
-
function
|
|
94
|
-
const
|
|
95
|
-
return
|
|
94
|
+
function l(r, s) {
|
|
95
|
+
const i = Object.keys(r), p = i.includes("allOf"), m = i.includes("anyOf"), v = p || m, k = (v ? r[v ? p ? "allOf" : "anyOf" : "allOf"] : [r]).map((A) => u(A, s));
|
|
96
|
+
return p ? !k.includes(!1) : k.includes(!0);
|
|
96
97
|
}
|
|
97
|
-
return { parseValueSchema:
|
|
98
|
+
return { parseValueSchema: l };
|
|
98
99
|
}
|
|
99
|
-
const
|
|
100
|
-
|
|
101
|
-
ButtonGroup: { type: "ButtonGroup", name: "按钮组", icon: "ButtonGroup" },
|
|
100
|
+
const f = {
|
|
101
|
+
button: { type: "button", name: "按钮", icon: "Button" },
|
|
102
102
|
"response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
|
|
103
|
-
"response-toolbar-item": { type: "response-toolbar-item", name: "
|
|
103
|
+
"response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
|
|
104
104
|
"content-container": { type: "content-container", name: "容器", icon: "ContentContainer" },
|
|
105
|
-
DisplayField: { type: "DisplayField", name: "标签", icon: "DisplayField" },
|
|
106
105
|
"input-group": { type: "input-group", name: "文本", icon: "TextBox" },
|
|
107
106
|
textarea: { type: "textarea", name: "多行文本", icon: "MultiTextBox" },
|
|
108
107
|
lookup: { type: "lookup", name: "帮助", icon: "LookupEdit" },
|
|
@@ -113,118 +112,47 @@ const p = {
|
|
|
113
112
|
"check-box": { type: "check-box", name: "复选框", icon: "CheckBox" },
|
|
114
113
|
"check-group": { type: "check-group", name: "复选框组", icon: "CheckGroup" },
|
|
115
114
|
"combo-list": { type: "combo-list", name: "下拉列表", icon: "EnumField" },
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
FlowLayout: { type: "FlowLayout", name: "流布局" },
|
|
120
|
-
ResponseLayout: { type: "ResponseLayout", name: "布局容器", icon: "ResponseLayout3" },
|
|
121
|
-
ResponseLayoutItem: { type: "ResponseLayoutItem", name: "布局", icon: "ResponseLayout1" },
|
|
115
|
+
"response-form": { type: "response-form", name: "卡片面板", icon: "Form" },
|
|
116
|
+
"response-layout": { type: "response-layout", name: "布局容器", icon: "ResponseLayout3" },
|
|
117
|
+
"response-layout-item": { type: "response-layout-item", name: "布局", icon: "ResponseLayout1" },
|
|
122
118
|
"tree-grid": { type: "tree-grid", name: "树表格", icon: "TreeGrid" },
|
|
123
|
-
|
|
124
|
-
FieldSet: { type: "FieldSet", name: "分组", icon: "FieldSet" },
|
|
125
|
-
Form: { type: "Form", name: "卡片面板", icon: "Form" },
|
|
126
|
-
QueryForm: { type: "QueryForm", name: "查询面板", icon: "Form" },
|
|
119
|
+
"tree-grid-column": { type: "tree-grid-column", name: "树表格列" },
|
|
127
120
|
"data-grid": { type: "data-grid", name: "表格", icon: "DataGrid" },
|
|
128
121
|
"data-grid-column": { type: "data-grid-column", name: "表格列" },
|
|
129
|
-
|
|
130
|
-
Module: { type: "Module", name: "模块", icon: "Module" },
|
|
122
|
+
module: { type: "Module", name: "模块", icon: "Module" },
|
|
131
123
|
component: { type: "component", name: "组件", icon: "Component" },
|
|
132
|
-
ExternalContainer: { type: "ExternalContainer", name: "外部容器", icon: "ContentContainer" },
|
|
133
|
-
Image: { type: "Image", name: "图像", icon: "Image" },
|
|
134
|
-
ImageUpload: { type: "ImageUpload", name: "图片上传", icon: "imageupload" },
|
|
135
|
-
HiddenContainer: { type: "HiddenContainer", name: "隐藏区域", icon: "ContentContainer" },
|
|
136
|
-
ModalContainer: { type: "ModalContainer", name: "弹窗容器", icon: "ContentContainer" },
|
|
137
|
-
RouteContainer: { type: "RouteContainer", name: "路由区域", icon: "ContentContainer" },
|
|
138
124
|
tabs: { type: "tabs", name: "标签页", icon: "Tab" },
|
|
139
125
|
"tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" },
|
|
140
126
|
"tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮", icon: "Button" },
|
|
141
|
-
|
|
142
|
-
Sidebar: { type: "Sidebar", name: "侧边栏", icon: "Sidebar" },
|
|
143
|
-
HtmlTemplate: { type: "HtmlTemplate", name: "模版容器", icon: "HtmlTemplate" },
|
|
144
|
-
ListView: { type: "ListView", name: "列表", icon: "ListView" },
|
|
145
|
-
RichTextBox: { type: "RichTextBox", name: "富文本", icon: "RichTextBox" },
|
|
146
|
-
TimeSpinner: { type: "TimeSpinner", name: "时间调节器", icon: "TimePicker" },
|
|
147
|
-
TimePicker: { type: "TimePicker", name: "时间选择", icon: "TimePicker" },
|
|
127
|
+
"time-picker": { type: "time-picker", name: "时间选择", icon: "TimePicker" },
|
|
148
128
|
section: { type: "section", name: "分组面板", icon: "Section" },
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
WizardDetail: { type: "WizardDetail", name: "向导详情页" },
|
|
156
|
-
WizardDetailContainer: { type: "WizardDetailContainer", name: "向导详情容器" },
|
|
157
|
-
Wizard: { type: "Wizard", name: "向导", icon: "Wizard" },
|
|
158
|
-
MultiSelect: { type: "MultiSelect", name: "数据分配", icon: "MultiSelect" },
|
|
159
|
-
Steps: { type: "Steps", name: "步骤条", icon: "Steps" },
|
|
160
|
-
avatar: { type: "avatar", name: "头像", icon: "Avatar" },
|
|
161
|
-
ListFilter: { type: "ListFilter", name: "筛选条", icon: "ListFilter" },
|
|
162
|
-
ListNav: { type: "ListNav", name: "列表导航", icon: "ListNav" },
|
|
163
|
-
NumberRange: { type: "NumberRange", name: "数字区间选择", icon: "NumericBox" },
|
|
164
|
-
Scrollspy: { type: "Scrollspy", name: "滚动监听", icon: "Scrollspy" },
|
|
165
|
-
LanguageTextBox: { type: "LanguageTextBox", name: "多语言输入框", icon: "LanguageTextBox" },
|
|
166
|
-
ComponentRef: { type: "ComponentRef", name: "组件引用节点" },
|
|
167
|
-
FileUpload: { type: "FileUpload", name: "附件上传", icon: "FileUpload" },
|
|
168
|
-
FilePreview: { type: "FilePreview", name: "附件预览", icon: "FilePreview" },
|
|
169
|
-
ViewChange: { type: "ViewChange", name: "多视图切换", icon: "Button" },
|
|
170
|
-
MultiViewContainer: { type: "MultiViewContainer", name: "多视图", icon: "MultiViewContainer" },
|
|
171
|
-
MultiViewItem: { type: "MultiViewItem", name: "多视图项", dependentParentControl: "MultiViewContainer" },
|
|
172
|
-
Footer: { type: "Footer", name: "页脚" },
|
|
173
|
-
DiscussionEditor: { type: "DiscussionEditor", name: "评论编辑区", icon: "DiscussionEditor" },
|
|
174
|
-
DiscussionList: { type: "DiscussionList", name: "评论列表", icon: "DiscussionList" },
|
|
175
|
-
NavTab: { type: "NavTab", name: "标签类导航", icon: "NavTab" },
|
|
176
|
-
Tags: { type: "Tags", name: "标记组", icon: "Tags" },
|
|
177
|
-
Portlet: { type: "Portlet", name: "小部件", icon: "dingzhi" },
|
|
129
|
+
"section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" },
|
|
130
|
+
"section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" },
|
|
131
|
+
splitter: { type: "splitter", name: "分栏面板", icon: "Splitter" },
|
|
132
|
+
"splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" },
|
|
133
|
+
"component-ref": { type: "component-ref", name: "组件引用节点" },
|
|
134
|
+
uploader: { type: "uploader", name: "附件上传", icon: "FileUpload" },
|
|
178
135
|
"page-header": { type: "page-header", name: "页头", icon: "Header" },
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
TabToolbar: { type: "TabToolbar", name: "标签页工具栏", icon: "TabToolbar" },
|
|
188
|
-
HeaderToolBar: { type: "HeaderToolBar", name: "头部组件工具栏", icon: "HeaderToolBar" },
|
|
189
|
-
ModalFooterToolBar: { type: "ModalFooterToolBar", name: "底部组件工具栏", icon: "ModalFooterToolBar" },
|
|
190
|
-
HeaderToolBarItem: { type: "HeaderToolBarItem", name: "头部组件工具栏按钮", icon: "HeaderToolBarItem" },
|
|
191
|
-
ModalFooterToolBarItem: { type: "ModalFooterToolBarItem", name: "底部组件工具栏按钮", icon: "ModalFooterToolBarItem" },
|
|
192
|
-
OrganizationSelector: { type: "OrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
193
|
-
AdminOrganizationSelector: { type: "AdminOrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
194
|
-
EmployeeSelector: { type: "EmployeeSelector", name: "人员选择", icon: "PersonnelSelector" },
|
|
195
|
-
OaRelation: { type: "OaRelation", name: "关联行政审批", icon: "TextBox" },
|
|
196
|
-
CitySelector: { type: "CitySelector", name: "城市选择", icon: "CitySelector" },
|
|
197
|
-
ExtIntergration: { type: "ExtIntergration", name: "外部服务集成", icon: "ViewModel" },
|
|
198
|
-
AppointmentCalendar: { type: "AppointmentCalendar", name: "预约日历", icon: "DateBox" },
|
|
199
|
-
/** 查询类 start */
|
|
200
|
-
Charts: { type: "Charts", name: "图表", icon: "Charts" },
|
|
201
|
-
QdpFramework: { type: "QdpFramework", name: "查询结果工具栏", icon: "QdpFramework" },
|
|
202
|
-
SpreadSheet: { type: "SpreadSheet", name: "查询表格控件", icon: "Charts" },
|
|
203
|
-
QdpConditionDialog: { type: "QdpConditionDialog", name: "查询筛选对话框", icon: "ContentContainer" },
|
|
204
|
-
QdpConditionDialogTab: { type: "QdpConditionDialogTab", name: "查询筛选标签页", icon: "Tab" },
|
|
205
|
-
/** 查询类 end */
|
|
206
|
-
/** 审批类 start */
|
|
207
|
-
ApprovalLogs: { type: "ApprovalLogs", name: "审批记录", icon: "ApprovalLogs" },
|
|
208
|
-
ApprovalComments: { type: "ApprovalComments", name: "审批意见", icon: "shenpiyijian" }
|
|
209
|
-
/** 审批类 end */
|
|
210
|
-
}, ge = {}, ve = {};
|
|
211
|
-
fe();
|
|
212
|
-
function he(e, t, n = /* @__PURE__ */ new Map(), o = (d, m, s) => m, a = {}, l = (d) => d) {
|
|
213
|
-
return R[t.title] = t, _[t.title] = o, ge[t.title] = a, ve[t.title] = l, (d = {}) => {
|
|
214
|
-
const m = ye(d, t, n), s = Object.keys(e).reduce((i, u) => (i[u] = e[u].default, i), {});
|
|
215
|
-
return Object.assign(s, m);
|
|
136
|
+
"page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
|
|
137
|
+
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
|
|
138
|
+
}, he = {}, be = {};
|
|
139
|
+
ge();
|
|
140
|
+
function Ce(e, t, n = /* @__PURE__ */ new Map(), o = (d, u, l) => u, a = {}, c = (d) => d) {
|
|
141
|
+
return X[t.title] = t, Y[t.title] = o, he[t.title] = a, be[t.title] = c, (d = {}) => {
|
|
142
|
+
const u = ve(d, t, n), l = Object.keys(e).reduce((r, s) => (r[s] = e[s].default, r), {});
|
|
143
|
+
return Object.assign(l, u);
|
|
216
144
|
};
|
|
217
145
|
}
|
|
218
|
-
function
|
|
146
|
+
function we(e, t) {
|
|
219
147
|
return { customClass: t.class, customStyle: t.style };
|
|
220
148
|
}
|
|
221
|
-
const
|
|
222
|
-
["appearance",
|
|
149
|
+
const Be = /* @__PURE__ */ new Map([
|
|
150
|
+
["appearance", we]
|
|
223
151
|
]);
|
|
224
152
|
function Te(e, t, n) {
|
|
225
153
|
return t;
|
|
226
154
|
}
|
|
227
|
-
const
|
|
155
|
+
const ke = "https://json-schema.org/draft/2020-12/schema", Me = "https://farris-design.gitee.io/input-group.schema.json", xe = "input-group", Se = "A Farris Input Component", Pe = "object", Ae = {
|
|
228
156
|
id: {
|
|
229
157
|
description: "The unique identifier for a Input Group",
|
|
230
158
|
type: "string"
|
|
@@ -426,18 +354,18 @@ const we = "https://json-schema.org/draft/2020-12/schema", Be = "https://farris-
|
|
|
426
354
|
type: "string",
|
|
427
355
|
default: ""
|
|
428
356
|
}
|
|
429
|
-
},
|
|
357
|
+
}, Ee = [
|
|
430
358
|
"id",
|
|
431
359
|
"type"
|
|
432
|
-
],
|
|
433
|
-
$schema:
|
|
434
|
-
$id:
|
|
435
|
-
title:
|
|
436
|
-
description:
|
|
437
|
-
type:
|
|
438
|
-
properties:
|
|
439
|
-
required:
|
|
440
|
-
},
|
|
360
|
+
], Fe = {
|
|
361
|
+
$schema: ke,
|
|
362
|
+
$id: Me,
|
|
363
|
+
title: xe,
|
|
364
|
+
description: Se,
|
|
365
|
+
type: Pe,
|
|
366
|
+
properties: Ae,
|
|
367
|
+
required: Ee
|
|
368
|
+
}, W = {
|
|
441
369
|
/** 是否自动完成 */
|
|
442
370
|
autocomplete: { Type: String, default: "off" },
|
|
443
371
|
/** 自定义CLASS */
|
|
@@ -503,118 +431,118 @@ const we = "https://json-schema.org/draft/2020-12/schema", Be = "https://farris-
|
|
|
503
431
|
* - input: 输入时更新
|
|
504
432
|
*/
|
|
505
433
|
updateOn: { type: String, default: "blur" }
|
|
506
|
-
},
|
|
507
|
-
function
|
|
508
|
-
const a =
|
|
434
|
+
}, R = Ce(W, Fe, Be, Te);
|
|
435
|
+
function De(e, t, n, o) {
|
|
436
|
+
const a = h(e.disabled), c = h(!1), d = h("text"), u = h(e.showBorder), l = h(e.textAlign), r = h(e.updateOn), s = y(() => e.editable || !e.readonly), i = y(() => e.editable && !e.disabled && !e.readonly), p = y(() => !e.disabled && c.value), m = y(() => n.value === "" || n.value === null || n.value === void 0), v = y(() => (e.disabled || e.readonly) && !e.forcePlaceholder ? "" : e.placeholder), w = y(() => e.readonly || !e.editable), x = y(() => e.enableTitle ? n.value : ""), k = y(() => ({
|
|
509
437
|
"form-control": !0,
|
|
510
438
|
"f-utils-fill": !0,
|
|
511
|
-
"text-left":
|
|
512
|
-
"text-center":
|
|
513
|
-
"text-right":
|
|
514
|
-
})),
|
|
515
|
-
const
|
|
439
|
+
"text-left": l.value === "left",
|
|
440
|
+
"text-center": l.value === "center",
|
|
441
|
+
"text-right": l.value === "right"
|
|
442
|
+
})), S = y(() => {
|
|
443
|
+
const g = {
|
|
516
444
|
"f-cmp-inputgroup": !0,
|
|
517
445
|
"input-group": !0,
|
|
518
446
|
"f-state-disable": a.value,
|
|
519
|
-
"f-state-editable":
|
|
520
|
-
"f-state-readonly":
|
|
521
|
-
"f-state-focus":
|
|
447
|
+
"f-state-editable": i.value,
|
|
448
|
+
"f-state-readonly": w.value,
|
|
449
|
+
"f-state-focus": p.value
|
|
522
450
|
};
|
|
523
|
-
return (e.customClass || "").split(" ").reduce((
|
|
524
|
-
}),
|
|
525
|
-
function M(
|
|
526
|
-
n.value =
|
|
451
|
+
return (e.customClass || "").split(" ").reduce((H, oe) => (H[oe] = !0, H), g), g;
|
|
452
|
+
}), A = y(() => u.value ? "" : "border-width : 0 ");
|
|
453
|
+
function M(g, E = !0) {
|
|
454
|
+
n.value = g, o.value !== g && (o.value = g), E && t.emit("change", g), t.emit("update:modelValue", g), t.emit("update:value", g);
|
|
527
455
|
}
|
|
528
|
-
|
|
456
|
+
D(
|
|
529
457
|
() => e.modelValue,
|
|
530
|
-
(
|
|
531
|
-
|
|
458
|
+
(g, E) => {
|
|
459
|
+
g !== E && (n.value = g, o.value = g);
|
|
532
460
|
}
|
|
533
|
-
),
|
|
534
|
-
|
|
461
|
+
), D(() => e.disabled, (g, E) => {
|
|
462
|
+
g !== E && (a.value = g);
|
|
535
463
|
});
|
|
536
|
-
function
|
|
537
|
-
return
|
|
464
|
+
function V(g) {
|
|
465
|
+
return c.value = !1, t.emit("blur", g), g.stopPropagation(), !1;
|
|
538
466
|
}
|
|
539
|
-
function
|
|
540
|
-
t.emit("click",
|
|
467
|
+
function b(g) {
|
|
468
|
+
t.emit("click", g);
|
|
541
469
|
}
|
|
542
|
-
function C(
|
|
543
|
-
e.disabled || (
|
|
470
|
+
function C(g) {
|
|
471
|
+
e.disabled || (u.value && (c.value = !0), s.value && t.emit("focus", g));
|
|
544
472
|
}
|
|
545
|
-
function
|
|
546
|
-
t.emit("input",
|
|
547
|
-
const
|
|
548
|
-
o.value =
|
|
473
|
+
function B(g) {
|
|
474
|
+
t.emit("input", g.target.value);
|
|
475
|
+
const E = g.target.value;
|
|
476
|
+
o.value = E, r.value === "input" && (t.emit("update:modelValue", E), t.emit("update:value", E));
|
|
549
477
|
}
|
|
550
|
-
function
|
|
551
|
-
t.emit("keydown",
|
|
478
|
+
function O(g) {
|
|
479
|
+
t.emit("keydown", g);
|
|
552
480
|
}
|
|
553
|
-
function
|
|
554
|
-
t.emit("keyup",
|
|
481
|
+
function G(g) {
|
|
482
|
+
t.emit("keyup", g);
|
|
555
483
|
}
|
|
556
|
-
function
|
|
557
|
-
|
|
484
|
+
function F(g) {
|
|
485
|
+
g.target.tagName !== "INPUT" && g.preventDefault(), g.stopPropagation();
|
|
558
486
|
}
|
|
559
|
-
function
|
|
560
|
-
if (
|
|
561
|
-
const
|
|
562
|
-
|
|
487
|
+
function U(g) {
|
|
488
|
+
if (r.value === "blur") {
|
|
489
|
+
const E = g.target.value;
|
|
490
|
+
g.stopPropagation(), M(E);
|
|
563
491
|
}
|
|
564
492
|
}
|
|
565
493
|
return {
|
|
566
494
|
changeTextBoxValue: M,
|
|
567
495
|
disabled: a,
|
|
568
496
|
displayText: o,
|
|
569
|
-
editable:
|
|
570
|
-
hasFocused:
|
|
571
|
-
inputGroupClass:
|
|
497
|
+
editable: i,
|
|
498
|
+
hasFocused: p,
|
|
499
|
+
inputGroupClass: S,
|
|
572
500
|
inputType: d,
|
|
573
|
-
isEmpty:
|
|
501
|
+
isEmpty: m,
|
|
574
502
|
modelValue: n,
|
|
575
|
-
readonly:
|
|
576
|
-
onBlur:
|
|
577
|
-
onClick:
|
|
503
|
+
readonly: w,
|
|
504
|
+
onBlur: V,
|
|
505
|
+
onClick: b,
|
|
578
506
|
onFocus: C,
|
|
579
|
-
onInput:
|
|
580
|
-
onKeydown:
|
|
581
|
-
onKeyup:
|
|
582
|
-
onMousedown:
|
|
583
|
-
onTextBoxValueChange:
|
|
584
|
-
placeholder:
|
|
585
|
-
textBoxClass:
|
|
586
|
-
textBoxTitle:
|
|
587
|
-
inputGroupStyle:
|
|
507
|
+
onInput: B,
|
|
508
|
+
onKeydown: O,
|
|
509
|
+
onKeyup: G,
|
|
510
|
+
onMousedown: F,
|
|
511
|
+
onTextBoxValueChange: U,
|
|
512
|
+
placeholder: v,
|
|
513
|
+
textBoxClass: k,
|
|
514
|
+
textBoxTitle: x,
|
|
515
|
+
inputGroupStyle: A
|
|
588
516
|
};
|
|
589
517
|
}
|
|
590
|
-
function
|
|
591
|
-
const a =
|
|
592
|
-
|
|
593
|
-
const
|
|
518
|
+
function Ve(e, t, n, o) {
|
|
519
|
+
const a = h(e.disabled), c = h(!1), d = h("text"), u = h(e.showBorder), l = h(e.textAlign);
|
|
520
|
+
y(() => e.editable || !e.readonly);
|
|
521
|
+
const r = y(() => e.editable && !e.disabled && !e.readonly), s = y(() => !e.disabled && c.value), i = y(() => n.value === "" || n.value === null || n.value === void 0), p = y(() => e.placeholder), m = y(() => e.readonly || !e.editable), v = y(() => e.enableTitle ? n.value : ""), w = y(() => ({
|
|
594
522
|
"form-control": !0,
|
|
595
523
|
// 'f-utils-fill': true,
|
|
596
|
-
"text-left":
|
|
597
|
-
"text-center":
|
|
598
|
-
"text-right":
|
|
599
|
-
})),
|
|
524
|
+
"text-left": l.value === "left",
|
|
525
|
+
"text-center": l.value === "center",
|
|
526
|
+
"text-right": l.value === "right"
|
|
527
|
+
})), x = y(() => ({
|
|
600
528
|
"f-cmp-inputgroup": !0,
|
|
601
529
|
"input-group": !0,
|
|
602
530
|
"f-state-disable": !0,
|
|
603
531
|
"f-state-editable": !1,
|
|
604
532
|
"f-state-readonly": !0
|
|
605
533
|
// 'f-state-focus': hasFocused.value
|
|
606
|
-
})),
|
|
534
|
+
})), k = y(() => u.value ? "" : "border-width : 0 ");
|
|
607
535
|
return {
|
|
608
536
|
// changeTextBoxValue,
|
|
609
537
|
disabled: a,
|
|
610
538
|
displayText: o,
|
|
611
|
-
editable:
|
|
612
|
-
hasFocused:
|
|
613
|
-
inputGroupClass:
|
|
539
|
+
editable: r,
|
|
540
|
+
hasFocused: s,
|
|
541
|
+
inputGroupClass: x,
|
|
614
542
|
inputType: d,
|
|
615
|
-
isEmpty:
|
|
543
|
+
isEmpty: i,
|
|
616
544
|
modelValue: n,
|
|
617
|
-
readonly:
|
|
545
|
+
readonly: m,
|
|
618
546
|
// onBlur,
|
|
619
547
|
// onClick,
|
|
620
548
|
// onFocus,
|
|
@@ -623,40 +551,40 @@ function De(e, t, n, o) {
|
|
|
623
551
|
// onKeyup,
|
|
624
552
|
// onMousedown,
|
|
625
553
|
// onTextBoxValueChange,
|
|
626
|
-
placeholder:
|
|
627
|
-
textBoxClass:
|
|
628
|
-
textBoxTitle:
|
|
629
|
-
inputGroupStyle:
|
|
554
|
+
placeholder: p,
|
|
555
|
+
textBoxClass: w,
|
|
556
|
+
textBoxTitle: v,
|
|
557
|
+
inputGroupStyle: k
|
|
630
558
|
};
|
|
631
559
|
}
|
|
632
|
-
function
|
|
633
|
-
const o =
|
|
634
|
-
function
|
|
635
|
-
o.value =
|
|
560
|
+
function K(e, t, n) {
|
|
561
|
+
const o = h(!1), a = y(() => e.enableClear && !e.readonly && !e.disabled), { changeTextBoxValue: c, displayText: d, hasFocused: u, isEmpty: l } = n;
|
|
562
|
+
function r(w) {
|
|
563
|
+
o.value = w;
|
|
636
564
|
}
|
|
637
|
-
|
|
638
|
-
|
|
565
|
+
D(d, () => {
|
|
566
|
+
u != null && u.value ? r(!!(d != null && d.value)) : r(!1);
|
|
639
567
|
});
|
|
640
|
-
const
|
|
568
|
+
const s = y(() => ({
|
|
641
569
|
"input-group-text": !0,
|
|
642
570
|
"input-group-clear": !0
|
|
643
|
-
})),
|
|
571
|
+
})), i = y(() => ({
|
|
644
572
|
width: "24px",
|
|
645
573
|
display: o.value ? "flex" : "none"
|
|
646
574
|
}));
|
|
647
|
-
function
|
|
648
|
-
|
|
575
|
+
function p(w) {
|
|
576
|
+
w.stopPropagation(), a.value && (c("", !0), r(!o.value), t.emit("clear"));
|
|
649
577
|
}
|
|
650
|
-
function
|
|
651
|
-
a.value && !
|
|
578
|
+
function m(w) {
|
|
579
|
+
a.value && !l.value && r(!0);
|
|
652
580
|
}
|
|
653
|
-
function
|
|
654
|
-
a.value &&
|
|
581
|
+
function v(w) {
|
|
582
|
+
a.value && r(!1);
|
|
655
583
|
}
|
|
656
|
-
return { clearButtonClass:
|
|
584
|
+
return { clearButtonClass: s, clearButtonStyle: i, hasShownClearButton: o, onClearValue: p, onMouseEnter: m, onMouseLeave: v, shouldShowClearButton: a };
|
|
657
585
|
}
|
|
658
|
-
const
|
|
659
|
-
function
|
|
586
|
+
const Oe = ["moz", "ms", "webkit"];
|
|
587
|
+
function Ne() {
|
|
660
588
|
let e = 0;
|
|
661
589
|
return (t) => {
|
|
662
590
|
const n = (/* @__PURE__ */ new Date()).getTime(), o = Math.max(0, 16 - (n - e)), a = setTimeout(() => {
|
|
@@ -665,430 +593,492 @@ function Oe() {
|
|
|
665
593
|
return e = n + o, a;
|
|
666
594
|
};
|
|
667
595
|
}
|
|
668
|
-
function
|
|
596
|
+
function je() {
|
|
669
597
|
if (typeof window > "u")
|
|
670
598
|
return () => 0;
|
|
671
599
|
if (window.requestAnimationFrame)
|
|
672
600
|
return window.requestAnimationFrame.bind(window);
|
|
673
|
-
const e =
|
|
674
|
-
return e ? window[`${e}RequestAnimationFrame`] :
|
|
601
|
+
const e = Oe.filter((t) => `${t}RequestAnimationFrame` in window)[0];
|
|
602
|
+
return e ? window[`${e}RequestAnimationFrame`] : Ne();
|
|
675
603
|
}
|
|
676
|
-
|
|
677
|
-
const
|
|
604
|
+
je();
|
|
605
|
+
const Ge = (e) => {
|
|
678
606
|
const t = e;
|
|
679
607
|
return t.install = function(n) {
|
|
680
608
|
n.component(t.name, e);
|
|
681
609
|
}, e;
|
|
682
610
|
};
|
|
683
|
-
function
|
|
684
|
-
const n =
|
|
685
|
-
return { appendedButtonClass:
|
|
611
|
+
function ee(e, t) {
|
|
612
|
+
const n = h(e.groupText), o = y(() => e.showButtonWhenDisabled && (e.readonly || e.disabled)), a = y(() => e.enableClear || !!e.groupText);
|
|
613
|
+
return { appendedButtonClass: y(() => ({
|
|
686
614
|
"input-group-append": !0,
|
|
687
615
|
"append-force-show": o.value
|
|
688
616
|
})), appendedContent: n, shouldShowAppendedButton: a };
|
|
689
617
|
}
|
|
690
|
-
function
|
|
691
|
-
const { appendedContent: a } = o,
|
|
692
|
-
|
|
693
|
-
d.value && (n.value =
|
|
618
|
+
function te(e, t, n, o) {
|
|
619
|
+
const { appendedContent: a } = o, c = h(e.enableViewPassword), d = y(() => e.type === "password"), u = '<span class="f-icon f-icon-eye" style="color: rgb(56, 143, 255);"></span>', l = '<span class="f-icon f-icon-eye"></span>', r = h(!1);
|
|
620
|
+
D(() => [e.readonly, e.disabled], ([p, m]) => {
|
|
621
|
+
d.value && (n.value = p || m ? "password" : n.value, a.value = p || m ? l : a.value);
|
|
694
622
|
});
|
|
695
|
-
function
|
|
696
|
-
return
|
|
623
|
+
function s() {
|
|
624
|
+
return r.value = !r.value, n.value = r.value ? "text" : "password", a.value = r.value ? u : l, !1;
|
|
697
625
|
}
|
|
698
|
-
function
|
|
699
|
-
n.value = d.value ? "password" : "text", a.value = d.value ?
|
|
626
|
+
function i() {
|
|
627
|
+
n.value = d.value ? "password" : "text", a.value = d.value ? c.value ? l : "" : a.value;
|
|
700
628
|
}
|
|
701
|
-
return
|
|
629
|
+
return i(), { isPassword: d, onClickAppendedButton: s };
|
|
702
630
|
}
|
|
703
|
-
function
|
|
704
|
-
const o =
|
|
631
|
+
function Le(e, t, n) {
|
|
632
|
+
const o = h(), {
|
|
705
633
|
onBlurTextBox: a,
|
|
706
|
-
onFocusTextBox:
|
|
634
|
+
onFocusTextBox: c,
|
|
707
635
|
onInput: d,
|
|
708
|
-
onKeyDown:
|
|
709
|
-
textBoxValue:
|
|
710
|
-
} = n,
|
|
636
|
+
onKeyDown: u,
|
|
637
|
+
textBoxValue: l
|
|
638
|
+
} = n, r = y(() => e.disabled || e.readonly || !e.editable ? "" : e.placeholder), s = y(() => ({
|
|
711
639
|
"form-control": !0,
|
|
712
640
|
"f-utils-fill": !0
|
|
713
|
-
})),
|
|
641
|
+
})), i = y(() => ({
|
|
714
642
|
"text-align": e.textAlign
|
|
715
643
|
}));
|
|
716
|
-
function
|
|
717
|
-
|
|
644
|
+
function p(w) {
|
|
645
|
+
w.stopPropagation();
|
|
718
646
|
}
|
|
719
|
-
function
|
|
647
|
+
function m() {
|
|
720
648
|
e.selectOnCreated, e.focusOnCreated;
|
|
721
649
|
}
|
|
722
|
-
async function
|
|
723
|
-
|
|
650
|
+
async function v(w) {
|
|
651
|
+
c(w), await z, m();
|
|
724
652
|
}
|
|
725
|
-
return
|
|
726
|
-
await z,
|
|
727
|
-
}), () =>
|
|
653
|
+
return j(async () => {
|
|
654
|
+
await z, m();
|
|
655
|
+
}), () => T("input", {
|
|
728
656
|
ref: o,
|
|
729
|
-
class:
|
|
730
|
-
style:
|
|
657
|
+
class: s.value,
|
|
658
|
+
style: i.value,
|
|
731
659
|
type: "text",
|
|
732
|
-
value:
|
|
660
|
+
value: l.value,
|
|
733
661
|
disabled: e.disabled,
|
|
734
662
|
readonly: e.readonly || !e.editable,
|
|
735
|
-
placeholder:
|
|
663
|
+
placeholder: r.value,
|
|
736
664
|
onBlur: a,
|
|
737
|
-
onChange:
|
|
738
|
-
onFocus:
|
|
665
|
+
onChange: p,
|
|
666
|
+
onFocus: v,
|
|
739
667
|
onInput: d,
|
|
740
|
-
onKeydown:
|
|
668
|
+
onKeydown: u
|
|
741
669
|
}, null);
|
|
742
670
|
}
|
|
743
|
-
function
|
|
671
|
+
function $e(e, t, n) {
|
|
744
672
|
const {
|
|
745
673
|
canDownward: o,
|
|
746
674
|
canUpward: a,
|
|
747
|
-
onClickDownButton:
|
|
675
|
+
onClickDownButton: c,
|
|
748
676
|
onClickUpButton: d
|
|
749
|
-
} = n,
|
|
677
|
+
} = n, u = y(() => ({
|
|
750
678
|
"input-group-append": !0,
|
|
751
679
|
"btn-group": !0,
|
|
752
680
|
"btn-group-number": !0
|
|
753
|
-
})),
|
|
681
|
+
})), l = y(() => ({
|
|
754
682
|
btn: !0,
|
|
755
683
|
"btn-secondary": !0,
|
|
756
684
|
"btn-number-flag": !0
|
|
757
|
-
})),
|
|
685
|
+
})), r = y(() => ({
|
|
758
686
|
cursor: a() ? "pointer" : "not-allowed",
|
|
759
687
|
"margin-left": 0
|
|
760
|
-
})),
|
|
688
|
+
})), s = y(() => ({
|
|
761
689
|
cursor: o() ? "pointer" : "not-allowed",
|
|
762
690
|
"margin-left": 0
|
|
763
691
|
}));
|
|
764
|
-
return () =>
|
|
765
|
-
class:
|
|
766
|
-
}, [
|
|
692
|
+
return () => T("div", {
|
|
693
|
+
class: u.value
|
|
694
|
+
}, [T("button", {
|
|
767
695
|
title: "upButton",
|
|
768
|
-
class:
|
|
769
|
-
style:
|
|
696
|
+
class: l.value,
|
|
697
|
+
style: r.value,
|
|
770
698
|
onClick: d,
|
|
771
699
|
disabled: !a()
|
|
772
|
-
}, [
|
|
700
|
+
}, [T("span", {
|
|
773
701
|
class: "f-icon f-icon-arrow-chevron-up number-arrow-chevron"
|
|
774
|
-
}, null)]),
|
|
702
|
+
}, null)]), T("button", {
|
|
775
703
|
title: "downButton",
|
|
776
|
-
class:
|
|
777
|
-
style:
|
|
778
|
-
onClick:
|
|
704
|
+
class: l.value,
|
|
705
|
+
style: s.value,
|
|
706
|
+
onClick: c,
|
|
779
707
|
disabled: !o()
|
|
780
|
-
}, [
|
|
708
|
+
}, [T("span", {
|
|
781
709
|
class: "f-icon f-icon-arrow-chevron-down number-arrow-chevron"
|
|
782
710
|
}, null)])]);
|
|
783
711
|
}
|
|
784
|
-
function
|
|
785
|
-
const n =
|
|
786
|
-
displayValue:
|
|
787
|
-
modelValue:
|
|
788
|
-
getRealValue:
|
|
789
|
-
} = n,
|
|
790
|
-
format:
|
|
712
|
+
function Ue(e, t) {
|
|
713
|
+
const n = ce(e, t), o = de(e, t, n), a = pe(e, t, o, n), c = fe(e, t, o, n, a), d = $e(e, t, a), {
|
|
714
|
+
displayValue: u,
|
|
715
|
+
modelValue: l,
|
|
716
|
+
getRealValue: r
|
|
717
|
+
} = n, s = Le(e, t, c), {
|
|
718
|
+
format: i
|
|
791
719
|
} = o, {
|
|
792
|
-
isFocus:
|
|
793
|
-
} =
|
|
794
|
-
return
|
|
795
|
-
const
|
|
796
|
-
|
|
797
|
-
}),
|
|
798
|
-
const
|
|
799
|
-
|
|
800
|
-
}),
|
|
801
|
-
|
|
802
|
-
}),
|
|
803
|
-
|
|
804
|
-
}), () =>
|
|
720
|
+
isFocus: p
|
|
721
|
+
} = c, m = y(() => !e.disabled && !e.readonly);
|
|
722
|
+
return j(() => {
|
|
723
|
+
const v = r(e.modelValue);
|
|
724
|
+
u.value = i(v);
|
|
725
|
+
}), D(() => [e.value], ([v]) => {
|
|
726
|
+
const w = r(v);
|
|
727
|
+
l.value = w, u.value = i(w);
|
|
728
|
+
}), D(() => [e.modelValue], ([v]) => {
|
|
729
|
+
v !== l.value && (l.value = v, !p.value && (u.value = i(r(v))));
|
|
730
|
+
}), D(() => [e.precision, e.useThousands, e.prefix, e.suffix, e.showZero], () => {
|
|
731
|
+
u.value = i(l.value);
|
|
732
|
+
}), () => T("div", {
|
|
805
733
|
class: "input-group f-state-hover flex-row f-cmp-number-spinner"
|
|
806
|
-
}, [
|
|
734
|
+
}, [s(), m.value && d()]);
|
|
807
735
|
}
|
|
808
|
-
function
|
|
809
|
-
const a =
|
|
810
|
-
isPassword:
|
|
811
|
-
} = n,
|
|
812
|
-
disabled:
|
|
813
|
-
displayText:
|
|
814
|
-
inputType:
|
|
815
|
-
onBlur:
|
|
816
|
-
onFocus:
|
|
817
|
-
onInput:
|
|
818
|
-
onClick:
|
|
819
|
-
onKeydown:
|
|
820
|
-
onKeyup:
|
|
736
|
+
function Ie(e, t, n, o) {
|
|
737
|
+
const a = h(), c = h(e.autocomplete), d = h(e.enableTitle), {
|
|
738
|
+
isPassword: u
|
|
739
|
+
} = n, l = h(e.minLength), r = h(e.maxLength), s = h(e.tabIndex), {
|
|
740
|
+
disabled: i,
|
|
741
|
+
displayText: p,
|
|
742
|
+
inputType: m,
|
|
743
|
+
onBlur: v,
|
|
744
|
+
onFocus: w,
|
|
745
|
+
onInput: x,
|
|
746
|
+
onClick: k,
|
|
747
|
+
onKeydown: S,
|
|
748
|
+
onKeyup: A,
|
|
821
749
|
onMousedown: M,
|
|
822
|
-
onTextBoxValueChange:
|
|
823
|
-
readonly:
|
|
750
|
+
onTextBoxValueChange: V,
|
|
751
|
+
readonly: b,
|
|
824
752
|
placeholder: C,
|
|
825
|
-
textBoxClass:
|
|
826
|
-
textBoxTitle:
|
|
753
|
+
textBoxClass: B,
|
|
754
|
+
textBoxTitle: O
|
|
827
755
|
} = o;
|
|
828
|
-
return
|
|
756
|
+
return j(() => {
|
|
829
757
|
e.selectOnCreated, e.focusOnCreated;
|
|
830
|
-
}), () =>
|
|
758
|
+
}), () => T("input", {
|
|
831
759
|
ref: a,
|
|
832
760
|
name: "input-group-value",
|
|
833
|
-
autocomplete:
|
|
834
|
-
class:
|
|
835
|
-
disabled:
|
|
836
|
-
maxlength:
|
|
837
|
-
minlength:
|
|
761
|
+
autocomplete: c.value,
|
|
762
|
+
class: B.value,
|
|
763
|
+
disabled: i == null ? void 0 : i.value,
|
|
764
|
+
maxlength: r.value,
|
|
765
|
+
minlength: l.value,
|
|
838
766
|
placeholder: C.value,
|
|
839
|
-
readonly:
|
|
840
|
-
tabindex:
|
|
841
|
-
title: d.value && !
|
|
842
|
-
type:
|
|
843
|
-
value:
|
|
844
|
-
onBlur:
|
|
845
|
-
onClick:
|
|
846
|
-
onChange:
|
|
847
|
-
onFocus:
|
|
848
|
-
onInput:
|
|
849
|
-
onKeydown:
|
|
850
|
-
onKeyup:
|
|
767
|
+
readonly: b == null ? void 0 : b.value,
|
|
768
|
+
tabindex: s.value,
|
|
769
|
+
title: d.value && !u.value ? O.value : "",
|
|
770
|
+
type: m.value,
|
|
771
|
+
value: p == null ? void 0 : p.value,
|
|
772
|
+
onBlur: v,
|
|
773
|
+
onClick: k,
|
|
774
|
+
onChange: V,
|
|
775
|
+
onFocus: w,
|
|
776
|
+
onInput: x,
|
|
777
|
+
onKeydown: S,
|
|
778
|
+
onKeyup: A,
|
|
851
779
|
onMousedown: M
|
|
852
780
|
}, null);
|
|
853
781
|
}
|
|
854
|
-
function
|
|
855
|
-
const n =
|
|
782
|
+
function qe(e, t) {
|
|
783
|
+
const n = y(() => e.useExtendInfo && !!e.extendInfo), o = ie({
|
|
856
784
|
content: e.extendInfo
|
|
857
785
|
});
|
|
858
786
|
function a() {
|
|
859
787
|
t.emit("updateExtendInfo");
|
|
860
788
|
}
|
|
861
|
-
return () => n.value &&
|
|
789
|
+
return () => n.value && le(T("span", {
|
|
862
790
|
class: "input-group-before-tips",
|
|
863
791
|
onMouseenter: a
|
|
864
|
-
}, [
|
|
792
|
+
}, [T("i", {
|
|
865
793
|
class: "f-icon f-icon-info-circle"
|
|
866
|
-
}, null),
|
|
794
|
+
}, null), T("b", {
|
|
867
795
|
class: "tips-arrow"
|
|
868
|
-
}, null)]), [[
|
|
796
|
+
}, null)]), [[ue("tooltip"), o]]);
|
|
869
797
|
}
|
|
870
|
-
function
|
|
798
|
+
function ne(e, t, n, o, a) {
|
|
871
799
|
const {
|
|
872
|
-
appendedButtonClass:
|
|
800
|
+
appendedButtonClass: c,
|
|
873
801
|
appendedContent: d
|
|
874
|
-
} = n,
|
|
875
|
-
clearButtonClass:
|
|
876
|
-
clearButtonStyle:
|
|
877
|
-
onClearValue:
|
|
878
|
-
shouldShowClearButton:
|
|
802
|
+
} = n, u = y(() => e.showButtonWhenDisabled && (!e.editable || !e.readonly) && !e.disabled), l = y(() => d.value && !t.slots.groupTextTemplate), r = y(() => !!t.slots.groupTextTemplate), {
|
|
803
|
+
clearButtonClass: s,
|
|
804
|
+
clearButtonStyle: i,
|
|
805
|
+
onClearValue: p,
|
|
806
|
+
shouldShowClearButton: m
|
|
879
807
|
} = o;
|
|
880
|
-
function
|
|
881
|
-
return
|
|
808
|
+
function v() {
|
|
809
|
+
return T("span", {
|
|
882
810
|
id: "clearIcon",
|
|
883
|
-
class:
|
|
884
|
-
style:
|
|
885
|
-
onClick: (C) =>
|
|
886
|
-
}, [
|
|
811
|
+
class: s.value,
|
|
812
|
+
style: i.value,
|
|
813
|
+
onClick: (C) => p(C)
|
|
814
|
+
}, [T("i", {
|
|
887
815
|
class: "f-icon modal_close"
|
|
888
816
|
}, null)]);
|
|
889
817
|
}
|
|
890
|
-
function
|
|
818
|
+
function w(C) {
|
|
891
819
|
t.emit("iconMouseEnter", C);
|
|
892
820
|
}
|
|
893
|
-
function
|
|
821
|
+
function x(C) {
|
|
894
822
|
t.emit("iconMouseLeave", C);
|
|
895
823
|
}
|
|
896
|
-
function
|
|
897
|
-
|
|
824
|
+
function k(C) {
|
|
825
|
+
u.value && t.emit("clickHandle", {
|
|
898
826
|
originalEvent: C
|
|
899
827
|
}), C.stopPropagation();
|
|
900
828
|
}
|
|
901
|
-
const
|
|
902
|
-
function
|
|
903
|
-
return
|
|
829
|
+
const S = e.type === "password" ? a.onClickAppendedButton : k;
|
|
830
|
+
function A() {
|
|
831
|
+
return T("span", {
|
|
904
832
|
class: "input-group-text",
|
|
905
|
-
onMouseenter: (C) =>
|
|
906
|
-
onMouseleave: (C) =>
|
|
833
|
+
onMouseenter: (C) => w(C),
|
|
834
|
+
onMouseleave: (C) => x(C),
|
|
907
835
|
innerHTML: d.value,
|
|
908
|
-
onClick: (C) =>
|
|
836
|
+
onClick: (C) => S(C)
|
|
909
837
|
}, null);
|
|
910
838
|
}
|
|
911
839
|
function M() {
|
|
912
840
|
return t.slots.groupTextTemplate && t.slots.groupTextTemplate();
|
|
913
841
|
}
|
|
914
|
-
function
|
|
915
|
-
return
|
|
842
|
+
function V() {
|
|
843
|
+
return l.value ? A : r.value ? M : "";
|
|
916
844
|
}
|
|
917
|
-
const
|
|
918
|
-
return () =>
|
|
919
|
-
class:
|
|
920
|
-
}, [
|
|
845
|
+
const b = V();
|
|
846
|
+
return () => T("div", {
|
|
847
|
+
class: c.value
|
|
848
|
+
}, [m.value && v(), b && b()]);
|
|
921
849
|
}
|
|
922
|
-
const
|
|
850
|
+
const L = /* @__PURE__ */ Q({
|
|
923
851
|
name: "FInputGroup",
|
|
924
|
-
props:
|
|
852
|
+
props: W,
|
|
925
853
|
emits: ["clear", "change", "blur", "click", "clickHandle", "focus", "input", "keydown", "keyup", "iconMouseEnter", "iconMouseLeave", "update:modelValue", "update:value", "updateExtendInfo", "valueChange"],
|
|
926
854
|
setup(e, t) {
|
|
927
|
-
const n =
|
|
928
|
-
inputGroupClass:
|
|
855
|
+
const n = h(e.modelValue), o = h(e.modelValue), a = De(e, t, n, o), {
|
|
856
|
+
inputGroupClass: c,
|
|
929
857
|
inputType: d,
|
|
930
|
-
inputGroupStyle:
|
|
931
|
-
} = a,
|
|
932
|
-
shouldShowAppendedButton:
|
|
933
|
-
} =
|
|
934
|
-
onMouseEnter:
|
|
935
|
-
onMouseLeave:
|
|
936
|
-
} =
|
|
937
|
-
|
|
858
|
+
inputGroupStyle: u
|
|
859
|
+
} = a, l = ee(e), {
|
|
860
|
+
shouldShowAppendedButton: r
|
|
861
|
+
} = l, s = K(e, t, a), {
|
|
862
|
+
onMouseEnter: i,
|
|
863
|
+
onMouseLeave: p
|
|
864
|
+
} = s, m = te(e, t, d, l), v = Ue(e, t), w = Ie(e, t, m, a), x = ne(e, t, l, s, m), k = qe(e, t), S = y(() => e.type === "number");
|
|
865
|
+
D(() => [e.value], ([M]) => {
|
|
938
866
|
n.value = M, o.value = M;
|
|
939
|
-
}),
|
|
867
|
+
}), D(() => [e.modelValue], ([M]) => {
|
|
940
868
|
n.value = M, o.value = M;
|
|
941
|
-
}),
|
|
869
|
+
}), j(() => {
|
|
942
870
|
e.value && (n.value = e.value, o.value = e.value);
|
|
943
871
|
});
|
|
944
|
-
const
|
|
872
|
+
const A = () => T(J, null, [T("div", {
|
|
945
873
|
id: "inputGroup",
|
|
946
|
-
class:
|
|
947
|
-
style:
|
|
948
|
-
onMouseenter:
|
|
949
|
-
onMouseleave:
|
|
950
|
-
}, [
|
|
951
|
-
return () =>
|
|
874
|
+
class: c.value,
|
|
875
|
+
style: u.value,
|
|
876
|
+
onMouseenter: i,
|
|
877
|
+
onMouseleave: p
|
|
878
|
+
}, [S.value ? v() : T(J, null, [k(), w(), r.value && x()])])]);
|
|
879
|
+
return () => A();
|
|
952
880
|
}
|
|
953
881
|
});
|
|
954
|
-
function
|
|
882
|
+
function We(e, t) {
|
|
955
883
|
e.schema;
|
|
956
|
-
const n =
|
|
957
|
-
function a(
|
|
884
|
+
const n = h(!0), o = h(!0);
|
|
885
|
+
function a(i) {
|
|
958
886
|
return !1;
|
|
959
887
|
}
|
|
960
|
-
function
|
|
888
|
+
function c() {
|
|
961
889
|
return !1;
|
|
962
890
|
}
|
|
963
891
|
function d() {
|
|
964
892
|
return !1;
|
|
965
893
|
}
|
|
966
|
-
function
|
|
894
|
+
function u() {
|
|
967
895
|
return !0;
|
|
968
896
|
}
|
|
969
|
-
function
|
|
897
|
+
function l(i) {
|
|
970
898
|
}
|
|
971
|
-
function
|
|
899
|
+
function r() {
|
|
972
900
|
}
|
|
973
|
-
function
|
|
901
|
+
function s(i) {
|
|
974
902
|
return null;
|
|
975
903
|
}
|
|
976
904
|
return {
|
|
977
905
|
canAccepts: a,
|
|
978
|
-
checkCanDeleteComponent:
|
|
906
|
+
checkCanDeleteComponent: c,
|
|
979
907
|
checkCanMoveComponent: d,
|
|
980
|
-
hideNestedPaddingInDesginerView:
|
|
981
|
-
onAcceptMovedChildElement:
|
|
982
|
-
resolveComponentContext:
|
|
908
|
+
hideNestedPaddingInDesginerView: u,
|
|
909
|
+
onAcceptMovedChildElement: l,
|
|
910
|
+
resolveComponentContext: r,
|
|
983
911
|
triggerBelongedComponentToMoveWhenMoved: n,
|
|
984
912
|
triggerBelongedComponentToDeleteWhenDeleted: o,
|
|
985
|
-
getPropsConfig:
|
|
913
|
+
getPropsConfig: s
|
|
986
914
|
};
|
|
987
915
|
}
|
|
988
|
-
class
|
|
916
|
+
class He {
|
|
917
|
+
constructor(t, n) {
|
|
918
|
+
P(this, "componentId");
|
|
919
|
+
P(this, "viewModelId");
|
|
920
|
+
P(this, "eventsEditorUtils");
|
|
921
|
+
P(this, "formSchemaUtils");
|
|
922
|
+
P(this, "formMetadataConverter");
|
|
923
|
+
P(this, "designViewModelUtils");
|
|
924
|
+
P(this, "designViewModelField");
|
|
925
|
+
P(this, "controlCreatorUtils");
|
|
926
|
+
P(this, "designerHostService");
|
|
927
|
+
P(this, "schemaService", null);
|
|
928
|
+
P(this, "metadataService", null);
|
|
929
|
+
P(this, "propertyConfig", {
|
|
930
|
+
type: "object",
|
|
931
|
+
categories: {}
|
|
932
|
+
});
|
|
933
|
+
var o;
|
|
934
|
+
this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((o = this.formSchemaUtils) == null ? void 0 : o.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
|
|
935
|
+
}
|
|
936
|
+
getTableInfo() {
|
|
937
|
+
var t;
|
|
938
|
+
return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
|
|
939
|
+
}
|
|
940
|
+
setDesignViewModelField(t) {
|
|
941
|
+
const n = t.binding && t.binding.type === "Form" && t.binding.field;
|
|
942
|
+
if (n) {
|
|
943
|
+
if (!this.designViewModelField) {
|
|
944
|
+
const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
945
|
+
this.designViewModelField = o.fields.find((a) => a.id === n);
|
|
946
|
+
}
|
|
947
|
+
t.updateOn = this.designViewModelField.updateOn;
|
|
948
|
+
}
|
|
949
|
+
}
|
|
950
|
+
changeFieldEditorType(t, n) {
|
|
951
|
+
}
|
|
952
|
+
getBasicPropConfig(t) {
|
|
953
|
+
return {
|
|
954
|
+
description: "Basic Information",
|
|
955
|
+
title: "基本信息",
|
|
956
|
+
properties: {
|
|
957
|
+
id: {
|
|
958
|
+
description: "组件标识",
|
|
959
|
+
title: "标识",
|
|
960
|
+
type: "string",
|
|
961
|
+
readonly: !0
|
|
962
|
+
},
|
|
963
|
+
type: {
|
|
964
|
+
description: "组件类型",
|
|
965
|
+
title: "控件类型",
|
|
966
|
+
type: "select",
|
|
967
|
+
editor: {
|
|
968
|
+
type: "combo-list",
|
|
969
|
+
textField: "name",
|
|
970
|
+
valueField: "value",
|
|
971
|
+
data: [{ value: t.type, name: f[t.type].name }]
|
|
972
|
+
}
|
|
973
|
+
}
|
|
974
|
+
}
|
|
975
|
+
};
|
|
976
|
+
}
|
|
977
|
+
getAppearanceConfig(t = null) {
|
|
978
|
+
return {
|
|
979
|
+
title: "样式",
|
|
980
|
+
description: "Appearance",
|
|
981
|
+
properties: {
|
|
982
|
+
class: {
|
|
983
|
+
title: "class样式",
|
|
984
|
+
type: "string",
|
|
985
|
+
description: "组件的CSS样式",
|
|
986
|
+
$converter: "/converter/appearance.converter"
|
|
987
|
+
},
|
|
988
|
+
style: {
|
|
989
|
+
title: "style样式",
|
|
990
|
+
type: "string",
|
|
991
|
+
description: "组件的样式",
|
|
992
|
+
$converter: "/converter/appearance.converter"
|
|
993
|
+
}
|
|
994
|
+
}
|
|
995
|
+
};
|
|
996
|
+
}
|
|
997
|
+
}
|
|
998
|
+
const N = class N {
|
|
999
|
+
/**
|
|
1000
|
+
* 根据绑定字段类型获取可用的输入类控件
|
|
1001
|
+
*/
|
|
989
1002
|
static getEditorTypesByMDataType(t) {
|
|
990
|
-
const n =
|
|
1003
|
+
const n = N.fieldControlTypeMapping[t];
|
|
991
1004
|
return n || [{ key: "", value: "" }];
|
|
992
1005
|
}
|
|
993
|
-
|
|
1006
|
+
/**
|
|
1007
|
+
* 获取所有输入类控件
|
|
1008
|
+
*/
|
|
1009
|
+
static getAllInputTypes() {
|
|
1010
|
+
const t = [];
|
|
1011
|
+
for (let n in N.fieldControlTypeMapping)
|
|
1012
|
+
N.fieldControlTypeMapping[n].forEach((o) => {
|
|
1013
|
+
t.find((a) => a.key === o.key && a.value === o.value) || t.push({ key: o.key, value: o.value });
|
|
1014
|
+
});
|
|
1015
|
+
return t;
|
|
1016
|
+
}
|
|
1017
|
+
};
|
|
994
1018
|
/**
|
|
995
1019
|
* <字段类型,可配置的控件类型列表>的映射
|
|
996
1020
|
*/
|
|
997
|
-
|
|
1021
|
+
P(N, "fieldControlTypeMapping", {
|
|
998
1022
|
String: [
|
|
999
|
-
{ key:
|
|
1000
|
-
{ key:
|
|
1001
|
-
{ key:
|
|
1002
|
-
{ key:
|
|
1003
|
-
{ key:
|
|
1004
|
-
{ key:
|
|
1005
|
-
{ key:
|
|
1006
|
-
{ key: p.textarea.type, value: p.textarea.name }
|
|
1007
|
-
// { key: DgControl.Tags.type, value: DgControl.Tags.name },
|
|
1023
|
+
{ key: f["input-group"].type, value: f["input-group"].name },
|
|
1024
|
+
{ key: f.lookup.type, value: f.lookup.name },
|
|
1025
|
+
{ key: f["date-picker"].type, value: f["date-picker"].name },
|
|
1026
|
+
{ key: f["check-box"].type, value: f["check-box"].name },
|
|
1027
|
+
{ key: f["radio-group"].type, value: f["radio-group"].name },
|
|
1028
|
+
{ key: f["combo-list"].type, value: f["combo-list"].name },
|
|
1029
|
+
{ key: f.textarea.type, value: f.textarea.name }
|
|
1008
1030
|
],
|
|
1009
1031
|
Text: [
|
|
1010
|
-
{ key:
|
|
1011
|
-
{ key:
|
|
1012
|
-
{ key: p.lookup.type, value: p.lookup.name }
|
|
1032
|
+
{ key: f.textarea.type, value: f.textarea.name },
|
|
1033
|
+
{ key: f.lookup.type, value: f.lookup.name }
|
|
1013
1034
|
],
|
|
1014
1035
|
Decimal: [
|
|
1015
|
-
{ key:
|
|
1036
|
+
{ key: f["number-spinner"].type, value: f["number-spinner"].name }
|
|
1016
1037
|
],
|
|
1017
1038
|
Integer: [
|
|
1018
|
-
{ key:
|
|
1039
|
+
{ key: f["number-spinner"].type, value: f["number-spinner"].name }
|
|
1019
1040
|
],
|
|
1020
1041
|
Number: [
|
|
1021
|
-
{ key:
|
|
1042
|
+
{ key: f["number-spinner"].type, value: f["number-spinner"].name }
|
|
1022
1043
|
],
|
|
1023
1044
|
BigNumber: [
|
|
1024
|
-
{ key:
|
|
1045
|
+
{ key: f["number-spinner"].type, value: f["number-spinner"].name }
|
|
1025
1046
|
],
|
|
1026
1047
|
Date: [
|
|
1027
|
-
{ key:
|
|
1048
|
+
{ key: f["date-picker"].type, value: f["date-picker"].name }
|
|
1028
1049
|
],
|
|
1029
1050
|
DateTime: [
|
|
1030
|
-
{ key:
|
|
1051
|
+
{ key: f["date-picker"].type, value: f["date-picker"].name }
|
|
1031
1052
|
],
|
|
1032
1053
|
Boolean: [
|
|
1033
|
-
{ key:
|
|
1034
|
-
{ key:
|
|
1054
|
+
{ key: f.switch.type, value: f.switch.name },
|
|
1055
|
+
{ key: f["check-box"].type, value: f["check-box"].name }
|
|
1035
1056
|
],
|
|
1036
1057
|
Enum: [
|
|
1037
|
-
{ key:
|
|
1038
|
-
{ key:
|
|
1058
|
+
{ key: f["combo-list"].type, value: f["combo-list"].name },
|
|
1059
|
+
{ key: f["radio-group"].type, value: f["radio-group"].name }
|
|
1039
1060
|
],
|
|
1040
1061
|
Object: [
|
|
1041
|
-
{ key:
|
|
1042
|
-
{ key:
|
|
1043
|
-
{ key:
|
|
1044
|
-
],
|
|
1045
|
-
EmployeeSelector: [
|
|
1046
|
-
{ key: p.EmployeeSelector.type, value: p.EmployeeSelector.name }
|
|
1047
|
-
],
|
|
1048
|
-
AdminOrganizationSelector: [
|
|
1049
|
-
{ key: p.AdminOrganizationSelector.type, value: p.AdminOrganizationSelector.name }
|
|
1062
|
+
{ key: f.lookup.type, value: f.lookup.name },
|
|
1063
|
+
{ key: f["combo-list"].type, value: f["combo-list"].name },
|
|
1064
|
+
{ key: f["radio-group"].type, value: f["radio-group"].name }
|
|
1050
1065
|
]
|
|
1051
1066
|
});
|
|
1052
|
-
|
|
1067
|
+
let $ = N;
|
|
1068
|
+
const ze = h(0);
|
|
1069
|
+
class Je extends He {
|
|
1053
1070
|
constructor(t, n) {
|
|
1054
|
-
|
|
1055
|
-
x(this, "viewModelId");
|
|
1056
|
-
x(this, "eventsEditorUtils");
|
|
1057
|
-
x(this, "formSchemaUtils");
|
|
1058
|
-
x(this, "formMetadataConverter");
|
|
1059
|
-
x(this, "designViewModelUtils");
|
|
1060
|
-
x(this, "designViewModelField");
|
|
1061
|
-
x(this, "controlCreatorUtils");
|
|
1062
|
-
x(this, "designerHostService");
|
|
1063
|
-
x(this, "schemaService", null);
|
|
1064
|
-
x(this, "metadataService", null);
|
|
1065
|
-
x(this, "propertyConfig", {
|
|
1066
|
-
type: "object",
|
|
1067
|
-
categories: {}
|
|
1068
|
-
});
|
|
1069
|
-
var o;
|
|
1070
|
-
this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((o = this.formSchemaUtils) == null ? void 0 : o.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
|
|
1071
|
-
}
|
|
1072
|
-
getTableInfo() {
|
|
1073
|
-
var t;
|
|
1074
|
-
return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
|
|
1075
|
-
}
|
|
1076
|
-
setDesignViewModelField(t) {
|
|
1077
|
-
const n = t.binding && t.binding.type === "Form" && t.binding.field;
|
|
1078
|
-
if (n) {
|
|
1079
|
-
if (!this.designViewModelField) {
|
|
1080
|
-
const o = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
1081
|
-
this.designViewModelField = o.fields.find((a) => a.id === n);
|
|
1082
|
-
}
|
|
1083
|
-
t.updateOn = this.designViewModelField.updateOn;
|
|
1084
|
-
}
|
|
1071
|
+
super(t, n);
|
|
1085
1072
|
}
|
|
1086
|
-
|
|
1073
|
+
getPropertyConfig(t, n) {
|
|
1074
|
+
return this.propertyConfig.categories.basic = this.getBasicProperties(t, n), this.propertyConfig.categories.appearance = this.getAppearanceProperties(t), this.propertyConfig.categories.editor = this.getEditorProperties(t), this.propertyConfig;
|
|
1087
1075
|
}
|
|
1088
|
-
|
|
1089
|
-
var
|
|
1090
|
-
var
|
|
1091
|
-
|
|
1076
|
+
getBasicProperties(t, n) {
|
|
1077
|
+
var d;
|
|
1078
|
+
var o = this;
|
|
1079
|
+
this.setDesignViewModelField(t);
|
|
1080
|
+
const a = this.formSchemaUtils.getFormMetadataBasicInfo(), c = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
1081
|
+
return {
|
|
1092
1082
|
description: "Basic Information",
|
|
1093
1083
|
title: "基本信息",
|
|
1094
1084
|
properties: {
|
|
@@ -1108,63 +1098,48 @@ class $e {
|
|
|
1108
1098
|
type: "combo-list",
|
|
1109
1099
|
textField: "value",
|
|
1110
1100
|
valueField: "key",
|
|
1111
|
-
|
|
1112
|
-
|
|
1101
|
+
editable: !1,
|
|
1102
|
+
data: o.designViewModelField ? $.getEditorTypesByMDataType((d = o.designViewModelField.type) == null ? void 0 : d.name) : $.getAllInputTypes()
|
|
1113
1103
|
}
|
|
1114
1104
|
},
|
|
1115
1105
|
label: {
|
|
1116
1106
|
title: "标签",
|
|
1117
1107
|
type: "string",
|
|
1118
1108
|
$converter: "/converter/form-group-label.converter"
|
|
1109
|
+
},
|
|
1110
|
+
binding: {
|
|
1111
|
+
description: "绑定的表单字段",
|
|
1112
|
+
title: "绑定",
|
|
1113
|
+
$converter: "/converter/field-selector.converter",
|
|
1114
|
+
editor: {
|
|
1115
|
+
type: "field-selector",
|
|
1116
|
+
bindingType: { enable: !1 },
|
|
1117
|
+
editorParams: {
|
|
1118
|
+
propertyData: t,
|
|
1119
|
+
formBasicInfo: a
|
|
1120
|
+
},
|
|
1121
|
+
columns: [
|
|
1122
|
+
{ field: "name", title: "字段名称" },
|
|
1123
|
+
{ field: "bindingField", title: "绑定字段" },
|
|
1124
|
+
{ field: "fieldType", title: "字段类型" }
|
|
1125
|
+
],
|
|
1126
|
+
textField: "bindingField",
|
|
1127
|
+
data: c
|
|
1128
|
+
}
|
|
1119
1129
|
}
|
|
1120
1130
|
},
|
|
1121
|
-
setPropertyRelates(
|
|
1122
|
-
if (
|
|
1123
|
-
switch (
|
|
1131
|
+
setPropertyRelates(u, l) {
|
|
1132
|
+
if (u)
|
|
1133
|
+
switch (u && u.propertyID) {
|
|
1124
1134
|
case "type": {
|
|
1125
|
-
|
|
1135
|
+
o.changeControlType(t, u, n);
|
|
1126
1136
|
break;
|
|
1127
1137
|
}
|
|
1128
1138
|
}
|
|
1129
1139
|
}
|
|
1130
1140
|
};
|
|
1131
1141
|
}
|
|
1132
|
-
|
|
1133
|
-
* 卡片控件:切换控件类型后事件
|
|
1134
|
-
* @param propertyData 控件DOM属性
|
|
1135
|
-
* @param newControlType 新控件类型
|
|
1136
|
-
*/
|
|
1137
|
-
changeControlType(t, n) {
|
|
1138
|
-
var i, u, r, c, y;
|
|
1139
|
-
const o = n.propertyValue, a = this.formSchemaUtils.getComponentById(this.componentId);
|
|
1140
|
-
let l = this.getControlParentContainer(t.id, a);
|
|
1141
|
-
if (!l)
|
|
1142
|
-
return;
|
|
1143
|
-
const d = l.contents.findIndex((f) => f.id === t.id), m = l.contents[d];
|
|
1144
|
-
let s;
|
|
1145
|
-
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
1146
|
-
editor: {
|
|
1147
|
-
$type: o
|
|
1148
|
-
},
|
|
1149
|
-
name: this.designViewModelField.name,
|
|
1150
|
-
require: this.designViewModelField.require,
|
|
1151
|
-
readonly: this.designViewModelField.readonly
|
|
1152
|
-
}, !1), s = this.controlCreatorUtils.setFormFieldProperty("Form", this.designViewModelField, null, o)), Object.assign(s, {
|
|
1153
|
-
id: m.id,
|
|
1154
|
-
appearance: m.appearance,
|
|
1155
|
-
size: m.size,
|
|
1156
|
-
label: m.label
|
|
1157
|
-
}), Object.assign(s.editor, {
|
|
1158
|
-
isTextArea: s.isTextArea && m.isTextArea,
|
|
1159
|
-
type: o || "",
|
|
1160
|
-
placeHolder: (i = m.editor) == null ? void 0 : i.placeHolder,
|
|
1161
|
-
holdPlace: (u = m.editor) == null ? void 0 : u.holdPlace,
|
|
1162
|
-
readonly: (r = m.editor) == null ? void 0 : r.readonly,
|
|
1163
|
-
require: (c = m.editor) == null ? void 0 : c.require,
|
|
1164
|
-
visible: (y = m.editor) == null ? void 0 : y.visible
|
|
1165
|
-
}), l.contents.splice(d, 1, s);
|
|
1166
|
-
}
|
|
1167
|
-
getAppearanceConfig(t = null) {
|
|
1142
|
+
getAppearanceProperties(t) {
|
|
1168
1143
|
return {
|
|
1169
1144
|
title: "样式",
|
|
1170
1145
|
description: "Appearance",
|
|
@@ -1194,65 +1169,44 @@ class $e {
|
|
|
1194
1169
|
}
|
|
1195
1170
|
};
|
|
1196
1171
|
}
|
|
1197
|
-
/**
|
|
1198
|
-
* 获取控件:以contents为节点进行定位
|
|
1199
|
-
* @param controlId 控件ID
|
|
1200
|
-
* @param domJson 容器
|
|
1201
|
-
*/
|
|
1202
|
-
getControlParentContainer(t, n) {
|
|
1203
|
-
let o;
|
|
1204
|
-
if (!n || !n.contents || n.contents.length === 0)
|
|
1205
|
-
return null;
|
|
1206
|
-
for (const a of n.contents) {
|
|
1207
|
-
if (a.id === t)
|
|
1208
|
-
return o = n, n;
|
|
1209
|
-
if (o = this.getControlParentContainer(t, a), o)
|
|
1210
|
-
return o;
|
|
1211
|
-
}
|
|
1212
|
-
}
|
|
1213
|
-
}
|
|
1214
|
-
class ze extends $e {
|
|
1215
|
-
constructor(t, n) {
|
|
1216
|
-
super(t, n);
|
|
1217
|
-
}
|
|
1218
|
-
getBasicProperties(t) {
|
|
1219
|
-
let n = this.getBasicPropConfig(t);
|
|
1220
|
-
return n.properties.binding = this.getFieldSelectorOptions(t), n;
|
|
1221
|
-
}
|
|
1222
|
-
getAppearanceProperties(t) {
|
|
1223
|
-
return this.getAppearanceConfig(t);
|
|
1224
|
-
}
|
|
1225
1172
|
getEditorProperties(t) {
|
|
1226
1173
|
return this.getComponentConfig(t);
|
|
1227
1174
|
}
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1175
|
+
/**
|
|
1176
|
+
* 卡片控件:切换控件类型后事件
|
|
1177
|
+
* @param propertyData 控件DOM属性
|
|
1178
|
+
* @param newControlType 新控件类型
|
|
1179
|
+
*/
|
|
1180
|
+
changeControlType(t, n, o) {
|
|
1181
|
+
var r, s, i, p;
|
|
1182
|
+
const a = n.propertyValue, c = o && o.parent && o.parent.schema;
|
|
1183
|
+
if (!c)
|
|
1184
|
+
return;
|
|
1185
|
+
const d = c.contents.findIndex((m) => m.id === t.id), u = c.contents[d];
|
|
1186
|
+
let l;
|
|
1187
|
+
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
1237
1188
|
editor: {
|
|
1238
|
-
type:
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1189
|
+
$type: a
|
|
1190
|
+
},
|
|
1191
|
+
name: this.designViewModelField.name,
|
|
1192
|
+
require: this.designViewModelField.require,
|
|
1193
|
+
readonly: this.designViewModelField.readonly
|
|
1194
|
+
}, !1), l = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, a)), l || (l = _("form-group") || {}, l.editor = _(a) || {}, delete l.editor.id, delete l.editor.binding, delete l.editor.appearance), Object.assign(l, {
|
|
1195
|
+
id: u.id,
|
|
1196
|
+
appearance: u.appearance,
|
|
1197
|
+
size: u.size,
|
|
1198
|
+
label: u.label,
|
|
1199
|
+
binding: u.binding,
|
|
1200
|
+
visible: u.visible
|
|
1201
|
+
}), Object.assign(l.editor, {
|
|
1202
|
+
isTextArea: l.isTextArea && u.isTextArea,
|
|
1203
|
+
placeholder: (r = u.editor) == null ? void 0 : r.placeholder,
|
|
1204
|
+
holdPlace: (s = u.editor) == null ? void 0 : s.holdPlace,
|
|
1205
|
+
readonly: (i = u.editor) == null ? void 0 : i.readonly,
|
|
1206
|
+
require: (p = u.editor) == null ? void 0 : p.require
|
|
1207
|
+
}), c.contents.splice(d, 1), c.contents.splice(d, 0, l), o.schema = Object.assign(u, l), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
1208
|
+
(m) => m.classList.remove("dgComponentSelected")
|
|
1209
|
+
), ze.value++;
|
|
1256
1210
|
}
|
|
1257
1211
|
getComponentConfig(t, n = {}, o = {}) {
|
|
1258
1212
|
const a = Object.assign({
|
|
@@ -1260,7 +1214,7 @@ class ze extends $e {
|
|
|
1260
1214
|
title: "组件信息",
|
|
1261
1215
|
type: "input-group",
|
|
1262
1216
|
$converter: "/converter/property-editor.converter"
|
|
1263
|
-
}, n),
|
|
1217
|
+
}, n), c = Object.assign({
|
|
1264
1218
|
readonly: {
|
|
1265
1219
|
description: "",
|
|
1266
1220
|
title: "只读",
|
|
@@ -1282,173 +1236,173 @@ class ze extends $e {
|
|
|
1282
1236
|
type: "string"
|
|
1283
1237
|
}
|
|
1284
1238
|
}, o);
|
|
1285
|
-
return { ...a, properties: { ...
|
|
1239
|
+
return { ...a, properties: { ...c } };
|
|
1286
1240
|
}
|
|
1287
1241
|
}
|
|
1288
|
-
class
|
|
1242
|
+
class Ze extends Je {
|
|
1289
1243
|
constructor(t, n) {
|
|
1290
1244
|
super(t, n);
|
|
1291
1245
|
}
|
|
1292
1246
|
}
|
|
1293
|
-
function
|
|
1247
|
+
function _e(e, t) {
|
|
1294
1248
|
const {
|
|
1295
1249
|
canAccepts: n,
|
|
1296
1250
|
checkCanDeleteComponent: o,
|
|
1297
1251
|
checkCanMoveComponent: a,
|
|
1298
|
-
hideNestedPaddingInDesginerView:
|
|
1252
|
+
hideNestedPaddingInDesginerView: c,
|
|
1299
1253
|
onAcceptMovedChildElement: d,
|
|
1300
|
-
resolveComponentContext:
|
|
1301
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1302
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1303
|
-
} =
|
|
1304
|
-
function
|
|
1305
|
-
return new
|
|
1254
|
+
resolveComponentContext: u,
|
|
1255
|
+
triggerBelongedComponentToMoveWhenMoved: l,
|
|
1256
|
+
triggerBelongedComponentToDeleteWhenDeleted: r
|
|
1257
|
+
} = We(e), s = e.schema;
|
|
1258
|
+
function i(p, m) {
|
|
1259
|
+
return new Ze(p, t).getPropertyConfig(s, m);
|
|
1306
1260
|
}
|
|
1307
1261
|
return {
|
|
1308
1262
|
canAccepts: n,
|
|
1309
1263
|
checkCanDeleteComponent: o,
|
|
1310
1264
|
checkCanMoveComponent: a,
|
|
1311
|
-
hideNestedPaddingInDesginerView:
|
|
1265
|
+
hideNestedPaddingInDesginerView: c,
|
|
1312
1266
|
onAcceptMovedChildElement: d,
|
|
1313
|
-
resolveComponentContext:
|
|
1314
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1315
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1316
|
-
getPropsConfig:
|
|
1267
|
+
resolveComponentContext: u,
|
|
1268
|
+
triggerBelongedComponentToMoveWhenMoved: l,
|
|
1269
|
+
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
1270
|
+
getPropsConfig: i
|
|
1317
1271
|
};
|
|
1318
1272
|
}
|
|
1319
1273
|
function Qe(e, t, n) {
|
|
1320
|
-
var
|
|
1274
|
+
var V;
|
|
1321
1275
|
function o() {
|
|
1322
1276
|
n != null && n.resolveComponentContext && n.resolveComponentContext();
|
|
1323
1277
|
}
|
|
1324
1278
|
o();
|
|
1325
|
-
const a = n && n.getStyles && n.getStyles() || "",
|
|
1326
|
-
function
|
|
1279
|
+
const a = n && n.getStyles && n.getStyles() || "", c = n && n.getDesignerClass && n.getDesignerClass() || "", d = h();
|
|
1280
|
+
function u() {
|
|
1327
1281
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
|
|
1328
1282
|
}
|
|
1329
|
-
function
|
|
1283
|
+
function l() {
|
|
1330
1284
|
return !1;
|
|
1331
1285
|
}
|
|
1332
|
-
function
|
|
1286
|
+
function r() {
|
|
1333
1287
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanDeleteComponent ? n.checkCanDeleteComponent() : !0;
|
|
1334
1288
|
}
|
|
1335
|
-
function
|
|
1289
|
+
function s() {
|
|
1336
1290
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 : n && n.hideNestedPaddingInDesginerView ? n.hideNestedPaddingInDesginerView() : !1;
|
|
1337
1291
|
}
|
|
1338
|
-
function
|
|
1339
|
-
if (!
|
|
1292
|
+
function i(b) {
|
|
1293
|
+
if (!b || !b.value)
|
|
1340
1294
|
return null;
|
|
1341
|
-
if (
|
|
1342
|
-
return
|
|
1343
|
-
const C = b
|
|
1344
|
-
return
|
|
1295
|
+
if (b.value.schema && b.value.schema.type === "component")
|
|
1296
|
+
return b.value;
|
|
1297
|
+
const C = h(b == null ? void 0 : b.value.parent), B = i(C);
|
|
1298
|
+
return B || null;
|
|
1345
1299
|
}
|
|
1346
|
-
function
|
|
1347
|
-
const { componentInstance: C, designerItemElementRef:
|
|
1348
|
-
return !C || !C.value ? null : C.value.canMove ?
|
|
1300
|
+
function p(b = t) {
|
|
1301
|
+
const { componentInstance: C, designerItemElementRef: B } = b;
|
|
1302
|
+
return !C || !C.value ? null : C.value.canMove ? B : p(b.parent);
|
|
1349
1303
|
}
|
|
1350
|
-
function
|
|
1351
|
-
return !!n && n.canAccepts(
|
|
1304
|
+
function m(b) {
|
|
1305
|
+
return !!n && n.canAccepts(b);
|
|
1352
1306
|
}
|
|
1353
|
-
function
|
|
1307
|
+
function v() {
|
|
1354
1308
|
return (t == null ? void 0 : t.schema.label) || (t == null ? void 0 : t.schema.title) || (t == null ? void 0 : t.schema.name);
|
|
1355
1309
|
}
|
|
1356
|
-
function
|
|
1310
|
+
function w() {
|
|
1357
1311
|
}
|
|
1358
|
-
function
|
|
1312
|
+
function x(b, C) {
|
|
1359
1313
|
C && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(C);
|
|
1360
1314
|
}
|
|
1361
|
-
function
|
|
1362
|
-
const { componentType: C } =
|
|
1363
|
-
let
|
|
1364
|
-
n && n.onResolveNewComponentSchema && (
|
|
1365
|
-
const
|
|
1366
|
-
return
|
|
1315
|
+
function k(b) {
|
|
1316
|
+
const { componentType: C } = b;
|
|
1317
|
+
let B = I(C, b);
|
|
1318
|
+
n && n.onResolveNewComponentSchema && (B = n.onResolveNewComponentSchema(b, B));
|
|
1319
|
+
const O = C.toLowerCase().replace("-", "_");
|
|
1320
|
+
return B && !B.id && B.type === C && (B.id = `${O}_${Math.random().toString().slice(2, 6)}`), B;
|
|
1367
1321
|
}
|
|
1368
|
-
function
|
|
1369
|
-
const
|
|
1370
|
-
|
|
1371
|
-
let
|
|
1372
|
-
n && n.onAcceptNewChildElement && (
|
|
1373
|
-
const
|
|
1374
|
-
return
|
|
1322
|
+
function S(b, C) {
|
|
1323
|
+
const B = String(b.getAttribute("data-controltype")), O = b.getAttribute("data-feature"), G = O ? JSON.parse(O) : {};
|
|
1324
|
+
G.parentComponentInstance = d.value;
|
|
1325
|
+
let F = I(B, G);
|
|
1326
|
+
n && n.onAcceptNewChildElement && (F = n.onAcceptNewChildElement(b, C, F));
|
|
1327
|
+
const U = B.toLowerCase().replace("-", "_");
|
|
1328
|
+
return F && !F.id && F.type === B && (F.id = `${U}_${Math.random().toString().slice(2, 6)}`), F;
|
|
1375
1329
|
}
|
|
1376
|
-
function
|
|
1330
|
+
function A(b) {
|
|
1377
1331
|
}
|
|
1378
|
-
function M(...
|
|
1332
|
+
function M(...b) {
|
|
1379
1333
|
if (n && n.getPropsConfig)
|
|
1380
|
-
return n.getPropsConfig(...
|
|
1334
|
+
return n.getPropsConfig(...b);
|
|
1381
1335
|
}
|
|
1382
1336
|
return d.value = {
|
|
1383
|
-
canMove:
|
|
1384
|
-
canSelectParent:
|
|
1385
|
-
canDelete:
|
|
1386
|
-
canNested: !
|
|
1337
|
+
canMove: u(),
|
|
1338
|
+
canSelectParent: l(),
|
|
1339
|
+
canDelete: r(),
|
|
1340
|
+
canNested: !s(),
|
|
1387
1341
|
contents: t == null ? void 0 : t.schema.contents,
|
|
1388
1342
|
elementRef: e,
|
|
1389
|
-
parent: (
|
|
1343
|
+
parent: (V = t == null ? void 0 : t.parent) == null ? void 0 : V.componentInstance,
|
|
1390
1344
|
schema: t == null ? void 0 : t.schema,
|
|
1391
1345
|
styles: a,
|
|
1392
|
-
designerClass:
|
|
1393
|
-
canAccepts:
|
|
1394
|
-
getBelongedComponentInstance:
|
|
1395
|
-
getDraggableDesignItemElement:
|
|
1396
|
-
getDraggingDisplayText:
|
|
1346
|
+
designerClass: c,
|
|
1347
|
+
canAccepts: m,
|
|
1348
|
+
getBelongedComponentInstance: i,
|
|
1349
|
+
getDraggableDesignItemElement: p,
|
|
1350
|
+
getDraggingDisplayText: v,
|
|
1397
1351
|
getPropConfig: M,
|
|
1398
|
-
getDragScopeElement:
|
|
1399
|
-
onAcceptMovedChildElement:
|
|
1400
|
-
onAcceptNewChildElement:
|
|
1401
|
-
onChildElementMovedOut:
|
|
1402
|
-
addNewChildComponentSchema:
|
|
1352
|
+
getDragScopeElement: w,
|
|
1353
|
+
onAcceptMovedChildElement: x,
|
|
1354
|
+
onAcceptNewChildElement: S,
|
|
1355
|
+
onChildElementMovedOut: A,
|
|
1356
|
+
addNewChildComponentSchema: k,
|
|
1403
1357
|
updateDragAndDropRules: o,
|
|
1404
|
-
triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved ||
|
|
1405
|
-
triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted ||
|
|
1358
|
+
triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || h(!1),
|
|
1359
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || h(!1)
|
|
1406
1360
|
}, d;
|
|
1407
1361
|
}
|
|
1408
|
-
const
|
|
1362
|
+
const Xe = /* @__PURE__ */ Q({
|
|
1409
1363
|
name: "FInputGroupDesign",
|
|
1410
|
-
props:
|
|
1364
|
+
props: W,
|
|
1411
1365
|
emits: ["updateExtendInfo", "clear", "valueChange", "clickHandle", "blurHandle", "focusHandle", "enterHandle", "iconMouseEnter", "iconMouseLeave", "keyupHandle", "keydownHandle", "inputClick"],
|
|
1412
1366
|
setup(e, t) {
|
|
1413
|
-
const n =
|
|
1414
|
-
inputGroupClass:
|
|
1367
|
+
const n = h(e.modelValue), o = h(e.modelValue), a = Ve(e, t, n, o), {
|
|
1368
|
+
inputGroupClass: c,
|
|
1415
1369
|
inputType: d,
|
|
1416
|
-
inputGroupStyle:
|
|
1417
|
-
} = a,
|
|
1418
|
-
shouldShowAppendedButton:
|
|
1419
|
-
} =
|
|
1420
|
-
onMouseEnter:
|
|
1421
|
-
onMouseLeave:
|
|
1422
|
-
} =
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
}), t.expose(
|
|
1426
|
-
const
|
|
1427
|
-
return () =>
|
|
1370
|
+
inputGroupStyle: u
|
|
1371
|
+
} = a, l = ee(e), {
|
|
1372
|
+
shouldShowAppendedButton: r
|
|
1373
|
+
} = l, s = K(e, t, a), {
|
|
1374
|
+
onMouseEnter: i,
|
|
1375
|
+
onMouseLeave: p
|
|
1376
|
+
} = s, m = te(e, t, d, l), v = h(), w = Z("designer-host-service"), x = Z("design-item-context"), k = _e(x, w), S = Qe(v, x, k);
|
|
1377
|
+
j(() => {
|
|
1378
|
+
v.value.componentInstance = S;
|
|
1379
|
+
}), t.expose(S.value);
|
|
1380
|
+
const A = ne(e, t, l, s, m), M = h();
|
|
1381
|
+
return () => T("div", {
|
|
1428
1382
|
id: "inputGroup",
|
|
1429
|
-
ref:
|
|
1430
|
-
class:
|
|
1431
|
-
style:
|
|
1432
|
-
onMouseenter:
|
|
1433
|
-
onMouseleave:
|
|
1434
|
-
}, [
|
|
1383
|
+
ref: v,
|
|
1384
|
+
class: c.value,
|
|
1385
|
+
style: u.value,
|
|
1386
|
+
onMouseenter: i,
|
|
1387
|
+
onMouseleave: p
|
|
1388
|
+
}, [T("input", {
|
|
1435
1389
|
ref: M,
|
|
1436
1390
|
class: "form-control",
|
|
1437
1391
|
readonly: !0,
|
|
1438
1392
|
placeholder: e.placeholder
|
|
1439
|
-
}, null),
|
|
1393
|
+
}, null), r.value && A()]);
|
|
1440
1394
|
}
|
|
1441
1395
|
});
|
|
1442
|
-
|
|
1443
|
-
e["input-group"] =
|
|
1396
|
+
L.register = (e, t, n, o) => {
|
|
1397
|
+
e["input-group"] = L, t["input-group"] = R;
|
|
1444
1398
|
};
|
|
1445
|
-
|
|
1446
|
-
e["input-group"] =
|
|
1399
|
+
L.registerDesigner = (e, t, n) => {
|
|
1400
|
+
e["input-group"] = Xe, t["input-group"] = R;
|
|
1447
1401
|
};
|
|
1448
|
-
const
|
|
1402
|
+
const ot = Ge(L);
|
|
1449
1403
|
export {
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1404
|
+
L as FInputGroup,
|
|
1405
|
+
ot as default,
|
|
1406
|
+
W as inputGroupProps,
|
|
1407
|
+
R as propsResolver
|
|
1454
1408
|
};
|