Contextual crop does not work with responsive image styles

Created on 28 July 2023, over 1 year ago
Updated 17 August 2023, over 1 year ago

When I create a responsive image style using Drupal core's "Responsive Image" module and include my individual image styles in breakpoints the crop that was selected for the image is not applied. If I change the image from using a responsive image and just use one of the individual image style to render the image then the crop works.

I know responsive image styles work when I used Image Widget Crop module on it's own but when I use the "Media Contextual Crop" suite of modules responsive image styles don't seem to work. Do these modules support responsive image styles? Or will this be added in the Future?

Thank you for your work, It has been what we have been looking to do for a long time.

Feature request
Status

Fixed

Version

1.2

Component

Code

Created by

🇨🇦Canada erichomanchuk

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

Comments & Activities

  • Issue created by @erichomanchuk
  • Assigned to DrDam
  • 🇫🇷France DrDam

    Thanks for report,

    Media Contextual Crop are currently not compatible with image responsive, I'll add this soon.

  • 🇨🇦Canada erichomanchuk

    Thank you @DrDam . Yes we are currently just using a single image style for these modules but we like how this works and want to use this functionality more but would need this to work with responsive images to do so. I am happy to help test when it is ready.

  • 🇫🇷France DrDam

    If you want test, you can use these versions :

    Media Contextual Crop : 1.2.x-dev
    Media Contextual Crop Reference / Media Contextual Crop Embed : 1.3.x-dev
    Media Contextual Crop Focal Point adapter / Media Contextual Crop Image widget crop : 1.1.x-dev

    there's little API changes, but enough to kill retro-compatibility ...

  • 🇫🇷France DrDam

    Hi,

    I'll just publish a new releases for the media_contextual_crop collection in order to manage responsive_image

    So you'll find the folowing releases :

    1.2.0 for media_contextual_crop module
    1.3.0 for media_contextual_crop_embed & media_contextual_crop_field_formatter (media references)
    1.1.0 for media_contextual_crop_fp_adapter (focal_point) & media_contextual_crop_iwc_adapter (Image widget Crop)

    Note : if you work with D9 & the legacy Ckeditor, there is an important note on the media_contextual_crop_embed module about patch management

  • Status changed to Fixed over 1 year ago
  • Status changed to Fixed over 1 year ago
Production build 0.71.5 2024