feat: page dark mode

This commit is contained in:
Kentai Radiquum 2024-05-19 19:12:48 +05:00
parent 40a31ce007
commit a9c029164f
Signed by: Radiquum
GPG key ID: 858E8EE696525EED
4 changed files with 72 additions and 12 deletions

View file

@ -32,7 +32,7 @@ const cards = [
const services = document.getElementById("services");
function renderCards() {
const theme = document.getElementById("body").classList[0];
const theme = localStorage.getItem("theme");
services.innerHTML = "";
for (let index = 0; index < cards.length; index++) {
const image_name = cards[index].image.split(".")[0];

View file

@ -14,7 +14,6 @@ const setTheme = (theme) => {
function updateTheme() {
let theme = localStorage.getItem("theme");
console.log("updatingTheme", theme);
if (theme) {
setTheme(theme);
} else {