Category Levels manual.

Installation, level depth per area and sales channel, layout of long lists, linking parent entries, diagnostics and licence. As of version 1.0.22.

System requirements

Shopware 6.7 with storefront, PHP 8.2 or newer. The plugin works on the category navigation and requires shopware/core and shopware/storefront in version 6.7.

No theme build needed: the layout is handled by an embedded stylesheet. A theme:compile is not required after installation.

Installation

Upload the ZIP in the Shopware admin under Extensions, My Extensions, then install and activate it. Afterwards enter the licence key, see Licence.

Clear the cache once after activating. The plugin registers a service that appends to the finished page, and that only takes effect after the container has been rebuilt.

Opening the settings

The plugin comes with its own admin module. It sits inside the Stone & Water plugin suite and is called Category Level Settings.

The sales channel is selected at the top of the page. Everything below applies to that channel. Where no value is set, the respective default applies.

Main navigation levels

Default: 3. Number of category levels in the header menu, adjustable between 2 and 10. The default matches Shopware behaviour without the plugin exactly.

Counting starts at the first category level. At 3 the customer sees the menu bar entries, their children and one further step. At 4 one more step is added.

Check first, then set: a value higher than the depth actually present has no effect, but does no harm either. How deep the tree really goes is shown by the diagnostics.

Default: 3. Number of levels in the sidebar category navigation, that is the category navigation CMS element. The value is independent of the main navigation.

At their core both areas use the same service. The plugin remembers per request which area the call came from and raises the depth only there. The offcanvas menu on mobile is left untouched and keeps the theme behaviour.

Per sales channel

All settings apply per sales channel. The channel is selected at the top of the page and saving affects only that channel. A B2B channel with a deep spare parts tree can therefore be set up differently from a lean consumer shop in the same system.

Checking existing levels

The button Check levels in the shop counts how many category levels actually exist in the selected sales channel and shows the number of categories per level. That removes the guesswork about which value will have any effect.

Long lists in columns

Default: 3 columns. Maximum number of columns for long category lists, selectable as off, 2, 3 or 4.

The setting is an upper limit, not a fixed value. How many columns are needed is worked out in the shop from the number of entries and the space remaining below. A list of twelve entries stays in one column if it fits on screen anyway.

The original menu width serves as the column width. Labels therefore stay exactly as readable as before, there are simply several blocks side by side. If the menu is too narrow for the calculated number of columns, it is widened exactly as far as needed and shifted left where necessary so it stays within the window.

Nested submenus are excluded: if an entry of the list itself carries a submenu, that list is left unchanged. It would otherwise be clipped when opened.

Wrap from

Default: 10 entries. From how many entries a list becomes multi-column at all, adjustable between 4 and 40. Short lists are left alone.

Prevent overflow

Default: on. Limits the height of a long list to the visible area. The height is rounded down to a multiple of the row height, so the box always ends flush with an entry edge and no entry is cut in half.

If the content fits the calculated columns there is no scrolling at all. If it does not, the list scrolls vertically without the page behind it moving along.

Default: on. An entry with a submenu opens its own category page when clicked.

Many themes attach a toggle to such entries which swallows the click, sometimes through an element placed on top of the link. The entry can then no longer be opened although the category has a page of its own. The plugin intercepts the click one step earlier and clears the way to the category.

While the submenu is still closed, the first click keeps opening it. Only once it is open does a click on the parent entry lead to the category. On mobile this produces the familiar pattern: tap once to open, tap again to go there.

Opening in a new tab still works: middle click and clicks with the Ctrl or Command key held are not touched.

Indenting deep levels

Default: off. Indents submenus of deeper levels and puts a fine line in front of them so the nesting stays recognisable. The indentation is drawn purely in the stylesheet, the theme markup is left unchanged.

Storefront diagnostics

If the layout does not look as expected, the parameter ?stawcd=debug in the address helps. The plugin then writes a report to the browser console:

  • the active settings as an overview
  • how many lists the rule matches, with column count, height and width
  • all category containers in the document grouped by build form
  • per longer list each condition individually, so it is readable which one fails
  • all entries with a submenu including link and category identifier

Without the parameter the plugin outputs nothing, so in normal shop operation the console stays quiet.

Caching and hosting

After saving, the plugin invalidates the affected navigation cache entries automatically. If a reverse proxy or CDN sits in front of the shop, its cache has to be cleared as well.

Nothing is loaded afterwards in the storefront and nothing is sent to a third-party server. The stylesheet sits in the page and the column calculation runs in the browser.

Licence

The licence key is assigned through the Stone & Water plugin suite. Validation runs against our licence platform and is cached; the storefront reads only that cache. If the server is unreachable, the last known state remains in force.

Without a valid licence the settings do not take effect in the storefront and the shop behaves as it would without the plugin. A notice appears in the settings in that case.

Troubleshooting

The additional levels do not appear. Use the diagnostics to check how many levels exist in the sales channel at all, then clear the storefront cache.

The list still runs off the screen. Open the page with ?stawcd=debug. If there is no output, the plugin is not in the page, which points to activation, licence or a missing cache run. If it says matched by the rule: 0, the list below shows which condition fails.

A parent entry cannot be clicked. Check under entries with a submenu in the diagnostics whether a link or a category identifier is reported. If neither is there, the theme does not output any reference to the category at that point.

Nothing changes after the update. Clear the cache and reload the page hard so the browser does not keep using the old stylesheet.

Support

Questions, requests and bug reports come straight to us. In the admin module the Request feature button leads to the right address; alternatively use the contact page or call +49 2555 9997342.

Availability

Directly from Stone & Water

Available now

Monthly2.99 €
Half-yearly14.99 €16 % cheaper
Best priceYearly26.99 €25 % cheaper

All prices net, plus VAT.

You buy the licence directly from us and receive an invoice from us. Installation by upload in the admin without SSH, updates through our licence platform, support straight from the developer.

Get in touch +49 2555 9997342

Shopware Store

In preparation

The plugin will be listed in the official Shopware Community Store. Installation and automatic updates then run through the plugin manager in the backend, billing through your Shopware account. We will link it here as soon as it is available.