From dca97b049776f039fd813a61132ad6368c10215e Mon Sep 17 00:00:00 2001 From: Tilman Date: Sun, 25 Jun 2023 16:59:57 +0200 Subject: [PATCH] commit --- index.twig | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/index.twig b/index.twig index 8eb5083..bad7159 100644 --- a/index.twig +++ b/index.twig @@ -177,13 +177,29 @@ } } + streamBtnActivate(); + setInterval(streamBtnActivate, 10000); + + /* var box = document.getElementById("nav-podcast"); var boxAfter = window.getComputedStyle(box, "::after"); console.log(boxAfter.backgroundColor); // getting the background color console.log(boxAfter.opacity); // getting the background color - - streamBtnActivate(); - setInterval(streamBtnActivate, 10000); + */ + + function menuOpacity() { + const navbar = document.getElementById("navbar"); + let y = navbar.scrollTop; + if (y > 10) { + navbar.style.setProperty('--bs-bg-opacity', 1); + } + else { + navbar.style.setProperty('--bs-bg-opacity', 0); + } + } + + +