Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: address book + new send flow #1239

Merged
merged 160 commits into from
Jan 22, 2020
Merged
Show file tree
Hide file tree
Changes from 125 commits
Commits
Show all changes
160 commits
Select commit Hold shift + click to select a range
4446993
basic components
estebanmino Nov 19, 2019
42ec6d9
basic components
estebanmino Nov 19, 2019
e196ac9
updates
estebanmino Nov 20, 2019
2dbd37e
wip
estebanmino Nov 20, 2019
6a96323
between my accounts
estebanmino Nov 20, 2019
ba2c317
basic add contact
estebanmino Nov 21, 2019
f1448f5
render list
estebanmino Nov 21, 2019
8824c1e
inputs func components
estebanmino Nov 22, 2019
96e9ff1
handle from selection
estebanmino Nov 22, 2019
6a011d6
from identicon
estebanmino Nov 22, 2019
ccc9fb0
onchangetoaddress
estebanmino Nov 22, 2019
59cebc9
add to address book modal
estebanmino Nov 22, 2019
a7a3a1e
add from modal and parse asdress book
estebanmino Nov 22, 2019
b97707f
scan qr
estebanmino Nov 22, 2019
d1b93a1
select own accounts
estebanmino Nov 22, 2019
465476f
reverse ens and better state
estebanmino Nov 25, 2019
f77ae1d
handle parse
estebanmino Nov 25, 2019
5287731
clear to
estebanmino Nov 25, 2019
2d38051
handle account label
estebanmino Nov 25, 2019
98388d6
next and redux
estebanmino Nov 25, 2019
f414f6b
handle to ens
estebanmino Nov 25, 2019
a0318ff
parse address book
estebanmino Nov 26, 2019
ae9efff
handle send flow navigation
estebanmino Nov 26, 2019
812056a
amount view
estebanmino Nov 26, 2019
91ac956
render only tokens
estebanmino Nov 27, 2019
a384dc6
pick selected asset
estebanmino Nov 27, 2019
7804d9c
redux set selected address
estebanmino Nov 27, 2019
584f9de
use max
estebanmino Nov 27, 2019
7a546a1
switch currency
estebanmino Nov 28, 2019
6d9f8fa
confirm
estebanmino Nov 28, 2019
0241097
clean
estebanmino Nov 28, 2019
6394378
init confirm
estebanmino Nov 28, 2019
b03d760
confirm view
estebanmino Nov 28, 2019
62b36e0
render fiat in confirm
estebanmino Nov 28, 2019
2465537
handle eth txs
estebanmino Nov 28, 2019
acc9f41
handle erc20 txs
estebanmino Nov 28, 2019
3fb8ff4
parseTransactionData
estebanmino Nov 29, 2019
e99f8ae
wait for gas estimation
estebanmino Nov 29, 2019
0461d11
custom gas modal
estebanmino Nov 29, 2019
250c225
handle gas selection
estebanmino Nov 29, 2019
9e2d9e5
handle advanced tx fee
estebanmino Nov 29, 2019
9fd5049
custom gas improvs
estebanmino Nov 29, 2019
b817d0c
handle gas selected
estebanmino Nov 29, 2019
e8176bb
handle current selected when cancel
estebanmino Nov 29, 2019
c30442b
use time estimates
estebanmino Nov 29, 2019
61246f9
handle amount errors
estebanmino Dec 2, 2019
9310fde
address search
estebanmino Dec 2, 2019
907e98f
typo
estebanmino Dec 2, 2019
55ad49b
recents
estebanmino Dec 2, 2019
3326913
parsedRecents
estebanmino Dec 2, 2019
b525c1e
cleaner code
estebanmino Dec 2, 2019
9cd5080
handle address errors
estebanmino Dec 2, 2019
0832840
handle more error cases
estebanmino Dec 2, 2019
a6c8e09
fix usemax
estebanmino Dec 2, 2019
6798468
handle global primary currency
estebanmino Dec 2, 2019
0593e9e
handle use max with fiat as prim currency
estebanmino Dec 2, 2019
593a50a
switch currency working
estebanmino Dec 2, 2019
c300255
set asset before and fix switched symbol
estebanmino Dec 3, 2019
add6593
render gas wait time
estebanmino Dec 3, 2019
3e7fe6d
improve gas selectors
estebanmino Dec 3, 2019
153c1c1
add weeks and days
estebanmino Dec 3, 2019
1f3e24e
better parsewaittime
estebanmino Dec 3, 2019
33b28e6
fix selected asset change
estebanmino Dec 3, 2019
9ed0243
improve conversion
estebanmino Dec 3, 2019
a6595e8
parseTransactionData
estebanmino Dec 3, 2019
e500106
validate gas on confirm
estebanmino Dec 3, 2019
320ca11
handle use max with gas for eth
estebanmino Dec 3, 2019
46c32fa
add gas estimation in amount
estebanmino Dec 3, 2019
a6e61c4
estimatedTotalGas once on mount
estebanmino Dec 3, 2019
a25f0b6
send tx
estebanmino Dec 4, 2019
bd51233
gas bug on amount
estebanmino Dec 4, 2019
69706a6
render collectibles in list
estebanmino Dec 4, 2019
a0b4287
handle collectibles list and data
estebanmino Dec 4, 2019
0657963
handle collectible on confirm
estebanmino Dec 4, 2019
1537868
ignore No stops in gradient
estebanmino Dec 5, 2019
a6255e3
handle focus
estebanmino Dec 5, 2019
1a527d3
handle tradable collectibles and sort them
estebanmino Dec 5, 2019
6e833a4
handle tokens without exchange rate
estebanmino Dec 5, 2019
98184d0
check collectible removal
estebanmino Dec 5, 2019
f18fd2c
start tx from asset
estebanmino Dec 5, 2019
515a8c0
go to new send flow from everywhere
estebanmino Dec 5, 2019
3711585
hex data modal
estebanmino Dec 5, 2019
1caa91b
reset tx on unmount
estebanmino Dec 5, 2019
fb54961
delete unused files
estebanmino Dec 5, 2019
beaf656
reset tx
estebanmino Dec 5, 2019
5f04ada
start tx with asset
estebanmino Dec 5, 2019
baf76c2
redux update
estebanmino Dec 6, 2019
c90be4b
clean state
estebanmino Dec 6, 2019
feaab16
isETH
estebanmino Dec 6, 2019
12b9187
highlight address to
estebanmino Dec 6, 2019
143f965
use currency symbols and texttransfor uppercase
estebanmino Dec 6, 2019
2d9e4e3
handle currency code in amount input
estebanmino Dec 6, 2019
34aeefa
send to up to date design
estebanmino Dec 6, 2019
88094ca
amount up to date design
estebanmino Dec 6, 2019
b1ed849
confirm up to date design
estebanmino Dec 6, 2019
61a3689
send to up to date design android
estebanmino Dec 6, 2019
42f6efa
next buttons margin bottom
estebanmino Dec 6, 2019
254a0d4
input amount font
estebanmino Dec 6, 2019
81050a3
fix texts color
estebanmino Dec 6, 2019
88f8c06
fix androi dpaste
estebanmino Dec 6, 2019
5751b8a
alignments
estebanmino Dec 6, 2019
1569558
handle mmm txs
estebanmino Dec 9, 2019
dc1c251
handle ens name when resolved
estebanmino Dec 9, 2019
f9b4491
formatting and locales
estebanmino Dec 9, 2019
3581b28
add contacts from settings
estebanmino Dec 9, 2019
ce608d9
no need for edit component
estebanmino Dec 10, 2019
b2f66dd
handle add validation
estebanmino Dec 10, 2019
27d1d89
locales
estebanmino Dec 10, 2019
0b04af8
rename route
estebanmino Dec 10, 2019
82ee0b5
delete contact
estebanmino Dec 10, 2019
8321d2c
spanish
estebanmino Dec 10, 2019
818fcd7
handle scan and android'
estebanmino Dec 10, 2019
d99c91d
more locales
estebanmino Dec 10, 2019
de5279e
address ready when edit
estebanmino Dec 10, 2019
bca8bf2
snappppppsSs
estebanmino Dec 10, 2019
12e1ab6
Merge branch 'develop' into feature/address-book
estebanmino Dec 10, 2019
b349388
others
estebanmino Dec 11, 2019
c2ab99f
fix reverse ens
estebanmino Dec 11, 2019
deb5324
disable add address without an alias
estebanmino Dec 11, 2019
fb9d3c4
fixes
estebanmino Dec 11, 2019
b0a78be
address elemenr
estebanmino Dec 11, 2019
c216e3f
snaps
estebanmino Dec 11, 2019
0be0475
custom gas validation
estebanmino Dec 16, 2019
0b534f0
locale missing
estebanmino Dec 16, 2019
e8a5c84
check decimal
estebanmino Dec 16, 2019
1e98ffd
comments
estebanmino Dec 17, 2019
6d68e0b
snaps
estebanmino Dec 17, 2019
1176fa7
fix key
estebanmino Jan 10, 2020
e4fb0e3
fix assets
estebanmino Jan 10, 2020
b47d5ee
fix use mac
estebanmino Jan 10, 2020
7926ac7
renderFiatAddition
estebanmino Jan 10, 2020
fdfc77c
fix empty data
estebanmino Jan 10, 2020
4c63753
snaps
estebanmino Jan 10, 2020
72700f5
fix gas calculation for erc721
estebanmino Jan 10, 2020
d0e5d5e
Merge branch 'develop' into feature/address-book
estebanmino Jan 10, 2020
0213035
rm logs
estebanmino Jan 10, 2020
a8a2dfc
validation
estebanmino Jan 10, 2020
42e784e
handle change from without asset
estebanmino Jan 14, 2020
e6ffa84
use flat list
estebanmino Jan 16, 2020
806424e
rm unused code
estebanmino Jan 16, 2020
93f0e97
rename
estebanmino Jan 16, 2020
9a526e7
fix delete
estebanmino Jan 16, 2020
e2d2a82
fix empty bug
estebanmino Jan 16, 2020
4ad6d35
fix margin issue 10
estebanmino Jan 16, 2020
ea6623e
issue 11
estebanmino Jan 16, 2020
68fb904
12
estebanmino Jan 16, 2020
19b293e
send qr to old sendflow 13
estebanmino Jan 16, 2020
1a76bc9
snaps
estebanmino Jan 16, 2020
adfe114
Merge branch 'develop' into feature/address-book
estebanmino Jan 16, 2020
6a5a023
fix others contacts
estebanmino Jan 21, 2020
38f9dca
fix edit
estebanmino Jan 21, 2020
ec25daf
use mac
estebanmino Jan 21, 2020
28a19f4
lte
estebanmino Jan 21, 2020
11da3ea
bn(0)
estebanmino Jan 21, 2020
03837c2
fix 13
estebanmino Jan 22, 2020
9ab0c52
handle space and emojis
estebanmino Jan 22, 2020
ca2dd53
fix validation
estebanmino Jan 22, 2020
5802545
contact form with refs
estebanmino Jan 22, 2020
5921076
snapS
estebanmino Jan 22, 2020
e8d4043
Merge branch 'develop' into feature/address-book
estebanmino Jan 22, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 66 additions & 0 deletions app/actions/newTransaction/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/**
* Clears transaction object completely
*/
export function resetTransaction() {
return {
type: 'RESET_TRANSACTION'
};
}

