Problem/Motivation

After updating to 1.1.x preview images for Site Studio components fail to load during content entry if not previously generated. Only existing thumbnails in the local file system load correctly.

Steps to reproduce

Upgrade to 1.1.x on a site with Site Studio and some Site Studio components with images from DAM.

DAM images will no longer show a thumbnail in the content entry experience of Site Studio, but will work elsewhere, including saved Site Studio content where the preview failed.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Issue fork acquia_dam-3512214

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:

Comments

ibullock created an issue. See original summary.

ibullock’s picture

Issue summary: View changes
paladyn’s picture

I have the same issue and I manage to solve it by changing one line of code in "src/Plugin/media/Source/Asset.php" - line 283.

return $this->getRemoteThumbnailUri($external_id) ?: $asset['thumbnails']['600px']['url'];

to

return $asset['thumbnails']['600px']['url'] ?: $this->getRemoteThumbnailUri($external_id);

For me $asset['thumbnails']['600px']['url'] - has right preview path and $this->getRemoteThumbnailUri($external_id); generates wrong one.

I was not digging further into it, but I hope it will help someone to fix the source of issue.

pablomoto1000’s picture

StatusFileSize
new565 bytes

Added a patch to enforce widget_table view mode as a quick fix to this missing thumbnails issue in a default D10 site.

vipin.mittal18’s picture

Hello @ibullock, Could you please outline the exact steps to reproduce the issue?

vipin.mittal18’s picture

Solution: Please follow the steps outlined below:

  1. Navigate to /admin/structure/media/manage/acquia_dam_image_asset/display/media_library.
  2. Replace the existing field with the “Asset Reference field.” and set image style along with.
  3. Finally, click “Save.”
vipin.mittal18’s picture

Status: Active » Needs review
vipin.mittal18’s picture

Status: Needs review » Needs work

The v2 structure format is causing issues with thumbnail generation. Therefore, we have decided to serve the thumbnail using v3 as a uniform solution.

rajeshreeputra made their first commit to this issue’s fork.

ankitv18 made their first commit to this issue’s fork.

rajeshreeputra’s picture

Status: Needs work » Needs review

Requesting review.

japerry’s picture

While a cursory look at the code looks ok, it'd be good to get validation here that the issue found with site studio is fixed.

japerry’s picture

Status: Needs review » Fixed

Received validation that it works in Site Studio, fixed!

Status: Fixed » Closed (fixed)

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