diff options
author | Chi Kei Chan <chikeichan@gmail.com> | 2019-02-27 02:30:41 +0800 |
---|---|---|
committer | Whymarrh Whitby <whymarrh.whitby@gmail.com> | 2019-02-27 02:30:41 +0800 |
commit | a2320c76fef084b7ec01839ab9c17b474839b3c0 (patch) | |
tree | 7620668c68c0de4e0de6ef745beb2cdc508ff50b /ui/app/components/transaction-view-balance/transaction-view-balance.container.js | |
parent | fc1655eecbf3da969dc9c9a8fc3ae95221ffa30b (diff) | |
download | tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar.gz tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar.bz2 tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar.lz tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar.xz tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.tar.zst tangerine-wallet-browser-a2320c76fef084b7ec01839ab9c17b474839b3c0.zip |
Show/Hide Fiat on Testnets based on User Preference (#6153)
Diffstat (limited to 'ui/app/components/transaction-view-balance/transaction-view-balance.container.js')
-rw-r--r-- | ui/app/components/transaction-view-balance/transaction-view-balance.container.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ui/app/components/transaction-view-balance/transaction-view-balance.container.js b/ui/app/components/transaction-view-balance/transaction-view-balance.container.js index 354db5ae1..df6d287eb 100644 --- a/ui/app/components/transaction-view-balance/transaction-view-balance.container.js +++ b/ui/app/components/transaction-view-balance/transaction-view-balance.container.js @@ -9,10 +9,14 @@ import { getSelectedTokenAssetImage, getMetaMaskAccounts, isBalanceCached, + preferencesSelector, + getIsMainnet, } from '../../selectors' import { showModal } from '../../actions' const mapStateToProps = state => { + const { showFiatInTestnets } = preferencesSelector(state) + const isMainnet = getIsMainnet(state) const selectedAddress = getSelectedAddress(state) const { metamask: { network } } = state const accounts = getMetaMaskAccounts(state) @@ -26,6 +30,7 @@ const mapStateToProps = state => { nativeCurrency: getNativeCurrency(state), assetImage: getSelectedTokenAssetImage(state), balanceIsCached: isBalanceCached(state), + showFiat: (isMainnet || !!showFiatInTestnets), } } |