Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot scroll to heading with label "Contents" #61

Closed
seshrs opened this issue Jul 27, 2020 · 0 comments · Fixed by #67
Closed

Cannot scroll to heading with label "Contents" #61

seshrs opened this issue Jul 27, 2020 · 0 comments · Fixed by #67
Labels
bug Something isn't working

Comments

@seshrs
Copy link
Member

seshrs commented Jul 27, 2020

Describe the bug
When a page contains a heading titled "Contents", AnchorJS gives it HTML id="contents". However, this conflicts with the Sidebar's "Contents" header with the same ID — as a result, using the internal link https://<page-url>#contents does not cause the page to scroll to the correct place. (In fact, this can be seen on the demo page for Primer Spec itself.)

To Reproduce
Steps to reproduce the behavior:

  1. Go to the Primer Spec demo page: https://eecs485staff.github.io/primer-spec/
  2. Click on 'Contents' in the Sidebar.

Page does not scroll.

Expected behavior
Page should scroll to the "Contents" section in the main content.

@seshrs seshrs added the bug Something isn't working label Jul 27, 2020
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 a pull request may close this issue.

1 participant