From db8afab5f0767d3c8c5b294ec6eeb66a5bf76712 Mon Sep 17 00:00:00 2001 From: blackcatsandy Date: Fri, 23 Jan 2015 12:31:11 +0000 Subject: [PATCH] Responsive iOS 6 Theme - ios6.js needs to be added in the config. Supports Desktop, iPad, iPhone - added smaller padding on mobile view http://forum.fhem.de/index.php/topic,23406.msg166953.html#msg166953 git-svn-id: https://svn.fhem.de/fhem/trunk@7670 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/www/pgm2/ios6.js | 8 ++++++-- fhem/www/pgm2/ios6touchpadstyle.css | 12 +++++++++--- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/fhem/www/pgm2/ios6.js b/fhem/www/pgm2/ios6.js index 64960eb30..17df9bcab 100644 --- a/fhem/www/pgm2/ios6.js +++ b/fhem/www/pgm2/ios6.js @@ -9,6 +9,7 @@ $( document ).ready(function() { */ var menuwidth = 200; var paddingwidth = 60; + var mobilepaddingwidth = 20; var logowidth = 28; var switchtomobilemode = 376; var hdrheight = 44; @@ -52,13 +53,16 @@ $( document ).ready(function() { if (switchtomobilemode > width) { $("#hdr input").width(width-inputpadding+menuwidth-logowidth); + $("#content").width(width-mobilepaddingwidth); + $("#right").width(width-mobilepaddingwidth); } else { $("#hdr input").width(width-inputpadding); + $("#content").width(width-paddingwidth); + $("#right").width(width-paddingwidth); } $("#menu").width(0); - $("#content").width(width-paddingwidth); - $("#right").width(width-paddingwidth); + $("#content").show() $("#right").show(); }; diff --git a/fhem/www/pgm2/ios6touchpadstyle.css b/fhem/www/pgm2/ios6touchpadstyle.css index 89ede3ed9..4ac79d309 100644 --- a/fhem/www/pgm2/ios6touchpadstyle.css +++ b/fhem/www/pgm2/ios6touchpadstyle.css @@ -49,8 +49,6 @@ width: -webkit-calc(100% - 60px); width: -o-calc(100% - 60px); /* Standard */ width: calc(100% - 60px); - -padding-left:30px; } @@ -66,7 +64,6 @@ padding-left:30px; } /*iPhone Skalierung*/ - /* iPhone < 5(portrait) ----------- */ @media only screen and (min-device-width : 320px) @@ -75,6 +72,9 @@ and (orientation : portrait) { body { width:320px; } +#content, #right { +padding: 0px 10px 0px 10px !important; +} } /* iPhone < 5(landscape) ----------- */ @media only screen @@ -94,6 +94,9 @@ and (orientation : portrait) { body { width:320px; } +#content, #right { +padding: 0px 10px 0px 10px !important; +} } /* iPhone 5(landscape) ----------- */ @media only screen @@ -113,6 +116,9 @@ and (orientation : portrait) { body { width:375px; } +#content, #right { +padding: 0px 10px 0px 10px !important; +} } /* iPhone 6(landscape) ----------- */ @media only screen