diff --git a/src/App.jsx b/src/App.jsx index 3181e90..00cd61b 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -18,40 +18,42 @@ import { UserTypeSelector } from './components/UserTypeSelecctor'; import { UserTypeSelectorLogin } from './components/UserTypeSelecctorLogin'; import AddProducts from './components/AddProducts'; - function App() { -const dispatch =useDispatch() + const dispatch = useDispatch(); + const [darkMode, setDarkMode] = useState(false); + + useEffect(() => { + dispatch(setUser(JSON.parse(localStorage.getItem('user')))); + }, []); -useEffect(()=>{ + const toggleDarkMode = () => { + setDarkMode(!darkMode); + }; - dispatch(setUser(JSON.parse(localStorage.getItem('user')))) - -},[]) return ( - - -
-
- - } /> - - } /> - } /> - } /> - } > - } /> + +
+
+ + + } /> + } /> + } /> + } /> + }> + } /> } /> } /> } /> } /> - - } /> - } /> - - -
-
- +
+ } /> + } /> +
+
+
); } diff --git a/src/components/Footer/Footer.jsx b/src/components/Footer/Footer.jsx index 394aac9..02d84f2 100644 --- a/src/components/Footer/Footer.jsx +++ b/src/components/Footer/Footer.jsx @@ -4,7 +4,7 @@ function Footer() { const today = new Date(); return (