diff --git a/src/components/Card.jsx b/src/components/Card.jsx index 3e9df64..1a59040 100644 --- a/src/components/Card.jsx +++ b/src/components/Card.jsx @@ -27,6 +27,13 @@ class Card extends React.Component { return makeNiceDate(datetime) } + handleCardSelect (e) { + if (!e.target.className.includes('arrow-down')) { + const selectedEventFormat = this.props.idx > 0 ? [this.props.event] : this.props.event + this.props.onSelect(selectedEventFormat, this.props.idx) + } + } + renderSummary () { return ( { - console.info('getting clicked') - if (!this.state.isOpen) { - const selectedEventFormat = idx > 0 ? [this.props.event] : this.props.event - this.props.onSelect(selectedEventFormat, idx) - } else { - console.info('NOT OPEN') - } - }} + onClick={(e) => this.handleCardSelect(e)} > {this.renderMain()} {this.state.isOpen ? this.renderExtra() : null} diff --git a/src/components/Layout.js b/src/components/Layout.js index a90174f..e820f30 100644 --- a/src/components/Layout.js +++ b/src/components/Layout.js @@ -83,7 +83,6 @@ class Dashboard extends React.Component { } handleSelect (selected, axis) { - console.info(selected) const matchedEvents = [] const TIMELINE_AXIS = 0 if (axis === TIMELINE_AXIS) {