FIX: Correct topic timeline position calculation

Fixes calculation for themes with tall custom headers.
This commit is contained in:
Penar Musaraj 2019-10-16 15:00:45 -04:00
parent 74207ef03a
commit baf8ae604a
1 changed files with 2 additions and 1 deletions

View File

@ -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;