Authored by lijing

优化

... ... @@ -12,7 +12,7 @@ var $userAvatar = $('.user-avatar'),
var myImage = new Image(),
avatar;
var Swiper = require('yoho-swiper');
var Swiper = require('yoho-swiper2');
require('home/index.page.css');
... ... @@ -28,7 +28,6 @@ new Swiper('.banner-center-swiper', {
lazyLoading: true,
lazyLoadingInPrevNext: true,
paginationClickable: true,
loop: true,
autoplay: 3000
});
... ... @@ -60,12 +59,21 @@ $('.res-c').on('click', 'a', function() {
var url = $this.attr('href');
var name = $this.attr('name');
var id = $this.attr('id');
var status = $this.parent('li').hasClass('swiper-slide');
window._yas.sendCustomInfo({
I_INDEX: index,
F_URL: encodeURIComponent(url),
F_NAME: name,
F_INDEX: pIndex,
F_ID: id
}, true);
if (status) {
index = $this.parent('li').index() + 1;
pIndex = 1;
}
if (window._yas && window._yas.sendCustomInfo) {
window._yas.sendCustomInfo({
I_INDEX: index,
F_URL: encodeURIComponent(url),
F_NAME: name,
F_INDEX: pIndex,
F_ID: id
}, false);
}
return false;
});
... ...
... ... @@ -329,31 +329,4 @@
padding-top: 0;
}
}
.banner-center-swiper {
position: relative;
z-index: 1;
overflow: hidden;
margin: 0 auto;
img {
width: 750px;
height: 234px;
}
.swiper-pagination-bullet {
display: inline-block;
width: 0.35rem;
height: 0.35rem;
background: #fff;
opacity: 0.5;
margin: 0 0.225rem;
border-radius: 50%;
}
.swiper-pagination-bullet-active {
background: #fff;
opacity: 1;
}
}
}
... ...
... ... @@ -4,4 +4,5 @@
@import "channel/footer-tab";
@import "channel/thumb-row";
@import "channel/divide-image";
@import "channel/banner-center";
@import "layout/swiper";
... ...