亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

VUE 3D輪播圖封裝實(shí)現(xiàn)方法

 更新時間:2018年07月03日 15:24:13   作者:indd  
這篇文章主要為大家詳細(xì)介紹了VUE 3D輪播圖封裝實(shí)現(xiàn)方法,具有一定的參考價值,感興趣的小伙伴們可以參考一下

本文為大家分享了VUE 3D輪播圖封裝的具體代碼,供大家參考,具體內(nèi)容如下

一、體驗(yàn)地址

VUE 3D輪播圖

二、實(shí)現(xiàn)功能點(diǎn)

(1)、無縫輪播
(2)、進(jìn)入變大、離開縮?。?d切換效果)

三、js代碼

<!--輪播圖插件模板-->
<template>

</template>

<script type="text/ecmascript-6">
 import {swiper, swiperSlide} from 'vue-awesome-swiper'
 require('swiper/dist/css/swiper.css');//注意這里
 import Pageination from "./pageination"
 import { mapActions, mapMutations, mapGetters, mapState} from "vuex"
 import {getPriceSymbolValue} from '../../util/tool/index'

 export default {
  //props: ['bannerList'],
  data() {
   let _self=this;
   return {
    pageinationIndex:0,
    data: {
     "bannerList":[]
    },
    swiperOption: {
     loop: true,  // 循環(huán)
     speed:500,  //切換速度
     mousewheelControl: false,// 禁止鼠標(biāo)滾輪切換
     lazy: {
      loadPrevNext: true,
     },
     pagination: {
      el: '.swiper-pagination',
     },
     autoplay: {
      delay:2000,
      stopOnLastSlide: false, // 切換到最后一個時不停止
      disableOnInteraction: false, //用戶操作swiper之后 不停止autoplay
     },
     watchSlidesProgress:true,
     centeredSlides: true, //設(shè)定為true時,活動塊會居中,而不是默認(rèn)狀態(tài)下的居左。
     spaceBetween:10,
     slidesPerView: 1.7,
     loopedSlides :2,
     observer: true,
     observeParents: true
    }
   }
  },
  methods: {
  },
  mounted() {
   // 這邊就可以使用swiper這個對象去使用swiper官網(wǎng)中的那些方法
//   this.$nextTick(function() {
//    this.swiper.slideTo(3, 10, false);
//   });
  },
  computed: {
   swiper() {
    return this.$refs.mySwiper.swiper
   }
  },
  components: {
   swiper,
   swiperSlide,
   Pageination
  }
 }
</script>

<style lang="scss" type="text/scss">

</style>

以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。

相關(guān)文章

最新評論