OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE HTML> |
| 2 <style> |
| 3 body { |
| 4 -webkit-transform: translateZ(0); |
| 5 } |
| 6 #overlapper { |
| 7 width: 400px; |
| 8 height: 400px; |
| 9 left: 200px; |
| 10 background: gray; |
| 11 position: absolute; |
| 12 -webkit-transform: translateZ(0); |
| 13 } |
| 14 |
| 15 #container { |
| 16 -webkit-perspective: 1400px; |
| 17 -webkit-transform: translateZ(0); |
| 18 position: absolute; |
| 19 width: 180px; |
| 20 height: 180px; |
| 21 background: papayawhip; |
| 22 } |
| 23 |
| 24 #composited { |
| 25 width: 100px; |
| 26 height: 100px; |
| 27 background: green; |
| 28 position: absolute; |
| 29 -webkit-transform: translateZ(10px); |
| 30 } |
| 31 |
| 32 #squashed { |
| 33 position: absolute; |
| 34 left: 200px; |
| 35 width: 50px; |
| 36 height: 50px; |
| 37 background: blue; |
| 38 } |
| 39 </style> |
| 40 <div id="overlapper"></div> |
| 41 <div id="container"> |
| 42 <div id="composited"></div> |
| 43 </div> |
| 44 <div id="squashed"></div> |
| 45 |
OLD | NEW |