vsoch/docsy-jekyll

Is there a way to make links collapsible in the sidebar?

SetpointCapybara opened this issue · 1 comments

Is there a way to edit the sidebar.html file in order to make the sections of the toc.yml (like "Documentation" or "Extras" in the example site: https://vsoch.github.io/docsy-jekyll/) collapsible just like in the Pandas API Reference (https://pandas.pydata.org/docs/reference/index.html)? In the Pandas documentation, only when you click the name of a section (like Input/output, General functions, etc...) do the pages related to that section appear. Is there a way to easily implement this behavior using the Docsy Jekyll Theme?

vsoch commented

The entire thing is just a website, so you'd need to edit the sidebar.html with your custom (likely) javascript, and css classes to control that. If I were doing it I'd take a look at how that site does it. A very simple way is to add identifiers to the top level and children, and then add an "on click" event for the parent that toggles the visibility of the children.