mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Select all in to and from of send screens, instead of clearing on focus.
This commit is contained in:
parent
eae40e0544
commit
56697ea9a4
@ -181,7 +181,7 @@ SendTokenScreen.prototype.renderToAddressInput = function () {
|
||||
to: e.target.value,
|
||||
errors: {},
|
||||
}),
|
||||
onFocus: () => to && this.setState({ to: '' }),
|
||||
onFocus: event => to && event.target.select(),
|
||||
}),
|
||||
h('datalist#addresses', [
|
||||
// Corresponds to the addresses owned.
|
||||
|
@ -123,14 +123,9 @@ SendTransactionScreen.prototype.renderFromInput = function (from, identities) {
|
||||
})
|
||||
},
|
||||
onBlur: () => this.setErrorsFor('from'),
|
||||
onFocus: () => {
|
||||
onFocus: event => {
|
||||
this.clearErrorsFor('from'),
|
||||
this.state.newTx.from && this.setState({
|
||||
newTx: {
|
||||
...this.state.newTx,
|
||||
from: '',
|
||||
},
|
||||
})
|
||||
this.state.newTx.from && event.target.select()
|
||||
},
|
||||
}),
|
||||
|
||||
@ -168,14 +163,9 @@ SendTransactionScreen.prototype.renderToInput = function (to, identities, addres
|
||||
})
|
||||
},
|
||||
onBlur: () => this.setErrorsFor('to'),
|
||||
onFocus: () => {
|
||||
onFocus: event => {
|
||||
this.clearErrorsFor('to')
|
||||
this.state.newTx.to && this.setState({
|
||||
newTx: {
|
||||
...this.state.newTx,
|
||||
to: '',
|
||||
},
|
||||
})
|
||||
this.state.newTx.to && event.target.select()
|
||||
},
|
||||
}),
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user