Removing an image from an image field on a node does not remove it in other languages

Created on 22 November 2016, about 8 years ago
Updated 5 April 2024, 9 months ago

In a current project we have a node with an image field. This image field is marked as translateble because the alt field of the image should be translated. This means we've set the field to be translateable, but only checked the alt field and not the file field as translatable in the field settings.

This works fine, adding an image will add it to all translations. Replacing the image with a new one replaces it for all translations. Editing the alt text will only change the current translation. All is well.

However, deleting the image in one language will not delete it for all translations. So suddenly they are not synced anymore.

Also, if the client edits the original language that still has the image since it was not deleted, the image will turn up again in the language where it was previously deleted, since adding an image is synced across translations. This seems to me like a bug.

Steps to reproduce
1. Spin up a new Drupal 8.2.3 installation on Simplytest.me
2. Enable the content translation module and Add a new language
4. Go to /admin/config/regional/content-language
5. Check "Content" and check "Article" to enable translation for that node type. Make sure the Image field is checked as translatable but the "File" checkbox is off (it should be by default).
4. Create a new Article node and upload an image
5. Translate the article, (it will have the image populated automatically) and save the translation.
6. Edit the translation and remove the image.
7. Visit the node in the original language.

Expected result
The image is removed in the original language as well.

Actual result
The image is still there. Editing this node and saving it will recreate the image in the translated version.

πŸ› Bug report
Status

Closed: duplicate

Version

11.0 πŸ”₯

Component
Image systemΒ  β†’

Last updated 1 day ago

Created by

πŸ‡ΈπŸ‡ͺSweden reekris

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