fly63前端网

www.fly63.com

首页文章资源工具教程 栏目
  • 关于我们
  • 网站投稿
  • 赞助一下
搜索

在线工具_工作生活好帮手

打造各种简单、易用、便捷的在线工具,网友无需注册和下载安装即可使用

点击查看

关闭

提交网站

Waterwheel-Carousel
分享
复制链接
新浪微博
QQ 好友

扫一扫分享

网站地址:https://github.com/bkosborne/jQuery-Waterwheel-Carousel
GitHub:https://github.com/bkosborne/jQuery-Waterwheel-Carousel
网站描述:一款jquery 3d Carousel轮播图插件

jjquery-Waterwheel-Carousel是一款jquery 3d Carousel轮播图插件。该jquery Carousel轮播图插件兼容ie8浏览器,提供丰富的参数和api方法由于控制Carousel,使用简单,非常实用。


jQuery-Waterwheel-Carousel特点

  • 支持水平或垂直Carousel轮播。
  • 可以通过键盘来控制前后轮播。
  • 图片移动时提供回调函数钩子。
  • 支持不同尺寸的图片。
  • 支持图片边部透明效果。
  • 支持无缝滚动。
  • 兼容Chrome, FireFox, Safari 和 IE7+浏览器。


使用方法

在页面中引入jquery和jquery.waterwheelCarousel.min.js文件。

<script src="js/jquery.min.js"></script>                          
<script src="js/jquery.waterwheelCarousel.min.js"></script>


 html结构

使用一个<div>来作为容器,里面放置一组图片。

<div id="carousel">
  <img src="/image1.jpg" alt="Image 1" />
  <img src="/image2.jpg" alt="Image 2" />
  <img src="/image3.jpg" alt="Image 3" />
  <img src="/image4.jpg" alt="Image 4" />
  <img src="/image5.jpg" alt="Image 5" />
</div>


 css样式

为carousel指定下面的CSS样式。

<style type="text/css">
  #carousel {
    width:800px;
    height: 300px;
    display: relative;
  }
  #carousel img {
    display: hidden; /* hide images until carousel prepares them */
    cursor: pointer; /* not needed if you wrap carousel items in links */
  }
</style>


 初始化插件

在页面dom元素加载完毕之后,通过下面的方法来初始化该Carousel轮播图插件。

$(document).ready(function() {
    $("#carousel").waterwheelCarousel({
      // include options like this:
      // (use quotes only for string values, and no trailing comma after last option)
      // option: value,
      // option: value
    });
  });


 配置参数

该jquery Carousel轮播图插件的可用配置参数有:

参数类型默认值描述
largeFeatureWidthinteger0可取3个种值。0表示原始图片宽度。0-1之间的数表示原始图片乘以该数值。大于1的数表示使用该数值作为图片的宽度。
largeFeatureHeightinteger0和largeFeatureWidth参数的意义相同。
smallFeatureWidthinteger0.5可取3种值。0表示原始图片的一半。0-1之间表示原始图片乘以该数值。大于1的数值表示使用该数值作为图片的宽度。
smallFeatureHeightinteger0.5和smallFeatureWidth参数的意义相同。
topPaddinginteger20容器顶部到Carousel边部的内边距。
sidePaddinginteger50容器左右边部到Carousel边部的内边距。
smallFeatureOffsetinteger50容器顶部到Carousel边部的补白。
startingFeatureinteger1标示那副图片在初始化时显示在中间。
carouselSpeedinteger1000Carousel的旋转速度,单位毫秒。
autoPlayinteger4000如果数值大于0,将使用该数值作为自动播放的速度。
pauseonHoverbooleantrue是否在鼠标hover是停止自动播放。
stopOnHoverbooleanfalse如果设置了autoplay参数可用,该参数设置为true时,当鼠标hover图片时停止自动播放。
trackerIndividualbooleantrue是否显示跟踪信息。
trackerSummationbooleantruea summation of the features can also be used to display an "x Of y" style of tracking this can be combined with the above option as well
preloadbooleantrue是否在显示Carousel之前预加载图片。
displayCutoffinteger0If greater than '0', will only use this amount of features within the carousel. Any after this number will be ignored.
animationEasingstring'swing'carousel动画的easing效果。
leftButtonTagstring'#carousel-left'prev按钮的jquery选择器。
rightButtonTagstring'#carousel-right'next按钮的jquery选择器。
captionBelowbooleanfalse是否在carousel下方显示描述文字。
movedToCenterfunction$.noop当图片移动到中间时触发的回调函数。
leavingCenterfunction$.noop当图片离开中间位置时触发的回调函数。
clickedCenterfunction$.noop当中间的图片是一个链接,单该链接被点击时触发的回调函数。

链接: https://fly63.com/nav/270

more>>
相关栏目
jQuery之家
致力于搜集和整理各种jQuery插件,jQuery特效...
官网
fullPage.js
jQuery全屏滚动插件
官网GitHub
Waterfall.js
瀑布流无限加载插件
官网GitHub
Raty
一个非常棒的jQuery 评分插件
官网GitHub
Bootstrap-waterfall
一款基于Bootstrap仿Pinterest网站的网格瀑布流插件
官网GitHub
Jcrop
一个功能强大的 jQuery 图像裁剪插件
官网GitHub
jcarousel
jQuery轮播图插件
官网GitHub
Parallax.js
一款jQuery滚动视觉差插件
官网GitHub
vegas
一个jQuery / Zepto幻灯片插件
官网GitHub
paroller.js
一款轻量级的页面滚动视觉差特效jquery插件
官网GitHub
lazyload.js
jquery图片懒加载插件
官网GitHub
alertify.js
jQuery酷炫的各种消息提示插件
官网GitHub
pickadate.js
一个轻量级的 jQuery 日期选择插件
官网GitHub
chosen.js
基于jquery的下拉选择框美化插件
官网GitHub
threesixty.js
360度产品图片预览jQuery插件
官网GitHub
textillate.js
实现动感的 CSS3 文本动画的简单插件
官网GitHub

手机预览