Remove link if no parent is available

Created on 14 September 2023, about 1 year ago
Updated 19 May 2024, 6 months ago

Hi, if a media image is rendered inside a paragraph and it's not strictly related to an entity, the link will point to the media edit page which is not a good behaviour.

The following patch prevent to display an url in this case.

Feature request
Status

Closed: works as designed

Version

1.0

Component

Code

Created by

🇮🇹Italy finex

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

Comments & Activities

  • Issue created by @finex
  • 🇩🇪Germany stefan.korn Jossgrund

    @FineX: what have you chosen for "Link image to" in display configuration for this media type?

  • Status changed to Postponed: needs info about 1 year ago
  • 🇮🇹Italy finex

    Parent content if I remember correctly.

  • 🇩🇪Germany stefan.korn Jossgrund

    I suppose if you choose "Nothing" for "Link image to" you will receive no link in the case you describe.

    The link to the media edit page is the default from Drupal core I suppose and media parent entity link will only come into play if there is a parent entity and this parent entity has a canonical link.

    So I think if you choose "Nothing" for "Link image to" and still check the box "Link to parent entity (if appicable)" you may get the same output that would come with your patch.

    tending to close this with "works as designed", if you do not have any more comments on this.

  • Status changed to Closed: works as designed 6 months ago
  • 🇩🇪Germany stefan.korn Jossgrund
Production build 0.71.5 2024