This snippet sets the swatch image for the "pa_shade" attribute assigned to each variation. Read the comments for tips on customizing it for other attributes and restricting it to a certain import ID.
# ************************************************************************************************************
# * Import swatches image for the "YITH WooCommerce Color, Image & Label Variation Swatches Premium" plugin. *
# ************************************************************************************************************
add_action( 'wp_all_import_variable_product_imported', 'wpai_wp_all_import_variable_product_imported', 10, 1 );
function wpai_wp_all_import_variable_product_imported( $post_parent ) {