<!DOCTYPE html>
<html lang="en-US">
<head>
<style>
div{
width: 100px;
height: 100px;
line-height: 5;
text-align: center;
border: 1px solid #000;
background: #39ac39;
-webkit-animation: myAnimation 1s infinite; /* Safari 4.0 - 8.0 */
animation: myAnimation 1s infinite;
-webkit-animation-direction: alternate; /* Safari 4.0 - 8.0 */
animation-direction: alternate;
}
#point{
-webkit-animation-timing-function: linear;
animation-timing-function: linear;
}
#point1{
-webkit-animation-timing-function: ease;
animation-timing-function: ease;
}
#point2{
-webkit-animation-timing-function: ease-in;
animation-timing-function: ease-in;
}
#point3{
-webkit-animation-timing-function: ease-out;
animation-timing-function: ease-out;
}
#point4{
-webkit-animation-timing-function: ease-in-out;
animation-timing-function: ease-in-out;
}
#point5{
-webkit-animation-timing-function: steps(infinite, jump-both);
animation-timing-function: steps(infinite, jump-both);
}
#point6{
-webkit-animation-timing-function: cubic-bezier(0.83, 2.3, 0.31, 0.46);
animation-timing-function: cubic-bezier(0.83, 2.3, 0.31, 0.46);
}
@-webkit-keyframes myAnimation {
from {border-radius: 0%; background: #f69d3c;}
to {border-radius: 50%; background: #0066ff}
}
@keyframes myAnimation {
from {border-radius: 0%; background: #f69d3c;}
to {border-radius: 50%; background: #0066ff}
}
</style>
</head>
<body>
<h1>CSS animation-timing-function Property</h1>
<h2>animation-timing-function: linear;</h2>
<div id="point">
div
</div>
<h2>animation-timing-function: ease;</h2>
<div id="point1">
div
</div>
<h2>animation-timing-function: ease-in;</h2>
<div id="point2">
div
</div>
<h2>animation-timing-function: ease-out;</h2>
<div id="point3">
div
</div>
<h2>animation-timing-function: ease-in-out;</h2>
<div id="point4">
div
</div>
<h2>animation-timing-function: steps(infinite, jump-both);</h2>
<div id="point5">
div
</div>
<h2>animation-timing-function: cubic-bezier(0.83, 2.3, 0.31, 0.46);</h2>
<div id="point6">
div
</div> </body>
</html>