Swipe 轮播图

轮播图,可自定义轮播时间间隔等


例子

基本用法

<Swipe :auto="3600">
  <Swipe-item> 1 </Swipe-item>
  <Swipe-item> 2 </Swipe-item>
  <Swipe-item> 3 </Swipe-item>
</Swipe>

取消自动播放

<Swipe :auto="0">
  <Swipe-item> 1 </Swipe-item>
  <Swipe-item> 2 </Swipe-item>
  <Swipe-item> 3 </Swipe-item>
</Swipe>

API

参数说明类型可选值默认值
speed动画持时(毫秒)Number400
auto自动播放的时间间隔(毫秒), 为 0 时关闭自动轮播Number3000
startSlide初始显示的轮播图的索引Number0
continuous是否可以循环播放Booleantrue
isShowIndicators是否显示indicatorsBooleantrue
stopPropagation是否在 touchstart 事件触发时阻止冒泡。Booleantrue

Slot

Swipe

name描述
-一个或多个 Swipe-item 组件

Swipe-item

name描述
-单个轮播图的内容