@farris/ui-vue 1.2.7 → 1.2.8
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 +79 -79
- package/components/avatar/index.esm.js +393 -440
- package/components/border-editor/index.esm.js +4 -4
- package/components/button/index.esm.js +1 -1
- package/components/button-edit/index.esm.js +353 -444
- package/components/button-group/index.esm.js +5 -5
- package/components/calendar/index.esm.js +176 -176
- package/components/capsule/index.esm.js +93 -93
- package/components/checkbox/index.esm.js +496 -542
- package/components/color-picker/index.esm.js +1 -1
- package/components/combo-list/index.esm.js +437 -483
- package/components/combo-tree/index.esm.js +8 -8
- package/components/component/index.esm.js +89 -89
- package/components/condition/index.esm.js +839 -726
- package/components/content-container/index.esm.js +61 -61
- package/components/data-grid/index.esm.js +4702 -4972
- package/components/data-view/index.esm.js +2999 -2875
- package/components/date-picker/index.esm.js +2626 -2672
- package/components/dependent-base/style.js +1 -0
- package/components/dependent-fluid/style.js +1 -0
- package/components/dependent-icon/style.js +1 -0
- package/components/dependent-input/style.js +1 -0
- package/components/dependent-table/style.js +1 -0
- package/components/designer-canvas/index.esm.js +478 -475
- package/components/designer-outline/index.esm.js +173 -131
- package/components/discussion-editor/index.esm.js +1 -1
- package/components/dropdown/index.esm.js +73 -73
- package/components/dynamic-form/index.esm.js +934 -976
- package/components/dynamic-resolver/index.esm.js +67 -35
- package/components/dynamic-view/index.esm.js +258 -249
- package/components/enum-editor/index.esm.js +3 -3
- package/components/events-editor/index.esm.js +178 -178
- package/components/expression-editor/index.esm.js +105 -105
- package/components/external-container/index.esm.js +1892 -1775
- package/components/field-selector/index.css +1 -1
- package/components/field-selector/index.esm.js +5245 -5514
- package/components/filter-bar/index.css +1 -1
- package/components/filter-bar/index.esm.js +1483 -1556
- package/components/flow-canvas/index.esm.js +678 -675
- package/components/image-cropper/index.esm.js +266 -266
- package/components/input-group/index.esm.js +668 -714
- package/components/layout/index.esm.js +148 -148
- package/components/list-nav/index.esm.js +109 -109
- package/components/list-view/index.esm.js +1679 -1563
- package/components/lookup/index.css +1 -1
- package/components/lookup/index.esm.js +6596 -6865
- package/components/mapping-editor/index.esm.js +5592 -5862
- package/components/message-box/index.esm.js +1 -1
- package/components/modal/index.esm.js +1 -1
- package/components/nav/index.esm.js +86 -86
- package/components/number-range/index.esm.js +1120 -0
- package/components/number-range/package.json +8 -0
- package/components/number-range/style.js +6 -0
- package/components/number-spinner/index.esm.js +1146 -0
- package/components/number-spinner/package.json +8 -0
- package/components/number-spinner/style.js +4 -0
- package/components/order/index.esm.js +988 -1034
- package/components/page-footer/index.esm.js +106 -106
- package/components/page-header/index.esm.js +1088 -1296
- package/components/pagination/index.esm.js +252 -252
- package/components/progress/index.esm.js +37 -37
- package/components/property-editor/index.esm.js +1416 -1462
- package/components/property-panel/index.css +1 -1
- package/components/property-panel/index.esm.js +757 -830
- package/components/query-solution/index.css +1 -0
- package/components/query-solution/index.esm.js +6935 -0
- package/components/query-solution/package.json +8 -0
- package/components/query-solution/style.js +2 -0
- package/components/radio-button/index.esm.js +64 -64
- package/components/radio-group/index.esm.js +452 -498
- package/components/rate/index.esm.js +92 -92
- package/components/response-layout/index.esm.js +33 -33
- package/components/response-layout-editor/index.esm.js +117 -117
- package/components/response-toolbar/index.esm.js +1021 -1238
- package/components/schema-selector/index.esm.js +3215 -3308
- package/components/search-box/index.esm.js +143 -143
- package/components/section/index.esm.js +209 -209
- package/components/smoke-detector/index.esm.js +22 -22
- package/components/spacing-editor/index.esm.js +2 -2
- package/components/splitter/index.esm.js +1097 -394
- package/components/step/index.esm.js +153 -153
- package/components/switch/index.esm.js +442 -488
- package/components/tabs/index.esm.js +1835 -2004
- package/components/tags/index.esm.js +215 -215
- package/components/text/index.esm.js +53 -53
- package/components/textarea/index.esm.js +451 -482
- package/components/time-picker/index.esm.js +1345 -1392
- package/components/transfer/index.esm.js +135 -135
- package/components/tree-grid/index.css +1 -1
- package/components/tree-grid/index.esm.js +5761 -6020
- package/components/tree-view/index.esm.js +2380 -2253
- package/components/uploader/index.esm.js +1 -1
- package/components/verify-detail/index.esm.js +232 -232
- package/components/video/index.esm.js +136 -136
- package/components/weather/index.esm.js +2 -2
- package/farris.all.esm.js +31630 -31224
- package/farris.all.umd.cjs +9 -9
- package/index.css +1 -1
- package/package.json +1 -1
- package/types/checkbox/index.d.ts +1 -0
- package/types/data-grid/src/designer/column-header.design.component.d.ts +1 -1
- package/types/data-grid/src/designer/data-grid-column.props.d.ts +1 -0
- package/types/data-view/composition/types.d.ts +1 -1
- package/types/designer-canvas/src/composition/dg-control.d.ts +16 -350
- package/types/designer-canvas/src/types.d.ts +1 -1
- package/types/dynamic-form/index.d.ts +1 -0
- package/types/dynamic-form/src/types.d.ts +1 -1
- package/types/dynamic-resolver/index.d.ts +1 -0
- package/types/dynamic-resolver/src/binding-resolver.d.ts +1 -0
- package/types/dynamic-view/src/dynamic-view.component.d.ts +1 -1
- package/types/lookup/src/property-config/lookup.property-config.d.ts +2 -1
- package/types/modal/src/modal.props.d.ts +1 -4
- package/types/property-panel/src/composition/entity/base-property.d.ts +0 -12
- package/types/property-panel/src/composition/entity/input-base-property.d.ts +11 -26
- package/types/property-panel/src/composition/entity/schema-dom-mapping.d.ts +10 -8
- package/types/tabs/src/designer/tab-toolbar-item.props.d.ts +19 -0
- package/types/tabs/src/property-config/tabs.property-config.d.ts +6 -6
- package/types/tree-grid/src/designer/use-designer-rules.d.ts +3 -0
- package/types/tree-grid/src/property-config/tree-grid.property-config.d.ts +11 -0
- package/types/tree-grid/src/schema/column-resolver.d.ts +1 -1
- package/types/tree-grid/src/tree-grid.props.d.ts +8 -0
- package/components/accordion/index.umd.cjs +0 -1
- package/components/avatar/index.umd.cjs +0 -1
- package/components/border-editor/index.umd.cjs +0 -1
- package/components/button/index.umd.cjs +0 -1
- package/components/button-edit/index.umd.cjs +0 -1
- package/components/button-group/index.umd.cjs +0 -1
- package/components/calculator/index.umd.cjs +0 -1
- package/components/calendar/index.umd.cjs +0 -1
- package/components/capsule/index.umd.cjs +0 -1
- package/components/checkbox/index.umd.cjs +0 -1
- package/components/color-picker/index.umd.cjs +0 -3
- package/components/combo-list/index.umd.cjs +0 -1
- package/components/combo-tree/index.umd.cjs +0 -1
- package/components/common/index.umd.cjs +0 -1
- package/components/component/index.umd.cjs +0 -1
- package/components/condition/index.umd.cjs +0 -1
- package/components/content-container/index.umd.cjs +0 -1
- package/components/data-grid/index.umd.cjs +0 -1
- package/components/data-view/index.umd.cjs +0 -1
- package/components/date-picker/index.umd.cjs +0 -1
- package/components/designer-canvas/index.umd.cjs +0 -1
- package/components/designer-outline/index.umd.cjs +0 -1
- package/components/designer-toolbox/index.umd.cjs +0 -1
- package/components/discussion-editor/index.umd.cjs +0 -3
- package/components/discussion-list/index.umd.cjs +0 -1
- package/components/drawer/index.umd.cjs +0 -1
- package/components/dropdown/index.umd.cjs +0 -2
- package/components/dynamic-form/index.umd.cjs +0 -1
- package/components/dynamic-resolver/index.umd.cjs +0 -1
- package/components/dynamic-view/index.umd.cjs +0 -1
- package/components/enum-editor/index.umd.cjs +0 -1
- package/components/events-editor/index.umd.cjs +0 -1
- package/components/expression-editor/index.umd.cjs +0 -1
- package/components/external-container/index.umd.cjs +0 -1
- package/components/field-selector/index.umd.cjs +0 -1
- package/components/filter-bar/index.umd.cjs +0 -1
- package/components/flow-canvas/index.umd.cjs +0 -1
- package/components/image-cropper/index.umd.cjs +0 -1
- package/components/input-group/index.umd.cjs +0 -1
- package/components/layout/index.umd.cjs +0 -1
- package/components/list-nav/index.umd.cjs +0 -1
- package/components/list-view/index.umd.cjs +0 -1
- package/components/loading/index.umd.cjs +0 -8
- package/components/locale/index.umd.cjs +0 -1
- package/components/lookup/index.umd.cjs +0 -1
- package/components/mapping-editor/index.umd.cjs +0 -1
- package/components/message-box/index.umd.cjs +0 -1
- package/components/modal/index.umd.cjs +0 -1
- package/components/nav/index.umd.cjs +0 -3
- package/components/notify/index.umd.cjs +0 -1
- package/components/order/index.umd.cjs +0 -1
- package/components/page-footer/index.umd.cjs +0 -1
- package/components/page-header/index.umd.cjs +0 -1
- package/components/pagination/index.umd.cjs +0 -1
- package/components/popover/index.umd.cjs +0 -1
- package/components/progress/index.umd.cjs +0 -3
- package/components/property-editor/index.umd.cjs +0 -3
- package/components/property-panel/index.umd.cjs +0 -1
- package/components/radio-button/index.umd.cjs +0 -1
- package/components/radio-group/index.umd.cjs +0 -1
- package/components/rate/index.umd.cjs +0 -1
- package/components/response-layout/index.umd.cjs +0 -1
- package/components/response-layout-editor/index.umd.cjs +0 -1
- package/components/response-toolbar/index.umd.cjs +0 -1
- package/components/schema-selector/index.umd.cjs +0 -8
- package/components/search-box/index.umd.cjs +0 -1
- package/components/section/index.umd.cjs +0 -1
- package/components/smoke-detector/index.umd.cjs +0 -1
- package/components/spacing-editor/index.umd.cjs +0 -1
- package/components/splitter/index.umd.cjs +0 -1
- package/components/step/index.umd.cjs +0 -1
- package/components/switch/index.umd.cjs +0 -1
- package/components/tabs/index.umd.cjs +0 -1
- package/components/tags/index.umd.cjs +0 -1
- package/components/text/index.umd.cjs +0 -1
- package/components/textarea/index.umd.cjs +0 -1
- package/components/time-picker/index.umd.cjs +0 -1
- package/components/tooltip/index.umd.cjs +0 -1
- package/components/transfer/index.umd.cjs +0 -1
- package/components/tree-grid/index.umd.cjs +0 -1
- package/components/tree-view/index.umd.cjs +0 -1
- package/components/uploader/index.umd.cjs +0 -2
- package/components/verify-detail/index.umd.cjs +0 -1
- package/components/video/index.umd.cjs +0 -1
- package/components/weather/index.umd.cjs +0 -16
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { ref as S, onMounted as _, defineComponent as W, createVNode as m, withDirectives as
|
|
2
|
-
import { cloneDeep as
|
|
1
|
+
import { ref as S, onMounted as _, defineComponent as W, createVNode as m, withDirectives as L, vShow as z, Teleport as Q, Fragment as Y, inject as U } from "vue";
|
|
2
|
+
import { cloneDeep as P } from "lodash-es";
|
|
3
3
|
const J = {}, Z = {};
|
|
4
|
-
function
|
|
5
|
-
const { properties: t, title: a } = e, o = Object.keys(t).reduce((s, d) => (s[d] = t[d].type === "object" && t[d].properties ?
|
|
4
|
+
function C(e) {
|
|
5
|
+
const { properties: t, title: a } = e, o = Object.keys(t).reduce((s, d) => (s[d] = t[d].type === "object" && t[d].properties ? C(t[d]) : P(t[d].default), s), {});
|
|
6
6
|
return o.id = `${a}-${Date.now()}`, o;
|
|
7
7
|
}
|
|
8
8
|
function M(e, t = {}) {
|
|
9
9
|
const a = J[e];
|
|
10
10
|
if (a) {
|
|
11
|
-
let o =
|
|
11
|
+
let o = C(a);
|
|
12
12
|
const s = Z[e];
|
|
13
13
|
return o = s ? s({ getSchemaByType: M }, o, t) : o, o;
|
|
14
14
|
}
|
|
15
15
|
return null;
|
|
16
16
|
}
|
|
17
|
-
function
|
|
18
|
-
const a =
|
|
19
|
-
return Object.keys(e).reduce((o, s) => (o[s] = e[s], o), a), a;
|
|
17
|
+
function K(e, t) {
|
|
18
|
+
const a = C(t);
|
|
19
|
+
return Object.keys(e).reduce((o, s) => (o[s] && typeof o[s] == "object" ? Object.assign(o[s], e[s]) : o[s] = e[s], o), a), a;
|
|
20
20
|
}
|
|
21
21
|
function I(e, t) {
|
|
22
22
|
return Object.keys(e).filter((o) => e[o] != null).reduce((o, s) => {
|
|
@@ -34,79 +34,79 @@ function I(e, t) {
|
|
|
34
34
|
}, {});
|
|
35
35
|
}
|
|
36
36
|
function ee(e, t, a = /* @__PURE__ */ new Map()) {
|
|
37
|
-
const o =
|
|
37
|
+
const o = K(e, t);
|
|
38
38
|
return I(o, a);
|
|
39
39
|
}
|
|
40
40
|
function te(e = {}) {
|
|
41
|
-
function t(
|
|
42
|
-
if (typeof
|
|
43
|
-
return u[
|
|
44
|
-
if (typeof
|
|
45
|
-
const b = Object.keys(
|
|
41
|
+
function t(i, l, r, u) {
|
|
42
|
+
if (typeof r == "number")
|
|
43
|
+
return u[i].length === r;
|
|
44
|
+
if (typeof r == "object") {
|
|
45
|
+
const b = Object.keys(r)[0], y = r[b];
|
|
46
46
|
if (b === "not")
|
|
47
|
-
return Number(u[
|
|
47
|
+
return Number(u[i].length) !== Number(y);
|
|
48
48
|
if (b === "moreThan")
|
|
49
|
-
return Number(u[
|
|
49
|
+
return Number(u[i].length) >= Number(y);
|
|
50
50
|
if (b === "lessThan")
|
|
51
|
-
return Number(u[
|
|
51
|
+
return Number(u[i].length) <= Number(y);
|
|
52
52
|
}
|
|
53
53
|
return !1;
|
|
54
54
|
}
|
|
55
|
-
function a(
|
|
56
|
-
return u[
|
|
55
|
+
function a(i, l, r, u) {
|
|
56
|
+
return u[i] && u[i].propertyValue && String(u[i].propertyValue.value) === String(r);
|
|
57
57
|
}
|
|
58
58
|
const o = /* @__PURE__ */ new Map([
|
|
59
59
|
["length", t],
|
|
60
60
|
["getProperty", a]
|
|
61
61
|
]);
|
|
62
|
-
Object.keys(e).reduce((
|
|
63
|
-
function s(
|
|
64
|
-
const
|
|
65
|
-
return typeof l == "number" ? [{ target:
|
|
62
|
+
Object.keys(e).reduce((i, l) => (i.set(l, e[l]), i), o);
|
|
63
|
+
function s(i, l) {
|
|
64
|
+
const r = i;
|
|
65
|
+
return typeof l == "number" ? [{ target: r, operator: "length", param: null, value: Number(l) }] : typeof l == "boolean" ? [{ target: r, operator: "getProperty", param: i, value: !!l }] : typeof l == "object" ? Object.keys(l).map((u) => {
|
|
66
66
|
if (u === "length")
|
|
67
|
-
return { target:
|
|
67
|
+
return { target: r, operator: "length", param: null, value: l[u] };
|
|
68
68
|
const b = u, y = l[u];
|
|
69
|
-
return { target:
|
|
69
|
+
return { target: r, operator: "getProperty", param: b, value: y };
|
|
70
70
|
}) : [];
|
|
71
71
|
}
|
|
72
|
-
function d(
|
|
73
|
-
return Object.keys(
|
|
74
|
-
const b = s(u,
|
|
75
|
-
return
|
|
72
|
+
function d(i) {
|
|
73
|
+
return Object.keys(i).reduce((r, u) => {
|
|
74
|
+
const b = s(u, i[u]);
|
|
75
|
+
return r.push(...b), r;
|
|
76
76
|
}, []);
|
|
77
77
|
}
|
|
78
|
-
function g(
|
|
79
|
-
if (o.has(
|
|
80
|
-
const
|
|
81
|
-
return
|
|
78
|
+
function g(i, l) {
|
|
79
|
+
if (o.has(i.operator)) {
|
|
80
|
+
const r = o.get(i.operator);
|
|
81
|
+
return r && r(i.target, i.param, i.value, l) || !1;
|
|
82
82
|
}
|
|
83
83
|
return !1;
|
|
84
84
|
}
|
|
85
|
-
function p(
|
|
86
|
-
return d(
|
|
85
|
+
function p(i, l) {
|
|
86
|
+
return d(i).reduce((b, y) => b && g(y, l), !0);
|
|
87
87
|
}
|
|
88
|
-
function k(
|
|
89
|
-
const
|
|
88
|
+
function k(i, l) {
|
|
89
|
+
const r = Object.keys(i), u = r.includes("allOf"), b = r.includes("anyOf"), y = u || b, c = (y ? i[y ? u ? "allOf" : "anyOf" : "allOf"] : [i]).map((B) => p(B, l));
|
|
90
90
|
return u ? !c.includes(!1) : c.includes(!0);
|
|
91
91
|
}
|
|
92
92
|
return { parseValueSchema: k };
|
|
93
93
|
}
|
|
94
94
|
const ne = {}, oe = {};
|
|
95
95
|
te();
|
|
96
|
-
function
|
|
96
|
+
function ie(e, t, a = /* @__PURE__ */ new Map(), o = (g, p, k) => p, s = {}, d = (g) => g) {
|
|
97
97
|
return J[t.title] = t, Z[t.title] = o, ne[t.title] = s, oe[t.title] = d, (g = {}) => {
|
|
98
|
-
const p = ee(g, t, a), k = Object.keys(e).reduce((
|
|
98
|
+
const p = ee(g, t, a), k = Object.keys(e).reduce((i, l) => (i[l] = e[l].default, i), {});
|
|
99
99
|
return Object.assign(k, p);
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
|
-
function
|
|
102
|
+
function re(e, t) {
|
|
103
103
|
return { customClass: t.class, customStyle: t.style };
|
|
104
104
|
}
|
|
105
105
|
function se(e, t, a) {
|
|
106
106
|
return t;
|
|
107
107
|
}
|
|
108
108
|
const ae = /* @__PURE__ */ new Map([
|
|
109
|
-
["appearance",
|
|
109
|
+
["appearance", re]
|
|
110
110
|
]), le = "https://json-schema.org/draft/2020-12/schema", ce = "https://farris-design.gitee.io/dropdown.schema.json", ue = "dropdown", de = "A Farris Component", fe = "object", pe = {
|
|
111
111
|
id: {
|
|
112
112
|
description: "The unique identifier for dropdown",
|
|
@@ -238,7 +238,7 @@ const ae = /* @__PURE__ */ new Map([
|
|
|
238
238
|
description: be,
|
|
239
239
|
type: we,
|
|
240
240
|
categories: he
|
|
241
|
-
},
|
|
241
|
+
}, V = {
|
|
242
242
|
/** 默认展开或折叠 */
|
|
243
243
|
show: { type: Boolean, default: !1 },
|
|
244
244
|
/** 下拉按钮是否禁用 */
|
|
@@ -268,7 +268,7 @@ const ae = /* @__PURE__ */ new Map([
|
|
|
268
268
|
},
|
|
269
269
|
onSelect: { type: Function, default: () => {
|
|
270
270
|
} }
|
|
271
|
-
}, X =
|
|
271
|
+
}, X = ie(V, ye, ae, se, ve);
|
|
272
272
|
function x(e, t) {
|
|
273
273
|
let a;
|
|
274
274
|
const o = S(e.show), s = S(), d = S(), g = S(), p = 10;
|
|
@@ -292,13 +292,13 @@ function x(e, t) {
|
|
|
292
292
|
}).filter((h) => h);
|
|
293
293
|
let D = Math.max(...B);
|
|
294
294
|
return D < 1040 && (D = 1040), D + c;
|
|
295
|
-
},
|
|
295
|
+
}, i = (c, n) => {
|
|
296
296
|
const {
|
|
297
297
|
height: B,
|
|
298
298
|
left: D,
|
|
299
299
|
top: h,
|
|
300
300
|
width: f
|
|
301
|
-
} = c.getBoundingClientRect(), { width: w, height: v, top:
|
|
301
|
+
} = c.getBoundingClientRect(), { width: w, height: v, top: j } = n.getBoundingClientRect();
|
|
302
302
|
if (c.className.indexOf("dropdown-submenu") > -1 || c.closest(".dropdown-submenu") || c.classList.contains("dropright")) {
|
|
303
303
|
const E = window.innerWidth - D - c.offsetWidth, N = window.innerHeight - h, { position: O } = getComputedStyle(n);
|
|
304
304
|
if (O === "fixed") {
|
|
@@ -320,9 +320,9 @@ function x(e, t) {
|
|
|
320
320
|
!important;top:${H}px !important;right: unset;${O ? "max-height:" + O + "px;overflow-y:auto;" : ""}`, O && (n.className += " dropdown-menu-maxheight"), n.style.zIndex = k().toString();
|
|
321
321
|
}
|
|
322
322
|
}, l = () => {
|
|
323
|
-
|
|
324
|
-
},
|
|
325
|
-
e.hover || (o.value = !1, document.removeEventListener("click",
|
|
323
|
+
i(s.value, d.value);
|
|
324
|
+
}, r = () => {
|
|
325
|
+
e.hover || (o.value = !1, document.removeEventListener("click", r), a.removeEventListener("click", r), document.removeEventListener("scroll", r), a.removeEventListener("scroll", r));
|
|
326
326
|
};
|
|
327
327
|
return {
|
|
328
328
|
show: o,
|
|
@@ -332,7 +332,7 @@ function x(e, t) {
|
|
|
332
332
|
showDropMenu: (c) => {
|
|
333
333
|
e.hover || e.disabled || (c == null || c.stopPropagation(), o.value || setTimeout(() => {
|
|
334
334
|
l();
|
|
335
|
-
}), o.value = !o.value, document.addEventListener("click",
|
|
335
|
+
}), o.value = !o.value, document.addEventListener("click", r), document.addEventListener("scroll", r), e.hideOnClick || (a.addEventListener("click", (n) => {
|
|
336
336
|
n.stopPropagation();
|
|
337
337
|
}), a.addEventListener("scroll", (n) => {
|
|
338
338
|
n.stopPropagation();
|
|
@@ -344,7 +344,7 @@ function x(e, t) {
|
|
|
344
344
|
},
|
|
345
345
|
leftButtonClick: () => {
|
|
346
346
|
},
|
|
347
|
-
closeDropMenu:
|
|
347
|
+
closeDropMenu: r,
|
|
348
348
|
selectItem: (c) => {
|
|
349
349
|
t.emit("select", c);
|
|
350
350
|
},
|
|
@@ -373,7 +373,7 @@ const Se = {
|
|
|
373
373
|
const a = S(e.value), o = S(e.label), s = S(e.disabled), d = S(e.active), g = S(e.divide), p = () => {
|
|
374
374
|
s.value || t.emit("select", e);
|
|
375
375
|
};
|
|
376
|
-
return () => m("div", null, [
|
|
376
|
+
return () => m("div", null, [L(m("div", {
|
|
377
377
|
class: "dropdown-divider"
|
|
378
378
|
}, null), [[z, g.value]]), m("li", {
|
|
379
379
|
class: `dropdown-item${d.value ? " active" : ""} ${s.value ? " disabled" : ""}`,
|
|
@@ -383,7 +383,7 @@ const Se = {
|
|
|
383
383
|
}
|
|
384
384
|
}), F = /* @__PURE__ */ W({
|
|
385
385
|
name: "FDropdown",
|
|
386
|
-
props:
|
|
386
|
+
props: V,
|
|
387
387
|
emits: ["select"],
|
|
388
388
|
setup(e, t) {
|
|
389
389
|
const a = S(e.model), {
|
|
@@ -393,9 +393,9 @@ const Se = {
|
|
|
393
393
|
clickEventRef: g,
|
|
394
394
|
showDropMenu: p,
|
|
395
395
|
hoverDropdown: k,
|
|
396
|
-
leftButtonClick:
|
|
396
|
+
leftButtonClick: i,
|
|
397
397
|
closeDropMenu: l,
|
|
398
|
-
selectItem:
|
|
398
|
+
selectItem: r,
|
|
399
399
|
resolveSize: u
|
|
400
400
|
} = x(e, t);
|
|
401
401
|
function b(y) {
|
|
@@ -432,7 +432,7 @@ const Se = {
|
|
|
432
432
|
"btn-info": e.type === "info"
|
|
433
433
|
}],
|
|
434
434
|
style: "width:100%",
|
|
435
|
-
onClick:
|
|
435
|
+
onClick: i
|
|
436
436
|
}, [e.title]), m("span", {
|
|
437
437
|
ref: g,
|
|
438
438
|
class: ["dropdown-toggle", {
|
|
@@ -466,9 +466,9 @@ const Se = {
|
|
|
466
466
|
onClick: p,
|
|
467
467
|
onMouseenter: k,
|
|
468
468
|
onMouseleave: k
|
|
469
|
-
}, [
|
|
469
|
+
}, [L(m("span", {
|
|
470
470
|
class: "sr-only"
|
|
471
|
-
}, null), [[z, e.splitButton]]), e.splitButton ? "" : e.title,
|
|
471
|
+
}, null), [[z, e.splitButton]]), e.splitButton ? "" : e.title, L(m("span", {
|
|
472
472
|
class: `f-icon ${e.iconClass.toString()}`
|
|
473
473
|
}, null), [[z, e.iconClass]])]), m(Q, {
|
|
474
474
|
to: "body"
|
|
@@ -504,18 +504,18 @@ function De(e, t, a) {
|
|
|
504
504
|
function k() {
|
|
505
505
|
return !1;
|
|
506
506
|
}
|
|
507
|
-
function
|
|
507
|
+
function i() {
|
|
508
508
|
return (t == null ? void 0 : t.schema.componentType) !== "frame";
|
|
509
509
|
}
|
|
510
510
|
function l() {
|
|
511
511
|
return (t == null ? void 0 : t.schema.componentType) === "frame";
|
|
512
512
|
}
|
|
513
|
-
function
|
|
513
|
+
function r(f) {
|
|
514
514
|
if (!f || !f.value)
|
|
515
515
|
return null;
|
|
516
516
|
if (f.value.schema && f.value.schema.type === "component")
|
|
517
517
|
return f.value;
|
|
518
|
-
const w = S(f == null ? void 0 : f.value.parent), v =
|
|
518
|
+
const w = S(f == null ? void 0 : f.value.parent), v = r(w);
|
|
519
519
|
return v || null;
|
|
520
520
|
}
|
|
521
521
|
function u(f = t) {
|
|
@@ -535,11 +535,11 @@ function De(e, t, a) {
|
|
|
535
535
|
function c(f) {
|
|
536
536
|
const { componentType: w } = f;
|
|
537
537
|
let v = M(w, f);
|
|
538
|
-
const
|
|
539
|
-
return v && !v.id && v.type === w && (v.id = `${
|
|
538
|
+
const j = w.toLowerCase().replace("-", "_");
|
|
539
|
+
return v && !v.id && v.type === w && (v.id = `${j}_${Math.random().toString().slice(2, 6)}`), v;
|
|
540
540
|
}
|
|
541
541
|
function n(f, w) {
|
|
542
|
-
const v = String(f.getAttribute("data-controltype")),
|
|
542
|
+
const v = String(f.getAttribute("data-controltype")), j = f.getAttribute("data-feature"), A = j ? JSON.parse(j) : {};
|
|
543
543
|
A.parentComponentInstance = g.value;
|
|
544
544
|
let E = M(v, A);
|
|
545
545
|
const N = v.toLowerCase().replace("-", "_");
|
|
@@ -552,7 +552,7 @@ function De(e, t, a) {
|
|
|
552
552
|
return g.value = {
|
|
553
553
|
canMove: p(),
|
|
554
554
|
canSelectParent: k(),
|
|
555
|
-
canDelete:
|
|
555
|
+
canDelete: i(),
|
|
556
556
|
canNested: !l(),
|
|
557
557
|
contents: t == null ? void 0 : t.schema.contents,
|
|
558
558
|
elementRef: e,
|
|
@@ -561,7 +561,7 @@ function De(e, t, a) {
|
|
|
561
561
|
styles: s,
|
|
562
562
|
designerClass: d,
|
|
563
563
|
canAccepts: b,
|
|
564
|
-
getBelongedComponentInstance:
|
|
564
|
+
getBelongedComponentInstance: r,
|
|
565
565
|
getDraggableDesignItemElement: u,
|
|
566
566
|
getDraggingDisplayText: y,
|
|
567
567
|
getPropConfig: D,
|
|
@@ -577,7 +577,7 @@ function De(e, t, a) {
|
|
|
577
577
|
}
|
|
578
578
|
const Be = /* @__PURE__ */ W({
|
|
579
579
|
name: "FDropdownDesign",
|
|
580
|
-
props:
|
|
580
|
+
props: V,
|
|
581
581
|
emits: ["select"],
|
|
582
582
|
setup(e, t) {
|
|
583
583
|
const a = S(e.model), {
|
|
@@ -587,16 +587,16 @@ const Be = /* @__PURE__ */ W({
|
|
|
587
587
|
leftButtonClick: g,
|
|
588
588
|
closeDropMenu: p,
|
|
589
589
|
selectItem: k,
|
|
590
|
-
resolveSize:
|
|
590
|
+
resolveSize: i
|
|
591
591
|
} = x(e, t);
|
|
592
592
|
function l(y) {
|
|
593
593
|
t.emit("select", y);
|
|
594
594
|
}
|
|
595
|
-
const
|
|
595
|
+
const r = S(), u = U("design-item-context"), b = De(r, u);
|
|
596
596
|
return _(() => {
|
|
597
|
-
|
|
597
|
+
r.value.componentInstance = b;
|
|
598
598
|
}), t.expose(b.value), () => m("div", {
|
|
599
|
-
ref:
|
|
599
|
+
ref: r
|
|
600
600
|
}, [m("div", {
|
|
601
601
|
class: ["farris-dropdown", "btn-group", {
|
|
602
602
|
dropup: e.position === "top"
|
|
@@ -662,9 +662,9 @@ const Be = /* @__PURE__ */ W({
|
|
|
662
662
|
onClick: s,
|
|
663
663
|
onMouseenter: d,
|
|
664
664
|
onMouseleave: d
|
|
665
|
-
}, [
|
|
665
|
+
}, [L(m("span", {
|
|
666
666
|
class: "sr-only"
|
|
667
|
-
}, null), [[z, e.splitButton]]), e.splitButton ? "" : e.title,
|
|
667
|
+
}, null), [[z, e.splitButton]]), e.splitButton ? "" : e.title, L(m("span", {
|
|
668
668
|
class: `f-icon ${e.iconClass.toString()}`
|
|
669
669
|
}, null), [[z, e.iconClass]])]), m("div", {
|
|
670
670
|
class: `dropdown-menu${o.value ? " show" : ""}`
|
|
@@ -697,6 +697,6 @@ const Be = /* @__PURE__ */ W({
|
|
|
697
697
|
export {
|
|
698
698
|
F as Dropdown,
|
|
699
699
|
$e as default,
|
|
700
|
-
|
|
700
|
+
V as dropdownProps,
|
|
701
701
|
X as propsResolver
|
|
702
702
|
};
|