/**
* Starts a new transaction state with an asset
*
* @param {object} selectedAsset - Asset to start the transaction with
*/
export function newAssetTransaction(selectedAsset) {
return {
type: 'NEW_ASSET_TRANSACTION',
selectedAsset,
assetType: selectedAsset.isETH ? 'ETH' : selectedAsset.tokenId ? 'ERC721' : 'ERC20'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we have this strings in a few different places, maybe it's time to have a transactionTypes utils and set them all as constants to avoid misspelling like ERC_20, ERC_721, etc

};
}

/**
* Sets transaction to address and ensRecipient in case is available
*
* @param {string} from - Address to send the transaction from
* @param {string} to - Address to send the transaction to
* @param {string} ensRecipient - Resolved ens name to send the transaction to
* @param {string} transactionToName - Resolved address book name for to address
* @param {string} transactionFromName - Resolved address book name for from address
*/
export function setRecipient(from, to, ensRecipient, transactionToName, transactionFromName) {
return {
type: 'SET_RECIPIENT',
from,
to,
ensRecipient,
transactionToName,
transactionFromName
};
}

/**
* Sets asset as selectedAsset
*
* @param {object} selectedAsset - Asset to start the transaction with
*/
export function setSelectedAsset(selectedAsset) {
return {
type: 'SET_SELECTED_ASSET',
selectedAsset,
assetType: selectedAsset.isETH ? 'ETH' : selectedAsset.tokenId ? 'ERC721' : 'ERC20'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same

};
}

