test
parent
da8e5f01af
commit
a9dc1e76ac
|
@ -1134,15 +1134,13 @@ class VariantSelects extends HTMLElement {
|
|||
|
||||
console.log('mediaGallery.elements.thumbnails', mediaGallery.elements.thumbnails);
|
||||
|
||||
let index = 0;
|
||||
|
||||
for (const galleryImage of galleryImages) {
|
||||
// if display is not none, then show the image
|
||||
console.log("galleryImage.getAttribute('thumbnail-alt')", galleryImage.getAttribute('thumbnail-alt'));
|
||||
if (galleryImage.getAttribute('thumbnail-alt') === this.currentVariant.featured_image.alt) {
|
||||
|
||||
if (index <= 0) {
|
||||
index++;
|
||||
// check if galleryImage is a video
|
||||
if (!galleryImage.classList.contains('thumbnail-list__item--video')) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue