File size: 690 Bytes
1e92f2d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
import clsx from 'clsx';
import PropTypes from 'prop-types';
import { PureComponent } from 'react';
export default class ChartBarTooltip extends PureComponent {
static propTypes = {
className: PropTypes.string,
icon: PropTypes.object,
label: PropTypes.string,
value: PropTypes.string,
};
render() {
return (
<li className={ clsx( 'module-content-list-item', this.props.className ) }>
<span className="chart__tooltip-wrapper wrapper">
<span className="chart__tooltip-value value">{ this.props.value }</span>
<span className="chart__tooltip-label label">
{ this.props.icon || null }
{ this.props.label }
</span>
</span>
</li>
);
}
}
|