diff --git a/app/assets/javascripts/discourse/components/topic-timeline.js.es6 b/app/assets/javascripts/discourse/components/topic-timeline.js.es6 index 17709a5fc70..1d9ec49b787 100644 --- a/app/assets/javascripts/discourse/components/topic-timeline.js.es6 +++ b/app/assets/javascripts/discourse/components/topic-timeline.js.es6 @@ -58,7 +58,8 @@ export default MountWidget.extend(Docking, { const mainOffset = $("#main").offset(); const offsetTop = mainOffset ? mainOffset.top : 0; const topicTop = $(".container.posts").offset().top - offsetTop; - const topicBottom = $("#topic-bottom").offset().top; + const topicBottom = + $("#topic-bottom").offset().top - $("#main-outlet").offset().top; const timeline = this.element.querySelector(".timeline-container"); const timelineHeight = (timeline && timeline.offsetHeight) || 400; const footerHeight = $(".timeline-footer-controls").outerHeight(true) || 0;