box-sizing-026.html (781B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Basic User Interface Test: box-sizing:border-box floors to 0</title> 4 <link rel="author" title="Florian Rivoal" href="http://florian.rivoal.net/"> 5 <link rel="help" href="https://drafts.csswg.org/css-ui-3/#box-sizing"> 6 <link rel="match" href="../reference/ref-filled-green-100px-square.xht"> 7 <meta name="assert" content="Floor width and height computation to 0 as they cannot be negative."> 8 <style> 9 #red { 10 position: absolute; 11 width: 100px; 12 height: 100px; 13 background:red; 14 z-index: -1; 15 } 16 #test { 17 box-sizing: border-box; 18 border: 50px green solid; 19 width: 10px; 20 height: 10px; 21 } 22 </style> 23 <body> 24 <p>Test passes if there is a filled green square and <strong>no red</strong>.</p> 25 <div id=red></div> 26 <div id=test></div> 27 </body>