From 15bd5b24f3b847890e2d4273e5a9d2a534682773 Mon Sep 17 00:00:00 2001 From: Anirban Kar Date: Sun, 8 Dec 2024 02:11:47 +0530 Subject: [PATCH] background rays and changed the theme color to purple --- app/components/ui/BackgroundRays/index.tsx | 26 ---------------------- 1 file changed, 26 deletions(-) diff --git a/app/components/ui/BackgroundRays/index.tsx b/app/components/ui/BackgroundRays/index.tsx index 7f77c4c..ac4ed86 100644 --- a/app/components/ui/BackgroundRays/index.tsx +++ b/app/components/ui/BackgroundRays/index.tsx @@ -1,32 +1,6 @@ -// PurpleRays.jsx -import React, { useEffect, useState } from 'react'; import styles from './styles.module.scss'; const BackgroundRays = () => { - const [theme, setTheme] = useState('dark'); - - useEffect(() => { - // Initial theme - const currentTheme = document.documentElement.getAttribute('data-theme'); - setTheme(currentTheme || 'dark'); - - // Optional: Watch for theme changes - const observer = new MutationObserver((mutations) => { - mutations.forEach((mutation) => { - if (mutation.attributeName === 'data-theme') { - const newTheme = document.documentElement.getAttribute('data-theme'); - setTheme((existingTheme) => newTheme || existingTheme); - } - }); - }); - - observer.observe(document.documentElement, { - attributes: true, - attributeFilter: ['data-theme'], - }); - - return () => observer.disconnect(); - }, []); return (