arcgis-maps-sdk-swift-toolkit icon indicating copy to clipboard operation
arcgis-maps-sdk-swift-toolkit copied to clipboard

Bottom toolbar covers floating panel

Open CalebRas opened this issue 1 year ago • 2 comments

Issue When opening a floatingPanel on a view with a bottom toolbar, the toolbar overlays the floating panel. This means that content at the bottom of the panel will be hidden behind the toolbar.

Simulator Screenshot - iPhone 15 Pro - 2024-04-10 at 10 28 54

Reproducible Code

Reproducible Code

struct ContentView: View {
    @State private var isPresented = false
    
    var body: some View {
        EmptyView()
            .toolbar {
                ToolbarItem(placement: .bottomBar) {
                    Button("Show Panel") { isPresented.toggle() }
                }
            }
            .floatingPanel(isPresented: $isPresented) {
                Text("Placeholder")
            }
    }
}

CalebRas avatar Apr 10 '24 17:04 CalebRas

Potential duplicate of #518

dfeinzimer avatar Apr 10 '24 20:04 dfeinzimer

After researching this a bit, I believe this is because FloatingPanel uses overlay(alignment:content:), which doesn't seem to allow a way to present content over system UI like the toolbar.

Long term we can probably look at wrapping sheets directly at compact widths.

dfeinzimer avatar Aug 01 '24 22:08 dfeinzimer