@farris/ui-vue 1.3.0 → 1.3.1
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 +1 -1
- package/components/accordion/index.umd.cjs +1 -1
- package/components/avatar/index.esm.js +472 -366
- package/components/avatar/index.umd.cjs +1 -1
- package/components/button-edit/index.esm.js +1 -1
- package/components/button-edit/index.umd.cjs +1 -1
- package/components/calendar/index.esm.js +472 -480
- package/components/calendar/index.umd.cjs +1 -1
- package/components/capsule/index.esm.js +225 -233
- package/components/capsule/index.umd.cjs +1 -1
- package/components/checkbox/index.esm.js +615 -517
- package/components/checkbox/index.umd.cjs +1 -1
- package/components/color-picker/index.esm.js +325 -333
- package/components/color-picker/index.umd.cjs +2 -2
- package/components/combo-list/index.esm.js +578 -472
- package/components/combo-list/index.umd.cjs +1 -1
- package/components/combo-tree/index.esm.js +49 -49
- package/components/combo-tree/index.umd.cjs +1 -1
- package/components/common/index.esm.js +832 -722
- package/components/common/index.umd.cjs +1 -1
- package/components/component/index.esm.js +303 -981
- package/components/component/index.umd.cjs +1 -1
- package/components/condition/index.esm.js +8 -8
- package/components/condition/index.umd.cjs +1 -1
- package/components/content-container/index.esm.js +335 -1002
- package/components/content-container/index.umd.cjs +1 -1
- package/components/data-grid/index.esm.js +4429 -4312
- package/components/data-grid/index.umd.cjs +1 -1
- package/components/data-view/index.esm.js +3037 -3020
- package/components/data-view/index.umd.cjs +1 -1
- package/components/date-picker/index.esm.js +2216 -2119
- package/components/date-picker/index.umd.cjs +1 -1
- package/components/designer-canvas/index.css +1 -1
- package/components/designer-canvas/index.esm.js +914 -883
- package/components/designer-canvas/index.umd.cjs +1 -1
- package/components/dropdown/index.esm.js +223 -231
- package/components/dropdown/index.umd.cjs +2 -2
- package/components/dynamic-form/index.esm.js +1691 -2187
- package/components/dynamic-form/index.umd.cjs +1 -1
- package/components/dynamic-resolver/index.esm.js +143 -136
- package/components/dynamic-resolver/index.umd.cjs +1 -1
- package/components/events-editor/index.esm.js +250 -258
- package/components/events-editor/index.umd.cjs +1 -1
- package/components/expression-editor/index.esm.js +1 -1
- package/components/expression-editor/index.umd.cjs +1 -1
- package/components/external-container/index.esm.js +2672 -3438
- package/components/external-container/index.umd.cjs +1 -1
- package/components/field-selector/index.esm.js +2965 -2970
- package/components/field-selector/index.umd.cjs +1 -1
- package/components/filter-bar/index.esm.js +1650 -1602
- package/components/filter-bar/index.umd.cjs +1 -1
- package/components/flow-canvas/index.css +1 -1
- package/components/flow-canvas/index.esm.js +684 -675
- package/components/flow-canvas/index.umd.cjs +1 -1
- package/components/image-cropper/index.esm.js +453 -461
- package/components/image-cropper/index.umd.cjs +1 -1
- package/components/input-group/index.esm.js +604 -507
- package/components/input-group/index.umd.cjs +1 -1
- package/components/layout/index.esm.js +402 -378
- package/components/layout/index.umd.cjs +1 -1
- package/components/list-nav/index.esm.js +348 -1019
- package/components/list-nav/index.umd.cjs +1 -1
- package/components/list-view/index.esm.js +1658 -1666
- package/components/list-view/index.umd.cjs +1 -1
- package/components/lookup/index.esm.js +5209 -5088
- package/components/lookup/index.umd.cjs +1 -1
- package/components/mapping-editor/index.esm.js +4329 -4213
- package/components/mapping-editor/index.umd.cjs +1 -1
- package/components/nav/index.esm.js +905 -1357
- package/components/nav/index.umd.cjs +3 -3
- package/components/number-range/index.esm.js +517 -420
- package/components/number-range/index.umd.cjs +1 -1
- package/components/number-spinner/index.esm.js +588 -491
- package/components/number-spinner/index.umd.cjs +1 -1
- package/components/order/index.esm.js +1376 -1965
- package/components/order/index.umd.cjs +1 -1
- package/components/page-footer/index.esm.js +1 -1
- package/components/page-footer/index.umd.cjs +1 -1
- package/components/page-header/index.esm.js +1073 -1905
- package/components/page-header/index.umd.cjs +1 -1
- package/components/pagination/index.esm.js +809 -1237
- package/components/pagination/index.umd.cjs +1 -1
- package/components/progress/index.esm.js +198 -206
- package/components/progress/index.umd.cjs +3 -3
- package/components/property-editor/index.esm.js +1297 -1200
- package/components/property-editor/index.umd.cjs +2 -2
- package/components/property-panel/index.esm.js +609 -507
- package/components/property-panel/index.umd.cjs +1 -1
- package/components/query-solution/index.esm.js +3391 -3758
- package/components/query-solution/index.umd.cjs +1 -1
- package/components/radio-button/index.esm.js +1 -1
- package/components/radio-button/index.umd.cjs +1 -1
- package/components/radio-group/index.esm.js +544 -447
- package/components/radio-group/index.umd.cjs +1 -1
- package/components/rate/index.esm.js +247 -255
- package/components/rate/index.umd.cjs +1 -1
- package/components/response-layout/index.esm.js +146 -154
- package/components/response-layout/index.umd.cjs +1 -1
- package/components/response-layout-editor/index.esm.js +700 -675
- package/components/response-layout-editor/index.umd.cjs +1 -1
- package/components/response-toolbar/index.esm.js +956 -1786
- package/components/response-toolbar/index.umd.cjs +1 -1
- package/components/schema-selector/index.esm.js +4963 -5617
- package/components/schema-selector/index.umd.cjs +2 -2
- package/components/search-box/index.esm.js +158 -161
- package/components/search-box/index.umd.cjs +1 -1
- package/components/section/index.esm.js +436 -1124
- package/components/section/index.umd.cjs +1 -1
- package/components/smoke-detector/index.esm.js +92 -100
- package/components/smoke-detector/index.umd.cjs +1 -1
- package/components/splitter/index.esm.js +571 -1210
- package/components/splitter/index.umd.cjs +1 -1
- package/components/splitter/style.js +2 -0
- package/components/step/index.esm.js +239 -247
- package/components/step/index.umd.cjs +1 -1
- package/components/switch/index.esm.js +445 -348
- package/components/switch/index.umd.cjs +1 -1
- package/components/tabs/index.esm.js +2278 -3031
- package/components/tabs/index.umd.cjs +1 -1
- package/components/tags/index.esm.js +311 -319
- package/components/tags/index.umd.cjs +1 -1
- package/components/text/index.esm.js +215 -223
- package/components/text/index.umd.cjs +1 -1
- package/components/textarea/index.esm.js +468 -371
- package/components/textarea/index.umd.cjs +1 -1
- package/components/time-picker/index.esm.js +1271 -1174
- package/components/time-picker/index.umd.cjs +1 -1
- package/components/transfer/index.esm.js +469 -477
- package/components/transfer/index.umd.cjs +1 -1
- package/components/tree-grid/index.esm.js +3060 -3065
- package/components/tree-grid/index.umd.cjs +1 -1
- package/components/tree-view/index.esm.js +2476 -2481
- package/components/tree-view/index.umd.cjs +1 -1
- package/components/uploader/index.esm.js +374 -382
- package/components/uploader/index.umd.cjs +2 -2
- package/components/verify-detail/index.esm.js +248 -256
- package/components/verify-detail/index.umd.cjs +1 -1
- package/components/video/index.esm.js +414 -1093
- package/components/video/index.umd.cjs +1 -1
- package/components/weather/index.esm.js +498 -506
- package/components/weather/index.umd.cjs +5 -5
- package/farris.all.esm.js +20216 -21844
- package/farris.all.umd.cjs +9 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/common/directive/area-response.d.ts +10 -0
- package/types/common/index.d.ts +8 -0
- package/types/common/radio-checkbox/radio-checkbox.props.d.ts +1 -0
- package/types/common/utils/resolve-field.d.ts +2 -0
- package/types/common/utils/use-class.d.ts +7 -0
- package/types/component/src/designer/use-designer-rules.d.ts +2 -2
- package/types/condition/src/types.d.ts +2 -1
- package/types/content-container/src/designer/use-designer-rules.d.ts +3 -3
- package/types/data-grid/index.d.ts +8 -5
- package/types/data-grid/src/data-grid.component.d.ts +3 -2
- package/types/data-grid/src/designer/data-grid.design.component.d.ts +2 -2
- package/types/data-grid/src/designer/use-designer-rules.d.ts +2 -2
- package/types/data-view/components/row/hierarchy-row.component.d.ts +2 -2
- package/types/data-view/composition/data/use-tree-data.d.ts +1 -1
- package/types/data-view/composition/types.d.ts +7 -9
- package/types/designer-canvas/index.d.ts +2 -1
- package/types/designer-canvas/src/composition/rule/use-dragula-common-rule.d.ts +4 -0
- package/types/designer-canvas/src/composition/rule/use-template-rule.d.ts +30 -0
- package/types/designer-canvas/src/composition/types.d.ts +1 -2
- package/types/designer-canvas/src/types.d.ts +2 -1
- package/types/dynamic-form/src/designer/response-form.design.component.d.ts +7 -1
- 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 +1 -1
- package/types/dynamic-resolver/src/common/toolbar-resolver.d.ts +1 -1
- package/types/external-container/src/designer/use-designer-rules.d.ts +3 -3
- package/types/layout/src/designer/layout-pane-use-designer-rules.d.ts +3 -3
- package/types/list-nav/src/designer/use-designer-rules.d.ts +3 -0
- package/types/pagination/src/components/buttons/goto-buttons.component.d.ts +2 -2
- package/types/pagination/src/components/buttons/next-buttons.component.d.ts +2 -2
- package/types/pagination/src/components/buttons/previous-buttons.component.d.ts +2 -2
- package/types/pagination/src/components/pages/page-list.component.d.ts +2 -2
- package/types/pagination/src/components/pages/page-number.component.d.ts +2 -2
- package/types/property-panel/index.d.ts +2 -1
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +1 -1
- package/types/query-solution/src/designer/query-solution-config/composition/types.d.ts +34 -27
- package/types/query-solution/src/designer/query-solution-config/composition/use-panel.d.ts +2 -16
- package/types/query-solution/src/designer/query-solution-config/composition/use-property.d.ts +19 -0
- package/types/query-solution/src/designer/query-solution-config/composition/use-querysolution-rules.d.ts +3 -0
- package/types/query-solution/src/designer/query-solution-config/composition/use-transfer.d.ts +1 -1
- package/types/query-solution/src/property-config/query-solution.property-config.d.ts +60 -0
- package/types/query-solution/src/solutions.d.ts +108 -509
- package/types/response-layout-editor/index.d.ts +3 -1
- package/types/response-toolbar/src/designer/use-designer-rules.d.ts +3 -3
- package/types/response-toolbar/src/property-config/response-toolbar-item.property-config.d.ts +1 -0
- package/types/section/src/designer/use-designer-rules.d.ts +3 -3
- package/types/splitter/src/components/splitter-pane.component.d.ts +1 -1
- package/types/splitter/src/designer/splitter-pane-use-designer-rules.d.ts +3 -3
- package/types/splitter/src/designer/splitter-use-designer-rules.d.ts +3 -3
- package/types/tabs/src/designer/tab-page-use-designer-rules.d.ts +3 -3
- package/types/tabs/src/designer/tab-use-designer-rules.d.ts +3 -3
- package/types/tree-grid/index.d.ts +3 -3
- package/types/tree-grid/src/tree-grid.component.d.ts +1 -1
- package/types/designer-canvas/src/composition/rule/use-drag-drop-rules.d.ts +0 -19
- package/types/designer-canvas/src/composition/use-dragula-common-rule.d.ts +0 -4
- package/types/list-nav/src/composition/use-designer-rules.d.ts +0 -3
- package/types/query-solution/src/designer/query-solution-config/composition/mock-data.d.ts +0 -6
|
@@ -1,102 +1,102 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { isPlainObject as
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as V, ref as O, computed as R, watch as G, createVNode as d, inject as H, onMounted as J } from "vue";
|
|
2
|
+
import { isPlainObject as z, cloneDeep as Q } from "lodash-es";
|
|
3
|
+
const q = {}, W = {};
|
|
4
4
|
function B(t) {
|
|
5
|
-
const { properties: e, title:
|
|
6
|
-
return (!
|
|
5
|
+
const { properties: e, title: i, ignore: n } = t, l = n && Array.isArray(n), y = Object.keys(e).reduce((f, j) => ((!l || !n.find((b) => b == j)) && (f[j] = e[j].type === "object" && e[j].properties ? B(e[j]) : Q(e[j].default)), f), {});
|
|
6
|
+
return i && (!l || !n.find((f) => f == "id")) && (y.id = `${i}-${Date.now()}`), y;
|
|
7
7
|
}
|
|
8
|
-
function
|
|
9
|
-
const
|
|
10
|
-
if (
|
|
11
|
-
let
|
|
12
|
-
const y =
|
|
13
|
-
return
|
|
8
|
+
function _(t, e = {}, i) {
|
|
9
|
+
const n = q[t];
|
|
10
|
+
if (n) {
|
|
11
|
+
let l = B(n);
|
|
12
|
+
const y = W[t];
|
|
13
|
+
return l = y ? y({ getSchemaByType: _ }, l, e, i) : l, l;
|
|
14
14
|
}
|
|
15
15
|
return null;
|
|
16
16
|
}
|
|
17
|
-
function Q(t, e) {
|
|
18
|
-
const o = B(e);
|
|
19
|
-
return Object.keys(t).reduce((l, i) => (l[i] && F(l[i]) && F(t[i]) ? Object.assign(l[i], t[i]) : l[i] = t[i], l), o), o;
|
|
20
|
-
}
|
|
21
17
|
function U(t, e) {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
18
|
+
const i = B(e);
|
|
19
|
+
return Object.keys(t).reduce((n, l) => (n[l] && z(n[l]) && z(t[l]) ? Object.assign(n[l], t[l]) : n[l] = t[l], n), i), i;
|
|
20
|
+
}
|
|
21
|
+
function X(t, e) {
|
|
22
|
+
return Object.keys(t).filter((n) => t[n] != null).reduce((n, l) => {
|
|
23
|
+
if (e.has(l)) {
|
|
24
|
+
const y = e.get(l);
|
|
25
25
|
if (typeof y == "string")
|
|
26
|
-
|
|
26
|
+
n[y] = t[l];
|
|
27
27
|
else {
|
|
28
|
-
const f = y(
|
|
29
|
-
Object.assign(
|
|
28
|
+
const f = y(l, t[l], t);
|
|
29
|
+
Object.assign(n, f);
|
|
30
30
|
}
|
|
31
31
|
} else
|
|
32
|
-
l
|
|
33
|
-
return
|
|
32
|
+
n[l] = t[l];
|
|
33
|
+
return n;
|
|
34
34
|
}, {});
|
|
35
35
|
}
|
|
36
|
-
function
|
|
37
|
-
const
|
|
38
|
-
return
|
|
36
|
+
function Y(t, e, i = /* @__PURE__ */ new Map()) {
|
|
37
|
+
const n = U(t, e);
|
|
38
|
+
return X(n, i);
|
|
39
39
|
}
|
|
40
|
-
function
|
|
41
|
-
function e(
|
|
40
|
+
function Z(t = {}) {
|
|
41
|
+
function e(r, p, u, v) {
|
|
42
42
|
if (typeof u == "number")
|
|
43
|
-
return
|
|
43
|
+
return v[r].length === u;
|
|
44
44
|
if (typeof u == "object") {
|
|
45
|
-
const
|
|
46
|
-
if (
|
|
47
|
-
return Number(
|
|
48
|
-
if (
|
|
49
|
-
return Number(
|
|
50
|
-
if (
|
|
51
|
-
return Number(
|
|
45
|
+
const k = Object.keys(u)[0], S = u[k];
|
|
46
|
+
if (k === "not")
|
|
47
|
+
return Number(v[r].length) !== Number(S);
|
|
48
|
+
if (k === "moreThan")
|
|
49
|
+
return Number(v[r].length) >= Number(S);
|
|
50
|
+
if (k === "lessThan")
|
|
51
|
+
return Number(v[r].length) <= Number(S);
|
|
52
52
|
}
|
|
53
53
|
return !1;
|
|
54
54
|
}
|
|
55
|
-
function
|
|
56
|
-
return
|
|
55
|
+
function i(r, p, u, v) {
|
|
56
|
+
return v[r] && v[r].propertyValue && String(v[r].propertyValue.value) === String(u);
|
|
57
57
|
}
|
|
58
|
-
const
|
|
58
|
+
const n = /* @__PURE__ */ new Map([
|
|
59
59
|
["length", e],
|
|
60
|
-
["getProperty",
|
|
60
|
+
["getProperty", i]
|
|
61
61
|
]);
|
|
62
|
-
Object.keys(t).reduce((
|
|
63
|
-
function
|
|
64
|
-
const u =
|
|
65
|
-
return typeof
|
|
66
|
-
if (
|
|
67
|
-
return { target: u, operator: "length", param: null, value: v
|
|
68
|
-
const
|
|
69
|
-
return { target: u, operator: "getProperty", param:
|
|
62
|
+
Object.keys(t).reduce((r, p) => (r.set(p, t[p]), r), n);
|
|
63
|
+
function l(r, p) {
|
|
64
|
+
const u = r;
|
|
65
|
+
return typeof p == "number" ? [{ target: u, operator: "length", param: null, value: Number(p) }] : typeof p == "boolean" ? [{ target: u, operator: "getProperty", param: r, value: !!p }] : typeof p == "object" ? Object.keys(p).map((v) => {
|
|
66
|
+
if (v === "length")
|
|
67
|
+
return { target: u, operator: "length", param: null, value: p[v] };
|
|
68
|
+
const k = v, S = p[v];
|
|
69
|
+
return { target: u, operator: "getProperty", param: k, value: S };
|
|
70
70
|
}) : [];
|
|
71
71
|
}
|
|
72
|
-
function y(
|
|
73
|
-
return Object.keys(
|
|
74
|
-
const
|
|
75
|
-
return u.push(...
|
|
72
|
+
function y(r) {
|
|
73
|
+
return Object.keys(r).reduce((u, v) => {
|
|
74
|
+
const k = l(v, r[v]);
|
|
75
|
+
return u.push(...k), u;
|
|
76
76
|
}, []);
|
|
77
77
|
}
|
|
78
|
-
function f(
|
|
79
|
-
if (
|
|
80
|
-
const u =
|
|
81
|
-
return u && u(
|
|
78
|
+
function f(r, p) {
|
|
79
|
+
if (n.has(r.operator)) {
|
|
80
|
+
const u = n.get(r.operator);
|
|
81
|
+
return u && u(r.target, r.param, r.value, p) || !1;
|
|
82
82
|
}
|
|
83
83
|
return !1;
|
|
84
84
|
}
|
|
85
|
-
function
|
|
86
|
-
return y(
|
|
85
|
+
function j(r, p) {
|
|
86
|
+
return y(r).reduce((k, S) => k && f(S, p), !0);
|
|
87
87
|
}
|
|
88
|
-
function b(
|
|
89
|
-
const u = Object.keys(
|
|
90
|
-
return
|
|
88
|
+
function b(r, p) {
|
|
89
|
+
const u = Object.keys(r), v = u.includes("allOf"), k = u.includes("anyOf"), S = v || k, T = (S ? r[S ? v ? "allOf" : "anyOf" : "allOf"] : [r]).map((D) => j(D, p));
|
|
90
|
+
return v ? !T.includes(!1) : T.includes(!0);
|
|
91
91
|
}
|
|
92
92
|
return { parseValueSchema: b };
|
|
93
93
|
}
|
|
94
|
-
const
|
|
95
|
-
|
|
96
|
-
function x(t, e,
|
|
97
|
-
return
|
|
98
|
-
const
|
|
99
|
-
return Object.assign(b,
|
|
94
|
+
const C = {}, K = {};
|
|
95
|
+
Z();
|
|
96
|
+
function x(t, e, i = /* @__PURE__ */ new Map(), n = (f, j, b) => j, l = {}, y = (f) => f) {
|
|
97
|
+
return q[e.title] = e, W[e.title] = n, C[e.title] = l, K[e.title] = y, (f = {}) => {
|
|
98
|
+
const j = Y(f, e, i), b = Object.keys(t).reduce((r, p) => (r[p] = t[p].default, r), {});
|
|
99
|
+
return Object.assign(b, j);
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
102
|
function I(t, e) {
|
|
@@ -105,7 +105,7 @@ function I(t, e) {
|
|
|
105
105
|
const ee = /* @__PURE__ */ new Map([
|
|
106
106
|
["appearance", I]
|
|
107
107
|
]);
|
|
108
|
-
function te(t, e,
|
|
108
|
+
function te(t, e, i) {
|
|
109
109
|
return e;
|
|
110
110
|
}
|
|
111
111
|
const se = "https://json-schema.org/draft/2020-12/schema", re = "https://farris-design.gitee.io/step.schema.json", ne = "step", ce = "A Farris Component", le = "object", ae = {
|
|
@@ -208,7 +208,7 @@ const se = "https://json-schema.org/draft/2020-12/schema", re = "https://farris-
|
|
|
208
208
|
description: pe,
|
|
209
209
|
type: fe,
|
|
210
210
|
categories: ve
|
|
211
|
-
},
|
|
211
|
+
}, L = {
|
|
212
212
|
/** 步骤条方向 */
|
|
213
213
|
direction: { type: String, default: "horizontal" },
|
|
214
214
|
/** 是否平铺 */
|
|
@@ -238,310 +238,302 @@ const se = "https://json-schema.org/draft/2020-12/schema", re = "https://farris-
|
|
|
238
238
|
/** 步骤条点击后事件 */
|
|
239
239
|
onClick: { type: Function, default: () => {
|
|
240
240
|
} }
|
|
241
|
-
},
|
|
241
|
+
}, F = x(L, oe, ee, te, he), A = /* @__PURE__ */ V({
|
|
242
242
|
name: "FStep",
|
|
243
|
-
props:
|
|
243
|
+
props: L,
|
|
244
244
|
emits: ["click"],
|
|
245
245
|
setup(t, e) {
|
|
246
|
-
const
|
|
247
|
-
"f-progress-step-list":
|
|
248
|
-
"f-progress-step-list-block":
|
|
249
|
-
"f-progress-step-horizontal-fill":
|
|
250
|
-
"f-progress-step-vertical-fill":
|
|
251
|
-
})),
|
|
252
|
-
height:
|
|
246
|
+
const i = O(t.direction), n = O(t.fill), l = O(t.height), y = O(t.steps), f = O(t.clickable), j = O(0), b = O(t.activeIndex), r = R(() => ({
|
|
247
|
+
"f-progress-step-list": i.value === "horizontal",
|
|
248
|
+
"f-progress-step-list-block": i.value === "vertical",
|
|
249
|
+
"f-progress-step-horizontal-fill": i.value === "horizontal" && n.value,
|
|
250
|
+
"f-progress-step-vertical-fill": i.value === "vertical" && n.value
|
|
251
|
+
})), p = R(() => ({
|
|
252
|
+
height: i.value === "vertical" ? `${l.value}px` : ""
|
|
253
253
|
}));
|
|
254
|
-
function u(
|
|
255
|
-
const
|
|
254
|
+
function u(c, s) {
|
|
255
|
+
const g = {
|
|
256
256
|
step: !0,
|
|
257
|
-
active:
|
|
257
|
+
active: s === b.value,
|
|
258
258
|
clickable: f.value,
|
|
259
259
|
// 'click-disable': step.disable,
|
|
260
|
-
current:
|
|
260
|
+
current: s === b.value
|
|
261
261
|
};
|
|
262
|
-
return
|
|
262
|
+
return s < b.value && (g.finish = !0), g;
|
|
263
263
|
}
|
|
264
|
-
function
|
|
265
|
-
const
|
|
266
|
-
step:
|
|
267
|
-
stepIndex:
|
|
264
|
+
function v(c, s) {
|
|
265
|
+
const g = {
|
|
266
|
+
step: c,
|
|
267
|
+
stepIndex: s
|
|
268
268
|
};
|
|
269
|
-
e.emit("click",
|
|
269
|
+
e.emit("click", g);
|
|
270
270
|
}
|
|
271
|
-
function
|
|
272
|
-
const
|
|
271
|
+
function k(c, s) {
|
|
272
|
+
const g = {
|
|
273
273
|
"f-progressstep-row": !0,
|
|
274
|
-
"step-active":
|
|
275
|
-
"step-current":
|
|
274
|
+
"step-active": s === b.value,
|
|
275
|
+
"step-current": s === b.value
|
|
276
276
|
};
|
|
277
|
-
return
|
|
277
|
+
return s < b.value && (g["step-finish"] = !0), g;
|
|
278
278
|
}
|
|
279
|
-
function
|
|
279
|
+
function S(c, s) {
|
|
280
280
|
return {
|
|
281
281
|
"step-icon": !0,
|
|
282
|
-
"step-success":
|
|
283
|
-
"f-icon":
|
|
284
|
-
"f-icon-check":
|
|
282
|
+
"step-success": s,
|
|
283
|
+
"f-icon": s,
|
|
284
|
+
"f-icon-check": s
|
|
285
285
|
};
|
|
286
286
|
}
|
|
287
|
-
function
|
|
288
|
-
const
|
|
289
|
-
return
|
|
287
|
+
function M(c, s) {
|
|
288
|
+
const g = [];
|
|
289
|
+
return s >= b.value || s === j.value ? g.push(d("span", {
|
|
290
290
|
class: "step-icon"
|
|
291
|
-
}, [
|
|
292
|
-
class:
|
|
293
|
-
}, null)),
|
|
291
|
+
}, [s + 1])) : g.push(d("span", {
|
|
292
|
+
class: S(c, !0)
|
|
293
|
+
}, null)), g;
|
|
294
294
|
}
|
|
295
|
-
function
|
|
295
|
+
function P(c, s) {
|
|
296
296
|
return {
|
|
297
297
|
"step-name": !0,
|
|
298
|
-
"step-name-success":
|
|
298
|
+
"step-name-success": s < b.value
|
|
299
299
|
};
|
|
300
300
|
}
|
|
301
|
-
function
|
|
301
|
+
function T(c, s) {
|
|
302
302
|
return d("div", {
|
|
303
303
|
class: "f-progress-step-title"
|
|
304
304
|
}, [d("p", {
|
|
305
|
-
class:
|
|
306
|
-
}, [
|
|
305
|
+
class: P(c, s)
|
|
306
|
+
}, [c.title])]);
|
|
307
307
|
}
|
|
308
|
-
function E(
|
|
308
|
+
function E(c, s) {
|
|
309
309
|
return {
|
|
310
310
|
"f-progress-step-line": !0,
|
|
311
|
-
"f-progress-step-line-success":
|
|
311
|
+
"f-progress-step-line-success": s === b.value
|
|
312
312
|
};
|
|
313
313
|
}
|
|
314
|
-
function
|
|
315
|
-
return
|
|
314
|
+
function D(c, s) {
|
|
315
|
+
return s !== y.value.length - 1;
|
|
316
316
|
}
|
|
317
|
-
const
|
|
317
|
+
const w = R(() => ({
|
|
318
318
|
triangle: !0,
|
|
319
|
-
"":
|
|
319
|
+
"": i.value === "vertical"
|
|
320
320
|
}));
|
|
321
|
-
function
|
|
322
|
-
return y.value.map((
|
|
323
|
-
class: u(
|
|
324
|
-
onClick: (
|
|
321
|
+
function h() {
|
|
322
|
+
return y.value.map((c, s) => d("li", {
|
|
323
|
+
class: u(c, s),
|
|
324
|
+
onClick: (g) => v(c, s)
|
|
325
325
|
}, [d("div", {
|
|
326
|
-
class:
|
|
326
|
+
class: k(c, s)
|
|
327
327
|
}, [d("div", {
|
|
328
328
|
class: "f-progress-step-content"
|
|
329
|
-
}, [
|
|
330
|
-
class: E(
|
|
329
|
+
}, [M(c, s), T(c, s)]), D(c, s) && d("div", {
|
|
330
|
+
class: E(c, s)
|
|
331
331
|
}, [d("span", {
|
|
332
|
-
class:
|
|
332
|
+
class: w.value
|
|
333
333
|
}, null)])])]));
|
|
334
334
|
}
|
|
335
|
-
return
|
|
336
|
-
t.activeIndex > -1 && t.activeIndex <= y.value.length && (b.value = t.activeIndex,
|
|
335
|
+
return G(() => t.activeIndex, () => {
|
|
336
|
+
t.activeIndex > -1 && t.activeIndex <= y.value.length && (b.value = t.activeIndex, h());
|
|
337
337
|
}), () => d("div", {
|
|
338
338
|
class: "f-progress-step"
|
|
339
339
|
}, [d("ul", {
|
|
340
|
-
class:
|
|
341
|
-
style:
|
|
342
|
-
}, [
|
|
340
|
+
class: r.value,
|
|
341
|
+
style: p.value
|
|
342
|
+
}, [h()])]);
|
|
343
343
|
}
|
|
344
344
|
});
|
|
345
|
-
function ge(t, e,
|
|
346
|
-
var
|
|
347
|
-
function
|
|
345
|
+
function ge(t, e, i) {
|
|
346
|
+
var w;
|
|
347
|
+
function n() {
|
|
348
348
|
}
|
|
349
|
-
const
|
|
350
|
-
function
|
|
349
|
+
const l = "", y = "", f = O();
|
|
350
|
+
function j() {
|
|
351
351
|
return (e == null ? void 0 : e.schema.componentType) !== "frame";
|
|
352
352
|
}
|
|
353
353
|
function b() {
|
|
354
354
|
return !1;
|
|
355
355
|
}
|
|
356
|
-
function
|
|
356
|
+
function r() {
|
|
357
357
|
return (e == null ? void 0 : e.schema.componentType) !== "frame";
|
|
358
358
|
}
|
|
359
|
-
function
|
|
359
|
+
function p() {
|
|
360
360
|
return (e == null ? void 0 : e.schema.componentType) === "frame";
|
|
361
361
|
}
|
|
362
|
-
function u(
|
|
363
|
-
if (!
|
|
362
|
+
function u(h) {
|
|
363
|
+
if (!h || !h.value)
|
|
364
364
|
return null;
|
|
365
|
-
if (
|
|
366
|
-
return
|
|
367
|
-
const
|
|
368
|
-
return
|
|
365
|
+
if (h.value.schema && h.value.schema.type === "component")
|
|
366
|
+
return h.value;
|
|
367
|
+
const c = O(h == null ? void 0 : h.value.parent), s = u(c);
|
|
368
|
+
return s || null;
|
|
369
369
|
}
|
|
370
|
-
function h
|
|
371
|
-
const { componentInstance:
|
|
372
|
-
return !
|
|
370
|
+
function v(h = e) {
|
|
371
|
+
const { componentInstance: c, designerItemElementRef: s } = h;
|
|
372
|
+
return !c || !c.value ? null : c.value.canMove ? s : v(h.parent);
|
|
373
373
|
}
|
|
374
|
-
function
|
|
375
|
-
return !!
|
|
374
|
+
function k(h) {
|
|
375
|
+
return !!i;
|
|
376
376
|
}
|
|
377
|
-
function
|
|
377
|
+
function S() {
|
|
378
378
|
return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
|
|
379
379
|
}
|
|
380
|
-
function
|
|
380
|
+
function M() {
|
|
381
381
|
}
|
|
382
|
-
function
|
|
382
|
+
function P(h, c) {
|
|
383
383
|
}
|
|
384
|
-
function
|
|
385
|
-
const { componentType:
|
|
386
|
-
let
|
|
387
|
-
const a =
|
|
388
|
-
return
|
|
384
|
+
function T(h, c) {
|
|
385
|
+
const { componentType: s } = h;
|
|
386
|
+
let g = _(s, h, c);
|
|
387
|
+
const a = s.toLowerCase().replace("-", "_");
|
|
388
|
+
return g && !g.id && g.type === s && (g.id = `${a}_${Math.random().toString().slice(2, 6)}`), g;
|
|
389
389
|
}
|
|
390
|
-
function E(
|
|
391
|
-
const p = String(s.getAttribute("data-controltype")), n = s.getAttribute("data-feature"), a = n ? JSON.parse(n) : {};
|
|
392
|
-
a.parentComponentInstance = f.value;
|
|
393
|
-
let g = L(p, a);
|
|
394
|
-
const D = p.toLowerCase().replace("-", "_");
|
|
395
|
-
return g && !g.id && g.type === p && (g.id = `${D}_${Math.random().toString().slice(2, 6)}`), g;
|
|
390
|
+
function E(h) {
|
|
396
391
|
}
|
|
397
|
-
function
|
|
398
|
-
}
|
|
399
|
-
function $(...s) {
|
|
392
|
+
function D(...h) {
|
|
400
393
|
}
|
|
401
394
|
return f.value = {
|
|
402
|
-
canMove:
|
|
395
|
+
canMove: j(),
|
|
403
396
|
canSelectParent: b(),
|
|
404
|
-
canDelete:
|
|
405
|
-
canNested: !
|
|
397
|
+
canDelete: r(),
|
|
398
|
+
canNested: !p(),
|
|
406
399
|
contents: e == null ? void 0 : e.schema.contents,
|
|
407
400
|
elementRef: t,
|
|
408
|
-
parent: (
|
|
401
|
+
parent: (w = e == null ? void 0 : e.parent) == null ? void 0 : w.componentInstance,
|
|
409
402
|
schema: e == null ? void 0 : e.schema,
|
|
410
|
-
styles:
|
|
403
|
+
styles: l,
|
|
411
404
|
designerClass: y,
|
|
412
|
-
canAccepts:
|
|
405
|
+
canAccepts: k,
|
|
413
406
|
getBelongedComponentInstance: u,
|
|
414
|
-
getDraggableDesignItemElement:
|
|
415
|
-
getDraggingDisplayText:
|
|
416
|
-
getPropConfig:
|
|
417
|
-
getDragScopeElement:
|
|
418
|
-
onAcceptMovedChildElement:
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
triggerBelongedComponentToDeleteWhenDeleted: m(!1)
|
|
407
|
+
getDraggableDesignItemElement: v,
|
|
408
|
+
getDraggingDisplayText: S,
|
|
409
|
+
getPropConfig: D,
|
|
410
|
+
getDragScopeElement: M,
|
|
411
|
+
onAcceptMovedChildElement: P,
|
|
412
|
+
onChildElementMovedOut: E,
|
|
413
|
+
addNewChildComponentSchema: T,
|
|
414
|
+
updateDragAndDropRules: n,
|
|
415
|
+
triggerBelongedComponentToMoveWhenMoved: O(!1),
|
|
416
|
+
triggerBelongedComponentToDeleteWhenDeleted: O(!1)
|
|
425
417
|
}, f;
|
|
426
418
|
}
|
|
427
|
-
const de = /* @__PURE__ */
|
|
419
|
+
const de = /* @__PURE__ */ V({
|
|
428
420
|
name: "FStepDesign",
|
|
429
|
-
props:
|
|
421
|
+
props: L,
|
|
430
422
|
emits: [],
|
|
431
423
|
setup(t, e) {
|
|
432
|
-
const
|
|
433
|
-
|
|
434
|
-
|
|
424
|
+
const i = O(t.direction), n = O(t.fill), l = O(t.height), y = O(t.steps), f = O(0), j = O(t.clickable), b = O(0), r = O(), p = H("design-item-context"), u = ge(r, p);
|
|
425
|
+
J(() => {
|
|
426
|
+
r.value.componentInstance = u;
|
|
435
427
|
}), e.expose(u.value);
|
|
436
|
-
const
|
|
437
|
-
"f-progress-step-list":
|
|
438
|
-
"f-progress-step-list-block":
|
|
439
|
-
"f-progress-step-horizontal-fill":
|
|
440
|
-
"f-progress-step-vertical-fill":
|
|
441
|
-
})),
|
|
442
|
-
height:
|
|
428
|
+
const v = R(() => ({
|
|
429
|
+
"f-progress-step-list": i.value === "horizontal",
|
|
430
|
+
"f-progress-step-list-block": i.value === "vertical",
|
|
431
|
+
"f-progress-step-horizontal-fill": i.value === "horizontal" && n.value,
|
|
432
|
+
"f-progress-step-vertical-fill": i.value === "vertical" && n.value
|
|
433
|
+
})), k = R(() => ({
|
|
434
|
+
height: i.value === "vertical" ? `${l.value}px` : ""
|
|
443
435
|
}));
|
|
444
|
-
function
|
|
445
|
-
const
|
|
436
|
+
function S(a, o) {
|
|
437
|
+
const m = {
|
|
446
438
|
step: !0,
|
|
447
|
-
active:
|
|
448
|
-
clickable:
|
|
449
|
-
"click-disable":
|
|
450
|
-
current:
|
|
439
|
+
active: o === f.value,
|
|
440
|
+
clickable: j.value,
|
|
441
|
+
"click-disable": a.disable,
|
|
442
|
+
current: o === f.value
|
|
451
443
|
};
|
|
452
|
-
return
|
|
444
|
+
return o < f.value && (m.finish = !0), a.status && (m[a.status] = !0), a.hasOwnProperty("class") && a.class.split(" ").reduce((N, $) => (N[$] = !0, N), m), m;
|
|
453
445
|
}
|
|
454
|
-
function
|
|
446
|
+
function M(a, o) {
|
|
455
447
|
}
|
|
456
|
-
function
|
|
457
|
-
const
|
|
448
|
+
function P(a, o) {
|
|
449
|
+
const m = {
|
|
458
450
|
"f-progressstep-row": !0,
|
|
459
|
-
"step-active":
|
|
460
|
-
"step-current":
|
|
451
|
+
"step-active": o === f.value,
|
|
452
|
+
"step-current": o === f.value
|
|
461
453
|
};
|
|
462
|
-
return
|
|
454
|
+
return o < f.value && (m["step-finish"] = !0), a.status && (m["step-" + a.status] = !0), m;
|
|
463
455
|
}
|
|
464
|
-
function
|
|
465
|
-
const
|
|
456
|
+
function T(a, o) {
|
|
457
|
+
const m = {
|
|
466
458
|
"step-icon": !0,
|
|
467
|
-
"step-success":
|
|
468
|
-
"k-icon":
|
|
469
|
-
"k-i-check":
|
|
459
|
+
"step-success": o,
|
|
460
|
+
"k-icon": o,
|
|
461
|
+
"k-i-check": o
|
|
470
462
|
};
|
|
471
|
-
return
|
|
463
|
+
return a.hasOwnProperty("icon") && a.class.split(" ").reduce((N, $) => (N[$] = !0, N), m), m;
|
|
472
464
|
}
|
|
473
|
-
function E(
|
|
474
|
-
const
|
|
475
|
-
return
|
|
476
|
-
class:
|
|
477
|
-
}, null)) :
|
|
465
|
+
function E(a, o) {
|
|
466
|
+
const m = [];
|
|
467
|
+
return a.icon ? m.push(d("span", {
|
|
468
|
+
class: T(a, !1)
|
|
469
|
+
}, null)) : o >= f.value || o === b.value ? m.push(d("span", {
|
|
478
470
|
class: "step-icon"
|
|
479
|
-
}, [
|
|
480
|
-
class:
|
|
481
|
-
}, null)),
|
|
471
|
+
}, [o + 1])) : m.push(d("span", {
|
|
472
|
+
class: T(a, !0)
|
|
473
|
+
}, null)), m;
|
|
482
474
|
}
|
|
483
|
-
function
|
|
475
|
+
function D(a, o) {
|
|
484
476
|
return {
|
|
485
477
|
"step-name": !0,
|
|
486
|
-
"step-name-success":
|
|
478
|
+
"step-name-success": o < f.value
|
|
487
479
|
};
|
|
488
480
|
}
|
|
489
|
-
function
|
|
481
|
+
function w(a, o) {
|
|
490
482
|
return d("div", {
|
|
491
483
|
class: "f-progress-step-title"
|
|
492
484
|
}, [d("p", {
|
|
493
|
-
class:
|
|
494
|
-
}, [
|
|
485
|
+
class: D(a, o)
|
|
486
|
+
}, [a.title])]);
|
|
495
487
|
}
|
|
496
|
-
function
|
|
488
|
+
function h(a, o) {
|
|
497
489
|
return {
|
|
498
490
|
"f-progress-step-line": !0,
|
|
499
|
-
"f-progress-step-line-success":
|
|
491
|
+
"f-progress-step-line-success": o === f.value
|
|
500
492
|
};
|
|
501
493
|
}
|
|
502
|
-
function
|
|
503
|
-
return
|
|
494
|
+
function c(a, o) {
|
|
495
|
+
return o !== y.value.length - 1;
|
|
504
496
|
}
|
|
505
|
-
const
|
|
497
|
+
const s = R(() => ({
|
|
506
498
|
triangle: !0,
|
|
507
|
-
"":
|
|
499
|
+
"": i.value === "vertical"
|
|
508
500
|
}));
|
|
509
|
-
function
|
|
510
|
-
return y.value.map((
|
|
511
|
-
class:
|
|
512
|
-
onClick: (
|
|
501
|
+
function g() {
|
|
502
|
+
return y.value.map((a, o) => d("li", {
|
|
503
|
+
class: S(a, o),
|
|
504
|
+
onClick: (m) => void 0
|
|
513
505
|
}, [d("div", {
|
|
514
|
-
class:
|
|
506
|
+
class: P(a, o)
|
|
515
507
|
}, [d("div", {
|
|
516
508
|
class: "f-progress-step-content"
|
|
517
|
-
}, [E(
|
|
518
|
-
class:
|
|
509
|
+
}, [E(a, o), w(a, o)]), c(a, o) && d("div", {
|
|
510
|
+
class: h(a, o)
|
|
519
511
|
}, [d("span", {
|
|
520
|
-
class:
|
|
512
|
+
class: s.value
|
|
521
513
|
}, null)])])]));
|
|
522
514
|
}
|
|
523
515
|
return () => d("div", {
|
|
524
|
-
ref:
|
|
516
|
+
ref: r,
|
|
525
517
|
class: "f-progress-step"
|
|
526
518
|
}, [d("ul", {
|
|
527
|
-
class:
|
|
528
|
-
style:
|
|
529
|
-
}, [
|
|
519
|
+
class: v.value,
|
|
520
|
+
style: k.value
|
|
521
|
+
}, [g()])]);
|
|
530
522
|
}
|
|
531
523
|
}), me = {
|
|
532
524
|
install(t) {
|
|
533
525
|
t.component(A.name, A);
|
|
534
526
|
},
|
|
535
|
-
register(t, e,
|
|
536
|
-
t.step = A, e.step =
|
|
527
|
+
register(t, e, i, n) {
|
|
528
|
+
t.step = A, e.step = F;
|
|
537
529
|
},
|
|
538
|
-
registerDesigner(t, e,
|
|
539
|
-
t.step = de, e.step =
|
|
530
|
+
registerDesigner(t, e, i) {
|
|
531
|
+
t.step = de, e.step = F;
|
|
540
532
|
}
|
|
541
533
|
};
|
|
542
534
|
export {
|
|
543
535
|
A as Step,
|
|
544
536
|
me as default,
|
|
545
|
-
|
|
546
|
-
|
|
537
|
+
F as propsResolver,
|
|
538
|
+
L as stepProps
|
|
547
539
|
};
|