@authagonal/login 0.1.97

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. package/README.md +348 -0
  2. package/dist/App.d.ts +1 -0
  3. package/dist/api.d.ts +35 -0
  4. package/dist/branding.d.ts +22 -0
  5. package/dist/branding.json +8 -0
  6. package/dist/components/AuthLayout.d.ts +7 -0
  7. package/dist/components/ui/alert.d.ts +9 -0
  8. package/dist/components/ui/button.d.ts +11 -0
  9. package/dist/components/ui/card.d.ts +8 -0
  10. package/dist/components/ui/input.d.ts +3 -0
  11. package/dist/components/ui/label.d.ts +3 -0
  12. package/dist/components/ui/separator.d.ts +6 -0
  13. package/dist/favicon.svg +1 -0
  14. package/dist/hooks/useDarkMode.d.ts +6 -0
  15. package/dist/i18n/index.d.ts +2 -0
  16. package/dist/icons.svg +24 -0
  17. package/dist/index.css +3 -0
  18. package/dist/index.d.ts +23 -0
  19. package/dist/index.js +6332 -0
  20. package/dist/lib/utils.d.ts +2 -0
  21. package/dist/main.d.ts +2 -0
  22. package/dist/pages/ConsentPage.d.ts +1 -0
  23. package/dist/pages/DevicePage.d.ts +1 -0
  24. package/dist/pages/ForgotPasswordPage.d.ts +1 -0
  25. package/dist/pages/GrantsPage.d.ts +1 -0
  26. package/dist/pages/LoginPage.d.ts +1 -0
  27. package/dist/pages/MfaChallengePage.d.ts +1 -0
  28. package/dist/pages/MfaSetupPage.d.ts +1 -0
  29. package/dist/pages/RegisterPage.d.ts +1 -0
  30. package/dist/pages/ResetPasswordPage.d.ts +1 -0
  31. package/dist/types.d.ts +91 -0
  32. package/index.html +13 -0
  33. package/package.json +65 -0
  34. package/public/branding.json +8 -0
  35. package/public/favicon.svg +1 -0
  36. package/public/icons.svg +24 -0
  37. package/src/App.tsx +32 -0
  38. package/src/api.ts +156 -0
  39. package/src/branding.ts +55 -0
  40. package/src/components/AuthLayout.tsx +107 -0
  41. package/src/components/ui/alert.tsx +31 -0
  42. package/src/components/ui/button.tsx +51 -0
  43. package/src/components/ui/card.tsx +50 -0
  44. package/src/components/ui/input.tsx +21 -0
  45. package/src/components/ui/label.tsx +17 -0
  46. package/src/components/ui/separator.tsx +16 -0
  47. package/src/hooks/useDarkMode.ts +39 -0
  48. package/src/i18n/de.json +111 -0
  49. package/src/i18n/en.json +136 -0
  50. package/src/i18n/es.json +111 -0
  51. package/src/i18n/fr.json +111 -0
  52. package/src/i18n/index.ts +39 -0
  53. package/src/i18n/pt.json +111 -0
  54. package/src/i18n/tlh.json +111 -0
  55. package/src/i18n/vi.json +111 -0
  56. package/src/i18n/zh-Hans.json +111 -0
  57. package/src/index.ts +44 -0
  58. package/src/lib/utils.ts +6 -0
  59. package/src/main.tsx +19 -0
  60. package/src/pages/ConsentPage.tsx +144 -0
  61. package/src/pages/DevicePage.tsx +145 -0
  62. package/src/pages/ForgotPasswordPage.tsx +90 -0
  63. package/src/pages/GrantsPage.tsx +87 -0
  64. package/src/pages/LoginPage.tsx +423 -0
  65. package/src/pages/MfaChallengePage.tsx +246 -0
  66. package/src/pages/MfaSetupPage.tsx +366 -0
  67. package/src/pages/RegisterPage.tsx +161 -0
  68. package/src/pages/ResetPasswordPage.tsx +219 -0
  69. package/src/styles.css +33 -0
  70. package/src/types.ts +112 -0
  71. package/tsconfig.app.json +37 -0
  72. package/tsconfig.json +7 -0
  73. package/vite.config.ts +54 -0
