mirror of
https://github.com/nkanaev/yarr.git
synced 2025-12-23 11:44:04 +00:00
reset article list right after filter/feed is selected
This commit is contained in:
@@ -361,14 +361,18 @@ var vm = new Vue({
|
||||
},
|
||||
'filterSelected': function(newVal, oldVal) {
|
||||
if (oldVal === undefined) return // do nothing, initial setup
|
||||
api.settings.update({filter: newVal}).then(this.refreshItems.bind(this, false))
|
||||
this.itemSelected = null
|
||||
this.items = []
|
||||
this.itemsHasMore = true
|
||||
api.settings.update({filter: newVal}).then(this.refreshItems.bind(this, false))
|
||||
this.computeStats()
|
||||
},
|
||||
'feedSelected': function(newVal, oldVal) {
|
||||
if (oldVal === undefined) return // do nothing, initial setup
|
||||
api.settings.update({feed: newVal}).then(this.refreshItems.bind(this, false))
|
||||
this.itemSelected = null
|
||||
this.items = []
|
||||
this.itemsHasMore = true
|
||||
api.settings.update({feed: newVal}).then(this.refreshItems.bind(this, false))
|
||||
if (this.$refs.itemlist) this.$refs.itemlist.scrollTop = 0
|
||||
},
|
||||
'itemSelected': function(newVal, oldVal) {
|
||||
|
||||
Reference in New Issue
Block a user