Quantcast
Viewing all articles
Browse latest Browse all 49209

GSOC idea: Prepare menu_block module for Drupal 8 core inclusion

Drupal core's menu module provides “strict hierarchical” information architecture with its menu system. Menu module currently provides just 3 ways to navigate that strict hierarchy:

  1. Breadcrumbs output to the $breadcrumbs variable in page.tpl.php
  2. Blocks containing full menu trees that can be navigated by clicking into deeper levels of the menu.
  3. A list of links that represent a single level of a menu tree. Output to the $main_menu and $secondary_menu variables in page.tpl.php

Option #1 works fine in core.

Option #2 is very limited because IA presentation on many websites don't follow the basic site navigation available with this option. Core should provide a way to easily create sub-trees or slices of menus as blocks.

Option #3 is a total PITA. Hard-coded variables are annoying and make it impossible for site admins (who aren't themers) to change positioning of them. We should be able to convert those into blocks, but we currently can't because of the limitations imposed by option #2.

The Menu block module extends the menu system by allowing site admins to create configurable sub-trees of a particular menu. So moving this module's functionality into core would solve the problems associated with option #2 and option #3.

However, the current menu_block 7.x-2.x branch is a straight port of the D6 version and, thus, uses the menu APIs that were available in D6. There are new menu APIs in D7 that allow you to retrieve sub-trees and menu_block 7.x-3.x needs to be re-worked to use those APIs. That work would be the first step in prepping menu_block for inclusion in Drupal 8.


Viewing all articles
Browse latest Browse all 49209

Trending Articles