Okay
  Public Ticket #1998198
One Product image becomes a gallery and flashes briefly
Closed

Comments

  •  1
    Jamal started the conversation


    With the addition of a single product image, once a property, such as size, is selected, a second (same) image appears. It becomes a gallery, so to speak, although only one product image has been added. And the picture flashes briefly, as if it is reloaded. This does not appear in the older version (2.11). Only with the newest "3.4.4" and with Woocommerce version "3.5.8".

    A live version, I can add on request. Currently being local.

    Thanks


  • [deleted] replied

    Hi Jamal,

    I took a look at the issue and you are right, it is happening also in our demos. So I have fixed it and here is the quick fix for you:

    Download this file and replace it in this directory (of the theme): /wp-content/themes/aurum/inc/

    I have tested and it worked, the images doesn't flash:

    https://d.pr/v/hKzQKe

  •  1
    Jamal replied

    Thank you. That helped with the flashes.

    The other, bigger problem is:

    One has only one product image, and as soon as a variation selection hits, a gallery appears.
    If you go back to the standard "choose an option", then it seems normal. If I make a largest selection, then a gallery with the same picture appears.


    And I have not added a variation image. If I do that, then I have two (three) images that will be displayed at the same time.

    I have tested this with the standard theme "Twenty Nineteen" and everything works fine without any mistakes. If I ONLY have a product image, then only this appears even if I make a variety selection. If I add an image to the variation, like the size, then only the image changes and the product image swaps. As it should be.


    See video where i show it with the gallery popup and no image swap by product and variation image... AurumVersion: 3.4.5(handle it false) and "Twenty Nineteen"(handle it right) 

    good night and thanks.


  • [deleted] replied

    Hi Jamal,

    Yes, that is true. I have tested another fix and it worked so you won't have this issue anymore when you update to 3.4.6

    We have just submitted the new update and as soon as you update the theme this issue will be fixed. 

    When the update is released you will get an email, please let me know if this worked for you.

  •  1
    Jamal replied

    Hello,

    So the sudden popup of the gallery has gone so far. Thanks.

    BUT, the variation pictures are not displayed, only the product picture. There is no swap. In an old version the Variatons picture appears but there is the error that the product main picture does not disappear and places  dont swaps.

    You have practically two pictures: one as a main picture and one in a variation. For all other themes as they swap the places if you select, for example, color black then only the black product etc .. This bug must still be corrected.

    Thanks.

  • [deleted] replied

    Hi Jamal,

    Sorry about that, I have just noticed that the variation images are not working, so I have fixed this issue:

    https://d.pr/v/BtS6li

    Download this file extract and replace (JS file) it in this directory (of the theme): /aurum/assets/js

    If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.

    So now it works just fine. Please note that current image stays in place.

  •  1
    Jamal replied

    Hi,

    Thank you.

    Try it tonight.

    I watched the video and for sizes is good.


    But what if you have colors several variants ... there should then only the variation image displayed the selected color, as standard in the other themes I tested.


    Kind regards

  •  1
    Jamal replied

    Hi,


    And with the new file from you, flashes briefly again when you have a variation image and product image.

    And the most important of all, what all Themes, which are Free, have: product image is swap with the variation image selection (like color), see video. 


    Thanks

  • [deleted] replied

    Hi Jamal,

    Can you try the following improvement:

    1. Download this file and replace it in this directory (of the theme): /inc/

    2. Download this file (extract it) and replace JS file in this directory (of the theme): /assets/js

    If you don't see the change immediately, please hard-refresh your browser (CTRL/CMD+R) because it takes longer to load the changes, as they are saved in browser cache. Another option is to open new private/incognito window and try if it works.

    See the result:

    https://d.pr/v/9aEFiU


  •  1
    Jamal replied

    Ok. I tested later.


    I have tested with an older version "2.1.1" and there this area works, it seems like it's fine without any errors. See the video. 


    Good evening to you

  •  1
    Jamal replied

    Hello,

    Tested and basically it works. Now the short flash has appeared again. Only when one in on the default value, then no flash by change the size appera By Twenty Nineteen there is not flash if one change the size in any color value.


    See video. Thank you

  • [deleted] replied

    Hi Jamal,

    I understand the point here. I tried adding this Custom CSS to disable the animation of images when it shows to the screen:

    .woocommerce .product-images .woocommerce-product-gallery__image .image-placeholder img {
    transition: none !important;
    opacity: 1 !important;
    }

    So here is the result:

    https://d.pr/v/YJaxC4

    I hope this will solve your issue.

    We use "lazy loading" library in combination with animation when it appears on screen so that uses that "flashing" effect which is unnecessary for you.

  •  1
    Jamal replied

    Thanks for your help and time.

    Just tested and now works :)

    One last thing, probably small ...

    With the product / variation pictures it is possible that also the given "ALT" text is displayed or you can adjust it via the child theme via filter / action.


    Now it is:


    "<img role="presentation" alt="EMPTY NOT SEO FRIENDLY" src="https://..." class="zoomImg" style=style.">"

    Thank you.

  • [deleted] replied

    Hi Jamal,

    I am glad that it worked for you.

    Regarding the Zoom image, it is not something our theme generates, WooCommerce uses jQuery Zoom plugin to generate the zoom image which is not applying the alt attribute, neither official WooCommerce Store Front theme does:

    medium
    (view large image)

    medium
    (view large image)

    So I have checked the plugin API and there is no option to add alt attribute for zoom image, you can check here the plugin API:

    https://www.jacklmoore.com/zoom/

    You may contact the plugin developer and ask them why the alt tag for image is not assigned for .zoomImg element.

  •  1
    Jamal replied

    Hi,


    Have looked at GitHub and there it was already solved.

    https://github.com/jackmoore/zoom/issues/134

    Thanks for your help.

    Then one can close the ticket now