动画图
<!!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>动画图</title>
</head>
<style type="text/css">
.content{
width: 300px;
height: 125px;
border: 1px solid #C00000;
margin: 200px auto 0;
}
.content p{
text-align: center;
width: 100%;
}
.content div{
width: 30px;
height: 70px;
float: left;
background-color: lilac;
margin: 15px;
border-radius: 10px;
}
.content div:nth-child(1) {
background-color: red;
animation: loading 500ms ease 0s infinite alternate;
}
.content div:nth-child(2){
background-color: pink;
animation: loading 500ms ease 100ms infinite alternate;
}
.content div:nth-child(3){
background-color: purple;
animation: loading 500ms ease 200ms infinite alternate;
}
.content div:nth-child(4){
background-color: green;
animation: loading 500ms ease 300ms infinite alternate;
}
.content div:nth-child(5){
background-color: gray;
animation: loading 500ms ease 400ms infinite alternate;
}
@keyframes loading{
from{
transform: scaleY(1);
}
to{
transform: scaleY(0.5);
}
}
</style>
<body>
<div class="content">
<div></div>
<div></div>
<div></div>
<div></div>
<div></div>
<p>dopgde..</p>
</body>
</html>
网友评论