@@ -0,0 +1,111 @@
1
+ {
2
+ "signIn": "Se connecter",
3
+ "email": "E-mail",
4
+ "password": "Mot de passe",
5
+ "emailPlaceholder": "you@example.com",
6
+ "passwordPlaceholder": "Entrez votre mot de passe",
7
+ "signingIn": "Connexion en cours...",
8
+ "forgotPassword": "Mot de passe oublié ?",
9
+ "ssoChecking": "Vérification des options de connexion...",
10
+ "ssoNotice": "Votre organisation utilise l'authentification unique",
11
+ "continueWithSso": "Continuer avec SSO",
12
+ "errorInvalidCredentials": "E-mail ou mot de passe invalide",
13
+ "errorLockedOut": "Compte verrouillé. Réessayez dans {{seconds}} secondes",
14
+ "errorEmailNotConfirmed": "Veuillez vérifier votre e-mail pour confirmer votre compte",
15
+ "errorSsoRequired": "L'authentification unique est requise pour ce compte",
16
+ "errorEmailRequired": "L'e-mail est requis",
17
+ "errorPasswordRequired": "Le mot de passe est requis",
18
+ "errorUnexpected": "Une erreur inattendue s'est produite. Veuillez réessayer.",
19
+ "resetYourPassword": "Réinitialiser votre mot de passe",
20
+ "resetSubtitle": "Entrez votre adresse e-mail et nous vous enverrons un lien pour réinitialiser votre mot de passe.",
21
+ "sending": "Envoi en cours...",
22
+ "sendResetLink": "Envoyer le lien de réinitialisation",
23
+ "backToSignIn": "Retour à la connexion",
24
+ "checkYourEmail": "Vérifiez votre e-mail",
25
+ "resetEmailSent": "Si un compte existe avec cette adresse e-mail, vous recevrez un lien de réinitialisation sous peu.",
26
+ "setNewPassword": "Définir un nouveau mot de passe",
27
+ "newPassword": "Nouveau mot de passe",
28
+ "newPasswordPlaceholder": "Entrez le nouveau mot de passe",
29
+ "confirmPassword": "Confirmer le mot de passe",
30
+ "confirmPasswordPlaceholder": "Confirmez le nouveau mot de passe",
31
+ "resetting": "Réinitialisation en cours...",
32
+ "resetPassword": "Réinitialiser le mot de passe",
33
+ "passwordResetSuccess": "Mot de passe réinitialisé avec succès",
34
+ "passwordResetSuccessMessage": "Votre mot de passe a été réinitialisé. Vous pouvez maintenant vous connecter avec votre nouveau mot de passe.",
35
+ "invalidLink": "Lien invalide",
36
+ "invalidOrExpiredLink": "Ce lien de réinitialisation est invalide ou a expiré.",
37
+ "requestNewResetLink": "Demander un nouveau lien de réinitialisation",
38
+ "passwordNotMeetRequirements": "Le mot de passe ne répond pas aux exigences",
39
+ "passwordsDoNotMatch": "Les mots de passe ne correspondent pas",
40
+ "passwordWeakError": "Le mot de passe ne répond pas aux exigences de robustesse",
41
+ "signInTitle": "Connexion — {{appName}}",
42
+ "ruleMinLength": "Au moins {{count}} caractères",
43
+ "ruleUppercase": "Lettre majuscule",
44
+ "ruleLowercase": "Lettre minuscule",
45
+ "ruleDigit": "Chiffre",
46
+ "ruleSpecialChar": "Caractère spécial",
47
+ "continueWith": "Continuer avec {{provider}}",
48
+ "or": "ou",
49
+ "signedInAs": "Connect\u00e9 en tant que {{name}}",
50
+ "signedInMessage": "Vous \u00eates d\u00e9j\u00e0 authentifi\u00e9.",
51
+ "welcomeTitle": "Bienvenue sur {{appName}}",
52
+ "welcomeSubtitle": "Connectez-vous pour acc\u00e9der \u00e0 votre compte",
53
+ "signOut": "Se déconnecte",
54
+ "mfaTitle": "Authentification à deux facteurs",
55
+ "mfaSubtitle": "Entrez le code de vérification pour continuer",
56
+ "mfaMethodTotp": "Authentificateur",
57
+ "mfaMethodRecovery": "Code de récupération",
58
+ "mfaTotpLabel": "Code à 6 chiffres",
59
+ "mfaRecoveryLabel": "Code de récupération",
60
+ "mfaVerify": "Vérifier",
61
+ "mfaVerifying": "Vérification en cours...",
62
+ "mfaInvalidCode": "Code invalide. Veuillez réessayer.",
63
+ "mfaChallengeExpired": "Session de vérification expirée. Veuillez vous reconnecter.",
64
+ "mfaSetupTitle": "Authentification multifacteur",
65
+ "mfaStatusEnabled": "L'AMF est activée sur votre compte.",
66
+ "mfaStatusDisabled": "L'AMF n'est pas encore configurée.",
67
+ "mfaEnrolledMethods": "Méthodes enregistrées",
68
+ "mfaAddedOn": "Ajouté le {{date}}",
69
+ "mfaRemove": "Supprimer",
70
+ "mfaSetupTotp": "Configurer une application d'authentification",
71
+ "mfaScanQrCode": "Scannez ce code QR avec votre application d'authentification",
72
+ "mfaEnterCode": "Entrez le code de votre application",
73
+ "mfaConfirm": "Confirmer",
74
+ "mfaTotpAlreadyEnrolled": "Une application d'authentification est déjà enregistrée.",
75
+ "mfaGenerateRecoveryCodes": "Générer des codes de récupération",
76
+ "mfaRegenerateRecoveryCodes": "Régénérer les codes de récupération",
77
+ "mfaRecoveryCodesTitle": "Codes de récupération",
78
+ "mfaRecoveryCodesWarning": "Conservez ces codes dans un endroit sûr. Chaque code ne peut être utilisé qu'une seule fois.",
79
+ "mfaRecoveryRequiresPrimary": "Configurez d'abord une application d'authentification.",
80
+ "mfaMethodWebAuthn": "Passkey",
81
+ "mfaUsePasskey": "Utiliser un passkey",
82
+ "mfaSetupPasskey": "Configurer un passkey",
83
+ "mfaWebAuthnCancelled": "L'authentification par passkey a été annulée.",
84
+ "mfaManualKeyLabel": "Ou entrez cette clé manuellement :",
85
+ "mfaCopyKey": "Cliquer pour copier",
86
+ "mfaSkipSetup": "Passer pour l'instant",
87
+ "mfaBackToApp": "Retour à l'application",
88
+ "mfaDone": "Terminé",
89
+ "mfaLoading": "Chargement...",
90
+ "mfaPromptTitle": "Sécurisez votre compte",
91
+ "mfaPromptMessage": "Ajoutez l'authentification multifacteur pour protéger votre compte avec une couche de sécurité supplémentaire.",
92
+ "mfaPromptSetup": "Configurer l'AMF",
93
+ "mfaPromptSkip": "Pas maintenant",
94
+ "noAccount": "Pas encore de compte ?",
95
+ "createAccount": "Créer un compte",
96
+ "continue": "Continuer",
97
+ "orSignInWith": "Ou se connecter avec {{provider}}",
98
+ "registerTitle": "Créer un compte",
99
+ "firstName": "Prénom",
100
+ "firstNamePlaceholder": "Jean",
101
+ "lastName": "Nom",
102
+ "lastNamePlaceholder": "Dupont",
103
+ "registering": "Création du compte...",
104
+ "registerButton": "Créer un compte",
105
+ "alreadyHaveAccount": "Déjà un compte ?",
106
+ "registrationSuccess": "Inscription réussie ! Veuillez vérifier votre e-mail pour confirmer votre compte, puis connectez-vous.",
107
+ "errorEmailAlreadyRegistered": "Un compte avec cet e-mail existe déjà.",
108
+ "errorWeakPassword": "Le mot de passe ne respecte pas les exigences.",
109
+ "errorEmailAndPasswordRequired": "L'e-mail et le mot de passe sont requis.",
110
+ "errorRegistrationFailed": "L'inscription a échoué. Veuillez réessayer."
111
+ }
@@ -0,0 +1,39 @@
1
+ import i18n from 'i18next';
2
+ import { initReactI18next } from 'react-i18next';
3
+ import LanguageDetector from 'i18next-browser-languagedetector';
4
+
5
+ import en from './en.json';
6
+ import zhHans from './zh-Hans.json';
7
+ import de from './de.json';
8
+ import fr from './fr.json';
9
+ import es from './es.json';
10
+ import vi from './vi.json';
11
+ import pt from './pt.json';
12
+ import tlh from './tlh.json';
13
+
14
+ i18n
15
+ .use(LanguageDetector)
16
+ .use(initReactI18next)
17
+ .init({
18
+ resources: {
19
+ en: { translation: en },
20
+ 'zh-Hans': { translation: zhHans },
21
+ de: { translation: de },
22
+ fr: { translation: fr },
23
+ es: { translation: es },
24
+ vi: { translation: vi },
25
+ pt: { translation: pt },
26
+ tlh: { translation: tlh },
27
+ },
28
+ fallbackLng: 'en',
29
+ interpolation: {
30
+ escapeValue: false,
31
+ },
32
+ detection: {
33
+ order: ['localStorage', 'querystring', 'navigator'],
34
+ lookupQuerystring: 'lng',
35
+ caches: ['localStorage'],
36
+ },
37
+ });
38
+
39
+ export default i18n;
@@ -0,0 +1,111 @@
1
+ {
2
+ "signIn": "Entrar",
3
+ "email": "E-mail",
4
+ "password": "Senha",
5
+ "emailPlaceholder": "voce@exemplo.com",
6
+ "passwordPlaceholder": "Introduza a sua senha",
7
+ "signingIn": "A entrar...",
8
+ "forgotPassword": "Esqueceu a senha?",
9
+ "ssoChecking": "A verificar opções de início de sessão...",
10
+ "ssoNotice": "A sua organização utiliza início de sessão único",
11
+ "continueWithSso": "Continuar com SSO",
12
+ "errorInvalidCredentials": "E-mail ou senha inválidos",
13
+ "errorLockedOut": "Conta bloqueada. Tente novamente em {{seconds}} segundos",
14
+ "errorEmailNotConfirmed": "Verifique o seu e-mail para confirmar a sua conta",
15
+ "errorSsoRequired": "O início de sessão único é obrigatório para esta conta",
16
+ "errorEmailRequired": "O e-mail é obrigatório",
17
+ "errorPasswordRequired": "A senha é obrigatória",
18
+ "errorUnexpected": "Ocorreu um erro inesperado. Tente novamente.",
19
+ "resetYourPassword": "Redefinir a sua senha",
20
+ "resetSubtitle": "Introduza o seu endereço de e-mail e enviaremos um link para redefinir a sua senha.",
21
+ "sending": "A enviar...",
22
+ "sendResetLink": "Enviar link de redefinição",
23
+ "backToSignIn": "Voltar ao início de sessão",
24
+ "checkYourEmail": "Verifique o seu e-mail",
25
+ "resetEmailSent": "Se existir uma conta com esse e-mail, receberá um link de redefinição em breve.",
26
+ "setNewPassword": "Definir nova senha",
27
+ "newPassword": "Nova senha",
28
+ "newPasswordPlaceholder": "Introduza a nova senha",
29
+ "confirmPassword": "Confirmar senha",
30
+ "confirmPasswordPlaceholder": "Confirme a nova senha",
31
+ "resetting": "A redefinir...",
32
+ "resetPassword": "Redefinir senha",
33
+ "passwordResetSuccess": "Senha redefinida com sucesso",
34
+ "passwordResetSuccessMessage": "A sua senha foi redefinida. Pode agora entrar com a sua nova senha.",
35
+ "invalidLink": "Link inválido",
36
+ "invalidOrExpiredLink": "Este link de redefinição é inválido ou expirou.",
37
+ "requestNewResetLink": "Solicitar um novo link de redefinição",
38
+ "passwordNotMeetRequirements": "A senha não cumpre os requisitos",
39
+ "passwordsDoNotMatch": "As senhas não coincidem",
40
+ "passwordWeakError": "A senha não atende aos requisitos de segurança",
41
+ "signInTitle": "Entrar — {{appName}}",
42
+ "ruleMinLength": "Pelo menos {{count}} caracteres",
43
+ "ruleUppercase": "Letra maiúscula",
44
+ "ruleLowercase": "Letra minúscula",
45
+ "ruleDigit": "Número",
46
+ "ruleSpecialChar": "Caractere especial",
47
+ "continueWith": "Continuar com {{provider}}",
48
+ "or": "ou",
49
+ "signedInAs": "Conectado como {{name}}",
50
+ "signedInMessage": "Você já está autenticado.",
51
+ "welcomeTitle": "Bem-vindo ao {{appName}}",
52
+ "welcomeSubtitle": "Entre para acessar sua conta",
53
+ "signOut": "Sair",
54
+ "mfaTitle": "Autenticação de dois fatores",
55
+ "mfaSubtitle": "Insira o código de verificação para continuar",
56
+ "mfaMethodTotp": "Autenticador",
57
+ "mfaMethodRecovery": "Código de recuperação",
58
+ "mfaTotpLabel": "Código de 6 dígitos",
59
+ "mfaRecoveryLabel": "Código de recuperação",
60
+ "mfaVerify": "Verificar",
61
+ "mfaVerifying": "A verificar...",
62
+ "mfaInvalidCode": "Código inválido. Tente novamente.",
63
+ "mfaChallengeExpired": "Sessão de verificação expirada. Faça login novamente.",
64
+ "mfaSetupTitle": "Autenticação multifator",
65
+ "mfaStatusEnabled": "A MFA está ativada na sua conta.",
66
+ "mfaStatusDisabled": "A MFA ainda não está configurada.",
67
+ "mfaEnrolledMethods": "Métodos registados",
68
+ "mfaAddedOn": "Adicionado em {{date}}",
69
+ "mfaRemove": "Remover",
70
+ "mfaSetupTotp": "Configurar aplicação de autenticação",
71
+ "mfaScanQrCode": "Digitalize este código QR com a sua aplicação de autenticação",
72
+ "mfaEnterCode": "Insira o código da sua aplicação",
73
+ "mfaConfirm": "Confirmar",
74
+ "mfaTotpAlreadyEnrolled": "Uma aplicação de autenticação já está registada.",
75
+ "mfaGenerateRecoveryCodes": "Gerar códigos de recuperação",
76
+ "mfaRegenerateRecoveryCodes": "Regenerar códigos de recuperação",
77
+ "mfaRecoveryCodesTitle": "Códigos de recuperação",
78
+ "mfaRecoveryCodesWarning": "Guarde estes códigos num local seguro. Cada código só pode ser usado uma vez.",
79
+ "mfaRecoveryRequiresPrimary": "Configure primeiro uma aplicação de autenticação.",
80
+ "mfaMethodWebAuthn": "Passkey",
81
+ "mfaUsePasskey": "Usar passkey",
82
+ "mfaSetupPasskey": "Configurar passkey",
83
+ "mfaWebAuthnCancelled": "A autenticação por passkey foi cancelada.",
84
+ "mfaManualKeyLabel": "Ou introduza esta chave manualmente:",
85
+ "mfaCopyKey": "Clique para copiar",
86
+ "mfaSkipSetup": "Ignorar por agora",
87
+ "mfaBackToApp": "Voltar ao aplicativo",
88
+ "mfaDone": "Concluído",
89
+ "mfaLoading": "A carregar...",
90
+ "mfaPromptTitle": "Proteja a sua conta",
91
+ "mfaPromptMessage": "Adicione a autenticação multifator para proteger a sua conta com uma camada extra de segurança.",
92
+ "mfaPromptSetup": "Configurar MFA",
93
+ "mfaPromptSkip": "Agora não",
94
+ "noAccount": "Não tem conta?",
95
+ "createAccount": "Criar uma",
96
+ "continue": "Continuar",
97
+ "orSignInWith": "Ou entrar com {{provider}}",
98
+ "registerTitle": "Criar conta",
99
+ "firstName": "Nome",
100
+ "firstNamePlaceholder": "João",
101
+ "lastName": "Apelido",
102
+ "lastNamePlaceholder": "Silva",
103
+ "registering": "A criar conta...",
104
+ "registerButton": "Criar conta",
105
+ "alreadyHaveAccount": "Já tem conta?",
106
+ "registrationSuccess": "Registo efetuado com sucesso! Verifique o seu e-mail para confirmar a conta e depois inicie sessão.",
107
+ "errorEmailAlreadyRegistered": "Já existe uma conta com este e-mail.",
108
+ "errorWeakPassword": "A palavra-passe não cumpre os requisitos.",
109
+ "errorEmailAndPasswordRequired": "E-mail e palavra-passe são obrigatórios.",
110
+ "errorRegistrationFailed": "O registo falhou. Tente novamente."
111
+ }
@@ -0,0 +1,111 @@
1
+ {
2
+ "signIn": "yI'el",
3
+ "email": "QIn nab",
4
+ "password": "mu'wIj pegh",
5
+ "emailPlaceholder": "SoH@pIqaD.tlh",
6
+ "passwordPlaceholder": "mu'wIj pegh yIngu'",
7
+ "signingIn": "'elmeH...",
8
+ "forgotPassword": "mu'wIj pegh lIjpu'?",
9
+ "ssoChecking": "'elmeH mIw vItlhutlh...",
10
+ "ssoNotice": "DIvI' potlh 'elmeH mIw lo'",
11
+ "continueWithSso": "SSO yIlo' yI'el",
12
+ "errorInvalidCredentials": "QIn nab pagh mu'wIj pegh muj",
13
+ "errorLockedOut": "De'wI' botlh. {{seconds}} lup yIloS",
14
+ "errorEmailNotConfirmed": "QIn nab yIchov",
15
+ "errorSsoRequired": "SSO 'elmeH mIw nIteb lo'nISlu'",
16
+ "errorEmailRequired": "QIn nab nIteb nISlu'",
17
+ "errorPasswordRequired": "mu'wIj pegh nIteb nISlu'",
18
+ "errorUnexpected": "Qagh qaS. yInIDqa'.",
19
+ "resetYourPassword": "mu'wIj pegh yIchoH",
20
+ "resetSubtitle": "QIn nab yIngu'. mu'wIj pegh choHmeH lIngwI' DangeH.",
21
+ "sending": "ngeHmeH...",
22
+ "sendResetLink": "choHmeH lIngwI' yIngeH",
23
+ "backToSignIn": "yI'el lutvam yIchegh",
24
+ "checkYourEmail": "QIn nab yISam",
25
+ "resetEmailSent": "QIn nab tu'lu'chugh, choHmeH lIngwI' DaHjaj DangeH.",
26
+ "setNewPassword": "mu'wIj pegh chu' yIchen",
27
+ "newPassword": "mu'wIj pegh chu'",
28
+ "newPasswordPlaceholder": "mu'wIj pegh chu' yIngu'",
29
+ "confirmPassword": "mu'wIj pegh chu' yIchov",
30
+ "confirmPasswordPlaceholder": "mu'wIj pegh chu' yIchov",
31
+ "resetting": "choHmeH...",
32
+ "resetPassword": "mu'wIj pegh yIchoH",
33
+ "passwordResetSuccess": "mu'wIj pegh choHta'",
34
+ "passwordResetSuccessMessage": "mu'wIj pegh choHlu'pu'. DaH mu'wIj pegh chu' DayI'el.",
35
+ "invalidLink": "lIngwI' muj",
36
+ "invalidOrExpiredLink": "lIngwI' muj pagh Qav.",
37
+ "requestNewResetLink": "lIngwI' chu' yItlhob",
38
+ "passwordNotMeetRequirements": "mu'wIj pegh pItlh pus",
39
+ "passwordsDoNotMatch": "mu'wIj pegh rap be'",
40
+ "passwordWeakError": "mu'wIj pegh pItlh pus",
41
+ "signInTitle": "yI'el — {{appName}}",
42
+ "ruleMinLength": "ngI' {{count}} mI' chen",
43
+ "ruleUppercase": "ngaS tIn",
44
+ "ruleLowercase": "ngaS mach",
45
+ "ruleDigit": "mI'",
46
+ "ruleSpecialChar": "Degh le'",
47
+ "continueWith": "{{provider}} yIlo' yI'el",
48
+ "or": "pagh",
49
+ "signedInAs": "{{name}} 'oH SoH",
50
+ "signedInMessage": "SoH 'elpu'.",
51
+ "welcomeTitle": "{{appName}} yI'el",
52
+ "welcomeSubtitle": "De'wI' yI'el",
53
+ "signOut": "yImej",
54
+ "mfaTitle": "cha' nger toblu'meH",
55
+ "mfaSubtitle": "mI' pegh yIngu' bIghHa'meH",
56
+ "mfaMethodTotp": "tobmeH jan",
57
+ "mfaMethodRecovery": "cheghmeH mI'",
58
+ "mfaTotpLabel": "mI' pegh jav",
59
+ "mfaRecoveryLabel": "cheghmeH mI'",
60
+ "mfaVerify": "yItob",
61
+ "mfaVerifying": "toblu'...",
62
+ "mfaInvalidCode": "mI' muj. yInIDqa'.",
63
+ "mfaChallengeExpired": "tobmeH poH Qav. yI'elqa'.",
64
+ "mfaSetupTitle": "law' nger toblu'meH",
65
+ "mfaStatusEnabled": "MFA Qaplu'.",
66
+ "mfaStatusDisabled": "MFA chenbe'.",
67
+ "mfaEnrolledMethods": "mIw qellu'pu'bogh",
68
+ "mfaAddedOn": "{{date}} chelta'",
69
+ "mfaRemove": "yIteq",
70
+ "mfaSetupTotp": "tobmeH jan yIchen",
71
+ "mfaScanQrCode": "QR mI' yIlaD tobmeH jan lo'",
72
+ "mfaEnterCode": "jan mI' yIngu'",
73
+ "mfaConfirm": "yIchov",
74
+ "mfaTotpAlreadyEnrolled": "tobmeH jan qelta'.",
75
+ "mfaGenerateRecoveryCodes": "cheghmeH mI' yIchen",
76
+ "mfaRegenerateRecoveryCodes": "cheghmeH mI' yIchenqa'",
77
+ "mfaRecoveryCodesTitle": "cheghmeH mI'mey",
78
+ "mfaRecoveryCodesWarning": "mI'mey yIQong Daq QaQ. wa' mI' wa'logh lo'lu'.",
79
+ "mfaRecoveryRequiresPrimary": "tobmeH jan yIchenpa'.",
80
+ "mfaMethodWebAuthn": "ngaSchu'wI'",
81
+ "mfaUsePasskey": "ngaSchu'wI' lo'",
82
+ "mfaSetupPasskey": "ngaSchu'wI' chen",
83
+ "mfaWebAuthnCancelled": "ngaSchu'wI' toblu'pu' 'ej mevlu'.",
84
+ "mfaManualKeyLabel": "pagh De' ngu'wI' yIlo':",
85
+ "mfaCopyKey": "ghItlhmeH yIHmey",
86
+ "mfaSkipSetup": "DaH yImev",
87
+ "mfaBackToApp": "ngoQ chegh",
88
+ "mfaDone": "pItlh",
89
+ "mfaLoading": "loDlu'...",
90
+ "mfaPromptTitle": "De'wI' yIQan",
91
+ "mfaPromptMessage": "law' nger toblu'meH yIchel. De'wI' tIQ QanmeH 'ej HoS QaH.",
92
+ "mfaPromptSetup": "MFA yIchen",
93
+ "mfaPromptSkip": "DaH Qo'",
94
+ "noAccount": "De'wI' ghajbe'?",
95
+ "createAccount": "yIchenmoH",
96
+ "continue": "yItaH",
97
+ "orSignInWith": "pagh {{provider}} yIlo' yI'el",
98
+ "registerTitle": "De'wI' yIchenmoH",
99
+ "firstName": "pong wa'DIch",
100
+ "firstNamePlaceholder": "worf",
101
+ "lastName": "pong qorDu'",
102
+ "lastNamePlaceholder": "mogh puqloD",
103
+ "registering": "De'wI' chenmoHlu'...",
104
+ "registerButton": "De'wI' yIchenmoH",
105
+ "alreadyHaveAccount": "De'wI' Daghaj'a'?",
106
+ "registrationSuccess": "QapHa'! QIn yInIDqa' 'ej yI'el.",
107
+ "errorEmailAlreadyRegistered": "De'wI' chenpu'.",
108
+ "errorWeakPassword": "mu'HaqHom puj.",
109
+ "errorEmailAndPasswordRequired": "QIn 'ej mu'HaqHom poQlu'.",
110
+ "errorRegistrationFailed": "chenmoH luj. yInIDqa'."
111
+ }
@@ -0,0 +1,111 @@
1
+ {
2
+ "signIn": "Đăng nhập",
3
+ "email": "Email",
4
+ "password": "Mật khẩu",
5
+ "emailPlaceholder": "you@example.com",
6
+ "passwordPlaceholder": "Nhập mật khẩu của bạn",
7
+ "signingIn": "Đang đăng nhập...",
8
+ "forgotPassword": "Quên mật khẩu?",
9
+ "ssoChecking": "Đang kiểm tra tùy chọn đăng nhập...",
10
+ "ssoNotice": "Tổ chức của bạn sử dụng đăng nhập một lần",
11
+ "continueWithSso": "Tiếp tục với SSO",
12
+ "errorInvalidCredentials": "Email hoặc mật khẩu không hợp lệ",
13
+ "errorLockedOut": "Tài khoản đã bị khóa. Vui lòng thử lại sau {{seconds}} giây",
14
+ "errorEmailNotConfirmed": "Vui lòng kiểm tra email để xác minh tài khoản của bạn",
15
+ "errorSsoRequired": "Đăng nhập một lần là bắt buộc cho tài khoản này",
16
+ "errorEmailRequired": "Email là bắt buộc",
17
+ "errorPasswordRequired": "Mật khẩu là bắt buộc",
18
+ "errorUnexpected": "Đã xảy ra lỗi không mong muốn. Vui lòng thử lại.",
19
+ "resetYourPassword": "Đặt lại mật khẩu",
20
+ "resetSubtitle": "Nhập địa chỉ email của bạn và chúng tôi sẽ gửi cho bạn liên kết để đặt lại mật khẩu.",
21
+ "sending": "Đang gửi...",
22
+ "sendResetLink": "Gửi liên kết đặt lại",
23
+ "backToSignIn": "Quay lại đăng nhập",
24
+ "checkYourEmail": "Kiểm tra email của bạn",
25
+ "resetEmailSent": "Nếu tài khoản tồn tại với email đó, bạn sẽ nhận được liên kết đặt lại trong thời gian ngắn.",
26
+ "setNewPassword": "Đặt mật khẩu mới",
27
+ "newPassword": "Mật khẩu mới",
28
+ "newPasswordPlaceholder": "Nhập mật khẩu mới",
29
+ "confirmPassword": "Xác nhận mật khẩu",
30
+ "confirmPasswordPlaceholder": "Xác nhận mật khẩu mới",
31
+ "resetting": "Đang đặt lại...",
32
+ "resetPassword": "Đặt lại mật khẩu",
33
+ "passwordResetSuccess": "Đặt lại mật khẩu thành công",
34
+ "passwordResetSuccessMessage": "Mật khẩu của bạn đã được đặt lại. Bạn có thể đăng nhập bằng mật khẩu mới.",
35
+ "invalidLink": "Liên kết không hợp lệ",
36
+ "invalidOrExpiredLink": "Liên kết đặt lại này không hợp lệ hoặc đã hết hạn.",
37
+ "requestNewResetLink": "Yêu cầu liên kết đặt lại mới",
38
+ "passwordNotMeetRequirements": "Mật khẩu không đáp ứng các yêu cầu",
39
+ "passwordsDoNotMatch": "Mật khẩu không khớp",
40
+ "passwordWeakError": "Mật khẩu không đáp ứng yêu cầu về độ mạnh",
41
+ "signInTitle": "Đăng nhập — {{appName}}",
42
+ "ruleMinLength": "Ít nhất {{count}} ký tự",
43
+ "ruleUppercase": "Chữ cái viết hoa",
44
+ "ruleLowercase": "Chữ cái viết thường",
45
+ "ruleDigit": "Chữ số",
46
+ "ruleSpecialChar": "Ký tự đặc biệt",
47
+ "continueWith": "Tiếp tục với {{provider}}",
48
+ "or": "hoặc",
49
+ "signedInAs": "Đã đăng nhập với tên {{name}}",
50
+ "signedInMessage": "Bạn đã được xác thực.",
51
+ "welcomeTitle": "Chào mừng đến với {{appName}}",
52
+ "welcomeSubtitle": "Đăng nhập để truy cập tài khoản của bạn",
53
+ "signOut": "Đăng xuất",
54
+ "mfaTitle": "Xác thực hai yếu tố",
55
+ "mfaSubtitle": "Nhập mã xác minh để tiếp tục",
56
+ "mfaMethodTotp": "Ứng dụng xác thực",
57
+ "mfaMethodRecovery": "Mã khôi phục",
58
+ "mfaTotpLabel": "Mã 6 chữ số",
59
+ "mfaRecoveryLabel": "Mã khôi phục",
60
+ "mfaVerify": "Xác minh",
61
+ "mfaVerifying": "Đang xác minh...",
62
+ "mfaInvalidCode": "Mã không hợp lệ. Vui lòng thử lại.",
63
+ "mfaChallengeExpired": "Phiên xác minh đã hết hạn. Vui lòng đăng nhập lại.",
64
+ "mfaSetupTitle": "Xác thực đa yếu tố",
65
+ "mfaStatusEnabled": "MFA đã được bật cho tài khoản của bạn.",
66
+ "mfaStatusDisabled": "MFA chưa được thiết lập.",
67
+ "mfaEnrolledMethods": "Phương thức đã đăng ký",
68
+ "mfaAddedOn": "Thêm vào {{date}}",
69
+ "mfaRemove": "Xóa",
70
+ "mfaSetupTotp": "Thiết lập ứng dụng xác thực",
71
+ "mfaScanQrCode": "Quét mã QR này bằng ứng dụng xác thực của bạn",
72
+ "mfaEnterCode": "Nhập mã từ ứng dụng của bạn",
73
+ "mfaConfirm": "Xác nhận",
74
+ "mfaTotpAlreadyEnrolled": "Ứng dụng xác thực đã được đăng ký.",
75
+ "mfaGenerateRecoveryCodes": "Tạo mã khôi phục",
76
+ "mfaRegenerateRecoveryCodes": "Tạo lại mã khôi phục",
77
+ "mfaRecoveryCodesTitle": "Mã khôi phục",
78
+ "mfaRecoveryCodesWarning": "Lưu các mã này ở nơi an toàn. Mỗi mã chỉ có thể sử dụng một lần.",
79
+ "mfaRecoveryRequiresPrimary": "Hãy thiết lập ứng dụng xác thực trước.",
80
+ "mfaMethodWebAuthn": "Passkey",
81
+ "mfaUsePasskey": "Sử dụng passkey",
82
+ "mfaSetupPasskey": "Thiết lập passkey",
83
+ "mfaWebAuthnCancelled": "Xác thực passkey đã bị hủy.",
84
+ "mfaManualKeyLabel": "Hoặc nhập khóa này theo cách thủ công:",
85
+ "mfaCopyKey": "Nhấp để sao chép",
86
+ "mfaSkipSetup": "Bỏ qua lần này",
87
+ "mfaBackToApp": "Quay lại ứng dụng",
88
+ "mfaDone": "Xong",
89
+ "mfaLoading": "Đang tải...",
90
+ "mfaPromptTitle": "Bảo mật tài khoản của bạn",
91
+ "mfaPromptMessage": "Thêm xác thực đa yếu tố để bảo vệ tài khoản của bạn bằng một lớp bảo mật bổ sung.",
92
+ "mfaPromptSetup": "Thiết lập MFA",
93
+ "mfaPromptSkip": "Không phải bây giờ",
94
+ "noAccount": "Chưa có tài khoản?",
95
+ "createAccount": "Tạo tài khoản",
96
+ "continue": "Tiếp tục",
97
+ "orSignInWith": "Hoặc đăng nhập với {{provider}}",
98
+ "registerTitle": "Tạo tài khoản",
99
+ "firstName": "Tên",
100
+ "firstNamePlaceholder": "Minh",
101
+ "lastName": "Họ",
102
+ "lastNamePlaceholder": "Nguyễn",
103
+ "registering": "Đang tạo tài khoản...",
104
+ "registerButton": "Tạo tài khoản",
105
+ "alreadyHaveAccount": "Đã có tài khoản?",
106
+ "registrationSuccess": "Đăng ký thành công! Vui lòng kiểm tra email để xác minh tài khoản, sau đó đăng nhập.",
107
+ "errorEmailAlreadyRegistered": "Tài khoản với email này đã tồn tại.",
108
+ "errorWeakPassword": "Mật khẩu không đáp ứng yêu cầu.",
109
+ "errorEmailAndPasswordRequired": "Email và mật khẩu là bắt buộc.",
110
+ "errorRegistrationFailed": "Đăng ký thất bại. Vui lòng thử lại."
111
+ }
@@ -0,0 +1,111 @@
1
+ {
2
+ "signIn": "登录",
3
+ "email": "电子邮件",
4
+ "password": "密码",
5
+ "emailPlaceholder": "you@example.com",
6
+ "passwordPlaceholder": "输入您的密码",
7
+ "signingIn": "正在登录...",
8
+ "forgotPassword": "忘记密码?",
9
+ "ssoChecking": "正在检查登录选项...",
10
+ "ssoNotice": "您的组织使用单点登录",
11
+ "continueWithSso": "使用 SSO 继续",
12
+ "errorInvalidCredentials": "电子邮件或密码无效",
13
+ "errorLockedOut": "账户已锁定。请在 {{seconds}} 秒后重试",
14
+ "errorEmailNotConfirmed": "请检查您的电子邮件以验证您的账户",
15
+ "errorSsoRequired": "此账户需要单点登录",
16
+ "errorEmailRequired": "电子邮件为必填项",
17
+ "errorPasswordRequired": "密码为必填项",
18
+ "errorUnexpected": "发生意外错误,请重试。",
19
+ "resetYourPassword": "重置密码",
20
+ "resetSubtitle": "输入您的电子邮件地址,我们将向您发送重置密码的链接。",
21
+ "sending": "正在发送...",
22
+ "sendResetLink": "发送重置链接",
23
+ "backToSignIn": "返回登录",
24
+ "checkYourEmail": "请查看您的电子邮件",
25
+ "resetEmailSent": "如果该电子邮件地址存在对应的账户,您将很快收到重置链接。",
26
+ "setNewPassword": "设置新密码",
27
+ "newPassword": "新密码",
28
+ "newPasswordPlaceholder": "输入新密码",
29
+ "confirmPassword": "确认密码",
30
+ "confirmPasswordPlaceholder": "确认新密码",
31
+ "resetting": "正在重置...",
32
+ "resetPassword": "重置密码",
33
+ "passwordResetSuccess": "密码重置成功",
34
+ "passwordResetSuccessMessage": "您的密码已重置。您现在可以使用新密码登录。",
35
+ "invalidLink": "无效链接",
36
+ "invalidOrExpiredLink": "此重置链接无效或已过期。",
37
+ "requestNewResetLink": "请求新的重置链接",
38
+ "passwordNotMeetRequirements": "密码不符合要求",
39
+ "passwordsDoNotMatch": "两次输入的密码不一致",
40
+ "passwordWeakError": "密码不符合强度要求",
41
+ "signInTitle": "登录 — {{appName}}",
42
+ "ruleMinLength": "至少 {{count}} 个字符",
43
+ "ruleUppercase": "大写字母",
44
+ "ruleLowercase": "小写字母",
45
+ "ruleDigit": "数字",
46
+ "ruleSpecialChar": "特殊字符",
47
+ "continueWith": "使用 {{provider}} 继续",
48
+ "or": "或",
49
+ "signedInAs": "已登录为 {{name}}",
50
+ "signedInMessage": "您已通过身份验证。",
51
+ "welcomeTitle": "欢迎使用 {{appName}}",
52
+ "welcomeSubtitle": "登录以访问您的帐户",
53
+ "signOut": "退出登录",
54
+ "mfaTitle": "两步验证",
55
+ "mfaSubtitle": "输入验证码以继续",
56
+ "mfaMethodTotp": "身份验证器",
57
+ "mfaMethodRecovery": "恢复码",
58
+ "mfaTotpLabel": "6位验证码",
59
+ "mfaRecoveryLabel": "恢复码",
60
+ "mfaVerify": "验证",
61
+ "mfaVerifying": "正在验证...",
62
+ "mfaInvalidCode": "验证码无效,请重试。",
63
+ "mfaChallengeExpired": "验证会话已过期,请重新登录。",
64
+ "mfaSetupTitle": "多因素认证",
65
+ "mfaStatusEnabled": "您的帐户已启用 MFA。",
66
+ "mfaStatusDisabled": "MFA 尚未设置。",
67
+ "mfaEnrolledMethods": "已注册的方法",
68
+ "mfaAddedOn": "添加于 {{date}}",
69
+ "mfaRemove": "移除",
70
+ "mfaSetupTotp": "设置身份验证器应用",
71
+ "mfaScanQrCode": "使用身份验证器应用扫描此二维码",
72
+ "mfaEnterCode": "输入应用中的验证码",
73
+ "mfaConfirm": "确认",
74
+ "mfaTotpAlreadyEnrolled": "已注册身份验证器应用。",
75
+ "mfaGenerateRecoveryCodes": "生成恢复码",
76
+ "mfaRegenerateRecoveryCodes": "重新生成恢复码",
77
+ "mfaRecoveryCodesTitle": "恢复码",
78
+ "mfaRecoveryCodesWarning": "请将这些代码保存在安全的地方。每个代码只能使用一次。",
79
+ "mfaRecoveryRequiresPrimary": "请先设置身份验证器应用。",
80
+ "mfaMethodWebAuthn": "通行密钥",
81
+ "mfaUsePasskey": "使用通行密钥",
82
+ "mfaSetupPasskey": "设置通行密钥",
83
+ "mfaWebAuthnCancelled": "通行密钥验证已取消。",
84
+ "mfaManualKeyLabel": "或手动输入此密钥:",
85
+ "mfaCopyKey": "点击复制",
86
+ "mfaSkipSetup": "暂时跳过",
87
+ "mfaBackToApp": "返回应用",
88
+ "mfaDone": "完成",
89
+ "mfaLoading": "加载中...",
90
+ "mfaPromptTitle": "保护您的账户",
91
+ "mfaPromptMessage": "添加多因素认证,为您的账户提供额外的安全保障。",
92
+ "mfaPromptSetup": "设置 MFA",
93
+ "mfaPromptSkip": "暂不设置",
94
+ "noAccount": "还没有账户?",
95
+ "createAccount": "创建账户",
96
+ "continue": "继续",
97
+ "orSignInWith": "或使用 {{provider}} 登录",
98
+ "registerTitle": "创建账户",
99
+ "firstName": "名",
100
+ "firstNamePlaceholder": "小明",
101
+ "lastName": "姓",
102
+ "lastNamePlaceholder": "张",
103
+ "registering": "正在创建账户...",
104
+ "registerButton": "创建账户",
105
+ "alreadyHaveAccount": "已有账户?",
106
+ "registrationSuccess": "注册成功!请检查您的邮箱以验证账户,然后登录。",
107
+ "errorEmailAlreadyRegistered": "此邮箱已注册。",
108
+ "errorWeakPassword": "密码不符合要求。",
109
+ "errorEmailAndPasswordRequired": "邮箱和密码为必填项。",
110
+ "errorRegistrationFailed": "注册失败,请重试。"
111
+ }
package/src/index.ts ADDED
@@ -0,0 +1,44 @@
1
+ // Public API — consumers import from '@authagonal/login'
2
+ //
3
+ // Usage:
4
+ // import { AuthLayout, LoginPage, useBranding } from '@authagonal/login';
5
+
6
+ // Components
7
+ export { default as AuthLayout } from './components/AuthLayout';
8
+ export { Button } from './components/ui/button';
9
+ export type { ButtonProps } from './components/ui/button';
10
+ export { Input } from './components/ui/input';
11
+ export { Label } from './components/ui/label';
12
+ export { Card, CardHeader, CardTitle, CardDescription, CardContent, CardFooter } from './components/ui/card';
13
+ export { Alert } from './components/ui/alert';
14
+ export { Separator } from './components/ui/separator';
15
+ export { cn } from './lib/utils';
16
+
17
+ // Pages
18
+ export { default as LoginPage } from './pages/LoginPage';
19
+ export { default as RegisterPage } from './pages/RegisterPage';
20
+ export { default as ForgotPasswordPage } from './pages/ForgotPasswordPage';
21
+ export { default as ResetPasswordPage } from './pages/ResetPasswordPage';
22
+ export { default as MfaChallengePage } from './pages/MfaChallengePage';
23
+ export { default as MfaSetupPage } from './pages/MfaSetupPage';
24
+
25
+ // App — standalone SPA with routing (for consumers that want the full app)
26
+ export { default as App } from './App';
27
+
28
+ // Branding
29
+ export { loadBranding, BrandingContext, useBranding, resolveLocalized } from './branding';
30
+ export type { BrandingConfig, LocalizedString } from './branding';
31
+
32
+ // API client
33
+ export { login, logout, forgotPassword, resetPassword, getSession, ssoCheck, getProviders, getPasswordPolicy, mfaVerify, mfaStatus, mfaTotpSetup, mfaTotpConfirm, mfaWebAuthnSetup, mfaWebAuthnConfirm, mfaRecoveryGenerate, mfaDeleteCredential, ApiRequestError } from './api';
34
+
35
+ // Types
36
+ export type { LoginResponse, ApiError, SessionResponse, SsoCheckResponse, ExternalProvider, ProvidersResponse, PasswordPolicyRule, PasswordPolicyResponse, MfaLoginResponse, MfaVerifyResponse, MfaStatusResponse, MfaMethod, MfaTotpSetupResponse, MfaRecoveryGenerateResponse, MfaWebAuthnSetupResponse, MfaWebAuthnConfirmResponse } from './types';
37
+
38
+ // i18n — re-export so consumers use the same react-i18next instance
39
+ export { default as i18n } from './i18n';
40
+ export { useTranslation } from 'react-i18next';
41
+
42
+ // Styles — bundled into dist/style.css via the side-effect import below.
43
+ // Consumers: import '@authagonal/login/styles.css'
44
+ import './styles.css';