<body>
<h2>Keyframe μμ보기</h2>
<div class="box"></div>
<ul class="progress">
<li></li>
</ul>
</body>
<style>
@keyframes{}
@-o-keyframes{}
@-ms-keyframes{}
@-moz-keyframes{}
@-webkit-keyframes{}
@keyframes myAni{
0%{
width: 200px;
height: 200px;
transform: rotate(0deg);
}
50%{
width: 400px;
width: 400px;
transform: rotate(180deg);
}
100%{
width: 200px;
height: 200px;
transform: rotate(0deg);
}
}
.box{
width: 300px; height: 300px;
background-color: #99f;
transition-property: width, background-color;
transition-duration: 0.3s;
animation-name: myAni;
animation-duration: 3s;
animation-iteration-count: infinite;
animation-play-state: paused;
}
.box:hover{
width: 400px;
}
.box:active{
background-color: #f00;
}
@keyframes myProg{
0%{
width: 0%;
}
100%{
width: 90%;
}
}
.progress{
padding: 0; margin: 0; list-style: none;
width: 600px;
background-color: #ccc;
border-radius: 10px;
}
.progress li{
width: 1000%;
height: 30px;
background-color: #f60;
border-radius: 20px;
border: 4px solid #ccc;
box-sizing: border-box;
animation-name: myProg;
animation-duration: 3s;
animation-fill-mode: forwards;
//animation-timing-function: cubic-bezier(0,2.03,1,-0.65);
}
</style>