Fix scroll top position for anchor links with new navigation
What does this MR do and why?
Fix scroll top position for anchor links with new navigation. Add .top-bar-fixed
height adjustment to handleLocationHash
and contentTop
functions in common_utils.js
.
Screenshots or screen recordings
Before | After |
---|---|
CleanShot_2023-06-16_at_09.29.29 | CleanShot_2023-06-16_at_09.31.43 |
How to set up and validate locally
- Enable new navigation
- Go to any Issue/MR/Epic or any other anchor link content
- Press a link
- Scroll position should cater for the fixed top-bar, comment/content should be fully visibile
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #415491 (closed)