From ffd19e148bc7abacca6498b54a24545965467443 Mon Sep 17 00:00:00 2001 From: nuttylmao Date: Tue, 6 May 2025 21:06:43 +1000 Subject: [PATCH] Added a hidden "Animation Speed" setting (defaults to 0.1s) --- multichat-overlay/script.js | 5 +++++ multichat-overlay/style.css | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/multichat-overlay/script.js b/multichat-overlay/script.js index 1d74922..b6c9ae9 100644 --- a/multichat-overlay/script.js +++ b/multichat-overlay/script.js @@ -56,6 +56,8 @@ const showFourthwallAlerts = GetBooleanParam("showFourthwallAlerts", true); const furryMode = GetBooleanParam("furryMode", false); +const animationSpeed = GetIntParam("animationSpeed", 0.1); + // Set fonts for the widget document.body.style.fontFamily = font; document.body.style.fontSize = `${fontSize}px`; @@ -84,6 +86,9 @@ switch (scrollDirection) { break; } +// Set the animation speed +document.documentElement.style.setProperty('--animation-speed', `${animationSpeed}s`); + diff --git a/multichat-overlay/style.css b/multichat-overlay/style.css index afc92c4..fcba6af 100644 --- a/multichat-overlay/style.css +++ b/multichat-overlay/style.css @@ -73,12 +73,12 @@ li { } .slide-fade li { - transition: all 0.5s ease-out; - opacity: 0; + transition: all var(--animation-speed) ease-out; + /* opacity: 0; */ } .slide-fade li.show { - opacity: 1; + /* opacity: 1; */ } #IPutThisHereSoICanCalculateHowBigEachMessageIsSupposedToBeBeforeIAddItToTheMessageList {