Including network in safe route container as a prop
This commit is contained in:
parent
8c9971f19d
commit
9b80866992
|
@ -47,13 +47,19 @@ class SafeView extends React.PureComponent<Props> {
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const {
|
const {
|
||||||
safe, provider, activeTokens, granted, userAddress,
|
safe, provider, activeTokens, granted, userAddress, network,
|
||||||
} = this.props
|
} = this.props
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Page>
|
<Page>
|
||||||
{ granted
|
{ granted
|
||||||
? <Layout activeTokens={activeTokens} provider={provider} safe={safe} userAddress={userAddress} />
|
? <Layout
|
||||||
|
activeTokens={activeTokens}
|
||||||
|
provider={provider}
|
||||||
|
safe={safe}
|
||||||
|
userAddress={userAddress}
|
||||||
|
network={network}
|
||||||
|
/>
|
||||||
: <NoRights />
|
: <NoRights />
|
||||||
}
|
}
|
||||||
</Page>
|
</Page>
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
import { List } from 'immutable'
|
import { List } from 'immutable'
|
||||||
import { createSelector, createStructuredSelector, type Selector } from 'reselect'
|
import { createSelector, createStructuredSelector, type Selector } from 'reselect'
|
||||||
import { safeSelector, type RouterProps, type SafeSelectorProps } from '~/routes/safe/store/selectors'
|
import { safeSelector, type RouterProps, type SafeSelectorProps } from '~/routes/safe/store/selectors'
|
||||||
import { providerNameSelector, userAccountSelector } from '~/logic/wallets/store/selectors'
|
import { providerNameSelector, userAccountSelector, networkSelector } from '~/logic/wallets/store/selectors'
|
||||||
import { type Safe } from '~/routes/safe/store/model/safe'
|
import { type Safe } from '~/routes/safe/store/model/safe'
|
||||||
import { type Owner } from '~/routes/safe/store/model/owner'
|
import { type Owner } from '~/routes/safe/store/model/owner'
|
||||||
import { type GlobalState } from '~/store'
|
import { type GlobalState } from '~/store'
|
||||||
|
@ -15,6 +15,7 @@ export type SelectorProps = {
|
||||||
provider: string,
|
provider: string,
|
||||||
activeTokens: List<Token>,
|
activeTokens: List<Token>,
|
||||||
userAddress: string,
|
userAddress: string,
|
||||||
|
network: string,
|
||||||
}
|
}
|
||||||
|
|
||||||
export const grantedSelector: Selector<GlobalState, RouterProps, boolean> = createSelector(
|
export const grantedSelector: Selector<GlobalState, RouterProps, boolean> = createSelector(
|
||||||
|
@ -44,4 +45,5 @@ export default createStructuredSelector({
|
||||||
activeTokens: activeTokensSelector,
|
activeTokens: activeTokensSelector,
|
||||||
granted: grantedSelector,
|
granted: grantedSelector,
|
||||||
userAddress: userAccountSelector,
|
userAddress: userAccountSelector,
|
||||||
|
network: networkSelector,
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue