Authored by 梁志锋

gulp ge文件

... ... @@ -35,26 +35,26 @@
<div class="limit-good-page yoho-page">
<div class="goodDesc">
{{#mainImg}}
<img class="lazy" src="{{mainImg}}" alt="">
{{/mainImg}}
{{# goodDescList}}
{{#goodDescription}}
<p class="desc">{{goodDescription}}</p>
{{/goodDescription}}
{{# item}}
{{#if img}}
<img class="lazy" src="{{.}}" alt="">
{{/if}}
{{#imgList}}
<img class="lazy" src="{{img}}" alt="">
{{/imgList}}
{{#if text}}
<p class=" desc">{{.}}</p>
{{/if}}
{{#vedio}}
{{#if video}}
<video poster="{{img}}" controls="controls" controls="controls" preload="metadata" loop="loop" width="100%" name="media">
{{#list}}
<source src="{{src}}" type="video/ogg;codecs=" theora,vorbis"" media="screen" />
<source src="{{src}}"/>
{{/list}}
</video>
{{/vedio}}
{{/if}}
{{/ item}}
{{/ goodDescList}}
</div>
</div>
</body>
... ...
... ... @@ -1689,6 +1689,7 @@ define("js/home/home", ["jquery","swiper","lazyload","hammer","index"], function
var $ = require("jquery"),
Swiper = require("swiper"),
lazyLoad = require("lazyload"),
noticeScroll = require("js/plugin/notice-scroll"),
$mobileWrap = $('.mobile-wrap'),
$overlay = $('.overlay'),
$sideNav = $('.side-nav'),
... ... @@ -1707,6 +1708,7 @@ var start = 0,
isen = true;
lazyLoad($('img.lazy'));
noticeScroll('.notice', $('.notice').data('time') * 1000);
$('.nav-btn').on('touchstart', function() {
$sideNav.css('pointer-events', 'none');
... ... @@ -1907,6 +1909,38 @@ exports.set = function(c) {
require("js/home/maybe-like")();
});
define("js/plugin/notice-scroll", ["jquery"], function(require, exports, module){
/**
* 公告栏目滚动
* bikai kai.bi@yoho.cn
*/
var $ = require("jquery");
function noticeScroll(selecter, time) {
var $notice = $(selecter),
$noticeItem = $notice.find('.notice-item'),
count = $noticeItem.length,
i = 1;
selecter = selecter || '.notice';
time = time || 3000;
if (count > 1) {
setInterval(function() {
if (i >= count) {
i = 0;
}
$noticeItem.fadeOut();
$notice.find('.item-' + i).fadeIn();
i++;
}, time);
}
}
module.exports = noticeScroll;
});
define("js/home/maybe-like", ["jquery","hammer","lazyload"], function(require, exports, module){
/**
* “你可能喜欢”模块JS
... ... @@ -7049,6 +7083,8 @@ var $ = require("jquery"),
var diaLog = require("js/me/dialog");
var tip = require("js/plugin/tip");
var $navLi = $('#fav-tab > li'),
$favContainer = $('.fav-content > .fav-type'),
swiperObj = {},
... ... @@ -7130,11 +7166,13 @@ function loadData($parent, url, page) {
if (data === ' ') {
$loadingMask.addClass('hide');
$parent.closest('.fav-type').find('.fav-null-box').removeClass('hide');
window.rePosFooter();
} else if (data === 'end') {
//处理data等于end时如果loadingMask存在且没有hide样式的情况
if ($loadingMask && !$loadingMask.hasClass('hide')) {
$loadingMask.addClass('hide');
//$parent.closest('.fav-type').find('.fav-null-box').removeClass('hide');
}
... ... @@ -7297,7 +7335,7 @@ $(document).on('touchend', '.swiper-header', function() {
}
});
$('.invalidGoods').on('touchstart touchend', function() {
$('.invalidGoods').on('touchstart touchend', function(e) {
var $this = $(e.target).closest('span');
if ($this.hasClass('del-fav')) {
... ... @@ -7306,6 +7344,7 @@ $('.invalidGoods').on('touchstart touchend', function() {
tip.show('商品已下架');
return false;
});
});
define("js/me/suggest", ["jquery","hammer","lazyload","handlebars","source-map"], function(require, exports, module){
/**
... ... @@ -8376,7 +8415,9 @@ define("js/me/index", ["jquery","swiper","index"], function(require, exports, mo
* @author: bikai<kai.bi@yoho.cn>
* @date: 2015/11/12
*/
var $ = require("jquery");
var $ = require("jquery"),
noticeScroll = require("js/plugin/notice-scroll");
var $userAvatar = $('.user-avatar'),
$listItem = $('.list-item');
var myImage = new Image(),
... ... @@ -8392,6 +8433,8 @@ myImage.onload = function() {
$userAvatar.css('background-image', 'url(' + avatar + ')');
};
noticeScroll('.notice', $('.notice').data('time') * 1000);
$('.yoho-page').on('touchstart', '.list-item, .type-item, .order-title', function() {
$listItem.removeClass('highlight');
$(this).addClass('highlight');
... ...
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.

23.3 KB | W: | H:

17.3 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin