From 8f46ce75b8e38a17eed88e883b5f252f54c26068 Mon Sep 17 00:00:00 2001 From: yangdx Date: Wed, 2 Apr 2025 23:55:28 +0800 Subject: [PATCH] Update i18n translation --- lightrag_webui/src/components/graph/Settings.tsx | 3 ++- lightrag_webui/src/locales/ar.json | 1 + lightrag_webui/src/locales/en.json | 1 + lightrag_webui/src/locales/fr.json | 1 + lightrag_webui/src/locales/zh.json | 1 + 5 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lightrag_webui/src/components/graph/Settings.tsx b/lightrag_webui/src/components/graph/Settings.tsx index 8c1ea652..e4085cef 100644 --- a/lightrag_webui/src/components/graph/Settings.tsx +++ b/lightrag_webui/src/components/graph/Settings.tsx @@ -54,6 +54,7 @@ const LabeledNumberInput = ({ max?: number defaultValue?: number }) => { + const { t } = useTranslation(); const [currentValue, setCurrentValue] = useState(value) const onValueChange = useCallback( @@ -120,7 +121,7 @@ const LabeledNumberInput = ({ className="h-6 w-6 flex-shrink-0 hover:bg-muted text-muted-foreground hover:text-foreground" onClick={handleReset} type="button" - title="重置为默认值" + title={t('graphPanel.sideBar.settings.resetToDefault')} > diff --git a/lightrag_webui/src/locales/ar.json b/lightrag_webui/src/locales/ar.json index 50119b06..0c2a1b38 100644 --- a/lightrag_webui/src/locales/ar.json +++ b/lightrag_webui/src/locales/ar.json @@ -150,6 +150,7 @@ "maxQueryDepth": "أقصى عمق للاستعلام", "maxNodes": "الحد الأقصى للعقد", "maxLayoutIterations": "أقصى تكرارات التخطيط", + "resetToDefault": "إعادة التعيين إلى الافتراضي", "depth": "D", "max": "Max", "degree": "الدرجة", diff --git a/lightrag_webui/src/locales/en.json b/lightrag_webui/src/locales/en.json index dd3757a9..c89855ed 100644 --- a/lightrag_webui/src/locales/en.json +++ b/lightrag_webui/src/locales/en.json @@ -150,6 +150,7 @@ "maxQueryDepth": "Max Query Depth", "maxNodes": "Max Nodes", "maxLayoutIterations": "Max Layout Iterations", + "resetToDefault": "Reset to default", "depth": "D", "max": "Max", "degree": "Degree", diff --git a/lightrag_webui/src/locales/fr.json b/lightrag_webui/src/locales/fr.json index e8792fd4..b3ac90da 100644 --- a/lightrag_webui/src/locales/fr.json +++ b/lightrag_webui/src/locales/fr.json @@ -150,6 +150,7 @@ "maxQueryDepth": "Profondeur maximale de la requête", "maxNodes": "Nombre maximum de nœuds", "maxLayoutIterations": "Itérations maximales de mise en page", + "resetToDefault": "Réinitialiser par défaut", "depth": "D", "max": "Max", "degree": "Degré", diff --git a/lightrag_webui/src/locales/zh.json b/lightrag_webui/src/locales/zh.json index c3c4676c..bbbb54e3 100644 --- a/lightrag_webui/src/locales/zh.json +++ b/lightrag_webui/src/locales/zh.json @@ -150,6 +150,7 @@ "maxQueryDepth": "最大查询深度", "maxNodes": "最大返回节点数", "maxLayoutIterations": "最大布局迭代次数", + "resetToDefault": "重置为默认值", "depth": "深", "max": "Max", "degree": "邻边",