feat: add 6 new locales (ja, ko, fr, es, de, pt) and UI polish

- Add Japanese, Korean, French, Spanish, German, Portuguese translations
- Improve session active state visibility in both themes
- Static language labels in LanguageSwitch component
- Dark theme: lighten chat input background for better contrast
- Fix system theme listener not toggling back to light

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
ekko
2026-04-17 09:09:50 +08:00
parent 16e07bcc9b
commit dcb477594b
10 changed files with 2728 additions and 12 deletions
@@ -1,16 +1,19 @@
<script setup lang="ts">
import { computed } from 'vue'
import { useI18n } from 'vue-i18n'
import { NSelect } from 'naive-ui'
const { locale, availableLocales, t } = useI18n()
const { locale } = useI18n()
const options = computed(() =>
availableLocales.map(loc => ({
label: loc === 'zh' ? t('language.zh') : t('language.en'),
value: loc,
})),
)
const options = [
{ label: '中文', value: 'zh' },
{ label: 'English', value: 'en' },
{ label: '日本語', value: 'ja' },
{ label: '한국어', value: 'ko' },
{ label: 'Français', value: 'fr' },
{ label: 'Español', value: 'es' },
{ label: 'Deutsch', value: 'de' },
{ label: 'Português', value: 'pt' },
]
function handleChange(val: string) {
locale.value = val