I am trying to customize the Select component from Material UI.
This is what it looks like:

However, when the select component is focused, I want to change the border-color from material UI's blue to a custom red color.
I tried setting the styles but it doesn't do anything at all
import FormControl from '@material-ui/core/FormControl'; import InputLabel from '@material-ui/core/InputLabel'; import MuiSelect from '@material-ui/core/Select'; import MenuItem from '@material-ui/core/MenuItem'; import { makeStyles } from '@material-ui/core/styles'; const useStyles = makeStyles((theme) => ({ formControl: { margin: theme.spacing(1), minWidth: 120, }, select: { borderColor: '#FF0000', // { const classes = useStyles(); return ( Months January February March April ); }; Select.propTypes = {}; export default Select;
Источник: https://stackoverflow.com/questions/677 ... -component
Мобильная версия