Skip to content

Commit 24bc22c

Browse files
fosbsbbrionmario
andauthored
feat(i18n): add Portuguese (pt-BR) and (pt-PT) translation (#199)
* feat(i18n): add Portuguese (pt-BR) translation, introduces the Portuguese (Brazil) language pack * chore: housekeeping - fix lint errors and add changeset * feat(i18n): add Portuguese (pt-PT) translation, introduces the Portuguese (Portugal) language pack --------- Co-authored-by: Brion Mario <[email protected]>
1 parent 7ee9462 commit 24bc22c

File tree

5 files changed

+331
-0
lines changed

5 files changed

+331
-0
lines changed

.changeset/quick-boxes-joke.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@asgardeo/i18n': minor
3+
---
4+
5+
Add Portuguese (pt-BR) language support to @asgardeo/i18n package.

.changeset/two-oranges-call.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@asgardeo/i18n': minor
3+
---
4+
5+
Add Portuguese (pt-PT) language support to @asgardeo/i18n package.

packages/i18n/src/translations/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,7 @@
1919
export {default as en_US} from './en-US';
2020
export {default as fr_FR} from './fr-FR';
2121
export {default as hi_IN} from './hi-IN';
22+
export {default as pt_BR} from './pt-BR';
23+
export {default as pt_PT} from './pt-PT';
2224
export {default as ta_IN} from './ta-IN';
2325
export {default as si_LK} from './si-LK';
Lines changed: 159 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,159 @@
1+
/**
2+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
3+
*
4+
* WSO2 LLC. licenses this file to you under the Apache License,
5+
* Version 2.0 (the "License"); you may not use this file except
6+
* in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing,
12+
* software distributed under the License is distributed on an
13+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
* KIND, either express or implied. See the License for the
15+
* specific language governing permissions and limitations
16+
* under the License.
17+
*/
18+
19+
/* eslint-disable sort-keys */
20+
/* eslint-disable @typescript-eslint/naming-convention */
21+
22+
import {I18nTranslations, I18nMetadata, I18nBundle} from '../models/i18n';
23+
24+
const translations: I18nTranslations = {
25+
/* |---------------------------------------------------------------| */
26+
/* | Elements | */
27+
/* |---------------------------------------------------------------| */
28+
29+
/* Buttons */
30+
'elements.buttons.signIn': 'Entrar',
31+
'elements.buttons.signOut': 'Sair',
32+
'elements.buttons.signUp': 'Cadastre-se',
33+
'elements.buttons.facebook': 'Entrar com Facebook',
34+
'elements.buttons.google': 'Entrar com Google',
35+
'elements.buttons.github': 'Entrar com GitHub',
36+
'elements.buttons.microsoft': 'Entrar com Microsoft',
37+
'elements.buttons.linkedin': 'Entrar com LinkedIn',
38+
'elements.buttons.ethereum': 'Entrar com Ethereum',
39+
'elements.buttons.multi.option': 'Entrar com {connection}',
40+
'elements.buttons.social': 'Entrar com {connection}',
41+
42+
/* Fields */
43+
'elements.fields.placeholder': 'Digite seu {field}',
44+
45+
/* |---------------------------------------------------------------| */
46+
/* | Widgets | */
47+
/* |---------------------------------------------------------------| */
48+
49+
/* Base Sign In */
50+
'signin.title': 'Entrar',
51+
'signin.subtitle': 'Digite suas credencias para continuar.',
52+
53+
/* Base Sign Up */
54+
'signup.title': 'Cadastra-se',
55+
'signup.subtitle': 'Crie uma nova conta para iniciar.',
56+
57+
/* Email OTP */
58+
'email.otp.title': 'Verificação OTP',
59+
'email.otp.subtitle': 'Digite o código enviado para seu e-mail.',
60+
'email.otp.submit.button': 'Continue',
61+
62+
/* Identifier First */
63+
'identifier.first.title': 'Entrar',
64+
'identifier.first.subtitle': 'Digite seu usuário ou e-mail.',
65+
'identifier.first.submit.button': 'Continue',
66+
67+
/* SMS OTP */
68+
'sms.otp.title': 'Verificação OTP',
69+
'sms.otp.subtitle': 'Digite o código enviado para seu telefone.',
70+
'sms.otp.submit.button': 'Continue',
71+
72+
/* TOTP */
73+
'totp.title': 'Verifique sua identidade',
74+
'totp.subtitle': 'Digite o código do seu aplicativo autenticador.',
75+
'totp.submit.button': 'Continue',
76+
77+
/* Username Password */
78+
'username.password.submit.button': 'Continue',
79+
'username.password.title': 'Entrar',
80+
'username.password.subtitle': 'Digite seu usuário e senha para continuar.',
81+
82+
/* |---------------------------------------------------------------| */
83+
/* | User Profile | */
84+
/* |---------------------------------------------------------------| */
85+
86+
'user.profile.title': 'Perfil',
87+
'user.profile.update.generic.error': 'Ocorreu um erro ao atualizar seu perfil. Tente novamente.',
88+
89+
/* |---------------------------------------------------------------| */
90+
/* | Organization Switcher | */
91+
/* |---------------------------------------------------------------| */
92+
93+
'organization.switcher.select.organization': 'Escolher Organização',
94+
'organization.switcher.switch.organization': 'Trocar Organização',
95+
'organization.switcher.loading.organizations': 'Carregando organizações...',
96+
'organization.switcher.members': 'membros',
97+
'organization.switcher.member': 'membro',
98+
'organization.switcher.create.organization': 'Criar Organização',
99+
'organization.switcher.manage.organizations': 'Gerenciar Organizações',
100+
'organization.switcher.manage.button': 'Gerenciar',
101+
'organization.switcher.organizations.title': 'Organizações',
102+
'organization.switcher.switch.button': 'Trocar',
103+
'organization.switcher.no.access': 'Sem Acesso',
104+
'organization.switcher.status.label': 'Situação:',
105+
'organization.switcher.showing.count': 'Exibindo {showing} de {total} organizações',
106+
'organization.switcher.refresh.button': 'Atualizar',
107+
'organization.switcher.load.more': 'Carregar Mais Organizações',
108+
'organization.switcher.loading.more': 'Carregando...',
109+
'organization.switcher.no.organizations': 'Nenhuma organização encontrada',
110+
'organization.switcher.error.prefix': 'Erro:',
111+
'organization.profile.title': 'Perfil da Organização',
112+
'organization.profile.loading': 'Carregando organização...',
113+
'organization.profile.error': 'Falha ao carregar organização',
114+
115+
'organization.create.title': 'Criar Organização',
116+
'organization.create.name.label': 'Nome da Organização',
117+
'organization.create.name.placeholder': 'Digite o nome da organização',
118+
'organization.create.handle.label': 'Identificador da Organização',
119+
'organization.create.handle.placeholder': 'minha-organizacao',
120+
'organization.create.description.label': 'Descrição',
121+
'organization.create.description.placeholder': 'Digite a descrição da organização',
122+
'organization.create.button': 'Criar Organização',
123+
'organization.create.creating': 'Criando...',
124+
'organization.create.cancel': 'Cancelar',
125+
126+
/* |---------------------------------------------------------------| */
127+
/* | Messages | */
128+
/* |---------------------------------------------------------------| */
129+
130+
'messages.loading': 'Carregando...',
131+
132+
/* |---------------------------------------------------------------| */
133+
/* | Errors | */
134+
/* |---------------------------------------------------------------| */
135+
136+
'errors.title': 'Erro',
137+
'errors.sign.in.initialization': 'Ocorreu um erro ao inicializar. Tente novamente mais tarde.',
138+
'errors.sign.in.flow.failure': 'Ocorreu um erro durante o login. Tente novamente mais tarde.',
139+
'errors.sign.in.flow.completion.failure': 'Ocorreu um erro ao completar o login. Tente novamente mais tarde.',
140+
'errors.sign.in.flow.passkeys.failure':
141+
'Ocorreu um erro ao entrar com as chaves de acesso (passkeys). Tente novamente mais tarde.',
142+
'errors.sign.in.flow.passkeys.completion.failure':
143+
'Ocorreu um erro ao completar o login com as chaves de acesso (passkeys). Tente novamente mais tarde.',
144+
};
145+
146+
const metadata: I18nMetadata = {
147+
localeCode: 'pt-BR',
148+
countryCode: 'BR',
149+
languageCode: 'pt',
150+
displayName: 'Português (Brazil)',
151+
direction: 'ltr',
152+
};
153+
154+
const pt_BR: I18nBundle = {
155+
metadata,
156+
translations,
157+
};
158+
159+
export default pt_BR;
Lines changed: 160 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,160 @@
1+
/**
2+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
3+
*
4+
* WSO2 LLC. licenses this file to you under the Apache License,
5+
* Version 2.0 (the "License"); you may not use this file except
6+
* in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing,
12+
* software distributed under the License is distributed on an
13+
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
* KIND, either express or implied. See the License for the
15+
* specific language governing permissions and limitations
16+
* under the License.
17+
*/
18+
19+
/* eslint-disable sort-keys */
20+
/* eslint-disable @typescript-eslint/naming-convention */
21+
22+
import {I18nTranslations, I18nMetadata, I18nBundle} from '../models/i18n';
23+
24+
const translations: I18nTranslations = {
25+
/* |---------------------------------------------------------------| */
26+
/* | Elements | */
27+
/* |---------------------------------------------------------------| */
28+
29+
/* Buttons */
30+
'elements.buttons.signIn': 'Iniciar Sessão',
31+
'elements.buttons.signOut': 'Terminar Sessão',
32+
'elements.buttons.signUp': 'Registar-se',
33+
'elements.buttons.facebook': 'Iniciar Sessão com Facebook',
34+
'elements.buttons.google': 'Iniciar Sessão com Google',
35+
'elements.buttons.github': 'Iniciar Sessão com GitHub',
36+
'elements.buttons.microsoft': 'Iniciar Sessão com Microsoft',
37+
'elements.buttons.linkedin': 'Iniciar Sessão com LinkedIn',
38+
'elements.buttons.ethereum': 'Iniciar Sessão com Ethereum',
39+
'elements.buttons.multi.option': 'Iniciar Sessão com {connection}',
40+
'elements.buttons.social': 'Iniciar Sessão com {connection}',
41+
42+
/* Fields */
43+
'elements.fields.placeholder': 'Introduza o seu {field}',
44+
45+
/* |---------------------------------------------------------------| */
46+
/* | Widgets | */
47+
/* |---------------------------------------------------------------| */
48+
49+
/* Base Sign In */
50+
'signin.title': 'Iniciar Sessão',
51+
'signin.subtitle': 'Introduza as suas credenciais para continuar.',
52+
53+
/* Base Sign Up */
54+
'signup.title': 'Registar-se',
55+
'signup.subtitle': 'Crie uma nova conta para começar.',
56+
57+
/* Email OTP */
58+
'email.otp.title': 'Verificação OTP',
59+
'email.otp.subtitle': 'Introduza o código enviado para o seu e-mail.',
60+
'email.otp.submit.button': 'Continuar',
61+
62+
/* Identifier First */
63+
'identifier.first.title': 'Iniciar Sessão',
64+
'identifier.first.subtitle': 'Introduza o seu utilizador ou e-mail.',
65+
'identifier.first.submit.button': 'Continuar',
66+
67+
/* SMS OTP */
68+
'sms.otp.title': 'Verificação OTP',
69+
'sms.otp.subtitle': 'Introduza o código enviado para o seu telemóvel.',
70+
'sms.otp.submit.button': 'Continuar',
71+
72+
/* TOTP */
73+
'totp.title': 'Verifique a sua identidade',
74+
'totp.subtitle': 'Introduza o código da sua aplicação autenticadora.',
75+
'totp.submit.button': 'Continuar',
76+
77+
/* Username Password */
78+
'username.password.submit.button': 'Continuar',
79+
'username.password.title': 'Iniciar Sessão',
80+
'username.password.subtitle': 'Introduza o seu utilizador e palavra-passe para continuar.',
81+
82+
/* |---------------------------------------------------------------| */
83+
/* | User Profile | */
84+
/* |---------------------------------------------------------------| */
85+
86+
'user.profile.title': 'Perfil',
87+
'user.profile.update.generic.error': 'Ocorreu um erro ao actualizar o seu perfil. Tente novamente.',
88+
89+
/* |---------------------------------------------------------------| */
90+
/* | Organization Switcher | */
91+
/* |---------------------------------------------------------------| */
92+
93+
'organization.switcher.select.organization': 'Escolher Organização',
94+
'organization.switcher.switch.organization': 'Trocar Organização',
95+
'organization.switcher.loading.organizations': 'A carregar organizações...',
96+
'organization.switcher.members': 'membros',
97+
'organization.switcher.member': 'membro',
98+
'organization.switcher.create.organization': 'Criar Organização',
99+
'organization.switcher.manage.organizations': 'Gerir Organizações',
100+
'organization.switcher.manage.button': 'Gerir',
101+
'organization.switcher.organizations.title': 'Organizações',
102+
'organization.switcher.switch.button': 'Trocar',
103+
'organization.switcher.no.access': 'Sem Acesso',
104+
'organization.switcher.status.label': 'Estado:',
105+
'organization.switcher.showing.count': 'A mostrar {showing} de {total} organizações',
106+
'organization.switcher.refresh.button': 'Actualizar',
107+
'organization.switcher.load.more': 'Carregar Mais Organizações',
108+
'organization.switcher.loading.more': 'A carregar...',
109+
'organization.switcher.no.organizations': 'Nenhuma organização encontrada',
110+
'organization.switcher.error.prefix': 'Erro:',
111+
'organization.profile.title': 'Perfil da Organização',
112+
'organization.profile.loading': 'A carregar organização...',
113+
'organization.profile.error': 'Falha ao carregar organização',
114+
115+
'organization.create.title': 'Criar Organização',
116+
'organization.create.name.label': 'Nome da Organização',
117+
'organization.create.name.placeholder': 'Introduza o nome da organização',
118+
'organization.create.handle.label': 'Identificador da Organização',
119+
'organization.create.handle.placeholder': 'minha-organizacao',
120+
'organization.create.description.label': 'Descrição',
121+
'organization.create.description.placeholder': 'Introduza a descrição da organização',
122+
'organization.create.button': 'Criar Organização',
123+
'organization.create.creating': 'A criar...',
124+
'organization.create.cancel': 'Cancelar',
125+
126+
/* |---------------------------------------------------------------| */
127+
/* | Messages | */
128+
/* |---------------------------------------------------------------| */
129+
130+
'messages.loading': 'A carregar...',
131+
132+
/* |---------------------------------------------------------------| */
133+
/* | Errors | */
134+
/* |---------------------------------------------------------------| */
135+
136+
'errors.title': 'Erro',
137+
'errors.sign.in.initialization': 'Ocorreu um erro ao inicializar. Tente novamente mais tarde.',
138+
'errors.sign.in.flow.failure': 'Ocorreu um erro durante o início de sessão. Tente novamente mais tarde.',
139+
'errors.sign.in.flow.completion.failure':
140+
'Ocorreu um erro ao completar o início de sessão. Tente novamente mais tarde.',
141+
'errors.sign.in.flow.passkeys.failure':
142+
'Ocorreu um erro ao iniciar sessão com as chaves de acesso (passkeys). Tente novamente mais tarde.',
143+
'errors.sign.in.flow.passkeys.completion.failure':
144+
'Ocorreu um erro ao completar o início de sessão com as chaves de acesso (passkeys). Tente novamente mais tarde.',
145+
};
146+
147+
const metadata: I18nMetadata = {
148+
localeCode: 'pt-PT',
149+
countryCode: 'PT',
150+
languageCode: 'pt',
151+
displayName: 'Português (Portugal)',
152+
direction: 'ltr',
153+
};
154+
155+
const pt_PT: I18nBundle = {
156+
metadata,
157+
translations,
158+
};
159+
160+
export default pt_PT;

0 commit comments

Comments
 (0)