【类 型】:factor 刷新地图 加一个延迟执行
【原 因】:容器变化需要时间 在容器变宽 之后 再刷新地图 【过 程】: 【影 响】:
This commit is contained in:
parent
b072965257
commit
b3e41420f0
@ -562,7 +562,9 @@ export default {
|
||||
*/
|
||||
handleResize () {
|
||||
if (this.map) {
|
||||
this.map.resize()
|
||||
setTimeout(() => {
|
||||
this.map.resize()
|
||||
}, 300)
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -135,9 +135,7 @@ export default {
|
||||
isCollapse: {
|
||||
handler (val) {
|
||||
if (val) {
|
||||
setTimeout(() => {
|
||||
this.$refs.mapbox.handleResize()
|
||||
}, 500)
|
||||
this.$refs.mapbox.handleResize()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user