translate loginpage 100%
This commit is contained in:
@@ -43,7 +43,7 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
context, MaterialPageRoute(builder: (_) => ListItemMenu()));
|
||||
} else {
|
||||
showAlertDialog(context, AppLocalizations.of(context)?.error ?? "Error",
|
||||
"Échec de l'authentification");
|
||||
AppLocalizations.of(context)?.failed_auth ?? "Authentication failed");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -80,7 +80,7 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
return Scaffold(
|
||||
backgroundColor: Colors.white,
|
||||
appBar: AppBar(
|
||||
title: Text("Login Page"),
|
||||
title: Text(AppLocalizations.of(context)?.login_page ?? "Login Page"),
|
||||
backgroundColor: Colors.blue,
|
||||
foregroundColor: Colors.white,
|
||||
),
|
||||
@@ -100,8 +100,10 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
controller: inputPseudo,
|
||||
decoration: InputDecoration(
|
||||
border: OutlineInputBorder(),
|
||||
labelText: 'Pseudo',
|
||||
hintText: 'Enter pseudo existant',
|
||||
labelText: AppLocalizations.of(context)?.pseudo ?? 'Pseudo',
|
||||
hintText:
|
||||
AppLocalizations.of(context)?.enter_existing_pseudo ??
|
||||
'Enter a existing pseudo',
|
||||
),
|
||||
),
|
||||
),
|
||||
@@ -112,13 +114,16 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
obscureText: true,
|
||||
decoration: InputDecoration(
|
||||
border: OutlineInputBorder(),
|
||||
labelText: 'Password',
|
||||
hintText: 'Enter secure password',
|
||||
labelText:
|
||||
AppLocalizations.of(context)?.password ?? "Password",
|
||||
hintText: AppLocalizations.of(context)?.enter_password ??
|
||||
"Enter the password",
|
||||
),
|
||||
),
|
||||
),
|
||||
CheckboxListTile(
|
||||
title: Text("Se souvenir de moi"),
|
||||
title: Text(
|
||||
AppLocalizations.of(context)?.remembr_me ?? "Remember me"),
|
||||
value: _rememberMe,
|
||||
onChanged: (newValue) {
|
||||
setState(() {
|
||||
@@ -131,7 +136,9 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
Navigator.push(context,
|
||||
MaterialPageRoute(builder: (_) => PasswordForgot()));
|
||||
},
|
||||
child: Text('Forgot Password',
|
||||
child: Text(
|
||||
AppLocalizations.of(context)?.forgot_password ??
|
||||
'Forgot Password',
|
||||
style: TextStyle(color: Colors.blue, fontSize: 15)),
|
||||
),
|
||||
Container(
|
||||
@@ -141,13 +148,14 @@ class _LoginDemoState extends State<LoginDemo> with ShowAlertDialog {
|
||||
color: Colors.blue, borderRadius: BorderRadius.circular(20)),
|
||||
child: TextButton(
|
||||
onPressed: () => _login(context),
|
||||
child: Text('Login',
|
||||
child: Text(AppLocalizations.of(context)?.sign_in ?? 'Sign in',
|
||||
style: TextStyle(color: Colors.white, fontSize: 25)),
|
||||
),
|
||||
),
|
||||
SizedBox(height: 130),
|
||||
InkWell(
|
||||
child: Text('New User? Create Account'),
|
||||
child: Text(AppLocalizations.of(context)?.new_user ??
|
||||
'New User? Create Account'),
|
||||
onTap: () {
|
||||
Navigator.push(
|
||||
context, MaterialPageRoute(builder: (_) => AddProfile()));
|
||||
|
Reference in New Issue
Block a user