Right hand side table of contents does not scroll/is too verbose #5636
-
I am using material for mkdocs, and I have the right-hand-side table of contents enabled. However, because my documentation pages are long and highly nested the TOC doesn't fit. I have toc.follow enabled, but as I scroll down, the TOC does not scroll, it just stays at the top. This is the theme section of my mkdocs.yml theme:
name: material
features:
- navigation.instant
- navigation.tabs
- navigation.path
- content.code.annotate
- toc.follow
- navigation.tracking I am using v9.1.16. I am a 'supporter' on github but have never actually installed the restricted version. Any thoughts on why this would not be working? Separately, what I really wish I could do is only show a top-level TOC (just the ## elements). I think that would clean up the TOC a lot and make it more useful. I think that is not a feature, is there any way to achieve that that I am missing? If none of that is possible, is there a global way to turn off the TOC? I see I can do it in the frontmatter, but it would be nicer to just turn it off globally. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Thanks for asking. Anchor following was released in 8.5.0, so there's no necessity for Insiders, you can just use our community edition. Next, you can limit the levels that go into the table of contents by configuring it in In order to investigate any issues why the table of contents only stays at the top when scrolling, we're going to need a runnable minimal reproduction. We're then happy to look into it. Please read our bug reporting guide carefully, as it explains everything. |
Beta Was this translation helpful? Give feedback.
-
Fantastic. The markdown_extensions:
- toc:
toc_depth: 3 Resolved the issue for me. Sorry I missed that in the docs. Thanks for your help. |
Beta Was this translation helpful? Give feedback.
Fantastic. The
Resolved the issue for me. Sorry I missed that in the docs. Thanks for your help.