feat(i18n): integrate internationalization into sidebar, title bar, and settings components

- Added useI18n hook to Sidebar and TitleBar components for translation support.
- Updated sidebar navigation items to use translation keys instead of hardcoded labels.
- Enhanced TitleBar buttons with localized titles for minimize, maximize, and close actions.
- Expanded i18n constants to include new namespaces for sidebar and login.
- Implemented translation messages for sidebar, settings, and login components in English, Chinese, and Japanese.
- Refactored Knowledge and Skills pages to utilize useLocale for locale management.
- Updated Login page to display localized text for form labels, placeholders, and error messages.
- Enhanced Account and General settings panels with localized titles and descriptions.
- Modified SettingMenu to use translation keys for menu items.
This commit is contained in:
DEV_DSW
2026-04-17 17:16:18 +08:00
parent bc3de923ed
commit eca70425cf
16 changed files with 533 additions and 141 deletions

View File

@@ -10,6 +10,6 @@ export const SUPPORTED_LANGUAGES = [
{ code: 'ja', label: '日本語' },
] as const;
export type Namespace = 'common' | 'conversation' | 'setting' | 'window';
export type Namespace = 'common' | 'conversation' | 'setting' | 'window' | 'sidebar' | 'login';
export const NAMESPACES = ['common', 'conversation', 'setting', 'window'] as const satisfies readonly Namespace[];
export const NAMESPACES = ['common', 'conversation', 'setting', 'window', 'sidebar', 'login'] as const satisfies readonly Namespace[];