1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-12-23 09:52:26 +01:00

Use localizations for placeholders in Swap (#9587)

This commit is contained in:
David Walsh 2020-10-14 11:45:44 -05:00 committed by GitHub
parent 48dd3fe069
commit d0152aad51
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 2 deletions

View File

@ -1784,6 +1784,9 @@
"swapSelectAQuote": { "swapSelectAQuote": {
"message": "Select a quote" "message": "Select a quote"
}, },
"swapSelectAToken": {
"message": "Select a token"
},
"swapSelectQuotePopoverDescription": { "swapSelectQuotePopoverDescription": {
"message": "Below are all the quotes gathered from multiple liquidity sources." "message": "Below are all the quotes gathered from multiple liquidity sources."
}, },

View File

@ -209,7 +209,7 @@ export default function BuildQuote ({
selectedItem={selectedFromToken} selectedItem={selectedFromToken}
maxListItems={30} maxListItems={30}
loading={loading && (!tokensToSearch?.length || !topAssets || !Object.keys(topAssets).length)} loading={loading && (!tokensToSearch?.length || !topAssets || !Object.keys(topAssets).length)}
selectPlaceHolderText="Select" selectPlaceHolderText={t('swapSelect')}
hideItemIf={(item) => item.address === selectedToToken?.address} hideItemIf={(item) => item.address === selectedToToken?.address}
listContainerClassName="build-quote__open-dropdown" listContainerClassName="build-quote__open-dropdown"
autoFocus autoFocus
@ -246,7 +246,7 @@ export default function BuildQuote ({
itemsToSearch={tokensToSearch} itemsToSearch={tokensToSearch}
searchPlaceholderText={t('swapSearchForAToken')} searchPlaceholderText={t('swapSearchForAToken')}
fuseSearchKeys={fuseSearchKeys} fuseSearchKeys={fuseSearchKeys}
selectPlaceHolderText="Select a token" selectPlaceHolderText={t('swapSelectAToken')}
maxListItems={30} maxListItems={30}
onSelect={onToSelect} onSelect={onToSelect}
loading={loading && (!tokensToSearch?.length || !topAssets || !Object.keys(topAssets).length)} loading={loading && (!tokensToSearch?.length || !topAssets || !Object.keys(topAssets).length)}