feat: clear button

This commit is contained in:
karishmas6
2024-06-15 21:01:22 +05:30
parent e2c56be61f
commit 33f37f35bc

View File

@@ -0,0 +1,17 @@
import { IconButton } from "@mui/material";
import { Clear } from "@mui/icons-material";
import React, { FC } from "react";
interface ClearButtonProps {
handleClick: () => void;
size?: "small" | "medium" | "large";
}
export const ClearButton: FC<ClearButtonProps> = ({ handleClick, size }) => {
return (
<IconButton aria-label="add" size={size || "small"} onClick={handleClick}
sx={{ color: 'inherit', '&:hover': { color: '#1976d2', backgroundColor: 'transparent' }}}>
<Clear/>
</IconButton>
);
};