vue 自定义轮播组件_针对Vue优化的可自定义轮播滑块

vue 自定义轮播组件

胡珀 (Hooper)

Vue.js carousal component, optimized to work with Vue.

Vue.js旋转组件,经过优化可与Vue一起使用。

入门 (Getting started)

安装 (Installation)

First step is to install it using yarn or npm:

第一步是使用yarnnpm安装它:

npm install hooper

# or use yarn
yarn add hooper

特征 (Features)

  • Touch support

    触控支持

  • Keyboard support

    键盘支持

  • Mouse wheel support

    鼠标滚轮支持

  • Responsive breakpoints

    响应断点

  • Auto play

    自动播放

  • Vertical scroll

    垂直滚动

  • Infinite scroll

    无限滚动

  • Two way control carousels (sync)

    两路控制轮播(同步)

  • Fully customizable using addons

    使用插件完全可定制

  • And even more...

    甚至更多...

使用胡珀 (Use Hooper)

<template>
  <hooper>
    <slide>
      slide 1
    </slide>
    <slide>
      slide 2
    </slide>
    ...
  </hooper>
<template>

<script>
  import { Hooper, Slide } form 'hooper';

  export default {
    name: 'App',
    components: {
      Hooper,
      Slide
    }
  }
</script>

more info at Documentation

更多信息,请参见文档

可用道具 (Available Props)

PropDefaultDescription
itemsToShow1count of items to showed per view (can be a fraction).
itemsToSlide1count of items to slide when use navigation buttons
infiniteScrollfalseenable infinite scrolling mode.
centerModefalseenable center mode
verticalfalseenable vertical sliding mode
rtlfalseenable rtl mode
mouseDragtruetoggle mouse dragging
touchDragtruetoggle touch dragging
wheelControlfalsetoggle mouse wheel sliding
keysControlfalsetoggle keyboard control
shortDragtrueenable any move to commit a slide
autoPlayfalseenable auto sliding to carousal
playSpeed3000speed of auto play to trigger slide in ms
transition300sliding transition time in ms
sync''sync two carousels to slide together
settings{ }an object to pass all settings
Struts 默认 描述
itemsToShow 1个 每个视图显示的项目数(可以是一个分数)。
itemsToSlide 1个 使用导航按钮时要滑动的项目数
infiniteScroll 启用无限滚动模式。
centerMode 启用中心模式
vertical 启用垂直滑动模式
rtl 启用rtl模式
mouseDrag 真正 切换鼠标拖动
touchDrag 真正 切换触摸拖动
wheelControl 切换鼠标滚轮滑动
keysControl 切换键盘控制
shortDrag 真正 启用任何动作即可提交幻灯片
autoPlay 启用自动滑动到旋转
playSpeed 3000 自动播放触发幻灯片的速度(毫秒)
transition 300 滑动过渡时间(以毫秒为单位)
sync '' 同步两个旋转木马一起滑动
settings {} 通过所有设置的对象

翻译自: https://vuejsexamples.com/a-customizable-carousel-slider-optimized-for-vue/

vue 自定义轮播组件

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值