@farris/ui-vue 1.2.9 → 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 +63 -63
- package/components/accordion/index.umd.cjs +1 -1
- package/components/avatar/index.esm.js +402 -323
- package/components/avatar/index.umd.cjs +1 -1
- package/components/button-edit/index.css +1 -1
- package/components/button-edit/index.esm.js +98 -96
- package/components/button-edit/index.umd.cjs +1 -1
- package/components/calendar/index.esm.js +66 -66
- package/components/calendar/index.umd.cjs +1 -1
- package/components/capsule/index.esm.js +118 -118
- package/components/capsule/index.umd.cjs +1 -1
- package/components/checkbox/index.esm.js +539 -460
- package/components/checkbox/index.umd.cjs +1 -1
- package/components/color-picker/index.esm.js +135 -135
- package/components/color-picker/index.umd.cjs +2 -2
- package/components/combo-list/index.css +1 -0
- package/components/combo-list/index.esm.js +1007 -312
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/combo-tree/index.esm.js +97 -97
- package/components/combo-tree/index.umd.cjs +1 -1
- package/components/common/index.esm.js +778 -700
- package/components/common/index.umd.cjs +1 -1
- package/components/component/index.esm.js +472 -329
- package/components/component/index.umd.cjs +1 -1
- package/components/condition/index.css +1 -0
- package/components/condition/index.esm.js +2231 -1055
- package/components/condition/index.umd.cjs +1 -1
- package/components/content-container/index.esm.js +79 -79
- package/components/content-container/index.umd.cjs +1 -1
- package/components/data-grid/index.css +1 -1
- package/components/data-grid/index.esm.js +6408 -5034
- package/components/data-grid/index.umd.cjs +1 -1
- package/components/data-view/index.css +1 -0
- package/components/data-view/index.esm.js +4762 -3511
- package/components/data-view/index.umd.cjs +1 -1
- package/components/date-picker/index.css +1 -1
- package/components/date-picker/index.esm.js +3442 -2742
- package/components/date-picker/index.umd.cjs +1 -1
- package/components/designer-outline/index.esm.js +14 -13
- package/components/designer-outline/index.umd.cjs +1 -1
- package/components/dropdown/index.esm.js +73 -73
- package/components/dropdown/index.umd.cjs +2 -2
- package/components/dynamic-form/index.css +1 -0
- package/components/dynamic-form/index.esm.js +2597 -1141
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +114 -71
- package/components/dynamic-resolver/index.umd.cjs +1 -1
- package/components/dynamic-view/index.esm.js +303 -290
- package/components/dynamic-view/index.umd.cjs +1 -1
- package/components/events-editor/index.esm.js +171 -171
- package/components/events-editor/index.umd.cjs +1 -1
- package/components/expression-editor/index.esm.js +65 -65
- package/components/expression-editor/index.umd.cjs +1 -1
- package/components/external-container/index.css +1 -1
- package/components/external-container/index.esm.js +3075 -2586
- package/components/external-container/index.umd.cjs +1 -1
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5272 -8511
- package/components/field-selector/index.umd.cjs +1 -1
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1726 -1822
- package/components/filter-bar/index.umd.cjs +1 -1
- package/components/image-cropper/index.esm.js +126 -126
- package/components/image-cropper/index.umd.cjs +1 -1
- package/components/input-group/index.esm.js +620 -540
- package/components/input-group/index.umd.cjs +1 -1
- package/components/layout/index.esm.js +88 -88
- package/components/layout/index.umd.cjs +1 -1
- package/components/list-nav/index.esm.js +71 -71
- package/components/list-nav/index.umd.cjs +1 -1
- package/components/list-view/index.css +1 -1
- package/components/list-view/index.esm.js +3582 -2356
- package/components/list-view/index.umd.cjs +1 -1
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +10752 -8972
- package/components/lookup/index.umd.cjs +1 -1
- package/components/mapping-editor/index.css +1 -1
- package/components/mapping-editor/index.esm.js +5601 -5329
- package/components/mapping-editor/index.umd.cjs +1 -1
- 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 -1
- package/components/modal/index.css +1 -1
- package/components/modal/index.esm.js +438 -398
- package/components/modal/index.umd.cjs +1 -1
- package/components/nav/index.esm.js +535 -452
- package/components/nav/index.umd.cjs +2 -2
- package/components/notify/index.esm.js +59 -53
- package/components/notify/index.umd.cjs +1 -1
- package/components/number-range/index.esm.js +556 -477
- package/components/number-range/index.umd.cjs +1 -1
- package/components/number-spinner/index.esm.js +504 -425
- package/components/number-spinner/index.umd.cjs +1 -1
- package/components/order/index.css +1 -1
- package/components/order/index.esm.js +1833 -1054
- package/components/order/index.umd.cjs +1 -1
- package/components/page-footer/index.esm.js +100 -100
- package/components/page-footer/index.umd.cjs +1 -1
- package/components/page-header/index.esm.js +899 -870
- package/components/page-header/index.umd.cjs +1 -1
- package/components/pagination/index.esm.js +576 -487
- package/components/pagination/index.umd.cjs +1 -1
- package/components/popover/index.esm.js +71 -70
- package/components/popover/index.umd.cjs +1 -1
- package/components/progress/index.esm.js +73 -73
- package/components/progress/index.umd.cjs +2 -2
- package/components/property-editor/index.css +1 -1
- package/components/property-editor/index.esm.js +1916 -1220
- package/components/property-editor/index.umd.cjs +3 -3
- package/components/property-panel/index.esm.js +783 -886
- package/components/property-panel/index.umd.cjs +1 -1
- package/components/query-solution/index.css +1 -1
- package/components/query-solution/index.esm.js +3632 -2556
- package/components/query-solution/index.umd.cjs +1 -1
- package/components/radio-button/index.esm.js +72 -72
- package/components/radio-button/index.umd.cjs +1 -1
- package/components/radio-group/index.esm.js +484 -405
- package/components/radio-group/index.umd.cjs +1 -1
- package/components/rate/index.esm.js +152 -152
- package/components/rate/index.umd.cjs +1 -1
- package/components/response-layout/index.esm.js +73 -73
- package/components/response-layout/index.umd.cjs +1 -1
- package/components/response-layout-editor/index.css +1 -1
- package/components/response-layout-editor/index.esm.js +1081 -1043
- package/components/response-layout-editor/index.umd.cjs +1 -1
- package/components/response-toolbar/index.esm.js +753 -738
- package/components/response-toolbar/index.umd.cjs +1 -1
- package/components/schema-selector/index.css +1 -1
- package/components/schema-selector/index.esm.js +4418 -4177
- package/components/schema-selector/index.umd.cjs +2 -2
- package/components/search-box/index.esm.js +119 -119
- package/components/search-box/index.umd.cjs +1 -1
- package/components/section/index.esm.js +92 -91
- package/components/section/index.umd.cjs +1 -1
- package/components/smoke-detector/index.esm.js +59 -59
- package/components/smoke-detector/index.umd.cjs +1 -1
- package/components/splitter/index.esm.js +103 -103
- package/components/splitter/index.umd.cjs +1 -1
- package/components/step/index.esm.js +85 -85
- package/components/step/index.umd.cjs +1 -1
- package/components/switch/index.esm.js +457 -378
- package/components/switch/index.umd.cjs +1 -1
- package/components/tabs/index.css +1 -1
- package/components/tabs/index.esm.js +1696 -1617
- package/components/tabs/index.umd.cjs +1 -1
- package/components/tags/index.esm.js +53 -53
- package/components/tags/index.umd.cjs +1 -1
- package/components/text/index.esm.js +268 -268
- package/components/text/index.umd.cjs +1 -1
- package/components/textarea/index.esm.js +420 -341
- package/components/textarea/index.umd.cjs +1 -1
- package/components/time-picker/index.css +1 -1
- package/components/time-picker/index.esm.js +1062 -981
- package/components/time-picker/index.umd.cjs +1 -1
- package/components/transfer/index.css +1 -1
- package/components/transfer/index.esm.js +381 -379
- package/components/transfer/index.umd.cjs +1 -1
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5252 -9560
- package/components/tree-grid/index.umd.cjs +1 -1
- package/components/tree-view/index.css +1 -0
- package/components/tree-view/index.esm.js +3920 -2692
- package/components/tree-view/index.umd.cjs +1 -1
- package/components/uploader/index.esm.js +373 -367
- package/components/uploader/index.umd.cjs +2 -2
- package/components/verify-detail/index.esm.js +92 -92
- package/components/verify-detail/index.umd.cjs +1 -1
- package/components/video/index.esm.js +597 -417
- package/components/video/index.umd.cjs +1 -1
- package/components/weather/index.esm.js +251 -251
- package/components/weather/index.umd.cjs +4 -4
- package/farris.all.esm.js +17125 -16176
- package/farris.all.umd.cjs +8 -8
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/capsule/src/capsule.props.d.ts +2 -2
- package/types/combo-list/src/components/list-container.component.d.ts +0 -3
- package/types/combo-list/src/components/list-container.props.d.ts +0 -4
- 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.props.d.ts +7 -0
- package/types/component/src/designer/use-designer-rules.d.ts +1 -1
- 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 +5 -2
- package/types/data-grid/src/data-grid.component.d.ts +2 -1
- package/types/data-grid/src/data-grid.props.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +18 -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/types.d.ts +1 -1
- 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 +1 -0
- 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/types.d.ts +9 -0
- 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/tabs/src/tabs.props.d.ts +1 -0
- package/types/tree-grid/index.d.ts +8 -2
- package/types/tree-grid/src/tree-grid.component.d.ts +3 -1
- package/types/data-grid/src/designer/use-group-column.d.ts +0 -20
- 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,5 +1,8 @@
|
|
|
1
|
-
import { defineComponent as ce, ref as
|
|
2
|
-
import { cloneDeep as
|
|
1
|
+
import { defineComponent as ce, ref as w, watch as je, computed as _, createVNode as N, createTextVNode as le, nextTick as Pe, inject as Ae, onMounted as Te } from "vue";
|
|
2
|
+
import { isPlainObject as te, cloneDeep as Ee } from "lodash-es";
|
|
3
|
+
import { BaseControlProperty as Se } from "../property-panel/index.esm.js/src/composition/entity/base-property";
|
|
4
|
+
import { useResponseLayoutEditorSetting as De } from "../response-layout-editor/index.esm.js/src/composition/converter/use-response-layout-editor-setting";
|
|
5
|
+
import { DgControl as we } from "../designer-canvas/index.esm.js/src/composition/dg-control";
|
|
3
6
|
var Y = function(n, t) {
|
|
4
7
|
return Y = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e, r) {
|
|
5
8
|
e.__proto__ = r;
|
|
@@ -7,7 +10,7 @@ var Y = function(n, t) {
|
|
|
7
10
|
for (var o in r) Object.prototype.hasOwnProperty.call(r, o) && (e[o] = r[o]);
|
|
8
11
|
}, Y(n, t);
|
|
9
12
|
};
|
|
10
|
-
function
|
|
13
|
+
function pe(n, t) {
|
|
11
14
|
if (typeof t != "function" && t !== null)
|
|
12
15
|
throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
|
|
13
16
|
Y(n, t);
|
|
@@ -16,7 +19,7 @@ function se(n, t) {
|
|
|
16
19
|
}
|
|
17
20
|
n.prototype = t === null ? Object.create(t) : (e.prototype = t.prototype, new e());
|
|
18
21
|
}
|
|
19
|
-
function
|
|
22
|
+
function ne(n) {
|
|
20
23
|
var t = typeof Symbol == "function" && Symbol.iterator, e = t && n[t], r = 0;
|
|
21
24
|
if (e) return e.call(n);
|
|
22
25
|
if (n && typeof n.length == "number") return {
|
|
@@ -26,38 +29,38 @@ function ee(n) {
|
|
|
26
29
|
};
|
|
27
30
|
throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
28
31
|
}
|
|
29
|
-
function
|
|
32
|
+
function X(n, t) {
|
|
30
33
|
var e = typeof Symbol == "function" && n[Symbol.iterator];
|
|
31
34
|
if (!e) return n;
|
|
32
|
-
var r = e.call(n), o,
|
|
35
|
+
var r = e.call(n), o, s = [], f;
|
|
33
36
|
try {
|
|
34
|
-
for (; (t === void 0 || t-- > 0) && !(o = r.next()).done; )
|
|
37
|
+
for (; (t === void 0 || t-- > 0) && !(o = r.next()).done; ) s.push(o.value);
|
|
35
38
|
} catch (d) {
|
|
36
|
-
|
|
39
|
+
f = { error: d };
|
|
37
40
|
} finally {
|
|
38
41
|
try {
|
|
39
42
|
o && !o.done && (e = r.return) && e.call(r);
|
|
40
43
|
} finally {
|
|
41
|
-
if (
|
|
44
|
+
if (f) throw f.error;
|
|
42
45
|
}
|
|
43
46
|
}
|
|
44
|
-
return
|
|
47
|
+
return s;
|
|
45
48
|
}
|
|
46
|
-
function
|
|
47
|
-
if (e || arguments.length === 2) for (var r = 0, o = t.length,
|
|
48
|
-
(
|
|
49
|
-
return n.concat(
|
|
49
|
+
function H(n, t, e) {
|
|
50
|
+
if (e || arguments.length === 2) for (var r = 0, o = t.length, s; r < o; r++)
|
|
51
|
+
(s || !(r in t)) && (s || (s = Array.prototype.slice.call(t, 0, r)), s[r] = t[r]);
|
|
52
|
+
return n.concat(s || Array.prototype.slice.call(t));
|
|
50
53
|
}
|
|
51
54
|
function O(n) {
|
|
52
55
|
return typeof n == "function";
|
|
53
56
|
}
|
|
54
|
-
function
|
|
57
|
+
function Ne(n) {
|
|
55
58
|
var t = function(r) {
|
|
56
59
|
Error.call(r), r.stack = new Error().stack;
|
|
57
60
|
}, e = n(t);
|
|
58
61
|
return e.prototype = Object.create(Error.prototype), e.prototype.constructor = e, e;
|
|
59
62
|
}
|
|
60
|
-
var U =
|
|
63
|
+
var U = Ne(function(n) {
|
|
61
64
|
return function(e) {
|
|
62
65
|
n(this), this.message = e ? e.length + ` errors occurred during unsubscription:
|
|
63
66
|
` + e.map(function(r, o) {
|
|
@@ -66,76 +69,76 @@ var U = Te(function(n) {
|
|
|
66
69
|
`) : "", this.name = "UnsubscriptionError", this.errors = e;
|
|
67
70
|
};
|
|
68
71
|
});
|
|
69
|
-
function
|
|
72
|
+
function re(n, t) {
|
|
70
73
|
if (n) {
|
|
71
74
|
var e = n.indexOf(t);
|
|
72
75
|
0 <= e && n.splice(e, 1);
|
|
73
76
|
}
|
|
74
77
|
}
|
|
75
|
-
var
|
|
78
|
+
var Q = function() {
|
|
76
79
|
function n(t) {
|
|
77
80
|
this.initialTeardown = t, this.closed = !1, this._parentage = null, this._finalizers = null;
|
|
78
81
|
}
|
|
79
82
|
return n.prototype.unsubscribe = function() {
|
|
80
|
-
var t, e, r, o,
|
|
83
|
+
var t, e, r, o, s;
|
|
81
84
|
if (!this.closed) {
|
|
82
85
|
this.closed = !0;
|
|
83
|
-
var
|
|
84
|
-
if (
|
|
85
|
-
if (this._parentage = null, Array.isArray(
|
|
86
|
+
var f = this._parentage;
|
|
87
|
+
if (f)
|
|
88
|
+
if (this._parentage = null, Array.isArray(f))
|
|
86
89
|
try {
|
|
87
|
-
for (var d =
|
|
88
|
-
var
|
|
89
|
-
|
|
90
|
+
for (var d = ne(f), y = d.next(); !y.done; y = d.next()) {
|
|
91
|
+
var a = y.value;
|
|
92
|
+
a.remove(this);
|
|
90
93
|
}
|
|
91
94
|
} catch (c) {
|
|
92
95
|
t = { error: c };
|
|
93
96
|
} finally {
|
|
94
97
|
try {
|
|
95
|
-
|
|
98
|
+
y && !y.done && (e = d.return) && e.call(d);
|
|
96
99
|
} finally {
|
|
97
100
|
if (t) throw t.error;
|
|
98
101
|
}
|
|
99
102
|
}
|
|
100
103
|
else
|
|
101
|
-
|
|
102
|
-
var
|
|
103
|
-
if (O(
|
|
104
|
+
f.remove(this);
|
|
105
|
+
var l = this.initialTeardown;
|
|
106
|
+
if (O(l))
|
|
104
107
|
try {
|
|
105
|
-
|
|
108
|
+
l();
|
|
106
109
|
} catch (c) {
|
|
107
|
-
|
|
110
|
+
s = c instanceof U ? c.errors : [c];
|
|
108
111
|
}
|
|
109
|
-
var
|
|
110
|
-
if (
|
|
112
|
+
var i = this._finalizers;
|
|
113
|
+
if (i) {
|
|
111
114
|
this._finalizers = null;
|
|
112
115
|
try {
|
|
113
|
-
for (var
|
|
114
|
-
var
|
|
116
|
+
for (var h = ne(i), g = h.next(); !g.done; g = h.next()) {
|
|
117
|
+
var p = g.value;
|
|
115
118
|
try {
|
|
116
|
-
|
|
119
|
+
oe(p);
|
|
117
120
|
} catch (c) {
|
|
118
|
-
|
|
121
|
+
s = s ?? [], c instanceof U ? s = H(H([], X(s)), X(c.errors)) : s.push(c);
|
|
119
122
|
}
|
|
120
123
|
}
|
|
121
124
|
} catch (c) {
|
|
122
125
|
r = { error: c };
|
|
123
126
|
} finally {
|
|
124
127
|
try {
|
|
125
|
-
|
|
128
|
+
g && !g.done && (o = h.return) && o.call(h);
|
|
126
129
|
} finally {
|
|
127
130
|
if (r) throw r.error;
|
|
128
131
|
}
|
|
129
132
|
}
|
|
130
133
|
}
|
|
131
|
-
if (
|
|
132
|
-
throw new U(
|
|
134
|
+
if (s)
|
|
135
|
+
throw new U(s);
|
|
133
136
|
}
|
|
134
137
|
}, n.prototype.add = function(t) {
|
|
135
138
|
var e;
|
|
136
139
|
if (t && t !== this)
|
|
137
140
|
if (this.closed)
|
|
138
|
-
|
|
141
|
+
oe(t);
|
|
139
142
|
else {
|
|
140
143
|
if (t instanceof n) {
|
|
141
144
|
if (t.closed || t._hasParent(this))
|
|
@@ -152,57 +155,57 @@ var X = function() {
|
|
|
152
155
|
this._parentage = Array.isArray(e) ? (e.push(t), e) : e ? [e, t] : t;
|
|
153
156
|
}, n.prototype._removeParent = function(t) {
|
|
154
157
|
var e = this._parentage;
|
|
155
|
-
e === t ? this._parentage = null : Array.isArray(e) &&
|
|
158
|
+
e === t ? this._parentage = null : Array.isArray(e) && re(e, t);
|
|
156
159
|
}, n.prototype.remove = function(t) {
|
|
157
160
|
var e = this._finalizers;
|
|
158
|
-
e &&
|
|
161
|
+
e && re(e, t), t instanceof n && t._removeParent(this);
|
|
159
162
|
}, n.EMPTY = function() {
|
|
160
163
|
var t = new n();
|
|
161
164
|
return t.closed = !0, t;
|
|
162
165
|
}(), n;
|
|
163
166
|
}();
|
|
164
|
-
|
|
165
|
-
function
|
|
166
|
-
return n instanceof
|
|
167
|
+
Q.EMPTY;
|
|
168
|
+
function ue(n) {
|
|
169
|
+
return n instanceof Q || n && "closed" in n && O(n.remove) && O(n.add) && O(n.unsubscribe);
|
|
167
170
|
}
|
|
168
|
-
function
|
|
171
|
+
function oe(n) {
|
|
169
172
|
O(n) ? n() : n.unsubscribe();
|
|
170
173
|
}
|
|
171
|
-
var
|
|
174
|
+
var fe = {
|
|
172
175
|
onUnhandledError: null,
|
|
173
176
|
onStoppedNotification: null,
|
|
174
177
|
Promise: void 0,
|
|
175
178
|
useDeprecatedSynchronousErrorHandling: !1,
|
|
176
179
|
useDeprecatedNextContext: !1
|
|
177
|
-
},
|
|
180
|
+
}, Me = {
|
|
178
181
|
setTimeout: function(n, t) {
|
|
179
182
|
for (var e = [], r = 2; r < arguments.length; r++)
|
|
180
183
|
e[r - 2] = arguments[r];
|
|
181
|
-
return setTimeout.apply(void 0,
|
|
184
|
+
return setTimeout.apply(void 0, H([n, t], X(e)));
|
|
182
185
|
},
|
|
183
186
|
clearTimeout: function(n) {
|
|
184
187
|
return clearTimeout(n);
|
|
185
188
|
},
|
|
186
189
|
delegate: void 0
|
|
187
190
|
};
|
|
188
|
-
function
|
|
189
|
-
|
|
191
|
+
function ke(n) {
|
|
192
|
+
Me.setTimeout(function() {
|
|
190
193
|
throw n;
|
|
191
194
|
});
|
|
192
195
|
}
|
|
193
|
-
function
|
|
196
|
+
function se() {
|
|
194
197
|
}
|
|
195
|
-
function
|
|
198
|
+
function Oe(n) {
|
|
196
199
|
n();
|
|
197
200
|
}
|
|
198
|
-
var
|
|
199
|
-
|
|
201
|
+
var de = function(n) {
|
|
202
|
+
pe(t, n);
|
|
200
203
|
function t(e) {
|
|
201
204
|
var r = n.call(this) || this;
|
|
202
|
-
return r.isStopped = !1, e ? (r.destination = e,
|
|
205
|
+
return r.isStopped = !1, e ? (r.destination = e, ue(e) && e.add(r)) : r.destination = Be, r;
|
|
203
206
|
}
|
|
204
207
|
return t.create = function(e, r, o) {
|
|
205
|
-
return new
|
|
208
|
+
return new J(e, r, o);
|
|
206
209
|
}, t.prototype.next = function(e) {
|
|
207
210
|
this.isStopped || this._next(e);
|
|
208
211
|
}, t.prototype.error = function(e) {
|
|
@@ -226,11 +229,11 @@ var ue = function(n) {
|
|
|
226
229
|
this.unsubscribe();
|
|
227
230
|
}
|
|
228
231
|
}, t;
|
|
229
|
-
}(
|
|
230
|
-
function
|
|
231
|
-
return
|
|
232
|
+
}(Q), Le = Function.prototype.bind;
|
|
233
|
+
function W(n, t) {
|
|
234
|
+
return Le.call(n, t);
|
|
232
235
|
}
|
|
233
|
-
var
|
|
236
|
+
var Fe = function() {
|
|
234
237
|
function n(t) {
|
|
235
238
|
this.partialObserver = t;
|
|
236
239
|
}
|
|
@@ -240,7 +243,7 @@ var Ne = function() {
|
|
|
240
243
|
try {
|
|
241
244
|
e.next(t);
|
|
242
245
|
} catch (r) {
|
|
243
|
-
|
|
246
|
+
I(r);
|
|
244
247
|
}
|
|
245
248
|
}, n.prototype.error = function(t) {
|
|
246
249
|
var e = this.partialObserver;
|
|
@@ -248,68 +251,68 @@ var Ne = function() {
|
|
|
248
251
|
try {
|
|
249
252
|
e.error(t);
|
|
250
253
|
} catch (r) {
|
|
251
|
-
|
|
254
|
+
I(r);
|
|
252
255
|
}
|
|
253
256
|
else
|
|
254
|
-
|
|
257
|
+
I(t);
|
|
255
258
|
}, n.prototype.complete = function() {
|
|
256
259
|
var t = this.partialObserver;
|
|
257
260
|
if (t.complete)
|
|
258
261
|
try {
|
|
259
262
|
t.complete();
|
|
260
263
|
} catch (e) {
|
|
261
|
-
|
|
264
|
+
I(e);
|
|
262
265
|
}
|
|
263
266
|
}, n;
|
|
264
|
-
}(),
|
|
265
|
-
|
|
267
|
+
}(), J = function(n) {
|
|
268
|
+
pe(t, n);
|
|
266
269
|
function t(e, r, o) {
|
|
267
|
-
var
|
|
270
|
+
var s = n.call(this) || this, f;
|
|
268
271
|
if (O(e) || !e)
|
|
269
|
-
|
|
272
|
+
f = {
|
|
270
273
|
next: e ?? void 0,
|
|
271
274
|
error: r ?? void 0,
|
|
272
275
|
complete: o ?? void 0
|
|
273
276
|
};
|
|
274
277
|
else {
|
|
275
278
|
var d;
|
|
276
|
-
|
|
277
|
-
return
|
|
278
|
-
},
|
|
279
|
-
next: e.next &&
|
|
280
|
-
error: e.error &&
|
|
281
|
-
complete: e.complete &&
|
|
282
|
-
}) :
|
|
279
|
+
s && fe.useDeprecatedNextContext ? (d = Object.create(e), d.unsubscribe = function() {
|
|
280
|
+
return s.unsubscribe();
|
|
281
|
+
}, f = {
|
|
282
|
+
next: e.next && W(e.next, d),
|
|
283
|
+
error: e.error && W(e.error, d),
|
|
284
|
+
complete: e.complete && W(e.complete, d)
|
|
285
|
+
}) : f = e;
|
|
283
286
|
}
|
|
284
|
-
return
|
|
287
|
+
return s.destination = new Fe(f), s;
|
|
285
288
|
}
|
|
286
289
|
return t;
|
|
287
|
-
}(
|
|
288
|
-
function
|
|
289
|
-
|
|
290
|
+
}(de);
|
|
291
|
+
function I(n) {
|
|
292
|
+
ke(n);
|
|
290
293
|
}
|
|
291
|
-
function
|
|
294
|
+
function _e(n) {
|
|
292
295
|
throw n;
|
|
293
296
|
}
|
|
294
|
-
var
|
|
297
|
+
var Be = {
|
|
295
298
|
closed: !0,
|
|
296
|
-
next:
|
|
297
|
-
error:
|
|
298
|
-
complete:
|
|
299
|
-
},
|
|
299
|
+
next: se,
|
|
300
|
+
error: _e,
|
|
301
|
+
complete: se
|
|
302
|
+
}, $e = function() {
|
|
300
303
|
return typeof Symbol == "function" && Symbol.observable || "@@observable";
|
|
301
304
|
}();
|
|
302
|
-
function
|
|
305
|
+
function xe(n) {
|
|
303
306
|
return n;
|
|
304
307
|
}
|
|
305
|
-
function
|
|
306
|
-
return n.length === 0 ?
|
|
308
|
+
function Ie(n) {
|
|
309
|
+
return n.length === 0 ? xe : n.length === 1 ? n[0] : function(e) {
|
|
307
310
|
return n.reduce(function(r, o) {
|
|
308
311
|
return o(r);
|
|
309
312
|
}, e);
|
|
310
313
|
};
|
|
311
314
|
}
|
|
312
|
-
var
|
|
315
|
+
var qe = function() {
|
|
313
316
|
function n(t) {
|
|
314
317
|
t && (this._subscribe = t);
|
|
315
318
|
}
|
|
@@ -317,11 +320,11 @@ var Le = function() {
|
|
|
317
320
|
var e = new n();
|
|
318
321
|
return e.source = this, e.operator = t, e;
|
|
319
322
|
}, n.prototype.subscribe = function(t, e, r) {
|
|
320
|
-
var o = this,
|
|
321
|
-
return
|
|
322
|
-
var
|
|
323
|
-
|
|
324
|
-
}),
|
|
323
|
+
var o = this, s = Ue(t) ? t : new J(t, e, r);
|
|
324
|
+
return Oe(function() {
|
|
325
|
+
var f = o, d = f.operator, y = f.source;
|
|
326
|
+
s.add(d ? d.call(s, y) : y ? o._subscribe(s) : o._trySubscribe(s));
|
|
327
|
+
}), s;
|
|
325
328
|
}, n.prototype._trySubscribe = function(t) {
|
|
326
329
|
try {
|
|
327
330
|
return this._subscribe(t);
|
|
@@ -330,160 +333,160 @@ var Le = function() {
|
|
|
330
333
|
}
|
|
331
334
|
}, n.prototype.forEach = function(t, e) {
|
|
332
335
|
var r = this;
|
|
333
|
-
return e =
|
|
334
|
-
var
|
|
336
|
+
return e = ae(e), new e(function(o, s) {
|
|
337
|
+
var f = new J({
|
|
335
338
|
next: function(d) {
|
|
336
339
|
try {
|
|
337
340
|
t(d);
|
|
338
|
-
} catch (
|
|
339
|
-
|
|
341
|
+
} catch (y) {
|
|
342
|
+
s(y), f.unsubscribe();
|
|
340
343
|
}
|
|
341
344
|
},
|
|
342
|
-
error:
|
|
345
|
+
error: s,
|
|
343
346
|
complete: o
|
|
344
347
|
});
|
|
345
|
-
r.subscribe(
|
|
348
|
+
r.subscribe(f);
|
|
346
349
|
});
|
|
347
350
|
}, n.prototype._subscribe = function(t) {
|
|
348
351
|
var e;
|
|
349
352
|
return (e = this.source) === null || e === void 0 ? void 0 : e.subscribe(t);
|
|
350
|
-
}, n.prototype[
|
|
353
|
+
}, n.prototype[$e] = function() {
|
|
351
354
|
return this;
|
|
352
355
|
}, n.prototype.pipe = function() {
|
|
353
356
|
for (var t = [], e = 0; e < arguments.length; e++)
|
|
354
357
|
t[e] = arguments[e];
|
|
355
|
-
return
|
|
358
|
+
return Ie(t)(this);
|
|
356
359
|
}, n.prototype.toPromise = function(t) {
|
|
357
360
|
var e = this;
|
|
358
|
-
return t =
|
|
359
|
-
var
|
|
360
|
-
e.subscribe(function(
|
|
361
|
-
return
|
|
362
|
-
}, function(
|
|
363
|
-
return o(
|
|
361
|
+
return t = ae(t), new t(function(r, o) {
|
|
362
|
+
var s;
|
|
363
|
+
e.subscribe(function(f) {
|
|
364
|
+
return s = f;
|
|
365
|
+
}, function(f) {
|
|
366
|
+
return o(f);
|
|
364
367
|
}, function() {
|
|
365
|
-
return r(
|
|
368
|
+
return r(s);
|
|
366
369
|
});
|
|
367
370
|
});
|
|
368
371
|
}, n.create = function(t) {
|
|
369
372
|
return new n(t);
|
|
370
373
|
}, n;
|
|
371
374
|
}();
|
|
372
|
-
function
|
|
375
|
+
function ae(n) {
|
|
373
376
|
var t;
|
|
374
|
-
return (t = n ??
|
|
377
|
+
return (t = n ?? fe.Promise) !== null && t !== void 0 ? t : Promise;
|
|
375
378
|
}
|
|
376
|
-
function
|
|
379
|
+
function Ve(n) {
|
|
377
380
|
return n && O(n.next) && O(n.error) && O(n.complete);
|
|
378
381
|
}
|
|
379
|
-
function
|
|
380
|
-
return n && n instanceof
|
|
382
|
+
function Ue(n) {
|
|
383
|
+
return n && n instanceof de || Ve(n) && ue(n);
|
|
381
384
|
}
|
|
382
|
-
const
|
|
385
|
+
const ye = {}, he = {};
|
|
383
386
|
function Z(n) {
|
|
384
|
-
const { properties: t, title: e, ignore: r } = n, o = r && Array.isArray(r),
|
|
385
|
-
return (!o || !r.find((
|
|
387
|
+
const { properties: t, title: e, ignore: r } = n, o = r && Array.isArray(r), s = Object.keys(t).reduce((f, d) => ((!o || !r.find((y) => y == d)) && (f[d] = t[d].type === "object" && t[d].properties ? Z(t[d]) : Ee(t[d].default)), f), {});
|
|
388
|
+
return (!o || !r.find((f) => f == "id")) && (s.id = `${e}-${Date.now()}`), s;
|
|
386
389
|
}
|
|
387
390
|
function $(n, t = {}, e) {
|
|
388
|
-
const r =
|
|
391
|
+
const r = ye[n];
|
|
389
392
|
if (r) {
|
|
390
393
|
let o = Z(r);
|
|
391
|
-
const
|
|
392
|
-
return o =
|
|
394
|
+
const s = he[n];
|
|
395
|
+
return o = s ? s({ getSchemaByType: $ }, o, t, e) : o, o;
|
|
393
396
|
}
|
|
394
397
|
return null;
|
|
395
398
|
}
|
|
396
|
-
function
|
|
399
|
+
function We(n, t) {
|
|
397
400
|
const e = Z(t);
|
|
398
|
-
return Object.keys(n).reduce((r, o) => (r[o] &&
|
|
401
|
+
return Object.keys(n).reduce((r, o) => (r[o] && te(r[o]) && te(n[o]) ? Object.assign(r[o], n[o]) : r[o] = n[o], r), e), e;
|
|
399
402
|
}
|
|
400
|
-
function
|
|
403
|
+
function Ge(n, t) {
|
|
401
404
|
return Object.keys(n).filter((r) => n[r] != null).reduce((r, o) => {
|
|
402
405
|
if (t.has(o)) {
|
|
403
|
-
const
|
|
404
|
-
if (typeof
|
|
405
|
-
r[
|
|
406
|
+
const s = t.get(o);
|
|
407
|
+
if (typeof s == "string")
|
|
408
|
+
r[s] = n[o];
|
|
406
409
|
else {
|
|
407
|
-
const
|
|
408
|
-
Object.assign(r,
|
|
410
|
+
const f = s(o, n[o], n);
|
|
411
|
+
Object.assign(r, f);
|
|
409
412
|
}
|
|
410
413
|
} else
|
|
411
414
|
r[o] = n[o];
|
|
412
415
|
return r;
|
|
413
416
|
}, {});
|
|
414
417
|
}
|
|
415
|
-
function
|
|
416
|
-
const r =
|
|
417
|
-
return
|
|
418
|
+
function ze(n, t, e = /* @__PURE__ */ new Map()) {
|
|
419
|
+
const r = We(n, t);
|
|
420
|
+
return Ge(r, e);
|
|
418
421
|
}
|
|
419
|
-
function
|
|
420
|
-
function t(
|
|
421
|
-
if (typeof
|
|
422
|
-
return
|
|
423
|
-
if (typeof
|
|
424
|
-
const
|
|
425
|
-
if (
|
|
426
|
-
return Number(
|
|
427
|
-
if (
|
|
428
|
-
return Number(
|
|
429
|
-
if (
|
|
430
|
-
return Number(
|
|
422
|
+
function Ye(n = {}) {
|
|
423
|
+
function t(a, l, i, h) {
|
|
424
|
+
if (typeof i == "number")
|
|
425
|
+
return h[a].length === i;
|
|
426
|
+
if (typeof i == "object") {
|
|
427
|
+
const g = Object.keys(i)[0], p = i[g];
|
|
428
|
+
if (g === "not")
|
|
429
|
+
return Number(h[a].length) !== Number(p);
|
|
430
|
+
if (g === "moreThan")
|
|
431
|
+
return Number(h[a].length) >= Number(p);
|
|
432
|
+
if (g === "lessThan")
|
|
433
|
+
return Number(h[a].length) <= Number(p);
|
|
431
434
|
}
|
|
432
435
|
return !1;
|
|
433
436
|
}
|
|
434
|
-
function e(
|
|
435
|
-
return
|
|
437
|
+
function e(a, l, i, h) {
|
|
438
|
+
return h[a] && h[a].propertyValue && String(h[a].propertyValue.value) === String(i);
|
|
436
439
|
}
|
|
437
440
|
const r = /* @__PURE__ */ new Map([
|
|
438
441
|
["length", t],
|
|
439
442
|
["getProperty", e]
|
|
440
443
|
]);
|
|
441
|
-
Object.keys(n).reduce((
|
|
442
|
-
function o(
|
|
443
|
-
const
|
|
444
|
-
return typeof
|
|
445
|
-
if (
|
|
446
|
-
return { target:
|
|
447
|
-
const
|
|
448
|
-
return { target:
|
|
444
|
+
Object.keys(n).reduce((a, l) => (a.set(l, n[l]), a), r);
|
|
445
|
+
function o(a, l) {
|
|
446
|
+
const i = a;
|
|
447
|
+
return typeof l == "number" ? [{ target: i, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: i, operator: "getProperty", param: a, value: !!l }] : typeof l == "object" ? Object.keys(l).map((h) => {
|
|
448
|
+
if (h === "length")
|
|
449
|
+
return { target: i, operator: "length", param: null, value: l[h] };
|
|
450
|
+
const g = h, p = l[h];
|
|
451
|
+
return { target: i, operator: "getProperty", param: g, value: p };
|
|
449
452
|
}) : [];
|
|
450
453
|
}
|
|
451
|
-
function a
|
|
452
|
-
return Object.keys(
|
|
453
|
-
const
|
|
454
|
-
return
|
|
454
|
+
function s(a) {
|
|
455
|
+
return Object.keys(a).reduce((i, h) => {
|
|
456
|
+
const g = o(h, a[h]);
|
|
457
|
+
return i.push(...g), i;
|
|
455
458
|
}, []);
|
|
456
459
|
}
|
|
457
|
-
function
|
|
458
|
-
if (r.has(
|
|
459
|
-
const
|
|
460
|
-
return
|
|
460
|
+
function f(a, l) {
|
|
461
|
+
if (r.has(a.operator)) {
|
|
462
|
+
const i = r.get(a.operator);
|
|
463
|
+
return i && i(a.target, a.param, a.value, l) || !1;
|
|
461
464
|
}
|
|
462
465
|
return !1;
|
|
463
466
|
}
|
|
464
|
-
function d(
|
|
465
|
-
return a
|
|
467
|
+
function d(a, l) {
|
|
468
|
+
return s(a).reduce((g, p) => g && f(p, l), !0);
|
|
466
469
|
}
|
|
467
|
-
function
|
|
468
|
-
const
|
|
469
|
-
return
|
|
470
|
+
function y(a, l) {
|
|
471
|
+
const i = Object.keys(a), h = i.includes("allOf"), g = i.includes("anyOf"), p = h || g, m = (p ? a[p ? h ? "allOf" : "anyOf" : "allOf"] : [a]).map((C) => d(C, l));
|
|
472
|
+
return h ? !m.includes(!1) : m.includes(!0);
|
|
470
473
|
}
|
|
471
|
-
return { parseValueSchema:
|
|
474
|
+
return { parseValueSchema: y };
|
|
472
475
|
}
|
|
473
|
-
const
|
|
474
|
-
|
|
475
|
-
function
|
|
476
|
-
return
|
|
477
|
-
const d =
|
|
478
|
-
return Object.assign(
|
|
476
|
+
const Xe = {}, He = {};
|
|
477
|
+
Ye();
|
|
478
|
+
function Je(n, t, e = /* @__PURE__ */ new Map(), r = (f, d, y) => d, o = {}, s = (f) => f) {
|
|
479
|
+
return ye[t.title] = t, he[t.title] = r, Xe[t.title] = o, He[t.title] = s, (f = {}) => {
|
|
480
|
+
const d = ze(f, t, e), y = Object.keys(n).reduce((a, l) => (a[l] = n[l].default, a), {});
|
|
481
|
+
return Object.assign(y, d);
|
|
479
482
|
};
|
|
480
483
|
}
|
|
481
|
-
function
|
|
484
|
+
function Qe(n, t) {
|
|
482
485
|
return { customClass: t.class, customStyle: t.style };
|
|
483
486
|
}
|
|
484
|
-
const
|
|
485
|
-
["appearance",
|
|
486
|
-
]),
|
|
487
|
+
const Ze = /* @__PURE__ */ new Map([
|
|
488
|
+
["appearance", Qe]
|
|
489
|
+
]), Re = "https://json-schema.org/draft/2020-12/schema", Ke = "https://farris-design.gitee.io/nav.schema.json", et = "nav", tt = "A Farris Component", nt = "object", rt = {
|
|
487
490
|
id: {
|
|
488
491
|
description: "The unique identifier for a nav",
|
|
489
492
|
type: "string"
|
|
@@ -575,22 +578,22 @@ const Ge = /* @__PURE__ */ new Map([
|
|
|
575
578
|
type: "sting",
|
|
576
579
|
default: ""
|
|
577
580
|
}
|
|
578
|
-
},
|
|
581
|
+
}, ot = [
|
|
579
582
|
"id",
|
|
580
583
|
"type"
|
|
581
|
-
],
|
|
582
|
-
$schema:
|
|
583
|
-
$id:
|
|
584
|
-
title:
|
|
585
|
-
description:
|
|
586
|
-
type:
|
|
587
|
-
properties:
|
|
588
|
-
required:
|
|
584
|
+
], st = {
|
|
585
|
+
$schema: Re,
|
|
586
|
+
$id: Ke,
|
|
587
|
+
title: et,
|
|
588
|
+
description: tt,
|
|
589
|
+
type: nt,
|
|
590
|
+
properties: rt,
|
|
591
|
+
required: ot
|
|
589
592
|
};
|
|
590
|
-
function
|
|
593
|
+
function at(n, t, e) {
|
|
591
594
|
return t;
|
|
592
595
|
}
|
|
593
|
-
const
|
|
596
|
+
const it = "nav", ct = "A Farris Component", lt = "object", pt = {
|
|
594
597
|
basic: {
|
|
595
598
|
description: "Basic Infomation",
|
|
596
599
|
title: "基本信息",
|
|
@@ -672,11 +675,11 @@ const nt = "nav", rt = "A Farris Component", ot = "object", at = {
|
|
|
672
675
|
}
|
|
673
676
|
}
|
|
674
677
|
}
|
|
675
|
-
},
|
|
676
|
-
title:
|
|
677
|
-
description:
|
|
678
|
-
type:
|
|
679
|
-
categories:
|
|
678
|
+
}, ut = {
|
|
679
|
+
title: it,
|
|
680
|
+
description: ct,
|
|
681
|
+
type: lt,
|
|
682
|
+
categories: pt
|
|
680
683
|
}, R = {
|
|
681
684
|
/** 未读最大值 */
|
|
682
685
|
maxNum: { Type: Number, default: 99 },
|
|
@@ -710,177 +713,177 @@ const nt = "nav", rt = "A Farris Component", ot = "object", at = {
|
|
|
710
713
|
/** 当前激活的id */
|
|
711
714
|
activeNavId: { Type: String, default: "1" },
|
|
712
715
|
/** nav切换前事件 */
|
|
713
|
-
navPicking: { Type: Function, default: (n) =>
|
|
714
|
-
},
|
|
716
|
+
navPicking: { Type: Function, default: (n) => qe }
|
|
717
|
+
}, ie = Je(R, st, Ze, at, ut), G = /* @__PURE__ */ ce({
|
|
715
718
|
name: "FNav",
|
|
716
719
|
props: R,
|
|
717
720
|
emits: ["nav", "update:activeNavId"],
|
|
718
721
|
setup(n, t) {
|
|
719
|
-
const e =
|
|
720
|
-
|
|
721
|
-
|
|
722
|
+
const e = w(n.activeNavId), r = w(n.navData), o = w(n.horizontal);
|
|
723
|
+
w(n.navPicking), je(() => n.activeNavId, (l, i) => {
|
|
724
|
+
l !== i && (e.value = l);
|
|
722
725
|
});
|
|
723
|
-
const
|
|
726
|
+
const s = _({
|
|
724
727
|
get() {
|
|
725
728
|
return r.value;
|
|
726
729
|
},
|
|
727
|
-
set(
|
|
728
|
-
r.value =
|
|
730
|
+
set(l) {
|
|
731
|
+
r.value = l, y();
|
|
729
732
|
}
|
|
730
|
-
}),
|
|
733
|
+
}), f = _({
|
|
731
734
|
get() {
|
|
732
735
|
return e.value;
|
|
733
736
|
},
|
|
734
|
-
set(
|
|
735
|
-
if (e.value =
|
|
736
|
-
const
|
|
737
|
-
|
|
737
|
+
set(l) {
|
|
738
|
+
if (e.value = l, e.value && s && s.value.length) {
|
|
739
|
+
const i = s.value.find((h) => h.id === e.value);
|
|
740
|
+
i && t.emit("nav", i);
|
|
738
741
|
}
|
|
739
742
|
}
|
|
740
|
-
}), d =
|
|
741
|
-
set(
|
|
742
|
-
o.value =
|
|
743
|
+
}), d = _({
|
|
744
|
+
set(l) {
|
|
745
|
+
o.value = l;
|
|
743
746
|
},
|
|
744
747
|
get() {
|
|
745
748
|
return o.value;
|
|
746
749
|
}
|
|
747
750
|
});
|
|
748
|
-
function
|
|
749
|
-
if (
|
|
750
|
-
const
|
|
751
|
-
|
|
751
|
+
function y() {
|
|
752
|
+
if (s.value && s.value.length && !e.value) {
|
|
753
|
+
const l = s.value.find((i) => !i.disable);
|
|
754
|
+
l && (e.value = l.id);
|
|
752
755
|
}
|
|
753
756
|
}
|
|
754
|
-
function
|
|
755
|
-
|
|
757
|
+
function a(l) {
|
|
758
|
+
l.disable || l.id === e.value || (e.value = l.id, t.emit("update:activeNavId", l.id), t.emit("nav", l));
|
|
756
759
|
}
|
|
757
760
|
return () => {
|
|
758
|
-
var
|
|
759
|
-
return
|
|
761
|
+
var l;
|
|
762
|
+
return N("div", {
|
|
760
763
|
class: ["farris-nav", {
|
|
761
764
|
"farris-nav-vertical": !d.value
|
|
762
765
|
}]
|
|
763
|
-
}, [(
|
|
766
|
+
}, [(l = s.value) == null ? void 0 : l.map((i) => N("div", {
|
|
764
767
|
class: ["farris-nav-item", {
|
|
765
|
-
active:
|
|
768
|
+
active: i.id === f.value
|
|
766
769
|
}, {
|
|
767
|
-
disabled:
|
|
770
|
+
disabled: i.disable
|
|
768
771
|
}],
|
|
769
|
-
onClick: () =>
|
|
770
|
-
}, [
|
|
772
|
+
onClick: () => a(i)
|
|
773
|
+
}, [N("div", {
|
|
771
774
|
class: "farris-nav-item-link"
|
|
772
|
-
}, [
|
|
775
|
+
}, [N("span", {
|
|
773
776
|
class: "farris-nav-item-link-text"
|
|
774
|
-
}, [typeof
|
|
777
|
+
}, [typeof i.text == "function" ? i.text() : i.text, i.num && N("div", {
|
|
775
778
|
class: "farris-nav-item-tag"
|
|
776
|
-
}, [
|
|
779
|
+
}, [i.num <= n.maxNum && N("span", {
|
|
777
780
|
class: "tag-text"
|
|
778
|
-
}, [
|
|
781
|
+
}, [i.num]), i.num > n.maxNum && N("span", {
|
|
779
782
|
class: "tag-text"
|
|
780
|
-
}, [n.maxNum,
|
|
783
|
+
}, [n.maxNum, le("+")])])])])]))]);
|
|
781
784
|
};
|
|
782
785
|
}
|
|
783
786
|
});
|
|
784
|
-
function
|
|
787
|
+
function ft(n, t, e) {
|
|
785
788
|
var M;
|
|
786
789
|
function r() {
|
|
787
790
|
e != null && e.resolveComponentContext && e.resolveComponentContext();
|
|
788
791
|
}
|
|
789
792
|
r();
|
|
790
|
-
const o = e && e.getStyles && e.getStyles() || "",
|
|
793
|
+
const o = e && e.getStyles && e.getStyles() || "", s = e && e.getDesignerClass && e.getDesignerClass() || "", f = w();
|
|
791
794
|
function d() {
|
|
792
795
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : e && e.checkCanMoveComponent ? e.checkCanMoveComponent() : !0;
|
|
793
796
|
}
|
|
794
|
-
function
|
|
797
|
+
function y() {
|
|
795
798
|
return !1;
|
|
796
799
|
}
|
|
797
|
-
function
|
|
800
|
+
function a() {
|
|
798
801
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !1 : e && e.checkCanDeleteComponent ? e.checkCanDeleteComponent() : !0;
|
|
799
802
|
}
|
|
800
|
-
function
|
|
803
|
+
function l() {
|
|
801
804
|
return (t == null ? void 0 : t.schema.componentType) === "frame" ? !0 : e && e.hideNestedPaddingInDesginerView ? e.hideNestedPaddingInDesginerView() : !1;
|
|
802
805
|
}
|
|
803
|
-
function
|
|
804
|
-
if (!
|
|
806
|
+
function i(b) {
|
|
807
|
+
if (!b || !b.value)
|
|
805
808
|
return null;
|
|
806
|
-
if (
|
|
807
|
-
return
|
|
808
|
-
const
|
|
809
|
-
return
|
|
809
|
+
if (b.value.schema && b.value.schema.type === "component")
|
|
810
|
+
return b.value;
|
|
811
|
+
const D = w(b == null ? void 0 : b.value.parent), E = i(D);
|
|
812
|
+
return E || null;
|
|
810
813
|
}
|
|
811
|
-
function b
|
|
812
|
-
const { componentInstance:
|
|
813
|
-
return !
|
|
814
|
+
function h(b = t) {
|
|
815
|
+
const { componentInstance: D, designerItemElementRef: E } = b;
|
|
816
|
+
return !D || !D.value ? null : D.value.canMove ? E : h(b.parent);
|
|
814
817
|
}
|
|
815
|
-
function
|
|
816
|
-
return !!e && e.canAccepts(
|
|
818
|
+
function g(b) {
|
|
819
|
+
return !!e && e.canAccepts(b);
|
|
817
820
|
}
|
|
818
|
-
function
|
|
821
|
+
function p() {
|
|
819
822
|
return (t == null ? void 0 : t.schema.label) || (t == null ? void 0 : t.schema.title) || (t == null ? void 0 : t.schema.name);
|
|
820
823
|
}
|
|
821
824
|
function c() {
|
|
822
825
|
}
|
|
823
|
-
function
|
|
824
|
-
|
|
826
|
+
function u(b, D) {
|
|
827
|
+
D && e != null && e.onAcceptMovedChildElement && e.onAcceptMovedChildElement(D);
|
|
825
828
|
}
|
|
826
|
-
function
|
|
827
|
-
const { componentType:
|
|
828
|
-
let
|
|
829
|
-
e && e.onResolveNewComponentSchema && (
|
|
830
|
-
const
|
|
831
|
-
return
|
|
829
|
+
function m(b, D) {
|
|
830
|
+
const { componentType: E } = b;
|
|
831
|
+
let v = $(E, b, D);
|
|
832
|
+
e && e.onResolveNewComponentSchema && (v = e.onResolveNewComponentSchema(b, v));
|
|
833
|
+
const P = E.toLowerCase().replace("-", "_");
|
|
834
|
+
return v && !v.id && v.type === E && (v.id = `${P}_${Math.random().toString().slice(2, 6)}`), v;
|
|
832
835
|
}
|
|
833
|
-
function A(
|
|
834
|
-
const
|
|
835
|
-
|
|
836
|
-
let
|
|
837
|
-
e && e.onAcceptNewChildElement && (
|
|
838
|
-
const
|
|
839
|
-
return
|
|
836
|
+
function A(b, D) {
|
|
837
|
+
const E = String(b.getAttribute("data-controltype")), v = b.getAttribute("data-feature"), P = v ? JSON.parse(v) : {};
|
|
838
|
+
P.parentComponentInstance = f.value;
|
|
839
|
+
let T = $(E, P);
|
|
840
|
+
e && e.onAcceptNewChildElement && (T = e.onAcceptNewChildElement(b, D, T));
|
|
841
|
+
const S = E.toLowerCase().replace("-", "_");
|
|
842
|
+
return T && !T.id && T.type === E && (T.id = `${S}_${Math.random().toString().slice(2, 6)}`), T;
|
|
840
843
|
}
|
|
841
|
-
function C(
|
|
844
|
+
function C(b) {
|
|
842
845
|
}
|
|
843
|
-
function
|
|
846
|
+
function j(...b) {
|
|
844
847
|
if (e && e.getPropsConfig)
|
|
845
|
-
return e.getPropsConfig(...
|
|
848
|
+
return e.getPropsConfig(...b);
|
|
846
849
|
}
|
|
847
|
-
return
|
|
850
|
+
return f.value = {
|
|
848
851
|
canMove: d(),
|
|
849
|
-
canSelectParent:
|
|
850
|
-
canDelete:
|
|
851
|
-
canNested: !
|
|
852
|
+
canSelectParent: y(),
|
|
853
|
+
canDelete: a(),
|
|
854
|
+
canNested: !l(),
|
|
852
855
|
contents: t == null ? void 0 : t.schema.contents,
|
|
853
856
|
elementRef: n,
|
|
854
857
|
parent: (M = t == null ? void 0 : t.parent) == null ? void 0 : M.componentInstance,
|
|
855
858
|
schema: t == null ? void 0 : t.schema,
|
|
856
859
|
styles: o,
|
|
857
|
-
designerClass:
|
|
858
|
-
canAccepts:
|
|
859
|
-
getBelongedComponentInstance:
|
|
860
|
-
getDraggableDesignItemElement:
|
|
861
|
-
getDraggingDisplayText:
|
|
862
|
-
getPropConfig:
|
|
860
|
+
designerClass: s,
|
|
861
|
+
canAccepts: g,
|
|
862
|
+
getBelongedComponentInstance: i,
|
|
863
|
+
getDraggableDesignItemElement: h,
|
|
864
|
+
getDraggingDisplayText: p,
|
|
865
|
+
getPropConfig: j,
|
|
863
866
|
getDragScopeElement: c,
|
|
864
|
-
onAcceptMovedChildElement:
|
|
867
|
+
onAcceptMovedChildElement: u,
|
|
865
868
|
onAcceptNewChildElement: A,
|
|
866
869
|
onChildElementMovedOut: C,
|
|
867
|
-
addNewChildComponentSchema:
|
|
870
|
+
addNewChildComponentSchema: m,
|
|
868
871
|
updateDragAndDropRules: r,
|
|
869
|
-
triggerBelongedComponentToMoveWhenMoved: !!e && e.triggerBelongedComponentToMoveWhenMoved ||
|
|
870
|
-
triggerBelongedComponentToDeleteWhenDeleted: !!e && e.triggerBelongedComponentToDeleteWhenDeleted ||
|
|
871
|
-
},
|
|
872
|
+
triggerBelongedComponentToMoveWhenMoved: !!e && e.triggerBelongedComponentToMoveWhenMoved || w(!1),
|
|
873
|
+
triggerBelongedComponentToDeleteWhenDeleted: !!e && e.triggerBelongedComponentToDeleteWhenDeleted || w(!1)
|
|
874
|
+
}, f;
|
|
872
875
|
}
|
|
873
|
-
function
|
|
876
|
+
function dt() {
|
|
874
877
|
function n(t) {
|
|
875
|
-
var o,
|
|
878
|
+
var o, s;
|
|
876
879
|
if (!t)
|
|
877
880
|
return !1;
|
|
878
881
|
const e = ((o = t.targetContainer) == null ? void 0 : o.componentInstance) && t.targetContainer.componentInstance.value;
|
|
879
882
|
if (!e)
|
|
880
883
|
return !1;
|
|
881
|
-
const r = (
|
|
884
|
+
const r = (s = e.schema.appearance) == null ? void 0 : s.class;
|
|
882
885
|
if (t.controlCategory === "input" || t.controlType === "form-group") {
|
|
883
|
-
const
|
|
886
|
+
const f = e.schema.type, d = (f === "response-form" || f === "content-container") && r && r.includes("farris-form");
|
|
884
887
|
if (e.schema.type !== "response-layout-item" && !d)
|
|
885
888
|
return !1;
|
|
886
889
|
}
|
|
@@ -890,7 +893,7 @@ function st() {
|
|
|
890
893
|
basalDragulaRuleForContainer: n
|
|
891
894
|
};
|
|
892
895
|
}
|
|
893
|
-
const
|
|
896
|
+
const yt = "https://json-schema.org/draft/2020-12/schema", ht = "https://farris-design.gitee.io/dragging-rules.schema.json", bt = "Dragging Rules", mt = "The rules of designer canvas", vt = "object", gt = {
|
|
894
897
|
"f-page": {
|
|
895
898
|
description: "The root class of page designed by farris.",
|
|
896
899
|
type: "object",
|
|
@@ -1528,38 +1531,38 @@ const pt = "https://json-schema.org/draft/2020-12/schema", lt = "https://farris-
|
|
|
1528
1531
|
description: "",
|
|
1529
1532
|
type: "object"
|
|
1530
1533
|
}
|
|
1531
|
-
},
|
|
1532
|
-
$schema:
|
|
1533
|
-
$id:
|
|
1534
|
-
title:
|
|
1535
|
-
description:
|
|
1536
|
-
type:
|
|
1537
|
-
properties:
|
|
1538
|
-
},
|
|
1539
|
-
function
|
|
1540
|
-
function n(
|
|
1534
|
+
}, Ct = {
|
|
1535
|
+
$schema: yt,
|
|
1536
|
+
$id: ht,
|
|
1537
|
+
title: bt,
|
|
1538
|
+
description: mt,
|
|
1539
|
+
type: vt,
|
|
1540
|
+
properties: gt
|
|
1541
|
+
}, z = /* @__PURE__ */ new Map();
|
|
1542
|
+
function jt() {
|
|
1543
|
+
function n(p, c, u, m) {
|
|
1541
1544
|
var A;
|
|
1542
|
-
if (typeof
|
|
1543
|
-
return ((A =
|
|
1544
|
-
if (typeof
|
|
1545
|
-
const C = Object.keys(
|
|
1545
|
+
if (typeof u == "number")
|
|
1546
|
+
return ((A = m[p]) == null ? void 0 : A.length) === u;
|
|
1547
|
+
if (typeof u == "object") {
|
|
1548
|
+
const C = Object.keys(u)[0], j = u[C];
|
|
1546
1549
|
if (C === "not")
|
|
1547
|
-
return Number(
|
|
1550
|
+
return Number(m[p].length) !== Number(j);
|
|
1548
1551
|
if (C === "moreThan")
|
|
1549
|
-
return Number(
|
|
1552
|
+
return Number(m[p].length) >= Number(j);
|
|
1550
1553
|
if (C === "lessThan")
|
|
1551
|
-
return Number(
|
|
1554
|
+
return Number(m[p].length) <= Number(j);
|
|
1552
1555
|
}
|
|
1553
1556
|
return !1;
|
|
1554
1557
|
}
|
|
1555
|
-
function t(
|
|
1556
|
-
return typeof
|
|
1558
|
+
function t(p, c, u, m) {
|
|
1559
|
+
return typeof u == "boolean" ? m.childrenClassList.includes(c) === !!u : !1;
|
|
1557
1560
|
}
|
|
1558
|
-
function e(
|
|
1559
|
-
return typeof
|
|
1561
|
+
function e(p, c, u, m) {
|
|
1562
|
+
return typeof u == "boolean" ? m.parentClassList.includes(c) === !!u : !1;
|
|
1560
1563
|
}
|
|
1561
|
-
function r(
|
|
1562
|
-
return typeof
|
|
1564
|
+
function r(p, c, u, m) {
|
|
1565
|
+
return typeof u == "boolean" ? m.parentClassList.includes(c) === !!u : !1;
|
|
1563
1566
|
}
|
|
1564
1567
|
const o = /* @__PURE__ */ new Map([
|
|
1565
1568
|
["length", n],
|
|
@@ -1567,201 +1570,281 @@ function ht() {
|
|
|
1567
1570
|
["hasSibling", r],
|
|
1568
1571
|
["hasParent", e]
|
|
1569
1572
|
]);
|
|
1570
|
-
function
|
|
1571
|
-
const
|
|
1572
|
-
return typeof c == "number" ? [{ target:
|
|
1573
|
-
if (
|
|
1574
|
-
return { target:
|
|
1575
|
-
const A =
|
|
1576
|
-
return { target:
|
|
1573
|
+
function s(p, c) {
|
|
1574
|
+
const u = p;
|
|
1575
|
+
return typeof c == "number" ? [{ target: u, operator: "length", param: null, value: Number(c) }] : typeof c == "object" ? Object.keys(c).map((m) => {
|
|
1576
|
+
if (m === "length")
|
|
1577
|
+
return { target: u, operator: "length", param: null, value: c[m] };
|
|
1578
|
+
const A = m, C = c[m];
|
|
1579
|
+
return { target: u, operator: p === "children" ? "hasChildren" : p === "parent" ? "hasParent" : "hasSibling", param: A, value: C };
|
|
1577
1580
|
}) : [];
|
|
1578
1581
|
}
|
|
1579
|
-
function
|
|
1580
|
-
if (o.has(
|
|
1581
|
-
const
|
|
1582
|
-
return
|
|
1582
|
+
function f(p, c) {
|
|
1583
|
+
if (o.has(p.operator)) {
|
|
1584
|
+
const u = o.get(p.operator);
|
|
1585
|
+
return u && u(p.target, p.param, p.value, c) || !1;
|
|
1583
1586
|
}
|
|
1584
1587
|
return !1;
|
|
1585
1588
|
}
|
|
1586
|
-
function d(
|
|
1587
|
-
return Object.keys(
|
|
1588
|
-
const M =
|
|
1589
|
+
function d(p, c) {
|
|
1590
|
+
return Object.keys(p).reduce((C, j) => {
|
|
1591
|
+
const M = s(j, p[j]);
|
|
1589
1592
|
return C.push(...M), C;
|
|
1590
|
-
}, []).reduce((C,
|
|
1593
|
+
}, []).reduce((C, j) => C && f(j, c), !0);
|
|
1591
1594
|
}
|
|
1592
|
-
function
|
|
1593
|
-
const
|
|
1594
|
-
return
|
|
1595
|
+
function y(p, c) {
|
|
1596
|
+
const u = Object.keys(p), m = u.includes("allOf"), A = u.includes("anyOf"), C = m || A, b = (C ? p[C ? m ? "allOf" : "anyOf" : "allOf"] : [p]).map((E) => d(E, c));
|
|
1597
|
+
return m ? !b.includes(!1) : b.includes(!0);
|
|
1595
1598
|
}
|
|
1596
|
-
function
|
|
1597
|
-
const
|
|
1598
|
-
return
|
|
1599
|
+
function a(p, c) {
|
|
1600
|
+
const u = p.const;
|
|
1601
|
+
return u ? typeof u == "boolean" ? u : typeof u == "object" ? y(u, c) : !1 : !1;
|
|
1599
1602
|
}
|
|
1600
|
-
function p
|
|
1603
|
+
function l(p) {
|
|
1601
1604
|
return (c) => {
|
|
1602
|
-
const
|
|
1603
|
-
return
|
|
1604
|
-
const C =
|
|
1605
|
-
return
|
|
1606
|
-
},
|
|
1605
|
+
const u = { canAccept: !0, fixed: !1, hidePadding: !1 };
|
|
1606
|
+
return p && p.properties && Object.keys(p.properties).reduce((m, A) => {
|
|
1607
|
+
const C = p.properties[A];
|
|
1608
|
+
return m[A] = a(C, c), m;
|
|
1609
|
+
}, u), u;
|
|
1607
1610
|
};
|
|
1608
1611
|
}
|
|
1609
|
-
function
|
|
1612
|
+
function i(p, c, u) {
|
|
1610
1613
|
if (c.type === "object" && c.properties) {
|
|
1611
|
-
const { rules:
|
|
1612
|
-
|
|
1613
|
-
(C) =>
|
|
1614
|
+
const { rules: m, contents: A } = c.properties;
|
|
1615
|
+
u.set(p, l(m)), A && Object.keys(A.properties).forEach(
|
|
1616
|
+
(C) => i(C, A.properties[C], u)
|
|
1614
1617
|
);
|
|
1615
1618
|
}
|
|
1616
1619
|
}
|
|
1617
|
-
function
|
|
1618
|
-
const { properties:
|
|
1619
|
-
Object.keys(
|
|
1620
|
-
|
|
1620
|
+
function h() {
|
|
1621
|
+
const { properties: p } = Ct;
|
|
1622
|
+
Object.keys(p).forEach((c) => {
|
|
1623
|
+
i(c, p[c], z);
|
|
1621
1624
|
});
|
|
1622
1625
|
}
|
|
1623
|
-
function
|
|
1624
|
-
const
|
|
1625
|
-
return
|
|
1626
|
+
function g(p, c) {
|
|
1627
|
+
const u = { canAccept: !0, fixed: !1, hidePadding: !0 };
|
|
1628
|
+
return z.has(p) ? z.get(p)(c) : u;
|
|
1626
1629
|
}
|
|
1627
|
-
return
|
|
1630
|
+
return h(), { getRuleValue: g };
|
|
1628
1631
|
}
|
|
1629
|
-
function
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
return u && u.componentClassList && u.componentClassList.includes("f-form-layout") && u.componentClassList.includes("farris-form") ? y.sourceType === "control" && y.controlCategory === "input" || y.sourceType === "move" && y.controlType === "form-group" : !0;
|
|
1632
|
+
function Pt(n, t) {
|
|
1633
|
+
function e(y, a = null) {
|
|
1634
|
+
if (a) return a;
|
|
1635
|
+
const l = n.getComponentById(t);
|
|
1636
|
+
return n.selectNode(l, (i) => i.id === y);
|
|
1635
1637
|
}
|
|
1636
|
-
function
|
|
1637
|
-
|
|
1638
|
+
function r(y) {
|
|
1639
|
+
const a = n.getComponentById(y);
|
|
1640
|
+
return !(!a || !a.componentType || !a.componentType.startsWith("form"));
|
|
1638
1641
|
}
|
|
1639
|
-
function
|
|
1640
|
-
a
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1642
|
+
function o(y) {
|
|
1643
|
+
const a = e(y.id), l = De(n), i = [];
|
|
1644
|
+
l.getResonseFormLayoutConfig(a, i, 1);
|
|
1645
|
+
const h = i.map((j) => j.columnInSM), g = i.map((j) => j.columnInMD), p = i.map((j) => j.columnInLG), c = i.map((j) => j.columnInEL), u = s(h) ? h[0] : 0, m = s(g) ? g[0] : 0, A = s(p) ? p[0] : 0, C = s(c) ? c[0] : 0;
|
|
1646
|
+
return {
|
|
1647
|
+
uniqueColClassInSM: u,
|
|
1648
|
+
uniqueColClassInMD: m,
|
|
1649
|
+
uniqueColClassInLG: A,
|
|
1650
|
+
uniqueColClassInEL: C
|
|
1651
|
+
};
|
|
1652
|
+
}
|
|
1653
|
+
function s(y) {
|
|
1654
|
+
const a = new Set(y);
|
|
1655
|
+
return Array.from(a).length === 1;
|
|
1656
|
+
}
|
|
1657
|
+
function f(y, a, l) {
|
|
1658
|
+
y = e(l, y), y.contents.forEach((i) => {
|
|
1659
|
+
if (i.type === we.fieldset.type) {
|
|
1660
|
+
f(i, a, i.id);
|
|
1661
|
+
return;
|
|
1662
|
+
}
|
|
1663
|
+
i.appearance || (i.appearance = {});
|
|
1664
|
+
const h = i.appearance.class;
|
|
1665
|
+
i.appearance.class = d(h, a);
|
|
1666
|
+
});
|
|
1667
|
+
}
|
|
1668
|
+
function d(y, a) {
|
|
1669
|
+
let l, i, h, g, p = [];
|
|
1670
|
+
if (y) {
|
|
1671
|
+
const j = y.split(" "), M = j.filter((b) => b.startsWith("col-"));
|
|
1672
|
+
l = M.find((b) => /^col-([1-9]|10|11|12)$/.test(b)), i = M.find((b) => /^col-md-([1-9]|10|11|12)$/.test(b)), h = M.find((b) => /^col-xl-([1-9]|10|11|12)$/.test(b)), g = M.find((b) => /^col-el-([1-9]|10|11|12)$/.test(b)), p = j.filter((b) => !b.startsWith("col-"));
|
|
1673
|
+
}
|
|
1674
|
+
const c = a.uniqueColClassInSM ? "col-" + a.uniqueColClassInSM : l, u = a.uniqueColClassInMD ? "col-md-" + a.uniqueColClassInMD : i, m = a.uniqueColClassInLG ? "col-xl-" + a.uniqueColClassInLG : h, A = a.uniqueColClassInEL ? "col-el-" + a.uniqueColClassInEL : g;
|
|
1675
|
+
return [c, u, m, A].concat(p).join(" ");
|
|
1676
|
+
}
|
|
1677
|
+
return { checkIsInFormComponent: r, assembleUnifiedLayoutContext: o, changeFormControlsByUnifiedLayoutConfig: f };
|
|
1678
|
+
}
|
|
1679
|
+
class At extends Se {
|
|
1680
|
+
constructor(t, e) {
|
|
1681
|
+
super(t, e);
|
|
1682
|
+
}
|
|
1683
|
+
getPropertyConfig(t, e) {
|
|
1684
|
+
var r = this;
|
|
1685
|
+
this.propertyConfig.categories.basic = this.getBasicPropConfig(t);
|
|
1686
|
+
const { checkIsInFormComponent: o, assembleUnifiedLayoutContext: s, changeFormControlsByUnifiedLayoutConfig: f } = Pt(this.formSchemaUtils, this.componentId), d = this.getAppearanceConfig(t);
|
|
1687
|
+
return d.properties.unifiedLayout = {
|
|
1688
|
+
title: "统一布局配置",
|
|
1689
|
+
description: "统一配置卡片区域内所有控件的宽度,只支持标准模式",
|
|
1690
|
+
visible: o(this.componentId),
|
|
1691
|
+
refreshPanelAfterChanged: !0,
|
|
1692
|
+
editor: {
|
|
1693
|
+
type: "response-form-layout-setting",
|
|
1694
|
+
initialState: s(t)
|
|
1695
|
+
}
|
|
1696
|
+
}, d.setPropertyRelates = function(y, a) {
|
|
1697
|
+
if (y)
|
|
1698
|
+
switch (y && y.propertyID) {
|
|
1699
|
+
case "unifiedLayout": {
|
|
1700
|
+
f(null, y.propertyValue, t.id), r.updateElementByParentContainer(t.id, e);
|
|
1701
|
+
break;
|
|
1702
|
+
}
|
|
1703
|
+
}
|
|
1704
|
+
}, this.propertyConfig.categories.appearance = d, this.propertyConfig;
|
|
1705
|
+
}
|
|
1706
|
+
}
|
|
1707
|
+
function Tt(n, t) {
|
|
1708
|
+
var E;
|
|
1709
|
+
const e = n.schema, r = (E = n.parent) == null ? void 0 : E.schema, o = jt(), s = w(!1), f = w(!1);
|
|
1710
|
+
let d = !0, y = !1, a, l = !1;
|
|
1711
|
+
function i(v) {
|
|
1712
|
+
return a && a.componentClassList && a.componentClassList.includes("f-form-layout") && a.componentClassList.includes("farris-form") ? v.sourceType === "control" && v.controlCategory === "input" || v.sourceType === "move" && v.controlType === "form-group" : !0;
|
|
1713
|
+
}
|
|
1714
|
+
function h(v) {
|
|
1715
|
+
return !(!dt().basalDragulaRuleForContainer(v) || !d || !i(v));
|
|
1716
|
+
}
|
|
1717
|
+
function g() {
|
|
1718
|
+
s.value = !1, f.value = !1;
|
|
1719
|
+
const v = e, P = v.appearance && v.appearance.class || "", T = P.split(" "), S = v.contents || [], L = S.length ? S[0] : null, F = L && L.appearance ? L.appearance.class : "", k = F ? F.split(" ") : [], B = S.length ? S.reduce((K, V) => {
|
|
1720
|
+
const ee = V && V.appearance ? V.appearance.class : "", Ce = ee ? ee.split(" ") : [];
|
|
1721
|
+
return K.push(...Ce), K;
|
|
1722
|
+
}, []) : [], x = r, q = x && x.appearance && x.appearance.class || "", be = q ? q.split(" ") : [];
|
|
1723
|
+
a = {
|
|
1724
|
+
componentClass: P,
|
|
1725
|
+
componentClassList: T,
|
|
1726
|
+
childContents: S,
|
|
1727
|
+
firstChildContent: L,
|
|
1728
|
+
firstChildClass: F,
|
|
1729
|
+
firstChildClassList: k,
|
|
1652
1730
|
parent: x,
|
|
1653
|
-
parentClass:
|
|
1654
|
-
parentClassList:
|
|
1655
|
-
children:
|
|
1656
|
-
childrenClassList:
|
|
1731
|
+
parentClass: q,
|
|
1732
|
+
parentClassList: be,
|
|
1733
|
+
children: S,
|
|
1734
|
+
childrenClassList: B
|
|
1657
1735
|
};
|
|
1658
|
-
const { canAccept:
|
|
1659
|
-
return d =
|
|
1736
|
+
const { canAccept: me, fixed: ve, hidePadding: ge } = o.getRuleValue(T[0], a);
|
|
1737
|
+
return d = me, y = ge, l = ve, !0;
|
|
1660
1738
|
}
|
|
1661
|
-
function
|
|
1662
|
-
|
|
1739
|
+
function p(v) {
|
|
1740
|
+
Pe();
|
|
1663
1741
|
}
|
|
1664
1742
|
function c() {
|
|
1665
1743
|
return e.componentType ? "display:inherit;flex-direction:inherit;margin-bottom:10px" : "";
|
|
1666
1744
|
}
|
|
1667
|
-
function
|
|
1668
|
-
const
|
|
1669
|
-
if ((
|
|
1670
|
-
const { label:
|
|
1671
|
-
return
|
|
1745
|
+
function u(v, P) {
|
|
1746
|
+
const T = e;
|
|
1747
|
+
if ((T.appearance && T.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1748
|
+
const { label: F } = v, k = $("form-group");
|
|
1749
|
+
return k.editor = P, k.label = F, m(k), delete k.editor.id, delete k.editor.binding, delete k.editor.appearance, delete k.editor.visible, k;
|
|
1672
1750
|
}
|
|
1673
|
-
return
|
|
1751
|
+
return P;
|
|
1674
1752
|
}
|
|
1675
|
-
function
|
|
1676
|
-
const
|
|
1677
|
-
if (
|
|
1678
|
-
const
|
|
1679
|
-
|
|
1753
|
+
function m(v) {
|
|
1754
|
+
const P = n.componentInstance.value.getBelongedComponentInstance(n.componentInstance);
|
|
1755
|
+
if (P && P.schema && P.schema.componentType) {
|
|
1756
|
+
const T = P.schema.formColumns;
|
|
1757
|
+
let S = A(T);
|
|
1758
|
+
S = t.formSchemaUtils.getControlClassByFormUnifiedLayout(S, "", n.schema), v.appearance || (v.appearance = {}), v.appearance.class = S;
|
|
1680
1759
|
}
|
|
1681
1760
|
}
|
|
1682
|
-
function A(
|
|
1683
|
-
let
|
|
1684
|
-
switch (
|
|
1761
|
+
function A(v) {
|
|
1762
|
+
let P = "";
|
|
1763
|
+
switch (v) {
|
|
1685
1764
|
case 1: {
|
|
1686
|
-
|
|
1765
|
+
P = "col-12 col-md-12 col-xl-12 col-el-12";
|
|
1687
1766
|
break;
|
|
1688
1767
|
}
|
|
1689
1768
|
case 2: {
|
|
1690
|
-
|
|
1769
|
+
P = "col-12 col-md-6 col-xl-6 col-el-6";
|
|
1691
1770
|
break;
|
|
1692
1771
|
}
|
|
1693
1772
|
case 3: {
|
|
1694
|
-
|
|
1773
|
+
P = "col-12 col-md-6 col-xl-4 col-el-4";
|
|
1695
1774
|
break;
|
|
1696
1775
|
}
|
|
1697
1776
|
case 4: {
|
|
1698
|
-
|
|
1777
|
+
P = "col-12 col-md-6 col-xl-3 col-el-2";
|
|
1699
1778
|
break;
|
|
1700
1779
|
}
|
|
1701
1780
|
}
|
|
1702
|
-
return
|
|
1781
|
+
return P;
|
|
1703
1782
|
}
|
|
1704
|
-
function C(
|
|
1705
|
-
const
|
|
1706
|
-
if ((
|
|
1707
|
-
const
|
|
1708
|
-
return
|
|
1783
|
+
function C(v, P, T) {
|
|
1784
|
+
const S = e;
|
|
1785
|
+
if ((S.appearance && S.appearance.class || "").split(" ").includes("f-form-layout")) {
|
|
1786
|
+
const k = String(v.innerText), B = $("form-group");
|
|
1787
|
+
return B.editor = T, B.label = k, B;
|
|
1709
1788
|
}
|
|
1710
|
-
return
|
|
1789
|
+
return T;
|
|
1711
1790
|
}
|
|
1712
|
-
function
|
|
1713
|
-
return !
|
|
1791
|
+
function j() {
|
|
1792
|
+
return !l;
|
|
1714
1793
|
}
|
|
1715
1794
|
function M() {
|
|
1716
|
-
return !
|
|
1795
|
+
return !l;
|
|
1717
1796
|
}
|
|
1718
|
-
function
|
|
1719
|
-
return
|
|
1797
|
+
function b() {
|
|
1798
|
+
return y;
|
|
1799
|
+
}
|
|
1800
|
+
function D(v) {
|
|
1801
|
+
return new At(v, t).getPropertyConfig(e, n.componentInstance.value);
|
|
1720
1802
|
}
|
|
1721
1803
|
return {
|
|
1722
|
-
canAccepts:
|
|
1804
|
+
canAccepts: h,
|
|
1723
1805
|
checkCanDeleteComponent: M,
|
|
1724
|
-
checkCanMoveComponent:
|
|
1806
|
+
checkCanMoveComponent: j,
|
|
1725
1807
|
getStyles: c,
|
|
1726
|
-
|
|
1808
|
+
getPropsConfig: D,
|
|
1809
|
+
hideNestedPaddingInDesginerView: b,
|
|
1727
1810
|
onAcceptNewChildElement: C,
|
|
1728
|
-
onAcceptMovedChildElement:
|
|
1729
|
-
resolveComponentContext:
|
|
1730
|
-
onResolveNewComponentSchema:
|
|
1731
|
-
triggerBelongedComponentToMoveWhenMoved:
|
|
1732
|
-
triggerBelongedComponentToDeleteWhenDeleted:
|
|
1811
|
+
onAcceptMovedChildElement: p,
|
|
1812
|
+
resolveComponentContext: g,
|
|
1813
|
+
onResolveNewComponentSchema: u,
|
|
1814
|
+
triggerBelongedComponentToMoveWhenMoved: s,
|
|
1815
|
+
triggerBelongedComponentToDeleteWhenDeleted: f
|
|
1733
1816
|
};
|
|
1734
1817
|
}
|
|
1735
|
-
const
|
|
1818
|
+
const Et = /* @__PURE__ */ ce({
|
|
1736
1819
|
name: "FNavDesign",
|
|
1737
1820
|
props: R,
|
|
1738
1821
|
emits: ["nav"],
|
|
1739
1822
|
setup(n, t) {
|
|
1740
|
-
var
|
|
1741
|
-
const e =
|
|
1742
|
-
|
|
1743
|
-
const
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
}), t.expose(
|
|
1747
|
-
const
|
|
1823
|
+
var p;
|
|
1824
|
+
const e = w(n.activeNavId), r = w(n.navData), o = w(n.horizontal);
|
|
1825
|
+
w(n.navPicking);
|
|
1826
|
+
const s = w(), f = Ae("design-item-context"), d = Tt(f.schema, (p = f.parent) == null ? void 0 : p.schema), y = ft(s, f, d);
|
|
1827
|
+
Te(() => {
|
|
1828
|
+
s.value.componentInstance = y;
|
|
1829
|
+
}), t.expose(y.value);
|
|
1830
|
+
const a = _({
|
|
1748
1831
|
get() {
|
|
1749
1832
|
return r.value;
|
|
1750
1833
|
},
|
|
1751
1834
|
set(c) {
|
|
1752
|
-
r.value = c,
|
|
1835
|
+
r.value = c, h();
|
|
1753
1836
|
}
|
|
1754
|
-
}),
|
|
1837
|
+
}), l = _({
|
|
1755
1838
|
get() {
|
|
1756
1839
|
return e.value;
|
|
1757
1840
|
},
|
|
1758
1841
|
set(c) {
|
|
1759
|
-
if (e.value = c, e.value &&
|
|
1760
|
-
const
|
|
1761
|
-
|
|
1842
|
+
if (e.value = c, e.value && a && a.value.length) {
|
|
1843
|
+
const u = a.value.find((m) => m.id === e.value);
|
|
1844
|
+
u && t.emit("nav", u);
|
|
1762
1845
|
}
|
|
1763
1846
|
}
|
|
1764
|
-
}),
|
|
1847
|
+
}), i = _({
|
|
1765
1848
|
set(c) {
|
|
1766
1849
|
o.value = c;
|
|
1767
1850
|
},
|
|
@@ -1769,56 +1852,56 @@ const vt = /* @__PURE__ */ ce({
|
|
|
1769
1852
|
return o.value;
|
|
1770
1853
|
}
|
|
1771
1854
|
});
|
|
1772
|
-
function
|
|
1773
|
-
if (
|
|
1774
|
-
const c =
|
|
1855
|
+
function h() {
|
|
1856
|
+
if (a.value && a.value.length && !e.value) {
|
|
1857
|
+
const c = a.value.find((u) => !u.disable);
|
|
1775
1858
|
c && (e.value = c.id);
|
|
1776
1859
|
}
|
|
1777
1860
|
}
|
|
1778
|
-
function
|
|
1861
|
+
function g(c) {
|
|
1779
1862
|
c.disable || c.id === e.value || (e.value = c.id, t.emit("nav", c));
|
|
1780
1863
|
}
|
|
1781
1864
|
return () => {
|
|
1782
1865
|
var c;
|
|
1783
|
-
return
|
|
1784
|
-
ref:
|
|
1866
|
+
return N("div", {
|
|
1867
|
+
ref: s,
|
|
1785
1868
|
class: ["farris-nav", {
|
|
1786
|
-
"farris-nav-vertical": !
|
|
1869
|
+
"farris-nav-vertical": !i.value
|
|
1787
1870
|
}]
|
|
1788
|
-
}, [(c =
|
|
1871
|
+
}, [(c = a.value) == null ? void 0 : c.map((u) => N("div", {
|
|
1789
1872
|
class: ["farris-nav-item", {
|
|
1790
|
-
active:
|
|
1873
|
+
active: u.id === l.value
|
|
1791
1874
|
}, {
|
|
1792
|
-
disabled:
|
|
1875
|
+
disabled: u.disable
|
|
1793
1876
|
}],
|
|
1794
|
-
onClick: () =>
|
|
1795
|
-
}, [
|
|
1877
|
+
onClick: () => g(u)
|
|
1878
|
+
}, [N("div", {
|
|
1796
1879
|
class: "farris-nav-item-link"
|
|
1797
|
-
}, [
|
|
1880
|
+
}, [N("span", {
|
|
1798
1881
|
class: "farris-nav-item-link-text"
|
|
1799
|
-
}, [
|
|
1882
|
+
}, [u.text, u.num && N("div", {
|
|
1800
1883
|
class: "farris-nav-item-tag"
|
|
1801
|
-
}, [
|
|
1884
|
+
}, [u.num <= n.maxNum && N("span", {
|
|
1802
1885
|
class: "tag-text"
|
|
1803
|
-
}, [
|
|
1886
|
+
}, [u.num]), u.num > n.maxNum && N("span", {
|
|
1804
1887
|
class: "tag-text"
|
|
1805
|
-
}, [n.maxNum,
|
|
1888
|
+
}, [n.maxNum, le("+")])])])])]))]);
|
|
1806
1889
|
};
|
|
1807
1890
|
}
|
|
1808
|
-
}),
|
|
1891
|
+
}), kt = {
|
|
1809
1892
|
install(n) {
|
|
1810
|
-
n.component(
|
|
1893
|
+
n.component(G.name, G);
|
|
1811
1894
|
},
|
|
1812
1895
|
register(n, t, e, r) {
|
|
1813
|
-
n.nav =
|
|
1896
|
+
n.nav = G, t.nav = ie;
|
|
1814
1897
|
},
|
|
1815
1898
|
registerDesigner(n, t, e) {
|
|
1816
|
-
n.nav =
|
|
1899
|
+
n.nav = Et, t.nav = ie;
|
|
1817
1900
|
}
|
|
1818
1901
|
};
|
|
1819
1902
|
export {
|
|
1820
|
-
|
|
1821
|
-
|
|
1903
|
+
G as FNav,
|
|
1904
|
+
kt as default,
|
|
1822
1905
|
R as navProps,
|
|
1823
|
-
|
|
1906
|
+
ie as propsResolver
|
|
1824
1907
|
};
|