ResponsiveGrid_Flutter icon indicating copy to clipboard operation
ResponsiveGrid_Flutter copied to clipboard

ResponsiveGridList of Equal Height of the tallest Widget

Open tehsunnliu opened this issue 3 years ago • 2 comments

Hi I've created a ResponsiveGridList as shown in the image below. Since in my case the height of the widget will vary according to the number of items. I wanted to set all the widget's sizes to the height of the tallest widget so they all look symmetric. Is there any way I can achieve this? I tried setting squareCells = true, however, I get RenderFlex overflowed exception.

Thank you.

Screenshot from 2021-03-27 22-08-30

tehsunnliu avatar Mar 27 '21 16:03 tehsunnliu

if i understand you well, that is the default behavior you don't have to set squareCells to true

also I couldn't reproduce the exception either

muhammad369 avatar Apr 03 '21 20:04 muhammad369

Hi Mohamed, Thank you for your reply. An exception occurs when the items in the list go beyond the height of squareCell. I tried placing a listview or singleChildScrollView but this doesn't work. I wanted to know if there is anyway I can stretch the remaining place for example in Order Id: 3 the Card srhinks to wrap its contents. Is it possible to stretch it to take the remaining space? For now, what I've done is fill empty widgets to match the height with the tallest widget.

tehsunnliu avatar Apr 04 '21 09:04 tehsunnliu