lw-cdp-ui 1.2.13 → 1.2.15
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.
|
@@ -9,7 +9,8 @@
|
|
|
9
9
|
<template #item="{element: item, index}">
|
|
10
10
|
<el-col :span="['list'].includes(item.component) ? 24 : item.span || 24"
|
|
11
11
|
:class="{ borderItem: hideBorder, cur: hideBorder && curIndex == (item.name || item?.options?.items[0]?.name) }"
|
|
12
|
-
v-if="!hideHandle(item)"
|
|
12
|
+
v-if="!hideHandle(item)"
|
|
13
|
+
@click.capture="changeClick(item)">
|
|
13
14
|
<!-- 组合 -->
|
|
14
15
|
<template v-if="['object'].includes(item.component)">
|
|
15
16
|
<el-form-item :label="item.label"
|
|
@@ -73,8 +74,7 @@
|
|
|
73
74
|
</template>
|
|
74
75
|
<FormItem v-else
|
|
75
76
|
:item="item"
|
|
76
|
-
:form="form"
|
|
77
|
-
@click="changeClick(item)">
|
|
77
|
+
:form="form">
|
|
78
78
|
<!-- 没有组件是component值 就是插槽名称 -->
|
|
79
79
|
<template v-if="!['input', 'upload', 'checkbox', 'checkboxGroup', 'switch', 'select', 'treeSelect', 'cascader', 'date', 'number', 'radio', 'color', 'rate', 'slider','tags'].includes(item.component)"
|
|
80
80
|
v-slot:[item.component]>
|
|
@@ -177,8 +177,8 @@ export default {
|
|
|
177
177
|
display: flex;
|
|
178
178
|
flex-wrap: wrap;
|
|
179
179
|
// gap: 10px;
|
|
180
|
+
padding-bottom: 10px;
|
|
180
181
|
> div {
|
|
181
|
-
margin-bottom: 10px;
|
|
182
182
|
.title-name {
|
|
183
183
|
margin-top: 0;
|
|
184
184
|
}
|
|
@@ -269,6 +269,9 @@ export default {
|
|
|
269
269
|
}
|
|
270
270
|
:deep(.el-form-item) {
|
|
271
271
|
position: relative;
|
|
272
|
+
.el-form-item {
|
|
273
|
+
margin-bottom: 18px;
|
|
274
|
+
}
|
|
272
275
|
}
|
|
273
276
|
.add-btn {
|
|
274
277
|
top: 0px;
|
|
@@ -128,6 +128,7 @@ export default {
|
|
|
128
128
|
return {
|
|
129
129
|
form: {},
|
|
130
130
|
curItem: {},
|
|
131
|
+
menuList: [],
|
|
131
132
|
scrollObserverEnabled: true,
|
|
132
133
|
renderLoading: false,
|
|
133
134
|
activeNames: '布局组件'
|
|
@@ -151,6 +152,29 @@ export default {
|
|
|
151
152
|
immediate: true,
|
|
152
153
|
deep: true
|
|
153
154
|
},
|
|
155
|
+
custom: {
|
|
156
|
+
handler(val) {
|
|
157
|
+
this.menuList = []
|
|
158
|
+
if (val && val.length > 0) {
|
|
159
|
+
let menuIndex = MenuList.findIndex((item) => {
|
|
160
|
+
return item.title == '自定义组件'
|
|
161
|
+
})
|
|
162
|
+
|
|
163
|
+
if (menuIndex > -1) {
|
|
164
|
+
MenuList[menuIndex].list = val
|
|
165
|
+
} else {
|
|
166
|
+
let custom = {
|
|
167
|
+
title: '自定义组件',
|
|
168
|
+
list: val
|
|
169
|
+
}
|
|
170
|
+
MenuList.push(custom)
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
this.menuList = MenuList
|
|
174
|
+
},
|
|
175
|
+
immediate: true,
|
|
176
|
+
deep: true
|
|
177
|
+
},
|
|
154
178
|
},
|
|
155
179
|
computed: {
|
|
156
180
|
hasConfig() {
|
|
@@ -158,26 +182,6 @@ export default {
|
|
|
158
182
|
},
|
|
159
183
|
hasValue() {
|
|
160
184
|
return Object.keys(this.modelValue).length > 0
|
|
161
|
-
},
|
|
162
|
-
// 合并自定义组件
|
|
163
|
-
menuList() {
|
|
164
|
-
let custom = {}
|
|
165
|
-
if (this.custom && this.custom.length > 0) {
|
|
166
|
-
let menuIndex = MenuList.findIndex((item) => {
|
|
167
|
-
return item.title == '自定义组件'
|
|
168
|
-
})
|
|
169
|
-
|
|
170
|
-
if (menuIndex > -1) {
|
|
171
|
-
MenuList[menuIndex].list = this.custom
|
|
172
|
-
} else {
|
|
173
|
-
custom = {
|
|
174
|
-
title: '自定义组件',
|
|
175
|
-
list: this.custom
|
|
176
|
-
}
|
|
177
|
-
MenuList.push(custom)
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
return MenuList
|
|
181
185
|
}
|
|
182
186
|
},
|
|
183
187
|
mounted() {
|
package/dist/lw-cdp-ui.esm.js
CHANGED
|
@@ -8321,7 +8321,8 @@ function Yy(e, t, n, a, r, o) {
|
|
|
8321
8321
|
o.hideHandle(L) ? $("", !0) : (g(), I(h, {
|
|
8322
8322
|
key: 0,
|
|
8323
8323
|
span: ["list"].includes(L.component) ? 24 : L.span || 24,
|
|
8324
|
-
class: Me({ borderItem: n.hideBorder, cur: n.hideBorder && o.curIndex == (L.name || ((X = (Q = L == null ? void 0 : L.options) == null ? void 0 : Q.items[0]) == null ? void 0 : X.name)) })
|
|
8324
|
+
class: Me({ borderItem: n.hideBorder, cur: n.hideBorder && o.curIndex == (L.name || ((X = (Q = L == null ? void 0 : L.options) == null ? void 0 : Q.items[0]) == null ? void 0 : X.name)) }),
|
|
8325
|
+
onClickCapture: (J) => o.changeClick(L)
|
|
8325
8326
|
}, {
|
|
8326
8327
|
default: _(() => {
|
|
8327
8328
|
var J, H;
|
|
@@ -8419,8 +8420,7 @@ function Yy(e, t, n, a, r, o) {
|
|
|
8419
8420
|
}, 1032, ["onClickCapture"])) : (g(), I(w, {
|
|
8420
8421
|
key: 2,
|
|
8421
8422
|
item: L,
|
|
8422
|
-
form: n.form
|
|
8423
|
-
onClick: (ee) => o.changeClick(L)
|
|
8423
|
+
form: n.form
|
|
8424
8424
|
}, ot({ _: 2 }, [
|
|
8425
8425
|
["input", "upload", "checkbox", "checkboxGroup", "switch", "select", "treeSelect", "cascader", "date", "number", "radio", "color", "rate", "slider", "tags"].includes(L.component) ? void 0 : {
|
|
8426
8426
|
name: L.component,
|
|
@@ -8432,7 +8432,7 @@ function Yy(e, t, n, a, r, o) {
|
|
|
8432
8432
|
]),
|
|
8433
8433
|
key: "0"
|
|
8434
8434
|
}
|
|
8435
|
-
]), 1032, ["item", "form"
|
|
8435
|
+
]), 1032, ["item", "form"])),
|
|
8436
8436
|
n.hideBorder && o.curIndex == (L.name || ((H = (J = L == null ? void 0 : L.options) == null ? void 0 : J.items[0]) == null ? void 0 : H.name)) ? (g(), T("div", Gy, [
|
|
8437
8437
|
y(f, {
|
|
8438
8438
|
class: "btn",
|
|
@@ -8460,13 +8460,13 @@ function Yy(e, t, n, a, r, o) {
|
|
|
8460
8460
|
];
|
|
8461
8461
|
}),
|
|
8462
8462
|
_: 2
|
|
8463
|
-
}, 1032, ["span", "class"]))
|
|
8463
|
+
}, 1032, ["span", "class", "onClickCapture"]))
|
|
8464
8464
|
];
|
|
8465
8465
|
}),
|
|
8466
8466
|
_: 3
|
|
8467
8467
|
}, 8, ["list", "disabled", "class"]);
|
|
8468
8468
|
}
|
|
8469
|
-
const $y = /* @__PURE__ */ be(Ky, [["render", Yy], ["__scopeId", "data-v-
|
|
8469
|
+
const $y = /* @__PURE__ */ be(Ky, [["render", Yy], ["__scopeId", "data-v-fc71052f"]]), Wy = {
|
|
8470
8470
|
name: "TreeItem",
|
|
8471
8471
|
components: {
|
|
8472
8472
|
draggable: Tn
|
|
@@ -9791,6 +9791,7 @@ const v_ = /* @__PURE__ */ be(o_, [["render", g_], ["__scopeId", "data-v-ef9d371
|
|
|
9791
9791
|
return {
|
|
9792
9792
|
form: {},
|
|
9793
9793
|
curItem: {},
|
|
9794
|
+
menuList: [],
|
|
9794
9795
|
scrollObserverEnabled: !0,
|
|
9795
9796
|
renderLoading: !1,
|
|
9796
9797
|
activeNames: "布局组件"
|
|
@@ -9810,6 +9811,25 @@ const v_ = /* @__PURE__ */ be(o_, [["render", g_], ["__scopeId", "data-v-ef9d371
|
|
|
9810
9811
|
},
|
|
9811
9812
|
immediate: !0,
|
|
9812
9813
|
deep: !0
|
|
9814
|
+
},
|
|
9815
|
+
custom: {
|
|
9816
|
+
handler(e) {
|
|
9817
|
+
if (this.menuList = [], e && e.length > 0) {
|
|
9818
|
+
let t = gn.findIndex((n) => n.title == "自定义组件");
|
|
9819
|
+
if (t > -1)
|
|
9820
|
+
gn[t].list = e;
|
|
9821
|
+
else {
|
|
9822
|
+
let n = {
|
|
9823
|
+
title: "自定义组件",
|
|
9824
|
+
list: e
|
|
9825
|
+
};
|
|
9826
|
+
gn.push(n);
|
|
9827
|
+
}
|
|
9828
|
+
}
|
|
9829
|
+
this.menuList = gn;
|
|
9830
|
+
},
|
|
9831
|
+
immediate: !0,
|
|
9832
|
+
deep: !0
|
|
9813
9833
|
}
|
|
9814
9834
|
},
|
|
9815
9835
|
computed: {
|
|
@@ -9818,18 +9838,6 @@ const v_ = /* @__PURE__ */ be(o_, [["render", g_], ["__scopeId", "data-v-ef9d371
|
|
|
9818
9838
|
},
|
|
9819
9839
|
hasValue() {
|
|
9820
9840
|
return Object.keys(this.modelValue).length > 0;
|
|
9821
|
-
},
|
|
9822
|
-
// 合并自定义组件
|
|
9823
|
-
menuList() {
|
|
9824
|
-
let e = {};
|
|
9825
|
-
if (this.custom && this.custom.length > 0) {
|
|
9826
|
-
let t = gn.findIndex((n) => n.title == "自定义组件");
|
|
9827
|
-
t > -1 ? gn[t].list = this.custom : (e = {
|
|
9828
|
-
title: "自定义组件",
|
|
9829
|
-
list: this.custom
|
|
9830
|
-
}, gn.push(e));
|
|
9831
|
-
}
|
|
9832
|
-
return gn;
|
|
9833
9841
|
}
|
|
9834
9842
|
},
|
|
9835
9843
|
mounted() {
|
|
@@ -9920,7 +9928,7 @@ function w_(e, t, n, a, r, o) {
|
|
|
9920
9928
|
"onUpdate:modelValue": t[0] || (t[0] = (B) => r.activeNames = B)
|
|
9921
9929
|
}, {
|
|
9922
9930
|
default: _(() => [
|
|
9923
|
-
(g(!0), T(j, null, re(
|
|
9931
|
+
(g(!0), T(j, null, re(r.menuList, (B) => (g(), I(i, {
|
|
9924
9932
|
title: B.title,
|
|
9925
9933
|
name: B.title,
|
|
9926
9934
|
class: "menu-list-title"
|
|
@@ -10012,7 +10020,7 @@ function w_(e, t, n, a, r, o) {
|
|
|
10012
10020
|
_: 3
|
|
10013
10021
|
}, 8, ["style"]);
|
|
10014
10022
|
}
|
|
10015
|
-
const k_ = /* @__PURE__ */ be(b_, [["render", w_], ["__scopeId", "data-v-
|
|
10023
|
+
const k_ = /* @__PURE__ */ be(b_, [["render", w_], ["__scopeId", "data-v-65cb0380"]]), S_ = {
|
|
10016
10024
|
props: {
|
|
10017
10025
|
modelValue: { type: String, default: "" },
|
|
10018
10026
|
// 传入的字符串
|
|
@@ -18347,6 +18355,7 @@ function _V(e, t, n, a, r, o) {
|
|
|
18347
18355
|
title: "节点编辑",
|
|
18348
18356
|
direction: "rtl",
|
|
18349
18357
|
"append-to-body": !0,
|
|
18358
|
+
size: 600,
|
|
18350
18359
|
"before-close": o.close
|
|
18351
18360
|
}, {
|
|
18352
18361
|
footer: _(() => [
|
|
@@ -18440,7 +18449,7 @@ function _V(e, t, n, a, r, o) {
|
|
|
18440
18449
|
_: 1
|
|
18441
18450
|
}, 8, ["modelValue", "before-close"]);
|
|
18442
18451
|
}
|
|
18443
|
-
const wV = /* @__PURE__ */ be(bV, [["render", _V], ["__scopeId", "data-v-
|
|
18452
|
+
const wV = /* @__PURE__ */ be(bV, [["render", _V], ["__scopeId", "data-v-5aff8d01"]]), jh = [
|
|
18444
18453
|
{
|
|
18445
18454
|
title: "ET2L节点",
|
|
18446
18455
|
list: [
|