效果:
代码:
动画的样式
// 动画
.animation-enter,
animation-leave-to {
transform: translateX(50px);
opacity: 0;
}
.animation-enter-active {
transition: all 0.5s ease-in-out;
}
.animation-enter-to,
animation-leave {
transform: translateX(0);
opacity: 1;
}