海报模式重新加上resize事件

This commit is contained in:
buvta
2020-12-13 16:08:57 +08:00
parent b1b4e61244
commit 1e6a98df88
4 changed files with 14 additions and 4 deletions

View File

@@ -872,7 +872,11 @@ export default {
},
mounted () {
window.addEventListener('resize', () => {
setTimeout(() => { this.showTableLastColumn = window.outerWidth >= 1200 }, 100)
setTimeout(() => {
this.showTableLastColumn = window.outerWidth >= 1200
if (this.$refs.filmWaterfall) this.$refs.filmWaterfall.resize()
if (this.$refs.filmSearchWaterfall) this.$refs.filmSearchWaterfall.resize()
}, 100)
}, true)
}
}

View File

@@ -323,7 +323,9 @@ export default {
}
},
mounted () {
window.addEventListener('resize', () => { }, true)
window.addEventListener('resize', () => {
setTimeout(() => { if (this.$refs.historyWaterfall) this.$refs.historyWaterfall.resize() }, 100)
}, true)
},
created () {
this.getAllhistory()

View File

@@ -330,7 +330,9 @@ export default {
this.getRecommendations()
},
mounted () {
window.addEventListener('resize', () => { }, true)
window.addEventListener('resize', () => {
setTimeout(() => { if (this.$refs.recommendataionsWaterfall) this.$refs.recommendataionsWaterfall.resize() }, 100)
}, true)
}
}
</script>

View File

@@ -475,7 +475,9 @@ export default {
this.getFavorites()
},
mounted () {
window.addEventListener('resize', () => { }, true)
window.addEventListener('resize', () => {
setTimeout(() => { if (this.$refs.starWaterfall) this.$refs.starWaterfall.resize() }, 100)
}, true)
}
}
</script>