Keep Fixed Aspect Ratios - Choose between fixed to width or height

@nick.carroll When working with different element types like an image and a video that are on the same line (ie: in a row container) the height of these elements is usually more important than their widths. And often, the aspect ratios are different as in the correct aspect ratio for videos is 16:9 but with images we may want it to be square (1:1) or slightly different, as image aspect ratios have more variability, but regardless the video and image aspect ratios may not always be the same.

In as much, this means having to do too much math to set the correct widths on the different elements to try and maintain the same heights, as when they are on the same line, the height between the two elements being the same is more important than their widths.

It would be nice to have a selection between fix the ratio to width or height rather than a default to width.

Screen Shot 2024-06-08 at 6.31.56 PM

What I would like to see is when I check the box for keep element aspect ratio fixed is another checkbox to fix the ratio to height, so that if I check this box, my width will automatically be determined by the height when the aspect ratio is fixed, so that I could set my heights to ensure both elements (image and video) are the same height as they are on the same line.

Then in addition to this, as all layout options need to be changed conditionally, there should be a conditional property to change to switch between fixing the ratio to height or width, so that once the line breaks and the two elements are no longer on the same line, we can switch the aspect ratio being fixed to height and have it fixed to width.

3 Likes