diff options
Diffstat (limited to 'app/javascript/mastodon/features/hashtag_timeline')
-rw-r--r-- | app/javascript/mastodon/features/hashtag_timeline/index.js | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/app/javascript/mastodon/features/hashtag_timeline/index.js b/app/javascript/mastodon/features/hashtag_timeline/index.js index 05e6d1996..ba6dbe6e5 100644 --- a/app/javascript/mastodon/features/hashtag_timeline/index.js +++ b/app/javascript/mastodon/features/hashtag_timeline/index.js @@ -5,7 +5,8 @@ import StatusListContainer from '../ui/containers/status_list_container'; import Column from '../../components/column'; import ColumnHeader from '../../components/column_header'; import { - refreshTimeline, + refreshHashtagTimeline, + expandHashtagTimeline, updateTimeline, deleteFromTimelines, } from '../../actions/timelines'; @@ -81,13 +82,13 @@ class HashtagTimeline extends React.PureComponent { const { dispatch } = this.props; const { id } = this.props.params; - dispatch(refreshTimeline('tag', id)); + dispatch(refreshHashtagTimeline(id)); this._subscribe(dispatch, id); } componentWillReceiveProps (nextProps) { if (nextProps.params.id !== this.props.params.id) { - this.props.dispatch(refreshTimeline('tag', nextProps.params.id)); + this.props.dispatch(refreshHashtagTimeline(nextProps.params.id)); this._unsubscribe(); this._subscribe(this.props.dispatch, nextProps.params.id); } @@ -101,6 +102,10 @@ class HashtagTimeline extends React.PureComponent { this.column = c; } + handleLoadMore = () => { + this.props.dispatch(expandHashtagTimeline(this.props.params.id)); + } + render () { const { hasUnread, columnId, multiColumn } = this.props; const { id } = this.props.params; @@ -123,8 +128,8 @@ class HashtagTimeline extends React.PureComponent { <StatusListContainer trackScroll={!pinned} scrollKey={`hashtag_timeline-${columnId}`} - type='tag' - id={id} + timelineId={`hashtag:${id}`} + loadMore={this.handleLoadMore} emptyMessage={<FormattedMessage id='empty_column.hashtag' defaultMessage='There is nothing in this hashtag yet.' />} /> </Column> |