Parent entity link does not work with responsive images

Created on 6 November 2024, about 2 months ago

Problem/Motivation

Despite what is announced in text and illustration in the presentation of the module it doesn't work with responive images, or I'm missing something in settings.

Steps to reproduce

In admin/structure/media/manage/image/display/teaser
- use "image" as formatter, set "link image" to "content" and check the "link to parent entity" with lazy loading: Display a node teaser containing a media image or a view with a media formatted "rendered entity" and view mode "teaser". The image is indeed linked to the node it belongs
- now change "image" formatter" to "responsive image" and chose a "responsive image style". Leave other options as above: The image no more links to the node entity but to the media file display.

In both settings if we set "link image" to "nothing", nothing happens, i.e. no link is displayed. Setting "link image" to "file" it displays the link to the file (not the media file display)

It seems like the media_parent_entity_link no more take precedence to the "link image" setting when formatter is "responsive image"

Using Drupal 10.3.6

Proposed resolution

Restore precedence of media_parent_entity_link over "link image" setting when using "responsive image" formatter, like with the "image" formatter.

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

1.2

Component

Code

Created by

🇫🇷France erwangel

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024