From 06d97b61554e7a157f1422217e2a923bd58e23c9 Mon Sep 17 00:00:00 2001 From: maxiwee Date: Tue, 30 Jan 2024 23:33:43 +0100 Subject: [PATCH] Remove unnecessary counter and update button position --- script.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/script.js b/script.js index 61c608b..b573959 100644 --- a/script.js +++ b/script.js @@ -20,8 +20,6 @@ window.onload = function() { button.style.top = y+'px'; } -let counter = 0; // Initialize the counter - document.getElementById('invisblebutton').addEventListener('click', function() { var secretImage = document.getElementById('secretImage'); if (secretImage.style.display === 'block') { @@ -35,8 +33,5 @@ document.getElementById('invisblebutton').addEventListener('click', function() { secretImage.style.position = "absolute"; secretImage.style.left = x+'px'; secretImage.style.top = y+'px'; - - counter++; // Increment the counter - document.getElementById('counter').textContent = counter + ' people have found the secret'; // Update the counter on the website } }); \ No newline at end of file