mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Gas inputs can be changed by up and down arrows (#3598)
* Up and down arrows can control gas inputs. * input-number.js just uses number type.
This commit is contained in:
parent
fd3e240dd9
commit
a69480d78d
@ -91,6 +91,7 @@ CurrencyInput.prototype.render = function () {
|
|||||||
placeholder,
|
placeholder,
|
||||||
readOnly,
|
readOnly,
|
||||||
inputRef,
|
inputRef,
|
||||||
|
type,
|
||||||
} = this.props
|
} = this.props
|
||||||
const { emptyState, focused } = this.state
|
const { emptyState, focused } = this.state
|
||||||
|
|
||||||
@ -99,6 +100,7 @@ CurrencyInput.prototype.render = function () {
|
|||||||
const valueToRender = this.getValueToRender()
|
const valueToRender = this.getValueToRender()
|
||||||
return h('input', {
|
return h('input', {
|
||||||
className,
|
className,
|
||||||
|
type,
|
||||||
value: emptyState ? '' : valueToRender,
|
value: emptyState ? '' : valueToRender,
|
||||||
placeholder: focused ? '' : placeholder,
|
placeholder: focused ? '' : placeholder,
|
||||||
size: valueToRender.length * inputSizeMultiplier,
|
size: valueToRender.length * inputSizeMultiplier,
|
||||||
|
@ -55,6 +55,7 @@ InputNumber.prototype.render = function () {
|
|||||||
className: 'customize-gas-input',
|
className: 'customize-gas-input',
|
||||||
value,
|
value,
|
||||||
placeholder,
|
placeholder,
|
||||||
|
type: 'number',
|
||||||
onInputChange: newValue => {
|
onInputChange: newValue => {
|
||||||
this.setValue(newValue)
|
this.setValue(newValue)
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user