_filterThumbnails: function(variant) { $('[thumbnail-color]').hide(); if (variant.featured_image != null && variant.featured_image.alt != null) { var selected_color = variant.featured_image.alt; var thumbnail_selector = '[thumbnail-color="' + selected_color + '"]'; $(thumbnail_selector).show(); } else { $('[thumbnail-color]').show(); } },