From 5de7eac67d94751126d14bec6925ed80814ae346 Mon Sep 17 00:00:00 2001 From: Annabel Dunstone Gray Date: Mon, 27 Mar 2017 11:07:54 -0600 Subject: [PATCH] Add subnav height to sidebar scroll calculation --- app/assets/javascripts/right_sidebar.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/right_sidebar.js b/app/assets/javascripts/right_sidebar.js index 64a68d56962..9be49b370d2 100644 --- a/app/assets/javascripts/right_sidebar.js +++ b/app/assets/javascripts/right_sidebar.js @@ -198,7 +198,7 @@ import Cookies from 'js-cookie'; }; Sidebar.prototype.setSidebarHeight = function() { - const $navHeight = $('.navbar-gitlab').outerHeight() + $('.layout-nav').outerHeight(); + const $navHeight = $('.navbar-gitlab').outerHeight() + $('.layout-nav').outerHeight() + $('.sub-nav-scroll').outerHeight(); const $rightSidebar = $('.js-right-sidebar'); const diff = $navHeight - $(window).scrollTop(); if (diff > 0) {