/**
* Sets transaction object to be sent
*
* @param {object} transaction - Transaction object with from, to, data, gas, gasPrice, value
*/
export function prepareTransaction(transaction) {
return {
type: 'PREPARE_TRANSACTION',
transaction
};
}
32 changes: 32 additions & 0 deletions app/components/Nav/App/__snapshots__/index.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,20 @@ exports[`App should render correctly 1`] = `
"getStateForAction": [Function],
},
"QRScanner": null,
"SendFlowView": Object {
"childRouters": Object {
"Amount": null,
"Confirm": null,
"SendTo": null,
},
"getActionCreators": [Function],
"getActionForPathAndParams": [Function],
"getComponentForRouteName": [Function],
"getComponentForState": [Function],
"getPathAndParamsForState": [Function],
"getScreenOptions": [Function],
"getStateForAction": [Function],
},
"SendView": Object {
"childRouters": Object {
"Send": null,
Expand Down Expand Up @@ -191,6 +205,8 @@ exports[`App should render correctly 1`] = `
"AdvancedSettings": null,
"ChoosePasswordSimple": null,
"CompanySettings": null,
"ContactForm": null,
"ContactsSettings": null,
"EnterPasswordSimple": null,
"ExperimentalSettings": null,
"GeneralSettings": null,
Expand Down Expand Up @@ -581,6 +597,20 @@ exports[`App should render correctly 1`] = `
"getStateForAction": [Function],
},
"QRScanner": null,
"SendFlowView": Object {
"childRouters": Object {
"Amount": null,
"Confirm": null,
"SendTo": null,
},
"getActionCreators": [Function],
"getActionForPathAndParams": [Function],
"getComponentForRouteName": [Function],
"getComponentForState": [Function],
"getPathAndParamsForState": [Function],
"getScreenOptions": [Function],
"getStateForAction": [Function],
},
"SendView": Object {
"childRouters": Object {
"Send": null,
Expand Down Expand Up @@ -617,6 +647,8 @@ exports[`App should render correctly 1`] = `
"AdvancedSettings": null,
"ChoosePasswordSimple": null,
"CompanySettings": null,
"ContactForm": null,
"ContactsSettings": null,
"EnterPasswordSimple": null,
"ExperimentalSettings": null,
"GeneralSettings": null,
Expand Down
32 changes: 32 additions & 0 deletions app/components/Nav/Main/__snapshots__/index.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,20 @@ exports[`Main should render correctly 1`] = `
"getStateForAction": [Function],
},
"QRScanner": null,
"SendFlowView": Object {
"childRouters": Object {
"Amount": null,
"Confirm": null,
"SendTo": null,
},
"getActionCreators": [Function],
"getActionForPathAndParams": [Function],
"getComponentForRouteName": [Function],
"getComponentForState": [Function],
"getPathAndParamsForState": [Function],
"getScreenOptions": [Function],
"getStateForAction": [Function],
},
"SendView": Object {
"childRouters": Object {
"Send": null,
Expand Down Expand Up @@ -199,6 +213,8 @@ exports[`Main should render correctly 1`] = `
"AdvancedSettings": null,
"ChoosePasswordSimple": null,
"CompanySettings": null,
"ContactForm": null,
"ContactsSettings": null,
"EnterPasswordSimple": null,
"ExperimentalSettings": null,
"GeneralSettings": null,
Expand Down Expand Up @@ -469,6 +485,20 @@ exports[`Main should render correctly 1`] = `
"getStateForAction": [Function],
},
"QRScanner": null,
"SendFlowView": Object {
"childRouters": Object {
"Amount": null,
"Confirm": null,
"SendTo": null,
},
"getActionCreators": [Function],
"getActionForPathAndParams": [Function],
"getComponentForRouteName": [Function],
"getComponentForState": [Function],
"getPathAndParamsForState": [Function],
"getScreenOptions": [Function],
"getStateForAction": [Function],
},
"SendView": Object {
"childRouters": Object {
"Send": null,
Expand Down Expand Up @@ -505,6 +535,8 @@ exports[`Main should render correctly 1`] = `
"AdvancedSettings": null,
"ChoosePasswordSimple": null,
"CompanySettings": null,
"ContactForm": null,
"ContactsSettings": null,
"EnterPasswordSimple": null,
"ExperimentalSettings": null,
"GeneralSettings": null,
Expand Down
26 changes: 25 additions & 1 deletion app/components/Nav/Main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import ExperimentalSettings from '../../Views/Settings/ExperimentalSettings';
import NetworksSettings from '../../Views/Settings/NetworksSettings';
import NetworkSettings from '../../Views/Settings/NetworksSettings/NetworkSettings';
import AppInformation from '../../Views/Settings/AppInformation';
import Contacts from '../../Views/Settings/Contacts';
import Wallet from '../../Views/Wallet';
import TransactionsView from '../../Views/TransactionsView';
import SyncWithExtension from '../../Views/SyncWithExtension';
Expand All @@ -38,6 +39,7 @@ import AddAsset from '../../Views/AddAsset';
import Collectible from '../../Views/Collectible';
import CollectibleView from '../../Views/CollectibleView';
import Send from '../../Views/Send';
import SendTo from '../../Views/SendFlow/SendTo';
import RevealPrivateCredential from '../../Views/RevealPrivateCredential';
import WalletConnectSessions from '../../Views/WalletConnectSessions';
import OfflineMode from '../../Views/OfflineMode';
Expand Down Expand Up @@ -87,6 +89,9 @@ import contractMap from 'eth-contract-metadata';
import MessageSign from '../../UI/MessageSign';
import WalletConnectReturnToBrowserModal from '../../UI/WalletConnectReturnToBrowserModal';
import AsyncStorage from '@react-native-community/async-storage';
import Amount from '../../Views/SendFlow/Amount';
import Confirm from '../../Views/SendFlow/Confirm';
import ContactForm from '../../Views/Settings/Contacts/ContactForm';

