1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 12:27:35 +00:00

LibWeb: Stretch-fit flex items with aspect ratio but no fixed sizes

This solves a particular issue with SVG as flex items, where the SVG has
an intrinsic aspect ratio via its viewBox, but no explicit natural width
or height.

Makes all corporate sponsor logos show up on https://ziglang.org/ :^)
This commit is contained in:
Andreas Kling 2024-02-25 12:56:01 +01:00
parent 92a7fd77f4
commit a61f09a010
5 changed files with 43 additions and 15 deletions

View file

@ -0,0 +1,6 @@
<!DOCTYPE html><style>
body {
display: flex;
flex-direction: row;
}
</style><body><svg viewBox="0 0 24 24"><rect x=0 y=0 width=12 height=12></svg>