fix 限飞区 禁飞区 menu缩进按钮 检测 半秒后再刷新地图组件 防止刷新太早 容器还没有展开

This commit is contained in:
oldHome 2025-06-28 16:23:55 +08:00
parent 05361d6065
commit 5172beb985
2 changed files with 28 additions and 8 deletions

View File

@ -43,10 +43,20 @@ export default {
})
}
},
isCollapse (val) {
/**
* @description: 侧边栏缩进有变化时 地图重新自适应
*/
isCollapse: {
handler (val) {
if (val) {
setTimeout(() => {
this.$nextTick(() => {
this.$refs.mapbox.handleResize()
})
}, 500)
}
},
deep: true
}
}
}

View File

@ -43,10 +43,20 @@ export default {
})
}
},
isCollapse (val) {
/**
* @description: 侧边栏缩进有变化时 地图重新自适应
*/
isCollapse: {
handler (val) {
if (val) {
setTimeout(() => {
this.$nextTick(() => {
this.$refs.mapbox.handleResize()
})
}, 500)
}
},
deep: true
}
}
}