I have been working on customizing the MUI Select
method, and I've encountered difficulty when trying to hover over the "NarrowDownIcon":
https://i.sstatic.net/VEZFP.png
My goal is to change the hover behavior of this icon by setting its backgroundColor
to "blue". Here is the code I have used:
icon: {
color: theme.palette.primary.dark,
height: 32,
width: 32,
top: `calc(50% - ${theme.spacing(2.2)}px)`,
borderRadius: "50%",
cursor: "pointer",
"&:hover": {
backgroundColor: theme.palette.primary.lighter,
},
},
I then applied this CSS to the select icon class:
<Select
value={selectedValue}
onChange={onChange}
onFocus={onFocus}
onBlur={onBlur}
className={classes.textInput}
inputProps={{
id,
name: id,
}}
classes={{
icon: classes.icon,
}}
However, it seems that my approach is not working. Can anyone provide assistance with this issue? Thank you.