Nested Sidebar Categories or Subcategories

:information_source: Summary Indents / nests selected categories or subcategories in the sidebar
:hammer_and_wrench: Repository https://github.com/Lillinator/discourse-nested-categories
:eyeglasses: Preview Preview on Discourse Theme Creator
:question: Install Guide How to install a theme or theme component
:open_book: New to Discourse Themes? Beginner’s guide to using Discourse Themes

Install this theme component

This is a simple theme component that allows admins to select categories or subcategories to indent (or nest) in the sidebar. Most people will want to indent only subcategories of course, to make them look nested, but you can indent any of your listed categories. Works in both desktop and mobile view, as well as header drop-down menu. Thanks to @dax for some of the code.

There is one setting - a category selector:

Screenshot of result in sidebar categories section:

21 Likes

Yes!!! This is one step towards finally being able to use the sidebar!

2 Likes

Nice work, @Lilly!

It doesn’t quite hit the need of my instance, however. I’ve got a lot of subcategories and only a few categories - and the subcategories are quite dynamic.

It would be better for our instance if all categories+subcats were indented by default and the list was for the categories that shouldn’t be indented.

2 Likes

Hmmm, let me think about this - I see what you mean. Let me tinker with it a bit, but I’ll address your use case either way (with a separate component or a couple of additional settings). I was also thinking of including a setting that allowed for formatting or hiding the subcategory bullets. :thinking:

3 Likes