WooCommerce – Switch Image Background On Color Variation Selection (Image Gallery & Navigation Thumbnails)

Setup: WooCommerce Variable Product for t-shirts with multiple colors and multiple sizes. Theme: GeneratePress. Primary image is of a t-shirt with artwork on it. Secondary image is a close-up of just the artwork with a colored background that matches the color of the t-shirt. Since there are multiple t-shirt colors (and multiple designs), I don’t…