| OLD | NEW | 
 | (Empty) | 
|   1 <!DOCTYPE html> |  | 
|   2 <html> |  | 
|   3 <head> |  | 
|   4 <script src='../resources/simple-rectangle.js'></script> |  | 
|   5 <style id='stylesheet'> |  | 
|   6 .content { |  | 
|   7     font: 50px/1 Ahem, sans-serif; |  | 
|   8     color: green; |  | 
|   9     word-break: break-all; |  | 
|  10     width: 100px; |  | 
|  11     height: 100px; |  | 
|  12     margin: 0; |  | 
|  13     padding: 0; |  | 
|  14 } |  | 
|  15 #inline-block * { |  | 
|  16     display: inline-block; |  | 
|  17 } |  | 
|  18 #float * { |  | 
|  19     float: left; |  | 
|  20 } |  | 
|  21 #list ul { |  | 
|  22     display: inline-block; |  | 
|  23     list-style: none; |  | 
|  24 } |  | 
|  25 #table table { |  | 
|  26     display: inline-table; |  | 
|  27     border-collapse: collapse; |  | 
|  28 } |  | 
|  29 #table tr { |  | 
|  30     dispay: inline-table; |  | 
|  31 } |  | 
|  32 #table td, #table tr { |  | 
|  33     padding: 0; margin: 0; |  | 
|  34 } |  | 
|  35 #old-flexbox * { |  | 
|  36     display: -webkit-inline-box; |  | 
|  37 } |  | 
|  38 #new-flexbox * { |  | 
|  39     display: -webkit-inline-flex; |  | 
|  40 } |  | 
|  41 </style> |  | 
|  42 <script> |  | 
|  43 window.onload = function() { |  | 
|  44     var elementBounds = { width: 200, height: 200 }; |  | 
|  45     var shapeBounds = { x: 50, y: 50, width: 100, height: 100 }; |  | 
|  46     createRectangleTest('inline-block', 'stylesheet', elementBounds, shapeBounds
    , 'px'); |  | 
|  47     createRectangleTest('float', 'stylesheet', elementBounds, shapeBounds, 'px')
    ; |  | 
|  48     createRectangleTest('list', 'stylesheet', elementBounds, shapeBounds, 'px'); |  | 
|  49     createRectangleTest('table', 'stylesheet', elementBounds, shapeBounds, 'px')
    ; |  | 
|  50     createRectangleTest('old-flexbox', 'stylesheet', elementBounds, shapeBounds,
     'px'); |  | 
|  51     createRectangleTest('new-flexbox', 'stylesheet', elementBounds, shapeBounds,
     'px'); |  | 
|  52 } |  | 
|  53 </script> |  | 
|  54 </head> |  | 
|  55 <body> |  | 
|  56 <p>This set of tests ensures that basic recursive layouts with inline-block elem
    ents |  | 
|  57 function correctly with shape-inside. They require the Ahem font, and should eac
    h display |  | 
|  58 a green square within a blue border.</p> |  | 
|  59  |  | 
|  60 <p>Inline-block div</p> |  | 
|  61 <div id='inline-block'> |  | 
|  62     <div class='content'>xxxx</div> |  | 
|  63 </div> |  | 
|  64  |  | 
|  65 <p>Floating div</p> |  | 
|  66 <div id='float'> |  | 
|  67     <div class='content'>xxxx</div> |  | 
|  68 </div> |  | 
|  69  |  | 
|  70 <p>Inline list</p> |  | 
|  71 <div id='list'> |  | 
|  72     <ul class='content'> |  | 
|  73         <li>xx</li> |  | 
|  74         <li>xx</li> |  | 
|  75     </ul> |  | 
|  76 </div> |  | 
|  77  |  | 
|  78 <p>Inline table</p> |  | 
|  79 <div id='table'> |  | 
|  80     <table class='content'> |  | 
|  81         <tr><td>x</td><td>x</td></tr> |  | 
|  82         <tr><td>x</td><td>x</td></tr> |  | 
|  83     </table> |  | 
|  84 </div> |  | 
|  85  |  | 
|  86 <p>Old flexbox</p> |  | 
|  87 <div id='old-flexbox'> |  | 
|  88     <div class='content'>xxxx</div> |  | 
|  89 </div> |  | 
|  90  |  | 
|  91 <p>New flexbox</p> |  | 
|  92 <div id='new-flexbox'> |  | 
|  93     <div class='content'>xxxx</div> |  | 
|  94 </div> |  | 
|  95 </body> |  | 
|  96 </html> |  | 
| OLD | NEW |