App randomly stops using the whole screen

We have a weird issue with an app we are developing. Occasionally -- seemingly randomly -- the app will stop using the whole screen -- the content only uses the top three-fifths (approximately) of the screen. The bottom of the screen is black.

The entire view is visible i.e. the content is squished, not cropped.

So far, we've only been able to see it on one user's phone. Can't reproduce it on a simulator. This user doesn't have any similar issues on any other application.

According to the user, it always starts either on 1) a screen that contains an MPChart (https://github.com/danielgindi/Charts), or 2) a screen that contains a WKWebView.

Once the squishing happens, it usually continues to be squished on other screens the user navigates to, though it seems to randomly reset back to normal as the user navigates around.

We use SwiftUI.

The users hardware and OS version are iPhone XR Ver 14.4.2.
It seems to have something to do with safe areas -- the original code wrapping content on each screen:

Code Block
ZStack(alignment: .topLeading) {
LinearGradient(
gradient: Gradient(colors: [Color.backgroundStart, Color.backgroundEnd]),
startPoint: .top,
endPoint: .bottom)
VStack(alignment: .center) {
content()
}
}.accentColor(Color.accent)


Adding .edgesIgnoringSafeArea(.bottom) to the ZStack seems to have worked around the problem, though a) that doesn't seem like the "right" solution, and b) doesn't explain why the problem was occurring inconsistently, even on the device on which it was reproducible.
App randomly stops using the whole screen
 
 
Q