diff options
author | Thomas <thomas.b.huang@gmail.com> | 2018-05-08 05:30:43 +0800 |
---|---|---|
committer | Thomas <thomas.b.huang@gmail.com> | 2018-05-08 05:30:43 +0800 |
commit | 8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b (patch) | |
tree | 7deae9281915f1499883fc1eb71b6fb62717dd42 /ui/app/components/send | |
parent | 6bf6589c440330d0089da4012709b831c722945a (diff) | |
parent | caf5a6c15c3375d9d64116d80d87eb064e955e59 (diff) | |
download | tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar.gz tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar.bz2 tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar.lz tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar.xz tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.tar.zst tangerine-wallet-browser-8250fd9d6daae3bcef17d8de4e3f2b22ac58ce5b.zip |
Merge branch 'develop' into testing
Diffstat (limited to 'ui/app/components/send')
-rw-r--r-- | ui/app/components/send/currency-display.js | 15 | ||||
-rw-r--r-- | ui/app/components/send/send-constants.js | 4 |
2 files changed, 10 insertions, 9 deletions
diff --git a/ui/app/components/send/currency-display.js b/ui/app/components/send/currency-display.js index a7bd5d7ea..90fb2b66c 100644 --- a/ui/app/components/send/currency-display.js +++ b/ui/app/components/send/currency-display.js @@ -89,7 +89,6 @@ CurrencyDisplay.prototype.render = function () { } = this.props const valueToRender = this.getValueToRender() - const convertedValueToRender = this.getConvertedValueToRender(valueToRender) return h('div', { @@ -97,22 +96,24 @@ CurrencyDisplay.prototype.render = function () { style: { borderColor: inError ? 'red' : null, }, - onClick: () => this.currencyInput.focus(), + onClick: () => this.currencyInput && this.currencyInput.focus(), }, [ h('div.currency-display__primary-row', [ h('div.currency-display__input-wrapper', [ - h(CurrencyInput, { + h(readOnly ? 'input' : CurrencyInput, { className: primaryBalanceClassName, value: `${valueToRender}`, placeholder: '0', readOnly, - onInputChange: newValue => { - handleChange(this.getAmount(newValue)) - }, - inputRef: input => { this.currencyInput = input }, + ...(!readOnly ? { + onInputChange: newValue => { + handleChange(this.getAmount(newValue)) + }, + inputRef: input => { this.currencyInput = input }, + } : {}), }), h('span.currency-display__currency-symbol', primaryCurrency), diff --git a/ui/app/components/send/send-constants.js b/ui/app/components/send/send-constants.js index b3ee0899a..5d89c74aa 100644 --- a/ui/app/components/send/send-constants.js +++ b/ui/app/components/send/send-constants.js @@ -1,8 +1,8 @@ const ethUtil = require('ethereumjs-util') const { conversionUtil, multiplyCurrencies } = require('../../conversion-util') -const MIN_GAS_PRICE_HEX = (100000000).toString(16) -const MIN_GAS_PRICE_DEC = '100000000' +const MIN_GAS_PRICE_DEC = '0' +const MIN_GAS_PRICE_HEX = (parseInt(MIN_GAS_PRICE_DEC)).toString(16) const MIN_GAS_LIMIT_DEC = '21000' const MIN_GAS_LIMIT_HEX = (parseInt(MIN_GAS_LIMIT_DEC)).toString(16) |