mirror of
https://github.com/DeveloLongScript/MHSF.git
synced 2026-05-16 15:28:01 -05:00
21 lines
422 B
TypeScript
21 lines
422 B
TypeScript
|
|
"use client";
|
||
|
|
|
||
|
|
import { useTheme } from "next-themes";
|
||
|
|
import { Toaster } from "react-hot-toast";
|
||
|
|
|
||
|
|
export default function ThemedToaster() {
|
||
|
|
const { resolvedTheme } = useTheme();
|
||
|
|
|
||
|
|
return (
|
||
|
|
<Toaster
|
||
|
|
position="bottom-center"
|
||
|
|
reverseOrder={false}
|
||
|
|
toastOptions={
|
||
|
|
resolvedTheme == "dark"
|
||
|
|
? { style: { background: "#333", color: "#fff" } }
|
||
|
|
: undefined
|
||
|
|
}
|
||
|
|
/>
|
||
|
|
);
|
||
|
|
}
|