[META] Decouple layouts from themes

Created on 18 September 2012, over 12 years ago
Updated 27 June 2023, over 1 year ago

Problem/motivation

Drupal themes just ship with hardwired layouts. If users want to apply different layouts to different pages, the theme code needs to be modified. There are solutions working around this whole system by overriding the page rendering and swapping out built-in regions and blocks altogether.

Solution proposal

We should support this use case much better by declaring layouts (and regions per layouts) explicitly within the theme. Then that should allow users to identify which layout to use per page and would need to shift blocks to relate to layouts instead of themes. The proposal is to:

  1. #1787846: Themes should declare their layouts - Identify layouts from themes either via .info file properties or plugin definitions or .yml config files or an automatic tpl.php discovery mechanism. Possibly also make themes define regions for each layout (although we can probably assume the same regions across all layouts in a theme for now).
  2. #1839278: Add layout template demonstration - Demonstration of layout templates defined by modules and themes for user review.
  3. #1841584: Add and configure master displays - Edit master layouts with global blocks
  4. Add simple blank page creation capability Needs work - Introduce simple page creation feature with fixed path and block placement.
🌱 Plan
Status

Active

Version

11.0 🔥

Component
Theme 

Last updated 5 days ago

Created by

🇭🇺Hungary Gábor Hojtsy Hungary

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024