Html CSS transitions area unit effects

 

The CSS transitions area unit effects that area unit additional to vary the component step by step from one vogue to a different, while not victimisation flash or JavaScript.

You should specify 2 things to form CSS transition.
1.The CSS property on that you wish to feature an impact.
2.The time length of the impact.

Example of Animation:

<!DOCTYPE html>
<html>
<head>
<style>
div.test1 {
width: 100px;
height: 100px;
background: #E88CEE; -webkit-transition: width 1s;
transition-duration:3s;
  }
div.test1:hover {
width: 100%;
background: #9A0E87;
}
div.test2 {
width: 100px;
height: 100px;
background: #899CDD; -webkit-transition: width 1s;
transition-duration:3s;
  }
div.test2:hover {
width: 80%;
background: #1759DF;
}
div.test3 {
width: 100px;
height: 100px;
background: #ADF29B;
-webkit-transition: width 1s;
transition-duration:3s;
  }
div.test3:hover {
width: 60%;
background: #1FA720;
}
</style>
</head>
<body>
<p>Move or Tap the cursor over the div element above, to see the transition effect.</p>
<div class="test1">Html 100%
</div>
<br>
<div class="test2">Css 60%
</div>
<br>
<div class="test3">Javascript 40%
</div>
</body>
</html>


Tags

Post a Comment

0 Comments
* Please Don't Spam Here. All the Comments are Reviewed by Admin.