Would anybody know the code for functions.php for this?
I have a product. It has three colors and comes with three sizes. I've already added code to allow color to be selected and change the corresponding variation image without having to select size. Step 1. Done.
Next I want to FORCE variations to always be selected. In the product tab, I can set the 'default color and default size' to a specific variation. This is ok, but i can still DESELECT the current selected color (meaning, all off the image gallery gets shown). What I need is to make sure that the customer cannot deselect any swatch/variation on the color selection, and instead, can only choose another color.
To clarify, it would behave like Zara's website. You can see, when selecting color, you cannot deselect a color and instead simply changes the variation images according to which one is selected. Note that a size doesn't have be selected for this either atmo.
https://www.zara.com/us/en/premium-cotton-shirt-p04174015.html?v1=172577525&v2=2025627
I also want to remove 'choose an option' completely ideally. Any solutions?