Remove navigation links to /explore when trends are disabled (#19415)
* Remove navigation links to /explore when trends are disabled * Do not display trends interface when trends are disabled
This commit is contained in:
parent
0ca29eaa3f
commit
267978d4fe
3 changed files with 19 additions and 4 deletions
|
@ -12,6 +12,7 @@ import Suggestions from './suggestions';
|
|||
import Search from 'mastodon/features/compose/containers/search_container';
|
||||
import SearchResults from './results';
|
||||
import { Helmet } from 'react-helmet';
|
||||
import { showTrends } from 'mastodon/initial_state';
|
||||
|
||||
const messages = defineMessages({
|
||||
title: { id: 'explore.title', defaultMessage: 'Explore' },
|
||||
|
@ -20,7 +21,7 @@ const messages = defineMessages({
|
|||
|
||||
const mapStateToProps = state => ({
|
||||
layout: state.getIn(['meta', 'layout']),
|
||||
isSearching: state.getIn(['search', 'submitted']),
|
||||
isSearching: state.getIn(['search', 'submitted']) || !showTrends,
|
||||
});
|
||||
|
||||
export default @connect(mapStateToProps)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue