Change featured hashtags to be displayed in navigation panel (#19382)
This commit is contained in:
30
app/javascript/mastodon/components/navigation_portal.js
Normal file
30
app/javascript/mastodon/components/navigation_portal.js
Normal file
@@ -0,0 +1,30 @@
|
||||
import React from 'react';
|
||||
import { Switch, Route, withRouter } from 'react-router-dom';
|
||||
import { showTrends } from 'mastodon/initial_state';
|
||||
import Trends from 'mastodon/features/getting_started/containers/trends_container';
|
||||
import AccountNavigation from 'mastodon/features/account/navigation';
|
||||
|
||||
const DefaultNavigation = () => (
|
||||
<>
|
||||
{showTrends && (
|
||||
<>
|
||||
<div className='flex-spacer' />
|
||||
<Trends />
|
||||
</>
|
||||
)}
|
||||
</>
|
||||
);
|
||||
|
||||
export default @withRouter
|
||||
class NavigationPortal extends React.PureComponent {
|
||||
|
||||
render () {
|
||||
return (
|
||||
<Switch>
|
||||
<Route path='/@:acct/(tagged/:tagged?)?' component={AccountNavigation} />
|
||||
<Route component={DefaultNavigation} />
|
||||
</Switch>
|
||||
);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user