Main Navigation Menu
The main navigation menu that is displayed in the storefront is rendered within main_menu layout block that is present on all pages. The name of the main navigation menu is fetched from the system configuration - oro_commerce_menu.main_navigation_menu that has a default value - commerce_main_menu.
Note
commerce_main_menu is originally declared in the @OroCommerceMenuBundle/Resources/config/oro/navigation.yml
.
Main navigation menu makes use of Menu Templates mechanism to render the top-level menu items.
Navigation Root Menu Items
The main navigation menu is automatically populated with menu items by the menu builder Oro\Bundle\CommerceMenuBundle\Builder\NavigationRootBuilder
taking data either from Web catalog or Master Catalog. Depending on the system configuration the menu builder delegates the responsibility to inner builders:
Oro\Bundle\CommerceMenuBundle\Builder\WebCatalogNavigationRootBuilder
that sets the Web Catalog navigation root content node to the root menu item turning it into the Content Node Menu Item.
Oro\Bundle\CommerceMenuBundle\Builder\MasterCatalogNavigationRootBuilder
that sets the Master Catalog root category to the root menu item turning it into the Category Menu Item.