- Issue created by @s_leu
- @s_leu opened merge request.
- Status changed to Needs review
over 1 year ago 9:12am 31 July 2023 - Status changed to Fixed
over 1 year ago 4:55am 2 August 2023 Automatically closed - issue fixed for 2 weeks with no activity.
Resized media images are currently embedded using the default view mode unless the Allow the user to override the default view mode option of the ckeditor5 media plugin is enabled.
If the used view mode isn't applying an image style that will resize the image to a width that is wider than the resize width, the image will look smaller than the width it actually got resized to.
Result the image is still only 480px wide even the resize width is wider.
If we can check the width and provide a set of default image styles the media image would be rendered width dynamically depending on the width, that would solve this problem. The image styles could be applied by using the data-view-mode
attribute of the drupal-media
ckeditor element.
This would happen in the filter and thus only when the content that contains the WYSIWYG field is viewed and not when the text is edited in ckeditor5. To achieve that, we'd have to alter the core media plugin which is more tedious.
Fixed
1.0
Code
Automatically closed - issue fixed for 2 weeks with no activity.