feat: add footer component

This commit is contained in:
syy11cn 2022-04-02 17:36:54 +08:00 committed by sunyiyang.11
parent 1d1f97159c
commit 2aa2c58de6
1 changed files with 14 additions and 0 deletions

14
src/components/footer.tsx Normal file
View File

@ -0,0 +1,14 @@
import { useDark } from '~/utils'
const Footer = () => {
const [isDark, toggleDark] = useDark()
return <>
{/* Toggle dark mode. */}
<button className={isDark ? 'i-carbon-sun' : 'i-carbon-moon'} onClick={() => toggleDark()}></button>
{/* Github icon. */}
<button className="icon-btn i-carbon-github"></button>
</>
}
export default Footer