I am trying to slide down a div element. SO I just use:
$("#myBox").addClass("moveDown");
.moveDown {
animation:mymove 1s ease-out forwards;
-webkit-animation:mymove 1s ease-out infinite;
}
@keyframes mymove {
from {top:0px; opacity: 0;}
to {top:100px; opacity: 1}
}
@-webkit-keyframes mymove {
from {top:0px; opacity: 0;}
to {top:100px; opacity: 1;}
}
that works fine: my Box moves smoothly 100px to bottom but when animation has ended, it jumps to its initial position: Any idea on how to achieve that ?
I don't want to use jquery's animate function because it is not smooth enough with jquery.