@@ -27,6 +27,7 @@ Gemini Desktop is a powerful, cross-platform desktop and web application that pr
27
27
- ** Multi-backend support** : Gemini CLI and Qwen Code integration
28
28
- ** Project management** : Session-based workspace management with chat history
29
29
- ** Security-first design** : Comprehensive command filtering and permission system
30
+ - ** Internationalization** : Full i18n support with language switching for English, Chinese Simplified, and Traditional Chinese
30
31
- ** Custom title bar** : Enhanced desktop experience with native window controls
31
32
- ** About dialog** : Integrated help and version information
32
33
- ** Resizable sidebar** : Interactive sidebar with drag-to-resize functionality and persistent width settings
@@ -113,6 +114,8 @@ The project is organized as a Rust workspace with three main crates:
113
114
- ` ToolCallsList.tsx ` - Tool execution history
114
115
- ` ToolResultRenderer.tsx ` - Tool output formatting
115
116
- ` UserAvatar.tsx ` - User profile display
117
+ - ` LanguageSwitcher.tsx ` - Language selection interface with flag icons
118
+ - ` I18nExample.tsx ` - Translation demonstration component
116
119
- ** ` conversation/ ` ** - Chat interface components
117
120
- ` ConversationList.tsx ` - Message history and pagination
118
121
- ` MessageInputBar.tsx ` - Text input with mention support
@@ -161,6 +164,10 @@ The project is organized as a Rust workspace with three main crates:
161
164
- Message history and pagination
162
165
- Tool call confirmation state
163
166
- Real-time event integration
167
+ - ** ` LanguageContext.tsx ` ** - Internationalization management
168
+ - Current language state and persistence
169
+ - Language switching functionality
170
+ - Browser language detection integration
164
171
165
172
#### Custom Hooks
166
173
- ** ` useCliInstallation.ts ` ** - CLI availability detection
@@ -203,6 +210,9 @@ The project is organized as a Rust workspace with three main crates:
203
210
- ** next-themes** - Theme management system
204
211
- ** class-variance-authority** - CSS class variance utilities
205
212
- ** Google Generative AI** - Direct Gemini API integration
213
+ - ** react-i18next** - Internationalization framework with hooks and components
214
+ - ** i18next** - Core internationalization library with interpolation and pluralization
215
+ - ** i18next-browser-languagedetector** - Browser language detection and persistence
206
216
207
217
### Development Tools
208
218
- ** Just** - Task runner and build automation
@@ -603,13 +613,22 @@ gemini-desktop/
603
613
- ** Chat history** stored in structured format
604
614
- ** Tool call logs** for debugging and replay
605
615
- ** Custom title bar** for enhanced desktop experience
616
+ - ** Full internationalization** with language detection and persistence
606
617
607
618
#### Authentication
608
619
- ** API key storage** (encrypted/secure storage planned)
609
620
- ** Multiple provider support** (Gemini, Vertex AI, Qwen)
610
621
- ** Session-based authentication** for web mode
611
622
- ** Unified backend configuration** with validation
612
623
624
+ #### Internationalization
625
+ - ** Language support** : English, Simplified Chinese, Traditional Chinese
626
+ - ** Browser language detection** with automatic fallback
627
+ - ** Persistent language preferences** stored in localStorage
628
+ - ** Component-level translations** using react-i18next hooks
629
+ - ** Translation interpolation** for dynamic content
630
+ - ** Pluralization support** for count-based translations
631
+
613
632
## Development Workflow
614
633
615
634
### Code Style and Standards
@@ -796,6 +815,8 @@ gemini-desktop/
796
815
│ │ │ │ ├── CodeBlock.tsx
797
816
│ │ │ │ ├── DiffViewer.tsx
798
817
│ │ │ │ ├── DirectorySelectionDialog.tsx
818
+ │ │ │ │ ├── I18nExample.tsx
819
+ │ │ │ │ ├── LanguageSwitcher.tsx
799
820
│ │ │ │ ├── MarkdownRenderer.tsx
800
821
│ │ │ │ ├── MentionInput.tsx
801
822
│ │ │ │ ├── ModelContextProtocol.tsx
@@ -864,7 +885,8 @@ gemini-desktop/
864
885
│ │ │ └── tooltip.tsx
865
886
│ │ ├── contexts/
866
887
│ │ │ ├── BackendContext.tsx
867
- │ │ │ └── ConversationContext.tsx
888
+ │ │ │ ├── ConversationContext.tsx
889
+ │ │ │ └── LanguageContext.tsx
868
890
│ │ ├── hooks/
869
891
│ │ │ ├── use-mobile.ts
870
892
│ │ │ ├── useCliInstallation.ts
@@ -898,6 +920,18 @@ gemini-desktop/
898
920
│ │ │ ├── toolCallParser.ts
899
921
│ │ │ ├── toolInputParser.ts
900
922
│ │ │ └── wordDiff.ts
923
+ │ │ ├── i18n/
924
+ │ │ │ ├── README.md
925
+ │ │ │ ├── config.ts
926
+ │ │ │ ├── index.ts
927
+ │ │ │ ├── locales/
928
+ │ │ │ │ ├── en/
929
+ │ │ │ │ │ └── translation.json
930
+ │ │ │ │ ├── zh-CN/
931
+ │ │ │ │ │ └── translation.json
932
+ │ │ │ │ └── zh-TW/
933
+ │ │ │ │ └── translation.json
934
+ │ │ │ └── types.ts
901
935
│ │ └── vite-env.d.ts
902
936
│ ├── tsconfig.json
903
937
│ ├── tsconfig.node.json
0 commit comments