yoga icon indicating copy to clipboard operation
yoga copied to clipboard

[BUG] Scroll Position Remains Fixed, Even When The Content Rerenders

Open tabishnaqvi1311 opened this issue 1 year ago • 1 comments

Describe the bug When using the side menu to navigate through the documentation, there is a problem where, if you are at the bottom of a page and you select a different section from the menu, the page does not automatically scroll back up to the top. Instead, you remain at the bottom of the page, which can be inconvenient and make it harder to navigate efficiently through the documentation. This behavior can be confusing and frustrating for users who are trying to quickly browse through the content.

To Reproduce Steps to reproduce the behavior:

  1. Go to https://gympass.github.io/yoga/components/getting-started
  2. Scroll down to the very bottom
  3. Select any of the links from the side navigation bar
  4. Notice how the content re-renders, but the scrollbar remains fixed

Expected behavior Instead of the scroll position remaining static, it would be convenient if the user does not have to scroll back up every time they open a new link.

Screenshots https://user-images.githubusercontent.com/115006878/231274800-efd84dde-8144-44dd-b8f6-77e41e2700ca.mp4

Desktop (please complete the following information):

  • OS: Windows 10
  • Browser: Google Chrome, Opera, Firefox

tabishnaqvi1311 avatar Apr 11 '23 20:04 tabishnaqvi1311

@tabishnaqvi1311 You mean on clicking a link it should go to the top of the page right?

ashutosh-rath02 avatar May 15 '23 17:05 ashutosh-rath02