comment fixes
This commit is contained in:
@@ -1,11 +1,3 @@
|
||||
// NEXT_PUBLIC_NODE_ADDRESS=https://cosmoshub.validator.network:443
|
||||
// NEXT_PUBLIC_DENOM=uatom
|
||||
// NEXT_PUBLIC_DISPLAY_DENOM=ATOM
|
||||
// NEXT_PUBLIC_DISPLAY_DENOM_EXPONENT=6
|
||||
// NEXT_PUBLIC_GAS_PRICE=0.03uatom
|
||||
// NEXT_PUBLIC_CHAIN_ID=cosmoshub-4
|
||||
// NEXT_PUBLIC_ADDRESS_PREFIX=cosmos
|
||||
|
||||
export const initialState = {
|
||||
chain: {
|
||||
nodeAddress: process.env.NEXT_PUBLIC_NODE_ADDRESS,
|
||||
|
||||
+13
-10
@@ -21,16 +21,19 @@ const abbreviateLongString = (longString) => {
|
||||
// NARROW NO-BREAK SPACE (U+202F)
|
||||
const thinSpace = "\u202F";
|
||||
|
||||
// Takes a Coin (e.g. `{"amount": "1234", "denom": "uatom"}`) and converts it
|
||||
// into a user-readable string.
|
||||
//
|
||||
// Also takes in a chainInfo object, defined in '../context/AppReducer'
|
||||
//
|
||||
// The chainInfo provided displayDenom/displayDenomExponent
|
||||
// will be used if the denom matches the denom stored in the chainInfo object.
|
||||
//
|
||||
// A leading "u" is interpreted as µ (micro) and uxyz will be converted to XYZ
|
||||
// for displaying.
|
||||
/**
|
||||
* Takes a Coin (e.g. `{"amount": "1234", "denom": "uatom"}`) and converts it into a user-readable string.
|
||||
*
|
||||
* The chainInfo provided displayDenom/displayDenomExponent
|
||||
* will be used if the denom matches the denom stored in the chainInfo object.
|
||||
*
|
||||
* A leading "u" is interpreted as µ (micro) and uxyz will be converted to XYZ
|
||||
* for displaying.
|
||||
*
|
||||
* @param {object} coin (e.g. `{"amount": "1234", "denom": "uatom"}`)
|
||||
* @param {object} chainInfo Provides information about a chain (e.g. node, prefix, denomination), object structure defined in '../context/AppReducer'.
|
||||
* @return {string} The abbreviated string.
|
||||
*/
|
||||
const printableCoin = (coin, chainInfo) => {
|
||||
// null, undefined and this sort of things
|
||||
if (!coin) return "–";
|
||||
|
||||
Reference in New Issue
Block a user