Skip to content

Make body position: relative

Warren Gifford requested to merge fix-octotree into main

Created by: felixfbecker

Fixes #9308

Octotree works by adding margin-left to the <html> element. We position the tooltip relative to the <body> (relativeElement: document.body). However, body is not actually position: relative. This still works because <body> is usually not different from the viewport. But when Octotree adds the margin-left, <body> gets moved too. The only thing we have to do to fix it it seems is to set body { position: relative; } in our CSS.

That still won't react to the sidebar sliding in of course, that is not really detectable since it's a CSS animation, except with MutationObserver on all style changes and a significant delay to allow for animations. But I think that's okay, positioning will be correct on the next hover.

Closes #9309

Merge request reports

Loading