blob: 12333690691944f01dbd74b35cb2af8337786772 [file] [log] [blame]
idillon-sfl44b05342022-08-24 15:46:42 -04001import { IconButton } from "@mui/material";
idillon-sfld5cc7862022-08-25 11:11:34 -04002import { styled } from "@mui/styles";
idillon-sfl44b05342022-08-24 15:46:42 -04003import { CameraIcon, CancelIcon, FolderIcon, PenIcon } from "./svgIcons";
4
idillon-sfld5cc7862022-08-25 11:11:34 -04005const CustomisePictureButton = styled(
6 ({Icon, ...props}) => (
7 <IconButton {...props} disableRipple={true}>
idillon-sfl44b05342022-08-24 15:46:42 -04008 <Icon fontSize="inherit"/>
9 </IconButton>
10 )
idillon-sfldeabd282022-08-25 22:50:03 -040011)(({theme}) => ({
12 border: `1px solid ${theme.palette.primary.dark}`,
13 color: theme.palette.primary.dark,
idillon-sfld5cc7862022-08-25 11:11:34 -040014 height: "53px",
15 width: "53px",
16 fontSize: "15px",
17 "&:hover": {
idillon-sfldeabd282022-08-25 22:50:03 -040018 background: theme.palette.primary.light,
idillon-sfld5cc7862022-08-25 11:11:34 -040019 },
20 "&:active": {
21 color: "#FFF",
idillon-sfldeabd282022-08-25 22:50:03 -040022 background: theme.palette.primary.dark,
idillon-sfld5cc7862022-08-25 11:11:34 -040023 },
24}));
idillon-sfl44b05342022-08-24 15:46:42 -040025
26export const RemovePictureButton = (props) => {
27 return (
28 <CustomisePictureButton {...props}
29 aria-label="remove picture"
30 Icon={CancelIcon}
31 />
32 )
33}
34
35export const EditPictureButton = (props) => {
36 return (
37 <CustomisePictureButton {...props}
38 aria-label="edit picture"
39 Icon={PenIcon}
40 />
41 )
42}
43
44export const UploadPictureButton = (props) => {
45 return (
46 <CustomisePictureButton {...props}
47 aria-label="upload picture"
48 Icon={FolderIcon}
49 />
50 )
51}
52
53export const TakePictureButton = (props) => {
54 return (
55 <CustomisePictureButton {...props}
56 aria-label="take picture"
57 Icon={CameraIcon}
58 />
59 )
60}