<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
/* 动画的声明 */
@keyframes move {
0% {
transform: translate(0, 0);
}
25% {
transform: translate(500px, 0);
}
50% {
transform: translate(500px, 500px);
}
75% {
transform: translate(0px, 500px);
}
100% {
transform: translate(0px, 0px);
}
}
div {
width: 200px;
height: 200px;
background-color: pink;
/* 调用动画 的名称 */
animation-name: move;
/* 调用动画的时间 */
animation-duration: 10s;
}
</style>
</head>
<body>
<div></div>
</body>
</html>
动画序列-5个状态
最新推荐文章于 2023-09-02 10:59:14 发布