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

Usability issues with long TOCs #58

Closed
jbms opened this issue Apr 7, 2022 · 0 comments · Fixed by #99
Closed

Usability issues with long TOCs #58

jbms opened this issue Apr 7, 2022 · 0 comments · Fixed by #99

Comments

@jbms
Copy link
Owner

jbms commented Apr 7, 2022

For API documentation you can easily end up with a very long table of contents in the left and/or right side panels.

This results in two usability issues:

  • The left TOC does not start out scrolled to have the current page in view, and the right TOC does not automatically keep the current section in view. That makes it challenging to understand the context of the current page/section. This feature is apparently implemented in the insiders-only version of mkdocs-material (Automatically position the left navigation to the current page squidfunk/mkdocs-material#2155).
  • When scrolling the left or right TOC, if there are multiple levels of nesting, the ancestors of the current page/section may be scrolled out of view and not visible, which also makes it difficult to understand the context of the current page/section. This could be solved by making the section headers "sticky", so that the headers for each nesting level "collect" at the top of the TOC. An implementation of this is explained here: https://stackoverflow.com/a/55941740
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 a pull request may close this issue.

1 participant