fix bug:搜索无法搜索分组、拖拽后右侧编辑器大小未自适应

This commit is contained in:
BillDowney
2021-07-08 20:39:09 +08:00
parent 134962be0d
commit ea2f53729e
3 changed files with 6 additions and 4 deletions

View File

@@ -106,7 +106,9 @@ export default {
folding: true,
lineDecorationsWidth: 35,
wordWrap: 'on',
theme: store.get('skin') || 'default'
theme: store.get('skin') || 'default',
// 自动调整大小
automaticLayout: true
})
this.editor.addAction({
id: 'editor.action.triggerSuggest.extension',
@@ -347,7 +349,7 @@ export default {
item.ext.loading = false;
})
}
this.layout()
// this.layout()
},
deleteWrapperProperties(obj){
delete obj.ext

View File

@@ -142,7 +142,7 @@ export default {
let loopSearch = (row, parentName, parentPath) => {
if (row.folder) {
row.children.forEach(it => loopSearch(it, parentName + '/' + (row.name || ''), parentPath + '/' + (row.path || '')))
row._searchShow = row.children.some(it => it._searchShow)
row._searchShow = (row.name || '').toLowerCase().indexOf(keyword) > -1 || row.children.some(it => it._searchShow)
} else {
row._searchShow = replaceURL(parentName + '/' + (row.name || '')).toLowerCase().indexOf(keyword) > -1 || replaceURL(parentPath + '/' + (row.path || '')).toLowerCase().indexOf(keyword) > -1
}

View File

@@ -141,7 +141,7 @@ export default {
let loopSearch = (row, parentName, parentPath) => {
if (row.folder) {
row.children.forEach(it => loopSearch(it, parentName + '/' + (row.name || ''), parentPath + '/' + (row.path || '')))
row._searchShow = row.children.some(it => it._searchShow)
row._searchShow = (row.name || '').toLowerCase().indexOf(keyword) > -1 || row.children.some(it => it._searchShow)
} else {
row._searchShow = replaceURL(parentName + '/' + (row.name || '')).toLowerCase().indexOf(keyword) > -1 || replaceURL(parentPath + '/' + (row.path || '')).toLowerCase().indexOf(keyword) > -1
}