Swap tabs in help section
We decided to make the Knowledge Base tab the default one since it contains the information which are easiest to understand for an user. [MAILPOET-1457]
This commit is contained in:
@@ -21,11 +21,11 @@ if (container) {
|
||||
ReactDOM.render((
|
||||
<Router history={history}>
|
||||
<Route path="/" component={App}>
|
||||
<IndexRedirect to="systemStatus" />
|
||||
<IndexRedirect to="knowledgeBase" />
|
||||
{/* Pages */}
|
||||
<Route path="knowledgeBase(/)**" params={{ tab: 'knowledgeBase' }} component={KnowledgeBase} />
|
||||
<Route path="systemStatus(/)**" params={{ tab: 'systemStatus' }} component={SystemStatus} />
|
||||
<Route path="systemInfo(/)**" params={{ tab: 'systemInfo' }} component={SystemInfo} />
|
||||
<Route path="knowledgeBase(/)**" params={{ tab: 'knowledgeBase' }} component={KnowledgeBase} />
|
||||
</Route>
|
||||
</Router>
|
||||
), container);
|
||||
|
@@ -4,6 +4,11 @@ import classNames from 'classnames';
|
||||
import MailPoet from 'mailpoet';
|
||||
|
||||
const tabs = [
|
||||
{
|
||||
name: 'knowledgeBase',
|
||||
label: MailPoet.I18n.t('tabKnowledgeBaseTitle'),
|
||||
link: '/knowledgeBase',
|
||||
},
|
||||
{
|
||||
name: 'systemStatus',
|
||||
label: MailPoet.I18n.t('tabSystemStatusTitle'),
|
||||
@@ -14,11 +19,6 @@ const tabs = [
|
||||
label: MailPoet.I18n.t('tabSystemInfoTitle'),
|
||||
link: '/systemInfo',
|
||||
},
|
||||
{
|
||||
name: 'knowledgeBase',
|
||||
label: MailPoet.I18n.t('tabKnowledgeBaseTitle'),
|
||||
link: '/knowledgeBase',
|
||||
},
|
||||
];
|
||||
|
||||
function Tabs(props) {
|
||||
@@ -45,6 +45,6 @@ function Tabs(props) {
|
||||
}
|
||||
|
||||
Tabs.propTypes = { tab: React.PropTypes.string };
|
||||
Tabs.defaultProps = { tab: 'systemStatus' };
|
||||
Tabs.defaultProps = { tab: 'knowledgeBase' };
|
||||
|
||||
module.exports = Tabs;
|
||||
|
Reference in New Issue
Block a user