Skip to content

feat(core, react): mfa step up components#147

Draft
NaveenChand755 wants to merge 4 commits intofeat/use-error-handler-mfafrom
feat/mfa-step-up-components
Draft

feat(core, react): mfa step up components#147
NaveenChand755 wants to merge 4 commits intofeat/use-error-handler-mfafrom
feat/mfa-step-up-components

Conversation

@NaveenChand755
Copy link
Contributor

@NaveenChand755 NaveenChand755 commented Mar 13, 2026

Changes

Summary
Adds an MFA step-up challenge/enrollment UI that automatically triggers whenever any API call returns an mfa_required error.

What's new -

GateKeeper:

  1. When a component’s API call triggers MFA, a dialog overlays the content.
  2. Dismissing the dialog without completing MFA shows an error fallback with a retry option.

MFA Step-Up Components (packages/react/src/components/auth0/shared/mfa-step-up/):

MfaStepUp — Orchestrates the flow: list → enroll or challenge → complete.
AuthenticatorsList — Lets the user pick a factor to enroll or verify.
StepUpEnrollmentForm — Multi-step enrollment for OTP, Push, SMS, Voice, and Email.
StepUpVerifyForm — Handles OTP, OOB (SMS/Email/Voice), push, and recovery-code challenges.
StepUpCodeForm — Shared 6-digit OTP or recovery-code input.

New Hooks:

useMfaStepUp — Wraps enroll, challenge, and verify flows with loading state and error handling.
useMfaRequirements — Determines whether to show enrollment factors or active authenticators.

References

Screenshot 2026-02-18 at 11 09 15 PM Screenshot 2026-03-13 at 1 22 57 PM Screenshot 2026-03-13 at 1 23 06 PM Screenshot 2026-03-13 at 1 23 16 PM Screenshot 2026-03-13 at 1 23 25 PM Screenshot 2026-03-13 at 1 23 34 PM Screenshot 2026-03-13 at 1 23 41 PM Screenshot 2026-03-13 at 1 23 46 PM

Testing

Please describe how this can be tested by reviewers. Be specific about anything not tested and reasons why. If this library has unit and tests should be added for new functionality and existing tests should complete without errors.

  • This change adds unit test coverage
  • This change has been tested on the latest version of the platform/language or why not

Checklist

@NaveenChand755 NaveenChand755 changed the title Feat/mfa step up components feat(core, react): mfa step up components Mar 13, 2026
@NaveenChand755 NaveenChand755 added enhancement New feature or request Gen AI Indicates that the most of the code in this PR were generated or assisted by generative AI tools. draft labels Mar 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

draft enhancement New feature or request Gen AI Indicates that the most of the code in this PR were generated or assisted by generative AI tools.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant