jQuery(document).ready((function($){let e=!1;if($('span.trash a, input[name="bulk_action"]').click((function(a){if(!e){switch($(this).attr("name")){case"bulk_action":if("delete"!==$('select[name="action"]').val()&&"delete"!==$('select[name="action2"]').val())return;result=confirm("Are you sure you want to delete these Keywords?");break;default:result=confirm("Are you sure you want to delete this Keyword?");break}if(!result)return a.preventDefault(),!1;e=!0}})),$('select[name="source"]').length>0&&(page_generator_pro_conditional_fields_initialize(),$('select[name="source"]').trigger("change")),$("textarea.wpzinc-codemirror").length>0&&$("textarea.wpzinc-codemirror").each((function(){wp.codeEditor.initialize($(this),page_generator_pro_keywords)})),$("table.page-generator-pro-keywords-table").length)var a=$("table.page-generator-pro-keywords-table").DataTable({ajax:{url:ajaxurl,type:"POST",data:{action:"page_generator_pro_keywords_get_terms",nonce:$('input[name="page-generator-pro_nonce"]').val(),id:$("table.page-generator-pro-keywords-table").data("keyword-id")}},processing:!0,serverSide:!0,responsive:!1,autoWidth:!0,scrollX:!0,scrollY:500});$("button.page-generator-pro-refresh-terms").on("click",(function(e){e.preventDefault();var r=$(this);$("span.spinner",$(r).parent()).addClass("is-active"),$(r).prop("disabled","disabled"),$.post(ajaxurl,{action:"page_generator_pro_keywords_refresh_terms",nonce:$(r).data("nonce"),keyword:$(r).data("keyword")},(function(e){$("span.spinner",$(r).parent()).removeClass("is-active"),$(r).prop("disabled",!1),e.success?a.ajax.reload():alert(e.data)}))}))}));