const styles = StyleSheet.create({
flex: {
Expand Down Expand Up @@ -203,6 +208,12 @@ const MainNavigator = createStackNavigator(
CompanySettings: {
screen: AppInformation
},
ContactsSettings: {
screen: Contacts
},
ContactForm: {
screen: ContactForm
},
SyncWithExtensionView: {
screen: SyncWithExtension
},
Expand Down Expand Up @@ -242,6 +253,19 @@ const MainNavigator = createStackNavigator(
}
})
},
SendFlowView: {
screen: createStackNavigator({
SendTo: {
screen: SendTo
},
Amount: {
screen: Amount
},
Confirm: {
screen: Confirm
}
})
},
ApprovalView: {
screen: createStackNavigator({
Approval: {
Expand Down Expand Up @@ -734,7 +758,7 @@ class Main extends PureComponent {
};

onUnapprovedTransaction = async transactionMeta => {
if (this.props.transaction.value || this.props.transaction.to) {
if (this.props.transaction.value || this.props.transaction.to || transactionMeta.origin === 'MMM') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that MMM could be part of the same utils file I mentioned in the previous comments

return;
}
// Check if it's a payment channel deposit transaction to sign
Expand Down
60 changes: 38 additions & 22 deletions app/components/UI/AccountList/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,11 @@ class AccountList extends PureComponent {
/**
* Current provider ticker
*/
ticker: PropTypes.string
ticker: PropTypes.string,
/**
* Whether it will show options to create or import accounts
*/
enableAccountsAddition: PropTypes.bool
};

state = {
Expand Down Expand Up @@ -150,6 +154,7 @@ class AccountList extends PureComponent {
const previousIndex = this.state.selectedAccountIndex;
const { PreferencesController } = Engine.context;
const { keyrings } = this.props;

requestAnimationFrame(async () => {
try {
this.mounted && this.setState({ selectedAccountIndex: newIndex });
Expand All @@ -158,6 +163,14 @@ class AccountList extends PureComponent {
keyrings && keyrings.length ? keyrings : Engine.context.KeyringController.state.keyrings;
const accountsOrdered = allKeyrings.reduce((list, keyring) => list.concat(keyring.accounts), []);

// If not enabled is used from address book so we don't change accounts
if (!this.props.enableAccountsAddition) {
this.props.onAccountChange(accountsOrdered[newIndex]);
const orderedAccounts = this.getAccounts();
this.mounted && this.setState({ orderedAccounts });
return;
}

PreferencesController.setSelectedAddress(accountsOrdered[newIndex]);

this.props.onAccountChange();
Expand Down Expand Up @@ -281,6 +294,7 @@ class AccountList extends PureComponent {

render() {
const { orderedAccounts } = this.state;
const { enableAccountsAddition } = this.props;
return (
<SafeAreaView style={styles.wrapper} testID={'account-list'}>
<View style={styles.titleWrapper}>
Expand All @@ -293,28 +307,30 @@ class AccountList extends PureComponent {
ref={this.flatList}
style={styles.accountsWrapper}
testID={'account-number-button'}
getItemLayout={(data, index) => ({ length: 80, offset: 80 * index, index })} // eslint-disable-line
getItemLayout={(_, index) => ({ length: 80, offset: 80 * index, index })} // eslint-disable-line
/>
<View style={styles.footer}>
<TouchableOpacity
style={styles.footerButton}
testID={'create-account-button'}
onPress={this.addAccount}
>
{this.state.loading ? (
<ActivityIndicator size="small" color={colors.blue} />
) : (
<Text style={styles.btnText}>{strings('accounts.create_new_account')}</Text>
)}
</TouchableOpacity>
<TouchableOpacity
onPress={this.importAccount}
style={styles.footerButton}
testID={'import-account-button'}
>
<Text style={styles.btnText}>{strings('accounts.import_account')}</Text>
</TouchableOpacity>
</View>
{enableAccountsAddition && (
<View style={styles.footer}>
<TouchableOpacity
style={styles.footerButton}
testID={'create-account-button'}
onPress={this.addAccount}
>
{this.state.loading ? (
<ActivityIndicator size="small" color={colors.blue} />
) : (
<Text style={styles.btnText}>{strings('accounts.create_new_account')}</Text>
)}
</TouchableOpacity>
<TouchableOpacity
onPress={this.importAccount}
style={styles.footerButton}
testID={'import-account-button'}
>
<Text style={styles.btnText}>{strings('accounts.import_account')}</Text>
</TouchableOpacity>
</View>
)}
</SafeAreaView>
);
}
Expand Down
8 changes: 4 additions & 4 deletions app/components/UI/AccountSelect/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,11 +176,11 @@ class AccountSelect extends PureComponent {
const state = PaymentChannelsClient.getState();
mainBalance = `${state.balance} ${strings('unit.sai')}`;
} else if (primaryCurrency === 'ETH') {
mainBalance = renderFromWei(balance) + ' ' + getTicker(ticker);
secondaryBalance = weiToFiat(balance, conversionRate, currentCurrency.toUpperCase());
mainBalance = `${renderFromWei(balance)} ${getTicker(ticker)}`;
secondaryBalance = weiToFiat(balance, conversionRate, currentCurrency);
} else {
mainBalance = weiToFiat(balance, conversionRate, currentCurrency.toUpperCase());
secondaryBalance = renderFromWei(balance) + ' ' + getTicker(ticker);
mainBalance = weiToFiat(balance, conversionRate, currentCurrency);
secondaryBalance = `${renderFromWei(balance)} ${getTicker(ticker)}`;
}

return (
Expand Down
Loading