mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 10:47:37 +00:00
feat(typescript): add i18n for all input required messages in Login V2 (#10288)
# Which Problems Are Solved - Currently message when required field is empty is hardcoded For example: <img width="429" height="381" alt="image" src="https://github.com/user-attachments/assets/31671d62-e45e-42c2-8ffe-a77982d0fc9d" /> # How the Problems Are Solved - adds i18n for all input required messages For example: <img width="434" height="374" alt="image" src="https://github.com/user-attachments/assets/9f94dd47-6c0a-4232-bef2-8dd1aa2674df" /> # Additional Changes N.A # Additional Context N.A Co-authored-by: Max Peintner <max@caos.ch>
This commit is contained in:
@@ -25,14 +25,20 @@
|
||||
"title": "Willkommen zurück!",
|
||||
"description": "Geben Sie Ihre Anmeldedaten ein.",
|
||||
"register": "Neuen Benutzer registrieren",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"loginName": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Passwort",
|
||||
"description": "Geben Sie Ihr Passwort ein.",
|
||||
"resetPassword": "Passwort zurücksetzen",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"password": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Passwort festlegen",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "Ein Code wurde an Ihre E-Mail-Adresse gesendet.",
|
||||
"noCodeReceived": "Keinen Code erhalten?",
|
||||
"resend": "Erneut senden",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"code": "Dieses Feld ist erforderlich",
|
||||
"newPassword": "Bitte geben Sie ein Passwort ein!",
|
||||
"confirmPassword": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Passwort ändern",
|
||||
"description": "Legen Sie das Passwort für Ihr Konto fest",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"newPassword": "Bitte geben Sie ein neues Passwort ein!",
|
||||
"confirmPassword": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Geben Sie Ihre LDAP-Anmeldedaten ein.",
|
||||
"username": "Benutzername",
|
||||
"password": "Passwort",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"username": "Dieses Feld ist erforderlich",
|
||||
"password": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Geben Sie den Code ein, den Sie per E-Mail erhalten haben.",
|
||||
"noCodeReceived": "Keinen Code erhalten?",
|
||||
"resendCode": "Code erneut senden",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"code": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "2-Faktor einrichten",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Geben Sie Ihre Telefonnummer ein, um einen Code per SMS zu erhalten.",
|
||||
"emailDescription": "Geben Sie Ihre E-Mail-Adresse ein, um einen Code per E-Mail zu erhalten.",
|
||||
"totpRegisterDescription": "Scannen Sie den QR-Code oder navigieren Sie manuell zur URL.",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"code": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Passwort festlegen",
|
||||
"description": "Legen Sie das Passwort für Ihr Konto fest",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"password": "Bitte geben Sie ein Passwort ein!",
|
||||
"confirmPassword": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "Dieses Feld ist erforderlich",
|
||||
"lastname": "Dieses Feld ist erforderlich",
|
||||
"email": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "Keinen Code erhalten?",
|
||||
"resendCode": "Code erneut senden",
|
||||
"codeSent": "Ein Code wurde gerade an Ihre E-Mail-Adresse gesendet.",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"code": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Gerätecode",
|
||||
"description": "Geben Sie den Code ein.",
|
||||
"submit": "Weiter"
|
||||
"submit": "Weiter",
|
||||
"required": {
|
||||
"code": "Dieses Feld ist erforderlich"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} möchte eine Verbindung herstellen:",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "Welcome back!",
|
||||
"description": "Enter your login data.",
|
||||
"register": "Register new user",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"loginName": "This field is required"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Password",
|
||||
"description": "Enter your password.",
|
||||
"resetPassword": "Reset Password",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"password": "This field is required"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Set Password",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "A code has been sent to your email address.",
|
||||
"noCodeReceived": "Didn't receive a code?",
|
||||
"resend": "Resend code",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"code": "This field is required",
|
||||
"newPassword": "You have to provide a password!",
|
||||
"confirmPassword": "This field is required"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Change Password",
|
||||
"description": "Set the password for your account",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"newPassword": "You have to provide a new password!",
|
||||
"confirmPassword": "This field is required"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Enter your LDAP credentials.",
|
||||
"username": "Username",
|
||||
"password": "Password",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"username": "This field is required",
|
||||
"password": "This field is required"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Enter the code you received via email.",
|
||||
"noCodeReceived": "Didn't receive a code?",
|
||||
"resendCode": "Resend code",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"code": "This field is required"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Set up 2-Factor",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Enter your phone number to receive a code via SMS.",
|
||||
"emailDescription": "Enter your email address to receive a code via email.",
|
||||
"totpRegisterDescription": "Scan the QR Code or navigate to the URL manually.",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"code": "This field is required"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Set Password",
|
||||
"description": "Set the password for your account",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"password": "You have to provide a password!",
|
||||
"confirmPassword": "This field is required"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "This field is required",
|
||||
"lastname": "This field is required",
|
||||
"email": "This field is required"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "Didn't receive a code?",
|
||||
"resendCode": "Resend code",
|
||||
"codeSent": "A code has just been sent to your email address.",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"code": "This field is required"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Device code",
|
||||
"description": "Enter the code displayed on your app or device.",
|
||||
"submit": "Continue"
|
||||
"submit": "Continue",
|
||||
"required": {
|
||||
"code": "This field is required"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} would like to connect",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "¡Bienvenido de nuevo!",
|
||||
"description": "Introduce tus datos de acceso.",
|
||||
"register": "Registrar nuevo usuario",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"loginName": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Contraseña",
|
||||
"description": "Introduce tu contraseña.",
|
||||
"resetPassword": "Restablecer contraseña",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"password": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Establecer Contraseña",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "Se ha enviado un código a su correo electrónico.",
|
||||
"noCodeReceived": "¿No recibiste un código?",
|
||||
"resend": "Reenviar código",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"code": "Este campo es obligatorio",
|
||||
"newPassword": "¡Debes proporcionar una contraseña!",
|
||||
"confirmPassword": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Cambiar Contraseña",
|
||||
"description": "Establece la contraseña para tu cuenta",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"newPassword": "¡Debes proporcionar una nueva contraseña!",
|
||||
"confirmPassword": "Este campo es obligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Introduce tus credenciales LDAP.",
|
||||
"username": "Nombre de usuario",
|
||||
"password": "Contraseña",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"username": "Este campo es obligatorio",
|
||||
"password": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Introduce el código que recibiste por correo electrónico.",
|
||||
"noCodeReceived": "¿No recibiste un código?",
|
||||
"resendCode": "Reenviar código",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"code": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Configurar autenticación de 2 factores",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Introduce tu número de teléfono para recibir un código por SMS.",
|
||||
"emailDescription": "Introduce tu dirección de correo electrónico para recibir un código por correo electrónico.",
|
||||
"totpRegisterDescription": "Escanea el código QR o navega manualmente a la URL.",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"code": "Este campo es obligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Establecer Contraseña",
|
||||
"description": "Establece la contraseña para tu cuenta",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"password": "¡Debes proporcionar una contraseña!",
|
||||
"confirmPassword": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "Este campo es obligatorio",
|
||||
"lastname": "Este campo es obligatorio",
|
||||
"email": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "¿No recibiste un código?",
|
||||
"resendCode": "Reenviar código",
|
||||
"codeSent": "Se ha enviado un código a tu dirección de correo electrónico.",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"code": "Este campo es obligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Código del dispositivo",
|
||||
"description": "Introduce el código.",
|
||||
"submit": "Continuar"
|
||||
"submit": "Continuar",
|
||||
"required": {
|
||||
"code": "Este campo es obligatorio"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} desea conectarse:",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "Bentornato!",
|
||||
"description": "Inserisci i tuoi dati di accesso.",
|
||||
"register": "Registrati come nuovo utente",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"loginName": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Password",
|
||||
"description": "Inserisci la tua password.",
|
||||
"resetPassword": "Reimposta Password",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"password": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Imposta Password",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "Un codice è stato inviato al tuo indirizzo email.",
|
||||
"noCodeReceived": "Non hai ricevuto un codice?",
|
||||
"resend": "Invia di nuovo",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"code": "Questo campo è obbligatorio",
|
||||
"newPassword": "Devi fornire una password!",
|
||||
"confirmPassword": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Cambia Password",
|
||||
"description": "Imposta la password per il tuo account",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"newPassword": "Devi fornire una nuova password!",
|
||||
"confirmPassword": "Questo campo è obbligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Inserisci le tue credenziali LDAP.",
|
||||
"username": "Nome utente",
|
||||
"password": "Password",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"username": "Questo campo è obbligatorio",
|
||||
"password": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Inserisci il codice ricevuto via email.",
|
||||
"noCodeReceived": "Non hai ricevuto un codice?",
|
||||
"resendCode": "Invia di nuovo il codice",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"code": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Configura l'autenticazione a 2 fattori",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Inserisci il tuo numero di telefono per ricevere un codice via SMS.",
|
||||
"emailDescription": "Inserisci il tuo indirizzo email per ricevere un codice via email.",
|
||||
"totpRegisterDescription": "Scansiona il codice QR o naviga manualmente all'URL.",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"code": "Questo campo è obbligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Imposta Password",
|
||||
"description": "Imposta la password per il tuo account",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"password": "Devi fornire una password!",
|
||||
"confirmPassword": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "Questo campo è obbligatorio",
|
||||
"lastname": "Questo campo è obbligatorio",
|
||||
"email": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "Non hai ricevuto un codice?",
|
||||
"resendCode": "Invia di nuovo il codice",
|
||||
"codeSent": "Un codice è stato appena inviato al tuo indirizzo email.",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"code": "Questo campo è obbligatorio"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Codice dispositivo",
|
||||
"description": "Inserisci il codice.",
|
||||
"submit": "Continua"
|
||||
"submit": "Continua",
|
||||
"required": {
|
||||
"code": "Questo campo è obbligatorio"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} desidera connettersi:",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "Witamy ponownie!",
|
||||
"description": "Wprowadź dane logowania.",
|
||||
"register": "Zarejestruj nowego użytkownika",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"loginName": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Hasło",
|
||||
"description": "Wprowadź swoje hasło.",
|
||||
"resetPassword": "Zresetuj hasło",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"password": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Ustaw hasło",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "Kod został wysłany na twój adres e-mail.",
|
||||
"noCodeReceived": "Nie otrzymałeś kodu?",
|
||||
"resend": "Wyślij kod ponownie",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"code": "To pole jest wymagane",
|
||||
"newPassword": "Musisz podać hasło!",
|
||||
"confirmPassword": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Zmień hasło",
|
||||
"description": "Ustaw nowe hasło dla swojego konta",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"newPassword": "Musisz podać nowe hasło!",
|
||||
"confirmPassword": "To pole jest wymagane"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Wprowadź swoje dane logowania LDAP.",
|
||||
"username": "Nazwa użytkownika",
|
||||
"password": "Hasło",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"username": "To pole jest wymagane",
|
||||
"password": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Wprowadź kod otrzymany e-mailem.",
|
||||
"noCodeReceived": "Nie otrzymałeś kodu?",
|
||||
"resendCode": "Wyślij kod ponownie",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"code": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Skonfiguruj uwierzytelnianie dwuskładnikowe",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Wprowadź swój numer telefonu, aby otrzymać kod SMS-em.",
|
||||
"emailDescription": "Wprowadź swój adres e-mail, aby otrzymać kod e-mailem.",
|
||||
"totpRegisterDescription": "Zeskanuj kod QR lub otwórz adres URL ręcznie.",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"code": "To pole jest wymagane"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Ustaw hasło",
|
||||
"description": "Ustaw hasło dla swojego konta",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"password": "Musisz podać hasło!",
|
||||
"confirmPassword": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "To pole jest wymagane",
|
||||
"lastname": "To pole jest wymagane",
|
||||
"email": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "Nie otrzymałeś kodu?",
|
||||
"resendCode": "Wyślij kod ponownie",
|
||||
"codeSent": "Kod został właśnie wysłany na twój adres e-mail.",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"code": "To pole jest wymagane"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Kod urządzenia",
|
||||
"description": "Wprowadź kod.",
|
||||
"submit": "Kontynuuj"
|
||||
"submit": "Kontynuuj",
|
||||
"required": {
|
||||
"code": "To pole jest wymagane"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} chce się połączyć:",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "С возвращением!",
|
||||
"description": "Введите свои данные для входа.",
|
||||
"register": "Зарегистрировать нового пользователя",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"loginName": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "Пароль",
|
||||
"description": "Введите ваш пароль.",
|
||||
"resetPassword": "Сбросить пароль",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"password": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Установить пароль",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "Код отправлен на ваш адрес электронной почты.",
|
||||
"noCodeReceived": "Не получили код?",
|
||||
"resend": "Отправить код повторно",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"code": "Это поле обязательно для заполнения",
|
||||
"newPassword": "Вы должны указать пароль!",
|
||||
"confirmPassword": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "Изменить пароль",
|
||||
"description": "Установите пароль для вашего аккаунта",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"newPassword": "Вы должны указать новый пароль!",
|
||||
"confirmPassword": "Это поле обязательно для заполнения"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "Введите ваши учетные данные LDAP.",
|
||||
"username": "Имя пользователя",
|
||||
"password": "Пароль",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"username": "Это поле обязательно для заполнения",
|
||||
"password": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "Введите код, полученный по email.",
|
||||
"noCodeReceived": "Не получили код?",
|
||||
"resendCode": "Отправить код повторно",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"code": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "Настройка двухфакторной аутентификации",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "Введите номер телефона для получения кода по SMS.",
|
||||
"emailDescription": "Введите email для получения кода.",
|
||||
"totpRegisterDescription": "Отсканируйте QR-код или перейдите по ссылке вручную.",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"code": "Это поле обязательно для заполнения"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "Установить пароль",
|
||||
"description": "Установите пароль для вашего аккаунта",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"password": "Вы должны указать пароль!",
|
||||
"confirmPassword": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "Это поле обязательно для заполнения",
|
||||
"lastname": "Это поле обязательно для заполнения",
|
||||
"email": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "Не получили код?",
|
||||
"resendCode": "Отправить код повторно",
|
||||
"codeSent": "Код отправлен на ваш email.",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"code": "Это поле обязательно для заполнения"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "Код устройства",
|
||||
"description": "Введите код.",
|
||||
"submit": "Продолжить"
|
||||
"submit": "Продолжить",
|
||||
"required": {
|
||||
"code": "Это поле обязательно для заполнения"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} хочет подключиться:",
|
||||
|
@@ -25,14 +25,20 @@
|
||||
"title": "欢迎回来!",
|
||||
"description": "请输入您的登录信息。",
|
||||
"register": "注册新用户",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"loginName": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"password": {
|
||||
"verify": {
|
||||
"title": "密码",
|
||||
"description": "请输入您的密码。",
|
||||
"resetPassword": "重置密码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"password": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "设置密码",
|
||||
@@ -40,12 +46,21 @@
|
||||
"codeSent": "验证码已发送到您的邮箱。",
|
||||
"noCodeReceived": "没有收到验证码?",
|
||||
"resend": "重发验证码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"code": "此字段为必填项",
|
||||
"newPassword": "必须提供密码!",
|
||||
"confirmPassword": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"change": {
|
||||
"title": "更改密码",
|
||||
"description": "为您的账户设置密码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"newPassword": "必须提供新密码!",
|
||||
"confirmPassword": "此字段为必填项"
|
||||
}
|
||||
}
|
||||
},
|
||||
"idp": {
|
||||
@@ -87,7 +102,11 @@
|
||||
"description": "请输入您的 LDAP 凭据。",
|
||||
"username": "用户名",
|
||||
"password": "密码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"username": "此字段为必填项",
|
||||
"password": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"mfa": {
|
||||
"verify": {
|
||||
@@ -109,7 +128,10 @@
|
||||
"emailDescription": "输入通过电子邮件收到的验证码。",
|
||||
"noCodeReceived": "没有收到验证码?",
|
||||
"resendCode": "重发验证码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"code": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"set": {
|
||||
"title": "设置双因素认证",
|
||||
@@ -117,7 +139,10 @@
|
||||
"smsDescription": "输入您的电话号码以接收短信验证码。",
|
||||
"emailDescription": "输入您的电子邮箱地址以接收电子邮件验证码。",
|
||||
"totpRegisterDescription": "扫描二维码或手动导航到URL。",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"code": "此字段为必填项"
|
||||
}
|
||||
}
|
||||
},
|
||||
"passkey": {
|
||||
@@ -174,7 +199,16 @@
|
||||
"password": {
|
||||
"title": "设置密码",
|
||||
"description": "为您的账户设置密码",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"password": "必须提供密码!",
|
||||
"confirmPassword": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"required": {
|
||||
"firstname": "此字段为必填项",
|
||||
"lastname": "此字段为必填项",
|
||||
"email": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"invite": {
|
||||
@@ -211,7 +245,10 @@
|
||||
"noCodeReceived": "没有收到验证码?",
|
||||
"resendCode": "重发验证码",
|
||||
"codeSent": "刚刚发送了一封包含验证码的电子邮件。",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"code": "此字段为必填项"
|
||||
}
|
||||
}
|
||||
},
|
||||
"authenticator": {
|
||||
@@ -225,7 +262,10 @@
|
||||
"usercode": {
|
||||
"title": "设备代码",
|
||||
"description": "输入代码。",
|
||||
"submit": "继续"
|
||||
"submit": "继续",
|
||||
"required": {
|
||||
"code": "此字段为必填项"
|
||||
}
|
||||
},
|
||||
"request": {
|
||||
"title": "{appName} 想要连接:",
|
||||
|
@@ -15,6 +15,7 @@ import { ChecksSchema } from "@zitadel/proto/zitadel/session/v2/session_service_
|
||||
import { PasswordComplexitySettings } from "@zitadel/proto/zitadel/settings/v2/password_settings_pb";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { FieldValues, useForm } from "react-hook-form";
|
||||
import { Alert } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
@@ -56,6 +57,8 @@ export function ChangePasswordForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("password");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
@@ -156,7 +159,7 @@ export function ChangePasswordForm({
|
||||
autoComplete="new-password"
|
||||
required
|
||||
{...register("password", {
|
||||
required: "You have to provide a new password!",
|
||||
required: t("change.required.newPassword"),
|
||||
})}
|
||||
label="New Password"
|
||||
error={errors.password?.message as string}
|
||||
@@ -169,7 +172,7 @@ export function ChangePasswordForm({
|
||||
required
|
||||
autoComplete="new-password"
|
||||
{...register("confirmPassword", {
|
||||
required: "This field is required",
|
||||
required: t("change.required.confirmPassword"),
|
||||
})}
|
||||
label="Confirm Password"
|
||||
error={errors.confirmPassword?.message as string}
|
||||
|
@@ -4,6 +4,7 @@ import { Alert } from "@/components/alert";
|
||||
import { getDeviceAuthorizationRequest } from "@/lib/server/oidc";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { BackButton } from "./back-button";
|
||||
import { Button, ButtonVariants } from "./button";
|
||||
@@ -25,6 +26,8 @@ export function DeviceCodeForm({ userCode }: { userCode?: string }) {
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("device");
|
||||
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
@@ -62,7 +65,7 @@ export function DeviceCodeForm({ userCode }: { userCode?: string }) {
|
||||
<TextInput
|
||||
type="text"
|
||||
autoComplete="one-time-code"
|
||||
{...register("userCode", { required: "This field is required" })}
|
||||
{...register("userCode", { required: t("usercode.required.code") })}
|
||||
label="Code"
|
||||
data-testid="code-text-input"
|
||||
/>
|
||||
|
@@ -68,7 +68,7 @@ export function LDAPUsernamePasswordForm({ idpId, link }: Props) {
|
||||
<TextInput
|
||||
type="text"
|
||||
autoComplete="username"
|
||||
{...register("loginName", { required: "This field is required" })}
|
||||
{...register("loginName", { required: t("required.username") })}
|
||||
label={t("username")}
|
||||
data-testid="username-text-input"
|
||||
/>
|
||||
@@ -77,7 +77,7 @@ export function LDAPUsernamePasswordForm({ idpId, link }: Props) {
|
||||
<TextInput
|
||||
type="password"
|
||||
autoComplete="password"
|
||||
{...register("password", { required: "This field is required" })}
|
||||
{...register("password", { required: t("required.password") })}
|
||||
label={t("password")}
|
||||
data-testid="password-text-input"
|
||||
/>
|
||||
|
@@ -11,6 +11,7 @@ import { useEffect, useRef, useState } from "react";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { Alert, AlertType } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { Button, ButtonVariants } from "./button";
|
||||
import { TextInput } from "./input";
|
||||
import { Spinner } from "./spinner";
|
||||
@@ -42,6 +43,8 @@ export function LoginOTP({
|
||||
code,
|
||||
loginSettings,
|
||||
}: Props) {
|
||||
const t = useTranslations("otp");
|
||||
|
||||
const [error, setError] = useState<string>("");
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
|
||||
@@ -249,7 +252,7 @@ export function LoginOTP({
|
||||
<div className="mt-4">
|
||||
<TextInput
|
||||
type="text"
|
||||
{...register("code", { required: "This field is required" })}
|
||||
{...register("code", { required: t("verify.required.code") })}
|
||||
label="Code"
|
||||
autoComplete="one-time-code"
|
||||
data-testid="code-text-input"
|
||||
|
@@ -6,6 +6,7 @@ import { ChecksSchema } from "@zitadel/proto/zitadel/session/v2/session_service_
|
||||
import { LoginSettings } from "@zitadel/proto/zitadel/settings/v2/login_settings_pb";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { Alert, AlertType } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
@@ -34,6 +35,8 @@ export function PasswordForm({
|
||||
const { register, handleSubmit, formState } = useForm<Inputs>({
|
||||
mode: "onBlur",
|
||||
});
|
||||
|
||||
const t = useTranslations("password");
|
||||
|
||||
const [info, setInfo] = useState<string>("");
|
||||
const [error, setError] = useState<string>("");
|
||||
@@ -118,7 +121,7 @@ export function PasswordForm({
|
||||
<TextInput
|
||||
type="password"
|
||||
autoComplete="password"
|
||||
{...register("password", { required: "This field is required" })}
|
||||
{...register("password", { required: t("verify.required.password") })}
|
||||
label="Password"
|
||||
data-testid="password-text-input"
|
||||
/>
|
||||
|
@@ -3,6 +3,7 @@
|
||||
import { registerUserAndLinkToIDP } from "@/lib/server/register";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { FieldValues, useForm } from "react-hook-form";
|
||||
import { Alert } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
@@ -54,6 +55,8 @@ export function RegisterFormIDPIncomplete({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("register");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
@@ -102,7 +105,7 @@ export function RegisterFormIDPIncomplete({
|
||||
type="firstname"
|
||||
autoComplete="firstname"
|
||||
required
|
||||
{...register("firstname", { required: "This field is required" })}
|
||||
{...register("firstname", { required: t("required.firstname") })}
|
||||
label="First name"
|
||||
error={errors.firstname?.message as string}
|
||||
data-testid="firstname-text-input"
|
||||
@@ -113,7 +116,7 @@ export function RegisterFormIDPIncomplete({
|
||||
type="lastname"
|
||||
autoComplete="lastname"
|
||||
required
|
||||
{...register("lastname", { required: "This field is required" })}
|
||||
{...register("lastname", { required: t("required.lastname") })}
|
||||
label="Last name"
|
||||
error={errors.lastname?.message as string}
|
||||
data-testid="lastname-text-input"
|
||||
@@ -124,7 +127,7 @@ export function RegisterFormIDPIncomplete({
|
||||
type="email"
|
||||
autoComplete="email"
|
||||
required
|
||||
{...register("email", { required: "This field is required" })}
|
||||
{...register("email", { required: t("required.email") })}
|
||||
label="E-mail"
|
||||
error={errors.email?.message as string}
|
||||
data-testid="email-text-input"
|
||||
|
@@ -8,6 +8,7 @@ import {
|
||||
} from "@zitadel/proto/zitadel/settings/v2/login_settings_pb";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { FieldValues, useForm } from "react-hook-form";
|
||||
import { Alert, AlertType } from "./alert";
|
||||
import {
|
||||
@@ -60,6 +61,8 @@ export function RegisterForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("register");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
const [selected, setSelected] = useState<AuthenticationMethod>(methods[0]);
|
||||
const [error, setError] = useState<string>("");
|
||||
@@ -130,7 +133,7 @@ export function RegisterForm({
|
||||
type="firstname"
|
||||
autoComplete="firstname"
|
||||
required
|
||||
{...register("firstname", { required: "This field is required" })}
|
||||
{...register("firstname", { required: t("required.firstname") })}
|
||||
label="First name"
|
||||
error={errors.firstname?.message as string}
|
||||
data-testid="firstname-text-input"
|
||||
@@ -141,7 +144,7 @@ export function RegisterForm({
|
||||
type="lastname"
|
||||
autoComplete="lastname"
|
||||
required
|
||||
{...register("lastname", { required: "This field is required" })}
|
||||
{...register("lastname", { required: t("required.lastname") })}
|
||||
label="Last name"
|
||||
error={errors.lastname?.message as string}
|
||||
data-testid="lastname-text-input"
|
||||
@@ -152,7 +155,7 @@ export function RegisterForm({
|
||||
type="email"
|
||||
autoComplete="email"
|
||||
required
|
||||
{...register("email", { required: "This field is required" })}
|
||||
{...register("email", { required: t("required.email") })}
|
||||
label="E-mail"
|
||||
error={errors.email?.message as string}
|
||||
data-testid="email-text-input"
|
||||
|
@@ -16,6 +16,7 @@ import { ChecksSchema } from "@zitadel/proto/zitadel/session/v2/session_service_
|
||||
import { PasswordComplexitySettings } from "@zitadel/proto/zitadel/settings/v2/password_settings_pb";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { FieldValues, useForm } from "react-hook-form";
|
||||
import { Alert, AlertType } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
@@ -59,6 +60,8 @@ export function SetPasswordForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("password");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
@@ -216,7 +219,7 @@ export function SetPasswordForm({
|
||||
type="text"
|
||||
required
|
||||
{...register("code", {
|
||||
required: "This field is required",
|
||||
required: t("set.required.code"),
|
||||
})}
|
||||
label="Code"
|
||||
autoComplete="one-time-code"
|
||||
@@ -231,7 +234,7 @@ export function SetPasswordForm({
|
||||
autoComplete="new-password"
|
||||
required
|
||||
{...register("password", {
|
||||
required: "You have to provide a password!",
|
||||
required: t("set.required.newPassword"),
|
||||
})}
|
||||
label="New Password"
|
||||
error={errors.password?.message as string}
|
||||
@@ -244,7 +247,7 @@ export function SetPasswordForm({
|
||||
required
|
||||
autoComplete="new-password"
|
||||
{...register("confirmPassword", {
|
||||
required: "This field is required",
|
||||
required: t("set.required.confirmPassword"),
|
||||
})}
|
||||
label="Confirm Password"
|
||||
error={errors.confirmPassword?.message as string}
|
||||
|
@@ -10,6 +10,7 @@ import { registerUser } from "@/lib/server/register";
|
||||
import { PasswordComplexitySettings } from "@zitadel/proto/zitadel/settings/v2/password_settings_pb";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { FieldValues, useForm } from "react-hook-form";
|
||||
import { Alert } from "./alert";
|
||||
import { BackButton } from "./back-button";
|
||||
@@ -52,6 +53,8 @@ export function SetRegisterPasswordForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("register");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
@@ -115,7 +118,7 @@ export function SetRegisterPasswordForm({
|
||||
autoComplete="new-password"
|
||||
required
|
||||
{...register("password", {
|
||||
required: "You have to provide a password!",
|
||||
required: t("password.required.password"),
|
||||
})}
|
||||
label="Password"
|
||||
error={errors.password?.message as string}
|
||||
@@ -128,7 +131,7 @@ export function SetRegisterPasswordForm({
|
||||
required
|
||||
autoComplete="new-password"
|
||||
{...register("confirmPassword", {
|
||||
required: "This field is required",
|
||||
required: t("password.required.confirmPassword"),
|
||||
})}
|
||||
label="Confirm Password"
|
||||
error={errors.confirmPassword?.message as string}
|
||||
|
@@ -7,6 +7,7 @@ import Link from "next/link";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { QRCodeSVG } from "qrcode.react";
|
||||
import { useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { Alert } from "./alert";
|
||||
import { Button, ButtonVariants } from "./button";
|
||||
@@ -50,6 +51,8 @@ export function TotpRegister({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("otp");
|
||||
|
||||
async function continueWithCode(values: Inputs) {
|
||||
setLoading(true);
|
||||
return verifyTOTP(values.code, loginName, organization)
|
||||
@@ -123,7 +126,7 @@ export function TotpRegister({
|
||||
<div className="">
|
||||
<TextInput
|
||||
type="text"
|
||||
{...register("code", { required: "This field is required" })}
|
||||
{...register("code", { required: t("set.required.code") })}
|
||||
label="Code"
|
||||
data-testid="code-text-input"
|
||||
/>
|
||||
|
@@ -11,6 +11,7 @@ import { Button, ButtonVariants } from "./button";
|
||||
import { TextInput } from "./input";
|
||||
import { Spinner } from "./spinner";
|
||||
import { Translated } from "./translated";
|
||||
import { useTranslations } from "next-intl";
|
||||
|
||||
type Inputs = {
|
||||
loginName: string;
|
||||
@@ -42,6 +43,8 @@ export function UsernameForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("loginname");
|
||||
|
||||
const router = useRouter();
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
@@ -101,7 +104,7 @@ export function UsernameForm({
|
||||
<TextInput
|
||||
type="text"
|
||||
autoComplete="username"
|
||||
{...register("loginName", { required: "This field is required" })}
|
||||
{...register("loginName", { required: t("required.loginName") })}
|
||||
label={inputLabel}
|
||||
data-testid="username-text-input"
|
||||
suffix={suffix}
|
||||
|
@@ -4,6 +4,7 @@ import { Alert, AlertType } from "@/components/alert";
|
||||
import { resendVerification, sendVerification } from "@/lib/server/verify";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useCallback, useEffect, useState } from "react";
|
||||
import { useTranslations } from "next-intl";
|
||||
import { useForm } from "react-hook-form";
|
||||
import { BackButton } from "./back-button";
|
||||
import { Button, ButtonVariants } from "./button";
|
||||
@@ -41,6 +42,8 @@ export function VerifyForm({
|
||||
},
|
||||
});
|
||||
|
||||
const t = useTranslations("verify");
|
||||
|
||||
const [error, setError] = useState<string>("");
|
||||
|
||||
const [loading, setLoading] = useState<boolean>(false);
|
||||
@@ -135,7 +138,7 @@ export function VerifyForm({
|
||||
<TextInput
|
||||
type="text"
|
||||
autoComplete="one-time-code"
|
||||
{...register("code", { required: "This field is required" })}
|
||||
{...register("code", { required: t("verify.required.code") })}
|
||||
label="Code"
|
||||
data-testid="code-text-input"
|
||||
/>
|
||||
|
Reference in New Issue
Block a user