bottomedOut/loadOlder resets
This commit is contained in:
parent
590ca6fb6f
commit
725b2f5387
2 changed files with 10 additions and 1 deletions
|
|
@ -52,7 +52,11 @@ const timelineFetcher = (timeline, argument, credentials) => {
|
|||
|
||||
const numStatusesBeforeFetch = timeline.statusIds.size
|
||||
|
||||
if (older && bottomedOut.value) return
|
||||
if (older && bottomedOut.value) {
|
||||
loadingOlder.value = false
|
||||
return
|
||||
}
|
||||
|
||||
return fetchTimeline(args)
|
||||
.then(({ data, pagination, timestamp }) => {
|
||||
// No statuses for timeline, ever.
|
||||
|
|
@ -135,6 +139,9 @@ const timelineFetcher = (timeline, argument, credentials) => {
|
|||
loadingOlder,
|
||||
loadingNewer,
|
||||
bottomedOut,
|
||||
resetBottomedOut: () => {
|
||||
bottomedOut.value = false
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -196,6 +196,7 @@ export const useTimelinesStore = defineStore('timelines', {
|
|||
timeline.maxId = ''
|
||||
timeline.minId = ''
|
||||
timeline.reloadNeeded = false
|
||||
timeline.fetcher.resetBottomedOut()
|
||||
},
|
||||
activatePersistents() {
|
||||
TIMELINES.forEach((name) => {
|
||||
|
|
@ -443,6 +444,7 @@ export const useTimelinesStore = defineStore('timelines', {
|
|||
...timeline.order.filter((id) => !timeline.ignoredIds.has(id)),
|
||||
])
|
||||
this.updateTimelineExtremes(timeline, {}, true)
|
||||
timeline.fetcher.resetBottomedOut()
|
||||
},
|
||||
syncOrder(timeline) {
|
||||
timeline.order = timeline.order.filter((id) => timeline.statusIds.has(id))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue