Skip to content

Commit

Permalink
chat auto-scroll on new message issue
Browse files Browse the repository at this point in the history
  • Loading branch information
SebinSong committed Dec 17, 2024
1 parent 2223594 commit 5e12228
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions frontend/views/containers/chatroom/ChatMain.vue
Original file line number Diff line number Diff line change
Expand Up @@ -984,8 +984,7 @@ export default ({
if (addedOrDeleted === 'ADDED' && this.messages.length) {
const isScrollable = this.$refs.conversation &&
this.$refs.conversation.scrollHeight !== this.$refs.conversation.clientHeight
const fromOurselves = this.isMsgSender(this.messages[this.messages.length - 1].from)
if (!fromOurselves && isScrollable) {
if (isScrollable) {
this.updateScroll()
} else {
// If there are any temporary messages that do not exist in the
Expand Down

0 comments on commit 5e12228

Please sign in to comment.