pbSlider支持手机端的响应式轮播图 支持显示文字,缩略图预览
XML/HTML Code
- <div class='o-sliderContainer hasShadow ' id="pbSliderWrap3">
- <div class='o-slider' id='pbSlider3'>
- <div class="o-slider--item" data-image="../demo1.jpg">
- <div class="o-slider-textWrap">
- <h1 class="o-slider-title">This is a title</h1>
- <span class="a-divider"></span>
- <h2 class="o-slider-subTitle">This is a sub title</h2>
- </div>
- </div>
- <div class="o-slider--item" data-image="../demo2.jpg">
- <div class="o-slider-textWrap">
- <h1 class="o-slider-title">This is a title</h1>
- <span class="a-divider"></span>
- <h2 class="o-slider-subTitle">This is a sub title</h2>
- </div>
- </div>
- <div class="o-slider--item" data-image="../demo3.jpg">
- <div class="o-slider-textWrap">
- <h1 class="o-slider-title">freejs.net</h1>
- <span class="a-divider"></span>
- <h2 class="o-slider-subTitle">专注web前端</h2>
- </div>
- </div>
- </div>
- </div>
JavaScript Code
- $('#pbSlider3').pbTouchSlider({
- slider_Wrap: '#pbSliderWrap3',
- slider_Threshold: 50 ,
- slider_Speed:400 ,
- slider_Ease:'linear',
- slider_Breakpoints: {
- default: {
- height: 400
- },
- tablet: {
- height: 300,
- media: 1024
- },
- smartphone: {
- height: 200,
- media: 768
- }
- }
- });
原文地址:http://www.freejs.net/article_jiaodiantu_614.html