Authored by zhangxiaoru

guang info js

@@ -7,7 +7,8 @@ require('guang/info-index.page.css'); @@ -7,7 +7,8 @@ require('guang/info-index.page.css');
7 7
8 var $ = require('yoho-jquery'), 8 var $ = require('yoho-jquery'),
9 ellipsis = require('yoho-mlellipsis'), 9 ellipsis = require('yoho-mlellipsis'),
10 - lazyLoad = require('yoho-jquery-lazyload'); 10 + lazyLoad = require('yoho-jquery-lazyload'),
  11 + Hammer = require('yoho-hammer');
11 12
12 var $authorIntro = $('.author .intro'); 13 var $authorIntro = $('.author .intro');
13 14
@@ -234,7 +235,6 @@ function setCookie(name, value, options) { @@ -234,7 +235,6 @@ function setCookie(name, value, options) {
234 // 初始化页面,包括是否使用iscorll初始化页面 235 // 初始化页面,包括是否使用iscorll初始化页面
235 // 接口暴露在HTML中,使用压缩名 236 // 接口暴露在HTML中,使用压缩名
236 (function() { 237 (function() {
237 - var isIphone = navigator.userAgent.indexOf('iPhone') > 0 ? true : false;  
238 var isweixin = navigator.userAgent.indexOf('MicroMessenger') ? true : false; 238 var isweixin = navigator.userAgent.indexOf('MicroMessenger') ? true : false;
239 var $this, $title; 239 var $this, $title;
240 240
@@ -272,11 +272,7 @@ function setCookie(name, value, options) { @@ -272,11 +272,7 @@ function setCookie(name, value, options) {
272 } 272 }
273 273
274 if (isweixin) { 274 if (isweixin) {
275 - if (isIphone) {  
276 - $overlay.css('position', 'relative');  
277 - } else {  
278 - $overlay.css('position', 'absolute');  
279 - } 275 + $overlay.css('position', 'absolute');
280 } 276 }
281 277
282 $('#float-layer-close').on('touchend', function(index) { 278 $('#float-layer-close').on('touchend', function(index) {
@@ -299,6 +295,7 @@ function setCookie(name, value, options) { @@ -299,6 +295,7 @@ function setCookie(name, value, options) {
299 295
300 if ($('#float-layer-btn') && $('#float-layer-btn')[0]) { 296 if ($('#float-layer-btn') && $('#float-layer-btn')[0]) {
301 var floatLayerBtnHammer = new Hammer($('#float-layer-btn')[0]); 297 var floatLayerBtnHammer = new Hammer($('#float-layer-btn')[0]);
  298 +
302 floatLayerBtnHammer.on('tap', function(e) { 299 floatLayerBtnHammer.on('tap', function(e) {
303 window.location = 'http://www.yohoshow.com/about/index/yohobuyqr'; 300 window.location = 'http://www.yohoshow.com/about/index/yohobuyqr';
304 e.srcEvent.stopPropagation(); 301 e.srcEvent.stopPropagation();