IBM / css-gridish

Automatically build your grid design’s CSS Grid code, CSS Flexbox fallback code, Sketch artboards, and Chrome extension.
https://ibm.github.io/css-gridish/
Other
2.25k stars 113 forks source link

Stretching rows for variable content #5

Closed seejamescode closed 6 years ago

seejamescode commented 6 years ago

As a developer with an unknown paragraph length, I want to not have to specify a specific row count for that paragraph’s DOM element.

Currently, the default rows are grid-auto-rows: $rowHeight * 1rem.

I think the behavior should be grid-auto-rows: minmax($rowHeight * 1rem, auto). However, this affects the situation when two subgrids are placed next to each other. The smaller of the two grids will stretch all of it’s children to fill the height of the larger subgrid.

seejamescode commented 6 years ago

Solution: Switch default grid-auto-rows from the fixed row height to minmax(rowHeight, min-content)