I have styles like this:
const useStyles = makeStyles(theme => ({ root: { margin: 5 }, container: { backgroundColor: 'red' }, active: { // here I want to target the 'container' className I created above like '& .container': { backgroundColor: 'green' } } });
I want to target the container
className I created inside of the active
className. The above won't work because in the DOM, MUI will generate a unique name so I won't be targeting the right class. Wasn't able to find any SO answer or blog or documentation addressing this.
没有评论:
发表评论