sergeykomlach/AdvancedBiometricPromptCompat

Bug: face authentication dialog out of screen bounds in portrait layout for tablet device

sandboiii opened this issue · 6 comments

Device: samsung galaxy tab s7
Android version: 12
When using face authentication dialog in portrait layout for tablet device it goes out of screen bounds (i.e. too wide).

Specifications:

Face authentication dialog in landscape layout:

Face authentication dialog in portrait layout:

Maybe the problem with

<dimen name="dialog_width">830dp</dimen>

In biometric/src/main/res/values-sw600dp-v31/dimens.xml

Hi.
dialog_width is the right point, as a hotfix it's fine.
but I would like to find some more "general" way to set dialog width for tablets to avoid tons of value-bla-bla

One thing that I don't understand is why there is bigger dialog_width specifically for v31? How sdk version affects screen size?

It was the wrong decision to use dialog_width from the begging :(.
In general "own" (non-system) dialogs were developed with the mind that they should look and behave similarly to system UI (exception: OEM solutions like Samsung)
On different SDK versions, minor difference exists, like padding, corners, etc., including dialog width.
On some SDK versions, the dialog is wider, on some - not, so dialog_width was introduced.
Now I see that dialog_width makes more problems than solves, so I focused on layouts refactoring to avoid dialog_width usage at all.

Can you please make a build with the quick fix?

2.0.99 published