fix: add default loginoptions for email and password fields

This commit is contained in:
mike doornenbal 2024-04-02 15:41:36 +02:00
parent f1b11ae79a
commit e8f3292dc7
3 changed files with 16 additions and 1 deletions

View file

@ -1,3 +1,7 @@
## 6.0.1
* Added default loginOptions for email and password fields.
## 6.0.0 ## 6.0.0
* Changed ForgotPasswordform to use the same layout as the EmailPasswordLoginForm. * Changed ForgotPasswordform to use the same layout as the EmailPasswordLoginForm.

View file

@ -35,6 +35,17 @@ class LoginOptions {
this.forgotPasswordSpacerOptions = const ForgotPasswordSpacerOptions(), this.forgotPasswordSpacerOptions = const ForgotPasswordSpacerOptions(),
}); });
factory LoginOptions.defaults() => const LoginOptions(
emailDecoration: InputDecoration(
labelText: 'Email',
hintText: 'Enter your email',
),
passwordDecoration: InputDecoration(
labelText: 'Password',
hintText: 'Enter your password',
),
);
/// Builds the login button. /// Builds the login button.
final ButtonBuilder loginButtonBuilder; final ButtonBuilder loginButtonBuilder;

View file

@ -1,6 +1,6 @@
name: flutter_login name: flutter_login
description: Flutter Login Component description: Flutter Login Component
version: 6.0.0 version: 6.0.1
environment: environment:
sdk: ">=2.18.1 <3.0.0" sdk: ">=2.18.1 <3.0.0"