diff --git a/src/components/MessagesList/MessagesList.vue b/src/components/MessagesList/MessagesList.vue index 72d83edf57ab..6be674d21d22 100644 --- a/src/components/MessagesList/MessagesList.vue +++ b/src/components/MessagesList/MessagesList.vue @@ -442,36 +442,6 @@ export default { return moment.unix(message.timestamp) }, - scrollToFocussedMessage() { - let focussed = null - if (this.$route?.hash?.startsWith('#message_')) { - // scroll to message in URL anchor - focussed = this.focusMessage(this.$route.hash.slice(9), false) - } - - if (!focussed && this.visualLastReadMessageId) { - // scroll to last read message if visible in the current pages - focussed = this.focusMessage(this.visualLastReadMessageId, false, false) - } - - // TODO: in case the element is not in a page but does exist in the DB, - // we need to scroll up / down to the page where it would exist after - // loading said pages - - if (!focussed) { - // if no anchor was present or the message to focus on did not exist, - // scroll to bottom - this.scrollToBottom() - } - - // if no scrollbars, clear read marker directly as scrolling is not possible for the user to clear it - // also clear in case lastReadMessage is zero which is due to an older bug - if (this.visualLastReadMessageId === 0 || this.scroller.scrollHeight <= this.scroller.offsetHeight) { - // clear after a delay, unless scrolling can resume in-between - this.debounceUpdateReadMarkerPosition() - } - }, - async handleStartGettingMessagesPreconditions() { if (this.token && this.isParticipant && !this.isInLobby) {