Minor clean up.

feature/default_network_editable
Dan 7 years ago
parent 5facba89ca
commit c605c9897d
  1. 7
      ui/app/components/gas-tooltip.js
  2. 5
      ui/app/css/itcss/components/send.scss
  3. 13
      ui/app/send.js

@ -59,12 +59,7 @@ GasTooltip.prototype.render = function () {
const { position, title, children, className } = this.props const { position, title, children, className } = this.props
const { gasPrice, gasLimit } = this.state const { gasPrice, gasLimit } = this.state
return h('div', { return h('div.gas-tooltip', {}, [
style: {
display: 'flex',
justifyContent: 'center',
}
}, [
h('div.gas-tooltip-close-area', { h('div.gas-tooltip-close-area', {
onClick: this.onClose onClick: this.onClose
}), }),

@ -148,6 +148,11 @@
position: relative; position: relative;
} }
.gas-tooltip {
display: flex;
justify-content: center;
}
.gas-tooltip-label { .gas-tooltip-label {
font-size: 16px; font-size: 16px;
color: $tundora; color: $tundora;

@ -66,14 +66,11 @@ function SendTransactionScreen () {
tooltipIsOpen: false, tooltipIsOpen: false,
} }
this.back = this.back.bind(this)
this.back = this.back.bind(this) this.back = this.back.bind(this)
this.closeTooltip = this.closeTooltip.bind(this) this.closeTooltip = this.closeTooltip.bind(this)
this.onSubmit = this.onSubmit.bind(this) this.onSubmit = this.onSubmit.bind(this)
this.onSubmit = this.onSubmit.bind(this)
this.recipientDidChange = this.recipientDidChange.bind(this) this.recipientDidChange = this.recipientDidChange.bind(this)
this.setCurrentCurrency = this.setCurrentCurrency.bind(this) this.setCurrentCurrency = this.setCurrentCurrency.bind(this)
this.setCurrentCurrency = this.setCurrentCurrency.bind(this)
this.toggleTooltip = this.toggleTooltip.bind(this) this.toggleTooltip = this.toggleTooltip.bind(this)
} }
@ -232,13 +229,11 @@ SendTransactionScreen.prototype.render = function () {
onClose: this.closeTooltip, onClose: this.closeTooltip,
onFeeChange: ({gasLimit, gasPrice}) => { onFeeChange: ({gasLimit, gasPrice}) => {
this.setState({ this.setState({
newTx: Object.assign( newTx: {
this.state.newTx, ...this.state.newTx,
{
gas: gasLimit, gas: gasLimit,
gasPrice, gasPrice,
} },
),
}) })
} }
}), }),
@ -287,7 +282,7 @@ SendTransactionScreen.prototype.render = function () {
} }
}), }),
h('div.send-screen-gas-input-customize', { h('div.send-screen-gas-input-customize', {
onClick: () => this.toggleTooltip.bind(this)(!this.state.tooltipIsOpen), onClick: this.toggleTooltip,
}, [ }, [
'Customize' 'Customize'
]), ]),

Loading…
Cancel
Save