Recently, I encountered an issue with typescript that involves the textTransform: 'none'
property throwing an error.
const useButtonStyles = makeStyles((theme: Theme) => createStyles({
// @ts-ignore
root: (props) => ({
boxShadow: 'none',
textTransform: 'none',
borderRadius: 3,
border: '1px solid',
backgroundColor: theme.palette[props.color].main,
borderColor: theme.palette[props.color].main,
color: theme.palette.getContrastText(theme.palette[props.color].light),
'&:hover': {
backgroundColor: theme.palette[props.color].light,
borderColor: theme.palette[props.color].light
},
'&:active': {
boxShadow: 'none',
backgroundColor: theme.palette[props.color].light,
borderColor: theme.palette[props.color].main
},
'&:focus': {
boxShadow: `${fade(theme.palette[props.color].light, 0.25)} 0 0 0 0.15rem`
}
}),
}));