UNPKG

@ima/devtools

Version:

IMA.js debugging panel in the Chrome Developer Tools window.

26 lines (22 loc) 518 B
import cn from 'clsx'; import PropTypes from 'prop-types'; import styles from './button.module.less'; export default function Button({ color, className, children, ...restProps }) { return ( <button className={cn( styles.btn, { [styles[`btn--${color}`]]: color }, className )} {...restProps} > {children} </button> ); } Button.propTypes = { children: PropTypes.any, color: PropTypes.oneOf(['primary', 'success']), className: PropTypes.string, };