I have a following view. The box (columnBox) can contain a lot of items. However in the view the box doesn't scroll. I have set overFlowY as auto , I can not set height as I don't know the exact height it will exand to. However my parent has fixed height, only that box contents need to be scrollable.
What can I do to fix this
columnBox: {
overflowY:'auto',
display: "flex",
flexGrow: 1,
flexDirection:"column"
}
<Card
height="calc(100vh - 200px)"
>
<Box>
<Divider />
<Box height={88} p={4} display="flex" alignItems="center">
{children}
</Box>
<Divider />
<Box className={classes.columnBox} bgcolor="green">
{products &&
products.length > 0 &&
testProducts.map(item => {
return (
<Fragment>
<Box
display="flex"
justifyContent="space-between"
alignItems="center"
>
{someChildren}
</Box>
<Divider>
<Fragment>
})