Updated locale keys
This commit is contained in:
@@ -29,7 +29,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
context.translate(LocaleKeys.recoverPasswordTitle),
|
||||
context.translate(I18n.recoverPasswordTitle),
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
fontWeight: FontWeight.w500,
|
||||
@@ -40,7 +40,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
SizedBox(height: SizeUtils.getByScreen(small: 42, big: 32)),
|
||||
CustomTextField(
|
||||
showPassword: viewState.passwordVisible,
|
||||
label: context.translate(LocaleKeys.newPassword),
|
||||
label: context.translate(I18n.newPassword),
|
||||
labelSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12),
|
||||
hint: '********',
|
||||
controller: viewModel.passwordController,
|
||||
@@ -49,7 +49,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
SizedBox(height: 16),
|
||||
CustomTextField(
|
||||
showPassword: viewState.passwordVisible,
|
||||
label: context.translate(LocaleKeys.repeatPassword),
|
||||
label: context.translate(I18n.repeatPassword),
|
||||
labelSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12),
|
||||
hint: '********',
|
||||
controller: viewModel.repeatedPasswordController,
|
||||
@@ -67,7 +67,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
size: 16,
|
||||
),
|
||||
Text(
|
||||
context.translate(LocaleKeys.errorMessageUnequalPasswords),
|
||||
context.translate(I18n.errorMessageUnequalPasswords),
|
||||
textAlign: TextAlign.left,
|
||||
style: TextStyle(
|
||||
color: Color.fromRGBO(239, 17, 17, 1),
|
||||
@@ -89,7 +89,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
: ThemeCode.buttonSecondary),
|
||||
),
|
||||
Text(
|
||||
context.translate(LocaleKeys.passwordLength),
|
||||
context.translate(I18n.passwordLength),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12))
|
||||
),
|
||||
],
|
||||
@@ -105,7 +105,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
: ThemeCode.buttonSecondary),
|
||||
),
|
||||
Text(
|
||||
context.translate(LocaleKeys.passwordCapital),
|
||||
context.translate(I18n.passwordCapital),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12))
|
||||
),
|
||||
],
|
||||
@@ -121,7 +121,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
: ThemeCode.buttonSecondary),
|
||||
),
|
||||
Text(
|
||||
context.translate(LocaleKeys.passwordNumber),
|
||||
context.translate(I18n.passwordNumber),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12))
|
||||
),
|
||||
],
|
||||
@@ -137,7 +137,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
: ThemeCode.buttonSecondary),
|
||||
),
|
||||
Text(
|
||||
context.translate(LocaleKeys.passwordSpecial),
|
||||
context.translate(I18n.passwordSpecial),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12))
|
||||
),
|
||||
],
|
||||
@@ -146,7 +146,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
Align(
|
||||
alignment: Alignment.bottomLeft,
|
||||
child: Text(
|
||||
context.translate(LocaleKeys.mobilePhone),
|
||||
context.translate(I18n.mobilePhone),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12), letterSpacing: 0),
|
||||
)
|
||||
),
|
||||
@@ -164,7 +164,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
},
|
||||
),
|
||||
Expanded(child: CustomTextField(
|
||||
hint: context.translate(LocaleKeys.phoneNumber),
|
||||
hint: context.translate(I18n.phoneNumber),
|
||||
numeric: true,
|
||||
controller: viewModel.newPhoneNumberController,
|
||||
))
|
||||
@@ -190,7 +190,7 @@ class NewPasswordScreen extends ConsumerWidget {
|
||||
navigationContract.goTo(AppRoutes.dashboardHome);
|
||||
}
|
||||
},
|
||||
text: context.translate(LocaleKeys.accept),
|
||||
text: context.translate(I18n.accept),
|
||||
color: theme.getColorFor(ThemeCode.buttonPrimary)
|
||||
),
|
||||
],
|
||||
|
||||
@@ -29,26 +29,26 @@ class RequestRecoveryScreen extends ConsumerWidget {
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
context.translate(LocaleKeys.recoverPasswordTitle),
|
||||
context.translate(I18n.recoverPasswordTitle),
|
||||
style: TextStyle(fontWeight: FontWeight.bold, fontSize: SizeUtils.getByScreen(small: 29, big: 29, xl: 26)),
|
||||
),
|
||||
SizedBox(height: SizeUtils.getByScreen(small: 24, big: 32)),
|
||||
Text(
|
||||
context.translate(LocaleKeys.recoverPasswordSubtitle),
|
||||
context.translate(I18n.recoverPasswordSubtitle),
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(letterSpacing: 0, fontSize: SizeUtils.getByScreen(small: 18, big: 18, xl: 16)),
|
||||
),
|
||||
SizedBox(height: SizeUtils.getByScreen(small: 56, big: 48)),
|
||||
CustomTextField(
|
||||
label: context.translate(LocaleKeys.email),
|
||||
hint: context.translate(LocaleKeys.email),
|
||||
label: context.translate(I18n.email),
|
||||
hint: context.translate(I18n.email),
|
||||
controller: viewModel.emailController,
|
||||
),
|
||||
SizedBox(height: SizeUtils.getByScreen(small: 40, big: 40, xl: 28)),
|
||||
Align(
|
||||
alignment: Alignment.bottomLeft,
|
||||
child: Text(
|
||||
context.translate(LocaleKeys.mobilePhone),
|
||||
context.translate(I18n.mobilePhone),
|
||||
style: TextStyle(fontSize: 14, letterSpacing: 0),
|
||||
),
|
||||
),
|
||||
@@ -92,7 +92,7 @@ class RequestRecoveryScreen extends ConsumerWidget {
|
||||
Expanded(
|
||||
child: SecondaryButton(
|
||||
onPressed: () => {Navigator.pop(context)},
|
||||
text: context.translate(LocaleKeys.back),
|
||||
text: context.translate(I18n.back),
|
||||
size: SizeUtils.getByScreen(small: 16, big: 16, xl: 14),
|
||||
),
|
||||
),
|
||||
@@ -111,7 +111,7 @@ class RequestRecoveryScreen extends ConsumerWidget {
|
||||
);
|
||||
}
|
||||
},
|
||||
text: context.translate(LocaleKeys.send),
|
||||
text: context.translate(I18n.send),
|
||||
size: SizeUtils.getByScreen(small: 16, big: 16, xl: 14),
|
||||
color: theme.getColorFor(ThemeCode.buttonSecondary),
|
||||
),
|
||||
|
||||
@@ -29,7 +29,7 @@ class SentScreen extends ConsumerWidget {
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Text(
|
||||
context.translate(LocaleKeys.recoverPasswordTitle),
|
||||
context.translate(I18n.recoverPasswordTitle),
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(
|
||||
fontWeight: FontWeight.w500,
|
||||
@@ -48,8 +48,8 @@ class SentScreen extends ConsumerWidget {
|
||||
SizedBox(width: SizeUtils.getByScreen(small: 10, big: 10, xl: 6)),
|
||||
Text(
|
||||
viewState.recoveryFormat == "email"
|
||||
? context.translate(LocaleKeys.emailSent)
|
||||
: context.translate(LocaleKeys.smsSent),
|
||||
? context.translate(I18n.emailSent)
|
||||
: context.translate(I18n.smsSent),
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 18, big: 18, xl: 15), fontWeight: FontWeight.bold),
|
||||
),
|
||||
],
|
||||
@@ -57,16 +57,16 @@ class SentScreen extends ConsumerWidget {
|
||||
SizedBox(height: SizeUtils.getByScreen(small: 48, big: 48, xl: 40)),
|
||||
Text(
|
||||
viewState.recoveryFormat == "email"
|
||||
? context.translate(LocaleKeys.checkEmail1)
|
||||
: context.translate(LocaleKeys.checkSms1),
|
||||
? context.translate(I18n.checkEmail1)
|
||||
: context.translate(I18n.checkSms1),
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 17, big: 17, xl: 15), letterSpacing: 0),
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
Text(
|
||||
viewState.recoveryFormat == "email"
|
||||
? context.translate(LocaleKeys.checkEmail2)
|
||||
: context.translate(LocaleKeys.checkSms2),
|
||||
? context.translate(I18n.checkEmail2)
|
||||
: context.translate(I18n.checkSms2),
|
||||
textAlign: TextAlign.center,
|
||||
style: TextStyle(fontSize: SizeUtils.getByScreen(small: 14, big: 14, xl: 12), letterSpacing: 0),
|
||||
),
|
||||
@@ -83,8 +83,8 @@ class SentScreen extends ConsumerWidget {
|
||||
}
|
||||
},
|
||||
text: viewState.recoveryFormat == "email"
|
||||
? context.translate(LocaleKeys.resendEmail)
|
||||
: context.translate(LocaleKeys.resendSms),
|
||||
? context.translate(I18n.resendEmail)
|
||||
: context.translate(I18n.resendSms),
|
||||
size: SizeUtils.getByScreen(small: 16, big: 16, xl: 14),
|
||||
),
|
||||
),
|
||||
@@ -95,7 +95,7 @@ class SentScreen extends ConsumerWidget {
|
||||
context,
|
||||
MaterialPageRoute(builder: (_) => NewPasswordScreen(navigationContract: navigationContract)),
|
||||
),
|
||||
text: context.translate(LocaleKeys.continueKey),
|
||||
text: context.translate(I18n.continueKey),
|
||||
color: theme.getColorFor(ThemeCode.buttonSecondary),
|
||||
size: SizeUtils.getByScreen(small: 16, big: 16, xl: 14),
|
||||
),
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
"checkEmail1": "Check your email and click the link to create a new password.",
|
||||
"checkSms1": "Check your phone and follow the instructions to create a new password.",
|
||||
"checkEmail2": "If you don't receive the email in some minutes, check your spam folder or press \"Resend email\".",
|
||||
"checkSms2": "If you don't receive the SMS in some minutes, make sure you have signal or press \"Resend SMS\"",
|
||||
"checkSms2": "If you don't receive the SMS in some minutes, make sure you have signal or press \"Resend SMS\".",
|
||||
"resendEmail": "Resend email",
|
||||
"resendSms": "Resend SMS",
|
||||
"continueKey": "Continue",
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
"checkEmail1": "Revisa tu email y haz clic en el enlace para crear una nueva contraseña.",
|
||||
"checkSms1": "Revisa tu móvil y sigue las instrucciones para crear una nueva contraseña.",
|
||||
"checkEmail2": "Si no recibes el correo en unos minutos, revisa tu carpeta de spam o pulsa \"Reenviar correo\".",
|
||||
"checkSms2": "Si no recibes el SMS en unos minutos, asegúrate de tener cobertura o pulsa \"Reenviar SMS\"",
|
||||
"checkSms2": "Si no recibes el SMS en unos minutos, asegúrate de tener cobertura o pulsa \"Reenviar SMS\".",
|
||||
"resendEmail": "Reenviar correo",
|
||||
"resendSms": "Reenviar SMS",
|
||||
"continueKey": "Continuar",
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
"checkEmail1": "Controlla la tua email e fai clic sul collegamento per creare una nuova password.",
|
||||
"checkSms1": "Controlla il tuo telefono e segui le istruzioni per creare una nuova password",
|
||||
"checkEmail2": "Se non ricevi l'e-mail entro pochi minuti, controlla la cartella spam o premi \"Invia nuovamente e-mail\".",
|
||||
"checkSms2": "Se non ricevi l'SMS entro pochi minuti, assicurati di avere copertura oppure premi \"Rinvia SMS\"",
|
||||
"checkSms2": "Se non ricevi l'SMS entro pochi minuti, assicurati di avere copertura oppure premi \"Rinvia SMS\".",
|
||||
"resendEmail": "Inoltra la posta",
|
||||
"resendSms": "Inoltra SMS",
|
||||
"continueKey": "Continuare",
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
"checkEmail1": "Revise seu e-mail e clique no link para criar uma nova senha.",
|
||||
"checkSms1": "Revise seu celular e siga as instruções para criar uma nova senha",
|
||||
"checkEmail2": "Se você não receber a correspondência em alguns minutos, revise sua pasta de spam ou pressione \"Reenviar correspondência\".",
|
||||
"checkSms2": "Se você não receber o SMS em alguns minutos, certifique-se de ter cobertura ou pressione \"Reenviar SMS\"",
|
||||
"checkSms2": "Se você não receber o SMS em alguns minutos, certifique-se de ter cobertura ou pressione \"Reenviar SMS\".",
|
||||
"resendEmail": "Reenviar correio",
|
||||
"resendSms": "Reenviar SMS",
|
||||
"continueKey": "Continuar",
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
export 'src/sf_delegate.dart';
|
||||
export 'src/generated/i18n.dart';
|
||||
export 'src/generated/i18n.g.dart';
|
||||
export 'src/utils/constants.dart';
|
||||
export 'src/utils/context_extension.dart';
|
||||
export 'src/utils/string_extension.dart';
|
||||
|
||||
@@ -3,26 +3,53 @@
|
||||
class I18n {
|
||||
const I18n._();
|
||||
|
||||
static const String example = 'example';
|
||||
static const String start = 'start';
|
||||
static const String next = 'next';
|
||||
static const String skip = 'skip';
|
||||
static const String onboardingTitle1 = 'onboardingTitle1';
|
||||
static const String onboardingSubtitle1 = 'onboardingSubtitle1';
|
||||
static const String onboardingTitle2 = 'onboardingTitle2';
|
||||
static const String onboardingSubtitle2 = 'onboardingSubtitle2';
|
||||
static const String onboardingTitle3 = 'onboardingTitle3';
|
||||
static const String onboardingSubtitle3 = 'onboardingSubtitle3';
|
||||
static const String linkPhoneTitle = 'linkPhoneTitle';
|
||||
static const String linkPhoneSubtitle = 'linkPhoneSubtitle';
|
||||
static const String mobilePhone = 'mobilePhone';
|
||||
static const String phoneNumber = 'phoneNumber';
|
||||
static const String selectYourCountry = 'selectYourCountry';
|
||||
static const String errorMessagePhoneIsEmpty = 'errorMessagePhoneIsEmpty';
|
||||
static const String connect = "connect";
|
||||
static const String verificationCodeSentTo = "verificationCodeSentTo";
|
||||
static const String enterCodeHere = "enterCodeHere";
|
||||
static const String enter = "enter";
|
||||
static const String didNotReceiveIt = "didNotReceiveIt";
|
||||
static const String tryAgain = "tryAgain";
|
||||
static const example = 'example';
|
||||
static const onboardingTitle1 = 'onboardingTitle1';
|
||||
static const onboardingSubtitle1 = 'onboardingSubtitle1';
|
||||
static const onboardingTitle2 = 'onboardingTitle2';
|
||||
static const onboardingSubtitle2 = 'onboardingSubtitle2';
|
||||
static const onboardingTitle3 = 'onboardingTitle3';
|
||||
static const onboardingSubtitle3 = 'onboardingSubtitle3';
|
||||
static const start = 'start';
|
||||
static const next = 'next';
|
||||
static const skip = 'skip';
|
||||
static const linkPhoneTitle = 'linkPhoneTitle';
|
||||
static const linkPhoneSubtitle = 'linkPhoneSubtitle';
|
||||
static const mobilePhone = 'mobilePhone';
|
||||
static const phoneNumber = 'phoneNumber';
|
||||
static const selectYourCountry = 'selectYourCountry';
|
||||
static const errorMessagePhoneIsEmpty = 'errorMessagePhoneIsEmpty';
|
||||
static const connect = 'connect';
|
||||
static const verificationCodeSentTo = 'verificationCodeSentTo';
|
||||
static const enterCodeHere = 'enterCodeHere';
|
||||
static const enter = 'enter';
|
||||
static const didNotReceiveIt = 'didNotReceiveIt';
|
||||
static const tryAgain = 'tryAgain';
|
||||
static const recoverPasswordTitle = 'recoverPasswordTitle';
|
||||
static const recoverPasswordSubtitle = 'recoverPasswordSubtitle';
|
||||
static const send = 'send';
|
||||
static const back = 'back';
|
||||
static const email = 'email';
|
||||
static const errorMessageContactIsEmpty = 'errorMessageContactIsEmpty';
|
||||
static const emailSent = 'emailSent';
|
||||
static const smsSent = 'smsSent';
|
||||
static const checkEmail1 = 'checkEmail1';
|
||||
static const checkSms1 = 'checkSms1';
|
||||
static const checkEmail2 = 'checkEmail2';
|
||||
static const checkSms2 = 'checkSms2';
|
||||
static const resendEmail = 'resendEmail';
|
||||
static const resendSms = 'resendSms';
|
||||
static const continueKey = 'continueKey';
|
||||
static const newPassword = 'newPassword';
|
||||
static const repeatPassword = 'repeatPassword';
|
||||
static const passwordLength = 'passwordLength';
|
||||
static const passwordCapital = 'passwordCapital';
|
||||
static const passwordNumber = 'passwordNumber';
|
||||
static const passwordSpecial = 'passwordSpecial';
|
||||
static const accept = 'accept';
|
||||
static const errorMessageUnequalPasswords = 'errorMessageUnequalPasswords';
|
||||
static const errorMessagePasswordTooShort = 'errorMessagePasswordTooShort';
|
||||
static const errorMessagePasswordNoCapitals = 'errorMessagePasswordNoCapitals';
|
||||
static const errorMessagePasswordNoNumbers = 'errorMessagePasswordNoNumbers';
|
||||
static const errorMessagePasswordNoSpecialChars = 'errorMessagePasswordNoSpecialChars';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user