@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,167 +1,166 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { defineComponent as
|
|
5
|
-
import { cloneDeep as
|
|
1
|
+
var Ee = Object.defineProperty;
|
|
2
|
+
var Ve = (e, t, n) => t in e ? Ee(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
|
+
var L = (e, t, n) => Ve(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
+
import { defineComponent as q, ref as m, computed as k, createVNode as A, nextTick as oe, inject as z, onMounted as U, watch as I, createTextVNode as Oe, reactive as $e, withDirectives as Ne, resolveDirective as Le, Fragment as ue, mergeProps as Z } from "vue";
|
|
5
|
+
import { cloneDeep as Ie } from "lodash-es";
|
|
6
6
|
import "bignumber.js";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import Qe from "
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
23
|
-
import
|
|
24
|
-
import
|
|
25
|
-
import
|
|
26
|
-
import
|
|
27
|
-
import
|
|
28
|
-
import
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import
|
|
32
|
-
import
|
|
33
|
-
import
|
|
34
|
-
import
|
|
35
|
-
import
|
|
36
|
-
import
|
|
37
|
-
import
|
|
38
|
-
import
|
|
39
|
-
import
|
|
40
|
-
import
|
|
41
|
-
import
|
|
42
|
-
import
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import Lt from "
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import Rt from "
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import "
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
7
|
+
import Ge, { useNumber as qe, useFormat as Re, useSpinner as Ue, useTextBox as We } from "../number-spinner/index.esm.js";
|
|
8
|
+
import He from "../accordion/index.esm.js";
|
|
9
|
+
import ze from "../avatar/index.esm.js";
|
|
10
|
+
import _e from "../button-edit/index.esm.js";
|
|
11
|
+
import Je from "../button-group/index.esm.js";
|
|
12
|
+
import Qe from "../calendar/index.esm.js";
|
|
13
|
+
import Ze from "../capsule/index.esm.js";
|
|
14
|
+
import Xe from "../checkbox/index.esm.js";
|
|
15
|
+
import Ye from "../combo-list/index.esm.js";
|
|
16
|
+
import Ke from "../combo-tree/index.esm.js";
|
|
17
|
+
import et from "../component/index.esm.js";
|
|
18
|
+
import tt from "../color-picker/index.esm.js";
|
|
19
|
+
import nt from "../content-container/index.esm.js";
|
|
20
|
+
import ot from "../date-picker/index.esm.js";
|
|
21
|
+
import rt from "../data-grid/index.esm.js";
|
|
22
|
+
import at from "../dropdown/index.esm.js";
|
|
23
|
+
import it from "../dynamic-form/index.esm.js";
|
|
24
|
+
import st from "../events-editor/index.esm.js";
|
|
25
|
+
import lt from "../filter-bar/index.esm.js";
|
|
26
|
+
import ct from "../field-selector/index.esm.js";
|
|
27
|
+
import ut from "../image-cropper/index.esm.js";
|
|
28
|
+
import pt from "../input-group/index.esm.js";
|
|
29
|
+
import dt from "../layout/index.esm.js";
|
|
30
|
+
import ft from "../list-nav/index.esm.js";
|
|
31
|
+
import mt from "../list-view/index.esm.js";
|
|
32
|
+
import yt from "../lookup/index.esm.js";
|
|
33
|
+
import gt from "../mapping-editor/index.esm.js";
|
|
34
|
+
import bt from "../nav/index.esm.js";
|
|
35
|
+
import ht from "../number-range/index.esm.js";
|
|
36
|
+
import vt from "../order/index.esm.js";
|
|
37
|
+
import Ct from "../page-header/index.esm.js";
|
|
38
|
+
import wt from "../page-footer/index.esm.js";
|
|
39
|
+
import Tt from "../pagination/index.esm.js";
|
|
40
|
+
import Ft from "../progress/index.esm.js";
|
|
41
|
+
import Bt from "../query-solution/index.esm.js";
|
|
42
|
+
import kt from "../radio-group/index.esm.js";
|
|
43
|
+
import jt from "../rate/index.esm.js";
|
|
44
|
+
import Pt from "../response-toolbar/index.esm.js";
|
|
45
|
+
import xt from "../response-layout/index.esm.js";
|
|
46
|
+
import St from "../response-layout-editor/index.esm.js";
|
|
47
|
+
import Mt from "../search-box/index.esm.js";
|
|
48
|
+
import At from "../section/index.esm.js";
|
|
49
|
+
import Dt from "../smoke-detector/index.esm.js";
|
|
50
|
+
import Et from "../splitter/index.esm.js";
|
|
51
|
+
import Vt from "../step/index.esm.js";
|
|
52
|
+
import Ot from "../switch/index.esm.js";
|
|
53
|
+
import $t from "../tabs/index.esm.js";
|
|
54
|
+
import Nt from "../tags/index.esm.js";
|
|
55
|
+
import Lt from "../text/index.esm.js";
|
|
56
|
+
import It from "../time-picker/index.esm.js";
|
|
57
|
+
import Gt from "../transfer/index.esm.js";
|
|
58
|
+
import qt from "../tree-view/index.esm.js";
|
|
59
|
+
import Rt from "../uploader/index.esm.js";
|
|
60
|
+
import Ut from "../verify-detail/index.esm.js";
|
|
61
|
+
import Wt from "../weather/index.esm.js";
|
|
62
|
+
import Ht from "../video/index.esm.js";
|
|
63
|
+
import zt from "../textarea/index.esm.js";
|
|
64
|
+
import _t from "../schema-selector/index.esm.js";
|
|
65
|
+
import Jt from "../tree-grid/index.esm.js";
|
|
66
|
+
import "../external-container/index.esm.js";
|
|
67
|
+
import { getSchemaByType as pe } from "../dynamic-resolver/index.esm.js";
|
|
68
|
+
const ye = {}, ge = {};
|
|
69
|
+
function re(e) {
|
|
70
|
+
const { properties: t, title: n } = e, r = Object.keys(t).reduce((o, s) => (o[s] = t[s].type === "object" && t[s].properties ? re(t[s]) : Ie(t[s].default), o), {});
|
|
70
71
|
return r.id = `${n}-${Date.now()}`, r;
|
|
71
72
|
}
|
|
72
|
-
function
|
|
73
|
-
const n =
|
|
73
|
+
function _(e, t = {}) {
|
|
74
|
+
const n = ye[e];
|
|
74
75
|
if (n) {
|
|
75
|
-
let r =
|
|
76
|
-
const o =
|
|
77
|
-
return r = o ? o({ getSchemaByType:
|
|
76
|
+
let r = re(n);
|
|
77
|
+
const o = ge[e];
|
|
78
|
+
return r = o ? o({ getSchemaByType: _ }, r, t) : r, r;
|
|
78
79
|
}
|
|
79
80
|
return null;
|
|
80
81
|
}
|
|
81
82
|
function Qt(e, t) {
|
|
82
|
-
const n =
|
|
83
|
-
return Object.keys(e).reduce((r, o) => (r[o] = e[o], r), n), n;
|
|
83
|
+
const n = re(t);
|
|
84
|
+
return Object.keys(e).reduce((r, o) => (r[o] && typeof r[o] == "object" ? Object.assign(r[o], e[o]) : r[o] = e[o], r), n), n;
|
|
84
85
|
}
|
|
85
|
-
function
|
|
86
|
+
function Zt(e, t) {
|
|
86
87
|
return Object.keys(e).filter((r) => e[r] != null).reduce((r, o) => {
|
|
87
88
|
if (t.has(o)) {
|
|
88
|
-
const
|
|
89
|
-
if (typeof
|
|
90
|
-
r[
|
|
89
|
+
const s = t.get(o);
|
|
90
|
+
if (typeof s == "string")
|
|
91
|
+
r[s] = e[o];
|
|
91
92
|
else {
|
|
92
|
-
const
|
|
93
|
-
Object.assign(r,
|
|
93
|
+
const i = s(o, e[o], e);
|
|
94
|
+
Object.assign(r, i);
|
|
94
95
|
}
|
|
95
96
|
} else
|
|
96
97
|
r[o] = e[o];
|
|
97
98
|
return r;
|
|
98
99
|
}, {});
|
|
99
100
|
}
|
|
100
|
-
function
|
|
101
|
+
function Xt(e, t, n = /* @__PURE__ */ new Map()) {
|
|
101
102
|
const r = Qt(e, t);
|
|
102
|
-
return
|
|
103
|
+
return Zt(r, n);
|
|
103
104
|
}
|
|
104
|
-
function
|
|
105
|
-
function t(a,
|
|
105
|
+
function Yt(e = {}) {
|
|
106
|
+
function t(a, d, c, y) {
|
|
106
107
|
if (typeof c == "number")
|
|
107
108
|
return y[a].length === c;
|
|
108
109
|
if (typeof c == "object") {
|
|
109
|
-
const
|
|
110
|
-
if (
|
|
111
|
-
return Number(y[a].length) !== Number(
|
|
112
|
-
if (
|
|
113
|
-
return Number(y[a].length) >= Number(
|
|
114
|
-
if (
|
|
115
|
-
return Number(y[a].length) <= Number(
|
|
110
|
+
const w = Object.keys(c)[0], l = c[w];
|
|
111
|
+
if (w === "not")
|
|
112
|
+
return Number(y[a].length) !== Number(l);
|
|
113
|
+
if (w === "moreThan")
|
|
114
|
+
return Number(y[a].length) >= Number(l);
|
|
115
|
+
if (w === "lessThan")
|
|
116
|
+
return Number(y[a].length) <= Number(l);
|
|
116
117
|
}
|
|
117
118
|
return !1;
|
|
118
119
|
}
|
|
119
|
-
function n(a,
|
|
120
|
+
function n(a, d, c, y) {
|
|
120
121
|
return y[a] && y[a].propertyValue && String(y[a].propertyValue.value) === String(c);
|
|
121
122
|
}
|
|
122
123
|
const r = /* @__PURE__ */ new Map([
|
|
123
124
|
["length", t],
|
|
124
125
|
["getProperty", n]
|
|
125
126
|
]);
|
|
126
|
-
Object.keys(e).reduce((a,
|
|
127
|
-
function o(a,
|
|
127
|
+
Object.keys(e).reduce((a, d) => (a.set(d, e[d]), a), r);
|
|
128
|
+
function o(a, d) {
|
|
128
129
|
const c = a;
|
|
129
|
-
return typeof
|
|
130
|
+
return typeof d == "number" ? [{ target: c, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: c, operator: "getProperty", param: a, value: !!d }] : typeof d == "object" ? Object.keys(d).map((y) => {
|
|
130
131
|
if (y === "length")
|
|
131
|
-
return { target: c, operator: "length", param: null, value:
|
|
132
|
-
const
|
|
133
|
-
return { target: c, operator: "getProperty", param:
|
|
132
|
+
return { target: c, operator: "length", param: null, value: d[y] };
|
|
133
|
+
const w = y, l = d[y];
|
|
134
|
+
return { target: c, operator: "getProperty", param: w, value: l };
|
|
134
135
|
}) : [];
|
|
135
136
|
}
|
|
136
|
-
function
|
|
137
|
+
function s(a) {
|
|
137
138
|
return Object.keys(a).reduce((c, y) => {
|
|
138
|
-
const
|
|
139
|
-
return c.push(...
|
|
139
|
+
const w = o(y, a[y]);
|
|
140
|
+
return c.push(...w), c;
|
|
140
141
|
}, []);
|
|
141
142
|
}
|
|
142
|
-
function
|
|
143
|
+
function i(a, d) {
|
|
143
144
|
if (r.has(a.operator)) {
|
|
144
145
|
const c = r.get(a.operator);
|
|
145
|
-
return c && c(a.target, a.param, a.value,
|
|
146
|
+
return c && c(a.target, a.param, a.value, d) || !1;
|
|
146
147
|
}
|
|
147
148
|
return !1;
|
|
148
149
|
}
|
|
149
|
-
function
|
|
150
|
-
return
|
|
150
|
+
function u(a, d) {
|
|
151
|
+
return s(a).reduce((w, l) => w && i(l, d), !0);
|
|
151
152
|
}
|
|
152
|
-
function
|
|
153
|
-
const c = Object.keys(a), y = c.includes("allOf"),
|
|
154
|
-
return y ? !
|
|
153
|
+
function p(a, d) {
|
|
154
|
+
const c = Object.keys(a), y = c.includes("allOf"), w = c.includes("anyOf"), l = y || w, T = (l ? a[l ? y ? "allOf" : "anyOf" : "allOf"] : [a]).map((M) => u(M, d));
|
|
155
|
+
return y ? !T.includes(!1) : T.includes(!0);
|
|
155
156
|
}
|
|
156
|
-
return { parseValueSchema:
|
|
157
|
+
return { parseValueSchema: p };
|
|
157
158
|
}
|
|
158
|
-
const
|
|
159
|
-
|
|
160
|
-
ButtonGroup: { type: "ButtonGroup", name: "按钮组", icon: "ButtonGroup" },
|
|
159
|
+
const j = {
|
|
160
|
+
button: { type: "button", name: "按钮", icon: "Button" },
|
|
161
161
|
"response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
|
|
162
|
-
"response-toolbar-item": { type: "response-toolbar-item", name: "
|
|
162
|
+
"response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
|
|
163
163
|
"content-container": { type: "content-container", name: "容器", icon: "ContentContainer" },
|
|
164
|
-
DisplayField: { type: "DisplayField", name: "标签", icon: "DisplayField" },
|
|
165
164
|
"input-group": { type: "input-group", name: "文本", icon: "TextBox" },
|
|
166
165
|
textarea: { type: "textarea", name: "多行文本", icon: "MultiTextBox" },
|
|
167
166
|
lookup: { type: "lookup", name: "帮助", icon: "LookupEdit" },
|
|
@@ -172,112 +171,41 @@ const T = {
|
|
|
172
171
|
"check-box": { type: "check-box", name: "复选框", icon: "CheckBox" },
|
|
173
172
|
"check-group": { type: "check-group", name: "复选框组", icon: "CheckGroup" },
|
|
174
173
|
"combo-list": { type: "combo-list", name: "下拉列表", icon: "EnumField" },
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
FlowLayout: { type: "FlowLayout", name: "流布局" },
|
|
179
|
-
ResponseLayout: { type: "ResponseLayout", name: "布局容器", icon: "ResponseLayout3" },
|
|
180
|
-
ResponseLayoutItem: { type: "ResponseLayoutItem", name: "布局", icon: "ResponseLayout1" },
|
|
174
|
+
"response-form": { type: "response-form", name: "卡片面板", icon: "Form" },
|
|
175
|
+
"response-layout": { type: "response-layout", name: "布局容器", icon: "ResponseLayout3" },
|
|
176
|
+
"response-layout-item": { type: "response-layout-item", name: "布局", icon: "ResponseLayout1" },
|
|
181
177
|
"tree-grid": { type: "tree-grid", name: "树表格", icon: "TreeGrid" },
|
|
182
|
-
|
|
183
|
-
FieldSet: { type: "FieldSet", name: "分组", icon: "FieldSet" },
|
|
184
|
-
Form: { type: "Form", name: "卡片面板", icon: "Form" },
|
|
185
|
-
QueryForm: { type: "QueryForm", name: "查询面板", icon: "Form" },
|
|
178
|
+
"tree-grid-column": { type: "tree-grid-column", name: "树表格列" },
|
|
186
179
|
"data-grid": { type: "data-grid", name: "表格", icon: "DataGrid" },
|
|
187
180
|
"data-grid-column": { type: "data-grid-column", name: "表格列" },
|
|
188
|
-
|
|
189
|
-
Module: { type: "Module", name: "模块", icon: "Module" },
|
|
181
|
+
module: { type: "Module", name: "模块", icon: "Module" },
|
|
190
182
|
component: { type: "component", name: "组件", icon: "Component" },
|
|
191
|
-
ExternalContainer: { type: "ExternalContainer", name: "外部容器", icon: "ContentContainer" },
|
|
192
|
-
Image: { type: "Image", name: "图像", icon: "Image" },
|
|
193
|
-
ImageUpload: { type: "ImageUpload", name: "图片上传", icon: "imageupload" },
|
|
194
|
-
HiddenContainer: { type: "HiddenContainer", name: "隐藏区域", icon: "ContentContainer" },
|
|
195
|
-
ModalContainer: { type: "ModalContainer", name: "弹窗容器", icon: "ContentContainer" },
|
|
196
|
-
RouteContainer: { type: "RouteContainer", name: "路由区域", icon: "ContentContainer" },
|
|
197
183
|
tabs: { type: "tabs", name: "标签页", icon: "Tab" },
|
|
198
184
|
"tab-page": { type: "tab-page", name: "标签页项", dependentParentControl: "Tab" },
|
|
199
185
|
"tab-toolbar-item": { type: "tab-toolbar-item", name: "标签页工具栏按钮", icon: "Button" },
|
|
200
|
-
|
|
201
|
-
Sidebar: { type: "Sidebar", name: "侧边栏", icon: "Sidebar" },
|
|
202
|
-
HtmlTemplate: { type: "HtmlTemplate", name: "模版容器", icon: "HtmlTemplate" },
|
|
203
|
-
ListView: { type: "ListView", name: "列表", icon: "ListView" },
|
|
204
|
-
RichTextBox: { type: "RichTextBox", name: "富文本", icon: "RichTextBox" },
|
|
205
|
-
TimeSpinner: { type: "TimeSpinner", name: "时间调节器", icon: "TimePicker" },
|
|
206
|
-
TimePicker: { type: "TimePicker", name: "时间选择", icon: "TimePicker" },
|
|
186
|
+
"time-picker": { type: "time-picker", name: "时间选择", icon: "TimePicker" },
|
|
207
187
|
section: { type: "section", name: "分组面板", icon: "Section" },
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
WizardDetail: { type: "WizardDetail", name: "向导详情页" },
|
|
215
|
-
WizardDetailContainer: { type: "WizardDetailContainer", name: "向导详情容器" },
|
|
216
|
-
Wizard: { type: "Wizard", name: "向导", icon: "Wizard" },
|
|
217
|
-
MultiSelect: { type: "MultiSelect", name: "数据分配", icon: "MultiSelect" },
|
|
218
|
-
Steps: { type: "Steps", name: "步骤条", icon: "Steps" },
|
|
219
|
-
avatar: { type: "avatar", name: "头像", icon: "Avatar" },
|
|
220
|
-
ListFilter: { type: "ListFilter", name: "筛选条", icon: "ListFilter" },
|
|
221
|
-
ListNav: { type: "ListNav", name: "列表导航", icon: "ListNav" },
|
|
222
|
-
NumberRange: { type: "NumberRange", name: "数字区间选择", icon: "NumericBox" },
|
|
223
|
-
Scrollspy: { type: "Scrollspy", name: "滚动监听", icon: "Scrollspy" },
|
|
224
|
-
LanguageTextBox: { type: "LanguageTextBox", name: "多语言输入框", icon: "LanguageTextBox" },
|
|
225
|
-
ComponentRef: { type: "ComponentRef", name: "组件引用节点" },
|
|
226
|
-
FileUpload: { type: "FileUpload", name: "附件上传", icon: "FileUpload" },
|
|
227
|
-
FilePreview: { type: "FilePreview", name: "附件预览", icon: "FilePreview" },
|
|
228
|
-
ViewChange: { type: "ViewChange", name: "多视图切换", icon: "Button" },
|
|
229
|
-
MultiViewContainer: { type: "MultiViewContainer", name: "多视图", icon: "MultiViewContainer" },
|
|
230
|
-
MultiViewItem: { type: "MultiViewItem", name: "多视图项", dependentParentControl: "MultiViewContainer" },
|
|
231
|
-
Footer: { type: "Footer", name: "页脚" },
|
|
232
|
-
DiscussionEditor: { type: "DiscussionEditor", name: "评论编辑区", icon: "DiscussionEditor" },
|
|
233
|
-
DiscussionList: { type: "DiscussionList", name: "评论列表", icon: "DiscussionList" },
|
|
234
|
-
NavTab: { type: "NavTab", name: "标签类导航", icon: "NavTab" },
|
|
235
|
-
Tags: { type: "Tags", name: "标记组", icon: "Tags" },
|
|
236
|
-
Portlet: { type: "Portlet", name: "小部件", icon: "dingzhi" },
|
|
188
|
+
"section-toolbar": { type: "section-toolbar", name: "分组面板工具栏" },
|
|
189
|
+
"section-toolbar-item": { type: "section-toolbar-item", name: "分组面板按钮" },
|
|
190
|
+
splitter: { type: "splitter", name: "分栏面板", icon: "Splitter" },
|
|
191
|
+
"splitter-pane": { type: "splitter-pane", name: "分栏面板项", dependentParentControl: "Splitter" },
|
|
192
|
+
"component-ref": { type: "component-ref", name: "组件引用节点" },
|
|
193
|
+
uploader: { type: "uploader", name: "附件上传", icon: "FileUpload" },
|
|
237
194
|
"page-header": { type: "page-header", name: "页头", icon: "Header" },
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
TabToolbar: { type: "TabToolbar", name: "标签页工具栏", icon: "TabToolbar" },
|
|
247
|
-
HeaderToolBar: { type: "HeaderToolBar", name: "头部组件工具栏", icon: "HeaderToolBar" },
|
|
248
|
-
ModalFooterToolBar: { type: "ModalFooterToolBar", name: "底部组件工具栏", icon: "ModalFooterToolBar" },
|
|
249
|
-
HeaderToolBarItem: { type: "HeaderToolBarItem", name: "头部组件工具栏按钮", icon: "HeaderToolBarItem" },
|
|
250
|
-
ModalFooterToolBarItem: { type: "ModalFooterToolBarItem", name: "底部组件工具栏按钮", icon: "ModalFooterToolBarItem" },
|
|
251
|
-
OrganizationSelector: { type: "OrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
252
|
-
AdminOrganizationSelector: { type: "AdminOrganizationSelector", name: "组织选择", icon: "OrganizationSelector" },
|
|
253
|
-
EmployeeSelector: { type: "EmployeeSelector", name: "人员选择", icon: "PersonnelSelector" },
|
|
254
|
-
OaRelation: { type: "OaRelation", name: "关联行政审批", icon: "TextBox" },
|
|
255
|
-
CitySelector: { type: "CitySelector", name: "城市选择", icon: "CitySelector" },
|
|
256
|
-
ExtIntergration: { type: "ExtIntergration", name: "外部服务集成", icon: "ViewModel" },
|
|
257
|
-
AppointmentCalendar: { type: "AppointmentCalendar", name: "预约日历", icon: "DateBox" },
|
|
258
|
-
/** 查询类 start */
|
|
259
|
-
Charts: { type: "Charts", name: "图表", icon: "Charts" },
|
|
260
|
-
QdpFramework: { type: "QdpFramework", name: "查询结果工具栏", icon: "QdpFramework" },
|
|
261
|
-
SpreadSheet: { type: "SpreadSheet", name: "查询表格控件", icon: "Charts" },
|
|
262
|
-
QdpConditionDialog: { type: "QdpConditionDialog", name: "查询筛选对话框", icon: "ContentContainer" },
|
|
263
|
-
QdpConditionDialogTab: { type: "QdpConditionDialogTab", name: "查询筛选标签页", icon: "Tab" },
|
|
264
|
-
/** 查询类 end */
|
|
265
|
-
/** 审批类 start */
|
|
266
|
-
ApprovalLogs: { type: "ApprovalLogs", name: "审批记录", icon: "ApprovalLogs" },
|
|
267
|
-
ApprovalComments: { type: "ApprovalComments", name: "审批意见", icon: "shenpiyijian" }
|
|
268
|
-
/** 审批类 end */
|
|
269
|
-
}, fe = {}, Yt = {};
|
|
270
|
-
Xt();
|
|
271
|
-
function Z(e, t, n = /* @__PURE__ */ new Map(), r = (l, d, m) => d, o = {}, i = (l) => l) {
|
|
272
|
-
return de[t.title] = t, me[t.title] = r, fe[t.title] = o, Yt[t.title] = i, (l = {}) => {
|
|
273
|
-
const d = Zt(l, t, n), m = Object.keys(e).reduce((a, u) => (a[u] = e[u].default, a), {});
|
|
274
|
-
return Object.assign(m, d);
|
|
195
|
+
"page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
|
|
196
|
+
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" }
|
|
197
|
+
}, be = {}, Kt = {};
|
|
198
|
+
Yt();
|
|
199
|
+
function X(e, t, n = /* @__PURE__ */ new Map(), r = (i, u, p) => u, o = {}, s = (i) => i) {
|
|
200
|
+
return ye[t.title] = t, ge[t.title] = r, be[t.title] = o, Kt[t.title] = s, (i = {}) => {
|
|
201
|
+
const u = Xt(i, t, n), p = Object.keys(e).reduce((a, d) => (a[d] = e[d].default, a), {});
|
|
202
|
+
return Object.assign(p, u);
|
|
275
203
|
};
|
|
276
204
|
}
|
|
277
|
-
function
|
|
205
|
+
function he(e, t) {
|
|
278
206
|
return { customClass: t.class, customStyle: t.style };
|
|
279
207
|
}
|
|
280
|
-
function
|
|
208
|
+
function en() {
|
|
281
209
|
function e(t) {
|
|
282
210
|
return t.editor;
|
|
283
211
|
}
|
|
@@ -285,25 +213,25 @@ function Kt() {
|
|
|
285
213
|
resolve: e
|
|
286
214
|
};
|
|
287
215
|
}
|
|
288
|
-
const
|
|
289
|
-
["appearance",
|
|
216
|
+
const ae = /* @__PURE__ */ new Map([
|
|
217
|
+
["appearance", he]
|
|
290
218
|
]);
|
|
291
|
-
function
|
|
219
|
+
function tn(e, t, n, r) {
|
|
292
220
|
const o = e.getSchemaByType("section");
|
|
293
221
|
return o.id = `${r}-section`, o.appearance = { class: "f-section-form f-section-in-main" }, o.mainTitle = "标题", o.contents = [t], o;
|
|
294
222
|
}
|
|
295
|
-
function
|
|
223
|
+
function nn(e, t, n, r) {
|
|
296
224
|
const o = e.getSchemaByType("component");
|
|
297
225
|
return o.id = `${r}-component`, o.componentType = "form-col-1", o.appearance = {
|
|
298
226
|
class: "f-struct-form f-struct-wrapper"
|
|
299
227
|
}, o.contents = [t], o;
|
|
300
228
|
}
|
|
301
|
-
function
|
|
229
|
+
function on(e, t, n) {
|
|
302
230
|
t.appearance = { class: "f-form-layout farris-form farris-form-controls-inline" };
|
|
303
|
-
const r =
|
|
304
|
-
return
|
|
231
|
+
const r = tn(e, t, n, t.id);
|
|
232
|
+
return nn(e, r, n, t.id);
|
|
305
233
|
}
|
|
306
|
-
const
|
|
234
|
+
const rn = "https://json-schema.org/draft/2020-12/schema", an = "https://farris-design.gitee.io/response-form.schema.json", sn = "response-form", ln = "A Farris Data Collection Component", cn = "object", un = {
|
|
307
235
|
id: {
|
|
308
236
|
description: "The unique identifier for a form group",
|
|
309
237
|
type: "string"
|
|
@@ -331,18 +259,18 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
331
259
|
type: "array",
|
|
332
260
|
default: []
|
|
333
261
|
}
|
|
334
|
-
},
|
|
262
|
+
}, pn = [
|
|
335
263
|
"id",
|
|
336
264
|
"type"
|
|
337
|
-
],
|
|
338
|
-
$schema:
|
|
339
|
-
$id:
|
|
340
|
-
title:
|
|
341
|
-
description:
|
|
342
|
-
type:
|
|
343
|
-
properties:
|
|
344
|
-
required:
|
|
345
|
-
},
|
|
265
|
+
], dn = {
|
|
266
|
+
$schema: rn,
|
|
267
|
+
$id: an,
|
|
268
|
+
title: sn,
|
|
269
|
+
description: ln,
|
|
270
|
+
type: cn,
|
|
271
|
+
properties: un,
|
|
272
|
+
required: pn
|
|
273
|
+
}, fn = "response-form", mn = "A Farris Component", yn = "object", gn = {
|
|
346
274
|
basic: {
|
|
347
275
|
description: "Basic Infomation",
|
|
348
276
|
title: "基本信息",
|
|
@@ -364,30 +292,30 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
364
292
|
}
|
|
365
293
|
}
|
|
366
294
|
}
|
|
367
|
-
},
|
|
368
|
-
title:
|
|
369
|
-
description:
|
|
370
|
-
type:
|
|
371
|
-
categories:
|
|
372
|
-
},
|
|
295
|
+
}, bn = {
|
|
296
|
+
title: fn,
|
|
297
|
+
description: mn,
|
|
298
|
+
type: yn,
|
|
299
|
+
categories: gn
|
|
300
|
+
}, ve = {
|
|
373
301
|
customClass: { type: String, default: "" }
|
|
374
|
-
},
|
|
302
|
+
}, de = X(ve, dn, ae, on, bn), ee = /* @__PURE__ */ q({
|
|
375
303
|
name: "FResponseForm",
|
|
376
|
-
props:
|
|
304
|
+
props: ve,
|
|
377
305
|
emits: [],
|
|
378
306
|
setup(e, t) {
|
|
379
|
-
const n =
|
|
380
|
-
const o = e.customClass.split(" "),
|
|
307
|
+
const n = m(), r = k(() => {
|
|
308
|
+
const o = e.customClass.split(" "), s = {
|
|
381
309
|
"drag-container": !0
|
|
382
310
|
};
|
|
383
|
-
return o.reduce((
|
|
311
|
+
return o.reduce((i, u) => (i[u] = !0, i), s), s;
|
|
384
312
|
});
|
|
385
313
|
return () => A("div", {
|
|
386
314
|
ref: n,
|
|
387
315
|
class: r.value
|
|
388
316
|
}, [t.slots.default && t.slots.default()]);
|
|
389
317
|
}
|
|
390
|
-
}),
|
|
318
|
+
}), hn = "https://json-schema.org/draft/2020-12/schema", vn = "https://farris-design.gitee.io/form-group.schema.json", Cn = "form-group", wn = "A Farris Input Component", Tn = "object", Fn = {
|
|
391
319
|
id: {
|
|
392
320
|
description: "The unique identifier for a form group",
|
|
393
321
|
type: "string"
|
|
@@ -428,18 +356,18 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
428
356
|
description: "",
|
|
429
357
|
type: "number"
|
|
430
358
|
}
|
|
431
|
-
},
|
|
359
|
+
}, Bn = [
|
|
432
360
|
"id",
|
|
433
361
|
"type"
|
|
434
|
-
],
|
|
435
|
-
$schema:
|
|
436
|
-
$id:
|
|
437
|
-
title:
|
|
438
|
-
description:
|
|
439
|
-
type:
|
|
440
|
-
properties:
|
|
441
|
-
required:
|
|
442
|
-
},
|
|
362
|
+
], Ce = {
|
|
363
|
+
$schema: hn,
|
|
364
|
+
$id: vn,
|
|
365
|
+
title: Cn,
|
|
366
|
+
description: wn,
|
|
367
|
+
type: Tn,
|
|
368
|
+
properties: Fn,
|
|
369
|
+
required: Bn
|
|
370
|
+
}, J = {
|
|
443
371
|
id: { type: String, default: "" },
|
|
444
372
|
customClass: { type: String, default: "" },
|
|
445
373
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
@@ -452,113 +380,113 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
452
380
|
required: { type: Boolean, default: !1 },
|
|
453
381
|
showLabel: { type: Boolean, default: !0 },
|
|
454
382
|
type: { type: String, default: "input-group" }
|
|
455
|
-
},
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
383
|
+
}, fe = X(
|
|
384
|
+
J,
|
|
385
|
+
Ce,
|
|
386
|
+
ae,
|
|
459
387
|
void 0
|
|
460
|
-
),
|
|
461
|
-
function
|
|
462
|
-
var
|
|
388
|
+
), kn = en();
|
|
389
|
+
function ie(e, t, n) {
|
|
390
|
+
var $;
|
|
463
391
|
function r() {
|
|
464
392
|
n != null && n.resolveComponentContext && n.resolveComponentContext();
|
|
465
393
|
}
|
|
466
394
|
r();
|
|
467
|
-
const o = n && n.getStyles && n.getStyles() || "",
|
|
468
|
-
function
|
|
395
|
+
const o = n && n.getStyles && n.getStyles() || "", s = n && n.getDesignerClass && n.getDesignerClass() || "", i = m();
|
|
396
|
+
function u() {
|
|
469
397
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
|
|
470
398
|
}
|
|
471
|
-
function
|
|
399
|
+
function p() {
|
|
472
400
|
return !1;
|
|
473
401
|
}
|
|
474
402
|
function a() {
|
|
475
403
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanDeleteComponent ? n.checkCanDeleteComponent() : !0;
|
|
476
404
|
}
|
|
477
|
-
function
|
|
405
|
+
function d() {
|
|
478
406
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 : n && n.hideNestedPaddingInDesginerView ? n.hideNestedPaddingInDesginerView() : !1;
|
|
479
407
|
}
|
|
480
|
-
function c(
|
|
481
|
-
if (!
|
|
408
|
+
function c(B) {
|
|
409
|
+
if (!B || !B.value)
|
|
482
410
|
return null;
|
|
483
|
-
if (
|
|
484
|
-
return
|
|
485
|
-
const x =
|
|
486
|
-
return
|
|
411
|
+
if (B.value.schema && B.value.schema.type === "component")
|
|
412
|
+
return B.value;
|
|
413
|
+
const x = m(B == null ? void 0 : B.value.parent), F = c(x);
|
|
414
|
+
return F || null;
|
|
487
415
|
}
|
|
488
|
-
function y(
|
|
489
|
-
const { componentInstance: x, designerItemElementRef:
|
|
490
|
-
return !x || !x.value ? null : x.value.canMove ?
|
|
416
|
+
function y(B = t) {
|
|
417
|
+
const { componentInstance: x, designerItemElementRef: F } = B;
|
|
418
|
+
return !x || !x.value ? null : x.value.canMove ? F : y(B.parent);
|
|
491
419
|
}
|
|
492
|
-
function
|
|
493
|
-
return !!n && n.canAccepts(
|
|
420
|
+
function w(B) {
|
|
421
|
+
return !!n && n.canAccepts(B);
|
|
494
422
|
}
|
|
495
|
-
function
|
|
423
|
+
function l() {
|
|
496
424
|
return (t == null ? void 0 : t.schema.label) || (t == null ? void 0 : t.schema.title) || (t == null ? void 0 : t.schema.name);
|
|
497
425
|
}
|
|
498
|
-
function
|
|
426
|
+
function f() {
|
|
499
427
|
}
|
|
500
|
-
function g(
|
|
428
|
+
function g(B, x) {
|
|
501
429
|
x && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(x);
|
|
502
430
|
}
|
|
503
|
-
function
|
|
504
|
-
const { componentType: x } =
|
|
505
|
-
let
|
|
506
|
-
n && n.onResolveNewComponentSchema && (
|
|
431
|
+
function T(B) {
|
|
432
|
+
const { componentType: x } = B;
|
|
433
|
+
let F = _(x, B);
|
|
434
|
+
n && n.onResolveNewComponentSchema && (F = n.onResolveNewComponentSchema(B, F));
|
|
507
435
|
const E = x.toLowerCase().replace("-", "_");
|
|
508
|
-
return
|
|
436
|
+
return F && !F.id && F.type === x && (F.id = `${E}_${Math.random().toString().slice(2, 6)}`), F;
|
|
509
437
|
}
|
|
510
|
-
function D(
|
|
511
|
-
const
|
|
512
|
-
N.parentComponentInstance =
|
|
513
|
-
let O =
|
|
514
|
-
n && n.onAcceptNewChildElement && (O = n.onAcceptNewChildElement(
|
|
515
|
-
const
|
|
516
|
-
return O && !O.id && O.type ===
|
|
438
|
+
function D(B, x) {
|
|
439
|
+
const F = String(B.getAttribute("data-controltype")), E = B.getAttribute("data-feature"), N = E ? JSON.parse(E) : {};
|
|
440
|
+
N.parentComponentInstance = i.value;
|
|
441
|
+
let O = _(F, N);
|
|
442
|
+
n && n.onAcceptNewChildElement && (O = n.onAcceptNewChildElement(B, x, O));
|
|
443
|
+
const G = F.toLowerCase().replace("-", "_");
|
|
444
|
+
return O && !O.id && O.type === F && (O.id = `${G}_${Math.random().toString().slice(2, 6)}`), O;
|
|
517
445
|
}
|
|
518
|
-
function
|
|
446
|
+
function M(B) {
|
|
519
447
|
}
|
|
520
|
-
function
|
|
448
|
+
function S(...B) {
|
|
521
449
|
if (n && n.getPropsConfig)
|
|
522
|
-
return n.getPropsConfig(...
|
|
450
|
+
return n.getPropsConfig(...B);
|
|
523
451
|
}
|
|
524
|
-
return
|
|
525
|
-
canMove:
|
|
526
|
-
canSelectParent:
|
|
452
|
+
return i.value = {
|
|
453
|
+
canMove: u(),
|
|
454
|
+
canSelectParent: p(),
|
|
527
455
|
canDelete: a(),
|
|
528
|
-
canNested: !
|
|
456
|
+
canNested: !d(),
|
|
529
457
|
contents: t == null ? void 0 : t.schema.contents,
|
|
530
458
|
elementRef: e,
|
|
531
|
-
parent: (
|
|
459
|
+
parent: ($ = t == null ? void 0 : t.parent) == null ? void 0 : $.componentInstance,
|
|
532
460
|
schema: t == null ? void 0 : t.schema,
|
|
533
461
|
styles: o,
|
|
534
|
-
designerClass:
|
|
535
|
-
canAccepts:
|
|
462
|
+
designerClass: s,
|
|
463
|
+
canAccepts: w,
|
|
536
464
|
getBelongedComponentInstance: c,
|
|
537
465
|
getDraggableDesignItemElement: y,
|
|
538
|
-
getDraggingDisplayText:
|
|
539
|
-
getPropConfig:
|
|
540
|
-
getDragScopeElement:
|
|
466
|
+
getDraggingDisplayText: l,
|
|
467
|
+
getPropConfig: S,
|
|
468
|
+
getDragScopeElement: f,
|
|
541
469
|
onAcceptMovedChildElement: g,
|
|
542
470
|
onAcceptNewChildElement: D,
|
|
543
|
-
onChildElementMovedOut:
|
|
544
|
-
addNewChildComponentSchema:
|
|
471
|
+
onChildElementMovedOut: M,
|
|
472
|
+
addNewChildComponentSchema: T,
|
|
545
473
|
updateDragAndDropRules: r,
|
|
546
|
-
triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved ||
|
|
547
|
-
triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted ||
|
|
548
|
-
},
|
|
474
|
+
triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || m(!1),
|
|
475
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || m(!1)
|
|
476
|
+
}, i;
|
|
549
477
|
}
|
|
550
|
-
function
|
|
478
|
+
function jn() {
|
|
551
479
|
function e(t) {
|
|
552
|
-
var o,
|
|
480
|
+
var o, s;
|
|
553
481
|
if (!t)
|
|
554
482
|
return !1;
|
|
555
483
|
const n = ((o = t.targetContainer) == null ? void 0 : o.componentInstance) && t.targetContainer.componentInstance.value;
|
|
556
484
|
if (!n)
|
|
557
485
|
return !1;
|
|
558
|
-
const r = (
|
|
486
|
+
const r = (s = n.schema.appearance) == null ? void 0 : s.class;
|
|
559
487
|
if (t.controlCategory === "input" || t.controlType === "form-group") {
|
|
560
|
-
const
|
|
561
|
-
if (n.schema.type !== "response-layout-item" && !
|
|
488
|
+
const i = n.schema.type, u = (i === "response-form" || i === "content-container") && r && r.includes("farris-form");
|
|
489
|
+
if (n.schema.type !== "response-layout-item" && !u)
|
|
562
490
|
return !1;
|
|
563
491
|
}
|
|
564
492
|
return t.controlType !== "field-set";
|
|
@@ -567,7 +495,7 @@ function Bn() {
|
|
|
567
495
|
basalDragulaRuleForContainer: e
|
|
568
496
|
};
|
|
569
497
|
}
|
|
570
|
-
const
|
|
498
|
+
const Pn = "https://json-schema.org/draft/2020-12/schema", xn = "https://farris-design.gitee.io/dragging-rules.schema.json", Sn = "Dragging Rules", Mn = "The rules of designer canvas", An = "object", Dn = {
|
|
571
499
|
"f-page": {
|
|
572
500
|
description: "The root class of page designed by farris.",
|
|
573
501
|
type: "object",
|
|
@@ -1131,39 +1059,39 @@ const Sn = "https://json-schema.org/draft/2020-12/schema", Pn = "https://farris-
|
|
|
1131
1059
|
description: "",
|
|
1132
1060
|
type: "object"
|
|
1133
1061
|
}
|
|
1134
|
-
},
|
|
1135
|
-
$schema:
|
|
1136
|
-
$id:
|
|
1137
|
-
title:
|
|
1138
|
-
description:
|
|
1139
|
-
type:
|
|
1140
|
-
properties:
|
|
1141
|
-
required:
|
|
1142
|
-
},
|
|
1143
|
-
function
|
|
1144
|
-
function e(
|
|
1062
|
+
}, En = [], Vn = {
|
|
1063
|
+
$schema: Pn,
|
|
1064
|
+
$id: xn,
|
|
1065
|
+
title: Sn,
|
|
1066
|
+
description: Mn,
|
|
1067
|
+
type: An,
|
|
1068
|
+
properties: Dn,
|
|
1069
|
+
required: En
|
|
1070
|
+
}, te = /* @__PURE__ */ new Map();
|
|
1071
|
+
function On() {
|
|
1072
|
+
function e(l, f, g, T) {
|
|
1145
1073
|
var D;
|
|
1146
1074
|
if (typeof g == "number")
|
|
1147
|
-
return ((D =
|
|
1075
|
+
return ((D = T[l]) == null ? void 0 : D.length) === g;
|
|
1148
1076
|
if (typeof g == "object") {
|
|
1149
|
-
const
|
|
1150
|
-
if (
|
|
1151
|
-
return Number(
|
|
1152
|
-
if (
|
|
1153
|
-
return Number(
|
|
1154
|
-
if (
|
|
1155
|
-
return Number(
|
|
1077
|
+
const M = Object.keys(g)[0], S = g[M];
|
|
1078
|
+
if (M === "not")
|
|
1079
|
+
return Number(T[l].length) !== Number(S);
|
|
1080
|
+
if (M === "moreThan")
|
|
1081
|
+
return Number(T[l].length) >= Number(S);
|
|
1082
|
+
if (M === "lessThan")
|
|
1083
|
+
return Number(T[l].length) <= Number(S);
|
|
1156
1084
|
}
|
|
1157
1085
|
return !1;
|
|
1158
1086
|
}
|
|
1159
|
-
function t(
|
|
1160
|
-
return typeof g == "boolean" ?
|
|
1087
|
+
function t(l, f, g, T) {
|
|
1088
|
+
return typeof g == "boolean" ? T.childrenClassList.includes(f) === !!g : !1;
|
|
1161
1089
|
}
|
|
1162
|
-
function n(
|
|
1163
|
-
return typeof g == "boolean" ?
|
|
1090
|
+
function n(l, f, g, T) {
|
|
1091
|
+
return typeof g == "boolean" ? T.parentClassList.includes(f) === !!g : !1;
|
|
1164
1092
|
}
|
|
1165
|
-
function r(
|
|
1166
|
-
return typeof g == "boolean" ?
|
|
1093
|
+
function r(l, f, g, T) {
|
|
1094
|
+
return typeof g == "boolean" ? T.parentClassList.includes(f) === !!g : !1;
|
|
1167
1095
|
}
|
|
1168
1096
|
const o = /* @__PURE__ */ new Map([
|
|
1169
1097
|
["length", e],
|
|
@@ -1171,121 +1099,121 @@ function En() {
|
|
|
1171
1099
|
["hasSibling", r],
|
|
1172
1100
|
["hasParent", n]
|
|
1173
1101
|
]);
|
|
1174
|
-
function
|
|
1175
|
-
const g =
|
|
1176
|
-
return typeof
|
|
1177
|
-
if (
|
|
1178
|
-
return { target: g, operator: "length", param: null, value:
|
|
1179
|
-
const D =
|
|
1180
|
-
return { target: g, operator:
|
|
1102
|
+
function s(l, f) {
|
|
1103
|
+
const g = l;
|
|
1104
|
+
return typeof f == "number" ? [{ target: g, operator: "length", param: null, value: Number(f) }] : typeof f == "object" ? Object.keys(f).map((T) => {
|
|
1105
|
+
if (T === "length")
|
|
1106
|
+
return { target: g, operator: "length", param: null, value: f[T] };
|
|
1107
|
+
const D = T, M = f[T];
|
|
1108
|
+
return { target: g, operator: l === "children" ? "hasChildren" : l === "parent" ? "hasParent" : "hasSibling", param: D, value: M };
|
|
1181
1109
|
}) : [];
|
|
1182
1110
|
}
|
|
1183
|
-
function l
|
|
1184
|
-
if (o.has(
|
|
1185
|
-
const g = o.get(
|
|
1186
|
-
return g && g(
|
|
1111
|
+
function i(l, f) {
|
|
1112
|
+
if (o.has(l.operator)) {
|
|
1113
|
+
const g = o.get(l.operator);
|
|
1114
|
+
return g && g(l.target, l.param, l.value, f) || !1;
|
|
1187
1115
|
}
|
|
1188
1116
|
return !1;
|
|
1189
1117
|
}
|
|
1190
|
-
function
|
|
1191
|
-
return Object.keys(
|
|
1192
|
-
const
|
|
1193
|
-
return
|
|
1194
|
-
}, []).reduce((
|
|
1118
|
+
function u(l, f) {
|
|
1119
|
+
return Object.keys(l).reduce((M, S) => {
|
|
1120
|
+
const $ = s(S, l[S]);
|
|
1121
|
+
return M.push(...$), M;
|
|
1122
|
+
}, []).reduce((M, S) => M && i(S, f), !0);
|
|
1195
1123
|
}
|
|
1196
|
-
function
|
|
1197
|
-
const g = Object.keys(
|
|
1198
|
-
return
|
|
1124
|
+
function p(l, f) {
|
|
1125
|
+
const g = Object.keys(l), T = g.includes("allOf"), D = g.includes("anyOf"), M = T || D, B = (M ? l[M ? T ? "allOf" : "anyOf" : "allOf"] : [l]).map((F) => u(F, f));
|
|
1126
|
+
return T ? !B.includes(!1) : B.includes(!0);
|
|
1199
1127
|
}
|
|
1200
|
-
function a(
|
|
1201
|
-
const g =
|
|
1202
|
-
return g ? typeof g == "boolean" ? g : typeof g == "object" ?
|
|
1128
|
+
function a(l, f) {
|
|
1129
|
+
const g = l.const;
|
|
1130
|
+
return g ? typeof g == "boolean" ? g : typeof g == "object" ? p(g, f) : !1 : !1;
|
|
1203
1131
|
}
|
|
1204
|
-
function
|
|
1205
|
-
return (
|
|
1132
|
+
function d(l) {
|
|
1133
|
+
return (f) => {
|
|
1206
1134
|
const g = { canAccept: !0, fixed: !1, hidePadding: !1 };
|
|
1207
|
-
return
|
|
1208
|
-
const
|
|
1209
|
-
return
|
|
1135
|
+
return l && l.properties && Object.keys(l.properties).reduce((T, D) => {
|
|
1136
|
+
const M = l.properties[D];
|
|
1137
|
+
return T[D] = a(M, f), T;
|
|
1210
1138
|
}, g), g;
|
|
1211
1139
|
};
|
|
1212
1140
|
}
|
|
1213
|
-
function c(
|
|
1214
|
-
if (
|
|
1215
|
-
const { rules:
|
|
1216
|
-
g.set(
|
|
1217
|
-
(
|
|
1141
|
+
function c(l, f, g) {
|
|
1142
|
+
if (f.type === "object" && f.properties) {
|
|
1143
|
+
const { rules: T, contents: D } = f.properties;
|
|
1144
|
+
g.set(l, d(T)), D && Object.keys(D.properties).forEach(
|
|
1145
|
+
(M) => c(M, D.properties[M], g)
|
|
1218
1146
|
);
|
|
1219
1147
|
}
|
|
1220
1148
|
}
|
|
1221
1149
|
function y() {
|
|
1222
|
-
const { properties:
|
|
1223
|
-
Object.keys(
|
|
1224
|
-
c(
|
|
1150
|
+
const { properties: l } = Vn;
|
|
1151
|
+
Object.keys(l).forEach((f) => {
|
|
1152
|
+
c(f, l[f], te);
|
|
1225
1153
|
});
|
|
1226
1154
|
}
|
|
1227
|
-
function
|
|
1155
|
+
function w(l, f) {
|
|
1228
1156
|
const g = { canAccept: !0, fixed: !1, hidePadding: !0 };
|
|
1229
|
-
return
|
|
1157
|
+
return te.has(l) ? te.get(l)(f) : g;
|
|
1230
1158
|
}
|
|
1231
|
-
return y(), { getRuleValue:
|
|
1159
|
+
return y(), { getRuleValue: w };
|
|
1232
1160
|
}
|
|
1233
|
-
function
|
|
1161
|
+
function $n(e, t) {
|
|
1234
1162
|
var x;
|
|
1235
|
-
const n = e.schema, r = (x = e.parent) == null ? void 0 : x.schema, o =
|
|
1236
|
-
let
|
|
1237
|
-
function c(
|
|
1238
|
-
return a && a.componentClassList && a.componentClassList.includes("f-form-layout") && a.componentClassList.includes("farris-form") ?
|
|
1239
|
-
}
|
|
1240
|
-
function y(
|
|
1241
|
-
return !(!
|
|
1242
|
-
}
|
|
1243
|
-
function
|
|
1244
|
-
|
|
1245
|
-
const
|
|
1246
|
-
const
|
|
1247
|
-
return
|
|
1248
|
-
}, []) : [],
|
|
1163
|
+
const n = e.schema, r = (x = e.parent) == null ? void 0 : x.schema, o = On(), s = m(!1), i = m(!1);
|
|
1164
|
+
let u = !0, p = !1, a, d = !1;
|
|
1165
|
+
function c(F) {
|
|
1166
|
+
return a && a.componentClassList && a.componentClassList.includes("f-form-layout") && a.componentClassList.includes("farris-form") ? F.sourceType === "control" && F.controlCategory === "input" || F.sourceType === "move" && F.controlType === "form-group" : !0;
|
|
1167
|
+
}
|
|
1168
|
+
function y(F) {
|
|
1169
|
+
return !(!jn().basalDragulaRuleForContainer(F) || !u || !c(F));
|
|
1170
|
+
}
|
|
1171
|
+
function w() {
|
|
1172
|
+
s.value = !1, i.value = !1;
|
|
1173
|
+
const F = n, E = F.appearance && F.appearance.class || "", N = E.split(" "), O = F.contents || [], G = O.length ? O[0] : null, P = G && G.appearance ? G.appearance.class : "", V = P ? P.split(" ") : [], R = O.length ? O.reduce((le, K) => {
|
|
1174
|
+
const ce = K && K.appearance ? K.appearance.class : "", De = ce ? ce.split(" ") : [];
|
|
1175
|
+
return le.push(...De), le;
|
|
1176
|
+
}, []) : [], W = r, Y = W && W.appearance && W.appearance.class || "", xe = Y ? Y.split(" ") : [];
|
|
1249
1177
|
a = {
|
|
1250
1178
|
componentClass: E,
|
|
1251
1179
|
componentClassList: N,
|
|
1252
1180
|
childContents: O,
|
|
1253
|
-
firstChildContent:
|
|
1254
|
-
firstChildClass:
|
|
1181
|
+
firstChildContent: G,
|
|
1182
|
+
firstChildClass: P,
|
|
1255
1183
|
firstChildClassList: V,
|
|
1256
|
-
parent:
|
|
1257
|
-
parentClass:
|
|
1258
|
-
parentClassList:
|
|
1184
|
+
parent: W,
|
|
1185
|
+
parentClass: Y,
|
|
1186
|
+
parentClassList: xe,
|
|
1259
1187
|
children: O,
|
|
1260
|
-
childrenClassList:
|
|
1188
|
+
childrenClassList: R
|
|
1261
1189
|
};
|
|
1262
|
-
const { canAccept:
|
|
1263
|
-
return
|
|
1190
|
+
const { canAccept: Se, fixed: Me, hidePadding: Ae } = o.getRuleValue(N[0], a);
|
|
1191
|
+
return u = Se, p = Ae, d = Me, !0;
|
|
1264
1192
|
}
|
|
1265
|
-
function
|
|
1266
|
-
|
|
1193
|
+
function l(F) {
|
|
1194
|
+
oe();
|
|
1267
1195
|
}
|
|
1268
|
-
function
|
|
1196
|
+
function f() {
|
|
1269
1197
|
return n.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
|
|
1270
1198
|
}
|
|
1271
|
-
function g(
|
|
1199
|
+
function g(F, E) {
|
|
1272
1200
|
const N = n;
|
|
1273
1201
|
if ((N.appearance && N.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1274
|
-
const { label:
|
|
1275
|
-
return V.editor = E, V.label =
|
|
1202
|
+
const { label: P } = F, V = _("form-group");
|
|
1203
|
+
return V.editor = E, V.label = P, T(V), delete V.editor.id, delete V.editor.binding, delete V.editor.appearance, delete V.editor.visible, V;
|
|
1276
1204
|
}
|
|
1277
1205
|
return E;
|
|
1278
1206
|
}
|
|
1279
|
-
function
|
|
1207
|
+
function T(F) {
|
|
1280
1208
|
const E = e.componentInstance.value.getBelongedComponentInstance(e.componentInstance);
|
|
1281
1209
|
if (E && E.schema && E.schema.componentType) {
|
|
1282
1210
|
const N = E.schema.componentType, O = D(N);
|
|
1283
|
-
|
|
1211
|
+
F.appearance || (F.appearance = {}), F.appearance.class = O;
|
|
1284
1212
|
}
|
|
1285
1213
|
}
|
|
1286
|
-
function D(
|
|
1214
|
+
function D(F) {
|
|
1287
1215
|
let E = "";
|
|
1288
|
-
switch (
|
|
1216
|
+
switch (F) {
|
|
1289
1217
|
case "form-col-1": {
|
|
1290
1218
|
E = "col-12 col-md-12 col-xl-12 col-el-12";
|
|
1291
1219
|
break;
|
|
@@ -1317,57 +1245,57 @@ function Vn(e, t) {
|
|
|
1317
1245
|
}
|
|
1318
1246
|
return E;
|
|
1319
1247
|
}
|
|
1320
|
-
function
|
|
1248
|
+
function M(F, E, N) {
|
|
1321
1249
|
const O = n;
|
|
1322
1250
|
if ((O.appearance && O.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1323
|
-
const V = String(
|
|
1324
|
-
return
|
|
1251
|
+
const V = String(F.innerText), R = _("form-group");
|
|
1252
|
+
return R.editor = N, R.label = V, R;
|
|
1325
1253
|
}
|
|
1326
1254
|
return N;
|
|
1327
1255
|
}
|
|
1328
|
-
function
|
|
1329
|
-
return !
|
|
1256
|
+
function S() {
|
|
1257
|
+
return !d;
|
|
1330
1258
|
}
|
|
1331
|
-
function
|
|
1332
|
-
return !
|
|
1259
|
+
function $() {
|
|
1260
|
+
return !d;
|
|
1333
1261
|
}
|
|
1334
|
-
function
|
|
1335
|
-
return
|
|
1262
|
+
function B() {
|
|
1263
|
+
return p;
|
|
1336
1264
|
}
|
|
1337
1265
|
return {
|
|
1338
1266
|
canAccepts: y,
|
|
1339
|
-
checkCanDeleteComponent:
|
|
1340
|
-
checkCanMoveComponent:
|
|
1341
|
-
getStyles:
|
|
1342
|
-
hideNestedPaddingInDesginerView:
|
|
1343
|
-
onAcceptNewChildElement:
|
|
1344
|
-
onAcceptMovedChildElement:
|
|
1345
|
-
resolveComponentContext:
|
|
1267
|
+
checkCanDeleteComponent: $,
|
|
1268
|
+
checkCanMoveComponent: S,
|
|
1269
|
+
getStyles: f,
|
|
1270
|
+
hideNestedPaddingInDesginerView: B,
|
|
1271
|
+
onAcceptNewChildElement: M,
|
|
1272
|
+
onAcceptMovedChildElement: l,
|
|
1273
|
+
resolveComponentContext: w,
|
|
1346
1274
|
onResolveNewComponentSchema: g,
|
|
1347
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1348
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1275
|
+
triggerBelongedComponentToMoveWhenMoved: s,
|
|
1276
|
+
triggerBelongedComponentToDeleteWhenDeleted: i
|
|
1349
1277
|
};
|
|
1350
1278
|
}
|
|
1351
|
-
const
|
|
1279
|
+
const Nn = /* @__PURE__ */ q({
|
|
1352
1280
|
name: "FResponseFormDesign",
|
|
1353
|
-
props:
|
|
1281
|
+
props: J,
|
|
1354
1282
|
emits: [],
|
|
1355
1283
|
setup(e, t) {
|
|
1356
|
-
const n =
|
|
1357
|
-
|
|
1358
|
-
const o =
|
|
1284
|
+
const n = m(), r = z("design-item-context");
|
|
1285
|
+
z("designer-host-service");
|
|
1286
|
+
const o = $n(r), s = ie(n, r, o);
|
|
1359
1287
|
U(() => {
|
|
1360
|
-
n.value.componentInstance =
|
|
1361
|
-
}), t.expose(
|
|
1362
|
-
const
|
|
1363
|
-
const
|
|
1288
|
+
n.value.componentInstance = s;
|
|
1289
|
+
}), t.expose(s.value);
|
|
1290
|
+
const i = k(() => {
|
|
1291
|
+
const u = e.customClass.split(" "), p = {
|
|
1364
1292
|
"drag-container": !0
|
|
1365
1293
|
};
|
|
1366
|
-
return
|
|
1294
|
+
return u.reduce((a, d) => (a[d] = !0, a), p), p;
|
|
1367
1295
|
});
|
|
1368
1296
|
return () => A("div", {
|
|
1369
1297
|
ref: n,
|
|
1370
|
-
class:
|
|
1298
|
+
class: i.value,
|
|
1371
1299
|
"data-dragref": `${r.schema.id}-container`,
|
|
1372
1300
|
"data-associate": `${r.schema.id}-component`
|
|
1373
1301
|
}, [t.slots.default && t.slots.default()]);
|
|
@@ -1377,32 +1305,32 @@ const On = /* @__PURE__ */ G({
|
|
|
1377
1305
|
required: { type: Boolean, default: !1 },
|
|
1378
1306
|
text: { type: String, default: "" },
|
|
1379
1307
|
title: { type: String }
|
|
1380
|
-
},
|
|
1308
|
+
}, we = /* @__PURE__ */ q({
|
|
1381
1309
|
name: "FDynamicFormLabel",
|
|
1382
1310
|
props: Ln,
|
|
1383
1311
|
emits: [],
|
|
1384
1312
|
setup(e, t) {
|
|
1385
|
-
const n =
|
|
1386
|
-
return
|
|
1313
|
+
const n = m(e.title || e.text), r = m(e.required), o = m(e.text);
|
|
1314
|
+
return I(() => e.text, () => {
|
|
1387
1315
|
o.value = e.text;
|
|
1388
|
-
}),
|
|
1389
|
-
|
|
1316
|
+
}), I(() => e.required, (s, i) => {
|
|
1317
|
+
s !== i && (r.value = s);
|
|
1390
1318
|
}), () => A("label", {
|
|
1391
1319
|
class: "col-form-label",
|
|
1392
1320
|
title: n.value
|
|
1393
1321
|
}, [r.value && A("span", {
|
|
1394
1322
|
class: "farris-label-info text-danger"
|
|
1395
|
-
}, [
|
|
1323
|
+
}, [Oe("*")]), A("span", {
|
|
1396
1324
|
class: "farris-label-text"
|
|
1397
1325
|
}, [o.value])]);
|
|
1398
1326
|
}
|
|
1399
|
-
}),
|
|
1400
|
-
["appearance",
|
|
1327
|
+
}), In = /* @__PURE__ */ new Map([
|
|
1328
|
+
["appearance", he]
|
|
1401
1329
|
]);
|
|
1402
|
-
function
|
|
1330
|
+
function Gn(e, t, n) {
|
|
1403
1331
|
return t;
|
|
1404
1332
|
}
|
|
1405
|
-
const
|
|
1333
|
+
const qn = "https://json-schema.org/draft/2020-12/schema", Rn = "https://farris-design.gitee.io/input-group.schema.json", Un = "input-group", Wn = "A Farris Input Component", Hn = "object", zn = {
|
|
1406
1334
|
id: {
|
|
1407
1335
|
description: "The unique identifier for a Input Group",
|
|
1408
1336
|
type: "string"
|
|
@@ -1604,18 +1532,18 @@ const $n = "https://json-schema.org/draft/2020-12/schema", Rn = "https://farris-
|
|
|
1604
1532
|
type: "string",
|
|
1605
1533
|
default: ""
|
|
1606
1534
|
}
|
|
1607
|
-
},
|
|
1535
|
+
}, _n = [
|
|
1608
1536
|
"id",
|
|
1609
1537
|
"type"
|
|
1610
|
-
],
|
|
1611
|
-
$schema:
|
|
1538
|
+
], Jn = {
|
|
1539
|
+
$schema: qn,
|
|
1612
1540
|
$id: Rn,
|
|
1613
|
-
title:
|
|
1614
|
-
description:
|
|
1615
|
-
type:
|
|
1616
|
-
properties:
|
|
1617
|
-
required:
|
|
1618
|
-
},
|
|
1541
|
+
title: Un,
|
|
1542
|
+
description: Wn,
|
|
1543
|
+
type: Hn,
|
|
1544
|
+
properties: zn,
|
|
1545
|
+
required: _n
|
|
1546
|
+
}, se = {
|
|
1619
1547
|
/** 是否自动完成 */
|
|
1620
1548
|
autocomplete: { Type: String, default: "off" },
|
|
1621
1549
|
/** 自定义CLASS */
|
|
@@ -1682,118 +1610,118 @@ const $n = "https://json-schema.org/draft/2020-12/schema", Rn = "https://farris-
|
|
|
1682
1610
|
*/
|
|
1683
1611
|
updateOn: { type: String, default: "blur" }
|
|
1684
1612
|
};
|
|
1685
|
-
|
|
1613
|
+
X(se, Jn, In, Gn);
|
|
1686
1614
|
function Qn(e, t, n, r) {
|
|
1687
|
-
const o =
|
|
1615
|
+
const o = m(e.disabled), s = m(!1), i = m("text"), u = m(e.showBorder), p = m(e.textAlign), a = m(e.updateOn), d = k(() => e.editable || !e.readonly), c = k(() => e.editable && !e.disabled && !e.readonly), y = k(() => !e.disabled && s.value), w = k(() => n.value === "" || n.value === null || n.value === void 0), l = k(() => (e.disabled || e.readonly) && !e.forcePlaceholder ? "" : e.placeholder), f = k(() => e.readonly || !e.editable), g = k(() => e.enableTitle ? n.value : ""), T = k(() => ({
|
|
1688
1616
|
"form-control": !0,
|
|
1689
1617
|
"f-utils-fill": !0,
|
|
1690
|
-
"text-left":
|
|
1691
|
-
"text-center":
|
|
1692
|
-
"text-right":
|
|
1693
|
-
})), D =
|
|
1694
|
-
const
|
|
1618
|
+
"text-left": p.value === "left",
|
|
1619
|
+
"text-center": p.value === "center",
|
|
1620
|
+
"text-right": p.value === "right"
|
|
1621
|
+
})), D = k(() => {
|
|
1622
|
+
const P = {
|
|
1695
1623
|
"f-cmp-inputgroup": !0,
|
|
1696
1624
|
"input-group": !0,
|
|
1697
1625
|
"f-state-disable": o.value,
|
|
1698
1626
|
"f-state-editable": c.value,
|
|
1699
|
-
"f-state-readonly":
|
|
1627
|
+
"f-state-readonly": f.value,
|
|
1700
1628
|
"f-state-focus": y.value
|
|
1701
1629
|
};
|
|
1702
|
-
return (e.customClass || "").split(" ").reduce((
|
|
1703
|
-
}),
|
|
1704
|
-
function
|
|
1705
|
-
n.value =
|
|
1630
|
+
return (e.customClass || "").split(" ").reduce((R, W) => (R[W] = !0, R), P), P;
|
|
1631
|
+
}), M = k(() => u.value ? "" : "border-width : 0 ");
|
|
1632
|
+
function S(P, V = !0) {
|
|
1633
|
+
n.value = P, r.value !== P && (r.value = P), V && t.emit("change", P), t.emit("update:modelValue", P), t.emit("update:value", P);
|
|
1706
1634
|
}
|
|
1707
|
-
|
|
1635
|
+
I(
|
|
1708
1636
|
() => e.modelValue,
|
|
1709
|
-
(
|
|
1710
|
-
|
|
1637
|
+
(P, V) => {
|
|
1638
|
+
P !== V && (n.value = P, r.value = P);
|
|
1711
1639
|
}
|
|
1712
|
-
),
|
|
1713
|
-
|
|
1640
|
+
), I(() => e.disabled, (P, V) => {
|
|
1641
|
+
P !== V && (o.value = P);
|
|
1714
1642
|
});
|
|
1715
|
-
function
|
|
1716
|
-
return
|
|
1643
|
+
function $(P) {
|
|
1644
|
+
return s.value = !1, t.emit("blur", P), P.stopPropagation(), !1;
|
|
1717
1645
|
}
|
|
1718
|
-
function
|
|
1719
|
-
t.emit("click",
|
|
1646
|
+
function B(P) {
|
|
1647
|
+
t.emit("click", P);
|
|
1720
1648
|
}
|
|
1721
|
-
function x(
|
|
1722
|
-
e.disabled || (
|
|
1649
|
+
function x(P) {
|
|
1650
|
+
e.disabled || (u.value && (s.value = !0), d.value && t.emit("focus", P));
|
|
1723
1651
|
}
|
|
1724
|
-
function
|
|
1725
|
-
t.emit("input",
|
|
1726
|
-
const V =
|
|
1652
|
+
function F(P) {
|
|
1653
|
+
t.emit("input", P.target.value);
|
|
1654
|
+
const V = P.target.value;
|
|
1727
1655
|
r.value = V, a.value === "input" && (t.emit("update:modelValue", V), t.emit("update:value", V));
|
|
1728
1656
|
}
|
|
1729
|
-
function E(
|
|
1730
|
-
t.emit("keydown",
|
|
1657
|
+
function E(P) {
|
|
1658
|
+
t.emit("keydown", P);
|
|
1731
1659
|
}
|
|
1732
|
-
function N(
|
|
1733
|
-
t.emit("keyup",
|
|
1660
|
+
function N(P) {
|
|
1661
|
+
t.emit("keyup", P);
|
|
1734
1662
|
}
|
|
1735
|
-
function O(
|
|
1736
|
-
|
|
1663
|
+
function O(P) {
|
|
1664
|
+
P.target.tagName !== "INPUT" && P.preventDefault(), P.stopPropagation();
|
|
1737
1665
|
}
|
|
1738
|
-
function
|
|
1666
|
+
function G(P) {
|
|
1739
1667
|
if (a.value === "blur") {
|
|
1740
|
-
const V =
|
|
1741
|
-
|
|
1668
|
+
const V = P.target.value;
|
|
1669
|
+
P.stopPropagation(), S(V);
|
|
1742
1670
|
}
|
|
1743
1671
|
}
|
|
1744
1672
|
return {
|
|
1745
|
-
changeTextBoxValue:
|
|
1673
|
+
changeTextBoxValue: S,
|
|
1746
1674
|
disabled: o,
|
|
1747
1675
|
displayText: r,
|
|
1748
1676
|
editable: c,
|
|
1749
1677
|
hasFocused: y,
|
|
1750
1678
|
inputGroupClass: D,
|
|
1751
|
-
inputType:
|
|
1752
|
-
isEmpty:
|
|
1679
|
+
inputType: i,
|
|
1680
|
+
isEmpty: w,
|
|
1753
1681
|
modelValue: n,
|
|
1754
|
-
readonly:
|
|
1755
|
-
onBlur:
|
|
1756
|
-
onClick:
|
|
1682
|
+
readonly: f,
|
|
1683
|
+
onBlur: $,
|
|
1684
|
+
onClick: B,
|
|
1757
1685
|
onFocus: x,
|
|
1758
|
-
onInput:
|
|
1686
|
+
onInput: F,
|
|
1759
1687
|
onKeydown: E,
|
|
1760
1688
|
onKeyup: N,
|
|
1761
1689
|
onMousedown: O,
|
|
1762
|
-
onTextBoxValueChange:
|
|
1763
|
-
placeholder:
|
|
1764
|
-
textBoxClass:
|
|
1690
|
+
onTextBoxValueChange: G,
|
|
1691
|
+
placeholder: l,
|
|
1692
|
+
textBoxClass: T,
|
|
1765
1693
|
textBoxTitle: g,
|
|
1766
|
-
inputGroupStyle:
|
|
1694
|
+
inputGroupStyle: M
|
|
1767
1695
|
};
|
|
1768
1696
|
}
|
|
1769
|
-
function
|
|
1770
|
-
const o =
|
|
1771
|
-
|
|
1772
|
-
const a =
|
|
1697
|
+
function Zn(e, t, n, r) {
|
|
1698
|
+
const o = m(e.disabled), s = m(!1), i = m("text"), u = m(e.showBorder), p = m(e.textAlign);
|
|
1699
|
+
k(() => e.editable || !e.readonly);
|
|
1700
|
+
const a = k(() => e.editable && !e.disabled && !e.readonly), d = k(() => !e.disabled && s.value), c = k(() => n.value === "" || n.value === null || n.value === void 0), y = k(() => e.placeholder), w = k(() => e.readonly || !e.editable), l = k(() => e.enableTitle ? n.value : ""), f = k(() => ({
|
|
1773
1701
|
"form-control": !0,
|
|
1774
1702
|
// 'f-utils-fill': true,
|
|
1775
|
-
"text-left":
|
|
1776
|
-
"text-center":
|
|
1777
|
-
"text-right":
|
|
1778
|
-
})), g =
|
|
1703
|
+
"text-left": p.value === "left",
|
|
1704
|
+
"text-center": p.value === "center",
|
|
1705
|
+
"text-right": p.value === "right"
|
|
1706
|
+
})), g = k(() => ({
|
|
1779
1707
|
"f-cmp-inputgroup": !0,
|
|
1780
1708
|
"input-group": !0,
|
|
1781
1709
|
"f-state-disable": !0,
|
|
1782
1710
|
"f-state-editable": !1,
|
|
1783
1711
|
"f-state-readonly": !0
|
|
1784
1712
|
// 'f-state-focus': hasFocused.value
|
|
1785
|
-
})),
|
|
1713
|
+
})), T = k(() => u.value ? "" : "border-width : 0 ");
|
|
1786
1714
|
return {
|
|
1787
1715
|
// changeTextBoxValue,
|
|
1788
1716
|
disabled: o,
|
|
1789
1717
|
displayText: r,
|
|
1790
1718
|
editable: a,
|
|
1791
|
-
hasFocused:
|
|
1719
|
+
hasFocused: d,
|
|
1792
1720
|
inputGroupClass: g,
|
|
1793
|
-
inputType:
|
|
1721
|
+
inputType: i,
|
|
1794
1722
|
isEmpty: c,
|
|
1795
1723
|
modelValue: n,
|
|
1796
|
-
readonly:
|
|
1724
|
+
readonly: w,
|
|
1797
1725
|
// onBlur,
|
|
1798
1726
|
// onClick,
|
|
1799
1727
|
// onFocus,
|
|
@@ -1803,39 +1731,39 @@ function _n(e, t, n, r) {
|
|
|
1803
1731
|
// onMousedown,
|
|
1804
1732
|
// onTextBoxValueChange,
|
|
1805
1733
|
placeholder: y,
|
|
1806
|
-
textBoxClass:
|
|
1807
|
-
textBoxTitle:
|
|
1808
|
-
inputGroupStyle:
|
|
1734
|
+
textBoxClass: f,
|
|
1735
|
+
textBoxTitle: l,
|
|
1736
|
+
inputGroupStyle: T
|
|
1809
1737
|
};
|
|
1810
1738
|
}
|
|
1811
|
-
function
|
|
1812
|
-
const r =
|
|
1813
|
-
function a(
|
|
1814
|
-
r.value =
|
|
1739
|
+
function Te(e, t, n) {
|
|
1740
|
+
const r = m(!1), o = k(() => e.enableClear && !e.readonly && !e.disabled), { changeTextBoxValue: s, displayText: i, hasFocused: u, isEmpty: p } = n;
|
|
1741
|
+
function a(f) {
|
|
1742
|
+
r.value = f;
|
|
1815
1743
|
}
|
|
1816
|
-
|
|
1817
|
-
|
|
1744
|
+
I(i, () => {
|
|
1745
|
+
u != null && u.value ? a(!!(i != null && i.value)) : a(!1);
|
|
1818
1746
|
});
|
|
1819
|
-
const
|
|
1747
|
+
const d = k(() => ({
|
|
1820
1748
|
"input-group-text": !0,
|
|
1821
1749
|
"input-group-clear": !0
|
|
1822
|
-
})), c =
|
|
1750
|
+
})), c = k(() => ({
|
|
1823
1751
|
width: "24px",
|
|
1824
1752
|
display: r.value ? "flex" : "none"
|
|
1825
1753
|
}));
|
|
1826
|
-
function y(
|
|
1827
|
-
|
|
1754
|
+
function y(f) {
|
|
1755
|
+
f.stopPropagation(), o.value && (s("", !0), a(!r.value), t.emit("clear"));
|
|
1828
1756
|
}
|
|
1829
|
-
function
|
|
1830
|
-
o.value && !
|
|
1757
|
+
function w(f) {
|
|
1758
|
+
o.value && !p.value && a(!0);
|
|
1831
1759
|
}
|
|
1832
|
-
function
|
|
1760
|
+
function l(f) {
|
|
1833
1761
|
o.value && a(!1);
|
|
1834
1762
|
}
|
|
1835
|
-
return { clearButtonClass:
|
|
1763
|
+
return { clearButtonClass: d, clearButtonStyle: c, hasShownClearButton: r, onClearValue: y, onMouseEnter: w, onMouseLeave: l, shouldShowClearButton: o };
|
|
1836
1764
|
}
|
|
1837
|
-
const
|
|
1838
|
-
function
|
|
1765
|
+
const Xn = ["moz", "ms", "webkit"];
|
|
1766
|
+
function Yn() {
|
|
1839
1767
|
let e = 0;
|
|
1840
1768
|
return (t) => {
|
|
1841
1769
|
const n = (/* @__PURE__ */ new Date()).getTime(), r = Math.max(0, 16 - (n - e)), o = setTimeout(() => {
|
|
@@ -1844,158 +1772,158 @@ function Xn() {
|
|
|
1844
1772
|
return e = n + r, o;
|
|
1845
1773
|
};
|
|
1846
1774
|
}
|
|
1847
|
-
function
|
|
1775
|
+
function Kn() {
|
|
1848
1776
|
if (typeof window > "u")
|
|
1849
1777
|
return () => 0;
|
|
1850
1778
|
if (window.requestAnimationFrame)
|
|
1851
1779
|
return window.requestAnimationFrame.bind(window);
|
|
1852
|
-
const e =
|
|
1853
|
-
return e ? window[`${e}RequestAnimationFrame`] :
|
|
1780
|
+
const e = Xn.filter((t) => `${t}RequestAnimationFrame` in window)[0];
|
|
1781
|
+
return e ? window[`${e}RequestAnimationFrame`] : Yn();
|
|
1854
1782
|
}
|
|
1855
|
-
|
|
1856
|
-
function
|
|
1857
|
-
const n =
|
|
1858
|
-
return { appendedButtonClass:
|
|
1783
|
+
Kn();
|
|
1784
|
+
function Fe(e, t) {
|
|
1785
|
+
const n = m(e.groupText), r = k(() => e.showButtonWhenDisabled && (e.readonly || e.disabled)), o = k(() => e.enableClear || !!e.groupText);
|
|
1786
|
+
return { appendedButtonClass: k(() => ({
|
|
1859
1787
|
"input-group-append": !0,
|
|
1860
1788
|
"append-force-show": r.value
|
|
1861
1789
|
})), appendedContent: n, shouldShowAppendedButton: o };
|
|
1862
1790
|
}
|
|
1863
|
-
function
|
|
1864
|
-
const { appendedContent: o } = r,
|
|
1865
|
-
|
|
1866
|
-
|
|
1791
|
+
function Be(e, t, n, r) {
|
|
1792
|
+
const { appendedContent: o } = r, s = m(e.enableViewPassword), i = k(() => e.type === "password"), u = '<span class="f-icon f-icon-eye" style="color: rgb(56, 143, 255);"></span>', p = '<span class="f-icon f-icon-eye"></span>', a = m(!1);
|
|
1793
|
+
I(() => [e.readonly, e.disabled], ([y, w]) => {
|
|
1794
|
+
i.value && (n.value = y || w ? "password" : n.value, o.value = y || w ? p : o.value);
|
|
1867
1795
|
});
|
|
1868
|
-
function
|
|
1869
|
-
return a.value = !a.value, n.value = a.value ? "text" : "password", o.value = a.value ?
|
|
1796
|
+
function d() {
|
|
1797
|
+
return a.value = !a.value, n.value = a.value ? "text" : "password", o.value = a.value ? u : p, !1;
|
|
1870
1798
|
}
|
|
1871
1799
|
function c() {
|
|
1872
|
-
n.value =
|
|
1800
|
+
n.value = i.value ? "password" : "text", o.value = i.value ? s.value ? p : "" : o.value;
|
|
1873
1801
|
}
|
|
1874
|
-
return c(), { isPassword:
|
|
1802
|
+
return c(), { isPassword: i, onClickAppendedButton: d };
|
|
1875
1803
|
}
|
|
1876
|
-
function
|
|
1877
|
-
const r =
|
|
1804
|
+
function eo(e, t, n) {
|
|
1805
|
+
const r = m(), {
|
|
1878
1806
|
onBlurTextBox: o,
|
|
1879
|
-
onFocusTextBox:
|
|
1880
|
-
onInput:
|
|
1881
|
-
onKeyDown:
|
|
1882
|
-
textBoxValue:
|
|
1883
|
-
} = n, a =
|
|
1807
|
+
onFocusTextBox: s,
|
|
1808
|
+
onInput: i,
|
|
1809
|
+
onKeyDown: u,
|
|
1810
|
+
textBoxValue: p
|
|
1811
|
+
} = n, a = k(() => e.disabled || e.readonly || !e.editable ? "" : e.placeholder), d = k(() => ({
|
|
1884
1812
|
"form-control": !0,
|
|
1885
1813
|
"f-utils-fill": !0
|
|
1886
|
-
})), c =
|
|
1814
|
+
})), c = k(() => ({
|
|
1887
1815
|
"text-align": e.textAlign
|
|
1888
1816
|
}));
|
|
1889
|
-
function y(
|
|
1890
|
-
|
|
1817
|
+
function y(f) {
|
|
1818
|
+
f.stopPropagation();
|
|
1891
1819
|
}
|
|
1892
|
-
function
|
|
1820
|
+
function w() {
|
|
1893
1821
|
e.selectOnCreated, e.focusOnCreated;
|
|
1894
1822
|
}
|
|
1895
|
-
async function
|
|
1896
|
-
|
|
1823
|
+
async function l(f) {
|
|
1824
|
+
s(f), await oe, w();
|
|
1897
1825
|
}
|
|
1898
1826
|
return U(async () => {
|
|
1899
|
-
await
|
|
1827
|
+
await oe, w();
|
|
1900
1828
|
}), () => A("input", {
|
|
1901
1829
|
ref: r,
|
|
1902
|
-
class:
|
|
1830
|
+
class: d.value,
|
|
1903
1831
|
style: c.value,
|
|
1904
1832
|
type: "text",
|
|
1905
|
-
value:
|
|
1833
|
+
value: p.value,
|
|
1906
1834
|
disabled: e.disabled,
|
|
1907
1835
|
readonly: e.readonly || !e.editable,
|
|
1908
1836
|
placeholder: a.value,
|
|
1909
1837
|
onBlur: o,
|
|
1910
1838
|
onChange: y,
|
|
1911
|
-
onFocus:
|
|
1912
|
-
onInput:
|
|
1913
|
-
onKeydown:
|
|
1839
|
+
onFocus: l,
|
|
1840
|
+
onInput: i,
|
|
1841
|
+
onKeydown: u
|
|
1914
1842
|
}, null);
|
|
1915
1843
|
}
|
|
1916
|
-
function
|
|
1844
|
+
function to(e, t, n) {
|
|
1917
1845
|
const {
|
|
1918
1846
|
canDownward: r,
|
|
1919
1847
|
canUpward: o,
|
|
1920
|
-
onClickDownButton:
|
|
1921
|
-
onClickUpButton:
|
|
1922
|
-
} = n,
|
|
1848
|
+
onClickDownButton: s,
|
|
1849
|
+
onClickUpButton: i
|
|
1850
|
+
} = n, u = k(() => ({
|
|
1923
1851
|
"input-group-append": !0,
|
|
1924
1852
|
"btn-group": !0,
|
|
1925
1853
|
"btn-group-number": !0
|
|
1926
|
-
})),
|
|
1854
|
+
})), p = k(() => ({
|
|
1927
1855
|
btn: !0,
|
|
1928
1856
|
"btn-secondary": !0,
|
|
1929
1857
|
"btn-number-flag": !0
|
|
1930
|
-
})), a =
|
|
1858
|
+
})), a = k(() => ({
|
|
1931
1859
|
cursor: o() ? "pointer" : "not-allowed",
|
|
1932
1860
|
"margin-left": 0
|
|
1933
|
-
})),
|
|
1861
|
+
})), d = k(() => ({
|
|
1934
1862
|
cursor: r() ? "pointer" : "not-allowed",
|
|
1935
1863
|
"margin-left": 0
|
|
1936
1864
|
}));
|
|
1937
1865
|
return () => A("div", {
|
|
1938
|
-
class:
|
|
1866
|
+
class: u.value
|
|
1939
1867
|
}, [A("button", {
|
|
1940
1868
|
title: "upButton",
|
|
1941
|
-
class:
|
|
1869
|
+
class: p.value,
|
|
1942
1870
|
style: a.value,
|
|
1943
|
-
onClick:
|
|
1871
|
+
onClick: i,
|
|
1944
1872
|
disabled: !o()
|
|
1945
1873
|
}, [A("span", {
|
|
1946
1874
|
class: "f-icon f-icon-arrow-chevron-up number-arrow-chevron"
|
|
1947
1875
|
}, null)]), A("button", {
|
|
1948
1876
|
title: "downButton",
|
|
1949
|
-
class:
|
|
1950
|
-
style:
|
|
1951
|
-
onClick:
|
|
1877
|
+
class: p.value,
|
|
1878
|
+
style: d.value,
|
|
1879
|
+
onClick: s,
|
|
1952
1880
|
disabled: !r()
|
|
1953
1881
|
}, [A("span", {
|
|
1954
1882
|
class: "f-icon f-icon-arrow-chevron-down number-arrow-chevron"
|
|
1955
1883
|
}, null)])]);
|
|
1956
1884
|
}
|
|
1957
|
-
function
|
|
1958
|
-
const n =
|
|
1959
|
-
displayValue:
|
|
1960
|
-
modelValue:
|
|
1885
|
+
function no(e, t) {
|
|
1886
|
+
const n = qe(e, t), r = Re(e, t, n), o = Ue(e, t, r, n), s = We(e, t, r, n, o), i = to(e, t, o), {
|
|
1887
|
+
displayValue: u,
|
|
1888
|
+
modelValue: p,
|
|
1961
1889
|
getRealValue: a
|
|
1962
|
-
} = n,
|
|
1890
|
+
} = n, d = eo(e, t, s), {
|
|
1963
1891
|
format: c
|
|
1964
1892
|
} = r, {
|
|
1965
1893
|
isFocus: y
|
|
1966
|
-
} =
|
|
1894
|
+
} = s, w = k(() => !e.disabled && !e.readonly);
|
|
1967
1895
|
return U(() => {
|
|
1968
|
-
const
|
|
1969
|
-
|
|
1970
|
-
}),
|
|
1971
|
-
const
|
|
1972
|
-
|
|
1973
|
-
}),
|
|
1974
|
-
|
|
1975
|
-
}),
|
|
1976
|
-
|
|
1896
|
+
const l = a(e.modelValue);
|
|
1897
|
+
u.value = c(l);
|
|
1898
|
+
}), I(() => [e.value], ([l]) => {
|
|
1899
|
+
const f = a(l);
|
|
1900
|
+
p.value = f, u.value = c(f);
|
|
1901
|
+
}), I(() => [e.modelValue], ([l]) => {
|
|
1902
|
+
l !== p.value && (p.value = l, !y.value && (u.value = c(a(l))));
|
|
1903
|
+
}), I(() => [e.precision, e.useThousands, e.prefix, e.suffix, e.showZero], () => {
|
|
1904
|
+
u.value = c(p.value);
|
|
1977
1905
|
}), () => A("div", {
|
|
1978
1906
|
class: "input-group f-state-hover flex-row f-cmp-number-spinner"
|
|
1979
|
-
}, [
|
|
1907
|
+
}, [d(), w.value && i()]);
|
|
1980
1908
|
}
|
|
1981
|
-
function
|
|
1982
|
-
const o =
|
|
1983
|
-
isPassword:
|
|
1984
|
-
} = n,
|
|
1909
|
+
function oo(e, t, n, r) {
|
|
1910
|
+
const o = m(), s = m(e.autocomplete), i = m(e.enableTitle), {
|
|
1911
|
+
isPassword: u
|
|
1912
|
+
} = n, p = m(e.minLength), a = m(e.maxLength), d = m(e.tabIndex), {
|
|
1985
1913
|
disabled: c,
|
|
1986
1914
|
displayText: y,
|
|
1987
|
-
inputType:
|
|
1988
|
-
onBlur:
|
|
1989
|
-
onFocus:
|
|
1915
|
+
inputType: w,
|
|
1916
|
+
onBlur: l,
|
|
1917
|
+
onFocus: f,
|
|
1990
1918
|
onInput: g,
|
|
1991
|
-
onClick:
|
|
1919
|
+
onClick: T,
|
|
1992
1920
|
onKeydown: D,
|
|
1993
|
-
onKeyup:
|
|
1994
|
-
onMousedown:
|
|
1995
|
-
onTextBoxValueChange:
|
|
1996
|
-
readonly:
|
|
1921
|
+
onKeyup: M,
|
|
1922
|
+
onMousedown: S,
|
|
1923
|
+
onTextBoxValueChange: $,
|
|
1924
|
+
readonly: B,
|
|
1997
1925
|
placeholder: x,
|
|
1998
|
-
textBoxClass:
|
|
1926
|
+
textBoxClass: F,
|
|
1999
1927
|
textBoxTitle: E
|
|
2000
1928
|
} = r;
|
|
2001
1929
|
return U(() => {
|
|
@@ -2003,35 +1931,35 @@ function to(e, t, n, r) {
|
|
|
2003
1931
|
}), () => A("input", {
|
|
2004
1932
|
ref: o,
|
|
2005
1933
|
name: "input-group-value",
|
|
2006
|
-
autocomplete:
|
|
2007
|
-
class:
|
|
1934
|
+
autocomplete: s.value,
|
|
1935
|
+
class: F.value,
|
|
2008
1936
|
disabled: c == null ? void 0 : c.value,
|
|
2009
1937
|
maxlength: a.value,
|
|
2010
|
-
minlength:
|
|
1938
|
+
minlength: p.value,
|
|
2011
1939
|
placeholder: x.value,
|
|
2012
|
-
readonly:
|
|
2013
|
-
tabindex:
|
|
2014
|
-
title:
|
|
2015
|
-
type:
|
|
1940
|
+
readonly: B == null ? void 0 : B.value,
|
|
1941
|
+
tabindex: d.value,
|
|
1942
|
+
title: i.value && !u.value ? E.value : "",
|
|
1943
|
+
type: w.value,
|
|
2016
1944
|
value: y == null ? void 0 : y.value,
|
|
2017
|
-
onBlur:
|
|
2018
|
-
onClick:
|
|
2019
|
-
onChange:
|
|
2020
|
-
onFocus:
|
|
1945
|
+
onBlur: l,
|
|
1946
|
+
onClick: T,
|
|
1947
|
+
onChange: $,
|
|
1948
|
+
onFocus: f,
|
|
2021
1949
|
onInput: g,
|
|
2022
1950
|
onKeydown: D,
|
|
2023
|
-
onKeyup:
|
|
2024
|
-
onMousedown:
|
|
1951
|
+
onKeyup: M,
|
|
1952
|
+
onMousedown: S
|
|
2025
1953
|
}, null);
|
|
2026
1954
|
}
|
|
2027
|
-
function
|
|
2028
|
-
const n =
|
|
1955
|
+
function ro(e, t) {
|
|
1956
|
+
const n = k(() => e.useExtendInfo && !!e.extendInfo), r = $e({
|
|
2029
1957
|
content: e.extendInfo
|
|
2030
1958
|
});
|
|
2031
1959
|
function o() {
|
|
2032
1960
|
t.emit("updateExtendInfo");
|
|
2033
1961
|
}
|
|
2034
|
-
return () => n.value &&
|
|
1962
|
+
return () => n.value && Ne(A("span", {
|
|
2035
1963
|
class: "input-group-before-tips",
|
|
2036
1964
|
onMouseenter: o
|
|
2037
1965
|
}, [A("i", {
|
|
@@ -2040,102 +1968,102 @@ function no(e, t) {
|
|
|
2040
1968
|
class: "tips-arrow"
|
|
2041
1969
|
}, null)]), [[Le("tooltip"), r]]);
|
|
2042
1970
|
}
|
|
2043
|
-
function
|
|
1971
|
+
function ke(e, t, n, r, o) {
|
|
2044
1972
|
const {
|
|
2045
|
-
appendedButtonClass:
|
|
2046
|
-
appendedContent:
|
|
2047
|
-
} = n,
|
|
2048
|
-
clearButtonClass:
|
|
1973
|
+
appendedButtonClass: s,
|
|
1974
|
+
appendedContent: i
|
|
1975
|
+
} = n, u = k(() => e.showButtonWhenDisabled && (!e.editable || !e.readonly) && !e.disabled), p = k(() => i.value && !t.slots.groupTextTemplate), a = k(() => !!t.slots.groupTextTemplate), {
|
|
1976
|
+
clearButtonClass: d,
|
|
2049
1977
|
clearButtonStyle: c,
|
|
2050
1978
|
onClearValue: y,
|
|
2051
|
-
shouldShowClearButton:
|
|
1979
|
+
shouldShowClearButton: w
|
|
2052
1980
|
} = r;
|
|
2053
|
-
function
|
|
1981
|
+
function l() {
|
|
2054
1982
|
return A("span", {
|
|
2055
1983
|
id: "clearIcon",
|
|
2056
|
-
class:
|
|
1984
|
+
class: d.value,
|
|
2057
1985
|
style: c.value,
|
|
2058
1986
|
onClick: (x) => y(x)
|
|
2059
1987
|
}, [A("i", {
|
|
2060
1988
|
class: "f-icon modal_close"
|
|
2061
1989
|
}, null)]);
|
|
2062
1990
|
}
|
|
2063
|
-
function
|
|
1991
|
+
function f(x) {
|
|
2064
1992
|
t.emit("iconMouseEnter", x);
|
|
2065
1993
|
}
|
|
2066
1994
|
function g(x) {
|
|
2067
1995
|
t.emit("iconMouseLeave", x);
|
|
2068
1996
|
}
|
|
2069
|
-
function
|
|
2070
|
-
|
|
1997
|
+
function T(x) {
|
|
1998
|
+
u.value && t.emit("clickHandle", {
|
|
2071
1999
|
originalEvent: x
|
|
2072
2000
|
}), x.stopPropagation();
|
|
2073
2001
|
}
|
|
2074
|
-
const D = e.type === "password" ? o.onClickAppendedButton :
|
|
2075
|
-
function
|
|
2002
|
+
const D = e.type === "password" ? o.onClickAppendedButton : T;
|
|
2003
|
+
function M() {
|
|
2076
2004
|
return A("span", {
|
|
2077
2005
|
class: "input-group-text",
|
|
2078
|
-
onMouseenter: (x) =>
|
|
2006
|
+
onMouseenter: (x) => f(x),
|
|
2079
2007
|
onMouseleave: (x) => g(x),
|
|
2080
|
-
innerHTML:
|
|
2008
|
+
innerHTML: i.value,
|
|
2081
2009
|
onClick: (x) => D(x)
|
|
2082
2010
|
}, null);
|
|
2083
2011
|
}
|
|
2084
|
-
function
|
|
2012
|
+
function S() {
|
|
2085
2013
|
return t.slots.groupTextTemplate && t.slots.groupTextTemplate();
|
|
2086
2014
|
}
|
|
2087
|
-
function
|
|
2088
|
-
return
|
|
2015
|
+
function $() {
|
|
2016
|
+
return p.value ? M : a.value ? S : "";
|
|
2089
2017
|
}
|
|
2090
|
-
const
|
|
2018
|
+
const B = $();
|
|
2091
2019
|
return () => A("div", {
|
|
2092
|
-
class:
|
|
2093
|
-
}, [
|
|
2020
|
+
class: s.value
|
|
2021
|
+
}, [w.value && l(), B && B()]);
|
|
2094
2022
|
}
|
|
2095
|
-
const
|
|
2023
|
+
const ao = /* @__PURE__ */ q({
|
|
2096
2024
|
name: "FInputGroup",
|
|
2097
|
-
props:
|
|
2025
|
+
props: se,
|
|
2098
2026
|
emits: ["clear", "change", "blur", "click", "clickHandle", "focus", "input", "keydown", "keyup", "iconMouseEnter", "iconMouseLeave", "update:modelValue", "update:value", "updateExtendInfo", "valueChange"],
|
|
2099
2027
|
setup(e, t) {
|
|
2100
|
-
const n =
|
|
2101
|
-
inputGroupClass:
|
|
2102
|
-
inputType:
|
|
2103
|
-
inputGroupStyle:
|
|
2104
|
-
} = o,
|
|
2028
|
+
const n = m(e.modelValue), r = m(e.modelValue), o = Qn(e, t, n, r), {
|
|
2029
|
+
inputGroupClass: s,
|
|
2030
|
+
inputType: i,
|
|
2031
|
+
inputGroupStyle: u
|
|
2032
|
+
} = o, p = Fe(e), {
|
|
2105
2033
|
shouldShowAppendedButton: a
|
|
2106
|
-
} =
|
|
2034
|
+
} = p, d = Te(e, t, o), {
|
|
2107
2035
|
onMouseEnter: c,
|
|
2108
2036
|
onMouseLeave: y
|
|
2109
|
-
} =
|
|
2110
|
-
|
|
2111
|
-
n.value =
|
|
2112
|
-
}),
|
|
2113
|
-
n.value =
|
|
2037
|
+
} = d, w = Be(e, t, i, p), l = no(e, t), f = oo(e, t, w, o), g = ke(e, t, p, d, w), T = ro(e, t), D = k(() => e.type === "number");
|
|
2038
|
+
I(() => [e.value], ([S]) => {
|
|
2039
|
+
n.value = S, r.value = S;
|
|
2040
|
+
}), I(() => [e.modelValue], ([S]) => {
|
|
2041
|
+
n.value = S, r.value = S;
|
|
2114
2042
|
}), U(() => {
|
|
2115
2043
|
e.value && (n.value = e.value, r.value = e.value);
|
|
2116
2044
|
});
|
|
2117
|
-
const
|
|
2045
|
+
const M = () => A(ue, null, [A("div", {
|
|
2118
2046
|
id: "inputGroup",
|
|
2119
|
-
class:
|
|
2120
|
-
style:
|
|
2047
|
+
class: s.value,
|
|
2048
|
+
style: u.value,
|
|
2121
2049
|
onMouseenter: c,
|
|
2122
2050
|
onMouseleave: y
|
|
2123
|
-
}, [D.value ?
|
|
2124
|
-
return () =>
|
|
2051
|
+
}, [D.value ? l() : A(ue, null, [T(), f(), a.value && g()])])]);
|
|
2052
|
+
return () => M();
|
|
2125
2053
|
}
|
|
2126
2054
|
}), b = {}, h = {}, v = {}, C = {};
|
|
2127
|
-
let
|
|
2128
|
-
function
|
|
2129
|
-
|
|
2055
|
+
let me = !1;
|
|
2056
|
+
function io() {
|
|
2057
|
+
me || (me = !0, ze.register(b, h, v, C), He.register(b, h, v, C), _e.register(b, h, v, C), Je.register(b, h, v, C), Qe.register(b, h, v, C), Ze.register(b, h, v, C), Xe.register(b, h, v, C), Ye.register(b, h, v, C), Ke.register(b, h, v, C), et.register(b, h, v, C), nt.register(b, h, v, C), tt.register(b, h, v, C), ot.register(b, h, v, C), rt.register(b, h, v, C), at.register(b, h, v, C), it.register(b, h, v, C), st.register(b, h, v, C), lt.register(b, h, v, C), ct.register(b, h, v, C), ut.register(b, h, v, C), pt.register(b, h, v, C), dt.register(b, h, v, C), mt.register(b, h, v, C), ft.register(b, h, v, C), yt.register(b, h, v, C), gt.register(b, h, v, C), bt.register(b, h, v, C), ht.register(b, h, v, C), Ge.register(b, h, v, C), vt.register(b, h, v, C), Ct.register(b, h, v, C), wt.register(b, h, v, C), Tt.register(b, h, v, C), Ft.register(b, h, v, C), Bt.register(b, h, v, C), kt.register(b, h, v, C), jt.register(b, h, v, C), xt.register(b, h, v, C), St.register(b, h, v, C), Pt.register(b, h, v, C), _t.register(b, h, v), Mt.register(b, h, v, C), At.register(b, h, v, C), Dt.register(b, h, v, C), Et.register(b, h, v, C), Vt.register(b, h, v, C), Ot.register(b, h, v, C), $t.register(b, h, v, C), Nt.register(b, h, v, C), Lt.register(b, h, v, C), It.register(b, h, v, C), Gt.register(b, h, v, C), qt.register(b, h, v, C), Ut.register(b, h, v, C), Rt.register(b, h, v, C), Wt.register(b, h, v, C), Ht.register(b, h, v, C), zt.register(b, h, v, C), Jt.register(b, h, v, C));
|
|
2130
2058
|
}
|
|
2131
|
-
function
|
|
2132
|
-
|
|
2133
|
-
function e(o,
|
|
2134
|
-
const
|
|
2135
|
-
return
|
|
2059
|
+
function je() {
|
|
2060
|
+
io();
|
|
2061
|
+
function e(o, s) {
|
|
2062
|
+
const i = h[o];
|
|
2063
|
+
return i ? i(s) : {};
|
|
2136
2064
|
}
|
|
2137
2065
|
function t(o) {
|
|
2138
|
-
return b[o] ||
|
|
2066
|
+
return b[o] || ao;
|
|
2139
2067
|
}
|
|
2140
2068
|
function n(o) {
|
|
2141
2069
|
switch (o) {
|
|
@@ -2190,209 +2118,274 @@ function we() {
|
|
|
2190
2118
|
return "onSchemaSelected";
|
|
2191
2119
|
case "mapping-editor":
|
|
2192
2120
|
return "onMappingFieldsChanged";
|
|
2121
|
+
case "textarea":
|
|
2122
|
+
return "onValueChange";
|
|
2193
2123
|
}
|
|
2194
2124
|
}
|
|
2195
2125
|
function r(o) {
|
|
2196
2126
|
switch (o) {
|
|
2197
2127
|
case "combo-list":
|
|
2198
2128
|
case "input-group":
|
|
2129
|
+
case "textarea":
|
|
2199
2130
|
return "onClear";
|
|
2200
2131
|
}
|
|
2201
2132
|
}
|
|
2202
2133
|
return { resolveEditorProps: e, resolveEditorType: t, getChangeFunctionName: n, getClearFunctionName: r };
|
|
2203
2134
|
}
|
|
2204
|
-
const
|
|
2135
|
+
const ne = /* @__PURE__ */ q({
|
|
2205
2136
|
name: "FDynamicFormGroup",
|
|
2206
|
-
props:
|
|
2137
|
+
props: J,
|
|
2207
2138
|
emits: ["change", "update:modelValue"],
|
|
2208
2139
|
setup(e, t) {
|
|
2209
|
-
const n =
|
|
2210
|
-
|
|
2211
|
-
const c =
|
|
2140
|
+
const n = m(e.id), r = m(e.customClass), o = m(e.editor), s = m(e.label), i = m(e.modelValue), u = m(e.readonly), p = m(e.required), a = m(e.showLabel), d = m(e.visible);
|
|
2141
|
+
m(e.type);
|
|
2142
|
+
const c = m(), {
|
|
2212
2143
|
resolveEditorProps: y,
|
|
2213
|
-
resolveEditorType:
|
|
2214
|
-
getChangeFunctionName:
|
|
2215
|
-
getClearFunctionName:
|
|
2216
|
-
} =
|
|
2144
|
+
resolveEditorType: w,
|
|
2145
|
+
getChangeFunctionName: l,
|
|
2146
|
+
getClearFunctionName: f
|
|
2147
|
+
} = je(), g = k(() => ({
|
|
2217
2148
|
"form-group": !0,
|
|
2218
2149
|
"farris-form-group": !0,
|
|
2219
2150
|
"common-group": !0,
|
|
2220
|
-
"q-state-readonly":
|
|
2151
|
+
"q-state-readonly": u.value
|
|
2221
2152
|
}));
|
|
2222
|
-
function
|
|
2223
|
-
|
|
2153
|
+
function T(S, $) {
|
|
2154
|
+
i.value = $ !== void 0 ? $ : S, t.emit("update:modelValue", i.value), t.emit("change", i.value);
|
|
2224
2155
|
}
|
|
2225
2156
|
function D() {
|
|
2226
2157
|
t.emit("update:modelValue", "");
|
|
2227
2158
|
}
|
|
2228
|
-
const
|
|
2229
|
-
const
|
|
2230
|
-
return
|
|
2159
|
+
const M = k(() => {
|
|
2160
|
+
const S = o.value.type || "input-group", $ = w(S), B = y(S, o.value), x = l(S), F = f(o.value.type);
|
|
2161
|
+
return B[x] = T, B[F] = D, () => A($, Z({
|
|
2231
2162
|
ref: c
|
|
2232
|
-
},
|
|
2233
|
-
modelValue:
|
|
2234
|
-
"onUpdate:modelValue": (E) =>
|
|
2163
|
+
}, B, {
|
|
2164
|
+
modelValue: i.value,
|
|
2165
|
+
"onUpdate:modelValue": (E) => i.value = E
|
|
2235
2166
|
}), null);
|
|
2236
2167
|
});
|
|
2237
|
-
return
|
|
2238
|
-
n.value =
|
|
2168
|
+
return I([() => e.id, () => e.customClass, () => e.editor, () => e.label, () => e.modelValue, () => e.readonly, () => e.required, () => e.showLabel, () => e.visible], ([S, $, B, x, F, E, N, O, G]) => {
|
|
2169
|
+
n.value = S, r.value = $, o.value = B, s.value = x, i.value = F, u.value = E, p.value = N, a.value = O, d.value = G;
|
|
2239
2170
|
}), t.expose({
|
|
2240
2171
|
editorRef: c
|
|
2241
|
-
}), () =>
|
|
2172
|
+
}), () => d.value && A("div", {
|
|
2242
2173
|
id: `${n.value}-input-group`,
|
|
2243
2174
|
class: r.value
|
|
2244
2175
|
}, [A("div", {
|
|
2245
2176
|
class: "farris-group-wrap"
|
|
2246
2177
|
}, [A("div", {
|
|
2247
2178
|
class: g.value
|
|
2248
|
-
}, [a.value && A(
|
|
2179
|
+
}, [a.value && A(we, {
|
|
2249
2180
|
id: `${n.value}-lable`,
|
|
2250
|
-
required:
|
|
2251
|
-
text:
|
|
2252
|
-
title:
|
|
2181
|
+
required: p.value,
|
|
2182
|
+
text: s.value,
|
|
2183
|
+
title: s.value
|
|
2253
2184
|
}, null), A("div", {
|
|
2254
2185
|
class: "farris-input-wrap"
|
|
2255
|
-
}, [
|
|
2186
|
+
}, [M.value()])])])]);
|
|
2256
2187
|
}
|
|
2257
|
-
}),
|
|
2258
|
-
function
|
|
2188
|
+
}), so = {}, lo = {};
|
|
2189
|
+
function co(e, t) {
|
|
2259
2190
|
e.schema;
|
|
2260
|
-
const n =
|
|
2191
|
+
const n = m(!0), r = m(!0);
|
|
2261
2192
|
function o(c) {
|
|
2262
2193
|
return !1;
|
|
2263
2194
|
}
|
|
2264
|
-
function
|
|
2195
|
+
function s() {
|
|
2265
2196
|
return !1;
|
|
2266
2197
|
}
|
|
2267
|
-
function
|
|
2198
|
+
function i() {
|
|
2268
2199
|
return !1;
|
|
2269
2200
|
}
|
|
2270
|
-
function
|
|
2201
|
+
function u() {
|
|
2271
2202
|
return !0;
|
|
2272
2203
|
}
|
|
2273
|
-
function
|
|
2204
|
+
function p(c) {
|
|
2274
2205
|
}
|
|
2275
2206
|
function a() {
|
|
2276
2207
|
}
|
|
2277
|
-
function
|
|
2208
|
+
function d(c) {
|
|
2278
2209
|
return null;
|
|
2279
2210
|
}
|
|
2280
2211
|
return {
|
|
2281
2212
|
canAccepts: o,
|
|
2282
|
-
checkCanDeleteComponent:
|
|
2283
|
-
checkCanMoveComponent:
|
|
2284
|
-
hideNestedPaddingInDesginerView:
|
|
2285
|
-
onAcceptMovedChildElement:
|
|
2213
|
+
checkCanDeleteComponent: s,
|
|
2214
|
+
checkCanMoveComponent: i,
|
|
2215
|
+
hideNestedPaddingInDesginerView: u,
|
|
2216
|
+
onAcceptMovedChildElement: p,
|
|
2286
2217
|
resolveComponentContext: a,
|
|
2287
2218
|
triggerBelongedComponentToMoveWhenMoved: n,
|
|
2288
2219
|
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
2289
|
-
getPropsConfig:
|
|
2220
|
+
getPropsConfig: d
|
|
2290
2221
|
};
|
|
2291
2222
|
}
|
|
2292
|
-
class
|
|
2223
|
+
class uo {
|
|
2224
|
+
constructor(t, n) {
|
|
2225
|
+
L(this, "componentId");
|
|
2226
|
+
L(this, "viewModelId");
|
|
2227
|
+
L(this, "eventsEditorUtils");
|
|
2228
|
+
L(this, "formSchemaUtils");
|
|
2229
|
+
L(this, "formMetadataConverter");
|
|
2230
|
+
L(this, "designViewModelUtils");
|
|
2231
|
+
L(this, "designViewModelField");
|
|
2232
|
+
L(this, "controlCreatorUtils");
|
|
2233
|
+
L(this, "designerHostService");
|
|
2234
|
+
L(this, "schemaService", null);
|
|
2235
|
+
L(this, "metadataService", null);
|
|
2236
|
+
L(this, "propertyConfig", {
|
|
2237
|
+
type: "object",
|
|
2238
|
+
categories: {}
|
|
2239
|
+
});
|
|
2240
|
+
var r;
|
|
2241
|
+
this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((r = this.formSchemaUtils) == null ? void 0 : r.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
|
|
2242
|
+
}
|
|
2243
|
+
getTableInfo() {
|
|
2244
|
+
var t;
|
|
2245
|
+
return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
|
|
2246
|
+
}
|
|
2247
|
+
setDesignViewModelField(t) {
|
|
2248
|
+
const n = t.binding && t.binding.type === "Form" && t.binding.field;
|
|
2249
|
+
if (n) {
|
|
2250
|
+
if (!this.designViewModelField) {
|
|
2251
|
+
const r = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
2252
|
+
this.designViewModelField = r.fields.find((o) => o.id === n);
|
|
2253
|
+
}
|
|
2254
|
+
t.updateOn = this.designViewModelField.updateOn;
|
|
2255
|
+
}
|
|
2256
|
+
}
|
|
2257
|
+
changeFieldEditorType(t, n) {
|
|
2258
|
+
}
|
|
2259
|
+
getBasicPropConfig(t) {
|
|
2260
|
+
return {
|
|
2261
|
+
description: "Basic Information",
|
|
2262
|
+
title: "基本信息",
|
|
2263
|
+
properties: {
|
|
2264
|
+
id: {
|
|
2265
|
+
description: "组件标识",
|
|
2266
|
+
title: "标识",
|
|
2267
|
+
type: "string",
|
|
2268
|
+
readonly: !0
|
|
2269
|
+
},
|
|
2270
|
+
type: {
|
|
2271
|
+
description: "组件类型",
|
|
2272
|
+
title: "控件类型",
|
|
2273
|
+
type: "select",
|
|
2274
|
+
editor: {
|
|
2275
|
+
type: "combo-list",
|
|
2276
|
+
textField: "name",
|
|
2277
|
+
valueField: "value",
|
|
2278
|
+
data: [{ value: t.type, name: j[t.type].name }]
|
|
2279
|
+
}
|
|
2280
|
+
}
|
|
2281
|
+
}
|
|
2282
|
+
};
|
|
2283
|
+
}
|
|
2284
|
+
getAppearanceConfig(t = null) {
|
|
2285
|
+
return {
|
|
2286
|
+
title: "样式",
|
|
2287
|
+
description: "Appearance",
|
|
2288
|
+
properties: {
|
|
2289
|
+
class: {
|
|
2290
|
+
title: "class样式",
|
|
2291
|
+
type: "string",
|
|
2292
|
+
description: "组件的CSS样式",
|
|
2293
|
+
$converter: "/converter/appearance.converter"
|
|
2294
|
+
},
|
|
2295
|
+
style: {
|
|
2296
|
+
title: "style样式",
|
|
2297
|
+
type: "string",
|
|
2298
|
+
description: "组件的样式",
|
|
2299
|
+
$converter: "/converter/appearance.converter"
|
|
2300
|
+
}
|
|
2301
|
+
}
|
|
2302
|
+
};
|
|
2303
|
+
}
|
|
2304
|
+
}
|
|
2305
|
+
const H = class H {
|
|
2306
|
+
/**
|
|
2307
|
+
* 根据绑定字段类型获取可用的输入类控件
|
|
2308
|
+
*/
|
|
2293
2309
|
static getEditorTypesByMDataType(t) {
|
|
2294
|
-
const n =
|
|
2310
|
+
const n = H.fieldControlTypeMapping[t];
|
|
2295
2311
|
return n || [{ key: "", value: "" }];
|
|
2296
2312
|
}
|
|
2297
|
-
|
|
2313
|
+
/**
|
|
2314
|
+
* 获取所有输入类控件
|
|
2315
|
+
*/
|
|
2316
|
+
static getAllInputTypes() {
|
|
2317
|
+
const t = [];
|
|
2318
|
+
for (let n in H.fieldControlTypeMapping)
|
|
2319
|
+
H.fieldControlTypeMapping[n].forEach((r) => {
|
|
2320
|
+
t.find((o) => o.key === r.key && o.value === r.value) || t.push({ key: r.key, value: r.value });
|
|
2321
|
+
});
|
|
2322
|
+
return t;
|
|
2323
|
+
}
|
|
2324
|
+
};
|
|
2298
2325
|
/**
|
|
2299
2326
|
* <字段类型,可配置的控件类型列表>的映射
|
|
2300
2327
|
*/
|
|
2301
|
-
|
|
2328
|
+
L(H, "fieldControlTypeMapping", {
|
|
2302
2329
|
String: [
|
|
2303
|
-
{ key:
|
|
2304
|
-
{ key:
|
|
2305
|
-
{ key:
|
|
2306
|
-
{ key:
|
|
2307
|
-
{ key:
|
|
2308
|
-
{ key:
|
|
2309
|
-
{ key:
|
|
2310
|
-
{ key: T.textarea.type, value: T.textarea.name }
|
|
2311
|
-
// { key: DgControl.Tags.type, value: DgControl.Tags.name },
|
|
2330
|
+
{ key: j["input-group"].type, value: j["input-group"].name },
|
|
2331
|
+
{ key: j.lookup.type, value: j.lookup.name },
|
|
2332
|
+
{ key: j["date-picker"].type, value: j["date-picker"].name },
|
|
2333
|
+
{ key: j["check-box"].type, value: j["check-box"].name },
|
|
2334
|
+
{ key: j["radio-group"].type, value: j["radio-group"].name },
|
|
2335
|
+
{ key: j["combo-list"].type, value: j["combo-list"].name },
|
|
2336
|
+
{ key: j.textarea.type, value: j.textarea.name }
|
|
2312
2337
|
],
|
|
2313
2338
|
Text: [
|
|
2314
|
-
{ key:
|
|
2315
|
-
{ key:
|
|
2316
|
-
{ key: T.lookup.type, value: T.lookup.name }
|
|
2339
|
+
{ key: j.textarea.type, value: j.textarea.name },
|
|
2340
|
+
{ key: j.lookup.type, value: j.lookup.name }
|
|
2317
2341
|
],
|
|
2318
2342
|
Decimal: [
|
|
2319
|
-
{ key:
|
|
2343
|
+
{ key: j["number-spinner"].type, value: j["number-spinner"].name }
|
|
2320
2344
|
],
|
|
2321
2345
|
Integer: [
|
|
2322
|
-
{ key:
|
|
2346
|
+
{ key: j["number-spinner"].type, value: j["number-spinner"].name }
|
|
2323
2347
|
],
|
|
2324
2348
|
Number: [
|
|
2325
|
-
{ key:
|
|
2349
|
+
{ key: j["number-spinner"].type, value: j["number-spinner"].name }
|
|
2326
2350
|
],
|
|
2327
2351
|
BigNumber: [
|
|
2328
|
-
{ key:
|
|
2352
|
+
{ key: j["number-spinner"].type, value: j["number-spinner"].name }
|
|
2329
2353
|
],
|
|
2330
2354
|
Date: [
|
|
2331
|
-
{ key:
|
|
2355
|
+
{ key: j["date-picker"].type, value: j["date-picker"].name }
|
|
2332
2356
|
],
|
|
2333
2357
|
DateTime: [
|
|
2334
|
-
{ key:
|
|
2358
|
+
{ key: j["date-picker"].type, value: j["date-picker"].name }
|
|
2335
2359
|
],
|
|
2336
2360
|
Boolean: [
|
|
2337
|
-
{ key:
|
|
2338
|
-
{ key:
|
|
2361
|
+
{ key: j.switch.type, value: j.switch.name },
|
|
2362
|
+
{ key: j["check-box"].type, value: j["check-box"].name }
|
|
2339
2363
|
],
|
|
2340
2364
|
Enum: [
|
|
2341
|
-
{ key:
|
|
2342
|
-
{ key:
|
|
2365
|
+
{ key: j["combo-list"].type, value: j["combo-list"].name },
|
|
2366
|
+
{ key: j["radio-group"].type, value: j["radio-group"].name }
|
|
2343
2367
|
],
|
|
2344
2368
|
Object: [
|
|
2345
|
-
{ key:
|
|
2346
|
-
{ key:
|
|
2347
|
-
{ key:
|
|
2348
|
-
],
|
|
2349
|
-
EmployeeSelector: [
|
|
2350
|
-
{ key: T.EmployeeSelector.type, value: T.EmployeeSelector.name }
|
|
2351
|
-
],
|
|
2352
|
-
AdminOrganizationSelector: [
|
|
2353
|
-
{ key: T.AdminOrganizationSelector.type, value: T.AdminOrganizationSelector.name }
|
|
2369
|
+
{ key: j.lookup.type, value: j.lookup.name },
|
|
2370
|
+
{ key: j["combo-list"].type, value: j["combo-list"].name },
|
|
2371
|
+
{ key: j["radio-group"].type, value: j["radio-group"].name }
|
|
2354
2372
|
]
|
|
2355
2373
|
});
|
|
2356
|
-
|
|
2374
|
+
let Q = H;
|
|
2375
|
+
const po = m(0);
|
|
2376
|
+
class fo extends uo {
|
|
2357
2377
|
constructor(t, n) {
|
|
2358
|
-
|
|
2359
|
-
I(this, "viewModelId");
|
|
2360
|
-
I(this, "eventsEditorUtils");
|
|
2361
|
-
I(this, "formSchemaUtils");
|
|
2362
|
-
I(this, "formMetadataConverter");
|
|
2363
|
-
I(this, "designViewModelUtils");
|
|
2364
|
-
I(this, "designViewModelField");
|
|
2365
|
-
I(this, "controlCreatorUtils");
|
|
2366
|
-
I(this, "designerHostService");
|
|
2367
|
-
I(this, "schemaService", null);
|
|
2368
|
-
I(this, "metadataService", null);
|
|
2369
|
-
I(this, "propertyConfig", {
|
|
2370
|
-
type: "object",
|
|
2371
|
-
categories: {}
|
|
2372
|
-
});
|
|
2373
|
-
var r;
|
|
2374
|
-
this.componentId = t, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((r = this.formSchemaUtils) == null ? void 0 : r.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
|
|
2375
|
-
}
|
|
2376
|
-
getTableInfo() {
|
|
2377
|
-
var t;
|
|
2378
|
-
return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
|
|
2379
|
-
}
|
|
2380
|
-
setDesignViewModelField(t) {
|
|
2381
|
-
const n = t.binding && t.binding.type === "Form" && t.binding.field;
|
|
2382
|
-
if (n) {
|
|
2383
|
-
if (!this.designViewModelField) {
|
|
2384
|
-
const r = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
2385
|
-
this.designViewModelField = r.fields.find((o) => o.id === n);
|
|
2386
|
-
}
|
|
2387
|
-
t.updateOn = this.designViewModelField.updateOn;
|
|
2388
|
-
}
|
|
2378
|
+
super(t, n);
|
|
2389
2379
|
}
|
|
2390
|
-
|
|
2380
|
+
getPropertyConfig(t, n) {
|
|
2381
|
+
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;
|
|
2391
2382
|
}
|
|
2392
|
-
|
|
2393
|
-
var
|
|
2394
|
-
var
|
|
2395
|
-
|
|
2383
|
+
getBasicProperties(t, n) {
|
|
2384
|
+
var i;
|
|
2385
|
+
var r = this;
|
|
2386
|
+
this.setDesignViewModelField(t);
|
|
2387
|
+
const o = this.formSchemaUtils.getFormMetadataBasicInfo(), s = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
2388
|
+
return {
|
|
2396
2389
|
description: "Basic Information",
|
|
2397
2390
|
title: "基本信息",
|
|
2398
2391
|
properties: {
|
|
@@ -2412,63 +2405,48 @@ class lo {
|
|
|
2412
2405
|
type: "combo-list",
|
|
2413
2406
|
textField: "value",
|
|
2414
2407
|
valueField: "key",
|
|
2415
|
-
|
|
2416
|
-
|
|
2408
|
+
editable: !1,
|
|
2409
|
+
data: r.designViewModelField ? Q.getEditorTypesByMDataType((i = r.designViewModelField.type) == null ? void 0 : i.name) : Q.getAllInputTypes()
|
|
2417
2410
|
}
|
|
2418
2411
|
},
|
|
2419
2412
|
label: {
|
|
2420
2413
|
title: "标签",
|
|
2421
2414
|
type: "string",
|
|
2422
2415
|
$converter: "/converter/form-group-label.converter"
|
|
2416
|
+
},
|
|
2417
|
+
binding: {
|
|
2418
|
+
description: "绑定的表单字段",
|
|
2419
|
+
title: "绑定",
|
|
2420
|
+
$converter: "/converter/field-selector.converter",
|
|
2421
|
+
editor: {
|
|
2422
|
+
type: "field-selector",
|
|
2423
|
+
bindingType: { enable: !1 },
|
|
2424
|
+
editorParams: {
|
|
2425
|
+
propertyData: t,
|
|
2426
|
+
formBasicInfo: o
|
|
2427
|
+
},
|
|
2428
|
+
columns: [
|
|
2429
|
+
{ field: "name", title: "字段名称" },
|
|
2430
|
+
{ field: "bindingField", title: "绑定字段" },
|
|
2431
|
+
{ field: "fieldType", title: "字段类型" }
|
|
2432
|
+
],
|
|
2433
|
+
textField: "bindingField",
|
|
2434
|
+
data: s
|
|
2435
|
+
}
|
|
2423
2436
|
}
|
|
2424
2437
|
},
|
|
2425
|
-
setPropertyRelates(
|
|
2426
|
-
if (
|
|
2427
|
-
switch (
|
|
2438
|
+
setPropertyRelates(u, p) {
|
|
2439
|
+
if (u)
|
|
2440
|
+
switch (u && u.propertyID) {
|
|
2428
2441
|
case "type": {
|
|
2429
|
-
|
|
2442
|
+
r.changeControlType(t, u, n);
|
|
2430
2443
|
break;
|
|
2431
2444
|
}
|
|
2432
2445
|
}
|
|
2433
2446
|
}
|
|
2434
2447
|
};
|
|
2435
2448
|
}
|
|
2436
|
-
|
|
2437
|
-
* 卡片控件:切换控件类型后事件
|
|
2438
|
-
* @param propertyData 控件DOM属性
|
|
2439
|
-
* @param newControlType 新控件类型
|
|
2440
|
-
*/
|
|
2441
|
-
changeControlType(t, n) {
|
|
2442
|
-
var a, u, c, y, F;
|
|
2443
|
-
const r = n.propertyValue, o = this.formSchemaUtils.getComponentById(this.componentId);
|
|
2444
|
-
let i = this.getControlParentContainer(t.id, o);
|
|
2445
|
-
if (!i)
|
|
2446
|
-
return;
|
|
2447
|
-
const l = i.contents.findIndex((s) => s.id === t.id), d = i.contents[l];
|
|
2448
|
-
let m;
|
|
2449
|
-
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
2450
|
-
editor: {
|
|
2451
|
-
$type: r
|
|
2452
|
-
},
|
|
2453
|
-
name: this.designViewModelField.name,
|
|
2454
|
-
require: this.designViewModelField.require,
|
|
2455
|
-
readonly: this.designViewModelField.readonly
|
|
2456
|
-
}, !1), m = this.controlCreatorUtils.setFormFieldProperty("Form", this.designViewModelField, null, r)), Object.assign(m, {
|
|
2457
|
-
id: d.id,
|
|
2458
|
-
appearance: d.appearance,
|
|
2459
|
-
size: d.size,
|
|
2460
|
-
label: d.label
|
|
2461
|
-
}), Object.assign(m.editor, {
|
|
2462
|
-
isTextArea: m.isTextArea && d.isTextArea,
|
|
2463
|
-
type: r || "",
|
|
2464
|
-
placeHolder: (a = d.editor) == null ? void 0 : a.placeHolder,
|
|
2465
|
-
holdPlace: (u = d.editor) == null ? void 0 : u.holdPlace,
|
|
2466
|
-
readonly: (c = d.editor) == null ? void 0 : c.readonly,
|
|
2467
|
-
require: (y = d.editor) == null ? void 0 : y.require,
|
|
2468
|
-
visible: (F = d.editor) == null ? void 0 : F.visible
|
|
2469
|
-
}), i.contents.splice(l, 1, m);
|
|
2470
|
-
}
|
|
2471
|
-
getAppearanceConfig(t = null) {
|
|
2449
|
+
getAppearanceProperties(t) {
|
|
2472
2450
|
return {
|
|
2473
2451
|
title: "样式",
|
|
2474
2452
|
description: "Appearance",
|
|
@@ -2498,65 +2476,44 @@ class lo {
|
|
|
2498
2476
|
}
|
|
2499
2477
|
};
|
|
2500
2478
|
}
|
|
2501
|
-
/**
|
|
2502
|
-
* 获取控件:以contents为节点进行定位
|
|
2503
|
-
* @param controlId 控件ID
|
|
2504
|
-
* @param domJson 容器
|
|
2505
|
-
*/
|
|
2506
|
-
getControlParentContainer(t, n) {
|
|
2507
|
-
let r;
|
|
2508
|
-
if (!n || !n.contents || n.contents.length === 0)
|
|
2509
|
-
return null;
|
|
2510
|
-
for (const o of n.contents) {
|
|
2511
|
-
if (o.id === t)
|
|
2512
|
-
return r = n, n;
|
|
2513
|
-
if (r = this.getControlParentContainer(t, o), r)
|
|
2514
|
-
return r;
|
|
2515
|
-
}
|
|
2516
|
-
}
|
|
2517
|
-
}
|
|
2518
|
-
class co extends lo {
|
|
2519
|
-
constructor(t, n) {
|
|
2520
|
-
super(t, n);
|
|
2521
|
-
}
|
|
2522
|
-
getBasicProperties(t) {
|
|
2523
|
-
let n = this.getBasicPropConfig(t);
|
|
2524
|
-
return n.properties.binding = this.getFieldSelectorOptions(t), n;
|
|
2525
|
-
}
|
|
2526
|
-
getAppearanceProperties(t) {
|
|
2527
|
-
return this.getAppearanceConfig(t);
|
|
2528
|
-
}
|
|
2529
2479
|
getEditorProperties(t) {
|
|
2530
2480
|
return this.getComponentConfig(t);
|
|
2531
2481
|
}
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2482
|
+
/**
|
|
2483
|
+
* 卡片控件:切换控件类型后事件
|
|
2484
|
+
* @param propertyData 控件DOM属性
|
|
2485
|
+
* @param newControlType 新控件类型
|
|
2486
|
+
*/
|
|
2487
|
+
changeControlType(t, n, r) {
|
|
2488
|
+
var a, d, c, y;
|
|
2489
|
+
const o = n.propertyValue, s = r && r.parent && r.parent.schema;
|
|
2490
|
+
if (!s)
|
|
2491
|
+
return;
|
|
2492
|
+
const i = s.contents.findIndex((w) => w.id === t.id), u = s.contents[i];
|
|
2493
|
+
let p;
|
|
2494
|
+
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
2541
2495
|
editor: {
|
|
2542
|
-
type:
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2496
|
+
$type: o
|
|
2497
|
+
},
|
|
2498
|
+
name: this.designViewModelField.name,
|
|
2499
|
+
require: this.designViewModelField.require,
|
|
2500
|
+
readonly: this.designViewModelField.readonly
|
|
2501
|
+
}, !1), p = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, o)), p || (p = pe("form-group") || {}, p.editor = pe(o) || {}, delete p.editor.id, delete p.editor.binding, delete p.editor.appearance), Object.assign(p, {
|
|
2502
|
+
id: u.id,
|
|
2503
|
+
appearance: u.appearance,
|
|
2504
|
+
size: u.size,
|
|
2505
|
+
label: u.label,
|
|
2506
|
+
binding: u.binding,
|
|
2507
|
+
visible: u.visible
|
|
2508
|
+
}), Object.assign(p.editor, {
|
|
2509
|
+
isTextArea: p.isTextArea && u.isTextArea,
|
|
2510
|
+
placeholder: (a = u.editor) == null ? void 0 : a.placeholder,
|
|
2511
|
+
holdPlace: (d = u.editor) == null ? void 0 : d.holdPlace,
|
|
2512
|
+
readonly: (c = u.editor) == null ? void 0 : c.readonly,
|
|
2513
|
+
require: (y = u.editor) == null ? void 0 : y.require
|
|
2514
|
+
}), s.contents.splice(i, 1), s.contents.splice(i, 0, p), r.schema = Object.assign(u, p), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
2515
|
+
(w) => w.classList.remove("dgComponentSelected")
|
|
2516
|
+
), po.value++;
|
|
2560
2517
|
}
|
|
2561
2518
|
getComponentConfig(t, n = {}, r = {}) {
|
|
2562
2519
|
const o = Object.assign({
|
|
@@ -2564,7 +2521,7 @@ class co extends lo {
|
|
|
2564
2521
|
title: "组件信息",
|
|
2565
2522
|
type: "input-group",
|
|
2566
2523
|
$converter: "/converter/property-editor.converter"
|
|
2567
|
-
}, n),
|
|
2524
|
+
}, n), s = Object.assign({
|
|
2568
2525
|
readonly: {
|
|
2569
2526
|
description: "",
|
|
2570
2527
|
title: "只读",
|
|
@@ -2586,113 +2543,113 @@ class co extends lo {
|
|
|
2586
2543
|
type: "string"
|
|
2587
2544
|
}
|
|
2588
2545
|
}, r);
|
|
2589
|
-
return { ...o, properties: { ...
|
|
2546
|
+
return { ...o, properties: { ...s } };
|
|
2590
2547
|
}
|
|
2591
2548
|
}
|
|
2592
|
-
class
|
|
2549
|
+
class mo extends fo {
|
|
2593
2550
|
constructor(t, n) {
|
|
2594
2551
|
super(t, n);
|
|
2595
2552
|
}
|
|
2596
2553
|
}
|
|
2597
|
-
function
|
|
2554
|
+
function yo(e, t) {
|
|
2598
2555
|
const {
|
|
2599
2556
|
canAccepts: n,
|
|
2600
2557
|
checkCanDeleteComponent: r,
|
|
2601
2558
|
checkCanMoveComponent: o,
|
|
2602
|
-
hideNestedPaddingInDesginerView:
|
|
2603
|
-
onAcceptMovedChildElement:
|
|
2604
|
-
resolveComponentContext:
|
|
2605
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
2559
|
+
hideNestedPaddingInDesginerView: s,
|
|
2560
|
+
onAcceptMovedChildElement: i,
|
|
2561
|
+
resolveComponentContext: u,
|
|
2562
|
+
triggerBelongedComponentToMoveWhenMoved: p,
|
|
2606
2563
|
triggerBelongedComponentToDeleteWhenDeleted: a
|
|
2607
|
-
} =
|
|
2608
|
-
function c(y) {
|
|
2609
|
-
return new
|
|
2564
|
+
} = co(e), d = e.schema;
|
|
2565
|
+
function c(y, w) {
|
|
2566
|
+
return new mo(y, t).getPropertyConfig(d, w);
|
|
2610
2567
|
}
|
|
2611
2568
|
return {
|
|
2612
2569
|
canAccepts: n,
|
|
2613
2570
|
checkCanDeleteComponent: r,
|
|
2614
2571
|
checkCanMoveComponent: o,
|
|
2615
|
-
hideNestedPaddingInDesginerView:
|
|
2616
|
-
onAcceptMovedChildElement:
|
|
2617
|
-
resolveComponentContext:
|
|
2618
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
2572
|
+
hideNestedPaddingInDesginerView: s,
|
|
2573
|
+
onAcceptMovedChildElement: i,
|
|
2574
|
+
resolveComponentContext: u,
|
|
2575
|
+
triggerBelongedComponentToMoveWhenMoved: p,
|
|
2619
2576
|
triggerBelongedComponentToDeleteWhenDeleted: a,
|
|
2620
2577
|
getPropsConfig: c
|
|
2621
2578
|
};
|
|
2622
2579
|
}
|
|
2623
|
-
const
|
|
2580
|
+
const go = /* @__PURE__ */ q({
|
|
2624
2581
|
name: "FInputGroupDesign",
|
|
2625
|
-
props:
|
|
2582
|
+
props: se,
|
|
2626
2583
|
emits: ["updateExtendInfo", "clear", "valueChange", "clickHandle", "blurHandle", "focusHandle", "enterHandle", "iconMouseEnter", "iconMouseLeave", "keyupHandle", "keydownHandle", "inputClick"],
|
|
2627
2584
|
setup(e, t) {
|
|
2628
|
-
const n =
|
|
2629
|
-
inputGroupClass:
|
|
2630
|
-
inputType:
|
|
2631
|
-
inputGroupStyle:
|
|
2632
|
-
} = o,
|
|
2585
|
+
const n = m(e.modelValue), r = m(e.modelValue), o = Zn(e, t, n, r), {
|
|
2586
|
+
inputGroupClass: s,
|
|
2587
|
+
inputType: i,
|
|
2588
|
+
inputGroupStyle: u
|
|
2589
|
+
} = o, p = Fe(e), {
|
|
2633
2590
|
shouldShowAppendedButton: a
|
|
2634
|
-
} =
|
|
2591
|
+
} = p, d = Te(e, t, o), {
|
|
2635
2592
|
onMouseEnter: c,
|
|
2636
2593
|
onMouseLeave: y
|
|
2637
|
-
} =
|
|
2594
|
+
} = d, w = Be(e, t, i, p), l = m(), f = z("designer-host-service"), g = z("design-item-context"), T = yo(g, f), D = ie(l, g, T);
|
|
2638
2595
|
U(() => {
|
|
2639
|
-
|
|
2596
|
+
l.value.componentInstance = D;
|
|
2640
2597
|
}), t.expose(D.value);
|
|
2641
|
-
const
|
|
2598
|
+
const M = ke(e, t, p, d, w), S = m();
|
|
2642
2599
|
return () => A("div", {
|
|
2643
2600
|
id: "inputGroup",
|
|
2644
|
-
ref:
|
|
2645
|
-
class:
|
|
2646
|
-
style:
|
|
2601
|
+
ref: l,
|
|
2602
|
+
class: s.value,
|
|
2603
|
+
style: u.value,
|
|
2647
2604
|
onMouseenter: c,
|
|
2648
2605
|
onMouseleave: y
|
|
2649
2606
|
}, [A("input", {
|
|
2650
|
-
ref:
|
|
2607
|
+
ref: S,
|
|
2651
2608
|
class: "form-control",
|
|
2652
2609
|
readonly: !0,
|
|
2653
2610
|
placeholder: e.placeholder
|
|
2654
|
-
}, null), a.value &&
|
|
2611
|
+
}, null), a.value && M()]);
|
|
2655
2612
|
}
|
|
2656
2613
|
});
|
|
2657
|
-
function
|
|
2614
|
+
function bo() {
|
|
2658
2615
|
function e(n, r) {
|
|
2659
|
-
const o =
|
|
2616
|
+
const o = lo[n];
|
|
2660
2617
|
return o ? o(r) : {};
|
|
2661
2618
|
}
|
|
2662
2619
|
function t(n) {
|
|
2663
|
-
return
|
|
2620
|
+
return so[n] || go;
|
|
2664
2621
|
}
|
|
2665
2622
|
return { resolveEditorProps: e, resolveEditorType: t };
|
|
2666
2623
|
}
|
|
2667
|
-
const
|
|
2624
|
+
const ho = /* @__PURE__ */ q({
|
|
2668
2625
|
name: "FDynamicFormGroupDesign",
|
|
2669
|
-
props:
|
|
2626
|
+
props: J,
|
|
2670
2627
|
emits: ["change", "update:modelValue"],
|
|
2671
2628
|
setup(e, t) {
|
|
2672
|
-
const n =
|
|
2673
|
-
|
|
2674
|
-
const
|
|
2629
|
+
const n = m(e.id), r = m(e.customClass), o = m(e.editor), s = m(e.label), i = m(e.modelValue), u = m(!0), p = m(e.required), a = m(e.showLabel);
|
|
2630
|
+
m(e.type);
|
|
2631
|
+
const d = m(), {
|
|
2675
2632
|
resolveEditorProps: c,
|
|
2676
2633
|
resolveEditorType: y
|
|
2677
|
-
} =
|
|
2634
|
+
} = bo(), w = k(() => ({
|
|
2678
2635
|
"form-group": !0,
|
|
2679
2636
|
"farris-form-group": !0,
|
|
2680
2637
|
"common-group": !0,
|
|
2681
|
-
"q-state-readonly":
|
|
2638
|
+
"q-state-readonly": u.value,
|
|
2682
2639
|
"form-group-in-canvas": !0
|
|
2683
|
-
})),
|
|
2684
|
-
const
|
|
2685
|
-
return () => A(g,
|
|
2686
|
-
ref:
|
|
2687
|
-
},
|
|
2688
|
-
modelValue:
|
|
2689
|
-
"onUpdate:modelValue": (D) =>
|
|
2640
|
+
})), l = k(() => {
|
|
2641
|
+
const f = o.value.type || "input-group", g = y(f), T = c(f, o.value);
|
|
2642
|
+
return () => A(g, Z({
|
|
2643
|
+
ref: d
|
|
2644
|
+
}, T, {
|
|
2645
|
+
modelValue: i.value,
|
|
2646
|
+
"onUpdate:modelValue": (D) => i.value = D
|
|
2690
2647
|
}), null);
|
|
2691
2648
|
});
|
|
2692
|
-
return
|
|
2693
|
-
n.value =
|
|
2649
|
+
return I([() => e.id, () => e.customClass, () => e.editor, () => e.label, () => e.modelValue, () => e.readonly, () => e.required, () => e.showLabel], ([f, g, T, D, M, S, $, B]) => {
|
|
2650
|
+
n.value = f, r.value = g, o.value = T, s.value = D, i.value = M, u.value = S, p.value = $, a.value = B;
|
|
2694
2651
|
}), t.expose({
|
|
2695
|
-
editorRef:
|
|
2652
|
+
editorRef: d
|
|
2696
2653
|
}), () => A("div", {
|
|
2697
2654
|
id: `${n.value}-input-group`,
|
|
2698
2655
|
class: r.value,
|
|
@@ -2700,33 +2657,33 @@ const yo = /* @__PURE__ */ G({
|
|
|
2700
2657
|
}, [A("div", {
|
|
2701
2658
|
class: "farris-group-wrap"
|
|
2702
2659
|
}, [A("div", {
|
|
2703
|
-
class:
|
|
2704
|
-
}, [a.value && A(
|
|
2660
|
+
class: w.value
|
|
2661
|
+
}, [a.value && A(we, {
|
|
2705
2662
|
id: `${n.value}-lable`,
|
|
2706
|
-
required:
|
|
2707
|
-
text:
|
|
2708
|
-
title:
|
|
2663
|
+
required: p.value,
|
|
2664
|
+
text: s.value,
|
|
2665
|
+
title: s.value
|
|
2709
2666
|
}, null), A("div", {
|
|
2710
2667
|
class: "farris-input-wrap"
|
|
2711
|
-
}, [
|
|
2668
|
+
}, [l.value()])])])]);
|
|
2712
2669
|
}
|
|
2713
|
-
}),
|
|
2670
|
+
}), vo = /* @__PURE__ */ q({
|
|
2714
2671
|
name: "FFormGroupDesign",
|
|
2715
|
-
props:
|
|
2672
|
+
props: J,
|
|
2716
2673
|
emits: [],
|
|
2717
2674
|
setup(e, t) {
|
|
2718
|
-
const n =
|
|
2675
|
+
const n = m(), r = z("design-item-context"), o = ie(n, r);
|
|
2719
2676
|
return o.value.canNested = !1, o.value.canMove = !0, o.value.canDelete = !0, U(() => {
|
|
2720
|
-
n.value.componentInstance = o, o.value.getPropConfig = (...
|
|
2721
|
-
var
|
|
2722
|
-
let
|
|
2723
|
-
return
|
|
2677
|
+
n.value.componentInstance = o, o.value.getPropConfig = (...s) => {
|
|
2678
|
+
var u, p, a;
|
|
2679
|
+
let i = be[e.editor.type];
|
|
2680
|
+
return i && Object.keys(i).length === 0 && ((u = n.value) != null && u.editorRef) && ((a = (p = n.value) == null ? void 0 : p.editorRef) != null && a.getPropConfig) && (i = n.value.editorRef.getPropConfig(...s, o.value)), i;
|
|
2724
2681
|
};
|
|
2725
|
-
}), t.expose(o.value), () => A(
|
|
2682
|
+
}), t.expose(o.value), () => A(ho, Z(e, {
|
|
2726
2683
|
ref: n
|
|
2727
2684
|
}), null);
|
|
2728
2685
|
}
|
|
2729
|
-
}),
|
|
2686
|
+
}), Pe = {
|
|
2730
2687
|
id: { type: String, default: "" },
|
|
2731
2688
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
2732
2689
|
editor: { type: Object, default: {} },
|
|
@@ -2740,55 +2697,56 @@ const yo = /* @__PURE__ */ G({
|
|
|
2740
2697
|
* 作为内嵌编辑器被创建后默认选中文本
|
|
2741
2698
|
*/
|
|
2742
2699
|
selectOnCreated: { type: Boolean, default: !1 }
|
|
2743
|
-
},
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2700
|
+
}, Co = X(
|
|
2701
|
+
Pe,
|
|
2702
|
+
Ce,
|
|
2703
|
+
ae,
|
|
2747
2704
|
void 0
|
|
2748
|
-
),
|
|
2705
|
+
), wo = /* @__PURE__ */ q({
|
|
2749
2706
|
name: "FDynamicFormInput",
|
|
2750
|
-
props:
|
|
2707
|
+
props: Pe,
|
|
2751
2708
|
emits: ["change", "update:modelValue"],
|
|
2752
2709
|
setup(e, t) {
|
|
2753
|
-
const n =
|
|
2754
|
-
resolveEditorProps:
|
|
2755
|
-
resolveEditorType:
|
|
2756
|
-
getChangeFunctionName:
|
|
2757
|
-
} =
|
|
2758
|
-
function
|
|
2759
|
-
o.value = c !== void 0 ? c :
|
|
2710
|
+
const n = m(e.id), r = m(e.editor), o = m(e.modelValue), {
|
|
2711
|
+
resolveEditorProps: s,
|
|
2712
|
+
resolveEditorType: i,
|
|
2713
|
+
getChangeFunctionName: u
|
|
2714
|
+
} = je();
|
|
2715
|
+
function p(d, c) {
|
|
2716
|
+
o.value = c !== void 0 ? c : d, t.emit("update:modelValue", o.value), t.emit("change", o.value);
|
|
2760
2717
|
}
|
|
2761
|
-
const a =
|
|
2762
|
-
const
|
|
2718
|
+
const a = k(() => {
|
|
2719
|
+
const d = i(r.value.type), c = s(r.value.type, r.value);
|
|
2763
2720
|
c.focusOnCreated = e.focusOnCreated, c.selectOnCreated = e.selectOnCreated;
|
|
2764
|
-
const y =
|
|
2765
|
-
return c[y] =
|
|
2721
|
+
const y = u(r.value.type);
|
|
2722
|
+
return c[y] = p, () => A(d, Z(c, {
|
|
2766
2723
|
modelValue: o.value,
|
|
2767
|
-
"onUpdate:modelValue": (
|
|
2724
|
+
"onUpdate:modelValue": (w) => o.value = w
|
|
2768
2725
|
}), null);
|
|
2769
2726
|
});
|
|
2770
|
-
return
|
|
2771
|
-
n.value =
|
|
2727
|
+
return I([() => e.id, () => e.editor, () => e.modelValue], ([d, c, y]) => {
|
|
2728
|
+
n.value = d, r.value = c, o.value = y;
|
|
2772
2729
|
}), () => a.value();
|
|
2773
2730
|
}
|
|
2774
|
-
}),
|
|
2731
|
+
}), Er = {
|
|
2775
2732
|
install(e) {
|
|
2776
|
-
e.component(
|
|
2733
|
+
e.component(ee.name, ee).component(ne.name, ne);
|
|
2777
2734
|
},
|
|
2778
2735
|
register(e, t, n, r) {
|
|
2779
|
-
e["form-group"] =
|
|
2736
|
+
e["form-group"] = ne, t["form-group"] = fe, e["response-form"] = ee, t["response-form"] = de, e["form-input"] = wo, t["form-input"] = Co, r["form-group"] = { editorResolver: kn };
|
|
2780
2737
|
},
|
|
2781
2738
|
registerDesigner(e, t, n) {
|
|
2782
|
-
e["form-group"] =
|
|
2739
|
+
e["form-group"] = vo, t["form-group"] = fe, e["response-form"] = Nn, t["response-form"] = de;
|
|
2783
2740
|
}
|
|
2784
2741
|
};
|
|
2785
2742
|
export {
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2743
|
+
ne as FDynamicFormGroup,
|
|
2744
|
+
ee as FResponseForm,
|
|
2745
|
+
Er as default,
|
|
2746
|
+
J as dynamicFormGroupProps,
|
|
2747
|
+
kn as editorResolver,
|
|
2748
|
+
fe as formGroupPropsResolver,
|
|
2749
|
+
de as formPropsResolver,
|
|
2750
|
+
ve as responseFormProps,
|
|
2751
|
+
$n as useDesignerRules
|
|
2794
2752
|
};
|