diff --git a/theme.info b/theme.info index 4481a1d32..96928f271 100644 --- a/theme.info +++ b/theme.info @@ -1,7 +1,7 @@ desc=Authentic Theme longdesc=Webmin/Usermin/Virtualmin/Cloudmin theme based on Bootstrap and Font Awesome (https://github.com/authentic-theme/authentic-theme) version=19.35-RC4 -mversion=18 +mversion=19 depends=1.900 1.750 webmin=1 usermin=1 diff --git a/unauthenticated/js/bundle.min.js b/unauthenticated/js/bundle.min.js index 501f4c6f2..7348d1895 100644 --- a/unauthenticated/js/bundle.min.js +++ b/unauthenticated/js/bundle.min.js @@ -233,11 +233,11 @@ function(t,e){"object"==typeof module&&module.exports?module.exports=e():"functi * Licensed under MIT (https://github.com/authentic-theme/authentic-theme/blob/master/LICENSE) */ Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(e,t){if(null==this)throw new TypeError('"this" is null or not defined');var a=Object(this),n=a.length>>>0;if(0===n)return!1;for(var r=0|t,i=Math.max(r>=0?r:n-Math.abs(r),0);i>>0,r=0;r-1&&navigator.userAgent&&!navigator.userAgent.match("CriOS");return e?a:n},firefox:function(){return/firefox/i.test(navigator.userAgent)}},storage:{size:function(e){var t=String(),a=e?"MB":"KB";for(var n in window.localStorage)window.localStorage.hasOwnProperty(n)&&(t+=window.localStorage[n]);return t?((3+16*t.length/8192)/(e?1024:1)).toFixed(2)+" "+a:"Empty (0 "+a+")"}}},Convert={arrFlip:function(e){var t,a={};for(t in e)e.hasOwnProperty(t)&&(a[e[t]]=t);return a},uriDecodeComponent:function(e,t){var a,n,r,i=String(),o=0;if(void 0===t&&(t=0),a=e?e.split(/(%(?:d0|d1)%.{2})/):[],$.isEmptyObject(a))return e;for(n=a.length;o":">",'"':""","'":"'","=":"="};return String(e).replace(/[&<>"'=]/g,function(e){return t[e]})},htmlUnEscape:function(e){var t=[["amp","&"],["apos","'"],["#x27","'"],["#x2F","/"],["#39","'"],["#47","/"],["#61","="],["lt","<"],["gt",">"],["nbsp"," "],["quot",'"']];if(e)for(var a=0,n=t.length;a").html(e).text()},pathnamePopLast:function(e){var t,a=~e.indexOf("%2F")?"%2F":"/",n=e.split(a);return n.pop(),t=n.join(a),t?t:"/"},strUpFirst:function(e){return e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()},strUpFirstEach:function(e){return e.replace(/\w\S*/g,function(e){return e.charAt(0).toUpperCase()+e.substr(1).toLowerCase()})},strUpInitial:function(e){return e.length?this.strUpFirst(e.toLowerCase()):e},json_to_query:function(e){return""+Object.entries(e).map(function(e){var t=e[0],a=e[1];return t+"="+encodeURIComponent(a)}).join("&")},nice_number:function(e){return e.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1,")}},core={get_global_vars:function(e,t){for(var a=t?{}:[],n=window,r=0;r-1},curModuleFileQuery:function(e,t,a){return $('body[class*="'+e+'"]').length&&v___location_file==t&&v___location_query&&v___location_query.indexOf(a)!==-1},curModuleFile:function(e,t){return $('body[class*="'+e+'"]').length&&v___location_file==t},curModule:function(e,t){return t=t?String():"*",$("body[class"+t+'="'+e+'"]').length},moduleFile:function(e,t,a){if(e.includes("/")&&e.includes(".cgi")){var n,r,i,o=e.split("/");if(o.filter(function(e,t){e.includes(".cgi")&&(n=t)}),r=o[n-1],i=o[n],r&&r.includes(t)&&i&&i.includes(a))return 1}return 0},updateModuleData:function(e,t,a){$.ajax({type:"POST",url:v___location_prefix+e,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var n=$(e).find("form.ui_form");$.each(a,function(e,t){n.find('[name="'+e+'"]').val(t)}),setTimeout(function(){$.ajax({type:"POST",url:v___location_prefix+t,data:$(n).serialize(),dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0)},error:function(){}})},100)},error:function(){}})},getModuleData:function(e){return $.ajax({type:"POST",url:v___location_prefix+e,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0)},error:function(){}})},setModuleData:function(e,t){this.getModuleData(e).then(function(e){return $(e).find("form.ui_form").serializeArray()}).done(function(e){var a={};$.each($(e),function(){a[this.name]=this.value}).promise().done(function(){$.each(t,function(e,t){var n=$('[name="'+t+'"]');n.val(a[t]),n.is("select")&&n.find("[data-clear]").remove()})})})}},HTML={bottom_progress:function(e,t,a){return'
'+(a?'
':"")+'
'+(a?"":"1%")+(a?'':"")+'
'},label:{temperature:function(e,t){var a="bg-semi-transparent";return t?e<=30?a:e>30&&e<=60?a:e>60&&e<=80?"bg-warning":e>80?"bg-danger":"":e<=86?a:e>86&&e<=140?a:e>140&&e<=176?"bg-warning":e>176?"bg-danger":""},rpm:function(e){return e<=2*rpmFactor?bg_semi_tr:e>2*rpmFactor&&e<=3*rpmFactor?bg_semi_tr:e>3*rpmFactor&&e<=4*rpmFactor?bg_warn:e>4*rpmFactor?bg_danger:""}},template:{accordion:function(e,t,a,n){for(var r='
',i=0;i
'+a[i]+"
"}return r+=""},page_content_preloader:function(e,t){return'
 '+e+'
'},reauthenticate:function(e){var t=Test.strContains(get_server_data("webprefix"),"servers/link.cgi")?1:0;return'

'+theme_language("theme_xhred_session_expired")+"

"+theme_language("theme_xhred_session_expired_details")+'
"}}},load={loaded:[],bundle:function($script,$css,callBack,callBackCalledNoEval){var head=$("head"),initial_name=$script,body=$("body"),callBack="object"==typeof callBack&&callBack,css=($css?1===$css?$script:$css:0)+"."+v___source_type+".css",js=$script+"."+v___source_type+".js";Test.strContains(initial_name,v___server_extensions_path)||Test.strContains(initial_name,v___server_js_path)||(css=v___server_css_path+"/"+css,js=v___server_js_path+"/"+js),load.loaded.includes(initial_name)||(o___gotten_scripts.push(js),this.loaded.push(initial_name),$css&&head.append(''),$.getScript(js+"?"+v___theme_version_plain,function(data,textStatus,jqxhr){callBack&&!callBackCalledNoEval?$.each(callBack,function(i2,v2){eval(v2)}):callBack&&callBackCalledNoEval&&2!==callBackCalledNoEval?$.each(callBack,function(e,t){t.call()}):callBack&&callBackCalledNoEval&&2===callBackCalledNoEval&&$.each(callBack,function(e,t){window[e].apply(null,t)})}).fail(function(e){"canceled"!==e.statusText&&connection_error(e,1)}))}},page={handle:{content:{offset:function(e){var t=core.curModuleFileQuery("syslog","save_log.cgi","view=")||core.curModuleFile("virtual-server","edit_html.cgi")||core.curModuleFile("mysql","view_table.cgi")||core.curModuleFile("postgresql","view_table.cgi")||core.curModuleFile("mailbox","")||core.curModuleFile("mailbox","index.cgi")||core.curModule(v___module_file_manager)||v___page_hasEditor||!settings_enable_container_offset?0:1;if(!e)return t;var a=$(".container-fluid");page.handle.content.offset()?a.addClass("col-lg-10 col-lg-offset-1").removeClass("margined-top-15"):a.removeClass("col-lg-10 col-lg-offset-1").addClass("margined-top-15")},preloader_dismiss:function(){$(".container-fluid-loading").length&&page.handle.content.preloader()},preloader:function(e,t){var a=this,n=$("#content"),r=$(".container-fluid"),i=$(".container-fluid-loading"),o=t?t:$("span[data-main_title]").text(),s=e===-2?"container-fluid-loading-persistent":0,l=HTML.template.page_content_preloader(o,s);return e!==-2&&i.length&&i.hasClass("container-fluid-loading-persistent")?void i.removeClass("container-fluid-loading-persistent"):e===-1?n.hasClass("progressing"):(i.length?(i.remove(),r.removeClass("invisible"),n.removeClass("progressing"),setTimeout(function(){progress.progress()&&progress.end()},10)):(n.addClass("progressing").prepend(l),r.addClass("invisible")),void(e&&e!==-2&&setTimeout(function(){a.preloader()},e)))}}},render:{content:{filter:{init:function(e,t){var a=this,n="container-fluid .nav.nav-tabs",r="dataTables_filter",i=$(".__page ."+r),o=$(".__page .panel-filter"),s=".panel-filter .panel.panel-default",l="filter-value",c="btn-filter-top-right",d="btn-accordion-filter",f=$("body");(i.length||o.length)&&setTimeout(function(){function t(t){var a=t.val(),o=$(".__page .panel-filter:visible");if(e)if(a){$.support.transition&&($.support.transition=!1),i.find(".fa-toggle-switch-off:not(.fa-toggle-switch)").trigger("click"),o.find(".panel tr:not([data-empty-row]):not(.hidden-skip)").addClass("hidden-forged");var f=o.find('.panel tbody tr:containsi("'+a+'")');f.removeClass("hidden-forged"),$.each($(s=" .hidden-dependent-skip"),function(e){$(this).hasClass("hidden-forged")?$(this).nextAll(".hidden-skip").addClass("hidden-forged"):$(this).nextAll(".hidden-skip").removeClass("hidden-forged")});var u=$(".__page .panel-filter:visible");$.each(u.find(".panel"),function(){var e=$(this).find("tr").first().find("td").length;rows=$(this).find("tbody").find("tr:not([data-empty-row])"),hidden_rows=$(this).find("tbody tr:not([data-empty-row]):hidden");var t=$(this).find("tbody tr[data-empty-row]");rows.length===hidden_rows.length?t.length?$(this).find("tbody").find("var[data-query-str]").text(a):$(this).find("tbody").append(''+theme_language("theme_xhred_filter_content_no_matches_query").replace("%str",""+a+"")+""):t.remove()})}else i.find(".fa-toggle-switch").trigger("click"),o.find(".panel tr").removeClass("hidden-forged"),o.find(".panel tr[data-empty-row]").remove(),!$.support.transition&&($.support.transition={end:"webkitTransitionEnd"});else{var p="."+r+" input";$("."+n).length?($(".nav-tabs li.active").data(l,a),$(".active "+p).val(a).trigger("keyup")):$(p).val(a).trigger("keyup")}var g="."+c+" span, ."+d+" span",_="."+c+" i, ."+d+" i";$.trim(a).length>0?($(g).removeClass("text-lighter"),$(_).addClass("text-danger")):($(g).addClass("text-lighter"),$(_).removeClass("text-danger"))}$("."+c).length||$("."+d).length||($("#headln2r .btn-group a").addClass("pull-left").attr("style",""),$("#headln2r .btn-group").prepend(''+(e?'':""))),$(".btn-filter-gl").data("title",theme_language("theme_xhred_datatable_filter")).attr("aria-label",theme_language("theme_xhred_datatable_filter")),$(".btn-toggle-accordions").data("title",theme_language("theme_xhred_toggle_accordions")).attr("aria-label",theme_language("theme_xhred_toggle_accordions")),$(".btn-group").tooltip({selector:'a[data-toggle="tooltip"][data-skip]',container:"body",trigger:"hover",delay:{show:600,hide:30}}),a.clear(),$("."+n).length&&(e&&f.on("hide.bs.tab",'a[data-toggle="tab"]',function(e){a.clear()}),f.on("shown.bs.tab",'a[data-toggle="tab"]',function(e){var t=$(e.target).parent(".active");t.data(l)?$(".dataTable-mirror").val(t.data(l)).trigger("keyup"):$(".dataTable-mirror").val("").trigger("keyup"),a.visibility(c,d,"btn-toggle-accordions",n)})),f.undelegate(s,"shown.bs.collapse.config hidden.bs.collapse.config"),f.on("shown.bs.collapse.config hidden.bs.collapse.config",s,function(e){$(".container-fluid .collapsing").length||setTimeout(function(){var e=$(".container-fluid").find(".btn-toggle-accordions").find("i");o.find(".panel-collapse").length===o.find(".panel-collapse.in").length?e.addClass("fa-toggle-switch text-light"):e.removeClass("fa-toggle-switch text-light")},0)});var i=$(".btn-toggle-accordions");if(e)$(o).find('a[data-toggle="collapse"]').on("click",function(e){$.trim($(".dataTable-mirror").val()).length&&page.render.content.filter.clear(),e.originalEvent&&$(".btn-toggle-accordions").find("i").removeClass("fa-toggle-switch text-light")});else{$("."+r).hide()}$(".filter_mirror_clear").mousedown(function(e){$(e.target).is(".filter_mirror_clear")&&a.clear()}),$("."+c+", ."+d).click(function(e){!$(e.target).is("input")&&$(this).find("label").slideToggle(300,function(){$(this).find("input").focus()})}),i.click(function(e){e.stopImmediatePropagation();var t=$(this).find(".fa"),n=$(this).find(".fa-toggle-switch").length?1:0,r=$(".__page .panel-filter:visible");0===n?(r.find(".panel-collapse.in").length,r.find(".panel-collapse").length,r.find(".panel-collapse:not(.in):not(.collapsing)").filter(function(){$(this).removeData("bs.collapse").collapse({parent:!0,toggle:!1}).collapse("show").removeData("bs.collapse")})):r.find(".panel-collapse.in:not(.collapsing)").filter(function(){"true"!==$(this).attr("aria-static")&&$(this).collapse("hide")}),t.toggleClass("fa-toggle-switch text-light"),void 0!==e.originalEvent&&$("."+d+" input").val().length&&a.clear()});var u;$(".dataTable-mirror").keydown(function(e){var t=void 0!==e.originalEvent?200:0;76==e.keyCode&&e.ctrlKey?(e.preventDefault(),e.stopPropagation(),t?setTimeout(function(){a.clear()},t):a.clear()):t&&clearTimeout(u)}).on("keyup paste",function(e){var a=$(this),n=void 0!==e.originalEvent?200:0;$(".btn-filter-gl").tooltip("hide"),n?(clearTimeout(u),u=setTimeout(function(){t(a)},n)):t(a)}),$("."+c+" input, ."+d+" input").blur(function(e){$(this).parent("label").slideToggle(0)}),a.visibility(c,d,"btn-toggle-accordions",n)},0)},visibility:function(e,t,a,n){var r=$("."+e+", ."+t+", ."+a);$("."+n).length&&($(".active .dataTables_filter").length||$(".active #conf-_-gr").length)||!$("."+n).length&&($(".dataTables_filter").length||$("#conf-_-gr").length)?r.show():r.hide()},clear:function(){var e=$(".btn-filter-top-right .dataTable-mirror, .btn-accordion-filter .dataTable-mirror"),t=$(".btn-filter-top-right input, .btn-accordion-filter input");e.val("").trigger("keyup"),t.is(":visible")&&t.trigger("blur"),$(".panel-filter").find("tr[data-empty-row]").remove(),!$.support.transition&&($.support.transition={end:"webkitTransitionEnd"})}}},module_config:function(e){var t=v___page_container.find(".table-title:visible"),a=t.parents(".table:visible"),n=a.parent("div.table-responsive:visible"),r=a.find("tbody > tr > td > table:visible"),i=0,o=1;$.each(r.find("tr"),function(e,t){var a=$(this);a.find(".col_header").length?(i+=1,a.attr("tj",i+":0")):a.attr("tj",i+":1")}).promise().done(function(){var t=$('tr[tj$=":0"]').map(function(){return $.trim($(this).text())});0===t.length&&(t.push(theme_language("theme_xhred_config_configurable_options")),o=0);for(var r=[],i=1;i tr[tj="0:1"]'),l='';l+=s.map(function(){return this.outerHTML}).get().join("\n"),l+="
",r[i-1]=l}var c="conf-_-gr";n.replaceWith(HTML.template.accordion(c,t,r,o?e:[2])),page.render.content.filter.init(1),$(".container-fluid > .panel > .panel-body").on("hide.bs.collapse show.bs.collapse","#"+c,function(){$(".module-help .close-popover-trigger").trigger("click")})})}}},pjax={clear:{modules:function(e){"csf"===v___module&&"function"==typeof __c_____undel&&__c_____undel(e.url),v___module===v___module_file_manager&&"function"==typeof __f_____undel&&"object"==typeof jsPanel&&"string"==typeof $v__fm__container_fluid&&(Test.strContains(e.url,v___module_file_manager+"/config.cgi")||Test.strContains(e.url,v___module_file_manager+"/index.cgi")||Test.strContains(e.url,"save_config.cgi")||__f_____undel()),"mysql"!==v___module&&"postgresql"!==v___module||"function"!=typeof __sql_____undel||__sql_____undel(),"syslog"===v___module&&"number"==typeof refreshTimer&&clearInterval(refreshTimer)}}},progress_percent={body:"body",control:function(e,t,a,n){var r=this;$(r.body).find(".bottom_progresses").length||$(r.body).append('
');var i=$(r.body).find(".bottom_progresses");if(!i.find('div[data-progress-id="'+e+'"]').length){if(i.append(HTML.bottom_progress(e,t,n)),n||i.find(".bottom_progress_horizontal").length){i=$(r.body).find(".bottom_progresses");var o=i.find('.bottom_progress:not(".bottom_progress_horizontal")').addClass("no-animation").detach();i.prepend(o)}i.find('div[data-progress-id="'+e+'"]').find(".bottom_progress_cancel").one("click",function(){var e=$(this).parent(),t=e.data("progress-id");e.find(".bottom_progress_level").removeClass("success").addClass("danger"),$(this).remove(),setTimeout(function(){e.remove(),0===i.find("div[data-progress-id]").length&&i.remove()},1e3),window["progress_id_ref_"+t].abort(),n&&window["progress_id_ref_"+t+"_tracker"].abort()})}var s=i.find('div[data-progress-id="'+e+'"]');if(s.find(".bottom_progress_level").css("height",a+"%"),n){var l=s.find(".bottom_progress_overlay"),c=".bottom_progress_";s.find(c+"filename").html(''+Convert.htmlEscape(Convert.textTruncate(Convert.htmlDecode(n[0]),24))).attr("title",Convert.htmlEscape(n[0])),l.find(c+"data").text($(Convert.htmlDecode(n[1])).text()),l.find(c+"percent").text(n[2]+"%")}else s.find(".bottom_progress_overlay").text(a+"%");100==a&&(s.find(".bottom_progress_cancel").remove(),setTimeout(function(){s.remove(),0===i.find("div[data-progress-id]").length&&i.remove()},1e3))}},progress={target:"body",element:"top-aprogress",progress:function(){return!settings_hide_top_loader},start:function(){var e=this;setTimeout(function(){e.progress()&&!$(e.target).find("."+e.element).length&&vars.allow_ui_features&&$(e.target).append('
')},100)},end:function(){0===v___theme_progress?$(this.target).find("."+this.element).remove():setTimeout(function(){v___theme_progress=0},0)}},session={reauthenticate:{start:function(){var e=this,t=e.target;!$("."+t).length&&$.ajax({type:"GET",url:v___location_prefix+"/index.cgi",data:!1,dataType:"text",success:function(a){var n=Test.strContains(a,v___page_signin_form+" pam_");if(!Test.strContains(a,v___page_signin_banner)){var r=$(a).find('input[name="twofactor"]').length,i=e.lock_targets,o=e.lock_type,s=$("body").find(".-shell-port-"),l='',c=$(a).find("._logo_welcome > img").attr("src");$(i).addClass(o),$("body").append(HTML.template.reauthenticate(t)),plugins.navigation.load.stop(),plugins.navigation.detect(),plugins.navigation.switch.reset(),despinnerfy_buttons(),plugins.shell.unlock(),plugins.shell.close(s),r||$("."+t).find("[data-container-twofactor]").remove(),c&&$("."+t).append(""),$("."+t).find("form").on("submit",function(e){function r(e,a,n,r){if(a){var i="theme_xhred_session_failed"===theme_language(a,1)?theme_language("theme_xhred_session_failed_password"):a;i.endsWith(".")||(i+="."),i=i.replace(/\n/gm,""),u.text(i).addClass("text-danger").removeClass("loading-dots"),c.removeClass("disabled btn-transparent").addClass("btn-success");var o=$(r).find(".alert[data-twofactor]"),s=o.length?$("."+t).find('input[name="twofactor"]'):$("."+t).find('input:not([name="user"]):not([name="twofactor"])');s.addClass("faa-horizontal animated"),s[0].focus(),setTimeout(function(){s.removeClass("faa-horizontal animated")},1e3)}else e&&!n&&(u.text(theme_language("theme_xhred_signing_success")).removeClass("text-danger").removeClass("loading-dots").addClass("text-success"),d.removeClass("fa-lock").addClass("fa-unlock fa-rotate-180 fa-flip-horizontal"),f.text(theme_language("theme_xhred_session_unlocked")),v___available_session=1,setTimeout(function(){session.reauthenticate.end()},1800))}if(e.preventDefault(),e.stopImmediatePropagation(),n){$("."+t).find('form input[name="user"]').attr("name","answer").val(get_server_data("user"))}var i=$(a).find("form").append(l),o=i.attr("action"),s=$("."+t).find("form").serialize(),c=$("."+t).find("[data-submit]"),d=$("."+t+"-header-icon i"),f=$("."+t+"-header-title h3"),u=$("."+t+"-header-title small");c.hasClass("disabled")||(u.text(theme_language("theme_xhred_signing_in")+"").removeClass("text-danger").addClass("loading-dots"),c.addClass("disabled btn-transparent").removeClass("btn-success"),$.ajax({type:"GET",url:o,data:s,dataType:"text",success:function(e){var a=$(e).find(".switch-toggle").text().length,i=$(e).find(".alert span").text(),s=i.length;if(n){var c=$(e).find("form").append(l),d=(c.find('input[name="answer"]').val($("."+t).find('input[type="password"]').val()),c.serialize());$.ajax({type:"GET",url:o,data:d,dataType:"text",success:function(e){a=$(e).find(".switch-toggle").text().length,i=$(e).find(".alert span").text(),s=i.length,r(a,i,s,e)}})}else r(a,i,s,e)}}))})}}})},end:function(){v___available_session=1,$("."+this.target).remove(),$(this.lock_targets).removeClass(this.lock_type)},target:"session-reauthenticate",lock_targets:"aside, aside .navigation, .form-control.sidebar-search, .container-fluid, .right-side-tabs, .right-side-tabs-toggler",lock_type:"pointer-events-none bg-filter-blur2-grayscale75-opacity75 disabled"}},Test={true:function(e){return!/^(false|0)$/i.test(e)&&!!e},false:function(e){return/^(false|0)$/i.test(e)||!e},numeric:function(e){return Number(parseFloat(e))==e},string:function(e){return"string"==typeof e||e instanceof String?1:0},strContains:function(e,t){return"string"==typeof e&&!!~e.indexOf(t)},str_contains_multi:function(e,t){for(var a in t){var n=t[a];if(e.indexOf(n)>-1)return!0}return!1},arrContains:function(e,t,a){return void 0===a&&(a=0),e=$.inArray(t,e),a?e:-1=n},occurrences:function(e,t,a){if(e+="",t+="",t.length<=0)return e.length+1;for(var n=0,r=0,i=a?1:t.length;;){if(!((r=e.indexOf(t,r))>=0))break;++n,r+=i}return n},editing:function(){return $("input:focus").length||$("textarea:focus").length||$('[contenteditable="true"]:focus').length}},theme={download:function(e,t,a,n){if(n=void 0===n||1==n||n===!0?String():'target="_blank"',e&&t){t="string"==typeof t?t:$.param(t);var r="";$.each(t.split("&"),function(){var e=this.split("=");r+=''}),$("
'+r+"
").appendTo("body").submit().remove()}},veiled:function(e){var t=$(".container-fluid, .jsPanel").add($("aside")).add($("#right-side-tabs")).add($(".right-side-tabs-toggler")),a="pointer-events-none bg-filter-blur-grayscale-opacity50";if(e===-1)return t.hasClass(a);e?t.addClass(a):t.removeClass(a)},update:function(e,t){var a=1===e?"-release":"-beta";theme.veiled(1),set_onbeforeunload_status(1,0),plugins.messenger.post(''+theme_language("theme_xhred_git_patch_initiated")+" "+theme_language("theme_xhred_global_please_wait")+'   ',1800,"info","themeUpgrade",0),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi?xhr-update=1&xhr-update-type="+a+"&xhr-update-force="+t,data:!1,dataType:"json",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);e[0]&&e[0].success?(plugins.messenger.post(''+e[0].success,4,"success","themeUpgrade"),plugins.slider.notifications.dismiss("authentic_remote_version"),set_server_theme_temp_data("goto",v___location_prefix+"/sysinfo.cgi"),setTimeout(function(){theme_reload()},2e3)):e[0]&&e[0].no_connection?(plugins.messenger.post(''+e[0].no_connection,40,"warning","themeUpgrade"),theme.veiled(0)):e[0]&&e[0].no_git?(plugins.messenger.post(''+e[0].no_git,20,"warning","themeUpgrade"),theme.veiled(0)):e[0]&&e[0].incompatible?(plugins.messenger.post(''+e[0].incompatible,120,"error","themeUpgrade"),theme.veiled(0)):(plugins.messenger.post(''+theme_language("theme_xhred_git_patch_update"),20,"error","themeUpgrade"),theme.veiled(0))},error:function(e){plugins.messenger.post(''+theme_language("theme_xhred_git_patch_update"),20,"error","themeUpgrade"),theme.veiled(0)},complete:function(e){set_onbeforeunload_status(0,0)}})},version:function(){return v___theme_version},visibility:function(e){0===v___theme_visibility_check&&(v___theme_visibility_check=1,0===e||"object"==typeof stats&&stats.general.enable(),setTimeout(function(){v___theme_visibility_check=0,vars.events.keypressed.shift=!1,vars.events.keypressed.alt=!1},0))}},quirks={active_element:function(){ -return document.activeElement&&$(document.activeElement).is("body")?v___page_activeElement:document.activeElement},local_storage:{safari:function(){if("object"==typeof localStorage)try{localStorage.setItem("d41d8cd98f00",1),localStorage.removeItem("d41d8cd98f00")}catch(e){Storage.prototype._setItem=Storage.prototype.setItem,Storage.prototype.setItem=function(){},vars.local_storage=0}}},render:{apple:function(){browser.detect.safari(1)&&$("html").css("overflow","auto");var e=$(".__page");browser.detect.safari()&&e.addClass("browser_safari"),navigator.userAgent.match(/(iPod|iPhone|iPad)/)&&e.attr("style","-webkit-overflow-scrolling: touch !important; overflow-y: scroll !important;")}}},regex={matches:function(e,t,a,n){a||(a=1);for(var r,i=[];r=t.exec(e);)i.push(r[a]);return n&&(i=i.slice(-1)[0]),i}},XHR={headers:function(e){return[e.getAllResponseHeaders(),e.getResponseHeader("content-type"),e.getResponseHeader("content-disposition"),e.getResponseHeader("content-length")]}};const plugins={};plugins.shell=function(){var e=function(){return $("body").find(".-shell-port-").hasClass("opened")},t=function(){return $t_uri_cloudmin&&$('a[target="page"][href*="/server-manager/save_serv.cgi"][href*="shell=1"]').length},a=function(){return t()?v___location_prefix+"/server-manager/shell.cgi":core.moduleAvailable("shell")?v___location_prefix+"/shell/index.cgi":0},n=function(){h()?0!=settings_show_terminal_link&&$(".user-link.ported-console").removeClass("hidden"):$(".user-link.ported-console").addClass("hidden")},s=function(){vars.shell.processing=0,$('.-shell-port- input[data-command="true"]').removeAttr("readonly")},r=function(e,t,a,i){return''},o=function(e){var a=t(),i=$('select[name="sid"]').val();e||(e=""),i||(i=0),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi/?xhr-shell-insert=1&xhr-shell-inserted="+e+"&xhr-shell-cms="+a+"&xhr-shell-cmsid="+i,dataType:"text",complete:function(e){if(e=e.responseText,Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=JSON.parse(e);localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(t))}})},l=function(e,t,a){$(e).next("pre").remove(),g(),_(t),a.scrollTop(a[0].scrollHeight),setTimeout(function(){vars.shell.processing=0,vars.shell.history=0,t.removeAttr("readonly").focus()},100)},_=function(e){e.val(""),e.focus()},d=function(e){var t=$("body").find(".-shell-port-"),a=a=void 0!==e&&(e.startsWith("!")?e.substr(1):e),i=t.find("input"),n=(t.find(".-shell-port-pwd").attr("data-pwd"),t.find("[data-shell-host]")),s=n.attr("data-shell-host");if($t_uri_cloudmin){var r=$('aside [name="sid"] option:selected');current_host_name=r.attr("title")||r.text(),n.text(current_host_name)}else n.text(s);if(o(!1),a){i.val(a);var l=$.Event("keydown");l.which=13,i.trigger(l)}t.css("bottom","0vh").addClass("opened"),u(),g(),setTimeout(function(){a||(focus(),i.focus())},20)},c=function(){$("body").find(".-shell-port-").css("bottom","100vh").removeClass("opened"),v___module==v___module_file_manager&&"function"==typeof __f__state__changed&&__f__state__changed(),$(".command-shell-editor-spinner").remove(),u(!0)},p=function(e){var t=$(".-shell-port-container .-shell-port-cmd");e?t.addClass("invisible"):t.removeClass("invisible")},g=function(){if(1==core.moduleAvailable("shell")){var e=parseInt($("body").find(".-shell-port-cmd").width()),t=parseInt($("body").find(".-shell-port-prompt").width());$("body").find('.-shell-port- input[data-command="true"]').css("width",e-t-50+"px")}},h=function(){var e=t();return 1==core.moduleAvailable("shell")||e?1:0},f=function(e){var t=$("body").find(".-shell-port-"),a=t.find(".-shell-port-pwd"),i=a.attr("data-home");if("string"==typeof e){e=Convert.uriDecodeComponent(e);var n=e&&e.endsWith("/")?e.slice(0,-1):e,s=n.split("/").pop();s||(s="/",e="/"),2==get_access_level()&&(e=get_server_data("user-home")+e),e===i&&(s="~"),a.attr("data-pwd",e).attr("title",e).text(s)}},u=function(n){var s=$(document.body).find(".-shell-port-"),f=s.find('input[data-command="true"]'),u=s.find("div[data-output]"),m=s.find(".-shell-port-container"),v=s.data("autocomplete"),b=$(window),x=".plugin-shell";if(n)return b.off("keydown"+x),b.off("keyup"+x),void m.off("click"+x);b.on("keydown"+x,function(t){var a=this,i=e(),n=$(".modal-shell-config:visible").length,r=String.fromCharCode(t.which).toLowerCase();if(t[settings_hotkey_toggle_modifier]&&r==settings_hotkey_shell&&theme_shortcuts_modifier_unique(t))return t.preventDefault(),void(i&&c());if((t.altKey||t.ctrlKey)&&"l"==String.fromCharCode(t.which).toLowerCase()&&t.preventDefault(),void 0===a.shell_request_interrupted&&(a.shell_request_interrupted=0),void 0===this.last_pressed_times?this.last_pressed_times=0:this.last_pressed_times+=1,setTimeout(function(){a.last_pressed_times=0},vars.event.double_click_delay),"c"===r&&a.last_pressed_times>1&&t.ctrlKey&&!t.shiftKey&&!t.altKey&&!t.metaKey)return a.shell_request_interrupted=1,"object"==typeof a.shell_request&&"pending"===a.shell_request.state()&&a.shell_request.abort(),void setTimeout(function(){a.shell_request_interrupted=0},1e3);if(this.searching||"r"===r&&t.ctrlKey&&!t.shiftKey&&!t.altKey&&!t.metaKey){if(t.preventDefault(),"object"==typeof a.shell_request&&"pending"===a.shell_request.state())return;var o=$(".-shell-port-type"),l=$('.-shell-port- input[data-command="true"]');if(m.scrollTop(m[0].scrollHeight),this.searching=1,run_search=function(e){var t=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),a=t.filter(function(t){return t.includes(e)});return $.unique(a).reverse()},update_search=function(e,i){if(this.used_index&&!i||(this.used_index=0),t.ctrlKey){if("c"===r)return void cancel_search(1);if("r"!==r)return}JSON.stringify(e)!=JSON.stringify(this.results)||i?this.results=e:t.shiftKey?--this.used_index:++this.used_index,e.length<=this.used_index&&(this.used_index=0),this.used_index<0&&(this.used_index=e.length-this.used_index-2);var n=this.searching_shell_str_replaced.find("span[data-searching]"),s=n.text(),o=localStorage.getItem(v___server_hostname+"-shell_command_last");if(!a.pre_searched&&o&&("undefined"===o&&(o=String()),a.pre_searched=o),!s&&a.pre_searched){n.text(a.pre_searched);var _=run_search(a.pre_searched);return void update_search(_,0)}if(!s||!e.length)return void failed_search();success_search(),e&&l.val(Convert.htmlUnEscape(e[this.used_index])),g()},failed_search=function(){var e=a.searching_shell_str_replaced.html();e.includes("failed reverse")||a.searching_shell_str_replaced.html(e.replace("reverse-i-search","failed reverse-i-search")),g(),new Audio("data:audio/ogg; codecs=opus;base64,T2dnUwACAAAAAAAAAAArS957AAAAAAff6O0BHgF2b3JiaXMAAAAAAkSsAAA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MOAAABBgQhkoNGQlAJAKAAAYo5RzzklJpUKIMecglNJShRBjzkEopaWoMcYglJJSa1FjjEEoJaXWomshlJJSSq1F10IoJaXWWotSqlRKaq3FGKVUqZTWWosxSqlzSq3FGGOUUveUWoux1iildDLGGGOtzTnnZIwxxloLAEBocAAAO7BhdYSTorHAQkNWAgB5AAAIQkoxxhhjECGlGGPMMYeQUowxxhhUijHGHGMOQsgYY4wxByFkjDHnnIMQMsYYY85BCJ1zjjHnIITQOceYcxBC55xjzDkIoXOMMeacAACgAgcAgAAbRTYnGAkqNGQlABAOAAAYw5hzjDkGnYQKIecgdA5CKqlUCDkHoXMQSkmpeA46KSGUUkoqxXMQSgmhlJRaKy6GUkoopaTUUpExhFJKKSWl1ooxpoSQUkqptVaMMaGEVFJKKbZijI2lpNRaa60VY2wsJZXWWmutGGOMaym1FmOsxRhjXEuppRhrLMYY43tqLcZYYzHGGJ9baimmXAsAMHlwAIBKsHGGlaSzwtHgQkNWAgC5AQAIQkoxxphjzjnnnHPOSaUYc8455yCEEEIIIZRKMeacc85BByGEEEIoGXPOOQchhBBCCCGEUFLqmHMOQgghhBBCCCGl1DnnIIQQQgghhBBCSqlzzkEIIYQQQgghhJRSCCGEEEIIIYQQQggppZRCCCGEEEIIIZQSUkophRBCCCWEEkoIJaSUUgohhBBCKaWEUkJJKaUUQgillFBKKaGUkFJKKaUQQiillFBKKSWllFJKJZRSSikllFBKSimllEoooZRQSimllJRSSimVUkopJZRSSgkppZRSSqmUUkoppZRSUkoppZRSKaWUUkoppaSUUkoppVJKKaWUEkpJKaWUUkqllFBKKaWUUlJKKaWUSgqllFJKKaUAAKADBwCAACMqLcROM648AkcUMkxAhYasBABSAQAAQiillFJKKTWMUUoppZRSihyklFJKKaWUUkoppZRSSimVUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKAcDdFw6APhM2rI5wUjQWWGjISgAgFQAAMIYx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PX0iAyC13P+/f2etbH3lS5uk/92ltLqWdVkj4/patxUt4/j4XOAfSxhbsS8e/b/jm/zha1MBM8nfAr8vym/++MeV5himtKKsn853EtfX16WAXl97b76q5Mgun32iLMqAaaQvvrIAnpHmkqVjWCz0tg7H1F9e7tzNNBkZ9u37PaZf7OVnnsmKI/AuP7odx7ulcTweA84yr8uzDz3LXO6dyTPnqS2yd0bu34a/ns5WAniVgWZ5zWXcp425/7a1pQIA3pSGHse7tGdraQCoPAFuBOXJC0/88nTUywU=").play()},success_search=function(){var e=a.searching_shell_str_replaced.html();a.searching_shell_str_replaced.html(e.replace("failed reverse-i-search","reverse-i-search")),g()},cancel_search=function(e){o.html(a.searching_shell_str),a.searching_shell_str=0,a.searching_shell_str_replaced=0,a.searching=0,e&&l.val(String()),g()},this.searching_shell_str||(this.searching_shell_str=o.html()),this.searching_shell_str_replaced){var _=this.searching_shell_str_replaced.find("span[data-searching]"),d=_.text();if(t.key&&1===t.key.length){var p=t.ctrlKey||t.altKey||t.metaKey?String():t.key,h=d+p;h&&(a.pre_searched=h,localStorage.setItem(v___server_hostname+"-shell_command_last",h)),_.text(h);var b=run_search(_.text());update_search(b,p)}}else this.searching_shell_str_replaced=o.html("(reverse-i-search)`': "),g();if(8===t.keyCode){var x=this.searching_shell_str_replaced.find("span[data-searching]"),y=x.text(),A=y.slice(0,-1);y&&(a.pre_searched=A,localStorage.setItem(v___server_hostname+"-shell_command_last",h)),x.text(A);var k=run_search(x.text());return void update_search(k,1)}return void(9!==t.keyCode&&13!==t.keyCode&&27!==t.keyCode&&37!==t.keyCode&&38!==t.keyCode&&39!==t.keyCode&&40!==t.keyCode||cancel_search())}if(i&&27===t.keyCode&&!n)return void c();if(i&&38===t.keyCode&&t.preventDefault(),i&&9===t.keyCode&&f.is(":focus")){if(t.preventDefault(),!v)return;var C=f.val().trim().split(/\s+(?!-)/),w=C.length,S=C[0]&&C[0].indexOf("-")===-1?0:1,I=C[1]&&C[1].indexOf(":")===-1?0:1,V=f.val().endsWith(" "),T="service"===$.trim(C[0]),O="systemctl"===$.trim(C[0]),z=$.trim(C[0])&&$.trim(C[0]).startsWith("chown"),Z=1!==C.length||!f.val().length||S||V?T||O?"services":z?"permissions":"lists":"commands";if(!$.trim(f.val()).length)return;var U=f.val(),q=s.find(".-shell-port-pwd"),E=q.attr("data-pwd");if("services"===Z){if("systemctl"===(Z=T?"service":"systemctl")&&3!==C.length)return;U="service"==Z?$.trim(C[1]):$.trim(C[2]),"service"===$.trim(C[0])&&(2===C.length&&V||3===C.length)&&(U=3===C.length?"::::"+$.trim(C[1])+"::::"+$.trim(C[2]):"::::"+$.trim(C[1]))}if(z){if(1===w&&!V)return void f.val($.trim(C[0])+" ");I&&$.trim(C[1])?V||C[2]?(Z="lists",U=E+"/::::"+$.trim(C[2])):(Z="groups",U=$.trim($.trim(C[1]).split(":")[1])):(Z="users",U=$.trim(C[1]))}"lists"!==Z||z||(U=E+"/::::"+$.trim(C[1])+"::::"+$.trim(C[0])+"::::"+$.trim(C[2])),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi?xhr-get_autocompletes=1&xhr-get_autocomplete_type="+Z+"&xhr-get_autocomplete_string="+U,data:!1,dataType:"json",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e.length;if(1===t)if("service"===Z||"systemctl"===Z||"lists"===Z){var a=$.trim(C[0]),i=$.trim(C[0])+" "+$.trim(C[1]);"lists"===Z?("cd"===a&&e[0].endsWith("/")||"cd"!==a)&&("cd"===a||"cat"===a?f.val(a+" "+e[0]):$.trim(C[2])?f.val(i+" "+e[0]):f.val(a+" "+e[0])):"service"!==a||2!==C.length&&3!==C.length?"systemctl"===a&&3===C.length&&f.val(a+" "+$.trim(C[1])+" "+e[0]):2===C.length?f.val(a+" "+e[0]+" "):3===C.length&&f.val($.trim(C[0])+" "+$.trim(C[1])+" "+e[0])}else z?I?V||C[2]?f.val($.trim(C[0])+" "+$.trim(C[1])+" "+e[0]):f.val($.trim(C[0])+" "+$.trim($.trim(C[1]).split(":")[0])+":"+e[0]+" "):f.val($.trim(C[0])+" "+e[0]+":"):f.val(e[0]+" ");else if(t>1){var n=""+$(".-shell-port-type").text()+" "+Convert.htmlEscape(f.val())+"\n";u.find("pre").append(n),u.find("pre").append(Convert.htmlEscape(e.join("\n")+"\n")),m.scrollTop(m[0].scrollHeight)}setTimeout(function(){f.focus().mousedown()},10)},error:function(){}})}}).on("keyup"+x,function(n){var h=this,m=e(),v=$(".modal-shell-config:visible").length;if(m&&!v){var b=0,x=0,y=0,A=$(".form-control.sidebar-search"),k=t(),C=$('select[name="sid"]').val(),w=0,S=a();if(!S)return;if((m||A.is(":focus"))&&8===n.keyCode&&(vars.shell.history=0),m?(b=$.trim(f.val()),x=1,y=1):(b=A.val(),x=void 0!==A.val(),y=0),(y||x&&(!b.trim()||b.trim().startsWith("!")))&&(38==n.keyCode||40==n.keyCode)){n.preventDefault(),n.stopPropagation(),void 0===localStorage.getItem(v___server_hostname+"-shell_commands")&&localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify({}));var I=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),V=I?I.length:0;if(0===vars.shell.history&&!b&&40==n.keyCode)return;if(0===vars.shell.history&&b&&38==n.keyCode)return void(w=1);if(vars.shell.history=40==n.keyCode?++vars.shell.history:--vars.shell.history,vars.shell.history<0&&38===n.keyCode?vars.shell.history=V-1:vars.shell.history>V&&(vars.shell.history=0),I&&I[vars.shell.history%V]){if(!$.isEmptyObject(I)&&(vars.shell.history==V&&38===n.keyCode||vars.shell.history==V&&40===n.keyCode||w))return m?f.val("").focus():A.val("").focus(),void(vars.shell.history=0);if(m){var T=I[vars.shell.history%V].replace(/^!/,"");f.val(Convert.htmlUnEscape(T)).focus()}}return}if(x&&b.trim().startsWith("!")&&27==n.keyCode)return n.preventDefault(),n.stopPropagation(),void A.val("").focus();if(x&&b.trim().startsWith("!")&&13==n.keyCode&&(A.addClass("_shell_form_"),n.preventDefault(),n.stopPropagation(),1==core.moduleAvailable("shell")||k)){f.val(b.trim().substring(1)).focus(),d();var O=$.Event("keyup");O.keyCode=13,f.trigger(O)}var z=s.find(".-shell-port-container"),Z=s.find(".-shell-port-pwd"),U=Z.attr("data-pwd"),q=$.trim(f.val()),E=0,J=n.keyCode?n.keyCode:n.which,K=(n.altKey||n.ctrlKey)&&"l"==String.fromCharCode(n.which).toLowerCase();if(f.is(":focus")||check_selected_text()||(n.ctrlKey||n.altKey||n.shiftKey||n.metaKey||f.val(f.val()+String.fromCharCode(n.which).toLowerCase()),f.focus()),q&&13===J||K){if(z.find("[data-searching]").length)return;if(core.moduleAvailable("shell")||k){if(1===vars.shell.processing)return;vars.shell.processing=1,("clear"===q||"reset"===q||"exit"===q||K)&&(u.find("pre").html(""),_(f),"exit"==q&&c()),"cd ~"===q&&(E=q,q="cd "+Z.attr("data-home"));var j=!1;if("cd /"===q&&(j="/"),"history -c"===q){localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify({}));var M=""+$(".-shell-port-type").text()+" "+q+"\n";u.find("pre").append(M),_(f),z.scrollTop(z[0].scrollHeight);var Q=r(S,k,null,U),R=new FormData($(Q)[0]);return void $.ajax({type:"POST",url:S+"?stripped=1&stripped=2",data:R,dataType:"text",cache:!1,contentType:!1,processData:!1,success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);o(q),vars.shell.processing=0},error:function(e){}})}if($.trim(q).startsWith("history -d")){var D=q.split(" "),W=D[2];return W&&W.length&&Test.numeric(W)&&$.ajax({type:"POST",url:v___location_prefix+"/index.cgi/?xhr-shell-pop="+W+"&xhr-shell-cms="+k+"&xhr-shell-cmsid="+C,data:!1,dataType:"text",cache:!1,contentType:!1,processData:!1,success:function(e){if("1"==e){var t=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands"));localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(t.filter(function(e,t){return t!==parseInt(W)-1})))}o(q)},error:function(e){}}),_(f),void(vars.shell.processing=0)}if(q.startsWith("history")){_(f);var P=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),N=P?P.length:0,G=N?N.toString().length:0,M=""+$(".-shell-port-type").text()+" "+q+"\n";return $.each($(P),function(e,t){var a=e.toString().length,n="";for(i=0;i"+$(".-shell-port-type").text()+" "+f.val();return F.endsWith("/")||F.includes("../")?(Y.append(B+" \nCan not open file editor. Unsupported path expression.\n"),void l(ne,f,z)):(edit_file(H[1],U,[{call:"plugins.shell.toggle"},{call:"plugins.shell.done",params:[ne,f,z]},{call:"plugins.shell.close"}]),Y.append(B+" \nOpening internal file editor. "+theme_spinner_small(void 0,"white command-shell-editor-spinner")+"\n"),p(1),z.scrollTop(z[0].scrollHeight),void o(q))}if("clear"===$.trim(q)||"reset"===$.trim(q)||"exit"===$.trim(q)||K)return vars.shell.processing=0,vars.shell.history=0,g(),f.focus(),void(!K&&o(q));var ee=r(S,k,q,U),te=new FormData($(ee)[0]);f.attr("readonly","true");var ae=0,ie=0,ne=".-shell-port-cmd",se=!1,re=0;h.shell_request=$.ajax({xhr:function(){var e=new window.XMLHttpRequest;return e.addEventListener("progress",function(e){var t=e.target.responseText;if(Test.strContains(t,v___page_signin_form))return v___available_session=0,void h.shell_request.abort();if(t&&t.length&&/[\x1B]/.test(t))return re=1,void h.shell_request.abort();if(!!t&&ie++,ie>=1&&!ae)t&&($(ne).after("
"),ae++,$(".-shell-port-container").addClass("progressing"));else if(ae){var a=extract_content(t,"
","
",1);a&&(a=a.replace(/<(b)[^>]*>[^<]*(<\/b>)/i,""),se=a,$(ne).next("pre").replaceWith(a)),z.scrollTop(z[0].scrollHeight)}},!1),e},type:"POST",url:S+"?stripped=1&stripped=2",data:te,dataType:"text",cache:!1,contentType:!1,processData:!1,complete:function(e){$(".-shell-port-container").removeClass("progressing");var t=e.status;if(e=e.responseText,Test.strContains(e,v___page_signin_form))return void(v___available_session=0);if(re||200!==t){var a=200!==t?$.trim(extract_content(se,"
","
",0))+(h.shell_request_interrupted?"\n^C":String()):theme_language("theme_xhred_shell_aborted");return u.find("pre").append(""+$(".-shell-port-type").text()+" "+f.val()+" \n"+a+"\n"),o(q),void l(ne,f,z)}var i=$(".-shell-port-type").text(),n=$(e).find("pre").length?$(e).find("pre"):$(e).filter("pre"),s=n.html().replace(/>>/g,">"+i),r=$(e).find('input[name="previous"][type="hidden"]').map(function(){return Convert.htmlEscape($(this).val())}).get();localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(r)),newPwd=$(e).find('input[name="pwd"]').val(),u.find("pre").append(E?s.replace(new RegExp(q,"g"),E):s),Z.text(j?j:newPwd==Z.attr("data-home")?"~":newPwd.split("/").filter(function(e){return""!=$.trim(e)}).slice(-1)[0]).attr("data-pwd",j?j:newPwd).attr("title",j?j:newPwd),l(ne,f,z)},error:function(e){}})}}}}),m.on("click"+x,"[data-shell-config]",function(){3!==get_access_level()&&$.ajax({type:"GET",url:v___location_prefix+"/config.cgi?shell",data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=$(e).find(".ui_form"),a=t.find("table.sub_table_container"),i=v___location_prefix+"/config_save.cgi";a.find("a").contents().unwrap();var n=a.find("tbody"),s=$(e).find("tr th.table-title b").text();theme_alert(s,'
'+n[0].outerHTML+'
",!1,"md","info","cogs",'10 modal-shell-config" data-keyboard="false" data-backdrop="static',0),setTimeout(function(){$("[data-save-shell-config]").on("click",function(e){e.preventDefault();var t=$(this);if(!t.hasClass("disabled")){var a=$(".modal-shell-config"),n=a.find("form").serialize();t.addClass("disabled").find("i").replaceWith(theme_spinner_small(!1," ")),$.ajax({type:"POST",url:i,data:n,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);a.find('[data-dismiss="modal"]').trigger("click")},error:function(){}})}})},300)}})}).on("click"+x,".-shell-port-close",function(){h()&&c()})};return{type:t,init:u,status:e,link:n,unlock:s,open:d,close:c,toggle:p,done:l,available:h,adjust:g,set:f}}(),plugins.favicon=function(){var e=function(e){a.badge(e),titlenotifier.set(e),a.lastNum=e},t=0;"object"==typeof a&&a.lastNum&&(t=a.lastNum);var a=new Favico({animation:"none"});return e(t),{set:e}}(),plugins.slider=function(){var set_visibility=function(e,t){if(1!==vars.slider_pinned||e||!$(".right-side-tabs i.fa2-collapse-right:visible").length){var a=get_server_data("access-level"),i="body .right-side-tabs";"0"==a&&(e?($(i+"-toggler").addClass("hidden"),$(i).css("right","0px").addClass("right-side-tabs-fixed"),settings_side_slider_enabled&&get_server_data("data-slider-fixed","1")):(settings_side_slider_enabled&&(t?$(i+"-toggler").removeClass("hidden").addClass("opened").css("right","300px"):$(i+"-toggler").removeClass("hidden opened").css("right","0")),t?$(i).css("right","0px"):$(i).css("right","-302px"),$(i).removeClass("right-side-tabs-fixed"),get_server_data("data-slider-fixed","0")))}},display_badges=function(){if(settings_side_slider_enabled&&settings_side_slider_notifications_enabled){var e="right-side-tab-notification-asterix",t="faa-ring faa-slow animated-hover",a=$(".right-side-tabs .list-group-item:not(.no-notifications, .opacity-0_3)").length;plugins.favicon.set(a),a>0?($(".right-side-tabs-toggler button i.fa-bell").addClass(t),$(".right-side-tabs-toggler button span.badge").removeClass("hidden").text(a),$("#right-side-tabs ."+e).removeClass("hidden").text(a)):($(".right-side-tabs-toggler button i.fa-bell").removeClass(t),$(".right-side-tabs-toggler button span.badge").addClass("hidden").text(0),$("#right-side-tabs ."+e).addClass("hidden").text(0))}},check_notifications=function(){var $current_localData_notifications={};$.each(localStorage,function(e,t){if("string"==typeof e&&e.indexOf("notifications_")>-1&&e.indexOf(v___server_hostname)>-1){var a=e.split("_")[1],i=JSON.parse(t),n=i.title,s=i.time,r=i.timestamp,o=i.message,l=i.readStatus,_=i.type,d=i.link,c=s+"_"+n;"csf_deny"===_&&(c=s+"_"+n.replace(/\W/g,"")+o.replace(/\W/g,"")),$current_localData_notifications[c]=a+"~~~~"+n+"~~~~"+s+"~~~~"+r+"~~~~"+o+"~~~~"+l+"~~~~"+_+"~~~~"+d,$('.list-group-item[id="'+a+'"][data-type="'+_+'"]').length&&$('.list-group-item[id="'+a+'"][data-type="'+_+'"] .list-group-item-heading small').text(moment.unix(s).fromNow())}});var package_message_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("package_message")>-1}).length,csf_remote_version_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("csf_remote_version")>-1}).length,authentic_remote_version_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("authentic_remote_version")>-1}).length,csf_title_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("csf_title")>-1}).length,keys=[] -;for(var key in $current_localData_notifications)$current_localData_notifications.hasOwnProperty(key)&&keys.push(key);$current_localData_notifications_sorted_keys=keys.sort(),$.each($current_localData_notifications_sorted_keys,function(i,v){var vx=$current_localData_notifications[v],$__id__=vx.split("~~~~")[0],$__data__title=vx.split("~~~~")[1],$__data__time=vx.split("~~~~")[2],$__data__timestamp=vx.split("~~~~")[3],$__data__message=vx.split("~~~~")[4],$__data__readStatus=vx.split("~~~~")[5],$__data__type=vx.split("~~~~")[6],$__data__link=vx.split("~~~~")[7];if("package_message"==$__data__type||"csf_remote_version"==$__data__type||"authentic_remote_version"==$__data__type||"csf_title"==$__data__type){var $__num=eval($__data__type+"_num");i+1<$__num&&($__data__readStatus=1)}$('.list-group-item[id="'+$__id__+'"][data-type="'+$__data__type+'"]').length||add_notification($__id__,$__data__title,$__data__time,$__data__timestamp,$__data__message,$__data__readStatus,$__data__type,$__data__link)})},remove_all_notifications=function(){$.each(localStorage,function(e,t){"string"==typeof e&&e.indexOf("notifications_")>-1&&e.indexOf(v___server_hostname)>-1&&delete localStorage[e]})},mark_notification_read=function(e,t,a,i){var n=JSON.parse(localStorage.getItem(v___server_hostname+"-notifications_"+e+"_"+t));n&&localStorage.setItem(v___server_hostname+"-notifications_"+e+"_"+t,JSON.stringify({title:n.title,time:n.time,timestamp:n.timestamp,message:n.message,readStatus:a,type:n.type,link:n.link})),i&&display_badges()},mark_group_notifications_read=function(e){var t="";e&&(t='[data-type="'+e+'"]'),$(".right-side-tabs .list-group-item"+t+":not(.no-notifications)").each(function(){$(this).addClass("opacity-0_3"),mark_notification_read($(this).attr("id"),$(this).data("type"),1,0)}).promise().done(function(){display_badges()})},add_notification=function(e,t,a,i,n,s,r,o){$(".right-side-tabs .list-group").prepend('
'+t+" "+moment.unix(a).fromNow()+"
"+n+"
"),$(".right-side-tabs-no-notifications").remove(),display_badges(),v___initial_load||mark_no_notifications()},mark_no_notifications=function(){var e=browser.detect.safari(1),t=e?2:0,a=function(){var e=theme_language("theme_xhred_notification_none");$(".right-side-tabs .list-group").prepend('
'+e.toUpperCase()+"
"),$(".right-side-tabs-no-notifications").animate({opacity:"1"},175,function(){})};0===$(".right-side-tabs .list-group-item").length&&(e?setTimeout(function(){a()},2):a()),setTimeout(function(){display_badges()},175+t)},update_right_pane_favorites=function(){if("function"==typeof plugins.favorites.fetch){var e=plugins.favorites.fetch(),t=$("#right-side-tabs .no-favorites_data");$("#right-side-tabs .favorites-dcontainer .right_pane_favorites_link, #right-side-tabs .favorites-dcontainer .right_pane_favorites_num").remove(),e.length?($.each(e,function(e,t){var a=$("#right-side-tabs .favorites-dcontainer");get_server_data("webprefix")&&!t.link.includes("!edit")&&(t.link=get_server_data("webprefix")+t.link),a.append(''+(e+1)+'  '+t.title+"")}),t.addClass("hidden")):t.removeClass("hidden")}},sysinfo_update=function(){if(!$("body .modal.in").length){if(!e)var e=get_server_data("webprefix");if(0==v___user_level){var t=$("body").find("#system-status"),a=t.length?t[0]:0;$("#right-side-tabs-sysinfo .graph-container").length||$("#right-side-tabs .info-container").html(function(){$_____________got_rp__sys_dat=1;var e=core.moduleAvailable("package-updates"),t=core.moduleAvailable("proc")?"":" pointer-events-none",a=core.moduleAvailable("disk-usage")||core.moduleAvailable("quota")?"":" pointer-events-none",i=e?"":' class="hidden"',n=localStorage.getItem(v___server_hostname+"-sysinfo_package_message"),s=vars.local_storage?String():" hidden";return'
'+theme_language("theme_xhred_notification_no_data").toUpperCase()+"
"}());var i=$(".right-side-tabs-dismiss .fa-reload");i.addClass("fa-spin-fastest cursor-na"),setTimeout(function(){i.removeClass("fa-spin-fastest cursor-na")},3e3),$.ajax({type:"GET",url:e+"/index.cgi/?xhr-info=1&webprefix="+get_server_data("webprefix"),data:!1,dataType:"json",success:function(t){if(Test.strContains(t,v___page_signin_form))return void(v___available_session=0);$.each(t[0],function(t,i){var n=$('#right-side-tabs [data-data="'+t+'"]');if(n=n.add(n.prev("br")),n=n.add(n.prev("strong")),null!=i?n.removeClass("hidden hidden-force"):n.addClass("hidden hidden-force"),"cpu_percent"!=t&&"mem_percent"!=t&&"virt_percent"!=t&&"disk_percent"!=t||(Test.numeric(i)?localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_stats",i):localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_stats","")),a){if($(a).find('span[data-id="sysinfo_'+t+'"]').html(i),"local_time"==t||"uptime"==t||"proc"==t){var s=$(a).find('span[data-id="sysinfo_'+t+'"]'),r=s.find("a").length?s.find("a"):s.find("span"),o=r,l=$(a).find('span[data-id="sysinfo_'+t+'"]').text();"local_time"==t?snippets.datetime.tictac(1,1):o&&o.length&&s.html(o.html(l))}if(page_sysinfo_sensor_update_label(),$(a).find('.piechart[data-charts="sysinfo_'+t+'"]').length){var _=$("body").find('.piechart[data-charts="sysinfo_'+t+'"]');_.length&&!isNaN(parseInt(i))&&_.data("easyPieChart").update(i)}"cpu_percent"!=t&&"mem_percent"!=t&&"virt_percent"!=t&&"disk_percent"!=t||localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_seen",i),$(a).find(".modal-backdrop").remove()}if($__id__=moment().unix(),"cpu_percent"==t||"mem_percent"==t||"virt_percent"==t||"disk_percent"==t||"csf_title"==t||"csf_remote_version"==t||"authentic_remote_version"==t||"package_message"==t?localStorage.getItem(v___server_hostname+"-sysinfo_"+t)||localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i):i&&null!=i&&NaN!=i?localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i):localStorage.setItem(v___server_hostname+"-sysinfo_"+t,""),localStorage.getItem(v___server_hostname+"-sysinfo_package_message_initial")||localStorage.setItem(v___server_hostname+"-sysinfo_package_message_initial",1),"authentic_theme_version"==t&&!localStorage.getItem(v___server_hostname+"-sysinfo_theme_current_version")&&i&&localStorage.setItem(v___server_hostname+"-sysinfo_theme_current_version",i.match(/^\d+|\d+\b|\d+(?=\w)/g)[0]+"."+i.match(/^\d+|\d+\b|\d+(?=\w)/g)[1]),"csf_data"==t&&!localStorage.getItem(v___server_hostname+"-sysinfo_csf_current_version")&&i&&localStorage.setItem(v___server_hostname+"-sysinfo_csf_current_version",i.match(/^\d+|\d+\b|\d+(?=\w)/g)[0]+"."+i.match(/^\d+|\d+\b|\d+(?=\w)/g)[1]),"csf_title"==t||"csf_data"==t||"csf_remote_version"==t||"authentic_remote_version"==t||"authentic_theme_version"==t||"package_message"==t){if("package_message"===t&&!core.curModuleFile("package-updates","update.cgi")){if((localStorage.getItem(v___server_hostname+"-sysinfo_"+t)!=i||1==localStorage.getItem(v___server_hostname+"-sysinfo_package_message_initial"))&&i&&i.indexOf("badge-danger")>-1){var d=theme_language("theme_xhred_notifications_packages_updates"),c=$(i).html().replace(/badge-danger/g,"badge-success"),p=e+"/package-updates/index.cgi?mode=updates";localStorage.setItem(v___server_hostname+"-notifications_"+$__id__+"_package_message",JSON.stringify({title:d,time:$__id__,timestamp:$__id__,message:c,readStatus:0,type:t,link:p})),plugins.slider.notifications.dismiss("package_message"),localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i),localStorage.setItem(v___server_hostname+"-sysinfo_package_message_initial",0),notifications(d,c,t,p)}else"package_message"===t&&localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i);$(i).find("i.badge:first-child").length||plugins.slider.notifications.dismiss("package_message")}var g=localStorage.getItem(v___server_hostname+"-sysinfo_theme_current_version");if(settings_sysinfo_theme_updates&&(0==localStorage.getItem(v___server_hostname+"-sysinfo_authentic_remote_version")&&localStorage.removeItem(v___server_hostname+"-sysinfo_authentic_remote_version"),g&&localStorage.getItem(v___server_hostname+"-sysinfo_authentic_remote_version")&&"authentic_remote_version"==t&&g-1&&1!=localStorage.getItem(v___server_hostname+"-sysinfo_csf_not_running")){var b=theme_language("theme_xhred_notifications_firewall_danger"),x=theme_language("theme_xhred_notifications_firewall_danger_message").replace("%v",moment.unix($__id__).format(config_portable_theme_locale_format_long)),p=e+"/csf/index.cgi?action=lfdstatus";localStorage.setItem(v___server_hostname+"-notifications_"+$__id__+"_csf_title",JSON.stringify({title:b,time:$__id__,timestamp:$__id__,message:x,readStatus:0,type:t,link:p})),plugins.slider.notifications.dismiss("csf_title"),localStorage.setItem(v___server_hostname+"-sysinfo_csf_not_running",1),notifications(b,x,"csf_remote_version",p)}else i&&i.indexOf("label-danger")===-1&&(plugins.slider.notifications.dismiss("csf_title"),localStorage.removeItem(v___server_hostname+"-sysinfo_csf_not_running"))}if("csf_deny"==t){var y=JSON.parse(i);$.each(y,function(a,i){var i=i.split("|"),n=i[0],s=i[1],r=i[2],o=i[3],l=(i[4],i[5],i[6],i[7]);if(l=l.replace("*Port Scan*",r&&o?'Port '+o+" scan":"Port scan"),!localStorage.getItem(v___server_hostname+"-allowed_trigger_"+(n+s.replace(/\./g,"0"))+"_csf_deny")){var _=theme_language("theme_xhred_notifications_firewall_warning"),d=l+(r&&o?" ("+r+":"+o+")":""),c=e+"/csf/index.cgi?action=temp";localStorage.setItem(v___server_hostname+"-notifications_"+(n+s.replace(/\./g,"0"))+"_csf_deny",JSON.stringify({title:_,time:$__id__,timestamp:$__id__,message:d,readStatus:0,type:t,link:c})),localStorage.setItem(v___server_hostname+"-allowed_trigger_"+(n+s.replace(/\./g,"0"))+"_csf_deny",1),notifications(_,d,t,c)}})}if("cpu_percent"==t||"mem_percent"==t||"virt_percent"==t||"disk_percent"==t){var A=$("#right-side-tabs .graph-container-fw."+t);A=A.add(A.next("br")),null!=i?A.removeClass("hidden-force"):A.addClass("hidden-force")}if((localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats"))&&$("#right-side-tabs-sysinfo .graph-container").length){var k=!localStorage.getItem(v___server_hostname+"-sysinfo_"+t+"_stats"),C=$(".info-container .graph-container."+t);if(k?C.addClass("hidden").next("br").addClass("hidden"):C.removeClass("hidden").next("br").removeClass("hidden"),"cpu_percent"==t){var w=localStorage.getItem(v___server_hostname+"-sysinfo_cpu"),S=w?"("+w+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_cpu")).text(theme_language("theme_xhred_global_cpu_load")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")+"% "+S),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")+"%")}if("mem_percent"==t){var I=localStorage.getItem(v___server_hostname+"-sysinfo_mem"),V=I?"("+I+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_mem")).text(theme_language("body_real")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")+"% "+V),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")+"%")}if("virt_percent"==t){var T=localStorage.getItem(v___server_hostname+"-sysinfo_virt"),O=T?"("+T+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_virt")).text(theme_language("body_virt")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")+"% "+O),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")+"%")}if("disk_percent"==t){var z=localStorage.getItem(v___server_hostname+"-sysinfo_disk"),Z=z?"("+z+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_disk")).text(theme_language("body_disk")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats")+"% "+Z),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats")+"%")}}if($('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]').html(i),"package_message"==t&&core.moduleAvailable("package-updates")){var U=i;U&&$('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]').html($(U).html($(U).html().split(",")[0])[0].outerHTML)}if("local_time"==t){var q=$('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]'),E=q.find("a").length?q.find("a"):q.find("span");E&&E.length&&E.html(E.next("span").detach()),snippets.datetime.tictac(1,1)}if("cpu_temperature"==t){var J=0;$.each($(i).filter(".badge-cpustatus"),function(e,t){var a,n=parseInt($(this).text().split(":")[1]),s=n,r=$(this).text().indexOf("°C")>-1;a=$(this).text().indexOf("RPM")>-1?HTML.label.rpm(s):HTML.label.temperature(n,r),"bg-warning"!=a&&"bg-danger"!=a||(J=1),$("#right-side-tabs .info-container .badge-drivestatus.badge-cpustatus").length||$('strong[data-stats="cpu"] + br[data-stats="cpu"]').after(i.replace(/
| /gi,"")),$($("#right-side-tabs .info-container .badge-drivestatus.badge-cpustatus")[e]).html($(this).text()).removeClass(function(e,t){return(t.match(/(^|\s)bg-\S+/g)||[]).join(" ")}).addClass(a+"-dark")}).promise().done(function(){J||"undefined"!=typeof config_custom_force_display_cpu_sensors?$('.info-container [data-stats="cpu"]').removeClass("hidden"):$('.info-container [data-stats="cpu"]').addClass("hidden")})}if("hdd_temperature"==t){var K=0;$.each($(i).filter(".badge-drivestatus:not(.badge-cpustatus)"),function(e,t){var a,n=parseInt($(this).text().split(":")[1]),s=$(this).text().indexOf("°C")>-1;a=HTML.label.temperature(n,s),"bg-warning"!=a&&"bg-danger"!=a||(K=1),$("#right-side-tabs .info-container .badge-drivestatus:not(.badge-cpustatus)").length||$('strong[data-stats="drive"] + br[data-stats="drive"]').after(i.replace(/
| /gi,"")),$($("#right-side-tabs .info-container .badge-drivestatus:not(.badge-cpustatus)")[e]).html($(this).text()).removeClass(function(e,t){return(t.match(/(^|\s)bg-\S+/g)||[]).join(" ")}).addClass(a+"-dark")}).promise().done(function(){K||"undefined"!=typeof config_custom_force_display_drive_sensors?$('.info-container [data-stats="drive"]').removeClass("hidden"):$('.info-container [data-stats="drive"]').addClass("hidden")})}if("warning_si"==t){var j=$("#right-side-tabs .info-container .warning-list-data");j.html(i.replace(/<(script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"").replace(/type='submit'/g,"formtarget='page' type='submit'").replace(/class='ui_submit/g,"class='ui_submit btn btn-default btn-xs").replace(/ui_form_end_submit" type="button"/g,'ui_form_end_submit" type="submit" formtarget="page"').replace(/ui_form_end_submit/g,"ui_form_end_submit btn-tiny")),"
"==i&&j.empty()}if("extended_si"==t){var j=$("#right-side-tabs .info-container .extended-list-data"),M=i.replace(/aria-expanded="true"/gi,'aria-expanded="false"').replace(/collapse in/gi,"collapse");opened_tabs=$("#extended_sysinfo .panel .in").map(function(){M=M.replace('data-toggle="collapse" href="#'+this.id+'" aria-expanded="false" aria-controls="'+this.id+'"','data-toggle="collapse" href="#'+this.id+'" aria-expanded="true" aria-controls="'+this.id+'"'),M=M.replace('div id="'+this.id+'" class="panel-collapse collapse"','div id="'+this.id+'" class="panel-collapse collapse in"')}).promise().done(function(){j.html('
'+M);var e=$("#right-side-tabs .extended-list-data");e.find("div.panel-heading:not(#mount_disks_info-mount):not(#status_services-status):not(#status-virtual-server):not(#acl_logins-acl):not(#sysinfo-virtual-server):not(#quota-virtual-server):not(#bw-virtual-server)").parent().remove(),$.each(e.find("div.panel-heading .panel-title"),function(){var e=$(this).find("a"),t="true"!=$(this).find("a").attr("aria-expanded")?1:0,a=t?"+":"—";$(this).append(''+a+""),e.text(Convert.strUpFirst($.trim(e.text())))}),e.find(".panel.panel-default").detach().appendTo("#right-side-tabs #extended_sysinfo"),e.find("div.panel-body").find("img").remove(),e.find('input[type="submit"]').addClass("btn btn-default btn-xs"),e.find('input[type="submit"]').parents("form").attr("formtarget","page"),e.find('button[type="button"].ui_submit').addClass("btn btn-default btn-xs"),e.find('button[type="button"].ui_submit').parents("form").attr("formtarget","page");var t=e.find('[data-referrer="acl_logins"] .panel-body > table:first-child');t.removeClass().addClass("table table-striped table-hover"),t.wrap('
'),$("#extended_sysinfo .panel").on("show.bs.collapse",function(){$(this).find(".panel-title-status").removeClass("margined-right-2").text("—")}).on("hide.bs.collapse",function(){$(this).find(".panel-title-status").addClass("margined-right-2").text("+")})})}"collect_interval"==t&&(Test.numeric(i)?settings_side_slider_background_refresh_time=parseFloat(i):settings_side_slider_background_refresh_time=0),$.trim($(".info-list-data").text()).length&&setTimeout(function(){$("#right-side-tabs .is-sysinfo_data").removeClass("hidden"),$("#right-side-tabs .no-sysinfo_data").addClass("hidden")},100)}),sysinfo_replace_dismiss_buttons(),setTimeout(function(){plugins.slider.notifications.check()},3e3),snippets.datetime.locale()}})}settings_side_slider_enabled&&("number"==typeof iupdateTimer&&clearInterval(iupdateTimer),settings_side_slider_background_refresh_time>0&&(iupdateTimer=setInterval(function(){sysinfo_update()},6e4*settings_side_slider_background_refresh_time)))}};return document.addEventListener("DOMContentLoaded",function(){if($(document.body).on("click",".right-side-tabs-dismiss i.fa-reload, ._sync_sysinfo_.fa-reload",function(){if(!$(this).hasClass("cursor-na")){var e=core.moduleAvailable("virtual-server")?"virtual-server":"system-status",t=$(this);t.addClass("fa-spin-fastest cursor-na"),$.ajax({type:"GET",url:v___location_prefix+"/"+e+"/recollect.cgi",data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);"sysinfo.cgi"===v___location_file&&get_pjax_content(v___location_prefix+"/sysinfo.cgi"),sysinfo_update()},error:function(e){t.removeClass("fa-spin-fastest cursor-na"),plugins.messenger.post(''+theme_language("theme_xhred_sysinfo_update_failed"),20,"error","sysinfoRecollect")}})}}),0==v___user_level&&$.support.spa){ +return document.activeElement&&$(document.activeElement).is("body")?v___page_activeElement:document.activeElement},local_storage:{safari:function(){if("object"==typeof localStorage)try{localStorage.setItem("d41d8cd98f00",1),localStorage.removeItem("d41d8cd98f00")}catch(e){Storage.prototype._setItem=Storage.prototype.setItem,Storage.prototype.setItem=function(){},vars.local_storage=0}}},render:{apple:function(){browser.detect.safari(1)&&$("html").css("overflow","auto");var e=$(".__page");browser.detect.safari()&&e.addClass("browser_safari"),navigator.userAgent.match(/(iPod|iPhone|iPad)/)&&e.attr("style","-webkit-overflow-scrolling: touch !important; overflow-y: scroll !important;")}}},regex={matches:function(e,t,a,n){a||(a=1);for(var r,i=[];r=t.exec(e);)i.push(r[a]);return n&&(i=i.slice(-1)[0]),i}},XHR={headers:function(e){return[e.getAllResponseHeaders(),e.getResponseHeader("content-type"),e.getResponseHeader("content-disposition"),e.getResponseHeader("content-length")]}};const plugins={};plugins.shell=function(){var e=function(){return $("body").find(".-shell-port-").hasClass("opened")},t=function(){return $t_uri_cloudmin&&$('a[target="page"][href*="/server-manager/save_serv.cgi"][href*="shell=1"]').length},a=function(){return t()?v___location_prefix+"/server-manager/shell.cgi":core.moduleAvailable("shell")?v___location_prefix+"/shell/index.cgi":0},n=function(){h()?0!=settings_show_terminal_link&&$(".user-link.ported-console").removeClass("hidden"):$(".user-link.ported-console").addClass("hidden")},s=function(){vars.shell.processing=0,$('.-shell-port- input[data-command="true"]').removeAttr("readonly")},r=function(e,t,a,i){return''},o=function(e){var a=t(),i=$('select[name="sid"]').val();e||(e=""),i||(i=0),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi/?xhr-shell-insert=1&xhr-shell-inserted="+e+"&xhr-shell-cms="+a+"&xhr-shell-cmsid="+i,dataType:"text",complete:function(e){if(e=e.responseText,Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=JSON.parse(e);localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(t))}})},l=function(e,t,a){$(e).next("pre").remove(),g(),_(t),a.scrollTop(a[0].scrollHeight),setTimeout(function(){vars.shell.processing=0,vars.shell.history=0,t.removeAttr("readonly").focus()},100)},_=function(e){e.val(""),e.focus()},d=function(e){var t=$("body").find(".-shell-port-"),a=a=void 0!==e&&(e.startsWith("!")?e.substr(1):e),i=t.find("input"),n=(t.find(".-shell-port-pwd").attr("data-pwd"),t.find("[data-shell-host]")),s=n.attr("data-shell-host");if($t_uri_cloudmin){var r=$('aside [name="sid"] option:selected');current_host_name=r.attr("title")||r.text(),n.text(current_host_name)}else n.text(s);if(o(!1),a){i.val(a);var l=$.Event("keydown");l.which=13,i.trigger(l)}t.css("bottom","0vh").addClass("opened"),u(),g(),setTimeout(function(){a||(focus(),i.focus())},20)},c=function(){$("body").find(".-shell-port-").css("bottom","100vh").removeClass("opened"),v___module==v___module_file_manager&&"function"==typeof __f__state__changed&&__f__state__changed(),$(".command-shell-editor-spinner").remove(),u(!0)},p=function(e){var t=$(".-shell-port-container .-shell-port-cmd");e?t.addClass("invisible"):t.removeClass("invisible")},g=function(){if(1==core.moduleAvailable("shell")){var e=parseInt($("body").find(".-shell-port-cmd").width()),t=parseInt($("body").find(".-shell-port-prompt").width());$("body").find('.-shell-port- input[data-command="true"]').css("width",e-t-50+"px")}},h=function(){var e=t();return 1==core.moduleAvailable("shell")||e?1:0},f=function(e){var t=$("body").find(".-shell-port-"),a=t.find(".-shell-port-pwd"),i=a.attr("data-home");if("string"==typeof e){e=Convert.uriDecodeComponent(e);var n=e&&e.endsWith("/")?e.slice(0,-1):e,s=n.split("/").pop();s||(s="/",e="/"),2==get_access_level()&&(e=get_server_data("user-home")+e),e===i&&(s="~"),a.attr("data-pwd",e).attr("title",e).text(s)}},u=function(n){var s=$(document.body).find(".-shell-port-"),f=s.find('input[data-command="true"]'),u=s.find("div[data-output]"),m=s.find(".-shell-port-container"),v=s.data("autocomplete"),b=$(window),x=".plugin-shell";if(n)return b.off("keydown"+x),b.off("keyup"+x),void m.off("click"+x);b.on("keydown"+x,function(t){var a=this,i=e(),n=$(".modal-shell-config:visible").length,r=String.fromCharCode(t.which).toLowerCase();if(t[settings_hotkey_toggle_modifier]&&r==settings_hotkey_shell&&theme_shortcuts_modifier_unique(t))return t.preventDefault(),void(i&&c());if((t.altKey||t.ctrlKey)&&"l"==String.fromCharCode(t.which).toLowerCase()&&t.preventDefault(),void 0===a.shell_request_interrupted&&(a.shell_request_interrupted=0),void 0===this.last_pressed_times?this.last_pressed_times=0:this.last_pressed_times+=1,setTimeout(function(){a.last_pressed_times=0},vars.event.double_click_delay),"c"===r&&a.last_pressed_times>1&&t.ctrlKey&&!t.shiftKey&&!t.altKey&&!t.metaKey)return a.shell_request_interrupted=1,"object"==typeof a.shell_request&&"pending"===a.shell_request.state()&&a.shell_request.abort(),void setTimeout(function(){a.shell_request_interrupted=0},1e3);if(this.searching||"r"===r&&t.ctrlKey&&!t.shiftKey&&!t.altKey&&!t.metaKey){if(t.preventDefault(),"object"==typeof a.shell_request&&"pending"===a.shell_request.state())return;var o=$(".-shell-port-type"),l=$('.-shell-port- input[data-command="true"]');if(m.scrollTop(m[0].scrollHeight),this.searching=1,run_search=function(e){var t=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),a=t.filter(function(t){return t.includes(e)});return $.unique(a).reverse()},update_search=function(e,i){if(this.used_index&&!i||(this.used_index=0),t.ctrlKey){if("c"===r)return void cancel_search(1);if("r"!==r)return}JSON.stringify(e)!=JSON.stringify(this.results)||i?this.results=e:t.shiftKey?--this.used_index:++this.used_index,e.length<=this.used_index&&(this.used_index=0),this.used_index<0&&(this.used_index=e.length-this.used_index-2);var n=this.searching_shell_str_replaced.find("span[data-searching]"),s=n.text(),o=localStorage.getItem(v___server_hostname+"-shell_command_last");if(!a.pre_searched&&o&&("undefined"===o&&(o=String()),a.pre_searched=o),!s&&a.pre_searched){n.text(a.pre_searched);var _=run_search(a.pre_searched);return void update_search(_,0)}if(!s||!e.length)return void failed_search();success_search(),e&&l.val(Convert.htmlUnEscape(e[this.used_index])),g()},failed_search=function(){var e=a.searching_shell_str_replaced.html();e.includes("failed reverse")||a.searching_shell_str_replaced.html(e.replace("reverse-i-search","failed reverse-i-search")),g(),new Audio("data:audio/ogg; codecs=opus;base64,T2dnUwACAAAAAAAAAAArS957AAAAAAff6O0BHgF2b3JiaXMAAAAAAkSsAAAAAAAAAO4CAAAAAAC4AU9nZ1MAAAAAAAAAAAAAK0veewEAAABiry0KEC3//////////////////3EDdm9yYmlzHQAAAFhpcGguT3JnIGxpYlZvcmJpcyBJIDIwMDcwNjIyAAAAAAEFdm9yYmlzK0JDVgEACAAAADFMIMWA0JBVAAAQAABgJCkOk2ZJKaWUoSh5mJRISSmllMUwiZiUicUYY4wxxhhjjDHGGGOMIDRkFQAABACAKAmOo+ZJas45ZxgnjnKgOWlOOKcgB4pR4DkJwvUmY26mtKZrbs4pJQgNWQUAAAIAQEghhRRSSCGFFGKIIYYYYoghhxxyyCGnnHIKKqigggoyyCCDTDLppJNOOumoo4466ii00EILLbTSSkwx1VZjrr0GXXxzzjnnnHPOOeecc84JQkNWAQAgAAAEQgYZZBBCCCGFFFKIKaaYcgoyyIDQkFUAACAAgAAAAABHkRRJsRTLsRzN0SRP8ixREzXRM0VTVE1VVVVVdV1XdmXXdnXXdn1ZmIVbuH1ZuIVb2IVd94VhGIZhGIZhGIZh+H3f933f930gNGQVACABAKAjOZbjKaIiGqLiOaIDhIasAgBkAAAEACAJkiIpkqNJpmZqrmmbtmirtm3LsizLsgyEhqwCAAABAAQAAAAAAKBpmqZpmqZpmqZpmqZpmqZpmqZpmmZZlmVZlmV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IIZQSUkophRBCCCWEEkoIJaSUUgohhBBCKaWEUkJJKaUUQgillFBKKaGUkFJKKaUQQiillFBKKSWllFJKJZRSSikllFBKSimllEoooZRQSimllJRSSimVUkopJZRSSgkppZRSSqmUUkoppZRSUkoppZRSKaWUUkoppaSUUkoppVJKKaWUEkpJKaWUUkqllFBKKaWUUlJKKaWUSgqllFJKKaUAAKADBwCAACMqLcROM648AkcUMkxAhYasBABSAQAAQiillFJKKTWMUUoppZRSihyklFJKKaWUUkoppZRSSimVUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKKaWUUkoppZRSSimllFJKAcDdFw6APhM2rI5wUjQWWGjISgAgFQAAMIYxxphyzjmllHPOOQadlEgp5yB0TkopPYQQQgidhJR6ByGEEEIpKfUYQyghlJRS67GGTjoIpbTUaw8hhJRaaqn3HjKoKKWSUu89tVBSainG3ntLJbPSWmu9595LKinG2nrvObeSUkwtFgBgEuEAgLhgw+oIJ0VjgYWGrAIAYgAACEMMQkgppZRSSinGGGOMMcYYY4wxxhhjjDHGGGOMMQEAgAkOAAABVrArs7Rqo7ipk7zog8AndMRmZMilVMzkRNAjNdRiJdihFdzgBWChISsBADIAAMRRrDXGXitiGISSaiwNQYxBibllxijlJObWKaWUk1hTyJRSzFmKJXRMKUYpphJCxpSkGGOMKXTSWs49t1RKCwAAgCAAwECEzAQCBVBgIAMADhASpACAwgJDx3AREJBLyCgwKBwTzkmnDQBAECIzRCJiMUhMqAaKiukAYHGBIR8AMjQ20i4uoMsAF3Rx14EQghCEIBYHUEACDk644Yk3POEGJ+gUlToQAAAAAAAIAHgAAEg2gIhoZuY4Ojw+QEJERkhKTE5QUlQEAAAAAAAQAD4AAJIVICKamTmODo8PkBCREZISkxOUFJUAAEAAAQAAAAAQQAACAgIAAAAAAAEAAAACAk9nZ1MAAEAUAAAAAAAAK0veewIAAABnj+O9HJeVV1dTVZqZlJWTVZOLl//3WFxXYJeV//8Y/+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TFzwBAE9nZ1MABAcYAAAAAAAAK0veewMAAAD63TjdAv/mPjWE51OfDSVdk9Eu11E1xM/X++JzOgLu0t2GOOH1n1Ws15//P+eIvXbQx7tjr+el59oLl11Wgw2g4nryAWpMvErF6MYxEgAAAEwJPe9Xlt/pk++eZK/lHE9KfcTQ6+D852DtPkt3soWb7tNULn++n+/rOr38+vT5burg9vnpWHko+qXJvaGl+9vP93o7FLq5ua6Rw/j9PtDT+7w/77Pvz31xvP6Sy5d3J5yrcSkf0LVnPSvpkkuZpHTZwWTtI/nhR95ZHU1YL+UqYkfz8Zvvz6VUl+ulY8GcfSaul+vlPLXrvHz7t2n66YGpX24Xx50YKRUtDrd/70H9f49u1ktNvfQ+0xlnlPu359vTPX0iAyC13P+/f2etbH3lS5uk/92ltLqWdVkj4/patxUt4/j4XOAfSxhbsS8e/b/jm/zha1MBM8nfAr8vym/++MeV5himtKKsn853EtfX16WAXl97b76q5Mgun32iLMqAaaQvvrIAnpHmkqVjWCz0tg7H1F9e7tzNNBkZ9u37PaZf7OVnnsmKI/AuP7odx7ulcTweA84yr8uzDz3LXO6dyTPnqS2yd0bu34a/ns5WAniVgWZ5zWXcp425/7a1pQIA3pSGHse7tGdraQCoPAFuBOXJC0/88nTUywU=").play()},success_search=function(){var e=a.searching_shell_str_replaced.html();a.searching_shell_str_replaced.html(e.replace("failed reverse-i-search","reverse-i-search")),g()},cancel_search=function(e){o.html(a.searching_shell_str),a.searching_shell_str=0,a.searching_shell_str_replaced=0,a.searching=0,e&&l.val(String()),g()},this.searching_shell_str||(this.searching_shell_str=o.html()),this.searching_shell_str_replaced){var _=this.searching_shell_str_replaced.find("span[data-searching]"),d=_.text();if(t.key&&1===t.key.length){var p=t.ctrlKey||t.altKey||t.metaKey?String():t.key,h=d+p;h&&(a.pre_searched=h,localStorage.setItem(v___server_hostname+"-shell_command_last",h)),_.text(h);var b=run_search(_.text());update_search(b,p)}}else this.searching_shell_str_replaced=o.html("(reverse-i-search)`': "),g();if(8===t.keyCode){var x=this.searching_shell_str_replaced.find("span[data-searching]"),y=x.text(),A=y.slice(0,-1);y&&(a.pre_searched=A,localStorage.setItem(v___server_hostname+"-shell_command_last",h)),x.text(A);var k=run_search(x.text());return void update_search(k,1)}return void(9!==t.keyCode&&13!==t.keyCode&&27!==t.keyCode&&37!==t.keyCode&&38!==t.keyCode&&39!==t.keyCode&&40!==t.keyCode||cancel_search())}if(i&&27===t.keyCode&&!n)return void c();if(i&&38===t.keyCode&&t.preventDefault(),i&&9===t.keyCode&&f.is(":focus")){if(t.preventDefault(),!v)return;var C=f.val().trim().split(/\s+(?!-)/),w=C.length,S=C[0]&&C[0].indexOf("-")===-1?0:1,I=C[1]&&C[1].indexOf(":")===-1?0:1,V=f.val().endsWith(" "),T="service"===$.trim(C[0]),O="systemctl"===$.trim(C[0]),z=$.trim(C[0])&&$.trim(C[0]).startsWith("chown"),Z=1!==C.length||!f.val().length||S||V?T||O?"services":z?"permissions":"lists":"commands";if(!$.trim(f.val()).length)return;var U=f.val(),E=s.find(".-shell-port-pwd"),q=E.attr("data-pwd");if("services"===Z){if("systemctl"===(Z=T?"service":"systemctl")&&3!==C.length)return;U="service"==Z?$.trim(C[1]):$.trim(C[2]),"service"===$.trim(C[0])&&(2===C.length&&V||3===C.length)&&(U=3===C.length?"::::"+$.trim(C[1])+"::::"+$.trim(C[2]):"::::"+$.trim(C[1]))}if(z){if(1===w&&!V)return void f.val($.trim(C[0])+" ");I&&$.trim(C[1])?V||C[2]?(Z="lists",U=q+"/::::"+$.trim(C[2])):(Z="groups",U=$.trim($.trim(C[1]).split(":")[1])):(Z="users",U=$.trim(C[1]))}"lists"!==Z||z||(U=q+"/::::"+$.trim(C[1])+"::::"+$.trim(C[0])+"::::"+$.trim(C[2])),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi?xhr-get_autocompletes=1&xhr-get_autocomplete_type="+Z+"&xhr-get_autocomplete_string="+U,data:!1,dataType:"json",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e.length;if(1===t)if("service"===Z||"systemctl"===Z||"lists"===Z){var a=$.trim(C[0]),i=$.trim(C[0])+" "+$.trim(C[1]);"lists"===Z?("cd"===a&&e[0].endsWith("/")||"cd"!==a)&&("cd"===a||"cat"===a?f.val(a+" "+e[0]):$.trim(C[2])?f.val(i+" "+e[0]):f.val(a+" "+e[0])):"service"!==a||2!==C.length&&3!==C.length?"systemctl"===a&&3===C.length&&f.val(a+" "+$.trim(C[1])+" "+e[0]):2===C.length?f.val(a+" "+e[0]+" "):3===C.length&&f.val($.trim(C[0])+" "+$.trim(C[1])+" "+e[0])}else z?I?V||C[2]?f.val($.trim(C[0])+" "+$.trim(C[1])+" "+e[0]):f.val($.trim(C[0])+" "+$.trim($.trim(C[1]).split(":")[0])+":"+e[0]+" "):f.val($.trim(C[0])+" "+e[0]+":"):f.val(e[0]+" ");else if(t>1){var n=""+$(".-shell-port-type").text()+" "+Convert.htmlEscape(f.val())+"\n";u.find("pre").append(n),u.find("pre").append(Convert.htmlEscape(e.join("\n")+"\n")),m.scrollTop(m[0].scrollHeight)}setTimeout(function(){f.focus().mousedown()},10)},error:function(){}})}}).on("keyup"+x,function(n){var h=this,m=e(),v=$(".modal-shell-config:visible").length;if(m&&!v){var b=0,x=0,y=0,A=$(".form-control.sidebar-search"),k=t(),C=$('select[name="sid"]').val(),w=0,S=a();if(!S)return;if((m||A.is(":focus"))&&8===n.keyCode&&(vars.shell.history=0),m?(b=$.trim(f.val()),x=1,y=1):(b=A.val(),x=void 0!==A.val(),y=0),(y||x&&(!b.trim()||b.trim().startsWith("!")))&&(38==n.keyCode||40==n.keyCode)){n.preventDefault(),n.stopPropagation(),void 0===localStorage.getItem(v___server_hostname+"-shell_commands")&&localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify({}));var I=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),V=I?I.length:0;if(0===vars.shell.history&&!b&&40==n.keyCode)return;if(0===vars.shell.history&&b&&38==n.keyCode)return void(w=1);if(vars.shell.history=40==n.keyCode?++vars.shell.history:--vars.shell.history,vars.shell.history<0&&38===n.keyCode?vars.shell.history=V-1:vars.shell.history>V&&(vars.shell.history=0),I&&I[vars.shell.history%V]){if(!$.isEmptyObject(I)&&(vars.shell.history==V&&38===n.keyCode||vars.shell.history==V&&40===n.keyCode||w))return m?f.val("").focus():A.val("").focus(),void(vars.shell.history=0);if(m){var T=I[vars.shell.history%V].replace(/^!/,"");f.val(Convert.htmlUnEscape(T)).focus()}}return}if(x&&b.trim().startsWith("!")&&27==n.keyCode)return n.preventDefault(),n.stopPropagation(),void A.val("").focus();if(x&&b.trim().startsWith("!")&&13==n.keyCode&&(A.addClass("_shell_form_"),n.preventDefault(),n.stopPropagation(),1==core.moduleAvailable("shell")||k)){f.val(b.trim().substring(1)).focus(),d();var O=$.Event("keyup");O.keyCode=13,f.trigger(O)}var z=s.find(".-shell-port-container"),Z=s.find(".-shell-port-pwd"),U=Z.attr("data-pwd"),E=$.trim(f.val()),q=0,J=n.keyCode?n.keyCode:n.which,K=(n.altKey||n.ctrlKey)&&"l"==String.fromCharCode(n.which).toLowerCase();if(f.is(":focus")||check_selected_text()||(n.ctrlKey||n.altKey||n.shiftKey||n.metaKey||f.val(f.val()+String.fromCharCode(n.which).toLowerCase()),f.focus()),E&&13===J||K){if(z.find("[data-searching]").length)return;if(core.moduleAvailable("shell")||k){if(1===vars.shell.processing)return;vars.shell.processing=1,("clear"===E||"reset"===E||"exit"===E||K)&&(u.find("pre").html(""),_(f),"exit"==E&&c()),"cd ~"===E&&(q=E,E="cd "+Z.attr("data-home"));var j=!1;if("cd /"===E&&(j="/"),"history -c"===E){localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify({}));var M=""+$(".-shell-port-type").text()+" "+E+"\n";u.find("pre").append(M),_(f),z.scrollTop(z[0].scrollHeight);var Q=r(S,k,null,U),R=new FormData($(Q)[0]);return void $.ajax({type:"POST",url:S+"?stripped=1&stripped=2",data:R,dataType:"text",cache:!1,contentType:!1,processData:!1,success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);o(E),vars.shell.processing=0},error:function(e){}})}if($.trim(E).startsWith("history -d")){var D=E.split(" "),W=D[2];return W&&W.length&&Test.numeric(W)&&$.ajax({type:"POST",url:v___location_prefix+"/index.cgi/?xhr-shell-pop="+W+"&xhr-shell-cms="+k+"&xhr-shell-cmsid="+C,data:!1,dataType:"text",cache:!1,contentType:!1,processData:!1,success:function(e){if("1"==e){var t=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands"));localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(t.filter(function(e,t){return t!==parseInt(W)-1})))}o(E)},error:function(e){}}),_(f),void(vars.shell.processing=0)}if(E.startsWith("history")){_(f);var P=JSON.parse(localStorage.getItem(v___server_hostname+"-shell_commands")),N=P?P.length:0,G=N?N.toString().length:0,M=""+$(".-shell-port-type").text()+" "+E+"\n";return $.each($(P),function(e,t){var a=e.toString().length,n="";for(i=0;i"+$(".-shell-port-type").text()+" "+f.val();return F.endsWith("/")||F.includes("../")?(Y.append(B+" \nCan not open file editor. Unsupported path expression.\n"),void l(ne,f,z)):(edit_file(H[1],U,[{call:"plugins.shell.toggle"},{call:"plugins.shell.done",params:[ne,f,z]},{call:"plugins.shell.close"}]),Y.append(B+" \nOpening internal file editor. "+theme_spinner_small(void 0,"white command-shell-editor-spinner")+"\n"),p(1),z.scrollTop(z[0].scrollHeight),void o(E))}if("clear"===$.trim(E)||"reset"===$.trim(E)||"exit"===$.trim(E)||K)return vars.shell.processing=0,vars.shell.history=0,g(),f.focus(),void(!K&&o(E));var ee=r(S,k,E,U),te=new FormData($(ee)[0]);f.attr("readonly","true");var ae=0,ie=0,ne=".-shell-port-cmd",se=!1,re=0;h.shell_request=$.ajax({xhr:function(){var e=new window.XMLHttpRequest;return e.addEventListener("progress",function(e){var t=e.target.responseText;if(Test.strContains(t,v___page_signin_form))return v___available_session=0,void h.shell_request.abort();if(t&&t.length&&/[\x1B]/.test(t))return re=1,void h.shell_request.abort();if(!!t&&ie++,ie>=1&&!ae)t&&($(ne).after("
"),ae++,$(".-shell-port-container").addClass("progressing"));else if(ae){var a=extract_content(t,"
","
",1);a&&(a=a.replace(/<(b)[^>]*>[^<]*(<\/b>)/i,""),se=a,$(ne).next("pre").replaceWith(a)),z.scrollTop(z[0].scrollHeight)}},!1),e},type:"POST",url:S+"?stripped=1&stripped=2",data:te,dataType:"text",cache:!1,contentType:!1,processData:!1,complete:function(e){$(".-shell-port-container").removeClass("progressing");var t=e.status;if(e=e.responseText,Test.strContains(e,v___page_signin_form))return void(v___available_session=0);if(re||200!==t){var a=200!==t?$.trim(extract_content(se,"
","
",0))+(h.shell_request_interrupted?"\n^C":String()):theme_language("theme_xhred_shell_aborted");return u.find("pre").append(""+$(".-shell-port-type").text()+" "+f.val()+" \n"+a+"\n"),o(E),void l(ne,f,z)}var i=$(".-shell-port-type").text(),n=$(e).find("pre").length?$(e).find("pre"):$(e).filter("pre"),s=n.html().replace(/>>/g,">"+i),r=$(e).find('input[name="previous"][type="hidden"]').map(function(){return Convert.htmlEscape($(this).val())}).get();localStorage.setItem(v___server_hostname+"-shell_commands",JSON.stringify(r)),newPwd=$(e).find('input[name="pwd"]').val(),u.find("pre").append(q?s.replace(new RegExp(E,"g"),q):s),Z.text(j?j:newPwd==Z.attr("data-home")?"~":newPwd.split("/").filter(function(e){return""!=$.trim(e)}).slice(-1)[0]).attr("data-pwd",j?j:newPwd).attr("title",j?j:newPwd),l(ne,f,z)},error:function(e){}})}}}}),m.on("click"+x,"[data-shell-config]",function(){3!==get_access_level()&&$.ajax({type:"GET",url:v___location_prefix+"/config.cgi?shell",data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=$(e).find(".ui_form"),a=t.find("table.sub_table_container"),i=v___location_prefix+"/config_save.cgi";a.find("a").contents().unwrap();var n=a.find("tbody"),s=$(e).find("tr th.table-title b").text();theme_alert(s,'
'+n[0].outerHTML+'
",!1,"md","info","cogs",'10 modal-shell-config" data-keyboard="false" data-backdrop="static',0),setTimeout(function(){$("[data-save-shell-config]").on("click",function(e){e.preventDefault();var t=$(this);if(!t.hasClass("disabled")){var a=$(".modal-shell-config"),n=a.find("form").serialize();t.addClass("disabled").find("i").replaceWith(theme_spinner_small(!1," ")),$.ajax({type:"POST",url:i,data:n,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);a.find('[data-dismiss="modal"]').trigger("click")},error:function(){}})}})},300)}})}).on("click"+x,".-shell-port-close",function(){h()&&c()})};return{type:t,init:u,status:e,link:n,unlock:s,open:d,close:c,toggle:p,done:l,available:h,adjust:g,set:f}}(),plugins.favicon=function(){var e=function(e){a.badge(e),titlenotifier.set(e),a.lastNum=e},t=0;"object"==typeof a&&a.lastNum&&(t=a.lastNum);var a=new Favico({animation:"none"});return e(t),{set:e}}(),plugins.slider=function(){var set_visibility=function(e,t){if(1!==vars.slider_pinned||e||!$(".right-side-tabs i.fa2-collapse-right:visible").length){var a=get_server_data("access-level"),i="body .right-side-tabs";"0"==a&&(e?($(i+"-toggler").addClass("hidden"),$(i).css("right","0px").addClass("right-side-tabs-fixed"),settings_side_slider_enabled&&get_server_data("data-slider-fixed","1")):(settings_side_slider_enabled&&(t?$(i+"-toggler").removeClass("hidden").addClass("opened").css("right","300px"):$(i+"-toggler").removeClass("hidden opened").css("right","0")),t?$(i).css("right","0px"):$(i).css("right","-302px"),$(i).removeClass("right-side-tabs-fixed"),get_server_data("data-slider-fixed","0")))}},display_badges=function(){if(settings_side_slider_enabled&&settings_side_slider_notifications_enabled){var e="right-side-tab-notification-asterix",t="faa-ring faa-slow animated-hover",a=$(".right-side-tabs .list-group-item:not(.no-notifications, .opacity-0_3)").length;plugins.favicon.set(a),a>0?($(".right-side-tabs-toggler button i.fa-bell").addClass(t),$(".right-side-tabs-toggler button span.badge").removeClass("hidden").text(a),$("#right-side-tabs ."+e).removeClass("hidden").text(a)):($(".right-side-tabs-toggler button i.fa-bell").removeClass(t),$(".right-side-tabs-toggler button span.badge").addClass("hidden").text(0),$("#right-side-tabs ."+e).addClass("hidden").text(0))}},check_notifications=function(){var $current_localData_notifications={};$.each(localStorage,function(e,t){if("string"==typeof e&&e.indexOf("notifications_")>-1&&e.indexOf(v___server_hostname)>-1){var a=e.split("_")[1],i=JSON.parse(t),n=i.title,s=i.time,r=i.timestamp,o=i.message,l=i.readStatus,_=i.type,d=i.link,c=s+"_"+n;"csf_deny"===_&&(c=s+"_"+n.replace(/\W/g,"")+o.replace(/\W/g,"")),$current_localData_notifications[c]=a+"~~~~"+n+"~~~~"+s+"~~~~"+r+"~~~~"+o+"~~~~"+l+"~~~~"+_+"~~~~"+d,$('.list-group-item[id="'+a+'"][data-type="'+_+'"]').length&&$('.list-group-item[id="'+a+'"][data-type="'+_+'"] .list-group-item-heading small').text(moment.unix(s).fromNow())}});var package_message_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("package_message")>-1}).length,csf_remote_version_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("csf_remote_version")>-1}).length,authentic_remote_version_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("authentic_remote_version")>-1}).length,csf_title_num=Object.values($current_localData_notifications).filter(function(e){return e.indexOf("csf_title")>-1}).length,keys=[] +;for(var key in $current_localData_notifications)$current_localData_notifications.hasOwnProperty(key)&&keys.push(key);$current_localData_notifications_sorted_keys=keys.sort(),$.each($current_localData_notifications_sorted_keys,function(i,v){var vx=$current_localData_notifications[v],$__id__=vx.split("~~~~")[0],$__data__title=vx.split("~~~~")[1],$__data__time=vx.split("~~~~")[2],$__data__timestamp=vx.split("~~~~")[3],$__data__message=vx.split("~~~~")[4],$__data__readStatus=vx.split("~~~~")[5],$__data__type=vx.split("~~~~")[6],$__data__link=vx.split("~~~~")[7];if("package_message"==$__data__type||"csf_remote_version"==$__data__type||"authentic_remote_version"==$__data__type||"csf_title"==$__data__type){var $__num=eval($__data__type+"_num");i+1<$__num&&($__data__readStatus=1)}$('.list-group-item[id="'+$__id__+'"][data-type="'+$__data__type+'"]').length||add_notification($__id__,$__data__title,$__data__time,$__data__timestamp,$__data__message,$__data__readStatus,$__data__type,$__data__link)})},remove_all_notifications=function(){$.each(localStorage,function(e,t){"string"==typeof e&&e.indexOf("notifications_")>-1&&e.indexOf(v___server_hostname)>-1&&delete localStorage[e]})},mark_notification_read=function(e,t,a,i){var n=JSON.parse(localStorage.getItem(v___server_hostname+"-notifications_"+e+"_"+t));n&&localStorage.setItem(v___server_hostname+"-notifications_"+e+"_"+t,JSON.stringify({title:n.title,time:n.time,timestamp:n.timestamp,message:n.message,readStatus:a,type:n.type,link:n.link})),i&&display_badges()},mark_group_notifications_read=function(e){var t="";e&&(t='[data-type="'+e+'"]'),$(".right-side-tabs .list-group-item"+t+":not(.no-notifications)").each(function(){$(this).addClass("opacity-0_3"),mark_notification_read($(this).attr("id"),$(this).data("type"),1,0)}).promise().done(function(){display_badges()})},add_notification=function(e,t,a,i,n,s,r,o){$(".right-side-tabs .list-group").prepend('
'+t+" "+moment.unix(a).fromNow()+"
"+n+"
"),$(".right-side-tabs-no-notifications").remove(),display_badges(),v___initial_load||mark_no_notifications()},mark_no_notifications=function(){var e=browser.detect.safari(1),t=e?2:0,a=function(){var e=theme_language("theme_xhred_notification_none");$(".right-side-tabs .list-group").prepend('
'+e.toUpperCase()+"
"),$(".right-side-tabs-no-notifications").animate({opacity:"1"},175,function(){})};0===$(".right-side-tabs .list-group-item").length&&(e?setTimeout(function(){a()},2):a()),setTimeout(function(){display_badges()},175+t)},update_right_pane_favorites=function(){if("function"==typeof plugins.favorites.fetch){var e=plugins.favorites.fetch(),t=$("#right-side-tabs .no-favorites_data");$("#right-side-tabs .favorites-dcontainer .right_pane_favorites_link, #right-side-tabs .favorites-dcontainer .right_pane_favorites_num").remove(),e.length?($.each(e,function(e,t){var a=$("#right-side-tabs .favorites-dcontainer");get_server_data("webprefix")&&!t.link.includes("!edit")&&(t.link=get_server_data("webprefix")+t.link),a.append(''+(e+1)+'  '+t.title+"")}),t.addClass("hidden")):t.removeClass("hidden")}},sysinfo_update=function(){if(!$("body .modal.in").length){if(!e)var e=get_server_data("webprefix");if(0==v___user_level){var t=$("body").find("#system-status"),a=t.length?t[0]:0;$("#right-side-tabs-sysinfo .graph-container").length||$("#right-side-tabs .info-container").html(function(){$_____________got_rp__sys_dat=1;var e=core.moduleAvailable("package-updates"),t=core.moduleAvailable("proc")?"":" pointer-events-none",a=core.moduleAvailable("disk-usage")||core.moduleAvailable("quota")?"":" pointer-events-none",i=e?"":' class="hidden"',n=localStorage.getItem(v___server_hostname+"-sysinfo_package_message"),s=vars.local_storage?String():" hidden";return'
'+theme_language("theme_xhred_notification_no_data").toUpperCase()+"
"}());var i=$(".right-side-tabs-dismiss .fa-reload");i.addClass("fa-spin-fastest cursor-na"),setTimeout(function(){i.removeClass("fa-spin-fastest cursor-na")},3e3),$.ajax({type:"GET",url:e+"/index.cgi/?xhr-info=1&webprefix="+get_server_data("webprefix"),data:!1,dataType:"json",success:function(t){if(Test.strContains(t,v___page_signin_form))return void(v___available_session=0);$.each(t[0],function(t,i){var n=$('#right-side-tabs [data-data="'+t+'"]');if(n=n.add(n.prev("br")),n=n.add(n.prev("strong")),null!=i?n.removeClass("hidden hidden-force"):n.addClass("hidden hidden-force"),"cpu_percent"!=t&&"mem_percent"!=t&&"virt_percent"!=t&&"disk_percent"!=t||(Test.numeric(i)?localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_stats",i):localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_stats","")),a){if($(a).find('span[data-id="sysinfo_'+t+'"]').html(i),"local_time"==t||"uptime"==t||"proc"==t){var s=$(a).find('span[data-id="sysinfo_'+t+'"]'),r=s.find("a").length?s.find("a"):s.find("span"),o=r,l=$(a).find('span[data-id="sysinfo_'+t+'"]').text();"local_time"==t?snippets.datetime.tictac(1,1):o&&o.length&&s.html(o.html(l))}if(page_sysinfo_sensor_update_label(),$(a).find('.piechart[data-charts="sysinfo_'+t+'"]').length){var _=$("body").find('.piechart[data-charts="sysinfo_'+t+'"]');_.length&&!isNaN(parseInt(i))&&_.data("easyPieChart").update(i)}"cpu_percent"!=t&&"mem_percent"!=t&&"virt_percent"!=t&&"disk_percent"!=t||localStorage.setItem(v___server_hostname+"-sysinfo_"+t+"_seen",i),$(a).find(".modal-backdrop").remove()}if($__id__=moment().unix(),"cpu_percent"==t||"mem_percent"==t||"virt_percent"==t||"disk_percent"==t||"csf_title"==t||"csf_remote_version"==t||"authentic_remote_version"==t||"package_message"==t?localStorage.getItem(v___server_hostname+"-sysinfo_"+t)||localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i):i&&null!=i&&NaN!=i?localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i):localStorage.setItem(v___server_hostname+"-sysinfo_"+t,""),localStorage.getItem(v___server_hostname+"-sysinfo_package_message_initial")||localStorage.setItem(v___server_hostname+"-sysinfo_package_message_initial",1),"authentic_theme_version"==t&&!localStorage.getItem(v___server_hostname+"-sysinfo_theme_current_version")&&i&&localStorage.setItem(v___server_hostname+"-sysinfo_theme_current_version",i.match(/^\d+|\d+\b|\d+(?=\w)/g)[0]+"."+i.match(/^\d+|\d+\b|\d+(?=\w)/g)[1]),"csf_data"==t&&!localStorage.getItem(v___server_hostname+"-sysinfo_csf_current_version")&&i&&localStorage.setItem(v___server_hostname+"-sysinfo_csf_current_version",i.match(/^\d+|\d+\b|\d+(?=\w)/g)[0]+"."+i.match(/^\d+|\d+\b|\d+(?=\w)/g)[1]),"csf_title"==t||"csf_data"==t||"csf_remote_version"==t||"authentic_remote_version"==t||"authentic_theme_version"==t||"package_message"==t){if("package_message"===t&&!core.curModuleFile("package-updates","update.cgi")){if((localStorage.getItem(v___server_hostname+"-sysinfo_"+t)!=i||1==localStorage.getItem(v___server_hostname+"-sysinfo_package_message_initial"))&&i&&i.indexOf("badge-danger")>-1){var d=theme_language("theme_xhred_notifications_packages_updates"),c=$(i).html().replace(/badge-danger/g,"badge-success"),p=e+"/package-updates/index.cgi?mode=updates";localStorage.setItem(v___server_hostname+"-notifications_"+$__id__+"_package_message",JSON.stringify({title:d,time:$__id__,timestamp:$__id__,message:c,readStatus:0,type:t,link:p})),plugins.slider.notifications.dismiss("package_message"),localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i),localStorage.setItem(v___server_hostname+"-sysinfo_package_message_initial",0),notifications(d,c,t,p)}else"package_message"===t&&localStorage.setItem(v___server_hostname+"-sysinfo_"+t,i);$(i).find("i.badge:first-child").length||plugins.slider.notifications.dismiss("package_message")}var g=localStorage.getItem(v___server_hostname+"-sysinfo_theme_current_version");if(settings_sysinfo_theme_updates&&(0==localStorage.getItem(v___server_hostname+"-sysinfo_authentic_remote_version")&&localStorage.removeItem(v___server_hostname+"-sysinfo_authentic_remote_version"),g&&localStorage.getItem(v___server_hostname+"-sysinfo_authentic_remote_version")&&"authentic_remote_version"==t&&g-1&&1!=localStorage.getItem(v___server_hostname+"-sysinfo_csf_not_running")){var b=theme_language("theme_xhred_notifications_firewall_danger"),x=theme_language("theme_xhred_notifications_firewall_danger_message").replace("%v",moment.unix($__id__).format(config_portable_theme_locale_format_long)),p=e+"/csf/index.cgi?action=lfdstatus";localStorage.setItem(v___server_hostname+"-notifications_"+$__id__+"_csf_title",JSON.stringify({title:b,time:$__id__,timestamp:$__id__,message:x,readStatus:0,type:t,link:p})),plugins.slider.notifications.dismiss("csf_title"),localStorage.setItem(v___server_hostname+"-sysinfo_csf_not_running",1),notifications(b,x,"csf_remote_version",p)}else i&&i.indexOf("label-danger")===-1&&(plugins.slider.notifications.dismiss("csf_title"),localStorage.removeItem(v___server_hostname+"-sysinfo_csf_not_running"))}if("csf_deny"==t){var y=JSON.parse(i);$.each(y,function(a,i){var i=i.split("|"),n=i[0],s=i[1],r=i[2],o=i[3],l=(i[4],i[5],i[6],i[7]);if(l=l.replace("*Port Scan*",r&&o?'Port '+o+" scan":"Port scan"),!localStorage.getItem(v___server_hostname+"-allowed_trigger_"+(n+s.replace(/\./g,"0"))+"_csf_deny")){var _=theme_language("theme_xhred_notifications_firewall_warning"),d=l+(r&&o?" ("+r+":"+o+")":""),c=e+"/csf/index.cgi?action=temp";localStorage.setItem(v___server_hostname+"-notifications_"+(n+s.replace(/\./g,"0"))+"_csf_deny",JSON.stringify({title:_,time:$__id__,timestamp:$__id__,message:d,readStatus:0,type:t,link:c})),localStorage.setItem(v___server_hostname+"-allowed_trigger_"+(n+s.replace(/\./g,"0"))+"_csf_deny",1),notifications(_,d,t,c)}})}if("cpu_percent"==t||"mem_percent"==t||"virt_percent"==t||"disk_percent"==t){var A=$("#right-side-tabs .graph-container-fw."+t);A=A.add(A.next("br")),null!=i?A.removeClass("hidden-force"):A.addClass("hidden-force")}if((localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")||localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats"))&&$("#right-side-tabs-sysinfo .graph-container").length){var k=!localStorage.getItem(v___server_hostname+"-sysinfo_"+t+"_stats"),C=$(".info-container .graph-container."+t);if(k?C.addClass("hidden").next("br").addClass("hidden"):C.removeClass("hidden").next("br").removeClass("hidden"),"cpu_percent"==t){var w=localStorage.getItem(v___server_hostname+"-sysinfo_cpu"),S=w?"("+w+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_cpu")).text(theme_language("theme_xhred_global_cpu_load")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")+"% "+S),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_cpu_percent_stats")+"%")}if("mem_percent"==t){var I=localStorage.getItem(v___server_hostname+"-sysinfo_mem"),V=I?"("+I+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_mem")).text(theme_language("body_real")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")+"% "+V),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_mem_percent_stats")+"%")}if("virt_percent"==t){var T=localStorage.getItem(v___server_hostname+"-sysinfo_virt"),O=T?"("+T+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_virt")).text(theme_language("body_virt")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")+"% "+O),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_virt_percent_stats")+"%")}if("disk_percent"==t){var z=localStorage.getItem(v___server_hostname+"-sysinfo_disk"),Z=z?"("+z+")":String();$("#right-side-tabs-sysinfo .graph-container."+t+" .description").attr("title",localStorage.getItem(v___server_hostname+"-sysinfo_disk")).text(theme_language("body_disk")+": "+localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats")+"% "+Z),$("#right-side-tabs-sysinfo .graph-container."+t+" .bar").attr("style","width:"+localStorage.getItem(v___server_hostname+"-sysinfo_disk_percent_stats")+"%")}}if($('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]').html(i),"package_message"==t&&core.moduleAvailable("package-updates")){var U=i;U&&$('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]').html($(U).html($(U).html().split(",")[0])[0].outerHTML)}if("local_time"==t){var E=$('#right-side-tabs .info-container .info-list-data span[data-data="'+t+'"]'),q=E.find("a").length?E.find("a"):E.find("span");q&&q.length&&q.html(q.next("span").detach()),snippets.datetime.tictac(1,1)}if("cpu_temperature"==t){var J=0;$.each($(i).filter(".badge-cpustatus"),function(e,t){var a,n=parseInt($(this).text().split(":")[1]),s=n,r=$(this).text().indexOf("°C")>-1;a=$(this).text().indexOf("RPM")>-1?HTML.label.rpm(s):HTML.label.temperature(n,r),"bg-warning"!=a&&"bg-danger"!=a||(J=1),$("#right-side-tabs .info-container .badge-drivestatus.badge-cpustatus").length||$('strong[data-stats="cpu"] + br[data-stats="cpu"]').after(i.replace(/
| /gi,"")),$($("#right-side-tabs .info-container .badge-drivestatus.badge-cpustatus")[e]).html($(this).text()).removeClass(function(e,t){return(t.match(/(^|\s)bg-\S+/g)||[]).join(" ")}).addClass(a+"-dark")}).promise().done(function(){J||"undefined"!=typeof config_custom_force_display_cpu_sensors?$('.info-container [data-stats="cpu"]').removeClass("hidden"):$('.info-container [data-stats="cpu"]').addClass("hidden")})}if("hdd_temperature"==t){var K=0;$.each($(i).filter(".badge-drivestatus:not(.badge-cpustatus)"),function(e,t){var a,n=parseInt($(this).text().split(":")[1]),s=$(this).text().indexOf("°C")>-1;a=HTML.label.temperature(n,s),"bg-warning"!=a&&"bg-danger"!=a||(K=1),$("#right-side-tabs .info-container .badge-drivestatus:not(.badge-cpustatus)").length||$('strong[data-stats="drive"] + br[data-stats="drive"]').after(i.replace(/
| /gi,"")),$($("#right-side-tabs .info-container .badge-drivestatus:not(.badge-cpustatus)")[e]).html($(this).text()).removeClass(function(e,t){return(t.match(/(^|\s)bg-\S+/g)||[]).join(" ")}).addClass(a+"-dark")}).promise().done(function(){K||"undefined"!=typeof config_custom_force_display_drive_sensors?$('.info-container [data-stats="drive"]').removeClass("hidden"):$('.info-container [data-stats="drive"]').addClass("hidden")})}if("warning_si"==t){var j=$("#right-side-tabs .info-container .warning-list-data");j.html(i.replace(/<(script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"").replace(/type='submit'/g,"formtarget='page' type='submit'").replace(/class='ui_submit/g,"class='ui_submit btn btn-default btn-xs").replace(/ui_form_end_submit" type="button"/g,'ui_form_end_submit" type="submit" formtarget="page"').replace(/ui_form_end_submit/g,"ui_form_end_submit btn-tiny")),"
"==i&&j.empty()}if("extended_si"==t){var j=$("#right-side-tabs .info-container .extended-list-data"),M=i.replace(/aria-expanded="true"/gi,'aria-expanded="false"').replace(/collapse in/gi,"collapse");opened_tabs=$("#extended_sysinfo .panel .in").map(function(){M=M.replace('data-toggle="collapse" href="#'+this.id+'" aria-expanded="false" aria-controls="'+this.id+'"','data-toggle="collapse" href="#'+this.id+'" aria-expanded="true" aria-controls="'+this.id+'"'),M=M.replace('div id="'+this.id+'" class="panel-collapse collapse"','div id="'+this.id+'" class="panel-collapse collapse in"')}).promise().done(function(){j.html('
'+M);var e=$("#right-side-tabs .extended-list-data");e.find("div.panel-heading:not(#mount_disks_info-mount):not(#status_services-status):not(#status-virtual-server):not(#acl_logins-acl):not(#sysinfo-virtual-server):not(#quota-virtual-server):not(#bw-virtual-server)").parent().remove(),$.each(e.find("div.panel-heading .panel-title"),function(){var e=$(this).find("a"),t="true"!=$(this).find("a").attr("aria-expanded")?1:0,a=t?"+":"—";$(this).append(''+a+""),e.text(Convert.strUpFirst($.trim(e.text())))}),e.find(".panel.panel-default").detach().appendTo("#right-side-tabs #extended_sysinfo"),e.find("div.panel-body").find("img").remove(),e.find('input[type="submit"]').addClass("btn btn-default btn-xs"),e.find('input[type="submit"]').parents("form").attr("formtarget","page"),e.find('button[type="button"].ui_submit').addClass("btn btn-default btn-xs"),e.find('button[type="button"].ui_submit').parents("form").attr("formtarget","page");var t=e.find('[data-referrer="acl_logins"] .panel-body > table:first-child');t.removeClass().addClass("table table-striped table-hover"),t.wrap('
'),$("#extended_sysinfo .panel").on("show.bs.collapse",function(){$(this).find(".panel-title-status").removeClass("margined-right-2").text("—")}).on("hide.bs.collapse",function(){$(this).find(".panel-title-status").addClass("margined-right-2").text("+")})})}"collect_interval"==t&&(Test.numeric(i)?settings_side_slider_background_refresh_time=parseFloat(i):settings_side_slider_background_refresh_time=0),$.trim($(".info-list-data").text()).length&&setTimeout(function(){$("#right-side-tabs .is-sysinfo_data").removeClass("hidden"),$("#right-side-tabs .no-sysinfo_data").addClass("hidden")},100)}),sysinfo_replace_dismiss_buttons(),setTimeout(function(){plugins.slider.notifications.check()},3e3),snippets.datetime.locale()}})}settings_side_slider_enabled&&("number"==typeof iupdateTimer&&clearInterval(iupdateTimer),settings_side_slider_background_refresh_time>0&&(iupdateTimer=setInterval(function(){sysinfo_update()},6e4*settings_side_slider_background_refresh_time)))}};return document.addEventListener("DOMContentLoaded",function(){if($(document.body).on("click",".right-side-tabs-dismiss i.fa-reload, ._sync_sysinfo_.fa-reload",function(){if(!$(this).hasClass("cursor-na")){var e=core.moduleAvailable("virtual-server")?"virtual-server":"system-status",t=$(this);t.addClass("fa-spin-fastest cursor-na"),$.ajax({type:"GET",url:v___location_prefix+"/"+e+"/recollect.cgi",data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);"sysinfo.cgi"===v___location_file&&get_pjax_content(v___location_prefix+"/sysinfo.cgi"),sysinfo_update()},error:function(e){t.removeClass("fa-spin-fastest cursor-na"),plugins.messenger.post(''+theme_language("theme_xhred_sysinfo_update_failed"),20,"error","sysinfoRecollect")}})}}),0==v___user_level&&$.support.spa){ var e=localStorage.getItem(v___server_hostname+"-right-side-tab")?localStorage.getItem(v___server_hostname+"-right-side-tab"):"#right-side-tabs-sysinfo",t='
'+theme_language("theme_xhred_notification_no_data").toUpperCase()+"
",a='
'+theme_language("theme_xhred_notification_no_favorites").toUpperCase()+"
",i='';browser.detect.safari(1)?setTimeout(function(){$(document.body).append(i)}):$(document.body).append(i),$('a[href="'+e+'"]:visible').length||$("#right-side-tabs ul.nav-tabs li a:visible").trigger("click"),$('#right-side-tabs .nav.nav-tabs a[data-toggle="tab"]').on("shown.bs.tab",function(e){var t=$(e.target).attr("href");localStorage.setItem(v___server_hostname+"-right-side-tab",t)}),$(document.body).on("click",'i[data-trigger="side_slider_pinned"]',function(e){e.stopImmediatePropagation();var t="1"==get_server_data("data-slider-fixed")?0:1;vars.slider_pinned=t,settings_side_slider_fixed=!settings_side_slider_fixed,set_visibility(t,void 0!==e.originalEvent?1:0),$(".dropdown.open.obj-settings .dropdown-toggle").dropdown("toggle"),$(window).resize()}).on("click",".right-side-tabs-favorites-ctl",function(e){$(".favorites-menu-outer").hasClass("hover")?$(".favorites-menu-close").trigger("click"):$(".user-link.favorites").trigger("click")}).on("click",'#right-side-tabs a:not([data-toggle="collapse"]):not([role="tab"]):not(.list-group-item)',function(e){$(".right-side-tabs-toggler:not(.hidden) .btn-menu-toggler").trigger("click")}).on("click","#right-side-tabs .info-container .graph-container-fw",function(e){var t,a=core.moduleAvailable("proc"),i=$(this).attr("class"),n=i.indexOf("cpu_")>-1?"cpu":i.indexOf("mem_")>-1?"mem":i.indexOf("virt_")>-1?"virt":"disk";"cpu"==n&&a?t=v___location_prefix+"/proc/index_cpu.cgi":"mem"!=n&&"virt"!=n||!a?"disk"==n&&core.moduleAvailable("disk-usage")?t=v___location_prefix+"/disk-usage":"disk"==n&&core.moduleAvailable("quota")&&(t=v___location_prefix+"/quota/list_users.cgi?dir=%2F"):t=v___location_prefix+"/proc/index_size.cgi",t&&get_pjax_content(t),$(".right-side-tabs-toggler:not(.hidden) .btn-menu-toggler").trigger("click")}).on("click","#right-side-tabs .fa-dashboard",function(e){get_onbeforeunload_status()?(this.href=v___location_prefix+"/sysinfo.cgi",get_onbeforeunload_message(e,this)):get_pjax_content(v___location_prefix+"/sysinfo.cgi"),$(".right-side-tabs-toggler:not(.hidden) .btn-menu-toggler").trigger("click")}).on("click","#right-side-tabs [data-click-about]",function(e){theme_update_notice(0)}).on("click",".right-side-tabs-toggler:not(.hidden)",function(e){$(this).hasClass("opened")?($(this).removeClass("opened"),$(this).animate({right:"0"},175),$(".right-side-tabs").animate({right:"-302"},175)):($(this).addClass("opened"),$(this).animate({right:"300"},350),$(".right-side-tabs").animate({right:"0"},350))}),$(".right-side-tabs .tab-pane").each(function(){$(this).css("height",$(document.body).outerHeight()-13)}),$(".right-side-tabs").on("mouseover",".list-group-item",function(e){$(this).find(".fa.fa-trash-o").removeClass("hidden"),!$(this).hasClass("opacity-0_3")&&$(this).find(".fa-clear-all").removeClass("hidden")}).on("mouseout",".list-group-item",function(e){$(this).find(".fa.fa-trash-o").addClass("hidden"),$(this).find(".fa-clear-all").addClass("hidden")}),$(".right-side-tabs").on("click","[data-port-href]",function(e){e.preventDefault(),e.stopPropagation(),open($(this).data("port-href"))}),$(".right-side-tabs").on("click",'a.list-group-item[data-type="csf_deny"]',function(e){e.preventDefault(),e.stopPropagation(),$(e.target).is(".fa.fa-trash-o")||$(e.target).is(".fa-clear-all")||$(e.target).is("[data-port-href]")||(get_bundle_csf(),$(document.body).append(''),$("form#csf_temporary_ip_entries").submit().remove(),$(".right-side-tabs-toggler:not(.hidden) .btn-menu-toggler").trigger("click"))}),$(".right-side-tabs").on("click contextmenu","a.list-group-item",function(e){e.preventDefault();var t=$(e.target).is(".fa.fa-trash-o"),a=$(e.target).is(".fa-clear-all"),i=$(e.target).is("[data-port-href]");if((t||a||i)&&(e.stopPropagation(),e.stopImmediatePropagation()),"contextmenu"==e.type)return $(this).find(".fa-clear-all").trigger("click"),e.preventDefault(),void e.stopPropagation();if(t||a||i){if($(e.target).is(".fa-clear-all"))return $(this).addClass("opacity-0_3"),$(this).find(".fa-clear-all").addClass("hidden"),void mark_notification_read($(this).attr("id"),$(this).data("type"),1,1);$(this).animate({opacity:"0"},175,function(){$(this).remove(),localStorage.removeItem(v___server_hostname+"-notifications_"+$(this).attr("id")+"_"+$(this).data("type")),mark_no_notifications()})}else $(this).attr("href")&&$(this).attr("href").length&&"undefined"!=$(this).attr("href")&&"csf_deny"!=$(this).attr("data-type")?($(this).addClass("opacity-0_3"),$(this).find(".fa-clear-all").addClass("hidden"),mark_notification_read($(this).attr("id"),$(this).data("type"),1,1),$(".right-side-tabs-toggler:not(.hidden) .btn-menu-toggler").trigger("click"),get_pjax_content($(this).attr("href"))):($(this).addClass("opacity-0_3"),mark_notification_read($(this).attr("id"),$(this).data("type"),1,1))}),$(".right-side-tabs-dismiss i.fa-clear-all").click(function(e){mark_group_notifications_read(!1)}),$(".right-side-tabs-dismiss i.fa-trash").click(function(e){$(".right-side-tabs .list-group-item:not(.no-notifications)").animate({opacity:"0"},175,function(){$(this).remove(),remove_all_notifications(),mark_no_notifications()})}),$(".right-side-tabs .tab-pane").mCustomScrollbar({axis:"y",theme:"minimal",scrollInertia:100,scrollButtons:!1}),mark_no_notifications(),check_notifications()}else get_server_data("data-slider-fixed","0"),$(".right-side-tabs-toggler").addClass("hidden")}),{state:set_visibility,badge:display_badges,notifications:{check:check_notifications,dismiss:mark_group_notifications_read},update:{favorites:update_right_pane_favorites},data:{fetch:sysinfo_update}}}(),plugins.dashboard=function(){var e=".container-fluid .panel-group .panel:not(#system-status)",t=function(){localStorage.removeItem(v___server_hostname+"-dashboard_panels")},a=function(){if(v___location_path&&v___location_path.indexOf("/sysinfo.cgi")>-1){var t=localStorage.getItem(v___server_hostname+"-dashboard_panels");if(null!=t){t=Object.entries(JSON.parse(t));for(var a=0;a div > nav > ul").length&&sortable("#favorites-menu > div > nav > ul",{items:":not(.favorites-title)",forcePlaceholderSize:!1}).on("sortupdate",function(){i()})},i=function(){$.ajax({type:"POST",url:v___location_prefix+"/settings-favorites_save.cgi",data:{favorites:'{"favorites":'+JSON.stringify(t(),null,4).replace(/\\n/g,"\\n").replace(/\\'/g,"\\'").replace(/\\"/g,'\\"').replace(/\\&/g,"\\&").replace(/\\r/g,"\\r").replace(/\\t/g,"\\t").replace(/\\b/g,"\\b").replace(/\\f/g,"\\f")+"}"},success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);plugins.slider.update.favorites()},error:function(e){}}),sortable("#favorites-menu > div > nav > ul")},n=function(){var t="favorites-menu .favorites-menu-content";0===e()&&($("#"+t+" li.favorites-no-message").removeClass("hidden"),$("#"+t+" .favorites-title sup a").addClass("hidden"))},s=function(t,a,i){var n="favorites-menu .favorites-menu-content";0===e()&&($("#"+n+" li.favorites-no-message").addClass("hidden"),$("#"+n+" .favorites-title sup a").removeClass("hidden"));var s;s='class="wbm-'+i+' wbm-sm"',$("#"+n+" li.favorites-title").after('')},r=function(e,t){$("#favorites-menu .favorites-menu-content").find('a[href="'+e+'"]').parent("li").remove(),!e.startsWith("!edit")&&$("#headln2c > .favorites, .xcustom-favorites").addClass("fa-star-o").removeClass("fa-star text-warning"),t||(n(),i())},o=function(e){var t=$("#favorites-menu li a.menu-exclude-link"),a=e,s=$('aside select option[value="'+a+'"]').attr("title");t&&t.length&&$.each(t,function(t,a){var i=$(a),n=i.attr("href"),o=i.find("span").text();n&&(n.includes(e)||o&&$.trim(o).startsWith(s))&&r(n,1)}).promise().done(function(){setTimeout(function(){n(),i()},300)})},l=function(e,t){n();var a,i,s,r=$("#favorites-menu .favorites-menu-content li:not(.exclude) a").map(function(e,t){return link_type_convert($(t).attr("href"),1)}).toArray();if(e?s=e.find(".favorites-editor"):(s=$("#headln2c > .favorites, .xcustom-favorites"),a=link_type_convert(URI(v___location).resource(),1),i=a.includes("index.cgi")?a.replace("index.cgi",""):a+"index.cgi"),a&&$.inArray(a,r)>-1||i&&$.inArray(i,r)>-1||r.includes("!edit "+t)){var o=theme_language("theme_xhred_favorites_remove");s.addClass("fa-star").removeClass("fa-star-o").attr("aria-label",o),s.attr("data-original-title",o).tooltip("fixTitle")}else{var l=theme_language("theme_xhred_favorites_add");s.removeClass("fa-star").addClass("fa-star-o").attr("aria-label",l),s.attr("data-original-title",l).tooltip("fixTitle")}};return document.addEventListener("DOMContentLoaded",function(){!function(){$(document.body).on("click",".favorites-menu a.menu-exclude-link, .right_pane_favorites_link",function(){var e=$(this).attr("href"),t=e.startsWith("!edit"),a=Test.strContains(e,"virtual-server/")?"dom":!!Test.strContains(e,"server-manager/")&&"id",i=Test.strContains(e,"gparent")?"gparent":a,n=URI.parseQuery(URI(e).query())[i],s="dom"===a?"virtualmin":"id"===a?"cloudmin":"webmin",r=$('.switch-toggle input:not([id="open_'+s+'"]):checked').length;a?setTimeout(function(){$("aside select").val()!=n&&("dom"===a?plugins.navigation.get.virtualmin(n):"id"===a&&plugins.navigation.get.cloudmin(n))},300):!t&&r&&plugins.navigation.get.webmin()}).on("click","#headln2c > .favorites:not(.dummy), .xcustom-favorites:not(.dummy), button.favorites-editor",function(e){e.preventDefault();var t,a=URI(v___location).resource(),n=function(e){var t=e.prev("strong").text(),a=t.match(/([^]+)\s\(([^)]+)\)/),i=a[1],n=a[2],s=n+"/"+i;return s=s.replace(/\/\//g,"/")},o=function(e){var t=theme_language("theme_xhred_favorites_remove");e.removeClass("fa-star-o").addClass("fa-star text-warning").attr("aria-label",t),e.attr("data-original-title",t).tooltip("fixTitle")},l=function(e){var t=theme_language("theme_xhred_favorites_add");e.addClass("fa-star-o").removeClass("fa-star text-warning").attr("aria-label",t),e.attr("data-original-title",t).tooltip("fixTitle")},_=$(this),d=_.is(".favorites-editor"),c=$(".jsPanel button.favorites-editor").not(_);if(_.hasClass("fa-star-o")){if(o(_),d)$.each(c,function(){n($(this))===n(_)&&o($(this))}),(t=n(_))&&s("!edit "+t,theme_language("theme_xhred_file_editor")+" - "+t,"editor");else{var p=$("#headln2c > span[data-main_title]").text().trim(),g=$(".has-sub.active").text().trim(),h=$(".sub_active").text().trim(),f=h.trim()!==p.trim(),u="",m="";($t_uri_virtualmin||$t_uri_cloudmin)&&(u=$("aside .ui_select option:selected").text()),$('body[class^="'+v___module_file_manager+'"]').length&&(m=URI.parseQuery(URI(v___location).query()).path,m=m?"["+m+"]":"[/]"),s(a,(u.length?u+" - ":"")+(g.length?g+"/":"")+(h.length?h+(p.length&&f?": ":""):"")+(f?p:"")+(m.length?" "+m:""),$t_uri_virtualmin?"virtualmin":$t_uri_cloudmin?"cloudmin":"webmin")}i()}else l(_),d?($.each(c,function(){n($(this))===n(_)&&l($(this))}),(t=n(_))&&r("!edit "+t)):r(link_type_convert(a,1))}).on("click","#right-side-tabs .right_pane_favorites_link",function(e){$(".favorites-menu-outer.hover + .favorites-menu-close").trigger("click")}).on("click",".favorites-menu-close, nav.favorites-menu li a",function(){$(".favorites-menu-outer").removeClass("hover")}).on("keydown",function(e){"0px"==$(".favorites-menu-outer").css("left")&&27==e.keyCode&&$(".favorites-menu-outer").removeClass("hover")}),$("#favorites-menu .favorites-menu-content").on("mouseover","li:not(.exclude) span.f__c, li:not(.exclude) span.f__c small",function(){$(this).find("small").removeClass("hidden")}).on("mouseleave","li:not(.exclude) span.f__c, li:not(.exclude) span.f__c small",function(){$(this).find("small").addClass("hidden")}),$("#favorites-menu .favorites-menu-content").on("mouseover","li:not(.exclude) small",function(){$(this).find(".fa-times").removeClass("fa-times").addClass("fa-times-circle"),$(this).animate({"font-size":"0.7em","margin-top":"-2px","margin-left":"-1px"},160)}).on("mouseleave","li:not(.exclude) small",function(){$(this).find(".fa-times-circle").removeClass("fa-times-circle").addClass("fa-times"),$(this).animate({"font-size":"0.6em","margin-top":"-1px","margin-left":"0"},80)}),$("#favorites-menu .favorites-menu-content").on("click","li:not(.exclude) small .fa-times-circle",function(e){e.preventDefault(),e.stopPropagation(),r($(this).parents("a").attr("href"))})}(),a()}),{detect:l,fetch:t,remove:o}}(),plugins.update_notice=function(){var e="pointer-events-none bg-filter-grayscale-opacity50",t="bg-filter-blur-grayscale-opacity50";$(document.body).on("hide.bs.modal","#update_notice",function(){$(this).hasClass("r")?($(document.body).append('
'),$("div.update_notice_overlay").animate({opacity:1},480,function(){setTimeout(function(){theme_reload()},100)})):("0px"==___________content_initial_?$("#content").removeAttr("style"):$("#content").animate({"margin-left":___________content_initial_},320/1.5),$("aside").animate({"margin-left":0},320/1.5,function(){$(".right-side-tabs, .right-side-tabs-toggler").removeClass(e),setTimeout(function(){$(".container-fluid").removeClass(e+" "+t)},0)})),$("#update_notice").remove()}).on("show.bs.modal","#update_notice",function(){$("#update_notice").length;var a=$(this),i=$("aside").css("left");___________content_initial_=$("#content").css("margin-left"),________version_date_obj=a.find(".modal-body > h4:first-child"),________version_curr_text=________version_date_obj.text().split(/\s+/)[1],________version_first_text=$(".versionSeparator:last").text(),________multi_in_branch=$(".versionSeparator").length,_____version__x=________version_first_text+"..."+v___theme_version;var n=$(".versionSeparator"),s=theme_language("theme_xhred_global_development_version");$.each(n,function(){$(this).attr("target","_blank")}),setTimeout(function(){$(".container-fluid").addClass(t)},0),$("#content").animate({"margin-left":0},320),$("aside").animate({"margin-left":i},320),$(".right-side-tabs, .right-side-tabs-toggler, .container-fluid").addClass(e);var r=$(this).find(".modal-body h4"),o=$(this).find(".modal-body h4:first");if(!$(this).find(".modal-body h4:first .diffctl").length){var l=new RegExp(RegExp.quote(________version_curr_text),"g");________multi_in_branch&&(r.replaceText(l,""+_____version__x+""),r.replaceText(/Version/,"Versions"));var _=$(this).find('.modal-body h4:contains("alpha"), .modal-body h4:contains("beta"), .modal-body h4:contains("RC")').length;if(r.length&&_){var d=$(this).find('.modal-body a[href*="authentic-theme/releases"]:first').text().match(/-?(?:\d+(?:\.\d*)?|\.\d+)/);latest_release=parseFloat(d?d[0]:v___theme_version);var c=o.text(),p=c.split("..."),g=0,h=$('a.versionSeparator[href*="releases"]:not(:empty)').first().text();p[1]&&(g=p[0].replace("Versions ",""),o.text(o.text().replace(g,h))),o.append(''),o.after(''+s+"")}else o.append('').append(''+________version_curr_text+"")}var f=[];$.each($(this).find('li:contains("Fix")'),function(){if($(this).find(".label").length){var e=($(this),$(this)),t=e.parent("ul"),a=e.find("a:not(.bctl)");a.length;________multi_in_branch?(f.push(a),1===t.find("li").length&&(t.prev("hr").prev("a").remove(),t.prev("hr").remove(),t.addClass("no-data")),e.remove()):(e.find("a:first").before(''),e.find("a.bctl").click(function(t){a.toggleClass("hidden"),e.find("a.bctl i").toggleClass("fa-minus-square-o")}),a.addClass("obj-popup hidden"))}}).promise().done(function(){if(________multi_in_branch&&!$(".bctl").length&&f.length){$(".modal-body h4[data-development]").prev("hr").before('
  • Fix bugs
'),$(".modal-body span[data-bugs-container]").append(f);var e=function(e,t){return parseInt($(t).text().replace("#",""))'),t.find("a.bctl").click(function(){a.toggleClass("hidden"),t.find("a.bctl i").toggleClass("fa-minus-square-o")}),a.addClass("obj-popup hidden");var n=$("div[data-bugs]"),s=n.find("a:not(.bctl)").length;!s&&n.prev(".hr-dashed").remove(),!s&&n.remove()}var r=$(".modal#update_notice h4 span");if(Test.strContains(r.text(),"...")&&Test.strContains(r.text(),"patch")){var o=parseInt(r.text().split("...")[1].substr(-1,1));o&&$.each($(".versionSeparator:not(.version_dev)"),function(e,t){e+1!=o?$(this).addClass("hidden"):$(this).text($(this).text()+"-"+theme_language("theme_xhred_global_release").toLowerCase())})}})})},plugins.icons_row=function(){$(document.body).on("click",".inline-row input",function(e){$(this).is(":checked")?$(this).parents(".gl-icon-container").addClass("highlighted"):$(this).parents(".gl-icon-container").removeClass("highlighted")}).on("click contextmenu","div.icons-container, div.small-icons-container",function(e){var t=$(e.target).find("a[href]").first();if("click"===e.type&&$(e.target).is($(this))&&t.length)return void t.trigger("click");if("click"===e.type&&$(e.target).is(".gl-icon-select")&&!$.support.spa)e.preventDefault(),$(this).trigger("contextmenu");else if("contextmenu"===e.type){e.preventDefault(),$(this).find("input").is(":checked")?($(this).find("input").prop("checked",!1),$(this).removeClass("highlighted")):$(this).find("input").length&&($(this).find("input").prop("checked",!0),$(this).addClass("highlighted"));var a=$(e.target).is(".icon_link")?$(e.target).parent(".gl-icon-container").find(".fa-select, .fa-selected"):$(e.target).is(".gl-icon-select")?$(e.target):$(e.target).is("img")?$(e.target).parent("a").parent(".gl-icon-container").find(".fa-select, .fa-selected"):$(e.target).find(".fa-select, .fa-selected");a.hasClass("fa-select")?a.removeClass("fa-select").addClass("fa-selected"):a.removeClass("fa-selected").addClass("fa-select")}"function"==typeof db_check_selected&&db_check_selected()}).on("click",".row.icons-row.vertical-align .icons-container, .row.icons-row.vertical-align .small-icons-container",function(){$(this).hasClass("forged-xx-skip")})},plugins.chooser=function(){var e=function(e){$(".mppopup .cspinner.hidden").removeClass("hidden"),$.ajax({type:"POST",url:e,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e.replace(/<(!doctype|script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"").replace(/<\/body>|<\/html>/gi,""),a=$(t).filter(".table").html(),i=$(t).filter(".table").prev("b").html();i=n(i),$(".mppopup .modal-body").html(i+''+a+"
"),$v__mpp__g_gp=0,$(".mppopup_filter_input").focus(),$(".mppopup_filter_input").val("")}})},t=function(e){return e.replace(/&file.*&chroot/,"&file="+Convert.uriEncodeComponent(($v__mpp__g_ol+"/").replace(/\/\/+/g,"/").replace(/:\//g,"://"))+"&chroot")},a=function(e,t){var a=e.prev('input[type="text"], input[name]');return a.is("input")||e.prev("textarea").length||e.prev("br").prev("textarea").length?a.length||a.is("input")||!t||(a=e.prev("textarea"),a.length||(a=e.prev("br").prev("textarea"))):a=e.prev("span:not(.awradio)").find('input[type="text"]'),a},i=function(e,t,a){if(a){if($(".refInputData").is("textarea")){var i=$(".refInputData");i.val()?i.val(i.val()+"\n"+e.replace(/\/\/+/g,"/").replace(/:\//g,"://")):i.val(e.replace(/\/\/+/g,"/").replace(/:\//g,"://"))}else $(".refInputData").val(e.replace(/\/\/+/g,"/").replace(/:\//g,"://"));var n=$(".refInputData").parent("td").prev("td").find('input[type="radio"]'),s=$(".refInputData").parent("span").prev("span").find('input[type="radio"]'),r=$(".refInputData").prev("span").find('input[type="radio"]'),o=$(".refInputData").prev("select").find('option[value="*"]');s.length?s.trigger("click"):r.length?r.trigger("click"):o.length?o.parent("select").val("*").trigger("change"):n.trigger("click")}t&&$("body .mppopup").modal("hide")},n=function(e){e=$.url(e).attr("path").replace(/\/$/g,"").split("/");var t="";return $.each(e,function(e,a){ t+=""===a?''+(0==get_access_level()?'':'')+"\n":''+a+"\n"}),''};return document.addEventListener("DOMContentLoaded",function(){!function(){var s=document.body;$(s).on("dblclick",'.mppopup a[onclick*="fileclick("], .mppopup a[onclick*="parentdir("]',function(e){e.preventDefault()}).on("dblclick",'.mppopup a[onclick*="select("]',function(){$(".mppopup button[data-mppopup_confirm]").trigger("click")}).on("click",'.mppopup a[onclick*="fileclick("], .mppopup a[onclick*="parentdir("]',function(a){a.preventDefault(),a.stopPropagation(),a.stopImmediatePropagation();var n=this;if(n.clicks||(n.clicks=0),n.timer||(n.timer=null),n.clicks++,$data_mppopup_value.val($v__mpp__g_ol),1===n.clicks)n.timer=setTimeout(function(){if(n.clicks=0,"undefined"==typeof $v__mpp__g_gp&&($v__mpp__g_gp=0),$v__mpp__g_gp){e(t($v__mpp__g_op))}else i($v__mpp__g_ol,0,0);$v__mpp__g_gp=0},vars.event.double_click_delay);else if(clearTimeout(n.timer),n.clicks=0,$v__mpp__g_olt){var s=t($v__mpp__g_op);e(s)}else i($v__mpp__g_ol,1,1)}).on("click",".mppopup button[data-mppopup_confirm]",function(){i($data_mppopup_value.val(),1,1),core.curModule("custom")&&refInput.trigger("input")}).on("show.bs.modal",".mppopup",function(){v__mpp__ml_t__e=0,$data_mppopup_value=$(".mppopup input[data-mppopup_value]"),$('.mppopup input[data-role="tagsinput"]').tagsinput({onTagExists:function(e,t){t.hide().fadeIn(),v__mpp__ml_t__e=1}})}).on("shown.bs.modal",".mppopup",function(){var e=$("body .mppopup").find(".modal-head");$("body .mppopup").find(".modal-body"),$("body .mppopup").find(".modal-body table"),e.find(".mppopup_filter > input");setTimeout(function(){$(".mppopup_filter_input").animate({opacity:1},0),$(".mppopup_filter_input").focus()},0)}).on("hidden.bs.modal",".mppopup",function(){refInput.removeClass("refInputData"),$('.mppopup input[data-role="tagsinput"]').tagsinput("destroy"),$("body .mppopup").remove(),$("button[data-mmclick].disabled, input[data-mmclick].disabled").removeClass("disabled").removeAttr("disabled")}).on("click",".mppopup_multi_done",function(){refInput.val($.trim($('.mppopup input[data-role="tagsinput"]').val().replace(/,/g," "))),$('.mppopup span[aria-hidden="true"]').trigger("click")}).on("keyup",".mppopup_filter_input",function(e){var t=e.which,a=$(".mppopup table tbody tr:visible"),i=a.find("td:first-child a");if(!$(".mppopup .breadcrumbx").length){if(13!=t||1!==a.length||e.shiftKey){if(13==t&&1===a.length&&e.shiftKey){i.trigger("click").trigger("dblclick");var n=$(".mppopup .mppopup_multi_done:visible");n.length&&setTimeout(function(){n.trigger("click")},240)}}else i.trigger("click");$(".mppopup table tbody tr.noresults").length||$(".mppopup table tbody").append(''+theme_language("theme_xhred_global_no_results_found")+"");var s=$(".mppopup table tbody tr:visible:not(.noresults)"),r=$(".mppopup table tbody tr.noresults");s.length?r.addClass("hidden"):r.removeClass("hidden")}}).on("click","button[data-mmclick]:not(.disabled), input[data-mmclick]:not(.disabled)",function(e){e.preventDefault(),e.stopPropagation(),refInput=a($(this),1);var t=$(this),i=refInput.val(),s=encodeURIComponent(i),r=$(this).attr("data-mmclick"),o=r.match("window.open\\(['\"]*(.*?)(\\s*['\"]*,.*?)"),l=o[1].match(/(\w+\.[a-z]{3,4})/gi)[0],_=l.replace(".cgi",""),d=!1,c=!1;if(t.addClass("disabled").attr("disabled","disabled"),o[1]){var p=o[1].replace("encodeURIComponent(ifield.value)","refInputCurrValSafe");p=p.replace('"+"',"").replace('"+',"").replace("refInputCurrValSafe",s);var g=function(e,t,a,n,s,r,o,l,d,c,p){var g;r||(r=String()),o||(o=String()),g=s?'":'";var h='";$(document.body).append(h),refInput.addClass("refInputData"),$("body .mppopup").on("shown.bs.modal",function(){c&&"function"==typeof c&&c()}).on("show.bs.modal",function(){p&&"function"==typeof p&&p()}).modal("show")},h=function(e){e[1].startsWith("/")?$v__mpp__g_op=e[1]:$v__mpp__g_op="/"+e[1]},f=String(),u='form[action*="backup_sched.cgi"], form[action*="save_newquotas.cgi"], form[action*="save_validate.cgi"]';if("cron_chooser"===_){f="cron_chooser.cgi?complex="+$(u).find('[name="enabled_hidden"], [name="sched_hidden"]').val()}$.ajax({type:"POST",url:f||p,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e,a=e.match(''+i+"","",0,refInput,1,"modal-lg","modal-no-header",1,1,c,d)}else if($.isArray(a)&&a[1]&&a[1].indexOf("&multi=1")===-1)h(a),$.ajax({type:"POST",url:$v__mpp__g_op,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e.replace(/<(!doctype|script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"").replace(/<\/body>|<\/html>/gi,""),a=$(t).filter(".table").html(),i=$(t).filter(".table").prev("b").html(),s=n(i);0===$(a).find("td").length&&(a=a.replace("thead","tbody"),a=a.replace("",''+theme_language("theme_xhred_datatable_semptydirectory")+"")),t=s+''+a+"
",g(t,"type1",0,refInput,0)}});else if($.isArray(a))h(a),$.ajax({type:"POST",url:$v__mpp__g_op,data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);var t=e.replace(/<(!doctype|script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"").replace(/<\/body>|<\/html>/gi,"");t=''+$(t).filter("table").html()+"
",g(t,"type2",0,refInput,1)}});else{if($.isArray(a)&&a[1].indexOf("&multi=1")===-1)return;var i=t,s=$(i).filter("table").html();g(''+s+"
","",1,refInput,0)}}})}else $(this).removeClass("disabled"),$(this).attr("onclick",$(this).attr("data-mmclick")).removeAttr("data-mmclick"),$(this).trigger("click")})}()}),{target:a}}(),plugins.navigation=function(){document.addEventListener("DOMContentLoaded",function(){s(),o(),$("aside").on("click",".select2-container .select2-selection__arrow b",function(e){e.preventDefault(),e.stopPropagation()}).on("click",'a[href*="/file/"], a[href*="history.cgi"]',function(e){e.preventDefault(),e.stopPropagation(),window.open($(this).attr("href"),"_blank")}).on("contextmenu",".switch-toggle label",function(e){e.preventDefault();var t=$(this).attr("for").replace("open_","");if($(this).prev("input").is(":checked")){var a=v___location_href;set_server_theme_temp_data("goto",link_type_convert(a,1)),setTimeout(function(){theme_open_new_tab(a)},200)}else if("virtualmin"===t||"cloudmin"===t){var i;i="cloudmin"===t?"/server-manager/index.cgi":"/virtual-server/index.cgi";var n=link_type_convert(i,2);set_server_theme_temp_data("goto",link_type_convert(n,1)),setTimeout(function(){theme_open_new_tab(n)},200)}else if("webmail"===t){var s=v___location_prefix+"/mailbox/index.cgi?"+$__theme_navigation;set_server_theme_temp_data("goto",link_type_convert(s,1)),setTimeout(function(){theme_open_new_tab(s)},200)}else{var s=v___location_prefix+"/sysinfo.cgi?"+$__theme_navigation;set_server_theme_temp_data("goto",link_type_convert(s,1)),setTimeout(function(){theme_open_new_tab(s)},200)}}).on("click",".switch-toggle input.dynamic",function(e){if(get_onbeforeunload_status()){e.preventDefault();var t=$(".switch-toggle input:checked").attr("id");return void get_onbeforeunload_message([],{href:"::switch::"+t})}return"open_thirdlane"==$(this).attr("id")?void(location.href=v___location_prefix+"/asterisk/index.cgi"):(v($(this).attr("id").replace("open_","")),"open_dashboard"==$(this).attr("id")?void get_pjax_content(v___location_prefix+"/sysinfo.cgi"):void get_navigation_and_content($(this).attr("id").replace("open_",""),0,0))}).on("focus",".sidebar-search",function(){if($("body").hasClass("loading-bg"))return void $(this).blur();d("c",!1)}).on("blur",".sidebar-search",function(){setTimeout(function(){d("c",!0)},150)}).on("click",'.navigation a[target="page"], .user-links a[target="page"]',function(){r()}).on("click",".navigation > li .navigation_external_link",function(e){e.preventDefault(),e.stopPropagation(),b=$(this),window.open(b.attr("href"),"_blank")}).on("click",".navigation > li:not('.sub-wrapper'):not('.menu-container'):not('.navigation_external'):not([data-linked])",function(e){if(e.preventDefault(),e.stopPropagation(),v___blocked_navigation=1,"undefined"==typeof $processing&&($processing=!1),!$processing){$processing=!0;var t=$("a",this).attr("href"),a=$("a",this).attr("target"),i=$(this);a&&$(".navigation > li > ul.sub > li").each(function(){$(this).removeClass("sub_active").find("span.current").remove()}),$.when($("#sidebar .navigation > li").each(function(){var e=$(this),t=e.find("a"),a=t.is("[data-has-sub-link]");e.is(i)||(e.removeClass("active"),"#search"!=e.find("a").attr("href")&&a&&$(e.find("a").attr("href")).slideUp(175))})).done(function(){i.hasClass("active")?i.removeClass("active"):"#hide"!=t&&!a&&i.addClass("active"),setTimeout(function(){$(t).is(":visible")&&"#hide"!=t&&!a?i.addClass("active"):i.removeClass("active"),$processing=!1},350),$(t).slideToggle(175)}),"#search"==t&&$('#sidebar input[name="search"]').focus()}}).on("click",".navigation > li > ul.sub > li:not('.menu-container')",function(e){if(!e.target||!$(e.target).is("li")){var t="MacIntel"===window.navigator.platform?1:0;if(!(!t&&e.ctrlKey||t&&e.metaKey)){var a=$(this);$(".navigation > li:not('.has-sub')").removeClass("sub_active").find("span.current-large").remove(),$(".navigation > li > ul.sub > li").each(function(){$(this).removeClass("sub_active").find("span.current").remove()}),$("#webmin_search_form").find('input[name="search"]').val(""),a.addClass("sub_active").append('')}}}).on("click",'a[data-refresh="true"]',function(e){e.preventDefault(),page_refresh()}).on("focus",".form-control.sidebar-search",function(e){$(".__logo").addClass("inited"),e.preventDefault(),e.stopPropagation(),vars.shell.history=0}).on("keydown","#webmin_search_form",function(e){var t=$(this),a=t.find("input.sidebar-search"),i=a.val();$("body").find(".-shell-port-");if(i&&13===e.keyCode)if(e.preventDefault(),i.startsWith("!"))core.moduleAvailable("shell")&&plugins.shell.open(i);else{$(this).find('input[name="mod"], input[name="title"]').remove(),"virtual-server"!==w()&&"server-manager"!==w()||$("").attr({type:"hidden",name:"mod",value:w()}).appendTo($(this));var n=w(1),s=theme_language("theme_xhred_search_in_"+("mailbox"===n?"usermin":n));s=s?s:theme_language("theme_xhred_filemanager_context_search"),$("").attr({type:"hidden",name:"title",value:s}).appendTo($(this));var r=$(this).attr("action")+"?"+$(this).serialize();get_onbeforeunload_status()?get_onbeforeunload_message(!1,{href:r}):(get_pjax_content(r),a.val(""))}}).on("click","[data-collapse-trigger]",function(e){e.stopImmediatePropagation();var t="1"==get_server_data("data-navigation-collapsed")?0:1;vars.navigation_pinned=t,settings_navigation_always_collapse=!settings_navigation_always_collapse,settings_navigation_always_collapse?(get_server_data("data-navigation-collapsed",1),$(".mobile-menu-toggler").removeClass("visible-xs"),r(1,void 0!==e.originalEvent?1:0)):(get_server_data("data-navigation-collapsed",0),$(".mobile-menu-toggler").addClass("visible-xs")),setTimeout(function(){page_resized()},0),$(window).resize()}).on("click",".user-links > li.favorites",function(e){$(".favorites-menu-outer").addClass("hover")}).on("click",".user-link.palette-toggle",function(e){theme_toggle_night_mode()}).on("click",".user-link.ported-console",function(e){plugins.shell.available()&&plugins.shell.open()}).on("click",'li[data-linked] a[href="'+v___location_prefix+'/shell/"], a[href="'+v___location_prefix+'/server-manager/shell.cgi"], a[href*="shell=1"]:not(a[href*="login.cgi"])',function(e){e.preventDefault(),e.stopPropagation(),plugins.shell.open()}).on("click",".__logout-link",function(e){progress.start(),get_server_theme_temp_data("goto",0)}).mCustomScrollbar({axis:"y",theme:"minimal",scrollInertia:100,scrollButtons:!1,callbacks:{onScroll:function(){$(".mobile-menu-toggler").is(":visible")||($(".form-control.sidebar-search").blur(),$("aside select")&&$("aside select").length>0&&$("aside select").hasClass("select2-hidden-accessible")&&$("aside select").select2("close"))}}})});var e=function(){var e=".navigation";$(e+" li.has-sub").removeClass("sub_active"),$(e+" > li:not('.has-sub')").removeClass("sub_active").find("span.current-large").remove(),$(e+" > li > ul.sub > li").removeClass("sub_active").find("span.current").remove(),$(e+" > li.has-sub").removeClass("active"),$(e+" > li > ul.sub").hide(),$(e+" > li > a > i.fa.fa-folder-open-o").removeClass("fa-folder-open-o")},t=function(t,a){if(Test.arrContains(["webmin_search.cgi","settings-user.cgi","settings-editor_favorites_read.cgi"],v___location_file))return void e();if(!v___blocked_navigation){if(void 0===a){var i=1,n=0,s=$('.navigation a[href*="'+v___location_path+'"]:not([data-parent-hidden]):first');$('.navigation a[href="'+v___location_resource+'"]:not([data-parent-hidden]):first, .navigation a[href*="'+link_type_convert(v___location_path,2)+'"]:not([data-parent-hidden]):first').length?(t=v___location_resource,n=1):$('.navigation a[href^="'+v___location_resource+'"]:not([data-parent-hidden]):first').length?(t=v___location_resource,i=0):Test.strContains(v___location_file,"cgi")&&s.length&&(t=s.attr("href"),i=0,"save_log.cgi"===v___location_file&&Test.strContains(v___location_query,"error")&&Test.strContains(t,"_log")&&(Test.strContains(t,"file=")||Test.strContains(t,"extra="))&&(t=$('.navigation a[href*="'+v___location_path+'"][href*="error"]:not([data-parent-hidden]):first').attr("href")));var t=t?t.replace("/edit_users.cgi","/list_users.cgi").replace("/edit_user.cgi","/list_users.cgi").replace("/edit_alias.cgi","/list_aliases.cgi").replace("/edit_database.cgi","/list_databases.cgi").replace("/save_database.cgi","/list_databases.cgi").replace("/edit_script.cgi","/list_scripts.cgi").replace("/script_form.cgi","/list_scripts.cgi"):t;!i||"config.cgi"!==v___location_file&&"uconfig.cgi"!==v___location_file||(t=$t_uri_virtualmin?v___location_prefix+"/config.cgi?virtual-server":$t_uri_cloudmin?v___location_prefix+"/config.cgi?server-manager":$t_uri_webmail?v___location_prefix+"/uconfig.cgi?mailbox":v___location_prefix+"/"+v___location_query+"/");var r=$t_uri_webmin||$t_uri_usermin;if(!t&&r)if(Test.strContains(v___location_file,".cgi")&&!Test.strContains(v___location_file,"sysinfo.cgi"))t=v___location_path.replace(v___location_file,""),page_extended()&&(t=v___location_prefix+"/webmin/");else if(!t){var o=new RegExp("^"+v___location_prefix,"i");t=get_server_data("data-uri").replace(o,"").split("/").filter(function(e){return 0!==e.length})[0],t=v___location_prefix+"/"+t}targeted_menu_link=n?$('.navigation a[href="'+t+'"]:not([data-parent-hidden]):first, .navigation a[href="'+link_type_convert(t,2)+'"]:not([data-parent-hidden]):first'):$('.navigation a[href^="'+t+'"]:not([data-parent-hidden]):first'),targeted_menu_link.length&&e()}else targeted_menu_link=$('.navigation a[href^="'+t+'"]:not([data-parent-hidden]):first'),targeted_menu_link.length&&e();targeted_menu_link.parent("li:not(.menu-exclude):not(.user-link)").addClass("sub_active").append('').parent("ul.sub").show().parent("li:not(.menu-exclude):not(.user-link)").prev("li").addClass("active")}},a=function(){$(".mCSB_container, .mCSB_dragger").css("top","0"),!$("#_menu_loader").length&&$("body ul.navigation").before(''),$("body aside .mCSB_scrollTools, body ul.navigation, body ul.user-links").css("visibility","hidden"),$("aside ul.user-html").addClass("invisible")},i=function(){$("aside ul.user-html").removeClass("invisible"),$("body aside .mCSB_scrollTools, body ul.navigation, body ul.user-links").css("visibility","visible"),$("#_menu_loader").remove(),o(),bind_sameorigin(1),theme_to_new_tab()},n=function(){return $("#_menu_loader").length},s=function(){"none"==$("aside").css("transform")&&"1"!=$("html").attr("data-navigation-collapsed")&&($("aside").transition({x:settings_leftmenu_width},437.5,function(){$(".__logo")&&"none"==$(".__logo").css("transform")&&!$(".mobile-menu-toggler:visible").length&&$(".__logo").transition({y:"-140px"},262.5)}),setTimeout(function(){$(".switch-toggle").css("display","table")},1))},r=function(e,t){var a="mobile-menu-toggler",i=$(quirks.active_element()).is('input[name="settings_navigation_always_collapse"]');if(e&&(i=1),t)return $("."+a).addClass("selected").find("button").addClass("btn-primary").removeClass("btn-default"),void $("."+a).css("transform","translate("+settings_leftmenu_width+"px, 0px)");"function"==typeof jQuery().transition&&$("."+a+":visible").length&&$("."+a).attr("style")&&$("."+a).attr("style").indexOf("ease")==-1&&($(".__logo")&&$(".__logo").transition({y:0},262.5),$("aside, ."+a).transition({x:0},i?0:175,function(){$("."+a).removeClass("selected"),$(".switch-toggle").css("display","none"),$("aside").addClass("hidden-xs")}))},o=function(e){vars.navigation.select.back=!1,$(".form-control.sidebar-search").is(":focus")||$.each($("aside select > option"),function(){var e=$(this).text().match(/^\s{0,4}/)[0].length,t=$(this).text();settings_leftmenu_vm_cm_dropdown_icons&&(4===e&&t.indexOf("↱")===-1?$(this).html("    â†± "+t.replace(/\s/g,"")):2===e&&t.indexOf("↴")===-1&&$(this).html("  â†´ "+t.replace(/\s/g,"")))}).promise().done(function(){var t=$("aside select");if(t.removeAttr("id"),t.length){t.removeAttr("onchange disabled"),!!t.data("select2")&&t.select2("destroy"),t.unbind("select2:select"),t.select2({minimumResultsForSearch:3});t.data("select2");e&&t.select2("open"),t.on("select2:selecting",function(){t.data("previous-value",$(this).val())}),t.on("select2:select",function(e){var t=e.currentTarget.value;"dom"===e.currentTarget.name?get_onbeforeunload_status()?(vars.navigation.select.back=!0,get_onbeforeunload_message(e,this,{"plugins.navigation.get.virtualmin":[t],get_default_virtualmin_content:[t]})):(y(t),get_default_virtualmin_content(t)):"sid"===e.currentTarget.name&&(get_onbeforeunload_status()?(vars.navigation.select.back=!0,get_onbeforeunload_message(e,this,{"plugins.navigation.get.cloudmin":[t],get_default_cloudmin_content:[t]})):(A(t),get_default_cloudmin_content(t)))}),t.on("select2:open",function(e){$.each($("select > option"),function(){if($(this).attr("style")&&$(this).attr("style").indexOf("italic")>-1){var e=$(this);setTimeout(function(){$("body").find('li[id$="'+e.attr("value")+'"]').attr("style","color: #"+(v___theme_night_mode_enabled?"9a5150":"e97471")+" !important;")},1)}}),$("body").find(".select2-container:not(.select2), "+v___class_select2_leak).addClass("select2-aside")}),t.on("select2:closing",function(e){$("body").find(".select2-container, "+v___class_select2_leak).removeClass("select2-aside")}),1===$("aside select option").length&&($(".select2 span").css("cursor","default"),$(".select2 .select2-selection__arrow").remove(),t.on("select2:open",function(){$(".select2-container .select2-dropdown").css("opacity","0")})),$.each($("aside select > option"),function(){$(this).attr("style")&&$(this).attr("style").indexOf("italic")>-1&&$(".select2-selection > .select2-selection__rendered").text().trim()==$(this).text().trim()&&$(".select2-selection > .select2-selection__rendered").attr("style","color: #"+(v___theme_night_mode_enabled?"9a5150":"e97471")+" !important;")})}})},l=function(e,t){var a=$("aside select");a.val(e).trigger("change"),t&&a.trigger("select2:select")},_=function(){if(vars.navigation.select.back){l($("aside select").data("previous-value"),0),vars.navigation.select.back=!1}},d=function(e,t){var i=function(e){return e&&(e.includes("http://")||e.includes("https://")||e.includes("ftp://")||e.includes("ftps://"))?1:0};if("c"!=e||($(".autocomplete-suggestions").remove(),$(".form-control.sidebar-search").removeAttr("disabled"),$(".form-control.sidebar-search").autocomplete("dispose"),!get_onbeforeunload_status()&&$(".form-control.sidebar-search").val(""),!t)){var n={},s="li:not(.menu-exclude):not(.user-link)";$.each($(s+' > ul[id^="global_"].sub > '+s+' > a, ul.navigation > [data-after] > a, ul.navigation > li > a[href*="virtual-server/index.cgi"], ul.navigation > li > a[href*="server-manager/index.cgi"]'),function(){var e=$(this).attr("href"),t=i(e),a=("/"==e.substring(0,1)?"":"/")+e;t&&(a=e),n[a]=$.trim($(this).text())}),$('li > a[target="page"][data-href="/virtual-server/index.cgi"], '+s+' > a[target="page"][data-href="/sysinfo.cgi"], '+s+' > a[target="page"][data-href="/virtual-server/pro/history.cgi"], '+s+' > a[target="page"][data-href="/server-manager/one_history.cgi"], '+s+' > a[target="page"][data-href="/server-manager/history.cgi"], '+s+' > a[target="page"][data-href="/mailbox/list_folders.cgi"], '+s+' > a[target="page"][data-href="/mailbox/list_ifolders.cgi"], '+s+' > a[target="page"][data-href="/mailbox/list_addresses.cgi"], '+s+' > a[target="page"][data-href="/filter/edit_forward.cgi"], '+s+' > a[target="page"][data-href="/filter/edit_auto.cgi"], '+s+' > a[target="page"][data-href="/filter/edit_auto.cgi"], '+s+' > a[target="page"][data-href="/filter/"], '+s+' > a[target="page"][data-href="/mailbox/edit_sig.cgi"]').each(function(){n[$(this).attr("data-href")]=$.trim($(this).text())});var o=$.map(n,function(e,t){if("undefined"!=t)return{value:e,url:t,data:{category:C()}}}),_={};(core.curModule("custom")||v___location_path==v___location_prefix+"/backup-config/"||v___location_path==v___location_prefix+"/backup-config/index.cgi"||v___location_path==v___location_prefix+"/usermin/"||v___location_path==v___location_prefix+"/usermin/index.cgi"||v___location_path==v___location_prefix+"/webmin/"||v___location_path==v___location_prefix+"/webmin/index.cgi"||v___location_path==v___location_prefix+"/acl/"||v___location_path==v___location_prefix+"/acl/index.cgi"||v___location_path==v___location_prefix+"/init/"||v___location_path==v___location_prefix+"/init/index.cgi"||v___location_path==v___location_prefix+"/mount/"||v___location_path==v___location_prefix+"/mount/index.cgi"||v___location_path==v___location_prefix+"/quota/"||v___location_path==v___location_prefix+"/quota/index.cgi"||v___location_path==v___location_prefix+"/fsdump/"||v___location_path==v___location_prefix+"/fsdump/index.cgi"||v___location_path==v___location_prefix+"/inittab/"||v___location_path==v___location_prefix+"/inittab/index.cgi"||v___location_path==v___location_prefix+"/logrotate/"||v___location_path==v___location_prefix+"/logrotate/index.cgi"||v___location_path==v___location_prefix+"/mailcap/"||v___location_path==v___location_prefix+"/mailcap/index.cgi"||v___location_path==v___location_prefix+"/pam/"||v___location_path==v___location_prefix+"/pam/index.cgi"||v___location_path==v___location_prefix+"/proc/"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_user.cgi"||v___location_path==v___location_prefix+"/proc/index_size.cgi"||v___location_path==v___location_prefix+"/proc/index_cpu.cgi"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_search.cgi"||v___location_path==v___location_prefix+"/cron/"||v___location_path==v___location_prefix+"/cron/index.cgi"||v___location_path==v___location_prefix+"/syslog/"||v___location_path==v___location_prefix+"/syslog/index.cgi"||v___location_path==v___location_prefix+"/useradmin/"||v___location_path==v___location_prefix+"/useradmin/index.cgi"||v___location_path==v___location_prefix+"/apache/"||v___location_path==v___location_prefix+"/apache/index.cgi"||v___location_path==v___location_prefix+"/bind8/"||v___location_path==v___location_prefix+"/bind8/index.cgi"||v___location_path==v___location_prefix+"/dhcpd/"||v___location_path==v___location_prefix+"/dhcpd/index.cgi"||v___location_path==v___location_prefix+"/dovecot/"||v___location_path==v___location_prefix+"/dovecot/index.cgi"||v___location_path==v___location_prefix+"/ldap-server/"||v___location_path==v___location_prefix+"/ldap-server/index.cgi"||v___location_path==v___location_prefix+"/virtualmin-nginx/"||v___location_path==v___location_prefix+"/virtualmin-nginx/index.cgi"||v___location_path==v___location_prefix+"/fetchmail/"||v___location_path==v___location_prefix+"/fetchmail/index.cgi"||v___location_path==v___location_prefix+"/mysql/"||v___location_path==v___location_prefix+"/mysql/index.cgi"||v___location_path==v___location_prefix+"/mysql/edit_dbase.cgi"||v___location_path==v___location_prefix+"/postgresql/"||v___location_path==v___location_prefix+"/postgresql/index.cgi"||v___location_path==v___location_prefix+"/postgresql/edit_dbase.cgi"||v___location_path==v___location_prefix+"/postfix/"||v___location_path==v___location_prefix+"/postfix/index.cgi"||v___location_path==v___location_prefix+"/procmail/"||v___location_path==v___location_prefix+"/procmail/index.cgi"||v___location_path==v___location_prefix+"/proftpd/"||v___location_path==v___location_prefix+"/proftpd/index.cgi"||v___location_path==v___location_prefix+"/mailboxes/"||v___location_path==v___location_prefix+"/mailboxes/index.cgi"||v___location_path==v___location_prefix+"/mailboxes/list_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/"||v___location_path==v___location_prefix+"/mailbox/index.cgi"||v___location_path==v___location_prefix+"/samba/"||v___location_path==v___location_prefix+"/samba/index.cgi"||v___location_path==v___location_prefix+"/spam/"||v___location_path==v___location_prefix+"/spam/index.cgi"||v___location_path==v___location_prefix+"/squid/"||v___location_path==v___location_prefix+"/squid/index.cgi"||v___location_path==v___location_prefix+"/sshd/"||v___location_path==v___location_prefix+"/sshd/index.cgi"||v___location_path==v___location_prefix+"/webalizer/"||v___location_path==v___location_prefix+"/webalizer/index.cgi"||v___location_path==v___location_prefix+"/cpan/"||v___location_path==v___location_prefix+"/cpan/index.cgi"||v___location_path==v___location_prefix+"/htaccess-htpasswd/"||v___location_path==v___location_prefix+"/htaccess-htpasswd/index.cgi"||v___location_path==v___location_prefix+"/status/"||v___location_path==v___location_prefix+"/status/index.cgi"||v___location_path==v___location_prefix+"/net/"||v___location_path==v___location_prefix+"/net/index.cgi"||v___location_path==v___location_prefix+"/tcpwrappers/"||v___location_path==v___location_prefix+"/tcpwrappers/index.cgi"||v___location_path==v___location_prefix+"/fdisk/"||v___location_path==v___location_prefix+"/fdisk/index.cgi"||v___location_path==v___location_prefix+"/fail2ban/"||v___location_path==v___location_prefix+"/fail2ban/index.cgi"||v___location_path==v___location_prefix+"/nis/"||v___location_path==v___location_prefix+"/nis/index.cgi"||v___location_path==v___location_prefix+"/passwd/"||v___location_path==v___location_prefix+"/passwd/index.cgi")&&$($(".container-fluid .panel-body a[href]:not([href*='javascript'],[href*='list_users.cgi?dom'],[href*='edit_hdparm.cgi?disk'],[href*='blink.cgi?disk'],[href*='smart-status/index.cgi?drive'],[href*='help.cgi'],[href*='edit_user.cgi?new='],[href*='edit_user.cgi?idx='],[href*='edit_recipe.cgi'],[href*='up.cgi'],[href*='down.cgi'],[href*='virt_index.cgi'],[href*='save_log.cgi'],[href*='backup.cgi'],[href*='activate.cgi'],[href*='#'])")).each(function(){if(v___location_path==v___location_prefix+"/syslog/"||v___location_path==v___location_prefix+"/syslog/index.cgi")_["/"+v___location_path_lead_unslashed+$(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").next("td[data-td-e]").find("a").attr("href")]=$.trim($(this).text());else{ -v___location_path==v___location_prefix+"/backup-config/"||v___location_path==v___location_prefix+"/backup-config/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):v___location_path==v___location_prefix+"/mount/"||v___location_path==v___location_prefix+"/mount/index.cgi"||v___location_path==v___location_prefix+"/quota/"||v___location_path==v___location_prefix+"/quota/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):v___location_path==v___location_prefix+"/fsdump/"||v___location_path==v___location_prefix+"/fsdump/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").next("td").find("label").find("tt").find("tt").text()):v___location_path==v___location_prefix+"/proc/"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_user.cgi"||v___location_path==v___location_prefix+"/proc/index_size.cgi"||v___location_path==v___location_prefix+"/proc/index_cpu.cgi"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_search.cgi"?v___location_path==v___location_prefix+"/proc/index_size.cgi"||v___location_path==v___location_prefix+"/proc/index_cpu.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").text()):v___location_path==v___location_prefix+"/proc/index_search.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").text()):$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parents("td").next("td").next("td").next("td").text()):v___location_path==v___location_prefix+"/useradmin/"||v___location_path==v___location_prefix+"/useradmin/index.cgi"?$description=$.trim($(this).parents("td").next("td").find("label").text())+" — "+$(this).text()+":"+$.trim($(this).parents("td").next("td").next("td").find("label").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").find("label").text())+", "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").next("td").find("label").text()):v___location_path==v___location_prefix+"/mailboxes/list_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/"||v___location_path==v___location_prefix+"/mailbox/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").next("td").find("label").text())+" — "+$.trim($(this).parents("td").next("td").find("label").text())+" ["+$.trim($(this).parents("td").next("td").next("td").find("label").text())+"]":v___location_path==v___location_prefix+"/cpan/"||v___location_path==v___location_prefix+"/cpan/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").find("label").text()):v___location_path==v___location_prefix+"/fdisk/"||v___location_path==v___location_prefix+"/fdisk/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" - "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):$description=$.trim($(this).parent("td").next("td[data-td-e]").text()),$description?$_description=!0:$_description=!1;var e=$.trim($(this).text());if(core.curModule("bind8")){var t=$(this).parents("form").prev("br").prev("b").find("tt");if(t.length){var a=t.text();!$(this).parent(".ui_links_row").length&&a&&(e=e+" ("+a+")")}}_[("/"==$(this).attr("href").substring(0,1)?"":"/")+v___location_directory_unslashed_trail_slashed+$(this).attr("href")]=e+($_description?" (":"")+$description+($_description?")":"")}});var d=$.map(_,function(e,t){if("undefined"!=t)return{value:e,url:t,data:{category:get_module_title()}}}),c={};$.each($(s+' > ul.sub:not([id^="global_"]) > '+s+' > a, ul.navigation > [data-linked]:not([data-after]) > a:not([href*="virtual-server/index.cgi"]):not([href*="server-manager/index.cgi"])'),function(e,t){c[("/"==$(this).attr("href").substring(0,1)?"":"/")+$(this).attr("href")]=$.trim($(this).text())}),$(s+' > a[target="page"]:not([data-href="/acl/edit_user.cgi"],[data-href="/virtual-server/index.cgi"],[data-href="/sysinfo.cgi"],[data-href="/virtual-server/pro/history.cgi"], [data-href="/mailbox/list_folders.cgi"], [data-href="/mailbox/list_ifolders.cgi"], [data-href="/mailbox/list_addresses.cgi"], [data-href="/filter/edit_forward.cgi"], [data-href="/filter/edit_auto.cgi"], [data-href="/filter/edit_auto.cgi"], [data-href="/filter/"], [data-href="/mailbox/edit_sig.cgi"])').each(function(e,t){$t_uri_usermin||h()||(c[$(this).attr("data-href")]=$.trim($(this).text()))});var p=$.map(c,function(e,t){if("undefined"!=t&&!Test.strContains(t,"/shell")&&!Test.strContains(t,"shell=1"))return{value:e,url:t,data:{category:$("aside .select2-selection__rendered").text()?''+$("aside .select2-selection__rendered").clone().children().remove().end().text()+"":C()}}}),g={};$("aside select option").each(function(){g[$(this).val()+":::"+$(this).parent("select").attr("name")]=$.trim($(this).text())});var f=$.map(g,function(e,t){if("undefined"!=t)return{value:e,url:t,data:{category:$("aside select").data("autocomplete-title")}}}),u=f.concat(d).concat(p).concat(o);$(".form-control.sidebar-search").on("keydown",function(e){34!=e.keyCode&&33!=e.keyCode&&20!=e.keyCode&&17!=e.keyCode&&16!=e.keyCode&&9!=e.keyCode||(e.preventDefault(),e.stopPropagation())}),$(".form-control.sidebar-search").autocomplete({lookup:u,onSelect:function(e,t){var n=$.Autocomplete.externalEvent;if(!$.isEmptyObject(n)){var s=n.keyCode?n.keyCode:n.which;if(n.ctrlKey||n.shiftKey||n.altKey||n.metaKey||20===s||32===s||33===s||34===s||35===s||36===s||37===s||38===s||39===s||40===s||45===s||46===s||112===s||113===s||114===s||115===s||116===s||117===s||118===s||119===s||120===s||121===s||122===s||123===s||144===s||145===s)return}h()===!0&&$t_uri_dashboard&&2!=get_access_level()&&4!=get_access_level()&&v("webmin"),$(this).val("").blur(),r();var o=i(e.url);if("/"==e.url.substring(0,1)||o){if(e.url&&(o||e.url.includes("virtual-server/pro/history.cgi")||e.url.includes("server-manager/history.cgi")||e.url.includes("server-manager/one_history.cgi")))return void theme_open_new_tab(e.url,1);var _=e.url.indexOf(v___location_prefix)>-1?e.url:v___location_prefix+e.url;if(Test.strContains(v___location_prefix,v___target_servers_index)&&_&&_.endsWith("/servers/"))return;get_onbeforeunload_status()?(t&&t.preventDefault(),get_onbeforeunload_message([],{href:_})):get_pjax_content(_,["reference"])}else if(e.url&&e.url.indexOf(":::")>-1){var d=e.url.split(":::")[0];get_onbeforeunload_status()?get_onbeforeunload_message(p,this,{"plugins.navigation.select.set":[d,1]}):(a(),l(d,1))}},groupBy:"category"})}},c=function(e){if(!get_onbeforeunload_status()){var e=void 0===e||e==-1||""==e?$("aside select").val():e,t=$t_uri_virtualmin?"virtualmin":$t_uri_cloudmin?"cloudmin":$t_uri_usermin?"usermin":$t_uri_webmin?"webmin":"mail";"webmin"==t?(v("webmin"),x("webmin")):"virtualmin"==t?(v("virtualmin"),y(e)):"cloudmin"==t?(v("cloudmin"),A(e)):"usermin"==t?(v("usermin"),x("usermin")):"mail"==t&&(v("webmail"),x("webmail"))}},p=function(e){var t=$("aside select"),a=t.data("select2");e||(vars.navigation_select=a&&"undefined"!=a&&!e&&t.select2("isOpen")),e?$.each($("aside").find("forms"),function(){$(this).replaceTagName("form")}).promise().done(function(){o(vars.navigation_select)}):(a&&t.select2("destroy"),$.each($("aside").find("form"),function(){$(this).replaceTagName("forms")}))},g=function(){if("undefined"==typeof settings_leftmenu_width_initial&&(settings_leftmenu_width_initial=settings_leftmenu_width),matchMedia("(max-width: 1080px)").matches||"1"==$("html").attr("data-navigation-collapsed"))settings_leftmenu_width=260,page_adjust(settings_leftmenu_width,0);else{if(1===v___initial_load)return;settings_leftmenu_width=settings_leftmenu_width_initial,page_adjust(settings_leftmenu_width,settings_leftmenu_width)}},h=function(){return"1"==f("dashboard")},f=function(e){return e=e?'[id="open_'+e+'"]':String(),$(".switch-toggle input"+e).length},u=function(){v("dashboard"),e(),get_pjax_content(v___location_prefix+"/sysinfo.cgi")},m=function(){Test.string(v___theme_navigation_active)&&v(v___theme_navigation_active)},v=function(e){get_onbeforeunload_status()||($('.switch-toggle input:not([id="open_'+e+'"])').each(function(){$(this).removeAttr("checked")}).promise().done(function(){$("#open_"+e).length?$("#open_"+e).prop("checked",!0):$('.dynamic[name="product-switcher"]').first().prop("checked",!0)}),S())},x=function(n){get_onbeforeunload_status()||(a(),v("webmail"==n?"webmail":get_server_data("product")),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type="+("webmail"==n?"webmail":"webmin"),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="webmail"==n?"webmail":get_server_data("product"),$("body ul.navigation").html(a),i(),!get_server_data("loading")&&t(),"webmail"===n&&settings_mail_ui&&("object"==typeof mail?mail.folders.get():load.bundle(v___server_extensions_path+"/mail/mail",1,["mail.folders.get()"]))}}),k())},y=function(n){get_onbeforeunload_status()||(a(),v("virtualmin"),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type=virtualmin"+(n?"&dom="+n:settings_right_virtualmin_default?"&dom="+settings_right_virtualmin_default:""),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="virtualmin",$("body ul.navigation").html(a),i(),!get_server_data("loading")&&t()}}),k())},A=function(n){get_onbeforeunload_status()||(a(),v("cloudmin"),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type=cloudmin"+(n||0===n?"&sid="+n:settings_right_cloudmin_default?"&sid="+settings_right_cloudmin_default:""),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="cloudmin",$("body ul.navigation").html(a),plugins.shell.link(),i(),!get_server_data("loading")&&t()}}),k())},k=function(){get_onbeforeunload_status()||$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-buttons=1&xhr-buttons-type="+($t_uri_virtualmin||$t_uri_cloudmin?1:0),data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);$("body ul.user-links").html(e),plugins.shell.link()}})},C=function(){return $t_uri_webmin?theme_language("theme_xhred_titles_wm"):$t_uri_usermin?theme_language("theme_xhred_titles_um"):$t_uri_virtualmin?theme_language("theme_xhred_titles_vm"):$t_uri_cloudmin?theme_language("theme_xhred_titles_cm"):$t_uri_webmail?theme_language("theme_xhred_titles_mail"):$t_uri_dashboard?theme_language("theme_xhred_titles_dashboard"):void 0},w=function(e,t){return $t_uri_webmin?"webmin":$t_uri_usermin?"usermin":$t_uri_dashboard?"dashboard":$t_uri_virtualmin?t?"virtualmin":e?"virtualserver":"virtual-server":$t_uri_cloudmin?t?"cloudmin":e?"servermanager":"server-manager":$t_uri_webmail?"mailbox":void 0},S=function(){$t_uri_webmin=$('.switch-toggle input[id="open_webmin"]:checked').length?1:0,$t_uri_usermin=$('.switch-toggle input[id="open_usermin"]:checked').length?1:0,$t_uri_virtualmin=$('.switch-toggle input[id="open_virtualmin"]:checked').length?1:0,$t_uri_cloudmin=$('.switch-toggle input[id="open_cloudmin"]:checked').length?1:0,$t_uri_webmail=$('.switch-toggle input[id="open_webmail"]:checked').length?1:0,$t_uri_dashboard=$('.switch-toggle input[id="open_dashboard"]:checked').length?1:0};return{reset:e,select:{set:l,back:_,load:o},detect:t,load:{start:a,stop:i},collapse:r,reload:c,deform:p,lock:g,switch:{dashboard:{get:h,set:u},available:f,set:v,reset:m},get:{webmin:x,virtualmin:y,cloudmin:A},intersect:{virtualmin:function(e){var e="object"==typeof e?e.attr("href"):e,t=URI.parseQuery(URI(e).query()).dom||URI.parseQuery(URI(e).query()).gparent,a=$('select[name="dom"]'),i=a.val();t&&t!=i&&y(t)},cloudmin:function(e){var e="object"==typeof e?e.attr("href"):e,t=URI.parseQuery(URI(e).query()).id,t=t?t:URI.parseQuery(URI(e).query()).d,a=$('select[name="sid"]'),i=a.val();t&&t!=i&&A(t)}},state:{title:C,module:w,update:S,loading:n}}}(),plugins.messenger=function(){var e=function(e,t,a,i,n,s){var r=void 0===i?1:i,o=void 0===n||n;if(s=void 0===s?"":s,"hide-all"===e)return void Messenger().hideAll();if($.isArray(e)&&(e=' '+e[1]),$.isArray(s)){var l=s;s="messenger-fixed ",s+="messenger-on-"+l.join(" messenger-on-")}else s=s.length?"messenger-fixed messenger-on-"+s:"messenger-fixed messenger-on-bottom";"function"==typeof Messenger&&(Messenger.options={extraClasses:s,theme:"air"},window["Messenger_"+r]=Messenger().post({message:e,extraClasses:s,hideAfter:t,showCloseButton:o,type:a,id:r}))};return document.addEventListener("DOMContentLoaded",function(){(function(){if("function"==typeof Messenger.Message){var e,t,a,i={}.hasOwnProperty,n=function(e,t){function a(){this.constructor=e}for(var n in t)i.call(t,n)&&(e[n]=t[n]);return a.prototype=t.prototype,e.prototype=new a,e.__super__=t.prototype,e};e=jQuery,a='
\n \n \n \n \n \n \n
',t=function(t){function i(){return i.__super__.constructor.apply(this,arguments)}return n(i,t),i.prototype.template=function(t){var n;return n=i.__super__.template.apply(this,arguments),n.append(e(a)),n},i}(Messenger.Message),Messenger.themes.air={Message:t},Messenger.options={extraClasses:"messenger-fixed messenger-on-bottom",theme:"air"}}}).call(this)}),{post:e}}(),plugins.upload=function(e){e.removeAttr("onsubmit"),e.on("submit.fm",function(e){e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation();var t=moment().unix()+""+parseInt(1e5*Math.random()),a=$(this),i=a.find(".ui_form_end_submit"),n=a.find('input[type="file"]')[0],s=n.files.length,r=a.find('input[name="dir"]').val(),o=$(n.files).map(function(e,t){return t.name}).get(),l=o.join("\n"),_=function(){theme_restore_buttons_class(),$.fn.bootstrapFileInputReset(a),despinnerfy_buttons(0,i)},d=function(){s>1?plugins.messenger.post(''+theme_language("theme_xhred_upload_successful").replace("$1",""+s+"").replace("$2","`"+r+"`").replace("'+theme_language("theme_xhred_upload_successful_single").replace("$1",""+s+"").replace("$2","`"+r+"`").replace("100&&(s=100),progress_percent.control(t,"success",s,[i,n,s])}if(Test.strContains(a,v___page_signin_form))return v___available_session=0,window["progress_id_ref_"+t].abort(),void window["progress_id_ref_"+t+"_tracker"].abort()},!1),e},type:a.attr("method"),url:v___location_prefix+"/uptracker.cgi?id="+t+"&uid="+(0===get_access_level()||1===get_access_level()?"":get_server_data("user-id")),complete:function(e){c&&(c=0,_()),200===e.status&&d()}})})};const snippets={};snippets.datetime={},snippets.page={},snippets.patches={},snippets.initial=function(){plugins.dashboard.reset(),snippets.get_goto()},snippets.form_pre_submitter=function(){$("body").on("click",'button.ui_form_end_submit[type="button"]:not(.disabled)',function(){var e=$(this).next('input[type="submit"].hidden'),t=$(this).parent(".btn-group").next('input[type="submit"].hidden');e.length||(e=t);var i=e.parent(),a=(i.parent("tr").find("form"),e.parents("form"));if(!a.length)return a=e.closest("form"),a.length||(a=i.prev("form")),a.length||(a=i.prev().prev("form")),a.length||(a=i.prev().prev().prev("form")),a.append(a.nextUntil(i)),void $.each(i.find("select, input"),function(){$('').attr({type:"hidden",name:$(this).attr("name")?$(this).attr("name"):$(this).attr("id"),value:$(this).val()}).appendTo(a)}).promise().done(function(){a.submit()});var n=e.attr("name")?e.attr("name"):e.attr("id"),s=$.trim(e.val());$('').attr({type:"hidden",name:n,value:s}).appendTo(a),e.trigger("click")}),$("body").on("click",'.ui_form_end_submit:not(.disabled), .page_footer_submit:not(.disabled):not([href*="javascript:history"])',function(){core.curModule("csf")?spinnerfy_buttons($(this),[2,-29,"small",!1]):spinnerfy_buttons($(this),!1,!1,!1)})},snippets.form_input_tester=function(e){if(e)return $(".btn-group.end_submits:visible button.ui_form_end_submit").hasClass("btn-warning dt-tester-btn");$(document).on("input.tester",'form:not([data-tester="1"]):not(#webmin_search_form)',function(e){if(!vars.pjax.post_page_fetch){var t=$(this);if(1!=t.attr("data-tester")){var i=t.find(".CodeMirror").length,a=$(this).attr("action");if(i&&!core.curModule("init")||(core.curModuleFile("mysql","")||core.curModuleFile("postgresql","")||core.curModuleFile("mysql","index.cgi")||core.curModuleFile("postgresql","index.cgi"))&&$(".ui_grid_table.table-hardcoded").length||core.curModuleFile("bind8","")||core.curModuleFile("bind8","index.cgi")||core.curModuleFile("mailbox","reply_mail.cgi")||core.curModuleFile("virtual-server","wizard.cgi")||core.curModuleFile("virtual-server","list_scripts.cgi")||core.curModuleFile("virtual-server","list_scripts.cgi")||a&&a.includes("edit_tmpl.cgi")||$(".modal.in.mppopup").length)return void t.attr("data-tester",1);var n=$(e.target).is('input[type="checkbox"], input[type="radio"]'),s=$(e.target).parents("tr");if(!(n&&s&&s.length&&s.attr("class")&&s.attr("class").includes("ui_checked"))){theme_restore_buttons_class();var o=t.find(".btn-group.end_submits:visible button.ui_form_end_submit"),r=o.first(),l=String("btn-xclass"),_=1===o.data("click-event");if(r[0]&&r[0].classList){var c=r[0].classList.value.match(/.*(btn-\S+)/);c&&(l=c[1],r.attr("data-class-restore",l))}o&&o.length&&(set_onbeforeunload_status(1),_||(o.data("click-event",1),r.removeClass(l).addClass("btn-warning dt-tester-btn"),t.attr("data-tester",1),o.one("click",function(){o.data("click-event",0),t.attr("data-tester",0),set_onbeforeunload_status(0)}),t.on("keydown",function(e){var t=e.keyCode?e.keyCode:e.which;(13===t&&!$(e.target).is("textarea")||13===t&&e.ctrlKey&&$(e.target).is("textarea"))&&(r.hasClass("btn-warning dt-tester-btn")?(e.preventDefault(),r.trigger("click")):set_onbeforeunload_status(0))})))}}}})},snippets.inject_extra_option=function(e,t,i,a){if("tr/yes:no"===e){var n=$("body"),s=t.parents("form");t.parents("td.col_value").parent("tr").after(' '+a+' ");var o="submit."+i;n.off(o),n.one(o,s,function(){var e=Test.true($("[name="+i+"]:checked").val());window[i]=e,theme_config_store()})}},snippets.datetime.tictac=function(e,t){var i=t?"convertible-date-full":"convertible-timestamp-full",a=$("[data-"+i+"]");if(a.parent().contents().filter(function(){return 3===this.nodeType}).remove(),"undefined"!=typeof moment){if(t){var n=a.data(i);if(n){var s=new Date(n);a.data(i,s),s.setSeconds(s.getSeconds()+1),a.text(moment(s.toISOString()).format(config_portable_theme_locale_format_full))}}else a.data(i,parseInt(a.data(i))+1),a.text(moment.unix(a.data(i)).format(config_portable_theme_locale_format_full));!e&&setInterval(snippets.datetime.tictac.bind(null,1,t),1e3)}},snippets.datetime.locale=function(){function e(e,a){var n=e.tagName.endsWith((t+i).toUpperCase())?1:0,s=e.outerHTML.indexOf(";1")>-1?1:0,o=e.outerHTML.indexOf(";2")>-1?1:0,r=e.outerHTML.indexOf(";-1")>-1?1:0,l=$(e).text(),_=n?l.split(";")[0]:l,c=config_portable_theme_locale_format_short,d=config_portable_theme_locale_format_long,p=moment.unix(_).format("l"),p=p.indexOf("/")>-1?"/":p.indexOf("-")>-1?"-":".",h=moment.unix(_).format("LT"),u=o?moment.unix(_).format("YYYY["+p+"]MM["+p+"]DD")+" "+h:moment.unix(_).format(s?d?d:"LL":c?c:"L");if(r){var f=moment(_).fromNow();h=f,u=f}var g={sameElse:"LLL"};if(a)return n?u:h;$(e).replaceWith(n?"-1?' data-placement="auto top" data-container="body" data-toggle="tooltip" data-title="'+(r?moment(_).calendar(null,g):moment.unix(_).fromNow())+'"':"")+">"+u+"":h)}var t="-",i="d",a="x"+t+"md"+t;$.each($(a+i).add(a+"t").add($("td:contains("+(a+i)+")").last()).add($("td:contains("+a+"t)").last()).add("option:contains("+(a+i)+")").add("option:contains("+a+"t)"),function(i,n){if(n.tagName.startsWith(a.toUpperCase()))e(n,0);else{var s=$(n).text(),o=Convert.htmlUnEscape(s),r="";$.each($(o),function(i,a){$(a)[0].tagName&&$(a)[0].tagName.startsWith(("x"+t+"md").toUpperCase())&&(r+=e($(a)[0],1)+" ")}).promise().done(function(){$(n).text(r)})}})},snippets.ajax=function(){$(document).ajaxStop(function(){setTimeout(function(){0===v___available_session&&session.reauthenticate.start()},300)}).ajaxSuccess(function(){v___theme_ajax_error=0,"object"==typeof stats&&stats.general.error&&0===get_access_level()&&settings_sysinfo_real_time_status&&(stats.general.enable(),stats.general.error=0)}).ajaxError(function(e,t){"canceled"!==t.statusText&&connection_error(t,0)}),$.ajaxSetup({complete:function(e,t){(Test.strContains(e.responseText,v___page_signin_form)||e&&("auth-required=1"===e.getResponseHeader("Auth-type")||e.responseText&&e.responseText.indexOf("reset-fonts-grids-base")>-1&&e.responseText.indexOf("window.top.location = window.location;")>-1))&&session.reauthenticate.start()},beforeSend:function(e,t){t.url=link_type_convert(t.url,1),e.setRequestHeader("X-Requested-From",v___module||v___module_previous),e.setRequestHeader("X-Requested-From-Tab",plugins.navigation.state.module())}})},snippets.pjax=function(){$(document).on("submit","form",function(e){if(void 0!==e.originalEvent&&(v___theme_content_history=0),"true"!=$(this).attr("data-download")){if("_blank"===e.target.target){var t=$(this);return void setTimeout(function(){t.removeAttr("target"),get_pjax_content(v___location_resource)},100)}e.preventDefault(),get_onbeforeunload_status()?get_onbeforeunload_message(e,this):get_pjax_action_submit(e)}}),$(document).on("click","a"+$__theme_default_deselectors,function(e){void 0!==e.originalEvent&&(v___theme_content_history=0),get_onbeforeunload_status()&&$(quirks.active_element()).is("a"+$__theme_event_deselectors)&&(!this.href||this.href&&!this.href.includes("!edit"))?(e.preventDefault(),get_onbeforeunload_message(e,this)):get_pjax_action_click(e,this)}),$(document).on("pjax:error",function(e,t,i,a,n){if("error"===i){var s=$.active;if(s&&($.active=s-1),Test.strContains(n.url,"/csf/index.cgi"))return void theme_reload()}}),$(document).on("pjax:start",function(e,t,i){t&&(get_server_data("loading",1),$("body").addClass("loading-bg")),vars.page_user_inactive=1,vars.requested_page=i.url,"number"==typeof set_server_theme_temp_data_timeout&&clearTimeout(set_server_theme_temp_data_timeout)}),$(document).on("pjax:beforeReplace",function(e,t,i){settings_mail_ui&&uri_parse("directory",i.url).indexOf("/mailboxes")===-1&&uri_parse("directory",i.url).indexOf("/mailbox")>-1&&(!uri_parse("file",i.url)||uri_parse("file",i.url).indexOf("index.cgi")>-1)&&(vars.pjax_replace_contents=0),plugins.navigation.deform(0),pjax.clear.modules(i),i.push===!1&&(Test.strContains(i.url,"/config.cgi?")||Test.strContains(i.url,"/uconfig.cgi?"))&&t.find(".btn-accordion-filter, .btn-toggle-accordions").remove()}),$(document).on("ready pjax:beforeSend",function(e,t,i){if(1===vars.pjax_cancel)return vars.pjax_cancel=0,!1;if(theme_download_link(i))return!1;if($t_uri_webmail&&settings_mail_ui&&core.moduleAvailable("mailbox")&&("object"==typeof mail?0===$("aside .fancytree-container").length&&mail_load_folders():load.bundle(v___server_extensions_path+"/mail/mail",1,["mail.folders.get()"])),settings_mail_ui&&core.curModule("mailbox")&&(core.curModuleFile("mailbox","")||core.curModuleFile("mailbox","index.cgi"))&&uri_parse("directory",i.url).indexOf("/mailboxes")===-1&&uri_parse("directory",i.url).indexOf("/mailbox")>-1&&(!uri_parse("file",i.url)||uri_parse("file",i.url).indexOf("index.cgi")>-1))return mail_load(i.url),!1;progress.start(),"number"==typeof v___theme_postponed_fetcher&&clearInterval(v___theme_postponed_fetcher);var a=$(e.relatedTarget),n=a.attr("href");n=n?n:i.url.replace(v___location_origin,""),clicked_in_nav_menu=a.parent().is("[data-linked], .favorites-dcontainer, .menu-exclude.ui-sortable-handle")||"object"==typeof i.callback&&"reference"===i.callback[0],clicked_in_nav_menu&&check_bundle(n),"object"==typeof i.callback&&"beforeSend"===i.callback[0]&&(i.callback[3]?setTimeout(function(){window[i.callback[1].apply(this,i.callback[2])]},i.callback[3]):window[i.callback[1].apply(this,i.callback[2])]),v___theme_pjax_call+=1}),$(document).on("pjax:success",function(event,data,status,xhr,options){theme_message_dismiss("ajaxError"),"object"==typeof options.callback&&"success"===options.callback[0]&&(options.callback[3]?setTimeout(function(){"string"==typeof options.callback[1]?eval(options.callback[1]):window[options.callback[1].apply(this,options.callback[2])]},options.callback[3]):"string"==typeof options.callback[1]?eval(options.callback[1]):window[options.callback[1].apply(this,options.callback[2])])}),$(document).on("pjax:complete",function(e,t,i){vars.allow_ui_features=1,v___theme_reload&&theme_reload(),setTimeout(function(){$(".container-fluid-loading").length||progress.end()},10),get_server_data("loading",0,1),$("body").removeClass("loading-bg"),v___theme_connection_triggered_origin=0,"object"==typeof stats&&stats.general.error&&stats.general.enable()}),$(document).on("ready pjax:end",function(e,t){vars.pjax.event.end&&0!==v___available_session&&1!==v___theme_reload&&(void 0!=t&&t.responseText&&t.responseText.includes("data-predownload")||(plugins.navigation.deform(1),get_pjax_event_end(e,t),setTimeout(function(){var e=link_type_convert(location.hash,1).replace("#","");if(e&&e.length>0){var t=$('[name="'+e+'"]');t.length&&t[0].scrollIntoView({duration:200,smooth:!0,direction:"vertical",complete:function(){}})}},200),v___page_container.find(".panel > .panel-body:first").one("click mousedown keypress",function(){vars.page_user_inactive=0}),vars.pjax.post_page_fetch=!0,setTimeout(function(){vars.pjax.post_page_fetch=!1},100)))}),$(document).on("pjax:popstate",function(e){var t=(e.state,"csf"!==v___module&&v___module!==v___module_file_manager&&!core.curModuleFile("webmin","edit_themes.cgi")&&"settings-user.cgi"!==v___location_file);get_pjax_event_end_funcs(0,!t),vars.previous_request=String(),vars.source_request=String()})},snippets.get_goto=function(){v___theme_navigation_active=$(".switch-toggle input:checked").attr("id"),v___theme_navigation_active=v___theme_navigation_active?v___theme_navigation_active.replace("open_",""):get_server_data("product"),setTimeout(function(){var e=function(){$t_uri_virtualmin&&"undefined"==typeof t_uri_get_content&&get_default_virtualmin_content(!1),$t_uri_cloudmin&&"undefined"==typeof t_uri_get_content&&get_default_cloudmin_content(!1),$t_uri_virtualmin||$t_uri_cloudmin||"undefined"!=typeof t_uri_get_content||get_default_content(),t_uri_get_content=1};$.when(get_server_theme_temp_data("goto",0,e)).then(function(t,i,a){if(!a.responseText||get_server_data("initial-wizard")||unbuffered_header_processor_allow(a.responseText))e();else{if(Test.strContains(a.responseText,v___module_file_manager+"/config.cgi"))return void get_pjax_content(v___location_prefix+"/"+v___module_file_manager);if(Test.strContains(a.responseText,"//")&&URI(a.responseText).hostname()!==URI(location.href).hostname()||Test.strContains(a.responseText,"/servers/link.cgi/")||Test.strContains(a.responseText,"settings-user.cgi")||Test.strContains(a.responseText,"/xerror")||"/"===a.responseText||a.responseText==="/?"+$__theme_navigation)return void get_pjax_content(v___location_prefix+"/sysinfo.cgi");if(Test.strContains(a.responseText,"virtual-server")){var n=URI.parseQuery(URI(a.responseText).query()).dom,s=$('select[name="dom"]').val(),o=n?n:s;plugins.navigation.switch.set("virtualmin"),(!s||n!=s)&&plugins.navigation.get.virtualmin(!!o&&o)}else if(Test.strContains(a.responseText,"server-manager")){var r=URI.parseQuery(URI(a.responseText).query()).id,l=r?r:$('select[name="sid"]').val();plugins.navigation.switch.set("cloudmin"),plugins.navigation.get.cloudmin(!!l&&l)}else $t_uri_webmin||2==v___user_level||3==v___user_level||(plugins.navigation.switch.set("webmin"),plugins.navigation.get.webmin("webmin")),3==v___user_level&&!$t_uri_webmail&&Test.strContains(a.responseText,"mailbox")&&core.moduleAvailable("mailbox")?(plugins.navigation.switch.set("webmail"),setTimeout(function(){plugins.navigation.get.webmin("webmail")},10)):3!=v___user_level||$t_uri_usermin||Test.strContains(a.responseText,"mailbox")||(plugins.navigation.switch.set("usermin"),setTimeout(function(){plugins.navigation.get.webmin("webmin")},10));check_bundle(a.responseText),get_pjax_content(a.responseText,["success","v___theme_content_history = 1"])}})},20),$.each(theme_config("get_options"),function(e,t){localStorage.setItem(v___server_hostname+"-"+t,window[t])}),setTimeout(function(){plugins.slider.update.favorites()},300)},snippets.tooltips=function(e){if(e){$(".__page").tooltip("destroy").tooltip({selector:'[data-toggle="tooltip"]:not([data-skip]), [data-toggle="virtualmin-license"], .panel-body td a:not([data-skip]), .icons-container',sanitize:!1,placement:"auto "+($(".gl-icon-container").length||$("[data-fbplacement]").length?"bottom":"top"),trigger:"hover",html:!0,delay:{show:600,hide:30}})}else $("aside").tooltip({selector:'li[data-toggle="tooltip"], li > a[data-toggle="tooltip"].menu-exclude-link, label[data-toggle="tooltip"]',sanitize:!1,container:"body",html:!0,delay:{show:600,hide:30}})},snippets.help_popup=function(){$("body").on("click",".help_popup",function(e){e.stopPropagation(),e.preventDefault();var t=$(this),i=$(this).attr("href"),a=$(this).parent();a.append(''),$.ajax({type:"POST",url:t.attr("href").indexOf("showpass.cgi")>-1?v___location_directory_trail_slashed+t.attr("href"):t.attr("href"),data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);a.find("._tmp_help_content").html(e.replace(/<(script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"")),$help_title=a.find("._tmp_help_content .ui_subheading").first().text(),$help_body=a.find("._tmp_help_content title").remove(),$help_body=a.find("._tmp_help_content h3.ui_subheading").remove(),$help_body=a.find("._tmp_help_content h3").addClass("h3_help"),$help_body=a.find("._tmp_help_content hr").remove();var n=a.find("._tmp_help_content a");void 0!==n.attr("href")&&$.each(n,function(){var e=$(this).attr("href");e.startsWith("http")?$help_body=a.find("._tmp_help_content a").attr("target","_blank").css("text-decoration","none").css("font-style","italic"):($("body").undelegate('a[href="'+e+'"]',"click"),$("body").one("click",'a[href="'+e+'"]',function(a){if($(a.target).is($('a[href="'+e+'"]'))){a.preventDefault();var n=Convert.pathnamePopLast(t.attr("href"))+"/"+e;$('a[href="'+i+'"].help_popup').attr("data-initial",i).attr("data-substituted",n),$('a[href="'+i+'"].help_popup').attr("href",n),t.trigger("click")}}))}),$help_body=a.find("._tmp_help_content").html(),a.find("._tmp_help_content").remove();var s='',o=t.attr("href").indexOf("showpass.cgi")>-1,r=t.attr("href").indexOf("/locale")>-1;o&&(s=""),t.popover({html:!0,sanitize:!1,container:".container-fluid",template:'',title:function(){return s+$help_title},content:function(){return $help_body},placement:"auto right"}),t.popover("show"),t.on("shown.bs.popover",function(){$help_body.indexOf("")>-1&&$(".popover").animate({"max-width":"540px"},300),$("body").find(".popover:visible").addClass("module-help"),$('body[class*="'+v___module_file_manager+'"]').find(".popover:visible").addClass("file-manager-help"),setTimeout(function(){$.each($(".module-help"),function(){$(this).is(t.next(".module-help"))?($(this).animate({opacity:1},600),popover_visibility_position($(this))):$(".module-help").length>1?$(this).css("opacity",.85):$(this).css("opacity",1)})},100)}),t.on("hidden.bs.popover",function(){$("body").undelegate(":not(tt)","click"),t.attr("data-initial")&&(t.attr("href",t.attr("data-initial")),t.removeAttr("data-initial").removeAttr("data-substituted"))})}})})},snippets.page.render_links=function(e){theme_buttonify(["/syslog-ng/list_destinations.cgi"],".container-fluid .table tbody tr td:last-child",'a[href*="view_log.cgi"]',"btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1",""),theme_buttonify(["/virtual-server/edit_newmysqls.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1","fa-cog"),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="delete.cgi"]',"btn btn-danger btn-xxs vertical-align-top margined-top-1 ---forced","fa-times-circle","","","","|"),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="//"]',"btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced",""),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="help.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced",""),theme_buttonify(["/webalizer/","/webalizer/index.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1",0),theme_buttonify(["/cpan/edit_mod.cgi"],".container-fluid .table tbody tr td","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-3 margined-right--1 btn-dnwo ---forced","","","","","|"),theme_buttonify(["/forward/index.cgi","/forward/"],".container-fluid",'.panel-body > a:first[href*="simple"]',"btn btn-default _btn-links-top btn-xs vertical-align-top margined-top-1 margined-left-3",0,"","","","|"),theme_buttonify(["/forward/index.cgi","/forward/"],".container-fluid",".panel-body > span[data-unckecked]","btn btn-info _btn-links-top btn-xs vertical-align-top margined-top-1 margined-left-3",0,"","","","|"),theme_buttonify(["/acl/list_sessions.cgi"],".container-fluid table td[data-td-e]",'a[href*="webminlog/"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 ---forced",0,"","","","|"),theme_buttonify(["/acl/list_sessions.cgi"],".container-fluid table td[data-td-e]",'a[href*="delete_session.cgi"]',"btn btn-danger btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced","fa-unplugged"),theme_buttonify(["/sysinfo.cgi","/virtual-server/edit_newchangelog.cgi","/server-manager/edit_newchangelog.cgi"],".container-fluid #newfeatures-virtual-server-1-collapse dt, .container-fluid #newfeatures-server-manager-1-collapse dt, .container-fluid .table td dt","a","btn btn-link btn-link-bordered btn-xxs btn-dnwo f__lnk_t_btn-el margined-left-3 vertical-align-top margined-top-1","fa-eye","|",""),theme_buttonify(["/virtual-server/","/virtual-server/index.cgi","/virtual-server/edit_plan.cgi","/virtual-server/search.cgi"],".container-fluid form table tbody td",'a[href*="list_users.cgi?"], a[href*="list_aliases.cgi?"]',"btn btn-link btn-link-bordered btn-xxs btn-hover-hide vertical-align-top margined-top-1",0,"(~)"," ~ ",""),theme_buttonify(["/server-manager/","/server-manager/index.cgi"],".container-fluid form table tbody td",'a[href*="mass_update_form.cgi?"]',"btn btn-link btn-link-bordered btn-xxs btn-transparent btn-link-bordered vertical-align-top margined-left-3 margined-top-1",0,"","","","-"),theme_buttonify(["/quota/","/quota/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="activate.cgi"][href*="&active=3"]',"btn btn-warning btn-xxs vertical-align-top margined-top-1","fa-ban"),theme_buttonify(["/quota/","/quota/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="activate.cgi"][href*="&active=0"]',"btn btn-success btn-xxs vertical-align-top margined-top-1","fa-check-circle-o"),theme_buttonify(["/virtualmin-google-analytics/","/virtualmin-google-analytics/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="edit.cgi"]',"btn btn-warning btn-xxs vertical-align-top margined-top-1","fa-pencil-square"),theme_buttonify(["/apache/","/apache/index.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1","fa-external-link"),theme_buttonify(["/ldap-server/edit_schema.cgi"],".container-fluid table tr.ui_checked_columns td",'a[href*="view_sfile.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 ---forced",0,"","","","|"),theme_buttonify(["/ldap-server/edit_schema.cgi"],".container-fluid table tr.ui_checked_columns td",'a[href*="edit_sfile.cgi"]',"btn btn-warning btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced","fa-pencil-square-o");var t=$(".container-fluid .ui_links_row");if((core.curModule("firewall",1)||core.curModule("firewall6",1))&&t.first().find(".ui_link_empty").addClass("btn-warning").removeClass("btn-success"),($('body[class*="status"]').length&&"edit_mon.cgi"==v___location_file||v___location_path==v___location_prefix+"/virtual-server/list_sched.cgi"||v___location_path==v___location_prefix+"/software/list_pack.cgi"||v___location_path==v___location_prefix+"/mailboxes/view_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/view_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/list_folders.cgi"||v___location_path==v___location_prefix+"/phpini/"||v___location_path==v___location_prefix+"/phpini/index.cgi"||v___location_path==v___location_prefix+"/fsdump/"||v___location_path==v___location_prefix+"/fsdump/index.cgi"||v___location_path==v___location_prefix+"/fdisk/"||v___location_path==v___location_prefix+"/fdisk/index.cgi"||v___location_path==v___location_prefix+"/virtualmin-awstats/"||v___location_path==v___location_prefix+"/virtualmin-awstats/index.cgi"||v___location_path==v___location_prefix+"/syslog/"||v___location_path==v___location_prefix+"/syslog/index.cgi")&&($.each($('tr td:last-child > .ui_links_row, tr td:last-child:contains("|")'),function(){var e=$(this).parent(),t="ui_link btn-inverse btn-tiny>";v___location_path==v___location_prefix+"/virtual-server/list_sched.cgi"&&(e.find('a[href^="backup_form.cgi"]').html(e.find('a[href^="backup_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="restore_form.cgi"]').html(e.find('a[href^="restore_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="backuplog.cgi"]').html(e.find('a[href^="backuplog.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/phpini/"&&v___location_path!=v___location_prefix+"/phpini/index.cgi"||(e.find('a[href^="list_ini.cgi"]').html(e.find('a[href^="list_ini.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="edit_manual.cgi"]').html(e.find('a[href^="edit_manual.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs f__lnk_t_btn-el").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/fdisk/"&&v___location_path!=v___location_prefix+"/fdisk/index.cgi"||(e.find('a[href^="edit_hdparm.cgi"]').html(e.find('a[href^="edit_hdparm.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t),e.find('a[href*="smart-status/index.cgi"]').html(e.find('a[href*="smart-status/index.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t),e.find('a[href^="blink.cgi"]').html(e.find('a[href^="blink.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t)),v___location_path==v___location_prefix+"/mailbox/list_folders.cgi"&&(e.find('a[href^="index.cgi"]').html(e.find('a[href^="index.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href^="edit_auto.cgi"]').html(e.find('a[href^="edit_auto.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href^="copy_form.cgi"]').html(e.find('a[href^="copy_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/mailboxes/view_mail.cgi"&&v___location_path!=v___location_prefix+"/mailbox/view_mail.cgi"||(e.find('a[href^="detach.cgi"]:not([href*="&save=1"]):not([target="_blank"])').html(e.find('a[href^="detach.cgi"]:not([href*="&save=1"]):not([target="_blank"])').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href*="detach.cgi"][target="_blank"]').html(e.find('a[href*="detach.cgi"][target="_blank"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs").removeClass("heighter-34").removeClass(t).prepend('  '),e.find('a[href*="&save=1"]:not([target="_blank"])').html(e.find('a[href*="&save=1"]:not([target="_blank"])').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs").removeClass("heighter-34").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/virtualmin-awstats/"&&v___location_path!=v___location_prefix+"/virtualmin-awstats/index.cgi"||(e.find('a[href^="view.cgi"]').html(e.find('a[href^="view.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t).prepend('  '),e.find('a[href^="config.cgi"]').html(e.find('a[href^="config.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t).prepend('  '))}).promise().done(function(){$(this).is(".ui_links_row")?$(this).contents().unwrap():$('tr td:last-child:contains("|")').replaceText(/\s*/gi,"").replaceText(/\|/gi,"")}),$('body[class*="status"]').length&&"edit_mon.cgi"==v___location_file?($('a[href*="edit_mon.cgi?id"]').addClass("ui_link_replaced btn btn-default btn-xxs").removeClass("heighter-34").removeClass("ui_link"),$('a[href*="edit_mon.cgi?id"]').last().css("margin-left","-1px"),$('tr td:last-child:contains("|")').replaceText(/\|/gi,"")):$('tr td:last-child:contains("|")').contents().filter(function(){return 3==this.nodeType}).remove(),v___location_path!=v___location_prefix+"/fdisk/"&&v___location_path!=v___location_prefix+"/fdisk/index.cgi"||$("body").find('a[href^="blink.cgi"]:not(.ui_link_replaced)').html($("body").find('a[href^="blink.cgi"]:not(.ui_link_replaced)').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link"),v___location_path!=v___location_prefix+"/fsdump/"&&v___location_path!=v___location_prefix+"/fsdump/index.cgi"||$.each($("tr td:last-child"),function(){$(this).find('a[href^="backup.cgi"]').html($(this).find('a[href^="backup.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link").prepend('  '),$(this).find('a[href^="kill.cgi"]').html($(this).find('a[href^="kill.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-danger btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link").prepend('  ')}),v___location_path!=v___location_prefix+"/syslog/"&&v___location_path!=v___location_prefix+"/syslog/index.cgi"||$.each($("tr td:last-child"),function(){ +v___location_path==v___location_prefix+"/backup-config/"||v___location_path==v___location_prefix+"/backup-config/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):v___location_path==v___location_prefix+"/mount/"||v___location_path==v___location_prefix+"/mount/index.cgi"||v___location_path==v___location_prefix+"/quota/"||v___location_path==v___location_prefix+"/quota/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):v___location_path==v___location_prefix+"/fsdump/"||v___location_path==v___location_prefix+"/fsdump/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").next("td").find("label").find("tt").find("tt").text()):v___location_path==v___location_prefix+"/proc/"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_user.cgi"||v___location_path==v___location_prefix+"/proc/index_size.cgi"||v___location_path==v___location_prefix+"/proc/index_cpu.cgi"||v___location_path==v___location_prefix+"/proc/index_tree.cgi"||v___location_path==v___location_prefix+"/proc/index_search.cgi"?v___location_path==v___location_prefix+"/proc/index_size.cgi"||v___location_path==v___location_prefix+"/proc/index_cpu.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").text()):v___location_path==v___location_prefix+"/proc/index_search.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").text()):$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" — "+$.trim($(this).parents("td").next("td").next("td").next("td").text()):v___location_path==v___location_prefix+"/useradmin/"||v___location_path==v___location_prefix+"/useradmin/index.cgi"?$description=$.trim($(this).parents("td").next("td").find("label").text())+" — "+$(this).text()+":"+$.trim($(this).parents("td").next("td").next("td").find("label").text())+" - "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").find("label").text())+", "+$.trim($(this).parents("td").next("td").next("td").next("td").next("td").next("td").find("label").text()):v___location_path==v___location_prefix+"/mailboxes/list_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/"||v___location_path==v___location_prefix+"/mailbox/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").next("td").find("label").text())+" — "+$.trim($(this).parents("td").next("td").find("label").text())+" ["+$.trim($(this).parents("td").next("td").next("td").find("label").text())+"]":v___location_path==v___location_prefix+"/cpan/"||v___location_path==v___location_prefix+"/cpan/index.cgi"?$description=$.trim($(this).parents("td").next("td").next("td").find("label").text()):v___location_path==v___location_prefix+"/fdisk/"||v___location_path==v___location_prefix+"/fdisk/index.cgi"?$description=$.trim($(this).parent("td").next("td[data-td-e]").text())+" - "+$.trim($(this).parent("td").next("td[data-td-e]").next("td[data-td-e]").text()):$description=$.trim($(this).parent("td").next("td[data-td-e]").text()),$description?$_description=!0:$_description=!1;var e=$.trim($(this).text());if(core.curModule("bind8")){var t=$(this).parents("form").prev("br").prev("b").find("tt");if(t.length){var a=t.text();!$(this).parent(".ui_links_row").length&&a&&(e=e+" ("+a+")")}}_[("/"==$(this).attr("href").substring(0,1)?"":"/")+v___location_directory_unslashed_trail_slashed+$(this).attr("href")]=e+($_description?" (":"")+$description+($_description?")":"")}});var d=$.map(_,function(e,t){if("undefined"!=t)return{value:e,url:t,data:{category:get_module_title()}}}),c={};$.each($(s+' > ul.sub:not([id^="global_"]) > '+s+' > a, ul.navigation > [data-linked]:not([data-after]) > a:not([href*="virtual-server/index.cgi"]):not([href*="server-manager/index.cgi"])'),function(e,t){c[("/"==$(this).attr("href").substring(0,1)?"":"/")+$(this).attr("href")]=$.trim($(this).text())}),$(s+' > a[target="page"]:not([data-href="/acl/edit_user.cgi"],[data-href="/virtual-server/index.cgi"],[data-href="/sysinfo.cgi"],[data-href="/virtual-server/pro/history.cgi"], [data-href="/mailbox/list_folders.cgi"], [data-href="/mailbox/list_ifolders.cgi"], [data-href="/mailbox/list_addresses.cgi"], [data-href="/filter/edit_forward.cgi"], [data-href="/filter/edit_auto.cgi"], [data-href="/filter/edit_auto.cgi"], [data-href="/filter/"], [data-href="/mailbox/edit_sig.cgi"])').each(function(e,t){$t_uri_usermin||h()||(c[$(this).attr("data-href")]=$.trim($(this).text()))});var p=$.map(c,function(e,t){if("undefined"!=t&&!Test.strContains(t,"/shell")&&!Test.strContains(t,"shell=1"))return{value:e,url:t,data:{category:$("aside .select2-selection__rendered").text()?''+$("aside .select2-selection__rendered").clone().children().remove().end().text()+"":C()}}}),g={};$("aside select option").each(function(){g[$(this).val()+":::"+$(this).parent("select").attr("name")]=$.trim($(this).text())});var f=$.map(g,function(e,t){if("undefined"!=t)return{value:e,url:t,data:{category:$("aside select").data("autocomplete-title")}}}),u=f.concat(d).concat(p).concat(o);$(".form-control.sidebar-search").on("keydown",function(e){34!=e.keyCode&&33!=e.keyCode&&20!=e.keyCode&&17!=e.keyCode&&16!=e.keyCode&&9!=e.keyCode||(e.preventDefault(),e.stopPropagation())}),$(".form-control.sidebar-search").autocomplete({lookup:u,onSelect:function(e,t){var n=$.Autocomplete.externalEvent;if(!$.isEmptyObject(n)){var s=n.keyCode?n.keyCode:n.which;if(n.ctrlKey||n.shiftKey||n.altKey||n.metaKey||20===s||32===s||33===s||34===s||35===s||36===s||37===s||38===s||39===s||40===s||45===s||46===s||112===s||113===s||114===s||115===s||116===s||117===s||118===s||119===s||120===s||121===s||122===s||123===s||144===s||145===s)return}h()===!0&&$t_uri_dashboard&&2!=get_access_level()&&4!=get_access_level()&&v("webmin"),$(this).val("").blur(),r();var o=i(e.url);if("/"==e.url.substring(0,1)||o){if(e.url&&(o||e.url.includes("virtual-server/pro/history.cgi")||e.url.includes("server-manager/history.cgi")||e.url.includes("server-manager/one_history.cgi")))return void theme_open_new_tab(e.url,1);var _=e.url.indexOf(v___location_prefix)>-1?e.url:v___location_prefix+e.url;if(Test.strContains(v___location_prefix,v___target_servers_index)&&_&&_.endsWith("/servers/"))return;get_onbeforeunload_status()?(t&&t.preventDefault(),get_onbeforeunload_message([],{href:_})):get_pjax_content(_,["reference"])}else if(e.url&&e.url.indexOf(":::")>-1){var d=e.url.split(":::")[0];get_onbeforeunload_status()?get_onbeforeunload_message(p,this,{"plugins.navigation.select.set":[d,1]}):(a(),l(d,1))}},groupBy:"category"})}},c=function(e){if(!get_onbeforeunload_status()){var e=void 0===e||e==-1||""==e?$("aside select").val():e,t=$t_uri_virtualmin?"virtualmin":$t_uri_cloudmin?"cloudmin":$t_uri_usermin?"usermin":$t_uri_webmin?"webmin":"mail";"webmin"==t?(v("webmin"),x("webmin")):"virtualmin"==t?(v("virtualmin"),y(e)):"cloudmin"==t?(v("cloudmin"),A(e)):"usermin"==t?(v("usermin"),x("usermin")):"mail"==t&&(v("webmail"),x("webmail"))}},p=function(e){var t=$("aside select"),a=t.data("select2");e||(vars.navigation_select=a&&"undefined"!=a&&!e&&t.select2("isOpen")),e?$.each($("aside").find("forms"),function(){$(this).replaceTagName("form")}).promise().done(function(){o(vars.navigation_select)}):(a&&t.select2("destroy"),$.each($("aside").find("form"),function(){$(this).replaceTagName("forms")}))},g=function(){if("undefined"==typeof settings_leftmenu_width_initial&&(settings_leftmenu_width_initial=settings_leftmenu_width),matchMedia("(max-width: 1080px)").matches||"1"==$("html").attr("data-navigation-collapsed"))settings_leftmenu_width=260,page_adjust(settings_leftmenu_width,0);else{if(1===v___initial_load)return;settings_leftmenu_width=settings_leftmenu_width_initial,page_adjust(settings_leftmenu_width,settings_leftmenu_width)}},h=function(){return"1"==f("dashboard")},f=function(e){return e=e?'[id="open_'+e+'"]':String(),$(".switch-toggle input"+e).length},u=function(){v("dashboard"),e(),get_pjax_content(v___location_prefix+"/sysinfo.cgi")},m=function(){Test.string(v___theme_navigation_active)&&v(v___theme_navigation_active)},v=function(e){get_onbeforeunload_status()||($('.switch-toggle input:not([id="open_'+e+'"])').each(function(){$(this).removeAttr("checked")}).promise().done(function(){$("#open_"+e).length?$("#open_"+e).prop("checked",!0):$('.dynamic[name="product-switcher"]').first().prop("checked",!0)}),S())},x=function(n){get_onbeforeunload_status()||(a(),v("webmail"==n?"webmail":get_server_data("product")),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type="+("webmail"==n?"webmail":"webmin"),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="webmail"==n?"webmail":get_server_data("product"),$("body ul.navigation").html(a),i(),!get_server_data("loading")&&t(),"webmail"===n&&settings_mail_ui&&("object"==typeof mail?mail.folders.get():load.bundle(v___server_extensions_path+"/mail/mail",1,["mail.folders.get()"]))}}),k())},y=function(n){get_onbeforeunload_status()||(a(),v("virtualmin"),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type=virtualmin"+(n?"&dom="+n:settings_right_virtualmin_default?"&dom="+settings_right_virtualmin_default:""),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="virtualmin",$("body ul.navigation").html(a),i(),!get_server_data("loading")&&t()}}),k())},A=function(n){get_onbeforeunload_status()||(a(),v("cloudmin"),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-navigation=1&xhr-navigation-type=cloudmin"+(n||0===n?"&sid="+n:settings_right_cloudmin_default?"&sid="+settings_right_cloudmin_default:""),data:!1,dataType:"text",success:function(a){if(Test.strContains(a,v___page_signin_form))return v___available_session=0,i(),void e();v___theme_navigation_active="cloudmin",$("body ul.navigation").html(a),plugins.shell.link(),i(),!get_server_data("loading")&&t()}}),k())},k=function(){get_onbeforeunload_status()||$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-buttons=1&xhr-buttons-type="+($t_uri_virtualmin||$t_uri_cloudmin?1:0),data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);$("body ul.user-links").html(e),plugins.shell.link()}})},C=function(){return $t_uri_webmin?theme_language("theme_xhred_titles_wm"):$t_uri_usermin?theme_language("theme_xhred_titles_um"):$t_uri_virtualmin?theme_language("theme_xhred_titles_vm"):$t_uri_cloudmin?theme_language("theme_xhred_titles_cm"):$t_uri_webmail?theme_language("theme_xhred_titles_mail"):$t_uri_dashboard?theme_language("theme_xhred_titles_dashboard"):void 0},w=function(e,t){return $t_uri_webmin?"webmin":$t_uri_usermin?"usermin":$t_uri_dashboard?"dashboard":$t_uri_virtualmin?t?"virtualmin":e?"virtualserver":"virtual-server":$t_uri_cloudmin?t?"cloudmin":e?"servermanager":"server-manager":$t_uri_webmail?"mailbox":void 0},S=function(){$t_uri_webmin=$('.switch-toggle input[id="open_webmin"]:checked').length?1:0,$t_uri_usermin=$('.switch-toggle input[id="open_usermin"]:checked').length?1:0,$t_uri_virtualmin=$('.switch-toggle input[id="open_virtualmin"]:checked').length?1:0,$t_uri_cloudmin=$('.switch-toggle input[id="open_cloudmin"]:checked').length?1:0,$t_uri_webmail=$('.switch-toggle input[id="open_webmail"]:checked').length?1:0,$t_uri_dashboard=$('.switch-toggle input[id="open_dashboard"]:checked').length?1:0};return{reset:e,select:{set:l,back:_,load:o},detect:t,load:{start:a,stop:i},collapse:r,reload:c,deform:p,lock:g,switch:{dashboard:{get:h,set:u},available:f,set:v,reset:m},get:{webmin:x,virtualmin:y,cloudmin:A},intersect:{virtualmin:function(e){var e="object"==typeof e?e.attr("href"):e,t=URI.parseQuery(URI(e).query()).dom||URI.parseQuery(URI(e).query()).gparent,a=$('select[name="dom"]'),i=a.val();t&&t!=i&&y(t)},cloudmin:function(e){var e="object"==typeof e?e.attr("href"):e,t=URI.parseQuery(URI(e).query()).id,t=t?t:URI.parseQuery(URI(e).query()).d,a=$('select[name="sid"]'),i=a.val();t&&t!=i&&A(t)}},state:{title:C,module:w,update:S,loading:n}}}(),plugins.messenger=function(){var e=function(e,t,a,i,n,s){var r=void 0===i?1:i,o=void 0===n||n;if(s=void 0===s?"":s,"hide-all"===e)return void Messenger().hideAll();if($.isArray(e)&&(e=' '+e[1]),$.isArray(s)){var l=s;s="messenger-fixed ",s+="messenger-on-"+l.join(" messenger-on-")}else s=s.length?"messenger-fixed messenger-on-"+s:"messenger-fixed messenger-on-bottom";"function"==typeof Messenger&&(Messenger.options={extraClasses:s,theme:"air"},window["Messenger_"+r]=Messenger().post({message:e,extraClasses:s,hideAfter:t,showCloseButton:o,type:a,id:r}))};return document.addEventListener("DOMContentLoaded",function(){(function(){if("function"==typeof Messenger.Message){var e,t,a,i={}.hasOwnProperty,n=function(e,t){function a(){this.constructor=e}for(var n in t)i.call(t,n)&&(e[n]=t[n]);return a.prototype=t.prototype,e.prototype=new a,e.__super__=t.prototype,e};e=jQuery,a='
\n \n \n \n \n \n \n
',t=function(t){function i(){return i.__super__.constructor.apply(this,arguments)}return n(i,t),i.prototype.template=function(t){var n;return n=i.__super__.template.apply(this,arguments),n.append(e(a)),n},i}(Messenger.Message),Messenger.themes.air={Message:t},Messenger.options={extraClasses:"messenger-fixed messenger-on-bottom",theme:"air"}}}).call(this)}),{post:e}}(),plugins.upload=function(e){e.removeAttr("onsubmit"),e.on("submit.fm",function(e){e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation();var t=moment().unix()+""+parseInt(1e5*Math.random()),a=$(this),i=a.find(".ui_form_end_submit"),n=a.find('input[type="file"]')[0],s=n.files.length,r=a.find('input[name="dir"]').val(),o=$(n.files).map(function(e,t){return t.name}).get(),l=o.join("\n"),_=function(){theme_restore_buttons_class(),$.fn.bootstrapFileInputReset(a),despinnerfy_buttons(0,i),i.addClass("disabled")},d=function(){s>1?plugins.messenger.post(''+theme_language("theme_xhred_upload_successful").replace("$1",""+s+"").replace("$2","`"+r+"`").replace("'+theme_language("theme_xhred_upload_successful_single").replace("$1",""+s+"").replace("$2","`"+r+"`").replace("'+theme_language("theme_xhred_global_error")+": "+a.replace(/\s:\s/g," — "),15,"error","uploadError_"+t,0,["top","right"]),1):0};spinnerfy_buttons(i),window["progress_id_ref_"+t]=$.ajax({type:"POST",url:"upload.cgi?id="+t,processData:!1,contentType:!1,data:new FormData(a[0]),complete:function(e){_(),c(e)||200===e.status&&d()},error:function(){$("[data-progress-id="+t+"] .bottom_progress_cancel").trigger("click")}}),theme_message_dismiss("upload_error");var p=1;window["progress_id_ref_"+t+"_tracker"]=$.ajax({xhr:function(){var e=new window.XMLHttpRequest;return e.addEventListener("progress",function(e){var a=e.target.responseText,i=regex.matches(a,/.file\.value\s+=\s+"(.*)";/g,0,1),n=regex.matches(a,/.size\.value\s+=\s+"(.*)";/g,0,1),s=regex.matches(a,/.pc\.value\s+=\s+"(.*)";/g,0,1);if(i&&n&&s){p&&(p=0,_());var s=parseInt((s.match(/|/g)||[]).length/50*100);s>100&&(s=100),progress_percent.control(t,"success",s,[i,n,s])}if(Test.strContains(a,v___page_signin_form))return v___available_session=0,window["progress_id_ref_"+t].abort(),void window["progress_id_ref_"+t+"_tracker"].abort()},!1),e},type:a.attr("method"),url:v___location_prefix+"/uptracker.cgi?id="+t+"&uid="+(0===get_access_level()||1===get_access_level()?"":get_server_data("user-id")),complete:function(e){p&&(p=0,_()),theme_message_exists("uploadError_"+t)||200===e.status&&d()}})})};const snippets={};snippets.datetime={},snippets.page={},snippets.patches={},snippets.initial=function(){plugins.dashboard.reset(),snippets.get_goto()},snippets.form_pre_submitter=function(){$("body").on("click",'button.ui_form_end_submit[type="button"]:not(.disabled)',function(){var e=$(this).next('input[type="submit"].hidden'),t=$(this).parent(".btn-group").next('input[type="submit"].hidden');e.length||(e=t);var i=e.parent(),a=(i.parent("tr").find("form"),e.parents("form"));if(!a.length)return a=e.closest("form"),a.length||(a=i.prev("form")),a.length||(a=i.prev().prev("form")),a.length||(a=i.prev().prev().prev("form")),a.append(a.nextUntil(i)),void $.each(i.find("select, input"),function(){$('').attr({type:"hidden",name:$(this).attr("name")?$(this).attr("name"):$(this).attr("id"),value:$(this).val()}).appendTo(a)}).promise().done(function(){a.submit()});var n=e.attr("name")?e.attr("name"):e.attr("id"),s=$.trim(e.val());$('').attr({type:"hidden",name:n,value:s}).appendTo(a),e.trigger("click")}),$("body").on("click",'.ui_form_end_submit:not(.disabled), .page_footer_submit:not(.disabled):not([href*="javascript:history"])',function(){core.curModule("csf")?spinnerfy_buttons($(this),[2,-29,"small",!1]):spinnerfy_buttons($(this),!1,!1,!1)})},snippets.form_input_tester=function(e){if(e)return $(".btn-group.end_submits:visible button.ui_form_end_submit").hasClass("btn-warning dt-tester-btn");$(document).on("input.tester",'form:not([data-tester="1"]):not(#webmin_search_form)',function(e){if(!vars.pjax.post_page_fetch){var t=$(this);if(1!=t.attr("data-tester")){var i=t.find(".CodeMirror").length,a=$(this).attr("action");if(i&&!core.curModule("init")||(core.curModuleFile("mysql","")||core.curModuleFile("postgresql","")||core.curModuleFile("mysql","index.cgi")||core.curModuleFile("postgresql","index.cgi"))&&$(".ui_grid_table.table-hardcoded").length||core.curModuleFile("bind8","")||core.curModuleFile("bind8","index.cgi")||core.curModuleFile("mailbox","reply_mail.cgi")||core.curModuleFile("virtual-server","wizard.cgi")||core.curModuleFile("virtual-server","list_scripts.cgi")||core.curModuleFile("virtual-server","list_scripts.cgi")||a&&a.includes("edit_tmpl.cgi")||$(".modal.in.mppopup").length)return void t.attr("data-tester",1);var n=$(e.target).is('input[type="checkbox"], input[type="radio"]'),s=$(e.target).parents("tr");if(!(n&&s&&s.length&&s.attr("class")&&s.attr("class").includes("ui_checked"))){theme_restore_buttons_class();var o=t.find(".btn-group.end_submits:visible button.ui_form_end_submit"),r=o.first(),l=String("btn-xclass"),_=1===o.data("click-event");if(r[0]&&r[0].classList){var c=r[0].classList.value.match(/.*(btn-\S+)/);c&&(l=c[1],r.attr("data-class-restore",l))}o&&o.length&&(set_onbeforeunload_status(1),_||(o.data("click-event",1),r.removeClass(l).addClass("btn-warning dt-tester-btn"),t.attr("data-tester",1),o.one("click",function(){o.data("click-event",0),t.attr("data-tester",0),set_onbeforeunload_status(0)}),t.on("keydown",function(e){var t=e.keyCode?e.keyCode:e.which;(13===t&&!$(e.target).is("textarea")||13===t&&e.ctrlKey&&$(e.target).is("textarea"))&&(r.hasClass("btn-warning dt-tester-btn")?(e.preventDefault(),r.trigger("click")):set_onbeforeunload_status(0))})))}}}})},snippets.inject_extra_option=function(e,t,i,a){if("tr/yes:no"===e){var n=$("body"),s=t.parents("form");t.parents("td.col_value").parent("tr").after(' '+a+' ");var o="submit."+i;n.off(o),n.one(o,s,function(){var e=Test.true($("[name="+i+"]:checked").val());window[i]=e,theme_config_store()})}},snippets.datetime.tictac=function(e,t){var i=t?"convertible-date-full":"convertible-timestamp-full",a=$("[data-"+i+"]");if(a.parent().contents().filter(function(){return 3===this.nodeType}).remove(),"undefined"!=typeof moment){if(t){var n=a.data(i);if(n){var s=new Date(n);a.data(i,s),s.setSeconds(s.getSeconds()+1),a.text(moment(s.toISOString()).format(config_portable_theme_locale_format_full))}}else a.data(i,parseInt(a.data(i))+1),a.text(moment.unix(a.data(i)).format(config_portable_theme_locale_format_full));!e&&setInterval(snippets.datetime.tictac.bind(null,1,t),1e3)}},snippets.datetime.locale=function(){function e(e,a){var n=e.tagName.endsWith((t+i).toUpperCase())?1:0,s=e.outerHTML.indexOf(";1")>-1?1:0,o=e.outerHTML.indexOf(";2")>-1?1:0,r=e.outerHTML.indexOf(";-1")>-1?1:0,l=$(e).text(),_=n?l.split(";")[0]:l,c=config_portable_theme_locale_format_short,d=config_portable_theme_locale_format_long,p=moment.unix(_).format("l"),p=p.indexOf("/")>-1?"/":p.indexOf("-")>-1?"-":".",h=moment.unix(_).format("LT"),u=o?moment.unix(_).format("YYYY["+p+"]MM["+p+"]DD")+" "+h:moment.unix(_).format(s?d?d:"LL":c?c:"L");if(r){var f=moment(_).fromNow();h=f,u=f}var g={sameElse:"LLL"};if(a)return n?u:h;$(e).replaceWith(n?"-1?' data-placement="auto top" data-container="body" data-toggle="tooltip" data-title="'+(r?moment(_).calendar(null,g):moment.unix(_).fromNow())+'"':"")+">"+u+"":h)}var t="-",i="d",a="x"+t+"md"+t;$.each($(a+i).add(a+"t").add($("td:contains("+(a+i)+")").last()).add($("td:contains("+a+"t)").last()).add("option:contains("+(a+i)+")").add("option:contains("+a+"t)"),function(i,n){if(n.tagName.startsWith(a.toUpperCase()))e(n,0);else{var s=$(n).text(),o=Convert.htmlUnEscape(s),r="";$.each($(o),function(i,a){$(a)[0].tagName&&$(a)[0].tagName.startsWith(("x"+t+"md").toUpperCase())&&(r+=e($(a)[0],1)+" ")}).promise().done(function(){$(n).text(r)})}})},snippets.ajax=function(){$(document).ajaxStop(function(){setTimeout(function(){0===v___available_session&&session.reauthenticate.start()},300)}).ajaxSuccess(function(){v___theme_ajax_error=0,"object"==typeof stats&&stats.general.error&&0===get_access_level()&&settings_sysinfo_real_time_status&&(stats.general.enable(),stats.general.error=0)}).ajaxError(function(e,t){"canceled"!==t.statusText&&connection_error(t,0)}),$.ajaxSetup({complete:function(e,t){(Test.strContains(e.responseText,v___page_signin_form)||e&&("auth-required=1"===e.getResponseHeader("Auth-type")||e.responseText&&e.responseText.indexOf("reset-fonts-grids-base")>-1&&e.responseText.indexOf("window.top.location = window.location;")>-1))&&session.reauthenticate.start()},beforeSend:function(e,t){t.url=link_type_convert(t.url,1),e.setRequestHeader("X-Requested-From",v___module||v___module_previous),e.setRequestHeader("X-Requested-From-Tab",plugins.navigation.state.module())}})},snippets.pjax=function(){$(document).on("submit","form",function(e){if(void 0!==e.originalEvent&&(v___theme_content_history=0),"true"!=$(this).attr("data-download")){if("_blank"===e.target.target){var t=$(this);return void setTimeout(function(){t.removeAttr("target"),get_pjax_content(v___location_resource)},100)}e.preventDefault(),get_onbeforeunload_status()?get_onbeforeunload_message(e,this):get_pjax_action_submit(e)}}),$(document).on("click","a"+$__theme_default_deselectors,function(e){void 0!==e.originalEvent&&(v___theme_content_history=0),get_onbeforeunload_status()&&$(quirks.active_element()).is("a"+$__theme_event_deselectors)&&(!this.href||this.href&&!this.href.includes("!edit"))?(e.preventDefault(),get_onbeforeunload_message(e,this)):get_pjax_action_click(e,this)}),$(document).on("pjax:error",function(e,t,i,a,n){if("error"===i){var s=$.active;if(s&&($.active=s-1),Test.strContains(n.url,"/csf/index.cgi"))return void theme_reload()}}),$(document).on("pjax:start",function(e,t,i){t&&(get_server_data("loading",1),$("body").addClass("loading-bg")),vars.page_user_inactive=1,vars.requested_page=i.url,"number"==typeof set_server_theme_temp_data_timeout&&clearTimeout(set_server_theme_temp_data_timeout)}),$(document).on("pjax:beforeReplace",function(e,t,i){settings_mail_ui&&uri_parse("directory",i.url).indexOf("/mailboxes")===-1&&uri_parse("directory",i.url).indexOf("/mailbox")>-1&&(!uri_parse("file",i.url)||uri_parse("file",i.url).indexOf("index.cgi")>-1)&&(vars.pjax_replace_contents=0),plugins.navigation.deform(0),pjax.clear.modules(i),i.push===!1&&(Test.strContains(i.url,"/config.cgi?")||Test.strContains(i.url,"/uconfig.cgi?"))&&t.find(".btn-accordion-filter, .btn-toggle-accordions").remove()}),$(document).on("ready pjax:beforeSend",function(e,t,i){if(1===vars.pjax_cancel)return vars.pjax_cancel=0,!1;if(theme_download_link(i))return!1;if($t_uri_webmail&&settings_mail_ui&&core.moduleAvailable("mailbox")&&("object"==typeof mail?0===$("aside .fancytree-container").length&&mail_load_folders():load.bundle(v___server_extensions_path+"/mail/mail",1,["mail.folders.get()"])),settings_mail_ui&&core.curModule("mailbox")&&(core.curModuleFile("mailbox","")||core.curModuleFile("mailbox","index.cgi"))&&uri_parse("directory",i.url).indexOf("/mailboxes")===-1&&uri_parse("directory",i.url).indexOf("/mailbox")>-1&&(!uri_parse("file",i.url)||uri_parse("file",i.url).indexOf("index.cgi")>-1))return mail_load(i.url),!1;progress.start(),"number"==typeof v___theme_postponed_fetcher&&clearInterval(v___theme_postponed_fetcher);var a=$(e.relatedTarget),n=a.attr("href");n=n?n:i.url.replace(v___location_origin,""),clicked_in_nav_menu=a.parent().is("[data-linked], .favorites-dcontainer, .menu-exclude.ui-sortable-handle")||"object"==typeof i.callback&&"reference"===i.callback[0],clicked_in_nav_menu&&check_bundle(n),"object"==typeof i.callback&&"beforeSend"===i.callback[0]&&(i.callback[3]?setTimeout(function(){window[i.callback[1].apply(this,i.callback[2])]},i.callback[3]):window[i.callback[1].apply(this,i.callback[2])]),v___theme_pjax_call+=1}),$(document).on("pjax:success",function(event,data,status,xhr,options){theme_message_dismiss("ajaxError"),"object"==typeof options.callback&&"success"===options.callback[0]&&(options.callback[3]?setTimeout(function(){"string"==typeof options.callback[1]?eval(options.callback[1]):window[options.callback[1].apply(this,options.callback[2])]},options.callback[3]):"string"==typeof options.callback[1]?eval(options.callback[1]):window[options.callback[1].apply(this,options.callback[2])])}),$(document).on("pjax:complete",function(e,t,i){vars.allow_ui_features=1,v___theme_reload&&theme_reload(),setTimeout(function(){$(".container-fluid-loading").length||progress.end()},10),get_server_data("loading",0,1),$("body").removeClass("loading-bg"),v___theme_connection_triggered_origin=0,"object"==typeof stats&&stats.general.error&&stats.general.enable()}),$(document).on("ready pjax:end",function(e,t){vars.pjax.event.end&&0!==v___available_session&&1!==v___theme_reload&&(void 0!=t&&t.responseText&&t.responseText.includes("data-predownload")||(plugins.navigation.deform(1),get_pjax_event_end(e,t),setTimeout(function(){var e=link_type_convert(location.hash,1).replace("#","");if(e&&e.length>0){var t=$('[name="'+e+'"]');t.length&&t[0].scrollIntoView({duration:200,smooth:!0,direction:"vertical",complete:function(){}})}},200),v___page_container.find(".panel > .panel-body:first").one("click mousedown keypress",function(){vars.page_user_inactive=0}),vars.pjax.post_page_fetch=!0,setTimeout(function(){vars.pjax.post_page_fetch=!1},100)))}),$(document).on("pjax:popstate",function(e){var t=(e.state,"csf"!==v___module&&v___module!==v___module_file_manager&&!core.curModuleFile("webmin","edit_themes.cgi")&&"settings-user.cgi"!==v___location_file);get_pjax_event_end_funcs(0,!t),vars.previous_request=String(),vars.source_request=String()})},snippets.get_goto=function(){v___theme_navigation_active=$(".switch-toggle input:checked").attr("id"),v___theme_navigation_active=v___theme_navigation_active?v___theme_navigation_active.replace("open_",""):get_server_data("product"),setTimeout(function(){var e=function(){$t_uri_virtualmin&&"undefined"==typeof t_uri_get_content&&get_default_virtualmin_content(!1),$t_uri_cloudmin&&"undefined"==typeof t_uri_get_content&&get_default_cloudmin_content(!1),$t_uri_virtualmin||$t_uri_cloudmin||"undefined"!=typeof t_uri_get_content||get_default_content(),t_uri_get_content=1};$.when(get_server_theme_temp_data("goto",0,e)).then(function(t,i,a){if(!a.responseText||get_server_data("initial-wizard")||unbuffered_header_processor_allow(a.responseText))e();else{if(Test.strContains(a.responseText,v___module_file_manager+"/config.cgi"))return void get_pjax_content(v___location_prefix+"/"+v___module_file_manager);if(Test.strContains(a.responseText,"//")&&URI(a.responseText).hostname()!==URI(location.href).hostname()||Test.strContains(a.responseText,"/servers/link.cgi/")||Test.strContains(a.responseText,"settings-user.cgi")||Test.strContains(a.responseText,"/xerror")||"/"===a.responseText||a.responseText==="/?"+$__theme_navigation)return void get_pjax_content(v___location_prefix+"/sysinfo.cgi");if(Test.strContains(a.responseText,"virtual-server")){var n=URI.parseQuery(URI(a.responseText).query()).dom,s=$('select[name="dom"]').val(),o=n?n:s;plugins.navigation.switch.set("virtualmin"),(!s||n!=s)&&plugins.navigation.get.virtualmin(!!o&&o)}else if(Test.strContains(a.responseText,"server-manager")){var r=URI.parseQuery(URI(a.responseText).query()).id,l=r?r:$('select[name="sid"]').val();plugins.navigation.switch.set("cloudmin"),plugins.navigation.get.cloudmin(!!l&&l)}else $t_uri_webmin||2==v___user_level||3==v___user_level||(plugins.navigation.switch.set("webmin"),plugins.navigation.get.webmin("webmin")),3==v___user_level&&!$t_uri_webmail&&Test.strContains(a.responseText,"mailbox")&&core.moduleAvailable("mailbox")?(plugins.navigation.switch.set("webmail"),setTimeout(function(){plugins.navigation.get.webmin("webmail")},10)):3!=v___user_level||$t_uri_usermin||Test.strContains(a.responseText,"mailbox")||(plugins.navigation.switch.set("usermin"),setTimeout(function(){plugins.navigation.get.webmin("webmin")},10));check_bundle(a.responseText),get_pjax_content(a.responseText,["success","v___theme_content_history = 1"])}})},20),$.each(theme_config("get_options"),function(e,t){localStorage.setItem(v___server_hostname+"-"+t,window[t])}),setTimeout(function(){plugins.slider.update.favorites()},300)},snippets.tooltips=function(e){if(e){$(".__page").tooltip("destroy").tooltip({selector:'[data-toggle="tooltip"]:not([data-skip]), [data-toggle="virtualmin-license"], .panel-body td a:not([data-skip]), .icons-container',sanitize:!1,placement:"auto "+($(".gl-icon-container").length||$("[data-fbplacement]").length?"bottom":"top"),trigger:"hover",html:!0,delay:{show:600,hide:30}})}else $("aside").tooltip({selector:'li[data-toggle="tooltip"], li > a[data-toggle="tooltip"].menu-exclude-link, label[data-toggle="tooltip"]',sanitize:!1,container:"body",html:!0,delay:{show:600,hide:30}})},snippets.help_popup=function(){$("body").on("click",".help_popup",function(e){e.stopPropagation(),e.preventDefault();var t=$(this),i=$(this).attr("href"),a=$(this).parent();a.append(''),$.ajax({type:"POST",url:t.attr("href").indexOf("showpass.cgi")>-1?v___location_directory_trail_slashed+t.attr("href"):t.attr("href"),data:!1,dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);a.find("._tmp_help_content").html(e.replace(/<(script|link|meta)\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/(script|link|meta)>/gi,"")),$help_title=a.find("._tmp_help_content .ui_subheading").first().text(),$help_body=a.find("._tmp_help_content title").remove(),$help_body=a.find("._tmp_help_content h3.ui_subheading").remove(),$help_body=a.find("._tmp_help_content h3").addClass("h3_help"),$help_body=a.find("._tmp_help_content hr").remove();var n=a.find("._tmp_help_content a");void 0!==n.attr("href")&&$.each(n,function(){var e=$(this).attr("href");e.startsWith("http")?$help_body=a.find("._tmp_help_content a").attr("target","_blank").css("text-decoration","none").css("font-style","italic"):($("body").undelegate('a[href="'+e+'"]',"click"),$("body").one("click",'a[href="'+e+'"]',function(a){if($(a.target).is($('a[href="'+e+'"]'))){a.preventDefault();var n=Convert.pathnamePopLast(t.attr("href"))+"/"+e;$('a[href="'+i+'"].help_popup').attr("data-initial",i).attr("data-substituted",n),$('a[href="'+i+'"].help_popup').attr("href",n),t.trigger("click")}}))}),$help_body=a.find("._tmp_help_content").html(),a.find("._tmp_help_content").remove();var s='',o=t.attr("href").indexOf("showpass.cgi")>-1,r=t.attr("href").indexOf("/locale")>-1;o&&(s=""),t.popover({html:!0,sanitize:!1,container:".container-fluid",template:'',title:function(){return s+$help_title},content:function(){return $help_body},placement:"auto right"}),t.popover("show"),t.on("shown.bs.popover",function(){$help_body.indexOf("")>-1&&$(".popover").animate({"max-width":"540px"},300),$("body").find(".popover:visible").addClass("module-help"),$('body[class*="'+v___module_file_manager+'"]').find(".popover:visible").addClass("file-manager-help"),setTimeout(function(){$.each($(".module-help"),function(){$(this).is(t.next(".module-help"))?($(this).animate({opacity:1},600),popover_visibility_position($(this))):$(".module-help").length>1?$(this).css("opacity",.85):$(this).css("opacity",1)})},100)}),t.on("hidden.bs.popover",function(){$("body").undelegate(":not(tt)","click"),t.attr("data-initial")&&(t.attr("href",t.attr("data-initial")),t.removeAttr("data-initial").removeAttr("data-substituted"))})}})})},snippets.page.render_links=function(e){theme_buttonify(["/syslog-ng/list_destinations.cgi"],".container-fluid .table tbody tr td:last-child",'a[href*="view_log.cgi"]',"btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1",""),theme_buttonify(["/virtual-server/edit_newmysqls.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1","fa-cog"),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="delete.cgi"]',"btn btn-danger btn-xxs vertical-align-top margined-top-1 ---forced","fa-times-circle","","","","|"),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="//"]',"btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced",""),theme_buttonify(["/virtualmin-git/","/virtualmin-git/index.cgi"],".container-fluid table td[data-td-e]",'a[href*="help.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced",""),theme_buttonify(["/webalizer/","/webalizer/index.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1",0),theme_buttonify(["/cpan/edit_mod.cgi"],".container-fluid .table tbody tr td","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-3 margined-right--1 btn-dnwo ---forced","","","","","|"),theme_buttonify(["/forward/index.cgi","/forward/"],".container-fluid",'.panel-body > a:first[href*="simple"]',"btn btn-default _btn-links-top btn-xs vertical-align-top margined-top-1 margined-left-3",0,"","","","|"),theme_buttonify(["/forward/index.cgi","/forward/"],".container-fluid",".panel-body > span[data-unckecked]","btn btn-info _btn-links-top btn-xs vertical-align-top margined-top-1 margined-left-3",0,"","","","|"),theme_buttonify(["/acl/list_sessions.cgi"],".container-fluid table td[data-td-e]",'a[href*="webminlog/"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 ---forced",0,"","","","|"),theme_buttonify(["/acl/list_sessions.cgi"],".container-fluid table td[data-td-e]",'a[href*="delete_session.cgi"]',"btn btn-danger btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced","fa-unplugged"),theme_buttonify(["/sysinfo.cgi","/virtual-server/edit_newchangelog.cgi","/server-manager/edit_newchangelog.cgi"],".container-fluid #newfeatures-virtual-server-1-collapse dt, .container-fluid #newfeatures-server-manager-1-collapse dt, .container-fluid .table td dt","a","btn btn-link btn-link-bordered btn-xxs btn-dnwo f__lnk_t_btn-el margined-left-3 vertical-align-top margined-top-1","fa-eye","|",""),theme_buttonify(["/virtual-server/","/virtual-server/index.cgi","/virtual-server/edit_plan.cgi","/virtual-server/search.cgi"],".container-fluid form table tbody td",'a[href*="list_users.cgi?"], a[href*="list_aliases.cgi?"]',"btn btn-link btn-link-bordered btn-xxs btn-hover-hide vertical-align-top margined-top-1",0,"(~)"," ~ ",""),theme_buttonify(["/server-manager/","/server-manager/index.cgi"],".container-fluid form table tbody td",'a[href*="mass_update_form.cgi?"]',"btn btn-link btn-link-bordered btn-xxs btn-transparent btn-link-bordered vertical-align-top margined-left-3 margined-top-1",0,"","","","-"),theme_buttonify(["/quota/","/quota/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="activate.cgi"][href*="&active=3"]',"btn btn-warning btn-xxs vertical-align-top margined-top-1","fa-ban"),theme_buttonify(["/quota/","/quota/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="activate.cgi"][href*="&active=0"]',"btn btn-success btn-xxs vertical-align-top margined-top-1","fa-check-circle-o"),theme_buttonify(["/virtualmin-google-analytics/","/virtualmin-google-analytics/index.cgi"],".container-fluid .table tbody td[data-td-e]",'a[href*="edit.cgi"]',"btn btn-warning btn-xxs vertical-align-top margined-top-1","fa-pencil-square"),theme_buttonify(["/apache/","/apache/index.cgi"],".container-fluid .table tbody tr td:last-child","a.ui_link","btn btn-transparent btn-link-bordered btn-xxs vertical-align-top margined-top-1","fa-external-link"),theme_buttonify(["/ldap-server/edit_schema.cgi"],".container-fluid table tr.ui_checked_columns td",'a[href*="view_sfile.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 ---forced",0,"","","","|"),theme_buttonify(["/ldap-server/edit_schema.cgi"],".container-fluid table tr.ui_checked_columns td",'a[href*="edit_sfile.cgi"]',"btn btn-warning btn-xxs vertical-align-top margined-left--2 margined-top-1 ---forced","fa-pencil-square-o");var t=$(".container-fluid .ui_links_row");if((core.curModule("firewall",1)||core.curModule("firewall6",1))&&t.first().find(".ui_link_empty").addClass("btn-warning").removeClass("btn-success"),($('body[class*="status"]').length&&"edit_mon.cgi"==v___location_file||v___location_path==v___location_prefix+"/virtual-server/list_sched.cgi"||v___location_path==v___location_prefix+"/software/list_pack.cgi"||v___location_path==v___location_prefix+"/mailboxes/view_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/view_mail.cgi"||v___location_path==v___location_prefix+"/mailbox/list_folders.cgi"||v___location_path==v___location_prefix+"/phpini/"||v___location_path==v___location_prefix+"/phpini/index.cgi"||v___location_path==v___location_prefix+"/fsdump/"||v___location_path==v___location_prefix+"/fsdump/index.cgi"||v___location_path==v___location_prefix+"/fdisk/"||v___location_path==v___location_prefix+"/fdisk/index.cgi"||v___location_path==v___location_prefix+"/virtualmin-awstats/"||v___location_path==v___location_prefix+"/virtualmin-awstats/index.cgi"||v___location_path==v___location_prefix+"/syslog/"||v___location_path==v___location_prefix+"/syslog/index.cgi")&&($.each($('tr td:last-child > .ui_links_row, tr td:last-child:contains("|")'),function(){var e=$(this).parent(),t="ui_link btn-inverse btn-tiny>";v___location_path==v___location_prefix+"/virtual-server/list_sched.cgi"&&(e.find('a[href^="backup_form.cgi"]').html(e.find('a[href^="backup_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="restore_form.cgi"]').html(e.find('a[href^="restore_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="backuplog.cgi"]').html(e.find('a[href^="backuplog.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/phpini/"&&v___location_path!=v___location_prefix+"/phpini/index.cgi"||(e.find('a[href^="list_ini.cgi"]').html(e.find('a[href^="list_ini.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass(t).prepend('  '),e.find('a[href^="edit_manual.cgi"]').html(e.find('a[href^="edit_manual.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs f__lnk_t_btn-el").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/fdisk/"&&v___location_path!=v___location_prefix+"/fdisk/index.cgi"||(e.find('a[href^="edit_hdparm.cgi"]').html(e.find('a[href^="edit_hdparm.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t),e.find('a[href*="smart-status/index.cgi"]').html(e.find('a[href*="smart-status/index.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t),e.find('a[href^="blink.cgi"]').html(e.find('a[href^="blink.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t)),v___location_path==v___location_prefix+"/mailbox/list_folders.cgi"&&(e.find('a[href^="index.cgi"]').html(e.find('a[href^="index.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href^="edit_auto.cgi"]').html(e.find('a[href^="edit_auto.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-info btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href^="copy_form.cgi"]').html(e.find('a[href^="copy_form.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/mailboxes/view_mail.cgi"&&v___location_path!=v___location_prefix+"/mailbox/view_mail.cgi"||(e.find('a[href^="detach.cgi"]:not([href*="&save=1"]):not([target="_blank"])').html(e.find('a[href^="detach.cgi"]:not([href*="&save=1"]):not([target="_blank"])').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs").removeClass("heighter-34").removeClass(t).removeClass(t).prepend('  '),e.find('a[href*="detach.cgi"][target="_blank"]').html(e.find('a[href*="detach.cgi"][target="_blank"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs").removeClass("heighter-34").removeClass(t).prepend('  '),e.find('a[href*="&save=1"]:not([target="_blank"])').html(e.find('a[href*="&save=1"]:not([target="_blank"])').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs").removeClass("heighter-34").removeClass(t).prepend('  ')),v___location_path!=v___location_prefix+"/virtualmin-awstats/"&&v___location_path!=v___location_prefix+"/virtualmin-awstats/index.cgi"||(e.find('a[href^="view.cgi"]').html(e.find('a[href^="view.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t).prepend('  '),e.find('a[href^="config.cgi"]').html(e.find('a[href^="config.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass(t).prepend('  '))}).promise().done(function(){$(this).is(".ui_links_row")?$(this).contents().unwrap():$('tr td:last-child:contains("|")').replaceText(/\s*/gi,"").replaceText(/\|/gi,"")}),$('body[class*="status"]').length&&"edit_mon.cgi"==v___location_file?($('a[href*="edit_mon.cgi?id"]').addClass("ui_link_replaced btn btn-default btn-xxs").removeClass("heighter-34").removeClass("ui_link"),$('a[href*="edit_mon.cgi?id"]').last().css("margin-left","-1px"),$('tr td:last-child:contains("|")').replaceText(/\|/gi,"")):$('tr td:last-child:contains("|")').contents().filter(function(){return 3==this.nodeType}).remove(),v___location_path!=v___location_prefix+"/fdisk/"&&v___location_path!=v___location_prefix+"/fdisk/index.cgi"||$("body").find('a[href^="blink.cgi"]:not(.ui_link_replaced)').html($("body").find('a[href^="blink.cgi"]:not(.ui_link_replaced)').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-warning btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link"),v___location_path!=v___location_prefix+"/fsdump/"&&v___location_path!=v___location_prefix+"/fsdump/index.cgi"||$.each($("tr td:last-child"),function(){$(this).find('a[href^="backup.cgi"]').html($(this).find('a[href^="backup.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-success btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link").prepend('  '),$(this).find('a[href^="kill.cgi"]').html($(this).find('a[href^="kill.cgi"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-danger btn-xxs margined-top--2 f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link").prepend('  ')}),v___location_path!=v___location_prefix+"/syslog/"&&v___location_path!=v___location_prefix+"/syslog/index.cgi"||$.each($("tr td:last-child"),function(){ $(this).find('a[href*="save_log.cgi"][href*="view=1"]').html($(this).find('a[href*="save_log.cgi"][href*="view=1"]').text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn btn-primary btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").removeClass("ui_link")}),v___location_path==v___location_prefix+"/software/list_pack.cgi")){$('td a.ui_link[href*="view.cgi"]').html('').addClass("ui_link_replaced btn btn-default btn-xxs f__lnk_t_btn-el").removeClass("heighter-34").attr("style","margin-top: 2px !important; margin-bottom: 0 !important; margin-right: 15px").removeClass("ui_link").prepend('')}if(v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"proc/"&&v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"proc/index.cgi"||((v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"proc/"&&v___location_file&&v___location_file.indexOf("index_")>-1||v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"proc/index.cgi"||v___location_path===v___location_prefix+"/proc/")&&($("a.ui_link + b").addClass("btn").css("margin-left","3px"),$("b + a.ui_link").addClass("btn").css("margin-left","3px"),$('.panel-body > b:first-child:contains("Display")').length>0&&$(".panel-body > b:first-child").remove(),$(".panel-body > b").addClass("btn btn-success")),$(".panel-body").contents().filter(function(){return 3==this.nodeType}).remove(),$(".panel-body > a.ui_link").addClass("btn").css("margin-left","3px")),!e){v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"fdisk/"&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"postfix/"&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"pam/"&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"syslog/"||$("p > a[href], table + a[href], div.panel-body > a.ui_link").each(function(e,t){$(this).text($(this).text().replace(/\.$/,""))});$(".container-fluid .panel-body a.select_all,.container-fluid .panel-body a.select_invert,.container-fluid .panel-body a.select_invert ~ .ui_link,.container-fluid .panel-body .ui_links_row > *:not(.ui_link_empty, .ui_link_replaced),.container-fluid .panel-body .ui_link:not(.ui_link_empty)").each(function(){if(!($(this).parent("td").length||$(this).parent("label").length||$(this).parent("tt").length||$(this).parents("b").length||v___location_path==v___location_prefix+"/webmin_search.cgi")&&(!core.curModuleFile("virtual-server","history.cgi")&&!core.curModuleFile("server-manager","one_history.cgi")&&!core.curModule("proc")&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"passwd/"&&$(this).text()&&v___location_path!=v___location_prefix+"/mailboxes/"&&v___location_path!=v___location_prefix+"/mailboxes/index.cgi"&&v___location_path!=v___location_prefix+"/usermin/list_configs.cgi"&&!$(this).hasClass("help_popup")||core.curModule("procmail"))){$(this).addClass("btn btn-inverse btn-tiny ui_link_replaced"),$(this).text($(this).text().replace(/\.$/,""));var e=$(this).parent().contents().filter(function(){return 3==this.nodeType});e&&$.each(e,function(){$(this).text()&&$(this).text().length<=3&&$(this).remove()}),$(this).hasClass("select_all")&&$(this).html(' '+$(this).text()),$(this).hasClass("select_invert")&&$(this).html(' '+$(this).text()),(core.curModuleFile("server-manager","index.cgi")||core.curModuleFile("server-manager",""))&&($(this).parent('form[action="mass.cgi"]').length||$(this).parent(".ui_links_row").parent('form[action="mass.cgi"]').length)&&(($(this).is(":nth-child(1)")||$(this).is(":nth-child(6)"))&&$(this).html(' '+$(this).text()),($(this).is(":nth-child(2)")||$(this).is(":nth-child(7)"))&&$(this).html(' '+$(this).text()),($(this).is(":nth-child(3)")||$(this).is(":nth-child(8)"))&&$(this).html(' '+$(this).text())),$(this).attr("href")&&(0===$(this).attr("href").indexOf("edit")&&0!==$(this).attr("href").indexOf("edit_allow")||0===$(this).attr("href").indexOf("master_form")||0===$(this).attr("href").indexOf("slave_form")||0===$(this).attr("href").indexOf("stub_form")||0===$(this).attr("href").indexOf("forward_form")||0===$(this).attr("href").indexOf("delegation_form")||0===$(this).attr("href").indexOf("mass_form")||0===$(this).attr("href").indexOf("newdb_form"))?$(this).html(' '+$(this).html()):$(this).attr("href")&&0===$(this).attr("href").indexOf("edit_allow")?$(this).html(' '+$(this).text()):($(this).attr("href")&&0===$(this).attr("href").indexOf("mass_ucreate")&&$(this).html(' '+$(this).text()),$(this).attr("href")&&$(this).attr("href").indexOf("grace_form")>-1&&$(this).html(' '+$(this).text())),$(this).attr("href")&&$(this).attr("href").indexOf("edit_manual")>-1&&$(this).html(' '+$(this).text()),core.curModule("custom")&&($(this).attr("href")&&0===$(this).attr("href").indexOf("edit_cmd.cgi?new")&&$(this).html(' '+$(this).text()),$(this).attr("href")&&0===$(this).attr("href").indexOf("edit_file.cgi?new")&&$(this).html(' '+$(this).text()),$(this).attr("href")&&0===$(this).attr("href").indexOf("edit_sql.cgi?new")&&$(this).html(' '+$(this).text())),$(this).attr("href")||$(this).remove()}});$.each($(".btn-group.ui_links_row > .ui_link_empty"),function(){($(this).prev(".btn-tiny.ui_link_replaced").length||$(this).next(".btn-tiny.ui_link_replaced").length)&&$(this).addClass("btn-tiny ui_link_replaced")}),$.each($(".btn-tiny.ui_link_replaced"),function(){$(this).prev('[class="table table-striped table-condensed"]').length&&$(this).next(':not(".ui_link_replaced")').length&&$(this).removeClass("btn-tiny ui_link_replaced").addClass("ui_link_re-replaced")}),$("a.ui_link_replaced").each(function(){$(this).prev().is("b")&&$(this).prev("b").addClass("btn btn-success btn-tiny"),$(this).next().is("b")&&$(this).next("b").addClass("btn btn-success btn-tiny"),core.curModule("htaccess-htpasswd")&&$("table tr.ui_checked_columns .ui_links_row > a").addClass("btn-link btn-link-bordered btn-xxs btn-hover-hide").removeClass("btn-tiny btn-inverse")}),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"fetchmail/"&&$("a.ui_link").each(function(){$(this).addClass("btn btn-inverse btn-tiny ui_link_replaced").css("margin-bottom","10px").css("margin-top","4px"),$(this).text($(this).text().replace(/\.$/,"")),$(this).parent().contents().filter(function(){return 3==this.nodeType}).remove();var e=function(e){return' '};$(this).attr("href").indexOf("edit_poll")>-1&&$(this).prepend(e("plus-square-o")),$(this).attr("href").indexOf("edit_global")>-1&&$(this).prepend(e("pencil-square-o")),$(this).attr("href").indexOf("check")>-1&&$(this).prepend(e("check-square-o"))}),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"filter/"&&$("a.ui_link").each(function(){function e(e){return' '}$(this).attr("href").indexOf("edit_auto")>-1&&$(this).find("i").replaceWith(e("reply")),$(this).attr("href").indexOf("edit_forward")>-1&&$(this).find("i").replaceWith(e("reply-all"))})}v___location_path!=v___location_prefix+"/virtual-server/domain_form.cgi"&&v___location_path!=v___location_prefix+"/server-manager/list_images.cgi"&&v___location_path!=v___location_prefix+"/virtual-server/bwgraph.cgi"||($(".panel-body > .ui_links_row > ").each(function(){$(this).addClass("btn btn-inverse btn-tiny ui_link_replaced").removeClass("ui_link"),$(this).text($(this).text().replace(/\.$/,"")),$(this).hasClass("btn-success")&&$(this).removeClass("btn-inverse")}),$.each($(".panel-body > .ui_links_row > .ui_link_empty"),function(){$(this).text().replace(/[\t\n]+/g," ").length<4?$(this).remove():($(this).text($(this).text().replace("|","").replace("|","").replace(/(?:\r\n|\r|\n)/g,"")),$(this).prev().is("img")&&$(this).removeClass().addClass("margined-left-3"))}),$(".panel-body > b").css("margin-right","7px"),v___location_path==v___location_prefix+"/virtual-server/domain_form.cgi"&&$.each($(".panel-body > .ui_links_row > .btn"),function(e,t){0==e&&$(this).html(' '+$(this).text()),1==e&&$(this).html(' '+$(this).text()),2==e&&$(this).html(' '+$(this).text()),3==e&&$(this).html(' '+$(this).text())})),v___location_path!=v___location_prefix+"/server-manager/edit_serv.cgi"&&v___location_path!=v___location_prefix+"/server-manager/edit_owner.cgi"||($('.table-striped .col_value a[href^="edit_serv.cgi"], .table-striped .col_value a[href^="edit_owner.cgi"]').each(function(){$(this).addClass("btn btn-inverse btn-xxs ui_link_replaced margined-right--2").removeClass("btn-tiny ui_link").attr("style","margin-top: 0 !important"),$(this).text($(this).text().replace(/\.$/,"")),$(this).hasClass("btn-success")&&$(this).removeClass("btn-inverse")}),$.each($(".table-striped .col_value .ui_links_row > .ui_link_empty"),function(){$(this).addClass("btn-xxs ui_link_replaced").removeClass("btn-tiny ui_link"),$(this).text().length<4?$(this).remove():$(this).text($(this).text().replace("|","").replace("|","").replace(/(?:\r\n|\r|\n)/g,""))})),$("a.ui_link, .btn").each(function(){if("."==$(this).text().substr(-1)&&!$(this).parent().is("label")){var e="."==$(this).text().substr(-1)&&".."==$(this).text().substr(-2)?2:1;$(this).text($(this).text().substr(0,$(this).text().length-e))}})},snippets.page.render=function($is_history_action){function __m_ico_row_tb(){$("body").find(".icons-row:not(._processed_):not(.inline-row)").css({"padding-top":"8px","padding-bottom":"8px"}),$("body").find(".icons-row:not(._processed_):not(.inline-row)").css("border-top","1px solid #efefef").css("border-bottom","1px solid #efefef")}function __m_ico_row_t(){$("body").find(".icons-row:not(._processed_):not(.inline-row)").css({"padding-top":"8px"}),$("body").find(".icons-row:not(._processed_):not(.inline-row)").css("border-top","1px solid #efefef")}function __m_ico_row_b(){$("body").find(".icons-row:not(._processed_):not(.inline-row)").css({"padding-bottom":"6px"}),$("body").find(".icons-row:not(._processed_):not(.inline-row)").css("border-bottom","1px solid #efefef")}function __m_ico_row_func(){return 0}function reset_dnd_uploads(){if(core.curModule("updown")||core.curModuleFile("updown","index.cgi")){var e=$('form.ui_form[action*="upload.cgi"]'),t=e.find(".ui_submit.ui_form_end_submit"),i=e.find(".file-input-wrapper");theme_restore_buttons_class(),$.fn.bootstrapFileInputReset(e),despinnerfy_buttons(0,t),i.find("span").remove(),i.contents().unwrap()}}function init_dnd_uploads(){if(core.curModule("updown")||core.curModuleFile("updown","index.cgi")){var e=$('input[type="file"]:not([name="upfiles"])'),t='form.ui_form[action*="upload.cgi"]',i=$(t+" .ui_submit.ui_form_end_submit");$(t+' input[name^="upload"]:not([name="upload0"])').remove(),e.bootstrapFileInput(["dnd dnd_updown",i]),i.addClass("disabled"),plugins.upload($("#att_upload .ui_form")),init_dnd_form($(t))}}function init_dnd_form(e){e.on("drag dragstart dragend dragover dragenter dragleave drop",function(e){e.preventDefault(),e.stopPropagation()}).on("drop",function(e){droppedFiles=e.originalEvent.dataTransfer.files,$(this).trigger("input").find('input[type="file"]').prop("files",droppedFiles).trigger("change.fiw")}),e.find(".file-input-wrapper").on("dragover dragenter",function(){$(this).addClass("pulse")}).on("dragleave dragend drop",function(){$(this).removeClass("pulse")})}if(plugins.dashboard.restore(),plugins.navigation.state.update(),$is_history_action&&"undefined"!=typeof __cm_editor_static&&(__cm_editor_static.toTextArea(),$('button[data-form="submitter"]').unwrap(),$('.CodeMirror, button[data-form="submitter"] + button, .-helper.__helper, .-helper.soft_wt').remove()),function(){var e=$("body");e.off("mousedown.cm1 keydown.cm1"),e.undelegate('button[type="submit"]:not(.disabled)',"click.cm"),e.undelegate('button[data-form="submitter"]:not(.disabled)',"click.cm")}(),table_proc_size_columns(),$("body").attr("style",get_server_data("style")),$.each($('select[onchange="form.submit()"]'),function(){$(this).removeAttr("onchange").addClass("onchange_form_submit_triggger")}),page.handle.content.offset(!0),editor_init_check()){var select_for_edited_file=$('select[name="file"]:first, select[name="manual"]:first');select_for_edited_file.addClass("onchange_form_submit_triggger"),select_for_edited_file.next("button.ui_form_end_submit").addClass("hidden")}snippets.datetime.locale();var $langLocaleLangStr=theme_language("theme_xhred_title_language_locale"),$userminModule=core.curModule("language"),$webminModule=core.curModule("change-user"),$webminConfModule=core.curModuleFile("webmin","edit_lang.cgi");if(core.curModule("webmin")){var $targetIconTitle=$('.icons-container a[href*="edit_lang.cgi"]'),$targetSmallIconTitle=$('.small-icons-container a[href*="edit_lang.cgi"]'),$targetNoIconTitle=$('a[href*="edit_lang.cgi"] p > .fa-angle-right');if($targetIconTitle.length){var $targetIconTitleImg=$targetIconTitle.find("img").detach();$targetIconTitle.text($langLocaleLangStr).prepend($targetIconTitleImg,"
")}else $targetSmallIconTitle.length?($targetSmallIconTitle.find(".hidden").text($langLocaleLangStr),$targetSmallIconTitle.parent().attr("title",$langLocaleLangStr)):$targetNoIconTitle.length&&$targetNoIconTitle.parent().html('  '+$langLocaleLangStr)}if(3==get_access_level()&&core.curModule("quota"))var $_table_quota=$(".container-fluid .panel-body .table"),$_table_quota_empty_label=$_table_quota.find("thead:first-child").add($_table_quota.find("thead:first-child").next("tbody")).remove();if(($webminConfModule||$webminModule||$userminModule)&&!$is_history_action){var $dateFormatTarget=$('.container-fluid form select[name="lang"]'),$dateFormatTargetMore=$userminModule?$dateFormatTarget.next(".ui_form_end_buttons").find("tbody"):$dateFormatTarget.parents("tr").first().parent("tbody"),$dateForm=$dateFormatTargetMore.parents("form").first(),$dateFormatFinalTarget=$userminModule?$dateFormatTargetMore:$dateFormatTargetMore.find('select[name="lang"]').parents("tr").first();$webminModule&&$('[name="overlay"]').parent("td").parent("tr").addClass("hidden"),$webminModule||$("span[data-main_title]").text($langLocaleLangStr);var insertionRow=' '+($webminModule?theme_language("theme_xhred_title_webmin_ui_locale"):theme_language("theme_xhred_title_locale_config"))+($userminModule?":   ":"")+' '+($webminModule?theme_language("theme_xhred_title_locale_config_format_ui"):theme_language("theme_xhred_title_locale_config_format"))+' '+($userminModule?"    ":"")+" "+theme_language("theme_xhred_title_locale_lang_based")+'    '+theme_language("theme_xhred_title_locale_full")+'  `LLLL`

"+theme_language("theme_xhred_global_output_example")+": "+moment().format("LLLL")+'

">
 
'+theme_language("theme_xhred_title_locale_long")+'  `LL`

"+theme_language("theme_xhred_global_output_example")+": "+moment().format("LL")+'

">
 
'+theme_language("theme_xhred_title_locale_short")+'  `L`

"+theme_language("theme_xhred_global_output_example")+": "+moment().format("L")+'

">
'+(core.moduleAvailable("webmin")?'
'+theme_language("theme_xhred_title_locale_non_ui_config")+' 
':"")+" ";$userminModule?$dateFormatFinalTarget.prepend(insertionRow):($dateFormatFinalTarget.after(insertionRow),core.setModuleData("/webmin/edit_ui.cgi",["dateformat"])),$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-get_theme_locale_languages=1",data:!1,dataType:"text",async:$.support.spa,success:function(e){$('select[data-select="locales"]').replaceWith(e),$('#config_portable_theme_locale_languages option[value="ru-su"]').remove();var t='input[id*="config_portable_theme_locale_language"], select[name="config_portable_theme_locale_languages"], input[name="config_portable_theme_locale_format_full"], input[name="config_portable_theme_locale_format_long"], input[name="config_portable_theme_locale_format_short"]',i=$(t);$(i).on("change keyup focus",function(e){var t=$(this).attr("name"),i=$(this).parent(),a=i.data("title"),n=$('select[name="config_portable_theme_locale_languages"]').val();fleeting_format=$(this).val(),fleeting_format||(t.includes("short")?fleeting_format="L":t.includes("long")?fleeting_format="LL":t.includes("full")&&(fleeting_format="LLLL")),t.indexOf("theme_locale_format_")>-1&&i.attr("title",a.replace(/g'>(.*)<\/i>/g,"g'>"+(n?moment().locale(n).format(fleeting_format):moment().format(fleeting_format))+"")).tooltip("fixTitle").tooltip("show");var s=$("._locale_config");"config_portable_theme_locale_language"===t&&"1"!=fleeting_format?"focus"!=e.type&&s.addClass("hidden"):"focus"!=e.type&&s.removeClass("hidden")}),$($dateForm).on("submit",function(){var e=$('[name="dateformat"]');e.length&&core.updateModuleData("/webmin/edit_ui.cgi","/webmin/change_ui.cgi",{dateformat:$.trim(e.val())}),$.each($(t.replace('locale_language"]','locale_language"]:checked')),function(e,t){var i=$(this).attr("name"),a=$(this).val();"config_portable_theme_locale_languages"===i&&""===a&&(a=get_server_data("language-full")),localStorage.setItem(v___server_hostname+"-"+i,a),window[i]=a}).promise().done(function(){var e=$dateForm.find('select[name="lang"]').val();if(e.indexOf(".")>-1&&(e=e.split(".")[0]),$webminModule&&"1"==$dateForm.find('[name="lang_def"]:checked').val()){var t=$('[name="lang_def"][value="1"]').next("label").text().match(/\(([^)]+)\)/),t=t&&t[0]&&t[1]?t[1]:get_server_data("language-full");t.indexOf(".")>-1&&(t=t.split(".")[0]),e=t}moment.locale(config_portable_theme_locale_language&&"0"!=config_portable_theme_locale_language?config_portable_theme_locale_languages:e),theme_config("save"),setTimeout(function(){plugins.navigation.reload()},2e3)})})}})}$.support.spa&&core.curModule("tunnel")&&$("form").on("submit",function(e){var t=$(quirks.active_element());e.preventDefault(),e.stopPropagation(),$.ajax({type:$(this).attr("method")?"GET":"POST",url:v___location_prefix+"/"+v___module+"/"+$(this).attr("action"),data:get_form_data($(this)),dataType:"text",complete:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);theme_open_new_tab(this.url),t.removeClass("disabled").find("i").removeClass("invisible").next(".cspinner_container").remove()}})}),check_location_resource("/config.cgi?tunnel")&&$('table table[width="100%"] tr:first-child').addClass("hidden"),$.each($('tr td:last-child a:contains("..")'),function(){if(v___location_path==v___location_prefix+"/virtual-server/list_databases.cgi"){if($(this).attr("href")&&$(this).attr("href").includes("showpass.cgi"))return!0;$(this).html($(this).text().replace(/\.\.$/," ")).addClass("ui_link_replaced btn f__lnk_t_btn-el btn-transparent btn-link-bordered btn-xxs margined-top--3").removeClass("ui_link")}}),$.support.spa&&!$is_history_action&&$("#headln2c").prepend(" '),plugins.favorites.detect(),$(".switch-toggle").find('label[for="open_thirdlane"]').length&&$('.switch-toggle input:not([id="open_webmin"])').each(function(){$(this).removeAttr("checked")}).promise().done(function(){$("#open_webmin").prop("checked",!0)}),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"init/"&&$("table.table tbody tr").addClass("ui_checked_columns"),page_table_rows_control(),!$is_history_action&&page_radios_evolve();var $onLoad_checkBox=$('.ui_checked_columns td.ui_checked_checkbox input[type="checkbox"]:checked:not(disabled)').parents("tr.ui_checked_columns").addClass("hl-aw");if($("body").hasClass("servers")&&$('form[action="delete_servs.cgi"] a.icon_link, form[action="delete_servs.cgi"] a.ui_link, form[action="delete_servs.cgi"] .col-xs-1').on("click",function(e){if($(e.target).is(".gl-icon-select"))return void($.support.spa?$(this).trigger("contextmenu"):$(this).parents(".gl-icon-container").trigger("contextmenu"));var t=v___location_href+$(this).attr("href"),i=$(this).attr("href");$(this);i&&i.indexOf("edit_serv.cgi")>-1||i&&i.indexOf("logout.cgi")>-1?void 0!==e.originalEvent&&$.pjax.click(e,{timeout:0,push:get_pjax_push(),type:get_pjax_type(),container:"[data-dcontainer]",fragment:"[data-dcontainer]"}):i&&i.indexOf("://")===-1?open(link_type_convert(t,1)):open(i),e.preventDefault(),e.stopPropagation()}),core.curModule("servers")&&$.each($('form[action*="delete_servs.cgi"] a[href*="link.cgi"]'),function(){var e=$(this).attr("href");e&&e.match(/(link.cgi\/\d+)/)&&$(this).attr("target","_blank")}),v___location_path!=v___location_prefix+"/apache/edit_global.cgi"&&v___location_path!=v___location_prefix+"/apache/edit_virt.cgi"&&v___location_path!=v___location_prefix+"/apache/edit_dir.cgi"||$.each($(".ui_opt_textbox.form-control"),function(){$(this).parent("span").next("button.btn.btn-default.chooser_button").length>0&&$(this).css("margin-right","4px")}),!$is_history_action){$(".opener_container").length&&$.each($(".opener_container"),function(){$(this).find(".opener_shown").is(":visible")&&$(this).parent("tr").prev("tr").find("td a:nth-child(1)").addClass("opener_container_opened").removeClass("opener_container_closed")}),$(".opener_shown, .opener_hidden").length>0&&$(".opener_trigger").length>0&&($(".panel-body .ui_form .table tbody tr").removeClass("thead"),$(".opener_trigger").parents("table.table").addClass("opener_table_style"),$(".opener_trigger").parents("tr").addClass("_c__op_r").attr("style","border: 0 !important"),$(".opener_trigger").parent("td").addClass("_c__op_d"),$(".opener_trigger").parent("td").find("a").addClass("link_hover_effect link_hover_effect_style_extra"));var target_restore_selector='a[id*="opener"][id$="_restore"]';$('a[id*="opener"][id$="_restore"]').parent().is("p")&&($('a[id*="opener"][id$="_restore"]').next("a").parent("p").replaceTagName("div"),$('a[id*="opener"][id$="_restore"]').next("a").removeClass().addClass("opener_extra_container_a_style link_hover_effect").parent("div").addClass("opener_extra_container opener_extra_container_style margined-top-10"),$('a[id*="opener"][id$="_restore"]').remove()),$('a[href^="javascript:hidden_opener"]:not(".opener_trigger")').length>0&&($('a[href^="javascript:hidden_opener"]:not(".opener_trigger")').each(function(e,t){var i=!!(v___location_path==v___location_prefix+"/virtual-server/backup_form.cgi"&&v___location_href&&v___location_href.indexOf("?sched=")>-1);if($(this).find("img").length>0&&$(this).remove(),$(this).css("border-bottom","0"),$(this).parents("table.table").addClass("opener_table_style_small"),$(this).parent("td").addClass("opener_table_cell_style_small"),i||$(this).parent("td").addClass("opener_table_cell_style_small opener_table_cell_style_small_exclusion_border_top"),$(this).parent("td").find("a").addClass("link_hover_effect link_hover_effect_style"),$(this).parent().is(".panel-body")||$(this).parent().is(".ui_form")||$(this).parent().is("p")){var a=$(this),n=a.parent().is(".panel-body")?".panel-body":a.parent().is("p")?"p":".ui_form",s=a.parent(n).find('a[href^="javascript:hidden_opener"]'),o='
';core.curModuleFile("bind8","edit_zonekey.cgi")?(s.eq(1).wrapAll(o),s.eq(e+1).wrapAll(o)):s.eq(e+1).wrapAll(o),a.parent('.panel-body > a[href^="javascript:hidden_opener"]:first-child').remove();var r=a.parent(n).find(".opener_extra_container");$(r).next("br").remove(),$(r).addClass("opener_extra_container_style"),$(r).find("a").addClass("opener_extra_container_a_style link_hover_effect"),$(r).next(".opener_hidden").attr("style","padding:8px")}}),$.each($(".opener_hidden"),function(){$(this).css("display","none")})),$("a.opener_trigger").each(function(){$(this).parent("td").css("text-align","left")}),$('form[action*="seen_newfeatures.cgi"]').each(function(){$(this).parents("table.table-striped").next(".ui_form_end_buttons").css("margin-top","14px")}),$("#tall_0").before("
"),$(".opener_container").each(function(e,t){$(this).find("div").hasClass("opener_hidden")?$(this).hide():$(this).show()}),$.each($("div.barchart"),function(){var e=$(this).find('img[src*="red.gif"]'),t=$(this).parent("td").contents().filter(function(){return 3==this.nodeType}).text();e&&e.attr("width")&&$(this).parent("td").html('
'+t+'
'+e.attr("width")+"
")}),$('.panel-body > form > table > tbody > tr > td:has(input[type="submit"])').parents("table.table-hardcoded > tbody > tr").css("border","none").parents("table").css("margin-top","20px"),$('.panel-body > form > table > tbody > tr > td:has(input[type="submit"])').parents("table.table-hardcoded > tbody").css("border","none"),$('.ui_grid_table > tbody > tr.ui_grid_row > td:has(button[type="submit"])').parents("table.ui_grid_table").css("border","none"),$("form.ui_form > table label.radio, form.ui_form > table label.checkbox").each(function(){var e=$(this),t=e.find("i.fa"),i=e.find("i.fa").text().trim(),a=e.text().trim();0===i.length&&0===a.length&&t.parent("label").remove()})}if(v___location_path&&(v___location_path.indexOf("/webmin/edit_themes.cgi")>-1||v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-user.cgi")){if(v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-user.cgi"){plugins.navigation.reset() ;var $target_parents_row=$('[name="settings_navigation_color"]').parent("td").parent("tr"),rows=' '+theme_language("settings_grayscale_level_navigation")+'
'+theme_language("settings_grayscale_level_navigation_description")+'
'+theme_language("settings_sepia_level_navigation")+'
'+theme_language("settings_sepia_level_navigation_description")+'
'+theme_language("settings_saturate_level_navigation")+'
'+theme_language("settings_saturate_level_navigation_description")+'
'+theme_language("settings_hue_level_navigation")+'
'+theme_language("settings_hue_level_navigation_description")+'
'+theme_language("settings_invert_level_navigation")+'
'+theme_language("settings_invert_level_navigation_description")+'
'+theme_language("settings_brightness_level_navigation")+'
'+theme_language("settings_brightness_level_navigation_description")+'
'+theme_language("settings_contrast_level_navigation")+'
'+theme_language("settings_contrast_level_navigation_description")+'
';$target_parents_row.after(rows)}var ev_change_atsettings='#atsettings form[action*="settings.cgi"] select, form[action*="save_config.cgi"]#settings_ select, #atsettings form[action*="settings.cgi"] input, form[action*="save_config.cgi"]#settings_ input';$("body").undelegate(ev_change_atsettings,"change"),$("body").on("change",ev_change_atsettings,function(e){var t=$(this).val();if("true"==t||"false"==t?"true"==t?c=!0:"false"==t&&(c=!1):c=t,window[$(this).attr("name")]=Test.numeric(c)?c&&c.length>16?c:parseFloat(c):c,void 0!==e.originalEvent)if(v___initial_load&&"settings-user.cgi"!==v___location_file)v___initial_load=0;else{var i='input[name="settings_side_slider_enabled"]';!$(e.target).is(i)&&$(e.target).is(i)||theme_config_controls(1)}});var ev_keydown_atsettings='#atsettings form[action*="settings.cgi"] input, form[action*="save_config.cgi"]#settings_ input';$("body").undelegate(ev_keydown_atsettings,"keydown"),$("body").on("keydown",ev_keydown_atsettings,function(e){void 0!==e.originalEvent&&theme_config_controls(1)}),v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-user.cgi"&&$('button[type="button"][name="save_user"]').on("click",function(e){e.preventDefault(),e.stopPropagation(),theme_config_update(),theme_config("save"),plugins.navigation.load.start(),spinnerfy_buttons($(this),[-.5,-25,"small"]),setTimeout(function(){plugins.navigation.reload()},1400)}),$(function(){function e(){$("body").undelegate("#atrestore:not(.disabled)","click"),$("#atrestore:not(.disabled)").off("click.confirm"),$("#atrestore:not(.disabled)").on("click",function(){var e=get_onbeforeunload_status();set_onbeforeunload_status(0),e&&setTimeout(function(){set_onbeforeunload_status(e)},2500)}),$("#atrestore:not(.disabled)").confirmation({classNameRemove:"btn-default"},function(){$(this).off();var e=$(this);e.hasClass("btn-inverse")||setTimeout(function(){spinnerfy_buttons(e,[1.5,-33,"small",!1]);var t=$(".ui_form").serialize();$.ajax({type:"POST",url:v___location_prefix+"/index.cgi?xhr-settings=1&restore=1",data:t,success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);theme_reload()},error:function(t){e.addClass("btn-danger").removeClass("btn-default btn-inverse opacity-0_5")}})},0)})}core.moduleAvailable("webmin")&&!$is_history_action&&($(".container-fluid .nav.nav-tabs").prepend('
  • '),$(".container-fluid .tab-pane").first().before('
    '),$('.container-fluid .nav-tabs a[href="#atsettings"]').tab("show")),$is_history_action||$.ajax({type:"GET",url:v___location_prefix+"/index.cgi/?xhr-settings=1",data:!1,dataType:"text",success:function(t){function i(e){void 0===e&&(e=$('input[name="settings_right_hide_table_icons"]:checked'));var t=["settings_right_small_table_icons","settings_right_animate_table_icons","settings_right_grayscaled_table_icons"];"true"==e.val()?$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!0),$('input[name="'+t+'"]').parent(".aradio").addClass("disabled")}):$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!1),$('input[name="'+t+'"]').parent(".aradio").removeClass("disabled")})}function a(e){void 0===e&&(e=$('input[name="settings_hotkeys_active"]:checked'));var t=["settings_hotkey_custom_1","settings_hotkey_custom_2","settings_hotkey_custom_3","settings_hotkey_custom_4","settings_hotkey_custom_5","settings_hotkey_custom_6","settings_hotkey_custom_7","settings_hotkey_custom_8","settings_hotkey_custom_9","settings_hotkey_toggle_modifier","settings_hotkey_toggle_key_webmin","settings_hotkey_toggle_key_virtualmin","settings_hotkey_toggle_key_cloudmin","settings_hotkey_toggle_key_usermin","settings_hotkey_toggle_key_webmail","settings_hotkey_shell","settings_hotkey_focus_search","settings_hotkey_navigation","settings_hotkey_slider","settings_hotkey_toggle_slider","settings_hotkey_reload","settings_hotkey_reload","settings_hotkey_toggle_key_night_mode","settings_hotkey_sysinfo","settings_hotkey_favorites"];"false"==e.val()?$.each(t,function(e,t){$('input[name="'+t+'"], select[name="'+t+'"]').prop("disabled",!0)}):$.each(t,function(e,t){$('input[name="'+t+'"], select[name="'+t+'"]').prop("disabled",!1)})}function n(e){void 0===e&&(e=$('input[name="settings_side_slider_enabled"]:checked'));var t=["settings_side_slider_palette","settings_side_slider_fixed","settings_side_slider_fixed_toggle","settings_side_slider_sysinfo_enabled","settings_side_slider_notifications_enabled","settings_side_slider_favorites_enabled"];"false"==e.val()?$.each(t,function(e,t){"settings_side_slider_fixed"!=t&&"settings_side_slider_fixed_toggle"!=t||$('input[name="settings_side_slider_fixed"][value="false"], input[name="settings_side_slider_fixed_toggle"][value="false"]').trigger("click"),setTimeout(function(){$('input[name="'+t+'"], select[name="'+t+'"]').prop("disabled",!0).parent(".aradio").addClass("disabled")},10)}):$.each(t,function(e,t){("settings_side_slider_fixed"!=t||"settings_side_slider_fixed"==t&&"true"!=$('input[name="settings_navigation_always_collapse"]:checked').val())&&("settings_side_slider_fixed_toggle"!=t||"settings_side_slider_fixed_toggle"==t&&"true"!=$('input[name="settings_navigation_always_collapse"]:checked').val())&&$('input[name="'+t+'"], select[name="'+t+'"]').prop("disabled",!1).parent(".aradio").removeClass("disabled")})}function s(e){void 0===e&&(e=$('input[name="settings_sysinfo_real_time_status"]:checked'));var t=["settings_sysinfo_real_time_timeout"];"true"==e.val()?$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!1).removeClass("disabled")}):$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!0).addClass("disabled")})}function o(e){void 0===e&&(e=$('input[name="settings_sysinfo_easypie_charts"]:checked'));var t=["settings_sysinfo_easypie_charts_size","settings_sysinfo_easypie_charts_width","settings_sysinfo_easypie_charts_scale"];"true"==e.val()?$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!1).removeClass("disabled")}):$.each(t,function(e,t){$('input[name="'+t+'"]').prop("disabled",!0).addClass("disabled")})}function r(e){void 0===e&&(e=$('input[name="settings_sysinfo_theme_updates"]:checked'));var t=["settings_cache_interval"];"true"==e.val()?$.each(t,function(e,t){$('[name="'+t+'"]').prop("disabled",!1).removeClass("disabled")}):$.each(t,function(e,t){$('[name="'+t+'"]').prop("disabled",!0).addClass("disabled")})}function l(e){void 0===e&&(e=$('input[name="settings_navigation_always_collapse"]:checked'));var t=["settings_side_slider_fixed","settings_side_slider_fixed_toggle","settings_leftmenu_width"];"true"==e.val()?(vars.slider_pinned=-1,$.each(t,function(e,t){"settings_side_slider_fixed"!=t&&"settings_side_slider_fixed_toggle"!=t||$('input[name="settings_side_slider_fixed"][value="false"], input[name="settings_side_slider_fixed_toggle"][value="false"]').trigger("click"),setTimeout(function(){$('input[name="'+t+'"]').prop("disabled",!0).parent(".aradio").addClass("disabled")},10)})):$.each(t,function(e,t){"settings_side_slider_fixed"!=t&&"settings_side_slider_fixed_toggle"!=t||"false"==$('input[name="settings_side_slider_enabled"]:checked').val()||$('input[name="'+t+'"]').prop("disabled",!1).parent(".aradio").removeClass("disabled")})}if(Test.strContains(t,v___page_signin_form))return void(v___available_session=0);$("#atsettings").html(t);var _=get_server_data("theme-version"),c=$('input[name="settings_sysinfo_theme_updates"]').first().parents("td").parent("tr.atshover"),d=c.find("td").first(),p=d.find(".smaller");c.next("tr").find("td").first().find("b");p.append(' ('+theme_language("theme_xhred_global_installed_version").toLowerCase()+" "+_+')'+theme_spinner_small("in-btn-md tmp_spinner_theme_version"," ","width:10px; height:10px; margin-left: 5px;")),$.ajax({type:"POST",url:v___location_prefix+"/index.cgi/?xhr-theme_latest_version=1",data:!1,dataType:"json",success:function(e){var t=String(),i=e[0],a=i!=e[1]&&e[1],n=$("[data-text-installed]"),s=$(".tmp_spinner_theme_version"),o=$("em[data-theme-stable-version]"),r=$("span[data-theme-versions]");i&&i!=_&&(t+=", "+theme_language("theme_xhred_global_latest_stable").toLowerCase()+' '+i+""),a&&a!=_&&(t+=", "+theme_language("theme_xhred_global_latest_beta").toLowerCase()+' '+a+""),_&&_.length<=5&&i&&i.length<=5&&i!=_&&o.addClass("text-danger"),t&&!t.length&&(n.text(theme_language("theme_xhred_global_installed_and_latest_version").toLowerCase()),o.addClass("text-success")),r.replaceWith(t),s.remove()},error:function(){}}),page.render.module_config([0,1,0,0,0,0,0,0,1]);var h=$("div#atsettings").find(".ui_form");$__theme_text_right_save=h.data("text-save"),$__theme_text_right_saved=h.data("text-settings_right_saved"),$__theme_text_right_saving=h.data("text-settings_right_saving"),$__theme_text_right_restore_defaults=h.data("text-settings_right_restore_defaults"),$__theme_text_right_restored=h.data("text-settings_right_restored"),$__theme_text_right_restoring=h.data("text-settings_right_restoring"),$__theme_text_right_error=h.data("text-error"),$('.container-fluid .nav-tabs a[href="#atsettings"]').text(h.data("text-current_theme")),$("div#atsettings").removeClass("text-center"),e(),theme_config_update();var u=$("body").find(".fa.fa-sub-title").parent("span");$(u).next("br").remove(),$(u).next("div.smaller").attr("style","margin-top: -15px !important"),u.remove(),i(),$('input[name="settings_right_hide_table_icons"]').on("change",function(){i($(this))}),a(),$('input[name="settings_hotkeys_active"]').on("change",function(){a($(this))}),n(),$('input[name="settings_side_slider_enabled"]').on("change",function(){n($(this))}),s(),$('input[name="settings_sysinfo_real_time_status"]').on("change",function(){s($(this))}),o(),$('input[name="settings_sysinfo_easypie_charts"]').on("change",function(){o($(this))}),r(),$('input[name="settings_sysinfo_theme_updates"]').on("change",function(){r($(this))}),$('select[name="settings_navigation_color"]').on("keyup change",function(e){var t=$(this).val(),i=$("link[data-palette]"),a="blue"!=t;a&&$("head").append(''),setTimeout(function(){get_server_data("data-theme",t),i.remove(),get_server_data("data-default-theme",t),$("body .user-link.palette-toggle").find(".fa-sun").trigger("click"),theme_config_update()},a?800:0)}),$('select[name="settings_background_color"]').on("click keyup change",function(){var e=$(this).val();get_server_data("data-background-style",e),get_server_data("data-background-style",e),$("link[data-palette]").remove(),"gainsboro"!=e&&($("head").append(''),$('select[name="settings_navigation_color"]').val("gunmetal").trigger("change")),theme_config_update()}),$('input[name="settings_enable_container_offset"]').change(function(){var e=$(this).val(),t=$(".container-fluid");"false"==e?t.removeClass("col-lg-10 col-lg-offset-1").addClass("margined-top-15"):t.addClass("col-lg-10 col-lg-offset-1").removeClass("margined-top-15")}),$('input[name="settings_contrast_mode"]').change(function(){var e=$(this).val();$("link[data-high-contrast]").remove(),"true"==e&&$("head").append(''),get_server_data("data-high-contrast","true"==e?"1":"0")}),$('input[name="settings_right_page_hide_persistent_vscroll"]').change(function(){var e=$(this).val(),t=$("#content.__page");"true"==e?t.removeClass("fvscroll"):t.addClass("fvscroll")}),$('select[name="settings_side_slider_palette"]').change(function(){$("body .right-side-tabs, body .right-side-tabs-toggler").attr("data-background-style",$(this).val())}),$('input[name="settings_side_slider_enabled"]').change(function(){"true"==$(this).val()?($("body .right-side-tabs-toggler").removeClass("hidden"),$("body .right-side-tabs").removeClass("hidden"),$('input[name="settings_side_slider_sysinfo_enabled"][value="true"], input[name="settings_side_slider_notifications_enabled"][value="true"], input[name="settings_side_slider_favorites_enabled"][value="true"]').trigger("click")):($("body .right-side-tabs-toggler").addClass("hidden"),$("body .right-side-tabs").addClass("hidden")),theme_config_update(),page_resized()}),$('input[name="settings_side_slider_fixed"]').change(function(){vars.slider_pinned=-1;var e=$(".right-side-tabs-dismiss .fa2-collapse-right");"true"==$(this).val()?(plugins.slider.state(1),e.removeClass("fa-rotate-45")):(plugins.slider.state(0),e.addClass("fa-rotate-45")),theme_config_update()}),$('input[name="settings_side_slider_fixed_toggle"]').change(function(e){var t=$(".right-side-tabs-dismiss .fa2-collapse-right");"true"==$(this).val()?t.removeClass("hidden"):(("true"==$('input[name="settings_side_slider_fixed"]:checked').val()&&t.hasClass("fa-rotate-45")||"false"==$('input[name="settings_side_slider_fixed"]:checked').val()&&!t.hasClass("fa-rotate-45"))&&t.trigger("click"),t.addClass("hidden")),vars.slider_pinned=-1,theme_config_update()}),$('input[name="settings_side_slider_sysinfo_enabled"], input[name="settings_side_slider_notifications_enabled"], input[name="settings_side_slider_favorites_enabled"]').change(function(e){var t="right-side-tabs-"+$(this).attr("name").split("_")[3],i=$(this).attr("name"),a=$("body").find("#"+t).hasClass("active"),n=$('input[name="settings_side_slider_sysinfo_enabled"][value="true"]:checked, input[name="settings_side_slider_notifications_enabled"][value="true"]:checked, input[name="settings_side_slider_favorites_enabled"][value="true"]:checked').length;"true"==$(this).val()?($("body").find('a[href="#'+t+'"], #'+t).removeClass("hidden").parent().removeClass("hidden"),"settings_side_slider_notifications_enabled"===i&&($(".right-side-tab-notification-asterix").removeClass("invisible hidden hidden-forged"),$(".right-side-tabs-toggler .badge.badge-danger").removeClass("invisible hidden hidden-forged"),setTimeout(function(){"function"==typeof plugins.slider.badge&&plugins.slider.badge()},300))):($("body").find('a[href="#'+t+'"], #'+t).addClass("hidden"),a&&n?$("body #right-side-tabs").find("li:not(.active) a:not(.hidden)").first().trigger("click"):0===n&&$('input[name="settings_side_slider_enabled"][value="false"]').trigger("click"),"settings_side_slider_notifications_enabled"===i&&($(".right-side-tab-notification-asterix").addClass("invisible hidden hidden-forged"),$(".right-side-tabs-toggler .badge.badge-danger").addClass("invisible hidden hidden-forged"),plugins.favicon.set(0))),theme_config_update()}),$('input[name="settings_side_slider_sysinfo_enabled"], input[name="settings_side_slider_notifications_enabled"], input[name="settings_side_slider_favorites_enabled"]').each(function(){$('input[name="'+$(this).attr("name")+'"][value="'+window[$(this).attr("name")]+'"]').trigger("change")}),$('select[name="settings_navigation_color"]').after(' ');var f=$(this).attr("data-name")+"_controller";window[f]="hidden",$(".settings_navigation_color_toggle, .settings_background_color_toggle").on("click",function(){void 0===window[f]||"hidden"==window[f]?($("."+$(this).attr("data-name")+"_reset, ."+$(this).attr("data-name")+"_rows").removeClass("hidden"),window[f]="shown"):($("."+$(this).attr("data-name")+"_reset, ."+$(this).attr("data-name")+"_rows").addClass("hidden"),window[f]="hidden"),$(this).toggleClass("forced")}),$(".settings_navigation_color_reset").on("click",function(){if("settings_navigation_color"==$(this).attr("data-name")){var e="-webkit-filter: grayscale(0) sepia(0) saturate(1) hue-rotate(0deg) invert(0) brightness(1) contrast(1); filter: grayscale(0) sepia(0) saturate(1) hue-rotate(0deg) invert(0) brightness(1) contrast(1);";$(".visible-xs.mobile-menu-toggler").attr("style","position: fixed;"+e),$("aside, .visible-xs.mobile-menu-toggler").attr("style","z-index: 10; overflow: visible; transform: translate("+settings_leftmenu_width+"px, 0px);"+e),$('input[name="settings_grayscale_level_navigation"], input[name="settings_sepia_level_navigation"], input[name="settings_hue_level_navigation"], input[name="settings_invert_level_navigation"]').val(0),$('input[name="settings_saturate_level_navigation"], input[name="settings_brightness_level_navigation"], input[name="settings_contrast_level_navigation"]').val(1);$('input[name="settings_grayscale_level_navigation"], input[name="settings_sepia_level_navigation"], input[name="settings_saturate_level_navigation"], input[name="settings_hue_level_navigation"], input[name="settings_invert_level_navigation"], input[name="settings_brightness_level_navigation"], input[name="settings_contrast_level_navigation"]').each(function(){$('code[data-name="'+$(this).attr("name")+'"]').text($(this).val())})}});var g=$('input[name="settings_grayscale_level_navigation"], input[name="settings_sepia_level_navigation"], input[name="settings_saturate_level_navigation"], input[name="settings_hue_level_navigation"], input[name="settings_invert_level_navigation"], input[name="settings_brightness_level_navigation"], input[name="settings_contrast_level_navigation"]');g.on("click keyup change",function(e){var t="-webkit-filter: grayscale("+$('input[name="settings_grayscale_level_navigation"]').val()+") sepia("+$('input[name="settings_sepia_level_navigation"]').val()+") saturate("+$('input[name="settings_saturate_level_navigation"]').val()+") hue-rotate("+$('input[name="settings_hue_level_navigation"]').val()+"deg) invert("+$('input[name="settings_invert_level_navigation"]').val()+") brightness("+$('input[name="settings_brightness_level_navigation"]').val()+") contrast("+$('input[name="settings_contrast_level_navigation"]').val()+"); filter: grayscale("+$('input[name="settings_grayscale_level_navigation"]').val()+") sepia("+$('input[name="settings_sepia_level_navigation"]').val()+") saturate("+$('input[name="settings_saturate_level_navigation"]').val()+") hue-rotate("+$('input[name="settings_hue_level_navigation"]').val()+"deg) invert("+$('input[name="settings_invert_level_navigation"]').val()+") brightness("+$('input[name="settings_brightness_level_navigation"]').val()+") contrast("+$('input[name="settings_contrast_level_navigation"]').val()+");";$(".visible-xs.mobile-menu-toggler").attr("style","position: fixed;"+t),$("aside, .visible-xs.mobile-menu-toggler").attr("style","z-index: 10; overflow: visible; transform: translate("+settings_leftmenu_width+"px, 0px);"+t),$('code[data-name="'+$(this).attr("name")+'"]').text($(this).val()),theme_config_update()}),g.each(function(e,t){$('code[data-name="'+$(this).attr("name")+'"]').text($(this).val()),$(this).parent().parent("td").parent("tr.atshover").addClass("hidden settings_navigation_color_rows hidden-skip"),0===e&&$(this).parent().parent("td").parent("tr.atshover").prev("tr").addClass("hidden-dependent-skip")}),setTimeout(function(){$(".mobile-menu-toggler:visible").length&&$('input[name="settings_leftmenu_width"]').prop("disabled",!0)},100);var m=$('input[name="settings_leftmenu_width"]');m.on("click keyup change",function(e){page_adjust($(this).val(),$(this).val()),$('code[data-name="'+$(this).attr("name")+'"]').text($(this).val()),theme_config_update(),settings_leftmenu_width_initial=$(this).val()}),$('input[name="settings_navigation_always_collapse"]').change(function(e){l($(this)),"true"==$(this).val()?($("html").attr("data-navigation-collapsed",1),$(".mobile-menu-toggler").removeClass("visible-xs"),plugins.navigation.collapse()):"false"==$(this).val()&&($("html").attr("data-navigation-collapsed",0),$(".mobile-menu-toggler").addClass("visible-xs")),setTimeout(function(){page_resized()},10)}),l(),m.each(function(){$('code[data-name="'+$(this).attr("name")+'"]').text($(this).val()),settings_leftmenu_width_initial=$(this).val()}),"restored"==v___location_query&&(g.trigger("click"),m.trigger("click"),$('select[name="settings_navigation_color"], select[name="settings_background_color"]').trigger("change")),$("aside ul.user-html li.user-html-string").html($('input[name="settings_leftmenu_user_html"]').val()),$('input[name="settings_leftmenu_user_html"]').keyup(function(){$("aside ul.user-html li.user-html-string").html($(this).val())}),plugins.navigation.switch.dashboard.get()&&$('input[name="settings_sysinfo_link_mini"]').parent().parent().parent().parent("tr").remove(),$('input[name^="settings_leftmenu_netdata_link"], input[name^="settings_leftmenu_user_html_only_for_administrator"], input[name="settings_sysinfo_real_time_timeout"], input[name="settings_sysinfo_real_time_status_disk"], input[name="settings_sysinfo_easypie_charts_size"], input[name="settings_sysinfo_easypie_charts_width"], input[name="settings_sysinfo_easypie_charts_scale"], input[name="settings_show_theme_configuration_for_admins_only"]').parents("td.col_value.atscontent").parent("tr.atshover").addClass("settings_option_padded"),$('input[data-role="tagsinput"]').tagsinput(),$("body").css("overflow","auto"),$.getScript(v___location_prefix+"/unauthenticated/js/detector."+v___source_type+".js?"+v___theme_version_plain,function(){var e=new Detector;$.each($('select[name="settings_font_family"] option'),function(){var t=$(this).text();e.detect(t)||"system-default"==$(this).val()||$(this).attr("disabled","disabled").text(t+" ("+theme_language("theme_xhred_global_not_available")+")")}),$('select[name="settings_font_family"]').on("keyup change",function(e){var t=$(this).val(),i=($.merge($("head"),$("head")),$("head").find('link[href*="font-"]').add($("head").find('link[href*="font-"]')).add($("head").find('link[href*="fonts-roboto"]')).add($("head").find('link[href*="fonts-roboto"]'))),a=$.merge($("head").find('link[href*="/authentic."]'),$("head").find('link[href*="/authentic."]')),a=a.length?a:$.merge($("head").find('link[href*="/bundle."]'),$("head").find('link[href*="/bundle."]'));i.remove(),"0"==t||"1"==t?"0"==t&&a.after(''):a.after('')})}).fail(function(e){"canceled"!==e.statusText&&connection_error(e,1)}),$('input[name="settings_leftmenu_netdata"]').on("change",function(){var e=$('input[name="settings_leftmenu_netdata_link"]');"true"==$(this).val()?e.removeAttr("disabled"):e.attr("disabled","disabled")}),$('input[name="settings_leftmenu_netdata"]:checked').trigger("change"),$(".right-side-tabs-toggler").length||($('input[name="settings_side_slider_enabled"][value="false"]').trigger("click"),$('input[name="settings_side_slider_enabled"]').attr("disabled","disabled")),page_resized(),$('input[name="settings_show_webmin_tab"]').parents("td").parent("tr").addClass("hidden"),$('[data-toggle="popover"]').popover({sanitize:!1});var v=$('textarea[name="settings_leftmenu_custom_links"]'),b=v.val();v.length&&v.val(Convert.htmlDecode(b).replace(///g,"/"));$('form[action*="settings.cgi"] textarea').on("input",function(e){void 0!==e.originalEvent&&theme_config_controls(1)})}})});var ev_click_atsettings="#atsave:not(.btn-inverse):not(.disabled)";$("body").undelegate("#atsave:not(.btn-inverse):not(.disabled)","click"),$("body").on("click","#atsave:not(.btn-inverse):not(.disabled)",function(e){e.preventDefault();var t=$(this);spinnerfy_buttons(t,[1.5,-33,"small"]),set_onbeforeunload_status(0,0),theme_config_update(),theme_config("save"),core.updateModuleData("/webmin/edit_startpage.cgi","/webmin/change_startpage.cgi",{gotomodule:$.trim($('select[name="goto_webmin_default_module"]').val())}),setTimeout(function(){$.ajax({type:"POST",url:v___location_prefix+"/index.cgi?xhr-settings=1&save=1",data:core.get_global_vars(["settings_"],1),dataType:"text",success:function(e){if(Test.strContains(e,v___page_signin_form))return void(v___available_session=0);plugins.navigation.reload(),theme_config_controls(0),despinnerfy_buttons(0,t),settings_sysinfo_real_time_status?"object"==typeof stats?(stats.general.timeout=settings_sysinfo_real_time_timeout,stats.general.query()):load.bundle(v___server_extensions_path+"/stats/stats",0,["stats.general.timeout = settings_sysinfo_real_time_timeout","stats.general.query()"]):"object"==typeof stats&&stats.general.kill()},error:function(){t.addClass("btn-danger").removeClass("btn-success btn-inverse opacity-0_5")}})},1e3)})}var theme_control_pages=v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-editor_read.cgi"||v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-logos.cgi"||v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-backgrounds.cgi";if($is_history_action||!theme_control_pages&&!core.curModuleFile("webmin","edit_themes.cgi")||plugins.navigation.reset(),!$is_history_action&&theme_control_pages){check_location_resource("/settings-logos.cgi?saved=1")&&$.each($(".file_chooser_button_preview:first"),function(){$(this).hasClass("disabled")?$("aside + .__logo").remove():matchMedia("(max-width: 1080px)").matches||($("aside + .__logo").length?($(".__logo img").attr("src",$("[data-image-lga]").attr("data-image")),$("aside + .__logo").attr("style","transform: translate(0px, 0px);"), setTimeout(function(){$(".__logo").transition({y:"-140px"},1200)},400)):($("aside").after(''),setTimeout(function(){$(".__logo").transition({y:"-140px"},1200)},400)))});var ev_click_atsettings2=".authentic_update:not(.disabled), .page_footer_ajax_submit:not(.disabled)";$("body").undelegate(ev_click_atsettings2,"click"),$("body").on("click",ev_click_atsettings2,function(){spinnerfy_buttons($(this),[1.5,-28,"small",!1])}),setTimeout(function(){v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-editor_read.cgi"&&$(".end_submits").parent("td").after(' '+theme_language("theme_xhred_settings_right_theme_bgs")+' '+theme_language("theme_xhred_settings_right_theme_logos")+" '+theme_language("theme_xhred_global_save")+" ")}},1300)},10)}if($is_history_action||v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"settings-logos.cgi"&&v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"settings-backgrounds.cgi"||($(function(){function e(e){void 0===e&&(e=i);var t=["authenticated_logo_file","authenticated_bg_file"];"1"!=e.val()?$.each(t,function(e,t){$('input[name="'+t+'"]').parents(".file-input-wrapper").addClass("disabled").prev(".file_chooser_button_preview").addClass("disabled")}):$.each(t,function(e,t){$('input[name="'+t+'"]').parents(".file-input-wrapper").removeClass("disabled"),"1"==a&&$('input[name="'+t+'"]').parents(".file-input-wrapper").prev(".file_chooser_button_preview").removeClass("disabled")})}function t(e){void 0===e&&(e=n);var t=["unauthenticated_logo_file","unauthenticated_bg_file"];"1"!=e.val()?$.each(t,function(e,t){$('input[name="'+t+'"]').parents(".file-input-wrapper").addClass("disabled").prev(".file_chooser_button_preview").addClass("disabled")}):$.each(t,function(e,t){$('input[name="'+t+'"]').parents(".file-input-wrapper").removeClass("disabled"),"1"==n&&$('input[name="'+t+'"]').parents(".file-input-wrapper").prev(".file_chooser_button_preview").removeClass("disabled")})}var i=$('input[name="authenticated_logo"]:checked, input[name="authenticated_bg"]:checked'),a=i.val(),n=$('input[name="unauthenticated_logo"]:checked, input[name="unauthenticated_bg"]:checked');n.val();e(),$('input[name="authenticated_logo"], input[name="authenticated_bg"]').on("change",function(){e($(this))}),t(),$('input[name="unauthenticated_logo"], input[name="unauthenticated_bg"]').on("change",function(){t($(this))})}),$(".file_chooser_button_preview").on("mouseout",function(e){$(this).css("background","white")}).on("mouseover",function(e){$(this).css("background","#eee")}),$.each($(".file_chooser_button_preview"),function(){$(this).data("image")&&$(this).popover({trigger:"hover",sanitize:!1,html:!0,content:function(){return""}})})),$("#system-status > div.panel-body > table > tbody > tr > td").on("mouseover",function(){$(this).find(".btn-hidden").removeClass("hidden")}).on("mouseout",function(){$(this).find(".btn-hidden").addClass("hidden")}),core.curModule("bind8")){var $table_data_recursive_tree=$(".container-fluid table[data-recursive_tree]");$table_data_recursive_tree.length&&($table_data_recursive_tree.removeClass().addClass("table table-hover"),$.each($table_data_recursive_tree.find('img[src*="images/"]'),function(e,t){var i=$(this);Test.strContains(i.attr("src"),"close")&&i.replaceWith(''),Test.strContains(i.attr("src"),"open")&&i.replaceWith(''),Test.strContains(i.attr("src"),"smallicon")&&i.replaceWith('')}))}if((core.curModule("software")&&(Test.strContains(v___location_file,"tree.cgi")||Test.strContains(v___location_file,"ipkg-tree.cgi"))||core.curModuleFile("cluster-software","edit_host.cgi"))&&($('img[src*="images/"]').each(function(e,t){var i=$(this);i.next("a").removeClass(),Test.strContains(i.attr("src"),"close")&&i.replaceWith(''),Test.strContains(i.attr("src"),"open")&&i.replaceWith(''),Test.strContains(i.attr("src"),"pack")&&i.replaceWith('')}),Test.strContains(v___location_file,"ipkg-tree.cgi")&&$('form[action*="ipkg-tree.cgi"] + script + p > a, form[action*="ipkg-tree.cgi"] + script + p + table +p > a').addClass("margined-top-10")),(core.curModule("mysql")||core.curModule("postgresql"))&&($('a > img[src*="images/left.gif"]').each(function(e,t){$(this).replaceWith('')}),$('a > img[src*="images/right.gif"]').each(function(e,t){$(this).replaceWith('')})),core.curModuleFile("virtual-server","list_scripts.cgi")&&($('td > a > img[src*="images/staroff.gif"]').each(function(e,t){$(this);$(t).attr("src",v___location_prefix+"/images/staroff.gif")}),$('td > a > img[src*="images/staron.gif"]').each(function(e,t){$(this);$(t).attr("src",v___location_prefix+"/images/staron.gif")})),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"status/"&&($('td img[src*="images/up.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/check.png"),i.addClass("scale-08")}),$('td img[src*="images/down.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/cross.png"),i.addClass("scale-08")}),$('td img[src*="images/not.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/not.png"),i.addClass("scale-08")})),$('.ui_form[action^="delete_mons"] tr.ui_checked_columns > td > label > img[src="images/up.gif"]:not(".ui_icon_protected"), .ui_form[action^="save_mon"] img[src="images/up.gif"]:not(".ui_icon_protected"), table.ui_buttons_table > tbody > tr.ui_buttons_row > td.ui_buttons_label > img[src="images/up.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/check.png"),i.addClass("scale-08")}),$('.ui_form[action^="delete_mons"] tr.ui_checked_columns > td > label > img[src="images/down.gif"]:not(".ui_icon_protected"), .ui_form[action^="save_mon"] img[src="images/down.gif"]:not(".ui_icon_protected"), table.ui_buttons_table > tbody > tr.ui_buttons_row > td.ui_buttons_label > img[src="images/down.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/cross.png"),i.addClass("scale-08")}),$('.ui_form[action^="delete_mons"] tr.ui_checked_columns > td > label > img[src="images/not.gif"]:not(".ui_icon_protected"), .ui_form[action^="save_mon"] img[src="images/not.gif"]:not(".ui_icon_protected"), table.ui_buttons_table > tbody > tr.ui_buttons_row > td.ui_buttons_label > img[src="images/not.gif"]:not(".ui_icon_protected")').each(function(e,t){var i=$(this);$(t).attr("src",v___location_prefix+"/images/not.png"),i.addClass("scale-08")}),(core.curModule("proc")||core.curModule("firewall")||core.curModule("firewall6")||core.curModule("shorewall")||core.curModule("shorewall6")||core.curModuleFile("pam","edit_pam.cgi")||core.curModule("filter"))&&($("td a img[src], td label a img[src]").parents("td").addClass("text-center"),$('td img[src*="images/gap.gif"]').replaceWith(''),$('td a img[src*="images/down.gif"]').replaceWith(''),$('td a img[src*="images/up.gif"]').replaceWith(''),$('td a img[src*="images/after.gif"]').replaceWith(''),$('td a img[src*="images/before.gif"]').replaceWith('')),(core.curModule("squid")||core.curModule("cron"))&&($('td a img[src*="images/movedown.gif"]').replaceWith(''),$('td a img[src*="images/moveup.gif"]').replaceWith('')),core.curModule("cron")&&($('td a img[src*="images/bottom.gif"]').replaceWith(''),$('td a img[src*="images/top.gif"]').replaceWith('')),$("input").each(function(e,t){"images/ok.gif"==$(this).attr("src")&&($(t).attr("src",v___location_prefix+"/"+$(this).attr("src")),$(this).parents("td").attr("style","white-space: nowrap"))}),core.curModule("commands")&&$("body").addClass("custom"),!$is_history_action){if(core.curModuleFile("custom","view.cgi")){var $_t_title=$('form[action="save.cgi"]').find(".table-title"),$_tt=$_t_title.find("tt").detach();$("#headln2c").find("[data-main_title]").after("
    "+$_tt[0].outerHTML+"
    "),$_t_title.remove()}if($.each($("form > table"),function(){$(this).next('input[type="submit"]')&&$(this).attr("style")}),$.each($("table tr"),function(){$(this).is(":empty")&&$(this).remove()}),$.each($("span > input"),function(){var e=$(this).parent("span").next(".chooser_button"),t=$(this).parent("span").next('input[type="button"][onclick]');$(this).parent("span").next("select");e&&e.attr("style","display: inline; width:40px; height: 28px; margin-right:0 !important; margin-top:4px !important;").find("i.fa-files-o").css("margin-top","0").addClass("vertical-align-middle"),$(this).parents(".tab-content")&&e.css("margin-top","4px"),t&&(t.attr("style","display: inline; width:40px; height: 28px; margin-right:0 !important; vertical-align: middle").next("i.fa-files-o").css("margin-top","11px").addClass("vertical-align-middle"),t.attr("style","display: inline; width:40px; height: 28px; margin-right:0 !important; vertical-align: middle").next("i.fa-calendar").attr("style","margin-top: 21px !important; font-size: 11px; margin-left: -27px; pointer-events: none;"))}),$.each($('input[type="button"][onclick^="ifield"]'),function(e,t){$(this).css("margin-left","0").css("width","40px").css("height","28px")}),$('.ui_form[action="switch.cgi"] > input.form-control.ui_textbox').next('input[type="button"][onclick^="ifield"]').attr("style","margin-top: 2px !important; margin-bottom: 2px !important; margin-left: 0 !important"),setTimeout(function(){$('.ui_form[action="switch.cgi"] .file_chooser_button_attached').attr("style","font-size: 11px; pointer-events: none; margin-top: 14px !important;")},10),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"cshrc/"&&$("textarea").each(function(e,t){$(this).attr("style","height: 20em !important")}),v___location_path!=v___location_prefix+"/acl/"&&v___location_path!=v___location_prefix+"/acl/edit_user.cgi"||$('.ui_grid_table.table-hardcoded .ui_grid_row .ui_grid_cell input[type="checkbox"], .table-hardcoded .col_value input[type="checkbox"]').each(function(e,t){$(this).attr("style","vertical-align: bottom !important")}),core.curModule("custom")||core.curModule("commands")){$(".panel-body > .ui_grid_table.table-hardcoded").each(function(e,t){$(this).attr("style","margin-top: 3px !important")}),$(".panel-body td > .ui_form").each(function(){$(this).attr("style","padding-top: 0 !important")}),$(".panel-body > a.ui_link").each(function(e,t){$(this).addClass("btn btn-inverse btn-tiny ui_link_replaced").removeClass("ui_link"),$(this).text($(this).text().replace(/\.$/,"")),$(this).parent().contents().filter(function(){return 3==this.nodeType}).remove(),0===$(this).attr("href").indexOf("edit_cmd.cgi?new")&&$(this).html(' '+$(this).text()),0===$(this).attr("href").indexOf("edit_file.cgi?new")&&$(this).html(' '+$(this).text()),0===$(this).attr("href").indexOf("edit_sql.cgi?new")&&$(this).html(' '+$(this).text())}),$.each($("td[data-td-e] > .ui_links_row"),function(){var e=$(this).parent();e.find('a[href^="edit_"]').addClass("ui_link_replaced btn btn-xxs btn-transparent btn-link-bordered f__lnk_t_btn-el").css("margin-right","3px").removeClass("ui_link").prepend(' '),e.parents("table").find("thead > tr > th:eq(2)").addClass("pointer-events-none")}).promise().done(function(){$(this).is(".ui_links_row")&&$(this).contents().unwrap()}),$.each($("td.col_value.col_header > .ui_links_row"),function(){}).promise().done(function(){$(this).is(".ui_links_row")&&$(this).contents().unwrap()}),theme_buttonify(["/custom/","/custom/index.cgi","/commands/","/commands/index.cgi"],".container-fluid table td[data-td-e]:nth-child(3)",'a[href^="form.cgi"]',"btn btn-primary btn-xxs vertical-align-top margined-top-1 margined-left--2 ---forced","fa-cog","","","","|"),theme_buttonify(["/custom/","/custom/index.cgi","/commands/","/commands/index.cgi"],".container-fluid table td[data-td-e]:nth-child(3)",'a[href^="run.cgi"], a[href^="sql.cgi"]',"btn btn-success btn-xxs vertical-align-top margined-top-1 margined-left--2 ---forced","fa-play fa-0_85x","","","","|"),theme_buttonify(["/custom/","/custom/index.cgi","/commands/","/commands/index.cgi"],".container-fluid table td[data-td-e]:nth-child(3)",'a[href^="view.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 margined-left--2 ---forced","fa-pencil-square-o","","","","|"),theme_buttonify(["/custom/","/custom/index.cgi","/commands/","/commands/index.cgi"],".container-fluid table td[data-td-e]:nth-child(3)",'a[href^="sqlform.cgi"]',"btn btn-info btn-xxs vertical-align-top margined-top-1 margined-left--2 ---forced","fa-cog","","","","|"),theme_buttonify(["/custom/","/custom/index.cgi"],".container-fluid table.ui_grid_table td:last-child",'a.ui_link[href^="edit_"]',"btn btn-default btn-transparent btn-transparent-link btn-xxs vertical-align-top margined-top-1 margined-right-5 pull-right btn-dnwo ---forced","fa-pencil","","","","|"),$('body[class*="custom"] table.ui_grid_table tr td > form .table-responsive table tr:first-child td.col_header button.ui_submit').prepend(''),$.fn.mytxtW=function(e,t){return $.fn.mytxtW.fakeEl||($.fn.mytxtW.fakeEl=$("").hide().appendTo(document.body)),$.fn.mytxtW.fakeEl.text(e||this.val()||this.text()||this.attr("placeholder")).css("font",t||this.css("font")),$.fn.mytxtW.fakeEl.width()+2},$('table.ui_grid_table td input[type="text"], table.ui_grid_table td input[type="password"], table.ui_grid_table td textarea').on("input",function(){var e=$(this).mytxtW()+15;$(this).attr("type"),$(this).css({width:e})}).trigger("input");var is_two_columns=$(".sub_table_container").first().find('td[colspan="4"]').length?0:1,$empty_cells=$("table.ui_grid_table tbody tr.ui_grid_row td.ui_grid_cell");$.each($empty_cells,function(){var e=$(this).html();("
    "==e||e.length<10)&&$(this).remove(),is_two_columns&&($(this).addClass("no-contents"),$(this).parent("tr").addClass("no-contents"))})}if(check_current_file("config.cgi")&&v___location_query&&v___location_query.includes("custom")&&$('[name="width_def"], [name="height_def"], [name="wrap"]').parent().parent("td").parent("tr").addClass("hidden"),snippets.page.render_links($is_history_action),v___location_path==v___location_prefix+"/fdisk/edit_disk.cgi"){var __delete=[];$.each($(".panel-body > table.table.table-striped tbody tr"),function(e,t){($(this).find("td:nth-child(3)").find('img[src*="images/use"]').length||$(this).find("td:nth-child(3)").find('img[src*="images/gap"]').length)&&($(this).find("td:nth-child(3)").remove(),__delete.push(e))}),$.isEmptyObject(__delete)||($(".panel-body > table.table.table-striped thead").find("th:nth-child(3)").remove(),delete __delete)}v___location_path==v___location_prefix+"/virtual-server/edit_link.cgi"&&$(".table-hardcoded").find('input[name="open"]').parent("td").parent("tr").remove(),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"init/"&&$('.table.table-striped.table-condensed tr.tr_tag td[data-td-e] input[type="checkbox"]').each(function(e,t){$(this).attr("style","vertical-align: middle !important")}),v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"proc/edit_proc.cgi"&&$("#signal").attr("style","margin-bottom: 0 !important;"),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"procmail/"&&($(".panel-body p:first-child").next("p").contents().filter(function(){return 3==this.nodeType}).remove(),$(".panel-body p:last-child").prev("a.ui_link").remove()),v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"cron/"&&v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"cron/index.cgi"||$('.panel-body form.ui_form[action="index.cgi"]').next("script").next("b").next("p").contents().filter(function(){return 3==this.nodeType}).remove(),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"filter/"&&$(".panel-body > b").next("p").contents().filter(function(){return 3==this.nodeType}).remove(),v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"dhcpd/"&&$(".panel-body > p").contents().filter(function(){return 3==this.nodeType}).remove(),v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"htaccess-htpasswd/"&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"forward/"||$("td table.table-hardcoded.table.table-subtable").removeClass("table-striped"),$(".ui_buttons_hr > td > table.table-hardcoded > tbody > tr > td[nowrap]").each(function(){$(this).parents("table").attr("style","margin-bottom: 15px !important")}),$("textarea.form-control.ui_textarea").next('button[type="button"].btn-default').each(function(){$(this).prev("textarea").attr("style","margin-bottom: 1px !important"),$(this).attr("style","width:100% !important; padding-top: 0; height:28px !important")}),$("textarea.form-control.ui_textarea").next("br").next('button[type="button"].btn-default').each(function(){$(this).prev("textarea").attr("style","margin-bottom: 1px !important"),$(this).attr("style","width:100% !important; padding-top: 0; height:28px !important")}),$(".table-hardcoded > tbody > tr > td > input.form-control.ui_textbox").next('button[type="button"].ui_button').each(function(){$(this).attr("style","margin-top: 2px !important")}),$(".table-hardcoded > tbody > tr > td.col_label b a, .ui_table_row td a").each(function(e,t){$(this).attr("href")||$(this).attr("style","color: #333; text-decoration: none; cursor:default")}),$('input[name="all_weekdays"], .ui_grid_cell > table.table-condensed, table.table-hardcoded table.table-condensed, select[multiple][name="days"]').each(function(){$(this).parent("td").attr("style","vertical-align: top !important; padding-left:2px; padding-right:2px;")}),$('input[type="submit"]').each(function(){$(this).addClass("btn btn-default")}),$("table tr th").each(function(){$(this).text()&&$(this).attr("style","width: auto")}),$("table thead th:not(.table-title)").each(function(){$(this).css("border-top","none"),$(this).css("border-bottom","none")}),$("body").attr("class")&&$("body").attr("class").indexOf(v___module_file_manager)>-1&&(!$("body").hasClass("file-manager")&&$("body").addClass("file-manager"),$("#headln2l").prepend("'));var $table_header_links=$(".panel-heading > table.header > tbody > tr > td > a");$.each($table_header_links,function(){if($(this).attr("href")&&$(this).attr("href").indexOf("config.cgi")>-1||$(this).attr("href").indexOf("man/search.cgi")>-1||$(this).attr("href").indexOf("/index.cgi")>-1||$(this).attr("href")==v___location_directory_trail_slashed||$(this).attr("href").indexOf("index.cgi")>-1&&v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"openvpn/"||$(this).attr("href").indexOf("index.cgi?")>-1&&v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"spam/"||$(this).attr("href").indexOf("restart_zone.cgi")>-1||$(this).attr("href").indexOf("restart.cgi")>-1||$(this).attr("href").indexOf("apply.cgi")>-1||$(this).attr("href").indexOf("start.cgi")>-1||$(this).attr("href").indexOf("stop.cgi")>-1||"//"==$(this).attr("href")&&(v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-editor_read.cgi"||v___location_path_lead_unslashed==v___location_prefix_unslashed_trail_slashed+"settings-logos.cgi")||$(this).attr("href").indexOf("delete_")>-1||$(this).attr("href").indexOf("list_mail.cgi")>-1||$(this).attr("href").indexOf("/virtual-")>-1||$(this).attr("href").indexOf("/virtualmin-")>-1||$(this).attr("href").indexOf("/server-")>-1||$(this).attr("href").indexOf("help.cgi")>-1){if($.each($(this).next("br"),function(){$(this).remove()}),$.each($(this).prev("br"),function(){$(this).remove()}),$(this).attr("href").indexOf("help.cgi")>-1){var e=$(this),t=$(this).parent("td");$(this).remove(),t.append(e)}$(this).attr("href").indexOf("/index.cgi")>-1||$(this).attr("href")==v___location_directory_trail_slashed||$(this).attr("href").indexOf("/virtual-")>-1||$(this).attr("href").indexOf("/virtualmin-")>-1||$(this).attr("href").indexOf("/server-")>-1?($iconized_class="fa-arrow-left",$(this).data("title","").data("back",1)):"//"!=$(this).attr("href")||v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"settings-editor_read.cgi"&&v___location_path_lead_unslashed!=v___location_prefix_unslashed_trail_slashed+"settings-logos.cgi"?$(this).attr("href").indexOf("config.cgi")>-1?($iconized_class="fa-cog",$(this).data("title","")):$(this).attr("href").indexOf("restart.cgi")>-1||$(this).attr("href").indexOf("apply.cgi")>-1?$iconized_class="fa-refresh":$(this).attr("href").indexOf("restart_zone.cgi")>-1?$iconized_class="fa-retweet":$(this).attr("href").indexOf("start.cgi")>-1?$iconized_class="fa-play":$(this).attr("href").indexOf("stop.cgi")>-1?$iconized_class="fa-square":$(this).attr("href").indexOf("man/search.cgi")>-1?$iconized_class="fa-search":$(this).attr("href").indexOf("delete_")>-1?$iconized_class="fa-trash-o":$(this).attr("href").indexOf("list_mail.cgi")>-1?$iconized_class="fa-inbox":$(this).attr("href").indexOf("index.cgi")>-1&&v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"openvpn/"?$iconized_class="fa-cogs":$(this).attr("href").indexOf("index.cgi?")>-1&&v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"spam/"&&($iconized_class="fa-arrow-left",$(this).data("back",1)):($iconized_class="fa-arrow-left",$(this).attr("href",v___location_prefix+"/webmin/edit_themes.cgi").data("title","").data("back",1));var i=$(this).attr("href").indexOf("help.cgi")>-1;i&&($iconized_class="fa-question-circle",$(this).data("title",""));var a=Convert.strUpInitial(i?theme_language("theme_xhred_global_help"):1===$(this).data("back")?core.curModule(v___module_file_manager)?"":theme_language("theme_xhred_global_return_to_module_index"):$(this).text());$(this).data("toggle","tooltip").data("title",a).attr("data-container","body").addClass("btn btn-link text-lighter").removeClass("ui_link").append(''),$(this).attr("aria-label",a),$(this).contents().filter(function(){return 3==this.nodeType}).remove(),$(this).tooltip({container:"body",placement:"auto top",trigger:"hover",delay:{show:600,hide:30}}),((v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"apache/"||v___location_directory_unslashed_trail_slashed==v___location_prefix_unslashed_trail_slashed+"proftpd/")&&($(this).attr("href").indexOf("restart.cgi")>-1||$(this).attr("href").indexOf("apply.cgi")>-1)||$(this).parent("td").find("a")&&1==$(this).parent("td").find("a").length||$(this).attr("href").indexOf("man/search.cgi")>-1||$(this).attr("href").indexOf("config.cgi")>-1||$(this).attr("href").indexOf("/index.cgi")>-1||$(this).attr("href").indexOf("/index.cgi")>-1||$(this).attr("href").indexOf("/virtual-")>-1||$(this).attr("href").indexOf("/virtualmin-")>-1||$(this).attr("href").indexOf("/server-")>-1)&&(($(this).attr("href").indexOf("/index.cgi")>-1||$(this).attr("href").indexOf("config.cgi")>-1)&&$("body").attr("class")&&$("body").attr("class").indexOf(v___module_file_manager)>-1?$(this).attr("style","margin-right: 0 !important; padding: 6px 12px"):$(this).attr("style","margin-right: 0 !important"))}$("#headln2l").removeClass("invisible")}),$.each($('td.ui_grid_cell:contains("|")'),function(){$(this).contents().filter(function(){return 3==this.nodeType}).remove()}),$('a[href*="help.cgi"][onclick], a[href*="help.cgi/"], a[href*="showpass.cgi?"][onclick]').attr("onclick","").unbind("click").addClass("help_popup"),$(".help_popup").each(function(){$(this).attr("style","color: #333; text-decoration: none; cursor:help")})}if(!$is_history_action){if($('select.ui_select[name="days"]').each(function(){$(this).parent("td").attr("style","vertical-align: top !important")}),v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"mailboxes/"&&v___location_path!=v___location_prefix+"/mailboxes/index.cgi"&&v___location_directory_unslashed_trail_slashed!=v___location_prefix_unslashed_trail_slashed+"mailbox/"&&v___location_path!=v___location_prefix+"/postfix/view_mailq.cgi"||(v___location_file?"list_mail.cgi"==v___location_file&&$('.container-fluid input:not([type="checkbox"]), .container-fluid .ui_form_end_submit, .container-fluid select').addClass("heighter-34").removeClass("heighter-28").css("margin-bottom","-1px"):($(".ui_form_end_submit").css("margin-top","0"),$("input#user").addClass("heighter-34 vertical-align-top")),$("body").find("form").removeAttr("onsubmit"),$header_tables=$("body").find('input[name="from"]').parents(".tab-pane").parent("td"),$header_tables.children("table").hide(),$.each($header_tables.find("input, textarea, select"),function(){$(this).hasClass("ui_select")||$(this).attr("onclick")||"checkbox"==$(this).attr("type")||"submit"==$(this).attr("type")||$(this).attr("style","width: 60%").addClass("inline-block"),$(this).attr("onclick")&&$(this).addClass("inline-block")}),onbeforeunload=null,1==$("body").find('input.ui_hidden[name="html_edit"]').val()&&editor_html_init(["body",2,!1,"edit_web"],"basic"),$("body").find('input[name="from"]').parents(".tab-pane").prev("table").remove(),$("body").find('input[name="from"]').parents(".tab-pane ").parent("td").find("div, table").each(function(e,t){$(this).find(".col_label").css("width","20%"),$(this).find('input[name="subject"]').parent("td").prev("td").find("b").attr("style","font-size: 13px !important"),$(this).find('input[name="subject"]').parents("table").show(),$(this).find('input[name="subject"]').parent("td").find(".submitter").remove()}),$editor_mode_link_container=$("body").find('textarea[id="body"]').parents("table").find("thead > tr > th:last-child"),$editor_mode_link=$editor_mode_link_container.find("a").addClass("editor_mode_link"),$editor_mode_link_container.parent("tr").find("th:first-child").append($editor_mode_link),$editor_mode_link_container.remove(),$editor_mode_link_button=$("body").find('textarea[id="body"]').parents("table").find(".editor_mode_link"),$editor_mode_link_button_state=!!$editor_mode_link_button.attr("href")&&$editor_mode_link_button.attr("href").indexOf("html=0"),$editor_mode_link_button.attr("title",$editor_mode_link_button.text()).addClass("editor_mode_link_button pull-right btn btn-sm "+($editor_mode_link_button_state==-1?"btn-success":"btn-primary")).html(' '),$("body").find('textarea[id="body"]').parents("table").find("thead > tr > th").find("b").css("padding-left","45px"),$(".editor_mode_link_button").tooltip(),$fileinput_container=$("body").find('a[onclick="return add_ss_attachment()"]'),$fileinput_container.parent("td").contents().filter(function(){return 3==this.nodeType}).remove(),$fileinput_container.remove(),$fileinput_add_another_attachment=$("body").find('a[onclick="return add_attachment()"]'),$fileinput_add_another_attachment.addClass("btn btn-default"),$fileinput_add_another_attachment.text($fileinput_add_another_attachment.text().replace(/\.$/,"")),(v___location_path.indexOf("view_mail.cgi")>-1||v___location_path.indexOf("view_mailq.cgi")>-1)&&($table_title_header_container=$(".ui_form").find("div.table-responsive").first().find(".table-title"),$table_title_links_container=$table_title_header_container.next(),$table_title_links_container.contents().filter(function(){return 3==this.nodeType}).remove(),$table_title_links_container.find("a").removeClass("btn-inverse").parent(".ui_links_row").contents().unwrap(),$table_title_links_container.find("a").addClass("table_title_links pull-right btn btn-info btn-tiny"),$table_title_links=$table_title_links_container.html(),$table_title_header_container.append($table_title_links),$table_title_links_container.remove(),$table_title_header_container_text_padding=35,$(".table-title > a.table_title_links").each(function(){$table_title_header_container_text_padding=v___location_path==v___location_prefix+"/postfix/view_mailq.cgi"?120:235}),$(".table_title_links_container a").each(function(){$table_title_header_container_text_padding+=$(this).width()}),$table_title_header_container.find("b").css("padding-left",$table_title_header_container_text_padding),$table_title_second_container=$(".ui_form").find("div.table-responsive").first().next("div.table-responsive").find("table:first-child"),$table_title_header_container=$(".ui_form").find("div.table-responsive").first().next("div.table-responsive").find("th:first-child"),$table_title_links_container=$(".ui_form").find("div.table-responsive").first().next("div.table-responsive").find("th:last-child"), diff --git a/unauthenticated/js/bundle.min.js.gz b/unauthenticated/js/bundle.min.js.gz index a9e29ee33..13cc38135 100644 Binary files a/unauthenticated/js/bundle.min.js.gz and b/unauthenticated/js/bundle.min.js.gz differ