我正在使用vue-awesome-swiper,每张幻灯片显示几张图片。可能是什么原因?
这是我的哈巴狗:
.worklist_block-background
swiper.gallery-top(:options ='swiperOptionTop',ref ='swiperTop')
swiper-slide(swiperItems中的v-for ='(item,idx)':key ='idx':class = 'slide-'+(idx+1)
)
img(:src ='item.bigImage')
.worklist_block-small
swiper.gallery-thumbs(:options ='swiperOptionThumbs',ref ='swiperThumbs')
swiper-slide.swiper__thumb-position(swiperItems中的v-for ='(item,idx)':key ='idx':class = 'slide-'+(idx+1)
)
img(:src ='item.smallImage')
.swiper-button-next(slot ='button-next')
.swiper-button-prev(slot ='button-prev')
和我的数据()
data: () => ({
swiperOptionTop: {
setWrapperSize: true,
},
swiperOptionThumbs: {
spaceBetween: 10,
centeredSlides: true,
slidesPerView: "auto",
touchRatio: 0.2,
slideToClickedSlide: true,
observeParents: true,
centeredSlides: true,
navigation: {
nextEl: ".swiper-button-next",
prevEl: ".swiper-button-prev",
},
},