console
<div class="outer">
<div class="img-container">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/1.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/2.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/3.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/4.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/5.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/6.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/7.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/1.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/2.jpg" alt="">
<img src="https://hjd6633.oss-cn-hangzhou.aliyuncs.com/notes/html_css/merry-go-round/3.jpg" alt="">
</div>
</div>
*{
margin: 0;
padding: 0;
border: none;
}
body{
background-color: white;
}
img{
width: 480px;
}
.outer{
width: 1440px;
height: 270px;
border: 10px solid blue;
}
.img-container{
width: 3360px;
height: 270px;
outline: 1px solid green;
display: flex;
}
.img-container{
transform: translateX(0);
transform: translateX(-3360px);
}
@keyframes carresole {
0% { transform: translateX(0);}
100% { transform: translateX(-3360px);}
}
.img-container{
animation: carresole 8s linear infinite;
}
.img-container:hover{
animation-play-state: paused;
}
.outer{
overflow: hidden;
}