"use strict";jQuery(document).ready((function($){if($("#seobooster_tabulator.seoboosterlogpage").length)if("undefined"!=typeof Tabulator){var t=new Tabulator("#seobooster_tabulator.seoboosterlogpage",{ajaxURL:sblogdata.ajaxurl,ajaxParams:function(){return{_nonce:sblogdata.security,action:"sb_log_table",search:$("#search-input").val(),page_size:t.getPageSize()}},layout:"fitDataStretch",pagination:!0,paginationMode:"remote",paginationSize:50,paginationInitialPage:1,paginationSizeSelector:[50,100,200,500],movableColumns:!0,columns:[{title:sblogdata.strings.timestamp,field:"logtime",sorter:"date",headerSort:!0},{title:sblogdata.strings.priority,field:"prio_text",headerSort:!1},{title:sblogdata.strings.logEntry,field:"log",headerSort:!1,formatter:function(t){return t.getValue().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;").replace(/&lt;code&gt;(.*?)&lt;\/code&gt;/g,"<code>$1</code>").replace(/&lt;span class=&quot;([a-zA-Z0-9-_\s]+)&quot;&gt;(.*?)&lt;\/span&gt;/g,'<span class="$1">$2</span>').replace(/&lt;a href=&quot;([^"]+)&quot; target=&quot;_blank&quot;&gt;(.*?)&lt;\/a&gt;/g,'<a href="$1" target="_blank">$2</a>').replace(/&lt;strong&gt;(.*?)&lt;\/strong&gt;/g,"<strong>$1</strong>").replace(/&lt;em&gt;(.*?)&lt;\/em&gt;/g,"<em>$1</em>")}}],rowFormatter:function(t){var a="prio-"+t.getData().prio;t.getElement().classList.add(a)},ajaxSorting:!0,ajaxFiltering:!0,ajaxResponse:function(t,a,e){return{last_page:e.last_page,data:e.data,total:e.total}}});t.on("tableBuilt",(function(){$(".tabulator-paginator button").addClass("button button-small")})),$("#refresh-button").addClass("button button-small").on("click",(function(){t.setData()})),$("#search-submit").on("click",(function(){t.setData()}))}else console.error(sblogdata.strings.tabulatorNotLoaded)}));