diff --git a/CHANGELOG.md b/CHANGELOG.md index 7a736308..41bfc386 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ _This release is scheduled to be released on 2022-04-01._ - Added a config option under the weather module, absoluteDates, providing an option to format weather forecast date output with either absolute or relative dates. - Added test for new weather forecast absoluteDates porperty. +- The modules get a class hidden added/removed if they get hidden/shown ### Updated diff --git a/js/main.js b/js/main.js index bc128194..dfb79708 100644 --- a/js/main.js +++ b/js/main.js @@ -245,6 +245,7 @@ const MM = (function () { if (moduleWrapper !== null) { moduleWrapper.style.transition = "opacity " + speed / 1000 + "s"; moduleWrapper.style.opacity = 0; + moduleWrapper.classList.add("hidden"); clearTimeout(module.showHideTimer); module.showHideTimer = setTimeout(function () { @@ -310,6 +311,7 @@ const MM = (function () { moduleWrapper.style.transition = "opacity " + speed / 1000 + "s"; // Restore the position. See hideModule() for more info. moduleWrapper.style.position = "static"; + moduleWrapper.classList.remove("hidden"); updateWrapperStates();