Like the title says, there is an unexpected behavior that safe area constrained views get magnified on iOS when you try to navigate between UIViewControllers while toggling status bar hidden/unhidden.
A reproducible project can be found here.
I wonder if this is a bug in iOS. Hope someone can explain why the issue happens and how can we fix it.
Update:
For "get magnified" part above:
The issue only happens at a glance, 2-3 times out of 5, during the UIViewController's navigation so you may have to pay much attention so as to notice it.
The magnified parts are: green background and two white boxes.
Note that the views keep the same size before-and-after the navigation.
Also, in the project, you might want to tap 'Button' and 'Close' button continuously so that it switches very quickly, to easily get issue noticed.