microsoft-authentication-library-for-android icon indicating copy to clipboard operation
microsoft-authentication-library-for-android copied to clipboard

On Android 15, MSAL Embedded WebView Login Page Input Fields Overlapped by On-Screen Keyboard

Open anikulytsya opened this issue 7 months ago • 1 comments

After migrating our app to target Android 15 (API level 35), we observed an issue with the Microsoft Authentication Library (MSAL) login page when using the embedded WebView. When the on-screen keyboard is opened (e.g., to enter the phone number or email), it overlaps the input fields instead of resizing the WebView or scrolling the content into view. As a result, users cannot see what they are typing, making it difficult or impossible to complete the login process.

Smartphone:

  • Device: reproducible on any device
  • Android Version: 15
  • MSAL Version: any version from 5.6 up to 6.2

To Reproduce

  • Launch the app on a device running Android 15 (API level 35).
  • Trigger MSAL authentication using the embedded WebView.
  • Focus an input field (e.g., username or password) to open the on-screen keyboard.
  • Observe that the keyboard overlaps the input fields.
Image

Expected behavior

  • The WebView should resize or scroll automatically so that the focused input field remains visible above the on-screen keyboard.

anikulytsya avatar Jul 16 '25 21:07 anikulytsya

It looks like this may be related to the Android System WebView version.

We noticed:

  • Scrolling works reliably on WebView versions 139.x and above
  • Issues appear consistently on version 138.x and bellow

You can easily check this if you add a newer implementation of WebView (e.g., Beta, Dev, or Canary) and change it from settings under Developer Options > WebView Implementation.

So it seems likely that the problem arises with the 138.x version of WebView.

Tzelalis avatar Aug 06 '25 10:08 Tzelalis