Skip to content

Conversation

maximusmith529
Copy link
Contributor

@maximusmith529 maximusmith529 commented Sep 5, 2025

Proposed changes

This PR adds functionality to the sidebar that allows it to move to the user's location in the docs on page load or reload. This helps with long lists or nested docs. This is in relevance to issue 578

Here I've got a video showcasing the changes. I navigate to a nested link, click on it and scroll up, then reload the page to show that it navigates back to the link. Then I show how it will try to bring the link to the top if possible.

Screen.Recording.2025-09-09.at.10.45.27.AM.mov

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING document
  • If applicable, I have added tests that prove my fix is effective or that my feature works
  • If applicable, I have checked that any relevant tests pass after adding my changes
  • I have updated any relevant documentation (README.md and CHANGELOG.md)

@maximusmith529 maximusmith529 requested a review from a team as a code owner September 5, 2025 23:24
Copy link

github-actions bot commented Sep 5, 2025

Deploy Preview will be available once build job completes!

Name Link
😎 Deploy Preview https://frontdoor-test-docs.nginx.com/previews/nginx-hugo-theme/391/

@maximusmith529 maximusmith529 force-pushed the maximus-sidebar-scroll-anchor-578 branch from 5e00b70 to 338844a Compare September 5, 2025 23:27
@nginxinc nginxinc deleted a comment from github-actions bot Sep 5, 2025
Copy link

github-actions bot commented Sep 5, 2025

❌ One or more of the commit messages in this PR do not match the nginx-hugo-theme git guidelines, please check the CI job for more details on which commits were flagged and why.

Please do not close this PR and open another, instead modify your commit message(s) with git commit --amend and force push those changes to update this PR.

@maximusmith529 maximusmith529 changed the title Maximus sidebar scroll anchor 578 Layout: sidebar scroll anchor 578 Sep 8, 2025
@maximusmith529 maximusmith529 force-pushed the maximus-sidebar-scroll-anchor-578 branch 2 times, most recently from 268f545 to 7fd157b Compare September 8, 2025 18:25
@maximusmith529 maximusmith529 changed the title Layout: sidebar scroll anchor 578 Layout: sidebar scroll anchor Sep 9, 2025
@maximusmith529 maximusmith529 force-pushed the maximus-sidebar-scroll-anchor-578 branch 2 times, most recently from 4dba16b to ea03101 Compare September 9, 2025 21:53
@maximusmith529 maximusmith529 force-pushed the maximus-sidebar-scroll-anchor-578 branch from 95c7f6d to dd8410b Compare September 10, 2025 16:57
@maximusmith529 maximusmith529 requested a review from a team September 10, 2025 17:21
@maximusmith529 maximusmith529 self-assigned this Sep 10, 2025
@maximusmith529 maximusmith529 added the bug Something isn't working label Sep 10, 2025
@maximusmith529 maximusmith529 merged commit 25240c9 into main Sep 10, 2025
8 checks passed
@maximusmith529 maximusmith529 deleted the maximus-sidebar-scroll-anchor-578 branch September 10, 2025 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants