Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/controllers/Lane.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ class Lane extends Component {
const elemScrollPosition = node.scrollHeight - node.scrollTop - node.clientHeight
const {onLaneScroll} = this.props
// In some browsers and/or screen sizes a decimal rest value between 0 and 1 exists, so it should be checked on < 1 instead of < 0
if (elemScrollPosition < 1 && onLaneScroll && !this.state.loading) {
// However, in come cases `elemScrollPosition` is never smaller than 1 and infinite scrolling ended too soon. Then we use some bigger value to compare
if (elemScrollPosition < 15 && onLaneScroll && !this.state.loading) {
const {currentPage} = this.state
this.setState({loading: true})
const nextPage = currentPage + 1
Expand Down