@farris/ui-vue 1.2.8 → 1.3.0
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 +180 -180
- package/components/accordion/index.umd.cjs +1 -0
- package/components/avatar/index.esm.js +419 -331
- package/components/avatar/index.umd.cjs +1 -0
- package/components/border-editor/index.umd.cjs +1 -0
- package/components/button/index.umd.cjs +1 -0
- package/components/button-edit/index.css +1 -1
- package/components/button-edit/index.esm.js +346 -326
- package/components/button-edit/index.umd.cjs +1 -0
- package/components/button-group/index.umd.cjs +1 -0
- package/components/calculator/index.umd.cjs +1 -0
- package/components/calendar/index.esm.js +384 -384
- package/components/calendar/index.umd.cjs +1 -0
- package/components/capsule/index.esm.js +205 -205
- package/components/capsule/index.umd.cjs +1 -0
- package/components/checkbox/index.esm.js +555 -467
- package/components/checkbox/index.umd.cjs +1 -0
- package/components/color-picker/index.esm.js +239 -239
- package/components/color-picker/index.umd.cjs +3 -0
- package/components/combo-list/index.css +1 -0
- package/components/combo-list/index.esm.js +1072 -364
- package/components/combo-list/index.umd.cjs +1 -0
- package/components/combo-tree/index.esm.js +129 -129
- package/components/combo-tree/index.umd.cjs +1 -0
- package/components/common/index.esm.js +778 -700
- package/components/common/index.umd.cjs +1 -0
- package/components/component/index.esm.js +582 -327
- package/components/component/index.umd.cjs +1 -0
- package/components/condition/index.css +1 -0
- package/components/condition/index.esm.js +2433 -1134
- package/components/condition/index.umd.cjs +1 -0
- package/components/content-container/index.esm.js +307 -234
- package/components/content-container/index.umd.cjs +1 -0
- package/components/data-grid/index.css +1 -1
- package/components/data-grid/index.esm.js +6762 -4946
- package/components/data-grid/index.umd.cjs +1 -0
- package/components/data-view/index.css +1 -0
- package/components/data-view/index.esm.js +4977 -3489
- package/components/data-view/index.umd.cjs +1 -0
- package/components/date-picker/index.css +1 -1
- package/components/date-picker/index.esm.js +3525 -2811
- package/components/date-picker/index.umd.cjs +1 -0
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +938 -928
- package/components/designer-canvas/index.umd.cjs +1 -0
- package/components/designer-outline/index.css +1 -1
- package/components/designer-outline/index.esm.js +38 -37
- package/components/designer-outline/index.umd.cjs +1 -0
- package/components/designer-toolbox/index.esm.js +36 -12
- package/components/designer-toolbox/index.umd.cjs +1 -0
- package/components/discussion-editor/index.umd.cjs +3 -0
- package/components/discussion-list/index.umd.cjs +1 -0
- package/components/drawer/index.umd.cjs +1 -0
- package/components/dropdown/index.esm.js +282 -282
- package/components/dropdown/index.umd.cjs +2 -0
- package/components/dynamic-form/index.css +1 -0
- package/components/dynamic-form/index.esm.js +2684 -1039
- package/components/dynamic-form/index.umd.cjs +1 -0
- package/components/dynamic-resolver/index.esm.js +149 -101
- package/components/dynamic-resolver/index.umd.cjs +1 -0
- package/components/dynamic-view/index.esm.js +303 -290
- package/components/dynamic-view/index.umd.cjs +1 -0
- package/components/enum-editor/index.umd.cjs +1 -0
- package/components/events-editor/index.esm.js +573 -518
- package/components/events-editor/index.umd.cjs +1 -0
- package/components/expression-editor/index.esm.js +99 -99
- package/components/expression-editor/index.umd.cjs +1 -0
- package/components/external-container/index.css +1 -1
- package/components/external-container/index.esm.js +3607 -2799
- package/components/external-container/index.umd.cjs +1 -0
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5438 -8236
- package/components/field-selector/index.umd.cjs +1 -0
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1679 -1759
- package/components/filter-bar/index.umd.cjs +1 -0
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +1062 -1052
- package/components/flow-canvas/index.umd.cjs +1 -0
- package/components/image-cropper/index.esm.js +421 -421
- package/components/image-cropper/index.umd.cjs +1 -0
- package/components/input-group/index.esm.js +677 -593
- package/components/input-group/index.umd.cjs +1 -0
- package/components/layout/index.esm.js +326 -326
- package/components/layout/index.umd.cjs +1 -0
- package/components/list-nav/index.esm.js +272 -199
- package/components/list-nav/index.umd.cjs +1 -0
- package/components/list-view/index.css +1 -1
- package/components/list-view/index.esm.js +3739 -2273
- package/components/list-view/index.umd.cjs +1 -0
- package/components/loading/index.umd.cjs +8 -0
- package/components/locale/index.umd.cjs +1 -0
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +11255 -9004
- package/components/lookup/index.umd.cjs +1 -0
- package/components/mapping-editor/index.css +1 -1
- package/components/mapping-editor/index.esm.js +6046 -5314
- package/components/mapping-editor/index.umd.cjs +1 -0
- package/components/message-box/index.css +1 -1
- package/components/message-box/index.esm.js +511 -471
- package/components/message-box/index.umd.cjs +1 -0
- package/components/modal/index.css +1 -1
- package/components/modal/index.esm.js +438 -398
- package/components/modal/index.umd.cjs +1 -0
- package/components/nav/index.esm.js +588 -444
- package/components/nav/index.umd.cjs +3 -0
- package/components/notify/index.esm.js +59 -53
- package/components/notify/index.umd.cjs +1 -0
- package/components/number-range/index.esm.js +568 -485
- package/components/number-range/index.umd.cjs +1 -0
- package/components/number-spinner/index.esm.js +542 -454
- package/components/number-spinner/index.umd.cjs +1 -0
- package/components/order/index.css +1 -1
- package/components/order/index.esm.js +1967 -1105
- package/components/order/index.umd.cjs +1 -0
- package/components/page-footer/index.esm.js +160 -160
- package/components/page-footer/index.umd.cjs +1 -0
- package/components/page-header/index.esm.js +1282 -1151
- package/components/page-header/index.umd.cjs +1 -0
- package/components/pagination/index.esm.js +705 -555
- package/components/pagination/index.umd.cjs +1 -0
- package/components/popover/index.esm.js +71 -70
- package/components/popover/index.umd.cjs +1 -0
- package/components/progress/index.esm.js +270 -270
- package/components/progress/index.umd.cjs +3 -0
- package/components/property-editor/index.css +1 -1
- package/components/property-editor/index.esm.js +2231 -1517
- package/components/property-editor/index.umd.cjs +3 -0
- package/components/property-panel/index.esm.js +813 -909
- package/components/property-panel/index.umd.cjs +1 -0
- package/components/query-solution/index.css +1 -1
- package/components/query-solution/index.esm.js +3781 -2566
- package/components/query-solution/index.umd.cjs +1 -0
- package/components/radio-button/index.esm.js +101 -101
- package/components/radio-button/index.umd.cjs +1 -0
- package/components/radio-group/index.esm.js +538 -450
- package/components/radio-group/index.umd.cjs +1 -0
- package/components/rate/index.esm.js +238 -233
- package/components/rate/index.umd.cjs +1 -0
- package/components/response-layout/index.esm.js +155 -155
- package/components/response-layout/index.umd.cjs +1 -0
- package/components/response-layout-editor/index.css +1 -1
- package/components/response-layout-editor/index.esm.js +1243 -1180
- package/components/response-layout-editor/index.umd.cjs +1 -0
- package/components/response-toolbar/index.esm.js +988 -877
- package/components/response-toolbar/index.umd.cjs +1 -0
- package/components/schema-selector/index.css +1 -1
- package/components/schema-selector/index.esm.js +5413 -4867
- package/components/schema-selector/index.umd.cjs +8 -0
- package/components/search-box/index.esm.js +199 -199
- package/components/search-box/index.umd.cjs +1 -0
- package/components/section/index.esm.js +646 -503
- package/components/section/index.umd.cjs +1 -0
- package/components/smoke-detector/index.esm.js +144 -144
- package/components/smoke-detector/index.umd.cjs +1 -0
- package/components/spacing-editor/index.umd.cjs +1 -0
- package/components/splitter/index.esm.js +464 -391
- package/components/splitter/index.umd.cjs +1 -0
- package/components/step/index.esm.js +249 -249
- package/components/step/index.umd.cjs +1 -0
- package/components/switch/index.esm.js +483 -394
- package/components/switch/index.umd.cjs +1 -0
- package/components/tabs/index.css +1 -1
- package/components/tabs/index.esm.js +2366 -2208
- package/components/tabs/index.umd.cjs +1 -0
- package/components/tags/index.esm.js +397 -399
- package/components/tags/index.umd.cjs +1 -0
- package/components/text/index.esm.js +394 -394
- package/components/text/index.umd.cjs +1 -0
- package/components/textarea/index.esm.js +451 -367
- package/components/textarea/index.umd.cjs +1 -0
- package/components/time-picker/index.css +1 -1
- package/components/time-picker/index.esm.js +1252 -1144
- package/components/time-picker/index.umd.cjs +1 -0
- package/components/tooltip/index.umd.cjs +1 -0
- package/components/transfer/index.css +1 -1
- package/components/transfer/index.esm.js +510 -499
- package/components/transfer/index.umd.cjs +1 -0
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5463 -9330
- package/components/tree-grid/index.umd.cjs +1 -0
- package/components/tree-view/index.css +1 -0
- package/components/tree-view/index.esm.js +4058 -2597
- package/components/tree-view/index.umd.cjs +1 -0
- package/components/uploader/index.esm.js +510 -504
- package/components/uploader/index.umd.cjs +2 -0
- package/components/verify-detail/index.esm.js +220 -220
- package/components/verify-detail/index.umd.cjs +1 -0
- package/components/video/index.esm.js +653 -394
- package/components/video/index.umd.cjs +1 -0
- package/components/weather/index.esm.js +1028 -1028
- package/components/weather/index.umd.cjs +16 -0
- package/farris.all.esm.js +20407 -18556
- package/farris.all.umd.cjs +8 -8
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/button-edit/src/designer/button-group.design.component.d.ts +7 -0
- package/types/capsule/src/capsule.props.d.ts +2 -2
- package/types/combo-list/src/components/list-container.props.d.ts +1 -1
- package/types/common/entity/entity-schema.d.ts +258 -0
- package/types/common/index.d.ts +1 -0
- package/types/common/types.d.ts +1 -1
- package/types/common/utils/encrypt.d.ts +2 -0
- package/types/component/src/component-ref.props.d.ts +4 -0
- package/types/component/src/component.props.d.ts +7 -0
- package/types/component/src/composition/inner-component-build-info.d.ts +27 -0
- package/types/component/src/designer/use-designer-rules.d.ts +2 -2
- package/types/component/src/property-config/component.property-config.d.ts +9 -0
- package/types/components.d.ts +1 -0
- package/types/data-grid/index.d.ts +8 -2
- package/types/data-grid/src/composition/data-grid-component-creator.service.d.ts +33 -0
- package/types/data-grid/src/data-grid.component.d.ts +3 -1
- package/types/data-grid/src/data-grid.props.d.ts +3 -2
- package/types/data-grid/src/property-config/data-grid.property-config.d.ts +4 -0
- package/types/data-grid/src/schema/schema-resolver.d.ts +2 -1
- package/types/data-view/components/column-format/boolean.component.d.ts +4 -0
- package/types/data-view/components/column-format/column-format.component.d.ts +4 -0
- package/types/data-view/components/column-format/date.component.d.ts +4 -0
- package/types/data-view/components/column-format/enum.component.d.ts +4 -0
- package/types/data-view/components/column-format/number.component.d.ts +4 -0
- package/types/data-view/composition/pagination/use-pagination.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +36 -7
- package/types/data-view/composition/use-edit.d.ts +2 -1
- package/types/data-view/composition/visualization/use-virtual-scroll.d.ts +0 -15
- package/types/designer-canvas/src/composition/dg-control.d.ts +5 -0
- package/types/designer-canvas/src/composition/function/use-dragula.d.ts +2 -2
- package/types/designer-canvas/src/composition/types.d.ts +1 -1
- package/types/designer-canvas/src/types.d.ts +2 -2
- package/types/dynamic-form/index.d.ts +2 -1
- package/types/dynamic-form/src/composition/response-form-component-creator.service.d.ts +31 -0
- package/types/dynamic-form/src/composition/use-response-form-layout-setting.d.ts +2 -0
- package/types/dynamic-form/src/designer/response-form-layout-setting.component.d.ts +8 -0
- package/types/dynamic-form/src/designer/response-form-layout-setting.props.d.ts +4 -0
- package/types/dynamic-form/src/designer/use-designer-rules.d.ts +2 -2
- package/types/dynamic-form/src/property-config/form.property-config.d.ts +9 -0
- package/types/dynamic-form/src/schema/schema-mapper.d.ts +1 -0
- package/types/dynamic-form/src/schema/schema-resolver.d.ts +3 -1
- package/types/dynamic-form/src/types.d.ts +12 -1
- package/types/dynamic-resolver/index.d.ts +1 -0
- package/types/dynamic-resolver/src/event-handler-resolver.d.ts +4 -0
- package/types/dynamic-resolver/src/schema-resolver.d.ts +2 -1
- package/types/dynamic-resolver/src/types.d.ts +12 -2
- package/types/dynamic-view/index.d.ts +1 -0
- package/types/dynamic-view/src/event-dispatcher.d.ts +1 -1
- package/types/index.d.ts +2 -0
- package/types/lookup/src/components/favorite/lookup-favorite.component.d.ts +29 -0
- package/types/lookup/src/components/favorite/lookup-favorite.props.d.ts +15 -0
- package/types/lookup/src/components/modal-container.component.d.ts +25 -0
- package/types/lookup/src/components/modal-container.props.d.ts +29 -0
- package/types/lookup/src/composition/types.d.ts +8 -0
- package/types/lookup/src/composition/use-check-props.d.ts +9 -2
- package/types/lookup/src/composition/use-dialog.d.ts +5 -1
- package/types/lookup/src/composition/use-favorite.d.ts +12 -0
- package/types/lookup/src/composition/use-http.d.ts +9 -5
- package/types/lookup/src/composition/use-input-change.d.ts +3 -0
- package/types/lookup/src/composition/use-user-data.d.ts +24 -0
- package/types/lookup/src/property-config/lookup.property-config.d.ts +6 -4
- package/types/mapping-editor/src/mapping-editor.component.d.ts +3 -0
- package/types/mapping-editor/src/mapping-editor.props.d.ts +0 -1
- package/types/modal/src/composition/use-draggable.d.ts +2 -1
- package/types/modal/src/composition/use-shortcut.d.ts +6 -0
- package/types/modal/src/modal.component.d.ts +3 -0
- package/types/modal/src/modal.props.d.ts +4 -0
- package/types/page-header/src/page-header.props.d.ts +1 -0
- package/types/property-panel/src/composition/entity/base-property.d.ts +8 -0
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +20 -1
- package/types/response-layout-editor/src/composition/converter/use-response-layout-editor-setting.d.ts +2 -0
- package/types/response-layout-editor/src/type.d.ts +21 -0
- package/types/response-toolbar/src/response-toolbar.props.d.ts +2 -2
- package/types/response-toolbar/src/schema/schema-mapper.d.ts +4 -0
- package/types/section/src/property-config/section.property-config.d.ts +93 -0
- package/types/section/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/composition/types.d.ts +2 -2
- package/types/tabs/src/designer/tab-header-item.design.component.d.ts +3 -1
- package/types/tabs/src/property-config/tab-page.property-config.d.ts +60 -0
- package/types/tabs/src/schema/schema-resolver.d.ts +2 -1
- package/types/tabs/src/tabs.props.d.ts +1 -0
- package/types/tags/index.d.ts +36 -5
- package/types/tree-grid/index.d.ts +8 -2
- package/types/tree-grid/src/tree-grid.component.d.ts +3 -1
- package/types/modal/src/composition/use-esc.d.ts +0 -1
- package/types/response-layout-editor/src/composition/converter/response-layout-editor.converter.d.ts +0 -3
- package/types/response-layout-editor/src/composition/converter/use-convert-property-value.d.ts +0 -20
|
@@ -1,111 +1,111 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { cloneDeep as
|
|
1
|
+
import { defineComponent as _, createVNode as z, ref as M, nextTick as Z, inject as R, computed as x, onMounted as K } from "vue";
|
|
2
|
+
import { isPlainObject as q, cloneDeep as I } from "lodash-es";
|
|
3
3
|
import "bignumber.js";
|
|
4
|
-
const
|
|
4
|
+
const G = {}, J = {};
|
|
5
5
|
function k(n) {
|
|
6
|
-
const { properties: e, title: t } = n, r = Object.keys(e).reduce((
|
|
7
|
-
return r.id = `${t}-${Date.now()}
|
|
6
|
+
const { properties: e, title: t, ignore: r } = n, c = r && Array.isArray(r), h = Object.keys(e).reduce((m, y) => ((!c || !r.find((T) => T == y)) && (m[y] = e[y].type === "object" && e[y].properties ? k(e[y]) : I(e[y].default)), m), {});
|
|
7
|
+
return (!c || !r.find((m) => m == "id")) && (h.id = `${t}-${Date.now()}`), h;
|
|
8
8
|
}
|
|
9
|
-
function N(n, e = {}) {
|
|
10
|
-
const
|
|
11
|
-
if (
|
|
12
|
-
let
|
|
13
|
-
const
|
|
14
|
-
return
|
|
9
|
+
function N(n, e = {}, t) {
|
|
10
|
+
const r = G[n];
|
|
11
|
+
if (r) {
|
|
12
|
+
let c = k(r);
|
|
13
|
+
const h = J[n];
|
|
14
|
+
return c = h ? h({ getSchemaByType: N }, c, e, t) : c, c;
|
|
15
15
|
}
|
|
16
16
|
return null;
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function ee(n, e) {
|
|
19
19
|
const t = k(e);
|
|
20
|
-
return Object.keys(n).reduce((r,
|
|
20
|
+
return Object.keys(n).reduce((r, c) => (r[c] && q(r[c]) && q(n[c]) ? Object.assign(r[c], n[c]) : r[c] = n[c], r), t), t;
|
|
21
21
|
}
|
|
22
|
-
function
|
|
23
|
-
return Object.keys(n).filter((r) => n[r] != null).reduce((r,
|
|
24
|
-
if (e.has(
|
|
25
|
-
const
|
|
26
|
-
if (typeof
|
|
27
|
-
r[
|
|
22
|
+
function te(n, e) {
|
|
23
|
+
return Object.keys(n).filter((r) => n[r] != null).reduce((r, c) => {
|
|
24
|
+
if (e.has(c)) {
|
|
25
|
+
const h = e.get(c);
|
|
26
|
+
if (typeof h == "string")
|
|
27
|
+
r[h] = n[c];
|
|
28
28
|
else {
|
|
29
|
-
const
|
|
30
|
-
Object.assign(r,
|
|
29
|
+
const m = h(c, n[c], n);
|
|
30
|
+
Object.assign(r, m);
|
|
31
31
|
}
|
|
32
32
|
} else
|
|
33
|
-
r[
|
|
33
|
+
r[c] = n[c];
|
|
34
34
|
return r;
|
|
35
35
|
}, {});
|
|
36
36
|
}
|
|
37
|
-
function
|
|
38
|
-
const r =
|
|
39
|
-
return
|
|
37
|
+
function ne(n, e, t = /* @__PURE__ */ new Map()) {
|
|
38
|
+
const r = ee(n, e);
|
|
39
|
+
return te(r, t);
|
|
40
40
|
}
|
|
41
|
-
function
|
|
42
|
-
function e(p, d, f,
|
|
41
|
+
function oe(n = {}) {
|
|
42
|
+
function e(p, d, f, b) {
|
|
43
43
|
if (typeof f == "number")
|
|
44
|
-
return
|
|
44
|
+
return b[p].length === f;
|
|
45
45
|
if (typeof f == "object") {
|
|
46
|
-
const
|
|
47
|
-
if (
|
|
48
|
-
return Number(
|
|
49
|
-
if (
|
|
50
|
-
return Number(
|
|
51
|
-
if (
|
|
52
|
-
return Number(
|
|
46
|
+
const v = Object.keys(f)[0], o = f[v];
|
|
47
|
+
if (v === "not")
|
|
48
|
+
return Number(b[p].length) !== Number(o);
|
|
49
|
+
if (v === "moreThan")
|
|
50
|
+
return Number(b[p].length) >= Number(o);
|
|
51
|
+
if (v === "lessThan")
|
|
52
|
+
return Number(b[p].length) <= Number(o);
|
|
53
53
|
}
|
|
54
54
|
return !1;
|
|
55
55
|
}
|
|
56
|
-
function t(p, d, f,
|
|
57
|
-
return
|
|
56
|
+
function t(p, d, f, b) {
|
|
57
|
+
return b[p] && b[p].propertyValue && String(b[p].propertyValue.value) === String(f);
|
|
58
58
|
}
|
|
59
59
|
const r = /* @__PURE__ */ new Map([
|
|
60
60
|
["length", e],
|
|
61
61
|
["getProperty", t]
|
|
62
62
|
]);
|
|
63
63
|
Object.keys(n).reduce((p, d) => (p.set(d, n[d]), p), r);
|
|
64
|
-
function
|
|
64
|
+
function c(p, d) {
|
|
65
65
|
const f = p;
|
|
66
|
-
return typeof d == "number" ? [{ target: f, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: f, operator: "getProperty", param: p, value: !!d }] : typeof d == "object" ? Object.keys(d).map((
|
|
67
|
-
if (
|
|
68
|
-
return { target: f, operator: "length", param: null, value: d[
|
|
69
|
-
const
|
|
70
|
-
return { target: f, operator: "getProperty", param:
|
|
66
|
+
return typeof d == "number" ? [{ target: f, operator: "length", param: null, value: Number(d) }] : typeof d == "boolean" ? [{ target: f, operator: "getProperty", param: p, value: !!d }] : typeof d == "object" ? Object.keys(d).map((b) => {
|
|
67
|
+
if (b === "length")
|
|
68
|
+
return { target: f, operator: "length", param: null, value: d[b] };
|
|
69
|
+
const v = b, o = d[b];
|
|
70
|
+
return { target: f, operator: "getProperty", param: v, value: o };
|
|
71
71
|
}) : [];
|
|
72
72
|
}
|
|
73
|
-
function
|
|
74
|
-
return Object.keys(p).reduce((f,
|
|
75
|
-
const
|
|
76
|
-
return f.push(...
|
|
73
|
+
function h(p) {
|
|
74
|
+
return Object.keys(p).reduce((f, b) => {
|
|
75
|
+
const v = c(b, p[b]);
|
|
76
|
+
return f.push(...v), f;
|
|
77
77
|
}, []);
|
|
78
78
|
}
|
|
79
|
-
function
|
|
79
|
+
function m(p, d) {
|
|
80
80
|
if (r.has(p.operator)) {
|
|
81
81
|
const f = r.get(p.operator);
|
|
82
82
|
return f && f(p.target, p.param, p.value, d) || !1;
|
|
83
83
|
}
|
|
84
84
|
return !1;
|
|
85
85
|
}
|
|
86
|
-
function
|
|
87
|
-
return
|
|
86
|
+
function y(p, d) {
|
|
87
|
+
return h(p).reduce((v, o) => v && m(o, d), !0);
|
|
88
88
|
}
|
|
89
|
-
function
|
|
90
|
-
const f = Object.keys(p),
|
|
91
|
-
return
|
|
89
|
+
function T(p, d) {
|
|
90
|
+
const f = Object.keys(p), b = f.includes("allOf"), v = f.includes("anyOf"), o = b || v, u = (o ? p[o ? b ? "allOf" : "anyOf" : "allOf"] : [p]).map((a) => y(a, d));
|
|
91
|
+
return b ? !u.includes(!1) : u.includes(!0);
|
|
92
92
|
}
|
|
93
|
-
return { parseValueSchema:
|
|
93
|
+
return { parseValueSchema: T };
|
|
94
94
|
}
|
|
95
|
-
const
|
|
96
|
-
|
|
97
|
-
function
|
|
98
|
-
return
|
|
99
|
-
const
|
|
100
|
-
return Object.assign(
|
|
95
|
+
const re = {}, ce = {};
|
|
96
|
+
oe();
|
|
97
|
+
function se(n, e, t = /* @__PURE__ */ new Map(), r = (m, y, T) => y, c = {}, h = (m) => m) {
|
|
98
|
+
return G[e.title] = e, J[e.title] = r, re[e.title] = c, ce[e.title] = h, (m = {}) => {
|
|
99
|
+
const y = ne(m, e, t), T = Object.keys(n).reduce((p, d) => (p[d] = n[d].default, p), {});
|
|
100
|
+
return Object.assign(T, y);
|
|
101
101
|
};
|
|
102
102
|
}
|
|
103
|
-
function
|
|
103
|
+
function ae(n, e) {
|
|
104
104
|
return { customClass: e.class, customStyle: e.style };
|
|
105
105
|
}
|
|
106
|
-
const
|
|
107
|
-
["appearance",
|
|
108
|
-
]),
|
|
106
|
+
const ie = /* @__PURE__ */ new Map([
|
|
107
|
+
["appearance", ae]
|
|
108
|
+
]), pe = "https://json-schema.org/draft/2020-12/schema", le = "https://farris-design.gitee.io/content-container.schema.json", ue = "content-container", fe = "A Farris Container Component", de = "object", ye = {
|
|
109
109
|
id: {
|
|
110
110
|
description: "The unique identifier for a Section",
|
|
111
111
|
type: "string"
|
|
@@ -151,19 +151,19 @@ const ae = /* @__PURE__ */ new Map([
|
|
|
151
151
|
type: "boolean",
|
|
152
152
|
default: !0
|
|
153
153
|
}
|
|
154
|
-
},
|
|
154
|
+
}, be = [
|
|
155
155
|
"id",
|
|
156
156
|
"type",
|
|
157
157
|
"contents"
|
|
158
|
-
],
|
|
159
|
-
$schema:
|
|
160
|
-
$id:
|
|
161
|
-
title:
|
|
162
|
-
description:
|
|
163
|
-
type:
|
|
164
|
-
properties:
|
|
165
|
-
required:
|
|
166
|
-
},
|
|
158
|
+
], me = {
|
|
159
|
+
$schema: pe,
|
|
160
|
+
$id: le,
|
|
161
|
+
title: ue,
|
|
162
|
+
description: fe,
|
|
163
|
+
type: de,
|
|
164
|
+
properties: ye,
|
|
165
|
+
required: be
|
|
166
|
+
}, he = "content-container", ge = "A Farris Container Component", je = "object", Ce = {
|
|
167
167
|
basic: {
|
|
168
168
|
description: "Basic Infomation",
|
|
169
169
|
title: "基本信息",
|
|
@@ -206,11 +206,11 @@ const ae = /* @__PURE__ */ new Map([
|
|
|
206
206
|
}
|
|
207
207
|
}
|
|
208
208
|
}
|
|
209
|
-
},
|
|
210
|
-
title:
|
|
211
|
-
description:
|
|
212
|
-
type:
|
|
213
|
-
categories:
|
|
209
|
+
}, Ae = {
|
|
210
|
+
title: he,
|
|
211
|
+
description: ge,
|
|
212
|
+
type: je,
|
|
213
|
+
categories: Ce
|
|
214
214
|
};
|
|
215
215
|
function ve(n, e, t) {
|
|
216
216
|
return e;
|
|
@@ -218,29 +218,29 @@ function ve(n, e, t) {
|
|
|
218
218
|
const L = {
|
|
219
219
|
customClass: { type: String, default: "" },
|
|
220
220
|
customStyle: { type: String, default: "" }
|
|
221
|
-
},
|
|
221
|
+
}, W = se(L, me, ie, ve, Ae), $ = /* @__PURE__ */ _({
|
|
222
222
|
name: "FContentContainer",
|
|
223
223
|
props: L,
|
|
224
224
|
emits: [],
|
|
225
225
|
setup(n, e) {
|
|
226
|
-
return () =>
|
|
226
|
+
return () => z("div", {
|
|
227
227
|
class: n.customClass,
|
|
228
228
|
style: n.customStyle
|
|
229
229
|
}, [e.slots.default && e.slots.default()]);
|
|
230
230
|
}
|
|
231
231
|
});
|
|
232
|
-
function
|
|
232
|
+
function Pe() {
|
|
233
233
|
function n(e) {
|
|
234
|
-
var
|
|
234
|
+
var c, h;
|
|
235
235
|
if (!e)
|
|
236
236
|
return !1;
|
|
237
|
-
const t = ((
|
|
237
|
+
const t = ((c = e.targetContainer) == null ? void 0 : c.componentInstance) && e.targetContainer.componentInstance.value;
|
|
238
238
|
if (!t)
|
|
239
239
|
return !1;
|
|
240
|
-
const r = (
|
|
240
|
+
const r = (h = t.schema.appearance) == null ? void 0 : h.class;
|
|
241
241
|
if (e.controlCategory === "input" || e.controlType === "form-group") {
|
|
242
|
-
const
|
|
243
|
-
if (t.schema.type !== "response-layout-item" && !
|
|
242
|
+
const m = t.schema.type, y = (m === "response-form" || m === "content-container") && r && r.includes("farris-form");
|
|
243
|
+
if (t.schema.type !== "response-layout-item" && !y)
|
|
244
244
|
return !1;
|
|
245
245
|
}
|
|
246
246
|
return e.controlType !== "field-set";
|
|
@@ -249,7 +249,7 @@ function Ae() {
|
|
|
249
249
|
basalDragulaRuleForContainer: n
|
|
250
250
|
};
|
|
251
251
|
}
|
|
252
|
-
const Te = "https://json-schema.org/draft/2020-12/schema",
|
|
252
|
+
const Te = "https://json-schema.org/draft/2020-12/schema", we = "https://farris-design.gitee.io/dragging-rules.schema.json", De = "Dragging Rules", Oe = "The rules of designer canvas", Me = "object", Ee = {
|
|
253
253
|
"f-page": {
|
|
254
254
|
description: "The root class of page designed by farris.",
|
|
255
255
|
type: "object",
|
|
@@ -668,6 +668,80 @@ const Te = "https://json-schema.org/draft/2020-12/schema", Pe = "https://farris-
|
|
|
668
668
|
"f-list-nav-left": {
|
|
669
669
|
description: "",
|
|
670
670
|
type: "object"
|
|
671
|
+
},
|
|
672
|
+
"f-struct-data-grid-in-nav": {
|
|
673
|
+
description: "",
|
|
674
|
+
type: "object",
|
|
675
|
+
properties: {
|
|
676
|
+
contents: {
|
|
677
|
+
type: "object",
|
|
678
|
+
properties: {
|
|
679
|
+
"f-section-form": {
|
|
680
|
+
description: "",
|
|
681
|
+
type: "object",
|
|
682
|
+
properties: {
|
|
683
|
+
rules: {
|
|
684
|
+
type: "object",
|
|
685
|
+
properties: {
|
|
686
|
+
canAccept: {
|
|
687
|
+
type: "boolean",
|
|
688
|
+
const: !1
|
|
689
|
+
},
|
|
690
|
+
fixed: {
|
|
691
|
+
type: "boolean",
|
|
692
|
+
const: !0
|
|
693
|
+
},
|
|
694
|
+
hidePadding: {
|
|
695
|
+
type: "boolean",
|
|
696
|
+
const: !0
|
|
697
|
+
}
|
|
698
|
+
}
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
},
|
|
702
|
+
"f-section-grid": {
|
|
703
|
+
description: "",
|
|
704
|
+
type: "object",
|
|
705
|
+
properties: {
|
|
706
|
+
rules: {
|
|
707
|
+
type: "object",
|
|
708
|
+
properties: {
|
|
709
|
+
canAccept: {
|
|
710
|
+
type: "boolean",
|
|
711
|
+
const: !1
|
|
712
|
+
},
|
|
713
|
+
fixed: {
|
|
714
|
+
type: "boolean",
|
|
715
|
+
const: !0
|
|
716
|
+
},
|
|
717
|
+
hidePadding: {
|
|
718
|
+
type: "boolean",
|
|
719
|
+
const: !0
|
|
720
|
+
}
|
|
721
|
+
}
|
|
722
|
+
}
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
}
|
|
726
|
+
},
|
|
727
|
+
rules: {
|
|
728
|
+
type: "object",
|
|
729
|
+
properties: {
|
|
730
|
+
canAccept: {
|
|
731
|
+
type: "boolean",
|
|
732
|
+
const: !1
|
|
733
|
+
},
|
|
734
|
+
fixed: {
|
|
735
|
+
type: "boolean",
|
|
736
|
+
const: !0
|
|
737
|
+
},
|
|
738
|
+
hidePadding: {
|
|
739
|
+
type: "boolean",
|
|
740
|
+
const: !0
|
|
741
|
+
}
|
|
742
|
+
}
|
|
743
|
+
}
|
|
744
|
+
}
|
|
671
745
|
}
|
|
672
746
|
}
|
|
673
747
|
}
|
|
@@ -813,192 +887,191 @@ const Te = "https://json-schema.org/draft/2020-12/schema", Pe = "https://farris-
|
|
|
813
887
|
description: "",
|
|
814
888
|
type: "object"
|
|
815
889
|
}
|
|
816
|
-
},
|
|
890
|
+
}, Ne = {
|
|
817
891
|
$schema: Te,
|
|
818
|
-
$id:
|
|
819
|
-
title:
|
|
820
|
-
description:
|
|
821
|
-
type:
|
|
822
|
-
properties:
|
|
823
|
-
required: Ee
|
|
892
|
+
$id: we,
|
|
893
|
+
title: De,
|
|
894
|
+
description: Oe,
|
|
895
|
+
type: Me,
|
|
896
|
+
properties: Ee
|
|
824
897
|
}, F = /* @__PURE__ */ new Map();
|
|
825
898
|
function Se() {
|
|
826
|
-
function n(o, l,
|
|
827
|
-
var
|
|
828
|
-
if (typeof
|
|
829
|
-
return ((
|
|
830
|
-
if (typeof
|
|
831
|
-
const a = Object.keys(
|
|
899
|
+
function n(o, l, s, u) {
|
|
900
|
+
var A;
|
|
901
|
+
if (typeof s == "number")
|
|
902
|
+
return ((A = u[o]) == null ? void 0 : A.length) === s;
|
|
903
|
+
if (typeof s == "object") {
|
|
904
|
+
const a = Object.keys(s)[0], j = s[a];
|
|
832
905
|
if (a === "not")
|
|
833
|
-
return Number(u[o].length) !== Number(
|
|
906
|
+
return Number(u[o].length) !== Number(j);
|
|
834
907
|
if (a === "moreThan")
|
|
835
|
-
return Number(u[o].length) >= Number(
|
|
908
|
+
return Number(u[o].length) >= Number(j);
|
|
836
909
|
if (a === "lessThan")
|
|
837
|
-
return Number(u[o].length) <= Number(
|
|
910
|
+
return Number(u[o].length) <= Number(j);
|
|
838
911
|
}
|
|
839
912
|
return !1;
|
|
840
913
|
}
|
|
841
|
-
function e(o, l,
|
|
842
|
-
return typeof
|
|
914
|
+
function e(o, l, s, u) {
|
|
915
|
+
return typeof s == "boolean" ? u.childrenClassList.includes(l) === !!s : !1;
|
|
843
916
|
}
|
|
844
|
-
function t(o, l,
|
|
845
|
-
return typeof
|
|
917
|
+
function t(o, l, s, u) {
|
|
918
|
+
return typeof s == "boolean" ? u.parentClassList.includes(l) === !!s : !1;
|
|
846
919
|
}
|
|
847
|
-
function r(o, l,
|
|
848
|
-
return typeof
|
|
920
|
+
function r(o, l, s, u) {
|
|
921
|
+
return typeof s == "boolean" ? u.parentClassList.includes(l) === !!s : !1;
|
|
849
922
|
}
|
|
850
|
-
const
|
|
923
|
+
const c = /* @__PURE__ */ new Map([
|
|
851
924
|
["length", n],
|
|
852
925
|
["hasChildren", e],
|
|
853
926
|
["hasSibling", r],
|
|
854
927
|
["hasParent", t]
|
|
855
928
|
]);
|
|
856
|
-
function
|
|
857
|
-
const
|
|
858
|
-
return typeof l == "number" ? [{ target:
|
|
929
|
+
function h(o, l) {
|
|
930
|
+
const s = o;
|
|
931
|
+
return typeof l == "number" ? [{ target: s, operator: "length", param: null, value: Number(l) }] : typeof l == "object" ? Object.keys(l).map((u) => {
|
|
859
932
|
if (u === "length")
|
|
860
|
-
return { target:
|
|
861
|
-
const
|
|
862
|
-
return { target:
|
|
933
|
+
return { target: s, operator: "length", param: null, value: l[u] };
|
|
934
|
+
const A = u, a = l[u];
|
|
935
|
+
return { target: s, operator: o === "children" ? "hasChildren" : o === "parent" ? "hasParent" : "hasSibling", param: A, value: a };
|
|
863
936
|
}) : [];
|
|
864
937
|
}
|
|
865
|
-
function
|
|
866
|
-
if (
|
|
867
|
-
const
|
|
868
|
-
return
|
|
938
|
+
function m(o, l) {
|
|
939
|
+
if (c.has(o.operator)) {
|
|
940
|
+
const s = c.get(o.operator);
|
|
941
|
+
return s && s(o.target, o.param, o.value, l) || !1;
|
|
869
942
|
}
|
|
870
943
|
return !1;
|
|
871
944
|
}
|
|
872
|
-
function
|
|
873
|
-
return Object.keys(o).reduce((a,
|
|
874
|
-
const
|
|
875
|
-
return a.push(...
|
|
876
|
-
}, []).reduce((a,
|
|
945
|
+
function y(o, l) {
|
|
946
|
+
return Object.keys(o).reduce((a, j) => {
|
|
947
|
+
const w = h(j, o[j]);
|
|
948
|
+
return a.push(...w), a;
|
|
949
|
+
}, []).reduce((a, j) => a && m(j, l), !0);
|
|
877
950
|
}
|
|
878
|
-
function
|
|
879
|
-
const
|
|
951
|
+
function T(o, l) {
|
|
952
|
+
const s = Object.keys(o), u = s.includes("allOf"), A = s.includes("anyOf"), a = u || A, i = (a ? o[a ? u ? "allOf" : "anyOf" : "allOf"] : [o]).map((g) => y(g, l));
|
|
880
953
|
return u ? !i.includes(!1) : i.includes(!0);
|
|
881
954
|
}
|
|
882
955
|
function p(o, l) {
|
|
883
|
-
const
|
|
884
|
-
return
|
|
956
|
+
const s = o.const;
|
|
957
|
+
return s ? typeof s == "boolean" ? s : typeof s == "object" ? T(s, l) : !1 : !1;
|
|
885
958
|
}
|
|
886
959
|
function d(o) {
|
|
887
960
|
return (l) => {
|
|
888
|
-
const
|
|
889
|
-
return o && o.properties && Object.keys(o.properties).reduce((u,
|
|
890
|
-
const a = o.properties[
|
|
891
|
-
return u[
|
|
892
|
-
},
|
|
961
|
+
const s = { canAccept: !0, fixed: !1, hidePadding: !1 };
|
|
962
|
+
return o && o.properties && Object.keys(o.properties).reduce((u, A) => {
|
|
963
|
+
const a = o.properties[A];
|
|
964
|
+
return u[A] = p(a, l), u;
|
|
965
|
+
}, s), s;
|
|
893
966
|
};
|
|
894
967
|
}
|
|
895
|
-
function f(o, l,
|
|
968
|
+
function f(o, l, s) {
|
|
896
969
|
if (l.type === "object" && l.properties) {
|
|
897
|
-
const { rules: u, contents:
|
|
898
|
-
|
|
899
|
-
(a) => f(a,
|
|
970
|
+
const { rules: u, contents: A } = l.properties;
|
|
971
|
+
s.set(o, d(u)), A && Object.keys(A.properties).forEach(
|
|
972
|
+
(a) => f(a, A.properties[a], s)
|
|
900
973
|
);
|
|
901
974
|
}
|
|
902
975
|
}
|
|
903
|
-
function
|
|
976
|
+
function b() {
|
|
904
977
|
const { properties: o } = Ne;
|
|
905
978
|
Object.keys(o).forEach((l) => {
|
|
906
979
|
f(l, o[l], F);
|
|
907
980
|
});
|
|
908
981
|
}
|
|
909
|
-
function
|
|
910
|
-
const
|
|
911
|
-
return F.has(o) ? F.get(o)(l) :
|
|
982
|
+
function v(o, l) {
|
|
983
|
+
const s = { canAccept: !0, fixed: !1, hidePadding: !0 };
|
|
984
|
+
return F.has(o) ? F.get(o)(l) : s;
|
|
912
985
|
}
|
|
913
|
-
return
|
|
986
|
+
return b(), { getRuleValue: v };
|
|
914
987
|
}
|
|
915
988
|
function $e(n, e) {
|
|
916
|
-
const t = Se(), r = M(!1),
|
|
917
|
-
let
|
|
989
|
+
const t = Se(), r = M(!1), c = M(!1);
|
|
990
|
+
let h = !0, m = !1, y, T = !1;
|
|
918
991
|
function p(a) {
|
|
919
|
-
return
|
|
992
|
+
return y && y.componentClassList && y.componentClassList.includes("f-form-layout") && y.componentClassList.includes("farris-form") ? a.sourceType === "control" && a.controlCategory === "input" || a.sourceType === "move" && a.controlType === "form-group" : !0;
|
|
920
993
|
}
|
|
921
994
|
function d(a) {
|
|
922
|
-
return !(!
|
|
995
|
+
return !(!Pe().basalDragulaRuleForContainer(a) || !h || !p(a));
|
|
923
996
|
}
|
|
924
997
|
function f() {
|
|
925
|
-
r.value = !1,
|
|
926
|
-
const a = n,
|
|
927
|
-
const B = S && S.appearance ? S.appearance.class : "",
|
|
928
|
-
return V.push(...
|
|
929
|
-
}, []) : [], D = e, E = D && D.appearance && D.appearance.class || "",
|
|
930
|
-
|
|
931
|
-
componentClass:
|
|
932
|
-
componentClassList:
|
|
998
|
+
r.value = !1, c.value = !1;
|
|
999
|
+
const a = n, j = a.appearance && a.appearance.class || "", w = j.split(" "), i = a.contents || [], C = i.length ? i[0] : null, g = C && C.appearance ? C.appearance.class : "", P = g ? g.split(" ") : [], O = i.length ? i.reduce((V, S) => {
|
|
1000
|
+
const B = S && S.appearance ? S.appearance.class : "", Y = B ? B.split(" ") : [];
|
|
1001
|
+
return V.push(...Y), V;
|
|
1002
|
+
}, []) : [], D = e, E = D && D.appearance && D.appearance.class || "", H = E ? E.split(" ") : [];
|
|
1003
|
+
y = {
|
|
1004
|
+
componentClass: j,
|
|
1005
|
+
componentClassList: w,
|
|
933
1006
|
childContents: i,
|
|
934
|
-
firstChildContent:
|
|
935
|
-
firstChildClass:
|
|
936
|
-
firstChildClassList:
|
|
1007
|
+
firstChildContent: C,
|
|
1008
|
+
firstChildClass: g,
|
|
1009
|
+
firstChildClassList: P,
|
|
937
1010
|
parent: D,
|
|
938
1011
|
parentClass: E,
|
|
939
|
-
parentClassList:
|
|
1012
|
+
parentClassList: H,
|
|
940
1013
|
children: i,
|
|
941
1014
|
childrenClassList: O
|
|
942
1015
|
};
|
|
943
|
-
const { canAccept:
|
|
944
|
-
return
|
|
1016
|
+
const { canAccept: Q, fixed: U, hidePadding: X } = t.getRuleValue(w[0], y);
|
|
1017
|
+
return h = Q, m = X, T = U, !0;
|
|
945
1018
|
}
|
|
946
|
-
function
|
|
947
|
-
|
|
1019
|
+
function b(a) {
|
|
1020
|
+
Z();
|
|
948
1021
|
}
|
|
949
|
-
function
|
|
1022
|
+
function v() {
|
|
950
1023
|
return n.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
|
|
951
1024
|
}
|
|
952
|
-
function o(a,
|
|
953
|
-
const
|
|
954
|
-
if ((
|
|
955
|
-
const { label:
|
|
956
|
-
return
|
|
1025
|
+
function o(a, j) {
|
|
1026
|
+
const w = n;
|
|
1027
|
+
if ((w.appearance && w.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1028
|
+
const { label: g } = a, P = N("form-group");
|
|
1029
|
+
return P.editor = j, P.label = g, P;
|
|
957
1030
|
}
|
|
958
|
-
return
|
|
1031
|
+
return j;
|
|
959
1032
|
}
|
|
960
|
-
function l(a,
|
|
1033
|
+
function l(a, j, w) {
|
|
961
1034
|
const i = n;
|
|
962
1035
|
if ((i.appearance && i.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
963
|
-
const
|
|
964
|
-
return O.editor =
|
|
1036
|
+
const P = String(a.innerText), O = N("form-group");
|
|
1037
|
+
return O.editor = w, O.label = P, O;
|
|
965
1038
|
}
|
|
966
|
-
return
|
|
1039
|
+
return w;
|
|
967
1040
|
}
|
|
968
|
-
function
|
|
969
|
-
return !
|
|
1041
|
+
function s() {
|
|
1042
|
+
return !T;
|
|
970
1043
|
}
|
|
971
1044
|
function u() {
|
|
972
|
-
return !
|
|
1045
|
+
return !T;
|
|
973
1046
|
}
|
|
974
|
-
function
|
|
975
|
-
return
|
|
1047
|
+
function A() {
|
|
1048
|
+
return m;
|
|
976
1049
|
}
|
|
977
1050
|
return {
|
|
978
1051
|
canAccepts: d,
|
|
979
1052
|
resolveComponentContext: f,
|
|
980
|
-
getStyles:
|
|
1053
|
+
getStyles: v,
|
|
981
1054
|
onAcceptNewChildElement: l,
|
|
982
|
-
onAcceptMovedChildElement:
|
|
1055
|
+
onAcceptMovedChildElement: b,
|
|
983
1056
|
onResolveNewComponentSchema: o,
|
|
984
1057
|
triggerBelongedComponentToMoveWhenMoved: r,
|
|
985
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
986
|
-
checkCanMoveComponent:
|
|
1058
|
+
triggerBelongedComponentToDeleteWhenDeleted: c,
|
|
1059
|
+
checkCanMoveComponent: s,
|
|
987
1060
|
checkCanDeleteComponent: u,
|
|
988
|
-
hideNestedPaddingInDesginerView:
|
|
1061
|
+
hideNestedPaddingInDesginerView: A
|
|
989
1062
|
};
|
|
990
1063
|
}
|
|
991
1064
|
function Fe(n, e, t) {
|
|
992
|
-
var
|
|
1065
|
+
var w;
|
|
993
1066
|
function r() {
|
|
994
1067
|
t != null && t.resolveComponentContext && t.resolveComponentContext();
|
|
995
1068
|
}
|
|
996
1069
|
r();
|
|
997
|
-
const
|
|
998
|
-
function
|
|
1070
|
+
const c = t && t.getStyles && t.getStyles() || "", h = t && t.getDesignerClass && t.getDesignerClass() || "", m = M();
|
|
1071
|
+
function y() {
|
|
999
1072
|
return (e == null ? void 0 : e.schema.componentType) === "frame" ? !1 : t && t.checkCanMoveComponent ? t.checkCanMoveComponent() : !0;
|
|
1000
1073
|
}
|
|
1001
|
-
function
|
|
1074
|
+
function T() {
|
|
1002
1075
|
return !1;
|
|
1003
1076
|
}
|
|
1004
1077
|
function p() {
|
|
@@ -1012,14 +1085,14 @@ function Fe(n, e, t) {
|
|
|
1012
1085
|
return null;
|
|
1013
1086
|
if (i.value.schema && i.value.schema.type === "component")
|
|
1014
1087
|
return i.value;
|
|
1015
|
-
const
|
|
1016
|
-
return
|
|
1088
|
+
const C = M(i == null ? void 0 : i.value.parent), g = f(C);
|
|
1089
|
+
return g || null;
|
|
1017
1090
|
}
|
|
1018
|
-
function
|
|
1019
|
-
const { componentInstance:
|
|
1020
|
-
return !
|
|
1091
|
+
function b(i = e) {
|
|
1092
|
+
const { componentInstance: C, designerItemElementRef: g } = i;
|
|
1093
|
+
return !C || !C.value ? null : C.value.canMove ? g : b(i.parent);
|
|
1021
1094
|
}
|
|
1022
|
-
function
|
|
1095
|
+
function v(i) {
|
|
1023
1096
|
return !!t && t.canAccepts(i);
|
|
1024
1097
|
}
|
|
1025
1098
|
function o() {
|
|
@@ -1027,64 +1100,64 @@ function Fe(n, e, t) {
|
|
|
1027
1100
|
}
|
|
1028
1101
|
function l() {
|
|
1029
1102
|
}
|
|
1030
|
-
function
|
|
1031
|
-
|
|
1103
|
+
function s(i, C) {
|
|
1104
|
+
C && t != null && t.onAcceptMovedChildElement && t.onAcceptMovedChildElement(C);
|
|
1032
1105
|
}
|
|
1033
|
-
function u(i) {
|
|
1106
|
+
function u(i, C) {
|
|
1034
1107
|
const { componentType: g } = i;
|
|
1035
|
-
let
|
|
1036
|
-
t && t.onResolveNewComponentSchema && (
|
|
1037
|
-
const
|
|
1038
|
-
return
|
|
1108
|
+
let P = N(g, i, C);
|
|
1109
|
+
t && t.onResolveNewComponentSchema && (P = t.onResolveNewComponentSchema(i, P));
|
|
1110
|
+
const O = g.toLowerCase().replace("-", "_");
|
|
1111
|
+
return P && !P.id && P.type === g && (P.id = `${O}_${Math.random().toString().slice(2, 6)}`), P;
|
|
1039
1112
|
}
|
|
1040
|
-
function
|
|
1041
|
-
const
|
|
1042
|
-
O.parentComponentInstance =
|
|
1043
|
-
let D = N(
|
|
1044
|
-
t && t.onAcceptNewChildElement && (D = t.onAcceptNewChildElement(i,
|
|
1045
|
-
const E =
|
|
1046
|
-
return D && !D.id && D.type ===
|
|
1113
|
+
function A(i, C) {
|
|
1114
|
+
const g = String(i.getAttribute("data-controltype")), P = i.getAttribute("data-feature"), O = P ? JSON.parse(P) : {};
|
|
1115
|
+
O.parentComponentInstance = m.value;
|
|
1116
|
+
let D = N(g, O);
|
|
1117
|
+
t && t.onAcceptNewChildElement && (D = t.onAcceptNewChildElement(i, C, D));
|
|
1118
|
+
const E = g.toLowerCase().replace("-", "_");
|
|
1119
|
+
return D && !D.id && D.type === g && (D.id = `${E}_${Math.random().toString().slice(2, 6)}`), D;
|
|
1047
1120
|
}
|
|
1048
1121
|
function a(i) {
|
|
1049
1122
|
}
|
|
1050
|
-
function
|
|
1123
|
+
function j(...i) {
|
|
1051
1124
|
if (t && t.getPropsConfig)
|
|
1052
1125
|
return t.getPropsConfig(...i);
|
|
1053
1126
|
}
|
|
1054
|
-
return
|
|
1055
|
-
canMove:
|
|
1056
|
-
canSelectParent:
|
|
1127
|
+
return m.value = {
|
|
1128
|
+
canMove: y(),
|
|
1129
|
+
canSelectParent: T(),
|
|
1057
1130
|
canDelete: p(),
|
|
1058
1131
|
canNested: !d(),
|
|
1059
1132
|
contents: e == null ? void 0 : e.schema.contents,
|
|
1060
1133
|
elementRef: n,
|
|
1061
|
-
parent: (
|
|
1134
|
+
parent: (w = e == null ? void 0 : e.parent) == null ? void 0 : w.componentInstance,
|
|
1062
1135
|
schema: e == null ? void 0 : e.schema,
|
|
1063
|
-
styles:
|
|
1064
|
-
designerClass:
|
|
1065
|
-
canAccepts:
|
|
1136
|
+
styles: c,
|
|
1137
|
+
designerClass: h,
|
|
1138
|
+
canAccepts: v,
|
|
1066
1139
|
getBelongedComponentInstance: f,
|
|
1067
|
-
getDraggableDesignItemElement:
|
|
1140
|
+
getDraggableDesignItemElement: b,
|
|
1068
1141
|
getDraggingDisplayText: o,
|
|
1069
|
-
getPropConfig:
|
|
1142
|
+
getPropConfig: j,
|
|
1070
1143
|
getDragScopeElement: l,
|
|
1071
|
-
onAcceptMovedChildElement:
|
|
1072
|
-
onAcceptNewChildElement:
|
|
1144
|
+
onAcceptMovedChildElement: s,
|
|
1145
|
+
onAcceptNewChildElement: A,
|
|
1073
1146
|
onChildElementMovedOut: a,
|
|
1074
1147
|
addNewChildComponentSchema: u,
|
|
1075
1148
|
updateDragAndDropRules: r,
|
|
1076
1149
|
triggerBelongedComponentToMoveWhenMoved: !!t && t.triggerBelongedComponentToMoveWhenMoved || M(!1),
|
|
1077
1150
|
triggerBelongedComponentToDeleteWhenDeleted: !!t && t.triggerBelongedComponentToDeleteWhenDeleted || M(!1)
|
|
1078
|
-
},
|
|
1151
|
+
}, m;
|
|
1079
1152
|
}
|
|
1080
1153
|
const ke = ["moz", "ms", "webkit"];
|
|
1081
1154
|
function Le() {
|
|
1082
1155
|
let n = 0;
|
|
1083
1156
|
return (e) => {
|
|
1084
|
-
const t = (/* @__PURE__ */ new Date()).getTime(), r = Math.max(0, 16 - (t - n)),
|
|
1157
|
+
const t = (/* @__PURE__ */ new Date()).getTime(), r = Math.max(0, 16 - (t - n)), c = setTimeout(() => {
|
|
1085
1158
|
e(t + r);
|
|
1086
1159
|
}, r);
|
|
1087
|
-
return n = t + r,
|
|
1160
|
+
return n = t + r, c;
|
|
1088
1161
|
};
|
|
1089
1162
|
}
|
|
1090
1163
|
function Ve() {
|
|
@@ -1097,22 +1170,22 @@ function Ve() {
|
|
|
1097
1170
|
}
|
|
1098
1171
|
Ve();
|
|
1099
1172
|
function Be(n, e) {
|
|
1100
|
-
return ((e == null ? void 0 : e.split(" ")) || []).reduce((r,
|
|
1173
|
+
return ((e == null ? void 0 : e.split(" ")) || []).reduce((r, c) => (c && (r[c] = !0), r), n), n;
|
|
1101
1174
|
}
|
|
1102
|
-
const qe = /* @__PURE__ */
|
|
1175
|
+
const qe = /* @__PURE__ */ _({
|
|
1103
1176
|
name: "FContentContainerDesign",
|
|
1104
1177
|
props: L,
|
|
1105
1178
|
emits: [],
|
|
1106
1179
|
setup(n, e) {
|
|
1107
|
-
var
|
|
1108
|
-
const t = M(), r =
|
|
1180
|
+
var y;
|
|
1181
|
+
const t = M(), r = R("design-item-context"), c = $e(r.schema, (y = r.parent) == null ? void 0 : y.schema), h = Fe(t, r, c), m = x(() => Be({
|
|
1109
1182
|
"drag-container": !0
|
|
1110
1183
|
}, n == null ? void 0 : n.customClass));
|
|
1111
1184
|
return K(() => {
|
|
1112
|
-
t.value.componentInstance =
|
|
1113
|
-
}), e.expose(
|
|
1185
|
+
t.value.componentInstance = h;
|
|
1186
|
+
}), e.expose(h.value), () => z("div", {
|
|
1114
1187
|
ref: t,
|
|
1115
|
-
class:
|
|
1188
|
+
class: m.value,
|
|
1116
1189
|
style: n.customStyle,
|
|
1117
1190
|
"data-dragref": `${r.schema.id}-container`
|
|
1118
1191
|
}, [e.slots.default && e.slots.default()]);
|
|
@@ -1122,10 +1195,10 @@ const qe = /* @__PURE__ */ W({
|
|
|
1122
1195
|
n.component($.name, $);
|
|
1123
1196
|
},
|
|
1124
1197
|
register(n, e, t, r) {
|
|
1125
|
-
n["content-container"] = $, e["content-container"] =
|
|
1198
|
+
n["content-container"] = $, e["content-container"] = W;
|
|
1126
1199
|
},
|
|
1127
1200
|
registerDesigner(n, e, t) {
|
|
1128
|
-
n["content-container"] = qe, e["content-container"] =
|
|
1201
|
+
n["content-container"] = qe, e["content-container"] = W;
|
|
1129
1202
|
}
|
|
1130
1203
|
};
|
|
1131
1204
|
export {
|
|
@@ -1133,5 +1206,5 @@ export {
|
|
|
1133
1206
|
qe as ContentContainerDesign,
|
|
1134
1207
|
L as contentContainerProps,
|
|
1135
1208
|
Ge as default,
|
|
1136
|
-
|
|
1209
|
+
W as propsResolver
|
|
1137
1210
|
};
|