diff options
Diffstat (limited to 'view/theme/redbasic/js/redbasic.js')
-rw-r--r-- | view/theme/redbasic/js/redbasic.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/view/theme/redbasic/js/redbasic.js b/view/theme/redbasic/js/redbasic.js index 4f70752c0..3db67dc87 100644 --- a/view/theme/redbasic/js/redbasic.js +++ b/view/theme/redbasic/js/redbasic.js @@ -1,6 +1,19 @@ $(document).ready(function() { +// CSS3 calc() fallback (for unsupported browsers) +$('body').append('<div id="css3-calc" style="width: 10px; width: calc(10px + 10px); display: none;"></div>'); +if( $('#css3-calc').width() == 10) { + $(window).resize(function() { + if($(window).width() < 767) { + $('main').css('width', $(window).width() + 231 ); + } else { + $('main').css('width', '100%' ); + } + }); +} +$('#css3-calc').remove(); // Remove the test element + $('#expand-aside').click(function() { $('#expand-aside-icon').toggleClass('icon-circle-arrow-right').toggleClass('icon-circle-arrow-left'); $('main').toggleClass('region_1-on'); |