grid same height for second block via aspect ratio
hello there i wanna first block which is h-full to have same height as second block (which is have aspect ratio) so i can apply overflow scroll to first block
4 Replies
i dont wanna use fixed height if possible since i've already declared aspect ratio
i guess i can just apply position absolute for 1 one but its doesnt feel right
Works for me? https://codepen.io/kevinpowell/pen/qEEVJxL
I guess the only problem is at smaller sizes, the 5fr 3fr goes out the window. This happens because
fr
works with available space... It's more like a max-size
than anything else.
If you want it to always be 5fr 3fr, you'd need to nest an element in the one on the left, and use position absolute like you mentioned: https://codepen.io/kevinpowell/pen/KwwyGxX?editors=1100yea seems like this is only way, thanks!