Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[iOS] Fixed Using safe area causes white area at the top upon entry focus #26063

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

devanathan-vaithiyanathan
Copy link
Contributor

@devanathan-vaithiyanathan devanathan-vaithiyanathan commented Nov 22, 2024

Root Cause

When an Entry is focused and the keyboard opens, the view adjusts and scrolls downward, causing a white space to appear at the top of the screen.

Description of Change

In the AdjustPosition method, the move value is calculated when CursorRect.Y is less than topBoundary and CursorRect.Bottom is also less than bottomBoundar, which lead to unnecessary scrollling. To address this, a condition was added to ensure that if the move value is less than 0, it is reset to 0.

Issues Fixed

Fixes #25866

Validated the behaviour in the following platforms

  • Android
  • Windows
  • iOS
  • Mac

UseSafeArea and IgnoreSafeArea are most relevant on iOS alone due to the unique layout constraints of safe areas.

Output Screenshot

Before After

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Nov 22, 2024
Copy link
Contributor

Hey there @devanathan-vaithiyanathan! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@jsuarezruiz
Copy link
Contributor

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[iOS] Using safe area causes white area at the top upon entry focus.
4 participants