diff options
Diffstat (limited to 'ui/app')
-rw-r--r-- | ui/app/send-v2.js | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/ui/app/send-v2.js b/ui/app/send-v2.js index 16e4d7801..0086faa1f 100644 --- a/ui/app/send-v2.js +++ b/ui/app/send-v2.js @@ -2,6 +2,7 @@ const { inherits } = require('util') const PersistentForm = require('../lib/persistent-form') const h = require('react-hyperscript') const connect = require('react-redux').connect +const classnames = require('classnames') const Identicon = require('./components/identicon') const FromDropdown = require('./components/send/from-dropdown') @@ -380,7 +381,6 @@ SendTransactionScreen.prototype.renderFooter = function () { } = this.props const noErrors = amountError === null && toError === null - const errorClass = noErrors ? '' : '__disabled' return h('div.send-v2__footer', [ h('button.send-v2__cancel-btn', { @@ -389,8 +389,13 @@ SendTransactionScreen.prototype.renderFooter = function () { goHome() }, }, 'Cancel'), - h(`button.send-v2__next-btn${errorClass}`, { - onClick: event => noErrors && this.onSubmit(event), + h(`button`, { + className: classnames({ + 'send-v2__next-btn': noErrors, + 'send-v2__next-btn__disabled': !noErrors, + }), + disabled: !noErrors, + onClick: event => this.onSubmit(event), }, 'Next'), ]) } |