Skip to content

Conversation

@ehuss
Copy link
Contributor

@ehuss ehuss commented Dec 10, 2025

This enables the sidebar navigation folding feature in mdbook (https://rust-lang.github.io/mdBook/format/configuration/renderers.html#outputhtmlfold) which collapses the sidebar by default. You can look at https://rustc-dev-guide.rust-lang.org/ as an example of folded chapters.

The main issue is that the sidebar has become quite long over time, and it can make it a little harder to see the big picture. Particularly the triagebot and infrastructure sections have a large number of sub-chapters which can overwhelm the navigation.

I don't love this 100% because it can make it a little harder for certain navigation use-cases. For example, I can't use my browser's search functionality and enter "zulip" to find the zulip-related chapters. I now have to use mdbook's search bar, and mdbook's search output isn't particularly great (especially the ranking). But overall I think this is a net win.

r? @rust-lang/internal-sites

This enables the sidebar navigation folding feature in mdbook
(https://rust-lang.github.io/mdBook/format/configuration/renderers.html#outputhtmlfold)
which collapses the sidebar by default.

The main issue is that the sidebar has become quite long over time, and
it can make it a little harder to see the big picture. Particularly the
triagebot and infrastructure sections have a large number of
sub-chapters which can overwhelm the navigation.

I don't love this 100% because it can make it a little harder for
certain navigation use-cases. For example, I can't use my browser's
search functionality and enter "zulip" to find the zulip-related
chapters. I now have to use mdbook's search bar, and mdbook's search
output isn't particularly great (especially the ranking). But overall I
think this is a net win.
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 10, 2025
@Urgau
Copy link
Member

Urgau commented Dec 10, 2025

I agree that triagebot's sub-chapters take too much space. Collapsing from the top-chapter seems fine.

As an extension to folding the chapters, we can probably move some chapters around to make them more discoverable.

@apiraino
Copy link
Contributor

Noting that the chapter folding does not seem to work without javascript enabled.

(I don't mean to diss on this proposal, I guess I'm just in the minority when testing these cases)

@jieyouxu
Copy link
Member

Noting that the chapter folding does not seem to work without javascript enabled.

(I don't mean to diss on this proposal, I guess I'm just in the minority when testing these cases)

No that's appreciated, especially if there's an much bigger issue of not just "folding don't work" but "all the subchapters get hidden and you can't unhide them unless you have js enabled".

@jieyouxu
Copy link
Member

I do agree that the current chapters are getting a bit unwieldy, so I would be both in favor of:

  1. Trying out the folding in this PR. At worst, we can revert.
  2. We can also do some reorganization, as Urgau mentioned.

Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@jieyouxu jieyouxu merged commit e02561a into rust-lang:master Dec 11, 2025
1 check passed
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants