1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 11:47:46 +00:00
serenity/Tests/LibWeb/Layout/expected/flex/abspos-flex-child-with-auto-height.txt
Andreas Kling 50d72f0d8c LibWeb: Handle case where abspos flex child position depends on height
There's a particularly awkward case where the static position of an
abspos child of a flex container is dependent on its height. This can
happen when `align-items: center` is in effect, as we have to adjust
the abspos child's Y position by half of its height.

This patch solves the issue by reordering operations in the abspos
height resolution algorithm, to make sure that height is resolved
before the static position is calculated.
2023-09-03 15:44:47 +02:00

12 lines
866 B
Text

Viewport <#document> at (0,0) content-size 800x600 children: not-inline
BlockContainer <html> at (0,0) content-size 800x16 [BFC] children: not-inline
Box <body> at (8,8) content-size 784x0 positioned flex-container(row) [FFC] children: not-inline
BlockContainer <div.abspos> at (8,-42) content-size 100x100 positioned [BFC] children: not-inline
BlockContainer <div.green> at (8,-42) content-size 100x200 children: inline
TextNode <#text>
ViewportPaintable (Viewport<#document>) [0,0 800x600] overflow: [0,-42 800x642]
PaintableWithLines (BlockContainer<HTML>) [0,0 800x16] overflow: [0,-42 800x200]
PaintableBox (Box<BODY>) [8,8 784x0] overflow: [8,-42 100x200]
PaintableWithLines (BlockContainer<DIV>.abspos) [8,-42 100x100] overflow: [8,-42 100x200]
PaintableWithLines (BlockContainer<DIV>.green) [8,-42 100x200]