I’ve a swiftUI view embed in UIhostingController with UInavigation. What I am attempting to attain is that after I’m presenting a .sheet overlay I wish to overlay the rest of the display with black shade with opacity.
one thing like this:
public var physique: some View {
ZStack {
Coloration.shade(for: ColorToken.Background._02, colorScheme: colorScheme)
.ignoresSafeArea()
mainContent
.padding(.high)
if retailer.bottomSheetPosition != .hidden {
Coloration.black
.opacity(0.6)
.ignoresSafeArea()
.transition(.opacity)
.contentShape(Rectangle())
.onTapGesture {
ship(.didTapDismissBottomSheet, animation: .easeOut(length: 0.3))
}
}
}
Downside that I am dealing with proper now could be that even tho it covers the rest display with shade, navigation buttons are nonetheless on the highest of the view heirarchy, so they don’t seem to be lined and are tappable.
it appears like this:
What are my choices?