Change product variant according to clicked image Brooklyn theme

Highlighted
Shopify Partner
10 0 2

Hello everyone. I've been struggling for a couple of days to make one feature work and can't seem to find the solution. All I want is that customer clicks on the image (thumbnail) of the product and it automatically changes the product variant from the dropdown menu. Same as described here: https://help.shopify.com/en/themes/customization/products/variants/select-variants-by-clicking-image... but for Brooklyn Theme. In my case I don't have colors, I have Lego Characters (https://legoavengers.com/products/free-lego-compatible-ninjago-sets). Any feedback is very appreciated!

1 Like
Shopify Expert
2684 67 787

Have you tried to implement the tutorial? Briefly, I see that you will probably need to replace 

thumbnails = $('img[src*="/products/"]').not(':first');

with 

thumbnails = $('.product-single__thumb');

and 

'.single-option-selector:eq('

with 

'.single-option-selector__radio:eq('

I'd recommend you to make a theme duplicate and try appying the code. If not working -- share the preview link here.

Want to hire me to tweak a theme? Mail me at tairli@yahoo.com!
My post solved your problem? Like it!
I am away till Feb-15.
5 Likes
Highlighted
Shopify Partner
10 0 2

Oh my god! You are the real hero! Thank you very much! It works like a charm!

1 Like
Highlighted
New Member
1 0 0

Nevermind

0 Likes
Highlighted
Shopify Partner
1 0 0

Nice! I have the same plan in my Brooklyn theme. I'm confuse if where will I start since the instruction were meant to different theme. Could you help me on the details. Thanks in advance.

0 Likes
Highlighted
Shopify Partner
9 0 0

Also on Brooklyn. It seems to only work when selecting an image on desktop mode. On mobile, when flicking through the images, the variants do not change.

How can we also make this work on mobile?

 

Thanks in advance!

0 Likes
Highlighted
Tourist
20 0 0
I’m also interested and also on Brooklyn!
0 Likes
Highlighted
New Member
1 0 0

please give me the soution for this problem

 

i cant select variant according  to images ,  I am using brooklyn theme

0 Likes
Highlighted
Excursionist
20 0 4

I did everything described and unfortunately it doesn't work for the Brooklyn theme. Nothing has changed.

0 Likes
Highlighted

@elena79rus wrote:

I did everything described and unfortunately it doesn't work for the Brooklyn theme. Nothing has changed.


Hey @elena79rus  are you still looking for this ?

With the @tim  changes has worked to me ... but ... with a sutil detail ... I had to change variant selector to DROPDOWN ...

 

But in mobile even with this adapt ... the feature really do not work  with BROOKLYN theme but works for Debut Theme both ... I still checking about mobile in BROOKLYN 



 

William Alencar
GoodFy Labs
Brazilian Shopify Experts
Getting Satisfied Customers around the World
Skype : william.br1
0 Likes