chore: add tooltip

This commit is contained in:
huzibaca 2024-11-05 17:39:59 +08:00
parent cb3bff589f
commit fe86b812cd
5 changed files with 23 additions and 2 deletions

View File

@ -1,11 +1,19 @@
import { useRef } from "react"; import { useRef } from "react";
import { useTranslation } from "react-i18next"; import { useTranslation } from "react-i18next";
import { TextField, Select, MenuItem, Typography } from "@mui/material"; import {
TextField,
Select,
MenuItem,
Typography,
Tooltip,
IconButton,
} from "@mui/material";
import { import {
SettingsRounded, SettingsRounded,
ShuffleRounded, ShuffleRounded,
LanRounded, LanRounded,
InfoRounded,
} from "@mui/icons-material"; } from "@mui/icons-material";
import { DialogRef, Notice, Switch } from "@/components/base"; import { DialogRef, Notice, Switch } from "@/components/base";
import { useClash } from "@/hooks/use-clash"; import { useClash } from "@/hooks/use-clash";
@ -111,7 +119,16 @@ const SettingClash = ({ onError }: Props) => {
</GuardState> </GuardState>
</SettingItem> </SettingItem>
<SettingItem label={t("Unified Delay")}> <SettingItem
label={t("Unified Delay")}
extra={
<Tooltip title={t("Unified Delay Info")} placement="top">
<IconButton color="inherit" size="small">
<InfoRounded fontSize="inherit" sx={{ opacity: 0.75 }} />
</IconButton>
</Tooltip>
}
>
<GuardState <GuardState
value={unifiedDelay ?? false} value={unifiedDelay ?? false}
valueProps="checked" valueProps="checked"

View File

@ -247,6 +247,7 @@
"Mac Address": "MAC Address", "Mac Address": "MAC Address",
"IPv6": "IPv6", "IPv6": "IPv6",
"Unified Delay": "Unified Delay", "Unified Delay": "Unified Delay",
"Unified Delay Info": "When unified delay is turned on, two delay tests will be performed to eliminate the delay differences between different types of nodes caused by connection handshakes, etc",
"Log Level": "Log Level", "Log Level": "Log Level",
"Port Config": "Port Config", "Port Config": "Port Config",
"Random Port": "Random Port", "Random Port": "Random Port",

View File

@ -242,6 +242,7 @@
"Mac Address": "آدرس MAC", "Mac Address": "آدرس MAC",
"IPv6": "IPv6", "IPv6": "IPv6",
"Unified Delay": "معادلDELAY", "Unified Delay": "معادلDELAY",
"Unified Delay Info": "معادلDELAY را فعال کنید تا ترافیک شبکه به سرعت رسید",
"Log Level": "سطح لاگ", "Log Level": "سطح لاگ",
"Port Config": "پیکربندی پورت", "Port Config": "پیکربندی پورت",
"Random Port": "پورت تصادفی", "Random Port": "پورت تصادفی",

View File

@ -245,6 +245,7 @@
"Mac Address": "MAC адрес", "Mac Address": "MAC адрес",
"IPv6": "IPv6", "IPv6": "IPv6",
"Unified Delay": "Общий задержка", "Unified Delay": "Общий задержка",
"Unified Delay Info": "Когда унифицированная задержка включена, будут выполнены два теста задержки, чтобы устранить различия в задержке между разными типами узлов, вызванные подтверждением соединения и т. д",
"Log Level": "Уровень логов", "Log Level": "Уровень логов",
"Port Config": "Настройка порта", "Port Config": "Настройка порта",
"Random Port": "Случайный порт", "Random Port": "Случайный порт",

View File

@ -247,6 +247,7 @@
"Mac Address": "MAC 地址", "Mac Address": "MAC 地址",
"IPv6": "IPv6", "IPv6": "IPv6",
"Unified Delay": "统一延时", "Unified Delay": "统一延时",
"Unified Delay Info": "开启统一延迟时,会进行两次延迟测试,以消除连接握手等带来的不同类型节点的延迟差异",
"Log Level": "日志等级", "Log Level": "日志等级",
"Port Config": "端口设置", "Port Config": "端口设置",
"Random Port": "随机端口", "Random Port": "随机端口",