Problem/Motivation

The preview images for the view modes in an image block are broken when a different interface language is used.

view modes

When seen on another language:

broken view modes

The reason for this seems to be that our rocketship_theme_starter/components/00-theme/01-atoms/05-forms/form-label/_form-label.twig is printing the classes with translated content

In english the class is correct view-mode-1-1-aspect-ratio but in another language the class is view-mode-1-1-aspect-ratio-optioneel so the CSS with the preview image does not apply.

Steps to reproduce

Test adding an image in layout builder while using another interface language besides EN

Proposed resolution

For now the patch targets another class that is available and not changed between languages.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Jolidog created an issue. See original summary.

  • rembrandx committed 5a57122 on 6.x authored by Jolidog
    Issue #3263407: Image block view mode images broken on translated...

Grayle credited rembrandx.

Grayle’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.