From bd5f6c104c06f3ab24b874a4305a8e1fe55ee772 Mon Sep 17 00:00:00 2001 From: CodeDevMLH Date: Sun, 24 Nov 2024 23:22:53 +0100 Subject: [PATCH] working --- add_to_index_html.html | 30 ++++++++++++++---------------- snowflakes.js | 6 +++++- 2 files changed, 19 insertions(+), 17 deletions(-) diff --git a/add_to_index_html.html b/add_to_index_html.html index 85f4bb0..b0ca41f 100644 --- a/add_to_index_html.html +++ b/add_to_index_html.html @@ -1,18 +1,16 @@ - - - \ No newline at end of file + \ No newline at end of file diff --git a/snowflakes.js b/snowflakes.js index 4aec48f..5464415 100644 --- a/snowflakes.js +++ b/snowflakes.js @@ -1,4 +1,4 @@ -const randomSnowflakes = flase; // enable random Snowflakes +const randomSnowflakes = false; // enable random Snowflakes const snowflakeCount = 50; // count of random extra snowflakes @@ -14,8 +14,10 @@ function toggleSnowflakes() { // hide snowflakes if video player is active or dashboard is visible if (videoPlayer || isDashboard || hasUserMenu) { snowflakeContainer.style.display = 'none'; // hide snowflakes + console.log('Snowflakes hidden'); } else { snowflakeContainer.style.display = 'block'; // show snowflakes + console.log('Snowflakes visible'); } } @@ -32,6 +34,8 @@ observer.observe(document.body, { function addRandomSnowflakes(count) { const snowflakeContainer = document.querySelector('.snowflakes'); // get the snowflake container if (!snowflakeContainer) return; // exit if snowflake container is not found + + console.log('Adding random snowflakes'); const snowflakeSymbols = ['❅', '❆', '❄']; // some snowflake symbols