Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Move classes out of the preprocess functions and into the Twig templates. Make sure all classes get into the resultant markup, even ones inherited.
Preprocess Functions Modified
core/includes/menu.inc: template_preprocess_menu_tree
core/themes/bartik/bartik.theme: bartik_preprocess_menu_tree
Twig Templates Modified
core/modules/system/templates/menu-tree.html.twig
Comment | File | Size | Author |
---|---|---|---|
#6 | move_menu_classes_from-2324661-6.patch | 2.62 KB | lauriii |
Comments
Comment #1
pwolanin CreditAttribution: pwolanin commentedI'll take a shot at this today
Comment #2
dawehnerI am sorry but isn't this a clear duplicate of #1777332: Replace theme_menu_link() and menu-tree.html.twig with a single Twig template ?
Comment #3
pwolanin CreditAttribution: pwolanin commented@dawehner, well this is about re-arranging the classes only
Comment #4
star-szrComment #5
star-szrComment #6
lauriiiComment #7
Wim LeersI think this will conflict heavily with #1777332: Replace theme_menu_link() and menu-tree.html.twig with a single Twig template.
Comment #8
dawehnerso
Comment #9
davidhernandez#1777332: Replace theme_menu_link() and menu-tree.html.twig with a single Twig template has been committed.
Comment #10
davidhernandezI'm assuming at least a reroll?
Comment #11
davidhernandezComment #12
lanchez CreditAttribution: lanchez commentedComment #13
lanchez CreditAttribution: lanchez commentedThis does not seem to be a relevant issue anymore.
Comment #14
lauriiiThere's no more
template_preprocess_menu_tree