diff options
author | Esteban MIno <efmino@uc.cl> | 2018-08-08 08:07:26 +0800 |
---|---|---|
committer | Esteban MIno <efmino@uc.cl> | 2018-08-08 08:07:26 +0800 |
commit | c245405acb2323239d079d574cbf4230ec068c35 (patch) | |
tree | 686b584d7d6e2866a9432ac9ba7e2a25cd14d854 | |
parent | 33357e3538b5157a852323d5f1e2db7f19b3303e (diff) | |
download | dexon-wallet-c245405acb2323239d079d574cbf4230ec068c35.tar.gz dexon-wallet-c245405acb2323239d079d574cbf4230ec068c35.tar.zst dexon-wallet-c245405acb2323239d079d574cbf4230ec068c35.zip |
show token address summary on old ui
-rw-r--r-- | old-ui/app/add-suggested-token.js | 29 |
1 files changed, 19 insertions, 10 deletions
diff --git a/old-ui/app/add-suggested-token.js b/old-ui/app/add-suggested-token.js index 1a0fc046..51be4c5f 100644 --- a/old-ui/app/add-suggested-token.js +++ b/old-ui/app/add-suggested-token.js @@ -5,6 +5,9 @@ const connect = require('react-redux').connect const actions = require('../../ui/app/actions') const Tooltip = require('./components/tooltip.js') const ethUtil = require('ethereumjs-util') +const Copyable = require('./components/copyable') +const addressSummary = require('./util').addressSummary + module.exports = connect(mapStateToProps)(AddSuggestedTokenScreen) @@ -70,16 +73,22 @@ AddSuggestedTokenScreen.prototype.render = function () { ]), ]), - h('section.flex-row.flex-center', [ - h('p#token-address', { - name: 'address', - style: { - width: 'inherit', - flex: '1 0 auto', - height: '30px', - margin: '8px', - }, - }, address), + h('div', { + style: { display: 'flex' }, + }, [ + h(Copyable, { + value: ethUtil.toChecksumAddress(address), + }, [ + h('span#token-address', { + style: { + width: 'inherit', + flex: '1 0 auto', + height: '30px', + margin: '8px', + display: 'flex', + }, + }, addressSummary(address, 24, 4, false)), + ]), ]), h('div', [ |