import React from 'react';
import ClickOutside from 'coral-framework/components/ClickOutside';
import styles from './Toggleable.css';
import cn from 'classnames';
const upArrow = ;
const downArrow = ;
export default class Toggleable extends React.Component {
constructor(props) {
super(props);
this.state = {
isOpen: false
};
}
toggle = () => {
this.setState({isOpen: !this.state.isOpen});
}
close = () => {
if (this.state.isOpen) {
this.setState({isOpen: false});
}
}
render() {
const {children, className, ...rest} = this.props;
const {isOpen} = this.state;
return (
{isOpen ? children : null}
);
}
}