From 0ec1a09c3032eb8badd29570f0e92d681320c43c Mon Sep 17 00:00:00 2001 From: Javier Pastor Date: Thu, 13 Nov 2025 22:26:41 +0100 Subject: [PATCH 1/2] fix issues #4939 add other translations --- .../components/Form/AccessClientFields.tsx | 10 +++--- .../src/components/Form/DNSProviderFields.tsx | 4 +-- frontend/src/locale/src/en.json | 36 +++++++++++++++++++ frontend/src/locale/src/es.json | 36 +++++++++++++++++++ frontend/src/modals/RedirectionHostModal.tsx | 14 ++++---- frontend/src/modals/StreamModal.tsx | 4 +-- frontend/src/pages/Login/index.tsx | 2 +- 7 files changed, 89 insertions(+), 17 deletions(-) diff --git a/frontend/src/components/Form/AccessClientFields.tsx b/frontend/src/components/Form/AccessClientFields.tsx index 820907dc64..9dda8c3de0 100644 --- a/frontend/src/components/Form/AccessClientFields.tsx +++ b/frontend/src/components/Form/AccessClientFields.tsx @@ -3,7 +3,7 @@ import cn from "classnames"; import { useFormikContext } from "formik"; import { useState } from "react"; import type { AccessListClient } from "src/api/backend"; -import { T } from "src/locale"; +import { intl, T } from "src/locale"; interface Props { initialValues: AccessListClient[]; @@ -65,8 +65,8 @@ export function AccessClientFields({ initialValues, name = "clients" }: Props) { value={client.directive} onChange={(e) => handleChange(idx, "directive", e.target.value)} > - - + + handleChange(idx, "address", e.target.value)} - placeholder="192.168.1.100 or 192.168.1.0/24 or 2001:0db8::/32" + placeholder={intl.formatMessage({ id: "access-list.rule-source.placeholder" })} /> @@ -112,7 +112,7 @@ export function AccessClientFields({ initialValues, name = "clients" }: Props) { value="deny" disabled > - + - + @@ -224,12 +224,12 @@ const RedirectionHostModal = EasyModal.create(({ id, visible, remove }: Props) = required {...field} > - - - - - - + + + + + + {form.errors.forwardHttpCode ? (
diff --git a/frontend/src/modals/StreamModal.tsx b/frontend/src/modals/StreamModal.tsx index 37a109b3ef..6d55348896 100644 --- a/frontend/src/modals/StreamModal.tsx +++ b/frontend/src/modals/StreamModal.tsx @@ -5,7 +5,7 @@ import { Alert } from "react-bootstrap"; import Modal from "react-bootstrap/Modal"; import { Button, Loading, SSLCertificateField, SSLOptionsFields } from "src/components"; import { useSetStream, useStream } from "src/hooks"; -import { T } from "src/locale"; +import { intl, T } from "src/locale"; import { validateNumber, validateString } from "src/modules/Validations"; import { showObjectSuccess } from "src/notifications"; @@ -154,7 +154,7 @@ const StreamModal = EasyModal.create(({ id, visible, remove }: Props) => { type="text" className={`form-control ${form.errors.forwardingHost && form.touched.forwardingHost ? "is-invalid" : ""}`} required - placeholder="example.com or 10.0.0.1 or 2001:db8:3333:4444:5555:6666:7777:8888" + placeholder={intl.formatMessage({ id: "stream.forward-host.placeholder" })} {...field} /> {form.errors.forwardingHost ? ( diff --git a/frontend/src/pages/Login/index.tsx b/frontend/src/pages/Login/index.tsx index 0d555380b9..856266d87c 100644 --- a/frontend/src/pages/Login/index.tsx +++ b/frontend/src/pages/Login/index.tsx @@ -103,7 +103,7 @@ export default function Login() { required maxLength={255} className={`form-control ${form.errors.password && form.touched.password ? " is-invalid" : ""}`} - placeholder="Password" + placeholder={intl.formatMessage({ id: "password" })} />
{form.errors.password}
From fce569ca2182afd5f681a8ebab4efaa3271f9562 Mon Sep 17 00:00:00 2001 From: Javier Pastor Date: Sun, 16 Nov 2025 01:53:48 +0100 Subject: [PATCH 2/2] Modify host.forward-port to avoid line breaks --- frontend/src/locale/src/es.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/locale/src/es.json b/frontend/src/locale/src/es.json index cb371e7b14..2b1ebfa4e8 100644 --- a/frontend/src/locale/src/es.json +++ b/frontend/src/locale/src/es.json @@ -363,7 +363,7 @@ "defaultMessage": "Soporte de Websockets" }, "host.forward-port": { - "defaultMessage": "Puerto de Reenvío" + "defaultMessage": "Puerto" }, "host.forward-scheme": { "defaultMessage": "Esquema"