我本意是让元素延迟1秒再执行,现在遇到的问题是加了延迟后,动画已经在执行完的动画的位置,到延迟时间又执行动画,如果不加动画是正常的,谢谢!
.tree_1{ width:150px;
height:150px;
position:absolute;
animation:tree_1 ease-in-out 2s;
animation-delay:1s;}
@keyframes tree_1{
from{ left:-150px;}
to{left:0;}
}
初始位置设置left:-150px;