feat(i18n): add i18n support

This commit is contained in:
leookun committed 2026-08-24 03:08:29 +08:00
1 parent 2abffcc835
commit 03075952a6
20 files changed
+932 -354

No files matched your search

+3 -3
View File
@@ -2,9 +2,9 @@ export const themeIds = ["default-dark", "default-light"] as const;
export type ThemeId = (typeof themeIds)[number];
export const themeOptions = [
{ id: "default-dark", name: "默认暗色" },
{ id: "default-light", name: "默认亮色" },
] satisfies { id: ThemeId; name: string }[];
{ id: "default-dark" },
{ id: "default-light" },
] satisfies { id: ThemeId }[];
export function isThemeId(value: string | null): value is ThemeId {
return value !== null && themeIds.some((id) => id === value);