Burn it all to the ground and start with bun and a reorg

This commit is contained in:
2025-05-09 17:51:29 +01:00
parent 6eaf1d6b9f
commit 95f317fd75
82 changed files with 3001 additions and 13108 deletions

View File

@@ -0,0 +1,26 @@
"use client";
import { MoonIcon, SunIcon } from "@heroicons/react/24/outline";
import type React from "react";
export default function ThemeSwitcher(): React.JSX.Element {
const toggleTheme = (): void => {
const currentTheme = document.documentElement.getAttribute('data-theme');
if (currentTheme === 'light') {
localStorage.theme = 'dark';
document.documentElement.setAttribute('data-theme', 'dark');
} else {
localStorage.theme = 'light';
document.documentElement.setAttribute('data-theme', 'light');
}
};
return (
<>
<button type="button" className="m-1 h-8 w-8 rounded-full" onClick={toggleTheme}>
<MoonIcon className="block dark:hidden" />
<SunIcon className="hidden dark:block" />
</button>
</>
);
}