0

New to Material-UI and getting spammed with the same error in console after adding the following component.

Full Error:

Material-UI: The key clicked provided to the classes prop is not implemented in ForwardRef(ExpansionPanelSummary). You can only override one of the following: root,expanded,focused,disabled,content,expandIcon.

const CustomExpansionPanelSummary = withStyles(theme => ({
    expandIcon: {
        order: -1,
        padding: '0',
        margin: '17px 0px'
    },
    clicked:{
        color: '#0000FF',
    },
    unclicked:{
        color: '#FF0000',
    },
    root:{
        fontFamily: 'Roboto',
        fontSize: '12px',
        lineHeight: '1.31',
        letterSpacing: '3px',
        marginTop: '0px,
        marginBottom: '0px,
    },
    expanded: {
        '&$expanded': {
          marginTop: '10px',
          marginBottom: '10px',
          minHeight:0
        },
      },
}))(ExpansionPanelSummary);
            <CustomExpansionPanelSummary
                classes ={{
                    content:(props.clicked ? "customcss":"customcss-name")
                }}
                
                expandIcon={<ArrowDropDownIcon 
                    className={props.clicked ? "customcss":"customcss-name"}
                    />}
            >
                {props.clicked} clicked item
            </CustomExpansionPanelSummary>
Parchie
  • 26
  • 1

0 Answers0