OLD | NEW |
---|---|
(Empty) | |
1 <!DOCTYPE html> | |
2 <p>Given a float followed by a regular block with the same height as the float, then a block B with | |
3 a negative margin, followed by a block with with overflow:hidden. Check that the | |
4 overflow:hidden block doesn't overlap with the float, and also that it takes up all available | |
5 space (but not more) beside the float. There's an empty collapse-through blo ck before B, so | |
6 that our initial logical top estimate fails and we have to relayout. When la ying out again, we | |
7 have to detect that the float that we first thought didn't affect the overfl ow:hidden block now | |
8 affects it.</p> | |
9 <p>Below there should be an olive square to the left of a navy square. The navy square should be | |
10 slightly larger than the olive one, and there should be spacing between them . They should not | |
11 overlap.</p> | |
12 <div style="width:18em;"> | |
13 <div> | |
14 <div style="float:left; width:8em; height:8em; margin-right:1em; backgro und:olive;"></div> | |
15 <div style="height:8em;"></div> | |
16 <div> | |
17 <!-- Here's an empty block that we can just collapse through, but we don't realize that | |
18 when calculating our initial top estimate on its parent, so we have to relayout | |
19 when it turns out that a negative margin has pulled us upwards (and suddenly we | |
20 have something block-level that's affected by the float). --> | |
21 <div></div> | |
22 | |
23 <div style="margin-top:-8em;"></div> | |
24 | |
25 <!-- Here's a block-level element that is affected by floats, becaus e it's a table. We | |
26 could have used e.g. an overflow:hidden DIV for the same effect . --> | |
27 <div style="overflow:hidden; height:9em; background:navy;"> | |
Julien - ping for review
2015/09/04 17:40:10
The tests really look like a check-layout.js tests
| |
28 </div> | |
29 </div> | |
30 </div> | |
OLD | NEW |