Tests/LibWeb: Add test for flex item auto height with flex-wrap: wrap

This commit is contained in:
Andreas Kling 2023-03-26 13:03:27 +02:00
parent 2699f226fb
commit 5b030a6923
Notes: sideshowbarker 2024-07-17 07:48:42 +09:00
2 changed files with 29 additions and 0 deletions

View File

@ -0,0 +1,11 @@
Viewport <#document> at (0,0) content-size 800x600 children: not-inline
BlockContainer <html> at (0,0) content-size 800x116 children: not-inline
Box <body.outer> at (8,8) content-size 400x100 flex-container(column) children: not-inline
Box <div.inner> at (8,8) content-size 400x17.46875 flex-container(row) flex-item children: not-inline
BlockContainer <(anonymous)> at (8,8) content-size 348.609375x17.46875 flex-item children: inline
line 0 width: 348.609375, height: 17.46875, bottom: 17.46875, baseline: 13.53125
frag 0 from TextNode start: 0, length: 40, rect: [8,8 348.609375x17.46875]
"The orange box should have a snug height"
TextNode <#text>
BlockContainer <(anonymous)> at (8,8) content-size 0x0 children: inline
TextNode <#text>

View File

@ -0,0 +1,18 @@
<!DOCTYPE html><html><head><style>
html {
background: white;
font: 16px 'SerenitySans';
}
.outer {
width: 400px;
height: 100px;
display: flex;
flex-direction: column;
background: pink;
}
.inner {
display: flex;
flex-wrap: wrap;
background: orange;
}
</style></head><body class="outer"><div class="inner">The orange box should have a snug height</div></div></div>