mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-15 05:12:49 +00:00
perf: ipad 发送消息后出现页面跳动的情况
This commit is contained in:
parent
ed36d622ec
commit
e325698899
@ -951,23 +951,27 @@ export default {
|
||||
},
|
||||
|
||||
scrollIntoActive() {
|
||||
if (this.windowPortrait || this.windowScrollY > 0) {
|
||||
return;
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
if (this.windowLandscape && this.$refs.list) {
|
||||
const active = this.$refs.list.querySelector(".active")
|
||||
if (active) {
|
||||
$A.scrollIntoViewIfNeeded(active);
|
||||
} else {
|
||||
const dialog = this.cacheDialogs.find(({id}) => id == this.dialogId)
|
||||
if (dialog && this.dialogActive) {
|
||||
this.dialogActive = '';
|
||||
this.$nextTick(() => {
|
||||
const active = this.$refs.list.querySelector(".active")
|
||||
if (active) {
|
||||
$A.scrollIntoViewIfNeeded(active);
|
||||
}
|
||||
});
|
||||
if (!this.$refs.list) {
|
||||
return;
|
||||
}
|
||||
const active = this.$refs.list.querySelector(".active")
|
||||
if (active) {
|
||||
$A.scrollIntoViewIfNeeded(active);
|
||||
return;
|
||||
}
|
||||
const dialog = this.cacheDialogs.find(({id}) => id == this.dialogId)
|
||||
if (dialog && this.dialogActive) {
|
||||
this.dialogActive = '';
|
||||
this.$nextTick(() => {
|
||||
const active = this.$refs.list.querySelector(".active")
|
||||
if (active) {
|
||||
$A.scrollIntoViewIfNeeded(active);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user