From b0287e13e5c53567ea4bab0714464a2781f574bf Mon Sep 17 00:00:00 2001 From: kullansunil Date: Sat, 19 Oct 2024 01:12:32 +0530 Subject: [PATCH] Update typing.js darkmode button can change the the theme to light and dark --- js/typing.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/js/typing.js b/js/typing.js index 3d98d66..baf5556 100644 --- a/js/typing.js +++ b/js/typing.js @@ -90,10 +90,11 @@ themeToggleButton.addEventListener('click', () => { body.classList.toggle('dark-theme'); const isDarkTheme = body.classList.contains('dark-theme'); themeToggleButton.innerHTML = isDarkTheme - ? '' - : ''; + ? '' + : ''; }); + document.addEventListener("DOMContentLoaded", function() { const sidebar = document.querySelector('.sidebar'); sidebar.style.display = 'none';