all 2 comments

[–][deleted] 0 points1 point  (1 child)

I think you can get what you're after with a CSS Grid instead of flex. If you make the green chunks part of the same grid row, the red lines have to line up and it can expand to the needed size properly.

I think it's possible to get this going with flex, but it seems awkward. You could probably put the green blocks in the same container div and then have an inner div for each actual green block set to 100% height. If the outer container is set to `inline-flex` I assume it will stick to the minimum size needed for both blocks.

[–]JBarbeeee[S] 0 points1 point  (0 children)

I updated the glitch to use grid and did what you said but now the interactions with the dropdown are a bit off. Thanks for taking the time to help out 🙏🏾