transition-property-004-manual.html (1075B)
1 <!DOCTYPE html> 2 <meta charset="utf-8"> 3 <title>CSS Transitions Test: transition-property - all</title> 4 <link rel="author" title="Intel" href="http://www.intel.com"> 5 <link rel="author" title="Shiyou Tan" href="mailto:shiyoux.tan@intel.com"> 6 <link rel="help" title="2.1. The 'transition-property' Property" href="http://www.w3.org/TR/css3-transitions/#transition-property-property"> 7 <meta name="assert" content="The 'transition-duration' property set 'all' means that all properties are transitioned."> 8 <style> 9 #test { 10 background-color: blue; 11 height: 100px; 12 transition-duration: 2s; 13 transition-property: all; 14 transition-timing-function: linear; 15 width: 100px; 16 } 17 </style> 18 <body> 19 <p>Click the blue square below. Test passes if both height and width of blue square grow smoothly.</p> 20 <div id="test"></div> 21 <script> 22 (function() { 23 var div = document.querySelector("#test"); 24 div.addEventListener("click", function(evt) { 25 div.setAttribute("style", "height: 200px; width: 200px;"); 26 }, false); 27 })(); 28 </script> 29 </body>