You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[css-sizing-4] Clarify transfer (or non-transfer) of indefinite sizes through aspect-ratio #5306
Current spec specifies that definite sizes are transferred through the aspect ratio. But there are probably some cases where "indefinite" sizes need to also be transferred, e.g. replaced elements with an intrinsic size must always be able to transfer those sizes.
(Probably for non-replaced elements, such sizes shouldn't transfer, since in many cases they will require layout. This rationale should also be noted in the spec so it's clear.)
This is a corner case, but yeah, it is possible to have an SVG with an intrinsic width and nothing else. In this situation, setting 'aspect-ratio: 1 / 1;' should probably transfer the intrinsic width across to become an intrinsic height as well.
I'm a little scared of doing that; I don't have any example, but I suspect it might have unexpected effects on layout algorithms. The above commit at least gives us the minimal edit to solve this issue, tho.
Activity
tabatkins commentedon Jul 20, 2020
This is a corner case, but yeah, it is possible to have an SVG with an intrinsic width and nothing else. In this situation, setting 'aspect-ratio: 1 / 1;' should probably transfer the intrinsic width across to become an intrinsic height as well.
fantasai commentedon Jul 20, 2020
I wonder if we should define fixed-length intrinsic sizes of replaced elements as definite?
[css-sizing-4] Specify that a-r can change a replaced element with a …
tabatkins commentedon Jul 20, 2020
I'm a little scared of doing that; I don't have any example, but I suspect it might have unexpected effects on layout algorithms. The above commit at least gives us the minimal edit to solve this issue, tho.