CSS aspect-ratio property
Normally, only certain replaced elements have an aspect ratio, particularly images. For them, if only one of width and height is specified, the other can be computed from it using the intrinsic aspect ratio. This property allows explicitly specifying an aspect ratio for any other element to get similar behavior.
Generalizes the aspect ratio concept to general elements. This allows various effects, for example sizing <iframe> elements using an aspect ratio, things like filmstrips where each element has the same height but needs an appropriate width, cases where a replaced element is wrapped by a component but should keep the aspect ratio, etc.
Status in Chromium
In development (tracking bug)
Consensus & Standardization
Intent to Prototype urlIntent to Prototype thread
Search tagsaspect-ratio, aspect, ratio,
Last updated on 2020-10-27