Problem/Motivation
In the menu-region--footer.html.twig file the menu_heading_id variable is used to set the id attribute value for the h4 tag. However the variable assignment is missing in the code thus resulting in id attribute with no value.

Steps to reproduce
1. Install Navigation module.
2. Inspect the templates HTML output and see that id has no value.
Also {{ dump(menu_heading_id }} returns null.
Proposed resolution
Add {% set menu_heading_id = 'menu--' ~ menu_name|clean_unique_id %} to templates/menu-region--footer.html.twig to assign value to menu_heading_id.
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
| Comment | File | Size | Author |
|---|---|---|---|
| Screenshot 2024-04-27 at 16.36.34.png | 27.63 KB | julilan |
Issue fork drupal-3443899
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
- 3443899-menu-heading-id
changes, plain diff MR !7801
Comments
Comment #2
julilan commentedComment #3
julilan commentedComment #4
julilan commentedComment #6
julilan commentedComment #7
smustgrave commentedChecking navigation-menu.html.twig this appears to be the same solution, so believe it is good.
Thanks!
Comment #9
nod_Awesome, thanks a lot for the clear issue summary and the MR!
Comment #12
catch