import"./vendor.c5f822cb.js";document.addEventListener("DOMContentLoaded",function(){window.innerWidth<992&&(document.querySelectorAll(".navbar .dropdown").forEach(function(e){e.addEventListener("hidden.bs.dropdown",function(){this.querySelectorAll(".submenu").forEach(function(s){s.style.display="none"})})}),document.querySelectorAll(".dropdown-menu a").forEach(function(e){e.addEventListener("click",function(s){let o=this.nextElementSibling;o&&o.classList.contains("submenu")&&(s.preventDefault(),o.style.display=="block"?o.style.display="none":o.style.display="block")})})),window.innerWidth>992&&(document.querySelectorAll(".navbar .nav-item").forEach(function(e){e.addEventListener("mouseover",function(s){let o=this.querySelector("a[data-bs-toggle]");if(o!=null){let d=o.nextElementSibling;o.classList.add("show"),d.classList.add("show")}}),e.addEventListener("mouseleave",function(s){let o=this.querySelector("a[data-bs-toggle]");if(o!=null){let d=o.nextElementSibling;o.classList.remove("show"),d.classList.remove("show")}})}),window.addEventListener("scroll",function(){let e=document.getElementById("head-container").offsetHeight;if(window.scrollY>e){document.getElementById("navbar-main").classList.add("fixed-top");let s=document.getElementById("navbar-main").offsetHeight;document.body.style.paddingTop=s+"px"}else document.getElementById("navbar-main").classList.remove("fixed-top"),document.body.style.paddingTop="0"}))});document.getElementById("navbar-main-search-toggle").addEventListener("click",e=>{e.preventDefault(),document.getElementById("navbar-main-search-toggle").classList.toggle("active"),document.getElementById("navbar-main-menu").classList.toggle("d-none"),document.getElementById("navbar-main-search").classList.toggle("d-none"),document.getElementById("navbar-search-icon-search").classList.toggle("d-none"),document.getElementById("navbar-search-icon-times").classList.toggle("d-none"),document.getElementById("navbar-main-search-input").focus()});(function(){let e=document.getElementById("darkmode-toggler");if(!e)return;function s(){var t=window.matchMedia("(prefers-color-scheme: dark)").matches;return window.localStorage.getItem("kfvuelzenDarkMode")==="yes"?t=!0:window.localStorage.getItem("kfvuelzenDarkMode")==="no"&&(t=!1),t}function o(){var t=s(),n=document.querySelector(".fa-sun"),l=document.querySelector(".fa-moon");t?(document.documentElement.classList.add("is-dark-theme"),document.body.classList.add("is-dark-theme"),n.style.display="block",l.style.display="none"):(document.documentElement.classList.remove("is-dark-theme"),document.body.classList.remove("is-dark-theme"),l.style.display="block",n.style.display="none"),e&&t&&e.setAttribute("aria-pressed","true")}function d(){var t=window.scrollY||document.documentElement.scrollTop,n,l=function(){n=window.scrollY||document.documentElement.scrollTop,n+window.innerHeight*1.5>document.body.clientHeight||n<t?e.classList.remove("hide"):n>t&&250<n&&e.classList.add("hide"),t=n};e&&window.addEventListener("scroll",l)}o(),d();function c(t,n){e.setAttribute("aria-pressed","true"),n.style.display="block",t.style.display="none",document.documentElement.classList.add("is-dark-theme"),document.body.classList.add("is-dark-theme"),document.querySelectorAll(".bg-light").forEach(i=>{i.className=i.className.replace(/-light/g,"-dark")}),document.body.classList.contains("text-dark")?document.body.classList.replace("text-dark","text-light"):document.body.classList.add("text-light");for(var l=document.querySelectorAll("table"),a=0;a<l.length;a++)l[a].classList.add("table-dark");window.localStorage.setItem("kfvuelzenDarkMode","yes"),console.log("INFO","Darkmode: On")}function r(t,n){e.setAttribute("aria-pressed","false"),t.style.display="block",n.style.display="none",document.documentElement.classList.remove("is-dark-theme"),document.body.classList.remove("is-dark-theme"),document.querySelectorAll(".bg-dark").forEach(i=>{i.className=i.className.replace(/-dark/g,"-light")}),document.body.classList.contains("text-light")?document.body.classList.replace("text-light","text-dark"):document.body.classList.add("text-dark");for(var l=document.querySelectorAll("table"),a=0;a<l.length;a++)l[a].classList.contains("table-dark")&&l[a].classList.remove("table-dark");window.localStorage.setItem("kfvuelzenDarkMode","no"),console.log("INFO","Darkmode: Off")}e.addEventListener("click",()=>{var t=document.getElementById("darkmode-toggler"),n=document.querySelector(".fa-sun"),l=document.querySelector(".fa-moon");t.getAttribute("aria-pressed")==="false"?c(l,n):r(l,n)})})();
