RegistrationOptions constructor
RegistrationOptions({ - RegistrationRepository? registrationRepository,
- List<AuthStep>? registrationSteps,
- required VoidCallback afterRegistration,
- int? titleFlex,
- int? formFlex,
- int? beforeTitleFlex,
- int? afterTitleFlex,
- RegistrationTranslations registrationTranslations = const RegistrationTranslations.empty(),
- int? onError(
- String error
)?,
- AppBar customAppbarBuilder(
- String title
)? = _createCustomAppBar,
- Widget nextButtonBuilder(
- Future<void> onPressed()?,
- String label,
- int step,
- bool enabled,
)?,
- Widget? previousButtonBuilder(
- VoidCallback onPressed,
- String label,
- int step
)?,
- MainAxisAlignment? buttonMainAxisAlignment,
- Color? backgroundColor,
- Widget? titleWidget,
- Widget? loginButton,
- double? maxFormWidth,
})
Implementation
RegistrationOptions({
this.registrationRepository,
this.registrationSteps,
required this.afterRegistration,
this.titleFlex,
this.formFlex,
this.beforeTitleFlex,
this.afterTitleFlex,
this.registrationTranslations = const RegistrationTranslations.empty(),
this.onError,
this.customAppbarBuilder = _createCustomAppBar,
this.nextButtonBuilder,
this.previousButtonBuilder,
this.buttonMainAxisAlignment,
this.backgroundColor,
this.titleWidget,
this.loginButton,
this.maxFormWidth,
}) {
if (registrationSteps == null || registrationSteps!.isEmpty) {
steps = RegistrationOptions.getDefaultSteps();
} else {
steps = registrationSteps!;
}
registrationRepository ??= ExampleRegistrationRepository();
}