Skip to content

Commit 589165a

Browse files
committed
fixed: theme switch bug for login & contributors pages respectively
1 parent 2a9c970 commit 589165a

10 files changed

Lines changed: 151 additions & 376 deletions

File tree

src/App.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import Footer from "./components/Footer";
33
import ScrollProgressBar from "./components/ScrollProgressBar";
44
import { Toaster } from "react-hot-toast";
55
import Router from "./Routes/Router";
6-
import ThemeWrapper from "./ThemeContext"; // ✅ import your wrapper
6+
import ThemeWrapper from "./context/ThemeContext"; // ✅ import your wrapper
77

88
function App() {
99
return (

src/Routes/Login/Login.tsx

Lines changed: 0 additions & 149 deletions
This file was deleted.

src/components/Navbar.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Link } from "react-router-dom";
22
import { useState, useContext } from "react";
3-
import { ThemeContext } from "../ThemeContext";
3+
import { ThemeContext } from "../context/ThemeContext";
44

55
const Navbar: React.FC = () => {
66
const [isOpen, setIsOpen] = useState<boolean>(false);

src/hooks/useTheme.ts

Lines changed: 0 additions & 31 deletions
This file was deleted.

src/main.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { createRoot } from "react-dom/client";
33
import App from "./App.tsx";
44
import "./index.css";
55
import { BrowserRouter } from "react-router-dom";
6-
import ThemeWrapper from "./ThemeContext.tsx";
6+
import ThemeWrapper from "./context/ThemeContext.tsx";
77

88
createRoot(document.getElementById("root")!).render(
99
<StrictMode>

src/pages/Contact/Contact.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { useState, useContext } from "react";
22
import { Github, Mail, Phone, Send, X, CheckCircle } from "lucide-react";
3-
import { ThemeContext } from "../../ThemeContext";
4-
import type { ThemeContextType } from "../../ThemeContext";
3+
import { ThemeContext } from "../../context/ThemeContext";
4+
import type { ThemeContextType } from "../../context/ThemeContext";
55

66
function Contact() {
77
const [showPopup, setShowPopup] = useState(false);

0 commit comments

Comments
 (0)