vue2-client 1.9.22 → 1.9.23
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/package.json
CHANGED
|
@@ -52,6 +52,7 @@
|
|
|
52
52
|
@check-change="handleCheckChange"
|
|
53
53
|
:default-expanded-keys="expandedKeys"
|
|
54
54
|
@node-expand="nodeExpand"
|
|
55
|
+
@node-collapse="nodeCollapse"
|
|
55
56
|
@node-click="handleNodeClick"
|
|
56
57
|
:filter-node-method="filterNode"
|
|
57
58
|
:props="props"
|
|
@@ -207,6 +208,7 @@ export default {
|
|
|
207
208
|
}
|
|
208
209
|
},
|
|
209
210
|
methods: {
|
|
211
|
+
// 节点展开暂存
|
|
210
212
|
nodeExpand (node) {
|
|
211
213
|
if (this.expandedKeys.includes(node[this.replaceFields.key])) {
|
|
212
214
|
this.expandedKeys = this.expandedKeys.filter(item => item !== node[this.replaceFields.key])
|
|
@@ -214,6 +216,10 @@ export default {
|
|
|
214
216
|
this.expandedKeys.push(node[this.replaceFields.key])
|
|
215
217
|
}
|
|
216
218
|
},
|
|
219
|
+
// 节点关闭
|
|
220
|
+
nodeCollapse (node) {
|
|
221
|
+
this.expandedKeys = this.expandedKeys.filter(item => item !== node[this.replaceFields.key])
|
|
222
|
+
},
|
|
217
223
|
highlightKeyword (label, keyword) {
|
|
218
224
|
const maxLen = this.config.deepNodeMaxWidth
|
|
219
225
|
|