2 lines
18 KiB
JavaScript
2 lines
18 KiB
JavaScript
|
(()=>{var e,t;-1<navigator.platform.indexOf("Win")&&(document.getElementsByClassName("main-content")[0]&&(e=document.querySelector(".main-content"),new PerfectScrollbar(e)),document.getElementsByClassName("sidenav")[0]&&(e=document.querySelector(".sidenav"),new PerfectScrollbar(e)),document.getElementsByClassName("navbar-collapse")[0]&&(t=document.querySelector(".navbar:not(.navbar-expand-lg) .navbar-collapse"),new PerfectScrollbar(t)),document.getElementsByClassName("fixed-plugin")[0])&&(t=document.querySelector(".fixed-plugin"),new PerfectScrollbar(t))})(),document.getElementById("navbarBlur")&&navbarBlurOnScroll("navbarBlur");var allInputs,fixedPlugin,fixedPluginButton,fixedPluginButtonNav,fixedPluginCard,fixedPluginCloseButton,navbar,buttonNavbarFixed,tooltipTriggerList=[].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]')),tooltipList=tooltipTriggerList.map(function(e){return new bootstrap.Tooltip(e)});function focused(e){e.parentElement.classList.contains("input-group")&&e.parentElement.classList.add("focused")}function defocused(e){e.parentElement.classList.contains("input-group")&&e.parentElement.classList.remove("focused")}function setAttributes(t,s){Object.keys(s).forEach(function(e){t.setAttribute(e,s[e])})}function sidebarColor(e){var t=document.querySelector(".nav-link.active"),e=e.getAttribute("data-color");t.classList.contains("bg-gradient-primary")&&t.classList.remove("bg-gradient-primary"),t.classList.contains("bg-gradient-dark")&&t.classList.remove("bg-gradient-dark"),t.classList.contains("bg-gradient-info")&&t.classList.remove("bg-gradient-info"),t.classList.contains("bg-gradient-success")&&t.classList.remove("bg-gradient-success"),t.classList.contains("bg-gradient-warning")&&t.classList.remove("bg-gradient-warning"),t.classList.contains("bg-gradient-danger")&&t.classList.remove("bg-gradient-danger"),t.classList.add("bg-gradient-"+e)}function sidebarType(e){for(var t=e.parentElement.children,s=e.getAttribute("data-class"),n=document.querySelector("body"),a=document.querySelector("body:not(.dark-version)"),n=n.classList.contains("dark-version"),i=[],r=0;r<t.length;r++)t[r].classList.remove("active"),i.push(t[r].getAttribute("data-class"));e.classList.contains("active")?e.classList.remove("active"):e.classList.add("active");for(var l,o,c,d=document.querySelector(".sidenav"),r=0;r<i.length;r++)d.classList.remove(i[r]);if(d.classList.add(s),"bg-transparent"==s||"bg-white"==s){var u=document.querySelectorAll(".sidenav .text-white:not(.nav-link-text):not(.active)");for(let e=0;e<u.length;e++)u[e].classList.remove("text-white"),u[e].classList.add("text-dark")}else{var f=document.querySelectorAll(".sidenav .text-dark");for(let e=0;e<f.length;e++)f[e].classList.add("text-white"),f[e].classList.remove("text-dark")}if("bg-transparent"==s&&n){f=document.querySelectorAll(".navbar-brand .text-dark");for(let e=0;e<f.length;e++)f[e].classList.add("text-white"),f[e].classList.remove("text-dark")}"bg-transparent"!=s&&"bg-white"!=s||!a?(o=(l=document.querySelector(".navbar-brand-img")).src).includes("logo-ct-dark.png")&&(c=o.replace("logo-ct-dark","logo-ct"),l.src=c):(o=(l=document.querySelector(".navbar-brand-img")).src).includes("logo-ct.png")&&(c=o.replace("logo-ct","logo-ct-dark"),l.src=c),"bg-white"==s&&n&&(o=(l=document.querySelector(".navbar-brand-img")).src).includes("logo-ct.png")&&(c=o.replace("logo-ct","logo-ct-dark"),l.src=c)}function navbarFixed(e){var t=["position-sticky","blur","shadow-blur","mt-4","left-auto","top-1","z-index-sticky"],s=document.getElementById("navbarBlur");e.getAttribute("checked")?(s.classList.remove(...t),s.setAttribute("navbar-scroll","false"),navbarBlurOnScroll("navbarBlur"),e.removeAttribute("checked")):(s.classList.add(...t),s.setAttribute("navbar-scroll","true"),navbarBlurOnScroll("navbarBlur"),e.setAttribute("checked","true"))}function navbarMinimize(e){var t=document.getElementsByClassName("g-sidenav-show")[0];e.getAttribute("checked")?(t.classList.remove("g-sidenav-hidden"),t.classList.add("g-sidenav-pinned"),e.removeAttribute("checked")):(t.classList.remove("g
|
||
|
//# sourceMappingURL=_site_dashboard_free/assets/js/dashboard-free.js.map
|