jQuery(document).ready(function(n){if(n(document.body).hasClass("elementor-editor-active"))return!1;n(document).on("click",".product a.compare:not(.added)",function(o){o.preventDefault();var e=n(this),o={action:yith_woocompare.actionadd,id:e.data("product_id"),context:"frontend",security:yith_woocompare.add_nonce},t=n(".yith-woocompare-widget ul.products-list");"undefined"!=typeof n.fn.block&&(e.block({message:null,overlayCSS:{background:"#fff url("+yith_woocompare.loader+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}}),t.block({message:null,overlayCSS:{background:"#fff url("+yith_woocompare.loader+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}})),n.ajax({type:"post",url:yith_woocompare.ajaxurl.toString().replace("%%endpoint%%",yith_woocompare.actionadd),data:o,dataType:"json",success:function(o){"undefined"!=typeof n.fn.block&&(e.unblock(),t.unblock()),e.addClass("added").attr("href",o.table_url).text(yith_woocompare.added_label),t.html(o.widget_table),"yes"==yith_woocompare.auto_open&&n("body").trigger("yith_woocompare_open_popup",{response:o.table_url,button:e})}})}),n(document).on("click",".product a.compare.added",function(o){o.preventDefault();o=this.href;void 0!==o&&n("body").trigger("yith_woocompare_open_popup",{response:o,button:n(this)})}),n("body").on("yith_woocompare_open_popup",function(o,e){e=e.response;if(768<=n(window).width())n.colorbox({href:e,iframe:!0,width:"90%",height:"90%",className:"yith_woocompare_colorbox",close:yith_woocompare.close_label,onClosed:function(){var e=n(".yith-woocompare-widget ul.products-list"),o={action:yith_woocompare.actionreload,context:"frontend",security:yith_woocompare.reload_nonce};"undefined"!=typeof n.fn.block&&e.block({message:null,overlayCSS:{background:"#fff url("+yith_woocompare.loader+") no-repeat center",backgroundSize:"16px 16px",opacity:.6}}),n.ajax({type:"post",url:yith_woocompare.ajaxurl.toString().replace("%%endpoint%%",yith_woocompare.actionreload),data:o,success:function(o){"undefined"!=typeof n.fn.block&&e.unblock().html(o),e.html(o)}})}}),n(window).resize(function(){n.colorbox.resize({width:"90%",height:"90%"})});else{var t=e.split("?");if(2<=t.length){for(var a=encodeURIComponent("iframe")+"=",r=t[1].split(/[&;]/g),c=r.length;0