diff options
Diffstat (limited to 'ui/app/components')
-rw-r--r-- | ui/app/components/buy-options.js | 5 | ||||
-rw-r--r-- | ui/app/components/modal.js | 23 |
2 files changed, 15 insertions, 13 deletions
diff --git a/ui/app/components/buy-options.js b/ui/app/components/buy-options.js index f0864d087..d36328efd 100644 --- a/ui/app/components/buy-options.js +++ b/ui/app/components/buy-options.js @@ -26,10 +26,12 @@ function BuyOptions () { module.exports = connect(mapStateToProps, mapDispatchToProps)(BuyOptions) +// BuyOptions is currently meant to be rendered inside <Modal /> +// It is the only component in this codebase that does so +// It utilizes modal styles BuyOptions.prototype.render = function () { return h('div', {}, [ h('div.modal-content.transfers-subview', { - }, [ h('div.modal-content-title-wrapper.flex-column.flex-center', { style: {}, @@ -44,7 +46,6 @@ BuyOptions.prototype.render = function () { h('div.modal-content-option', { onClick: () => { - console.log("buy clicked") const { toCoinbase, address } = this.props toCoinbase(address) }, diff --git a/ui/app/components/modal.js b/ui/app/components/modal.js index 2339ee497..8bac866a8 100644 --- a/ui/app/components/modal.js +++ b/ui/app/components/modal.js @@ -1,10 +1,7 @@ const Component = require('react').Component - const h = require('react-hyperscript') const inherits = require('util').inherits const connect = require('react-redux').connect -// const elementType = require('react-prop-types/lib/elementType') -// const PropTypes from 'prop-types' const FadeModal = require('boron').FadeModal const actions = require('../actions') const isMobileView = require('../../lib/is-mobile-view') @@ -30,16 +27,16 @@ function Modal () { module.exports = connect(mapStateToProps, mapDispatchToProps)(Modal) -Modal.prototype.render = function () { +const mobileModalStyles = { + width: '95%', +} - const mobileModalStyles = { - width: '95%', - } +const laptopModalStyles = { + width: '66%', + top: '30%', +} - const laptopModalStyles = { - width: '66%', - top: '30%', - } +Modal.prototype.render = function () { return h(FadeModal, { @@ -78,8 +75,12 @@ Modal.prototype.show = function() { this.modalRef.show() } +// TODO: specify default props and proptypes // Modal.defaultProps = {} +// const elementType = require('react-prop-types/lib/elementType') +// const PropTypes from 'prop-types' + // Modal.propTypes = { // active: PropTypes.bool, // hideModal: PropTypes.func.isRequired, |