Removed onReload and pull to refresh from StatusList, ScrollableList
• Removed: - onReload and pull to refresh from StatusList, ScrollableList
This commit is contained in:
parent
b6f7321c23
commit
880dad7b5a
@ -17,7 +17,6 @@ class ScrollableList extends React.PureComponent {
|
||||
}
|
||||
|
||||
state = {
|
||||
pullToRefreshTriggered: false,
|
||||
cachedMediaWidth: 250, // Default media/card width using default Gab Social theme
|
||||
}
|
||||
|
||||
@ -99,13 +98,6 @@ class ScrollableList extends React.PureComponent {
|
||||
const { innerHeight } = this.window;
|
||||
const offset = scrollHeight - scrollTop - innerHeight;
|
||||
|
||||
if (scrollTop < -80 && this.props.onReload && !this.state.pullToRefreshTriggered) {
|
||||
this.setState({ pullToRefreshTriggered: true })
|
||||
} else if (scrollTop > -10 && this.props.onReload && this.state.pullToRefreshTriggered) {
|
||||
this.props.onReload()
|
||||
this.setState({ pullToRefreshTriggered: false })
|
||||
}
|
||||
|
||||
if (600 > offset && this.props.onLoadMore && this.props.hasMore && !this.props.isLoading) {
|
||||
this.props.onLoadMore();
|
||||
}
|
||||
@ -267,7 +259,6 @@ class ScrollableList extends React.PureComponent {
|
||||
ScrollableList.propTypes = {
|
||||
scrollKey: PropTypes.string.isRequired,
|
||||
onLoadMore: PropTypes.func,
|
||||
onReload: PropTypes.func,
|
||||
isLoading: PropTypes.bool,
|
||||
showLoading: PropTypes.bool,
|
||||
hasMore: PropTypes.bool,
|
||||
|
@ -284,7 +284,6 @@ class StatusList extends ImmutablePureComponent {
|
||||
isLoading={isLoading}
|
||||
showLoading={(isLoading && statusIds.size === 0)}
|
||||
onLoadMore={onLoadMore && this.handleLoadOlder}
|
||||
onReload={this.handleOnReload}
|
||||
placeholderComponent={StatusPlaceholder}
|
||||
placeholderCount={1}
|
||||
scrollKey={scrollKey}
|
||||
|
Loading…
Reference in New Issue
Block a user