Y
Y
Yashka Gypsy2021-06-02 21:07:10
css
Yashka Gypsy, 2021-06-02 21:07:10

How to make a custom slider (carousel) outside the container?

I am learning to type. I can't figure out how the slider is implemented (in the attached image): it obviously goes beyond the container and displays images in a non-standard way. There are 3 images in total. I use the swiper plugin, is it possible to do it with its help (and how?) or do I need a different solution?

60b7c88f57838872627523.png

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
inkShio, 2021-06-02
@Ya_Gypsy

This is the standard in swiper

.swiper-container {
  overflow: hidden;
}

you have to do it
.swiper-container {
  overflow: visible;
}

and add to the parent
.slider {
  overflow: hidden;
}

<div class="slider">
  <div class="slider__container swiper-container">
    <div class="slider__list swiper-wrapper">
      <div class="slider__item swiper-slide">Slide 1</div>
      <div class="slider__item swiper-slide">Slide 2</div>
      <div class="slider__item swiper-slide">Slide 3</div>
    </div>
  </div>
</div>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question