"use strict";const Whizzie=function($){let e,t="",i="";const a={do_next_step:function(e){s(e)},activate_firewall:function(e){const t={action:"secnin_activate_firewall",_ajax_nonce:whizzie_params.nonce};$.get(ajaxurl,t,(function(e){e.success?s():console.error("Error:",e.data)})).fail((function(e,t,i){console.error("AJAX error:",t,i)}))},activate_default_fixes:function(e){const t={action:"secnin_activate_default_fixes",_ajax_nonce:whizzie_params.nonce};$.get(ajaxurl,t,(function(e){e.success?s():console.error("Error:",e.data)})).fail((function(e,t,i){console.error("AJAX error:",t,i)}))},activate_woocommerce:function(e){const t={action:"secnin_activate_woocommerce",_ajax_nonce:whizzie_params.nonce};$.get(ajaxurl,t,(function(e){e.success?s():console.error("Error:",e.data)})).fail((function(e,t,i){console.error("AJAX error:",t,i)}))}};function n(){!function(){let e=0;$(".whizzie-menu li.step").each((function(t){$(this).attr("data-height",$(this).innerHeight()),$(this).innerHeight()>e&&(e=$(this).innerHeight())})),$(".whizzie-menu li .detail").each((function(e){$(this).attr("data-height",$(this).innerHeight()),$(this).addClass("scale-down")})),$(".whizzie-menu li.step").css("height",e)}(),$(".whizzie-menu li.step:first-child").addClass("active-step"),$(".whizzie-nav li:first-child").addClass("active-step"),$(".whizzie-wrap").addClass("loaded"),$(".whizzie-wrap").on("click",".more-info",(function(e){e.preventDefault();const t=$(this).parent().parent();t.toggleClass("show-detail");const i=t.find(".detail"),a=t.data("height");t.hasClass("show-detail")?t.animate({height:a+i.data("height")},500,(function(){i.toggleClass("scale-down")})).css("overflow","visible"):t.animate({height:a},500,(function(){i.toggleClass("scale-down")})).css("overflow","visible")})),$(".whizzie-wrap").on("click",".do-it",(function(e){return e.preventDefault(),i=$(this).data("step"),t=$(`.step-${i}`),$(".whizzie-wrap").addClass("spinning"),!$(this).data("callback")||void 0===a[$(this).data("callback")]||(a[$(this).data("callback")](this),!1)}))}function s(e){t.removeClass("active-step"),$(`.nav-step-${i}`).removeClass("active-step"),t.addClass("done-step"),$(`.nav-step-${i}`).addClass("done-step"),t.fadeOut(500,(function(){t=t.next(),i=t.data("step"),t.fadeIn(),t.addClass("active-step"),$(`.nav-step-${i}`).addClass("active-step"),$(".whizzie-wrap").removeClass("spinning")}))}return{init:function(){e=this,$(n)},callback:function(e){}}}(jQuery);jQuery(document).ready((function(){Whizzie.init()}));