aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2012-03-01 09:50:41 +0000
committerMatthew Somerville <matthew@mysociety.org>2012-03-01 09:50:41 +0000
commit00115a2171a6ae6877a9ed668f84254db78574f3 (patch)
tree4a53f9088b465df61d082553095e6ae03a486ac3
parent4c6fe90795c6f1597775ad317798a6c75f8f27f9 (diff)
For #258, immediately go full screen map on mobile around page.
-rw-r--r--web/cobrands/fixmystreet/fixmystreet.js15
1 files changed, 8 insertions, 7 deletions
diff --git a/web/cobrands/fixmystreet/fixmystreet.js b/web/cobrands/fixmystreet/fixmystreet.js
index ae7b2e820..85b0e6f43 100644
--- a/web/cobrands/fixmystreet/fixmystreet.js
+++ b/web/cobrands/fixmystreet/fixmystreet.js
@@ -80,13 +80,14 @@ $(function(){
//add mobile class if small screen
if(Modernizr.mq('only screen and (max-width:48em)')) {
$('html').addClass('mobile');
-// XXX Make map full screen here?
-// if (fixmystreet.page == 'around') {
-// $('#map_box').css({
-// height: $(window).height(),
-// margin: 0
-// });
-// }
+ if (fixmystreet.page == 'around') {
+ // Immediately go full screen map if on around page
+ $('#site-header').hide();
+ $('#map_box').prependTo('.wrapper').css({
+ height: $(window).height(),
+ margin: 0
+ });
+ }
} else {
// Make map full screen on non-mobile sizes.
var map_pos = 'fixed', map_height = '100%';