Shopify themes, liquid, logos, and UX
I added the below code and now every variants have the same picture and one can't differentiate in color variant
Code replaced in product-variant-options-liquid line 62 to 65
<label for="{{ section.id }}-{{ option.position }}-{{ forloop.index0 }}">
{{ value -}}
<span class="visually-hidden">{{ 'products.product.variant_sold_out_or_unavailable' | t }}</span>
</label>
with;
{% if product.variants[forloop.index0].image != blank and option.name == 'Color' %}
<label
for="{{ section.id }}-{{ option.position }}-{{ forloop.index0 }}"
style="background-image: url({{ product.variants[forloop.index0].image | img_url: '' }});height:40px;width:40px;background-size: cover;"
></label>
{% else %}
<label for="{{ section.id }}-{{ option.position }}-{{ forloop.index0 }}">
{{ value -}}
<span class="visually-hidden">{{ 'products.product.variant_sold_out_or_unavailable' | t }}</span>
</label>
{% endif %}
Hi @Zeshanzaidi
Please provide your store URL and password if store is password protected and also the name of the theme.
Buyhub.store
Hello @Zeshanzaidi,
Please follow this tutorial because it's very helpful.
yes dawn 12.0.0 no color swatches. image swatches. in the picker the customer should see the pictures of the variant, like in aliexpress
Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025