Create theme template suggestions for overridden pages

Created on 9 April 2024, 8 months ago
Updated 5 June 2024, 6 months ago

DOD: For each override category, create a template suggestions

page__override_{type}
page__override_{type}__{entity_type}
page__override_{type}__{entity_type}__{bundle}
page__override_{type}__{override_page_key}

In PHP, be sure to replace the "override page key" dot with an underscore. So node.123 would become node_123. This of course would become a hyphen in Twig node-123.

Examples:

page--override-sidebars.html.twig
page--override-body.html.twig
page--override-all.html.twig

Example of the suggestions cascade for overriding sidebars:

page--override-sidebars--node-123.html.twig
page--override-sidebars--node--article.html.twig
page--override-sidebars--node.html.twig
page--override-sidebars.html.twig
✨ Feature request
Status

Fixed

Version

1.0

Component

Code

Created by

🇺🇸United States segovia94

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024