Hover to enlarge animation - HTML CSS CSS Animation

HTML CSS examples for CSS Animation:Size

Description

Hover to enlarge animation

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">

div {<!--from w  w w  .  j  a  va 2 s  .c  o  m-->
   width:100px;
   height:50px;
   -moz-transition:
   width 1s 1s,
   height 1s;
   background: red;
}
div:hover {
   width:400px;
   height:400px;
   -moz-transition:
   width 1s,
   height 1s 1s;
}


      </style> 
 </head> 
 <body> 
  <div></div>  
 </body>
</html>

Related Tutorials