diff options
Send v2 to autocomplete.
Diffstat (limited to 'ui/app/send-v2.js')
-rw-r--r-- | ui/app/send-v2.js | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/ui/app/send-v2.js b/ui/app/send-v2.js index e0d7c2394..dbc8a23d0 100644 --- a/ui/app/send-v2.js +++ b/ui/app/send-v2.js @@ -3,6 +3,7 @@ const PersistentForm = require('../lib/persistent-form') const h = require('react-hyperscript') const connect = require('react-redux').connect const FromDropdown = require('./components/send/from-dropdown') +const ToAutoComplete = require('./components/send/to-autocomplete') module.exports = connect(mapStateToProps)(SendTransactionScreen) @@ -43,7 +44,8 @@ function SendTransactionScreen () { SendTransactionScreen.prototype.render = function () { const { accounts } = this.props - const { dropdownOpen } = this.state + const { dropdownOpen, newTx } = this.state + const { to } = newTx return ( @@ -81,7 +83,26 @@ SendTransactionScreen.prototype.render = function () { closeDropdown: () => this.setState({ dropdownOpen: false }), }), - ]) + ]), + + h('div.send-v2__form-row', [ + + h('div.send-v2__form-label', 'To:'), + + h(ToAutoComplete, { + to, + identities: identities.map(({ identity }) => identity), + onChange: (event) => { + this.setState({ + newTx: { + ...this.state.newTx, + to: event.target.value, + }, + }) + }, + }), + + ]), ]), |