Prevent auto translations

Created on 7 December 2020, over 3 years ago
Updated 2 August 2023, 11 months ago

When a user creates a new paragraph field, it applies this value new value to all translations.

It's probably easiest to explain with an example:

Say there is a content type that has a paragraph field (Book Genre), and that paragraph has another paragraph entity field (Title) in it, which has unlimited options. so let’s say...

My Custom Node has the paragraph field field...
--My Paragraph Book Genre which has the sub-paragraph field...
----My Book Titles which have no limit on the number of Titles used.

What’s happening is if English has a Book Genre with 3 Titles, all translations have those three. titles.

I’ve read about this and it seems this is just how paragraphs work and people have talked about creating Asyncronous Paragraph Translations, but nothing seems stable. For now, we can live with the same number of Book Genres being used with each translation.

The problem I’m trying to solve for is, if a user adds a new Title to the En language, that Title is applied to all translations. It would be ok if the field was blank, but it’s problematic that the value is also automatically applied to all languages.

So if a user adds “On the Road” to English, now the Japan page will automatically show “On the Road”. That’s a problem for our case.

I’ve tried translation default values and trying other settings, but haven’t found that it’s possible to set new values to only create in the language being updated.

Is this something I’ll have to write a custom module to try to prevent, or are there settings I’m unaware of.

Thanks

đź’¬ Support request
Status

Needs review

Version

1.12

Component

Code

Created by

🇺🇸United States kid_baco

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.

  • Created Untranslated Paragraph Warning → module to mitigate this problem. Need to use it in conjunction with some custom twig as described on project page.

    I know you can already get some logic together in your twig templates to hide untranslated paragraphs. Also #4 looks interesting, That being said, the next time the translation of the node is saved those paragraphs are going to be classified as translated by Drupal, even if they were not touched. This module detects those untranslated paragraphs and displays a warning message at the top of the node edit form.

Production build 0.69.0 2024