diff options
author | Yamagishi Kazutoshi <ykzts@desire.sh> | 2018-07-29 23:52:06 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2018-07-29 16:52:06 +0200 |
commit | 06c83527f5e4b7c8460f7d4a62322d2b8e805056 (patch) | |
tree | 4f78cae7f5954993299c84996eb314152d9a3abe /app/javascript/mastodon/features/home_timeline/index.js | |
parent | 0a3cc246acca9645d5d41a25d73f510ff67af6f6 (diff) |
Do not scroll up when modal is opened (#8095)
Diffstat (limited to 'app/javascript/mastodon/features/home_timeline/index.js')
-rw-r--r-- | app/javascript/mastodon/features/home_timeline/index.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/javascript/mastodon/features/home_timeline/index.js b/app/javascript/mastodon/features/home_timeline/index.js index db6bbdec1..4e6853c5b 100644 --- a/app/javascript/mastodon/features/home_timeline/index.js +++ b/app/javascript/mastodon/features/home_timeline/index.js @@ -25,6 +25,7 @@ export default class HomeTimeline extends React.PureComponent { static propTypes = { dispatch: PropTypes.func.isRequired, + shouldUpdateScroll: PropTypes.func, intl: PropTypes.object.isRequired, hasUnread: PropTypes.bool, isPartial: PropTypes.bool, @@ -93,7 +94,7 @@ export default class HomeTimeline extends React.PureComponent { } render () { - const { intl, hasUnread, columnId, multiColumn } = this.props; + const { intl, shouldUpdateScroll, hasUnread, columnId, multiColumn } = this.props; const pinned = !!columnId; return ( @@ -117,6 +118,7 @@ export default class HomeTimeline extends React.PureComponent { onLoadMore={this.handleLoadMore} timelineId='home' emptyMessage={<FormattedMessage id='empty_column.home' defaultMessage='Your home timeline is empty! Visit {public} or use search to get started and meet other users.' values={{ public: <Link to='/timelines/public'><FormattedMessage id='empty_column.home.public_timeline' defaultMessage='the public timeline' /></Link> }} />} + shouldUpdateScroll={shouldUpdateScroll} /> </Column> ); |