Change DropDownMenu List item selected color

464 Views Asked by At

Hello I am trying to change the selected color of a material-ui element but I cannot find any information on how to do that. I want to change this pinkish color to be blue.

enter image description here

edit: maybe this is the way to go but I cannot make this work:

import getMuiTheme from 'material-ui/lib/styles/getMuiTheme';

const muiTheme = getMuiTheme({}, {
  menuItem: {
  selectedTextColor: 'white',
  },
});
1

There are 1 best solutions below

0
user1780729 On

I managed to implement the solution that I had in mind:

import getMuiTheme from 'material-ui/styles/getMuiTheme';

const muiTheme = getMuiTheme({}, {
  palette: {
    accent1Color: 'blue',
  },
});

and in the render:

<MuiThemeProvider muiTheme={muiTheme}>