Good day,
I have a styled component named "GridDropDownItem" where i am taking class name through props and it has its own css properties as well.
Styled Component:
const GridDropDownItem = styled.div.attrs<{ class: string }>(props => ({
className: props.class //here i am taking class name
})) <{ class: string }>`
width: 180px;
height: 100px;
border-radius: 4px;
`;
In Render:
<GridDropDownItem class={itemClass ? itemClass : ''}></GridDropDownItem>
The problem is when I pass itemClass with width and height properties, it is getting overwritten. How can i tackle this situation?
Any suggestion would be appreciated.
