@farris/ui-vue 1.3.1 → 1.3.4
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 +103 -99
- package/components/accordion/index.umd.cjs +1 -1
- package/components/avatar/index.esm.js +301 -351
- package/components/avatar/index.umd.cjs +1 -1
- package/components/binding-selector/index.esm.js +444 -0
- package/components/binding-selector/index.umd.cjs +1 -0
- package/components/binding-selector/package.json +8 -0
- package/components/border-editor/index.esm.js +5 -3
- package/components/border-editor/index.umd.cjs +1 -1
- package/components/button-edit/index.esm.js +143 -139
- package/components/button-edit/index.umd.cjs +1 -1
- package/components/calendar/index.esm.js +407 -396
- package/components/calendar/index.umd.cjs +1 -1
- package/components/capsule/index.esm.js +266 -255
- package/components/capsule/index.umd.cjs +1 -1
- package/components/checkbox/index.esm.js +628 -641
- package/components/checkbox/index.umd.cjs +1 -1
- package/components/color-picker/index.esm.js +379 -374
- package/components/color-picker/index.umd.cjs +2 -2
- package/components/combo-list/index.esm.js +471 -471
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/combo-tree/index.esm.js +155 -148
- package/components/combo-tree/index.umd.cjs +1 -1
- package/components/common/index.esm.js +487 -478
- package/components/common/index.umd.cjs +1 -1
- package/components/component/index.esm.js +330 -279
- package/components/component/index.umd.cjs +1 -1
- package/components/condition/index.esm.js +1175 -1280
- package/components/condition/index.umd.cjs +1 -1
- package/components/content-container/index.esm.js +220 -204
- package/components/content-container/index.umd.cjs +1 -1
- package/components/data-grid/index.esm.js +4658 -4555
- package/components/data-grid/index.umd.cjs +1 -1
- package/components/data-view/index.esm.js +2891 -2994
- package/components/data-view/index.umd.cjs +1 -1
- package/components/date-picker/index.esm.js +2375 -2590
- package/components/date-picker/index.umd.cjs +1 -1
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +9912 -1191
- package/components/designer-canvas/index.umd.cjs +1 -1
- package/components/designer-outline/index.esm.js +2 -1
- package/components/designer-outline/index.umd.cjs +1 -1
- package/components/drawer/index.esm.js +34 -38
- package/components/drawer/index.umd.cjs +1 -1
- package/components/dropdown/index.esm.js +149 -138
- package/components/dropdown/index.umd.cjs +2 -2
- package/components/dynamic-form/index.esm.js +1595 -1725
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +159 -151
- package/components/dynamic-resolver/index.umd.cjs +1 -1
- package/components/dynamic-view/index.esm.js +218 -218
- package/components/dynamic-view/index.umd.cjs +1 -1
- package/components/event-parameter/index.esm.js +355 -0
- package/components/event-parameter/index.umd.cjs +1 -0
- package/components/event-parameter/package.json +8 -0
- package/components/events-editor/index.css +1 -1
- package/components/events-editor/index.esm.js +622 -633
- package/components/events-editor/index.umd.cjs +1 -1
- package/components/expression-editor/index.esm.js +95 -91
- package/components/expression-editor/index.umd.cjs +1 -1
- package/components/external-container/index.esm.js +2079 -2178
- package/components/external-container/index.umd.cjs +1 -1
- package/components/field-selector/index.esm.js +3062 -3322
- package/components/field-selector/index.umd.cjs +1 -1
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +10581 -3225
- package/components/filter-bar/index.umd.cjs +1 -1
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +10182 -1327
- package/components/flow-canvas/index.umd.cjs +1 -1
- package/components/image-cropper/index.esm.js +353 -341
- package/components/image-cropper/index.umd.cjs +1 -1
- package/components/input-group/index.esm.js +510 -827
- package/components/input-group/index.umd.cjs +1 -1
- package/components/layout/index.esm.js +278 -268
- package/components/layout/index.umd.cjs +1 -1
- package/components/list-nav/index.esm.js +144 -136
- package/components/list-nav/index.umd.cjs +1 -1
- package/components/list-view/index.esm.js +1909 -2007
- package/components/list-view/index.umd.cjs +1 -1
- package/components/lookup/index.esm.js +6292 -6244
- package/components/lookup/index.umd.cjs +1 -1
- package/components/mapping-editor/index.esm.js +5165 -5062
- package/components/mapping-editor/index.umd.cjs +1 -1
- package/components/message-box/index.esm.js +252 -252
- package/components/message-box/index.umd.cjs +1 -1
- package/components/modal/index.esm.js +70 -70
- package/components/modal/index.umd.cjs +1 -1
- package/components/nav/index.esm.js +486 -984
- package/components/nav/index.umd.cjs +3 -3
- package/components/number-range/index.esm.js +446 -498
- package/components/number-range/index.umd.cjs +1 -1
- package/components/number-spinner/index.esm.js +363 -388
- package/components/number-spinner/index.umd.cjs +1 -1
- package/components/order/index.esm.js +1050 -1308
- package/components/order/index.umd.cjs +1 -1
- package/components/page-footer/index.esm.js +134 -131
- package/components/page-footer/index.umd.cjs +1 -1
- package/components/page-header/index.esm.js +1072 -1082
- package/components/page-header/index.umd.cjs +1 -1
- package/components/pagination/index.esm.js +412 -910
- package/components/pagination/index.umd.cjs +1 -1
- package/components/progress/index.esm.js +214 -203
- package/components/progress/index.umd.cjs +3 -3
- package/components/property-editor/index.esm.js +1361 -1536
- package/components/property-editor/index.umd.cjs +2 -2
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +650 -677
- package/components/property-panel/index.umd.cjs +1 -1
- package/components/query-solution/index.css +1 -1
- package/components/query-solution/index.esm.js +12607 -5080
- package/components/query-solution/index.umd.cjs +6 -1
- package/components/radio-button/index.esm.js +97 -97
- package/components/radio-button/index.umd.cjs +1 -1
- package/components/radio-group/index.css +1 -1
- package/components/radio-group/index.esm.js +1821 -565
- package/components/radio-group/index.umd.cjs +1 -1
- package/components/rate/index.esm.js +251 -244
- package/components/rate/index.umd.cjs +1 -1
- package/components/response-layout/index.esm.js +151 -140
- package/components/response-layout/index.umd.cjs +1 -1
- package/components/response-layout-editor/index.esm.js +707 -676
- package/components/response-layout-editor/index.umd.cjs +1 -1
- package/components/response-toolbar/index.esm.js +719 -740
- package/components/response-toolbar/index.umd.cjs +1 -1
- package/components/schema-selector/index.esm.js +5002 -5272
- package/components/schema-selector/index.umd.cjs +2 -2
- package/components/search-box/index.esm.js +145 -134
- package/components/search-box/index.umd.cjs +1 -1
- package/components/section/index.esm.js +2128 -427
- package/components/section/index.umd.cjs +1 -1
- package/components/smoke-detector/index.esm.js +141 -130
- package/components/smoke-detector/index.umd.cjs +1 -1
- package/components/splitter/index.esm.js +311 -301
- package/components/splitter/index.umd.cjs +1 -1
- package/components/step/index.esm.js +231 -220
- package/components/step/index.umd.cjs +1 -1
- package/components/switch/index.esm.js +385 -432
- package/components/switch/index.umd.cjs +1 -1
- package/components/tabs/index.esm.js +2223 -2203
- package/components/tabs/index.umd.cjs +1 -1
- package/components/tags/index.esm.js +351 -340
- package/components/tags/index.umd.cjs +1 -1
- package/components/text/index.esm.js +209 -199
- package/components/text/index.umd.cjs +1 -1
- package/components/textarea/index.esm.js +399 -421
- package/components/textarea/index.umd.cjs +1 -1
- package/components/time-picker/index.esm.js +619 -666
- package/components/time-picker/index.umd.cjs +1 -1
- package/components/transfer/index.esm.js +493 -486
- package/components/transfer/index.umd.cjs +1 -1
- package/components/tree-grid/index.esm.js +2992 -3101
- package/components/tree-grid/index.umd.cjs +1 -1
- package/components/tree-view/index.esm.js +2350 -2448
- package/components/tree-view/index.umd.cjs +1 -1
- package/components/uploader/index.esm.js +563 -554
- package/components/uploader/index.umd.cjs +2 -2
- package/components/verify-detail/index.esm.js +287 -276
- package/components/verify-detail/index.umd.cjs +1 -1
- package/components/video/index.esm.js +368 -324
- package/components/video/index.umd.cjs +1 -1
- package/components/weather/index.esm.js +498 -487
- package/components/weather/index.umd.cjs +5 -5
- package/farris.all.esm.js +46910 -42804
- package/farris.all.umd.cjs +14 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/binding-selector/index.d.ts +55 -0
- package/types/binding-selector/src/binding-selector.component.d.ts +11 -0
- package/types/binding-selector/src/binding-selector.props.d.ts +52 -0
- package/types/binding-selector/src/components/binding-selector-container.component.d.ts +13 -0
- package/types/binding-selector/src/composition/use-field-selection.d.ts +9 -0
- package/types/combo-list/src/components/list-container.component.d.ts +6 -6
- package/types/combo-list/src/components/list-container.props.d.ts +1 -1
- package/types/combo-tree/src/components/tree-container.component.d.ts +5 -5
- package/types/common/entity/entity-schema.d.ts +26 -11
- package/types/common/index.d.ts +1 -0
- package/types/common/types.d.ts +2 -2
- package/types/condition/src/condition-fields.design.component.d.ts +18 -0
- package/types/condition/src/types.d.ts +6 -6
- package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +20 -0
- package/types/data-grid/src/{designer/data-grid-column.props.d.ts → data-grid-column.props.d.ts} +1 -1
- package/types/data-grid/src/data-grid.props.d.ts +2 -2
- package/types/data-grid/src/designer/grid-field-editor.component.d.ts +14 -14
- package/types/data-grid/src/schema/schema-resolver.d.ts +1 -1
- package/types/data-view/composition/types.d.ts +2 -2
- package/types/date-picker/src/components/calendar/calendar.component.d.ts +3 -3
- package/types/date-picker/src/components/month/month.component.d.ts +3 -3
- package/types/date-picker/src/components/year/year.component.d.ts +3 -3
- package/types/designer-canvas/index.d.ts +2 -1
- package/types/designer-canvas/src/composition/dg-control.d.ts +5 -0
- package/types/designer-canvas/src/composition/function/drag-resolve.d.ts +5 -0
- package/types/designer-canvas/src/composition/types.d.ts +49 -40
- package/types/designer-canvas/src/types.d.ts +8 -20
- package/types/dynamic-form/index.d.ts +1 -1
- package/types/dynamic-form/src/designer/form-group-use-designer-rules.d.ts +2 -0
- package/types/dynamic-form/src/schema/{schema-resolver.d.ts → response-form-schema-resolver.d.ts} +1 -1
- package/types/dynamic-form/src/types.d.ts +1 -1
- package/types/dynamic-resolver/src/common/toolbar-resolver.d.ts +5 -0
- package/types/dynamic-resolver/src/converter/row-number.converter.d.ts +3 -0
- package/types/entity-binding-selector/composition/use-entity-tree.d.ts +18 -0
- package/types/entity-binding-selector/composition/use-field-tree.d.ts +28 -0
- package/types/entity-binding-selector/entity-binding-selector.component.d.ts +11 -0
- package/types/entity-binding-selector/entity-binding-selector.props.d.ts +3 -0
- package/types/enum-editor/src/components/enum-editor-container.component.d.ts +3 -3
- package/types/enum-editor/src/enum-editor.component.d.ts +3 -3
- package/types/event-parameter/index.d.ts +31 -0
- package/types/event-parameter/src/composition/type.d.ts +77 -0
- package/types/event-parameter/src/composition/use-editor-combotree.d.ts +3 -0
- package/types/event-parameter/src/composition/use-editor-input.d.ts +3 -0
- package/types/event-parameter/src/composition/use-editor-select.d.ts +3 -0
- package/types/event-parameter/src/composition/use-editor-switch.d.ts +3 -0
- package/types/event-parameter/src/composition/use-editor.d.ts +3 -0
- package/types/event-parameter/src/composition/use-general-editor.d.ts +26 -0
- package/types/event-parameter/src/event-parameter.component.d.ts +8 -0
- package/types/event-parameter/src/event-parameter.props.d.ts +34 -0
- package/types/events-editor/src/composition/types.d.ts +1 -1
- package/types/external-container/src/designer/import-external-schema.component.d.ts +1 -1
- package/types/field-selector/src/field-selector.component.d.ts +1 -2
- package/types/field-selector/src/field-selector.props.d.ts +0 -9
- package/types/input-group/src/designer/use-input-group-rules.d.ts +1 -2
- package/types/list-view/src/designer/list-view-table.design.component.d.ts +15 -0
- package/types/list-view/src/list-view-table.component.d.ts +15 -0
- package/types/lookup/src/composition/use-user-data.d.ts +2 -2
- package/types/lookup/src/property-config/lookup.property-config.d.ts +2 -6
- package/types/modal/src/composition/modal.service.d.ts +2 -1
- package/types/page-header/src/designer/page-header.design.component.d.ts +1 -1
- package/types/page-header/src/page-header.component.d.ts +1 -1
- package/types/property-panel/index.d.ts +2 -1
- package/types/property-panel/src/composition/entity/property-entity.d.ts +1 -1
- package/types/property-panel/src/composition/type.d.ts +0 -13
- package/types/query-solution/src/composition/types.d.ts +90 -4
- package/types/query-solution/src/composition/use-condition.d.ts +19 -0
- package/types/query-solution/src/composition/use-header.d.ts +21 -0
- package/types/query-solution/src/composition/{use-filter.d.ts → use-http.d.ts} +2 -2
- package/types/query-solution/src/composition/use-solution.d.ts +20 -0
- package/types/query-solution/src/designer/query-solution-config/composition/types.d.ts +18 -16
- package/types/query-solution/src/designer/query-solution-config/converter/query-solution-config-property.converter.d.ts +4 -0
- package/types/query-solution/src/designer/query-solution-config/query-solution-config.props.d.ts +14 -14
- package/types/query-solution/src/property-config/query-solution.property-config.d.ts +3 -51
- package/types/query-solution/src/query-solution.d.ts +10 -2
- package/types/radio-group/src/designer/item-collection-editor-inner.component.d.ts +29 -0
- package/types/radio-group/src/designer/item-collection-editor.component.d.ts +29 -0
- package/types/radio-group/src/designer/item-collection-editor.props.d.ts +21 -0
- package/types/radio-group/src/schema/schema-mapper.d.ts +1 -0
- package/types/radio-group/src/schema/schema-resolver.d.ts +1 -0
- package/types/response-toolbar/src/property-config/response-toolbar.property-config.d.ts +1 -0
- package/types/section/index.d.ts +15 -0
- package/types/section/src/designer/section-header.design.component.d.ts +4 -0
- package/types/section/src/designer/section-toolbar-item.props.d.ts +19 -0
- package/types/section/src/designer/section-toolbar.design.component.d.ts +3 -0
- package/types/section/src/property-config/section.property-config.d.ts +17 -17
- package/types/section/src/schema/schema-resolver.d.ts +1 -2
- package/types/section/src/schema/toolbar-resolver.d.ts +1 -1
- package/types/tabs/src/composition/types.d.ts +4 -1
- package/types/tabs/src/property-config/tab-page.property-config.d.ts +9 -59
- package/types/tabs/src/property-config/tabs.property-config.d.ts +8 -71
- package/types/tabs/src/schema/schema-resolver.d.ts +1 -2
- package/types/text/src/composition/types.d.ts +4 -4
- package/types/textarea/src/property-config/textarea.property-config.d.ts +23 -0
- package/types/weather/src/composition/use-weather-charts.d.ts +15 -0
- package/types/weather/src/composition/use-weather-color.d.ts +15 -0
- package/types/weather/src/composition/use-weather-data.d.ts +15 -0
- package/types/weather/src/composition/use-weather-format-number.d.ts +15 -0
- package/types/property-panel/src/composition/entity/use-input-rules.d.ts +0 -3
- package/types/tree-grid/src/schema/column-resolver.d.ts +0 -3
- package/types/weather/src/composition/types.d.ts +0 -2
- /package/types/dynamic-form/src/designer/{use-designer-rules.d.ts → response-form-use-designer-rules.d.ts} +0 -0
- /package/types/dynamic-form/src/property-config/{form.property-config.d.ts → response-form.property-config.d.ts} +0 -0
|
@@ -1,163 +1,169 @@
|
|
|
1
1
|
var kt = Object.defineProperty;
|
|
2
|
-
var
|
|
3
|
-
var N = (
|
|
4
|
-
import { defineComponent as
|
|
5
|
-
import { isPlainObject as
|
|
6
|
-
import { DgControl as
|
|
7
|
-
import "
|
|
8
|
-
import At, { useNumber as
|
|
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 An from "../
|
|
59
|
-
import
|
|
60
|
-
import
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import
|
|
64
|
-
import
|
|
65
|
-
import
|
|
66
|
-
import
|
|
2
|
+
var It = (t, e, n) => e in t ? kt(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
3
|
+
var N = (t, e, n) => It(t, typeof e != "symbol" ? e + "" : e, n);
|
|
4
|
+
import { defineComponent as X, ref as p, computed as S, createVNode as f, nextTick as ce, inject as ee, onMounted as J, withDirectives as Ae, resolveDirective as $e, watch as W, createTextVNode as Y, reactive as Z, Fragment as ae, mergeProps as te, onUnmounted as Ue, Teleport as Et, Transition as St, shallowRef as Lt, createApp as Dt, render as ge, h as Pt, cloneVNode as Vt } from "vue";
|
|
5
|
+
import { isPlainObject as De, cloneDeep as Te } from "lodash-es";
|
|
6
|
+
import { DgControl as Me, useDesignerComponent as Rt } from "../designer-canvas/index.esm.js";
|
|
7
|
+
import { useTextBox as Nt, useClear as je, useTextBoxDesign as Ot } from "../common/index.esm.js";
|
|
8
|
+
import At, { useNumber as $t, useFormat as Ut, useSpinner as jt, useTextBox as zt } from "../number-spinner/index.esm.js";
|
|
9
|
+
import qt from "../accordion/index.esm.js";
|
|
10
|
+
import Gt from "../avatar/index.esm.js";
|
|
11
|
+
import Wt from "../button-edit/index.esm.js";
|
|
12
|
+
import Ht from "../button-group/index.esm.js";
|
|
13
|
+
import Xt from "../calendar/index.esm.js";
|
|
14
|
+
import Yt from "../capsule/index.esm.js";
|
|
15
|
+
import Jt from "../checkbox/index.esm.js";
|
|
16
|
+
import oe from "../combo-list/index.esm.js";
|
|
17
|
+
import Qt from "../combo-tree/index.esm.js";
|
|
18
|
+
import Zt from "../component/index.esm.js";
|
|
19
|
+
import _t from "../color-picker/index.esm.js";
|
|
20
|
+
import Kt from "../content-container/index.esm.js";
|
|
21
|
+
import en from "../date-picker/index.esm.js";
|
|
22
|
+
import tn from "../data-grid/index.esm.js";
|
|
23
|
+
import nn from "../dropdown/index.esm.js";
|
|
24
|
+
import on from "../dynamic-form/index.esm.js";
|
|
25
|
+
import an from "../events-editor/index.esm.js";
|
|
26
|
+
import ln from "../filter-bar/index.esm.js";
|
|
27
|
+
import sn from "../field-selector/index.esm.js";
|
|
28
|
+
import rn from "../binding-selector/index.esm.js";
|
|
29
|
+
import un from "../image-cropper/index.esm.js";
|
|
30
|
+
import cn from "../input-group/index.esm.js";
|
|
31
|
+
import dn from "../layout/index.esm.js";
|
|
32
|
+
import pn from "../list-nav/index.esm.js";
|
|
33
|
+
import mn from "../list-view/index.esm.js";
|
|
34
|
+
import fn from "../lookup/index.esm.js";
|
|
35
|
+
import vn from "../mapping-editor/index.esm.js";
|
|
36
|
+
import hn from "../nav/index.esm.js";
|
|
37
|
+
import yn from "../number-range/index.esm.js";
|
|
38
|
+
import gn from "../order/index.esm.js";
|
|
39
|
+
import Cn from "../page-header/index.esm.js";
|
|
40
|
+
import bn from "../page-footer/index.esm.js";
|
|
41
|
+
import wn from "../pagination/index.esm.js";
|
|
42
|
+
import Mn from "../progress/index.esm.js";
|
|
43
|
+
import Fn from "../query-solution/index.esm.js";
|
|
44
|
+
import xn from "../radio-group/index.esm.js";
|
|
45
|
+
import Tn from "../rate/index.esm.js";
|
|
46
|
+
import Bn from "../response-toolbar/index.esm.js";
|
|
47
|
+
import kn from "../response-layout/index.esm.js";
|
|
48
|
+
import In from "../response-layout-editor/index.esm.js";
|
|
49
|
+
import En from "../search-box/index.esm.js";
|
|
50
|
+
import Sn from "../section/index.esm.js";
|
|
51
|
+
import Ln from "../smoke-detector/index.esm.js";
|
|
52
|
+
import Dn from "../splitter/index.esm.js";
|
|
53
|
+
import Pn from "../step/index.esm.js";
|
|
54
|
+
import Vn from "../switch/index.esm.js";
|
|
55
|
+
import Rn from "../tabs/index.esm.js";
|
|
56
|
+
import Nn from "../tags/index.esm.js";
|
|
57
|
+
import On from "../text/index.esm.js";
|
|
58
|
+
import An from "../time-picker/index.esm.js";
|
|
59
|
+
import $n from "../transfer/index.esm.js";
|
|
60
|
+
import Un from "../tree-view/index.esm.js";
|
|
61
|
+
import jn from "../uploader/index.esm.js";
|
|
62
|
+
import zn from "../verify-detail/index.esm.js";
|
|
63
|
+
import qn from "../weather/index.esm.js";
|
|
64
|
+
import Gn from "../video/index.esm.js";
|
|
65
|
+
import Wn from "../textarea/index.esm.js";
|
|
66
|
+
import Hn from "../schema-selector/index.esm.js";
|
|
67
|
+
import Xn from "../tree-grid/index.esm.js";
|
|
68
|
+
import Yn from "../event-parameter/index.esm.js";
|
|
67
69
|
import "../external-container/index.esm.js";
|
|
68
|
-
import { createPropsResolver as
|
|
69
|
-
const
|
|
70
|
-
function Be(
|
|
71
|
-
const { properties:
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
70
|
+
import { createPropsResolver as Jn } from "../dynamic-resolver/index.esm.js";
|
|
71
|
+
const ze = {}, qe = {};
|
|
72
|
+
function Be(t) {
|
|
73
|
+
const { properties: e, title: n, ignore: o } = t, a = o && Array.isArray(o), s = Object.keys(e).reduce((l, c) => ((!a || !o.find((u) => u === c)) && (l[c] = e[c].type === "object" && e[c].properties ? Be(e[c]) : Te(e[c].default)), l), {});
|
|
74
|
+
if (n && (!a || !o.find((l) => l === "id"))) {
|
|
75
|
+
const l = n.toLowerCase().replace(/-/g, "_");
|
|
76
|
+
s.id = `${l}_${Math.random().toString().slice(2, 6)}`;
|
|
77
|
+
}
|
|
78
|
+
return s;
|
|
79
|
+
}
|
|
80
|
+
function ke(t, e = {}, n) {
|
|
81
|
+
const o = ze[t];
|
|
76
82
|
if (o) {
|
|
77
83
|
let a = Be(o);
|
|
78
|
-
const s =
|
|
79
|
-
return a = s ? s({ getSchemaByType: ke }, a,
|
|
84
|
+
const s = qe[t];
|
|
85
|
+
return a = s ? s({ getSchemaByType: ke }, a, e, n) : a, a;
|
|
80
86
|
}
|
|
81
87
|
return null;
|
|
82
88
|
}
|
|
83
|
-
function
|
|
84
|
-
const n = Be(
|
|
85
|
-
return Object.keys(
|
|
89
|
+
function Qn(t, e) {
|
|
90
|
+
const n = Be(e);
|
|
91
|
+
return Object.keys(n).reduce((o, a) => (o[a] && De(o[a]) && De(t[a] || !t[a]) ? Object.assign(o[a], t[a] || {}) : o[a] = t[a], o), n), n;
|
|
86
92
|
}
|
|
87
|
-
function
|
|
88
|
-
return Object.keys(
|
|
89
|
-
if (
|
|
90
|
-
const s =
|
|
93
|
+
function Zn(t, e) {
|
|
94
|
+
return Object.keys(t).filter((o) => t[o] != null).reduce((o, a) => {
|
|
95
|
+
if (e.has(a)) {
|
|
96
|
+
const s = e.get(a);
|
|
91
97
|
if (typeof s == "string")
|
|
92
|
-
o[s] =
|
|
98
|
+
o[s] = t[a];
|
|
93
99
|
else {
|
|
94
|
-
const l = s(a,
|
|
100
|
+
const l = s(a, t[a], t);
|
|
95
101
|
Object.assign(o, l);
|
|
96
102
|
}
|
|
97
103
|
} else
|
|
98
|
-
o[a] =
|
|
104
|
+
o[a] = t[a];
|
|
99
105
|
return o;
|
|
100
106
|
}, {});
|
|
101
107
|
}
|
|
102
|
-
function
|
|
103
|
-
const o =
|
|
104
|
-
return
|
|
108
|
+
function _n(t, e, n = /* @__PURE__ */ new Map()) {
|
|
109
|
+
const o = Qn(t, e);
|
|
110
|
+
return Zn(o, n);
|
|
105
111
|
}
|
|
106
|
-
function
|
|
107
|
-
function
|
|
108
|
-
if (typeof
|
|
109
|
-
return m[
|
|
110
|
-
if (typeof
|
|
111
|
-
const h = Object.keys(
|
|
112
|
+
function Kn(t = {}) {
|
|
113
|
+
function e(i, d, r, m) {
|
|
114
|
+
if (typeof r == "number")
|
|
115
|
+
return m[i].length === r;
|
|
116
|
+
if (typeof r == "object") {
|
|
117
|
+
const h = Object.keys(r)[0], v = r[h];
|
|
112
118
|
if (h === "not")
|
|
113
|
-
return Number(m[
|
|
119
|
+
return Number(m[i].length) !== Number(v);
|
|
114
120
|
if (h === "moreThan")
|
|
115
|
-
return Number(m[
|
|
121
|
+
return Number(m[i].length) >= Number(v);
|
|
116
122
|
if (h === "lessThan")
|
|
117
|
-
return Number(m[
|
|
123
|
+
return Number(m[i].length) <= Number(v);
|
|
118
124
|
}
|
|
119
125
|
return !1;
|
|
120
126
|
}
|
|
121
|
-
function n(
|
|
122
|
-
return m[
|
|
127
|
+
function n(i, d, r, m) {
|
|
128
|
+
return m[i] && m[i].propertyValue && String(m[i].propertyValue.value) === String(r);
|
|
123
129
|
}
|
|
124
130
|
const o = /* @__PURE__ */ new Map([
|
|
125
|
-
["length",
|
|
131
|
+
["length", e],
|
|
126
132
|
["getProperty", n]
|
|
127
133
|
]);
|
|
128
|
-
Object.keys(
|
|
129
|
-
function a(
|
|
130
|
-
const
|
|
131
|
-
return typeof
|
|
134
|
+
Object.keys(t).reduce((i, d) => (i.set(d, t[d]), i), o);
|
|
135
|
+
function a(i, d) {
|
|
136
|
+
const r = i;
|
|
137
|
+
return typeof d == "number" ? [{ target: r, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: r, operator: "getProperty", param: i, value: !!d }] : typeof d == "object" ? Object.keys(d).map((m) => {
|
|
132
138
|
if (m === "length")
|
|
133
|
-
return { target:
|
|
134
|
-
const h = m,
|
|
135
|
-
return { target:
|
|
139
|
+
return { target: r, operator: "length", param: null, value: d[m] };
|
|
140
|
+
const h = m, v = d[m];
|
|
141
|
+
return { target: r, operator: "getProperty", param: h, value: v };
|
|
136
142
|
}) : [];
|
|
137
143
|
}
|
|
138
|
-
function s(
|
|
139
|
-
return Object.keys(
|
|
140
|
-
const h = a(m,
|
|
141
|
-
return
|
|
144
|
+
function s(i) {
|
|
145
|
+
return Object.keys(i).reduce((r, m) => {
|
|
146
|
+
const h = a(m, i[m]);
|
|
147
|
+
return r.push(...h), r;
|
|
142
148
|
}, []);
|
|
143
149
|
}
|
|
144
|
-
function l(
|
|
145
|
-
if (o.has(
|
|
146
|
-
const
|
|
147
|
-
return
|
|
150
|
+
function l(i, d) {
|
|
151
|
+
if (o.has(i.operator)) {
|
|
152
|
+
const r = o.get(i.operator);
|
|
153
|
+
return r && r(i.target, i.param, i.value, d) || !1;
|
|
148
154
|
}
|
|
149
155
|
return !1;
|
|
150
156
|
}
|
|
151
|
-
function c(
|
|
152
|
-
return s(
|
|
157
|
+
function c(i, d) {
|
|
158
|
+
return s(i).reduce((h, v) => h && l(v, d), !0);
|
|
153
159
|
}
|
|
154
|
-
function u(
|
|
155
|
-
const
|
|
156
|
-
return m ? !
|
|
160
|
+
function u(i, d) {
|
|
161
|
+
const r = Object.keys(i), m = r.includes("allOf"), h = r.includes("anyOf"), v = m || h, M = (v ? i[v ? m ? "allOf" : "anyOf" : "allOf"] : [i]).map((R) => c(R, d));
|
|
162
|
+
return m ? !M.includes(!1) : M.includes(!0);
|
|
157
163
|
}
|
|
158
164
|
return { parseValueSchema: u };
|
|
159
165
|
}
|
|
160
|
-
const
|
|
166
|
+
const V = {
|
|
161
167
|
button: { type: "button", name: "按钮", icon: "Button" },
|
|
162
168
|
"response-toolbar": { type: "response-toolbar", name: "工具栏", icon: "ButtonGroup" },
|
|
163
169
|
"response-toolbar-item": { type: "response-toolbar-item", name: "按钮", icon: "Button" },
|
|
@@ -195,59 +201,60 @@ const A = {
|
|
|
195
201
|
"page-header": { type: "page-header", name: "页头", icon: "Header" },
|
|
196
202
|
"page-footer": { type: "page-footer", name: "页脚", icon: "ModalFooter" },
|
|
197
203
|
"tab-toolbar": { type: "tab-toolbar", name: "标签页工具栏", icon: "TabToolbar" },
|
|
198
|
-
fieldset: { type: "fieldset", name: "分组", icon: "fieldset" }
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
+
fieldset: { type: "fieldset", name: "分组", icon: "fieldset" },
|
|
205
|
+
"query-solution": { type: "query-solution", name: "筛选方案", icon: "QueryScheme" }
|
|
206
|
+
}, Ge = {}, eo = {};
|
|
207
|
+
Kn();
|
|
208
|
+
function pe(t, e, n = /* @__PURE__ */ new Map(), o = (l, c, u, i) => c, a = {}, s = (l) => l) {
|
|
209
|
+
return ze[e.title] = e, qe[e.title] = o, Ge[e.title] = a, eo[e.title] = s, (l = {}) => {
|
|
210
|
+
const c = _n(l, e, n), u = Object.keys(t).reduce((i, d) => (i[d] = t[d].default, i), {});
|
|
204
211
|
return Object.assign(u, c);
|
|
205
212
|
};
|
|
206
213
|
}
|
|
207
|
-
function We(
|
|
208
|
-
return { customClass:
|
|
214
|
+
function We(t, e) {
|
|
215
|
+
return { customClass: e.class, customStyle: e.style };
|
|
209
216
|
}
|
|
210
|
-
function
|
|
211
|
-
function e
|
|
212
|
-
return
|
|
217
|
+
function to() {
|
|
218
|
+
function t(e) {
|
|
219
|
+
return e.editor;
|
|
213
220
|
}
|
|
214
221
|
return {
|
|
215
|
-
resolve:
|
|
222
|
+
resolve: t
|
|
216
223
|
};
|
|
217
224
|
}
|
|
218
|
-
const
|
|
225
|
+
const Ie = /* @__PURE__ */ new Map([
|
|
219
226
|
["appearance", We]
|
|
220
|
-
]),
|
|
221
|
-
var
|
|
222
|
-
const
|
|
223
|
-
class
|
|
224
|
-
constructor(
|
|
227
|
+
]), no = /* @__PURE__ */ new Map([]);
|
|
228
|
+
var Fe = /* @__PURE__ */ ((t) => (t.String = "String", t.DateTime = "DateTime", t.Date = "Date", t.Enum = "Enum", t.Boolean = "Boolean", t.Number = "Number", t.Text = "Text", t.BigNumber = "BigNumber", t))(Fe || {});
|
|
229
|
+
const oo = "root-viewmodel";
|
|
230
|
+
class ao {
|
|
231
|
+
constructor(e, n) {
|
|
225
232
|
N(this, "formSchemaUtils");
|
|
226
233
|
N(this, "controlCreatorUtils");
|
|
227
234
|
N(this, "designViewModelUtils");
|
|
228
|
-
this.resolver =
|
|
235
|
+
this.resolver = e, this.designerHostService = n, this.formSchemaUtils = this.designerHostService.formSchemaUtils, this.controlCreatorUtils = this.designerHostService.controlCreatorUtils, this.designViewModelUtils = this.designerHostService.designViewModelUtils;
|
|
229
236
|
}
|
|
230
|
-
createComponent(
|
|
231
|
-
const n = this.createComponentRefNode(
|
|
237
|
+
createComponent(e) {
|
|
238
|
+
const n = this.createComponentRefNode(e), o = this.createComponentNode(e), a = this.createViewModeNode(e), s = this.formSchemaUtils.getFormSchema();
|
|
232
239
|
return s.module.viewmodels.push(a), s.module.components.push(o), this.designViewModelUtils.assembleDesignViewModel(), n;
|
|
233
240
|
}
|
|
234
|
-
createComponentRefNode(
|
|
241
|
+
createComponentRefNode(e) {
|
|
235
242
|
const n = this.resolver.getSchemaByType("component-ref");
|
|
236
243
|
return Object.assign(n, {
|
|
237
|
-
id: `${
|
|
238
|
-
component: `${
|
|
244
|
+
id: `${e.componentId}-component-ref`,
|
|
245
|
+
component: `${e.componentId}-component`
|
|
239
246
|
}), n;
|
|
240
247
|
}
|
|
241
|
-
createComponentNode(
|
|
242
|
-
const n = this.resolver.getSchemaByType("component"), o = this.createFormComponentContents(
|
|
248
|
+
createComponentNode(e) {
|
|
249
|
+
const n = this.resolver.getSchemaByType("component"), o = this.createFormComponentContents(e);
|
|
243
250
|
return Object.assign(n, {
|
|
244
|
-
id: `${
|
|
245
|
-
viewModel: `${
|
|
246
|
-
componentType:
|
|
251
|
+
id: `${e.componentId}-component`,
|
|
252
|
+
viewModel: `${e.componentId}-component-viewmodel`,
|
|
253
|
+
componentType: e.componentType,
|
|
247
254
|
appearance: {
|
|
248
255
|
class: this.getFormComponentClass()
|
|
249
256
|
},
|
|
250
|
-
formColumns:
|
|
257
|
+
formColumns: e.formColumns,
|
|
251
258
|
contents: o
|
|
252
259
|
}), n;
|
|
253
260
|
}
|
|
@@ -255,34 +262,37 @@ class _n {
|
|
|
255
262
|
* 获取卡片组件层级的class样式
|
|
256
263
|
*/
|
|
257
264
|
getFormComponentClass() {
|
|
258
|
-
|
|
265
|
+
const { templateId: e } = this.formSchemaUtils.getFormSchema().module;
|
|
266
|
+
return e === "double-list-in-tab-template" ? "f-struct-wrapper f-utils-fill-flex-column" : "f-struct-wrapper";
|
|
259
267
|
}
|
|
260
|
-
createFormComponentContents(
|
|
268
|
+
createFormComponentContents(e) {
|
|
261
269
|
const n = this.resolver.getSchemaByType("section");
|
|
262
270
|
Object.assign(n, {
|
|
263
|
-
id:
|
|
271
|
+
id: e.componentId + "-form-section",
|
|
264
272
|
appearance: {
|
|
265
273
|
class: "f-section-form f-section-in-mainsubcard"
|
|
266
274
|
},
|
|
267
|
-
mainTitle:
|
|
275
|
+
mainTitle: e.componentName
|
|
268
276
|
});
|
|
269
277
|
const o = this.resolver.getSchemaByType("response-form"), a = [];
|
|
270
278
|
Object.assign(o, {
|
|
271
|
-
id:
|
|
279
|
+
id: e.componentId + "-form",
|
|
272
280
|
appearance: {
|
|
273
281
|
class: "f-form-layout farris-form farris-form-controls-inline"
|
|
274
282
|
},
|
|
275
283
|
contents: a
|
|
276
284
|
}), n.contents = [o];
|
|
277
|
-
const { selectedFields: s } =
|
|
278
|
-
|
|
279
|
-
const u =
|
|
280
|
-
|
|
281
|
-
})
|
|
285
|
+
const { selectedFields: s } = e;
|
|
286
|
+
s == null || s.forEach((c) => {
|
|
287
|
+
const u = Te(c), i = this.resolveControlClassByFormColumns(e), d = this.controlCreatorUtils.setFormFieldProperty(u, "", i);
|
|
288
|
+
d && a.push(d);
|
|
289
|
+
});
|
|
290
|
+
const { templateId: l } = this.formSchemaUtils.getFormSchema().module;
|
|
291
|
+
return l === "double-list-in-tab-template" && (n.appearance.class = "f-section-grid f-section-in-main px-0 pt-0", n.fill = !0), [n];
|
|
282
292
|
}
|
|
283
|
-
resolveControlClassByFormColumns(
|
|
293
|
+
resolveControlClassByFormColumns(e) {
|
|
284
294
|
let n = "";
|
|
285
|
-
switch (
|
|
295
|
+
switch (e.formColumns) {
|
|
286
296
|
case 1: {
|
|
287
297
|
n = "col-12";
|
|
288
298
|
break;
|
|
@@ -305,31 +315,28 @@ class _n {
|
|
|
305
315
|
/**
|
|
306
316
|
* 添加viewModel节点
|
|
307
317
|
*/
|
|
308
|
-
createViewModeNode(
|
|
318
|
+
createViewModeNode(e) {
|
|
309
319
|
return {
|
|
310
|
-
id: `${
|
|
311
|
-
code: `${
|
|
312
|
-
name:
|
|
313
|
-
bindTo:
|
|
314
|
-
parent:
|
|
315
|
-
fields: this.assembleViewModelFields(
|
|
320
|
+
id: `${e.componentId}-component-viewmodel`,
|
|
321
|
+
code: `${e.componentId}-component-viewmodel`,
|
|
322
|
+
name: e.componentName,
|
|
323
|
+
bindTo: e.bindTo,
|
|
324
|
+
parent: oo,
|
|
325
|
+
fields: this.assembleViewModelFields(e),
|
|
316
326
|
commands: [],
|
|
317
327
|
states: [],
|
|
318
|
-
enableValidation: !0
|
|
319
|
-
pagination: {
|
|
320
|
-
enable: !1
|
|
321
|
-
}
|
|
328
|
+
enableValidation: !0
|
|
322
329
|
};
|
|
323
330
|
}
|
|
324
331
|
/**
|
|
325
332
|
* 组装viewModel fields 节点
|
|
326
333
|
*/
|
|
327
|
-
assembleViewModelFields(
|
|
328
|
-
const n = [], { selectedFields: o } =
|
|
334
|
+
assembleViewModelFields(e) {
|
|
335
|
+
const n = [], { selectedFields: o } = e;
|
|
329
336
|
return o == null || o.forEach((a) => {
|
|
330
337
|
let s = "blur";
|
|
331
338
|
const l = a.type.name;
|
|
332
|
-
(l ===
|
|
339
|
+
(l === Fe.Enum || l === Fe.Boolean) && (s = "change"), n.push({
|
|
333
340
|
type: "Form",
|
|
334
341
|
id: a.id,
|
|
335
342
|
fieldName: a.bindingField,
|
|
@@ -341,26 +348,27 @@ class _n {
|
|
|
341
348
|
}), n;
|
|
342
349
|
}
|
|
343
350
|
}
|
|
344
|
-
function
|
|
345
|
-
var s;
|
|
351
|
+
function lo(t, e, n, o) {
|
|
352
|
+
var s, l, c, u, i;
|
|
346
353
|
const a = n.parentComponentInstance;
|
|
347
|
-
if (a) {
|
|
348
|
-
const
|
|
354
|
+
if (a && o) {
|
|
355
|
+
const d = (s = a.schema) == null ? void 0 : s.type, m = {
|
|
349
356
|
componentId: `form-${Math.random().toString(36).slice(2, 6)}`,
|
|
350
|
-
componentName: "标题",
|
|
357
|
+
componentName: ((c = (l = n.bindingSourceContext) == null ? void 0 : l.bindingEntity) == null ? void 0 : c.name) || "标题",
|
|
351
358
|
componentType: "form",
|
|
352
|
-
formColumns:
|
|
359
|
+
formColumns: d === "splitter-pane" ? 1 : 4,
|
|
353
360
|
parentContainerId: a.schema.id,
|
|
354
|
-
bindTo: "/"
|
|
361
|
+
bindTo: ((u = n.bindingSourceContext) == null ? void 0 : u.bindTo) || "/",
|
|
362
|
+
selectedFields: (i = n.bindingSourceContext) == null ? void 0 : i.bindingEntityFields
|
|
355
363
|
};
|
|
356
|
-
return new
|
|
364
|
+
return new ao(t, o).createComponent(m);
|
|
357
365
|
} else
|
|
358
|
-
return
|
|
366
|
+
return e;
|
|
359
367
|
}
|
|
360
|
-
function
|
|
361
|
-
return
|
|
368
|
+
function so(t, e, n) {
|
|
369
|
+
return e;
|
|
362
370
|
}
|
|
363
|
-
const
|
|
371
|
+
const ro = "https://json-schema.org/draft/2020-12/schema", io = "https://farris-design.gitee.io/response-form.schema.json", uo = "response-form", co = "A Farris Data Collection Component", po = "object", mo = {
|
|
364
372
|
id: {
|
|
365
373
|
description: "The unique identifier for a form group",
|
|
366
374
|
type: "string"
|
|
@@ -388,36 +396,38 @@ const no = "https://json-schema.org/draft/2020-12/schema", oo = "https://farris-
|
|
|
388
396
|
type: "array",
|
|
389
397
|
default: []
|
|
390
398
|
}
|
|
391
|
-
},
|
|
399
|
+
}, fo = [
|
|
392
400
|
"id",
|
|
393
401
|
"type"
|
|
394
|
-
],
|
|
395
|
-
$schema:
|
|
396
|
-
$id:
|
|
397
|
-
title:
|
|
398
|
-
description:
|
|
399
|
-
type:
|
|
400
|
-
properties:
|
|
401
|
-
required:
|
|
402
|
+
], vo = {
|
|
403
|
+
$schema: ro,
|
|
404
|
+
$id: io,
|
|
405
|
+
title: uo,
|
|
406
|
+
description: co,
|
|
407
|
+
type: po,
|
|
408
|
+
properties: mo,
|
|
409
|
+
required: fo
|
|
402
410
|
}, He = {
|
|
403
|
-
customClass: { type: String, default: "" }
|
|
404
|
-
|
|
411
|
+
customClass: { type: String, default: "" },
|
|
412
|
+
customStyle: { type: String, defaut: "" }
|
|
413
|
+
}, Pe = pe(He, vo, Ie, lo), Ce = /* @__PURE__ */ X({
|
|
405
414
|
name: "FResponseForm",
|
|
406
415
|
props: He,
|
|
407
416
|
emits: [],
|
|
408
|
-
setup(
|
|
409
|
-
const n =
|
|
410
|
-
const a =
|
|
417
|
+
setup(t, e) {
|
|
418
|
+
const n = p(), o = S(() => {
|
|
419
|
+
const a = t.customClass.split(" "), s = {
|
|
411
420
|
"drag-container": !0
|
|
412
421
|
};
|
|
413
422
|
return a.reduce((l, c) => (l[c] = !0, l), s), s;
|
|
414
423
|
});
|
|
415
424
|
return () => f("div", {
|
|
416
425
|
ref: n,
|
|
417
|
-
class: o.value
|
|
418
|
-
|
|
426
|
+
class: o.value,
|
|
427
|
+
style: t.customStyle
|
|
428
|
+
}, [e.slots.default && e.slots.default()]);
|
|
419
429
|
}
|
|
420
|
-
}),
|
|
430
|
+
}), ho = "https://json-schema.org/draft/2020-12/schema", yo = "https://farris-design.gitee.io/form-group.schema.json", go = "form-group", Co = "A Farris Input Component", bo = "object", wo = {
|
|
421
431
|
id: {
|
|
422
432
|
description: "The unique identifier for a form group",
|
|
423
433
|
type: "string"
|
|
@@ -457,21 +467,27 @@ const no = "https://json-schema.org/draft/2020-12/schema", oo = "https://farris-
|
|
|
457
467
|
lableWidth: {
|
|
458
468
|
description: "",
|
|
459
469
|
type: "number"
|
|
470
|
+
},
|
|
471
|
+
binding: {
|
|
472
|
+
description: "",
|
|
473
|
+
type: "object",
|
|
474
|
+
default: {}
|
|
460
475
|
}
|
|
461
|
-
},
|
|
476
|
+
}, Mo = [
|
|
462
477
|
"id",
|
|
463
478
|
"type"
|
|
464
479
|
], Xe = {
|
|
465
|
-
$schema:
|
|
466
|
-
$id:
|
|
467
|
-
title:
|
|
468
|
-
description:
|
|
469
|
-
type:
|
|
470
|
-
properties:
|
|
471
|
-
required:
|
|
472
|
-
},
|
|
480
|
+
$schema: ho,
|
|
481
|
+
$id: yo,
|
|
482
|
+
title: go,
|
|
483
|
+
description: Co,
|
|
484
|
+
type: bo,
|
|
485
|
+
properties: wo,
|
|
486
|
+
required: Mo
|
|
487
|
+
}, le = {
|
|
473
488
|
id: { type: String, default: "" },
|
|
474
489
|
customClass: { type: String, default: "" },
|
|
490
|
+
customStyle: { type: String, default: "" },
|
|
475
491
|
/** 筛选组件配置器,具体配置项可查看各组件文档 */
|
|
476
492
|
editor: { type: Object, default: {} },
|
|
477
493
|
label: { type: String, default: "" },
|
|
@@ -482,138 +498,143 @@ const no = "https://json-schema.org/draft/2020-12/schema", oo = "https://farris-
|
|
|
482
498
|
required: { type: Boolean, default: !1 },
|
|
483
499
|
showLabel: { type: Boolean, default: !0 },
|
|
484
500
|
type: { type: String, default: "input-group" }
|
|
485
|
-
},
|
|
486
|
-
|
|
501
|
+
}, Ve = pe(
|
|
502
|
+
le,
|
|
487
503
|
Xe,
|
|
488
|
-
|
|
504
|
+
Ie,
|
|
489
505
|
void 0
|
|
490
|
-
),
|
|
491
|
-
function
|
|
492
|
-
var
|
|
493
|
-
|
|
494
|
-
|
|
506
|
+
), Fo = to();
|
|
507
|
+
function Ye(t, e, n) {
|
|
508
|
+
var w;
|
|
509
|
+
const o = n && n.getStyles && n.getStyles() || "", a = n && n.getDesignerClass && n.getDesignerClass() || "", s = p();
|
|
510
|
+
function l() {
|
|
511
|
+
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
|
|
495
512
|
}
|
|
496
|
-
o();
|
|
497
|
-
const a = n && n.getStyles && n.getStyles() || "", s = n && n.getDesignerClass && n.getDesignerClass() || "", l = d();
|
|
498
513
|
function c() {
|
|
499
|
-
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : n && n.checkCanMoveComponent ? n.checkCanMoveComponent() : !0;
|
|
500
|
-
}
|
|
501
|
-
function u() {
|
|
502
514
|
return !1;
|
|
503
515
|
}
|
|
504
|
-
function
|
|
505
|
-
return (
|
|
516
|
+
function u() {
|
|
517
|
+
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : n && n.checkCanDeleteComponent ? n.checkCanDeleteComponent() : !0;
|
|
506
518
|
}
|
|
507
|
-
function
|
|
508
|
-
return (
|
|
519
|
+
function i() {
|
|
520
|
+
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !0 : n && n.hideNestedPaddingInDesginerView ? n.hideNestedPaddingInDesginerView() : !1;
|
|
509
521
|
}
|
|
510
|
-
function
|
|
511
|
-
if (!
|
|
522
|
+
function d(g) {
|
|
523
|
+
if (!g || !g.value)
|
|
512
524
|
return null;
|
|
513
|
-
if (
|
|
514
|
-
return
|
|
515
|
-
const
|
|
516
|
-
return
|
|
525
|
+
if (g.value.schema && g.value.schema.type === "component")
|
|
526
|
+
return g.value;
|
|
527
|
+
const L = p(g == null ? void 0 : g.value.parent), y = d(L);
|
|
528
|
+
return y || null;
|
|
517
529
|
}
|
|
518
|
-
function
|
|
519
|
-
const { componentInstance:
|
|
520
|
-
return !
|
|
530
|
+
function r(g = e) {
|
|
531
|
+
const { componentInstance: L, designerItemElementRef: y } = g;
|
|
532
|
+
return !L || !L.value ? null : L.value.canMove ? y : r(g.parent);
|
|
521
533
|
}
|
|
522
|
-
function
|
|
523
|
-
return !!n && n.canAccepts(
|
|
534
|
+
function m(g) {
|
|
535
|
+
return !!n && n.canAccepts(g);
|
|
524
536
|
}
|
|
525
|
-
function
|
|
526
|
-
return (
|
|
537
|
+
function h() {
|
|
538
|
+
return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
|
|
527
539
|
}
|
|
528
|
-
function
|
|
540
|
+
function v() {
|
|
529
541
|
}
|
|
530
|
-
function
|
|
531
|
-
|
|
542
|
+
function b(g, L) {
|
|
543
|
+
L && n != null && n.onAcceptMovedChildElement && n.onAcceptMovedChildElement(L);
|
|
532
544
|
}
|
|
533
|
-
function
|
|
534
|
-
const { componentType:
|
|
535
|
-
let
|
|
536
|
-
n && n.onResolveNewComponentSchema && (
|
|
537
|
-
const
|
|
538
|
-
return
|
|
545
|
+
function F(g, L) {
|
|
546
|
+
const { componentType: y } = g;
|
|
547
|
+
let P = ke(y, g, L);
|
|
548
|
+
n && n.onResolveNewComponentSchema && (P = n.onResolveNewComponentSchema(g, P));
|
|
549
|
+
const O = y.toLowerCase().replace(/-/g, "_");
|
|
550
|
+
return P && !P.id && P.type === y && (P.id = `${O}_${Math.random().toString().slice(2, 6)}`), P;
|
|
539
551
|
}
|
|
540
|
-
function
|
|
552
|
+
function M(g) {
|
|
541
553
|
}
|
|
542
|
-
function
|
|
554
|
+
function C(...g) {
|
|
543
555
|
if (n && n.getPropsConfig)
|
|
544
|
-
return n.getPropsConfig(...
|
|
545
|
-
}
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
556
|
+
return n.getPropsConfig(...g);
|
|
557
|
+
}
|
|
558
|
+
function R() {
|
|
559
|
+
n && n.onRemoveComponent && n.onRemoveComponent(), e != null && e.schema.contents && e.schema.contents.map((g) => {
|
|
560
|
+
var P;
|
|
561
|
+
let L = g.id;
|
|
562
|
+
g.type === "component-ref" && (L = g.component);
|
|
563
|
+
const y = t.value.querySelector(`#${L}-design-item`);
|
|
564
|
+
(P = y == null ? void 0 : y.componentInstance) != null && P.value.onRemoveComponent && y.componentInstance.value.onRemoveComponent();
|
|
565
|
+
});
|
|
566
|
+
}
|
|
567
|
+
return s.value = {
|
|
568
|
+
canMove: l(),
|
|
569
|
+
canSelectParent: c(),
|
|
570
|
+
canDelete: u(),
|
|
571
|
+
canNested: !i(),
|
|
572
|
+
contents: e == null ? void 0 : e.schema.contents,
|
|
573
|
+
elementRef: t,
|
|
574
|
+
parent: (w = e == null ? void 0 : e.parent) == null ? void 0 : w.componentInstance,
|
|
575
|
+
schema: e == null ? void 0 : e.schema,
|
|
576
|
+
styles: o,
|
|
577
|
+
designerClass: a,
|
|
578
|
+
canAccepts: m,
|
|
579
|
+
getBelongedComponentInstance: d,
|
|
580
|
+
getDraggableDesignItemElement: r,
|
|
581
|
+
getDraggingDisplayText: h,
|
|
582
|
+
getPropConfig: C,
|
|
583
|
+
getDragScopeElement: v,
|
|
584
|
+
onAcceptMovedChildElement: b,
|
|
585
|
+
onChildElementMovedOut: M,
|
|
586
|
+
addNewChildComponentSchema: F,
|
|
587
|
+
triggerBelongedComponentToMoveWhenMoved: !!n && n.triggerBelongedComponentToMoveWhenMoved || p(!1),
|
|
588
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!n && n.triggerBelongedComponentToDeleteWhenDeleted || p(!1),
|
|
589
|
+
onRemoveComponent: R
|
|
590
|
+
}, s;
|
|
591
|
+
}
|
|
592
|
+
function xo() {
|
|
593
|
+
function t(e, n) {
|
|
573
594
|
var l;
|
|
574
|
-
if (!
|
|
595
|
+
if (!e)
|
|
575
596
|
return !1;
|
|
576
|
-
const o = ((l =
|
|
597
|
+
const o = ((l = e.targetContainer) == null ? void 0 : l.componentInstance) && e.targetContainer.componentInstance.value;
|
|
577
598
|
if (!o)
|
|
578
599
|
return !1;
|
|
579
600
|
const a = o.schema.type, s = n == null ? void 0 : n.formSchemaUtils.getComponentById(o.belongedComponentId);
|
|
580
|
-
return !((
|
|
601
|
+
return !((e.componentCategory === "input" || e.componentType === "form-group") && ![V["response-layout-item"].type, V["response-form"].type].includes(a) || (e.componentType === V.tabs.type || e.componentType === V.section.type) && ((s == null ? void 0 : s.componentType) !== "frame" || ![V["content-container"].type, V["splitter-pane"].type, V["response-layout-item"].type].includes(a)));
|
|
581
602
|
}
|
|
582
603
|
return {
|
|
583
|
-
basalDragulaRuleForContainer:
|
|
604
|
+
basalDragulaRuleForContainer: t
|
|
584
605
|
};
|
|
585
606
|
}
|
|
586
|
-
class
|
|
587
|
-
getTemplateRule(
|
|
607
|
+
class To {
|
|
608
|
+
getTemplateRule(e, n) {
|
|
588
609
|
const o = n == null ? void 0 : n.formSchemaUtils, a = o == null ? void 0 : o.getFormTemplateRule(), s = { canAccept: !0, canDelete: !0, canMove: !0 };
|
|
589
610
|
if (!a)
|
|
590
611
|
return s;
|
|
591
|
-
const l = this.getComponentContext(
|
|
592
|
-
return
|
|
612
|
+
const l = this.getComponentContext(e), { componentClassList: c } = l;
|
|
613
|
+
return c.forEach((u) => {
|
|
593
614
|
if (!u || !a[u])
|
|
594
615
|
return;
|
|
595
|
-
const { canMove:
|
|
596
|
-
s.canMove = s.canMove && this.resolveRuleValue(
|
|
616
|
+
const { canMove: i, canDelete: d, canAccept: r } = a[u];
|
|
617
|
+
s.canMove = s.canMove && this.resolveRuleValue(i, l), s.canDelete = s.canDelete && this.resolveRuleValue(d, l), s.canAccept = s.canAccept && this.resolveRuleValue(r, l);
|
|
597
618
|
}), s;
|
|
598
619
|
}
|
|
599
|
-
resolveRuleValue(
|
|
600
|
-
return typeof
|
|
620
|
+
resolveRuleValue(e, n) {
|
|
621
|
+
return typeof e == "boolean" ? e : this.parseRuleValueSchema(e, n);
|
|
601
622
|
}
|
|
602
|
-
parseRuleValueSchema(
|
|
603
|
-
const o =
|
|
623
|
+
parseRuleValueSchema(e, n) {
|
|
624
|
+
const o = e.invalidContext || [];
|
|
604
625
|
let a = !0;
|
|
605
626
|
for (const s of o) {
|
|
606
627
|
if (s.firstLevelChild) {
|
|
607
628
|
if (s.firstLevelChild.class) {
|
|
608
|
-
const l = n
|
|
629
|
+
const { firstLevelChildClassList: l } = n;
|
|
609
630
|
if (l && !l.includes(s.firstLevelChild.class)) {
|
|
610
631
|
a = !1;
|
|
611
632
|
continue;
|
|
612
633
|
}
|
|
613
634
|
}
|
|
614
635
|
if (s.firstLevelChild.type) {
|
|
615
|
-
const l = n
|
|
616
|
-
if (l
|
|
636
|
+
const { firstLevelChildSchema: l } = n;
|
|
637
|
+
if (!l || l.type !== s.firstLevelChild.type) {
|
|
617
638
|
a = !1;
|
|
618
639
|
continue;
|
|
619
640
|
}
|
|
@@ -621,15 +642,15 @@ class bo {
|
|
|
621
642
|
}
|
|
622
643
|
if (s.secondLevelChild) {
|
|
623
644
|
if (s.secondLevelChild.class) {
|
|
624
|
-
const l = n
|
|
645
|
+
const { secondLevelChildClassList: l } = n;
|
|
625
646
|
if (l && !l.includes(s.secondLevelChild.class)) {
|
|
626
647
|
a = !1;
|
|
627
648
|
continue;
|
|
628
649
|
}
|
|
629
650
|
}
|
|
630
651
|
if (s.secondLevelChild.type) {
|
|
631
|
-
const l = n
|
|
632
|
-
if (l
|
|
652
|
+
const { secondLevelChildSchema: l } = n;
|
|
653
|
+
if (!l || l.type !== s.secondLevelChild.type) {
|
|
633
654
|
a = !1;
|
|
634
655
|
continue;
|
|
635
656
|
}
|
|
@@ -637,14 +658,14 @@ class bo {
|
|
|
637
658
|
}
|
|
638
659
|
if (s.parent) {
|
|
639
660
|
if (s.parent.class) {
|
|
640
|
-
const l = n
|
|
661
|
+
const { parentClassList: l } = n;
|
|
641
662
|
if (l && !l.includes(s.parent.class)) {
|
|
642
663
|
a = !1;
|
|
643
664
|
continue;
|
|
644
665
|
}
|
|
645
666
|
}
|
|
646
667
|
if (s.parent.type) {
|
|
647
|
-
const l = n
|
|
668
|
+
const { parentSchema: l } = n;
|
|
648
669
|
if (l && l.type !== s.parent.type) {
|
|
649
670
|
a = !1;
|
|
650
671
|
continue;
|
|
@@ -656,9 +677,9 @@ class bo {
|
|
|
656
677
|
}
|
|
657
678
|
return !a;
|
|
658
679
|
}
|
|
659
|
-
getComponentContext(
|
|
660
|
-
var
|
|
661
|
-
const n =
|
|
680
|
+
getComponentContext(e) {
|
|
681
|
+
var b, F, M, C;
|
|
682
|
+
const n = e.schema, o = n.appearance && n.appearance.class || "", a = o.split(" ") || [], s = n.contents || [], l = s.length ? s[0] : null, c = l && l.appearance ? l.appearance.class : "", u = c ? c.split(" ") : [], i = (b = l == null ? void 0 : l.contents) != null && b.length ? l == null ? void 0 : l.contents[0] : null, d = i && i.appearance ? i.appearance.class : "", r = d ? d.split(" ") : [], m = n.type === "component" ? (M = (F = e.parent) == null ? void 0 : F.parent) == null ? void 0 : M.schema : (C = e.parent) == null ? void 0 : C.schema, h = m && m.appearance && m.appearance.class || "", v = h ? h.split(" ") : [];
|
|
662
683
|
return {
|
|
663
684
|
componentClass: o,
|
|
664
685
|
componentClassList: a,
|
|
@@ -666,17 +687,17 @@ class bo {
|
|
|
666
687
|
firstLevelChildSchema: l,
|
|
667
688
|
firstLevelChildClass: c,
|
|
668
689
|
firstLevelChildClassList: u,
|
|
669
|
-
secondLevelChildSchema:
|
|
670
|
-
secondLevelChildClass:
|
|
671
|
-
secondLevelChildClassList:
|
|
690
|
+
secondLevelChildSchema: i,
|
|
691
|
+
secondLevelChildClass: d,
|
|
692
|
+
secondLevelChildClassList: r,
|
|
672
693
|
parentSchema: m,
|
|
673
694
|
parentClass: h,
|
|
674
|
-
parentClassList:
|
|
695
|
+
parentClassList: v
|
|
675
696
|
};
|
|
676
697
|
}
|
|
677
698
|
}
|
|
678
|
-
class
|
|
679
|
-
constructor(
|
|
699
|
+
class Je {
|
|
700
|
+
constructor(e, n) {
|
|
680
701
|
N(this, "componentId");
|
|
681
702
|
N(this, "viewModelId");
|
|
682
703
|
N(this, "eventsEditorUtils");
|
|
@@ -693,25 +714,26 @@ class Ye {
|
|
|
693
714
|
categories: {}
|
|
694
715
|
});
|
|
695
716
|
var o;
|
|
696
|
-
this.componentId =
|
|
717
|
+
this.componentId = e, this.designerHostService = n, this.eventsEditorUtils = n.eventsEditorUtils, this.formSchemaUtils = n.formSchemaUtils, this.formMetadataConverter = n.formMetadataConverter, this.viewModelId = ((o = this.formSchemaUtils) == null ? void 0 : o.getViewModelIdByComponentId(e)) || "", this.designViewModelUtils = n.designViewModelUtils, this.controlCreatorUtils = n.controlCreatorUtils, this.metadataService = n.metadataService, this.schemaService = n.schemaService;
|
|
697
718
|
}
|
|
698
719
|
getTableInfo() {
|
|
699
|
-
var
|
|
700
|
-
return (
|
|
720
|
+
var e;
|
|
721
|
+
return (e = this.schemaService) == null ? void 0 : e.getTableInfoByViewModelId(this.viewModelId);
|
|
701
722
|
}
|
|
702
|
-
setDesignViewModelField(
|
|
703
|
-
|
|
723
|
+
setDesignViewModelField(e) {
|
|
724
|
+
var o;
|
|
725
|
+
const n = e.binding && e.binding.type === "Form" && e.binding.field;
|
|
704
726
|
if (n) {
|
|
705
727
|
if (!this.designViewModelField) {
|
|
706
|
-
const
|
|
707
|
-
this.designViewModelField =
|
|
728
|
+
const a = this.designViewModelUtils.getDgViewModel(this.viewModelId);
|
|
729
|
+
this.designViewModelField = a.fields.find((s) => s.id === n);
|
|
708
730
|
}
|
|
709
|
-
|
|
731
|
+
e.updateOn = (o = this.designViewModelField) == null ? void 0 : o.updateOn;
|
|
710
732
|
}
|
|
711
733
|
}
|
|
712
|
-
changeFieldEditorType(
|
|
734
|
+
changeFieldEditorType(e, n) {
|
|
713
735
|
}
|
|
714
|
-
getBasicPropConfig(
|
|
736
|
+
getBasicPropConfig(e) {
|
|
715
737
|
return {
|
|
716
738
|
description: "Basic Information",
|
|
717
739
|
title: "基本信息",
|
|
@@ -730,13 +752,13 @@ class Ye {
|
|
|
730
752
|
type: "combo-list",
|
|
731
753
|
textField: "name",
|
|
732
754
|
valueField: "value",
|
|
733
|
-
data: [{ value:
|
|
755
|
+
data: [{ value: e.type, name: V[e.type].name }]
|
|
734
756
|
}
|
|
735
757
|
}
|
|
736
758
|
}
|
|
737
759
|
};
|
|
738
760
|
}
|
|
739
|
-
getAppearanceConfig(
|
|
761
|
+
getAppearanceConfig(e = null) {
|
|
740
762
|
return {
|
|
741
763
|
title: "样式",
|
|
742
764
|
description: "Appearance",
|
|
@@ -762,15 +784,15 @@ class Ye {
|
|
|
762
784
|
* @param componentInstance
|
|
763
785
|
* @returns
|
|
764
786
|
*/
|
|
765
|
-
updateElementByParentContainer(
|
|
787
|
+
updateElementByParentContainer(e, n) {
|
|
766
788
|
const o = n && n.parent && n.parent.schema;
|
|
767
789
|
if (!o)
|
|
768
790
|
return;
|
|
769
|
-
const a = o.contents.findIndex((l) => l.id ===
|
|
791
|
+
const a = o.contents.findIndex((l) => l.id === e), s = Te(o.contents[a]);
|
|
770
792
|
o.contents.splice(a, 1), o.contents.splice(a, 0, s);
|
|
771
793
|
}
|
|
772
794
|
}
|
|
773
|
-
class
|
|
795
|
+
class Bo {
|
|
774
796
|
constructor() {
|
|
775
797
|
/** 控件标题 */
|
|
776
798
|
N(this, "label", "");
|
|
@@ -800,137 +822,139 @@ class wo {
|
|
|
800
822
|
N(this, "fieldSetId", "");
|
|
801
823
|
}
|
|
802
824
|
}
|
|
803
|
-
function
|
|
804
|
-
let
|
|
825
|
+
function Qe(t) {
|
|
826
|
+
let e, n;
|
|
805
827
|
const o = /* @__PURE__ */ new Map();
|
|
806
828
|
let a = [];
|
|
807
|
-
function s(
|
|
808
|
-
const h =
|
|
829
|
+
function s(d, r) {
|
|
830
|
+
const h = d.split(" ").filter((C) => C.startsWith("col-"));
|
|
809
831
|
if (h.length === 0) {
|
|
810
|
-
|
|
832
|
+
r.isSupportedClass = !1;
|
|
811
833
|
return;
|
|
812
834
|
}
|
|
813
|
-
let
|
|
814
|
-
|
|
815
|
-
}
|
|
816
|
-
function l(
|
|
817
|
-
let
|
|
818
|
-
|
|
819
|
-
if (
|
|
820
|
-
m += 1, l(
|
|
835
|
+
let v = h.find((C) => /^col-([1-9]|10|11|12)$/.test(C)), b = h.find((C) => /^col-md-([1-9]|10|11|12)$/.test(C)), F = h.find((C) => /^col-xl-([1-9]|10|11|12)$/.test(C)), M = h.find((C) => /^col-el-([1-9]|10|11|12)$/.test(C));
|
|
836
|
+
v = v || "col-12", r.columnInSM = parseInt(v.replace("col-", ""), 10), r.displayWidthInSM = r.columnInSM / 12, r.displayWidthInSM !== 1 && (r.isSupportedClass = !1), b = b || "col-md-" + r.columnInSM, r.columnInMD = parseInt(b.replace("col-md-", ""), 10), r.displayWidthInMD = r.columnInMD / 6, [1, 2].includes(r.displayWidthInMD) || (r.isSupportedClass = !1), F = F || "col-xl-" + r.columnInMD, r.columnInLG = parseInt(F.replace("col-xl-", ""), 10), r.displayWidthInLG = r.columnInLG / 3, [1, 2, 3, 4].includes(r.displayWidthInLG) || (r.isSupportedClass = !1), M = M || "col-el-" + r.columnInLG, r.columnInEL = parseInt(M.replace("col-el-", ""), 10), r.displayWidthInEL = r.columnInEL / 2, [1, 2, 3, 4, 5, 6].includes(r.displayWidthInEL) || (r.isSupportedClass = !1);
|
|
837
|
+
}
|
|
838
|
+
function l(d, r, m, h = !1) {
|
|
839
|
+
let v = !1;
|
|
840
|
+
d.contents.forEach((b) => {
|
|
841
|
+
if (b.type === "fieldset") {
|
|
842
|
+
m += 1, l(b, r, m, !0), v = !0;
|
|
821
843
|
return;
|
|
822
844
|
}
|
|
823
|
-
|
|
824
|
-
const
|
|
825
|
-
|
|
845
|
+
v && (m += 1, v = !1);
|
|
846
|
+
const F = b.appearance && b.appearance.class, M = new Bo();
|
|
847
|
+
F ? s(F, M) : M.isSupportedClass = !1, M.label = b.label || b.id, M.id = b.id, M.group = m, h && (M.fieldSetId = d.id), n === b.id && (e = m), o.set(b.id, b), r.push(M);
|
|
826
848
|
});
|
|
827
849
|
}
|
|
828
|
-
function c(
|
|
829
|
-
const
|
|
830
|
-
if (!
|
|
850
|
+
function c(d) {
|
|
851
|
+
const r = t.getComponentById(d);
|
|
852
|
+
if (!r || !r.componentType || !r.componentType.startsWith("form"))
|
|
831
853
|
return { result: !1, message: "只可以在响应式表单组件中调整响应式布局配置" };
|
|
832
|
-
const m =
|
|
854
|
+
const m = t.selectNode(r, (h) => h.type === Me["response-form"].type);
|
|
833
855
|
return !m || !m.contents || m.contents.length === 0 ? { result: !1, message: "Form区域内没有控件,请先添加控件" } : { result: !0, message: "", formNode: m };
|
|
834
856
|
}
|
|
835
|
-
function u(
|
|
836
|
-
|
|
837
|
-
const { result: m, message: h, formNode:
|
|
857
|
+
function u(d, r) {
|
|
858
|
+
r = r || d.id;
|
|
859
|
+
const { result: m, message: h, formNode: v } = c(r);
|
|
838
860
|
if (!m)
|
|
839
861
|
return { result: m, message: h };
|
|
840
|
-
n =
|
|
841
|
-
const
|
|
842
|
-
l(
|
|
843
|
-
const
|
|
862
|
+
n = d.id, a = [], o.clear();
|
|
863
|
+
const b = v.contents[0].type === Me.fieldset.type ? 0 : 1;
|
|
864
|
+
l(v, a, b);
|
|
865
|
+
const F = a.find((C) => !C.isSupportedClass);
|
|
844
866
|
return {
|
|
845
867
|
defaultState: {
|
|
846
|
-
defaultGroupNumber:
|
|
847
|
-
model:
|
|
868
|
+
defaultGroupNumber: e || 1,
|
|
869
|
+
model: F ? "customize" : "standard"
|
|
848
870
|
},
|
|
849
871
|
importData: a
|
|
850
872
|
};
|
|
851
873
|
}
|
|
852
|
-
function
|
|
853
|
-
|
|
854
|
-
const { result: m, formNode: h } = c(
|
|
874
|
+
function i(d, r) {
|
|
875
|
+
r = r;
|
|
876
|
+
const { result: m, formNode: h } = c(r);
|
|
855
877
|
if (!m)
|
|
856
878
|
return "";
|
|
857
|
-
const
|
|
858
|
-
return
|
|
859
|
-
var
|
|
860
|
-
const
|
|
861
|
-
if (
|
|
862
|
-
const
|
|
863
|
-
|
|
879
|
+
const v = [];
|
|
880
|
+
return d.forEach((b) => {
|
|
881
|
+
var C;
|
|
882
|
+
const F = o.get(b.id), M = F.appearance && F.appearance.class;
|
|
883
|
+
if (M) {
|
|
884
|
+
const w = M.split(" ").filter((U) => !U.startsWith("col-")), g = "col-" + b.columnInSM, L = "col-md-" + b.columnInMD, y = "col-xl-" + b.columnInLG, P = "col-el-" + b.columnInEL, O = [g, L, y, P].concat(w);
|
|
885
|
+
F.appearance.class = O.join(" ");
|
|
864
886
|
}
|
|
865
|
-
if (
|
|
866
|
-
const
|
|
867
|
-
|
|
887
|
+
if (b.fieldSetId) {
|
|
888
|
+
const R = h.contents.find((g) => g.id === b.fieldSetId), w = v.find((g) => g.id === b.fieldSetId);
|
|
889
|
+
w ? (C = w.contents) == null || C.push(F) : (v.push(R), R.contents = [F]);
|
|
868
890
|
} else
|
|
869
|
-
|
|
870
|
-
}), h.contents =
|
|
891
|
+
v.push(F);
|
|
892
|
+
}), h.contents = v, h.id;
|
|
871
893
|
}
|
|
872
894
|
return {
|
|
873
895
|
checkCanFindFormNode: c,
|
|
874
896
|
checkCanOpenLayoutEditor: u,
|
|
875
|
-
changeFormControlsByResponseLayoutConfig:
|
|
897
|
+
changeFormControlsByResponseLayoutConfig: i,
|
|
876
898
|
getResonseFormLayoutConfig: l
|
|
877
899
|
};
|
|
878
900
|
}
|
|
879
|
-
function
|
|
880
|
-
function n(
|
|
881
|
-
if (
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
901
|
+
function ko(t, e) {
|
|
902
|
+
function n(c, u = null) {
|
|
903
|
+
if (u)
|
|
904
|
+
return u;
|
|
905
|
+
const i = t.getComponentById(e);
|
|
906
|
+
return t.selectNode(i, (d) => d.id === c);
|
|
907
|
+
}
|
|
908
|
+
function o(c) {
|
|
909
|
+
const u = t.getComponentById(c);
|
|
910
|
+
return !(!u || !u.componentType || !u.componentType.startsWith("form"));
|
|
911
|
+
}
|
|
912
|
+
function a(c) {
|
|
913
|
+
const u = n(c.id), i = Qe(t), d = [];
|
|
914
|
+
i.getResonseFormLayoutConfig(u, d, 1);
|
|
915
|
+
const r = d.map((w) => w.columnInSM), m = d.map((w) => w.columnInMD), h = d.map((w) => w.columnInLG), v = d.map((w) => w.columnInEL);
|
|
916
|
+
function b(w) {
|
|
917
|
+
const g = new Set(w);
|
|
918
|
+
return Array.from(g).length === 1;
|
|
919
|
+
}
|
|
920
|
+
const F = b(r) ? r[0] : 0, M = b(m) ? m[0] : 0, C = b(h) ? h[0] : 0, R = b(v) ? v[0] : 0;
|
|
893
921
|
return {
|
|
894
|
-
uniqueColClassInSM:
|
|
895
|
-
uniqueColClassInMD:
|
|
896
|
-
uniqueColClassInLG:
|
|
897
|
-
uniqueColClassInEL:
|
|
922
|
+
uniqueColClassInSM: F,
|
|
923
|
+
uniqueColClassInMD: M,
|
|
924
|
+
uniqueColClassInLG: C,
|
|
925
|
+
uniqueColClassInEL: R
|
|
898
926
|
};
|
|
899
927
|
}
|
|
900
|
-
function s(u) {
|
|
901
|
-
|
|
902
|
-
|
|
928
|
+
function s(c, u) {
|
|
929
|
+
let i, d, r, m, h = [];
|
|
930
|
+
if (c) {
|
|
931
|
+
const R = c.split(" "), w = R.filter((g) => g.startsWith("col-"));
|
|
932
|
+
i = w.find((g) => /^col-([1-9]|10|11|12)$/.test(g)), d = w.find((g) => /^col-md-([1-9]|10|11|12)$/.test(g)), r = w.find((g) => /^col-xl-([1-9]|10|11|12)$/.test(g)), m = w.find((g) => /^col-el-([1-9]|10|11|12)$/.test(g)), h = R.filter((g) => !g.startsWith("col-"));
|
|
933
|
+
}
|
|
934
|
+
const v = u.uniqueColClassInSM ? "col-" + u.uniqueColClassInSM : i, b = u.uniqueColClassInMD ? "col-md-" + u.uniqueColClassInMD : d, F = u.uniqueColClassInLG ? "col-xl-" + u.uniqueColClassInLG : r, M = u.uniqueColClassInEL ? "col-el-" + u.uniqueColClassInEL : m;
|
|
935
|
+
return [v, b, F, M].concat(h).join(" ");
|
|
903
936
|
}
|
|
904
|
-
function l(
|
|
905
|
-
|
|
906
|
-
if (
|
|
907
|
-
l(
|
|
937
|
+
function l(c, u, i) {
|
|
938
|
+
c = n(i, c), c.contents.forEach((d) => {
|
|
939
|
+
if (d.type === Me.fieldset.type) {
|
|
940
|
+
l(d, u, d.id);
|
|
908
941
|
return;
|
|
909
942
|
}
|
|
910
|
-
|
|
911
|
-
const
|
|
912
|
-
|
|
943
|
+
d.appearance || (d.appearance = {});
|
|
944
|
+
const r = d.appearance.class;
|
|
945
|
+
d.appearance.class = s(r, u);
|
|
913
946
|
});
|
|
914
947
|
}
|
|
915
|
-
function c(u, r) {
|
|
916
|
-
let p, i, m, h, g = [];
|
|
917
|
-
if (u) {
|
|
918
|
-
const B = u.split(" "), F = B.filter((V) => V.startsWith("col-"));
|
|
919
|
-
p = F.find((V) => /^col-([1-9]|10|11|12)$/.test(V)), i = F.find((V) => /^col-md-([1-9]|10|11|12)$/.test(V)), m = F.find((V) => /^col-xl-([1-9]|10|11|12)$/.test(V)), h = F.find((V) => /^col-el-([1-9]|10|11|12)$/.test(V)), g = B.filter((V) => !V.startsWith("col-"));
|
|
920
|
-
}
|
|
921
|
-
const y = r.uniqueColClassInSM ? "col-" + r.uniqueColClassInSM : p, x = r.uniqueColClassInMD ? "col-md-" + r.uniqueColClassInMD : i, C = r.uniqueColClassInLG ? "col-xl-" + r.uniqueColClassInLG : m, v = r.uniqueColClassInEL ? "col-el-" + r.uniqueColClassInEL : h;
|
|
922
|
-
return [y, x, C, v].concat(g).join(" ");
|
|
923
|
-
}
|
|
924
948
|
return { checkIsInFormComponent: o, assembleUnifiedLayoutContext: a, changeFormControlsByUnifiedLayoutConfig: l };
|
|
925
949
|
}
|
|
926
|
-
class
|
|
927
|
-
constructor(
|
|
928
|
-
super(
|
|
950
|
+
class Io extends Je {
|
|
951
|
+
constructor(e, n) {
|
|
952
|
+
super(e, n);
|
|
929
953
|
}
|
|
930
|
-
getPropertyConfig(
|
|
931
|
-
|
|
932
|
-
this.propertyConfig.categories.basic = this.getBasicPropConfig(
|
|
933
|
-
const { checkIsInFormComponent: a, assembleUnifiedLayoutContext: s, changeFormControlsByUnifiedLayoutConfig: l } =
|
|
954
|
+
getPropertyConfig(e, n) {
|
|
955
|
+
const o = this;
|
|
956
|
+
this.propertyConfig.categories.basic = this.getBasicPropConfig(e);
|
|
957
|
+
const { checkIsInFormComponent: a, assembleUnifiedLayoutContext: s, changeFormControlsByUnifiedLayoutConfig: l } = ko(this.formSchemaUtils, this.componentId), c = this.getAppearanceConfig(e);
|
|
934
958
|
return c.properties.unifiedLayout = {
|
|
935
959
|
title: "统一布局配置",
|
|
936
960
|
description: "统一配置卡片区域内所有控件的宽度,只支持标准模式",
|
|
@@ -938,110 +962,126 @@ class Mo extends Ye {
|
|
|
938
962
|
refreshPanelAfterChanged: !0,
|
|
939
963
|
editor: {
|
|
940
964
|
type: "response-form-layout-setting",
|
|
941
|
-
initialState: s(
|
|
965
|
+
initialState: s(e)
|
|
942
966
|
}
|
|
943
|
-
}, c.setPropertyRelates = function(u,
|
|
967
|
+
}, c.setPropertyRelates = function(u, i) {
|
|
944
968
|
if (u)
|
|
945
969
|
switch (u && u.propertyID) {
|
|
946
970
|
case "unifiedLayout": {
|
|
947
|
-
l(null, u.propertyValue,
|
|
971
|
+
l(null, u.propertyValue, e.id), o.updateElementByParentContainer(e.id, n);
|
|
948
972
|
break;
|
|
949
973
|
}
|
|
950
974
|
}
|
|
951
975
|
}, this.propertyConfig.categories.appearance = c, this.propertyConfig;
|
|
952
976
|
}
|
|
953
977
|
}
|
|
954
|
-
function
|
|
955
|
-
const n =
|
|
956
|
-
function c(
|
|
957
|
-
const
|
|
958
|
-
|
|
978
|
+
function Eo(t, e) {
|
|
979
|
+
const n = t.schema, o = new To(), { canMove: a, canAccept: s, canDelete: l } = o.getTemplateRule(t, e);
|
|
980
|
+
function c(w) {
|
|
981
|
+
const { sourceElement: g } = w, { componentInstance: L } = g, y = e == null ? void 0 : e.formSchemaUtils;
|
|
982
|
+
if (!y)
|
|
983
|
+
return !0;
|
|
984
|
+
const P = y.getComponentById(L.value.belongedComponentId), O = y.getViewModelById(P.viewModel), U = y.getComponentById(t.componentInstance.value.belongedComponentId), z = y.getViewModelById(U.viewModel);
|
|
985
|
+
return O != null && O.id && (z != null && z.id) && O.id !== z.id ? O.bindTo === z.bindTo : !0;
|
|
959
986
|
}
|
|
960
|
-
function u(
|
|
961
|
-
|
|
987
|
+
function u(w) {
|
|
988
|
+
const g = o.getComponentContext(t);
|
|
989
|
+
return g && g.componentClassList && g.componentClassList.includes("f-form-layout") && g.componentClassList.includes("farris-form") ? w.sourceType === "control" && w.componentCategory === "input" ? !0 : w.sourceType === "move" && w.componentType === "form-group" ? c(w) : !1 : !0;
|
|
962
990
|
}
|
|
963
|
-
function
|
|
964
|
-
|
|
991
|
+
function i(w) {
|
|
992
|
+
return !(!xo().basalDragulaRuleForContainer(w, e) || !s || !u(w));
|
|
965
993
|
}
|
|
966
|
-
function
|
|
967
|
-
|
|
994
|
+
function d(w) {
|
|
995
|
+
ce();
|
|
968
996
|
}
|
|
969
|
-
function
|
|
970
|
-
|
|
971
|
-
if ((B.appearance && B.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
972
|
-
const { label: b } = v, D = ke("form-group");
|
|
973
|
-
return D.editor = T, D.label = b, m(D), delete D.editor.id, delete D.editor.binding, delete D.editor.appearance, delete D.editor.visible, D;
|
|
974
|
-
}
|
|
975
|
-
return T;
|
|
976
|
-
}
|
|
977
|
-
function m(v) {
|
|
978
|
-
const T = e.componentInstance.value.getBelongedComponentInstance(e.componentInstance);
|
|
979
|
-
if (T && T.schema && T.schema.componentType) {
|
|
980
|
-
const B = T.schema.formColumns;
|
|
981
|
-
let F = h(B);
|
|
982
|
-
F = t == null ? void 0 : t.formSchemaUtils.getControlClassByFormUnifiedLayout(F, "", e.schema), v.appearance || (v.appearance = {}), v.appearance.class = F;
|
|
983
|
-
}
|
|
997
|
+
function r() {
|
|
998
|
+
return n.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
|
|
984
999
|
}
|
|
985
|
-
function
|
|
986
|
-
let
|
|
987
|
-
switch (
|
|
1000
|
+
function m(w) {
|
|
1001
|
+
let g = "";
|
|
1002
|
+
switch (w) {
|
|
988
1003
|
case 1: {
|
|
989
|
-
|
|
1004
|
+
g = "col-12";
|
|
990
1005
|
break;
|
|
991
1006
|
}
|
|
992
1007
|
case 2: {
|
|
993
|
-
|
|
1008
|
+
g = "col-12 col-md-6 col-xl-6 col-el-6";
|
|
994
1009
|
break;
|
|
995
1010
|
}
|
|
996
1011
|
case 3: {
|
|
997
|
-
|
|
1012
|
+
g = "col-12 col-md-6 col-xl-4 col-el-4";
|
|
998
1013
|
break;
|
|
999
1014
|
}
|
|
1000
1015
|
case 4: {
|
|
1001
|
-
|
|
1016
|
+
g = "col-12 col-md-6 col-xl-3 col-el-2";
|
|
1002
1017
|
break;
|
|
1003
1018
|
}
|
|
1004
1019
|
}
|
|
1005
|
-
return
|
|
1020
|
+
return g;
|
|
1021
|
+
}
|
|
1022
|
+
function h(w) {
|
|
1023
|
+
const g = t.componentInstance.value.getBelongedComponentInstance(t.componentInstance);
|
|
1024
|
+
if (g && g.schema && g.schema.componentType) {
|
|
1025
|
+
const { formColumns: L } = g.schema;
|
|
1026
|
+
let y = m(L);
|
|
1027
|
+
y = e == null ? void 0 : e.formSchemaUtils.getControlClassByFormUnifiedLayout(y, "", t.schema), w.appearance || (w.appearance = {}), w.appearance.class = y;
|
|
1028
|
+
}
|
|
1006
1029
|
}
|
|
1007
|
-
function g
|
|
1030
|
+
function v(w, g) {
|
|
1031
|
+
const { bindingSourceContext: L, parentComponentInstance: y } = w;
|
|
1032
|
+
if (L != null && L.entityFieldNode && y) {
|
|
1033
|
+
const P = e == null ? void 0 : e.designViewModelUtils, U = (e == null ? void 0 : e.formSchemaUtils).getViewModelIdByComponentId(y.belongedComponentId), z = P.getDgViewModel(U);
|
|
1034
|
+
z.removeField([L.entityFieldNode.id]), z.addField(L.designViewModelField), g && z.changeField(L.entityFieldNode.id, { editor: { $type: g } });
|
|
1035
|
+
}
|
|
1036
|
+
}
|
|
1037
|
+
function b(w, g) {
|
|
1038
|
+
var O, U;
|
|
1039
|
+
const L = n;
|
|
1040
|
+
if ((L.appearance && L.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1041
|
+
const { label: z } = w;
|
|
1042
|
+
let H;
|
|
1043
|
+
return (O = w.bindingSourceContext) != null && O.entityFieldNode ? H = (e == null ? void 0 : e.controlCreatorUtils).setFormFieldProperty((U = w.bindingSourceContext) == null ? void 0 : U.entityFieldNode, g.type) : (H = ke("form-group"), H.editor = g, H.label = z), h(H), v(w, g.type), H;
|
|
1044
|
+
}
|
|
1045
|
+
return g;
|
|
1046
|
+
}
|
|
1047
|
+
function F() {
|
|
1008
1048
|
return a;
|
|
1009
1049
|
}
|
|
1010
|
-
function
|
|
1050
|
+
function M() {
|
|
1011
1051
|
return l;
|
|
1012
1052
|
}
|
|
1013
|
-
function
|
|
1053
|
+
function C() {
|
|
1014
1054
|
return !1;
|
|
1015
1055
|
}
|
|
1016
|
-
function
|
|
1017
|
-
return new
|
|
1056
|
+
function R(w) {
|
|
1057
|
+
return new Io(w, e).getPropertyConfig(n, t.componentInstance.value);
|
|
1018
1058
|
}
|
|
1019
1059
|
return {
|
|
1020
|
-
canAccepts:
|
|
1021
|
-
checkCanDeleteComponent:
|
|
1022
|
-
checkCanMoveComponent:
|
|
1023
|
-
getStyles:
|
|
1024
|
-
getPropsConfig:
|
|
1025
|
-
hideNestedPaddingInDesginerView:
|
|
1026
|
-
onAcceptMovedChildElement:
|
|
1027
|
-
onResolveNewComponentSchema:
|
|
1060
|
+
canAccepts: i,
|
|
1061
|
+
checkCanDeleteComponent: M,
|
|
1062
|
+
checkCanMoveComponent: F,
|
|
1063
|
+
getStyles: r,
|
|
1064
|
+
getPropsConfig: R,
|
|
1065
|
+
hideNestedPaddingInDesginerView: C,
|
|
1066
|
+
onAcceptMovedChildElement: d,
|
|
1067
|
+
onResolveNewComponentSchema: b
|
|
1028
1068
|
};
|
|
1029
1069
|
}
|
|
1030
|
-
function
|
|
1031
|
-
const
|
|
1032
|
-
return
|
|
1070
|
+
function Ze(t) {
|
|
1071
|
+
const e = t.nativeElement ? t.nativeElement : t;
|
|
1072
|
+
return e.classList !== void 0 && e.classList !== null ? e : null;
|
|
1033
1073
|
}
|
|
1034
|
-
function
|
|
1035
|
-
if (
|
|
1074
|
+
function _e(t, e) {
|
|
1075
|
+
if (e === void 0)
|
|
1036
1076
|
return;
|
|
1037
|
-
const n =
|
|
1038
|
-
n && n.classList.remove(
|
|
1077
|
+
const n = Ze(t);
|
|
1078
|
+
n && n.classList.remove(e);
|
|
1039
1079
|
}
|
|
1040
|
-
function
|
|
1041
|
-
if (
|
|
1080
|
+
function xe(t, e) {
|
|
1081
|
+
if (e === void 0)
|
|
1042
1082
|
return;
|
|
1043
|
-
const n =
|
|
1044
|
-
n && n.classList.add(
|
|
1083
|
+
const n = Ze(t);
|
|
1084
|
+
n && n.classList.add(e);
|
|
1045
1085
|
}
|
|
1046
1086
|
const be = [
|
|
1047
1087
|
{ size: "sm", width: 576 },
|
|
@@ -1050,53 +1090,52 @@ const be = [
|
|
|
1050
1090
|
{ size: "xl", width: 1200 },
|
|
1051
1091
|
{ size: "el", width: 1690 }
|
|
1052
1092
|
];
|
|
1053
|
-
function
|
|
1054
|
-
|
|
1055
|
-
if (!n || n.length < 1 || !n[0].contentRect)
|
|
1056
|
-
return;
|
|
1057
|
-
const o = n[0].contentRect;
|
|
1058
|
-
Math.abs(parseInt(o.width + "") - e.width) > e.threshold && (_e(e, t, o.width), e.width = parseInt(o.width + ""));
|
|
1059
|
-
}), e.resizeObserver.observe(t)) : Ke(e);
|
|
1093
|
+
function Ke(t) {
|
|
1094
|
+
t.resizeObserver && (t.resizeObserver.disconnect(), t.sharedObject = null);
|
|
1060
1095
|
}
|
|
1061
|
-
function
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
function _e(e, t, n = 0) {
|
|
1065
|
-
let o = [];
|
|
1066
|
-
if (!t)
|
|
1096
|
+
function et(t, e, n = 0) {
|
|
1097
|
+
const o = [];
|
|
1098
|
+
if (!e)
|
|
1067
1099
|
return;
|
|
1068
|
-
const a = n ||
|
|
1069
|
-
let s = parseFloat(a);
|
|
1100
|
+
const a = n || e.getBoundingClientRect().width, s = parseFloat(a);
|
|
1070
1101
|
for (let l = 0; l < be.length; l++)
|
|
1071
1102
|
be[l].width <= s && o.push(be[l].size);
|
|
1072
|
-
if (
|
|
1073
|
-
if (
|
|
1074
|
-
for (let c = o.length; c <
|
|
1075
|
-
|
|
1103
|
+
if (t.className.join(",") !== o.join(",")) {
|
|
1104
|
+
if (t.className.length - o.length > 0)
|
|
1105
|
+
for (let c = o.length; c < t.className.length; c++)
|
|
1106
|
+
_e(e, "f-area-response--" + t.className[c]);
|
|
1076
1107
|
else
|
|
1077
|
-
for (let c =
|
|
1078
|
-
|
|
1079
|
-
|
|
1108
|
+
for (let c = t.className.length; c < o.length; c++)
|
|
1109
|
+
xe(e, "f-area-response--" + o[c]);
|
|
1110
|
+
t.className = [...o];
|
|
1080
1111
|
}
|
|
1081
1112
|
}
|
|
1082
|
-
function
|
|
1083
|
-
|
|
1084
|
-
|
|
1113
|
+
function So(t, e) {
|
|
1114
|
+
t.enable && t.autoWidth ? t.resizeObserver || (t.resizeObserver = new ResizeObserver((n) => {
|
|
1115
|
+
if (!n || n.length < 1 || !n[0].contentRect)
|
|
1116
|
+
return;
|
|
1117
|
+
const o = n[0].contentRect;
|
|
1118
|
+
Math.abs(parseInt(o.width + "") - t.width) > t.threshold && (et(t, e, o.width), t.width = parseInt(o.width + ""));
|
|
1119
|
+
}), t.resizeObserver.observe(e)) : Ke(t);
|
|
1120
|
+
}
|
|
1121
|
+
function Re(t, e) {
|
|
1122
|
+
if (t.enable)
|
|
1123
|
+
xe(e, "f-area-response"), et(t, e);
|
|
1085
1124
|
else {
|
|
1086
|
-
|
|
1087
|
-
for (let n =
|
|
1088
|
-
|
|
1089
|
-
|
|
1125
|
+
_e(e, "f-area-response");
|
|
1126
|
+
for (let n = t.className.length; n > 0; n--)
|
|
1127
|
+
xe(e, "f-area-response--" + t.className[n]);
|
|
1128
|
+
t.className = [];
|
|
1090
1129
|
}
|
|
1091
|
-
|
|
1130
|
+
So(t, e);
|
|
1092
1131
|
}
|
|
1093
|
-
function Ne(
|
|
1094
|
-
|
|
1132
|
+
function Ne(t, e) {
|
|
1133
|
+
e.value && Object.prototype.hasOwnProperty.call(e.value, "enable") && (t.enable = e.value.enable), e.value && Object.prototype.hasOwnProperty.call(e.value, "autoWidth") && (t.autoWidth = e.value.autoWidth);
|
|
1095
1134
|
}
|
|
1096
|
-
const
|
|
1135
|
+
const Lo = {
|
|
1097
1136
|
// 在绑定元素的父组件
|
|
1098
1137
|
// 及他自己的所有子节点都挂载完成后调用
|
|
1099
|
-
mounted: (
|
|
1138
|
+
mounted: (t, e, n) => {
|
|
1100
1139
|
n.sharedObject = {
|
|
1101
1140
|
className: [],
|
|
1102
1141
|
resizeObserver: null,
|
|
@@ -1104,73 +1143,74 @@ const Bo = {
|
|
|
1104
1143
|
autoWidth: !0,
|
|
1105
1144
|
threshold: 10,
|
|
1106
1145
|
width: 0
|
|
1107
|
-
}, Ne(n.sharedObject,
|
|
1146
|
+
}, Ne(n.sharedObject, e), Re(n.sharedObject, t);
|
|
1108
1147
|
},
|
|
1109
1148
|
// 在绑定元素的父组件
|
|
1110
1149
|
// 及他自己的所有子节点都更新后调用
|
|
1111
|
-
updated: function(
|
|
1112
|
-
n.sharedObject = o.sharedObject, Ne(n.sharedObject,
|
|
1150
|
+
updated: function(t, e, n, o) {
|
|
1151
|
+
n.sharedObject = o.sharedObject, Ne(n.sharedObject, e), Re(n.sharedObject, t);
|
|
1113
1152
|
},
|
|
1114
1153
|
// 绑定元素的父组件卸载前调用
|
|
1115
|
-
beforeUnmount(
|
|
1154
|
+
beforeUnmount(t, e, n) {
|
|
1116
1155
|
Ke(n.sharedObject);
|
|
1117
1156
|
}
|
|
1118
|
-
},
|
|
1157
|
+
}, Do = /* @__PURE__ */ X({
|
|
1119
1158
|
name: "FResponseFormDesign",
|
|
1120
1159
|
directives: {
|
|
1121
|
-
"area-response":
|
|
1160
|
+
"area-response": Lo
|
|
1122
1161
|
},
|
|
1123
|
-
props:
|
|
1162
|
+
props: le,
|
|
1124
1163
|
emits: [],
|
|
1125
|
-
setup(
|
|
1126
|
-
const n =
|
|
1127
|
-
|
|
1164
|
+
setup(t, e) {
|
|
1165
|
+
const n = p(), o = ee("design-item-context"), a = ee("designer-host-service"), s = Eo(o, a), l = Ye(n, o, s);
|
|
1166
|
+
J(() => {
|
|
1128
1167
|
n.value.componentInstance = l;
|
|
1129
|
-
}),
|
|
1130
|
-
const c =
|
|
1131
|
-
const u =
|
|
1168
|
+
}), e.expose(l.value);
|
|
1169
|
+
const c = S(() => {
|
|
1170
|
+
const u = t.customClass.split(" "), i = {
|
|
1132
1171
|
"drag-container": !0
|
|
1133
1172
|
};
|
|
1134
|
-
return u.reduce((
|
|
1173
|
+
return u.reduce((d, r) => (d[r] = !0, d), i), i;
|
|
1135
1174
|
});
|
|
1136
|
-
return () =>
|
|
1175
|
+
return () => Ae(f("div", {
|
|
1137
1176
|
ref: n,
|
|
1138
1177
|
class: c.value,
|
|
1178
|
+
style: t.customClass,
|
|
1139
1179
|
"data-dragref": `${o.schema.id}-container`,
|
|
1140
1180
|
"data-associate": `${o.schema.id}-component`
|
|
1141
|
-
}, [
|
|
1181
|
+
}, [e.slots.default && e.slots.default()]), [[$e("area-response")]]);
|
|
1142
1182
|
}
|
|
1143
|
-
}),
|
|
1183
|
+
}), Po = {
|
|
1144
1184
|
id: { type: String },
|
|
1145
1185
|
required: { type: Boolean, default: !1 },
|
|
1146
1186
|
text: { type: String, default: "" },
|
|
1147
1187
|
title: { type: String }
|
|
1148
|
-
},
|
|
1188
|
+
}, tt = /* @__PURE__ */ X({
|
|
1149
1189
|
name: "FDynamicFormLabel",
|
|
1150
|
-
props:
|
|
1190
|
+
props: Po,
|
|
1151
1191
|
emits: [],
|
|
1152
|
-
setup(
|
|
1153
|
-
const n =
|
|
1154
|
-
return
|
|
1155
|
-
a.value =
|
|
1156
|
-
}),
|
|
1192
|
+
setup(t, e) {
|
|
1193
|
+
const n = p(t.title || t.text), o = p(t.required), a = p(t.text);
|
|
1194
|
+
return W(() => t.text, () => {
|
|
1195
|
+
a.value = t.text;
|
|
1196
|
+
}), W(() => t.required, (s, l) => {
|
|
1157
1197
|
s !== l && (o.value = s);
|
|
1158
1198
|
}), () => a.value && f("label", {
|
|
1159
1199
|
class: "col-form-label",
|
|
1160
1200
|
title: n.value
|
|
1161
1201
|
}, [o.value && f("span", {
|
|
1162
1202
|
class: "farris-label-info text-danger"
|
|
1163
|
-
}, [
|
|
1203
|
+
}, [Y("*")]), f("span", {
|
|
1164
1204
|
class: "farris-label-text"
|
|
1165
1205
|
}, [a.value])]);
|
|
1166
1206
|
}
|
|
1167
|
-
}),
|
|
1207
|
+
}), Vo = /* @__PURE__ */ new Map([
|
|
1168
1208
|
["appearance", We]
|
|
1169
1209
|
]);
|
|
1170
|
-
function
|
|
1171
|
-
return
|
|
1210
|
+
function Ro(t, e, n) {
|
|
1211
|
+
return e;
|
|
1172
1212
|
}
|
|
1173
|
-
const
|
|
1213
|
+
const No = "https://json-schema.org/draft/2020-12/schema", Oo = "https://farris-design.gitee.io/input-group.schema.json", Ao = "input-group", $o = "A Farris Input Component", Uo = "object", jo = {
|
|
1174
1214
|
id: {
|
|
1175
1215
|
description: "The unique identifier for a Input Group",
|
|
1176
1216
|
type: "string"
|
|
@@ -1232,11 +1272,6 @@ const Lo = "https://json-schema.org/draft/2020-12/schema", Do = "https://farris-
|
|
|
1232
1272
|
type: "boolean",
|
|
1233
1273
|
default: !1
|
|
1234
1274
|
},
|
|
1235
|
-
required: {
|
|
1236
|
-
description: "",
|
|
1237
|
-
type: "boolean",
|
|
1238
|
-
default: !1
|
|
1239
|
-
},
|
|
1240
1275
|
tabIndex: {
|
|
1241
1276
|
description: "",
|
|
1242
1277
|
type: "number",
|
|
@@ -1372,17 +1407,23 @@ const Lo = "https://json-schema.org/draft/2020-12/schema", Do = "https://farris-
|
|
|
1372
1407
|
type: "string",
|
|
1373
1408
|
default: ""
|
|
1374
1409
|
}
|
|
1375
|
-
},
|
|
1410
|
+
}, zo = [
|
|
1376
1411
|
"id",
|
|
1377
1412
|
"type"
|
|
1378
|
-
],
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1413
|
+
], qo = [
|
|
1414
|
+
"id",
|
|
1415
|
+
"appearance",
|
|
1416
|
+
"binding",
|
|
1417
|
+
"visible"
|
|
1418
|
+
], Go = {
|
|
1419
|
+
$schema: No,
|
|
1420
|
+
$id: Oo,
|
|
1421
|
+
title: Ao,
|
|
1422
|
+
description: $o,
|
|
1423
|
+
type: Uo,
|
|
1424
|
+
properties: jo,
|
|
1425
|
+
required: zo,
|
|
1426
|
+
ignore: qo
|
|
1386
1427
|
}, Ee = {
|
|
1387
1428
|
id: { Type: String, default: "" },
|
|
1388
1429
|
/** 是否自动完成 */
|
|
@@ -1451,255 +1492,85 @@ const Lo = "https://json-schema.org/draft/2020-12/schema", Do = "https://farris-
|
|
|
1451
1492
|
*/
|
|
1452
1493
|
updateOn: { type: String, default: "blur" }
|
|
1453
1494
|
};
|
|
1454
|
-
|
|
1455
|
-
function
|
|
1456
|
-
const
|
|
1457
|
-
|
|
1458
|
-
"f-utils-fill": !0,
|
|
1459
|
-
"text-left": u.value === "left",
|
|
1460
|
-
"text-center": u.value === "center",
|
|
1461
|
-
"text-right": u.value === "right"
|
|
1462
|
-
})), v = w(() => {
|
|
1463
|
-
const R = {
|
|
1464
|
-
"f-cmp-inputgroup": !0,
|
|
1465
|
-
"input-group": !0,
|
|
1466
|
-
"f-state-disable": a.value,
|
|
1467
|
-
"f-state-editable": i.value,
|
|
1468
|
-
"f-state-readonly": y.value,
|
|
1469
|
-
"f-state-focus": m.value
|
|
1470
|
-
};
|
|
1471
|
-
return (e.customClass || "").split(" ").reduce((te, ne) => (te[ne] = !0, te), R), R;
|
|
1472
|
-
}), T = w(() => c.value ? "" : "border-width : 0 ");
|
|
1473
|
-
function B(R, H = !0) {
|
|
1474
|
-
n.value = R, o.value !== R && (o.value = R), H && t.emit("change", R), t.emit("update:modelValue", R), t.emit("update:value", R);
|
|
1475
|
-
}
|
|
1476
|
-
U(
|
|
1477
|
-
() => e.modelValue,
|
|
1478
|
-
(R, H) => {
|
|
1479
|
-
R !== H && (n.value = R, o.value = R);
|
|
1480
|
-
}
|
|
1481
|
-
), U(() => e.disabled, (R, H) => {
|
|
1482
|
-
R !== H && (a.value = R);
|
|
1483
|
-
});
|
|
1484
|
-
function F(R) {
|
|
1485
|
-
return s.value = !1, t.emit("blur", R), R.stopPropagation(), !1;
|
|
1486
|
-
}
|
|
1487
|
-
function V(R) {
|
|
1488
|
-
t.emit("click", R);
|
|
1489
|
-
}
|
|
1490
|
-
function b(R) {
|
|
1491
|
-
e.disabled || (c.value && (s.value = !0), p.value && t.emit("focus", R));
|
|
1492
|
-
}
|
|
1493
|
-
function D(R) {
|
|
1494
|
-
t.emit("input", R.target.value);
|
|
1495
|
-
const H = R.target.value;
|
|
1496
|
-
o.value = H, r.value === "change" && (t.emit("update:modelValue", H), t.emit("update:value", H));
|
|
1497
|
-
}
|
|
1498
|
-
function j(R) {
|
|
1499
|
-
t.emit("keydown", R);
|
|
1500
|
-
}
|
|
1501
|
-
function q(R) {
|
|
1502
|
-
t.emit("keyup", R);
|
|
1503
|
-
}
|
|
1504
|
-
function X(R) {
|
|
1505
|
-
R.target.tagName !== "INPUT" && R.preventDefault(), R.stopPropagation();
|
|
1506
|
-
}
|
|
1507
|
-
function J(R) {
|
|
1508
|
-
if (r.value === "blur") {
|
|
1509
|
-
const H = R.target.value;
|
|
1510
|
-
R.stopPropagation(), B(H);
|
|
1511
|
-
}
|
|
1512
|
-
}
|
|
1513
|
-
return {
|
|
1514
|
-
changeTextBoxValue: B,
|
|
1515
|
-
disabled: a,
|
|
1516
|
-
displayText: o,
|
|
1517
|
-
editable: i,
|
|
1518
|
-
hasFocused: m,
|
|
1519
|
-
inputGroupClass: v,
|
|
1520
|
-
inputType: l,
|
|
1521
|
-
isEmpty: h,
|
|
1522
|
-
modelValue: n,
|
|
1523
|
-
readonly: y,
|
|
1524
|
-
onBlur: F,
|
|
1525
|
-
onClick: V,
|
|
1526
|
-
onFocus: b,
|
|
1527
|
-
onInput: D,
|
|
1528
|
-
onKeydown: j,
|
|
1529
|
-
onKeyup: q,
|
|
1530
|
-
onMousedown: X,
|
|
1531
|
-
onTextBoxValueChange: J,
|
|
1532
|
-
placeholder: g,
|
|
1533
|
-
textBoxClass: C,
|
|
1534
|
-
textBoxTitle: x,
|
|
1535
|
-
inputGroupStyle: T
|
|
1536
|
-
};
|
|
1537
|
-
}
|
|
1538
|
-
function jo(e, t, n, o) {
|
|
1539
|
-
const a = d(e.disabled), s = d(!1), l = d("text"), c = d(e.showBorder), u = d(e.textAlign);
|
|
1540
|
-
w(() => e.editable || !e.readonly);
|
|
1541
|
-
const r = w(() => e.editable && !e.disabled && !e.readonly), p = w(() => !e.disabled && s.value), i = w(() => n.value === "" || n.value === null || n.value === void 0), m = w(() => e.placeholder), h = w(() => e.readonly || !e.editable), g = w(() => e.enableTitle ? n.value : ""), y = w(() => ({
|
|
1542
|
-
"form-control": !0,
|
|
1543
|
-
// 'f-utils-fill': true,
|
|
1544
|
-
"text-left": u.value === "left",
|
|
1545
|
-
"text-center": u.value === "center",
|
|
1546
|
-
"text-right": u.value === "right"
|
|
1547
|
-
})), x = w(() => ({
|
|
1548
|
-
"f-cmp-inputgroup": !0,
|
|
1549
|
-
"input-group": !0,
|
|
1550
|
-
"f-state-disable": !0,
|
|
1551
|
-
"f-state-editable": !1,
|
|
1552
|
-
"f-state-readonly": !0
|
|
1553
|
-
// 'f-state-focus': hasFocused.value
|
|
1554
|
-
})), C = w(() => c.value ? "" : "border-width : 0 ");
|
|
1555
|
-
return {
|
|
1556
|
-
// changeTextBoxValue,
|
|
1557
|
-
disabled: a,
|
|
1558
|
-
displayText: o,
|
|
1559
|
-
editable: r,
|
|
1560
|
-
hasFocused: p,
|
|
1561
|
-
inputGroupClass: x,
|
|
1562
|
-
inputType: l,
|
|
1563
|
-
isEmpty: i,
|
|
1564
|
-
modelValue: n,
|
|
1565
|
-
readonly: h,
|
|
1566
|
-
// onBlur,
|
|
1567
|
-
// onClick,
|
|
1568
|
-
// onFocus,
|
|
1569
|
-
// onInput,
|
|
1570
|
-
// onKeydown,
|
|
1571
|
-
// onKeyup,
|
|
1572
|
-
// onMousedown,
|
|
1573
|
-
// onTextBoxValueChange,
|
|
1574
|
-
placeholder: m,
|
|
1575
|
-
textBoxClass: y,
|
|
1576
|
-
textBoxTitle: g,
|
|
1577
|
-
inputGroupStyle: C
|
|
1578
|
-
};
|
|
1579
|
-
}
|
|
1580
|
-
function tt(e, t, n) {
|
|
1581
|
-
const o = d(!1), a = w(() => e.enableClear && !e.readonly && !e.disabled), { changeTextBoxValue: s, displayText: l, hasFocused: c, isEmpty: u } = n;
|
|
1582
|
-
function r(y) {
|
|
1583
|
-
o.value = y;
|
|
1584
|
-
}
|
|
1585
|
-
U(l, () => {
|
|
1586
|
-
c != null && c.value ? r(!!(l != null && l.value)) : r(!1);
|
|
1587
|
-
});
|
|
1588
|
-
const p = w(() => ({
|
|
1589
|
-
"input-group-text": !0,
|
|
1590
|
-
"input-group-clear": !0
|
|
1591
|
-
})), i = w(() => ({
|
|
1592
|
-
width: "24px",
|
|
1593
|
-
display: o.value ? "flex" : "none"
|
|
1594
|
-
}));
|
|
1595
|
-
function m(y) {
|
|
1596
|
-
y.stopPropagation(), a.value && (s("", !0), r(!o.value), t.emit("clear"));
|
|
1597
|
-
}
|
|
1598
|
-
function h(y) {
|
|
1599
|
-
a.value && !u.value && r(!0);
|
|
1600
|
-
}
|
|
1601
|
-
function g(y) {
|
|
1602
|
-
a.value && r(!1);
|
|
1603
|
-
}
|
|
1604
|
-
return { clearButtonClass: p, clearButtonStyle: i, hasShownClearButton: o, onClearValue: m, onMouseEnter: h, onMouseLeave: g, shouldShowClearButton: a };
|
|
1605
|
-
}
|
|
1606
|
-
const zo = ["moz", "ms", "webkit"];
|
|
1607
|
-
function qo() {
|
|
1608
|
-
let e = 0;
|
|
1609
|
-
return (t) => {
|
|
1610
|
-
const n = (/* @__PURE__ */ new Date()).getTime(), o = Math.max(0, 16 - (n - e)), a = setTimeout(() => {
|
|
1611
|
-
t(n + o);
|
|
1612
|
-
}, o);
|
|
1613
|
-
return e = n + o, a;
|
|
1614
|
-
};
|
|
1615
|
-
}
|
|
1616
|
-
function Uo() {
|
|
1617
|
-
if (typeof window > "u")
|
|
1618
|
-
return () => 0;
|
|
1619
|
-
if (window.requestAnimationFrame)
|
|
1620
|
-
return window.requestAnimationFrame.bind(window);
|
|
1621
|
-
const e = zo.filter((t) => `${t}RequestAnimationFrame` in window)[0];
|
|
1622
|
-
return e ? window[`${e}RequestAnimationFrame`] : qo();
|
|
1623
|
-
}
|
|
1624
|
-
Uo();
|
|
1625
|
-
function nt(e, t) {
|
|
1626
|
-
const n = d(e.groupText), o = w(() => e.showButtonWhenDisabled && (e.readonly || e.disabled)), a = w(() => e.enableClear || !!e.groupText);
|
|
1627
|
-
return { appendedButtonClass: w(() => ({
|
|
1495
|
+
pe(Ee, Go, Vo, Ro);
|
|
1496
|
+
function nt(t, e) {
|
|
1497
|
+
const n = p(t.groupText), o = S(() => t.showButtonWhenDisabled && (t.readonly || t.disabled)), a = S(() => t.enableClear || !!t.groupText);
|
|
1498
|
+
return { appendedButtonClass: S(() => ({
|
|
1628
1499
|
"input-group-append": !0,
|
|
1629
1500
|
"append-force-show": o.value
|
|
1630
1501
|
})), appendedContent: n, shouldShowAppendedButton: a };
|
|
1631
1502
|
}
|
|
1632
|
-
function ot(
|
|
1633
|
-
const { appendedContent: a } = o, s =
|
|
1634
|
-
|
|
1503
|
+
function ot(t, e, n, o) {
|
|
1504
|
+
const { appendedContent: a } = o, s = p(t.enableViewPassword), l = S(() => t.type === "password"), c = '<span class="f-icon f-icon-eye" style="color: rgb(56, 143, 255);"></span>', u = '<span class="f-icon f-icon-eye"></span>', i = p(!1);
|
|
1505
|
+
W(() => [t.readonly, t.disabled], ([m, h]) => {
|
|
1635
1506
|
l.value && (n.value = m || h ? "password" : n.value, a.value = m || h ? u : a.value);
|
|
1636
1507
|
});
|
|
1637
|
-
function
|
|
1638
|
-
return
|
|
1508
|
+
function d() {
|
|
1509
|
+
return i.value = !i.value, n.value = i.value ? "text" : "password", a.value = i.value ? c : u, !1;
|
|
1639
1510
|
}
|
|
1640
|
-
function
|
|
1511
|
+
function r() {
|
|
1641
1512
|
n.value = l.value ? "password" : "text", a.value = l.value ? s.value ? u : "" : a.value;
|
|
1642
1513
|
}
|
|
1643
|
-
return
|
|
1514
|
+
return r(), { isPassword: l, onClickAppendedButton: d };
|
|
1644
1515
|
}
|
|
1645
|
-
function
|
|
1646
|
-
const o =
|
|
1516
|
+
function Wo(t, e, n) {
|
|
1517
|
+
const o = p(), {
|
|
1647
1518
|
onBlurTextBox: a,
|
|
1648
1519
|
onFocusTextBox: s,
|
|
1649
1520
|
onInput: l,
|
|
1650
1521
|
onKeyDown: c,
|
|
1651
1522
|
textBoxValue: u
|
|
1652
|
-
} = n,
|
|
1523
|
+
} = n, i = S(() => t.disabled || t.readonly || !t.editable ? "" : t.placeholder), d = S(() => ({
|
|
1653
1524
|
"form-control": !0,
|
|
1654
1525
|
"f-utils-fill": !0
|
|
1655
|
-
})),
|
|
1656
|
-
"text-align":
|
|
1526
|
+
})), r = S(() => ({
|
|
1527
|
+
"text-align": t.textAlign
|
|
1657
1528
|
}));
|
|
1658
|
-
function m(
|
|
1659
|
-
|
|
1529
|
+
function m(b) {
|
|
1530
|
+
b.stopPropagation();
|
|
1660
1531
|
}
|
|
1661
1532
|
function h() {
|
|
1662
|
-
|
|
1533
|
+
t.selectOnCreated, t.focusOnCreated;
|
|
1663
1534
|
}
|
|
1664
|
-
async function
|
|
1665
|
-
s(
|
|
1535
|
+
async function v(b) {
|
|
1536
|
+
s(b), await ce, h();
|
|
1666
1537
|
}
|
|
1667
|
-
return
|
|
1668
|
-
await
|
|
1538
|
+
return J(async () => {
|
|
1539
|
+
await ce, h();
|
|
1669
1540
|
}), () => f("input", {
|
|
1670
1541
|
ref: o,
|
|
1671
|
-
class:
|
|
1672
|
-
style:
|
|
1542
|
+
class: d.value,
|
|
1543
|
+
style: r.value,
|
|
1673
1544
|
type: "text",
|
|
1674
1545
|
value: u.value,
|
|
1675
|
-
disabled:
|
|
1676
|
-
readonly:
|
|
1677
|
-
placeholder:
|
|
1546
|
+
disabled: t.disabled,
|
|
1547
|
+
readonly: t.readonly || !t.editable,
|
|
1548
|
+
placeholder: i.value,
|
|
1678
1549
|
onBlur: a,
|
|
1679
1550
|
onChange: m,
|
|
1680
|
-
onFocus:
|
|
1551
|
+
onFocus: v,
|
|
1681
1552
|
onInput: l,
|
|
1682
1553
|
onKeydown: c
|
|
1683
1554
|
}, null);
|
|
1684
1555
|
}
|
|
1685
|
-
function
|
|
1556
|
+
function Ho(t, e, n) {
|
|
1686
1557
|
const {
|
|
1687
1558
|
canDownward: o,
|
|
1688
1559
|
canUpward: a,
|
|
1689
1560
|
onClickDownButton: s,
|
|
1690
1561
|
onClickUpButton: l
|
|
1691
|
-
} = n, c =
|
|
1562
|
+
} = n, c = S(() => ({
|
|
1692
1563
|
"input-group-append": !0,
|
|
1693
1564
|
"btn-group": !0,
|
|
1694
1565
|
"btn-group-number": !0
|
|
1695
|
-
})), u =
|
|
1566
|
+
})), u = S(() => ({
|
|
1696
1567
|
btn: !0,
|
|
1697
1568
|
"btn-secondary": !0,
|
|
1698
1569
|
"btn-number-flag": !0
|
|
1699
|
-
})),
|
|
1570
|
+
})), i = S(() => ({
|
|
1700
1571
|
cursor: a() ? "pointer" : "not-allowed",
|
|
1701
1572
|
"margin-left": 0
|
|
1702
|
-
})),
|
|
1573
|
+
})), d = S(() => ({
|
|
1703
1574
|
cursor: o() ? "pointer" : "not-allowed",
|
|
1704
1575
|
"margin-left": 0
|
|
1705
1576
|
}));
|
|
@@ -1708,7 +1579,7 @@ function Wo(e, t, n) {
|
|
|
1708
1579
|
}, [f("button", {
|
|
1709
1580
|
title: "upButton",
|
|
1710
1581
|
class: u.value,
|
|
1711
|
-
style:
|
|
1582
|
+
style: i.value,
|
|
1712
1583
|
onClick: l,
|
|
1713
1584
|
disabled: !a()
|
|
1714
1585
|
}, [f("span", {
|
|
@@ -1716,196 +1587,196 @@ function Wo(e, t, n) {
|
|
|
1716
1587
|
}, null)]), f("button", {
|
|
1717
1588
|
title: "downButton",
|
|
1718
1589
|
class: u.value,
|
|
1719
|
-
style:
|
|
1590
|
+
style: d.value,
|
|
1720
1591
|
onClick: s,
|
|
1721
1592
|
disabled: !o()
|
|
1722
1593
|
}, [f("span", {
|
|
1723
1594
|
class: "f-icon f-icon-arrow-chevron-down number-arrow-chevron"
|
|
1724
1595
|
}, null)])]);
|
|
1725
1596
|
}
|
|
1726
|
-
function
|
|
1727
|
-
const n =
|
|
1597
|
+
function Xo(t, e) {
|
|
1598
|
+
const n = $t(t, e), o = Ut(t, e, n), a = jt(t, e, o, n), s = zt(t, e, o, n, a), l = Ho(t, e, a), {
|
|
1728
1599
|
displayValue: c,
|
|
1729
1600
|
modelValue: u,
|
|
1730
|
-
getRealValue:
|
|
1731
|
-
} = n,
|
|
1732
|
-
format:
|
|
1601
|
+
getRealValue: i
|
|
1602
|
+
} = n, d = Wo(t, e, s), {
|
|
1603
|
+
format: r
|
|
1733
1604
|
} = o, {
|
|
1734
1605
|
isFocus: m
|
|
1735
|
-
} = s, h =
|
|
1736
|
-
return
|
|
1737
|
-
const
|
|
1738
|
-
c.value =
|
|
1739
|
-
}),
|
|
1740
|
-
const
|
|
1741
|
-
u.value =
|
|
1742
|
-
}),
|
|
1743
|
-
|
|
1744
|
-
}),
|
|
1745
|
-
c.value =
|
|
1606
|
+
} = s, h = S(() => !t.disabled && !t.readonly);
|
|
1607
|
+
return J(() => {
|
|
1608
|
+
const v = i(t.modelValue);
|
|
1609
|
+
c.value = r(v);
|
|
1610
|
+
}), W(() => [t.value], ([v]) => {
|
|
1611
|
+
const b = i(v);
|
|
1612
|
+
u.value = b, c.value = r(b);
|
|
1613
|
+
}), W(() => [t.modelValue], ([v]) => {
|
|
1614
|
+
v !== u.value && (u.value = v, !m.value && (c.value = r(i(v))));
|
|
1615
|
+
}), W(() => [t.precision, t.useThousands, t.prefix, t.suffix, t.showZero], () => {
|
|
1616
|
+
c.value = r(u.value);
|
|
1746
1617
|
}), () => f("div", {
|
|
1747
1618
|
class: "input-group f-state-hover flex-row f-cmp-number-spinner"
|
|
1748
|
-
}, [
|
|
1619
|
+
}, [d(), h.value && l()]);
|
|
1749
1620
|
}
|
|
1750
|
-
function
|
|
1751
|
-
const a =
|
|
1621
|
+
function Yo(t, e, n, o) {
|
|
1622
|
+
const a = p(), s = p(t.autocomplete), l = p(t.enableTitle), {
|
|
1752
1623
|
isPassword: c
|
|
1753
|
-
} = n, u =
|
|
1754
|
-
disabled:
|
|
1624
|
+
} = n, u = p(t.minLength), i = p(t.maxLength), d = p(t.tabIndex), {
|
|
1625
|
+
disabled: r,
|
|
1755
1626
|
displayText: m,
|
|
1756
1627
|
inputType: h,
|
|
1757
|
-
onBlur:
|
|
1758
|
-
onFocus:
|
|
1759
|
-
onInput:
|
|
1760
|
-
onClick:
|
|
1761
|
-
onKeydown:
|
|
1762
|
-
onKeyup:
|
|
1763
|
-
onMousedown:
|
|
1764
|
-
onTextBoxValueChange:
|
|
1765
|
-
readonly:
|
|
1766
|
-
placeholder:
|
|
1767
|
-
textBoxClass:
|
|
1768
|
-
textBoxTitle:
|
|
1628
|
+
onBlur: v,
|
|
1629
|
+
onFocus: b,
|
|
1630
|
+
onInput: F,
|
|
1631
|
+
onClick: M,
|
|
1632
|
+
onKeydown: C,
|
|
1633
|
+
onKeyup: R,
|
|
1634
|
+
onMousedown: w,
|
|
1635
|
+
onTextBoxValueChange: g,
|
|
1636
|
+
readonly: L,
|
|
1637
|
+
placeholder: y,
|
|
1638
|
+
textBoxClass: P,
|
|
1639
|
+
textBoxTitle: O
|
|
1769
1640
|
} = o;
|
|
1770
|
-
return
|
|
1771
|
-
|
|
1641
|
+
return J(() => {
|
|
1642
|
+
t.selectOnCreated, t.focusOnCreated;
|
|
1772
1643
|
}), () => f("input", {
|
|
1773
1644
|
ref: a,
|
|
1774
1645
|
name: "input-group-value",
|
|
1775
1646
|
autocomplete: s.value,
|
|
1776
|
-
class:
|
|
1777
|
-
disabled:
|
|
1778
|
-
maxlength:
|
|
1647
|
+
class: P.value,
|
|
1648
|
+
disabled: r == null ? void 0 : r.value,
|
|
1649
|
+
maxlength: i.value,
|
|
1779
1650
|
minlength: u.value,
|
|
1780
|
-
placeholder:
|
|
1781
|
-
readonly:
|
|
1782
|
-
tabindex:
|
|
1783
|
-
title: l.value && !c.value ?
|
|
1651
|
+
placeholder: y.value,
|
|
1652
|
+
readonly: L == null ? void 0 : L.value,
|
|
1653
|
+
tabindex: d.value,
|
|
1654
|
+
title: l.value && !c.value ? O.value : "",
|
|
1784
1655
|
type: h.value,
|
|
1785
1656
|
value: m == null ? void 0 : m.value,
|
|
1786
|
-
onBlur:
|
|
1787
|
-
onClick:
|
|
1788
|
-
onChange:
|
|
1789
|
-
onFocus:
|
|
1790
|
-
onInput:
|
|
1791
|
-
onKeydown:
|
|
1792
|
-
onKeyup:
|
|
1793
|
-
onMousedown:
|
|
1657
|
+
onBlur: v,
|
|
1658
|
+
onClick: M,
|
|
1659
|
+
onChange: g,
|
|
1660
|
+
onFocus: b,
|
|
1661
|
+
onInput: F,
|
|
1662
|
+
onKeydown: C,
|
|
1663
|
+
onKeyup: R,
|
|
1664
|
+
onMousedown: w
|
|
1794
1665
|
}, null);
|
|
1795
1666
|
}
|
|
1796
|
-
function
|
|
1797
|
-
const n =
|
|
1798
|
-
content:
|
|
1667
|
+
function Jo(t, e) {
|
|
1668
|
+
const n = S(() => t.useExtendInfo && !!t.extendInfo), o = Z({
|
|
1669
|
+
content: t.extendInfo
|
|
1799
1670
|
});
|
|
1800
1671
|
function a() {
|
|
1801
|
-
|
|
1672
|
+
e.emit("updateExtendInfo");
|
|
1802
1673
|
}
|
|
1803
|
-
return () => n.value &&
|
|
1674
|
+
return () => n.value && Ae(f("span", {
|
|
1804
1675
|
class: "input-group-before-tips",
|
|
1805
1676
|
onMouseenter: a
|
|
1806
1677
|
}, [f("i", {
|
|
1807
1678
|
class: "f-icon f-icon-info-circle"
|
|
1808
1679
|
}, null), f("b", {
|
|
1809
1680
|
class: "tips-arrow"
|
|
1810
|
-
}, null)]), [[
|
|
1681
|
+
}, null)]), [[$e("tooltip"), o]]);
|
|
1811
1682
|
}
|
|
1812
|
-
function at(
|
|
1683
|
+
function at(t, e, n, o, a) {
|
|
1813
1684
|
const {
|
|
1814
1685
|
appendedButtonClass: s,
|
|
1815
1686
|
appendedContent: l
|
|
1816
|
-
} = n, c =
|
|
1817
|
-
clearButtonClass:
|
|
1818
|
-
clearButtonStyle:
|
|
1687
|
+
} = n, c = S(() => t.showButtonWhenDisabled && (!t.editable || !t.readonly) && !t.disabled), u = S(() => l.value && !e.slots.groupTextTemplate), i = S(() => !!e.slots.groupTextTemplate), {
|
|
1688
|
+
clearButtonClass: d,
|
|
1689
|
+
clearButtonStyle: r,
|
|
1819
1690
|
onClearValue: m,
|
|
1820
1691
|
shouldShowClearButton: h
|
|
1821
1692
|
} = o;
|
|
1822
|
-
function
|
|
1693
|
+
function v() {
|
|
1823
1694
|
return f("span", {
|
|
1824
1695
|
id: "clearIcon",
|
|
1825
|
-
class:
|
|
1826
|
-
style:
|
|
1827
|
-
onClick: (
|
|
1696
|
+
class: d.value,
|
|
1697
|
+
style: r.value,
|
|
1698
|
+
onClick: (y) => m(y)
|
|
1828
1699
|
}, [f("i", {
|
|
1829
1700
|
class: "f-icon modal_close"
|
|
1830
1701
|
}, null)]);
|
|
1831
1702
|
}
|
|
1832
|
-
function y
|
|
1833
|
-
|
|
1703
|
+
function b(y) {
|
|
1704
|
+
e.emit("iconMouseEnter", y);
|
|
1834
1705
|
}
|
|
1835
|
-
function
|
|
1836
|
-
|
|
1706
|
+
function F(y) {
|
|
1707
|
+
e.emit("iconMouseLeave", y);
|
|
1837
1708
|
}
|
|
1838
|
-
function
|
|
1839
|
-
c.value &&
|
|
1840
|
-
originalEvent:
|
|
1841
|
-
}),
|
|
1709
|
+
function M(y) {
|
|
1710
|
+
c.value && e.emit("clickHandle", {
|
|
1711
|
+
originalEvent: y
|
|
1712
|
+
}), y.stopPropagation();
|
|
1842
1713
|
}
|
|
1843
|
-
const
|
|
1844
|
-
function
|
|
1714
|
+
const C = t.type === "password" ? a.onClickAppendedButton : M;
|
|
1715
|
+
function R() {
|
|
1845
1716
|
return f("span", {
|
|
1846
1717
|
class: "input-group-text",
|
|
1847
|
-
onMouseenter: (
|
|
1848
|
-
onMouseleave: (
|
|
1718
|
+
onMouseenter: (y) => b(y),
|
|
1719
|
+
onMouseleave: (y) => F(y),
|
|
1849
1720
|
innerHTML: l.value,
|
|
1850
|
-
onClick: (
|
|
1721
|
+
onClick: (y) => C(y)
|
|
1851
1722
|
}, null);
|
|
1852
1723
|
}
|
|
1853
|
-
function
|
|
1854
|
-
return
|
|
1724
|
+
function w() {
|
|
1725
|
+
return e.slots.groupTextTemplate && e.slots.groupTextTemplate();
|
|
1855
1726
|
}
|
|
1856
|
-
function
|
|
1857
|
-
return u.value ?
|
|
1727
|
+
function g() {
|
|
1728
|
+
return u.value ? R : i.value ? w : "";
|
|
1858
1729
|
}
|
|
1859
|
-
const
|
|
1730
|
+
const L = g();
|
|
1860
1731
|
return () => f("div", {
|
|
1861
1732
|
class: s.value
|
|
1862
|
-
}, [h.value &&
|
|
1733
|
+
}, [h.value && v(), L && L()]);
|
|
1863
1734
|
}
|
|
1864
|
-
const
|
|
1735
|
+
const Qo = /* @__PURE__ */ X({
|
|
1865
1736
|
name: "FInputGroup",
|
|
1866
1737
|
props: Ee,
|
|
1867
1738
|
emits: ["clear", "change", "blur", "click", "clickHandle", "focus", "input", "keydown", "keyup", "iconMouseEnter", "iconMouseLeave", "update:modelValue", "update:value", "updateExtendInfo", "valueChange"],
|
|
1868
|
-
setup(
|
|
1869
|
-
const n =
|
|
1739
|
+
setup(t, e) {
|
|
1740
|
+
const n = p(t.modelValue), o = p(t.modelValue), a = Nt(t, e, n, o), {
|
|
1870
1741
|
inputGroupClass: s,
|
|
1871
1742
|
inputType: l,
|
|
1872
1743
|
inputGroupStyle: c
|
|
1873
|
-
} = a, u = nt(
|
|
1874
|
-
shouldShowAppendedButton:
|
|
1875
|
-
} = u,
|
|
1876
|
-
onMouseEnter:
|
|
1744
|
+
} = a, u = nt(t), {
|
|
1745
|
+
shouldShowAppendedButton: i
|
|
1746
|
+
} = u, d = je(t, e, a), {
|
|
1747
|
+
onMouseEnter: r,
|
|
1877
1748
|
onMouseLeave: m
|
|
1878
|
-
} =
|
|
1879
|
-
|
|
1880
|
-
n.value =
|
|
1881
|
-
}),
|
|
1882
|
-
n.value =
|
|
1883
|
-
}),
|
|
1884
|
-
|
|
1749
|
+
} = d, h = ot(t, e, l, u), v = Xo(t, e), b = Yo(t, e, h, a), F = at(t, e, u, d, h), M = Jo(t, e), C = S(() => t.type === "number");
|
|
1750
|
+
W(() => [t.value], ([w]) => {
|
|
1751
|
+
n.value = w, o.value = w;
|
|
1752
|
+
}), W(() => [t.modelValue], ([w]) => {
|
|
1753
|
+
n.value = w, o.value = w;
|
|
1754
|
+
}), J(() => {
|
|
1755
|
+
t.value && (n.value = t.value, o.value = t.value);
|
|
1885
1756
|
});
|
|
1886
|
-
const
|
|
1887
|
-
id:
|
|
1757
|
+
const R = () => f(ae, null, [f("div", {
|
|
1758
|
+
id: t.id,
|
|
1888
1759
|
class: s.value,
|
|
1889
1760
|
style: c.value,
|
|
1890
|
-
onMouseenter:
|
|
1761
|
+
onMouseenter: r,
|
|
1891
1762
|
onMouseleave: m
|
|
1892
|
-
}, [
|
|
1893
|
-
return () =>
|
|
1763
|
+
}, [C.value ? v() : f(ae, null, [M(), b(), i.value && F()])])]);
|
|
1764
|
+
return () => R();
|
|
1894
1765
|
}
|
|
1895
|
-
}),
|
|
1766
|
+
}), T = {}, B = {}, k = {}, E = {};
|
|
1896
1767
|
let Oe = !1;
|
|
1897
|
-
function
|
|
1898
|
-
Oe || (Oe = !0,
|
|
1768
|
+
function Zo() {
|
|
1769
|
+
Oe || (Oe = !0, Gt.register(T, B, k, E), qt.register(T, B, k, E), Wt.register(T, B, k, E), Ht.register(T, B, k, E), Xt.register(T, B, k, E), Yt.register(T, B, k, E), Jt.register(T, B, k, E), oe.register(T, B, k, E), Qt.register(T, B, k, E), Zt.register(T, B, k, E), Kt.register(T, B, k, E), _t.register(T, B, k, E), en.register(T, B, k, E), tn.register(T, B, k, E), nn.register(T, B, k, E), on.register(T, B, k, E), an.register(T, B, k, E), ln.register(T, B, k, E), sn.register(T, B, k, E), un.register(T, B, k, E), cn.register(T, B, k, E), dn.register(T, B, k, E), mn.register(T, B, k, E), pn.register(T, B, k, E), fn.register(T, B, k, E), vn.register(T, B, k, E), hn.register(T, B, k, E), yn.register(T, B, k, E), At.register(T, B, k, E), gn.register(T, B, k, E), Cn.register(T, B, k, E), bn.register(T, B, k, E), wn.register(T, B, k, E), Mn.register(T, B, k, E), Fn.register(T, B, k, E), xn.register(T, B, k, E), Tn.register(T, B, k, E), kn.register(T, B, k, E), In.register(T, B, k, E), Bn.register(T, B, k, E), Hn.register(T, B, k), En.register(T, B, k, E), Sn.register(T, B, k, E), Ln.register(T, B, k, E), Dn.register(T, B, k, E), Pn.register(T, B, k, E), Vn.register(T, B, k, E), Rn.register(T, B, k, E), Nn.register(T, B, k, E), On.register(T, B, k, E), An.register(T, B, k, E), $n.register(T, B, k, E), Un.register(T, B, k, E), zn.register(T, B, k, E), jn.register(T, B, k, E), qn.register(T, B, k, E), Gn.register(T, B, k, E), Wn.register(T, B, k, E), Xn.register(T, B, k, E), rn.register(T, B, k, E), Yn.register(T, B, k, E));
|
|
1899
1770
|
}
|
|
1900
1771
|
function lt() {
|
|
1901
|
-
|
|
1772
|
+
Zo();
|
|
1773
|
+
function t(a) {
|
|
1774
|
+
return T[a] || Qo;
|
|
1775
|
+
}
|
|
1902
1776
|
function e(a, s) {
|
|
1903
|
-
const l =
|
|
1777
|
+
const l = B[a];
|
|
1904
1778
|
return l ? l(s) : {};
|
|
1905
1779
|
}
|
|
1906
|
-
function t(a) {
|
|
1907
|
-
return S[a] || Jo;
|
|
1908
|
-
}
|
|
1909
1780
|
function n(a) {
|
|
1910
1781
|
switch (a) {
|
|
1911
1782
|
case "check-box":
|
|
@@ -1953,9 +1824,12 @@ function lt() {
|
|
|
1953
1824
|
return "onSavedCommandListChanged";
|
|
1954
1825
|
case "grid-field-editor":
|
|
1955
1826
|
return "onChange";
|
|
1827
|
+
case "item-collection-editor":
|
|
1828
|
+
return "onChange";
|
|
1956
1829
|
case "response-form-layout-setting":
|
|
1957
1830
|
return "onChange";
|
|
1958
1831
|
case "field-selector":
|
|
1832
|
+
case "binding-selector":
|
|
1959
1833
|
return "onFieldSelected";
|
|
1960
1834
|
case "schema-selector":
|
|
1961
1835
|
return "onSchemaSelected";
|
|
@@ -1963,6 +1837,8 @@ function lt() {
|
|
|
1963
1837
|
return "onMappingFieldsChanged";
|
|
1964
1838
|
case "textarea":
|
|
1965
1839
|
return "onValueChange";
|
|
1840
|
+
case "query-solution-config":
|
|
1841
|
+
return "onFieldsChanged";
|
|
1966
1842
|
}
|
|
1967
1843
|
}
|
|
1968
1844
|
function o(a) {
|
|
@@ -1975,181 +1851,145 @@ function lt() {
|
|
|
1975
1851
|
}
|
|
1976
1852
|
return { resolveEditorProps: e, resolveEditorType: t, getChangeFunctionName: n, getClearFunctionName: o };
|
|
1977
1853
|
}
|
|
1978
|
-
const we = /* @__PURE__ */
|
|
1854
|
+
const we = /* @__PURE__ */ X({
|
|
1979
1855
|
name: "FDynamicFormGroup",
|
|
1980
|
-
props:
|
|
1856
|
+
props: le,
|
|
1981
1857
|
emits: ["change", "update:modelValue"],
|
|
1982
|
-
setup(
|
|
1983
|
-
const n =
|
|
1984
|
-
|
|
1985
|
-
const
|
|
1858
|
+
setup(t, e) {
|
|
1859
|
+
const n = p(t.id), o = p(t.customClass), a = p(t.editor), s = p(t.label), l = p(t.modelValue), c = p(t.readonly), u = p(t.required), i = p(t.showLabel), d = p(t.visible);
|
|
1860
|
+
p(t.type);
|
|
1861
|
+
const r = p(), {
|
|
1986
1862
|
resolveEditorProps: m,
|
|
1987
1863
|
resolveEditorType: h,
|
|
1988
|
-
getChangeFunctionName:
|
|
1989
|
-
getClearFunctionName:
|
|
1990
|
-
} = lt(),
|
|
1864
|
+
getChangeFunctionName: v,
|
|
1865
|
+
getClearFunctionName: b
|
|
1866
|
+
} = lt(), F = S(() => ({
|
|
1991
1867
|
"form-group": !0,
|
|
1992
1868
|
"farris-form-group": !0,
|
|
1993
1869
|
"common-group": !0,
|
|
1994
1870
|
"q-state-readonly": c.value
|
|
1995
1871
|
}));
|
|
1996
|
-
function
|
|
1997
|
-
l.value =
|
|
1872
|
+
function M(w, g) {
|
|
1873
|
+
l.value = g !== void 0 ? g : w, e.emit("update:modelValue", l.value), e.emit("change", l.value);
|
|
1998
1874
|
}
|
|
1999
|
-
function
|
|
2000
|
-
|
|
1875
|
+
function C() {
|
|
1876
|
+
e.emit("update:modelValue", "");
|
|
2001
1877
|
}
|
|
2002
|
-
const
|
|
2003
|
-
const
|
|
2004
|
-
return
|
|
2005
|
-
ref:
|
|
2006
|
-
},
|
|
1878
|
+
const R = S(() => {
|
|
1879
|
+
const w = a.value.type || "input-group", g = h(w), L = m(w, a.value), y = v(w), P = b(a.value.type);
|
|
1880
|
+
return P && (L[P] = C), L[y] = M, (L.id == null || L.id === "") && (L.id = n.value), () => f(g, te({
|
|
1881
|
+
ref: r
|
|
1882
|
+
}, L, {
|
|
2007
1883
|
modelValue: l.value,
|
|
2008
|
-
"onUpdate:modelValue": (
|
|
2009
|
-
}),
|
|
1884
|
+
"onUpdate:modelValue": (O) => l.value = O
|
|
1885
|
+
}), e.slots);
|
|
2010
1886
|
});
|
|
2011
|
-
return
|
|
2012
|
-
n.value =
|
|
2013
|
-
}),
|
|
2014
|
-
editorRef:
|
|
2015
|
-
}), () =>
|
|
1887
|
+
return W([() => t.id, () => t.customClass, () => t.editor, () => t.label, () => t.modelValue, () => t.readonly, () => t.required, () => t.showLabel, () => t.visible], ([w, g, L, y, P, O, U, z, H]) => {
|
|
1888
|
+
n.value = w, o.value = g, a.value = L, s.value = y, l.value = P, c.value = O, u.value = U, i.value = z, d.value = H;
|
|
1889
|
+
}), e.expose({
|
|
1890
|
+
editorRef: r
|
|
1891
|
+
}), () => d.value && f("div", {
|
|
2016
1892
|
id: `${n.value}-input-group`,
|
|
2017
|
-
class: o.value
|
|
1893
|
+
class: o.value,
|
|
1894
|
+
style: t.customStyle
|
|
2018
1895
|
}, [f("div", {
|
|
2019
1896
|
class: "farris-group-wrap"
|
|
2020
1897
|
}, [f("div", {
|
|
2021
|
-
class:
|
|
2022
|
-
}, [
|
|
1898
|
+
class: F.value
|
|
1899
|
+
}, [i.value && f(tt, {
|
|
2023
1900
|
id: `${n.value}-lable`,
|
|
2024
1901
|
required: u.value,
|
|
2025
1902
|
text: s.value,
|
|
2026
1903
|
title: s.value
|
|
2027
1904
|
}, null), f("div", {
|
|
2028
1905
|
class: "farris-input-wrap"
|
|
2029
|
-
}, [
|
|
2030
|
-
}
|
|
2031
|
-
}), Zo = {}, Ko = {};
|
|
2032
|
-
function _o(e, t) {
|
|
2033
|
-
e.schema;
|
|
2034
|
-
const n = d(!0), o = d(!0);
|
|
2035
|
-
function a(i) {
|
|
2036
|
-
return !1;
|
|
2037
|
-
}
|
|
2038
|
-
function s() {
|
|
2039
|
-
return !1;
|
|
2040
|
-
}
|
|
2041
|
-
function l() {
|
|
2042
|
-
return !1;
|
|
2043
|
-
}
|
|
2044
|
-
function c() {
|
|
2045
|
-
return !0;
|
|
2046
|
-
}
|
|
2047
|
-
function u(i) {
|
|
2048
|
-
}
|
|
2049
|
-
function r() {
|
|
1906
|
+
}, [R.value()])])])]);
|
|
2050
1907
|
}
|
|
2051
|
-
|
|
2052
|
-
return null;
|
|
2053
|
-
}
|
|
2054
|
-
return {
|
|
2055
|
-
canAccepts: a,
|
|
2056
|
-
checkCanDeleteComponent: s,
|
|
2057
|
-
checkCanMoveComponent: l,
|
|
2058
|
-
hideNestedPaddingInDesginerView: c,
|
|
2059
|
-
onAcceptMovedChildElement: u,
|
|
2060
|
-
resolveComponentContext: r,
|
|
2061
|
-
triggerBelongedComponentToMoveWhenMoved: n,
|
|
2062
|
-
triggerBelongedComponentToDeleteWhenDeleted: o,
|
|
2063
|
-
getPropsConfig: p
|
|
2064
|
-
};
|
|
2065
|
-
}
|
|
2066
|
-
const oe = class oe {
|
|
1908
|
+
}), _o = {}, Ko = {}, K = class K {
|
|
2067
1909
|
/**
|
|
2068
1910
|
* 根据绑定字段类型获取可用的输入类控件
|
|
2069
1911
|
*/
|
|
2070
|
-
static getEditorTypesByMDataType(
|
|
2071
|
-
const n =
|
|
1912
|
+
static getEditorTypesByMDataType(e) {
|
|
1913
|
+
const n = K.fieldControlTypeMapping[e];
|
|
2072
1914
|
return n || [{ key: "", value: "" }];
|
|
2073
1915
|
}
|
|
2074
1916
|
/**
|
|
2075
1917
|
* 获取所有输入类控件
|
|
2076
1918
|
*/
|
|
2077
1919
|
static getAllInputTypes() {
|
|
2078
|
-
const
|
|
2079
|
-
for (
|
|
2080
|
-
|
|
2081
|
-
|
|
1920
|
+
const e = [];
|
|
1921
|
+
for (const n in K.fieldControlTypeMapping)
|
|
1922
|
+
K.fieldControlTypeMapping[n].forEach((o) => {
|
|
1923
|
+
e.find((a) => a.key === o.key && a.value === o.value) || e.push({ key: o.key, value: o.value });
|
|
2082
1924
|
});
|
|
2083
|
-
return
|
|
1925
|
+
return e;
|
|
2084
1926
|
}
|
|
2085
1927
|
};
|
|
2086
1928
|
/**
|
|
2087
1929
|
* <字段类型,可配置的控件类型列表>的映射
|
|
2088
1930
|
*/
|
|
2089
|
-
N(
|
|
1931
|
+
N(K, "fieldControlTypeMapping", {
|
|
2090
1932
|
String: [
|
|
2091
|
-
{ key:
|
|
2092
|
-
{ key:
|
|
2093
|
-
{ key:
|
|
2094
|
-
{ key:
|
|
2095
|
-
{ key:
|
|
2096
|
-
{ key:
|
|
2097
|
-
{ key:
|
|
2098
|
-
{ key:
|
|
1933
|
+
{ key: V["input-group"].type, value: V["input-group"].name },
|
|
1934
|
+
{ key: V.lookup.type, value: V.lookup.name },
|
|
1935
|
+
{ key: V["date-picker"].type, value: V["date-picker"].name },
|
|
1936
|
+
{ key: V["check-box"].type, value: V["check-box"].name },
|
|
1937
|
+
{ key: V["check-group"].type, value: V["check-group"].name },
|
|
1938
|
+
{ key: V["radio-group"].type, value: V["radio-group"].name },
|
|
1939
|
+
{ key: V["combo-list"].type, value: V["combo-list"].name },
|
|
1940
|
+
{ key: V.textarea.type, value: V.textarea.name }
|
|
2099
1941
|
],
|
|
2100
1942
|
Text: [
|
|
2101
|
-
{ key:
|
|
2102
|
-
{ key:
|
|
1943
|
+
{ key: V.textarea.type, value: V.textarea.name },
|
|
1944
|
+
{ key: V.lookup.type, value: V.lookup.name }
|
|
2103
1945
|
],
|
|
2104
1946
|
Decimal: [
|
|
2105
|
-
{ key:
|
|
1947
|
+
{ key: V["number-spinner"].type, value: V["number-spinner"].name }
|
|
2106
1948
|
],
|
|
2107
1949
|
Integer: [
|
|
2108
|
-
{ key:
|
|
1950
|
+
{ key: V["number-spinner"].type, value: V["number-spinner"].name }
|
|
2109
1951
|
],
|
|
2110
1952
|
Number: [
|
|
2111
|
-
{ key:
|
|
1953
|
+
{ key: V["number-spinner"].type, value: V["number-spinner"].name }
|
|
2112
1954
|
],
|
|
2113
1955
|
BigNumber: [
|
|
2114
|
-
{ key:
|
|
1956
|
+
{ key: V["number-spinner"].type, value: V["number-spinner"].name }
|
|
2115
1957
|
],
|
|
2116
1958
|
Date: [
|
|
2117
|
-
{ key:
|
|
1959
|
+
{ key: V["date-picker"].type, value: V["date-picker"].name }
|
|
2118
1960
|
],
|
|
2119
1961
|
DateTime: [
|
|
2120
|
-
{ key:
|
|
1962
|
+
{ key: V["date-picker"].type, value: V["date-picker"].name }
|
|
2121
1963
|
],
|
|
2122
1964
|
Boolean: [
|
|
2123
|
-
{ key:
|
|
2124
|
-
{ key:
|
|
1965
|
+
{ key: V.switch.type, value: V.switch.name },
|
|
1966
|
+
{ key: V["check-box"].type, value: V["check-box"].name }
|
|
2125
1967
|
],
|
|
2126
1968
|
Enum: [
|
|
2127
|
-
{ key:
|
|
2128
|
-
{ key:
|
|
1969
|
+
{ key: V["combo-list"].type, value: V["combo-list"].name },
|
|
1970
|
+
{ key: V["radio-group"].type, value: V["radio-group"].name }
|
|
2129
1971
|
],
|
|
2130
1972
|
Object: [
|
|
2131
|
-
{ key:
|
|
2132
|
-
{ key:
|
|
2133
|
-
{ key:
|
|
1973
|
+
{ key: V.lookup.type, value: V.lookup.name },
|
|
1974
|
+
{ key: V["combo-list"].type, value: V["combo-list"].name },
|
|
1975
|
+
{ key: V["radio-group"].type, value: V["radio-group"].name }
|
|
2134
1976
|
]
|
|
2135
1977
|
});
|
|
2136
|
-
let
|
|
2137
|
-
const ea =
|
|
2138
|
-
class ta extends
|
|
1978
|
+
let de = K;
|
|
1979
|
+
const ea = p(0);
|
|
1980
|
+
class ta extends Je {
|
|
2139
1981
|
constructor(n, o) {
|
|
2140
1982
|
super(n, o);
|
|
2141
1983
|
N(this, "responseLayoutEditorFunction");
|
|
2142
|
-
this.responseLayoutEditorFunction =
|
|
1984
|
+
this.responseLayoutEditorFunction = Qe(this.formSchemaUtils);
|
|
2143
1985
|
}
|
|
2144
1986
|
getPropertyConfig(n, o) {
|
|
2145
1987
|
return this.propertyConfig.categories.basic = this.getBasicProperties(n, o), this.propertyConfig.categories.appearance = this.getAppearanceProperties(n, o), this.propertyConfig.categories.editor = this.getEditorProperties(n), this.propertyConfig;
|
|
2146
1988
|
}
|
|
2147
1989
|
getBasicProperties(n, o) {
|
|
2148
|
-
var
|
|
2149
|
-
|
|
2150
|
-
this.setDesignViewModelField(n)
|
|
2151
|
-
const s = this.formSchemaUtils.getFormMetadataBasicInfo(), l = this.designViewModelUtils.getAllFields2TreeByVMId(this.viewModelId);
|
|
2152
|
-
return {
|
|
1990
|
+
var s;
|
|
1991
|
+
const a = this;
|
|
1992
|
+
return this.setDesignViewModelField(n), this.formSchemaUtils.getFormMetadataBasicInfo(), {
|
|
2153
1993
|
description: "Basic Information",
|
|
2154
1994
|
title: "基本信息",
|
|
2155
1995
|
properties: {
|
|
@@ -2170,7 +2010,7 @@ class ta extends Ye {
|
|
|
2170
2010
|
textField: "value",
|
|
2171
2011
|
valueField: "key",
|
|
2172
2012
|
editable: !1,
|
|
2173
|
-
data: a.designViewModelField ?
|
|
2013
|
+
data: a.designViewModelField ? de.getEditorTypesByMDataType((s = a.designViewModelField.type) == null ? void 0 : s.name) : de.getAllInputTypes()
|
|
2174
2014
|
}
|
|
2175
2015
|
},
|
|
2176
2016
|
label: {
|
|
@@ -2181,33 +2021,29 @@ class ta extends Ye {
|
|
|
2181
2021
|
binding: {
|
|
2182
2022
|
description: "绑定的表单字段",
|
|
2183
2023
|
title: "绑定",
|
|
2184
|
-
$converter: "/converter/field-selector.converter",
|
|
2185
2024
|
editor: {
|
|
2186
|
-
type: "
|
|
2025
|
+
type: "binding-selector",
|
|
2187
2026
|
bindingType: { enable: !1 },
|
|
2188
2027
|
editorParams: {
|
|
2189
|
-
|
|
2190
|
-
|
|
2028
|
+
componentSchema: n,
|
|
2029
|
+
needSyncToViewModel: !0,
|
|
2030
|
+
viewModelId: this.viewModelId,
|
|
2031
|
+
designerHostService: this.designerHostService,
|
|
2032
|
+
disableOccupiedFields: !0
|
|
2191
2033
|
},
|
|
2192
|
-
|
|
2193
|
-
{ field: "name", title: "字段名称" },
|
|
2194
|
-
{ field: "bindingField", title: "绑定字段" },
|
|
2195
|
-
{ field: "fieldType", title: "字段类型" }
|
|
2196
|
-
],
|
|
2197
|
-
textField: "bindingField",
|
|
2198
|
-
data: l
|
|
2034
|
+
textField: "bindingField"
|
|
2199
2035
|
}
|
|
2200
2036
|
}
|
|
2201
2037
|
},
|
|
2202
|
-
setPropertyRelates(
|
|
2203
|
-
if (
|
|
2204
|
-
switch (
|
|
2038
|
+
setPropertyRelates(l, c) {
|
|
2039
|
+
if (l)
|
|
2040
|
+
switch (l && l.propertyID) {
|
|
2205
2041
|
case "type": {
|
|
2206
|
-
a.changeControlType(n,
|
|
2042
|
+
a.changeControlType(n, l, o);
|
|
2207
2043
|
break;
|
|
2208
2044
|
}
|
|
2209
2045
|
case "label": {
|
|
2210
|
-
|
|
2046
|
+
l.needRefreshControlTree = !0;
|
|
2211
2047
|
break;
|
|
2212
2048
|
}
|
|
2213
2049
|
}
|
|
@@ -2215,7 +2051,7 @@ class ta extends Ye {
|
|
|
2215
2051
|
};
|
|
2216
2052
|
}
|
|
2217
2053
|
getAppearanceProperties(n, o) {
|
|
2218
|
-
|
|
2054
|
+
const a = this;
|
|
2219
2055
|
return {
|
|
2220
2056
|
title: "样式",
|
|
2221
2057
|
description: "Appearance",
|
|
@@ -2267,12 +2103,12 @@ class ta extends Ye {
|
|
|
2267
2103
|
* @param newControlType 新控件类型
|
|
2268
2104
|
*/
|
|
2269
2105
|
changeControlType(n, o, a) {
|
|
2270
|
-
var
|
|
2106
|
+
var d, r, m, h;
|
|
2271
2107
|
const s = o.propertyValue, l = a && a.parent && a.parent.schema;
|
|
2272
2108
|
if (!l)
|
|
2273
2109
|
return;
|
|
2274
|
-
const c = l.contents.findIndex((
|
|
2275
|
-
let
|
|
2110
|
+
const c = l.contents.findIndex((v) => v.id === n.id), u = l.contents[c];
|
|
2111
|
+
let i;
|
|
2276
2112
|
this.designViewModelField && (this.designViewModelUtils.getDgViewModel(this.viewModelId).changeField(this.designViewModelField.id, {
|
|
2277
2113
|
editor: {
|
|
2278
2114
|
$type: s
|
|
@@ -2280,21 +2116,21 @@ class ta extends Ye {
|
|
|
2280
2116
|
name: this.designViewModelField.name,
|
|
2281
2117
|
require: this.designViewModelField.require,
|
|
2282
2118
|
readonly: this.designViewModelField.readonly
|
|
2283
|
-
}, !1),
|
|
2119
|
+
}, !1), i = this.controlCreatorUtils.setFormFieldProperty(this.designViewModelField, s)), i || (i = this.controlCreatorUtils.createFormGroupWithoutField(s)), Object.assign(i, {
|
|
2284
2120
|
id: u.id,
|
|
2285
2121
|
appearance: u.appearance,
|
|
2286
2122
|
size: u.size,
|
|
2287
2123
|
label: u.label,
|
|
2288
2124
|
binding: u.binding,
|
|
2289
2125
|
visible: u.visible
|
|
2290
|
-
}), Object.assign(
|
|
2291
|
-
isTextArea:
|
|
2292
|
-
placeholder: (
|
|
2293
|
-
holdPlace: (
|
|
2126
|
+
}), Object.assign(i.editor, {
|
|
2127
|
+
isTextArea: i.isTextArea && u.isTextArea,
|
|
2128
|
+
placeholder: (d = u.editor) == null ? void 0 : d.placeholder,
|
|
2129
|
+
holdPlace: (r = u.editor) == null ? void 0 : r.holdPlace,
|
|
2294
2130
|
readonly: (m = u.editor) == null ? void 0 : m.readonly,
|
|
2295
2131
|
require: (h = u.editor) == null ? void 0 : h.require
|
|
2296
|
-
}), l.contents.splice(c, 1), l.contents.splice(c, 0,
|
|
2297
|
-
(
|
|
2132
|
+
}), l.contents.splice(c, 1), l.contents.splice(c, 0, i), a.schema = Object.assign(u, i), Array.from(document.getElementsByClassName("dgComponentSelected")).forEach(
|
|
2133
|
+
(v) => v.classList.remove("dgComponentSelected")
|
|
2298
2134
|
), ea.value++;
|
|
2299
2135
|
}
|
|
2300
2136
|
getComponentConfig(n, o = {}, a = {}) {
|
|
@@ -2335,16 +2171,16 @@ class ta extends Ye {
|
|
|
2335
2171
|
*/
|
|
2336
2172
|
updateUnifiedLayoutAfterControlChanged(n, o, a) {
|
|
2337
2173
|
const s = n.split(" ");
|
|
2338
|
-
let l = s.find((
|
|
2339
|
-
l = l || "col-12", c = c || "col-md-" + l.replace("col-", ""), u = u || "col-xl-" + c.replace("col-md-", ""),
|
|
2340
|
-
const
|
|
2174
|
+
let l = s.find((r) => /^col-([1-9]|10|11|12)$/.test(r)), c = s.find((r) => /^col-md-([1-9]|10|11|12)$/.test(r)), u = s.find((r) => /^col-xl-([1-9]|10|11|12)$/.test(r)), i = s.find((r) => /^col-el-([1-9]|10|11|12)$/.test(r));
|
|
2175
|
+
l = l || "col-12", c = c || "col-md-" + l.replace("col-", ""), u = u || "col-xl-" + c.replace("col-md-", ""), i = i || "col-el-" + u.replace("col-xl-", "");
|
|
2176
|
+
const d = {
|
|
2341
2177
|
id: o,
|
|
2342
2178
|
columnInSM: parseInt(l.replace("col-", ""), 10),
|
|
2343
2179
|
columnInMD: parseInt(c.replace("col-md-", ""), 10),
|
|
2344
2180
|
columnInLG: parseInt(u.replace("col-xl-", ""), 10),
|
|
2345
|
-
columnInEL: parseInt(
|
|
2181
|
+
columnInEL: parseInt(i.replace("col-el-", ""), 10)
|
|
2346
2182
|
};
|
|
2347
|
-
this.updateUnifiedLayoutAfterResponseLayoutChanged(a,
|
|
2183
|
+
this.updateUnifiedLayoutAfterResponseLayoutChanged(a, d);
|
|
2348
2184
|
}
|
|
2349
2185
|
/**
|
|
2350
2186
|
* 修改控件布局配置后更新Form统一布局配置
|
|
@@ -2357,13 +2193,13 @@ class ta extends Ye {
|
|
|
2357
2193
|
return;
|
|
2358
2194
|
const s = [];
|
|
2359
2195
|
if (this.responseLayoutEditorFunction.getResonseFormLayoutConfig(a, s, 1), o) {
|
|
2360
|
-
const
|
|
2361
|
-
Object.assign(
|
|
2196
|
+
const v = s.find((b) => b.id === o.id);
|
|
2197
|
+
Object.assign(v || {}, o);
|
|
2362
2198
|
}
|
|
2363
|
-
const l = s.map((
|
|
2199
|
+
const l = s.map((v) => v.columnInSM), c = s.map((v) => v.columnInMD), u = s.map((v) => v.columnInLG), i = s.map((v) => v.columnInEL), d = this.checkIsUniqueColumn(l) ? l[0] : null, r = this.checkIsUniqueColumn(c) ? c[0] : null, m = this.checkIsUniqueColumn(u) ? u[0] : null, h = this.checkIsUniqueColumn(i) ? i[0] : null;
|
|
2364
2200
|
Object.assign(a.unifiedLayout, {
|
|
2365
|
-
uniqueColClassInSM:
|
|
2366
|
-
uniqueColClassInMD:
|
|
2201
|
+
uniqueColClassInSM: d,
|
|
2202
|
+
uniqueColClassInMD: r,
|
|
2367
2203
|
uniqueColClassInLG: m,
|
|
2368
2204
|
uniqueColClassInEL: h
|
|
2369
2205
|
});
|
|
@@ -2377,109 +2213,94 @@ class ta extends Ye {
|
|
|
2377
2213
|
}
|
|
2378
2214
|
}
|
|
2379
2215
|
class na extends ta {
|
|
2380
|
-
constructor(
|
|
2381
|
-
super(
|
|
2216
|
+
constructor(e, n) {
|
|
2217
|
+
super(e, n);
|
|
2382
2218
|
}
|
|
2383
2219
|
}
|
|
2384
|
-
function oa(
|
|
2385
|
-
const
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
checkCanMoveComponent: a,
|
|
2389
|
-
hideNestedPaddingInDesginerView: s,
|
|
2390
|
-
onAcceptMovedChildElement: l,
|
|
2391
|
-
resolveComponentContext: c,
|
|
2392
|
-
triggerBelongedComponentToMoveWhenMoved: u,
|
|
2393
|
-
triggerBelongedComponentToDeleteWhenDeleted: r
|
|
2394
|
-
} = _o(e), p = e.schema;
|
|
2395
|
-
function i(m, h) {
|
|
2396
|
-
return new na(m, t).getPropertyConfig(p, h);
|
|
2220
|
+
function oa(t, e) {
|
|
2221
|
+
const n = t.schema;
|
|
2222
|
+
function o(a, s) {
|
|
2223
|
+
return new na(a, e).getPropertyConfig(n, s);
|
|
2397
2224
|
}
|
|
2398
|
-
return {
|
|
2399
|
-
canAccepts: n,
|
|
2400
|
-
checkCanDeleteComponent: o,
|
|
2401
|
-
checkCanMoveComponent: a,
|
|
2402
|
-
hideNestedPaddingInDesginerView: s,
|
|
2403
|
-
onAcceptMovedChildElement: l,
|
|
2404
|
-
resolveComponentContext: c,
|
|
2405
|
-
triggerBelongedComponentToMoveWhenMoved: u,
|
|
2406
|
-
triggerBelongedComponentToDeleteWhenDeleted: r,
|
|
2407
|
-
getPropsConfig: i
|
|
2408
|
-
};
|
|
2225
|
+
return { getPropsConfig: o };
|
|
2409
2226
|
}
|
|
2410
|
-
const aa = /* @__PURE__ */
|
|
2227
|
+
const aa = /* @__PURE__ */ X({
|
|
2411
2228
|
name: "FInputGroupDesign",
|
|
2412
2229
|
props: Ee,
|
|
2413
2230
|
emits: ["updateExtendInfo", "clear", "valueChange", "clickHandle", "blurHandle", "focusHandle", "enterHandle", "iconMouseEnter", "iconMouseLeave", "keyupHandle", "keydownHandle", "inputClick"],
|
|
2414
|
-
setup(
|
|
2415
|
-
const n =
|
|
2231
|
+
setup(t, e) {
|
|
2232
|
+
const n = p(t.modelValue), o = p(t.modelValue), a = Ot(t, e, n, o), {
|
|
2416
2233
|
inputGroupClass: s,
|
|
2417
2234
|
inputType: l,
|
|
2418
2235
|
inputGroupStyle: c
|
|
2419
|
-
} = a, u = nt(
|
|
2420
|
-
shouldShowAppendedButton:
|
|
2421
|
-
} = u,
|
|
2422
|
-
onMouseEnter:
|
|
2236
|
+
} = a, u = nt(t), {
|
|
2237
|
+
shouldShowAppendedButton: i
|
|
2238
|
+
} = u, d = je(t, e, a), {
|
|
2239
|
+
onMouseEnter: r,
|
|
2423
2240
|
onMouseLeave: m
|
|
2424
|
-
} =
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
}),
|
|
2428
|
-
const
|
|
2241
|
+
} = d, h = ot(t, e, l, u), v = p(), b = ee("designer-host-service"), F = ee("design-item-context"), M = oa(F, b), C = Rt(v, F, M);
|
|
2242
|
+
J(() => {
|
|
2243
|
+
v.value.componentInstance = C;
|
|
2244
|
+
}), e.expose(C.value);
|
|
2245
|
+
const R = at(t, e, u, d, h), w = p();
|
|
2429
2246
|
return () => f("div", {
|
|
2430
2247
|
id: "inputGroup",
|
|
2431
|
-
ref:
|
|
2248
|
+
ref: v,
|
|
2432
2249
|
class: s.value,
|
|
2433
2250
|
style: c.value,
|
|
2434
|
-
onMouseenter:
|
|
2251
|
+
onMouseenter: r,
|
|
2435
2252
|
onMouseleave: m
|
|
2436
2253
|
}, [f("input", {
|
|
2437
|
-
ref:
|
|
2254
|
+
ref: w,
|
|
2438
2255
|
class: "form-control",
|
|
2439
2256
|
readonly: !0,
|
|
2440
|
-
placeholder:
|
|
2441
|
-
}, null),
|
|
2257
|
+
placeholder: t.placeholder
|
|
2258
|
+
}, null), i.value && R()]);
|
|
2442
2259
|
}
|
|
2443
2260
|
});
|
|
2444
2261
|
function la() {
|
|
2445
|
-
function
|
|
2446
|
-
const
|
|
2447
|
-
return
|
|
2262
|
+
function t(a, s) {
|
|
2263
|
+
const l = Ko[a];
|
|
2264
|
+
return l ? l(s) : {};
|
|
2265
|
+
}
|
|
2266
|
+
function e(a) {
|
|
2267
|
+
return _o[a] || aa;
|
|
2268
|
+
}
|
|
2269
|
+
function n(a) {
|
|
2448
2270
|
}
|
|
2449
|
-
function
|
|
2450
|
-
return Zo[n] || aa;
|
|
2271
|
+
function o(a) {
|
|
2451
2272
|
}
|
|
2452
|
-
return { resolveEditorProps:
|
|
2273
|
+
return { getChangeFunctionName: n, getClearFunctionName: o, resolveEditorProps: t, resolveEditorType: e };
|
|
2453
2274
|
}
|
|
2454
|
-
const sa = /* @__PURE__ */
|
|
2275
|
+
const sa = /* @__PURE__ */ X({
|
|
2455
2276
|
name: "FDynamicFormGroupDesign",
|
|
2456
|
-
props:
|
|
2277
|
+
props: le,
|
|
2457
2278
|
emits: ["change", "update:modelValue"],
|
|
2458
|
-
setup(
|
|
2459
|
-
const n =
|
|
2460
|
-
|
|
2461
|
-
const
|
|
2462
|
-
resolveEditorProps:
|
|
2279
|
+
setup(t, e) {
|
|
2280
|
+
const n = p(t.id), o = p(t.customClass), a = p(t.editor), s = p(t.label), l = p(t.modelValue), c = p(!0), u = p(t.required), i = p(t.showLabel);
|
|
2281
|
+
p(t.type);
|
|
2282
|
+
const d = p(), {
|
|
2283
|
+
resolveEditorProps: r,
|
|
2463
2284
|
resolveEditorType: m
|
|
2464
|
-
} = la(), h =
|
|
2285
|
+
} = la(), h = S(() => ({
|
|
2465
2286
|
"form-group": !0,
|
|
2466
2287
|
"farris-form-group": !0,
|
|
2467
2288
|
"common-group": !0,
|
|
2468
2289
|
"q-state-readonly": c.value,
|
|
2469
2290
|
"form-group-in-canvas": !0
|
|
2470
|
-
})),
|
|
2471
|
-
const
|
|
2472
|
-
return () => f(
|
|
2473
|
-
ref:
|
|
2474
|
-
},
|
|
2291
|
+
})), v = S(() => {
|
|
2292
|
+
const b = a.value.type || "input-group", F = m(b), M = r(b, a.value);
|
|
2293
|
+
return () => f(F, te({
|
|
2294
|
+
ref: d
|
|
2295
|
+
}, M, {
|
|
2475
2296
|
modelValue: l.value,
|
|
2476
|
-
"onUpdate:modelValue": (
|
|
2297
|
+
"onUpdate:modelValue": (C) => l.value = C
|
|
2477
2298
|
}), null);
|
|
2478
2299
|
});
|
|
2479
|
-
return
|
|
2480
|
-
n.value =
|
|
2481
|
-
}),
|
|
2482
|
-
editorRef:
|
|
2300
|
+
return W([() => t.id, () => t.customClass, () => t.editor, () => t.label, () => t.modelValue, () => t.readonly, () => t.required, () => t.showLabel], ([b, F, M, C, R, w, g, L]) => {
|
|
2301
|
+
n.value = b, o.value = F, a.value = M, s.value = C, l.value = R, c.value = w, u.value = g, i.value = L;
|
|
2302
|
+
}), e.expose({
|
|
2303
|
+
editorRef: d
|
|
2483
2304
|
}), () => f("div", {
|
|
2484
2305
|
id: `${n.value}-input-group`,
|
|
2485
2306
|
class: o.value,
|
|
@@ -2488,28 +2309,69 @@ const sa = /* @__PURE__ */ Y({
|
|
|
2488
2309
|
class: "farris-group-wrap"
|
|
2489
2310
|
}, [f("div", {
|
|
2490
2311
|
class: h.value
|
|
2491
|
-
}, [
|
|
2312
|
+
}, [i.value && f(tt, {
|
|
2492
2313
|
id: `${n.value}-lable`,
|
|
2493
2314
|
required: u.value,
|
|
2494
2315
|
text: s.value,
|
|
2495
2316
|
title: s.value
|
|
2496
2317
|
}, null), f("div", {
|
|
2497
2318
|
class: "farris-input-wrap"
|
|
2498
|
-
}, [
|
|
2319
|
+
}, [v.value()])])])]);
|
|
2320
|
+
}
|
|
2321
|
+
});
|
|
2322
|
+
function ra(t, e) {
|
|
2323
|
+
function n() {
|
|
2324
|
+
return !0;
|
|
2325
|
+
}
|
|
2326
|
+
function o() {
|
|
2327
|
+
return !0;
|
|
2328
|
+
}
|
|
2329
|
+
function a() {
|
|
2330
|
+
return !1;
|
|
2331
|
+
}
|
|
2332
|
+
function s() {
|
|
2333
|
+
return !0;
|
|
2334
|
+
}
|
|
2335
|
+
function l(i) {
|
|
2336
|
+
var b;
|
|
2337
|
+
const d = e == null ? void 0 : e.designViewModelUtils, r = e == null ? void 0 : e.formSchemaUtils, m = (b = t == null ? void 0 : t.componentInstance.value) == null ? void 0 : b.belongedComponentId;
|
|
2338
|
+
if (!m || !d || !r)
|
|
2339
|
+
return;
|
|
2340
|
+
const h = r.getViewModelIdByComponentId(m), v = d.getDgViewModel(h);
|
|
2341
|
+
v && v.removeField([i]);
|
|
2342
|
+
}
|
|
2343
|
+
function c(i) {
|
|
2344
|
+
const d = e == null ? void 0 : e.formSchemaUtils;
|
|
2345
|
+
if (d.getExpressions().length) {
|
|
2346
|
+
const r = d.getExpressions().findIndex((m) => m.fieldId === i);
|
|
2347
|
+
r > -1 && d.getExpressions().splice(r, 1);
|
|
2348
|
+
}
|
|
2349
|
+
}
|
|
2350
|
+
function u() {
|
|
2351
|
+
const { schema: i } = t, d = i.binding && i.binding.field;
|
|
2352
|
+
d && (l(d), c(d));
|
|
2499
2353
|
}
|
|
2500
|
-
|
|
2354
|
+
return {
|
|
2355
|
+
canAccepts: a,
|
|
2356
|
+
checkCanDeleteComponent: o,
|
|
2357
|
+
checkCanMoveComponent: n,
|
|
2358
|
+
hideNestedPaddingInDesginerView: s,
|
|
2359
|
+
onRemoveComponent: u
|
|
2360
|
+
};
|
|
2361
|
+
}
|
|
2362
|
+
const ia = /* @__PURE__ */ X({
|
|
2501
2363
|
name: "FFormGroupDesign",
|
|
2502
|
-
props:
|
|
2364
|
+
props: le,
|
|
2503
2365
|
emits: [],
|
|
2504
|
-
setup(
|
|
2505
|
-
const n =
|
|
2506
|
-
return
|
|
2507
|
-
n.value.componentInstance =
|
|
2508
|
-
var
|
|
2509
|
-
let
|
|
2510
|
-
return
|
|
2366
|
+
setup(t, e) {
|
|
2367
|
+
const n = p(), o = ee("design-item-context"), a = ee("designer-host-service"), s = ra(o, a), l = Ye(n, o, s);
|
|
2368
|
+
return J(() => {
|
|
2369
|
+
n.value.componentInstance = l, l.value.getPropConfig = (...c) => {
|
|
2370
|
+
var i, d, r;
|
|
2371
|
+
let u = Ge[t.editor.type];
|
|
2372
|
+
return u && Object.keys(u).length === 0 && ((i = n.value) != null && i.editorRef) && ((r = (d = n.value) == null ? void 0 : d.editorRef) != null && r.getPropConfig) && (u = n.value.editorRef.getPropConfig(...c, l.value)), u;
|
|
2511
2373
|
};
|
|
2512
|
-
}),
|
|
2374
|
+
}), e.expose(l.value), () => f(sa, te(t, {
|
|
2513
2375
|
ref: n
|
|
2514
2376
|
}), null);
|
|
2515
2377
|
}
|
|
@@ -2527,38 +2389,38 @@ const sa = /* @__PURE__ */ Y({
|
|
|
2527
2389
|
* 作为内嵌编辑器被创建后默认选中文本
|
|
2528
2390
|
*/
|
|
2529
2391
|
selectOnCreated: { type: Boolean, default: !1 }
|
|
2530
|
-
},
|
|
2392
|
+
}, ua = pe(
|
|
2531
2393
|
st,
|
|
2532
2394
|
Xe,
|
|
2533
|
-
|
|
2395
|
+
Ie,
|
|
2534
2396
|
void 0
|
|
2535
|
-
),
|
|
2397
|
+
), ca = /* @__PURE__ */ X({
|
|
2536
2398
|
name: "FDynamicFormInput",
|
|
2537
2399
|
props: st,
|
|
2538
2400
|
emits: ["change", "update:modelValue"],
|
|
2539
|
-
setup(
|
|
2540
|
-
const n =
|
|
2401
|
+
setup(t, e) {
|
|
2402
|
+
const n = p(t.id), o = p(t.editor), a = p(t.modelValue), {
|
|
2541
2403
|
resolveEditorProps: s,
|
|
2542
2404
|
resolveEditorType: l,
|
|
2543
2405
|
getChangeFunctionName: c
|
|
2544
2406
|
} = lt();
|
|
2545
|
-
function u(
|
|
2546
|
-
a.value =
|
|
2407
|
+
function u(d, r) {
|
|
2408
|
+
a.value = r !== void 0 ? r : d, e.emit("update:modelValue", a.value), e.emit("change", a.value);
|
|
2547
2409
|
}
|
|
2548
|
-
const
|
|
2549
|
-
const
|
|
2550
|
-
|
|
2410
|
+
const i = S(() => {
|
|
2411
|
+
const d = l(o.value.type), r = s(o.value.type, o.value);
|
|
2412
|
+
r.focusOnCreated = t.focusOnCreated, r.selectOnCreated = t.selectOnCreated;
|
|
2551
2413
|
const m = c(o.value.type);
|
|
2552
|
-
return
|
|
2414
|
+
return r[m] = u, (r.id == null || r.id === "") && (r.id = n.value), () => f(d, te(r, {
|
|
2553
2415
|
modelValue: a.value,
|
|
2554
2416
|
"onUpdate:modelValue": (h) => a.value = h
|
|
2555
2417
|
}), null);
|
|
2556
2418
|
});
|
|
2557
|
-
return
|
|
2558
|
-
n.value =
|
|
2559
|
-
}), () =>
|
|
2419
|
+
return W([() => t.id, () => t.editor, () => t.modelValue], ([d, r, m]) => {
|
|
2420
|
+
n.value = d, o.value = r, a.value = m;
|
|
2421
|
+
}), () => i.value();
|
|
2560
2422
|
}
|
|
2561
|
-
}),
|
|
2423
|
+
}), da = "https://json-schema.org/draft/2020-12/schema", pa = "https://farris-design.gitee.io/grid-field-editor.schema.json", ma = "response-form-layout-setting", fa = "A Farris Data Grid Component", va = "object", ha = {
|
|
2562
2424
|
id: {
|
|
2563
2425
|
description: "The unique identifier for a Input Group",
|
|
2564
2426
|
type: "string"
|
|
@@ -2578,17 +2440,17 @@ const sa = /* @__PURE__ */ Y({
|
|
|
2578
2440
|
type: "Object",
|
|
2579
2441
|
default: null
|
|
2580
2442
|
}
|
|
2581
|
-
},
|
|
2443
|
+
}, ya = [
|
|
2582
2444
|
"id",
|
|
2583
2445
|
"type"
|
|
2584
2446
|
], ga = {
|
|
2585
|
-
$schema:
|
|
2586
|
-
$id:
|
|
2587
|
-
title:
|
|
2588
|
-
description:
|
|
2589
|
-
type:
|
|
2590
|
-
properties:
|
|
2591
|
-
required:
|
|
2447
|
+
$schema: da,
|
|
2448
|
+
$id: pa,
|
|
2449
|
+
title: ma,
|
|
2450
|
+
description: fa,
|
|
2451
|
+
type: va,
|
|
2452
|
+
properties: ha,
|
|
2453
|
+
required: ya
|
|
2592
2454
|
}, rt = {
|
|
2593
2455
|
initialState: {
|
|
2594
2456
|
type: Object,
|
|
@@ -2599,7 +2461,7 @@ const sa = /* @__PURE__ */ Y({
|
|
|
2599
2461
|
uniqueColClassInEL: 2
|
|
2600
2462
|
}
|
|
2601
2463
|
}
|
|
2602
|
-
},
|
|
2464
|
+
}, Ca = Jn(rt, ga, no, so), ba = {
|
|
2603
2465
|
width: { Type: Number, default: 400 },
|
|
2604
2466
|
type: { Type: String, default: "info" },
|
|
2605
2467
|
title: { Type: String, default: "" },
|
|
@@ -2609,80 +2471,81 @@ const sa = /* @__PURE__ */ Y({
|
|
|
2609
2471
|
exceptionInfo: { Type: Object, default: null },
|
|
2610
2472
|
promptEditorType: { Type: String, default: "text-area" }
|
|
2611
2473
|
};
|
|
2612
|
-
function
|
|
2474
|
+
function Se() {
|
|
2613
2475
|
return new DOMException("The request is not allowed", "NotAllowedError");
|
|
2614
2476
|
}
|
|
2615
|
-
async function
|
|
2477
|
+
async function wa(t) {
|
|
2616
2478
|
if (!navigator.clipboard)
|
|
2617
|
-
throw
|
|
2618
|
-
return navigator.clipboard.writeText(
|
|
2479
|
+
throw Se();
|
|
2480
|
+
return navigator.clipboard.writeText(t);
|
|
2619
2481
|
}
|
|
2620
|
-
async function
|
|
2621
|
-
const
|
|
2622
|
-
|
|
2482
|
+
async function Ma(t) {
|
|
2483
|
+
const e = document.createElement("span");
|
|
2484
|
+
e.textContent = t, e.style.whiteSpace = "pre", e.style.webkitUserSelect = "auto", e.style.userSelect = "all", document.body.appendChild(e);
|
|
2623
2485
|
const n = window.getSelection(), o = window.document.createRange();
|
|
2624
|
-
n == null || n.removeAllRanges(), o.selectNode(
|
|
2486
|
+
n == null || n.removeAllRanges(), o.selectNode(e), n == null || n.addRange(o);
|
|
2625
2487
|
let a = !1;
|
|
2626
2488
|
try {
|
|
2627
2489
|
a = window.document.execCommand("copy");
|
|
2628
2490
|
} finally {
|
|
2629
|
-
n == null || n.removeAllRanges(), window.document.body.removeChild(
|
|
2491
|
+
n == null || n.removeAllRanges(), window.document.body.removeChild(e);
|
|
2630
2492
|
}
|
|
2631
|
-
if (!a)
|
|
2493
|
+
if (!a)
|
|
2494
|
+
throw Se();
|
|
2632
2495
|
}
|
|
2633
|
-
async function
|
|
2496
|
+
async function Fa(t) {
|
|
2634
2497
|
try {
|
|
2635
|
-
await
|
|
2636
|
-
} catch (
|
|
2498
|
+
await wa(t);
|
|
2499
|
+
} catch (e) {
|
|
2637
2500
|
try {
|
|
2638
|
-
await
|
|
2501
|
+
await Ma(t);
|
|
2639
2502
|
} catch (n) {
|
|
2640
|
-
throw n ||
|
|
2503
|
+
throw n || e || Se();
|
|
2641
2504
|
}
|
|
2642
2505
|
}
|
|
2643
2506
|
}
|
|
2644
|
-
function
|
|
2645
|
-
async function e
|
|
2646
|
-
await
|
|
2507
|
+
function xa() {
|
|
2508
|
+
async function t(e) {
|
|
2509
|
+
await Fa(e);
|
|
2647
2510
|
}
|
|
2648
|
-
return { onCopy:
|
|
2511
|
+
return { onCopy: t };
|
|
2649
2512
|
}
|
|
2650
|
-
function Ta(
|
|
2651
|
-
const a =
|
|
2513
|
+
function Ta(t, e, n, o) {
|
|
2514
|
+
const a = p(14), s = p(140), l = p(""), c = p(o.value.length), u = S(() => o.value), i = S(() => ({
|
|
2652
2515
|
"font-size": `${a.value}px`,
|
|
2653
2516
|
height: "100%"
|
|
2654
2517
|
}));
|
|
2655
|
-
function
|
|
2656
|
-
if (
|
|
2657
|
-
const m =
|
|
2518
|
+
function d(r) {
|
|
2519
|
+
if (r.currentTarget) {
|
|
2520
|
+
const m = r.currentTarget.value || "";
|
|
2658
2521
|
c.value = m.length;
|
|
2659
2522
|
}
|
|
2660
2523
|
}
|
|
2661
|
-
return () => f(
|
|
2524
|
+
return () => f(ae, null, [f("textarea", {
|
|
2662
2525
|
title: "promptMessage",
|
|
2663
2526
|
name: "promptMessage",
|
|
2664
2527
|
class: "form-control",
|
|
2665
|
-
style:
|
|
2528
|
+
style: i.value,
|
|
2666
2529
|
rows: "4",
|
|
2667
2530
|
maxlength: s.value,
|
|
2668
|
-
onInput: (
|
|
2531
|
+
onInput: (r) => d(r)
|
|
2669
2532
|
}, [u.value]), f("span", {
|
|
2670
2533
|
class: "textarea-wordcount",
|
|
2671
2534
|
title: l.value,
|
|
2672
2535
|
style: "position: absolute; bottom: 76px; right: 32px; cursor: pointer; text-align: right;"
|
|
2673
2536
|
}, [c.value + " / " + s.value])]);
|
|
2674
2537
|
}
|
|
2675
|
-
function
|
|
2676
|
-
const a = Ta(
|
|
2538
|
+
function Ba(t, e, n, o) {
|
|
2539
|
+
const a = Ta(t, e, n, o), s = /* @__PURE__ */ new Map([["text-area", a]]);
|
|
2677
2540
|
function l(c) {
|
|
2678
2541
|
return s.get(c) || null;
|
|
2679
2542
|
}
|
|
2680
2543
|
return { getEditorRender: l };
|
|
2681
2544
|
}
|
|
2682
|
-
function
|
|
2683
|
-
const
|
|
2545
|
+
function ka() {
|
|
2546
|
+
const t = p(!1), e = p("复制成功");
|
|
2684
2547
|
return {
|
|
2685
|
-
feedbackStyle:
|
|
2548
|
+
feedbackStyle: S(() => {
|
|
2686
2549
|
const o = {
|
|
2687
2550
|
position: "absolute",
|
|
2688
2551
|
left: "50%",
|
|
@@ -2699,41 +2562,41 @@ function Ba() {
|
|
|
2699
2562
|
color: "#fff",
|
|
2700
2563
|
transition: "all .3s ease"
|
|
2701
2564
|
};
|
|
2702
|
-
return o.opacity =
|
|
2565
|
+
return o.opacity = t.value ? "0.8" : "0", o.display = t.value ? "" : "none", o;
|
|
2703
2566
|
}),
|
|
2704
|
-
feedbackMessage:
|
|
2705
|
-
toShowFeedback:
|
|
2567
|
+
feedbackMessage: e,
|
|
2568
|
+
toShowFeedback: t
|
|
2706
2569
|
};
|
|
2707
2570
|
}
|
|
2708
|
-
function
|
|
2709
|
-
const n =
|
|
2571
|
+
function Ia(t, e) {
|
|
2572
|
+
const n = e.getEditorRender(t.promptEditorType);
|
|
2710
2573
|
return () => n && n();
|
|
2711
2574
|
}
|
|
2712
|
-
function
|
|
2713
|
-
const
|
|
2714
|
-
const
|
|
2575
|
+
function Ea(t) {
|
|
2576
|
+
const e = p(3), n = p(480), o = S(() => !!t.value && !!t.value.date), a = S(() => `发生时间 : ${t.value && t.value.date || ""}`), s = S(() => !!t.value && !!t.value.detail), l = S(() => {
|
|
2577
|
+
const F = `${n.value}px`;
|
|
2715
2578
|
return {
|
|
2716
2579
|
overflow: "hidden",
|
|
2717
2580
|
"text-overflow": "ellipsis",
|
|
2718
2581
|
display: "-webkit-box",
|
|
2719
2582
|
"-webkit-box-orient": "vertical",
|
|
2720
|
-
"-webkit-line-clamp":
|
|
2721
|
-
"max-height":
|
|
2583
|
+
"-webkit-line-clamp": e.value,
|
|
2584
|
+
"max-height": F
|
|
2722
2585
|
};
|
|
2723
|
-
}), c =
|
|
2724
|
-
const
|
|
2586
|
+
}), c = S(() => t.value && t.value.detail || ""), u = S(() => !0), i = p(!1), d = p("展开"), r = p("收起"), m = S(() => {
|
|
2587
|
+
const F = {
|
|
2725
2588
|
display: "block",
|
|
2726
2589
|
color: "#2A87FF"
|
|
2727
2590
|
};
|
|
2728
|
-
return
|
|
2591
|
+
return F["text-align"] = i.value ? "" : "right", F;
|
|
2729
2592
|
});
|
|
2730
|
-
function h(
|
|
2731
|
-
|
|
2593
|
+
function h(F, M) {
|
|
2594
|
+
i.value = !i.value, e.value = i.value ? 20 : 3;
|
|
2732
2595
|
}
|
|
2733
|
-
function
|
|
2596
|
+
function v(F) {
|
|
2734
2597
|
return h();
|
|
2735
2598
|
}
|
|
2736
|
-
function
|
|
2599
|
+
function b(F) {
|
|
2737
2600
|
return h();
|
|
2738
2601
|
}
|
|
2739
2602
|
return () => f("div", {
|
|
@@ -2742,36 +2605,36 @@ function Sa(e) {
|
|
|
2742
2605
|
id: "exception_error_msg",
|
|
2743
2606
|
ref: "exceptionMessageRef",
|
|
2744
2607
|
style: l.value
|
|
2745
|
-
}, [
|
|
2608
|
+
}, [Y("详细信息 : "), f("span", {
|
|
2746
2609
|
innerHTML: c.value
|
|
2747
2610
|
}, null)]), u.value && f("span", {
|
|
2748
2611
|
style: m.value
|
|
2749
|
-
}, [
|
|
2750
|
-
onClick:
|
|
2612
|
+
}, [i.value && f("span", {
|
|
2613
|
+
onClick: v,
|
|
2751
2614
|
style: "cursor: pointer;"
|
|
2752
|
-
}, [
|
|
2753
|
-
onClick:
|
|
2615
|
+
}, [r.value]), !i.value && f("span", {
|
|
2616
|
+
onClick: b,
|
|
2754
2617
|
style: "cursor: pointer;"
|
|
2755
|
-
}, [
|
|
2618
|
+
}, [d.value])])]);
|
|
2756
2619
|
}
|
|
2757
|
-
function
|
|
2620
|
+
function Sa(t) {
|
|
2758
2621
|
return () => f("p", {
|
|
2759
2622
|
class: "toast-msg-detail",
|
|
2760
|
-
innerHTML:
|
|
2623
|
+
innerHTML: t.value
|
|
2761
2624
|
}, null);
|
|
2762
2625
|
}
|
|
2763
|
-
function
|
|
2764
|
-
const a =
|
|
2626
|
+
function La(t, e, n, o) {
|
|
2627
|
+
const a = p(t.exceptionInfo), s = S(() => {
|
|
2765
2628
|
const m = {
|
|
2766
2629
|
"f-icon": !0
|
|
2767
|
-
}, h = `f-icon-${
|
|
2630
|
+
}, h = `f-icon-${e.value}`;
|
|
2768
2631
|
return m[h] = !0, m;
|
|
2769
|
-
}), l =
|
|
2770
|
-
function
|
|
2771
|
-
return
|
|
2632
|
+
}), l = S(() => n.value || a.value && a.value.message), c = S(() => o.value), u = S(() => !!o.value), i = S(() => !!a.value);
|
|
2633
|
+
function d() {
|
|
2634
|
+
return i.value ? Ea(a) : u.value ? Sa(c) : () => null;
|
|
2772
2635
|
}
|
|
2773
|
-
const
|
|
2774
|
-
return () => f(
|
|
2636
|
+
const r = d();
|
|
2637
|
+
return () => f(ae, null, [f("div", {
|
|
2775
2638
|
class: "float-left modal-tips-iconwrap"
|
|
2776
2639
|
}, [f("span", {
|
|
2777
2640
|
class: s.value
|
|
@@ -2780,20 +2643,20 @@ function Ea(e, t, n, o) {
|
|
|
2780
2643
|
}, [f("p", {
|
|
2781
2644
|
class: "toast-msg-title",
|
|
2782
2645
|
innerHTML: l.value
|
|
2783
|
-
}, null),
|
|
2646
|
+
}, null), r()])]);
|
|
2784
2647
|
}
|
|
2785
|
-
function
|
|
2648
|
+
function Da(t, e, n) {
|
|
2786
2649
|
const {
|
|
2787
2650
|
onCopy: o
|
|
2788
|
-
} =
|
|
2651
|
+
} = e, {
|
|
2789
2652
|
toShowFeedback: a
|
|
2790
|
-
} = n, s =
|
|
2653
|
+
} = n, s = p("复制成功"), l = p("复制详细信息"), c = p(t.exceptionInfo || {
|
|
2791
2654
|
date: "",
|
|
2792
2655
|
message: "",
|
|
2793
2656
|
detail: ""
|
|
2794
|
-
}), u =
|
|
2795
|
-
function
|
|
2796
|
-
o(u.value).catch((
|
|
2657
|
+
}), u = S(() => c.value && c.value.detail || "");
|
|
2658
|
+
function i(d) {
|
|
2659
|
+
o(u.value).catch((r) => {
|
|
2797
2660
|
s.value = "复制失败";
|
|
2798
2661
|
}).finally(() => {
|
|
2799
2662
|
a.value = !0, setTimeout(() => {
|
|
@@ -2804,77 +2667,77 @@ function La(e, t, n) {
|
|
|
2804
2667
|
return () => f("span", {
|
|
2805
2668
|
style: "width: 100%;color: #2A87FF;padding-left: 37px;"
|
|
2806
2669
|
}, [f("span", {
|
|
2807
|
-
onClick:
|
|
2670
|
+
onClick: i,
|
|
2808
2671
|
style: "cursor: pointer;"
|
|
2809
2672
|
}, [l.value])]);
|
|
2810
2673
|
}
|
|
2811
|
-
function
|
|
2812
|
-
const a =
|
|
2813
|
-
function
|
|
2814
|
-
a.value === "question" &&
|
|
2674
|
+
function Pa(t, e, n, o) {
|
|
2675
|
+
const a = p(t.type), s = p([]), l = p(t.exceptionInfo), c = p(t.okButtonText), u = p(t.cancelButtonText), i = p(!0), d = p(!0), r = S(() => !!(s.value && s.value.length)), m = S(() => l.value && l.value.date && l.value.message && l.value.detail), h = S(() => !(s.value && s.value.length) && (c.value || u.value)), v = S(() => d.value && c.value), b = S(() => i.value && u.value), F = Da(t, n, o);
|
|
2676
|
+
function M(R) {
|
|
2677
|
+
a.value === "question" && e.emit("reject"), e.emit("close");
|
|
2815
2678
|
}
|
|
2816
|
-
function
|
|
2817
|
-
a.value === "question" &&
|
|
2679
|
+
function C(R) {
|
|
2680
|
+
a.value === "question" && e.emit("accept"), e.emit("close");
|
|
2818
2681
|
}
|
|
2819
2682
|
return () => f("div", {
|
|
2820
2683
|
class: "modal-footer"
|
|
2821
|
-
}, [m.value &&
|
|
2684
|
+
}, [m.value && F(), h.value && b.value && f("button", {
|
|
2822
2685
|
type: "button",
|
|
2823
2686
|
class: "btn btn-secondary btn-lg",
|
|
2824
|
-
onClick:
|
|
2825
|
-
}, [u.value]), h.value &&
|
|
2687
|
+
onClick: M
|
|
2688
|
+
}, [u.value]), h.value && v.value && f("button", {
|
|
2826
2689
|
type: "button",
|
|
2827
2690
|
class: "btn btn-primary btn-lg",
|
|
2828
|
-
onClick:
|
|
2829
|
-
}, [c.value]),
|
|
2691
|
+
onClick: C
|
|
2692
|
+
}, [c.value]), r.value && s.value.length && s.value.map((R) => f("button", {
|
|
2830
2693
|
type: "button",
|
|
2831
|
-
onClick:
|
|
2832
|
-
class:
|
|
2833
|
-
}, [
|
|
2834
|
-
class:
|
|
2835
|
-
}, null),
|
|
2694
|
+
onClick: R.handle,
|
|
2695
|
+
class: R.class
|
|
2696
|
+
}, [R.iconClass && f("span", {
|
|
2697
|
+
class: R.iconClass
|
|
2698
|
+
}, null), R.text]))]);
|
|
2836
2699
|
}
|
|
2837
|
-
const
|
|
2700
|
+
const ue = /* @__PURE__ */ X({
|
|
2838
2701
|
name: "FMessageBox",
|
|
2839
|
-
props:
|
|
2702
|
+
props: ba,
|
|
2840
2703
|
emits: ["accept", "reject", "close"],
|
|
2841
|
-
setup(
|
|
2842
|
-
const n =
|
|
2843
|
-
const
|
|
2704
|
+
setup(t, e) {
|
|
2705
|
+
const n = p(t.type), o = p(t.title), a = p(t.detail), s = S(() => {
|
|
2706
|
+
const F = {
|
|
2844
2707
|
"modal-tips": !0,
|
|
2845
2708
|
"d-flex": !0,
|
|
2846
2709
|
"flex-row": !0
|
|
2847
|
-
},
|
|
2848
|
-
return
|
|
2849
|
-
}), l =
|
|
2850
|
-
const
|
|
2851
|
-
return n.value === "prompt" ?
|
|
2852
|
-
}), c =
|
|
2853
|
-
feedbackStyle:
|
|
2854
|
-
feedbackMessage:
|
|
2855
|
-
} =
|
|
2710
|
+
}, M = `messager-type-${n.value}`;
|
|
2711
|
+
return F[M] = !0, F;
|
|
2712
|
+
}), l = S(() => {
|
|
2713
|
+
const F = {};
|
|
2714
|
+
return n.value === "prompt" ? F.padding = "0.5rem 0.5rem 1rem 1.5rem" : n.value === "error" && (F.padding = "0.5rem 1.5rem 1rem 1.5rem"), F;
|
|
2715
|
+
}), c = xa(), u = Ba(t, n, o, a), i = ka(), {
|
|
2716
|
+
feedbackStyle: d,
|
|
2717
|
+
feedbackMessage: r
|
|
2718
|
+
} = i;
|
|
2856
2719
|
function m() {
|
|
2857
2720
|
return f("div", {
|
|
2858
|
-
style:
|
|
2859
|
-
}, [
|
|
2721
|
+
style: d.value
|
|
2722
|
+
}, [r.value]);
|
|
2860
2723
|
}
|
|
2861
2724
|
function h() {
|
|
2862
2725
|
switch (n.value) {
|
|
2863
2726
|
case "prompt":
|
|
2864
|
-
return
|
|
2727
|
+
return Ia(t, u);
|
|
2865
2728
|
default:
|
|
2866
|
-
return
|
|
2729
|
+
return La(t, n, o, a);
|
|
2867
2730
|
}
|
|
2868
2731
|
}
|
|
2869
|
-
const
|
|
2732
|
+
const v = h(), b = Pa(t, e, c, i);
|
|
2870
2733
|
return () => f("div", {
|
|
2871
2734
|
class: "farris-messager"
|
|
2872
2735
|
}, [f("section", {
|
|
2873
2736
|
class: s.value,
|
|
2874
2737
|
style: l.value
|
|
2875
|
-
}, [
|
|
2738
|
+
}, [v()]), b(), m()]);
|
|
2876
2739
|
}
|
|
2877
|
-
}),
|
|
2740
|
+
}), Va = {
|
|
2878
2741
|
/**
|
|
2879
2742
|
* 自定义类
|
|
2880
2743
|
*/
|
|
@@ -2935,37 +2798,37 @@ const de = /* @__PURE__ */ Y({
|
|
|
2935
2798
|
enableEsc: { type: Boolean, default: !0 },
|
|
2936
2799
|
enableEnter: { type: Boolean, default: !1 }
|
|
2937
2800
|
};
|
|
2938
|
-
class
|
|
2939
|
-
constructor(
|
|
2940
|
-
this.x =
|
|
2801
|
+
class q {
|
|
2802
|
+
constructor(e, n) {
|
|
2803
|
+
this.x = e, this.y = n;
|
|
2941
2804
|
}
|
|
2942
|
-
static getTransformInfo(
|
|
2943
|
-
const o = window.getComputedStyle(
|
|
2805
|
+
static getTransformInfo(e) {
|
|
2806
|
+
const o = window.getComputedStyle(e).getPropertyValue("transform").replace(/[^-\d,]/g, "").split(",");
|
|
2944
2807
|
if (o.length >= 6) {
|
|
2945
2808
|
const a = parseInt(o[4], 10), s = parseInt(o[5], 10);
|
|
2946
2809
|
return { x: a, y: s };
|
|
2947
2810
|
}
|
|
2948
2811
|
return { x: 0, y: 0 };
|
|
2949
2812
|
}
|
|
2950
|
-
static fromEvent(
|
|
2951
|
-
if (this.isMouseEvent(
|
|
2952
|
-
return new
|
|
2953
|
-
if (n === null ||
|
|
2954
|
-
return new
|
|
2955
|
-
for (let o = 0; o <
|
|
2956
|
-
if (
|
|
2957
|
-
return new
|
|
2813
|
+
static fromEvent(e, n = null) {
|
|
2814
|
+
if (this.isMouseEvent(e))
|
|
2815
|
+
return new q(e.clientX, e.clientY);
|
|
2816
|
+
if (n === null || e.changedTouches.length === 1)
|
|
2817
|
+
return new q(e.changedTouches[0].clientX, e.changedTouches[0].clientY);
|
|
2818
|
+
for (let o = 0; o < e.changedTouches.length; o++)
|
|
2819
|
+
if (e.changedTouches[o].target === n)
|
|
2820
|
+
return new q(e.changedTouches[o].clientX, e.changedTouches[o].clientY);
|
|
2958
2821
|
}
|
|
2959
|
-
static isMouseEvent(
|
|
2960
|
-
return Object.prototype.toString.apply(
|
|
2822
|
+
static isMouseEvent(e) {
|
|
2823
|
+
return Object.prototype.toString.apply(e).indexOf("MouseEvent") === 8;
|
|
2961
2824
|
}
|
|
2962
|
-
static isIPosition(
|
|
2963
|
-
return !!
|
|
2825
|
+
static isIPosition(e) {
|
|
2826
|
+
return !!e && "x" in e && "y" in e;
|
|
2964
2827
|
}
|
|
2965
|
-
static getCurrent(
|
|
2966
|
-
const n = new
|
|
2828
|
+
static getCurrent(e) {
|
|
2829
|
+
const n = new q(0, 0);
|
|
2967
2830
|
if (window) {
|
|
2968
|
-
const o = window.getComputedStyle(
|
|
2831
|
+
const o = window.getComputedStyle(e);
|
|
2969
2832
|
if (o) {
|
|
2970
2833
|
const a = parseInt(o.getPropertyValue("left"), 10), s = parseInt(o.getPropertyValue("top"), 10);
|
|
2971
2834
|
n.x = isNaN(a) ? 0 : a, n.y = isNaN(s) ? 0 : s;
|
|
@@ -2974,655 +2837,655 @@ class G {
|
|
|
2974
2837
|
}
|
|
2975
2838
|
return null;
|
|
2976
2839
|
}
|
|
2977
|
-
static copy(
|
|
2978
|
-
return new
|
|
2840
|
+
static copy(e) {
|
|
2841
|
+
return new q(0, 0).set(e);
|
|
2979
2842
|
}
|
|
2980
2843
|
get value() {
|
|
2981
2844
|
return { x: this.x, y: this.y };
|
|
2982
2845
|
}
|
|
2983
|
-
add(
|
|
2984
|
-
return this.x +=
|
|
2846
|
+
add(e) {
|
|
2847
|
+
return this.x += e.x, this.y += e.y, this;
|
|
2985
2848
|
}
|
|
2986
|
-
subtract(
|
|
2987
|
-
return this.x -=
|
|
2849
|
+
subtract(e) {
|
|
2850
|
+
return this.x -= e.x, this.y -= e.y, this;
|
|
2988
2851
|
}
|
|
2989
|
-
multiply(
|
|
2990
|
-
this.x *=
|
|
2852
|
+
multiply(e) {
|
|
2853
|
+
this.x *= e, this.y *= e;
|
|
2991
2854
|
}
|
|
2992
|
-
divide(
|
|
2993
|
-
this.x /=
|
|
2855
|
+
divide(e) {
|
|
2856
|
+
this.x /= e, this.y /= e;
|
|
2994
2857
|
}
|
|
2995
2858
|
reset() {
|
|
2996
2859
|
return this.x = 0, this.y = 0, this;
|
|
2997
2860
|
}
|
|
2998
|
-
set(
|
|
2999
|
-
return this.x =
|
|
2861
|
+
set(e) {
|
|
2862
|
+
return this.x = e.x, this.y = e.y, this;
|
|
3000
2863
|
}
|
|
3001
2864
|
}
|
|
3002
|
-
class
|
|
3003
|
-
constructor(
|
|
3004
|
-
this.width =
|
|
2865
|
+
class _ {
|
|
2866
|
+
constructor(e, n) {
|
|
2867
|
+
this.width = e, this.height = n;
|
|
3005
2868
|
}
|
|
3006
|
-
static getCurrent(
|
|
3007
|
-
const n = new
|
|
2869
|
+
static getCurrent(e) {
|
|
2870
|
+
const n = new _(0, 0);
|
|
3008
2871
|
if (window) {
|
|
3009
|
-
const o = window.getComputedStyle(
|
|
2872
|
+
const o = window.getComputedStyle(e);
|
|
3010
2873
|
return o && (n.width = parseInt(o.getPropertyValue("width"), 10), n.height = parseInt(o.getPropertyValue("height"), 10)), n;
|
|
3011
2874
|
}
|
|
3012
2875
|
return null;
|
|
3013
2876
|
}
|
|
3014
|
-
static copy(
|
|
3015
|
-
return new
|
|
2877
|
+
static copy(e) {
|
|
2878
|
+
return new _(0, 0).set(e);
|
|
3016
2879
|
}
|
|
3017
|
-
set(
|
|
3018
|
-
return this.width =
|
|
2880
|
+
set(e) {
|
|
2881
|
+
return this.width = e.width, this.height = e.height, this;
|
|
3019
2882
|
}
|
|
3020
2883
|
}
|
|
3021
|
-
function
|
|
3022
|
-
const n =
|
|
3023
|
-
function
|
|
3024
|
-
const
|
|
3025
|
-
if (!
|
|
2884
|
+
function Ra(t, e) {
|
|
2885
|
+
const n = p(), o = p(), a = p(), s = p(), l = p(), c = p(), u = p(), i = p(), d = p(), r = p(), m = p(), h = p(), v = p(t.draggable), b = p(!1);
|
|
2886
|
+
function F() {
|
|
2887
|
+
const I = o.value || document.body, D = window.getComputedStyle(I);
|
|
2888
|
+
if (!D || !n.value)
|
|
3026
2889
|
return;
|
|
3027
|
-
const $ =
|
|
3028
|
-
u.value && (
|
|
3029
|
-
const
|
|
3030
|
-
|
|
2890
|
+
const $ = q.getTransformInfo(n.value), A = {};
|
|
2891
|
+
u.value && (A.deltaL = n.value.offsetLeft - u.value.x, A.deltaT = n.value.offsetTop - u.value.y);
|
|
2892
|
+
const G = D.getPropertyValue("position");
|
|
2893
|
+
A.width = I.clientWidth, A.height = I.clientHeight, A.pr = parseInt(D.getPropertyValue("padding-right"), 10), A.pb = parseInt(D.getPropertyValue("padding-bottom"), 10), A.position = D.getPropertyValue("position"), G === "static" && (I.style.position = "relative"), A.translateX = $.x, A.translateY = $.y, r.value = A;
|
|
3031
2894
|
}
|
|
3032
|
-
function
|
|
2895
|
+
function M(I) {
|
|
3033
2896
|
if (n.value) {
|
|
3034
|
-
s.value =
|
|
3035
|
-
const
|
|
3036
|
-
|
|
3037
|
-
n: !!
|
|
3038
|
-
s: !!
|
|
3039
|
-
w: !!
|
|
3040
|
-
e: !!
|
|
2897
|
+
s.value = _.getCurrent(n.value), l.value = q.getCurrent(n.value), c.value = s.value ? _.copy(s.value) : null, u.value = l.value ? q.copy(l.value) : null, F();
|
|
2898
|
+
const D = I.target.getAttribute("type") || "";
|
|
2899
|
+
i.value = {
|
|
2900
|
+
n: !!D.match(/n/),
|
|
2901
|
+
s: !!D.match(/s/),
|
|
2902
|
+
w: !!D.match(/w/),
|
|
2903
|
+
e: !!D.match(/e/)
|
|
3041
2904
|
};
|
|
3042
2905
|
}
|
|
3043
2906
|
}
|
|
3044
|
-
function
|
|
3045
|
-
var
|
|
2907
|
+
function C() {
|
|
2908
|
+
var I, D, $, A;
|
|
3046
2909
|
if (n.value) {
|
|
3047
|
-
const
|
|
3048
|
-
|
|
2910
|
+
const G = n.value;
|
|
2911
|
+
i.value && ((i.value.n || i.value.s) && ((I = c.value) != null && I.height) && (G.style.height = c.value.height + "px"), (i.value.w || i.value.e) && ((D = c.value) != null && D.width) && (G.style.width = c.value.width + "px"), u.value && (($ = u.value) != null && $.x && (G.style.left = u.value.x + "px"), (A = u.value) != null && A.y && (G.style.top = u.value.y + "px")));
|
|
3049
2912
|
}
|
|
3050
2913
|
}
|
|
3051
|
-
function
|
|
3052
|
-
const
|
|
3053
|
-
c.value && u.value &&
|
|
2914
|
+
function R() {
|
|
2915
|
+
const I = t.minHeight ? t.minHeight : 1, D = t.minWidth ? t.minWidth : 1;
|
|
2916
|
+
c.value && u.value && i.value && s.value && (c.value.height < I && (c.value.height = I, i.value.n && l.value && (u.value.y = l.value.y + (s.value.height - I))), c.value.width < D && (c.value.width = D, i.value.w && l.value && (u.value.x = l.value.x + (s.value.width - D))), t.maxHeight && c.value.height > t.maxHeight && (c.value.height = t.maxHeight, l.value && i.value.n && (u.value.y = l.value.y + (s.value.height - t.maxHeight))), t.maxWidth && c.value.width > t.maxWidth && (c.value.width = t.maxWidth, i.value.w && l.value && (u.value.x = l.value.x + (s.value.width - t.maxWidth))));
|
|
3054
2917
|
}
|
|
3055
|
-
function
|
|
2918
|
+
function w() {
|
|
3056
2919
|
if (o.value) {
|
|
3057
|
-
const
|
|
3058
|
-
if (u.value && c.value &&
|
|
3059
|
-
const
|
|
3060
|
-
|
|
2920
|
+
const I = r.value;
|
|
2921
|
+
if (u.value && c.value && i.value && s.value) {
|
|
2922
|
+
const D = I.width - I.pr - I.deltaL - I.translateX - u.value.x, $ = I.height - I.pb - I.deltaT - I.translateY - u.value.y;
|
|
2923
|
+
i.value.n && u.value.y + I.translateY < 0 && l.value && (u.value.y = -I.translateY, c.value.height = s.value.height + l.value.y + I.translateY), i.value.w && u.value.x + I.translateX < 0 && l.value && (u.value.x = -I.translateX, c.value.width = s.value.width + l.value.x + I.translateX), c.value.width > D && (c.value.width = D), c.value.height > $ && (c.value.height = $);
|
|
3061
2924
|
}
|
|
3062
2925
|
}
|
|
3063
2926
|
}
|
|
3064
|
-
function
|
|
3065
|
-
if (!a.value || !s.value || !l.value || !
|
|
2927
|
+
function g(I) {
|
|
2928
|
+
if (!a.value || !s.value || !l.value || !i.value)
|
|
3066
2929
|
return;
|
|
3067
|
-
|
|
3068
|
-
const
|
|
3069
|
-
|
|
2930
|
+
I.subtract(a.value);
|
|
2931
|
+
const D = I.x, $ = I.y;
|
|
2932
|
+
i.value.n ? (u.value.y = l.value.y + $, c.value.height = s.value.height - $) : i.value.s && (c.value.height = s.value.height + $), i.value.e ? c.value.width = s.value.width + D : i.value.w && (c.value.width = s.value.width - D, u.value.x = l.value.x + D), w(), R(), C();
|
|
3070
2933
|
}
|
|
3071
|
-
function
|
|
3072
|
-
if (!
|
|
2934
|
+
function L(I) {
|
|
2935
|
+
if (!d.value)
|
|
3073
2936
|
return;
|
|
3074
|
-
const
|
|
3075
|
-
|
|
2937
|
+
const D = q.fromEvent(I);
|
|
2938
|
+
D && g(D);
|
|
3076
2939
|
}
|
|
3077
|
-
function
|
|
2940
|
+
function y() {
|
|
3078
2941
|
if (n.value) {
|
|
3079
2942
|
const {
|
|
3080
|
-
width:
|
|
3081
|
-
height:
|
|
2943
|
+
width: I,
|
|
2944
|
+
height: D,
|
|
3082
2945
|
x: $,
|
|
3083
|
-
y:
|
|
3084
|
-
} = n.value.getBoundingClientRect(),
|
|
2946
|
+
y: A
|
|
2947
|
+
} = n.value.getBoundingClientRect(), G = q.getTransformInfo(n.value);
|
|
3085
2948
|
return {
|
|
3086
2949
|
size: {
|
|
3087
|
-
width:
|
|
3088
|
-
height:
|
|
2950
|
+
width: I,
|
|
2951
|
+
height: D
|
|
3089
2952
|
},
|
|
3090
2953
|
position: {
|
|
3091
|
-
x: $ -
|
|
3092
|
-
y:
|
|
2954
|
+
x: $ - G.x,
|
|
2955
|
+
y: A - G.y
|
|
3093
2956
|
}
|
|
3094
2957
|
};
|
|
3095
2958
|
}
|
|
3096
2959
|
return null;
|
|
3097
2960
|
}
|
|
3098
|
-
function
|
|
2961
|
+
function P(I) {
|
|
3099
2962
|
if (n.value) {
|
|
3100
|
-
const
|
|
3101
|
-
m.value =
|
|
2963
|
+
const D = y();
|
|
2964
|
+
m.value = D;
|
|
3102
2965
|
}
|
|
3103
|
-
a.value = void 0, s.value = null, l.value = null, c.value = null, u.value = null,
|
|
2966
|
+
a.value = void 0, s.value = null, l.value = null, c.value = null, u.value = null, i.value = null, d.value = null, document.removeEventListener("mousemove", L), document.removeEventListener("mouseup", P);
|
|
3104
2967
|
}
|
|
3105
|
-
function
|
|
3106
|
-
document.addEventListener("mousemove",
|
|
2968
|
+
function O() {
|
|
2969
|
+
document.addEventListener("mousemove", L), document.addEventListener("mouseup", P);
|
|
3107
2970
|
}
|
|
3108
|
-
function
|
|
3109
|
-
|
|
2971
|
+
function U(I) {
|
|
2972
|
+
I instanceof MouseEvent && I.button === 2 || v.value && (I.stopPropagation(), I.preventDefault(), a.value = q.fromEvent(I), d.value = I.target, M(I), O());
|
|
3110
2973
|
}
|
|
3111
|
-
function
|
|
3112
|
-
return n.value =
|
|
2974
|
+
function z(I) {
|
|
2975
|
+
return n.value = I, f(ae, null, [f("div", {
|
|
3113
2976
|
class: "fv-resizable-handle fv-resizable-n",
|
|
3114
2977
|
type: "n",
|
|
3115
|
-
onMousedown: (
|
|
2978
|
+
onMousedown: (D) => U(D)
|
|
3116
2979
|
}, null), f("div", {
|
|
3117
2980
|
class: "fv-resizable-handle fv-resizable-e",
|
|
3118
2981
|
type: "e",
|
|
3119
|
-
onMousedown: (
|
|
2982
|
+
onMousedown: (D) => U(D)
|
|
3120
2983
|
}, null), f("div", {
|
|
3121
2984
|
class: "fv-resizable-handle fv-resizable-s",
|
|
3122
2985
|
type: "s",
|
|
3123
|
-
onMousedown: (
|
|
2986
|
+
onMousedown: (D) => U(D)
|
|
3124
2987
|
}, null), f("div", {
|
|
3125
2988
|
class: "fv-resizable-handle fv-resizable-w",
|
|
3126
2989
|
type: "w",
|
|
3127
|
-
onMousedown: (
|
|
2990
|
+
onMousedown: (D) => U(D)
|
|
3128
2991
|
}, null), f("div", {
|
|
3129
2992
|
class: "fv-resizable-handle fv-resizable-ne",
|
|
3130
2993
|
type: "ne",
|
|
3131
|
-
onMousedown: (
|
|
2994
|
+
onMousedown: (D) => U(D)
|
|
3132
2995
|
}, null), f("div", {
|
|
3133
2996
|
class: "fv-resizable-handle fv-resizable-se fv-resizable-diagonal",
|
|
3134
2997
|
type: "se",
|
|
3135
|
-
onMousedown: (
|
|
2998
|
+
onMousedown: (D) => U(D)
|
|
3136
2999
|
}, null), f("div", {
|
|
3137
3000
|
class: "fv-resizable-handle fv-resizable-sw",
|
|
3138
3001
|
type: "sw",
|
|
3139
|
-
onMousedown: (
|
|
3002
|
+
onMousedown: (D) => U(D)
|
|
3140
3003
|
}, null), f("div", {
|
|
3141
3004
|
class: "fv-resizable-handle fv-resizable-nw",
|
|
3142
3005
|
type: "nw",
|
|
3143
|
-
onMousedown: (
|
|
3006
|
+
onMousedown: (D) => U(D)
|
|
3144
3007
|
}, null)]);
|
|
3145
3008
|
}
|
|
3146
|
-
function
|
|
3147
|
-
const
|
|
3148
|
-
|
|
3009
|
+
function H(I = !0) {
|
|
3010
|
+
const D = o.value || document.body, $ = _.getCurrent(D), A = n.value;
|
|
3011
|
+
I && (h.value = y(), h.value.transform = A.style.transform), $ && A && (c.value = $, A.style.height = c.value.height - 14 + "px", A.style.width = c.value.width - 14 + "px", A.style.left = "7px", A.style.top = "7px", A.style.transform = "", m.value = {
|
|
3149
3012
|
size: c.value,
|
|
3150
3013
|
position: {
|
|
3151
3014
|
x: 0,
|
|
3152
3015
|
y: 0
|
|
3153
3016
|
}
|
|
3154
|
-
},
|
|
3017
|
+
}, v.value = !1, b.value = !0);
|
|
3155
3018
|
}
|
|
3156
|
-
function
|
|
3157
|
-
var
|
|
3019
|
+
function se() {
|
|
3020
|
+
var I, D;
|
|
3158
3021
|
if (h.value) {
|
|
3159
3022
|
const $ = {
|
|
3160
3023
|
width: h.value.size.width || 0,
|
|
3161
3024
|
height: h.value.size.height || 0
|
|
3162
|
-
},
|
|
3025
|
+
}, A = {
|
|
3163
3026
|
x: (window.innerWidth - $.width) / 2,
|
|
3164
3027
|
y: (window.innerHeight - $.height) / 2
|
|
3165
3028
|
};
|
|
3166
|
-
(
|
|
3167
|
-
const
|
|
3168
|
-
|
|
3029
|
+
(I = c.value) == null || I.set($), (D = u.value) == null || D.set(A);
|
|
3030
|
+
const G = n.value;
|
|
3031
|
+
G.style.height = $.height + "px", G.style.width = $.width + "px", G.style.left = `${A.x}px`, G.style.top = `${A.y}px`, G.style.transform = "", m.value = {
|
|
3169
3032
|
size: $,
|
|
3170
|
-
position:
|
|
3171
|
-
},
|
|
3033
|
+
position: A
|
|
3034
|
+
}, v.value = t.draggable, b.value = !1;
|
|
3172
3035
|
}
|
|
3173
3036
|
}
|
|
3174
|
-
function
|
|
3037
|
+
function me() {
|
|
3175
3038
|
if (n.value) {
|
|
3176
|
-
const
|
|
3177
|
-
if (
|
|
3039
|
+
const I = _.getCurrent(n.value);
|
|
3040
|
+
if (I) {
|
|
3178
3041
|
const {
|
|
3179
|
-
width:
|
|
3042
|
+
width: D,
|
|
3180
3043
|
height: $
|
|
3181
|
-
} =
|
|
3182
|
-
n.value.style.left = `${(window.innerWidth -
|
|
3044
|
+
} = I;
|
|
3045
|
+
n.value.style.left = `${(window.innerWidth - D) / 2}px`, n.value.style.top = `${(window.innerHeight - $) / 2}px`, n.value.style.transform = "";
|
|
3183
3046
|
}
|
|
3184
3047
|
}
|
|
3185
3048
|
}
|
|
3186
|
-
function
|
|
3187
|
-
const
|
|
3188
|
-
|
|
3049
|
+
function fe() {
|
|
3050
|
+
const I = () => {
|
|
3051
|
+
b.value ? H(!1) : me();
|
|
3189
3052
|
};
|
|
3190
|
-
return window.addEventListener("resize",
|
|
3191
|
-
window.removeEventListener("resize",
|
|
3053
|
+
return window.addEventListener("resize", I), () => {
|
|
3054
|
+
window.removeEventListener("resize", I);
|
|
3192
3055
|
};
|
|
3193
3056
|
}
|
|
3194
|
-
const
|
|
3057
|
+
const re = fe();
|
|
3195
3058
|
return {
|
|
3196
|
-
renderResizeBar:
|
|
3059
|
+
renderResizeBar: z,
|
|
3197
3060
|
boundingElement: o,
|
|
3198
3061
|
resizedEventParam: m,
|
|
3199
|
-
maximize:
|
|
3200
|
-
restore:
|
|
3201
|
-
allowDrag:
|
|
3202
|
-
isMaximized:
|
|
3203
|
-
unWindowResizeHandle:
|
|
3062
|
+
maximize: H,
|
|
3063
|
+
restore: se,
|
|
3064
|
+
allowDrag: v,
|
|
3065
|
+
isMaximized: b,
|
|
3066
|
+
unWindowResizeHandle: re
|
|
3204
3067
|
};
|
|
3205
3068
|
}
|
|
3206
|
-
function
|
|
3207
|
-
const o =
|
|
3208
|
-
|
|
3209
|
-
l.value.style.cursor =
|
|
3069
|
+
function Na(t, e, n) {
|
|
3070
|
+
const o = p(), a = p(t.draggable), s = p(t.lockAxis), l = p(), c = p(), u = p(!1), i = p(new q(0, 0)), d = p(new q(0, 0)), r = p(new q(0, 0)), m = p(new q(0, 0));
|
|
3071
|
+
W(() => n.value, (y) => {
|
|
3072
|
+
l.value.style.cursor = y ? "move" : "default";
|
|
3210
3073
|
});
|
|
3211
|
-
function h(
|
|
3212
|
-
if (
|
|
3074
|
+
function h(y, P) {
|
|
3075
|
+
if (P.tagName === "BUTTON")
|
|
3213
3076
|
return !1;
|
|
3214
|
-
if (
|
|
3077
|
+
if (P === y)
|
|
3215
3078
|
return !0;
|
|
3216
|
-
for (const
|
|
3217
|
-
if (
|
|
3079
|
+
for (const O in P.children)
|
|
3080
|
+
if (Object.prototype.hasOwnProperty.call(P.children, O) && h(y, P.children[O]))
|
|
3218
3081
|
return !0;
|
|
3219
3082
|
return !1;
|
|
3220
3083
|
}
|
|
3221
|
-
function
|
|
3222
|
-
var
|
|
3223
|
-
let
|
|
3224
|
-
s.value === "x" ? (
|
|
3225
|
-
const
|
|
3226
|
-
o.value && (o.value.style.transform =
|
|
3084
|
+
function v() {
|
|
3085
|
+
var U, z;
|
|
3086
|
+
let y = r.value.x + d.value.x, P = r.value.y + d.value.y;
|
|
3087
|
+
s.value === "x" ? (y = ((U = i.value) == null ? void 0 : U.x) || 0, r.value.x = 0) : s.value === "y" && (P = ((z = i.value) == null ? void 0 : z.y) || 0, r.value.y = 0);
|
|
3088
|
+
const O = `translate3d(${Math.round(y)}px, ${Math.round(P)}px, 0px)`;
|
|
3089
|
+
o.value && (o.value.style.transform = O), m.value.x = y, m.value.y = P;
|
|
3227
3090
|
}
|
|
3228
|
-
function
|
|
3091
|
+
function b() {
|
|
3229
3092
|
if (!c.value || !o.value)
|
|
3230
3093
|
return null;
|
|
3231
|
-
const
|
|
3232
|
-
top:
|
|
3233
|
-
right:
|
|
3234
|
-
bottom:
|
|
3235
|
-
left:
|
|
3094
|
+
const y = c.value.getBoundingClientRect(), P = o.value.getBoundingClientRect(), O = {
|
|
3095
|
+
top: y.top < P.top,
|
|
3096
|
+
right: y.right > P.right,
|
|
3097
|
+
bottom: y.bottom > P.bottom,
|
|
3098
|
+
left: y.left < P.left
|
|
3236
3099
|
};
|
|
3237
|
-
return
|
|
3100
|
+
return O.top || (r.value.y -= P.top - y.top), O.bottom || (r.value.y -= P.bottom - y.bottom), O.right || (r.value.x -= P.right - y.right), O.left || (r.value.x -= P.left - y.left), v(), O;
|
|
3238
3101
|
}
|
|
3239
|
-
function
|
|
3240
|
-
|
|
3102
|
+
function F(y) {
|
|
3103
|
+
y && (i.value && y.subtract(i.value), r.value.set(y), v(), b());
|
|
3241
3104
|
}
|
|
3242
|
-
function
|
|
3243
|
-
u.value && a.value && (
|
|
3105
|
+
function M(y) {
|
|
3106
|
+
u.value && a.value && (y.stopPropagation(), y.preventDefault(), F(q.fromEvent(y, l.value)));
|
|
3244
3107
|
}
|
|
3245
|
-
function
|
|
3246
|
-
var
|
|
3247
|
-
u.value && (u.value = !1,
|
|
3108
|
+
function C() {
|
|
3109
|
+
var y;
|
|
3110
|
+
u.value && (u.value = !1, d.value.add(r.value), r.value.reset(), (y = o.value) == null || y.classList.remove("ng-dragging"), document.removeEventListener("mousemove", M), document.removeEventListener("mouseup", C));
|
|
3248
3111
|
}
|
|
3249
|
-
function
|
|
3250
|
-
!u.value && l.value && (u.value = !0, l.value.classList.add("ng-dragging"), document.addEventListener("mousemove",
|
|
3112
|
+
function R() {
|
|
3113
|
+
!u.value && l.value && (u.value = !0, l.value.classList.add("ng-dragging"), document.addEventListener("mousemove", M), document.addEventListener("mouseup", C));
|
|
3251
3114
|
}
|
|
3252
|
-
function
|
|
3115
|
+
function w() {
|
|
3253
3116
|
if (o.value) {
|
|
3254
|
-
const
|
|
3255
|
-
|
|
3117
|
+
const y = q.getTransformInfo(o.value);
|
|
3118
|
+
d.value.set(y);
|
|
3256
3119
|
return;
|
|
3257
3120
|
}
|
|
3258
|
-
|
|
3121
|
+
d.value.reset();
|
|
3259
3122
|
}
|
|
3260
|
-
function
|
|
3261
|
-
if (!n.value ||
|
|
3123
|
+
function g(y) {
|
|
3124
|
+
if (!n.value || y instanceof MouseEvent && y.button === 2)
|
|
3262
3125
|
return;
|
|
3263
|
-
const
|
|
3264
|
-
l.value !== void 0 &&
|
|
3265
|
-
}
|
|
3266
|
-
function
|
|
3267
|
-
if (a.value &&
|
|
3268
|
-
if (
|
|
3269
|
-
l.value =
|
|
3270
|
-
else if (
|
|
3271
|
-
if (
|
|
3272
|
-
l.value =
|
|
3273
|
-
else if (typeof
|
|
3274
|
-
const
|
|
3275
|
-
|
|
3126
|
+
const P = y.target || y.srcElement;
|
|
3127
|
+
l.value !== void 0 && P && !h(P, l.value) || a.value !== !1 && (document.body.click(), y.stopPropagation(), y.preventDefault(), i.value = q.fromEvent(y, o.value), w(), R());
|
|
3128
|
+
}
|
|
3129
|
+
function L(y, P, O) {
|
|
3130
|
+
if (a.value && P) {
|
|
3131
|
+
if (y)
|
|
3132
|
+
l.value = y;
|
|
3133
|
+
else if (t.dragHandle) {
|
|
3134
|
+
if (t.dragHandle instanceof HTMLElement)
|
|
3135
|
+
l.value = t.dragHandle;
|
|
3136
|
+
else if (typeof t.dragHandle == "string") {
|
|
3137
|
+
const U = P.querySelector(t.dragHandle);
|
|
3138
|
+
U && (l.value = U);
|
|
3276
3139
|
}
|
|
3277
3140
|
}
|
|
3278
|
-
o.value =
|
|
3141
|
+
o.value = P, c.value = O, l.value.classList.add("ng-draggable"), l.value.addEventListener("mousedown", g);
|
|
3279
3142
|
}
|
|
3280
3143
|
}
|
|
3281
3144
|
return {
|
|
3282
|
-
registerDraggle:
|
|
3283
|
-
resetTranslate:
|
|
3145
|
+
registerDraggle: L,
|
|
3146
|
+
resetTranslate: w
|
|
3284
3147
|
};
|
|
3285
3148
|
}
|
|
3286
|
-
function it(
|
|
3287
|
-
if (
|
|
3149
|
+
function it(t, e) {
|
|
3150
|
+
if (t) {
|
|
3288
3151
|
const n = (o) => {
|
|
3289
|
-
o.key.toLowerCase() ===
|
|
3152
|
+
o.key.toLowerCase() === t.toLowerCase() && e({ event: o, key: t });
|
|
3290
3153
|
};
|
|
3291
3154
|
return document.addEventListener("keydown", n), () => {
|
|
3292
3155
|
document.removeEventListener("keydown", n);
|
|
3293
3156
|
};
|
|
3294
3157
|
}
|
|
3295
3158
|
}
|
|
3296
|
-
function
|
|
3297
|
-
const n =
|
|
3159
|
+
function Oa(t, e) {
|
|
3160
|
+
const n = p(t.enableEsc);
|
|
3298
3161
|
let o = null;
|
|
3299
3162
|
return n.value ? (o = it("Escape", (a) => {
|
|
3300
|
-
|
|
3163
|
+
e.emit("esc", { event: a.event, type: "esc" });
|
|
3301
3164
|
}), {
|
|
3302
3165
|
remove: o
|
|
3303
3166
|
}) : null;
|
|
3304
3167
|
}
|
|
3305
|
-
function
|
|
3306
|
-
const n =
|
|
3168
|
+
function Aa(t, e) {
|
|
3169
|
+
const n = p(t.enableEnter);
|
|
3307
3170
|
let o = null;
|
|
3308
3171
|
return n.value ? (o = it("Enter", (a) => {
|
|
3309
|
-
|
|
3172
|
+
e.emit("enter", { event: a.event, type: "enter" });
|
|
3310
3173
|
}), {
|
|
3311
3174
|
remove: o
|
|
3312
3175
|
}) : null;
|
|
3313
3176
|
}
|
|
3314
|
-
const ut = /* @__PURE__ */
|
|
3177
|
+
const ut = /* @__PURE__ */ X({
|
|
3315
3178
|
name: "FModal",
|
|
3316
|
-
props:
|
|
3179
|
+
props: Va,
|
|
3317
3180
|
emits: ["update:modelValue", "accept", "cancel", "closed", "resize", "esc", "enter"],
|
|
3318
|
-
setup(
|
|
3319
|
-
const n =
|
|
3320
|
-
function
|
|
3321
|
-
a.value = !1,
|
|
3181
|
+
setup(t, e) {
|
|
3182
|
+
const n = p(t.width || 300), o = p(t.height || 200), a = p(t.modelValue), s = p(""), l = p(t.class), c = p(t.fitContent), u = p(t.showHeader), i = p(""), d = p(t.showCloseButton), r = p(t.showMaxButton), m = p(!1), h = p(""), v = p(""), b = p(""), F = p(t.showButtons), M = p(t.title), C = p(t.reiszeable), R = p(t.containment || null), w = p();
|
|
3183
|
+
function g(x, j) {
|
|
3184
|
+
a.value = !1, e.emit("update:modelValue", !1), j != null && e.emit(j ? "accept" : "cancel"), e.emit("closed", x);
|
|
3322
3185
|
}
|
|
3323
|
-
const
|
|
3186
|
+
const L = [{
|
|
3324
3187
|
name: "cancel",
|
|
3325
3188
|
text: "取消",
|
|
3326
3189
|
class: "btn btn-secondary",
|
|
3327
|
-
handle: (
|
|
3328
|
-
|
|
3190
|
+
handle: (x) => {
|
|
3191
|
+
g(x, !1);
|
|
3329
3192
|
}
|
|
3330
3193
|
}, {
|
|
3331
3194
|
name: "accept",
|
|
3332
3195
|
text: "确定",
|
|
3333
3196
|
class: "btn btn-primary",
|
|
3334
|
-
handle: (
|
|
3335
|
-
|
|
3197
|
+
handle: (x) => {
|
|
3198
|
+
g(x, !0);
|
|
3336
3199
|
}
|
|
3337
|
-
}],
|
|
3338
|
-
renderResizeBar:
|
|
3339
|
-
maximize:
|
|
3340
|
-
restore:
|
|
3341
|
-
boundingElement:
|
|
3342
|
-
resizedEventParam:
|
|
3343
|
-
allowDrag:
|
|
3200
|
+
}], y = p(t.buttons && t.buttons.length ? t.buttons : L), P = S(() => !!i.value), O = S(() => !!F.value && !!y.value), U = p(), z = p(), H = p(!1), {
|
|
3201
|
+
renderResizeBar: se,
|
|
3202
|
+
maximize: me,
|
|
3203
|
+
restore: fe,
|
|
3204
|
+
boundingElement: re,
|
|
3205
|
+
resizedEventParam: I,
|
|
3206
|
+
allowDrag: D,
|
|
3344
3207
|
unWindowResizeHandle: $
|
|
3345
|
-
} =
|
|
3346
|
-
registerDraggle:
|
|
3347
|
-
} =
|
|
3348
|
-
|
|
3349
|
-
|
|
3350
|
-
}),
|
|
3351
|
-
|
|
3352
|
-
}),
|
|
3353
|
-
|
|
3354
|
-
}),
|
|
3355
|
-
|
|
3356
|
-
}),
|
|
3357
|
-
const
|
|
3358
|
-
JSON.stringify(
|
|
3359
|
-
newSize:
|
|
3360
|
-
oldSize:
|
|
3208
|
+
} = Ra(t), {
|
|
3209
|
+
registerDraggle: A
|
|
3210
|
+
} = Na(t, e, D);
|
|
3211
|
+
W(() => t.title, (x, j) => {
|
|
3212
|
+
x !== j && (M.value = x);
|
|
3213
|
+
}), W(() => t.modelValue, (x, j) => {
|
|
3214
|
+
x !== j && (a.value = x);
|
|
3215
|
+
}), W(() => t.showHeader, (x, j) => {
|
|
3216
|
+
x !== j && (u.value = x);
|
|
3217
|
+
}), W(() => t.showButtons, (x, j) => {
|
|
3218
|
+
x !== j && (F.value = x);
|
|
3219
|
+
}), W(() => I.value, (x, j) => {
|
|
3220
|
+
const ne = x || {}, ie = j || {};
|
|
3221
|
+
JSON.stringify(ne) !== JSON.stringify(ie) && e.emit("resize", {
|
|
3222
|
+
newSize: x,
|
|
3223
|
+
oldSize: j
|
|
3361
3224
|
});
|
|
3362
3225
|
});
|
|
3363
|
-
function
|
|
3364
|
-
const
|
|
3365
|
-
(!
|
|
3226
|
+
function G() {
|
|
3227
|
+
const x = document.querySelectorAll(".farris-modal").length;
|
|
3228
|
+
(!x || x - 1 <= 0) && document.body.classList.remove("modal-open"), w.value && w.value.classList.remove("show");
|
|
3366
3229
|
}
|
|
3367
|
-
const ve =
|
|
3368
|
-
const
|
|
3230
|
+
const ve = S(() => (a.value ? document.body.classList.add("modal-open") : G(), a.value)), dt = S(() => {
|
|
3231
|
+
const x = {
|
|
3369
3232
|
modal: !0,
|
|
3370
3233
|
"farris-modal": !0,
|
|
3371
3234
|
fade: !0
|
|
3372
3235
|
};
|
|
3373
|
-
return
|
|
3374
|
-
}), pt =
|
|
3375
|
-
var
|
|
3376
|
-
const
|
|
3236
|
+
return x["f-modal-fitContent"] = !!c.value, x.show = !!ve.value, x;
|
|
3237
|
+
}), pt = S(() => {
|
|
3238
|
+
var ne;
|
|
3239
|
+
const x = {
|
|
3377
3240
|
"modal-dialog": !0
|
|
3378
|
-
},
|
|
3379
|
-
return
|
|
3380
|
-
}), mt =
|
|
3241
|
+
}, j = (ne = l.value) == null ? void 0 : ne.split(" ");
|
|
3242
|
+
return j == null || j.reduce((ie, Bt) => (ie[Bt] = !0, ie), x), x;
|
|
3243
|
+
}), mt = S(() => ({
|
|
3381
3244
|
position: "absolute",
|
|
3382
3245
|
top: `${(window.innerHeight - o.value) / 2}px`,
|
|
3383
3246
|
left: `${(window.innerWidth - n.value) / 2}px`,
|
|
3384
3247
|
width: `${n.value}px`,
|
|
3385
3248
|
height: c.value ? "auto" : `${o.value}px`
|
|
3386
|
-
})), ft =
|
|
3249
|
+
})), ft = S(() => ({
|
|
3387
3250
|
"modal-content": !0,
|
|
3388
3251
|
"modal-content-has-header": u.value
|
|
3389
|
-
})), vt =
|
|
3390
|
-
const
|
|
3252
|
+
})), vt = S(() => {
|
|
3253
|
+
const x = {
|
|
3391
3254
|
display: u.value ? "" : "none"
|
|
3392
3255
|
};
|
|
3393
|
-
return
|
|
3394
|
-
}), ht =
|
|
3256
|
+
return x["pointer-events"] = D.value ? "auto" : "none", x;
|
|
3257
|
+
}), ht = S(() => ({
|
|
3395
3258
|
"f-icon": !0,
|
|
3396
3259
|
modal_maximize: !0,
|
|
3397
|
-
modalrevert:
|
|
3398
|
-
})),
|
|
3260
|
+
modalrevert: H.value
|
|
3261
|
+
})), yt = S(() => ({
|
|
3399
3262
|
"modal-body": !0,
|
|
3400
3263
|
"f-utils-flex-column": h.value === "iframe"
|
|
3401
3264
|
}));
|
|
3402
|
-
function
|
|
3265
|
+
function gt() {
|
|
3403
3266
|
return {};
|
|
3404
3267
|
}
|
|
3405
|
-
const Ct =
|
|
3406
|
-
const
|
|
3407
|
-
textAlgin:
|
|
3408
|
-
},
|
|
3409
|
-
return Object.assign(
|
|
3268
|
+
const Ct = S(() => {
|
|
3269
|
+
const x = {
|
|
3270
|
+
textAlgin: b.value
|
|
3271
|
+
}, j = gt();
|
|
3272
|
+
return Object.assign(x, j);
|
|
3410
3273
|
});
|
|
3411
|
-
function
|
|
3412
|
-
if (
|
|
3413
|
-
|
|
3274
|
+
function Le(x) {
|
|
3275
|
+
if (x.stopPropagation(), H.value) {
|
|
3276
|
+
H.value = !1, fe();
|
|
3414
3277
|
return;
|
|
3415
3278
|
}
|
|
3416
|
-
|
|
3279
|
+
me(), H.value = !0;
|
|
3417
3280
|
}
|
|
3418
|
-
async function bt(
|
|
3419
|
-
|
|
3281
|
+
async function bt(x, j) {
|
|
3282
|
+
x.handle && await x.handle(j, x) && e.emit("closed", j);
|
|
3420
3283
|
}
|
|
3421
|
-
function wt(
|
|
3422
|
-
|
|
3284
|
+
function wt(x) {
|
|
3285
|
+
x.width && (n.value = x.width), x.height && (o.value = x.height), x.buttons && (y.value = x.buttons), x.title && (M.value = x.title);
|
|
3423
3286
|
}
|
|
3424
|
-
let he = null,
|
|
3425
|
-
|
|
3426
|
-
|
|
3427
|
-
}),
|
|
3428
|
-
|
|
3429
|
-
}),
|
|
3430
|
-
modalElementRef:
|
|
3287
|
+
let he = null, ye = null;
|
|
3288
|
+
J(() => {
|
|
3289
|
+
z.value && !R.value && (R.value = z.value.parentElement, re.value = R.value, A(U.value, z.value, re.value)), ve.value && document.body.classList.add("modal-open"), he = Oa(t, e), ye = Aa(t, e);
|
|
3290
|
+
}), Ue(() => {
|
|
3291
|
+
G(), $ && $(), he && he.remove(), ye && ye.remove();
|
|
3292
|
+
}), e.expose({
|
|
3293
|
+
modalElementRef: z,
|
|
3431
3294
|
updateModalOptions: wt,
|
|
3432
|
-
close:
|
|
3433
|
-
maxDialog:
|
|
3295
|
+
close: g,
|
|
3296
|
+
maxDialog: Le
|
|
3434
3297
|
});
|
|
3435
|
-
function
|
|
3298
|
+
function Mt() {
|
|
3436
3299
|
return f("ul", null, [m.value && f("li", {
|
|
3437
3300
|
class: "f-btn-icon f-bare"
|
|
3438
3301
|
}, [f("span", {
|
|
3439
3302
|
class: "f-icon modal_minimize"
|
|
3440
|
-
}, null)]),
|
|
3441
|
-
onClick:
|
|
3303
|
+
}, null)]), r.value && f("li", {
|
|
3304
|
+
onClick: Le,
|
|
3442
3305
|
class: "f-btn-icon f-bare",
|
|
3443
3306
|
style: "pointer-events: auto;"
|
|
3444
3307
|
}, [f("span", {
|
|
3445
3308
|
class: ht.value
|
|
3446
|
-
}, null)]),
|
|
3309
|
+
}, null)]), d.value && f("li", {
|
|
3447
3310
|
class: "f-btn-icon f-bare",
|
|
3448
|
-
onClick: (
|
|
3311
|
+
onClick: (x) => g(x, !1),
|
|
3449
3312
|
style: "pointer-events: auto;"
|
|
3450
3313
|
}, [f("span", {
|
|
3451
3314
|
class: "f-icon modal_close"
|
|
3452
3315
|
}, null)])]);
|
|
3453
3316
|
}
|
|
3454
|
-
function
|
|
3317
|
+
function Ft() {
|
|
3455
3318
|
return f("div", {
|
|
3456
3319
|
class: "modal-footer",
|
|
3457
3320
|
style: Ct.value
|
|
3458
|
-
}, [
|
|
3459
|
-
name:
|
|
3321
|
+
}, [y.value && y.value.map((x) => f("button", {
|
|
3322
|
+
name: x.name,
|
|
3460
3323
|
type: "button",
|
|
3461
|
-
class:
|
|
3462
|
-
onClick: (
|
|
3463
|
-
bt(
|
|
3324
|
+
class: x.class + (x.iconClass ? " btn-icontext" : ""),
|
|
3325
|
+
onClick: (j) => {
|
|
3326
|
+
bt(x, j);
|
|
3464
3327
|
}
|
|
3465
|
-
}, [!!
|
|
3466
|
-
class:
|
|
3467
|
-
}, null),
|
|
3328
|
+
}, [!!x.iconClass && f("i", {
|
|
3329
|
+
class: x.iconClass
|
|
3330
|
+
}, null), x.text]))]);
|
|
3468
3331
|
}
|
|
3469
|
-
function
|
|
3332
|
+
function xt() {
|
|
3470
3333
|
return f("div", {
|
|
3471
|
-
ref:
|
|
3334
|
+
ref: U,
|
|
3472
3335
|
class: "modal-header",
|
|
3473
3336
|
style: vt.value
|
|
3474
3337
|
}, [f("div", {
|
|
3475
3338
|
class: "modal-title"
|
|
3476
|
-
}, [
|
|
3477
|
-
class:
|
|
3339
|
+
}, [P.value && f("span", {
|
|
3340
|
+
class: i.value,
|
|
3478
3341
|
style: "margin-right: 8px"
|
|
3479
3342
|
}, null), f("span", {
|
|
3480
3343
|
class: "modal-title-label"
|
|
3481
|
-
}, [
|
|
3344
|
+
}, [M.value])]), f("div", {
|
|
3482
3345
|
class: "actions"
|
|
3483
|
-
}, [
|
|
3346
|
+
}, [Mt()])]);
|
|
3484
3347
|
}
|
|
3485
|
-
function
|
|
3486
|
-
|
|
3348
|
+
function Tt(x) {
|
|
3349
|
+
x.stopPropagation();
|
|
3487
3350
|
}
|
|
3488
|
-
return () => f(
|
|
3351
|
+
return () => f(Et, {
|
|
3489
3352
|
to: "body"
|
|
3490
3353
|
}, {
|
|
3491
|
-
default: () => [ve.value && f(
|
|
3354
|
+
default: () => [ve.value && f(St, {
|
|
3492
3355
|
name: "fade",
|
|
3493
3356
|
appear: !0
|
|
3494
3357
|
}, {
|
|
3495
3358
|
default: () => {
|
|
3496
|
-
var
|
|
3359
|
+
var x, j;
|
|
3497
3360
|
return [f("div", {
|
|
3498
3361
|
class: dt.value,
|
|
3499
3362
|
style: "display: block",
|
|
3500
|
-
ref:
|
|
3501
|
-
onClick:
|
|
3363
|
+
ref: w,
|
|
3364
|
+
onClick: Tt
|
|
3502
3365
|
}, [f("div", {
|
|
3503
3366
|
id: s.value,
|
|
3504
3367
|
class: pt.value,
|
|
3505
3368
|
style: mt.value,
|
|
3506
|
-
ref:
|
|
3369
|
+
ref: z
|
|
3507
3370
|
}, [f("div", {
|
|
3508
3371
|
class: ft.value
|
|
3509
|
-
}, [u.value &&
|
|
3510
|
-
class:
|
|
3511
|
-
}, [(
|
|
3372
|
+
}, [u.value && xt(), f("div", {
|
|
3373
|
+
class: yt.value
|
|
3374
|
+
}, [(j = (x = e.slots).default) == null ? void 0 : j.call(x), h.value === "iframe" && f("iframe", {
|
|
3512
3375
|
title: s.value,
|
|
3513
3376
|
class: "f-utils-fill",
|
|
3514
3377
|
width: "100%",
|
|
3515
3378
|
frameborder: "0",
|
|
3516
|
-
src:
|
|
3517
|
-
}, null)]),
|
|
3379
|
+
src: v.value
|
|
3380
|
+
}, null)]), O.value && Ft()]), !c.value && C.value && z.value && se(z.value)])])];
|
|
3518
3381
|
}
|
|
3519
3382
|
})]
|
|
3520
3383
|
});
|
|
3521
3384
|
}
|
|
3522
3385
|
});
|
|
3523
|
-
function ct(
|
|
3524
|
-
if (
|
|
3525
|
-
return
|
|
3526
|
-
if (
|
|
3527
|
-
return
|
|
3528
|
-
}
|
|
3529
|
-
function
|
|
3530
|
-
const
|
|
3531
|
-
|
|
3386
|
+
function ct(t) {
|
|
3387
|
+
if (t.content && t.content.render)
|
|
3388
|
+
return t.content.render;
|
|
3389
|
+
if (t.render && typeof t.render == "function")
|
|
3390
|
+
return t.render;
|
|
3391
|
+
}
|
|
3392
|
+
function $a(t) {
|
|
3393
|
+
const e = document.createElement("div");
|
|
3394
|
+
e.style.display = "contents";
|
|
3532
3395
|
const n = Dt({
|
|
3533
3396
|
setup(o, a) {
|
|
3534
|
-
|
|
3535
|
-
document.body.removeChild(
|
|
3397
|
+
Ue(() => {
|
|
3398
|
+
document.body.removeChild(e);
|
|
3536
3399
|
});
|
|
3537
|
-
const s =
|
|
3538
|
-
}), h =
|
|
3539
|
-
}),
|
|
3540
|
-
}),
|
|
3541
|
-
}),
|
|
3542
|
-
|
|
3400
|
+
const s = p(), l = p(t.class || ""), c = p(!!t.showButtons), u = p(!!t.showHeader), i = p(t.showCloseButton == null ? !0 : t.showCloseButton), d = p(!0), r = p(t.title || ""), m = t.acceptCallback || (() => {
|
|
3401
|
+
}), h = t.rejectCallback || (() => {
|
|
3402
|
+
}), v = t.closedCallback || ((C) => {
|
|
3403
|
+
}), b = t.resizeHandle || ((C) => {
|
|
3404
|
+
}), F = ct(t), M = (C) => {
|
|
3405
|
+
d.value = !1, n.unmount(), v(C);
|
|
3543
3406
|
};
|
|
3544
|
-
return
|
|
3407
|
+
return J(() => {
|
|
3545
3408
|
}), a.expose({
|
|
3546
3409
|
modalRef: s
|
|
3547
3410
|
}), () => f(ut, {
|
|
3548
3411
|
ref: s,
|
|
3549
3412
|
class: l.value,
|
|
3550
|
-
modelValue:
|
|
3551
|
-
"onUpdate:modelValue": (
|
|
3552
|
-
title:
|
|
3553
|
-
width:
|
|
3554
|
-
height:
|
|
3555
|
-
buttons:
|
|
3413
|
+
modelValue: d.value,
|
|
3414
|
+
"onUpdate:modelValue": (C) => d.value = C,
|
|
3415
|
+
title: r.value,
|
|
3416
|
+
width: t.width,
|
|
3417
|
+
height: t.height,
|
|
3418
|
+
buttons: t.buttons,
|
|
3556
3419
|
"show-header": u.value,
|
|
3557
3420
|
"show-buttons": c.value,
|
|
3558
|
-
"show-close-button":
|
|
3421
|
+
"show-close-button": i.value,
|
|
3559
3422
|
"show-max-button": !1,
|
|
3560
3423
|
onAccept: m,
|
|
3561
3424
|
onCancel: h,
|
|
3562
|
-
fitContent:
|
|
3563
|
-
onClosed:
|
|
3564
|
-
onResize:
|
|
3425
|
+
fitContent: t.fitContent == null ? !0 : t.fitContent,
|
|
3426
|
+
onClosed: M,
|
|
3427
|
+
onResize: b
|
|
3565
3428
|
}, {
|
|
3566
|
-
default: () => [
|
|
3429
|
+
default: () => [F && F(n)]
|
|
3567
3430
|
});
|
|
3568
3431
|
}
|
|
3569
3432
|
});
|
|
3570
|
-
return document.body.appendChild(
|
|
3433
|
+
return document.body.appendChild(e), n.mount(e), n;
|
|
3571
3434
|
}
|
|
3572
|
-
class
|
|
3573
|
-
constructor(
|
|
3435
|
+
class Ua {
|
|
3436
|
+
constructor(e) {
|
|
3574
3437
|
N(this, "appContext", null);
|
|
3575
|
-
N(this, "modalRef",
|
|
3576
|
-
N(this, "activeModalIndex",
|
|
3438
|
+
N(this, "modalRef", p());
|
|
3439
|
+
N(this, "activeModalIndex", p(0));
|
|
3577
3440
|
N(this, "modalRefs", {});
|
|
3578
|
-
N(this, "isUseEscCloseModal",
|
|
3579
|
-
N(this, "activeModalInstance",
|
|
3580
|
-
this.appContext =
|
|
3441
|
+
N(this, "isUseEscCloseModal", p(!1));
|
|
3442
|
+
N(this, "activeModalInstance", S(() => this.modalRefs[this.activeModalIndex.value]));
|
|
3443
|
+
this.app = e, this.appContext = e ? e._context : null;
|
|
3581
3444
|
}
|
|
3582
3445
|
getCurrentModal() {
|
|
3583
3446
|
return this.activeModalInstance.value;
|
|
3584
3447
|
}
|
|
3585
|
-
static show(
|
|
3448
|
+
static show(e) {
|
|
3586
3449
|
const n = Object.assign({
|
|
3587
3450
|
title: "",
|
|
3588
3451
|
showButtons: !0,
|
|
3589
3452
|
showHeader: !0
|
|
3590
|
-
},
|
|
3591
|
-
return
|
|
3453
|
+
}, e);
|
|
3454
|
+
return $a(n);
|
|
3592
3455
|
}
|
|
3593
|
-
open(
|
|
3456
|
+
open(e) {
|
|
3594
3457
|
const n = document.createDocumentFragment();
|
|
3595
|
-
|
|
3458
|
+
e.showMaxButton && e.fitContent && (e.showMaxButton = !1);
|
|
3596
3459
|
const o = Lt(Object.assign({
|
|
3597
3460
|
title: "",
|
|
3598
3461
|
showButtons: !0,
|
|
3599
3462
|
showHeader: !0
|
|
3600
|
-
},
|
|
3463
|
+
}, e)), a = p(!0), s = o.value.acceptCallback || (() => {
|
|
3601
3464
|
}), l = o.value.rejectCallback || (() => {
|
|
3602
|
-
}), c = o.value.closedCallback || ((
|
|
3603
|
-
}), u = o.value.resizeHandle || ((
|
|
3465
|
+
}), c = o.value.closedCallback || ((M, C) => {
|
|
3466
|
+
}), u = o.value.resizeHandle || ((M) => {
|
|
3604
3467
|
});
|
|
3605
|
-
let
|
|
3606
|
-
const
|
|
3607
|
-
var
|
|
3468
|
+
let i;
|
|
3469
|
+
const d = ct(o.value), r = (M) => {
|
|
3470
|
+
var R;
|
|
3608
3471
|
a.value = !1;
|
|
3609
|
-
const
|
|
3610
|
-
c(
|
|
3611
|
-
}, m = (
|
|
3612
|
-
|
|
3613
|
-
if (this.modalRefs[this.activeModalIndex.value] && delete this.modalRefs[this.activeModalIndex.value],
|
|
3614
|
-
const
|
|
3615
|
-
|
|
3472
|
+
const C = (R = M == null ? void 0 : M.target) == null ? void 0 : R.classList.contains("modal_close");
|
|
3473
|
+
c(M, this.isUseEscCloseModal.value ? "esc" : C ? "icon" : "button");
|
|
3474
|
+
}, m = (M) => {
|
|
3475
|
+
r(M), i && ce(() => {
|
|
3476
|
+
if (this.modalRefs[this.activeModalIndex.value] && delete this.modalRefs[this.activeModalIndex.value], ge(null, n), i = null, this.modalRef.value = null, this.modalRefs) {
|
|
3477
|
+
const C = Object.keys(this.modalRefs).map((R) => Number(R));
|
|
3478
|
+
C.length > 0 ? this.activeModalIndex.value = Math.max(...C) : this.activeModalIndex.value = 0;
|
|
3616
3479
|
}
|
|
3617
3480
|
this.isUseEscCloseModal.value = !1;
|
|
3618
3481
|
});
|
|
3619
|
-
}, h = (
|
|
3620
|
-
var
|
|
3621
|
-
this.isUseEscCloseModal.value = !0, this.activeModalInstance && ((
|
|
3622
|
-
},
|
|
3482
|
+
}, h = (M) => {
|
|
3483
|
+
var C;
|
|
3484
|
+
this.isUseEscCloseModal.value = !0, this.activeModalInstance && ((C = this.activeModalInstance.value) == null || C.close(M == null ? void 0 : M.event));
|
|
3485
|
+
}, v = () => f(ut, te({
|
|
3623
3486
|
ref: this.modalRef,
|
|
3624
3487
|
modelValue: a.value,
|
|
3625
|
-
"onUpdate:modelValue": (
|
|
3488
|
+
"onUpdate:modelValue": (M) => a.value = M
|
|
3626
3489
|
}, o.value, {
|
|
3627
3490
|
onAccept: s,
|
|
3628
3491
|
onCancel: l,
|
|
@@ -3630,20 +3493,20 @@ class $a {
|
|
|
3630
3493
|
onResize: u,
|
|
3631
3494
|
onEsc: h
|
|
3632
3495
|
}), {
|
|
3633
|
-
default: () => [
|
|
3496
|
+
default: () => [d && d(this.app)]
|
|
3634
3497
|
});
|
|
3635
|
-
return
|
|
3636
|
-
const
|
|
3637
|
-
return
|
|
3498
|
+
return i = ((M) => {
|
|
3499
|
+
const C = Pt(v, M);
|
|
3500
|
+
return C.appContext = this.appContext, ge(C, n), C;
|
|
3638
3501
|
})({
|
|
3639
3502
|
...o.value
|
|
3640
3503
|
// 'onUpdate:modelValue': onUpdateModelValue,
|
|
3641
3504
|
}), this.activeModalIndex.value++, this.modalRefs[this.activeModalIndex.value] = this.modalRef.value, {
|
|
3642
|
-
update: (
|
|
3505
|
+
update: (M) => {
|
|
3643
3506
|
o.value = {
|
|
3644
3507
|
...o.value,
|
|
3645
|
-
...
|
|
3646
|
-
},
|
|
3508
|
+
...M
|
|
3509
|
+
}, i && ge(Vt(i, {
|
|
3647
3510
|
...o
|
|
3648
3511
|
}), n);
|
|
3649
3512
|
},
|
|
@@ -3652,250 +3515,257 @@ class $a {
|
|
|
3652
3515
|
};
|
|
3653
3516
|
}
|
|
3654
3517
|
}
|
|
3655
|
-
class
|
|
3656
|
-
static show(
|
|
3657
|
-
|
|
3658
|
-
|
|
3659
|
-
|
|
3660
|
-
}),
|
|
3661
|
-
}), u = o.rejectCallback || (() => {
|
|
3518
|
+
class Q {
|
|
3519
|
+
static show(e) {
|
|
3520
|
+
const n = Z({
|
|
3521
|
+
...e
|
|
3522
|
+
}), o = !1, a = n.type === "error" || n.type === "prompt", s = n.type === "error" ? "错误提示" : n.type === "prompt" && n.title || "", l = n.acceptCallback || (() => {
|
|
3523
|
+
}), c = n.rejectCallback || (() => {
|
|
3662
3524
|
});
|
|
3663
|
-
let
|
|
3664
|
-
const
|
|
3665
|
-
|
|
3525
|
+
let u = null, i = new Ua(u);
|
|
3526
|
+
const d = () => {
|
|
3527
|
+
u && (u == null || u.destroy(), i = null);
|
|
3666
3528
|
};
|
|
3667
|
-
|
|
3529
|
+
u = i == null ? void 0 : i.open({
|
|
3668
3530
|
class: "modal-message modal-message-type-info",
|
|
3669
|
-
title:
|
|
3670
|
-
showButtons:
|
|
3671
|
-
showHeader:
|
|
3672
|
-
width:
|
|
3531
|
+
title: s,
|
|
3532
|
+
showButtons: o,
|
|
3533
|
+
showHeader: a,
|
|
3534
|
+
width: n.width || 400,
|
|
3673
3535
|
fitContent: !0,
|
|
3674
3536
|
showMaxButton: !1,
|
|
3675
|
-
render: () => f(
|
|
3676
|
-
onAccept:
|
|
3677
|
-
onReject:
|
|
3678
|
-
onClose:
|
|
3537
|
+
render: () => f(ue, te(n, {
|
|
3538
|
+
onAccept: l,
|
|
3539
|
+
onReject: c,
|
|
3540
|
+
onClose: d
|
|
3679
3541
|
}), null)
|
|
3680
3542
|
});
|
|
3681
3543
|
}
|
|
3682
|
-
static info(
|
|
3683
|
-
const o =
|
|
3544
|
+
static info(e, n) {
|
|
3545
|
+
const o = Z({
|
|
3684
3546
|
type: "info",
|
|
3685
|
-
title:
|
|
3547
|
+
title: e,
|
|
3686
3548
|
detail: n,
|
|
3687
3549
|
okButtonText: "知道了",
|
|
3688
3550
|
cancelButtonText: ""
|
|
3689
3551
|
});
|
|
3690
|
-
|
|
3552
|
+
Q.show(o);
|
|
3691
3553
|
}
|
|
3692
|
-
static warning(
|
|
3693
|
-
const o =
|
|
3554
|
+
static warning(e, n) {
|
|
3555
|
+
const o = Z({
|
|
3694
3556
|
type: "warning",
|
|
3695
|
-
title:
|
|
3557
|
+
title: e,
|
|
3696
3558
|
detail: n,
|
|
3697
3559
|
okButtonText: "知道了",
|
|
3698
3560
|
cancelButtonText: ""
|
|
3699
3561
|
});
|
|
3700
|
-
|
|
3562
|
+
Q.show(o);
|
|
3701
3563
|
}
|
|
3702
|
-
static success(
|
|
3703
|
-
const o =
|
|
3564
|
+
static success(e, n) {
|
|
3565
|
+
const o = Z({
|
|
3704
3566
|
type: "success",
|
|
3705
|
-
title:
|
|
3567
|
+
title: e,
|
|
3706
3568
|
detail: n,
|
|
3707
3569
|
okButtonText: "关闭",
|
|
3708
3570
|
cancelButtonText: ""
|
|
3709
3571
|
});
|
|
3710
|
-
|
|
3572
|
+
Q.show(o);
|
|
3711
3573
|
}
|
|
3712
|
-
static error(
|
|
3713
|
-
const a =
|
|
3574
|
+
static error(e, n, o) {
|
|
3575
|
+
const a = Z({
|
|
3714
3576
|
width: 500,
|
|
3715
3577
|
type: "error",
|
|
3716
3578
|
okButtonText: "关闭",
|
|
3717
3579
|
cancelButtonText: "",
|
|
3718
3580
|
exceptionInfo: {
|
|
3719
3581
|
date: o,
|
|
3720
|
-
message:
|
|
3582
|
+
message: e,
|
|
3721
3583
|
detail: n
|
|
3722
3584
|
}
|
|
3723
3585
|
});
|
|
3724
|
-
|
|
3586
|
+
Q.show(a);
|
|
3725
3587
|
}
|
|
3726
|
-
static prompt(
|
|
3727
|
-
const o =
|
|
3588
|
+
static prompt(e, n) {
|
|
3589
|
+
const o = Z({
|
|
3728
3590
|
type: "prompt",
|
|
3729
|
-
title:
|
|
3591
|
+
title: e,
|
|
3730
3592
|
detail: n,
|
|
3731
3593
|
okButtonText: "确定",
|
|
3732
3594
|
cancelButtonText: "取消"
|
|
3733
3595
|
});
|
|
3734
|
-
|
|
3596
|
+
Q.show(o);
|
|
3735
3597
|
}
|
|
3736
|
-
static question(
|
|
3737
|
-
const s =
|
|
3598
|
+
static question(e, n, o, a) {
|
|
3599
|
+
const s = Z({
|
|
3738
3600
|
type: "question",
|
|
3739
|
-
title:
|
|
3601
|
+
title: e,
|
|
3740
3602
|
detail: n,
|
|
3741
3603
|
okButtonText: "确定",
|
|
3742
3604
|
cancelButtonText: "取消",
|
|
3743
3605
|
acceptCallback: o,
|
|
3744
3606
|
rejectCallback: a
|
|
3745
3607
|
});
|
|
3746
|
-
|
|
3608
|
+
Q.show(s);
|
|
3747
3609
|
}
|
|
3748
3610
|
}
|
|
3749
|
-
|
|
3750
|
-
|
|
3611
|
+
ue.install = (t) => {
|
|
3612
|
+
t.component(ue.name, ue), t.provide("FMessageBoxService", Q);
|
|
3751
3613
|
};
|
|
3752
|
-
const ja = /* @__PURE__ */
|
|
3614
|
+
const ja = /* @__PURE__ */ X({
|
|
3753
3615
|
name: "FResponseFormLayoutSetting",
|
|
3754
3616
|
props: rt,
|
|
3755
3617
|
emits: ["change"],
|
|
3756
|
-
setup(
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
-
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
const v = "自定义", T = 12 / p.value.uniqueColClassInSM;
|
|
3764
|
-
n.includes(T) ? i.value = T : (l.push({
|
|
3618
|
+
setup(t, e) {
|
|
3619
|
+
const n = [1], o = [1, 2], a = [1, 2, 3, 4], s = [1, 2, 3, 4, 6];
|
|
3620
|
+
let l = [], c = [], u = [], i = [];
|
|
3621
|
+
const d = p(t.initialState), r = p(0), m = p(0), h = p(0), v = p(0);
|
|
3622
|
+
function b() {
|
|
3623
|
+
const C = "自定义", R = 12 / d.value.uniqueColClassInSM;
|
|
3624
|
+
n.includes(R) ? r.value = R : (l.push({
|
|
3765
3625
|
value: 0,
|
|
3766
|
-
name:
|
|
3767
|
-
}),
|
|
3768
|
-
const
|
|
3769
|
-
o.includes(
|
|
3626
|
+
name: C
|
|
3627
|
+
}), r.value = 0);
|
|
3628
|
+
const w = 12 / d.value.uniqueColClassInMD;
|
|
3629
|
+
o.includes(w) ? m.value = w : (c.push({
|
|
3770
3630
|
value: 0,
|
|
3771
|
-
name:
|
|
3631
|
+
name: C
|
|
3772
3632
|
}), m.value = 0);
|
|
3773
|
-
const
|
|
3774
|
-
a.includes(
|
|
3633
|
+
const g = 12 / d.value.uniqueColClassInLG;
|
|
3634
|
+
a.includes(g) ? h.value = g : (u.push({
|
|
3775
3635
|
value: 0,
|
|
3776
|
-
name:
|
|
3636
|
+
name: C
|
|
3777
3637
|
}), h.value = 0);
|
|
3778
|
-
const
|
|
3779
|
-
s.includes(
|
|
3638
|
+
const L = 12 / d.value.uniqueColClassInEL;
|
|
3639
|
+
s.includes(L) ? v.value = L : (i.push({
|
|
3780
3640
|
value: 0,
|
|
3781
|
-
name:
|
|
3782
|
-
}),
|
|
3641
|
+
name: C
|
|
3642
|
+
}), v.value = 0), l = [...l], c = [...c], u = [...u], i = [...i];
|
|
3783
3643
|
}
|
|
3784
|
-
function
|
|
3785
|
-
n.forEach((
|
|
3644
|
+
function F() {
|
|
3645
|
+
n.forEach((C) => {
|
|
3786
3646
|
l.push({
|
|
3787
|
-
value:
|
|
3788
|
-
name:
|
|
3647
|
+
value: C,
|
|
3648
|
+
name: C + ""
|
|
3789
3649
|
});
|
|
3790
|
-
}), o.forEach((
|
|
3650
|
+
}), o.forEach((C) => {
|
|
3791
3651
|
c.push({
|
|
3792
|
-
value:
|
|
3793
|
-
name:
|
|
3652
|
+
value: C,
|
|
3653
|
+
name: C + ""
|
|
3794
3654
|
});
|
|
3795
|
-
}), a.forEach((
|
|
3655
|
+
}), a.forEach((C) => {
|
|
3796
3656
|
u.push({
|
|
3797
|
-
value:
|
|
3798
|
-
name:
|
|
3657
|
+
value: C,
|
|
3658
|
+
name: C + ""
|
|
3799
3659
|
});
|
|
3800
|
-
}), s.forEach((
|
|
3801
|
-
|
|
3802
|
-
value:
|
|
3803
|
-
name:
|
|
3660
|
+
}), s.forEach((C) => {
|
|
3661
|
+
i.push({
|
|
3662
|
+
value: C,
|
|
3663
|
+
name: C + ""
|
|
3804
3664
|
});
|
|
3805
3665
|
});
|
|
3806
3666
|
}
|
|
3807
|
-
function
|
|
3808
|
-
|
|
3809
|
-
|
|
3667
|
+
function M() {
|
|
3668
|
+
Q.question("应用统一布局,将重置区域内部所有控件的宽度样式,确定应用?", "", () => {
|
|
3669
|
+
d.value.uniqueColClassInSM = r.value === 0 ? null : 12 / r.value, d.value.uniqueColClassInMD = m.value === 0 ? null : 12 / m.value, d.value.uniqueColClassInLG = h.value === 0 ? null : 12 / h.value, d.value.uniqueColClassInEL = v.value === 0 ? null : 12 / v.value, e.emit("change", d.value);
|
|
3810
3670
|
}, () => {
|
|
3811
3671
|
});
|
|
3812
3672
|
}
|
|
3813
|
-
return () =>
|
|
3673
|
+
return J(() => {
|
|
3674
|
+
F(), b();
|
|
3675
|
+
}), () => f("div", null, [f("div", {
|
|
3814
3676
|
class: "f-form-layout farris-form farris-form-controls-inline"
|
|
3815
3677
|
}, [f("div", {
|
|
3816
3678
|
class: "form-group farris-form-group screenGroup"
|
|
3817
3679
|
}, [f("span", {
|
|
3818
3680
|
class: "screenName"
|
|
3819
|
-
}, [
|
|
3681
|
+
}, [Y(" 小屏幕 ")]), f("div", {
|
|
3820
3682
|
class: "d-flex ml-2 screen-input"
|
|
3821
|
-
}, [f(
|
|
3683
|
+
}, [f(oe, {
|
|
3822
3684
|
data: l,
|
|
3823
3685
|
idField: "value",
|
|
3824
3686
|
valueField: "value",
|
|
3825
|
-
|
|
3826
|
-
|
|
3687
|
+
editable: !1,
|
|
3688
|
+
enableClear: !1,
|
|
3689
|
+
modelValue: r.value,
|
|
3690
|
+
"onUpdate:modelValue": (C) => r.value = C
|
|
3827
3691
|
}, null), f("span", {
|
|
3828
3692
|
class: "ml-2 columnText"
|
|
3829
|
-
}, [
|
|
3693
|
+
}, [Y("列")])])]), f("div", {
|
|
3830
3694
|
class: "form-group farris-form-group screenGroup"
|
|
3831
3695
|
}, [f("span", {
|
|
3832
3696
|
class: "screenName"
|
|
3833
|
-
}, [
|
|
3697
|
+
}, [Y("中等屏幕")]), f("div", {
|
|
3834
3698
|
class: "d-flex ml-2 screen-input"
|
|
3835
|
-
}, [f(
|
|
3699
|
+
}, [f(oe, {
|
|
3836
3700
|
data: c,
|
|
3837
3701
|
idField: "value",
|
|
3838
3702
|
valueField: "value",
|
|
3703
|
+
editable: !1,
|
|
3704
|
+
enableClear: !1,
|
|
3839
3705
|
modelValue: m.value,
|
|
3840
|
-
"onUpdate:modelValue": (
|
|
3706
|
+
"onUpdate:modelValue": (C) => m.value = C
|
|
3841
3707
|
}, null), f("span", {
|
|
3842
3708
|
class: "ml-2 columnText"
|
|
3843
|
-
}, [
|
|
3709
|
+
}, [Y("列")])])]), f("div", {
|
|
3844
3710
|
class: "form-group farris-form-group screenGroup"
|
|
3845
3711
|
}, [f("span", {
|
|
3846
3712
|
class: "screenName"
|
|
3847
|
-
}, [
|
|
3713
|
+
}, [Y("大屏幕")]), f("div", {
|
|
3848
3714
|
class: "d-flex ml-2 screen-input"
|
|
3849
|
-
}, [f(
|
|
3715
|
+
}, [f(oe, {
|
|
3850
3716
|
data: u,
|
|
3851
3717
|
idField: "value",
|
|
3852
3718
|
valueField: "value",
|
|
3719
|
+
editable: !1,
|
|
3720
|
+
enableClear: !1,
|
|
3853
3721
|
modelValue: h.value,
|
|
3854
|
-
"onUpdate:modelValue": (
|
|
3722
|
+
"onUpdate:modelValue": (C) => h.value = C
|
|
3855
3723
|
}, null), f("span", {
|
|
3856
3724
|
class: "ml-2 columnText"
|
|
3857
|
-
}, [
|
|
3725
|
+
}, [Y("列")])])]), f("div", {
|
|
3858
3726
|
class: "form-group farris-form-group screenGroup"
|
|
3859
3727
|
}, [f("span", {
|
|
3860
3728
|
class: "screenName"
|
|
3861
|
-
}, [
|
|
3729
|
+
}, [Y("极大屏幕")]), f("div", {
|
|
3862
3730
|
class: "d-flex ml-2 screen-input"
|
|
3863
|
-
}, [f(
|
|
3864
|
-
data:
|
|
3731
|
+
}, [f(oe, {
|
|
3732
|
+
data: i,
|
|
3865
3733
|
idField: "value",
|
|
3866
3734
|
valueField: "value",
|
|
3867
|
-
|
|
3868
|
-
|
|
3735
|
+
editable: !1,
|
|
3736
|
+
enableClear: !1,
|
|
3737
|
+
modelValue: v.value,
|
|
3738
|
+
"onUpdate:modelValue": (C) => v.value = C
|
|
3869
3739
|
}, null), f("span", {
|
|
3870
3740
|
class: "ml-2 columnText"
|
|
3871
|
-
}, [
|
|
3741
|
+
}, [Y("列")])])])]), f("div", {
|
|
3872
3742
|
class: "applyBtn"
|
|
3873
3743
|
}, [f("button", {
|
|
3874
3744
|
class: "btn f-rt-btn btn-primary",
|
|
3875
3745
|
type: "button",
|
|
3876
|
-
onClick: () =>
|
|
3877
|
-
}, [
|
|
3746
|
+
onClick: () => M()
|
|
3747
|
+
}, [Y("应用")])])]);
|
|
3878
3748
|
}
|
|
3879
|
-
}),
|
|
3880
|
-
install(
|
|
3881
|
-
|
|
3749
|
+
}), ns = {
|
|
3750
|
+
install(t) {
|
|
3751
|
+
t.component(Ce.name, Ce).component(we.name, we);
|
|
3882
3752
|
},
|
|
3883
|
-
register(
|
|
3884
|
-
|
|
3753
|
+
register(t, e, n, o) {
|
|
3754
|
+
t["form-group"] = we, e["form-group"] = Ve, t["response-form"] = Ce, e["response-form"] = Pe, t["form-input"] = ca, e["form-input"] = ua, o["form-group"] = { editorResolver: Fo }, t["response-form-layout-setting"] = ja, e["response-form-layout-setting"] = Ca;
|
|
3885
3755
|
},
|
|
3886
|
-
registerDesigner(
|
|
3887
|
-
|
|
3756
|
+
registerDesigner(t, e, n) {
|
|
3757
|
+
t["form-group"] = ia, e["form-group"] = Ve, t["response-form"] = Do, e["response-form"] = Pe;
|
|
3888
3758
|
}
|
|
3889
3759
|
};
|
|
3890
3760
|
export {
|
|
3891
3761
|
we as FDynamicFormGroup,
|
|
3892
|
-
|
|
3762
|
+
ca as FDynamicFormInput,
|
|
3893
3763
|
Ce as FResponseForm,
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3764
|
+
ns as default,
|
|
3765
|
+
le as dynamicFormGroupProps,
|
|
3766
|
+
Fo as editorResolver,
|
|
3767
|
+
Ve as formGroupPropsResolver,
|
|
3768
|
+
Pe as formPropsResolver,
|
|
3899
3769
|
He as responseFormProps,
|
|
3900
|
-
|
|
3770
|
+
Eo as useDesignerRules
|
|
3901
3771
|
};
|