From 0cf630ef23ad3e5469f165a0b6a2f81bcf8e407b Mon Sep 17 00:00:00 2001 From: dongchengjie <2424014450@qq.com> Date: Thu, 2 May 2024 22:16:05 +0800 Subject: [PATCH] chore: add service mode locale --- src/components/setting/mods/service-viewer.tsx | 15 +++++++++------ src/locales/en.json | 9 +++++++++ src/locales/ru.json | 9 +++++++++ src/locales/zh.json | 9 +++++++++ 4 files changed, 36 insertions(+), 6 deletions(-) diff --git a/src/components/setting/mods/service-viewer.tsx b/src/components/setting/mods/service-viewer.tsx index 839c8c2d..8413ab9f 100644 --- a/src/components/setting/mods/service-viewer.tsx +++ b/src/components/setting/mods/service-viewer.tsx @@ -86,12 +86,15 @@ export const ServiceViewer = forwardRef((props, ref) => { disableFooter onClose={() => setOpen(false)} > - Current State: {state} + + {t("Current State")}: {t(state)} + {(state === "unknown" || state === "uninstall") && ( - Information: Please make sure that the Clash Verge Service is - installed and enabled + {t( + "Information: Please make sure that the Clash Verge Service is installed and enabled" + )} )} @@ -102,19 +105,19 @@ export const ServiceViewer = forwardRef((props, ref) => { > {state === "uninstall" && enable && ( )} {state === "uninstall" && ( )} {(state === "active" || state === "installed") && ( )} diff --git a/src/locales/en.json b/src/locales/en.json index 392c90a0..928be199 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -185,9 +185,18 @@ "MTU": "Max Transmission Unit", "Reset to Default": "Reset to Default", + "Current State": "Current State", + "pending": "pending", + "installed": "installed", + "uninstall": "uninstalled", + "Disable Service Mode": "Disable Service Mode", + "Install": "Install", + "Uninstall": "Uninstall", + "Portable Updater Error": "The portable version does not support in-app updates. Please manually download and replace it", "Tun Mode Info": "The Tun mode requires granting core-related permissions. Please enable service mode before using it", "System and Mixed Can Only be Used in Service Mode": "System and Mixed Can Only be Used in Service Mode", + "Information: Please make sure that the Clash Verge Service is installed and enabled": "Information: Please make sure that the Clash Verge Service is installed and enabled", "Use Regular Expression": "Use Regular Expression" } diff --git a/src/locales/ru.json b/src/locales/ru.json index 57847d7b..a7ec2c5a 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -185,9 +185,18 @@ "MTU": "Максимальная единица передачи", "Reset to Default": "Сбросить настройки по умолчанию", + "Current State": "Текущее состояние", + "pending": "Ожидающий", + "installed": "Установленный", + "uninstall": "Не установленный", + "Disable Service Mode": "Отключить режим обслуживания", + "Install": "Установить", + "Uninstall": "Удалить", + "Portable Updater Error": "Портативная версия не поддерживает обновление внутри приложения, пожалуйста, скачайте и замените вручную", "Tun Mode Info": "Режим туннеля требует предоставления разрешений, связанных с ядром. Пожалуйста, включите сервисный режим перед его использованием", "System and Mixed Can Only be Used in Service Mode": "Система и смешанные могут использоваться только в сервисном режиме", + "Information: Please make sure that the Clash Verge Service is installed and enabled": "Информация: Пожалуйста, убедитесь, что сервис Clash Verge Service установлен и включен", "Use Regular Expression": "Использование регулярных выражений" } diff --git a/src/locales/zh.json b/src/locales/zh.json index 1e9fb644..1f65a4e4 100644 --- a/src/locales/zh.json +++ b/src/locales/zh.json @@ -185,9 +185,18 @@ "MTU": "最大传输单元", "Reset to Default": "重置为默认值", + "Current State": "当前状态", + "pending": "等待中", + "installed": "已安装", + "uninstall": "未安装", + "Disable Service Mode": "禁用服务模式", + "Install": "安装", + "Uninstall": "卸载", + "Portable Updater Error": "便携版不支持应用内更新,请手动下载替换", "Tun Mode Info": "Tun模式需要授予内核相关权限,使用前请先开启服务模式", "System and Mixed Can Only be Used in Service Mode": "System和Mixed只能在服务模式下使用", + "Information: Please make sure that the Clash Verge Service is installed and enabled": "提示信息: 请确保Clash Verge Service已安装并启用", "Use Regular Expression": "使用正则表达式" }