Commit 8fe2cc5a authored by rocosen's avatar rocosen

Merge branch 'feat-permissions' into 'release'

Update Button.tsx

See merge request !53
parents 9cec3b3e 834f43ea
......@@ -6,24 +6,24 @@ import { Typography, Menu, MenuItem, IconButton, Button } from "@mui/material";
import ArrowDropDownIcon from '@mui/icons-material/ArrowDropDown';
type ButtonTagProps = {
text: string;
variant?: "text" | 'contained' | 'outlined';
click?: any;
select?: any[];
fontSize?: string;
dropValue?: boolean;
drop?: boolean;
color?: "inherit" | "primary" | "secondary" | undefined,
btnStyle?: any,
size?: "large" | "medium" | "small",
disabled?: boolean,
style?: any,
img?: JSX.Element;
selectCallBack?: (item: any, key: number) => void
text: string;//文本内容
variant?: "text" | 'contained' | 'outlined';//按钮样式
click?: any;//点击事件
select?: any[];//选择按钮的下拉列表
fontSize?: string;//按钮文字大小
dropValue?: boolean;//选择的值
drop?: boolean;//是否开启选择
color?: "inherit" | "primary" | "secondary" | undefined,//按钮颜色风格
btnStyle?: any,//按钮自定义样式类
size?: "large" | "medium" | "small",//按钮尺寸
disabled?: boolean,//是否禁用
style?: any,//按钮自定义样式
img?: JSX.Element;//图标按钮中的图标
selectCallBack?: (item: any, key: number) => void//选择按钮的回调
}
const ButtonComponent = (props: ButtonTagProps) => {
const { size, disabled, variant, color, img, btnStyle = {},select, selectCallBack } = props;
const { size, disabled, variant, color, img, btnStyle = {}, select, selectCallBack } = props;
const { classes, cx } = useStyles({});
const [anchorEl, setAnchorEl] = React.useState(null);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment