From 1136df09e6362338dd4e5aebeb662e16354262f5 Mon Sep 17 00:00:00 2001 From: sa6anw Date: Thu, 8 May 2025 21:31:22 +0000 Subject: [PATCH] Fix --- docs/index.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/index.md b/docs/index.md index 577715b..0abe07e 100644 --- a/docs/index.md +++ b/docs/index.md @@ -11,6 +11,15 @@ title: Start window.scrollTo({ top: y, behavior: 'smooth' }); } + // Göm knappen vid scroll + window.addEventListener('scroll', () => { + const button = document.getElementById('scrollButton'); + if (window.scrollY > 10) { + button.style.display = 'none'; + } + }); + + - // Göm knappen vid scroll - window.addEventListener('scroll', () => { - const button = document.getElementById('scrollButton'); - if (window.scrollY > 10) { - button.style.display = 'none'; - } - }); - -