-
Notifications
You must be signed in to change notification settings - Fork 25.6k
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
scrollable sticky toc (enhancement request ) #1851
Comments
Don't know if this could be done gracefully. The right sidebar is a huge hack right now because it supports Markdown auto TOCs and a Liquid helper that creates the TOC. The placement of the HTML is more flexible with the Liquid helper method, but styling it in a way to not break Kramdown TOCs is challenging. I prefer the pattern of not sticking the TOC and having it scroll with the content. For documentation heavy sites the left nav sidebar is a better place for adding waypoints. I'm willing to bet most people ignore the sidebar anyways. There's likely few people who are going to be bouncing around multiple headings on a single page. Sticky sidebars and "back to top" links are things people like to add to their site just because they can. But I don't think they add value to most users, other than clutter up the page more. |
You had me convinced about the added visual clutter because of table of contents. Personally I too give less attention to them. However this may be a dormant feature in the theme. Also the bug in the current My main motive was to get your attention to this closed issue - link1 You can see in link 2, he have implemented the scrollable toc. Check this commit Again I would say that the present system of |
Link2 is super buggy for me. There's all sorts of screen flashes and inconsistencies with how the page scrolls, don't think that's a particularly good solution. As far as right sidebars that get cutoff. This is one of the reasons I was hesitant to add a sticky behavior. If your body content is shorter than the height of the table of contents, it's going to extend beyond the viewport. Either turn off the stickiness or limit what headlines are used to make it shorter. |
Thanks for the pointer to limit headlines. |
This issue has been automatically marked as stale because it has not had recent activity. If this is a bug and you can still reproduce this error on the If this is a feature request, please consider whether it can be accomplished in another way. If it cannot, please elaborate on why it is core to this project and why you feel more than 80% of users would find this beneficial. This issue will automatically be closed in 7 days if no further activity occurs. Thank you for all your contributions. |
In reference to closed issue on this repo - Link
The asked person had made a custom fix.
However If I may request for this feature in the theme, because having lengthy table of contents overflowed from the page and are not reachable.
@mmistakes - Would you like to introduce it?
The text was updated successfully, but these errors were encountered: