Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!DOCTYPE html> | |
| 2 <style> | |
| 3 html, body { | |
| 4 margin: 0; | |
| 5 } | |
| 6 | |
| 7 #flexbox { | |
| 8 display: flex; | |
| 9 flex-direction: column; | |
| 10 } | |
| 11 | |
| 12 #flexitem { | |
| 13 outline: 1px solid black; | |
| 14 width: 100%; | |
| 15 height: 166px; | |
| 16 position: relative; | |
| 17 background: green; | |
| 18 } | |
| 19 | |
| 20 #abspos { | |
| 21 position: absolute; | |
| 22 } | |
| 23 | |
| 24 #container { | |
| 25 background: red; | |
| 26 } | |
| 27 </style> | |
| 28 | |
| 29 <script src="../../resources/testharness.js"></script> | |
| 30 <script src="../../resources/testharnessreport.js"></script> | |
| 31 | |
| 32 <script> | |
| 33 function runTest() { | |
| 34 test(function() { | |
| 35 assert_equals(document.getElementById('flexbox').offsetWidth, | |
| 36 document.getElementById('flexitem').offsetWidth); | |
| 37 }, "sizes"); | |
| 38 } | |
| 39 </script> | |
| 40 | |
| 41 <body onload="runTest()"> | |
| 42 <div id="container"> | |
| 43 <div id="flexbox"> | |
| 44 <div id="flexitem"> | |
| 45 <div id="abspos"> | |
| 46 <svg></svg> | |
| 47 </div> | |
| 48 </div> | |
| 49 </div> | |
| 50 </div> | |
| 51 | |
| OLD | NEW |