Switch the menu entries to be hierarchial.
Owner:
Ivan Hawkes
Menu System
The menu was hard coded, improve it.
Menu System
- Make it work from front matter in the content
- Set the names, parents and weights of all the menus
- Update the code to use the new metadata
- Make the menu render the hierarchy
Acceptance Criteria
- Every menu entry, its name, parent, weight and icon come from the
menusfront matter of a content file; no entry is hard coded in the theme. - Which menus the sidebar renders, and the nesting depth, come from
sidebar.menusandsidebar.maxDepthinconfig/_default/params.yaml. - Entries nest to three levels: Home, About, Posts at level 1; the sections of About and Posts at level 2; the recipe cuisines at level 3.
- Entries below the configured depth are not rendered.
- The entry for the current page carries
class="active", as do its ancestors; the submenus on that path, including the current entry’s own when it has children, render open and expanded.