Bug 1732060 [wpt PR 30876] - Update wpt metadata, a=testonly
[gecko.git] / layout / reftests / floats / bfc-displace-3a.html
blob6622fa723c646a193bfb3069a6b4b18c839ea00a
1 <!DOCTYPE HTML>
2 <title>Test of block formatting context displacement by floats</title>
3 <link rel="help" href="https://drafts.csswg.org/css2/visuren.html#floats">
4 <meta name="assert" content="The border box of a table, a block-level replaced element, or an element in the normal flow that establishes a new block formatting context (such as an element with 'overflow' other than 'visible') must not overlap the margin box of any floats in the same block formatting context as the element itself.">
5 <style>
7 .contain {
8 border: medium solid;
9 width: 400px;
10 height: 400px;
11 background: yellow;
14 .margin {
15 margin-top: 3px;
18 .float {
19 float: left;
20 clear: left;
21 height: 20px;
22 background: blue;
25 .bfc {
26 overflow: hidden;
27 width: 250px;
28 margin-top: 7px; /* collapses */
29 height: 20px; /* fits exactly */
30 margin-bottom: 20px;
31 background: fuchsia;
34 </style>
37 <div class="contain">
38 <div class="margin">
39 <div class="float" style="width: 100px"></div>
40 <div class="float" style="width: 200px"></div>
41 <div class="bfc"></div>
42 </div>
43 </div>