flutter-auth-ui
flutter-auth-ui copied to clipboard
fix: Call onToggleRecoverPassword(false) on “Back to sign in”
What kind of change does this PR introduce?
Bug fix.
What is the current behavior?
- Tapping “Forgot password” correctly triggers
onToggleRecoverPassword(true). - Tapping “Back to sign in” does not trigger
onToggleRecoverPassword(false). - As a result, parent widgets relying on this callback remain stuck in the “Recover Password” state (e.g., titles or layouts don’t update back).
Related issue: Fixes #147
What is the new behavior?
- Tapping “Back to sign in” now triggers onToggleRecoverPassword(false) after the internal state switches back from recovery, keeping parent UI in sync.
- Entering the recovery flow via “Forgot password” continues to trigger onToggleRecoverPassword(true) as before.
- Parent widgets relying on this callback (e.g., to update titles/layout) immediately reflect the correct state when leaving the password recovery view.
- No breaking changes; existing onToggleSignIn behavior remains unchanged.
Additional context
- No breaking changes.
- Minimal patch touching only the callback invocation on the “Back to sign in” action.
- Tested manually on mobile and web; no performance implications expected.