Disable layouts for entity views and entity forms by default

Created on 23 May 2019, almost 6 years ago
Updated 16 May 2025, 3 days ago

Problem/Motivation

When adding layout_discovery to an existing project it defaults all layouts to layout_onecol which can wreak havoc on existing layouts since it overrides the custom templates for all entities.

Proposed resolution

Create a new default layout_disabled layout and add a check to field_layout that ignores the buildView() call if disabled is set.

Remaining tasks

  1. Need to look into effect on layout_builder module if any
  2. Needs tests
  3. Needs reviews

User interface changes

This adds a new "Disabled" option to the field_layout select field and changes the default from "One column".

Release notes snippet

In order to make layout_discovery more agnostic to current template settings a new "Disabled" layout option has been added as the default layout. This allows users to choose which entities should opt-in to layouts.

πŸ› Bug report
Status

Postponed

Version

11.0 πŸ”₯

Component

field_layout.module

Created by

πŸ‡ΊπŸ‡ΈUnited States audioroger Bristol, VT

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