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

Config entities should implement TranslatableInterface

$
0
0

Problem/Motivation

Viewing a webform via an entity reference formatter in any language which is not the interface language doesn't display the desired translation.

Steps to reproduce

  1. Set up language negotiation so that content and interface are separate
  2. Set up a webform reference field on a translatable content entity type
  3. Add a webform and translate it
  4. Add such a content entity and translate it and refer the webform
  5. View the translated entity

Proposed resolution

If config entities implemented TranslatableInterface methods then EntityReferenceFormatterBase would, as if by magic, suddenly be able to display translated config entities in the correct langcode.

As an aside, the base TranslatableInterface is currently in the TypedData namespace but there's no reason it should be as none of the methods take or return typed data. The entity version of it extends it but I think the base version should be somewhere else more generic. This is probably a separate issue.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet


Viewing all articles
Browse latest Browse all 294415

Trending Articles



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