Take off the sub catégorie on the display panel

AI-generated summary

The discussion revolves around removing subcategories from the display panel. Jeremie_Leroy asked for help on how to achieve this, and Johani provided a solution using CSS: .menu-panel li.subcategory { display: none; }. This code worked for Jeremie_Leroy. Duane asked for clarification on where to add the code and if subcategories would still be visible when clicking on the main category. Benjamin_D provided the location to add the code (https://your.domain/admin/customize/themes/1/common/scss/edit) and confirmed that subcategories would still be visible on the category page.

Hi all,

I hope you are well. Could you let me know how to only display catégories and not the sub-catégorie. Here is below what i have which look messy in my opinion.

Many thanks for your help,

I don’t think there’s a setting for that but I could be wrong.

In case there isn’t, you can use this to hide subcategories:

.menu-panel li.subcategory {
    display: none;
}

Yep great, it does the job perfectly.

Thanks a lot

If there isn’t another way to hide subcategories I’d like to add this to my site. Two questions… 1) Where exactly is this code added and 2) do the subcategories still show if you click on the main category?

Thanks in advance!!

I think that would be there:
https://your.domain/admin/customize/themes/1/common/scss/edit

(for my setup, with 1 for the dark theme, 2 for light, etc depends of your theme)

yes, if you mean on the category page, that’s the purpose of .menu-panel

@Benjamin_D thank you very much!!