perf: 优化消息流效果

This commit is contained in:
kuaifan 2025-03-18 11:38:58 +08:00
parent da7c1e40e3
commit 0eb3430c14

View File

@ -1977,6 +1977,7 @@ export default {
msg.text = text
}
const curText = msg.text
this.$nextTick(_ => {
if (tail <= 10 && tail != this.scrollInfo().tail) {
this.operatePreventScroll++
@ -1990,7 +1991,7 @@ export default {
}
setTimeout(_ => {
this.msgChangeCache[load] = false
this.onMsgOutput(id, msg)
curText === msg.text && this.onMsgOutput(id, msg)
}, 5)
})
} catch (e) {