We want to see the pointer cursor when hovering over a Material UI component.
<Typography sx={{ "&:hover": { cursor: "pointer" } }}> This is some text </Typography>
<Box p={2} border="1px solid #ccc" sx={{ "&:hover": { cursor: "pointer" } }}> <Typography>This is a box</Typography> </Box>
Make sure not to have a space between the &
and :hover
. That will only select hovered child components.
If you're trying to add cursor: pointer to an Icon, use an IconButton