...
|
...
|
@@ -4,7 +4,8 @@ |
|
|
* @date: 2015/11/12
|
|
|
*/
|
|
|
var $ = require('jquery');
|
|
|
var $userAvatar = $('.user-avatar');
|
|
|
var $userAvatar = $('.user-avatar'),
|
|
|
$listItem = $('.list-item');
|
|
|
var myImage = new Image();
|
|
|
|
|
|
require('../product/recommend-for-you.js');
|
...
|
...
|
@@ -12,3 +13,10 @@ myImage.src = $userAvatar.attr('src'); |
|
|
myImage.onerror = function() {
|
|
|
$userAvatar.attr('src', 'http://static.dev.yohobuy.com/img/me/index/user-avatar.png');
|
|
|
};
|
|
|
|
|
|
$('.yoho-page').on('touchstart', '.list-item, .type-item', function() {
|
|
|
$listItem.removeClass('highlight');
|
|
|
$(this).addClass('highlight');
|
|
|
}).on('touchend touchcancel', '.list-item, .type-item', function() {
|
|
|
$(this).removeClass('highlight');
|
|
|
}); |
...
|
...
|
|