diff --git a/public/locales/de-DE/dashboard.json b/public/locales/de-DE/dashboard.json index bc4bd2a..c39d52d 100644 --- a/public/locales/de-DE/dashboard.json +++ b/public/locales/de-DE/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Breite", "captchaHeight": "Höhe", "captchaLength": "Länge", + "captchaLengthDes": "Die Länge der Zeichen im Captcha.", "captchaMode": "Modus", "captchaModeNumber": "Zahlen", "captchaModeLetter": "Buchstaben", diff --git a/public/locales/en-US/dashboard.json b/public/locales/en-US/dashboard.json index b7e7af6..ed4d04f 100644 --- a/public/locales/en-US/dashboard.json +++ b/public/locales/en-US/dashboard.json @@ -472,6 +472,7 @@ "captchaWidth": "Width", "captchaHeight": "Height", "captchaLength": "Length", + "captchaLengthDes": "The length of characters in the captcha.", "captchaMode": "Mode", "captchaModeNumber": "Numbers", "captchaModeLetter": "Letters", diff --git a/public/locales/es-ES/dashboard.json b/public/locales/es-ES/dashboard.json index 0293722..79c0225 100644 --- a/public/locales/es-ES/dashboard.json +++ b/public/locales/es-ES/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Ancho", "captchaHeight": "Altura", "captchaLength": "Longitud", + "captchaLengthDes": "La longitud de los caracteres en el captcha.", "captchaMode": "Modo", "captchaModeNumber": "Números", "captchaModeLetter": "Letras", diff --git a/public/locales/fr-FR/dashboard.json b/public/locales/fr-FR/dashboard.json index 113bc30..238cca2 100644 --- a/public/locales/fr-FR/dashboard.json +++ b/public/locales/fr-FR/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Largeur", "captchaHeight": "Hauteur", "captchaLength": "Longueur", + "captchaLengthDes": "La longueur des caractères dans le captcha.", "captchaMode": "Mode", "captchaModeNumber": "Chiffres", "captchaModeLetter": "Lettres", diff --git a/public/locales/it-IT/dashboard.json b/public/locales/it-IT/dashboard.json index 6caf401..3cbeff4 100644 --- a/public/locales/it-IT/dashboard.json +++ b/public/locales/it-IT/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Larghezza", "captchaHeight": "Altezza", "captchaLength": "Lunghezza", + "captchaLengthDes": "La lunghezza dei caratteri nel captcha.", "captchaMode": "Modalità", "captchaModeNumber": "Numeri", "captchaModeLetter": "Lettere", diff --git a/public/locales/ja-JP/dashboard.json b/public/locales/ja-JP/dashboard.json index 83b634d..85263a0 100644 --- a/public/locales/ja-JP/dashboard.json +++ b/public/locales/ja-JP/dashboard.json @@ -472,6 +472,7 @@ "captchaWidth": "幅", "captchaHeight": "高さ", "captchaLength": "長さ", + "captchaLengthDes": "キャプチャ内の文字の長さ。", "captchaMode": "モード", "captchaModeNumber": "数字", "captchaModeLetter": "アルファベット", diff --git a/public/locales/ko-KR/dashboard.json b/public/locales/ko-KR/dashboard.json index e168a79..121a4c5 100644 --- a/public/locales/ko-KR/dashboard.json +++ b/public/locales/ko-KR/dashboard.json @@ -472,6 +472,7 @@ "captchaWidth": "너비", "captchaHeight": "높이", "captchaLength": "길이", + "captchaLengthDes": "캡차 내 문자의 길이입니다.", "captchaMode": "모드", "captchaModeNumber": "숫자", "captchaModeLetter": "문자", diff --git a/public/locales/pt-BR/dashboard.json b/public/locales/pt-BR/dashboard.json index 8dc63ce..64ff78e 100644 --- a/public/locales/pt-BR/dashboard.json +++ b/public/locales/pt-BR/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Largura", "captchaHeight": "Altura", "captchaLength": "Comprimento", + "captchaLengthDes": "O comprimento dos caracteres no captcha.", "captchaMode": "Modo", "captchaModeNumber": "Números", "captchaModeLetter": "Letras", diff --git a/public/locales/ru-RU/dashboard.json b/public/locales/ru-RU/dashboard.json index 47f8043..fd2b51b 100644 --- a/public/locales/ru-RU/dashboard.json +++ b/public/locales/ru-RU/dashboard.json @@ -473,6 +473,7 @@ "captchaWidth": "Ширина", "captchaHeight": "Высота", "captchaLength": "Длина", + "captchaLengthDes": "Длина символов в капче.", "captchaMode": "Режим", "captchaModeNumber": "Цифры", "captchaModeLetter": "Буквы", diff --git a/public/locales/zh-CN/dashboard.json b/public/locales/zh-CN/dashboard.json index d38340d..de74cf9 100644 --- a/public/locales/zh-CN/dashboard.json +++ b/public/locales/zh-CN/dashboard.json @@ -472,6 +472,7 @@ "captchaWidth": "宽度", "captchaHeight": "高度", "captchaLength": "长度", + "captchaLengthDes": "验证码中字符的长度。", "captchaMode": "模式", "captchaModeNumber": "数字", "captchaModeLetter": "字母", diff --git a/public/locales/zh-TW/dashboard.json b/public/locales/zh-TW/dashboard.json index 0083bd4..523c9bd 100644 --- a/public/locales/zh-TW/dashboard.json +++ b/public/locales/zh-TW/dashboard.json @@ -472,6 +472,7 @@ "captchaWidth": "寬度", "captchaHeight": "高度", "captchaLength": "長度", + "captchaLengthDes": "驗證碼中字符的長度。", "captchaMode": "模式", "captchaModeNumber": "數字", "captchaModeLetter": "字母", diff --git a/src/component/Admin/Settings/Captcha/GraphicCaptcha.tsx b/src/component/Admin/Settings/Captcha/GraphicCaptcha.tsx index 83cc131..9bc43c0 100644 --- a/src/component/Admin/Settings/Captcha/GraphicCaptcha.tsx +++ b/src/component/Admin/Settings/Captcha/GraphicCaptcha.tsx @@ -1,10 +1,10 @@ +import { Collapse, FormControl, FormControlLabel, ListItemText, Stack, Switch } from "@mui/material"; import { useTranslation } from "react-i18next"; -import { FormControl, FormControlLabel, ListItemText, Stack, Switch } from "@mui/material"; -import SettingForm from "../../../Pages/Setting/SettingForm.tsx"; -import { DenseSelect } from "../../../Common/StyledComponents.tsx"; -import { SquareMenuItem } from "../../../FileManager/ContextMenu/ContextMenu.tsx"; -import * as React from "react"; import { isTrueVal } from "../../../../session/utils.ts"; +import { DenseFilledTextField, DenseSelect } from "../../../Common/StyledComponents.tsx"; +import { SquareMenuItem } from "../../../FileManager/ContextMenu/ContextMenu.tsx"; +import SettingForm from "../../../Pages/Setting/SettingForm.tsx"; +import { NoMarginHelperText } from "../Settings.tsx"; export interface GraphicCaptchaProps { values: { @@ -41,6 +41,28 @@ const GraphicCaptcha = ({ values, setSettings }: GraphicCaptchaProps) => { + + + + + setSettings({ + captcha_CaptchaLen: e.target.value, + }) + } + /> + {t("settings.captchaLengthDes")} + + + {[ { name: "complexOfNoiseText",