layout/reftests/w3c-css/submitted/ui3/box-sizing-padding-box-003-ref.xht

Fri, 16 Jan 2015 18:13:44 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Fri, 16 Jan 2015 18:13:44 +0100
branch
TOR_BUG_9701
changeset 14
925c144e1f1f
permissions
-rw-r--r--

Integrate suggestion from review to improve consistency with existing code.

     1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
     2 <html xmlns="http://www.w3.org/1999/xhtml">
     3  <head>
     4   <title>CSS Reference: Box Sizing - Padding-Box with min/max width/height</title>
     5   <link rel="author" title="Scott Johnson" href="mailto:sjohnson@mozilla.com" />
     6   <style type="text/css"><![CDATA[
     7     .container {
     8       width: 500px;
     9       height: 70px;
    10       border: 2px solid black;
    11       position: absolute;
    12       left: 25px;
    13       top: 25px;
    14       background-color: red;
    15     }
    17     .box-sized {
    18       height: calc(100% - 10px);
    19       width: calc(50% - 10px);
    20       z-index: 1;
    21       float: left;
    22       padding: 5px 5px;
    23     }
    25     #one {
    26       background-color: green;
    27     }
    29     #two {
    30       background-color: blue;
    31     }
    32   ]]></style>
    33  </head>
    34  <body>
    35    The two divs should be side-by-side, not one on top of another. No red should be visible.
    36    <br />
    37    <div class="container">
    38      <div class="box-sized" id="one">LEFT HALF</div>
    39      <div class="box-sized" id="two">RIGHT HALF</div>
    40    </div>
    41  </body>
    42 </html>

mercurial