简体   繁体   中英

Show part of previous and next slide in Swiper

I want to show part of the previous and next slide in swiper, but using config like "slidesPerView: 2.2" always shows part of the next slide but never part of the previous one. See these examples:

First Slide示例1

Second Slide示例2

what i actually want:

示例3

Any ideas?

Btw this question here is related but doesn't give the answer I was looking for: Swiper slides - showing end/start of previous/next slides like Airbnb Slider?

I was having a conflicting config using slidesOffsetBefore and slidesOffsetAfter in conjunction with centeredSlides. centeredSlides works as expected if I remove those and then I am getting the result I described above.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM