Make clicking on the account and status column headers scroll to top
This commit is contained in:
@ -57,10 +57,18 @@ export default class AccountTimeline extends ImmutablePureComponent {
|
||||
}
|
||||
}
|
||||
|
||||
handleHeaderClick = () => {
|
||||
this.column.scrollTop();
|
||||
}
|
||||
|
||||
handleLoadMore = maxId => {
|
||||
this.props.dispatch(expandAccountTimeline(this.props.params.accountId, { maxId, withReplies: this.props.withReplies }));
|
||||
}
|
||||
|
||||
setRef = c => {
|
||||
this.column = c;
|
||||
}
|
||||
|
||||
render () {
|
||||
const { statusIds, featuredStatusIds, isLoading, hasMore } = this.props;
|
||||
|
||||
@ -73,8 +81,8 @@ export default class AccountTimeline extends ImmutablePureComponent {
|
||||
}
|
||||
|
||||
return (
|
||||
<Column name='account'>
|
||||
<ProfileColumnHeader />
|
||||
<Column ref={this.setRef} name='account'>
|
||||
<ProfileColumnHeader onClick={this.handleHeaderClick} />
|
||||
|
||||
<StatusList
|
||||
prepend={<HeaderContainer accountId={this.props.params.accountId} />}
|
||||
|
Reference in New Issue
Block a user