Skip to content

Commit

Permalink
Merge pull request #950 from dcloudio/fix-popup-android
Browse files Browse the repository at this point in the history
fix(popup):修复uni-popup在android上的重复点击弹出位置不正确的bug
  • Loading branch information
GRCmade authored Sep 9, 2024
2 parents 24aa6a2 + 7a40728 commit 087cdf7
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions uni_modules/uni-popup/components/uni-popup/uni-popup.vue
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,7 @@
this.showPopup = true
this.showTrans = true
this.$nextTick(() => {
this.showPoptrans()
if (this.messageChild && this.type === 'message') {
this.messageChild.timerClose()
}
Expand All @@ -372,8 +373,7 @@
}
// TODO 兼容 type 属性 ,后续会废弃
if (type) return
this.showPopup = true
this.showTrans = true
this.showPoptrans()
},
/**
* 中间弹出样式处理
Expand Down Expand Up @@ -403,8 +403,7 @@
}
// TODO 兼容 type 属性 ,后续会废弃
if (type) return
this.showPopup = true
this.showTrans = true
this.showPoptrans()
},
left(type) {
this.popupstyle = 'left'
Expand All @@ -423,8 +422,7 @@
}
// TODO 兼容 type 属性 ,后续会废弃
if (type) return
this.showPopup = true
this.showTrans = true
this.showPoptrans()
},
right(type) {
this.popupstyle = 'right'
Expand All @@ -443,8 +441,13 @@
}
// TODO 兼容 type 属性 ,后续会废弃
if (type) return
this.showPopup = true
this.showTrans = true
this.showPoptrans()
},
showPoptrans(){
this.$nextTick(()=>{
this.showPopup = true
this.showTrans = true
})
}
}
}
Expand Down

0 comments on commit 087cdf7

Please sign in to comment.