i18n and UI fix

This commit is contained in:
2026-03-14 23:16:15 +08:00
parent 43289845fc
commit f7ad51b9ec
69 changed files with 5970 additions and 286 deletions

View File

@@ -0,0 +1,33 @@
# Task 04: Locale Store - Compilation Evidence
## Date: 2026-03-13
## Files Created
- src/renderer/src/stores/localeStore.ts
## Verification
### TypeScript Check
```bash
npx tsc --noEmit
# Result: PASSED (no errors)
```
### Store Implementation
- Uses Zustand with persist middleware
- Imports LocaleCode and DEFAULT_LOCALE from @shared/types/locale
- Persists only the locale state value (partialize pattern)
- Exports useLocaleStore hook
### State Shape
```typescript
interface LocaleState {
locale: LocaleCode; // "zh-CN" | "ja-JP" | "en-US"
setLocale: (locale: LocaleCode) => void;
}
```
### Default Value
- locale: "zh-CN" (from DEFAULT_LOCALE constant)
## Status: COMPLETED