gearheads
/
mastodon
Archived
2
0
Fork 0

Fix auto-loading-more when not scrolled (#27286)

gh/dev^2
Claire 2023-10-05 16:33:54 +02:00
parent 88fc73dbbc
commit b9b8eafc98
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ class ScrollableList extends PureComponent {
const clientHeight = this.getClientHeight();
const offset = scrollHeight - scrollTop - clientHeight;
if (400 > offset && this.props.onLoadMore && this.props.hasMore && !this.props.isLoading) {
if (scrollTop > 0 && offset < 400 && this.props.onLoadMore && this.props.hasMore && !this.props.isLoading) {
this.props.onLoadMore();
}