mirror of
https://git.pleroma.social/sjw/pleroma-fe.git
synced 2025-01-30 01:10:19 +01:00
fix scrollerref not setting properly
This commit is contained in:
parent
8c4de692f4
commit
1c459028cc
@ -119,13 +119,15 @@ const Notifications = {
|
||||
},
|
||||
teleportTarget () {
|
||||
// handle scroller change
|
||||
this.scrollerRef.removeEventListener('scroll', this.updateScrollPosition)
|
||||
this.scrollerRef = this.$refs.root.closest('.column.-scrollable')
|
||||
if (!this.scrollerRef) {
|
||||
this.scrollerRef = this.$refs.root.closest('.mobile-notifications')
|
||||
}
|
||||
this.scrollerRef.addEventListener('scroll', this.updateScrollPosition)
|
||||
this.updateScrollPosition()
|
||||
this.$nextTick(() => {
|
||||
this.scrollerRef.removeEventListener('scroll', this.updateScrollPosition)
|
||||
this.scrollerRef = this.$refs.root.closest('.column.-scrollable')
|
||||
if (!this.scrollerRef) {
|
||||
this.scrollerRef = this.$refs.root.closest('.mobile-notifications')
|
||||
}
|
||||
this.scrollerRef.addEventListener('scroll', this.updateScrollPosition)
|
||||
this.updateScrollPosition()
|
||||
})
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
Loading…
x
Reference in New Issue
Block a user