rustdoc: highlight all anchored headings on click #86012
Labels
A-rustdoc-ui
Area: Rustdoc UI (generated HTML)
C-enhancement
Category: An issue proposing an enhancement or a PR with one.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
When you visit on a rustdoc URL with a fragment linking to a specific method (e.g. https://doc.rust-lang.org/nightly/std/string/struct.String.html#method.as_bytes), or when you click an internal link from the sidebar, the method declaration is highlighted.
However, if you click an internal section heading in the sidebar, or visit a URL with such a fragment, there is no highlighting. This is particularly noticeable on short pages (like module pages, e.g. https://doc.rust-lang.org/nightly/std/option/index.html#enums), where the section heading can't be moved all the way to the top of the page. You can wind up clicking on a sidebar link and not immediately seeing the heading you selected because it's towards the bottom of the page.
The text was updated successfully, but these errors were encountered: