--- --- console.log(''); if ("{{ site.removeBootstrapJs }}" === "true") { const languagesModal = document.querySelector("#staticBackdrop"); const intModalBtn = document.querySelector("#int-modal-btn"); const closeBtn = document.querySelector("#close-modal"); if(intModalBtn){ intModalBtn.addEventListener("click", () => { languagesModal.style.display = "block"; languagesModal.classList.add("show"); let modal = document.createElement("div"); modal.classList.add("modal-backdrop", "show"); document.body.appendChild(modal); }); closeBtn.addEventListener("click", () => { languagesModal.style.display = "none"; languagesModal.classList.remove("show"); let modal = document.querySelector(".modal-backdrop"); document.body.removeChild(modal); }); } var mediaQuery = window.matchMedia("(max-width: 768px)") let navbarDropdown = document.querySelector("#navbarDropdown"); let dropmenu = document.querySelector(".dropmenu"); navbarDropdown.addEventListener("click", () => { if (dropmenu.classList.contains("show")) { dropmenu.classList.remove("show"); dropmenu.style.display = "none" } else { dropmenu.classList.add("show"); if (mediaQuery.matches) { dropmenu.style.display = "block" } else { dropmenu.style.display = "grid" dropmenu.style.padding = "3.5rem" dropmenu.style.gridTemplateColumns = "auto auto"; dropmenu.style.columnGap= "5rem"; dropmenu.style.rowGap= "1rem"; dropmenu.style.borderBottom= "1px solid rgba(0, 0, 0, 0.1)" dropmenu.style.borderLeft= "1px solid rgba(0, 0, 0, 0.1)" dropmenu.style.borderRight= "1px solid rgba(0, 0, 0, 0.1)" } } }); const navbarToggler = document.querySelector('.navbar-toggler') const navBar = document.querySelector('#navbarSupportedContent') navbarToggler.addEventListener('click', () => { if (navBar.classList.contains("show")) { navBar.classList.remove("show"); navBar.style.display = "none" } else { navBar.classList.add("show"); navBar.style.display = "block" } }) }