修复评论列表显示问题

pull/930/merge
lyswhut 2022-03-11 10:10:01 +08:00
parent 09a5111e36
commit 081d6dc91e
1 changed files with 6 additions and 2 deletions

View File

@ -134,6 +134,10 @@ export default {
setWidth() {
setTimeout(() => {
this.$refs.dom_container.style.width = Math.floor(this.$refs.dom_container.parentNode.clientWidth * 0.5) + 'px'
setTimeout(() => {
this.handleToggleTab(this.tabActiveId, true)
})
})
},
async getComment(musicInfo, page, limit, retryNum = 0) {
@ -221,8 +225,8 @@ export default {
this.newComment.nextPage = page
this.handleGetNewComment(this.currentMusicInfo, page, this.newComment.limit)
},
handleToggleTab(id) {
if (this.tabActiveId == id) return
handleToggleTab(id, force) {
if (!force && this.tabActiveId == id) return
switch (id) {
case 'hot':
this.$refs.dom_tabMain.scrollLeft = 0