OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <link href="resources/flexbox.css" rel="stylesheet"> |
| 3 <style> |
| 4 .horizontal { |
| 5 height: 100px; |
| 6 background-color: purple; |
| 7 position: relative; |
| 8 } |
| 9 |
| 10 .vertical { |
| 11 width: 100px; |
| 12 background-color: purple; |
| 13 position: relative; |
| 14 -webkit-writing-mode: vertical-rl; |
| 15 } |
| 16 |
| 17 .flex-one { |
| 18 background-color: red; |
| 19 } |
| 20 </style> |
| 21 <script src="../../resources/check-layout.js"></script> |
| 22 <script> |
| 23 function changeHeight() |
| 24 { |
| 25 document.getElementById('dynamicHorizontalChild').style.height = "90%"; |
| 26 document.getElementById('dynamicVerticalChild').style.width = "30%"; |
| 27 checkLayout('.flexbox'); |
| 28 checkLayout('.flexbox'); |
| 29 } |
| 30 </script> |
| 31 <body onload="changeHeight()"> |
| 32 <div class="flexbox horizontal"> |
| 33 <div data-expected-height="100" class="flex-one"> |
| 34 <div data-expected-height="70" style="height:70%; background-color:lime">Hor
izontal Writing Mode</div> |
| 35 </div> |
| 36 </div> |
| 37 |
| 38 <div class="flexbox vertical"> |
| 39 <div data-expected-width="100" class="flex-one"> |
| 40 <div data-expected-width="50" style="width: 50%; background-color:lime">Vert
ical Writing Mode</div> |
| 41 </div> |
| 42 </div> |
| 43 |
| 44 <div class="flexbox horizontal"> |
| 45 <div data-expected-height="100" class="flex-one"> |
| 46 <div id="dynamicHorizontalChild" data-expected-height="90" style="height:70%
; background-color:lime">Horizontal Writing Mode</div> |
| 47 </div> |
| 48 </div> |
| 49 |
| 50 <div class="flexbox vertical"> |
| 51 <div data-expected-width="100" class="flex-one"> |
| 52 <div id="dynamicVerticalChild" data-expected-width="30" style="width: 50%; b
ackground-color:lime">Vertical Writing Mode</div> |
| 53 </div> |
| 54 </div> |
| 55 |
| 56 <div class="flexbox horizontal"> |
| 57 <div data-expected-height="100" class="flex-one" style="padding:10px; border:2
px solid black"> |
| 58 <div data-expected-height="53" style="height:70%; background-color:lime">Hor
izontal Writing Mode</div> |
| 59 </div> |
| 60 </div> |
| 61 |
| 62 <div class="flexbox vertical"> |
| 63 <div data-expected-width="100" class="flex-one" style="padding:10px; border:2p
x solid black"> |
| 64 <div data-expected-width="38" style="width: 50%; background-color:lime">Vert
ical Writing Mode</div> |
| 65 </div> |
| 66 </div> |
| 67 |
| 68 <div class="flexbox horizontal"> |
| 69 <img data-expected-height="50" style="max-height:50%" src="../images/resources
/green-10.png" /> |
| 70 </div> |
| 71 |
| 72 <div class="flexbox vertical"> |
| 73 <img data-expected-width="50" style="max-width:50%" src="../images/resources/g
reen-10.png" /> |
| 74 </div> |
| 75 |
| 76 <div class="flexbox horizontal"> |
| 77 <div data-expected-height="50" class="flex-one" style="max-height:50%"> |
| 78 <div data-expected-height="25" style="height:50%; background-color:lime">Hor
izontal Writing Mode</div> |
| 79 </div> |
| 80 </div> |
| 81 |
| 82 <div class="flexbox vertical"> |
| 83 <div data-expected-width="50" class="flex-one" style="max-width:50%"> |
| 84 <div data-expected-width="25" style="width: 50%; background-color:lime">Vert
ical Writing Mode</div> |
| 85 </div> |
| 86 </div> |
| 87 </body> |
OLD | NEW |