Status: PASS | Duration: 8ms | Subtests: 1/1 | Open test on wpt.live | Open ref on wpt.live | wpt.fyi
/css/CSS2/box-display/block-in-inline-margin-with-line-break-then-block-in-inline.html
<!DOCTYPE html> <title>CSS Test: block-in-inline with line break and trailing block-in-inline collapses margin once</title> <link rel="help" href="https://www.w3.org/TR/CSS21/visuren.html#anonymous-block-level"> <link rel="help" href="https://www.w3.org/TR/CSS21/box.html#collapsing-margins"> <link rel="match" href="block-in-inline-margin-with-line-break-then-block-in-inline-ref.html"> <link rel="stylesheet" type="text/css" href="/fonts/ahem.css"> <meta name="assert" content="A line break between two block-in-inlines does not introduce additional margin advance for the second block."> <style> .container { width: 100px; font: 20px/1 Ahem; } .first { width: 100px; height: 20px; margin-bottom: 40px; background: blue; } .second { width: 100px; height: 20px; background: green; } </style> <p>Blue rectangle, an empty line of 20px, 40px gap, then green rectangle.</p> <div class="container"> <span><div class="first"></div><br></span> <span><div class="second"></div></span> </div>
/css/CSS2/box-display/block-in-inline-margin-with-line-break-then-block-in-inline-ref.html
<!DOCTYPE html> <title>CSS Reference</title> <link rel="stylesheet" type="text/css" href="/fonts/ahem.css"> <style> .container { width: 100px; font: 20px/1 Ahem; } .first { width: 100px; height: 20px; margin-bottom: 40px; background: blue; } .second { width: 100px; height: 20px; background: green; } </style> <p>Blue rectangle, an empty line of 20px, 40px gap, then green rectangle.</p> <div class="container"> <div class="first"></div><br> <div class="second"></div> </div>