mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
94967072f7
* remove global transaction state from send slice * fixup new test
24 lines
925 B
JavaScript
24 lines
925 B
JavaScript
import contractMap from '@metamask/contract-metadata';
|
|
|
|
/**
|
|
* A normalized list of addresses exported as part of the contractMap in
|
|
* `@metamask/contract-metadata`. Used primarily to validate if manually entered
|
|
* contract addresses do not match one of our listed tokens
|
|
*/
|
|
export const LISTED_CONTRACT_ADDRESSES = Object.keys(
|
|
contractMap,
|
|
).map((address) => address.toLowerCase());
|
|
|
|
/**
|
|
* @typedef {Object} TokenDetails
|
|
* @property {string} address - The address of the selected 'TOKEN' or
|
|
* 'COLLECTIBLE' contract.
|
|
* @property {string} [symbol] - The symbol of the token.
|
|
* @property {number} [decimals] - The number of decimals of the selected
|
|
* 'ERC20' asset.
|
|
* @property {number} [tokenId] - The id of the selected 'COLLECTIBLE' asset.
|
|
* @property {TokenStandardStrings} [standard] - The standard of the selected
|
|
* asset.
|
|
* @property {boolean} [isERC721] - True when the asset is a ERC721 token.
|
|
*/
|