feat: add admin MFA UI - #15493
Conversation
🦋 Changeset detectedLatest commit: 7f821b3 The changes in this PR will be included in the next version bump. This PR includes changesets to release 78 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
ef89a6d to
39bc38f
Compare
| <Button variant="secondary" onClick={onClose}> | ||
| {t("actions.cancel")} | ||
| </Button> |
There was a problem hiding this comment.
suggestion: for the recovery codes screen, the cancel button is unnecessary here. I'm also not a big fan of showing the Download / Copy above the Cancel / Complete
Maybe we can either:
- Use the CodeBlock component for the recovery codes, with the built-in copy button, and show in the footer "Download" and "Complete"
- Show "Download" / "Copy" / "Complete" in the footer
| <> | ||
| <ShieldCheck className="text-ui-fg-subtle" /> | ||
| <Text size="small" leading="compact"> | ||
| {enabledFactorLabel || t("profile.mfa.authenticatorApp")} |
There was a problem hiding this comment.
q: not sure what enabledFactorLabel would be, but is it something that we can allow translating?
|
|
||
| if (isLoading || !user) { | ||
| return <SingleColumnPageSkeleton sections={1} /> | ||
| return <SingleColumnPageSkeleton sections={3} /> |
There was a problem hiding this comment.
Good catch, I used 3 before
| export const callbackWithCloudAuth = async ( | ||
| query: Record<string, unknown> | ||
| ): ReturnType<typeof sdk.auth.callback> => | ||
| sdk.auth.callback("user", "cloud", query) |
There was a problem hiding this comment.
I assume this works just fine when doing auth with Cloud? How does it work, does it require MFA after the oauth or it's skipped entirely?
There was a problem hiding this comment.
Cloud OAuth can return an MFA challenge after the OAuth callback. Admin then shows the same MFA challenge screen and only continues after challenge verification. So admin MFA is not skipped
sradevski
left a comment
There was a problem hiding this comment.
Looks good overall 👍 We just need to test it well before releasing a new core version
|
/snapshot-this |
🚀 A snapshot release has been made for this PRTest the snapshots by updating your yarn add @medusajs/admin-bundler@2.15.5-snapshot-20260526085619yarn add @medusajs/admin-sdk@2.15.5-snapshot-20260526085619yarn add @medusajs/admin-shared@2.15.5-snapshot-20260526085619yarn add @medusajs/admin-vite-plugin@2.15.5-snapshot-20260526085619yarn add @medusajs/dashboard@2.15.5-snapshot-20260526085619yarn add create-medusa-app@2.15.5-snapshot-20260526085619yarn add @medusajs/http-types-generator@2.15.5-snapshot-20260526085619yarn add @medusajs/cli@2.15.5-snapshot-20260526085619yarn add medusa-dev-cli@2.15.5-snapshot-20260526085619yarn add @medusajs/medusa-oas-cli@2.15.5-snapshot-20260526085619yarn add @medusajs/core-flows@2.15.5-snapshot-20260526085619yarn add @medusajs/framework@2.15.5-snapshot-20260526085619yarn add @medusajs/js-sdk@2.15.5-snapshot-20260526085619yarn add @medusajs/modules-sdk@2.15.5-snapshot-20260526085619yarn add @medusajs/orchestration@2.15.5-snapshot-20260526085619yarn add @medusajs/types@2.15.5-snapshot-20260526085619yarn add @medusajs/utils@2.15.5-snapshot-20260526085619yarn add @medusajs/workflows-sdk@2.15.5-snapshot-20260526085619yarn add @medusajs/deps@2.15.5-snapshot-20260526085619yarn add @medusajs/icons@2.15.5-snapshot-20260526085619yarn add @medusajs/ui@4.1.15-snapshot-20260526085619yarn add @medusajs/ui-preset@2.15.5-snapshot-20260526085619yarn add @medusajs/medusa@2.15.5-snapshot-20260526085619yarn add @medusajs/telemetry@2.15.5-snapshot-20260526085619yarn add @medusajs/test-utils@2.15.5-snapshot-20260526085619yarn add @medusajs/analytics@2.15.5-snapshot-20260526085619yarn add @medusajs/api-key@2.15.5-snapshot-20260526085619yarn add @medusajs/auth@2.15.5-snapshot-20260526085619yarn add @medusajs/cache-inmemory@2.15.5-snapshot-20260526085619yarn add @medusajs/cache-redis@2.15.5-snapshot-20260526085619yarn add @medusajs/caching@2.15.5-snapshot-20260526085619yarn add @medusajs/cart@2.15.5-snapshot-20260526085619yarn add @medusajs/currency@2.15.5-snapshot-20260526085619yarn add @medusajs/customer@2.15.5-snapshot-20260526085619yarn add @medusajs/event-bus-local@2.15.5-snapshot-20260526085619yarn add @medusajs/event-bus-redis@2.15.5-snapshot-20260526085619yarn add @medusajs/file@2.15.5-snapshot-20260526085619yarn add @medusajs/fulfillment@2.15.5-snapshot-20260526085619yarn add @medusajs/index@2.15.5-snapshot-20260526085619yarn add @medusajs/inventory@2.15.5-snapshot-20260526085619yarn add @medusajs/link-modules@2.15.5-snapshot-20260526085619yarn add @medusajs/locking@2.15.5-snapshot-20260526085619yarn add @medusajs/notification@2.15.5-snapshot-20260526085619yarn add @medusajs/order@2.15.5-snapshot-20260526085619yarn add @medusajs/payment@2.15.5-snapshot-20260526085619yarn add @medusajs/pricing@2.15.5-snapshot-20260526085619yarn add @medusajs/product@2.15.5-snapshot-20260526085619yarn add @medusajs/promotion@2.15.5-snapshot-20260526085619yarn add @medusajs/analytics-local@2.15.5-snapshot-20260526085619yarn add @medusajs/analytics-posthog@2.15.5-snapshot-20260526085619yarn add @medusajs/auth-emailpass@2.15.5-snapshot-20260526085619yarn add @medusajs/auth-github@2.15.5-snapshot-20260526085619yarn add @medusajs/auth-google@2.15.5-snapshot-20260526085619yarn add @medusajs/caching-redis@2.15.5-snapshot-20260526085619yarn add @medusajs/file-local@2.15.5-snapshot-20260526085619yarn add @medusajs/file-s3@2.15.5-snapshot-20260526085619yarn add @medusajs/fulfillment-manual@2.15.5-snapshot-20260526085619yarn add @medusajs/locking-postgres@2.15.5-snapshot-20260526085619yarn add @medusajs/locking-redis@2.15.5-snapshot-20260526085619yarn add @medusajs/notification-local@2.15.5-snapshot-20260526085619yarn add @medusajs/notification-sendgrid@2.15.5-snapshot-20260526085619yarn add @medusajs/payment-stripe@2.15.5-snapshot-20260526085619yarn add @medusajs/rbac@2.15.5-snapshot-20260526085619yarn add @medusajs/region@2.15.5-snapshot-20260526085619yarn add @medusajs/sales-channel@2.15.5-snapshot-20260526085619yarn add @medusajs/settings@2.15.5-snapshot-20260526085619yarn add @medusajs/stock-location@2.15.5-snapshot-20260526085619yarn add @medusajs/store@2.15.5-snapshot-20260526085619yarn add @medusajs/tax@2.15.5-snapshot-20260526085619yarn add @medusajs/translation@2.15.5-snapshot-20260526085619yarn add @medusajs/user@2.15.5-snapshot-20260526085619yarn add @medusajs/workflow-engine-inmemory@2.15.5-snapshot-20260526085619yarn add @medusajs/workflow-engine-redis@2.15.5-snapshot-20260526085619yarn add @medusajs/draft-order@2.15.5-snapshot-20260526085619yarn add @medusajs/loyalty-plugin@2.15.5-snapshot-20260526085619
|
9ecf8ce to
7f821b3
Compare
|
/snapshot-this |
* Add admin MFA UI * Refine admin MFA setup modal * Await admin MFA success callback * Remove dashboard dev proxy config * Refine MFA admin review feedback * Harden MFA admin error handling * fix(admin): prepare new apps for mfa
Adds admin MFA setup and challenge handling in the dashboard.
Bildschirmaufnahme.2026-05-25.um.09.15.45.mov