fix: i18n

This commit is contained in:
hamster1963 2024-11-24 20:51:48 +08:00
parent 26871521d8
commit 8812cd1d3f
2 changed files with 5 additions and 5 deletions

View File

@ -10,10 +10,10 @@ import { Moon, Sun } from "lucide-react";
import { Theme } from "@/components/ThemeProvider"; import { Theme } from "@/components/ThemeProvider";
import { useTheme } from "../hooks/use-theme"; import { useTheme } from "../hooks/use-theme";
import { CheckCircleIcon } from "@heroicons/react/20/solid"; import { CheckCircleIcon } from "@heroicons/react/20/solid";
import { useTranslation } from 'react-i18next'; import { useTranslation } from "react-i18next";
export function ModeToggle() { export function ModeToggle() {
const {t} = useTranslation(); const { t } = useTranslation();
const { setTheme, theme } = useTheme(); const { setTheme, theme } = useTheme();
const handleSelect = (e: Event, newTheme: Theme) => { const handleSelect = (e: Event, newTheme: Theme) => {

View File

@ -1,7 +1,7 @@
{ {
"overview": "Overview", "overview": "Overview",
"language": { "language": {
"zh-CN": "简体中文", "zh-CN": "简体中文",
"zh-TW": "繁體中文", "zh-TW": "繁體中文",
"en": "English" "en": "English"
}, },