Commit f078cf8f authored by orozot's avatar orozot

Replace offsetTop with getBoundingClientRect for roadmap_setting panel

Issue: https://gitlab.com/gitlab-org/gitlab/-/issues/350967
Changelog: fixed
parent a1e62a34
...@@ -16,7 +16,8 @@ export default { ...@@ -16,7 +16,8 @@ export default {
const wrapperEl = document.querySelector('.roadmap-container'); const wrapperEl = document.querySelector('.roadmap-container');
if (wrapperEl) { if (wrapperEl) {
return `${wrapperEl.offsetTop}px`; const topPosition = wrapperEl.getBoundingClientRect().top + window.pageYOffset;
return `${topPosition}px`;
} }
return ''; return '';
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment