frzi / swiftui-router

Path-based routing in SwiftUI
MIT License
900 stars 43 forks source link

Full screen navigation without ignoring safe area #46

Open blommegard opened 2 years ago

blommegard commented 2 years ago

I have tried without success in creating a full screen navigation that don't get clipped, is this even possible?

We still need the inner views to handle safe area insets for laying out its components, but having a slide transition between 2 views without ignoring safe area on the parent ends up with views appearing / disappearing on screen (landscape).

The only real solution I got is to read the safe area outside of the router and then pass it down as environment, however, this is not ideal because we need to rebuild all views to use the custom values + padding instead of the proper way to leverage safe area.