From cbd3509ad230f8ce7a7b1ec142d6156741ae70c6 Mon Sep 17 00:00:00 2001 From: Toby Zerner Date: Thu, 25 Jun 2015 15:34:34 +0930 Subject: [PATCH] More accurate scrubber height resizing --- js/forum/src/components/post-scrubber.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/forum/src/components/post-scrubber.js b/js/forum/src/components/post-scrubber.js index 6d137a57d..db473f9b2 100644 --- a/js/forum/src/components/post-scrubber.js +++ b/js/forum/src/components/post-scrubber.js @@ -315,8 +315,9 @@ export default class PostScrubber extends Component { // Adjust the height of the scrollbar so that it fills the height of // the sidebar and doesn't overlap the footer. + var scrubber = this.$(); var scrollbar = this.$('.scrubber-scrollbar'); - scrollbar.css('max-height', $(window).height() - scrollbar.offset().top + $(window).scrollTop() - parseInt($('.global-page').css('padding-bottom'))); + scrollbar.css('max-height', $(window).height() - scrubber.offset().top + $(window).scrollTop() - parseInt($('.global-page').css('padding-bottom')) - (scrubber.outerHeight() - scrollbar.outerHeight())); } onmousedown(e) {