aframevr / aframe-site

:a: Official A-Frame site.
https://aframe.io/
MIT License
99 stars 141 forks source link

reset sidebar scroll top to 0 when navigating between sections of the site #398

Open ngokevin opened 7 years ago

ngokevin commented 7 years ago

When going from Blog -> Docs, the Sidebar should reset scroll state top to 0.

Can do this by keeping track of last section in localStorage and checking.

cvan commented 7 years ago

could do this with history.pushState and a popstate event listener and pjax-standalone (or similar)

lainshiHenry commented 10 months ago

As of testing today,

image

Navigating between Docs and Blog, the sidebar position does not change. When you select Blog, then on the sidebar try to select Docs, as Docs is the first item in the list, you would scroll all the way up to select Docs.

As a test case:

image

1) I did a partial scroll to reveal a part of Docs 2) Clicked on the Docs link 3) Sidebar position does not change.

Navigating between direct links (https://aframe.io/blog/) and (https://aframe.io/docs) does reset the sidebar position.

I know this issue is almost 8 years old, @ngokevin @dmarcos does this issue still need to be looked at?