import React, { useEffect, useState } from "react" import MoonIcon from "@geist-ui/icons/moon" import SunIcon from "@geist-ui/icons/sun" // import { useAllThemes, useTheme } from '@geist-ui/core' import styles from "./header.module.css" import { Select } from "@geist-ui/core/dist" import { useTheme } from "next-themes" const Controls = () => { const [mounted, setMounted] = useState(false) const { resolvedTheme, setTheme } = useTheme() useEffect(() => setMounted(true), []) if (!mounted) return null const switchThemes = () => { if (resolvedTheme === "dark") { setTheme("light") } else { setTheme("dark") } } return (