@wulperstudio/cms
Version:
Wulper Studio Library Components CMS
41 lines • 1.13 kB
JavaScript
import { Accordion } from '@mui/material';
import { styled } from '@mui/material/styles';
export var CAccordion = styled(Accordion, {
shouldForwardProp: function shouldForwardProp(prop) {
return prop !== 'backgroundColor' && prop !== 'borderColor' && prop !== 'borderRadius' && prop !== 'disabledDivider';
}
})(function (_ref) {
var disabledDivider = _ref.disabledDivider,
color = _ref.color,
radius = _ref.radius,
backgroundColor = _ref.backgroundColor,
borderColor = _ref.borderColor;
return {
width: '100%',
backgroundColor: backgroundColor,
color: color,
padding: '1rem',
'&.Mui-expanded .MuiAccordionSummary-content.Mui-expanded': {
margin: '0 !important'
},
'&.Mui-expanded .MuiAccordionDetails-root': {
padding: 0
},
'&.Mui-expanded': {
margin: 0,
padding: '1rem',
'& div': {
minHeight: 'auto'
}
},
'&.MuiAccordion-rounded': {
borderRadius: radius
},
'&.MuiPaper-outlined': {
borderColor: borderColor
},
'&:before': {
display: disabledDivider ? 'none' : 'block'
}
};
});