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

Preserve View margins for snapshots #757

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

Conversation

leohemanth
Copy link

@leohemanth leohemanth commented Aug 4, 2023

This addresses the issue: #750

Looks like we are trying to update ViewController's root view's frame to avoid safe area influence, but this would change the directionalLayoutMargins of the view.

This PR updates the strategy to restore the margins after we update the frame.

This PR also adds unit tests for the same.

@leohemanth leohemanth changed the title Preserve UIView margins for snapshots Preserve View margins for snapshots Aug 4, 2023
@leohemanth leohemanth marked this pull request as draft August 4, 2023 20:41
@leohemanth leohemanth marked this pull request as ready for review August 16, 2023 16:06
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.

None yet

1 participant