Skip to content

Commit b3e3d0e

Browse files
committed
feat(neuron-ui): hide the general settings and redirect to wallets setting
1 parent b5d4b35 commit b3e3d0e

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

packages/neuron-ui/src/components/Settings/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { WalletWizardPath } from 'components/WalletWizard'
1313
import { Routes } from 'utils/const'
1414

1515
const pivotItems = [
16-
{ label: 'settings.setting-tabs.general', url: Routes.SettingsGeneral },
16+
// { label: 'settings.setting-tabs.general', url: Routes.SettingsGeneral },
1717
{ label: 'settings.setting-tabs.wallets', url: Routes.SettingsWallets },
1818
{ label: 'settings.setting-tabs.network', url: Routes.SettingsNetworks },
1919
]

packages/neuron-ui/src/containers/Main/index.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import React, { useMemo } from 'react'
2-
import { Route, RouteComponentProps } from 'react-router-dom'
2+
import { Route, RouteComponentProps, Switch, Redirect } from 'react-router-dom'
33
import { useTranslation } from 'react-i18next'
44

55
import { useState } from 'states/stateProvider'
@@ -157,7 +157,8 @@ const MainContent = ({
157157
})
158158

159159
return (
160-
<>
160+
<Switch>
161+
<Redirect from={Routes.SettingsGeneral} to={Routes.SettingsWallets} />
161162
{mainContents.map(container => (
162163
<Route
163164
exact={container.exact}
@@ -168,7 +169,7 @@ const MainContent = ({
168169
}}
169170
/>
170171
))}
171-
</>
172+
</Switch>
172173
)
173174
}
174175

0 commit comments

Comments
 (0)