刷卡器,无法使画廊的手指移动如何修复?

问题描述 投票:0回答:1

按需显示大拇指图片,但大拇指本身不动,我的大拇指比显示的要多,当我点击大拇指时,她必须像单击下一个按钮一样移动**

let galleryThumbs = new Swiper('.gallery-thumbs', {
    spaceBetween: 10,
    slidesPerView: 2,
    loop: true,
    freeMode: false,
    watchSlidesVisibility: true,
    watchSlidesProgress: true,
    slideToClickedSlide: true,
    loopedSlides: 5
});
let galleryTop = new Swiper('.gallery-top', {
    spaceBetween: 10,
    loopedSlides: 5,
    loop:true,
    thumbs: {
      swiper: galleryThumbs,
    },
});

这是我的html(呈现简单的swiper-slide)

 <div class="swiper-container gallery-top">
    <div class="swiper-wrapper">
            [[getImageList?
              &docid=`[[*id]]`
              &limit=`0`
              &tvname=`img-slider`
              &tpl=`@CODE: <div class="swiper-slide"><img src="/[[+home_img]]" alt="[[*pagetitle]]"></div>`
            ]]
    </div>
  </div>
  <div class='swiper-container gallery-thumbs'>
    <div class="swiper-wrapper">
        [[getImageList?
          &docid=`[[*id]]`
          &limit=`0`
          &tvname=`img-slider`
          &tpl=`@CODE: <div class="swiper-slide"><div class="small_body"><img src="/[[+home_img]]" alt="[[*pagetitle]]"></div></div>`
        ]] 
    </div>  
</div>
javascript html swiper
1个回答
0
投票

Easy bro_))将此行添加到代码中,并将其移动! galleryTop.controller.control = galleryThumbs;

© www.soinside.com 2019 - 2024. All rights reserved.