diff --git a/src/lib/utils.js b/src/lib/utils.js index 5a7026b..378ccef 100644 --- a/src/lib/utils.js +++ b/src/lib/utils.js @@ -1,25 +1,6 @@ -import { useTheme } from "@/components/theme-provider"; import { clsx } from "clsx"; -import { useEffect } from "react"; import { twMerge } from "tailwind-merge"; export function cn(...inputs) { return twMerge(clsx(inputs)); } - -// know what theme is set and set theme -export default function useWhatTheme() { - const { theme, setTheme } = useTheme(); - - useEffect(() => { - if (theme === "system") { - setTheme( - window.matchMedia("(prefers-color-scheme: dark)")?.matches - ? "dark" - : "light", - ); - } - }); - - return { theme }; -}