How do you change the Stepper color on React Material UI?

前端 未结 7 1281
不知归路
不知归路 2021-02-14 01:17

In the screenshot above, I am trying to change the step color to either: green for correct, yellow for in-progress and red for incorrect.

How could I do this?

7条回答
  •  眼角桃花
    2021-02-14 01:35

    You can set the classes property for the StepIconProps property:

    
        
        Some Text
        
    
    

    Then your style should overwrite the default theme color by using the !important CSS rule:

    const styles = theme => ({
      icon: {
        color: "red !important"
      },
    });
    

提交回复
热议问题