/***************css3 实现页面从左右两侧进入效果 start****************/
div{
/**0.5s是时间可设置多个**/
animation: bounceInLeft 0.5s 0.25s linear forwards;
}
@keyframes bounceInLeft {
from, 60%, 75%, 90%, to {animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);}
0% {opacity: 0;transform: translate3d(-3000px, 0, 0);}
60% {opacity: 1;transform: translate3d(25px, 0, 0);}
75% {transform: translate3d(-10px, 0, 0);}
90% {transform: translate3d(5px, 0, 0);}
100% {opacity: 1;transform: none;}
}
@keyframes bounceInRight {
from, 60%, 75%, 90%, to {animation-timing-function: cubic-bezier(0.215, 0.610, 0.355, 1.000);}
0% {opacity: 0;transform: translate3d(3000px, 0, 0);}
60% {opacity: 1;transform: translate3d(-25px, 0, 0);}
75% {transform: translate3d(10px, 0, 0);}
90% {transform: translate3d(-5px, 0, 0);}
100% {opacity: 1;transform: none;}
}
/***************css3 实现页面从左右两侧进入效果 end****************/
参考:https://blog.csdn.net/a419419/article/details/79151256