Skip to content

Commit

Permalink
content area should be properly placed
Browse files Browse the repository at this point in the history
  • Loading branch information
dgrammatiko committed Jul 4, 2015
1 parent a6a546b commit 3f9ee3b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions administrator/templates/isis/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,9 @@ function processScrollInit()
if ($('.subhead').length) {
navTop = $('.subhead').length && $('.subhead').offset().top - <?php echo ($displayHeader || !$statusFixed) ? 30 : 20;?>;

// Fix the container top
$(".container-main").css("top", $('.subhead').height() + $('nav.navbar').height());

// Only apply the scrollspy when the toolbar is not collapsed
if (document.body.clientWidth > 480)
{
Expand All @@ -325,6 +328,9 @@ function processScroll()
if (scrollTop >= navTop && !isFixed) {
isFixed = true;
$('.subhead').addClass('subhead-fixed');

// Fix the container top
$(".container-main").css("top", $('.subhead').height() + $('nav.navbar').height());
} else if (scrollTop <= navTop && isFixed) {
isFixed = false;
$('.subhead').removeClass('subhead-fixed');
Expand Down

0 comments on commit 3f9ee3b

Please sign in to comment.