Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 293902

Layout overrides cannot be translated

$
0
0

Problem/Motivation

You cannot update the Layout of a translated entity when you allow layout overrides per entity.

To reproduce:

1. Add a new language and enable translation for the Basic page content type.
2. Enable Layout Builder and tick Allow each content item to have its layout customized.
3. Create a Basic page in its original language.
4. Translate the Basic page to the new language.
5. Update the Layout of the translated node and Save the layout.

Expected result:

The translated node should have its layout updated.

Current behaviour:

The original node layout has been updated.

Layout Builder loads the wrong entity.

Proposed resolution

There are a few things that need to be done:

  • Update getSectionListFromId() to load the correct translation of an entity by using EntityRepository::getTranslationFromContext.
  • Clone the inline blocks for the translated node, if the original node has an override.

Remaining tasks

User interface changes

API changes

Data model changes


Viewing all articles
Browse latest Browse all 293902

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>