Skip to content

Commit

Permalink
update i18n
Browse files Browse the repository at this point in the history
  • Loading branch information
arvinxx committed Feb 25, 2025
1 parent c8a567f commit ce78ed0
Show file tree
Hide file tree
Showing 22 changed files with 139 additions and 29 deletions.
8 changes: 7 additions & 1 deletion locales/ar/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} نسخة",
"emptyAgent": "لا يوجد مساعد",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "تفعيل التفكير العميق"
},
"reasoningBudgetToken": {
"title": "استهلاك توكن التفكير"
},
"title": "وظائف توسيع النموذج"
},
"historyRange": "نطاق التاريخ",
Expand Down
8 changes: 7 additions & 1 deletion locales/bg-BG/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Копие",
"emptyAgent": "Няма наличен асистент",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Активиране на дълбочинно мислене"
},
"reasoningBudgetToken": {
"title": "Токени за разходи при мислене"
},
"title": "Разширени функции на модела"
},
"historyRange": "Диапазон на историята",
Expand Down
8 changes: 7 additions & 1 deletion locales/de-DE/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Kopie",
"emptyAgent": "Kein Assistent verfügbar",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Tiefes Denken aktivieren"
},
"reasoningBudgetToken": {
"title": "Token für Denkaufwand"
},
"title": "Modell Erweiterungsfunktionen"
},
"historyRange": "Verlaufsbereich",
Expand Down
8 changes: 7 additions & 1 deletion locales/en-US/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Copy",
"emptyAgent": "No assistant available",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Enable Deep Thinking"
},
"reasoningBudgetToken": {
"title": "Thinking Consumption Token"
},
"title": "Model Extension Features"
},
"historyRange": "History Range",
Expand Down
10 changes: 8 additions & 2 deletions locales/es-ES/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,14 @@
},
"duplicateTitle": "{{title}} Copia",
"emptyAgent": "No hay asistente disponible",
"extendControls": {
"title": "Funciones de extensión del modelo"
"extendParams": {
"enableReasoning": {
"title": "Activar el pensamiento profundo"
},
"reasoningBudgetToken": {
"title": "Token de consumo de pensamiento"
},
"title": "Funcionalidad de extensión del modelo"
},
"historyRange": "Rango de historial",
"historySummary": "Resumen de mensajes históricos",
Expand Down
8 changes: 7 additions & 1 deletion locales/fa-IR/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "نسخه‌ای از {{title}}",
"emptyAgent": "دستیار موجود نیست",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "فعال‌سازی تفکر عمیق"
},
"reasoningBudgetToken": {
"title": "توکن مصرف تفکر"
},
"title": "ویژگی‌های گسترش مدل"
},
"historyRange": "محدوده تاریخی",
Expand Down
8 changes: 7 additions & 1 deletion locales/fr-FR/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Copie",
"emptyAgent": "Aucun assistant disponible",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Activer la réflexion approfondie"
},
"reasoningBudgetToken": {
"title": "Token de consommation de réflexion"
},
"title": "Fonctionnalités d'extension du modèle"
},
"historyRange": "Plage d'historique",
Expand Down
8 changes: 7 additions & 1 deletion locales/it-IT/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Copia",
"emptyAgent": "Nessun assistente disponibile",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Attiva il pensiero profondo"
},
"reasoningBudgetToken": {
"title": "Token di consumo del pensiero"
},
"title": "Funzionalità di estensione del modello"
},
"historyRange": "Intervallo cronologico",
Expand Down
8 changes: 7 additions & 1 deletion locales/ja-JP/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} のコピー",
"emptyAgent": "エージェントがいません",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "深い思考を有効にする"
},
"reasoningBudgetToken": {
"title": "思考消費トークン"
},
"title": "モデル拡張機能"
},
"historyRange": "履歴範囲",
Expand Down
8 changes: 7 additions & 1 deletion locales/ko-KR/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} 복사본",
"emptyAgent": "도우미가 없습니다",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "심층 사고 활성화"
},
"reasoningBudgetToken": {
"title": "사고 소모 토큰"
},
"title": "모델 확장 기능"
},
"historyRange": "대화 기록 범위",
Expand Down
10 changes: 8 additions & 2 deletions locales/nl-NL/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,14 @@
},
"duplicateTitle": "{{title}} Kopie",
"emptyAgent": "Geen assistent beschikbaar",
"extendControls": {
"title": "Modeluitbreidingsfuncties"
"extendParams": {
"enableReasoning": {
"title": "Diepe denkwijze inschakelen"
},
"reasoningBudgetToken": {
"title": "Denken verbruik Token"
},
"title": "Modeluitbreidingsfunctie"
},
"historyRange": "Geschiedenisbereik",
"historySummary": "Geschiedenis samenvatting",
Expand Down
8 changes: 7 additions & 1 deletion locales/pl-PL/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} kopia",
"emptyAgent": "Brak asystenta",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Włącz głębokie myślenie"
},
"reasoningBudgetToken": {
"title": "Token zużycia myślenia"
},
"title": "Funkcje rozszerzenia modelu"
},
"historyRange": "Zakres historii",
Expand Down
8 changes: 7 additions & 1 deletion locales/pt-BR/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Cópia",
"emptyAgent": "Sem assistente disponível",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Ativar Pensamento Profundo"
},
"reasoningBudgetToken": {
"title": "Token de Consumo de Pensamento"
},
"title": "Funcionalidade de Extensão do Modelo"
},
"historyRange": "Intervalo de Histórico",
Expand Down
10 changes: 8 additions & 2 deletions locales/ru-RU/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,14 @@
},
"duplicateTitle": "{{title}} Копия",
"emptyAgent": "Нет ассистента",
"extendControls": {
"title": "Функции расширения модели"
"extendParams": {
"enableReasoning": {
"title": "Включить глубокое мышление"
},
"reasoningBudgetToken": {
"title": "Токены на размышления"
},
"title": "Расширенные функции модели"
},
"historyRange": "История сообщений",
"historySummary": "Сводка исторических сообщений",
Expand Down
8 changes: 7 additions & 1 deletion locales/tr-TR/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Kopya",
"emptyAgent": "Asistan yok",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Derin Düşünmeyi Aç"
},
"reasoningBudgetToken": {
"title": "Düşünme Tüketim Tokeni"
},
"title": "Model Genişletme Özellikleri"
},
"historyRange": "Geçmiş Aralığı",
Expand Down
8 changes: 7 additions & 1 deletion locales/vi-VN/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} Bản sao",
"emptyAgent": "Không có trợ lý",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "Bật tư duy sâu sắc"
},
"reasoningBudgetToken": {
"title": "Token tiêu tốn cho tư duy"
},
"title": "Chức năng mở rộng mô hình"
},
"historyRange": "Phạm vi lịch sử",
Expand Down
8 changes: 7 additions & 1 deletion locales/zh-CN/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} 副本",
"emptyAgent": "暂无助手",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "开启深度思考"
},
"reasoningBudgetToken": {
"title": "思考消耗 Token"
},
"title": "模型扩展功能"
},
"historyRange": "历史范围",
Expand Down
8 changes: 7 additions & 1 deletion locales/zh-TW/chat.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@
},
"duplicateTitle": "{{title}} 副本",
"emptyAgent": "暫無助手",
"extendControls": {
"extendParams": {
"enableReasoning": {
"title": "開啟深度思考"
},
"reasoningBudgetToken": {
"title": "思考消耗 Token"
},
"title": "模型擴展功能"
},
"historyRange": "歷史範圍",
Expand Down
4 changes: 2 additions & 2 deletions src/features/ChatInput/ActionBar/Model/ControlsForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ const ControlsForm = memo(() => {
const items: FormItemProps[] = [
{
children: <Switch />,
label: '开启思考',
label: t('extendParams.enableReasoning.title'),
minWidth: undefined,
name: 'enableReasoning',
},
{
children: <ReasoningTokenSlider />,
label: '思考消耗 Token',
label: t('extendParams.reasoningBudgetToken.title'),
layout: 'vertical',
minWidth: undefined,
name: 'reasoningBudgetToken',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
import { InputNumber, Slider } from 'antd';
import { memo, useMemo } from 'react';
import { useTranslation } from 'react-i18next';
import { Flexbox } from 'react-layout-kit';
import useMergeState from 'use-merge-value';


const Kibi = 1024;

const exponent = (num: number) => Math.log2(num);
Expand All @@ -18,8 +16,6 @@ interface MaxTokenSliderProps {
}

const MaxTokenSlider = memo<MaxTokenSliderProps>(({ value, onChange, defaultValue }) => {
const { t } = useTranslation('components');

const [token, setTokens] = useMergeState(0, {
defaultValue,
onChange,
Expand Down
2 changes: 1 addition & 1 deletion src/features/ChatInput/ActionBar/Model/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ const ModelSwitch = memo(() => {
icon={Settings2Icon}
placement={'bottom'}
style={{ borderRadius: 20 }}
title={t('extendControls.title')}
title={t('extendParams.title')}
/>
</Popover>
</Flexbox>
Expand Down
8 changes: 7 additions & 1 deletion src/locales/default/chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,13 @@ export default {
},
duplicateTitle: '{{title}} 副本',
emptyAgent: '暂无助手',
extendControls: {
extendParams: {
enableReasoning: {
title: '开启深度思考',
},
reasoningBudgetToken: {
title: '思考消耗 Token',
},
title: '模型扩展功能',
},
historyRange: '历史范围',
Expand Down

0 comments on commit ce78ed0

Please sign in to comment.