Improve thread loading (#4402)
* Increase the number of posts loaded when a self-thread is present * Increase depth to 10, detect cutoffs on self-threads and show continue link * Stacky the avis
This commit is contained in:
@@ -34,6 +34,7 @@ import {ComposePrompt} from '../composer/Prompt'
|
||||
import {List, ListMethods} from '../util/List'
|
||||
import {ViewHeader} from '../util/ViewHeader'
|
||||
import {PostThreadItem} from './PostThreadItem'
|
||||
import {PostThreadLoadMore} from './PostThreadLoadMore'
|
||||
import {PostThreadShowHiddenReplies} from './PostThreadShowHiddenReplies'
|
||||
|
||||
// FlatList maintainVisibleContentPosition breaks if too many items
|
||||
@@ -364,6 +365,9 @@ export function PostThread({
|
||||
</View>
|
||||
)
|
||||
} else if (isThreadPost(item)) {
|
||||
if (!treeView && item.ctx.hasMoreSelfThread) {
|
||||
return <PostThreadLoadMore post={item.post} />
|
||||
}
|
||||
const prev = isThreadPost(posts[index - 1])
|
||||
? (posts[index - 1] as ThreadPost)
|
||||
: undefined
|
||||
|
||||
Reference in New Issue
Block a user