react-native-safe-area-context icon indicating copy to clipboard operation
react-native-safe-area-context copied to clipboard

fix: added run recalculation for safe_area when window did become visible

Open ruslan-deyarov opened this issue 1 year ago • 3 comments

Added run recalculation for safe_area when window did become visible

Summary

We found missed scenario when we have to run recalculation for safe_area. In case we open before native modal and then put our app into background mode. After restore it from background and close this modal we see old values for safe_area. We need to run recalculation to cover this scenario.

Native modal partially cover screen and in this case safe_area is reduced a little bit by iOS.

Screenshot 2024-03-08 at 15 32 09

ruslan-deyarov avatar Mar 13 '24 11:03 ruslan-deyarov

Do you have a reproduction here?

jacobp100 avatar Mar 13 '24 11:03 jacobp100

Do you have a reproduction here?

Yes, let me attach video.

ruslan-deyarov avatar Mar 13 '24 11:03 ruslan-deyarov

Wrong safe_area size after background and closing native modal on top.

https://github.com/th3rdwave/react-native-safe-area-context/assets/109741896/c0d5c2fa-9aaa-405b-92cb-eb4625b25d9d

ruslan-deyarov avatar Mar 13 '24 12:03 ruslan-deyarov

Thanks, sorry about the delay merging this!

janicduplessis avatar Apr 23 '24 17:04 janicduplessis