按钮组件:
import { Button } from 'antd';
import * as React from 'react';
import PropTypes from 'prop-types';
const BaseBtn = ({ children, onClick, bcolor, color, bgColor, full }) => {
// const btnClassName = classnames({
// [`new_btn_${bcolor}`]: true,
// 'new-btn': true,
// });
const boxStyle = {
border: `1px solid ${bcolor}`,
width: full ? '100%' : 'max-content',
color: `${color}`,
backgroundColor: `${bgColor}`,
};
return (
<>
<Button className="new-btn" style={boxStyle} onClick={onClick}>
{children}
</Button>
</>
);
};
BaseBtn.defaultProps = {
bcolor: 'gray',
disabled: false,
icon: true,
color: '#000000',
bgColor: '#ffffff',
full: false,
};
BaseBtn.propTypes = {
children: PropTypes.any,
di