@farris/ui-vue 1.2.7 → 1.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/accordion/index.esm.js +136 -136
- package/components/accordion/index.umd.cjs +1 -1
- package/components/avatar/index.esm.js +418 -456
- package/components/avatar/index.umd.cjs +1 -1
- package/components/border-editor/index.esm.js +4 -4
- package/components/border-editor/index.umd.cjs +1 -1
- package/components/button/index.esm.js +1 -1
- package/components/button/index.umd.cjs +1 -1
- package/components/button-edit/index.esm.js +363 -436
- package/components/button-edit/index.umd.cjs +1 -1
- package/components/button-group/index.esm.js +5 -5
- package/components/button-group/index.umd.cjs +1 -1
- package/components/calendar/index.esm.js +417 -417
- package/components/calendar/index.umd.cjs +1 -1
- package/components/capsule/index.esm.js +176 -176
- package/components/capsule/index.umd.cjs +1 -1
- package/components/checkbox/index.esm.js +557 -594
- package/components/checkbox/index.umd.cjs +1 -1
- package/components/color-picker/index.esm.js +119 -119
- package/components/color-picker/index.umd.cjs +2 -2
- package/components/combo-list/index.esm.js +502 -535
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/combo-tree/index.esm.js +69 -69
- package/components/combo-tree/index.umd.cjs +1 -1
- package/components/component/index.esm.js +387 -275
- package/components/component/index.umd.cjs +1 -1
- package/components/condition/index.esm.js +1219 -983
- package/components/condition/index.umd.cjs +1 -1
- package/components/content-container/index.esm.js +292 -219
- package/components/content-container/index.umd.cjs +1 -1
- package/components/data-grid/index.css +1 -1
- package/components/data-grid/index.esm.js +5718 -5546
- package/components/data-grid/index.umd.cjs +1 -1
- package/components/data-view/index.esm.js +3291 -2930
- package/components/data-view/index.umd.cjs +1 -1
- package/components/date-picker/index.esm.js +2650 -2682
- package/components/date-picker/index.umd.cjs +1 -1
- 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.css +1 -1
- package/components/designer-canvas/index.esm.js +945 -932
- package/components/designer-canvas/index.umd.cjs +1 -1
- package/components/designer-outline/index.css +1 -1
- package/components/designer-outline/index.esm.js +175 -133
- package/components/designer-outline/index.umd.cjs +1 -1
- package/components/designer-toolbox/index.esm.js +36 -12
- package/components/designer-toolbox/index.umd.cjs +1 -1
- package/components/discussion-editor/index.esm.js +1 -1
- package/components/discussion-editor/index.umd.cjs +1 -1
- package/components/dropdown/index.esm.js +246 -246
- package/components/dropdown/index.umd.cjs +2 -2
- package/components/dynamic-form/index.esm.js +1319 -1172
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +119 -82
- package/components/dynamic-resolver/index.umd.cjs +1 -1
- package/components/dynamic-view/index.esm.js +258 -249
- package/components/dynamic-view/index.umd.cjs +1 -1
- package/components/enum-editor/index.esm.js +3 -3
- package/components/enum-editor/index.umd.cjs +1 -1
- package/components/events-editor/index.esm.js +569 -514
- package/components/events-editor/index.umd.cjs +1 -1
- package/components/expression-editor/index.esm.js +104 -104
- package/components/expression-editor/index.umd.cjs +1 -1
- package/components/external-container/index.css +1 -1
- package/components/external-container/index.esm.js +3122 -2686
- package/components/external-container/index.umd.cjs +1 -1
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +6780 -6608
- package/components/field-selector/index.umd.cjs +1 -1
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1466 -1523
- package/components/filter-bar/index.umd.cjs +1 -1
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +1048 -1035
- package/components/flow-canvas/index.umd.cjs +1 -1
- package/components/image-cropper/index.esm.js +422 -422
- package/components/image-cropper/index.umd.cjs +1 -1
- package/components/input-group/index.esm.js +674 -716
- package/components/input-group/index.umd.cjs +1 -1
- package/components/layout/index.esm.js +291 -291
- package/components/layout/index.umd.cjs +1 -1
- package/components/list-nav/index.esm.js +303 -230
- package/components/list-nav/index.umd.cjs +1 -1
- package/components/list-view/index.css +1 -1
- package/components/list-view/index.esm.js +2486 -2130
- package/components/list-view/index.umd.cjs +1 -1
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +7474 -7272
- package/components/lookup/index.umd.cjs +1 -1
- package/components/mapping-editor/index.css +1 -1
- package/components/mapping-editor/index.esm.js +6139 -5949
- package/components/mapping-editor/index.umd.cjs +1 -1
- package/components/message-box/index.esm.js +1 -1
- package/components/message-box/index.umd.cjs +1 -1
- package/components/modal/index.esm.js +1 -1
- package/components/modal/index.umd.cjs +1 -1
- package/components/nav/index.esm.js +432 -371
- package/components/nav/index.umd.cjs +3 -3
- package/components/number-range/index.esm.js +1124 -0
- package/components/number-range/index.umd.cjs +1 -0
- package/components/number-range/package.json +8 -0
- package/components/number-range/style.js +6 -0
- package/components/number-spinner/index.esm.js +1155 -0
- package/components/number-spinner/index.umd.cjs +1 -0
- package/components/number-spinner/package.json +8 -0
- package/components/number-spinner/style.js +4 -0
- package/components/order/index.css +1 -1
- package/components/order/index.esm.js +1215 -1178
- package/components/order/index.umd.cjs +1 -1
- package/components/page-footer/index.esm.js +147 -147
- package/components/page-footer/index.umd.cjs +1 -1
- package/components/page-header/index.esm.js +1240 -1346
- package/components/page-header/index.umd.cjs +1 -1
- package/components/pagination/index.esm.js +489 -428
- package/components/pagination/index.umd.cjs +1 -1
- package/components/progress/index.esm.js +220 -220
- package/components/progress/index.umd.cjs +3 -3
- package/components/property-editor/index.esm.js +1512 -1540
- package/components/property-editor/index.umd.cjs +3 -3
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +749 -815
- package/components/property-panel/index.umd.cjs +1 -1
- package/components/query-solution/index.css +1 -0
- package/components/query-solution/index.esm.js +7074 -0
- package/components/query-solution/index.umd.cjs +1 -0
- package/components/query-solution/package.json +8 -0
- package/components/query-solution/style.js +2 -0
- package/components/radio-button/index.esm.js +86 -86
- package/components/radio-button/index.umd.cjs +1 -1
- package/components/radio-group/index.esm.js +442 -479
- package/components/radio-group/index.umd.cjs +1 -1
- package/components/rate/index.esm.js +213 -208
- package/components/rate/index.umd.cjs +1 -1
- package/components/response-layout/index.esm.js +116 -116
- package/components/response-layout/index.umd.cjs +1 -1
- package/components/response-layout-editor/index.esm.js +943 -918
- package/components/response-layout-editor/index.umd.cjs +1 -1
- package/components/response-toolbar/index.esm.js +1174 -1295
- package/components/response-toolbar/index.umd.cjs +1 -1
- package/components/schema-selector/index.css +1 -1
- package/components/schema-selector/index.esm.js +5383 -5171
- package/components/schema-selector/index.umd.cjs +2 -2
- package/components/search-box/index.esm.js +201 -201
- package/components/search-box/index.umd.cjs +1 -1
- package/components/section/index.esm.js +684 -542
- package/components/section/index.umd.cjs +1 -1
- package/components/smoke-detector/index.esm.js +121 -121
- package/components/smoke-detector/index.umd.cjs +1 -1
- package/components/spacing-editor/index.esm.js +2 -2
- package/components/spacing-editor/index.umd.cjs +1 -1
- package/components/splitter/index.esm.js +1158 -382
- package/components/splitter/index.umd.cjs +1 -1
- package/components/step/index.esm.js +232 -232
- package/components/step/index.umd.cjs +1 -1
- package/components/switch/index.esm.js +451 -487
- package/components/switch/index.umd.cjs +1 -1
- package/components/tabs/index.esm.js +2078 -2168
- package/components/tabs/index.umd.cjs +1 -1
- package/components/tags/index.esm.js +318 -320
- package/components/tags/index.umd.cjs +1 -1
- package/components/text/index.esm.js +192 -192
- package/components/text/index.umd.cjs +1 -1
- package/components/textarea/index.esm.js +471 -497
- package/components/textarea/index.umd.cjs +1 -1
- package/components/time-picker/index.esm.js +1421 -1441
- package/components/time-picker/index.umd.cjs +1 -1
- package/components/transfer/index.css +1 -1
- package/components/transfer/index.esm.js +430 -421
- package/components/transfer/index.umd.cjs +1 -1
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +6806 -6624
- package/components/tree-grid/index.umd.cjs +1 -1
- package/components/tree-view/index.esm.js +2793 -2433
- package/components/tree-view/index.umd.cjs +1 -1
- package/components/uploader/index.esm.js +165 -165
- package/components/uploader/index.umd.cjs +2 -2
- package/components/verify-detail/index.esm.js +255 -255
- package/components/verify-detail/index.umd.cjs +1 -1
- package/components/video/index.esm.js +413 -334
- package/components/video/index.umd.cjs +1 -1
- package/components/weather/index.esm.js +902 -902
- package/components/weather/index.umd.cjs +4 -4
- package/farris.all.esm.js +54155 -52847
- package/farris.all.umd.cjs +9 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/button-edit/src/designer/button-group.design.component.d.ts +7 -0
- package/types/checkbox/index.d.ts +1 -0
- package/types/combo-list/src/components/list-container.component.d.ts +3 -0
- package/types/combo-list/src/components/list-container.props.d.ts +5 -1
- package/types/common/entity/entity-schema.d.ts +258 -0
- package/types/component/src/component-ref.props.d.ts +4 -0
- package/types/component/src/composition/inner-component-build-info.d.ts +27 -0
- package/types/component/src/designer/use-designer-rules.d.ts +2 -2
- package/types/data-grid/index.d.ts +5 -2
- package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +33 -0
- package/types/data-grid/src/data-grid.component.d.ts +2 -1
- package/types/data-grid/src/data-grid.props.d.ts +2 -2
- package/types/data-grid/src/designer/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-grid/src/designer/use-group-column.d.ts +20 -0
- package/types/data-grid/src/property-config/data-grid.property-config.d.ts +4 -0
- package/types/data-grid/src/schema/schema-resolver.d.ts +2 -1
- package/types/data-view/components/column-format/boolean.component.d.ts +4 -0
- package/types/data-view/components/column-format/column-format.component.d.ts +4 -0
- package/types/data-view/components/column-format/date.component.d.ts +4 -0
- package/types/data-view/components/column-format/enum.component.d.ts +4 -0
- package/types/data-view/components/column-format/number.component.d.ts +4 -0
- package/types/data-view/composition/pagination/use-pagination.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +19 -7
- package/types/data-view/composition/use-edit.d.ts +2 -1
- package/types/designer-canvas/src/composition/dg-control.d.ts +16 -350
- package/types/designer-canvas/src/composition/function/use-dragula.d.ts +2 -2
- package/types/designer-canvas/src/types.d.ts +3 -3
- package/types/dynamic-form/index.d.ts +3 -1
- package/types/dynamic-form/src/composition/response-form-component-creator.service.d.ts +31 -0
- package/types/dynamic-form/src/schema/schema-resolver.d.ts +2 -1
- package/types/dynamic-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-resolver/src/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/types.d.ts +3 -2
- 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/response-toolbar/src/response-toolbar.props.d.ts +2 -2
- package/types/response-toolbar/src/schema/schema-mapper.d.ts +4 -0
- package/types/section/src/property-config/section.property-config.d.ts +93 -0
- package/types/section/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/composition/types.d.ts +2 -2
- package/types/tabs/src/designer/tab-header-item.design.component.d.ts +3 -1
- package/types/tabs/src/designer/tab-toolbar-item.props.d.ts +19 -0
- package/types/tabs/src/property-config/tab-page.property-config.d.ts +60 -0
- package/types/tabs/src/property-config/tabs.property-config.d.ts +6 -6
- package/types/tabs/src/schema/schema-resolver.d.ts +2 -1
- package/types/tags/index.d.ts +36 -5
- 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
|
@@ -1,167 +1,166 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { defineComponent as G, ref as f, computed as
|
|
5
|
-
import { cloneDeep as
|
|
1
|
+
var Ne = Object.defineProperty;
|
|
2
|
+
var Oe = (e, t, o) => t in e ? Ne(e, t, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[t] = o;
|
|
3
|
+
var L = (e, t, o) => Oe(e, typeof t != "symbol" ? t + "" : t, o);
|
|
4
|
+
import { defineComponent as G, ref as f, computed as B, createVNode as A, nextTick as ne, inject as _, onMounted as q, watch as I, createTextVNode as $e, reactive as Le, withDirectives as Ie, resolveDirective as Re, Fragment as pe, mergeProps as Z } from "vue";
|
|
5
|
+
import { cloneDeep as ge } from "lodash-es";
|
|
6
6
|
import "bignumber.js";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
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
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import "
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
7
|
+
import Ge, { useNumber as Ue, useFormat as qe, useSpinner as We, useTextBox as He } from "../number-spinner/index.esm.js";
|
|
8
|
+
import _e from "../accordion/index.esm.js";
|
|
9
|
+
import ze from "../avatar/index.esm.js";
|
|
10
|
+
import Je from "../button-edit/index.esm.js";
|
|
11
|
+
import Qe from "../button-group/index.esm.js";
|
|
12
|
+
import Ze from "../calendar/index.esm.js";
|
|
13
|
+
import Xe from "../capsule/index.esm.js";
|
|
14
|
+
import Ye from "../checkbox/index.esm.js";
|
|
15
|
+
import Ke from "../combo-list/index.esm.js";
|
|
16
|
+
import et from "../combo-tree/index.esm.js";
|
|
17
|
+
import tt from "../component/index.esm.js";
|
|
18
|
+
import ot from "../color-picker/index.esm.js";
|
|
19
|
+
import nt from "../content-container/index.esm.js";
|
|
20
|
+
import rt from "../date-picker/index.esm.js";
|
|
21
|
+
import at from "../data-grid/index.esm.js";
|
|
22
|
+
import st from "../dropdown/index.esm.js";
|
|
23
|
+
import it from "../dynamic-form/index.esm.js";
|
|
24
|
+
import lt from "../events-editor/index.esm.js";
|
|
25
|
+
import ct from "../filter-bar/index.esm.js";
|
|
26
|
+
import ut from "../field-selector/index.esm.js";
|
|
27
|
+
import pt from "../image-cropper/index.esm.js";
|
|
28
|
+
import dt from "../input-group/index.esm.js";
|
|
29
|
+
import mt from "../layout/index.esm.js";
|
|
30
|
+
import ft from "../list-nav/index.esm.js";
|
|
31
|
+
import yt from "../list-view/index.esm.js";
|
|
32
|
+
import gt from "../lookup/index.esm.js";
|
|
33
|
+
import bt from "../mapping-editor/index.esm.js";
|
|
34
|
+
import ht from "../nav/index.esm.js";
|
|
35
|
+
import vt from "../number-range/index.esm.js";
|
|
36
|
+
import Ct from "../order/index.esm.js";
|
|
37
|
+
import wt from "../page-header/index.esm.js";
|
|
38
|
+
import Tt from "../page-footer/index.esm.js";
|
|
39
|
+
import Ft from "../pagination/index.esm.js";
|
|
40
|
+
import Bt from "../progress/index.esm.js";
|
|
41
|
+
import jt from "../query-solution/index.esm.js";
|
|
42
|
+
import kt from "../radio-group/index.esm.js";
|
|
43
|
+
import Pt from "../rate/index.esm.js";
|
|
44
|
+
import xt from "../response-toolbar/index.esm.js";
|
|
45
|
+
import St from "../response-layout/index.esm.js";
|
|
46
|
+
import Mt from "../response-layout-editor/index.esm.js";
|
|
47
|
+
import At from "../search-box/index.esm.js";
|
|
48
|
+
import Dt from "../section/index.esm.js";
|
|
49
|
+
import Vt from "../smoke-detector/index.esm.js";
|
|
50
|
+
import Et from "../splitter/index.esm.js";
|
|
51
|
+
import Nt from "../step/index.esm.js";
|
|
52
|
+
import Ot from "../switch/index.esm.js";
|
|
53
|
+
import $t from "../tabs/index.esm.js";
|
|
54
|
+
import Lt from "../tags/index.esm.js";
|
|
55
|
+
import It from "../text/index.esm.js";
|
|
56
|
+
import Rt from "../time-picker/index.esm.js";
|
|
57
|
+
import Gt from "../transfer/index.esm.js";
|
|
58
|
+
import Ut from "../tree-view/index.esm.js";
|
|
59
|
+
import qt from "../uploader/index.esm.js";
|
|
60
|
+
import Wt from "../verify-detail/index.esm.js";
|
|
61
|
+
import Ht from "../weather/index.esm.js";
|
|
62
|
+
import _t from "../video/index.esm.js";
|
|
63
|
+
import zt from "../textarea/index.esm.js";
|
|
64
|
+
import Jt from "../schema-selector/index.esm.js";
|
|
65
|
+
import Qt from "../tree-grid/index.esm.js";
|
|
66
|
+
import "../external-container/index.esm.js";
|
|
67
|
+
import { getSchemaByType as de } from "../dynamic-resolver/index.esm.js";
|
|
68
|
+
const be = {}, he = {};
|
|
69
|
+
function ae(e) {
|
|
70
|
+
const { properties: t, title: o, ignore: r } = e, n = r && Array.isArray(r), s = Object.keys(t).reduce((a, l) => ((!n || !r.find((u) => u == l)) && (a[l] = t[l].type === "object" && t[l].properties ? ae(t[l]) : ge(t[l].default)), a), {});
|
|
71
|
+
return (!n || !r.find((a) => a == "id")) && (s.id = `${o}-${Date.now()}`), s;
|
|
71
72
|
}
|
|
72
|
-
function z(e, t = {}) {
|
|
73
|
-
const
|
|
74
|
-
if (
|
|
75
|
-
let
|
|
76
|
-
const
|
|
77
|
-
return
|
|
73
|
+
function z(e, t = {}, o) {
|
|
74
|
+
const r = be[e];
|
|
75
|
+
if (r) {
|
|
76
|
+
let n = ae(r);
|
|
77
|
+
const s = he[e];
|
|
78
|
+
return n = s ? s({ getSchemaByType: z }, n, t, o) : n, n;
|
|
78
79
|
}
|
|
79
80
|
return null;
|
|
80
81
|
}
|
|
81
|
-
function
|
|
82
|
-
const
|
|
83
|
-
return Object.keys(e).reduce((r,
|
|
82
|
+
function Zt(e, t) {
|
|
83
|
+
const o = ae(t);
|
|
84
|
+
return Object.keys(e).reduce((r, n) => (r[n] && typeof r[n] == "object" ? Object.assign(r[n], e[n]) : r[n] = e[n], r), o), o;
|
|
84
85
|
}
|
|
85
|
-
function
|
|
86
|
-
return Object.keys(e).filter((r) => e[r] != null).reduce((r,
|
|
87
|
-
if (t.has(
|
|
88
|
-
const
|
|
89
|
-
if (typeof
|
|
90
|
-
r[
|
|
86
|
+
function Xt(e, t) {
|
|
87
|
+
return Object.keys(e).filter((r) => e[r] != null).reduce((r, n) => {
|
|
88
|
+
if (t.has(n)) {
|
|
89
|
+
const s = t.get(n);
|
|
90
|
+
if (typeof s == "string")
|
|
91
|
+
r[s] = e[n];
|
|
91
92
|
else {
|
|
92
|
-
const
|
|
93
|
-
Object.assign(r,
|
|
93
|
+
const a = s(n, e[n], e);
|
|
94
|
+
Object.assign(r, a);
|
|
94
95
|
}
|
|
95
96
|
} else
|
|
96
|
-
r[
|
|
97
|
+
r[n] = e[n];
|
|
97
98
|
return r;
|
|
98
99
|
}, {});
|
|
99
100
|
}
|
|
100
|
-
function
|
|
101
|
-
const r =
|
|
102
|
-
return
|
|
101
|
+
function Yt(e, t, o = /* @__PURE__ */ new Map()) {
|
|
102
|
+
const r = Zt(e, t);
|
|
103
|
+
return Xt(r, o);
|
|
103
104
|
}
|
|
104
|
-
function
|
|
105
|
-
function t(
|
|
106
|
-
if (typeof
|
|
107
|
-
return y[
|
|
108
|
-
if (typeof
|
|
109
|
-
const
|
|
110
|
-
if (
|
|
111
|
-
return Number(y[
|
|
112
|
-
if (
|
|
113
|
-
return Number(y[
|
|
114
|
-
if (
|
|
115
|
-
return Number(y[
|
|
105
|
+
function Kt(e = {}) {
|
|
106
|
+
function t(i, d, p, y) {
|
|
107
|
+
if (typeof p == "number")
|
|
108
|
+
return y[i].length === p;
|
|
109
|
+
if (typeof p == "object") {
|
|
110
|
+
const w = Object.keys(p)[0], c = p[w];
|
|
111
|
+
if (w === "not")
|
|
112
|
+
return Number(y[i].length) !== Number(c);
|
|
113
|
+
if (w === "moreThan")
|
|
114
|
+
return Number(y[i].length) >= Number(c);
|
|
115
|
+
if (w === "lessThan")
|
|
116
|
+
return Number(y[i].length) <= Number(c);
|
|
116
117
|
}
|
|
117
118
|
return !1;
|
|
118
119
|
}
|
|
119
|
-
function
|
|
120
|
-
return y[
|
|
120
|
+
function o(i, d, p, y) {
|
|
121
|
+
return y[i] && y[i].propertyValue && String(y[i].propertyValue.value) === String(p);
|
|
121
122
|
}
|
|
122
123
|
const r = /* @__PURE__ */ new Map([
|
|
123
124
|
["length", t],
|
|
124
|
-
["getProperty",
|
|
125
|
+
["getProperty", o]
|
|
125
126
|
]);
|
|
126
|
-
Object.keys(e).reduce((
|
|
127
|
-
function
|
|
128
|
-
const
|
|
129
|
-
return typeof
|
|
127
|
+
Object.keys(e).reduce((i, d) => (i.set(d, e[d]), i), r);
|
|
128
|
+
function n(i, d) {
|
|
129
|
+
const p = i;
|
|
130
|
+
return typeof d == "number" ? [{ target: p, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: p, operator: "getProperty", param: i, value: !!d }] : typeof d == "object" ? Object.keys(d).map((y) => {
|
|
130
131
|
if (y === "length")
|
|
131
|
-
return { target:
|
|
132
|
-
const
|
|
133
|
-
return { target:
|
|
132
|
+
return { target: p, operator: "length", param: null, value: d[y] };
|
|
133
|
+
const w = y, c = d[y];
|
|
134
|
+
return { target: p, operator: "getProperty", param: w, value: c };
|
|
134
135
|
}) : [];
|
|
135
136
|
}
|
|
136
|
-
function i
|
|
137
|
-
return Object.keys(
|
|
138
|
-
const
|
|
139
|
-
return
|
|
137
|
+
function s(i) {
|
|
138
|
+
return Object.keys(i).reduce((p, y) => {
|
|
139
|
+
const w = n(y, i[y]);
|
|
140
|
+
return p.push(...w), p;
|
|
140
141
|
}, []);
|
|
141
142
|
}
|
|
142
|
-
function
|
|
143
|
-
if (r.has(
|
|
144
|
-
const
|
|
145
|
-
return
|
|
143
|
+
function a(i, d) {
|
|
144
|
+
if (r.has(i.operator)) {
|
|
145
|
+
const p = r.get(i.operator);
|
|
146
|
+
return p && p(i.target, i.param, i.value, d) || !1;
|
|
146
147
|
}
|
|
147
148
|
return !1;
|
|
148
149
|
}
|
|
149
|
-
function
|
|
150
|
-
return i
|
|
150
|
+
function l(i, d) {
|
|
151
|
+
return s(i).reduce((w, c) => w && a(c, d), !0);
|
|
151
152
|
}
|
|
152
|
-
function
|
|
153
|
-
const
|
|
154
|
-
return y ? !
|
|
153
|
+
function u(i, d) {
|
|
154
|
+
const p = Object.keys(i), y = p.includes("allOf"), w = p.includes("anyOf"), c = y || w, T = (c ? i[c ? y ? "allOf" : "anyOf" : "allOf"] : [i]).map((S) => l(S, d));
|
|
155
|
+
return y ? !T.includes(!1) : T.includes(!0);
|
|
155
156
|
}
|
|
156
|
-
return { parseValueSchema:
|
|
157
|
+
return { parseValueSchema: u };
|
|
157
158
|
}
|
|
158
|
-
const
|
|
159
|
-
|
|
160
|
-
ButtonGroup: { type: "ButtonGroup", name: "按钮组", icon: "ButtonGroup" },
|
|
159
|
+
const k = {
|
|
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
|
+
}, ve = {}, eo = {};
|
|
198
|
+
Kt();
|
|
199
|
+
function X(e, t, o = /* @__PURE__ */ new Map(), r = (a, l, u) => l, n = {}, s = (a) => a) {
|
|
200
|
+
return be[t.title] = t, he[t.title] = r, ve[t.title] = n, eo[t.title] = s, (a = {}) => {
|
|
201
|
+
const l = Yt(a, t, o), u = Object.keys(e).reduce((i, d) => (i[d] = e[d].default, i), {});
|
|
202
|
+
return Object.assign(u, l);
|
|
275
203
|
};
|
|
276
204
|
}
|
|
277
|
-
function
|
|
205
|
+
function Ce(e, t) {
|
|
278
206
|
return { customClass: t.class, customStyle: t.style };
|
|
279
207
|
}
|
|
280
|
-
function
|
|
208
|
+
function to() {
|
|
281
209
|
function e(t) {
|
|
282
210
|
return t.editor;
|
|
283
211
|
}
|
|
@@ -285,25 +213,148 @@ function Kt() {
|
|
|
285
213
|
resolve: e
|
|
286
214
|
};
|
|
287
215
|
}
|
|
288
|
-
const
|
|
289
|
-
["appearance",
|
|
216
|
+
const se = /* @__PURE__ */ new Map([
|
|
217
|
+
["appearance", Ce]
|
|
290
218
|
]);
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
}
|
|
219
|
+
var re = /* @__PURE__ */ ((e) => (e.String = "String", e.DateTime = "DateTime", e.Date = "Date", e.Enum = "Enum", e.Boolean = "Boolean", e.Number = "Number", e.Text = "Text", e.BigNumber = "BigNumber", e))(re || {});
|
|
220
|
+
const oo = "root-viewmodel";
|
|
221
|
+
class no {
|
|
222
|
+
constructor(t, o) {
|
|
223
|
+
L(this, "formSchemaUtils");
|
|
224
|
+
L(this, "controlCreatorUtils");
|
|
225
|
+
L(this, "designViewModelUtils");
|
|
226
|
+
this.resolver = t, this.designerHostService = o, this.formSchemaUtils = this.designerHostService.formSchemaUtils, this.controlCreatorUtils = this.designerHostService.controlCreatorUtils, this.designViewModelUtils = this.designerHostService.designViewModelUtils;
|
|
227
|
+
}
|
|
228
|
+
createComponent(t) {
|
|
229
|
+
const o = this.createComponentRefNode(t), r = this.createComponentNode(t), n = this.createViewModeNode(t), s = this.formSchemaUtils.getFormSchema();
|
|
230
|
+
return s.module.viewmodels.push(n), s.module.components.push(r), this.designViewModelUtils.assembleDesignViewModel(), o;
|
|
231
|
+
}
|
|
232
|
+
createComponentRefNode(t) {
|
|
233
|
+
const o = this.resolver.getSchemaByType("component-ref");
|
|
234
|
+
return Object.assign(o, {
|
|
235
|
+
id: `${t.componentId}-component-ref`,
|
|
236
|
+
component: `${t.componentId}-component`
|
|
237
|
+
}), o;
|
|
238
|
+
}
|
|
239
|
+
createComponentNode(t) {
|
|
240
|
+
const o = this.resolver.getSchemaByType("component"), r = this.createFormComponentContents(t);
|
|
241
|
+
return Object.assign(o, {
|
|
242
|
+
id: `${t.componentId}-component`,
|
|
243
|
+
viewModel: `${t.componentId}-component-viewmodel`,
|
|
244
|
+
componentType: t.componentType,
|
|
245
|
+
appearance: {
|
|
246
|
+
class: this.getFormComponentClass()
|
|
247
|
+
},
|
|
248
|
+
formColumns: t.formColumns,
|
|
249
|
+
contents: r
|
|
250
|
+
}), o;
|
|
251
|
+
}
|
|
252
|
+
/**
|
|
253
|
+
* 获取卡片组件层级的class样式
|
|
254
|
+
*/
|
|
255
|
+
getFormComponentClass() {
|
|
256
|
+
return this.formSchemaUtils.getFormSchema().module.templateId === "double-list-in-tab-template" ? "f-struct-wrapper f-utils-fill-flex-column" : "f-struct-wrapper";
|
|
257
|
+
}
|
|
258
|
+
createFormComponentContents(t) {
|
|
259
|
+
const o = this.resolver.getSchemaByType("section");
|
|
260
|
+
Object.assign(o, {
|
|
261
|
+
id: t.componentId + "-form-section",
|
|
262
|
+
appearance: {
|
|
263
|
+
class: "f-section-form f-section-in-mainsubcard"
|
|
264
|
+
},
|
|
265
|
+
mainTitle: t.componentName
|
|
266
|
+
});
|
|
267
|
+
const r = this.resolver.getSchemaByType("response-form"), n = [];
|
|
268
|
+
Object.assign(r, {
|
|
269
|
+
id: t.componentId + "-form",
|
|
270
|
+
appearance: {
|
|
271
|
+
class: "f-form-layout farris-form farris-form-controls-inline"
|
|
272
|
+
},
|
|
273
|
+
contents: n
|
|
274
|
+
}), o.contents = [r];
|
|
275
|
+
const { selectedFields: s } = t;
|
|
276
|
+
return s == null || s.forEach((l) => {
|
|
277
|
+
const u = ge(l), i = this.resolveControlClassByFormColumns(t), d = this.controlCreatorUtils.setFormFieldProperty(u, "", i);
|
|
278
|
+
d && n.push(d);
|
|
279
|
+
}), this.formSchemaUtils.getFormSchema().module.templateId === "double-list-in-tab-template" && (o.appearance.class = "f-section-grid f-section-in-main px-0 pt-0", o.fill = !0), [o];
|
|
280
|
+
}
|
|
281
|
+
resolveControlClassByFormColumns(t) {
|
|
282
|
+
let o = "";
|
|
283
|
+
switch (t.formColumns) {
|
|
284
|
+
case 1: {
|
|
285
|
+
o = "col-12 col-md-12 col-xl-12 col-el-12";
|
|
286
|
+
break;
|
|
287
|
+
}
|
|
288
|
+
case 2: {
|
|
289
|
+
o = "col-12 col-md-6 col-xl-6 col-el-6";
|
|
290
|
+
break;
|
|
291
|
+
}
|
|
292
|
+
case 3: {
|
|
293
|
+
o = "col-12 col-md-6 col-xl-4 col-el-4";
|
|
294
|
+
break;
|
|
295
|
+
}
|
|
296
|
+
case 4: {
|
|
297
|
+
o = "col-12 col-md-6 col-xl-3 col-el-2";
|
|
298
|
+
break;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
return o;
|
|
302
|
+
}
|
|
303
|
+
/**
|
|
304
|
+
* 添加viewModel节点
|
|
305
|
+
*/
|
|
306
|
+
createViewModeNode(t) {
|
|
307
|
+
return {
|
|
308
|
+
id: `${t.componentId}-component-viewmodel`,
|
|
309
|
+
code: `${t.componentId}-component-viewmodel`,
|
|
310
|
+
name: t.componentName,
|
|
311
|
+
bindTo: t.bindTo,
|
|
312
|
+
parent: oo,
|
|
313
|
+
fields: this.assembleViewModelFields(t),
|
|
314
|
+
commands: [],
|
|
315
|
+
states: [],
|
|
316
|
+
enableValidation: !0,
|
|
317
|
+
pagination: {
|
|
318
|
+
enable: !1
|
|
319
|
+
}
|
|
320
|
+
};
|
|
321
|
+
}
|
|
322
|
+
/**
|
|
323
|
+
* 组装viewModel fields 节点
|
|
324
|
+
*/
|
|
325
|
+
assembleViewModelFields(t) {
|
|
326
|
+
const o = [], { selectedFields: r } = t;
|
|
327
|
+
return r == null || r.forEach((n) => {
|
|
328
|
+
let s = "blur";
|
|
329
|
+
const a = n.type.name;
|
|
330
|
+
(a === re.Enum || a === re.Boolean) && (s = "change"), o.push({
|
|
331
|
+
type: "Form",
|
|
332
|
+
id: n.id,
|
|
333
|
+
fieldName: n.bindingField,
|
|
334
|
+
groupId: null,
|
|
335
|
+
groupName: null,
|
|
336
|
+
updateOn: s,
|
|
337
|
+
fieldSchema: {}
|
|
338
|
+
});
|
|
339
|
+
}), o;
|
|
340
|
+
}
|
|
300
341
|
}
|
|
301
|
-
function
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
342
|
+
function ro(e, t, o, r) {
|
|
343
|
+
const n = o.parentComponentInstance;
|
|
344
|
+
if (n) {
|
|
345
|
+
const a = {
|
|
346
|
+
componentId: `form-${Math.random().toString(36).slice(2, 6)}`,
|
|
347
|
+
componentName: "标题",
|
|
348
|
+
componentType: "form",
|
|
349
|
+
formColumns: 4,
|
|
350
|
+
parentContainerId: n.schema.id,
|
|
351
|
+
bindTo: "/"
|
|
352
|
+
};
|
|
353
|
+
return new no(e, r).createComponent(a);
|
|
354
|
+
} else
|
|
355
|
+
return t;
|
|
305
356
|
}
|
|
306
|
-
const
|
|
357
|
+
const ao = "https://json-schema.org/draft/2020-12/schema", so = "https://farris-design.gitee.io/response-form.schema.json", io = "response-form", lo = "A Farris Data Collection Component", co = "object", uo = {
|
|
307
358
|
id: {
|
|
308
359
|
description: "The unique identifier for a form group",
|
|
309
360
|
type: "string"
|
|
@@ -331,18 +382,18 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
331
382
|
type: "array",
|
|
332
383
|
default: []
|
|
333
384
|
}
|
|
334
|
-
},
|
|
385
|
+
}, po = [
|
|
335
386
|
"id",
|
|
336
387
|
"type"
|
|
337
|
-
],
|
|
338
|
-
$schema:
|
|
339
|
-
$id:
|
|
340
|
-
title:
|
|
341
|
-
description:
|
|
342
|
-
type:
|
|
343
|
-
properties:
|
|
344
|
-
required:
|
|
345
|
-
},
|
|
388
|
+
], mo = {
|
|
389
|
+
$schema: ao,
|
|
390
|
+
$id: so,
|
|
391
|
+
title: io,
|
|
392
|
+
description: lo,
|
|
393
|
+
type: co,
|
|
394
|
+
properties: uo,
|
|
395
|
+
required: po
|
|
396
|
+
}, fo = "response-form", yo = "A Farris Component", go = "object", bo = {
|
|
346
397
|
basic: {
|
|
347
398
|
description: "Basic Infomation",
|
|
348
399
|
title: "基本信息",
|
|
@@ -364,30 +415,30 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
364
415
|
}
|
|
365
416
|
}
|
|
366
417
|
}
|
|
367
|
-
},
|
|
368
|
-
title:
|
|
369
|
-
description:
|
|
370
|
-
type:
|
|
371
|
-
categories:
|
|
372
|
-
},
|
|
418
|
+
}, ho = {
|
|
419
|
+
title: fo,
|
|
420
|
+
description: yo,
|
|
421
|
+
type: go,
|
|
422
|
+
categories: bo
|
|
423
|
+
}, we = {
|
|
373
424
|
customClass: { type: String, default: "" }
|
|
374
|
-
},
|
|
425
|
+
}, me = X(we, mo, se, ro, ho), ee = /* @__PURE__ */ G({
|
|
375
426
|
name: "FResponseForm",
|
|
376
|
-
props:
|
|
427
|
+
props: we,
|
|
377
428
|
emits: [],
|
|
378
429
|
setup(e, t) {
|
|
379
|
-
const
|
|
380
|
-
const
|
|
430
|
+
const o = f(), r = B(() => {
|
|
431
|
+
const n = e.customClass.split(" "), s = {
|
|
381
432
|
"drag-container": !0
|
|
382
433
|
};
|
|
383
|
-
return
|
|
434
|
+
return n.reduce((a, l) => (a[l] = !0, a), s), s;
|
|
384
435
|
});
|
|
385
436
|
return () => A("div", {
|
|
386
|
-
ref:
|
|
437
|
+
ref: o,
|
|
387
438
|
class: r.value
|
|
388
439
|
}, [t.slots.default && t.slots.default()]);
|
|
389
440
|
}
|
|
390
|
-
}),
|
|
441
|
+
}), vo = "https://json-schema.org/draft/2020-12/schema", Co = "https://farris-design.gitee.io/form-group.schema.json", wo = "form-group", To = "A Farris Input Component", Fo = "object", Bo = {
|
|
391
442
|
id: {
|
|
392
443
|
description: "The unique identifier for a form group",
|
|
393
444
|
type: "string"
|
|
@@ -428,18 +479,18 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
428
479
|
description: "",
|
|
429
480
|
type: "number"
|
|
430
481
|
}
|
|
431
|
-
},
|
|
482
|
+
}, jo = [
|
|
432
483
|
"id",
|
|
433
484
|
"type"
|
|
434
|
-
],
|
|
435
|
-
$schema:
|
|
436
|
-
$id:
|
|
437
|
-
title:
|
|
438
|
-
description:
|
|
439
|
-
type:
|
|
440
|
-
properties:
|
|
441
|
-
required:
|
|
442
|
-
},
|
|
485
|
+
], Te = {
|
|
486
|
+
$schema: vo,
|
|
487
|
+
$id: Co,
|
|
488
|
+
title: wo,
|
|
489
|
+
description: To,
|
|
490
|
+
type: Fo,
|
|
491
|
+
properties: Bo,
|
|
492
|
+
required: jo
|
|
493
|
+
}, J = {
|
|
443
494
|
id: { type: String, default: "" },
|
|
444
495
|
customClass: { type: String, default: "" },
|
|
445
496
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
@@ -452,113 +503,113 @@ const nn = "https://json-schema.org/draft/2020-12/schema", on = "https://farris-
|
|
|
452
503
|
required: { type: Boolean, default: !1 },
|
|
453
504
|
showLabel: { type: Boolean, default: !0 },
|
|
454
505
|
type: { type: String, default: "input-group" }
|
|
455
|
-
},
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
506
|
+
}, fe = X(
|
|
507
|
+
J,
|
|
508
|
+
Te,
|
|
509
|
+
se,
|
|
459
510
|
void 0
|
|
460
|
-
),
|
|
461
|
-
function
|
|
462
|
-
var
|
|
511
|
+
), ko = to();
|
|
512
|
+
function ie(e, t, o) {
|
|
513
|
+
var O;
|
|
463
514
|
function r() {
|
|
464
|
-
|
|
515
|
+
o != null && o.resolveComponentContext && o.resolveComponentContext();
|
|
465
516
|
}
|
|
466
517
|
r();
|
|
467
|
-
const
|
|
468
|
-
function
|
|
469
|
-
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 :
|
|
518
|
+
const n = o && o.getStyles && o.getStyles() || "", s = o && o.getDesignerClass && o.getDesignerClass() || "", a = f();
|
|
519
|
+
function l() {
|
|
520
|
+
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : o && o.checkCanMoveComponent ? o.checkCanMoveComponent() : !0;
|
|
470
521
|
}
|
|
471
|
-
function
|
|
522
|
+
function u() {
|
|
472
523
|
return !1;
|
|
473
524
|
}
|
|
474
|
-
function
|
|
475
|
-
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 :
|
|
525
|
+
function i() {
|
|
526
|
+
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : o && o.checkCanDeleteComponent ? o.checkCanDeleteComponent() : !0;
|
|
476
527
|
}
|
|
477
|
-
function
|
|
478
|
-
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 :
|
|
528
|
+
function d() {
|
|
529
|
+
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 : o && o.hideNestedPaddingInDesginerView ? o.hideNestedPaddingInDesginerView() : !1;
|
|
479
530
|
}
|
|
480
|
-
function
|
|
481
|
-
if (!
|
|
531
|
+
function p(F) {
|
|
532
|
+
if (!F || !F.value)
|
|
482
533
|
return null;
|
|
483
|
-
if (
|
|
484
|
-
return
|
|
485
|
-
const
|
|
486
|
-
return
|
|
534
|
+
if (F.value.schema && F.value.schema.type === "component")
|
|
535
|
+
return F.value;
|
|
536
|
+
const M = f(F == null ? void 0 : F.value.parent), j = p(M);
|
|
537
|
+
return j || null;
|
|
487
538
|
}
|
|
488
|
-
function y(
|
|
489
|
-
const { componentInstance:
|
|
490
|
-
return !
|
|
539
|
+
function y(F = t) {
|
|
540
|
+
const { componentInstance: M, designerItemElementRef: j } = F;
|
|
541
|
+
return !M || !M.value ? null : M.value.canMove ? j : y(F.parent);
|
|
491
542
|
}
|
|
492
|
-
function F
|
|
493
|
-
return !!
|
|
543
|
+
function w(F) {
|
|
544
|
+
return !!o && o.canAccepts(F);
|
|
494
545
|
}
|
|
495
|
-
function
|
|
546
|
+
function c() {
|
|
496
547
|
return (t == null ? void 0 : t.schema.label) || (t == null ? void 0 : t.schema.title) || (t == null ? void 0 : t.schema.name);
|
|
497
548
|
}
|
|
498
|
-
function
|
|
549
|
+
function m() {
|
|
499
550
|
}
|
|
500
|
-
function g(
|
|
501
|
-
|
|
502
|
-
}
|
|
503
|
-
function
|
|
504
|
-
const { componentType:
|
|
505
|
-
let
|
|
506
|
-
|
|
507
|
-
const
|
|
508
|
-
return
|
|
509
|
-
}
|
|
510
|
-
function D(
|
|
511
|
-
const
|
|
512
|
-
|
|
513
|
-
let
|
|
514
|
-
|
|
515
|
-
const R =
|
|
516
|
-
return
|
|
517
|
-
}
|
|
518
|
-
function
|
|
519
|
-
}
|
|
520
|
-
function
|
|
521
|
-
if (
|
|
522
|
-
return
|
|
523
|
-
}
|
|
524
|
-
return
|
|
525
|
-
canMove:
|
|
526
|
-
canSelectParent:
|
|
527
|
-
canDelete:
|
|
528
|
-
canNested: !
|
|
551
|
+
function g(F, M) {
|
|
552
|
+
M && o != null && o.onAcceptMovedChildElement && o.onAcceptMovedChildElement(M);
|
|
553
|
+
}
|
|
554
|
+
function T(F, M) {
|
|
555
|
+
const { componentType: j } = F;
|
|
556
|
+
let V = z(j, F, M);
|
|
557
|
+
o && o.onResolveNewComponentSchema && (V = o.onResolveNewComponentSchema(F, V));
|
|
558
|
+
const $ = j.toLowerCase().replace("-", "_");
|
|
559
|
+
return V && !V.id && V.type === j && (V.id = `${$}_${Math.random().toString().slice(2, 6)}`), V;
|
|
560
|
+
}
|
|
561
|
+
function D(F, M) {
|
|
562
|
+
const j = String(F.getAttribute("data-controltype")), V = F.getAttribute("data-feature"), $ = V ? JSON.parse(V) : {};
|
|
563
|
+
$.parentComponentInstance = a.value;
|
|
564
|
+
let N = z(j, $);
|
|
565
|
+
o && o.onAcceptNewChildElement && (N = o.onAcceptNewChildElement(F, M, N));
|
|
566
|
+
const R = j.toLowerCase().replace("-", "_");
|
|
567
|
+
return N && !N.id && N.type === j && (N.id = `${R}_${Math.random().toString().slice(2, 6)}`), N;
|
|
568
|
+
}
|
|
569
|
+
function S(F) {
|
|
570
|
+
}
|
|
571
|
+
function x(...F) {
|
|
572
|
+
if (o && o.getPropsConfig)
|
|
573
|
+
return o.getPropsConfig(...F);
|
|
574
|
+
}
|
|
575
|
+
return a.value = {
|
|
576
|
+
canMove: l(),
|
|
577
|
+
canSelectParent: u(),
|
|
578
|
+
canDelete: i(),
|
|
579
|
+
canNested: !d(),
|
|
529
580
|
contents: t == null ? void 0 : t.schema.contents,
|
|
530
581
|
elementRef: e,
|
|
531
|
-
parent: (
|
|
582
|
+
parent: (O = t == null ? void 0 : t.parent) == null ? void 0 : O.componentInstance,
|
|
532
583
|
schema: t == null ? void 0 : t.schema,
|
|
533
|
-
styles:
|
|
534
|
-
designerClass:
|
|
535
|
-
canAccepts:
|
|
536
|
-
getBelongedComponentInstance:
|
|
584
|
+
styles: n,
|
|
585
|
+
designerClass: s,
|
|
586
|
+
canAccepts: w,
|
|
587
|
+
getBelongedComponentInstance: p,
|
|
537
588
|
getDraggableDesignItemElement: y,
|
|
538
|
-
getDraggingDisplayText:
|
|
539
|
-
getPropConfig:
|
|
540
|
-
getDragScopeElement:
|
|
589
|
+
getDraggingDisplayText: c,
|
|
590
|
+
getPropConfig: x,
|
|
591
|
+
getDragScopeElement: m,
|
|
541
592
|
onAcceptMovedChildElement: g,
|
|
542
593
|
onAcceptNewChildElement: D,
|
|
543
|
-
onChildElementMovedOut:
|
|
544
|
-
addNewChildComponentSchema:
|
|
594
|
+
onChildElementMovedOut: S,
|
|
595
|
+
addNewChildComponentSchema: T,
|
|
545
596
|
updateDragAndDropRules: r,
|
|
546
|
-
triggerBelongedComponentToMoveWhenMoved: !!
|
|
547
|
-
triggerBelongedComponentToDeleteWhenDeleted: !!
|
|
548
|
-
},
|
|
597
|
+
triggerBelongedComponentToMoveWhenMoved: !!o && o.triggerBelongedComponentToMoveWhenMoved || f(!1),
|
|
598
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!o && o.triggerBelongedComponentToDeleteWhenDeleted || f(!1)
|
|
599
|
+
}, a;
|
|
549
600
|
}
|
|
550
|
-
function
|
|
601
|
+
function Po() {
|
|
551
602
|
function e(t) {
|
|
552
|
-
var
|
|
603
|
+
var n, s;
|
|
553
604
|
if (!t)
|
|
554
605
|
return !1;
|
|
555
|
-
const
|
|
556
|
-
if (!
|
|
606
|
+
const o = ((n = t.targetContainer) == null ? void 0 : n.componentInstance) && t.targetContainer.componentInstance.value;
|
|
607
|
+
if (!o)
|
|
557
608
|
return !1;
|
|
558
|
-
const r = (
|
|
609
|
+
const r = (s = o.schema.appearance) == null ? void 0 : s.class;
|
|
559
610
|
if (t.controlCategory === "input" || t.controlType === "form-group") {
|
|
560
|
-
const
|
|
561
|
-
if (
|
|
611
|
+
const a = o.schema.type, l = (a === "response-form" || a === "content-container") && r && r.includes("farris-form");
|
|
612
|
+
if (o.schema.type !== "response-layout-item" && !l)
|
|
562
613
|
return !1;
|
|
563
614
|
}
|
|
564
615
|
return t.controlType !== "field-set";
|
|
@@ -567,7 +618,7 @@ function Bn() {
|
|
|
567
618
|
basalDragulaRuleForContainer: e
|
|
568
619
|
};
|
|
569
620
|
}
|
|
570
|
-
const
|
|
621
|
+
const xo = "https://json-schema.org/draft/2020-12/schema", So = "https://farris-design.gitee.io/dragging-rules.schema.json", Mo = "Dragging Rules", Ao = "The rules of designer canvas", Do = "object", Vo = {
|
|
571
622
|
"f-page": {
|
|
572
623
|
description: "The root class of page designed by farris.",
|
|
573
624
|
type: "object",
|
|
@@ -986,6 +1037,80 @@ const Sn = "https://json-schema.org/draft/2020-12/schema", Pn = "https://farris-
|
|
|
986
1037
|
"f-list-nav-left": {
|
|
987
1038
|
description: "",
|
|
988
1039
|
type: "object"
|
|
1040
|
+
},
|
|
1041
|
+
"f-struct-data-grid-in-nav": {
|
|
1042
|
+
description: "",
|
|
1043
|
+
type: "object",
|
|
1044
|
+
properties: {
|
|
1045
|
+
contents: {
|
|
1046
|
+
type: "object",
|
|
1047
|
+
properties: {
|
|
1048
|
+
"f-section-form": {
|
|
1049
|
+
description: "",
|
|
1050
|
+
type: "object",
|
|
1051
|
+
properties: {
|
|
1052
|
+
rules: {
|
|
1053
|
+
type: "object",
|
|
1054
|
+
properties: {
|
|
1055
|
+
canAccept: {
|
|
1056
|
+
type: "boolean",
|
|
1057
|
+
const: !1
|
|
1058
|
+
},
|
|
1059
|
+
fixed: {
|
|
1060
|
+
type: "boolean",
|
|
1061
|
+
const: !0
|
|
1062
|
+
},
|
|
1063
|
+
hidePadding: {
|
|
1064
|
+
type: "boolean",
|
|
1065
|
+
const: !0
|
|
1066
|
+
}
|
|
1067
|
+
}
|
|
1068
|
+
}
|
|
1069
|
+
}
|
|
1070
|
+
},
|
|
1071
|
+
"f-section-grid": {
|
|
1072
|
+
description: "",
|
|
1073
|
+
type: "object",
|
|
1074
|
+
properties: {
|
|
1075
|
+
rules: {
|
|
1076
|
+
type: "object",
|
|
1077
|
+
properties: {
|
|
1078
|
+
canAccept: {
|
|
1079
|
+
type: "boolean",
|
|
1080
|
+
const: !1
|
|
1081
|
+
},
|
|
1082
|
+
fixed: {
|
|
1083
|
+
type: "boolean",
|
|
1084
|
+
const: !0
|
|
1085
|
+
},
|
|
1086
|
+
hidePadding: {
|
|
1087
|
+
type: "boolean",
|
|
1088
|
+
const: !0
|
|
1089
|
+
}
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1092
|
+
}
|
|
1093
|
+
}
|
|
1094
|
+
}
|
|
1095
|
+
},
|
|
1096
|
+
rules: {
|
|
1097
|
+
type: "object",
|
|
1098
|
+
properties: {
|
|
1099
|
+
canAccept: {
|
|
1100
|
+
type: "boolean",
|
|
1101
|
+
const: !1
|
|
1102
|
+
},
|
|
1103
|
+
fixed: {
|
|
1104
|
+
type: "boolean",
|
|
1105
|
+
const: !0
|
|
1106
|
+
},
|
|
1107
|
+
hidePadding: {
|
|
1108
|
+
type: "boolean",
|
|
1109
|
+
const: !0
|
|
1110
|
+
}
|
|
1111
|
+
}
|
|
1112
|
+
}
|
|
1113
|
+
}
|
|
989
1114
|
}
|
|
990
1115
|
}
|
|
991
1116
|
}
|
|
@@ -1131,278 +1256,265 @@ const Sn = "https://json-schema.org/draft/2020-12/schema", Pn = "https://farris-
|
|
|
1131
1256
|
description: "",
|
|
1132
1257
|
type: "object"
|
|
1133
1258
|
}
|
|
1134
|
-
},
|
|
1135
|
-
$schema:
|
|
1136
|
-
$id:
|
|
1137
|
-
title:
|
|
1138
|
-
description:
|
|
1139
|
-
type:
|
|
1140
|
-
properties:
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
function
|
|
1144
|
-
function e(s, p, g, w) {
|
|
1259
|
+
}, Eo = {
|
|
1260
|
+
$schema: xo,
|
|
1261
|
+
$id: So,
|
|
1262
|
+
title: Mo,
|
|
1263
|
+
description: Ao,
|
|
1264
|
+
type: Do,
|
|
1265
|
+
properties: Vo
|
|
1266
|
+
}, te = /* @__PURE__ */ new Map();
|
|
1267
|
+
function No() {
|
|
1268
|
+
function e(c, m, g, T) {
|
|
1145
1269
|
var D;
|
|
1146
1270
|
if (typeof g == "number")
|
|
1147
|
-
return ((D =
|
|
1271
|
+
return ((D = T[c]) == null ? void 0 : D.length) === g;
|
|
1148
1272
|
if (typeof g == "object") {
|
|
1149
|
-
const
|
|
1150
|
-
if (
|
|
1151
|
-
return Number(
|
|
1152
|
-
if (
|
|
1153
|
-
return Number(
|
|
1154
|
-
if (
|
|
1155
|
-
return Number(
|
|
1273
|
+
const S = Object.keys(g)[0], x = g[S];
|
|
1274
|
+
if (S === "not")
|
|
1275
|
+
return Number(T[c].length) !== Number(x);
|
|
1276
|
+
if (S === "moreThan")
|
|
1277
|
+
return Number(T[c].length) >= Number(x);
|
|
1278
|
+
if (S === "lessThan")
|
|
1279
|
+
return Number(T[c].length) <= Number(x);
|
|
1156
1280
|
}
|
|
1157
1281
|
return !1;
|
|
1158
1282
|
}
|
|
1159
|
-
function t(
|
|
1160
|
-
return typeof g == "boolean" ?
|
|
1283
|
+
function t(c, m, g, T) {
|
|
1284
|
+
return typeof g == "boolean" ? T.childrenClassList.includes(m) === !!g : !1;
|
|
1161
1285
|
}
|
|
1162
|
-
function
|
|
1163
|
-
return typeof g == "boolean" ?
|
|
1286
|
+
function o(c, m, g, T) {
|
|
1287
|
+
return typeof g == "boolean" ? T.parentClassList.includes(m) === !!g : !1;
|
|
1164
1288
|
}
|
|
1165
|
-
function r(
|
|
1166
|
-
return typeof g == "boolean" ?
|
|
1289
|
+
function r(c, m, g, T) {
|
|
1290
|
+
return typeof g == "boolean" ? T.parentClassList.includes(m) === !!g : !1;
|
|
1167
1291
|
}
|
|
1168
|
-
const
|
|
1292
|
+
const n = /* @__PURE__ */ new Map([
|
|
1169
1293
|
["length", e],
|
|
1170
1294
|
["hasChildren", t],
|
|
1171
1295
|
["hasSibling", r],
|
|
1172
|
-
["hasParent",
|
|
1296
|
+
["hasParent", o]
|
|
1173
1297
|
]);
|
|
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:
|
|
1298
|
+
function s(c, m) {
|
|
1299
|
+
const g = c;
|
|
1300
|
+
return typeof m == "number" ? [{ target: g, operator: "length", param: null, value: Number(m) }] : typeof m == "object" ? Object.keys(m).map((T) => {
|
|
1301
|
+
if (T === "length")
|
|
1302
|
+
return { target: g, operator: "length", param: null, value: m[T] };
|
|
1303
|
+
const D = T, S = m[T];
|
|
1304
|
+
return { target: g, operator: c === "children" ? "hasChildren" : c === "parent" ? "hasParent" : "hasSibling", param: D, value: S };
|
|
1181
1305
|
}) : [];
|
|
1182
1306
|
}
|
|
1183
|
-
function
|
|
1184
|
-
if (
|
|
1185
|
-
const g =
|
|
1186
|
-
return g && g(
|
|
1307
|
+
function a(c, m) {
|
|
1308
|
+
if (n.has(c.operator)) {
|
|
1309
|
+
const g = n.get(c.operator);
|
|
1310
|
+
return g && g(c.target, c.param, c.value, m) || !1;
|
|
1187
1311
|
}
|
|
1188
1312
|
return !1;
|
|
1189
1313
|
}
|
|
1190
|
-
function
|
|
1191
|
-
return Object.keys(
|
|
1192
|
-
const
|
|
1193
|
-
return
|
|
1194
|
-
}, []).reduce((
|
|
1314
|
+
function l(c, m) {
|
|
1315
|
+
return Object.keys(c).reduce((S, x) => {
|
|
1316
|
+
const O = s(x, c[x]);
|
|
1317
|
+
return S.push(...O), S;
|
|
1318
|
+
}, []).reduce((S, x) => S && a(x, m), !0);
|
|
1195
1319
|
}
|
|
1196
|
-
function
|
|
1197
|
-
const g = Object.keys(
|
|
1198
|
-
return
|
|
1320
|
+
function u(c, m) {
|
|
1321
|
+
const g = Object.keys(c), T = g.includes("allOf"), D = g.includes("anyOf"), S = T || D, F = (S ? c[S ? T ? "allOf" : "anyOf" : "allOf"] : [c]).map((j) => l(j, m));
|
|
1322
|
+
return T ? !F.includes(!1) : F.includes(!0);
|
|
1199
1323
|
}
|
|
1200
|
-
function
|
|
1201
|
-
const g =
|
|
1202
|
-
return g ? typeof g == "boolean" ? g : typeof g == "object" ?
|
|
1324
|
+
function i(c, m) {
|
|
1325
|
+
const g = c.const;
|
|
1326
|
+
return g ? typeof g == "boolean" ? g : typeof g == "object" ? u(g, m) : !1 : !1;
|
|
1203
1327
|
}
|
|
1204
|
-
function
|
|
1205
|
-
return (
|
|
1328
|
+
function d(c) {
|
|
1329
|
+
return (m) => {
|
|
1206
1330
|
const g = { canAccept: !0, fixed: !1, hidePadding: !1 };
|
|
1207
|
-
return
|
|
1208
|
-
const
|
|
1209
|
-
return
|
|
1331
|
+
return c && c.properties && Object.keys(c.properties).reduce((T, D) => {
|
|
1332
|
+
const S = c.properties[D];
|
|
1333
|
+
return T[D] = i(S, m), T;
|
|
1210
1334
|
}, g), g;
|
|
1211
1335
|
};
|
|
1212
1336
|
}
|
|
1213
|
-
function c
|
|
1214
|
-
if (
|
|
1215
|
-
const { rules:
|
|
1216
|
-
g.set(
|
|
1217
|
-
(
|
|
1337
|
+
function p(c, m, g) {
|
|
1338
|
+
if (m.type === "object" && m.properties) {
|
|
1339
|
+
const { rules: T, contents: D } = m.properties;
|
|
1340
|
+
g.set(c, d(T)), D && Object.keys(D.properties).forEach(
|
|
1341
|
+
(S) => p(S, D.properties[S], g)
|
|
1218
1342
|
);
|
|
1219
1343
|
}
|
|
1220
1344
|
}
|
|
1221
1345
|
function y() {
|
|
1222
|
-
const { properties:
|
|
1223
|
-
Object.keys(
|
|
1224
|
-
|
|
1346
|
+
const { properties: c } = Eo;
|
|
1347
|
+
Object.keys(c).forEach((m) => {
|
|
1348
|
+
p(m, c[m], te);
|
|
1225
1349
|
});
|
|
1226
1350
|
}
|
|
1227
|
-
function
|
|
1351
|
+
function w(c, m) {
|
|
1228
1352
|
const g = { canAccept: !0, fixed: !1, hidePadding: !0 };
|
|
1229
|
-
return
|
|
1353
|
+
return te.has(c) ? te.get(c)(m) : g;
|
|
1230
1354
|
}
|
|
1231
|
-
return y(), { getRuleValue:
|
|
1355
|
+
return y(), { getRuleValue: w };
|
|
1232
1356
|
}
|
|
1233
|
-
function
|
|
1234
|
-
var
|
|
1235
|
-
const
|
|
1236
|
-
let
|
|
1237
|
-
function
|
|
1238
|
-
return
|
|
1239
|
-
}
|
|
1240
|
-
function y(
|
|
1241
|
-
return !(!
|
|
1242
|
-
}
|
|
1243
|
-
function
|
|
1244
|
-
|
|
1245
|
-
const
|
|
1246
|
-
const
|
|
1247
|
-
return
|
|
1248
|
-
}, []) : [],
|
|
1249
|
-
|
|
1250
|
-
componentClass:
|
|
1251
|
-
componentClassList:
|
|
1252
|
-
childContents:
|
|
1357
|
+
function Oo(e, t) {
|
|
1358
|
+
var M;
|
|
1359
|
+
const o = e.schema, r = (M = e.parent) == null ? void 0 : M.schema, n = No(), s = f(!1), a = f(!1);
|
|
1360
|
+
let l = !0, u = !1, i, d = !1;
|
|
1361
|
+
function p(j) {
|
|
1362
|
+
return i && i.componentClassList && i.componentClassList.includes("f-form-layout") && i.componentClassList.includes("farris-form") ? j.sourceType === "control" && j.controlCategory === "input" || j.sourceType === "move" && j.controlType === "form-group" : !0;
|
|
1363
|
+
}
|
|
1364
|
+
function y(j) {
|
|
1365
|
+
return !(!Po().basalDragulaRuleForContainer(j) || !l || !p(j));
|
|
1366
|
+
}
|
|
1367
|
+
function w() {
|
|
1368
|
+
s.value = !1, a.value = !1;
|
|
1369
|
+
const j = o, V = j.appearance && j.appearance.class || "", $ = V.split(" "), N = j.contents || [], R = N.length ? N[0] : null, P = R && R.appearance ? R.appearance.class : "", E = P ? P.split(" ") : [], U = N.length ? N.reduce((ce, K) => {
|
|
1370
|
+
const ue = K && K.appearance ? K.appearance.class : "", Ee = ue ? ue.split(" ") : [];
|
|
1371
|
+
return ce.push(...Ee), ce;
|
|
1372
|
+
}, []) : [], W = r, Y = W && W.appearance && W.appearance.class || "", Me = Y ? Y.split(" ") : [];
|
|
1373
|
+
i = {
|
|
1374
|
+
componentClass: V,
|
|
1375
|
+
componentClassList: $,
|
|
1376
|
+
childContents: N,
|
|
1253
1377
|
firstChildContent: R,
|
|
1254
|
-
firstChildClass:
|
|
1255
|
-
firstChildClassList:
|
|
1256
|
-
parent:
|
|
1257
|
-
parentClass:
|
|
1258
|
-
parentClassList:
|
|
1259
|
-
children:
|
|
1260
|
-
childrenClassList:
|
|
1378
|
+
firstChildClass: P,
|
|
1379
|
+
firstChildClassList: E,
|
|
1380
|
+
parent: W,
|
|
1381
|
+
parentClass: Y,
|
|
1382
|
+
parentClassList: Me,
|
|
1383
|
+
children: N,
|
|
1384
|
+
childrenClassList: U
|
|
1261
1385
|
};
|
|
1262
|
-
const { canAccept:
|
|
1263
|
-
return
|
|
1386
|
+
const { canAccept: Ae, fixed: De, hidePadding: Ve } = n.getRuleValue($[0], i);
|
|
1387
|
+
return l = Ae, u = Ve, d = De, !0;
|
|
1264
1388
|
}
|
|
1265
|
-
function
|
|
1266
|
-
|
|
1389
|
+
function c(j) {
|
|
1390
|
+
ne();
|
|
1267
1391
|
}
|
|
1268
|
-
function
|
|
1269
|
-
return
|
|
1392
|
+
function m() {
|
|
1393
|
+
return o.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
|
|
1270
1394
|
}
|
|
1271
|
-
function g(
|
|
1272
|
-
const
|
|
1273
|
-
if ((
|
|
1274
|
-
const { label:
|
|
1275
|
-
return
|
|
1395
|
+
function g(j, V) {
|
|
1396
|
+
const $ = o;
|
|
1397
|
+
if (($.appearance && $.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1398
|
+
const { label: P } = j, E = z("form-group");
|
|
1399
|
+
return E.editor = V, E.label = P, T(E), delete E.editor.id, delete E.editor.binding, delete E.editor.appearance, delete E.editor.visible, E;
|
|
1276
1400
|
}
|
|
1277
|
-
return
|
|
1401
|
+
return V;
|
|
1278
1402
|
}
|
|
1279
|
-
function
|
|
1280
|
-
const
|
|
1281
|
-
if (
|
|
1282
|
-
const
|
|
1283
|
-
|
|
1403
|
+
function T(j) {
|
|
1404
|
+
const V = e.componentInstance.value.getBelongedComponentInstance(e.componentInstance);
|
|
1405
|
+
if (V && V.schema && V.schema.componentType) {
|
|
1406
|
+
const $ = V.schema.formColumns, N = D($);
|
|
1407
|
+
j.appearance || (j.appearance = {}), j.appearance.class = N;
|
|
1284
1408
|
}
|
|
1285
1409
|
}
|
|
1286
|
-
function D(
|
|
1287
|
-
let
|
|
1288
|
-
switch (
|
|
1289
|
-
case
|
|
1290
|
-
|
|
1291
|
-
break;
|
|
1292
|
-
}
|
|
1293
|
-
case "form-col-12": {
|
|
1294
|
-
E = "col-12 col-md-12 col-xl-12 col-el-12";
|
|
1295
|
-
break;
|
|
1296
|
-
}
|
|
1297
|
-
case "form-col-2": {
|
|
1298
|
-
E = "col-12 col-md-6 col-xl-6 col-el-6";
|
|
1410
|
+
function D(j) {
|
|
1411
|
+
let V = "";
|
|
1412
|
+
switch (j) {
|
|
1413
|
+
case 1: {
|
|
1414
|
+
V = "col-12 col-md-12 col-xl-12 col-el-12";
|
|
1299
1415
|
break;
|
|
1300
1416
|
}
|
|
1301
|
-
case
|
|
1302
|
-
|
|
1417
|
+
case 2: {
|
|
1418
|
+
V = "col-12 col-md-6 col-xl-6 col-el-6";
|
|
1303
1419
|
break;
|
|
1304
1420
|
}
|
|
1305
|
-
case
|
|
1306
|
-
|
|
1421
|
+
case 3: {
|
|
1422
|
+
V = "col-12 col-md-6 col-xl-4 col-el-4";
|
|
1307
1423
|
break;
|
|
1308
1424
|
}
|
|
1309
|
-
case
|
|
1310
|
-
|
|
1311
|
-
break;
|
|
1312
|
-
}
|
|
1313
|
-
case "frame": {
|
|
1314
|
-
E = "col-12";
|
|
1425
|
+
case 4: {
|
|
1426
|
+
V = "col-12 col-md-6 col-xl-3 col-el-2";
|
|
1315
1427
|
break;
|
|
1316
1428
|
}
|
|
1317
1429
|
}
|
|
1318
|
-
return
|
|
1430
|
+
return V;
|
|
1319
1431
|
}
|
|
1320
|
-
function j
|
|
1321
|
-
const
|
|
1322
|
-
if ((
|
|
1323
|
-
const
|
|
1324
|
-
return
|
|
1432
|
+
function S(j, V, $) {
|
|
1433
|
+
const N = o;
|
|
1434
|
+
if ((N.appearance && N.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1435
|
+
const E = String(j.innerText), U = z("form-group");
|
|
1436
|
+
return U.editor = $, U.label = E, U;
|
|
1325
1437
|
}
|
|
1326
|
-
return
|
|
1438
|
+
return $;
|
|
1327
1439
|
}
|
|
1328
|
-
function
|
|
1329
|
-
return !
|
|
1440
|
+
function x() {
|
|
1441
|
+
return !d;
|
|
1330
1442
|
}
|
|
1331
|
-
function
|
|
1332
|
-
return !
|
|
1443
|
+
function O() {
|
|
1444
|
+
return !d;
|
|
1333
1445
|
}
|
|
1334
|
-
function
|
|
1335
|
-
return
|
|
1446
|
+
function F() {
|
|
1447
|
+
return u;
|
|
1336
1448
|
}
|
|
1337
1449
|
return {
|
|
1338
1450
|
canAccepts: y,
|
|
1339
|
-
checkCanDeleteComponent:
|
|
1340
|
-
checkCanMoveComponent:
|
|
1341
|
-
getStyles:
|
|
1342
|
-
hideNestedPaddingInDesginerView:
|
|
1343
|
-
onAcceptNewChildElement:
|
|
1344
|
-
onAcceptMovedChildElement:
|
|
1345
|
-
resolveComponentContext:
|
|
1451
|
+
checkCanDeleteComponent: O,
|
|
1452
|
+
checkCanMoveComponent: x,
|
|
1453
|
+
getStyles: m,
|
|
1454
|
+
hideNestedPaddingInDesginerView: F,
|
|
1455
|
+
onAcceptNewChildElement: S,
|
|
1456
|
+
onAcceptMovedChildElement: c,
|
|
1457
|
+
resolveComponentContext: w,
|
|
1346
1458
|
onResolveNewComponentSchema: g,
|
|
1347
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1348
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1459
|
+
triggerBelongedComponentToMoveWhenMoved: s,
|
|
1460
|
+
triggerBelongedComponentToDeleteWhenDeleted: a
|
|
1349
1461
|
};
|
|
1350
1462
|
}
|
|
1351
|
-
const
|
|
1463
|
+
const $o = /* @__PURE__ */ G({
|
|
1352
1464
|
name: "FResponseFormDesign",
|
|
1353
|
-
props:
|
|
1465
|
+
props: J,
|
|
1354
1466
|
emits: [],
|
|
1355
1467
|
setup(e, t) {
|
|
1356
|
-
const
|
|
1357
|
-
|
|
1358
|
-
const
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
}), t.expose(
|
|
1362
|
-
const
|
|
1363
|
-
const
|
|
1468
|
+
const o = f(), r = _("design-item-context");
|
|
1469
|
+
_("designer-host-service");
|
|
1470
|
+
const n = Oo(r), s = ie(o, r, n);
|
|
1471
|
+
q(() => {
|
|
1472
|
+
o.value.componentInstance = s;
|
|
1473
|
+
}), t.expose(s.value);
|
|
1474
|
+
const a = B(() => {
|
|
1475
|
+
const l = e.customClass.split(" "), u = {
|
|
1364
1476
|
"drag-container": !0
|
|
1365
1477
|
};
|
|
1366
|
-
return
|
|
1478
|
+
return l.reduce((i, d) => (i[d] = !0, i), u), u;
|
|
1367
1479
|
});
|
|
1368
1480
|
return () => A("div", {
|
|
1369
|
-
ref:
|
|
1370
|
-
class:
|
|
1481
|
+
ref: o,
|
|
1482
|
+
class: a.value,
|
|
1371
1483
|
"data-dragref": `${r.schema.id}-container`,
|
|
1372
1484
|
"data-associate": `${r.schema.id}-component`
|
|
1373
1485
|
}, [t.slots.default && t.slots.default()]);
|
|
1374
1486
|
}
|
|
1375
|
-
}),
|
|
1487
|
+
}), Lo = {
|
|
1376
1488
|
id: { type: String },
|
|
1377
1489
|
required: { type: Boolean, default: !1 },
|
|
1378
1490
|
text: { type: String, default: "" },
|
|
1379
1491
|
title: { type: String }
|
|
1380
|
-
},
|
|
1492
|
+
}, Fe = /* @__PURE__ */ G({
|
|
1381
1493
|
name: "FDynamicFormLabel",
|
|
1382
|
-
props:
|
|
1494
|
+
props: Lo,
|
|
1383
1495
|
emits: [],
|
|
1384
1496
|
setup(e, t) {
|
|
1385
|
-
const
|
|
1386
|
-
return
|
|
1387
|
-
|
|
1388
|
-
}),
|
|
1389
|
-
|
|
1497
|
+
const o = f(e.title || e.text), r = f(e.required), n = f(e.text);
|
|
1498
|
+
return I(() => e.text, () => {
|
|
1499
|
+
n.value = e.text;
|
|
1500
|
+
}), I(() => e.required, (s, a) => {
|
|
1501
|
+
s !== a && (r.value = s);
|
|
1390
1502
|
}), () => A("label", {
|
|
1391
1503
|
class: "col-form-label",
|
|
1392
|
-
title:
|
|
1504
|
+
title: o.value
|
|
1393
1505
|
}, [r.value && A("span", {
|
|
1394
1506
|
class: "farris-label-info text-danger"
|
|
1395
|
-
}, [
|
|
1507
|
+
}, [$e("*")]), A("span", {
|
|
1396
1508
|
class: "farris-label-text"
|
|
1397
|
-
}, [
|
|
1509
|
+
}, [n.value])]);
|
|
1398
1510
|
}
|
|
1399
|
-
}),
|
|
1400
|
-
["appearance",
|
|
1511
|
+
}), Io = /* @__PURE__ */ new Map([
|
|
1512
|
+
["appearance", Ce]
|
|
1401
1513
|
]);
|
|
1402
|
-
function
|
|
1514
|
+
function Ro(e, t, o) {
|
|
1403
1515
|
return t;
|
|
1404
1516
|
}
|
|
1405
|
-
const
|
|
1517
|
+
const Go = "https://json-schema.org/draft/2020-12/schema", Uo = "https://farris-design.gitee.io/input-group.schema.json", qo = "input-group", Wo = "A Farris Input Component", Ho = "object", _o = {
|
|
1406
1518
|
id: {
|
|
1407
1519
|
description: "The unique identifier for a Input Group",
|
|
1408
1520
|
type: "string"
|
|
@@ -1604,18 +1716,18 @@ const $n = "https://json-schema.org/draft/2020-12/schema", Rn = "https://farris-
|
|
|
1604
1716
|
type: "string",
|
|
1605
1717
|
default: ""
|
|
1606
1718
|
}
|
|
1607
|
-
},
|
|
1719
|
+
}, zo = [
|
|
1608
1720
|
"id",
|
|
1609
1721
|
"type"
|
|
1610
|
-
],
|
|
1611
|
-
$schema:
|
|
1612
|
-
$id:
|
|
1613
|
-
title:
|
|
1614
|
-
description:
|
|
1615
|
-
type:
|
|
1616
|
-
properties:
|
|
1617
|
-
required:
|
|
1618
|
-
},
|
|
1722
|
+
], Jo = {
|
|
1723
|
+
$schema: Go,
|
|
1724
|
+
$id: Uo,
|
|
1725
|
+
title: qo,
|
|
1726
|
+
description: Wo,
|
|
1727
|
+
type: Ho,
|
|
1728
|
+
properties: _o,
|
|
1729
|
+
required: zo
|
|
1730
|
+
}, le = {
|
|
1619
1731
|
/** 是否自动完成 */
|
|
1620
1732
|
autocomplete: { Type: String, default: "off" },
|
|
1621
1733
|
/** 自定义CLASS */
|
|
@@ -1682,118 +1794,118 @@ const $n = "https://json-schema.org/draft/2020-12/schema", Rn = "https://farris-
|
|
|
1682
1794
|
*/
|
|
1683
1795
|
updateOn: { type: String, default: "blur" }
|
|
1684
1796
|
};
|
|
1685
|
-
|
|
1686
|
-
function
|
|
1687
|
-
const
|
|
1797
|
+
X(le, Jo, Io, Ro);
|
|
1798
|
+
function Qo(e, t, o, r) {
|
|
1799
|
+
const n = f(e.disabled), s = f(!1), a = f("text"), l = f(e.showBorder), u = f(e.textAlign), i = f(e.updateOn), d = B(() => e.editable || !e.readonly), p = B(() => e.editable && !e.disabled && !e.readonly), y = B(() => !e.disabled && s.value), w = B(() => o.value === "" || o.value === null || o.value === void 0), c = B(() => (e.disabled || e.readonly) && !e.forcePlaceholder ? "" : e.placeholder), m = B(() => e.readonly || !e.editable), g = B(() => e.enableTitle ? o.value : ""), T = B(() => ({
|
|
1688
1800
|
"form-control": !0,
|
|
1689
1801
|
"f-utils-fill": !0,
|
|
1690
|
-
"text-left":
|
|
1691
|
-
"text-center":
|
|
1692
|
-
"text-right":
|
|
1693
|
-
})), D =
|
|
1694
|
-
const
|
|
1802
|
+
"text-left": u.value === "left",
|
|
1803
|
+
"text-center": u.value === "center",
|
|
1804
|
+
"text-right": u.value === "right"
|
|
1805
|
+
})), D = B(() => {
|
|
1806
|
+
const P = {
|
|
1695
1807
|
"f-cmp-inputgroup": !0,
|
|
1696
1808
|
"input-group": !0,
|
|
1697
|
-
"f-state-disable":
|
|
1698
|
-
"f-state-editable":
|
|
1699
|
-
"f-state-readonly":
|
|
1809
|
+
"f-state-disable": n.value,
|
|
1810
|
+
"f-state-editable": p.value,
|
|
1811
|
+
"f-state-readonly": m.value,
|
|
1700
1812
|
"f-state-focus": y.value
|
|
1701
1813
|
};
|
|
1702
|
-
return (e.customClass || "").split(" ").reduce((
|
|
1703
|
-
}),
|
|
1704
|
-
function
|
|
1705
|
-
|
|
1814
|
+
return (e.customClass || "").split(" ").reduce((U, W) => (U[W] = !0, U), P), P;
|
|
1815
|
+
}), S = B(() => l.value ? "" : "border-width : 0 ");
|
|
1816
|
+
function x(P, E = !0) {
|
|
1817
|
+
o.value = P, r.value !== P && (r.value = P), E && t.emit("change", P), t.emit("update:modelValue", P), t.emit("update:value", P);
|
|
1706
1818
|
}
|
|
1707
|
-
|
|
1819
|
+
I(
|
|
1708
1820
|
() => e.modelValue,
|
|
1709
|
-
(
|
|
1710
|
-
|
|
1821
|
+
(P, E) => {
|
|
1822
|
+
P !== E && (o.value = P, r.value = P);
|
|
1711
1823
|
}
|
|
1712
|
-
),
|
|
1713
|
-
|
|
1824
|
+
), I(() => e.disabled, (P, E) => {
|
|
1825
|
+
P !== E && (n.value = P);
|
|
1714
1826
|
});
|
|
1715
|
-
function
|
|
1716
|
-
return
|
|
1827
|
+
function O(P) {
|
|
1828
|
+
return s.value = !1, t.emit("blur", P), P.stopPropagation(), !1;
|
|
1717
1829
|
}
|
|
1718
|
-
function
|
|
1719
|
-
t.emit("click",
|
|
1830
|
+
function F(P) {
|
|
1831
|
+
t.emit("click", P);
|
|
1720
1832
|
}
|
|
1721
|
-
function
|
|
1722
|
-
e.disabled || (
|
|
1833
|
+
function M(P) {
|
|
1834
|
+
e.disabled || (l.value && (s.value = !0), d.value && t.emit("focus", P));
|
|
1723
1835
|
}
|
|
1724
|
-
function
|
|
1725
|
-
t.emit("input",
|
|
1726
|
-
const
|
|
1727
|
-
r.value =
|
|
1836
|
+
function j(P) {
|
|
1837
|
+
t.emit("input", P.target.value);
|
|
1838
|
+
const E = P.target.value;
|
|
1839
|
+
r.value = E, i.value === "input" && (t.emit("update:modelValue", E), t.emit("update:value", E));
|
|
1728
1840
|
}
|
|
1729
|
-
function
|
|
1730
|
-
t.emit("keydown",
|
|
1841
|
+
function V(P) {
|
|
1842
|
+
t.emit("keydown", P);
|
|
1731
1843
|
}
|
|
1732
|
-
function
|
|
1733
|
-
t.emit("keyup",
|
|
1844
|
+
function $(P) {
|
|
1845
|
+
t.emit("keyup", P);
|
|
1734
1846
|
}
|
|
1735
|
-
function
|
|
1736
|
-
|
|
1847
|
+
function N(P) {
|
|
1848
|
+
P.target.tagName !== "INPUT" && P.preventDefault(), P.stopPropagation();
|
|
1737
1849
|
}
|
|
1738
|
-
function R(
|
|
1739
|
-
if (
|
|
1740
|
-
const
|
|
1741
|
-
|
|
1850
|
+
function R(P) {
|
|
1851
|
+
if (i.value === "blur") {
|
|
1852
|
+
const E = P.target.value;
|
|
1853
|
+
P.stopPropagation(), x(E);
|
|
1742
1854
|
}
|
|
1743
1855
|
}
|
|
1744
1856
|
return {
|
|
1745
|
-
changeTextBoxValue:
|
|
1746
|
-
disabled:
|
|
1857
|
+
changeTextBoxValue: x,
|
|
1858
|
+
disabled: n,
|
|
1747
1859
|
displayText: r,
|
|
1748
|
-
editable:
|
|
1860
|
+
editable: p,
|
|
1749
1861
|
hasFocused: y,
|
|
1750
1862
|
inputGroupClass: D,
|
|
1751
|
-
inputType:
|
|
1752
|
-
isEmpty:
|
|
1753
|
-
modelValue:
|
|
1754
|
-
readonly:
|
|
1755
|
-
onBlur:
|
|
1756
|
-
onClick:
|
|
1757
|
-
onFocus:
|
|
1758
|
-
onInput:
|
|
1759
|
-
onKeydown:
|
|
1760
|
-
onKeyup:
|
|
1761
|
-
onMousedown:
|
|
1863
|
+
inputType: a,
|
|
1864
|
+
isEmpty: w,
|
|
1865
|
+
modelValue: o,
|
|
1866
|
+
readonly: m,
|
|
1867
|
+
onBlur: O,
|
|
1868
|
+
onClick: F,
|
|
1869
|
+
onFocus: M,
|
|
1870
|
+
onInput: j,
|
|
1871
|
+
onKeydown: V,
|
|
1872
|
+
onKeyup: $,
|
|
1873
|
+
onMousedown: N,
|
|
1762
1874
|
onTextBoxValueChange: R,
|
|
1763
|
-
placeholder:
|
|
1764
|
-
textBoxClass:
|
|
1875
|
+
placeholder: c,
|
|
1876
|
+
textBoxClass: T,
|
|
1765
1877
|
textBoxTitle: g,
|
|
1766
|
-
inputGroupStyle:
|
|
1878
|
+
inputGroupStyle: S
|
|
1767
1879
|
};
|
|
1768
1880
|
}
|
|
1769
|
-
function
|
|
1770
|
-
const
|
|
1771
|
-
|
|
1772
|
-
const
|
|
1881
|
+
function Zo(e, t, o, r) {
|
|
1882
|
+
const n = f(e.disabled), s = f(!1), a = f("text"), l = f(e.showBorder), u = f(e.textAlign);
|
|
1883
|
+
B(() => e.editable || !e.readonly);
|
|
1884
|
+
const i = B(() => e.editable && !e.disabled && !e.readonly), d = B(() => !e.disabled && s.value), p = B(() => o.value === "" || o.value === null || o.value === void 0), y = B(() => e.placeholder), w = B(() => e.readonly || !e.editable), c = B(() => e.enableTitle ? o.value : ""), m = B(() => ({
|
|
1773
1885
|
"form-control": !0,
|
|
1774
1886
|
// 'f-utils-fill': true,
|
|
1775
|
-
"text-left":
|
|
1776
|
-
"text-center":
|
|
1777
|
-
"text-right":
|
|
1778
|
-
})), g =
|
|
1887
|
+
"text-left": u.value === "left",
|
|
1888
|
+
"text-center": u.value === "center",
|
|
1889
|
+
"text-right": u.value === "right"
|
|
1890
|
+
})), g = B(() => ({
|
|
1779
1891
|
"f-cmp-inputgroup": !0,
|
|
1780
1892
|
"input-group": !0,
|
|
1781
1893
|
"f-state-disable": !0,
|
|
1782
1894
|
"f-state-editable": !1,
|
|
1783
1895
|
"f-state-readonly": !0
|
|
1784
1896
|
// 'f-state-focus': hasFocused.value
|
|
1785
|
-
})),
|
|
1897
|
+
})), T = B(() => l.value ? "" : "border-width : 0 ");
|
|
1786
1898
|
return {
|
|
1787
1899
|
// changeTextBoxValue,
|
|
1788
|
-
disabled:
|
|
1900
|
+
disabled: n,
|
|
1789
1901
|
displayText: r,
|
|
1790
|
-
editable:
|
|
1791
|
-
hasFocused:
|
|
1902
|
+
editable: i,
|
|
1903
|
+
hasFocused: d,
|
|
1792
1904
|
inputGroupClass: g,
|
|
1793
|
-
inputType:
|
|
1794
|
-
isEmpty:
|
|
1795
|
-
modelValue:
|
|
1796
|
-
readonly:
|
|
1905
|
+
inputType: a,
|
|
1906
|
+
isEmpty: p,
|
|
1907
|
+
modelValue: o,
|
|
1908
|
+
readonly: w,
|
|
1797
1909
|
// onBlur,
|
|
1798
1910
|
// onClick,
|
|
1799
1911
|
// onFocus,
|
|
@@ -1803,342 +1915,342 @@ function _n(e, t, n, r) {
|
|
|
1803
1915
|
// onMousedown,
|
|
1804
1916
|
// onTextBoxValueChange,
|
|
1805
1917
|
placeholder: y,
|
|
1806
|
-
textBoxClass:
|
|
1807
|
-
textBoxTitle:
|
|
1808
|
-
inputGroupStyle:
|
|
1918
|
+
textBoxClass: m,
|
|
1919
|
+
textBoxTitle: c,
|
|
1920
|
+
inputGroupStyle: T
|
|
1809
1921
|
};
|
|
1810
1922
|
}
|
|
1811
|
-
function
|
|
1812
|
-
const r = f(!1),
|
|
1813
|
-
function
|
|
1814
|
-
r.value =
|
|
1923
|
+
function Be(e, t, o) {
|
|
1924
|
+
const r = f(!1), n = B(() => e.enableClear && !e.readonly && !e.disabled), { changeTextBoxValue: s, displayText: a, hasFocused: l, isEmpty: u } = o;
|
|
1925
|
+
function i(m) {
|
|
1926
|
+
r.value = m;
|
|
1815
1927
|
}
|
|
1816
|
-
|
|
1817
|
-
|
|
1928
|
+
I(a, () => {
|
|
1929
|
+
l != null && l.value ? i(!!(a != null && a.value)) : i(!1);
|
|
1818
1930
|
});
|
|
1819
|
-
const
|
|
1931
|
+
const d = B(() => ({
|
|
1820
1932
|
"input-group-text": !0,
|
|
1821
1933
|
"input-group-clear": !0
|
|
1822
|
-
})),
|
|
1934
|
+
})), p = B(() => ({
|
|
1823
1935
|
width: "24px",
|
|
1824
1936
|
display: r.value ? "flex" : "none"
|
|
1825
1937
|
}));
|
|
1826
|
-
function y(
|
|
1827
|
-
|
|
1938
|
+
function y(m) {
|
|
1939
|
+
m.stopPropagation(), n.value && (s("", !0), i(!r.value), t.emit("clear"));
|
|
1828
1940
|
}
|
|
1829
|
-
function
|
|
1830
|
-
|
|
1941
|
+
function w(m) {
|
|
1942
|
+
n.value && !u.value && i(!0);
|
|
1831
1943
|
}
|
|
1832
|
-
function
|
|
1833
|
-
|
|
1944
|
+
function c(m) {
|
|
1945
|
+
n.value && i(!1);
|
|
1834
1946
|
}
|
|
1835
|
-
return { clearButtonClass:
|
|
1947
|
+
return { clearButtonClass: d, clearButtonStyle: p, hasShownClearButton: r, onClearValue: y, onMouseEnter: w, onMouseLeave: c, shouldShowClearButton: n };
|
|
1836
1948
|
}
|
|
1837
|
-
const
|
|
1838
|
-
function
|
|
1949
|
+
const Xo = ["moz", "ms", "webkit"];
|
|
1950
|
+
function Yo() {
|
|
1839
1951
|
let e = 0;
|
|
1840
1952
|
return (t) => {
|
|
1841
|
-
const
|
|
1842
|
-
t(
|
|
1953
|
+
const o = (/* @__PURE__ */ new Date()).getTime(), r = Math.max(0, 16 - (o - e)), n = setTimeout(() => {
|
|
1954
|
+
t(o + r);
|
|
1843
1955
|
}, r);
|
|
1844
|
-
return e =
|
|
1956
|
+
return e = o + r, n;
|
|
1845
1957
|
};
|
|
1846
1958
|
}
|
|
1847
|
-
function
|
|
1959
|
+
function Ko() {
|
|
1848
1960
|
if (typeof window > "u")
|
|
1849
1961
|
return () => 0;
|
|
1850
1962
|
if (window.requestAnimationFrame)
|
|
1851
1963
|
return window.requestAnimationFrame.bind(window);
|
|
1852
|
-
const e =
|
|
1853
|
-
return e ? window[`${e}RequestAnimationFrame`] :
|
|
1964
|
+
const e = Xo.filter((t) => `${t}RequestAnimationFrame` in window)[0];
|
|
1965
|
+
return e ? window[`${e}RequestAnimationFrame`] : Yo();
|
|
1854
1966
|
}
|
|
1855
|
-
|
|
1856
|
-
function
|
|
1857
|
-
const
|
|
1858
|
-
return { appendedButtonClass:
|
|
1967
|
+
Ko();
|
|
1968
|
+
function je(e, t) {
|
|
1969
|
+
const o = f(e.groupText), r = B(() => e.showButtonWhenDisabled && (e.readonly || e.disabled)), n = B(() => e.enableClear || !!e.groupText);
|
|
1970
|
+
return { appendedButtonClass: B(() => ({
|
|
1859
1971
|
"input-group-append": !0,
|
|
1860
1972
|
"append-force-show": r.value
|
|
1861
|
-
})), appendedContent:
|
|
1973
|
+
})), appendedContent: o, shouldShowAppendedButton: n };
|
|
1862
1974
|
}
|
|
1863
|
-
function
|
|
1864
|
-
const { appendedContent:
|
|
1865
|
-
|
|
1866
|
-
|
|
1975
|
+
function ke(e, t, o, r) {
|
|
1976
|
+
const { appendedContent: n } = r, s = f(e.enableViewPassword), a = B(() => e.type === "password"), l = '<span class="f-icon f-icon-eye" style="color: rgb(56, 143, 255);"></span>', u = '<span class="f-icon f-icon-eye"></span>', i = f(!1);
|
|
1977
|
+
I(() => [e.readonly, e.disabled], ([y, w]) => {
|
|
1978
|
+
a.value && (o.value = y || w ? "password" : o.value, n.value = y || w ? u : n.value);
|
|
1867
1979
|
});
|
|
1868
|
-
function
|
|
1869
|
-
return
|
|
1980
|
+
function d() {
|
|
1981
|
+
return i.value = !i.value, o.value = i.value ? "text" : "password", n.value = i.value ? l : u, !1;
|
|
1870
1982
|
}
|
|
1871
|
-
function
|
|
1872
|
-
|
|
1983
|
+
function p() {
|
|
1984
|
+
o.value = a.value ? "password" : "text", n.value = a.value ? s.value ? u : "" : n.value;
|
|
1873
1985
|
}
|
|
1874
|
-
return
|
|
1986
|
+
return p(), { isPassword: a, onClickAppendedButton: d };
|
|
1875
1987
|
}
|
|
1876
|
-
function
|
|
1988
|
+
function en(e, t, o) {
|
|
1877
1989
|
const r = f(), {
|
|
1878
|
-
onBlurTextBox:
|
|
1879
|
-
onFocusTextBox:
|
|
1880
|
-
onInput:
|
|
1881
|
-
onKeyDown:
|
|
1882
|
-
textBoxValue:
|
|
1883
|
-
} =
|
|
1990
|
+
onBlurTextBox: n,
|
|
1991
|
+
onFocusTextBox: s,
|
|
1992
|
+
onInput: a,
|
|
1993
|
+
onKeyDown: l,
|
|
1994
|
+
textBoxValue: u
|
|
1995
|
+
} = o, i = B(() => e.disabled || e.readonly || !e.editable ? "" : e.placeholder), d = B(() => ({
|
|
1884
1996
|
"form-control": !0,
|
|
1885
1997
|
"f-utils-fill": !0
|
|
1886
|
-
})),
|
|
1998
|
+
})), p = B(() => ({
|
|
1887
1999
|
"text-align": e.textAlign
|
|
1888
2000
|
}));
|
|
1889
|
-
function y(
|
|
1890
|
-
|
|
2001
|
+
function y(m) {
|
|
2002
|
+
m.stopPropagation();
|
|
1891
2003
|
}
|
|
1892
|
-
function
|
|
2004
|
+
function w() {
|
|
1893
2005
|
e.selectOnCreated, e.focusOnCreated;
|
|
1894
2006
|
}
|
|
1895
|
-
async function
|
|
1896
|
-
|
|
2007
|
+
async function c(m) {
|
|
2008
|
+
s(m), await ne, w();
|
|
1897
2009
|
}
|
|
1898
|
-
return
|
|
1899
|
-
await
|
|
2010
|
+
return q(async () => {
|
|
2011
|
+
await ne, w();
|
|
1900
2012
|
}), () => A("input", {
|
|
1901
2013
|
ref: r,
|
|
1902
|
-
class:
|
|
1903
|
-
style:
|
|
2014
|
+
class: d.value,
|
|
2015
|
+
style: p.value,
|
|
1904
2016
|
type: "text",
|
|
1905
|
-
value:
|
|
2017
|
+
value: u.value,
|
|
1906
2018
|
disabled: e.disabled,
|
|
1907
2019
|
readonly: e.readonly || !e.editable,
|
|
1908
|
-
placeholder:
|
|
1909
|
-
onBlur:
|
|
2020
|
+
placeholder: i.value,
|
|
2021
|
+
onBlur: n,
|
|
1910
2022
|
onChange: y,
|
|
1911
|
-
onFocus:
|
|
1912
|
-
onInput:
|
|
1913
|
-
onKeydown:
|
|
2023
|
+
onFocus: c,
|
|
2024
|
+
onInput: a,
|
|
2025
|
+
onKeydown: l
|
|
1914
2026
|
}, null);
|
|
1915
2027
|
}
|
|
1916
|
-
function
|
|
2028
|
+
function tn(e, t, o) {
|
|
1917
2029
|
const {
|
|
1918
2030
|
canDownward: r,
|
|
1919
|
-
canUpward:
|
|
1920
|
-
onClickDownButton:
|
|
1921
|
-
onClickUpButton:
|
|
1922
|
-
} =
|
|
2031
|
+
canUpward: n,
|
|
2032
|
+
onClickDownButton: s,
|
|
2033
|
+
onClickUpButton: a
|
|
2034
|
+
} = o, l = B(() => ({
|
|
1923
2035
|
"input-group-append": !0,
|
|
1924
2036
|
"btn-group": !0,
|
|
1925
2037
|
"btn-group-number": !0
|
|
1926
|
-
})),
|
|
2038
|
+
})), u = B(() => ({
|
|
1927
2039
|
btn: !0,
|
|
1928
2040
|
"btn-secondary": !0,
|
|
1929
2041
|
"btn-number-flag": !0
|
|
1930
|
-
})),
|
|
1931
|
-
cursor:
|
|
2042
|
+
})), i = B(() => ({
|
|
2043
|
+
cursor: n() ? "pointer" : "not-allowed",
|
|
1932
2044
|
"margin-left": 0
|
|
1933
|
-
})),
|
|
2045
|
+
})), d = B(() => ({
|
|
1934
2046
|
cursor: r() ? "pointer" : "not-allowed",
|
|
1935
2047
|
"margin-left": 0
|
|
1936
2048
|
}));
|
|
1937
2049
|
return () => A("div", {
|
|
1938
|
-
class:
|
|
2050
|
+
class: l.value
|
|
1939
2051
|
}, [A("button", {
|
|
1940
2052
|
title: "upButton",
|
|
1941
|
-
class:
|
|
1942
|
-
style:
|
|
1943
|
-
onClick:
|
|
1944
|
-
disabled: !
|
|
2053
|
+
class: u.value,
|
|
2054
|
+
style: i.value,
|
|
2055
|
+
onClick: a,
|
|
2056
|
+
disabled: !n()
|
|
1945
2057
|
}, [A("span", {
|
|
1946
2058
|
class: "f-icon f-icon-arrow-chevron-up number-arrow-chevron"
|
|
1947
2059
|
}, null)]), A("button", {
|
|
1948
2060
|
title: "downButton",
|
|
1949
|
-
class:
|
|
1950
|
-
style:
|
|
1951
|
-
onClick:
|
|
2061
|
+
class: u.value,
|
|
2062
|
+
style: d.value,
|
|
2063
|
+
onClick: s,
|
|
1952
2064
|
disabled: !r()
|
|
1953
2065
|
}, [A("span", {
|
|
1954
2066
|
class: "f-icon f-icon-arrow-chevron-down number-arrow-chevron"
|
|
1955
2067
|
}, null)])]);
|
|
1956
2068
|
}
|
|
1957
|
-
function
|
|
1958
|
-
const
|
|
1959
|
-
displayValue:
|
|
1960
|
-
modelValue:
|
|
1961
|
-
getRealValue:
|
|
1962
|
-
} =
|
|
1963
|
-
format:
|
|
2069
|
+
function on(e, t) {
|
|
2070
|
+
const o = Ue(e, t), r = qe(e, t, o), n = We(e, t, r, o), s = He(e, t, r, o, n), a = tn(e, t, n), {
|
|
2071
|
+
displayValue: l,
|
|
2072
|
+
modelValue: u,
|
|
2073
|
+
getRealValue: i
|
|
2074
|
+
} = o, d = en(e, t, s), {
|
|
2075
|
+
format: p
|
|
1964
2076
|
} = r, {
|
|
1965
2077
|
isFocus: y
|
|
1966
|
-
} =
|
|
1967
|
-
return
|
|
1968
|
-
const
|
|
1969
|
-
|
|
1970
|
-
}),
|
|
1971
|
-
const
|
|
1972
|
-
|
|
1973
|
-
}),
|
|
1974
|
-
|
|
1975
|
-
}),
|
|
1976
|
-
|
|
2078
|
+
} = s, w = B(() => !e.disabled && !e.readonly);
|
|
2079
|
+
return q(() => {
|
|
2080
|
+
const c = i(e.modelValue);
|
|
2081
|
+
l.value = p(c);
|
|
2082
|
+
}), I(() => [e.value], ([c]) => {
|
|
2083
|
+
const m = i(c);
|
|
2084
|
+
u.value = m, l.value = p(m);
|
|
2085
|
+
}), I(() => [e.modelValue], ([c]) => {
|
|
2086
|
+
c !== u.value && (u.value = c, !y.value && (l.value = p(i(c))));
|
|
2087
|
+
}), I(() => [e.precision, e.useThousands, e.prefix, e.suffix, e.showZero], () => {
|
|
2088
|
+
l.value = p(u.value);
|
|
1977
2089
|
}), () => A("div", {
|
|
1978
2090
|
class: "input-group f-state-hover flex-row f-cmp-number-spinner"
|
|
1979
|
-
}, [
|
|
2091
|
+
}, [d(), w.value && a()]);
|
|
1980
2092
|
}
|
|
1981
|
-
function
|
|
1982
|
-
const
|
|
1983
|
-
isPassword:
|
|
1984
|
-
} =
|
|
1985
|
-
disabled:
|
|
2093
|
+
function nn(e, t, o, r) {
|
|
2094
|
+
const n = f(), s = f(e.autocomplete), a = f(e.enableTitle), {
|
|
2095
|
+
isPassword: l
|
|
2096
|
+
} = o, u = f(e.minLength), i = f(e.maxLength), d = f(e.tabIndex), {
|
|
2097
|
+
disabled: p,
|
|
1986
2098
|
displayText: y,
|
|
1987
|
-
inputType:
|
|
1988
|
-
onBlur:
|
|
1989
|
-
onFocus:
|
|
2099
|
+
inputType: w,
|
|
2100
|
+
onBlur: c,
|
|
2101
|
+
onFocus: m,
|
|
1990
2102
|
onInput: g,
|
|
1991
|
-
onClick:
|
|
2103
|
+
onClick: T,
|
|
1992
2104
|
onKeydown: D,
|
|
1993
|
-
onKeyup:
|
|
1994
|
-
onMousedown:
|
|
1995
|
-
onTextBoxValueChange:
|
|
1996
|
-
readonly:
|
|
1997
|
-
placeholder:
|
|
1998
|
-
textBoxClass:
|
|
1999
|
-
textBoxTitle:
|
|
2105
|
+
onKeyup: S,
|
|
2106
|
+
onMousedown: x,
|
|
2107
|
+
onTextBoxValueChange: O,
|
|
2108
|
+
readonly: F,
|
|
2109
|
+
placeholder: M,
|
|
2110
|
+
textBoxClass: j,
|
|
2111
|
+
textBoxTitle: V
|
|
2000
2112
|
} = r;
|
|
2001
|
-
return
|
|
2113
|
+
return q(() => {
|
|
2002
2114
|
e.selectOnCreated, e.focusOnCreated;
|
|
2003
2115
|
}), () => A("input", {
|
|
2004
|
-
ref:
|
|
2116
|
+
ref: n,
|
|
2005
2117
|
name: "input-group-value",
|
|
2006
|
-
autocomplete:
|
|
2007
|
-
class:
|
|
2008
|
-
disabled:
|
|
2009
|
-
maxlength:
|
|
2010
|
-
minlength:
|
|
2011
|
-
placeholder:
|
|
2012
|
-
readonly:
|
|
2013
|
-
tabindex:
|
|
2014
|
-
title:
|
|
2015
|
-
type:
|
|
2118
|
+
autocomplete: s.value,
|
|
2119
|
+
class: j.value,
|
|
2120
|
+
disabled: p == null ? void 0 : p.value,
|
|
2121
|
+
maxlength: i.value,
|
|
2122
|
+
minlength: u.value,
|
|
2123
|
+
placeholder: M.value,
|
|
2124
|
+
readonly: F == null ? void 0 : F.value,
|
|
2125
|
+
tabindex: d.value,
|
|
2126
|
+
title: a.value && !l.value ? V.value : "",
|
|
2127
|
+
type: w.value,
|
|
2016
2128
|
value: y == null ? void 0 : y.value,
|
|
2017
|
-
onBlur:
|
|
2018
|
-
onClick:
|
|
2019
|
-
onChange:
|
|
2020
|
-
onFocus:
|
|
2129
|
+
onBlur: c,
|
|
2130
|
+
onClick: T,
|
|
2131
|
+
onChange: O,
|
|
2132
|
+
onFocus: m,
|
|
2021
2133
|
onInput: g,
|
|
2022
2134
|
onKeydown: D,
|
|
2023
|
-
onKeyup:
|
|
2024
|
-
onMousedown:
|
|
2135
|
+
onKeyup: S,
|
|
2136
|
+
onMousedown: x
|
|
2025
2137
|
}, null);
|
|
2026
2138
|
}
|
|
2027
|
-
function
|
|
2028
|
-
const
|
|
2139
|
+
function rn(e, t) {
|
|
2140
|
+
const o = B(() => e.useExtendInfo && !!e.extendInfo), r = Le({
|
|
2029
2141
|
content: e.extendInfo
|
|
2030
2142
|
});
|
|
2031
|
-
function
|
|
2143
|
+
function n() {
|
|
2032
2144
|
t.emit("updateExtendInfo");
|
|
2033
2145
|
}
|
|
2034
|
-
return () =>
|
|
2146
|
+
return () => o.value && Ie(A("span", {
|
|
2035
2147
|
class: "input-group-before-tips",
|
|
2036
|
-
onMouseenter:
|
|
2148
|
+
onMouseenter: n
|
|
2037
2149
|
}, [A("i", {
|
|
2038
2150
|
class: "f-icon f-icon-info-circle"
|
|
2039
2151
|
}, null), A("b", {
|
|
2040
2152
|
class: "tips-arrow"
|
|
2041
|
-
}, null)]), [[
|
|
2153
|
+
}, null)]), [[Re("tooltip"), r]]);
|
|
2042
2154
|
}
|
|
2043
|
-
function
|
|
2155
|
+
function Pe(e, t, o, r, n) {
|
|
2044
2156
|
const {
|
|
2045
|
-
appendedButtonClass:
|
|
2046
|
-
appendedContent:
|
|
2047
|
-
} =
|
|
2048
|
-
clearButtonClass:
|
|
2049
|
-
clearButtonStyle:
|
|
2157
|
+
appendedButtonClass: s,
|
|
2158
|
+
appendedContent: a
|
|
2159
|
+
} = o, l = B(() => e.showButtonWhenDisabled && (!e.editable || !e.readonly) && !e.disabled), u = B(() => a.value && !t.slots.groupTextTemplate), i = B(() => !!t.slots.groupTextTemplate), {
|
|
2160
|
+
clearButtonClass: d,
|
|
2161
|
+
clearButtonStyle: p,
|
|
2050
2162
|
onClearValue: y,
|
|
2051
|
-
shouldShowClearButton:
|
|
2163
|
+
shouldShowClearButton: w
|
|
2052
2164
|
} = r;
|
|
2053
|
-
function
|
|
2165
|
+
function c() {
|
|
2054
2166
|
return A("span", {
|
|
2055
2167
|
id: "clearIcon",
|
|
2056
|
-
class:
|
|
2057
|
-
style:
|
|
2058
|
-
onClick: (
|
|
2168
|
+
class: d.value,
|
|
2169
|
+
style: p.value,
|
|
2170
|
+
onClick: (M) => y(M)
|
|
2059
2171
|
}, [A("i", {
|
|
2060
2172
|
class: "f-icon modal_close"
|
|
2061
2173
|
}, null)]);
|
|
2062
2174
|
}
|
|
2063
|
-
function
|
|
2064
|
-
t.emit("iconMouseEnter",
|
|
2175
|
+
function m(M) {
|
|
2176
|
+
t.emit("iconMouseEnter", M);
|
|
2065
2177
|
}
|
|
2066
|
-
function g(
|
|
2067
|
-
t.emit("iconMouseLeave",
|
|
2178
|
+
function g(M) {
|
|
2179
|
+
t.emit("iconMouseLeave", M);
|
|
2068
2180
|
}
|
|
2069
|
-
function
|
|
2070
|
-
|
|
2071
|
-
originalEvent:
|
|
2072
|
-
}),
|
|
2181
|
+
function T(M) {
|
|
2182
|
+
l.value && t.emit("clickHandle", {
|
|
2183
|
+
originalEvent: M
|
|
2184
|
+
}), M.stopPropagation();
|
|
2073
2185
|
}
|
|
2074
|
-
const D = e.type === "password" ?
|
|
2075
|
-
function
|
|
2186
|
+
const D = e.type === "password" ? n.onClickAppendedButton : T;
|
|
2187
|
+
function S() {
|
|
2076
2188
|
return A("span", {
|
|
2077
2189
|
class: "input-group-text",
|
|
2078
|
-
onMouseenter: (
|
|
2079
|
-
onMouseleave: (
|
|
2080
|
-
innerHTML:
|
|
2081
|
-
onClick: (
|
|
2190
|
+
onMouseenter: (M) => m(M),
|
|
2191
|
+
onMouseleave: (M) => g(M),
|
|
2192
|
+
innerHTML: a.value,
|
|
2193
|
+
onClick: (M) => D(M)
|
|
2082
2194
|
}, null);
|
|
2083
2195
|
}
|
|
2084
|
-
function
|
|
2196
|
+
function x() {
|
|
2085
2197
|
return t.slots.groupTextTemplate && t.slots.groupTextTemplate();
|
|
2086
2198
|
}
|
|
2087
|
-
function
|
|
2088
|
-
return
|
|
2199
|
+
function O() {
|
|
2200
|
+
return u.value ? S : i.value ? x : "";
|
|
2089
2201
|
}
|
|
2090
|
-
const
|
|
2202
|
+
const F = O();
|
|
2091
2203
|
return () => A("div", {
|
|
2092
|
-
class:
|
|
2093
|
-
}, [
|
|
2204
|
+
class: s.value
|
|
2205
|
+
}, [w.value && c(), F && F()]);
|
|
2094
2206
|
}
|
|
2095
|
-
const
|
|
2207
|
+
const an = /* @__PURE__ */ G({
|
|
2096
2208
|
name: "FInputGroup",
|
|
2097
|
-
props:
|
|
2209
|
+
props: le,
|
|
2098
2210
|
emits: ["clear", "change", "blur", "click", "clickHandle", "focus", "input", "keydown", "keyup", "iconMouseEnter", "iconMouseLeave", "update:modelValue", "update:value", "updateExtendInfo", "valueChange"],
|
|
2099
2211
|
setup(e, t) {
|
|
2100
|
-
const
|
|
2101
|
-
inputGroupClass:
|
|
2102
|
-
inputType:
|
|
2103
|
-
inputGroupStyle:
|
|
2104
|
-
} =
|
|
2105
|
-
shouldShowAppendedButton:
|
|
2106
|
-
} =
|
|
2107
|
-
onMouseEnter:
|
|
2212
|
+
const o = f(e.modelValue), r = f(e.modelValue), n = Qo(e, t, o, r), {
|
|
2213
|
+
inputGroupClass: s,
|
|
2214
|
+
inputType: a,
|
|
2215
|
+
inputGroupStyle: l
|
|
2216
|
+
} = n, u = je(e), {
|
|
2217
|
+
shouldShowAppendedButton: i
|
|
2218
|
+
} = u, d = Be(e, t, n), {
|
|
2219
|
+
onMouseEnter: p,
|
|
2108
2220
|
onMouseLeave: y
|
|
2109
|
-
} =
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
}),
|
|
2113
|
-
|
|
2114
|
-
}),
|
|
2115
|
-
e.value && (
|
|
2221
|
+
} = d, w = ke(e, t, a, u), c = on(e, t), m = nn(e, t, w, n), g = Pe(e, t, u, d, w), T = rn(e, t), D = B(() => e.type === "number");
|
|
2222
|
+
I(() => [e.value], ([x]) => {
|
|
2223
|
+
o.value = x, r.value = x;
|
|
2224
|
+
}), I(() => [e.modelValue], ([x]) => {
|
|
2225
|
+
o.value = x, r.value = x;
|
|
2226
|
+
}), q(() => {
|
|
2227
|
+
e.value && (o.value = e.value, r.value = e.value);
|
|
2116
2228
|
});
|
|
2117
|
-
const
|
|
2229
|
+
const S = () => A(pe, null, [A("div", {
|
|
2118
2230
|
id: "inputGroup",
|
|
2119
|
-
class:
|
|
2120
|
-
style:
|
|
2121
|
-
onMouseenter:
|
|
2231
|
+
class: s.value,
|
|
2232
|
+
style: l.value,
|
|
2233
|
+
onMouseenter: p,
|
|
2122
2234
|
onMouseleave: y
|
|
2123
|
-
}, [D.value ?
|
|
2124
|
-
return () =>
|
|
2235
|
+
}, [D.value ? c() : A(pe, null, [T(), m(), i.value && g()])])]);
|
|
2236
|
+
return () => S();
|
|
2125
2237
|
}
|
|
2126
2238
|
}), b = {}, h = {}, v = {}, C = {};
|
|
2127
|
-
let
|
|
2128
|
-
function
|
|
2129
|
-
|
|
2239
|
+
let ye = !1;
|
|
2240
|
+
function sn() {
|
|
2241
|
+
ye || (ye = !0, ze.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), tt.register(b, h, v, C), nt.register(b, h, v, C), ot.register(b, h, v, C), rt.register(b, h, v, C), at.register(b, h, v, C), st.register(b, h, v, C), it.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), yt.register(b, h, v, C), ft.register(b, h, v, C), gt.register(b, h, v, C), bt.register(b, h, v, C), ht.register(b, h, v, C), vt.register(b, h, v, C), Ge.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), jt.register(b, h, v, C), kt.register(b, h, v, C), Pt.register(b, h, v, C), St.register(b, h, v, C), Mt.register(b, h, v, C), xt.register(b, h, v, C), Jt.register(b, h, v), At.register(b, h, v, C), Dt.register(b, h, v, C), Vt.register(b, h, v, C), Et.register(b, h, v, C), Nt.register(b, h, v, C), Ot.register(b, h, v, C), $t.register(b, h, v, C), Lt.register(b, h, v, C), It.register(b, h, v, C), Rt.register(b, h, v, C), Gt.register(b, h, v, C), Ut.register(b, h, v, C), Wt.register(b, h, v, C), qt.register(b, h, v, C), Ht.register(b, h, v, C), _t.register(b, h, v, C), zt.register(b, h, v, C), Qt.register(b, h, v, C));
|
|
2130
2242
|
}
|
|
2131
|
-
function
|
|
2132
|
-
|
|
2133
|
-
function e(
|
|
2134
|
-
const
|
|
2135
|
-
return
|
|
2243
|
+
function xe() {
|
|
2244
|
+
sn();
|
|
2245
|
+
function e(n, s) {
|
|
2246
|
+
const a = h[n];
|
|
2247
|
+
return a ? a(s) : {};
|
|
2136
2248
|
}
|
|
2137
|
-
function t(
|
|
2138
|
-
return b[
|
|
2249
|
+
function t(n) {
|
|
2250
|
+
return b[n] || an;
|
|
2139
2251
|
}
|
|
2140
|
-
function n
|
|
2141
|
-
switch (
|
|
2252
|
+
function o(n) {
|
|
2253
|
+
switch (n) {
|
|
2142
2254
|
case "check-box":
|
|
2143
2255
|
return "onChangeValue";
|
|
2144
2256
|
case "switch":
|
|
@@ -2190,209 +2302,274 @@ function we() {
|
|
|
2190
2302
|
return "onSchemaSelected";
|
|
2191
2303
|
case "mapping-editor":
|
|
2192
2304
|
return "onMappingFieldsChanged";
|
|
2305
|
+
case "textarea":
|
|
2306
|
+
return "onValueChange";
|
|
2193
2307
|
}
|
|
2194
2308
|
}
|
|
2195
|
-
function r(
|
|
2196
|
-
switch (
|
|
2309
|
+
function r(n) {
|
|
2310
|
+
switch (n) {
|
|
2197
2311
|
case "combo-list":
|
|
2198
2312
|
case "input-group":
|
|
2313
|
+
case "textarea":
|
|
2199
2314
|
return "onClear";
|
|
2200
2315
|
}
|
|
2201
2316
|
}
|
|
2202
|
-
return { resolveEditorProps: e, resolveEditorType: t, getChangeFunctionName:
|
|
2317
|
+
return { resolveEditorProps: e, resolveEditorType: t, getChangeFunctionName: o, getClearFunctionName: r };
|
|
2203
2318
|
}
|
|
2204
|
-
const
|
|
2319
|
+
const oe = /* @__PURE__ */ G({
|
|
2205
2320
|
name: "FDynamicFormGroup",
|
|
2206
|
-
props:
|
|
2321
|
+
props: J,
|
|
2207
2322
|
emits: ["change", "update:modelValue"],
|
|
2208
2323
|
setup(e, t) {
|
|
2209
|
-
const
|
|
2324
|
+
const o = f(e.id), r = f(e.customClass), n = f(e.editor), s = f(e.label), a = f(e.modelValue), l = f(e.readonly), u = f(e.required), i = f(e.showLabel), d = f(e.visible);
|
|
2210
2325
|
f(e.type);
|
|
2211
|
-
const
|
|
2326
|
+
const p = f(), {
|
|
2212
2327
|
resolveEditorProps: y,
|
|
2213
|
-
resolveEditorType:
|
|
2214
|
-
getChangeFunctionName:
|
|
2215
|
-
getClearFunctionName:
|
|
2216
|
-
} =
|
|
2328
|
+
resolveEditorType: w,
|
|
2329
|
+
getChangeFunctionName: c,
|
|
2330
|
+
getClearFunctionName: m
|
|
2331
|
+
} = xe(), g = B(() => ({
|
|
2217
2332
|
"form-group": !0,
|
|
2218
2333
|
"farris-form-group": !0,
|
|
2219
2334
|
"common-group": !0,
|
|
2220
|
-
"q-state-readonly":
|
|
2335
|
+
"q-state-readonly": l.value
|
|
2221
2336
|
}));
|
|
2222
|
-
function
|
|
2223
|
-
|
|
2337
|
+
function T(x, O) {
|
|
2338
|
+
a.value = O !== void 0 ? O : x, t.emit("update:modelValue", a.value), t.emit("change", a.value);
|
|
2224
2339
|
}
|
|
2225
2340
|
function D() {
|
|
2226
2341
|
t.emit("update:modelValue", "");
|
|
2227
2342
|
}
|
|
2228
|
-
const
|
|
2229
|
-
const
|
|
2230
|
-
return
|
|
2231
|
-
ref:
|
|
2232
|
-
},
|
|
2233
|
-
modelValue:
|
|
2234
|
-
"onUpdate:modelValue": (
|
|
2343
|
+
const S = B(() => {
|
|
2344
|
+
const x = n.value.type || "input-group", O = w(x), F = y(x, n.value), M = c(x), j = m(n.value.type);
|
|
2345
|
+
return F[M] = T, F[j] = D, () => A(O, Z({
|
|
2346
|
+
ref: p
|
|
2347
|
+
}, F, {
|
|
2348
|
+
modelValue: a.value,
|
|
2349
|
+
"onUpdate:modelValue": (V) => a.value = V
|
|
2235
2350
|
}), null);
|
|
2236
2351
|
});
|
|
2237
|
-
return
|
|
2238
|
-
|
|
2352
|
+
return I([() => e.id, () => e.customClass, () => e.editor, () => e.label, () => e.modelValue, () => e.readonly, () => e.required, () => e.showLabel, () => e.visible], ([x, O, F, M, j, V, $, N, R]) => {
|
|
2353
|
+
o.value = x, r.value = O, n.value = F, s.value = M, a.value = j, l.value = V, u.value = $, i.value = N, d.value = R;
|
|
2239
2354
|
}), t.expose({
|
|
2240
|
-
editorRef:
|
|
2241
|
-
}), () =>
|
|
2242
|
-
id: `${
|
|
2355
|
+
editorRef: p
|
|
2356
|
+
}), () => d.value && A("div", {
|
|
2357
|
+
id: `${o.value}-input-group`,
|
|
2243
2358
|
class: r.value
|
|
2244
2359
|
}, [A("div", {
|
|
2245
2360
|
class: "farris-group-wrap"
|
|
2246
2361
|
}, [A("div", {
|
|
2247
2362
|
class: g.value
|
|
2248
|
-
}, [
|
|
2249
|
-
id: `${
|
|
2250
|
-
required:
|
|
2251
|
-
text:
|
|
2252
|
-
title:
|
|
2363
|
+
}, [i.value && A(Fe, {
|
|
2364
|
+
id: `${o.value}-lable`,
|
|
2365
|
+
required: u.value,
|
|
2366
|
+
text: s.value,
|
|
2367
|
+
title: s.value
|
|
2253
2368
|
}, null), A("div", {
|
|
2254
2369
|
class: "farris-input-wrap"
|
|
2255
|
-
}, [
|
|
2370
|
+
}, [S.value()])])])]);
|
|
2256
2371
|
}
|
|
2257
|
-
}),
|
|
2258
|
-
function
|
|
2372
|
+
}), ln = {}, cn = {};
|
|
2373
|
+
function un(e, t) {
|
|
2259
2374
|
e.schema;
|
|
2260
|
-
const
|
|
2261
|
-
function
|
|
2375
|
+
const o = f(!0), r = f(!0);
|
|
2376
|
+
function n(p) {
|
|
2262
2377
|
return !1;
|
|
2263
2378
|
}
|
|
2264
|
-
function
|
|
2379
|
+
function s() {
|
|
2265
2380
|
return !1;
|
|
2266
2381
|
}
|
|
2267
|
-
function
|
|
2382
|
+
function a() {
|
|
2268
2383
|
return !1;
|
|
2269
2384
|
}
|
|
2270
|
-
function
|
|
2385
|
+
function l() {
|
|
2271
2386
|
return !0;
|
|
2272
2387
|
}
|
|
2273
|
-
function
|
|
2388
|
+
function u(p) {
|
|
2274
2389
|
}
|
|
2275
|
-
function
|
|
2390
|
+
function i() {
|
|
2276
2391
|
}
|
|
2277
|
-
function
|
|
2392
|
+
function d(p) {
|
|
2278
2393
|
return null;
|
|
2279
2394
|
}
|
|
2280
2395
|
return {
|
|
2281
|
-
canAccepts:
|
|
2282
|
-
checkCanDeleteComponent:
|
|
2283
|
-
checkCanMoveComponent:
|
|
2284
|
-
hideNestedPaddingInDesginerView:
|
|
2285
|
-
onAcceptMovedChildElement:
|
|
2286
|
-
resolveComponentContext:
|
|
2287
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
2396
|
+
canAccepts: n,
|
|
2397
|
+
checkCanDeleteComponent: s,
|
|
2398
|
+
checkCanMoveComponent: a,
|
|
2399
|
+
hideNestedPaddingInDesginerView: l,
|
|
2400
|
+
onAcceptMovedChildElement: u,
|
|
2401
|
+
resolveComponentContext: i,
|
|
2402
|
+
triggerBelongedComponentToMoveWhenMoved: o,
|
|
2288
2403
|
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
2289
|
-
getPropsConfig:
|
|
2404
|
+
getPropsConfig: d
|
|
2290
2405
|
};
|
|
2291
2406
|
}
|
|
2292
|
-
class
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2407
|
+
class pn {
|
|
2408
|
+
constructor(t, o) {
|
|
2409
|
+
L(this, "componentId");
|
|
2410
|
+
L(this, "viewModelId");
|
|
2411
|
+
L(this, "eventsEditorUtils");
|
|
2412
|
+
L(this, "formSchemaUtils");
|
|
2413
|
+
L(this, "formMetadataConverter");
|
|
2414
|
+
L(this, "designViewModelUtils");
|
|
2415
|
+
L(this, "designViewModelField");
|
|
2416
|
+
L(this, "controlCreatorUtils");
|
|
2417
|
+
L(this, "designerHostService");
|
|
2418
|
+
L(this, "schemaService", null);
|
|
2419
|
+
L(this, "metadataService", null);
|
|
2420
|
+
L(this, "propertyConfig", {
|
|
2421
|
+
type: "object",
|
|
2422
|
+
categories: {}
|
|
2423
|
+
});
|
|
2424
|
+
var r;
|
|
2425
|
+
this.componentId = t, this.designerHostService = o, this.eventsEditorUtils = o.eventsEditorUtils, this.formSchemaUtils = o.formSchemaUtils, this.formMetadataConverter = o.formMetadataConverter, this.viewModelId = ((r = this.formSchemaUtils) == null ? void 0 : r.getViewModelIdByComponentId(t)) || "", this.designViewModelUtils = o.designViewModelUtils, this.controlCreatorUtils = o.controlCreatorUtils, this.metadataService = o.metadataService, this.schemaService = o.schemaService;
|
|
2426
|
+
}
|
|
2427
|
+
getTableInfo() {
|
|
2428
|
+
var t;
|
|
2429
|
+
return (t = this.schemaService) == null ? void 0 : t.getTableInfoByViewModelId(this.viewModelId);
|
|
2430
|
+
}
|
|
2431
|
+
setDesignViewModelField(t) {
|
|
2432
|
+
const o = t.binding && t.binding.type === "Form" && t.binding.field;
|
|
2433
|
+
if (o) {
|
|
2434
|
+
if (!this.designViewModelField) {
|
|
2435
|
+
const r = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
2436
|
+
this.designViewModelField = r.fields.find((n) => n.id === o);
|
|
2437
|
+
}
|
|
2438
|
+
t.updateOn = this.designViewModelField.updateOn;
|
|
2439
|
+
}
|
|
2440
|
+
}
|
|
2441
|
+
changeFieldEditorType(t, o) {
|
|
2442
|
+
}
|
|
2443
|
+
getBasicPropConfig(t) {
|
|
2444
|
+
return {
|
|
2445
|
+
description: "Basic Information",
|
|
2446
|
+
title: "基本信息",
|
|
2447
|
+
properties: {
|
|
2448
|
+
id: {
|
|
2449
|
+
description: "组件标识",
|
|
2450
|
+
title: "标识",
|
|
2451
|
+
type: "string",
|
|
2452
|
+
readonly: !0
|
|
2453
|
+
},
|
|
2454
|
+
type: {
|
|
2455
|
+
description: "组件类型",
|
|
2456
|
+
title: "控件类型",
|
|
2457
|
+
type: "select",
|
|
2458
|
+
editor: {
|
|
2459
|
+
type: "combo-list",
|
|
2460
|
+
textField: "name",
|
|
2461
|
+
valueField: "value",
|
|
2462
|
+
data: [{ value: t.type, name: k[t.type].name }]
|
|
2463
|
+
}
|
|
2464
|
+
}
|
|
2465
|
+
}
|
|
2466
|
+
};
|
|
2467
|
+
}
|
|
2468
|
+
getAppearanceConfig(t = null) {
|
|
2469
|
+
return {
|
|
2470
|
+
title: "样式",
|
|
2471
|
+
description: "Appearance",
|
|
2472
|
+
properties: {
|
|
2473
|
+
class: {
|
|
2474
|
+
title: "class样式",
|
|
2475
|
+
type: "string",
|
|
2476
|
+
description: "组件的CSS样式",
|
|
2477
|
+
$converter: "/converter/appearance.converter"
|
|
2478
|
+
},
|
|
2479
|
+
style: {
|
|
2480
|
+
title: "style样式",
|
|
2481
|
+
type: "string",
|
|
2482
|
+
description: "组件的样式",
|
|
2483
|
+
$converter: "/converter/appearance.converter"
|
|
2484
|
+
}
|
|
2485
|
+
}
|
|
2486
|
+
};
|
|
2296
2487
|
}
|
|
2297
2488
|
}
|
|
2489
|
+
const H = class H {
|
|
2490
|
+
/**
|
|
2491
|
+
* 根据绑定字段类型获取可用的输入类控件
|
|
2492
|
+
*/
|
|
2493
|
+
static getEditorTypesByMDataType(t) {
|
|
2494
|
+
const o = H.fieldControlTypeMapping[t];
|
|
2495
|
+
return o || [{ key: "", value: "" }];
|
|
2496
|
+
}
|
|
2497
|
+
/**
|
|
2498
|
+
* 获取所有输入类控件
|
|
2499
|
+
*/
|
|
2500
|
+
static getAllInputTypes() {
|
|
2501
|
+
const t = [];
|
|
2502
|
+
for (let o in H.fieldControlTypeMapping)
|
|
2503
|
+
H.fieldControlTypeMapping[o].forEach((r) => {
|
|
2504
|
+
t.find((n) => n.key === r.key && n.value === r.value) || t.push({ key: r.key, value: r.value });
|
|
2505
|
+
});
|
|
2506
|
+
return t;
|
|
2507
|
+
}
|
|
2508
|
+
};
|
|
2298
2509
|
/**
|
|
2299
2510
|
* <字段类型,可配置的控件类型列表>的映射
|
|
2300
2511
|
*/
|
|
2301
|
-
|
|
2512
|
+
L(H, "fieldControlTypeMapping", {
|
|
2302
2513
|
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 },
|
|
2514
|
+
{ key: k["input-group"].type, value: k["input-group"].name },
|
|
2515
|
+
{ key: k.lookup.type, value: k.lookup.name },
|
|
2516
|
+
{ key: k["date-picker"].type, value: k["date-picker"].name },
|
|
2517
|
+
{ key: k["check-box"].type, value: k["check-box"].name },
|
|
2518
|
+
{ key: k["radio-group"].type, value: k["radio-group"].name },
|
|
2519
|
+
{ key: k["combo-list"].type, value: k["combo-list"].name },
|
|
2520
|
+
{ key: k.textarea.type, value: k.textarea.name }
|
|
2312
2521
|
],
|
|
2313
2522
|
Text: [
|
|
2314
|
-
{ key:
|
|
2315
|
-
{ key:
|
|
2316
|
-
{ key: T.lookup.type, value: T.lookup.name }
|
|
2523
|
+
{ key: k.textarea.type, value: k.textarea.name },
|
|
2524
|
+
{ key: k.lookup.type, value: k.lookup.name }
|
|
2317
2525
|
],
|
|
2318
2526
|
Decimal: [
|
|
2319
|
-
{ key:
|
|
2527
|
+
{ key: k["number-spinner"].type, value: k["number-spinner"].name }
|
|
2320
2528
|
],
|
|
2321
2529
|
Integer: [
|
|
2322
|
-
{ key:
|
|
2530
|
+
{ key: k["number-spinner"].type, value: k["number-spinner"].name }
|
|
2323
2531
|
],
|
|
2324
2532
|
Number: [
|
|
2325
|
-
{ key:
|
|
2533
|
+
{ key: k["number-spinner"].type, value: k["number-spinner"].name }
|
|
2326
2534
|
],
|
|
2327
2535
|
BigNumber: [
|
|
2328
|
-
{ key:
|
|
2536
|
+
{ key: k["number-spinner"].type, value: k["number-spinner"].name }
|
|
2329
2537
|
],
|
|
2330
2538
|
Date: [
|
|
2331
|
-
{ key:
|
|
2539
|
+
{ key: k["date-picker"].type, value: k["date-picker"].name }
|
|
2332
2540
|
],
|
|
2333
2541
|
DateTime: [
|
|
2334
|
-
{ key:
|
|
2542
|
+
{ key: k["date-picker"].type, value: k["date-picker"].name }
|
|
2335
2543
|
],
|
|
2336
2544
|
Boolean: [
|
|
2337
|
-
{ key:
|
|
2338
|
-
{ key:
|
|
2545
|
+
{ key: k.switch.type, value: k.switch.name },
|
|
2546
|
+
{ key: k["check-box"].type, value: k["check-box"].name }
|
|
2339
2547
|
],
|
|
2340
2548
|
Enum: [
|
|
2341
|
-
{ key:
|
|
2342
|
-
{ key:
|
|
2549
|
+
{ key: k["combo-list"].type, value: k["combo-list"].name },
|
|
2550
|
+
{ key: k["radio-group"].type, value: k["radio-group"].name }
|
|
2343
2551
|
],
|
|
2344
2552
|
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 }
|
|
2553
|
+
{ key: k.lookup.type, value: k.lookup.name },
|
|
2554
|
+
{ key: k["combo-list"].type, value: k["combo-list"].name },
|
|
2555
|
+
{ key: k["radio-group"].type, value: k["radio-group"].name }
|
|
2354
2556
|
]
|
|
2355
2557
|
});
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
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
|
-
}
|
|
2389
|
-
}
|
|
2390
|
-
changeFieldEditorType(t, n) {
|
|
2391
|
-
}
|
|
2392
|
-
getBasicPropConfig(t) {
|
|
2393
|
-
var r, o;
|
|
2394
|
-
var n = this;
|
|
2395
|
-
return this.setDesignViewModelField(t), {
|
|
2558
|
+
let Q = H;
|
|
2559
|
+
const dn = f(0);
|
|
2560
|
+
class mn extends pn {
|
|
2561
|
+
constructor(t, o) {
|
|
2562
|
+
super(t, o);
|
|
2563
|
+
}
|
|
2564
|
+
getPropertyConfig(t, o) {
|
|
2565
|
+
return this.propertyConfig.categories.basic = this.getBasicProperties(t, o), this.propertyConfig.categories.appearance = this.getAppearanceProperties(t), this.propertyConfig.categories.editor = this.getEditorProperties(t), this.propertyConfig;
|
|
2566
|
+
}
|
|
2567
|
+
getBasicProperties(t, o) {
|
|
2568
|
+
var a;
|
|
2569
|
+
var r = this;
|
|
2570
|
+
this.setDesignViewModelField(t);
|
|
2571
|
+
const n = this.formSchemaUtils.getFormMetadataBasicInfo(), s = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
2572
|
+
return {
|
|
2396
2573
|
description: "Basic Information",
|
|
2397
2574
|
title: "基本信息",
|
|
2398
2575
|
properties: {
|
|
@@ -2403,8 +2580,8 @@ class lo {
|
|
|
2403
2580
|
readonly: !0
|
|
2404
2581
|
},
|
|
2405
2582
|
type: {
|
|
2406
|
-
description: "
|
|
2407
|
-
title: "
|
|
2583
|
+
description: "编辑器类型",
|
|
2584
|
+
title: "编辑器类型",
|
|
2408
2585
|
type: "string",
|
|
2409
2586
|
refreshPanelAfterChanged: !0,
|
|
2410
2587
|
$converter: "/converter/change-editor.converter",
|
|
@@ -2412,63 +2589,52 @@ class lo {
|
|
|
2412
2589
|
type: "combo-list",
|
|
2413
2590
|
textField: "value",
|
|
2414
2591
|
valueField: "key",
|
|
2415
|
-
|
|
2416
|
-
|
|
2592
|
+
editable: !1,
|
|
2593
|
+
data: r.designViewModelField ? Q.getEditorTypesByMDataType((a = r.designViewModelField.type) == null ? void 0 : a.name) : Q.getAllInputTypes()
|
|
2417
2594
|
}
|
|
2418
2595
|
},
|
|
2419
2596
|
label: {
|
|
2420
2597
|
title: "标签",
|
|
2421
2598
|
type: "string",
|
|
2422
2599
|
$converter: "/converter/form-group-label.converter"
|
|
2600
|
+
},
|
|
2601
|
+
binding: {
|
|
2602
|
+
description: "绑定的表单字段",
|
|
2603
|
+
title: "绑定",
|
|
2604
|
+
$converter: "/converter/field-selector.converter",
|
|
2605
|
+
editor: {
|
|
2606
|
+
type: "field-selector",
|
|
2607
|
+
bindingType: { enable: !1 },
|
|
2608
|
+
editorParams: {
|
|
2609
|
+
propertyData: t,
|
|
2610
|
+
formBasicInfo: n
|
|
2611
|
+
},
|
|
2612
|
+
columns: [
|
|
2613
|
+
{ field: "name", title: "字段名称" },
|
|
2614
|
+
{ field: "bindingField", title: "绑定字段" },
|
|
2615
|
+
{ field: "fieldType", title: "字段类型" }
|
|
2616
|
+
],
|
|
2617
|
+
textField: "bindingField",
|
|
2618
|
+
data: s
|
|
2619
|
+
}
|
|
2423
2620
|
}
|
|
2424
2621
|
},
|
|
2425
|
-
setPropertyRelates(
|
|
2426
|
-
if (
|
|
2427
|
-
switch (
|
|
2622
|
+
setPropertyRelates(l, u) {
|
|
2623
|
+
if (l)
|
|
2624
|
+
switch (l && l.propertyID) {
|
|
2428
2625
|
case "type": {
|
|
2429
|
-
|
|
2626
|
+
r.changeControlType(t, l, o);
|
|
2627
|
+
break;
|
|
2628
|
+
}
|
|
2629
|
+
case "label": {
|
|
2630
|
+
l.needRefreshControlTree = !0;
|
|
2430
2631
|
break;
|
|
2431
2632
|
}
|
|
2432
2633
|
}
|
|
2433
2634
|
}
|
|
2434
2635
|
};
|
|
2435
2636
|
}
|
|
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) {
|
|
2637
|
+
getAppearanceProperties(t) {
|
|
2472
2638
|
return {
|
|
2473
2639
|
title: "样式",
|
|
2474
2640
|
description: "Appearance",
|
|
@@ -2498,73 +2664,52 @@ class lo {
|
|
|
2498
2664
|
}
|
|
2499
2665
|
};
|
|
2500
2666
|
}
|
|
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
2667
|
getEditorProperties(t) {
|
|
2530
2668
|
return this.getComponentConfig(t);
|
|
2531
2669
|
}
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2670
|
+
/**
|
|
2671
|
+
* 卡片控件:切换控件类型后事件
|
|
2672
|
+
* @param propertyData 控件DOM属性
|
|
2673
|
+
* @param newControlType 新控件类型
|
|
2674
|
+
*/
|
|
2675
|
+
changeControlType(t, o, r) {
|
|
2676
|
+
var i, d, p, y;
|
|
2677
|
+
const n = o.propertyValue, s = r && r.parent && r.parent.schema;
|
|
2678
|
+
if (!s)
|
|
2679
|
+
return;
|
|
2680
|
+
const a = s.contents.findIndex((w) => w.id === t.id), l = s.contents[a];
|
|
2681
|
+
let u;
|
|
2682
|
+
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
2541
2683
|
editor: {
|
|
2542
|
-
type:
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2684
|
+
$type: n
|
|
2685
|
+
},
|
|
2686
|
+
name: this.designViewModelField.name,
|
|
2687
|
+
require: this.designViewModelField.require,
|
|
2688
|
+
readonly: this.designViewModelField.readonly
|
|
2689
|
+
}, !1), u = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, n)), u || (u = de("form-group") || {}, u.editor = de(n) || {}, delete u.editor.id, delete u.editor.binding, delete u.editor.appearance), Object.assign(u, {
|
|
2690
|
+
id: l.id,
|
|
2691
|
+
appearance: l.appearance,
|
|
2692
|
+
size: l.size,
|
|
2693
|
+
label: l.label,
|
|
2694
|
+
binding: l.binding,
|
|
2695
|
+
visible: l.visible
|
|
2696
|
+
}), Object.assign(u.editor, {
|
|
2697
|
+
isTextArea: u.isTextArea && l.isTextArea,
|
|
2698
|
+
placeholder: (i = l.editor) == null ? void 0 : i.placeholder,
|
|
2699
|
+
holdPlace: (d = l.editor) == null ? void 0 : d.holdPlace,
|
|
2700
|
+
readonly: (p = l.editor) == null ? void 0 : p.readonly,
|
|
2701
|
+
require: (y = l.editor) == null ? void 0 : y.require
|
|
2702
|
+
}), s.contents.splice(a, 1), s.contents.splice(a, 0, u), r.schema = Object.assign(l, u), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
2703
|
+
(w) => w.classList.remove("dgComponentSelected")
|
|
2704
|
+
), dn.value++;
|
|
2705
|
+
}
|
|
2706
|
+
getComponentConfig(t, o = {}, r = {}) {
|
|
2707
|
+
const n = Object.assign({
|
|
2708
|
+
description: "编辑器",
|
|
2709
|
+
title: "编辑器",
|
|
2565
2710
|
type: "input-group",
|
|
2566
2711
|
$converter: "/converter/property-editor.converter"
|
|
2567
|
-
},
|
|
2712
|
+
}, o), s = Object.assign({
|
|
2568
2713
|
readonly: {
|
|
2569
2714
|
description: "",
|
|
2570
2715
|
title: "只读",
|
|
@@ -2586,144 +2731,144 @@ class co extends lo {
|
|
|
2586
2731
|
type: "string"
|
|
2587
2732
|
}
|
|
2588
2733
|
}, r);
|
|
2589
|
-
return { ...
|
|
2734
|
+
return { ...n, properties: { ...s } };
|
|
2590
2735
|
}
|
|
2591
2736
|
}
|
|
2592
|
-
class
|
|
2593
|
-
constructor(t,
|
|
2594
|
-
super(t,
|
|
2737
|
+
class fn extends mn {
|
|
2738
|
+
constructor(t, o) {
|
|
2739
|
+
super(t, o);
|
|
2595
2740
|
}
|
|
2596
2741
|
}
|
|
2597
|
-
function
|
|
2742
|
+
function yn(e, t) {
|
|
2598
2743
|
const {
|
|
2599
|
-
canAccepts:
|
|
2744
|
+
canAccepts: o,
|
|
2600
2745
|
checkCanDeleteComponent: r,
|
|
2601
|
-
checkCanMoveComponent:
|
|
2602
|
-
hideNestedPaddingInDesginerView:
|
|
2603
|
-
onAcceptMovedChildElement:
|
|
2604
|
-
resolveComponentContext:
|
|
2605
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
2606
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
2607
|
-
} =
|
|
2608
|
-
function
|
|
2609
|
-
return new
|
|
2746
|
+
checkCanMoveComponent: n,
|
|
2747
|
+
hideNestedPaddingInDesginerView: s,
|
|
2748
|
+
onAcceptMovedChildElement: a,
|
|
2749
|
+
resolveComponentContext: l,
|
|
2750
|
+
triggerBelongedComponentToMoveWhenMoved: u,
|
|
2751
|
+
triggerBelongedComponentToDeleteWhenDeleted: i
|
|
2752
|
+
} = un(e), d = e.schema;
|
|
2753
|
+
function p(y, w) {
|
|
2754
|
+
return new fn(y, t).getPropertyConfig(d, w);
|
|
2610
2755
|
}
|
|
2611
2756
|
return {
|
|
2612
|
-
canAccepts:
|
|
2757
|
+
canAccepts: o,
|
|
2613
2758
|
checkCanDeleteComponent: r,
|
|
2614
|
-
checkCanMoveComponent:
|
|
2615
|
-
hideNestedPaddingInDesginerView:
|
|
2616
|
-
onAcceptMovedChildElement:
|
|
2617
|
-
resolveComponentContext:
|
|
2618
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
2619
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
2620
|
-
getPropsConfig:
|
|
2759
|
+
checkCanMoveComponent: n,
|
|
2760
|
+
hideNestedPaddingInDesginerView: s,
|
|
2761
|
+
onAcceptMovedChildElement: a,
|
|
2762
|
+
resolveComponentContext: l,
|
|
2763
|
+
triggerBelongedComponentToMoveWhenMoved: u,
|
|
2764
|
+
triggerBelongedComponentToDeleteWhenDeleted: i,
|
|
2765
|
+
getPropsConfig: p
|
|
2621
2766
|
};
|
|
2622
2767
|
}
|
|
2623
|
-
const
|
|
2768
|
+
const gn = /* @__PURE__ */ G({
|
|
2624
2769
|
name: "FInputGroupDesign",
|
|
2625
|
-
props:
|
|
2770
|
+
props: le,
|
|
2626
2771
|
emits: ["updateExtendInfo", "clear", "valueChange", "clickHandle", "blurHandle", "focusHandle", "enterHandle", "iconMouseEnter", "iconMouseLeave", "keyupHandle", "keydownHandle", "inputClick"],
|
|
2627
2772
|
setup(e, t) {
|
|
2628
|
-
const
|
|
2629
|
-
inputGroupClass:
|
|
2630
|
-
inputType:
|
|
2631
|
-
inputGroupStyle:
|
|
2632
|
-
} =
|
|
2633
|
-
shouldShowAppendedButton:
|
|
2634
|
-
} =
|
|
2635
|
-
onMouseEnter:
|
|
2773
|
+
const o = f(e.modelValue), r = f(e.modelValue), n = Zo(e, t, o, r), {
|
|
2774
|
+
inputGroupClass: s,
|
|
2775
|
+
inputType: a,
|
|
2776
|
+
inputGroupStyle: l
|
|
2777
|
+
} = n, u = je(e), {
|
|
2778
|
+
shouldShowAppendedButton: i
|
|
2779
|
+
} = u, d = Be(e, t, n), {
|
|
2780
|
+
onMouseEnter: p,
|
|
2636
2781
|
onMouseLeave: y
|
|
2637
|
-
} =
|
|
2638
|
-
|
|
2639
|
-
|
|
2782
|
+
} = d, w = ke(e, t, a, u), c = f(), m = _("designer-host-service"), g = _("design-item-context"), T = yn(g, m), D = ie(c, g, T);
|
|
2783
|
+
q(() => {
|
|
2784
|
+
c.value.componentInstance = D;
|
|
2640
2785
|
}), t.expose(D.value);
|
|
2641
|
-
const
|
|
2786
|
+
const S = Pe(e, t, u, d, w), x = f();
|
|
2642
2787
|
return () => A("div", {
|
|
2643
2788
|
id: "inputGroup",
|
|
2644
|
-
ref:
|
|
2645
|
-
class:
|
|
2646
|
-
style:
|
|
2647
|
-
onMouseenter:
|
|
2789
|
+
ref: c,
|
|
2790
|
+
class: s.value,
|
|
2791
|
+
style: l.value,
|
|
2792
|
+
onMouseenter: p,
|
|
2648
2793
|
onMouseleave: y
|
|
2649
2794
|
}, [A("input", {
|
|
2650
|
-
ref:
|
|
2795
|
+
ref: x,
|
|
2651
2796
|
class: "form-control",
|
|
2652
2797
|
readonly: !0,
|
|
2653
2798
|
placeholder: e.placeholder
|
|
2654
|
-
}, null),
|
|
2799
|
+
}, null), i.value && S()]);
|
|
2655
2800
|
}
|
|
2656
2801
|
});
|
|
2657
|
-
function
|
|
2658
|
-
function e(
|
|
2659
|
-
const
|
|
2660
|
-
return
|
|
2802
|
+
function bn() {
|
|
2803
|
+
function e(o, r) {
|
|
2804
|
+
const n = cn[o];
|
|
2805
|
+
return n ? n(r) : {};
|
|
2661
2806
|
}
|
|
2662
|
-
function t(
|
|
2663
|
-
return
|
|
2807
|
+
function t(o) {
|
|
2808
|
+
return ln[o] || gn;
|
|
2664
2809
|
}
|
|
2665
2810
|
return { resolveEditorProps: e, resolveEditorType: t };
|
|
2666
2811
|
}
|
|
2667
|
-
const
|
|
2812
|
+
const hn = /* @__PURE__ */ G({
|
|
2668
2813
|
name: "FDynamicFormGroupDesign",
|
|
2669
|
-
props:
|
|
2814
|
+
props: J,
|
|
2670
2815
|
emits: ["change", "update:modelValue"],
|
|
2671
2816
|
setup(e, t) {
|
|
2672
|
-
const
|
|
2817
|
+
const o = f(e.id), r = f(e.customClass), n = f(e.editor), s = f(e.label), a = f(e.modelValue), l = f(!0), u = f(e.required), i = f(e.showLabel);
|
|
2673
2818
|
f(e.type);
|
|
2674
|
-
const
|
|
2675
|
-
resolveEditorProps:
|
|
2819
|
+
const d = f(), {
|
|
2820
|
+
resolveEditorProps: p,
|
|
2676
2821
|
resolveEditorType: y
|
|
2677
|
-
} =
|
|
2822
|
+
} = bn(), w = B(() => ({
|
|
2678
2823
|
"form-group": !0,
|
|
2679
2824
|
"farris-form-group": !0,
|
|
2680
2825
|
"common-group": !0,
|
|
2681
|
-
"q-state-readonly":
|
|
2826
|
+
"q-state-readonly": l.value,
|
|
2682
2827
|
"form-group-in-canvas": !0
|
|
2683
|
-
})),
|
|
2684
|
-
const
|
|
2685
|
-
return () => A(g,
|
|
2686
|
-
ref:
|
|
2687
|
-
},
|
|
2688
|
-
modelValue:
|
|
2689
|
-
"onUpdate:modelValue": (D) =>
|
|
2828
|
+
})), c = B(() => {
|
|
2829
|
+
const m = n.value.type || "input-group", g = y(m), T = p(m, n.value);
|
|
2830
|
+
return () => A(g, Z({
|
|
2831
|
+
ref: d
|
|
2832
|
+
}, T, {
|
|
2833
|
+
modelValue: a.value,
|
|
2834
|
+
"onUpdate:modelValue": (D) => a.value = D
|
|
2690
2835
|
}), null);
|
|
2691
2836
|
});
|
|
2692
|
-
return
|
|
2693
|
-
|
|
2837
|
+
return I([() => e.id, () => e.customClass, () => e.editor, () => e.label, () => e.modelValue, () => e.readonly, () => e.required, () => e.showLabel], ([m, g, T, D, S, x, O, F]) => {
|
|
2838
|
+
o.value = m, r.value = g, n.value = T, s.value = D, a.value = S, l.value = x, u.value = O, i.value = F;
|
|
2694
2839
|
}), t.expose({
|
|
2695
|
-
editorRef:
|
|
2840
|
+
editorRef: d
|
|
2696
2841
|
}), () => A("div", {
|
|
2697
|
-
id: `${
|
|
2842
|
+
id: `${o.value}-input-group`,
|
|
2698
2843
|
class: r.value,
|
|
2699
2844
|
design_test: !0
|
|
2700
2845
|
}, [A("div", {
|
|
2701
2846
|
class: "farris-group-wrap"
|
|
2702
2847
|
}, [A("div", {
|
|
2703
|
-
class:
|
|
2704
|
-
}, [
|
|
2705
|
-
id: `${
|
|
2706
|
-
required:
|
|
2707
|
-
text:
|
|
2708
|
-
title:
|
|
2848
|
+
class: w.value
|
|
2849
|
+
}, [i.value && A(Fe, {
|
|
2850
|
+
id: `${o.value}-lable`,
|
|
2851
|
+
required: u.value,
|
|
2852
|
+
text: s.value,
|
|
2853
|
+
title: s.value
|
|
2709
2854
|
}, null), A("div", {
|
|
2710
2855
|
class: "farris-input-wrap"
|
|
2711
|
-
}, [
|
|
2856
|
+
}, [c.value()])])])]);
|
|
2712
2857
|
}
|
|
2713
|
-
}),
|
|
2858
|
+
}), vn = /* @__PURE__ */ G({
|
|
2714
2859
|
name: "FFormGroupDesign",
|
|
2715
|
-
props:
|
|
2860
|
+
props: J,
|
|
2716
2861
|
emits: [],
|
|
2717
2862
|
setup(e, t) {
|
|
2718
|
-
const
|
|
2719
|
-
return
|
|
2720
|
-
|
|
2721
|
-
var
|
|
2722
|
-
let
|
|
2723
|
-
return
|
|
2863
|
+
const o = f(), r = _("design-item-context"), n = ie(o, r);
|
|
2864
|
+
return n.value.canNested = !1, n.value.canMove = !0, n.value.canDelete = !0, q(() => {
|
|
2865
|
+
o.value.componentInstance = n, n.value.getPropConfig = (...s) => {
|
|
2866
|
+
var l, u, i;
|
|
2867
|
+
let a = ve[e.editor.type];
|
|
2868
|
+
return a && Object.keys(a).length === 0 && ((l = o.value) != null && l.editorRef) && ((i = (u = o.value) == null ? void 0 : u.editorRef) != null && i.getPropConfig) && (a = o.value.editorRef.getPropConfig(...s, n.value)), a;
|
|
2724
2869
|
};
|
|
2725
|
-
}), t.expose(
|
|
2726
|
-
ref:
|
|
2870
|
+
}), t.expose(n.value), () => A(hn, Z(e, {
|
|
2871
|
+
ref: o
|
|
2727
2872
|
}), null);
|
|
2728
2873
|
}
|
|
2729
2874
|
}), Se = {
|
|
@@ -2740,55 +2885,57 @@ const yo = /* @__PURE__ */ G({
|
|
|
2740
2885
|
* 作为内嵌编辑器被创建后默认选中文本
|
|
2741
2886
|
*/
|
|
2742
2887
|
selectOnCreated: { type: Boolean, default: !1 }
|
|
2743
|
-
},
|
|
2888
|
+
}, Cn = X(
|
|
2744
2889
|
Se,
|
|
2745
|
-
|
|
2746
|
-
|
|
2890
|
+
Te,
|
|
2891
|
+
se,
|
|
2747
2892
|
void 0
|
|
2748
|
-
),
|
|
2893
|
+
), wn = /* @__PURE__ */ G({
|
|
2749
2894
|
name: "FDynamicFormInput",
|
|
2750
2895
|
props: Se,
|
|
2751
2896
|
emits: ["change", "update:modelValue"],
|
|
2752
2897
|
setup(e, t) {
|
|
2753
|
-
const
|
|
2754
|
-
resolveEditorProps:
|
|
2755
|
-
resolveEditorType:
|
|
2756
|
-
getChangeFunctionName:
|
|
2757
|
-
} =
|
|
2758
|
-
function
|
|
2759
|
-
|
|
2898
|
+
const o = f(e.id), r = f(e.editor), n = f(e.modelValue), {
|
|
2899
|
+
resolveEditorProps: s,
|
|
2900
|
+
resolveEditorType: a,
|
|
2901
|
+
getChangeFunctionName: l
|
|
2902
|
+
} = xe();
|
|
2903
|
+
function u(d, p) {
|
|
2904
|
+
n.value = p !== void 0 ? p : d, t.emit("update:modelValue", n.value), t.emit("change", n.value);
|
|
2760
2905
|
}
|
|
2761
|
-
const
|
|
2762
|
-
const
|
|
2763
|
-
|
|
2764
|
-
const y =
|
|
2765
|
-
return
|
|
2766
|
-
modelValue:
|
|
2767
|
-
"onUpdate:modelValue": (
|
|
2906
|
+
const i = B(() => {
|
|
2907
|
+
const d = a(r.value.type), p = s(r.value.type, r.value);
|
|
2908
|
+
p.focusOnCreated = e.focusOnCreated, p.selectOnCreated = e.selectOnCreated;
|
|
2909
|
+
const y = l(r.value.type);
|
|
2910
|
+
return p[y] = u, () => A(d, Z(p, {
|
|
2911
|
+
modelValue: n.value,
|
|
2912
|
+
"onUpdate:modelValue": (w) => n.value = w
|
|
2768
2913
|
}), null);
|
|
2769
2914
|
});
|
|
2770
|
-
return
|
|
2771
|
-
|
|
2772
|
-
}), () =>
|
|
2915
|
+
return I([() => e.id, () => e.editor, () => e.modelValue], ([d, p, y]) => {
|
|
2916
|
+
o.value = d, r.value = p, n.value = y;
|
|
2917
|
+
}), () => i.value();
|
|
2773
2918
|
}
|
|
2774
|
-
}),
|
|
2919
|
+
}), Vr = {
|
|
2775
2920
|
install(e) {
|
|
2776
|
-
e.component(
|
|
2921
|
+
e.component(ee.name, ee).component(oe.name, oe);
|
|
2777
2922
|
},
|
|
2778
|
-
register(e, t,
|
|
2779
|
-
e["form-group"] =
|
|
2923
|
+
register(e, t, o, r) {
|
|
2924
|
+
e["form-group"] = oe, t["form-group"] = fe, e["response-form"] = ee, t["response-form"] = me, e["form-input"] = wn, t["form-input"] = Cn, r["form-group"] = { editorResolver: ko };
|
|
2780
2925
|
},
|
|
2781
|
-
registerDesigner(e, t,
|
|
2782
|
-
e["form-group"] =
|
|
2926
|
+
registerDesigner(e, t, o) {
|
|
2927
|
+
e["form-group"] = vn, t["form-group"] = fe, e["response-form"] = $o, t["response-form"] = me;
|
|
2783
2928
|
}
|
|
2784
2929
|
};
|
|
2785
2930
|
export {
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2931
|
+
oe as FDynamicFormGroup,
|
|
2932
|
+
wn as FDynamicFormInput,
|
|
2933
|
+
ee as FResponseForm,
|
|
2934
|
+
Vr as default,
|
|
2935
|
+
J as dynamicFormGroupProps,
|
|
2936
|
+
ko as editorResolver,
|
|
2937
|
+
fe as formGroupPropsResolver,
|
|
2938
|
+
me as formPropsResolver,
|
|
2939
|
+
we as responseFormProps,
|
|
2940
|
+
Oo as useDesignerRules
|
|
2794
2941
|
};
|