CSS
语言:
CSSSCSS
确定
*,
*:before,
*:after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
margin-top: 50px;
overflow: hidden;
}
ul {
list-style-type: none;
width: 110%;
height: 500px;
overflow: hidden;
padding: 0;
background: #08f;
animation: current 2s linear infinite;
}
ul:after {
content: "";
clear: both;
display: table;
}
li {
float: left;
width: 10%;
height: 20px;
margin: 0 -1% 31px 0;
border-radius: 0 0 50% 50%;
background: #fff;
animation: waves 2s linear infinite;
}
li:first-of-type {
margin-left: 0;
}
@keyframes current {
0% {
margin-left: 0%;
}
100% {
margin-left: -10%;
}
}
@keyframes waves {
0% {
height: 20px;
border-radius: 0 0 50% 50%;
}
50% {
height: 30px;
border-radius: 0 0 0% 0%;
}
100% {
height: 20px;
border-radius: 0 0 50% 50%;
}
}