!function(e){"use strict";e(document).on("click",".js-wvs-migrate-btn",(function(a){a.preventDefault();var t=e(this);t.addClass("--loading disabled"),e.ajax({url:reyCoreAdmin.ajax_url,cache:!1,data:{action:"reycore_variation_swatches_wvs_migration",security:reyCoreAdmin.ajax_nonce},success:function(e){e?(t.text("Reloading page.."),setTimeout((function(){window.location.reload()}),1e3)):t.text("Something went wrong! Please refresh..").removeClass("--loading")}})})),e(document).on("click",".js-rey-button[data-action='reycore_variation_swatches_wvs_migration']",(function(a){var t=e(this),n=t.attr("data-action")||"";n&&(a.preventDefault(),t.addClass("--loading disabled"),e.post({url:reyCoreAdmin.ajax_url,data:{action:n,security:reyCoreAdmin.ajax_nonce},success:function(e){t.closest(".customize-control").hide()}}))}))}(jQuery);