tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

margin-collapse-015a.xht (1739B)


      1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
      2 
      3 <html xmlns="http://www.w3.org/1999/xhtml">
      4 
      5  <head>
      6 
      7   <title>CSS Test: Margin collapsing - inline-block child does not collapse margins with parent</title>
      8 
      9   <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
     10   <link rel="reviewer" title="Arron Eicholz" href="arronei(at)gmail.com" /> <!-- 2013-07-30 -->
     11   <link rel="help" href="http://www.w3.org/TR/CSS21/box.html#collapsing-margins" />
     12   <link rel="match" href="margin-collapse-002-ref.xht" />
     13 
     14   <meta name="flags" content="ahem image" />
     15   <meta name="assert" content="An element with its display set to 'inline-block' does not collapse its margins with its children." />
     16 
     17   <link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
     18   <style type="text/css"><![CDATA[
     19   div
     20   {
     21   font: 20px/1 Ahem;
     22   width: 5em;
     23   }
     24 
     25   div#wrapper
     26   {
     27   background-image: url("support/margin-collapse-2em-space.png");
     28   height: 4em;
     29   }
     30 
     31   div#inline-block
     32   {
     33   display: inline-block;
     34   margin-bottom: 2.5em;
     35   vertical-align: bottom;
     36   }
     37 
     38   div#block-child-of-inline-block
     39   {
     40   display: block;
     41   margin-bottom: 3.5em;
     42   margin-top: 0.5em;
     43   }
     44 
     45   div#wrapper div {background-color: green;}
     46 
     47   div#inline-block, div#block-child-of-inline-block {height: 0.5em;}
     48 
     49   div#following-sibling-after-inline-block {height: 1em;}
     50   ]]></style>
     51 
     52  </head>
     53 
     54  <body>
     55 
     56   <p>Test passes if there is <strong>no red</strong>.</p>
     57 
     58   <div id="wrapper">
     59       <div id="inline-block">
     60           <div id="block-child-of-inline-block"></div>
     61       </div>
     62       <div id="following-sibling-after-inline-block"></div>
     63   </div>
     64 
     65  </body>
     66 </html>