| OLD | NEW |
| (Empty) | |
| 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/x
html1/DTD/xhtml1-strict.dtd"> |
| 2 |
| 3 <html xmlns="http://www.w3.org/1999/xhtml"> |
| 4 |
| 5 <head> |
| 6 |
| 7 <title>CSS Test: margin collapsing - child has no clearance</title> |
| 8 |
| 9 <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserB
ugsSection/css21testsuite/" /> |
| 10 <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins"
/> |
| 11 <link rel="match" href="margin-collapse-031-ref.xht" /> |
| 12 |
| 13 <meta name="flags" content="" /> |
| 14 <meta name="assert" content="The top margin of an in-flow block-level element
is adjoining to its first in-flow block-level child's top margin if the element
has no top border, no top padding, and the child has no clearance." /> |
| 15 |
| 16 <style type="text/css"><![CDATA[ |
| 17 body |
| 18 { |
| 19 background-color: white; |
| 20 margin: 8px; |
| 21 } |
| 22 |
| 23 div#parent-block-container |
| 24 { |
| 25 background-color: red; |
| 26 margin: 0px; |
| 27 width: 100%; |
| 28 } |
| 29 |
| 30 div#child-block |
| 31 { |
| 32 background-color: green; |
| 33 color: white; |
| 34 margin: 100px 0px; |
| 35 } |
| 36 ]]></style> |
| 37 |
| 38 </head> |
| 39 |
| 40 <body> |
| 41 |
| 42 <div id="parent-block-container"> |
| 43 <div id="child-block"> |
| 44 Test passes if there is <strong>no red</strong>. |
| 45 </div> |
| 46 </div> |
| 47 |
| 48 </body> |
| 49 </html> |
| OLD | NEW |