Problem/Motivation

In Thunder we are using blazy, slick and slick_media. Our gallery is a media_entity_slideshow which contains lots of media_entity_images.
We are rendering the gallery in "Slick Media" format with the option vanilla mode. The selected view mode renders the images in format "Blazy"

So the problem is, if you are on a page with a gallery, just the first two images will be shown. If you step to the third one and further, these images will not be loaded.
I found out, if you resize the browser, the image will be loaded.

This problem occurs in beta6 and still is in the rc.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

CommentFileSizeAuthor
#3 blazy-gallery-not-loaded-2846560.patch3.38 KBgausarts
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

chr.fritsch created an issue. See original summary.

gausarts’s picture

Status: Active » Postponed (maintainer needs more info)

Thanks for the report.

Based on your info, it is like a slideshow with multiple visible images at a time:
https://www.drupal.org/files/project-images/slick-carousel.jpg

Or a single image visible at a time?
Or could you provide a screenshot of the issue so I can narrow down the issue?

...with the option vanilla mode. The selected view mode renders the images in format "Blazy".

Vanilla option needs more love ;)
It has potential broken things as mentioned in the provided form item description disclaimer.

One potential issue I can see is dup of blazy class and [data-blazy] attributes which are output from Blazy itself, and the Slick formatters.

I haven't verified if it is the actual root cause, but a potential.

Possible solutions if the above is the root cause:

  1. You can either remove Blazy field attributes manually using hook_preprocess_field() to stop Blazy from outputting those attributes when it is used within Slick, under other certain conditions.
  2. Or this is solved if you use non-vanilla option.

You can verify #2 above:
Replicate the basic slideshow with non-vanilla option, and see if the problem persists, or not.

gausarts’s picture

Status: Postponed (maintainer needs more info) » Needs review
FileSize
3.38 KB

Let's see if revalidate() fixes the issue.

This is called once, and only cares to revalidate visible images which are normally seen within a carousel with multiple visible images at a time. The rest of hidden images will not be loaded till visible on scroll, or forced by Slick load when slide changes.

chr.fritsch’s picture

Nice, seems that this issue is fixed with the patch

  • gausarts committed c05974d on 8.x-1.x
    - #2846560 by gausarts, chr.fritsch: Images of gallery will not be...
gausarts’s picture

Status: Needs review » Fixed

Committed. Thank you for contribution.

Status: Fixed » Closed (fixed)

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