DeleteAccountButton constructor
const
DeleteAccountButton({
- Key? key,
- FirebaseAuth? auth,
- SignInRequiredCallback? onSignInRequired,
- DeleteFailedCallback? onDeleteFailed,
- ButtonVariant variant = ButtonVariant.filled,
- bool showDeleteConfirmationDialog = false,
A button that triggers the deletion of the user's account.
If you want to perform an action after the account is deleted, you can use AccountDeletedAction.
Example usage:
ProfileScreen(
actions: [
AccountDeletedAction((context, user) {
// Do something after the account is deleted.
}),
],
);
or
FirebaseUIActions(
actions: [
AccountDeletedAction((context, user) {
// Do something after the account is deleted.
}),
],
// MyCustomScreen should use DeleteAccountButton internally.
child: MyCustomScreen(),
)
Implementation
const DeleteAccountButton({
super.key,
this.auth,
this.onSignInRequired,
this.onDeleteFailed,
this.variant = ButtonVariant.filled,
this.showDeleteConfirmationDialog = false,
});