3

When editing the form display mode of a translatable content entity, there is a field called Translation in the UI. I thought this field would manage the weight/visibility of translation meta data fields (like content_translation_uid or content_translation_outdated) in the entity's edit form.

But moving that field around doesn't have any effect, it neither reorders the position, nore does it hide the Translation <details> element when I move it into the disabled section.

So, what is the real purpose of the field Translation in /admin/structure/ENTITY/manage/BUNDLE/form-display ?

(This is a follow-up of my question Custom content entity: can't hide translation details in edit form)

1 Answer 1

2

This is an extra field (Drupal term for a pseudo field not stored in the database you can move around in UI), which is added when Content Translation is enabled: content_translation_entity_extra_field_info()

See this issue:

content_translation_entity_extra_field_info is obsolete

Problem/Motivation

content_translation_entity_extra_field_info is adding the extra field "Translation" but it is not used by content_translation in the form alter hooks and it only confuses when we are on the form display configuring the fields and reordering it doesn't change anything on the edit page.

Proposed resolution

Remove content_translation_entity_extra_field_info and remove the "translation" component from all saved form display configs.

https://www.drupal.org/project/drupal/issues/2856551

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.