Updated StatusList, ScrollableList to use given props
• Updated: - StatusList, ScrollableList to use given props • Fixed: - Issue with scrolling back to top onLoadMore
This commit is contained in:
@@ -87,7 +87,6 @@ class AccountTimeline extends ImmutablePureComponent {
|
||||
statusIds={statusIds}
|
||||
featuredStatusIds={featuredStatusIds}
|
||||
isLoading={isLoading}
|
||||
showLoading={isLoading}
|
||||
hasMore={hasMore}
|
||||
onLoadMore={this.handleLoadMore}
|
||||
emptyMessage={intl.formatMessage(messages.empty)}
|
||||
|
||||
@@ -34,7 +34,6 @@ class GroupTimeline extends ImmutablePureComponent {
|
||||
static propTypes = {
|
||||
params: PropTypes.object.isRequired,
|
||||
dispatch: PropTypes.func.isRequired,
|
||||
columnId: PropTypes.string,
|
||||
hasUnread: PropTypes.bool,
|
||||
group: PropTypes.oneOfType([
|
||||
ImmutablePropTypes.map,
|
||||
@@ -77,7 +76,7 @@ class GroupTimeline extends ImmutablePureComponent {
|
||||
}
|
||||
|
||||
render() {
|
||||
const { columnId, group, relationships, account, intl } = this.props
|
||||
const { group, relationships, account, intl } = this.props
|
||||
const { collapsed } = this.state
|
||||
const { id } = this.props.params
|
||||
|
||||
@@ -90,7 +89,7 @@ class GroupTimeline extends ImmutablePureComponent {
|
||||
return (
|
||||
<StatusList
|
||||
alwaysPrepend
|
||||
scrollKey={`group_timeline-${columnId}`}
|
||||
scrollKey={`group_timeline-${id}`}
|
||||
timelineId={`group:${id}`}
|
||||
onLoadMore={this.handleLoadMore}
|
||||
group={group}
|
||||
|
||||
@@ -38,9 +38,7 @@ class Shortcuts extends ImmutablePureComponent {
|
||||
shortcuts,
|
||||
} = this.props
|
||||
|
||||
if (isLoading) {
|
||||
return <ColumnIndicator type='loading' />
|
||||
} else if (isError) {
|
||||
if (isError) {
|
||||
return <ColumnIndicator type='error' message='Error fetching shortcuts' />
|
||||
}
|
||||
|
||||
@@ -55,6 +53,7 @@ class Shortcuts extends ImmutablePureComponent {
|
||||
scrollKey='shortcuts'
|
||||
emptyMessage='You have no shortcuts'
|
||||
items={listItems}
|
||||
showLoading={isLoading}
|
||||
/>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user