import React from 'react';
import PropTypes from 'prop-types';
import { Tooltip } from 'reactstrap';
import Icon from './icon';
const propTypes = {
id: PropTypes.string.isRequired,
icon: PropTypes.string.isRequired,
text: PropTypes.string.isRequired,
onClick: PropTypes.func,
href: PropTypes.string
};
class IconButton extends React.Component {
constructor(props) {
super(props);
this.state = {
tooltipOpen: false
};
}
toggle = () => {
this.setState({
tooltipOpen: !this.state.tooltipOpen
});
};
render() {
const btnContent = (
<>