Recovered from backup
This commit is contained in:
12
frontend/src/components/ThemeButton.jsx
Normal file
12
frontend/src/components/ThemeButton.jsx
Normal file
@@ -0,0 +1,12 @@
|
||||
import { useTheme } from "../contexts/ThemeContext.jsx";
|
||||
import "../css/ThemeButton.css";
|
||||
|
||||
export default function ThemeButton() {
|
||||
const { theme, toggleTheme } = useTheme();
|
||||
|
||||
return (
|
||||
<button className="theme-toggle" onClick={toggleTheme}>
|
||||
{theme === "dark" ? "☀️" : "🌙"}
|
||||
</button>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user