parent
3ce69e1b65
commit
1485ec7392
@ -0,0 +1,26 @@ |
||||
const Component = require('react').Component |
||||
const h = require('react-hyperscript') |
||||
const inherits = require('util').inherits |
||||
module.exports = CurrencyToggle |
||||
|
||||
inherits(CurrencyToggle, Component) |
||||
function CurrencyToggle () { |
||||
Component.call(this) |
||||
} |
||||
|
||||
CurrencyToggle.prototype.render = function () { |
||||
const { onClick, currentCurrency } = this.props |
||||
|
||||
return h('span', {}, [ |
||||
h('span', { |
||||
className: currentCurrency === 'ETH' ? 'selected-currency' : 'unselected-currency', |
||||
onClick: () => onClick('ETH')
|
||||
}, ['ETH']), |
||||
'<>', |
||||
h('span', { |
||||
className: currentCurrency === 'USD' ? 'selected-currency' : 'unselected-currency', |
||||
onClick: () => onClick('USD'),
|
||||
}, ['USD']), |
||||
]) //holding on icon from design
|
||||
} |
||||
|
@ -1,7 +1,7 @@ |
||||
const Component = require('react').Component |
||||
const h = require('react-hyperscript') |
||||
const inherits = require('util').inherits |
||||
const InputNumber = require('./input-number.js') |
||||
const InputNumber = require('../input-number.js') |
||||
const findDOMNode = require('react-dom').findDOMNode |
||||
|
||||
module.exports = GasTooltip |
Loading…
Reference in new issue