Skip to content

fix(auth): handle edge-to-edge insets in MFA challenge and auth screens - #2413

Merged
russellwheatley merged 4 commits into
version-10.0.0-beta04from
fix/mfa-edge-to-edge-insets
Jul 28, 2026
Merged

fix(auth): handle edge-to-edge insets in MFA challenge and auth screens#2413
russellwheatley merged 4 commits into
version-10.0.0-beta04from
fix/mfa-edge-to-edge-insets

Conversation

@demolaf

@demolaf demolaf commented Jul 22, 2026

Copy link
Copy Markdown
Member

Fixes #2403.

The MFA challenge screen had no inset handling, so its title collided with the status bar/camera cutout on edge-to-edge devices. Also found a related, opposite bug in six other auth screens combining Scaffold's innerPadding with a redundant, double-counted safeDrawingPadding() call.

  • MfaChallengeDefaults.kt: wrapped DefaultMfaChallengeContent in a Scaffold
  • SignInUI, SignUpUI, SignInEmailLinkUI, ResetPasswordUI, EnterPhoneNumberUI, EnterVerificationCodeUI: removed the redundant .safeDrawingPadding(), added a uniform 16.dp margin
  • FirebaseAuthScreen.customMethodPickerLayout now renders full-screen (was Scaffold-confined) so fully custom layouts can go edge-to-edge; direct behavior change since library is pre-1.0

Preview

Screenshot_1784708851

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the custom method picker layout to render edge-to-edge across the entire screen, bypassing the default Scaffold and terms configuration when a custom layout is provided. It also cleans up safeDrawingPadding across several email and phone auth screens and wraps the MFA challenge content in a Scaffold. The review feedback suggests optimizing the MFA challenge layout by applying padding directly to the root Column instead of using a Scaffold, updating an outdated KDoc comment in the preview, and reverting several helper functions and composables in the demo activity back to private visibility to maintain proper encapsulation.

Comment thread app/src/main/java/com/firebaseui/android/demo/CustomMethodPickerDemoActivity.kt Outdated
Comment thread app/src/main/java/com/firebaseui/android/demo/CustomMethodPickerDemoActivity.kt Outdated
Comment thread app/src/main/java/com/firebaseui/android/demo/CustomMethodPickerDemoActivity.kt Outdated
@demolaf demolaf linked an issue Jul 22, 2026 that may be closed by this pull request
@demolaf
demolaf force-pushed the version-10.0.0-beta04 branch from d382bd5 to 1ecd498 Compare July 22, 2026 22:13

@russellwheatley russellwheatley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of suggestions on the customMethodPickerLayout changes below.

Also, this branch looks like it's stacked on top of the unmerged display-name-validation fix (d382bd5) rather than rebased onto version-10.0.0-beta04, so the diff here currently pulls in an unrelated SignUpUI/SignUpUITest.kt change. Can you rebase onto the base branch before merge so the diff only has your two commits?

@demolaf
demolaf force-pushed the fix/mfa-edge-to-edge-insets branch from 747dddc to 345f70c Compare July 27, 2026 11:25
@demolaf
demolaf requested a review from russellwheatley July 28, 2026 07:18

@russellwheatley russellwheatley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@russellwheatley
russellwheatley merged commit 76e5a3f into version-10.0.0-beta04 Jul 28, 2026
9 of 10 checks passed
@russellwheatley
russellwheatley deleted the fix/mfa-edge-to-edge-insets branch July 28, 2026 10:00
@github-project-automation github-project-automation Bot moved this from Backlog to Done in studio-2394994192-60a69 Jul 28, 2026
demolaf added a commit that referenced this pull request Jul 29, 2026
…2404)

* fix(auth): validate display name only when required in sign-up form (#2383)

* fix(auth): validate display name only when required in sign-up form

* fix(auth): use locale-safe matcher for sign-up button in test

* fix(internal): append CHAR_LIMIT to translation descriptions in export script (#2417)

Fixes #1613

* fix(auth): mitigate tapjacking on the auth activity window (#2416)

Fixes #2041

* sample(app): add Firestore, Database & Storage demos to sample app (#2406)

* fix(auth): allow customizing top app bar colors via AuthUITheme (#2391)

* fix(auth): handle edge-to-edge insets in MFA challenge and auth screens (#2413)

* fix(auth): use fixed padding for method picker provider buttons (#2424) (#2426)

* fix(firestore): catch InterruptedException in FirestorePagingSource

* fix(firestore): drop load error logging and restore rx error handler in test

* fix(firestore): return LoadResult.Error for every load failure instead of throwing

* fix(firestore): fix PageKey.equals NPE on null snapshots and add hashCode

* test(firestore): run paging source test in CI via robolectric and replace sleeps with latches

* fix(firestore): log genuine load failures while keeping cancellations silent

---------

Co-authored-by: Oluwatobi Shokunbi <ayoshokz@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The default UI of the MFA does not handle edge-to-edge properly.

2 participants