Showing
2 changed files
with
8 additions
and
25 deletions
@@ -29,6 +29,11 @@ $('.nav-btn').on('touchstart', function(event) { | @@ -29,6 +29,11 @@ $('.nav-btn').on('touchstart', function(event) { | ||
29 | $overlay.show().css('opacity', 0.3); | 29 | $overlay.show().css('opacity', 0.3); |
30 | $sideNav.addClass('on'); | 30 | $sideNav.addClass('on'); |
31 | openSideNav = true; | 31 | openSideNav = true; |
32 | + | ||
33 | + //设置boy高宽,页面不能上下滑动 | ||
34 | + $('body').css({ | ||
35 | + overflow: 'hidden' | ||
36 | + }); | ||
32 | return false; | 37 | return false; |
33 | }); | 38 | }); |
34 | 39 | ||
@@ -39,6 +44,9 @@ function hideSideBar() { | @@ -39,6 +44,9 @@ function hideSideBar() { | ||
39 | $('.overlay').hide(); | 44 | $('.overlay').hide(); |
40 | $('.sub-nav').removeClass('show'); | 45 | $('.sub-nav').removeClass('show'); |
41 | $sideNav.removeClass('on'); | 46 | $sideNav.removeClass('on'); |
47 | + $('body').css({ | ||
48 | + overflow: 'auto' | ||
49 | + }); | ||
42 | } | 50 | } |
43 | } | 51 | } |
44 | 52 | ||
@@ -60,10 +68,6 @@ $sideNav.on('touchstart', 'li', function(e) { | @@ -60,10 +68,6 @@ $sideNav.on('touchstart', 'li', function(e) { | ||
60 | } | 68 | } |
61 | }); | 69 | }); |
62 | 70 | ||
63 | -$sideNav.on('touchmove', function(e) { | ||
64 | - return false; | ||
65 | -}); | ||
66 | - | ||
67 | //返回一级导航,收起二级导航 | 71 | //返回一级导航,收起二级导航 |
68 | $subNav.each(function() { | 72 | $subNav.each(function() { |
69 | $(this).find('li').eq(0).on('touchstart', function() { | 73 | $(this).find('li').eq(0).on('touchstart', function() { |
@@ -152,18 +152,6 @@ | @@ -152,18 +152,6 @@ | ||
152 | } | 152 | } |
153 | } | 153 | } |
154 | 154 | ||
155 | - // li.new { | ||
156 | - // margin: (19rem / $pxConvertRem) 0 0; | ||
157 | - // border-top: 1px solid #e0e0e0; | ||
158 | - // | ||
159 | - // a {} | ||
160 | - // | ||
161 | - // i { | ||
162 | - // background: image-url("side-nav/new.png") no-repeat left center; | ||
163 | - // background-size: 100% 100%; | ||
164 | - // } | ||
165 | - // } | ||
166 | - | ||
167 | li.guang, li.trendfinder { | 155 | li.guang, li.trendfinder { |
168 | .nav-icon { | 156 | .nav-icon { |
169 | background: image-url("side-nav/guang.png") no-repeat left center; | 157 | background: image-url("side-nav/guang.png") no-repeat left center; |
@@ -208,15 +196,6 @@ | @@ -208,15 +196,6 @@ | ||
208 | z-index: 2; | 196 | z-index: 2; |
209 | } | 197 | } |
210 | 198 | ||
211 | - /* img{ | ||
212 | - position: absolute; | ||
213 | - max-width: 50rem / $pxConvertRem; | ||
214 | - max-height: 50rem / $pxConvertRem; | ||
215 | - left: 32rem / $pxConvertRem; | ||
216 | - top: 50%; | ||
217 | - margin-top: -25rem / $pxConvertRem; | ||
218 | - border: none; | ||
219 | - } */ | ||
220 | .nav-point { | 199 | .nav-point { |
221 | position: absolute; | 200 | position: absolute; |
222 | left: 0rem / $pxConvertRem; | 201 | left: 0rem / $pxConvertRem; |
-
Please register or login to post a comment