diff --git a/CHANGELOG.md b/CHANGELOG.md index 36b458c..9d7b702 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +## 6.0.1 + +* Added default loginOptions for email and password fields. + ## 6.0.0 * Changed ForgotPasswordform to use the same layout as the EmailPasswordLoginForm. diff --git a/lib/src/config/login_options.dart b/lib/src/config/login_options.dart index 9a8fd25..d61f245 100644 --- a/lib/src/config/login_options.dart +++ b/lib/src/config/login_options.dart @@ -35,6 +35,17 @@ class LoginOptions { 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. final ButtonBuilder loginButtonBuilder; diff --git a/pubspec.yaml b/pubspec.yaml index 5166b25..33bf03c 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: flutter_login description: Flutter Login Component -version: 6.0.0 +version: 6.0.1 environment: sdk: ">=2.18.1 <3.0.0"