"use strict";function_classCallCheck(a,b){if(!(ainstanceofb))thrownewTypeError("Cannot call a class as a function")}function_defineProperties(a,b){for(varc,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"inc&&(c.writable=!0),Object.defineProperty(a,c.key,c)}function_createClass(a,b,c){returnb&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),a}(function(){'use strict';vara=/*#__PURE__*/function(){functiona(){_classCallCheck(this,a)}return_createClass(a,[{key:"forEach",value:functionforEach(a,b){a=a||[];for(varc=0;c<a.length;c++)b(a[c])}},{key:"getScrollTop",value:functiongetScrollTop(){returndocument.documentElement&&document.documentElement.scrollTop||document.body.scrollTop}},{key:"isMobile",value:functionisMobile(){returnwindow.matchMedia("only screen and (max-width: 680px)").matches}},{key:"isTocStatic",value:functionisTocStatic(){returnwindow.matchMedia("only screen and (max-width: 960px)").matches}}]),a}(),b=/*#__PURE__*/function(){functionb(){_classCallCheck(this,b),this.util=newa,this.newScrollTop=this.util.getScrollTop(),this.oldScrollTop=this.newScrollTop,this.scrollEventSet=newSet,this.resizeEventSet=newSet}return_createClass(b,[{key:"initMenuMobile",value:functioninitMenuMobile(){vara=document.getElementById("menu-toggle-mobile"),b=document.getElementById("menu-mobile");this._menuMobileOnScroll=this._menuMobileOnScroll||function(){a.classList.remove("active"),b.classList.remove("active")},this.util.isMobile()?(a.onclick=function(){a.classList.toggle("active"),b.classList.toggle("active")},this.scrollEventSet.add(this._menuMobileOnScroll)):this.scrollEventSet.delete(this._menuMobileOnScroll)}},{key:"initSwitchTheme",value:functioninitSwitchTheme(){vara=this;this.util.forEach(document.getElementsByClassName("theme-switch"),function(b){b.onclick=function(){document.body.classList.toggle("dark-theme"),window.isDark=!window.isDark,window.localStorage&&window.localStorage.setItem("theme",window.isDark?"dark":"light"),a.initEcharts()}})}},{key:"initHighlight",value:functioninitHighlight(){this.util.forEach(document.querySelectorAll(".highlight > .chroma"),function(a){varb=a.querySelectorAll("pre.chroma > code"),c=b[b.length-1],d=c?c.className.toLowerCase():"";a.className+=" "+d}),this.util.forEach(document.querySelectorAll(".highlight > pre.chroma"),function(a){varb=document.createElement("div");b.className=a.className;varc=document.createElement("table");b.appendChild(c);vard=document.createElement("tbody");c.appendChild(d);vare=document.createElement("tr");d.appendChild(e);varf=document.createElement("td");e.appendChild(f),a.parentElement.replaceChild(b,a),f.appendChild(a)})}},{key:"initTable",value:functioninitTable(){this.util.forEach(document.querySelectorAll(".content table"),function(a){varb=document.createElement("div");b.className="table-wrapper",a.parentElement.replaceChild(b,a),b.appendChild(a)})}},{key:"initHeaderLink",value:functioninitHeaderLink(){for(vara=1;6>=a;a++)this.util.forEach(document.querySelectorAll(".page.single .content > h"+a),function(a){a.classList.add("headerLink"),a.innerHTML="<a href=\"#".concat(a.id,"\" class=\"header-mark\"></a>").concat(a.innerHTML)})}},{key:"initToc",value:functioninitToc(){vara=this,b=document.getElementById("TableOfContents");if(null!==b)if(this.util.isTocStatic()){vark=document.getElementById("toc-content-static");b.parentElement!==k&&(b.parentElement.removeChild(b),k.appendChild(b)),this._tocOnScroll&&this.scrollEventSet.delete(this._tocOnScroll)}else{varl=document.getElementById("toc-content-auto");b.parentElement!==l&&(b.parentElement.removeChild(b),l.appendChild(b));varc=document.getElementById("toc-auto"),d=document.getElementsByClassName("page")[0];c.style.maxWidth="".concat(d.getBoundingClientRect().left-20,"px"),this._tocLinks=this._tocLinks||b.getElementsByTagName("a"),this._tocLis=this._tocLis||b.getElementsByTagName("li"),this._headerLinks=this._headerLinks||document.getElementsByClassName("headerLink")||[];vare="normal"!==window.desktopHeaderMode,f=document.g