26 lines
540 B
SCSS
26 lines
540 B
SCSS
.slider-container {
|
|
position: relative;
|
|
overflow: hidden;
|
|
width: 100%;
|
|
}
|
|
|
|
.slider-content {
|
|
display: flex;
|
|
will-change: transform;
|
|
animation: scroll-left infinite linear;
|
|
animation-duration: var(--scroll-speed);
|
|
}
|
|
|
|
.slider-content.paused {
|
|
animation-play-state: paused; /* Pause on hover */
|
|
}
|
|
|
|
@keyframes scroll-left {
|
|
0% {
|
|
transform: translateX(0); /* Start position */
|
|
}
|
|
100% {
|
|
transform: translateX(-100%); /* Move by the full width of the content */
|
|
}
|
|
}
|
|
|