Reload Favourites from reload button
This commit is contained in:
parent
83f432c643
commit
657675eb5d
|
@ -22,7 +22,8 @@ export default {
|
|||
account: state => state.TimelineSpace.account,
|
||||
favourites: state => state.TimelineSpace.Contents.Favourites.favourites,
|
||||
lazyLoading: state => state.TimelineSpace.Contents.Favourites.lazyLoading,
|
||||
backgroundColor: state => state.App.theme.background_color
|
||||
backgroundColor: state => state.App.theme.background_color,
|
||||
startReload: state => state.TimelineSpace.HeaderMenu.reload
|
||||
})
|
||||
},
|
||||
created () {
|
||||
|
@ -54,6 +55,16 @@ export default {
|
|||
document.getElementById('scrollable').scrollTop = 0
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
startReload: function (newState, oldState) {
|
||||
if (!oldState && newState) {
|
||||
this.reload()
|
||||
.finally(() => {
|
||||
this.$store.commit('TimelineSpace/HeaderMenu/changeReload', false)
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
updateToot (message) {
|
||||
this.$store.commit('TimelineSpace/Contents/Favourites/updateToot', message)
|
||||
|
|
Loading…
Reference in New Issue